@webitel/ui-datalist 1.0.92 → 1.0.94
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
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@webitel/ui-datalist",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.94",
|
|
4
4
|
"description": "Toolkit for building data lists in webitel ui system",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"make-all": "npm version patch --git-tag-version false && ( npm run lint:fix || true) && (npm run build:types || true) && npm run utils:publish",
|
|
@@ -36,7 +36,7 @@
|
|
|
36
36
|
"@vuelidate/core": "^2.0.3",
|
|
37
37
|
"@vuelidate/validators": "^2.0.4",
|
|
38
38
|
"@vueuse/core": "^13.3.0",
|
|
39
|
-
"@webitel/api-services": "^0.0.
|
|
39
|
+
"@webitel/api-services": "^0.0.90",
|
|
40
40
|
"@webitel/styleguide": "^24.12.61",
|
|
41
41
|
"@webitel/ui-sdk": "^25.8.62",
|
|
42
42
|
"zod": "^3.25.55"
|
|
@@ -19,6 +19,7 @@
|
|
|
19
19
|
<section class="apply-preset-main-content">
|
|
20
20
|
<wt-search-bar
|
|
21
21
|
:value="search"
|
|
22
|
+
@input="handleSearchInput"
|
|
22
23
|
@search="search = $event"
|
|
23
24
|
/>
|
|
24
25
|
|
|
@@ -118,15 +119,30 @@ filtersManager.value.addFilter({
|
|
|
118
119
|
value: props.namespace,
|
|
119
120
|
});
|
|
120
121
|
|
|
122
|
+
const lastSetSearchValue = ref<string | null>(null);
|
|
123
|
+
|
|
121
124
|
const search = computed({
|
|
122
125
|
get: () => {
|
|
123
126
|
return filtersManager.value.getFilter('search')?.value || '';
|
|
124
127
|
},
|
|
125
128
|
set: (value) => {
|
|
129
|
+
// Skip if this value was already set via handleSearchInput
|
|
130
|
+
if (lastSetSearchValue.value === value) {
|
|
131
|
+
lastSetSearchValue.value = null;
|
|
132
|
+
return;
|
|
133
|
+
}
|
|
126
134
|
filtersManager.value.addFilter({ name: 'search', value });
|
|
127
135
|
},
|
|
128
136
|
});
|
|
129
137
|
|
|
138
|
+
const handleSearchInput = (value: string) => {
|
|
139
|
+
// Update search immediately when cleared to bypass debounce
|
|
140
|
+
if (!value) {
|
|
141
|
+
lastSetSearchValue.value = value;
|
|
142
|
+
filtersManager.value.addFilter({ name: 'search', value });
|
|
143
|
+
}
|
|
144
|
+
};
|
|
145
|
+
|
|
130
146
|
const {
|
|
131
147
|
showEmpty,
|
|
132
148
|
image: imageEmpty,
|
|
@@ -229,7 +229,10 @@ export const tableHeadersStoreBody = ({
|
|
|
229
229
|
isReorderingColumn.value = true;
|
|
230
230
|
|
|
231
231
|
const reordered = setHeaderOrder(orderedFields);
|
|
232
|
-
|
|
232
|
+
const uniqueHeaders = headers.value.filter(
|
|
233
|
+
(merged) => !reordered.some((r) => r.field === merged.field),
|
|
234
|
+
);
|
|
235
|
+
updateShownHeaders([...reordered, ...uniqueHeaders]);
|
|
233
236
|
|
|
234
237
|
nextTick(() => {
|
|
235
238
|
isReorderingColumn.value = false;
|