prlg-ui 1.8.184 → 1.8.186
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/index.d.ts +2 -0
- package/dist/prlg-ui.cjs.js +4 -4
- package/dist/prlg-ui.css +1 -1
- package/dist/prlg-ui.es.js +552 -548
- package/package.json +1 -1
package/dist/prlg-ui.es.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as q, computed as T, resolveComponent as jn, createBlock as W, openBlock as m, resolveDynamicComponent as Fe, normalizeClass as H, withCtx as ie, createCommentVNode as F, createElementBlock as y, renderSlot as ne, Fragment as le, createTextVNode as ve, toDisplayString as K, ref as
|
|
1
|
+
import { defineComponent as q, computed as T, resolveComponent as jn, createBlock as W, openBlock as m, resolveDynamicComponent as Fe, normalizeClass as H, withCtx as ie, createCommentVNode as F, createElementBlock as y, renderSlot as ne, Fragment as le, createTextVNode as ve, toDisplayString as K, ref as D, useTemplateRef as lt, onMounted as ye, createElementVNode as k, createVNode as j, renderList as ce, unref as $, mergeModels as se, useModel as ue, watch as ee, shallowRef as ze, getCurrentScope as Ml, onScopeDispose as Dl, shallowReadonly as Je, toRefs as Tl, useId as ht, onUnmounted as De, Transition as Te, normalizeStyle as oe, nextTick as pe, withModifiers as he, withDirectives as Ce, vModelRadio as Al, vModelText as ut, provide as _e, watchEffect as Un, toRef as tt, useSlots as Wn, inject as Se, isRef as Yn, h as Qt, resolveDirective as Fl, vModelCheckbox as Xn, vModelDynamic as El, toValue as et, vModelSelect as Ll, createStaticVNode as Ol, Teleport as Ne, reactive as Zn, TransitionGroup as zl, vShow as Qn, useCssVars as Hl, createApp as Bl } from "vue";
|
|
2
2
|
import { P as Jn, h as el, i as tl, I as nl, e as mt, C as Tt, A as Gl, a as ll, f as Kl, M as ql, S as Nl, g as jl, b as Ul, c as Wl, E as Yl, B as Xl, d as Zl, Q as Ql, W as $n } from "./QuestionIcon-tK1kUB_h.js";
|
|
3
3
|
import { o as Jl, d as fe } from "./parseFileSize.util-CxVk4CvB.js";
|
|
4
4
|
import { _ as de, C as dt, a as eo } from "./FileIcon-maHE2Nhr.js";
|
|
@@ -65,7 +65,7 @@ const no = {
|
|
|
65
65
|
size: { default: "default" }
|
|
66
66
|
},
|
|
67
67
|
setup(e) {
|
|
68
|
-
const n =
|
|
68
|
+
const n = D(!1), t = lt("menuRef"), l = lt("targetRef"), o = () => {
|
|
69
69
|
n.value = !n.value;
|
|
70
70
|
}, r = (a) => {
|
|
71
71
|
a.command && a.command(), n.value = !1;
|
|
@@ -144,11 +144,11 @@ const no = {
|
|
|
144
144
|
}),
|
|
145
145
|
emits: /* @__PURE__ */ se(["change", "update:modelValue", "update:checked", "update:indeterminate"], ["update:modelValue"]),
|
|
146
146
|
setup(e, { emit: n }) {
|
|
147
|
-
const t = n, l = ue(e, "modelValue"), o =
|
|
147
|
+
const t = n, l = ue(e, "modelValue"), o = D(e.indeterminate);
|
|
148
148
|
e.checked !== void 0 && (e.value !== void 0 && l.value === void 0 ? l.value = e.checked ? [e.value] : [] : e.value === void 0 && (e.checked ? l.value = e.trueValue !== !0 ? e.trueValue : !0 : l.value = e.falseValue !== !1 ? e.falseValue : !1)), ee(
|
|
149
149
|
() => e.checked,
|
|
150
|
-
(
|
|
151
|
-
|
|
150
|
+
(g) => {
|
|
151
|
+
g !== void 0 && (g ? l.value = e.trueValue !== !0 ? e.trueValue : !0 : l.value = e.falseValue !== !1 ? e.falseValue : !1);
|
|
152
152
|
}
|
|
153
153
|
);
|
|
154
154
|
const r = T(() => Math.random().toString(36).substring(2, 9)), a = T(() => o.value), s = T(() => Array.isArray(l.value) || l.value === null && e.value !== void 0 || l.value === void 0 && e.value !== void 0), i = T(() => s.value ? e.value === void 0 || !Array.isArray(l.value) ? !1 : l.value.includes(e.value) : l.value !== void 0 && l.value !== null ? e.trueValue !== !0 || e.falseValue !== !1 ? l.value === e.trueValue : !!l.value : !1), u = T(() => [
|
|
@@ -158,23 +158,23 @@ const no = {
|
|
|
158
158
|
"checkbox--disabled": e.disabled,
|
|
159
159
|
"checkbox--error": e.error
|
|
160
160
|
}
|
|
161
|
-
]), d = (
|
|
161
|
+
]), d = (g) => {
|
|
162
162
|
if (e.disabled) return;
|
|
163
|
-
const
|
|
163
|
+
const f = g.target.checked;
|
|
164
164
|
let h;
|
|
165
165
|
if (s.value) {
|
|
166
166
|
if (e.value === void 0)
|
|
167
167
|
return;
|
|
168
168
|
const b = Array.isArray(l.value) ? [...l.value] : [];
|
|
169
|
-
if (
|
|
169
|
+
if (f)
|
|
170
170
|
b.includes(e.value) || b.push(e.value);
|
|
171
171
|
else {
|
|
172
172
|
const S = b.indexOf(e.value);
|
|
173
173
|
S > -1 && b.splice(S, 1);
|
|
174
174
|
}
|
|
175
175
|
h = b;
|
|
176
|
-
} else e.trueValue !== !0 || e.falseValue !== !1 ? h =
|
|
177
|
-
l.value = h, t("update:modelValue", h), t("change", h,
|
|
176
|
+
} else e.trueValue !== !0 || e.falseValue !== !1 ? h = f ? e.trueValue : e.falseValue : e.value !== void 0 ? h = f ? e.value : null : h = f;
|
|
177
|
+
l.value = h, t("update:modelValue", h), t("change", h, g), t("update:checked", f), o.value && (o.value = !1, t("update:indeterminate", !1));
|
|
178
178
|
};
|
|
179
179
|
return ee(
|
|
180
180
|
l,
|
|
@@ -183,21 +183,21 @@ const no = {
|
|
|
183
183
|
{ immediate: !0 }
|
|
184
184
|
), ee(
|
|
185
185
|
() => e.indeterminate,
|
|
186
|
-
(
|
|
187
|
-
o.value =
|
|
186
|
+
(g) => {
|
|
187
|
+
o.value = g;
|
|
188
188
|
}
|
|
189
|
-
), (
|
|
189
|
+
), (g, v) => (m(), y("label", {
|
|
190
190
|
for: r.value,
|
|
191
191
|
class: H(u.value)
|
|
192
192
|
}, [
|
|
193
193
|
k("input", {
|
|
194
|
-
id:
|
|
194
|
+
id: g.customId ?? r.value,
|
|
195
195
|
type: "checkbox",
|
|
196
|
-
value:
|
|
196
|
+
value: g.value,
|
|
197
197
|
indeterminate: a.value,
|
|
198
198
|
class: "checkbox__input",
|
|
199
|
-
name:
|
|
200
|
-
disabled:
|
|
199
|
+
name: g.name,
|
|
200
|
+
disabled: g.disabled,
|
|
201
201
|
checked: i.value,
|
|
202
202
|
onChange: d
|
|
203
203
|
}, null, 40, so),
|
|
@@ -217,11 +217,11 @@ const no = {
|
|
|
217
217
|
])])) : F("", !0)
|
|
218
218
|
])
|
|
219
219
|
]),
|
|
220
|
-
|
|
221
|
-
ve(K(
|
|
222
|
-
ne(
|
|
220
|
+
g.label || g.$slots.label ? (m(), y("span", go, [
|
|
221
|
+
ve(K(g.label) + " ", 1),
|
|
222
|
+
ne(g.$slots, "label")
|
|
223
223
|
])) : F("", !0),
|
|
224
|
-
|
|
224
|
+
g.error && g.errorText ? (m(), y("span", vo, K(g.errorText), 1)) : F("", !0)
|
|
225
225
|
], 10, ro));
|
|
226
226
|
}
|
|
227
227
|
}), mo = /* @__PURE__ */ q({
|
|
@@ -231,7 +231,7 @@ const no = {
|
|
|
231
231
|
},
|
|
232
232
|
emits: ["updateSort"],
|
|
233
233
|
setup(e, { emit: n }) {
|
|
234
|
-
const t =
|
|
234
|
+
const t = D({
|
|
235
235
|
field: "",
|
|
236
236
|
order: null
|
|
237
237
|
}), l = n, o = () => {
|
|
@@ -360,48 +360,48 @@ function _n(e, n, t) {
|
|
|
360
360
|
reference: l,
|
|
361
361
|
floating: o
|
|
362
362
|
} = e;
|
|
363
|
-
const r = Be(n), a = dn(n), s = un(a), i = We(n), u = r === "y", d = l.x + l.width / 2 - o.width / 2,
|
|
364
|
-
let
|
|
363
|
+
const r = Be(n), a = dn(n), s = un(a), i = We(n), u = r === "y", d = l.x + l.width / 2 - o.width / 2, g = l.y + l.height / 2 - o.height / 2, v = l[s] / 2 - o[s] / 2;
|
|
364
|
+
let f;
|
|
365
365
|
switch (i) {
|
|
366
366
|
case "top":
|
|
367
|
-
|
|
367
|
+
f = {
|
|
368
368
|
x: d,
|
|
369
369
|
y: l.y - o.height
|
|
370
370
|
};
|
|
371
371
|
break;
|
|
372
372
|
case "bottom":
|
|
373
|
-
|
|
373
|
+
f = {
|
|
374
374
|
x: d,
|
|
375
375
|
y: l.y + l.height
|
|
376
376
|
};
|
|
377
377
|
break;
|
|
378
378
|
case "right":
|
|
379
|
-
|
|
379
|
+
f = {
|
|
380
380
|
x: l.x + l.width,
|
|
381
|
-
y:
|
|
381
|
+
y: g
|
|
382
382
|
};
|
|
383
383
|
break;
|
|
384
384
|
case "left":
|
|
385
|
-
|
|
385
|
+
f = {
|
|
386
386
|
x: l.x - o.width,
|
|
387
|
-
y:
|
|
387
|
+
y: g
|
|
388
388
|
};
|
|
389
389
|
break;
|
|
390
390
|
default:
|
|
391
|
-
|
|
391
|
+
f = {
|
|
392
392
|
x: l.x,
|
|
393
393
|
y: l.y
|
|
394
394
|
};
|
|
395
395
|
}
|
|
396
396
|
switch (wt(n)) {
|
|
397
397
|
case "start":
|
|
398
|
-
|
|
398
|
+
f[a] -= v * (t && u ? -1 : 1);
|
|
399
399
|
break;
|
|
400
400
|
case "end":
|
|
401
|
-
|
|
401
|
+
f[a] += v * (t && u ? -1 : 1);
|
|
402
402
|
break;
|
|
403
403
|
}
|
|
404
|
-
return
|
|
404
|
+
return f;
|
|
405
405
|
}
|
|
406
406
|
const Vo = async (e, n, t) => {
|
|
407
407
|
const {
|
|
@@ -416,24 +416,24 @@ const Vo = async (e, n, t) => {
|
|
|
416
416
|
strategy: o
|
|
417
417
|
}), {
|
|
418
418
|
x: d,
|
|
419
|
-
y:
|
|
420
|
-
} = _n(u, l, i), v = l,
|
|
419
|
+
y: g
|
|
420
|
+
} = _n(u, l, i), v = l, f = {}, h = 0;
|
|
421
421
|
for (let b = 0; b < s.length; b++) {
|
|
422
422
|
const {
|
|
423
423
|
name: S,
|
|
424
|
-
fn:
|
|
424
|
+
fn: M
|
|
425
425
|
} = s[b], {
|
|
426
426
|
x: _,
|
|
427
427
|
y: P,
|
|
428
428
|
data: O,
|
|
429
429
|
reset: I
|
|
430
|
-
} = await
|
|
430
|
+
} = await M({
|
|
431
431
|
x: d,
|
|
432
|
-
y:
|
|
432
|
+
y: g,
|
|
433
433
|
initialPlacement: l,
|
|
434
434
|
placement: v,
|
|
435
435
|
strategy: o,
|
|
436
|
-
middlewareData:
|
|
436
|
+
middlewareData: f,
|
|
437
437
|
rects: u,
|
|
438
438
|
platform: a,
|
|
439
439
|
elements: {
|
|
@@ -441,10 +441,10 @@ const Vo = async (e, n, t) => {
|
|
|
441
441
|
floating: n
|
|
442
442
|
}
|
|
443
443
|
});
|
|
444
|
-
d = _ ?? d,
|
|
445
|
-
...
|
|
444
|
+
d = _ ?? d, g = P ?? g, f = {
|
|
445
|
+
...f,
|
|
446
446
|
[S]: {
|
|
447
|
-
...
|
|
447
|
+
...f[S],
|
|
448
448
|
...O
|
|
449
449
|
}
|
|
450
450
|
}, I && h <= 50 && (h++, typeof I == "object" && (I.placement && (v = I.placement), I.rects && (u = I.rects === !0 ? await a.getElementRects({
|
|
@@ -453,15 +453,15 @@ const Vo = async (e, n, t) => {
|
|
|
453
453
|
strategy: o
|
|
454
454
|
}) : I.rects), {
|
|
455
455
|
x: d,
|
|
456
|
-
y:
|
|
456
|
+
y: g
|
|
457
457
|
} = _n(u, v, i)), b = -1);
|
|
458
458
|
}
|
|
459
459
|
return {
|
|
460
460
|
x: d,
|
|
461
|
-
y:
|
|
461
|
+
y: g,
|
|
462
462
|
placement: v,
|
|
463
463
|
strategy: o,
|
|
464
|
-
middlewareData:
|
|
464
|
+
middlewareData: f
|
|
465
465
|
};
|
|
466
466
|
};
|
|
467
467
|
async function It(e, n) {
|
|
@@ -477,15 +477,15 @@ async function It(e, n) {
|
|
|
477
477
|
} = e, {
|
|
478
478
|
boundary: u = "clippingAncestors",
|
|
479
479
|
rootBoundary: d = "viewport",
|
|
480
|
-
elementContext:
|
|
480
|
+
elementContext: g = "floating",
|
|
481
481
|
altBoundary: v = !1,
|
|
482
|
-
padding:
|
|
483
|
-
} = ct(n, e), h = al(
|
|
482
|
+
padding: f = 0
|
|
483
|
+
} = ct(n, e), h = al(f), S = s[v ? g === "floating" ? "reference" : "floating" : g], M = Pt(await r.getClippingRect({
|
|
484
484
|
element: (t = await (r.isElement == null ? void 0 : r.isElement(S))) == null || t ? S : S.contextElement || await (r.getDocumentElement == null ? void 0 : r.getDocumentElement(s.floating)),
|
|
485
485
|
boundary: u,
|
|
486
486
|
rootBoundary: d,
|
|
487
487
|
strategy: i
|
|
488
|
-
})), _ =
|
|
488
|
+
})), _ = g === "floating" ? {
|
|
489
489
|
x: l,
|
|
490
490
|
y: o,
|
|
491
491
|
width: a.floating.width,
|
|
@@ -503,10 +503,10 @@ async function It(e, n) {
|
|
|
503
503
|
strategy: i
|
|
504
504
|
}) : _);
|
|
505
505
|
return {
|
|
506
|
-
top: (
|
|
507
|
-
bottom: (I.bottom -
|
|
508
|
-
left: (
|
|
509
|
-
right: (I.right -
|
|
506
|
+
top: (M.top - I.top + h.top) / O.y,
|
|
507
|
+
bottom: (I.bottom - M.bottom + h.bottom) / O.y,
|
|
508
|
+
left: (M.left - I.left + h.left) / O.x,
|
|
509
|
+
right: (I.right - M.right + h.right) / O.x
|
|
510
510
|
};
|
|
511
511
|
}
|
|
512
512
|
const Po = (e) => ({
|
|
@@ -527,17 +527,17 @@ const Po = (e) => ({
|
|
|
527
527
|
} = ct(e, n) || {};
|
|
528
528
|
if (u == null)
|
|
529
529
|
return {};
|
|
530
|
-
const
|
|
530
|
+
const g = al(d), v = {
|
|
531
531
|
x: t,
|
|
532
532
|
y: l
|
|
533
|
-
},
|
|
533
|
+
}, f = dn(o), h = un(f), b = await a.getDimensions(u), S = f === "y", M = S ? "top" : "left", _ = S ? "bottom" : "right", P = S ? "clientHeight" : "clientWidth", O = r.reference[h] + r.reference[f] - v[f] - r.floating[h], I = v[f] - r.reference[f], C = await (a.getOffsetParent == null ? void 0 : a.getOffsetParent(u));
|
|
534
534
|
let c = C ? C[P] : 0;
|
|
535
535
|
(!c || !await (a.isElement == null ? void 0 : a.isElement(C))) && (c = s.floating[P] || r.floating[h]);
|
|
536
|
-
const p = O / 2 - I / 2, w = c / 2 - b[h] / 2 - 1, x = st(
|
|
536
|
+
const p = O / 2 - I / 2, w = c / 2 - b[h] / 2 - 1, x = st(g[M], w), A = st(g[_], w), z = x, N = c - b[h] - A, B = c / 2 - b[h] / 2 + p, X = Jt(z, B, N), R = !i.arrow && wt(o) != null && B !== X && r.reference[h] / 2 - (B < z ? x : A) - b[h] / 2 < 0, G = R ? B < z ? B - z : B - N : 0;
|
|
537
537
|
return {
|
|
538
|
-
[
|
|
538
|
+
[f]: v[f] + G,
|
|
539
539
|
data: {
|
|
540
|
-
[
|
|
540
|
+
[f]: X,
|
|
541
541
|
centerOffset: B - X - G,
|
|
542
542
|
...R && {
|
|
543
543
|
alignmentOffset: G
|
|
@@ -561,20 +561,20 @@ const Po = (e) => ({
|
|
|
561
561
|
elements: u
|
|
562
562
|
} = n, {
|
|
563
563
|
mainAxis: d = !0,
|
|
564
|
-
crossAxis:
|
|
564
|
+
crossAxis: g = !0,
|
|
565
565
|
fallbackPlacements: v,
|
|
566
|
-
fallbackStrategy:
|
|
566
|
+
fallbackStrategy: f = "bestFit",
|
|
567
567
|
fallbackAxisSideDirection: h = "none",
|
|
568
568
|
flipAlignment: b = !0,
|
|
569
569
|
...S
|
|
570
570
|
} = ct(e, n);
|
|
571
571
|
if ((t = r.arrow) != null && t.alignmentOffset)
|
|
572
572
|
return {};
|
|
573
|
-
const
|
|
573
|
+
const M = We(o), _ = Be(s), P = We(s) === s, O = await (i.isRTL == null ? void 0 : i.isRTL(u.floating)), I = v || (P || !b ? [Vt(s)] : Co(s)), C = h !== "none";
|
|
574
574
|
!v && C && I.push(..._o(s, b, h, O));
|
|
575
575
|
const c = [s, ...I], p = await It(n, S), w = [];
|
|
576
576
|
let x = ((l = r.flip) == null ? void 0 : l.overflows) || [];
|
|
577
|
-
if (d && w.push(p[
|
|
577
|
+
if (d && w.push(p[M]), g) {
|
|
578
578
|
const B = So(o, a, O);
|
|
579
579
|
w.push(p[B[0]], p[B[1]]);
|
|
580
580
|
}
|
|
@@ -584,7 +584,7 @@ const Po = (e) => ({
|
|
|
584
584
|
}], !w.every((B) => B <= 0)) {
|
|
585
585
|
var A, z;
|
|
586
586
|
const B = (((A = r.flip) == null ? void 0 : A.index) || 0) + 1, X = c[B];
|
|
587
|
-
if (X && (!(
|
|
587
|
+
if (X && (!(g === "alignment" ? _ !== Be(X) : !1) || // We leave the current main axis only if every placement on that axis
|
|
588
588
|
// overflows the main axis.
|
|
589
589
|
x.every((L) => Be(L.placement) === _ ? L.overflows[0] > 0 : !0)))
|
|
590
590
|
return {
|
|
@@ -598,7 +598,7 @@ const Po = (e) => ({
|
|
|
598
598
|
};
|
|
599
599
|
let R = (z = x.filter((G) => G.overflows[0] <= 0).sort((G, L) => G.overflows[1] - L.overflows[1])[0]) == null ? void 0 : z.placement;
|
|
600
600
|
if (!R)
|
|
601
|
-
switch (
|
|
601
|
+
switch (f) {
|
|
602
602
|
case "bestFit": {
|
|
603
603
|
var N;
|
|
604
604
|
const G = (N = x.filter((L) => {
|
|
@@ -686,26 +686,26 @@ async function To(e, n) {
|
|
|
686
686
|
placement: t,
|
|
687
687
|
platform: l,
|
|
688
688
|
elements: o
|
|
689
|
-
} = e, r = await (l.isRTL == null ? void 0 : l.isRTL(o.floating)), a = We(t), s = wt(t), i = Be(t) === "y", u = Do.has(a) ? -1 : 1, d = r && i ? -1 : 1,
|
|
689
|
+
} = e, r = await (l.isRTL == null ? void 0 : l.isRTL(o.floating)), a = We(t), s = wt(t), i = Be(t) === "y", u = Do.has(a) ? -1 : 1, d = r && i ? -1 : 1, g = ct(n, e);
|
|
690
690
|
let {
|
|
691
691
|
mainAxis: v,
|
|
692
|
-
crossAxis:
|
|
692
|
+
crossAxis: f,
|
|
693
693
|
alignmentAxis: h
|
|
694
|
-
} = typeof
|
|
695
|
-
mainAxis:
|
|
694
|
+
} = typeof g == "number" ? {
|
|
695
|
+
mainAxis: g,
|
|
696
696
|
crossAxis: 0,
|
|
697
697
|
alignmentAxis: null
|
|
698
698
|
} : {
|
|
699
|
-
mainAxis:
|
|
700
|
-
crossAxis:
|
|
701
|
-
alignmentAxis:
|
|
699
|
+
mainAxis: g.mainAxis || 0,
|
|
700
|
+
crossAxis: g.crossAxis || 0,
|
|
701
|
+
alignmentAxis: g.alignmentAxis
|
|
702
702
|
};
|
|
703
|
-
return s && typeof h == "number" && (
|
|
704
|
-
x:
|
|
703
|
+
return s && typeof h == "number" && (f = s === "end" ? h * -1 : h), i ? {
|
|
704
|
+
x: f * d,
|
|
705
705
|
y: v * u
|
|
706
706
|
} : {
|
|
707
707
|
x: v * u,
|
|
708
|
-
y:
|
|
708
|
+
y: f * d
|
|
709
709
|
};
|
|
710
710
|
}
|
|
711
711
|
const Ao = function(e) {
|
|
@@ -745,11 +745,11 @@ const Ao = function(e) {
|
|
|
745
745
|
limiter: s = {
|
|
746
746
|
fn: (S) => {
|
|
747
747
|
let {
|
|
748
|
-
x:
|
|
748
|
+
x: M,
|
|
749
749
|
y: _
|
|
750
750
|
} = S;
|
|
751
751
|
return {
|
|
752
|
-
x:
|
|
752
|
+
x: M,
|
|
753
753
|
y: _
|
|
754
754
|
};
|
|
755
755
|
}
|
|
@@ -758,20 +758,20 @@ const Ao = function(e) {
|
|
|
758
758
|
} = ct(e, n), u = {
|
|
759
759
|
x: t,
|
|
760
760
|
y: l
|
|
761
|
-
}, d = await It(n, i),
|
|
762
|
-
let
|
|
761
|
+
}, d = await It(n, i), g = Be(We(o)), v = ol(g);
|
|
762
|
+
let f = u[v], h = u[g];
|
|
763
763
|
if (r) {
|
|
764
|
-
const S = v === "y" ? "top" : "left",
|
|
765
|
-
|
|
764
|
+
const S = v === "y" ? "top" : "left", M = v === "y" ? "bottom" : "right", _ = f + d[S], P = f - d[M];
|
|
765
|
+
f = Jt(_, f, P);
|
|
766
766
|
}
|
|
767
767
|
if (a) {
|
|
768
|
-
const S =
|
|
768
|
+
const S = g === "y" ? "top" : "left", M = g === "y" ? "bottom" : "right", _ = h + d[S], P = h - d[M];
|
|
769
769
|
h = Jt(_, h, P);
|
|
770
770
|
}
|
|
771
771
|
const b = s.fn({
|
|
772
772
|
...n,
|
|
773
|
-
[v]:
|
|
774
|
-
[
|
|
773
|
+
[v]: f,
|
|
774
|
+
[g]: h
|
|
775
775
|
});
|
|
776
776
|
return {
|
|
777
777
|
...b,
|
|
@@ -780,7 +780,7 @@ const Ao = function(e) {
|
|
|
780
780
|
y: b.y - l,
|
|
781
781
|
enabled: {
|
|
782
782
|
[v]: r,
|
|
783
|
-
[
|
|
783
|
+
[g]: a
|
|
784
784
|
}
|
|
785
785
|
}
|
|
786
786
|
};
|
|
@@ -946,18 +946,18 @@ function Ye(e, n, t, l) {
|
|
|
946
946
|
let a = Ae(1);
|
|
947
947
|
n && (l ? Ie(l) && (a = at(l)) : a = at(e));
|
|
948
948
|
const s = jo(r, t, l) ? il(r) : Ae(0);
|
|
949
|
-
let i = (o.left + s.x) / a.x, u = (o.top + s.y) / a.y, d = o.width / a.x,
|
|
949
|
+
let i = (o.left + s.x) / a.x, u = (o.top + s.y) / a.y, d = o.width / a.x, g = o.height / a.y;
|
|
950
950
|
if (r) {
|
|
951
|
-
const v = $e(r),
|
|
951
|
+
const v = $e(r), f = l && Ie(l) ? $e(l) : l;
|
|
952
952
|
let h = v, b = tn(h);
|
|
953
|
-
for (; b && l &&
|
|
954
|
-
const S = at(b),
|
|
955
|
-
i *= S.x, u *= S.y, d *= S.x,
|
|
953
|
+
for (; b && l && f !== h; ) {
|
|
954
|
+
const S = at(b), M = b.getBoundingClientRect(), _ = Me(b), P = M.left + (b.clientLeft + parseFloat(_.paddingLeft)) * S.x, O = M.top + (b.clientTop + parseFloat(_.paddingTop)) * S.y;
|
|
955
|
+
i *= S.x, u *= S.y, d *= S.x, g *= S.y, i += P, u += O, h = $e(b), b = tn(h);
|
|
956
956
|
}
|
|
957
957
|
}
|
|
958
958
|
return Pt({
|
|
959
959
|
width: d,
|
|
960
|
-
height:
|
|
960
|
+
height: g,
|
|
961
961
|
x: i,
|
|
962
962
|
y: u
|
|
963
963
|
});
|
|
@@ -987,12 +987,12 @@ function Uo(e) {
|
|
|
987
987
|
scrollLeft: 0,
|
|
988
988
|
scrollTop: 0
|
|
989
989
|
}, u = Ae(1);
|
|
990
|
-
const d = Ae(0),
|
|
991
|
-
if ((
|
|
992
|
-
const
|
|
993
|
-
u = at(l), d.x =
|
|
990
|
+
const d = Ae(0), g = Ee(l);
|
|
991
|
+
if ((g || !g && !r) && ((Ze(l) !== "body" || bt(a)) && (i = Lt(l)), Ee(l))) {
|
|
992
|
+
const f = Ye(l);
|
|
993
|
+
u = at(l), d.x = f.x + l.clientLeft, d.y = f.y + l.clientTop;
|
|
994
994
|
}
|
|
995
|
-
const v = a && !
|
|
995
|
+
const v = a && !g && !r ? ul(a, i) : Ae(0);
|
|
996
996
|
return {
|
|
997
997
|
width: t.width * u.x,
|
|
998
998
|
height: t.height * u.y,
|
|
@@ -1025,7 +1025,7 @@ function Xo(e, n) {
|
|
|
1025
1025
|
}
|
|
1026
1026
|
const u = Ot(l);
|
|
1027
1027
|
if (u <= 0) {
|
|
1028
|
-
const d = l.ownerDocument,
|
|
1028
|
+
const d = l.ownerDocument, g = d.body, v = getComputedStyle(g), f = d.compatMode === "CSS1Compat" && parseFloat(v.marginLeft) + parseFloat(v.marginRight) || 0, h = Math.abs(l.clientWidth - g.clientWidth - f);
|
|
1029
1029
|
h <= In && (r -= h);
|
|
1030
1030
|
} else u <= In && (r += u);
|
|
1031
1031
|
return {
|
|
@@ -1089,8 +1089,8 @@ function ea(e) {
|
|
|
1089
1089
|
strategy: o
|
|
1090
1090
|
} = e;
|
|
1091
1091
|
const a = [...t === "clippingAncestors" ? Et(n) ? [] : Jo(n, this._c) : [].concat(t), l], s = a[0], i = a.reduce((u, d) => {
|
|
1092
|
-
const
|
|
1093
|
-
return u.top = je(
|
|
1092
|
+
const g = Mn(n, d, o);
|
|
1093
|
+
return u.top = je(g.top, u.top), u.right = st(g.right, u.right), u.bottom = st(g.bottom, u.bottom), u.left = je(g.left, u.left), u;
|
|
1094
1094
|
}, Mn(n, s, o));
|
|
1095
1095
|
return {
|
|
1096
1096
|
width: i.right - i.left,
|
|
@@ -1121,13 +1121,13 @@ function na(e, n, t) {
|
|
|
1121
1121
|
}
|
|
1122
1122
|
if (l || !l && !r)
|
|
1123
1123
|
if ((Ze(n) !== "body" || bt(o)) && (s = Lt(n)), l) {
|
|
1124
|
-
const
|
|
1125
|
-
i.x =
|
|
1124
|
+
const f = Ye(n, !0, r, n);
|
|
1125
|
+
i.x = f.x + n.clientLeft, i.y = f.y + n.clientTop;
|
|
1126
1126
|
} else o && u();
|
|
1127
1127
|
r && !l && o && u();
|
|
1128
|
-
const d = o && !l && !r ? ul(o, s) : Ae(0),
|
|
1128
|
+
const d = o && !l && !r ? ul(o, s) : Ae(0), g = a.left + s.scrollLeft - i.x - d.x, v = a.top + s.scrollTop - i.y - d.y;
|
|
1129
1129
|
return {
|
|
1130
|
-
x:
|
|
1130
|
+
x: g,
|
|
1131
1131
|
y: v,
|
|
1132
1132
|
width: a.width,
|
|
1133
1133
|
height: a.height
|
|
@@ -1203,14 +1203,14 @@ function ra(e, n) {
|
|
|
1203
1203
|
s === void 0 && (s = !1), i === void 0 && (i = 1), r();
|
|
1204
1204
|
const u = e.getBoundingClientRect(), {
|
|
1205
1205
|
left: d,
|
|
1206
|
-
top:
|
|
1206
|
+
top: g,
|
|
1207
1207
|
width: v,
|
|
1208
|
-
height:
|
|
1208
|
+
height: f
|
|
1209
1209
|
} = u;
|
|
1210
|
-
if (s || n(), !v || !
|
|
1210
|
+
if (s || n(), !v || !f)
|
|
1211
1211
|
return;
|
|
1212
|
-
const h = Ct(
|
|
1213
|
-
rootMargin: -h + "px " + -b + "px " + -S + "px " + -
|
|
1212
|
+
const h = Ct(g), b = Ct(o.clientWidth - (d + v)), S = Ct(o.clientHeight - (g + f)), M = Ct(d), P = {
|
|
1213
|
+
rootMargin: -h + "px " + -b + "px " + -S + "px " + -M + "px",
|
|
1214
1214
|
threshold: je(0, st(1, i)) || 1
|
|
1215
1215
|
};
|
|
1216
1216
|
let O = !0;
|
|
@@ -1247,31 +1247,31 @@ function sa(e, n, t, l) {
|
|
|
1247
1247
|
layoutShift: s = typeof IntersectionObserver == "function",
|
|
1248
1248
|
animationFrame: i = !1
|
|
1249
1249
|
} = l, u = vn(e), d = o || r ? [...u ? pt(u) : [], ...pt(n)] : [];
|
|
1250
|
-
d.forEach((
|
|
1251
|
-
o &&
|
|
1250
|
+
d.forEach((M) => {
|
|
1251
|
+
o && M.addEventListener("scroll", t, {
|
|
1252
1252
|
passive: !0
|
|
1253
|
-
}), r &&
|
|
1253
|
+
}), r && M.addEventListener("resize", t);
|
|
1254
1254
|
});
|
|
1255
|
-
const
|
|
1256
|
-
let v = -1,
|
|
1257
|
-
a && (
|
|
1258
|
-
let [_] =
|
|
1259
|
-
_ && _.target === u &&
|
|
1255
|
+
const g = u && s ? ra(u, t) : null;
|
|
1256
|
+
let v = -1, f = null;
|
|
1257
|
+
a && (f = new ResizeObserver((M) => {
|
|
1258
|
+
let [_] = M;
|
|
1259
|
+
_ && _.target === u && f && (f.unobserve(n), cancelAnimationFrame(v), v = requestAnimationFrame(() => {
|
|
1260
1260
|
var P;
|
|
1261
|
-
(P =
|
|
1261
|
+
(P = f) == null || P.observe(n);
|
|
1262
1262
|
})), t();
|
|
1263
|
-
}), u && !i &&
|
|
1263
|
+
}), u && !i && f.observe(u), f.observe(n));
|
|
1264
1264
|
let h, b = i ? Ye(e) : null;
|
|
1265
1265
|
i && S();
|
|
1266
1266
|
function S() {
|
|
1267
|
-
const
|
|
1268
|
-
b && !fl(b,
|
|
1267
|
+
const M = Ye(e);
|
|
1268
|
+
b && !fl(b, M) && t(), b = M, h = requestAnimationFrame(S);
|
|
1269
1269
|
}
|
|
1270
1270
|
return t(), () => {
|
|
1271
|
-
var
|
|
1271
|
+
var M;
|
|
1272
1272
|
d.forEach((_) => {
|
|
1273
1273
|
o && _.removeEventListener("scroll", t), r && _.removeEventListener("resize", t);
|
|
1274
|
-
}),
|
|
1274
|
+
}), g?.(), (M = f) == null || M.disconnect(), f = null, i && cancelAnimationFrame(h);
|
|
1275
1275
|
};
|
|
1276
1276
|
}
|
|
1277
1277
|
const Mt = Ao, mn = Fo, gl = Io, Tn = Mo, vl = Po, pn = (e, n, t) => {
|
|
@@ -1334,15 +1334,15 @@ function Fn(e, n, t) {
|
|
|
1334
1334
|
}), i = T(() => {
|
|
1335
1335
|
var c;
|
|
1336
1336
|
return (c = nt(t.transform)) != null ? c : !0;
|
|
1337
|
-
}), u = T(() => nn(e.value)), d = T(() => nn(n.value)),
|
|
1337
|
+
}), u = T(() => nn(e.value)), d = T(() => nn(n.value)), g = D(0), v = D(0), f = D(s.value), h = D(a.value), b = ze({}), S = D(!1), M = T(() => {
|
|
1338
1338
|
const c = {
|
|
1339
|
-
position:
|
|
1339
|
+
position: f.value,
|
|
1340
1340
|
left: "0",
|
|
1341
1341
|
top: "0"
|
|
1342
1342
|
};
|
|
1343
1343
|
if (!d.value)
|
|
1344
1344
|
return c;
|
|
1345
|
-
const p = An(d.value,
|
|
1345
|
+
const p = An(d.value, g.value), w = An(d.value, v.value);
|
|
1346
1346
|
return i.value ? {
|
|
1347
1347
|
...c,
|
|
1348
1348
|
transform: "translate(" + p + "px, " + w + "px)",
|
|
@@ -1350,7 +1350,7 @@ function Fn(e, n, t) {
|
|
|
1350
1350
|
willChange: "transform"
|
|
1351
1351
|
}
|
|
1352
1352
|
} : {
|
|
1353
|
-
position:
|
|
1353
|
+
position: f.value,
|
|
1354
1354
|
left: p + "px",
|
|
1355
1355
|
top: w + "px"
|
|
1356
1356
|
};
|
|
@@ -1365,7 +1365,7 @@ function Fn(e, n, t) {
|
|
|
1365
1365
|
placement: a.value,
|
|
1366
1366
|
strategy: s.value
|
|
1367
1367
|
}).then((p) => {
|
|
1368
|
-
|
|
1368
|
+
g.value = p.x, v.value = p.y, f.value = p.strategy, h.value = p.placement, b.value = p.middlewareData, S.value = c !== !1;
|
|
1369
1369
|
});
|
|
1370
1370
|
}
|
|
1371
1371
|
function O() {
|
|
@@ -1391,13 +1391,13 @@ function Fn(e, n, t) {
|
|
|
1391
1391
|
}), ee(o, C, {
|
|
1392
1392
|
flush: "sync"
|
|
1393
1393
|
}), Ml() && Dl(O), {
|
|
1394
|
-
x: Je(
|
|
1394
|
+
x: Je(g),
|
|
1395
1395
|
y: Je(v),
|
|
1396
|
-
strategy: Je(
|
|
1396
|
+
strategy: Je(f),
|
|
1397
1397
|
placement: Je(h),
|
|
1398
1398
|
middlewareData: Je(b),
|
|
1399
1399
|
isPositioned: Je(S),
|
|
1400
|
-
floatingStyles:
|
|
1400
|
+
floatingStyles: M,
|
|
1401
1401
|
update: P
|
|
1402
1402
|
};
|
|
1403
1403
|
}
|
|
@@ -1436,14 +1436,14 @@ const da = {
|
|
|
1436
1436
|
},
|
|
1437
1437
|
emits: ["update:modelValue"],
|
|
1438
1438
|
setup(e, { expose: n, emit: t }) {
|
|
1439
|
-
const l = e, { placement: o, offset: r, arrowVisible: a, closeMode: s, modelValue: i } = Tl(l), u = t, d = lt("reference"),
|
|
1439
|
+
const l = e, { placement: o, offset: r, arrowVisible: a, closeMode: s, modelValue: i } = Tl(l), u = t, d = lt("reference"), g = lt("floating"), v = lt("arrow-block"), f = lt("second-screen"), h = T(() => "23px"), b = T(() => r ? typeof r.value == "number" ? r.value + Number(h.value.split("px")[0]) : {
|
|
1440
1440
|
mainAxis: r.value?.mainAxis ? r.value?.mainAxis + Number(h.value.split("px")[0]) / 2 : Number(h.value.split("px")[0]) / 2,
|
|
1441
1441
|
crossAxis: r.value?.crossAxis ? o.value?.includes("start") ? r.value?.crossAxis - Number(h.value.split("px")[0]) : o.value?.includes("end") ? r.value?.crossAxis + Number(h.value.split("px")[0]) : r.value?.crossAxis : o.value?.includes("start") ? -Number(h.value.split("px")[0]) : o.value?.includes("end") ? Number(h.value.split("px")[0]) : void 0,
|
|
1442
1442
|
alignmentAxis: r.value?.alignmentAxis
|
|
1443
1443
|
} : {
|
|
1444
1444
|
mainAxis: Number(h.value.split("px")[0]) / 2,
|
|
1445
1445
|
crossAxis: o.value?.includes("start") ? -Number(h.value.split("px")[0]) : o.value?.includes("end") ? Number(h.value.split("px")[0]) : void 0
|
|
1446
|
-
}), S =
|
|
1446
|
+
}), S = D([
|
|
1447
1447
|
Tn(),
|
|
1448
1448
|
Mt(b.value),
|
|
1449
1449
|
ua({ element: v }),
|
|
@@ -1452,22 +1452,22 @@ const da = {
|
|
|
1452
1452
|
mainAxis: o.value.includes("top") || o.value.includes("bottom")
|
|
1453
1453
|
})
|
|
1454
1454
|
]), {
|
|
1455
|
-
floatingStyles:
|
|
1455
|
+
floatingStyles: M,
|
|
1456
1456
|
middlewareData: _,
|
|
1457
1457
|
update: P,
|
|
1458
1458
|
placement: O
|
|
1459
|
-
} = Fn(d,
|
|
1459
|
+
} = Fn(d, g, {
|
|
1460
1460
|
placement: o.value,
|
|
1461
1461
|
middleware: S
|
|
1462
|
-
}), I =
|
|
1462
|
+
}), I = D("left-start"), { floatingStyles: C, update: c } = Fn(g, f, {
|
|
1463
1463
|
placement: I,
|
|
1464
1464
|
middleware: [Tn(), Mt(8)]
|
|
1465
|
-
}), p = ht(), w =
|
|
1465
|
+
}), p = ht(), w = D(!1), x = D(!1), A = D(!1), { lockScroll: z, unlockScroll: N } = yt(), B = D(null), X = D(null), R = () => {
|
|
1466
1466
|
P(), x.value && c();
|
|
1467
1467
|
}, G = T(() => i && i.value !== void 0), L = T({
|
|
1468
1468
|
get: () => G.value ? i?.value : w.value,
|
|
1469
|
-
set: (
|
|
1470
|
-
G.value ? u("update:modelValue",
|
|
1469
|
+
set: (re) => {
|
|
1470
|
+
G.value ? u("update:modelValue", re) : w.value = re;
|
|
1471
1471
|
}
|
|
1472
1472
|
}), J = () => {
|
|
1473
1473
|
L.value = !0;
|
|
@@ -1477,15 +1477,15 @@ const da = {
|
|
|
1477
1477
|
L.value = !L.value;
|
|
1478
1478
|
}, U = () => {
|
|
1479
1479
|
G.value ? L.value ? V() : J() : E();
|
|
1480
|
-
}, te = async (
|
|
1481
|
-
|
|
1480
|
+
}, te = async (re) => {
|
|
1481
|
+
re && re.stopPropagation(), g.value && (x.value = !0);
|
|
1482
1482
|
}, Y = () => {
|
|
1483
1483
|
x.value = !1;
|
|
1484
|
-
},
|
|
1484
|
+
}, ae = (re) => {
|
|
1485
1485
|
if (s.value === "button-only") return;
|
|
1486
|
-
const we =
|
|
1487
|
-
if (!(
|
|
1488
|
-
if (
|
|
1486
|
+
const we = re.composedPath();
|
|
1487
|
+
if (!(f.value && we.includes(f.value))) {
|
|
1488
|
+
if (g.value && we.includes(g.value) || d.value && we.includes(d.value)) {
|
|
1489
1489
|
setTimeout(() => {
|
|
1490
1490
|
x.value && Y();
|
|
1491
1491
|
}, 0);
|
|
@@ -1495,31 +1495,31 @@ const da = {
|
|
|
1495
1495
|
}
|
|
1496
1496
|
}, He = T(() => {
|
|
1497
1497
|
if (!_.value.arrow) return {};
|
|
1498
|
-
const { x:
|
|
1498
|
+
const { x: re, y: we } = _.value.arrow;
|
|
1499
1499
|
switch (O.value) {
|
|
1500
1500
|
case "top":
|
|
1501
1501
|
return {
|
|
1502
|
-
left:
|
|
1502
|
+
left: re ? `${re}px` : "-9px",
|
|
1503
1503
|
bottom: we ? `${we}px` : "-9px"
|
|
1504
1504
|
};
|
|
1505
1505
|
case "bottom":
|
|
1506
1506
|
default:
|
|
1507
1507
|
return {
|
|
1508
|
-
left:
|
|
1508
|
+
left: re ? `${re}px` : "-9px",
|
|
1509
1509
|
top: we ? `${we}px` : "-9px"
|
|
1510
1510
|
};
|
|
1511
1511
|
}
|
|
1512
1512
|
});
|
|
1513
|
-
return ee(_, (
|
|
1514
|
-
G.value || (L.value =
|
|
1513
|
+
return ee(_, (re) => {
|
|
1514
|
+
G.value || (L.value = re.hide?.referenceHidden === !1);
|
|
1515
1515
|
}), ee(
|
|
1516
1516
|
L,
|
|
1517
|
-
async (
|
|
1518
|
-
|
|
1517
|
+
async (re) => {
|
|
1518
|
+
re || (Y(), A.value = !1), re && s.value === "button-only" ? (z(), setTimeout(() => {
|
|
1519
1519
|
R(), A.value = !0;
|
|
1520
|
-
}, 0)) : !
|
|
1520
|
+
}, 0)) : !re && s.value === "button-only" ? (N(), setTimeout(() => {
|
|
1521
1521
|
R();
|
|
1522
|
-
}, 0)) :
|
|
1522
|
+
}, 0)) : re && setTimeout(() => {
|
|
1523
1523
|
R(), A.value = !0;
|
|
1524
1524
|
}, 0);
|
|
1525
1525
|
},
|
|
@@ -1531,10 +1531,10 @@ const da = {
|
|
|
1531
1531
|
},
|
|
1532
1532
|
{ deep: !0 }
|
|
1533
1533
|
), ye(() => {
|
|
1534
|
-
document.addEventListener("click",
|
|
1535
|
-
let
|
|
1534
|
+
document.addEventListener("click", ae);
|
|
1535
|
+
let re = null, we = null;
|
|
1536
1536
|
const St = () => {
|
|
1537
|
-
|
|
1537
|
+
re && clearTimeout(re), re = setTimeout(R, 16);
|
|
1538
1538
|
}, Il = () => {
|
|
1539
1539
|
we && clearTimeout(we), we = setTimeout(R, 100);
|
|
1540
1540
|
};
|
|
@@ -1558,7 +1558,7 @@ const da = {
|
|
|
1558
1558
|
attributeFilter: ["style", "class"]
|
|
1559
1559
|
});
|
|
1560
1560
|
}), De(() => {
|
|
1561
|
-
document.removeEventListener("click",
|
|
1561
|
+
document.removeEventListener("click", ae), window.removeEventListener("resize", R), window.removeEventListener("scroll", R), window.removeEventListener("orientationchange", R), B.value && B.value.disconnect(), X.value && X.value.disconnect(), s.value === "button-only" && L.value && N();
|
|
1562
1562
|
}), n({
|
|
1563
1563
|
open: J,
|
|
1564
1564
|
close: V,
|
|
@@ -1569,7 +1569,7 @@ const da = {
|
|
|
1569
1569
|
},
|
|
1570
1570
|
isOpen: L,
|
|
1571
1571
|
isSecondScreenOpen: x
|
|
1572
|
-
}), (
|
|
1572
|
+
}), (re, we) => (m(), y("div", {
|
|
1573
1573
|
class: H(["popover", { "popover--with-arrow": $(a) }])
|
|
1574
1574
|
}, [
|
|
1575
1575
|
k("div", {
|
|
@@ -1577,7 +1577,7 @@ const da = {
|
|
|
1577
1577
|
ref: "reference",
|
|
1578
1578
|
onClick: U
|
|
1579
1579
|
}, [
|
|
1580
|
-
ne(
|
|
1580
|
+
ne(re.$slots, "trigger", {}, void 0, !0)
|
|
1581
1581
|
], 2),
|
|
1582
1582
|
k("div", null, [
|
|
1583
1583
|
j(Te, { name: "fade" }, {
|
|
@@ -1595,17 +1595,17 @@ const da = {
|
|
|
1595
1595
|
{ "popover__wrapper--no-style": e.withoutStyle },
|
|
1596
1596
|
{ "popover__wrapper--positioning": !A.value }
|
|
1597
1597
|
]]),
|
|
1598
|
-
style:
|
|
1598
|
+
style: oe({ ...$(M) }),
|
|
1599
1599
|
ref: "floating"
|
|
1600
1600
|
}, [
|
|
1601
1601
|
k("div", ca, [
|
|
1602
1602
|
$(a) ? (m(), y("div", fa, [
|
|
1603
|
-
ne(
|
|
1603
|
+
ne(re.$slots, "default", {
|
|
1604
1604
|
openSecondScreen: te,
|
|
1605
1605
|
closeSecondScreen: Y,
|
|
1606
1606
|
close: V
|
|
1607
1607
|
}, void 0, !0)
|
|
1608
|
-
])) : ne(
|
|
1608
|
+
])) : ne(re.$slots, "default", {
|
|
1609
1609
|
key: 1,
|
|
1610
1610
|
openSecondScreen: te,
|
|
1611
1611
|
closeSecondScreen: Y,
|
|
@@ -1616,7 +1616,7 @@ const da = {
|
|
|
1616
1616
|
key: 0,
|
|
1617
1617
|
class: "popover__arrow",
|
|
1618
1618
|
ref: "arrow-block",
|
|
1619
|
-
style:
|
|
1619
|
+
style: oe(He.value)
|
|
1620
1620
|
}, null, 4)) : F("", !0)
|
|
1621
1621
|
], 6)) : F("", !0)
|
|
1622
1622
|
]),
|
|
@@ -1628,9 +1628,9 @@ const da = {
|
|
|
1628
1628
|
key: 0,
|
|
1629
1629
|
class: "popover__second-screen",
|
|
1630
1630
|
ref: "second-screen",
|
|
1631
|
-
style:
|
|
1631
|
+
style: oe({ ...$(C) })
|
|
1632
1632
|
}, [
|
|
1633
|
-
ne(
|
|
1633
|
+
ne(re.$slots, "second-screen", { closeSecondScreen: Y }, void 0, !0)
|
|
1634
1634
|
], 4)) : F("", !0)
|
|
1635
1635
|
]),
|
|
1636
1636
|
_: 3
|
|
@@ -1696,7 +1696,7 @@ const da = {
|
|
|
1696
1696
|
(m(!0), y(le, null, ce(a.columns, (i, u) => (m(), y("th", {
|
|
1697
1697
|
class: H(o(i)),
|
|
1698
1698
|
key: u,
|
|
1699
|
-
style:
|
|
1699
|
+
style: oe(r(i))
|
|
1700
1700
|
}, [
|
|
1701
1701
|
k("div", {
|
|
1702
1702
|
class: H(["table-header__cell-body", { "table-header__cell-body--center": i.selectionMode }])
|
|
@@ -1789,7 +1789,7 @@ const da = {
|
|
|
1789
1789
|
const t = n, l = T(() => e.rowStyle ? e.rowStyle(e.item) : {});
|
|
1790
1790
|
return (o, r) => (m(), y("tr", {
|
|
1791
1791
|
class: H(["table-row", { "table-row--hovered-color": o.colorHovered }]),
|
|
1792
|
-
style:
|
|
1792
|
+
style: oe(l.value),
|
|
1793
1793
|
onClick: r[1] || (r[1] = (a) => t("rowClickHandler", { data: o.item, index: o.rowIndex }))
|
|
1794
1794
|
}, [
|
|
1795
1795
|
(m(!0), y(le, null, ce(o.columns, (a) => (m(), W(Ra, {
|
|
@@ -1823,7 +1823,7 @@ const da = {
|
|
|
1823
1823
|
},
|
|
1824
1824
|
emits: ["rowClickHandler", "toggleRow"],
|
|
1825
1825
|
setup(e, { expose: n, emit: t }) {
|
|
1826
|
-
const l = t, o =
|
|
1826
|
+
const l = t, o = D(), r = D(0), a = D(0), s = T(() => !e.virtualScroll || !e.virtualScroll.enable ? 0 : Math.floor(r.value / e.virtualScroll.itemHeight)), i = T(() => {
|
|
1827
1827
|
if (!e.virtualScroll || !e.virtualScroll.enable) return e.data.length;
|
|
1828
1828
|
const v = Math.ceil(
|
|
1829
1829
|
a.value / e.virtualScroll.itemHeight
|
|
@@ -1835,13 +1835,13 @@ const da = {
|
|
|
1835
1835
|
ye(async () => {
|
|
1836
1836
|
e.virtualScroll && e.virtualScroll.enable && o.value && (await pe(), a.value = o.value.clientHeight);
|
|
1837
1837
|
});
|
|
1838
|
-
const
|
|
1838
|
+
const g = (v, f) => e.dataKey && v[e.dataKey] !== void 0 ? `row-${v[e.dataKey]}` : v.id ? `row-${v.id}` : `row-${f}`;
|
|
1839
1839
|
return n({
|
|
1840
1840
|
handleScroll: d,
|
|
1841
1841
|
updateContainerHeight: (v) => {
|
|
1842
1842
|
v ? a.value = v.clientHeight : o.value && (a.value = o.value.clientHeight);
|
|
1843
1843
|
}
|
|
1844
|
-
}), (v,
|
|
1844
|
+
}), (v, f) => v.virtualScroll && v.virtualScroll.enable ? (m(), y("tbody", {
|
|
1845
1845
|
key: 0,
|
|
1846
1846
|
ref_key: "virtualScrollBody",
|
|
1847
1847
|
ref: o,
|
|
@@ -1849,14 +1849,14 @@ const da = {
|
|
|
1849
1849
|
}, [
|
|
1850
1850
|
s.value > 0 ? (m(), y("tr", {
|
|
1851
1851
|
key: 0,
|
|
1852
|
-
style:
|
|
1852
|
+
style: oe({ height: `${s.value * v.virtualScroll.itemHeight}px` })
|
|
1853
1853
|
}, [
|
|
1854
1854
|
k("td", {
|
|
1855
1855
|
colspan: v.columns.length
|
|
1856
1856
|
}, null, 8, xa)
|
|
1857
1857
|
], 4)) : F("", !0),
|
|
1858
1858
|
(m(!0), y(le, null, ce(u.value, (h, b) => (m(), W(Ln, {
|
|
1859
|
-
key:
|
|
1859
|
+
key: g(h, s.value + b),
|
|
1860
1860
|
rowIndex: s.value + b,
|
|
1861
1861
|
item: h,
|
|
1862
1862
|
columns: v.columns,
|
|
@@ -1867,12 +1867,12 @@ const da = {
|
|
|
1867
1867
|
size: v.size,
|
|
1868
1868
|
colorHovered: v.colorHovered,
|
|
1869
1869
|
rowStyle: v.rowStyle,
|
|
1870
|
-
onRowClickHandler:
|
|
1871
|
-
onToggleRow:
|
|
1870
|
+
onRowClickHandler: f[0] || (f[0] = (S) => l("rowClickHandler", S)),
|
|
1871
|
+
onToggleRow: f[1] || (f[1] = (S) => l("toggleRow", S))
|
|
1872
1872
|
}, null, 8, ["rowIndex", "item", "columns", "selectedRows", "dataKey", "checkboxKey", "checkboxDisabled", "size", "colorHovered", "rowStyle"]))), 128)),
|
|
1873
1873
|
i.value < v.data.length ? (m(), y("tr", {
|
|
1874
1874
|
key: 1,
|
|
1875
|
-
style:
|
|
1875
|
+
style: oe({
|
|
1876
1876
|
height: `${(v.data.length - i.value) * v.virtualScroll.itemHeight}px`
|
|
1877
1877
|
})
|
|
1878
1878
|
}, [
|
|
@@ -1886,10 +1886,10 @@ const da = {
|
|
|
1886
1886
|
"table-body",
|
|
1887
1887
|
{ "table-body--scroller": v.scroller && v.scroller.enable }
|
|
1888
1888
|
]),
|
|
1889
|
-
style:
|
|
1889
|
+
style: oe({ maxHeight: `${v.scroller && v.scroller.height}px` })
|
|
1890
1890
|
}, [
|
|
1891
1891
|
(m(!0), y(le, null, ce(v.data, (h, b) => (m(), W(Ln, {
|
|
1892
|
-
key:
|
|
1892
|
+
key: g(h, b),
|
|
1893
1893
|
rowIndex: b,
|
|
1894
1894
|
item: h,
|
|
1895
1895
|
columns: v.columns,
|
|
@@ -1900,8 +1900,8 @@ const da = {
|
|
|
1900
1900
|
size: v.size,
|
|
1901
1901
|
colorHovered: v.colorHovered,
|
|
1902
1902
|
rowStyle: v.rowStyle,
|
|
1903
|
-
onRowClickHandler:
|
|
1904
|
-
onToggleRow:
|
|
1903
|
+
onRowClickHandler: f[2] || (f[2] = (S) => l("rowClickHandler", S)),
|
|
1904
|
+
onToggleRow: f[3] || (f[3] = (S) => l("toggleRow", S))
|
|
1905
1905
|
}, null, 8, ["rowIndex", "item", "columns", "selectedRows", "dataKey", "checkboxKey", "checkboxDisabled", "size", "colorHovered", "rowStyle"]))), 128))
|
|
1906
1906
|
], 6));
|
|
1907
1907
|
}
|
|
@@ -2043,7 +2043,7 @@ const da = {
|
|
|
2043
2043
|
},
|
|
2044
2044
|
emits: ["update:modelValue", "search", "change", "clear", "remove-tag"],
|
|
2045
2045
|
setup(e, { emit: n }) {
|
|
2046
|
-
const t = e, l = n, o =
|
|
2046
|
+
const t = e, l = n, o = D(!1), r = D(""), a = D(), s = D(), i = D(), u = D({});
|
|
2047
2047
|
function d(R) {
|
|
2048
2048
|
let G = 1e3, L = R;
|
|
2049
2049
|
for (; L && L !== document.body; ) {
|
|
@@ -2052,7 +2052,7 @@ const da = {
|
|
|
2052
2052
|
}
|
|
2053
2053
|
return G;
|
|
2054
2054
|
}
|
|
2055
|
-
const
|
|
2055
|
+
const g = D(9999), v = T(() => {
|
|
2056
2056
|
if (!t.modelValue) return [];
|
|
2057
2057
|
if (t.multiple)
|
|
2058
2058
|
return (Array.isArray(t.modelValue) ? t.modelValue : [t.modelValue]).map((G) => {
|
|
@@ -2074,7 +2074,7 @@ const da = {
|
|
|
2074
2074
|
);
|
|
2075
2075
|
return R ? [R] : [];
|
|
2076
2076
|
}
|
|
2077
|
-
}),
|
|
2077
|
+
}), f = T(() => t.multiple || !v.value.length ? "" : C(v.value[0])), h = T(() => t.multiple ? v.value.length > 0 : t.modelValue !== void 0 && t.modelValue !== null), b = T(() => v.value.slice(0, t.maxTags)), S = T(() => Math.max(0, v.value.length - t.maxTags)), M = T(() => r.value ? (t.options || []).filter(
|
|
2078
2078
|
(R) => C(R).toLowerCase().includes(r.value.toLowerCase())
|
|
2079
2079
|
) : t.options || []), _ = T(() => t.multiple ? v.value.map((R) => O(R)) : []), P = T(() => t.multiple || !v.value.length ? null : O(v.value[0]));
|
|
2080
2080
|
function O(R) {
|
|
@@ -2129,12 +2129,12 @@ const da = {
|
|
|
2129
2129
|
function B() {
|
|
2130
2130
|
!a.value || !o.value || pe(() => {
|
|
2131
2131
|
const R = d(a.value);
|
|
2132
|
-
|
|
2132
|
+
g.value = R + 10;
|
|
2133
2133
|
const G = a.value.getBoundingClientRect(), L = window.innerHeight, J = window.innerWidth, V = L - G.bottom, E = G.top, te = V < 300 && E > V, Y = Math.max(300, G.width);
|
|
2134
|
-
let
|
|
2135
|
-
|
|
2134
|
+
let ae = G.left;
|
|
2135
|
+
ae + Y > J && (ae = Math.max(0, J - Y - 10)), u.value = {
|
|
2136
2136
|
position: "fixed",
|
|
2137
|
-
left: `${
|
|
2137
|
+
left: `${ae}px`,
|
|
2138
2138
|
width: `${Y}px`,
|
|
2139
2139
|
maxHeight: "300px"
|
|
2140
2140
|
}, te ? u.value.bottom = `${L - G.top + 4}px` : u.value.top = `${G.bottom + 4}px`;
|
|
@@ -2198,12 +2198,12 @@ const da = {
|
|
|
2198
2198
|
_: 1
|
|
2199
2199
|
})) : F("", !0)
|
|
2200
2200
|
])) : (m(), y(le, { key: 1 }, [
|
|
2201
|
-
|
|
2201
|
+
f.value ? ne(R.$slots, "input", {
|
|
2202
2202
|
key: 0,
|
|
2203
|
-
value:
|
|
2203
|
+
value: f.value,
|
|
2204
2204
|
selectedOption: v.value[0]
|
|
2205
2205
|
}, () => [
|
|
2206
|
-
k("span", za, K(
|
|
2206
|
+
k("span", za, K(f.value), 1)
|
|
2207
2207
|
], !0) : (m(), y("span", Ha, K(R.placeholder), 1))
|
|
2208
2208
|
], 64))
|
|
2209
2209
|
]),
|
|
@@ -2222,14 +2222,14 @@ const da = {
|
|
|
2222
2222
|
], 2),
|
|
2223
2223
|
j($(At), {
|
|
2224
2224
|
show: o.value,
|
|
2225
|
-
"z-index":
|
|
2225
|
+
"z-index": g.value
|
|
2226
2226
|
}, {
|
|
2227
2227
|
default: ie(() => [
|
|
2228
2228
|
k("div", {
|
|
2229
2229
|
ref_key: "dropdownOverlay",
|
|
2230
2230
|
ref: s,
|
|
2231
2231
|
class: "dropdown__overlay",
|
|
2232
|
-
style:
|
|
2232
|
+
style: oe(u.value),
|
|
2233
2233
|
onClick: G[1] || (G[1] = he(() => {
|
|
2234
2234
|
}, ["stop"]))
|
|
2235
2235
|
}, [
|
|
@@ -2247,7 +2247,7 @@ const da = {
|
|
|
2247
2247
|
])) : F("", !0),
|
|
2248
2248
|
k("div", Ga, [
|
|
2249
2249
|
R.loading ? (m(), y("div", Ka, "Загрузка...")) : (m(), y(le, { key: 1 }, [
|
|
2250
|
-
(m(!0), y(le, null, ce(
|
|
2250
|
+
(m(!0), y(le, null, ce(M.value, (L) => (m(), y("div", {
|
|
2251
2251
|
key: I(L),
|
|
2252
2252
|
class: H(["dropdown__option", {
|
|
2253
2253
|
"dropdown__option--disabled": L.disabled
|
|
@@ -2283,7 +2283,7 @@ const da = {
|
|
|
2283
2283
|
], 8, Na)
|
|
2284
2284
|
])
|
|
2285
2285
|
], 2))), 128)),
|
|
2286
|
-
|
|
2286
|
+
M.value.length ? F("", !0) : (m(), y("div", Ua, " Ничего не найдено ")),
|
|
2287
2287
|
R.$slots.footer ? (m(), y("div", Wa, [
|
|
2288
2288
|
ne(R.$slots, "footer", {}, void 0, !0)
|
|
2289
2289
|
])) : F("", !0)
|
|
@@ -2417,13 +2417,13 @@ const da = {
|
|
|
2417
2417
|
return (o, r) => (m(), y("div", {
|
|
2418
2418
|
class: H(l.value),
|
|
2419
2419
|
"aria-label": "Loading",
|
|
2420
|
-
style:
|
|
2420
|
+
style: oe(t.value)
|
|
2421
2421
|
}, [...r[0] || (r[0] = [
|
|
2422
2422
|
k("span", { class: "spinner__circle" }, null, -1)
|
|
2423
2423
|
])], 6));
|
|
2424
2424
|
}
|
|
2425
2425
|
}), ir = () => {
|
|
2426
|
-
const e =
|
|
2426
|
+
const e = D([]), n = D([]), t = D({
|
|
2427
2427
|
selectedMode: null
|
|
2428
2428
|
}), l = (a) => {
|
|
2429
2429
|
const s = e.value.findIndex((i) => i.id === a.id);
|
|
@@ -2486,7 +2486,7 @@ const da = {
|
|
|
2486
2486
|
}),
|
|
2487
2487
|
emits: /* @__PURE__ */ se(["rowClickHandler"], ["update:currentPage", "update:perPage", "update:selectedRows"]),
|
|
2488
2488
|
setup(e, { emit: n }) {
|
|
2489
|
-
const t = n, { columns: l, options: o } = ir(), r = T(() => o.value.selectedMode), a =
|
|
2489
|
+
const t = n, { columns: l, options: o } = ir(), r = T(() => o.value.selectedMode), a = D(null), s = D(), i = D(), u = ue(e, "currentPage"), d = ue(e, "perPage"), g = (p) => {
|
|
2490
2490
|
if (e.virtualScroll && e.virtualScroll.enable && s.value) {
|
|
2491
2491
|
const w = p.target;
|
|
2492
2492
|
s.value.handleScroll(w);
|
|
@@ -2509,7 +2509,7 @@ const da = {
|
|
|
2509
2509
|
p && s.value.updateContainerHeight(p);
|
|
2510
2510
|
}
|
|
2511
2511
|
});
|
|
2512
|
-
const
|
|
2512
|
+
const f = D([...e.data]);
|
|
2513
2513
|
Un(() => {
|
|
2514
2514
|
let p = [...e.data];
|
|
2515
2515
|
if (a.value) {
|
|
@@ -2519,7 +2519,7 @@ const da = {
|
|
|
2519
2519
|
return N === B ? 0 : x === 1 ? N > B ? 1 : -1 : N < B ? 1 : -1;
|
|
2520
2520
|
});
|
|
2521
2521
|
}
|
|
2522
|
-
|
|
2522
|
+
f.value = p;
|
|
2523
2523
|
});
|
|
2524
2524
|
const h = T(() => e.scroller && e.scroller.enable || e.virtualScroll && e.virtualScroll.enable || e.maxHeight), b = T(() => [
|
|
2525
2525
|
"table",
|
|
@@ -2535,7 +2535,7 @@ const da = {
|
|
|
2535
2535
|
{
|
|
2536
2536
|
"table-wrapper--scrollable": h.value
|
|
2537
2537
|
}
|
|
2538
|
-
]),
|
|
2538
|
+
]), M = T(() => {
|
|
2539
2539
|
const p = {};
|
|
2540
2540
|
return e.maxHeight ? (p.maxHeight = typeof e.maxHeight == "number" ? `${e.maxHeight}px` : e.maxHeight, p.overflow = "auto") : e.scroller && e.scroller.enable && (p.maxHeight = `${e.scroller.height}px`, p.overflow = "auto"), p;
|
|
2541
2541
|
}), _ = ue(
|
|
@@ -2604,8 +2604,8 @@ const da = {
|
|
|
2604
2604
|
}), (p, w) => h.value ? (m(), y("div", {
|
|
2605
2605
|
key: 0,
|
|
2606
2606
|
class: H(S.value),
|
|
2607
|
-
style:
|
|
2608
|
-
onScroll:
|
|
2607
|
+
style: oe(M.value),
|
|
2608
|
+
onScroll: g
|
|
2609
2609
|
}, [
|
|
2610
2610
|
k("table", {
|
|
2611
2611
|
ref_key: "tableRef",
|
|
@@ -2623,7 +2623,7 @@ const da = {
|
|
|
2623
2623
|
onSelectAllRow: c,
|
|
2624
2624
|
"onUpdate:sort": w[0] || (w[0] = (x) => a.value = x)
|
|
2625
2625
|
}, null, 8, ["size", "columns", "isSelectedAll", "isIndeterminate", "sortMode", "sortField"]),
|
|
2626
|
-
|
|
2626
|
+
f.value.length > 0 && !p.loading ? (m(), W(On, {
|
|
2627
2627
|
key: 0,
|
|
2628
2628
|
ref_key: "tableBodyRef",
|
|
2629
2629
|
ref: s,
|
|
@@ -2633,7 +2633,7 @@ const da = {
|
|
|
2633
2633
|
checkboxKey: p.checkboxKey,
|
|
2634
2634
|
checkboxDisabled: p.checkboxDisabled,
|
|
2635
2635
|
columns: $(l),
|
|
2636
|
-
data:
|
|
2636
|
+
data: f.value,
|
|
2637
2637
|
colorHovered: p.rowColorHovered,
|
|
2638
2638
|
scroller: p.scroller || void 0,
|
|
2639
2639
|
virtualScroll: p.virtualScroll || void 0,
|
|
@@ -2691,7 +2691,7 @@ const da = {
|
|
|
2691
2691
|
onSelectAllRow: c,
|
|
2692
2692
|
"onUpdate:sort": w[5] || (w[5] = (x) => a.value = x)
|
|
2693
2693
|
}, null, 8, ["size", "columns", "isSelectedAll", "isIndeterminate", "sortMode", "sortField"]),
|
|
2694
|
-
|
|
2694
|
+
f.value.length > 0 && !p.loading ? (m(), W(On, {
|
|
2695
2695
|
key: 0,
|
|
2696
2696
|
ref_key: "tableBodyRef",
|
|
2697
2697
|
ref: s,
|
|
@@ -2701,7 +2701,7 @@ const da = {
|
|
|
2701
2701
|
checkboxKey: p.checkboxKey,
|
|
2702
2702
|
checkboxDisabled: p.checkboxDisabled,
|
|
2703
2703
|
columns: $(l),
|
|
2704
|
-
data:
|
|
2704
|
+
data: f.value,
|
|
2705
2705
|
colorHovered: p.rowColorHovered,
|
|
2706
2706
|
scroller: p.scroller || void 0,
|
|
2707
2707
|
virtualScroll: p.virtualScroll || void 0,
|
|
@@ -2836,17 +2836,17 @@ function Z(e, n, t) {
|
|
|
2836
2836
|
let a;
|
|
2837
2837
|
t.key && t.debug && (a = Date.now());
|
|
2838
2838
|
const s = e(r);
|
|
2839
|
-
if (!(s.length !== l.length || s.some((d,
|
|
2839
|
+
if (!(s.length !== l.length || s.some((d, g) => l[g] !== d)))
|
|
2840
2840
|
return o;
|
|
2841
2841
|
l = s;
|
|
2842
2842
|
let u;
|
|
2843
2843
|
if (t.key && t.debug && (u = Date.now()), o = n(...s), t == null || t.onChange == null || t.onChange(o), t.key && t.debug && t != null && t.debug()) {
|
|
2844
|
-
const d = Math.round((Date.now() - a) * 100) / 100,
|
|
2844
|
+
const d = Math.round((Date.now() - a) * 100) / 100, g = Math.round((Date.now() - u) * 100) / 100, v = g / 16, f = (h, b) => {
|
|
2845
2845
|
for (h = String(h); h.length < b; )
|
|
2846
2846
|
h = " " + h;
|
|
2847
2847
|
return h;
|
|
2848
2848
|
};
|
|
2849
|
-
console.info(`%c⏱ ${g
|
|
2849
|
+
console.info(`%c⏱ ${f(g, 5)} /${f(d, 5)} ms`, `
|
|
2850
2850
|
font-size: .6rem;
|
|
2851
2851
|
font-weight: bold;
|
|
2852
2852
|
color: hsl(${Math.max(0, Math.min(120 - 120 * v, 120))}deg 100% 31%);`, t?.key);
|
|
@@ -2895,15 +2895,15 @@ function kr(e, n, t, l) {
|
|
|
2895
2895
|
}, i = s.accessorKey;
|
|
2896
2896
|
let u = (o = (r = s.id) != null ? r : i ? typeof String.prototype.replaceAll == "function" ? i.replaceAll(".", "_") : i.replace(/\./g, "_") : void 0) != null ? o : typeof s.header == "string" ? s.header : void 0, d;
|
|
2897
2897
|
if (s.accessorFn ? d = s.accessorFn : i && (i.includes(".") ? d = (v) => {
|
|
2898
|
-
let
|
|
2898
|
+
let f = v;
|
|
2899
2899
|
for (const b of i.split(".")) {
|
|
2900
2900
|
var h;
|
|
2901
|
-
|
|
2901
|
+
f = (h = f) == null ? void 0 : h[b], process.env.NODE_ENV !== "production" && f === void 0 && console.warn(`"${b}" in deeply nested key "${i}" returned undefined.`);
|
|
2902
2902
|
}
|
|
2903
|
-
return
|
|
2903
|
+
return f;
|
|
2904
2904
|
} : d = (v) => v[s.accessorKey]), !u)
|
|
2905
2905
|
throw process.env.NODE_ENV !== "production" ? new Error(s.accessorFn ? "Columns require an id when using an accessorFn" : "Columns require an id when using a non-string header") : new Error();
|
|
2906
|
-
let
|
|
2906
|
+
let g = {
|
|
2907
2907
|
id: `${String(u)}`,
|
|
2908
2908
|
accessorFn: d,
|
|
2909
2909
|
parent: l,
|
|
@@ -2912,20 +2912,20 @@ function kr(e, n, t, l) {
|
|
|
2912
2912
|
columns: [],
|
|
2913
2913
|
getFlatColumns: Z(() => [!0], () => {
|
|
2914
2914
|
var v;
|
|
2915
|
-
return [
|
|
2915
|
+
return [g, ...(v = g.columns) == null ? void 0 : v.flatMap((f) => f.getFlatColumns())];
|
|
2916
2916
|
}, Q(e.options, "debugColumns", "column.getFlatColumns")),
|
|
2917
2917
|
getLeafColumns: Z(() => [e._getOrderColumnsFn()], (v) => {
|
|
2918
|
-
var
|
|
2919
|
-
if ((
|
|
2920
|
-
let h =
|
|
2918
|
+
var f;
|
|
2919
|
+
if ((f = g.columns) != null && f.length) {
|
|
2920
|
+
let h = g.columns.flatMap((b) => b.getLeafColumns());
|
|
2921
2921
|
return v(h);
|
|
2922
2922
|
}
|
|
2923
|
-
return [
|
|
2923
|
+
return [g];
|
|
2924
2924
|
}, Q(e.options, "debugColumns", "column.getLeafColumns"))
|
|
2925
2925
|
};
|
|
2926
2926
|
for (const v of e._features)
|
|
2927
|
-
v.createColumn == null || v.createColumn(
|
|
2928
|
-
return
|
|
2927
|
+
v.createColumn == null || v.createColumn(g, e);
|
|
2928
|
+
return g;
|
|
2929
2929
|
}
|
|
2930
2930
|
const be = "debugHeaders";
|
|
2931
2931
|
function Bn(e, n, t) {
|
|
@@ -2961,7 +2961,7 @@ const Rr = {
|
|
|
2961
2961
|
createTable: (e) => {
|
|
2962
2962
|
e.getHeaderGroups = Z(() => [e.getAllColumns(), e.getVisibleLeafColumns(), e.getState().columnPinning.left, e.getState().columnPinning.right], (n, t, l, o) => {
|
|
2963
2963
|
var r, a;
|
|
2964
|
-
const s = (r = l?.map((
|
|
2964
|
+
const s = (r = l?.map((g) => t.find((v) => v.id === g)).filter(Boolean)) != null ? r : [], i = (a = o?.map((g) => t.find((v) => v.id === g)).filter(Boolean)) != null ? a : [], u = t.filter((g) => !(l != null && l.includes(g.id)) && !(o != null && o.includes(g.id)));
|
|
2965
2965
|
return $t(n, [...s, ...u, ...i], e);
|
|
2966
2966
|
}, Q(e.options, be, "getHeaderGroups")), e.getCenterHeaderGroups = Z(() => [e.getAllColumns(), e.getVisibleLeafColumns(), e.getState().columnPinning.left, e.getState().columnPinning.right], (n, t, l, o) => (t = t.filter((r) => !(l != null && l.includes(r.id)) && !(o != null && o.includes(r.id))), $t(n, t, e, "center")), Q(e.options, be, "getCenterHeaderGroups")), e.getLeftHeaderGroups = Z(() => [e.getAllColumns(), e.getVisibleLeafColumns(), e.getState().columnPinning.left], (n, t, l) => {
|
|
2967
2967
|
var o;
|
|
@@ -2989,58 +2989,58 @@ const Rr = {
|
|
|
2989
2989
|
function $t(e, n, t, l) {
|
|
2990
2990
|
var o, r;
|
|
2991
2991
|
let a = 0;
|
|
2992
|
-
const s = function(v,
|
|
2993
|
-
|
|
2992
|
+
const s = function(v, f) {
|
|
2993
|
+
f === void 0 && (f = 1), a = Math.max(a, f), v.filter((h) => h.getIsVisible()).forEach((h) => {
|
|
2994
2994
|
var b;
|
|
2995
|
-
(b = h.columns) != null && b.length && s(h.columns,
|
|
2995
|
+
(b = h.columns) != null && b.length && s(h.columns, f + 1);
|
|
2996
2996
|
}, 0);
|
|
2997
2997
|
};
|
|
2998
2998
|
s(e);
|
|
2999
2999
|
let i = [];
|
|
3000
|
-
const u = (v,
|
|
3000
|
+
const u = (v, f) => {
|
|
3001
3001
|
const h = {
|
|
3002
|
-
depth:
|
|
3003
|
-
id: [l, `${
|
|
3002
|
+
depth: f,
|
|
3003
|
+
id: [l, `${f}`].filter(Boolean).join("_"),
|
|
3004
3004
|
headers: []
|
|
3005
3005
|
}, b = [];
|
|
3006
3006
|
v.forEach((S) => {
|
|
3007
|
-
const
|
|
3007
|
+
const M = [...b].reverse()[0], _ = S.column.depth === h.depth;
|
|
3008
3008
|
let P, O = !1;
|
|
3009
|
-
if (_ && S.column.parent ? P = S.column.parent : (P = S.column, O = !0),
|
|
3010
|
-
|
|
3009
|
+
if (_ && S.column.parent ? P = S.column.parent : (P = S.column, O = !0), M && M?.column === P)
|
|
3010
|
+
M.subHeaders.push(S);
|
|
3011
3011
|
else {
|
|
3012
3012
|
const I = Bn(t, P, {
|
|
3013
|
-
id: [l,
|
|
3013
|
+
id: [l, f, P.id, S?.id].filter(Boolean).join("_"),
|
|
3014
3014
|
isPlaceholder: O,
|
|
3015
3015
|
placeholderId: O ? `${b.filter((C) => C.column === P).length}` : void 0,
|
|
3016
|
-
depth:
|
|
3016
|
+
depth: f,
|
|
3017
3017
|
index: b.length
|
|
3018
3018
|
});
|
|
3019
3019
|
I.subHeaders.push(S), b.push(I);
|
|
3020
3020
|
}
|
|
3021
3021
|
h.headers.push(S), S.headerGroup = h;
|
|
3022
|
-
}), i.push(h),
|
|
3023
|
-
}, d = n.map((v,
|
|
3022
|
+
}), i.push(h), f > 0 && u(b, f - 1);
|
|
3023
|
+
}, d = n.map((v, f) => Bn(t, v, {
|
|
3024
3024
|
depth: a,
|
|
3025
|
-
index:
|
|
3025
|
+
index: f
|
|
3026
3026
|
}));
|
|
3027
3027
|
u(d, a - 1), i.reverse();
|
|
3028
|
-
const
|
|
3029
|
-
let b = 0, S = 0,
|
|
3030
|
-
h.subHeaders && h.subHeaders.length ? (
|
|
3028
|
+
const g = (v) => v.filter((h) => h.column.getIsVisible()).map((h) => {
|
|
3029
|
+
let b = 0, S = 0, M = [0];
|
|
3030
|
+
h.subHeaders && h.subHeaders.length ? (M = [], g(h.subHeaders).forEach((P) => {
|
|
3031
3031
|
let {
|
|
3032
3032
|
colSpan: O,
|
|
3033
3033
|
rowSpan: I
|
|
3034
3034
|
} = P;
|
|
3035
|
-
b += O,
|
|
3035
|
+
b += O, M.push(I);
|
|
3036
3036
|
})) : b = 1;
|
|
3037
|
-
const _ = Math.min(...
|
|
3037
|
+
const _ = Math.min(...M);
|
|
3038
3038
|
return S = S + _, h.colSpan = b, h.rowSpan = S, {
|
|
3039
3039
|
colSpan: b,
|
|
3040
3040
|
rowSpan: S
|
|
3041
3041
|
};
|
|
3042
3042
|
});
|
|
3043
|
-
return
|
|
3043
|
+
return g((o = (r = i[0]) == null ? void 0 : r.headers) != null ? o : []), i;
|
|
3044
3044
|
}
|
|
3045
3045
|
const _r = (e, n, t, l, o, r, a) => {
|
|
3046
3046
|
let s = {
|
|
@@ -3413,20 +3413,20 @@ const Hr = {
|
|
|
3413
3413
|
if (t === "right") {
|
|
3414
3414
|
var s, i;
|
|
3415
3415
|
return {
|
|
3416
|
-
left: ((s = o?.left) != null ? s : []).filter((
|
|
3417
|
-
right: [...((i = o?.right) != null ? i : []).filter((
|
|
3416
|
+
left: ((s = o?.left) != null ? s : []).filter((g) => !(l != null && l.includes(g))),
|
|
3417
|
+
right: [...((i = o?.right) != null ? i : []).filter((g) => !(l != null && l.includes(g))), ...l]
|
|
3418
3418
|
};
|
|
3419
3419
|
}
|
|
3420
3420
|
if (t === "left") {
|
|
3421
3421
|
var u, d;
|
|
3422
3422
|
return {
|
|
3423
|
-
left: [...((u = o?.left) != null ? u : []).filter((
|
|
3424
|
-
right: ((d = o?.right) != null ? d : []).filter((
|
|
3423
|
+
left: [...((u = o?.left) != null ? u : []).filter((g) => !(l != null && l.includes(g))), ...l],
|
|
3424
|
+
right: ((d = o?.right) != null ? d : []).filter((g) => !(l != null && l.includes(g)))
|
|
3425
3425
|
};
|
|
3426
3426
|
}
|
|
3427
3427
|
return {
|
|
3428
|
-
left: ((r = o?.left) != null ? r : []).filter((
|
|
3429
|
-
right: ((a = o?.right) != null ? a : []).filter((
|
|
3428
|
+
left: ((r = o?.left) != null ? r : []).filter((g) => !(l != null && l.includes(g))),
|
|
3429
|
+
right: ((a = o?.right) != null ? a : []).filter((g) => !(l != null && l.includes(g)))
|
|
3430
3430
|
};
|
|
3431
3431
|
});
|
|
3432
3432
|
}, e.getCanPin = () => e.getLeafColumns().some((l) => {
|
|
@@ -3542,7 +3542,7 @@ const kt = {
|
|
|
3542
3542
|
return (r) => {
|
|
3543
3543
|
if (!l || !o || (r.persist == null || r.persist(), Nt(r) && r.touches && r.touches.length > 1))
|
|
3544
3544
|
return;
|
|
3545
|
-
const a = e.getSize(), s = e ? e.getLeafHeaders().map((
|
|
3545
|
+
const a = e.getSize(), s = e ? e.getLeafHeaders().map((M) => [M.column.id, M.column.getSize()]) : [[l.id, l.getSize()]], i = Nt(r) ? Math.round(r.touches[0].clientX) : r.clientX, u = {}, d = (M, _) => {
|
|
3546
3546
|
typeof _ == "number" && (n.setColumnSizingInfo((P) => {
|
|
3547
3547
|
var O, I;
|
|
3548
3548
|
const C = n.options.columnResizeDirection === "rtl" ? -1 : 1, c = (_ - ((O = P?.startOffset) != null ? O : 0)) * C, p = Math.max(c / ((I = P?.startSize) != null ? I : 0), -0.999999);
|
|
@@ -3554,12 +3554,12 @@ const kt = {
|
|
|
3554
3554
|
deltaOffset: c,
|
|
3555
3555
|
deltaPercentage: p
|
|
3556
3556
|
};
|
|
3557
|
-
}), (n.options.columnResizeMode === "onChange" ||
|
|
3557
|
+
}), (n.options.columnResizeMode === "onChange" || M === "end") && n.setColumnSizing((P) => ({
|
|
3558
3558
|
...P,
|
|
3559
3559
|
...u
|
|
3560
3560
|
})));
|
|
3561
|
-
},
|
|
3562
|
-
d("end",
|
|
3561
|
+
}, g = (M) => d("move", M), v = (M) => {
|
|
3562
|
+
d("end", M), n.setColumnSizingInfo((_) => ({
|
|
3563
3563
|
..._,
|
|
3564
3564
|
isResizingColumn: !1,
|
|
3565
3565
|
startOffset: null,
|
|
@@ -3568,22 +3568,22 @@ const kt = {
|
|
|
3568
3568
|
deltaPercentage: null,
|
|
3569
3569
|
columnSizingStart: []
|
|
3570
3570
|
}));
|
|
3571
|
-
},
|
|
3572
|
-
moveHandler: (
|
|
3573
|
-
upHandler: (
|
|
3574
|
-
|
|
3571
|
+
}, f = Gr(t), h = {
|
|
3572
|
+
moveHandler: (M) => g(M.clientX),
|
|
3573
|
+
upHandler: (M) => {
|
|
3574
|
+
f?.removeEventListener("mousemove", h.moveHandler), f?.removeEventListener("mouseup", h.upHandler), v(M.clientX);
|
|
3575
3575
|
}
|
|
3576
3576
|
}, b = {
|
|
3577
|
-
moveHandler: (
|
|
3578
|
-
upHandler: (
|
|
3577
|
+
moveHandler: (M) => (M.cancelable && (M.preventDefault(), M.stopPropagation()), g(M.touches[0].clientX), !1),
|
|
3578
|
+
upHandler: (M) => {
|
|
3579
3579
|
var _;
|
|
3580
|
-
|
|
3580
|
+
f?.removeEventListener("touchmove", b.moveHandler), f?.removeEventListener("touchend", b.upHandler), M.cancelable && (M.preventDefault(), M.stopPropagation()), v((_ = M.touches[0]) == null ? void 0 : _.clientX);
|
|
3581
3581
|
}
|
|
3582
3582
|
}, S = qr() ? {
|
|
3583
3583
|
passive: !1
|
|
3584
3584
|
} : !1;
|
|
3585
|
-
Nt(r) ? (
|
|
3586
|
-
...
|
|
3585
|
+
Nt(r) ? (f?.addEventListener("touchmove", b.moveHandler, S), f?.addEventListener("touchend", b.upHandler, S)) : (f?.addEventListener("mousemove", h.moveHandler, S), f?.addEventListener("mouseup", h.upHandler, S)), n.setColumnSizingInfo((M) => ({
|
|
3586
|
+
...M,
|
|
3587
3587
|
startOffset: i,
|
|
3588
3588
|
startSize: a,
|
|
3589
3589
|
deltaOffset: 0,
|
|
@@ -3921,16 +3921,16 @@ const jr = {
|
|
|
3921
3921
|
n.setRowPinning((i) => {
|
|
3922
3922
|
var u, d;
|
|
3923
3923
|
if (t === "bottom") {
|
|
3924
|
-
var
|
|
3924
|
+
var g, v;
|
|
3925
3925
|
return {
|
|
3926
|
-
top: ((
|
|
3926
|
+
top: ((g = i?.top) != null ? g : []).filter((b) => !(s != null && s.has(b))),
|
|
3927
3927
|
bottom: [...((v = i?.bottom) != null ? v : []).filter((b) => !(s != null && s.has(b))), ...Array.from(s)]
|
|
3928
3928
|
};
|
|
3929
3929
|
}
|
|
3930
3930
|
if (t === "top") {
|
|
3931
|
-
var
|
|
3931
|
+
var f, h;
|
|
3932
3932
|
return {
|
|
3933
|
-
top: [...((
|
|
3933
|
+
top: [...((f = i?.top) != null ? f : []).filter((b) => !(s != null && s.has(b))), ...Array.from(s)],
|
|
3934
3934
|
bottom: ((h = i?.bottom) != null ? h : []).filter((b) => !(s != null && s.has(b)))
|
|
3935
3935
|
};
|
|
3936
3936
|
}
|
|
@@ -4227,20 +4227,20 @@ const ft = {
|
|
|
4227
4227
|
}, e.toggleSorting = (t, l) => {
|
|
4228
4228
|
const o = e.getNextSortingOrder(), r = typeof t < "u" && t !== null;
|
|
4229
4229
|
n.setSorting((a) => {
|
|
4230
|
-
const s = a?.find((
|
|
4231
|
-
let u = [], d,
|
|
4230
|
+
const s = a?.find((f) => f.id === e.id), i = a?.findIndex((f) => f.id === e.id);
|
|
4231
|
+
let u = [], d, g = r ? t : o === "desc";
|
|
4232
4232
|
if (a != null && a.length && e.getCanMultiSort() && l ? s ? d = "toggle" : d = "add" : a != null && a.length && i !== a.length - 1 ? d = "replace" : s ? d = "toggle" : d = "replace", d === "toggle" && (r || o || (d = "remove")), d === "add") {
|
|
4233
4233
|
var v;
|
|
4234
4234
|
u = [...a, {
|
|
4235
4235
|
id: e.id,
|
|
4236
|
-
desc:
|
|
4236
|
+
desc: g
|
|
4237
4237
|
}], u.splice(0, u.length - ((v = n.options.maxMultiSortColCount) != null ? v : Number.MAX_SAFE_INTEGER));
|
|
4238
|
-
} else d === "toggle" ? u = a.map((
|
|
4239
|
-
...
|
|
4240
|
-
desc:
|
|
4241
|
-
} :
|
|
4238
|
+
} else d === "toggle" ? u = a.map((f) => f.id === e.id ? {
|
|
4239
|
+
...f,
|
|
4240
|
+
desc: g
|
|
4241
|
+
} : f) : d === "remove" ? u = a.filter((f) => f.id !== e.id) : u = [{
|
|
4242
4242
|
id: e.id,
|
|
4243
|
-
desc:
|
|
4243
|
+
desc: g
|
|
4244
4244
|
}];
|
|
4245
4245
|
return u;
|
|
4246
4246
|
});
|
|
@@ -4307,7 +4307,7 @@ function rs(e) {
|
|
|
4307
4307
|
let o = {
|
|
4308
4308
|
_features: l
|
|
4309
4309
|
};
|
|
4310
|
-
const r = o._features.reduce((v,
|
|
4310
|
+
const r = o._features.reduce((v, f) => Object.assign(v, f.getDefaultOptions == null ? void 0 : f.getDefaultOptions(o)), {}), a = (v) => o.options.mergeOptions ? o.options.mergeOptions(r, v) : {
|
|
4311
4311
|
...r,
|
|
4312
4312
|
...v
|
|
4313
4313
|
};
|
|
@@ -4316,12 +4316,12 @@ function rs(e) {
|
|
|
4316
4316
|
...(t = e.initialState) != null ? t : {}
|
|
4317
4317
|
};
|
|
4318
4318
|
o._features.forEach((v) => {
|
|
4319
|
-
var
|
|
4320
|
-
i = (
|
|
4319
|
+
var f;
|
|
4320
|
+
i = (f = v.getInitialState == null ? void 0 : v.getInitialState(i)) != null ? f : i;
|
|
4321
4321
|
});
|
|
4322
4322
|
const u = [];
|
|
4323
4323
|
let d = !1;
|
|
4324
|
-
const
|
|
4324
|
+
const g = {
|
|
4325
4325
|
_features: l,
|
|
4326
4326
|
options: {
|
|
4327
4327
|
...r,
|
|
@@ -4333,39 +4333,39 @@ function rs(e) {
|
|
|
4333
4333
|
for (; u.length; )
|
|
4334
4334
|
u.shift()();
|
|
4335
4335
|
d = !1;
|
|
4336
|
-
}).catch((
|
|
4337
|
-
throw
|
|
4336
|
+
}).catch((f) => setTimeout(() => {
|
|
4337
|
+
throw f;
|
|
4338
4338
|
})));
|
|
4339
4339
|
},
|
|
4340
4340
|
reset: () => {
|
|
4341
4341
|
o.setState(o.initialState);
|
|
4342
4342
|
},
|
|
4343
4343
|
setOptions: (v) => {
|
|
4344
|
-
const
|
|
4345
|
-
o.options = a(
|
|
4344
|
+
const f = Ge(v, o.options);
|
|
4345
|
+
o.options = a(f);
|
|
4346
4346
|
},
|
|
4347
4347
|
getState: () => o.options.state,
|
|
4348
4348
|
setState: (v) => {
|
|
4349
4349
|
o.options.onStateChange == null || o.options.onStateChange(v);
|
|
4350
4350
|
},
|
|
4351
|
-
_getRowId: (v,
|
|
4351
|
+
_getRowId: (v, f, h) => {
|
|
4352
4352
|
var b;
|
|
4353
|
-
return (b = o.options.getRowId == null ? void 0 : o.options.getRowId(v,
|
|
4353
|
+
return (b = o.options.getRowId == null ? void 0 : o.options.getRowId(v, f, h)) != null ? b : `${h ? [h.id, f].join(".") : f}`;
|
|
4354
4354
|
},
|
|
4355
4355
|
getCoreRowModel: () => (o._getCoreRowModel || (o._getCoreRowModel = o.options.getCoreRowModel(o)), o._getCoreRowModel()),
|
|
4356
4356
|
// The final calls start at the bottom of the model,
|
|
4357
4357
|
// expanded rows, which then work their way up
|
|
4358
4358
|
getRowModel: () => o.getPaginationRowModel(),
|
|
4359
4359
|
//in next version, we should just pass in the row model as the optional 2nd arg
|
|
4360
|
-
getRow: (v,
|
|
4361
|
-
let h = (
|
|
4360
|
+
getRow: (v, f) => {
|
|
4361
|
+
let h = (f ? o.getPrePaginationRowModel() : o.getRowModel()).rowsById[v];
|
|
4362
4362
|
if (!h && (h = o.getCoreRowModel().rowsById[v], !h))
|
|
4363
4363
|
throw process.env.NODE_ENV !== "production" ? new Error(`getRow could not find row with ID: ${v}`) : new Error();
|
|
4364
4364
|
return h;
|
|
4365
4365
|
},
|
|
4366
4366
|
_getDefaultColumnDef: Z(() => [o.options.defaultColumn], (v) => {
|
|
4367
|
-
var
|
|
4368
|
-
return v = (
|
|
4367
|
+
var f;
|
|
4368
|
+
return v = (f = v) != null ? f : {}, {
|
|
4369
4369
|
header: (h) => {
|
|
4370
4370
|
const b = h.header.column.columnDef;
|
|
4371
4371
|
return b.accessorKey ? b.accessorKey : b.accessorFn ? b.id : null;
|
|
@@ -4381,29 +4381,29 @@ function rs(e) {
|
|
|
4381
4381
|
}, Q(e, "debugColumns", "_getDefaultColumnDef")),
|
|
4382
4382
|
_getColumnDefs: () => o.options.columns,
|
|
4383
4383
|
getAllColumns: Z(() => [o._getColumnDefs()], (v) => {
|
|
4384
|
-
const
|
|
4385
|
-
return S === void 0 && (S = 0), h.map((
|
|
4386
|
-
const _ = kr(o,
|
|
4387
|
-
return _.columns = P.columns ?
|
|
4384
|
+
const f = function(h, b, S) {
|
|
4385
|
+
return S === void 0 && (S = 0), h.map((M) => {
|
|
4386
|
+
const _ = kr(o, M, S, b), P = M;
|
|
4387
|
+
return _.columns = P.columns ? f(P.columns, _, S + 1) : [], _;
|
|
4388
4388
|
});
|
|
4389
4389
|
};
|
|
4390
|
-
return
|
|
4390
|
+
return f(v);
|
|
4391
4391
|
}, Q(e, "debugColumns", "getAllColumns")),
|
|
4392
|
-
getAllFlatColumns: Z(() => [o.getAllColumns()], (v) => v.flatMap((
|
|
4393
|
-
_getAllFlatColumnsById: Z(() => [o.getAllFlatColumns()], (v) => v.reduce((
|
|
4394
|
-
getAllLeafColumns: Z(() => [o.getAllColumns(), o._getOrderColumnsFn()], (v,
|
|
4392
|
+
getAllFlatColumns: Z(() => [o.getAllColumns()], (v) => v.flatMap((f) => f.getFlatColumns()), Q(e, "debugColumns", "getAllFlatColumns")),
|
|
4393
|
+
_getAllFlatColumnsById: Z(() => [o.getAllFlatColumns()], (v) => v.reduce((f, h) => (f[h.id] = h, f), {}), Q(e, "debugColumns", "getAllFlatColumnsById")),
|
|
4394
|
+
getAllLeafColumns: Z(() => [o.getAllColumns(), o._getOrderColumnsFn()], (v, f) => {
|
|
4395
4395
|
let h = v.flatMap((b) => b.getLeafColumns());
|
|
4396
|
-
return
|
|
4396
|
+
return f(h);
|
|
4397
4397
|
}, Q(e, "debugColumns", "getAllLeafColumns")),
|
|
4398
4398
|
getColumn: (v) => {
|
|
4399
|
-
const
|
|
4400
|
-
return process.env.NODE_ENV !== "production" && !
|
|
4399
|
+
const f = o._getAllFlatColumnsById()[v];
|
|
4400
|
+
return process.env.NODE_ENV !== "production" && !f && console.error(`[Table] Column with id '${v}' does not exist.`), f;
|
|
4401
4401
|
}
|
|
4402
4402
|
};
|
|
4403
|
-
Object.assign(o,
|
|
4403
|
+
Object.assign(o, g);
|
|
4404
4404
|
for (let v = 0; v < o._features.length; v++) {
|
|
4405
|
-
const
|
|
4406
|
-
|
|
4405
|
+
const f = o._features[v];
|
|
4406
|
+
f == null || f.createTable == null || f.createTable(o);
|
|
4407
4407
|
}
|
|
4408
4408
|
return o;
|
|
4409
4409
|
}
|
|
@@ -4525,7 +4525,7 @@ function ds(e) {
|
|
|
4525
4525
|
immediate: !0
|
|
4526
4526
|
});
|
|
4527
4527
|
}
|
|
4528
|
-
const o =
|
|
4528
|
+
const o = D(l.initialState);
|
|
4529
4529
|
return Un(() => {
|
|
4530
4530
|
l.setOptions((r) => {
|
|
4531
4531
|
var a;
|
|
@@ -4554,7 +4554,7 @@ const cs = { class: "table-wrapper" }, fs = { class: "table__header" }, gs = ["c
|
|
|
4554
4554
|
class: "table__body"
|
|
4555
4555
|
}, ys = { class: "table__empty-row" }, ws = ["colspan"], bs = { class: "table__footer" }, Ss = ["colspan"], Cs = { class: "table__actions" }, $s = /* @__PURE__ */ q({
|
|
4556
4556
|
__name: "Table",
|
|
4557
|
-
props: {
|
|
4557
|
+
props: /* @__PURE__ */ se({
|
|
4558
4558
|
data: {},
|
|
4559
4559
|
columns: {},
|
|
4560
4560
|
size: { default: "medium" },
|
|
@@ -4563,25 +4563,28 @@ const cs = { class: "table-wrapper" }, fs = { class: "table__header" }, gs = ["c
|
|
|
4563
4563
|
enableSorting: { type: Boolean },
|
|
4564
4564
|
enableRowSelection: { type: Boolean },
|
|
4565
4565
|
rowId: {}
|
|
4566
|
-
},
|
|
4567
|
-
|
|
4566
|
+
}, {
|
|
4567
|
+
rowSelection: {},
|
|
4568
|
+
rowSelectionModifiers: {}
|
|
4569
|
+
}),
|
|
4570
|
+
emits: /* @__PURE__ */ se(["update:sort", "update:selected"], ["update:rowSelection"]),
|
|
4568
4571
|
setup(e, { emit: n }) {
|
|
4569
|
-
const t = n, l = br(), o =
|
|
4572
|
+
const t = n, l = br(), o = D(1), r = D(25), a = D([]), s = ue(e, "rowSelection"), i = T(() => {
|
|
4570
4573
|
let d = e.columns;
|
|
4571
4574
|
return e.enableRowSelection && (d = [
|
|
4572
4575
|
l.display({
|
|
4573
4576
|
id: "checkbox",
|
|
4574
|
-
header: ({ table:
|
|
4577
|
+
header: ({ table: g }) => Qt(Ue, {
|
|
4575
4578
|
size: "small",
|
|
4576
|
-
checked:
|
|
4577
|
-
indeterminate:
|
|
4578
|
-
onChange: (v,
|
|
4579
|
+
checked: g.getIsAllRowsSelected(),
|
|
4580
|
+
indeterminate: g.getIsSomeRowsSelected(),
|
|
4581
|
+
onChange: (v, f) => g.getToggleAllRowsSelectedHandler()(f)
|
|
4579
4582
|
}),
|
|
4580
|
-
cell: ({ row:
|
|
4583
|
+
cell: ({ row: g }) => g.original.isViewCheckbox || g.original.isViewCheckbox === void 0 ? Qt(Ue, {
|
|
4581
4584
|
size: "small",
|
|
4582
|
-
checked:
|
|
4583
|
-
disabled: !
|
|
4584
|
-
onChange: (v) =>
|
|
4585
|
+
checked: g.getIsSelected(),
|
|
4586
|
+
disabled: !g.getCanSelect(),
|
|
4587
|
+
onChange: (v) => g.getToggleSelectedHandler()(v)
|
|
4585
4588
|
}) : null
|
|
4586
4589
|
}),
|
|
4587
4590
|
...e.columns
|
|
@@ -4599,7 +4602,7 @@ const cs = { class: "table-wrapper" }, fs = { class: "table__header" }, gs = ["c
|
|
|
4599
4602
|
return s.value;
|
|
4600
4603
|
}
|
|
4601
4604
|
},
|
|
4602
|
-
getRowId: (d,
|
|
4605
|
+
getRowId: (d, g) => e.rowId ? d.data[e.rowId] : g,
|
|
4603
4606
|
getCoreRowModel: ss(),
|
|
4604
4607
|
//sorting
|
|
4605
4608
|
enableSorting: e.enableSorting,
|
|
@@ -4609,22 +4612,22 @@ const cs = { class: "table-wrapper" }, fs = { class: "table__header" }, gs = ["c
|
|
|
4609
4612
|
//selection
|
|
4610
4613
|
enableRowSelection: (d) => (d.original.isViewCheckbox || d.original.isViewCheckbox === void 0) && e.enableRowSelection,
|
|
4611
4614
|
onRowSelectionChange: (d) => {
|
|
4612
|
-
s.value = typeof d == "function" ? d(s.value) : d, t("update:selected", s.value);
|
|
4615
|
+
s.value = typeof d == "function" ? d(s.value || {}) : d, t("update:selected", s.value);
|
|
4613
4616
|
},
|
|
4614
|
-
debugTable: !
|
|
4617
|
+
debugTable: !1
|
|
4615
4618
|
});
|
|
4616
|
-
return (d,
|
|
4619
|
+
return (d, g) => {
|
|
4617
4620
|
const v = Fl("loading");
|
|
4618
4621
|
return m(), y("div", cs, [
|
|
4619
4622
|
Ce((m(), y("table", {
|
|
4620
4623
|
class: H(["table", `table--${d.size}`])
|
|
4621
4624
|
}, [
|
|
4622
4625
|
k("thead", fs, [
|
|
4623
|
-
(m(!0), y(le, null, ce($(u).getHeaderGroups(), (
|
|
4624
|
-
key:
|
|
4626
|
+
(m(!0), y(le, null, ce($(u).getHeaderGroups(), (f) => (m(), y("tr", {
|
|
4627
|
+
key: f.id,
|
|
4625
4628
|
class: "table__row table__row--header"
|
|
4626
4629
|
}, [
|
|
4627
|
-
(m(!0), y(le, null, ce(
|
|
4630
|
+
(m(!0), y(le, null, ce(f.headers, (h) => (m(), y("th", {
|
|
4628
4631
|
key: h.id,
|
|
4629
4632
|
colspan: h.colSpan,
|
|
4630
4633
|
scope: "col",
|
|
@@ -4653,11 +4656,12 @@ const cs = { class: "table-wrapper" }, fs = { class: "table__header" }, gs = ["c
|
|
|
4653
4656
|
]))), 128))
|
|
4654
4657
|
]),
|
|
4655
4658
|
d.data.length > 0 ? (m(), y("tbody", ps, [
|
|
4656
|
-
(m(!0), y(le, null, ce($(u).getRowModel().rows, (
|
|
4657
|
-
key:
|
|
4658
|
-
class: "table__row"
|
|
4659
|
+
(m(!0), y(le, null, ce($(u).getRowModel().rows, (f) => Ce((m(), y("tr", {
|
|
4660
|
+
key: f.id,
|
|
4661
|
+
class: "table__row",
|
|
4662
|
+
style: oe({ background: f.original.bgColor && f.original.viewBgColor ? f.original.bgColor : "transparent" })
|
|
4659
4663
|
}, [
|
|
4660
|
-
(m(!0), y(le, null, ce(
|
|
4664
|
+
(m(!0), y(le, null, ce(f.getVisibleCells(), (h) => (m(), y("td", {
|
|
4661
4665
|
key: h.id,
|
|
4662
4666
|
class: H(["table__cell", { "table__cell--selected": h.id.includes("checkbox") }])
|
|
4663
4667
|
}, [
|
|
@@ -4666,10 +4670,10 @@ const cs = { class: "table-wrapper" }, fs = { class: "table__header" }, gs = ["c
|
|
|
4666
4670
|
props: h.getContext()
|
|
4667
4671
|
}, null, 8, ["render", "props"])
|
|
4668
4672
|
], 2))), 128))
|
|
4669
|
-
])), [
|
|
4673
|
+
], 4)), [
|
|
4670
4674
|
[
|
|
4671
4675
|
v,
|
|
4672
|
-
|
|
4676
|
+
f.original.isLoading,
|
|
4673
4677
|
void 0,
|
|
4674
4678
|
{ xl: !0 }
|
|
4675
4679
|
]
|
|
@@ -4680,16 +4684,16 @@ const cs = { class: "table-wrapper" }, fs = { class: "table__header" }, gs = ["c
|
|
|
4680
4684
|
k("td", {
|
|
4681
4685
|
colspan: $(u).getAllColumns().length,
|
|
4682
4686
|
class: "table__empty"
|
|
4683
|
-
}, [...
|
|
4687
|
+
}, [...g[2] || (g[2] = [
|
|
4684
4688
|
k("span", { class: "table__empty-text" }, "Данные отсутствуют", -1)
|
|
4685
4689
|
])], 8, ws)
|
|
4686
4690
|
])
|
|
4687
4691
|
])) : F("", !0),
|
|
4688
4692
|
k("tfoot", bs, [
|
|
4689
|
-
(m(!0), y(le, null, ce($(u).getFooterGroups(), (
|
|
4690
|
-
key:
|
|
4693
|
+
(m(!0), y(le, null, ce($(u).getFooterGroups(), (f) => (m(), y("tr", {
|
|
4694
|
+
key: f.id
|
|
4691
4695
|
}, [
|
|
4692
|
-
(m(!0), y(le, null, ce(
|
|
4696
|
+
(m(!0), y(le, null, ce(f.headers, (h) => (m(), y("th", {
|
|
4693
4697
|
key: h.id,
|
|
4694
4698
|
colspan: h.colSpan,
|
|
4695
4699
|
scope: "row"
|
|
@@ -4714,9 +4718,9 @@ const cs = { class: "table-wrapper" }, fs = { class: "table__header" }, gs = ["c
|
|
|
4714
4718
|
d.paginator && d.paginator.enabled ? (m(), W($(pl), {
|
|
4715
4719
|
key: 0,
|
|
4716
4720
|
"current-page": o.value,
|
|
4717
|
-
"onUpdate:currentPage":
|
|
4721
|
+
"onUpdate:currentPage": g[0] || (g[0] = (f) => o.value = f),
|
|
4718
4722
|
"per-page": r.value,
|
|
4719
|
-
"onUpdate:perPage":
|
|
4723
|
+
"onUpdate:perPage": g[1] || (g[1] = (f) => r.value = f),
|
|
4720
4724
|
totals: d.paginator.totals ?? d.data.length,
|
|
4721
4725
|
"view-per-page": d.paginator.viewPerPage
|
|
4722
4726
|
}, null, 8, ["current-page", "per-page", "totals", "view-per-page"])) : F("", !0)
|
|
@@ -4724,7 +4728,7 @@ const cs = { class: "table-wrapper" }, fs = { class: "table__header" }, gs = ["c
|
|
|
4724
4728
|
]);
|
|
4725
4729
|
};
|
|
4726
4730
|
}
|
|
4727
|
-
}), md = /* @__PURE__ */ de($s, [["__scopeId", "data-v-
|
|
4731
|
+
}), md = /* @__PURE__ */ de($s, [["__scopeId", "data-v-07ea2160"]]), ks = { class: "chip-checkbox" }, Rs = ["name", "id", "value"], _s = { class: "chip-checkbox__text" }, pd = /* @__PURE__ */ q({
|
|
4728
4732
|
__name: "ChipCheckbox",
|
|
4729
4733
|
props: /* @__PURE__ */ se({
|
|
4730
4734
|
value: {},
|
|
@@ -4800,7 +4804,7 @@ const cs = { class: "table-wrapper" }, fs = { class: "table__header" }, gs = ["c
|
|
|
4800
4804
|
},
|
|
4801
4805
|
emits: ["update:modelValue", "search", "change", "clear", "remove-tag"],
|
|
4802
4806
|
setup(e, { emit: n }) {
|
|
4803
|
-
const t = e, l = n, o =
|
|
4807
|
+
const t = e, l = n, o = D(!1), r = D(!1), a = D(""), s = D(-1), i = D(), u = D(), d = D(), g = D({});
|
|
4804
4808
|
function v(V) {
|
|
4805
4809
|
let E = 1e3, U = V;
|
|
4806
4810
|
for (; U && U !== document.body; ) {
|
|
@@ -4809,7 +4813,7 @@ const cs = { class: "table-wrapper" }, fs = { class: "table__header" }, gs = ["c
|
|
|
4809
4813
|
}
|
|
4810
4814
|
return E;
|
|
4811
4815
|
}
|
|
4812
|
-
const
|
|
4816
|
+
const f = D(9999), h = T(() => {
|
|
4813
4817
|
if (!t.modelValue) return [];
|
|
4814
4818
|
if (t.multiple)
|
|
4815
4819
|
return (Array.isArray(t.modelValue) ? t.modelValue : [t.modelValue]).map((E) => {
|
|
@@ -4831,7 +4835,7 @@ const cs = { class: "table-wrapper" }, fs = { class: "table__header" }, gs = ["c
|
|
|
4831
4835
|
);
|
|
4832
4836
|
return V ? [V] : [];
|
|
4833
4837
|
}
|
|
4834
|
-
}), b = T(() => t.multiple ? h.value.length > 0 : !!t.modelValue), S = T(() => t.multiple && h.value.length > 0 ? "" : t.placeholder),
|
|
4838
|
+
}), b = T(() => t.multiple ? h.value.length > 0 : !!t.modelValue), S = T(() => t.multiple && h.value.length > 0 ? "" : t.placeholder), M = T(() => h.value.slice(0, t.maxTags)), _ = T(() => Math.max(0, h.value.length - t.maxTags)), P = T(() => t.options || []), O = T(() => t.multiple ? h.value.map((V) => C(V)) : []), I = T(() => t.multiple || !h.value.length ? null : C(h.value[0]));
|
|
4835
4839
|
function C(V) {
|
|
4836
4840
|
return t.valueKey && t.valueKey in V ? V[t.valueKey] : V.value || "";
|
|
4837
4841
|
}
|
|
@@ -4858,13 +4862,13 @@ const cs = { class: "table-wrapper" }, fs = { class: "table__header" }, gs = ["c
|
|
|
4858
4862
|
function z(V) {
|
|
4859
4863
|
if (!V.disabled) {
|
|
4860
4864
|
if (t.multiple) {
|
|
4861
|
-
const E = C(V), U = Array.isArray(t.modelValue) ? [...t.modelValue] : [], te = U.some((
|
|
4865
|
+
const E = C(V), U = Array.isArray(t.modelValue) ? [...t.modelValue] : [], te = U.some((ae) => typeof ae == "object" && ae !== null ? C(ae) === E : ae === E);
|
|
4862
4866
|
let Y;
|
|
4863
4867
|
if (te)
|
|
4864
|
-
Y = U.filter((
|
|
4868
|
+
Y = U.filter((ae) => typeof ae == "object" && ae !== null ? C(ae) !== E : ae !== E);
|
|
4865
4869
|
else {
|
|
4866
|
-
const
|
|
4867
|
-
Y = [...U,
|
|
4870
|
+
const ae = t.valueKey ? C(V) : V;
|
|
4871
|
+
Y = [...U, ae];
|
|
4868
4872
|
}
|
|
4869
4873
|
l("update:modelValue", Y), l("change", Y), a.value = "";
|
|
4870
4874
|
} else {
|
|
@@ -4895,15 +4899,15 @@ const cs = { class: "table-wrapper" }, fs = { class: "table__header" }, gs = ["c
|
|
|
4895
4899
|
function L() {
|
|
4896
4900
|
!i.value || !o.value || pe(() => {
|
|
4897
4901
|
const V = v(i.value);
|
|
4898
|
-
|
|
4899
|
-
const E = i.value.getBoundingClientRect(), U = window.innerHeight, te = window.innerWidth, Y = U - E.bottom,
|
|
4902
|
+
f.value = V + 10;
|
|
4903
|
+
const E = i.value.getBoundingClientRect(), U = window.innerHeight, te = window.innerWidth, Y = U - E.bottom, ae = E.top, xe = Y < 300 && ae > Y, re = Math.max(300, E.width);
|
|
4900
4904
|
let we = E.left;
|
|
4901
|
-
we +
|
|
4905
|
+
we + re > te && (we = Math.max(0, te - re - 10)), g.value = {
|
|
4902
4906
|
position: "fixed",
|
|
4903
4907
|
left: `${we}px`,
|
|
4904
|
-
width: `${
|
|
4908
|
+
width: `${re}px`,
|
|
4905
4909
|
maxHeight: "300px"
|
|
4906
|
-
}, xe ?
|
|
4910
|
+
}, xe ? g.value.bottom = `${U - E.top + 4}px` : g.value.top = `${E.bottom + 4}px`;
|
|
4907
4911
|
});
|
|
4908
4912
|
}
|
|
4909
4913
|
function J(V) {
|
|
@@ -4964,7 +4968,7 @@ const cs = { class: "table-wrapper" }, fs = { class: "table__header" }, gs = ["c
|
|
|
4964
4968
|
}, [
|
|
4965
4969
|
k("div", Ps, [
|
|
4966
4970
|
V.multiple && h.value.length ? (m(), y("div", Is, [
|
|
4967
|
-
(m(!0), y(le, null, ce(
|
|
4971
|
+
(m(!0), y(le, null, ce(M.value, (U) => (m(), W($(Dt), {
|
|
4968
4972
|
key: C(U),
|
|
4969
4973
|
removable: "",
|
|
4970
4974
|
variant: "secondary",
|
|
@@ -5015,14 +5019,14 @@ const cs = { class: "table-wrapper" }, fs = { class: "table__header" }, gs = ["c
|
|
|
5015
5019
|
], 2),
|
|
5016
5020
|
j($(At), {
|
|
5017
5021
|
show: o.value,
|
|
5018
|
-
"z-index":
|
|
5022
|
+
"z-index": f.value
|
|
5019
5023
|
}, {
|
|
5020
5024
|
default: ie(() => [
|
|
5021
5025
|
k("div", {
|
|
5022
5026
|
ref_key: "autocompleteOverlay",
|
|
5023
5027
|
ref: u,
|
|
5024
5028
|
class: "autocomplete__overlay",
|
|
5025
|
-
style:
|
|
5029
|
+
style: oe(g.value),
|
|
5026
5030
|
onClick: E[2] || (E[2] = he(() => {
|
|
5027
5031
|
}, ["stop"]))
|
|
5028
5032
|
}, [
|
|
@@ -5101,7 +5105,7 @@ const cs = { class: "table-wrapper" }, fs = { class: "table__header" }, gs = ["c
|
|
|
5101
5105
|
}),
|
|
5102
5106
|
emits: /* @__PURE__ */ se(["blur", "input", "paste", "focus", "clear"], ["update:modelValue"]),
|
|
5103
5107
|
setup(e, { emit: n }) {
|
|
5104
|
-
const t = n, l = ue(e, "modelValue"), o = T(() => (/* @__PURE__ */ new Date()).getTime().toString()), r =
|
|
5108
|
+
const t = n, l = ue(e, "modelValue"), o = T(() => (/* @__PURE__ */ new Date()).getTime().toString()), r = D(!1), a = T(() => [
|
|
5105
5109
|
"input",
|
|
5106
5110
|
`input--${e.size}`,
|
|
5107
5111
|
`input--${e.variant}`,
|
|
@@ -5131,7 +5135,7 @@ const cs = { class: "table-wrapper" }, fs = { class: "table__header" }, gs = ["c
|
|
|
5131
5135
|
], 8, zs)) : F("", !0),
|
|
5132
5136
|
k("div", Bs, [
|
|
5133
5137
|
Ce(k("input", {
|
|
5134
|
-
"onUpdate:modelValue": d[0] || (d[0] = (
|
|
5138
|
+
"onUpdate:modelValue": d[0] || (d[0] = (g) => l.value = g),
|
|
5135
5139
|
id: u.inputId ?? o.value,
|
|
5136
5140
|
placeholder: u.placeholder,
|
|
5137
5141
|
name: u.name,
|
|
@@ -5142,10 +5146,10 @@ const cs = { class: "table-wrapper" }, fs = { class: "table__header" }, gs = ["c
|
|
|
5142
5146
|
required: u.required,
|
|
5143
5147
|
readonly: u.readonly,
|
|
5144
5148
|
maxlength: u.maxlength,
|
|
5145
|
-
onBlur: d[1] || (d[1] = (
|
|
5146
|
-
onInput: d[2] || (d[2] = (
|
|
5147
|
-
onPaste: d[3] || (d[3] = (
|
|
5148
|
-
onFocus: d[4] || (d[4] = (
|
|
5149
|
+
onBlur: d[1] || (d[1] = (g) => t("blur", g)),
|
|
5150
|
+
onInput: d[2] || (d[2] = (g) => t("input", g)),
|
|
5151
|
+
onPaste: d[3] || (d[3] = (g) => t("paste", g)),
|
|
5152
|
+
onFocus: d[4] || (d[4] = (g) => t("focus", g))
|
|
5149
5153
|
}, null, 40, Gs), [
|
|
5150
5154
|
[El, l.value]
|
|
5151
5155
|
]),
|
|
@@ -5161,7 +5165,7 @@ const cs = { class: "table-wrapper" }, fs = { class: "table__header" }, gs = ["c
|
|
|
5161
5165
|
key: 1,
|
|
5162
5166
|
type: "button",
|
|
5163
5167
|
class: "input__eye",
|
|
5164
|
-
onClick: d[5] || (d[5] = he((
|
|
5168
|
+
onClick: d[5] || (d[5] = he((g) => r.value = !r.value, ["prevent"]))
|
|
5165
5169
|
}, [
|
|
5166
5170
|
r.value ? (m(), W($(eo), { key: 0 })) : (m(), W($(Kl), { key: 1 }))
|
|
5167
5171
|
])) : F("", !0)
|
|
@@ -5173,7 +5177,7 @@ const cs = { class: "table-wrapper" }, fs = { class: "table__header" }, gs = ["c
|
|
|
5173
5177
|
}
|
|
5174
5178
|
});
|
|
5175
5179
|
function js(e, n) {
|
|
5176
|
-
const { mask: t, slotChar: l = "_", autoClear: o = !0, definitions: r } = n, a =
|
|
5180
|
+
const { mask: t, slotChar: l = "_", autoClear: o = !0, definitions: r } = n, a = D(""), s = D(!1), i = {
|
|
5177
5181
|
9: /[0-9]/,
|
|
5178
5182
|
// только цифры
|
|
5179
5183
|
a: /[a-zA-Z]/,
|
|
@@ -5193,7 +5197,7 @@ function js(e, n) {
|
|
|
5193
5197
|
function d(C) {
|
|
5194
5198
|
return C in i;
|
|
5195
5199
|
}
|
|
5196
|
-
function
|
|
5200
|
+
function g(C, c) {
|
|
5197
5201
|
return d(c) ? i[c].test(C) : !1;
|
|
5198
5202
|
}
|
|
5199
5203
|
function v(C) {
|
|
@@ -5204,7 +5208,7 @@ function js(e, n) {
|
|
|
5204
5208
|
if (d(N))
|
|
5205
5209
|
if (A < C.length) {
|
|
5206
5210
|
const B = C[A];
|
|
5207
|
-
if (
|
|
5211
|
+
if (g(B, N))
|
|
5208
5212
|
x += B, A++;
|
|
5209
5213
|
else {
|
|
5210
5214
|
A++;
|
|
@@ -5218,7 +5222,7 @@ function js(e, n) {
|
|
|
5218
5222
|
}
|
|
5219
5223
|
return x;
|
|
5220
5224
|
}
|
|
5221
|
-
function
|
|
5225
|
+
function f() {
|
|
5222
5226
|
const { required: C, optional: c } = u(t);
|
|
5223
5227
|
return (C + c).replace(/[9a*]/g, l);
|
|
5224
5228
|
}
|
|
@@ -5231,7 +5235,7 @@ function js(e, n) {
|
|
|
5231
5235
|
A++;
|
|
5232
5236
|
continue;
|
|
5233
5237
|
}
|
|
5234
|
-
d(B) ?
|
|
5238
|
+
d(B) ? g(N, B) ? (x += N, A++, z++) : A++ : (N === B && A++, z++);
|
|
5235
5239
|
}
|
|
5236
5240
|
for (; A < C.length; ) {
|
|
5237
5241
|
const N = C[A];
|
|
@@ -5243,7 +5247,7 @@ function js(e, n) {
|
|
|
5243
5247
|
for (let R = 0; R < w.length; R++)
|
|
5244
5248
|
if (d(w[R])) {
|
|
5245
5249
|
if (X === x.length) {
|
|
5246
|
-
|
|
5250
|
+
g(N, w[R]) && (x += N, B = !0);
|
|
5247
5251
|
break;
|
|
5248
5252
|
}
|
|
5249
5253
|
X++;
|
|
@@ -5269,7 +5273,7 @@ function js(e, n) {
|
|
|
5269
5273
|
a.value = x;
|
|
5270
5274
|
}
|
|
5271
5275
|
}
|
|
5272
|
-
function
|
|
5276
|
+
function M(C) {
|
|
5273
5277
|
if (!C.isTrusted) return;
|
|
5274
5278
|
const c = C.target, p = c.value, w = h(p), x = v(w);
|
|
5275
5279
|
a.value = x, e.value = w, pe(() => {
|
|
@@ -5344,21 +5348,21 @@ function js(e, n) {
|
|
|
5344
5348
|
const J = a.value;
|
|
5345
5349
|
let V = "", E = -1;
|
|
5346
5350
|
const { required: U, optional: te } = u(t), Y = U + te;
|
|
5347
|
-
for (let
|
|
5348
|
-
if (
|
|
5349
|
-
E =
|
|
5351
|
+
for (let ae = p - 1; ae >= 0; ae--)
|
|
5352
|
+
if (ae < Y.length && d(Y[ae])) {
|
|
5353
|
+
E = ae;
|
|
5350
5354
|
break;
|
|
5351
5355
|
}
|
|
5352
5356
|
if (E >= 0) {
|
|
5353
|
-
let
|
|
5357
|
+
let ae = h(J), He = 0;
|
|
5354
5358
|
for (let xe = 0; xe <= E; xe++) {
|
|
5355
|
-
const { required:
|
|
5359
|
+
const { required: re, optional: we } = u(t), St = re + we;
|
|
5356
5360
|
if (xe < St.length && d(St[xe])) {
|
|
5357
5361
|
if (xe === E) break;
|
|
5358
5362
|
He++;
|
|
5359
5363
|
}
|
|
5360
5364
|
}
|
|
5361
|
-
|
|
5365
|
+
ae = ae.slice(0, He) + ae.slice(He + 1), V = v(ae), a.value = V, e.value = ae, pe(() => {
|
|
5362
5366
|
c.setSelectionRange(E, E);
|
|
5363
5367
|
});
|
|
5364
5368
|
}
|
|
@@ -5396,7 +5400,7 @@ function js(e, n) {
|
|
|
5396
5400
|
if (V >= 0) {
|
|
5397
5401
|
let E = h(J), U = 0;
|
|
5398
5402
|
for (let Y = 0; Y <= V; Y++) {
|
|
5399
|
-
const { required:
|
|
5403
|
+
const { required: ae, optional: He } = u(t), xe = ae + He;
|
|
5400
5404
|
if (Y < xe.length && d(xe[Y])) {
|
|
5401
5405
|
if (Y === V) break;
|
|
5402
5406
|
U++;
|
|
@@ -5427,7 +5431,7 @@ function js(e, n) {
|
|
|
5427
5431
|
}
|
|
5428
5432
|
X++;
|
|
5429
5433
|
}
|
|
5430
|
-
B >= 0 && !
|
|
5434
|
+
B >= 0 && !g(C.key, A[B]) && C.preventDefault();
|
|
5431
5435
|
}
|
|
5432
5436
|
function O(C) {
|
|
5433
5437
|
s.value = !0, pe(() => {
|
|
@@ -5462,12 +5466,12 @@ function js(e, n) {
|
|
|
5462
5466
|
C !== c && S();
|
|
5463
5467
|
}), {
|
|
5464
5468
|
displayValue: a,
|
|
5465
|
-
handleInput:
|
|
5469
|
+
handleInput: M,
|
|
5466
5470
|
handlePaste: _,
|
|
5467
5471
|
handleKeydown: P,
|
|
5468
5472
|
handleFocus: O,
|
|
5469
5473
|
handleBlur: I,
|
|
5470
|
-
placeholder:
|
|
5474
|
+
placeholder: f()
|
|
5471
5475
|
};
|
|
5472
5476
|
}
|
|
5473
5477
|
const yd = /* @__PURE__ */ q({
|
|
@@ -5500,9 +5504,9 @@ const yd = /* @__PURE__ */ q({
|
|
|
5500
5504
|
autoClear: n.autoClear,
|
|
5501
5505
|
definitions: n.definitions
|
|
5502
5506
|
});
|
|
5503
|
-
return (d,
|
|
5507
|
+
return (d, g) => (m(), W($(Sn), {
|
|
5504
5508
|
modelValue: $(l),
|
|
5505
|
-
"onUpdate:modelValue":
|
|
5509
|
+
"onUpdate:modelValue": g[0] || (g[0] = (v) => Yn(l) ? l.value = v : null),
|
|
5506
5510
|
label: d.label,
|
|
5507
5511
|
placeholder: $(u),
|
|
5508
5512
|
error: d.error,
|
|
@@ -5554,23 +5558,23 @@ const yd = /* @__PURE__ */ q({
|
|
|
5554
5558
|
}),
|
|
5555
5559
|
emits: /* @__PURE__ */ se(["change"], ["update:modelValue"]),
|
|
5556
5560
|
setup(e, { emit: n }) {
|
|
5557
|
-
const t = ue(e, "modelValue"), l = n, o =
|
|
5561
|
+
const t = ue(e, "modelValue"), l = n, o = D(
|
|
5558
5562
|
e.formatter ? e.formatter(t.value) : t.value
|
|
5559
5563
|
);
|
|
5560
5564
|
ee(t, (u) => {
|
|
5561
5565
|
o.value = e.formatter ? e.formatter(u) : u;
|
|
5562
5566
|
});
|
|
5563
5567
|
const r = (u) => {
|
|
5564
|
-
let
|
|
5565
|
-
if (console.log(
|
|
5568
|
+
let g = u.target.value;
|
|
5569
|
+
if (console.log(g), g.length === 0) {
|
|
5566
5570
|
const h = e.countInPackage || e.min;
|
|
5567
5571
|
t.value = h, l("change", h);
|
|
5568
5572
|
return;
|
|
5569
5573
|
}
|
|
5570
|
-
|
|
5571
|
-
let v = parseInt(
|
|
5572
|
-
const
|
|
5573
|
-
v <
|
|
5574
|
+
g = g.replace(/(?!^)-|[^\d-]/g, "");
|
|
5575
|
+
let v = parseInt(g);
|
|
5576
|
+
const f = e.countInPackage || e.min;
|
|
5577
|
+
v < f && (v = f), e.max && v > e.max && (v = e.max), e.countInPackage && v % e.countInPackage !== 0 && (v = Math.floor(v / e.countInPackage) * e.countInPackage + e.countInPackage), o.value = e.formatter ? e.formatter(v) : v, t.value = v, l("change", v);
|
|
5574
5578
|
}, a = () => {
|
|
5575
5579
|
if (e.max && t.value === e.max) return;
|
|
5576
5580
|
let u = e.countInPackage ? t.value + e.countInPackage : t.value + 1;
|
|
@@ -5607,7 +5611,7 @@ const yd = /* @__PURE__ */ q({
|
|
|
5607
5611
|
k("div", Ws, [
|
|
5608
5612
|
(m(), W(Fe(u.icon))),
|
|
5609
5613
|
Ce(k("input", {
|
|
5610
|
-
"onUpdate:modelValue": d[0] || (d[0] = (
|
|
5614
|
+
"onUpdate:modelValue": d[0] || (d[0] = (g) => o.value = g),
|
|
5611
5615
|
type: "number",
|
|
5612
5616
|
name: "input-number",
|
|
5613
5617
|
id: "input-number",
|
|
@@ -5780,7 +5784,7 @@ const yd = /* @__PURE__ */ q({
|
|
|
5780
5784
|
set(u) {
|
|
5781
5785
|
n.value = u;
|
|
5782
5786
|
}
|
|
5783
|
-
}), l = e, o =
|
|
5787
|
+
}), l = e, o = D(null), r = T(() => {
|
|
5784
5788
|
let u;
|
|
5785
5789
|
if (typeof l.size == "number")
|
|
5786
5790
|
u = l.size;
|
|
@@ -5809,23 +5813,23 @@ const yd = /* @__PURE__ */ q({
|
|
|
5809
5813
|
o.value = null;
|
|
5810
5814
|
};
|
|
5811
5815
|
return (u, d) => (m(), y("div", ni, [
|
|
5812
|
-
(m(!0), y(le, null, ce(u.maxStars, (
|
|
5813
|
-
key:
|
|
5816
|
+
(m(!0), y(le, null, ce(u.maxStars, (g) => (m(), y("button", {
|
|
5817
|
+
key: g,
|
|
5814
5818
|
type: "button",
|
|
5815
|
-
class: H(["star-button", { "star-button--active":
|
|
5816
|
-
onClick: (v) => a(
|
|
5817
|
-
onMouseenter: (v) => s(
|
|
5819
|
+
class: H(["star-button", { "star-button--active": g <= t.value }]),
|
|
5820
|
+
onClick: (v) => a(g),
|
|
5821
|
+
onMouseenter: (v) => s(g),
|
|
5818
5822
|
onMouseleave: i,
|
|
5819
5823
|
disabled: u.disabled
|
|
5820
5824
|
}, [
|
|
5821
|
-
|
|
5825
|
+
g <= (o.value ?? t.value) ? (m(), W(Nl, {
|
|
5822
5826
|
key: 0,
|
|
5823
5827
|
class: "star-icon star-icon--filled",
|
|
5824
|
-
style:
|
|
5828
|
+
style: oe(r.value)
|
|
5825
5829
|
}, null, 8, ["style"])) : (m(), W(jl, {
|
|
5826
5830
|
key: 1,
|
|
5827
5831
|
class: "star-icon star-icon--empty",
|
|
5828
|
-
style:
|
|
5832
|
+
style: oe(r.value)
|
|
5829
5833
|
}, null, 8, ["style"]))
|
|
5830
5834
|
], 42, li))), 128))
|
|
5831
5835
|
]));
|
|
@@ -5859,7 +5863,7 @@ const yd = /* @__PURE__ */ q({
|
|
|
5859
5863
|
}),
|
|
5860
5864
|
emits: /* @__PURE__ */ se(["focusIn", "focusOut", "blur"], ["update:modelValue"]),
|
|
5861
5865
|
setup(e, { emit: n }) {
|
|
5862
|
-
const t = n, l = ue(e, "modelValue"), o =
|
|
5866
|
+
const t = n, l = ue(e, "modelValue"), o = D(null), r = ht(), a = () => {
|
|
5863
5867
|
const i = o.value;
|
|
5864
5868
|
if (!i) return;
|
|
5865
5869
|
const u = {
|
|
@@ -5908,7 +5912,7 @@ const yd = /* @__PURE__ */ q({
|
|
|
5908
5912
|
rows: i.rows,
|
|
5909
5913
|
resizable: i.resizable,
|
|
5910
5914
|
cols: i.cols,
|
|
5911
|
-
style:
|
|
5915
|
+
style: oe({ minHeight: i.minHeight }),
|
|
5912
5916
|
onInput: a,
|
|
5913
5917
|
onFocusIn: u[1] || (u[1] = (d) => t("focusIn", d)),
|
|
5914
5918
|
onFocusOut: u[2] || (u[2] = (d) => t("focusOut", d)),
|
|
@@ -5949,8 +5953,8 @@ const yd = /* @__PURE__ */ q({
|
|
|
5949
5953
|
const a = [], s = n.interval;
|
|
5950
5954
|
for (let i = 0; i < 24; i++)
|
|
5951
5955
|
for (let u = 0; u < 60; u += s) {
|
|
5952
|
-
const d = i.toString().padStart(2, "0"),
|
|
5953
|
-
a.push({ value: v, label:
|
|
5956
|
+
const d = i.toString().padStart(2, "0"), g = u.toString().padStart(2, "0"), v = `${d}:${g}`, f = `${d}:${g}`;
|
|
5957
|
+
a.push({ value: v, label: f });
|
|
5954
5958
|
}
|
|
5955
5959
|
return a;
|
|
5956
5960
|
}, o = T(() => n.options || l()), r = () => {
|
|
@@ -6074,9 +6078,9 @@ function Zt(e, n, t, l) {
|
|
|
6074
6078
|
return o;
|
|
6075
6079
|
}
|
|
6076
6080
|
function hi(e, n, t, l = null, o = "dd/mm/yy", r = null, a = null, s = !1) {
|
|
6077
|
-
const i = [], u = fe().year(e).month(n).date(1), d = u.endOf("month"),
|
|
6078
|
-
for (let
|
|
6079
|
-
const h = u.subtract(
|
|
6081
|
+
const i = [], u = fe().year(e).month(n).date(1), d = u.endOf("month"), g = (u.day() + 6) % 7;
|
|
6082
|
+
for (let f = g - 1; f >= 0; f--) {
|
|
6083
|
+
const h = u.subtract(f + 1, "day"), b = Zt(h, l, o, s);
|
|
6080
6084
|
i.push({
|
|
6081
6085
|
value: rt(h, o),
|
|
6082
6086
|
label: h.format("D"),
|
|
@@ -6089,12 +6093,12 @@ function hi(e, n, t, l = null, o = "dd/mm/yy", r = null, a = null, s = !1) {
|
|
|
6089
6093
|
inRange: b.inRange
|
|
6090
6094
|
});
|
|
6091
6095
|
}
|
|
6092
|
-
for (let
|
|
6093
|
-
const h = fe().year(e).month(n).date(
|
|
6096
|
+
for (let f = 1; f <= d.date(); f++) {
|
|
6097
|
+
const h = fe().year(e).month(n).date(f), b = h.isSame(t, "day"), S = Zt(h, l, o, s), M = mi(h, r, a);
|
|
6094
6098
|
i.push({
|
|
6095
6099
|
value: rt(h, o),
|
|
6096
|
-
label: String(
|
|
6097
|
-
disabled: !
|
|
6100
|
+
label: String(f),
|
|
6101
|
+
disabled: !M,
|
|
6098
6102
|
// Отключаем даты вне разрешенного диапазона
|
|
6099
6103
|
current: b,
|
|
6100
6104
|
selected: S.selected,
|
|
@@ -6105,8 +6109,8 @@ function hi(e, n, t, l = null, o = "dd/mm/yy", r = null, a = null, s = !1) {
|
|
|
6105
6109
|
}
|
|
6106
6110
|
const v = d.day();
|
|
6107
6111
|
if (v !== 0) {
|
|
6108
|
-
const
|
|
6109
|
-
for (let h = 1; h <=
|
|
6112
|
+
const f = 7 - v;
|
|
6113
|
+
for (let h = 1; h <= f; h++) {
|
|
6110
6114
|
const b = d.add(h, "day"), S = Zt(b, l, o, s);
|
|
6111
6115
|
i.push({
|
|
6112
6116
|
value: rt(b, o),
|
|
@@ -6161,9 +6165,9 @@ function wi(e, n = "dd.mm.yyyy", t = null, l = null) {
|
|
|
6161
6165
|
}
|
|
6162
6166
|
return r;
|
|
6163
6167
|
}
|
|
6164
|
-
function bi(e, n, t =
|
|
6165
|
-
const a =
|
|
6166
|
-
a.value =
|
|
6168
|
+
function bi(e, n, t = D(fe().format("DD.MM.YYYY")), l = D(null), o = D(null), r = D(!1)) {
|
|
6169
|
+
const a = D(fe()), s = (f) => {
|
|
6170
|
+
a.value = f;
|
|
6167
6171
|
}, i = () => {
|
|
6168
6172
|
switch (e.value) {
|
|
6169
6173
|
case "day":
|
|
@@ -6190,20 +6194,20 @@ function bi(e, n, t = M(fe().format("DD.MM.YYYY")), l = M(null), o = M(null), r
|
|
|
6190
6194
|
}
|
|
6191
6195
|
}, d = () => {
|
|
6192
6196
|
a.value = fe();
|
|
6193
|
-
},
|
|
6194
|
-
const
|
|
6197
|
+
}, g = T(() => {
|
|
6198
|
+
const f = fe(), h = a.value.year(), b = a.value.month(), S = n.value || "dd.mm.yy";
|
|
6195
6199
|
switch (e.value) {
|
|
6196
6200
|
case "day":
|
|
6197
|
-
return hi(h, b,
|
|
6201
|
+
return hi(h, b, f, t.value, S, l.value, o.value, r.value);
|
|
6198
6202
|
case "month":
|
|
6199
|
-
return yi(h,
|
|
6203
|
+
return yi(h, f, S, l.value, o.value);
|
|
6200
6204
|
case "year":
|
|
6201
6205
|
return wi(a.value, S, l.value, o.value);
|
|
6202
6206
|
default:
|
|
6203
6207
|
return [];
|
|
6204
6208
|
}
|
|
6205
6209
|
}), v = T(() => {
|
|
6206
|
-
const
|
|
6210
|
+
const f = [
|
|
6207
6211
|
"Январь",
|
|
6208
6212
|
"Февраль",
|
|
6209
6213
|
"Март",
|
|
@@ -6216,15 +6220,15 @@ function bi(e, n, t = M(fe().format("DD.MM.YYYY")), l = M(null), o = M(null), r
|
|
|
6216
6220
|
"Октябрь",
|
|
6217
6221
|
"Ноябрь",
|
|
6218
6222
|
"Декабрь"
|
|
6219
|
-
], h = a.value, b = h.year(), S = h.month(),
|
|
6223
|
+
], h = a.value, b = h.year(), S = h.month(), M = b - 10, _ = M + 19;
|
|
6220
6224
|
return {
|
|
6221
|
-
month:
|
|
6225
|
+
month: f[S],
|
|
6222
6226
|
year: String(b),
|
|
6223
|
-
year_range: `${
|
|
6227
|
+
year_range: `${M}-${_}`
|
|
6224
6228
|
};
|
|
6225
6229
|
});
|
|
6226
6230
|
return {
|
|
6227
|
-
calendarCells:
|
|
6231
|
+
calendarCells: g,
|
|
6228
6232
|
activeDateInfo: v,
|
|
6229
6233
|
// Функции навигации
|
|
6230
6234
|
goToPreviousPage: i,
|
|
@@ -6256,11 +6260,11 @@ const Si = {
|
|
|
6256
6260
|
}),
|
|
6257
6261
|
emits: ["update:modelValue"],
|
|
6258
6262
|
setup(e) {
|
|
6259
|
-
const n = e, t = tt(n, "type"), l = tt(n, "format"), o = tt(n, "range"), r = tt(n, "minDate"), a = tt(n, "maxDate"), s = ue(e, "modelValue"), i =
|
|
6260
|
-
function
|
|
6263
|
+
const n = e, t = tt(n, "type"), l = tt(n, "format"), o = tt(n, "range"), r = tt(n, "minDate"), a = tt(n, "maxDate"), s = ue(e, "modelValue"), i = D(!1), u = D(""), d = D(g());
|
|
6264
|
+
function g() {
|
|
6261
6265
|
return t.value === "time" ? "time" : t.value || "day";
|
|
6262
6266
|
}
|
|
6263
|
-
const v = T(() => ["day", "month", "year", "date", "datetime"].includes(t.value || "day")),
|
|
6267
|
+
const v = T(() => ["day", "month", "year", "date", "datetime"].includes(t.value || "day")), f = T(() => ["time", "datetime"].includes(t.value || "day")), { calendarCells: h, activeDateInfo: b, goToPreviousPage: S, goToNextPage: M, setCurrentDate: _ } = bi(d, l, s, r, a, o);
|
|
6264
6268
|
ee([u, s], () => {
|
|
6265
6269
|
t.value === "datetime" && s.value && u.value ? typeof s.value == "string" && (s.value = `${s.value} ${u.value}`) : t.value === "time" && (s.value = u.value);
|
|
6266
6270
|
});
|
|
@@ -6354,7 +6358,7 @@ const Si = {
|
|
|
6354
6358
|
variant: "secondary",
|
|
6355
6359
|
"button-style": "outlined",
|
|
6356
6360
|
disabled: P.value === "month",
|
|
6357
|
-
onClick: $(
|
|
6361
|
+
onClick: $(M)
|
|
6358
6362
|
}, null, 8, ["icon", "disabled", "onClick"])
|
|
6359
6363
|
]),
|
|
6360
6364
|
k("div", Ri, [
|
|
@@ -6373,7 +6377,7 @@ const Si = {
|
|
|
6373
6377
|
])
|
|
6374
6378
|
])
|
|
6375
6379
|
])) : F("", !0),
|
|
6376
|
-
|
|
6380
|
+
f.value ? (m(), y("div", Pi, [
|
|
6377
6381
|
j(vi, {
|
|
6378
6382
|
modelValue: u.value,
|
|
6379
6383
|
"onUpdate:modelValue": p[2] || (p[2] = (w) => u.value = w)
|
|
@@ -6395,14 +6399,14 @@ class Di {
|
|
|
6395
6399
|
a.length > s && (a = a.slice(0, s)), a = this.correctDateValues(a, t);
|
|
6396
6400
|
let i = "", u = 0;
|
|
6397
6401
|
for (let d = 0; d < t.length && u < a.length; d++) {
|
|
6398
|
-
const
|
|
6399
|
-
|
|
6402
|
+
const g = t[d];
|
|
6403
|
+
g === "d" || g === "m" || g === "y" ? (i += a[u], u++) : i += g;
|
|
6400
6404
|
}
|
|
6401
6405
|
if (i.length >= t.length) {
|
|
6402
6406
|
const d = this.parseDate(i, t);
|
|
6403
6407
|
if (d && d.isValid()) {
|
|
6404
|
-
const
|
|
6405
|
-
|
|
6408
|
+
const g = this.applyDateLimits(i, t, l, o);
|
|
6409
|
+
g && (i = g);
|
|
6406
6410
|
}
|
|
6407
6411
|
}
|
|
6408
6412
|
r.value = i;
|
|
@@ -6454,8 +6458,8 @@ class Di {
|
|
|
6454
6458
|
if (!i || !u) return n;
|
|
6455
6459
|
const d = this.getDaysInMonth(u);
|
|
6456
6460
|
if (i > d) {
|
|
6457
|
-
const
|
|
6458
|
-
return n.substring(0, a) +
|
|
6461
|
+
const g = d.toString().padStart(2, "0");
|
|
6462
|
+
return n.substring(0, a) + g + n.substring(a + 2);
|
|
6459
6463
|
}
|
|
6460
6464
|
return n;
|
|
6461
6465
|
}
|
|
@@ -6563,9 +6567,9 @@ const Ti = /* @__PURE__ */ q({
|
|
|
6563
6567
|
return null;
|
|
6564
6568
|
}
|
|
6565
6569
|
}
|
|
6566
|
-
const o = new Di(), r = e, a = n, s = ue(e, "modelValue"), i =
|
|
6567
|
-
let
|
|
6568
|
-
const h =
|
|
6570
|
+
const o = new Di(), r = e, a = n, s = ue(e, "modelValue"), i = D(), u = D(), d = D(), g = D(!1), v = D({});
|
|
6571
|
+
let f = null;
|
|
6572
|
+
const h = D(s.value), { zIndex: b } = Xe("popover"), S = T(() => {
|
|
6569
6573
|
if (!s.value) return "";
|
|
6570
6574
|
if (typeof s.value == "string")
|
|
6571
6575
|
return s.value;
|
|
@@ -6582,7 +6586,7 @@ const Ti = /* @__PURE__ */ q({
|
|
|
6582
6586
|
return c.from || c.to || "";
|
|
6583
6587
|
}
|
|
6584
6588
|
return "";
|
|
6585
|
-
}),
|
|
6589
|
+
}), M = (c) => {
|
|
6586
6590
|
o.getDateMask(c, r.format);
|
|
6587
6591
|
const p = c.target;
|
|
6588
6592
|
if (!p.value) {
|
|
@@ -6597,15 +6601,15 @@ const Ti = /* @__PURE__ */ q({
|
|
|
6597
6601
|
}, _ = () => {
|
|
6598
6602
|
s.value = null, h.value = null, a("clear");
|
|
6599
6603
|
}, P = () => {
|
|
6600
|
-
h.value = s.value,
|
|
6601
|
-
u.value && d.value && (
|
|
6604
|
+
h.value = s.value, g.value = !0, pe(() => {
|
|
6605
|
+
u.value && d.value && (f = sa(
|
|
6602
6606
|
u.value,
|
|
6603
6607
|
d.value,
|
|
6604
6608
|
I
|
|
6605
6609
|
));
|
|
6606
6610
|
});
|
|
6607
6611
|
}, O = (c) => {
|
|
6608
|
-
c && (h.value = c, typeof c == "string" ? (s.value = c, c.length === r.format.length && !r.range && (
|
|
6612
|
+
c && (h.value = c, typeof c == "string" ? (s.value = c, c.length === r.format.length && !r.range && (g.value = !1)) : c instanceof Date ? (s.value = t(fe(c), r.format), r.range || (g.value = !1)) : typeof c == "object" && (r.range ? s.value = c : (s.value = c.from || c.to || null, typeof s.value == "string" && s.value.length === r.format.length && (g.value = !1))), a("select", c));
|
|
6609
6613
|
}, I = async () => {
|
|
6610
6614
|
if (!u.value || !d.value) return;
|
|
6611
6615
|
const { x: c, y: p } = await pn(
|
|
@@ -6628,7 +6632,7 @@ const Ti = /* @__PURE__ */ q({
|
|
|
6628
6632
|
}, C = (c) => {
|
|
6629
6633
|
if (!i.value || !d.value) return;
|
|
6630
6634
|
const p = c.target;
|
|
6631
|
-
!i.value.contains(p) && !d.value.contains(p) && (
|
|
6635
|
+
!i.value.contains(p) && !d.value.contains(p) && (g.value = !1, f && (f(), f = null));
|
|
6632
6636
|
};
|
|
6633
6637
|
return ee(
|
|
6634
6638
|
s,
|
|
@@ -6639,9 +6643,9 @@ const Ti = /* @__PURE__ */ q({
|
|
|
6639
6643
|
), ye(() => {
|
|
6640
6644
|
document.addEventListener("mousedown", C);
|
|
6641
6645
|
}), De(() => {
|
|
6642
|
-
document.removeEventListener("mousedown", C),
|
|
6643
|
-
}), ee(
|
|
6644
|
-
!c &&
|
|
6646
|
+
document.removeEventListener("mousedown", C), f && (f(), f = null);
|
|
6647
|
+
}), ee(g, (c) => {
|
|
6648
|
+
!c && f && (f(), f = null);
|
|
6645
6649
|
}), (c, p) => (m(), y("div", {
|
|
6646
6650
|
class: "date-picker",
|
|
6647
6651
|
ref_key: "datePickerRef",
|
|
@@ -6664,18 +6668,18 @@ const Ti = /* @__PURE__ */ q({
|
|
|
6664
6668
|
"allow-clear": c.allowClear,
|
|
6665
6669
|
"model-value": S.value,
|
|
6666
6670
|
readonly: c.range,
|
|
6667
|
-
onInput:
|
|
6671
|
+
onInput: M,
|
|
6668
6672
|
onClear: _,
|
|
6669
6673
|
onFocus: P
|
|
6670
6674
|
}, null, 8, ["label", "placeholder", "error", "error-text", "required", "disabled", "name", "allow-clear", "model-value", "readonly"])
|
|
6671
6675
|
], 512),
|
|
6672
6676
|
(m(), W(Ne, { to: "body" }, [
|
|
6673
|
-
|
|
6677
|
+
g.value ? (m(), y("div", {
|
|
6674
6678
|
key: 0,
|
|
6675
6679
|
ref_key: "popoverRef",
|
|
6676
6680
|
ref: d,
|
|
6677
6681
|
class: "date-picker__popover",
|
|
6678
|
-
style:
|
|
6682
|
+
style: oe({ ...v.value, zIndex: Math.max($(b)?.zIndex || 1100, 9999) })
|
|
6679
6683
|
}, [
|
|
6680
6684
|
k("div", {
|
|
6681
6685
|
onMousedown: p[1] || (p[1] = he(() => {
|
|
@@ -6723,7 +6727,7 @@ const Ti = /* @__PURE__ */ q({
|
|
|
6723
6727
|
}),
|
|
6724
6728
|
emits: /* @__PURE__ */ se(["change", "complete", "focus", "blur"], ["update:modelValue"]),
|
|
6725
6729
|
setup(e, { expose: n, emit: t }) {
|
|
6726
|
-
const l = e, o = t, r = ue(e, "modelValue"), a =
|
|
6730
|
+
const l = e, o = t, r = ue(e, "modelValue"), a = D([]), s = D([]), i = T(() => l.length);
|
|
6727
6731
|
ee(
|
|
6728
6732
|
() => r.value,
|
|
6729
6733
|
(b) => {
|
|
@@ -6749,11 +6753,11 @@ const Ti = /* @__PURE__ */ q({
|
|
|
6749
6753
|
"otp--error": l.error
|
|
6750
6754
|
}
|
|
6751
6755
|
]), d = (b, S) => {
|
|
6752
|
-
const
|
|
6753
|
-
_.length > 1 && (
|
|
6756
|
+
const M = S.target, _ = M.value;
|
|
6757
|
+
_.length > 1 && (M.value = _.slice(0, 1)), s.value[b] = M.value, M.value && b < i.value - 1 && pe(() => {
|
|
6754
6758
|
a.value[b + 1]?.focus();
|
|
6755
6759
|
});
|
|
6756
|
-
},
|
|
6760
|
+
}, g = (b, S) => {
|
|
6757
6761
|
S.key === "Backspace" && !s.value[b] && b > 0 && pe(() => {
|
|
6758
6762
|
a.value[b - 1]?.focus();
|
|
6759
6763
|
}), S.key === "ArrowLeft" && b > 0 && (S.preventDefault(), a.value[b - 1]?.focus()), S.key === "ArrowRight" && b < i.value - 1 && (S.preventDefault(), a.value[b + 1]?.focus());
|
|
@@ -6770,7 +6774,7 @@ const Ti = /* @__PURE__ */ q({
|
|
|
6770
6774
|
pe(() => {
|
|
6771
6775
|
a.value[P]?.focus();
|
|
6772
6776
|
});
|
|
6773
|
-
},
|
|
6777
|
+
}, f = (b) => {
|
|
6774
6778
|
o("focus", b);
|
|
6775
6779
|
}, h = (b) => {
|
|
6776
6780
|
o("blur", b);
|
|
@@ -6785,7 +6789,7 @@ const Ti = /* @__PURE__ */ q({
|
|
|
6785
6789
|
ve(" " + K(b.label), 1)
|
|
6786
6790
|
])) : F("", !0),
|
|
6787
6791
|
k("div", Ei, [
|
|
6788
|
-
(m(!0), y(le, null, ce(i.value, (
|
|
6792
|
+
(m(!0), y(le, null, ce(i.value, (M, _) => Ce((m(), y("input", {
|
|
6789
6793
|
key: _,
|
|
6790
6794
|
ref_for: !0,
|
|
6791
6795
|
ref_key: "inputRefs",
|
|
@@ -6800,9 +6804,9 @@ const Ti = /* @__PURE__ */ q({
|
|
|
6800
6804
|
inputmode: b.inputmode,
|
|
6801
6805
|
pattern: "[0-9]*",
|
|
6802
6806
|
onInput: (P) => d(_, P),
|
|
6803
|
-
onKeydown: (P) =>
|
|
6807
|
+
onKeydown: (P) => g(_, P),
|
|
6804
6808
|
onPaste: (P) => v(_, P),
|
|
6805
|
-
onFocus: (P) =>
|
|
6809
|
+
onFocus: (P) => f(_),
|
|
6806
6810
|
onBlur: (P) => h(_)
|
|
6807
6811
|
}, null, 40, Li)), [
|
|
6808
6812
|
[ut, s.value[_]]
|
|
@@ -6853,20 +6857,20 @@ const Ti = /* @__PURE__ */ q({
|
|
|
6853
6857
|
error: ze(Xl),
|
|
6854
6858
|
warn: ze(Yl),
|
|
6855
6859
|
info: ze(nl)
|
|
6856
|
-
}), o = T(() => e.msg.severity ? e.msg.icon ? e.msg.icon : l[e.msg.severity] : l.info), r = T(() => ["toast-message", `toast-message--${e.msg.severity}`]), a =
|
|
6860
|
+
}), o = T(() => e.msg.severity ? e.msg.icon ? e.msg.icon : l[e.msg.severity] : l.info), r = T(() => ["toast-message", `toast-message--${e.msg.severity}`]), a = D(null), s = D(void 0), i = () => {
|
|
6857
6861
|
a.value = setTimeout(() => {
|
|
6858
6862
|
u({ message: e.msg, type: "life-end" });
|
|
6859
6863
|
}, s.value);
|
|
6860
6864
|
}, u = (v) => {
|
|
6861
6865
|
t("close", v);
|
|
6862
6866
|
}, d = () => {
|
|
6863
|
-
|
|
6864
|
-
},
|
|
6867
|
+
g(), u({ message: e.msg, type: "close" });
|
|
6868
|
+
}, g = () => {
|
|
6865
6869
|
a.value && (clearTimeout(a.value), a.value = null);
|
|
6866
6870
|
};
|
|
6867
6871
|
return ye(() => {
|
|
6868
6872
|
e.msg.life && (s.value = e.msg.life, i());
|
|
6869
|
-
}), (v,
|
|
6873
|
+
}), (v, f) => (m(), y("div", {
|
|
6870
6874
|
class: H(r.value)
|
|
6871
6875
|
}, [
|
|
6872
6876
|
k("div", Gi, [
|
|
@@ -6897,10 +6901,10 @@ const Ti = /* @__PURE__ */ q({
|
|
|
6897
6901
|
},
|
|
6898
6902
|
setup(e) {
|
|
6899
6903
|
let n = 0;
|
|
6900
|
-
const t =
|
|
6904
|
+
const t = D([]), l = (u) => {
|
|
6901
6905
|
u.id == null && (u.id = n++), t.value = [...t.value, u];
|
|
6902
6906
|
}, o = (u) => {
|
|
6903
|
-
const d = t.value.findIndex((
|
|
6907
|
+
const d = t.value.findIndex((g) => g.id === u.message.id);
|
|
6904
6908
|
d !== -1 && t.value.splice(d, 1);
|
|
6905
6909
|
}, r = (u) => {
|
|
6906
6910
|
e.group == u.group && l(u);
|
|
@@ -6923,9 +6927,9 @@ const Ti = /* @__PURE__ */ q({
|
|
|
6923
6927
|
class: "toast-messages"
|
|
6924
6928
|
}, {
|
|
6925
6929
|
default: ie(() => [
|
|
6926
|
-
(m(!0), y(le, null, ce(t.value, (
|
|
6927
|
-
key:
|
|
6928
|
-
msg:
|
|
6930
|
+
(m(!0), y(le, null, ce(t.value, (g) => (m(), W(ji, {
|
|
6931
|
+
key: g.id,
|
|
6932
|
+
msg: g,
|
|
6929
6933
|
onClose: d[0] || (d[0] = (v) => o(v))
|
|
6930
6934
|
}, null, 8, ["msg"]))), 128))
|
|
6931
6935
|
]),
|
|
@@ -7042,7 +7046,7 @@ const Md = {
|
|
|
7042
7046
|
value: t.value,
|
|
7043
7047
|
variant: t.variant,
|
|
7044
7048
|
class: "overlay-badge__badge",
|
|
7045
|
-
style:
|
|
7049
|
+
style: oe(n.value)
|
|
7046
7050
|
}, null, 8, ["value", "variant", "style"])) : F("", !0),
|
|
7047
7051
|
ne(t.$slots, "default")
|
|
7048
7052
|
], 2));
|
|
@@ -7071,7 +7075,7 @@ const Md = {
|
|
|
7071
7075
|
}));
|
|
7072
7076
|
return (l, o) => (m(), y("div", {
|
|
7073
7077
|
class: H(n.value),
|
|
7074
|
-
style:
|
|
7078
|
+
style: oe(t.value)
|
|
7075
7079
|
}, null, 6));
|
|
7076
7080
|
}
|
|
7077
7081
|
}), xl = Symbol("DialogService"), Fd = () => {
|
|
@@ -7084,7 +7088,7 @@ const Md = {
|
|
|
7084
7088
|
if (!e)
|
|
7085
7089
|
throw new Error("useConfirmDialog() должен использоваться внутри приложения с DialogService");
|
|
7086
7090
|
return e;
|
|
7087
|
-
}, ge =
|
|
7091
|
+
}, ge = D(null), me = D(null), Ji = {
|
|
7088
7092
|
require: (e) => {
|
|
7089
7093
|
ge.value = {
|
|
7090
7094
|
modal: !0,
|
|
@@ -7147,14 +7151,14 @@ const Md = {
|
|
|
7147
7151
|
key: 0,
|
|
7148
7152
|
class: H(["confirm-dialog-overlay", { "confirm-dialog-overlay--modal": !0 }]),
|
|
7149
7153
|
onClick: a,
|
|
7150
|
-
style:
|
|
7154
|
+
style: oe({ zIndex: $(l)?.zIndex })
|
|
7151
7155
|
}, [
|
|
7152
7156
|
k("div", {
|
|
7153
7157
|
ref: "popupRef",
|
|
7154
7158
|
class: H(["confirm-dialog", [`confirm-dialog--${$(ge).position}`, $(ge).class]]),
|
|
7155
7159
|
onClick: u[2] || (u[2] = he(() => {
|
|
7156
7160
|
}, ["stop"])),
|
|
7157
|
-
style:
|
|
7161
|
+
style: oe($(ge).style)
|
|
7158
7162
|
}, [
|
|
7159
7163
|
$(ge).header ? (m(), y("div", tu, [
|
|
7160
7164
|
k("h4", nu, K($(ge).header), 1)
|
|
@@ -7198,14 +7202,14 @@ const Md = {
|
|
|
7198
7202
|
}, uu = { class: "confirm-popup__actions" }, du = /* @__PURE__ */ q({
|
|
7199
7203
|
__name: "ConfirmPopup",
|
|
7200
7204
|
setup(e) {
|
|
7201
|
-
const n =
|
|
7205
|
+
const n = D(), t = D({}), l = D("bottom"), { zIndex: o } = Xe("popover"), r = T(() => `confirm-popup--${l.value}`), a = T(() => `confirm-popup__arrow--${l.value}`), s = () => {
|
|
7202
7206
|
if (!me.value?.target || !n.value) return;
|
|
7203
|
-
const
|
|
7204
|
-
if (!document.contains(
|
|
7207
|
+
const f = me.value.target, h = n.value, b = me.value.position || "bottom";
|
|
7208
|
+
if (!document.contains(f)) {
|
|
7205
7209
|
u();
|
|
7206
7210
|
return;
|
|
7207
7211
|
}
|
|
7208
|
-
const S =
|
|
7212
|
+
const S = f.getBoundingClientRect();
|
|
7209
7213
|
if (!(S.bottom > 0 && S.right > 0 && S.top < window.innerHeight && S.left < window.innerWidth && S.width > 0 && S.height > 0)) {
|
|
7210
7214
|
u();
|
|
7211
7215
|
return;
|
|
@@ -7278,27 +7282,27 @@ const Md = {
|
|
|
7278
7282
|
me.value?.accept?.(), me.value = null;
|
|
7279
7283
|
}, u = () => {
|
|
7280
7284
|
me.value?.reject?.(), me.value = null;
|
|
7281
|
-
}, d = (
|
|
7282
|
-
|
|
7283
|
-
},
|
|
7285
|
+
}, d = (f) => {
|
|
7286
|
+
f.key === "Escape" && me.value && u();
|
|
7287
|
+
}, g = () => {
|
|
7284
7288
|
me.value?.target && s();
|
|
7285
7289
|
}, v = () => {
|
|
7286
7290
|
me.value?.target && s();
|
|
7287
7291
|
};
|
|
7288
|
-
return ee(me, async (
|
|
7289
|
-
|
|
7292
|
+
return ee(me, async (f) => {
|
|
7293
|
+
f?.target && (await pe(), s());
|
|
7290
7294
|
}, { immediate: !0 }), ye(() => {
|
|
7291
|
-
document.addEventListener("keydown", d), window.addEventListener("scroll",
|
|
7295
|
+
document.addEventListener("keydown", d), window.addEventListener("scroll", g, !0), window.addEventListener("resize", v);
|
|
7292
7296
|
}), De(() => {
|
|
7293
|
-
document.removeEventListener("keydown", d), window.removeEventListener("scroll",
|
|
7294
|
-
}), (
|
|
7297
|
+
document.removeEventListener("keydown", d), window.removeEventListener("scroll", g, !0), window.removeEventListener("resize", v);
|
|
7298
|
+
}), (f, h) => (m(), W(Ne, { to: "body" }, [
|
|
7295
7299
|
j(Te, { name: "confirm" }, {
|
|
7296
7300
|
default: ie(() => [
|
|
7297
7301
|
$(me) ? (m(), y("div", {
|
|
7298
7302
|
key: 0,
|
|
7299
7303
|
class: "confirm-overlay",
|
|
7300
7304
|
onClick: u,
|
|
7301
|
-
style:
|
|
7305
|
+
style: oe({ zIndex: $(o)?.zIndex })
|
|
7302
7306
|
}, [
|
|
7303
7307
|
k("div", {
|
|
7304
7308
|
ref_key: "popupRef",
|
|
@@ -7306,7 +7310,7 @@ const Md = {
|
|
|
7306
7310
|
class: H(["confirm-popup", r.value]),
|
|
7307
7311
|
onClick: h[0] || (h[0] = he(() => {
|
|
7308
7312
|
}, ["stop"])),
|
|
7309
|
-
style:
|
|
7313
|
+
style: oe(t.value)
|
|
7310
7314
|
}, [
|
|
7311
7315
|
k("div", {
|
|
7312
7316
|
class: H(["confirm-popup__arrow", a.value])
|
|
@@ -7368,8 +7372,8 @@ const Md = {
|
|
|
7368
7372
|
}), i = t, u = () => {
|
|
7369
7373
|
r.value = !0;
|
|
7370
7374
|
}, d = () => {
|
|
7371
|
-
e.beforeClose ? e.beforeClose(
|
|
7372
|
-
},
|
|
7375
|
+
e.beforeClose ? e.beforeClose(g) : g();
|
|
7376
|
+
}, g = () => {
|
|
7373
7377
|
r.value = !1, i("close");
|
|
7374
7378
|
};
|
|
7375
7379
|
return ee(r, () => {
|
|
@@ -7379,26 +7383,26 @@ const Md = {
|
|
|
7379
7383
|
}), n({
|
|
7380
7384
|
isOpen: r,
|
|
7381
7385
|
open: u,
|
|
7382
|
-
close:
|
|
7383
|
-
}), (v,
|
|
7386
|
+
close: g
|
|
7387
|
+
}), (v, f) => (m(), W(Ne, { to: "body" }, [
|
|
7384
7388
|
j(Te, { name: "drawer-animate" }, {
|
|
7385
7389
|
default: ie(() => [
|
|
7386
7390
|
r.value ? (m(), y("div", {
|
|
7387
7391
|
key: 0,
|
|
7388
7392
|
class: H(["drawer", { [`drawer--${v.position}`]: v.position }]),
|
|
7389
|
-
style:
|
|
7393
|
+
style: oe({ zIndex: $(a)?.zIndex })
|
|
7390
7394
|
}, [
|
|
7391
7395
|
k("div", {
|
|
7392
7396
|
class: "drawer-overlay",
|
|
7393
|
-
onClick:
|
|
7397
|
+
onClick: f[0] || (f[0] = (h) => d())
|
|
7394
7398
|
}),
|
|
7395
7399
|
k("div", {
|
|
7396
7400
|
class: H(["drawer-wrapper", { "drawer-wrapper--no-style": v.wrapperNoStyle }]),
|
|
7397
|
-
style:
|
|
7401
|
+
style: oe(s.value)
|
|
7398
7402
|
}, [
|
|
7399
7403
|
k("div", {
|
|
7400
7404
|
class: "drawer-close",
|
|
7401
|
-
onClick:
|
|
7405
|
+
onClick: f[1] || (f[1] = (h) => d())
|
|
7402
7406
|
}, [
|
|
7403
7407
|
k("button", null, [
|
|
7404
7408
|
j($(mt))
|
|
@@ -7410,7 +7414,7 @@ const Md = {
|
|
|
7410
7414
|
]),
|
|
7411
7415
|
k("div", gu, [
|
|
7412
7416
|
k("button", {
|
|
7413
|
-
onClick:
|
|
7417
|
+
onClick: f[2] || (f[2] = (h) => d())
|
|
7414
7418
|
}, [
|
|
7415
7419
|
j($(mt))
|
|
7416
7420
|
])
|
|
@@ -7440,7 +7444,7 @@ const Md = {
|
|
|
7440
7444
|
}),
|
|
7441
7445
|
emits: ["update:open"],
|
|
7442
7446
|
setup(e) {
|
|
7443
|
-
const { zIndex: n } = Xe("modal"), t =
|
|
7447
|
+
const { zIndex: n } = Xe("modal"), t = D(e.title), l = ue(e, "open"), o = Wn(), { unlockScroll: r, lockScroll: a } = yt(), s = T(() => ["modal", `modal--${e.position}`]), i = (u) => {
|
|
7444
7448
|
t.value = u;
|
|
7445
7449
|
};
|
|
7446
7450
|
return ee(
|
|
@@ -7455,15 +7459,15 @@ const Md = {
|
|
|
7455
7459
|
l.value ? (m(), y("div", {
|
|
7456
7460
|
key: 0,
|
|
7457
7461
|
class: H(s.value),
|
|
7458
|
-
style:
|
|
7462
|
+
style: oe({ zIndex: $(n)?.zIndex })
|
|
7459
7463
|
}, [
|
|
7460
7464
|
k("div", {
|
|
7461
7465
|
class: "modal__overlay",
|
|
7462
|
-
onClick: d[0] || (d[0] = (
|
|
7466
|
+
onClick: d[0] || (d[0] = (g) => u.closeOnClickModal ? l.value = !1 : void 0)
|
|
7463
7467
|
}),
|
|
7464
7468
|
k("div", {
|
|
7465
7469
|
class: "modal__content",
|
|
7466
|
-
style:
|
|
7470
|
+
style: oe(u.style)
|
|
7467
7471
|
}, [
|
|
7468
7472
|
k("div", vu, [
|
|
7469
7473
|
ne(u.$slots, "header"),
|
|
@@ -7471,7 +7475,7 @@ const Md = {
|
|
|
7471
7475
|
k("button", {
|
|
7472
7476
|
text: "",
|
|
7473
7477
|
class: "modal__header-close",
|
|
7474
|
-
onClick: d[1] || (d[1] = (
|
|
7478
|
+
onClick: d[1] || (d[1] = (g) => l.value = !1)
|
|
7475
7479
|
}, [
|
|
7476
7480
|
j($(dt))
|
|
7477
7481
|
])
|
|
@@ -7494,39 +7498,39 @@ const Md = {
|
|
|
7494
7498
|
},
|
|
7495
7499
|
emits: ["update:open"],
|
|
7496
7500
|
setup(e) {
|
|
7497
|
-
const n = ue(e, "open"), { zIndex: t } = Xe("modal"), l =
|
|
7501
|
+
const n = ue(e, "open"), { zIndex: t } = Xe("modal"), l = D(), o = D(), r = D(0), a = D(!1), s = D(0), i = D(0), u = D(0), d = D(0), g = D(!1), { unlockScroll: v, lockScroll: f } = yt(), h = () => {
|
|
7498
7502
|
n.value = !1;
|
|
7499
7503
|
}, b = (C) => {
|
|
7500
7504
|
if (!o.value) return;
|
|
7501
7505
|
s.value = C.touches[0].clientY, i.value = s.value, d.value = o.value.scrollTop;
|
|
7502
7506
|
const p = C.target.closest(".bottom-sheet__handle"), w = o.value.scrollTop === 0;
|
|
7503
|
-
|
|
7507
|
+
g.value = !!(p || w), g.value && (a.value = !0);
|
|
7504
7508
|
}, S = (C) => {
|
|
7505
|
-
if (!a.value || !
|
|
7509
|
+
if (!a.value || !g.value || !o.value) return;
|
|
7506
7510
|
i.value = C.touches[0].clientY;
|
|
7507
7511
|
const c = i.value - s.value;
|
|
7508
7512
|
if (o.value.scrollTop > 0 && c < 0) {
|
|
7509
|
-
a.value = !1,
|
|
7513
|
+
a.value = !1, g.value = !1, r.value = 0;
|
|
7510
7514
|
return;
|
|
7511
7515
|
}
|
|
7512
7516
|
o.value.scrollTop === 0 && c < 0 || c > 0 && (C.preventDefault(), r.value = c);
|
|
7513
|
-
},
|
|
7514
|
-
if (!a.value || !
|
|
7517
|
+
}, M = () => {
|
|
7518
|
+
if (!a.value || !g.value) return;
|
|
7515
7519
|
const C = u.value * 0.3;
|
|
7516
|
-
r.value > C && h(), r.value = 0, a.value = !1,
|
|
7520
|
+
r.value > C && h(), r.value = 0, a.value = !1, g.value = !1;
|
|
7517
7521
|
}, _ = (C) => {
|
|
7518
|
-
s.value = C.touches[0].clientY, i.value = s.value,
|
|
7522
|
+
s.value = C.touches[0].clientY, i.value = s.value, g.value = !0, a.value = !0;
|
|
7519
7523
|
}, P = (C) => {
|
|
7520
|
-
a.value = !0,
|
|
7524
|
+
a.value = !0, g.value = !0, s.value = C.clientY, i.value = s.value;
|
|
7521
7525
|
const c = (w) => {
|
|
7522
|
-
if (!a.value || !
|
|
7526
|
+
if (!a.value || !g.value) return;
|
|
7523
7527
|
i.value = w.clientY;
|
|
7524
7528
|
const x = i.value - s.value;
|
|
7525
7529
|
x > 0 && (w.preventDefault(), r.value = x);
|
|
7526
7530
|
}, p = () => {
|
|
7527
|
-
if (!a.value || !
|
|
7531
|
+
if (!a.value || !g.value) return;
|
|
7528
7532
|
const w = u.value * 0.3;
|
|
7529
|
-
r.value > w && h(), r.value = 0, a.value = !1,
|
|
7533
|
+
r.value > w && h(), r.value = 0, a.value = !1, g.value = !1, document.removeEventListener("mousemove", c), document.removeEventListener("mouseup", p);
|
|
7530
7534
|
};
|
|
7531
7535
|
document.addEventListener("mousemove", c), document.addEventListener("mouseup", p);
|
|
7532
7536
|
}, O = () => {
|
|
@@ -7539,7 +7543,7 @@ const Md = {
|
|
|
7539
7543
|
l.value && (l.value.removeEventListener("touchstart", b), l.value.removeEventListener("touchmove", S));
|
|
7540
7544
|
};
|
|
7541
7545
|
return ee(n, async (C) => {
|
|
7542
|
-
C ? (
|
|
7546
|
+
C ? (f(), await pe(), l.value && (u.value = l.value.offsetHeight, O())) : (v(), I(), r.value = 0);
|
|
7543
7547
|
}), ye(() => {
|
|
7544
7548
|
n.value && l.value && (u.value = l.value.offsetHeight, O());
|
|
7545
7549
|
}), De(() => {
|
|
@@ -7550,7 +7554,7 @@ const Md = {
|
|
|
7550
7554
|
n.value ? (m(), y("div", {
|
|
7551
7555
|
key: 0,
|
|
7552
7556
|
class: "bottom-sheet",
|
|
7553
|
-
style:
|
|
7557
|
+
style: oe({ zIndex: $(t)?.zIndex })
|
|
7554
7558
|
}, [
|
|
7555
7559
|
k("div", {
|
|
7556
7560
|
class: "bottom-sheet__overlay",
|
|
@@ -7563,8 +7567,8 @@ const Md = {
|
|
|
7563
7567
|
class: "bottom-sheet__content",
|
|
7564
7568
|
ref_key: "contentRef",
|
|
7565
7569
|
ref: l,
|
|
7566
|
-
style:
|
|
7567
|
-
onTouchend:
|
|
7570
|
+
style: oe({ transform: `translateY(${r.value}px)` }),
|
|
7571
|
+
onTouchend: M
|
|
7568
7572
|
}, [
|
|
7569
7573
|
k("div", {
|
|
7570
7574
|
class: "bottom-sheet__handle",
|
|
@@ -7599,7 +7603,7 @@ const Md = {
|
|
|
7599
7603
|
},
|
|
7600
7604
|
emits: ["update:value"],
|
|
7601
7605
|
setup(e, { emit: n }) {
|
|
7602
|
-
const t = n, l = T(() => e.styleView), o =
|
|
7606
|
+
const t = n, l = T(() => e.styleView), o = D(
|
|
7603
7607
|
Array.isArray(e.value) || e.value !== void 0 ? e.value : e.multiple ? [] : void 0
|
|
7604
7608
|
);
|
|
7605
7609
|
function r(a) {
|
|
@@ -7612,7 +7616,7 @@ const Md = {
|
|
|
7612
7616
|
}), qd = /* @__PURE__ */ q({
|
|
7613
7617
|
__name: "AccordionContent",
|
|
7614
7618
|
setup(e) {
|
|
7615
|
-
const n = Se("panelIsOpen"), t =
|
|
7619
|
+
const n = Se("panelIsOpen"), t = D(null), l = D("0px"), o = D(n.value);
|
|
7616
7620
|
return ee(n, async (r) => {
|
|
7617
7621
|
r ? (o.value = !0, await pe(), l.value = t.value?.scrollHeight + "px") : (l.value = t.value?.scrollHeight + "px", await pe(), l.value = "0px", setTimeout(() => o.value = !1, 300));
|
|
7618
7622
|
}), ye(() => {
|
|
@@ -7624,7 +7628,7 @@ const Md = {
|
|
|
7624
7628
|
}).observe(t.value);
|
|
7625
7629
|
}), (r, a) => (m(), y("div", {
|
|
7626
7630
|
class: "accordion-content-wrapper",
|
|
7627
|
-
style:
|
|
7631
|
+
style: oe({ height: $(n) ? l.value : "0px" })
|
|
7628
7632
|
}, [
|
|
7629
7633
|
Ce(k("div", {
|
|
7630
7634
|
ref_key: "contentRef",
|
|
@@ -7732,7 +7736,7 @@ const Md = {
|
|
|
7732
7736
|
},
|
|
7733
7737
|
emits: ["update:value"],
|
|
7734
7738
|
setup(e, { emit: n }) {
|
|
7735
|
-
const t = n, l =
|
|
7739
|
+
const t = n, l = D(e.value ?? 0);
|
|
7736
7740
|
return _e("stepper", {
|
|
7737
7741
|
isStepActive: (u) => l.value === u,
|
|
7738
7742
|
isStepDisabled: () => e.linear,
|
|
@@ -7741,16 +7745,16 @@ const Md = {
|
|
|
7741
7745
|
},
|
|
7742
7746
|
isLastItem: (u) => u === e.steps.length - 1,
|
|
7743
7747
|
isStepPassed: (u) => {
|
|
7744
|
-
const d = e.steps.findIndex((
|
|
7748
|
+
const d = e.steps.findIndex((g) => g.value === l.value);
|
|
7745
7749
|
return d === -1 ? l.value > u : d > u;
|
|
7746
7750
|
}
|
|
7747
7751
|
}), (u, d) => (m(), y("div", _u, [
|
|
7748
7752
|
k("div", xu, [
|
|
7749
|
-
(m(!0), y(le, null, ce(u.steps, (
|
|
7750
|
-
key:
|
|
7753
|
+
(m(!0), y(le, null, ce(u.steps, (g, v) => (m(), W(Ru, {
|
|
7754
|
+
key: g.value,
|
|
7751
7755
|
index: v,
|
|
7752
|
-
value:
|
|
7753
|
-
label:
|
|
7756
|
+
value: g.value,
|
|
7757
|
+
label: g.label
|
|
7754
7758
|
}, null, 8, ["index", "value", "label"]))), 128))
|
|
7755
7759
|
])
|
|
7756
7760
|
]));
|
|
@@ -7778,7 +7782,7 @@ const Md = {
|
|
|
7778
7782
|
},
|
|
7779
7783
|
emits: ["update:value"],
|
|
7780
7784
|
setup(e, { emit: n }) {
|
|
7781
|
-
const t = e, l = n, o =
|
|
7785
|
+
const t = e, l = n, o = D(t.value);
|
|
7782
7786
|
ee(() => t.value, (a) => {
|
|
7783
7787
|
o.value = a;
|
|
7784
7788
|
});
|
|
@@ -7836,13 +7840,13 @@ const Md = {
|
|
|
7836
7840
|
maxWidth: { default: 300 }
|
|
7837
7841
|
},
|
|
7838
7842
|
setup(e, { expose: n }) {
|
|
7839
|
-
const t = e, l =
|
|
7840
|
-
let u = null, d = null,
|
|
7843
|
+
const t = e, l = D(), o = D(!1), r = D("top"), a = D({}), s = D({}), { zIndex: i } = Xe("tooltip");
|
|
7844
|
+
let u = null, d = null, g = null;
|
|
7841
7845
|
const v = async () => {
|
|
7842
7846
|
if (!u || !l.value) return;
|
|
7843
7847
|
const b = l.value.querySelector(
|
|
7844
7848
|
".tooltip__arrow"
|
|
7845
|
-
), { x: S, y:
|
|
7849
|
+
), { x: S, y: M, placement: _, middlewareData: P } = await pn(
|
|
7846
7850
|
u,
|
|
7847
7851
|
l.value,
|
|
7848
7852
|
{
|
|
@@ -7857,7 +7861,7 @@ const Md = {
|
|
|
7857
7861
|
);
|
|
7858
7862
|
if (r.value = _, a.value = {
|
|
7859
7863
|
left: `${S}px`,
|
|
7860
|
-
top: `${
|
|
7864
|
+
top: `${M}px`
|
|
7861
7865
|
}, t.showArrow && P.arrow && b) {
|
|
7862
7866
|
const { x: O, y: I } = P.arrow, C = _.split("-")[0], c = {
|
|
7863
7867
|
top: "bottom",
|
|
@@ -7876,12 +7880,12 @@ const Md = {
|
|
|
7876
7880
|
};
|
|
7877
7881
|
return n({
|
|
7878
7882
|
show: (b) => {
|
|
7879
|
-
|
|
7883
|
+
g && (clearTimeout(g), g = null), u = b, d = setTimeout(async () => {
|
|
7880
7884
|
o.value = !0, await pe(), await v();
|
|
7881
7885
|
}, t.delay);
|
|
7882
7886
|
},
|
|
7883
7887
|
hide: () => {
|
|
7884
|
-
d && (clearTimeout(d), d = null),
|
|
7888
|
+
d && (clearTimeout(d), d = null), g = setTimeout(() => {
|
|
7885
7889
|
o.value = !1, u = null;
|
|
7886
7890
|
}, 50);
|
|
7887
7891
|
}
|
|
@@ -7893,17 +7897,17 @@ const Md = {
|
|
|
7893
7897
|
ref_key: "tooltipRef",
|
|
7894
7898
|
ref: l,
|
|
7895
7899
|
class: H(["tooltip", [`tooltip--${r.value}`, b.tooltipClass]]),
|
|
7896
|
-
style:
|
|
7900
|
+
style: oe({ ...a.value, zIndex: $(i)?.zIndex }),
|
|
7897
7901
|
role: "tooltip"
|
|
7898
7902
|
}, [
|
|
7899
7903
|
k("div", {
|
|
7900
7904
|
class: "tooltip__content",
|
|
7901
|
-
style:
|
|
7905
|
+
style: oe({ maxWidth: `${b.maxWidth}px` })
|
|
7902
7906
|
}, K(b.content), 5),
|
|
7903
7907
|
b.showArrow ? (m(), y("div", {
|
|
7904
7908
|
key: 0,
|
|
7905
7909
|
class: "tooltip__arrow",
|
|
7906
|
-
style:
|
|
7910
|
+
style: oe(s.value)
|
|
7907
7911
|
}, null, 4)) : F("", !0)
|
|
7908
7912
|
], 6)) : F("", !0)
|
|
7909
7913
|
]),
|
|
@@ -7969,7 +7973,7 @@ const Md = {
|
|
|
7969
7973
|
}),
|
|
7970
7974
|
emits: ["update:modelValue"],
|
|
7971
7975
|
setup(e) {
|
|
7972
|
-
const n = ue(e, "modelValue"), t =
|
|
7976
|
+
const n = ue(e, "modelValue"), t = D(!1), l = D(), o = D({}), r = D(), a = D(""), s = T(() => [
|
|
7973
7977
|
"time-select",
|
|
7974
7978
|
`time-select--${e.size}`,
|
|
7975
7979
|
{
|
|
@@ -8000,13 +8004,13 @@ const Md = {
|
|
|
8000
8004
|
function d() {
|
|
8001
8005
|
e.disabled || (t.value = !0);
|
|
8002
8006
|
}
|
|
8003
|
-
function
|
|
8007
|
+
function g() {
|
|
8004
8008
|
e.disabled || (t.value = !t.value);
|
|
8005
8009
|
}
|
|
8006
8010
|
function v(I) {
|
|
8007
8011
|
n.value = I, a.value = I, t.value = !1;
|
|
8008
8012
|
}
|
|
8009
|
-
function
|
|
8013
|
+
function f(I) {
|
|
8010
8014
|
let c = I.target.value;
|
|
8011
8015
|
c.endsWith(":") && c.length === 3 && (c = c.replace(":", ""));
|
|
8012
8016
|
const p = c.replace(/\D/g, "");
|
|
@@ -8041,7 +8045,7 @@ const Md = {
|
|
|
8041
8045
|
const [C, c] = I.split(":").map(Number);
|
|
8042
8046
|
return C * 60 + c;
|
|
8043
8047
|
}
|
|
8044
|
-
function
|
|
8048
|
+
function M(I) {
|
|
8045
8049
|
if ([
|
|
8046
8050
|
"Backspace",
|
|
8047
8051
|
"Delete",
|
|
@@ -8120,9 +8124,9 @@ const Md = {
|
|
|
8120
8124
|
class: "time-select__input",
|
|
8121
8125
|
placeholder: I.placeholder,
|
|
8122
8126
|
onClick: d,
|
|
8123
|
-
onInput:
|
|
8127
|
+
onInput: f,
|
|
8124
8128
|
onFocus: d,
|
|
8125
|
-
onKeydown:
|
|
8129
|
+
onKeydown: M,
|
|
8126
8130
|
onBlur: h,
|
|
8127
8131
|
maxlength: "5"
|
|
8128
8132
|
}, null, 40, zu), [
|
|
@@ -8132,7 +8136,7 @@ const Md = {
|
|
|
8132
8136
|
I.showCevron ? (m(), y("div", {
|
|
8133
8137
|
key: 0,
|
|
8134
8138
|
class: H(["time-select__arrow", { "time-select__arrow--rotated": t.value }]),
|
|
8135
|
-
onClick:
|
|
8139
|
+
onClick: g
|
|
8136
8140
|
}, [
|
|
8137
8141
|
j($(Tt))
|
|
8138
8142
|
], 2)) : F("", !0),
|
|
@@ -8155,7 +8159,7 @@ const Md = {
|
|
|
8155
8159
|
ref_key: "timePickerOverlay",
|
|
8156
8160
|
ref: l,
|
|
8157
8161
|
class: "time-select__overlay",
|
|
8158
|
-
style:
|
|
8162
|
+
style: oe(o.value),
|
|
8159
8163
|
onClick: C[2] || (C[2] = he(() => {
|
|
8160
8164
|
}, ["stop"]))
|
|
8161
8165
|
}, [
|
|
@@ -8251,7 +8255,7 @@ const Md = {
|
|
|
8251
8255
|
},
|
|
8252
8256
|
emits: ["update:modelValue", "change", "clear"],
|
|
8253
8257
|
setup(e, { expose: n, emit: t }) {
|
|
8254
|
-
const l = e, o = t, r =
|
|
8258
|
+
const l = e, o = t, r = D(!1), a = D(), s = D(), i = D({}), u = D({});
|
|
8255
8259
|
n({ errorTime: u });
|
|
8256
8260
|
const d = [
|
|
8257
8261
|
{
|
|
@@ -8296,7 +8300,7 @@ const Md = {
|
|
|
8296
8300
|
enabled: !1,
|
|
8297
8301
|
time: { from: "", to: "" }
|
|
8298
8302
|
}
|
|
8299
|
-
],
|
|
8303
|
+
], g = T(() => l.modelValue && l.modelValue.length > 0 ? l.modelValue : d);
|
|
8300
8304
|
ye(() => {
|
|
8301
8305
|
(!l.modelValue || l.modelValue.length === 0) && o("update:modelValue", d);
|
|
8302
8306
|
});
|
|
@@ -8308,30 +8312,30 @@ const Md = {
|
|
|
8308
8312
|
}
|
|
8309
8313
|
return p;
|
|
8310
8314
|
}
|
|
8311
|
-
const
|
|
8312
|
-
const c =
|
|
8315
|
+
const f = D(9999), h = T(() => {
|
|
8316
|
+
const c = g.value.filter((p) => p.enabled);
|
|
8313
8317
|
return c.length === 0 ? "" : c.length === 7 ? "Все дни недели" : c.map((p) => p.label).join(", ");
|
|
8314
|
-
}), b = T(() =>
|
|
8318
|
+
}), b = T(() => g.value.some((c) => c.enabled));
|
|
8315
8319
|
function S() {
|
|
8316
8320
|
l.disabled || (r.value = !r.value);
|
|
8317
8321
|
}
|
|
8318
|
-
function
|
|
8322
|
+
function M() {
|
|
8319
8323
|
r.value = !1;
|
|
8320
8324
|
}
|
|
8321
8325
|
function _(c) {
|
|
8322
|
-
const w =
|
|
8326
|
+
const w = g.value.map(
|
|
8323
8327
|
(x) => x.key === c ? { ...x, enabled: !x.enabled } : x
|
|
8324
8328
|
);
|
|
8325
8329
|
o("update:modelValue", w), o("change", w);
|
|
8326
8330
|
}
|
|
8327
8331
|
function P(c, p) {
|
|
8328
|
-
const w =
|
|
8332
|
+
const w = g.value.map(
|
|
8329
8333
|
(x) => x.key === c ? { ...x, time: p ?? { from: "", to: "" } } : x
|
|
8330
8334
|
);
|
|
8331
8335
|
o("update:modelValue", w), o("change", w);
|
|
8332
8336
|
}
|
|
8333
8337
|
function O() {
|
|
8334
|
-
const c =
|
|
8338
|
+
const c = g.value.map((p) => ({
|
|
8335
8339
|
...p,
|
|
8336
8340
|
enabled: !1,
|
|
8337
8341
|
time: { from: "", to: "" }
|
|
@@ -8341,7 +8345,7 @@ const Md = {
|
|
|
8341
8345
|
function I() {
|
|
8342
8346
|
!a.value || !r.value || pe(() => {
|
|
8343
8347
|
const c = v(a.value);
|
|
8344
|
-
|
|
8348
|
+
f.value = c + 10;
|
|
8345
8349
|
const p = a.value.getBoundingClientRect(), w = window.innerHeight, x = window.innerWidth, A = w - p.bottom, z = p.top, B = A < 400 && z > A, X = Math.max(300, p.width);
|
|
8346
8350
|
let R = p.left;
|
|
8347
8351
|
R + X > x && (R = Math.max(0, x - X - 10)), i.value = {
|
|
@@ -8399,26 +8403,26 @@ const Md = {
|
|
|
8399
8403
|
], 2),
|
|
8400
8404
|
j($(At), {
|
|
8401
8405
|
show: r.value,
|
|
8402
|
-
"z-index":
|
|
8406
|
+
"z-index": f.value
|
|
8403
8407
|
}, {
|
|
8404
8408
|
default: ie(() => [
|
|
8405
8409
|
k("div", {
|
|
8406
8410
|
ref_key: "scheduleOverlay",
|
|
8407
8411
|
ref: s,
|
|
8408
8412
|
class: "schedule__overlay",
|
|
8409
|
-
style:
|
|
8413
|
+
style: oe(i.value),
|
|
8410
8414
|
onClick: p[0] || (p[0] = he(() => {
|
|
8411
8415
|
}, ["stop"]))
|
|
8412
8416
|
}, [
|
|
8413
8417
|
k("div", ed, [
|
|
8414
8418
|
ne(c.$slots, "content", {
|
|
8415
|
-
close:
|
|
8416
|
-
days:
|
|
8419
|
+
close: M,
|
|
8420
|
+
days: g.value,
|
|
8417
8421
|
toggleDay: _,
|
|
8418
8422
|
updateDayTime: P
|
|
8419
8423
|
}, () => [
|
|
8420
8424
|
k("div", td, [
|
|
8421
|
-
(m(!0), y(le, null, ce(
|
|
8425
|
+
(m(!0), y(le, null, ce(g.value, (w) => (m(), y("div", {
|
|
8422
8426
|
key: w.key,
|
|
8423
8427
|
class: "schedule__day"
|
|
8424
8428
|
}, [
|