sprof 1.22.7 → 1.22.9
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/sprof.js
CHANGED
|
@@ -2,7 +2,7 @@ var $c = Object.defineProperty;
|
|
|
2
2
|
var Tc = (t, e, n) => e in t ? $c(t, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : t[e] = n;
|
|
3
3
|
var u = (t, e, n) => Tc(t, typeof e != "symbol" ? e + "" : e, n);
|
|
4
4
|
import { Notify as sa, Dialog as oa, QBtn as vn, QItemLabel as qs, QTooltip as xr, QInput as as, QMenu as Ta, QList as Ei, QItem as Bn, QItemSection as hn, QIcon as re, QSeparator as Zi, QDialog as Pc, QCard as Xt, QCardSection as kt, QCardActions as ti, ClosePopup as Wn, QSpace as _n, QSlideTransition as Rc, QCheckbox as Ic, QPopupProxy as Ci, QDate as Ks, date as Jn, QSelect as Mc, QToggle as gl, QRadio as Ac, QUploader as Ec, QUploaderAddTrigger as Fc, QImg as Oc, QSpinner as vl, QBadge as yl, QTime as bl, QTabs as wl, QTab as Sl, QTd as wn, QScrollArea as Dc, QSpinnerDots as zc, QTable as Lc, QTr as $r, QInnerLoading as Vc, QTh as Tr, QTabPanels as Cl, QTabPanel as kl, QSplitter as _c, QChip as Uc, QForm as Bc, QCarousel as qc, QCarouselSlide as Nc, Ripple as Hc, Quasar as jc } from "quasar";
|
|
5
|
-
import { reactive as ht, ref as O, openBlock as m, createElementBlock as S, createElementVNode as y, onBeforeMount as Sn, computed as D, defineComponent as j, useAttrs as an, createBlock as z, unref as f, mergeProps as at, withCtx as C, renderSlot as N, createTextVNode as be, toDisplayString as U, normalizeClass as ve, createVNode as g, normalizeStyle as J, useModel as
|
|
5
|
+
import { reactive as ht, ref as O, openBlock as m, createElementBlock as S, createElementVNode as y, onBeforeMount as Sn, computed as D, defineComponent as j, useAttrs as an, createBlock as z, unref as f, mergeProps as at, withCtx as C, renderSlot as N, createTextVNode as be, toDisplayString as U, normalizeClass as ve, createVNode as g, normalizeStyle as J, useModel as vt, createSlots as di, mergeModels as De, resolveDirective as Pa, withDirectives as Je, Fragment as K, createCommentVNode as G, watch as Ae, isRef as Ie, TransitionGroup as xl, renderList as we, withModifiers as Ye, vShow as eo, inject as Gc, getCurrentInstance as Wc, provide as Yc, normalizeProps as Os, guardReactiveProps as Ds, nextTick as Ji, resolveComponent as Me, resolveDynamicComponent as Rn, onMounted as Fi, onBeforeUnmount as rs, withKeys as Ns, mergeDefaults as Qc, markRaw as Xc, useCssVars as $l, createStaticVNode as Tl, onUpdated as Zc, useTemplateRef as Jc, onUnmounted as Kc, defineAsyncComponent as ef, getCurrentScope as Pl, onScopeDispose as Rl } from "vue";
|
|
6
6
|
import { onBeforeRouteLeave as tf, useRouter as nf } from "vue-router";
|
|
7
7
|
import si from "vuedraggable";
|
|
8
8
|
var Et = /* @__PURE__ */ ((t) => (t.Login = "login", t.Register = "register", t.Restore = "restore", t.Refresh = "refresh", t))(Et || {}), Be = /* @__PURE__ */ ((t) => (t.Primary = "primary", t.Success = "success", t.Warning = "warning", t.Error = "error", t.Info = "info", t))(Be || {});
|
|
@@ -687,19 +687,19 @@ var Mr;
|
|
|
687
687
|
}, h = Object.getPrototypeOf(Function), p = typeof Map == "function" && typeof Map.prototype.entries == "function" ? Map : Ro(), b = typeof Set == "function" && typeof Set.prototype.entries == "function" ? Set : Io(), k = typeof WeakMap == "function" ? WeakMap : ws(), P = s ? Symbol.for("@reflect-metadata:registry") : void 0, E = Ui(), T = ci(E);
|
|
688
688
|
function M(F, _, H, ne) {
|
|
689
689
|
if (oe(H)) {
|
|
690
|
-
if (!
|
|
690
|
+
if (!pt(F))
|
|
691
691
|
throw new TypeError();
|
|
692
692
|
if (!An(_))
|
|
693
693
|
throw new TypeError();
|
|
694
|
-
return
|
|
694
|
+
return Ke(F, _);
|
|
695
695
|
} else {
|
|
696
|
-
if (!
|
|
696
|
+
if (!pt(F))
|
|
697
697
|
throw new TypeError();
|
|
698
698
|
if (!We(_))
|
|
699
699
|
throw new TypeError();
|
|
700
700
|
if (!We(ne) && !oe(ne) && !ut(ne))
|
|
701
701
|
throw new TypeError();
|
|
702
|
-
return ut(ne) && (ne = void 0), H = Oe(H),
|
|
702
|
+
return ut(ne) && (ne = void 0), H = Oe(H), mt(F, _, H, ne);
|
|
703
703
|
}
|
|
704
704
|
}
|
|
705
705
|
e("decorate", M);
|
|
@@ -723,7 +723,7 @@ var Mr;
|
|
|
723
723
|
function $(F, _, H) {
|
|
724
724
|
if (!We(_))
|
|
725
725
|
throw new TypeError();
|
|
726
|
-
return oe(H) || (H = Oe(H)),
|
|
726
|
+
return oe(H) || (H = Oe(H)), Xe(F, _, H);
|
|
727
727
|
}
|
|
728
728
|
e("hasMetadata", $);
|
|
729
729
|
function B(F, _, H) {
|
|
@@ -741,7 +741,7 @@ var Mr;
|
|
|
741
741
|
function L(F, _, H) {
|
|
742
742
|
if (!We(_))
|
|
743
743
|
throw new TypeError();
|
|
744
|
-
return oe(H) || (H = Oe(H)),
|
|
744
|
+
return oe(H) || (H = Oe(H)), Vt(F, _, H);
|
|
745
745
|
}
|
|
746
746
|
e("getOwnMetadata", L);
|
|
747
747
|
function Q(F, _) {
|
|
@@ -762,7 +762,7 @@ var Mr;
|
|
|
762
762
|
if (oe(H) || (H = Oe(H)), !We(_))
|
|
763
763
|
throw new TypeError();
|
|
764
764
|
oe(H) || (H = Oe(H));
|
|
765
|
-
var ne =
|
|
765
|
+
var ne = Ze(
|
|
766
766
|
_,
|
|
767
767
|
H,
|
|
768
768
|
/*Create*/
|
|
@@ -771,7 +771,7 @@ var Mr;
|
|
|
771
771
|
return oe(ne) ? !1 : ne.OrdinaryDeleteMetadata(F, _, H);
|
|
772
772
|
}
|
|
773
773
|
e("deleteMetadata", ke);
|
|
774
|
-
function
|
|
774
|
+
function Ke(F, _) {
|
|
775
775
|
for (var H = F.length - 1; H >= 0; --H) {
|
|
776
776
|
var ne = F[H], pe = ne(_);
|
|
777
777
|
if (!oe(pe) && !ut(pe)) {
|
|
@@ -782,26 +782,26 @@ var Mr;
|
|
|
782
782
|
}
|
|
783
783
|
return _;
|
|
784
784
|
}
|
|
785
|
-
function
|
|
785
|
+
function mt(F, _, H, ne) {
|
|
786
786
|
for (var pe = F.length - 1; pe >= 0; --pe) {
|
|
787
|
-
var ot = F[pe],
|
|
788
|
-
if (!oe(
|
|
789
|
-
if (!We(
|
|
787
|
+
var ot = F[pe], et = ot(_, H, ne);
|
|
788
|
+
if (!oe(et) && !ut(et)) {
|
|
789
|
+
if (!We(et))
|
|
790
790
|
throw new TypeError();
|
|
791
|
-
ne =
|
|
791
|
+
ne = et;
|
|
792
792
|
}
|
|
793
793
|
}
|
|
794
794
|
return ne;
|
|
795
795
|
}
|
|
796
|
-
function
|
|
796
|
+
function Xe(F, _, H) {
|
|
797
797
|
var ne = rt(F, _, H);
|
|
798
798
|
if (ne)
|
|
799
799
|
return !0;
|
|
800
800
|
var pe = Qn(_);
|
|
801
|
-
return ut(pe) ? !1 :
|
|
801
|
+
return ut(pe) ? !1 : Xe(F, pe, H);
|
|
802
802
|
}
|
|
803
803
|
function rt(F, _, H) {
|
|
804
|
-
var ne =
|
|
804
|
+
var ne = Ze(
|
|
805
805
|
_,
|
|
806
806
|
H,
|
|
807
807
|
/*Create*/
|
|
@@ -812,13 +812,13 @@ var Mr;
|
|
|
812
812
|
function lt(F, _, H) {
|
|
813
813
|
var ne = rt(F, _, H);
|
|
814
814
|
if (ne)
|
|
815
|
-
return
|
|
815
|
+
return Vt(F, _, H);
|
|
816
816
|
var pe = Qn(_);
|
|
817
817
|
if (!ut(pe))
|
|
818
818
|
return lt(F, pe, H);
|
|
819
819
|
}
|
|
820
|
-
function
|
|
821
|
-
var ne =
|
|
820
|
+
function Vt(F, _, H) {
|
|
821
|
+
var ne = Ze(
|
|
822
822
|
_,
|
|
823
823
|
H,
|
|
824
824
|
/*Create*/
|
|
@@ -828,7 +828,7 @@ var Mr;
|
|
|
828
828
|
return ne.OrdinaryGetOwnMetadata(F, _, H);
|
|
829
829
|
}
|
|
830
830
|
function yt(F, _, H, ne) {
|
|
831
|
-
var pe =
|
|
831
|
+
var pe = Ze(
|
|
832
832
|
H,
|
|
833
833
|
ne,
|
|
834
834
|
/*Create*/
|
|
@@ -845,18 +845,18 @@ var Mr;
|
|
|
845
845
|
return H;
|
|
846
846
|
if (H.length <= 0)
|
|
847
847
|
return pe;
|
|
848
|
-
for (var ot = new b(),
|
|
848
|
+
for (var ot = new b(), et = [], $e = 0, ie = H; $e < ie.length; $e++) {
|
|
849
849
|
var ae = ie[$e], le = ot.has(ae);
|
|
850
|
-
le || (ot.add(ae),
|
|
850
|
+
le || (ot.add(ae), et.push(ae));
|
|
851
851
|
}
|
|
852
852
|
for (var de = 0, Te = pe; de < Te.length; de++) {
|
|
853
853
|
var ae = Te[de], le = ot.has(ae);
|
|
854
|
-
le || (ot.add(ae),
|
|
854
|
+
le || (ot.add(ae), et.push(ae));
|
|
855
855
|
}
|
|
856
|
-
return
|
|
856
|
+
return et;
|
|
857
857
|
}
|
|
858
858
|
function Dt(F, _) {
|
|
859
|
-
var H =
|
|
859
|
+
var H = Ze(
|
|
860
860
|
F,
|
|
861
861
|
_,
|
|
862
862
|
/*create*/
|
|
@@ -864,7 +864,7 @@ var Mr;
|
|
|
864
864
|
);
|
|
865
865
|
return H ? H.OrdinaryOwnMetadataKeys(F, _) : [];
|
|
866
866
|
}
|
|
867
|
-
function
|
|
867
|
+
function Ue(F) {
|
|
868
868
|
if (F === null)
|
|
869
869
|
return 1;
|
|
870
870
|
switch (typeof F) {
|
|
@@ -897,7 +897,7 @@ var Mr;
|
|
|
897
897
|
return typeof F == "object" ? F !== null : typeof F == "function";
|
|
898
898
|
}
|
|
899
899
|
function Z(F, _) {
|
|
900
|
-
switch (
|
|
900
|
+
switch (Ue(F)) {
|
|
901
901
|
case 0:
|
|
902
902
|
return F;
|
|
903
903
|
case 1:
|
|
@@ -948,7 +948,7 @@ var Mr;
|
|
|
948
948
|
var _ = Z(F);
|
|
949
949
|
return en(_) ? _ : me(_);
|
|
950
950
|
}
|
|
951
|
-
function
|
|
951
|
+
function pt(F) {
|
|
952
952
|
return Array.isArray ? Array.isArray(F) : F instanceof Object ? F instanceof Array : Object.prototype.toString.call(F) === "[object Array]";
|
|
953
953
|
}
|
|
954
954
|
function bt(F) {
|
|
@@ -958,7 +958,7 @@ var Mr;
|
|
|
958
958
|
return typeof F == "function";
|
|
959
959
|
}
|
|
960
960
|
function En(F) {
|
|
961
|
-
switch (
|
|
961
|
+
switch (Ue(F)) {
|
|
962
962
|
case 3:
|
|
963
963
|
return !0;
|
|
964
964
|
case 4:
|
|
@@ -987,14 +987,14 @@ var Mr;
|
|
|
987
987
|
throw new TypeError();
|
|
988
988
|
return H;
|
|
989
989
|
}
|
|
990
|
-
function
|
|
990
|
+
function _t(F) {
|
|
991
991
|
return F.value;
|
|
992
992
|
}
|
|
993
993
|
function jt(F) {
|
|
994
994
|
var _ = F.next();
|
|
995
995
|
return _.done ? !1 : _;
|
|
996
996
|
}
|
|
997
|
-
function
|
|
997
|
+
function Ut(F) {
|
|
998
998
|
var _ = F.return;
|
|
999
999
|
_ && _.call(F);
|
|
1000
1000
|
}
|
|
@@ -1012,12 +1012,12 @@ var Mr;
|
|
|
1012
1012
|
var F;
|
|
1013
1013
|
!oe(P) && typeof n.Reflect < "u" && !(P in n.Reflect) && typeof n.Reflect.defineMetadata == "function" && (F = Po(n.Reflect));
|
|
1014
1014
|
var _, H, ne, pe = new k(), ot = {
|
|
1015
|
-
registerProvider:
|
|
1015
|
+
registerProvider: et,
|
|
1016
1016
|
getProvider: ie,
|
|
1017
1017
|
setProvider: le
|
|
1018
1018
|
};
|
|
1019
1019
|
return ot;
|
|
1020
|
-
function
|
|
1020
|
+
function et(de) {
|
|
1021
1021
|
if (!Object.isExtensible(ot))
|
|
1022
1022
|
throw new Error("Cannot add provider to a frozen registry.");
|
|
1023
1023
|
switch (!0) {
|
|
@@ -1050,9 +1050,9 @@ var Mr;
|
|
|
1050
1050
|
var je = jt(He);
|
|
1051
1051
|
if (!je)
|
|
1052
1052
|
return;
|
|
1053
|
-
var St =
|
|
1053
|
+
var St = _t(je);
|
|
1054
1054
|
if (St.isProviderFor(de, Te))
|
|
1055
|
-
return
|
|
1055
|
+
return Ut(He), St;
|
|
1056
1056
|
}
|
|
1057
1057
|
}
|
|
1058
1058
|
}
|
|
@@ -1096,7 +1096,7 @@ var Mr;
|
|
|
1096
1096
|
var de = _.get(ae);
|
|
1097
1097
|
return oe(de) ? !1 : de.has(le);
|
|
1098
1098
|
},
|
|
1099
|
-
OrdinaryDefineOwnMetadata:
|
|
1099
|
+
OrdinaryDefineOwnMetadata: et,
|
|
1100
1100
|
OrdinaryHasOwnMetadata: pe,
|
|
1101
1101
|
OrdinaryGetOwnMetadata: ot,
|
|
1102
1102
|
OrdinaryOwnMetadataKeys: $e,
|
|
@@ -1138,7 +1138,7 @@ var Mr;
|
|
|
1138
1138
|
if (!oe(Te))
|
|
1139
1139
|
return Te.get(ae);
|
|
1140
1140
|
}
|
|
1141
|
-
function
|
|
1141
|
+
function et(ae, le, de, Te) {
|
|
1142
1142
|
var He = ne(
|
|
1143
1143
|
de,
|
|
1144
1144
|
Te,
|
|
@@ -1160,12 +1160,12 @@ var Mr;
|
|
|
1160
1160
|
var Ss = jt(je);
|
|
1161
1161
|
if (!Ss)
|
|
1162
1162
|
return de.length = St, de;
|
|
1163
|
-
var Cs =
|
|
1163
|
+
var Cs = _t(Ss);
|
|
1164
1164
|
try {
|
|
1165
1165
|
de[St] = Cs;
|
|
1166
1166
|
} catch (Mo) {
|
|
1167
1167
|
try {
|
|
1168
|
-
|
|
1168
|
+
Ut(je);
|
|
1169
1169
|
} finally {
|
|
1170
1170
|
throw Mo;
|
|
1171
1171
|
}
|
|
@@ -1190,10 +1190,10 @@ var Mr;
|
|
|
1190
1190
|
}
|
|
1191
1191
|
}
|
|
1192
1192
|
function Po(F) {
|
|
1193
|
-
var _ = F.defineMetadata, H = F.hasOwnMetadata, ne = F.getOwnMetadata, pe = F.getOwnMetadataKeys, ot = F.deleteMetadata,
|
|
1193
|
+
var _ = F.defineMetadata, H = F.hasOwnMetadata, ne = F.getOwnMetadata, pe = F.getOwnMetadataKeys, ot = F.deleteMetadata, et = new k(), $e = {
|
|
1194
1194
|
isProviderFor: function(ie, ae) {
|
|
1195
|
-
var le =
|
|
1196
|
-
return !oe(le) && le.has(ae) ? !0 : pe(ie, ae).length ? (oe(le) && (le = new b(),
|
|
1195
|
+
var le = et.get(ie);
|
|
1196
|
+
return !oe(le) && le.has(ae) ? !0 : pe(ie, ae).length ? (oe(le) && (le = new b(), et.set(ie, le)), le.add(ae), !0) : !1;
|
|
1197
1197
|
},
|
|
1198
1198
|
OrdinaryDefineOwnMetadata: _,
|
|
1199
1199
|
OrdinaryHasOwnMetadata: H,
|
|
@@ -1203,7 +1203,7 @@ var Mr;
|
|
|
1203
1203
|
};
|
|
1204
1204
|
return $e;
|
|
1205
1205
|
}
|
|
1206
|
-
function
|
|
1206
|
+
function Ze(F, _, H) {
|
|
1207
1207
|
var ne = E.getProvider(F, _);
|
|
1208
1208
|
if (!oe(ne))
|
|
1209
1209
|
return ne;
|
|
@@ -1288,7 +1288,7 @@ var Mr;
|
|
|
1288
1288
|
}, $e.prototype.values = function() {
|
|
1289
1289
|
return new H(this._keys, this._values, ot);
|
|
1290
1290
|
}, $e.prototype.entries = function() {
|
|
1291
|
-
return new H(this._keys, this._values,
|
|
1291
|
+
return new H(this._keys, this._values, et);
|
|
1292
1292
|
}, $e.prototype["@@iterator"] = function() {
|
|
1293
1293
|
return this.entries();
|
|
1294
1294
|
}, $e.prototype[a] = function() {
|
|
@@ -1313,7 +1313,7 @@ var Mr;
|
|
|
1313
1313
|
function ot($e, ie) {
|
|
1314
1314
|
return ie;
|
|
1315
1315
|
}
|
|
1316
|
-
function
|
|
1316
|
+
function et($e, ie) {
|
|
1317
1317
|
return [$e, ie];
|
|
1318
1318
|
}
|
|
1319
1319
|
}
|
|
@@ -1414,7 +1414,7 @@ var Mr;
|
|
|
1414
1414
|
ie[le] = Math.random() * 255 | 0;
|
|
1415
1415
|
return ie;
|
|
1416
1416
|
}
|
|
1417
|
-
function
|
|
1417
|
+
function et(ie) {
|
|
1418
1418
|
if (typeof Uint8Array == "function") {
|
|
1419
1419
|
var ae = new Uint8Array(ie);
|
|
1420
1420
|
return typeof crypto < "u" ? crypto.getRandomValues(ae) : typeof msCrypto < "u" ? msCrypto.getRandomValues(ae) : ot(ae, ie), ae;
|
|
@@ -1422,7 +1422,7 @@ var Mr;
|
|
|
1422
1422
|
return ot(new Array(ie), ie);
|
|
1423
1423
|
}
|
|
1424
1424
|
function $e() {
|
|
1425
|
-
var ie =
|
|
1425
|
+
var ie = et(F);
|
|
1426
1426
|
ie[6] = ie[6] & 79 | 64, ie[8] = ie[8] & 191 | 128;
|
|
1427
1427
|
for (var ae = "", le = 0; le < F; ++le) {
|
|
1428
1428
|
var de = ie[le];
|
|
@@ -1457,7 +1457,7 @@ function Cf(t, e, n) {
|
|
|
1457
1457
|
throw new Error("Random bytes length must be >= 16");
|
|
1458
1458
|
return i[6] = i[6] & 15 | 64, i[8] = i[8] & 63 | 128, bf(i);
|
|
1459
1459
|
}
|
|
1460
|
-
class
|
|
1460
|
+
class Lt {
|
|
1461
1461
|
static UUID() {
|
|
1462
1462
|
return Hn();
|
|
1463
1463
|
}
|
|
@@ -1672,7 +1672,7 @@ const Tn = class Tn {
|
|
|
1672
1672
|
}
|
|
1673
1673
|
static InitClassInstance(e, n) {
|
|
1674
1674
|
const i = e.constructor(n);
|
|
1675
|
-
return Tn.BuildClass(i), i.id =
|
|
1675
|
+
return Tn.BuildClass(i), i.id = Lt.UUID(), i;
|
|
1676
1676
|
}
|
|
1677
1677
|
static ExistsWithId(e, n) {
|
|
1678
1678
|
return e.some((i) => i.id === n);
|
|
@@ -1708,7 +1708,7 @@ let Ce = Tn, es = class Fl {
|
|
|
1708
1708
|
}
|
|
1709
1709
|
static Create() {
|
|
1710
1710
|
const e = new Fl();
|
|
1711
|
-
return e.id =
|
|
1711
|
+
return e.id = Lt.UUID(), e;
|
|
1712
1712
|
}
|
|
1713
1713
|
};
|
|
1714
1714
|
const Bo = "/api/static";
|
|
@@ -1776,10 +1776,10 @@ class Nt {
|
|
|
1776
1776
|
}
|
|
1777
1777
|
static CreatePreviewFile(e, n) {
|
|
1778
1778
|
const i = new Nt();
|
|
1779
|
-
return i.id = n ??
|
|
1779
|
+
return i.id = n ?? Lt.UUID(), i.originalName = e.name, i.file = e.blob, i.fileSystemPath = Lt.UUID(), i;
|
|
1780
1780
|
}
|
|
1781
1781
|
setFile(e) {
|
|
1782
|
-
this.id || (this.id =
|
|
1782
|
+
this.id || (this.id = Lt.UUID()), this.originalName = e.name, this.file = e, this.fileSystemPath = Lt.UUID(), this.url = e.src;
|
|
1783
1783
|
}
|
|
1784
1784
|
clearFile() {
|
|
1785
1785
|
this.url = "", this.file = void 0, this.fileSystemPath = "", this.originalName = "";
|
|
@@ -1851,7 +1851,7 @@ class oi {
|
|
|
1851
1851
|
}
|
|
1852
1852
|
static Create() {
|
|
1853
1853
|
const e = new oi();
|
|
1854
|
-
return e.id =
|
|
1854
|
+
return e.id = Lt.UUID(), e;
|
|
1855
1855
|
}
|
|
1856
1856
|
}
|
|
1857
1857
|
class js {
|
|
@@ -1872,7 +1872,7 @@ class so {
|
|
|
1872
1872
|
}
|
|
1873
1873
|
static Create() {
|
|
1874
1874
|
const e = new so();
|
|
1875
|
-
return e.id =
|
|
1875
|
+
return e.id = Lt.UUID(), e;
|
|
1876
1876
|
}
|
|
1877
1877
|
}
|
|
1878
1878
|
class Ia {
|
|
@@ -1931,7 +1931,7 @@ class yn {
|
|
|
1931
1931
|
e[n].order = n + 1, e[n + 1] && (e[n + 1].order = n), [e[n], e[n + 1]] = [e[n + 1], e[n]];
|
|
1932
1932
|
}
|
|
1933
1933
|
}
|
|
1934
|
-
var
|
|
1934
|
+
var Ee = /* @__PURE__ */ ((t) => (t.Date = "date", t.String = "string", t.Boolean = "boolean", t.Number = "number", t.Set = "set", t.Join = "join", t.ArrayString = "arrayString", t.ArrayNumber = "arrayNumber", t))(Ee || {}), Qe = /* @__PURE__ */ ((t) => (t.Eq = "=", t.Ne = "!=", t.Gt = ">", t.Lt = "<", t.Btw = "between", t.In = "in", t.Like = "like", t.Null = "is null", t.NotNull = "is not null", t))(Qe || {}), $f = Object.defineProperty, Tf = (t, e, n, i) => {
|
|
1935
1935
|
for (var s = void 0, o = t.length - 1, a; o >= 0; o--)
|
|
1936
1936
|
(a = t[o]) && (s = a(e, n, s) || s);
|
|
1937
1937
|
return s && $f(e, n, s), s;
|
|
@@ -1942,13 +1942,13 @@ const Dl = class Hi {
|
|
|
1942
1942
|
u(this, "model", "");
|
|
1943
1943
|
u(this, "label", "");
|
|
1944
1944
|
u(this, "col", "");
|
|
1945
|
-
u(this, "operator",
|
|
1945
|
+
u(this, "operator", Qe.Eq);
|
|
1946
1946
|
u(this, "date1");
|
|
1947
1947
|
u(this, "date2");
|
|
1948
1948
|
u(this, "value1", "");
|
|
1949
1949
|
u(this, "boolean", !1);
|
|
1950
1950
|
u(this, "number", 0);
|
|
1951
|
-
u(this, "type",
|
|
1951
|
+
u(this, "type", Ee.String);
|
|
1952
1952
|
u(this, "set", []);
|
|
1953
1953
|
u(this, "isSet", !1);
|
|
1954
1954
|
/**
|
|
@@ -1967,17 +1967,17 @@ const Dl = class Hi {
|
|
|
1967
1967
|
eq(e) {
|
|
1968
1968
|
if (!e)
|
|
1969
1969
|
return !1;
|
|
1970
|
-
if (this.type ===
|
|
1970
|
+
if (this.type === Ee.Join) {
|
|
1971
1971
|
const n = e.model === this.model && e.operator === this.operator && this.joinTableModel === e.joinTableModel;
|
|
1972
|
-
return e.operator ===
|
|
1972
|
+
return e.operator === Qe.In ? n && yn.Eq(this.set, e.set) : n;
|
|
1973
1973
|
}
|
|
1974
1974
|
return e.model === this.model && e.col === this.col && e.operator === this.operator;
|
|
1975
1975
|
}
|
|
1976
1976
|
valueEq(e) {
|
|
1977
|
-
return !this || !e || !this.eq(e) ? !1 : this.type ===
|
|
1977
|
+
return !this || !e || !this.eq(e) ? !1 : this.type === Ee.Boolean ? this.boolean === (e == null ? void 0 : e.boolean) : this.type === Ee.String ? this.value1 === (e == null ? void 0 : e.value1) : this.type === Ee.Join && this.set.length ? yn.Eq(this.set, e.set) : !1;
|
|
1978
1978
|
}
|
|
1979
1979
|
toUrlQuery() {
|
|
1980
|
-
const e = this.type ? `"type":"${this.type}"` : "", n = this.group ? `"group":${this.group}` : "", i = this.model ? `"model":"${this.model}"` : "", s = this.col ? `"col":"${this.col}"` : "", o = this.operator ? `"operator":"${this.operator}"` : "", a = this.value1 ? `"value1":"${this.value1}"` : "", l = this.type ===
|
|
1980
|
+
const e = this.type ? `"type":"${this.type}"` : "", n = this.group ? `"group":${this.group}` : "", i = this.model ? `"model":"${this.model}"` : "", s = this.col ? `"col":"${this.col}"` : "", o = this.operator ? `"operator":"${this.operator}"` : "", a = this.value1 ? `"value1":"${this.value1}"` : "", l = this.type === Ee.Boolean ? `"boolean":${this.boolean}` : "", r = this.type === Ee.Date && this.date1 ? `"date1":"${this.date1.toISOString()}"` : "", d = this.type === Ee.Date && this.date2 ? `"date2":"${this.date2.toISOString()}"` : "", c = this.type === Ee.Number ? `"number":${this.number}` : "", h = this.type === Ee.Set || this.operator === Qe.In ? `"set":${JSON.stringify(this.set)}` : "", p = this.type === Ee.Join ? `"joinTableModel":"${this.joinTableModel}"` : "";
|
|
1981
1981
|
return [e, i, s, o, a, l, r, d, c, h, p, n].filter((b) => b !== "").toString();
|
|
1982
1982
|
}
|
|
1983
1983
|
/**
|
|
@@ -1987,17 +1987,17 @@ const Dl = class Hi {
|
|
|
1987
1987
|
* (это использует `SearchStore`).
|
|
1988
1988
|
*/
|
|
1989
1989
|
isUnaryFilter() {
|
|
1990
|
-
return this.operator ===
|
|
1990
|
+
return this.operator === Qe.Eq || this.operator === Qe.Gt || this.operator === Qe.Lt;
|
|
1991
1991
|
}
|
|
1992
1992
|
isBetweenFilter() {
|
|
1993
|
-
return this.operator ===
|
|
1993
|
+
return this.operator === Qe.Btw;
|
|
1994
1994
|
}
|
|
1995
1995
|
isSetFilter() {
|
|
1996
|
-
return this.operator ===
|
|
1996
|
+
return this.operator === Qe.In;
|
|
1997
1997
|
}
|
|
1998
1998
|
static Create(e, n, i) {
|
|
1999
1999
|
const s = new Hi();
|
|
2000
|
-
return s.model = e.GetClassName(), s.col = n ?? "", s.type = i, s.type ===
|
|
2000
|
+
return s.model = e.GetClassName(), s.col = n ?? "", s.type = i, s.type === Ee.Number && (s.value1 = ""), s.type === Ee.String && (s.value1 = ""), s.type === Ee.Boolean && (s.value1 = "false", s.operator = Qe.Eq), s;
|
|
2001
2001
|
}
|
|
2002
2002
|
static CreateFilterModelWithJoin(e, n, i, s, o, a, l, r) {
|
|
2003
2003
|
const d = new Hi();
|
|
@@ -2005,11 +2005,11 @@ const Dl = class Hi {
|
|
|
2005
2005
|
}
|
|
2006
2006
|
static CreateFilterModelWithJoinV2(e, n, i, s, o, a, l) {
|
|
2007
2007
|
const r = new Hi();
|
|
2008
|
-
return r.model = e, r.joinTableModel = i, r.joinTablePk = s, r.joinTableFk = o, r.col = n, r.type =
|
|
2008
|
+
return r.model = e, r.joinTableModel = i, r.joinTablePk = s, r.joinTableFk = o, r.col = n, r.type = Ee.Join, a && (r.joinTableId = a), l && (r.joinTableIdCol = l), r;
|
|
2009
2009
|
}
|
|
2010
2010
|
static OnlyIfSecondModelExists(e, n) {
|
|
2011
2011
|
const i = new Hi();
|
|
2012
|
-
return i.id = Hn(), i.model = nt.ToCamelCase(e.GetClassName()), i.joinTableModel = nt.ToCamelCase(n.GetClassName()), i.type =
|
|
2012
|
+
return i.id = Hn(), i.model = nt.ToCamelCase(e.GetClassName()), i.joinTableModel = nt.ToCamelCase(n.GetClassName()), i.type = Ee.Join, i;
|
|
2013
2013
|
}
|
|
2014
2014
|
addToSet(...e) {
|
|
2015
2015
|
e.forEach((n) => {
|
|
@@ -2049,10 +2049,10 @@ const Dl = class Hi {
|
|
|
2049
2049
|
return;
|
|
2050
2050
|
}
|
|
2051
2051
|
if (!n) {
|
|
2052
|
-
this.setDate1(e), this.operator =
|
|
2052
|
+
this.setDate1(e), this.operator = Qe.Eq;
|
|
2053
2053
|
return;
|
|
2054
2054
|
}
|
|
2055
|
-
this.setDate2(n), this.operator =
|
|
2055
|
+
this.setDate2(n), this.operator = Qe.Btw;
|
|
2056
2056
|
}
|
|
2057
2057
|
};
|
|
2058
2058
|
Tf([
|
|
@@ -2061,7 +2061,7 @@ Tf([
|
|
|
2061
2061
|
let Ma = Dl;
|
|
2062
2062
|
class Pf {
|
|
2063
2063
|
constructor() {
|
|
2064
|
-
u(this, "operation",
|
|
2064
|
+
u(this, "operation", Qe.Lt);
|
|
2065
2065
|
u(this, "column", "");
|
|
2066
2066
|
u(this, "value");
|
|
2067
2067
|
u(this, "initial", !0);
|
|
@@ -2100,10 +2100,10 @@ class ts {
|
|
|
2100
2100
|
Ce.BuildClass(this, e);
|
|
2101
2101
|
}
|
|
2102
2102
|
setLoadMore(e, n, i) {
|
|
2103
|
-
this.cursor.value = e, this.cursor.initial = !1, this.cursor.operation =
|
|
2103
|
+
this.cursor.value = e, this.cursor.initial = !1, this.cursor.operation = Qe.Gt, this.cursor.column = n, this.cursor.tableName = i, this.cursorMode = !0;
|
|
2104
2104
|
}
|
|
2105
2105
|
setLoadMoreV2(e, n, i) {
|
|
2106
|
-
this.cursor.value = e, this.cursor.initial = !1, this.cursor.operation =
|
|
2106
|
+
this.cursor.value = e, this.cursor.initial = !1, this.cursor.operation = Qe.Gt, this.cursor.column = n, this.cursor.model = i, this.cursorMode = !0, this.version = "v2";
|
|
2107
2107
|
}
|
|
2108
2108
|
setOffset(e) {
|
|
2109
2109
|
this.offset = e;
|
|
@@ -2186,8 +2186,8 @@ var Rf = Object.defineProperty, ao = (t, e, n, i) => {
|
|
|
2186
2186
|
for (var s = void 0, o = t.length - 1, a; o >= 0; o--)
|
|
2187
2187
|
(a = t[o]) && (s = a(e, n, s) || s);
|
|
2188
2188
|
return s && Rf(e, n, s), s;
|
|
2189
|
-
},
|
|
2190
|
-
const us = (
|
|
2189
|
+
}, zt;
|
|
2190
|
+
const us = (zt = class {
|
|
2191
2191
|
constructor(e) {
|
|
2192
2192
|
u(this, "id");
|
|
2193
2193
|
u(this, "f", []);
|
|
@@ -2197,7 +2197,7 @@ const us = (Ut = class {
|
|
|
2197
2197
|
Ce.BuildClass(this, e);
|
|
2198
2198
|
}
|
|
2199
2199
|
static Get() {
|
|
2200
|
-
return this.instance || (this.instance =
|
|
2200
|
+
return this.instance || (this.instance = zt.create()), this.instance;
|
|
2201
2201
|
}
|
|
2202
2202
|
/**
|
|
2203
2203
|
* Фабрика (Т1 TECH_DEBT): реактивный экземпляр на страницу/компонент.
|
|
@@ -2207,15 +2207,31 @@ const us = (Ut = class {
|
|
|
2207
2207
|
* чтобы фильтры/пагинация не «перетекали» между разделами.
|
|
2208
2208
|
*/
|
|
2209
2209
|
static create() {
|
|
2210
|
-
return ht(new
|
|
2210
|
+
return ht(new zt());
|
|
2211
2211
|
}
|
|
2212
2212
|
createFrom(e) {
|
|
2213
|
-
const n = new
|
|
2213
|
+
const n = new zt(JSON.parse(e));
|
|
2214
2214
|
this.f = n.f;
|
|
2215
2215
|
}
|
|
2216
2216
|
clearForHTTP() {
|
|
2217
|
-
const e = new
|
|
2218
|
-
return e.f = this.f.map((n) =>
|
|
2217
|
+
const e = new zt(this);
|
|
2218
|
+
return e.f = this.f.filter((n) => !!n && !zt.isEmptyFilter(n)).map((n) => zt.EmptyEntiries(n)), e.s = this.s.map((n) => zt.EmptyEntiries(n)), e.p = zt.EmptyEntiries(this.p), e.t = zt.EmptyEntiries(this.t), e;
|
|
2219
|
+
}
|
|
2220
|
+
/**
|
|
2221
|
+
* Фильтр ничего не отбирает — в запрос не идёт.
|
|
2222
|
+
*
|
|
2223
|
+
* `is null` / `is not null` — значимы ВСЕГДА (у них нет значения). Остальные:
|
|
2224
|
+
* boolean — только `true` (дефолт `false` = «не фильтруем»; тумблеры с
|
|
2225
|
+
* инвертированной логикой помечают модель и передают `true`), строки/числа —
|
|
2226
|
+
* непустое значение, `in`/join — непустой набор.
|
|
2227
|
+
*
|
|
2228
|
+
* ⚠️ `like ''` — это ФИЛЬТР (Postgres вернёт пустой список), а не «не задано»:
|
|
2229
|
+
* пустой поиск, оставшийся в FTSP после очистки поля, обнулял выборку
|
|
2230
|
+
* (07.11: «очистил поиск — список не вернулся»). Пустое значение модели —
|
|
2231
|
+
* единственный признак «фильтра нет».
|
|
2232
|
+
*/
|
|
2233
|
+
static isEmptyFilter(e) {
|
|
2234
|
+
return e ? e.operator === Qe.Null || e.operator === Qe.NotNull ? !1 : e.type === Ee.Boolean ? e.boolean !== !0 : e.type === Ee.Join || e.operator === Qe.In ? e.set.length === 0 : e.type === Ee.Date ? !e.date1 && !e.date2 : e.value1 === void 0 || e.value1 === null || e.value1 === "" : !0;
|
|
2219
2235
|
}
|
|
2220
2236
|
static EmptyEntiries(e) {
|
|
2221
2237
|
if (!e)
|
|
@@ -2251,7 +2267,7 @@ const us = (Ut = class {
|
|
|
2251
2267
|
resetF() {
|
|
2252
2268
|
this.f = [];
|
|
2253
2269
|
}
|
|
2254
|
-
}, u(
|
|
2270
|
+
}, u(zt, "instance"), zt);
|
|
2255
2271
|
ao([
|
|
2256
2272
|
Ce.GetClassConstructor(Ma)
|
|
2257
2273
|
], us.prototype, "f");
|
|
@@ -2265,20 +2281,20 @@ ao([
|
|
|
2265
2281
|
Ce.GetClassConstructor(oo)
|
|
2266
2282
|
], us.prototype, "t");
|
|
2267
2283
|
let Ht = us;
|
|
2268
|
-
const If = "ftsp", Mf = [
|
|
2269
|
-
[
|
|
2270
|
-
[
|
|
2271
|
-
[
|
|
2272
|
-
[
|
|
2273
|
-
[
|
|
2274
|
-
[
|
|
2284
|
+
const If = "ftsp", Mf = [Qe.NotNull, Qe.Null], la = {
|
|
2285
|
+
[Ee.String]: "s",
|
|
2286
|
+
[Ee.Number]: "n",
|
|
2287
|
+
[Ee.Boolean]: "b",
|
|
2288
|
+
[Ee.Date]: "d",
|
|
2289
|
+
[Ee.Set]: "e",
|
|
2290
|
+
[Ee.Join]: "j"
|
|
2275
2291
|
};
|
|
2276
2292
|
function Ar(t) {
|
|
2277
|
-
return Mf.includes(t.operator) ? !0 : t.type ===
|
|
2293
|
+
return Mf.includes(t.operator) ? !0 : t.type === Ee.Boolean ? t.boolean === !0 : t.type === Ee.Date ? !!(t.date1 || t.date2) : t.type === Ee.Number ? t.value1 !== void 0 && t.value1 !== "" : t.type === Ee.Join || t.operator === Qe.In ? t.set.length > 0 : !!t.value1;
|
|
2278
2294
|
}
|
|
2279
2295
|
function Af(t) {
|
|
2280
2296
|
const e = {};
|
|
2281
|
-
return t.model && (e.model = t.model), t.col && (e.col = t.col), e.t = la[t.type] ?? t.type, e.operator = t.operator, t.group && (e.group = t.group), t.joinTableModel && (e.joinTableModel = t.joinTableModel), t.type ===
|
|
2297
|
+
return t.model && (e.model = t.model), t.col && (e.col = t.col), e.t = la[t.type] ?? t.type, e.operator = t.operator, t.group && (e.group = t.group), t.joinTableModel && (e.joinTableModel = t.joinTableModel), t.type === Ee.Boolean ? e.boolean = t.boolean : t.type === Ee.Date ? (t.date1 && (e.date1 = t.date1), t.date2 && (e.date2 = t.date2)) : t.type === Ee.Join || t.operator === Qe.In ? e.set = t.set : t.value1 !== void 0 && (e.value1 = t.value1), e;
|
|
2282
2298
|
}
|
|
2283
2299
|
function Ef(t) {
|
|
2284
2300
|
const e = new TextEncoder().encode(t);
|
|
@@ -2299,7 +2315,7 @@ function ua(t) {
|
|
|
2299
2315
|
function Of(t) {
|
|
2300
2316
|
return Array.isArray(t) ? t.filter(ua).map((e) => {
|
|
2301
2317
|
const { t: n, ...i } = e, s = new Ma();
|
|
2302
|
-
return s.model = i.model ?? "", s.col = i.col ?? "", s.operator = i.operator ??
|
|
2318
|
+
return s.model = i.model ?? "", s.col = i.col ?? "", s.operator = i.operator ?? Qe.Eq, s.type = n && Object.keys(la).find((o) => la[o] === n) || s.type, s.group = i.group ?? 0, s.joinTableModel = i.joinTableModel ?? "", s.boolean = i.boolean ?? !1, s.value1 = i.value1 ?? "", s.set = Array.isArray(i.set) ? i.set : [], s.date1 = i.date1 ? new Date(i.date1) : void 0, s.date2 = i.date2 ? new Date(i.date2) : void 0, s;
|
|
2303
2319
|
}) : [];
|
|
2304
2320
|
}
|
|
2305
2321
|
let yi = null;
|
|
@@ -3973,18 +3989,18 @@ const za = "1.18.1", Hr = 64 * 1024, { isFunction: Ps } = A, $m = (t) => encodeU
|
|
|
3973
3989
|
onUploadProgress: Q,
|
|
3974
3990
|
responseType: xe,
|
|
3975
3991
|
headers: ke,
|
|
3976
|
-
withCredentials:
|
|
3977
|
-
fetchOptions:
|
|
3978
|
-
maxContentLength:
|
|
3992
|
+
withCredentials: Ke = "same-origin",
|
|
3993
|
+
fetchOptions: mt,
|
|
3994
|
+
maxContentLength: Xe,
|
|
3979
3995
|
maxBodyLength: rt
|
|
3980
3996
|
} = nu(T);
|
|
3981
|
-
const lt = A.isNumber(
|
|
3997
|
+
const lt = A.isNumber(Xe) && Xe > -1, Vt = A.isNumber(rt) && rt > -1, yt = (Z) => A.hasOwnProp(T, Z) ? T[Z] : void 0;
|
|
3982
3998
|
let un = s || fetch;
|
|
3983
3999
|
xe = xe ? (xe + "").toLowerCase() : "text";
|
|
3984
4000
|
let Dt = bm(
|
|
3985
4001
|
[$, B && B.toAbortSignal()],
|
|
3986
4002
|
I
|
|
3987
|
-
),
|
|
4003
|
+
), Ue = null;
|
|
3988
4004
|
const oe = Dt && Dt.unsubscribe && (() => {
|
|
3989
4005
|
Dt.unsubscribe();
|
|
3990
4006
|
});
|
|
@@ -3993,7 +4009,7 @@ const za = "1.18.1", Hr = 64 * 1024, { isFunction: Ps } = A, $m = (t) => encodeU
|
|
|
3993
4009
|
"Request body larger than maxBodyLength limit",
|
|
3994
4010
|
se.ERR_BAD_REQUEST,
|
|
3995
4011
|
T,
|
|
3996
|
-
|
|
4012
|
+
Ue
|
|
3997
4013
|
);
|
|
3998
4014
|
try {
|
|
3999
4015
|
let Z;
|
|
@@ -4008,10 +4024,10 @@ const za = "1.18.1", Hr = 64 * 1024, { isFunction: Ps } = A, $m = (t) => encodeU
|
|
|
4008
4024
|
if (Tm(M)) {
|
|
4009
4025
|
const Se = new URL(M, $t.origin);
|
|
4010
4026
|
if (!Z && (Se.username || Se.password)) {
|
|
4011
|
-
const dt = jr(Se.username),
|
|
4027
|
+
const dt = jr(Se.username), _t = jr(Se.password);
|
|
4012
4028
|
Z = {
|
|
4013
4029
|
username: dt,
|
|
4014
|
-
password:
|
|
4030
|
+
password: _t
|
|
4015
4031
|
};
|
|
4016
4032
|
}
|
|
4017
4033
|
(Se.username || Se.password) && (Se.username = "", Se.password = "", M = Se.href);
|
|
@@ -4019,27 +4035,27 @@ const za = "1.18.1", Hr = 64 * 1024, { isFunction: Ps } = A, $m = (t) => encodeU
|
|
|
4019
4035
|
if (Z && (ke.delete("authorization"), ke.set(
|
|
4020
4036
|
"Authorization",
|
|
4021
4037
|
"Basic " + btoa($m((Z.username || "") + ":" + (Z.password || "")))
|
|
4022
|
-
)), lt && typeof M == "string" && M.startsWith("data:") && xm(M) >
|
|
4038
|
+
)), lt && typeof M == "string" && M.startsWith("data:") && xm(M) > Xe)
|
|
4023
4039
|
throw new se(
|
|
4024
|
-
"maxContentLength size of " +
|
|
4040
|
+
"maxContentLength size of " + Xe + " exceeded",
|
|
4025
4041
|
se.ERR_BAD_RESPONSE,
|
|
4026
4042
|
T,
|
|
4027
|
-
|
|
4043
|
+
Ue
|
|
4028
4044
|
);
|
|
4029
|
-
if (
|
|
4045
|
+
if (Vt && x !== "get" && x !== "head") {
|
|
4030
4046
|
const Se = await P(V);
|
|
4031
4047
|
if (typeof Se == "number" && isFinite(Se) && (ut = Se, Se > rt))
|
|
4032
4048
|
throw We();
|
|
4033
4049
|
}
|
|
4034
|
-
const Fe =
|
|
4050
|
+
const Fe = Vt && (A.isReadableStream(V) || A.isStream(V)), me = (Se, dt, _t) => Nr(
|
|
4035
4051
|
Se,
|
|
4036
4052
|
Hr,
|
|
4037
4053
|
(jt) => {
|
|
4038
|
-
if (
|
|
4054
|
+
if (Vt && jt > rt)
|
|
4039
4055
|
throw en = We();
|
|
4040
4056
|
dt && dt(jt);
|
|
4041
4057
|
},
|
|
4042
|
-
|
|
4058
|
+
_t
|
|
4043
4059
|
);
|
|
4044
4060
|
if (p && x !== "get" && x !== "head" && (Q || Fe)) {
|
|
4045
4061
|
if (ut = ut ?? await E(ke, V), ut !== 0 || Fe) {
|
|
@@ -4049,11 +4065,11 @@ const za = "1.18.1", Hr = 64 * 1024, { isFunction: Ps } = A, $m = (t) => encodeU
|
|
|
4049
4065
|
duplex: "half"
|
|
4050
4066
|
}), dt;
|
|
4051
4067
|
if (A.isFormData(V) && (dt = Se.headers.get("content-type")) && ke.setContentType(dt), Se.body) {
|
|
4052
|
-
const [
|
|
4068
|
+
const [_t, jt] = Q && _r(
|
|
4053
4069
|
ut,
|
|
4054
4070
|
Ws(Ur(Q))
|
|
4055
4071
|
) || [];
|
|
4056
|
-
V = me(Se.body,
|
|
4072
|
+
V = me(Se.body, _t, jt);
|
|
4057
4073
|
}
|
|
4058
4074
|
}
|
|
4059
4075
|
} else if (Fe && !r && c && x !== "get" && x !== "head")
|
|
@@ -4063,35 +4079,35 @@ const za = "1.18.1", Hr = 64 * 1024, { isFunction: Ps } = A, $m = (t) => encodeU
|
|
|
4063
4079
|
"Stream request bodies are not supported by the current fetch implementation",
|
|
4064
4080
|
se.ERR_NOT_SUPPORT,
|
|
4065
4081
|
T,
|
|
4066
|
-
|
|
4082
|
+
Ue
|
|
4067
4083
|
);
|
|
4068
|
-
A.isString(
|
|
4084
|
+
A.isString(Ke) || (Ke = Ke ? "include" : "omit");
|
|
4069
4085
|
const Oe = r && "credentials" in o.prototype;
|
|
4070
4086
|
if (A.isFormData(V)) {
|
|
4071
4087
|
const Se = ke.getContentType();
|
|
4072
4088
|
Se && /^multipart\/form-data/i.test(Se) && !/boundary=/i.test(Se) && ke.delete("content-type");
|
|
4073
4089
|
}
|
|
4074
4090
|
ke.set("User-Agent", "axios/" + za, !1);
|
|
4075
|
-
const
|
|
4076
|
-
...
|
|
4091
|
+
const pt = {
|
|
4092
|
+
...mt,
|
|
4077
4093
|
signal: Dt,
|
|
4078
4094
|
method: x.toUpperCase(),
|
|
4079
4095
|
headers: jl(ke.normalize()),
|
|
4080
4096
|
body: V,
|
|
4081
4097
|
duplex: "half",
|
|
4082
|
-
credentials: Oe ?
|
|
4098
|
+
credentials: Oe ? Ke : void 0
|
|
4083
4099
|
};
|
|
4084
|
-
|
|
4085
|
-
let bt = await (r ? un(
|
|
4100
|
+
Ue = r && new o(M, pt);
|
|
4101
|
+
let bt = await (r ? un(Ue, mt) : un(M, pt));
|
|
4086
4102
|
const An = Ot.from(bt.headers);
|
|
4087
4103
|
if (lt) {
|
|
4088
4104
|
const Se = A.toFiniteNumber(An.getContentLength());
|
|
4089
|
-
if (Se != null && Se >
|
|
4105
|
+
if (Se != null && Se > Xe)
|
|
4090
4106
|
throw new se(
|
|
4091
|
-
"maxContentLength size of " +
|
|
4107
|
+
"maxContentLength size of " + Xe + " exceeded",
|
|
4092
4108
|
se.ERR_BAD_RESPONSE,
|
|
4093
4109
|
T,
|
|
4094
|
-
|
|
4110
|
+
Ue
|
|
4095
4111
|
);
|
|
4096
4112
|
}
|
|
4097
4113
|
const En = b && (xe === "stream" || xe === "response");
|
|
@@ -4100,20 +4116,20 @@ const za = "1.18.1", Hr = 64 * 1024, { isFunction: Ps } = A, $m = (t) => encodeU
|
|
|
4100
4116
|
["status", "statusText", "headers"].forEach((dn) => {
|
|
4101
4117
|
Se[dn] = bt[dn];
|
|
4102
4118
|
});
|
|
4103
|
-
const dt = A.toFiniteNumber(An.getContentLength()), [
|
|
4119
|
+
const dt = A.toFiniteNumber(An.getContentLength()), [_t, jt] = L && _r(
|
|
4104
4120
|
dt,
|
|
4105
4121
|
Ws(Ur(L), !0)
|
|
4106
4122
|
) || [];
|
|
4107
|
-
let
|
|
4123
|
+
let Ut = 0;
|
|
4108
4124
|
const Qn = (dn) => {
|
|
4109
|
-
if (lt && (
|
|
4125
|
+
if (lt && (Ut = dn, Ut > Xe))
|
|
4110
4126
|
throw new se(
|
|
4111
|
-
"maxContentLength size of " +
|
|
4127
|
+
"maxContentLength size of " + Xe + " exceeded",
|
|
4112
4128
|
se.ERR_BAD_RESPONSE,
|
|
4113
4129
|
T,
|
|
4114
|
-
|
|
4130
|
+
Ue
|
|
4115
4131
|
);
|
|
4116
|
-
|
|
4132
|
+
_t && _t(dn);
|
|
4117
4133
|
};
|
|
4118
4134
|
bt = new a(
|
|
4119
4135
|
Nr(bt.body, Hr, Qn, () => {
|
|
@@ -4129,12 +4145,12 @@ const za = "1.18.1", Hr = 64 * 1024, { isFunction: Ps } = A, $m = (t) => encodeU
|
|
|
4129
4145
|
);
|
|
4130
4146
|
if (lt && !b && !En) {
|
|
4131
4147
|
let Se;
|
|
4132
|
-
if (wt != null && (typeof wt.byteLength == "number" ? Se = wt.byteLength : typeof wt.size == "number" ? Se = wt.size : typeof wt == "string" && (Se = typeof i == "function" ? new i().encode(wt).byteLength : wt.length)), typeof Se == "number" && Se >
|
|
4148
|
+
if (wt != null && (typeof wt.byteLength == "number" ? Se = wt.byteLength : typeof wt.size == "number" ? Se = wt.size : typeof wt == "string" && (Se = typeof i == "function" ? new i().encode(wt).byteLength : wt.length)), typeof Se == "number" && Se > Xe)
|
|
4133
4149
|
throw new se(
|
|
4134
|
-
"maxContentLength size of " +
|
|
4150
|
+
"maxContentLength size of " + Xe + " exceeded",
|
|
4135
4151
|
se.ERR_BAD_RESPONSE,
|
|
4136
4152
|
T,
|
|
4137
|
-
|
|
4153
|
+
Ue
|
|
4138
4154
|
);
|
|
4139
4155
|
}
|
|
4140
4156
|
return !En && oe && oe(), await new Promise((Se, dt) => {
|
|
@@ -4144,13 +4160,13 @@ const za = "1.18.1", Hr = 64 * 1024, { isFunction: Ps } = A, $m = (t) => encodeU
|
|
|
4144
4160
|
status: bt.status,
|
|
4145
4161
|
statusText: bt.statusText,
|
|
4146
4162
|
config: T,
|
|
4147
|
-
request:
|
|
4163
|
+
request: Ue
|
|
4148
4164
|
});
|
|
4149
4165
|
});
|
|
4150
4166
|
} catch (Z) {
|
|
4151
4167
|
if (oe && oe(), Dt && Dt.aborted && Dt.reason instanceof se) {
|
|
4152
4168
|
const te = Dt.reason;
|
|
4153
|
-
throw te.config = T,
|
|
4169
|
+
throw te.config = T, Ue && (te.request = Ue), Z !== te && Object.defineProperty(te, "cause", {
|
|
4154
4170
|
__proto__: null,
|
|
4155
4171
|
value: Z,
|
|
4156
4172
|
writable: !0,
|
|
@@ -4159,15 +4175,15 @@ const za = "1.18.1", Hr = 64 * 1024, { isFunction: Ps } = A, $m = (t) => encodeU
|
|
|
4159
4175
|
}), te;
|
|
4160
4176
|
}
|
|
4161
4177
|
if (en)
|
|
4162
|
-
throw
|
|
4178
|
+
throw Ue && !en.request && (en.request = Ue), en;
|
|
4163
4179
|
if (Z instanceof se)
|
|
4164
|
-
throw
|
|
4180
|
+
throw Ue && !Z.request && (Z.request = Ue), Z;
|
|
4165
4181
|
if (Z && Z.name === "TypeError" && /Load failed|fetch/i.test(Z.message)) {
|
|
4166
4182
|
const te = new se(
|
|
4167
4183
|
"Network Error",
|
|
4168
4184
|
se.ERR_NETWORK,
|
|
4169
4185
|
T,
|
|
4170
|
-
|
|
4186
|
+
Ue,
|
|
4171
4187
|
Z && Z.response
|
|
4172
4188
|
);
|
|
4173
4189
|
throw Object.defineProperty(te, "cause", {
|
|
@@ -4178,7 +4194,7 @@ const za = "1.18.1", Hr = 64 * 1024, { isFunction: Ps } = A, $m = (t) => encodeU
|
|
|
4178
4194
|
configurable: !0
|
|
4179
4195
|
}), te;
|
|
4180
4196
|
}
|
|
4181
|
-
throw se.from(Z, Z && Z.code, T,
|
|
4197
|
+
throw se.from(Z, Z && Z.code, T, Ue, Z && Z.response);
|
|
4182
4198
|
}
|
|
4183
4199
|
};
|
|
4184
4200
|
}, Rm = /* @__PURE__ */ new Map(), iu = (t) => {
|
|
@@ -5981,7 +5997,7 @@ var Pe;
|
|
|
5981
5997
|
let Cp = (Pe = class {
|
|
5982
5998
|
}, u(Pe, "Arrays", yn), u(Pe, "Axios", Gi), u(Pe, "BaseStore", st), // static Phone = Phone;
|
|
5983
5999
|
u(Pe, "Cache", Un), u(Pe, "Classes", Ce), u(Pe, "CarouselSwipe", Bm), u(Pe, "Color", Nm), u(Pe, "CreateSortModels", uu), u(Pe, "Cursor", Hm), u(Pe, "DateMask", Xm), u(Pe, "Dates", At), u(Pe, "Dragger", Km), u(Pe, "Extension", du), u(Pe, "Favourite", ep), // static FTSP = FTSP;
|
|
5984
|
-
u(Pe, "Hooks", cu), u(Pe, "HttpClient", qe), u(Pe, "Id",
|
|
6000
|
+
u(Pe, "Hooks", cu), u(Pe, "HttpClient", qe), u(Pe, "Id", Lt), u(Pe, "MakeCarousel", sp), u(Pe, "Period", aa), u(Pe, "PhoneService", ga), u(Pe, "Rating", op), u(Pe, "Router", Kt), u(Pe, "RouterGuard", ap), u(Pe, "Scheduler", rp), u(Pe, "Scroll", up), // static Sizes = Sizes;
|
|
5985
6001
|
u(Pe, "Sorter", dp), u(Pe, "Static", io), // static Statuses = Statuses;
|
|
5986
6002
|
u(Pe, "Strings", nt), u(Pe, "Time", Re), u(Pe, "Timer", Qs), u(Pe, "Token", is), u(Pe, "Try", Pi), u(Pe, "Menus", _a), // static useConfirmLeavePage = useConfirmLeavePage();
|
|
5987
6003
|
u(Pe, "Validate", yp), u(Pe, "WaitElement", bp), u(Pe, "WebSocketClient", Sp), Pe);
|
|
@@ -6113,7 +6129,7 @@ const ms = class yu {
|
|
|
6113
6129
|
}
|
|
6114
6130
|
static Create() {
|
|
6115
6131
|
const e = new yu();
|
|
6116
|
-
return e.id =
|
|
6132
|
+
return e.id = Lt.UUID(), e;
|
|
6117
6133
|
}
|
|
6118
6134
|
removeEmail(e) {
|
|
6119
6135
|
Ce.RemoveFromClassById(e, this.emails);
|
|
@@ -6403,7 +6419,7 @@ let nn = (Gt = class {
|
|
|
6403
6419
|
}, u(Gt, "Auth", Rp), u(Gt, "Contacts", Ep), u(Gt, "Emails", Op), u(Gt, "FileInfos", new st(Nt, "file-infos")), u(Gt, "Humans", zp), u(Gt, "Phones", Vp), u(Gt, "Schemas", Np), u(Gt, "UserAccounts", Yp), u(Gt, "ValueTypes", Xp), u(Gt, "Search", va), Gt);
|
|
6404
6420
|
var Ft = /* @__PURE__ */ ((t) => (t.XS = "xs", t.S = "s", t.M = "m", t.L = "l", t.XL = "xl", t))(Ft || {}), zn;
|
|
6405
6421
|
let Zp = (zn = class {
|
|
6406
|
-
}, u(zn, "Orders", Qt), u(zn, "Sizes", Ft), u(zn, "Statuses", Be), u(zn, "DataTypes",
|
|
6422
|
+
}, u(zn, "Orders", Qt), u(zn, "Sizes", Ft), u(zn, "Statuses", Be), u(zn, "DataTypes", Ee), u(zn, "ValueTypes", Mt), u(zn, "Operators", Qe), zn);
|
|
6407
6423
|
class Jp {
|
|
6408
6424
|
constructor() {
|
|
6409
6425
|
u(this, "title", "");
|
|
@@ -6800,7 +6816,7 @@ const ue = /* @__PURE__ */ j({
|
|
|
6800
6816
|
}, mg = /* @__PURE__ */ j({
|
|
6801
6817
|
inheritAttrs: !1,
|
|
6802
6818
|
__name: "PInput",
|
|
6803
|
-
props: /* @__PURE__ */
|
|
6819
|
+
props: /* @__PURE__ */ De({
|
|
6804
6820
|
label: { type: String, default: "", required: !1 },
|
|
6805
6821
|
margin: { type: String, required: !1, default: "" },
|
|
6806
6822
|
disabled: { type: Boolean, required: !1, default: !1 },
|
|
@@ -6829,9 +6845,9 @@ const ue = /* @__PURE__ */ j({
|
|
|
6829
6845
|
modelValue: {},
|
|
6830
6846
|
modelModifiers: {}
|
|
6831
6847
|
}),
|
|
6832
|
-
emits: /* @__PURE__ */
|
|
6848
|
+
emits: /* @__PURE__ */ De(["blur", "input", "focus", "clear"], ["update:modelValue"]),
|
|
6833
6849
|
setup(t, { expose: e, emit: n }) {
|
|
6834
|
-
const i = n, s =
|
|
6850
|
+
const i = n, s = vt(t, "modelValue"), o = an(), a = D(() => typeof o.id == "string" ? o.id : void 0), l = D(() => {
|
|
6835
6851
|
const $ = {};
|
|
6836
6852
|
for (const B of Object.keys(o))
|
|
6837
6853
|
B !== "id" && B !== "disable" && ($[B] = o[B]);
|
|
@@ -6990,7 +7006,7 @@ const ue = /* @__PURE__ */ j({
|
|
|
6990
7006
|
default: C(() => [
|
|
6991
7007
|
g(f(Ei), { dense: "" }, {
|
|
6992
7008
|
default: C(() => [
|
|
6993
|
-
|
|
7009
|
+
Je((m(), z(f(Bn), {
|
|
6994
7010
|
clickable: "",
|
|
6995
7011
|
onClick: s[0] || (s[0] = (a) => n("copy"))
|
|
6996
7012
|
}, {
|
|
@@ -7015,7 +7031,7 @@ const ue = /* @__PURE__ */ j({
|
|
|
7015
7031
|
})), [
|
|
7016
7032
|
[o]
|
|
7017
7033
|
]),
|
|
7018
|
-
|
|
7034
|
+
Je((m(), z(f(Bn), {
|
|
7019
7035
|
clickable: "",
|
|
7020
7036
|
onClick: s[1] || (s[1] = (a) => n("edit"))
|
|
7021
7037
|
}, {
|
|
@@ -7042,7 +7058,7 @@ const ue = /* @__PURE__ */ j({
|
|
|
7042
7058
|
]),
|
|
7043
7059
|
t.canRemove ? (m(), S(K, { key: 0 }, [
|
|
7044
7060
|
g(f(Zi)),
|
|
7045
|
-
|
|
7061
|
+
Je((m(), z(f(Bn), {
|
|
7046
7062
|
clickable: "",
|
|
7047
7063
|
onClick: s[2] || (s[2] = (a) => n("remove"))
|
|
7048
7064
|
}, {
|
|
@@ -7158,7 +7174,7 @@ const ue = /* @__PURE__ */ j({
|
|
|
7158
7174
|
}
|
|
7159
7175
|
}), vg = { class: "q-mb-md" }, yg = { class: "text-subtitle1 text-weight-medium text-grey-9" }, bg = { class: "text-caption text-grey-6 q-mt-xs" }, fo = /* @__PURE__ */ j({
|
|
7160
7176
|
__name: "PContactFormDeleteDialog",
|
|
7161
|
-
props: /* @__PURE__ */
|
|
7177
|
+
props: /* @__PURE__ */ De({
|
|
7162
7178
|
title: { type: String, default: "Удалить элемент?" },
|
|
7163
7179
|
subtitle: { type: String, default: "Это действие нельзя отменить." },
|
|
7164
7180
|
loading: { type: Boolean, default: !1 }
|
|
@@ -7166,9 +7182,9 @@ const ue = /* @__PURE__ */ j({
|
|
|
7166
7182
|
modelValue: { type: Boolean, default: !1 },
|
|
7167
7183
|
modelModifiers: {}
|
|
7168
7184
|
}),
|
|
7169
|
-
emits: /* @__PURE__ */
|
|
7185
|
+
emits: /* @__PURE__ */ De(["confirm"], ["update:modelValue"]),
|
|
7170
7186
|
setup(t) {
|
|
7171
|
-
const e = Wn, n =
|
|
7187
|
+
const e = Wn, n = vt(t, "modelValue");
|
|
7172
7188
|
return (i, s) => (m(), z(on, {
|
|
7173
7189
|
modelValue: n.value,
|
|
7174
7190
|
"onUpdate:modelValue": s[1] || (s[1] = (o) => n.value = o),
|
|
@@ -7193,7 +7209,7 @@ const ue = /* @__PURE__ */ j({
|
|
|
7193
7209
|
}),
|
|
7194
7210
|
g(f(ti), { class: "q-px-lg q-pb-lg justify-between" }, {
|
|
7195
7211
|
default: C(() => [
|
|
7196
|
-
|
|
7212
|
+
Je(g(ue, {
|
|
7197
7213
|
flat: "",
|
|
7198
7214
|
label: "Отмена",
|
|
7199
7215
|
color: "grey-7",
|
|
@@ -7221,7 +7237,7 @@ const ue = /* @__PURE__ */ j({
|
|
|
7221
7237
|
}
|
|
7222
7238
|
}), wg = { class: "q-mr-md" }, Sg = { class: "text-subtitle1 text-weight-medium text-grey-9" }, ho = /* @__PURE__ */ j({
|
|
7223
7239
|
__name: "PContactFormEditDialog",
|
|
7224
|
-
props: /* @__PURE__ */
|
|
7240
|
+
props: /* @__PURE__ */ De({
|
|
7225
7241
|
icon: { type: String, default: "edit" },
|
|
7226
7242
|
title: { type: String, default: "Редактирование" },
|
|
7227
7243
|
saving: { type: Boolean, default: !1 }
|
|
@@ -7229,9 +7245,9 @@ const ue = /* @__PURE__ */ j({
|
|
|
7229
7245
|
modelValue: { type: Boolean, default: !1 },
|
|
7230
7246
|
modelModifiers: {}
|
|
7231
7247
|
}),
|
|
7232
|
-
emits: /* @__PURE__ */
|
|
7248
|
+
emits: /* @__PURE__ */ De(["save"], ["update:modelValue"]),
|
|
7233
7249
|
setup(t) {
|
|
7234
|
-
const e = Wn, n =
|
|
7250
|
+
const e = Wn, n = vt(t, "modelValue");
|
|
7235
7251
|
return (i, s) => (m(), z(on, {
|
|
7236
7252
|
modelValue: n.value,
|
|
7237
7253
|
"onUpdate:modelValue": s[1] || (s[1] = (o) => n.value = o),
|
|
@@ -7255,7 +7271,7 @@ const ue = /* @__PURE__ */ j({
|
|
|
7255
7271
|
]),
|
|
7256
7272
|
y("div", Sg, U(t.title), 1),
|
|
7257
7273
|
g(f(_n)),
|
|
7258
|
-
|
|
7274
|
+
Je(g(ue, {
|
|
7259
7275
|
flat: "",
|
|
7260
7276
|
round: "",
|
|
7261
7277
|
dense: "",
|
|
@@ -7276,7 +7292,7 @@ const ue = /* @__PURE__ */ j({
|
|
|
7276
7292
|
}),
|
|
7277
7293
|
g(f(ti), { class: "q-px-lg q-pb-lg justify-between" }, {
|
|
7278
7294
|
default: C(() => [
|
|
7279
|
-
|
|
7295
|
+
Je(g(ue, {
|
|
7280
7296
|
flat: "",
|
|
7281
7297
|
label: "Отмена",
|
|
7282
7298
|
color: "grey-7",
|
|
@@ -7394,7 +7410,7 @@ const ue = /* @__PURE__ */ j({
|
|
|
7394
7410
|
}, {
|
|
7395
7411
|
default: C(() => [
|
|
7396
7412
|
(m(!0), S(K, null, we(f(s), (I, L) => {
|
|
7397
|
-
var Q, xe, ke,
|
|
7413
|
+
var Q, xe, ke, Ke, mt, Xe;
|
|
7398
7414
|
return m(), S("div", {
|
|
7399
7415
|
key: ((xe = (Q = t.adapter).emailId) == null ? void 0 : xe.call(Q, I)) ?? L,
|
|
7400
7416
|
class: ve(["row items-center justify-between q-pa-sm bg-grey-1 rounded-borders", $.$q.dark.isActive ? "" : "hover-item"]),
|
|
@@ -7403,7 +7419,7 @@ const ue = /* @__PURE__ */ j({
|
|
|
7403
7419
|
y("div", Pg, [
|
|
7404
7420
|
y("div", Rg, [
|
|
7405
7421
|
y("div", Ig, U(t.adapter.emailValue(I)), 1),
|
|
7406
|
-
(
|
|
7422
|
+
(Ke = (ke = t.adapter).emailDescription) != null && Ke.call(ke, I) ? (m(), S("div", Mg, U((Xe = (mt = t.adapter).emailDescription) == null ? void 0 : Xe.call(mt, I)), 1)) : G("", !0)
|
|
7407
7423
|
])
|
|
7408
7424
|
]),
|
|
7409
7425
|
g(ku, {
|
|
@@ -7594,7 +7610,7 @@ const ue = /* @__PURE__ */ j({
|
|
|
7594
7610
|
}, {
|
|
7595
7611
|
default: C(() => [
|
|
7596
7612
|
(m(!0), S(K, null, we(f(s), (L, Q) => {
|
|
7597
|
-
var xe, ke,
|
|
7613
|
+
var xe, ke, Ke, mt, Xe, rt;
|
|
7598
7614
|
return m(), S("div", {
|
|
7599
7615
|
key: ((ke = (xe = t.adapter).phoneId) == null ? void 0 : ke.call(xe, L)) ?? Q,
|
|
7600
7616
|
class: ve(["row items-center justify-between q-pa-sm bg-grey-1 rounded-borders", B.$q.dark.isActive ? "" : "hover-item"]),
|
|
@@ -7603,7 +7619,7 @@ const ue = /* @__PURE__ */ j({
|
|
|
7603
7619
|
y("div", _g, [
|
|
7604
7620
|
y("div", Ug, [
|
|
7605
7621
|
y("div", Bg, U(t.adapter.phoneNumber(L)), 1),
|
|
7606
|
-
(
|
|
7622
|
+
(mt = (Ke = t.adapter).phoneDescription) != null && mt.call(Ke, L) ? (m(), S("div", qg, U((rt = (Xe = t.adapter).phoneDescription) == null ? void 0 : rt.call(Xe, L)), 1)) : G("", !0)
|
|
7607
7623
|
])
|
|
7608
7624
|
]),
|
|
7609
7625
|
g(ku, {
|
|
@@ -7771,7 +7787,7 @@ const ue = /* @__PURE__ */ j({
|
|
|
7771
7787
|
]),
|
|
7772
7788
|
g(f(Rc), null, {
|
|
7773
7789
|
default: C(() => [
|
|
7774
|
-
|
|
7790
|
+
Je(y("div", null, [
|
|
7775
7791
|
g(f(Zi)),
|
|
7776
7792
|
g(f(kt), { class: "q-pt-xs q-pb-md q-px-md" }, {
|
|
7777
7793
|
default: C(() => [
|
|
@@ -7909,7 +7925,7 @@ const sv = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
7909
7925
|
}, Symbol.toStringTag, { value: "Module" })), ss = /* @__PURE__ */ j({
|
|
7910
7926
|
inheritAttrs: !1,
|
|
7911
7927
|
__name: "PCheckBox",
|
|
7912
|
-
props: /* @__PURE__ */
|
|
7928
|
+
props: /* @__PURE__ */ De({
|
|
7913
7929
|
label: { type: String, default: "" },
|
|
7914
7930
|
fontSize: { type: String, default: "" },
|
|
7915
7931
|
value: { type: [String, Boolean], default: void 0 },
|
|
@@ -7922,9 +7938,9 @@ const sv = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
7922
7938
|
modelValue: { type: Boolean },
|
|
7923
7939
|
modelModifiers: {}
|
|
7924
7940
|
}),
|
|
7925
|
-
emits: /* @__PURE__ */
|
|
7941
|
+
emits: /* @__PURE__ */ De(["change"], ["update:modelValue"]),
|
|
7926
7942
|
setup(t, { emit: e }) {
|
|
7927
|
-
const n =
|
|
7943
|
+
const n = vt(t, "modelValue"), i = e, s = an(), o = D(() => {
|
|
7928
7944
|
const l = {};
|
|
7929
7945
|
for (const r of Object.keys(s))
|
|
7930
7946
|
l[r] = s[r];
|
|
@@ -7975,14 +7991,19 @@ const Au = /* @__PURE__ */ j({
|
|
|
7975
7991
|
},
|
|
7976
7992
|
emits: ["load"],
|
|
7977
7993
|
setup(t, { emit: e }) {
|
|
7978
|
-
const n = t, i = e, s = Cn(), o = O(!1), a = (
|
|
7979
|
-
|
|
7994
|
+
const n = t, i = e, s = Cn(), o = O(!1), a = () => {
|
|
7995
|
+
const r = s.f.find((d) => d.model === n.model.model && d.col === n.model.col);
|
|
7996
|
+
o.value = r ? r.boolean : !1;
|
|
7980
7997
|
};
|
|
7981
|
-
|
|
7998
|
+
Ae(s.f, a, { immediate: !0, deep: !0 });
|
|
7999
|
+
const l = (r) => {
|
|
8000
|
+
o.value = !!r, n.model.setBoolean(!!r), r ? s.setF(n.model) : s.removeF(n.model), i("load");
|
|
8001
|
+
};
|
|
8002
|
+
return (r, d) => (m(), z(ss, at(r.$attrs, {
|
|
7982
8003
|
"model-value": f(o),
|
|
7983
8004
|
label: t.model.label,
|
|
7984
8005
|
size: "mini",
|
|
7985
|
-
"onUpdate:modelValue":
|
|
8006
|
+
"onUpdate:modelValue": l
|
|
7986
8007
|
}), null, 16, ["model-value", "label"]));
|
|
7987
8008
|
}
|
|
7988
8009
|
}), lv = { class: "p-filter-code-toggle row items-center no-wrap" }, uv = /* @__PURE__ */ j({
|
|
@@ -8078,14 +8099,14 @@ const Au = /* @__PURE__ */ j({
|
|
|
8078
8099
|
}, {
|
|
8079
8100
|
default: C(() => [
|
|
8080
8101
|
y("div", dv, [
|
|
8081
|
-
|
|
8102
|
+
Je(g(ue, {
|
|
8082
8103
|
label: "Закрыть",
|
|
8083
8104
|
color: "primary",
|
|
8084
8105
|
flat: ""
|
|
8085
8106
|
}, null, 512), [
|
|
8086
8107
|
[b]
|
|
8087
8108
|
]),
|
|
8088
|
-
|
|
8109
|
+
Je(g(ue, {
|
|
8089
8110
|
label: "Очистить",
|
|
8090
8111
|
color: "negative",
|
|
8091
8112
|
flat: "",
|
|
@@ -8131,7 +8152,7 @@ const Au = /* @__PURE__ */ j({
|
|
|
8131
8152
|
h && h !== i.model && (h.value1 = c);
|
|
8132
8153
|
}
|
|
8133
8154
|
}), d = () => {
|
|
8134
|
-
i.model.value1 = r.value,
|
|
8155
|
+
i.model.value1 = r.value, o.f.filter((c) => c.model === i.model.model && c.col === i.model.col).forEach((c) => o.removeF(c)), r.value && o.setF(i.model), s("input");
|
|
8135
8156
|
};
|
|
8136
8157
|
return e({ focus: () => {
|
|
8137
8158
|
var c, h;
|
|
@@ -8183,10 +8204,12 @@ const Au = /* @__PURE__ */ j({
|
|
|
8183
8204
|
}), l = () => {
|
|
8184
8205
|
const d = a.value.trim() !== "";
|
|
8185
8206
|
n.models.forEach((c) => {
|
|
8186
|
-
|
|
8207
|
+
s.f.filter((h) => h.model === c.model && h.col === c.col).forEach((h) => s.removeF(h)), d && s.setF(c);
|
|
8187
8208
|
}), i("input");
|
|
8188
8209
|
}, r = () => {
|
|
8189
|
-
a.value = "",
|
|
8210
|
+
a.value = "", s.f.filter((d) => n.models.some((c) => c.model === d.model && c.col === d.col)).forEach((d) => {
|
|
8211
|
+
d.value1 = "";
|
|
8212
|
+
}), l();
|
|
8190
8213
|
};
|
|
8191
8214
|
return (d, c) => (m(), z(Ne, {
|
|
8192
8215
|
modelValue: a.value,
|
|
@@ -8220,7 +8243,7 @@ const Au = /* @__PURE__ */ j({
|
|
|
8220
8243
|
}), sn = /* @__PURE__ */ j({
|
|
8221
8244
|
inheritAttrs: !1,
|
|
8222
8245
|
__name: "PSelect",
|
|
8223
|
-
props: /* @__PURE__ */
|
|
8246
|
+
props: /* @__PURE__ */ De({
|
|
8224
8247
|
label: { type: String, default: "", required: !1 },
|
|
8225
8248
|
placeholder: { type: String, default: "", required: !1 },
|
|
8226
8249
|
value: { type: String, default: "", required: !1 },
|
|
@@ -8260,9 +8283,9 @@ const Au = /* @__PURE__ */ j({
|
|
|
8260
8283
|
modelValue: {},
|
|
8261
8284
|
modelModifiers: {}
|
|
8262
8285
|
}),
|
|
8263
|
-
emits: /* @__PURE__ */
|
|
8286
|
+
emits: /* @__PURE__ */ De(["change", "clear"], ["update:modelValue"]),
|
|
8264
8287
|
setup(t, { expose: e, emit: n }) {
|
|
8265
|
-
const i =
|
|
8288
|
+
const i = vt(t, "modelValue"), s = n, o = O(null);
|
|
8266
8289
|
function a() {
|
|
8267
8290
|
var $;
|
|
8268
8291
|
($ = o.value) == null || $.focus();
|
|
@@ -8538,40 +8561,41 @@ const Au = /* @__PURE__ */ j({
|
|
|
8538
8561
|
}), mo = /* @__PURE__ */ j({
|
|
8539
8562
|
inheritAttrs: !1,
|
|
8540
8563
|
__name: "PToggle",
|
|
8541
|
-
props:
|
|
8564
|
+
props: {
|
|
8565
|
+
// ⚠️ `type: undefined` — намеренно: без него компилятор выводит `Boolean`
|
|
8566
|
+
// из TS-типа `boolean | undefined`, а Vue с типом `Boolean` приводит
|
|
8567
|
+
// отсутствующее значение к `false`.
|
|
8568
|
+
modelValue: { type: void 0, default: void 0 },
|
|
8542
8569
|
label: { type: String, default: "" },
|
|
8543
8570
|
fontSize: { type: String, default: "" },
|
|
8544
8571
|
size: { type: String, default: "md" },
|
|
8545
8572
|
padding: { type: String, default: "" },
|
|
8546
8573
|
margin: { type: String, default: "" },
|
|
8547
8574
|
width: { type: String, default: "" }
|
|
8548
|
-
},
|
|
8549
|
-
|
|
8550
|
-
modelModifiers: {}
|
|
8551
|
-
}),
|
|
8552
|
-
emits: /* @__PURE__ */ Ee(["change"], ["update:modelValue"]),
|
|
8575
|
+
},
|
|
8576
|
+
emits: ["update:modelValue", "change"],
|
|
8553
8577
|
setup(t, { emit: e }) {
|
|
8554
|
-
const n =
|
|
8578
|
+
const n = t, i = e, s = an(), o = D(() => {
|
|
8555
8579
|
const l = {};
|
|
8556
8580
|
for (const r of Object.keys(s))
|
|
8557
8581
|
l[r] = s[r];
|
|
8558
8582
|
return l;
|
|
8559
|
-
}), a = () => {
|
|
8560
|
-
|
|
8583
|
+
}), a = (l) => {
|
|
8584
|
+
const r = l ?? void 0;
|
|
8585
|
+
i("update:modelValue", r), i("change", r);
|
|
8561
8586
|
};
|
|
8562
8587
|
return (l, r) => (m(), S("div", {
|
|
8563
8588
|
class: "p-toggle",
|
|
8564
|
-
style: J({ padding:
|
|
8589
|
+
style: J({ padding: n.padding, margin: n.margin, maxWidth: n.width })
|
|
8565
8590
|
}, [
|
|
8566
8591
|
g(f(gl), at({
|
|
8567
|
-
|
|
8568
|
-
"onUpdate:modelValue": r[0] || (r[0] = (d) => n.value = d)
|
|
8592
|
+
"model-value": n.modelValue
|
|
8569
8593
|
}, f(o), {
|
|
8570
|
-
label:
|
|
8571
|
-
size:
|
|
8572
|
-
style: { fontSize:
|
|
8594
|
+
label: n.label || void 0,
|
|
8595
|
+
size: n.size,
|
|
8596
|
+
style: { fontSize: n.fontSize },
|
|
8573
8597
|
"onUpdate:modelValue": a
|
|
8574
|
-
}), null, 16, ["
|
|
8598
|
+
}), null, 16, ["model-value", "label", "size", "style"])
|
|
8575
8599
|
], 4));
|
|
8576
8600
|
}
|
|
8577
8601
|
}), Vu = /* @__PURE__ */ j({
|
|
@@ -8596,7 +8620,6 @@ const Au = /* @__PURE__ */ j({
|
|
|
8596
8620
|
"checked-icon": "check",
|
|
8597
8621
|
"unchecked-icon": "clear",
|
|
8598
8622
|
"keep-color": !0,
|
|
8599
|
-
"toggle-indeterminate": "",
|
|
8600
8623
|
label: t.model.label,
|
|
8601
8624
|
"onUpdate:modelValue": r
|
|
8602
8625
|
}), null, 16, ["model-value", "label"]));
|
|
@@ -8654,7 +8677,7 @@ const wv = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
8654
8677
|
default: Uu
|
|
8655
8678
|
}, Symbol.toStringTag, { value: "Module" })), Sv = { class: "row items-center justify-end" }, Kr = "DD.MM.YYYY", qa = /* @__PURE__ */ j({
|
|
8656
8679
|
__name: "PDateInput",
|
|
8657
|
-
props: /* @__PURE__ */
|
|
8680
|
+
props: /* @__PURE__ */ De({
|
|
8658
8681
|
label: { type: String, default: "", required: !1 },
|
|
8659
8682
|
placeholder: { type: String, default: "", required: !1 },
|
|
8660
8683
|
dense: { type: Boolean, default: !1 },
|
|
@@ -8675,9 +8698,9 @@ const wv = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
8675
8698
|
modelValue: { default: null },
|
|
8676
8699
|
modelModifiers: {}
|
|
8677
8700
|
}),
|
|
8678
|
-
emits: /* @__PURE__ */
|
|
8701
|
+
emits: /* @__PURE__ */ De(["blur", "input"], ["update:modelValue"]),
|
|
8679
8702
|
setup(t, { emit: e }) {
|
|
8680
|
-
const n = Wn, i = t, s = e, o =
|
|
8703
|
+
const n = Wn, i = t, s = e, o = vt(t, "modelValue"), a = Kr.replace(/[DMY]/g, "#"), l = O(null), r = (x) => {
|
|
8681
8704
|
if (i.modelType) {
|
|
8682
8705
|
l.value = i.modelType;
|
|
8683
8706
|
return;
|
|
@@ -8781,7 +8804,7 @@ const wv = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
8781
8804
|
}, {
|
|
8782
8805
|
default: C(() => [
|
|
8783
8806
|
y("div", Sv, [
|
|
8784
|
-
|
|
8807
|
+
Je(g(ue, {
|
|
8785
8808
|
label: "Готово",
|
|
8786
8809
|
color: "primary",
|
|
8787
8810
|
flat: ""
|
|
@@ -8887,7 +8910,7 @@ const wv = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
8887
8910
|
}), $v = /* @__PURE__ */ X(xv, [["__scopeId", "data-v-1f1f064c"]]), Tv = /* @__PURE__ */ j({
|
|
8888
8911
|
inheritAttrs: !1,
|
|
8889
8912
|
__name: "PInputNumber",
|
|
8890
|
-
props: /* @__PURE__ */
|
|
8913
|
+
props: /* @__PURE__ */ De({
|
|
8891
8914
|
label: { type: String, default: "", required: !1 },
|
|
8892
8915
|
margin: { type: String, required: !1, default: "" },
|
|
8893
8916
|
padding: { type: String, default: "", required: !1 },
|
|
@@ -8902,7 +8925,7 @@ const wv = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
8902
8925
|
modelValue: { default: 0 },
|
|
8903
8926
|
modelModifiers: {}
|
|
8904
8927
|
}),
|
|
8905
|
-
emits: /* @__PURE__ */
|
|
8928
|
+
emits: /* @__PURE__ */ De(["blur", "input", "change"], ["update:modelValue"]),
|
|
8906
8929
|
setup(t, { emit: e }) {
|
|
8907
8930
|
const n = e, i = an(), s = D(() => typeof i.id == "string" ? i.id : void 0), o = D(() => {
|
|
8908
8931
|
const $ = {};
|
|
@@ -8912,7 +8935,7 @@ const wv = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
8912
8935
|
}), a = t, l = () => {
|
|
8913
8936
|
const $ = a.step.toString();
|
|
8914
8937
|
return $.includes(".") ? $.split(".")[1].length : 0;
|
|
8915
|
-
}, r = l(), d =
|
|
8938
|
+
}, r = l(), d = vt(t, "modelValue"), h = (($) => Math.min(Math.max($, a.min), a.max))(d.value);
|
|
8916
8939
|
h !== d.value && (d.value = h);
|
|
8917
8940
|
const p = O(h.toFixed(l())), b = D(() => {
|
|
8918
8941
|
const $ = {};
|
|
@@ -8976,7 +8999,7 @@ const wv = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
8976
8999
|
}
|
|
8977
9000
|
}), Bu = /* @__PURE__ */ X(Tv, [["__scopeId", "data-v-d5544390"]]), qu = /* @__PURE__ */ j({
|
|
8978
9001
|
__name: "PRadio",
|
|
8979
|
-
props: /* @__PURE__ */
|
|
9002
|
+
props: /* @__PURE__ */ De({
|
|
8980
9003
|
label: { type: String, default: "" },
|
|
8981
9004
|
name: { type: String, default: "group" },
|
|
8982
9005
|
fontSize: { type: String, default: "" },
|
|
@@ -8990,9 +9013,9 @@ const wv = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
8990
9013
|
modelValue: {},
|
|
8991
9014
|
modelModifiers: {}
|
|
8992
9015
|
}),
|
|
8993
|
-
emits: /* @__PURE__ */
|
|
9016
|
+
emits: /* @__PURE__ */ De(["change"], ["update:modelValue"]),
|
|
8994
9017
|
setup(t, { emit: e }) {
|
|
8995
|
-
const n =
|
|
9018
|
+
const n = vt(t, "modelValue"), i = e, s = t, o = () => {
|
|
8996
9019
|
i("change", s.value);
|
|
8997
9020
|
};
|
|
8998
9021
|
return (a, l) => (m(), S("div", {
|
|
@@ -9016,7 +9039,7 @@ const wv = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
9016
9039
|
}), Pv = /* @__PURE__ */ j({
|
|
9017
9040
|
inheritAttrs: !1,
|
|
9018
9041
|
__name: "PTextarea",
|
|
9019
|
-
props: /* @__PURE__ */
|
|
9042
|
+
props: /* @__PURE__ */ De({
|
|
9020
9043
|
label: { type: String, default: "", required: !1 },
|
|
9021
9044
|
margin: { type: String, required: !1, default: "0" },
|
|
9022
9045
|
padding: { type: String, default: "0", required: !1 },
|
|
@@ -9030,9 +9053,9 @@ const wv = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
9030
9053
|
modelValue: {},
|
|
9031
9054
|
modelModifiers: {}
|
|
9032
9055
|
}),
|
|
9033
|
-
emits: /* @__PURE__ */
|
|
9056
|
+
emits: /* @__PURE__ */ De(["blur", "input", "focus"], ["update:modelValue"]),
|
|
9034
9057
|
setup(t) {
|
|
9035
|
-
const e =
|
|
9058
|
+
const e = vt(t, "modelValue"), n = an(), i = D(() => typeof n.id == "string" ? n.id : void 0), s = D(() => {
|
|
9036
9059
|
const r = {};
|
|
9037
9060
|
for (const d of Object.keys(n))
|
|
9038
9061
|
d !== "id" && (r[d] = n[d]);
|
|
@@ -9091,7 +9114,7 @@ class Mn {
|
|
|
9091
9114
|
}
|
|
9092
9115
|
const Rv = { class: "p-form-field" }, Iv = { key: 5 }, Mv = { key: 6 }, po = /* @__PURE__ */ j({
|
|
9093
9116
|
__name: "PFieldInput",
|
|
9094
|
-
props: /* @__PURE__ */
|
|
9117
|
+
props: /* @__PURE__ */ De({
|
|
9095
9118
|
field: {}
|
|
9096
9119
|
}, {
|
|
9097
9120
|
fill: { required: !0 },
|
|
@@ -9099,7 +9122,7 @@ const Rv = { class: "p-form-field" }, Iv = { key: 5 }, Mv = { key: 6 }, po = /*
|
|
|
9099
9122
|
}),
|
|
9100
9123
|
emits: ["update:fill"],
|
|
9101
9124
|
setup(t) {
|
|
9102
|
-
const e = t, n =
|
|
9125
|
+
const e = t, n = vt(t, "fill"), i = D(() => {
|
|
9103
9126
|
var b;
|
|
9104
9127
|
return String(((b = e.field.valueType) == null ? void 0 : b.name) || "string");
|
|
9105
9128
|
}), s = D(() => i.value === "string"), o = D(() => i.value === "text"), a = D(() => i.value === "number"), l = D(() => i.value === "date" || i.value === "dateTime"), r = D(() => i.value === "boolean"), d = D(() => i.value === "radio"), c = D(() => i.value === "set"), h = (b) => {
|
|
@@ -9165,7 +9188,7 @@ function el(t, e) {
|
|
|
9165
9188
|
}
|
|
9166
9189
|
return n;
|
|
9167
9190
|
}
|
|
9168
|
-
function
|
|
9191
|
+
function Le(t) {
|
|
9169
9192
|
for (var e = 1; e < arguments.length; e++) {
|
|
9170
9193
|
var n = arguments[e] != null ? arguments[e] : {};
|
|
9171
9194
|
e % 2 ? el(Object(n), !0).forEach(function(i) {
|
|
@@ -9312,7 +9335,7 @@ function nl(t) {
|
|
|
9312
9335
|
function mi(t) {
|
|
9313
9336
|
return !!(t && t.constructor && t.call && t.apply);
|
|
9314
9337
|
}
|
|
9315
|
-
function
|
|
9338
|
+
function gt(t) {
|
|
9316
9339
|
return t === void 0;
|
|
9317
9340
|
}
|
|
9318
9341
|
function _s(t) {
|
|
@@ -9321,7 +9344,7 @@ function _s(t) {
|
|
|
9321
9344
|
function wa(t, e, n) {
|
|
9322
9345
|
var i = {};
|
|
9323
9346
|
return _s(t) ? (Object.keys(e).forEach(function(s) {
|
|
9324
|
-
|
|
9347
|
+
gt(t[s]) ? i[s] = e[s] : _s(e[s]) ? _s(t[s]) ? i[s] = wa(t[s], e[s], n[s]) : i[s] = t[s] ? e[s] : n[s] : e[s] === !0 || e[s] === !1 ? i[s] = !!t[s] : i[s] = t[s];
|
|
9325
9348
|
}), i) : t ? e : n;
|
|
9326
9349
|
}
|
|
9327
9350
|
function Is(t) {
|
|
@@ -9492,7 +9515,7 @@ function Jt(t, e, n, i) {
|
|
|
9492
9515
|
}
|
|
9493
9516
|
return t;
|
|
9494
9517
|
}
|
|
9495
|
-
function
|
|
9518
|
+
function _e(t) {
|
|
9496
9519
|
return t.width / t.height;
|
|
9497
9520
|
}
|
|
9498
9521
|
function Ii(t, e) {
|
|
@@ -9507,7 +9530,7 @@ function Xo(t, e) {
|
|
|
9507
9530
|
return e.minimum && t < e.minimum ? n = e.minimum : e.maximum && t > e.maximum && (n = e.maximum), n;
|
|
9508
9531
|
}
|
|
9509
9532
|
function Xu(t, e) {
|
|
9510
|
-
var n =
|
|
9533
|
+
var n = _e(t), i = _e(e);
|
|
9511
9534
|
return e.width < 1 / 0 && e.height < 1 / 0 ? n > i ? { width: e.width, height: e.width / n } : { width: e.height * n, height: e.height } : e.width < 1 / 0 ? { width: e.width, height: e.width / n } : e.height < 1 / 0 ? { width: e.height * n, height: e.height } : t;
|
|
9512
9535
|
}
|
|
9513
9536
|
function Zu(t, e) {
|
|
@@ -9546,7 +9569,7 @@ function yo(t, e) {
|
|
|
9546
9569
|
}
|
|
9547
9570
|
function al(t) {
|
|
9548
9571
|
var e = t.size, n = t.aspectRatio, i = t.ignoreMinimum, s = t.sizeRestrictions;
|
|
9549
|
-
return !!((e.correctRatio ||
|
|
9572
|
+
return !!((e.correctRatio || _e(e) >= n.minimum && _e(e) <= n.maximum) && e.height <= s.maxHeight && e.width <= s.maxWidth && e.width && e.height && (i || e.height >= s.minHeight && e.width >= s.minWidth));
|
|
9550
9573
|
}
|
|
9551
9574
|
function rl(t, e) {
|
|
9552
9575
|
return Math.pow(t.width - e.width, 2) + Math.pow(t.height - e.height, 2);
|
|
@@ -9575,10 +9598,10 @@ function Bv(t) {
|
|
|
9575
9598
|
}, d = ge({}, e);
|
|
9576
9599
|
return (Array.isArray(n) ? n : [n]).forEach(function(c) {
|
|
9577
9600
|
var h = {};
|
|
9578
|
-
|
|
9601
|
+
gt((h = typeof c == "function" ? c({ coordinates: d, imageSize: i, visibleArea: l }) : c).width) && gt(h.height) || (d = function(p, b) {
|
|
9579
9602
|
var k = ge(ge(ge({}, p), Pn({ width: b.width, height: b.height, sizeRestrictions: s, aspectRatio: a })), { left: 0, top: 0 });
|
|
9580
9603
|
return r(k, { left: p.left, top: p.top });
|
|
9581
|
-
}(d, ge(ge({}, d), h))),
|
|
9604
|
+
}(d, ge(ge({}, d), h))), gt(h.left) && gt(h.top) || (d = r(d, ge(ge({}, d), h)));
|
|
9582
9605
|
}), d;
|
|
9583
9606
|
}
|
|
9584
9607
|
function qv(t) {
|
|
@@ -9588,7 +9611,7 @@ function qv(t) {
|
|
|
9588
9611
|
var o = t.stencilSize, a = t.sizeRestrictions, l = t.positionRestrictions;
|
|
9589
9612
|
t.stencilReference;
|
|
9590
9613
|
var r, d, c, h = ge({}, i), p = ge({}, s), b = ge({}, o);
|
|
9591
|
-
r =
|
|
9614
|
+
r = _e(b), d = _e(h), c === void 0 && (c = 1e-3), (r === 0 || d === 0 ? Math.abs(d - r) < c : Math.abs(d / r) < 1 + c && Math.abs(d / r) > 1 - c) || (h = ge(ge({}, h), Pn({ sizeRestrictions: a, width: h.width, height: h.height, aspectRatio: { minimum: _e(b), maximum: _e(b) } })));
|
|
9592
9615
|
var k = vo(p = Jt(p, h.width * n.width / (p.width * b.width)), e({ visibleArea: p, type: "resize" }));
|
|
9593
9616
|
return k !== 1 && (p = Jt(p, k), h = Jt(h, k)), p = Pt(p = qt(p, Ri(Tt(h), Tt(p))), e({ visibleArea: p, type: "move" })), { coordinates: h = Pt(h, yo(bn(p), l)), visibleArea: p };
|
|
9594
9617
|
}
|
|
@@ -9600,7 +9623,7 @@ function Nv(t) {
|
|
|
9600
9623
|
var l = ge({}, s), r = ge({}, o);
|
|
9601
9624
|
if (s && o && e.type !== "manipulateImage") {
|
|
9602
9625
|
var d = { width: 0, height: 0 };
|
|
9603
|
-
r.width, i.width,
|
|
9626
|
+
r.width, i.width, _e(i) > _e(l) ? (d.height = 0.8 * i.height, d.width = d.height * _e(l)) : (d.width = 0.8 * i.width, d.height = d.width * _e(l));
|
|
9604
9627
|
var c = vo(r = Jt(r, l.width * i.width / (r.width * d.width)), n({ visibleArea: r, type: "resize" }));
|
|
9605
9628
|
r = Jt(r, c), c !== 1 && (d.height /= c, d.width /= c), r = Pt(r = qt(r, Ri(Tt(l), Tt(r))), n({ visibleArea: r, type: "move" })), l = Pt(l, yo(bn(r), a));
|
|
9606
9629
|
}
|
|
@@ -9619,20 +9642,20 @@ function jv(t) {
|
|
|
9619
9642
|
return { left: (n ? n.left : 0) + s.width / 2 - i.width / 2, top: (n ? n.top : 0) + s.height / 2 - i.height / 2 };
|
|
9620
9643
|
}
|
|
9621
9644
|
function Gv(t) {
|
|
9622
|
-
var e = t.imageSize, n = t.visibleArea, i = t.aspectRatio, s = t.sizeRestrictions, o = n || e, a = Math.min(i.maximum || 1 / 0, Math.max(i.minimum || 0,
|
|
9645
|
+
var e = t.imageSize, n = t.visibleArea, i = t.aspectRatio, s = t.sizeRestrictions, o = n || e, a = Math.min(i.maximum || 1 / 0, Math.max(i.minimum || 0, _e(o))), l = o.width < o.height ? { width: 0.8 * o.width, height: 0.8 * o.width / a } : { height: 0.8 * o.height, width: 0.8 * o.height * a };
|
|
9623
9646
|
return Pn(ge(ge({}, l), { aspectRatio: i, sizeRestrictions: s }));
|
|
9624
9647
|
}
|
|
9625
9648
|
function Wv(t) {
|
|
9626
9649
|
var e, n, i = t.imageSize, s = t.visibleArea, o = t.boundaries, a = t.aspectRatio, l = t.sizeRestrictions, r = t.stencilSize, d = s || i;
|
|
9627
|
-
return
|
|
9650
|
+
return _e(d) > _e(o) ? n = (e = r.height * d.height / o.height) * _e(r) : e = (n = r.width * d.width / o.width) / _e(r), Pn({ width: n, height: e, aspectRatio: a, sizeRestrictions: l });
|
|
9628
9651
|
}
|
|
9629
9652
|
function Yv(t) {
|
|
9630
|
-
var e = t.getAreaRestrictions, n = t.coordinates, i = t.imageSize, s =
|
|
9653
|
+
var e = t.getAreaRestrictions, n = t.coordinates, i = t.imageSize, s = _e(t.boundaries);
|
|
9631
9654
|
if (n) {
|
|
9632
|
-
var o = { height: Math.max(n.height, i.height), width: Math.max(n.width, i.width) }, a = Xu({ width:
|
|
9655
|
+
var o = { height: Math.max(n.height, i.height), width: Math.max(n.width, i.width) }, a = Xu({ width: _e(o) > s ? o.width : o.height * s, height: _e(o) > s ? o.width / s : o.height }, Sa(e())), l = { left: n.left + n.width / 2 - a.width / 2, top: n.top + n.height / 2 - a.height / 2, width: a.width, height: a.height }, r = os(n, bn(ge({ left: 0, top: 0 }, i))), d = {};
|
|
9633
9656
|
return !r.left && !r.right && l.width <= i.width && (d.left = 0, d.right = i.width), !r.top && !r.bottom && l.height <= i.height && (d.top = 0, d.bottom = i.height), Pt(l, d);
|
|
9634
9657
|
}
|
|
9635
|
-
var c =
|
|
9658
|
+
var c = _e(i);
|
|
9636
9659
|
return a = { height: c > s ? i.height : i.width / s, width: c > s ? i.height * s : i.width }, { left: i.width / 2 - a.width / 2, top: i.height / 2 - a.height / 2, width: a.width, height: a.height };
|
|
9637
9660
|
}
|
|
9638
9661
|
function Ms(t, e) {
|
|
@@ -10024,7 +10047,7 @@ var Es = ln("vue-preview"), id = { props: { coordinates: { type: Object }, trans
|
|
|
10024
10047
|
return this.transitions && this.transitions.enabled && (t.transition = "".concat(this.transitions.time, "ms ").concat(this.transitions.timingFunction)), t;
|
|
10025
10048
|
}, imageStyle: function() {
|
|
10026
10049
|
if (this.coordinates && this.image) {
|
|
10027
|
-
var t = this.coordinates.width / this.size.width, e =
|
|
10050
|
+
var t = this.coordinates.width / this.size.width, e = Le(Le({ rotate: 0, flip: { horizontal: !1, vertical: !1 } }, this.image.transforms), {}, { scaleX: 1 / t, scaleY: 1 / t }), n = this.imageSize.width, i = this.imageSize.height, s = Zu({ width: n, height: i }, e.rotate), o = { width: "".concat(n, "px"), height: "".concat(i, "px"), left: "0px", top: "0px" }, a = { rotate: { left: (n - s.width) * e.scaleX / 2, top: (i - s.height) * e.scaleY / 2 }, scale: { left: (1 - e.scaleX) * n / 2, top: (1 - e.scaleY) * i / 2 } };
|
|
10028
10051
|
return o.transform = `translate(
|
|
10029
10052
|
`.concat(-this.coordinates.left / t - a.rotate.left - a.scale.left, "px,").concat(-this.coordinates.top / t - a.rotate.top - a.scale.top, "px) ") + td(e), this.transitions && this.transitions.enabled && (o.transition = "".concat(this.transitions.time, "ms ").concat(this.transitions.timingFunction)), o;
|
|
10030
10053
|
}
|
|
@@ -10053,7 +10076,7 @@ var Es = ln("vue-preview"), id = { props: { coordinates: { type: Object }, trans
|
|
|
10053
10076
|
t && t.complete && this.refreshImage(), this.refresh();
|
|
10054
10077
|
} } };
|
|
10055
10078
|
id.render = function(t, e, n, i, s, o) {
|
|
10056
|
-
return m(), z("div", { ref: "root", class: o.classes.root, style: o.style }, [g("div", { ref: "wrapper", class: o.classes.wrapper, style: o.wrapperStyle }, [
|
|
10079
|
+
return m(), z("div", { ref: "root", class: o.classes.root, style: o.style }, [g("div", { ref: "wrapper", class: o.classes.wrapper, style: o.wrapperStyle }, [Je(g("img", { ref: "image", src: n.image && n.image.src, class: o.classes.image, style: o.imageStyle }, null, 14, ["src"]), [[eo, n.image && n.image.src]])], 6)], 6);
|
|
10057
10080
|
};
|
|
10058
10081
|
var sd = { components: { Preview: id }, inheritAttrs: !1 };
|
|
10059
10082
|
sd.render = function(t, e, n, i, s, o) {
|
|
@@ -10113,7 +10136,7 @@ var r1 = ["transitions"], xn = ln("vue-advanced-cropper"), ad = { name: "Cropper
|
|
|
10113
10136
|
o.widthFrozen && (r.left = 0, r.right = 0), o.heightFrozen && (r.top = 0, r.bottom = 0), gn.forEach(function(V) {
|
|
10114
10137
|
d[V] || (r[V] = 0);
|
|
10115
10138
|
});
|
|
10116
|
-
var c = pn(a, r = ll({ coordinates: a, directions: r, sizeRestrictions: o, positionRestrictions: s })).width, h = pn(a, r).height, p = l.preserveRatio ?
|
|
10139
|
+
var c = pn(a, r = ll({ coordinates: a, directions: r, sizeRestrictions: o, positionRestrictions: s })).width, h = pn(a, r).height, p = l.preserveRatio ? _e(a) : Xo(c / h, i);
|
|
10117
10140
|
if (p) {
|
|
10118
10141
|
var b = l.respectDirection;
|
|
10119
10142
|
if (b || (b = a.width >= a.height || p === 1 ? "width" : "height"), b === "width") {
|
|
@@ -10131,30 +10154,30 @@ var r1 = ["transitions"], xn = ln("vue-advanced-cropper"), ad = { name: "Cropper
|
|
|
10131
10154
|
}
|
|
10132
10155
|
r = ll({ directions: r, coordinates: a, sizeRestrictions: o, positionRestrictions: s, preserveRatio: !0, compensate: l.compensate });
|
|
10133
10156
|
}
|
|
10134
|
-
return c = pn(a, r).width, h = pn(a, r).height, (p = l.preserveRatio ?
|
|
10157
|
+
return c = pn(a, r).width, h = pn(a, r).height, (p = l.preserveRatio ? _e(a) : Xo(c / h, i)) && Math.abs(p - c / h) > 1e-3 && gn.forEach(function(V) {
|
|
10135
10158
|
d[V] || (r[V] = 0);
|
|
10136
10159
|
}), Ca({ event: new Na({ left: -r.left, top: -r.top }), coordinates: { width: n.width + r.right + r.left, height: n.height + r.top + r.bottom, left: n.left, top: n.top }, positionRestrictions: s });
|
|
10137
10160
|
} }, moveAlgorithm: { type: Function, default: Ca }, initStretcher: { type: Function, default: function(t) {
|
|
10138
|
-
var e = t.stretcher, n = t.imageSize, i =
|
|
10161
|
+
var e = t.stretcher, n = t.imageSize, i = _e(n);
|
|
10139
10162
|
e.style.width = n.width + "px", e.style.height = e.clientWidth / i + "px", e.style.width = e.clientWidth + "px";
|
|
10140
10163
|
} }, fitCoordinates: { type: Function, default: function(t) {
|
|
10141
10164
|
var e = t.visibleArea, n = t.coordinates, i = t.aspectRatio, s = t.sizeRestrictions, o = t.positionRestrictions, a = ge(ge({}, n), Pn({ width: n.width, height: n.height, aspectRatio: i, sizeRestrictions: { maxWidth: e.width, maxHeight: e.height, minHeight: Math.min(e.height, s.minHeight), minWidth: Math.min(e.width, s.minWidth) } }));
|
|
10142
10165
|
return a = Pt(a = qt(a, Ri(Tt(n), Tt(a))), yo(bn(e), o));
|
|
10143
10166
|
} }, fitVisibleArea: { type: Function, default: function(t) {
|
|
10144
10167
|
var e = t.visibleArea, n = t.boundaries, i = t.getAreaRestrictions, s = t.coordinates, o = ge({}, e);
|
|
10145
|
-
o.height = o.width /
|
|
10168
|
+
o.height = o.width / _e(n), o.top += (e.height - o.height) / 2, (s.height - o.height > 0 || s.width - o.width > 0) && (o = Jt(o, Math.max(s.height / o.height, s.width / o.width)));
|
|
10146
10169
|
var a = go(Mi(s, bn(o = Jt(o, vo(o, i({ visibleArea: o, type: "resize" }))))));
|
|
10147
10170
|
return o.width < s.width && (a.left = 0), o.height < s.height && (a.top = 0), o = Pt(o = qt(o, a), i({ visibleArea: o, type: "move" }));
|
|
10148
10171
|
} }, areaRestrictionsAlgorithm: { type: Function, default: function(t) {
|
|
10149
10172
|
var e = t.visibleArea, n = t.boundaries, i = t.imageSize, s = t.imageRestriction, o = t.type, a = {};
|
|
10150
|
-
return s === "fill-area" ? a = { left: 0, top: 0, right: i.width, bottom: i.height } : s === "fit-area" && (
|
|
10173
|
+
return s === "fill-area" ? a = { left: 0, top: 0, right: i.width, bottom: i.height } : s === "fit-area" && (_e(n) > _e(i) ? (a = { top: 0, bottom: i.height }, e && o === "move" && (e.width > i.width ? (a.left = -(e.width - i.width) / 2, a.right = i.width - a.left) : (a.left = 0, a.right = i.width))) : (a = { left: 0, right: i.width }, e && o === "move" && (e.height > i.height ? (a.top = -(e.height - i.height) / 2, a.bottom = i.height - a.top) : (a.top = 0, a.bottom = i.height)))), a;
|
|
10151
10174
|
} }, sizeRestrictionsAlgorithm: { type: Function, default: function(t) {
|
|
10152
10175
|
return { minWidth: t.minWidth, minHeight: t.minHeight, maxWidth: t.maxWidth, maxHeight: t.maxHeight };
|
|
10153
10176
|
} }, positionRestrictionsAlgorithm: { type: Function, default: function(t) {
|
|
10154
10177
|
var e = t.imageSize, n = {};
|
|
10155
10178
|
return t.imageRestriction !== "none" && (n = { left: 0, top: 0, right: e.width, bottom: e.height }), n;
|
|
10156
10179
|
} } }, data: function() {
|
|
10157
|
-
return { transitionsActive: !1, imageLoaded: !1, imageAttributes: { width: null, height: null, crossOrigin: null, src: null }, defaultImageTransforms: { rotate: 0, flip: { horizontal: !1, vertical: !1 } }, appliedImageTransforms: { rotate: 0, flip: { horizontal: !1, vertical: !1 } }, boundaries: { width: 0, height: 0 }, visibleArea: null, coordinates:
|
|
10180
|
+
return { transitionsActive: !1, imageLoaded: !1, imageAttributes: { width: null, height: null, crossOrigin: null, src: null }, defaultImageTransforms: { rotate: 0, flip: { horizontal: !1, vertical: !1 } }, appliedImageTransforms: { rotate: 0, flip: { horizontal: !1, vertical: !1 } }, boundaries: { width: 0, height: 0 }, visibleArea: null, coordinates: Le({}, sl) };
|
|
10158
10181
|
}, computed: { image: function() {
|
|
10159
10182
|
return { src: this.imageAttributes.src, width: this.imageAttributes.width, height: this.imageAttributes.height, transforms: this.imageTransforms };
|
|
10160
10183
|
}, imageTransforms: function() {
|
|
@@ -10177,7 +10200,7 @@ var r1 = ["transitions"], xn = ln("vue-advanced-cropper"), ad = { name: "Cropper
|
|
|
10177
10200
|
return { enabled: this.transitionsActive, timingFunction: "ease-in-out", time: 350 };
|
|
10178
10201
|
}, sizeRestrictions: function() {
|
|
10179
10202
|
if (this.boundaries.width && this.boundaries.height && this.imageSize.width && this.imageSize.height) {
|
|
10180
|
-
var t = this.sizeRestrictionsAlgorithm({ imageSize: this.imageSize, minWidth:
|
|
10203
|
+
var t = this.sizeRestrictionsAlgorithm({ imageSize: this.imageSize, minWidth: gt(this.minWidth) ? 0 : Is(this.minWidth), minHeight: gt(this.minHeight) ? 0 : Is(this.minHeight), maxWidth: gt(this.maxWidth) ? 1 / 0 : Is(this.maxWidth), maxHeight: gt(this.maxHeight) ? 1 / 0 : Is(this.maxHeight) });
|
|
10181
10204
|
if (t = function(i) {
|
|
10182
10205
|
var s = i.areaRestrictions, o = i.sizeRestrictions, a = i.boundaries, l = i.positionRestrictions, r = ge(ge({}, o), { minWidth: o.minWidth !== void 0 ? o.minWidth : 0, minHeight: o.minHeight !== void 0 ? o.minHeight : 0, maxWidth: o.maxWidth !== void 0 ? o.maxWidth : 1 / 0, maxHeight: o.maxHeight !== void 0 ? o.maxHeight : 1 / 0 });
|
|
10183
10206
|
l.left !== void 0 && l.right !== void 0 && (r.maxWidth = Math.min(r.maxWidth, l.right - l.left)), l.bottom !== void 0 && l.top !== void 0 && (r.maxHeight = Math.min(r.maxHeight, l.bottom - l.top));
|
|
@@ -10204,7 +10227,7 @@ var r1 = ["transitions"], xn = ln("vue-advanced-cropper"), ad = { name: "Cropper
|
|
|
10204
10227
|
var t = { width: this.boundaries.width ? "".concat(Math.round(this.boundaries.width), "px") : "auto", height: this.boundaries.height ? "".concat(Math.round(this.boundaries.height), "px") : "auto", transition: "opacity ".concat(this.transitionTime, "ms"), pointerEvents: this.imageLoaded ? "all" : "none" };
|
|
10205
10228
|
return this.imageLoaded || (t.opacity = "0"), t;
|
|
10206
10229
|
}, imageStyle: function() {
|
|
10207
|
-
var t = this.imageAttributes.width > this.imageAttributes.height ? { width: Math.min(1024, this.imageAttributes.width), height: Math.min(1024, this.imageAttributes.width) / (this.imageAttributes.width / this.imageAttributes.height) } : { height: Math.min(1024, this.imageAttributes.height), width: Math.min(1024, this.imageAttributes.height) * (this.imageAttributes.width / this.imageAttributes.height) }, e = { left: (t.width - this.imageSize.width) / (2 * this.coefficient), top: (t.height - this.imageSize.height) / (2 * this.coefficient) }, n = { left: (1 - 1 / this.coefficient) * t.width / 2, top: (1 - 1 / this.coefficient) * t.height / 2 }, i =
|
|
10230
|
+
var t = this.imageAttributes.width > this.imageAttributes.height ? { width: Math.min(1024, this.imageAttributes.width), height: Math.min(1024, this.imageAttributes.width) / (this.imageAttributes.width / this.imageAttributes.height) } : { height: Math.min(1024, this.imageAttributes.height), width: Math.min(1024, this.imageAttributes.height) * (this.imageAttributes.width / this.imageAttributes.height) }, e = { left: (t.width - this.imageSize.width) / (2 * this.coefficient), top: (t.height - this.imageSize.height) / (2 * this.coefficient) }, n = { left: (1 - 1 / this.coefficient) * t.width / 2, top: (1 - 1 / this.coefficient) * t.height / 2 }, i = Le(Le({}, this.imageTransforms), {}, { scaleX: this.imageTransforms.scaleX * (this.imageAttributes.width / t.width), scaleY: this.imageTransforms.scaleY * (this.imageAttributes.height / t.height) }), s = { width: "".concat(t.width, "px"), height: "".concat(t.height, "px"), left: "0px", top: "0px", transform: "translate(".concat(-e.left - n.left - this.imageTransforms.translateX, "px, ").concat(-e.top - n.top - this.imageTransforms.translateY, "px)") + td(i) };
|
|
10208
10231
|
return this.transitionsOptions.enabled && (s.transition = "".concat(this.transitionsOptions.time, "ms ").concat(this.transitionsOptions.timingFunction)), s;
|
|
10209
10232
|
} }, watch: { src: function() {
|
|
10210
10233
|
this.onChangeImage();
|
|
@@ -10234,14 +10257,14 @@ var r1 = ["transitions"], xn = ln("vue-advanced-cropper"), ad = { name: "Cropper
|
|
|
10234
10257
|
}, unmounted: function() {
|
|
10235
10258
|
window.removeEventListener("resize", this.refresh), window.removeEventListener("orientationchange", this.refresh), this.imageAttributes.revoke && this.imageAttributes.src && URL.revokeObjectURL(this.imageAttributes.src), this.debouncedUpdate.clear(), this.debouncedDisableTransitions.clear();
|
|
10236
10259
|
}, methods: { getResult: function() {
|
|
10237
|
-
var t = this.initialized ? this.prepareResult(
|
|
10260
|
+
var t = this.initialized ? this.prepareResult(Le({}, this.coordinates)) : this.defaultCoordinates(), e = { rotate: this.imageTransforms.rotate % 360, flip: Le({}, this.imageTransforms.flip) };
|
|
10238
10261
|
if (this.src && this.imageLoaded) {
|
|
10239
10262
|
var n = this;
|
|
10240
|
-
return { image: this.image, coordinates: t, visibleArea: this.visibleArea ?
|
|
10263
|
+
return { image: this.image, coordinates: t, visibleArea: this.visibleArea ? Le({}, this.visibleArea) : null, imageTransforms: e, get canvas() {
|
|
10241
10264
|
return n.canvas ? n.getCanvas() : void 0;
|
|
10242
10265
|
} };
|
|
10243
10266
|
}
|
|
10244
|
-
return { image: this.image, coordinates: t, visibleArea: this.visibleArea ?
|
|
10267
|
+
return { image: this.image, coordinates: t, visibleArea: this.visibleArea ? Le({}, this.visibleArea) : null, canvas: void 0, imageTransforms: e };
|
|
10245
10268
|
}, zoom: function(t, e) {
|
|
10246
10269
|
var n = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : {}, i = n.transitions, s = i === void 0 || i;
|
|
10247
10270
|
this.onManipulateImage(new Qi({}, { factor: 1 / t, center: e }), { normalize: !1, transitions: s });
|
|
@@ -10274,12 +10297,12 @@ var r1 = ["transitions"], xn = ln("vue-advanced-cropper"), ad = { name: "Cropper
|
|
|
10274
10297
|
return this.roundResult ? function(e) {
|
|
10275
10298
|
var n = e.coordinates, i = e.sizeRestrictions, s = e.positionRestrictions, o = { width: Math.round(n.width), height: Math.round(n.height), left: Math.round(n.left), top: Math.round(n.top) };
|
|
10276
10299
|
return o.width > i.maxWidth ? o.width = Math.floor(n.width) : o.width < i.minWidth && (o.width = Math.ceil(n.width)), o.height > i.maxHeight ? o.height = Math.floor(n.height) : o.height < i.minHeight && (o.height = Math.ceil(n.height)), Pt(o, s);
|
|
10277
|
-
}(
|
|
10300
|
+
}(Le(Le({}, this.getPublicProperties()), {}, { positionRestrictions: Ms(this.positionRestrictions, this.visibleArea), coordinates: t })) : t;
|
|
10278
10301
|
}, processAutoZoom: function(t, e, n, i) {
|
|
10279
10302
|
var s = this.autoZoomAlgorithm;
|
|
10280
10303
|
s || (s = this.stencilSize ? qv : this.autoZoom ? Nv : Hv);
|
|
10281
10304
|
var o = s({ event: { type: t, params: i }, visibleArea: e, coordinates: n, boundaries: this.boundaries, aspectRatio: this.getAspectRatio(), positionRestrictions: this.positionRestrictions, getAreaRestrictions: this.getAreaRestrictions, sizeRestrictions: this.sizeRestrictions, stencilSize: this.getStencilSize() });
|
|
10282
|
-
return
|
|
10305
|
+
return Le(Le({}, o), {}, { changed: !ol(o.visibleArea, e) || !ol(o.coordinates, n) });
|
|
10283
10306
|
}, runAutoZoom: function(t) {
|
|
10284
10307
|
var e = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, n = e.transitions, i = n !== void 0 && n, s = Av(e, r1), o = this.processAutoZoom(t, this.visibleArea, this.coordinates, s), a = o.visibleArea, l = o.coordinates, r = o.changed;
|
|
10285
10308
|
i && r && this.enableTransitions(), this.visibleArea = a, this.coordinates = l, i && r && this.debouncedDisableTransitions();
|
|
@@ -10300,7 +10323,7 @@ var r1 = ["transitions"], xn = ln("vue-advanced-cropper"), ad = { name: "Cropper
|
|
|
10300
10323
|
}), a;
|
|
10301
10324
|
}
|
|
10302
10325
|
return n;
|
|
10303
|
-
}(
|
|
10326
|
+
}(Le(Le({}, this.getPublicProperties()), {}, { event: t }));
|
|
10304
10327
|
}, getCanvas: function() {
|
|
10305
10328
|
if (this.$refs.canvas) {
|
|
10306
10329
|
var t = this.$refs.canvas, e = this.$refs.image, n = this.imageTransforms.rotate !== 0 || this.imageTransforms.flip.horizontal || this.imageTransforms.flip.vertical ? function(l, r, d) {
|
|
@@ -10308,7 +10331,7 @@ var r1 = ["transitions"], xn = ln("vue-advanced-cropper"), ad = { name: "Cropper
|
|
|
10308
10331
|
l.height = b.height, l.width = b.width, k.save();
|
|
10309
10332
|
var P = Vn(Tt(ge({ left: 0, top: 0 }, p)), c);
|
|
10310
10333
|
return k.translate(-(P.left - b.width / 2), -(P.top - b.height / 2)), k.rotate(c * Math.PI / 180), k.translate(h.horizontal ? p.width : 0, h.vertical ? p.height : 0), k.scale(h.horizontal ? -1 : 1, h.vertical ? -1 : 1), k.drawImage(r, 0, 0, p.width, p.height), k.restore(), l;
|
|
10311
|
-
}(this.$refs.sourceCanvas, e, this.imageTransforms) : e, i =
|
|
10334
|
+
}(this.$refs.sourceCanvas, e, this.imageTransforms) : e, i = Le({ minWidth: 0, minHeight: 0, maxWidth: 1 / 0, maxHeight: 1 / 0, maxArea: this.maxCanvasSize, imageSmoothingEnabled: !0, imageSmoothingQuality: "high", fillColor: "transparent" }, this.canvas), s = function(l) {
|
|
10312
10335
|
return l.find(function(r) {
|
|
10313
10336
|
return d = r, !Number.isNaN(parseFloat(d)) && isFinite(d);
|
|
10314
10337
|
var d;
|
|
@@ -10341,7 +10364,7 @@ var r1 = ["transitions"], xn = ln("vue-advanced-cropper"), ad = { name: "Cropper
|
|
|
10341
10364
|
n.minWidth, n.minHeight, n.maxWidth, n.maxHeight;
|
|
10342
10365
|
var i = mi(e) ? e({ boundaries: this.boundaries, imageSize: this.imageSize, aspectRatio: this.getAspectRatio(), sizeRestrictions: this.sizeRestrictions, stencilSize: this.getStencilSize(), visibleArea: this.visibleArea }) : e, s = this.defaultPosition || jv, o = [i, function(a) {
|
|
10343
10366
|
var l = a.coordinates;
|
|
10344
|
-
return
|
|
10367
|
+
return Le({}, mi(s) ? s({ coordinates: l, imageSize: t.imageSize, visibleArea: t.visibleArea }) : t.defaultPosition);
|
|
10345
10368
|
}];
|
|
10346
10369
|
this.delayedTransforms && o.push.apply(o, li(Array.isArray(this.delayedTransforms) ? this.delayedTransforms : [this.delayedTransforms])), this.coordinates = this.applyTransform(o, !0), this.delayedTransforms = null;
|
|
10347
10370
|
}
|
|
@@ -10369,10 +10392,10 @@ var r1 = ["transitions"], xn = ln("vue-advanced-cropper"), ad = { name: "Cropper
|
|
|
10369
10392
|
});
|
|
10370
10393
|
}, resetVisibleArea: function() {
|
|
10371
10394
|
var t = this;
|
|
10372
|
-
return this.appliedImageTransforms =
|
|
10395
|
+
return this.appliedImageTransforms = Le(Le({}, this.defaultImageTransforms), {}, { flip: Le({}, this.defaultImageTransforms.flip) }), this.updateBoundaries().then(function() {
|
|
10373
10396
|
t.priority !== "visible-area" && (t.visibleArea = null, t.resetCoordinates());
|
|
10374
10397
|
var e, n, i, s, o, a, l = t.defaultVisibleArea || Yv;
|
|
10375
|
-
t.visibleArea = mi(l) ? l({ imageSize: t.imageSize, boundaries: t.boundaries, coordinates: t.priority !== "visible-area" ? t.coordinates : null, getAreaRestrictions: t.getAreaRestrictions, stencilSize: t.getStencilSize() }) : t.defaultVisibleArea, t.visibleArea = (e = { visibleArea: t.visibleArea, boundaries: t.boundaries, getAreaRestrictions: t.getAreaRestrictions }, n = e.visibleArea, i = e.boundaries, s = e.getAreaRestrictions, o = ge({}, n), a =
|
|
10398
|
+
t.visibleArea = mi(l) ? l({ imageSize: t.imageSize, boundaries: t.boundaries, coordinates: t.priority !== "visible-area" ? t.coordinates : null, getAreaRestrictions: t.getAreaRestrictions, stencilSize: t.getStencilSize() }) : t.defaultVisibleArea, t.visibleArea = (e = { visibleArea: t.visibleArea, boundaries: t.boundaries, getAreaRestrictions: t.getAreaRestrictions }, n = e.visibleArea, i = e.boundaries, s = e.getAreaRestrictions, o = ge({}, n), a = _e(i), o.width / o.height !== a && (o.height = o.width / a), Pt(o, s({ visibleArea: o, type: "move" }))), t.priority === "visible-area" ? t.resetCoordinates() : t.coordinates = t.fitCoordinates({ visibleArea: t.visibleArea, coordinates: t.coordinates, aspectRatio: t.getAspectRatio(), positionRestrictions: t.positionRestrictions, sizeRestrictions: t.sizeRestrictions }), t.runAutoZoom("resetVisibleArea");
|
|
10376
10399
|
}).catch(function() {
|
|
10377
10400
|
t.visibleArea = null;
|
|
10378
10401
|
});
|
|
@@ -10396,7 +10419,7 @@ var r1 = ["transitions"], xn = ln("vue-advanced-cropper"), ad = { name: "Cropper
|
|
|
10396
10419
|
};
|
|
10397
10420
|
return !(!l.protocol && !l.host && !l.port || l.protocol && l.protocol == o.protocol && l.host && l.host == o.host && l.host && r(l) == r(o));
|
|
10398
10421
|
}(this.src)) {
|
|
10399
|
-
var n =
|
|
10422
|
+
var n = gt(this.crossOrigin) ? this.canvas : this.crossOrigin;
|
|
10400
10423
|
n === !0 && (n = "anonymous"), this.imageAttributes.crossOrigin = n || null;
|
|
10401
10424
|
}
|
|
10402
10425
|
if (this.checkOrientation) {
|
|
@@ -10455,7 +10478,7 @@ var r1 = ["transitions"], xn = ln("vue-advanced-cropper"), ad = { name: "Cropper
|
|
|
10455
10478
|
a.rotate = -90;
|
|
10456
10479
|
}
|
|
10457
10480
|
return a;
|
|
10458
|
-
}(s), this.defaultImageTransforms =
|
|
10481
|
+
}(s), this.defaultImageTransforms = Le(Le({}, this.appliedImageTransforms), {}, { flip: Le({}, this.appliedImageTransforms.flip) }), this.$nextTick(function() {
|
|
10459
10482
|
var o = e.$refs.image;
|
|
10460
10483
|
o && o.complete && (function(a) {
|
|
10461
10484
|
return !!a.naturalWidth;
|
|
@@ -10468,20 +10491,20 @@ var r1 = ["transitions"], xn = ln("vue-advanced-cropper"), ad = { name: "Cropper
|
|
|
10468
10491
|
}, onMove: function(t) {
|
|
10469
10492
|
var e = this;
|
|
10470
10493
|
this.transitionsOptions.enabled || this.awaitRender(function() {
|
|
10471
|
-
e.coordinates = e.moveAlgorithm(
|
|
10494
|
+
e.coordinates = e.moveAlgorithm(Le(Le({}, e.getPublicProperties()), {}, { positionRestrictions: Ms(e.positionRestrictions, e.visibleArea), coordinates: e.coordinates, event: e.normalizeEvent(t) })), e.onChange();
|
|
10472
10495
|
});
|
|
10473
10496
|
}, onResize: function(t) {
|
|
10474
10497
|
var e = this;
|
|
10475
10498
|
this.transitionsOptions.enabled || this.stencilSize && !this.autoZoom || this.awaitRender(function() {
|
|
10476
10499
|
var n = e.sizeRestrictions, i = Math.min(e.coordinates.width, e.coordinates.height, 20 * e.coefficient);
|
|
10477
|
-
e.coordinates = e.resizeAlgorithm(
|
|
10500
|
+
e.coordinates = e.resizeAlgorithm(Le(Le({}, e.getPublicProperties()), {}, { positionRestrictions: Ms(e.positionRestrictions, e.visibleArea), sizeRestrictions: { maxWidth: Math.min(n.maxWidth, e.visibleArea.width), maxHeight: Math.min(n.maxHeight, e.visibleArea.height), minWidth: Math.max(n.minWidth, i), minHeight: Math.max(n.minHeight, i) }, event: e.normalizeEvent(t) })), e.onChange(), e.ticking = !1;
|
|
10478
10501
|
});
|
|
10479
10502
|
}, onManipulateImage: function(t) {
|
|
10480
10503
|
var e = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {};
|
|
10481
10504
|
if (!this.transitionsOptions.enabled) {
|
|
10482
10505
|
var n = e.transitions, i = n !== void 0 && n, s = e.normalize, o = s === void 0 || s;
|
|
10483
10506
|
i && this.enableTransitions();
|
|
10484
|
-
var a = Qv(
|
|
10507
|
+
var a = Qv(Le(Le({}, this.getPublicProperties()), {}, { event: o ? this.normalizeEvent(t) : t, getAreaRestrictions: this.getAreaRestrictions, imageRestriction: this.imageRestriction, adjustStencil: !this.stencilSize && this.settings.resizeImage.adjustStencil })), l = a.visibleArea, r = a.coordinates;
|
|
10485
10508
|
this.visibleArea = l, this.coordinates = r, this.runAutoZoom("manipulateImage"), this.onChange(), i && this.debouncedDisableTransitions();
|
|
10486
10509
|
}
|
|
10487
10510
|
}, onPropsChange: function() {
|
|
@@ -10495,30 +10518,30 @@ var r1 = ["transitions"], xn = ln("vue-advanced-cropper"), ad = { name: "Cropper
|
|
|
10495
10518
|
var l = this.$refs.stencil.aspectRatios();
|
|
10496
10519
|
e = l.minimum, n = l.maximum;
|
|
10497
10520
|
}
|
|
10498
|
-
if (
|
|
10499
|
-
var r = this.getStencilSize(), d = r ?
|
|
10500
|
-
|
|
10521
|
+
if (gt(e) && (e = gt(s) ? o : s), gt(n) && (n = gt(s) ? a : s), !t && (gt(e) || gt(n))) {
|
|
10522
|
+
var r = this.getStencilSize(), d = r ? _e(r) : null;
|
|
10523
|
+
gt(e) && (e = il(d) ? d : void 0), gt(n) && (n = il(d) ? d : void 0);
|
|
10501
10524
|
}
|
|
10502
10525
|
return { minimum: e, maximum: n };
|
|
10503
10526
|
}, getStencilSize: function() {
|
|
10504
|
-
if (this.stencilSize) return t = { currentStencilSize: { width: this.stencilCoordinates.width, height: this.stencilCoordinates.height }, stencilSize: this.stencilSize, boundaries: this.boundaries, coefficient: this.coefficient, coordinates: this.coordinates, aspectRatio: this.getAspectRatio(!0) }, e = t.boundaries, n = t.stencilSize, i = t.aspectRatio, Xo(
|
|
10527
|
+
if (this.stencilSize) return t = { currentStencilSize: { width: this.stencilCoordinates.width, height: this.stencilCoordinates.height }, stencilSize: this.stencilSize, boundaries: this.boundaries, coefficient: this.coefficient, coordinates: this.coordinates, aspectRatio: this.getAspectRatio(!0) }, e = t.boundaries, n = t.stencilSize, i = t.aspectRatio, Xo(_e(s = mi(n) ? n({ boundaries: e, aspectRatio: i }) : n), i) && (s = Pn({ sizeRestrictions: { maxWidth: e.width, maxHeight: e.height, minWidth: 0, minHeight: 0 }, width: s.width, height: s.height, aspectRatio: { minimum: i.minimum, maximum: i.maximum } })), (s.width > e.width || s.height > e.height) && (s = Pn({ sizeRestrictions: { maxWidth: e.width, maxHeight: e.height, minWidth: 0, minHeight: 0 }, width: s.width, height: s.height, aspectRatio: { minimum: _e(s), maximum: _e(s) } })), s;
|
|
10505
10528
|
var t, e, n, i, s;
|
|
10506
10529
|
}, getPublicProperties: function() {
|
|
10507
10530
|
return { coefficient: this.coefficient, visibleArea: this.visibleArea, coordinates: this.coordinates, boundaries: this.boundaries, sizeRestrictions: this.sizeRestrictions, positionRestrictions: this.positionRestrictions, aspectRatio: this.getAspectRatio(), imageRestriction: this.imageRestriction };
|
|
10508
10531
|
}, defaultCoordinates: function() {
|
|
10509
|
-
return
|
|
10532
|
+
return Le({}, sl);
|
|
10510
10533
|
}, flip: function(t, e) {
|
|
10511
10534
|
var n = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : {}, i = n.transitions, s = i === void 0 || i;
|
|
10512
10535
|
if (!this.transitionsActive) {
|
|
10513
10536
|
s && this.enableTransitions();
|
|
10514
|
-
var o =
|
|
10537
|
+
var o = Le({}, this.imageTransforms.flip), a = Zv({ flip: { horizontal: t ? !o.horizontal : o.horizontal, vertical: e ? !o.vertical : o.vertical }, previousFlip: o, rotate: this.imageTransforms.rotate, visibleArea: this.visibleArea, coordinates: this.coordinates, imageSize: this.imageSize, positionRestrictions: this.positionRestrictions, sizeRestrictions: this.sizeRestrictions, getAreaRestrictions: this.getAreaRestrictions, aspectRatio: this.getAspectRatio() }), l = a.visibleArea, r = a.coordinates;
|
|
10515
10538
|
t && (this.appliedImageTransforms.flip.horizontal = !this.appliedImageTransforms.flip.horizontal), e && (this.appliedImageTransforms.flip.vertical = !this.appliedImageTransforms.flip.vertical), this.visibleArea = l, this.coordinates = r, this.onChange(), s && this.debouncedDisableTransitions();
|
|
10516
10539
|
}
|
|
10517
10540
|
}, rotate: function(t) {
|
|
10518
10541
|
var e = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, n = e.transitions, i = n === void 0 || n;
|
|
10519
10542
|
if (!this.transitionsActive) {
|
|
10520
10543
|
i && this.enableTransitions();
|
|
10521
|
-
var s =
|
|
10544
|
+
var s = Le({}, this.imageSize);
|
|
10522
10545
|
this.appliedImageTransforms.rotate += t;
|
|
10523
10546
|
var o = Xv({ visibleArea: this.visibleArea, coordinates: this.coordinates, previousImageSize: s, imageSize: this.imageSize, angle: t, positionRestrictions: this.positionRestrictions, sizeRestrictions: this.sizeRestrictions, getAreaRestrictions: this.getAreaRestrictions, aspectRatio: this.getAspectRatio() }), a = o.visibleArea, l = o.coordinates, r = this.processAutoZoom("rotateImage", a, l);
|
|
10524
10547
|
a = r.visibleArea, l = r.coordinates, this.visibleArea = a, this.coordinates = l, this.onChange(), i && this.debouncedDisableTransitions();
|
|
@@ -10527,7 +10550,7 @@ var r1 = ["transitions"], xn = ln("vue-advanced-cropper"), ad = { name: "Cropper
|
|
|
10527
10550
|
ad.render = function(t, e, n, i, s, o) {
|
|
10528
10551
|
return m(), z("div", { ref: "cropper", class: o.classes.cropper }, [g("div", { ref: "stretcher", class: o.classes.stretcher }, null, 2), g("div", { class: o.classes.boundaries, style: o.boundariesStyle }, [(m(), z(Rn(n.backgroundWrapperComponent), { class: o.classes.cropperWrapper, "wheel-resize": o.settings.resizeImage.wheel, "touch-resize": o.settings.resizeImage.touch, "touch-move": o.settings.moveImage.touch, "mouse-move": o.settings.moveImage.mouse, onMove: o.onManipulateImage, onResize: o.onManipulateImage }, { default: C(function() {
|
|
10529
10552
|
return [g("div", { class: o.classes.background, style: o.boundariesStyle }, null, 6), g("div", { class: o.classes.imageWrapper }, [g("img", { ref: "image", crossorigin: s.imageAttributes.crossOrigin, src: s.imageAttributes.src, class: o.classes.image, style: o.imageStyle, onMousedown: e[1] || (e[1] = Ye(function() {
|
|
10530
|
-
}, ["prevent"])) }, null, 46, ["crossorigin", "src"])], 2), g("div", { class: o.classes.foreground, style: o.boundariesStyle }, null, 6),
|
|
10553
|
+
}, ["prevent"])) }, null, 46, ["crossorigin", "src"])], 2), g("div", { class: o.classes.foreground, style: o.boundariesStyle }, null, 6), Je((m(), z(Rn(n.stencilComponent), at({ ref: "stencil", image: o.image, coordinates: s.coordinates, "stencil-coordinates": o.stencilCoordinates, transitions: o.transitionsOptions }, n.stencilProps, { onResize: o.onResize, onResizeEnd: o.onResizeEnd, onMove: o.onMove, onMoveEnd: o.onMoveEnd }), null, 16, ["image", "coordinates", "stencil-coordinates", "transitions", "onResize", "onResizeEnd", "onMove", "onMoveEnd"])), [[eo, s.imageLoaded]]), n.canvas ? (m(), z("canvas", l1, null, 512)) : G("", !0), n.canvas ? (m(), z("canvas", u1, null, 512)) : G("", !0)];
|
|
10531
10554
|
}), _: 1 }, 8, ["class", "wheel-resize", "touch-resize", "touch-move", "mouse-move", "onMove", "onResize"]))], 6)], 2);
|
|
10532
10555
|
};
|
|
10533
10556
|
const d1 = {
|
|
@@ -10812,7 +10835,7 @@ const c1 = { class: "cropper-wrapper" }, f1 = { class: "row justify-end q-mt-md"
|
|
|
10812
10835
|
g(f(kt), { class: "row items-center q-pb-none" }, {
|
|
10813
10836
|
default: C(() => [
|
|
10814
10837
|
g(f(_n)),
|
|
10815
|
-
|
|
10838
|
+
Je(g(ue, {
|
|
10816
10839
|
icon: "close",
|
|
10817
10840
|
flat: "",
|
|
10818
10841
|
round: "",
|
|
@@ -10849,7 +10872,7 @@ const c1 = { class: "cropper-wrapper" }, f1 = { class: "row justify-end q-mt-md"
|
|
|
10849
10872
|
class: "p-form-image-input__status"
|
|
10850
10873
|
}, S1 = /* @__PURE__ */ j({
|
|
10851
10874
|
__name: "PFormImageInput",
|
|
10852
|
-
props: /* @__PURE__ */
|
|
10875
|
+
props: /* @__PURE__ */ De({
|
|
10853
10876
|
height: { default: 180 },
|
|
10854
10877
|
ratio: { default: 16 / 9 }
|
|
10855
10878
|
}, {
|
|
@@ -10858,7 +10881,7 @@ const c1 = { class: "cropper-wrapper" }, f1 = { class: "row justify-end q-mt-md"
|
|
|
10858
10881
|
}),
|
|
10859
10882
|
emits: ["update:modelValue"],
|
|
10860
10883
|
setup(t) {
|
|
10861
|
-
const e =
|
|
10884
|
+
const e = vt(t, "modelValue"), n = ht(new Nt());
|
|
10862
10885
|
n.getFileUrl = () => n.url || n.fileSystemPath;
|
|
10863
10886
|
const i = O(!1);
|
|
10864
10887
|
Ae(
|
|
@@ -11183,7 +11206,7 @@ const T1 = { class: "p-form-renderer" }, P1 = {
|
|
|
11183
11206
|
}, [
|
|
11184
11207
|
l(x) ? (m(), S(K, { key: 0 }, [
|
|
11185
11208
|
x.name ? (m(), S("div", M1, U(x.name), 1)) : G("", !0),
|
|
11186
|
-
(m(!0), S(K, null, we(x.fields, (V) =>
|
|
11209
|
+
(m(!0), S(K, null, we(x.fields, (V) => Je((m(), S("div", {
|
|
11187
11210
|
key: V.id,
|
|
11188
11211
|
class: "field-block q-mb-md"
|
|
11189
11212
|
}, [
|
|
@@ -11368,7 +11391,7 @@ const T1 = { class: "p-form-renderer" }, P1 = {
|
|
|
11368
11391
|
class: "text-caption text-grey-7 q-pt-md"
|
|
11369
11392
|
}, dy = { class: "col-auto" }, cy = /* @__PURE__ */ j({
|
|
11370
11393
|
__name: "PFormFieldEditor",
|
|
11371
|
-
props: /* @__PURE__ */
|
|
11394
|
+
props: /* @__PURE__ */ De({
|
|
11372
11395
|
valueTypes: {},
|
|
11373
11396
|
typeLabels: {},
|
|
11374
11397
|
fields: {}
|
|
@@ -11376,9 +11399,9 @@ const T1 = { class: "p-form-renderer" }, P1 = {
|
|
|
11376
11399
|
field: { required: !0 },
|
|
11377
11400
|
fieldModifiers: {}
|
|
11378
11401
|
}),
|
|
11379
|
-
emits: /* @__PURE__ */
|
|
11402
|
+
emits: /* @__PURE__ */ De(["move", "remove", "change"], ["update:field"]),
|
|
11380
11403
|
setup(t, { emit: e }) {
|
|
11381
|
-
const n =
|
|
11404
|
+
const n = vt(t, "field"), i = t, s = e, o = {
|
|
11382
11405
|
string: "Строка",
|
|
11383
11406
|
text: "Текст",
|
|
11384
11407
|
number: "Число",
|
|
@@ -11417,9 +11440,9 @@ const T1 = { class: "p-form-renderer" }, P1 = {
|
|
|
11417
11440
|
], k = D(
|
|
11418
11441
|
() => (i.fields ?? []).filter((I) => I.id !== n.value.id).map((I) => ({ label: I.name || I.code || "Вопрос", value: I.id }))
|
|
11419
11442
|
), P = (I) => (i.fields ?? []).find((L) => L.id === I.dependsOnFieldId), E = (I) => ["equals", "notEquals", "contains", "notContains"].includes(I), T = (I) => {
|
|
11420
|
-
var xe, ke,
|
|
11443
|
+
var xe, ke, Ke, mt;
|
|
11421
11444
|
const L = P(I);
|
|
11422
|
-
return (!!((ke = (xe = L == null ? void 0 : L.valueType) == null ? void 0 : xe.isRadio) != null && ke.call(xe)) || !!((
|
|
11445
|
+
return (!!((ke = (xe = L == null ? void 0 : L.valueType) == null ? void 0 : xe.isRadio) != null && ke.call(xe)) || !!((mt = (Ke = L == null ? void 0 : L.valueType) == null ? void 0 : Ke.isSet) != null && mt.call(Ke))) && E(I.operator);
|
|
11423
11446
|
}, M = (I) => !["answered", "notAnswered"].includes(I.operator), x = (I) => {
|
|
11424
11447
|
var L;
|
|
11425
11448
|
return (((L = P(I)) == null ? void 0 : L.answerVariants) ?? []).map((Q) => ({ label: Q.name, value: Q.id }));
|
|
@@ -11619,16 +11642,16 @@ const T1 = { class: "p-form-renderer" }, P1 = {
|
|
|
11619
11642
|
class: "col-auto"
|
|
11620
11643
|
}, my = { class: "col" }, py = { class: "col-auto" }, gy = { class: "drag-handle" }, vy = /* @__PURE__ */ j({
|
|
11621
11644
|
__name: "PFormSectionEditor",
|
|
11622
|
-
props: /* @__PURE__ */
|
|
11645
|
+
props: /* @__PURE__ */ De({
|
|
11623
11646
|
valueTypes: {},
|
|
11624
11647
|
fields: {}
|
|
11625
11648
|
}, {
|
|
11626
11649
|
section: { required: !0 },
|
|
11627
11650
|
sectionModifiers: {}
|
|
11628
11651
|
}),
|
|
11629
|
-
emits: /* @__PURE__ */
|
|
11652
|
+
emits: /* @__PURE__ */ De(["move", "remove", "change"], ["update:section"]),
|
|
11630
11653
|
setup(t, { emit: e }) {
|
|
11631
|
-
const n =
|
|
11654
|
+
const n = vt(t, "section"), i = e, s = () => {
|
|
11632
11655
|
n.value.sortFields();
|
|
11633
11656
|
}, o = () => {
|
|
11634
11657
|
s(), i("change");
|
|
@@ -11729,15 +11752,15 @@ const T1 = { class: "p-form-renderer" }, P1 = {
|
|
|
11729
11752
|
style: { "min-width": "180px" }
|
|
11730
11753
|
}, Cy = { class: "col-auto" }, ky = { class: "form-image q-mb-md" }, xy = { class: "drag-handle" }, $y = { class: "preview-card" }, Ty = { class: "row items-center justify-between q-mb-md" }, Py = /* @__PURE__ */ j({
|
|
11731
11754
|
__name: "PFormBuilder",
|
|
11732
|
-
props: /* @__PURE__ */
|
|
11755
|
+
props: /* @__PURE__ */ De({
|
|
11733
11756
|
valueTypes: {}
|
|
11734
11757
|
}, {
|
|
11735
11758
|
form: { required: !0 },
|
|
11736
11759
|
formModifiers: {}
|
|
11737
11760
|
}),
|
|
11738
|
-
emits: /* @__PURE__ */
|
|
11761
|
+
emits: /* @__PURE__ */ De(["change", "save"], ["update:form"]),
|
|
11739
11762
|
setup(t, { emit: e }) {
|
|
11740
|
-
const n =
|
|
11763
|
+
const n = vt(t, "form"), i = t, s = e, o = O(i.valueTypes ?? []), a = O(!1), l = [
|
|
11741
11764
|
{ label: "Черновик", value: "draft" },
|
|
11742
11765
|
{ label: "Опубликована", value: "published" }
|
|
11743
11766
|
], r = D(() => n.value.getFields()), d = O(null), c = () => {
|
|
@@ -12386,7 +12409,7 @@ class $o {
|
|
|
12386
12409
|
Ce.BuildClass(this, e);
|
|
12387
12410
|
}
|
|
12388
12411
|
addFile(e) {
|
|
12389
|
-
this.icon.id || (this.icon.id =
|
|
12412
|
+
this.icon.id || (this.icon.id = Lt.UUID()), this.icon.originalName = e.name, this.icon.file = e.raw;
|
|
12390
12413
|
}
|
|
12391
12414
|
}
|
|
12392
12415
|
var e0 = Object.defineProperty, t0 = (t, e, n, i) => {
|
|
@@ -12423,7 +12446,7 @@ class Ja {
|
|
|
12423
12446
|
}), e;
|
|
12424
12447
|
}
|
|
12425
12448
|
addFile(e) {
|
|
12426
|
-
this.icon.id || (this.icon.id =
|
|
12449
|
+
this.icon.id || (this.icon.id = Lt.UUID()), this.icon.originalName = e.name, this.icon.file = e.raw;
|
|
12427
12450
|
}
|
|
12428
12451
|
addSubMenu() {
|
|
12429
12452
|
this.subMenus.push(new $o());
|
|
@@ -12770,36 +12793,36 @@ const S0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
12770
12793
|
SchedulePlace: ys,
|
|
12771
12794
|
ScheduleSession: vs,
|
|
12772
12795
|
ScheduleSlot: Yn
|
|
12773
|
-
}, Symbol.toStringTag, { value: "Module" })),
|
|
12796
|
+
}, Symbol.toStringTag, { value: "Module" })), Ve = (t) => t ? Y.H.Time.HMtoM(t) : NaN, It = (t) => Y.H.Time.ConcatHM(Math.floor(t / 60), t % 60), Zn = (t) => {
|
|
12774
12797
|
if (!t)
|
|
12775
12798
|
return "";
|
|
12776
12799
|
const e = Y.H.Time.HmsToHm(t);
|
|
12777
12800
|
return /^\d{1,2}:\d{2}$/.test(e) ? e : "";
|
|
12778
12801
|
}, vi = (t, e) => Y.H.Time.DiffM(t ?? "", e ?? ""), tn = (t, e) => Y.H.Time.AddMtoHM(t, e), $a = (t, e) => {
|
|
12779
|
-
const n =
|
|
12802
|
+
const n = Ve(t.startTime), i = Ve(e.startTime);
|
|
12780
12803
|
return isFinite(n) ? isFinite(i) ? n - i : -1 : 1;
|
|
12781
12804
|
}, Wi = (t, e) => {
|
|
12782
|
-
const n =
|
|
12805
|
+
const n = Ve(t.startTime), i = Ve(t.endTime), s = Ve(e.startTime), o = Ve(e.endTime);
|
|
12783
12806
|
return !isFinite(n) || !isFinite(i) || !isFinite(s) || !isFinite(o) ? !1 : n < o && s < i;
|
|
12784
12807
|
}, Yi = (t, e) => Math.round(t / e) * e, Id = (t, e = 8 * 60, n = 20 * 60) => {
|
|
12785
12808
|
let i = e, s = n;
|
|
12786
12809
|
for (const { item: l } of t) {
|
|
12787
|
-
const r =
|
|
12810
|
+
const r = Ve(l.startTime), d = Ve(l.endTime);
|
|
12788
12811
|
isFinite(r) && (i = Math.min(i, r)), isFinite(d) && (s = Math.max(s, d));
|
|
12789
12812
|
}
|
|
12790
12813
|
const o = Math.floor(i / 60) * 60, a = Math.ceil(s / 60) * 60;
|
|
12791
12814
|
return { start: o, end: a, total: a - o || 60 };
|
|
12792
12815
|
}, Md = (t, e) => {
|
|
12793
|
-
const n =
|
|
12816
|
+
const n = Ve(t.item.startTime), i = Ve(t.item.endTime);
|
|
12794
12817
|
if (!isFinite(n) || !isFinite(i))
|
|
12795
12818
|
return { top: "0%", height: "48px" };
|
|
12796
12819
|
const s = (n - e.start) / e.total * 100, o = Math.max((i - n) / e.total * 100, 2.5);
|
|
12797
12820
|
return { top: s + "%", height: o + "%" };
|
|
12798
12821
|
}, Ad = (t, e) => {
|
|
12799
|
-
const n =
|
|
12822
|
+
const n = Ve(t.startTime), i = Ve(t.endTime);
|
|
12800
12823
|
if (!isFinite(n) || !isFinite(i) || i <= n)
|
|
12801
12824
|
return { top: "0%", height: "auto" };
|
|
12802
|
-
const s = i - n, o =
|
|
12825
|
+
const s = i - n, o = Ve(e.startTime), a = Ve(e.endTime), l = isFinite(o) ? Math.max((o - n) / s * 100, 0) : 0;
|
|
12803
12826
|
let r = isFinite(o) && isFinite(a) ? (a - o) / s * 100 : 8;
|
|
12804
12827
|
return r = Math.min(Math.max(r, 3), 100 - l), { top: l + "%", height: r + "%" };
|
|
12805
12828
|
}, Ed = (t, e, n) => t.some((i) => i.item.id === e.item.id || e.kind === "session" && i.kind === "slot" && i.item.sessionId === e.item.id ? !1 : n(e.item, i.item)), Fd = (t, e, n) => t.some((i) => i.id !== e.id && n(e, i)), Od = (t, e, n, i) => {
|
|
@@ -13158,12 +13181,12 @@ const S0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
13158
13181
|
})), a = D(() => ({
|
|
13159
13182
|
...Ld,
|
|
13160
13183
|
...e.factories
|
|
13161
|
-
})), l = (v) => e.slotListOf ? e.slotListOf(v) : (v == null ? void 0 : v.slots) || [], r = (v) => e.nestedSlotListOf ? e.nestedSlotListOf(v) : (v == null ? void 0 : v.slots) || [], d = (v) => (v == null ? void 0 : v.name) || o.value.hall, c = (v) => e.sessionName ? e.sessionName(v) : (v == null ? void 0 : v.name) || `${o.value.session} ${(v == null ? void 0 : v.startTime) || ""}–${(v == null ? void 0 : v.endTime) || ""}`.trim(), h = (v) => e.slotName ? e.slotName(v) : (v == null ? void 0 : v.name) || o.value.slot, p = (v) => e.slotSubtitle ? e.slotSubtitle(v) : "", b = O("grid"), k = O((kr = (Cr = e.days) == null ? void 0 : Cr[0]) == null ? void 0 : kr.id), P = O(!1), E = O(""), T = O(!1), M = O(!1), x = O(null), V = O(null), $ = O(null), B = O(void 0), I = O(null), L = O(null), Q = O(!1), xe = O(0), ke = O(null),
|
|
13184
|
+
})), l = (v) => e.slotListOf ? e.slotListOf(v) : (v == null ? void 0 : v.slots) || [], r = (v) => e.nestedSlotListOf ? e.nestedSlotListOf(v) : (v == null ? void 0 : v.slots) || [], d = (v) => (v == null ? void 0 : v.name) || o.value.hall, c = (v) => e.sessionName ? e.sessionName(v) : (v == null ? void 0 : v.name) || `${o.value.session} ${(v == null ? void 0 : v.startTime) || ""}–${(v == null ? void 0 : v.endTime) || ""}`.trim(), h = (v) => e.slotName ? e.slotName(v) : (v == null ? void 0 : v.name) || o.value.slot, p = (v) => e.slotSubtitle ? e.slotSubtitle(v) : "", b = O("grid"), k = O((kr = (Cr = e.days) == null ? void 0 : Cr[0]) == null ? void 0 : kr.id), P = O(!1), E = O(""), T = O(!1), M = O(!1), x = O(null), V = O(null), $ = O(null), B = O(void 0), I = O(null), L = O(null), Q = O(!1), xe = O(0), ke = O(null), Ke = [
|
|
13162
13185
|
{ label: "5 мин", value: 5 },
|
|
13163
13186
|
{ label: "10 мин", value: 10 },
|
|
13164
13187
|
{ label: "15 мин", value: 15 },
|
|
13165
13188
|
{ label: "30 мин", value: 30 }
|
|
13166
|
-
],
|
|
13189
|
+
], mt = [
|
|
13167
13190
|
{ label: "20 px/ч", value: 20 },
|
|
13168
13191
|
{ label: "30 px/ч", value: 30 },
|
|
13169
13192
|
{ label: "40 px/ч", value: 40 },
|
|
@@ -13173,30 +13196,30 @@ const S0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
13173
13196
|
{ label: "160 px/ч", value: 160 },
|
|
13174
13197
|
{ label: "200 px/ч", value: 200 },
|
|
13175
13198
|
{ label: "240 px/ч", value: 240 }
|
|
13176
|
-
],
|
|
13199
|
+
], Xe = D(() => [
|
|
13177
13200
|
{ label: o.value.grid, value: "grid", icon: "calendar_view_week" },
|
|
13178
13201
|
{ label: o.value.list, value: "list", icon: "view_list" }
|
|
13179
13202
|
]), rt = (v, w, R) => {
|
|
13180
13203
|
const q = Number(localStorage.getItem(v));
|
|
13181
13204
|
return w.includes(q) ? q : R;
|
|
13182
13205
|
}, lt = O(
|
|
13183
|
-
rt(cl,
|
|
13184
|
-
),
|
|
13185
|
-
rt(fl,
|
|
13206
|
+
rt(cl, Ke.map((v) => v.value), Mb)
|
|
13207
|
+
), Vt = O(
|
|
13208
|
+
rt(fl, mt.map((v) => v.value), Ab)
|
|
13186
13209
|
), yt = D(() => lt.value);
|
|
13187
|
-
Ae(lt, (v) => localStorage.setItem(cl, String(v))), Ae(
|
|
13188
|
-
const un = D(() => Math.max(
|
|
13210
|
+
Ae(lt, (v) => localStorage.setItem(cl, String(v))), Ae(Vt, (v) => localStorage.setItem(fl, String(v)));
|
|
13211
|
+
const un = D(() => Math.max(Ze.value.total / 60 * Vt.value, 360)), Dt = D(() => un.value + "px"), Ue = D(
|
|
13189
13212
|
() => [...e.days || []].sort(
|
|
13190
13213
|
(v, w) => new Date(v.date).getTime() - new Date(w.date).getTime()
|
|
13191
13214
|
)
|
|
13192
13215
|
), oe = D(
|
|
13193
|
-
() =>
|
|
13216
|
+
() => Ue.value.find((v) => v.id === k.value)
|
|
13194
13217
|
);
|
|
13195
13218
|
Ae(
|
|
13196
|
-
() =>
|
|
13219
|
+
() => Ue.value.map((v) => v.id).join(","),
|
|
13197
13220
|
() => {
|
|
13198
13221
|
var v;
|
|
13199
|
-
(!k.value || !
|
|
13222
|
+
(!k.value || !Ue.value.some((w) => w.id === k.value)) && (k.value = (v = Ue.value[0]) == null ? void 0 : v.id);
|
|
13200
13223
|
}
|
|
13201
13224
|
);
|
|
13202
13225
|
const ut = (v) => {
|
|
@@ -13219,13 +13242,13 @@ const S0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
13219
13242
|
if (!v)
|
|
13220
13243
|
return;
|
|
13221
13244
|
for (const q of Oe(v))
|
|
13222
|
-
await
|
|
13245
|
+
await _t(q);
|
|
13223
13246
|
await e.persist.removeDay(v);
|
|
13224
13247
|
const w = (e.days || []).indexOf(v);
|
|
13225
|
-
w >= 0 && e.days.splice(w, 1), await e.persist.refresh(), k.value = (R =
|
|
13248
|
+
w >= 0 && e.days.splice(w, 1), await e.persist.refresh(), k.value = (R = Ue.value[0]) == null ? void 0 : R.id;
|
|
13226
13249
|
}, me = async () => {
|
|
13227
13250
|
var ee, fe;
|
|
13228
|
-
const v =
|
|
13251
|
+
const v = Ue.value, w = v[v.length - 1], R = w ? new Date(new Date(w.date).getTime() + 864e5) : /* @__PURE__ */ new Date();
|
|
13229
13252
|
let q;
|
|
13230
13253
|
try {
|
|
13231
13254
|
q = a.value.createDay(R);
|
|
@@ -13235,8 +13258,8 @@ const S0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
13235
13258
|
}
|
|
13236
13259
|
try {
|
|
13237
13260
|
await ((fe = (ee = e.persist).createDay) == null ? void 0 : fe.call(ee, q));
|
|
13238
|
-
for (const
|
|
13239
|
-
await En(
|
|
13261
|
+
for (const ze of e.places || [])
|
|
13262
|
+
await En(ze, q);
|
|
13240
13263
|
await e.persist.refresh();
|
|
13241
13264
|
} catch {
|
|
13242
13265
|
e.persist.notify("negative", o.value.createFailed);
|
|
@@ -13244,9 +13267,9 @@ const S0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
13244
13267
|
}
|
|
13245
13268
|
k.value = q.id, e.persist.notify("positive", `${o.value.dayAdded}: ${ut(q)}`);
|
|
13246
13269
|
}, Oe = (v) => ((v == null ? void 0 : v.schedules) || []).slice().sort((w, R) => {
|
|
13247
|
-
const q =
|
|
13270
|
+
const q = pt(w), ee = pt(R);
|
|
13248
13271
|
return q.localeCompare(ee, "ru");
|
|
13249
|
-
}),
|
|
13272
|
+
}), pt = (v) => {
|
|
13250
13273
|
if (e.hallName)
|
|
13251
13274
|
return e.hallName(v);
|
|
13252
13275
|
const w = v.place || (e.places || []).find((R) => R.id === v.placeId);
|
|
@@ -13300,10 +13323,10 @@ const S0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
13300
13323
|
}
|
|
13301
13324
|
E.value = "", await wt(w), e.persist.notify("positive", o.value.hallCreated.replace("{name}", v));
|
|
13302
13325
|
}, dt = async (v) => {
|
|
13303
|
-
await
|
|
13326
|
+
await _t(v);
|
|
13304
13327
|
const w = jt(v);
|
|
13305
13328
|
w && (w.schedules = (w.schedules || []).filter((R) => R.id !== v.id)), await e.persist.refresh();
|
|
13306
|
-
},
|
|
13329
|
+
}, _t = async (v) => {
|
|
13307
13330
|
for (const w of v.sessions || []) {
|
|
13308
13331
|
for (const R of r(w))
|
|
13309
13332
|
await e.persist.removeSlot(R);
|
|
@@ -13314,7 +13337,7 @@ const S0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
13314
13337
|
await e.persist.removeSchedule(v);
|
|
13315
13338
|
}, jt = (v) => (e.days || []).find(
|
|
13316
13339
|
(w) => (w.schedules || []).some((R) => R.id === v.id)
|
|
13317
|
-
),
|
|
13340
|
+
), Ut = (v) => [...r(v)].sort($a), Qn = (v) => (v.sessions || []).some((w) => r(w).length > 0), dn = /* @__PURE__ */ new WeakMap(), Ui = (v) => {
|
|
13318
13341
|
const w = dn.get(v), R = l(v);
|
|
13319
13342
|
if (w && w.src === R)
|
|
13320
13343
|
return w.list;
|
|
@@ -13323,35 +13346,35 @@ const S0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
13323
13346
|
}, ci = (v) => [
|
|
13324
13347
|
...n.value ? (v.sessions || []).map((w) => ({ kind: "session", item: w })) : [],
|
|
13325
13348
|
...Ui(v).map((w) => ({ kind: "slot", item: w }))
|
|
13326
|
-
], Po = (v) => n.value ? (v.sessions || []).map((w) => ({ kind: "session", item: w })) : [],
|
|
13349
|
+
], Po = (v) => n.value ? (v.sessions || []).map((w) => ({ kind: "session", item: w })) : [], Ze = D(() => {
|
|
13327
13350
|
var w, R;
|
|
13328
13351
|
const v = (((w = oe.value) == null ? void 0 : w.schedules) || []).flatMap((q) => ci(q));
|
|
13329
13352
|
for (const q of ((R = oe.value) == null ? void 0 : R.schedules) || [])
|
|
13330
13353
|
for (const ee of q.sessions || [])
|
|
13331
|
-
v.push(...
|
|
13354
|
+
v.push(...Ut(ee).map((fe) => ({ kind: "slot", item: fe })));
|
|
13332
13355
|
return Id(v);
|
|
13333
13356
|
}), Ro = D(() => {
|
|
13334
13357
|
const v = [];
|
|
13335
|
-
for (let w =
|
|
13358
|
+
for (let w = Ze.value.start; w <= Ze.value.end; w += 60)
|
|
13336
13359
|
v.push({ min: w, label: It(w) });
|
|
13337
13360
|
return v;
|
|
13338
13361
|
}), Io = D(() => {
|
|
13339
13362
|
const v = [];
|
|
13340
|
-
for (let w =
|
|
13363
|
+
for (let w = Ze.value.start + 30; w < Ze.value.end; w += 60)
|
|
13341
13364
|
v.push({ min: w, label: It(w) });
|
|
13342
13365
|
return v;
|
|
13343
|
-
}), ws = (v) => Md(v,
|
|
13366
|
+
}), ws = (v) => Md(v, Ze.value), Bi = D(() => {
|
|
13344
13367
|
if (!I.value || !$.value)
|
|
13345
13368
|
return {};
|
|
13346
|
-
const v =
|
|
13369
|
+
const v = Ze.value, w = (I.value.minutes - v.start) / v.total * 100, R = Math.max($.value.duration / v.total * 100, 2.5);
|
|
13347
13370
|
return { top: w + "%", height: R + "%" };
|
|
13348
13371
|
}), F = D(() => !I.value || !$.value ? "" : It(I.value.minutes + $.value.duration)), _ = D(() => {
|
|
13349
13372
|
if (!I.value)
|
|
13350
13373
|
return {};
|
|
13351
|
-
const v =
|
|
13374
|
+
const v = Ze.value, w = (I.value.minutes - v.start) / v.total * 100, R = Math.max(yt.value / v.total * 100, 1.5);
|
|
13352
13375
|
return { top: w + "%", height: R + "%" };
|
|
13353
13376
|
}), H = D(() => {
|
|
13354
|
-
var ee, fe,
|
|
13377
|
+
var ee, fe, ze, tt, ct;
|
|
13355
13378
|
if (!I.value || !$.value || !$.value.id)
|
|
13356
13379
|
return 0;
|
|
13357
13380
|
const v = fi(I.value.scheduleId);
|
|
@@ -13360,13 +13383,13 @@ const S0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
13360
13383
|
const w = { startTime: I.value.time, endTime: F.value }, R = (ee = I.value.session) == null ? void 0 : ee.id;
|
|
13361
13384
|
let q = 0;
|
|
13362
13385
|
for (const W of ci(v))
|
|
13363
|
-
W.item.id !== ((fe = $.value) == null ? void 0 : fe.id) && (((
|
|
13364
|
-
if (((
|
|
13365
|
-
for (const W of
|
|
13386
|
+
W.item.id !== ((fe = $.value) == null ? void 0 : fe.id) && (((ze = $.value) == null ? void 0 : ze.kind) === "slot" && W.kind === "session" && W.item.id === R || Wi(w, W.item) && q++);
|
|
13387
|
+
if (((tt = $.value) == null ? void 0 : tt.kind) === "slot" && I.value.session)
|
|
13388
|
+
for (const W of Ut(I.value.session))
|
|
13366
13389
|
W.id !== ((ct = $.value) == null ? void 0 : ct.id) && Wi(w, W) && q++;
|
|
13367
13390
|
return q;
|
|
13368
|
-
}), ne = D(() => H.value > 0), pe = (v, w) => Ed(ci(v), w, Wi), ot = (v, w) => Fd(
|
|
13369
|
-
const w =
|
|
13391
|
+
}), ne = D(() => H.value > 0), pe = (v, w) => Ed(ci(v), w, Wi), ot = (v, w) => Fd(Ut(v), w, Wi), et = (v, w) => Ad(v, w), $e = (v) => {
|
|
13392
|
+
const w = Ze.value, R = Ve(v.item.startTime), q = Ve(v.item.endTime);
|
|
13370
13393
|
return !isFinite(R) || !isFinite(q) ? 48 : (q - R) / w.total * un.value;
|
|
13371
13394
|
}, ie = (v) => Dd($e(v)), ae = (v) => {
|
|
13372
13395
|
const w = e.slotName ? e.slotName(v.item) : v.item.name || (v.kind === "session" ? o.value.session : o.value.slot);
|
|
@@ -13410,7 +13433,7 @@ const S0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
13410
13433
|
};
|
|
13411
13434
|
}, je = O(null), St = (v, w) => {
|
|
13412
13435
|
const R = v.getBoundingClientRect(), q = Math.min(Math.max((w - R.top) / R.height, 0), 1);
|
|
13413
|
-
return
|
|
13436
|
+
return Ze.value.start + Yi(q * Ze.value.total, yt.value);
|
|
13414
13437
|
}, Ss = (v, w) => {
|
|
13415
13438
|
w.target.closest(".block-actions, .block-resize") || w.button !== 0 || Q.value || (je.value = { gi: v, startX: w.clientX, startY: w.clientY, moved: !1 }, window.addEventListener("pointermove", Cs), window.addEventListener("pointerup", ir), window.addEventListener("pointercancel", Eo), window.addEventListener("keydown", or));
|
|
13416
13439
|
}, Cs = (v) => {
|
|
@@ -13431,7 +13454,7 @@ const S0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
13431
13454
|
Mo(v.clientX, v.clientY), sc(v.clientX, v.clientY);
|
|
13432
13455
|
}
|
|
13433
13456
|
}, Mo = (v, w) => {
|
|
13434
|
-
var
|
|
13457
|
+
var tt, ct;
|
|
13435
13458
|
const R = document.elementFromPoint(v, w), q = R == null ? void 0 : R.closest(".hall-col"), ee = q == null ? void 0 : q.getAttribute("data-schedule-id");
|
|
13436
13459
|
if (!q || !ee) {
|
|
13437
13460
|
B.value = void 0, I.value = null;
|
|
@@ -13441,19 +13464,19 @@ const S0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
13441
13464
|
if (!fe)
|
|
13442
13465
|
return;
|
|
13443
13466
|
B.value = fe.id;
|
|
13444
|
-
const
|
|
13467
|
+
const ze = St(q, w);
|
|
13445
13468
|
I.value = {
|
|
13446
13469
|
scheduleId: fe.id,
|
|
13447
|
-
minutes:
|
|
13448
|
-
time: It(
|
|
13449
|
-
hallName:
|
|
13470
|
+
minutes: ze,
|
|
13471
|
+
time: It(ze),
|
|
13472
|
+
hallName: pt(fe),
|
|
13450
13473
|
// слот, целиком попадающий в секцию, будет вложен в неё при броске
|
|
13451
|
-
...((
|
|
13474
|
+
...((tt = $.value) == null ? void 0 : tt.kind) === "slot" && n.value ? {
|
|
13452
13475
|
session: xs(
|
|
13453
13476
|
fe.sessions,
|
|
13454
|
-
|
|
13455
|
-
|
|
13456
|
-
|
|
13477
|
+
ze,
|
|
13478
|
+
ze + (((ct = $.value) == null ? void 0 : ct.duration) || 30),
|
|
13479
|
+
Ve
|
|
13457
13480
|
)
|
|
13458
13481
|
} : {}
|
|
13459
13482
|
}, L.value = { x: v, y: w };
|
|
@@ -13472,8 +13495,8 @@ const S0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
13472
13495
|
xe.value = Date.now();
|
|
13473
13496
|
const R = document.elementFromPoint(v.clientX, v.clientY), q = R == null ? void 0 : R.closest(".hall-col"), ee = q == null ? void 0 : q.getAttribute("data-schedule-id"), fe = ee ? fi(ee) : void 0;
|
|
13474
13497
|
if (q && fe) {
|
|
13475
|
-
const
|
|
13476
|
-
await ur(fe,
|
|
13498
|
+
const ze = St(q, v.clientY);
|
|
13499
|
+
await ur(fe, ze);
|
|
13477
13500
|
}
|
|
13478
13501
|
sr();
|
|
13479
13502
|
}, Ao = () => {
|
|
@@ -13506,26 +13529,26 @@ const S0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
13506
13529
|
return ks((v = $.value) == null ? void 0 : v.id);
|
|
13507
13530
|
}, rc = (v, w) => {
|
|
13508
13531
|
w.preventDefault(), w.stopPropagation();
|
|
13509
|
-
const R = v.item, q =
|
|
13532
|
+
const R = v.item, q = Ve(R.startTime), ee = Ve(R.endTime);
|
|
13510
13533
|
if (!isFinite(q) || !isFinite(ee))
|
|
13511
13534
|
return;
|
|
13512
13535
|
const fe = w.clientY;
|
|
13513
13536
|
Q.value = !0;
|
|
13514
|
-
const
|
|
13515
|
-
const ce = (W.clientY - fe) /
|
|
13537
|
+
const ze = (W) => {
|
|
13538
|
+
const ce = (W.clientY - fe) / Vt.value * 60, ye = Yi(ee + ce, yt.value);
|
|
13516
13539
|
R.endTime = It(Math.max(ye, q + yt.value));
|
|
13517
|
-
},
|
|
13518
|
-
window.removeEventListener("pointermove",
|
|
13540
|
+
}, tt = async () => {
|
|
13541
|
+
window.removeEventListener("pointermove", ze), window.removeEventListener("pointerup", ct), Q.value = !1, xe.value = Date.now();
|
|
13519
13542
|
const W = ks(R.id);
|
|
13520
13543
|
W && (await Fn(R, W.kind), await e.persist.refresh());
|
|
13521
13544
|
}, ct = () => {
|
|
13522
|
-
|
|
13545
|
+
tt();
|
|
13523
13546
|
};
|
|
13524
|
-
window.addEventListener("pointermove",
|
|
13547
|
+
window.addEventListener("pointermove", ze), window.addEventListener("pointerup", ct);
|
|
13525
13548
|
}, cn = O(null), lc = (v, w, R) => {
|
|
13526
13549
|
if (R.target.closest(".nested-edit, .nested-resize") || R.button !== 0 || Q.value)
|
|
13527
13550
|
return;
|
|
13528
|
-
const q = R.target.closest(".session-perfoms"), ee =
|
|
13551
|
+
const q = R.target.closest(".session-perfoms"), ee = Ve(v.startTime), fe = Ve(v.endTime), ze = vi(w.startTime, w.endTime);
|
|
13529
13552
|
!q || !isFinite(ee) || !isFinite(fe) || fe <= ee || (cn.value = {
|
|
13530
13553
|
perfom: w,
|
|
13531
13554
|
session: v,
|
|
@@ -13536,7 +13559,7 @@ const S0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
13536
13559
|
savedEnd: w.endTime,
|
|
13537
13560
|
sessionStart: ee,
|
|
13538
13561
|
sessionDur: fe - ee,
|
|
13539
|
-
durMin: isFinite(
|
|
13562
|
+
durMin: isFinite(ze) && ze > 0 ? ze : 30,
|
|
13540
13563
|
container: q
|
|
13541
13564
|
}, window.addEventListener("pointermove", ar), window.addEventListener("pointerup", rr), window.addEventListener("pointercancel", Fo), window.addEventListener("keydown", lr));
|
|
13542
13565
|
}, ar = (v) => {
|
|
@@ -13555,7 +13578,7 @@ const S0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
13555
13578
|
}, rr = (v) => {
|
|
13556
13579
|
uc(v);
|
|
13557
13580
|
}, uc = async (v) => {
|
|
13558
|
-
var
|
|
13581
|
+
var ze;
|
|
13559
13582
|
const w = cn.value;
|
|
13560
13583
|
if (Oo(), cn.value = null, L.value = null, document.body.style.userSelect = "", document.body.style.cursor = "", !w || !w.moved)
|
|
13561
13584
|
return;
|
|
@@ -13568,8 +13591,8 @@ const S0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
13568
13591
|
name: w.perfom.name || o.value.slot,
|
|
13569
13592
|
duration: w.durMin
|
|
13570
13593
|
};
|
|
13571
|
-
const
|
|
13572
|
-
await ur(fe,
|
|
13594
|
+
const tt = St(q, v.clientY), ct = It(tt), W = vi(w.perfom.startTime, w.perfom.endTime), ce = tn(ct, W > 0 ? W : 30), ye = ((ze = fr(w.perfom)) == null ? void 0 : ze.id) === fe.id && w.perfom.startTime === ct && w.perfom.endTime === ce;
|
|
13595
|
+
await ur(fe, tt), ye && (await e.persist.updateSlot(w.perfom), await e.persist.refresh()), $.value = null;
|
|
13573
13596
|
return;
|
|
13574
13597
|
}
|
|
13575
13598
|
w.perfom.startTime = Zn(w.perfom.startTime), w.perfom.endTime = Zn(w.perfom.endTime), w.perfom.startTime && (await e.persist.updateSlot(w.perfom), await e.persist.refresh());
|
|
@@ -13582,10 +13605,10 @@ const S0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
13582
13605
|
v.key === "Escape" && Fo();
|
|
13583
13606
|
}, dc = (v, w, R) => {
|
|
13584
13607
|
R.preventDefault(), R.stopPropagation();
|
|
13585
|
-
const q =
|
|
13586
|
-
if (!
|
|
13608
|
+
const q = Ve(v.startTime), ee = Ve(v.endTime), fe = Ve(w.startTime), ze = R.target.closest(".nested-perfom"), tt = ze == null ? void 0 : ze.closest(".session-perfoms");
|
|
13609
|
+
if (!ze || !tt || !isFinite(q) || !isFinite(ee) || ee <= q || !isFinite(fe))
|
|
13587
13610
|
return;
|
|
13588
|
-
const ct =
|
|
13611
|
+
const ct = tt.getBoundingClientRect(), W = ee - q;
|
|
13589
13612
|
Q.value = !0;
|
|
13590
13613
|
const ce = (kn) => {
|
|
13591
13614
|
const kc = Math.min(Math.max((kn.clientY - ct.top) / ct.height, 0), 1), xc = Math.min(
|
|
@@ -13608,20 +13631,20 @@ const S0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
13608
13631
|
const q = It(w), ee = vi(R.item.startTime, R.item.endTime), fe = tn(q, ee > 0 ? ee : 30);
|
|
13609
13632
|
if (((ce = R.schedule) == null ? void 0 : ce.id) === v.id && R.item.startTime === q && R.item.endTime === fe)
|
|
13610
13633
|
return;
|
|
13611
|
-
const
|
|
13634
|
+
const ze = R.item.startTime;
|
|
13612
13635
|
if (R.item.startTime = q, R.item.endTime = fe, R.kind === "slot" && n.value) {
|
|
13613
|
-
const ye = xs(v.sessions,
|
|
13636
|
+
const ye = xs(v.sessions, Ve(q), Ve(fe), Ve);
|
|
13614
13637
|
ye ? R.item.sessionId = ye.id : delete R.item.sessionId;
|
|
13615
13638
|
} else R.kind === "slot" && delete R.item.sessionId;
|
|
13616
13639
|
if (R.kind === "session") {
|
|
13617
|
-
const ye =
|
|
13618
|
-
for (const he of
|
|
13640
|
+
const ye = Ve(q) - Ve(ze);
|
|
13641
|
+
for (const he of Ut(R.item))
|
|
13619
13642
|
he.startTime && (he.startTime = tn(he.startTime, ye), he.endTime && (he.endTime = tn(he.endTime, ye)), he.scheduleId = v.id, await Fn(he, "slot"));
|
|
13620
13643
|
}
|
|
13621
|
-
const
|
|
13622
|
-
if (
|
|
13644
|
+
const tt = R.schedule, ct = R.kind === "session" ? v.sessions : l(v), W = R.item;
|
|
13645
|
+
if (tt && tt.id !== v.id) {
|
|
13623
13646
|
W.scheduleId = v.id;
|
|
13624
|
-
const ye = R.kind === "session" ?
|
|
13647
|
+
const ye = R.kind === "session" ? tt.sessions : l(tt);
|
|
13625
13648
|
Y.H.Classes.RemoveFromClassById(W.id, ye, []), ct.push(W);
|
|
13626
13649
|
}
|
|
13627
13650
|
await Fn(W, R.kind), await e.persist.refresh();
|
|
@@ -13630,7 +13653,7 @@ const S0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
13630
13653
|
return;
|
|
13631
13654
|
const R = St(w.currentTarget, w.clientY), q = a.value.createSlot(v);
|
|
13632
13655
|
if (q.startTime = It(R), q.endTime = It(R + 30), n.value) {
|
|
13633
|
-
const fe = xs(v.sessions, R, R + 30,
|
|
13656
|
+
const fe = xs(v.sessions, R, R + 30, Ve);
|
|
13634
13657
|
fe != null && fe.id && (q.sessionId = fe.id);
|
|
13635
13658
|
}
|
|
13636
13659
|
await e.persist.createSlot(q), await e.persist.refresh();
|
|
@@ -13684,7 +13707,7 @@ const S0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
13684
13707
|
}, hc = async (v, w) => {
|
|
13685
13708
|
const R = a.value.createSlot(v);
|
|
13686
13709
|
if (R.startTime = It(w), R.endTime = tn(R.startTime, 30), n.value) {
|
|
13687
|
-
const ee = xs(v.sessions, w, w + 30,
|
|
13710
|
+
const ee = xs(v.sessions, w, w + 30, Ve);
|
|
13688
13711
|
ee != null && ee.id && (R.sessionId = ee.id);
|
|
13689
13712
|
}
|
|
13690
13713
|
await e.persist.createSlot(R), await e.persist.refresh();
|
|
@@ -13807,10 +13830,10 @@ const S0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
13807
13830
|
v[w] = R, Fn(v, q);
|
|
13808
13831
|
};
|
|
13809
13832
|
return e.persist.loadOptions && e.persist.loadOptions(), (v, w) => {
|
|
13810
|
-
var
|
|
13811
|
-
const R = Me("PButton"), q = Me("PTooltip"), ee = Me("PSelect"), fe = Me("PInput"),
|
|
13833
|
+
var tt, ct;
|
|
13834
|
+
const R = Me("PButton"), q = Me("PTooltip"), ee = Me("PSelect"), fe = Me("PInput"), ze = Me("PDialog");
|
|
13812
13835
|
return m(), S("div", P0, [
|
|
13813
|
-
(
|
|
13836
|
+
(tt = t.days) != null && tt.length ? (m(), S(K, { key: 1 }, [
|
|
13814
13837
|
y("div", I0, [
|
|
13815
13838
|
i.value ? (m(), S("div", M0, [
|
|
13816
13839
|
g(f(wl), {
|
|
@@ -13821,7 +13844,7 @@ const S0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
13821
13844
|
"active-color": "primary"
|
|
13822
13845
|
}, {
|
|
13823
13846
|
default: C(() => [
|
|
13824
|
-
(m(!0), S(K, null, we(
|
|
13847
|
+
(m(!0), S(K, null, we(Ue.value, (W) => (m(), z(f(Sl), {
|
|
13825
13848
|
key: W.id,
|
|
13826
13849
|
name: W.id,
|
|
13827
13850
|
class: "day-tab"
|
|
@@ -13896,7 +13919,7 @@ const S0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
13896
13919
|
g(ee, {
|
|
13897
13920
|
modelValue: lt.value,
|
|
13898
13921
|
"onUpdate:modelValue": w[2] || (w[2] = (W) => lt.value = W),
|
|
13899
|
-
options:
|
|
13922
|
+
options: Ke,
|
|
13900
13923
|
clearable: !1,
|
|
13901
13924
|
size: "sm",
|
|
13902
13925
|
dense: "",
|
|
@@ -13919,9 +13942,9 @@ const S0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
13919
13942
|
class: "text-grey-6"
|
|
13920
13943
|
}),
|
|
13921
13944
|
g(ee, {
|
|
13922
|
-
modelValue:
|
|
13923
|
-
"onUpdate:modelValue": w[3] || (w[3] = (W) =>
|
|
13924
|
-
options:
|
|
13945
|
+
modelValue: Vt.value,
|
|
13946
|
+
"onUpdate:modelValue": w[3] || (w[3] = (W) => Vt.value = W),
|
|
13947
|
+
options: mt,
|
|
13925
13948
|
clearable: !1,
|
|
13926
13949
|
size: "sm",
|
|
13927
13950
|
dense: "",
|
|
@@ -13942,7 +13965,7 @@ const S0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
13942
13965
|
g(ee, {
|
|
13943
13966
|
modelValue: b.value,
|
|
13944
13967
|
"onUpdate:modelValue": w[4] || (w[4] = (W) => b.value = W),
|
|
13945
|
-
options:
|
|
13968
|
+
options: Xe.value,
|
|
13946
13969
|
clearable: !1,
|
|
13947
13970
|
size: "sm",
|
|
13948
13971
|
dense: "",
|
|
@@ -13971,8 +13994,8 @@ const S0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
13971
13994
|
class: "grid-wrap",
|
|
13972
13995
|
style: J({
|
|
13973
13996
|
"--halls": Oe(oe.value).length,
|
|
13974
|
-
"--hours": Math.max(
|
|
13975
|
-
"--half-hours": Math.max(
|
|
13997
|
+
"--hours": Math.max(Ze.value.total / 60, 1),
|
|
13998
|
+
"--half-hours": Math.max(Ze.value.total / 60 * 2, 2)
|
|
13976
13999
|
})
|
|
13977
14000
|
}, [
|
|
13978
14001
|
y("div", D0, [
|
|
@@ -13986,7 +14009,7 @@ const S0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
13986
14009
|
name: "meeting_room",
|
|
13987
14010
|
size: "15px"
|
|
13988
14011
|
}),
|
|
13989
|
-
y("span", L0, U(
|
|
14012
|
+
y("span", L0, U(pt(W)), 1),
|
|
13990
14013
|
g(R, {
|
|
13991
14014
|
size: "sm",
|
|
13992
14015
|
flat: "",
|
|
@@ -14054,12 +14077,12 @@ const S0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
14054
14077
|
(m(!0), S(K, null, we(Ro.value, (W) => (m(), S("div", {
|
|
14055
14078
|
key: W.min,
|
|
14056
14079
|
class: "hour-label",
|
|
14057
|
-
style: J({ top: (W.min -
|
|
14080
|
+
style: J({ top: (W.min - Ze.value.start) / Ze.value.total * 100 + "%" })
|
|
14058
14081
|
}, U(W.label), 5))), 128)),
|
|
14059
14082
|
(m(!0), S(K, null, we(Io.value, (W) => (m(), S("div", {
|
|
14060
14083
|
key: W.min,
|
|
14061
14084
|
class: "half-label",
|
|
14062
|
-
style: J({ top: (W.min -
|
|
14085
|
+
style: J({ top: (W.min - Ze.value.start) / Ze.value.total * 100 + "%" })
|
|
14063
14086
|
}, U(W.label), 5))), 128))
|
|
14064
14087
|
]),
|
|
14065
14088
|
(m(!0), S(K, null, we(Oe(oe.value), (W) => (m(), S("div", {
|
|
@@ -14093,11 +14116,11 @@ const S0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
14093
14116
|
y("div", N0, U(ae(ce)), 1),
|
|
14094
14117
|
ce.kind === "slot" && p(ce.item) ? (m(), S("div", H0, U(p(ce.item)), 1)) : G("", !0)
|
|
14095
14118
|
]),
|
|
14096
|
-
ce.kind === "session" &&
|
|
14097
|
-
(m(!0), S(K, null, we(
|
|
14119
|
+
ce.kind === "session" && Ut(ce.item).length ? (m(), S("div", j0, [
|
|
14120
|
+
(m(!0), S(K, null, we(Ut(ce.item), (he) => (m(), S("div", {
|
|
14098
14121
|
key: he.id,
|
|
14099
14122
|
class: ve(["nested-perfom", He(ce, he)]),
|
|
14100
|
-
style: J(
|
|
14123
|
+
style: J(et(ce.item, he)),
|
|
14101
14124
|
title: Te(he),
|
|
14102
14125
|
onPointerdown: Ye((kn) => lc(ce.item, he, kn), ["stop"]),
|
|
14103
14126
|
onClick: Ye((kn) => On({ kind: "slot", item: he }), ["stop"]),
|
|
@@ -14258,7 +14281,7 @@ const S0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
14258
14281
|
size: "18px",
|
|
14259
14282
|
color: "primary"
|
|
14260
14283
|
}),
|
|
14261
|
-
y("span", lb, U(
|
|
14284
|
+
y("span", lb, U(pt(W)), 1),
|
|
14262
14285
|
g(f(_n)),
|
|
14263
14286
|
g(R, {
|
|
14264
14287
|
size: "sm",
|
|
@@ -14361,8 +14384,8 @@ const S0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
14361
14384
|
onClick: (he) => qi(ye, "session")
|
|
14362
14385
|
}, null, 8, ["onClick"])
|
|
14363
14386
|
]),
|
|
14364
|
-
|
|
14365
|
-
(m(!0), S(K, null, we(
|
|
14387
|
+
Ut(ye).length ? (m(), S("div", fb, [
|
|
14388
|
+
(m(!0), S(K, null, we(Ut(ye), (he) => (m(), S("div", {
|
|
14366
14389
|
key: he.id,
|
|
14367
14390
|
class: "list-row nested-row"
|
|
14368
14391
|
}, [
|
|
@@ -14487,7 +14510,7 @@ const S0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
14487
14510
|
onClick: me
|
|
14488
14511
|
}, null, 8, ["label"])
|
|
14489
14512
|
])),
|
|
14490
|
-
g(
|
|
14513
|
+
g(ze, {
|
|
14491
14514
|
modelValue: P.value,
|
|
14492
14515
|
"onUpdate:modelValue": w[7] || (w[7] = (W) => P.value = W)
|
|
14493
14516
|
}, {
|
|
@@ -14565,7 +14588,7 @@ const S0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
14565
14588
|
]),
|
|
14566
14589
|
_: 3
|
|
14567
14590
|
}, 8, ["modelValue"]),
|
|
14568
|
-
g(
|
|
14591
|
+
g(ze, {
|
|
14569
14592
|
modelValue: M.value,
|
|
14570
14593
|
"onUpdate:modelValue": w[9] || (w[9] = (W) => M.value = W)
|
|
14571
14594
|
}, {
|
|
@@ -14606,7 +14629,7 @@ const S0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
14606
14629
|
]),
|
|
14607
14630
|
_: 1
|
|
14608
14631
|
}, 8, ["modelValue"]),
|
|
14609
|
-
g(
|
|
14632
|
+
g(ze, {
|
|
14610
14633
|
modelValue: T.value,
|
|
14611
14634
|
"onUpdate:modelValue": w[16] || (w[16] = (W) => T.value = W)
|
|
14612
14635
|
}, {
|
|
@@ -14965,7 +14988,7 @@ const S0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
14965
14988
|
nestedSlotStyle: Ad,
|
|
14966
14989
|
normTime: Zn,
|
|
14967
14990
|
snapMinutes: Yi,
|
|
14968
|
-
toMin:
|
|
14991
|
+
toMin: Ve
|
|
14969
14992
|
}, Symbol.toStringTag, { value: "Module" }));
|
|
14970
14993
|
let mw = class extends st {
|
|
14971
14994
|
constructor() {
|
|
@@ -15085,7 +15108,7 @@ const kw = new Cw(), xw = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.d
|
|
|
15085
15108
|
default: C(() => [
|
|
15086
15109
|
g(f(Ei), { dense: "" }, {
|
|
15087
15110
|
default: C(() => [
|
|
15088
|
-
(m(!0), S(K, null, we(f(o), (h) =>
|
|
15111
|
+
(m(!0), S(K, null, we(f(o), (h) => Je((m(), z(f(Bn), {
|
|
15089
15112
|
key: h.value,
|
|
15090
15113
|
clickable: "",
|
|
15091
15114
|
class: "tag-item",
|
|
@@ -15182,7 +15205,7 @@ const kw = new Cw(), xw = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.d
|
|
|
15182
15205
|
}, [
|
|
15183
15206
|
y("div", Fw, [
|
|
15184
15207
|
y("div", Ow, U(s.title), 1),
|
|
15185
|
-
|
|
15208
|
+
Je(g(ue, {
|
|
15186
15209
|
icon: "close",
|
|
15187
15210
|
flat: "",
|
|
15188
15211
|
dense: "",
|
|
@@ -15196,7 +15219,7 @@ const kw = new Cw(), xw = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.d
|
|
|
15196
15219
|
N(p.$slots, "default", {}, void 0, !0)
|
|
15197
15220
|
]),
|
|
15198
15221
|
s.showConfirm ? (m(), S("div", zw, [
|
|
15199
|
-
|
|
15222
|
+
Je(g(ue, {
|
|
15200
15223
|
flat: "",
|
|
15201
15224
|
label: s.cancelLabel,
|
|
15202
15225
|
size: "sm"
|
|
@@ -16322,7 +16345,7 @@ const S2 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
16322
16345
|
}
|
|
16323
16346
|
}), k2 = { class: "row items-center justify-end" }, x2 = { class: "row items-center justify-end" }, $2 = /* @__PURE__ */ j({
|
|
16324
16347
|
__name: "PDateTimeInput",
|
|
16325
|
-
props: /* @__PURE__ */
|
|
16348
|
+
props: /* @__PURE__ */ De({
|
|
16326
16349
|
label: { type: String, default: "Дата и время" },
|
|
16327
16350
|
placeholder: { type: String, default: "ДД.ММ.ГГГГ ЧЧ:мм" },
|
|
16328
16351
|
disable: { type: Boolean, default: !1 },
|
|
@@ -16337,7 +16360,7 @@ const S2 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
16337
16360
|
}),
|
|
16338
16361
|
emits: ["update:modelValue"],
|
|
16339
16362
|
setup(t) {
|
|
16340
|
-
const e = Wn, n =
|
|
16363
|
+
const e = Wn, n = vt(t, "modelValue"), i = O(""), s = O(""), o = O(""), a = (k) => k ? Jn.formatDate(k, "DD.MM.YYYY HH:mm") : "", l = (k) => {
|
|
16341
16364
|
if (!k || !/^\d{2}\.\d{2}\.\d{4} \d{2}:\d{2}$/.test(k)) return null;
|
|
16342
16365
|
const P = Jn.extractDate(k, "DD.MM.YYYY HH:mm");
|
|
16343
16366
|
return Number.isNaN(P.getTime()) ? null : P;
|
|
@@ -16410,7 +16433,7 @@ const S2 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
16410
16433
|
}, {
|
|
16411
16434
|
default: C(() => [
|
|
16412
16435
|
y("div", k2, [
|
|
16413
|
-
|
|
16436
|
+
Je(g(ue, {
|
|
16414
16437
|
label: "OK",
|
|
16415
16438
|
color: "primary",
|
|
16416
16439
|
flat: "",
|
|
@@ -16446,7 +16469,7 @@ const S2 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
16446
16469
|
}, {
|
|
16447
16470
|
default: C(() => [
|
|
16448
16471
|
y("div", x2, [
|
|
16449
|
-
|
|
16472
|
+
Je(g(ue, {
|
|
16450
16473
|
label: "OK",
|
|
16451
16474
|
color: "primary",
|
|
16452
16475
|
flat: "",
|
|
@@ -16506,7 +16529,7 @@ const S2 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
16506
16529
|
}, I2 = /* @__PURE__ */ j({
|
|
16507
16530
|
name: "PForm",
|
|
16508
16531
|
__name: "PForm",
|
|
16509
|
-
props: /* @__PURE__ */
|
|
16532
|
+
props: /* @__PURE__ */ De({
|
|
16510
16533
|
greedy: { type: Boolean, default: !1 },
|
|
16511
16534
|
autofocus: { type: Boolean, default: !1 },
|
|
16512
16535
|
noErrorFocus: { type: Boolean, default: !1 },
|
|
@@ -16515,9 +16538,9 @@ const S2 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
16515
16538
|
valid: { type: Boolean, default: void 0 },
|
|
16516
16539
|
validModifiers: {}
|
|
16517
16540
|
}),
|
|
16518
|
-
emits: /* @__PURE__ */
|
|
16541
|
+
emits: /* @__PURE__ */ De(["submit", "reset", "validation-success", "validation-error"], ["update:valid"]),
|
|
16519
16542
|
setup(t, { expose: e, emit: n }) {
|
|
16520
|
-
const i = n, s =
|
|
16543
|
+
const i = n, s = vt(t, "valid"), o = O(!0), a = (T) => {
|
|
16521
16544
|
o.value = T, s.value !== void 0 && (s.value = T);
|
|
16522
16545
|
}, l = O(), r = () => {
|
|
16523
16546
|
a(!0), i("validation-success");
|
|
@@ -17299,7 +17322,7 @@ const cS = { class: "admin-gallery" }, fS = { class: "groups" }, hS = ["src", "a
|
|
|
17299
17322
|
class: "viewer-caption"
|
|
17300
17323
|
}, kS = /* @__PURE__ */ j({
|
|
17301
17324
|
__name: "AdminGallery",
|
|
17302
|
-
props: /* @__PURE__ */
|
|
17325
|
+
props: /* @__PURE__ */ De({
|
|
17303
17326
|
id: { default: "" },
|
|
17304
17327
|
type: { default: "" },
|
|
17305
17328
|
ratio: { default: 0 },
|
|
@@ -17310,9 +17333,9 @@ const cS = { class: "admin-gallery" }, fS = { class: "groups" }, hS = ["src", "a
|
|
|
17310
17333
|
images: { default: () => [] },
|
|
17311
17334
|
imagesModifiers: {}
|
|
17312
17335
|
}),
|
|
17313
|
-
emits: /* @__PURE__ */
|
|
17336
|
+
emits: /* @__PURE__ */ De(["addImage", "remove", "sort"], ["update:images"]),
|
|
17314
17337
|
setup(t, { emit: e }) {
|
|
17315
|
-
const n = Wn, i = t, s =
|
|
17338
|
+
const n = Wn, i = t, s = vt(t, "images"), o = e, a = D(() => f(s) ?? []), l = O(), r = O(!1), d = O(!1), c = O(0), h = O(!1), p = O(""), b = O(i.ratio), k = D(
|
|
17316
17339
|
() => b.value > 0 ? { aspectRatio: String(b.value) } : {}
|
|
17317
17340
|
), P = O(), E = O(), T = (Z) => typeof Z.getFileUrl == "function" ? Z.getFileUrl() : "", M = ht(/* @__PURE__ */ new Set()), x = (Z) => {
|
|
17318
17341
|
Z.id && M.add(Z.id);
|
|
@@ -17325,8 +17348,8 @@ const cS = { class: "admin-gallery" }, fS = { class: "groups" }, hS = ["src", "a
|
|
|
17325
17348
|
return !0;
|
|
17326
17349
|
const Fe = Z.type.toLowerCase(), me = Z.name.toLowerCase();
|
|
17327
17350
|
return te.split(",").some((Oe) => {
|
|
17328
|
-
const
|
|
17329
|
-
return
|
|
17351
|
+
const pt = Oe.trim().toLowerCase();
|
|
17352
|
+
return pt ? pt.startsWith(".") ? me.endsWith(pt) : pt.endsWith("/*") ? Fe.startsWith(pt.slice(0, -1)) : Fe === pt : !1;
|
|
17330
17353
|
});
|
|
17331
17354
|
}, L = O(!1);
|
|
17332
17355
|
let Q = 0;
|
|
@@ -17335,11 +17358,11 @@ const cS = { class: "admin-gallery" }, fS = { class: "groups" }, hS = ["src", "a
|
|
|
17335
17358
|
return Array.from(((te = Z.dataTransfer) == null ? void 0 : te.types) ?? []).includes("Files");
|
|
17336
17359
|
}, ke = (Z) => {
|
|
17337
17360
|
!i.upload || !xe(Z) || (Q += 1, L.value = !0);
|
|
17338
|
-
},
|
|
17361
|
+
}, Ke = (Z) => {
|
|
17339
17362
|
!i.upload || !xe(Z) || Z.dataTransfer && (Z.dataTransfer.dropEffect = "copy");
|
|
17340
|
-
},
|
|
17363
|
+
}, mt = (Z) => {
|
|
17341
17364
|
!i.upload || !xe(Z) || (Q = Math.max(0, Q - 1), Q === 0 && (L.value = !1));
|
|
17342
|
-
},
|
|
17365
|
+
}, Xe = (Z) => {
|
|
17343
17366
|
var Fe, me;
|
|
17344
17367
|
if (Q = 0, L.value = !1, !i.upload)
|
|
17345
17368
|
return;
|
|
@@ -17361,8 +17384,8 @@ const cS = { class: "admin-gallery" }, fS = { class: "groups" }, hS = ["src", "a
|
|
|
17361
17384
|
return;
|
|
17362
17385
|
}
|
|
17363
17386
|
const te = new Nt();
|
|
17364
|
-
te.id =
|
|
17365
|
-
},
|
|
17387
|
+
te.id = Lt.UUID(), te.itemId = $(), te.type = i.type, te.originalName = Z.name, te.file = Z, te.src = URL.createObjectURL(Z), E.value = te, P.value = void 0, p.value = te.src, h.value = !0;
|
|
17388
|
+
}, Vt = async (Z) => {
|
|
17366
17389
|
var Fe;
|
|
17367
17390
|
const te = P.value;
|
|
17368
17391
|
if (te) {
|
|
@@ -17393,7 +17416,7 @@ const cS = { class: "admin-gallery" }, fS = { class: "groups" }, hS = ["src", "a
|
|
|
17393
17416
|
}
|
|
17394
17417
|
}, Dt = () => {
|
|
17395
17418
|
h.value = !1, E.value = void 0, P.value = void 0;
|
|
17396
|
-
},
|
|
17419
|
+
}, Ue = (Z) => {
|
|
17397
17420
|
const te = s.value.findIndex((Fe) => Fe.id === Z.id);
|
|
17398
17421
|
c.value = te > -1 ? te : 0, d.value = !0;
|
|
17399
17422
|
}, oe = (Z) => {
|
|
@@ -17424,9 +17447,9 @@ const cS = { class: "admin-gallery" }, fS = { class: "groups" }, hS = ["src", "a
|
|
|
17424
17447
|
y("div", {
|
|
17425
17448
|
class: ve(["dropzone", { "is-dragover": t.upload && f(L) }]),
|
|
17426
17449
|
onDragenter: Ye(ke, ["prevent"]),
|
|
17427
|
-
onDragover: Ye(
|
|
17428
|
-
onDragleave: Ye(
|
|
17429
|
-
onDrop: Ye(
|
|
17450
|
+
onDragover: Ye(Ke, ["prevent"]),
|
|
17451
|
+
onDragleave: Ye(mt, ["prevent"]),
|
|
17452
|
+
onDrop: Ye(Xe, ["prevent"])
|
|
17430
17453
|
}, [
|
|
17431
17454
|
y("div", fS, [
|
|
17432
17455
|
g(f(si), {
|
|
@@ -17450,11 +17473,11 @@ const cS = { class: "admin-gallery" }, fS = { class: "groups" }, hS = ["src", "a
|
|
|
17450
17473
|
alt: me.description,
|
|
17451
17474
|
loading: "lazy",
|
|
17452
17475
|
onError: (Oe) => x(me),
|
|
17453
|
-
onClick: (Oe) =>
|
|
17476
|
+
onClick: (Oe) => Ue(me)
|
|
17454
17477
|
}, null, 40, hS)) : (m(), S("div", {
|
|
17455
17478
|
key: 1,
|
|
17456
17479
|
class: "card-placeholder",
|
|
17457
|
-
onClick: (Oe) =>
|
|
17480
|
+
onClick: (Oe) => Ue(me)
|
|
17458
17481
|
}, [
|
|
17459
17482
|
g(f(re), {
|
|
17460
17483
|
name: "broken_image",
|
|
@@ -17559,7 +17582,7 @@ const cS = { class: "admin-gallery" }, fS = { class: "groups" }, hS = ["src", "a
|
|
|
17559
17582
|
g(f(kt), { class: "row items-center q-pb-none" }, {
|
|
17560
17583
|
default: C(() => [
|
|
17561
17584
|
g(f(_n)),
|
|
17562
|
-
|
|
17585
|
+
Je(g(ue, {
|
|
17563
17586
|
icon: "close",
|
|
17564
17587
|
flat: "",
|
|
17565
17588
|
round: "",
|
|
@@ -17578,7 +17601,7 @@ const cS = { class: "admin-gallery" }, fS = { class: "groups" }, hS = ["src", "a
|
|
|
17578
17601
|
key: 0,
|
|
17579
17602
|
src: f(p),
|
|
17580
17603
|
ratio: f(b),
|
|
17581
|
-
onCrop: te[0] || (te[0] = (me) => f(P) ?
|
|
17604
|
+
onCrop: te[0] || (te[0] = (me) => f(P) ? Vt(me) : un(me)),
|
|
17582
17605
|
"onUpdate:ratio": te[1] || (te[1] = (me) => b.value = me)
|
|
17583
17606
|
}, null, 8, ["src", "ratio"])) : G("", !0)
|
|
17584
17607
|
]),
|
|
@@ -19046,7 +19069,7 @@ const F8 = /* @__PURE__ */ X(I8, [["render", E8], ["__scopeId", "data-v-6fb8269e
|
|
|
19046
19069
|
}
|
|
19047
19070
|
}), j8 = /* @__PURE__ */ X(H8, [["__scopeId", "data-v-caedda9d"]]), G8 = { class: "select-dialog" }, W8 = { class: "select-dialog-header" }, Y8 = { class: "select-dialog-title" }, Q8 = { class: "select-dialog-content" }, X8 = { class: "select-dialog-actions" }, Z8 = /* @__PURE__ */ j({
|
|
19048
19071
|
__name: "PAddDialog",
|
|
19049
|
-
props: /* @__PURE__ */
|
|
19072
|
+
props: /* @__PURE__ */ De({
|
|
19050
19073
|
title: {
|
|
19051
19074
|
type: String,
|
|
19052
19075
|
default: ""
|
|
@@ -19059,9 +19082,9 @@ const F8 = /* @__PURE__ */ X(I8, [["render", E8], ["__scopeId", "data-v-6fb8269e
|
|
|
19059
19082
|
modelValue: { type: Boolean, default: !1 },
|
|
19060
19083
|
modelModifiers: {}
|
|
19061
19084
|
}),
|
|
19062
|
-
emits: /* @__PURE__ */
|
|
19085
|
+
emits: /* @__PURE__ */ De(["add", "close"], ["update:modelValue"]),
|
|
19063
19086
|
setup(t, { expose: e, emit: n }) {
|
|
19064
|
-
const i = t, s = n, o =
|
|
19087
|
+
const i = t, s = n, o = vt(t, "modelValue"), a = O([]), l = Hc, r = Wn, d = async () => {
|
|
19065
19088
|
await i.store.GetOptions(), a.value = i.store.Options;
|
|
19066
19089
|
}, c = async (E) => {
|
|
19067
19090
|
await i.store.Get(E.value);
|
|
@@ -19094,7 +19117,7 @@ const F8 = /* @__PURE__ */ X(I8, [["render", E8], ["__scopeId", "data-v-6fb8269e
|
|
|
19094
19117
|
y("div", G8, [
|
|
19095
19118
|
y("div", W8, [
|
|
19096
19119
|
y("div", Y8, U(t.title), 1),
|
|
19097
|
-
|
|
19120
|
+
Je(g(ue, {
|
|
19098
19121
|
icon: "close",
|
|
19099
19122
|
flat: "",
|
|
19100
19123
|
dense: "",
|
|
@@ -19110,7 +19133,7 @@ const F8 = /* @__PURE__ */ X(I8, [["render", E8], ["__scopeId", "data-v-6fb8269e
|
|
|
19110
19133
|
separator: ""
|
|
19111
19134
|
}, {
|
|
19112
19135
|
default: C(() => [
|
|
19113
|
-
(m(!0), S(K, null, we(f(a), (M) =>
|
|
19136
|
+
(m(!0), S(K, null, we(f(a), (M) => Je((m(), z(f(Bn), {
|
|
19114
19137
|
key: M.value,
|
|
19115
19138
|
clickable: "",
|
|
19116
19139
|
class: "q-px-md q-py-sm",
|
|
@@ -19138,7 +19161,7 @@ const F8 = /* @__PURE__ */ X(I8, [["render", E8], ["__scopeId", "data-v-6fb8269e
|
|
|
19138
19161
|
})
|
|
19139
19162
|
]),
|
|
19140
19163
|
y("div", X8, [
|
|
19141
|
-
|
|
19164
|
+
Je(g(ue, {
|
|
19142
19165
|
flat: "",
|
|
19143
19166
|
label: "Закрыть",
|
|
19144
19167
|
size: "sm",
|
|
@@ -19720,7 +19743,7 @@ const pC = { class: "btn-group" }, gC = /* @__PURE__ */ j({
|
|
|
19720
19743
|
},
|
|
19721
19744
|
emits: ["upload", "remove"],
|
|
19722
19745
|
setup(t, { emit: e }) {
|
|
19723
|
-
const n = t, i = e, s =
|
|
19746
|
+
const n = t, i = e, s = Lt.GUID(), o = Lt.GUID(), a = () => {
|
|
19724
19747
|
const d = document.getElementById(s);
|
|
19725
19748
|
if (!d.files)
|
|
19726
19749
|
return;
|