@webitel/ui-sdk 26.6.88 → 26.6.90
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/dist/{components-DaDed2hn.js → components-BqXO2X92.js} +397 -395
- package/dist/{composables-DEdhzUqN.js → composables-CuxX3Ib0.js} +39 -34
- package/dist/ui-sdk.css +1 -1
- package/dist/ui-sdk.js +1 -1
- package/dist/ui-sdk.umd.cjs +274 -274
- package/dist/{wt-chat-emoji-T8LDtZS-.js → wt-chat-emoji-DMGWnSDG.js} +1 -1
- package/dist/{wt-display-chip-items-C0p7MwL6.js → wt-display-chip-items-CL9lPf4i.js} +1 -1
- package/dist/{wt-expansion-card-BANe4zX2.js → wt-expansion-card-afRJCmRw.js} +1 -1
- package/dist/{wt-galleria-YxNez7SX.js → wt-galleria-DGkRyAjw.js} +1 -1
- package/dist/{wt-send-message-popup-D4CA3o4I.js → wt-send-message-popup-BV_3DOj4.js} +1 -1
- package/dist/{wt-table-CPGSqs5Z.js → wt-table-CC01Dw6T.js} +1 -1
- package/dist/{wt-type-extension-value-input-DSF-DMlv.js → wt-type-extension-value-input-Cb_PUwOS.js} +1 -1
- package/dist/{wt-vidstack-player-Wgg83Pt1.js → wt-vidstack-player-DlSB9Hkq.js} +1 -1
- package/package.json +1 -1
- package/src/components/_internals/composables/useSelect/useSelect.ts +5 -4
- package/src/components/_internals/composables/useSelect/useSelectDropdown.ts +25 -1
- package/src/components/_internals/composables/useSelect/useSelectOptions.ts +2 -2
- package/src/components/wt-card/wt-card.vue +1 -1
- package/src/components/wt-popup/wt-popup.vue +14 -0
- package/types/components/_internals/composables/useSelect/useSelect.d.ts +1 -1
- package/types/components/_internals/composables/useSelect/useSelectDropdown.d.ts +1 -0
- package/types/components/_internals/composables/useSelect/useSelectOptions.d.ts +1 -1
|
@@ -73,37 +73,42 @@ var l = () => {
|
|
|
73
73
|
o.value = "", s("");
|
|
74
74
|
});
|
|
75
75
|
} };
|
|
76
|
-
}, _ = ({ selectId: e, selectRef: t, filterInput: n, searchMethod:
|
|
77
|
-
let
|
|
76
|
+
}, _ = ({ selectId: e, selectRef: t, filterInput: n, searchMethod: i, filteredOptions: a, filterText: o, filterOptions: l, resetAndFetch: u, sortOptions: d, fetchOptions: f, isLoading: p, searchHasNext: m }) => {
|
|
77
|
+
let h = s(!1), g = null, _ = null, v = () => document.querySelector(`#${e.value}_list`)?.parentElement, y = (e) => {
|
|
78
78
|
let t = e.target;
|
|
79
|
-
t.scrollTop + t.clientHeight >= t.scrollHeight - 40 && !
|
|
80
|
-
}
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
79
|
+
t.scrollTop + t.clientHeight >= t.scrollHeight - 40 && !p.value && m.value && f();
|
|
80
|
+
}, b = () => {
|
|
81
|
+
h.value = !0, a.value = d(a.value);
|
|
82
|
+
}, x = () => {
|
|
83
|
+
n.value?.focus(), i.value && v()?.addEventListener("scroll", y);
|
|
84
|
+
let e = t?.value?.overlay;
|
|
85
|
+
e && (g = new ResizeObserver(() => {
|
|
86
|
+
t.value?.alignOverlay();
|
|
87
|
+
}), g.observe(e));
|
|
88
|
+
let r = t?.value?.$el;
|
|
89
|
+
if (r) {
|
|
90
|
+
let e = r.getBoundingClientRect().top, n = r.getBoundingClientRect().left, i = () => {
|
|
91
|
+
let a = r.getBoundingClientRect();
|
|
92
|
+
(a.top !== e || a.left !== n) && (e = a.top, n = a.left, t.value?.alignOverlay()), _ = requestAnimationFrame(i);
|
|
93
|
+
};
|
|
94
|
+
_ = requestAnimationFrame(i);
|
|
95
|
+
}
|
|
96
|
+
}, S = !1;
|
|
97
|
+
return c(a, () => {
|
|
98
|
+
S && (S = !1, r(() => v()?.scrollTo(0, 0)));
|
|
99
|
+
}), {
|
|
100
|
+
isDropdownOpen: h,
|
|
101
|
+
onDropdownBeforeShow: b,
|
|
86
102
|
onDropdownBeforeHide: () => {
|
|
87
103
|
let e = t?.value?.overlay;
|
|
88
|
-
e && (e.style.pointerEvents = "none"),
|
|
89
|
-
},
|
|
90
|
-
onDropdownShow: () => {
|
|
91
|
-
n.value?.focus(), r.value && g()?.addEventListener("scroll", _);
|
|
92
|
-
let e = t?.value?.overlay;
|
|
93
|
-
e && (m = new ResizeObserver(() => {
|
|
94
|
-
t.value?.alignOverlay();
|
|
95
|
-
}), m.observe(e));
|
|
96
|
-
let i = t?.value?.$el;
|
|
97
|
-
if (i) {
|
|
98
|
-
let e = i.getBoundingClientRect().top, n = i.getBoundingClientRect().left, r = () => {
|
|
99
|
-
let a = i.getBoundingClientRect();
|
|
100
|
-
(a.top !== e || a.left !== n) && (e = a.top, n = a.left, t.value?.alignOverlay()), h = requestAnimationFrame(r);
|
|
101
|
-
};
|
|
102
|
-
h = requestAnimationFrame(r);
|
|
103
|
-
}
|
|
104
|
+
e && (e.style.pointerEvents = "none"), v()?.scrollTo(0, 0);
|
|
104
105
|
},
|
|
106
|
+
onDropdownShow: x,
|
|
105
107
|
onDropdownHide: () => {
|
|
106
|
-
|
|
108
|
+
h.value = !1, g?.disconnect(), g = null, _ !== null && (cancelAnimationFrame(_), _ = null), i.value ? (v()?.removeEventListener("scroll", y), o.value && u()) : l(""), o.value = "";
|
|
109
|
+
},
|
|
110
|
+
filterOptionsAndScrollToTop: (e) => {
|
|
111
|
+
S = !0, l(e);
|
|
107
112
|
}
|
|
108
113
|
};
|
|
109
114
|
}, v = (e) => {
|
|
@@ -187,12 +192,12 @@ var l = () => {
|
|
|
187
192
|
fetchOptions: k,
|
|
188
193
|
fetchSelectedByIds: O,
|
|
189
194
|
resetAndFetch: A,
|
|
190
|
-
|
|
195
|
+
filterOptionsBase: M,
|
|
191
196
|
updateSelectedOptionsCache: D,
|
|
192
197
|
isOptionDisabled: (e) => g?.value ? Array.isArray(g.value) ? g.value.some((t) => typeof t == "object" && !!t && typeof e == "object" && !!e && t[l.value] === e[l.value]) : !!g.value : !1
|
|
193
198
|
};
|
|
194
199
|
}, b = ({ selected: e, options: t, optionLabel: n, optionValue: r, dataKey: a, allowCustomValues: o, manualCustomValues: s = !1, filterInput: c, selectRef: l, searchMethod: u, selectId: d, isSingle: f, disabledOptions: p = void 0, emit: m = () => {} }) => {
|
|
195
|
-
let { filterText: h, filteredOptions: b, isLoading: x, searchHasNext: S, sortOptions: C, getOptionLabel: w, fetchOptions: T, fetchSelectedByIds: E, resetAndFetch: D,
|
|
200
|
+
let { filterText: h, filteredOptions: b, isLoading: x, searchHasNext: S, sortOptions: C, getOptionLabel: w, fetchOptions: T, fetchSelectedByIds: E, resetAndFetch: D, filterOptionsBase: O, updateSelectedOptionsCache: k, isOptionDisabled: A } = y({
|
|
196
201
|
selected: e,
|
|
197
202
|
options: t,
|
|
198
203
|
optionLabel: n,
|
|
@@ -201,7 +206,7 @@ var l = () => {
|
|
|
201
206
|
allowCustomValues: o,
|
|
202
207
|
searchMethod: u,
|
|
203
208
|
disabledOptions: p
|
|
204
|
-
}), { isDropdownOpen: j, onDropdownBeforeShow: M, onDropdownBeforeHide: N, onDropdownShow: P, onDropdownHide: F } = _({
|
|
209
|
+
}), { isDropdownOpen: j, onDropdownBeforeShow: M, onDropdownBeforeHide: N, onDropdownShow: P, onDropdownHide: F, filterOptionsAndScrollToTop: I } = _({
|
|
205
210
|
selectId: d,
|
|
206
211
|
selectRef: l,
|
|
207
212
|
filterInput: c,
|
|
@@ -214,14 +219,14 @@ var l = () => {
|
|
|
214
219
|
fetchOptions: T,
|
|
215
220
|
isLoading: x,
|
|
216
221
|
searchHasNext: S
|
|
217
|
-
}), { showFooterLoader:
|
|
222
|
+
}), { showFooterLoader: L } = v(x), { onInputKeydown: R } = g({
|
|
218
223
|
selected: e,
|
|
219
224
|
filteredOptions: b,
|
|
220
225
|
options: t,
|
|
221
226
|
optionValue: r,
|
|
222
227
|
dataKey: a,
|
|
223
228
|
filterText: h,
|
|
224
|
-
filterOptions:
|
|
229
|
+
filterOptions: I,
|
|
225
230
|
updateSelectedOptionsCache: k,
|
|
226
231
|
selectRef: l,
|
|
227
232
|
allowCustomValues: o,
|
|
@@ -233,18 +238,18 @@ var l = () => {
|
|
|
233
238
|
await E(), u.value && T();
|
|
234
239
|
}), {
|
|
235
240
|
isLoading: x,
|
|
236
|
-
showFooterLoader:
|
|
241
|
+
showFooterLoader: L,
|
|
237
242
|
isDropdownOpen: j,
|
|
238
243
|
filterText: h,
|
|
239
244
|
filteredOptions: b,
|
|
240
245
|
getOptionLabel: w,
|
|
241
246
|
fetchOptions: T,
|
|
242
|
-
filterOptions:
|
|
247
|
+
filterOptions: I,
|
|
243
248
|
onDropdownBeforeShow: M,
|
|
244
249
|
onDropdownBeforeHide: N,
|
|
245
250
|
onDropdownShow: P,
|
|
246
251
|
onDropdownHide: F,
|
|
247
|
-
onInputKeydown:
|
|
252
|
+
onInputKeydown: R,
|
|
248
253
|
clearValue: () => {
|
|
249
254
|
let t = "";
|
|
250
255
|
Array.isArray(e.value) ? t = [] : typeof e.value == "object" && e.value !== null && (t = {}), e.value = t, m("reset", t);
|