@deskhero/dh_ui 2.18.0 → 2.19.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/TextEditor.vue.d.ts +1 -1
- package/dist/dh_ui.es.js +707 -703
- package/dist/dh_ui.umd.js +18 -18
- package/package.json +1 -1
package/dist/dh_ui.es.js
CHANGED
|
@@ -5492,8 +5492,8 @@ function $u(i, e, t, n) {
|
|
|
5492
5492
|
if (Ve) {
|
|
5493
5493
|
var ve = Ve.incompatibleTokens;
|
|
5494
5494
|
if (Array.isArray(ve)) {
|
|
5495
|
-
var Xe = T.find(function(
|
|
5496
|
-
return ve.includes(
|
|
5495
|
+
var Xe = T.find(function(J) {
|
|
5496
|
+
return ve.includes(J.token) || J.token === xe;
|
|
5497
5497
|
});
|
|
5498
5498
|
if (Xe)
|
|
5499
5499
|
throw new RangeError("The format string mustn't contain `".concat(Xe.fullToken, "` and `").concat(ue, "` at the same time"));
|
|
@@ -5532,7 +5532,7 @@ function $u(i, e, t, n) {
|
|
|
5532
5532
|
}
|
|
5533
5533
|
if (A.length > 0 && W0.test(A))
|
|
5534
5534
|
return /* @__PURE__ */ new Date(NaN);
|
|
5535
|
-
var
|
|
5535
|
+
var W = L.map(function(le) {
|
|
5536
5536
|
return le.priority;
|
|
5537
5537
|
}).sort(function(le, ue) {
|
|
5538
5538
|
return ue - le;
|
|
@@ -5549,21 +5549,21 @@ function $u(i, e, t, n) {
|
|
|
5549
5549
|
}), U = je(t);
|
|
5550
5550
|
if (isNaN(U.getTime()))
|
|
5551
5551
|
return /* @__PURE__ */ new Date(NaN);
|
|
5552
|
-
var
|
|
5552
|
+
var V = gj(U, Sa(U)), P = {}, $ = td(W), ie;
|
|
5553
5553
|
try {
|
|
5554
|
-
for (
|
|
5555
|
-
var
|
|
5556
|
-
if (!
|
|
5554
|
+
for ($.s(); !(ie = $.n()).done; ) {
|
|
5555
|
+
var F = ie.value;
|
|
5556
|
+
if (!F.validate(V, f))
|
|
5557
5557
|
return /* @__PURE__ */ new Date(NaN);
|
|
5558
|
-
var ee =
|
|
5559
|
-
Array.isArray(ee) ? (
|
|
5558
|
+
var ee = F.set(V, P, f);
|
|
5559
|
+
Array.isArray(ee) ? (V = ee[0], zD(P, ee[1])) : V = ee;
|
|
5560
5560
|
}
|
|
5561
5561
|
} catch (le) {
|
|
5562
|
-
|
|
5562
|
+
$.e(le);
|
|
5563
5563
|
} finally {
|
|
5564
|
-
|
|
5564
|
+
$.f();
|
|
5565
5565
|
}
|
|
5566
|
-
return
|
|
5566
|
+
return V;
|
|
5567
5567
|
}
|
|
5568
5568
|
function F0(i) {
|
|
5569
5569
|
return i.match(G0)[1].replace(V0, "'");
|
|
@@ -6570,10 +6570,10 @@ const Qj = /* @__PURE__ */ Un(Kz, [["render", iA]]), sd = (i, e) => {
|
|
|
6570
6570
|
if (t("setHoverDate", E), (Y = (C = E.marker) == null ? void 0 : C.tooltip) != null && Y.length) {
|
|
6571
6571
|
const G = mt(a.value[T][w]);
|
|
6572
6572
|
if (G) {
|
|
6573
|
-
const { width:
|
|
6573
|
+
const { width: W, height: U } = G.getBoundingClientRect();
|
|
6574
6574
|
r.value = {
|
|
6575
6575
|
bottom: `${U}px`,
|
|
6576
|
-
left: `${
|
|
6576
|
+
left: `${W / 2}px`,
|
|
6577
6577
|
transform: "translateX(-50%)"
|
|
6578
6578
|
}, o.value = E.value;
|
|
6579
6579
|
}
|
|
@@ -6649,17 +6649,17 @@ const Qj = /* @__PURE__ */ Un(Kz, [["render", iA]]), sd = (i, e) => {
|
|
|
6649
6649
|
role: "gridcell",
|
|
6650
6650
|
class: "dp__calendar_item",
|
|
6651
6651
|
ref_for: !0,
|
|
6652
|
-
ref: (
|
|
6652
|
+
ref: (W) => f(W, C, G),
|
|
6653
6653
|
key: G + C,
|
|
6654
6654
|
"aria-selected": Y.classData.dp__active_date || Y.classData.dp__range_start || Y.classData.dp__range_start,
|
|
6655
6655
|
"aria-disabled": Y.classData.dp__cell_disabled,
|
|
6656
6656
|
tabindex: "0",
|
|
6657
|
-
onClick: ht((
|
|
6657
|
+
onClick: ht((W) => E.$emit("selectDate", Y), ["stop", "prevent"]),
|
|
6658
6658
|
onKeydown: [
|
|
6659
|
-
Ne((
|
|
6660
|
-
Ne((
|
|
6659
|
+
Ne((W) => E.$emit("selectDate", Y), ["enter"]),
|
|
6660
|
+
Ne((W) => E.$emit("handleSpace", Y), ["space"])
|
|
6661
6661
|
],
|
|
6662
|
-
onMouseover: (
|
|
6662
|
+
onMouseover: (W) => A(Y, C, G),
|
|
6663
6663
|
onMouseleave: b
|
|
6664
6664
|
}, [
|
|
6665
6665
|
Q("div", {
|
|
@@ -6688,24 +6688,24 @@ const Qj = /* @__PURE__ */ Un(Kz, [["render", iA]]), sd = (i, e) => {
|
|
|
6688
6688
|
onClick: T[0] || (T[0] = ht(() => {
|
|
6689
6689
|
}, ["stop"]))
|
|
6690
6690
|
}, [
|
|
6691
|
-
(S(!0), k(ye, null, we(Y.marker.tooltip, (
|
|
6691
|
+
(S(!0), k(ye, null, we(Y.marker.tooltip, (W, U) => (S(), k("div", {
|
|
6692
6692
|
key: U,
|
|
6693
6693
|
class: "dp__tooltip_text"
|
|
6694
6694
|
}, [
|
|
6695
6695
|
E.$slots["marker-tooltip"] ? oe(E.$slots, "marker-tooltip", {
|
|
6696
6696
|
key: 0,
|
|
6697
|
-
tooltop:
|
|
6697
|
+
tooltop: W,
|
|
6698
6698
|
day: Y.value
|
|
6699
6699
|
}) : _("", !0),
|
|
6700
6700
|
E.$slots["marker-tooltip"] ? _("", !0) : (S(), k(ye, { key: 1 }, [
|
|
6701
6701
|
Q("div", {
|
|
6702
6702
|
class: "dp__tooltip_mark",
|
|
6703
|
-
style: zt(
|
|
6703
|
+
style: zt(W.color ? { backgroundColor: W.color } : {})
|
|
6704
6704
|
}, null, 4),
|
|
6705
|
-
|
|
6705
|
+
W.html ? (S(), k("div", {
|
|
6706
6706
|
key: 0,
|
|
6707
|
-
innerHTML:
|
|
6708
|
-
}, null, 8, WA)) : (S(), k("div", HA, re(
|
|
6707
|
+
innerHTML: W.html
|
|
6708
|
+
}, null, 8, WA)) : (S(), k("div", HA, re(W.text), 1))
|
|
6709
6709
|
], 64))
|
|
6710
6710
|
]))), 128)),
|
|
6711
6711
|
FA
|
|
@@ -6791,9 +6791,9 @@ const Qj = /* @__PURE__ */ Un(Kz, [["render", iA]]), sd = (i, e) => {
|
|
|
6791
6791
|
dp__overlay_col: !0
|
|
6792
6792
|
})), m = q(() => n.items.map((T) => T.filter((w) => w).map((w) => {
|
|
6793
6793
|
var C, Y, G;
|
|
6794
|
-
const
|
|
6795
|
-
(
|
|
6796
|
-
|
|
6794
|
+
const W = n.disabledValues.some((V) => V === w.value) || I(w.value), U = (C = n.multiModelValue) != null && C.length ? (Y = n.multiModelValue) == null ? void 0 : Y.some(
|
|
6795
|
+
(V) => qe(
|
|
6796
|
+
V,
|
|
6797
6797
|
vn(
|
|
6798
6798
|
n.monthPicker ? Yo(/* @__PURE__ */ new Date(), w.value) : /* @__PURE__ */ new Date(),
|
|
6799
6799
|
n.monthPicker ? n.year : w.value
|
|
@@ -6805,8 +6805,8 @@ const Qj = /* @__PURE__ */ Un(Kz, [["render", iA]]), sd = (i, e) => {
|
|
|
6805
6805
|
className: {
|
|
6806
6806
|
dp__overlay_cell_active: U,
|
|
6807
6807
|
dp__overlay_cell: !U,
|
|
6808
|
-
dp__overlay_cell_disabled:
|
|
6809
|
-
dp__overlay_cell_active_disabled:
|
|
6808
|
+
dp__overlay_cell_disabled: W,
|
|
6809
|
+
dp__overlay_cell_active_disabled: W && U,
|
|
6810
6810
|
dp__overlay_cell_pad: !0,
|
|
6811
6811
|
dp__cell_in_between: (G = n.multiModelValue) != null && G.length ? z(w.value) : !1
|
|
6812
6812
|
}
|
|
@@ -6851,11 +6851,11 @@ const Qj = /* @__PURE__ */ Un(Kz, [["render", iA]]), sd = (i, e) => {
|
|
|
6851
6851
|
}, L = () => {
|
|
6852
6852
|
n.escClose && f();
|
|
6853
6853
|
}, E = (T, w, C, Y) => {
|
|
6854
|
-
var G,
|
|
6854
|
+
var G, W;
|
|
6855
6855
|
if (T && (w.value === +n.modelValue && !n.disabledValues.includes(w.value) && (r.value = T), c != null && c.value)) {
|
|
6856
6856
|
Array.isArray(s.value[C]) ? s.value[C][Y] = T : s.value[C] = [T];
|
|
6857
6857
|
const U = (G = n.headerRefs) != null && G.length ? [n.headerRefs].concat(s.value) : s.value.concat([n.skipButtonRef ? [] : [j.value]]);
|
|
6858
|
-
D(U, (
|
|
6858
|
+
D(U, (W = n.headerRefs) != null && W.length ? "monthPicker" : "selectionGrid");
|
|
6859
6859
|
}
|
|
6860
6860
|
};
|
|
6861
6861
|
return e({ focusGrid: p }), (T, w) => (S(), k("div", {
|
|
@@ -6878,14 +6878,14 @@ const Qj = /* @__PURE__ */ Un(Kz, [["render", iA]]), sd = (i, e) => {
|
|
|
6878
6878
|
key: Z(EA)(Y),
|
|
6879
6879
|
role: "row"
|
|
6880
6880
|
}, [
|
|
6881
|
-
(S(!0), k(ye, null, we(C, (G,
|
|
6881
|
+
(S(!0), k(ye, null, we(C, (G, W) => (S(), k("div", {
|
|
6882
6882
|
role: "gridcell",
|
|
6883
6883
|
class: ne(Z(v)),
|
|
6884
6884
|
key: G.value,
|
|
6885
6885
|
"aria-selected": G.value === i.modelValue && !i.disabledValues.includes(G.value),
|
|
6886
6886
|
"aria-disabled": G.className.dp__overlay_cell_disabled,
|
|
6887
6887
|
ref_for: !0,
|
|
6888
|
-
ref: (U) => E(U, G, Y,
|
|
6888
|
+
ref: (U) => E(U, G, Y, W),
|
|
6889
6889
|
tabindex: "0",
|
|
6890
6890
|
onClick: (U) => O(G.value),
|
|
6891
6891
|
onKeydown: [
|
|
@@ -7040,19 +7040,19 @@ const Qj = /* @__PURE__ */ Un(Kz, [["render", iA]]), sd = (i, e) => {
|
|
|
7040
7040
|
});
|
|
7041
7041
|
const d = (U) => ({
|
|
7042
7042
|
get: () => n[U],
|
|
7043
|
-
set: (
|
|
7043
|
+
set: (V) => {
|
|
7044
7044
|
const P = U === "month" ? "year" : "month";
|
|
7045
|
-
t("update-month-year", { [U]:
|
|
7045
|
+
t("update-month-year", { [U]: V, [P]: n[P] }), t("monthYearSelect", U === "year"), U === "month" ? w(!0) : C(!0);
|
|
7046
7046
|
}
|
|
7047
7047
|
}), p = q(d("month")), x = q(d("year")), v = q(() => (U) => {
|
|
7048
|
-
const
|
|
7048
|
+
const V = U === "month";
|
|
7049
7049
|
return {
|
|
7050
|
-
showSelectionGrid: (
|
|
7051
|
-
items: (
|
|
7052
|
-
disabledValues: n.filters[
|
|
7053
|
-
minValue: (
|
|
7054
|
-
maxValue: (
|
|
7055
|
-
headerRefs:
|
|
7050
|
+
showSelectionGrid: (V ? s : M).value,
|
|
7051
|
+
items: (V ? f : L).value,
|
|
7052
|
+
disabledValues: n.filters[V ? "months" : "years"],
|
|
7053
|
+
minValue: (V ? b : m).value,
|
|
7054
|
+
maxValue: (V ? I : A).value,
|
|
7055
|
+
headerRefs: V && n.monthPicker ? [l.value, c.value, g.value] : [],
|
|
7056
7056
|
escClose: n.escClose
|
|
7057
7057
|
};
|
|
7058
7058
|
}), m = q(() => n.minDate ? He(new Date(n.minDate)) : null), A = q(() => n.maxDate ? He(new Date(n.maxDate)) : null), b = q(() => {
|
|
@@ -7063,14 +7063,14 @@ const Qj = /* @__PURE__ */ Un(Kz, [["render", iA]]), sd = (i, e) => {
|
|
|
7063
7063
|
return rt(new Date(n.minDate));
|
|
7064
7064
|
}
|
|
7065
7065
|
return null;
|
|
7066
|
-
}), I = q(() => n.maxDate && A.value ? A.value < n.year ? -1 : A.value === n.year ? rt(new Date(n.maxDate)) : null : null), h = q(() => n.range && n.internalModelValue && (n.monthPicker || n.yearPicker) ? n.internalModelValue : []), O = (U,
|
|
7066
|
+
}), I = q(() => n.maxDate && A.value ? A.value < n.year ? -1 : A.value === n.year ? rt(new Date(n.maxDate)) : null : null), h = q(() => n.range && n.internalModelValue && (n.monthPicker || n.yearPicker) ? n.internalModelValue : []), O = (U, V = !1) => {
|
|
7067
7067
|
const P = [];
|
|
7068
|
-
for (let
|
|
7069
|
-
const ie = [U[
|
|
7070
|
-
P.push(
|
|
7068
|
+
for (let $ = 0; $ < U.length; $ += 3) {
|
|
7069
|
+
const ie = [U[$], U[$ + 1], U[$ + 2]];
|
|
7070
|
+
P.push(V ? ie.reverse() : ie);
|
|
7071
7071
|
}
|
|
7072
|
-
return
|
|
7073
|
-
}, z = q(() => n.months.find((
|
|
7072
|
+
return V ? P.reverse() : P;
|
|
7073
|
+
}, z = q(() => n.months.find((V) => V.value === n.month) || { text: "", value: 0 }), f = q(() => O(n.months)), L = q(() => O(n.years, n.reverseYears)), E = q(() => n.multiCalendars ? n.multiCalendarsSolo ? !0 : n.instance === 0 : !0), T = q(() => n.multiCalendars ? n.multiCalendarsSolo ? !0 : n.instance === n.multiCalendars - 1 : !0), w = (U = !1) => {
|
|
7074
7074
|
Y(U), s.value = !s.value, s.value || t("overlay-closed");
|
|
7075
7075
|
}, C = (U = !1) => {
|
|
7076
7076
|
Y(U), M.value = !M.value, M.value || t("overlay-closed");
|
|
@@ -7082,20 +7082,20 @@ const Qj = /* @__PURE__ */ Un(Kz, [["render", iA]]), sd = (i, e) => {
|
|
|
7082
7082
|
month: n.month,
|
|
7083
7083
|
fromNav: !0
|
|
7084
7084
|
});
|
|
7085
|
-
},
|
|
7086
|
-
N != null && N.value && (u.value[
|
|
7085
|
+
}, W = (U, V) => {
|
|
7086
|
+
N != null && N.value && (u.value[V] = mt(U), a(u.value, "monthYear"));
|
|
7087
7087
|
};
|
|
7088
7088
|
return e({
|
|
7089
7089
|
toggleMonthPicker: w,
|
|
7090
7090
|
toggleYearPicker: C
|
|
7091
|
-
}), (U,
|
|
7091
|
+
}), (U, V) => (S(), k("div", nT, [
|
|
7092
7092
|
!U.monthPicker && !i.yearPicker ? (S(), k(ye, { key: 0 }, [
|
|
7093
7093
|
Z(E) && !U.vertical ? (S(), ge(NM, {
|
|
7094
7094
|
key: 0,
|
|
7095
7095
|
"aria-label": Z(j).prevMonth,
|
|
7096
7096
|
disabled: Z(y)(!1),
|
|
7097
|
-
onActivate:
|
|
7098
|
-
onSetRef:
|
|
7097
|
+
onActivate: V[0] || (V[0] = (P) => Z(D)(!1)),
|
|
7098
|
+
onSetRef: V[1] || (V[1] = (P) => W(P, 0))
|
|
7099
7099
|
}, {
|
|
7100
7100
|
default: ce(() => [
|
|
7101
7101
|
U.$slots["arrow-left"] ? oe(U.$slots, "arrow-left", { key: 0 }) : _("", !0),
|
|
@@ -7107,10 +7107,10 @@ const Qj = /* @__PURE__ */ Un(Kz, [["render", iA]]), sd = (i, e) => {
|
|
|
7107
7107
|
"aria-label": Z(j).openMonthsOverlay,
|
|
7108
7108
|
"slot-name": "month-overlay",
|
|
7109
7109
|
modelValue: Z(p),
|
|
7110
|
-
"onUpdate:modelValue":
|
|
7110
|
+
"onUpdate:modelValue": V[2] || (V[2] = (P) => An(p) ? p.value = P : null)
|
|
7111
7111
|
}, Z(v)("month"), {
|
|
7112
7112
|
onToggle: w,
|
|
7113
|
-
onSetRef:
|
|
7113
|
+
onSetRef: V[3] || (V[3] = (P) => W(P, 1))
|
|
7114
7114
|
}), _t({
|
|
7115
7115
|
default: ce(() => [
|
|
7116
7116
|
U.$slots.month ? oe(U.$slots, "month", Ki(pt({ key: 0 }, Z(z)))) : _("", !0),
|
|
@@ -7142,10 +7142,10 @@ const Qj = /* @__PURE__ */ Un(Kz, [["render", iA]]), sd = (i, e) => {
|
|
|
7142
7142
|
"aria-label": Z(j).openYearsOverlay,
|
|
7143
7143
|
"slot-name": "year-overlay",
|
|
7144
7144
|
modelValue: Z(x),
|
|
7145
|
-
"onUpdate:modelValue":
|
|
7145
|
+
"onUpdate:modelValue": V[4] || (V[4] = (P) => An(x) ? x.value = P : null)
|
|
7146
7146
|
}, Z(v)("year"), {
|
|
7147
7147
|
onToggle: C,
|
|
7148
|
-
onSetRef:
|
|
7148
|
+
onSetRef: V[5] || (V[5] = (P) => W(P, 2))
|
|
7149
7149
|
}), _t({
|
|
7150
7150
|
default: ce(() => [
|
|
7151
7151
|
U.$slots.year ? oe(U.$slots, "year", {
|
|
@@ -7180,7 +7180,7 @@ const Qj = /* @__PURE__ */ Un(Kz, [["render", iA]]), sd = (i, e) => {
|
|
|
7180
7180
|
key: 1,
|
|
7181
7181
|
"aria-label": Z(j).prevMonth,
|
|
7182
7182
|
disabled: Z(y)(!1),
|
|
7183
|
-
onActivate:
|
|
7183
|
+
onActivate: V[6] || (V[6] = (P) => Z(D)(!1))
|
|
7184
7184
|
}, {
|
|
7185
7185
|
default: ce(() => [
|
|
7186
7186
|
U.$slots["arrow-up"] ? oe(U.$slots, "arrow-up", { key: 0 }) : _("", !0),
|
|
@@ -7192,9 +7192,9 @@ const Qj = /* @__PURE__ */ Un(Kz, [["render", iA]]), sd = (i, e) => {
|
|
|
7192
7192
|
key: 2,
|
|
7193
7193
|
disabled: Z(y)(!0),
|
|
7194
7194
|
"aria-label": Z(j).nextMonth,
|
|
7195
|
-
onActivate:
|
|
7195
|
+
onActivate: V[7] || (V[7] = (P) => Z(D)(!0)),
|
|
7196
7196
|
ref: "rightIcon",
|
|
7197
|
-
onSetRef:
|
|
7197
|
+
onSetRef: V[8] || (V[8] = (P) => W(P, 3))
|
|
7198
7198
|
}, {
|
|
7199
7199
|
default: ce(() => [
|
|
7200
7200
|
U.$slots[U.vertical ? "arrow-down" : "arrow-right"] ? oe(U.$slots, U.vertical ? "arrow-down" : "arrow-right", { key: 0 }) : _("", !0),
|
|
@@ -7209,9 +7209,9 @@ const Qj = /* @__PURE__ */ Un(Kz, [["render", iA]]), sd = (i, e) => {
|
|
|
7209
7209
|
"multi-model-value": Z(h),
|
|
7210
7210
|
"month-picker": "",
|
|
7211
7211
|
modelValue: Z(p),
|
|
7212
|
-
"onUpdate:modelValue":
|
|
7212
|
+
"onUpdate:modelValue": V[15] || (V[15] = (P) => An(p) ? p.value = P : null),
|
|
7213
7213
|
onToggle: w,
|
|
7214
|
-
onSelected:
|
|
7214
|
+
onSelected: V[16] || (V[16] = (P) => U.$emit("overlay-closed"))
|
|
7215
7215
|
}), _t({
|
|
7216
7216
|
header: ce(() => [
|
|
7217
7217
|
Q("div", oT, [
|
|
@@ -7220,8 +7220,8 @@ const Qj = /* @__PURE__ */ Un(Kz, [["render", iA]]), sd = (i, e) => {
|
|
|
7220
7220
|
tabindex: "0",
|
|
7221
7221
|
ref_key: "mpPrevIconRef",
|
|
7222
7222
|
ref: l,
|
|
7223
|
-
onClick:
|
|
7224
|
-
onKeydown:
|
|
7223
|
+
onClick: V[9] || (V[9] = (P) => G(!1)),
|
|
7224
|
+
onKeydown: V[10] || (V[10] = Ne((P) => G(!1), ["enter"]))
|
|
7225
7225
|
}, [
|
|
7226
7226
|
Q("div", {
|
|
7227
7227
|
class: "dp__inner_nav",
|
|
@@ -7255,8 +7255,8 @@ const Qj = /* @__PURE__ */ Un(Kz, [["render", iA]]), sd = (i, e) => {
|
|
|
7255
7255
|
tabindex: "0",
|
|
7256
7256
|
ref_key: "mpNextIconRef",
|
|
7257
7257
|
ref: g,
|
|
7258
|
-
onClick:
|
|
7259
|
-
onKeydown:
|
|
7258
|
+
onClick: V[11] || (V[11] = (P) => G(!0)),
|
|
7259
|
+
onKeydown: V[12] || (V[12] = Ne((P) => G(!0), ["enter"]))
|
|
7260
7260
|
}, [
|
|
7261
7261
|
Q("div", {
|
|
7262
7262
|
class: "dp__inner_nav",
|
|
@@ -7275,9 +7275,9 @@ const Qj = /* @__PURE__ */ Un(Kz, [["render", iA]]), sd = (i, e) => {
|
|
|
7275
7275
|
default: ce(() => [
|
|
7276
7276
|
M.value ? (S(), ge(Uo, pt({ key: 0 }, Z(v)("year"), {
|
|
7277
7277
|
modelValue: Z(x),
|
|
7278
|
-
"onUpdate:modelValue":
|
|
7278
|
+
"onUpdate:modelValue": V[13] || (V[13] = (P) => An(x) ? x.value = P : null),
|
|
7279
7279
|
onToggle: C,
|
|
7280
|
-
onSelected:
|
|
7280
|
+
onSelected: V[14] || (V[14] = (P) => U.$emit("overlay-closed"))
|
|
7281
7281
|
}), _t({
|
|
7282
7282
|
"button-icon": ce(() => [
|
|
7283
7283
|
U.$slots["calendar-icon"] ? oe(U.$slots, "calendar-icon", { key: 0 }) : _("", !0),
|
|
@@ -7315,13 +7315,13 @@ const Qj = /* @__PURE__ */ Un(Kz, [["render", iA]]), sd = (i, e) => {
|
|
|
7315
7315
|
]), 1040, ["skip-active", "year", "multi-model-value", "modelValue"])) : _("", !0),
|
|
7316
7316
|
i.yearPicker ? (S(), ge(Uo, pt({ key: 2 }, Z(v)("year"), {
|
|
7317
7317
|
modelValue: Z(x),
|
|
7318
|
-
"onUpdate:modelValue":
|
|
7318
|
+
"onUpdate:modelValue": V[17] || (V[17] = (P) => An(x) ? x.value = P : null),
|
|
7319
7319
|
"multi-model-value": Z(h),
|
|
7320
7320
|
"skip-active": n.range,
|
|
7321
7321
|
"skip-button-ref": "",
|
|
7322
7322
|
"year-picker": "",
|
|
7323
7323
|
onToggle: C,
|
|
7324
|
-
onSelected:
|
|
7324
|
+
onSelected: V[18] || (V[18] = (P) => U.$emit("overlay-closed"))
|
|
7325
7325
|
}), _t({ _: 2 }, [
|
|
7326
7326
|
U.$slots["year-overlay"] ? {
|
|
7327
7327
|
name: "item",
|
|
@@ -7759,7 +7759,7 @@ const Qj = /* @__PURE__ */ Un(Kz, [["render", iA]]), sd = (i, e) => {
|
|
|
7759
7759
|
},
|
|
7760
7760
|
{ deep: !0 }
|
|
7761
7761
|
), Je(() => {
|
|
7762
|
-
h(!0), d.value || (i.startDate && (a.value[0].month = rt(new Date(i.startDate)), a.value[0].year = He(new Date(i.startDate)), i.multiCalendars &&
|
|
7762
|
+
h(!0), d.value || (i.startDate && (a.value[0].month = rt(new Date(i.startDate)), a.value[0].year = He(new Date(i.startDate)), i.multiCalendars && V(0)), i.startTime && y());
|
|
7763
7763
|
});
|
|
7764
7764
|
const l = q(
|
|
7765
7765
|
() => (B) => a.value[B] ? a.value[B].month : 0
|
|
@@ -7895,7 +7895,7 @@ const Qj = /* @__PURE__ */ Un(Kz, [["render", iA]]), sd = (i, e) => {
|
|
|
7895
7895
|
return !1;
|
|
7896
7896
|
}
|
|
7897
7897
|
return !1;
|
|
7898
|
-
},
|
|
7898
|
+
}, W = (B) => {
|
|
7899
7899
|
if (i.autoRange || i.weekPicker) {
|
|
7900
7900
|
if (r.value) {
|
|
7901
7901
|
const te = Ui(r.value, +i.autoRange);
|
|
@@ -7918,7 +7918,7 @@ const Qj = /* @__PURE__ */ Un(Kz, [["render", iA]]), sd = (i, e) => {
|
|
|
7918
7918
|
return !1;
|
|
7919
7919
|
}
|
|
7920
7920
|
return !1;
|
|
7921
|
-
},
|
|
7921
|
+
}, V = (B) => {
|
|
7922
7922
|
for (let te = B - 1; te >= 0; te--) {
|
|
7923
7923
|
const se = ti(Ct(/* @__PURE__ */ new Date(), { month: l.value(te + 1), year: c.value(te + 1) }), 1);
|
|
7924
7924
|
g(te, rt(se), He(se));
|
|
@@ -7927,9 +7927,9 @@ const Qj = /* @__PURE__ */ Un(Kz, [["render", iA]]), sd = (i, e) => {
|
|
|
7927
7927
|
const se = xi(Ct(/* @__PURE__ */ new Date(), { month: l.value(te - 1), year: c.value(te - 1) }), 1);
|
|
7928
7928
|
g(te, rt(se), He(se));
|
|
7929
7929
|
}
|
|
7930
|
-
}, P = (B) => bn(/* @__PURE__ */ new Date(), l.value(B), c.value(B)),
|
|
7930
|
+
}, P = (B) => bn(/* @__PURE__ */ new Date(), l.value(B), c.value(B)), $ = (B, te) => {
|
|
7931
7931
|
const se = i.monthPicker ? l.value(B) !== te.month || !te.fromNav : c.value(B) !== te.year;
|
|
7932
|
-
if (j(B, te.month), N(B, te.year), i.multiCalendars && !i.multiCalendarsSolo &&
|
|
7932
|
+
if (j(B, te.month), N(B, te.year), i.multiCalendars && !i.multiCalendarsSolo && V(B), i.monthPicker || i.yearPicker)
|
|
7933
7933
|
if (i.range) {
|
|
7934
7934
|
if (se) {
|
|
7935
7935
|
let ze = d.value ? d.value.slice() : [];
|
|
@@ -7938,7 +7938,7 @@ const Qj = /* @__PURE__ */ Un(Kz, [["render", iA]]), sd = (i, e) => {
|
|
|
7938
7938
|
} else
|
|
7939
7939
|
d.value = P(B);
|
|
7940
7940
|
e("updateMonthYear", { instance: B, month: te.month, year: te.year }), Nn(i.multiCalendarsSolo ? B : void 0);
|
|
7941
|
-
}, ie = (B) => Qt(B, s.value, M.value, D()),
|
|
7941
|
+
}, ie = (B) => Qt(B, s.value, M.value, D()), F = (B) => {
|
|
7942
7942
|
Eo(B) && Eo(d.value) && ai(s.value) && ai(M.value) ? (B[0] && d.value[0] && (d.value[0] = Qt(B[0], s.value[0], M.value[0], D())), B[1] && d.value[1] && (d.value[1] = Qt(
|
|
7943
7943
|
B[1],
|
|
7944
7944
|
s.value[1],
|
|
@@ -7955,11 +7955,11 @@ const Qj = /* @__PURE__ */ Un(Kz, [["render", iA]]), sd = (i, e) => {
|
|
|
7955
7955
|
if (s.value = ze, M.value = yt, u.value = Ht, d.value)
|
|
7956
7956
|
if (i.multiDates) {
|
|
7957
7957
|
const Rt = I();
|
|
7958
|
-
Rt &&
|
|
7958
|
+
Rt && F(Rt);
|
|
7959
7959
|
} else
|
|
7960
|
-
|
|
7960
|
+
F(d.value);
|
|
7961
7961
|
else
|
|
7962
|
-
i.timePicker &&
|
|
7962
|
+
i.timePicker && F(i.range ? [/* @__PURE__ */ new Date(), /* @__PURE__ */ new Date()] : /* @__PURE__ */ new Date());
|
|
7963
7963
|
t();
|
|
7964
7964
|
}, le = () => {
|
|
7965
7965
|
r.value = null;
|
|
@@ -7985,8 +7985,8 @@ const Qj = /* @__PURE__ */ Un(Kz, [["render", iA]]), sd = (i, e) => {
|
|
|
7985
7985
|
He(ze),
|
|
7986
7986
|
B < 0,
|
|
7987
7987
|
i.preventMinMaxNavigation
|
|
7988
|
-
) && (g(te, rt(ze), He(ze)), i.multiCalendars && !i.multiCalendarsSolo &&
|
|
7989
|
-
},
|
|
7988
|
+
) && (g(te, rt(ze), He(ze)), i.multiCalendars && !i.multiCalendarsSolo && V(te), Nn());
|
|
7989
|
+
}, J = (B, te) => {
|
|
7990
7990
|
i.monthChangeOnScroll && Pe(i.monthChangeOnScroll !== "inverse" ? -B.deltaY : B.deltaY, te);
|
|
7991
7991
|
}, me = (B, te, se = !1) => {
|
|
7992
7992
|
i.monthChangeOnArrows && i.vertical === se && be(B, te);
|
|
@@ -8014,13 +8014,13 @@ const Qj = /* @__PURE__ */ Un(Kz, [["render", iA]]), sd = (i, e) => {
|
|
|
8014
8014
|
selectDate: w,
|
|
8015
8015
|
rangeActive: v,
|
|
8016
8016
|
isActiveDate: x,
|
|
8017
|
-
updateMonthYear:
|
|
8017
|
+
updateMonthYear: $,
|
|
8018
8018
|
isHoverRangeEnd: G,
|
|
8019
|
-
isAutoRangeInBetween:
|
|
8019
|
+
isAutoRangeInBetween: W,
|
|
8020
8020
|
isAutoRangeStart: U,
|
|
8021
8021
|
clearHoverDate: le,
|
|
8022
8022
|
rangeActiveStartEnd: xe,
|
|
8023
|
-
handleScroll:
|
|
8023
|
+
handleScroll: J,
|
|
8024
8024
|
getMarker: ot,
|
|
8025
8025
|
handleArrow: me,
|
|
8026
8026
|
handleSwipe: be,
|
|
@@ -8082,8 +8082,8 @@ const TT = ["id", "aria-label", "onKeydown"], xT = {
|
|
|
8082
8082
|
calendar: !1
|
|
8083
8083
|
}), a = K([]), s = K([]), M = K(null), u = K(null), l = K(0), c = K(!1), g = K(0), j = dt(Es), N = dt(un), D = dt(ln), { setMenuFocused: y, setShiftKey: d, getStore: p } = ey();
|
|
8084
8084
|
Je(() => {
|
|
8085
|
-
var
|
|
8086
|
-
c.value = !0, !((
|
|
8085
|
+
var X;
|
|
8086
|
+
c.value = !0, !((X = t.presetRanges) != null && X.length) && !n["left-sidebar"] && !n["right-sidebar"] && ze();
|
|
8087
8087
|
const he = mt(u);
|
|
8088
8088
|
if (he && !t.textInput && !t.inline && (y(!0), b()), he) {
|
|
8089
8089
|
const de = (Ae) => {
|
|
@@ -8096,11 +8096,11 @@ const TT = ["id", "aria-label", "onKeydown"], xT = {
|
|
|
8096
8096
|
document.removeEventListener("resize", ze);
|
|
8097
8097
|
});
|
|
8098
8098
|
const { arrowRight: x, arrowLeft: v, arrowDown: m, arrowUp: A } = cn(), b = () => {
|
|
8099
|
-
const
|
|
8100
|
-
|
|
8099
|
+
const X = mt(u);
|
|
8100
|
+
X && X.focus({ preventScroll: !0 });
|
|
8101
8101
|
}, I = () => {
|
|
8102
|
-
var
|
|
8103
|
-
(
|
|
8102
|
+
var X;
|
|
8103
|
+
(X = t.flow) != null && X.length && g.value !== -1 && (g.value += 1, e("flow-step", g.value), Jt());
|
|
8104
8104
|
}, h = () => {
|
|
8105
8105
|
g.value = -1;
|
|
8106
8106
|
}, {
|
|
@@ -8114,13 +8114,13 @@ const TT = ["id", "aria-label", "onKeydown"], xT = {
|
|
|
8114
8114
|
seconds: C,
|
|
8115
8115
|
isDisabled: Y,
|
|
8116
8116
|
isActiveDate: G,
|
|
8117
|
-
selectDate:
|
|
8117
|
+
selectDate: W,
|
|
8118
8118
|
getWeekNum: U,
|
|
8119
|
-
setHoverDate:
|
|
8119
|
+
setHoverDate: V,
|
|
8120
8120
|
isHoverRangeEnd: P,
|
|
8121
|
-
isAutoRangeInBetween:
|
|
8121
|
+
isAutoRangeInBetween: $,
|
|
8122
8122
|
isAutoRangeStart: ie,
|
|
8123
|
-
rangeActive:
|
|
8123
|
+
rangeActive: F,
|
|
8124
8124
|
clearHoverDate: ee,
|
|
8125
8125
|
rangeActiveStartEnd: le,
|
|
8126
8126
|
monthYearSelect: ue,
|
|
@@ -8129,23 +8129,23 @@ const TT = ["id", "aria-label", "onKeydown"], xT = {
|
|
|
8129
8129
|
handleSwipe: ve,
|
|
8130
8130
|
getMarker: Xe,
|
|
8131
8131
|
selectCurrentDate: Pe,
|
|
8132
|
-
isHoverDateStartEnd:
|
|
8132
|
+
isHoverDateStartEnd: J,
|
|
8133
8133
|
isHoverDate: me,
|
|
8134
8134
|
presetDateRange: be
|
|
8135
8135
|
} = AT(t, e, I, s), ot = mn(n, "calendar"), ri = mn(n, "action"), dn = mn(n, "timePicker"), Nn = mn(n, "monthYear"), B = q(() => t.openOnTop ? "dp__arrow_bottom" : "dp__arrow_top"), te = q(() => mA(t.yearRange)), se = q(() => LA(t.locale, t.monthNameFormat)), ze = () => {
|
|
8136
|
-
const
|
|
8137
|
-
|
|
8136
|
+
const X = mt(o);
|
|
8137
|
+
X && (l.value = X.getBoundingClientRect().width);
|
|
8138
8138
|
}, yt = q(
|
|
8139
|
-
() => (
|
|
8140
|
-
L.value(
|
|
8141
|
-
E.value(
|
|
8139
|
+
() => (X) => AA(
|
|
8140
|
+
L.value(X),
|
|
8141
|
+
E.value(X),
|
|
8142
8142
|
+t.weekStart,
|
|
8143
8143
|
t.hideOffsetDates
|
|
8144
8144
|
)
|
|
8145
8145
|
), Ht = q(
|
|
8146
8146
|
() => t.multiCalendars > 0 && t.range ? [...Array(t.multiCalendars).keys()] : [0]
|
|
8147
8147
|
), Rt = q(
|
|
8148
|
-
() => (
|
|
8148
|
+
() => (X) => X === 1
|
|
8149
8149
|
), Ri = q(() => t.monthPicker || t.timePicker || t.yearPicker), yi = q(
|
|
8150
8150
|
() => ({
|
|
8151
8151
|
dp__flex_display: t.multiCalendars > 0
|
|
@@ -8156,7 +8156,7 @@ const TT = ["id", "aria-label", "onKeydown"], xT = {
|
|
|
8156
8156
|
dp__menu_disabled: t.disabled,
|
|
8157
8157
|
dp__menu_readonly: t.readonly
|
|
8158
8158
|
})), Zi = q(
|
|
8159
|
-
() => (
|
|
8159
|
+
() => (X) => Gi(yt, X)
|
|
8160
8160
|
), Ft = q(() => ({
|
|
8161
8161
|
locale: t.locale,
|
|
8162
8162
|
weekNumName: t.weekNumName,
|
|
@@ -8180,22 +8180,22 @@ const TT = ["id", "aria-label", "onKeydown"], xT = {
|
|
|
8180
8180
|
dp__relative: t.inline,
|
|
8181
8181
|
[t.menuClassName]: !!t.menuClassName
|
|
8182
8182
|
})
|
|
8183
|
-
), $s = () => t.modelAuto && Array.isArray(t.internalModelValue) ? !!t.internalModelValue[0] : !1, $t = () => t.modelAuto ? Kj(t.internalModelValue) : !0, Gi = (
|
|
8183
|
+
), $s = () => t.modelAuto && Array.isArray(t.internalModelValue) ? !!t.internalModelValue[0] : !1, $t = () => t.modelAuto ? Kj(t.internalModelValue) : !0, Gi = (X, he) => X.value(he).map((de) => ({
|
|
8184
8184
|
...de,
|
|
8185
8185
|
days: de.days.map((Ae) => {
|
|
8186
|
-
const Le = Y(Ae.value), jn = me(Le, Ae), Ei = t.range ? t.modelAuto ? $s() && G(Ae) : !1 : G(Ae), Xt = t.highlight ? _j(Ae.value, t.highlight) : !1, ur = Le && t.highlightDisabledDays == !1, lr = t.highlightWeekDays && t.highlightWeekDays.includes(Ae.value.getDay()), cr = (t.range || t.weekPicker) && (!(t.multiCalendars > 0) || Ae.current) && !Le && $t() && !(!Ae.current && t.hideOffsetDates) && !G(Ae) ?
|
|
8186
|
+
const Le = Y(Ae.value), jn = me(Le, Ae), Ei = t.range ? t.modelAuto ? $s() && G(Ae) : !1 : G(Ae), Xt = t.highlight ? _j(Ae.value, t.highlight) : !1, ur = Le && t.highlightDisabledDays == !1, lr = t.highlightWeekDays && t.highlightWeekDays.includes(Ae.value.getDay()), cr = (t.range || t.weekPicker) && (!(t.multiCalendars > 0) || Ae.current) && !Le && $t() && !(!Ae.current && t.hideOffsetDates) && !G(Ae) ? F(Ae) : !1;
|
|
8187
8187
|
return Ae.marker = Xe(Ae), Ae.classData = {
|
|
8188
8188
|
dp__cell_offset: !Ae.current,
|
|
8189
8189
|
dp__pointer: !Le && !(!Ae.current && t.hideOffsetDates),
|
|
8190
8190
|
dp__active_date: Ei,
|
|
8191
8191
|
dp__date_hover: jn,
|
|
8192
|
-
dp__date_hover_start:
|
|
8193
|
-
dp__date_hover_end:
|
|
8192
|
+
dp__date_hover_start: J(jn, Ae, !0),
|
|
8193
|
+
dp__date_hover_end: J(jn, Ae, !1),
|
|
8194
8194
|
dp__range_between: cr && !t.weekPicker,
|
|
8195
8195
|
dp__range_between_week: cr && t.weekPicker,
|
|
8196
8196
|
dp__today: !t.noToday && qe(Ae.value, f.value) && Ae.current,
|
|
8197
8197
|
dp__cell_disabled: Le,
|
|
8198
|
-
dp__cell_auto_range:
|
|
8198
|
+
dp__cell_auto_range: $(Ae),
|
|
8199
8199
|
dp__cell_auto_range_start: ie(Ae),
|
|
8200
8200
|
dp__cell_auto_range_end: P(Ae),
|
|
8201
8201
|
dp__range_start: t.multiCalendars > 0 ? Ae.current && le(Ae) && $t() : le(Ae) && $t(),
|
|
@@ -8206,35 +8206,35 @@ const TT = ["id", "aria-label", "onKeydown"], xT = {
|
|
|
8206
8206
|
[t.dayClass ? t.dayClass(Ae.value) : ""]: !0
|
|
8207
8207
|
}, Ae;
|
|
8208
8208
|
})
|
|
8209
|
-
})), sr = (
|
|
8210
|
-
|
|
8209
|
+
})), sr = (X) => {
|
|
8210
|
+
X.stopPropagation(), X.preventDefault(), X.stopImmediatePropagation();
|
|
8211
8211
|
}, Mr = () => {
|
|
8212
8212
|
t.escClose && e("closePicker");
|
|
8213
|
-
}, Js = (
|
|
8214
|
-
|
|
8215
|
-
}, Pn = (
|
|
8213
|
+
}, Js = (X, he = !1) => {
|
|
8214
|
+
W(X, he), t.spaceConfirm && e("selectDate");
|
|
8215
|
+
}, Pn = (X) => {
|
|
8216
8216
|
var he;
|
|
8217
|
-
(he = t.flow) != null && he.length && (r[
|
|
8217
|
+
(he = t.flow) != null && he.length && (r[X] = !0, Object.keys(r).filter((de) => !r[de]).length || Jt());
|
|
8218
8218
|
}, Jt = () => {
|
|
8219
8219
|
t.flow[g.value] === "month" && a.value[0] && a.value[0].toggleMonthPicker(!0), t.flow[g.value] === "year" && a.value && a.value[0].toggleYearPicker(!0), t.flow[g.value] === "calendar" && M.value && M.value.toggleTimePicker(!1, !0), t.flow[g.value] === "time" && M.value && M.value.toggleTimePicker(!0, !0);
|
|
8220
|
-
const
|
|
8221
|
-
(
|
|
8222
|
-
}, Vi = (
|
|
8220
|
+
const X = t.flow[g.value];
|
|
8221
|
+
(X === "hours" || X === "minutes" || X === "seconds") && M.value && M.value.toggleTimePicker(!0, !0, X);
|
|
8222
|
+
}, Vi = (X) => {
|
|
8223
8223
|
if (D != null && D.value) {
|
|
8224
|
-
if (
|
|
8224
|
+
if (X === "up")
|
|
8225
8225
|
return A();
|
|
8226
|
-
if (
|
|
8226
|
+
if (X === "down")
|
|
8227
8227
|
return m();
|
|
8228
|
-
if (
|
|
8228
|
+
if (X === "left")
|
|
8229
8229
|
return v();
|
|
8230
|
-
if (
|
|
8230
|
+
if (X === "right")
|
|
8231
8231
|
return x();
|
|
8232
8232
|
} else
|
|
8233
|
-
|
|
8234
|
-
}, yo = (
|
|
8235
|
-
d(
|
|
8233
|
+
X === "left" || X === "up" ? Ve("left", 0, X === "up") : Ve("right", 0, X === "down");
|
|
8234
|
+
}, yo = (X) => {
|
|
8235
|
+
d(X.shiftKey), !t.disableMonthYearSelect && X.code === "Tab" && X.target.classList.contains("dp__menu") && p().shiftKeyInMenu && (X.preventDefault(), X.stopImmediatePropagation(), e("closePicker"));
|
|
8236
8236
|
};
|
|
8237
|
-
return (
|
|
8237
|
+
return (X, he) => (S(), ge(Yn, {
|
|
8238
8238
|
appear: "",
|
|
8239
8239
|
name: Z(j).menuAppear,
|
|
8240
8240
|
mode: "out-in",
|
|
@@ -8242,7 +8242,7 @@ const TT = ["id", "aria-label", "onKeydown"], xT = {
|
|
|
8242
8242
|
}, {
|
|
8243
8243
|
default: ce(() => [
|
|
8244
8244
|
Q("div", {
|
|
8245
|
-
id:
|
|
8245
|
+
id: X.uid ? `dp-menu-${X.uid}` : void 0,
|
|
8246
8246
|
tabindex: "0",
|
|
8247
8247
|
ref_key: "dpMenuRef",
|
|
8248
8248
|
ref: u,
|
|
@@ -8260,30 +8260,30 @@ const TT = ["id", "aria-label", "onKeydown"], xT = {
|
|
|
8260
8260
|
yo
|
|
8261
8261
|
]
|
|
8262
8262
|
}, [
|
|
8263
|
-
(
|
|
8263
|
+
(X.disabled || X.readonly) && X.inline ? (S(), k("div", {
|
|
8264
8264
|
key: 0,
|
|
8265
8265
|
class: ne(Z(Hs))
|
|
8266
8266
|
}, null, 2)) : _("", !0),
|
|
8267
|
-
!
|
|
8267
|
+
!X.inline && !X.teleportCenter ? (S(), k("div", {
|
|
8268
8268
|
key: 1,
|
|
8269
8269
|
class: ne(Z(B))
|
|
8270
8270
|
}, null, 2)) : _("", !0),
|
|
8271
8271
|
Q("div", {
|
|
8272
8272
|
class: ne({
|
|
8273
|
-
dp__menu_content_wrapper:
|
|
8273
|
+
dp__menu_content_wrapper: X.presetRanges.length || !!X.$slots["left-sidebar"] || !!X.$slots["right-sidebar"]
|
|
8274
8274
|
})
|
|
8275
8275
|
}, [
|
|
8276
|
-
|
|
8277
|
-
oe(
|
|
8276
|
+
X.$slots["left-sidebar"] ? (S(), k("div", xT, [
|
|
8277
|
+
oe(X.$slots, "left-sidebar")
|
|
8278
8278
|
])) : _("", !0),
|
|
8279
|
-
|
|
8280
|
-
(S(!0), k(ye, null, we(
|
|
8279
|
+
X.presetRanges.length ? (S(), k("div", mT, [
|
|
8280
|
+
(S(!0), k(ye, null, we(X.presetRanges, (de, Ae) => (S(), k("div", {
|
|
8281
8281
|
key: Ae,
|
|
8282
8282
|
style: zt(de.style || {}),
|
|
8283
8283
|
class: "dp__preset_range",
|
|
8284
8284
|
onClick: (Le) => Z(be)(de.range, !!de.slot)
|
|
8285
8285
|
}, [
|
|
8286
|
-
de.slot ? oe(
|
|
8286
|
+
de.slot ? oe(X.$slots, de.slot, {
|
|
8287
8287
|
key: 0,
|
|
8288
8288
|
presetDateRange: Z(be),
|
|
8289
8289
|
label: de.label,
|
|
@@ -8306,7 +8306,7 @@ const TT = ["id", "aria-label", "onKeydown"], xT = {
|
|
|
8306
8306
|
key: de,
|
|
8307
8307
|
class: ne(Z(Ws))
|
|
8308
8308
|
}, [
|
|
8309
|
-
!
|
|
8309
|
+
!X.disableMonthYearSelect && !X.timePicker ? (S(), ge(_r(X.monthYearComponent ? X.monthYearComponent : MT), pt({
|
|
8310
8310
|
key: 0,
|
|
8311
8311
|
ref_for: !0,
|
|
8312
8312
|
ref: (Le) => {
|
|
@@ -8315,23 +8315,23 @@ const TT = ["id", "aria-label", "onKeydown"], xT = {
|
|
|
8315
8315
|
}, {
|
|
8316
8316
|
months: Z(se),
|
|
8317
8317
|
years: Z(te),
|
|
8318
|
-
filters:
|
|
8319
|
-
monthPicker:
|
|
8318
|
+
filters: X.filters,
|
|
8319
|
+
monthPicker: X.monthPicker,
|
|
8320
8320
|
month: Z(L)(de),
|
|
8321
8321
|
year: Z(E)(de),
|
|
8322
|
-
customProps:
|
|
8322
|
+
customProps: X.customProps,
|
|
8323
8323
|
multiCalendars: i.multiCalendars,
|
|
8324
|
-
multiCalendarsSolo:
|
|
8324
|
+
multiCalendarsSolo: X.multiCalendarsSolo,
|
|
8325
8325
|
instance: de,
|
|
8326
|
-
minDate:
|
|
8327
|
-
maxDate:
|
|
8328
|
-
preventMinMaxNavigation:
|
|
8326
|
+
minDate: X.minDate,
|
|
8327
|
+
maxDate: X.maxDate,
|
|
8328
|
+
preventMinMaxNavigation: X.preventMinMaxNavigation,
|
|
8329
8329
|
internalModelValue: i.internalModelValue,
|
|
8330
|
-
range:
|
|
8331
|
-
reverseYears:
|
|
8332
|
-
vertical:
|
|
8333
|
-
yearPicker:
|
|
8334
|
-
escClose:
|
|
8330
|
+
range: X.range,
|
|
8331
|
+
reverseYears: X.reverseYears,
|
|
8332
|
+
vertical: X.vertical,
|
|
8333
|
+
yearPicker: X.yearPicker,
|
|
8334
|
+
escClose: X.escClose
|
|
8335
8335
|
}, {
|
|
8336
8336
|
onMount: he[0] || (he[0] = (Le) => Pn("monthYearInput")),
|
|
8337
8337
|
onResetFlow: h,
|
|
@@ -8342,7 +8342,7 @@ const TT = ["id", "aria-label", "onKeydown"], xT = {
|
|
|
8342
8342
|
we(Z(Nn), (Le, jn) => ({
|
|
8343
8343
|
name: Le,
|
|
8344
8344
|
fn: ce((Ei) => [
|
|
8345
|
-
oe(
|
|
8345
|
+
oe(X.$slots, Le, Ki(xn(Ei)))
|
|
8346
8346
|
])
|
|
8347
8347
|
}))
|
|
8348
8348
|
]), 1040, ["onUpdateMonthYear", "onMonthYearSelect"])) : _("", !0),
|
|
@@ -8358,9 +8358,9 @@ const TT = ["id", "aria-label", "onKeydown"], xT = {
|
|
|
8358
8358
|
"mapped-dates": Z(Zi)(de),
|
|
8359
8359
|
month: Z(L)(de),
|
|
8360
8360
|
year: Z(E)(de),
|
|
8361
|
-
onSelectDate: (Le) => Z(
|
|
8361
|
+
onSelectDate: (Le) => Z(W)(Le, !Z(Rt)(de)),
|
|
8362
8362
|
onHandleSpace: (Le) => Js(Le, !Z(Rt)(de)),
|
|
8363
|
-
onSetHoverDate: he[2] || (he[2] = (Le) => Z(
|
|
8363
|
+
onSetHoverDate: he[2] || (he[2] = (Le) => Z(V)(Le)),
|
|
8364
8364
|
onHandleScroll: (Le) => Z(xe)(Le, de),
|
|
8365
8365
|
onHandleSwipe: (Le) => Z(ve)(Le, de),
|
|
8366
8366
|
onMount: he[3] || (he[3] = (Le) => Pn("calendar")),
|
|
@@ -8369,41 +8369,41 @@ const TT = ["id", "aria-label", "onKeydown"], xT = {
|
|
|
8369
8369
|
we(Z(ot), (Le, jn) => ({
|
|
8370
8370
|
name: Le,
|
|
8371
8371
|
fn: ce((Ei) => [
|
|
8372
|
-
oe(
|
|
8372
|
+
oe(X.$slots, Le, Ki(xn({ ...Ei })))
|
|
8373
8373
|
])
|
|
8374
8374
|
}))
|
|
8375
8375
|
]), 1040, ["flow-step", "instance", "mapped-dates", "month", "year", "onSelectDate", "onHandleSpace", "onHandleScroll", "onHandleSwipe"])
|
|
8376
8376
|
], 2))), 128))
|
|
8377
8377
|
], 2),
|
|
8378
8378
|
Q("div", null, [
|
|
8379
|
-
|
|
8379
|
+
X.enableTimePicker && !X.monthPicker && !X.weekPicker ? (S(), ge(_r(X.timePickerComponent ? X.timePickerComponent : zT), pt({
|
|
8380
8380
|
key: 0,
|
|
8381
8381
|
ref_key: "timePickerRef",
|
|
8382
8382
|
ref: M
|
|
8383
8383
|
}, {
|
|
8384
|
-
is24:
|
|
8385
|
-
hoursIncrement:
|
|
8386
|
-
minutesIncrement:
|
|
8387
|
-
hoursGridIncrement:
|
|
8388
|
-
secondsIncrement:
|
|
8389
|
-
minutesGridIncrement:
|
|
8390
|
-
secondsGridIncrement:
|
|
8391
|
-
noHoursOverlay:
|
|
8392
|
-
noMinutesOverlay:
|
|
8393
|
-
noSecondsOverlay:
|
|
8394
|
-
range:
|
|
8395
|
-
filters:
|
|
8396
|
-
timePicker:
|
|
8384
|
+
is24: X.is24,
|
|
8385
|
+
hoursIncrement: X.hoursIncrement,
|
|
8386
|
+
minutesIncrement: X.minutesIncrement,
|
|
8387
|
+
hoursGridIncrement: X.hoursGridIncrement,
|
|
8388
|
+
secondsIncrement: X.secondsIncrement,
|
|
8389
|
+
minutesGridIncrement: X.minutesGridIncrement,
|
|
8390
|
+
secondsGridIncrement: X.secondsGridIncrement,
|
|
8391
|
+
noHoursOverlay: X.noHoursOverlay,
|
|
8392
|
+
noMinutesOverlay: X.noMinutesOverlay,
|
|
8393
|
+
noSecondsOverlay: X.noSecondsOverlay,
|
|
8394
|
+
range: X.range,
|
|
8395
|
+
filters: X.filters,
|
|
8396
|
+
timePicker: X.timePicker,
|
|
8397
8397
|
hours: Z(T),
|
|
8398
8398
|
minutes: Z(w),
|
|
8399
8399
|
seconds: Z(C),
|
|
8400
|
-
customProps:
|
|
8401
|
-
enableSeconds:
|
|
8402
|
-
fixedStart:
|
|
8403
|
-
fixedEnd:
|
|
8404
|
-
modelAuto:
|
|
8400
|
+
customProps: X.customProps,
|
|
8401
|
+
enableSeconds: X.enableSeconds,
|
|
8402
|
+
fixedStart: X.fixedStart,
|
|
8403
|
+
fixedEnd: X.fixedEnd,
|
|
8404
|
+
modelAuto: X.modelAuto,
|
|
8405
8405
|
internalModelValue: i.internalModelValue,
|
|
8406
|
-
escClose:
|
|
8406
|
+
escClose: X.escClose
|
|
8407
8407
|
}, {
|
|
8408
8408
|
onMount: he[4] || (he[4] = (de) => Pn("timePicker")),
|
|
8409
8409
|
"onUpdate:hours": he[5] || (he[5] = (de) => Z(O)(de)),
|
|
@@ -8415,60 +8415,60 @@ const TT = ["id", "aria-label", "onKeydown"], xT = {
|
|
|
8415
8415
|
we(Z(dn), (de, Ae) => ({
|
|
8416
8416
|
name: de,
|
|
8417
8417
|
fn: ce((Le) => [
|
|
8418
|
-
oe(
|
|
8418
|
+
oe(X.$slots, de, Ki(xn(Le)))
|
|
8419
8419
|
])
|
|
8420
8420
|
}))
|
|
8421
8421
|
]), 1040)) : _("", !0)
|
|
8422
8422
|
])
|
|
8423
8423
|
], 512),
|
|
8424
|
-
|
|
8425
|
-
oe(
|
|
8424
|
+
X.$slots["right-sidebar"] ? (S(), k("div", vT, [
|
|
8425
|
+
oe(X.$slots, "right-sidebar")
|
|
8426
8426
|
])) : _("", !0),
|
|
8427
|
-
|
|
8428
|
-
|
|
8427
|
+
X.showNowButton ? (S(), k("div", bT, [
|
|
8428
|
+
X.$slots["now-button"] ? oe(X.$slots, "now-button", {
|
|
8429
8429
|
key: 0,
|
|
8430
8430
|
selectCurrentDate: Z(Pe)
|
|
8431
8431
|
}) : _("", !0),
|
|
8432
|
-
|
|
8432
|
+
X.$slots["now-button"] ? _("", !0) : (S(), k("button", {
|
|
8433
8433
|
key: 1,
|
|
8434
8434
|
type: "button",
|
|
8435
8435
|
role: "button",
|
|
8436
8436
|
class: "dp__now_button",
|
|
8437
8437
|
onClick: he[8] || (he[8] = (...de) => Z(Pe) && Z(Pe)(...de))
|
|
8438
|
-
}, re(
|
|
8438
|
+
}, re(X.nowButtonLabel), 1))
|
|
8439
8439
|
])) : _("", !0)
|
|
8440
8440
|
], 2),
|
|
8441
|
-
!
|
|
8441
|
+
!X.autoApply || X.keepActionRow ? (S(), ge(_r(X.actionRowComponent ? X.actionRowComponent : YA), pt({ key: 2 }, {
|
|
8442
8442
|
calendarWidth: l.value,
|
|
8443
|
-
selectText:
|
|
8444
|
-
cancelText:
|
|
8443
|
+
selectText: X.selectText,
|
|
8444
|
+
cancelText: X.cancelText,
|
|
8445
8445
|
internalModelValue: i.internalModelValue,
|
|
8446
|
-
range:
|
|
8447
|
-
previewFormat:
|
|
8448
|
-
inline:
|
|
8449
|
-
monthPicker:
|
|
8450
|
-
timePicker:
|
|
8451
|
-
customProps:
|
|
8446
|
+
range: X.range,
|
|
8447
|
+
previewFormat: X.previewFormat,
|
|
8448
|
+
inline: X.inline,
|
|
8449
|
+
monthPicker: X.monthPicker,
|
|
8450
|
+
timePicker: X.timePicker,
|
|
8451
|
+
customProps: X.customProps,
|
|
8452
8452
|
multiCalendars: i.multiCalendars,
|
|
8453
8453
|
menuMount: c.value,
|
|
8454
|
-
maxTime:
|
|
8455
|
-
minTime:
|
|
8456
|
-
enableTimePicker:
|
|
8457
|
-
minDate:
|
|
8458
|
-
maxDate:
|
|
8459
|
-
multiDates:
|
|
8460
|
-
modelAuto:
|
|
8461
|
-
partialRange:
|
|
8462
|
-
ignoreTimeValidation:
|
|
8454
|
+
maxTime: X.maxTime,
|
|
8455
|
+
minTime: X.minTime,
|
|
8456
|
+
enableTimePicker: X.enableTimePicker,
|
|
8457
|
+
minDate: X.minDate,
|
|
8458
|
+
maxDate: X.maxDate,
|
|
8459
|
+
multiDates: X.multiDates,
|
|
8460
|
+
modelAuto: X.modelAuto,
|
|
8461
|
+
partialRange: X.partialRange,
|
|
8462
|
+
ignoreTimeValidation: X.ignoreTimeValidation
|
|
8463
8463
|
}, {
|
|
8464
|
-
onClosePicker: he[9] || (he[9] = (de) =>
|
|
8465
|
-
onSelectDate: he[10] || (he[10] = (de) =>
|
|
8466
|
-
onInvalidSelect: he[11] || (he[11] = (de) =>
|
|
8464
|
+
onClosePicker: he[9] || (he[9] = (de) => X.$emit("closePicker")),
|
|
8465
|
+
onSelectDate: he[10] || (he[10] = (de) => X.$emit("selectDate")),
|
|
8466
|
+
onInvalidSelect: he[11] || (he[11] = (de) => X.$emit("invalid-select"))
|
|
8467
8467
|
}), _t({ _: 2 }, [
|
|
8468
8468
|
we(Z(ri), (de, Ae) => ({
|
|
8469
8469
|
name: de,
|
|
8470
8470
|
fn: ce((Le) => [
|
|
8471
|
-
oe(
|
|
8471
|
+
oe(X.$slots, de, Ki(xn({ ...Le })))
|
|
8472
8472
|
])
|
|
8473
8473
|
}))
|
|
8474
8474
|
]), 1040)) : _("", !0)
|
|
@@ -8665,9 +8665,9 @@ const TT = ["id", "aria-label", "onKeydown"], xT = {
|
|
|
8665
8665
|
Bn(Hl, n.autoApply);
|
|
8666
8666
|
const l = q(() => n.formatLocale);
|
|
8667
8667
|
Bn(Rj, l), Bn(Bj, jr(n, "textInput")), Bn(ln, jr(n, "arrowNavigation")), Je(() => {
|
|
8668
|
-
v(n.modelValue), n.inline || (window.addEventListener("scroll", U), window.addEventListener("resize",
|
|
8668
|
+
v(n.modelValue), n.inline || (window.addEventListener("scroll", U), window.addEventListener("resize", V)), n.inline && (r.value = !0);
|
|
8669
8669
|
}), wl(() => {
|
|
8670
|
-
n.inline || (window.removeEventListener("scroll", U), window.removeEventListener("resize",
|
|
8670
|
+
n.inline || (window.removeEventListener("scroll", U), window.removeEventListener("resize", V));
|
|
8671
8671
|
});
|
|
8672
8672
|
const c = mn(o, "all", n.presetRanges), g = mn(o, "input");
|
|
8673
8673
|
Fe(
|
|
@@ -8734,7 +8734,7 @@ const TT = ["id", "aria-label", "onKeydown"], xT = {
|
|
|
8734
8734
|
const T = q(() => n.dark ? "dp__theme_dark" : "dp__theme_light"), w = q(() => Object.assign(bA(), n.textInputOptions)), C = q(() => SA(n.ariaLabels));
|
|
8735
8735
|
Bn(un, C);
|
|
8736
8736
|
const Y = q(() => OA(n.filters)), G = q(() => {
|
|
8737
|
-
const
|
|
8737
|
+
const J = (me) => {
|
|
8738
8738
|
const be = {
|
|
8739
8739
|
hours: Mi(/* @__PURE__ */ new Date()),
|
|
8740
8740
|
minutes: ui(/* @__PURE__ */ new Date()),
|
|
@@ -8742,19 +8742,19 @@ const TT = ["id", "aria-label", "onKeydown"], xT = {
|
|
|
8742
8742
|
};
|
|
8743
8743
|
return Object.assign(be, me);
|
|
8744
8744
|
};
|
|
8745
|
-
return n.range ? n.startTime && Array.isArray(n.startTime) ? [
|
|
8746
|
-
}),
|
|
8745
|
+
return n.range ? n.startTime && Array.isArray(n.startTime) ? [J(n.startTime[0]), J(n.startTime[1])] : null : n.startTime && !Array.isArray(n.startTime) ? J(n.startTime) : null;
|
|
8746
|
+
}), W = q(() => n.multiCalendars === null ? 0 : typeof n.multiCalendars == "boolean" ? n.multiCalendars ? 2 : 0 : +n.multiCalendars >= 2 ? +n.multiCalendars : 2), U = () => {
|
|
8747
8747
|
r.value && (n.closeOnScroll ? xe() : n.autoPosition ? D() : window.removeEventListener("scroll", U));
|
|
8748
|
-
},
|
|
8748
|
+
}, V = () => {
|
|
8749
8749
|
r.value && D();
|
|
8750
8750
|
}, P = () => {
|
|
8751
8751
|
!n.disabled && !n.readonly && (d(), r.value = !0, Ti().then(() => {
|
|
8752
8752
|
D(), r.value && t("open");
|
|
8753
8753
|
}), r.value || ue(), v(n.modelValue));
|
|
8754
|
-
},
|
|
8754
|
+
}, $ = () => {
|
|
8755
8755
|
x.value = "", ue(), t("update:modelValue", null), t("cleared"), xe();
|
|
8756
8756
|
}, ie = () => {
|
|
8757
|
-
const { validate:
|
|
8757
|
+
const { validate: J } = Pj(
|
|
8758
8758
|
n.minDate,
|
|
8759
8759
|
n.maxDate,
|
|
8760
8760
|
n.disabledDates,
|
|
@@ -8763,86 +8763,86 @@ const TT = ["id", "aria-label", "onKeydown"], xT = {
|
|
|
8763
8763
|
n.disabledWeekDays,
|
|
8764
8764
|
n.yearRange
|
|
8765
8765
|
), me = p.value;
|
|
8766
|
-
return !me || !Array.isArray(me) &&
|
|
8767
|
-
},
|
|
8766
|
+
return !me || !Array.isArray(me) && J(me) ? !0 : Array.isArray(me) ? me.length === 2 && J(me[0]) && J(me[1]) ? !0 : !!J(me[0]) : !1;
|
|
8767
|
+
}, F = () => {
|
|
8768
8768
|
A() && ie() ? (m(), xe()) : t("invalid-select", p.value);
|
|
8769
|
-
}, ee = (
|
|
8770
|
-
m(), n.closeOnAutoApply &&
|
|
8771
|
-
}, le = (
|
|
8772
|
-
n.autoApply && (!n.enableTimePicker || n.monthPicker || n.yearPicker || n.ignoreTimeValidation || Ku(p.value, n.maxTime, n.minTime, n.maxDate, n.minDate)) && ie() && (n.range && Array.isArray(p.value) ? (n.partialRange || p.value.length === 2) && ee(
|
|
8769
|
+
}, ee = (J) => {
|
|
8770
|
+
m(), n.closeOnAutoApply && !J && xe();
|
|
8771
|
+
}, le = (J = !1) => {
|
|
8772
|
+
n.autoApply && (!n.enableTimePicker || n.monthPicker || n.yearPicker || n.ignoreTimeValidation || Ku(p.value, n.maxTime, n.minTime, n.maxDate, n.minDate)) && ie() && (n.range && Array.isArray(p.value) ? (n.partialRange || p.value.length === 2) && ee(J) : ee(J));
|
|
8773
8773
|
}, ue = () => {
|
|
8774
8774
|
p.value = null;
|
|
8775
8775
|
}, xe = () => {
|
|
8776
8776
|
n.inline || (r.value && (r.value = !1, h(!1), O(!1), I(), t("closed"), d(), x.value && v(a.value)), ue(), M.value && M.value.focusInput());
|
|
8777
|
-
}, Ve = (
|
|
8778
|
-
if (
|
|
8777
|
+
}, Ve = (J, me) => {
|
|
8778
|
+
if (!J) {
|
|
8779
8779
|
p.value = null;
|
|
8780
8780
|
return;
|
|
8781
8781
|
}
|
|
8782
|
-
p.value =
|
|
8782
|
+
p.value = J, me && (F(), t("textSubmit"));
|
|
8783
8783
|
}, ve = () => {
|
|
8784
8784
|
n.autoApply && Ku(p.value, n.maxTime, n.minTime, n.maxDate, n.minDate) && m();
|
|
8785
|
-
}, Xe = () => r.value ? xe() : P(), Pe = (
|
|
8786
|
-
p.value =
|
|
8785
|
+
}, Xe = () => r.value ? xe() : P(), Pe = (J) => {
|
|
8786
|
+
p.value = J;
|
|
8787
8787
|
};
|
|
8788
8788
|
return QT(s, M, xe), e({
|
|
8789
8789
|
closeMenu: xe,
|
|
8790
|
-
selectDate:
|
|
8791
|
-
clearValue:
|
|
8790
|
+
selectDate: F,
|
|
8791
|
+
clearValue: $,
|
|
8792
8792
|
openMenu: P,
|
|
8793
8793
|
onScroll: U,
|
|
8794
8794
|
formatInputValue: b,
|
|
8795
8795
|
updateInternalModelValue: Pe
|
|
8796
|
-
}), (
|
|
8796
|
+
}), (J, me) => (S(), k("div", {
|
|
8797
8797
|
class: ne(Z(z))
|
|
8798
8798
|
}, [
|
|
8799
8799
|
De(NA, pt({
|
|
8800
8800
|
ref_key: "inputRef",
|
|
8801
8801
|
ref: M
|
|
8802
8802
|
}, {
|
|
8803
|
-
placeholder:
|
|
8804
|
-
hideInputIcon:
|
|
8805
|
-
readonly:
|
|
8806
|
-
disabled:
|
|
8807
|
-
inputClassName:
|
|
8808
|
-
clearable:
|
|
8809
|
-
state:
|
|
8810
|
-
inline:
|
|
8811
|
-
inlineWithInput:
|
|
8812
|
-
textInput:
|
|
8803
|
+
placeholder: J.placeholder,
|
|
8804
|
+
hideInputIcon: J.hideInputIcon,
|
|
8805
|
+
readonly: J.readonly,
|
|
8806
|
+
disabled: J.disabled,
|
|
8807
|
+
inputClassName: J.inputClassName,
|
|
8808
|
+
clearable: J.clearable,
|
|
8809
|
+
state: J.state,
|
|
8810
|
+
inline: J.inline,
|
|
8811
|
+
inlineWithInput: J.inlineWithInput,
|
|
8812
|
+
textInput: J.textInput,
|
|
8813
8813
|
textInputOptions: Z(w),
|
|
8814
|
-
range:
|
|
8814
|
+
range: J.range,
|
|
8815
8815
|
isMenuOpen: r.value,
|
|
8816
8816
|
pattern: Z(f),
|
|
8817
|
-
autoApply:
|
|
8818
|
-
uid:
|
|
8819
|
-
required:
|
|
8820
|
-
name:
|
|
8821
|
-
autocomplete:
|
|
8817
|
+
autoApply: J.autoApply,
|
|
8818
|
+
uid: J.uid,
|
|
8819
|
+
required: J.required,
|
|
8820
|
+
name: J.name,
|
|
8821
|
+
autocomplete: J.autocomplete
|
|
8822
8822
|
}, {
|
|
8823
8823
|
"input-value": Z(x),
|
|
8824
8824
|
"onUpdate:input-value": me[0] || (me[0] = (be) => An(x) ? x.value = be : null),
|
|
8825
|
-
onClear:
|
|
8825
|
+
onClear: $,
|
|
8826
8826
|
onOpen: P,
|
|
8827
8827
|
onSetInputDate: Ve,
|
|
8828
8828
|
onSetEmptyDate: Z(m),
|
|
8829
|
-
onSelectDate:
|
|
8829
|
+
onSelectDate: F,
|
|
8830
8830
|
onToggle: Xe,
|
|
8831
8831
|
onClose: xe,
|
|
8832
|
-
onFocus: me[1] || (me[1] = (be) =>
|
|
8833
|
-
onBlur: me[2] || (me[2] = (be) =>
|
|
8832
|
+
onFocus: me[1] || (me[1] = (be) => J.$emit("focus")),
|
|
8833
|
+
onBlur: me[2] || (me[2] = (be) => J.$emit("blur"))
|
|
8834
8834
|
}), _t({ _: 2 }, [
|
|
8835
8835
|
we(Z(g), (be, ot) => ({
|
|
8836
8836
|
name: be,
|
|
8837
8837
|
fn: ce((ri) => [
|
|
8838
|
-
oe(
|
|
8838
|
+
oe(J.$slots, be, Ki(xn(ri)))
|
|
8839
8839
|
])
|
|
8840
8840
|
}))
|
|
8841
8841
|
]), 1040, ["input-value", "onSetEmptyDate"]),
|
|
8842
8842
|
r.value ? (S(), ge(hi, {
|
|
8843
8843
|
key: 0,
|
|
8844
|
-
to:
|
|
8845
|
-
disabled:
|
|
8844
|
+
to: J.teleport,
|
|
8845
|
+
disabled: J.inline
|
|
8846
8846
|
}, [
|
|
8847
8847
|
r.value ? (S(), ge(OT, pt({
|
|
8848
8848
|
key: 0,
|
|
@@ -8851,111 +8851,111 @@ const TT = ["id", "aria-label", "onKeydown"], xT = {
|
|
|
8851
8851
|
class: Z(T),
|
|
8852
8852
|
style: Z(N)
|
|
8853
8853
|
}, {
|
|
8854
|
-
weekNumbers:
|
|
8855
|
-
weekStart:
|
|
8856
|
-
disableMonthYearSelect:
|
|
8857
|
-
menuClassName:
|
|
8858
|
-
calendarClassName:
|
|
8859
|
-
yearRange:
|
|
8860
|
-
range:
|
|
8861
|
-
multiCalendars: Z(
|
|
8862
|
-
multiCalendarsSolo:
|
|
8863
|
-
multiStatic:
|
|
8864
|
-
calendarCellClassName:
|
|
8865
|
-
enableTimePicker:
|
|
8866
|
-
is24:
|
|
8867
|
-
hoursIncrement:
|
|
8868
|
-
minutesIncrement:
|
|
8869
|
-
hoursGridIncrement:
|
|
8870
|
-
minutesGridIncrement:
|
|
8871
|
-
minDate:
|
|
8872
|
-
maxDate:
|
|
8873
|
-
autoApply:
|
|
8874
|
-
selectText:
|
|
8875
|
-
cancelText:
|
|
8854
|
+
weekNumbers: J.weekNumbers,
|
|
8855
|
+
weekStart: J.weekStart,
|
|
8856
|
+
disableMonthYearSelect: J.disableMonthYearSelect,
|
|
8857
|
+
menuClassName: J.menuClassName,
|
|
8858
|
+
calendarClassName: J.calendarClassName,
|
|
8859
|
+
yearRange: J.yearRange,
|
|
8860
|
+
range: J.range,
|
|
8861
|
+
multiCalendars: Z(W),
|
|
8862
|
+
multiCalendarsSolo: J.multiCalendarsSolo,
|
|
8863
|
+
multiStatic: J.multiStatic,
|
|
8864
|
+
calendarCellClassName: J.calendarCellClassName,
|
|
8865
|
+
enableTimePicker: J.enableTimePicker,
|
|
8866
|
+
is24: J.is24,
|
|
8867
|
+
hoursIncrement: J.hoursIncrement,
|
|
8868
|
+
minutesIncrement: J.minutesIncrement,
|
|
8869
|
+
hoursGridIncrement: J.hoursGridIncrement,
|
|
8870
|
+
minutesGridIncrement: J.minutesGridIncrement,
|
|
8871
|
+
minDate: J.minDate,
|
|
8872
|
+
maxDate: J.maxDate,
|
|
8873
|
+
autoApply: J.autoApply,
|
|
8874
|
+
selectText: J.selectText,
|
|
8875
|
+
cancelText: J.cancelText,
|
|
8876
8876
|
previewFormat: Z(L),
|
|
8877
|
-
locale:
|
|
8878
|
-
weekNumName:
|
|
8879
|
-
disabledDates:
|
|
8877
|
+
locale: J.locale,
|
|
8878
|
+
weekNumName: J.weekNumName,
|
|
8879
|
+
disabledDates: J.disabledDates,
|
|
8880
8880
|
filters: Z(Y),
|
|
8881
|
-
minTime:
|
|
8882
|
-
maxTime:
|
|
8883
|
-
inline:
|
|
8881
|
+
minTime: J.minTime,
|
|
8882
|
+
maxTime: J.maxTime,
|
|
8883
|
+
inline: J.inline,
|
|
8884
8884
|
openOnTop: Z(j),
|
|
8885
|
-
monthPicker:
|
|
8886
|
-
timePicker:
|
|
8887
|
-
monthNameFormat:
|
|
8888
|
-
startDate:
|
|
8885
|
+
monthPicker: J.monthPicker,
|
|
8886
|
+
timePicker: J.timePicker,
|
|
8887
|
+
monthNameFormat: J.monthNameFormat,
|
|
8888
|
+
startDate: J.startDate,
|
|
8889
8889
|
startTime: Z(G),
|
|
8890
|
-
monthYearComponent:
|
|
8891
|
-
timePickerComponent:
|
|
8892
|
-
actionRowComponent:
|
|
8893
|
-
customProps:
|
|
8894
|
-
hideOffsetDates:
|
|
8895
|
-
autoRange:
|
|
8896
|
-
noToday:
|
|
8897
|
-
noHoursOverlay:
|
|
8898
|
-
noMinutesOverlay:
|
|
8899
|
-
disabledWeekDays:
|
|
8900
|
-
allowedDates:
|
|
8901
|
-
showNowButton:
|
|
8902
|
-
nowButtonLabel:
|
|
8903
|
-
monthChangeOnScroll:
|
|
8904
|
-
markers:
|
|
8905
|
-
uid:
|
|
8906
|
-
modeHeight:
|
|
8907
|
-
enableSeconds:
|
|
8908
|
-
secondsIncrement:
|
|
8909
|
-
secondsGridIncrement:
|
|
8910
|
-
noSecondsOverlay:
|
|
8911
|
-
escClose:
|
|
8912
|
-
spaceConfirm:
|
|
8913
|
-
monthChangeOnArrows:
|
|
8914
|
-
textInput:
|
|
8915
|
-
disabled:
|
|
8916
|
-
readonly:
|
|
8917
|
-
multiDates:
|
|
8918
|
-
presetRanges:
|
|
8919
|
-
flow:
|
|
8920
|
-
preventMinMaxNavigation:
|
|
8921
|
-
minRange:
|
|
8922
|
-
maxRange:
|
|
8923
|
-
fixedStart:
|
|
8924
|
-
fixedEnd:
|
|
8925
|
-
multiDatesLimit:
|
|
8926
|
-
reverseYears:
|
|
8927
|
-
keepActionRow:
|
|
8928
|
-
weekPicker:
|
|
8929
|
-
noSwipe:
|
|
8930
|
-
vertical:
|
|
8931
|
-
arrowNavigation:
|
|
8932
|
-
yearPicker:
|
|
8933
|
-
disableTimeRangeValidation:
|
|
8934
|
-
dayNames:
|
|
8935
|
-
modelAuto:
|
|
8936
|
-
highlight:
|
|
8937
|
-
highlightWeekDays:
|
|
8938
|
-
highlightDisabledDays:
|
|
8939
|
-
partialRange:
|
|
8940
|
-
teleportCenter:
|
|
8941
|
-
ignoreTimeValidation:
|
|
8942
|
-
dayClass:
|
|
8890
|
+
monthYearComponent: J.monthYearComponent,
|
|
8891
|
+
timePickerComponent: J.timePickerComponent,
|
|
8892
|
+
actionRowComponent: J.actionRowComponent,
|
|
8893
|
+
customProps: J.customProps,
|
|
8894
|
+
hideOffsetDates: J.hideOffsetDates,
|
|
8895
|
+
autoRange: J.autoRange,
|
|
8896
|
+
noToday: J.noToday,
|
|
8897
|
+
noHoursOverlay: J.noHoursOverlay,
|
|
8898
|
+
noMinutesOverlay: J.noMinutesOverlay,
|
|
8899
|
+
disabledWeekDays: J.disabledWeekDays,
|
|
8900
|
+
allowedDates: J.allowedDates,
|
|
8901
|
+
showNowButton: J.showNowButton,
|
|
8902
|
+
nowButtonLabel: J.nowButtonLabel,
|
|
8903
|
+
monthChangeOnScroll: J.monthChangeOnScroll,
|
|
8904
|
+
markers: J.markers,
|
|
8905
|
+
uid: J.uid,
|
|
8906
|
+
modeHeight: J.modeHeight,
|
|
8907
|
+
enableSeconds: J.enableSeconds,
|
|
8908
|
+
secondsIncrement: J.secondsIncrement,
|
|
8909
|
+
secondsGridIncrement: J.secondsGridIncrement,
|
|
8910
|
+
noSecondsOverlay: J.noSecondsOverlay,
|
|
8911
|
+
escClose: J.escClose,
|
|
8912
|
+
spaceConfirm: J.spaceConfirm,
|
|
8913
|
+
monthChangeOnArrows: J.monthChangeOnArrows,
|
|
8914
|
+
textInput: J.textInput,
|
|
8915
|
+
disabled: J.disabled,
|
|
8916
|
+
readonly: J.readonly,
|
|
8917
|
+
multiDates: J.multiDates,
|
|
8918
|
+
presetRanges: J.presetRanges,
|
|
8919
|
+
flow: J.flow,
|
|
8920
|
+
preventMinMaxNavigation: J.preventMinMaxNavigation,
|
|
8921
|
+
minRange: J.minRange,
|
|
8922
|
+
maxRange: J.maxRange,
|
|
8923
|
+
fixedStart: J.fixedStart,
|
|
8924
|
+
fixedEnd: J.fixedEnd,
|
|
8925
|
+
multiDatesLimit: J.multiDatesLimit,
|
|
8926
|
+
reverseYears: J.reverseYears,
|
|
8927
|
+
keepActionRow: J.keepActionRow,
|
|
8928
|
+
weekPicker: J.weekPicker,
|
|
8929
|
+
noSwipe: J.noSwipe,
|
|
8930
|
+
vertical: J.vertical,
|
|
8931
|
+
arrowNavigation: J.arrowNavigation,
|
|
8932
|
+
yearPicker: J.yearPicker,
|
|
8933
|
+
disableTimeRangeValidation: J.disableTimeRangeValidation,
|
|
8934
|
+
dayNames: J.dayNames,
|
|
8935
|
+
modelAuto: J.modelAuto,
|
|
8936
|
+
highlight: J.highlight,
|
|
8937
|
+
highlightWeekDays: J.highlightWeekDays,
|
|
8938
|
+
highlightDisabledDays: J.highlightDisabledDays,
|
|
8939
|
+
partialRange: J.partialRange,
|
|
8940
|
+
teleportCenter: J.teleportCenter,
|
|
8941
|
+
ignoreTimeValidation: J.ignoreTimeValidation,
|
|
8942
|
+
dayClass: J.dayClass
|
|
8943
8943
|
}, {
|
|
8944
8944
|
internalModelValue: Z(p),
|
|
8945
8945
|
"onUpdate:internalModelValue": me[3] || (me[3] = (be) => An(p) ? p.value = be : null),
|
|
8946
8946
|
onClosePicker: xe,
|
|
8947
|
-
onSelectDate:
|
|
8947
|
+
onSelectDate: F,
|
|
8948
8948
|
onDpOpen: Z(y),
|
|
8949
8949
|
onAutoApply: le,
|
|
8950
8950
|
onTimeUpdate: ve,
|
|
8951
|
-
onFlowStep: me[4] || (me[4] = (be) =>
|
|
8952
|
-
onUpdateMonthYear: me[5] || (me[5] = (be) =>
|
|
8953
|
-
onInvalidSelect: me[6] || (me[6] = (be) =>
|
|
8951
|
+
onFlowStep: me[4] || (me[4] = (be) => J.$emit("flow-step", be)),
|
|
8952
|
+
onUpdateMonthYear: me[5] || (me[5] = (be) => J.$emit("updateMonthYear", be)),
|
|
8953
|
+
onInvalidSelect: me[6] || (me[6] = (be) => J.$emit("invalid-select", Z(p)))
|
|
8954
8954
|
}), _t({ _: 2 }, [
|
|
8955
8955
|
we(Z(c), (be, ot) => ({
|
|
8956
8956
|
name: be,
|
|
8957
8957
|
fn: ce((ri) => [
|
|
8958
|
-
oe(
|
|
8958
|
+
oe(J.$slots, be, Ki(xn({ ...ri })))
|
|
8959
8959
|
])
|
|
8960
8960
|
}))
|
|
8961
8961
|
]), 1040, ["class", "style", "internalModelValue", "onDpOpen"])) : _("", !0)
|
|
@@ -12853,7 +12853,7 @@ class _n extends Bi {
|
|
|
12853
12853
|
}
|
|
12854
12854
|
const L = ke(o.ticks.maxTicksLimit, l), E = Math.max(1, Math.ceil(l / L));
|
|
12855
12855
|
for (p = 0; p < l; p += E) {
|
|
12856
|
-
const T = r.setContext(this.getContext(p)), w = T.lineWidth, C = T.color, Y = T.borderDash || [], G = T.borderDashOffset,
|
|
12856
|
+
const T = r.setContext(this.getContext(p)), w = T.lineWidth, C = T.color, Y = T.borderDash || [], G = T.borderDashOffset, W = T.tickWidth, U = T.tickColor, V = T.tickBorderDash || [], P = T.tickBorderDashOffset;
|
|
12857
12857
|
x = Ib(this, p, s), x !== void 0 && (v = yn(n, x, w), M ? m = b = h = z = v : A = I = O = f = v, g.push({
|
|
12858
12858
|
tx1: m,
|
|
12859
12859
|
ty1: A,
|
|
@@ -12867,9 +12867,9 @@ class _n extends Bi {
|
|
|
12867
12867
|
color: C,
|
|
12868
12868
|
borderDash: Y,
|
|
12869
12869
|
borderDashOffset: G,
|
|
12870
|
-
tickWidth:
|
|
12870
|
+
tickWidth: W,
|
|
12871
12871
|
tickColor: U,
|
|
12872
|
-
tickBorderDash:
|
|
12872
|
+
tickBorderDash: V,
|
|
12873
12873
|
tickBorderDashOffset: P
|
|
12874
12874
|
}));
|
|
12875
12875
|
}
|
|
@@ -12912,12 +12912,12 @@ class _n extends Bi {
|
|
|
12912
12912
|
const T = r.setContext(this.getContext(d));
|
|
12913
12913
|
I = this.getPixelForTick(d) + r.labelOffset, h = this._resolveTickFontOptions(d), O = h.lineHeight, z = it(v) ? v.length : 1;
|
|
12914
12914
|
const w = z / 2, C = T.color, Y = T.textStrokeColor, G = T.textStrokeWidth;
|
|
12915
|
-
let
|
|
12916
|
-
a ? (m = I, b === "inner" && (d === p - 1 ?
|
|
12915
|
+
let W = b;
|
|
12916
|
+
a ? (m = I, b === "inner" && (d === p - 1 ? W = this.options.reverse ? "left" : "right" : d === 0 ? W = this.options.reverse ? "right" : "left" : W = "center"), o === "top" ? u === "near" || D !== 0 ? f = -z * O + O / 2 : u === "center" ? f = -E.highest.height / 2 - w * O + O : f = -E.highest.height + O / 2 : u === "near" || D !== 0 ? f = O / 2 : u === "center" ? f = E.highest.height / 2 - w * O : f = E.highest.height - z * O, c && (f *= -1)) : (A = I, f = (1 - z) * O / 2);
|
|
12917
12917
|
let U;
|
|
12918
12918
|
if (T.showLabelBackdrop) {
|
|
12919
|
-
const
|
|
12920
|
-
let ie = A + f -
|
|
12919
|
+
const V = oi(T.backdropPadding), P = E.heights[d], $ = E.widths[d];
|
|
12920
|
+
let ie = A + f - V.top, F = m - V.left;
|
|
12921
12921
|
switch (L) {
|
|
12922
12922
|
case "middle":
|
|
12923
12923
|
ie -= P / 2;
|
|
@@ -12928,17 +12928,17 @@ class _n extends Bi {
|
|
|
12928
12928
|
}
|
|
12929
12929
|
switch (b) {
|
|
12930
12930
|
case "center":
|
|
12931
|
-
|
|
12931
|
+
F -= $ / 2;
|
|
12932
12932
|
break;
|
|
12933
12933
|
case "right":
|
|
12934
|
-
|
|
12934
|
+
F -= $;
|
|
12935
12935
|
break;
|
|
12936
12936
|
}
|
|
12937
12937
|
U = {
|
|
12938
|
-
left:
|
|
12938
|
+
left: F,
|
|
12939
12939
|
top: ie,
|
|
12940
|
-
width:
|
|
12941
|
-
height: P +
|
|
12940
|
+
width: $ + V.width,
|
|
12941
|
+
height: P + V.height,
|
|
12942
12942
|
color: T.backdropColor
|
|
12943
12943
|
};
|
|
12944
12944
|
}
|
|
@@ -12950,7 +12950,7 @@ class _n extends Bi {
|
|
|
12950
12950
|
strokeColor: Y,
|
|
12951
12951
|
strokeWidth: G,
|
|
12952
12952
|
textOffset: f,
|
|
12953
|
-
textAlign:
|
|
12953
|
+
textAlign: W,
|
|
12954
12954
|
textBaseline: L,
|
|
12955
12955
|
translation: [m, A],
|
|
12956
12956
|
backdrop: U
|
|
@@ -18966,11 +18966,11 @@ function bw(i, e, t) {
|
|
|
18966
18966
|
groupOptions: C,
|
|
18967
18967
|
groupHideEmpty: Y,
|
|
18968
18968
|
groupSelect: G,
|
|
18969
|
-
onCreate:
|
|
18969
|
+
onCreate: W,
|
|
18970
18970
|
disabledProp: U,
|
|
18971
|
-
searchStart:
|
|
18971
|
+
searchStart: V,
|
|
18972
18972
|
searchFilter: P
|
|
18973
|
-
} = Wt(i),
|
|
18973
|
+
} = Wt(i), $ = tr().proxy, ie = t.iv, F = t.ev, ee = t.search, le = t.clearSearch, ue = t.update, xe = t.pointer, Ve = t.clearPointer, ve = t.focus, Xe = t.deactivate, Pe = t.close, J = t.localize, me = K([]), be = K([]), ot = K(!1), ri = K(null), dn = K(w.value && a.value === -1 ? 10 : a.value), Nn = q(() => M.value || u.value || !1), B = q(() => c.value !== void 0 ? c.value : g.value !== void 0 ? g.value : !0), te = q(() => {
|
|
18974
18974
|
if (E.value) {
|
|
18975
18975
|
let R = yt.value || /* istanbul ignore next */
|
|
18976
18976
|
[], ae = [];
|
|
@@ -19030,7 +19030,7 @@ function bw(i, e, t) {
|
|
|
19030
19030
|
case "tags":
|
|
19031
19031
|
return !Di(ie.value) && ie.value.length > 0;
|
|
19032
19032
|
}
|
|
19033
|
-
}), yi = q(() => j !== void 0 && j.value !== void 0 ? j.value(ie.value,
|
|
19033
|
+
}), yi = q(() => j !== void 0 && j.value !== void 0 ? j.value(ie.value, $) : ie.value && ie.value.length > 1 ? `${ie.value.length} options selected` : "1 option selected"), Ws = q(() => !te.value.length && !ot.value && !Zi.value.length), Hs = q(() => te.value.length > 0 && ze.value.length == 0 && (ee.value && E.value || !E.value)), Zi = q(() => Nn.value === !1 || !ee.value ? [] : ur(ee.value) !== -1 ? [] : [{
|
|
19034
19034
|
[A.value]: ee.value,
|
|
19035
19035
|
[Ft.value]: ee.value,
|
|
19036
19036
|
[l.value]: ee.value,
|
|
@@ -19053,7 +19053,7 @@ function bw(i, e, t) {
|
|
|
19053
19053
|
ue(ie.value.concat(R));
|
|
19054
19054
|
break;
|
|
19055
19055
|
}
|
|
19056
|
-
e.emit("select", sr(R), R,
|
|
19056
|
+
e.emit("select", sr(R), R, $);
|
|
19057
19057
|
}, Gi = (R) => {
|
|
19058
19058
|
switch (typeof R != "object" && (R = Xt(R)), o.value) {
|
|
19059
19059
|
case "single":
|
|
@@ -19064,7 +19064,7 @@ function bw(i, e, t) {
|
|
|
19064
19064
|
ue(Array.isArray(R) ? ie.value.filter((ae) => R.map((Oe) => Oe[A.value]).indexOf(ae[A.value]) === -1) : ie.value.filter((ae) => ae[A.value] != R[A.value]));
|
|
19065
19065
|
break;
|
|
19066
19066
|
}
|
|
19067
|
-
e.emit("deselect", sr(R), R,
|
|
19067
|
+
e.emit("deselect", sr(R), R, $);
|
|
19068
19068
|
}, sr = (R) => N.value ? R : R[A.value], Mr = (R) => {
|
|
19069
19069
|
Gi(R);
|
|
19070
19070
|
}, Js = (R, ae) => {
|
|
@@ -19074,7 +19074,7 @@ function bw(i, e, t) {
|
|
|
19074
19074
|
}
|
|
19075
19075
|
Mr(R);
|
|
19076
19076
|
}, Pn = () => {
|
|
19077
|
-
e.emit("clear",
|
|
19077
|
+
e.emit("clear", $), ue(Fs.value);
|
|
19078
19078
|
}, Jt = (R) => {
|
|
19079
19079
|
if (R.group !== void 0)
|
|
19080
19080
|
return o.value === "single" ? !1 : Ei(R[C.value]) && R[C.value].length;
|
|
@@ -19085,9 +19085,9 @@ function bw(i, e, t) {
|
|
|
19085
19085
|
case "multiple":
|
|
19086
19086
|
return !Di(ie.value) && ie.value.map((ae) => ae[A.value]).indexOf(R[A.value]) !== -1;
|
|
19087
19087
|
}
|
|
19088
|
-
}, Vi = (R) => R[U.value] === !0, yo = () => O === void 0 || O.value === -1 || !Ri.value && O.value > 0 ? !1 : ie.value.length >= O.value,
|
|
19088
|
+
}, Vi = (R) => R[U.value] === !0, yo = () => O === void 0 || O.value === -1 || !Ri.value && O.value > 0 ? !1 : ie.value.length >= O.value, X = (R) => {
|
|
19089
19089
|
if (!Vi(R)) {
|
|
19090
|
-
if (
|
|
19090
|
+
if (W && W.value && !Jt(R) && R.__CREATE__ && (R = { ...R }, delete R.__CREATE__, R = W.value(R, $), R instanceof Promise)) {
|
|
19091
19091
|
ot.value = !0, R.then((ae) => {
|
|
19092
19092
|
ot.value = !1, he(ae);
|
|
19093
19093
|
});
|
|
@@ -19110,7 +19110,7 @@ function bw(i, e, t) {
|
|
|
19110
19110
|
return;
|
|
19111
19111
|
}
|
|
19112
19112
|
if (yo()) {
|
|
19113
|
-
e.emit("max",
|
|
19113
|
+
e.emit("max", $);
|
|
19114
19114
|
return;
|
|
19115
19115
|
}
|
|
19116
19116
|
R && (Ae(R), $t(R)), m.value && le(), s.value && Ve(), f.value && Pe();
|
|
@@ -19121,7 +19121,7 @@ function bw(i, e, t) {
|
|
|
19121
19121
|
return;
|
|
19122
19122
|
}
|
|
19123
19123
|
if (yo()) {
|
|
19124
|
-
e.emit("max",
|
|
19124
|
+
e.emit("max", $);
|
|
19125
19125
|
return;
|
|
19126
19126
|
}
|
|
19127
19127
|
R && Ae(R), m.value && le(), R && $t(R), s.value && Ve(), f.value && Pe();
|
|
@@ -19141,7 +19141,7 @@ function bw(i, e, t) {
|
|
|
19141
19141
|
f.value && Xe();
|
|
19142
19142
|
}
|
|
19143
19143
|
}, Ae = (R) => {
|
|
19144
|
-
Xt(R[A.value]) === void 0 && Nn.value && (e.emit("tag", R[A.value],
|
|
19144
|
+
Xt(R[A.value]) === void 0 && Nn.value && (e.emit("tag", R[A.value], $), e.emit("option", R[A.value], $), e.emit("create", R[A.value], $), B.value && cr(R), le());
|
|
19145
19145
|
}, Le = () => {
|
|
19146
19146
|
o.value !== "single" && $t(ze.value.filter((R) => !R.disabled && !Jt(R)));
|
|
19147
19147
|
}, jn = (R) => R.find((ae) => !Jt(ae) && !ae[U.value]) === void 0, Ei = (R) => R.find((ae) => !Jt(ae)) === void 0, Xt = (R) => te.value[te.value.map((ae) => String(ae[A.value])).indexOf(String(R))], ur = (R, ae = !0) => te.value.map((Oe) => parseInt(Oe[Ft.value]) == Oe[Ft.value] ? parseInt(Oe[Ft.value]) : Oe[Ft.value]).indexOf(
|
|
@@ -19155,8 +19155,8 @@ function bw(i, e, t) {
|
|
|
19155
19155
|
if (ee.value && x.value) {
|
|
19156
19156
|
let ct = P.value;
|
|
19157
19157
|
ct || (ct = (Io, I3) => {
|
|
19158
|
-
let _c = bM(
|
|
19159
|
-
return
|
|
19158
|
+
let _c = bM(J(Io[Ft.value]), z.value);
|
|
19159
|
+
return V.value ? _c.startsWith(bM(ee.value, z.value)) : _c.indexOf(bM(ee.value, z.value)) !== -1;
|
|
19160
19160
|
}), Oe = Oe.filter(ct);
|
|
19161
19161
|
}
|
|
19162
19162
|
return s.value && ae && (Oe = Oe.filter((ct) => !lr(ct))), Oe;
|
|
@@ -19167,9 +19167,9 @@ function bw(i, e, t) {
|
|
|
19167
19167
|
return { [A.value]: Oe, [Ft.value]: ct, [l.value]: ct };
|
|
19168
19168
|
})), ae = ae.map((Oe) => typeof Oe == "object" ? Oe : { [A.value]: Oe, [Ft.value]: Oe, [l.value]: Oe }), ae;
|
|
19169
19169
|
}, gr = () => {
|
|
19170
|
-
Di(
|
|
19170
|
+
Di(F.value) || (ie.value = Nr(F.value));
|
|
19171
19171
|
}, dr = (R) => (ot.value = !0, new Promise((ae, Oe) => {
|
|
19172
|
-
n.value(ee.value,
|
|
19172
|
+
n.value(ee.value, $).then((ct) => {
|
|
19173
19173
|
be.value = ct || [], typeof R == "function" && R(ct), ot.value = !1;
|
|
19174
19174
|
}).catch((ct) => {
|
|
19175
19175
|
console.error(ct), be.value = [], ot.value = !1;
|
|
@@ -19182,14 +19182,14 @@ function bw(i, e, t) {
|
|
|
19182
19182
|
let R = Xt(ie.value[A.value]);
|
|
19183
19183
|
if (R !== void 0) {
|
|
19184
19184
|
let ae = R[l.value];
|
|
19185
|
-
ie.value[l.value] = ae, N.value && (
|
|
19185
|
+
ie.value[l.value] = ae, N.value && (F.value[l.value] = ae);
|
|
19186
19186
|
}
|
|
19187
19187
|
} else
|
|
19188
19188
|
ie.value.forEach((R, ae) => {
|
|
19189
19189
|
let Oe = Xt(ie.value[ae][A.value]);
|
|
19190
19190
|
if (Oe !== void 0) {
|
|
19191
19191
|
let ct = Oe[l.value];
|
|
19192
|
-
ie.value[ae][l.value] = ct, N.value && (
|
|
19192
|
+
ie.value[ae][l.value] = ct, N.value && (F.value[ae][l.value] = ct);
|
|
19193
19193
|
}
|
|
19194
19194
|
});
|
|
19195
19195
|
}, eh = (R) => {
|
|
@@ -19205,7 +19205,7 @@ function bw(i, e, t) {
|
|
|
19205
19205
|
}), Uc = () => {
|
|
19206
19206
|
ri.value = Fe(ee, (R) => {
|
|
19207
19207
|
R.length < p.value || !R && p.value !== 0 || (ot.value = !0, v.value && (be.value = []), setTimeout(() => {
|
|
19208
|
-
R == ee.value && n.value(ee.value,
|
|
19208
|
+
R == ee.value && n.value(ee.value, $).then((ae) => {
|
|
19209
19209
|
(R == ee.value || !ee.value) && (be.value = ae, xe.value = ze.value.filter((Oe) => Oe[U.value] !== !0)[0] || null, ot.value = !1);
|
|
19210
19210
|
}).catch(
|
|
19211
19211
|
/* istanbul ignore next */
|
|
@@ -19216,11 +19216,11 @@ function bw(i, e, t) {
|
|
|
19216
19216
|
}, y.value));
|
|
19217
19217
|
}, { flush: "sync" });
|
|
19218
19218
|
};
|
|
19219
|
-
if (o.value !== "single" && !Di(
|
|
19219
|
+
if (o.value !== "single" && !Di(F.value) && !Array.isArray(F.value))
|
|
19220
19220
|
throw new Error(`v-model must be an array when using "${o.value}" mode`);
|
|
19221
19221
|
return n && typeof n.value == "function" ? d.value ? dr(gr) : N.value == !0 && gr() : (be.value = n.value, gr()), y.value > -1 && Uc(), Fe(y, (R, ae) => {
|
|
19222
19222
|
ri.value && ri.value(), R >= 0 && Uc();
|
|
19223
|
-
}), Fe(
|
|
19223
|
+
}), Fe(F, (R) => {
|
|
19224
19224
|
if (Di(R)) {
|
|
19225
19225
|
ue(Nr(R), !1);
|
|
19226
19226
|
return;
|
|
@@ -19262,7 +19262,7 @@ function bw(i, e, t) {
|
|
|
19262
19262
|
isDisabled: Vi,
|
|
19263
19263
|
isMax: yo,
|
|
19264
19264
|
getOption: Xt,
|
|
19265
|
-
handleOptionClick:
|
|
19265
|
+
handleOptionClick: X,
|
|
19266
19266
|
handleGroupClick: de,
|
|
19267
19267
|
handleTagRemove: Js,
|
|
19268
19268
|
refreshOptions: eh,
|
|
@@ -19281,66 +19281,66 @@ function Ow(i, e, t) {
|
|
|
19281
19281
|
groupSelect: u,
|
|
19282
19282
|
disabledProp: l,
|
|
19283
19283
|
groupOptions: c
|
|
19284
|
-
} = Wt(i), g = t.fo, j = t.fg, N = t.handleOptionClick, D = t.handleGroupClick, y = t.search, d = t.pointer, p = t.setPointer, x = t.clearPointer, v = t.multiselect, m = t.isOpen, A = q(() => g.value.filter((
|
|
19285
|
-
const
|
|
19284
|
+
} = Wt(i), g = t.fo, j = t.fg, N = t.handleOptionClick, D = t.handleGroupClick, y = t.search, d = t.pointer, p = t.setPointer, x = t.clearPointer, v = t.multiselect, m = t.isOpen, A = q(() => g.value.filter((F) => !F[l.value])), b = q(() => j.value.filter((F) => !F[l.value])), I = q(() => M.value !== "single" && u.value), h = q(() => d.value && d.value.group), O = q(() => $(d.value)), z = q(() => {
|
|
19285
|
+
const F = h.value ? d.value : (
|
|
19286
19286
|
/* istanbul ignore next */
|
|
19287
|
-
|
|
19288
|
-
), ee = b.value.map((ue) => ue[a.value]).indexOf(
|
|
19287
|
+
$(d.value)
|
|
19288
|
+
), ee = b.value.map((ue) => ue[a.value]).indexOf(F[a.value]);
|
|
19289
19289
|
let le = b.value[ee - 1];
|
|
19290
19290
|
return le === void 0 && (le = L.value), le;
|
|
19291
19291
|
}), f = q(() => {
|
|
19292
|
-
let
|
|
19293
|
-
return b.value.length <=
|
|
19294
|
-
}), L = q(() => [...b.value].slice(-1)[0]), E = q(() => d.value.__VISIBLE__.filter((
|
|
19295
|
-
const
|
|
19296
|
-
return
|
|
19292
|
+
let F = b.value.map((ee) => ee.label).indexOf(h.value ? d.value[a.value] : $(d.value)[a.value]) + 1;
|
|
19293
|
+
return b.value.length <= F && (F = 0), b.value[F];
|
|
19294
|
+
}), L = q(() => [...b.value].slice(-1)[0]), E = q(() => d.value.__VISIBLE__.filter((F) => !F[l.value])[0]), T = q(() => {
|
|
19295
|
+
const F = O.value.__VISIBLE__.filter((ee) => !ee[l.value]);
|
|
19296
|
+
return F[F.map((ee) => ee[n.value]).indexOf(d.value[n.value]) - 1];
|
|
19297
19297
|
}), w = q(() => {
|
|
19298
|
-
const
|
|
19299
|
-
return
|
|
19300
|
-
}), C = q(() => [...z.value.__VISIBLE__.filter((
|
|
19298
|
+
const F = $(d.value).__VISIBLE__.filter((ee) => !ee[l.value]);
|
|
19299
|
+
return F[F.map((ee) => ee[n.value]).indexOf(d.value[n.value]) + 1];
|
|
19300
|
+
}), C = q(() => [...z.value.__VISIBLE__.filter((F) => !F[l.value])].slice(-1)[0]), Y = q(() => [...L.value.__VISIBLE__.filter((F) => !F[l.value])].slice(-1)[0]), G = (F) => d.value && (!F.group && d.value[n.value] === F[n.value] || F.group !== void 0 && d.value[a.value] === F[a.value]) ? !0 : void 0, W = () => {
|
|
19301
19301
|
p(A.value[0] || null);
|
|
19302
19302
|
}, U = () => {
|
|
19303
19303
|
!d.value || d.value[l.value] === !0 || (h.value ? D(d.value) : N(d.value));
|
|
19304
|
-
},
|
|
19304
|
+
}, V = () => {
|
|
19305
19305
|
if (d.value === null)
|
|
19306
19306
|
p((s.value && I.value ? b.value[0].__CREATE__ ? A.value[0] : b.value[0] : A.value[0]) || null);
|
|
19307
19307
|
else if (s.value && I.value) {
|
|
19308
|
-
let
|
|
19309
|
-
|
|
19308
|
+
let F = h.value ? E.value : w.value;
|
|
19309
|
+
F === void 0 && (F = f.value, F.__CREATE__ && (F = F[c.value][0])), p(F || /* istanbul ignore next */
|
|
19310
19310
|
null);
|
|
19311
19311
|
} else {
|
|
19312
|
-
let
|
|
19313
|
-
A.value.length <=
|
|
19312
|
+
let F = A.value.map((ee) => ee[n.value]).indexOf(d.value[n.value]) + 1;
|
|
19313
|
+
A.value.length <= F && (F = 0), p(A.value[F] || null);
|
|
19314
19314
|
}
|
|
19315
19315
|
Ti(() => {
|
|
19316
19316
|
ie();
|
|
19317
19317
|
});
|
|
19318
19318
|
}, P = () => {
|
|
19319
19319
|
if (d.value === null) {
|
|
19320
|
-
let
|
|
19321
|
-
s.value && I.value && (
|
|
19320
|
+
let F = A.value[A.value.length - 1];
|
|
19321
|
+
s.value && I.value && (F = Y.value, F === void 0 && (F = L.value)), p(F || null);
|
|
19322
19322
|
} else if (s.value && I.value) {
|
|
19323
|
-
let
|
|
19324
|
-
|
|
19323
|
+
let F = h.value ? C.value : T.value;
|
|
19324
|
+
F === void 0 && (F = h.value ? z.value : O.value, F.__CREATE__ && (F = C.value, F === void 0 && (F = z.value))), p(F || /* istanbul ignore next */
|
|
19325
19325
|
null);
|
|
19326
19326
|
} else {
|
|
19327
|
-
let
|
|
19328
|
-
|
|
19327
|
+
let F = A.value.map((ee) => ee[n.value]).indexOf(d.value[n.value]) - 1;
|
|
19328
|
+
F < 0 && (F = A.value.length - 1), p(A.value[F] || null);
|
|
19329
19329
|
}
|
|
19330
19330
|
Ti(() => {
|
|
19331
19331
|
ie();
|
|
19332
19332
|
});
|
|
19333
|
-
},
|
|
19334
|
-
let
|
|
19335
|
-
if (!
|
|
19333
|
+
}, $ = (F) => b.value.find((ee) => ee.__VISIBLE__.map((le) => le[n.value]).indexOf(F[n.value]) !== -1), ie = () => {
|
|
19334
|
+
let F = v.value.querySelector("[data-pointed]");
|
|
19335
|
+
if (!F)
|
|
19336
19336
|
return;
|
|
19337
|
-
let ee =
|
|
19338
|
-
s.value && (ee = h.value ?
|
|
19337
|
+
let ee = F.parentElement.parentElement;
|
|
19338
|
+
s.value && (ee = h.value ? F.parentElement.parentElement.parentElement : F.parentElement.parentElement.parentElement.parentElement), F.offsetTop + F.offsetHeight > ee.clientHeight + ee.scrollTop && (ee.scrollTop = F.offsetTop + F.offsetHeight - ee.clientHeight), F.offsetTop < ee.scrollTop && (ee.scrollTop = F.offsetTop);
|
|
19339
19339
|
};
|
|
19340
|
-
return Fe(y, (
|
|
19341
|
-
r.value && (
|
|
19342
|
-
}), Fe(m, (
|
|
19343
|
-
if (
|
|
19340
|
+
return Fe(y, (F) => {
|
|
19341
|
+
r.value && (F.length && o.value ? W() : x());
|
|
19342
|
+
}), Fe(m, (F) => {
|
|
19343
|
+
if (F) {
|
|
19344
19344
|
let ee = v.value.querySelectorAll("[data-selected]")[0];
|
|
19345
19345
|
if (!ee)
|
|
19346
19346
|
return;
|
|
@@ -19353,9 +19353,9 @@ function Ow(i, e, t) {
|
|
|
19353
19353
|
pointer: d,
|
|
19354
19354
|
canPointGroups: I,
|
|
19355
19355
|
isPointed: G,
|
|
19356
|
-
setPointerFirst:
|
|
19356
|
+
setPointerFirst: W,
|
|
19357
19357
|
selectPointer: U,
|
|
19358
|
-
forwardPointer:
|
|
19358
|
+
forwardPointer: V,
|
|
19359
19359
|
backwardPointer: P
|
|
19360
19360
|
};
|
|
19361
19361
|
}
|
|
@@ -19428,16 +19428,16 @@ function Sw(i, e, t) {
|
|
|
19428
19428
|
} = Wt(i), N = tr().proxy, D = t.iv, y = t.update, d = t.search, p = t.setPointer, x = t.selectPointer, v = t.backwardPointer, m = t.forwardPointer, A = t.multiselect, b = t.wrapper, I = t.tags, h = t.isOpen, O = t.open, z = t.blur, f = t.fo, L = q(() => c.value || g.value || !1), E = q(() => o.value !== void 0 ? o.value : l.value !== void 0 ? l.value : ["enter"]), T = () => {
|
|
19429
19429
|
n.value === "tags" && !s.value && L.value && a.value && !u.value && p(f.value[f.value.map((G) => G[M.value]).indexOf(d.value)]);
|
|
19430
19430
|
}, w = (G) => {
|
|
19431
|
-
let
|
|
19432
|
-
for (;
|
|
19433
|
-
|
|
19434
|
-
return
|
|
19431
|
+
let W = G.length - 1;
|
|
19432
|
+
for (; W >= 0 && (G[W].remove === !1 || G[W].disabled); )
|
|
19433
|
+
W--;
|
|
19434
|
+
return W < 0 || G.splice(W, 1), G;
|
|
19435
19435
|
};
|
|
19436
19436
|
return {
|
|
19437
19437
|
handleKeydown: (G) => {
|
|
19438
19438
|
e.emit("keydown", G, N);
|
|
19439
|
-
let
|
|
19440
|
-
switch (["ArrowLeft", "ArrowRight", "Enter"].indexOf(G.key) !== -1 && n.value === "tags" && (
|
|
19439
|
+
let W, U;
|
|
19440
|
+
switch (["ArrowLeft", "ArrowRight", "Enter"].indexOf(G.key) !== -1 && n.value === "tags" && (W = [...A.value.querySelectorAll("[data-tags] > *")].filter((V) => V !== I.value), U = W.findIndex((V) => V === document.activeElement)), G.key) {
|
|
19441
19441
|
case "Backspace":
|
|
19442
19442
|
if (n.value === "single" || a.value && [null, ""].indexOf(d.value) === -1 || D.value.length === 0)
|
|
19443
19443
|
return;
|
|
@@ -19447,7 +19447,7 @@ function Sw(i, e, t) {
|
|
|
19447
19447
|
if (G.preventDefault(), G.keyCode === 229)
|
|
19448
19448
|
return;
|
|
19449
19449
|
if (U !== -1 && U !== void 0) {
|
|
19450
|
-
y([...D.value].filter((
|
|
19450
|
+
y([...D.value].filter((V, P) => P !== U)), U === W.length - 1 && (W.length - 1 ? W[W.length - 2].focus() : a.value ? I.value.querySelector("input").focus() : b.value.focus());
|
|
19451
19451
|
return;
|
|
19452
19452
|
}
|
|
19453
19453
|
if (E.value.indexOf("enter") === -1 && L.value)
|
|
@@ -19488,12 +19488,12 @@ function Sw(i, e, t) {
|
|
|
19488
19488
|
case "ArrowLeft":
|
|
19489
19489
|
if (a.value && I.value && I.value.querySelector("input").selectionStart || G.shiftKey || n.value !== "tags" || !D.value || !D.value.length)
|
|
19490
19490
|
return;
|
|
19491
|
-
G.preventDefault(), U === -1 ?
|
|
19491
|
+
G.preventDefault(), U === -1 ? W[W.length - 1].focus() : U > 0 && W[U - 1].focus();
|
|
19492
19492
|
break;
|
|
19493
19493
|
case "ArrowRight":
|
|
19494
19494
|
if (U === -1 || G.shiftKey || n.value !== "tags" || !D.value || !D.value.length)
|
|
19495
19495
|
return;
|
|
19496
|
-
G.preventDefault(),
|
|
19496
|
+
G.preventDefault(), W.length > U + 1 ? W[U + 1].focus() : a.value ? I.value.querySelector("input").focus() : a.value || b.value.focus();
|
|
19497
19497
|
break;
|
|
19498
19498
|
}
|
|
19499
19499
|
},
|
|
@@ -21546,7 +21546,7 @@ function eC(i, e) {
|
|
|
21546
21546
|
const t = Array.isArray(i) || vt(i), n = Array.isArray(e) || vt(e);
|
|
21547
21547
|
return t || n ? JSON.stringify(i) === JSON.stringify(e) : i === e;
|
|
21548
21548
|
}
|
|
21549
|
-
class
|
|
21549
|
+
class H {
|
|
21550
21550
|
/**
|
|
21551
21551
|
* Check if passed tag has no closed tag
|
|
21552
21552
|
*
|
|
@@ -21683,7 +21683,7 @@ class W {
|
|
|
21683
21683
|
* @param holder - element where to find inputs
|
|
21684
21684
|
*/
|
|
21685
21685
|
static findAllInputs(e) {
|
|
21686
|
-
return eI(e.querySelectorAll(
|
|
21686
|
+
return eI(e.querySelectorAll(H.allInputsSelector)).reduce((t, n) => H.isNativeInput(n) || H.containsOnlyInlineElements(n) ? [...t, n] : [...t, ...H.getDeepestBlockElements(n)], []);
|
|
21687
21687
|
}
|
|
21688
21688
|
/**
|
|
21689
21689
|
* Search for deepest node which is Leaf.
|
|
@@ -21699,7 +21699,7 @@ class W {
|
|
|
21699
21699
|
const n = t ? "lastChild" : "firstChild", o = t ? "previousSibling" : "nextSibling";
|
|
21700
21700
|
if (e && e.nodeType === Node.ELEMENT_NODE && e[n]) {
|
|
21701
21701
|
let r = e[n];
|
|
21702
|
-
if (
|
|
21702
|
+
if (H.isSingleTag(r) && !H.isNativeInput(r) && !H.isLineBreakTag(r))
|
|
21703
21703
|
if (r[o])
|
|
21704
21704
|
r = r[o];
|
|
21705
21705
|
else if (r.parentNode[o])
|
|
@@ -21761,7 +21761,7 @@ class W {
|
|
|
21761
21761
|
*/
|
|
21762
21762
|
static canSetCaret(e) {
|
|
21763
21763
|
let t = !0;
|
|
21764
|
-
if (
|
|
21764
|
+
if (H.isNativeInput(e))
|
|
21765
21765
|
switch (e.type) {
|
|
21766
21766
|
case "file":
|
|
21767
21767
|
case "checkbox":
|
|
@@ -21775,7 +21775,7 @@ class W {
|
|
|
21775
21775
|
break;
|
|
21776
21776
|
}
|
|
21777
21777
|
else
|
|
21778
|
-
t =
|
|
21778
|
+
t = H.isContentEditable(e);
|
|
21779
21779
|
return t;
|
|
21780
21780
|
}
|
|
21781
21781
|
/**
|
|
@@ -21825,7 +21825,7 @@ class W {
|
|
|
21825
21825
|
* @returns {boolean}
|
|
21826
21826
|
*/
|
|
21827
21827
|
static isHTMLString(e) {
|
|
21828
|
-
const t =
|
|
21828
|
+
const t = H.make("div");
|
|
21829
21829
|
return t.innerHTML = e, t.childElementCount > 0;
|
|
21830
21830
|
}
|
|
21831
21831
|
/**
|
|
@@ -21835,7 +21835,7 @@ class W {
|
|
|
21835
21835
|
* @returns {number}
|
|
21836
21836
|
*/
|
|
21837
21837
|
static getContentLength(e) {
|
|
21838
|
-
return
|
|
21838
|
+
return H.isNativeInput(e) ? e.value.length : e.nodeType === Node.TEXT_NODE ? e.length : e.textContent.length;
|
|
21839
21839
|
}
|
|
21840
21840
|
/**
|
|
21841
21841
|
* Return array of names of block html elements
|
|
@@ -21894,7 +21894,7 @@ class W {
|
|
|
21894
21894
|
static containsOnlyInlineElements(e) {
|
|
21895
21895
|
let t;
|
|
21896
21896
|
Mn(e) ? (t = document.createElement("div"), t.innerHTML = e) : t = e;
|
|
21897
|
-
const n = (o) => !
|
|
21897
|
+
const n = (o) => !H.blockElements.includes(o.tagName.toLowerCase()) && Array.from(o.children).every(n);
|
|
21898
21898
|
return Array.from(t.children).every(n);
|
|
21899
21899
|
}
|
|
21900
21900
|
/**
|
|
@@ -21904,7 +21904,7 @@ class W {
|
|
|
21904
21904
|
* @returns {HTMLElement[]}
|
|
21905
21905
|
*/
|
|
21906
21906
|
static getDeepestBlockElements(e) {
|
|
21907
|
-
return
|
|
21907
|
+
return H.containsOnlyInlineElements(e) ? [e] : Array.from(e.children).reduce((t, n) => [...t, ...H.getDeepestBlockElements(n)], []);
|
|
21908
21908
|
}
|
|
21909
21909
|
/**
|
|
21910
21910
|
* Helper for get holder from {string} or return HTMLElement
|
|
@@ -22433,7 +22433,7 @@ let Ce = class oI {
|
|
|
22433
22433
|
if (!e)
|
|
22434
22434
|
return null;
|
|
22435
22435
|
const t = e.anchorNode;
|
|
22436
|
-
return t ?
|
|
22436
|
+
return t ? H.isElement(t) ? t : t.parentElement : null;
|
|
22437
22437
|
}
|
|
22438
22438
|
/**
|
|
22439
22439
|
* Returns selection offset according to the anchor node
|
|
@@ -22565,7 +22565,7 @@ let Ce = class oI {
|
|
|
22565
22565
|
*/
|
|
22566
22566
|
static setCursor(e, t = 0) {
|
|
22567
22567
|
const n = document.createRange(), o = window.getSelection();
|
|
22568
|
-
return
|
|
22568
|
+
return H.isNativeInput(e) ? H.canSetCaret(e) ? (e.focus(), e.selectionStart = e.selectionEnd = t, e.getBoundingClientRect()) : void 0 : (n.setStart(e, t), n.setEnd(e, t), o.removeAllRanges(), o.addRange(n), n.getBoundingClientRect());
|
|
22569
22569
|
}
|
|
22570
22570
|
/**
|
|
22571
22571
|
* Check if current range exists and belongs to container
|
|
@@ -22583,7 +22583,7 @@ let Ce = class oI {
|
|
|
22583
22583
|
const e = Ji.range;
|
|
22584
22584
|
if (e === null)
|
|
22585
22585
|
return;
|
|
22586
|
-
const t =
|
|
22586
|
+
const t = H.make("span", "codex-editor__fake-cursor");
|
|
22587
22587
|
t.dataset.mutationFree = "true", e.collapse(), e.insertNode(t);
|
|
22588
22588
|
}
|
|
22589
22589
|
/**
|
|
@@ -22592,7 +22592,7 @@ let Ce = class oI {
|
|
|
22592
22592
|
* @param el - where to check
|
|
22593
22593
|
*/
|
|
22594
22594
|
static isFakeCursorInsideContainer(e) {
|
|
22595
|
-
return
|
|
22595
|
+
return H.find(e, ".codex-editor__fake-cursor") !== null;
|
|
22596
22596
|
}
|
|
22597
22597
|
/**
|
|
22598
22598
|
* Removes fake cursor from a container
|
|
@@ -22600,7 +22600,7 @@ let Ce = class oI {
|
|
|
22600
22600
|
* @param container - container to look for
|
|
22601
22601
|
*/
|
|
22602
22602
|
static removeFakeCursor(e = document.body) {
|
|
22603
|
-
const t =
|
|
22603
|
+
const t = H.find(e, ".codex-editor__fake-cursor");
|
|
22604
22604
|
t && t.remove();
|
|
22605
22605
|
}
|
|
22606
22606
|
/**
|
|
@@ -22733,7 +22733,7 @@ class ft extends Zs {
|
|
|
22733
22733
|
...Array.from(j),
|
|
22734
22734
|
...Array.from(N),
|
|
22735
22735
|
D
|
|
22736
|
-
].some((y) =>
|
|
22736
|
+
].some((y) => H.isElement(y) ? y.dataset.mutationFree === "true" : !1);
|
|
22737
22737
|
})), c && (this.dropInputsCache(), this.updateCurrentInput(), this.call(
|
|
22738
22738
|
"updated"
|
|
22739
22739
|
/* UPDATED */
|
|
@@ -22765,7 +22765,7 @@ class ft extends Zs {
|
|
|
22765
22765
|
get inputs() {
|
|
22766
22766
|
if (this.cachedInputs.length !== 0)
|
|
22767
22767
|
return this.cachedInputs;
|
|
22768
|
-
const e =
|
|
22768
|
+
const e = H.findAllInputs(this.holder);
|
|
22769
22769
|
return this.inputIndex > e.length - 1 && (this.inputIndex = e.length - 1), this.cachedInputs = e, e;
|
|
22770
22770
|
}
|
|
22771
22771
|
/**
|
|
@@ -22849,7 +22849,7 @@ class ft extends Zs {
|
|
|
22849
22849
|
* @returns {boolean}
|
|
22850
22850
|
*/
|
|
22851
22851
|
get isEmpty() {
|
|
22852
|
-
const e =
|
|
22852
|
+
const e = H.isEmpty(this.pluginsContent), t = !this.hasMedia;
|
|
22853
22853
|
return e && t;
|
|
22854
22854
|
}
|
|
22855
22855
|
/**
|
|
@@ -23018,14 +23018,14 @@ class ft extends Zs {
|
|
|
23018
23018
|
...this.defaultTunesInstances.values()
|
|
23019
23019
|
].map((r) => r.render());
|
|
23020
23020
|
return [n, o].flat().forEach((r) => {
|
|
23021
|
-
|
|
23021
|
+
H.isElement(r) ? e.appendChild(r) : Array.isArray(r) ? t.push(...r) : t.push(r);
|
|
23022
23022
|
}), [t, e];
|
|
23023
23023
|
}
|
|
23024
23024
|
/**
|
|
23025
23025
|
* Update current input index with selection anchor node
|
|
23026
23026
|
*/
|
|
23027
23027
|
updateCurrentInput() {
|
|
23028
|
-
this.currentInput =
|
|
23028
|
+
this.currentInput = H.isNativeInput(document.activeElement) || !Ie.anchorNode ? document.activeElement : Ie.anchorNode;
|
|
23029
23029
|
}
|
|
23030
23030
|
/**
|
|
23031
23031
|
* Allows to say Editor that Block was changed. Used to manually trigger Editor's 'onChange' callback
|
|
@@ -23064,7 +23064,7 @@ class ft extends Zs {
|
|
|
23064
23064
|
* @returns {HTMLDivElement}
|
|
23065
23065
|
*/
|
|
23066
23066
|
compose() {
|
|
23067
|
-
const e =
|
|
23067
|
+
const e = H.make("div", ft.CSS.wrapper), t = H.make("div", ft.CSS.content), n = this.toolInstance.render();
|
|
23068
23068
|
e.dataset.id = this.id, this.toolRenderedElement = n, t.appendChild(this.toolRenderedElement);
|
|
23069
23069
|
let o = t;
|
|
23070
23070
|
return [...this.tunesInstances.values(), ...this.defaultTunesInstances.values()].forEach((r) => {
|
|
@@ -23094,7 +23094,7 @@ class ft extends Zs {
|
|
|
23094
23094
|
*/
|
|
23095
23095
|
addInputEvents() {
|
|
23096
23096
|
this.inputs.forEach((e) => {
|
|
23097
|
-
e.addEventListener("focus", this.handleFocus),
|
|
23097
|
+
e.addEventListener("focus", this.handleFocus), H.isNativeInput(e) && e.addEventListener("input", this.didMutated);
|
|
23098
23098
|
});
|
|
23099
23099
|
}
|
|
23100
23100
|
/**
|
|
@@ -23102,7 +23102,7 @@ class ft extends Zs {
|
|
|
23102
23102
|
*/
|
|
23103
23103
|
removeInputEvents() {
|
|
23104
23104
|
this.inputs.forEach((e) => {
|
|
23105
|
-
e.removeEventListener("focus", this.handleFocus),
|
|
23105
|
+
e.removeEventListener("focus", this.handleFocus), H.isNativeInput(e) && e.removeEventListener("input", this.didMutated);
|
|
23106
23106
|
});
|
|
23107
23107
|
}
|
|
23108
23108
|
/**
|
|
@@ -23796,11 +23796,11 @@ var yl = {}, NC = {
|
|
|
23796
23796
|
var w = document.createElement("link");
|
|
23797
23797
|
return T.attrs.type === void 0 && (T.attrs.type = "text/css"), T.attrs.rel = "stylesheet", x(w, T.attrs), y(T, w), w;
|
|
23798
23798
|
}(h), z = (function(T, w, C) {
|
|
23799
|
-
var Y = C.css, G = C.sourceMap,
|
|
23800
|
-
(w.convertToAbsoluteUrls ||
|
|
23799
|
+
var Y = C.css, G = C.sourceMap, W = w.convertToAbsoluteUrls === void 0 && G;
|
|
23800
|
+
(w.convertToAbsoluteUrls || W) && (Y = j(Y)), G && (Y += `
|
|
23801
23801
|
/*# sourceMappingURL=data:application/json;base64,` + btoa(unescape(encodeURIComponent(JSON.stringify(G)))) + " */");
|
|
23802
|
-
var U = new Blob([Y], { type: "text/css" }),
|
|
23803
|
-
T.href = URL.createObjectURL(U),
|
|
23802
|
+
var U = new Blob([Y], { type: "text/css" }), V = T.href;
|
|
23803
|
+
T.href = URL.createObjectURL(U), V && URL.revokeObjectURL(V);
|
|
23804
23804
|
}).bind(null, O, h), f = function() {
|
|
23805
23805
|
d(O), O.href && URL.revokeObjectURL(O.href);
|
|
23806
23806
|
}) : (O = p(h), z = (function(T, w) {
|
|
@@ -24666,12 +24666,12 @@ class gt {
|
|
|
24666
24666
|
* @param params - item construction params
|
|
24667
24667
|
*/
|
|
24668
24668
|
make(e) {
|
|
24669
|
-
const t =
|
|
24670
|
-
return e.name && (t.dataset.itemName = e.name), this.nodes.icon =
|
|
24669
|
+
const t = H.make("div", gt.CSS.container);
|
|
24670
|
+
return e.name && (t.dataset.itemName = e.name), this.nodes.icon = H.make("div", gt.CSS.icon, {
|
|
24671
24671
|
innerHTML: e.icon || UC
|
|
24672
|
-
}), t.appendChild(this.nodes.icon), t.appendChild(
|
|
24672
|
+
}), t.appendChild(this.nodes.icon), t.appendChild(H.make("div", gt.CSS.title, {
|
|
24673
24673
|
innerHTML: e.title || ""
|
|
24674
|
-
})), e.secondaryLabel && t.appendChild(
|
|
24674
|
+
})), e.secondaryLabel && t.appendChild(H.make("div", gt.CSS.secondaryTitle, {
|
|
24675
24675
|
textContent: e.secondaryLabel
|
|
24676
24676
|
})), e.isActive && t.classList.add(gt.CSS.active), e.isDisabled && t.classList.add(gt.CSS.disabled), t;
|
|
24677
24677
|
}
|
|
@@ -24790,7 +24790,7 @@ const Co = class {
|
|
|
24790
24790
|
if (this.items.length === 0)
|
|
24791
24791
|
return this.cursor;
|
|
24792
24792
|
let e = this.cursor;
|
|
24793
|
-
return e === -1 ? e = i === Co.directions.RIGHT ? -1 : 0 : this.items[e].classList.remove(this.focusedCssClass), i === Co.directions.RIGHT ? e = (e + 1) % this.items.length : e = (this.items.length + e - 1) % this.items.length,
|
|
24793
|
+
return e === -1 ? e = i === Co.directions.RIGHT ? -1 : 0 : this.items[e].classList.remove(this.focusedCssClass), i === Co.directions.RIGHT ? e = (e + 1) % this.items.length : e = (this.items.length + e - 1) % this.items.length, H.canSetCaret(this.items[e]) && Mo(() => Ie.setCursor(this.items[e]), 50)(), this.items[e].classList.add(this.focusedCssClass), e;
|
|
24794
24794
|
}
|
|
24795
24795
|
};
|
|
24796
24796
|
let $n = Co;
|
|
@@ -24998,11 +24998,11 @@ class Go {
|
|
|
24998
24998
|
* @param placeholder - input placeholder
|
|
24999
24999
|
*/
|
|
25000
25000
|
render(e) {
|
|
25001
|
-
this.wrapper =
|
|
25002
|
-
const t =
|
|
25001
|
+
this.wrapper = H.make("div", Go.CSS.wrapper);
|
|
25002
|
+
const t = H.make("div", Go.CSS.icon, {
|
|
25003
25003
|
innerHTML: RC
|
|
25004
25004
|
});
|
|
25005
|
-
this.input =
|
|
25005
|
+
this.input = H.make("input", Go.CSS.input, {
|
|
25006
25006
|
placeholder: e
|
|
25007
25007
|
}), this.wrapper.appendChild(t), this.wrapper.appendChild(this.input), this.listeners.on(this.input, "input", () => {
|
|
25008
25008
|
this.searchQuery = this.input.value, this.onSearch(this.searchQuery, this.foundItems);
|
|
@@ -25145,14 +25145,14 @@ const xt = class extends Zs {
|
|
|
25145
25145
|
* Constructs HTML element corresponding to popover
|
|
25146
25146
|
*/
|
|
25147
25147
|
make() {
|
|
25148
|
-
this.nodes.popover =
|
|
25148
|
+
this.nodes.popover = H.make("div", [xt.CSS.popover]), this.nodes.nothingFoundMessage = H.make("div", [xt.CSS.nothingFoundMessage], {
|
|
25149
25149
|
textContent: this.messages.nothingFound
|
|
25150
|
-
}), this.nodes.popover.appendChild(this.nodes.nothingFoundMessage), this.nodes.items =
|
|
25150
|
+
}), this.nodes.popover.appendChild(this.nodes.nothingFoundMessage), this.nodes.items = H.make("div", [xt.CSS.items]), this.items.forEach((i) => {
|
|
25151
25151
|
this.nodes.items.appendChild(i.getElement());
|
|
25152
25152
|
}), this.nodes.popover.appendChild(this.nodes.items), this.listeners.on(this.nodes.popover, "click", (i) => {
|
|
25153
25153
|
const e = this.getTargetItem(i);
|
|
25154
25154
|
e !== void 0 && this.handleItemClick(e);
|
|
25155
|
-
}), this.nodes.wrapper =
|
|
25155
|
+
}), this.nodes.wrapper = H.make("div"), this.nodes.overlay = H.make("div", [xt.CSS.overlay, xt.CSS.overlayHidden]), this.listeners.on(this.nodes.overlay, "click", () => {
|
|
25156
25156
|
this.hide();
|
|
25157
25157
|
}), this.nodes.wrapper.appendChild(this.nodes.overlay), this.nodes.wrapper.appendChild(this.nodes.popover);
|
|
25158
25158
|
}
|
|
@@ -25319,7 +25319,7 @@ class FC extends Ce {
|
|
|
25319
25319
|
* - Default Settings [Move, Remove, etc]
|
|
25320
25320
|
*/
|
|
25321
25321
|
make() {
|
|
25322
|
-
this.nodes.wrapper =
|
|
25322
|
+
this.nodes.wrapper = H.make("div", [this.CSS.settings]);
|
|
25323
25323
|
}
|
|
25324
25324
|
/**
|
|
25325
25325
|
* Destroys module
|
|
@@ -25366,7 +25366,7 @@ class FC extends Ce {
|
|
|
25366
25366
|
*/
|
|
25367
25367
|
getControls(e) {
|
|
25368
25368
|
const { StylesAPI: t } = this.Editor, n = e.querySelectorAll(
|
|
25369
|
-
`.${t.classes.settingsButton}, ${
|
|
25369
|
+
`.${t.classes.settingsButton}, ${H.allInputsSelector}`
|
|
25370
25370
|
);
|
|
25371
25371
|
return Array.from(n);
|
|
25372
25372
|
}
|
|
@@ -25405,14 +25405,14 @@ class Zt extends Ce {
|
|
|
25405
25405
|
* Create UI of Conversion Toolbar
|
|
25406
25406
|
*/
|
|
25407
25407
|
make() {
|
|
25408
|
-
this.nodes.wrapper =
|
|
25408
|
+
this.nodes.wrapper = H.make("div", [
|
|
25409
25409
|
Zt.CSS.conversionToolbarWrapper,
|
|
25410
25410
|
...this.isRtl ? [this.Editor.UI.CSS.editorRtlFix] : []
|
|
25411
|
-
]), this.nodes.tools =
|
|
25412
|
-
const e =
|
|
25411
|
+
]), this.nodes.tools = H.make("div", Zt.CSS.conversionToolbarTools);
|
|
25412
|
+
const e = H.make("div", Zt.CSS.conversionToolbarLabel, {
|
|
25413
25413
|
textContent: Bt.ui(di.ui.inlineToolbar.converter, "Convert to")
|
|
25414
25414
|
});
|
|
25415
|
-
return this.addTools(), this.enableFlipper(),
|
|
25415
|
+
return this.addTools(), this.enableFlipper(), H.append(this.nodes.wrapper, e), H.append(this.nodes.wrapper, this.nodes.tools), this.nodes.wrapper;
|
|
25416
25416
|
}
|
|
25417
25417
|
/**
|
|
25418
25418
|
* Deactivates flipper and removes all nodes
|
|
@@ -25492,16 +25492,16 @@ class Zt extends Ce {
|
|
|
25492
25492
|
*/
|
|
25493
25493
|
addTool(e, t) {
|
|
25494
25494
|
var n;
|
|
25495
|
-
const o =
|
|
25496
|
-
o.dataset.tool = e, r.innerHTML = t.icon,
|
|
25495
|
+
const o = H.make("div", [Zt.CSS.conversionTool]), r = H.make("div", [Zt.CSS.conversionToolIcon]);
|
|
25496
|
+
o.dataset.tool = e, r.innerHTML = t.icon, H.append(o, r), H.append(o, H.text(Bt.t(di.toolNames, t.title || uo(e))));
|
|
25497
25497
|
const a = (n = this.Editor.Tools.blockTools.get(e)) == null ? void 0 : n.shortcut;
|
|
25498
25498
|
if (a) {
|
|
25499
|
-
const s =
|
|
25499
|
+
const s = H.make("span", Zt.CSS.conversionToolSecondaryLabel, {
|
|
25500
25500
|
innerText: fc(a)
|
|
25501
25501
|
});
|
|
25502
|
-
|
|
25502
|
+
H.append(o, s);
|
|
25503
25503
|
}
|
|
25504
|
-
|
|
25504
|
+
H.append(this.nodes.tools, o), this.tools.push({
|
|
25505
25505
|
name: e,
|
|
25506
25506
|
button: o,
|
|
25507
25507
|
toolboxItem: t
|
|
@@ -26037,27 +26037,27 @@ class e2 extends Ce {
|
|
|
26037
26037
|
* Draws Toolbar elements
|
|
26038
26038
|
*/
|
|
26039
26039
|
make() {
|
|
26040
|
-
this.nodes.wrapper =
|
|
26041
|
-
this.nodes[t] =
|
|
26042
|
-
}),
|
|
26040
|
+
this.nodes.wrapper = H.make("div", this.CSS.toolbar), ["content", "actions"].forEach((t) => {
|
|
26041
|
+
this.nodes[t] = H.make("div", this.CSS[t]);
|
|
26042
|
+
}), H.append(this.nodes.wrapper, this.nodes.content), H.append(this.nodes.content, this.nodes.actions), this.nodes.plusButton = H.make("div", this.CSS.plusButton, {
|
|
26043
26043
|
innerHTML: BC
|
|
26044
|
-
}),
|
|
26044
|
+
}), H.append(this.nodes.actions, this.nodes.plusButton), this.readOnlyMutableListeners.on(this.nodes.plusButton, "click", () => {
|
|
26045
26045
|
this.tooltip.hide(!0), this.plusButtonClicked();
|
|
26046
26046
|
}, !1);
|
|
26047
|
-
const e =
|
|
26048
|
-
e.appendChild(document.createTextNode(Bt.ui(di.ui.toolbar.toolbox, "Add"))), e.appendChild(
|
|
26047
|
+
const e = H.make("div");
|
|
26048
|
+
e.appendChild(document.createTextNode(Bt.ui(di.ui.toolbar.toolbox, "Add"))), e.appendChild(H.make("div", this.CSS.plusButtonShortcut, {
|
|
26049
26049
|
textContent: "⇥ Tab"
|
|
26050
26050
|
})), this.tooltip.onHover(this.nodes.plusButton, e, {
|
|
26051
26051
|
hidingDelay: 400
|
|
26052
|
-
}), this.nodes.settingsToggler =
|
|
26052
|
+
}), this.nodes.settingsToggler = H.make("span", this.CSS.settingsToggler, {
|
|
26053
26053
|
innerHTML: PC
|
|
26054
|
-
}),
|
|
26054
|
+
}), H.append(this.nodes.actions, this.nodes.settingsToggler), this.tooltip.onHover(
|
|
26055
26055
|
this.nodes.settingsToggler,
|
|
26056
26056
|
Bt.ui(di.ui.blockTunes.toggler, "Click to tune"),
|
|
26057
26057
|
{
|
|
26058
26058
|
hidingDelay: 400
|
|
26059
26059
|
}
|
|
26060
|
-
),
|
|
26060
|
+
), H.append(this.nodes.actions, this.makeToolbox()), H.append(this.nodes.actions, this.Editor.BlockSettings.getElement()), H.append(this.Editor.UI.nodes.wrapper, this.nodes.wrapper);
|
|
26061
26061
|
}
|
|
26062
26062
|
/**
|
|
26063
26063
|
* Creates the Toolbox instance and return it's rendered element
|
|
@@ -26320,12 +26320,12 @@ class t2 extends Ce {
|
|
|
26320
26320
|
* Making DOM
|
|
26321
26321
|
*/
|
|
26322
26322
|
make() {
|
|
26323
|
-
this.nodes.wrapper =
|
|
26323
|
+
this.nodes.wrapper = H.make("div", [
|
|
26324
26324
|
this.CSS.inlineToolbar,
|
|
26325
26325
|
...this.isRtl ? [this.Editor.UI.CSS.editorRtlFix] : []
|
|
26326
|
-
]), this.nodes.togglerAndButtonsWrapper =
|
|
26326
|
+
]), this.nodes.togglerAndButtonsWrapper = H.make("div", this.CSS.togglerAndButtonsWrapper), this.nodes.buttons = H.make("div", this.CSS.buttonsWrapper), this.nodes.actions = H.make("div", this.CSS.actionsWrapper), this.listeners.on(this.nodes.wrapper, "mousedown", (e) => {
|
|
26327
26327
|
e.target.closest(`.${this.CSS.actionsWrapper}`) || e.preventDefault();
|
|
26328
|
-
}),
|
|
26328
|
+
}), H.append(this.nodes.wrapper, [this.nodes.togglerAndButtonsWrapper, this.nodes.actions]), H.append(this.Editor.UI.nodes.wrapper, this.nodes.wrapper), this.addConversionToggler(), H.append(this.nodes.togglerAndButtonsWrapper, this.nodes.buttons), this.prepareConversionToolbar(), window.requestAnimationFrame(() => {
|
|
26329
26329
|
this.recalculateWidth();
|
|
26330
26330
|
}), this.enableFlipper();
|
|
26331
26331
|
}
|
|
@@ -26336,7 +26336,7 @@ class t2 extends Ce {
|
|
|
26336
26336
|
const e = ["IMG", "INPUT"], t = Ie.get(), n = Ie.text;
|
|
26337
26337
|
if (!t || !t.anchorNode || t.isCollapsed || n.length < 1)
|
|
26338
26338
|
return !1;
|
|
26339
|
-
const o =
|
|
26339
|
+
const o = H.isElement(t.anchorNode) ? t.anchorNode : t.anchorNode.parentElement;
|
|
26340
26340
|
if (t && e.includes(o.tagName) || o.closest('[contenteditable="true"]') === null)
|
|
26341
26341
|
return !1;
|
|
26342
26342
|
const r = this.Editor.BlockManager.getBlock(t.anchorNode);
|
|
@@ -26353,8 +26353,8 @@ class t2 extends Ce {
|
|
|
26353
26353
|
* and prepend it to the buttons list
|
|
26354
26354
|
*/
|
|
26355
26355
|
addConversionToggler() {
|
|
26356
|
-
this.nodes.conversionToggler =
|
|
26357
|
-
const e =
|
|
26356
|
+
this.nodes.conversionToggler = H.make("div", this.CSS.conversionToggler), this.nodes.conversionTogglerContent = H.make("div", this.CSS.conversionTogglerContent);
|
|
26357
|
+
const e = H.make("div", this.CSS.conversionTogglerArrow, {
|
|
26358
26358
|
innerHTML: lI
|
|
26359
26359
|
});
|
|
26360
26360
|
this.nodes.conversionToggler.appendChild(this.nodes.conversionTogglerContent), this.nodes.conversionToggler.appendChild(e), this.nodes.togglerAndButtonsWrapper.appendChild(this.nodes.conversionToggler), this.listeners.on(this.nodes.conversionToggler, "click", () => {
|
|
@@ -26380,7 +26380,7 @@ class t2 extends Ce {
|
|
|
26380
26380
|
*/
|
|
26381
26381
|
prepareConversionToolbar() {
|
|
26382
26382
|
const e = this.Editor.ConversionToolbar.make();
|
|
26383
|
-
|
|
26383
|
+
H.append(this.nodes.wrapper, e);
|
|
26384
26384
|
}
|
|
26385
26385
|
/**
|
|
26386
26386
|
* Working with Tools
|
|
@@ -26419,11 +26419,11 @@ class t2 extends Ce {
|
|
|
26419
26419
|
this.enableShortcuts(t, o);
|
|
26420
26420
|
} catch {
|
|
26421
26421
|
}
|
|
26422
|
-
const r =
|
|
26422
|
+
const r = H.make("div"), a = Bt.t(
|
|
26423
26423
|
di.toolNames,
|
|
26424
26424
|
e.title || uo(e.name)
|
|
26425
26425
|
);
|
|
26426
|
-
r.appendChild(
|
|
26426
|
+
r.appendChild(H.text(a)), o && r.appendChild(H.make("div", this.CSS.inlineToolbarShortcut, {
|
|
26427
26427
|
textContent: fc(o)
|
|
26428
26428
|
})), En() === !1 && this.tooltip.onHover(n, r, {
|
|
26429
26429
|
placement: "top",
|
|
@@ -26811,7 +26811,7 @@ class EM {
|
|
|
26811
26811
|
*/
|
|
26812
26812
|
swap(e, t) {
|
|
26813
26813
|
const n = this.blocks[t];
|
|
26814
|
-
|
|
26814
|
+
H.swap(this.blocks[e].holder, n.holder), this.blocks[t] = this.blocks[e], this.blocks[e] = n;
|
|
26815
26815
|
}
|
|
26816
26816
|
/**
|
|
26817
26817
|
* Move a block from one to another index
|
|
@@ -27300,10 +27300,10 @@ class r2 extends Ce {
|
|
|
27300
27300
|
* @returns {Block}
|
|
27301
27301
|
*/
|
|
27302
27302
|
split() {
|
|
27303
|
-
const e = this.Editor.Caret.extractFragmentFromCaretPosition(), t =
|
|
27303
|
+
const e = this.Editor.Caret.extractFragmentFromCaretPosition(), t = H.make("div");
|
|
27304
27304
|
t.appendChild(e);
|
|
27305
27305
|
const n = {
|
|
27306
|
-
text:
|
|
27306
|
+
text: H.isEmpty(t) ? "" : t.innerHTML
|
|
27307
27307
|
};
|
|
27308
27308
|
return this.insert({ data: n });
|
|
27309
27309
|
}
|
|
@@ -27339,7 +27339,7 @@ class r2 extends Ce {
|
|
|
27339
27339
|
* @param {Node} element - html element to get Block by
|
|
27340
27340
|
*/
|
|
27341
27341
|
getBlock(e) {
|
|
27342
|
-
|
|
27342
|
+
H.isElement(e) || (e = e.parentNode);
|
|
27343
27343
|
const t = this._blocks.nodes, n = e.closest(`.${ft.CSS.wrapper}`), o = t.indexOf(n);
|
|
27344
27344
|
if (o >= 0)
|
|
27345
27345
|
return this._blocks[o];
|
|
@@ -27366,7 +27366,7 @@ class r2 extends Ce {
|
|
|
27366
27366
|
* @returns {Block | undefined} can return undefined in case when the passed child note is not a part of the current editor instance
|
|
27367
27367
|
*/
|
|
27368
27368
|
setCurrentBlockByChildNode(e) {
|
|
27369
|
-
|
|
27369
|
+
H.isElement(e) || (e = e.parentNode);
|
|
27370
27370
|
const t = e.closest(`.${ft.CSS.wrapper}`);
|
|
27371
27371
|
if (!t)
|
|
27372
27372
|
return;
|
|
@@ -27381,7 +27381,7 @@ class r2 extends Ce {
|
|
|
27381
27381
|
* @returns {Block}
|
|
27382
27382
|
*/
|
|
27383
27383
|
getBlockByChildNode(e) {
|
|
27384
|
-
|
|
27384
|
+
H.isElement(e) || (e = e.parentNode);
|
|
27385
27385
|
const t = e.closest(`.${ft.CSS.wrapper}`);
|
|
27386
27386
|
return this.blocks.find((n) => n.holder === t);
|
|
27387
27387
|
}
|
|
@@ -27671,9 +27671,9 @@ class a2 extends Ce {
|
|
|
27671
27671
|
*/
|
|
27672
27672
|
copySelectedBlocks(e) {
|
|
27673
27673
|
e.preventDefault();
|
|
27674
|
-
const t =
|
|
27674
|
+
const t = H.make("div");
|
|
27675
27675
|
this.selectedBlocks.forEach((r) => {
|
|
27676
|
-
const a = Yi(r.holder.innerHTML, this.sanitizerConfig), s =
|
|
27676
|
+
const a = Yi(r.holder.innerHTML, this.sanitizerConfig), s = H.make("p");
|
|
27677
27677
|
s.innerHTML = a, t.appendChild(s);
|
|
27678
27678
|
});
|
|
27679
27679
|
const n = Array.from(t.childNodes).map((r) => r.textContent).join(`
|
|
@@ -27717,7 +27717,7 @@ class a2 extends Ce {
|
|
|
27717
27717
|
* @param {KeyboardEvent} event - keyboard event
|
|
27718
27718
|
*/
|
|
27719
27719
|
handleCommandA(e) {
|
|
27720
|
-
if (this.Editor.RectangleSelection.clearSelection(),
|
|
27720
|
+
if (this.Editor.RectangleSelection.clearSelection(), H.isNativeInput(e.target) && !this.readyToBlockSelection) {
|
|
27721
27721
|
this.readyToBlockSelection = !0;
|
|
27722
27722
|
return;
|
|
27723
27723
|
}
|
|
@@ -27768,18 +27768,18 @@ class vs extends Ce {
|
|
|
27768
27768
|
* @returns {boolean}
|
|
27769
27769
|
*/
|
|
27770
27770
|
get isAtStart() {
|
|
27771
|
-
const e = Ie.get(), t =
|
|
27771
|
+
const e = Ie.get(), t = H.getDeepestNode(this.Editor.BlockManager.currentBlock.currentInput);
|
|
27772
27772
|
let n = e.focusNode;
|
|
27773
|
-
if (
|
|
27773
|
+
if (H.isNativeInput(t))
|
|
27774
27774
|
return t.selectionEnd === 0;
|
|
27775
27775
|
if (!e.anchorNode)
|
|
27776
27776
|
return !1;
|
|
27777
27777
|
let o = n.textContent.search(/\S/);
|
|
27778
27778
|
o === -1 && (o = 0);
|
|
27779
27779
|
let r = e.focusOffset;
|
|
27780
|
-
return n.nodeType !== Node.TEXT_NODE && n.childNodes.length && (n.childNodes[r] ? (n = n.childNodes[r], r = 0) : (n = n.childNodes[r - 1], r = n.textContent.length)), (
|
|
27781
|
-
const s =
|
|
27782
|
-
return
|
|
27780
|
+
return n.nodeType !== Node.TEXT_NODE && n.childNodes.length && (n.childNodes[r] ? (n = n.childNodes[r], r = 0) : (n = n.childNodes[r - 1], r = n.textContent.length)), (H.isLineBreakTag(t) || H.isEmpty(t)) && this.getHigherLevelSiblings(n, "left").every((a) => {
|
|
27781
|
+
const s = H.isLineBreakTag(a), M = a.children.length === 1 && H.isLineBreakTag(a.children[0]), u = s || M;
|
|
27782
|
+
return H.isEmpty(a) && !u;
|
|
27783
27783
|
}) && r === o ? !0 : t === null || n === t && r <= o;
|
|
27784
27784
|
}
|
|
27785
27785
|
/**
|
|
@@ -27790,15 +27790,15 @@ class vs extends Ce {
|
|
|
27790
27790
|
get isAtEnd() {
|
|
27791
27791
|
const e = Ie.get();
|
|
27792
27792
|
let t = e.focusNode;
|
|
27793
|
-
const n =
|
|
27794
|
-
if (
|
|
27793
|
+
const n = H.getDeepestNode(this.Editor.BlockManager.currentBlock.currentInput, !0);
|
|
27794
|
+
if (H.isNativeInput(n))
|
|
27795
27795
|
return n.selectionEnd === n.value.length;
|
|
27796
27796
|
if (!e.focusNode)
|
|
27797
27797
|
return !1;
|
|
27798
27798
|
let o = e.focusOffset;
|
|
27799
|
-
if (t.nodeType !== Node.TEXT_NODE && t.childNodes.length && (t.childNodes[o - 1] ? (t = t.childNodes[o - 1], o = t.textContent.length) : (t = t.childNodes[0], o = 0)),
|
|
27799
|
+
if (t.nodeType !== Node.TEXT_NODE && t.childNodes.length && (t.childNodes[o - 1] ? (t = t.childNodes[o - 1], o = t.textContent.length) : (t = t.childNodes[0], o = 0)), H.isLineBreakTag(n) || H.isEmpty(n)) {
|
|
27800
27800
|
const a = this.getHigherLevelSiblings(t, "right");
|
|
27801
|
-
if (a.every((s, M) => M === a.length - 1 &&
|
|
27801
|
+
if (a.every((s, M) => M === a.length - 1 && H.isLineBreakTag(s) || H.isEmpty(s) && !H.isLineBreakTag(s)) && o === t.textContent.length)
|
|
27802
27802
|
return !0;
|
|
27803
27803
|
}
|
|
27804
27804
|
const r = n.textContent.replace(/\s+$/, "");
|
|
@@ -27830,7 +27830,7 @@ class vs extends Ce {
|
|
|
27830
27830
|
}
|
|
27831
27831
|
if (!r)
|
|
27832
27832
|
return;
|
|
27833
|
-
const a =
|
|
27833
|
+
const a = H.getDeepestNode(r, t === this.positions.END), s = H.getContentLength(a);
|
|
27834
27834
|
switch (!0) {
|
|
27835
27835
|
case t === this.positions.START:
|
|
27836
27836
|
n = 0;
|
|
@@ -27853,13 +27853,13 @@ class vs extends Ce {
|
|
|
27853
27853
|
* @param {number} offset - caret offset regarding to the text node
|
|
27854
27854
|
*/
|
|
27855
27855
|
setToInput(e, t = this.positions.DEFAULT, n = 0) {
|
|
27856
|
-
const { currentBlock: o } = this.Editor.BlockManager, r =
|
|
27856
|
+
const { currentBlock: o } = this.Editor.BlockManager, r = H.getDeepestNode(e);
|
|
27857
27857
|
switch (t) {
|
|
27858
27858
|
case this.positions.START:
|
|
27859
27859
|
this.set(r, 0);
|
|
27860
27860
|
break;
|
|
27861
27861
|
case this.positions.END:
|
|
27862
|
-
this.set(r,
|
|
27862
|
+
this.set(r, H.getContentLength(r));
|
|
27863
27863
|
break;
|
|
27864
27864
|
default:
|
|
27865
27865
|
n && this.set(r, n);
|
|
@@ -27898,7 +27898,7 @@ class vs extends Ce {
|
|
|
27898
27898
|
if (e.rangeCount) {
|
|
27899
27899
|
const t = e.getRangeAt(0), n = this.Editor.BlockManager.currentBlock.currentInput;
|
|
27900
27900
|
if (t.deleteContents(), n)
|
|
27901
|
-
if (
|
|
27901
|
+
if (H.isNativeInput(n)) {
|
|
27902
27902
|
const o = n, r = document.createDocumentFragment(), a = o.value.substring(0, o.selectionStart), s = o.value.substring(o.selectionStart);
|
|
27903
27903
|
return r.textContent = s, o.value = a, r;
|
|
27904
27904
|
} else {
|
|
@@ -28307,7 +28307,7 @@ const II = class extends Ce {
|
|
|
28307
28307
|
}
|
|
28308
28308
|
e && r.trim() && a.trim() && (a = "<p>" + (a.trim() ? a : r) + "</p>");
|
|
28309
28309
|
const s = Object.keys(this.toolsTags).reduce((l, c) => (l[c.toLowerCase()] = this.toolsTags[c].sanitizationConfig ?? {}, l), {}), M = Object.assign({}, s, t.getAllInlineToolsSanitizeConfig(), { br: {} }), u = Yi(a, M);
|
|
28310
|
-
!u.trim() || u.trim() === r || !
|
|
28310
|
+
!u.trim() || u.trim() === r || !H.isHTMLString(u) ? await this.processText(r) : await this.processText(u, !0);
|
|
28311
28311
|
}
|
|
28312
28312
|
/**
|
|
28313
28313
|
* Process pasted text and divide them into Blocks
|
|
@@ -28422,7 +28422,7 @@ const II = class extends Ce {
|
|
|
28422
28422
|
* @returns {boolean}
|
|
28423
28423
|
*/
|
|
28424
28424
|
isNativeBehaviour(i) {
|
|
28425
|
-
return
|
|
28425
|
+
return H.isNativeInput(i);
|
|
28426
28426
|
}
|
|
28427
28427
|
/**
|
|
28428
28428
|
* Get files from data transfer object and insert related Tools
|
|
@@ -28472,12 +28472,12 @@ const II = class extends Ce {
|
|
|
28472
28472
|
* @returns {PasteData[]}
|
|
28473
28473
|
*/
|
|
28474
28474
|
processHTML(i) {
|
|
28475
|
-
const { Tools: e } = this.Editor, t =
|
|
28475
|
+
const { Tools: e } = this.Editor, t = H.make("DIV");
|
|
28476
28476
|
return t.innerHTML = i, this.getNodes(t).map((n) => {
|
|
28477
28477
|
let o, r = e.defaultTool, a = !1;
|
|
28478
28478
|
switch (n.nodeType) {
|
|
28479
28479
|
case Node.DOCUMENT_FRAGMENT_NODE:
|
|
28480
|
-
o =
|
|
28480
|
+
o = H.make("div"), o.appendChild(n);
|
|
28481
28481
|
break;
|
|
28482
28482
|
case Node.ELEMENT_NODE:
|
|
28483
28483
|
o = n, a = !0, this.toolsTags[o.tagName] && (r = this.toolsTags[o.tagName].tool);
|
|
@@ -28489,7 +28489,7 @@ const II = class extends Ce {
|
|
|
28489
28489
|
}), c), {}), u = Object.assign({}, M, r.baseSanitizeConfig);
|
|
28490
28490
|
if (o.tagName.toLowerCase() === "table") {
|
|
28491
28491
|
const c = Yi(o.outerHTML, u);
|
|
28492
|
-
o =
|
|
28492
|
+
o = H.make("div", void 0, {
|
|
28493
28493
|
innerHTML: c
|
|
28494
28494
|
}).firstChild;
|
|
28495
28495
|
} else
|
|
@@ -28504,7 +28504,7 @@ const II = class extends Ce {
|
|
|
28504
28504
|
event: l
|
|
28505
28505
|
};
|
|
28506
28506
|
}).filter((n) => {
|
|
28507
|
-
const o =
|
|
28507
|
+
const o = H.isEmpty(n.content), r = H.isSingleTag(n.content);
|
|
28508
28508
|
return !o || r;
|
|
28509
28509
|
});
|
|
28510
28510
|
}
|
|
@@ -28520,7 +28520,7 @@ const II = class extends Ce {
|
|
|
28520
28520
|
return [];
|
|
28521
28521
|
const t = e;
|
|
28522
28522
|
return i.split(/\r?\n/).filter((n) => n.trim()).map((n) => {
|
|
28523
|
-
const o =
|
|
28523
|
+
const o = H.make("div");
|
|
28524
28524
|
o.textContent = n;
|
|
28525
28525
|
const r = this.composePasteEvent("tag", {
|
|
28526
28526
|
data: o
|
|
@@ -28540,7 +28540,7 @@ const II = class extends Ce {
|
|
|
28540
28540
|
*/
|
|
28541
28541
|
async processSingleBlock(i) {
|
|
28542
28542
|
const { Caret: e, BlockManager: t } = this.Editor, { currentBlock: n } = t;
|
|
28543
|
-
if (!n || i.tool !== n.name || !
|
|
28543
|
+
if (!n || i.tool !== n.name || !H.containsOnlyInlineElements(i.content.innerHTML)) {
|
|
28544
28544
|
this.insertBlock(i, (n == null ? void 0 : n.tool.isDefault) && n.isEmpty);
|
|
28545
28545
|
return;
|
|
28546
28546
|
}
|
|
@@ -28639,10 +28639,10 @@ const II = class extends Ce {
|
|
|
28639
28639
|
* @param {Node} destNode - destination node
|
|
28640
28640
|
*/
|
|
28641
28641
|
processElementNode(i, e, t) {
|
|
28642
|
-
const n = Object.keys(this.toolsTags), o = i, { tool: r } = this.toolsTags[o.tagName] || {}, a = this.tagsByTool[r == null ? void 0 : r.name] || [], s = n.includes(o.tagName), M =
|
|
28642
|
+
const n = Object.keys(this.toolsTags), o = i, { tool: r } = this.toolsTags[o.tagName] || {}, a = this.tagsByTool[r == null ? void 0 : r.name] || [], s = n.includes(o.tagName), M = H.blockElements.includes(o.tagName.toLowerCase()), u = Array.from(o.children).some(
|
|
28643
28643
|
({ tagName: c }) => n.includes(c) && !a.includes(c)
|
|
28644
28644
|
), l = Array.from(o.children).some(
|
|
28645
|
-
({ tagName: c }) =>
|
|
28645
|
+
({ tagName: c }) => H.blockElements.includes(c.toLowerCase())
|
|
28646
28646
|
);
|
|
28647
28647
|
if (!M && !s && !u)
|
|
28648
28648
|
return t.appendChild(o), [...e, t];
|
|
@@ -28661,11 +28661,11 @@ const II = class extends Ce {
|
|
|
28661
28661
|
const e = Array.from(i.childNodes);
|
|
28662
28662
|
let t;
|
|
28663
28663
|
const n = (o, r) => {
|
|
28664
|
-
if (
|
|
28664
|
+
if (H.isEmpty(r) && !H.isSingleTag(r))
|
|
28665
28665
|
return o;
|
|
28666
28666
|
const a = o[o.length - 1];
|
|
28667
28667
|
let s = new DocumentFragment();
|
|
28668
|
-
switch (a &&
|
|
28668
|
+
switch (a && H.isFragment(a) && (s = o.pop()), r.nodeType) {
|
|
28669
28669
|
case Node.ELEMENT_NODE:
|
|
28670
28670
|
if (t = this.processElementNode(r, o, s), t)
|
|
28671
28671
|
return t;
|
|
@@ -28824,7 +28824,7 @@ class Vo extends Ce {
|
|
|
28824
28824
|
* @param {MouseEvent} mouseEvent - mouse event payload
|
|
28825
28825
|
*/
|
|
28826
28826
|
processMouseDown(e) {
|
|
28827
|
-
e.button === this.MAIN_MOUSE_BUTTON && (e.target.closest(
|
|
28827
|
+
e.button === this.MAIN_MOUSE_BUTTON && (e.target.closest(H.allInputsSelector) !== null || this.startSelection(e.pageX, e.pageY));
|
|
28828
28828
|
}
|
|
28829
28829
|
/**
|
|
28830
28830
|
* Handle mouse move events
|
|
@@ -28870,7 +28870,7 @@ class Vo extends Ce {
|
|
|
28870
28870
|
* @returns {Object<string, Element>}
|
|
28871
28871
|
*/
|
|
28872
28872
|
genHTML() {
|
|
28873
|
-
const { UI: e } = this.Editor, t = e.nodes.holder.querySelector("." + e.CSS.editorWrapper), n =
|
|
28873
|
+
const { UI: e } = this.Editor, t = e.nodes.holder.querySelector("." + e.CSS.editorWrapper), n = H.make("div", Vo.CSS.overlay, {}), o = H.make("div", Vo.CSS.overlayContainer, {}), r = H.make("div", Vo.CSS.rect, {});
|
|
28874
28874
|
return o.appendChild(r), n.appendChild(o), t.appendChild(n), this.overlayRectangle = r, {
|
|
28875
28875
|
container: t,
|
|
28876
28876
|
overlay: n
|
|
@@ -29733,9 +29733,9 @@ class DI {
|
|
|
29733
29733
|
* @returns {HTMLElement}
|
|
29734
29734
|
*/
|
|
29735
29735
|
make() {
|
|
29736
|
-
const e =
|
|
29736
|
+
const e = H.make("div", this.CSS.wrapper), t = GC, n = H.make("div", this.CSS.info), o = H.make("div", this.CSS.title, {
|
|
29737
29737
|
textContent: this.title
|
|
29738
|
-
}), r =
|
|
29738
|
+
}), r = H.make("div", this.CSS.subtitle, {
|
|
29739
29739
|
textContent: this.subtitle
|
|
29740
29740
|
});
|
|
29741
29741
|
return e.innerHTML = t, n.appendChild(o), n.appendChild(r), e.appendChild(n), e;
|
|
@@ -30432,23 +30432,23 @@ class T2 extends Ce {
|
|
|
30432
30432
|
* Makes Editor.js interface
|
|
30433
30433
|
*/
|
|
30434
30434
|
make() {
|
|
30435
|
-
this.nodes.holder =
|
|
30435
|
+
this.nodes.holder = H.getHolder(this.config.holder), this.nodes.wrapper = H.make("div", [
|
|
30436
30436
|
this.CSS.editorWrapper,
|
|
30437
30437
|
...this.isRtl ? [this.CSS.editorRtlFix] : []
|
|
30438
|
-
]), this.nodes.redactor =
|
|
30438
|
+
]), this.nodes.redactor = H.make("div", this.CSS.editorZone), this.nodes.holder.offsetWidth < this.contentRect.width && this.nodes.wrapper.classList.add(this.CSS.editorWrapperNarrow), this.nodes.redactor.style.paddingBottom = this.config.minHeight + "px", this.nodes.wrapper.appendChild(this.nodes.redactor), this.nodes.holder.appendChild(this.nodes.wrapper);
|
|
30439
30439
|
}
|
|
30440
30440
|
/**
|
|
30441
30441
|
* Appends CSS
|
|
30442
30442
|
*/
|
|
30443
30443
|
loadStyles() {
|
|
30444
30444
|
const e = "editor-js-styles";
|
|
30445
|
-
if (
|
|
30445
|
+
if (H.get(e))
|
|
30446
30446
|
return;
|
|
30447
|
-
const t =
|
|
30447
|
+
const t = H.make("style", null, {
|
|
30448
30448
|
id: e,
|
|
30449
30449
|
textContent: A2.toString()
|
|
30450
30450
|
});
|
|
30451
|
-
|
|
30451
|
+
H.prepend(document.head, t);
|
|
30452
30452
|
}
|
|
30453
30453
|
/**
|
|
30454
30454
|
* Bind events on the Editor.js interface
|
|
@@ -30627,13 +30627,13 @@ class T2 extends Ce {
|
|
|
30627
30627
|
const n = () => {
|
|
30628
30628
|
e.stopImmediatePropagation(), e.stopPropagation();
|
|
30629
30629
|
}, o = e.target, r = e.metaKey || e.ctrlKey;
|
|
30630
|
-
if (
|
|
30630
|
+
if (H.isAnchor(o) && r) {
|
|
30631
30631
|
n();
|
|
30632
30632
|
const u = o.getAttribute("href"), l = JS(u);
|
|
30633
30633
|
KS(l);
|
|
30634
30634
|
return;
|
|
30635
30635
|
}
|
|
30636
|
-
const a = this.Editor.BlockManager.getBlockByIndex(-1), s =
|
|
30636
|
+
const a = this.Editor.BlockManager.getBlockByIndex(-1), s = H.offset(a.holder).bottom, M = e.pageY;
|
|
30637
30637
|
if (e.target instanceof Element && e.target.isEqualNode(this.nodes.redactor) && /**
|
|
30638
30638
|
* If there is cross block selection started, target will be equal to redactor so we need additional check
|
|
30639
30639
|
*/
|
|
@@ -30759,9 +30759,9 @@ class m2 {
|
|
|
30759
30759
|
const { holderId: e, holder: t } = this.config;
|
|
30760
30760
|
if (e && t)
|
|
30761
30761
|
throw Error("«holderId» and «holder» param can't assign at the same time.");
|
|
30762
|
-
if (Mn(t) && !
|
|
30762
|
+
if (Mn(t) && !H.get(t))
|
|
30763
30763
|
throw Error(`element with ID «${t}» is missing. Pass correct holder's ID.`);
|
|
30764
|
-
if (t && vt(t) && !
|
|
30764
|
+
if (t && vt(t) && !H.isElement(t))
|
|
30765
30765
|
throw Error("«holder» value must be an Element node");
|
|
30766
30766
|
}
|
|
30767
30767
|
/**
|
|
@@ -31093,11 +31093,11 @@ var xI = { exports: {} };
|
|
|
31093
31093
|
var w = document.createElement("link");
|
|
31094
31094
|
return T.attrs.type === void 0 && (T.attrs.type = "text/css"), T.attrs.rel = "stylesheet", x(w, T.attrs), y(T, w), w;
|
|
31095
31095
|
}(h), z = (function(T, w, C) {
|
|
31096
|
-
var Y = C.css, G = C.sourceMap,
|
|
31097
|
-
(w.convertToAbsoluteUrls ||
|
|
31096
|
+
var Y = C.css, G = C.sourceMap, W = w.convertToAbsoluteUrls === void 0 && G;
|
|
31097
|
+
(w.convertToAbsoluteUrls || W) && (Y = j(Y)), G && (Y += `
|
|
31098
31098
|
/*# sourceMappingURL=data:application/json;base64,` + btoa(unescape(encodeURIComponent(JSON.stringify(G)))) + " */");
|
|
31099
|
-
var U = new Blob([Y], { type: "text/css" }),
|
|
31100
|
-
T.href = URL.createObjectURL(U),
|
|
31099
|
+
var U = new Blob([Y], { type: "text/css" }), V = T.href;
|
|
31100
|
+
T.href = URL.createObjectURL(U), V && URL.revokeObjectURL(V);
|
|
31101
31101
|
}).bind(null, O, h), f = function() {
|
|
31102
31102
|
d(O), O.href && URL.revokeObjectURL(O.href);
|
|
31103
31103
|
}) : (O = p(h), z = (function(T, w) {
|
|
@@ -31687,11 +31687,11 @@ var LI = { exports: {} };
|
|
|
31687
31687
|
var w = document.createElement("link");
|
|
31688
31688
|
return T.attrs.type === void 0 && (T.attrs.type = "text/css"), T.attrs.rel = "stylesheet", x(w, T.attrs), y(T, w), w;
|
|
31689
31689
|
}(h), z = (function(T, w, C) {
|
|
31690
|
-
var Y = C.css, G = C.sourceMap,
|
|
31691
|
-
(w.convertToAbsoluteUrls ||
|
|
31690
|
+
var Y = C.css, G = C.sourceMap, W = w.convertToAbsoluteUrls === void 0 && G;
|
|
31691
|
+
(w.convertToAbsoluteUrls || W) && (Y = j(Y)), G && (Y += `
|
|
31692
31692
|
/*# sourceMappingURL=data:application/json;base64,` + btoa(unescape(encodeURIComponent(JSON.stringify(G)))) + " */");
|
|
31693
|
-
var U = new Blob([Y], { type: "text/css" }),
|
|
31694
|
-
T.href = URL.createObjectURL(U),
|
|
31693
|
+
var U = new Blob([Y], { type: "text/css" }), V = T.href;
|
|
31694
|
+
T.href = URL.createObjectURL(U), V && URL.revokeObjectURL(V);
|
|
31695
31695
|
}).bind(null, O, h), f = function() {
|
|
31696
31696
|
d(O), O.href && URL.revokeObjectURL(O.href);
|
|
31697
31697
|
}) : (O = p(h), z = (function(T, w) {
|
|
@@ -33930,11 +33930,11 @@ var EI = { exports: {} };
|
|
|
33930
33930
|
var w = document.createElement("link");
|
|
33931
33931
|
return T.attrs.type === void 0 && (T.attrs.type = "text/css"), T.attrs.rel = "stylesheet", x(w, T.attrs), y(T, w), w;
|
|
33932
33932
|
}(h), z = (function(T, w, C) {
|
|
33933
|
-
var Y = C.css, G = C.sourceMap,
|
|
33934
|
-
(w.convertToAbsoluteUrls ||
|
|
33933
|
+
var Y = C.css, G = C.sourceMap, W = w.convertToAbsoluteUrls === void 0 && G;
|
|
33934
|
+
(w.convertToAbsoluteUrls || W) && (Y = j(Y)), G && (Y += `
|
|
33935
33935
|
/*# sourceMappingURL=data:application/json;base64,` + btoa(unescape(encodeURIComponent(JSON.stringify(G)))) + " */");
|
|
33936
|
-
var U = new Blob([Y], { type: "text/css" }),
|
|
33937
|
-
T.href = URL.createObjectURL(U),
|
|
33936
|
+
var U = new Blob([Y], { type: "text/css" }), V = T.href;
|
|
33937
|
+
T.href = URL.createObjectURL(U), V && URL.revokeObjectURL(V);
|
|
33938
33938
|
}).bind(null, O, h), f = function() {
|
|
33939
33939
|
d(O), O.href && URL.revokeObjectURL(O.href);
|
|
33940
33940
|
}) : (O = p(h), z = (function(T, w) {
|
|
@@ -34540,29 +34540,29 @@ var SI = { exports: {} };
|
|
|
34540
34540
|
}, 666: (a) => {
|
|
34541
34541
|
var s = function(M) {
|
|
34542
34542
|
var u, l = Object.prototype, c = l.hasOwnProperty, g = typeof Symbol == "function" ? Symbol : {}, j = g.iterator || "@@iterator", N = g.asyncIterator || "@@asyncIterator", D = g.toStringTag || "@@toStringTag";
|
|
34543
|
-
function y(P,
|
|
34544
|
-
return Object.defineProperty(P,
|
|
34543
|
+
function y(P, $, ie) {
|
|
34544
|
+
return Object.defineProperty(P, $, { value: ie, enumerable: !0, configurable: !0, writable: !0 }), P[$];
|
|
34545
34545
|
}
|
|
34546
34546
|
try {
|
|
34547
34547
|
y({}, "");
|
|
34548
34548
|
} catch {
|
|
34549
|
-
y = function(
|
|
34550
|
-
return
|
|
34549
|
+
y = function($, ie, F) {
|
|
34550
|
+
return $[ie] = F;
|
|
34551
34551
|
};
|
|
34552
34552
|
}
|
|
34553
|
-
function d(P,
|
|
34554
|
-
var ee =
|
|
34553
|
+
function d(P, $, ie, F) {
|
|
34554
|
+
var ee = $ && $.prototype instanceof I ? $ : I, le = Object.create(ee.prototype), ue = new W(F || []);
|
|
34555
34555
|
return le._invoke = function(xe, Ve, ve) {
|
|
34556
34556
|
var Xe = x;
|
|
34557
|
-
return function(Pe,
|
|
34557
|
+
return function(Pe, J) {
|
|
34558
34558
|
if (Xe === m)
|
|
34559
34559
|
throw new Error("Generator is already running");
|
|
34560
34560
|
if (Xe === A) {
|
|
34561
34561
|
if (Pe === "throw")
|
|
34562
|
-
throw
|
|
34563
|
-
return
|
|
34562
|
+
throw J;
|
|
34563
|
+
return V();
|
|
34564
34564
|
}
|
|
34565
|
-
for (ve.method = Pe, ve.arg =
|
|
34565
|
+
for (ve.method = Pe, ve.arg = J; ; ) {
|
|
34566
34566
|
var me = ve.delegate;
|
|
34567
34567
|
if (me) {
|
|
34568
34568
|
var be = C(me, ve);
|
|
@@ -34592,11 +34592,11 @@ var SI = { exports: {} };
|
|
|
34592
34592
|
};
|
|
34593
34593
|
}(P, ie, ue), le;
|
|
34594
34594
|
}
|
|
34595
|
-
function p(P,
|
|
34595
|
+
function p(P, $, ie) {
|
|
34596
34596
|
try {
|
|
34597
|
-
return { type: "normal", arg: P.call(
|
|
34598
|
-
} catch (
|
|
34599
|
-
return { type: "throw", arg:
|
|
34597
|
+
return { type: "normal", arg: P.call($, ie) };
|
|
34598
|
+
} catch (F) {
|
|
34599
|
+
return { type: "throw", arg: F };
|
|
34600
34600
|
}
|
|
34601
34601
|
}
|
|
34602
34602
|
M.wrap = d;
|
|
@@ -34615,22 +34615,22 @@ var SI = { exports: {} };
|
|
|
34615
34615
|
L && L !== l && c.call(L, j) && (z = L);
|
|
34616
34616
|
var E = O.prototype = I.prototype = Object.create(z);
|
|
34617
34617
|
function T(P) {
|
|
34618
|
-
["next", "throw", "return"].forEach(function(
|
|
34619
|
-
y(P,
|
|
34620
|
-
return this._invoke(
|
|
34618
|
+
["next", "throw", "return"].forEach(function($) {
|
|
34619
|
+
y(P, $, function(ie) {
|
|
34620
|
+
return this._invoke($, ie);
|
|
34621
34621
|
});
|
|
34622
34622
|
});
|
|
34623
34623
|
}
|
|
34624
|
-
function w(P,
|
|
34624
|
+
function w(P, $) {
|
|
34625
34625
|
function ie(ee, le, ue, xe) {
|
|
34626
34626
|
var Ve = p(P[ee], P, le);
|
|
34627
34627
|
if (Ve.type !== "throw") {
|
|
34628
34628
|
var ve = Ve.arg, Xe = ve.value;
|
|
34629
|
-
return Xe && typeof Xe == "object" && c.call(Xe, "__await") ?
|
|
34629
|
+
return Xe && typeof Xe == "object" && c.call(Xe, "__await") ? $.resolve(Xe.__await).then(function(Pe) {
|
|
34630
34630
|
ie("next", Pe, ue, xe);
|
|
34631
34631
|
}, function(Pe) {
|
|
34632
34632
|
ie("throw", Pe, ue, xe);
|
|
34633
|
-
}) :
|
|
34633
|
+
}) : $.resolve(Xe).then(function(Pe) {
|
|
34634
34634
|
ve.value = Pe, ue(ve);
|
|
34635
34635
|
}, function(Pe) {
|
|
34636
34636
|
return ie("throw", Pe, ue, xe);
|
|
@@ -34638,78 +34638,78 @@ var SI = { exports: {} };
|
|
|
34638
34638
|
}
|
|
34639
34639
|
xe(Ve.arg);
|
|
34640
34640
|
}
|
|
34641
|
-
var
|
|
34641
|
+
var F;
|
|
34642
34642
|
this._invoke = function(ee, le) {
|
|
34643
34643
|
function ue() {
|
|
34644
|
-
return new
|
|
34644
|
+
return new $(function(xe, Ve) {
|
|
34645
34645
|
ie(ee, le, xe, Ve);
|
|
34646
34646
|
});
|
|
34647
34647
|
}
|
|
34648
|
-
return
|
|
34648
|
+
return F = F ? F.then(ue, ue) : ue();
|
|
34649
34649
|
};
|
|
34650
34650
|
}
|
|
34651
|
-
function C(P,
|
|
34652
|
-
var ie = P.iterator[
|
|
34651
|
+
function C(P, $) {
|
|
34652
|
+
var ie = P.iterator[$.method];
|
|
34653
34653
|
if (ie === u) {
|
|
34654
|
-
if (
|
|
34655
|
-
if (P.iterator.return && (
|
|
34654
|
+
if ($.delegate = null, $.method === "throw") {
|
|
34655
|
+
if (P.iterator.return && ($.method = "return", $.arg = u, C(P, $), $.method === "throw"))
|
|
34656
34656
|
return b;
|
|
34657
|
-
|
|
34657
|
+
$.method = "throw", $.arg = new TypeError("The iterator does not provide a 'throw' method");
|
|
34658
34658
|
}
|
|
34659
34659
|
return b;
|
|
34660
34660
|
}
|
|
34661
|
-
var
|
|
34662
|
-
if (
|
|
34663
|
-
return
|
|
34664
|
-
var ee =
|
|
34665
|
-
return ee ? ee.done ? (
|
|
34661
|
+
var F = p(ie, P.iterator, $.arg);
|
|
34662
|
+
if (F.type === "throw")
|
|
34663
|
+
return $.method = "throw", $.arg = F.arg, $.delegate = null, b;
|
|
34664
|
+
var ee = F.arg;
|
|
34665
|
+
return ee ? ee.done ? ($[P.resultName] = ee.value, $.next = P.nextLoc, $.method !== "return" && ($.method = "next", $.arg = u), $.delegate = null, b) : ee : ($.method = "throw", $.arg = new TypeError("iterator result is not an object"), $.delegate = null, b);
|
|
34666
34666
|
}
|
|
34667
34667
|
function Y(P) {
|
|
34668
|
-
var
|
|
34669
|
-
1 in P && (
|
|
34668
|
+
var $ = { tryLoc: P[0] };
|
|
34669
|
+
1 in P && ($.catchLoc = P[1]), 2 in P && ($.finallyLoc = P[2], $.afterLoc = P[3]), this.tryEntries.push($);
|
|
34670
34670
|
}
|
|
34671
34671
|
function G(P) {
|
|
34672
|
-
var
|
|
34673
|
-
|
|
34672
|
+
var $ = P.completion || {};
|
|
34673
|
+
$.type = "normal", delete $.arg, P.completion = $;
|
|
34674
34674
|
}
|
|
34675
|
-
function
|
|
34675
|
+
function W(P) {
|
|
34676
34676
|
this.tryEntries = [{ tryLoc: "root" }], P.forEach(Y, this), this.reset(!0);
|
|
34677
34677
|
}
|
|
34678
34678
|
function U(P) {
|
|
34679
34679
|
if (P) {
|
|
34680
|
-
var
|
|
34681
|
-
if (
|
|
34682
|
-
return
|
|
34680
|
+
var $ = P[j];
|
|
34681
|
+
if ($)
|
|
34682
|
+
return $.call(P);
|
|
34683
34683
|
if (typeof P.next == "function")
|
|
34684
34684
|
return P;
|
|
34685
34685
|
if (!isNaN(P.length)) {
|
|
34686
|
-
var ie = -1,
|
|
34686
|
+
var ie = -1, F = function ee() {
|
|
34687
34687
|
for (; ++ie < P.length; )
|
|
34688
34688
|
if (c.call(P, ie))
|
|
34689
34689
|
return ee.value = P[ie], ee.done = !1, ee;
|
|
34690
34690
|
return ee.value = u, ee.done = !0, ee;
|
|
34691
34691
|
};
|
|
34692
|
-
return
|
|
34692
|
+
return F.next = F;
|
|
34693
34693
|
}
|
|
34694
34694
|
}
|
|
34695
|
-
return { next:
|
|
34695
|
+
return { next: V };
|
|
34696
34696
|
}
|
|
34697
|
-
function
|
|
34697
|
+
function V() {
|
|
34698
34698
|
return { value: u, done: !0 };
|
|
34699
34699
|
}
|
|
34700
34700
|
return h.prototype = O, y(E, "constructor", O), y(O, "constructor", h), h.displayName = y(O, D, "GeneratorFunction"), M.isGeneratorFunction = function(P) {
|
|
34701
|
-
var
|
|
34702
|
-
return
|
|
34701
|
+
var $ = typeof P == "function" && P.constructor;
|
|
34702
|
+
return !!$ && ($ === h || ($.displayName || $.name) === "GeneratorFunction");
|
|
34703
34703
|
}, M.mark = function(P) {
|
|
34704
34704
|
return Object.setPrototypeOf ? Object.setPrototypeOf(P, O) : (P.__proto__ = O, y(P, D, "GeneratorFunction")), P.prototype = Object.create(E), P;
|
|
34705
34705
|
}, M.awrap = function(P) {
|
|
34706
34706
|
return { __await: P };
|
|
34707
34707
|
}, T(w.prototype), y(w.prototype, N, function() {
|
|
34708
34708
|
return this;
|
|
34709
|
-
}), M.AsyncIterator = w, M.async = function(P,
|
|
34709
|
+
}), M.AsyncIterator = w, M.async = function(P, $, ie, F, ee) {
|
|
34710
34710
|
ee === void 0 && (ee = Promise);
|
|
34711
|
-
var le = new w(d(P,
|
|
34712
|
-
return M.isGeneratorFunction(
|
|
34711
|
+
var le = new w(d(P, $, ie, F), ee);
|
|
34712
|
+
return M.isGeneratorFunction($) ? le : le.next().then(function(ue) {
|
|
34713
34713
|
return ue.done ? ue.value : le.next();
|
|
34714
34714
|
});
|
|
34715
34715
|
}, T(E), y(E, D, "Generator"), y(E, j, function() {
|
|
@@ -34717,21 +34717,21 @@ var SI = { exports: {} };
|
|
|
34717
34717
|
}), y(E, "toString", function() {
|
|
34718
34718
|
return "[object Generator]";
|
|
34719
34719
|
}), M.keys = function(P) {
|
|
34720
|
-
var
|
|
34720
|
+
var $ = [];
|
|
34721
34721
|
for (var ie in P)
|
|
34722
|
-
|
|
34723
|
-
return
|
|
34724
|
-
for (;
|
|
34725
|
-
var ee =
|
|
34722
|
+
$.push(ie);
|
|
34723
|
+
return $.reverse(), function F() {
|
|
34724
|
+
for (; $.length; ) {
|
|
34725
|
+
var ee = $.pop();
|
|
34726
34726
|
if (ee in P)
|
|
34727
|
-
return
|
|
34727
|
+
return F.value = ee, F.done = !1, F;
|
|
34728
34728
|
}
|
|
34729
|
-
return
|
|
34729
|
+
return F.done = !0, F;
|
|
34730
34730
|
};
|
|
34731
|
-
}, M.values = U,
|
|
34731
|
+
}, M.values = U, W.prototype = { constructor: W, reset: function(P) {
|
|
34732
34732
|
if (this.prev = 0, this.next = 0, this.sent = this._sent = u, this.done = !1, this.delegate = null, this.method = "next", this.arg = u, this.tryEntries.forEach(G), !P)
|
|
34733
|
-
for (var
|
|
34734
|
-
|
|
34733
|
+
for (var $ in this)
|
|
34734
|
+
$.charAt(0) === "t" && c.call(this, $) && !isNaN(+$.slice(1)) && (this[$] = u);
|
|
34735
34735
|
}, stop: function() {
|
|
34736
34736
|
this.done = !0;
|
|
34737
34737
|
var P = this.tryEntries[0].completion;
|
|
@@ -34741,12 +34741,12 @@ var SI = { exports: {} };
|
|
|
34741
34741
|
}, dispatchException: function(P) {
|
|
34742
34742
|
if (this.done)
|
|
34743
34743
|
throw P;
|
|
34744
|
-
var
|
|
34744
|
+
var $ = this;
|
|
34745
34745
|
function ie(Ve, ve) {
|
|
34746
|
-
return le.type = "throw", le.arg = P,
|
|
34746
|
+
return le.type = "throw", le.arg = P, $.next = Ve, ve && ($.method = "next", $.arg = u), !!ve;
|
|
34747
34747
|
}
|
|
34748
|
-
for (var
|
|
34749
|
-
var ee = this.tryEntries[
|
|
34748
|
+
for (var F = this.tryEntries.length - 1; F >= 0; --F) {
|
|
34749
|
+
var ee = this.tryEntries[F], le = ee.completion;
|
|
34750
34750
|
if (ee.tryLoc === "root")
|
|
34751
34751
|
return ie("end");
|
|
34752
34752
|
if (ee.tryLoc <= this.prev) {
|
|
@@ -34767,42 +34767,42 @@ var SI = { exports: {} };
|
|
|
34767
34767
|
}
|
|
34768
34768
|
}
|
|
34769
34769
|
}
|
|
34770
|
-
}, abrupt: function(P,
|
|
34770
|
+
}, abrupt: function(P, $) {
|
|
34771
34771
|
for (var ie = this.tryEntries.length - 1; ie >= 0; --ie) {
|
|
34772
|
-
var
|
|
34773
|
-
if (
|
|
34774
|
-
var ee =
|
|
34772
|
+
var F = this.tryEntries[ie];
|
|
34773
|
+
if (F.tryLoc <= this.prev && c.call(F, "finallyLoc") && this.prev < F.finallyLoc) {
|
|
34774
|
+
var ee = F;
|
|
34775
34775
|
break;
|
|
34776
34776
|
}
|
|
34777
34777
|
}
|
|
34778
|
-
ee && (P === "break" || P === "continue") && ee.tryLoc <=
|
|
34778
|
+
ee && (P === "break" || P === "continue") && ee.tryLoc <= $ && $ <= ee.finallyLoc && (ee = null);
|
|
34779
34779
|
var le = ee ? ee.completion : {};
|
|
34780
|
-
return le.type = P, le.arg =
|
|
34781
|
-
}, complete: function(P,
|
|
34780
|
+
return le.type = P, le.arg = $, ee ? (this.method = "next", this.next = ee.finallyLoc, b) : this.complete(le);
|
|
34781
|
+
}, complete: function(P, $) {
|
|
34782
34782
|
if (P.type === "throw")
|
|
34783
34783
|
throw P.arg;
|
|
34784
|
-
return P.type === "break" || P.type === "continue" ? this.next = P.arg : P.type === "return" ? (this.rval = this.arg = P.arg, this.method = "return", this.next = "end") : P.type === "normal" &&
|
|
34784
|
+
return P.type === "break" || P.type === "continue" ? this.next = P.arg : P.type === "return" ? (this.rval = this.arg = P.arg, this.method = "return", this.next = "end") : P.type === "normal" && $ && (this.next = $), b;
|
|
34785
34785
|
}, finish: function(P) {
|
|
34786
|
-
for (var
|
|
34787
|
-
var ie = this.tryEntries[
|
|
34786
|
+
for (var $ = this.tryEntries.length - 1; $ >= 0; --$) {
|
|
34787
|
+
var ie = this.tryEntries[$];
|
|
34788
34788
|
if (ie.finallyLoc === P)
|
|
34789
34789
|
return this.complete(ie.completion, ie.afterLoc), G(ie), b;
|
|
34790
34790
|
}
|
|
34791
34791
|
}, catch: function(P) {
|
|
34792
|
-
for (var
|
|
34793
|
-
var ie = this.tryEntries[
|
|
34792
|
+
for (var $ = this.tryEntries.length - 1; $ >= 0; --$) {
|
|
34793
|
+
var ie = this.tryEntries[$];
|
|
34794
34794
|
if (ie.tryLoc === P) {
|
|
34795
|
-
var
|
|
34796
|
-
if (
|
|
34797
|
-
var ee =
|
|
34795
|
+
var F = ie.completion;
|
|
34796
|
+
if (F.type === "throw") {
|
|
34797
|
+
var ee = F.arg;
|
|
34798
34798
|
G(ie);
|
|
34799
34799
|
}
|
|
34800
34800
|
return ee;
|
|
34801
34801
|
}
|
|
34802
34802
|
}
|
|
34803
34803
|
throw new Error("illegal catch attempt");
|
|
34804
|
-
}, delegateYield: function(P,
|
|
34805
|
-
return this.delegate = { iterator: U(P), resultName:
|
|
34804
|
+
}, delegateYield: function(P, $, ie) {
|
|
34805
|
+
return this.delegate = { iterator: U(P), resultName: $, nextLoc: ie }, this.method === "next" && (this.arg = u), b;
|
|
34806
34806
|
} }, M;
|
|
34807
34807
|
}(a.exports);
|
|
34808
34808
|
try {
|
|
@@ -34986,8 +34986,8 @@ var SI = { exports: {} };
|
|
|
34986
34986
|
var h = this, O = I.editor, z = I.config, f = z === void 0 ? {} : z, L = I.onUpdate, E = I.maxLength;
|
|
34987
34987
|
u(this, v);
|
|
34988
34988
|
var T = { maxLength: 30, onUpdate: function() {
|
|
34989
|
-
}, config: { debounceTimer: 200, shortcuts: { undo: ["CMD+Z"], redo: ["CMD+Y", "CMD+SHIFT+Z"] } } }, w = O.blocks, C = O.caret, Y = O.configuration, G = Y.holder,
|
|
34990
|
-
this.holder = typeof G == "string" ? document.getElementById(G) : G, this.editor = O, this.defaultBlock =
|
|
34989
|
+
}, config: { debounceTimer: 200, shortcuts: { undo: ["CMD+Z"], redo: ["CMD+Y", "CMD+SHIFT+Z"] } } }, w = O.blocks, C = O.caret, Y = O.configuration, G = Y.holder, W = Y.defaultBlock, U = T.config.shortcuts, V = f.shortcuts, P = p(p({}, U), V), $ = Array.isArray(P.undo) ? P.undo : [P.undo], ie = Array.isArray(P.redo) ? P.redo : [P.redo], F = T.config.debounceTimer, ee = f.debounceTimer, le = ee === void 0 ? F : ee;
|
|
34990
|
+
this.holder = typeof G == "string" ? document.getElementById(G) : G, this.editor = O, this.defaultBlock = W, this.blocks = w, this.caret = C, this.shouldSaveHistory = !0, this.readOnly = Y.readOnly, this.maxLength = E || T.maxLength, this.onUpdate = L || T.onUpdate, this.config = { debounceTimer: le, shortcuts: { undo: $, redo: ie } }, new y(function() {
|
|
34991
34991
|
return h.registerChange();
|
|
34992
34992
|
}, this.holder, this.config.debounceTimer).setMutationObserver(), this.setEventListeners(), this.initialItem = null, this.clear();
|
|
34993
34993
|
}
|
|
@@ -35038,68 +35038,68 @@ var SI = { exports: {} };
|
|
|
35038
35038
|
return I.length > h.length;
|
|
35039
35039
|
} }, { key: "undo", value: (b = s(j().mark(function I() {
|
|
35040
35040
|
var h, O, z, f, L, E, T, w, C, Y, G;
|
|
35041
|
-
return j().wrap(function(
|
|
35041
|
+
return j().wrap(function(W) {
|
|
35042
35042
|
for (; ; )
|
|
35043
|
-
switch (
|
|
35043
|
+
switch (W.prev = W.next) {
|
|
35044
35044
|
case 0:
|
|
35045
35045
|
if (!this.canUndo()) {
|
|
35046
|
-
|
|
35046
|
+
W.next = 43;
|
|
35047
35047
|
break;
|
|
35048
35048
|
}
|
|
35049
35049
|
if (h = this.stack[this.position], O = h.index, z = h.state, this.position -= 1, this.shouldSaveHistory = !1, f = this.stack[this.position].index, L = this.stack[this.position], E = L.state, T = L.caretIndex, this.onUpdate(), w = this.blocks.getBlocksCount(), E[f] || (f -= 1, this.stack[this.position].index = f), !this.blockWasDeleted(E, z)) {
|
|
35050
|
-
|
|
35050
|
+
W.next = 13;
|
|
35051
35051
|
break;
|
|
35052
35052
|
}
|
|
35053
|
-
this.insertDeletedBlock(E, z, f),
|
|
35053
|
+
this.insertDeletedBlock(E, z, f), W.next = 38;
|
|
35054
35054
|
break;
|
|
35055
35055
|
case 13:
|
|
35056
35056
|
if (!this.blockWasSkipped(f, O, E, z)) {
|
|
35057
|
-
|
|
35057
|
+
W.next = 19;
|
|
35058
35058
|
break;
|
|
35059
35059
|
}
|
|
35060
|
-
return
|
|
35060
|
+
return W.next = 16, this.blocks.delete(O);
|
|
35061
35061
|
case 16:
|
|
35062
|
-
this.caret.setToBlock(f, "end"),
|
|
35062
|
+
this.caret.setToBlock(f, "end"), W.next = 38;
|
|
35063
35063
|
break;
|
|
35064
35064
|
case 19:
|
|
35065
35065
|
if (!(w > E.length)) {
|
|
35066
|
-
|
|
35066
|
+
W.next = 27;
|
|
35067
35067
|
break;
|
|
35068
35068
|
}
|
|
35069
|
-
return
|
|
35069
|
+
return W.next = 22, this.blocks.render({ blocks: E });
|
|
35070
35070
|
case 22:
|
|
35071
|
-
return
|
|
35071
|
+
return W.next = 24, this.editor.blocks.insert(this.defaultBlock, {});
|
|
35072
35072
|
case 24:
|
|
35073
|
-
this.setCaretIndex(f, T),
|
|
35073
|
+
this.setCaretIndex(f, T), W.next = 38;
|
|
35074
35074
|
break;
|
|
35075
35075
|
case 27:
|
|
35076
35076
|
if (!this.blockWasDropped(E, z)) {
|
|
35077
|
-
|
|
35077
|
+
W.next = 33;
|
|
35078
35078
|
break;
|
|
35079
35079
|
}
|
|
35080
|
-
return
|
|
35080
|
+
return W.next = 30, this.blocks.render({ blocks: E });
|
|
35081
35081
|
case 30:
|
|
35082
|
-
this.caret.setToBlock(f, "end"),
|
|
35082
|
+
this.caret.setToBlock(f, "end"), W.next = 38;
|
|
35083
35083
|
break;
|
|
35084
35084
|
case 33:
|
|
35085
35085
|
if (!this.contentChangedInNoFocusBlock(f, O)) {
|
|
35086
|
-
|
|
35086
|
+
W.next = 38;
|
|
35087
35087
|
break;
|
|
35088
35088
|
}
|
|
35089
|
-
return C = this.blocks.getBlockByIndex(O), Y = C.id,
|
|
35089
|
+
return C = this.blocks.getBlockByIndex(O), Y = C.id, W.next = 37, this.blocks.update(Y, E[O].data);
|
|
35090
35090
|
case 37:
|
|
35091
35091
|
this.setCaretIndex(f, T);
|
|
35092
35092
|
case 38:
|
|
35093
35093
|
if (!(G = this.blocks.getBlockByIndex(f))) {
|
|
35094
|
-
|
|
35094
|
+
W.next = 43;
|
|
35095
35095
|
break;
|
|
35096
35096
|
}
|
|
35097
|
-
return
|
|
35097
|
+
return W.next = 42, this.blocks.update(G.id, E[f].data);
|
|
35098
35098
|
case 42:
|
|
35099
35099
|
this.setCaretIndex(f, T);
|
|
35100
35100
|
case 43:
|
|
35101
35101
|
case "end":
|
|
35102
|
-
return
|
|
35102
|
+
return W.stop();
|
|
35103
35103
|
}
|
|
35104
35104
|
}, I, this);
|
|
35105
35105
|
})), function() {
|
|
@@ -35196,27 +35196,27 @@ var SI = { exports: {} };
|
|
|
35196
35196
|
return I.parseKeys(U);
|
|
35197
35197
|
}), w = E.map(function(U) {
|
|
35198
35198
|
return I.parseKeys(U);
|
|
35199
|
-
}), C = function(U,
|
|
35200
|
-
return
|
|
35201
|
-
return P || function(ie,
|
|
35202
|
-
return
|
|
35203
|
-
}(U,
|
|
35199
|
+
}), C = function(U, V) {
|
|
35200
|
+
return V.reduce(function(P, $) {
|
|
35201
|
+
return P || function(ie, F) {
|
|
35202
|
+
return F.length === 3 && ie[F[0]] && ie[F[1]] && ie.key.toLowerCase() === F[2];
|
|
35203
|
+
}(U, $);
|
|
35204
35204
|
}, !1);
|
|
35205
|
-
}, Y = function(U,
|
|
35206
|
-
return !(!function(
|
|
35207
|
-
return ie.reduce(function(
|
|
35208
|
-
return
|
|
35205
|
+
}, Y = function(U, V, P) {
|
|
35206
|
+
return !(!function($, ie) {
|
|
35207
|
+
return ie.reduce(function(F, ee) {
|
|
35208
|
+
return F || function(le, ue) {
|
|
35209
35209
|
return ue.length === 2 && le[ue[0]] && le.key.toLowerCase() === ue[1];
|
|
35210
|
-
}(
|
|
35210
|
+
}($, ee);
|
|
35211
35211
|
}, !1);
|
|
35212
|
-
}(U,
|
|
35212
|
+
}(U, V) || C(U, P)) || !!C(U, V);
|
|
35213
35213
|
}, G = function(U) {
|
|
35214
35214
|
Y(U, T, w) && (U.preventDefault(), I.undo());
|
|
35215
|
-
},
|
|
35215
|
+
}, W = function(U) {
|
|
35216
35216
|
Y(U, w, T) && (U.preventDefault(), I.redo());
|
|
35217
35217
|
};
|
|
35218
|
-
h.addEventListener("keydown", G), h.addEventListener("keydown",
|
|
35219
|
-
h.removeEventListener("keydown", G), h.removeEventListener("keydown",
|
|
35218
|
+
h.addEventListener("keydown", G), h.addEventListener("keydown", W), h.addEventListener("destroy", function() {
|
|
35219
|
+
h.removeEventListener("keydown", G), h.removeEventListener("keydown", W);
|
|
35220
35220
|
});
|
|
35221
35221
|
} }], [{ key: "isReadOnlySupported", get: function() {
|
|
35222
35222
|
return !0;
|
|
@@ -35315,22 +35315,22 @@ var CI = { exports: {} };
|
|
|
35315
35315
|
var Y = T[C], G = c[Y.id];
|
|
35316
35316
|
if (G) {
|
|
35317
35317
|
G.refs++;
|
|
35318
|
-
for (var
|
|
35319
|
-
G.parts[
|
|
35320
|
-
for (;
|
|
35321
|
-
G.parts.push(h(Y.parts[
|
|
35318
|
+
for (var W = 0; W < G.parts.length; W++)
|
|
35319
|
+
G.parts[W](Y.parts[W]);
|
|
35320
|
+
for (; W < Y.parts.length; W++)
|
|
35321
|
+
G.parts.push(h(Y.parts[W], w));
|
|
35322
35322
|
} else {
|
|
35323
35323
|
var U = [];
|
|
35324
|
-
for (
|
|
35325
|
-
U.push(h(Y.parts[
|
|
35324
|
+
for (W = 0; W < Y.parts.length; W++)
|
|
35325
|
+
U.push(h(Y.parts[W], w));
|
|
35326
35326
|
c[Y.id] = { id: Y.id, refs: 1, parts: U };
|
|
35327
35327
|
}
|
|
35328
35328
|
}
|
|
35329
35329
|
}
|
|
35330
35330
|
function v(T, w) {
|
|
35331
35331
|
for (var C = [], Y = {}, G = 0; G < T.length; G++) {
|
|
35332
|
-
var
|
|
35333
|
-
Y[U] ? Y[U].parts.push(
|
|
35332
|
+
var W = T[G], U = w.base ? W[0] + w.base : W[0], V = { css: W[1], media: W[2], sourceMap: W[3] };
|
|
35333
|
+
Y[U] ? Y[U].parts.push(V) : C.push(Y[U] = { id: U, parts: [V] });
|
|
35334
35334
|
}
|
|
35335
35335
|
return C;
|
|
35336
35336
|
}
|
|
@@ -35372,30 +35372,30 @@ var CI = { exports: {} };
|
|
|
35372
35372
|
});
|
|
35373
35373
|
}
|
|
35374
35374
|
function h(T, w) {
|
|
35375
|
-
var C, Y, G,
|
|
35375
|
+
var C, Y, G, W;
|
|
35376
35376
|
if (w.transform && T.css) {
|
|
35377
|
-
if (!(
|
|
35377
|
+
if (!(W = w.transform(T.css)))
|
|
35378
35378
|
return function() {
|
|
35379
35379
|
};
|
|
35380
|
-
T.css =
|
|
35380
|
+
T.css = W;
|
|
35381
35381
|
}
|
|
35382
35382
|
if (w.singleton) {
|
|
35383
35383
|
var U = y++;
|
|
35384
35384
|
C = D || (D = b(w)), Y = f.bind(null, C, U, !1), G = f.bind(null, C, U, !0);
|
|
35385
35385
|
} else
|
|
35386
|
-
T.sourceMap && typeof URL == "function" && typeof URL.createObjectURL == "function" && typeof URL.revokeObjectURL == "function" && typeof Blob == "function" && typeof btoa == "function" ? (C = function(
|
|
35386
|
+
T.sourceMap && typeof URL == "function" && typeof URL.createObjectURL == "function" && typeof URL.revokeObjectURL == "function" && typeof Blob == "function" && typeof btoa == "function" ? (C = function(V) {
|
|
35387
35387
|
var P = document.createElement("link");
|
|
35388
|
-
return
|
|
35388
|
+
return V.attrs.type === void 0 && (V.attrs.type = "text/css"), V.attrs.rel = "stylesheet", I(P, V.attrs), m(V, P), P;
|
|
35389
35389
|
}(w), Y = E.bind(null, C, w), G = function() {
|
|
35390
35390
|
A(C), C.href && URL.revokeObjectURL(C.href);
|
|
35391
35391
|
}) : (C = b(w), Y = L.bind(null, C), G = function() {
|
|
35392
35392
|
A(C);
|
|
35393
35393
|
});
|
|
35394
|
-
return Y(T), function(
|
|
35395
|
-
if (
|
|
35396
|
-
if (
|
|
35394
|
+
return Y(T), function(V) {
|
|
35395
|
+
if (V) {
|
|
35396
|
+
if (V.css === T.css && V.media === T.media && V.sourceMap === T.sourceMap)
|
|
35397
35397
|
return;
|
|
35398
|
-
Y(T =
|
|
35398
|
+
Y(T = V);
|
|
35399
35399
|
} else
|
|
35400
35400
|
G();
|
|
35401
35401
|
};
|
|
@@ -35406,16 +35406,16 @@ var CI = { exports: {} };
|
|
|
35406
35406
|
(w = w || {}).attrs = typeof w.attrs == "object" ? w.attrs : {}, w.singleton || typeof w.singleton == "boolean" || (w.singleton = g()), w.insertInto || (w.insertInto = "head"), w.insertAt || (w.insertAt = "bottom");
|
|
35407
35407
|
var C = v(T, w);
|
|
35408
35408
|
return x(C, w), function(Y) {
|
|
35409
|
-
for (var G = [],
|
|
35410
|
-
var U = C[
|
|
35411
|
-
(
|
|
35409
|
+
for (var G = [], W = 0; W < C.length; W++) {
|
|
35410
|
+
var U = C[W];
|
|
35411
|
+
(V = c[U.id]).refs--, G.push(V);
|
|
35412
35412
|
}
|
|
35413
|
-
for (Y && x(v(Y, w), w),
|
|
35414
|
-
var
|
|
35415
|
-
if ((
|
|
35416
|
-
for (var P = 0; P <
|
|
35417
|
-
|
|
35418
|
-
delete c[
|
|
35413
|
+
for (Y && x(v(Y, w), w), W = 0; W < G.length; W++) {
|
|
35414
|
+
var V;
|
|
35415
|
+
if ((V = G[W]).refs === 0) {
|
|
35416
|
+
for (var P = 0; P < V.parts.length; P++)
|
|
35417
|
+
V.parts[P]();
|
|
35418
|
+
delete c[V.id];
|
|
35419
35419
|
}
|
|
35420
35420
|
}
|
|
35421
35421
|
};
|
|
@@ -35429,8 +35429,8 @@ var CI = { exports: {} };
|
|
|
35429
35429
|
if (T.styleSheet)
|
|
35430
35430
|
T.styleSheet.cssText = z(w, G);
|
|
35431
35431
|
else {
|
|
35432
|
-
var
|
|
35433
|
-
U[w] && T.removeChild(U[w]), U.length ? T.insertBefore(
|
|
35432
|
+
var W = document.createTextNode(G), U = T.childNodes;
|
|
35433
|
+
U[w] && T.removeChild(U[w]), U.length ? T.insertBefore(W, U[w]) : T.appendChild(W);
|
|
35434
35434
|
}
|
|
35435
35435
|
}
|
|
35436
35436
|
function L(T, w) {
|
|
@@ -35444,11 +35444,11 @@ var CI = { exports: {} };
|
|
|
35444
35444
|
}
|
|
35445
35445
|
}
|
|
35446
35446
|
function E(T, w, C) {
|
|
35447
|
-
var Y = C.css, G = C.sourceMap,
|
|
35448
|
-
(w.convertToAbsoluteUrls ||
|
|
35447
|
+
var Y = C.css, G = C.sourceMap, W = w.convertToAbsoluteUrls === void 0 && G;
|
|
35448
|
+
(w.convertToAbsoluteUrls || W) && (Y = p(Y)), G && (Y += `
|
|
35449
35449
|
/*# sourceMappingURL=data:application/json;base64,` + btoa(unescape(encodeURIComponent(JSON.stringify(G)))) + " */");
|
|
35450
|
-
var U = new Blob([Y], { type: "text/css" }),
|
|
35451
|
-
T.href = URL.createObjectURL(U),
|
|
35450
|
+
var U = new Blob([Y], { type: "text/css" }), V = T.href;
|
|
35451
|
+
T.href = URL.createObjectURL(U), V && URL.revokeObjectURL(V);
|
|
35452
35452
|
}
|
|
35453
35453
|
}, 947: (a) => {
|
|
35454
35454
|
a.exports = function(s) {
|
|
@@ -36341,7 +36341,7 @@ const ck = {
|
|
|
36341
36341
|
required: !1
|
|
36342
36342
|
}
|
|
36343
36343
|
},
|
|
36344
|
-
emits: ["change", "blockMoved"],
|
|
36344
|
+
emits: ["change", "blockMoved", "blockRemoved"],
|
|
36345
36345
|
setup(i, { expose: e, emit: t }) {
|
|
36346
36346
|
const n = i, o = K(!1), r = K(0), a = K(!1), s = K({}), M = K(n.isSuggestionReplyEnabled), u = K(n.isSuggestionReplyEnabled), l = K(!0), c = K({
|
|
36347
36347
|
holder: n.holder,
|
|
@@ -36355,26 +36355,30 @@ const ck = {
|
|
|
36355
36355
|
o.value = !0;
|
|
36356
36356
|
},
|
|
36357
36357
|
onChange: async (b, I) => {
|
|
36358
|
-
|
|
36358
|
+
var U;
|
|
36359
|
+
const h = Array.isArray(I) ? I : I ? [I] : [];
|
|
36360
|
+
if (I.type === "block-moved" && t("blockMoved", I.detail), (U = h == null ? void 0 : h.filter((V) => V.type === "block-removed")) == null || U.map((V) => {
|
|
36361
|
+
t("blockRemoved", V.detail);
|
|
36362
|
+
}), I.type !== "block-changed" || !n.wordCount) {
|
|
36359
36363
|
const V = await b.saver.save();
|
|
36360
36364
|
t("change", V.blocks);
|
|
36361
36365
|
return;
|
|
36362
36366
|
}
|
|
36363
|
-
function
|
|
36367
|
+
function O(V) {
|
|
36364
36368
|
return "text" in V.data;
|
|
36365
36369
|
}
|
|
36366
|
-
function
|
|
36367
|
-
return V.filter(
|
|
36370
|
+
function z(V) {
|
|
36371
|
+
return V.filter(O).reduce((P, $) => (P += $.data.text.length, P), 0);
|
|
36368
36372
|
}
|
|
36369
|
-
const
|
|
36370
|
-
if (r.value =
|
|
36373
|
+
const f = 300, L = await b.saver.save(), E = z(L.blocks);
|
|
36374
|
+
if (r.value = E, E <= f)
|
|
36371
36375
|
return;
|
|
36372
|
-
const
|
|
36373
|
-
(V) => V.id !==
|
|
36374
|
-
),
|
|
36375
|
-
b.blocks.update(
|
|
36376
|
-
text:
|
|
36377
|
-
}), b.caret.setToBlock(
|
|
36376
|
+
const T = I.detail.target, w = I.detail.index, C = L.blocks.filter((V) => V.id === T.id).pop(), Y = L.blocks.filter(
|
|
36377
|
+
(V) => V.id !== T.id
|
|
36378
|
+
), G = z(Y), W = f - G;
|
|
36379
|
+
b.blocks.update(T.id, {
|
|
36380
|
+
text: C.data.text.substr(0, W)
|
|
36381
|
+
}), b.caret.setToBlock(w, "end");
|
|
36378
36382
|
}
|
|
36379
36383
|
}), g = q(() => r.value > 300);
|
|
36380
36384
|
e({
|
|
@@ -37286,7 +37290,7 @@ function t3(i, e, t, n) {
|
|
|
37286
37290
|
aspectRatio: j,
|
|
37287
37291
|
width: z,
|
|
37288
37292
|
height: L
|
|
37289
|
-
}, "cover"), Y = Math.min(w.width, Math.max(C.width, N)), G = Math.min(w.height, Math.max(C.height, D)),
|
|
37293
|
+
}, "cover"), Y = Math.min(w.width, Math.max(C.width, N)), G = Math.min(w.height, Math.max(C.height, D)), W = on({
|
|
37290
37294
|
aspectRatio: o,
|
|
37291
37295
|
width: b,
|
|
37292
37296
|
height: h
|
|
@@ -37294,8 +37298,8 @@ function t3(i, e, t, n) {
|
|
|
37294
37298
|
aspectRatio: o,
|
|
37295
37299
|
width: z,
|
|
37296
37300
|
height: L
|
|
37297
|
-
}, "cover"),
|
|
37298
|
-
return E.width = to(Y), E.height = to(G), T.fillStyle = d, T.fillRect(0, 0, Y, G), T.save(), T.translate(Y / 2, G / 2), T.rotate(M * Math.PI / 180), T.scale(l, g), T.imageSmoothingEnabled = x, T.imageSmoothingQuality = m, T.drawImage.apply(T, [i].concat(UI(
|
|
37301
|
+
}, "cover"), V = Math.min(W.width, Math.max(U.width, r)), P = Math.min(W.height, Math.max(U.height, a)), $ = [-V / 2, -P / 2, V, P];
|
|
37302
|
+
return E.width = to(Y), E.height = to(G), T.fillStyle = d, T.fillRect(0, 0, Y, G), T.save(), T.translate(Y / 2, G / 2), T.rotate(M * Math.PI / 180), T.scale(l, g), T.imageSmoothingEnabled = x, T.imageSmoothingQuality = m, T.drawImage.apply(T, [i].concat(UI($.map(function(ie) {
|
|
37299
37303
|
return Math.floor(to(ie));
|
|
37300
37304
|
})))), T.restore(), E;
|
|
37301
37305
|
}
|