From 52a557febcfe2f5949d91119fda75a85fccbe972 Mon Sep 17 00:00:00 2001 From: mertsincan Date: Fri, 5 Aug 2022 10:30:13 +0100 Subject: [PATCH] Refactor --- src/components/multiselect/MultiSelect.vue | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/components/multiselect/MultiSelect.vue b/src/components/multiselect/MultiSelect.vue index 170272ad6..2d62050da 100755 --- a/src/components/multiselect/MultiSelect.vue +++ b/src/components/multiselect/MultiSelect.vue @@ -67,7 +67,7 @@
  • + @click="onOptionSelect($event, option, getOptionIndex(i, getItemOptions), true)" @mousemove="onOptionMouseMove($event, getOptionIndex(i, getItemOptions))">
    @@ -429,7 +429,7 @@ export default { onHeaderCheckboxBlur() { this.headerCheckboxFocused = false; }, - onOptionSelect(event, option, index = -1) { + onOptionSelect(event, option, index = -1, isFocus = false) { if (this.disabled || this.isOptionDisabled(option)) { return; } @@ -443,7 +443,7 @@ export default { value = [...(this.modelValue || []), this.getOptionValue(option)]; this.updateModel(event, value); - this.$refs.focusInput.focus(); + isFocus && this.$refs.focusInput.focus(); index !== -1 && (this.focusedOptionIndex = index); }, onOptionMouseMove(event, index) {