@dataloop-ai/components 0.20.112 → 0.20.113
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
|
@@ -71,6 +71,8 @@
|
|
|
71
71
|
@input="handleSearchInput"
|
|
72
72
|
@focus="handleSearchFocus"
|
|
73
73
|
@blur="handleSearchBlur"
|
|
74
|
+
@keyup.enter="handleSearchEnter"
|
|
75
|
+
@keyup.esc="handleSearchEscape"
|
|
74
76
|
/>
|
|
75
77
|
<dl-tooltip v-if="disabled && disabledTooltip">
|
|
76
78
|
{{ disabledTooltip }}
|
|
@@ -451,6 +453,8 @@ export default defineComponent({
|
|
|
451
453
|
emits: [
|
|
452
454
|
'search-focus',
|
|
453
455
|
'search-blur',
|
|
456
|
+
'search-enter',
|
|
457
|
+
'search-escape',
|
|
454
458
|
'filter',
|
|
455
459
|
'change',
|
|
456
460
|
'search-input',
|
|
@@ -1023,6 +1027,16 @@ export default defineComponent({
|
|
|
1023
1027
|
|
|
1024
1028
|
return html
|
|
1025
1029
|
},
|
|
1030
|
+
handleSearchEnter(e: Event): void {
|
|
1031
|
+
if (this.searchable) {
|
|
1032
|
+
this.$emit('search-enter', e, this.searchInputValue)
|
|
1033
|
+
}
|
|
1034
|
+
},
|
|
1035
|
+
handleSearchEscape(e: Event): void {
|
|
1036
|
+
if (this.searchable) {
|
|
1037
|
+
this.$emit('search-escape', e, this.searchInputValue)
|
|
1038
|
+
}
|
|
1039
|
+
},
|
|
1026
1040
|
handleSearchBlur(e: Event): void {
|
|
1027
1041
|
if (this.searchable) {
|
|
1028
1042
|
const inputRef = this.$refs.searchInput as HTMLInputElement
|