From b1d08b19eef1cf5153ea17d668173f51a1fd81d8 Mon Sep 17 00:00:00 2001 From: Thanaphon Frappet Date: Thu, 14 Nov 2024 17:50:50 +0700 Subject: [PATCH] refactor: add define props multiple --- src/components/shared/SelectInput.vue | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/components/shared/SelectInput.vue b/src/components/shared/SelectInput.vue index 14f4a33c..1026ca22 100644 --- a/src/components/shared/SelectInput.vue +++ b/src/components/shared/SelectInput.vue @@ -3,7 +3,7 @@ import { onMounted, ref, watch } from 'vue'; import { selectFilterOptionRefMod } from 'src/stores/utils'; import { QSelect } from 'quasar'; -const model = defineModel | null>(); +const model = defineModel | null>(); const options = ref[]>([]); let defaultFilter: ( @@ -26,6 +26,7 @@ const props = withDefaults( incremental?: boolean; fillInput?: boolean; disable?: boolean; + multiple?: boolean; rules?: ((value: string) => string | true)[]; }>(), @@ -75,7 +76,9 @@ watch( use-input emit-value map-options - :hideSelected + :multiple + :use-chips="multiple" + :hide-selected hide-bottom-space :fill-input="fillInput && !!model" :hide-dropdown-icon="readonly" @@ -108,7 +111,6 @@ watch(