diff --git a/app/javascript/dashboard/components/ui/Dropdown/DropdownList.vue b/app/javascript/dashboard/components/ui/Dropdown/DropdownList.vue index 0ecb6bf08..e6de8e1b1 100644 --- a/app/javascript/dashboard/components/ui/Dropdown/DropdownList.vue +++ b/app/javascript/dashboard/components/ui/Dropdown/DropdownList.vue @@ -84,10 +84,10 @@ const shouldShowEmptyState = computed(() => { diff --git a/app/javascript/dashboard/components/ui/Dropdown/DropdownSearch.vue b/app/javascript/dashboard/components/ui/Dropdown/DropdownSearch.vue index 67ed6820c..6c663ae6c 100644 --- a/app/javascript/dashboard/components/ui/Dropdown/DropdownSearch.vue +++ b/app/javascript/dashboard/components/ui/Dropdown/DropdownSearch.vue @@ -1,10 +1,6 @@ @@ -29,16 +30,15 @@ const emit = defineEmits(['input', 'remove']); class="text-slate-400 dark:text-slate-400 flex-shrink-0" /> export default { - // The value types are dynamic, hence prop validation removed to work with our action schema - // eslint-disable-next-line vue/require-prop-types - props: ['teams', 'value'], - emits: ['input'], + props: { + teams: { type: Array, required: true }, + modelValue: { type: Object, required: true }, + }, + emits: ['update:modelValue'], data() { return { selectedTeams: [], @@ -11,13 +12,13 @@ export default { }; }, mounted() { - const { team_ids: teamIds } = this.value; + const { team_ids: teamIds } = this.modelValue; this.selectedTeams = teamIds; - this.message = this.value.message; + this.message = this.modelValue.message; }, methods: { updateValue() { - this.$emit('input', { + this.$emit('update:modelValue', { team_ids: this.selectedTeams.map(team => team.id), message: this.message, }); diff --git a/app/javascript/dashboard/routes/dashboard/helpcenter/components/Sidebar/Sidebar.vue b/app/javascript/dashboard/routes/dashboard/helpcenter/components/Sidebar/Sidebar.vue index 3cef5e52b..243ef1b69 100644 --- a/app/javascript/dashboard/routes/dashboard/helpcenter/components/Sidebar/Sidebar.vue +++ b/app/javascript/dashboard/routes/dashboard/helpcenter/components/Sidebar/Sidebar.vue @@ -37,7 +37,7 @@ export default { default: () => [], }, }, - emits: ['input', 'openPopover', 'openModal'], + emits: ['openPopover', 'openModal'], computed: { hasCategory() { return ( @@ -50,9 +50,6 @@ export default { }, }, methods: { - onSearch(value) { - this.$emit('input', value); - }, openPortalPopover() { this.$emit('openPopover'); }, diff --git a/app/javascript/dashboard/routes/dashboard/helpcenter/components/Sidebar/SidebarSearch.vue b/app/javascript/dashboard/routes/dashboard/helpcenter/components/Sidebar/SidebarSearch.vue deleted file mode 100644 index 1426a3c31..000000000 --- a/app/javascript/dashboard/routes/dashboard/helpcenter/components/Sidebar/SidebarSearch.vue +++ /dev/null @@ -1,63 +0,0 @@ - - - - - - - - - - - - diff --git a/app/javascript/dashboard/routes/dashboard/settings/agentBots/components/CSMLMonacoEditor.vue b/app/javascript/dashboard/routes/dashboard/settings/agentBots/components/CSMLMonacoEditor.vue index 17885ba42..0f80e0e31 100644 --- a/app/javascript/dashboard/routes/dashboard/settings/agentBots/components/CSMLMonacoEditor.vue +++ b/app/javascript/dashboard/routes/dashboard/settings/agentBots/components/CSMLMonacoEditor.vue @@ -5,12 +5,12 @@ import { mapGetters } from 'vuex'; export default { components: { LoadingState }, props: { - value: { + modelValue: { type: String, default: '', }, }, - emits: ['input'], + emits: ['update:modelValue'], data() { return { iframeLoading: true, @@ -30,7 +30,7 @@ export default { return; } const csmlContent = e.data.replace('chatwoot-csml-editor:update', ''); - this.$emit('input', csmlContent); + this.$emit('update:modelValue', csmlContent); }; }, methods: { @@ -38,7 +38,7 @@ export default { const frameElement = document.getElementById(`csml-editor--frame`); const eventData = { event: 'editorContext', - data: this.value || '', + data: this.modelValue || '', }; frameElement.contentWindow.postMessage(JSON.stringify(eventData), '*'); this.iframeLoading = false; diff --git a/app/javascript/dashboard/routes/dashboard/settings/profile/NotificationCheckBox.vue b/app/javascript/dashboard/routes/dashboard/settings/profile/NotificationCheckBox.vue index 4cd512055..7b2c4fd22 100644 --- a/app/javascript/dashboard/routes/dashboard/settings/profile/NotificationCheckBox.vue +++ b/app/javascript/dashboard/routes/dashboard/settings/profile/NotificationCheckBox.vue @@ -2,7 +2,7 @@ import { ref, watch } from 'vue'; const props = defineProps({ - value: { + modelValue: { type: String, required: true, }, @@ -20,9 +20,9 @@ const props = defineProps({ }, }); -const emit = defineEmits(['input']); +const emit = defineEmits(['update:modelValue', 'input']); -const localValue = ref(props.value); +const localValue = ref(props.modelValue); const localFlags = ref(props.selectedFlags); watch( @@ -33,6 +33,7 @@ watch( ); const handleInput = e => { + emit('update:modelValue', props.type, e); emit('input', props.type, e); }; diff --git a/app/javascript/dashboard/routes/dashboard/settings/profile/NotificationPreferences.vue b/app/javascript/dashboard/routes/dashboard/settings/profile/NotificationPreferences.vue index 8e49a4366..215b46923 100644 --- a/app/javascript/dashboard/routes/dashboard/settings/profile/NotificationPreferences.vue +++ b/app/javascript/dashboard/routes/dashboard/settings/profile/NotificationPreferences.vue @@ -257,8 +257,8 @@ export default { diff --git a/app/javascript/v3/components/Form/RadioTags.vue b/app/javascript/v3/components/Form/RadioTags.vue deleted file mode 100644 index 8624fa405..000000000 --- a/app/javascript/v3/components/Form/RadioTags.vue +++ /dev/null @@ -1,57 +0,0 @@ - - - - - - - {{ option.label }} - - - - diff --git a/app/javascript/v3/components/Form/Switch.vue b/app/javascript/v3/components/Form/Switch.vue index 495172169..cc2fc6133 100644 --- a/app/javascript/v3/components/Form/Switch.vue +++ b/app/javascript/v3/components/Form/Switch.vue @@ -1,12 +1,12 @@ - - - - - {{ label }} - - - - {{ error }} - - - {{ helpText }} - - - diff --git a/app/javascript/widget/components/Form/TextArea.vue b/app/javascript/widget/components/Form/TextArea.vue deleted file mode 100644 index e617be361..000000000 --- a/app/javascript/widget/components/Form/TextArea.vue +++ /dev/null @@ -1,91 +0,0 @@ - - - - - - {{ label }} - - - - {{ error }} - - - - -