@strands.gg/accui 2.17.48 → 2.17.49
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{StrandsUIPlugin-Po7_Snlv.es.js → StrandsUIPlugin-CSsUxobq.es.js} +509 -487
- package/dist/{StrandsUIPlugin-7aDynSMv.cjs.js → StrandsUIPlugin-fvlbvZ-P.cjs.js} +22 -22
- package/dist/accui.css +1 -1
- package/dist/index.cjs.js +1 -1
- package/dist/index.es.js +3 -3
- package/dist/vite.cjs.js +1 -1
- package/dist/vite.es.js +1 -1
- package/package.json +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { defineComponent as ae, computed as L, createElementBlock as T, openBlock as C, createElementVNode as $, normalizeClass as X, createCommentVNode as W, toDisplayString as ee, renderSlot as E, createTextVNode as Ve, unref as R, normalizeStyle as Le, useSlots as xn, createVNode as z, Fragment as be, withCtx as N, getCurrentInstance as ta, createBlock as Z, resolveDynamicComponent as In, ref as _, onUnmounted as wn, mergeProps as Dn, Teleport as hi, nextTick as $e, normalizeProps as jd, createSlots as Xe, useAttrs as qd, resolveComponent as Co, h as Kt, onMounted as er, withModifiers as cn, renderList as Je, watch as ht, toRefs as Ud, withDirectives as Mo, vModelSelect as To, watchEffect as Wd, onBeforeUnmount as Ds, shallowRef as Kd, markRaw as Jd, customRef as Gd, useCssVars as Yd } from "vue";
|
|
2
|
-
const
|
|
2
|
+
const Oe = (n, e) => {
|
|
3
3
|
const t = n.__vccOpts || n;
|
|
4
4
|
for (const [r, i] of e)
|
|
5
5
|
t[r] = i;
|
|
@@ -85,7 +85,7 @@ const Ae = (n, e) => {
|
|
|
85
85
|
], 2)
|
|
86
86
|
]));
|
|
87
87
|
}
|
|
88
|
-
}), na = /* @__PURE__ */
|
|
88
|
+
}), na = /* @__PURE__ */ Oe(ru, [["__scopeId", "data-v-68f69cce"]]), iu = `<svg width="302" height="438" viewBox="0 0 302 438" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
89
89
|
<path d="M71.5001 96C71.5001 96 132 106 137 61.5C142 17 117.5 3.50005 94.5001 1.50003C71.5001 -0.499996 16.0001 8.5 2.00014 72.5C-6.5 130.5 71.5003 227.5 165 218C258.5 208.5 280.758 148.5 283.5 121C286.242 93.5 277.5 61.5 238.5 61.5C153 61.5 150.501 185 170.5 235C190.5 285 199 279 213 314C227.001 349 217.296 411.458 183 427C129.456 450.65 92 426 78.5 407.5C65 389 68.0003 357 94.5001 344.5C121 332 212.41 393.5 301.5 361" stroke="black"/>
|
|
90
90
|
</svg>
|
|
91
91
|
`, su = {
|
|
@@ -185,7 +185,7 @@ const Ae = (n, e) => {
|
|
|
185
185
|
n.text ? (C(), T("p", uu, ee(n.text), 1)) : W("", !0)
|
|
186
186
|
], 2));
|
|
187
187
|
}
|
|
188
|
-
}), $s = /* @__PURE__ */
|
|
188
|
+
}), $s = /* @__PURE__ */ Oe(fu, [["__scopeId", "data-v-4b565c5d"]]), hu = {
|
|
189
189
|
key: 0,
|
|
190
190
|
class: "button-loading-content"
|
|
191
191
|
}, pu = { key: 0 }, mu = {
|
|
@@ -251,7 +251,7 @@ const Ae = (n, e) => {
|
|
|
251
251
|
], 64))
|
|
252
252
|
], 2));
|
|
253
253
|
}
|
|
254
|
-
}), Sr = /* @__PURE__ */
|
|
254
|
+
}), Sr = /* @__PURE__ */ Oe(bu, [["__scopeId", "data-v-12d1d1fc"]]), ku = ["href", "target", "rel"], Eo = /* @__PURE__ */ ae({
|
|
255
255
|
__name: "UiButton.Anchor",
|
|
256
256
|
props: {
|
|
257
257
|
to: {},
|
|
@@ -467,7 +467,7 @@ const Ae = (n, e) => {
|
|
|
467
467
|
]))
|
|
468
468
|
], 16));
|
|
469
469
|
}
|
|
470
|
-
}), wu = /* @__PURE__ */
|
|
470
|
+
}), wu = /* @__PURE__ */ Oe(xu, [["__scopeId", "data-v-ba66edda"]]), Su = ["type", "disabled", "tabindex"], Cu = ["type", "disabled", "tabindex"], Mu = /* @__PURE__ */ ae({
|
|
471
471
|
inheritAttrs: !1,
|
|
472
472
|
__name: "UiButton",
|
|
473
473
|
props: {
|
|
@@ -738,7 +738,7 @@ const Ae = (n, e) => {
|
|
|
738
738
|
], 16, Cu))
|
|
739
739
|
], 64));
|
|
740
740
|
}
|
|
741
|
-
}), re = /* @__PURE__ */
|
|
741
|
+
}), re = /* @__PURE__ */ Oe(Mu, [["__scopeId", "data-v-a6756518"]]), Tu = {
|
|
742
742
|
key: 0,
|
|
743
743
|
class: "ui-card-header"
|
|
744
744
|
}, Eu = {
|
|
@@ -822,7 +822,7 @@ const Ae = (n, e) => {
|
|
|
822
822
|
_: 3
|
|
823
823
|
}, 8, ["to", "href", "class"]));
|
|
824
824
|
}
|
|
825
|
-
}), ra = /* @__PURE__ */
|
|
825
|
+
}), ra = /* @__PURE__ */ Oe(Du, [["__scopeId", "data-v-87ba4932"]]);
|
|
826
826
|
const Oo = (n) => n.replace(/([a-z0-9])([A-Z])/g, "$1-$2").toLowerCase(), $u = (n) => n.replace(
|
|
827
827
|
/^([A-Z])|[\s-_]+(\w)/g,
|
|
828
828
|
(e, t, r) => r ? r.toUpperCase() : t.toLowerCase()
|
|
@@ -1173,7 +1173,7 @@ const Ls = oe("x", [
|
|
|
1173
1173
|
E(g.$slots, "trailing", {}, void 0, !0)
|
|
1174
1174
|
], 2));
|
|
1175
1175
|
}
|
|
1176
|
-
}), yf = /* @__PURE__ */
|
|
1176
|
+
}), yf = /* @__PURE__ */ Oe(gf, [["__scopeId", "data-v-4807b700"]]), bf = {
|
|
1177
1177
|
key: 0,
|
|
1178
1178
|
class: "input-leading-icon"
|
|
1179
1179
|
}, kf = ["id", "value", "placeholder", "disabled", "readonly", "required", "rows", "cols", "maxlength", "autocomplete", "spellcheck"], vf = {
|
|
@@ -1278,7 +1278,7 @@ const Ls = oe("x", [
|
|
|
1278
1278
|
], 512)) : W("", !0)
|
|
1279
1279
|
], 2));
|
|
1280
1280
|
}
|
|
1281
|
-
}), wf = /* @__PURE__ */
|
|
1281
|
+
}), wf = /* @__PURE__ */ Oe(xf, [["__scopeId", "data-v-5728c58e"]]);
|
|
1282
1282
|
function Ps(n) {
|
|
1283
1283
|
const {
|
|
1284
1284
|
trigger: e,
|
|
@@ -1711,7 +1711,7 @@ const Sf = {
|
|
|
1711
1711
|
], 8, ["to"]))
|
|
1712
1712
|
], 64));
|
|
1713
1713
|
}
|
|
1714
|
-
}), Bf = /* @__PURE__ */
|
|
1714
|
+
}), Bf = /* @__PURE__ */ Oe(zf, [["__scopeId", "data-v-e9ac7d68"]]), Vf = { class: "input-leading-icon" }, Ff = ["src"], Hf = ["id", "accept", "multiple", "disabled", "required"], jf = { class: "input-file-content" }, qf = {
|
|
1715
1715
|
key: 0,
|
|
1716
1716
|
class: "input-file-selected"
|
|
1717
1717
|
}, Uf = { class: "input-file-list" }, Wf = { class: "input-file-item" }, Kf = { class: "input-file-name" }, Jf = {
|
|
@@ -1904,7 +1904,7 @@ const Sf = {
|
|
|
1904
1904
|
E(M.$slots, "trailing", {}, void 0, !0)
|
|
1905
1905
|
], 2));
|
|
1906
1906
|
}
|
|
1907
|
-
}), ih = /* @__PURE__ */
|
|
1907
|
+
}), ih = /* @__PURE__ */ Oe(rh, [["__scopeId", "data-v-3c7bee41"]]), sh = { class: "tabs-wrapper" }, oh = {
|
|
1908
1908
|
key: 0,
|
|
1909
1909
|
class: "tabs-before"
|
|
1910
1910
|
}, lh = ["aria-selected", "id", "onClick"], ah = {
|
|
@@ -2202,7 +2202,7 @@ const Sf = {
|
|
|
2202
2202
|
], 10, ch)) : W("", !0)
|
|
2203
2203
|
], 2));
|
|
2204
2204
|
}
|
|
2205
|
-
}), zs = /* @__PURE__ */
|
|
2205
|
+
}), zs = /* @__PURE__ */ Oe(dh, [["__scopeId", "data-v-901716e3"]]), uh = {
|
|
2206
2206
|
key: 0,
|
|
2207
2207
|
class: "ui-divider-text"
|
|
2208
2208
|
}, fh = /* @__PURE__ */ ae({
|
|
@@ -2241,7 +2241,7 @@ const Sf = {
|
|
|
2241
2241
|
])) : W("", !0)
|
|
2242
2242
|
], 6));
|
|
2243
2243
|
}
|
|
2244
|
-
}), Lt = /* @__PURE__ */
|
|
2244
|
+
}), Lt = /* @__PURE__ */ Oe(fh, [["__scopeId", "data-v-1c798024"]]), hh = { class: "datetime-picker-wrapper" }, ph = { class: "datetime-picker-leading-icon" }, mh = { class: "datetime-picker-display" }, gh = {
|
|
2245
2245
|
key: 0,
|
|
2246
2246
|
class: "datetime-picker-value"
|
|
2247
2247
|
}, yh = {
|
|
@@ -2706,7 +2706,7 @@ const Sf = {
|
|
|
2706
2706
|
]))
|
|
2707
2707
|
]));
|
|
2708
2708
|
}
|
|
2709
|
-
}), Bs = /* @__PURE__ */
|
|
2709
|
+
}), Bs = /* @__PURE__ */ Oe(Lh, [["__scopeId", "data-v-f688c330"]]), Ph = /* @__PURE__ */ ae({
|
|
2710
2710
|
__name: "UiInput.Date",
|
|
2711
2711
|
props: {
|
|
2712
2712
|
min: {},
|
|
@@ -8471,7 +8471,7 @@ function fm(n, e, t) {
|
|
|
8471
8471
|
return { node: r.startContainer, offset: Math.min(Ge(r.startContainer), r.startOffset) };
|
|
8472
8472
|
}
|
|
8473
8473
|
}
|
|
8474
|
-
const st = typeof navigator < "u" ? navigator : null, Zo = typeof document < "u" ? document : null, _t = st && st.userAgent || "", cs = /Edge\/(\d+)/.exec(_t), Ua = /MSIE \d/.exec(_t), ds = /Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(_t), He = !!(Ua || ds || cs), Et = Ua ? document.documentMode : ds ? +ds[1] : cs ? +cs[1] : 0, tt = !He && /gecko\/(\d+)/i.test(_t), us = !He && /Chrome\/(\d+)/.exec(_t), we = !!us, Wa = us ? +us[1] : 0,
|
|
8474
|
+
const st = typeof navigator < "u" ? navigator : null, Zo = typeof document < "u" ? document : null, _t = st && st.userAgent || "", cs = /Edge\/(\d+)/.exec(_t), Ua = /MSIE \d/.exec(_t), ds = /Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(_t), He = !!(Ua || ds || cs), Et = Ua ? document.documentMode : ds ? +ds[1] : cs ? +cs[1] : 0, tt = !He && /gecko\/(\d+)/i.test(_t), us = !He && /Chrome\/(\d+)/.exec(_t), we = !!us, Wa = us ? +us[1] : 0, Ae = !He && !!st && /Apple Computer/.test(st.vendor), yn = Ae && (/Mobile\/\w+/.test(_t) || !!st && st.maxTouchPoints > 2), Ke = yn || (st ? /Mac/.test(st.platform) : !1), Ka = st ? /Win/.test(st.platform) : !1, ft = /Android \d/.test(_t), nr = !!Zo && "webkitFontSmoothing" in Zo.documentElement.style, hm = nr ? +(/\bAppleWebKit\/(\d+)/.exec(navigator.userAgent) || [0, 0])[1] : 0;
|
|
8475
8475
|
function pm(n) {
|
|
8476
8476
|
let e = n.defaultView && n.defaultView.visualViewport;
|
|
8477
8477
|
return e ? {
|
|
@@ -8659,7 +8659,7 @@ function Sm(n, e) {
|
|
|
8659
8659
|
if (!Ws(e, c) || (o = Qa(n.dom, e, c), !o))
|
|
8660
8660
|
return null;
|
|
8661
8661
|
}
|
|
8662
|
-
if (
|
|
8662
|
+
if (Ae)
|
|
8663
8663
|
for (let c = o; r && c; c = gn(c))
|
|
8664
8664
|
c.draggable && (r = void 0);
|
|
8665
8665
|
if (o = vm(o, e), r) {
|
|
@@ -9067,7 +9067,7 @@ class rr {
|
|
|
9067
9067
|
p = g;
|
|
9068
9068
|
}
|
|
9069
9069
|
let l = this.domFromPos(e, e ? -1 : 1), a = t == e ? l : this.domFromPos(t, t ? -1 : 1), c = r.root.getSelection(), d = r.domSelectionRange(), u = !1;
|
|
9070
|
-
if ((tt ||
|
|
9070
|
+
if ((tt || Ae) && e == t) {
|
|
9071
9071
|
let { node: h, offset: p } = l;
|
|
9072
9072
|
if (h.nodeType == 3) {
|
|
9073
9073
|
if (u = !!(p && h.nodeValue[p - 1] == `
|
|
@@ -9090,7 +9090,7 @@ class rr {
|
|
|
9090
9090
|
let h = d.focusNode.childNodes[d.focusOffset];
|
|
9091
9091
|
h && h.contentEditable == "false" && (i = !0);
|
|
9092
9092
|
}
|
|
9093
|
-
if (!(i || u &&
|
|
9093
|
+
if (!(i || u && Ae) && Yt(l.node, l.offset, d.anchorNode, d.anchorOffset) && Yt(a.node, a.offset, d.focusNode, d.focusOffset))
|
|
9094
9094
|
return;
|
|
9095
9095
|
let f = !1;
|
|
9096
9096
|
if ((c.extend || e == t) && !(u && tt)) {
|
|
@@ -9314,12 +9314,12 @@ class At extends rr {
|
|
|
9314
9314
|
updateChildren(e, t) {
|
|
9315
9315
|
let r = this.node.inlineContent, i = t, s = e.composing ? this.localCompositionInfo(e, t) : null, o = s && s.pos > -1 ? s : null, l = s && s.pos < 0, a = new Dm(this, o && o.node, e);
|
|
9316
9316
|
Lm(this.node, this.innerDeco, (c, d, u) => {
|
|
9317
|
-
c.spec.marks ? a.syncToMarks(c.spec.marks, r, e) : c.type.side >= 0 && !u && a.syncToMarks(d == this.node.childCount ? le.none : this.node.child(d).marks, r, e), a.placeWidget(c, e, i);
|
|
9317
|
+
c.spec.marks ? a.syncToMarks(c.spec.marks, r, e, d) : c.type.side >= 0 && !u && a.syncToMarks(d == this.node.childCount ? le.none : this.node.child(d).marks, r, e, d), a.placeWidget(c, e, i);
|
|
9318
9318
|
}, (c, d, u, f) => {
|
|
9319
|
-
a.syncToMarks(c.marks, r, e);
|
|
9319
|
+
a.syncToMarks(c.marks, r, e, f);
|
|
9320
9320
|
let h;
|
|
9321
9321
|
a.findNodeMatch(c, d, u, f) || l && e.state.selection.from > i && e.state.selection.to < i + c.nodeSize && (h = a.findIndexWithChild(s.node)) > -1 && a.updateNodeAt(c, d, u, h, e) || a.updateNextNode(c, d, u, e, f, i) || a.addNode(c, d, u, e, i), i += c.nodeSize;
|
|
9322
|
-
}), a.syncToMarks([], r, e), this.node.isTextblock && a.addTextblockHacks(), a.destroyRest(), (a.changed || this.dirty == zt) && (o && this.protectLocalComposition(e, o), tc(this.contentDOM, this.children, e), yn && Pm(this.dom));
|
|
9322
|
+
}), a.syncToMarks([], r, e, 0), this.node.isTextblock && a.addTextblockHacks(), a.destroyRest(), (a.changed || this.dirty == zt) && (o && this.protectLocalComposition(e, o), tc(this.contentDOM, this.children, e), yn && Pm(this.dom));
|
|
9323
9323
|
}
|
|
9324
9324
|
localCompositionInfo(e, t) {
|
|
9325
9325
|
let { from: r, to: i } = e.state.selection;
|
|
@@ -9580,29 +9580,30 @@ class Dm {
|
|
|
9580
9580
|
}
|
|
9581
9581
|
// Sync the current stack of mark descs with the given array of
|
|
9582
9582
|
// marks, reusing existing mark descs when possible.
|
|
9583
|
-
syncToMarks(e, t, r) {
|
|
9584
|
-
let
|
|
9585
|
-
for (;
|
|
9586
|
-
|
|
9587
|
-
for (;
|
|
9588
|
-
this.destroyRest(), this.top.dirty = Qe, this.index = this.stack.pop(), this.top = this.stack.pop(),
|
|
9589
|
-
for (;
|
|
9583
|
+
syncToMarks(e, t, r, i) {
|
|
9584
|
+
let s = 0, o = this.stack.length >> 1, l = Math.min(o, e.length);
|
|
9585
|
+
for (; s < l && (s == o - 1 ? this.top : this.stack[s + 1 << 1]).matchesMark(e[s]) && e[s].type.spec.spanning !== !1; )
|
|
9586
|
+
s++;
|
|
9587
|
+
for (; s < o; )
|
|
9588
|
+
this.destroyRest(), this.top.dirty = Qe, this.index = this.stack.pop(), this.top = this.stack.pop(), o--;
|
|
9589
|
+
for (; o < e.length; ) {
|
|
9590
9590
|
this.stack.push(this.top, this.index + 1);
|
|
9591
|
-
let
|
|
9592
|
-
|
|
9593
|
-
|
|
9594
|
-
|
|
9595
|
-
|
|
9591
|
+
let a = -1, c = this.top.children.length;
|
|
9592
|
+
i < this.preMatch.index && (c = Math.min(this.index + 3, c));
|
|
9593
|
+
for (let d = this.index; d < c; d++) {
|
|
9594
|
+
let u = this.top.children[d];
|
|
9595
|
+
if (u.matchesMark(e[o]) && !this.isLocked(u.dom)) {
|
|
9596
|
+
a = d;
|
|
9596
9597
|
break;
|
|
9597
9598
|
}
|
|
9598
9599
|
}
|
|
9599
|
-
if (
|
|
9600
|
-
|
|
9600
|
+
if (a > -1)
|
|
9601
|
+
a > this.index && (this.changed = !0, this.destroyBetween(this.index, a)), this.top = this.top.children[this.index];
|
|
9601
9602
|
else {
|
|
9602
|
-
let
|
|
9603
|
-
this.top.children.splice(this.index, 0,
|
|
9603
|
+
let d = Qt.create(this.top, e[o], t, r);
|
|
9604
|
+
this.top.children.splice(this.index, 0, d), this.top = d, this.changed = !0;
|
|
9604
9605
|
}
|
|
9605
|
-
this.index = 0,
|
|
9606
|
+
this.index = 0, o++;
|
|
9606
9607
|
}
|
|
9607
9608
|
}
|
|
9608
9609
|
// Try to find a node desc matching the given data. Skip over it and
|
|
@@ -9695,7 +9696,7 @@ class Dm {
|
|
|
9695
9696
|
for (; e instanceof Qt; )
|
|
9696
9697
|
t = e, e = t.children[t.children.length - 1];
|
|
9697
9698
|
(!e || // Empty textblock
|
|
9698
|
-
!(e instanceof ki) || /\n$/.test(e.node.text) || this.view.requiresGeckoHackNode && /\s$/.test(e.node.text)) && ((
|
|
9699
|
+
!(e instanceof ki) || /\n$/.test(e.node.text) || this.view.requiresGeckoHackNode && /\s$/.test(e.node.text)) && ((Ae || we) && e && e.dom.contentEditable == "false" && this.addHackNode("IMG", t), this.addHackNode("BR", this.top));
|
|
9699
9700
|
}
|
|
9700
9701
|
addHackNode(e, t) {
|
|
9701
9702
|
if (t == this.top && this.index < t.children.length && t.children[this.index].matchesHack(e))
|
|
@@ -9887,10 +9888,10 @@ function pt(n, e = !1) {
|
|
|
9887
9888
|
n.domObserver.setCurSelection(), n.domObserver.connectSelection();
|
|
9888
9889
|
}
|
|
9889
9890
|
}
|
|
9890
|
-
const ll =
|
|
9891
|
+
const ll = Ae || we && Wa < 63;
|
|
9891
9892
|
function al(n, e) {
|
|
9892
9893
|
let { node: t, offset: r } = n.docView.domFromPos(e, 0), i = r < t.childNodes.length ? t.childNodes[r] : null, s = r ? t.childNodes[r - 1] : null;
|
|
9893
|
-
if (
|
|
9894
|
+
if (Ae && i && i.contentEditable == "false")
|
|
9894
9895
|
return Vi(i);
|
|
9895
9896
|
if ((!i || i.contentEditable == "false") && (!s || s.contentEditable == "false")) {
|
|
9896
9897
|
if (i)
|
|
@@ -9900,7 +9901,7 @@ function al(n, e) {
|
|
|
9900
9901
|
}
|
|
9901
9902
|
}
|
|
9902
9903
|
function Vi(n) {
|
|
9903
|
-
return n.contentEditable = "true",
|
|
9904
|
+
return n.contentEditable = "true", Ae && n.draggable && (n.draggable = !1, n.wasDraggable = !0), n;
|
|
9904
9905
|
}
|
|
9905
9906
|
function cl(n) {
|
|
9906
9907
|
n.contentEditable = "false", n.wasDraggable && (n.draggable = !0, n.wasDraggable = null);
|
|
@@ -10167,7 +10168,7 @@ function gl(n, e, t) {
|
|
|
10167
10168
|
n.domObserver.stop(), e.contentEditable = t, n.domObserver.start();
|
|
10168
10169
|
}
|
|
10169
10170
|
function Wm(n) {
|
|
10170
|
-
if (!
|
|
10171
|
+
if (!Ae || n.state.selection.$head.parentOffset > 0)
|
|
10171
10172
|
return !1;
|
|
10172
10173
|
let { focusNode: e, focusOffset: t } = n.domSelectionRange();
|
|
10173
10174
|
if (e && e.nodeType == 1 && t == 0 && e.firstChild && e.firstChild.contentEditable == "false") {
|
|
@@ -10397,7 +10398,7 @@ function _m(n, e) {
|
|
|
10397
10398
|
const Pe = {}, ze = {}, eg = { touchstart: !0, touchmove: !0 };
|
|
10398
10399
|
class tg {
|
|
10399
10400
|
constructor() {
|
|
10400
|
-
this.shiftKey = !1, this.mouseDown = null, this.lastKeyCode = null, this.lastKeyCodeTime = 0, this.lastClick = { time: 0, x: 0, y: 0, type: "", button: 0 }, this.lastSelectionOrigin = null, this.lastSelectionTime = 0, this.lastIOSEnter = 0, this.lastIOSEnterFallbackTimeout = -1, this.lastFocus = 0, this.lastTouch = 0, this.lastChromeDelete = 0, this.composing = !1, this.compositionNode = null, this.composingTimeout = -1, this.compositionNodes = [], this.compositionEndedAt = -2e8, this.compositionID = 1, this.compositionPendingChanges = 0, this.domChangeCount = 0, this.eventHandlers = /* @__PURE__ */ Object.create(null), this.hideSelectionGuard = null;
|
|
10401
|
+
this.shiftKey = !1, this.mouseDown = null, this.lastKeyCode = null, this.lastKeyCodeTime = 0, this.lastClick = { time: 0, x: 0, y: 0, type: "", button: 0 }, this.lastSelectionOrigin = null, this.lastSelectionTime = 0, this.lastIOSEnter = 0, this.lastIOSEnterFallbackTimeout = -1, this.lastFocus = 0, this.lastTouch = 0, this.lastChromeDelete = 0, this.composing = !1, this.compositionNode = null, this.composingTimeout = -1, this.compositionNodes = [], this.compositionEndedAt = -2e8, this.compositionID = 1, this.badSafariComposition = !1, this.compositionPendingChanges = 0, this.domChangeCount = 0, this.eventHandlers = /* @__PURE__ */ Object.create(null), this.hideSelectionGuard = null;
|
|
10401
10402
|
}
|
|
10402
10403
|
}
|
|
10403
10404
|
function ng(n) {
|
|
@@ -10407,7 +10408,7 @@ function ng(n) {
|
|
|
10407
10408
|
ig(n, r) && !Ys(n, r) && (n.editable || !(r.type in ze)) && t(n, r);
|
|
10408
10409
|
}, eg[e] ? { passive: !0 } : void 0);
|
|
10409
10410
|
}
|
|
10410
|
-
|
|
10411
|
+
Ae && n.dom.addEventListener("input", () => null), ys(n);
|
|
10411
10412
|
}
|
|
10412
10413
|
function Mt(n, e) {
|
|
10413
10414
|
n.input.lastSelectionOrigin = e, n.input.lastSelectionTime = Date.now();
|
|
@@ -10582,7 +10583,7 @@ class hg {
|
|
|
10582
10583
|
return;
|
|
10583
10584
|
let t = this.pos;
|
|
10584
10585
|
this.view.state.doc != this.startDoc && (t = this.view.posAtCoords(vi(e))), this.updateAllowDefault(e), this.allowDefault || !t ? Mt(this.view, "pointer") : cg(this.view, t.pos, t.inside, e, this.selectNode) ? e.preventDefault() : e.button == 0 && (this.flushed || // Safari ignores clicks on draggable elements
|
|
10585
|
-
|
|
10586
|
+
Ae && this.mightDrag && !this.mightDrag.node.isAtom || // Chrome will sometimes treat a node selection as a
|
|
10586
10587
|
// cursor, but still report that the node is selected
|
|
10587
10588
|
// when asked through getSelection. You'll then get a
|
|
10588
10589
|
// situation where clicking at the point where that
|
|
@@ -10606,7 +10607,7 @@ Pe.touchmove = (n) => {
|
|
|
10606
10607
|
};
|
|
10607
10608
|
Pe.contextmenu = (n) => Xs(n);
|
|
10608
10609
|
function mc(n, e) {
|
|
10609
|
-
return n.composing ? !0 :
|
|
10610
|
+
return n.composing ? !0 : Ae && Math.abs(e.timeStamp - n.input.compositionEndedAt) < 500 ? (n.input.compositionEndedAt = -2e8, !0) : !1;
|
|
10610
10611
|
}
|
|
10611
10612
|
const pg = ft ? 5e3 : -1;
|
|
10612
10613
|
ze.compositionstart = ze.compositionupdate = (n) => {
|
|
@@ -10641,7 +10642,7 @@ function mg(n) {
|
|
|
10641
10642
|
return r.nodeType == 1 && r.contentEditable == "false";
|
|
10642
10643
|
}
|
|
10643
10644
|
ze.compositionend = (n, e) => {
|
|
10644
|
-
n.composing && (n.input.composing = !1, n.input.compositionEndedAt = e.timeStamp, n.input.compositionPendingChanges = n.domObserver.pendingRecords().length ? n.input.compositionID : 0, n.input.compositionNode = null, n.input.compositionPendingChanges && Promise.resolve().then(() => n.domObserver.flush()), n.input.compositionID++, gc(n, 20));
|
|
10645
|
+
n.composing && (n.input.composing = !1, n.input.compositionEndedAt = e.timeStamp, n.input.compositionPendingChanges = n.domObserver.pendingRecords().length ? n.input.compositionID : 0, n.input.compositionNode = null, n.input.badSafariComposition ? n.domObserver.forceFlush() : n.input.compositionPendingChanges && Promise.resolve().then(() => n.domObserver.flush()), n.input.compositionID++, gc(n, 20));
|
|
10645
10646
|
};
|
|
10646
10647
|
function gc(n, e) {
|
|
10647
10648
|
clearTimeout(n.input.composingTimeout), e > -1 && (n.input.composingTimeout = setTimeout(() => Ir(n), e));
|
|
@@ -10991,7 +10992,7 @@ class de {
|
|
|
10991
10992
|
you must make a copy if you want need to preserve that.
|
|
10992
10993
|
*/
|
|
10993
10994
|
static create(e, t) {
|
|
10994
|
-
return t.length ? $r(t, e, 0, qt) :
|
|
10995
|
+
return t.length ? $r(t, e, 0, qt) : Ne;
|
|
10995
10996
|
}
|
|
10996
10997
|
/**
|
|
10997
10998
|
Find all decorations in this set which touch the given range
|
|
@@ -11021,7 +11022,7 @@ class de {
|
|
|
11021
11022
|
document.
|
|
11022
11023
|
*/
|
|
11023
11024
|
map(e, t, r) {
|
|
11024
|
-
return this ==
|
|
11025
|
+
return this == Ne || e.maps.length == 0 ? this : this.mapInner(e, t, 0, 0, r || qt);
|
|
11025
11026
|
}
|
|
11026
11027
|
/**
|
|
11027
11028
|
@internal
|
|
@@ -11032,7 +11033,7 @@ class de {
|
|
|
11032
11033
|
let a = this.local[l].map(e, r, i);
|
|
11033
11034
|
a && a.type.valid(t, a) ? (o || (o = [])).push(a) : s.onRemove && s.onRemove(this.local[l].spec);
|
|
11034
11035
|
}
|
|
11035
|
-
return this.children.length ? Sg(this.children, o || [], e, t, r, i, s) : o ? new de(o.sort(Ut), on) :
|
|
11036
|
+
return this.children.length ? Sg(this.children, o || [], e, t, r, i, s) : o ? new de(o.sort(Ut), on) : Ne;
|
|
11036
11037
|
}
|
|
11037
11038
|
/**
|
|
11038
11039
|
Add the given array of decorations to the ones in the set,
|
|
@@ -11041,7 +11042,7 @@ class de {
|
|
|
11041
11042
|
structure.
|
|
11042
11043
|
*/
|
|
11043
11044
|
add(e, t) {
|
|
11044
|
-
return t.length ? this ==
|
|
11045
|
+
return t.length ? this == Ne ? de.create(e, t) : this.addInner(e, t, 0) : this;
|
|
11045
11046
|
}
|
|
11046
11047
|
addInner(e, t, r) {
|
|
11047
11048
|
let i, s = 0;
|
|
@@ -11063,7 +11064,7 @@ class de {
|
|
|
11063
11064
|
the ones in the given array.
|
|
11064
11065
|
*/
|
|
11065
11066
|
remove(e) {
|
|
11066
|
-
return e.length == 0 || this ==
|
|
11067
|
+
return e.length == 0 || this == Ne ? this : this.removeInner(e, 0);
|
|
11067
11068
|
}
|
|
11068
11069
|
removeInner(e, t) {
|
|
11069
11070
|
let r = this.children, i = this.local;
|
|
@@ -11075,7 +11076,7 @@ class de {
|
|
|
11075
11076
|
continue;
|
|
11076
11077
|
r == this.children && (r = this.children.slice());
|
|
11077
11078
|
let c = r[s + 2].removeInner(o, l + 1);
|
|
11078
|
-
c !=
|
|
11079
|
+
c != Ne ? r[s + 2] = c : (r.splice(s, 3), s -= 3);
|
|
11079
11080
|
}
|
|
11080
11081
|
if (i.length) {
|
|
11081
11082
|
for (let s = 0, o; s < e.length; s++)
|
|
@@ -11083,10 +11084,10 @@ class de {
|
|
|
11083
11084
|
for (let l = 0; l < i.length; l++)
|
|
11084
11085
|
i[l].eq(o, t) && (i == this.local && (i = this.local.slice()), i.splice(l--, 1));
|
|
11085
11086
|
}
|
|
11086
|
-
return r == this.children && i == this.local ? this : i.length || r.length ? new de(i, r) :
|
|
11087
|
+
return r == this.children && i == this.local ? this : i.length || r.length ? new de(i, r) : Ne;
|
|
11087
11088
|
}
|
|
11088
11089
|
forChild(e, t) {
|
|
11089
|
-
if (this ==
|
|
11090
|
+
if (this == Ne)
|
|
11090
11091
|
return this;
|
|
11091
11092
|
if (t.isLeaf)
|
|
11092
11093
|
return de.empty;
|
|
@@ -11108,7 +11109,7 @@ class de {
|
|
|
11108
11109
|
let l = new de(i.sort(Ut), on);
|
|
11109
11110
|
return r ? new xt([l, r]) : l;
|
|
11110
11111
|
}
|
|
11111
|
-
return r ||
|
|
11112
|
+
return r || Ne;
|
|
11112
11113
|
}
|
|
11113
11114
|
/**
|
|
11114
11115
|
@internal
|
|
@@ -11136,7 +11137,7 @@ class de {
|
|
|
11136
11137
|
@internal
|
|
11137
11138
|
*/
|
|
11138
11139
|
localsInner(e) {
|
|
11139
|
-
if (this ==
|
|
11140
|
+
if (this == Ne)
|
|
11140
11141
|
return on;
|
|
11141
11142
|
if (e.inlineContent || !this.local.some(Ot.is))
|
|
11142
11143
|
return this.local;
|
|
@@ -11151,7 +11152,7 @@ class de {
|
|
|
11151
11152
|
}
|
|
11152
11153
|
de.empty = new de([], []);
|
|
11153
11154
|
de.removeOverlap = _s;
|
|
11154
|
-
const
|
|
11155
|
+
const Ne = de.empty;
|
|
11155
11156
|
class xt {
|
|
11156
11157
|
constructor(e) {
|
|
11157
11158
|
this.members = e;
|
|
@@ -11166,7 +11167,7 @@ class xt {
|
|
|
11166
11167
|
let r = [];
|
|
11167
11168
|
for (let i = 0; i < this.members.length; i++) {
|
|
11168
11169
|
let s = this.members[i].forChild(e, t);
|
|
11169
|
-
s !=
|
|
11170
|
+
s != Ne && (s instanceof xt ? r = r.concat(s.members) : r.push(s));
|
|
11170
11171
|
}
|
|
11171
11172
|
return xt.from(r);
|
|
11172
11173
|
}
|
|
@@ -11198,7 +11199,7 @@ class xt {
|
|
|
11198
11199
|
static from(e) {
|
|
11199
11200
|
switch (e.length) {
|
|
11200
11201
|
case 0:
|
|
11201
|
-
return
|
|
11202
|
+
return Ne;
|
|
11202
11203
|
case 1:
|
|
11203
11204
|
return e[0];
|
|
11204
11205
|
default:
|
|
@@ -11241,7 +11242,7 @@ function Sg(n, e, t, r, i, s, o) {
|
|
|
11241
11242
|
let f = t.map(n[c + 1] + s, -1), h = f - i, { index: p, offset: m } = r.content.findIndex(u), g = r.maybeChild(p);
|
|
11242
11243
|
if (g && m == u && m + g.nodeSize == h) {
|
|
11243
11244
|
let y = l[c + 2].mapInner(t, g, d + 1, n[c] + s + 1, o);
|
|
11244
|
-
y !=
|
|
11245
|
+
y != Ne ? (l[c] = u, l[c + 1] = h, l[c + 2] = y) : (l[c + 1] = -2, a = !0);
|
|
11245
11246
|
} else
|
|
11246
11247
|
a = !0;
|
|
11247
11248
|
}
|
|
@@ -11303,13 +11304,13 @@ function $r(n, e, t, r) {
|
|
|
11303
11304
|
if (c) {
|
|
11304
11305
|
s = !0;
|
|
11305
11306
|
let d = $r(c, l, t + a + 1, r);
|
|
11306
|
-
d !=
|
|
11307
|
+
d != Ne && i.push(a, a + l.nodeSize, d);
|
|
11307
11308
|
}
|
|
11308
11309
|
});
|
|
11309
11310
|
let o = xc(s ? Sc(n) : n, -t).sort(Ut);
|
|
11310
11311
|
for (let l = 0; l < o.length; l++)
|
|
11311
11312
|
o[l].type.valid(e, o[l]) || (r.onRemove && r.onRemove(o[l].spec), o.splice(l--, 1));
|
|
11312
|
-
return o.length || i.length ? new de(o, i) :
|
|
11313
|
+
return o.length || i.length ? new de(o, i) : Ne;
|
|
11313
11314
|
}
|
|
11314
11315
|
function Ut(n, e) {
|
|
11315
11316
|
return n.from - e.from || n.to - e.to;
|
|
@@ -11341,7 +11342,7 @@ function Hi(n) {
|
|
|
11341
11342
|
let e = [];
|
|
11342
11343
|
return n.someProp("decorations", (t) => {
|
|
11343
11344
|
let r = t(n.state);
|
|
11344
|
-
r && r !=
|
|
11345
|
+
r && r != Ne && e.push(r);
|
|
11345
11346
|
}), n.cursorWrapper && e.push(de.create(n.state.doc, [n.cursorWrapper.deco])), xt.from(e);
|
|
11346
11347
|
}
|
|
11347
11348
|
const Mg = {
|
|
@@ -11371,7 +11372,7 @@ class Ag {
|
|
|
11371
11372
|
this.view = e, this.handleDOMChange = t, this.queue = [], this.flushingSoon = -1, this.observer = null, this.currentSelection = new Eg(), this.onCharData = null, this.suppressingSelectionUpdates = !1, this.lastChangedTextNode = null, this.observer = window.MutationObserver && new window.MutationObserver((r) => {
|
|
11372
11373
|
for (let i = 0; i < r.length; i++)
|
|
11373
11374
|
this.queue.push(r[i]);
|
|
11374
|
-
He && Et <= 11 && r.some((i) => i.type == "childList" && i.removedNodes.length || i.type == "characterData" && i.oldValue.length > i.target.nodeValue.length) ? this.flushSoon() : this.flush();
|
|
11375
|
+
He && Et <= 11 && r.some((i) => i.type == "childList" && i.removedNodes.length || i.type == "characterData" && i.oldValue.length > i.target.nodeValue.length) ? this.flushSoon() : Ae && e.composing && r.some((i) => i.type == "childList" && i.target.nodeName == "TR") ? (e.input.badSafariComposition = !0, this.flushSoon()) : this.flush();
|
|
11375
11376
|
}), Tg && (this.onCharData = (r) => {
|
|
11376
11377
|
this.queue.push({ target: r.target, type: "characterData", oldValue: r.prevValue }), this.flushSoon();
|
|
11377
11378
|
}), this.onSelectionChange = this.onSelectionChange.bind(this);
|
|
@@ -11471,7 +11472,7 @@ class Ag {
|
|
|
11471
11472
|
h && h.nodeName == "LI" && (!u || Ig(e, u) != h) && f.remove();
|
|
11472
11473
|
}
|
|
11473
11474
|
}
|
|
11474
|
-
} else if ((we ||
|
|
11475
|
+
} else if ((we || Ae) && a.some((d) => d.nodeName == "BR") && (e.input.lastKeyCode == 8 || e.input.lastKeyCode == 46)) {
|
|
11475
11476
|
for (let d of a)
|
|
11476
11477
|
if (d.nodeName == "BR" && d.parentNode) {
|
|
11477
11478
|
let u = d.nextSibling;
|
|
@@ -11479,7 +11480,7 @@ class Ag {
|
|
|
11479
11480
|
}
|
|
11480
11481
|
}
|
|
11481
11482
|
let c = null;
|
|
11482
|
-
s < 0 && i && e.input.lastFocus > Date.now() - 200 && Math.max(e.input.lastTouch, e.input.lastClick.time) < Date.now() - 300 && bi(r) && (c = Ks(e)) && c.eq(Y.near(e.state.doc.resolve(0), 1)) ? (e.input.lastFocus = 0, pt(e), this.currentSelection.set(r), e.scrollToSelection()) : (s > -1 || i) && (s > -1 && (e.docView.markDirty(s, o), Og(e)), this.handleDOMChange(s, o, l, a), e.docView && e.docView.dirty ? e.updateState(e.state) : this.currentSelection.eq(r) || pt(e), this.currentSelection.set(r));
|
|
11483
|
+
s < 0 && i && e.input.lastFocus > Date.now() - 200 && Math.max(e.input.lastTouch, e.input.lastClick.time) < Date.now() - 300 && bi(r) && (c = Ks(e)) && c.eq(Y.near(e.state.doc.resolve(0), 1)) ? (e.input.lastFocus = 0, pt(e), this.currentSelection.set(r), e.scrollToSelection()) : (s > -1 || i) && (s > -1 && (e.docView.markDirty(s, o), Og(e)), e.input.badSafariComposition && (e.input.badSafariComposition = !1, Dg(e, a)), this.handleDOMChange(s, o, l, a), e.docView && e.docView.dirty ? e.updateState(e.state) : this.currentSelection.eq(r) || pt(e), this.currentSelection.set(r));
|
|
11483
11484
|
}
|
|
11484
11485
|
registerMutation(e, t) {
|
|
11485
11486
|
if (t.indexOf(e.target) > -1)
|
|
@@ -11546,7 +11547,28 @@ function Ig(n, e) {
|
|
|
11546
11547
|
}
|
|
11547
11548
|
return null;
|
|
11548
11549
|
}
|
|
11549
|
-
function Dg(n, e
|
|
11550
|
+
function Dg(n, e) {
|
|
11551
|
+
var t;
|
|
11552
|
+
let { focusNode: r, focusOffset: i } = n.domSelectionRange();
|
|
11553
|
+
for (let s of e)
|
|
11554
|
+
if (((t = s.parentNode) === null || t === void 0 ? void 0 : t.nodeName) == "TR") {
|
|
11555
|
+
let o = s.nextSibling;
|
|
11556
|
+
for (; o && o.nodeName != "TD" && o.nodeName != "TH"; )
|
|
11557
|
+
o = o.nextSibling;
|
|
11558
|
+
if (o) {
|
|
11559
|
+
let l = o;
|
|
11560
|
+
for (; ; ) {
|
|
11561
|
+
let a = l.firstChild;
|
|
11562
|
+
if (!a || a.nodeType != 1 || a.contentEditable == "false" || /^(BR|IMG)$/.test(a.nodeName))
|
|
11563
|
+
break;
|
|
11564
|
+
l = a;
|
|
11565
|
+
}
|
|
11566
|
+
l.insertBefore(s, l.firstChild), r == s && n.domSelection().collapse(s, i);
|
|
11567
|
+
} else
|
|
11568
|
+
s.parentNode.removeChild(s);
|
|
11569
|
+
}
|
|
11570
|
+
}
|
|
11571
|
+
function $g(n, e, t) {
|
|
11550
11572
|
let { node: r, fromOffset: i, toOffset: s, from: o, to: l } = n.docView.parseRange(e, t), a = n.domSelectionRange(), c, d = a.anchorNode;
|
|
11551
11573
|
if (d && n.dom.contains(d.nodeType == 1 ? d : d.parentNode) && (c = [{ node: d, offset: a.anchorOffset }], bi(a) || c.push({ node: a.focusNode, offset: a.focusOffset })), we && n.input.lastKeyCode === 8)
|
|
11552
11574
|
for (let g = s; g > i; g--) {
|
|
@@ -11566,7 +11588,7 @@ function Dg(n, e, t) {
|
|
|
11566
11588
|
to: s,
|
|
11567
11589
|
preserveWhitespace: h.parent.type.whitespace == "pre" ? "full" : !0,
|
|
11568
11590
|
findPositions: c,
|
|
11569
|
-
ruleFromNode:
|
|
11591
|
+
ruleFromNode: Rg,
|
|
11570
11592
|
context: h
|
|
11571
11593
|
});
|
|
11572
11594
|
if (c && c[0].pos != null) {
|
|
@@ -11575,22 +11597,22 @@ function Dg(n, e, t) {
|
|
|
11575
11597
|
}
|
|
11576
11598
|
return { doc: m, sel: p, from: o, to: l };
|
|
11577
11599
|
}
|
|
11578
|
-
function
|
|
11600
|
+
function Rg(n) {
|
|
11579
11601
|
let e = n.pmViewDesc;
|
|
11580
11602
|
if (e)
|
|
11581
11603
|
return e.parseRule();
|
|
11582
11604
|
if (n.nodeName == "BR" && n.parentNode) {
|
|
11583
|
-
if (
|
|
11605
|
+
if (Ae && /^(ul|ol)$/i.test(n.parentNode.nodeName)) {
|
|
11584
11606
|
let t = document.createElement("div");
|
|
11585
11607
|
return t.appendChild(document.createElement("li")), { skip: t };
|
|
11586
|
-
} else if (n.parentNode.lastChild == n ||
|
|
11608
|
+
} else if (n.parentNode.lastChild == n || Ae && /^(tr|table)$/i.test(n.parentNode.nodeName))
|
|
11587
11609
|
return { ignore: !0 };
|
|
11588
11610
|
} else if (n.nodeName == "IMG" && n.getAttribute("mark-placeholder"))
|
|
11589
11611
|
return { ignore: !0 };
|
|
11590
11612
|
return null;
|
|
11591
11613
|
}
|
|
11592
|
-
const
|
|
11593
|
-
function
|
|
11614
|
+
const Lg = /^(a|abbr|acronym|b|bd[io]|big|br|button|cite|code|data(list)?|del|dfn|em|i|img|ins|kbd|label|map|mark|meter|output|q|ruby|s|samp|small|span|strong|su[bp]|time|u|tt|var)$/i;
|
|
11615
|
+
function Pg(n, e, t, r, i) {
|
|
11594
11616
|
let s = n.input.compositionPendingChanges || (n.composing ? n.input.compositionID : 0);
|
|
11595
11617
|
if (n.input.compositionPendingChanges = 0, e < 0) {
|
|
11596
11618
|
let x = n.input.lastSelectionTime > Date.now() - 50 ? n.input.lastSelectionOrigin : null, M = Ks(n, x);
|
|
@@ -11604,10 +11626,10 @@ function Lg(n, e, t, r, i) {
|
|
|
11604
11626
|
}
|
|
11605
11627
|
let o = n.state.doc.resolve(e), l = o.sharedDepth(t);
|
|
11606
11628
|
e = o.before(l + 1), t = n.state.doc.resolve(t).after(l + 1);
|
|
11607
|
-
let a = n.state.selection, c =
|
|
11629
|
+
let a = n.state.selection, c = $g(n, e, t), d = n.state.doc, u = d.slice(c.from, c.to), f, h;
|
|
11608
11630
|
n.input.lastKeyCode === 8 && Date.now() - 100 < n.input.lastKeyCodeTime ? (f = n.state.selection.to, h = "end") : (f = n.state.selection.from, h = "start"), n.input.lastKeyCode = null;
|
|
11609
|
-
let p =
|
|
11610
|
-
if (p && n.input.domChangeCount++, (yn && n.input.lastIOSEnter > Date.now() - 225 || ft) && i.some((x) => x.nodeType == 1 && !
|
|
11631
|
+
let p = Vg(u.content, c.doc.content, c.from, f, h);
|
|
11632
|
+
if (p && n.input.domChangeCount++, (yn && n.input.lastIOSEnter > Date.now() - 225 || ft) && i.some((x) => x.nodeType == 1 && !Lg.test(x.nodeName)) && (!p || p.endA >= p.endB) && n.someProp("handleKeyDown", (x) => x(n, Pt(13, "Enter")))) {
|
|
11611
11633
|
n.input.lastIOSEnter = 0;
|
|
11612
11634
|
return;
|
|
11613
11635
|
}
|
|
@@ -11630,7 +11652,7 @@ function Lg(n, e, t, r, i) {
|
|
|
11630
11652
|
n.input.lastIOSEnter = 0;
|
|
11631
11653
|
return;
|
|
11632
11654
|
}
|
|
11633
|
-
if (n.state.selection.anchor > p.start &&
|
|
11655
|
+
if (n.state.selection.anchor > p.start && Bg(d, p.start, p.endA, m, g) && n.someProp("handleKeyDown", (x) => x(n, Pt(8, "Backspace")))) {
|
|
11634
11656
|
ft && we && n.domObserver.suppressSelectionUpdates();
|
|
11635
11657
|
return;
|
|
11636
11658
|
}
|
|
@@ -11654,7 +11676,7 @@ function Lg(n, e, t, r, i) {
|
|
|
11654
11676
|
M && x.ensureMarks(M), n.dispatch(x);
|
|
11655
11677
|
} else if (
|
|
11656
11678
|
// Adding or removing a mark
|
|
11657
|
-
p.endA == p.endB && (w =
|
|
11679
|
+
p.endA == p.endB && (w = zg(m.parent.content.cut(m.parentOffset, g.parentOffset), y.parent.content.cut(y.parentOffset, p.endA - y.start())))
|
|
11658
11680
|
) {
|
|
11659
11681
|
let x = k(n.state.tr);
|
|
11660
11682
|
w.type == "add" ? x.addMark(v, b, w.mark) : x.removeMark(v, b, w.mark), n.dispatch(x);
|
|
@@ -11669,7 +11691,7 @@ function Lg(n, e, t, r, i) {
|
|
|
11669
11691
|
function Sl(n, e, t) {
|
|
11670
11692
|
return Math.max(t.anchor, t.head) > e.content.size ? null : Js(n, e.resolve(t.anchor), e.resolve(t.head));
|
|
11671
11693
|
}
|
|
11672
|
-
function
|
|
11694
|
+
function zg(n, e) {
|
|
11673
11695
|
let t = n.firstChild.marks, r = e.firstChild.marks, i = t, s = r, o, l, a;
|
|
11674
11696
|
for (let d = 0; d < r.length; d++)
|
|
11675
11697
|
i = r[d].removeFromSet(i);
|
|
@@ -11687,7 +11709,7 @@ function Pg(n, e) {
|
|
|
11687
11709
|
if (A.from(c).eq(n))
|
|
11688
11710
|
return { mark: l, type: o };
|
|
11689
11711
|
}
|
|
11690
|
-
function
|
|
11712
|
+
function Bg(n, e, t, r, i) {
|
|
11691
11713
|
if (
|
|
11692
11714
|
// The content must have shrunk
|
|
11693
11715
|
t - e <= i.pos - r.pos || // newEnd must point directly at or after the end of the block that newStart points into
|
|
@@ -11715,7 +11737,7 @@ function ji(n, e, t) {
|
|
|
11715
11737
|
}
|
|
11716
11738
|
return i;
|
|
11717
11739
|
}
|
|
11718
|
-
function
|
|
11740
|
+
function Vg(n, e, t, r, i) {
|
|
11719
11741
|
let s = n.findDiffStart(e, t);
|
|
11720
11742
|
if (s == null)
|
|
11721
11743
|
return null;
|
|
@@ -11748,7 +11770,7 @@ class Cc {
|
|
|
11748
11770
|
added to the document.
|
|
11749
11771
|
*/
|
|
11750
11772
|
constructor(e, t) {
|
|
11751
|
-
this._root = null, this.focused = !1, this.trackWrites = null, this.mounted = !1, this.markCursor = null, this.cursorWrapper = null, this.lastSelectedViewDesc = void 0, this.input = new tg(), this.prevDirectPlugins = [], this.pluginViews = [], this.requiresGeckoHackNode = !1, this.dragging = null, this._props = t, this.state = t.state, this.directPlugins = t.plugins || [], this.directPlugins.forEach(Ol), this.dispatch = this.dispatch.bind(this), this.dom = e && e.mount || document.createElement("div"), e && (e.appendChild ? e.appendChild(this.dom) : typeof e == "function" ? e(this.dom) : e.mount && (this.mounted = !0)), this.editable = El(this), Tl(this), this.nodeViews = Al(this), this.docView = sl(this.state.doc, Ml(this), Hi(this), this.dom, this), this.domObserver = new Ag(this, (r, i, s, o) =>
|
|
11773
|
+
this._root = null, this.focused = !1, this.trackWrites = null, this.mounted = !1, this.markCursor = null, this.cursorWrapper = null, this.lastSelectedViewDesc = void 0, this.input = new tg(), this.prevDirectPlugins = [], this.pluginViews = [], this.requiresGeckoHackNode = !1, this.dragging = null, this._props = t, this.state = t.state, this.directPlugins = t.plugins || [], this.directPlugins.forEach(Ol), this.dispatch = this.dispatch.bind(this), this.dom = e && e.mount || document.createElement("div"), e && (e.appendChild ? e.appendChild(this.dom) : typeof e == "function" ? e(this.dom) : e.mount && (this.mounted = !0)), this.editable = El(this), Tl(this), this.nodeViews = Al(this), this.docView = sl(this.state.doc, Ml(this), Hi(this), this.dom, this), this.domObserver = new Ag(this, (r, i, s, o) => Pg(this, r, i, s, o)), this.domObserver.start(), ng(this), this.updatePluginViews();
|
|
11752
11774
|
}
|
|
11753
11775
|
/**
|
|
11754
11776
|
Holds `true` when a
|
|
@@ -11808,7 +11830,7 @@ class Cc {
|
|
|
11808
11830
|
let l = i.plugins != e.plugins || this._props.plugins != t.plugins;
|
|
11809
11831
|
if (l || this._props.plugins != t.plugins || this._props.nodeViews != t.nodeViews) {
|
|
11810
11832
|
let h = Al(this);
|
|
11811
|
-
|
|
11833
|
+
Hg(h, this.nodeViews) && (this.nodeViews = h, s = !0);
|
|
11812
11834
|
}
|
|
11813
11835
|
(l || t.handleDOMEvents != this._props.handleDOMEvents) && ys(this), this.editable = El(this), Tl(this);
|
|
11814
11836
|
let a = Hi(this), c = Ml(this), d = i.plugins != e.plugins && !i.doc.eq(e.doc) ? "reset" : e.scrollToSelection > i.scrollToSelection ? "to selection" : "preserve", u = s || !this.docView.matchesNode(e.doc, c, a);
|
|
@@ -11816,10 +11838,10 @@ class Cc {
|
|
|
11816
11838
|
let f = d == "preserve" && o && this.dom.style.overflowAnchor == null && gm(this);
|
|
11817
11839
|
if (o) {
|
|
11818
11840
|
this.domObserver.stop();
|
|
11819
|
-
let h = u && (He || we) && !this.composing && !i.selection.empty && !e.selection.empty &&
|
|
11841
|
+
let h = u && (He || we) && !this.composing && !i.selection.empty && !e.selection.empty && Fg(i.selection, e.selection);
|
|
11820
11842
|
if (u) {
|
|
11821
11843
|
let p = we ? this.trackWrites = this.domSelectionRange().focusNode : null;
|
|
11822
|
-
this.composing && (this.input.compositionNode = gg(this)), (s || !this.docView.update(e.doc, c, a, this)) && (this.docView.updateOuterDeco(c), this.docView.destroy(), this.docView = sl(e.doc, c, a, this.dom, this)), p && !this.trackWrites && (h = !0);
|
|
11844
|
+
this.composing && (this.input.compositionNode = gg(this)), (s || !this.docView.update(e.doc, c, a, this)) && (this.docView.updateOuterDeco(c), this.docView.destroy(), this.docView = sl(e.doc, c, a, this.dom, this)), p && (!this.trackWrites || !this.dom.contains(this.trackWrites)) && (h = !0);
|
|
11823
11845
|
}
|
|
11824
11846
|
h || !(this.input.mouseDown && this.domObserver.currentSelection.eq(this.domSelectionRange()) && Fm(this)) ? pt(this, h) : (sc(this, e.selection), this.domObserver.setCurSelection()), this.domObserver.start();
|
|
11825
11847
|
}
|
|
@@ -12062,7 +12084,7 @@ class Cc {
|
|
|
12062
12084
|
*/
|
|
12063
12085
|
domSelectionRange() {
|
|
12064
12086
|
let e = this.domSelection();
|
|
12065
|
-
return e ?
|
|
12087
|
+
return e ? Ae && this.root.nodeType === 11 && um(this.dom.ownerDocument) == this.dom && Ng(this, e) || e : { focusNode: null, focusOffset: 0, anchorNode: null, anchorOffset: 0 };
|
|
12066
12088
|
}
|
|
12067
12089
|
/**
|
|
12068
12090
|
@internal
|
|
@@ -12093,7 +12115,7 @@ function Tl(n) {
|
|
|
12093
12115
|
function El(n) {
|
|
12094
12116
|
return !n.someProp("editable", (e) => e(n.state) === !1);
|
|
12095
12117
|
}
|
|
12096
|
-
function
|
|
12118
|
+
function Fg(n, e) {
|
|
12097
12119
|
let t = Math.min(n.$anchor.sharedDepth(n.head), e.$anchor.sharedDepth(e.head));
|
|
12098
12120
|
return n.$anchor.start(t) != e.$anchor.start(t);
|
|
12099
12121
|
}
|
|
@@ -12105,7 +12127,7 @@ function Al(n) {
|
|
|
12105
12127
|
}
|
|
12106
12128
|
return n.someProp("nodeViews", t), n.someProp("markViews", t), e;
|
|
12107
12129
|
}
|
|
12108
|
-
function
|
|
12130
|
+
function Hg(n, e) {
|
|
12109
12131
|
let t = 0, r = 0;
|
|
12110
12132
|
for (let i in n) {
|
|
12111
12133
|
if (n[i] != e[i])
|
|
@@ -12198,18 +12220,18 @@ var Nt = {
|
|
|
12198
12220
|
220: "|",
|
|
12199
12221
|
221: "}",
|
|
12200
12222
|
222: '"'
|
|
12201
|
-
},
|
|
12223
|
+
}, jg = typeof navigator < "u" && /Mac/.test(navigator.platform), qg = typeof navigator < "u" && /MSIE \d|Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(navigator.userAgent);
|
|
12202
12224
|
for (var Te = 0; Te < 10; Te++) Nt[48 + Te] = Nt[96 + Te] = String(Te);
|
|
12203
12225
|
for (var Te = 1; Te <= 24; Te++) Nt[Te + 111] = "F" + Te;
|
|
12204
12226
|
for (var Te = 65; Te <= 90; Te++)
|
|
12205
12227
|
Nt[Te] = String.fromCharCode(Te + 32), Rr[Te] = String.fromCharCode(Te);
|
|
12206
12228
|
for (var qi in Nt) Rr.hasOwnProperty(qi) || (Rr[qi] = Nt[qi]);
|
|
12207
|
-
function
|
|
12208
|
-
var e =
|
|
12229
|
+
function Ug(n) {
|
|
12230
|
+
var e = jg && n.metaKey && n.shiftKey && !n.ctrlKey && !n.altKey || qg && n.shiftKey && n.key && n.key.length == 1 || n.key == "Unidentified", t = !e && n.key || (n.shiftKey ? Rr : Nt)[n.keyCode] || n.key || "Unidentified";
|
|
12209
12231
|
return t == "Esc" && (t = "Escape"), t == "Del" && (t = "Delete"), t == "Left" && (t = "ArrowLeft"), t == "Up" && (t = "ArrowUp"), t == "Right" && (t = "ArrowRight"), t == "Down" && (t = "ArrowDown"), t;
|
|
12210
12232
|
}
|
|
12211
|
-
const
|
|
12212
|
-
function
|
|
12233
|
+
const Wg = typeof navigator < "u" && /Mac|iP(hone|[oa]d)/.test(navigator.platform), Kg = typeof navigator < "u" && /Win/.test(navigator.platform);
|
|
12234
|
+
function Jg(n) {
|
|
12213
12235
|
let e = n.split(/-(?!$)/), t = e[e.length - 1];
|
|
12214
12236
|
t == "Space" && (t = " ");
|
|
12215
12237
|
let r, i, s, o;
|
|
@@ -12224,28 +12246,28 @@ function Kg(n) {
|
|
|
12224
12246
|
else if (/^s(hift)?$/i.test(a))
|
|
12225
12247
|
s = !0;
|
|
12226
12248
|
else if (/^mod$/i.test(a))
|
|
12227
|
-
|
|
12249
|
+
Wg ? o = !0 : i = !0;
|
|
12228
12250
|
else
|
|
12229
12251
|
throw new Error("Unrecognized modifier name: " + a);
|
|
12230
12252
|
}
|
|
12231
12253
|
return r && (t = "Alt-" + t), i && (t = "Ctrl-" + t), o && (t = "Meta-" + t), s && (t = "Shift-" + t), t;
|
|
12232
12254
|
}
|
|
12233
|
-
function
|
|
12255
|
+
function Gg(n) {
|
|
12234
12256
|
let e = /* @__PURE__ */ Object.create(null);
|
|
12235
12257
|
for (let t in n)
|
|
12236
|
-
e[
|
|
12258
|
+
e[Jg(t)] = n[t];
|
|
12237
12259
|
return e;
|
|
12238
12260
|
}
|
|
12239
12261
|
function Ui(n, e, t = !0) {
|
|
12240
12262
|
return e.altKey && (n = "Alt-" + n), e.ctrlKey && (n = "Ctrl-" + n), e.metaKey && (n = "Meta-" + n), t && e.shiftKey && (n = "Shift-" + n), n;
|
|
12241
12263
|
}
|
|
12242
|
-
function
|
|
12264
|
+
function Yg(n) {
|
|
12243
12265
|
return new ue({ props: { handleKeyDown: Mc(n) } });
|
|
12244
12266
|
}
|
|
12245
12267
|
function Mc(n) {
|
|
12246
|
-
let e =
|
|
12268
|
+
let e = Gg(n);
|
|
12247
12269
|
return function(t, r) {
|
|
12248
|
-
let i =
|
|
12270
|
+
let i = Ug(r), s, o = e[Ui(i, r)];
|
|
12249
12271
|
if (o && o(t.state, t.dispatch, t))
|
|
12250
12272
|
return !0;
|
|
12251
12273
|
if (i.length == 1 && i != " ") {
|
|
@@ -12255,7 +12277,7 @@ function Mc(n) {
|
|
|
12255
12277
|
return !0;
|
|
12256
12278
|
}
|
|
12257
12279
|
if ((r.altKey || r.metaKey || r.ctrlKey) && // Ctrl-Alt may be used for AltGr on Windows
|
|
12258
|
-
!(
|
|
12280
|
+
!(Kg && r.ctrlKey && r.altKey) && (s = Nt[r.keyCode]) && s != i) {
|
|
12259
12281
|
let l = e[Ui(s, r)];
|
|
12260
12282
|
if (l && l(t.state, t.dispatch, t))
|
|
12261
12283
|
return !0;
|
|
@@ -12264,9 +12286,9 @@ function Mc(n) {
|
|
|
12264
12286
|
return !1;
|
|
12265
12287
|
};
|
|
12266
12288
|
}
|
|
12267
|
-
var
|
|
12289
|
+
var Qg = Object.defineProperty, eo = (n, e) => {
|
|
12268
12290
|
for (var t in e)
|
|
12269
|
-
|
|
12291
|
+
Qg(n, t, { get: e[t], enumerable: !0 });
|
|
12270
12292
|
};
|
|
12271
12293
|
function xi(n) {
|
|
12272
12294
|
const { state: e, transaction: t } = n;
|
|
@@ -12362,71 +12384,71 @@ var wi = class {
|
|
|
12362
12384
|
}
|
|
12363
12385
|
}, Tc = {};
|
|
12364
12386
|
eo(Tc, {
|
|
12365
|
-
blur: () =>
|
|
12366
|
-
clearContent: () =>
|
|
12367
|
-
clearNodes: () =>
|
|
12368
|
-
command: () =>
|
|
12369
|
-
createParagraphNear: () =>
|
|
12370
|
-
cut: () =>
|
|
12371
|
-
deleteCurrentNode: () =>
|
|
12372
|
-
deleteNode: () =>
|
|
12373
|
-
deleteRange: () =>
|
|
12374
|
-
deleteSelection: () =>
|
|
12375
|
-
enter: () =>
|
|
12376
|
-
exitCode: () =>
|
|
12377
|
-
extendMarkRange: () =>
|
|
12378
|
-
first: () =>
|
|
12379
|
-
focus: () =>
|
|
12380
|
-
forEach: () =>
|
|
12381
|
-
insertContent: () =>
|
|
12382
|
-
insertContentAt: () =>
|
|
12383
|
-
joinBackward: () =>
|
|
12384
|
-
joinDown: () =>
|
|
12385
|
-
joinForward: () =>
|
|
12386
|
-
joinItemBackward: () =>
|
|
12387
|
-
joinItemForward: () =>
|
|
12388
|
-
joinTextblockBackward: () =>
|
|
12389
|
-
joinTextblockForward: () =>
|
|
12390
|
-
joinUp: () =>
|
|
12391
|
-
keyboardShortcut: () =>
|
|
12392
|
-
lift: () =>
|
|
12393
|
-
liftEmptyBlock: () =>
|
|
12394
|
-
liftListItem: () =>
|
|
12395
|
-
newlineInCode: () =>
|
|
12396
|
-
resetAttributes: () =>
|
|
12397
|
-
scrollIntoView: () =>
|
|
12398
|
-
selectAll: () =>
|
|
12399
|
-
selectNodeBackward: () =>
|
|
12400
|
-
selectNodeForward: () =>
|
|
12401
|
-
selectParentNode: () =>
|
|
12402
|
-
selectTextblockEnd: () =>
|
|
12403
|
-
selectTextblockStart: () =>
|
|
12404
|
-
setContent: () =>
|
|
12405
|
-
setMark: () =>
|
|
12406
|
-
setMeta: () =>
|
|
12407
|
-
setNode: () =>
|
|
12408
|
-
setNodeSelection: () =>
|
|
12409
|
-
setTextDirection: () =>
|
|
12410
|
-
setTextSelection: () =>
|
|
12411
|
-
sinkListItem: () =>
|
|
12412
|
-
splitBlock: () =>
|
|
12413
|
-
splitListItem: () =>
|
|
12414
|
-
toggleList: () =>
|
|
12415
|
-
toggleMark: () =>
|
|
12416
|
-
toggleNode: () =>
|
|
12417
|
-
toggleWrap: () =>
|
|
12418
|
-
undoInputRule: () =>
|
|
12419
|
-
unsetAllMarks: () =>
|
|
12420
|
-
unsetMark: () =>
|
|
12421
|
-
unsetTextDirection: () =>
|
|
12422
|
-
updateAttributes: () =>
|
|
12423
|
-
wrapIn: () =>
|
|
12424
|
-
wrapInList: () =>
|
|
12387
|
+
blur: () => Xg,
|
|
12388
|
+
clearContent: () => Zg,
|
|
12389
|
+
clearNodes: () => _g,
|
|
12390
|
+
command: () => ey,
|
|
12391
|
+
createParagraphNear: () => ty,
|
|
12392
|
+
cut: () => ny,
|
|
12393
|
+
deleteCurrentNode: () => ry,
|
|
12394
|
+
deleteNode: () => iy,
|
|
12395
|
+
deleteRange: () => sy,
|
|
12396
|
+
deleteSelection: () => oy,
|
|
12397
|
+
enter: () => ly,
|
|
12398
|
+
exitCode: () => ay,
|
|
12399
|
+
extendMarkRange: () => cy,
|
|
12400
|
+
first: () => dy,
|
|
12401
|
+
focus: () => fy,
|
|
12402
|
+
forEach: () => hy,
|
|
12403
|
+
insertContent: () => py,
|
|
12404
|
+
insertContentAt: () => yy,
|
|
12405
|
+
joinBackward: () => vy,
|
|
12406
|
+
joinDown: () => ky,
|
|
12407
|
+
joinForward: () => xy,
|
|
12408
|
+
joinItemBackward: () => wy,
|
|
12409
|
+
joinItemForward: () => Sy,
|
|
12410
|
+
joinTextblockBackward: () => Cy,
|
|
12411
|
+
joinTextblockForward: () => My,
|
|
12412
|
+
joinUp: () => by,
|
|
12413
|
+
keyboardShortcut: () => Ey,
|
|
12414
|
+
lift: () => Ay,
|
|
12415
|
+
liftEmptyBlock: () => Oy,
|
|
12416
|
+
liftListItem: () => Ny,
|
|
12417
|
+
newlineInCode: () => Iy,
|
|
12418
|
+
resetAttributes: () => Dy,
|
|
12419
|
+
scrollIntoView: () => $y,
|
|
12420
|
+
selectAll: () => Ry,
|
|
12421
|
+
selectNodeBackward: () => Ly,
|
|
12422
|
+
selectNodeForward: () => Py,
|
|
12423
|
+
selectParentNode: () => zy,
|
|
12424
|
+
selectTextblockEnd: () => By,
|
|
12425
|
+
selectTextblockStart: () => Vy,
|
|
12426
|
+
setContent: () => Fy,
|
|
12427
|
+
setMark: () => o0,
|
|
12428
|
+
setMeta: () => l0,
|
|
12429
|
+
setNode: () => a0,
|
|
12430
|
+
setNodeSelection: () => c0,
|
|
12431
|
+
setTextDirection: () => d0,
|
|
12432
|
+
setTextSelection: () => u0,
|
|
12433
|
+
sinkListItem: () => f0,
|
|
12434
|
+
splitBlock: () => h0,
|
|
12435
|
+
splitListItem: () => p0,
|
|
12436
|
+
toggleList: () => m0,
|
|
12437
|
+
toggleMark: () => g0,
|
|
12438
|
+
toggleNode: () => y0,
|
|
12439
|
+
toggleWrap: () => b0,
|
|
12440
|
+
undoInputRule: () => k0,
|
|
12441
|
+
unsetAllMarks: () => v0,
|
|
12442
|
+
unsetMark: () => x0,
|
|
12443
|
+
unsetTextDirection: () => w0,
|
|
12444
|
+
updateAttributes: () => S0,
|
|
12445
|
+
wrapIn: () => C0,
|
|
12446
|
+
wrapInList: () => M0
|
|
12425
12447
|
});
|
|
12426
|
-
var
|
|
12448
|
+
var Xg = () => ({ editor: n, view: e }) => (requestAnimationFrame(() => {
|
|
12427
12449
|
var t;
|
|
12428
12450
|
n.isDestroyed || (e.dom.blur(), (t = window?.getSelection()) == null || t.removeAllRanges());
|
|
12429
|
-
}), !0),
|
|
12451
|
+
}), !0), Zg = (n = !0) => ({ commands: e }) => e.setContent("", { emitUpdate: n }), _g = () => ({ state: n, tr: e, dispatch: t }) => {
|
|
12430
12452
|
const { selection: r } = e, { ranges: i } = r;
|
|
12431
12453
|
return t && i.forEach(({ $from: s, $to: o }) => {
|
|
12432
12454
|
n.doc.nodesBetween(s.pos, o.pos, (l, a) => {
|
|
@@ -12443,12 +12465,12 @@ var Qg = () => ({ editor: n, view: e }) => (requestAnimationFrame(() => {
|
|
|
12443
12465
|
(p || p === 0) && e.lift(h, p);
|
|
12444
12466
|
});
|
|
12445
12467
|
}), !0;
|
|
12446
|
-
},
|
|
12468
|
+
}, ey = (n) => (e) => n(e), ty = () => ({ state: n, dispatch: e }) => Kp(n, e), ny = (n, e) => ({ editor: t, tr: r }) => {
|
|
12447
12469
|
const { state: i } = t, s = i.doc.slice(n.from, n.to);
|
|
12448
12470
|
r.deleteRange(n.from, n.to);
|
|
12449
12471
|
const o = r.mapping.map(e);
|
|
12450
12472
|
return r.insert(o, s.content), r.setSelection(new J(r.doc.resolve(Math.max(o - 1, 0)))), !0;
|
|
12451
|
-
},
|
|
12473
|
+
}, ry = () => ({ tr: n, dispatch: e }) => {
|
|
12452
12474
|
const { selection: t } = n, r = t.$anchor.node();
|
|
12453
12475
|
if (r.content.size > 0)
|
|
12454
12476
|
return !1;
|
|
@@ -12471,7 +12493,7 @@ function ge(n, e) {
|
|
|
12471
12493
|
}
|
|
12472
12494
|
return n;
|
|
12473
12495
|
}
|
|
12474
|
-
var
|
|
12496
|
+
var iy = (n) => ({ tr: e, state: t, dispatch: r }) => {
|
|
12475
12497
|
const i = ge(n, t.schema), s = e.selection.$anchor;
|
|
12476
12498
|
for (let o = s.depth; o > 0; o -= 1)
|
|
12477
12499
|
if (s.node(o).type === i) {
|
|
@@ -12482,10 +12504,10 @@ var ry = (n) => ({ tr: e, state: t, dispatch: r }) => {
|
|
|
12482
12504
|
return !0;
|
|
12483
12505
|
}
|
|
12484
12506
|
return !1;
|
|
12485
|
-
},
|
|
12507
|
+
}, sy = (n) => ({ tr: e, dispatch: t }) => {
|
|
12486
12508
|
const { from: r, to: i } = n;
|
|
12487
12509
|
return t && e.delete(r, i), !0;
|
|
12488
|
-
},
|
|
12510
|
+
}, oy = () => ({ state: n, dispatch: e }) => Rp(n, e), ly = () => ({ commands: n }) => n.keyboardShortcut("Enter"), ay = () => ({ state: n, dispatch: e }) => Wp(n, e);
|
|
12489
12511
|
function to(n) {
|
|
12490
12512
|
return Object.prototype.toString.call(n) === "[object RegExp]";
|
|
12491
12513
|
}
|
|
@@ -12528,7 +12550,7 @@ function mt(n, e) {
|
|
|
12528
12550
|
}
|
|
12529
12551
|
return n;
|
|
12530
12552
|
}
|
|
12531
|
-
var
|
|
12553
|
+
var cy = (n, e = {}) => ({ tr: t, state: r, dispatch: i }) => {
|
|
12532
12554
|
const s = mt(n, r.schema), { doc: o, selection: l } = t, { $from: a, from: c, to: d } = l;
|
|
12533
12555
|
if (i) {
|
|
12534
12556
|
const u = no(a, s, e);
|
|
@@ -12538,7 +12560,7 @@ var ay = (n, e = {}) => ({ tr: t, state: r, dispatch: i }) => {
|
|
|
12538
12560
|
}
|
|
12539
12561
|
}
|
|
12540
12562
|
return !0;
|
|
12541
|
-
},
|
|
12563
|
+
}, dy = (n) => (e) => {
|
|
12542
12564
|
const t = typeof n == "function" ? n(e) : n;
|
|
12543
12565
|
for (let r = 0; r < t.length; r += 1)
|
|
12544
12566
|
if (t[r](e))
|
|
@@ -12569,16 +12591,16 @@ function Pr() {
|
|
|
12569
12591
|
return ["iPad Simulator", "iPhone Simulator", "iPod Simulator", "iPad", "iPhone", "iPod"].includes(navigator.platform) || // iPad on iOS 13 detection
|
|
12570
12592
|
navigator.userAgent.includes("Mac") && "ontouchend" in document;
|
|
12571
12593
|
}
|
|
12572
|
-
function
|
|
12594
|
+
function uy() {
|
|
12573
12595
|
return typeof navigator < "u" ? /^((?!chrome|android).)*safari/i.test(navigator.userAgent) : !1;
|
|
12574
12596
|
}
|
|
12575
|
-
var
|
|
12597
|
+
var fy = (n = null, e = {}) => ({ editor: t, view: r, tr: i, dispatch: s }) => {
|
|
12576
12598
|
e = {
|
|
12577
12599
|
scrollIntoView: !0,
|
|
12578
12600
|
...e
|
|
12579
12601
|
};
|
|
12580
12602
|
const o = () => {
|
|
12581
|
-
(Pr() || Il()) && r.dom.focus(),
|
|
12603
|
+
(Pr() || Il()) && r.dom.focus(), uy() && !Pr() && !Il() && r.dom.focus({ preventScroll: !0 }), requestAnimationFrame(() => {
|
|
12582
12604
|
t.isDestroyed || (r.focus(), e?.scrollIntoView && t.commands.scrollIntoView());
|
|
12583
12605
|
});
|
|
12584
12606
|
};
|
|
@@ -12588,7 +12610,7 @@ var uy = (n = null, e = {}) => ({ editor: t, view: r, tr: i, dispatch: s }) => {
|
|
|
12588
12610
|
return o(), !0;
|
|
12589
12611
|
const l = Oc(i.doc, n) || t.state.selection, a = t.state.selection.eq(l);
|
|
12590
12612
|
return s && (a || i.setSelection(l), a && i.storedMarks && i.setStoredMarks(i.storedMarks), o()), !0;
|
|
12591
|
-
},
|
|
12613
|
+
}, hy = (n, e) => (t) => n.every((r, i) => e(r, { ...t, index: i })), py = (n, e) => ({ tr: t, commands: r }) => r.insertContentAt({ from: t.selection.from, to: t.selection.to }, n, e), Nc = (n) => {
|
|
12592
12614
|
const e = n.childNodes;
|
|
12593
12615
|
for (let t = e.length - 1; t >= 0; t -= 1) {
|
|
12594
12616
|
const r = e[t];
|
|
@@ -12653,7 +12675,7 @@ function Qn(n, e, t) {
|
|
|
12653
12675
|
}
|
|
12654
12676
|
return Qn("", e, t);
|
|
12655
12677
|
}
|
|
12656
|
-
function
|
|
12678
|
+
function my(n, e, t) {
|
|
12657
12679
|
const r = n.steps.length - 1;
|
|
12658
12680
|
if (r < e)
|
|
12659
12681
|
return;
|
|
@@ -12666,7 +12688,7 @@ function py(n, e, t) {
|
|
|
12666
12688
|
o === 0 && (o = d);
|
|
12667
12689
|
}), n.setSelection(Y.near(n.doc.resolve(o), t));
|
|
12668
12690
|
}
|
|
12669
|
-
var
|
|
12691
|
+
var gy = (n) => !("type" in n), yy = (n, e, t) => ({ tr: r, dispatch: i, editor: s }) => {
|
|
12670
12692
|
var o;
|
|
12671
12693
|
if (i) {
|
|
12672
12694
|
t = {
|
|
@@ -12707,7 +12729,7 @@ var my = (n) => !("type" in n), gy = (n, e, t) => ({ tr: r, dispatch: i, editor:
|
|
|
12707
12729
|
return a(g), !1;
|
|
12708
12730
|
}
|
|
12709
12731
|
let { from: d, to: u } = typeof n == "number" ? { from: n, to: n } : { from: n.from, to: n.to }, f = !0, h = !0;
|
|
12710
|
-
if ((
|
|
12732
|
+
if ((gy(l) ? l : [l]).forEach((g) => {
|
|
12711
12733
|
g.check(), f = f ? g.isText && g.marks.length === 0 : !1, h = h ? g.isBlock : !1;
|
|
12712
12734
|
}), d === u && h) {
|
|
12713
12735
|
const { parent: g } = r.doc.resolve(d);
|
|
@@ -12729,28 +12751,28 @@ var my = (n) => !("type" in n), gy = (n, e, t) => ({ tr: r, dispatch: i, editor:
|
|
|
12729
12751
|
const g = r.doc.resolve(d), y = g.node(), S = g.parentOffset === 0, v = y.isText || y.isTextblock, b = y.content.size > 0;
|
|
12730
12752
|
S && v && b && (d = Math.max(0, d - 1)), r.replaceWith(d, u, m);
|
|
12731
12753
|
}
|
|
12732
|
-
t.updateSelection &&
|
|
12754
|
+
t.updateSelection && my(r, r.steps.length - 1, -1), t.applyInputRules && r.setMeta("applyInputRules", { from: d, text: m }), t.applyPasteRules && r.setMeta("applyPasteRules", { from: d, text: m });
|
|
12733
12755
|
}
|
|
12734
12756
|
return !0;
|
|
12735
|
-
},
|
|
12757
|
+
}, by = () => ({ state: n, dispatch: e }) => Hp(n, e), ky = () => ({ state: n, dispatch: e }) => jp(n, e), vy = () => ({ state: n, dispatch: e }) => Lp(n, e), xy = () => ({ state: n, dispatch: e }) => Vp(n, e), wy = () => ({ state: n, dispatch: e, tr: t }) => {
|
|
12736
12758
|
try {
|
|
12737
12759
|
const r = mi(n.doc, n.selection.$from.pos, -1);
|
|
12738
12760
|
return r == null ? !1 : (t.join(r, 2), e && e(t), !0);
|
|
12739
12761
|
} catch {
|
|
12740
12762
|
return !1;
|
|
12741
12763
|
}
|
|
12742
|
-
},
|
|
12764
|
+
}, Sy = () => ({ state: n, dispatch: e, tr: t }) => {
|
|
12743
12765
|
try {
|
|
12744
12766
|
const r = mi(n.doc, n.selection.$from.pos, 1);
|
|
12745
12767
|
return r == null ? !1 : (t.join(r, 2), e && e(t), !0);
|
|
12746
12768
|
} catch {
|
|
12747
12769
|
return !1;
|
|
12748
12770
|
}
|
|
12749
|
-
},
|
|
12771
|
+
}, Cy = () => ({ state: n, dispatch: e }) => Pp(n, e), My = () => ({ state: n, dispatch: e }) => zp(n, e);
|
|
12750
12772
|
function Ic() {
|
|
12751
12773
|
return typeof navigator < "u" ? /Mac/.test(navigator.platform) : !1;
|
|
12752
12774
|
}
|
|
12753
|
-
function
|
|
12775
|
+
function Ty(n) {
|
|
12754
12776
|
const e = n.split(/-(?!$)/);
|
|
12755
12777
|
let t = e[e.length - 1];
|
|
12756
12778
|
t === "Space" && (t = " ");
|
|
@@ -12772,8 +12794,8 @@ function My(n) {
|
|
|
12772
12794
|
}
|
|
12773
12795
|
return r && (t = `Alt-${t}`), i && (t = `Ctrl-${t}`), o && (t = `Meta-${t}`), s && (t = `Shift-${t}`), t;
|
|
12774
12796
|
}
|
|
12775
|
-
var
|
|
12776
|
-
const s =
|
|
12797
|
+
var Ey = (n) => ({ editor: e, view: t, tr: r, dispatch: i }) => {
|
|
12798
|
+
const s = Ty(n).split(/-(?!$)/), o = s.find((c) => !["Alt", "Ctrl", "Meta", "Shift"].includes(c)), l = new KeyboardEvent("keydown", {
|
|
12777
12799
|
key: o === "Space" ? " " : o,
|
|
12778
12800
|
altKey: s.includes("Alt"),
|
|
12779
12801
|
ctrlKey: s.includes("Ctrl"),
|
|
@@ -12804,13 +12826,13 @@ function It(n, e, t = {}) {
|
|
|
12804
12826
|
const a = i - r, c = l.filter((u) => o ? o.name === u.node.type.name : !0).filter((u) => Lr(u.node.attrs, t, { strict: !1 }));
|
|
12805
12827
|
return s ? !!c.length : c.reduce((u, f) => u + f.to - f.from, 0) >= a;
|
|
12806
12828
|
}
|
|
12807
|
-
var
|
|
12829
|
+
var Ay = (n, e = {}) => ({ state: t, dispatch: r }) => {
|
|
12808
12830
|
const i = ge(n, t.schema);
|
|
12809
12831
|
return It(t, i, e) ? qp(t, r) : !1;
|
|
12810
|
-
},
|
|
12832
|
+
}, Oy = () => ({ state: n, dispatch: e }) => Jp(n, e), Ny = (n) => ({ state: e, dispatch: t }) => {
|
|
12811
12833
|
const r = ge(n, e.schema);
|
|
12812
12834
|
return nm(r)(e, t);
|
|
12813
|
-
},
|
|
12835
|
+
}, Iy = () => ({ state: n, dispatch: e }) => Up(n, e);
|
|
12814
12836
|
function Si(n, e) {
|
|
12815
12837
|
return e.nodes[n] ? "node" : e.marks[n] ? "mark" : null;
|
|
12816
12838
|
}
|
|
@@ -12818,7 +12840,7 @@ function Dl(n, e) {
|
|
|
12818
12840
|
const t = typeof e == "string" ? [e] : e;
|
|
12819
12841
|
return Object.keys(n).reduce((r, i) => (t.includes(i) || (r[i] = n[i]), r), {});
|
|
12820
12842
|
}
|
|
12821
|
-
var
|
|
12843
|
+
var Dy = (n, e) => ({ tr: t, state: r, dispatch: i }) => {
|
|
12822
12844
|
let s = null, o = null;
|
|
12823
12845
|
const l = Si(
|
|
12824
12846
|
typeof n == "string" ? n : n.name,
|
|
@@ -12835,13 +12857,13 @@ var Iy = (n, e) => ({ tr: t, state: r, dispatch: i }) => {
|
|
|
12835
12857
|
});
|
|
12836
12858
|
});
|
|
12837
12859
|
}), a;
|
|
12838
|
-
},
|
|
12860
|
+
}, $y = () => ({ tr: n, dispatch: e }) => (e && n.scrollIntoView(), !0), Ry = () => ({ tr: n, dispatch: e }) => {
|
|
12839
12861
|
if (e) {
|
|
12840
12862
|
const t = new Ye(n.doc);
|
|
12841
12863
|
n.setSelection(t);
|
|
12842
12864
|
}
|
|
12843
12865
|
return !0;
|
|
12844
|
-
},
|
|
12866
|
+
}, Ly = () => ({ state: n, dispatch: e }) => Bp(n, e), Py = () => ({ state: n, dispatch: e }) => Fp(n, e), zy = () => ({ state: n, dispatch: e }) => Gp(n, e), By = () => ({ state: n, dispatch: e }) => Xp(n, e), Vy = () => ({ state: n, dispatch: e }) => Qp(n, e);
|
|
12845
12867
|
function bs(n, e, t = {}, r = {}) {
|
|
12846
12868
|
return Qn(n, e, {
|
|
12847
12869
|
slice: !1,
|
|
@@ -12849,7 +12871,7 @@ function bs(n, e, t = {}, r = {}) {
|
|
|
12849
12871
|
errorOnInvalidContent: r.errorOnInvalidContent
|
|
12850
12872
|
});
|
|
12851
12873
|
}
|
|
12852
|
-
var
|
|
12874
|
+
var Fy = (n, { errorOnInvalidContent: e, emitUpdate: t = !0, parseOptions: r = {} } = {}) => ({ editor: i, tr: s, dispatch: o, commands: l }) => {
|
|
12853
12875
|
const { doc: a } = s;
|
|
12854
12876
|
if (r.preserveWhitespace !== "full") {
|
|
12855
12877
|
const c = bs(n, i.schema, r, {
|
|
@@ -12878,7 +12900,7 @@ function $c(n, e) {
|
|
|
12878
12900
|
});
|
|
12879
12901
|
}), t;
|
|
12880
12902
|
}
|
|
12881
|
-
function
|
|
12903
|
+
function Hy(n) {
|
|
12882
12904
|
for (let e = 0; e < n.edgeCount; e += 1) {
|
|
12883
12905
|
const { type: t } = n.edge(e);
|
|
12884
12906
|
if (t.isTextblock && !t.hasRequiredAttrs())
|
|
@@ -12886,7 +12908,7 @@ function Fy(n) {
|
|
|
12886
12908
|
}
|
|
12887
12909
|
return null;
|
|
12888
12910
|
}
|
|
12889
|
-
function
|
|
12911
|
+
function jy(n, e, t) {
|
|
12890
12912
|
const r = [];
|
|
12891
12913
|
return n.nodesBetween(e.from, e.to, (i, s) => {
|
|
12892
12914
|
t(i) && r.push({
|
|
@@ -12895,7 +12917,7 @@ function Hy(n, e, t) {
|
|
|
12895
12917
|
});
|
|
12896
12918
|
}), r;
|
|
12897
12919
|
}
|
|
12898
|
-
function
|
|
12920
|
+
function qy(n, e) {
|
|
12899
12921
|
for (let t = n.depth; t > 0; t -= 1) {
|
|
12900
12922
|
const r = n.node(t);
|
|
12901
12923
|
if (e(r))
|
|
@@ -12908,7 +12930,7 @@ function jy(n, e) {
|
|
|
12908
12930
|
}
|
|
12909
12931
|
}
|
|
12910
12932
|
function Ci(n) {
|
|
12911
|
-
return (e) =>
|
|
12933
|
+
return (e) => qy(e.$from, n);
|
|
12912
12934
|
}
|
|
12913
12935
|
function U(n, e, t) {
|
|
12914
12936
|
return n.config[e] === void 0 && n.parent ? U(n.parent, e, t) : typeof n.config[e] == "function" ? n.config[e].bind({
|
|
@@ -12936,7 +12958,7 @@ function Rc(n) {
|
|
|
12936
12958
|
function se(n, e = void 0, ...t) {
|
|
12937
12959
|
return Rc(n) ? e ? n.bind(e)(...t) : n(...t) : n;
|
|
12938
12960
|
}
|
|
12939
|
-
function
|
|
12961
|
+
function Uy(n = {}) {
|
|
12940
12962
|
return Object.keys(n).length === 0 && n.constructor === Object;
|
|
12941
12963
|
}
|
|
12942
12964
|
function bn(n) {
|
|
@@ -13040,7 +13062,7 @@ function Xn(n, e) {
|
|
|
13040
13062
|
[t.name]: n.attrs[t.name]
|
|
13041
13063
|
}).reduce((t, r) => ye(t, r), {});
|
|
13042
13064
|
}
|
|
13043
|
-
function
|
|
13065
|
+
function Wy(n) {
|
|
13044
13066
|
return typeof n != "string" ? n : n.match(/^[+-]?(?:\d*\.)?\d+$/) ? Number(n) : n === "true" ? !0 : n === "false" ? !1 : n;
|
|
13045
13067
|
}
|
|
13046
13068
|
function $l(n, e) {
|
|
@@ -13051,7 +13073,7 @@ function $l(n, e) {
|
|
|
13051
13073
|
if (r === !1)
|
|
13052
13074
|
return !1;
|
|
13053
13075
|
const i = e.reduce((s, o) => {
|
|
13054
|
-
const l = o.attribute.parseHTML ? o.attribute.parseHTML(t) :
|
|
13076
|
+
const l = o.attribute.parseHTML ? o.attribute.parseHTML(t) : Wy(t.getAttribute(o.name));
|
|
13055
13077
|
return l == null ? s : {
|
|
13056
13078
|
...s,
|
|
13057
13079
|
[o.name]: l
|
|
@@ -13064,7 +13086,7 @@ function $l(n, e) {
|
|
|
13064
13086
|
function Rl(n) {
|
|
13065
13087
|
return Object.fromEntries(
|
|
13066
13088
|
// @ts-ignore
|
|
13067
|
-
Object.entries(n).filter(([e, t]) => e === "attrs" &&
|
|
13089
|
+
Object.entries(n).filter(([e, t]) => e === "attrs" && Uy(t) ? !1 : t != null)
|
|
13068
13090
|
);
|
|
13069
13091
|
}
|
|
13070
13092
|
function Ll(n) {
|
|
@@ -13072,7 +13094,7 @@ function Ll(n) {
|
|
|
13072
13094
|
const r = {};
|
|
13073
13095
|
return !((e = n?.attribute) != null && e.isRequired) && "default" in (n?.attribute || {}) && (r.default = n.attribute.default), ((t = n?.attribute) == null ? void 0 : t.validate) !== void 0 && (r.validate = n.attribute.validate), [n.name, r];
|
|
13074
13096
|
}
|
|
13075
|
-
function
|
|
13097
|
+
function Ky(n, e) {
|
|
13076
13098
|
var t;
|
|
13077
13099
|
const r = Lc(n), { nodeExtensions: i, markExtensions: s } = bn(n), o = (t = i.find((c) => U(c, "topNode"))) == null ? void 0 : t.name, l = Object.fromEntries(
|
|
13078
13100
|
i.map((c) => {
|
|
@@ -13154,7 +13176,7 @@ function Wy(n, e) {
|
|
|
13154
13176
|
marks: a
|
|
13155
13177
|
});
|
|
13156
13178
|
}
|
|
13157
|
-
function
|
|
13179
|
+
function Jy(n) {
|
|
13158
13180
|
const e = n.filter((t, r) => n.indexOf(t) !== r);
|
|
13159
13181
|
return Array.from(new Set(e));
|
|
13160
13182
|
}
|
|
@@ -13165,7 +13187,7 @@ function zr(n) {
|
|
|
13165
13187
|
});
|
|
13166
13188
|
}
|
|
13167
13189
|
function Pc(n) {
|
|
13168
|
-
const e = zr(ro(n)), t =
|
|
13190
|
+
const e = zr(ro(n)), t = Jy(e.map((r) => r.name));
|
|
13169
13191
|
return t.length && console.warn(
|
|
13170
13192
|
`[tiptap warn]: Duplicate extension names found: [${t.map((r) => `'${r}'`).join(", ")}]. This can lead to issues.`
|
|
13171
13193
|
), e;
|
|
@@ -13190,7 +13212,7 @@ function zc(n, e, t) {
|
|
|
13190
13212
|
a.isText && (l += (f = a?.text) == null ? void 0 : f.slice(Math.max(r, c) - c, i - c));
|
|
13191
13213
|
}), l;
|
|
13192
13214
|
}
|
|
13193
|
-
function
|
|
13215
|
+
function Gy(n, e) {
|
|
13194
13216
|
const t = {
|
|
13195
13217
|
from: 0,
|
|
13196
13218
|
to: n.content.size
|
|
@@ -13202,7 +13224,7 @@ function Bc(n) {
|
|
|
13202
13224
|
Object.entries(n.nodes).filter(([, e]) => e.spec.toText).map(([e, t]) => [e, t.spec.toText])
|
|
13203
13225
|
);
|
|
13204
13226
|
}
|
|
13205
|
-
function
|
|
13227
|
+
function Yy(n, e) {
|
|
13206
13228
|
const t = ge(e, n.schema), { from: r, to: i } = n.selection, s = [];
|
|
13207
13229
|
n.doc.nodesBetween(r, i, (l) => {
|
|
13208
13230
|
s.push(l);
|
|
@@ -13215,17 +13237,17 @@ function Vc(n, e) {
|
|
|
13215
13237
|
typeof e == "string" ? e : e.name,
|
|
13216
13238
|
n.schema
|
|
13217
13239
|
);
|
|
13218
|
-
return t === "node" ?
|
|
13240
|
+
return t === "node" ? Yy(n, e) : t === "mark" ? Dc(n, e) : {};
|
|
13219
13241
|
}
|
|
13220
|
-
function
|
|
13242
|
+
function Qy(n, e = JSON.stringify) {
|
|
13221
13243
|
const t = {};
|
|
13222
13244
|
return n.filter((r) => {
|
|
13223
13245
|
const i = e(r);
|
|
13224
13246
|
return Object.prototype.hasOwnProperty.call(t, i) ? !1 : t[i] = !0;
|
|
13225
13247
|
});
|
|
13226
13248
|
}
|
|
13227
|
-
function
|
|
13228
|
-
const e =
|
|
13249
|
+
function Xy(n) {
|
|
13250
|
+
const e = Qy(n);
|
|
13229
13251
|
return e.length === 1 ? e : e.filter((t, r) => !e.filter((s, o) => o !== r).some((s) => t.oldRange.from >= s.oldRange.from && t.oldRange.to <= s.oldRange.to && t.newRange.from >= s.newRange.from && t.newRange.to <= s.newRange.to));
|
|
13230
13252
|
}
|
|
13231
13253
|
function Fc(n) {
|
|
@@ -13255,7 +13277,7 @@ function Fc(n) {
|
|
|
13255
13277
|
}
|
|
13256
13278
|
});
|
|
13257
13279
|
});
|
|
13258
|
-
}),
|
|
13280
|
+
}), Xy(r);
|
|
13259
13281
|
}
|
|
13260
13282
|
function so(n, e, t) {
|
|
13261
13283
|
const r = [];
|
|
@@ -13275,7 +13297,7 @@ function so(n, e, t) {
|
|
|
13275
13297
|
);
|
|
13276
13298
|
}), r;
|
|
13277
13299
|
}
|
|
13278
|
-
var
|
|
13300
|
+
var Zy = (n, e, t, r = 20) => {
|
|
13279
13301
|
const i = n.doc.resolve(t);
|
|
13280
13302
|
let s = r, o = null;
|
|
13281
13303
|
for (; s > 0 && o === null; ) {
|
|
@@ -13295,7 +13317,7 @@ function vr(n, e, t) {
|
|
|
13295
13317
|
})
|
|
13296
13318
|
);
|
|
13297
13319
|
}
|
|
13298
|
-
var
|
|
13320
|
+
var _y = (n, e = 500) => {
|
|
13299
13321
|
let t = "";
|
|
13300
13322
|
const r = n.parentOffset;
|
|
13301
13323
|
return n.parent.nodesBetween(Math.max(0, r - e), r, (i, s, o, l) => {
|
|
@@ -13334,13 +13356,13 @@ function ks(n, e, t = {}) {
|
|
|
13334
13356
|
const a = l.filter((u) => s ? s.name === u.mark.type.name : !0).filter((u) => Lr(u.mark.attrs, t, { strict: !1 })).reduce((u, f) => u + f.to - f.from, 0), c = l.filter((u) => s ? u.mark.type !== s && u.mark.type.excludes(s) : !0).reduce((u, f) => u + f.to - f.from, 0);
|
|
13335
13357
|
return (a > 0 ? a + c : a) >= o;
|
|
13336
13358
|
}
|
|
13337
|
-
function
|
|
13359
|
+
function e0(n, e, t = {}) {
|
|
13338
13360
|
if (!e)
|
|
13339
13361
|
return It(n, null, t) || ks(n, null, t);
|
|
13340
13362
|
const r = Si(e, n.schema);
|
|
13341
13363
|
return r === "node" ? It(n, e, t) : r === "mark" ? ks(n, e, t) : !1;
|
|
13342
13364
|
}
|
|
13343
|
-
var
|
|
13365
|
+
var t0 = (n, e) => {
|
|
13344
13366
|
const { $from: t, $to: r, $anchor: i } = n.selection;
|
|
13345
13367
|
if (e) {
|
|
13346
13368
|
const s = Ci((l) => l.type.name === e)(n.selection);
|
|
@@ -13350,7 +13372,7 @@ var e0 = (n, e) => {
|
|
|
13350
13372
|
return i.pos + 1 === o.end();
|
|
13351
13373
|
}
|
|
13352
13374
|
return !(r.parentOffset < r.parent.nodeSize - 2 || t.pos !== r.pos);
|
|
13353
|
-
},
|
|
13375
|
+
}, n0 = (n) => {
|
|
13354
13376
|
const { $from: e, $to: t } = n.selection;
|
|
13355
13377
|
return !(e.parentOffset > 0 || e.pos !== t.pos);
|
|
13356
13378
|
};
|
|
@@ -13415,17 +13437,17 @@ var jc = class qc {
|
|
|
13415
13437
|
};
|
|
13416
13438
|
}
|
|
13417
13439
|
};
|
|
13418
|
-
function
|
|
13440
|
+
function r0(n, e) {
|
|
13419
13441
|
const t = e.mapping.mapResult(n.position);
|
|
13420
13442
|
return {
|
|
13421
13443
|
position: new jc(t.pos),
|
|
13422
13444
|
mapResult: t
|
|
13423
13445
|
};
|
|
13424
13446
|
}
|
|
13425
|
-
function
|
|
13447
|
+
function i0(n) {
|
|
13426
13448
|
return new jc(n);
|
|
13427
13449
|
}
|
|
13428
|
-
function
|
|
13450
|
+
function s0(n, e, t) {
|
|
13429
13451
|
var r;
|
|
13430
13452
|
const { selection: i } = e;
|
|
13431
13453
|
let s = null;
|
|
@@ -13447,7 +13469,7 @@ function i0(n, e, t) {
|
|
|
13447
13469
|
}), c;
|
|
13448
13470
|
});
|
|
13449
13471
|
}
|
|
13450
|
-
var
|
|
13472
|
+
var o0 = (n, e = {}) => ({ tr: t, state: r, dispatch: i }) => {
|
|
13451
13473
|
const { selection: s } = t, { empty: o, ranges: l } = s, a = mt(n, r.schema);
|
|
13452
13474
|
if (i)
|
|
13453
13475
|
if (o) {
|
|
@@ -13475,18 +13497,18 @@ var s0 = (n, e = {}) => ({ tr: t, state: r, dispatch: i }) => {
|
|
|
13475
13497
|
}) : t.addMark(p, m, a.create(e));
|
|
13476
13498
|
});
|
|
13477
13499
|
});
|
|
13478
|
-
return
|
|
13479
|
-
},
|
|
13500
|
+
return s0(r, t, a);
|
|
13501
|
+
}, l0 = (n, e) => ({ tr: t }) => (t.setMeta(n, e), !0), a0 = (n, e = {}) => ({ state: t, dispatch: r, chain: i }) => {
|
|
13480
13502
|
const s = ge(n, t.schema);
|
|
13481
13503
|
let o;
|
|
13482
13504
|
return t.selection.$anchor.sameParent(t.selection.$head) && (o = t.selection.$anchor.parent.attrs), s.isTextblock ? i().command(({ commands: l }) => Qo(s, { ...o, ...e })(t) ? !0 : l.clearNodes()).command(({ state: l }) => Qo(s, { ...o, ...e })(l, r)).run() : (console.warn('[tiptap warn]: Currently "setNode()" only supports text block nodes.'), !1);
|
|
13483
|
-
},
|
|
13505
|
+
}, c0 = (n) => ({ tr: e, dispatch: t }) => {
|
|
13484
13506
|
if (t) {
|
|
13485
13507
|
const { doc: r } = e, i = Vt(n, 0, r.content.size), s = K.create(r, i);
|
|
13486
13508
|
e.setSelection(s);
|
|
13487
13509
|
}
|
|
13488
13510
|
return !0;
|
|
13489
|
-
},
|
|
13511
|
+
}, d0 = (n, e) => ({ tr: t, state: r, dispatch: i }) => {
|
|
13490
13512
|
const { selection: s } = r;
|
|
13491
13513
|
let o, l;
|
|
13492
13514
|
return typeof e == "number" ? (o = e, l = e) : e && "from" in e && "to" in e ? (o = e.from, l = e.to) : (o = s.from, l = s.to), i && t.doc.nodesBetween(o, l, (a, c) => {
|
|
@@ -13495,13 +13517,13 @@ var s0 = (n, e = {}) => ({ tr: t, state: r, dispatch: i }) => {
|
|
|
13495
13517
|
dir: n
|
|
13496
13518
|
});
|
|
13497
13519
|
}), !0;
|
|
13498
|
-
},
|
|
13520
|
+
}, u0 = (n) => ({ tr: e, dispatch: t }) => {
|
|
13499
13521
|
if (t) {
|
|
13500
13522
|
const { doc: r } = e, { from: i, to: s } = typeof n == "number" ? { from: n, to: n } : n, o = J.atStart(r).from, l = J.atEnd(r).to, a = Vt(i, o, l), c = Vt(s, o, l), d = J.create(r, a, c);
|
|
13501
13523
|
e.setSelection(d);
|
|
13502
13524
|
}
|
|
13503
13525
|
return !0;
|
|
13504
|
-
},
|
|
13526
|
+
}, f0 = (n) => ({ state: e, dispatch: t }) => {
|
|
13505
13527
|
const r = ge(n, e.schema);
|
|
13506
13528
|
return sm(r)(e, t);
|
|
13507
13529
|
};
|
|
@@ -13512,13 +13534,13 @@ function Bl(n, e) {
|
|
|
13512
13534
|
n.tr.ensureMarks(r);
|
|
13513
13535
|
}
|
|
13514
13536
|
}
|
|
13515
|
-
var
|
|
13537
|
+
var h0 = ({ keepMarks: n = !0 } = {}) => ({ tr: e, state: t, dispatch: r, editor: i }) => {
|
|
13516
13538
|
const { selection: s, doc: o } = e, { $from: l, $to: a } = s, c = i.extensionManager.attributes, d = vr(c, l.node().type.name, l.node().attrs);
|
|
13517
13539
|
if (s instanceof K && s.node.isBlock)
|
|
13518
13540
|
return !l.parentOffset || !un(o, l.pos) ? !1 : (r && (n && Bl(t, i.extensionManager.splittableMarks), e.split(l.pos).scrollIntoView()), !0);
|
|
13519
13541
|
if (!l.parent.isBlock)
|
|
13520
13542
|
return !1;
|
|
13521
|
-
const u = a.parentOffset === a.parent.content.size, f = l.depth === 0 ? void 0 :
|
|
13543
|
+
const u = a.parentOffset === a.parent.content.size, f = l.depth === 0 ? void 0 : Hy(l.node(-1).contentMatchAt(l.indexAfter(-1)));
|
|
13522
13544
|
let h = u && f ? [
|
|
13523
13545
|
{
|
|
13524
13546
|
type: f,
|
|
@@ -13538,7 +13560,7 @@ var f0 = ({ keepMarks: n = !0 } = {}) => ({ tr: e, state: t, dispatch: r, editor
|
|
|
13538
13560
|
n && Bl(t, i.extensionManager.splittableMarks), e.scrollIntoView();
|
|
13539
13561
|
}
|
|
13540
13562
|
return p;
|
|
13541
|
-
},
|
|
13563
|
+
}, p0 = (n, e = {}) => ({ tr: t, state: r, dispatch: i, editor: s }) => {
|
|
13542
13564
|
var o;
|
|
13543
13565
|
const l = ge(n, r.schema), { $from: a, $to: c } = r.selection, d = r.selection.node;
|
|
13544
13566
|
if (d && d.isBlock || a.depth < 2 || !a.sameParent(c))
|
|
@@ -13614,7 +13636,7 @@ var f0 = ({ keepMarks: n = !0 } = {}) => ({ tr: e, state: t, dispatch: r, editor
|
|
|
13614
13636
|
return !0;
|
|
13615
13637
|
const i = n.doc.nodeAt(r);
|
|
13616
13638
|
return t.node.type === i?.type && Dt(n.doc, r) && n.join(r), !0;
|
|
13617
|
-
},
|
|
13639
|
+
}, m0 = (n, e, t, r = {}) => ({ editor: i, tr: s, state: o, dispatch: l, chain: a, commands: c, can: d }) => {
|
|
13618
13640
|
const { extensions: u, splittableMarks: f } = i.extensionManager, h = ge(n, o.schema), p = ge(e, o.schema), { selection: m, storedMarks: g } = o, { $from: y, $to: S } = m, v = y.blockRange(S), b = g || m.$to.parentOffset && m.$from.marks();
|
|
13619
13641
|
if (!v)
|
|
13620
13642
|
return !1;
|
|
@@ -13629,17 +13651,17 @@ var f0 = ({ keepMarks: n = !0 } = {}) => ({ tr: e, state: t, dispatch: r, editor
|
|
|
13629
13651
|
const w = d().wrapInList(h, r), x = b.filter((M) => f.includes(M.type.name));
|
|
13630
13652
|
return s.ensureMarks(x), w ? !0 : c.clearNodes();
|
|
13631
13653
|
}).wrapInList(h, r).command(() => Wi(s, h)).command(() => Ki(s, h)).run();
|
|
13632
|
-
},
|
|
13654
|
+
}, g0 = (n, e = {}, t = {}) => ({ state: r, commands: i }) => {
|
|
13633
13655
|
const { extendEmptyMarkRange: s = !1 } = t, o = mt(n, r.schema);
|
|
13634
13656
|
return ks(r, o, e) ? i.unsetMark(o, { extendEmptyMarkRange: s }) : i.setMark(o, e);
|
|
13635
|
-
},
|
|
13657
|
+
}, y0 = (n, e, t = {}) => ({ state: r, commands: i }) => {
|
|
13636
13658
|
const s = ge(n, r.schema), o = ge(e, r.schema), l = It(r, s, t);
|
|
13637
13659
|
let a;
|
|
13638
13660
|
return r.selection.$anchor.sameParent(r.selection.$head) && (a = r.selection.$anchor.parent.attrs), l ? i.setNode(o, a) : i.setNode(s, { ...a, ...t });
|
|
13639
|
-
},
|
|
13661
|
+
}, b0 = (n, e = {}) => ({ state: t, commands: r }) => {
|
|
13640
13662
|
const i = ge(n, t.schema);
|
|
13641
13663
|
return It(t, i, e) ? r.lift(i) : r.wrapIn(i, e);
|
|
13642
|
-
},
|
|
13664
|
+
}, k0 = () => ({ state: n, dispatch: e }) => {
|
|
13643
13665
|
const t = n.plugins;
|
|
13644
13666
|
for (let r = 0; r < t.length; r += 1) {
|
|
13645
13667
|
const i = t[r];
|
|
@@ -13659,12 +13681,12 @@ var f0 = ({ keepMarks: n = !0 } = {}) => ({ tr: e, state: t, dispatch: r, editor
|
|
|
13659
13681
|
}
|
|
13660
13682
|
}
|
|
13661
13683
|
return !1;
|
|
13662
|
-
},
|
|
13684
|
+
}, v0 = () => ({ tr: n, dispatch: e }) => {
|
|
13663
13685
|
const { selection: t } = n, { empty: r, ranges: i } = t;
|
|
13664
13686
|
return r || e && i.forEach((s) => {
|
|
13665
13687
|
n.removeMark(s.$from.pos, s.$to.pos);
|
|
13666
13688
|
}), !0;
|
|
13667
|
-
},
|
|
13689
|
+
}, x0 = (n, e = {}) => ({ tr: t, state: r, dispatch: i }) => {
|
|
13668
13690
|
var s;
|
|
13669
13691
|
const { extendEmptyMarkRange: o = !1 } = e, { selection: l } = t, a = mt(n, r.schema), { $from: c, empty: d, ranges: u } = l;
|
|
13670
13692
|
if (!i)
|
|
@@ -13678,7 +13700,7 @@ var f0 = ({ keepMarks: n = !0 } = {}) => ({ tr: e, state: t, dispatch: r, editor
|
|
|
13678
13700
|
t.removeMark(f.$from.pos, f.$to.pos, a);
|
|
13679
13701
|
});
|
|
13680
13702
|
return t.removeStoredMark(a), !0;
|
|
13681
|
-
},
|
|
13703
|
+
}, w0 = (n) => ({ tr: e, state: t, dispatch: r }) => {
|
|
13682
13704
|
const { selection: i } = t;
|
|
13683
13705
|
let s, o;
|
|
13684
13706
|
return typeof n == "number" ? (s = n, o = n) : n && "from" in n && "to" in n ? (s = n.from, o = n.to) : (s = i.from, o = i.to), r && e.doc.nodesBetween(s, o, (l, a) => {
|
|
@@ -13687,7 +13709,7 @@ var f0 = ({ keepMarks: n = !0 } = {}) => ({ tr: e, state: t, dispatch: r, editor
|
|
|
13687
13709
|
const c = { ...l.attrs };
|
|
13688
13710
|
delete c.dir, e.setNodeMarkup(a, void 0, c);
|
|
13689
13711
|
}), !0;
|
|
13690
|
-
},
|
|
13712
|
+
}, S0 = (n, e = {}) => ({ tr: t, state: r, dispatch: i }) => {
|
|
13691
13713
|
let s = null, o = null;
|
|
13692
13714
|
const l = Si(
|
|
13693
13715
|
typeof n == "string" ? n : n.name,
|
|
@@ -13733,13 +13755,13 @@ var f0 = ({ keepMarks: n = !0 } = {}) => ({ tr: e, state: t, dispatch: r, editor
|
|
|
13733
13755
|
);
|
|
13734
13756
|
}));
|
|
13735
13757
|
}), a;
|
|
13736
|
-
},
|
|
13758
|
+
}, C0 = (n, e = {}) => ({ state: t, dispatch: r }) => {
|
|
13737
13759
|
const i = ge(n, t.schema);
|
|
13738
13760
|
return Zp(i, e)(t, r);
|
|
13739
|
-
},
|
|
13761
|
+
}, M0 = (n, e = {}) => ({ state: t, dispatch: r }) => {
|
|
13740
13762
|
const i = ge(n, t.schema);
|
|
13741
13763
|
return _p(i, e)(t, r);
|
|
13742
|
-
},
|
|
13764
|
+
}, T0 = class {
|
|
13743
13765
|
constructor() {
|
|
13744
13766
|
this.callbacks = {};
|
|
13745
13767
|
}
|
|
@@ -13768,7 +13790,7 @@ var f0 = ({ keepMarks: n = !0 } = {}) => ({ tr: e, state: t, dispatch: r, editor
|
|
|
13768
13790
|
var e;
|
|
13769
13791
|
this.find = n.find, this.handler = n.handler, this.undoable = (e = n.undoable) != null ? e : !0;
|
|
13770
13792
|
}
|
|
13771
|
-
},
|
|
13793
|
+
}, E0 = (n, e) => {
|
|
13772
13794
|
if (to(e))
|
|
13773
13795
|
return e.exec(n);
|
|
13774
13796
|
const t = e(n);
|
|
@@ -13789,11 +13811,11 @@ function ur(n) {
|
|
|
13789
13811
|
)
|
|
13790
13812
|
return !1;
|
|
13791
13813
|
let d = !1;
|
|
13792
|
-
const u =
|
|
13814
|
+
const u = _y(c) + s;
|
|
13793
13815
|
return o.forEach((f) => {
|
|
13794
13816
|
if (d)
|
|
13795
13817
|
return;
|
|
13796
|
-
const h =
|
|
13818
|
+
const h = E0(u, f.find);
|
|
13797
13819
|
if (!h)
|
|
13798
13820
|
return;
|
|
13799
13821
|
const p = a.state.tr, m = xi({
|
|
@@ -13821,7 +13843,7 @@ function ur(n) {
|
|
|
13821
13843
|
}), a.dispatch(p), d = !0);
|
|
13822
13844
|
}), d;
|
|
13823
13845
|
}
|
|
13824
|
-
function
|
|
13846
|
+
function A0(n) {
|
|
13825
13847
|
const { editor: e, rules: t } = n, r = new ue({
|
|
13826
13848
|
state: {
|
|
13827
13849
|
init() {
|
|
@@ -13893,11 +13915,11 @@ function E0(n) {
|
|
|
13893
13915
|
});
|
|
13894
13916
|
return r;
|
|
13895
13917
|
}
|
|
13896
|
-
function
|
|
13918
|
+
function O0(n) {
|
|
13897
13919
|
return Object.prototype.toString.call(n).slice(8, -1);
|
|
13898
13920
|
}
|
|
13899
13921
|
function fr(n) {
|
|
13900
|
-
return
|
|
13922
|
+
return O0(n) !== "Object" ? !1 : n.constructor === Object && Object.getPrototypeOf(n) === Object.prototype;
|
|
13901
13923
|
}
|
|
13902
13924
|
function Uc(n, e) {
|
|
13903
13925
|
const t = { ...n };
|
|
@@ -13975,14 +13997,14 @@ var oo = class {
|
|
|
13975
13997
|
return super.extend(t);
|
|
13976
13998
|
}
|
|
13977
13999
|
};
|
|
13978
|
-
function
|
|
14000
|
+
function N0(n) {
|
|
13979
14001
|
return typeof n == "number";
|
|
13980
14002
|
}
|
|
13981
|
-
var
|
|
14003
|
+
var I0 = class {
|
|
13982
14004
|
constructor(n) {
|
|
13983
14005
|
this.find = n.find, this.handler = n.handler;
|
|
13984
14006
|
}
|
|
13985
|
-
},
|
|
14007
|
+
}, D0 = (n, e, t) => {
|
|
13986
14008
|
if (to(e))
|
|
13987
14009
|
return [...n.matchAll(e)];
|
|
13988
14010
|
const r = e(n, t);
|
|
@@ -13991,7 +14013,7 @@ var N0 = class {
|
|
|
13991
14013
|
return s.index = i.index, s.input = n, s.data = i.data, i.replaceWith && (i.text.includes(i.replaceWith) || console.warn('[tiptap warn]: "pasteRuleMatch.replaceWith" must be part of "pasteRuleMatch.text".'), s.push(i.replaceWith)), s;
|
|
13992
14014
|
}) : [];
|
|
13993
14015
|
};
|
|
13994
|
-
function
|
|
14016
|
+
function $0(n) {
|
|
13995
14017
|
const { editor: e, state: t, from: r, to: i, rule: s, pasteEvent: o, dropEvent: l } = n, { commands: a, chain: c, can: d } = new wi({
|
|
13996
14018
|
editor: e,
|
|
13997
14019
|
state: t
|
|
@@ -14004,7 +14026,7 @@ function D0(n) {
|
|
|
14004
14026
|
if (k >= w)
|
|
14005
14027
|
return;
|
|
14006
14028
|
const x = h.isText ? h.text || "" : h.textBetween(k - p, w - p, void 0, "");
|
|
14007
|
-
|
|
14029
|
+
D0(x, s.find, o).forEach((D) => {
|
|
14008
14030
|
if (D.index === void 0)
|
|
14009
14031
|
return;
|
|
14010
14032
|
const H = k + D.index + 1, te = H + D[0].length, Q = {
|
|
@@ -14024,14 +14046,14 @@ function D0(n) {
|
|
|
14024
14046
|
});
|
|
14025
14047
|
}), u.every((h) => h !== null);
|
|
14026
14048
|
}
|
|
14027
|
-
var hr = null,
|
|
14049
|
+
var hr = null, R0 = (n) => {
|
|
14028
14050
|
var e;
|
|
14029
14051
|
const t = new ClipboardEvent("paste", {
|
|
14030
14052
|
clipboardData: new DataTransfer()
|
|
14031
14053
|
});
|
|
14032
14054
|
return (e = t.clipboardData) == null || e.setData("text/html", n), t;
|
|
14033
14055
|
};
|
|
14034
|
-
function
|
|
14056
|
+
function L0(n) {
|
|
14035
14057
|
const { editor: e, rules: t } = n;
|
|
14036
14058
|
let r = null, i = !1, s = !1, o = typeof ClipboardEvent < "u" ? new ClipboardEvent("paste") : null, l;
|
|
14037
14059
|
try {
|
|
@@ -14050,7 +14072,7 @@ function R0(n) {
|
|
|
14050
14072
|
state: d,
|
|
14051
14073
|
transaction: m
|
|
14052
14074
|
});
|
|
14053
|
-
if (!(
|
|
14075
|
+
if (!(!$0({
|
|
14054
14076
|
editor: e,
|
|
14055
14077
|
state: g,
|
|
14056
14078
|
from: Math.max(u - 1, 0),
|
|
@@ -14108,7 +14130,7 @@ function R0(n) {
|
|
|
14108
14130
|
if (S) {
|
|
14109
14131
|
let { text: k } = y;
|
|
14110
14132
|
typeof k == "string" ? k = k : k = io(A.from(k), h.schema);
|
|
14111
|
-
const { from: w } = y, x = w + k.length, M =
|
|
14133
|
+
const { from: w } = y, x = w + k.length, M = R0(k);
|
|
14112
14134
|
return a({
|
|
14113
14135
|
rule: d,
|
|
14114
14136
|
state: h,
|
|
@@ -14118,7 +14140,7 @@ function R0(n) {
|
|
|
14118
14140
|
});
|
|
14119
14141
|
}
|
|
14120
14142
|
const v = f.doc.content.findDiffStart(h.doc.content), b = f.doc.content.findDiffEnd(h.doc.content);
|
|
14121
|
-
if (!(!
|
|
14143
|
+
if (!(!N0(v) || !b || v === b.b))
|
|
14122
14144
|
return a({
|
|
14123
14145
|
rule: d,
|
|
14124
14146
|
state: h,
|
|
@@ -14131,7 +14153,7 @@ function R0(n) {
|
|
|
14131
14153
|
}
|
|
14132
14154
|
var Ei = class {
|
|
14133
14155
|
constructor(n, e) {
|
|
14134
|
-
this.splittableMarks = [], this.editor = e, this.baseExtensions = n, this.extensions = Pc(n), this.schema =
|
|
14156
|
+
this.splittableMarks = [], this.editor = e, this.baseExtensions = n, this.extensions = Pc(n), this.schema = Ky(this.extensions, e), this.setupExtensions();
|
|
14135
14157
|
}
|
|
14136
14158
|
/**
|
|
14137
14159
|
* Get all commands from the extensions.
|
|
@@ -14177,13 +14199,13 @@ var Ei = class {
|
|
|
14177
14199
|
);
|
|
14178
14200
|
l = { ...l, ...f };
|
|
14179
14201
|
}
|
|
14180
|
-
const a =
|
|
14202
|
+
const a = Yg(l);
|
|
14181
14203
|
s.push(a);
|
|
14182
14204
|
const c = U(r, "addInputRules", i);
|
|
14183
14205
|
if (Pl(r, n.options.enableInputRules) && c) {
|
|
14184
14206
|
const f = c();
|
|
14185
14207
|
if (f && f.length) {
|
|
14186
|
-
const h =
|
|
14208
|
+
const h = A0({
|
|
14187
14209
|
editor: n,
|
|
14188
14210
|
rules: f
|
|
14189
14211
|
}), p = Array.isArray(h) ? h : [h];
|
|
@@ -14194,7 +14216,7 @@ var Ei = class {
|
|
|
14194
14216
|
if (Pl(r, n.options.enablePasteRules) && d) {
|
|
14195
14217
|
const f = d();
|
|
14196
14218
|
if (f && f.length) {
|
|
14197
|
-
const h =
|
|
14219
|
+
const h = L0({ editor: n, rules: f });
|
|
14198
14220
|
s.push(...h);
|
|
14199
14221
|
}
|
|
14200
14222
|
}
|
|
@@ -14305,7 +14327,7 @@ var Ei = class {
|
|
|
14305
14327
|
extension: t,
|
|
14306
14328
|
HTMLAttributes: d,
|
|
14307
14329
|
updateAttributes: (u) => {
|
|
14308
|
-
|
|
14330
|
+
Y0(l, n, u);
|
|
14309
14331
|
}
|
|
14310
14332
|
});
|
|
14311
14333
|
};
|
|
@@ -14343,8 +14365,8 @@ var Ei = class {
|
|
|
14343
14365
|
Ei.resolve = Pc;
|
|
14344
14366
|
Ei.sort = zr;
|
|
14345
14367
|
Ei.flatten = ro;
|
|
14346
|
-
var
|
|
14347
|
-
eo(
|
|
14368
|
+
var P0 = {};
|
|
14369
|
+
eo(P0, {
|
|
14348
14370
|
ClipboardTextSerializer: () => Jc,
|
|
14349
14371
|
Commands: () => Gc,
|
|
14350
14372
|
Delete: () => Yc,
|
|
@@ -14669,7 +14691,7 @@ var pe = class Kc extends oo {
|
|
|
14669
14691
|
})
|
|
14670
14692
|
];
|
|
14671
14693
|
}
|
|
14672
|
-
}),
|
|
14694
|
+
}), z0 = class ln {
|
|
14673
14695
|
constructor(e, t, r = !1, i = null) {
|
|
14674
14696
|
this.currentNode = null, this.actualDepth = null, this.isBlock = r, this.resolvedPos = e, this.editor = t, this.currentNode = i;
|
|
14675
14697
|
}
|
|
@@ -14783,7 +14805,7 @@ var pe = class Kc extends oo {
|
|
|
14783
14805
|
...e
|
|
14784
14806
|
}), this.editor.view.dispatch(t);
|
|
14785
14807
|
}
|
|
14786
|
-
},
|
|
14808
|
+
}, B0 = `.ProseMirror {
|
|
14787
14809
|
position: relative;
|
|
14788
14810
|
}
|
|
14789
14811
|
|
|
@@ -14854,14 +14876,14 @@ img.ProseMirror-separator {
|
|
|
14854
14876
|
.ProseMirror-focused .ProseMirror-gapcursor {
|
|
14855
14877
|
display: block;
|
|
14856
14878
|
}`;
|
|
14857
|
-
function
|
|
14879
|
+
function V0(n, e, t) {
|
|
14858
14880
|
const r = document.querySelector("style[data-tiptap-style]");
|
|
14859
14881
|
if (r !== null)
|
|
14860
14882
|
return r;
|
|
14861
14883
|
const i = document.createElement("style");
|
|
14862
14884
|
return e && i.setAttribute("nonce", e), i.setAttribute("data-tiptap-style", ""), i.innerHTML = n, document.getElementsByTagName("head")[0].appendChild(i), i;
|
|
14863
14885
|
}
|
|
14864
|
-
var
|
|
14886
|
+
var F0 = class extends T0 {
|
|
14865
14887
|
constructor(e = {}) {
|
|
14866
14888
|
super(), this.css = null, this.className = "tiptap", this.editorView = null, this.isFocused = !1, this.isInitialized = !1, this.extensionStorage = {}, this.instanceId = Math.random().toString(36).slice(2, 9), this.options = {
|
|
14867
14889
|
element: typeof document < "u" ? document.createElement("div") : null,
|
|
@@ -14898,8 +14920,8 @@ var V0 = class extends M0 {
|
|
|
14898
14920
|
onDelete: () => null,
|
|
14899
14921
|
enableExtensionDispatchTransaction: !0
|
|
14900
14922
|
}, this.isCapturingTransaction = !1, this.capturedTransaction = null, this.utils = {
|
|
14901
|
-
getUpdatedPosition:
|
|
14902
|
-
createMappablePosition:
|
|
14923
|
+
getUpdatedPosition: r0,
|
|
14924
|
+
createMappablePosition: i0
|
|
14903
14925
|
}, this.setOptions(e), this.createExtensionManager(), this.createCommandManager(), this.createSchema(), this.on("beforeCreate", this.options.onBeforeCreate), this.emit("beforeCreate", { editor: this }), this.on("mount", this.options.onMount), this.on("unmount", this.options.onUnmount), this.on("contentError", this.options.onContentError), this.on("create", this.options.onCreate), this.on("update", this.options.onUpdate), this.on("selectionUpdate", this.options.onSelectionUpdate), this.on("transaction", this.options.onTransaction), this.on("focus", this.options.onFocus), this.on("blur", this.options.onBlur), this.on("destroy", this.options.onDestroy), this.on("drop", ({ event: i, slice: s, moved: o }) => this.options.onDrop(i, s, o)), this.on("paste", ({ event: i, slice: s }) => this.options.onPaste(i, s)), this.on("delete", this.options.onDelete);
|
|
14904
14926
|
const t = this.createDoc(), r = Oc(t, this.options.autofocus);
|
|
14905
14927
|
this.editorState = dn.create({
|
|
@@ -14964,7 +14986,7 @@ var V0 = class extends M0 {
|
|
|
14964
14986
|
* Inject CSS styles.
|
|
14965
14987
|
*/
|
|
14966
14988
|
injectCSS() {
|
|
14967
|
-
this.options.injectCSS && typeof document < "u" && (this.css = B0
|
|
14989
|
+
this.options.injectCSS && typeof document < "u" && (this.css = V0(B0, this.options.injectNonce));
|
|
14968
14990
|
}
|
|
14969
14991
|
/**
|
|
14970
14992
|
* Update editor options.
|
|
@@ -15225,7 +15247,7 @@ var V0 = class extends M0 {
|
|
|
15225
15247
|
}
|
|
15226
15248
|
isActive(e, t) {
|
|
15227
15249
|
const r = typeof e == "string" ? e : null, i = typeof e == "string" ? t : e;
|
|
15228
|
-
return
|
|
15250
|
+
return e0(this.state, r, i);
|
|
15229
15251
|
}
|
|
15230
15252
|
/**
|
|
15231
15253
|
* Get the document as JSON.
|
|
@@ -15246,7 +15268,7 @@ var V0 = class extends M0 {
|
|
|
15246
15268
|
const { blockSeparator: t = `
|
|
15247
15269
|
|
|
15248
15270
|
`, textSerializers: r = {} } = e || {};
|
|
15249
|
-
return
|
|
15271
|
+
return Gy(this.state.doc, {
|
|
15250
15272
|
blockSeparator: t,
|
|
15251
15273
|
textSerializers: {
|
|
15252
15274
|
...Bc(this.schema),
|
|
@@ -15283,7 +15305,7 @@ var V0 = class extends M0 {
|
|
|
15283
15305
|
}
|
|
15284
15306
|
$pos(e) {
|
|
15285
15307
|
const t = this.state.doc.resolve(e);
|
|
15286
|
-
return new
|
|
15308
|
+
return new z0(t, this);
|
|
15287
15309
|
}
|
|
15288
15310
|
get $doc() {
|
|
15289
15311
|
return this.$pos(0);
|
|
@@ -15309,7 +15331,7 @@ function kn(n) {
|
|
|
15309
15331
|
undoable: n.undoable
|
|
15310
15332
|
});
|
|
15311
15333
|
}
|
|
15312
|
-
function
|
|
15334
|
+
function H0(n) {
|
|
15313
15335
|
return new Ti({
|
|
15314
15336
|
find: n.find,
|
|
15315
15337
|
handler: ({ state: e, range: t, match: r }) => {
|
|
@@ -15367,7 +15389,7 @@ function vn(n) {
|
|
|
15367
15389
|
undoable: n.undoable
|
|
15368
15390
|
});
|
|
15369
15391
|
}
|
|
15370
|
-
function
|
|
15392
|
+
function j0(n, e) {
|
|
15371
15393
|
const { selection: t } = n, { $from: r } = t;
|
|
15372
15394
|
if (t instanceof K) {
|
|
15373
15395
|
const s = r.index();
|
|
@@ -15382,11 +15404,11 @@ function H0(n, e) {
|
|
|
15382
15404
|
}
|
|
15383
15405
|
return !1;
|
|
15384
15406
|
}
|
|
15385
|
-
var
|
|
15386
|
-
eo(
|
|
15387
|
-
createAtomBlockMarkdownSpec: () =>
|
|
15388
|
-
createBlockMarkdownSpec: () =>
|
|
15389
|
-
createInlineMarkdownSpec: () =>
|
|
15407
|
+
var q0 = {};
|
|
15408
|
+
eo(q0, {
|
|
15409
|
+
createAtomBlockMarkdownSpec: () => U0,
|
|
15410
|
+
createBlockMarkdownSpec: () => W0,
|
|
15411
|
+
createInlineMarkdownSpec: () => G0,
|
|
15390
15412
|
parseAttributes: () => lo,
|
|
15391
15413
|
parseIndentedBlocks: () => xs,
|
|
15392
15414
|
renderNestedMarkdownContent: () => co,
|
|
@@ -15421,7 +15443,7 @@ function ao(n) {
|
|
|
15421
15443
|
t === "class" || t === "id" || (r === !0 ? e.push(t) : r !== !1 && r != null && e.push(`${t}="${String(r)}"`));
|
|
15422
15444
|
}), e.join(" ");
|
|
15423
15445
|
}
|
|
15424
|
-
function
|
|
15446
|
+
function U0(n) {
|
|
15425
15447
|
const {
|
|
15426
15448
|
nodeName: e,
|
|
15427
15449
|
name: t,
|
|
@@ -15470,7 +15492,7 @@ function q0(n) {
|
|
|
15470
15492
|
}
|
|
15471
15493
|
};
|
|
15472
15494
|
}
|
|
15473
|
-
function
|
|
15495
|
+
function W0(n) {
|
|
15474
15496
|
const {
|
|
15475
15497
|
nodeName: e,
|
|
15476
15498
|
name: t,
|
|
@@ -15566,7 +15588,7 @@ ${g}
|
|
|
15566
15588
|
}
|
|
15567
15589
|
};
|
|
15568
15590
|
}
|
|
15569
|
-
function
|
|
15591
|
+
function K0(n) {
|
|
15570
15592
|
if (!n.trim())
|
|
15571
15593
|
return {};
|
|
15572
15594
|
const e = {}, t = /(\w+)=(?:"([^"]*)"|'([^']*)')/g;
|
|
@@ -15577,16 +15599,16 @@ function W0(n) {
|
|
|
15577
15599
|
}
|
|
15578
15600
|
return e;
|
|
15579
15601
|
}
|
|
15580
|
-
function
|
|
15602
|
+
function J0(n) {
|
|
15581
15603
|
return Object.entries(n).filter(([, e]) => e != null).map(([e, t]) => `${e}="${t}"`).join(" ");
|
|
15582
15604
|
}
|
|
15583
|
-
function
|
|
15605
|
+
function G0(n) {
|
|
15584
15606
|
const {
|
|
15585
15607
|
nodeName: e,
|
|
15586
15608
|
name: t,
|
|
15587
15609
|
getContent: r,
|
|
15588
|
-
parseAttributes: i =
|
|
15589
|
-
serializeAttributes: s =
|
|
15610
|
+
parseAttributes: i = K0,
|
|
15611
|
+
serializeAttributes: s = J0,
|
|
15590
15612
|
defaultAttributes: o = {},
|
|
15591
15613
|
selfClosing: l = !1,
|
|
15592
15614
|
allowedAttributes: a
|
|
@@ -15720,7 +15742,7 @@ function co(n, e, t, r) {
|
|
|
15720
15742
|
}), a.join(`
|
|
15721
15743
|
`);
|
|
15722
15744
|
}
|
|
15723
|
-
function
|
|
15745
|
+
function Y0(n, e, t = {}) {
|
|
15724
15746
|
const { state: r } = e, { doc: i, tr: s } = r, o = n;
|
|
15725
15747
|
i.descendants((l, a) => {
|
|
15726
15748
|
const c = s.mapping.map(a), d = s.mapping.map(a) + l.nodeSize;
|
|
@@ -15764,7 +15786,7 @@ var qe = class id extends oo {
|
|
|
15764
15786
|
}
|
|
15765
15787
|
};
|
|
15766
15788
|
function Xt(n) {
|
|
15767
|
-
return new
|
|
15789
|
+
return new I0({
|
|
15768
15790
|
find: n.find,
|
|
15769
15791
|
handler: ({ state: e, range: t, match: r, pasteEvent: i }) => {
|
|
15770
15792
|
const s = se(n.getAttributes, void 0, r, i);
|
|
@@ -15795,7 +15817,7 @@ function Vl(n) {
|
|
|
15795
15817
|
}
|
|
15796
15818
|
}));
|
|
15797
15819
|
}
|
|
15798
|
-
var
|
|
15820
|
+
var Q0 = class extends F0 {
|
|
15799
15821
|
constructor(n = {}) {
|
|
15800
15822
|
return super(n), this.contentComponent = null, this.appContext = null, this.reactiveState = Vl(this.view.state), this.reactiveExtensionStorage = Vl(this.extensionStorage), this.on("beforeTransaction", ({ nextState: e }) => {
|
|
15801
15823
|
this.reactiveState.value = e, this.reactiveExtensionStorage.value = this.extensionStorage;
|
|
@@ -15821,7 +15843,7 @@ var Y0 = class extends V0 {
|
|
|
15821
15843
|
const e = super.unregisterPlugin(n);
|
|
15822
15844
|
return this.reactiveState && e && (this.reactiveState.value = e), e;
|
|
15823
15845
|
}
|
|
15824
|
-
},
|
|
15846
|
+
}, X0 = ae({
|
|
15825
15847
|
name: "EditorContent",
|
|
15826
15848
|
props: {
|
|
15827
15849
|
editor: {
|
|
@@ -15905,10 +15927,10 @@ ae({
|
|
|
15905
15927
|
);
|
|
15906
15928
|
}
|
|
15907
15929
|
});
|
|
15908
|
-
var
|
|
15930
|
+
var Z0 = (n = {}) => {
|
|
15909
15931
|
const e = Kd();
|
|
15910
15932
|
return er(() => {
|
|
15911
|
-
e.value = new
|
|
15933
|
+
e.value = new Q0(n);
|
|
15912
15934
|
}), Ds(() => {
|
|
15913
15935
|
var t, r, i, s;
|
|
15914
15936
|
const o = (r = (t = e.value) == null ? void 0 : t.view.dom) == null ? void 0 : r.parentNode, l = o?.cloneNode(!0);
|
|
@@ -15941,7 +15963,7 @@ var Br = (n, e) => {
|
|
|
15941
15963
|
if (n === "svg")
|
|
15942
15964
|
throw new Error("SVG elements are not supported in the JSX syntax, use the array syntax instead");
|
|
15943
15965
|
return [n, r, t];
|
|
15944
|
-
},
|
|
15966
|
+
}, _0 = /^\s*>\s$/, e1 = qe.create({
|
|
15945
15967
|
name: "blockquote",
|
|
15946
15968
|
addOptions() {
|
|
15947
15969
|
return {
|
|
@@ -15986,12 +16008,12 @@ ${t}
|
|
|
15986
16008
|
addInputRules() {
|
|
15987
16009
|
return [
|
|
15988
16010
|
vn({
|
|
15989
|
-
find:
|
|
16011
|
+
find: _0,
|
|
15990
16012
|
type: this.type
|
|
15991
16013
|
})
|
|
15992
16014
|
];
|
|
15993
16015
|
}
|
|
15994
|
-
}),
|
|
16016
|
+
}), t1 = /(?:^|\s)(\*\*(?!\s+\*\*)((?:[^*]+))\*\*(?!\s+\*\*))$/, n1 = /(?:^|\s)(\*\*(?!\s+\*\*)((?:[^*]+))\*\*(?!\s+\*\*))/g, r1 = /(?:^|\s)(__(?!\s+__)((?:[^_]+))__(?!\s+__))$/, i1 = /(?:^|\s)(__(?!\s+__)((?:[^_]+))__(?!\s+__))/g, s1 = en.create({
|
|
15995
16017
|
name: "bold",
|
|
15996
16018
|
addOptions() {
|
|
15997
16019
|
return {
|
|
@@ -16039,11 +16061,11 @@ ${t}
|
|
|
16039
16061
|
addInputRules() {
|
|
16040
16062
|
return [
|
|
16041
16063
|
kn({
|
|
16042
|
-
find:
|
|
16064
|
+
find: t1,
|
|
16043
16065
|
type: this.type
|
|
16044
16066
|
}),
|
|
16045
16067
|
kn({
|
|
16046
|
-
find:
|
|
16068
|
+
find: r1,
|
|
16047
16069
|
type: this.type
|
|
16048
16070
|
})
|
|
16049
16071
|
];
|
|
@@ -16051,16 +16073,16 @@ ${t}
|
|
|
16051
16073
|
addPasteRules() {
|
|
16052
16074
|
return [
|
|
16053
16075
|
Xt({
|
|
16054
|
-
find:
|
|
16076
|
+
find: n1,
|
|
16055
16077
|
type: this.type
|
|
16056
16078
|
}),
|
|
16057
16079
|
Xt({
|
|
16058
|
-
find:
|
|
16080
|
+
find: i1,
|
|
16059
16081
|
type: this.type
|
|
16060
16082
|
})
|
|
16061
16083
|
];
|
|
16062
16084
|
}
|
|
16063
|
-
}),
|
|
16085
|
+
}), o1 = /(^|[^`])`([^`]+)`(?!`)$/, l1 = /(^|[^`])`([^`]+)`(?!`)/g, a1 = en.create({
|
|
16064
16086
|
name: "code",
|
|
16065
16087
|
addOptions() {
|
|
16066
16088
|
return {
|
|
@@ -16094,7 +16116,7 @@ ${t}
|
|
|
16094
16116
|
addInputRules() {
|
|
16095
16117
|
return [
|
|
16096
16118
|
kn({
|
|
16097
|
-
find:
|
|
16119
|
+
find: o1,
|
|
16098
16120
|
type: this.type
|
|
16099
16121
|
})
|
|
16100
16122
|
];
|
|
@@ -16102,12 +16124,12 @@ ${t}
|
|
|
16102
16124
|
addPasteRules() {
|
|
16103
16125
|
return [
|
|
16104
16126
|
Xt({
|
|
16105
|
-
find:
|
|
16127
|
+
find: l1,
|
|
16106
16128
|
type: this.type
|
|
16107
16129
|
})
|
|
16108
16130
|
];
|
|
16109
16131
|
}
|
|
16110
|
-
}), Ji = 4,
|
|
16132
|
+
}), Ji = 4, c1 = /^```([a-z]+)?[\s\n]$/, d1 = /^~~~([a-z]+)?[\s\n]$/, u1 = qe.create({
|
|
16111
16133
|
name: "codeBlock",
|
|
16112
16134
|
addOptions() {
|
|
16113
16135
|
return {
|
|
@@ -16280,14 +16302,14 @@ ${t}
|
|
|
16280
16302
|
addInputRules() {
|
|
16281
16303
|
return [
|
|
16282
16304
|
vs({
|
|
16283
|
-
find:
|
|
16305
|
+
find: c1,
|
|
16284
16306
|
type: this.type,
|
|
16285
16307
|
getAttributes: (n) => ({
|
|
16286
16308
|
language: n[1]
|
|
16287
16309
|
})
|
|
16288
16310
|
}),
|
|
16289
16311
|
vs({
|
|
16290
|
-
find:
|
|
16312
|
+
find: d1,
|
|
16291
16313
|
type: this.type,
|
|
16292
16314
|
getAttributes: (n) => ({
|
|
16293
16315
|
language: n[1]
|
|
@@ -16316,14 +16338,14 @@ ${t}
|
|
|
16316
16338
|
})
|
|
16317
16339
|
];
|
|
16318
16340
|
}
|
|
16319
|
-
}),
|
|
16341
|
+
}), f1 = qe.create({
|
|
16320
16342
|
name: "doc",
|
|
16321
16343
|
topNode: !0,
|
|
16322
16344
|
content: "block+",
|
|
16323
16345
|
renderMarkdown: (n, e) => n.content ? e.renderChildren(n.content, `
|
|
16324
16346
|
|
|
16325
16347
|
`) : ""
|
|
16326
|
-
}),
|
|
16348
|
+
}), h1 = qe.create({
|
|
16327
16349
|
name: "hardBreak",
|
|
16328
16350
|
markdownTokenName: "br",
|
|
16329
16351
|
addOptions() {
|
|
@@ -16435,7 +16457,7 @@ ${t}
|
|
|
16435
16457
|
}
|
|
16436
16458
|
}));
|
|
16437
16459
|
}
|
|
16438
|
-
}),
|
|
16460
|
+
}), p1 = sd, m1 = qe.create({
|
|
16439
16461
|
name: "horizontalRule",
|
|
16440
16462
|
addOptions() {
|
|
16441
16463
|
return {
|
|
@@ -16456,7 +16478,7 @@ ${t}
|
|
|
16456
16478
|
addCommands() {
|
|
16457
16479
|
return {
|
|
16458
16480
|
setHorizontalRule: () => ({ chain: n, state: e }) => {
|
|
16459
|
-
if (!
|
|
16481
|
+
if (!j0(e, e.schema.nodes[this.name]))
|
|
16460
16482
|
return !1;
|
|
16461
16483
|
const { selection: t } = e, { $to: r } = t, i = n();
|
|
16462
16484
|
return Hc(t) ? i.insertContentAt(r.pos, {
|
|
@@ -16479,13 +16501,13 @@ ${t}
|
|
|
16479
16501
|
},
|
|
16480
16502
|
addInputRules() {
|
|
16481
16503
|
return [
|
|
16482
|
-
|
|
16504
|
+
H0({
|
|
16483
16505
|
find: /^(?:---|—-|___\s|\*\*\*\s)$/,
|
|
16484
16506
|
type: this.type
|
|
16485
16507
|
})
|
|
16486
16508
|
];
|
|
16487
16509
|
}
|
|
16488
|
-
}),
|
|
16510
|
+
}), g1 = /(?:^|\s)(\*(?!\s+\*)((?:[^*]+))\*(?!\s+\*))$/, y1 = /(?:^|\s)(\*(?!\s+\*)((?:[^*]+))\*(?!\s+\*))/g, b1 = /(?:^|\s)(_(?!\s+_)((?:[^_]+))_(?!\s+_))$/, k1 = /(?:^|\s)(_(?!\s+_)((?:[^_]+))_(?!\s+_))/g, v1 = en.create({
|
|
16489
16511
|
name: "italic",
|
|
16490
16512
|
addOptions() {
|
|
16491
16513
|
return {
|
|
@@ -16532,11 +16554,11 @@ ${t}
|
|
|
16532
16554
|
addInputRules() {
|
|
16533
16555
|
return [
|
|
16534
16556
|
kn({
|
|
16535
|
-
find:
|
|
16557
|
+
find: g1,
|
|
16536
16558
|
type: this.type
|
|
16537
16559
|
}),
|
|
16538
16560
|
kn({
|
|
16539
|
-
find:
|
|
16561
|
+
find: b1,
|
|
16540
16562
|
type: this.type
|
|
16541
16563
|
})
|
|
16542
16564
|
];
|
|
@@ -16544,28 +16566,28 @@ ${t}
|
|
|
16544
16566
|
addPasteRules() {
|
|
16545
16567
|
return [
|
|
16546
16568
|
Xt({
|
|
16547
|
-
find:
|
|
16569
|
+
find: y1,
|
|
16548
16570
|
type: this.type
|
|
16549
16571
|
}),
|
|
16550
16572
|
Xt({
|
|
16551
|
-
find:
|
|
16573
|
+
find: k1,
|
|
16552
16574
|
type: this.type
|
|
16553
16575
|
})
|
|
16554
16576
|
];
|
|
16555
16577
|
}
|
|
16556
16578
|
});
|
|
16557
|
-
const
|
|
16558
|
-
function
|
|
16579
|
+
const x1 = "aaa1rp3bb0ott3vie4c1le2ogado5udhabi7c0ademy5centure6ountant0s9o1tor4d0s1ult4e0g1ro2tna4f0l1rica5g0akhan5ency5i0g1rbus3force5tel5kdn3l0ibaba4pay4lfinanz6state5y2sace3tom5m0azon4ericanexpress7family11x2fam3ica3sterdam8nalytics7droid5quan4z2o0l2partments8p0le4q0uarelle8r0ab1mco4chi3my2pa2t0e3s0da2ia2sociates9t0hleta5torney7u0ction5di0ble3o3spost5thor3o0s4w0s2x0a2z0ure5ba0by2idu3namex4d1k2r0celona5laycard4s5efoot5gains6seball5ketball8uhaus5yern5b0c1t1va3cg1n2d1e0ats2uty4er2rlin4st0buy5t2f1g1h0arti5i0ble3d1ke2ng0o3o1z2j1lack0friday9ockbuster8g1omberg7ue3m0s1w2n0pparibas9o0ats3ehringer8fa2m1nd2o0k0ing5sch2tik2on4t1utique6x2r0adesco6idgestone9oadway5ker3ther5ussels7s1t1uild0ers6siness6y1zz3v1w1y1z0h3ca0b1fe2l0l1vinklein9m0era3p2non3petown5ital0one8r0avan4ds2e0er0s4s2sa1e1h1ino4t0ering5holic7ba1n1re3c1d1enter4o1rn3f0a1d2g1h0anel2nel4rity4se2t2eap3intai5ristmas6ome4urch5i0priani6rcle4sco3tadel4i0c2y3k1l0aims4eaning6ick2nic1que6othing5ud3ub0med6m1n1o0ach3des3ffee4llege4ogne5m0mbank4unity6pany2re3uter5sec4ndos3struction8ulting7tact3ractors9oking4l1p2rsica5untry4pon0s4rses6pa2r0edit0card4union9icket5own3s1uise0s6u0isinella9v1w1x1y0mru3ou3z2dad1nce3ta1e1ing3sun4y2clk3ds2e0al0er2s3gree4livery5l1oitte5ta3mocrat6ntal2ist5si0gn4v2hl2iamonds6et2gital5rect0ory7scount3ver5h2y2j1k1m1np2o0cs1tor4g1mains5t1wnload7rive4tv2ubai3nlop4pont4rban5vag2r2z2earth3t2c0o2deka3u0cation8e1g1mail3erck5nergy4gineer0ing9terprises10pson4quipment8r0icsson6ni3s0q1tate5t1u0rovision8s2vents5xchange6pert3osed4ress5traspace10fage2il1rwinds6th3mily4n0s2rm0ers5shion4t3edex3edback6rrari3ero6i0delity5o2lm2nal1nce1ial7re0stone6mdale6sh0ing5t0ness6j1k1lickr3ghts4r2orist4wers5y2m1o0o0d1tball6rd1ex2sale4um3undation8x2r0ee1senius7l1ogans4ntier7tr2ujitsu5n0d2rniture7tbol5yi3ga0l0lery3o1up4me0s3p1rden4y2b0iz3d0n2e0a1nt0ing5orge5f1g0ee3h1i0ft0s3ves2ing5l0ass3e1obal2o4m0ail3bh2o1x2n1odaddy5ld0point6f2o0dyear5g0le4p1t1v2p1q1r0ainger5phics5tis4een3ipe3ocery4up4s1t1u0cci3ge2ide2tars5ru3w1y2hair2mburg5ngout5us3bo2dfc0bank7ealth0care8lp1sinki6re1mes5iphop4samitsu7tachi5v2k0t2m1n1ockey4ldings5iday5medepot5goods5s0ense7nda3rse3spital5t0ing5t0els3mail5use3w2r1sbc3t1u0ghes5yatt3undai7ibm2cbc2e1u2d1e0ee3fm2kano4l1m0amat4db2mo0bilien9n0c1dustries8finiti5o2g1k1stitute6urance4e4t0ernational10uit4vestments10o1piranga7q1r0ish4s0maili5t0anbul7t0au2v3jaguar4va3cb2e0ep2tzt3welry6io2ll2m0p2nj2o0bs1urg4t1y2p0morgan6rs3uegos4niper7kaufen5ddi3e0rryhotels6properties14fh2g1h1i0a1ds2m1ndle4tchen5wi3m1n1oeln3matsu5sher5p0mg2n2r0d1ed3uokgroup8w1y0oto4z2la0caixa5mborghini8er3nd0rover6xess5salle5t0ino3robe5w0yer5b1c1ds2ease3clerc5frak4gal2o2xus4gbt3i0dl2fe0insurance9style7ghting6ke2lly3mited4o2ncoln4k2ve1ing5k1lc1p2oan0s3cker3us3l1ndon4tte1o3ve3pl0financial11r1s1t0d0a3u0ndbeck6xe1ury5v1y2ma0drid4if1son4keup4n0agement7go3p1rket0ing3s4riott5shalls7ttel5ba2c0kinsey7d1e0d0ia3et2lbourne7me1orial6n0u2rckmsd7g1h1iami3crosoft7l1ni1t2t0subishi9k1l0b1s2m0a2n1o0bi0le4da2e1i1m1nash3ey2ster5rmon3tgage6scow4to0rcycles9v0ie4p1q1r1s0d2t0n1r2u0seum3ic4v1w1x1y1z2na0b1goya4me2vy3ba2c1e0c1t0bank4flix4work5ustar5w0s2xt0direct7us4f0l2g0o2hk2i0co2ke1on3nja3ssan1y5l1o0kia3rton4w0ruz3tv4p1r0a1w2tt2u1yc2z2obi1server7ffice5kinawa6layan0group9lo3m0ega4ne1g1l0ine5oo2pen3racle3nge4g0anic5igins6saka4tsuka4t2vh3pa0ge2nasonic7ris2s1tners4s1y3y2ccw3e0t2f0izer5g1h0armacy6d1ilips5one2to0graphy6s4ysio5ics1tet2ures6d1n0g1k2oneer5zza4k1l0ace2y0station9umbing5s3m1n0c2ohl2ker3litie5rn2st3r0axi3ess3ime3o0d0uctions8f1gressive8mo2perties3y5tection8u0dential9s1t1ub2w0c2y2qa1pon3uebec3st5racing4dio4e0ad1lestate6tor2y4cipes5d0stone5umbrella9hab3ise0n3t2liance6n0t0als5pair3ort3ublican8st0aurant8view0s5xroth6ich0ardli6oh3l1o1p2o0cks3deo3gers4om3s0vp3u0gby3hr2n2w0e2yukyu6sa0arland6fe0ty4kura4le1on3msclub4ung5ndvik0coromant12ofi4p1rl2s1ve2xo3b0i1s2c0b1haeffler7midt4olarships8ol3ule3warz5ience5ot3d1e0arch3t2cure1ity6ek2lect4ner3rvices6ven3w1x0y3fr2g1h0angrila6rp3ell3ia1ksha5oes2p0ping5uji3w3i0lk2na1gles5te3j1k0i0n2y0pe4l0ing4m0art3ile4n0cf3o0ccer3ial4ftbank4ware6hu2lar2utions7ng1y2y2pa0ce3ort2t3r0l2s1t0ada2ples4r1tebank4farm7c0group6ockholm6rage3e3ream4udio2y3yle4u0cks3pplies3y2ort5rf1gery5zuki5v1watch4iss4x1y0dney4stems6z2tab1ipei4lk2obao4rget4tamotors6r2too4x0i3c0i2d0k2eam2ch0nology8l1masek5nnis4va3f1g1h0d1eater2re6iaa2ckets5enda4ps2res2ol4j0maxx4x2k0maxx5l1m0all4n1o0day3kyo3ols3p1ray3shiba5tal3urs3wn2yota3s3r0ade1ing4ining5vel0ers0insurance16ust3v2t1ube2i1nes3shu4v0s2w1z2ua1bank3s2g1k1nicom3versity8o2ol2ps2s1y1z2va0cations7na1guard7c1e0gas3ntures6risign5mögensberater2ung14sicherung10t2g1i0ajes4deo3g1king4llas4n1p1rgin4sa1ion4va1o3laanderen9n1odka3lvo3te1ing3o2yage5u2wales2mart4ter4ng0gou5tch0es6eather0channel12bcam3er2site5d0ding5ibo2r3f1hoswho6ien2ki2lliamhill9n0dows4e1ners6me2olterskluwer11odside6rk0s2ld3w2s1tc1f3xbox3erox4ihuan4n2xx2yz3yachts4hoo3maxun5ndex5e1odobashi7ga2kohama6u0tube6t1un3za0ppos4ra3ero3ip2m1one3uerich6w2", w1 = "ελ1υ2бг1ел3дети4ею2католик6ом3мкд2он1сква6онлайн5рг3рус2ф2сайт3рб3укр3қаз3հայ3ישראל5קום3ابوظبي5رامكو5لاردن4بحرين5جزائر5سعودية6عليان5مغرب5مارات5یران5بارت2زار4يتك3ھارت5تونس4سودان3رية5شبكة4عراق2ب2مان4فلسطين6قطر3كاثوليك6وم3مصر2ليسيا5وريتانيا7قع4همراه5پاکستان7ڀارت4कॉम3नेट3भारत0म्3ोत5संगठन5বাংলা5ভারত2ৰত4ਭਾਰਤ4ભારત4ଭାରତ4இந்தியா6லங்கை6சிங்கப்பூர்11భారత్5ಭಾರತ4ഭാരതം5ලංකා4คอม3ไทย3ລາວ3გე2みんな3アマゾン4クラウド4グーグル4コム2ストア3セール3ファッション6ポイント4世界2中信1国1國1文网3亚马逊3企业2佛山2信息2健康2八卦2公司1益2台湾1灣2商城1店1标2嘉里0大酒店5在线2大拿2天主教3娱乐2家電2广东2微博2慈善2我爱你3手机2招聘2政务1府2新加坡2闻2时尚2書籍2机构2淡马锡3游戏2澳門2点看2移动2组织机构4网址1店1站1络2联通2谷歌2购物2通販2集团2電訊盈科4飞利浦3食品2餐厅2香格里拉3港2닷넷1컴2삼성2한국2", ws = "numeric", Ss = "ascii", Cs = "alpha", zn = "asciinumeric", Nn = "alphanumeric", Ms = "domain", od = "emoji", S1 = "scheme", C1 = "slashscheme", Gi = "whitespace";
|
|
16580
|
+
function M1(n, e) {
|
|
16559
16581
|
return n in e || (e[n] = []), e[n];
|
|
16560
16582
|
}
|
|
16561
16583
|
function Ft(n, e, t) {
|
|
16562
16584
|
e[ws] && (e[zn] = !0, e[Nn] = !0), e[Ss] && (e[zn] = !0, e[Cs] = !0), e[zn] && (e[Nn] = !0), e[Cs] && (e[Nn] = !0), e[Nn] && (e[Ms] = !0), e[od] && (e[Ms] = !0);
|
|
16563
16585
|
for (const r in e) {
|
|
16564
|
-
const i =
|
|
16586
|
+
const i = M1(r, t);
|
|
16565
16587
|
i.indexOf(n) < 0 && i.push(n);
|
|
16566
16588
|
}
|
|
16567
16589
|
}
|
|
16568
|
-
function
|
|
16590
|
+
function T1(n, e) {
|
|
16569
16591
|
const t = {};
|
|
16570
16592
|
for (const r in e)
|
|
16571
16593
|
e[r].indexOf(n) >= 0 && (t[r] = !0);
|
|
@@ -16687,7 +16709,7 @@ Fe.prototype = {
|
|
|
16687
16709
|
if (l ? (o = new Fe(), Object.assign(o.j, l.j), o.jr.push.apply(o.jr, l.jr), o.jd = l.jd, o.t = l.t) : o = new Fe(), s) {
|
|
16688
16710
|
if (r)
|
|
16689
16711
|
if (o.t && typeof o.t == "string") {
|
|
16690
|
-
const a = Object.assign(
|
|
16712
|
+
const a = Object.assign(T1(o.t, r), t);
|
|
16691
16713
|
Ft(s, a, r);
|
|
16692
16714
|
} else t && Ft(s, t, r);
|
|
16693
16715
|
o.t = s;
|
|
@@ -16755,13 +16777,13 @@ var ud = /* @__PURE__ */ Object.freeze({
|
|
|
16755
16777
|
WS: Os
|
|
16756
16778
|
});
|
|
16757
16779
|
const at = /[a-z]/, Tn = new RegExp("\\p{L}", "u"), Yi = new RegExp("\\p{Emoji}", "u"), ct = /\d/, Qi = /\s/, Hl = "\r", Xi = `
|
|
16758
|
-
`,
|
|
16780
|
+
`, E1 = "️", A1 = "", Zi = "";
|
|
16759
16781
|
let pr = null, mr = null;
|
|
16760
|
-
function
|
|
16782
|
+
function O1(n = []) {
|
|
16761
16783
|
const e = {};
|
|
16762
16784
|
Fe.groups = e;
|
|
16763
16785
|
const t = new Fe();
|
|
16764
|
-
pr == null && (pr = jl(
|
|
16786
|
+
pr == null && (pr = jl(x1)), mr == null && (mr = jl(w1)), O(t, "'", ei), O(t, "{", Bn), O(t, "}", Vn), O(t, "[", Vr), O(t, "]", Fr), O(t, "(", Hr), O(t, ")", jr), O(t, "<", qr), O(t, ">", Ur), O(t, "(", Wr), O(t, ")", Kr), O(t, "「", Jr), O(t, "」", Gr), O(t, "『", Yr), O(t, "』", Qr), O(t, "<", Xr), O(t, ">", Zr), O(t, "&", _r), O(t, "*", ti), O(t, "@", kt), O(t, "`", ri), O(t, "^", ii), O(t, ":", wt), O(t, ",", ho), O(t, "$", si), O(t, ".", nt), O(t, "=", oi), O(t, "!", po), O(t, "-", We), O(t, "%", Fn), O(t, "|", li), O(t, "+", ai), O(t, "#", ci), O(t, "?", Hn), O(t, '"', mo), O(t, "/", rt), O(t, ";", go), O(t, "~", jn), O(t, "_", di), O(t, "\\", ni), O(t, "・", cd);
|
|
16765
16787
|
const r = fe(t, ct, uo, {
|
|
16766
16788
|
[ws]: !0
|
|
16767
16789
|
});
|
|
@@ -16789,8 +16811,8 @@ function A1(n = []) {
|
|
|
16789
16811
|
const u = fe(t, Yi, dd, {
|
|
16790
16812
|
[od]: !0
|
|
16791
16813
|
});
|
|
16792
|
-
O(u, "#"), fe(u, Yi, u), O(u,
|
|
16793
|
-
const f = O(u,
|
|
16814
|
+
O(u, "#"), fe(u, Yi, u), O(u, E1, u);
|
|
16815
|
+
const f = O(u, A1);
|
|
16794
16816
|
O(f, "#"), fe(f, Yi, u);
|
|
16795
16817
|
const h = [[at, o], [ct, i]], p = [[at, null], [Tn, l], [ct, s]];
|
|
16796
16818
|
for (let m = 0; m < pr.length; m++)
|
|
@@ -16812,9 +16834,9 @@ function A1(n = []) {
|
|
|
16812
16834
|
}, e), n = n.sort((m, g) => m[0] > g[0] ? 1 : -1);
|
|
16813
16835
|
for (let m = 0; m < n.length; m++) {
|
|
16814
16836
|
const g = n[m][0], S = n[m][1] ? {
|
|
16815
|
-
[w1]: !0
|
|
16816
|
-
} : {
|
|
16817
16837
|
[S1]: !0
|
|
16838
|
+
} : {
|
|
16839
|
+
[C1]: !0
|
|
16818
16840
|
};
|
|
16819
16841
|
g.indexOf("-") >= 0 ? S[Ms] = !0 : at.test(g) ? ct.test(g) ? S[zn] = !0 : S[Ss] = !0 : S[ws] = !0, Fl(t, g, g, S);
|
|
16820
16842
|
}
|
|
@@ -16828,7 +16850,7 @@ function A1(n = []) {
|
|
|
16828
16850
|
};
|
|
16829
16851
|
}
|
|
16830
16852
|
function fd(n, e) {
|
|
16831
|
-
const t =
|
|
16853
|
+
const t = N1(e.replace(/[A-Z]/g, (l) => l.toLowerCase())), r = t.length, i = [];
|
|
16832
16854
|
let s = 0, o = 0;
|
|
16833
16855
|
for (; o < r; ) {
|
|
16834
16856
|
let l = n, a = null, c = 0, d = null, u = -1, f = -1;
|
|
@@ -16847,7 +16869,7 @@ function fd(n, e) {
|
|
|
16847
16869
|
}
|
|
16848
16870
|
return i;
|
|
16849
16871
|
}
|
|
16850
|
-
function
|
|
16872
|
+
function N1(n) {
|
|
16851
16873
|
const e = [], t = n.length;
|
|
16852
16874
|
let r = 0;
|
|
16853
16875
|
for (; r < t; ) {
|
|
@@ -17093,7 +17115,7 @@ const Ul = Ai("email", {
|
|
|
17093
17115
|
toHref() {
|
|
17094
17116
|
return "mailto:" + this.toString();
|
|
17095
17117
|
}
|
|
17096
|
-
}), Wl = Ai("text"),
|
|
17118
|
+
}), Wl = Ai("text"), I1 = Ai("nl"), gr = Ai("url", {
|
|
17097
17119
|
isLink: !0,
|
|
17098
17120
|
/**
|
|
17099
17121
|
Lowercases relevant parts of the domain and adds the protocol if
|
|
@@ -17114,7 +17136,7 @@ const Ul = Ai("email", {
|
|
|
17114
17136
|
return n.length >= 2 && n[0].t !== Zn && n[1].t === wt;
|
|
17115
17137
|
}
|
|
17116
17138
|
}), Ue = (n) => new Fe(n);
|
|
17117
|
-
function
|
|
17139
|
+
function D1({
|
|
17118
17140
|
groups: n
|
|
17119
17141
|
}) {
|
|
17120
17142
|
const e = n.domain.concat([_r, ti, kt, ni, ri, ii, si, oi, We, uo, Fn, li, ai, ci, rt, ui, jn, di]), t = [ei, wt, ho, nt, po, Fn, Hn, mo, go, qr, Ur, Bn, Vn, Fr, Vr, Hr, jr, Wr, Kr, Jr, Gr, Yr, Qr, Xr, Zr], r = [_r, ei, ti, ni, ri, ii, si, oi, We, Bn, Vn, Fn, li, ai, ci, Hn, rt, ui, jn, di], i = Ue(), s = O(i, jn);
|
|
@@ -17171,12 +17193,12 @@ function I1({
|
|
|
17171
17193
|
const De = Ue();
|
|
17172
17194
|
G(V, t), G(j, e, j), G(j, t, De), G(De, e, j), G(De, t, De), O(j, I, k), O(De, I, k);
|
|
17173
17195
|
}
|
|
17174
|
-
return O(i, Zn, S), O(i, fo,
|
|
17196
|
+
return O(i, Zn, S), O(i, fo, I1), {
|
|
17175
17197
|
start: i,
|
|
17176
17198
|
tokens: ud
|
|
17177
17199
|
};
|
|
17178
17200
|
}
|
|
17179
|
-
function
|
|
17201
|
+
function $1(n, e, t) {
|
|
17180
17202
|
let r = t.length, i = 0, s = [], o = [];
|
|
17181
17203
|
for (; i < r; ) {
|
|
17182
17204
|
let l = n, a = null, c = null, d = 0, u = null, f = -1;
|
|
@@ -17198,8 +17220,8 @@ function _i(n, e, t) {
|
|
|
17198
17220
|
const r = t[0].s, i = t[t.length - 1].e, s = e.slice(r, i);
|
|
17199
17221
|
return new n(s, t);
|
|
17200
17222
|
}
|
|
17201
|
-
const
|
|
17202
|
-
}),
|
|
17223
|
+
const R1 = typeof console < "u" && console && console.warn || (() => {
|
|
17224
|
+
}), L1 = "until manual call of linkify.init(). Register all schemes and plugins before invoking linkify the first time.", ce = {
|
|
17203
17225
|
scanner: null,
|
|
17204
17226
|
parser: null,
|
|
17205
17227
|
tokenQueue: [],
|
|
@@ -17207,24 +17229,24 @@ const $1 = typeof console < "u" && console && console.warn || (() => {
|
|
|
17207
17229
|
customSchemes: [],
|
|
17208
17230
|
initialized: !1
|
|
17209
17231
|
};
|
|
17210
|
-
function
|
|
17232
|
+
function P1() {
|
|
17211
17233
|
return Fe.groups = {}, ce.scanner = null, ce.parser = null, ce.tokenQueue = [], ce.pluginQueue = [], ce.customSchemes = [], ce.initialized = !1, ce;
|
|
17212
17234
|
}
|
|
17213
17235
|
function Kl(n, e = !1) {
|
|
17214
|
-
if (ce.initialized &&
|
|
17236
|
+
if (ce.initialized && R1(`linkifyjs: already initialized - will not register custom scheme "${n}" ${L1}`), !/^[0-9a-z]+(-[0-9a-z]+)*$/.test(n))
|
|
17215
17237
|
throw new Error(`linkifyjs: incorrect scheme format.
|
|
17216
17238
|
1. Must only contain digits, lowercase ASCII letters or "-"
|
|
17217
17239
|
2. Cannot start or end with "-"
|
|
17218
17240
|
3. "-" cannot repeat`);
|
|
17219
17241
|
ce.customSchemes.push([n, e]);
|
|
17220
17242
|
}
|
|
17221
|
-
function
|
|
17222
|
-
ce.scanner =
|
|
17243
|
+
function z1() {
|
|
17244
|
+
ce.scanner = O1(ce.customSchemes);
|
|
17223
17245
|
for (let n = 0; n < ce.tokenQueue.length; n++)
|
|
17224
17246
|
ce.tokenQueue[n][1]({
|
|
17225
17247
|
scanner: ce.scanner
|
|
17226
17248
|
});
|
|
17227
|
-
ce.parser =
|
|
17249
|
+
ce.parser = D1(ce.scanner.tokens);
|
|
17228
17250
|
for (let n = 0; n < ce.pluginQueue.length; n++)
|
|
17229
17251
|
ce.pluginQueue[n][1]({
|
|
17230
17252
|
scanner: ce.scanner,
|
|
@@ -17233,7 +17255,7 @@ function P1() {
|
|
|
17233
17255
|
return ce.initialized = !0, ce;
|
|
17234
17256
|
}
|
|
17235
17257
|
function bo(n) {
|
|
17236
|
-
return ce.initialized ||
|
|
17258
|
+
return ce.initialized || z1(), $1(ce.parser.start, n, fd(ce.scanner.start, n));
|
|
17237
17259
|
}
|
|
17238
17260
|
bo.scan = fd;
|
|
17239
17261
|
function pd(n, e = null, t = null) {
|
|
@@ -17249,11 +17271,11 @@ function pd(n, e = null, t = null) {
|
|
|
17249
17271
|
}
|
|
17250
17272
|
return s;
|
|
17251
17273
|
}
|
|
17252
|
-
var ko = "[\0- -\u2029 ]",
|
|
17253
|
-
function
|
|
17274
|
+
var ko = "[\0- -\u2029 ]", B1 = new RegExp(ko), V1 = new RegExp(`${ko}$`), F1 = new RegExp(ko, "g");
|
|
17275
|
+
function H1(n) {
|
|
17254
17276
|
return n.length === 1 ? n[0].isLink : n.length === 3 && n[1].isLink ? ["()", "[]"].includes(n[0].value + n[2].value) : !1;
|
|
17255
17277
|
}
|
|
17256
|
-
function
|
|
17278
|
+
function j1(n) {
|
|
17257
17279
|
return new ue({
|
|
17258
17280
|
key: new ke("autolink"),
|
|
17259
17281
|
appendTransaction: (e, t, r) => {
|
|
@@ -17262,7 +17284,7 @@ function H1(n) {
|
|
|
17262
17284
|
return;
|
|
17263
17285
|
const { tr: o } = r, l = $c(t.doc, [...e]);
|
|
17264
17286
|
if (Fc(l).forEach(({ newRange: c }) => {
|
|
17265
|
-
const d =
|
|
17287
|
+
const d = jy(r.doc, c, (h) => h.isTextblock);
|
|
17266
17288
|
let u, f;
|
|
17267
17289
|
if (d.length > 1)
|
|
17268
17290
|
u = d[0], f = r.doc.textBetween(
|
|
@@ -17273,19 +17295,19 @@ function H1(n) {
|
|
|
17273
17295
|
);
|
|
17274
17296
|
else if (d.length) {
|
|
17275
17297
|
const h = r.doc.textBetween(c.from, c.to, " ", " ");
|
|
17276
|
-
if (!
|
|
17298
|
+
if (!V1.test(h))
|
|
17277
17299
|
return;
|
|
17278
17300
|
u = d[0], f = r.doc.textBetween(u.pos, c.to, void 0, " ");
|
|
17279
17301
|
}
|
|
17280
17302
|
if (u && f) {
|
|
17281
|
-
const h = f.split(
|
|
17303
|
+
const h = f.split(B1).filter(Boolean);
|
|
17282
17304
|
if (h.length <= 0)
|
|
17283
17305
|
return !1;
|
|
17284
17306
|
const p = h[h.length - 1], m = u.pos + f.lastIndexOf(p);
|
|
17285
17307
|
if (!p)
|
|
17286
17308
|
return !1;
|
|
17287
17309
|
const g = bo(p).map((y) => y.toObject(n.defaultProtocol));
|
|
17288
|
-
if (!
|
|
17310
|
+
if (!H1(g))
|
|
17289
17311
|
return !1;
|
|
17290
17312
|
g.filter((y) => y.isLink).map((y) => ({
|
|
17291
17313
|
...y,
|
|
@@ -17306,7 +17328,7 @@ function H1(n) {
|
|
|
17306
17328
|
}
|
|
17307
17329
|
});
|
|
17308
17330
|
}
|
|
17309
|
-
function
|
|
17331
|
+
function q1(n) {
|
|
17310
17332
|
return new ue({
|
|
17311
17333
|
key: new ke("handleClickLink"),
|
|
17312
17334
|
props: {
|
|
@@ -17336,7 +17358,7 @@ function j1(n) {
|
|
|
17336
17358
|
}
|
|
17337
17359
|
});
|
|
17338
17360
|
}
|
|
17339
|
-
function
|
|
17361
|
+
function U1(n) {
|
|
17340
17362
|
return new ue({
|
|
17341
17363
|
key: new ke("handlePasteLink"),
|
|
17342
17364
|
props: {
|
|
@@ -17363,7 +17385,7 @@ function Rt(n, e) {
|
|
|
17363
17385
|
return e && e.forEach((r) => {
|
|
17364
17386
|
const i = typeof r == "string" ? r : r.scheme;
|
|
17365
17387
|
i && t.push(i);
|
|
17366
|
-
}), !n || n.replace(
|
|
17388
|
+
}), !n || n.replace(F1, "").match(
|
|
17367
17389
|
new RegExp(
|
|
17368
17390
|
// eslint-disable-next-line no-useless-escape
|
|
17369
17391
|
`^(?:(?:${t.join("|")}):|[^a-z]|[a-z0-9+.-]+(?:[^a-z+.-:]|$))`,
|
|
@@ -17371,7 +17393,7 @@ function Rt(n, e) {
|
|
|
17371
17393
|
)
|
|
17372
17394
|
);
|
|
17373
17395
|
}
|
|
17374
|
-
var
|
|
17396
|
+
var W1 = en.create({
|
|
17375
17397
|
name: "link",
|
|
17376
17398
|
priority: 1e3,
|
|
17377
17399
|
keepOnSplit: !1,
|
|
@@ -17386,7 +17408,7 @@ var U1 = en.create({
|
|
|
17386
17408
|
});
|
|
17387
17409
|
},
|
|
17388
17410
|
onDestroy() {
|
|
17389
|
-
|
|
17411
|
+
P1();
|
|
17390
17412
|
},
|
|
17391
17413
|
inclusive() {
|
|
17392
17414
|
return this.options.autolink;
|
|
@@ -17525,7 +17547,7 @@ var U1 = en.create({
|
|
|
17525
17547
|
addProseMirrorPlugins() {
|
|
17526
17548
|
const n = [], { protocols: e, defaultProtocol: t } = this.options;
|
|
17527
17549
|
return this.options.autolink && n.push(
|
|
17528
|
-
|
|
17550
|
+
j1({
|
|
17529
17551
|
type: this.type,
|
|
17530
17552
|
defaultProtocol: this.options.defaultProtocol,
|
|
17531
17553
|
validate: (r) => this.options.isAllowedUri(r, {
|
|
@@ -17536,14 +17558,14 @@ var U1 = en.create({
|
|
|
17536
17558
|
shouldAutoLink: this.options.shouldAutoLink
|
|
17537
17559
|
})
|
|
17538
17560
|
), n.push(
|
|
17539
|
-
|
|
17561
|
+
q1({
|
|
17540
17562
|
type: this.type,
|
|
17541
17563
|
editor: this.editor,
|
|
17542
17564
|
openOnClick: this.options.openOnClick === "whenNotEditable" ? !0 : this.options.openOnClick,
|
|
17543
17565
|
enableClickSelection: this.options.enableClickSelection
|
|
17544
17566
|
})
|
|
17545
17567
|
), this.options.linkOnPaste && n.push(
|
|
17546
|
-
|
|
17568
|
+
U1({
|
|
17547
17569
|
editor: this.editor,
|
|
17548
17570
|
defaultProtocol: this.options.defaultProtocol,
|
|
17549
17571
|
type: this.type,
|
|
@@ -17551,10 +17573,10 @@ var U1 = en.create({
|
|
|
17551
17573
|
})
|
|
17552
17574
|
), n;
|
|
17553
17575
|
}
|
|
17554
|
-
}),
|
|
17576
|
+
}), K1 = Object.defineProperty, J1 = (n, e) => {
|
|
17555
17577
|
for (var t in e)
|
|
17556
|
-
|
|
17557
|
-
},
|
|
17578
|
+
K1(n, t, { get: e[t], enumerable: !0 });
|
|
17579
|
+
}, G1 = "listItem", Jl = "textStyle", Gl = /^\s*([-+*])\s$/, md = qe.create({
|
|
17558
17580
|
name: "bulletList",
|
|
17559
17581
|
addOptions() {
|
|
17560
17582
|
return {
|
|
@@ -17586,7 +17608,7 @@ var U1 = en.create({
|
|
|
17586
17608
|
},
|
|
17587
17609
|
addCommands() {
|
|
17588
17610
|
return {
|
|
17589
|
-
toggleBulletList: () => ({ commands: n, chain: e }) => this.options.keepAttributes ? e().toggleList(this.name, this.options.itemTypeName, this.options.keepMarks).updateAttributes(
|
|
17611
|
+
toggleBulletList: () => ({ commands: n, chain: e }) => this.options.keepAttributes ? e().toggleList(this.name, this.options.itemTypeName, this.options.keepMarks).updateAttributes(G1, this.editor.getAttributes(Jl)).run() : n.toggleList(this.name, this.options.itemTypeName, this.options.keepMarks)
|
|
17590
17612
|
};
|
|
17591
17613
|
},
|
|
17592
17614
|
addKeyboardShortcuts() {
|
|
@@ -17675,14 +17697,14 @@ var U1 = en.create({
|
|
|
17675
17697
|
"Shift-Tab": () => this.editor.commands.liftListItem(this.name)
|
|
17676
17698
|
};
|
|
17677
17699
|
}
|
|
17678
|
-
}),
|
|
17679
|
-
|
|
17700
|
+
}), Y1 = {};
|
|
17701
|
+
J1(Y1, {
|
|
17680
17702
|
findListItemPos: () => ir,
|
|
17681
17703
|
getNextListDepth: () => vo,
|
|
17682
17704
|
handleBackspace: () => Ns,
|
|
17683
17705
|
handleDelete: () => Is,
|
|
17684
17706
|
hasListBefore: () => yd,
|
|
17685
|
-
hasListItemAfter: () =>
|
|
17707
|
+
hasListItemAfter: () => Q1,
|
|
17686
17708
|
hasListItemBefore: () => bd,
|
|
17687
17709
|
listItemHasSubList: () => kd,
|
|
17688
17710
|
nextListIsDeeper: () => vd,
|
|
@@ -17698,7 +17720,7 @@ var ir = (n, e) => {
|
|
|
17698
17720
|
const t = ir(n, e);
|
|
17699
17721
|
if (!t)
|
|
17700
17722
|
return !1;
|
|
17701
|
-
const [, r] =
|
|
17723
|
+
const [, r] = Zy(e, n, t.$pos.pos + 4);
|
|
17702
17724
|
return r;
|
|
17703
17725
|
}, yd = (n, e, t) => {
|
|
17704
17726
|
const { $anchor: r } = n.selection, i = Math.max(0, r.pos - 2), s = n.doc.resolve(i).node();
|
|
@@ -17731,7 +17753,7 @@ var ir = (n, e) => {
|
|
|
17731
17753
|
const u = n.state.doc.resolve(a.start() + d.pos + 1);
|
|
17732
17754
|
return n.chain().cut({ from: l.start() - 1, to: l.end() + 1 }, u.end()).joinForward().run();
|
|
17733
17755
|
}
|
|
17734
|
-
if (!It(n.state, e) || !
|
|
17756
|
+
if (!It(n.state, e) || !n0(n.state))
|
|
17735
17757
|
return !1;
|
|
17736
17758
|
const r = ir(e, n.state);
|
|
17737
17759
|
if (!r)
|
|
@@ -17745,11 +17767,11 @@ var ir = (n, e) => {
|
|
|
17745
17767
|
const t = vo(n, e), r = ir(n, e);
|
|
17746
17768
|
return !r || !t ? !1 : t < r.depth;
|
|
17747
17769
|
}, Is = (n, e) => {
|
|
17748
|
-
if (!It(n.state, e) || !
|
|
17770
|
+
if (!It(n.state, e) || !t0(n.state, e))
|
|
17749
17771
|
return !1;
|
|
17750
17772
|
const { selection: t } = n.state, { $from: r, $to: i } = t;
|
|
17751
17773
|
return !t.empty && r.sameParent(i) ? !1 : vd(e, n.state) ? n.chain().focus(n.state.selection.from + 4).lift(e).joinBackward().run() : xd(e, n.state) ? n.chain().joinForward().joinBackward().run() : n.commands.joinItemForward();
|
|
17752
|
-
},
|
|
17774
|
+
}, Q1 = (n, e) => {
|
|
17753
17775
|
var t;
|
|
17754
17776
|
const { $anchor: r } = e.selection, i = e.doc.resolve(r.pos - r.parentOffset - 2);
|
|
17755
17777
|
return !(i.index() === i.parent.childCount - 1 || ((t = i.nodeAfter) == null ? void 0 : t.type.name) !== n);
|
|
@@ -17797,8 +17819,8 @@ var ir = (n, e) => {
|
|
|
17797
17819
|
}
|
|
17798
17820
|
};
|
|
17799
17821
|
}
|
|
17800
|
-
}), Yl = /^(\s*)(\d+)\.\s+(.*)$/,
|
|
17801
|
-
function
|
|
17822
|
+
}), Yl = /^(\s*)(\d+)\.\s+(.*)$/, X1 = /^\s/;
|
|
17823
|
+
function Z1(n) {
|
|
17802
17824
|
const e = [];
|
|
17803
17825
|
let t = 0, r = 0;
|
|
17804
17826
|
for (; t < n.length; ) {
|
|
@@ -17815,7 +17837,7 @@ function X1(n) {
|
|
|
17815
17837
|
if (h.trim() === "")
|
|
17816
17838
|
f.push(h), d += `
|
|
17817
17839
|
`, u += 1;
|
|
17818
|
-
else if (h.match(
|
|
17840
|
+
else if (h.match(X1))
|
|
17819
17841
|
f.push(h), d += `
|
|
17820
17842
|
${h.slice(c + 2)}`, u += 1;
|
|
17821
17843
|
else
|
|
@@ -17876,7 +17898,7 @@ function Sd(n, e, t) {
|
|
|
17876
17898
|
}
|
|
17877
17899
|
return i;
|
|
17878
17900
|
}
|
|
17879
|
-
function
|
|
17901
|
+
function _1(n, e) {
|
|
17880
17902
|
return n.map((t) => {
|
|
17881
17903
|
if (t.type !== "list_item")
|
|
17882
17904
|
return e.parseChildren([t])[0];
|
|
@@ -17900,7 +17922,7 @@ function Z1(n, e) {
|
|
|
17900
17922
|
};
|
|
17901
17923
|
});
|
|
17902
17924
|
}
|
|
17903
|
-
var
|
|
17925
|
+
var eb = "listItem", Ql = "textStyle", Xl = /^(\d+)\.\s$/, Cd = qe.create({
|
|
17904
17926
|
name: "orderedList",
|
|
17905
17927
|
addOptions() {
|
|
17906
17928
|
return {
|
|
@@ -17941,7 +17963,7 @@ var _1 = "listItem", Ql = "textStyle", Xl = /^(\d+)\.\s$/, Cd = qe.create({
|
|
|
17941
17963
|
parseMarkdown: (n, e) => {
|
|
17942
17964
|
if (n.type !== "list" || !n.ordered)
|
|
17943
17965
|
return [];
|
|
17944
|
-
const t = n.start || 1, r = n.items ?
|
|
17966
|
+
const t = n.start || 1, r = n.items ? _1(n.items, e) : [];
|
|
17945
17967
|
return t !== 1 ? {
|
|
17946
17968
|
type: "orderedList",
|
|
17947
17969
|
attrs: { start: t },
|
|
@@ -17963,7 +17985,7 @@ var _1 = "listItem", Ql = "textStyle", Xl = /^(\d+)\.\s$/, Cd = qe.create({
|
|
|
17963
17985
|
tokenize: (n, e, t) => {
|
|
17964
17986
|
var r;
|
|
17965
17987
|
const i = n.split(`
|
|
17966
|
-
`), [s, o] =
|
|
17988
|
+
`), [s, o] = Z1(i);
|
|
17967
17989
|
if (s.length === 0)
|
|
17968
17990
|
return;
|
|
17969
17991
|
const l = Sd(s, 0, t);
|
|
@@ -17982,7 +18004,7 @@ var _1 = "listItem", Ql = "textStyle", Xl = /^(\d+)\.\s$/, Cd = qe.create({
|
|
|
17982
18004
|
},
|
|
17983
18005
|
addCommands() {
|
|
17984
18006
|
return {
|
|
17985
|
-
toggleOrderedList: () => ({ commands: n, chain: e }) => this.options.keepAttributes ? e().toggleList(this.name, this.options.itemTypeName, this.options.keepMarks).updateAttributes(
|
|
18007
|
+
toggleOrderedList: () => ({ commands: n, chain: e }) => this.options.keepAttributes ? e().toggleList(this.name, this.options.itemTypeName, this.options.keepMarks).updateAttributes(eb, this.editor.getAttributes(Ql)).run() : n.toggleList(this.name, this.options.itemTypeName, this.options.keepMarks)
|
|
17986
18008
|
};
|
|
17987
18009
|
},
|
|
17988
18010
|
addKeyboardShortcuts() {
|
|
@@ -18007,7 +18029,7 @@ var _1 = "listItem", Ql = "textStyle", Xl = /^(\d+)\.\s$/, Cd = qe.create({
|
|
|
18007
18029
|
editor: this.editor
|
|
18008
18030
|
})), [n];
|
|
18009
18031
|
}
|
|
18010
|
-
}),
|
|
18032
|
+
}), tb = /^\s*(\[([( |x])?\])\s$/, nb = qe.create({
|
|
18011
18033
|
name: "taskItem",
|
|
18012
18034
|
addOptions() {
|
|
18013
18035
|
return {
|
|
@@ -18135,7 +18157,7 @@ var _1 = "listItem", Ql = "textStyle", Xl = /^(\d+)\.\s$/, Cd = qe.create({
|
|
|
18135
18157
|
addInputRules() {
|
|
18136
18158
|
return [
|
|
18137
18159
|
vn({
|
|
18138
|
-
find:
|
|
18160
|
+
find: tb,
|
|
18139
18161
|
type: this.type,
|
|
18140
18162
|
getAttributes: (n) => ({
|
|
18141
18163
|
checked: n[n.length - 1] === "x"
|
|
@@ -18143,7 +18165,7 @@ var _1 = "listItem", Ql = "textStyle", Xl = /^(\d+)\.\s$/, Cd = qe.create({
|
|
|
18143
18165
|
})
|
|
18144
18166
|
];
|
|
18145
18167
|
}
|
|
18146
|
-
}),
|
|
18168
|
+
}), rb = qe.create({
|
|
18147
18169
|
name: "taskList",
|
|
18148
18170
|
addOptions() {
|
|
18149
18171
|
return {
|
|
@@ -18260,10 +18282,10 @@ pe.create({
|
|
|
18260
18282
|
name: "listKit",
|
|
18261
18283
|
addExtensions() {
|
|
18262
18284
|
const n = [];
|
|
18263
|
-
return this.options.bulletList !== !1 && n.push(md.configure(this.options.bulletList)), this.options.listItem !== !1 && n.push(gd.configure(this.options.listItem)), this.options.listKeymap !== !1 && n.push(wd.configure(this.options.listKeymap)), this.options.orderedList !== !1 && n.push(Cd.configure(this.options.orderedList)), this.options.taskItem !== !1 && n.push(
|
|
18285
|
+
return this.options.bulletList !== !1 && n.push(md.configure(this.options.bulletList)), this.options.listItem !== !1 && n.push(gd.configure(this.options.listItem)), this.options.listKeymap !== !1 && n.push(wd.configure(this.options.listKeymap)), this.options.orderedList !== !1 && n.push(Cd.configure(this.options.orderedList)), this.options.taskItem !== !1 && n.push(nb.configure(this.options.taskItem)), this.options.taskList !== !1 && n.push(rb.configure(this.options.taskList)), n;
|
|
18264
18286
|
}
|
|
18265
18287
|
});
|
|
18266
|
-
var
|
|
18288
|
+
var ib = qe.create({
|
|
18267
18289
|
name: "paragraph",
|
|
18268
18290
|
priority: 1e3,
|
|
18269
18291
|
addOptions() {
|
|
@@ -18299,7 +18321,7 @@ var rb = qe.create({
|
|
|
18299
18321
|
"Mod-Alt-0": () => this.editor.commands.setParagraph()
|
|
18300
18322
|
};
|
|
18301
18323
|
}
|
|
18302
|
-
}),
|
|
18324
|
+
}), sb = /(?:^|\s)(~~(?!\s+~~)((?:[^~]+))~~(?!\s+~~))$/, ob = /(?:^|\s)(~~(?!\s+~~)((?:[^~]+))~~(?!\s+~~))/g, lb = en.create({
|
|
18303
18325
|
name: "strike",
|
|
18304
18326
|
addOptions() {
|
|
18305
18327
|
return {
|
|
@@ -18345,7 +18367,7 @@ var rb = qe.create({
|
|
|
18345
18367
|
addInputRules() {
|
|
18346
18368
|
return [
|
|
18347
18369
|
kn({
|
|
18348
|
-
find:
|
|
18370
|
+
find: sb,
|
|
18349
18371
|
type: this.type
|
|
18350
18372
|
})
|
|
18351
18373
|
];
|
|
@@ -18353,12 +18375,12 @@ var rb = qe.create({
|
|
|
18353
18375
|
addPasteRules() {
|
|
18354
18376
|
return [
|
|
18355
18377
|
Xt({
|
|
18356
|
-
find:
|
|
18378
|
+
find: ob,
|
|
18357
18379
|
type: this.type
|
|
18358
18380
|
})
|
|
18359
18381
|
];
|
|
18360
18382
|
}
|
|
18361
|
-
}),
|
|
18383
|
+
}), ab = qe.create({
|
|
18362
18384
|
name: "text",
|
|
18363
18385
|
group: "inline",
|
|
18364
18386
|
parseMarkdown: (n) => ({
|
|
@@ -18426,15 +18448,15 @@ var rb = qe.create({
|
|
|
18426
18448
|
"Mod-U": () => this.editor.commands.toggleUnderline()
|
|
18427
18449
|
};
|
|
18428
18450
|
}
|
|
18429
|
-
}),
|
|
18430
|
-
function
|
|
18451
|
+
}), cb = Md;
|
|
18452
|
+
function db(n = {}) {
|
|
18431
18453
|
return new ue({
|
|
18432
18454
|
view(e) {
|
|
18433
|
-
return new
|
|
18455
|
+
return new ub(e, n);
|
|
18434
18456
|
}
|
|
18435
18457
|
});
|
|
18436
18458
|
}
|
|
18437
|
-
class
|
|
18459
|
+
class ub {
|
|
18438
18460
|
constructor(e, t) {
|
|
18439
18461
|
var r;
|
|
18440
18462
|
this.editorView = e, this.cursorPos = null, this.element = null, this.timeout = -1, this.width = (r = t.width) !== null && r !== void 0 ? r : 1, this.color = t.color === !1 ? void 0 : t.color || "black", this.class = t.class, this.handlers = ["dragover", "dragend", "drop", "dragleave"].map((i) => {
|
|
@@ -18547,7 +18569,7 @@ class he extends Y {
|
|
|
18547
18569
|
*/
|
|
18548
18570
|
static valid(e) {
|
|
18549
18571
|
let t = e.parent;
|
|
18550
|
-
if (t.isTextblock || !
|
|
18572
|
+
if (t.isTextblock || !fb(e) || !hb(e))
|
|
18551
18573
|
return !1;
|
|
18552
18574
|
let r = t.type.spec.allowGapCursor;
|
|
18553
18575
|
if (r != null)
|
|
@@ -18611,7 +18633,7 @@ class xo {
|
|
|
18611
18633
|
function Td(n) {
|
|
18612
18634
|
return n.isAtom || n.spec.isolating || n.spec.createGapCursor;
|
|
18613
18635
|
}
|
|
18614
|
-
function
|
|
18636
|
+
function fb(n) {
|
|
18615
18637
|
for (let e = n.depth; e >= 0; e--) {
|
|
18616
18638
|
let t = n.index(e), r = n.node(e);
|
|
18617
18639
|
if (t == 0) {
|
|
@@ -18628,7 +18650,7 @@ function ub(n) {
|
|
|
18628
18650
|
}
|
|
18629
18651
|
return !0;
|
|
18630
18652
|
}
|
|
18631
|
-
function
|
|
18653
|
+
function hb(n) {
|
|
18632
18654
|
for (let e = n.depth; e >= 0; e--) {
|
|
18633
18655
|
let t = n.indexAfter(e), r = n.node(e);
|
|
18634
18656
|
if (t == r.childCount) {
|
|
@@ -18645,20 +18667,20 @@ function fb(n) {
|
|
|
18645
18667
|
}
|
|
18646
18668
|
return !0;
|
|
18647
18669
|
}
|
|
18648
|
-
function
|
|
18670
|
+
function pb() {
|
|
18649
18671
|
return new ue({
|
|
18650
18672
|
props: {
|
|
18651
|
-
decorations:
|
|
18673
|
+
decorations: bb,
|
|
18652
18674
|
createSelectionBetween(n, e, t) {
|
|
18653
18675
|
return e.pos == t.pos && he.valid(t) ? new he(t) : null;
|
|
18654
18676
|
},
|
|
18655
|
-
handleClick:
|
|
18656
|
-
handleKeyDown:
|
|
18657
|
-
handleDOMEvents: { beforeinput:
|
|
18677
|
+
handleClick: gb,
|
|
18678
|
+
handleKeyDown: mb,
|
|
18679
|
+
handleDOMEvents: { beforeinput: yb }
|
|
18658
18680
|
}
|
|
18659
18681
|
});
|
|
18660
18682
|
}
|
|
18661
|
-
const
|
|
18683
|
+
const mb = Mc({
|
|
18662
18684
|
ArrowLeft: yr("horiz", -1),
|
|
18663
18685
|
ArrowRight: yr("horiz", 1),
|
|
18664
18686
|
ArrowUp: yr("vert", -1),
|
|
@@ -18677,7 +18699,7 @@ function yr(n, e) {
|
|
|
18677
18699
|
return c ? (i && i(r.tr.setSelection(new he(c))), !0) : !1;
|
|
18678
18700
|
};
|
|
18679
18701
|
}
|
|
18680
|
-
function
|
|
18702
|
+
function gb(n, e, t) {
|
|
18681
18703
|
if (!n || !n.editable)
|
|
18682
18704
|
return !1;
|
|
18683
18705
|
let r = n.state.doc.resolve(e);
|
|
@@ -18686,7 +18708,7 @@ function mb(n, e, t) {
|
|
|
18686
18708
|
let i = n.posAtCoords({ left: t.clientX, top: t.clientY });
|
|
18687
18709
|
return i && i.inside > -1 && K.isSelectable(n.state.doc.nodeAt(i.inside)) ? !1 : (n.dispatch(n.state.tr.setSelection(new he(r))), !0);
|
|
18688
18710
|
}
|
|
18689
|
-
function
|
|
18711
|
+
function yb(n, e) {
|
|
18690
18712
|
if (e.inputType != "insertCompositionText" || !(n.state.selection instanceof he))
|
|
18691
18713
|
return !1;
|
|
18692
18714
|
let { $from: t } = n.state.selection, r = t.parent.contentMatchAt(t.index()).findWrapping(n.state.schema.nodes.text);
|
|
@@ -18698,7 +18720,7 @@ function gb(n, e) {
|
|
|
18698
18720
|
let s = n.state.tr.replace(t.pos, t.pos, new P(i, 0, 0));
|
|
18699
18721
|
return s.setSelection(J.near(s.doc.resolve(t.pos + 1))), n.dispatch(s), !1;
|
|
18700
18722
|
}
|
|
18701
|
-
function
|
|
18723
|
+
function bb(n) {
|
|
18702
18724
|
if (!(n.selection instanceof he))
|
|
18703
18725
|
return null;
|
|
18704
18726
|
let e = document.createElement("div");
|
|
@@ -18713,7 +18735,7 @@ Ee.prototype.prepend = function(e) {
|
|
|
18713
18735
|
return e.length ? Ee.from(e).append(this) : this;
|
|
18714
18736
|
};
|
|
18715
18737
|
Ee.prototype.appendInner = function(e) {
|
|
18716
|
-
return new
|
|
18738
|
+
return new kb(this, e);
|
|
18717
18739
|
};
|
|
18718
18740
|
Ee.prototype.slice = function(e, t) {
|
|
18719
18741
|
return e === void 0 && (e = 0), t === void 0 && (t = this.length), e >= t ? Ee.empty : this.sliceInner(Math.max(0, e), Math.min(this.length, t));
|
|
@@ -18768,7 +18790,7 @@ var Ed = /* @__PURE__ */ (function(n) {
|
|
|
18768
18790
|
}, Object.defineProperties(e.prototype, t), e;
|
|
18769
18791
|
})(Ee);
|
|
18770
18792
|
Ee.empty = new Ed([]);
|
|
18771
|
-
var
|
|
18793
|
+
var kb = /* @__PURE__ */ (function(n) {
|
|
18772
18794
|
function e(t, r) {
|
|
18773
18795
|
n.call(this), this.left = t, this.right = r, this.length = t.length + r.length, this.depth = Math.max(t.depth, r.depth) + 1;
|
|
18774
18796
|
}
|
|
@@ -18801,7 +18823,7 @@ var bb = /* @__PURE__ */ (function(n) {
|
|
|
18801
18823
|
return this.left.depth >= Math.max(this.right.depth, r.depth) + 1 ? new e(this.left, new e(this.right, r)) : new e(this, r);
|
|
18802
18824
|
}, e;
|
|
18803
18825
|
})(Ee);
|
|
18804
|
-
const Ad = Ee,
|
|
18826
|
+
const Ad = Ee, vb = 500;
|
|
18805
18827
|
class Ze {
|
|
18806
18828
|
constructor(e, t) {
|
|
18807
18829
|
this.items = e, this.eventCount = t;
|
|
@@ -18843,7 +18865,7 @@ class Ze {
|
|
|
18843
18865
|
(h = a && a.merge(f)) && (f = h, d ? s.pop() : l = l.slice(0, l.length - 1)), s.push(f), t && (o++, t = void 0), i || (a = f);
|
|
18844
18866
|
}
|
|
18845
18867
|
let c = o - r.depth;
|
|
18846
|
-
return c >
|
|
18868
|
+
return c > wb && (l = xb(l, c), o -= c), new Ze(l.append(s), o);
|
|
18847
18869
|
}
|
|
18848
18870
|
remapping(e, t) {
|
|
18849
18871
|
let r = new Wn();
|
|
@@ -18883,7 +18905,7 @@ class Ze {
|
|
|
18883
18905
|
for (let f = t; f < o; f++)
|
|
18884
18906
|
c.push(new it(s.maps[f]));
|
|
18885
18907
|
let d = this.items.slice(0, i).append(c).append(r), u = new Ze(d, l);
|
|
18886
|
-
return u.emptyItemCount() >
|
|
18908
|
+
return u.emptyItemCount() > vb && (u = u.compress(this.items.length - r.length)), u;
|
|
18887
18909
|
}
|
|
18888
18910
|
emptyItemCount() {
|
|
18889
18911
|
let e = 0;
|
|
@@ -18915,7 +18937,7 @@ class Ze {
|
|
|
18915
18937
|
}
|
|
18916
18938
|
}
|
|
18917
18939
|
Ze.empty = new Ze(Ad.empty, 0);
|
|
18918
|
-
function
|
|
18940
|
+
function xb(n, e) {
|
|
18919
18941
|
let t;
|
|
18920
18942
|
return n.forEach((r, i) => {
|
|
18921
18943
|
if (r.selection && e-- == 0)
|
|
@@ -18939,23 +18961,23 @@ class vt {
|
|
|
18939
18961
|
this.done = e, this.undone = t, this.prevRanges = r, this.prevTime = i, this.prevComposition = s;
|
|
18940
18962
|
}
|
|
18941
18963
|
}
|
|
18942
|
-
const
|
|
18943
|
-
function
|
|
18964
|
+
const wb = 20;
|
|
18965
|
+
function Sb(n, e, t, r) {
|
|
18944
18966
|
let i = t.getMeta(Wt), s;
|
|
18945
18967
|
if (i)
|
|
18946
18968
|
return i.historyState;
|
|
18947
|
-
t.getMeta(
|
|
18969
|
+
t.getMeta(Tb) && (n = new vt(n.done, n.undone, null, 0, -1));
|
|
18948
18970
|
let o = t.getMeta("appendedTransaction");
|
|
18949
18971
|
if (t.steps.length == 0)
|
|
18950
18972
|
return n;
|
|
18951
18973
|
if (o && o.getMeta(Wt))
|
|
18952
18974
|
return o.getMeta(Wt).redo ? new vt(n.done.addTransform(t, void 0, r, wr(e)), n.undone, Zl(t.mapping.maps), n.prevTime, n.prevComposition) : new vt(n.done, n.undone.addTransform(t, void 0, r, wr(e)), null, n.prevTime, n.prevComposition);
|
|
18953
18975
|
if (t.getMeta("addToHistory") !== !1 && !(o && o.getMeta("addToHistory") === !1)) {
|
|
18954
|
-
let l = t.getMeta("composition"), a = n.prevTime == 0 || !o && n.prevComposition != l && (n.prevTime < (t.time || 0) - r.newGroupDelay || !
|
|
18976
|
+
let l = t.getMeta("composition"), a = n.prevTime == 0 || !o && n.prevComposition != l && (n.prevTime < (t.time || 0) - r.newGroupDelay || !Cb(t, n.prevRanges)), c = o ? es(n.prevRanges, t.mapping) : Zl(t.mapping.maps);
|
|
18955
18977
|
return new vt(n.done.addTransform(t, a ? e.selection.getBookmark() : void 0, r, wr(e)), Ze.empty, c, t.time, l ?? n.prevComposition);
|
|
18956
18978
|
} else return (s = t.getMeta("rebased")) ? new vt(n.done.rebased(t, s), n.undone.rebased(t, s), es(n.prevRanges, t.mapping), n.prevTime, n.prevComposition) : new vt(n.done.addMaps(t.mapping.maps), n.undone.addMaps(t.mapping.maps), es(n.prevRanges, t.mapping), n.prevTime, n.prevComposition);
|
|
18957
18979
|
}
|
|
18958
|
-
function
|
|
18980
|
+
function Cb(n, e) {
|
|
18959
18981
|
if (!e)
|
|
18960
18982
|
return !1;
|
|
18961
18983
|
if (!n.docChanged)
|
|
@@ -18982,7 +19004,7 @@ function es(n, e) {
|
|
|
18982
19004
|
}
|
|
18983
19005
|
return t;
|
|
18984
19006
|
}
|
|
18985
|
-
function
|
|
19007
|
+
function Mb(n, e, t) {
|
|
18986
19008
|
let r = wr(e), i = Wt.get(e).spec.config, s = (t ? n.undone : n.done).popEvent(e, r);
|
|
18987
19009
|
if (!s)
|
|
18988
19010
|
return null;
|
|
@@ -19002,8 +19024,8 @@ function wr(n) {
|
|
|
19002
19024
|
}
|
|
19003
19025
|
return ts;
|
|
19004
19026
|
}
|
|
19005
|
-
const Wt = new ke("history"),
|
|
19006
|
-
function
|
|
19027
|
+
const Wt = new ke("history"), Tb = new ke("closeHistory");
|
|
19028
|
+
function Eb(n = {}) {
|
|
19007
19029
|
return n = {
|
|
19008
19030
|
depth: n.depth || 100,
|
|
19009
19031
|
newGroupDelay: n.newGroupDelay || 500
|
|
@@ -19014,7 +19036,7 @@ function Tb(n = {}) {
|
|
|
19014
19036
|
return new vt(Ze.empty, Ze.empty, null, 0, -1);
|
|
19015
19037
|
},
|
|
19016
19038
|
apply(e, t, r) {
|
|
19017
|
-
return
|
|
19039
|
+
return Sb(t, r, e, n);
|
|
19018
19040
|
}
|
|
19019
19041
|
},
|
|
19020
19042
|
config: n,
|
|
@@ -19034,7 +19056,7 @@ function Od(n, e) {
|
|
|
19034
19056
|
if (!i || (n ? i.undone : i.done).eventCount == 0)
|
|
19035
19057
|
return !1;
|
|
19036
19058
|
if (r) {
|
|
19037
|
-
let s =
|
|
19059
|
+
let s = Mb(i, t, n);
|
|
19038
19060
|
s && r(e ? s.scrollIntoView() : s);
|
|
19039
19061
|
}
|
|
19040
19062
|
return !0;
|
|
@@ -19110,7 +19132,7 @@ pe.create({
|
|
|
19110
19132
|
];
|
|
19111
19133
|
}
|
|
19112
19134
|
});
|
|
19113
|
-
var
|
|
19135
|
+
var Ab = pe.create({
|
|
19114
19136
|
name: "dropCursor",
|
|
19115
19137
|
addOptions() {
|
|
19116
19138
|
return {
|
|
@@ -19120,7 +19142,7 @@ var Eb = pe.create({
|
|
|
19120
19142
|
};
|
|
19121
19143
|
},
|
|
19122
19144
|
addProseMirrorPlugins() {
|
|
19123
|
-
return [
|
|
19145
|
+
return [db(this.options)];
|
|
19124
19146
|
}
|
|
19125
19147
|
});
|
|
19126
19148
|
pe.create({
|
|
@@ -19166,10 +19188,10 @@ pe.create({
|
|
|
19166
19188
|
];
|
|
19167
19189
|
}
|
|
19168
19190
|
});
|
|
19169
|
-
var
|
|
19191
|
+
var Ob = pe.create({
|
|
19170
19192
|
name: "gapCursor",
|
|
19171
19193
|
addProseMirrorPlugins() {
|
|
19172
|
-
return [
|
|
19194
|
+
return [pb()];
|
|
19173
19195
|
},
|
|
19174
19196
|
extendNodeSchema(n) {
|
|
19175
19197
|
var e;
|
|
@@ -19182,7 +19204,7 @@ var Ab = pe.create({
|
|
|
19182
19204
|
allowGapCursor: (e = se(U(n, "allowGapCursor", t))) != null ? e : null
|
|
19183
19205
|
};
|
|
19184
19206
|
}
|
|
19185
|
-
}),
|
|
19207
|
+
}), Nb = pe.create({
|
|
19186
19208
|
name: "placeholder",
|
|
19187
19209
|
addOptions() {
|
|
19188
19210
|
return {
|
|
@@ -19256,7 +19278,7 @@ pe.create({
|
|
|
19256
19278
|
function ea({ types: n, node: e }) {
|
|
19257
19279
|
return e && Array.isArray(n) && n.includes(e.type) || e?.type === n;
|
|
19258
19280
|
}
|
|
19259
|
-
var
|
|
19281
|
+
var Ib = pe.create({
|
|
19260
19282
|
name: "trailingNode",
|
|
19261
19283
|
addOptions() {
|
|
19262
19284
|
return {
|
|
@@ -19290,7 +19312,7 @@ var Nb = pe.create({
|
|
|
19290
19312
|
})
|
|
19291
19313
|
];
|
|
19292
19314
|
}
|
|
19293
|
-
}),
|
|
19315
|
+
}), Db = pe.create({
|
|
19294
19316
|
name: "undoRedo",
|
|
19295
19317
|
addOptions() {
|
|
19296
19318
|
return {
|
|
@@ -19305,7 +19327,7 @@ var Nb = pe.create({
|
|
|
19305
19327
|
};
|
|
19306
19328
|
},
|
|
19307
19329
|
addProseMirrorPlugins() {
|
|
19308
|
-
return [
|
|
19330
|
+
return [Eb(this.options)];
|
|
19309
19331
|
},
|
|
19310
19332
|
addKeyboardShortcuts() {
|
|
19311
19333
|
return {
|
|
@@ -19317,14 +19339,14 @@ var Nb = pe.create({
|
|
|
19317
19339
|
"Shift-Mod-я": () => this.editor.commands.redo()
|
|
19318
19340
|
};
|
|
19319
19341
|
}
|
|
19320
|
-
}),
|
|
19342
|
+
}), $b = pe.create({
|
|
19321
19343
|
name: "starterKit",
|
|
19322
19344
|
addExtensions() {
|
|
19323
19345
|
var n, e, t, r;
|
|
19324
19346
|
const i = [];
|
|
19325
|
-
return this.options.bold !== !1 && i.push(
|
|
19347
|
+
return this.options.bold !== !1 && i.push(s1.configure(this.options.bold)), this.options.blockquote !== !1 && i.push(e1.configure(this.options.blockquote)), this.options.bulletList !== !1 && i.push(md.configure(this.options.bulletList)), this.options.code !== !1 && i.push(a1.configure(this.options.code)), this.options.codeBlock !== !1 && i.push(u1.configure(this.options.codeBlock)), this.options.document !== !1 && i.push(f1.configure(this.options.document)), this.options.dropcursor !== !1 && i.push(Ab.configure(this.options.dropcursor)), this.options.gapcursor !== !1 && i.push(Ob.configure(this.options.gapcursor)), this.options.hardBreak !== !1 && i.push(h1.configure(this.options.hardBreak)), this.options.heading !== !1 && i.push(sd.configure(this.options.heading)), this.options.undoRedo !== !1 && i.push(Db.configure(this.options.undoRedo)), this.options.horizontalRule !== !1 && i.push(m1.configure(this.options.horizontalRule)), this.options.italic !== !1 && i.push(v1.configure(this.options.italic)), this.options.listItem !== !1 && i.push(gd.configure(this.options.listItem)), this.options.listKeymap !== !1 && i.push(wd.configure((n = this.options) == null ? void 0 : n.listKeymap)), this.options.link !== !1 && i.push(W1.configure((e = this.options) == null ? void 0 : e.link)), this.options.orderedList !== !1 && i.push(Cd.configure(this.options.orderedList)), this.options.paragraph !== !1 && i.push(ib.configure(this.options.paragraph)), this.options.strike !== !1 && i.push(lb.configure(this.options.strike)), this.options.text !== !1 && i.push(ab.configure(this.options.text)), this.options.underline !== !1 && i.push(Md.configure((t = this.options) == null ? void 0 : t.underline)), this.options.trailingNode !== !1 && i.push(Ib.configure((r = this.options) == null ? void 0 : r.trailingNode)), i;
|
|
19326
19348
|
}
|
|
19327
|
-
}),
|
|
19349
|
+
}), Rb = $b, Lb = pe.create({
|
|
19328
19350
|
name: "textAlign",
|
|
19329
19351
|
addOptions() {
|
|
19330
19352
|
return {
|
|
@@ -19365,11 +19387,11 @@ var Nb = pe.create({
|
|
|
19365
19387
|
"Mod-Shift-j": () => this.editor.commands.setTextAlign("justify")
|
|
19366
19388
|
};
|
|
19367
19389
|
}
|
|
19368
|
-
}),
|
|
19369
|
-
const
|
|
19390
|
+
}), Pb = Lb, zb = Nb;
|
|
19391
|
+
const Bb = { class: "input-richtext-toolbar" }, Vb = { class: "input-richtext-group" }, Fb = { class: "input-richtext-group" }, Hb = { class: "input-richtext-group" }, jb = { class: "input-richtext-group" }, qb = { class: "input-richtext-group" }, Ub = { class: "input-richtext-group" }, Wb = { key: 0 }, Kb = {
|
|
19370
19392
|
key: 1,
|
|
19371
19393
|
class: "input-richtext-dropdown-wrapper"
|
|
19372
|
-
},
|
|
19394
|
+
}, Jb = { key: 0 }, Gb = ["onClick"], Yb = { class: "input-richtext-dropdown-item-label" }, Qb = { class: "input-richtext-editor-wrapper" }, Xb = /* @__PURE__ */ ae({
|
|
19373
19395
|
__name: "UiInput.RichText",
|
|
19374
19396
|
props: {
|
|
19375
19397
|
minHeight: { default: "200px" },
|
|
@@ -19434,19 +19456,19 @@ const zb = { class: "input-richtext-toolbar" }, Bb = { class: "input-richtext-gr
|
|
|
19434
19456
|
b.value && k.action(b.value), m();
|
|
19435
19457
|
}, v = (k, w) => {
|
|
19436
19458
|
k && (c.value[w] = k.$el || k);
|
|
19437
|
-
}, b =
|
|
19459
|
+
}, b = Z0({
|
|
19438
19460
|
content: l.value,
|
|
19439
19461
|
editable: !t.disabled && !t.readonly,
|
|
19440
19462
|
extensions: [
|
|
19441
|
-
|
|
19442
|
-
|
|
19463
|
+
Rb,
|
|
19464
|
+
p1.configure({
|
|
19443
19465
|
levels: [1, 2, 3]
|
|
19444
19466
|
}),
|
|
19445
|
-
|
|
19446
|
-
|
|
19467
|
+
cb,
|
|
19468
|
+
Pb.configure({
|
|
19447
19469
|
types: ["heading", "paragraph"]
|
|
19448
19470
|
}),
|
|
19449
|
-
|
|
19471
|
+
zb.configure({
|
|
19450
19472
|
placeholder: t.placeholder
|
|
19451
19473
|
})
|
|
19452
19474
|
],
|
|
@@ -19475,8 +19497,8 @@ const zb = { class: "input-richtext-toolbar" }, Bb = { class: "input-richtext-gr
|
|
|
19475
19497
|
"input-disabled": n.disabled
|
|
19476
19498
|
}])
|
|
19477
19499
|
}, [
|
|
19478
|
-
$("div",
|
|
19479
|
-
$("div",
|
|
19500
|
+
$("div", Bb, [
|
|
19501
|
+
$("div", Vb, [
|
|
19480
19502
|
z(re, {
|
|
19481
19503
|
color: R(b)?.isActive("bold") ? "primary" : "secondary",
|
|
19482
19504
|
size: "sm",
|
|
@@ -19539,7 +19561,7 @@ const zb = { class: "input-richtext-toolbar" }, Bb = { class: "input-richtext-gr
|
|
|
19539
19561
|
spacing: "28px",
|
|
19540
19562
|
margin: "4px"
|
|
19541
19563
|
}),
|
|
19542
|
-
$("div",
|
|
19564
|
+
$("div", Fb, [
|
|
19543
19565
|
z(re, {
|
|
19544
19566
|
color: R(b)?.isActive("heading", { level: 1 }) ? "primary" : "secondary",
|
|
19545
19567
|
size: "sm",
|
|
@@ -19588,7 +19610,7 @@ const zb = { class: "input-richtext-toolbar" }, Bb = { class: "input-richtext-gr
|
|
|
19588
19610
|
spacing: "28px",
|
|
19589
19611
|
margin: "4px"
|
|
19590
19612
|
}),
|
|
19591
|
-
$("div",
|
|
19613
|
+
$("div", Hb, [
|
|
19592
19614
|
z(re, {
|
|
19593
19615
|
color: R(b)?.isActive({ textAlign: "left" }) ? "primary" : "secondary",
|
|
19594
19616
|
size: "sm",
|
|
@@ -19637,7 +19659,7 @@ const zb = { class: "input-richtext-toolbar" }, Bb = { class: "input-richtext-gr
|
|
|
19637
19659
|
spacing: "28px",
|
|
19638
19660
|
margin: "4px"
|
|
19639
19661
|
}),
|
|
19640
|
-
$("div",
|
|
19662
|
+
$("div", jb, [
|
|
19641
19663
|
z(re, {
|
|
19642
19664
|
color: R(b)?.isActive("bulletList") ? "primary" : "secondary",
|
|
19643
19665
|
size: "sm",
|
|
@@ -19700,7 +19722,7 @@ const zb = { class: "input-richtext-toolbar" }, Bb = { class: "input-richtext-gr
|
|
|
19700
19722
|
spacing: "28px",
|
|
19701
19723
|
margin: "4px"
|
|
19702
19724
|
}),
|
|
19703
|
-
$("div",
|
|
19725
|
+
$("div", qb, [
|
|
19704
19726
|
z(re, {
|
|
19705
19727
|
color: "secondary",
|
|
19706
19728
|
size: "sm",
|
|
@@ -19750,7 +19772,7 @@ const zb = { class: "input-richtext-toolbar" }, Bb = { class: "input-richtext-gr
|
|
|
19750
19772
|
spacing: "28px",
|
|
19751
19773
|
margin: "4px"
|
|
19752
19774
|
}),
|
|
19753
|
-
$("div",
|
|
19775
|
+
$("div", Ub, [
|
|
19754
19776
|
(C(!0), T(be, null, Je(n.customControls, (x, M) => (C(), T(be, { key: M }, [
|
|
19755
19777
|
x.action ? (C(), Z(re, {
|
|
19756
19778
|
key: 0,
|
|
@@ -19763,7 +19785,7 @@ const zb = { class: "input-richtext-toolbar" }, Bb = { class: "input-richtext-gr
|
|
|
19763
19785
|
title: x.tooltip || x.label
|
|
19764
19786
|
}, Xe({
|
|
19765
19787
|
default: N(() => [
|
|
19766
|
-
x.label && x.icon ? (C(), T("span",
|
|
19788
|
+
x.label && x.icon ? (C(), T("span", Wb, ee(x.label), 1)) : x.label ? (C(), T(be, { key: 1 }, [
|
|
19767
19789
|
Ve(ee(x.label), 1)
|
|
19768
19790
|
], 64)) : W("", !0)
|
|
19769
19791
|
]),
|
|
@@ -19776,7 +19798,7 @@ const zb = { class: "input-richtext-toolbar" }, Bb = { class: "input-richtext-gr
|
|
|
19776
19798
|
]),
|
|
19777
19799
|
key: "0"
|
|
19778
19800
|
} : void 0
|
|
19779
|
-
]), 1032, ["icon", "onClick", "disabled", "title"])) : x.list ? (C(), T("div",
|
|
19801
|
+
]), 1032, ["icon", "onClick", "disabled", "title"])) : x.list ? (C(), T("div", Kb, [
|
|
19780
19802
|
z(re, {
|
|
19781
19803
|
ref_for: !0,
|
|
19782
19804
|
ref: (D) => v(D, M),
|
|
@@ -19795,7 +19817,7 @@ const zb = { class: "input-richtext-toolbar" }, Bb = { class: "input-richtext-gr
|
|
|
19795
19817
|
})
|
|
19796
19818
|
]),
|
|
19797
19819
|
default: N(() => [
|
|
19798
|
-
x.label ? (C(), T("span",
|
|
19820
|
+
x.label ? (C(), T("span", Jb, ee(x.label), 1)) : W("", !0)
|
|
19799
19821
|
]),
|
|
19800
19822
|
_: 2
|
|
19801
19823
|
}, [
|
|
@@ -19831,12 +19853,12 @@ const zb = { class: "input-richtext-toolbar" }, Bb = { class: "input-richtext-gr
|
|
|
19831
19853
|
size: 16,
|
|
19832
19854
|
class: "input-richtext-dropdown-item-icon"
|
|
19833
19855
|
})) : W("", !0),
|
|
19834
|
-
$("span",
|
|
19835
|
-
], 8,
|
|
19856
|
+
$("span", Yb, ee(x.label), 1)
|
|
19857
|
+
], 8, Gb))), 128))
|
|
19836
19858
|
], 4)) : W("", !0)
|
|
19837
19859
|
])),
|
|
19838
|
-
$("div",
|
|
19839
|
-
z(R(
|
|
19860
|
+
$("div", Qb, [
|
|
19861
|
+
z(R(X0), {
|
|
19840
19862
|
editor: R(b),
|
|
19841
19863
|
class: "input-richtext-editor",
|
|
19842
19864
|
id: n.inputId
|
|
@@ -19853,16 +19875,16 @@ const zb = { class: "input-richtext-toolbar" }, Bb = { class: "input-richtext-gr
|
|
|
19853
19875
|
], 512)) : W("", !0)
|
|
19854
19876
|
], 2));
|
|
19855
19877
|
}
|
|
19856
|
-
}),
|
|
19878
|
+
}), Zb = /* @__PURE__ */ Oe(Xb, [["__scopeId", "data-v-5216bae2"]]), _b = { class: "pincode-inputs" }, ek = {
|
|
19857
19879
|
key: 0,
|
|
19858
19880
|
class: "pincode-icon pincode-icon-leading"
|
|
19859
|
-
},
|
|
19881
|
+
}, tk = ["value", "disabled", "readonly", "tabindex", "data-index", "onInput", "onKeydown", "onFocus"], nk = {
|
|
19860
19882
|
key: 1,
|
|
19861
19883
|
class: "pincode-divider"
|
|
19862
|
-
},
|
|
19884
|
+
}, rk = {
|
|
19863
19885
|
key: 1,
|
|
19864
19886
|
class: "pincode-icon pincode-icon-trailing"
|
|
19865
|
-
},
|
|
19887
|
+
}, ik = /* @__PURE__ */ ae({
|
|
19866
19888
|
__name: "UiInput.Pincode",
|
|
19867
19889
|
props: {
|
|
19868
19890
|
maxLength: { default: 6 },
|
|
@@ -19970,9 +19992,9 @@ const zb = { class: "input-richtext-toolbar" }, Bb = { class: "input-richtext-gr
|
|
|
19970
19992
|
}), (S, v) => (C(), T("div", {
|
|
19971
19993
|
class: X(["pincode-wrapper", [`pincode-size-${n.size}`, { "pincode-error": n.error }]])
|
|
19972
19994
|
}, [
|
|
19973
|
-
$("div",
|
|
19995
|
+
$("div", _b, [
|
|
19974
19996
|
E(S.$slots, "leading", {}, void 0, !0),
|
|
19975
|
-
t.hasLeadingIcon ? (C(), T("div",
|
|
19997
|
+
t.hasLeadingIcon ? (C(), T("div", ek, [
|
|
19976
19998
|
E(S.$slots, "leading-icon", {}, void 0, !0)
|
|
19977
19999
|
])) : W("", !0),
|
|
19978
20000
|
(C(!0), T(be, null, Je(n.maxLength, (b) => (C(), T(be, { key: b }, [
|
|
@@ -19996,39 +20018,39 @@ const zb = { class: "input-richtext-toolbar" }, Bb = { class: "input-richtext-gr
|
|
|
19996
20018
|
onFocus: (k) => g(b - 1),
|
|
19997
20019
|
onBlur: y,
|
|
19998
20020
|
onPaste: m
|
|
19999
|
-
}, null, 42,
|
|
20021
|
+
}, null, 42, tk),
|
|
20000
20022
|
u(b) && c.value ? (C(), Z(Lt, Dn({
|
|
20001
20023
|
key: 0,
|
|
20002
20024
|
ref_for: !0
|
|
20003
|
-
}, d.value, { class: "pincode-custom-divider" }), null, 16)) : u(b) ? (C(), T("span",
|
|
20025
|
+
}, d.value, { class: "pincode-custom-divider" }), null, 16)) : u(b) ? (C(), T("span", nk, ee(a.value), 1)) : W("", !0)
|
|
20004
20026
|
], 64))), 128)),
|
|
20005
|
-
t.hasTrailingIcon ? (C(), T("div",
|
|
20027
|
+
t.hasTrailingIcon ? (C(), T("div", rk, [
|
|
20006
20028
|
E(S.$slots, "trailing-icon", {}, void 0, !0)
|
|
20007
20029
|
])) : W("", !0),
|
|
20008
20030
|
E(S.$slots, "trailing", {}, void 0, !0)
|
|
20009
20031
|
])
|
|
20010
20032
|
], 2));
|
|
20011
20033
|
}
|
|
20012
|
-
}),
|
|
20013
|
-
function
|
|
20034
|
+
}), sk = /* @__PURE__ */ Oe(ik, [["__scopeId", "data-v-12f41567"]]);
|
|
20035
|
+
function ok(n, e) {
|
|
20014
20036
|
const t = n[e];
|
|
20015
20037
|
if (!t) return !1;
|
|
20016
20038
|
const r = t();
|
|
20017
20039
|
return !r || r.length === 0 ? !1 : r.some((i) => !!(i.children && i.children !== "" || i.type && typeof i.type == "object" || i.props && Object.keys(i.props).length > 0));
|
|
20018
20040
|
}
|
|
20019
|
-
const
|
|
20041
|
+
const lk = ["for"], ak = {
|
|
20020
20042
|
key: 0,
|
|
20021
20043
|
class: "input-required"
|
|
20022
|
-
},
|
|
20044
|
+
}, ck = {
|
|
20023
20045
|
key: 1,
|
|
20024
20046
|
class: "input-hint"
|
|
20025
|
-
},
|
|
20047
|
+
}, dk = {
|
|
20026
20048
|
key: 2,
|
|
20027
20049
|
class: "input-error-text"
|
|
20028
|
-
},
|
|
20050
|
+
}, uk = {
|
|
20029
20051
|
key: 3,
|
|
20030
20052
|
class: "input-help-text"
|
|
20031
|
-
},
|
|
20053
|
+
}, fk = /* @__PURE__ */ ae({
|
|
20032
20054
|
__name: "UiInput",
|
|
20033
20055
|
props: {
|
|
20034
20056
|
type: {},
|
|
@@ -20086,7 +20108,7 @@ const ok = ["for"], lk = {
|
|
|
20086
20108
|
}, { immediate: !0 }), ht(() => t.modelValue, (y) => {
|
|
20087
20109
|
y !== void 0 && (s.value = y);
|
|
20088
20110
|
}, { immediate: !0 });
|
|
20089
|
-
const l = L(() => `input-${Math.random().toString(36).substring(2, 11)}`), a = (y) =>
|
|
20111
|
+
const l = L(() => `input-${Math.random().toString(36).substring(2, 11)}`), a = (y) => ok(i, y), c = L(() => {
|
|
20090
20112
|
const y = ["text", "email", "password", "number", "tel", "url", "search"], S = t.type || "text";
|
|
20091
20113
|
return y.includes(S);
|
|
20092
20114
|
}), d = (y) => {
|
|
@@ -20117,8 +20139,8 @@ const ok = ["for"], lk = {
|
|
|
20117
20139
|
class: "input-label"
|
|
20118
20140
|
}, [
|
|
20119
20141
|
Ve(ee(t.label) + " ", 1),
|
|
20120
|
-
t.required ? (C(), T("span",
|
|
20121
|
-
], 8,
|
|
20142
|
+
t.required ? (C(), T("span", ak, "*")) : W("", !0)
|
|
20143
|
+
], 8, lk)) : W("", !0),
|
|
20122
20144
|
$("div", null, [
|
|
20123
20145
|
c.value ? (C(), Z(yf, {
|
|
20124
20146
|
key: 0,
|
|
@@ -20319,7 +20341,7 @@ const ok = ["for"], lk = {
|
|
|
20319
20341
|
"onUpdate:modelValue": d,
|
|
20320
20342
|
onBlur: u,
|
|
20321
20343
|
onFocus: f
|
|
20322
|
-
}, null, 8, ["model-value", "placeholder", "disabled", "readonly", "required", "min", "max", "input-id", "error", "size", "tabindex"])) : n.type === "richtext" ? (C(), Z(
|
|
20344
|
+
}, null, 8, ["model-value", "placeholder", "disabled", "readonly", "required", "min", "max", "input-id", "error", "size", "tabindex"])) : n.type === "richtext" ? (C(), Z(Zb, {
|
|
20323
20345
|
key: 7,
|
|
20324
20346
|
"model-value": o.value,
|
|
20325
20347
|
placeholder: n.placeholder,
|
|
@@ -20342,7 +20364,7 @@ const ok = ["for"], lk = {
|
|
|
20342
20364
|
]),
|
|
20343
20365
|
key: "0"
|
|
20344
20366
|
} : void 0
|
|
20345
|
-
]), 1032, ["model-value", "placeholder", "disabled", "readonly", "input-id", "error", "min-height", "max-height", "custom-controls", "tabindex"])) : n.type === "pincode" ? (C(), Z(
|
|
20367
|
+
]), 1032, ["model-value", "placeholder", "disabled", "readonly", "input-id", "error", "min-height", "max-height", "custom-controls", "tabindex"])) : n.type === "pincode" ? (C(), Z(sk, {
|
|
20346
20368
|
key: 8,
|
|
20347
20369
|
"model-value": o.value,
|
|
20348
20370
|
"max-length": t.maxLength || 6,
|
|
@@ -20389,13 +20411,13 @@ const ok = ["for"], lk = {
|
|
|
20389
20411
|
} : void 0
|
|
20390
20412
|
]), 1032, ["model-value", "max-length", "variant", "divider", "disabled", "readonly", "input-id", "error", "size", "tabindex"])) : W("", !0)
|
|
20391
20413
|
]),
|
|
20392
|
-
y.$slots.hint ? (C(), T("div",
|
|
20414
|
+
y.$slots.hint ? (C(), T("div", ck, [
|
|
20393
20415
|
E(y.$slots, "hint", {}, void 0, !0)
|
|
20394
20416
|
])) : W("", !0),
|
|
20395
|
-
t.error && t.error !== !0 ? (C(), T("p",
|
|
20417
|
+
t.error && t.error !== !0 ? (C(), T("p", dk, ee(typeof t.error == "string" ? t.error : t.error?.message || String(t.error)), 1)) : t.helpText ? (C(), T("p", uk, ee(t.helpText), 1)) : W("", !0)
|
|
20396
20418
|
], 2));
|
|
20397
20419
|
}
|
|
20398
|
-
}), wo = /* @__PURE__ */
|
|
20420
|
+
}), wo = /* @__PURE__ */ Oe(fk, [["__scopeId", "data-v-e216292d"]]), hk = ["disabled", "aria-disabled"], pk = ["href", "target", "rel", "aria-disabled"], mk = /* @__PURE__ */ ae({
|
|
20399
20421
|
__name: "UiLink",
|
|
20400
20422
|
props: {
|
|
20401
20423
|
href: {},
|
|
@@ -20468,7 +20490,7 @@ const ok = ["for"], lk = {
|
|
|
20468
20490
|
onClick: c
|
|
20469
20491
|
}, [
|
|
20470
20492
|
E(d.$slots, "default", {}, void 0, !0)
|
|
20471
|
-
], 14,
|
|
20493
|
+
], 14, hk)) : (C(), T("a", {
|
|
20472
20494
|
key: 1,
|
|
20473
20495
|
class: X(["ui-link", [
|
|
20474
20496
|
`ui-link-${n.variant}`,
|
|
@@ -20484,9 +20506,9 @@ const ok = ["for"], lk = {
|
|
|
20484
20506
|
onClick: c
|
|
20485
20507
|
}, [
|
|
20486
20508
|
E(d.$slots, "default", {}, void 0, !0)
|
|
20487
|
-
], 14,
|
|
20509
|
+
], 14, pk));
|
|
20488
20510
|
}
|
|
20489
|
-
}), Dd = /* @__PURE__ */
|
|
20511
|
+
}), Dd = /* @__PURE__ */ Oe(mk, [["__scopeId", "data-v-3bf99110"]]), gk = {
|
|
20490
20512
|
StrandsUiAlert: na,
|
|
20491
20513
|
StrandsUiButton: re,
|
|
20492
20514
|
StrandsUiCard: ra,
|
|
@@ -20494,15 +20516,15 @@ const ok = ["for"], lk = {
|
|
|
20494
20516
|
StrandsUiLink: Dd,
|
|
20495
20517
|
StrandsUiTabs: zs,
|
|
20496
20518
|
StrandsUiLoader: $s
|
|
20497
|
-
},
|
|
20519
|
+
}, yk = {
|
|
20498
20520
|
install(n, e = {}) {
|
|
20499
20521
|
const { prefix: t = "" } = e;
|
|
20500
|
-
Object.entries(
|
|
20522
|
+
Object.entries(gk).forEach(([r, i]) => {
|
|
20501
20523
|
const s = t ? `${t}${r}` : r;
|
|
20502
20524
|
n.component(s, i);
|
|
20503
20525
|
});
|
|
20504
20526
|
}
|
|
20505
|
-
},
|
|
20527
|
+
}, vk = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
20506
20528
|
__proto__: null,
|
|
20507
20529
|
StrandsUiAlert: na,
|
|
20508
20530
|
StrandsUiButton: re,
|
|
@@ -20511,14 +20533,14 @@ const ok = ["for"], lk = {
|
|
|
20511
20533
|
StrandsUiLink: Dd,
|
|
20512
20534
|
StrandsUiLoader: $s,
|
|
20513
20535
|
StrandsUiTabs: zs,
|
|
20514
|
-
default:
|
|
20536
|
+
default: yk
|
|
20515
20537
|
}, Symbol.toStringTag, { value: "Module" }));
|
|
20516
20538
|
export {
|
|
20517
20539
|
Rs as C,
|
|
20518
20540
|
rf as M,
|
|
20519
20541
|
re as S,
|
|
20520
20542
|
Sr as U,
|
|
20521
|
-
|
|
20543
|
+
Oe as _,
|
|
20522
20544
|
Eo as a,
|
|
20523
20545
|
Ao as b,
|
|
20524
20546
|
oe as c,
|
|
@@ -20530,7 +20552,7 @@ export {
|
|
|
20530
20552
|
zs as i,
|
|
20531
20553
|
Dd as j,
|
|
20532
20554
|
na as k,
|
|
20533
|
-
|
|
20534
|
-
|
|
20555
|
+
yk as l,
|
|
20556
|
+
vk as m,
|
|
20535
20557
|
Ps as u
|
|
20536
20558
|
};
|