mainstack-design-system 0.7.43 → 0.7.45
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/build/index.d.ts +8 -2
- package/build/mainstack-design-system.js +581 -577
- package/package.json +1 -1
|
@@ -7894,15 +7894,15 @@ function c5(e, o) {
|
|
|
7894
7894
|
}
|
|
7895
7895
|
var J6 = ["defaultInputValue", "defaultMenuIsOpen", "defaultValue", "inputValue", "menuIsOpen", "onChange", "onInputChange", "onMenuClose", "onMenuOpen", "value"];
|
|
7896
7896
|
function ce(e) {
|
|
7897
|
-
var o = e.defaultInputValue, i = o === void 0 ? "" : o, r = e.defaultMenuIsOpen, n = r === void 0 ? !1 : r, d = e.defaultValue, p = d === void 0 ? null : d, b = e.inputValue, s = e.menuIsOpen, v = e.onChange, h = e.onInputChange, u = e.onMenuClose, a = e.onMenuOpen, l = e.value, y = c5(e, J6), m = E1(b !== void 0 ? b : i), c = J1(m, 2), f = c[0], g = c[1], x = E1(s !== void 0 ? s : n), C = J1(x, 2), w = C[0],
|
|
7897
|
+
var o = e.defaultInputValue, i = o === void 0 ? "" : o, r = e.defaultMenuIsOpen, n = r === void 0 ? !1 : r, d = e.defaultValue, p = d === void 0 ? null : d, b = e.inputValue, s = e.menuIsOpen, v = e.onChange, h = e.onInputChange, u = e.onMenuClose, a = e.onMenuOpen, l = e.value, y = c5(e, J6), m = E1(b !== void 0 ? b : i), c = J1(m, 2), f = c[0], g = c[1], x = E1(s !== void 0 ? s : n), C = J1(x, 2), w = C[0], _ = C[1], L = E1(l !== void 0 ? l : p), I = J1(L, 2), Z = I[0], V = I[1], H = X1(function(Q, X) {
|
|
7898
7898
|
typeof v == "function" && v(Q, X), V(Q);
|
|
7899
7899
|
}, [v]), k = X1(function(Q, X) {
|
|
7900
7900
|
var P;
|
|
7901
7901
|
typeof h == "function" && (P = h(Q, X)), g(P !== void 0 ? P : Q);
|
|
7902
7902
|
}, [h]), S = X1(function() {
|
|
7903
|
-
typeof a == "function" && a(),
|
|
7903
|
+
typeof a == "function" && a(), _(!0);
|
|
7904
7904
|
}, [a]), E = X1(function() {
|
|
7905
|
-
typeof u == "function" && u(),
|
|
7905
|
+
typeof u == "function" && u(), _(!1);
|
|
7906
7906
|
}, [u]), F = b !== void 0 ? b : f, D = s !== void 0 ? s : w, z = l !== void 0 ? l : Z;
|
|
7907
7907
|
return v1(v1({}, y), {}, {
|
|
7908
7908
|
inputValue: F,
|
|
@@ -8201,8 +8201,8 @@ function mt(e, o) {
|
|
|
8201
8201
|
threshold: at(0, it(1, s)) || 1
|
|
8202
8202
|
};
|
|
8203
8203
|
let C = !0;
|
|
8204
|
-
function w(
|
|
8205
|
-
const L =
|
|
8204
|
+
function w(_) {
|
|
8205
|
+
const L = _[0].intersectionRatio;
|
|
8206
8206
|
if (L !== s) {
|
|
8207
8207
|
if (!C)
|
|
8208
8208
|
return p();
|
|
@@ -8401,7 +8401,7 @@ function Ot(e) {
|
|
|
8401
8401
|
};
|
|
8402
8402
|
if (!i || !i.offsetParent)
|
|
8403
8403
|
return v;
|
|
8404
|
-
var h = s.getBoundingClientRect(), u = h.height, a = i.getBoundingClientRect(), l = a.bottom, y = a.height, m = a.top, c = i.offsetParent.getBoundingClientRect(), f = c.top, g = p ? window.innerHeight : It(s), x = l9(s), C = parseInt(getComputedStyle(i).marginBottom, 10), w = parseInt(getComputedStyle(i).marginTop, 10),
|
|
8404
|
+
var h = s.getBoundingClientRect(), u = h.height, a = i.getBoundingClientRect(), l = a.bottom, y = a.height, m = a.top, c = i.offsetParent.getBoundingClientRect(), f = c.top, g = p ? window.innerHeight : It(s), x = l9(s), C = parseInt(getComputedStyle(i).marginBottom, 10), w = parseInt(getComputedStyle(i).marginTop, 10), _ = f - w, L = g - m, I = _ + x, Z = u - x - m, V = l - g + x + C, H = x + m - w, k = 160;
|
|
8405
8405
|
switch (n) {
|
|
8406
8406
|
case "auto":
|
|
8407
8407
|
case "bottom":
|
|
@@ -8424,7 +8424,7 @@ function Ot(e) {
|
|
|
8424
8424
|
};
|
|
8425
8425
|
}
|
|
8426
8426
|
if (n === "auto" || p) {
|
|
8427
|
-
var E = o, F = p ?
|
|
8427
|
+
var E = o, F = p ? _ : I;
|
|
8428
8428
|
return F >= r && (E = Math.min(F - C - b, o)), {
|
|
8429
8429
|
placement: "top",
|
|
8430
8430
|
maxHeight: E
|
|
@@ -8437,7 +8437,7 @@ function Ot(e) {
|
|
|
8437
8437
|
};
|
|
8438
8438
|
break;
|
|
8439
8439
|
case "top":
|
|
8440
|
-
if (
|
|
8440
|
+
if (_ >= y)
|
|
8441
8441
|
return {
|
|
8442
8442
|
placement: "top",
|
|
8443
8443
|
maxHeight: o
|
|
@@ -8447,9 +8447,9 @@ function Ot(e) {
|
|
|
8447
8447
|
placement: "top",
|
|
8448
8448
|
maxHeight: o
|
|
8449
8449
|
};
|
|
8450
|
-
if (!p && I >= r || p &&
|
|
8450
|
+
if (!p && I >= r || p && _ >= r) {
|
|
8451
8451
|
var D = o;
|
|
8452
|
-
return (!p && I >= r || p &&
|
|
8452
|
+
return (!p && I >= r || p && _ >= r) && (D = p ? _ - w : I - w), d && V2(s, H, k), {
|
|
8453
8453
|
placement: "top",
|
|
8454
8454
|
maxHeight: D
|
|
8455
8455
|
};
|
|
@@ -8488,13 +8488,13 @@ var u9 = function(o) {
|
|
|
8488
8488
|
return z3(function() {
|
|
8489
8489
|
var w = u.current;
|
|
8490
8490
|
if (w) {
|
|
8491
|
-
var
|
|
8491
|
+
var _ = p === "fixed", L = b && !_, I = Ot({
|
|
8492
8492
|
maxHeight: n,
|
|
8493
8493
|
menuEl: w,
|
|
8494
8494
|
minHeight: r,
|
|
8495
8495
|
placement: d,
|
|
8496
8496
|
shouldScroll: L,
|
|
8497
|
-
isFixedPosition:
|
|
8497
|
+
isFixedPosition: _,
|
|
8498
8498
|
controlHeight: C
|
|
8499
8499
|
});
|
|
8500
8500
|
m(I.maxHeight), x(I.placement), h == null || h(I.placement);
|
|
@@ -8598,7 +8598,7 @@ var u9 = function(o) {
|
|
|
8598
8598
|
}, [C]);
|
|
8599
8599
|
if (!i && b !== "fixed" || !f)
|
|
8600
8600
|
return null;
|
|
8601
|
-
var
|
|
8601
|
+
var _ = x1("div", I1({
|
|
8602
8602
|
ref: w
|
|
8603
8603
|
}, G1(v1(v1({}, o), {}, {
|
|
8604
8604
|
offset: f.offset,
|
|
@@ -8609,7 +8609,7 @@ var u9 = function(o) {
|
|
|
8609
8609
|
}), d), r);
|
|
8610
8610
|
return x1(c9.Provider, {
|
|
8611
8611
|
value: y
|
|
8612
|
-
}, i ? /* @__PURE__ */ L6(
|
|
8612
|
+
}, i ? /* @__PURE__ */ L6(_, i) : _);
|
|
8613
8613
|
}, Ut = function(o) {
|
|
8614
8614
|
var i = o.isDisabled, r = o.isRtl;
|
|
8615
8615
|
return {
|
|
@@ -9176,19 +9176,19 @@ var $0 = process.env.NODE_ENV === "production" ? {
|
|
|
9176
9176
|
return "".concat(r).concat(i ? " for search term " + i : "", ".");
|
|
9177
9177
|
}
|
|
9178
9178
|
}, e8 = function(o) {
|
|
9179
|
-
var i = o.ariaSelection, r = o.focusedOption, n = o.focusedValue, d = o.focusableOptions, p = o.isFocused, b = o.selectValue, s = o.selectProps, v = o.id, h = o.isAppleDevice, u = s.ariaLiveMessages, a = s.getOptionLabel, l = s.inputValue, y = s.isMulti, m = s.isOptionDisabled, c = s.isSearchable, f = s.menuIsOpen, g = s.options, x = s.screenReaderStatus, C = s.tabSelectsValue, w = s.isLoading,
|
|
9179
|
+
var i = o.ariaSelection, r = o.focusedOption, n = o.focusedValue, d = o.focusableOptions, p = o.isFocused, b = o.selectValue, s = o.selectProps, v = o.id, h = o.isAppleDevice, u = s.ariaLiveMessages, a = s.getOptionLabel, l = s.inputValue, y = s.isMulti, m = s.isOptionDisabled, c = s.isSearchable, f = s.menuIsOpen, g = s.options, x = s.screenReaderStatus, C = s.tabSelectsValue, w = s.isLoading, _ = s["aria-label"], L = s["aria-live"], I = f5(function() {
|
|
9180
9180
|
return v1(v1({}, Q0), u || {});
|
|
9181
9181
|
}, [u]), Z = f5(function() {
|
|
9182
9182
|
var F = "";
|
|
9183
9183
|
if (i && I.onChange) {
|
|
9184
9184
|
var D = i.option, z = i.options, Q = i.removedValue, X = i.removedValues, P = i.value, M = function(Y) {
|
|
9185
9185
|
return Array.isArray(Y) ? null : Y;
|
|
9186
|
-
}, B = Q || D || M(P), R = B ? a(B) : "", j = z || X || void 0,
|
|
9186
|
+
}, B = Q || D || M(P), R = B ? a(B) : "", j = z || X || void 0, A = j ? j.map(a) : [], N = v1({
|
|
9187
9187
|
// multiSelected items are usually items that have already been selected
|
|
9188
9188
|
// or set by the user as a default value so we assume they are not disabled
|
|
9189
9189
|
isDisabled: B && m(B, b),
|
|
9190
9190
|
label: R,
|
|
9191
|
-
labels:
|
|
9191
|
+
labels: A
|
|
9192
9192
|
}, i);
|
|
9193
9193
|
F = I.onChange(N);
|
|
9194
9194
|
}
|
|
@@ -9226,7 +9226,7 @@ var $0 = process.env.NODE_ENV === "production" ? {
|
|
|
9226
9226
|
if (I.guidance) {
|
|
9227
9227
|
var D = n ? "value" : f ? "menu" : "input";
|
|
9228
9228
|
F = I.guidance({
|
|
9229
|
-
"aria-label":
|
|
9229
|
+
"aria-label": _,
|
|
9230
9230
|
context: D,
|
|
9231
9231
|
isDisabled: r && m(r, b),
|
|
9232
9232
|
isMulti: y,
|
|
@@ -9236,7 +9236,7 @@ var $0 = process.env.NODE_ENV === "production" ? {
|
|
|
9236
9236
|
});
|
|
9237
9237
|
}
|
|
9238
9238
|
return F;
|
|
9239
|
-
}, [
|
|
9239
|
+
}, [_, r, n, y, m, c, f, I, b, C, k]), E = x1(B3, null, x1("span", {
|
|
9240
9240
|
id: "aria-selection"
|
|
9241
9241
|
}, Z), x1("span", {
|
|
9242
9242
|
id: "aria-focused"
|
|
@@ -9567,8 +9567,8 @@ var s8 = function(o) {
|
|
|
9567
9567
|
function u8(e) {
|
|
9568
9568
|
var o = e.isEnabled, i = e.onBottomArrive, r = e.onBottomLeave, n = e.onTopArrive, d = e.onTopLeave, p = P1(!1), b = P1(!1), s = P1(0), v = P1(null), h = X1(function(c, f) {
|
|
9569
9569
|
if (v.current !== null) {
|
|
9570
|
-
var g = v.current, x = g.scrollTop, C = g.scrollHeight, w = g.clientHeight,
|
|
9571
|
-
I > f && p.current && (r && r(c), p.current = !1), L && b.current && (d && d(c), b.current = !1), L && f > I ? (i && !p.current && i(c),
|
|
9570
|
+
var g = v.current, x = g.scrollTop, C = g.scrollHeight, w = g.clientHeight, _ = v.current, L = f > 0, I = C - w - x, Z = !1;
|
|
9571
|
+
I > f && p.current && (r && r(c), p.current = !1), L && b.current && (d && d(c), b.current = !1), L && f > I ? (i && !p.current && i(c), _.scrollTop = C, Z = !0, p.current = !0) : !L && -f > x && (n && !b.current && n(c), _.scrollTop = 0, Z = !0, b.current = !0), Z && s8(c);
|
|
9572
9572
|
}
|
|
9573
9573
|
}, [i, r, n, d]), u = X1(function(c) {
|
|
9574
9574
|
h(c, c.deltaY);
|
|
@@ -10150,7 +10150,7 @@ var M9 = function(o) {
|
|
|
10150
10150
|
}, n.onValueInputFocus = function(s) {
|
|
10151
10151
|
s.preventDefault(), s.stopPropagation(), n.focus();
|
|
10152
10152
|
}, n.onKeyDown = function(s) {
|
|
10153
|
-
var v = n.props, h = v.isMulti, u = v.backspaceRemovesValue, a = v.escapeClearsValue, l = v.inputValue, y = v.isClearable, m = v.isDisabled, c = v.menuIsOpen, f = v.onKeyDown, g = v.tabSelectsValue, x = v.openMenuOnFocus, C = n.state, w = C.focusedOption,
|
|
10153
|
+
var v = n.props, h = v.isMulti, u = v.backspaceRemovesValue, a = v.escapeClearsValue, l = v.inputValue, y = v.isClearable, m = v.isDisabled, c = v.menuIsOpen, f = v.onKeyDown, g = v.tabSelectsValue, x = v.openMenuOnFocus, C = n.state, w = C.focusedOption, _ = C.focusedValue, L = C.selectValue;
|
|
10154
10154
|
if (!m && !(typeof f == "function" && (f(s), s.defaultPrevented))) {
|
|
10155
10155
|
switch (n.blockOptionHover = !0, s.key) {
|
|
10156
10156
|
case "ArrowLeft":
|
|
@@ -10167,8 +10167,8 @@ var M9 = function(o) {
|
|
|
10167
10167
|
case "Backspace":
|
|
10168
10168
|
if (l)
|
|
10169
10169
|
return;
|
|
10170
|
-
if (
|
|
10171
|
-
n.removeValue(
|
|
10170
|
+
if (_)
|
|
10171
|
+
n.removeValue(_);
|
|
10172
10172
|
else {
|
|
10173
10173
|
if (!u)
|
|
10174
10174
|
return;
|
|
@@ -10537,12 +10537,12 @@ var M9 = function(o) {
|
|
|
10537
10537
|
}, {
|
|
10538
10538
|
key: "renderPlaceholderOrValue",
|
|
10539
10539
|
value: function() {
|
|
10540
|
-
var n = this, d = this.getComponents(), p = d.MultiValue, b = d.MultiValueContainer, s = d.MultiValueLabel, v = d.MultiValueRemove, h = d.SingleValue, u = d.Placeholder, a = this.commonProps, l = this.props, y = l.controlShouldRenderValue, m = l.isDisabled, c = l.isMulti, f = l.inputValue, g = l.placeholder, x = this.state, C = x.selectValue, w = x.focusedValue,
|
|
10540
|
+
var n = this, d = this.getComponents(), p = d.MultiValue, b = d.MultiValueContainer, s = d.MultiValueLabel, v = d.MultiValueRemove, h = d.SingleValue, u = d.Placeholder, a = this.commonProps, l = this.props, y = l.controlShouldRenderValue, m = l.isDisabled, c = l.isMulti, f = l.inputValue, g = l.placeholder, x = this.state, C = x.selectValue, w = x.focusedValue, _ = x.isFocused;
|
|
10541
10541
|
if (!this.hasValue() || !y)
|
|
10542
10542
|
return f ? null : /* @__PURE__ */ M1.createElement(u, I1({}, a, {
|
|
10543
10543
|
key: "placeholder",
|
|
10544
10544
|
isDisabled: m,
|
|
10545
|
-
isFocused:
|
|
10545
|
+
isFocused: _,
|
|
10546
10546
|
innerProps: {
|
|
10547
10547
|
id: this.getElementId("placeholder")
|
|
10548
10548
|
}
|
|
@@ -10645,11 +10645,11 @@ var M9 = function(o) {
|
|
|
10645
10645
|
}, {
|
|
10646
10646
|
key: "renderMenu",
|
|
10647
10647
|
value: function() {
|
|
10648
|
-
var n = this, d = this.getComponents(), p = d.Group, b = d.GroupHeading, s = d.Menu, v = d.MenuList, h = d.MenuPortal, u = d.LoadingMessage, a = d.NoOptionsMessage, l = d.Option, y = this.commonProps, m = this.state.focusedOption, c = this.props, f = c.captureMenuScroll, g = c.inputValue, x = c.isLoading, C = c.loadingMessage, w = c.minMenuHeight,
|
|
10648
|
+
var n = this, d = this.getComponents(), p = d.Group, b = d.GroupHeading, s = d.Menu, v = d.MenuList, h = d.MenuPortal, u = d.LoadingMessage, a = d.NoOptionsMessage, l = d.Option, y = this.commonProps, m = this.state.focusedOption, c = this.props, f = c.captureMenuScroll, g = c.inputValue, x = c.isLoading, C = c.loadingMessage, w = c.minMenuHeight, _ = c.maxMenuHeight, L = c.menuIsOpen, I = c.menuPlacement, Z = c.menuPosition, V = c.menuPortalTarget, H = c.menuShouldBlockScroll, k = c.menuShouldScrollIntoView, S = c.noOptionsMessage, E = c.onMenuScrollToTop, F = c.onMenuScrollToBottom;
|
|
10649
10649
|
if (!L)
|
|
10650
10650
|
return null;
|
|
10651
10651
|
var D = function(R, j) {
|
|
10652
|
-
var
|
|
10652
|
+
var A = R.type, N = R.data, W = R.isDisabled, Y = R.isSelected, J = R.label, e1 = R.value, s1 = m === N, f1 = W ? void 0 : function() {
|
|
10653
10653
|
return n.onOptionHover(N);
|
|
10654
10654
|
}, p1 = W ? void 0 : function() {
|
|
10655
10655
|
return n.selectOption(N);
|
|
@@ -10670,7 +10670,7 @@ var M9 = function(o) {
|
|
|
10670
10670
|
isSelected: Y,
|
|
10671
10671
|
key: m1,
|
|
10672
10672
|
label: J,
|
|
10673
|
-
type:
|
|
10673
|
+
type: A,
|
|
10674
10674
|
value: e1,
|
|
10675
10675
|
isFocused: s1,
|
|
10676
10676
|
innerRef: s1 ? n.getFocusedOptionRef : void 0
|
|
@@ -10679,7 +10679,7 @@ var M9 = function(o) {
|
|
|
10679
10679
|
if (this.hasOptions())
|
|
10680
10680
|
z = this.getCategorizedOptions().map(function(B) {
|
|
10681
10681
|
if (B.type === "group") {
|
|
10682
|
-
var R = B.data, j = B.options,
|
|
10682
|
+
var R = B.data, j = B.options, A = B.index, N = "".concat(n.getElementId("group"), "-").concat(A), W = "".concat(N, "-heading");
|
|
10683
10683
|
return /* @__PURE__ */ M1.createElement(p, I1({}, y, {
|
|
10684
10684
|
key: N,
|
|
10685
10685
|
data: R,
|
|
@@ -10691,7 +10691,7 @@ var M9 = function(o) {
|
|
|
10691
10691
|
},
|
|
10692
10692
|
label: n.formatGroupLabel(B.data)
|
|
10693
10693
|
}), B.options.map(function(Y) {
|
|
10694
|
-
return D(Y, "".concat(
|
|
10694
|
+
return D(Y, "".concat(A, "-").concat(Y.index));
|
|
10695
10695
|
}));
|
|
10696
10696
|
} else if (B.type === "option")
|
|
10697
10697
|
return D(B, "".concat(B.index));
|
|
@@ -10713,12 +10713,12 @@ var M9 = function(o) {
|
|
|
10713
10713
|
}
|
|
10714
10714
|
var P = {
|
|
10715
10715
|
minMenuHeight: w,
|
|
10716
|
-
maxMenuHeight:
|
|
10716
|
+
maxMenuHeight: _,
|
|
10717
10717
|
menuPlacement: I,
|
|
10718
10718
|
menuPosition: Z,
|
|
10719
10719
|
menuShouldScrollIntoView: k
|
|
10720
10720
|
}, M = /* @__PURE__ */ M1.createElement(Nt, I1({}, y, P), function(B) {
|
|
10721
|
-
var R = B.ref, j = B.placerProps,
|
|
10721
|
+
var R = B.ref, j = B.placerProps, A = j.placement, N = j.maxHeight;
|
|
10722
10722
|
return /* @__PURE__ */ M1.createElement(s, I1({}, y, P, {
|
|
10723
10723
|
innerRef: R,
|
|
10724
10724
|
innerProps: {
|
|
@@ -10726,7 +10726,7 @@ var M9 = function(o) {
|
|
|
10726
10726
|
onMouseMove: n.onMenuMouseMove
|
|
10727
10727
|
},
|
|
10728
10728
|
isLoading: x,
|
|
10729
|
-
placement:
|
|
10729
|
+
placement: A
|
|
10730
10730
|
}), /* @__PURE__ */ M1.createElement(h8, {
|
|
10731
10731
|
captureEnabled: f,
|
|
10732
10732
|
onTopArrive: E,
|
|
@@ -10846,13 +10846,13 @@ var M9 = function(o) {
|
|
|
10846
10846
|
value: function(n, d) {
|
|
10847
10847
|
var p = d.prevProps, b = d.clearFocusValueOnUpdate, s = d.inputIsHiddenAfterUpdate, v = d.ariaSelection, h = d.isFocused, u = d.prevWasFocused, a = d.instancePrefix, l = n.options, y = n.value, m = n.menuIsOpen, c = n.inputValue, f = n.isMulti, g = D2(y), x = {};
|
|
10848
10848
|
if (p && (y !== p.value || l !== p.options || m !== p.menuIsOpen || c !== p.inputValue)) {
|
|
10849
|
-
var C = m ? Z8(n, g) : [], w = m ? $e(Z2(n, g), "".concat(a, "-option")) : [],
|
|
10849
|
+
var C = m ? Z8(n, g) : [], w = m ? $e(Z2(n, g), "".concat(a, "-option")) : [], _ = b ? S8(d, g) : null, L = T8(d, C), I = V3(w, L);
|
|
10850
10850
|
x = {
|
|
10851
10851
|
selectValue: g,
|
|
10852
10852
|
focusedOption: L,
|
|
10853
10853
|
focusedOptionId: I,
|
|
10854
10854
|
focusableOptionsWithIds: w,
|
|
10855
|
-
focusedValue:
|
|
10855
|
+
focusedValue: _,
|
|
10856
10856
|
clearFocusValueOnUpdate: !1
|
|
10857
10857
|
};
|
|
10858
10858
|
}
|
|
@@ -10901,7 +10901,7 @@ var B8 = /* @__PURE__ */ c2(function(e, o) {
|
|
|
10901
10901
|
}
|
|
10902
10902
|
};
|
|
10903
10903
|
function P8(e) {
|
|
10904
|
-
var o = e.allowCreateWhileLoading, i = o === void 0 ? !1 : o, r = e.createOptionPosition, n = r === void 0 ? "last" : r, d = e.formatCreateLabel, p = d === void 0 ? L3.formatCreateLabel : d, b = e.isValidNewOption, s = b === void 0 ? L3.isValidNewOption : b, v = e.getNewOptionData, h = v === void 0 ? L3.getNewOptionData : v, u = e.onCreateOption, a = e.options, l = a === void 0 ? [] : a, y = e.onChange, m = c5(e, N8), c = m.getOptionValue, f = c === void 0 ? w9 : c, g = m.getOptionLabel, x = g === void 0 ? b9 : g, C = m.inputValue, w = m.isLoading,
|
|
10904
|
+
var o = e.allowCreateWhileLoading, i = o === void 0 ? !1 : o, r = e.createOptionPosition, n = r === void 0 ? "last" : r, d = e.formatCreateLabel, p = d === void 0 ? L3.formatCreateLabel : d, b = e.isValidNewOption, s = b === void 0 ? L3.isValidNewOption : b, v = e.getNewOptionData, h = v === void 0 ? L3.getNewOptionData : v, u = e.onCreateOption, a = e.options, l = a === void 0 ? [] : a, y = e.onChange, m = c5(e, N8), c = m.getOptionValue, f = c === void 0 ? w9 : c, g = m.getOptionLabel, x = g === void 0 ? b9 : g, C = m.inputValue, w = m.isLoading, _ = m.isMulti, L = m.value, I = m.name, Z = f5(function() {
|
|
10905
10905
|
return s(C, D2(L), l, {
|
|
10906
10906
|
getOptionValue: f,
|
|
10907
10907
|
getOptionLabel: x
|
|
@@ -10921,12 +10921,12 @@ function P8(e) {
|
|
|
10921
10921
|
name: I,
|
|
10922
10922
|
option: F
|
|
10923
10923
|
};
|
|
10924
|
-
y(n2(
|
|
10924
|
+
y(n2(_, [].concat(F5(D2(L)), [F]), F), D);
|
|
10925
10925
|
}
|
|
10926
10926
|
return;
|
|
10927
10927
|
}
|
|
10928
10928
|
y(k, S);
|
|
10929
|
-
}, [h, C,
|
|
10929
|
+
}, [h, C, _, I, Z, u, y, L]);
|
|
10930
10930
|
return v1(v1({}, m), {}, {
|
|
10931
10931
|
options: V,
|
|
10932
10932
|
onChange: H
|
|
@@ -11070,13 +11070,14 @@ const ge = {
|
|
|
11070
11070
|
openMenuOnFocus: f,
|
|
11071
11071
|
isSearchable: g = !0,
|
|
11072
11072
|
formatOptionLabel: x,
|
|
11073
|
-
customComponent: C
|
|
11073
|
+
customComponent: C,
|
|
11074
|
+
formatGroupLabel: w
|
|
11074
11075
|
}) => {
|
|
11075
|
-
const
|
|
11076
|
-
|
|
11077
|
-
const
|
|
11076
|
+
const _ = C ?? {}, L = a, I = l;
|
|
11077
|
+
L && (_.Option = L), I && (_.MultiValue = I);
|
|
11078
|
+
const Z = P1(
|
|
11078
11079
|
null
|
|
11079
|
-
), [
|
|
11080
|
+
), [V, H] = E1(!1);
|
|
11080
11081
|
return /* @__PURE__ */ r1(
|
|
11081
11082
|
L1,
|
|
11082
11083
|
{
|
|
@@ -11084,8 +11085,8 @@ const ge = {
|
|
|
11084
11085
|
fontFamily: c ?? "Degular",
|
|
11085
11086
|
fontWeight: 500,
|
|
11086
11087
|
onClick: () => {
|
|
11087
|
-
var
|
|
11088
|
-
|
|
11088
|
+
var k;
|
|
11089
|
+
V || (k = Z.current) == null || k.focus();
|
|
11089
11090
|
},
|
|
11090
11091
|
children: [
|
|
11091
11092
|
e && /* @__PURE__ */ t(
|
|
@@ -11109,22 +11110,22 @@ const ge = {
|
|
|
11109
11110
|
isClearable: h,
|
|
11110
11111
|
defaultInputValue: s,
|
|
11111
11112
|
value: b,
|
|
11112
|
-
onChange: (
|
|
11113
|
-
var
|
|
11114
|
-
d && (d(
|
|
11113
|
+
onChange: (k) => {
|
|
11114
|
+
var S;
|
|
11115
|
+
d && (d(k), h || (S = Z == null ? void 0 : Z.current) == null || S.blur());
|
|
11115
11116
|
},
|
|
11116
|
-
onInputChange: (
|
|
11117
|
-
p && p(
|
|
11117
|
+
onInputChange: (k) => {
|
|
11118
|
+
p && p(k);
|
|
11118
11119
|
},
|
|
11119
|
-
ref:
|
|
11120
|
-
onBlur: (
|
|
11120
|
+
ref: Z,
|
|
11121
|
+
onBlur: (k) => n && n(k),
|
|
11121
11122
|
components: {
|
|
11122
11123
|
ClearIndicator: _9,
|
|
11123
11124
|
DropdownIndicator: me,
|
|
11124
11125
|
IndicatorSeparator: A9,
|
|
11125
11126
|
MultiValueRemove: E9,
|
|
11126
11127
|
// IndicatorsContainer,
|
|
11127
|
-
...
|
|
11128
|
+
..._
|
|
11128
11129
|
},
|
|
11129
11130
|
id: o,
|
|
11130
11131
|
options: v,
|
|
@@ -11137,13 +11138,14 @@ const ge = {
|
|
|
11137
11138
|
noOptionsMessage: () => m ?? "No options",
|
|
11138
11139
|
openMenuOnFocus: f,
|
|
11139
11140
|
onMenuOpen: () => {
|
|
11140
|
-
|
|
11141
|
+
H(!0);
|
|
11141
11142
|
},
|
|
11142
11143
|
onMenuClose: () => {
|
|
11143
|
-
|
|
11144
|
+
H(!1);
|
|
11144
11145
|
},
|
|
11145
11146
|
formatOptionLabel: x,
|
|
11146
|
-
isSearchable: g
|
|
11147
|
+
isSearchable: g,
|
|
11148
|
+
formatGroupLabel: w
|
|
11147
11149
|
}
|
|
11148
11150
|
)
|
|
11149
11151
|
]
|
|
@@ -11168,7 +11170,9 @@ const ge = {
|
|
|
11168
11170
|
noOptionsMessage: m,
|
|
11169
11171
|
fontFamily: c
|
|
11170
11172
|
}) => {
|
|
11171
|
-
const [f, g] = E1(
|
|
11173
|
+
const [f, g] = E1(
|
|
11174
|
+
v
|
|
11175
|
+
), x = {};
|
|
11172
11176
|
if (h) {
|
|
11173
11177
|
const Z = a, V = l;
|
|
11174
11178
|
Z && (x.Option = Z), V && (x.MultiValue = V);
|
|
@@ -11179,8 +11183,8 @@ const ge = {
|
|
|
11179
11183
|
value: Z.toLowerCase().replace(/\W/g, "")
|
|
11180
11184
|
};
|
|
11181
11185
|
g((H) => [...H, V]), d && d(h ? [...b, V] : V);
|
|
11182
|
-
}, [w,
|
|
11183
|
-
Z.keyCode === 188 && (Z.preventDefault(), C(Z.target.value),
|
|
11186
|
+
}, [w, _] = E1(""), L = (Z) => {
|
|
11187
|
+
Z.keyCode === 188 && (Z.preventDefault(), C(Z.target.value), _(""));
|
|
11184
11188
|
}, I = P1(
|
|
11185
11189
|
null
|
|
11186
11190
|
);
|
|
@@ -11205,11 +11209,11 @@ const ge = {
|
|
|
11205
11209
|
isMulti: h,
|
|
11206
11210
|
isClearable: !0,
|
|
11207
11211
|
onChange: (Z) => {
|
|
11208
|
-
var V
|
|
11209
|
-
d && (
|
|
11212
|
+
var V;
|
|
11213
|
+
d && (d(Z), h || (V = I == null ? void 0 : I.current) == null || V.blur());
|
|
11210
11214
|
},
|
|
11211
11215
|
onInputChange: (Z) => {
|
|
11212
|
-
p && p(Z),
|
|
11216
|
+
p && p(Z), _(Z);
|
|
11213
11217
|
},
|
|
11214
11218
|
ref: I,
|
|
11215
11219
|
onBlur: (Z) => n && n(Z),
|
|
@@ -11251,7 +11255,7 @@ var G8 = ["defaultOptions", "cacheOptions", "loadOptions", "options", "isLoading
|
|
|
11251
11255
|
function j8(e) {
|
|
11252
11256
|
var o = e.defaultOptions, i = o === void 0 ? !1 : o, r = e.cacheOptions, n = r === void 0 ? !1 : r, d = e.loadOptions;
|
|
11253
11257
|
e.options;
|
|
11254
|
-
var p = e.isLoading, b = p === void 0 ? !1 : p, s = e.onInputChange, v = e.filterOption, h = v === void 0 ? null : v, u = c5(e, G8), a = u.inputValue, l = P1(void 0), y = P1(!1), m = E1(Array.isArray(i) ? i : void 0), c = J1(m, 2), f = c[0], g = c[1], x = E1(typeof a < "u" ? a : ""), C = J1(x, 2), w = C[0],
|
|
11258
|
+
var p = e.isLoading, b = p === void 0 ? !1 : p, s = e.onInputChange, v = e.filterOption, h = v === void 0 ? null : v, u = c5(e, G8), a = u.inputValue, l = P1(void 0), y = P1(!1), m = E1(Array.isArray(i) ? i : void 0), c = J1(m, 2), f = c[0], g = c[1], x = E1(typeof a < "u" ? a : ""), C = J1(x, 2), w = C[0], _ = C[1], L = E1(i === !0), I = J1(L, 2), Z = I[0], V = I[1], H = E1(void 0), k = J1(H, 2), S = k[0], E = k[1], F = E1([]), D = J1(F, 2), z = D[0], Q = D[1], X = E1(!1), P = J1(X, 2), M = P[0], B = P[1], R = E1({}), j = J1(R, 2), A = j[0], N = j[1], W = E1(void 0), Y = J1(W, 2), J = Y[0], e1 = Y[1], s1 = E1(void 0), f1 = J1(s1, 2), p1 = f1[0], m1 = f1[1];
|
|
11255
11259
|
n !== p1 && (N({}), m1(n)), i !== J && (g(Array.isArray(i) ? i : void 0), e1(i)), K1(function() {
|
|
11256
11260
|
return y.current = !0, function() {
|
|
11257
11261
|
y.current = !1;
|
|
@@ -11273,18 +11277,18 @@ function j8(e) {
|
|
|
11273
11277
|
var o1 = X1(function(q, $) {
|
|
11274
11278
|
var t1 = xt(q, $, s);
|
|
11275
11279
|
if (!t1) {
|
|
11276
|
-
l.current = void 0,
|
|
11280
|
+
l.current = void 0, _(""), E(""), Q([]), V(!1), B(!1);
|
|
11277
11281
|
return;
|
|
11278
11282
|
}
|
|
11279
|
-
if (n &&
|
|
11280
|
-
|
|
11283
|
+
if (n && A[t1])
|
|
11284
|
+
_(t1), E(t1), Q(A[t1]), V(!1), B(!1);
|
|
11281
11285
|
else {
|
|
11282
11286
|
var i1 = l.current = {};
|
|
11283
|
-
|
|
11284
|
-
y && i1 === l.current && (l.current = void 0, V(!1), E(t1), Q(n1 || []), B(!1), N(n1 ? v1(v1({},
|
|
11287
|
+
_(t1), V(!0), B(!S), U(t1, function(n1) {
|
|
11288
|
+
y && i1 === l.current && (l.current = void 0, V(!1), E(t1), Q(n1 || []), B(!1), N(n1 ? v1(v1({}, A), {}, B5({}, t1, n1)) : A));
|
|
11285
11289
|
});
|
|
11286
11290
|
}
|
|
11287
|
-
}, [n, U, S,
|
|
11291
|
+
}, [n, U, S, A, s]), C1 = M ? [] : w && S ? z : f || [];
|
|
11288
11292
|
return v1(v1({}, u), {}, {
|
|
11289
11293
|
options: C1,
|
|
11290
11294
|
isLoading: Z || b,
|
|
@@ -13242,8 +13246,8 @@ var J8 = function(e) {
|
|
|
13242
13246
|
if (g(w))
|
|
13243
13247
|
return NaN;
|
|
13244
13248
|
if (f(w)) {
|
|
13245
|
-
var
|
|
13246
|
-
w = f(
|
|
13249
|
+
var _ = typeof w.valueOf == "function" ? w.valueOf() : w;
|
|
13250
|
+
w = f(_) ? _ + "" : _;
|
|
13247
13251
|
}
|
|
13248
13252
|
if (typeof w != "string")
|
|
13249
13253
|
return w === 0 ? w : +w;
|
|
@@ -13252,12 +13256,12 @@ var J8 = function(e) {
|
|
|
13252
13256
|
return L || b.test(w) ? s(w.slice(2), L ? 2 : 8) : d.test(w) ? NaN : +w;
|
|
13253
13257
|
}(C)) === 1 / 0 || C === -1 / 0 ? 17976931348623157e292 * (C < 0 ? -1 : 1) : C == C ? C : 0 : C === 0 ? C : 0;
|
|
13254
13258
|
}
|
|
13255
|
-
e.exports = function(C, w,
|
|
13259
|
+
e.exports = function(C, w, _) {
|
|
13256
13260
|
var L, I, Z, V;
|
|
13257
13261
|
return C = (L = C) == null ? "" : c(L), I = function(H) {
|
|
13258
13262
|
var k = x(H), S = k % 1;
|
|
13259
13263
|
return k == k ? S ? k - S : k : 0;
|
|
13260
|
-
}(
|
|
13264
|
+
}(_), Z = 0, V = C.length, I == I && (V !== void 0 && (I = I <= V ? I : V), Z !== void 0 && (I = I >= Z ? I : Z)), _ = I, w = c(w), C.slice(_, _ + w.length) == w;
|
|
13261
13265
|
};
|
|
13262
13266
|
}).call(this, i(3));
|
|
13263
13267
|
}, function(e, o) {
|
|
@@ -13281,7 +13285,7 @@ var J8 = function(e) {
|
|
|
13281
13285
|
this.set(z[0], z[1]);
|
|
13282
13286
|
}
|
|
13283
13287
|
}
|
|
13284
|
-
function
|
|
13288
|
+
function _(E) {
|
|
13285
13289
|
var F = -1, D = E ? E.length : 0;
|
|
13286
13290
|
for (this.clear(); ++F < D; ) {
|
|
13287
13291
|
var z = E[F];
|
|
@@ -13370,21 +13374,21 @@ var J8 = function(e) {
|
|
|
13370
13374
|
return C ? F[E] !== void 0 : m.call(F, E);
|
|
13371
13375
|
}, w.prototype.set = function(E, F) {
|
|
13372
13376
|
return this.__data__[E] = C && F === void 0 ? "__lodash_hash_undefined__" : F, this;
|
|
13373
|
-
},
|
|
13377
|
+
}, _.prototype.clear = function() {
|
|
13374
13378
|
this.__data__ = [];
|
|
13375
|
-
},
|
|
13379
|
+
}, _.prototype.delete = function(E) {
|
|
13376
13380
|
var F = this.__data__, D = I(F, E);
|
|
13377
13381
|
return !(D < 0) && (D == F.length - 1 ? F.pop() : g.call(F, D, 1), !0);
|
|
13378
|
-
},
|
|
13382
|
+
}, _.prototype.get = function(E) {
|
|
13379
13383
|
var F = this.__data__, D = I(F, E);
|
|
13380
13384
|
return D < 0 ? void 0 : F[D][1];
|
|
13381
|
-
},
|
|
13385
|
+
}, _.prototype.has = function(E) {
|
|
13382
13386
|
return I(this.__data__, E) > -1;
|
|
13383
|
-
},
|
|
13387
|
+
}, _.prototype.set = function(E, F) {
|
|
13384
13388
|
var D = this.__data__, z = I(D, E);
|
|
13385
13389
|
return z < 0 ? D.push([E, F]) : D[z][1] = F, this;
|
|
13386
13390
|
}, L.prototype.clear = function() {
|
|
13387
|
-
this.__data__ = { hash: new w(), map: new (x ||
|
|
13391
|
+
this.__data__ = { hash: new w(), map: new (x || _)(), string: new w() };
|
|
13388
13392
|
}, L.prototype.delete = function(E) {
|
|
13389
13393
|
return V(this, E).delete(E);
|
|
13390
13394
|
}, L.prototype.get = function(E) {
|
|
@@ -13408,8 +13412,8 @@ var J8 = function(e) {
|
|
|
13408
13412
|
if (typeof g == "number")
|
|
13409
13413
|
return g;
|
|
13410
13414
|
if (function(w) {
|
|
13411
|
-
return typeof w == "symbol" || function(
|
|
13412
|
-
return !!
|
|
13415
|
+
return typeof w == "symbol" || function(_) {
|
|
13416
|
+
return !!_ && typeof _ == "object";
|
|
13413
13417
|
}(w) && a.call(w) == "[object Symbol]";
|
|
13414
13418
|
}(g))
|
|
13415
13419
|
return NaN;
|
|
@@ -13424,12 +13428,12 @@ var J8 = function(e) {
|
|
|
13424
13428
|
return C || b.test(g) ? s(g.slice(2), C ? 2 : 8) : d.test(g) ? NaN : +g;
|
|
13425
13429
|
}
|
|
13426
13430
|
e.exports = function(g, x, C) {
|
|
13427
|
-
var w,
|
|
13431
|
+
var w, _, L, I, Z, V, H = 0, k = !1, S = !1, E = !0;
|
|
13428
13432
|
if (typeof g != "function")
|
|
13429
13433
|
throw new TypeError("Expected a function");
|
|
13430
13434
|
function F(M) {
|
|
13431
|
-
var B = w, R =
|
|
13432
|
-
return w =
|
|
13435
|
+
var B = w, R = _;
|
|
13436
|
+
return w = _ = void 0, H = M, I = g.apply(R, B);
|
|
13433
13437
|
}
|
|
13434
13438
|
function D(M) {
|
|
13435
13439
|
return H = M, Z = setTimeout(Q, x), k ? F(M) : I;
|
|
@@ -13448,11 +13452,11 @@ var J8 = function(e) {
|
|
|
13448
13452
|
}(M));
|
|
13449
13453
|
}
|
|
13450
13454
|
function X(M) {
|
|
13451
|
-
return Z = void 0, E && w ? F(M) : (w =
|
|
13455
|
+
return Z = void 0, E && w ? F(M) : (w = _ = void 0, I);
|
|
13452
13456
|
}
|
|
13453
13457
|
function P() {
|
|
13454
13458
|
var M = m(), B = z(M);
|
|
13455
|
-
if (w = arguments,
|
|
13459
|
+
if (w = arguments, _ = this, V = M, B) {
|
|
13456
13460
|
if (Z === void 0)
|
|
13457
13461
|
return D(V);
|
|
13458
13462
|
if (S)
|
|
@@ -13461,7 +13465,7 @@ var J8 = function(e) {
|
|
|
13461
13465
|
return Z === void 0 && (Z = setTimeout(Q, x)), I;
|
|
13462
13466
|
}
|
|
13463
13467
|
return x = f(x) || 0, c(C) && (k = !!C.leading, L = (S = "maxWait" in C) ? l(f(C.maxWait) || 0, x) : L, E = "trailing" in C ? !!C.trailing : E), P.cancel = function() {
|
|
13464
|
-
Z !== void 0 && clearTimeout(Z), H = 0, w = V =
|
|
13468
|
+
Z !== void 0 && clearTimeout(Z), H = 0, w = V = _ = Z = void 0;
|
|
13465
13469
|
}, P.flush = function() {
|
|
13466
13470
|
return Z === void 0 ? I : X(m());
|
|
13467
13471
|
}, P;
|
|
@@ -13471,9 +13475,9 @@ var J8 = function(e) {
|
|
|
13471
13475
|
(function(r, n) {
|
|
13472
13476
|
var d = "[object Arguments]", p = "[object Map]", b = "[object Object]", s = "[object Set]", v = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, h = /^\w*$/, u = /^\./, a = /[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g, l = /\\(\\)?/g, y = /^\[object .+?Constructor\]$/, m = /^(?:0|[1-9]\d*)$/, c = {};
|
|
13473
13477
|
c["[object Float32Array]"] = c["[object Float64Array]"] = c["[object Int8Array]"] = c["[object Int16Array]"] = c["[object Int32Array]"] = c["[object Uint8Array]"] = c["[object Uint8ClampedArray]"] = c["[object Uint16Array]"] = c["[object Uint32Array]"] = !0, c[d] = c["[object Array]"] = c["[object ArrayBuffer]"] = c["[object Boolean]"] = c["[object DataView]"] = c["[object Date]"] = c["[object Error]"] = c["[object Function]"] = c[p] = c["[object Number]"] = c[b] = c["[object RegExp]"] = c[s] = c["[object String]"] = c["[object WeakMap]"] = !1;
|
|
13474
|
-
var f = typeof r == "object" && r && r.Object === Object && r, g = typeof self == "object" && self && self.Object === Object && self, x = f || g || Function("return this")(), C = o && !o.nodeType && o, w = C && typeof n == "object" && n && !n.nodeType && n,
|
|
13478
|
+
var f = typeof r == "object" && r && r.Object === Object && r, g = typeof self == "object" && self && self.Object === Object && self, x = f || g || Function("return this")(), C = o && !o.nodeType && o, w = C && typeof n == "object" && n && !n.nodeType && n, _ = w && w.exports === C && f.process, L = function() {
|
|
13475
13479
|
try {
|
|
13476
|
-
return
|
|
13480
|
+
return _ && _.binding("util");
|
|
13477
13481
|
} catch {
|
|
13478
13482
|
}
|
|
13479
13483
|
}(), I = L && L.isTypedArray;
|
|
@@ -13515,7 +13519,7 @@ var J8 = function(e) {
|
|
|
13515
13519
|
a1[++K] = c1;
|
|
13516
13520
|
}), a1;
|
|
13517
13521
|
}
|
|
13518
|
-
var F, D, z, Q = Array.prototype, X = Function.prototype, P = Object.prototype, M = x["__core-js_shared__"], B = (F = /[^.]+$/.exec(M && M.keys && M.keys.IE_PROTO || "")) ? "Symbol(src)_1." + F : "", R = X.toString, j = P.hasOwnProperty,
|
|
13522
|
+
var F, D, z, Q = Array.prototype, X = Function.prototype, P = Object.prototype, M = x["__core-js_shared__"], B = (F = /[^.]+$/.exec(M && M.keys && M.keys.IE_PROTO || "")) ? "Symbol(src)_1." + F : "", R = X.toString, j = P.hasOwnProperty, A = P.toString, N = RegExp("^" + R.call(j).replace(/[\\^$.*+?()[\]{}|]/g, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"), W = x.Symbol, Y = x.Uint8Array, J = P.propertyIsEnumerable, e1 = Q.splice, s1 = (D = Object.keys, z = Object, function(G) {
|
|
13519
13523
|
return D(z(G));
|
|
13520
13524
|
}), f1 = S5(x, "DataView"), p1 = S5(x, "Map"), m1 = S5(x, "Promise"), U = S5(x, "Set"), o1 = S5(x, "WeakMap"), C1 = S5(Object, "create"), q = V5(f1), $ = V5(p1), t1 = V5(m1), i1 = V5(U), n1 = V5(o1), l1 = W ? W.prototype : void 0, u1 = l1 ? l1.valueOf : void 0, d1 = l1 ? l1.toString : void 0;
|
|
13521
13525
|
function h1(G) {
|
|
@@ -13856,7 +13860,7 @@ var J8 = function(e) {
|
|
|
13856
13860
|
return J5(a1) ? a1 : void 0;
|
|
13857
13861
|
}
|
|
13858
13862
|
var m5 = function(G) {
|
|
13859
|
-
return
|
|
13863
|
+
return A.call(G);
|
|
13860
13864
|
};
|
|
13861
13865
|
function Ie(G, K) {
|
|
13862
13866
|
return !!(K = K ?? 9007199254740991) && (typeof G == "number" || m.test(G)) && G > -1 && G % 1 == 0 && G < K;
|
|
@@ -13876,7 +13880,7 @@ var J8 = function(e) {
|
|
|
13876
13880
|
};
|
|
13877
13881
|
}
|
|
13878
13882
|
(f1 && m5(new f1(new ArrayBuffer(1))) != "[object DataView]" || p1 && m5(new p1()) != p || m1 && m5(m1.resolve()) != "[object Promise]" || U && m5(new U()) != s || o1 && m5(new o1()) != "[object WeakMap]") && (m5 = function(G) {
|
|
13879
|
-
var K =
|
|
13883
|
+
var K = A.call(G), a1 = K == b ? G.constructor : void 0, c1 = a1 ? V5(a1) : void 0;
|
|
13880
13884
|
if (c1)
|
|
13881
13885
|
switch (c1) {
|
|
13882
13886
|
case q:
|
|
@@ -13944,7 +13948,7 @@ var J8 = function(e) {
|
|
|
13944
13948
|
function ke(G) {
|
|
13945
13949
|
return function(K) {
|
|
13946
13950
|
return p2(K) && d3(K);
|
|
13947
|
-
}(G) && j.call(G, "callee") && (!J.call(G, "callee") ||
|
|
13951
|
+
}(G) && j.call(G, "callee") && (!J.call(G, "callee") || A.call(G) == d);
|
|
13948
13952
|
}
|
|
13949
13953
|
C3.Cache = H1;
|
|
13950
13954
|
var v5 = Array.isArray;
|
|
@@ -13952,7 +13956,7 @@ var J8 = function(e) {
|
|
|
13952
13956
|
return G != null && f3(G.length) && !Me(G);
|
|
13953
13957
|
}
|
|
13954
13958
|
function Me(G) {
|
|
13955
|
-
var K = h2(G) ?
|
|
13959
|
+
var K = h2(G) ? A.call(G) : "";
|
|
13956
13960
|
return K == "[object Function]" || K == "[object GeneratorFunction]";
|
|
13957
13961
|
}
|
|
13958
13962
|
function f3(G) {
|
|
@@ -13966,14 +13970,14 @@ var J8 = function(e) {
|
|
|
13966
13970
|
return !!G && typeof G == "object";
|
|
13967
13971
|
}
|
|
13968
13972
|
function h3(G) {
|
|
13969
|
-
return typeof G == "symbol" || p2(G) &&
|
|
13973
|
+
return typeof G == "symbol" || p2(G) && A.call(G) == "[object Symbol]";
|
|
13970
13974
|
}
|
|
13971
13975
|
var e6 = I ? function(G) {
|
|
13972
13976
|
return function(K) {
|
|
13973
13977
|
return G(K);
|
|
13974
13978
|
};
|
|
13975
13979
|
}(I) : function(G) {
|
|
13976
|
-
return p2(G) && f3(G.length) && !!c[
|
|
13980
|
+
return p2(G) && f3(G.length) && !!c[A.call(G)];
|
|
13977
13981
|
};
|
|
13978
13982
|
function g2(G) {
|
|
13979
13983
|
return d3(G) ? j1(G) : K9(G);
|
|
@@ -14065,19 +14069,19 @@ var J8 = function(e) {
|
|
|
14065
14069
|
})(P, M);
|
|
14066
14070
|
}
|
|
14067
14071
|
i.r(o);
|
|
14068
|
-
var m = i(0), c = i.n(m), f = i(5), g = i.n(f), x = i(4), C = i.n(x), w = i(6),
|
|
14072
|
+
var m = i(0), c = i.n(m), f = i(5), g = i.n(f), x = i(4), C = i.n(x), w = i(6), _ = i.n(w), L = i(2), I = i.n(L), Z = i(1), V = i.n(Z);
|
|
14069
14073
|
i(8);
|
|
14070
14074
|
function H(P, M) {
|
|
14071
14075
|
return p(P) || function(B, R) {
|
|
14072
|
-
var j = [],
|
|
14076
|
+
var j = [], A = !0, N = !1, W = void 0;
|
|
14073
14077
|
try {
|
|
14074
|
-
for (var Y, J = B[Symbol.iterator](); !(
|
|
14078
|
+
for (var Y, J = B[Symbol.iterator](); !(A = (Y = J.next()).done) && (j.push(Y.value), !R || j.length !== R); A = !0)
|
|
14075
14079
|
;
|
|
14076
14080
|
} catch (e1) {
|
|
14077
14081
|
N = !0, W = e1;
|
|
14078
14082
|
} finally {
|
|
14079
14083
|
try {
|
|
14080
|
-
|
|
14084
|
+
A || J.return == null || J.return();
|
|
14081
14085
|
} finally {
|
|
14082
14086
|
if (N)
|
|
14083
14087
|
throw W;
|
|
@@ -14091,8 +14095,8 @@ var J8 = function(e) {
|
|
|
14091
14095
|
return !B || j ? P + "".padEnd(M.length, ".") + " " + R : P + "".padEnd(M.length, ".") + " " + B;
|
|
14092
14096
|
}
|
|
14093
14097
|
function F(P, M, B, R, j) {
|
|
14094
|
-
var
|
|
14095
|
-
return N = M === !0, [(
|
|
14098
|
+
var A, N, W = [];
|
|
14099
|
+
return N = M === !0, [(A = []).concat.apply(A, d(P.map(function(Y) {
|
|
14096
14100
|
var J = { name: Y[0], regions: Y[1], iso2: Y[2], countryCode: Y[3], dialCode: Y[3], format: E(B, Y[3], Y[4], R, j), priority: Y[5] || 0 }, e1 = [];
|
|
14097
14101
|
return Y[6] && Y[6].map(function(s1) {
|
|
14098
14102
|
var f1 = function(p1) {
|
|
@@ -14112,25 +14116,25 @@ var J8 = function(e) {
|
|
|
14112
14116
|
}
|
|
14113
14117
|
function D(P, M, B, R) {
|
|
14114
14118
|
if (B !== null) {
|
|
14115
|
-
var j = Object.keys(B),
|
|
14119
|
+
var j = Object.keys(B), A = Object.values(B);
|
|
14116
14120
|
j.forEach(function(N, W) {
|
|
14117
14121
|
if (R)
|
|
14118
|
-
return P.push([N,
|
|
14122
|
+
return P.push([N, A[W]]);
|
|
14119
14123
|
var Y = P.findIndex(function(e1) {
|
|
14120
14124
|
return e1[0] === N;
|
|
14121
14125
|
});
|
|
14122
14126
|
if (Y === -1) {
|
|
14123
14127
|
var J = [N];
|
|
14124
|
-
J[M] =
|
|
14128
|
+
J[M] = A[W], P.push(J);
|
|
14125
14129
|
} else
|
|
14126
|
-
P[Y][M] =
|
|
14130
|
+
P[Y][M] = A[W];
|
|
14127
14131
|
});
|
|
14128
14132
|
}
|
|
14129
14133
|
}
|
|
14130
14134
|
function z(P, M) {
|
|
14131
14135
|
return M.length === 0 ? P : P.map(function(B) {
|
|
14132
|
-
var R = M.findIndex(function(
|
|
14133
|
-
return
|
|
14136
|
+
var R = M.findIndex(function(A) {
|
|
14137
|
+
return A[0] === B[2];
|
|
14134
14138
|
});
|
|
14135
14139
|
if (R === -1)
|
|
14136
14140
|
return B;
|
|
@@ -14138,7 +14142,7 @@ var J8 = function(e) {
|
|
|
14138
14142
|
return j[1] && (B[4] = j[1]), j[3] && (B[5] = j[3]), j[2] && (B[6] = j[2]), B;
|
|
14139
14143
|
});
|
|
14140
14144
|
}
|
|
14141
|
-
var Q = function P(M, B, R, j,
|
|
14145
|
+
var Q = function P(M, B, R, j, A, N, W, Y, J, e1, s1, f1, p1, m1) {
|
|
14142
14146
|
s(this, P), this.filterRegions = function(l1, u1) {
|
|
14143
14147
|
if (typeof l1 == "string") {
|
|
14144
14148
|
var d1 = l1;
|
|
@@ -14201,19 +14205,19 @@ var J8 = function(e) {
|
|
|
14201
14205
|
var i1 = H(F(C1, M, f1, p1, m1), 2), n1 = i1[0];
|
|
14202
14206
|
i1[1], $ = this.sortTerritories(n1, $);
|
|
14203
14207
|
}
|
|
14204
|
-
R && ($ = this.filterRegions(R, $)), this.onlyCountries = this.localizeCountries(this.excludeCountries(this.getFilteredCountryList(j, $, W.includes("onlyCountries")), N), s1, W.includes("onlyCountries")), this.preferredCountries =
|
|
14208
|
+
R && ($ = this.filterRegions(R, $)), this.onlyCountries = this.localizeCountries(this.excludeCountries(this.getFilteredCountryList(j, $, W.includes("onlyCountries")), N), s1, W.includes("onlyCountries")), this.preferredCountries = A.length === 0 ? [] : this.localizeCountries(this.getFilteredCountryList(A, $, W.includes("preferredCountries")), s1, W.includes("preferredCountries")), this.hiddenAreaCodes = this.excludeCountries(this.getFilteredCountryList(j, t1), N);
|
|
14205
14209
|
}, X = function(P) {
|
|
14206
14210
|
function M(j) {
|
|
14207
|
-
var
|
|
14208
|
-
s(this, M), (
|
|
14211
|
+
var A;
|
|
14212
|
+
s(this, M), (A = function(U, o1) {
|
|
14209
14213
|
return !o1 || u(o1) !== "object" && typeof o1 != "function" ? a(U) : o1;
|
|
14210
14214
|
}(this, l(M).call(this, j))).getProbableCandidate = C()(function(U) {
|
|
14211
|
-
return U && U.length !== 0 ?
|
|
14215
|
+
return U && U.length !== 0 ? A.state.onlyCountries.filter(function(o1) {
|
|
14212
14216
|
return I()(o1.name.toLowerCase(), U.toLowerCase());
|
|
14213
|
-
}, a(a(
|
|
14214
|
-
}),
|
|
14217
|
+
}, a(a(A)))[0] : null;
|
|
14218
|
+
}), A.guessSelectedCountry = C()(function(U, o1, C1, q) {
|
|
14215
14219
|
var $;
|
|
14216
|
-
if (
|
|
14220
|
+
if (A.props.enableAreaCodes === !1 && (q.some(function(n1) {
|
|
14217
14221
|
if (I()(U, n1.dialCode))
|
|
14218
14222
|
return C1.some(function(l1) {
|
|
14219
14223
|
if (n1.iso2 === l1.iso2 && l1.mainCode)
|
|
@@ -14228,21 +14232,21 @@ var J8 = function(e) {
|
|
|
14228
14232
|
return t1;
|
|
14229
14233
|
var i1 = C1.reduce(function(n1, l1) {
|
|
14230
14234
|
return I()(U, l1.dialCode) && (l1.dialCode.length > n1.dialCode.length || l1.dialCode.length === n1.dialCode.length && l1.priority < n1.priority) ? l1 : n1;
|
|
14231
|
-
}, { dialCode: "", priority: 10001 }, a(a(
|
|
14235
|
+
}, { dialCode: "", priority: 10001 }, a(a(A)));
|
|
14232
14236
|
return i1.name ? i1 : t1;
|
|
14233
|
-
}),
|
|
14234
|
-
var o1, C1 =
|
|
14237
|
+
}), A.updateCountry = function(U) {
|
|
14238
|
+
var o1, C1 = A.state.onlyCountries;
|
|
14235
14239
|
(o1 = U.indexOf(0) >= "0" && U.indexOf(0) <= "9" ? C1.find(function(q) {
|
|
14236
14240
|
return q.dialCode == +U;
|
|
14237
14241
|
}) : C1.find(function(q) {
|
|
14238
14242
|
return q.iso2 == U;
|
|
14239
|
-
})) && o1.dialCode &&
|
|
14240
|
-
},
|
|
14243
|
+
})) && o1.dialCode && A.setState({ selectedCountry: o1, formattedNumber: A.props.disableCountryCode ? "" : A.formatNumber(o1.dialCode, o1) });
|
|
14244
|
+
}, A.scrollTo = function(U, o1) {
|
|
14241
14245
|
if (U) {
|
|
14242
|
-
var C1 =
|
|
14246
|
+
var C1 = A.dropdownRef;
|
|
14243
14247
|
if (C1 && document.body) {
|
|
14244
14248
|
var q = C1.offsetHeight, $ = C1.getBoundingClientRect().top + document.body.scrollTop, t1 = $ + q, i1 = U, n1 = i1.getBoundingClientRect(), l1 = i1.offsetHeight, u1 = n1.top + document.body.scrollTop, d1 = u1 + l1, h1 = u1 - $ + C1.scrollTop, g1 = q / 2 - l1 / 2;
|
|
14245
|
-
if (
|
|
14249
|
+
if (A.props.enableSearch ? u1 < $ + 32 : u1 < $)
|
|
14246
14250
|
o1 && (h1 -= g1), C1.scrollTop = h1;
|
|
14247
14251
|
else if (d1 > t1) {
|
|
14248
14252
|
o1 && (h1 += g1);
|
|
@@ -14251,18 +14255,18 @@ var J8 = function(e) {
|
|
|
14251
14255
|
}
|
|
14252
14256
|
}
|
|
14253
14257
|
}
|
|
14254
|
-
},
|
|
14255
|
-
var U =
|
|
14258
|
+
}, A.scrollToTop = function() {
|
|
14259
|
+
var U = A.dropdownRef;
|
|
14256
14260
|
U && document.body && (U.scrollTop = 0);
|
|
14257
|
-
},
|
|
14261
|
+
}, A.formatNumber = function(U, o1) {
|
|
14258
14262
|
if (!o1)
|
|
14259
14263
|
return U;
|
|
14260
|
-
var C1, q = o1.format, $ =
|
|
14264
|
+
var C1, q = o1.format, $ = A.props, t1 = $.disableCountryCode, i1 = $.enableAreaCodeStretch, n1 = $.enableLongNumbers, l1 = $.autoFormat;
|
|
14261
14265
|
if (t1 ? ((C1 = q.split(" ")).shift(), C1 = C1.join(" ")) : i1 && o1.isAreaCode ? ((C1 = q.split(" "))[1] = C1[1].replace(/\.+/, "".padEnd(o1.areaCodeLength, ".")), C1 = C1.join(" ")) : C1 = q, !U || U.length === 0)
|
|
14262
|
-
return t1 ? "" :
|
|
14266
|
+
return t1 ? "" : A.props.prefix;
|
|
14263
14267
|
if (U && U.length < 2 || !C1 || !l1)
|
|
14264
|
-
return t1 ? U :
|
|
14265
|
-
var u1, d1 =
|
|
14268
|
+
return t1 ? U : A.props.prefix + U;
|
|
14269
|
+
var u1, d1 = _()(C1, function(h1, g1) {
|
|
14266
14270
|
if (h1.remainingText.length === 0)
|
|
14267
14271
|
return h1;
|
|
14268
14272
|
if (g1 !== ".")
|
|
@@ -14271,94 +14275,94 @@ var J8 = function(e) {
|
|
|
14271
14275
|
return { formattedText: h1.formattedText + k1, remainingText: j1 };
|
|
14272
14276
|
}, { formattedText: "", remainingText: U.split("") });
|
|
14273
14277
|
return (u1 = n1 ? d1.formattedText + d1.remainingText.join("") : d1.formattedText).includes("(") && !u1.includes(")") && (u1 += ")"), u1;
|
|
14274
|
-
},
|
|
14275
|
-
var U =
|
|
14278
|
+
}, A.cursorToEnd = function() {
|
|
14279
|
+
var U = A.numberInputRef;
|
|
14276
14280
|
if (document.activeElement === U) {
|
|
14277
14281
|
U.focus();
|
|
14278
14282
|
var o1 = U.value.length;
|
|
14279
14283
|
U.value.charAt(o1 - 1) === ")" && (o1 -= 1), U.setSelectionRange(o1, o1);
|
|
14280
14284
|
}
|
|
14281
|
-
},
|
|
14282
|
-
return
|
|
14283
|
-
},
|
|
14284
|
-
return
|
|
14285
|
-
},
|
|
14286
|
-
if (U.preventDefault(),
|
|
14287
|
-
var o1 =
|
|
14285
|
+
}, A.getElement = function(U) {
|
|
14286
|
+
return A["flag_no_".concat(U)];
|
|
14287
|
+
}, A.getCountryData = function() {
|
|
14288
|
+
return A.state.selectedCountry ? { name: A.state.selectedCountry.name || "", dialCode: A.state.selectedCountry.dialCode || "", countryCode: A.state.selectedCountry.iso2 || "", format: A.state.selectedCountry.format || "" } : {};
|
|
14289
|
+
}, A.handleFlagDropdownClick = function(U) {
|
|
14290
|
+
if (U.preventDefault(), A.state.showDropdown || !A.props.disabled) {
|
|
14291
|
+
var o1 = A.state, C1 = o1.preferredCountries, q = o1.onlyCountries, $ = o1.selectedCountry, t1 = A.concatPreferredCountries(C1, q).findIndex(function(i1) {
|
|
14288
14292
|
return i1.dialCode === $.dialCode && i1.iso2 === $.iso2;
|
|
14289
14293
|
});
|
|
14290
|
-
|
|
14291
|
-
|
|
14294
|
+
A.setState({ showDropdown: !A.state.showDropdown, highlightCountryIndex: t1 }, function() {
|
|
14295
|
+
A.state.showDropdown && A.scrollTo(A.getElement(A.state.highlightCountryIndex));
|
|
14292
14296
|
});
|
|
14293
14297
|
}
|
|
14294
|
-
},
|
|
14295
|
-
var o1 = U.target.value, C1 =
|
|
14296
|
-
if (!
|
|
14297
|
-
var l1 = q + (i1.hasAreaCodes ?
|
|
14298
|
+
}, A.handleInput = function(U) {
|
|
14299
|
+
var o1 = U.target.value, C1 = A.props, q = C1.prefix, $ = C1.onChange, t1 = A.props.disableCountryCode ? "" : q, i1 = A.state.selectedCountry, n1 = A.state.freezeSelection;
|
|
14300
|
+
if (!A.props.countryCodeEditable) {
|
|
14301
|
+
var l1 = q + (i1.hasAreaCodes ? A.state.onlyCountries.find(function(z1) {
|
|
14298
14302
|
return z1.iso2 === i1.iso2 && z1.mainCode;
|
|
14299
14303
|
}).dialCode : i1.dialCode);
|
|
14300
14304
|
if (o1.slice(0, l1.length) !== l1)
|
|
14301
14305
|
return;
|
|
14302
14306
|
}
|
|
14303
14307
|
if (o1 === q)
|
|
14304
|
-
return $ && $("",
|
|
14305
|
-
if (!(o1.replace(/\D/g, "").length > 15 && (
|
|
14308
|
+
return $ && $("", A.getCountryData(), U, ""), A.setState({ formattedNumber: "" });
|
|
14309
|
+
if (!(o1.replace(/\D/g, "").length > 15 && (A.props.enableLongNumbers === !1 || typeof A.props.enableLongNumbers == "number" && o1.replace(/\D/g, "").length > A.props.enableLongNumbers)) && o1 !== A.state.formattedNumber) {
|
|
14306
14310
|
U.preventDefault ? U.preventDefault() : U.returnValue = !1;
|
|
14307
|
-
var u1 =
|
|
14311
|
+
var u1 = A.props.country, d1 = A.state, h1 = d1.onlyCountries, g1 = d1.selectedCountry, H1 = d1.hiddenAreaCodes;
|
|
14308
14312
|
if ($ && U.persist(), o1.length > 0) {
|
|
14309
14313
|
var $1 = o1.replace(/\D/g, "");
|
|
14310
|
-
(!
|
|
14314
|
+
(!A.state.freezeSelection || g1 && g1.dialCode.length > $1.length) && (i1 = A.props.disableCountryGuess ? g1 : A.guessSelectedCountry($1.substring(0, 6), u1, h1, H1) || g1, n1 = !1), t1 = A.formatNumber($1, i1), i1 = i1.dialCode ? i1 : g1;
|
|
14311
14315
|
}
|
|
14312
|
-
var k1 = U.target.selectionStart, j1 = U.target.selectionStart, C5 =
|
|
14313
|
-
|
|
14314
|
-
H5 > 0 && (j1 -= H5), t1.charAt(t1.length - 1) == ")" ?
|
|
14316
|
+
var k1 = U.target.selectionStart, j1 = U.target.selectionStart, C5 = A.state.formattedNumber, H5 = t1.length - C5.length;
|
|
14317
|
+
A.setState({ formattedNumber: t1, freezeSelection: n1, selectedCountry: i1 }, function() {
|
|
14318
|
+
H5 > 0 && (j1 -= H5), t1.charAt(t1.length - 1) == ")" ? A.numberInputRef.setSelectionRange(t1.length - 1, t1.length - 1) : j1 > 0 && C5.length >= t1.length ? A.numberInputRef.setSelectionRange(j1, j1) : k1 < C5.length && A.numberInputRef.setSelectionRange(k1, k1), $ && $(t1.replace(/[^0-9]+/g, ""), A.getCountryData(), U, t1);
|
|
14315
14319
|
});
|
|
14316
14320
|
}
|
|
14317
|
-
},
|
|
14318
|
-
|
|
14319
|
-
},
|
|
14321
|
+
}, A.handleInputClick = function(U) {
|
|
14322
|
+
A.setState({ showDropdown: !1 }), A.props.onClick && A.props.onClick(U, A.getCountryData());
|
|
14323
|
+
}, A.handleDoubleClick = function(U) {
|
|
14320
14324
|
var o1 = U.target.value.length;
|
|
14321
14325
|
U.target.setSelectionRange(0, o1);
|
|
14322
|
-
},
|
|
14323
|
-
var C1 =
|
|
14326
|
+
}, A.handleFlagItemClick = function(U, o1) {
|
|
14327
|
+
var C1 = A.state.selectedCountry, q = A.state.onlyCountries.find(function(n1) {
|
|
14324
14328
|
return n1 == U;
|
|
14325
14329
|
});
|
|
14326
14330
|
if (q) {
|
|
14327
|
-
var $ =
|
|
14328
|
-
|
|
14329
|
-
|
|
14331
|
+
var $ = A.state.formattedNumber.replace(" ", "").replace("(", "").replace(")", "").replace("-", ""), t1 = $.length > 1 ? $.replace(C1.dialCode, q.dialCode) : q.dialCode, i1 = A.formatNumber(t1.replace(/\D/g, ""), q);
|
|
14332
|
+
A.setState({ showDropdown: !1, selectedCountry: q, freezeSelection: !0, formattedNumber: i1, searchValue: "" }, function() {
|
|
14333
|
+
A.cursorToEnd(), A.props.onChange && A.props.onChange(i1.replace(/[^0-9]+/g, ""), A.getCountryData(), o1, i1);
|
|
14330
14334
|
});
|
|
14331
14335
|
}
|
|
14332
|
-
},
|
|
14333
|
-
|
|
14334
|
-
|
|
14335
|
-
}),
|
|
14336
|
-
},
|
|
14337
|
-
U.target.value ||
|
|
14338
|
-
},
|
|
14339
|
-
if (
|
|
14336
|
+
}, A.handleInputFocus = function(U) {
|
|
14337
|
+
A.numberInputRef && A.numberInputRef.value === A.props.prefix && A.state.selectedCountry && !A.props.disableCountryCode && A.setState({ formattedNumber: A.props.prefix + A.state.selectedCountry.dialCode }, function() {
|
|
14338
|
+
A.props.jumpCursorToEnd && setTimeout(A.cursorToEnd, 0);
|
|
14339
|
+
}), A.setState({ placeholder: "" }), A.props.onFocus && A.props.onFocus(U, A.getCountryData()), A.props.jumpCursorToEnd && setTimeout(A.cursorToEnd, 0);
|
|
14340
|
+
}, A.handleInputBlur = function(U) {
|
|
14341
|
+
U.target.value || A.setState({ placeholder: A.props.placeholder }), A.props.onBlur && A.props.onBlur(U, A.getCountryData());
|
|
14342
|
+
}, A.handleInputCopy = function(U) {
|
|
14343
|
+
if (A.props.copyNumbersOnly) {
|
|
14340
14344
|
var o1 = window.getSelection().toString().replace(/[^0-9]+/g, "");
|
|
14341
14345
|
U.clipboardData.setData("text/plain", o1), U.preventDefault();
|
|
14342
14346
|
}
|
|
14343
|
-
},
|
|
14344
|
-
var o1 =
|
|
14345
|
-
return o1 < 0 || o1 >=
|
|
14346
|
-
},
|
|
14347
|
-
var U =
|
|
14347
|
+
}, A.getHighlightCountryIndex = function(U) {
|
|
14348
|
+
var o1 = A.state.highlightCountryIndex + U;
|
|
14349
|
+
return o1 < 0 || o1 >= A.state.onlyCountries.length + A.state.preferredCountries.length ? o1 - U : A.props.enableSearch && o1 > A.getSearchFilteredCountries().length ? 0 : o1;
|
|
14350
|
+
}, A.searchCountry = function() {
|
|
14351
|
+
var U = A.getProbableCandidate(A.state.queryString) || A.state.onlyCountries[0], o1 = A.state.onlyCountries.findIndex(function(C1) {
|
|
14348
14352
|
return C1 == U;
|
|
14349
|
-
}) +
|
|
14350
|
-
|
|
14351
|
-
},
|
|
14352
|
-
var o1 =
|
|
14353
|
-
if (C1.includes("selected-flag") && U.which === o1.ENTER && !
|
|
14354
|
-
return
|
|
14353
|
+
}) + A.state.preferredCountries.length;
|
|
14354
|
+
A.scrollTo(A.getElement(o1), !0), A.setState({ queryString: "", highlightCountryIndex: o1 });
|
|
14355
|
+
}, A.handleKeydown = function(U) {
|
|
14356
|
+
var o1 = A.props.keys, C1 = U.target.className;
|
|
14357
|
+
if (C1.includes("selected-flag") && U.which === o1.ENTER && !A.state.showDropdown)
|
|
14358
|
+
return A.handleFlagDropdownClick(U);
|
|
14355
14359
|
if (C1.includes("form-control") && (U.which === o1.ENTER || U.which === o1.ESC))
|
|
14356
14360
|
return U.target.blur();
|
|
14357
|
-
if (
|
|
14361
|
+
if (A.state.showDropdown && !A.props.disabled && (!C1.includes("search-box") || U.which === o1.UP || U.which === o1.DOWN || U.which === o1.ENTER || U.which === o1.ESC && U.target.value === "")) {
|
|
14358
14362
|
U.preventDefault ? U.preventDefault() : U.returnValue = !1;
|
|
14359
14363
|
var q = function($) {
|
|
14360
|
-
|
|
14361
|
-
|
|
14364
|
+
A.setState({ highlightCountryIndex: A.getHighlightCountryIndex($) }, function() {
|
|
14365
|
+
A.scrollTo(A.getElement(A.state.highlightCountryIndex), !0);
|
|
14362
14366
|
});
|
|
14363
14367
|
};
|
|
14364
14368
|
switch (U.which) {
|
|
@@ -14369,38 +14373,38 @@ var J8 = function(e) {
|
|
|
14369
14373
|
q(-1);
|
|
14370
14374
|
break;
|
|
14371
14375
|
case o1.ENTER:
|
|
14372
|
-
|
|
14376
|
+
A.props.enableSearch ? A.handleFlagItemClick(A.getSearchFilteredCountries()[A.state.highlightCountryIndex] || A.getSearchFilteredCountries()[0], U) : A.handleFlagItemClick([].concat(d(A.state.preferredCountries), d(A.state.onlyCountries))[A.state.highlightCountryIndex], U);
|
|
14373
14377
|
break;
|
|
14374
14378
|
case o1.ESC:
|
|
14375
14379
|
case o1.TAB:
|
|
14376
|
-
|
|
14380
|
+
A.setState({ showDropdown: !1 }, A.cursorToEnd);
|
|
14377
14381
|
break;
|
|
14378
14382
|
default:
|
|
14379
|
-
(U.which >= o1.A && U.which <= o1.Z || U.which === o1.SPACE) &&
|
|
14383
|
+
(U.which >= o1.A && U.which <= o1.Z || U.which === o1.SPACE) && A.setState({ queryString: A.state.queryString + String.fromCharCode(U.which) }, A.state.debouncedQueryStingSearcher);
|
|
14380
14384
|
}
|
|
14381
14385
|
}
|
|
14382
|
-
},
|
|
14383
|
-
var o1 =
|
|
14386
|
+
}, A.handleInputKeyDown = function(U) {
|
|
14387
|
+
var o1 = A.props, C1 = o1.keys, q = o1.onEnterKeyPress, $ = o1.onKeyDown;
|
|
14384
14388
|
U.which === C1.ENTER && q && q(U), $ && $(U);
|
|
14385
|
-
},
|
|
14386
|
-
|
|
14387
|
-
},
|
|
14388
|
-
var o1 = U.currentTarget.value, C1 =
|
|
14389
|
+
}, A.handleClickOutside = function(U) {
|
|
14390
|
+
A.dropdownRef && !A.dropdownContainerRef.contains(U.target) && A.state.showDropdown && A.setState({ showDropdown: !1 });
|
|
14391
|
+
}, A.handleSearchChange = function(U) {
|
|
14392
|
+
var o1 = U.currentTarget.value, C1 = A.state, q = C1.preferredCountries, $ = C1.selectedCountry, t1 = 0;
|
|
14389
14393
|
if (o1 === "" && $) {
|
|
14390
|
-
var i1 =
|
|
14391
|
-
t1 =
|
|
14394
|
+
var i1 = A.state.onlyCountries;
|
|
14395
|
+
t1 = A.concatPreferredCountries(q, i1).findIndex(function(n1) {
|
|
14392
14396
|
return n1 == $;
|
|
14393
14397
|
}), setTimeout(function() {
|
|
14394
|
-
return
|
|
14398
|
+
return A.scrollTo(A.getElement(t1));
|
|
14395
14399
|
}, 100);
|
|
14396
14400
|
}
|
|
14397
|
-
|
|
14398
|
-
},
|
|
14401
|
+
A.setState({ searchValue: o1, highlightCountryIndex: t1 });
|
|
14402
|
+
}, A.concatPreferredCountries = function(U, o1) {
|
|
14399
14403
|
return U.length > 0 ? d(new Set(U.concat(o1))) : o1;
|
|
14400
|
-
},
|
|
14404
|
+
}, A.getDropdownCountryName = function(U) {
|
|
14401
14405
|
return U.localName || U.name;
|
|
14402
|
-
},
|
|
14403
|
-
var U =
|
|
14406
|
+
}, A.getSearchFilteredCountries = function() {
|
|
14407
|
+
var U = A.state, o1 = U.preferredCountries, C1 = U.onlyCountries, q = U.searchValue, $ = A.props.enableSearch, t1 = A.concatPreferredCountries(o1, C1), i1 = q.trim().toLowerCase().replace("+", "");
|
|
14404
14408
|
if ($ && i1) {
|
|
14405
14409
|
if (/^\d+$/.test(i1))
|
|
14406
14410
|
return t1.filter(function(u1) {
|
|
@@ -14420,50 +14424,50 @@ var J8 = function(e) {
|
|
|
14420
14424
|
return g1.toLowerCase().includes(i1);
|
|
14421
14425
|
});
|
|
14422
14426
|
});
|
|
14423
|
-
return
|
|
14427
|
+
return A.scrollToTop(), d(new Set([].concat(n1, l1)));
|
|
14424
14428
|
}
|
|
14425
14429
|
return t1;
|
|
14426
|
-
},
|
|
14427
|
-
var U =
|
|
14430
|
+
}, A.getCountryDropdownList = function() {
|
|
14431
|
+
var U = A.state, o1 = U.preferredCountries, C1 = U.highlightCountryIndex, q = U.showDropdown, $ = U.searchValue, t1 = A.props, i1 = t1.disableDropdown, n1 = t1.prefix, l1 = A.props, u1 = l1.enableSearch, d1 = l1.searchNotFound, h1 = l1.disableSearchIcon, g1 = l1.searchClass, H1 = l1.searchStyle, $1 = l1.searchPlaceholder, k1 = l1.autocompleteSearch, j1 = A.getSearchFilteredCountries().map(function(z1, Z5) {
|
|
14428
14432
|
var X5 = C1 === Z5, c3 = V()({ country: !0, preferred: z1.iso2 === "us" || z1.iso2 === "gb", active: z1.iso2 === "us", highlight: X5 }), Y5 = "flag ".concat(z1.iso2);
|
|
14429
14433
|
return c.a.createElement("li", Object.assign({ ref: function(J5) {
|
|
14430
|
-
return
|
|
14434
|
+
return A["flag_no_".concat(Z5)] = J5;
|
|
14431
14435
|
}, key: "flag_no_".concat(Z5), "data-flag-key": "flag_no_".concat(Z5), className: c3, "data-dial-code": "1", tabIndex: i1 ? "-1" : "0", "data-country-code": z1.iso2, onClick: function(J5) {
|
|
14432
|
-
return
|
|
14433
|
-
}, role: "option" }, X5 ? { "aria-selected": !0 } : {}), c.a.createElement("div", { className: Y5 }), c.a.createElement("span", { className: "country-name" },
|
|
14436
|
+
return A.handleFlagItemClick(z1, J5);
|
|
14437
|
+
}, role: "option" }, X5 ? { "aria-selected": !0 } : {}), c.a.createElement("div", { className: Y5 }), c.a.createElement("span", { className: "country-name" }, A.getDropdownCountryName(z1)), c.a.createElement("span", { className: "dial-code" }, z1.format ? A.formatNumber(z1.dialCode, z1) : n1 + z1.dialCode));
|
|
14434
14438
|
}), C5 = c.a.createElement("li", { key: "dashes", className: "divider" });
|
|
14435
14439
|
o1.length > 0 && (!u1 || u1 && !$.trim()) && j1.splice(o1.length, 0, C5);
|
|
14436
|
-
var H5 = V()(r({ "country-list": !0, hide: !q },
|
|
14440
|
+
var H5 = V()(r({ "country-list": !0, hide: !q }, A.props.dropdownClass, !0));
|
|
14437
14441
|
return c.a.createElement("ul", { ref: function(z1) {
|
|
14438
|
-
return !u1 && z1 && z1.focus(),
|
|
14439
|
-
}, className: H5, style:
|
|
14442
|
+
return !u1 && z1 && z1.focus(), A.dropdownRef = z1;
|
|
14443
|
+
}, className: H5, style: A.props.dropdownStyle, role: "listbox", tabIndex: "0" }, u1 && c.a.createElement("li", { className: V()(r({ search: !0 }, g1, g1)) }, !h1 && c.a.createElement("span", { className: V()(r({ "search-emoji": !0 }, "".concat(g1, "-emoji"), g1)), role: "img", "aria-label": "Magnifying glass" }, "🔎"), c.a.createElement("input", { className: V()(r({ "search-box": !0 }, "".concat(g1, "-box"), g1)), style: H1, type: "search", placeholder: $1, autoFocus: !0, autoComplete: k1 ? "on" : "off", value: $, onChange: A.handleSearchChange })), j1.length > 0 ? j1 : c.a.createElement("li", { className: "no-entries-message" }, c.a.createElement("span", null, d1)));
|
|
14440
14444
|
};
|
|
14441
14445
|
var N, W = new Q(j.enableAreaCodes, j.enableTerritories, j.regions, j.onlyCountries, j.preferredCountries, j.excludeCountries, j.preserveOrder, j.masks, j.priority, j.areaCodes, j.localization, j.prefix, j.defaultMask, j.alwaysDefaultMask), Y = W.onlyCountries, J = W.preferredCountries, e1 = W.hiddenAreaCodes, s1 = j.value ? j.value.replace(/\D/g, "") : "";
|
|
14442
|
-
N = j.disableInitialCountryGuess ? 0 : s1.length > 1 ?
|
|
14446
|
+
N = j.disableInitialCountryGuess ? 0 : s1.length > 1 ? A.guessSelectedCountry(s1.substring(0, 6), j.country, Y, e1) || 0 : j.country && Y.find(function(U) {
|
|
14443
14447
|
return U.iso2 == j.country;
|
|
14444
14448
|
}) || 0;
|
|
14445
14449
|
var f1, p1 = s1.length < 2 && N && !I()(s1, N.dialCode) ? N.dialCode : "";
|
|
14446
|
-
f1 = s1 === "" && N === 0 ? "" :
|
|
14450
|
+
f1 = s1 === "" && N === 0 ? "" : A.formatNumber((j.disableCountryCode ? "" : p1) + s1, N.name ? N : void 0);
|
|
14447
14451
|
var m1 = Y.findIndex(function(U) {
|
|
14448
14452
|
return U == N;
|
|
14449
14453
|
});
|
|
14450
|
-
return
|
|
14454
|
+
return A.state = { showDropdown: j.showDropdown, formattedNumber: f1, onlyCountries: Y, preferredCountries: J, hiddenAreaCodes: e1, selectedCountry: N, highlightCountryIndex: m1, queryString: "", freezeSelection: !1, debouncedQueryStingSearcher: g()(A.searchCountry, 250), searchValue: "" }, A;
|
|
14451
14455
|
}
|
|
14452
14456
|
var B, R;
|
|
14453
|
-
return function(j,
|
|
14454
|
-
if (typeof
|
|
14457
|
+
return function(j, A) {
|
|
14458
|
+
if (typeof A != "function" && A !== null)
|
|
14455
14459
|
throw new TypeError("Super expression must either be null or a function");
|
|
14456
|
-
j.prototype = Object.create(
|
|
14460
|
+
j.prototype = Object.create(A && A.prototype, { constructor: { value: j, writable: !0, configurable: !0 } }), A && y(j, A);
|
|
14457
14461
|
}(M, P), B = M, (R = [{ key: "componentDidMount", value: function() {
|
|
14458
14462
|
document.addEventListener && this.props.enableClickOutside && document.addEventListener("mousedown", this.handleClickOutside), this.props.onMount && this.props.onMount(this.state.formattedNumber.replace(/[^0-9]+/g, ""), this.getCountryData(), this.state.formattedNumber);
|
|
14459
14463
|
} }, { key: "componentWillUnmount", value: function() {
|
|
14460
14464
|
document.removeEventListener && this.props.enableClickOutside && document.removeEventListener("mousedown", this.handleClickOutside);
|
|
14461
|
-
} }, { key: "componentDidUpdate", value: function(j,
|
|
14465
|
+
} }, { key: "componentDidUpdate", value: function(j, A, N) {
|
|
14462
14466
|
j.country !== this.props.country ? this.updateCountry(this.props.country) : j.value !== this.props.value && this.updateFormattedNumber(this.props.value);
|
|
14463
14467
|
} }, { key: "updateFormattedNumber", value: function(j) {
|
|
14464
14468
|
if (j === null)
|
|
14465
14469
|
return this.setState({ selectedCountry: 0, formattedNumber: "" });
|
|
14466
|
-
var
|
|
14470
|
+
var A = this.state, N = A.onlyCountries, W = A.selectedCountry, Y = A.hiddenAreaCodes, J = this.props, e1 = J.country, s1 = J.prefix;
|
|
14467
14471
|
if (j === "")
|
|
14468
14472
|
return this.setState({ selectedCountry: W, formattedNumber: "" });
|
|
14469
14473
|
var f1, p1, m1 = j.replace(/\D/g, "");
|
|
@@ -14474,14 +14478,14 @@ var J8 = function(e) {
|
|
|
14474
14478
|
p1 = this.formatNumber((this.props.disableCountryCode ? "" : U) + m1, f1 || void 0), this.setState({ selectedCountry: f1, formattedNumber: p1 });
|
|
14475
14479
|
}
|
|
14476
14480
|
} }, { key: "render", value: function() {
|
|
14477
|
-
var j,
|
|
14481
|
+
var j, A, N, W = this, Y = this.state, J = Y.onlyCountries, e1 = Y.selectedCountry, s1 = Y.showDropdown, f1 = Y.formattedNumber, p1 = Y.hiddenAreaCodes, m1 = this.props, U = m1.disableDropdown, o1 = m1.renderStringAsFlag, C1 = m1.isValid, q = m1.defaultErrorMessage, $ = m1.specialLabel;
|
|
14478
14482
|
if (typeof C1 == "boolean")
|
|
14479
|
-
|
|
14483
|
+
A = C1;
|
|
14480
14484
|
else {
|
|
14481
14485
|
var t1 = C1(f1.replace(/\D/g, ""), e1, J, p1);
|
|
14482
|
-
typeof t1 == "boolean" ? (
|
|
14486
|
+
typeof t1 == "boolean" ? (A = t1) === !1 && (N = q) : (A = !1, N = t1);
|
|
14483
14487
|
}
|
|
14484
|
-
var i1 = V()((r(j = {}, this.props.containerClass, !0), r(j, "react-tel-input", !0), j)), n1 = V()({ arrow: !0, up: s1 }), l1 = V()(r({ "form-control": !0, "invalid-number": !
|
|
14488
|
+
var i1 = V()((r(j = {}, this.props.containerClass, !0), r(j, "react-tel-input", !0), j)), n1 = V()({ arrow: !0, up: s1 }), l1 = V()(r({ "form-control": !0, "invalid-number": !A, open: s1 }, this.props.inputClass, !0)), u1 = V()({ "selected-flag": !0, open: s1 }), d1 = V()(r({ "flag-dropdown": !0, "invalid-number": !A, open: s1 }, this.props.buttonClass, !0)), h1 = "flag ".concat(e1 && e1.iso2);
|
|
14485
14489
|
return c.a.createElement("div", { className: "".concat(i1, " ").concat(this.props.className), style: this.props.style || this.props.containerStyle, onKeyDown: this.handleKeydown }, $ && c.a.createElement("div", { className: "special-label" }, $), N && c.a.createElement("div", { className: "invalid-number-message" }, N), c.a.createElement("input", Object.assign({ className: l1, style: this.props.inputStyle, onChange: this.handleInput, onClick: this.handleInputClick, onDoubleClick: this.handleDoubleClick, onFocus: this.handleInputFocus, onBlur: this.handleInputBlur, onCopy: this.handleInputCopy, value: f1, onKeyDown: this.handleInputKeyDown, placeholder: this.props.placeholder, disabled: this.props.disabled, type: "tel" }, this.props.inputProps, { ref: function(g1) {
|
|
14486
14490
|
W.numberInputRef = g1, typeof W.props.inputProps.ref == "function" ? W.props.inputProps.ref(g1) : typeof W.props.inputProps.ref == "object" && (W.props.inputProps.ref.current = g1);
|
|
14487
14491
|
} })), c.a.createElement("div", { className: d1, style: this.props.buttonStyle, ref: function(g1) {
|
|
@@ -14583,11 +14587,11 @@ const sh = ({
|
|
|
14583
14587
|
leftElement: c,
|
|
14584
14588
|
...f
|
|
14585
14589
|
}) => {
|
|
14586
|
-
const [g, x] = E1(!1), C = P1(null), [w,
|
|
14590
|
+
const [g, x] = E1(!1), C = P1(null), [w, _] = E1(0);
|
|
14587
14591
|
return K1(() => {
|
|
14588
14592
|
if (c && C.current) {
|
|
14589
14593
|
const L = C.current.offsetWidth;
|
|
14590
|
-
|
|
14594
|
+
_(L);
|
|
14591
14595
|
}
|
|
14592
14596
|
}, [c, C]), /* @__PURE__ */ r1(L1, { w: l || "full", children: [
|
|
14593
14597
|
e && /* @__PURE__ */ t(
|
|
@@ -15542,8 +15546,8 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
15542
15546
|
if (typeof C.retain == "number") {
|
|
15543
15547
|
var w = {};
|
|
15544
15548
|
typeof x.retain == "number" ? w.retain = g : w.insert = x.insert;
|
|
15545
|
-
var
|
|
15546
|
-
if (
|
|
15549
|
+
var _ = s.attributes.compose(x.attributes, C.attributes, typeof x.retain == "number");
|
|
15550
|
+
if (_ && (w.attributes = _), f.push(w), !l.hasNext() && p(f.ops[f.ops.length - 1], w)) {
|
|
15547
15551
|
var L = new h(a.rest());
|
|
15548
15552
|
return f.concat(L).chop();
|
|
15549
15553
|
}
|
|
@@ -15577,8 +15581,8 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
15577
15581
|
break;
|
|
15578
15582
|
case d.EQUAL:
|
|
15579
15583
|
C = Math.min(c.peekLength(), f.peekLength(), x);
|
|
15580
|
-
var w = c.next(C),
|
|
15581
|
-
p(w.insert,
|
|
15584
|
+
var w = c.next(C), _ = f.next(C);
|
|
15585
|
+
p(w.insert, _.insert) ? y.retain(C, s.attributes.diff(w.attributes, _.attributes)) : y.push(_).delete(C);
|
|
15582
15586
|
break;
|
|
15583
15587
|
}
|
|
15584
15588
|
x -= C;
|
|
@@ -15663,11 +15667,11 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
15663
15667
|
return l[y];
|
|
15664
15668
|
};
|
|
15665
15669
|
i.exports = function a() {
|
|
15666
|
-
var l, y, m, c, f, g, x = arguments[0], C = 1, w = arguments.length,
|
|
15667
|
-
for (typeof x == "boolean" && (
|
|
15670
|
+
var l, y, m, c, f, g, x = arguments[0], C = 1, w = arguments.length, _ = !1;
|
|
15671
|
+
for (typeof x == "boolean" && (_ = x, x = arguments[1] || {}, C = 2), (x == null || typeof x != "object" && typeof x != "function") && (x = {}); C < w; ++C)
|
|
15668
15672
|
if (l = arguments[C], l != null)
|
|
15669
15673
|
for (y in l)
|
|
15670
|
-
m = u(x, y), c = u(l, y), x !== c && (
|
|
15674
|
+
m = u(x, y), c = u(l, y), x !== c && (_ && c && (v(c) || (f = s(c))) ? (f ? (f = !1, g = m && s(m) ? m : []) : g = m && v(m) ? m : {}, h(x, { name: y, newValue: a(_, g, c) })) : typeof c < "u" && h(x, { name: y, newValue: c }));
|
|
15671
15675
|
return x;
|
|
15672
15676
|
};
|
|
15673
15677
|
},
|
|
@@ -15712,13 +15716,13 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
15712
15716
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
15713
15717
|
return k && (typeof k == "object" || typeof k == "function") ? k : H;
|
|
15714
15718
|
}
|
|
15715
|
-
function
|
|
15719
|
+
function _(H, k) {
|
|
15716
15720
|
if (typeof k != "function" && k !== null)
|
|
15717
15721
|
throw new TypeError("Super expression must either be null or a function, not " + typeof k);
|
|
15718
15722
|
H.prototype = Object.create(k && k.prototype, { constructor: { value: H, enumerable: !1, writable: !0, configurable: !0 } }), k && (Object.setPrototypeOf ? Object.setPrototypeOf(H, k) : H.__proto__ = k);
|
|
15719
15723
|
}
|
|
15720
15724
|
var L = 1, I = function(H) {
|
|
15721
|
-
|
|
15725
|
+
_(k, H);
|
|
15722
15726
|
function k() {
|
|
15723
15727
|
return C(this, k), w(this, (k.__proto__ || Object.getPrototypeOf(k)).apply(this, arguments));
|
|
15724
15728
|
}
|
|
@@ -15757,7 +15761,7 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
15757
15761
|
}(a.default.Embed);
|
|
15758
15762
|
I.scope = a.default.Scope.BLOCK_BLOT;
|
|
15759
15763
|
var Z = function(H) {
|
|
15760
|
-
|
|
15764
|
+
_(k, H);
|
|
15761
15765
|
function k(S) {
|
|
15762
15766
|
C(this, k);
|
|
15763
15767
|
var E = w(this, (k.__proto__ || Object.getPrototypeOf(k)).call(this, S));
|
|
@@ -15860,18 +15864,18 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
15860
15864
|
return X && typeof Symbol == "function" && X.constructor === Symbol && X !== Symbol.prototype ? "symbol" : typeof X;
|
|
15861
15865
|
}, p = function() {
|
|
15862
15866
|
function X(P, M) {
|
|
15863
|
-
var B = [], R = !0, j = !1,
|
|
15867
|
+
var B = [], R = !0, j = !1, A = void 0;
|
|
15864
15868
|
try {
|
|
15865
15869
|
for (var N = P[Symbol.iterator](), W; !(R = (W = N.next()).done) && (B.push(W.value), !(M && B.length === M)); R = !0)
|
|
15866
15870
|
;
|
|
15867
15871
|
} catch (Y) {
|
|
15868
|
-
j = !0,
|
|
15872
|
+
j = !0, A = Y;
|
|
15869
15873
|
} finally {
|
|
15870
15874
|
try {
|
|
15871
15875
|
!R && N.return && N.return();
|
|
15872
15876
|
} finally {
|
|
15873
15877
|
if (j)
|
|
15874
|
-
throw
|
|
15878
|
+
throw A;
|
|
15875
15879
|
}
|
|
15876
15880
|
}
|
|
15877
15881
|
return B;
|
|
@@ -15895,7 +15899,7 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
15895
15899
|
};
|
|
15896
15900
|
}();
|
|
15897
15901
|
n(50);
|
|
15898
|
-
var s = n(2), v = V(s), h = n(14), u = V(h), a = n(8), l = V(a), y = n(9), m = V(y), c = n(0), f = V(c), g = n(15), x = V(g), C = n(3), w = V(C),
|
|
15902
|
+
var s = n(2), v = V(s), h = n(14), u = V(h), a = n(8), l = V(a), y = n(9), m = V(y), c = n(0), f = V(c), g = n(15), x = V(g), C = n(3), w = V(C), _ = n(10), L = V(_), I = n(34), Z = V(I);
|
|
15899
15903
|
function V(X) {
|
|
15900
15904
|
return X && X.__esModule ? X : { default: X };
|
|
15901
15905
|
}
|
|
@@ -15927,8 +15931,8 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
15927
15931
|
value: function(M, B) {
|
|
15928
15932
|
var R = this, j = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : !1;
|
|
15929
15933
|
if (typeof M != "string") {
|
|
15930
|
-
var
|
|
15931
|
-
typeof
|
|
15934
|
+
var A = M.attrName || M.blotName;
|
|
15935
|
+
typeof A == "string" ? this.register("formats/" + A, M, B) : Object.keys(M).forEach(function(N) {
|
|
15932
15936
|
R.register(N, M[N], B);
|
|
15933
15937
|
});
|
|
15934
15938
|
} else
|
|
@@ -15944,13 +15948,13 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
15944
15948
|
this.container.classList.add("ql-container"), this.container.innerHTML = "", this.container.__quill = this, this.root = this.addContainer("ql-editor"), this.root.classList.add("ql-blank"), this.root.setAttribute("data-gramm", !1), this.scrollingContainer = this.options.scrollingContainer || this.root, this.emitter = new l.default(), this.scroll = f.default.create(this.root, {
|
|
15945
15949
|
emitter: this.emitter,
|
|
15946
15950
|
whitelist: this.options.formats
|
|
15947
|
-
}), this.editor = new u.default(this.scroll), this.selection = new x.default(this.scroll, this.emitter), this.theme = new this.options.theme(this, this.options), this.keyboard = this.theme.addModule("keyboard"), this.clipboard = this.theme.addModule("clipboard"), this.history = this.theme.addModule("history"), this.theme.init(), this.emitter.on(l.default.events.EDITOR_CHANGE, function(
|
|
15948
|
-
|
|
15949
|
-
}), this.emitter.on(l.default.events.SCROLL_UPDATE, function(
|
|
15951
|
+
}), this.editor = new u.default(this.scroll), this.selection = new x.default(this.scroll, this.emitter), this.theme = new this.options.theme(this, this.options), this.keyboard = this.theme.addModule("keyboard"), this.clipboard = this.theme.addModule("clipboard"), this.history = this.theme.addModule("history"), this.theme.init(), this.emitter.on(l.default.events.EDITOR_CHANGE, function(A) {
|
|
15952
|
+
A === l.default.events.TEXT_CHANGE && M.root.classList.toggle("ql-blank", M.editor.isBlank());
|
|
15953
|
+
}), this.emitter.on(l.default.events.SCROLL_UPDATE, function(A, N) {
|
|
15950
15954
|
var W = M.selection.lastRange, Y = W && W.length === 0 ? W.index : void 0;
|
|
15951
15955
|
D.call(M, function() {
|
|
15952
15956
|
return M.editor.update(null, N, Y);
|
|
15953
|
-
},
|
|
15957
|
+
}, A);
|
|
15954
15958
|
});
|
|
15955
15959
|
var j = this.clipboard.convert(`<div class='ql-editor' style="white-space: normal;">` + R + "<p><br></p></div>");
|
|
15956
15960
|
this.setContents(j), this.history.clear(), this.options.placeholder && this.root.setAttribute("data-placeholder", this.options.placeholder), this.options.readOnly && this.disable();
|
|
@@ -15973,7 +15977,7 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
15973
15977
|
}, {
|
|
15974
15978
|
key: "deleteText",
|
|
15975
15979
|
value: function(M, B, R) {
|
|
15976
|
-
var j = this,
|
|
15980
|
+
var j = this, A = z(M, B, R), N = p(A, 4);
|
|
15977
15981
|
return M = N[0], B = N[1], R = N[3], D.call(this, function() {
|
|
15978
15982
|
return j.editor.deleteText(M, B);
|
|
15979
15983
|
}, R, M, -1 * B);
|
|
@@ -16000,34 +16004,34 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
16000
16004
|
value: function(M, B) {
|
|
16001
16005
|
var R = this, j = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : l.default.sources.API;
|
|
16002
16006
|
return D.call(this, function() {
|
|
16003
|
-
var
|
|
16004
|
-
if (
|
|
16007
|
+
var A = R.getSelection(!0), N = new v.default();
|
|
16008
|
+
if (A == null)
|
|
16005
16009
|
return N;
|
|
16006
16010
|
if (f.default.query(M, f.default.Scope.BLOCK))
|
|
16007
|
-
N = R.editor.formatLine(
|
|
16011
|
+
N = R.editor.formatLine(A.index, A.length, H({}, M, B));
|
|
16008
16012
|
else {
|
|
16009
|
-
if (
|
|
16013
|
+
if (A.length === 0)
|
|
16010
16014
|
return R.selection.format(M, B), N;
|
|
16011
|
-
N = R.editor.formatText(
|
|
16015
|
+
N = R.editor.formatText(A.index, A.length, H({}, M, B));
|
|
16012
16016
|
}
|
|
16013
|
-
return R.setSelection(
|
|
16017
|
+
return R.setSelection(A, l.default.sources.SILENT), N;
|
|
16014
16018
|
}, j);
|
|
16015
16019
|
}
|
|
16016
16020
|
}, {
|
|
16017
16021
|
key: "formatLine",
|
|
16018
|
-
value: function(M, B, R, j,
|
|
16019
|
-
var N = this, W = void 0, Y = z(M, B, R, j,
|
|
16020
|
-
return M = J[0], B = J[1], W = J[2],
|
|
16022
|
+
value: function(M, B, R, j, A) {
|
|
16023
|
+
var N = this, W = void 0, Y = z(M, B, R, j, A), J = p(Y, 4);
|
|
16024
|
+
return M = J[0], B = J[1], W = J[2], A = J[3], D.call(this, function() {
|
|
16021
16025
|
return N.editor.formatLine(M, B, W);
|
|
16022
|
-
},
|
|
16026
|
+
}, A, M, 0);
|
|
16023
16027
|
}
|
|
16024
16028
|
}, {
|
|
16025
16029
|
key: "formatText",
|
|
16026
|
-
value: function(M, B, R, j,
|
|
16027
|
-
var N = this, W = void 0, Y = z(M, B, R, j,
|
|
16028
|
-
return M = J[0], B = J[1], W = J[2],
|
|
16030
|
+
value: function(M, B, R, j, A) {
|
|
16031
|
+
var N = this, W = void 0, Y = z(M, B, R, j, A), J = p(Y, 4);
|
|
16032
|
+
return M = J[0], B = J[1], W = J[2], A = J[3], D.call(this, function() {
|
|
16029
16033
|
return N.editor.formatText(M, B, W);
|
|
16030
|
-
},
|
|
16034
|
+
}, A, M, 0);
|
|
16031
16035
|
}
|
|
16032
16036
|
}, {
|
|
16033
16037
|
key: "getBounds",
|
|
@@ -16107,18 +16111,18 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
16107
16111
|
}, {
|
|
16108
16112
|
key: "insertEmbed",
|
|
16109
16113
|
value: function(M, B, R) {
|
|
16110
|
-
var j = this,
|
|
16114
|
+
var j = this, A = arguments.length > 3 && arguments[3] !== void 0 ? arguments[3] : X.sources.API;
|
|
16111
16115
|
return D.call(this, function() {
|
|
16112
16116
|
return j.editor.insertEmbed(M, B, R);
|
|
16113
|
-
},
|
|
16117
|
+
}, A, M);
|
|
16114
16118
|
}
|
|
16115
16119
|
}, {
|
|
16116
16120
|
key: "insertText",
|
|
16117
|
-
value: function(M, B, R, j,
|
|
16118
|
-
var N = this, W = void 0, Y = z(M, 0, R, j,
|
|
16119
|
-
return M = J[0], W = J[2],
|
|
16121
|
+
value: function(M, B, R, j, A) {
|
|
16122
|
+
var N = this, W = void 0, Y = z(M, 0, R, j, A), J = p(Y, 4);
|
|
16123
|
+
return M = J[0], W = J[2], A = J[3], D.call(this, function() {
|
|
16120
16124
|
return N.editor.insertText(M, B, W);
|
|
16121
|
-
},
|
|
16125
|
+
}, A, M, B.length);
|
|
16122
16126
|
}
|
|
16123
16127
|
}, {
|
|
16124
16128
|
key: "isEnabled",
|
|
@@ -16148,7 +16152,7 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
16148
16152
|
}, {
|
|
16149
16153
|
key: "removeFormat",
|
|
16150
16154
|
value: function(M, B, R) {
|
|
16151
|
-
var j = this,
|
|
16155
|
+
var j = this, A = z(M, B, R), N = p(A, 4);
|
|
16152
16156
|
return M = N[0], B = N[1], R = N[3], D.call(this, function() {
|
|
16153
16157
|
return j.editor.removeFormat(M, B);
|
|
16154
16158
|
}, R, M);
|
|
@@ -16164,10 +16168,10 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
16164
16168
|
var B = this, R = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : l.default.sources.API;
|
|
16165
16169
|
return D.call(this, function() {
|
|
16166
16170
|
M = new v.default(M);
|
|
16167
|
-
var j = B.getLength(),
|
|
16171
|
+
var j = B.getLength(), A = B.editor.deleteText(0, j), N = B.editor.applyDelta(M), W = N.ops[N.ops.length - 1];
|
|
16168
16172
|
W != null && typeof W.insert == "string" && W.insert[W.insert.length - 1] === `
|
|
16169
16173
|
` && (B.editor.deleteText(B.getLength() - 1, 1), N.delete(1));
|
|
16170
|
-
var Y =
|
|
16174
|
+
var Y = A.compose(N);
|
|
16171
16175
|
return Y;
|
|
16172
16176
|
}, R);
|
|
16173
16177
|
}
|
|
@@ -16177,8 +16181,8 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
16177
16181
|
if (M == null)
|
|
16178
16182
|
this.selection.setRange(null, B || X.sources.API);
|
|
16179
16183
|
else {
|
|
16180
|
-
var j = z(M, B, R),
|
|
16181
|
-
M =
|
|
16184
|
+
var j = z(M, B, R), A = p(j, 4);
|
|
16185
|
+
M = A[0], B = A[1], R = A[3], this.selection.setRange(new g.Range(M, B), R), R !== l.default.sources.SILENT && this.selection.scrollIntoView(this.scrollingContainer);
|
|
16182
16186
|
}
|
|
16183
16187
|
}
|
|
16184
16188
|
}, {
|
|
@@ -16232,34 +16236,34 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
16232
16236
|
throw new Error("Invalid theme " + P.theme + ". Did you register it?");
|
|
16233
16237
|
var M = (0, w.default)(!0, {}, P.theme.DEFAULTS);
|
|
16234
16238
|
[M, P].forEach(function(j) {
|
|
16235
|
-
j.modules = j.modules || {}, Object.keys(j.modules).forEach(function(
|
|
16236
|
-
j.modules[
|
|
16239
|
+
j.modules = j.modules || {}, Object.keys(j.modules).forEach(function(A) {
|
|
16240
|
+
j.modules[A] === !0 && (j.modules[A] = {});
|
|
16237
16241
|
});
|
|
16238
16242
|
});
|
|
16239
|
-
var B = Object.keys(M.modules).concat(Object.keys(P.modules)), R = B.reduce(function(j,
|
|
16240
|
-
var N = E.import("modules/" +
|
|
16241
|
-
return N == null ? S.error("Cannot load " +
|
|
16243
|
+
var B = Object.keys(M.modules).concat(Object.keys(P.modules)), R = B.reduce(function(j, A) {
|
|
16244
|
+
var N = E.import("modules/" + A);
|
|
16245
|
+
return N == null ? S.error("Cannot load " + A + " module. Are you sure you registered it?") : j[A] = N.DEFAULTS || {}, j;
|
|
16242
16246
|
}, {});
|
|
16243
16247
|
return P.modules != null && P.modules.toolbar && P.modules.toolbar.constructor !== Object && (P.modules.toolbar = {
|
|
16244
16248
|
container: P.modules.toolbar
|
|
16245
16249
|
}), P = (0, w.default)(!0, {}, E.DEFAULTS, { modules: R }, M, P), ["bounds", "container", "scrollingContainer"].forEach(function(j) {
|
|
16246
16250
|
typeof P[j] == "string" && (P[j] = document.querySelector(P[j]));
|
|
16247
|
-
}), P.modules = Object.keys(P.modules).reduce(function(j,
|
|
16248
|
-
return P.modules[
|
|
16251
|
+
}), P.modules = Object.keys(P.modules).reduce(function(j, A) {
|
|
16252
|
+
return P.modules[A] && (j[A] = P.modules[A]), j;
|
|
16249
16253
|
}, {}), P;
|
|
16250
16254
|
}
|
|
16251
16255
|
function D(X, P, M, B) {
|
|
16252
16256
|
if (this.options.strict && !this.isEnabled() && P === l.default.sources.USER)
|
|
16253
16257
|
return new v.default();
|
|
16254
|
-
var R = M == null ? null : this.getSelection(), j = this.editor.delta,
|
|
16255
|
-
if (R != null && (M === !0 && (M = R.index), B == null ? R = Q(R,
|
|
16256
|
-
var N, W = [l.default.events.TEXT_CHANGE,
|
|
16258
|
+
var R = M == null ? null : this.getSelection(), j = this.editor.delta, A = X();
|
|
16259
|
+
if (R != null && (M === !0 && (M = R.index), B == null ? R = Q(R, A, P) : B !== 0 && (R = Q(R, M, B, P)), this.setSelection(R, l.default.sources.SILENT)), A.length() > 0) {
|
|
16260
|
+
var N, W = [l.default.events.TEXT_CHANGE, A, j, P];
|
|
16257
16261
|
if ((N = this.emitter).emit.apply(N, [l.default.events.EDITOR_CHANGE].concat(W)), P !== l.default.sources.SILENT) {
|
|
16258
16262
|
var Y;
|
|
16259
16263
|
(Y = this.emitter).emit.apply(Y, W);
|
|
16260
16264
|
}
|
|
16261
16265
|
}
|
|
16262
|
-
return
|
|
16266
|
+
return A;
|
|
16263
16267
|
}
|
|
16264
16268
|
function z(X, P, M, B, R) {
|
|
16265
16269
|
var j = {};
|
|
@@ -16270,9 +16274,9 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
16270
16274
|
return null;
|
|
16271
16275
|
var R = void 0, j = void 0;
|
|
16272
16276
|
if (P instanceof v.default) {
|
|
16273
|
-
var
|
|
16277
|
+
var A = [X.index, X.index + X.length].map(function(J) {
|
|
16274
16278
|
return P.transformPosition(J, B !== l.default.sources.USER);
|
|
16275
|
-
}), N = p(
|
|
16279
|
+
}), N = p(A, 2);
|
|
16276
16280
|
R = N[0], j = N[1];
|
|
16277
16281
|
} else {
|
|
16278
16282
|
var W = [X.index, X.index + X.length].map(function(J) {
|
|
@@ -16309,8 +16313,8 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
16309
16313
|
} else {
|
|
16310
16314
|
if ("value" in C)
|
|
16311
16315
|
return C.value;
|
|
16312
|
-
var
|
|
16313
|
-
return
|
|
16316
|
+
var _ = C.get;
|
|
16317
|
+
return _ === void 0 ? void 0 : _.call(x);
|
|
16314
16318
|
}
|
|
16315
16319
|
}, b = n(7), s = u(b), v = n(0), h = u(v);
|
|
16316
16320
|
function u(c) {
|
|
@@ -16337,12 +16341,12 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
16337
16341
|
}
|
|
16338
16342
|
return d(f, [{
|
|
16339
16343
|
key: "formatAt",
|
|
16340
|
-
value: function(x, C, w,
|
|
16344
|
+
value: function(x, C, w, _) {
|
|
16341
16345
|
if (f.compare(this.statics.blotName, w) < 0 && h.default.query(w, h.default.Scope.BLOT)) {
|
|
16342
16346
|
var L = this.isolate(x, C);
|
|
16343
|
-
|
|
16347
|
+
_ && L.wrap(w, _);
|
|
16344
16348
|
} else
|
|
16345
|
-
p(f.prototype.__proto__ || Object.getPrototypeOf(f.prototype), "formatAt", this).call(this, x, C, w,
|
|
16349
|
+
p(f.prototype.__proto__ || Object.getPrototypeOf(f.prototype), "formatAt", this).call(this, x, C, w, _);
|
|
16346
16350
|
}
|
|
16347
16351
|
}, {
|
|
16348
16352
|
key: "optimize",
|
|
@@ -16355,8 +16359,8 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
16355
16359
|
}], [{
|
|
16356
16360
|
key: "compare",
|
|
16357
16361
|
value: function(x, C) {
|
|
16358
|
-
var w = f.order.indexOf(x),
|
|
16359
|
-
return w >= 0 ||
|
|
16362
|
+
var w = f.order.indexOf(x), _ = f.order.indexOf(C);
|
|
16363
|
+
return w >= 0 || _ >= 0 ? w - _ : x === C ? 0 : x < C ? -1 : 1;
|
|
16360
16364
|
}
|
|
16361
16365
|
}]), f;
|
|
16362
16366
|
}(h.default.Inline);
|
|
@@ -16416,8 +16420,8 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
16416
16420
|
var d = function() {
|
|
16417
16421
|
function g(x, C) {
|
|
16418
16422
|
for (var w = 0; w < C.length; w++) {
|
|
16419
|
-
var
|
|
16420
|
-
|
|
16423
|
+
var _ = C[w];
|
|
16424
|
+
_.enumerable = _.enumerable || !1, _.configurable = !0, "value" in _ && (_.writable = !0), Object.defineProperty(x, _.key, _);
|
|
16421
16425
|
}
|
|
16422
16426
|
}
|
|
16423
16427
|
return function(x, C, w) {
|
|
@@ -16425,14 +16429,14 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
16425
16429
|
};
|
|
16426
16430
|
}(), p = function g(x, C, w) {
|
|
16427
16431
|
x === null && (x = Function.prototype);
|
|
16428
|
-
var
|
|
16429
|
-
if (
|
|
16432
|
+
var _ = Object.getOwnPropertyDescriptor(x, C);
|
|
16433
|
+
if (_ === void 0) {
|
|
16430
16434
|
var L = Object.getPrototypeOf(x);
|
|
16431
16435
|
return L === null ? void 0 : g(L, C, w);
|
|
16432
16436
|
} else {
|
|
16433
|
-
if ("value" in
|
|
16434
|
-
return
|
|
16435
|
-
var I =
|
|
16437
|
+
if ("value" in _)
|
|
16438
|
+
return _.value;
|
|
16439
|
+
var I = _.get;
|
|
16436
16440
|
return I === void 0 ? void 0 : I.call(w);
|
|
16437
16441
|
}
|
|
16438
16442
|
}, b = n(54), s = u(b), v = n(10), h = u(v);
|
|
@@ -16458,10 +16462,10 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
16458
16462
|
document.addEventListener(g, function() {
|
|
16459
16463
|
for (var x = arguments.length, C = Array(x), w = 0; w < x; w++)
|
|
16460
16464
|
C[w] = arguments[w];
|
|
16461
|
-
[].slice.call(document.querySelectorAll(".ql-container")).forEach(function(
|
|
16462
|
-
if (
|
|
16465
|
+
[].slice.call(document.querySelectorAll(".ql-container")).forEach(function(_) {
|
|
16466
|
+
if (_.__quill && _.__quill.emitter) {
|
|
16463
16467
|
var L;
|
|
16464
|
-
(L =
|
|
16468
|
+
(L = _.__quill.emitter).handleDOM.apply(L, C);
|
|
16465
16469
|
}
|
|
16466
16470
|
});
|
|
16467
16471
|
});
|
|
@@ -16481,7 +16485,7 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
16481
16485
|
}, {
|
|
16482
16486
|
key: "handleDOM",
|
|
16483
16487
|
value: function(w) {
|
|
16484
|
-
for (var
|
|
16488
|
+
for (var _ = arguments.length, L = Array(_ > 1 ? _ - 1 : 0), I = 1; I < _; I++)
|
|
16485
16489
|
L[I - 1] = arguments[I];
|
|
16486
16490
|
(this.listeners[w.type] || []).forEach(function(Z) {
|
|
16487
16491
|
var V = Z.node, H = Z.handler;
|
|
@@ -16490,8 +16494,8 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
16490
16494
|
}
|
|
16491
16495
|
}, {
|
|
16492
16496
|
key: "listenDOM",
|
|
16493
|
-
value: function(w,
|
|
16494
|
-
this.listeners[w] || (this.listeners[w] = []), this.listeners[w].push({ node:
|
|
16497
|
+
value: function(w, _, L) {
|
|
16498
|
+
this.listeners[w] || (this.listeners[w] = []), this.listeners[w].push({ node: _, handler: L });
|
|
16495
16499
|
}
|
|
16496
16500
|
}]), x;
|
|
16497
16501
|
}(s.default);
|
|
@@ -16691,14 +16695,14 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
16691
16695
|
throw new TypeError("Super expression must either be null or a function, not " + typeof Z);
|
|
16692
16696
|
I.prototype = Object.create(Z && Z.prototype, { constructor: { value: I, enumerable: !1, writable: !0, configurable: !0 } }), Z && (Object.setPrototypeOf ? Object.setPrototypeOf(I, Z) : I.__proto__ = Z);
|
|
16693
16697
|
}
|
|
16694
|
-
var
|
|
16698
|
+
var _ = function(I) {
|
|
16695
16699
|
w(Z, I);
|
|
16696
16700
|
function Z() {
|
|
16697
16701
|
return x(this, Z), C(this, (Z.__proto__ || Object.getPrototypeOf(Z)).apply(this, arguments));
|
|
16698
16702
|
}
|
|
16699
16703
|
return Z;
|
|
16700
16704
|
}(m.default);
|
|
16701
|
-
|
|
16705
|
+
_.blotName = "code", _.tagName = "CODE";
|
|
16702
16706
|
var L = function(I) {
|
|
16703
16707
|
w(Z, I);
|
|
16704
16708
|
function Z() {
|
|
@@ -16790,7 +16794,7 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
16790
16794
|
}
|
|
16791
16795
|
}]), Z;
|
|
16792
16796
|
}(l.default);
|
|
16793
|
-
L.blotName = "code-block", L.tagName = "PRE", L.TAB = " ", r.Code =
|
|
16797
|
+
L.blotName = "code-block", L.tagName = "PRE", L.TAB = " ", r.Code = _, r.default = L;
|
|
16794
16798
|
},
|
|
16795
16799
|
/* 14 */
|
|
16796
16800
|
/***/
|
|
@@ -16804,18 +16808,18 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
16804
16808
|
return X && typeof Symbol == "function" && X.constructor === Symbol && X !== Symbol.prototype ? "symbol" : typeof X;
|
|
16805
16809
|
}, p = function() {
|
|
16806
16810
|
function X(P, M) {
|
|
16807
|
-
var B = [], R = !0, j = !1,
|
|
16811
|
+
var B = [], R = !0, j = !1, A = void 0;
|
|
16808
16812
|
try {
|
|
16809
16813
|
for (var N = P[Symbol.iterator](), W; !(R = (W = N.next()).done) && (B.push(W.value), !(M && B.length === M)); R = !0)
|
|
16810
16814
|
;
|
|
16811
16815
|
} catch (Y) {
|
|
16812
|
-
j = !0,
|
|
16816
|
+
j = !0, A = Y;
|
|
16813
16817
|
} finally {
|
|
16814
16818
|
try {
|
|
16815
16819
|
!R && N.return && N.return();
|
|
16816
16820
|
} finally {
|
|
16817
16821
|
if (j)
|
|
16818
|
-
throw
|
|
16822
|
+
throw A;
|
|
16819
16823
|
}
|
|
16820
16824
|
}
|
|
16821
16825
|
return B;
|
|
@@ -16837,7 +16841,7 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
16837
16841
|
return function(P, M, B) {
|
|
16838
16842
|
return M && X(P.prototype, M), B && X(P, B), P;
|
|
16839
16843
|
};
|
|
16840
|
-
}(), s = n(2), v = k(s), h = n(20), u = k(h), a = n(0), l = k(a), y = n(13), m = k(y), c = n(24), f = k(c), g = n(4), x = k(g), C = n(16), w = k(C),
|
|
16844
|
+
}(), s = n(2), v = k(s), h = n(20), u = k(h), a = n(0), l = k(a), y = n(13), m = k(y), c = n(24), f = k(c), g = n(4), x = k(g), C = n(16), w = k(C), _ = n(21), L = k(_), I = n(11), Z = k(I), V = n(3), H = k(V);
|
|
16841
16845
|
function k(X) {
|
|
16842
16846
|
return X && X.__esModule ? X : { default: X };
|
|
16843
16847
|
}
|
|
@@ -16858,15 +16862,15 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
16858
16862
|
var B = this, R = !1;
|
|
16859
16863
|
this.scroll.update();
|
|
16860
16864
|
var j = this.scroll.length();
|
|
16861
|
-
return this.scroll.batchStart(), M = Q(M), M.reduce(function(
|
|
16865
|
+
return this.scroll.batchStart(), M = Q(M), M.reduce(function(A, N) {
|
|
16862
16866
|
var W = N.retain || N.delete || N.insert.length || 1, Y = N.attributes || {};
|
|
16863
16867
|
if (N.insert != null) {
|
|
16864
16868
|
if (typeof N.insert == "string") {
|
|
16865
16869
|
var J = N.insert;
|
|
16866
16870
|
J.endsWith(`
|
|
16867
|
-
`) && R && (R = !1, J = J.slice(0, -1)),
|
|
16868
|
-
`) && (R = !0), B.scroll.insertAt(
|
|
16869
|
-
var e1 = B.scroll.line(
|
|
16871
|
+
`) && R && (R = !1, J = J.slice(0, -1)), A >= j && !J.endsWith(`
|
|
16872
|
+
`) && (R = !0), B.scroll.insertAt(A, J);
|
|
16873
|
+
var e1 = B.scroll.line(A), s1 = p(e1, 2), f1 = s1[0], p1 = s1[1], m1 = (0, H.default)({}, (0, g.bubbleFormats)(f1));
|
|
16870
16874
|
if (f1 instanceof x.default) {
|
|
16871
16875
|
var U = f1.descendant(l.default.Leaf, p1), o1 = p(U, 1), C1 = o1[0];
|
|
16872
16876
|
m1 = (0, H.default)(m1, (0, g.bubbleFormats)(C1));
|
|
@@ -16875,16 +16879,16 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
16875
16879
|
} else if (d(N.insert) === "object") {
|
|
16876
16880
|
var q = Object.keys(N.insert)[0];
|
|
16877
16881
|
if (q == null)
|
|
16878
|
-
return
|
|
16879
|
-
B.scroll.insertAt(
|
|
16882
|
+
return A;
|
|
16883
|
+
B.scroll.insertAt(A, q, N.insert[q]);
|
|
16880
16884
|
}
|
|
16881
16885
|
j += W;
|
|
16882
16886
|
}
|
|
16883
16887
|
return Object.keys(Y).forEach(function($) {
|
|
16884
|
-
B.scroll.formatAt(
|
|
16885
|
-
}),
|
|
16886
|
-
}, 0), M.reduce(function(
|
|
16887
|
-
return typeof N.delete == "number" ? (B.scroll.deleteAt(
|
|
16888
|
+
B.scroll.formatAt(A, W, $, Y[$]);
|
|
16889
|
+
}), A + W;
|
|
16890
|
+
}, 0), M.reduce(function(A, N) {
|
|
16891
|
+
return typeof N.delete == "number" ? (B.scroll.deleteAt(A, N.delete), A) : A + (N.retain || N.insert.length || 1);
|
|
16888
16892
|
}, 0), this.scroll.batchEnd(), this.update(M);
|
|
16889
16893
|
}
|
|
16890
16894
|
}, {
|
|
@@ -16896,16 +16900,16 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
16896
16900
|
key: "formatLine",
|
|
16897
16901
|
value: function(M, B) {
|
|
16898
16902
|
var R = this, j = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : {};
|
|
16899
|
-
return this.scroll.update(), Object.keys(j).forEach(function(
|
|
16900
|
-
if (!(R.scroll.whitelist != null && !R.scroll.whitelist[
|
|
16903
|
+
return this.scroll.update(), Object.keys(j).forEach(function(A) {
|
|
16904
|
+
if (!(R.scroll.whitelist != null && !R.scroll.whitelist[A])) {
|
|
16901
16905
|
var N = R.scroll.lines(M, Math.max(B, 1)), W = B;
|
|
16902
16906
|
N.forEach(function(Y) {
|
|
16903
16907
|
var J = Y.length();
|
|
16904
16908
|
if (!(Y instanceof m.default))
|
|
16905
|
-
Y.format(
|
|
16909
|
+
Y.format(A, j[A]);
|
|
16906
16910
|
else {
|
|
16907
16911
|
var e1 = M - Y.offset(R.scroll), s1 = Y.newlineIndex(e1 + W) - e1 + 1;
|
|
16908
|
-
Y.formatAt(e1, s1,
|
|
16912
|
+
Y.formatAt(e1, s1, A, j[A]);
|
|
16909
16913
|
}
|
|
16910
16914
|
W -= J;
|
|
16911
16915
|
});
|
|
@@ -16916,8 +16920,8 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
16916
16920
|
key: "formatText",
|
|
16917
16921
|
value: function(M, B) {
|
|
16918
16922
|
var R = this, j = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : {};
|
|
16919
|
-
return Object.keys(j).forEach(function(
|
|
16920
|
-
R.scroll.formatAt(M, B,
|
|
16923
|
+
return Object.keys(j).forEach(function(A) {
|
|
16924
|
+
R.scroll.formatAt(M, B, A, j[A]);
|
|
16921
16925
|
}), this.update(new v.default().retain(M).retain(B, (0, L.default)(j)));
|
|
16922
16926
|
}
|
|
16923
16927
|
}, {
|
|
@@ -16940,7 +16944,7 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
16940
16944
|
var W = p(N, 1), Y = W[0];
|
|
16941
16945
|
Y instanceof x.default ? R.push(Y) : Y instanceof l.default.Leaf && j.push(Y);
|
|
16942
16946
|
}) : (R = this.scroll.lines(M, B), j = this.scroll.descendants(l.default.Leaf, M, B));
|
|
16943
|
-
var
|
|
16947
|
+
var A = [R, j].map(function(N) {
|
|
16944
16948
|
if (N.length === 0)
|
|
16945
16949
|
return {};
|
|
16946
16950
|
for (var W = (0, g.bubbleFormats)(N.shift()); Object.keys(W).length > 0; ) {
|
|
@@ -16951,7 +16955,7 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
16951
16955
|
}
|
|
16952
16956
|
return W;
|
|
16953
16957
|
});
|
|
16954
|
-
return H.default.apply(H.default,
|
|
16958
|
+
return H.default.apply(H.default, A);
|
|
16955
16959
|
}
|
|
16956
16960
|
}, {
|
|
16957
16961
|
key: "getText",
|
|
@@ -16973,8 +16977,8 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
16973
16977
|
var R = this, j = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : {};
|
|
16974
16978
|
return B = B.replace(/\r\n/g, `
|
|
16975
16979
|
`).replace(/\r/g, `
|
|
16976
|
-
`), this.scroll.insertAt(M, B), Object.keys(j).forEach(function(
|
|
16977
|
-
R.scroll.formatAt(M, B.length,
|
|
16980
|
+
`), this.scroll.insertAt(M, B), Object.keys(j).forEach(function(A) {
|
|
16981
|
+
R.scroll.formatAt(M, B.length, A, j[A]);
|
|
16978
16982
|
}), this.update(new v.default().retain(M).insert(B, (0, L.default)(j)));
|
|
16979
16983
|
}
|
|
16980
16984
|
}, {
|
|
@@ -16990,7 +16994,7 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
16990
16994
|
}, {
|
|
16991
16995
|
key: "removeFormat",
|
|
16992
16996
|
value: function(M, B) {
|
|
16993
|
-
var R = this.getText(M, B), j = this.scroll.line(M + B),
|
|
16997
|
+
var R = this.getText(M, B), j = this.scroll.line(M + B), A = p(j, 2), N = A[0], W = A[1], Y = 0, J = new v.default();
|
|
16994
16998
|
N != null && (N instanceof m.default ? Y = N.newlineIndex(W) - W + 1 : Y = N.length() - W, J = N.delta().slice(W, W + Y - 1).insert(`
|
|
16995
16999
|
`));
|
|
16996
17000
|
var e1 = this.getContents(M, B + Y), s1 = e1.diff(new v.default().insert(R).concat(J)), f1 = new v.default().retain(M).concat(s1);
|
|
@@ -17001,7 +17005,7 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
17001
17005
|
value: function(M) {
|
|
17002
17006
|
var B = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : [], R = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : void 0, j = this.delta;
|
|
17003
17007
|
if (B.length === 1 && B[0].type === "characterData" && B[0].target.data.match(F) && l.default.find(B[0].target)) {
|
|
17004
|
-
var
|
|
17008
|
+
var A = l.default.find(B[0].target), N = (0, g.bubbleFormats)(A), W = A.offset(this.scroll), Y = B[0].oldValue.replace(f.default.CONTENTS, ""), J = new v.default().insert(Y), e1 = new v.default().insert(A.value()), s1 = new v.default().retain(W).concat(J.diff(e1, R));
|
|
17005
17009
|
M = s1.reduce(function(f1, p1) {
|
|
17006
17010
|
return p1.insert ? f1.insert(p1.insert, N) : f1.push(p1);
|
|
17007
17011
|
}, new v.default()), this.delta = j.compose(M);
|
|
@@ -17093,7 +17097,7 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
17093
17097
|
var C = (0, c.default)("quill:selection"), w = function I(Z) {
|
|
17094
17098
|
var V = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : 0;
|
|
17095
17099
|
x(this, I), this.index = Z, this.length = V;
|
|
17096
|
-
},
|
|
17100
|
+
}, _ = function() {
|
|
17097
17101
|
function I(Z, V) {
|
|
17098
17102
|
var H = this;
|
|
17099
17103
|
x(this, I), this.emitter = V, this.scroll = Z, this.composing = !1, this.mouseDown = !1, this.root = this.scroll.domNode, this.cursor = s.default.create("cursor", this), this.lastRange = this.savedRange = new w(0, 0), this.handleComposition(), this.handleDragging(), this.emitter.listenDOM("selectionchange", document, function() {
|
|
@@ -17190,12 +17194,12 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
17190
17194
|
var R = D.position(z, !0), j = d(R, 2);
|
|
17191
17195
|
return S = j[0], z = j[1], P.setEnd(S, z), P.getBoundingClientRect();
|
|
17192
17196
|
} else {
|
|
17193
|
-
var
|
|
17194
|
-
return S instanceof Text ? (z < S.data.length ? (P.setStart(S, z), P.setEnd(S, z + 1)) : (P.setStart(S, z - 1), P.setEnd(S, z),
|
|
17197
|
+
var A = "left", N = void 0;
|
|
17198
|
+
return S instanceof Text ? (z < S.data.length ? (P.setStart(S, z), P.setEnd(S, z + 1)) : (P.setStart(S, z - 1), P.setEnd(S, z), A = "right"), N = P.getBoundingClientRect()) : (N = D.domNode.getBoundingClientRect(), z > 0 && (A = "right")), {
|
|
17195
17199
|
bottom: N.top + N.height,
|
|
17196
17200
|
height: N.height,
|
|
17197
|
-
left: N[
|
|
17198
|
-
right: N[
|
|
17201
|
+
left: N[A],
|
|
17202
|
+
right: N[A],
|
|
17199
17203
|
top: N.top,
|
|
17200
17204
|
width: 0
|
|
17201
17205
|
};
|
|
@@ -17342,7 +17346,7 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
17342
17346
|
}
|
|
17343
17347
|
return Z instanceof Text && (Z = Z.parentNode), I.contains(Z);
|
|
17344
17348
|
}
|
|
17345
|
-
r.Range = w, r.default =
|
|
17349
|
+
r.Range = w, r.default = _;
|
|
17346
17350
|
},
|
|
17347
17351
|
/* 16 */
|
|
17348
17352
|
/***/
|
|
@@ -17772,7 +17776,7 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
17772
17776
|
}
|
|
17773
17777
|
function v(m, c, f, g, x) {
|
|
17774
17778
|
typeof c == "object" && (f = c.depth, g = c.prototype, x = c.includeNonEnumerable, c = c.circular);
|
|
17775
|
-
var C = [], w = [],
|
|
17779
|
+
var C = [], w = [], _ = typeof Buffer < "u";
|
|
17776
17780
|
typeof c > "u" && (c = !0), typeof f > "u" && (f = 1 / 0);
|
|
17777
17781
|
function L(I, Z) {
|
|
17778
17782
|
if (I === null)
|
|
@@ -17801,7 +17805,7 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
17801
17805
|
else if (v.__isDate(I))
|
|
17802
17806
|
V = new Date(I.getTime());
|
|
17803
17807
|
else {
|
|
17804
|
-
if (
|
|
17808
|
+
if (_ && Buffer.isBuffer(I))
|
|
17805
17809
|
return Buffer.allocUnsafe ? V = Buffer.allocUnsafe(I.length) : V = new Buffer(I.length), I.copy(V), V;
|
|
17806
17810
|
d(I, Error) ? V = Object.create(I) : typeof g > "u" ? (H = Object.getPrototypeOf(I), V = Object.create(H)) : (V = Object.create(g), H = g);
|
|
17807
17811
|
}
|
|
@@ -17932,7 +17936,7 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
17932
17936
|
if (!(V instanceof H))
|
|
17933
17937
|
throw new TypeError("Cannot call a class as a function");
|
|
17934
17938
|
}
|
|
17935
|
-
function
|
|
17939
|
+
function _(V, H) {
|
|
17936
17940
|
if (!V)
|
|
17937
17941
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
17938
17942
|
return H && (typeof H == "object" || typeof H == "function") ? H : V;
|
|
@@ -17949,7 +17953,7 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
17949
17953
|
L(H, V);
|
|
17950
17954
|
function H(k, S) {
|
|
17951
17955
|
w(this, H);
|
|
17952
|
-
var E =
|
|
17956
|
+
var E = _(this, (H.__proto__ || Object.getPrototypeOf(H)).call(this, k));
|
|
17953
17957
|
return E.emitter = S.emitter, Array.isArray(S.whitelist) && (E.whitelist = S.whitelist.reduce(function(F, D) {
|
|
17954
17958
|
return F[D] = !0, F;
|
|
17955
17959
|
}, {})), E.domNode.addEventListener("DOMNodeInserted", function() {
|
|
@@ -18116,7 +18120,7 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
18116
18120
|
return function(W, Y, J) {
|
|
18117
18121
|
return Y && N(W.prototype, Y), J && N(W, J), W;
|
|
18118
18122
|
};
|
|
18119
|
-
}(), s = n(21), v = V(s), h = n(11), u = V(h), a = n(3), l = V(a), y = n(2), m = V(y), c = n(20), f = V(c), g = n(0), x = V(g), C = n(5), w = V(C),
|
|
18123
|
+
}(), s = n(21), v = V(s), h = n(11), u = V(h), a = n(3), l = V(a), y = n(2), m = V(y), c = n(20), f = V(c), g = n(0), x = V(g), C = n(5), w = V(C), _ = n(10), L = V(_), I = n(9), Z = V(I);
|
|
18120
18124
|
function V(N) {
|
|
18121
18125
|
return N && N.__esModule ? N : { default: N };
|
|
18122
18126
|
}
|
|
@@ -18141,7 +18145,7 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
18141
18145
|
E(W, N), b(W, null, [{
|
|
18142
18146
|
key: "match",
|
|
18143
18147
|
value: function(J, e1) {
|
|
18144
|
-
return e1 =
|
|
18148
|
+
return e1 = A(e1), ["altKey", "ctrlKey", "metaKey", "shiftKey"].some(function(s1) {
|
|
18145
18149
|
return !!e1[s1] !== J[s1] && e1[s1] !== null;
|
|
18146
18150
|
}) ? !1 : e1.key === (J.which || J.keyCode);
|
|
18147
18151
|
}
|
|
@@ -18157,7 +18161,7 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
18157
18161
|
return b(W, [{
|
|
18158
18162
|
key: "addBinding",
|
|
18159
18163
|
value: function(J) {
|
|
18160
|
-
var e1 = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, s1 = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : {}, f1 =
|
|
18164
|
+
var e1 = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, s1 = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : {}, f1 = A(J);
|
|
18161
18165
|
if (f1 == null || f1.key == null)
|
|
18162
18166
|
return F.warn("Attempted to add invalid keyboard binding", f1);
|
|
18163
18167
|
typeof e1 == "function" && (e1 = { handler: e1 }), typeof s1 == "function" && (s1 = { handler: s1 }), f1 = (0, l.default)(f1, e1, s1), this.bindings[f1.key] = this.bindings[f1.key] || [], this.bindings[f1.key].push(f1);
|
|
@@ -18434,9 +18438,9 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
18434
18438
|
}
|
|
18435
18439
|
};
|
|
18436
18440
|
}
|
|
18437
|
-
function
|
|
18441
|
+
function A(N) {
|
|
18438
18442
|
if (typeof N == "string" || typeof N == "number")
|
|
18439
|
-
return
|
|
18443
|
+
return A({ key: N });
|
|
18440
18444
|
if ((typeof N > "u" ? "undefined" : d(N)) === "object" && (N = (0, v.default)(N, !1)), typeof N.key == "string")
|
|
18441
18445
|
if (z.keys[N.key.toUpperCase()] != null)
|
|
18442
18446
|
N.key = z.keys[N.key.toUpperCase()];
|
|
@@ -18456,17 +18460,17 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
18456
18460
|
});
|
|
18457
18461
|
var d = function() {
|
|
18458
18462
|
function f(g, x) {
|
|
18459
|
-
var C = [], w = !0,
|
|
18463
|
+
var C = [], w = !0, _ = !1, L = void 0;
|
|
18460
18464
|
try {
|
|
18461
18465
|
for (var I = g[Symbol.iterator](), Z; !(w = (Z = I.next()).done) && (C.push(Z.value), !(x && C.length === x)); w = !0)
|
|
18462
18466
|
;
|
|
18463
18467
|
} catch (V) {
|
|
18464
|
-
|
|
18468
|
+
_ = !0, L = V;
|
|
18465
18469
|
} finally {
|
|
18466
18470
|
try {
|
|
18467
18471
|
!w && I.return && I.return();
|
|
18468
18472
|
} finally {
|
|
18469
|
-
if (
|
|
18473
|
+
if (_)
|
|
18470
18474
|
throw L;
|
|
18471
18475
|
}
|
|
18472
18476
|
}
|
|
@@ -18483,8 +18487,8 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
18483
18487
|
g === null && (g = Function.prototype);
|
|
18484
18488
|
var w = Object.getOwnPropertyDescriptor(g, x);
|
|
18485
18489
|
if (w === void 0) {
|
|
18486
|
-
var
|
|
18487
|
-
return
|
|
18490
|
+
var _ = Object.getPrototypeOf(g);
|
|
18491
|
+
return _ === null ? void 0 : f(_, x, C);
|
|
18488
18492
|
} else {
|
|
18489
18493
|
if ("value" in w)
|
|
18490
18494
|
return w.value;
|
|
@@ -18540,9 +18544,9 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
18540
18544
|
value: function(C, w) {
|
|
18541
18545
|
if (this._length !== 0)
|
|
18542
18546
|
return p(g.prototype.__proto__ || Object.getPrototypeOf(g.prototype), "format", this).call(this, C, w);
|
|
18543
|
-
for (var
|
|
18544
|
-
L +=
|
|
18545
|
-
|
|
18547
|
+
for (var _ = this, L = 0; _ != null && _.statics.scope !== v.default.Scope.BLOCK_BLOT; )
|
|
18548
|
+
L += _.offset(_.parent), _ = _.parent;
|
|
18549
|
+
_ != null && (this._length = g.CONTENTS.length, _.optimize(), _.formatAt(L, g.CONTENTS.length, C, w), this._length = 0);
|
|
18546
18550
|
}
|
|
18547
18551
|
}, {
|
|
18548
18552
|
key: "index",
|
|
@@ -18568,25 +18572,25 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
18568
18572
|
key: "restore",
|
|
18569
18573
|
value: function() {
|
|
18570
18574
|
if (!(this.selection.composing || this.parent == null)) {
|
|
18571
|
-
var C = this.textNode, w = this.selection.getNativeRange(),
|
|
18575
|
+
var C = this.textNode, w = this.selection.getNativeRange(), _ = void 0, L = void 0, I = void 0;
|
|
18572
18576
|
if (w != null && w.start.node === C && w.end.node === C) {
|
|
18573
18577
|
var Z = [C, w.start.offset, w.end.offset];
|
|
18574
|
-
|
|
18578
|
+
_ = Z[0], L = Z[1], I = Z[2];
|
|
18575
18579
|
}
|
|
18576
18580
|
for (; this.domNode.lastChild != null && this.domNode.lastChild !== this.textNode; )
|
|
18577
18581
|
this.domNode.parentNode.insertBefore(this.domNode.lastChild, this.domNode);
|
|
18578
18582
|
if (this.textNode.data !== g.CONTENTS) {
|
|
18579
18583
|
var V = this.textNode.data.split(g.CONTENTS).join("");
|
|
18580
|
-
this.next instanceof u.default ? (
|
|
18584
|
+
this.next instanceof u.default ? (_ = this.next.domNode, this.next.insertAt(0, V), this.textNode.data = g.CONTENTS) : (this.textNode.data = V, this.parent.insertBefore(v.default.create(this.textNode), this), this.textNode = document.createTextNode(g.CONTENTS), this.domNode.appendChild(this.textNode));
|
|
18581
18585
|
}
|
|
18582
18586
|
if (this.remove(), L != null) {
|
|
18583
18587
|
var H = [L, I].map(function(S) {
|
|
18584
|
-
return Math.max(0, Math.min(
|
|
18588
|
+
return Math.max(0, Math.min(_.data.length, S - 1));
|
|
18585
18589
|
}), k = d(H, 2);
|
|
18586
18590
|
return L = k[0], I = k[1], {
|
|
18587
|
-
startNode:
|
|
18591
|
+
startNode: _,
|
|
18588
18592
|
startOffset: L,
|
|
18589
|
-
endNode:
|
|
18593
|
+
endNode: _,
|
|
18590
18594
|
endOffset: I
|
|
18591
18595
|
};
|
|
18592
18596
|
}
|
|
@@ -18595,9 +18599,9 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
18595
18599
|
}, {
|
|
18596
18600
|
key: "update",
|
|
18597
18601
|
value: function(C, w) {
|
|
18598
|
-
var
|
|
18602
|
+
var _ = this;
|
|
18599
18603
|
if (C.some(function(I) {
|
|
18600
|
-
return I.type === "characterData" && I.target ===
|
|
18604
|
+
return I.type === "characterData" && I.target === _.textNode;
|
|
18601
18605
|
})) {
|
|
18602
18606
|
var L = this.restore();
|
|
18603
18607
|
L && (w.range = L);
|
|
@@ -18670,8 +18674,8 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
18670
18674
|
} else {
|
|
18671
18675
|
if ("value" in C)
|
|
18672
18676
|
return C.value;
|
|
18673
|
-
var
|
|
18674
|
-
return
|
|
18677
|
+
var _ = C.get;
|
|
18678
|
+
return _ === void 0 ? void 0 : _.call(x);
|
|
18675
18679
|
}
|
|
18676
18680
|
}, b = n(0), s = v(b);
|
|
18677
18681
|
function v(c) {
|
|
@@ -18939,7 +18943,7 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
18939
18943
|
Object.defineProperty(r, "__esModule", {
|
|
18940
18944
|
value: !0
|
|
18941
18945
|
});
|
|
18942
|
-
var d = n(0), p = F(d), b = n(5), s = F(b), v = n(4), h = F(v), u = n(16), a = F(u), l = n(25), y = F(l), m = n(24), c = F(m), f = n(35), g = F(f), x = n(6), C = F(x), w = n(22),
|
|
18946
|
+
var d = n(0), p = F(d), b = n(5), s = F(b), v = n(4), h = F(v), u = n(16), a = F(u), l = n(25), y = F(l), m = n(24), c = F(m), f = n(35), g = F(f), x = n(6), C = F(x), w = n(22), _ = F(w), L = n(7), I = F(L), Z = n(55), V = F(Z), H = n(42), k = F(H), S = n(23), E = F(S);
|
|
18943
18947
|
function F(D) {
|
|
18944
18948
|
return D && D.__esModule ? D : { default: D };
|
|
18945
18949
|
}
|
|
@@ -18951,12 +18955,12 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
18951
18955
|
"blots/cursor": c.default,
|
|
18952
18956
|
"blots/embed": g.default,
|
|
18953
18957
|
"blots/inline": C.default,
|
|
18954
|
-
"blots/scroll":
|
|
18958
|
+
"blots/scroll": _.default,
|
|
18955
18959
|
"blots/text": I.default,
|
|
18956
18960
|
"modules/clipboard": V.default,
|
|
18957
18961
|
"modules/history": k.default,
|
|
18958
18962
|
"modules/keyboard": E.default
|
|
18959
|
-
}), p.default.register(h.default, a.default, c.default, C.default,
|
|
18963
|
+
}), p.default.register(h.default, a.default, c.default, C.default, _.default, I.default), r.default = s.default;
|
|
18960
18964
|
},
|
|
18961
18965
|
/* 30 */
|
|
18962
18966
|
/***/
|
|
@@ -19242,8 +19246,8 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
19242
19246
|
g === null && (g = Function.prototype);
|
|
19243
19247
|
var w = Object.getOwnPropertyDescriptor(g, x);
|
|
19244
19248
|
if (w === void 0) {
|
|
19245
|
-
var
|
|
19246
|
-
return
|
|
19249
|
+
var _ = Object.getPrototypeOf(g);
|
|
19250
|
+
return _ === null ? void 0 : f(_, x, C);
|
|
19247
19251
|
} else {
|
|
19248
19252
|
if ("value" in w)
|
|
19249
19253
|
return w.value;
|
|
@@ -19285,7 +19289,7 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
19285
19289
|
}, {
|
|
19286
19290
|
key: "restore",
|
|
19287
19291
|
value: function(C) {
|
|
19288
|
-
var w = void 0,
|
|
19292
|
+
var w = void 0, _ = void 0, L = C.data.split(m).join("");
|
|
19289
19293
|
if (C === this.leftGuard)
|
|
19290
19294
|
if (this.prev instanceof h.default) {
|
|
19291
19295
|
var I = this.prev.length();
|
|
@@ -19294,16 +19298,16 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
19294
19298
|
startOffset: I + L.length
|
|
19295
19299
|
};
|
|
19296
19300
|
} else
|
|
19297
|
-
|
|
19298
|
-
startNode:
|
|
19301
|
+
_ = document.createTextNode(L), this.parent.insertBefore(s.default.create(_), this), w = {
|
|
19302
|
+
startNode: _,
|
|
19299
19303
|
startOffset: L.length
|
|
19300
19304
|
};
|
|
19301
19305
|
else
|
|
19302
19306
|
C === this.rightGuard && (this.next instanceof h.default ? (this.next.insertAt(0, L), w = {
|
|
19303
19307
|
startNode: this.next.domNode,
|
|
19304
19308
|
startOffset: L.length
|
|
19305
|
-
}) : (
|
|
19306
|
-
startNode:
|
|
19309
|
+
}) : (_ = document.createTextNode(L), this.parent.insertBefore(s.default.create(_), this.next), w = {
|
|
19310
|
+
startNode: _,
|
|
19307
19311
|
startOffset: L.length
|
|
19308
19312
|
}));
|
|
19309
19313
|
return C.data = m, w;
|
|
@@ -19311,10 +19315,10 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
19311
19315
|
}, {
|
|
19312
19316
|
key: "update",
|
|
19313
19317
|
value: function(C, w) {
|
|
19314
|
-
var
|
|
19318
|
+
var _ = this;
|
|
19315
19319
|
C.forEach(function(L) {
|
|
19316
|
-
if (L.type === "characterData" && (L.target ===
|
|
19317
|
-
var I =
|
|
19320
|
+
if (L.type === "characterData" && (L.target === _.leftGuard || L.target === _.rightGuard)) {
|
|
19321
|
+
var I = _.restore(L.target);
|
|
19318
19322
|
I && (w.range = I);
|
|
19319
19323
|
}
|
|
19320
19324
|
});
|
|
@@ -19392,8 +19396,8 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
19392
19396
|
g === null && (g = Function.prototype);
|
|
19393
19397
|
var w = Object.getOwnPropertyDescriptor(g, x);
|
|
19394
19398
|
if (w === void 0) {
|
|
19395
|
-
var
|
|
19396
|
-
return
|
|
19399
|
+
var _ = Object.getPrototypeOf(g);
|
|
19400
|
+
return _ === null ? void 0 : f(_, x, C);
|
|
19397
19401
|
} else {
|
|
19398
19402
|
if ("value" in w)
|
|
19399
19403
|
return w.value;
|
|
@@ -19515,13 +19519,13 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
19515
19519
|
}), r.getLastChangeIndex = r.default = void 0;
|
|
19516
19520
|
var d = function() {
|
|
19517
19521
|
function x(C, w) {
|
|
19518
|
-
for (var
|
|
19519
|
-
var L = w[
|
|
19522
|
+
for (var _ = 0; _ < w.length; _++) {
|
|
19523
|
+
var L = w[_];
|
|
19520
19524
|
L.enumerable = L.enumerable || !1, L.configurable = !0, "value" in L && (L.writable = !0), Object.defineProperty(C, L.key, L);
|
|
19521
19525
|
}
|
|
19522
19526
|
}
|
|
19523
|
-
return function(C, w,
|
|
19524
|
-
return w && x(C.prototype, w),
|
|
19527
|
+
return function(C, w, _) {
|
|
19528
|
+
return w && x(C.prototype, w), _ && x(C, _), C;
|
|
19525
19529
|
};
|
|
19526
19530
|
}(), p = n(0), b = a(p), s = n(5), v = a(s), h = n(9), u = a(h);
|
|
19527
19531
|
function a(x) {
|
|
@@ -19543,20 +19547,20 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
19543
19547
|
}
|
|
19544
19548
|
var c = function(x) {
|
|
19545
19549
|
m(C, x);
|
|
19546
|
-
function C(w,
|
|
19550
|
+
function C(w, _) {
|
|
19547
19551
|
l(this, C);
|
|
19548
|
-
var L = y(this, (C.__proto__ || Object.getPrototypeOf(C)).call(this, w,
|
|
19552
|
+
var L = y(this, (C.__proto__ || Object.getPrototypeOf(C)).call(this, w, _));
|
|
19549
19553
|
return L.lastRecorded = 0, L.ignoreChange = !1, L.clear(), L.quill.on(v.default.events.EDITOR_CHANGE, function(I, Z, V, H) {
|
|
19550
19554
|
I !== v.default.events.TEXT_CHANGE || L.ignoreChange || (!L.options.userOnly || H === v.default.sources.USER ? L.record(Z, V) : L.transform(Z));
|
|
19551
19555
|
}), L.quill.keyboard.addBinding({ key: "Z", shortKey: !0 }, L.undo.bind(L)), L.quill.keyboard.addBinding({ key: "Z", shortKey: !0, shiftKey: !0 }, L.redo.bind(L)), /Win/i.test(navigator.platform) && L.quill.keyboard.addBinding({ key: "Y", shortKey: !0 }, L.redo.bind(L)), L;
|
|
19552
19556
|
}
|
|
19553
19557
|
return d(C, [{
|
|
19554
19558
|
key: "change",
|
|
19555
|
-
value: function(
|
|
19556
|
-
if (this.stack[
|
|
19557
|
-
var I = this.stack[
|
|
19558
|
-
this.stack[L].push(I), this.lastRecorded = 0, this.ignoreChange = !0, this.quill.updateContents(I[
|
|
19559
|
-
var Z = g(I[
|
|
19559
|
+
value: function(_, L) {
|
|
19560
|
+
if (this.stack[_].length !== 0) {
|
|
19561
|
+
var I = this.stack[_].pop();
|
|
19562
|
+
this.stack[L].push(I), this.lastRecorded = 0, this.ignoreChange = !0, this.quill.updateContents(I[_], v.default.sources.USER), this.ignoreChange = !1;
|
|
19563
|
+
var Z = g(I[_]);
|
|
19560
19564
|
this.quill.setSelection(Z);
|
|
19561
19565
|
}
|
|
19562
19566
|
}
|
|
@@ -19572,17 +19576,17 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
19572
19576
|
}
|
|
19573
19577
|
}, {
|
|
19574
19578
|
key: "record",
|
|
19575
|
-
value: function(
|
|
19576
|
-
if (
|
|
19579
|
+
value: function(_, L) {
|
|
19580
|
+
if (_.ops.length !== 0) {
|
|
19577
19581
|
this.stack.redo = [];
|
|
19578
19582
|
var I = this.quill.getContents().diff(L), Z = Date.now();
|
|
19579
19583
|
if (this.lastRecorded + this.options.delay > Z && this.stack.undo.length > 0) {
|
|
19580
19584
|
var V = this.stack.undo.pop();
|
|
19581
|
-
I = I.compose(V.undo),
|
|
19585
|
+
I = I.compose(V.undo), _ = V.redo.compose(_);
|
|
19582
19586
|
} else
|
|
19583
19587
|
this.lastRecorded = Z;
|
|
19584
19588
|
this.stack.undo.push({
|
|
19585
|
-
redo:
|
|
19589
|
+
redo: _,
|
|
19586
19590
|
undo: I
|
|
19587
19591
|
}), this.stack.undo.length > this.options.maxStack && this.stack.undo.shift();
|
|
19588
19592
|
}
|
|
@@ -19594,11 +19598,11 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
19594
19598
|
}
|
|
19595
19599
|
}, {
|
|
19596
19600
|
key: "transform",
|
|
19597
|
-
value: function(
|
|
19601
|
+
value: function(_) {
|
|
19598
19602
|
this.stack.undo.forEach(function(L) {
|
|
19599
|
-
L.undo =
|
|
19603
|
+
L.undo = _.transform(L.undo, !0), L.redo = _.transform(L.redo, !0);
|
|
19600
19604
|
}), this.stack.redo.forEach(function(L) {
|
|
19601
|
-
L.undo =
|
|
19605
|
+
L.undo = _.transform(L.undo, !0), L.redo = _.transform(L.redo, !0);
|
|
19602
19606
|
});
|
|
19603
19607
|
}
|
|
19604
19608
|
}, {
|
|
@@ -19621,8 +19625,8 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
19621
19625
|
}) : !1;
|
|
19622
19626
|
}
|
|
19623
19627
|
function g(x) {
|
|
19624
|
-
var C = x.reduce(function(
|
|
19625
|
-
return
|
|
19628
|
+
var C = x.reduce(function(_, L) {
|
|
19629
|
+
return _ += L.delete || 0, _;
|
|
19626
19630
|
}, 0), w = x.length() - C;
|
|
19627
19631
|
return f(x) && (w -= 1), w;
|
|
19628
19632
|
}
|
|
@@ -19636,27 +19640,27 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
19636
19640
|
}), r.default = r.BaseTooltip = void 0;
|
|
19637
19641
|
var d = function() {
|
|
19638
19642
|
function B(R, j) {
|
|
19639
|
-
for (var
|
|
19640
|
-
var N = j[
|
|
19643
|
+
for (var A = 0; A < j.length; A++) {
|
|
19644
|
+
var N = j[A];
|
|
19641
19645
|
N.enumerable = N.enumerable || !1, N.configurable = !0, "value" in N && (N.writable = !0), Object.defineProperty(R, N.key, N);
|
|
19642
19646
|
}
|
|
19643
19647
|
}
|
|
19644
|
-
return function(R, j,
|
|
19645
|
-
return j && B(R.prototype, j),
|
|
19648
|
+
return function(R, j, A) {
|
|
19649
|
+
return j && B(R.prototype, j), A && B(R, A), R;
|
|
19646
19650
|
};
|
|
19647
|
-
}(), p = function B(R, j,
|
|
19651
|
+
}(), p = function B(R, j, A) {
|
|
19648
19652
|
R === null && (R = Function.prototype);
|
|
19649
19653
|
var N = Object.getOwnPropertyDescriptor(R, j);
|
|
19650
19654
|
if (N === void 0) {
|
|
19651
19655
|
var W = Object.getPrototypeOf(R);
|
|
19652
|
-
return W === null ? void 0 : B(W, j,
|
|
19656
|
+
return W === null ? void 0 : B(W, j, A);
|
|
19653
19657
|
} else {
|
|
19654
19658
|
if ("value" in N)
|
|
19655
19659
|
return N.value;
|
|
19656
19660
|
var Y = N.get;
|
|
19657
|
-
return Y === void 0 ? void 0 : Y.call(
|
|
19661
|
+
return Y === void 0 ? void 0 : Y.call(A);
|
|
19658
19662
|
}
|
|
19659
|
-
}, b = n(3), s = Z(b), v = n(2), h = Z(v), u = n(8), a = Z(u), l = n(23), y = Z(l), m = n(34), c = Z(m), f = n(59), g = Z(f), x = n(60), C = Z(x), w = n(28),
|
|
19663
|
+
}, b = n(3), s = Z(b), v = n(2), h = Z(v), u = n(8), a = Z(u), l = n(23), y = Z(l), m = n(34), c = Z(m), f = n(59), g = Z(f), x = n(60), C = Z(x), w = n(28), _ = Z(w), L = n(61), I = Z(L);
|
|
19660
19664
|
function Z(B) {
|
|
19661
19665
|
return B && B.__esModule ? B : { default: B };
|
|
19662
19666
|
}
|
|
@@ -19676,9 +19680,9 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
19676
19680
|
}
|
|
19677
19681
|
var S = [!1, "center", "right", "justify"], E = ["#000000", "#e60000", "#ff9900", "#ffff00", "#008a00", "#0066cc", "#9933ff", "#ffffff", "#facccc", "#ffebcc", "#ffffcc", "#cce8cc", "#cce0f5", "#ebd6ff", "#bbbbbb", "#f06666", "#ffc266", "#ffff66", "#66b966", "#66a3e0", "#c285ff", "#888888", "#a10000", "#b26b00", "#b2b200", "#006100", "#0047b2", "#6b24b2", "#444444", "#5c0000", "#663d00", "#666600", "#003700", "#002966", "#3d1466"], F = [!1, "serif", "monospace"], D = ["1", "2", "3", !1], z = ["small", !1, "large", "huge"], Q = function(B) {
|
|
19678
19682
|
k(R, B);
|
|
19679
|
-
function R(j,
|
|
19683
|
+
function R(j, A) {
|
|
19680
19684
|
V(this, R);
|
|
19681
|
-
var N = H(this, (R.__proto__ || Object.getPrototypeOf(R)).call(this, j,
|
|
19685
|
+
var N = H(this, (R.__proto__ || Object.getPrototypeOf(R)).call(this, j, A)), W = function Y(J) {
|
|
19682
19686
|
if (!document.body.contains(j.root))
|
|
19683
19687
|
return document.body.removeEventListener("click", Y);
|
|
19684
19688
|
N.tooltip != null && !N.tooltip.root.contains(J.target) && document.activeElement !== N.tooltip.textbox && !N.quill.hasFocus() && N.tooltip.hide(), N.pickers != null && N.pickers.forEach(function(e1) {
|
|
@@ -19689,14 +19693,14 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
19689
19693
|
}
|
|
19690
19694
|
return d(R, [{
|
|
19691
19695
|
key: "addModule",
|
|
19692
|
-
value: function(
|
|
19693
|
-
var N = p(R.prototype.__proto__ || Object.getPrototypeOf(R.prototype), "addModule", this).call(this,
|
|
19694
|
-
return
|
|
19696
|
+
value: function(A) {
|
|
19697
|
+
var N = p(R.prototype.__proto__ || Object.getPrototypeOf(R.prototype), "addModule", this).call(this, A);
|
|
19698
|
+
return A === "toolbar" && this.extendToolbar(N), N;
|
|
19695
19699
|
}
|
|
19696
19700
|
}, {
|
|
19697
19701
|
key: "buildButtons",
|
|
19698
|
-
value: function(
|
|
19699
|
-
|
|
19702
|
+
value: function(A, N) {
|
|
19703
|
+
A.forEach(function(W) {
|
|
19700
19704
|
var Y = W.getAttribute("class") || "";
|
|
19701
19705
|
Y.split(/\s+/).forEach(function(J) {
|
|
19702
19706
|
if (J.startsWith("ql-") && (J = J.slice(3), N[J] != null))
|
|
@@ -19713,16 +19717,16 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
19713
19717
|
}
|
|
19714
19718
|
}, {
|
|
19715
19719
|
key: "buildPickers",
|
|
19716
|
-
value: function(
|
|
19720
|
+
value: function(A, N) {
|
|
19717
19721
|
var W = this;
|
|
19718
|
-
this.pickers =
|
|
19722
|
+
this.pickers = A.map(function(J) {
|
|
19719
19723
|
if (J.classList.contains("ql-align"))
|
|
19720
19724
|
return J.querySelector("option") == null && M(J, S), new C.default(J, N.align);
|
|
19721
19725
|
if (J.classList.contains("ql-background") || J.classList.contains("ql-color")) {
|
|
19722
19726
|
var e1 = J.classList.contains("ql-background") ? "background" : "color";
|
|
19723
19727
|
return J.querySelector("option") == null && M(J, E, e1 === "background" ? "#ffffff" : "#000000"), new g.default(J, N[e1]);
|
|
19724
19728
|
} else
|
|
19725
|
-
return J.querySelector("option") == null && (J.classList.contains("ql-font") ? M(J, F) : J.classList.contains("ql-header") ? M(J, D) : J.classList.contains("ql-size") && M(J, z)), new
|
|
19729
|
+
return J.querySelector("option") == null && (J.classList.contains("ql-font") ? M(J, F) : J.classList.contains("ql-header") ? M(J, D) : J.classList.contains("ql-size") && M(J, z)), new _.default(J);
|
|
19726
19730
|
});
|
|
19727
19731
|
var Y = function() {
|
|
19728
19732
|
W.pickers.forEach(function(e1) {
|
|
@@ -19744,11 +19748,11 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
19744
19748
|
var R = this, j = this.container.querySelector("input.ql-image[type=file]");
|
|
19745
19749
|
j == null && (j = document.createElement("input"), j.setAttribute("type", "file"), j.setAttribute("accept", "image/png, image/gif, image/jpeg, image/bmp, image/x-icon"), j.classList.add("ql-image"), j.addEventListener("change", function() {
|
|
19746
19750
|
if (j.files != null && j.files[0] != null) {
|
|
19747
|
-
var
|
|
19748
|
-
|
|
19751
|
+
var A = new FileReader();
|
|
19752
|
+
A.onload = function(N) {
|
|
19749
19753
|
var W = R.quill.getSelection(!0);
|
|
19750
19754
|
R.quill.updateContents(new h.default().retain(W.index).delete(W.length).insert({ image: N.target.result }), a.default.sources.USER), R.quill.setSelection(W.index + 1, a.default.sources.SILENT), j.value = "";
|
|
19751
|
-
},
|
|
19755
|
+
}, A.readAsDataURL(j.files[0]);
|
|
19752
19756
|
}
|
|
19753
19757
|
}), this.container.appendChild(j)), j.click();
|
|
19754
19758
|
},
|
|
@@ -19761,17 +19765,17 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
19761
19765
|
});
|
|
19762
19766
|
var X = function(B) {
|
|
19763
19767
|
k(R, B);
|
|
19764
|
-
function R(j,
|
|
19768
|
+
function R(j, A) {
|
|
19765
19769
|
V(this, R);
|
|
19766
|
-
var N = H(this, (R.__proto__ || Object.getPrototypeOf(R)).call(this, j,
|
|
19770
|
+
var N = H(this, (R.__proto__ || Object.getPrototypeOf(R)).call(this, j, A));
|
|
19767
19771
|
return N.textbox = N.root.querySelector('input[type="text"]'), N.listen(), N;
|
|
19768
19772
|
}
|
|
19769
19773
|
return d(R, [{
|
|
19770
19774
|
key: "listen",
|
|
19771
19775
|
value: function() {
|
|
19772
|
-
var
|
|
19776
|
+
var A = this;
|
|
19773
19777
|
this.textbox.addEventListener("keydown", function(N) {
|
|
19774
|
-
y.default.match(N, "enter") ? (
|
|
19778
|
+
y.default.match(N, "enter") ? (A.save(), N.preventDefault()) : y.default.match(N, "escape") && (A.cancel(), N.preventDefault());
|
|
19775
19779
|
});
|
|
19776
19780
|
}
|
|
19777
19781
|
}, {
|
|
@@ -19782,34 +19786,34 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
19782
19786
|
}, {
|
|
19783
19787
|
key: "edit",
|
|
19784
19788
|
value: function() {
|
|
19785
|
-
var
|
|
19786
|
-
this.root.classList.remove("ql-hidden"), this.root.classList.add("ql-editing"), N != null ? this.textbox.value = N :
|
|
19789
|
+
var A = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : "link", N = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : null;
|
|
19790
|
+
this.root.classList.remove("ql-hidden"), this.root.classList.add("ql-editing"), N != null ? this.textbox.value = N : A !== this.root.getAttribute("data-mode") && (this.textbox.value = ""), this.position(this.quill.getBounds(this.quill.selection.savedRange)), this.textbox.select(), this.textbox.setAttribute("placeholder", this.textbox.getAttribute("data-" + A) || ""), this.root.setAttribute("data-mode", A);
|
|
19787
19791
|
}
|
|
19788
19792
|
}, {
|
|
19789
19793
|
key: "restoreFocus",
|
|
19790
19794
|
value: function() {
|
|
19791
|
-
var
|
|
19792
|
-
this.quill.focus(), this.quill.scrollingContainer.scrollTop =
|
|
19795
|
+
var A = this.quill.scrollingContainer.scrollTop;
|
|
19796
|
+
this.quill.focus(), this.quill.scrollingContainer.scrollTop = A;
|
|
19793
19797
|
}
|
|
19794
19798
|
}, {
|
|
19795
19799
|
key: "save",
|
|
19796
19800
|
value: function() {
|
|
19797
|
-
var
|
|
19801
|
+
var A = this.textbox.value;
|
|
19798
19802
|
switch (this.root.getAttribute("data-mode")) {
|
|
19799
19803
|
case "link": {
|
|
19800
19804
|
var N = this.quill.root.scrollTop;
|
|
19801
|
-
this.linkRange ? (this.quill.formatText(this.linkRange, "link",
|
|
19805
|
+
this.linkRange ? (this.quill.formatText(this.linkRange, "link", A, a.default.sources.USER), delete this.linkRange) : (this.restoreFocus(), this.quill.format("link", A, a.default.sources.USER)), this.quill.root.scrollTop = N;
|
|
19802
19806
|
break;
|
|
19803
19807
|
}
|
|
19804
19808
|
case "video":
|
|
19805
|
-
|
|
19809
|
+
A = P(A);
|
|
19806
19810
|
case "formula": {
|
|
19807
|
-
if (!
|
|
19811
|
+
if (!A)
|
|
19808
19812
|
break;
|
|
19809
19813
|
var W = this.quill.getSelection(!0);
|
|
19810
19814
|
if (W != null) {
|
|
19811
19815
|
var Y = W.index + W.length;
|
|
19812
|
-
this.quill.insertEmbed(Y, this.root.getAttribute("data-mode"),
|
|
19816
|
+
this.quill.insertEmbed(Y, this.root.getAttribute("data-mode"), A, a.default.sources.USER), this.root.getAttribute("data-mode") === "formula" && this.quill.insertText(Y + 1, " ", a.default.sources.USER), this.quill.setSelection(Y + 2, a.default.sources.USER);
|
|
19813
19817
|
}
|
|
19814
19818
|
break;
|
|
19815
19819
|
}
|
|
@@ -19824,9 +19828,9 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
19824
19828
|
}
|
|
19825
19829
|
function M(B, R) {
|
|
19826
19830
|
var j = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : !1;
|
|
19827
|
-
R.forEach(function(
|
|
19831
|
+
R.forEach(function(A) {
|
|
19828
19832
|
var N = document.createElement("option");
|
|
19829
|
-
|
|
19833
|
+
A === j ? N.setAttribute("selected", "selected") : N.setAttribute("value", A), B.appendChild(N);
|
|
19830
19834
|
});
|
|
19831
19835
|
}
|
|
19832
19836
|
r.BaseTooltip = X, r.default = Q;
|
|
@@ -19947,8 +19951,8 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
19947
19951
|
l === void 0 && (l = []), y === void 0 && (y = {}), u.prototype.optimize.call(this, y);
|
|
19948
19952
|
for (var c = [].slice.call(this.observer.takeRecords()); c.length > 0; )
|
|
19949
19953
|
l.push(c.pop());
|
|
19950
|
-
for (var f = function(w,
|
|
19951
|
-
|
|
19954
|
+
for (var f = function(w, _) {
|
|
19955
|
+
_ === void 0 && (_ = !0), !(w == null || w === m) && w.domNode.parentNode != null && (w.domNode[b.DATA_KEY].mutations == null && (w.domNode[b.DATA_KEY].mutations = []), _ && f(w.parent));
|
|
19952
19956
|
}, g = function(w) {
|
|
19953
19957
|
// @ts-ignore
|
|
19954
19958
|
w.domNode[b.DATA_KEY] == null || // @ts-ignore
|
|
@@ -19957,13 +19961,13 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
19957
19961
|
if (C >= v)
|
|
19958
19962
|
throw new Error("[Parchment] Maximum optimize iterations reached");
|
|
19959
19963
|
for (x.forEach(function(w) {
|
|
19960
|
-
var
|
|
19961
|
-
|
|
19964
|
+
var _ = b.find(w.target, !0);
|
|
19965
|
+
_ != null && (_.domNode === w.target && (w.type === "childList" ? (f(b.find(w.previousSibling, !1)), [].forEach.call(w.addedNodes, function(L) {
|
|
19962
19966
|
var I = b.find(L, !1);
|
|
19963
19967
|
f(I, !1), I instanceof p.default && I.children.forEach(function(Z) {
|
|
19964
19968
|
f(Z, !1);
|
|
19965
19969
|
});
|
|
19966
|
-
})) : w.type === "attributes" && f(
|
|
19970
|
+
})) : w.type === "attributes" && f(_.prev)), f(_));
|
|
19967
19971
|
}), this.children.forEach(g), x = [].slice.call(this.observer.takeRecords()), c = x.slice(); c.length > 0; )
|
|
19968
19972
|
l.push(c.pop());
|
|
19969
19973
|
}
|
|
@@ -20228,30 +20232,30 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
20228
20232
|
/***/
|
|
20229
20233
|
function(i, r) {
|
|
20230
20234
|
var n = -1, d = 1, p = 0;
|
|
20231
|
-
function b(C, w,
|
|
20235
|
+
function b(C, w, _) {
|
|
20232
20236
|
if (C == w)
|
|
20233
20237
|
return C ? [[p, C]] : [];
|
|
20234
|
-
(
|
|
20238
|
+
(_ < 0 || C.length < _) && (_ = null);
|
|
20235
20239
|
var L = u(C, w), I = C.substring(0, L);
|
|
20236
20240
|
C = C.substring(L), w = w.substring(L), L = a(C, w);
|
|
20237
20241
|
var Z = C.substring(C.length - L);
|
|
20238
20242
|
C = C.substring(0, C.length - L), w = w.substring(0, w.length - L);
|
|
20239
20243
|
var V = s(C, w);
|
|
20240
|
-
return I && V.unshift([p, I]), Z && V.push([p, Z]), y(V),
|
|
20244
|
+
return I && V.unshift([p, I]), Z && V.push([p, Z]), y(V), _ != null && (V = f(V, _)), V = g(V), V;
|
|
20241
20245
|
}
|
|
20242
20246
|
function s(C, w) {
|
|
20243
|
-
var
|
|
20247
|
+
var _;
|
|
20244
20248
|
if (!C)
|
|
20245
20249
|
return [[d, w]];
|
|
20246
20250
|
if (!w)
|
|
20247
20251
|
return [[n, C]];
|
|
20248
20252
|
var L = C.length > w.length ? C : w, I = C.length > w.length ? w : C, Z = L.indexOf(I);
|
|
20249
20253
|
if (Z != -1)
|
|
20250
|
-
return
|
|
20254
|
+
return _ = [
|
|
20251
20255
|
[d, L.substring(0, Z)],
|
|
20252
20256
|
[p, I],
|
|
20253
20257
|
[d, L.substring(Z + I.length)]
|
|
20254
|
-
], C.length > w.length && (
|
|
20258
|
+
], C.length > w.length && (_[0][0] = _[2][0] = n), _;
|
|
20255
20259
|
if (I.length == 1)
|
|
20256
20260
|
return [[n, C], [d, w]];
|
|
20257
20261
|
var V = l(C, w);
|
|
@@ -20262,34 +20266,34 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
20262
20266
|
return v(C, w);
|
|
20263
20267
|
}
|
|
20264
20268
|
function v(C, w) {
|
|
20265
|
-
for (var
|
|
20269
|
+
for (var _ = C.length, L = w.length, I = Math.ceil((_ + L) / 2), Z = I, V = 2 * I, H = new Array(V), k = new Array(V), S = 0; S < V; S++)
|
|
20266
20270
|
H[S] = -1, k[S] = -1;
|
|
20267
20271
|
H[Z + 1] = 0, k[Z + 1] = 0;
|
|
20268
|
-
for (var E =
|
|
20272
|
+
for (var E = _ - L, F = E % 2 != 0, D = 0, z = 0, Q = 0, X = 0, P = 0; P < I; P++) {
|
|
20269
20273
|
for (var M = -P + D; M <= P - z; M += 2) {
|
|
20270
20274
|
var B = Z + M, R;
|
|
20271
20275
|
M == -P || M != P && H[B - 1] < H[B + 1] ? R = H[B + 1] : R = H[B - 1] + 1;
|
|
20272
|
-
for (var j = R - M; R <
|
|
20276
|
+
for (var j = R - M; R < _ && j < L && C.charAt(R) == w.charAt(j); )
|
|
20273
20277
|
R++, j++;
|
|
20274
|
-
if (H[B] = R, R >
|
|
20278
|
+
if (H[B] = R, R > _)
|
|
20275
20279
|
z += 2;
|
|
20276
20280
|
else if (j > L)
|
|
20277
20281
|
D += 2;
|
|
20278
20282
|
else if (F) {
|
|
20279
|
-
var
|
|
20280
|
-
if (
|
|
20281
|
-
var N =
|
|
20283
|
+
var A = Z + E - M;
|
|
20284
|
+
if (A >= 0 && A < V && k[A] != -1) {
|
|
20285
|
+
var N = _ - k[A];
|
|
20282
20286
|
if (R >= N)
|
|
20283
20287
|
return h(C, w, R, j);
|
|
20284
20288
|
}
|
|
20285
20289
|
}
|
|
20286
20290
|
}
|
|
20287
20291
|
for (var W = -P + Q; W <= P - X; W += 2) {
|
|
20288
|
-
var
|
|
20289
|
-
W == -P || W != P && k[
|
|
20290
|
-
for (var Y = N - W; N <
|
|
20292
|
+
var A = Z + W, N;
|
|
20293
|
+
W == -P || W != P && k[A - 1] < k[A + 1] ? N = k[A + 1] : N = k[A - 1] + 1;
|
|
20294
|
+
for (var Y = N - W; N < _ && Y < L && C.charAt(_ - N - 1) == w.charAt(L - Y - 1); )
|
|
20291
20295
|
N++, Y++;
|
|
20292
|
-
if (k[
|
|
20296
|
+
if (k[A] = N, N > _)
|
|
20293
20297
|
X += 2;
|
|
20294
20298
|
else if (Y > L)
|
|
20295
20299
|
Q += 2;
|
|
@@ -20297,7 +20301,7 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
20297
20301
|
var B = Z + E - W;
|
|
20298
20302
|
if (B >= 0 && B < V && H[B] != -1) {
|
|
20299
20303
|
var R = H[B], j = Z + R - B;
|
|
20300
|
-
if (N =
|
|
20304
|
+
if (N = _ - N, R >= N)
|
|
20301
20305
|
return h(C, w, R, j);
|
|
20302
20306
|
}
|
|
20303
20307
|
}
|
|
@@ -20305,30 +20309,30 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
20305
20309
|
}
|
|
20306
20310
|
return [[n, C], [d, w]];
|
|
20307
20311
|
}
|
|
20308
|
-
function h(C, w,
|
|
20309
|
-
var I = C.substring(0,
|
|
20312
|
+
function h(C, w, _, L) {
|
|
20313
|
+
var I = C.substring(0, _), Z = w.substring(0, L), V = C.substring(_), H = w.substring(L), k = b(I, Z), S = b(V, H);
|
|
20310
20314
|
return k.concat(S);
|
|
20311
20315
|
}
|
|
20312
20316
|
function u(C, w) {
|
|
20313
20317
|
if (!C || !w || C.charAt(0) != w.charAt(0))
|
|
20314
20318
|
return 0;
|
|
20315
|
-
for (var
|
|
20316
|
-
C.substring(Z, I) == w.substring(Z, I) ? (
|
|
20319
|
+
for (var _ = 0, L = Math.min(C.length, w.length), I = L, Z = 0; _ < I; )
|
|
20320
|
+
C.substring(Z, I) == w.substring(Z, I) ? (_ = I, Z = _) : L = I, I = Math.floor((L - _) / 2 + _);
|
|
20317
20321
|
return I;
|
|
20318
20322
|
}
|
|
20319
20323
|
function a(C, w) {
|
|
20320
20324
|
if (!C || !w || C.charAt(C.length - 1) != w.charAt(w.length - 1))
|
|
20321
20325
|
return 0;
|
|
20322
|
-
for (var
|
|
20323
|
-
C.substring(C.length - I, C.length - Z) == w.substring(w.length - I, w.length - Z) ? (
|
|
20326
|
+
for (var _ = 0, L = Math.min(C.length, w.length), I = L, Z = 0; _ < I; )
|
|
20327
|
+
C.substring(C.length - I, C.length - Z) == w.substring(w.length - I, w.length - Z) ? (_ = I, Z = _) : L = I, I = Math.floor((L - _) / 2 + _);
|
|
20324
20328
|
return I;
|
|
20325
20329
|
}
|
|
20326
20330
|
function l(C, w) {
|
|
20327
|
-
var
|
|
20328
|
-
if (
|
|
20331
|
+
var _ = C.length > w.length ? C : w, L = C.length > w.length ? w : C;
|
|
20332
|
+
if (_.length < 4 || L.length * 2 < _.length)
|
|
20329
20333
|
return null;
|
|
20330
20334
|
function I(z, Q, X) {
|
|
20331
|
-
for (var P = z.substring(X, X + Math.floor(z.length / 4)), M = -1, B = "", R, j,
|
|
20335
|
+
for (var P = z.substring(X, X + Math.floor(z.length / 4)), M = -1, B = "", R, j, A, N; (M = Q.indexOf(P, M + 1)) != -1; ) {
|
|
20332
20336
|
var W = u(
|
|
20333
20337
|
z.substring(X),
|
|
20334
20338
|
Q.substring(M)
|
|
@@ -20336,24 +20340,24 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
20336
20340
|
z.substring(0, X),
|
|
20337
20341
|
Q.substring(0, M)
|
|
20338
20342
|
);
|
|
20339
|
-
B.length < Y + W && (B = Q.substring(M - Y, M) + Q.substring(M, M + W), R = z.substring(0, X - Y), j = z.substring(X + W),
|
|
20343
|
+
B.length < Y + W && (B = Q.substring(M - Y, M) + Q.substring(M, M + W), R = z.substring(0, X - Y), j = z.substring(X + W), A = Q.substring(0, M - Y), N = Q.substring(M + W));
|
|
20340
20344
|
}
|
|
20341
20345
|
return B.length * 2 >= z.length ? [
|
|
20342
20346
|
R,
|
|
20343
20347
|
j,
|
|
20344
|
-
|
|
20348
|
+
A,
|
|
20345
20349
|
N,
|
|
20346
20350
|
B
|
|
20347
20351
|
] : null;
|
|
20348
20352
|
}
|
|
20349
20353
|
var Z = I(
|
|
20350
|
-
|
|
20354
|
+
_,
|
|
20351
20355
|
L,
|
|
20352
|
-
Math.ceil(
|
|
20356
|
+
Math.ceil(_.length / 4)
|
|
20353
20357
|
), V = I(
|
|
20354
|
-
|
|
20358
|
+
_,
|
|
20355
20359
|
L,
|
|
20356
|
-
Math.ceil(
|
|
20360
|
+
Math.ceil(_.length / 2)
|
|
20357
20361
|
), H;
|
|
20358
20362
|
if (!Z && !V)
|
|
20359
20363
|
return null;
|
|
@@ -20365,32 +20369,32 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
20365
20369
|
}
|
|
20366
20370
|
function y(C) {
|
|
20367
20371
|
C.push([p, ""]);
|
|
20368
|
-
for (var w = 0,
|
|
20372
|
+
for (var w = 0, _ = 0, L = 0, I = "", Z = "", V; w < C.length; )
|
|
20369
20373
|
switch (C[w][0]) {
|
|
20370
20374
|
case d:
|
|
20371
20375
|
L++, Z += C[w][1], w++;
|
|
20372
20376
|
break;
|
|
20373
20377
|
case n:
|
|
20374
|
-
|
|
20378
|
+
_++, I += C[w][1], w++;
|
|
20375
20379
|
break;
|
|
20376
20380
|
case p:
|
|
20377
|
-
|
|
20381
|
+
_ + L > 1 ? (_ !== 0 && L !== 0 && (V = u(Z, I), V !== 0 && (w - _ - L > 0 && C[w - _ - L - 1][0] == p ? C[w - _ - L - 1][1] += Z.substring(0, V) : (C.splice(0, 0, [
|
|
20378
20382
|
p,
|
|
20379
20383
|
Z.substring(0, V)
|
|
20380
|
-
]), w++), Z = Z.substring(V), I = I.substring(V)), V = a(Z, I), V !== 0 && (C[w][1] = Z.substring(Z.length - V) + C[w][1], Z = Z.substring(0, Z.length - V), I = I.substring(0, I.length - V))),
|
|
20384
|
+
]), w++), Z = Z.substring(V), I = I.substring(V)), V = a(Z, I), V !== 0 && (C[w][1] = Z.substring(Z.length - V) + C[w][1], Z = Z.substring(0, Z.length - V), I = I.substring(0, I.length - V))), _ === 0 ? C.splice(
|
|
20381
20385
|
w - L,
|
|
20382
|
-
|
|
20386
|
+
_ + L,
|
|
20383
20387
|
[d, Z]
|
|
20384
20388
|
) : L === 0 ? C.splice(
|
|
20385
|
-
w -
|
|
20386
|
-
|
|
20389
|
+
w - _,
|
|
20390
|
+
_ + L,
|
|
20387
20391
|
[n, I]
|
|
20388
20392
|
) : C.splice(
|
|
20389
|
-
w -
|
|
20390
|
-
|
|
20393
|
+
w - _ - L,
|
|
20394
|
+
_ + L,
|
|
20391
20395
|
[n, I],
|
|
20392
20396
|
[d, Z]
|
|
20393
|
-
), w = w -
|
|
20397
|
+
), w = w - _ - L + (_ ? 1 : 0) + (L ? 1 : 0) + 1) : w !== 0 && C[w - 1][0] == p ? (C[w - 1][1] += C[w][1], C.splice(w, 1)) : w++, L = 0, _ = 0, I = "", Z = "";
|
|
20394
20398
|
break;
|
|
20395
20399
|
}
|
|
20396
20400
|
C[C.length - 1][1] === "" && C.pop();
|
|
@@ -20404,24 +20408,24 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
20404
20408
|
function c(C, w) {
|
|
20405
20409
|
if (w === 0)
|
|
20406
20410
|
return [p, C];
|
|
20407
|
-
for (var
|
|
20411
|
+
for (var _ = 0, L = 0; L < C.length; L++) {
|
|
20408
20412
|
var I = C[L];
|
|
20409
20413
|
if (I[0] === n || I[0] === p) {
|
|
20410
|
-
var Z =
|
|
20414
|
+
var Z = _ + I[1].length;
|
|
20411
20415
|
if (w === Z)
|
|
20412
20416
|
return [L + 1, C];
|
|
20413
20417
|
if (w < Z) {
|
|
20414
20418
|
C = C.slice();
|
|
20415
|
-
var V = w -
|
|
20419
|
+
var V = w - _, H = [I[0], I[1].slice(0, V)], k = [I[0], I[1].slice(V)];
|
|
20416
20420
|
return C.splice(L, 1, H, k), [L + 1, C];
|
|
20417
20421
|
} else
|
|
20418
|
-
|
|
20422
|
+
_ = Z;
|
|
20419
20423
|
}
|
|
20420
20424
|
}
|
|
20421
20425
|
throw new Error("cursor_pos is out of bounds!");
|
|
20422
20426
|
}
|
|
20423
20427
|
function f(C, w) {
|
|
20424
|
-
var
|
|
20428
|
+
var _ = c(C, w), L = _[1], I = _[0], Z = L[I], V = L[I + 1];
|
|
20425
20429
|
if (Z == null)
|
|
20426
20430
|
return C;
|
|
20427
20431
|
if (Z[0] !== p)
|
|
@@ -20436,20 +20440,20 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
20436
20440
|
return C;
|
|
20437
20441
|
}
|
|
20438
20442
|
function g(C) {
|
|
20439
|
-
for (var w = !1,
|
|
20443
|
+
for (var w = !1, _ = function(V) {
|
|
20440
20444
|
return V.charCodeAt(0) >= 56320 && V.charCodeAt(0) <= 57343;
|
|
20441
20445
|
}, L = function(V) {
|
|
20442
20446
|
return V.charCodeAt(V.length - 1) >= 55296 && V.charCodeAt(V.length - 1) <= 56319;
|
|
20443
20447
|
}, I = 2; I < C.length; I += 1)
|
|
20444
|
-
C[I - 2][0] === p && L(C[I - 2][1]) && C[I - 1][0] === n &&
|
|
20448
|
+
C[I - 2][0] === p && L(C[I - 2][1]) && C[I - 1][0] === n && _(C[I - 1][1]) && C[I][0] === d && _(C[I][1]) && (w = !0, C[I - 1][1] = C[I - 2][1].slice(-1) + C[I - 1][1], C[I][1] = C[I - 2][1].slice(-1) + C[I][1], C[I - 2][1] = C[I - 2][1].slice(0, -1));
|
|
20445
20449
|
if (!w)
|
|
20446
20450
|
return C;
|
|
20447
20451
|
for (var Z = [], I = 0; I < C.length; I += 1)
|
|
20448
20452
|
C[I][1].length > 0 && Z.push(C[I]);
|
|
20449
20453
|
return Z;
|
|
20450
20454
|
}
|
|
20451
|
-
function x(C, w,
|
|
20452
|
-
for (var L = w +
|
|
20455
|
+
function x(C, w, _) {
|
|
20456
|
+
for (var L = w + _ - 1; L >= 0 && L >= w - 1; L--)
|
|
20453
20457
|
if (L + 1 < C.length) {
|
|
20454
20458
|
var I = C[L], Z = C[L + 1];
|
|
20455
20459
|
I[0] === Z[1] && C.splice(L, 2, [I[0], I[1] + Z[1]]);
|
|
@@ -20538,7 +20542,7 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
20538
20542
|
x[C - 1] = arguments[C];
|
|
20539
20543
|
f.fn.apply(f.context, x);
|
|
20540
20544
|
} else {
|
|
20541
|
-
var w = f.length,
|
|
20545
|
+
var w = f.length, _;
|
|
20542
20546
|
for (C = 0; C < w; C++)
|
|
20543
20547
|
switch (f[C].once && this.removeListener(h, f[C].fn, void 0, !0), g) {
|
|
20544
20548
|
case 1:
|
|
@@ -20555,8 +20559,8 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
20555
20559
|
break;
|
|
20556
20560
|
default:
|
|
20557
20561
|
if (!x)
|
|
20558
|
-
for (
|
|
20559
|
-
x[
|
|
20562
|
+
for (_ = 1, x = new Array(g - 1); _ < g; _++)
|
|
20563
|
+
x[_ - 1] = arguments[_];
|
|
20560
20564
|
f[C].fn.apply(f[C].context, x);
|
|
20561
20565
|
}
|
|
20562
20566
|
}
|
|
@@ -20634,7 +20638,7 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
20634
20638
|
return function($, t1, i1) {
|
|
20635
20639
|
return t1 && q($.prototype, t1), i1 && q($, i1), $;
|
|
20636
20640
|
};
|
|
20637
|
-
}(), s = n(3), v = k(s), h = n(2), u = k(h), a = n(0), l = k(a), y = n(5), m = k(y), c = n(10), f = k(c), g = n(9), x = k(g), C = n(36), w = n(37),
|
|
20641
|
+
}(), s = n(3), v = k(s), h = n(2), u = k(h), a = n(0), l = k(a), y = n(5), m = k(y), c = n(10), f = k(c), g = n(9), x = k(g), C = n(36), w = n(37), _ = n(13), L = k(_), I = n(26), Z = n(38), V = n(39), H = n(40);
|
|
20638
20642
|
function k(q) {
|
|
20639
20643
|
return q && q.__esModule ? q : { default: q };
|
|
20640
20644
|
}
|
|
@@ -20685,7 +20689,7 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
20685
20689
|
return this.container.innerHTML = "", new u.default().insert(l1, S({}, L.default.blotName, n1[L.default.blotName]));
|
|
20686
20690
|
}
|
|
20687
20691
|
var u1 = this.prepareMatching(), d1 = p(u1, 2), h1 = d1[0], g1 = d1[1], H1 = W(this.container, h1, g1);
|
|
20688
|
-
return
|
|
20692
|
+
return A(H1, `
|
|
20689
20693
|
`) && H1.ops[H1.ops.length - 1].attributes == null && (H1 = H1.compose(new u.default().retain(H1.length() - 1).delete(1))), z.log("convert", this.container.innerHTML, H1), this.container.innerHTML = "", H1;
|
|
20690
20694
|
}
|
|
20691
20695
|
}, {
|
|
@@ -20750,7 +20754,7 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
20750
20754
|
var $ = "__ql-computed-style";
|
|
20751
20755
|
return q[$] || (q[$] = window.getComputedStyle(q));
|
|
20752
20756
|
}
|
|
20753
|
-
function
|
|
20757
|
+
function A(q, $) {
|
|
20754
20758
|
for (var t1 = "", i1 = q.ops.length - 1; i1 >= 0 && t1.length < $.length; --i1) {
|
|
20755
20759
|
var n1 = q.ops[i1];
|
|
20756
20760
|
if (typeof n1.insert != "string")
|
|
@@ -20799,7 +20803,7 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
20799
20803
|
return $;
|
|
20800
20804
|
}
|
|
20801
20805
|
function s1(q, $) {
|
|
20802
|
-
return
|
|
20806
|
+
return A($, `
|
|
20803
20807
|
`) || $.insert(`
|
|
20804
20808
|
`), $;
|
|
20805
20809
|
}
|
|
@@ -20808,7 +20812,7 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
20808
20812
|
}
|
|
20809
20813
|
function p1(q, $) {
|
|
20810
20814
|
var t1 = l.default.query(q);
|
|
20811
|
-
if (t1 == null || t1.blotName !== "list-item" || !
|
|
20815
|
+
if (t1 == null || t1.blotName !== "list-item" || !A($, `
|
|
20812
20816
|
`))
|
|
20813
20817
|
return $;
|
|
20814
20818
|
for (var i1 = -1, n1 = q.parentNode; !n1.classList.contains("ql-clipboard"); )
|
|
@@ -20816,12 +20820,12 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
20816
20820
|
return i1 <= 0 ? $ : $.compose(new u.default().retain($.length() - 1).retain(1, { indent: i1 }));
|
|
20817
20821
|
}
|
|
20818
20822
|
function m1(q, $) {
|
|
20819
|
-
return
|
|
20823
|
+
return A($, `
|
|
20820
20824
|
`) || (N(q) || $.length() > 0 && q.nextSibling && N(q.nextSibling)) && $.insert(`
|
|
20821
20825
|
`), $;
|
|
20822
20826
|
}
|
|
20823
20827
|
function U(q, $) {
|
|
20824
|
-
if (N(q) && q.nextElementSibling != null && !
|
|
20828
|
+
if (N(q) && q.nextElementSibling != null && !A($, `
|
|
20825
20829
|
|
|
20826
20830
|
`)) {
|
|
20827
20831
|
var t1 = q.offsetHeight + parseFloat(j(q).marginTop) + parseFloat(j(q).marginBottom);
|
|
@@ -20982,7 +20986,7 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
20982
20986
|
throw new TypeError("Super expression must either be null or a function, not " + typeof k);
|
|
20983
20987
|
H.prototype = Object.create(k && k.prototype, { constructor: { value: H, enumerable: !1, writable: !0, configurable: !0 } }), k && (Object.setPrototypeOf ? Object.setPrototypeOf(H, k) : H.__proto__ = k);
|
|
20984
20988
|
}
|
|
20985
|
-
var
|
|
20989
|
+
var _ = (0, y.default)("quill:toolbar"), L = function(H) {
|
|
20986
20990
|
w(k, H);
|
|
20987
20991
|
function k(S, E) {
|
|
20988
20992
|
x(this, k);
|
|
@@ -20994,7 +20998,7 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
20994
20998
|
typeof F.options.container == "string" ? F.container = document.querySelector(F.options.container) : F.container = F.options.container;
|
|
20995
20999
|
if (!(F.container instanceof HTMLElement)) {
|
|
20996
21000
|
var z;
|
|
20997
|
-
return z =
|
|
21001
|
+
return z = _.error("Container required for toolbar", F.options), C(F, z);
|
|
20998
21002
|
}
|
|
20999
21003
|
return F.container.classList.add("ql-toolbar"), F.controls = [], F.handlers = {}, Object.keys(F.options.handlers).forEach(function(Q) {
|
|
21000
21004
|
F.addHandler(Q, F.options.handlers[Q]);
|
|
@@ -21021,11 +21025,11 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
21021
21025
|
if (D) {
|
|
21022
21026
|
if (D = D.slice(3), E.tagName === "BUTTON" && E.setAttribute("type", "button"), this.handlers[D] == null) {
|
|
21023
21027
|
if (this.quill.scroll.whitelist != null && this.quill.scroll.whitelist[D] == null) {
|
|
21024
|
-
|
|
21028
|
+
_.warn("ignoring attaching to disabled format", D, E);
|
|
21025
21029
|
return;
|
|
21026
21030
|
}
|
|
21027
21031
|
if (h.default.query(D) == null) {
|
|
21028
|
-
|
|
21032
|
+
_.warn("ignoring attaching to nonexistent format", D, E);
|
|
21029
21033
|
return;
|
|
21030
21034
|
}
|
|
21031
21035
|
}
|
|
@@ -21402,13 +21406,13 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
21402
21406
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
21403
21407
|
return H && (typeof H == "object" || typeof H == "function") ? H : V;
|
|
21404
21408
|
}
|
|
21405
|
-
function
|
|
21409
|
+
function _(V, H) {
|
|
21406
21410
|
if (typeof H != "function" && H !== null)
|
|
21407
21411
|
throw new TypeError("Super expression must either be null or a function, not " + typeof H);
|
|
21408
21412
|
V.prototype = Object.create(H && H.prototype, { constructor: { value: V, enumerable: !1, writable: !0, configurable: !0 } }), H && (Object.setPrototypeOf ? Object.setPrototypeOf(V, H) : V.__proto__ = H);
|
|
21409
21413
|
}
|
|
21410
21414
|
var L = [[{ header: ["1", "2", "3", !1] }], ["bold", "italic", "underline", "link"], [{ list: "ordered" }, { list: "bullet" }], ["clean"]], I = function(V) {
|
|
21411
|
-
|
|
21415
|
+
_(H, V);
|
|
21412
21416
|
function H(k, S) {
|
|
21413
21417
|
C(this, H), S.modules.toolbar != null && S.modules.toolbar.container == null && (S.modules.toolbar.container = L);
|
|
21414
21418
|
var E = w(this, (H.__proto__ || Object.getPrototypeOf(H)).call(this, k, S));
|
|
@@ -21444,7 +21448,7 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
21444
21448
|
}
|
|
21445
21449
|
});
|
|
21446
21450
|
var Z = function(V) {
|
|
21447
|
-
|
|
21451
|
+
_(H, V);
|
|
21448
21452
|
function H(k, S) {
|
|
21449
21453
|
C(this, H);
|
|
21450
21454
|
var E = w(this, (H.__proto__ || Object.getPrototypeOf(H)).call(this, k, S));
|
|
@@ -21493,7 +21497,7 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
21493
21497
|
Object.defineProperty(r, "__esModule", {
|
|
21494
21498
|
value: !0
|
|
21495
21499
|
});
|
|
21496
|
-
var d = n(29), p = n1(d), b = n(36), s = n(38), v = n(64), h = n(65), u = n1(h), a = n(66), l = n1(a), y = n(67), m = n1(y), c = n(37), f = n(26), g = n(39), x = n(40), C = n(56), w = n1(C),
|
|
21500
|
+
var d = n(29), p = n1(d), b = n(36), s = n(38), v = n(64), h = n(65), u = n1(h), a = n(66), l = n1(a), y = n(67), m = n1(y), c = n(37), f = n(26), g = n(39), x = n(40), C = n(56), w = n1(C), _ = n(68), L = n1(_), I = n(27), Z = n1(I), V = n(69), H = n1(V), k = n(70), S = n1(k), E = n(71), F = n1(E), D = n(72), z = n1(D), Q = n(73), X = n1(Q), P = n(13), M = n1(P), B = n(74), R = n1(B), j = n(75), A = n1(j), N = n(57), W = n1(N), Y = n(41), J = n1(Y), e1 = n(28), s1 = n1(e1), f1 = n(59), p1 = n1(f1), m1 = n(60), U = n1(m1), o1 = n(61), C1 = n1(o1), q = n(108), $ = n1(q), t1 = n(62), i1 = n1(t1);
|
|
21497
21501
|
function n1(l1) {
|
|
21498
21502
|
return l1 && l1.__esModule ? l1 : { default: l1 };
|
|
21499
21503
|
}
|
|
@@ -21534,7 +21538,7 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
21534
21538
|
"formats/video": X.default,
|
|
21535
21539
|
"formats/list/item": y.ListItem,
|
|
21536
21540
|
"modules/formula": R.default,
|
|
21537
|
-
"modules/syntax":
|
|
21541
|
+
"modules/syntax": A.default,
|
|
21538
21542
|
"modules/toolbar": W.default,
|
|
21539
21543
|
"themes/bubble": $.default,
|
|
21540
21544
|
"themes/snow": i1.default,
|
|
@@ -21710,21 +21714,21 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
21710
21714
|
value: !0
|
|
21711
21715
|
}), r.default = r.ListItem = void 0;
|
|
21712
21716
|
var d = function() {
|
|
21713
|
-
function C(w,
|
|
21714
|
-
for (var L = 0; L <
|
|
21715
|
-
var I =
|
|
21717
|
+
function C(w, _) {
|
|
21718
|
+
for (var L = 0; L < _.length; L++) {
|
|
21719
|
+
var I = _[L];
|
|
21716
21720
|
I.enumerable = I.enumerable || !1, I.configurable = !0, "value" in I && (I.writable = !0), Object.defineProperty(w, I.key, I);
|
|
21717
21721
|
}
|
|
21718
21722
|
}
|
|
21719
|
-
return function(w,
|
|
21720
|
-
return
|
|
21723
|
+
return function(w, _, L) {
|
|
21724
|
+
return _ && C(w.prototype, _), L && C(w, L), w;
|
|
21721
21725
|
};
|
|
21722
|
-
}(), p = function C(w,
|
|
21726
|
+
}(), p = function C(w, _, L) {
|
|
21723
21727
|
w === null && (w = Function.prototype);
|
|
21724
|
-
var I = Object.getOwnPropertyDescriptor(w,
|
|
21728
|
+
var I = Object.getOwnPropertyDescriptor(w, _);
|
|
21725
21729
|
if (I === void 0) {
|
|
21726
21730
|
var Z = Object.getPrototypeOf(w);
|
|
21727
|
-
return Z === null ? void 0 : C(Z,
|
|
21731
|
+
return Z === null ? void 0 : C(Z, _, L);
|
|
21728
21732
|
} else {
|
|
21729
21733
|
if ("value" in I)
|
|
21730
21734
|
return I.value;
|
|
@@ -21735,8 +21739,8 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
21735
21739
|
function l(C) {
|
|
21736
21740
|
return C && C.__esModule ? C : { default: C };
|
|
21737
21741
|
}
|
|
21738
|
-
function y(C, w,
|
|
21739
|
-
return w in C ? Object.defineProperty(C, w, { value:
|
|
21742
|
+
function y(C, w, _) {
|
|
21743
|
+
return w in C ? Object.defineProperty(C, w, { value: _, enumerable: !0, configurable: !0, writable: !0 }) : C[w] = _, C;
|
|
21740
21744
|
}
|
|
21741
21745
|
function m(C, w) {
|
|
21742
21746
|
if (!(C instanceof w))
|
|
@@ -21796,15 +21800,15 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
21796
21800
|
return L.hasAttribute("data-checked") ? L.getAttribute("data-checked") === "true" ? "checked" : "unchecked" : "bullet";
|
|
21797
21801
|
}
|
|
21798
21802
|
}]);
|
|
21799
|
-
function w(
|
|
21803
|
+
function w(_) {
|
|
21800
21804
|
m(this, w);
|
|
21801
|
-
var L = c(this, (w.__proto__ || Object.getPrototypeOf(w)).call(this,
|
|
21802
|
-
if (V.target.parentNode ===
|
|
21803
|
-
var H = L.statics.formats(
|
|
21805
|
+
var L = c(this, (w.__proto__ || Object.getPrototypeOf(w)).call(this, _)), I = function(V) {
|
|
21806
|
+
if (V.target.parentNode === _) {
|
|
21807
|
+
var H = L.statics.formats(_), k = s.default.find(V.target);
|
|
21804
21808
|
H === "checked" ? k.format("list", "unchecked") : H === "unchecked" && k.format("list", "checked");
|
|
21805
21809
|
}
|
|
21806
21810
|
};
|
|
21807
|
-
return
|
|
21811
|
+
return _.addEventListener("touchstart", I), _.addEventListener("mousedown", I), L;
|
|
21808
21812
|
}
|
|
21809
21813
|
return d(w, [{
|
|
21810
21814
|
key: "format",
|
|
@@ -22038,8 +22042,8 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
22038
22042
|
} else {
|
|
22039
22043
|
if ("value" in C)
|
|
22040
22044
|
return C.value;
|
|
22041
|
-
var
|
|
22042
|
-
return
|
|
22045
|
+
var _ = C.get;
|
|
22046
|
+
return _ === void 0 ? void 0 : _.call(x);
|
|
22043
22047
|
}
|
|
22044
22048
|
}, b = n(0), s = h(b), v = n(27);
|
|
22045
22049
|
function h(c) {
|
|
@@ -22126,8 +22130,8 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
22126
22130
|
} else {
|
|
22127
22131
|
if ("value" in C)
|
|
22128
22132
|
return C.value;
|
|
22129
|
-
var
|
|
22130
|
-
return
|
|
22133
|
+
var _ = C.get;
|
|
22134
|
+
return _ === void 0 ? void 0 : _.call(x);
|
|
22131
22135
|
}
|
|
22132
22136
|
}, b = n(4), s = n(27), v = h(s);
|
|
22133
22137
|
function h(c) {
|
|
@@ -22192,25 +22196,25 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
22192
22196
|
}), r.default = r.FormulaBlot = void 0;
|
|
22193
22197
|
var d = function() {
|
|
22194
22198
|
function x(C, w) {
|
|
22195
|
-
for (var
|
|
22196
|
-
var L = w[
|
|
22199
|
+
for (var _ = 0; _ < w.length; _++) {
|
|
22200
|
+
var L = w[_];
|
|
22197
22201
|
L.enumerable = L.enumerable || !1, L.configurable = !0, "value" in L && (L.writable = !0), Object.defineProperty(C, L.key, L);
|
|
22198
22202
|
}
|
|
22199
22203
|
}
|
|
22200
|
-
return function(C, w,
|
|
22201
|
-
return w && x(C.prototype, w),
|
|
22204
|
+
return function(C, w, _) {
|
|
22205
|
+
return w && x(C.prototype, w), _ && x(C, _), C;
|
|
22202
22206
|
};
|
|
22203
|
-
}(), p = function x(C, w,
|
|
22207
|
+
}(), p = function x(C, w, _) {
|
|
22204
22208
|
C === null && (C = Function.prototype);
|
|
22205
22209
|
var L = Object.getOwnPropertyDescriptor(C, w);
|
|
22206
22210
|
if (L === void 0) {
|
|
22207
22211
|
var I = Object.getPrototypeOf(C);
|
|
22208
|
-
return I === null ? void 0 : x(I, w,
|
|
22212
|
+
return I === null ? void 0 : x(I, w, _);
|
|
22209
22213
|
} else {
|
|
22210
22214
|
if ("value" in L)
|
|
22211
22215
|
return L.value;
|
|
22212
22216
|
var Z = L.get;
|
|
22213
|
-
return Z === void 0 ? void 0 : Z.call(
|
|
22217
|
+
return Z === void 0 ? void 0 : Z.call(_);
|
|
22214
22218
|
}
|
|
22215
22219
|
}, b = n(35), s = l(b), v = n(5), h = l(v), u = n(9), a = l(u);
|
|
22216
22220
|
function l(x) {
|
|
@@ -22237,17 +22241,17 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
22237
22241
|
}
|
|
22238
22242
|
return d(C, null, [{
|
|
22239
22243
|
key: "create",
|
|
22240
|
-
value: function(
|
|
22241
|
-
var L = p(C.__proto__ || Object.getPrototypeOf(C), "create", this).call(this,
|
|
22242
|
-
return typeof
|
|
22244
|
+
value: function(_) {
|
|
22245
|
+
var L = p(C.__proto__ || Object.getPrototypeOf(C), "create", this).call(this, _);
|
|
22246
|
+
return typeof _ == "string" && (window.katex.render(_, L, {
|
|
22243
22247
|
throwOnError: !1,
|
|
22244
22248
|
errorColor: "#f00"
|
|
22245
|
-
}), L.setAttribute("data-value",
|
|
22249
|
+
}), L.setAttribute("data-value", _)), L;
|
|
22246
22250
|
}
|
|
22247
22251
|
}, {
|
|
22248
22252
|
key: "value",
|
|
22249
|
-
value: function(
|
|
22250
|
-
return
|
|
22253
|
+
value: function(_) {
|
|
22254
|
+
return _.getAttribute("data-value");
|
|
22251
22255
|
}
|
|
22252
22256
|
}]), C;
|
|
22253
22257
|
}(s.default);
|
|
@@ -22277,21 +22281,21 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
22277
22281
|
value: !0
|
|
22278
22282
|
}), r.default = r.CodeToken = r.CodeBlock = void 0;
|
|
22279
22283
|
var d = function() {
|
|
22280
|
-
function
|
|
22284
|
+
function _(L, I) {
|
|
22281
22285
|
for (var Z = 0; Z < I.length; Z++) {
|
|
22282
22286
|
var V = I[Z];
|
|
22283
22287
|
V.enumerable = V.enumerable || !1, V.configurable = !0, "value" in V && (V.writable = !0), Object.defineProperty(L, V.key, V);
|
|
22284
22288
|
}
|
|
22285
22289
|
}
|
|
22286
22290
|
return function(L, I, Z) {
|
|
22287
|
-
return I &&
|
|
22291
|
+
return I && _(L.prototype, I), Z && _(L, Z), L;
|
|
22288
22292
|
};
|
|
22289
|
-
}(), p = function
|
|
22293
|
+
}(), p = function _(L, I, Z) {
|
|
22290
22294
|
L === null && (L = Function.prototype);
|
|
22291
22295
|
var V = Object.getOwnPropertyDescriptor(L, I);
|
|
22292
22296
|
if (V === void 0) {
|
|
22293
22297
|
var H = Object.getPrototypeOf(L);
|
|
22294
|
-
return H === null ? void 0 :
|
|
22298
|
+
return H === null ? void 0 : _(H, I, Z);
|
|
22295
22299
|
} else {
|
|
22296
22300
|
if ("value" in V)
|
|
22297
22301
|
return V.value;
|
|
@@ -22299,25 +22303,25 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
22299
22303
|
return k === void 0 ? void 0 : k.call(Z);
|
|
22300
22304
|
}
|
|
22301
22305
|
}, b = n(0), s = m(b), v = n(5), h = m(v), u = n(9), a = m(u), l = n(13), y = m(l);
|
|
22302
|
-
function m(
|
|
22303
|
-
return
|
|
22306
|
+
function m(_) {
|
|
22307
|
+
return _ && _.__esModule ? _ : { default: _ };
|
|
22304
22308
|
}
|
|
22305
|
-
function c(
|
|
22306
|
-
if (!(
|
|
22309
|
+
function c(_, L) {
|
|
22310
|
+
if (!(_ instanceof L))
|
|
22307
22311
|
throw new TypeError("Cannot call a class as a function");
|
|
22308
22312
|
}
|
|
22309
|
-
function f(
|
|
22310
|
-
if (!
|
|
22313
|
+
function f(_, L) {
|
|
22314
|
+
if (!_)
|
|
22311
22315
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
22312
|
-
return L && (typeof L == "object" || typeof L == "function") ? L :
|
|
22316
|
+
return L && (typeof L == "object" || typeof L == "function") ? L : _;
|
|
22313
22317
|
}
|
|
22314
|
-
function g(
|
|
22318
|
+
function g(_, L) {
|
|
22315
22319
|
if (typeof L != "function" && L !== null)
|
|
22316
22320
|
throw new TypeError("Super expression must either be null or a function, not " + typeof L);
|
|
22317
|
-
|
|
22321
|
+
_.prototype = Object.create(L && L.prototype, { constructor: { value: _, enumerable: !1, writable: !0, configurable: !0 } }), L && (Object.setPrototypeOf ? Object.setPrototypeOf(_, L) : _.__proto__ = L);
|
|
22318
22322
|
}
|
|
22319
|
-
var x = function(
|
|
22320
|
-
g(L,
|
|
22323
|
+
var x = function(_) {
|
|
22324
|
+
g(L, _);
|
|
22321
22325
|
function L() {
|
|
22322
22326
|
return c(this, L), f(this, (L.__proto__ || Object.getPrototypeOf(L)).apply(this, arguments));
|
|
22323
22327
|
}
|
|
@@ -22337,8 +22341,8 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
22337
22341
|
x.className = "ql-syntax";
|
|
22338
22342
|
var C = new s.default.Attributor.Class("token", "hljs", {
|
|
22339
22343
|
scope: s.default.Scope.INLINE
|
|
22340
|
-
}), w = function(
|
|
22341
|
-
g(L,
|
|
22344
|
+
}), w = function(_) {
|
|
22345
|
+
g(L, _), d(L, null, [{
|
|
22342
22346
|
key: "register",
|
|
22343
22347
|
value: function() {
|
|
22344
22348
|
h.default.register(C, !0), h.default.register(x, !0);
|
|
@@ -22372,8 +22376,8 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
22372
22376
|
}(a.default);
|
|
22373
22377
|
w.DEFAULTS = {
|
|
22374
22378
|
highlight: function() {
|
|
22375
|
-
return window.hljs == null ? null : function(
|
|
22376
|
-
var L = window.hljs.highlightAuto(
|
|
22379
|
+
return window.hljs == null ? null : function(_) {
|
|
22380
|
+
var L = window.hljs.highlightAuto(_);
|
|
22377
22381
|
return L.value;
|
|
22378
22382
|
};
|
|
22379
22383
|
}(),
|
|
@@ -22596,7 +22600,7 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
22596
22600
|
return p(I, [{
|
|
22597
22601
|
key: "extendToolbar",
|
|
22598
22602
|
value: function(V) {
|
|
22599
|
-
this.tooltip = new
|
|
22603
|
+
this.tooltip = new _(this.quill, this.options.bounds), this.tooltip.root.appendChild(V.container), this.buildButtons([].slice.call(V.container.querySelectorAll("button")), m.default), this.buildPickers([].slice.call(V.container.querySelectorAll("select")), m.default);
|
|
22600
22604
|
}
|
|
22601
22605
|
}]), I;
|
|
22602
22606
|
}(a.default);
|
|
@@ -22611,7 +22615,7 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
22611
22615
|
}
|
|
22612
22616
|
}
|
|
22613
22617
|
});
|
|
22614
|
-
var
|
|
22618
|
+
var _ = function(L) {
|
|
22615
22619
|
x(I, L);
|
|
22616
22620
|
function I(Z, V) {
|
|
22617
22621
|
f(this, I);
|
|
@@ -22661,7 +22665,7 @@ var Vl = Hl, Y9 = { exports: {} };
|
|
|
22661
22665
|
}
|
|
22662
22666
|
}]), I;
|
|
22663
22667
|
}(u.BaseTooltip);
|
|
22664
|
-
|
|
22668
|
+
_.TEMPLATE = ['<span class="ql-tooltip-arrow"></span>', '<div class="ql-tooltip-editor">', '<input type="text" data-formula="e=mc^2" data-link="https://quilljs.com" data-video="Embed URL">', '<a class="ql-close"></a>', "</div>"].join(""), r.BubbleTooltip = _, r.default = w;
|
|
22665
22669
|
},
|
|
22666
22670
|
/* 109 */
|
|
22667
22671
|
/***/
|
|
@@ -23096,11 +23100,11 @@ const Pl = ({
|
|
|
23096
23100
|
}
|
|
23097
23101
|
const w = g.getLength();
|
|
23098
23102
|
w > 0 && g.deleteText(0, w);
|
|
23099
|
-
let
|
|
23103
|
+
let _ = 0;
|
|
23100
23104
|
const L = setInterval(() => {
|
|
23101
|
-
if (
|
|
23105
|
+
if (_ < C.length) {
|
|
23102
23106
|
const I = g.getLength();
|
|
23103
|
-
I > 0 ? g.insertText(I - 1, C[
|
|
23107
|
+
I > 0 ? g.insertText(I - 1, C[_]) : g.insertText(I, C[_]), _++;
|
|
23104
23108
|
} else
|
|
23105
23109
|
clearInterval(L);
|
|
23106
23110
|
}, 5);
|
|
@@ -23682,7 +23686,7 @@ const Pl = ({
|
|
|
23682
23686
|
justifyContent: "space-between",
|
|
23683
23687
|
alignItems: "center",
|
|
23684
23688
|
children: [
|
|
23685
|
-
/* @__PURE__ */ t(y1, { flexWrap: "wrap", gap: "4px", children: new Array(v).fill(null).map((
|
|
23689
|
+
/* @__PURE__ */ t(y1, { flexWrap: "wrap", gap: "4px", children: new Array(v).fill(null).map((_, L) => /* @__PURE__ */ t(
|
|
23686
23690
|
x5.div,
|
|
23687
23691
|
{
|
|
23688
23692
|
w: "12px",
|
|
@@ -24753,12 +24757,12 @@ function Dl(e) {
|
|
|
24753
24757
|
return !n.current || b.props.enableMultiContainer && k.containerId !== b.props.containerId || d.has(k.toastId) && k.updateId == null;
|
|
24754
24758
|
}(f))
|
|
24755
24759
|
return;
|
|
24756
|
-
const { toastId: g, updateId: x, data: C } = f, { props: w } = b,
|
|
24760
|
+
const { toastId: g, updateId: x, data: C } = f, { props: w } = b, _ = () => v(g), L = x == null;
|
|
24757
24761
|
L && b.count++;
|
|
24758
24762
|
const I = { ...w, style: w.toastStyle, key: b.toastKey++, ...Object.fromEntries(Object.entries(f).filter((k) => {
|
|
24759
24763
|
let [S, E] = k;
|
|
24760
24764
|
return E != null;
|
|
24761
|
-
})), toastId: g, updateId: x, data: C, closeToast:
|
|
24765
|
+
})), toastId: g, updateId: x, data: C, closeToast: _, isIn: !1, className: T2(f.className || w.toastClassName), bodyClassName: T2(f.bodyClassName || w.bodyClassName), progressClassName: T2(f.progressClassName || w.progressClassName), autoClose: !f.isLoading && (Z = f.autoClose, V = w.autoClose, Z === !1 || a2(Z) && Z > 0 ? Z : V), deleteToast() {
|
|
24762
24766
|
const k = A7(d.get(g), "removed");
|
|
24763
24767
|
d.delete(g), l5.emit(4, k);
|
|
24764
24768
|
const S = b.queue.length;
|
|
@@ -24782,7 +24786,7 @@ function Dl(e) {
|
|
|
24782
24786
|
return D === !1 || (Q1(D) ? z = D(Q) : N5(D) ? z = F3(D, Q) : E5(D) || a2(D) ? z = D : F ? z = T3.spinner() : ((X) => X in T3)(E) && (z = T3[E](Q))), z;
|
|
24783
24787
|
}(I), Q1(f.onOpen) && (I.onOpen = f.onOpen), Q1(f.onClose) && (I.onClose = f.onClose), I.closeButton = w.closeButton, f.closeButton === !1 || S3(f.closeButton) ? I.closeButton = f.closeButton : f.closeButton === !0 && (I.closeButton = !S3(w.closeButton) || w.closeButton);
|
|
24784
24788
|
let H = l;
|
|
24785
|
-
N5(l) && !E5(l.type) ? H = F3(l, { closeToast:
|
|
24789
|
+
N5(l) && !E5(l.type) ? H = F3(l, { closeToast: _, toastProps: I, data: C }) : Q1(l) && (H = l({ closeToast: _, toastProps: I, data: C })), w.limit && w.limit > 0 && b.count > w.limit && L ? b.queue.push({ toastContent: H, toastProps: I, staleId: c }) : a2(m) ? setTimeout(() => {
|
|
24786
24790
|
a(H, I, c);
|
|
24787
24791
|
}, m) : a(H, I, c);
|
|
24788
24792
|
}
|
|
@@ -24821,8 +24825,8 @@ function Gl(e) {
|
|
|
24821
24825
|
}
|
|
24822
24826
|
function y(C) {
|
|
24823
24827
|
if (p.boundingRect) {
|
|
24824
|
-
const { top: w, bottom:
|
|
24825
|
-
C.nativeEvent.type !== "touchend" && e.pauseOnHover && p.x >= L && p.x <= I && p.y >= w && p.y <=
|
|
24828
|
+
const { top: w, bottom: _, left: L, right: I } = p.boundingRect;
|
|
24829
|
+
C.nativeEvent.type !== "touchend" && e.pauseOnHover && p.x >= L && p.x <= I && p.y >= w && p.y <= _ ? c() : m();
|
|
24826
24830
|
}
|
|
24827
24831
|
}
|
|
24828
24832
|
function m() {
|
|
@@ -24873,9 +24877,9 @@ function jl(e) {
|
|
|
24873
24877
|
} });
|
|
24874
24878
|
}
|
|
24875
24879
|
const Wl = (e) => {
|
|
24876
|
-
const { isRunning: o, preventExitTransition: i, toastRef: r, eventHandlers: n } = Gl(e), { closeButton: d, children: p, autoClose: b, onClick: s, type: v, hideProgressBar: h, closeToast: u, transition: a, position: l, className: y, style: m, bodyClassName: c, bodyStyle: f, progressClassName: g, progressStyle: x, updateId: C, role: w, progress:
|
|
24880
|
+
const { isRunning: o, preventExitTransition: i, toastRef: r, eventHandlers: n } = Gl(e), { closeButton: d, children: p, autoClose: b, onClick: s, type: v, hideProgressBar: h, closeToast: u, transition: a, position: l, className: y, style: m, bodyClassName: c, bodyStyle: f, progressClassName: g, progressStyle: x, updateId: C, role: w, progress: _, rtl: L, toastId: I, deleteToast: Z, isIn: V, isLoading: H, iconOut: k, closeOnClick: S, theme: E } = e, F = I5("Toastify__toast", `Toastify__toast-theme--${E}`, `Toastify__toast--${v}`, { "Toastify__toast--rtl": L }, { "Toastify__toast--close-on-click": S }), D = Q1(y) ? y({ rtl: L, position: l, type: v, defaultClassName: F }) : I5(F, y), z = !!_ || !b, Q = { closeToast: u, type: v, theme: E };
|
|
24877
24881
|
let X = null;
|
|
24878
|
-
return d === !1 || (X = Q1(d) ? d(Q) : N5(d) ? F3(d, Q) : U9(Q)), O1.createElement(a, { isIn: V, done: Z, position: l, preventExitTransition: i, nodeRef: r }, O1.createElement("div", { id: I, onClick: s, className: D, ...n, style: m, ref: r }, O1.createElement("div", { ...V && { role: w }, className: Q1(c) ? c({ type: v }) : I5("Toastify__toast-body", c), style: f }, k != null && O1.createElement("div", { className: I5("Toastify__toast-icon", { "Toastify--animate-icon Toastify__zoom-enter": !H }) }, k), O1.createElement("div", null, p)), X, O1.createElement(jl, { ...C && !z ? { key: `pb-${C}` } : {}, rtl: L, theme: E, delay: b, isRunning: o, isIn: V, closeToast: u, hide: h, type: v, style: x, className: g, controlledProgress: z, progress:
|
|
24882
|
+
return d === !1 || (X = Q1(d) ? d(Q) : N5(d) ? F3(d, Q) : U9(Q)), O1.createElement(a, { isIn: V, done: Z, position: l, preventExitTransition: i, nodeRef: r }, O1.createElement("div", { id: I, onClick: s, className: D, ...n, style: m, ref: r }, O1.createElement("div", { ...V && { role: w }, className: Q1(c) ? c({ type: v }) : I5("Toastify__toast-body", c), style: f }, k != null && O1.createElement("div", { className: I5("Toastify__toast-icon", { "Toastify--animate-icon Toastify__zoom-enter": !H }) }, k), O1.createElement("div", null, p)), X, O1.createElement(jl, { ...C && !z ? { key: `pb-${C}` } : {}, rtl: L, theme: E, delay: b, isRunning: o, isIn: V, closeToast: u, hide: h, type: v, style: x, className: g, controlledProgress: z, progress: _ || 0 })));
|
|
24879
24883
|
}, u3 = function(e, o) {
|
|
24880
24884
|
return o === void 0 && (o = !1), { enter: `Toastify--animate Toastify__${e}-enter`, exit: `Toastify--animate Toastify__${e}-exit`, appendPosition: o };
|
|
24881
24885
|
}, zl = s3(u3("bounce", !0)), Xl = s3(u3("slide", !0));
|