@dataloop-ai/components 0.18.24 → 0.18.26
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
:style="iconStyle"
|
|
14
14
|
:icon="icon"
|
|
15
15
|
:color="iconColor"
|
|
16
|
-
size="
|
|
16
|
+
:size="iconSize"
|
|
17
17
|
/>
|
|
18
18
|
<span
|
|
19
19
|
class="text"
|
|
@@ -98,6 +98,10 @@ export default defineComponent({
|
|
|
98
98
|
type: String,
|
|
99
99
|
default: 'dl-color-darker'
|
|
100
100
|
},
|
|
101
|
+
iconSize: {
|
|
102
|
+
type: String,
|
|
103
|
+
default: '16px'
|
|
104
|
+
},
|
|
101
105
|
fluid: {
|
|
102
106
|
type: Boolean,
|
|
103
107
|
default: false
|
|
@@ -100,7 +100,12 @@
|
|
|
100
100
|
]"
|
|
101
101
|
>
|
|
102
102
|
<slot name="append" />
|
|
103
|
-
<span
|
|
103
|
+
<span
|
|
104
|
+
v-if="showClearButton"
|
|
105
|
+
v-show="focused || mouseOverClear"
|
|
106
|
+
@mouseenter="mouseOverClear = true"
|
|
107
|
+
@mouseleave="mouseOverClear = false"
|
|
108
|
+
>
|
|
104
109
|
<dl-button
|
|
105
110
|
ref="input-clear-button"
|
|
106
111
|
icon="icon-dl-close"
|
|
@@ -378,6 +383,7 @@ export default defineComponent({
|
|
|
378
383
|
},
|
|
379
384
|
emits: ['input', 'focus', 'blur', 'clear', 'enter', 'update:model-value'],
|
|
380
385
|
setup(props, { emit }) {
|
|
386
|
+
const mouseOverClear = ref(false)
|
|
381
387
|
const highlightedIndex = ref(-1)
|
|
382
388
|
const isMenuOpen = ref(false)
|
|
383
389
|
const suggestItems = computed<string[]>(() => {
|
|
@@ -408,7 +414,8 @@ export default defineComponent({
|
|
|
408
414
|
onAutoSuggestClick,
|
|
409
415
|
isMenuOpen,
|
|
410
416
|
setHighlightedIndex,
|
|
411
|
-
handleSelectedItem
|
|
417
|
+
handleSelectedItem,
|
|
418
|
+
mouseOverClear
|
|
412
419
|
}
|
|
413
420
|
},
|
|
414
421
|
data() {
|