hexagon-editor 0.1.4 → 0.1.6
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/README.md +24 -11
- package/dist/MarkdownEditor.vue.d.ts +28 -26
- package/dist/MarkdownEditor.vue.d.ts.map +1 -1
- package/dist/{MarkdownEditorLinkForm-C7CGgA83.js → MarkdownEditorLinkForm-B9dEX3WT.js} +1 -1
- package/dist/{base-Bnv2-Te4.js → base-BPdMUtQo.js} +141 -137
- package/dist/components/MarkdownEditorToolbar.vue.d.ts +4 -3
- package/dist/components/MarkdownEditorToolbar.vue.d.ts.map +1 -1
- package/dist/configure.d.ts +0 -2
- package/dist/configure.d.ts.map +1 -1
- package/dist/configure.js +11 -12
- package/dist/core/basic-editor-markdown.d.ts.map +1 -1
- package/dist/core/basic-editor-renderers.d.ts +6 -4
- package/dist/core/basic-editor-renderers.d.ts.map +1 -1
- package/dist/core/basic-editor-types.d.ts +2 -0
- package/dist/core/basic-editor-types.d.ts.map +1 -1
- package/dist/core/basic-editor.d.ts +1 -1
- package/dist/core/basic-editor.d.ts.map +1 -1
- package/dist/core/index.d.ts +0 -2
- package/dist/core/index.d.ts.map +1 -1
- package/dist/core/markup-editor.d.ts.map +1 -1
- package/dist/core.js +28 -31
- package/dist/extensions.js +1 -1
- package/dist/forms/MarkdownEditorImageForm.vue.d.ts +2 -2
- package/dist/forms/MarkdownEditorImageForm.vue.d.ts.map +1 -1
- package/dist/forms/MarkdownEditorLinkForm.vue.d.ts +2 -2
- package/dist/forms/MarkdownEditorTextInput.vue.d.ts +2 -2
- package/dist/forms/MarkdownEditorTextInput.vue.d.ts.map +1 -1
- package/dist/forms.js +1 -1
- package/dist/{full-C-o2lPBX.js → full-Da8esvj2.js} +1 -1
- package/dist/{full-specs-Cl-ODShc.js → full-specs-hXKoMF-0.js} +1 -1
- package/dist/index-D_CMntQU.js +3173 -0
- package/dist/index.css +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +3611 -1284
- package/dist/{markup-commands-BckOOKIe.js → markup-commands-BYsx8ADT.js} +1993 -1963
- package/dist/presets.js +2 -2
- package/dist/public-types.d.ts +22 -0
- package/dist/public-types.d.ts.map +1 -1
- package/dist/renderer/MarkdownRenderer.vue.d.ts +2 -0
- package/dist/renderer/MarkdownRenderer.vue.d.ts.map +1 -1
- package/dist/renderer/markdown.d.ts +2 -1
- package/dist/renderer/markdown.d.ts.map +1 -1
- package/dist/renderer.css +1 -1
- package/dist/renderer.js +142 -146
- package/package.json +106 -108
- package/dist/MarkdownEditorLinkForm.css +0 -1
- package/dist/abnfDiagram-N423BO3Z-DCf6sPky.js +0 -87
- package/dist/arc-y6UeoJpJ.js +0 -83
- package/dist/architectureDiagram-T3A2C74G-Cc3_3-cI.js +0 -4778
- package/dist/base.css +0 -1
- package/dist/blockDiagram-VBNYF7ZC-DWVLZwXY.js +0 -2419
- package/dist/c4Diagram-5PPSVZJV-CaIN7qay.js +0 -1577
- package/dist/channel-BwXGcavV.js +0 -5
- package/dist/chunk-2GRJ4B5K-O75udjPr.js +0 -68
- package/dist/chunk-2Q5K7J3B-CySL0lOA.js +0 -15
- package/dist/chunk-5RXB4S5H-BKPnLCOJ.js +0 -1408
- package/dist/chunk-5VM5RSS4--it1VJIv.js +0 -19
- package/dist/chunk-6Q2QTUOP-DNiML-50.js +0 -664
- package/dist/chunk-GF5L2VYU-z7A-k0-V.js +0 -1533
- package/dist/chunk-JWPE2WC7-DAjx3Kjr.js +0 -8
- package/dist/chunk-KBJHAD2P-D4R1VW0r.js +0 -19
- package/dist/chunk-RYQCIY6F-DmJAYxq8.js +0 -313
- package/dist/chunk-XXDRQBXY-CK913N-t.js +0 -8
- package/dist/classDiagram-JCYQIIEL-Djipq_HJ.js +0 -16
- package/dist/classDiagram-v2-OCEON4UE-Djipq_HJ.js +0 -16
- package/dist/core/optional-renderers.d.ts +0 -9
- package/dist/core/optional-renderers.d.ts.map +0 -1
- package/dist/cose-bilkent-JH36ORCC-CXuKFbXy.js +0 -2608
- package/dist/cynefin-VYW2F7L2-Bkk-F_Js.js +0 -23766
- package/dist/cynefinDiagram-MW4NZA55-DwOK40hm.js +0 -299
- package/dist/cytoscape.esm-3W4EOjxC.js +0 -18756
- package/dist/dagre-VZM6K2ZE-0VsGm8Ag.js +0 -340
- package/dist/defaultLocale-BgPVtth8.js +0 -171
- package/dist/diagram-7IWD3JNH-BrApu1hz.js +0 -350
- package/dist/diagram-B4RE2ZJO-CVXoBg2r.js +0 -461
- package/dist/diagram-LBJQPF4R-Dp0eSz2L.js +0 -142
- package/dist/diagram-Q27KOJAE-DWIltqIH.js +0 -528
- package/dist/diagram-UB23O5K3-B7z2Lj3K.js +0 -219
- package/dist/ebnfDiagram-BXEA7PRR-CYgE6z_2.js +0 -109
- package/dist/erDiagram-JOGREHBK-D3QWrPo-.js +0 -910
- package/dist/flowDiagram-UKHOOZJN-CfjPcHNW.js +0 -1638
- package/dist/ganttDiagram-PKOTCBZU-ECmaWI-9.js +0 -2711
- package/dist/gitGraphDiagram-DS77QQ5N-DgG1RGJ8.js +0 -815
- package/dist/graph-DAHC4kPm.js +0 -1545
- package/dist/infoDiagram-6WML65LV-B1Yl3nZV.js +0 -24
- package/dist/init-DjUOC4st.js +0 -16
- package/dist/ishikawaDiagram-WSZJBQD7-4sngaB5o.js +0 -621
- package/dist/journeyDiagram-NVQOT4AX-B_6AmR_j.js +0 -834
- package/dist/kanban-definition-27J2QSJJ-B8BO9o8J.js +0 -724
- package/dist/katex-ByXcxnHy.js +0 -14436
- package/dist/katex-DoRnZ_sp.js +0 -11682
- package/dist/layout-DBbo_M5I.js +0 -1519
- package/dist/linear-BEdRfKba.js +0 -259
- package/dist/map-DRdzG8Ho.js +0 -224
- package/dist/markup-commands.css +0 -1
- package/dist/mermaid.core-CR0bA2Wa.js +0 -16496
- package/dist/mindmap-definition-FAOFIHXS-DnPz807N.js +0 -827
- package/dist/optional-renderers-BalvqqvY.js +0 -11
- package/dist/ordinal-B6-f3MAq.js +0 -61
- package/dist/pegDiagram-VL7TDLO6-csGWlzs8.js +0 -95
- package/dist/pieDiagram-7S7Q4E2Y-Bqs8j5FX.js +0 -207
- package/dist/quadrantDiagram-CIZ2JOQS-jzP4lRrY.js +0 -1023
- package/dist/railroadDiagram-AXF67PYL-BSCyR24u.js +0 -77
- package/dist/renderer/mermaid-runtime.d.ts +0 -4
- package/dist/renderer/mermaid-runtime.d.ts.map +0 -1
- package/dist/requirementDiagram-LRYGKXZP-DmEkLYqX.js +0 -882
- package/dist/sankeyDiagram-W5VNT64P-CYvRYMTh.js +0 -847
- package/dist/sequenceDiagram-SI44F4Z6-CyWbDtPA.js +0 -2888
- package/dist/sizeCapture-X5ZJPWSS-xKhYCY84.js +0 -46
- package/dist/stateDiagram-OKZ733FA-DP44R2Dd.js +0 -263
- package/dist/stateDiagram-v2-UEYNNEHI-BvlOisND.js +0 -16
- package/dist/swimlanes-SLNWSIFB-BKFp8twH.js +0 -5332
- package/dist/swimlanesDiagram-ULZ7WXOC-CTvIFuHq.js +0 -13
- package/dist/timeline-definition-Z64GVDOM-B4137uIl.js +0 -1055
- package/dist/vennDiagram-T6HMQDX7-CPs8gXjx.js +0 -1578
- package/dist/wardleyDiagram-T6FBY63Y-BYp13hbI.js +0 -675
- package/dist/xychartDiagram-ELKLHX3M-DTT37K2u.js +0 -1388
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { B as Da, o as fi, b as Ea, r as Aa, d as Ia, c as Wi, f as va, y as Ra, e as Pa, v as Gn, C as di, h as Ba, g as hr, i as za, R as La, S as ks, j as
|
|
1
|
+
import { B as Da, o as fi, b as Ea, r as Aa, d as Ia, c as Wi, f as va, y as Ra, e as Pa, v as Gn, C as di, h as Ba, g as hr, i as za, R as La, S as ks, j as $a, W as Va, k as Fa, L as fe, Z as Wa, m as z, l as xs, T as ui, n as Ka, H as Ha, O as _a, M as Fr } from "./heading-specs-D7Bj4aIM.js";
|
|
2
2
|
import { i as qa, s as Ja, a as ja } from "./index-CqpK5VVw.js";
|
|
3
3
|
import { reactive as Ss, h as Ki, render as Hi } from "vue";
|
|
4
|
-
|
|
4
|
+
function F(n) {
|
|
5
5
|
this.content = n;
|
|
6
6
|
}
|
|
7
7
|
F.prototype = {
|
|
@@ -1802,7 +1802,7 @@ function Ls(n, e) {
|
|
|
1802
1802
|
t[r] = new cc(n, r, e[r]);
|
|
1803
1803
|
return t;
|
|
1804
1804
|
}
|
|
1805
|
-
let ji = class
|
|
1805
|
+
let ji = class $s {
|
|
1806
1806
|
/**
|
|
1807
1807
|
@internal
|
|
1808
1808
|
*/
|
|
@@ -1970,7 +1970,7 @@ let ji = class Vs {
|
|
|
1970
1970
|
*/
|
|
1971
1971
|
static compile(e, t) {
|
|
1972
1972
|
let r = /* @__PURE__ */ Object.create(null);
|
|
1973
|
-
e.forEach((o, s) => r[o] = new
|
|
1973
|
+
e.forEach((o, s) => r[o] = new $s(o, t, s));
|
|
1974
1974
|
let i = t.spec.topNode || "doc";
|
|
1975
1975
|
if (!r[i])
|
|
1976
1976
|
throw new RangeError("Schema is missing its top node type ('" + i + "')");
|
|
@@ -2258,7 +2258,7 @@ class Xt {
|
|
|
2258
2258
|
return e.cached.domParser || (e.cached.domParser = new Xt(e, Xt.schemaRules(e)));
|
|
2259
2259
|
}
|
|
2260
2260
|
}
|
|
2261
|
-
const
|
|
2261
|
+
const Vs = {
|
|
2262
2262
|
address: !0,
|
|
2263
2263
|
article: !0,
|
|
2264
2264
|
aside: !0,
|
|
@@ -2333,7 +2333,7 @@ class gn {
|
|
|
2333
2333
|
return !e && this.match && (t = t.append(this.match.fillBefore(b.empty, !0))), this.type ? this.type.create(this.attrs, t, this.marks) : t;
|
|
2334
2334
|
}
|
|
2335
2335
|
inlineContext(e) {
|
|
2336
|
-
return this.type ? this.type.inlineContent : this.content.length ? this.content[0].isInline : e.parentNode &&
|
|
2336
|
+
return this.type ? this.type.inlineContent : this.content.length ? this.content[0].isInline : e.parentNode && !Vs.hasOwnProperty(e.parentNode.nodeName.toLowerCase());
|
|
2337
2337
|
}
|
|
2338
2338
|
}
|
|
2339
2339
|
class Yi {
|
|
@@ -2386,7 +2386,7 @@ class Yi {
|
|
|
2386
2386
|
else if (!a || a.skip || a.closeParent) {
|
|
2387
2387
|
a && a.closeParent ? this.open = Math.max(0, this.open - 1) : a && a.skip.nodeType && (e = a.skip);
|
|
2388
2388
|
let c, f = this.needsBlock;
|
|
2389
|
-
if (
|
|
2389
|
+
if (Vs.hasOwnProperty(s))
|
|
2390
2390
|
o.content.length && o.content[0].isInline && this.open && (this.open--, o = this.top), c = !0, o.type || (this.needsBlock = !0);
|
|
2391
2391
|
else if (!e.firstChild) {
|
|
2392
2392
|
this.leafFallback(e, t);
|
|
@@ -3321,7 +3321,7 @@ class ut extends j {
|
|
|
3321
3321
|
}
|
|
3322
3322
|
}
|
|
3323
3323
|
j.jsonID("removeNodeMark", ut);
|
|
3324
|
-
class
|
|
3324
|
+
class $ extends j {
|
|
3325
3325
|
/**
|
|
3326
3326
|
The given `slice` should fit the 'gap' between `from` and
|
|
3327
3327
|
`to`—the depths must line up, and the surrounding nodes must be
|
|
@@ -3341,21 +3341,21 @@ class V extends j {
|
|
|
3341
3341
|
return new Z([this.from, this.to - this.from, this.slice.size]);
|
|
3342
3342
|
}
|
|
3343
3343
|
invert(e) {
|
|
3344
|
-
return new
|
|
3344
|
+
return new $(this.from, this.from + this.slice.size, e.slice(this.from, this.to));
|
|
3345
3345
|
}
|
|
3346
3346
|
map(e) {
|
|
3347
|
-
let t = e.mapResult(this.to, -1), r = this.from == this.to &&
|
|
3348
|
-
return r.deletedAcross && t.deletedAcross ? null : new
|
|
3347
|
+
let t = e.mapResult(this.to, -1), r = this.from == this.to && $.MAP_BIAS < 0 ? t : e.mapResult(this.from, 1);
|
|
3348
|
+
return r.deletedAcross && t.deletedAcross ? null : new $(r.pos, Math.max(r.pos, t.pos), this.slice, this.structure);
|
|
3349
3349
|
}
|
|
3350
3350
|
merge(e) {
|
|
3351
|
-
if (!(e instanceof
|
|
3351
|
+
if (!(e instanceof $) || e.structure || this.structure)
|
|
3352
3352
|
return null;
|
|
3353
3353
|
if (this.from + this.slice.size == e.from && !this.slice.openEnd && !e.slice.openStart) {
|
|
3354
3354
|
let t = this.slice.size + e.slice.size == 0 ? x.empty : new x(this.slice.content.append(e.slice.content), this.slice.openStart, e.slice.openEnd);
|
|
3355
|
-
return new
|
|
3355
|
+
return new $(this.from, this.to + (e.to - e.from), t, this.structure);
|
|
3356
3356
|
} else if (e.to == this.from && !this.slice.openStart && !e.slice.openEnd) {
|
|
3357
3357
|
let t = this.slice.size + e.slice.size == 0 ? x.empty : new x(e.slice.content.append(this.slice.content), e.slice.openStart, this.slice.openEnd);
|
|
3358
|
-
return new
|
|
3358
|
+
return new $(e.from, this.to, t, this.structure);
|
|
3359
3359
|
} else
|
|
3360
3360
|
return null;
|
|
3361
3361
|
}
|
|
@@ -3369,11 +3369,11 @@ class V extends j {
|
|
|
3369
3369
|
static fromJSON(e, t) {
|
|
3370
3370
|
if (typeof t.from != "number" || typeof t.to != "number")
|
|
3371
3371
|
throw new RangeError("Invalid input for ReplaceStep.fromJSON");
|
|
3372
|
-
return new
|
|
3372
|
+
return new $(t.from, t.to, x.fromJSON(e, t.slice), !!t.structure);
|
|
3373
3373
|
}
|
|
3374
3374
|
}
|
|
3375
|
-
|
|
3376
|
-
j.jsonID("replace",
|
|
3375
|
+
$.MAP_BIAS = 1;
|
|
3376
|
+
j.jsonID("replace", $);
|
|
3377
3377
|
class _ extends j {
|
|
3378
3378
|
/**
|
|
3379
3379
|
Create a replace-around step with the given range and gap.
|
|
@@ -3490,7 +3490,7 @@ function pi(n, e, t, r = t.contentMatch, i = !0) {
|
|
|
3490
3490
|
for (let a = 0; a < o.childCount; a++) {
|
|
3491
3491
|
let c = o.child(a), f = l + c.nodeSize, d = r.matchType(c.type);
|
|
3492
3492
|
if (!d)
|
|
3493
|
-
s.push(new
|
|
3493
|
+
s.push(new $(l, f, x.empty));
|
|
3494
3494
|
else {
|
|
3495
3495
|
r = d;
|
|
3496
3496
|
for (let u = 0; u < c.marks.length; u++)
|
|
@@ -3498,7 +3498,7 @@ function pi(n, e, t, r = t.contentMatch, i = !0) {
|
|
|
3498
3498
|
if (i && c.isText && t.whitespace != "pre") {
|
|
3499
3499
|
let u, h = /\r?\n|\r/g, p;
|
|
3500
3500
|
for (; u = h.exec(c.text); )
|
|
3501
|
-
p || (p = new x(b.from(t.schema.text(" ", t.allowedMarks(c.marks))), 0, 0)), s.push(new
|
|
3501
|
+
p || (p = new x(b.from(t.schema.text(" ", t.allowedMarks(c.marks))), 0, 0)), s.push(new $(l + u.index, l + u.index + u[0].length, p));
|
|
3502
3502
|
}
|
|
3503
3503
|
}
|
|
3504
3504
|
l = f;
|
|
@@ -3648,7 +3648,7 @@ function Ec(n, e, t = 1, r) {
|
|
|
3648
3648
|
let f = r && r[c];
|
|
3649
3649
|
s = b.from(f ? f.type.create(f.attrs, s) : i.node(l).copy(s));
|
|
3650
3650
|
}
|
|
3651
|
-
n.step(new
|
|
3651
|
+
n.step(new $(e, e, new x(o.append(s), t, t), !0));
|
|
3652
3652
|
}
|
|
3653
3653
|
function Xn(n, e) {
|
|
3654
3654
|
let t = n.resolve(e), r = t.index();
|
|
@@ -3680,7 +3680,7 @@ function vc(n, e, t) {
|
|
|
3680
3680
|
}
|
|
3681
3681
|
s.inlineContent && pi(n, e + t - 1, s, o.node().contentMatchAt(o.index()), r == null);
|
|
3682
3682
|
let a = n.mapping.slice(l), c = a.map(e - t);
|
|
3683
|
-
if (n.step(new
|
|
3683
|
+
if (n.step(new $(c, a.map(e + t, -1), x.empty, !0)), r === !0) {
|
|
3684
3684
|
let f = n.doc.resolve(c);
|
|
3685
3685
|
Js(n, f.node(), f.before(), n.steps.length);
|
|
3686
3686
|
}
|
|
@@ -3733,7 +3733,7 @@ function gi(n, e, t = e, r = x.empty) {
|
|
|
3733
3733
|
if (e == t && !r.size)
|
|
3734
3734
|
return null;
|
|
3735
3735
|
let i = n.resolve(e), o = n.resolve(t);
|
|
3736
|
-
return Gs(i, o, r) ? new
|
|
3736
|
+
return Gs(i, o, r) ? new $(e, t, r) : new Pc(i, o, r).fit();
|
|
3737
3737
|
}
|
|
3738
3738
|
function Gs(n, e, t) {
|
|
3739
3739
|
return !t.openStart && !t.openEnd && n.start() == e.start() && n.parent.canReplace(n.index(), e.index(), t.content);
|
|
@@ -3766,7 +3766,7 @@ class Pc {
|
|
|
3766
3766
|
for (; s && l && o.childCount == 1; )
|
|
3767
3767
|
o = o.firstChild.content, s--, l--;
|
|
3768
3768
|
let a = new x(o, s, l);
|
|
3769
|
-
return e > -1 ? new _(r.pos, e, this.$to.pos, this.$to.end(), a, t) : a.size || r.pos != this.$to.pos ? new
|
|
3769
|
+
return e > -1 ? new _(r.pos, e, this.$to.pos, this.$to.end(), a, t) : a.size || r.pos != this.$to.pos ? new $(r.pos, i.pos, a) : null;
|
|
3770
3770
|
}
|
|
3771
3771
|
// Find a position on the start spine of `this.unplaced` that has
|
|
3772
3772
|
// content that can be moved somewhere on the frontier. Returns two
|
|
@@ -3923,7 +3923,7 @@ function Lc(n, e, t, r) {
|
|
|
3923
3923
|
return n.deleteRange(e, t);
|
|
3924
3924
|
let i = n.doc.resolve(e), o = n.doc.resolve(t);
|
|
3925
3925
|
if (Gs(i, o, r))
|
|
3926
|
-
return n.step(new
|
|
3926
|
+
return n.step(new $(e, t, r));
|
|
3927
3927
|
let s = Qs(i, o);
|
|
3928
3928
|
s[s.length - 1] == 0 && s.pop();
|
|
3929
3929
|
let l = -(i.depth + 1);
|
|
@@ -3976,14 +3976,14 @@ function Xs(n, e, t, r, i) {
|
|
|
3976
3976
|
}
|
|
3977
3977
|
return n;
|
|
3978
3978
|
}
|
|
3979
|
-
function
|
|
3979
|
+
function $c(n, e, t, r) {
|
|
3980
3980
|
if (!r.isInline && e == t && n.doc.resolve(e).parent.content.size) {
|
|
3981
3981
|
let i = Rc(n.doc, e, r.type);
|
|
3982
3982
|
i != null && (e = t = i);
|
|
3983
3983
|
}
|
|
3984
3984
|
n.replaceRange(e, t, new x(b.from(r), 0, 0));
|
|
3985
3985
|
}
|
|
3986
|
-
function
|
|
3986
|
+
function Vc(n, e, t) {
|
|
3987
3987
|
let r = n.doc.resolve(e), i = n.doc.resolve(t);
|
|
3988
3988
|
if (r.parent.isTextblock && i.parent.isTextblock && r.start() != i.start() && r.parentOffset == 0 && i.parentOffset == 0) {
|
|
3989
3989
|
let s = r.sharedDepth(t), l = !1;
|
|
@@ -4222,14 +4222,14 @@ class Fc {
|
|
|
4222
4222
|
that parent node.
|
|
4223
4223
|
*/
|
|
4224
4224
|
replaceRangeWith(e, t, r) {
|
|
4225
|
-
return
|
|
4225
|
+
return $c(this, e, t, r), this;
|
|
4226
4226
|
}
|
|
4227
4227
|
/**
|
|
4228
4228
|
Delete the given range, expanding it to cover fully covered
|
|
4229
4229
|
parent nodes until a valid replace is found.
|
|
4230
4230
|
*/
|
|
4231
4231
|
deleteRange(e, t) {
|
|
4232
|
-
return
|
|
4232
|
+
return Vc(this, e, t), this;
|
|
4233
4233
|
}
|
|
4234
4234
|
/**
|
|
4235
4235
|
Split the content in the given range off from its parent, if there
|
|
@@ -4732,7 +4732,7 @@ function oo(n, e, t) {
|
|
|
4732
4732
|
if (r < e)
|
|
4733
4733
|
return;
|
|
4734
4734
|
let i = n.steps[r];
|
|
4735
|
-
if (!(i instanceof
|
|
4735
|
+
if (!(i instanceof $ || i instanceof _))
|
|
4736
4736
|
return;
|
|
4737
4737
|
let o = n.mapping.maps[r], s;
|
|
4738
4738
|
o.forEach((l, a, c, f) => {
|
|
@@ -5857,7 +5857,7 @@ function Nf(n, e, t) {
|
|
|
5857
5857
|
return { node: r.startContainer, offset: Math.min(ie(r.startContainer), r.startOffset) };
|
|
5858
5858
|
}
|
|
5859
5859
|
}
|
|
5860
|
-
const me = typeof navigator < "u" ? navigator : null, uo = typeof document < "u" ? document : null, je = me && me.userAgent || "", Ur = /Edge\/(\d+)/.exec(je), ul = /MSIE \d/.exec(je), Gr = /Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(je), X = !!(ul || Gr || Ur),
|
|
5860
|
+
const me = typeof navigator < "u" ? navigator : null, uo = typeof document < "u" ? document : null, je = me && me.userAgent || "", Ur = /Edge\/(\d+)/.exec(je), ul = /MSIE \d/.exec(je), Gr = /Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(je), X = !!(ul || Gr || Ur), $e = ul ? document.documentMode : Gr ? +Gr[1] : Ur ? +Ur[1] : 0, oe = !X && /gecko\/(\d+)/i.test(je);
|
|
5861
5861
|
oe && +(/Firefox\/(\d+)/.exec(je) || [0, 0])[1];
|
|
5862
5862
|
const Yr = !X && /Chrome\/(\d+)/.exec(je), H = !!Yr, hl = Yr ? +Yr[1] : 0, J = !X && !!me && /Apple Computer/.test(me.vendor), Rt = J && (/Mobile\/\w+/.test(je) || !!me && me.maxTouchPoints > 2), re = Rt || (me ? /Mac/.test(me.platform) : !1), pl = me ? /Win/.test(me.platform) : !1, Se = /Android \d/.test(je), dn = !!uo && "webkitFontSmoothing" in uo.documentElement.style, Df = dn ? +(/\bAppleWebKit\/(\d+)/.exec(navigator.userAgent) || [0, 0])[1] : 0;
|
|
5863
5863
|
function Ef(n) {
|
|
@@ -6040,7 +6040,7 @@ function bl(n, e, t) {
|
|
|
6040
6040
|
}
|
|
6041
6041
|
return n;
|
|
6042
6042
|
}
|
|
6043
|
-
function
|
|
6043
|
+
function $f(n, e) {
|
|
6044
6044
|
let t = n.dom.ownerDocument, r, i = 0, o = Nf(t, e.left, e.top);
|
|
6045
6045
|
o && ({ node: r, offset: i } = o);
|
|
6046
6046
|
let s = (n.root.elementFromPoint ? n.root : t).elementFromPoint(e.left, e.top), l;
|
|
@@ -6076,24 +6076,24 @@ function Ee(n, e) {
|
|
|
6076
6076
|
}
|
|
6077
6077
|
return Array.prototype.find.call(t, Xr) || n.getBoundingClientRect();
|
|
6078
6078
|
}
|
|
6079
|
-
const
|
|
6079
|
+
const Vf = /[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac]/;
|
|
6080
6080
|
function kl(n, e, t) {
|
|
6081
6081
|
let { node: r, offset: i, atom: o } = n.docView.domFromPos(e, t < 0 ? -1 : 1), s = dn || oe;
|
|
6082
6082
|
if (r.nodeType == 3)
|
|
6083
|
-
if (s && (
|
|
6083
|
+
if (s && (Vf.test(r.nodeValue) || (t < 0 ? !i : i == r.nodeValue.length))) {
|
|
6084
6084
|
let a = Ee(ke(r, i, i), t);
|
|
6085
6085
|
if (oe && i && /\s/.test(r.nodeValue[i - 1]) && i < r.nodeValue.length) {
|
|
6086
6086
|
let c = Ee(ke(r, i - 1, i - 1), -1);
|
|
6087
6087
|
if (c.top == a.top) {
|
|
6088
6088
|
let f = Ee(ke(r, i, i + 1), -1);
|
|
6089
6089
|
if (f.top != a.top)
|
|
6090
|
-
return
|
|
6090
|
+
return Vt(f, f.left < c.left);
|
|
6091
6091
|
}
|
|
6092
6092
|
}
|
|
6093
6093
|
return a;
|
|
6094
6094
|
} else {
|
|
6095
6095
|
let a = i, c = i, f = t < 0 ? 1 : -1;
|
|
6096
|
-
return t < 0 && !i ? (c++, f = -1) : t >= 0 && i == r.nodeValue.length ? (a--, f = 1) : t < 0 ? a-- : c++,
|
|
6096
|
+
return t < 0 && !i ? (c++, f = -1) : t >= 0 && i == r.nodeValue.length ? (a--, f = 1) : t < 0 ? a-- : c++, Vt(Ee(ke(r, a, c), f), f < 0);
|
|
6097
6097
|
}
|
|
6098
6098
|
if (!n.state.doc.resolve(e - (o || 0)).parent.inlineContent) {
|
|
6099
6099
|
if (o == null && i && (t < 0 || i == ie(r))) {
|
|
@@ -6111,7 +6111,7 @@ function kl(n, e, t) {
|
|
|
6111
6111
|
if (o == null && i && (t < 0 || i == ie(r))) {
|
|
6112
6112
|
let a = r.childNodes[i - 1], c = a.nodeType == 3 ? ke(a, ie(a) - (s ? 0 : 1)) : a.nodeType == 1 && (a.nodeName != "BR" || !a.nextSibling) ? a : null;
|
|
6113
6113
|
if (c)
|
|
6114
|
-
return
|
|
6114
|
+
return Vt(Ee(c, 1), !1);
|
|
6115
6115
|
}
|
|
6116
6116
|
if (o == null && i < ie(r)) {
|
|
6117
6117
|
let a = r.childNodes[i];
|
|
@@ -6119,11 +6119,11 @@ function kl(n, e, t) {
|
|
|
6119
6119
|
a = a.nextSibling;
|
|
6120
6120
|
let c = a ? a.nodeType == 3 ? ke(a, 0, s ? 0 : 1) : a.nodeType == 1 ? a : null : null;
|
|
6121
6121
|
if (c)
|
|
6122
|
-
return
|
|
6122
|
+
return Vt(Ee(c, -1), !0);
|
|
6123
6123
|
}
|
|
6124
|
-
return
|
|
6124
|
+
return Vt(Ee(r.nodeType == 3 ? ke(r) : r, -t), t >= 0);
|
|
6125
6125
|
}
|
|
6126
|
-
function
|
|
6126
|
+
function Vt(n, e) {
|
|
6127
6127
|
if (n.width == 0)
|
|
6128
6128
|
return n;
|
|
6129
6129
|
let t = e ? n.left : n.right;
|
|
@@ -6602,13 +6602,13 @@ class _f extends un {
|
|
|
6602
6602
|
return e.type === "characterData" && e.target.nodeValue == e.oldValue;
|
|
6603
6603
|
}
|
|
6604
6604
|
}
|
|
6605
|
-
class
|
|
6605
|
+
class Ve extends un {
|
|
6606
6606
|
constructor(e, t, r, i, o) {
|
|
6607
6607
|
super(e, [], r, i), this.mark = t, this.spec = o;
|
|
6608
6608
|
}
|
|
6609
6609
|
static create(e, t, r, i) {
|
|
6610
6610
|
let o = i.nodeViews[t.type.name], s = o && o(t, i, r);
|
|
6611
|
-
return (!s || !s.dom) && (s = yt.renderSpec(document, t.type.spec.toDOM(t, r), null, t.attrs)), new
|
|
6611
|
+
return (!s || !s.dom) && (s = yt.renderSpec(document, t.type.spec.toDOM(t, r), null, t.attrs)), new Ve(e, t, s.dom, s.contentDOM || s.dom, s);
|
|
6612
6612
|
}
|
|
6613
6613
|
parseRule() {
|
|
6614
6614
|
return this.dirty & de || this.mark.type.spec.reparseInView ? null : { mark: this.mark.type.name, attrs: this.mark.attrs, contentElement: this.contentDOM };
|
|
@@ -6625,7 +6625,7 @@ class $e extends un {
|
|
|
6625
6625
|
}
|
|
6626
6626
|
}
|
|
6627
6627
|
slice(e, t, r) {
|
|
6628
|
-
let i =
|
|
6628
|
+
let i = Ve.create(this.parent, this.mark, !0, r), o = this.children, s = this.size;
|
|
6629
6629
|
t < s && (o = Zr(o, t, s, r)), e > 0 && (o = Zr(o, 0, e, r));
|
|
6630
6630
|
for (let l = 0; l < o.length; l++)
|
|
6631
6631
|
o[l].parent = i;
|
|
@@ -6873,7 +6873,7 @@ function Cl(n, e, t) {
|
|
|
6873
6873
|
r = r.nextSibling;
|
|
6874
6874
|
} else
|
|
6875
6875
|
i = !0, n.insertBefore(l, r);
|
|
6876
|
-
if (s instanceof
|
|
6876
|
+
if (s instanceof Ve) {
|
|
6877
6877
|
let a = r ? r.previousSibling : n.lastChild;
|
|
6878
6878
|
Cl(s.contentDOM, s.children, t), r = a ? a.nextSibling : n.firstChild;
|
|
6879
6879
|
}
|
|
@@ -6992,12 +6992,12 @@ class jf {
|
|
|
6992
6992
|
}
|
|
6993
6993
|
if (a < 0 && this.index < this.top.children.length) {
|
|
6994
6994
|
let f = this.top.children[this.index];
|
|
6995
|
-
f instanceof
|
|
6995
|
+
f instanceof Ve && f.dirty != de && f.mark.type == e[s].type && f.spec.update && !this.isLocked(f.dom) && f.spec.update(e[s]) && (f.mark = e[s], a = this.index, this.changed = !0);
|
|
6996
6996
|
}
|
|
6997
6997
|
if (a > -1)
|
|
6998
6998
|
a > this.index && (this.changed = !0, this.destroyBetween(this.index, a)), this.top = this.top.children[this.index];
|
|
6999
6999
|
else {
|
|
7000
|
-
let f =
|
|
7000
|
+
let f = Ve.create(this.top, e[s], t, r);
|
|
7001
7001
|
this.top.children.splice(this.index, 0, f), this.top = f, this.changed = !0;
|
|
7002
7002
|
}
|
|
7003
7003
|
this.index = 0, s++;
|
|
@@ -7090,7 +7090,7 @@ class jf {
|
|
|
7090
7090
|
// contentEditable.
|
|
7091
7091
|
addTextblockHacks() {
|
|
7092
7092
|
let e = this.top.children[this.index - 1], t = this.top;
|
|
7093
|
-
for (; e instanceof
|
|
7093
|
+
for (; e instanceof Ve; )
|
|
7094
7094
|
t = e, e = t.children[t.children.length - 1];
|
|
7095
7095
|
(!e || // Empty textblock
|
|
7096
7096
|
!(e instanceof nr) || /\n$/.test(e.node.text) || this.view.requiresGeckoHackNode && /\s$/.test(e.node.text)) && ((J || H) && e && e.dom.contentEditable == "false" && this.addHackNode("IMG", t), this.addHackNode("BR", this.top));
|
|
@@ -7116,7 +7116,7 @@ function Uf(n, e) {
|
|
|
7116
7116
|
for (; ; )
|
|
7117
7117
|
if (r) {
|
|
7118
7118
|
let c = t.children[r - 1];
|
|
7119
|
-
if (c instanceof
|
|
7119
|
+
if (c instanceof Ve)
|
|
7120
7120
|
t = c, r = c.children.length;
|
|
7121
7121
|
else {
|
|
7122
7122
|
l = c, r--;
|
|
@@ -7319,7 +7319,7 @@ function ed(n) {
|
|
|
7319
7319
|
if (!e)
|
|
7320
7320
|
return;
|
|
7321
7321
|
let t = n.cursorWrapper.dom, r = t.nodeName == "IMG";
|
|
7322
|
-
r ? e.collapse(t.parentNode, K(t) + 1) : e.collapse(t, 0), !r && !n.state.selection.visible && X &&
|
|
7322
|
+
r ? e.collapse(t.parentNode, K(t) + 1) : e.collapse(t, 0), !r && !n.state.selection.visible && X && $e <= 11 && (t.disabled = !0, t.disabled = !1);
|
|
7323
7323
|
}
|
|
7324
7324
|
function Nl(n, e) {
|
|
7325
7325
|
if (e instanceof w) {
|
|
@@ -7854,7 +7854,7 @@ function xd(n, e) {
|
|
|
7854
7854
|
}
|
|
7855
7855
|
G.keydown = (n, e) => {
|
|
7856
7856
|
let t = e;
|
|
7857
|
-
if (n.input.shiftKey = t.keyCode == 16 || t.shiftKey,
|
|
7857
|
+
if (n.input.shiftKey = t.keyCode == 16 || t.shiftKey, !Vl(n) && (n.input.lastKeyCode = t.keyCode, n.input.lastKeyCodeTime = Date.now(), !(Se && H && t.keyCode == 13)))
|
|
7858
7858
|
if (t.keyCode != 229 && n.domObserver.forceFlush(), Rt && t.keyCode == 13 && !t.ctrlKey && !t.altKey && !t.metaKey) {
|
|
7859
7859
|
let r = Date.now();
|
|
7860
7860
|
n.input.lastIOSEnter = r, n.input.lastIOSEnterFallbackTimeout = setTimeout(() => {
|
|
@@ -7867,7 +7867,7 @@ G.keyup = (n, e) => {
|
|
|
7867
7867
|
};
|
|
7868
7868
|
G.keypress = (n, e) => {
|
|
7869
7869
|
let t = e;
|
|
7870
|
-
if (
|
|
7870
|
+
if (Vl(n) || !t.charCode || t.ctrlKey && !t.altKey || re && t.metaKey)
|
|
7871
7871
|
return;
|
|
7872
7872
|
if (n.someProp("handleKeyPress", (i) => i(n, t))) {
|
|
7873
7873
|
t.preventDefault();
|
|
@@ -7963,7 +7963,7 @@ U.mousedown = (n, e) => {
|
|
|
7963
7963
|
let s = n.posAtCoords(hn(t));
|
|
7964
7964
|
s && (o == "singleClick" ? n.input.mouseDown = new Dd(n, s, t, !!r) : (o == "doubleClick" ? Od : Td)(n, s.pos, s.inside, t) ? t.preventDefault() : we(n, "pointer"));
|
|
7965
7965
|
};
|
|
7966
|
-
class
|
|
7966
|
+
class $l {
|
|
7967
7967
|
constructor(e) {
|
|
7968
7968
|
this.view = e, this.mightDrag = null, e.root.addEventListener("mouseup", this.up = this.up.bind(this)), e.root.addEventListener("mousemove", this.move = this.move.bind(this));
|
|
7969
7969
|
}
|
|
@@ -7980,7 +7980,7 @@ class Vl {
|
|
|
7980
7980
|
return !1;
|
|
7981
7981
|
}
|
|
7982
7982
|
}
|
|
7983
|
-
class Dd extends
|
|
7983
|
+
class Dd extends $l {
|
|
7984
7984
|
constructor(e, t, r, i) {
|
|
7985
7985
|
super(e), this.pos = t, this.event = r, this.flushed = i, this.delayedSelectionSync = !1, this.startDoc = e.state.doc, this.selectNode = !!r[Ll], this.allowDefault = r.shiftKey;
|
|
7986
7986
|
let o, s;
|
|
@@ -8031,7 +8031,7 @@ class Dd extends Vl {
|
|
|
8031
8031
|
return this.allowDefault ? (this.delayedSelectionSync = !0, !0) : !1;
|
|
8032
8032
|
}
|
|
8033
8033
|
}
|
|
8034
|
-
class Ed extends
|
|
8034
|
+
class Ed extends $l {
|
|
8035
8035
|
constructor(e, t) {
|
|
8036
8036
|
super(e), this.startSelection = t, this.startDoc = e.state.doc;
|
|
8037
8037
|
}
|
|
@@ -8055,7 +8055,7 @@ U.touchmove = (n) => {
|
|
|
8055
8055
|
n.input.lastTouch = Date.now(), we(n, "pointer");
|
|
8056
8056
|
};
|
|
8057
8057
|
U.contextmenu = (n) => Oi(n);
|
|
8058
|
-
function
|
|
8058
|
+
function Vl(n, e) {
|
|
8059
8059
|
return n.composing ? !0 : J && Math.abs(Date.now() - n.input.compositionEndedAt) < 500 ? (n.input.compositionEndedAt = -2e8, !0) : !1;
|
|
8060
8060
|
}
|
|
8061
8061
|
const Ad = Se ? 5e3 : -1;
|
|
@@ -8138,7 +8138,7 @@ function Rd(n, e) {
|
|
|
8138
8138
|
t.parentNode && t.parentNode.removeChild(t), n.focus();
|
|
8139
8139
|
}, 50);
|
|
8140
8140
|
}
|
|
8141
|
-
const nn = X &&
|
|
8141
|
+
const nn = X && $e < 15 || Rt && Df < 604;
|
|
8142
8142
|
U.copy = G.cut = (n, e) => {
|
|
8143
8143
|
let t = e, r = n.state.selection, i = t.type == "cut";
|
|
8144
8144
|
if (r.empty)
|
|
@@ -8295,7 +8295,7 @@ function on(n, e) {
|
|
|
8295
8295
|
return !1;
|
|
8296
8296
|
return !0;
|
|
8297
8297
|
}
|
|
8298
|
-
class
|
|
8298
|
+
class $n {
|
|
8299
8299
|
constructor(e, t) {
|
|
8300
8300
|
this.toDOM = e, this.spec = t || ot, this.side = this.spec.side || 0;
|
|
8301
8301
|
}
|
|
@@ -8307,7 +8307,7 @@ class Vn {
|
|
|
8307
8307
|
return !0;
|
|
8308
8308
|
}
|
|
8309
8309
|
eq(e) {
|
|
8310
|
-
return this == e || e instanceof
|
|
8310
|
+
return this == e || e instanceof $n && (this.spec.key && this.spec.key == e.spec.key || this.toDOM == e.toDOM && on(this.spec, e.spec));
|
|
8311
8311
|
}
|
|
8312
8312
|
destroy(e) {
|
|
8313
8313
|
this.spec.destroy && this.spec.destroy(e);
|
|
@@ -8388,7 +8388,7 @@ class I {
|
|
|
8388
8388
|
widget's current document position.
|
|
8389
8389
|
*/
|
|
8390
8390
|
static widget(e, t, r) {
|
|
8391
|
-
return new I(e, e, new
|
|
8391
|
+
return new I(e, e, new $n(t, r));
|
|
8392
8392
|
}
|
|
8393
8393
|
/**
|
|
8394
8394
|
Creates an inline decoration, which adds the given attributes to
|
|
@@ -8422,7 +8422,7 @@ class I {
|
|
|
8422
8422
|
@internal
|
|
8423
8423
|
*/
|
|
8424
8424
|
get widget() {
|
|
8425
|
-
return this.type instanceof
|
|
8425
|
+
return this.type instanceof $n;
|
|
8426
8426
|
}
|
|
8427
8427
|
}
|
|
8428
8428
|
const Ct = [], ot = {};
|
|
@@ -8439,7 +8439,7 @@ class D {
|
|
|
8439
8439
|
you must make a copy if you want need to preserve that.
|
|
8440
8440
|
*/
|
|
8441
8441
|
static create(e, t) {
|
|
8442
|
-
return t.length ?
|
|
8442
|
+
return t.length ? Vn(t, e, 0, ot) : q;
|
|
8443
8443
|
}
|
|
8444
8444
|
/**
|
|
8445
8445
|
Find all decorations in this set which touch the given range
|
|
@@ -8480,7 +8480,7 @@ class D {
|
|
|
8480
8480
|
let a = this.local[l].map(e, r, i);
|
|
8481
8481
|
a && a.type.valid(t, a) ? (s || (s = [])).push(a) : o.onRemove && o.onRemove(this.local[l].spec);
|
|
8482
8482
|
}
|
|
8483
|
-
return this.children.length ?
|
|
8483
|
+
return this.children.length ? $d(this.children, s || [], e, t, r, i, o) : s ? new D(s.sort(st), Ct) : q;
|
|
8484
8484
|
}
|
|
8485
8485
|
/**
|
|
8486
8486
|
Add the given array of decorations to the ones in the set,
|
|
@@ -8498,7 +8498,7 @@ class D {
|
|
|
8498
8498
|
if (f = Jl(t, l, c)) {
|
|
8499
8499
|
for (i || (i = this.children.slice()); o < i.length && i[o] < a; )
|
|
8500
8500
|
o += 3;
|
|
8501
|
-
i[o] == a ? i[o + 2] = i[o + 2].addInner(l, f, c + 1) : i.splice(o, 0, a, a + l.nodeSize,
|
|
8501
|
+
i[o] == a ? i[o + 2] = i[o + 2].addInner(l, f, c + 1) : i.splice(o, 0, a, a + l.nodeSize, Vn(f, l, c + 1, ot)), o += 3;
|
|
8502
8502
|
}
|
|
8503
8503
|
});
|
|
8504
8504
|
let s = ql(o ? jl(t) : t, -r);
|
|
@@ -8658,7 +8658,7 @@ class Re {
|
|
|
8658
8658
|
this.members[t].forEachSet(e);
|
|
8659
8659
|
}
|
|
8660
8660
|
}
|
|
8661
|
-
function
|
|
8661
|
+
function $d(n, e, t, r, i, o, s) {
|
|
8662
8662
|
let l = n.slice();
|
|
8663
8663
|
for (let c = 0, f = o; c < t.maps.length; c++) {
|
|
8664
8664
|
let d = 0;
|
|
@@ -8694,7 +8694,7 @@ function Vd(n, e, t, r, i, o, s) {
|
|
|
8694
8694
|
a = !0;
|
|
8695
8695
|
}
|
|
8696
8696
|
if (a) {
|
|
8697
|
-
let c =
|
|
8697
|
+
let c = Vd(l, n, e, t, i, o, s), f = Vn(c, r, 0, s);
|
|
8698
8698
|
e = f.local;
|
|
8699
8699
|
for (let d = 0; d < l.length; d += 3)
|
|
8700
8700
|
l[d + 1] < 0 && (l.splice(d, 3), d -= 3);
|
|
@@ -8717,7 +8717,7 @@ function ql(n, e) {
|
|
|
8717
8717
|
}
|
|
8718
8718
|
return t;
|
|
8719
8719
|
}
|
|
8720
|
-
function
|
|
8720
|
+
function Vd(n, e, t, r, i, o, s) {
|
|
8721
8721
|
function l(a, c) {
|
|
8722
8722
|
for (let f = 0; f < a.local.length; f++) {
|
|
8723
8723
|
let d = a.local[f].map(r, i, c);
|
|
@@ -8744,13 +8744,13 @@ function jl(n) {
|
|
|
8744
8744
|
n[t] != null && e.push(n[t]);
|
|
8745
8745
|
return e;
|
|
8746
8746
|
}
|
|
8747
|
-
function
|
|
8747
|
+
function Vn(n, e, t, r) {
|
|
8748
8748
|
let i = [], o = !1;
|
|
8749
8749
|
e.forEach((l, a) => {
|
|
8750
8750
|
let c = Jl(n, l, a + t);
|
|
8751
8751
|
if (c) {
|
|
8752
8752
|
o = !0;
|
|
8753
|
-
let f =
|
|
8753
|
+
let f = Vn(c, l, t + a + 1, r);
|
|
8754
8754
|
f != q && i.push(a, a + l.nodeSize, f);
|
|
8755
8755
|
}
|
|
8756
8756
|
});
|
|
@@ -8799,7 +8799,7 @@ const Fd = {
|
|
|
8799
8799
|
attributes: !0,
|
|
8800
8800
|
attributeOldValue: !0,
|
|
8801
8801
|
subtree: !0
|
|
8802
|
-
}, Wd = X &&
|
|
8802
|
+
}, Wd = X && $e <= 11;
|
|
8803
8803
|
class Kd {
|
|
8804
8804
|
constructor() {
|
|
8805
8805
|
this.anchorNode = null, this.anchorOffset = 0, this.focusNode = null, this.focusOffset = 0;
|
|
@@ -8819,7 +8819,7 @@ class Hd {
|
|
|
8819
8819
|
this.view = e, this.handleDOMChange = t, this.queue = [], this.flushingSoon = -1, this.observer = null, this.currentSelection = new Kd(), this.onCharData = null, this.suppressingSelectionUpdates = !1, this.lastChangedTextNode = null, this.observer = window.MutationObserver && new window.MutationObserver((r) => {
|
|
8820
8820
|
for (let i = 0; i < r.length; i++)
|
|
8821
8821
|
this.queue.push(r[i]);
|
|
8822
|
-
X &&
|
|
8822
|
+
X && $e <= 11 && r.some((i) => i.type == "childList" && i.removedNodes.length || i.type == "characterData" && i.oldValue.length > i.target.nodeValue.length) ? this.flushSoon() : J && e.composing && r.some((i) => i.type == "childList" && i.target.nodeName == "TR") ? (e.input.badSafariComposition = !0, this.flushSoon()) : this.flush();
|
|
8823
8823
|
}), Wd && (this.onCharData = (r) => {
|
|
8824
8824
|
this.queue.push({ target: r.target, type: "characterData", oldValue: r.prevValue }), this.flushSoon();
|
|
8825
8825
|
}), this.onSelectionChange = this.onSelectionChange.bind(this);
|
|
@@ -8860,7 +8860,7 @@ class Hd {
|
|
|
8860
8860
|
if (Mo(this.view)) {
|
|
8861
8861
|
if (this.suppressingSelectionUpdates)
|
|
8862
8862
|
return Ce(this.view);
|
|
8863
|
-
if (X &&
|
|
8863
|
+
if (X && $e <= 11 && !this.view.state.selection.empty) {
|
|
8864
8864
|
let e = this.view.domSelectionRange();
|
|
8865
8865
|
if (e.focusNode && ht(e.focusNode, e.focusOffset, e.anchorNode, e.anchorOffset))
|
|
8866
8866
|
return this.flushSoon();
|
|
@@ -8950,7 +8950,7 @@ class Hd {
|
|
|
8950
8950
|
if (r.contentDOM && r.contentDOM != r.dom && !r.contentDOM.contains(e.target))
|
|
8951
8951
|
return { from: r.posBefore, to: r.posAfter };
|
|
8952
8952
|
let i = e.previousSibling, o = e.nextSibling;
|
|
8953
|
-
if (X &&
|
|
8953
|
+
if (X && $e <= 11 && e.addedNodes.length)
|
|
8954
8954
|
for (let f = 0; f < e.addedNodes.length; f++) {
|
|
8955
8955
|
let { previousSibling: d, nextSibling: u } = e.addedNodes[f];
|
|
8956
8956
|
(!d || Array.prototype.indexOf.call(e.addedNodes, d) < 0) && (i = d), (!u || Array.prototype.indexOf.call(e.addedNodes, u) < 0) && (o = u);
|
|
@@ -9098,7 +9098,7 @@ function Xd(n, e, t, r, i) {
|
|
|
9098
9098
|
}
|
|
9099
9099
|
return;
|
|
9100
9100
|
}
|
|
9101
|
-
n.state.selection.from < n.state.selection.to && p.start == p.endB && n.state.selection instanceof k && (p.start > n.state.selection.from && p.start <= n.state.selection.from + 2 && n.state.selection.from >= c.from ? p.start = n.state.selection.from : p.endA < n.state.selection.to && p.endA >= n.state.selection.to - 2 && n.state.selection.to <= c.to && (p.endB += n.state.selection.to - p.endA, p.endA = n.state.selection.to)), X &&
|
|
9101
|
+
n.state.selection.from < n.state.selection.to && p.start == p.endB && n.state.selection instanceof k && (p.start > n.state.selection.from && p.start <= n.state.selection.from + 2 && n.state.selection.from >= c.from ? p.start = n.state.selection.from : p.endA < n.state.selection.to && p.endA >= n.state.selection.to - 2 && n.state.selection.to <= c.to && (p.endB += n.state.selection.to - p.endA, p.endA = n.state.selection.to)), X && $e <= 11 && p.endB == p.start + 1 && p.endA == p.start && p.start > c.from && c.doc.textBetween(p.start - c.from - 1, p.start - c.from + 1) == " " && (p.start--, p.endA--, p.endB--);
|
|
9102
9102
|
let m = c.doc.resolveNoCache(p.start - c.from), g = c.doc.resolveNoCache(p.endB - c.from), y = f.resolve(p.start), C = m.sameParent(g) && m.parent.inlineContent && y.end() >= p.endA;
|
|
9103
9103
|
if ((Rt && n.input.lastIOSEnter > Date.now() - 225 && (!C || i.some((O) => O.nodeName == "DIV" || O.nodeName == "P")) || !C && m.pos < c.doc.content.size && (!m.sameParent(g) || !m.parent.inlineContent) && m.pos < g.pos && !/\S/.test(c.doc.textBetween(m.pos, g.pos, "", ""))) && n.someProp("handleKeyDown", (O) => O(n, Ze(13, "Enter")))) {
|
|
9104
9104
|
n.input.lastIOSEnter = 0;
|
|
@@ -9123,7 +9123,7 @@ function Xd(n, e, t, r, i) {
|
|
|
9123
9123
|
}, L;
|
|
9124
9124
|
if (C)
|
|
9125
9125
|
if (m.pos == g.pos) {
|
|
9126
|
-
X &&
|
|
9126
|
+
X && $e <= 11 && m.parentOffset == 0 && (n.domObserver.suppressSelectionUpdates(), setTimeout(() => Ce(n), 20));
|
|
9127
9127
|
let O = v(n.state.tr.delete(M, N)), A = f.resolve(p.start).marksAcross(f.resolve(p.endA));
|
|
9128
9128
|
A && O.ensureMarks(A), n.dispatch(O);
|
|
9129
9129
|
} else if (
|
|
@@ -9216,7 +9216,7 @@ class tu {
|
|
|
9216
9216
|
added to the document.
|
|
9217
9217
|
*/
|
|
9218
9218
|
constructor(e, t) {
|
|
9219
|
-
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 gd(), this.prevDirectPlugins = [], this.pluginViews = [], this.requiresGeckoHackNode = !1, this.dragging = null, this._props = t, this.state = t.state, this.directPlugins = t.plugins || [], this.directPlugins.forEach(Fo), 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 =
|
|
9219
|
+
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 gd(), this.prevDirectPlugins = [], this.pluginViews = [], this.requiresGeckoHackNode = !1, this.dragging = null, this._props = t, this.state = t.state, this.directPlugins = t.plugins || [], this.directPlugins.forEach(Fo), 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 = $o(this), Lo(this), this.nodeViews = Vo(this), this.docView = bo(this.state.doc, zo(this), Nr(this), this.dom, this), this.domObserver = new Hd(this, (r, i, o, s) => Xd(this, r, i, o, s)), this.domObserver.start(), yd(this), this.updatePluginViews();
|
|
9220
9220
|
}
|
|
9221
9221
|
/**
|
|
9222
9222
|
Holds `true` when a
|
|
@@ -9275,10 +9275,10 @@ class tu {
|
|
|
9275
9275
|
e.storedMarks && this.composing && (Wl(this), s = !0), this.state = e;
|
|
9276
9276
|
let l = i.plugins != e.plugins || this._props.plugins != t.plugins;
|
|
9277
9277
|
if (l || this._props.plugins != t.plugins || this._props.nodeViews != t.nodeViews) {
|
|
9278
|
-
let h =
|
|
9278
|
+
let h = Vo(this);
|
|
9279
9279
|
ru(h, this.nodeViews) && (this.nodeViews = h, o = !0);
|
|
9280
9280
|
}
|
|
9281
|
-
(l || t.handleDOMEvents != this._props.handleDOMEvents) && ri(this), this.editable =
|
|
9281
|
+
(l || t.handleDOMEvents != this._props.handleDOMEvents) && ri(this), this.editable = $o(this), Lo(this);
|
|
9282
9282
|
let a = Nr(this), c = zo(this), f = i.plugins != e.plugins && !i.doc.eq(e.doc) ? "reset" : e.scrollToSelection > i.scrollToSelection ? "to selection" : "preserve", d = o || !this.docView.matchesNode(e.doc, c, a);
|
|
9283
9283
|
(d || !e.selection.eq(i.selection)) && (s = !0);
|
|
9284
9284
|
let u = f == "preserve" && s && this.dom.style.overflowAnchor == null && If(this);
|
|
@@ -9413,7 +9413,7 @@ class tu {
|
|
|
9413
9413
|
the top level, not in any node.
|
|
9414
9414
|
*/
|
|
9415
9415
|
posAtCoords(e) {
|
|
9416
|
-
return
|
|
9416
|
+
return $f(this, e);
|
|
9417
9417
|
}
|
|
9418
9418
|
/**
|
|
9419
9419
|
Returns the viewport rectangle at a given document position.
|
|
@@ -9559,14 +9559,14 @@ function Lo(n) {
|
|
|
9559
9559
|
} else
|
|
9560
9560
|
n.cursorWrapper = null;
|
|
9561
9561
|
}
|
|
9562
|
-
function
|
|
9562
|
+
function $o(n) {
|
|
9563
9563
|
return !n.someProp("editable", (e) => e(n.state) === !1);
|
|
9564
9564
|
}
|
|
9565
9565
|
function nu(n, e) {
|
|
9566
9566
|
let t = Math.min(n.$anchor.sharedDepth(n.head), e.$anchor.sharedDepth(e.head));
|
|
9567
9567
|
return n.$anchor.start(t) != e.$anchor.start(t);
|
|
9568
9568
|
}
|
|
9569
|
-
function
|
|
9569
|
+
function Vo(n) {
|
|
9570
9570
|
let e = /* @__PURE__ */ Object.create(null);
|
|
9571
9571
|
function t(r) {
|
|
9572
9572
|
for (let i in r)
|
|
@@ -9764,8 +9764,10 @@ function hu(n) {
|
|
|
9764
9764
|
}), n;
|
|
9765
9765
|
}
|
|
9766
9766
|
const ii = {
|
|
9767
|
-
inline_math: { atom: !0, attrs: { latex: { default: "" } }, group: "inline", inline: !0, toDOM: (n) => ["span", { "data-math-inline": "" }, n.attrs.latex] },
|
|
9768
|
-
math_block: { atom: !0, attrs: { latex: { default: "" } }, group: "block", toDOM: (n) => ["pre", { "data-math-block": "" },
|
|
9767
|
+
inline_math: { atom: !0, attrs: { latex: { default: "" } }, group: "inline", inline: !0, toDOM: (n) => ["span", { "data-math-inline": "" }, `$${n.attrs.latex}$`] },
|
|
9768
|
+
math_block: { atom: !0, attrs: { latex: { default: "" } }, group: "block", toDOM: (n) => ["pre", { "data-math-block": "" }, `$$
|
|
9769
|
+
${n.attrs.latex}
|
|
9770
|
+
$$`] }
|
|
9769
9771
|
};
|
|
9770
9772
|
function vm(n) {
|
|
9771
9773
|
return {
|
|
@@ -9937,7 +9939,9 @@ const Yl = {
|
|
|
9937
9939
|
attrs: { source: { default: "" } },
|
|
9938
9940
|
group: "block",
|
|
9939
9941
|
selectable: !0,
|
|
9940
|
-
toDOM: (n) => ["pre", { "data-mermaid": "" },
|
|
9942
|
+
toDOM: (n) => ["pre", { "data-mermaid": "" }, `\`\`\`mermaid
|
|
9943
|
+
${n.attrs.source}
|
|
9944
|
+
\`\`\``]
|
|
9941
9945
|
};
|
|
9942
9946
|
function Bm(n) {
|
|
9943
9947
|
return { ...Yl, toDOM: (e) => n(e.attrs.source) };
|
|
@@ -10056,13 +10060,13 @@ const Ql = {
|
|
|
10056
10060
|
selectable: !0,
|
|
10057
10061
|
toDOM: (n) => ["div", { "data-yfm-html": "" }, n.attrs.html]
|
|
10058
10062
|
};
|
|
10059
|
-
function
|
|
10063
|
+
function $m(n) {
|
|
10060
10064
|
return { ...Ql, toDOM: (e) => n(e.attrs.html) };
|
|
10061
10065
|
}
|
|
10062
|
-
const
|
|
10066
|
+
const $u = {
|
|
10063
10067
|
getAttrs: (n) => ({ html: n.content }),
|
|
10064
10068
|
node: lt
|
|
10065
|
-
},
|
|
10069
|
+
}, Vu = (n, e) => {
|
|
10066
10070
|
n.write(`:::html
|
|
10067
10071
|
${e.attrs.html}
|
|
10068
10072
|
:::`), n.closeBlock(e);
|
|
@@ -10077,8 +10081,8 @@ ${Ar}
|
|
|
10077
10081
|
function Qo(n) {
|
|
10078
10082
|
return typeof n == "object" && n !== null && "state" in n && n.state instanceof pe;
|
|
10079
10083
|
}
|
|
10080
|
-
const
|
|
10081
|
-
n.configureMd(Lu).addNodeSpec(lt, () => Ql).addMarkdownTokenParserSpec(lt, () =>
|
|
10084
|
+
const Vm = (n) => {
|
|
10085
|
+
n.configureMd(Lu).addNodeSpec(lt, () => Ql).addMarkdownTokenParserSpec(lt, () => $u).addNodeSerializerSpec(lt, () => Vu).addAction(zu, () => ({
|
|
10082
10086
|
isActive: () => !1,
|
|
10083
10087
|
isEnabled: (e) => Qo(e) && Xo(e.state),
|
|
10084
10088
|
metadata: () => {
|
|
@@ -10733,12 +10737,12 @@ function Mh(n) {
|
|
|
10733
10737
|
}
|
|
10734
10738
|
}
|
|
10735
10739
|
function On(n) {
|
|
10736
|
-
const e = n.marks[
|
|
10740
|
+
const e = n.marks[Va];
|
|
10737
10741
|
if (e === void 0) throw new Error("Italic extension requires an em mark");
|
|
10738
10742
|
return e;
|
|
10739
10743
|
}
|
|
10740
10744
|
const sg = (n, e, t) => ee(On(n.schema))(n, e, t), lg = (n, e) => {
|
|
10741
|
-
n.use(
|
|
10745
|
+
n.use($a), n.addInputRules(({ schema: t }) => ({
|
|
10742
10746
|
rules: [
|
|
10743
10747
|
Je({ close: "*", ignoreBetween: "*", open: "*" }, On(t)),
|
|
10744
10748
|
Je({ close: "_", ignoreBetween: "_", open: "_" }, On(t))
|
|
@@ -10849,13 +10853,13 @@ function ia(n) {
|
|
|
10849
10853
|
if (!e) throw new Error("Subscript requires sub mark");
|
|
10850
10854
|
return e;
|
|
10851
10855
|
}
|
|
10852
|
-
const bg = (n, e, t) => ee(ia(n.schema))(n, e, t), kg = (n) => n.configureMd((e) => e.use(Ja)).addMarkSpec(Tn, () => Ph).addMarkdownTokenParserSpec(Tn, () => Bh).addMarkSerializerSpec(Tn, () => zh).addInputRules(({ schema: e }) => ({ rules: [Je({ close: "~", ignoreBetween: "~", open: "~" }, ia(e))] })), Nn = "ins", Lh = { parseDOM: [{ tag: "ins" }, { tag: "u" }], toDOM: () => ["ins", 0] },
|
|
10856
|
+
const bg = (n, e, t) => ee(ia(n.schema))(n, e, t), kg = (n) => n.configureMd((e) => e.use(Ja)).addMarkSpec(Tn, () => Ph).addMarkdownTokenParserSpec(Tn, () => Bh).addMarkSerializerSpec(Tn, () => zh).addInputRules(({ schema: e }) => ({ rules: [Je({ close: "~", ignoreBetween: "~", open: "~" }, ia(e))] })), Nn = "ins", Lh = { parseDOM: [{ tag: "ins" }, { tag: "u" }], toDOM: () => ["ins", 0] }, $h = { mark: Nn }, Vh = { close: "++", expelEnclosingWhitespace: !0, mixable: !0, open: "++" };
|
|
10853
10857
|
function oa(n) {
|
|
10854
10858
|
const e = n.marks.ins;
|
|
10855
10859
|
if (!e) throw new Error("Underline requires ins mark");
|
|
10856
10860
|
return e;
|
|
10857
10861
|
}
|
|
10858
|
-
const xg = (n, e, t) => ee(oa(n.schema))(n, e, t), Sg = (n) => n.configureMd((e) => e.use(ja)).addMarkSpec(Nn, () => Lh).addMarkdownTokenParserSpec(Nn, () =>
|
|
10862
|
+
const xg = (n, e, t) => ee(oa(n.schema))(n, e, t), Sg = (n) => n.configureMd((e) => e.use(ja)).addMarkSpec(Nn, () => Lh).addMarkdownTokenParserSpec(Nn, () => $h).addMarkSerializerSpec(Nn, () => Vh).addInputRules(({ schema: e }) => ({ rules: [Je({ close: "++", ignoreBetween: "+", open: "++" }, oa(e))] }));
|
|
10859
10863
|
function Pe(n, e) {
|
|
10860
10864
|
const t = n.nodes[e];
|
|
10861
10865
|
if (t === void 0) throw new Error(`Table extension requires a ${e} node`);
|
|
@@ -11505,36 +11509,36 @@ Version: ${ap}`), !0)
|
|
|
11505
11509
|
n.Priority.Lowest
|
|
11506
11510
|
);
|
|
11507
11511
|
};
|
|
11508
|
-
var _n = 200,
|
|
11512
|
+
var _n = 200, V = function() {
|
|
11509
11513
|
};
|
|
11510
|
-
|
|
11511
|
-
return e.length ? (e =
|
|
11514
|
+
V.prototype.append = function(e) {
|
|
11515
|
+
return e.length ? (e = V.from(e), !this.length && e || e.length < _n && this.leafAppend(e) || this.length < _n && e.leafPrepend(this) || this.appendInner(e)) : this;
|
|
11512
11516
|
};
|
|
11513
|
-
|
|
11514
|
-
return e.length ?
|
|
11517
|
+
V.prototype.prepend = function(e) {
|
|
11518
|
+
return e.length ? V.from(e).append(this) : this;
|
|
11515
11519
|
};
|
|
11516
|
-
|
|
11520
|
+
V.prototype.appendInner = function(e) {
|
|
11517
11521
|
return new cp(this, e);
|
|
11518
11522
|
};
|
|
11519
|
-
|
|
11520
|
-
return e === void 0 && (e = 0), t === void 0 && (t = this.length), e >= t ?
|
|
11523
|
+
V.prototype.slice = function(e, t) {
|
|
11524
|
+
return e === void 0 && (e = 0), t === void 0 && (t = this.length), e >= t ? V.empty : this.sliceInner(Math.max(0, e), Math.min(this.length, t));
|
|
11521
11525
|
};
|
|
11522
|
-
|
|
11526
|
+
V.prototype.get = function(e) {
|
|
11523
11527
|
if (!(e < 0 || e >= this.length))
|
|
11524
11528
|
return this.getInner(e);
|
|
11525
11529
|
};
|
|
11526
|
-
|
|
11530
|
+
V.prototype.forEach = function(e, t, r) {
|
|
11527
11531
|
t === void 0 && (t = 0), r === void 0 && (r = this.length), t <= r ? this.forEachInner(e, t, r, 0) : this.forEachInvertedInner(e, t, r, 0);
|
|
11528
11532
|
};
|
|
11529
|
-
|
|
11533
|
+
V.prototype.map = function(e, t, r) {
|
|
11530
11534
|
t === void 0 && (t = 0), r === void 0 && (r = this.length);
|
|
11531
11535
|
var i = [];
|
|
11532
11536
|
return this.forEach(function(o, s) {
|
|
11533
11537
|
return i.push(e(o, s));
|
|
11534
11538
|
}, t, r), i;
|
|
11535
11539
|
};
|
|
11536
|
-
|
|
11537
|
-
return e instanceof
|
|
11540
|
+
V.from = function(e) {
|
|
11541
|
+
return e instanceof V ? e : e && e.length ? new pa(e) : V.empty;
|
|
11538
11542
|
};
|
|
11539
11543
|
var pa = /* @__PURE__ */ (function(n) {
|
|
11540
11544
|
function e(r) {
|
|
@@ -11567,8 +11571,8 @@ var pa = /* @__PURE__ */ (function(n) {
|
|
|
11567
11571
|
}, t.depth.get = function() {
|
|
11568
11572
|
return 0;
|
|
11569
11573
|
}, Object.defineProperties(e.prototype, t), e;
|
|
11570
|
-
})(
|
|
11571
|
-
|
|
11574
|
+
})(V);
|
|
11575
|
+
V.empty = new pa([]);
|
|
11572
11576
|
var cp = /* @__PURE__ */ (function(n) {
|
|
11573
11577
|
function e(t, r) {
|
|
11574
11578
|
n.call(this), this.left = t, this.right = r, this.length = t.length + r.length, this.depth = Math.max(t.depth, r.depth) + 1;
|
|
@@ -11601,7 +11605,7 @@ var cp = /* @__PURE__ */ (function(n) {
|
|
|
11601
11605
|
}, e.prototype.appendInner = function(r) {
|
|
11602
11606
|
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);
|
|
11603
11607
|
}, e;
|
|
11604
|
-
})(
|
|
11608
|
+
})(V);
|
|
11605
11609
|
const fp = 500;
|
|
11606
11610
|
class ce {
|
|
11607
11611
|
constructor(e, t) {
|
|
@@ -11712,10 +11716,10 @@ class ce {
|
|
|
11712
11716
|
(u = i.length && i[h].merge(d)) ? i[h] = u : i.push(d);
|
|
11713
11717
|
}
|
|
11714
11718
|
} else s.map && r--;
|
|
11715
|
-
}, this.items.length, 0), new ce(
|
|
11719
|
+
}, this.items.length, 0), new ce(V.from(i.reverse()), o);
|
|
11716
11720
|
}
|
|
11717
11721
|
}
|
|
11718
|
-
ce.empty = new ce(
|
|
11722
|
+
ce.empty = new ce(V.empty, 0);
|
|
11719
11723
|
function dp(n, e) {
|
|
11720
11724
|
let t;
|
|
11721
11725
|
return n.forEach((r, i) => {
|
|
@@ -11851,13 +11855,13 @@ const Lg = (n, e) => {
|
|
|
11851
11855
|
const t = {};
|
|
11852
11856
|
return e?.undoKey !== void 0 && e.undoKey !== null && (t[e.undoKey] = vi), e?.redoKey !== void 0 && e.redoKey !== null && (t[e.redoKey] = Ri), t;
|
|
11853
11857
|
});
|
|
11854
|
-
},
|
|
11858
|
+
}, $g = (n, e) => {
|
|
11855
11859
|
n.addPlugin(() => new P({
|
|
11856
11860
|
props: {
|
|
11857
11861
|
attributes: () => e?.content === void 0 || e.content.length === 0 ? {} : { "data-placeholder": e.content }
|
|
11858
11862
|
}
|
|
11859
11863
|
}), n.Priority.VeryHigh);
|
|
11860
|
-
}, ds = 40,
|
|
11864
|
+
}, ds = 40, Vg = (n) => {
|
|
11861
11865
|
n.addPlugin(() => new P({
|
|
11862
11866
|
props: {
|
|
11863
11867
|
decorations: (e) => !(e.selection instanceof w) || e.selection.node.type.name !== He ? D.empty : D.create(e.doc, [
|
|
@@ -12051,14 +12055,14 @@ function Lp(n, e, t) {
|
|
|
12051
12055
|
let s = i === "x" ? r === (t ? "end" : "start") ? "right" : "left" : r === "start" ? "bottom" : "top";
|
|
12052
12056
|
return e.reference[o] > e.floating[o] && (s = jn(s)), [s, jn(s)];
|
|
12053
12057
|
}
|
|
12054
|
-
function
|
|
12058
|
+
function $p(n) {
|
|
12055
12059
|
const e = jn(n);
|
|
12056
12060
|
return [ai(n), e, ai(e)];
|
|
12057
12061
|
}
|
|
12058
12062
|
function ai(n) {
|
|
12059
12063
|
return n.includes("start") ? n.replace("start", "end") : n.replace("end", "start");
|
|
12060
12064
|
}
|
|
12061
|
-
const hs = ["left", "right"], ps = ["right", "left"],
|
|
12065
|
+
const hs = ["left", "right"], ps = ["right", "left"], Vp = ["top", "bottom"], Fp = ["bottom", "top"];
|
|
12062
12066
|
function Wp(n, e, t) {
|
|
12063
12067
|
switch (n) {
|
|
12064
12068
|
case "top":
|
|
@@ -12066,7 +12070,7 @@ function Wp(n, e, t) {
|
|
|
12066
12070
|
return t ? e ? ps : hs : e ? hs : ps;
|
|
12067
12071
|
case "left":
|
|
12068
12072
|
case "right":
|
|
12069
|
-
return e ?
|
|
12073
|
+
return e ? Vp : Fp;
|
|
12070
12074
|
default:
|
|
12071
12075
|
return [];
|
|
12072
12076
|
}
|
|
@@ -12286,7 +12290,7 @@ const Jp = 50, jp = async (n, e, t) => {
|
|
|
12286
12290
|
} = or(n, e);
|
|
12287
12291
|
if ((t = o.arrow) != null && t.alignmentOffset)
|
|
12288
12292
|
return {};
|
|
12289
|
-
const y = Pt(i), C = Le(l), M = Pt(l) === l, N = await (a.isRTL == null ? void 0 : a.isRTL(c.floating)), v = u || (M || !m ? [jn(l)] :
|
|
12293
|
+
const y = Pt(i), C = Le(l), M = Pt(l) === l, N = await (a.isRTL == null ? void 0 : a.isRTL(c.floating)), v = u || (M || !m ? [jn(l)] : $p(l)), L = p !== "none";
|
|
12290
12294
|
!u && L && v.push(...Kp(l, m, p, N));
|
|
12291
12295
|
const O = [l, ...v], A = await a.detectOverflow(e, g), R = [];
|
|
12292
12296
|
let ne = ((r = o.flip) == null ? void 0 : r.overflows) || [];
|
|
@@ -12298,8 +12302,8 @@ const Jp = 50, jp = async (n, e, t) => {
|
|
|
12298
12302
|
placement: i,
|
|
12299
12303
|
overflows: R
|
|
12300
12304
|
}], !R.every((Ye) => Ye <= 0)) {
|
|
12301
|
-
var
|
|
12302
|
-
const Ye = (((
|
|
12305
|
+
var $i, Vi;
|
|
12306
|
+
const Ye = ((($i = o.flip) == null ? void 0 : $i.index) || 0) + 1, ur = O[Ye];
|
|
12303
12307
|
if (ur && (!(d === "alignment" ? C !== Le(ur) : !1) || // We leave the current main axis only if every placement on that axis
|
|
12304
12308
|
// overflows the main axis.
|
|
12305
12309
|
ne.every((le) => Le(le.placement) === C ? le.overflows[0] > 0 : !0)))
|
|
@@ -12312,8 +12316,8 @@ const Jp = 50, jp = async (n, e, t) => {
|
|
|
12312
12316
|
placement: ur
|
|
12313
12317
|
}
|
|
12314
12318
|
};
|
|
12315
|
-
let
|
|
12316
|
-
if (
|
|
12319
|
+
let $t = (Vi = ne.filter((Xe) => Xe.overflows[0] <= 0).sort((Xe, le) => Xe.overflows[1] - le.overflows[1])[0]) == null ? void 0 : Vi.placement;
|
|
12320
|
+
if (!$t)
|
|
12317
12321
|
switch (h) {
|
|
12318
12322
|
case "bestFit": {
|
|
12319
12323
|
var Fi;
|
|
@@ -12326,17 +12330,17 @@ const Jp = 50, jp = async (n, e, t) => {
|
|
|
12326
12330
|
}
|
|
12327
12331
|
return !0;
|
|
12328
12332
|
}).map((le) => [le.placement, le.overflows.filter((De) => De > 0).reduce((De, Na) => De + Na, 0)]).sort((le, De) => le[1] - De[1])[0]) == null ? void 0 : Fi[0];
|
|
12329
|
-
Xe && (
|
|
12333
|
+
Xe && ($t = Xe);
|
|
12330
12334
|
break;
|
|
12331
12335
|
}
|
|
12332
12336
|
case "initialPlacement":
|
|
12333
|
-
|
|
12337
|
+
$t = l;
|
|
12334
12338
|
break;
|
|
12335
12339
|
}
|
|
12336
|
-
if (i !==
|
|
12340
|
+
if (i !== $t)
|
|
12337
12341
|
return {
|
|
12338
12342
|
reset: {
|
|
12339
|
-
placement:
|
|
12343
|
+
placement: $t
|
|
12340
12344
|
}
|
|
12341
12345
|
};
|
|
12342
12346
|
}
|
|
@@ -12496,7 +12500,7 @@ function cr(n) {
|
|
|
12496
12500
|
}
|
|
12497
12501
|
}
|
|
12498
12502
|
const em = /transform|translate|scale|rotate|perspective|filter/, tm = /paint|layout|strict|content/, Qe = (n) => !!n && n !== "none";
|
|
12499
|
-
let
|
|
12503
|
+
let $r;
|
|
12500
12504
|
function Pi(n) {
|
|
12501
12505
|
const e = ge(n) ? ye(n) : n;
|
|
12502
12506
|
return Qe(e.transform) || Qe(e.translate) || Qe(e.scale) || Qe(e.rotate) || Qe(e.perspective) || !Bi() && (Qe(e.backdropFilter) || Qe(e.filter)) || em.test(e.willChange || "") || tm.test(e.contain || "");
|
|
@@ -12513,7 +12517,7 @@ function nm(n) {
|
|
|
12513
12517
|
return null;
|
|
12514
12518
|
}
|
|
12515
12519
|
function Bi() {
|
|
12516
|
-
return
|
|
12520
|
+
return $r == null && ($r = typeof CSS < "u" && CSS.supports && CSS.supports("-webkit-backdrop-filter", "none")), $r;
|
|
12517
12521
|
}
|
|
12518
12522
|
function an(n) {
|
|
12519
12523
|
return /^(html|body|#document)$/.test(Lt(n));
|
|
@@ -12783,7 +12787,7 @@ function pm(n, e, t) {
|
|
|
12783
12787
|
height: s.height
|
|
12784
12788
|
};
|
|
12785
12789
|
}
|
|
12786
|
-
function
|
|
12790
|
+
function Vr(n) {
|
|
12787
12791
|
return ye(n).position === "static";
|
|
12788
12792
|
}
|
|
12789
12793
|
function bs(n, e) {
|
|
@@ -12801,16 +12805,16 @@ function Oa(n, e) {
|
|
|
12801
12805
|
if (!Ge(n)) {
|
|
12802
12806
|
let i = mt(n);
|
|
12803
12807
|
for (; i && !an(i); ) {
|
|
12804
|
-
if (ge(i) &&
|
|
12808
|
+
if (ge(i) && !Vr(i))
|
|
12805
12809
|
return i;
|
|
12806
12810
|
i = mt(i);
|
|
12807
12811
|
}
|
|
12808
12812
|
return t;
|
|
12809
12813
|
}
|
|
12810
12814
|
let r = bs(n, e);
|
|
12811
|
-
for (; r && Zp(r) &&
|
|
12815
|
+
for (; r && Zp(r) && Vr(r); )
|
|
12812
12816
|
r = bs(r, e);
|
|
12813
|
-
return r && an(r) &&
|
|
12817
|
+
return r && an(r) && Vr(r) && !Pi(r) ? t : r || nm(n) || t;
|
|
12814
12818
|
}
|
|
12815
12819
|
const mm = async function(n) {
|
|
12816
12820
|
const e = this.getOffsetParent || Oa, t = this.getDimensions, r = await t(n.floating);
|
|
@@ -13123,16 +13127,16 @@ export {
|
|
|
13123
13127
|
Pm as N,
|
|
13124
13128
|
Gl as O,
|
|
13125
13129
|
zm as P,
|
|
13126
|
-
|
|
13130
|
+
$g as Q,
|
|
13127
13131
|
Lm as R,
|
|
13128
|
-
|
|
13132
|
+
Vg as S,
|
|
13129
13133
|
Fg as T,
|
|
13130
13134
|
Hg as U,
|
|
13131
13135
|
yg as V,
|
|
13132
13136
|
kg as W,
|
|
13133
13137
|
Eg as X,
|
|
13134
13138
|
Sg as Y,
|
|
13135
|
-
|
|
13139
|
+
Vm as Z,
|
|
13136
13140
|
Ku as _,
|
|
13137
13141
|
jh as a,
|
|
13138
13142
|
jt as a$,
|
|
@@ -13184,7 +13188,7 @@ export {
|
|
|
13184
13188
|
vm as ai,
|
|
13185
13189
|
Bm as aj,
|
|
13186
13190
|
Fh as ak,
|
|
13187
|
-
|
|
13191
|
+
$m as al,
|
|
13188
13192
|
Di as am,
|
|
13189
13193
|
Tu as an,
|
|
13190
13194
|
Ar as ao,
|
|
@@ -13237,7 +13241,7 @@ export {
|
|
|
13237
13241
|
xg as bX,
|
|
13238
13242
|
Nn as bY,
|
|
13239
13243
|
Lh as bZ,
|
|
13240
|
-
|
|
13244
|
+
$h as b_,
|
|
13241
13245
|
Du as ba,
|
|
13242
13246
|
xu as bb,
|
|
13243
13247
|
Su as bc,
|
|
@@ -13261,14 +13265,14 @@ export {
|
|
|
13261
13265
|
Pu as bu,
|
|
13262
13266
|
Rh as bv,
|
|
13263
13267
|
zh as bw,
|
|
13264
|
-
|
|
13265
|
-
|
|
13268
|
+
Vh as bx,
|
|
13269
|
+
Vu as by,
|
|
13266
13270
|
jm as bz,
|
|
13267
13271
|
Gh as c,
|
|
13268
13272
|
zu as c0,
|
|
13269
13273
|
lt as c1,
|
|
13270
13274
|
Ql as c2,
|
|
13271
|
-
|
|
13275
|
+
$u as c3,
|
|
13272
13276
|
km as c4,
|
|
13273
13277
|
Cm as c5,
|
|
13274
13278
|
xm as c6,
|