Merge branch 'develop' into feat/contacts-redesign

This commit is contained in:
Sivin Varghese
2024-11-20 20:26:27 +05:30
committed by GitHub
19 changed files with 369 additions and 344 deletions
@@ -118,13 +118,12 @@ watch(
<ComboBoxDropdown
ref="dropdownRef"
v-model:search-value="search"
:open="open"
:options="filteredOptions"
:search-value="search"
:search-placeholder="searchPlaceholder"
:empty-state="emptyState"
:selected-values="selectedValue"
@update:search-value="search = $event"
@search="emit('search', $event)"
@select="selectOption"
/>
@@ -11,10 +11,6 @@ const props = defineProps({
type: Array,
required: true,
},
searchValue: {
type: String,
required: true,
},
searchPlaceholder: {
type: String,
default: '',
@@ -33,10 +29,15 @@ const props = defineProps({
},
});
const emit = defineEmits(['update:searchValue', 'select', 'search']);
const emit = defineEmits(['select', 'search']);
const { t } = useI18n();
const searchValue = defineModel('searchValue', {
type: String,
default: '',
});
const searchInput = ref(null);
const isSelected = option => {
@@ -47,7 +48,7 @@ const isSelected = option => {
};
const onInputSearch = event => {
emit('update:searchValue', event.target.value);
searchValue.value = event.target.value;
emit('search', event.target.value);
};