prlg-ui 1.8.108 → 1.8.110
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/prlg-ui.cjs.js +1 -1
- package/dist/prlg-ui.css +1 -1
- package/dist/prlg-ui.es.js +358 -344
- package/package.json +1 -1
package/dist/prlg-ui.es.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as Y, computed as
|
|
1
|
+
import { defineComponent as Y, computed as R, resolveComponent as ul, createBlock as U, openBlock as v, resolveDynamicComponent as Pe, normalizeClass as z, withCtx as oe, createCommentVNode as A, createElementBlock as p, renderSlot as J, Fragment as re, createTextVNode as ve, toDisplayString as j, ref as P, useTemplateRef as Ze, onMounted as he, createElementVNode as b, createVNode as K, renderList as ge, unref as k, mergeModels as ae, useModel as ie, withDirectives as be, vModelCheckbox as Mt, shallowRef as Oe, watch as ee, getCurrentScope as Ml, onScopeDispose as Al, shallowReadonly as Ye, toRefs as Ol, useId as nt, onUnmounted as Ve, Transition as Te, normalizeStyle as le, nextTick as fe, withModifiers as pe, vModelRadio as Bl, vModelText as ze, provide as _e, toRef as Ke, useSlots as cl, inject as ye, vModelDynamic as El, toValue as je, isRef as Ll, vModelSelect as Dl, createStaticVNode as zl, Teleport as Le, reactive as At, TransitionGroup as Hl, vShow as dl, createApp as Fl } from "vue";
|
|
2
2
|
import { P as fl, h as ql, i as Nl, I as vl, e as ct, C as bt, A as Wl, a as ml, f as Yl, M as jl, S as Kl, g as Ul, b as Zl, c as Ql, E as Xl, B as Gl, d as Jl, Q as en, W as Wt } from "./QuestionIcon-tK1kUB_h.js";
|
|
3
3
|
import { o as tn, d as se } from "./parseFileSize.util-CxVk4CvB.js";
|
|
4
4
|
import { _ as ue, C as et, a as ln } from "./FileIcon-maHE2Nhr.js";
|
|
@@ -24,7 +24,7 @@ const on = {
|
|
|
24
24
|
full: { type: Boolean }
|
|
25
25
|
},
|
|
26
26
|
setup(e) {
|
|
27
|
-
const l =
|
|
27
|
+
const l = R(() => e.variant === "link" && e.url || e.url ? ul("RouterLink") : "button"), t = R(() => [
|
|
28
28
|
"button",
|
|
29
29
|
`button--${e.size}`,
|
|
30
30
|
`button--${e.variant}`,
|
|
@@ -65,7 +65,7 @@ const on = {
|
|
|
65
65
|
size: { default: "default" }
|
|
66
66
|
},
|
|
67
67
|
setup(e) {
|
|
68
|
-
const l =
|
|
68
|
+
const l = P(!1), t = Ze("menuRef"), a = Ze("targetRef"), n = () => {
|
|
69
69
|
l.value = !l.value;
|
|
70
70
|
}, i = (o) => {
|
|
71
71
|
o.command && o.command(), l.value = !1;
|
|
@@ -143,7 +143,7 @@ const on = {
|
|
|
143
143
|
}),
|
|
144
144
|
emits: /* @__PURE__ */ ae(["change"], ["update:modelValue"]),
|
|
145
145
|
setup(e, { emit: l }) {
|
|
146
|
-
const t = l, a =
|
|
146
|
+
const t = l, a = R({
|
|
147
147
|
get() {
|
|
148
148
|
if (!e.indeterminate) {
|
|
149
149
|
if (e.trueValue && e.falseValue)
|
|
@@ -173,7 +173,7 @@ const on = {
|
|
|
173
173
|
else
|
|
174
174
|
n.value = s;
|
|
175
175
|
}
|
|
176
|
-
}), n = ie(e, "modelValue"), i =
|
|
176
|
+
}), n = ie(e, "modelValue"), i = R(() => Math.random().toString(36).substr(2, 9)), o = R(() => [
|
|
177
177
|
"checkbox",
|
|
178
178
|
`checkbox--${e.size}`,
|
|
179
179
|
{
|
|
@@ -229,7 +229,7 @@ const on = {
|
|
|
229
229
|
},
|
|
230
230
|
emits: ["updateSort"],
|
|
231
231
|
setup(e, { emit: l }) {
|
|
232
|
-
const t =
|
|
232
|
+
const t = P({
|
|
233
233
|
field: "",
|
|
234
234
|
order: null
|
|
235
235
|
}), a = l, n = () => {
|
|
@@ -423,7 +423,7 @@ const Pn = async (e, l, t) => {
|
|
|
423
423
|
} = s[$], {
|
|
424
424
|
x: _,
|
|
425
425
|
y: B,
|
|
426
|
-
data:
|
|
426
|
+
data: M,
|
|
427
427
|
reset: x
|
|
428
428
|
} = await O({
|
|
429
429
|
x: f,
|
|
@@ -443,7 +443,7 @@ const Pn = async (e, l, t) => {
|
|
|
443
443
|
...y,
|
|
444
444
|
[S]: {
|
|
445
445
|
...y[S],
|
|
446
|
-
...
|
|
446
|
+
...M
|
|
447
447
|
}
|
|
448
448
|
}, x && g <= 50 && (g++, typeof x == "object" && (x.placement && (h = x.placement), x.rects && (u = x.rects === !0 ? await o.getElementRects({
|
|
449
449
|
reference: e,
|
|
@@ -488,7 +488,7 @@ async function mt(e, l) {
|
|
|
488
488
|
y: n,
|
|
489
489
|
width: o.floating.width,
|
|
490
490
|
height: o.floating.height
|
|
491
|
-
} : o.reference, B = await (i.getOffsetParent == null ? void 0 : i.getOffsetParent(s.floating)),
|
|
491
|
+
} : o.reference, B = await (i.getOffsetParent == null ? void 0 : i.getOffsetParent(s.floating)), M = await (i.isElement == null ? void 0 : i.isElement(B)) ? await (i.getScale == null ? void 0 : i.getScale(B)) || {
|
|
492
492
|
x: 1,
|
|
493
493
|
y: 1
|
|
494
494
|
} : {
|
|
@@ -501,10 +501,10 @@ async function mt(e, l) {
|
|
|
501
501
|
strategy: r
|
|
502
502
|
}) : _);
|
|
503
503
|
return {
|
|
504
|
-
top: (O.top - x.top + g.top) /
|
|
505
|
-
bottom: (x.bottom - O.bottom + g.bottom) /
|
|
506
|
-
left: (O.left - x.left + g.left) /
|
|
507
|
-
right: (x.right - O.right + g.right) /
|
|
504
|
+
top: (O.top - x.top + g.top) / M.y,
|
|
505
|
+
bottom: (x.bottom - O.bottom + g.bottom) / M.y,
|
|
506
|
+
left: (O.left - x.left + g.left) / M.x,
|
|
507
|
+
right: (x.right - O.right + g.right) / M.x
|
|
508
508
|
};
|
|
509
509
|
}
|
|
510
510
|
const Rn = (e) => ({
|
|
@@ -528,10 +528,10 @@ const Rn = (e) => ({
|
|
|
528
528
|
const m = gl(f), h = {
|
|
529
529
|
x: t,
|
|
530
530
|
y: a
|
|
531
|
-
}, y = Bt(n), g = Ot(y), $ = await o.getDimensions(u), S = y === "y", O = S ? "top" : "left", _ = S ? "bottom" : "right", B = S ? "clientHeight" : "clientWidth",
|
|
531
|
+
}, y = Bt(n), g = Ot(y), $ = await o.getDimensions(u), S = y === "y", O = S ? "top" : "left", _ = S ? "bottom" : "right", B = S ? "clientHeight" : "clientWidth", M = i.reference[g] + i.reference[y] - h[y] - i.floating[g], x = h[y] - i.reference[y], d = await (o.getOffsetParent == null ? void 0 : o.getOffsetParent(u));
|
|
532
532
|
let c = d ? d[B] : 0;
|
|
533
533
|
(!c || !await (o.isElement == null ? void 0 : o.isElement(d))) && (c = s.floating[B] || i.floating[g]);
|
|
534
|
-
const w =
|
|
534
|
+
const w = M / 2 - x / 2, I = c / 2 - $[g] / 2 - 1, L = Ge(m[O], I), D = Ge(m[_], I), N = L, q = c - $[g] - D, F = c / 2 - $[g] / 2 + w, V = Tt(N, F, q), T = !r.arrow && st(n) != null && F !== V && i.reference[g] / 2 - (F < N ? L : D) - $[g] / 2 < 0, H = T ? F < N ? F - N : F - q : 0;
|
|
535
535
|
return {
|
|
536
536
|
[y]: h[y] + H,
|
|
537
537
|
data: {
|
|
@@ -568,38 +568,38 @@ const Rn = (e) => ({
|
|
|
568
568
|
} = tt(e, l);
|
|
569
569
|
if ((t = i.arrow) != null && t.alignmentOffset)
|
|
570
570
|
return {};
|
|
571
|
-
const O = He(n), _ = Be(s), B = He(s) === s,
|
|
572
|
-
!h && d && x.push(...Tn(s, $, g,
|
|
573
|
-
const c = [s, ...x], w = await mt(l, S),
|
|
574
|
-
let
|
|
575
|
-
if (f &&
|
|
576
|
-
const F = $n(n, o,
|
|
577
|
-
|
|
571
|
+
const O = He(n), _ = Be(s), B = He(s) === s, M = await (r.isRTL == null ? void 0 : r.isRTL(u.floating)), x = h || (B || !$ ? [ft(s)] : Sn(s)), d = g !== "none";
|
|
572
|
+
!h && d && x.push(...Tn(s, $, g, M));
|
|
573
|
+
const c = [s, ...x], w = await mt(l, S), I = [];
|
|
574
|
+
let L = ((a = i.flip) == null ? void 0 : a.overflows) || [];
|
|
575
|
+
if (f && I.push(w[O]), m) {
|
|
576
|
+
const F = $n(n, o, M);
|
|
577
|
+
I.push(w[F[0]], w[F[1]]);
|
|
578
578
|
}
|
|
579
|
-
if (
|
|
579
|
+
if (L = [...L, {
|
|
580
580
|
placement: n,
|
|
581
|
-
overflows:
|
|
582
|
-
}], !
|
|
583
|
-
var
|
|
584
|
-
const F = (((
|
|
581
|
+
overflows: I
|
|
582
|
+
}], !I.every((F) => F <= 0)) {
|
|
583
|
+
var D, N;
|
|
584
|
+
const F = (((D = i.flip) == null ? void 0 : D.index) || 0) + 1, V = c[F];
|
|
585
585
|
if (V && (!(m === "alignment" ? _ !== Be(V) : !1) || // We leave the current main axis only if every placement on that axis
|
|
586
586
|
// overflows the main axis.
|
|
587
|
-
|
|
587
|
+
L.every((Z) => Be(Z.placement) === _ ? Z.overflows[0] > 0 : !0)))
|
|
588
588
|
return {
|
|
589
589
|
data: {
|
|
590
590
|
index: F,
|
|
591
|
-
overflows:
|
|
591
|
+
overflows: L
|
|
592
592
|
},
|
|
593
593
|
reset: {
|
|
594
594
|
placement: V
|
|
595
595
|
}
|
|
596
596
|
};
|
|
597
|
-
let T = (N =
|
|
597
|
+
let T = (N = L.filter((H) => H.overflows[0] <= 0).sort((H, Z) => H.overflows[1] - Z.overflows[1])[0]) == null ? void 0 : N.placement;
|
|
598
598
|
if (!T)
|
|
599
599
|
switch (y) {
|
|
600
600
|
case "bestFit": {
|
|
601
601
|
var q;
|
|
602
|
-
const H = (q =
|
|
602
|
+
const H = (q = L.filter((Z) => {
|
|
603
603
|
if (d) {
|
|
604
604
|
const X = Be(Z.placement);
|
|
605
605
|
return X === _ || // Create a bias to the `y` side axis due to horizontal
|
|
@@ -949,8 +949,8 @@ function Fe(e, l, t, a) {
|
|
|
949
949
|
const h = we(i), y = a && Ce(a) ? we(a) : a;
|
|
950
950
|
let g = h, $ = Pt(g);
|
|
951
951
|
for (; $ && a && y !== g; ) {
|
|
952
|
-
const S = Qe($), O = $.getBoundingClientRect(), _ = xe($), B = O.left + ($.clientLeft + parseFloat(_.paddingLeft)) * S.x,
|
|
953
|
-
r *= S.x, u *= S.y, f *= S.x, m *= S.y, r += B, u +=
|
|
952
|
+
const S = Qe($), O = $.getBoundingClientRect(), _ = xe($), B = O.left + ($.clientLeft + parseFloat(_.paddingLeft)) * S.x, M = O.top + ($.clientTop + parseFloat(_.paddingTop)) * S.y;
|
|
953
|
+
r *= S.x, u *= S.y, f *= S.x, m *= S.y, r += B, u += M, g = we($), $ = Pt(g);
|
|
954
954
|
}
|
|
955
955
|
}
|
|
956
956
|
return vt({
|
|
@@ -1211,17 +1211,17 @@ function io(e, l) {
|
|
|
1211
1211
|
rootMargin: -g + "px " + -$ + "px " + -S + "px " + -O + "px",
|
|
1212
1212
|
threshold: De(0, Ge(1, r)) || 1
|
|
1213
1213
|
};
|
|
1214
|
-
let
|
|
1214
|
+
let M = !0;
|
|
1215
1215
|
function x(d) {
|
|
1216
1216
|
const c = d[0].intersectionRatio;
|
|
1217
1217
|
if (c !== r) {
|
|
1218
|
-
if (!
|
|
1218
|
+
if (!M)
|
|
1219
1219
|
return o();
|
|
1220
1220
|
c ? o(!1, c) : a = setTimeout(() => {
|
|
1221
1221
|
o(!1, 1e-7);
|
|
1222
1222
|
}, 1e3);
|
|
1223
1223
|
}
|
|
1224
|
-
c === 1 && !$l(u, e.getBoundingClientRect()) && o(),
|
|
1224
|
+
c === 1 && !$l(u, e.getBoundingClientRect()) && o(), M = !1;
|
|
1225
1225
|
}
|
|
1226
1226
|
try {
|
|
1227
1227
|
t = new IntersectionObserver(x, {
|
|
@@ -1320,19 +1320,19 @@ function tl(e, l) {
|
|
|
1320
1320
|
}
|
|
1321
1321
|
function ll(e, l, t) {
|
|
1322
1322
|
t === void 0 && (t = {});
|
|
1323
|
-
const a = t.whileElementsMounted, n =
|
|
1323
|
+
const a = t.whileElementsMounted, n = R(() => {
|
|
1324
1324
|
var c;
|
|
1325
1325
|
return (c = Ue(t.open)) != null ? c : !0;
|
|
1326
|
-
}), i =
|
|
1326
|
+
}), i = R(() => Ue(t.middleware)), o = R(() => {
|
|
1327
1327
|
var c;
|
|
1328
1328
|
return (c = Ue(t.placement)) != null ? c : "bottom";
|
|
1329
|
-
}), s =
|
|
1329
|
+
}), s = R(() => {
|
|
1330
1330
|
var c;
|
|
1331
1331
|
return (c = Ue(t.strategy)) != null ? c : "absolute";
|
|
1332
|
-
}), r =
|
|
1332
|
+
}), r = R(() => {
|
|
1333
1333
|
var c;
|
|
1334
1334
|
return (c = Ue(t.transform)) != null ? c : !0;
|
|
1335
|
-
}), u =
|
|
1335
|
+
}), u = R(() => Rt(e.value)), f = R(() => Rt(l.value)), m = P(0), h = P(0), y = P(s.value), g = P(o.value), $ = Oe({}), S = P(!1), O = R(() => {
|
|
1336
1336
|
const c = {
|
|
1337
1337
|
position: y.value,
|
|
1338
1338
|
left: "0",
|
|
@@ -1340,17 +1340,17 @@ function ll(e, l, t) {
|
|
|
1340
1340
|
};
|
|
1341
1341
|
if (!f.value)
|
|
1342
1342
|
return c;
|
|
1343
|
-
const w = tl(f.value, m.value),
|
|
1343
|
+
const w = tl(f.value, m.value), I = tl(f.value, h.value);
|
|
1344
1344
|
return r.value ? {
|
|
1345
1345
|
...c,
|
|
1346
|
-
transform: "translate(" + w + "px, " +
|
|
1346
|
+
transform: "translate(" + w + "px, " + I + "px)",
|
|
1347
1347
|
...xl(f.value) >= 1.5 && {
|
|
1348
1348
|
willChange: "transform"
|
|
1349
1349
|
}
|
|
1350
1350
|
} : {
|
|
1351
1351
|
position: y.value,
|
|
1352
1352
|
left: w + "px",
|
|
1353
|
-
top:
|
|
1353
|
+
top: I + "px"
|
|
1354
1354
|
};
|
|
1355
1355
|
});
|
|
1356
1356
|
let _;
|
|
@@ -1366,11 +1366,11 @@ function ll(e, l, t) {
|
|
|
1366
1366
|
m.value = w.x, h.value = w.y, y.value = w.strategy, g.value = w.placement, $.value = w.middlewareData, S.value = c !== !1;
|
|
1367
1367
|
});
|
|
1368
1368
|
}
|
|
1369
|
-
function
|
|
1369
|
+
function M() {
|
|
1370
1370
|
typeof _ == "function" && (_(), _ = void 0);
|
|
1371
1371
|
}
|
|
1372
1372
|
function x() {
|
|
1373
|
-
if (
|
|
1373
|
+
if (M(), a === void 0) {
|
|
1374
1374
|
B();
|
|
1375
1375
|
return;
|
|
1376
1376
|
}
|
|
@@ -1388,7 +1388,7 @@ function ll(e, l, t) {
|
|
|
1388
1388
|
flush: "sync"
|
|
1389
1389
|
}), ee(n, d, {
|
|
1390
1390
|
flush: "sync"
|
|
1391
|
-
}), Ml() && Al(
|
|
1391
|
+
}), Ml() && Al(M), {
|
|
1392
1392
|
x: Ye(m),
|
|
1393
1393
|
y: Ye(h),
|
|
1394
1394
|
strategy: Ye(y),
|
|
@@ -1434,14 +1434,14 @@ const vo = {
|
|
|
1434
1434
|
},
|
|
1435
1435
|
emits: ["update:modelValue"],
|
|
1436
1436
|
setup(e, { expose: l, emit: t }) {
|
|
1437
|
-
const a = e, { placement: n, offset: i, arrowVisible: o, closeMode: s, modelValue: r } = Ol(a), u = t, f = Ze("reference"), m = Ze("floating"), h = Ze("arrow-block"), y = Ze("second-screen"), g =
|
|
1437
|
+
const a = e, { placement: n, offset: i, arrowVisible: o, closeMode: s, modelValue: r } = Ol(a), u = t, f = Ze("reference"), m = Ze("floating"), h = Ze("arrow-block"), y = Ze("second-screen"), g = R(() => "23px"), $ = R(() => i ? typeof i.value == "number" ? i.value + Number(g.value.split("px")[0]) : {
|
|
1438
1438
|
mainAxis: i.value?.mainAxis ? i.value?.mainAxis + Number(g.value.split("px")[0]) / 2 : Number(g.value.split("px")[0]) / 2,
|
|
1439
1439
|
crossAxis: i.value?.crossAxis ? n.value?.includes("start") ? i.value?.crossAxis - Number(g.value.split("px")[0]) : n.value?.includes("end") ? i.value?.crossAxis + Number(g.value.split("px")[0]) : i.value?.crossAxis : n.value?.includes("start") ? -Number(g.value.split("px")[0]) : n.value?.includes("end") ? Number(g.value.split("px")[0]) : void 0,
|
|
1440
1440
|
alignmentAxis: i.value?.alignmentAxis
|
|
1441
1441
|
} : {
|
|
1442
1442
|
mainAxis: Number(g.value.split("px")[0]) / 2,
|
|
1443
1443
|
crossAxis: n.value?.includes("start") ? -Number(g.value.split("px")[0]) : n.value?.includes("end") ? Number(g.value.split("px")[0]) : void 0
|
|
1444
|
-
}), S =
|
|
1444
|
+
}), S = P([
|
|
1445
1445
|
el(),
|
|
1446
1446
|
gt({ padding: 8, crossAxis: !1, mainAxis: !0 }),
|
|
1447
1447
|
pt($.value),
|
|
@@ -1450,19 +1450,19 @@ const vo = {
|
|
|
1450
1450
|
floatingStyles: O,
|
|
1451
1451
|
middlewareData: _,
|
|
1452
1452
|
update: B,
|
|
1453
|
-
placement:
|
|
1453
|
+
placement: M
|
|
1454
1454
|
} = ll(f, m, {
|
|
1455
1455
|
placement: n.value,
|
|
1456
1456
|
middleware: S
|
|
1457
|
-
}), x =
|
|
1457
|
+
}), x = P("left-start"), { floatingStyles: d, update: c } = ll(m, y, {
|
|
1458
1458
|
placement: x,
|
|
1459
1459
|
middleware: [el(), gt({ padding: 8 }), pt(8)]
|
|
1460
|
-
}), w = nt(),
|
|
1461
|
-
B(),
|
|
1462
|
-
}, H =
|
|
1463
|
-
get: () => H.value ? r?.value :
|
|
1460
|
+
}), w = nt(), I = P(!1), L = P(!1), D = P(!1), { lockScroll: N, unlockScroll: q } = ot(), F = P(null), V = P(null), T = () => {
|
|
1461
|
+
B(), L.value && c();
|
|
1462
|
+
}, H = R(() => r && r.value !== void 0), Z = R({
|
|
1463
|
+
get: () => H.value ? r?.value : I.value,
|
|
1464
1464
|
set: (te) => {
|
|
1465
|
-
H.value ? u("update:modelValue", te) :
|
|
1465
|
+
H.value ? u("update:modelValue", te) : I.value = te;
|
|
1466
1466
|
}
|
|
1467
1467
|
}), X = () => {
|
|
1468
1468
|
Z.value = !0;
|
|
@@ -1473,25 +1473,25 @@ const vo = {
|
|
|
1473
1473
|
}, W = () => {
|
|
1474
1474
|
H.value ? X() : E();
|
|
1475
1475
|
}, G = async (te) => {
|
|
1476
|
-
te && te.stopPropagation(), m.value && (
|
|
1476
|
+
te && te.stopPropagation(), m.value && (L.value = !0);
|
|
1477
1477
|
}, Q = () => {
|
|
1478
|
-
|
|
1478
|
+
L.value = !1;
|
|
1479
1479
|
}, ne = (te) => {
|
|
1480
1480
|
if (s.value === "button-only") return;
|
|
1481
1481
|
const me = te.composedPath();
|
|
1482
1482
|
if (!(y.value && me.includes(y.value))) {
|
|
1483
1483
|
if (m.value && me.includes(m.value) || f.value && me.includes(f.value)) {
|
|
1484
1484
|
setTimeout(() => {
|
|
1485
|
-
|
|
1485
|
+
L.value && Q();
|
|
1486
1486
|
}, 0);
|
|
1487
1487
|
return;
|
|
1488
1488
|
}
|
|
1489
1489
|
C();
|
|
1490
1490
|
}
|
|
1491
|
-
}, Ae =
|
|
1491
|
+
}, Ae = R(() => {
|
|
1492
1492
|
if (!_.value.arrow) return {};
|
|
1493
1493
|
const { x: te, y: me } = _.value.arrow;
|
|
1494
|
-
switch (
|
|
1494
|
+
switch (M.value) {
|
|
1495
1495
|
case "top":
|
|
1496
1496
|
return {
|
|
1497
1497
|
left: te ? `${te}px` : "-9px",
|
|
@@ -1510,12 +1510,12 @@ const vo = {
|
|
|
1510
1510
|
}), ee(
|
|
1511
1511
|
Z,
|
|
1512
1512
|
async (te) => {
|
|
1513
|
-
te || (Q(),
|
|
1514
|
-
T(),
|
|
1513
|
+
te || (Q(), D.value = !1), te && s.value === "button-only" ? (N(), setTimeout(() => {
|
|
1514
|
+
T(), D.value = !0;
|
|
1515
1515
|
}, 0)) : !te && s.value === "button-only" ? (q(), setTimeout(() => {
|
|
1516
1516
|
T();
|
|
1517
1517
|
}, 0)) : te && setTimeout(() => {
|
|
1518
|
-
T(),
|
|
1518
|
+
T(), D.value = !0;
|
|
1519
1519
|
}, 0);
|
|
1520
1520
|
},
|
|
1521
1521
|
{ immediate: !0 }
|
|
@@ -1563,7 +1563,7 @@ const vo = {
|
|
|
1563
1563
|
T();
|
|
1564
1564
|
},
|
|
1565
1565
|
isOpen: Z,
|
|
1566
|
-
isSecondScreenOpen:
|
|
1566
|
+
isSecondScreenOpen: L
|
|
1567
1567
|
}), (te, me) => (v(), p("div", {
|
|
1568
1568
|
class: z(["popover", { "popover--with-arrow": k(o) }])
|
|
1569
1569
|
}, [
|
|
@@ -1588,7 +1588,7 @@ const vo = {
|
|
|
1588
1588
|
class: z(["popover__wrapper", [
|
|
1589
1589
|
`popover__wrapper--${k(w)}`,
|
|
1590
1590
|
{ "popover__wrapper--no-style": e.withoutStyle },
|
|
1591
|
-
{ "popover__wrapper--positioning": !
|
|
1591
|
+
{ "popover__wrapper--positioning": !D.value }
|
|
1592
1592
|
]]),
|
|
1593
1593
|
style: le({ ...k(O) }),
|
|
1594
1594
|
ref: "floating"
|
|
@@ -1619,7 +1619,7 @@ const vo = {
|
|
|
1619
1619
|
}),
|
|
1620
1620
|
K(Te, { name: "slide" }, {
|
|
1621
1621
|
default: oe(() => [
|
|
1622
|
-
|
|
1622
|
+
L.value ? (v(), p("div", {
|
|
1623
1623
|
key: 0,
|
|
1624
1624
|
class: "popover__second-screen",
|
|
1625
1625
|
ref: "second-screen",
|
|
@@ -1673,7 +1673,7 @@ const vo = {
|
|
|
1673
1673
|
},
|
|
1674
1674
|
emits: ["update:sort", "selectAllRow"],
|
|
1675
1675
|
setup(e, { emit: l }) {
|
|
1676
|
-
const t = l, a =
|
|
1676
|
+
const t = l, a = R(() => [
|
|
1677
1677
|
"table-header",
|
|
1678
1678
|
`table-header--${e.size}`
|
|
1679
1679
|
]), n = (o) => [
|
|
@@ -1730,7 +1730,7 @@ const vo = {
|
|
|
1730
1730
|
},
|
|
1731
1731
|
emits: ["toggleRow"],
|
|
1732
1732
|
setup(e, { emit: l }) {
|
|
1733
|
-
const t = l, a =
|
|
1733
|
+
const t = l, a = R(() => Array.isArray(e.selectedRows) ? e.selectedRows.includes(e.item) : e.selectedRows === e.item), n = R(() => [
|
|
1734
1734
|
"table-cell",
|
|
1735
1735
|
`table-cell--vertical-${e.column.alignVertical || "top"}`,
|
|
1736
1736
|
`table-cell--${e.column.selectionMode ? "center" : e.column.align || "left"}`,
|
|
@@ -1772,7 +1772,7 @@ const vo = {
|
|
|
1772
1772
|
},
|
|
1773
1773
|
emits: ["rowClickHandler", "toggleRow"],
|
|
1774
1774
|
setup(e, { emit: l }) {
|
|
1775
|
-
const t = l, a =
|
|
1775
|
+
const t = l, a = R(() => e.rowStyle ? e.rowStyle(e.item) : {});
|
|
1776
1776
|
return (n, i) => (v(), p("tr", {
|
|
1777
1777
|
class: z(["table-row", { "table-row--hovered-color": n.colorHovered }]),
|
|
1778
1778
|
style: le(a.value),
|
|
@@ -1803,11 +1803,11 @@ const vo = {
|
|
|
1803
1803
|
},
|
|
1804
1804
|
emits: ["rowClickHandler", "toggleRow"],
|
|
1805
1805
|
setup(e, { expose: l, emit: t }) {
|
|
1806
|
-
const a = t, n =
|
|
1806
|
+
const a = t, n = P(), i = P(0), o = P(0), s = R(() => !e.virtualScroll || !e.virtualScroll.enable ? 0 : Math.floor(i.value / e.virtualScroll.itemHeight)), r = R(() => {
|
|
1807
1807
|
if (!e.virtualScroll || !e.virtualScroll.enable) return e.data.length;
|
|
1808
1808
|
const h = Math.ceil(o.value / e.virtualScroll.itemHeight);
|
|
1809
1809
|
return Math.min(s.value + h + 5, e.data.length);
|
|
1810
|
-
}), u =
|
|
1810
|
+
}), u = R(() => !e.virtualScroll || !e.virtualScroll.enable ? e.data : e.data.slice(s.value, r.value)), f = (h) => {
|
|
1811
1811
|
h ? i.value = h.scrollTop : n.value && (i.value = n.value.scrollTop);
|
|
1812
1812
|
};
|
|
1813
1813
|
he(async () => {
|
|
@@ -1887,7 +1887,7 @@ const vo = {
|
|
|
1887
1887
|
},
|
|
1888
1888
|
emits: ["remove"],
|
|
1889
1889
|
setup(e, { emit: l }) {
|
|
1890
|
-
const t = l, a =
|
|
1890
|
+
const t = l, a = R(() => [
|
|
1891
1891
|
"tag",
|
|
1892
1892
|
`tag--${e.variant}`,
|
|
1893
1893
|
{
|
|
@@ -1932,7 +1932,7 @@ const vo = {
|
|
|
1932
1932
|
}),
|
|
1933
1933
|
emits: /* @__PURE__ */ ae(["change"], ["update:modelValue"]),
|
|
1934
1934
|
setup(e, { emit: l }) {
|
|
1935
|
-
const t = ie(e, "modelValue"), a = nt(), n = l, i =
|
|
1935
|
+
const t = ie(e, "modelValue"), a = nt(), n = l, i = R(() => ["radio", `radio--${e.size}`]);
|
|
1936
1936
|
return (o, s) => (v(), p("div", {
|
|
1937
1937
|
class: z(i.value)
|
|
1938
1938
|
}, [
|
|
@@ -2003,7 +2003,7 @@ const vo = {
|
|
|
2003
2003
|
},
|
|
2004
2004
|
emits: ["update:modelValue", "search", "change", "clear", "remove-tag"],
|
|
2005
2005
|
setup(e, { emit: l }) {
|
|
2006
|
-
const t = e, a = l, n =
|
|
2006
|
+
const t = e, a = l, n = P(!1), i = P(""), o = P(), s = P(), r = P(), u = P({});
|
|
2007
2007
|
function f(V) {
|
|
2008
2008
|
let T = 1e3, H = V;
|
|
2009
2009
|
for (; H && H !== document.body; ) {
|
|
@@ -2012,25 +2012,25 @@ const vo = {
|
|
|
2012
2012
|
}
|
|
2013
2013
|
return T;
|
|
2014
2014
|
}
|
|
2015
|
-
const m =
|
|
2015
|
+
const m = P(9999), h = R(() => {
|
|
2016
2016
|
if (!t.modelValue) return [];
|
|
2017
2017
|
if (t.multiple)
|
|
2018
2018
|
return (Array.isArray(t.modelValue) ? t.modelValue : [t.modelValue]).map((T) => {
|
|
2019
2019
|
if (typeof T == "object" && T !== null)
|
|
2020
2020
|
return T;
|
|
2021
|
-
const H = t.options?.find((X) =>
|
|
2021
|
+
const H = t.options?.find((X) => M(X) === T);
|
|
2022
2022
|
return H || { value: T, label: String(T) };
|
|
2023
2023
|
}).filter((T) => T !== void 0);
|
|
2024
2024
|
{
|
|
2025
2025
|
if (typeof t.modelValue == "object" && t.modelValue !== null)
|
|
2026
2026
|
return [t.modelValue];
|
|
2027
|
-
const V = t.options?.find((T) =>
|
|
2027
|
+
const V = t.options?.find((T) => M(T) === t.modelValue);
|
|
2028
2028
|
return V ? [V] : [];
|
|
2029
2029
|
}
|
|
2030
|
-
}), y =
|
|
2030
|
+
}), y = R(() => t.multiple || !h.value.length ? "" : x(h.value[0])), g = R(() => t.multiple ? h.value.length > 0 : !!t.modelValue), $ = R(() => h.value.slice(0, t.maxTags)), S = R(() => Math.max(0, h.value.length - t.maxTags)), O = R(() => i.value ? (t.options || []).filter(
|
|
2031
2031
|
(V) => x(V).toLowerCase().includes(i.value.toLowerCase())
|
|
2032
|
-
) : t.options || []), _ =
|
|
2033
|
-
function
|
|
2032
|
+
) : t.options || []), _ = R(() => t.multiple ? h.value.map((V) => M(V)) : []), B = R(() => t.multiple || !h.value.length ? null : M(h.value[0]));
|
|
2033
|
+
function M(V) {
|
|
2034
2034
|
return t.valueKey && t.valueKey in V ? V[t.valueKey] : V.value || "";
|
|
2035
2035
|
}
|
|
2036
2036
|
function x(V) {
|
|
@@ -2042,27 +2042,27 @@ const vo = {
|
|
|
2042
2042
|
function c(V) {
|
|
2043
2043
|
if (!V.disabled)
|
|
2044
2044
|
if (t.multiple) {
|
|
2045
|
-
const T =
|
|
2045
|
+
const T = M(V), H = Array.isArray(t.modelValue) ? [...t.modelValue] : [], Z = H.some((C) => typeof C == "object" && C !== null ? M(C) === T : C === T);
|
|
2046
2046
|
let X;
|
|
2047
|
-
Z ? X = H.filter((C) => typeof C == "object" && C !== null ?
|
|
2047
|
+
Z ? X = H.filter((C) => typeof C == "object" && C !== null ? M(C) !== T : C !== T) : X = [...H, t.valueKey && t.valueKey !== "" ? M(V) : V], a("update:modelValue", X), a("change", X);
|
|
2048
2048
|
} else {
|
|
2049
|
-
const T = t.valueKey && t.valueKey !== "" ?
|
|
2049
|
+
const T = t.valueKey && t.valueKey !== "" ? M(V) : V;
|
|
2050
2050
|
a("update:modelValue", T), a("change", T), n.value = !1;
|
|
2051
2051
|
}
|
|
2052
2052
|
}
|
|
2053
2053
|
function w(V) {
|
|
2054
2054
|
if (!t.multiple) return;
|
|
2055
|
-
const T =
|
|
2056
|
-
a("update:modelValue", Z), a("change", Z), a("remove-tag", t.valueKey && t.valueKey !== "" ?
|
|
2055
|
+
const T = M(V), Z = (Array.isArray(t.modelValue) ? [...t.modelValue] : []).filter((X) => typeof X == "object" && X !== null ? M(X) !== T : X !== T);
|
|
2056
|
+
a("update:modelValue", Z), a("change", Z), a("remove-tag", t.valueKey && t.valueKey !== "" ? M(V) : V);
|
|
2057
2057
|
}
|
|
2058
|
-
function
|
|
2058
|
+
function I() {
|
|
2059
2059
|
const V = t.multiple ? [] : void 0;
|
|
2060
2060
|
a("update:modelValue", V), a("change", V), a("clear");
|
|
2061
2061
|
}
|
|
2062
|
-
function
|
|
2062
|
+
function L(V) {
|
|
2063
2063
|
V.disabled || !t.multiple || c(V);
|
|
2064
2064
|
}
|
|
2065
|
-
function
|
|
2065
|
+
function D(V) {
|
|
2066
2066
|
V.disabled || t.multiple || c(V);
|
|
2067
2067
|
}
|
|
2068
2068
|
function N() {
|
|
@@ -2113,7 +2113,7 @@ const vo = {
|
|
|
2113
2113
|
b("div", Ho, [
|
|
2114
2114
|
V.multiple && h.value.length ? (v(), p("div", Fo, [
|
|
2115
2115
|
(v(!0), p(re, null, ge($.value, (H) => (v(), U(k(ht), {
|
|
2116
|
-
key:
|
|
2116
|
+
key: M(H),
|
|
2117
2117
|
removable: "",
|
|
2118
2118
|
variant: "secondary",
|
|
2119
2119
|
onRemove: (Z) => w(H)
|
|
@@ -2150,7 +2150,7 @@ const vo = {
|
|
|
2150
2150
|
V.clearable && g.value ? (v(), p("button", {
|
|
2151
2151
|
key: 0,
|
|
2152
2152
|
class: "dropdown__clear",
|
|
2153
|
-
onClick: pe(
|
|
2153
|
+
onClick: pe(I, ["stop"])
|
|
2154
2154
|
}, [
|
|
2155
2155
|
K(k(et))
|
|
2156
2156
|
])) : A("", !0)
|
|
@@ -2183,7 +2183,7 @@ const vo = {
|
|
|
2183
2183
|
b("div", Yo, [
|
|
2184
2184
|
V.loading ? (v(), p("div", jo, " Загрузка... ")) : (v(), p(re, { key: 1 }, [
|
|
2185
2185
|
(v(!0), p(re, null, ge(O.value, (H) => (v(), p("div", {
|
|
2186
|
-
key:
|
|
2186
|
+
key: M(H),
|
|
2187
2187
|
class: z(["dropdown__option", {
|
|
2188
2188
|
"dropdown__option--disabled": H.disabled
|
|
2189
2189
|
}])
|
|
@@ -2192,25 +2192,25 @@ const vo = {
|
|
|
2192
2192
|
V.multiple ? (v(), U(at, {
|
|
2193
2193
|
key: 0,
|
|
2194
2194
|
"model-value": _.value,
|
|
2195
|
-
value:
|
|
2196
|
-
label: x(H),
|
|
2195
|
+
value: M(H),
|
|
2197
2196
|
disabled: H.disabled,
|
|
2198
|
-
onChange: (Z) =>
|
|
2199
|
-
}, null, 8, ["model-value", "value", "
|
|
2197
|
+
onChange: (Z) => L(H)
|
|
2198
|
+
}, null, 8, ["model-value", "value", "disabled", "onChange"])) : (v(), U(Ft, {
|
|
2200
2199
|
key: 1,
|
|
2201
2200
|
"model-value": B.value,
|
|
2202
|
-
value:
|
|
2203
|
-
label: x(H),
|
|
2201
|
+
value: M(H),
|
|
2204
2202
|
disabled: H.disabled,
|
|
2205
|
-
onChange: (Z) =>
|
|
2206
|
-
}, null, 8, ["model-value", "value", "
|
|
2207
|
-
|
|
2208
|
-
|
|
2209
|
-
|
|
2210
|
-
|
|
2211
|
-
|
|
2212
|
-
|
|
2213
|
-
|
|
2203
|
+
onChange: (Z) => D(H)
|
|
2204
|
+
}, null, 8, ["model-value", "value", "disabled", "onChange"]))
|
|
2205
|
+
]),
|
|
2206
|
+
J(V.$slots, "option", {
|
|
2207
|
+
option: H,
|
|
2208
|
+
selected: V.multiple ? _.value.includes(M(H)) : B.value === M(H),
|
|
2209
|
+
multiple: V.multiple,
|
|
2210
|
+
handleSelect: V.multiple ? () => L(H) : () => D(H)
|
|
2211
|
+
}, () => [
|
|
2212
|
+
b("span", null, j(x(H)), 1)
|
|
2213
|
+
], !0)
|
|
2214
2214
|
], 2))), 128)),
|
|
2215
2215
|
O.value.length ? A("", !0) : (v(), p("div", Uo, " Ничего не найдено "))
|
|
2216
2216
|
], 64))
|
|
@@ -2222,7 +2222,7 @@ const vo = {
|
|
|
2222
2222
|
V.error && V.errorText ? (v(), p("small", Zo, j(V.errorText), 1)) : A("", !0)
|
|
2223
2223
|
], 2));
|
|
2224
2224
|
}
|
|
2225
|
-
}), Xo = /* @__PURE__ */ ue(Qo, [["__scopeId", "data-v-
|
|
2225
|
+
}), Xo = /* @__PURE__ */ ue(Qo, [["__scopeId", "data-v-9b2f8a98"]]), Go = {
|
|
2226
2226
|
key: 0,
|
|
2227
2227
|
class: "paginator"
|
|
2228
2228
|
}, Jo = ["disabled"], ea = { class: "paginator__pages" }, ta = ["onClick"], la = ["disabled"], na = {
|
|
@@ -2242,10 +2242,10 @@ const vo = {
|
|
|
2242
2242
|
}),
|
|
2243
2243
|
emits: ["update:currentPage", "update:perPage"],
|
|
2244
2244
|
setup(e) {
|
|
2245
|
-
const l = ie(e, "currentPage"), t = ie(e, "perPage"), a =
|
|
2245
|
+
const l = ie(e, "currentPage"), t = ie(e, "perPage"), a = R(() => Math.ceil(e.totals / (t.value ?? 25))), n = R(() => e.perPageOptions.map((o) => ({
|
|
2246
2246
|
label: o,
|
|
2247
2247
|
value: o
|
|
2248
|
-
}))), i =
|
|
2248
|
+
}))), i = R(() => {
|
|
2249
2249
|
const o = a.value, s = l.value;
|
|
2250
2250
|
if (o <= 7)
|
|
2251
2251
|
return Array.from({ length: o }, (u, f) => f + 1);
|
|
@@ -2307,7 +2307,7 @@ const vo = {
|
|
|
2307
2307
|
}),
|
|
2308
2308
|
emits: ["update:currentPage", "update:perPage"],
|
|
2309
2309
|
setup(e) {
|
|
2310
|
-
const l = ie(e, "currentPage"), t = ie(e, "perPage"), a =
|
|
2310
|
+
const l = ie(e, "currentPage"), t = ie(e, "perPage"), a = R(() => e.paginator && l.value);
|
|
2311
2311
|
return (n, i) => a.value ? (v(), p("tfoot", sa, [
|
|
2312
2312
|
b("tr", null, [
|
|
2313
2313
|
b("td", ra, [
|
|
@@ -2333,10 +2333,10 @@ const vo = {
|
|
|
2333
2333
|
size: { default: "default" }
|
|
2334
2334
|
},
|
|
2335
2335
|
setup(e) {
|
|
2336
|
-
const l =
|
|
2336
|
+
const l = R(() => typeof e.strokeWidth == "string" ? `${e.strokeWidth.split("px")[0]}px` : `${e.strokeWidth}px`), t = R(() => ({
|
|
2337
2337
|
"--spinner-stroke-width": l.value,
|
|
2338
2338
|
...e.style
|
|
2339
|
-
})), a =
|
|
2339
|
+
})), a = R(() => [
|
|
2340
2340
|
"spinner",
|
|
2341
2341
|
`spinner--${e.size}`
|
|
2342
2342
|
]);
|
|
@@ -2349,7 +2349,7 @@ const vo = {
|
|
|
2349
2349
|
])], 6));
|
|
2350
2350
|
}
|
|
2351
2351
|
}), ua = () => {
|
|
2352
|
-
const e =
|
|
2352
|
+
const e = P([]), l = P([]), t = P({
|
|
2353
2353
|
selectedMode: null
|
|
2354
2354
|
}), a = (o) => {
|
|
2355
2355
|
const s = e.value.findIndex((r) => r.id === o.id);
|
|
@@ -2407,16 +2407,16 @@ const vo = {
|
|
|
2407
2407
|
}),
|
|
2408
2408
|
emits: /* @__PURE__ */ ae(["rowClickHandler"], ["update:currentPage", "update:perPage", "update:selectedRows"]),
|
|
2409
2409
|
setup(e, { emit: l }) {
|
|
2410
|
-
const t = l, { columns: a, options: n } = ua(), i =
|
|
2410
|
+
const t = l, { columns: a, options: n } = ua(), i = R(() => n.value.selectedMode), o = P(null), s = P(), r = P(), u = ie(e, "currentPage"), f = ie(e, "perPage"), m = (d) => {
|
|
2411
2411
|
if (e.virtualScroll && e.virtualScroll.enable && s.value) {
|
|
2412
2412
|
const c = d.target;
|
|
2413
2413
|
s.value.handleScroll(c);
|
|
2414
2414
|
}
|
|
2415
2415
|
}, h = () => {
|
|
2416
2416
|
if (r.value) {
|
|
2417
|
-
const c = r.value.getBoundingClientRect(),
|
|
2417
|
+
const c = r.value.getBoundingClientRect(), I = (window.pageYOffset || document.documentElement.scrollTop) + c.top - 80;
|
|
2418
2418
|
window.scrollTo({
|
|
2419
|
-
top:
|
|
2419
|
+
top: I,
|
|
2420
2420
|
behavior: "smooth"
|
|
2421
2421
|
});
|
|
2422
2422
|
}
|
|
@@ -2430,17 +2430,17 @@ const vo = {
|
|
|
2430
2430
|
d && s.value.updateContainerHeight(d);
|
|
2431
2431
|
}
|
|
2432
2432
|
});
|
|
2433
|
-
const y =
|
|
2433
|
+
const y = R(() => {
|
|
2434
2434
|
let d = [...e.data];
|
|
2435
2435
|
if (o.value) {
|
|
2436
2436
|
const { field: c, order: w } = o.value;
|
|
2437
|
-
d.sort((
|
|
2438
|
-
const
|
|
2439
|
-
return
|
|
2437
|
+
d.sort((I, L) => {
|
|
2438
|
+
const D = I[c], N = L[c];
|
|
2439
|
+
return D === N ? 0 : w === 1 ? D > N ? 1 : -1 : D < N ? 1 : -1;
|
|
2440
2440
|
});
|
|
2441
2441
|
}
|
|
2442
2442
|
return d;
|
|
2443
|
-
}), g =
|
|
2443
|
+
}), g = R(() => e.scroller && e.scroller.enable || e.virtualScroll && e.virtualScroll.enable || e.maxHeight), $ = R(() => [
|
|
2444
2444
|
"table",
|
|
2445
2445
|
{
|
|
2446
2446
|
[`table--theme-${e.theme}`]: e.theme,
|
|
@@ -2449,15 +2449,15 @@ const vo = {
|
|
|
2449
2449
|
"table--scrollable": g.value,
|
|
2450
2450
|
"table--empty": e.data.length === 0
|
|
2451
2451
|
}
|
|
2452
|
-
]), S =
|
|
2452
|
+
]), S = R(() => [
|
|
2453
2453
|
"table-wrapper",
|
|
2454
2454
|
{
|
|
2455
2455
|
"table-wrapper--scrollable": g.value
|
|
2456
2456
|
}
|
|
2457
|
-
]), O =
|
|
2457
|
+
]), O = R(() => {
|
|
2458
2458
|
const d = {};
|
|
2459
2459
|
return e.maxHeight ? (d.maxHeight = typeof e.maxHeight == "number" ? `${e.maxHeight}px` : e.maxHeight, d.overflow = "auto") : e.scroller && e.scroller.enable && (d.maxHeight = `${e.scroller.height}px`, d.overflow = "auto"), d;
|
|
2460
|
-
}), _ = ie(e, "selectedRows"), B =
|
|
2460
|
+
}), _ = ie(e, "selectedRows"), B = R(
|
|
2461
2461
|
() => {
|
|
2462
2462
|
if (!_.value || !Array.isArray(_.value) || e.data.length === 0)
|
|
2463
2463
|
return !1;
|
|
@@ -2466,7 +2466,7 @@ const vo = {
|
|
|
2466
2466
|
);
|
|
2467
2467
|
return e.data.length === d.length;
|
|
2468
2468
|
}
|
|
2469
|
-
),
|
|
2469
|
+
), M = (d) => {
|
|
2470
2470
|
if (i.value)
|
|
2471
2471
|
if (_.value || (_.value = []), i.value === "multiple") {
|
|
2472
2472
|
const c = Array.isArray(_.value) ? _.value.findIndex((w) => w === d) : -1;
|
|
@@ -2474,7 +2474,21 @@ const vo = {
|
|
|
2474
2474
|
} else
|
|
2475
2475
|
_.value = d;
|
|
2476
2476
|
}, x = () => {
|
|
2477
|
-
|
|
2477
|
+
if (!i.value || i.value !== "multiple") return;
|
|
2478
|
+
(!_.value || !Array.isArray(_.value)) && (_.value = []);
|
|
2479
|
+
const d = _.value;
|
|
2480
|
+
if (d.filter(
|
|
2481
|
+
(w) => e.data.some((I) => I === w)
|
|
2482
|
+
).length === e.data.length)
|
|
2483
|
+
_.value = d.filter(
|
|
2484
|
+
(w) => !e.data.some((I) => I === w)
|
|
2485
|
+
);
|
|
2486
|
+
else {
|
|
2487
|
+
const w = e.data.filter(
|
|
2488
|
+
(I) => !d.some((L) => L === I)
|
|
2489
|
+
);
|
|
2490
|
+
_.value = [...d, ...w];
|
|
2491
|
+
}
|
|
2478
2492
|
};
|
|
2479
2493
|
return ee(u, (d, c) => {
|
|
2480
2494
|
d !== c && d !== void 0 && c !== void 0 && fe(() => {
|
|
@@ -2514,7 +2528,7 @@ const vo = {
|
|
|
2514
2528
|
virtualScroll: d.virtualScroll || void 0,
|
|
2515
2529
|
rowStyle: d.rowStyle,
|
|
2516
2530
|
onRowClickHandler: c[1] || (c[1] = (w) => t("rowClickHandler", w)),
|
|
2517
|
-
onToggleRow: c[2] || (c[2] = (w) =>
|
|
2531
|
+
onToggleRow: c[2] || (c[2] = (w) => M(w))
|
|
2518
2532
|
}, null, 8, ["size", "selectedRows", "columns", "data", "colorHovered", "scroller", "virtualScroll", "rowStyle"])) : d.loading ? (v(), p("tbody", ca, [
|
|
2519
2533
|
b("tr", null, [
|
|
2520
2534
|
b("td", {
|
|
@@ -2578,7 +2592,7 @@ const vo = {
|
|
|
2578
2592
|
virtualScroll: d.virtualScroll || void 0,
|
|
2579
2593
|
rowStyle: d.rowStyle,
|
|
2580
2594
|
onRowClickHandler: c[6] || (c[6] = (w) => t("rowClickHandler", w)),
|
|
2581
|
-
onToggleRow: c[7] || (c[7] = (w) =>
|
|
2595
|
+
onToggleRow: c[7] || (c[7] = (w) => M(w))
|
|
2582
2596
|
}, null, 8, ["size", "selectedRows", "columns", "data", "colorHovered", "scroller", "virtualScroll", "rowStyle"])) : d.loading ? (v(), p("tbody", pa, [
|
|
2583
2597
|
b("tr", null, [
|
|
2584
2598
|
b("td", {
|
|
@@ -2614,7 +2628,7 @@ const vo = {
|
|
|
2614
2628
|
}, null, 8, ["currentPage", "per-page", "data", "per-page-options", "totals-row", "paginator", "viewPerPage"])
|
|
2615
2629
|
], 2));
|
|
2616
2630
|
}
|
|
2617
|
-
}), ai = /* @__PURE__ */ ue(wa, [["__scopeId", "data-v-
|
|
2631
|
+
}), ai = /* @__PURE__ */ ue(wa, [["__scopeId", "data-v-0c6555e5"]]), si = /* @__PURE__ */ Y({
|
|
2618
2632
|
__name: "Column",
|
|
2619
2633
|
props: {
|
|
2620
2634
|
field: {},
|
|
@@ -2628,7 +2642,7 @@ const vo = {
|
|
|
2628
2642
|
visible: { type: Boolean, default: !0 }
|
|
2629
2643
|
},
|
|
2630
2644
|
setup(e) {
|
|
2631
|
-
const l = e, t = Ke(l, "visible"), a = cl(), n = l.field || `column-${Math.random().toString(36).substring(2, 11)}`, i = ye("registerColumn"), o =
|
|
2645
|
+
const l = e, t = Ke(l, "visible"), a = cl(), n = l.field || `column-${Math.random().toString(36).substring(2, 11)}`, i = ye("registerColumn"), o = R(() => ({
|
|
2632
2646
|
id: n,
|
|
2633
2647
|
header: l.header,
|
|
2634
2648
|
field: l.field,
|
|
@@ -2726,7 +2740,7 @@ const vo = {
|
|
|
2726
2740
|
},
|
|
2727
2741
|
emits: ["update:modelValue", "search", "change", "clear", "remove-tag"],
|
|
2728
2742
|
setup(e, { emit: l }) {
|
|
2729
|
-
const t = e, a = l, n =
|
|
2743
|
+
const t = e, a = l, n = P(!1), i = P(!1), o = P(""), s = P(-1), r = P(), u = P(), f = P(), m = P({});
|
|
2730
2744
|
function h(C) {
|
|
2731
2745
|
let E = 1e3, W = C;
|
|
2732
2746
|
for (; W && W !== document.body; ) {
|
|
@@ -2735,7 +2749,7 @@ const vo = {
|
|
|
2735
2749
|
}
|
|
2736
2750
|
return E;
|
|
2737
2751
|
}
|
|
2738
|
-
const y =
|
|
2752
|
+
const y = P(9999), g = R(() => {
|
|
2739
2753
|
if (!t.modelValue) return [];
|
|
2740
2754
|
if (t.multiple)
|
|
2741
2755
|
return (Array.isArray(t.modelValue) ? t.modelValue : [t.modelValue]).map((E) => {
|
|
@@ -2750,7 +2764,7 @@ const vo = {
|
|
|
2750
2764
|
const C = t.options?.find((E) => d(E) === t.modelValue);
|
|
2751
2765
|
return C ? [C] : [];
|
|
2752
2766
|
}
|
|
2753
|
-
}), $ =
|
|
2767
|
+
}), $ = R(() => t.multiple ? g.value.length > 0 : !!t.modelValue), S = R(() => t.multiple && g.value.length > 0 ? "" : t.placeholder), O = R(() => g.value.slice(0, t.maxTags)), _ = R(() => Math.max(0, g.value.length - t.maxTags)), B = R(() => t.options || []), M = R(() => t.multiple ? g.value.map((C) => d(C)) : []), x = R(() => t.multiple || !g.value.length ? null : d(g.value[0]));
|
|
2754
2768
|
function d(C) {
|
|
2755
2769
|
return t.valueKey && t.valueKey in C ? C[t.valueKey] : C.value || "";
|
|
2756
2770
|
}
|
|
@@ -2760,15 +2774,15 @@ const vo = {
|
|
|
2760
2774
|
function w() {
|
|
2761
2775
|
a("search", o.value), o.value.length >= t.minQueryLength && ((t.options?.length || 0) > 0 || t.loading) ? (n.value = !0, s.value = -1) : n.value = !1;
|
|
2762
2776
|
}
|
|
2763
|
-
function
|
|
2777
|
+
function I() {
|
|
2764
2778
|
i.value = !0, o.value.length >= t.minQueryLength && ((t.options?.length || 0) > 0 || t.loading) && (n.value = !0);
|
|
2765
2779
|
}
|
|
2766
|
-
function
|
|
2780
|
+
function L() {
|
|
2767
2781
|
i.value = !1, t.multiple || setTimeout(() => {
|
|
2768
2782
|
n.value = !1;
|
|
2769
2783
|
}, 150);
|
|
2770
2784
|
}
|
|
2771
|
-
function
|
|
2785
|
+
function D(C) {
|
|
2772
2786
|
C.key === "ArrowDown" ? (C.preventDefault(), n.value && B.value.length > 0 && (s.value = Math.min(s.value + 1, B.value.length - 1))) : C.key === "ArrowUp" ? (C.preventDefault(), n.value && B.value.length > 0 && (s.value = Math.max(s.value - 1, 0))) : C.key === "Enter" ? (C.preventDefault(), n.value && s.value >= 0 && N(B.value[s.value])) : C.key === "Escape" ? (n.value = !1, f.value?.blur()) : C.key === "Tab" && (n.value = !1);
|
|
2773
2787
|
}
|
|
2774
2788
|
function N(C) {
|
|
@@ -2894,9 +2908,9 @@ const vo = {
|
|
|
2894
2908
|
placeholder: S.value,
|
|
2895
2909
|
disabled: C.disabled,
|
|
2896
2910
|
onInput: w,
|
|
2897
|
-
onFocus:
|
|
2898
|
-
onBlur:
|
|
2899
|
-
onKeydown:
|
|
2911
|
+
onFocus: I,
|
|
2912
|
+
onBlur: L,
|
|
2913
|
+
onKeydown: D
|
|
2900
2914
|
}, null, 40, Ta), [
|
|
2901
2915
|
[ze, o.value]
|
|
2902
2916
|
])
|
|
@@ -2945,7 +2959,7 @@ const vo = {
|
|
|
2945
2959
|
onClick: pe((Q) => T(W), ["stop"])
|
|
2946
2960
|
}, [
|
|
2947
2961
|
K(at, {
|
|
2948
|
-
"model-value":
|
|
2962
|
+
"model-value": M.value,
|
|
2949
2963
|
value: d(W),
|
|
2950
2964
|
label: c(W),
|
|
2951
2965
|
disabled: W.disabled,
|
|
@@ -2997,7 +3011,7 @@ const vo = {
|
|
|
2997
3011
|
}),
|
|
2998
3012
|
emits: /* @__PURE__ */ ae(["blur", "input", "paste", "focus", "clear"], ["update:modelValue"]),
|
|
2999
3013
|
setup(e, { emit: l }) {
|
|
3000
|
-
const t = l, a = ie(e, "modelValue"), n =
|
|
3014
|
+
const t = l, a = ie(e, "modelValue"), n = R(() => (/* @__PURE__ */ new Date()).getTime().toString()), i = P(!1), o = R(() => [
|
|
3001
3015
|
"input",
|
|
3002
3016
|
`input--${e.size}`,
|
|
3003
3017
|
`input--${e.variant}`,
|
|
@@ -3006,7 +3020,7 @@ const vo = {
|
|
|
3006
3020
|
"input--disabled": e.disabled,
|
|
3007
3021
|
"input--error": e.error
|
|
3008
3022
|
}
|
|
3009
|
-
]), s =
|
|
3023
|
+
]), s = R(() => e.type === "password" ? i.value ? "text" : "password" : e.type), r = () => {
|
|
3010
3024
|
a.value = "", t("clear");
|
|
3011
3025
|
};
|
|
3012
3026
|
return ee(
|
|
@@ -3067,7 +3081,7 @@ const vo = {
|
|
|
3067
3081
|
}
|
|
3068
3082
|
});
|
|
3069
3083
|
function qa(e, l) {
|
|
3070
|
-
const { mask: t, slotChar: a = "_", autoClear: n = !0, definitions: i } = l, o =
|
|
3084
|
+
const { mask: t, slotChar: a = "_", autoClear: n = !0, definitions: i } = l, o = P(""), s = P(!1), r = {
|
|
3071
3085
|
9: /[0-9]/,
|
|
3072
3086
|
// только цифры
|
|
3073
3087
|
a: /[a-zA-Z]/,
|
|
@@ -3091,61 +3105,61 @@ function qa(e, l) {
|
|
|
3091
3105
|
return f(c) ? r[c].test(d) : !1;
|
|
3092
3106
|
}
|
|
3093
3107
|
function h(d) {
|
|
3094
|
-
const { required: c, optional: w } = u(t),
|
|
3095
|
-
let
|
|
3096
|
-
for (; N <
|
|
3097
|
-
const q =
|
|
3108
|
+
const { required: c, optional: w } = u(t), I = c + w;
|
|
3109
|
+
let L = "", D = 0, N = 0;
|
|
3110
|
+
for (; N < I.length; ) {
|
|
3111
|
+
const q = I[N];
|
|
3098
3112
|
if (f(q))
|
|
3099
|
-
if (
|
|
3100
|
-
const F = d[
|
|
3113
|
+
if (D < d.length) {
|
|
3114
|
+
const F = d[D];
|
|
3101
3115
|
if (m(F, q))
|
|
3102
|
-
|
|
3116
|
+
L += F, D++;
|
|
3103
3117
|
else {
|
|
3104
|
-
|
|
3118
|
+
D++;
|
|
3105
3119
|
continue;
|
|
3106
3120
|
}
|
|
3107
3121
|
} else
|
|
3108
|
-
|
|
3122
|
+
L += a;
|
|
3109
3123
|
else
|
|
3110
|
-
|
|
3124
|
+
L += q;
|
|
3111
3125
|
N++;
|
|
3112
3126
|
}
|
|
3113
|
-
return
|
|
3127
|
+
return L;
|
|
3114
3128
|
}
|
|
3115
3129
|
function y() {
|
|
3116
3130
|
const { required: d, optional: c } = u(t);
|
|
3117
3131
|
return (d + c).replace(/[9a*]/g, a);
|
|
3118
3132
|
}
|
|
3119
3133
|
function g(d) {
|
|
3120
|
-
const { required: c, optional: w } = u(t),
|
|
3121
|
-
let
|
|
3122
|
-
for (;
|
|
3123
|
-
const q = d[
|
|
3134
|
+
const { required: c, optional: w } = u(t), I = c + w;
|
|
3135
|
+
let L = "", D = 0, N = 0;
|
|
3136
|
+
for (; D < d.length && N < I.length; ) {
|
|
3137
|
+
const q = d[D], F = I[N];
|
|
3124
3138
|
if (q === a) {
|
|
3125
|
-
|
|
3139
|
+
D++;
|
|
3126
3140
|
continue;
|
|
3127
3141
|
}
|
|
3128
|
-
f(F) ? m(q, F) ? (
|
|
3142
|
+
f(F) ? m(q, F) ? (L += q, D++, N++) : D++ : (q === F && D++, N++);
|
|
3129
3143
|
}
|
|
3130
|
-
for (;
|
|
3131
|
-
const q = d[
|
|
3144
|
+
for (; D < d.length; ) {
|
|
3145
|
+
const q = d[D];
|
|
3132
3146
|
if (q === a) {
|
|
3133
|
-
|
|
3147
|
+
D++;
|
|
3134
3148
|
continue;
|
|
3135
3149
|
}
|
|
3136
3150
|
let F = !1, V = 0;
|
|
3137
|
-
for (let T = 0; T <
|
|
3138
|
-
if (f(
|
|
3139
|
-
if (V ===
|
|
3140
|
-
m(q,
|
|
3151
|
+
for (let T = 0; T < I.length; T++)
|
|
3152
|
+
if (f(I[T])) {
|
|
3153
|
+
if (V === L.length) {
|
|
3154
|
+
m(q, I[T]) && (L += q, F = !0);
|
|
3141
3155
|
break;
|
|
3142
3156
|
}
|
|
3143
3157
|
V++;
|
|
3144
3158
|
}
|
|
3145
|
-
if (
|
|
3159
|
+
if (D++, !F)
|
|
3146
3160
|
break;
|
|
3147
3161
|
}
|
|
3148
|
-
return
|
|
3162
|
+
return L;
|
|
3149
3163
|
}
|
|
3150
3164
|
function $(d) {
|
|
3151
3165
|
const { required: c } = u(t), w = c.replace(/[^9a*]/g, "").length;
|
|
@@ -3156,62 +3170,62 @@ function qa(e, l) {
|
|
|
3156
3170
|
if (s.value || d)
|
|
3157
3171
|
o.value = h(d);
|
|
3158
3172
|
else {
|
|
3159
|
-
const { required: c, optional: w } = u(t),
|
|
3160
|
-
let
|
|
3161
|
-
for (let
|
|
3162
|
-
|
|
3163
|
-
o.value =
|
|
3173
|
+
const { required: c, optional: w } = u(t), I = c + w;
|
|
3174
|
+
let L = "";
|
|
3175
|
+
for (let D = 0; D < I.length && !f(I[D]); D++)
|
|
3176
|
+
L += I[D];
|
|
3177
|
+
o.value = L;
|
|
3164
3178
|
}
|
|
3165
3179
|
}
|
|
3166
3180
|
function O(d) {
|
|
3167
3181
|
if (!d.isTrusted) return;
|
|
3168
|
-
const c = d.target, w = c.value,
|
|
3169
|
-
o.value =
|
|
3170
|
-
const { required:
|
|
3182
|
+
const c = d.target, w = c.value, I = g(w), L = h(I);
|
|
3183
|
+
o.value = L, e.value = I, fe(() => {
|
|
3184
|
+
const { required: D, optional: N } = u(t), q = D + N;
|
|
3171
3185
|
let F = 0, V = 0;
|
|
3172
3186
|
for (let T = 0; T < q.length; T++)
|
|
3173
3187
|
if (f(q[T]))
|
|
3174
|
-
if (V <
|
|
3188
|
+
if (V < I.length)
|
|
3175
3189
|
V++;
|
|
3176
3190
|
else {
|
|
3177
3191
|
F = T;
|
|
3178
3192
|
break;
|
|
3179
3193
|
}
|
|
3180
|
-
if (V ===
|
|
3194
|
+
if (V === I.length && I.length > 0) {
|
|
3181
3195
|
V = 0;
|
|
3182
3196
|
for (let T = 0; T < q.length; T++)
|
|
3183
|
-
if (f(q[T]) && (V++, V ===
|
|
3197
|
+
if (f(q[T]) && (V++, V === I.length)) {
|
|
3184
3198
|
F = T + 1;
|
|
3185
3199
|
break;
|
|
3186
3200
|
}
|
|
3187
3201
|
}
|
|
3188
|
-
F = Math.min(F,
|
|
3202
|
+
F = Math.min(F, L.length), c.setSelectionRange(F, F);
|
|
3189
3203
|
});
|
|
3190
3204
|
}
|
|
3191
3205
|
function _(d) {
|
|
3192
3206
|
const c = d.target;
|
|
3193
3207
|
setTimeout(() => {
|
|
3194
|
-
const w = c.value,
|
|
3195
|
-
o.value =
|
|
3196
|
-
const { required:
|
|
3208
|
+
const w = c.value, I = g(w), L = h(I);
|
|
3209
|
+
o.value = L, e.value = I;
|
|
3210
|
+
const { required: D, optional: N } = u(t), q = D + N;
|
|
3197
3211
|
let F = 0, V = 0;
|
|
3198
3212
|
for (let T = 0; T < q.length; T++)
|
|
3199
3213
|
if (f(q[T]))
|
|
3200
|
-
if (V <
|
|
3214
|
+
if (V < I.length)
|
|
3201
3215
|
V++;
|
|
3202
3216
|
else {
|
|
3203
3217
|
F = T;
|
|
3204
3218
|
break;
|
|
3205
3219
|
}
|
|
3206
|
-
if (V ===
|
|
3220
|
+
if (V === I.length && I.length > 0) {
|
|
3207
3221
|
V = 0;
|
|
3208
3222
|
for (let T = 0; T < q.length; T++)
|
|
3209
|
-
if (f(q[T]) && (V++, V ===
|
|
3223
|
+
if (f(q[T]) && (V++, V === I.length)) {
|
|
3210
3224
|
F = T + 1;
|
|
3211
3225
|
break;
|
|
3212
3226
|
}
|
|
3213
3227
|
}
|
|
3214
|
-
F = Math.min(F,
|
|
3228
|
+
F = Math.min(F, L.length), c.setSelectionRange(F, F);
|
|
3215
3229
|
}, 0);
|
|
3216
3230
|
}
|
|
3217
3231
|
function B(d) {
|
|
@@ -3307,44 +3321,44 @@ function qa(e, l) {
|
|
|
3307
3321
|
}
|
|
3308
3322
|
if (d.metaKey || d.ctrlKey || ["ArrowLeft", "ArrowRight", "Tab", "Home", "End", "Escape"].includes(d.key))
|
|
3309
3323
|
return;
|
|
3310
|
-
const { required:
|
|
3324
|
+
const { required: I, optional: L } = u(t), D = I + L, N = g(o.value), q = D.split("").filter((T) => f(T)).length;
|
|
3311
3325
|
if (N.length >= q) {
|
|
3312
3326
|
d.preventDefault();
|
|
3313
3327
|
return;
|
|
3314
3328
|
}
|
|
3315
3329
|
let F = -1, V = 0;
|
|
3316
|
-
for (let T = 0; T <
|
|
3317
|
-
if (f(
|
|
3330
|
+
for (let T = 0; T < D.length; T++)
|
|
3331
|
+
if (f(D[T])) {
|
|
3318
3332
|
if (V === N.length) {
|
|
3319
3333
|
F = T;
|
|
3320
3334
|
break;
|
|
3321
3335
|
}
|
|
3322
3336
|
V++;
|
|
3323
3337
|
}
|
|
3324
|
-
F >= 0 && !m(d.key,
|
|
3338
|
+
F >= 0 && !m(d.key, D[F]) && d.preventDefault();
|
|
3325
3339
|
}
|
|
3326
|
-
function
|
|
3340
|
+
function M(d) {
|
|
3327
3341
|
s.value = !0, fe(() => {
|
|
3328
|
-
const c = d.target, { required: w, optional:
|
|
3329
|
-
let
|
|
3330
|
-
for (let N = 0; N <
|
|
3331
|
-
if (f(
|
|
3332
|
-
|
|
3342
|
+
const c = d.target, { required: w, optional: I } = u(t), L = w + I;
|
|
3343
|
+
let D = 0;
|
|
3344
|
+
for (let N = 0; N < L.length; N++)
|
|
3345
|
+
if (f(L[N])) {
|
|
3346
|
+
D = N;
|
|
3333
3347
|
break;
|
|
3334
3348
|
}
|
|
3335
3349
|
if (je(e)) {
|
|
3336
3350
|
let N = 0;
|
|
3337
|
-
for (let q = 0; q <
|
|
3338
|
-
if (f(
|
|
3351
|
+
for (let q = 0; q < L.length; q++)
|
|
3352
|
+
if (f(L[q])) {
|
|
3339
3353
|
if (N >= je(e).length) {
|
|
3340
|
-
|
|
3354
|
+
D = q;
|
|
3341
3355
|
break;
|
|
3342
3356
|
}
|
|
3343
3357
|
N++;
|
|
3344
3358
|
}
|
|
3345
|
-
N === je(e).length && (
|
|
3359
|
+
N === je(e).length && (D = o.value.length);
|
|
3346
3360
|
}
|
|
3347
|
-
c.setSelectionRange(
|
|
3361
|
+
c.setSelectionRange(D, D);
|
|
3348
3362
|
});
|
|
3349
3363
|
}
|
|
3350
3364
|
function x() {
|
|
@@ -3359,7 +3373,7 @@ function qa(e, l) {
|
|
|
3359
3373
|
handleInput: O,
|
|
3360
3374
|
handlePaste: _,
|
|
3361
3375
|
handleKeydown: B,
|
|
3362
|
-
handleFocus:
|
|
3376
|
+
handleFocus: M,
|
|
3363
3377
|
handleBlur: x,
|
|
3364
3378
|
placeholder: y()
|
|
3365
3379
|
};
|
|
@@ -3416,7 +3430,7 @@ const ui = /* @__PURE__ */ Y({
|
|
|
3416
3430
|
disabled: { type: Boolean }
|
|
3417
3431
|
},
|
|
3418
3432
|
setup(e) {
|
|
3419
|
-
const l =
|
|
3433
|
+
const l = R(() => [
|
|
3420
3434
|
"icon-field",
|
|
3421
3435
|
{
|
|
3422
3436
|
[`icon-field--${e.position}`]: e.position,
|
|
@@ -3448,7 +3462,7 @@ const ui = /* @__PURE__ */ Y({
|
|
|
3448
3462
|
}),
|
|
3449
3463
|
emits: ["update:modelValue"],
|
|
3450
3464
|
setup(e) {
|
|
3451
|
-
const l = ie(e, "modelValue"), t =
|
|
3465
|
+
const l = ie(e, "modelValue"), t = P(
|
|
3452
3466
|
e.formatter ? e.formatter(l.value) : l.value
|
|
3453
3467
|
);
|
|
3454
3468
|
ee(l, (s) => {
|
|
@@ -3471,7 +3485,7 @@ const ui = /* @__PURE__ */ Y({
|
|
|
3471
3485
|
if (l.value === 1) return;
|
|
3472
3486
|
let s = e.countInPackage ? l.value - e.countInPackage : l.value - 1;
|
|
3473
3487
|
s < e.min && (s = e.min), l.value = s;
|
|
3474
|
-
}, o =
|
|
3488
|
+
}, o = R(() => [
|
|
3475
3489
|
"input-number",
|
|
3476
3490
|
{
|
|
3477
3491
|
"input-number--view-buttons": e.viewButtons,
|
|
@@ -3529,7 +3543,7 @@ const ui = /* @__PURE__ */ Y({
|
|
|
3529
3543
|
},
|
|
3530
3544
|
emits: ["update:modelValue"],
|
|
3531
3545
|
setup(e) {
|
|
3532
|
-
const l = ie(e, "modelValue"), t =
|
|
3546
|
+
const l = ie(e, "modelValue"), t = R({
|
|
3533
3547
|
get() {
|
|
3534
3548
|
return a(l.value);
|
|
3535
3549
|
},
|
|
@@ -3641,14 +3655,14 @@ const ui = /* @__PURE__ */ Y({
|
|
|
3641
3655
|
}),
|
|
3642
3656
|
emits: ["update:modelValue"],
|
|
3643
3657
|
setup(e) {
|
|
3644
|
-
const l = ie(e, "modelValue"), t =
|
|
3658
|
+
const l = ie(e, "modelValue"), t = R({
|
|
3645
3659
|
get() {
|
|
3646
3660
|
return l.value ?? 0;
|
|
3647
3661
|
},
|
|
3648
3662
|
set(u) {
|
|
3649
3663
|
l.value = u;
|
|
3650
3664
|
}
|
|
3651
|
-
}), a = e, n =
|
|
3665
|
+
}), a = e, n = P(null), i = R(() => {
|
|
3652
3666
|
let u;
|
|
3653
3667
|
if (typeof a.size == "number")
|
|
3654
3668
|
u = a.size;
|
|
@@ -3725,7 +3739,7 @@ const ui = /* @__PURE__ */ Y({
|
|
|
3725
3739
|
}),
|
|
3726
3740
|
emits: /* @__PURE__ */ ae(["focusIn", "focusOut", "blur"], ["update:modelValue"]),
|
|
3727
3741
|
setup(e, { emit: l }) {
|
|
3728
|
-
const t = l, a = ie(e, "modelValue"), n =
|
|
3742
|
+
const t = l, a = ie(e, "modelValue"), n = P(null), i = nt(), o = () => {
|
|
3729
3743
|
const r = n.value;
|
|
3730
3744
|
if (!r) return;
|
|
3731
3745
|
const u = {
|
|
@@ -3740,7 +3754,7 @@ const ui = /* @__PURE__ */ Y({
|
|
|
3740
3754
|
}), ee(() => [e.rows, e.maxHeight], () => {
|
|
3741
3755
|
o();
|
|
3742
3756
|
});
|
|
3743
|
-
const s =
|
|
3757
|
+
const s = R(() => [
|
|
3744
3758
|
"textarea",
|
|
3745
3759
|
`textarea--${e.size}`,
|
|
3746
3760
|
{
|
|
@@ -3809,7 +3823,7 @@ const ui = /* @__PURE__ */ Y({
|
|
|
3809
3823
|
o.push({ value: h, label: y });
|
|
3810
3824
|
}
|
|
3811
3825
|
return o;
|
|
3812
|
-
}, n =
|
|
3826
|
+
}, n = R(() => l.options || a()), i = () => {
|
|
3813
3827
|
};
|
|
3814
3828
|
return (o, s) => (v(), p("div", ss, [
|
|
3815
3829
|
be(b("select", {
|
|
@@ -4017,8 +4031,8 @@ function ms(e, l = "dd.mm.yyyy", t = null, a = null) {
|
|
|
4017
4031
|
}
|
|
4018
4032
|
return i;
|
|
4019
4033
|
}
|
|
4020
|
-
function ps(e, l, t =
|
|
4021
|
-
const o =
|
|
4034
|
+
function ps(e, l, t = P(se().format("DD.MM.YYYY")), a = P(null), n = P(null), i = P(!1)) {
|
|
4035
|
+
const o = P(se()), s = () => {
|
|
4022
4036
|
switch (e.value) {
|
|
4023
4037
|
case "day":
|
|
4024
4038
|
o.value = o.value.subtract(1, "month");
|
|
@@ -4044,7 +4058,7 @@ function ps(e, l, t = I(se().format("DD.MM.YYYY")), a = I(null), n = I(null), i
|
|
|
4044
4058
|
}
|
|
4045
4059
|
}, u = () => {
|
|
4046
4060
|
o.value = se();
|
|
4047
|
-
}, f =
|
|
4061
|
+
}, f = R(() => {
|
|
4048
4062
|
const h = se(), y = o.value.year(), g = o.value.month(), $ = l.value || "dd.mm.yy";
|
|
4049
4063
|
switch (e.value) {
|
|
4050
4064
|
case "day":
|
|
@@ -4056,7 +4070,7 @@ function ps(e, l, t = I(se().format("DD.MM.YYYY")), a = I(null), n = I(null), i
|
|
|
4056
4070
|
default:
|
|
4057
4071
|
return [];
|
|
4058
4072
|
}
|
|
4059
|
-
}), m =
|
|
4073
|
+
}), m = R(() => {
|
|
4060
4074
|
const h = [
|
|
4061
4075
|
"Январь",
|
|
4062
4076
|
"Февраль",
|
|
@@ -4111,25 +4125,25 @@ const gs = {
|
|
|
4111
4125
|
}),
|
|
4112
4126
|
emits: ["update:modelValue"],
|
|
4113
4127
|
setup(e) {
|
|
4114
|
-
const l = e, t = Ke(l, "type"), a = Ke(l, "format"), n = Ke(l, "range"), i = Ke(l, "minDate"), o = Ke(l, "maxDate"), s = ie(e, "modelValue"), r =
|
|
4128
|
+
const l = e, t = Ke(l, "type"), a = Ke(l, "format"), n = Ke(l, "range"), i = Ke(l, "minDate"), o = Ke(l, "maxDate"), s = ie(e, "modelValue"), r = P(!1), u = P(""), f = P(m());
|
|
4115
4129
|
function m() {
|
|
4116
4130
|
return t.value === "time" ? "time" : t.value || "day";
|
|
4117
4131
|
}
|
|
4118
|
-
const h =
|
|
4132
|
+
const h = R(() => ["day", "month", "year", "date", "datetime"].includes(t.value || "day")), y = R(() => ["time", "datetime"].includes(t.value || "day")), { calendarCells: g, activeDateInfo: $, goToPreviousPage: S, goToNextPage: O } = ps(f, a, s, i, o, n);
|
|
4119
4133
|
ee([u, s], () => {
|
|
4120
4134
|
t.value === "datetime" && s.value && u.value ? typeof s.value == "string" && (s.value = `${s.value} ${u.value}`) : t.value === "time" && (s.value = u.value);
|
|
4121
4135
|
});
|
|
4122
|
-
const _ =
|
|
4136
|
+
const _ = R({
|
|
4123
4137
|
get() {
|
|
4124
4138
|
return f.value;
|
|
4125
4139
|
},
|
|
4126
4140
|
set(d) {
|
|
4127
4141
|
["date", "datetime"].includes(t.value || "") ? ["day", "month", "year"].includes(d) && (f.value = d) : t.value === "time" ? f.value = "time" : t.value === "day" ? f.value = d : t.value === "month" ? (d === "month" || d === "year") && (f.value = d) : f.value = d;
|
|
4128
4142
|
}
|
|
4129
|
-
}), B =
|
|
4143
|
+
}), B = R(() => [
|
|
4130
4144
|
"calendar",
|
|
4131
4145
|
`calendar--${f.value}`
|
|
4132
|
-
]),
|
|
4146
|
+
]), M = (d) => [
|
|
4133
4147
|
"calendar__body-item",
|
|
4134
4148
|
{
|
|
4135
4149
|
"calendar__body-item--current": d.current,
|
|
@@ -4213,9 +4227,9 @@ const gs = {
|
|
|
4213
4227
|
b("div", _s, [
|
|
4214
4228
|
(v(!0), p(re, null, ge(k(g), (w) => (v(), p("button", {
|
|
4215
4229
|
key: w.value,
|
|
4216
|
-
class: z(
|
|
4230
|
+
class: z(M(w)),
|
|
4217
4231
|
disabled: w.disabled,
|
|
4218
|
-
onClick: (
|
|
4232
|
+
onClick: (I) => x(w)
|
|
4219
4233
|
}, [
|
|
4220
4234
|
b("span", null, j(w.label), 1)
|
|
4221
4235
|
], 10, $s))), 128))
|
|
@@ -4354,17 +4368,17 @@ const Ts = /* @__PURE__ */ Y({
|
|
|
4354
4368
|
emits: /* @__PURE__ */ ae(["update:modelValue", "select", "clear", "focus", "blur", "input"], ["update:modelValue"]),
|
|
4355
4369
|
setup(e, { emit: l }) {
|
|
4356
4370
|
function t(c, w) {
|
|
4357
|
-
let
|
|
4358
|
-
const
|
|
4371
|
+
let I = w;
|
|
4372
|
+
const L = c.dayOfYear(), D = [
|
|
4359
4373
|
// День месяца
|
|
4360
4374
|
[/dd/g, c.format("DD")],
|
|
4361
4375
|
// два знака
|
|
4362
4376
|
[/d/g, c.format("D")],
|
|
4363
4377
|
// без ведущего нуля
|
|
4364
4378
|
// День года
|
|
4365
|
-
[/oo/g, String(
|
|
4379
|
+
[/oo/g, String(L).padStart(3, "0")],
|
|
4366
4380
|
// три знака
|
|
4367
|
-
[/o/g, String(
|
|
4381
|
+
[/o/g, String(L)],
|
|
4368
4382
|
// без ведущих нулей
|
|
4369
4383
|
// Название дня
|
|
4370
4384
|
[/DD/g, c.format("dddd")],
|
|
@@ -4392,29 +4406,29 @@ const Ts = /* @__PURE__ */ Y({
|
|
|
4392
4406
|
// Windows ticks
|
|
4393
4407
|
], N = [];
|
|
4394
4408
|
let q = 0;
|
|
4395
|
-
return
|
|
4409
|
+
return I = I.replace(/'([^']*)'/g, (F, V) => {
|
|
4396
4410
|
const T = `__LITERAL_${q}__`;
|
|
4397
4411
|
return N[q] = V, q++, T;
|
|
4398
|
-
}),
|
|
4399
|
-
|
|
4412
|
+
}), I = I.replace(/''/g, "'"), D.forEach(([F, V]) => {
|
|
4413
|
+
I = I.replace(F, V);
|
|
4400
4414
|
}), N.forEach((F, V) => {
|
|
4401
|
-
|
|
4402
|
-
}),
|
|
4415
|
+
I = I.replace(`__LITERAL_${V}__`, F);
|
|
4416
|
+
}), I;
|
|
4403
4417
|
}
|
|
4404
4418
|
function a(c, w) {
|
|
4405
4419
|
try {
|
|
4406
|
-
const
|
|
4407
|
-
if (
|
|
4408
|
-
return
|
|
4409
|
-
const
|
|
4410
|
-
return
|
|
4420
|
+
const I = se(c, w, !0);
|
|
4421
|
+
if (I.isValid())
|
|
4422
|
+
return I;
|
|
4423
|
+
const L = se(c);
|
|
4424
|
+
return L.isValid() ? L : null;
|
|
4411
4425
|
} catch {
|
|
4412
4426
|
return null;
|
|
4413
4427
|
}
|
|
4414
4428
|
}
|
|
4415
|
-
const n = new Vs(), i = e, o = l, s = ie(e, "modelValue"), r =
|
|
4429
|
+
const n = new Vs(), i = e, o = l, s = ie(e, "modelValue"), r = P(), u = P(), f = P(), m = P(!1), h = P({});
|
|
4416
4430
|
let y = null;
|
|
4417
|
-
const g =
|
|
4431
|
+
const g = P(s.value), { zIndex: $ } = qe("popover"), S = R(() => {
|
|
4418
4432
|
if (!s.value) return "";
|
|
4419
4433
|
if (typeof s.value == "string")
|
|
4420
4434
|
return s.value;
|
|
@@ -4439,8 +4453,8 @@ const Ts = /* @__PURE__ */ Y({
|
|
|
4439
4453
|
return;
|
|
4440
4454
|
}
|
|
4441
4455
|
if (w.value.length === i.format.length) {
|
|
4442
|
-
const
|
|
4443
|
-
|
|
4456
|
+
const I = a(w.value, i.format);
|
|
4457
|
+
I && I.isValid() ? (s.value = w.value, o("select", I.toDate())) : s.value = null;
|
|
4444
4458
|
}
|
|
4445
4459
|
o("input", c);
|
|
4446
4460
|
}, _ = () => {
|
|
@@ -4453,7 +4467,7 @@ const Ts = /* @__PURE__ */ Y({
|
|
|
4453
4467
|
x
|
|
4454
4468
|
));
|
|
4455
4469
|
});
|
|
4456
|
-
},
|
|
4470
|
+
}, M = (c) => {
|
|
4457
4471
|
c && (g.value = c, typeof c == "string" ? (s.value = c, c.length === i.format.length && !i.range && (m.value = !1)) : c instanceof Date ? (s.value = t(se(c), i.format), i.range || (m.value = !1)) : typeof c == "object" && (i.range ? s.value = c : (s.value = c.from || c.to || null, typeof s.value == "string" && s.value.length === i.format.length && (m.value = !1))), o("select", c));
|
|
4458
4472
|
}, x = async () => {
|
|
4459
4473
|
if (!u.value || !f.value) return;
|
|
@@ -4533,8 +4547,8 @@ const Ts = /* @__PURE__ */ Y({
|
|
|
4533
4547
|
K(k(xs), {
|
|
4534
4548
|
modelValue: g.value,
|
|
4535
4549
|
"onUpdate:modelValue": [
|
|
4536
|
-
w[0] || (w[0] = (
|
|
4537
|
-
|
|
4550
|
+
w[0] || (w[0] = (I) => g.value = I),
|
|
4551
|
+
M
|
|
4538
4552
|
],
|
|
4539
4553
|
format: c.format,
|
|
4540
4554
|
range: c.range,
|
|
@@ -4571,14 +4585,14 @@ const Ts = /* @__PURE__ */ Y({
|
|
|
4571
4585
|
}),
|
|
4572
4586
|
emits: /* @__PURE__ */ ae(["change", "complete", "focus", "blur"], ["update:modelValue"]),
|
|
4573
4587
|
setup(e, { emit: l }) {
|
|
4574
|
-
const t = e, a = l, n = ie(e, "modelValue"), i =
|
|
4588
|
+
const t = e, a = l, n = ie(e, "modelValue"), i = P([]), o = P([]), s = R(() => t.length);
|
|
4575
4589
|
ee(() => n.value, (g) => {
|
|
4576
4590
|
o.value = g.split("").concat(Array(Math.max(0, s.value - g.length)).fill(""));
|
|
4577
4591
|
}, { immediate: !0 }), ee(o, (g) => {
|
|
4578
4592
|
const $ = g.join("").slice(0, s.value);
|
|
4579
4593
|
$ !== n.value && (n.value = $, a("change", $), $.length === s.value && $.replace(/\s/g, "").length === s.value && a("complete", $));
|
|
4580
4594
|
}, { deep: !0 });
|
|
4581
|
-
const r =
|
|
4595
|
+
const r = R(() => [
|
|
4582
4596
|
"otp",
|
|
4583
4597
|
`otp--${t.size}`,
|
|
4584
4598
|
`otp--${t.variant}`,
|
|
@@ -4598,8 +4612,8 @@ const Ts = /* @__PURE__ */ Y({
|
|
|
4598
4612
|
}, m = (g, $) => {
|
|
4599
4613
|
$.preventDefault();
|
|
4600
4614
|
const O = ($.clipboardData?.getData("text") || "").slice(0, s.value - g).split("");
|
|
4601
|
-
O.forEach((B,
|
|
4602
|
-
g +
|
|
4615
|
+
O.forEach((B, M) => {
|
|
4616
|
+
g + M < s.value && (o.value[g + M] = B);
|
|
4603
4617
|
});
|
|
4604
4618
|
const _ = Math.min(g + O.length, s.value - 1);
|
|
4605
4619
|
fe(() => {
|
|
@@ -4684,7 +4698,7 @@ const Ts = /* @__PURE__ */ Y({
|
|
|
4684
4698
|
error: Oe(Gl),
|
|
4685
4699
|
warn: Oe(Xl),
|
|
4686
4700
|
info: Oe(vl)
|
|
4687
|
-
}), n =
|
|
4701
|
+
}), n = R(() => e.msg.severity ? e.msg.icon ? e.msg.icon : a[e.msg.severity] : a.info), i = R(() => ["toast-message", `toast-message--${e.msg.severity}`]), o = P(null), s = P(void 0), r = () => {
|
|
4688
4702
|
o.value = setTimeout(() => {
|
|
4689
4703
|
u({ message: e.msg, type: "life-end" });
|
|
4690
4704
|
}, s.value);
|
|
@@ -4728,7 +4742,7 @@ const Ts = /* @__PURE__ */ Y({
|
|
|
4728
4742
|
},
|
|
4729
4743
|
setup(e) {
|
|
4730
4744
|
let l = 0;
|
|
4731
|
-
const t =
|
|
4745
|
+
const t = P([]), a = (u) => {
|
|
4732
4746
|
u.id == null && (u.id = l++), t.value = [...t.value, u];
|
|
4733
4747
|
}, n = (u) => {
|
|
4734
4748
|
const f = t.value.findIndex((m) => m.id === u.message.id);
|
|
@@ -4801,7 +4815,7 @@ const _i = {
|
|
|
4801
4815
|
outlined: Boolean
|
|
4802
4816
|
},
|
|
4803
4817
|
setup(e) {
|
|
4804
|
-
const l = e, t =
|
|
4818
|
+
const l = e, t = R(() => [
|
|
4805
4819
|
"message",
|
|
4806
4820
|
`message--${l.type}`,
|
|
4807
4821
|
{ "message--outlined": l.outlined }
|
|
@@ -4834,7 +4848,7 @@ const _i = {
|
|
|
4834
4848
|
strong: { type: Boolean }
|
|
4835
4849
|
},
|
|
4836
4850
|
setup(e) {
|
|
4837
|
-
const l =
|
|
4851
|
+
const l = R(() => [
|
|
4838
4852
|
"badge",
|
|
4839
4853
|
{
|
|
4840
4854
|
"badge--strong": e.strong,
|
|
@@ -4858,7 +4872,7 @@ const _i = {
|
|
|
4858
4872
|
offset: { default: () => ({ x: -5, y: -7 }) }
|
|
4859
4873
|
},
|
|
4860
4874
|
setup(e) {
|
|
4861
|
-
const l =
|
|
4875
|
+
const l = R(() => typeof e.offset == "number" ? {
|
|
4862
4876
|
left: `calc(100% + ${e.offset}px)`,
|
|
4863
4877
|
top: `${e.offset}px`
|
|
4864
4878
|
} : {
|
|
@@ -4888,13 +4902,13 @@ const _i = {
|
|
|
4888
4902
|
size: {}
|
|
4889
4903
|
},
|
|
4890
4904
|
setup(e) {
|
|
4891
|
-
const l =
|
|
4905
|
+
const l = R(() => [
|
|
4892
4906
|
"skeleton",
|
|
4893
4907
|
`skeleton--${e.shape}`,
|
|
4894
4908
|
{
|
|
4895
4909
|
"skeleton--square": e.size
|
|
4896
4910
|
}
|
|
4897
|
-
]), t =
|
|
4911
|
+
]), t = R(() => ({
|
|
4898
4912
|
"--size": e.size,
|
|
4899
4913
|
width: typeof e.width == "string" ? e.width : `${e.width}px`,
|
|
4900
4914
|
height: typeof e.height == "string" ? e.height : `${e.height}px`,
|
|
@@ -4915,7 +4929,7 @@ const _i = {
|
|
|
4915
4929
|
if (!e)
|
|
4916
4930
|
throw new Error("useConfirmDialog() должен использоваться внутри приложения с DialogService");
|
|
4917
4931
|
return e;
|
|
4918
|
-
}, ce =
|
|
4932
|
+
}, ce = P(null), de = P(null), Us = {
|
|
4919
4933
|
require: (e) => {
|
|
4920
4934
|
ce.value = {
|
|
4921
4935
|
modal: !0,
|
|
@@ -5029,7 +5043,7 @@ const _i = {
|
|
|
5029
5043
|
}, or = { class: "confirm-popup__actions" }, ar = /* @__PURE__ */ Y({
|
|
5030
5044
|
__name: "ConfirmPopup",
|
|
5031
5045
|
setup(e) {
|
|
5032
|
-
const l =
|
|
5046
|
+
const l = P(), t = P({}), a = P("bottom"), { zIndex: n } = qe("popover"), i = R(() => `confirm-popup--${a.value}`), o = R(() => `confirm-popup__arrow--${a.value}`), s = () => {
|
|
5033
5047
|
if (!de.value?.target || !l.value) return;
|
|
5034
5048
|
const y = de.value.target, g = l.value, $ = de.value.position || "bottom";
|
|
5035
5049
|
if (!document.contains(y)) {
|
|
@@ -5041,68 +5055,68 @@ const _i = {
|
|
|
5041
5055
|
u();
|
|
5042
5056
|
return;
|
|
5043
5057
|
}
|
|
5044
|
-
const _ = g.getBoundingClientRect(), B = 8,
|
|
5045
|
-
switch (
|
|
5058
|
+
const _ = g.getBoundingClientRect(), B = 8, M = 8, x = (D) => {
|
|
5059
|
+
switch (D) {
|
|
5046
5060
|
case "top":
|
|
5047
5061
|
return {
|
|
5048
|
-
top: S.top - _.height -
|
|
5062
|
+
top: S.top - _.height - M,
|
|
5049
5063
|
left: S.left + S.width / 2 - _.width / 2
|
|
5050
5064
|
};
|
|
5051
5065
|
case "bottom":
|
|
5052
5066
|
return {
|
|
5053
|
-
top: S.bottom +
|
|
5067
|
+
top: S.bottom + M,
|
|
5054
5068
|
left: S.left + S.width / 2 - _.width / 2
|
|
5055
5069
|
};
|
|
5056
5070
|
case "left":
|
|
5057
5071
|
return {
|
|
5058
5072
|
top: S.top + S.height / 2 - _.height / 2,
|
|
5059
|
-
left: S.left - _.width -
|
|
5073
|
+
left: S.left - _.width - M
|
|
5060
5074
|
};
|
|
5061
5075
|
case "right":
|
|
5062
5076
|
return {
|
|
5063
5077
|
top: S.top + S.height / 2 - _.height / 2,
|
|
5064
|
-
left: S.right +
|
|
5078
|
+
left: S.right + M
|
|
5065
5079
|
};
|
|
5066
5080
|
case "topleft":
|
|
5067
5081
|
return {
|
|
5068
|
-
top: S.top - _.height -
|
|
5082
|
+
top: S.top - _.height - M,
|
|
5069
5083
|
left: S.left
|
|
5070
5084
|
};
|
|
5071
5085
|
case "topright":
|
|
5072
5086
|
return {
|
|
5073
|
-
top: S.top - _.height -
|
|
5087
|
+
top: S.top - _.height - M,
|
|
5074
5088
|
left: S.right - _.width
|
|
5075
5089
|
};
|
|
5076
5090
|
case "bottomleft":
|
|
5077
5091
|
return {
|
|
5078
|
-
top: S.bottom +
|
|
5092
|
+
top: S.bottom + M,
|
|
5079
5093
|
left: S.left
|
|
5080
5094
|
};
|
|
5081
5095
|
case "bottomright":
|
|
5082
5096
|
return {
|
|
5083
|
-
top: S.bottom +
|
|
5097
|
+
top: S.bottom + M,
|
|
5084
5098
|
left: S.right - _.width
|
|
5085
5099
|
};
|
|
5086
5100
|
default:
|
|
5087
5101
|
return { top: 0, left: 0 };
|
|
5088
5102
|
}
|
|
5089
|
-
}, d = (
|
|
5090
|
-
const N = x(
|
|
5103
|
+
}, d = (D) => {
|
|
5104
|
+
const N = x(D);
|
|
5091
5105
|
return N.top >= B && N.left >= B && N.top + _.height <= window.innerHeight - B && N.left + _.width <= window.innerWidth - B;
|
|
5092
5106
|
}, c = [$];
|
|
5093
|
-
["bottomright", "bottom", "top", "right", "left", "bottomleft", "topright", "topleft"].forEach((
|
|
5094
|
-
c.includes(
|
|
5107
|
+
["bottomright", "bottom", "top", "right", "left", "bottomleft", "topright", "topleft"].forEach((D) => {
|
|
5108
|
+
c.includes(D) || c.push(D);
|
|
5095
5109
|
});
|
|
5096
|
-
let
|
|
5097
|
-
for (const
|
|
5098
|
-
if (d(
|
|
5099
|
-
|
|
5110
|
+
let I = $, L = x($);
|
|
5111
|
+
for (const D of c)
|
|
5112
|
+
if (d(D)) {
|
|
5113
|
+
I = D, L = x(D);
|
|
5100
5114
|
break;
|
|
5101
5115
|
}
|
|
5102
|
-
|
|
5116
|
+
L.top = Math.max(B, Math.min(L.top, window.innerHeight - _.height - B)), L.left = Math.max(B, Math.min(L.left, window.innerWidth - _.width - B)), a.value = I, t.value = {
|
|
5103
5117
|
position: "fixed",
|
|
5104
|
-
top: `${
|
|
5105
|
-
left: `${
|
|
5118
|
+
top: `${L.top}px`,
|
|
5119
|
+
left: `${L.left}px`,
|
|
5106
5120
|
zIndex: 1e3
|
|
5107
5121
|
};
|
|
5108
5122
|
}, r = () => {
|
|
@@ -5188,7 +5202,7 @@ const _i = {
|
|
|
5188
5202
|
}),
|
|
5189
5203
|
emits: /* @__PURE__ */ ae(["close"], ["update:open"]),
|
|
5190
5204
|
setup(e, { expose: l, emit: t }) {
|
|
5191
|
-
const { lockScroll: a, unlockScroll: n } = ot(), i = ie(e, "open"), { zIndex: o } = qe("drawer"), s =
|
|
5205
|
+
const { lockScroll: a, unlockScroll: n } = ot(), i = ie(e, "open"), { zIndex: o } = qe("drawer"), s = R(() => {
|
|
5192
5206
|
let h = {};
|
|
5193
5207
|
return e.styleWrapper ? h = {
|
|
5194
5208
|
...h,
|
|
@@ -5269,7 +5283,7 @@ const _i = {
|
|
|
5269
5283
|
}),
|
|
5270
5284
|
emits: ["update:open"],
|
|
5271
5285
|
setup(e) {
|
|
5272
|
-
const { zIndex: l } = qe("modal"), t =
|
|
5286
|
+
const { zIndex: l } = qe("modal"), t = P(e.title), a = ie(e, "open"), n = cl(), { unlockScroll: i, lockScroll: o } = ot(), s = R(() => ["modal", `modal--${e.position}`]), r = (u) => {
|
|
5273
5287
|
t.value = u;
|
|
5274
5288
|
};
|
|
5275
5289
|
return ee(
|
|
@@ -5323,13 +5337,13 @@ const _i = {
|
|
|
5323
5337
|
},
|
|
5324
5338
|
emits: ["update:open"],
|
|
5325
5339
|
setup(e) {
|
|
5326
|
-
const l = ie(e, "open"), { zIndex: t } = qe("modal"), a =
|
|
5340
|
+
const l = ie(e, "open"), { zIndex: t } = qe("modal"), a = P(), n = P(), i = P(0), o = P(!1), s = P(0), r = P(0), u = P(0), f = P(0), m = P(!1), { unlockScroll: h, lockScroll: y } = ot(), g = () => {
|
|
5327
5341
|
l.value = !1;
|
|
5328
5342
|
}, $ = (d) => {
|
|
5329
5343
|
if (!n.value) return;
|
|
5330
5344
|
s.value = d.touches[0].clientY, r.value = s.value, f.value = n.value.scrollTop;
|
|
5331
|
-
const w = d.target.closest(".bottom-sheet__handle"),
|
|
5332
|
-
m.value = !!(w ||
|
|
5345
|
+
const w = d.target.closest(".bottom-sheet__handle"), I = n.value.scrollTop === 0;
|
|
5346
|
+
m.value = !!(w || I), m.value && (o.value = !0);
|
|
5333
5347
|
}, S = (d) => {
|
|
5334
5348
|
if (!o.value || !m.value || !n.value) return;
|
|
5335
5349
|
r.value = d.touches[0].clientY;
|
|
@@ -5347,18 +5361,18 @@ const _i = {
|
|
|
5347
5361
|
s.value = d.touches[0].clientY, r.value = s.value, m.value = !0, o.value = !0;
|
|
5348
5362
|
}, B = (d) => {
|
|
5349
5363
|
o.value = !0, m.value = !0, s.value = d.clientY, r.value = s.value;
|
|
5350
|
-
const c = (
|
|
5364
|
+
const c = (I) => {
|
|
5351
5365
|
if (!o.value || !m.value) return;
|
|
5352
|
-
r.value =
|
|
5353
|
-
const
|
|
5354
|
-
|
|
5366
|
+
r.value = I.clientY;
|
|
5367
|
+
const L = r.value - s.value;
|
|
5368
|
+
L > 0 && (I.preventDefault(), i.value = L);
|
|
5355
5369
|
}, w = () => {
|
|
5356
5370
|
if (!o.value || !m.value) return;
|
|
5357
|
-
const
|
|
5358
|
-
i.value >
|
|
5371
|
+
const I = u.value * 0.3;
|
|
5372
|
+
i.value > I && g(), i.value = 0, o.value = !1, m.value = !1, document.removeEventListener("mousemove", c), document.removeEventListener("mouseup", w);
|
|
5359
5373
|
};
|
|
5360
5374
|
document.addEventListener("mousemove", c), document.addEventListener("mouseup", w);
|
|
5361
|
-
},
|
|
5375
|
+
}, M = () => {
|
|
5362
5376
|
a.value && (a.value.addEventListener("touchstart", $, {
|
|
5363
5377
|
passive: !0
|
|
5364
5378
|
}), a.value.addEventListener("touchmove", S, {
|
|
@@ -5368,9 +5382,9 @@ const _i = {
|
|
|
5368
5382
|
a.value && (a.value.removeEventListener("touchstart", $), a.value.removeEventListener("touchmove", S));
|
|
5369
5383
|
};
|
|
5370
5384
|
return ee(l, async (d) => {
|
|
5371
|
-
d ? (y(), await fe(), a.value && (u.value = a.value.offsetHeight,
|
|
5385
|
+
d ? (y(), await fe(), a.value && (u.value = a.value.offsetHeight, M())) : (h(), x(), i.value = 0);
|
|
5372
5386
|
}), he(() => {
|
|
5373
|
-
l.value && a.value && (u.value = a.value.offsetHeight,
|
|
5387
|
+
l.value && a.value && (u.value = a.value.offsetHeight, M());
|
|
5374
5388
|
}), Ve(() => {
|
|
5375
5389
|
h(), x();
|
|
5376
5390
|
}), (d, c) => (v(), U(Le, { to: "body" }, [
|
|
@@ -5427,7 +5441,7 @@ const _i = {
|
|
|
5427
5441
|
styleView: { default: "fill" }
|
|
5428
5442
|
},
|
|
5429
5443
|
setup(e) {
|
|
5430
|
-
const l =
|
|
5444
|
+
const l = R(() => e.styleView), t = P(
|
|
5431
5445
|
Array.isArray(e.value) ? e.value : e.value !== void 0 ? [e.value] : []
|
|
5432
5446
|
);
|
|
5433
5447
|
ee(() => e.value, (n) => {
|
|
@@ -5443,7 +5457,7 @@ const _i = {
|
|
|
5443
5457
|
}), Bi = /* @__PURE__ */ Y({
|
|
5444
5458
|
__name: "AccordionContent",
|
|
5445
5459
|
setup(e) {
|
|
5446
|
-
const l = ye("panelIsOpen"), t =
|
|
5460
|
+
const l = ye("panelIsOpen"), t = P(null), a = P("0px"), n = P(l.value);
|
|
5447
5461
|
return ee(l, async (i) => {
|
|
5448
5462
|
i ? (n.value = !0, await fe(), a.value = t.value?.scrollHeight + "px") : (a.value = t.value?.scrollHeight + "px", await fe(), a.value = "0px", setTimeout(() => n.value = !1, 300));
|
|
5449
5463
|
}), he(() => {
|
|
@@ -5486,7 +5500,7 @@ const _i = {
|
|
|
5486
5500
|
value: {}
|
|
5487
5501
|
},
|
|
5488
5502
|
setup(e) {
|
|
5489
|
-
const l = e, t = ye("accordionOpenValues"), a = ye("accordionToggle"), n = ye("accordionStyle"), i =
|
|
5503
|
+
const l = e, t = ye("accordionOpenValues"), a = ye("accordionToggle"), n = ye("accordionStyle"), i = R(() => t?.value.includes(l.value));
|
|
5490
5504
|
return _e("panelValue", l.value), _e("panelIsOpen", i), _e("panelToggle", () => a?.(l.value)), (o, s) => (v(), p("div", {
|
|
5491
5505
|
class: z(["accordion-panel", `accordion-panel--${k(n)}`])
|
|
5492
5506
|
}, [
|
|
@@ -5504,7 +5518,7 @@ const _i = {
|
|
|
5504
5518
|
align: { default: "center" }
|
|
5505
5519
|
},
|
|
5506
5520
|
setup(e) {
|
|
5507
|
-
const l =
|
|
5521
|
+
const l = R(() => ["divider", `divider--${e.layouts}`, `divider--${e.type}`, `divider--${e.align}`]);
|
|
5508
5522
|
return (t, a) => (v(), p("div", {
|
|
5509
5523
|
class: z(l.value)
|
|
5510
5524
|
}, [
|
|
@@ -5522,7 +5536,7 @@ const _i = {
|
|
|
5522
5536
|
disabled: { type: Boolean }
|
|
5523
5537
|
},
|
|
5524
5538
|
setup(e) {
|
|
5525
|
-
const l = ye("stepper"), t =
|
|
5539
|
+
const l = ye("stepper"), t = R(() => l?.isStepDisabled() || e.disabled), a = () => {
|
|
5526
5540
|
l?.updateValue(e.value ?? e.index);
|
|
5527
5541
|
};
|
|
5528
5542
|
return (n, i) => (v(), p("div", {
|
|
@@ -5554,7 +5568,7 @@ const _i = {
|
|
|
5554
5568
|
},
|
|
5555
5569
|
emits: ["update:value"],
|
|
5556
5570
|
setup(e, { emit: l }) {
|
|
5557
|
-
const t = l, a =
|
|
5571
|
+
const t = l, a = P(e.value ?? 0);
|
|
5558
5572
|
return _e("stepper", {
|
|
5559
5573
|
isStepActive: (u) => a.value === u,
|
|
5560
5574
|
isStepDisabled: () => e.linear,
|
|
@@ -5583,7 +5597,7 @@ const _i = {
|
|
|
5583
5597
|
value: {}
|
|
5584
5598
|
},
|
|
5585
5599
|
setup(e) {
|
|
5586
|
-
const l = e, t = ye("tabsValue"), a = ye("setTabsValue"), n =
|
|
5600
|
+
const l = e, t = ye("tabsValue"), a = ye("setTabsValue"), n = R(() => t?.value === l.value);
|
|
5587
5601
|
return (i, o) => (v(), p("button", {
|
|
5588
5602
|
class: z(["tab", { "tab--active": n.value }]),
|
|
5589
5603
|
onClick: o[0] || (o[0] = () => k(a)?.(i.value)),
|
|
@@ -5600,7 +5614,7 @@ const _i = {
|
|
|
5600
5614
|
},
|
|
5601
5615
|
emits: ["update:value"],
|
|
5602
5616
|
setup(e, { emit: l }) {
|
|
5603
|
-
const t = e, a = l, n =
|
|
5617
|
+
const t = e, a = l, n = P(t.value);
|
|
5604
5618
|
ee(() => t.value, (o) => {
|
|
5605
5619
|
n.value = o;
|
|
5606
5620
|
});
|
|
@@ -5620,7 +5634,7 @@ const _i = {
|
|
|
5620
5634
|
value: {}
|
|
5621
5635
|
},
|
|
5622
5636
|
setup(e) {
|
|
5623
|
-
const l = e, t = ye("tabsValue"), a =
|
|
5637
|
+
const l = e, t = ye("tabsValue"), a = R(() => t?.value === l.value);
|
|
5624
5638
|
return (n, i) => be((v(), p("div", Vr, [
|
|
5625
5639
|
J(n.$slots, "default")
|
|
5626
5640
|
], 512)), [
|
|
@@ -5658,7 +5672,7 @@ const _i = {
|
|
|
5658
5672
|
maxWidth: { default: 300 }
|
|
5659
5673
|
},
|
|
5660
5674
|
setup(e, { expose: l }) {
|
|
5661
|
-
const t = e, a =
|
|
5675
|
+
const t = e, a = P(), n = P(!1), i = P("top"), o = P({}), s = P({}), { zIndex: r } = qe("tooltip");
|
|
5662
5676
|
let u = null, f = null, m = null;
|
|
5663
5677
|
const h = async () => {
|
|
5664
5678
|
if (!u || !a.value) return;
|
|
@@ -5681,14 +5695,14 @@ const _i = {
|
|
|
5681
5695
|
left: `${S}px`,
|
|
5682
5696
|
top: `${O}px`
|
|
5683
5697
|
}, t.showArrow && B.arrow && $) {
|
|
5684
|
-
const { x:
|
|
5698
|
+
const { x: M, y: x } = B.arrow, d = _.split("-")[0], c = {
|
|
5685
5699
|
top: "bottom",
|
|
5686
5700
|
right: "left",
|
|
5687
5701
|
bottom: "top",
|
|
5688
5702
|
left: "right"
|
|
5689
5703
|
}[d];
|
|
5690
5704
|
s.value = {
|
|
5691
|
-
left:
|
|
5705
|
+
left: M != null ? `${M}px` : "",
|
|
5692
5706
|
top: x != null ? `${x}px` : "",
|
|
5693
5707
|
right: "",
|
|
5694
5708
|
bottom: "",
|
|
@@ -5774,19 +5788,19 @@ const _i = {
|
|
|
5774
5788
|
},
|
|
5775
5789
|
emits: ["update:modelValue", "change", "clear"],
|
|
5776
5790
|
setup(e, { emit: l }) {
|
|
5777
|
-
const t = e, a = l, n =
|
|
5791
|
+
const t = e, a = l, n = P(!1), i = P(), o = P(), s = P({}), r = At({
|
|
5778
5792
|
from: t.modelValue?.from || "",
|
|
5779
5793
|
to: t.modelValue?.to || ""
|
|
5780
5794
|
});
|
|
5781
|
-
function u(
|
|
5782
|
-
let x = 1e3, d =
|
|
5795
|
+
function u(M) {
|
|
5796
|
+
let x = 1e3, d = M;
|
|
5783
5797
|
for (; d && d !== document.body; ) {
|
|
5784
5798
|
const c = window.getComputedStyle(d), w = parseInt(c.zIndex);
|
|
5785
5799
|
!isNaN(w) && w > x && (x = w), d = d.parentElement;
|
|
5786
5800
|
}
|
|
5787
5801
|
return x;
|
|
5788
5802
|
}
|
|
5789
|
-
const f =
|
|
5803
|
+
const f = P(9999), m = R(() => !r.from && !r.to ? "" : r.from && r.to ? `${r.from} - ${r.to}` : r.from ? `с ${r.from}` : r.to ? `до ${r.to}` : ""), h = R(() => !!(r.from || r.to));
|
|
5790
5804
|
function y() {
|
|
5791
5805
|
t.disabled || (n.value = !n.value);
|
|
5792
5806
|
}
|
|
@@ -5794,49 +5808,49 @@ const _i = {
|
|
|
5794
5808
|
n.value = !1;
|
|
5795
5809
|
}
|
|
5796
5810
|
function $() {
|
|
5797
|
-
const
|
|
5811
|
+
const M = {
|
|
5798
5812
|
from: r.from,
|
|
5799
5813
|
to: r.to
|
|
5800
5814
|
};
|
|
5801
|
-
a("update:modelValue",
|
|
5815
|
+
a("update:modelValue", M), a("change", M);
|
|
5802
5816
|
}
|
|
5803
|
-
function S(
|
|
5804
|
-
r.from =
|
|
5817
|
+
function S(M) {
|
|
5818
|
+
r.from = M.from, r.to = M.to, $();
|
|
5805
5819
|
}
|
|
5806
5820
|
function O() {
|
|
5807
5821
|
r.from = "", r.to = "", a("update:modelValue", void 0), a("change", void 0), a("clear");
|
|
5808
5822
|
}
|
|
5809
5823
|
function _() {
|
|
5810
5824
|
!i.value || !n.value || fe(() => {
|
|
5811
|
-
const
|
|
5812
|
-
f.value =
|
|
5813
|
-
const x = i.value.getBoundingClientRect(), d = window.innerHeight, c = window.innerWidth, w = d - x.bottom,
|
|
5825
|
+
const M = u(i.value);
|
|
5826
|
+
f.value = M + 10;
|
|
5827
|
+
const x = i.value.getBoundingClientRect(), d = window.innerHeight, c = window.innerWidth, w = d - x.bottom, I = x.top, D = w < 200 && I > w, N = Math.max(100, x.width);
|
|
5814
5828
|
let q = x.left;
|
|
5815
5829
|
q + N > c && (q = Math.max(0, c - N - 10)), s.value = {
|
|
5816
5830
|
position: "fixed",
|
|
5817
5831
|
left: `${q}px`,
|
|
5818
5832
|
width: `${N}px`,
|
|
5819
5833
|
maxHeight: "200px"
|
|
5820
|
-
},
|
|
5834
|
+
}, D ? s.value.bottom = `${d - x.top + 4}px` : s.value.top = `${x.bottom + 4}px`;
|
|
5821
5835
|
});
|
|
5822
5836
|
}
|
|
5823
|
-
function B(
|
|
5837
|
+
function B(M) {
|
|
5824
5838
|
if (!n.value) return;
|
|
5825
|
-
const x =
|
|
5839
|
+
const x = M.target, d = i.value, c = o.value;
|
|
5826
5840
|
if (!d) return;
|
|
5827
|
-
const w = d.contains(x),
|
|
5828
|
-
!w && !
|
|
5841
|
+
const w = d.contains(x), I = c && c.contains(x);
|
|
5842
|
+
!w && !I && (n.value = !1);
|
|
5829
5843
|
}
|
|
5830
|
-
return ee(() => t.modelValue, (
|
|
5831
|
-
|
|
5832
|
-
}, { deep: !0 }), ee(n, (
|
|
5833
|
-
|
|
5844
|
+
return ee(() => t.modelValue, (M) => {
|
|
5845
|
+
M ? (r.from = M.from || "", r.to = M.to || "") : (r.from = "", r.to = "");
|
|
5846
|
+
}, { deep: !0 }), ee(n, (M) => {
|
|
5847
|
+
M && _();
|
|
5834
5848
|
}), he(() => {
|
|
5835
5849
|
document.addEventListener("click", B, !0), window.addEventListener("resize", _), window.addEventListener("scroll", _);
|
|
5836
5850
|
}), Ve(() => {
|
|
5837
5851
|
document.removeEventListener("click", B, !0), window.removeEventListener("resize", _), window.removeEventListener("scroll", _);
|
|
5838
|
-
}), (
|
|
5839
|
-
class: z(["time-picker", { "time-picker--disabled":
|
|
5852
|
+
}), (M, x) => (v(), p("div", {
|
|
5853
|
+
class: z(["time-picker", { "time-picker--disabled": M.disabled }])
|
|
5840
5854
|
}, [
|
|
5841
5855
|
b("div", {
|
|
5842
5856
|
ref_key: "timePickerTrigger",
|
|
@@ -5845,19 +5859,19 @@ const _i = {
|
|
|
5845
5859
|
onClick: y
|
|
5846
5860
|
}, [
|
|
5847
5861
|
b("div", Ar, [
|
|
5848
|
-
m.value ? J(
|
|
5862
|
+
m.value ? J(M.$slots, "input", {
|
|
5849
5863
|
key: 0,
|
|
5850
5864
|
value: m.value
|
|
5851
5865
|
}, () => [
|
|
5852
5866
|
b("span", Or, j(m.value), 1)
|
|
5853
|
-
], !0) : (v(), p("span", Br, j(
|
|
5867
|
+
], !0) : (v(), p("span", Br, j(M.placeholder), 1))
|
|
5854
5868
|
]),
|
|
5855
5869
|
b("div", {
|
|
5856
5870
|
class: z(["time-picker__arrow", { "time-picker__arrow--rotated": n.value }])
|
|
5857
5871
|
}, [
|
|
5858
5872
|
K(k(bt))
|
|
5859
5873
|
], 2),
|
|
5860
|
-
|
|
5874
|
+
M.clearable && h.value ? (v(), p("button", {
|
|
5861
5875
|
key: 0,
|
|
5862
5876
|
class: "time-picker__clear",
|
|
5863
5877
|
onClick: pe(O, ["stop"])
|
|
@@ -5879,7 +5893,7 @@ const _i = {
|
|
|
5879
5893
|
}, ["stop"]))
|
|
5880
5894
|
}, [
|
|
5881
5895
|
b("div", Er, [
|
|
5882
|
-
J(
|
|
5896
|
+
J(M.$slots, "content", {
|
|
5883
5897
|
close: g,
|
|
5884
5898
|
updateTime: S,
|
|
5885
5899
|
timeRange: r
|
|
@@ -5941,7 +5955,7 @@ const _i = {
|
|
|
5941
5955
|
},
|
|
5942
5956
|
emits: ["update:modelValue", "change", "clear"],
|
|
5943
5957
|
setup(e, { emit: l }) {
|
|
5944
|
-
const t = e, a = l, n =
|
|
5958
|
+
const t = e, a = l, n = P(!1), i = P(), o = P(), s = P({}), r = [
|
|
5945
5959
|
{ key: "monday", label: "Понедельник", enabled: !1 },
|
|
5946
5960
|
{ key: "tuesday", label: "Вторник", enabled: !1 },
|
|
5947
5961
|
{ key: "wednesday", label: "Среда", enabled: !1 },
|
|
@@ -5949,22 +5963,22 @@ const _i = {
|
|
|
5949
5963
|
{ key: "friday", label: "Пятница", enabled: !1 },
|
|
5950
5964
|
{ key: "saturday", label: "Суббота", enabled: !1 },
|
|
5951
5965
|
{ key: "sunday", label: "Воскресенье", enabled: !1 }
|
|
5952
|
-
], u =
|
|
5966
|
+
], u = R(() => t.modelValue && t.modelValue.length > 0 ? t.modelValue : r);
|
|
5953
5967
|
he(() => {
|
|
5954
5968
|
(!t.modelValue || t.modelValue.length === 0) && a("update:modelValue", r);
|
|
5955
5969
|
});
|
|
5956
5970
|
function f(x) {
|
|
5957
5971
|
let d = 1e3, c = x;
|
|
5958
5972
|
for (; c && c !== document.body; ) {
|
|
5959
|
-
const w = window.getComputedStyle(c),
|
|
5960
|
-
!isNaN(
|
|
5973
|
+
const w = window.getComputedStyle(c), I = parseInt(w.zIndex);
|
|
5974
|
+
!isNaN(I) && I > d && (d = I), c = c.parentElement;
|
|
5961
5975
|
}
|
|
5962
5976
|
return d;
|
|
5963
5977
|
}
|
|
5964
|
-
const m =
|
|
5978
|
+
const m = P(9999), h = R(() => {
|
|
5965
5979
|
const x = u.value.filter((d) => d.enabled);
|
|
5966
5980
|
return x.length === 0 ? "" : x.length === 7 ? "Все дни недели" : x.map((d) => d.label).join(", ");
|
|
5967
|
-
}), y =
|
|
5981
|
+
}), y = R(() => u.value.some((x) => x.enabled));
|
|
5968
5982
|
function g() {
|
|
5969
5983
|
t.disabled || (n.value = !n.value);
|
|
5970
5984
|
}
|
|
@@ -5991,7 +6005,7 @@ const _i = {
|
|
|
5991
6005
|
!i.value || !n.value || fe(() => {
|
|
5992
6006
|
const x = f(i.value);
|
|
5993
6007
|
m.value = x + 10;
|
|
5994
|
-
const d = i.value.getBoundingClientRect(), c = window.innerHeight, w = window.innerWidth,
|
|
6008
|
+
const d = i.value.getBoundingClientRect(), c = window.innerHeight, w = window.innerWidth, I = c - d.bottom, L = d.top, N = I < 400 && L > I, q = Math.max(300, d.width);
|
|
5995
6009
|
let F = d.left;
|
|
5996
6010
|
F + q > w && (F = Math.max(0, w - q - 10)), s.value = {
|
|
5997
6011
|
position: "fixed",
|
|
@@ -6001,17 +6015,17 @@ const _i = {
|
|
|
6001
6015
|
}, N ? s.value.bottom = `${c - d.top + 4}px` : s.value.top = `${d.bottom + 4}px`;
|
|
6002
6016
|
});
|
|
6003
6017
|
}
|
|
6004
|
-
function
|
|
6018
|
+
function M(x) {
|
|
6005
6019
|
if (!i.value || !n.value) return;
|
|
6006
|
-
const d = x.target, c = o.value, w = i.value.contains(d),
|
|
6007
|
-
!w && !
|
|
6020
|
+
const d = x.target, c = o.value, w = i.value.contains(d), I = c && c.contains(d);
|
|
6021
|
+
!w && !I && (n.value = !1);
|
|
6008
6022
|
}
|
|
6009
6023
|
return ee(n, (x) => {
|
|
6010
6024
|
x && B();
|
|
6011
6025
|
}), he(() => {
|
|
6012
|
-
document.addEventListener("click",
|
|
6026
|
+
document.addEventListener("click", M), window.addEventListener("resize", B), window.addEventListener("scroll", B);
|
|
6013
6027
|
}), Ve(() => {
|
|
6014
|
-
document.removeEventListener("click",
|
|
6028
|
+
document.removeEventListener("click", M), window.removeEventListener("resize", B), window.removeEventListener("scroll", B);
|
|
6015
6029
|
}), (x, d) => (v(), p("div", {
|
|
6016
6030
|
class: z(["schedule", { "schedule--disabled": x.disabled }])
|
|
6017
6031
|
}, [
|