@harbour-enterprises/superdoc 0.9.29 → 0.9.31
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/chunks/{super-editor.es-3vjviElK.es.js → super-editor.es-Cfp9d4tz.es.js} +2627 -2586
- package/dist/chunks/{super-editor.es-B_22wiv0.cjs → super-editor.es-PLzciugT.cjs} +43 -43
- package/dist/super-editor/chunks/{converter-CGQb9Hy1.js → converter-DPs2uVUI.js} +778 -758
- package/dist/super-editor/chunks/{docx-zipper-BV5p4q9h.js → docx-zipper-qfQSstu1.js} +1 -1
- package/dist/super-editor/chunks/{editor-C6C8E75p.js → editor-BHdWrpsU.js} +477 -454
- package/dist/super-editor/chunks/{toolbar-D92URE2F.js → toolbar-xuviIFg4.js} +2 -2
- package/dist/super-editor/converter.es.js +1 -1
- package/dist/super-editor/core/super-converter/v2/importer/autoPageNumberImporter.d.ts +4 -0
- package/dist/super-editor/core/super-converter/v2/importer/autoPageNumberImporter.d.ts.map +1 -1
- package/dist/super-editor/core/super-converter/v2/importer/docxImporter.d.ts.map +1 -1
- package/dist/super-editor/core/super-converter/v2/importer/paragraphNodeImporter.d.ts.map +1 -1
- package/dist/super-editor/docx-zipper.es.js +2 -2
- package/dist/super-editor/editor.es.js +3 -3
- package/dist/super-editor/extensions/index.d.ts.map +1 -1
- package/dist/super-editor/extensions/page-number/page-number.d.ts +1 -0
- package/dist/super-editor/extensions/page-number/page-number.d.ts.map +1 -1
- package/dist/super-editor/file-zipper.es.js +1 -1
- package/dist/super-editor/super-editor.es.js +6 -6
- package/dist/super-editor/toolbar.es.js +2 -2
- package/dist/super-editor.cjs +1 -1
- package/dist/super-editor.es.js +1 -1
- package/dist/superdoc.cjs +4 -4
- package/dist/superdoc.es.js +3 -3
- package/dist/superdoc.umd.js +1719 -1676
- package/dist/superdoc.umd.js.map +1 -1
- package/package.json +1 -1
|
@@ -7,9 +7,9 @@ var P = (t, e, n) => ff(t, typeof e != "symbol" ? e + "" : e, n), Ho = (t, e, n)
|
|
|
7
7
|
var Ge = (t, e, n) => (Ho(t, e, "read from private field"), n ? n.call(t) : e.get(t)), ft = (t, e, n) => e.has(t) ? Gs("Cannot add the same private member more than once") : e instanceof WeakSet ? e.add(t) : e.set(t, n), jo = (t, e, n, r) => (Ho(t, e, "write to private field"), r ? r.call(t, n) : e.set(t, n), n), I = (t, e, n) => (Ho(t, e, "access private method"), n);
|
|
8
8
|
import * as T from "yjs";
|
|
9
9
|
import { UndoManager as pf, Item as hf, ContentType as mf, Text as gf, XmlElement as yf } from "yjs";
|
|
10
|
-
import { P as G, a as Z, M as cr, N as B, S as
|
|
10
|
+
import { P as G, a as Z, M as cr, N as B, S as Y, T as H, b as W, D as $n, F as E, c as An, d as bf, e as Jl, A as Ar, p as ie, B as wf, f as Yl, i as vf, g as wt, l as Or, h as Ht, j as Gl, r as Zl, R as sn, o as dr, k as $t, m as bi, n as Ql, q as ue, s as $e, v as Do, t as kn, u as kf, w as Se, x as to, y as ec, z as Cn, C as Wo, E as Uo, G as qo, H as no, I as Cf, J as Zs, K as Sf, L as xf } from "./converter-DPs2uVUI.js";
|
|
11
11
|
import { ref as Qs, computed as Mf, createElementBlock as Kt, openBlock as Xt, withModifiers as Ko, Fragment as Af, renderList as Of, normalizeClass as Tf, createCommentVNode as ea, toDisplayString as Xo, createElementVNode as Df, createApp as Nf } from "vue";
|
|
12
|
-
import { D as ta } from "./docx-zipper-
|
|
12
|
+
import { D as ta } from "./docx-zipper-qfQSstu1.js";
|
|
13
13
|
function No(t) {
|
|
14
14
|
const { from: e, to: n, empty: r } = t.selection, o = [];
|
|
15
15
|
return r ? (t.storedMarks && o.push(...t.storedMarks), o.push(...t.selection.$head.marks())) : t.doc.nodesBetween(e, n, (i) => {
|
|
@@ -407,15 +407,15 @@ function nc(t, e) {
|
|
|
407
407
|
};
|
|
408
408
|
}
|
|
409
409
|
const rc = nc(!1, !0), oc = nc(!0, !0);
|
|
410
|
-
function
|
|
410
|
+
function $k(t) {
|
|
411
411
|
let e = vt.getState(t);
|
|
412
412
|
return e ? e.done.eventCount : 0;
|
|
413
413
|
}
|
|
414
|
-
function
|
|
414
|
+
function Vk(t) {
|
|
415
415
|
let e = vt.getState(t);
|
|
416
416
|
return e ? e.undone.eventCount : 0;
|
|
417
417
|
}
|
|
418
|
-
function
|
|
418
|
+
function N(t, e, n = {}) {
|
|
419
419
|
return typeof t.config[e] == "function" ? t.config[e].bind({ ...n }) : t.config[e];
|
|
420
420
|
}
|
|
421
421
|
function K(t, e = null, ...n) {
|
|
@@ -434,11 +434,11 @@ class Q {
|
|
|
434
434
|
...this.config,
|
|
435
435
|
...e
|
|
436
436
|
}, this.name = this.config.name, this.config.addOptions && (this.options = K(
|
|
437
|
-
|
|
437
|
+
N(this, "addOptions", {
|
|
438
438
|
name: this.name
|
|
439
439
|
})
|
|
440
440
|
)), this.storage = K(
|
|
441
|
-
|
|
441
|
+
N(this, "addStorage", {
|
|
442
442
|
name: this.name,
|
|
443
443
|
options: this.options
|
|
444
444
|
})
|
|
@@ -1431,7 +1431,7 @@ class Ft extends Nr {
|
|
|
1431
1431
|
}
|
|
1432
1432
|
localCompositionInfo(e, n) {
|
|
1433
1433
|
let { from: r, to: o } = e.state.selection;
|
|
1434
|
-
if (!(e.state.selection instanceof
|
|
1434
|
+
if (!(e.state.selection instanceof H) || r < n || o > n + this.node.content.size)
|
|
1435
1435
|
return null;
|
|
1436
1436
|
let i = e.input.compositionNode;
|
|
1437
1437
|
if (!i || !this.dom.contains(i.parentNode))
|
|
@@ -1990,7 +1990,7 @@ function kt(t, e = !1) {
|
|
|
1990
1990
|
Sp(t);
|
|
1991
1991
|
else {
|
|
1992
1992
|
let { anchor: r, head: o } = n, i, s;
|
|
1993
|
-
ma && !(n instanceof
|
|
1993
|
+
ma && !(n instanceof H) && (n.$from.parent.inlineContent || (i = ga(t, n.from)), !n.empty && !n.$from.parent.inlineContent && (s = ga(t, n.to))), t.docView.setSelection(r, o, t, e), ma && (i && ya(i), s && ya(s)), n.visible ? t.dom.classList.remove("ProseMirror-hideselection") : (t.dom.classList.add("ProseMirror-hideselection"), "onselectionchange" in document && Cp(t));
|
|
1994
1994
|
}
|
|
1995
1995
|
t.domObserver.setCurSelection(), t.domObserver.connectSelection();
|
|
1996
1996
|
}
|
|
@@ -2041,7 +2041,7 @@ function ba(t) {
|
|
|
2041
2041
|
t.lastSelectedViewDesc && (t.lastSelectedViewDesc.parent && t.lastSelectedViewDesc.deselectNode(), t.lastSelectedViewDesc = void 0);
|
|
2042
2042
|
}
|
|
2043
2043
|
function bs(t, e, n, r) {
|
|
2044
|
-
return t.someProp("createSelectionBetween", (o) => o(t, e, n)) ||
|
|
2044
|
+
return t.someProp("createSelectionBetween", (o) => o(t, e, n)) || H.between(e, n, r);
|
|
2045
2045
|
}
|
|
2046
2046
|
function wa(t) {
|
|
2047
2047
|
return t.editable && !t.hasFocus() ? !1 : vc(t);
|
|
@@ -2062,20 +2062,20 @@ function xp(t) {
|
|
|
2062
2062
|
}
|
|
2063
2063
|
function Mi(t, e) {
|
|
2064
2064
|
let { $anchor: n, $head: r } = t.selection, o = e > 0 ? n.max(r) : n.min(r), i = o.parent.inlineContent ? o.depth ? t.doc.resolve(e > 0 ? o.after() : o.before()) : null : o;
|
|
2065
|
-
return i &&
|
|
2065
|
+
return i && Y.findFrom(i, e);
|
|
2066
2066
|
}
|
|
2067
2067
|
function Nt(t, e) {
|
|
2068
2068
|
return t.dispatch(t.state.tr.setSelection(e).scrollIntoView()), !0;
|
|
2069
2069
|
}
|
|
2070
2070
|
function va(t, e, n) {
|
|
2071
2071
|
let r = t.state.selection;
|
|
2072
|
-
if (r instanceof
|
|
2072
|
+
if (r instanceof H)
|
|
2073
2073
|
if (n.indexOf("s") > -1) {
|
|
2074
2074
|
let { $head: o } = r, i = o.textOffset ? null : e < 0 ? o.nodeBefore : o.nodeAfter;
|
|
2075
2075
|
if (!i || i.isText || !i.isLeaf)
|
|
2076
2076
|
return !1;
|
|
2077
2077
|
let s = t.state.doc.resolve(o.pos + i.nodeSize * (e < 0 ? -1 : 1));
|
|
2078
|
-
return Nt(t, new
|
|
2078
|
+
return Nt(t, new H(r.$anchor, s));
|
|
2079
2079
|
} else if (r.empty) {
|
|
2080
2080
|
if (t.endOfTextblock(e > 0 ? "forward" : "backward")) {
|
|
2081
2081
|
let o = Mi(t.state, e);
|
|
@@ -2085,12 +2085,12 @@ function va(t, e, n) {
|
|
|
2085
2085
|
if (!i || i.isText)
|
|
2086
2086
|
return !1;
|
|
2087
2087
|
let a = e < 0 ? o.pos - i.nodeSize : o.pos;
|
|
2088
|
-
return i.isAtom || (s = t.docView.descAt(a)) && !s.contentDOM ? B.isSelectable(i) ? Nt(t, new B(e < 0 ? t.state.doc.resolve(o.pos - i.nodeSize) : o)) : Dr ? Nt(t, new
|
|
2088
|
+
return i.isAtom || (s = t.docView.descAt(a)) && !s.contentDOM ? B.isSelectable(i) ? Nt(t, new B(e < 0 ? t.state.doc.resolve(o.pos - i.nodeSize) : o)) : Dr ? Nt(t, new H(t.state.doc.resolve(e < 0 ? a : a + i.nodeSize))) : !1 : !1;
|
|
2089
2089
|
}
|
|
2090
2090
|
} else return !1;
|
|
2091
2091
|
else {
|
|
2092
2092
|
if (r instanceof B && r.node.isInline)
|
|
2093
|
-
return Nt(t, new
|
|
2093
|
+
return Nt(t, new H(e > 0 ? r.$to : r.$from));
|
|
2094
2094
|
{
|
|
2095
2095
|
let o = Mi(t.state, e);
|
|
2096
2096
|
return o ? Nt(t, o) : !1;
|
|
@@ -2240,7 +2240,7 @@ function ka(t, e) {
|
|
|
2240
2240
|
}
|
|
2241
2241
|
function Ca(t, e, n) {
|
|
2242
2242
|
let r = t.state.selection;
|
|
2243
|
-
if (r instanceof
|
|
2243
|
+
if (r instanceof H && !r.empty || n.indexOf("s") > -1 || _e && n.indexOf("m") > -1)
|
|
2244
2244
|
return !1;
|
|
2245
2245
|
let { $from: o, $to: i } = r;
|
|
2246
2246
|
if (!o.parent.inlineContent || t.endOfTextblock(e < 0 ? "up" : "down")) {
|
|
@@ -2249,13 +2249,13 @@ function Ca(t, e, n) {
|
|
|
2249
2249
|
return Nt(t, s);
|
|
2250
2250
|
}
|
|
2251
2251
|
if (!o.parent.inlineContent) {
|
|
2252
|
-
let s = e < 0 ? o : i, a = r instanceof Ar ?
|
|
2252
|
+
let s = e < 0 ? o : i, a = r instanceof Ar ? Y.near(s, e) : Y.findFrom(s, e);
|
|
2253
2253
|
return a ? Nt(t, a) : !1;
|
|
2254
2254
|
}
|
|
2255
2255
|
return !1;
|
|
2256
2256
|
}
|
|
2257
2257
|
function Sa(t, e) {
|
|
2258
|
-
if (!(t.state.selection instanceof
|
|
2258
|
+
if (!(t.state.selection instanceof H))
|
|
2259
2259
|
return !0;
|
|
2260
2260
|
let { $head: n, $anchor: r, empty: o } = t.state.selection;
|
|
2261
2261
|
if (!n.sameParent(r))
|
|
@@ -2571,7 +2571,7 @@ Ae.keypress = (t, e) => {
|
|
|
2571
2571
|
return;
|
|
2572
2572
|
}
|
|
2573
2573
|
let r = t.state.selection;
|
|
2574
|
-
if (!(r instanceof
|
|
2574
|
+
if (!(r instanceof H) || !r.$from.sameParent(r.$to)) {
|
|
2575
2575
|
let o = String.fromCharCode(n.charCode);
|
|
2576
2576
|
!/[\r\n]/.test(o) && !t.someProp("handleTextInput", (i) => i(t, r.$from.pos, r.$to.pos, o)) && t.dispatch(t.state.tr.insertText(o).scrollIntoView()), n.preventDefault();
|
|
2577
2577
|
}
|
|
@@ -2633,12 +2633,12 @@ function Yp(t, e, n) {
|
|
|
2633
2633
|
return !1;
|
|
2634
2634
|
let r = t.state.doc;
|
|
2635
2635
|
if (e == -1)
|
|
2636
|
-
return r.inlineContent ? (On(t,
|
|
2636
|
+
return r.inlineContent ? (On(t, H.create(r, 0, r.content.size)), !0) : !1;
|
|
2637
2637
|
let o = r.resolve(e);
|
|
2638
2638
|
for (let i = o.depth + 1; i > 0; i--) {
|
|
2639
2639
|
let s = i > o.depth ? o.nodeAfter : o.node(i), a = o.before(i);
|
|
2640
2640
|
if (s.inlineContent)
|
|
2641
|
-
On(t,
|
|
2641
|
+
On(t, H.create(r, a + 1, a + 1 + s.content.size));
|
|
2642
2642
|
else if (B.isSelectable(s))
|
|
2643
2643
|
On(t, B.create(r, a));
|
|
2644
2644
|
else
|
|
@@ -2695,7 +2695,7 @@ class Gp {
|
|
|
2695
2695
|
// (hidden) cursor is doesn't change the selection, and
|
|
2696
2696
|
// thus doesn't get a reaction from ProseMirror. This
|
|
2697
2697
|
// works around that.
|
|
2698
|
-
be && !this.view.state.selection.visible && Math.min(Math.abs(n.pos - this.view.state.selection.from), Math.abs(n.pos - this.view.state.selection.to)) <= 2) ? (On(this.view,
|
|
2698
|
+
be && !this.view.state.selection.visible && Math.min(Math.abs(n.pos - this.view.state.selection.from), Math.abs(n.pos - this.view.state.selection.to)) <= 2) ? (On(this.view, Y.near(this.view.state.doc.resolve(n.pos))), e.preventDefault()) : Pt(this.view, "pointer");
|
|
2699
2699
|
}
|
|
2700
2700
|
move(e) {
|
|
2701
2701
|
this.updateAllowDefault(e), Pt(this.view, "pointer"), e.buttons == 0 && this.done();
|
|
@@ -2719,7 +2719,7 @@ Ae.compositionstart = Ae.compositionupdate = (t) => {
|
|
|
2719
2719
|
if (!t.composing) {
|
|
2720
2720
|
t.domObserver.flush();
|
|
2721
2721
|
let { state: e } = t, n = e.selection.$to;
|
|
2722
|
-
if (e.selection instanceof
|
|
2722
|
+
if (e.selection instanceof H && (e.storedMarks || !n.textOffset && n.parentOffset && n.nodeBefore.marks.some((r) => r.type.spec.inclusive === !1)))
|
|
2723
2723
|
t.markCursor = t.state.storedMarks || n.marks(), mo(t, !0), t.markCursor = null;
|
|
2724
2724
|
else if (mo(t, !e.selection.empty), Je && e.selection.empty && n.parentOffset && !n.textOffset && n.nodeBefore.marks.length) {
|
|
2725
2725
|
let r = t.domSelectionRange();
|
|
@@ -2946,7 +2946,7 @@ class go {
|
|
|
2946
2946
|
}
|
|
2947
2947
|
map(e, n, r, o) {
|
|
2948
2948
|
let { pos: i, deleted: s } = e.mapResult(n.from + o, this.side < 0 ? -1 : 1);
|
|
2949
|
-
return s ? null : new
|
|
2949
|
+
return s ? null : new $(i - r, i - r, this);
|
|
2950
2950
|
}
|
|
2951
2951
|
valid() {
|
|
2952
2952
|
return !0;
|
|
@@ -2964,7 +2964,7 @@ class Bt {
|
|
|
2964
2964
|
}
|
|
2965
2965
|
map(e, n, r, o) {
|
|
2966
2966
|
let i = e.map(n.from + o, this.spec.inclusiveStart ? -1 : 1) - r, s = e.map(n.to + o, this.spec.inclusiveEnd ? 1 : -1) - r;
|
|
2967
|
-
return i >= s ? null : new
|
|
2967
|
+
return i >= s ? null : new $(i, s, this);
|
|
2968
2968
|
}
|
|
2969
2969
|
valid(e, n) {
|
|
2970
2970
|
return n.from < n.to;
|
|
@@ -2987,7 +2987,7 @@ class Ss {
|
|
|
2987
2987
|
if (i.deleted)
|
|
2988
2988
|
return null;
|
|
2989
2989
|
let s = e.mapResult(n.to + o, -1);
|
|
2990
|
-
return s.deleted || s.pos <= i.pos ? null : new
|
|
2990
|
+
return s.deleted || s.pos <= i.pos ? null : new $(i.pos - r, s.pos - r, this);
|
|
2991
2991
|
}
|
|
2992
2992
|
valid(e, n) {
|
|
2993
2993
|
let { index: r, offset: o } = e.content.findIndex(n.from), i;
|
|
@@ -2999,7 +2999,7 @@ class Ss {
|
|
|
2999
2999
|
destroy() {
|
|
3000
3000
|
}
|
|
3001
3001
|
}
|
|
3002
|
-
class
|
|
3002
|
+
class $ {
|
|
3003
3003
|
/**
|
|
3004
3004
|
@internal
|
|
3005
3005
|
*/
|
|
@@ -3010,7 +3010,7 @@ class z {
|
|
|
3010
3010
|
@internal
|
|
3011
3011
|
*/
|
|
3012
3012
|
copy(e, n) {
|
|
3013
|
-
return new
|
|
3013
|
+
return new $(e, n, this.type);
|
|
3014
3014
|
}
|
|
3015
3015
|
/**
|
|
3016
3016
|
@internal
|
|
@@ -3033,14 +3033,14 @@ class z {
|
|
|
3033
3033
|
widget's current document position.
|
|
3034
3034
|
*/
|
|
3035
3035
|
static widget(e, n, r) {
|
|
3036
|
-
return new
|
|
3036
|
+
return new $(e, e, new go(n, r));
|
|
3037
3037
|
}
|
|
3038
3038
|
/**
|
|
3039
3039
|
Creates an inline decoration, which adds the given attributes to
|
|
3040
3040
|
each inline node between `from` and `to`.
|
|
3041
3041
|
*/
|
|
3042
3042
|
static inline(e, n, r, o) {
|
|
3043
|
-
return new
|
|
3043
|
+
return new $(e, n, new Bt(r, o));
|
|
3044
3044
|
}
|
|
3045
3045
|
/**
|
|
3046
3046
|
Creates a node decoration. `from` and `to` should point precisely
|
|
@@ -3048,7 +3048,7 @@ class z {
|
|
|
3048
3048
|
node, will receive the given attributes.
|
|
3049
3049
|
*/
|
|
3050
3050
|
static node(e, n, r, o) {
|
|
3051
|
-
return new
|
|
3051
|
+
return new $(e, n, new Ss(r, o));
|
|
3052
3052
|
}
|
|
3053
3053
|
/**
|
|
3054
3054
|
The spec provided when creating this decoration. Can be useful
|
|
@@ -3358,7 +3358,7 @@ function Lc(t, e) {
|
|
|
3358
3358
|
let n = [];
|
|
3359
3359
|
for (let r = 0; r < t.length; r++) {
|
|
3360
3360
|
let o = t[r];
|
|
3361
|
-
n.push(new
|
|
3361
|
+
n.push(new $(o.from + e, o.to + e, o.type));
|
|
3362
3362
|
}
|
|
3363
3363
|
return n;
|
|
3364
3364
|
}
|
|
@@ -3566,7 +3566,7 @@ class dh {
|
|
|
3566
3566
|
}
|
|
3567
3567
|
}
|
|
3568
3568
|
let c = null;
|
|
3569
|
-
i < 0 && o && e.input.lastFocus > Date.now() - 200 && Math.max(e.input.lastTouch, e.input.lastClick.time) < Date.now() - 300 && Io(r) && (c = ys(e)) && c.eq(
|
|
3569
|
+
i < 0 && o && e.input.lastFocus > Date.now() - 200 && Math.max(e.input.lastTouch, e.input.lastClick.time) < Date.now() - 300 && Io(r) && (c = ys(e)) && c.eq(Y.near(e.state.doc.resolve(0), 1)) ? (e.input.lastFocus = 0, kt(e), this.currentSelection.set(r), e.scrollToSelection()) : (i > -1 || o) && (i > -1 && (e.docView.markDirty(i, s), uh(e)), this.handleDOMChange(i, s, a, l), e.docView && e.docView.dirty ? e.updateState(e.state) : this.currentSelection.eq(r) || kt(e), this.currentSelection.set(r));
|
|
3570
3570
|
}
|
|
3571
3571
|
registerMutation(e, n) {
|
|
3572
3572
|
if (n.indexOf(e.target) > -1)
|
|
@@ -3680,11 +3680,11 @@ const gh = /^(a|abbr|acronym|b|bd[io]|big|br|button|cite|code|data(list)?|del|df
|
|
|
3680
3680
|
function yh(t, e, n, r, o) {
|
|
3681
3681
|
let i = t.input.compositionPendingChanges || (t.composing ? t.input.compositionID : 0);
|
|
3682
3682
|
if (t.input.compositionPendingChanges = 0, e < 0) {
|
|
3683
|
-
let x = t.input.lastSelectionTime > Date.now() - 50 ? t.input.lastSelectionOrigin : null,
|
|
3684
|
-
if (
|
|
3685
|
-
if (be && bt && t.input.lastKeyCode === 13 && Date.now() - 100 < t.input.lastKeyCodeTime && t.someProp("handleKeyDown", (
|
|
3683
|
+
let x = t.input.lastSelectionTime > Date.now() - 50 ? t.input.lastSelectionOrigin : null, z = ys(t, x);
|
|
3684
|
+
if (z && !t.state.selection.eq(z)) {
|
|
3685
|
+
if (be && bt && t.input.lastKeyCode === 13 && Date.now() - 100 < t.input.lastKeyCodeTime && t.someProp("handleKeyDown", (V) => V(t, Gt(13, "Enter"))))
|
|
3686
3686
|
return;
|
|
3687
|
-
let _ = t.state.tr.setSelection(
|
|
3687
|
+
let _ = t.state.tr.setSelection(z);
|
|
3688
3688
|
x == "pointer" ? _.setMeta("pointer", !0) : x == "key" && _.scrollIntoView(), i && _.setMeta("composition", i), t.dispatch(_);
|
|
3689
3689
|
}
|
|
3690
3690
|
return;
|
|
@@ -3699,21 +3699,21 @@ function yh(t, e, n, r, o) {
|
|
|
3699
3699
|
return;
|
|
3700
3700
|
}
|
|
3701
3701
|
if (!h)
|
|
3702
|
-
if (r && l instanceof
|
|
3702
|
+
if (r && l instanceof H && !l.empty && l.$head.sameParent(l.$anchor) && !t.composing && !(c.sel && c.sel.anchor != c.sel.head))
|
|
3703
3703
|
h = { start: l.from, endA: l.to, endB: l.to };
|
|
3704
3704
|
else {
|
|
3705
3705
|
if (c.sel) {
|
|
3706
3706
|
let x = Ea(t, t.state.doc, c.sel);
|
|
3707
3707
|
if (x && !x.eq(t.state.selection)) {
|
|
3708
|
-
let
|
|
3709
|
-
i &&
|
|
3708
|
+
let z = t.state.tr.setSelection(x);
|
|
3709
|
+
i && z.setMeta("composition", i), t.dispatch(z);
|
|
3710
3710
|
}
|
|
3711
3711
|
}
|
|
3712
3712
|
return;
|
|
3713
3713
|
}
|
|
3714
|
-
t.state.selection.from < t.state.selection.to && h.start == h.endB && t.state.selection instanceof
|
|
3714
|
+
t.state.selection.from < t.state.selection.to && h.start == h.endB && t.state.selection instanceof H && (h.start > t.state.selection.from && h.start <= t.state.selection.from + 2 && t.state.selection.from >= c.from ? h.start = t.state.selection.from : h.endA < t.state.selection.to && h.endA >= t.state.selection.to - 2 && t.state.selection.to <= c.to && (h.endB += t.state.selection.to - h.endA, h.endA = t.state.selection.to)), Oe && Lt <= 11 && h.endB == h.start + 1 && h.endA == h.start && h.start > c.from && c.doc.textBetween(h.start - c.from - 1, h.start - c.from + 1) == " " && (h.start--, h.endA--, h.endB--);
|
|
3715
3715
|
let m = c.doc.resolveNoCache(h.start - c.from), g = c.doc.resolveNoCache(h.endB - c.from), b = d.resolve(h.start), w = m.sameParent(g) && m.parent.inlineContent && b.end() >= h.endA, C;
|
|
3716
|
-
if ((Dn && t.input.lastIOSEnter > Date.now() - 225 && (!w || o.some((x) => x.nodeName == "DIV" || x.nodeName == "P")) || !w && m.pos < c.doc.content.size && (!m.sameParent(g) || !m.parent.inlineContent) && (C =
|
|
3716
|
+
if ((Dn && t.input.lastIOSEnter > Date.now() - 225 && (!w || o.some((x) => x.nodeName == "DIV" || x.nodeName == "P")) || !w && m.pos < c.doc.content.size && (!m.sameParent(g) || !m.parent.inlineContent) && (C = Y.findFrom(c.doc.resolve(m.pos + 1), 1, !0)) && C.head > m.pos) && t.someProp("handleKeyDown", (x) => x(t, Gt(13, "Enter")))) {
|
|
3717
3717
|
t.input.lastIOSEnter = 0;
|
|
3718
3718
|
return;
|
|
3719
3719
|
}
|
|
@@ -3737,7 +3737,7 @@ function yh(t, e, n, r, o) {
|
|
|
3737
3737
|
k = t.state.tr, L.type == "add" ? k.addMark(y, S, L.mark) : k.removeMark(y, S, L.mark);
|
|
3738
3738
|
else if (m.parent.child(m.index()).isText && m.index() == g.index() - (g.textOffset ? 0 : 1)) {
|
|
3739
3739
|
let x = m.parent.textBetween(m.parentOffset, g.parentOffset);
|
|
3740
|
-
if (t.someProp("handleTextInput", (
|
|
3740
|
+
if (t.someProp("handleTextInput", (z) => z(t, y, S, x)))
|
|
3741
3741
|
return;
|
|
3742
3742
|
k = t.state.tr.insertText(x, y, S);
|
|
3743
3743
|
}
|
|
@@ -4172,12 +4172,12 @@ function Pa(t) {
|
|
|
4172
4172
|
if (typeof n == "function" && (n = n(t.state)), n)
|
|
4173
4173
|
for (let r in n)
|
|
4174
4174
|
r == "class" ? e.class += " " + n[r] : r == "style" ? e.style = (e.style ? e.style + ";" : "") + n[r] : !e[r] && r != "contenteditable" && r != "nodeName" && (e[r] = String(n[r]));
|
|
4175
|
-
}), e.translate || (e.translate = "no"), [
|
|
4175
|
+
}), e.translate || (e.translate = "no"), [$.node(0, t.state.doc.content.size, e)];
|
|
4176
4176
|
}
|
|
4177
4177
|
function Ra(t) {
|
|
4178
4178
|
if (t.markCursor) {
|
|
4179
4179
|
let e = document.createElement("img");
|
|
4180
|
-
e.className = "ProseMirror-separator", e.setAttribute("mark-placeholder", "true"), e.setAttribute("alt", ""), t.cursorWrapper = { dom: e, deco:
|
|
4180
|
+
e.className = "ProseMirror-separator", e.setAttribute("mark-placeholder", "true"), e.setAttribute("alt", ""), t.cursorWrapper = { dom: e, deco: $.widget(t.state.selection.from, e, { raw: !0, marks: t.markCursor }) };
|
|
4181
4181
|
} else
|
|
4182
4182
|
t.cursorWrapper = null;
|
|
4183
4183
|
}
|
|
@@ -4669,7 +4669,7 @@ e.sv.get(t.id.client) > t.id.clock && !T.isDeleted(e.ds, t.id), Rm = [{ light: "
|
|
|
4669
4669
|
e.head,
|
|
4670
4670
|
n.mapping
|
|
4671
4671
|
);
|
|
4672
|
-
r !== null && o !== null && (t = t.setSelection(
|
|
4672
|
+
r !== null && o !== null && (t = t.setSelection(H.create(t.doc, r, o)));
|
|
4673
4673
|
}
|
|
4674
4674
|
}, Pi = (t, e) => ({
|
|
4675
4675
|
type: (
|
|
@@ -4765,7 +4765,7 @@ class _m {
|
|
|
4765
4765
|
);
|
|
4766
4766
|
if (e) {
|
|
4767
4767
|
const o = _t(Nn(e.anchor, 0), r.doc.content.size), i = _t(Nn(e.head, 0), r.doc.content.size);
|
|
4768
|
-
r.setSelection(
|
|
4768
|
+
r.setSelection(H.create(r.doc, o, i));
|
|
4769
4769
|
}
|
|
4770
4770
|
this.prosemirrorView.dispatch(
|
|
4771
4771
|
r.setMeta(te, { isChangeOrigin: !0, binding: this })
|
|
@@ -5355,14 +5355,14 @@ const qm = () => {
|
|
|
5355
5355
|
if (u !== null && f !== null) {
|
|
5356
5356
|
const p = Nn(t.doc.content.size - 1, 0);
|
|
5357
5357
|
u = _t(u, p), f = _t(f, p), a.push(
|
|
5358
|
-
|
|
5358
|
+
$.widget(f, () => r(d, c), {
|
|
5359
5359
|
key: c + "",
|
|
5360
5360
|
side: 10
|
|
5361
5361
|
})
|
|
5362
5362
|
);
|
|
5363
5363
|
const h = _t(u, f), m = Nn(u, f);
|
|
5364
5364
|
a.push(
|
|
5365
|
-
|
|
5365
|
+
$.inline(h, m, o(d, c), {
|
|
5366
5366
|
inclusiveEnd: !0,
|
|
5367
5367
|
inclusiveStart: !1
|
|
5368
5368
|
})
|
|
@@ -5704,7 +5704,7 @@ function Er(t, e) {
|
|
|
5704
5704
|
return e.nodes[t] ? "node" : e.marks[t] ? "mark" : null;
|
|
5705
5705
|
}
|
|
5706
5706
|
var Bn, Yc, Gc;
|
|
5707
|
-
class
|
|
5707
|
+
class D {
|
|
5708
5708
|
/**
|
|
5709
5709
|
* Get a list of all attributes defined in the extensions.
|
|
5710
5710
|
* @param extensions List of all extensions.
|
|
@@ -5852,7 +5852,7 @@ Bn = new WeakSet(), Yc = function(e, n) {
|
|
|
5852
5852
|
name: i.name,
|
|
5853
5853
|
options: i.options,
|
|
5854
5854
|
storage: i.storage
|
|
5855
|
-
}, a =
|
|
5855
|
+
}, a = N(i, "addGlobalAttributes", s);
|
|
5856
5856
|
if (!a) continue;
|
|
5857
5857
|
const l = a();
|
|
5858
5858
|
for (const c of l)
|
|
@@ -5866,7 +5866,7 @@ Bn = new WeakSet(), Yc = function(e, n) {
|
|
|
5866
5866
|
name: i.name,
|
|
5867
5867
|
options: i.options,
|
|
5868
5868
|
storage: i.storage
|
|
5869
|
-
}, a =
|
|
5869
|
+
}, a = N(i, "addAttributes", s);
|
|
5870
5870
|
if (!a) continue;
|
|
5871
5871
|
const l = a();
|
|
5872
5872
|
for (const [c, d] of Object.entries(l)) {
|
|
@@ -5882,7 +5882,7 @@ Bn = new WeakSet(), Yc = function(e, n) {
|
|
|
5882
5882
|
}
|
|
5883
5883
|
}
|
|
5884
5884
|
return r;
|
|
5885
|
-
}, ft(
|
|
5885
|
+
}, ft(D, Bn);
|
|
5886
5886
|
function mg(t = {}) {
|
|
5887
5887
|
return Object.keys(t).length === 0 && t.constructor === Object;
|
|
5888
5888
|
}
|
|
@@ -5900,7 +5900,7 @@ const lr = class lr {
|
|
|
5900
5900
|
*/
|
|
5901
5901
|
static createSchemaByExtensions(e, n) {
|
|
5902
5902
|
var c, d;
|
|
5903
|
-
const r = e.filter((u) => u.type === "node"), o = e.filter((u) => u.type === "mark"), i = r.find((u) =>
|
|
5903
|
+
const r = e.filter((u) => u.type === "node"), o = e.filter((u) => u.type === "mark"), i = r.find((u) => N(u, "topNode"))?.name, s = D.getAttributesFromExtensions(e), a = I(c = lr, _n, Zc).call(c, r, s, n), l = I(d = lr, _n, Qc).call(d, o, s, n);
|
|
5904
5904
|
return new Yl({ topNode: i, nodes: a, marks: l });
|
|
5905
5905
|
}
|
|
5906
5906
|
};
|
|
@@ -5914,32 +5914,32 @@ _n = new WeakSet(), Zc = function(e, n, r) {
|
|
|
5914
5914
|
}, l = Object.fromEntries(
|
|
5915
5915
|
s.map((h) => [h.name, { default: h?.attribute?.default }])
|
|
5916
5916
|
), c = e.reduce((h, m) => {
|
|
5917
|
-
const g =
|
|
5917
|
+
const g = N(m, "extendNodeSchema", a);
|
|
5918
5918
|
return {
|
|
5919
5919
|
...h,
|
|
5920
5920
|
...g ? g(i) : {}
|
|
5921
5921
|
};
|
|
5922
5922
|
}, {}), d = Bi({
|
|
5923
|
-
content: K(
|
|
5924
|
-
group: K(
|
|
5925
|
-
marks: K(
|
|
5926
|
-
inline: K(
|
|
5927
|
-
atom: K(
|
|
5928
|
-
selectable: K(
|
|
5929
|
-
draggable: K(
|
|
5930
|
-
code: K(
|
|
5931
|
-
defining: K(
|
|
5932
|
-
isolating: K(
|
|
5923
|
+
content: K(N(i, "content", a)),
|
|
5924
|
+
group: K(N(i, "group", a)),
|
|
5925
|
+
marks: K(N(i, "marks", a)),
|
|
5926
|
+
inline: K(N(i, "inline", a)),
|
|
5927
|
+
atom: K(N(i, "atom", a)),
|
|
5928
|
+
selectable: K(N(i, "selectable", a)),
|
|
5929
|
+
draggable: K(N(i, "draggable", a)),
|
|
5930
|
+
code: K(N(i, "code", a)),
|
|
5931
|
+
defining: K(N(i, "defining", a)),
|
|
5932
|
+
isolating: K(N(i, "isolating", a)),
|
|
5933
5933
|
attrs: l,
|
|
5934
5934
|
...c
|
|
5935
|
-
}), u = K(
|
|
5936
|
-
u && (d.parseDOM = u.map((h) =>
|
|
5937
|
-
const f =
|
|
5935
|
+
}), u = K(N(i, "parseDOM", a));
|
|
5936
|
+
u && (d.parseDOM = u.map((h) => D.insertExtensionAttrsToParseRule(h, s)));
|
|
5937
|
+
const f = N(i, "renderDOM", a);
|
|
5938
5938
|
f && (d.toDOM = (h) => f({
|
|
5939
5939
|
node: h,
|
|
5940
|
-
htmlAttributes:
|
|
5940
|
+
htmlAttributes: D.getAttributesToRender(h, s)
|
|
5941
5941
|
}));
|
|
5942
|
-
const p =
|
|
5942
|
+
const p = N(i, "renderText", a);
|
|
5943
5943
|
return p && (d.toText = p), [i.name, d];
|
|
5944
5944
|
});
|
|
5945
5945
|
return Object.fromEntries(o);
|
|
@@ -5953,18 +5953,18 @@ _n = new WeakSet(), Zc = function(e, n, r) {
|
|
|
5953
5953
|
}, l = Object.fromEntries(
|
|
5954
5954
|
s.map((f) => [f.name, { default: f?.attribute?.default }])
|
|
5955
5955
|
), c = Bi({
|
|
5956
|
-
group: K(
|
|
5957
|
-
inclusive: K(
|
|
5958
|
-
excludes: K(
|
|
5959
|
-
spanning: K(
|
|
5960
|
-
code: K(
|
|
5956
|
+
group: K(N(i, "group", a)),
|
|
5957
|
+
inclusive: K(N(i, "inclusive", a)),
|
|
5958
|
+
excludes: K(N(i, "excludes", a)),
|
|
5959
|
+
spanning: K(N(i, "spanning", a)),
|
|
5960
|
+
code: K(N(i, "code", a)),
|
|
5961
5961
|
attrs: l
|
|
5962
|
-
}), d = K(
|
|
5963
|
-
d && (c.parseDOM = d.map((f) =>
|
|
5964
|
-
const u =
|
|
5962
|
+
}), d = K(N(i, "parseDOM", a));
|
|
5963
|
+
d && (c.parseDOM = d.map((f) => D.insertExtensionAttrsToParseRule(f, s)));
|
|
5964
|
+
const u = N(i, "renderDOM", a);
|
|
5965
5965
|
return u && (c.toDOM = (f) => u({
|
|
5966
5966
|
mark: f,
|
|
5967
|
-
htmlAttributes:
|
|
5967
|
+
htmlAttributes: D.getAttributesToRender(f, s)
|
|
5968
5968
|
})), [i.name, c];
|
|
5969
5969
|
});
|
|
5970
5970
|
return Object.fromEntries(o);
|
|
@@ -6267,7 +6267,7 @@ const Mn = class Mn {
|
|
|
6267
6267
|
*/
|
|
6268
6268
|
static sortByPriority(e) {
|
|
6269
6269
|
return e.sort((r, o) => {
|
|
6270
|
-
const i =
|
|
6270
|
+
const i = N(r, "priority") || 100, s = N(o, "priority") || 100;
|
|
6271
6271
|
return i > s ? -1 : i < s ? 1 : 0;
|
|
6272
6272
|
});
|
|
6273
6273
|
}
|
|
@@ -6276,7 +6276,7 @@ const Mn = class Mn {
|
|
|
6276
6276
|
* @returns Array of attributes.
|
|
6277
6277
|
*/
|
|
6278
6278
|
get attributes() {
|
|
6279
|
-
return
|
|
6279
|
+
return D.getAttributesFromExtensions(this.extensions);
|
|
6280
6280
|
}
|
|
6281
6281
|
/**
|
|
6282
6282
|
* Get all commands defined in the extensions.
|
|
@@ -6291,7 +6291,7 @@ const Mn = class Mn {
|
|
|
6291
6291
|
storage: n.storage,
|
|
6292
6292
|
editor: this.editor,
|
|
6293
6293
|
type: Yn(n.name, this.schema)
|
|
6294
|
-
}, o =
|
|
6294
|
+
}, o = N(n, "addCommands", r);
|
|
6295
6295
|
o && (e = {
|
|
6296
6296
|
...e,
|
|
6297
6297
|
...o()
|
|
@@ -6312,16 +6312,16 @@ const Mn = class Mn {
|
|
|
6312
6312
|
storage: i.storage,
|
|
6313
6313
|
editor: e,
|
|
6314
6314
|
type: Yn(i.name, this.schema)
|
|
6315
|
-
}, a = [], l =
|
|
6315
|
+
}, a = [], l = N(i, "addShortcuts", s);
|
|
6316
6316
|
let c = {};
|
|
6317
6317
|
if (l) {
|
|
6318
6318
|
const f = Object.entries(l()).map(([p, h]) => [p, (...m) => h({ editor: e, keymapArgs: m })]);
|
|
6319
6319
|
c = { ...Object.fromEntries(f) };
|
|
6320
6320
|
}
|
|
6321
6321
|
a.push(hg(c));
|
|
6322
|
-
const d =
|
|
6322
|
+
const d = N(i, "addInputRules", s);
|
|
6323
6323
|
gg(i, e.options.enableInputRules) && d && r.push(...d());
|
|
6324
|
-
const u =
|
|
6324
|
+
const u = N(i, "addPmPlugins", s);
|
|
6325
6325
|
if (u) {
|
|
6326
6326
|
const f = u();
|
|
6327
6327
|
a.push(...f);
|
|
@@ -6341,17 +6341,17 @@ const Mn = class Mn {
|
|
|
6341
6341
|
* @returns An object with all node views.
|
|
6342
6342
|
*/
|
|
6343
6343
|
get nodeViews() {
|
|
6344
|
-
const { editor: e } = this, r = this.extensions.filter((o) => o.type === "node").filter((o) => !!
|
|
6344
|
+
const { editor: e } = this, r = this.extensions.filter((o) => o.type === "node").filter((o) => !!N(o, "addNodeView")).map((o) => {
|
|
6345
6345
|
const i = this.attributes.filter((c) => c.type === o.name), s = {
|
|
6346
6346
|
name: o.name,
|
|
6347
6347
|
options: o.options,
|
|
6348
6348
|
storage: o.storage,
|
|
6349
6349
|
editor: e,
|
|
6350
6350
|
type: le(o.name, this.schema)
|
|
6351
|
-
}, a =
|
|
6351
|
+
}, a = N(o, "addNodeView", s);
|
|
6352
6352
|
if (!a) return [];
|
|
6353
6353
|
const l = (c, d, u, f) => {
|
|
6354
|
-
const p =
|
|
6354
|
+
const p = D.getAttributesToRender(c, i);
|
|
6355
6355
|
return a()({
|
|
6356
6356
|
editor: e,
|
|
6357
6357
|
node: c,
|
|
@@ -6380,7 +6380,7 @@ ed = function() {
|
|
|
6380
6380
|
editor: this.editor,
|
|
6381
6381
|
type: Yn(e.name, this.schema)
|
|
6382
6382
|
};
|
|
6383
|
-
e.type === "mark" && (K(
|
|
6383
|
+
e.type === "mark" && (K(N(e, "keepOnSplit", n)) ?? !0) && this.splittableMarks.push(e.name), I(this, zn, td).call(this, e);
|
|
6384
6384
|
}
|
|
6385
6385
|
}, /**
|
|
6386
6386
|
* Attach editor events to extension
|
|
@@ -6394,7 +6394,7 @@ td = function(e) {
|
|
|
6394
6394
|
storage: e.storage,
|
|
6395
6395
|
editor: this.editor,
|
|
6396
6396
|
type: Yn(e.name, this.schema)
|
|
6397
|
-
}, r =
|
|
6397
|
+
}, r = N(e, "onBeforeCreate", n), o = N(e, "onCreate", n), i = N(e, "onUpdate", n), s = N(e, "onSelectionUpdate", n), a = N(e, "onTransaction", n), l = N(e, "onFocus", n), c = N(e, "onBlur", n), d = N(e, "onDestroy", n);
|
|
6398
6398
|
r && this.editor.on("beforeCreate", r), o && this.editor.on("create", o), i && this.editor.on("update", i), s && this.editor.on("selectionUpdate", s), a && this.editor.on("transaction", a), l && this.editor.on("focus", l), c && this.editor.on("blur", c), d && this.editor.on("destroy", d);
|
|
6399
6399
|
};
|
|
6400
6400
|
let zi = Mn;
|
|
@@ -6430,7 +6430,7 @@ const nd = (t, e, n) => {
|
|
|
6430
6430
|
if (a && a.slice.size < a.to - a.from) {
|
|
6431
6431
|
if (e) {
|
|
6432
6432
|
let l = t.tr.step(a);
|
|
6433
|
-
l.setSelection(In(i, "end") ?
|
|
6433
|
+
l.setSelection(In(i, "end") ? Y.findFrom(l.doc.resolve(l.mapping.map(o.pos, -1)), -1) : B.create(l.doc, o.pos - i.nodeSize)), e(l.scrollIntoView());
|
|
6434
6434
|
}
|
|
6435
6435
|
return !0;
|
|
6436
6436
|
}
|
|
@@ -6489,7 +6489,7 @@ const id = (t, e, n) => {
|
|
|
6489
6489
|
if (s && s.slice.size < s.to - s.from) {
|
|
6490
6490
|
if (e) {
|
|
6491
6491
|
let a = t.tr.step(s);
|
|
6492
|
-
a.setSelection(In(i, "start") ?
|
|
6492
|
+
a.setSelection(In(i, "start") ? Y.findFrom(a.doc.resolve(a.mapping.map(o.pos)), 1) : B.create(a.doc, a.mapping.map(o.pos))), e(a.scrollIntoView());
|
|
6493
6493
|
}
|
|
6494
6494
|
return !0;
|
|
6495
6495
|
}
|
|
@@ -6562,7 +6562,7 @@ const Eg = (t, e) => {
|
|
|
6562
6562
|
return !1;
|
|
6563
6563
|
if (e) {
|
|
6564
6564
|
let a = n.after(), l = t.tr.replaceWith(a, a, s.createAndFill());
|
|
6565
|
-
l.setSelection(
|
|
6565
|
+
l.setSelection(Y.near(l.doc.resolve(a), 1)), e(l.scrollIntoView());
|
|
6566
6566
|
}
|
|
6567
6567
|
return !0;
|
|
6568
6568
|
}, cd = (t, e) => {
|
|
@@ -6574,7 +6574,7 @@ const Eg = (t, e) => {
|
|
|
6574
6574
|
return !1;
|
|
6575
6575
|
if (e) {
|
|
6576
6576
|
let s = (!r.parentOffset && o.index() < o.parent.childCount ? r : o).pos, a = t.tr.insert(s, i.createAndFill());
|
|
6577
|
-
a.setSelection(
|
|
6577
|
+
a.setSelection(H.create(a.doc, s + 1)), e(a.scrollIntoView());
|
|
6578
6578
|
}
|
|
6579
6579
|
return !0;
|
|
6580
6580
|
}, dd = (t, e) => {
|
|
@@ -6607,7 +6607,7 @@ function Ig(t) {
|
|
|
6607
6607
|
i.unshift(null);
|
|
6608
6608
|
}
|
|
6609
6609
|
let d = e.tr;
|
|
6610
|
-
(e.selection instanceof
|
|
6610
|
+
(e.selection instanceof H || e.selection instanceof Ar) && d.deleteSelection();
|
|
6611
6611
|
let u = d.mapping.map(r.pos), f = wt(d.doc, u, i.length, i);
|
|
6612
6612
|
if (f || (i[0] = a ? { type: a } : null, f = wt(d.doc, u, i.length, i)), d.split(u, i.length, i), !l && c && r.node(s).type != a) {
|
|
6613
6613
|
let p = d.mapping.map(r.before(s)), h = d.doc.resolve(p);
|
|
@@ -6637,7 +6637,7 @@ function ud(t, e, n, r) {
|
|
|
6637
6637
|
}
|
|
6638
6638
|
return !0;
|
|
6639
6639
|
}
|
|
6640
|
-
let d = i.type.spec.isolating || r > 0 && l ? null :
|
|
6640
|
+
let d = i.type.spec.isolating || r > 0 && l ? null : Y.findFrom(e, 1), u = d && d.$from.blockRange(d.$to), f = u && Or(u);
|
|
6641
6641
|
if (f != null && f >= e.depth)
|
|
6642
6642
|
return n && n(t.tr.lift(u, f).scrollIntoView()), !0;
|
|
6643
6643
|
if (c && In(i, "start", !0) && In(o, "end")) {
|
|
@@ -6668,7 +6668,7 @@ function fd(t) {
|
|
|
6668
6668
|
return !1;
|
|
6669
6669
|
i--;
|
|
6670
6670
|
}
|
|
6671
|
-
return o.node(i).isTextblock ? (n && n(e.tr.setSelection(
|
|
6671
|
+
return o.node(i).isTextblock ? (n && n(e.tr.setSelection(H.create(e.doc, t < 0 ? o.start(i) : o.end(i)))), !0) : !1;
|
|
6672
6672
|
};
|
|
6673
6673
|
}
|
|
6674
6674
|
const Fg = fd(-1), Bg = fd(1);
|
|
@@ -6728,13 +6728,13 @@ const Ka = (t, e) => {
|
|
|
6728
6728
|
t.tr.ensureMarks(r);
|
|
6729
6729
|
}
|
|
6730
6730
|
}, _g = ({ keepMarks: t = !0 } = {}) => (e) => {
|
|
6731
|
-
const { tr: n, state: r, dispatch: o, editor: i } = e, { selection: s, doc: a } = n, { $from: l, $to: c } = s, d = i.extensionService.attributes, u =
|
|
6731
|
+
const { tr: n, state: r, dispatch: o, editor: i } = e, { selection: s, doc: a } = n, { $from: l, $to: c } = s, d = i.extensionService.attributes, u = D.getSplittedAttributes(d, l.node().type.name, l.node().attrs);
|
|
6732
6732
|
if (s instanceof B && s.node.isBlock)
|
|
6733
6733
|
return !l.parentOffset || !wt(a, l.pos) ? !1 : (o && (t && Ka(r, i.extensionService.splittableMarks), n.split(l.pos).scrollIntoView()), !0);
|
|
6734
6734
|
if (!l.parent.isBlock) return !1;
|
|
6735
6735
|
if (o) {
|
|
6736
6736
|
const f = c.parentOffset === c.parent.content.size;
|
|
6737
|
-
s instanceof
|
|
6737
|
+
s instanceof H && n.deleteSelection();
|
|
6738
6738
|
const p = l.depth === 0 ? null : pd(l.node(-1).contentMatchAt(l.indexAfter(-1)));
|
|
6739
6739
|
let h = f && p ? [{ type: p, attrs: u }] : void 0, m = wt(n.doc, n.mapping.map(l.pos), 1, h);
|
|
6740
6740
|
if (!h && !m && wt(n.doc, n.mapping.map(l.pos), 1, p ? [{ type: p }] : void 0) && (m = !0, h = p ? [{ type: p, attrs: u }] : void 0), m && (n.split(n.mapping.map(l.pos), 1, h), p && !f && !l.parentOffset && l.parent.type !== p)) {
|
|
@@ -6769,7 +6769,7 @@ const Wg = (t, e = {}) => ({ tr: n, state: r, dispatch: o }) => {
|
|
|
6769
6769
|
const { selection: i } = n, { empty: s, ranges: a } = i, l = xt(t, r.schema);
|
|
6770
6770
|
if (o)
|
|
6771
6771
|
if (s) {
|
|
6772
|
-
const c =
|
|
6772
|
+
const c = D.getMarkAttributes(r, l);
|
|
6773
6773
|
n.addStoredMark(
|
|
6774
6774
|
l.create({
|
|
6775
6775
|
...c,
|
|
@@ -7001,7 +7001,7 @@ function uy(t, e, n) {
|
|
|
7001
7001
|
let s = 0;
|
|
7002
7002
|
i.forEach((a, l, c, d) => {
|
|
7003
7003
|
s === 0 && (s = d);
|
|
7004
|
-
}), t.setSelection(
|
|
7004
|
+
}), t.setSelection(Y.near(t.doc.resolve(s), n));
|
|
7005
7005
|
}
|
|
7006
7006
|
const fy = (t) => !("type" in t), py = (t, e, n) => ({ tr: r, dispatch: o, editor: i }) => {
|
|
7007
7007
|
if (o) {
|
|
@@ -7163,7 +7163,7 @@ const Cy = (t, e = {}) => ({ state: n, dispatch: r }) => {
|
|
|
7163
7163
|
name: r.name,
|
|
7164
7164
|
options: r.options,
|
|
7165
7165
|
storage: r.storage
|
|
7166
|
-
}, i = K(
|
|
7166
|
+
}, i = K(N(r, "group", o));
|
|
7167
7167
|
return typeof i != "string" ? !1 : i.split(" ").includes("list");
|
|
7168
7168
|
}, Sy = {
|
|
7169
7169
|
type: "element",
|
|
@@ -8335,12 +8335,12 @@ const Cy = (t, e = {}) => ({ state: n, dispatch: r }) => {
|
|
|
8335
8335
|
return c().command(() => (s.setNodeMarkup(k.pos, h), !0)).command(() => ai(s, h)).command(() => li(s, h)).run();
|
|
8336
8336
|
}
|
|
8337
8337
|
const L = ({ ensureMarks: _ = !1 }) => () => {
|
|
8338
|
-
const
|
|
8338
|
+
const V = d().wrapInList(h, r);
|
|
8339
8339
|
if (_) {
|
|
8340
8340
|
const j = S.filter((se) => p.includes(se.type.name));
|
|
8341
8341
|
s.ensureMarks(j);
|
|
8342
8342
|
}
|
|
8343
|
-
return
|
|
8343
|
+
return V ? !0 : u.clearNodes();
|
|
8344
8344
|
}, x = gd(M.definitions);
|
|
8345
8345
|
return i.converter.numbering = Ay(x, M, h), r.listId = x, !n || !S || !l ? c().command(L({ ensureMarks: !1 })).wrapInList(h, r).command(() => ai(s, h)).command(() => li(s, h)).run() : c().command(L({ ensureMarks: !0 })).wrapInList(h, r).command(() => ai(s, h)).command(() => li(s, h)).run();
|
|
8346
8346
|
}, gd = (t) => Math.max(...Object.keys(t).map(Number)) + 1, Ay = (t, e, n) => {
|
|
@@ -8384,7 +8384,7 @@ const Cy = (t, e = {}) => ({ state: n, dispatch: r }) => {
|
|
|
8384
8384
|
const b = a.index(-1) ? 1 : a.index(-2) ? 2 : 3;
|
|
8385
8385
|
for (let M = a.depth - b; M >= a.depth - 3; M--)
|
|
8386
8386
|
g = E.from(a.node(M).copy(g));
|
|
8387
|
-
const w = a.indexAfter(-1) < a.node(-2).childCount ? 1 : a.indexAfter(-2) < a.node(-3).childCount ? 2 : 3, C =
|
|
8387
|
+
const w = a.indexAfter(-1) < a.node(-2).childCount ? 1 : a.indexAfter(-2) < a.node(-3).childCount ? 2 : 3, C = D.getSplittedAttributes(
|
|
8388
8388
|
u,
|
|
8389
8389
|
a.node().type.name,
|
|
8390
8390
|
a.node().attrs
|
|
@@ -8396,11 +8396,11 @@ const Cy = (t, e = {}) => ({ state: n, dispatch: r }) => {
|
|
|
8396
8396
|
n.doc.nodesBetween(S, n.doc.content.size, (M, L) => {
|
|
8397
8397
|
if (k > -1) return !1;
|
|
8398
8398
|
M.isTextblock && M.content.size === 0 && (k = L + 1);
|
|
8399
|
-
}), k > -1 && n.setSelection(
|
|
8399
|
+
}), k > -1 && n.setSelection(H.near(n.doc.resolve(k))), n.scrollIntoView();
|
|
8400
8400
|
}
|
|
8401
8401
|
return !0;
|
|
8402
8402
|
}
|
|
8403
|
-
const f = l.pos === a.end() ? d.contentMatchAt(0).defaultType : null, p =
|
|
8403
|
+
const f = l.pos === a.end() ? d.contentMatchAt(0).defaultType : null, p = D.getSplittedAttributes(u, d.type.name, d.attrs), h = D.getSplittedAttributes(
|
|
8404
8404
|
u,
|
|
8405
8405
|
a.node().type.name,
|
|
8406
8406
|
a.node().attrs
|
|
@@ -8761,7 +8761,7 @@ const Cd = (t) => {
|
|
|
8761
8761
|
generateDocxRandomId: kn,
|
|
8762
8762
|
generateRandom32BitHex: kf,
|
|
8763
8763
|
getActiveFormatting: Ef,
|
|
8764
|
-
getExtensionConfigField:
|
|
8764
|
+
getExtensionConfigField: N,
|
|
8765
8765
|
getMarkRange: Ps,
|
|
8766
8766
|
getMarkType: xt,
|
|
8767
8767
|
getMarksBetween: $y,
|
|
@@ -8884,39 +8884,39 @@ const Cd = (t) => {
|
|
|
8884
8884
|
return o.length ? (o.forEach(({ mark: i, from: s, to: a }) => {
|
|
8885
8885
|
if (i.type.name === $e)
|
|
8886
8886
|
if (e) {
|
|
8887
|
-
const l =
|
|
8887
|
+
const l = $.inline(s, a, {
|
|
8888
8888
|
class: "track-insert-dec hidden"
|
|
8889
8889
|
});
|
|
8890
8890
|
r.push(l);
|
|
8891
8891
|
} else if (n) {
|
|
8892
|
-
const l =
|
|
8892
|
+
const l = $.inline(s, a, {
|
|
8893
8893
|
class: "track-insert-dec normal"
|
|
8894
8894
|
});
|
|
8895
8895
|
r.push(l);
|
|
8896
8896
|
} else {
|
|
8897
|
-
const l =
|
|
8897
|
+
const l = $.inline(s, a, {
|
|
8898
8898
|
class: "track-insert-dec highlighted"
|
|
8899
8899
|
});
|
|
8900
8900
|
r.push(l);
|
|
8901
8901
|
}
|
|
8902
8902
|
if (i.type.name === ue)
|
|
8903
8903
|
if (e) {
|
|
8904
|
-
const l =
|
|
8904
|
+
const l = $.inline(s, a, {
|
|
8905
8905
|
class: "track-delete-dec normal"
|
|
8906
8906
|
});
|
|
8907
8907
|
r.push(l);
|
|
8908
8908
|
} else if (n) {
|
|
8909
|
-
const l =
|
|
8909
|
+
const l = $.inline(s, a, {
|
|
8910
8910
|
class: "track-delete-dec hidden"
|
|
8911
8911
|
});
|
|
8912
8912
|
r.push(l);
|
|
8913
8913
|
} else {
|
|
8914
|
-
const l =
|
|
8914
|
+
const l = $.inline(s, a, {
|
|
8915
8915
|
class: "track-delete-dec highlighted"
|
|
8916
8916
|
// 'hidden'
|
|
8917
8917
|
});
|
|
8918
8918
|
r.push(l);
|
|
8919
|
-
const c =
|
|
8919
|
+
const c = $.widget(
|
|
8920
8920
|
s,
|
|
8921
8921
|
() => {
|
|
8922
8922
|
const d = document.createElement("span");
|
|
@@ -8928,17 +8928,17 @@ const Cd = (t) => {
|
|
|
8928
8928
|
}
|
|
8929
8929
|
if (i.type.name === Se)
|
|
8930
8930
|
if (e) {
|
|
8931
|
-
const l =
|
|
8931
|
+
const l = $.inline(s, a, {
|
|
8932
8932
|
class: "track-format-dec before"
|
|
8933
8933
|
});
|
|
8934
8934
|
r.push(l);
|
|
8935
8935
|
} else if (n) {
|
|
8936
|
-
const l =
|
|
8936
|
+
const l = $.inline(s, a, {
|
|
8937
8937
|
class: "track-format-dec normal"
|
|
8938
8938
|
});
|
|
8939
8939
|
r.push(l);
|
|
8940
8940
|
} else {
|
|
8941
|
-
const l =
|
|
8941
|
+
const l = $.inline(s, a, {
|
|
8942
8942
|
class: "track-format-dec highlighted"
|
|
8943
8943
|
});
|
|
8944
8944
|
r.push(l);
|
|
@@ -9097,7 +9097,7 @@ const Cd = (t) => {
|
|
|
9097
9097
|
editable: !1,
|
|
9098
9098
|
element: r,
|
|
9099
9099
|
content: e,
|
|
9100
|
-
extensions:
|
|
9100
|
+
extensions: Rk(),
|
|
9101
9101
|
documentId: "sectionId"
|
|
9102
9102
|
});
|
|
9103
9103
|
c.on("create", () => {
|
|
@@ -9237,19 +9237,19 @@ const Cd = (t) => {
|
|
|
9237
9237
|
);
|
|
9238
9238
|
let S = !1;
|
|
9239
9239
|
y.forEach((M) => {
|
|
9240
|
-
const { attrs: L } = M, x = L.commentId || L.importedId,
|
|
9240
|
+
const { attrs: L } = M, x = L.commentId || L.importedId, z = s.coordsAtPos(w);
|
|
9241
9241
|
Za({
|
|
9242
9242
|
allCommentPositions: f,
|
|
9243
9243
|
threadId: x,
|
|
9244
9244
|
pos: w,
|
|
9245
|
-
currentBounds:
|
|
9245
|
+
currentBounds: z,
|
|
9246
9246
|
node: b
|
|
9247
9247
|
});
|
|
9248
9248
|
const _ = L.internal;
|
|
9249
9249
|
S || (S = n === x);
|
|
9250
|
-
let
|
|
9251
|
-
const j =
|
|
9252
|
-
style: `background-color: ${
|
|
9250
|
+
let V = Xy({ activeThreadId: n, threadId: x, isInternal: _, editor: t });
|
|
9251
|
+
const j = $.inline(w, w + b.nodeSize, {
|
|
9252
|
+
style: `background-color: ${V};`,
|
|
9253
9253
|
"data-thread-id": x,
|
|
9254
9254
|
class: "comment-highlight"
|
|
9255
9255
|
});
|
|
@@ -9615,17 +9615,17 @@ const Td = ({ state: t, tr: e, step: n, newTr: r, map: o, doc: i, user: s, date:
|
|
|
9615
9615
|
}), console.debug("[track-changes]: removeMarkStep")) : (i.step(u), console.log("[track-changes]: otherStep")));
|
|
9616
9616
|
}), t.getMeta("inputType") && i.setMeta(t.getMeta("inputType")), t.getMeta("uiEvent") && i.setMeta(t.getMeta("uiEvent")), t.selectionSet) {
|
|
9617
9617
|
const c = e.schema.marks[ue], d = Eo(e, c, !1);
|
|
9618
|
-
if (t.selection instanceof
|
|
9618
|
+
if (t.selection instanceof H && (t.selection.from < e.selection.from || t.getMeta("inputType") === "deleteContentBackward")) {
|
|
9619
9619
|
const u = s.map(t.selection.from, -1);
|
|
9620
|
-
i.setSelection(new
|
|
9620
|
+
i.setSelection(new H(i.doc.resolve(u)));
|
|
9621
9621
|
} else if (t.selection.from > e.selection.from && d) {
|
|
9622
9622
|
const u = s.map(d.to + 1, 1);
|
|
9623
|
-
i.setSelection(new
|
|
9623
|
+
i.setSelection(new H(i.doc.resolve(u)));
|
|
9624
9624
|
} else
|
|
9625
9625
|
i.setSelection(t.selection.map(i.doc, s));
|
|
9626
9626
|
} else if (e.selection.from - t.selection.from > 1 && t.selection.$head.depth > 1) {
|
|
9627
9627
|
const c = s.map(t.selection.from - 2, -1);
|
|
9628
|
-
i.setSelection(new
|
|
9628
|
+
i.setSelection(new H(i.doc.resolve(c)));
|
|
9629
9629
|
}
|
|
9630
9630
|
return t.storedMarksSet && i.setStoredMarks(t.storedMarks), t.scrolledIntoView && i.scrollIntoView(), i;
|
|
9631
9631
|
}, ob = (t) => {
|
|
@@ -9917,7 +9917,7 @@ const Js = class Js extends ag {
|
|
|
9917
9917
|
* editor.getAttributes('textStyle').color
|
|
9918
9918
|
*/
|
|
9919
9919
|
getAttributes(n) {
|
|
9920
|
-
return
|
|
9920
|
+
return D.getAttributes(this.state, n);
|
|
9921
9921
|
}
|
|
9922
9922
|
/**
|
|
9923
9923
|
* Returns if the currently selected node or mark is active.
|
|
@@ -10018,7 +10018,7 @@ const Js = class Js extends ag {
|
|
|
10018
10018
|
* @returns {Y.Doc | undefined} Updated Y.Doc if any, otherwise undefined
|
|
10019
10019
|
*/
|
|
10020
10020
|
processCollaborationMigrations() {
|
|
10021
|
-
if (console.debug("[checkVersionMigrations] Current editor version", "0.9.
|
|
10021
|
+
if (console.debug("[checkVersionMigrations] Current editor version", "0.9.31"), !this.options.ydoc) return;
|
|
10022
10022
|
let r = this.options.ydoc.getMap("meta").get("version");
|
|
10023
10023
|
r || (r = "initial"), console.debug("[checkVersionMigrations] Document version", r);
|
|
10024
10024
|
const o = Qa(r) || [], s = this.state.plugins.find((c) => c.key.startsWith("y-sync"));
|
|
@@ -10048,7 +10048,7 @@ en = new WeakMap(), ms = new WeakMap(), O = new WeakSet(), Id = function(n) {
|
|
|
10048
10048
|
this.isDestroyed || this.emit("create", { editor: this });
|
|
10049
10049
|
}, 0));
|
|
10050
10050
|
}, Pd = function(n) {
|
|
10051
|
-
(!n.extensions || !n.extensions.length) && (this.options.extensions =
|
|
10051
|
+
(!n.extensions || !n.extensions.length) && (this.options.extensions = Pk()), I(this, O, Ki).call(this), I(this, O, Xi).call(this), I(this, O, Gi).call(this), this.on("beforeCreate", this.options.onBeforeCreate), this.emit("beforeCreate", { editor: this }), this.on("contentError", this.options.onContentError), I(this, O, Qi).call(this), 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", I(this, O, Wi)), this.on("blur", this.options.onBlur), this.on("destroy", this.options.onDestroy), this.on("commentsLoaded", this.options.onCommentsLoaded), this.on("commentClick", this.options.onCommentClicked), this.on("locked", this.options.onDocumentLocked), window.setTimeout(() => {
|
|
10052
10052
|
this.isDestroyed || this.emit("create", { editor: this });
|
|
10053
10053
|
}, 0);
|
|
10054
10054
|
}, Wi = function({ editor: n, event: r }) {
|
|
@@ -10249,7 +10249,7 @@ zd = function() {
|
|
|
10249
10249
|
}
|
|
10250
10250
|
};
|
|
10251
10251
|
let ji = Js;
|
|
10252
|
-
class
|
|
10252
|
+
class J {
|
|
10253
10253
|
constructor(e) {
|
|
10254
10254
|
P(this, "type", "node");
|
|
10255
10255
|
P(this, "name", "node");
|
|
@@ -10262,11 +10262,11 @@ class Y {
|
|
|
10262
10262
|
...this.config,
|
|
10263
10263
|
...e
|
|
10264
10264
|
}, this.name = this.config.name, this.config.addOptions && (this.options = K(
|
|
10265
|
-
|
|
10265
|
+
N(this, "addOptions", {
|
|
10266
10266
|
name: this.name
|
|
10267
10267
|
})
|
|
10268
10268
|
)), this.storage = K(
|
|
10269
|
-
|
|
10269
|
+
N(this, "addStorage", {
|
|
10270
10270
|
name: this.name,
|
|
10271
10271
|
options: this.options
|
|
10272
10272
|
})
|
|
@@ -10277,7 +10277,7 @@ class Y {
|
|
|
10277
10277
|
* @param args Arguments for the constructor.
|
|
10278
10278
|
*/
|
|
10279
10279
|
static create(...e) {
|
|
10280
|
-
return new
|
|
10280
|
+
return new J(...e);
|
|
10281
10281
|
}
|
|
10282
10282
|
}
|
|
10283
10283
|
class Le {
|
|
@@ -10293,11 +10293,11 @@ class Le {
|
|
|
10293
10293
|
...this.config,
|
|
10294
10294
|
...e
|
|
10295
10295
|
}, this.name = this.config.name, this.config.addOptions && (this.options = K(
|
|
10296
|
-
|
|
10296
|
+
N(this, "addOptions", {
|
|
10297
10297
|
name: this.name
|
|
10298
10298
|
})
|
|
10299
10299
|
)), this.storage = K(
|
|
10300
|
-
|
|
10300
|
+
N(this, "addStorage", {
|
|
10301
10301
|
name: this.name,
|
|
10302
10302
|
options: this.options
|
|
10303
10303
|
})
|
|
@@ -10688,7 +10688,7 @@ const Kd = Q.create({
|
|
|
10688
10688
|
return [lb(this.options)];
|
|
10689
10689
|
}
|
|
10690
10690
|
});
|
|
10691
|
-
class re extends
|
|
10691
|
+
class re extends Y {
|
|
10692
10692
|
/**
|
|
10693
10693
|
Create a gap cursor.
|
|
10694
10694
|
*/
|
|
@@ -10697,7 +10697,7 @@ class re extends J {
|
|
|
10697
10697
|
}
|
|
10698
10698
|
map(e, n) {
|
|
10699
10699
|
let r = e.resolve(n.map(this.head));
|
|
10700
|
-
return re.valid(r) ? new re(r) :
|
|
10700
|
+
return re.valid(r) ? new re(r) : Y.near(r);
|
|
10701
10701
|
}
|
|
10702
10702
|
content() {
|
|
10703
10703
|
return W.empty;
|
|
@@ -10775,7 +10775,7 @@ class re extends J {
|
|
|
10775
10775
|
}
|
|
10776
10776
|
re.prototype.visible = !1;
|
|
10777
10777
|
re.findFrom = re.findGapCursorFrom;
|
|
10778
|
-
|
|
10778
|
+
Y.jsonID("gapcursor", re);
|
|
10779
10779
|
class _s {
|
|
10780
10780
|
constructor(e) {
|
|
10781
10781
|
this.pos = e;
|
|
@@ -10785,7 +10785,7 @@ class _s {
|
|
|
10785
10785
|
}
|
|
10786
10786
|
resolve(e) {
|
|
10787
10787
|
let n = e.resolve(this.pos);
|
|
10788
|
-
return re.valid(n) ? new re(n) :
|
|
10788
|
+
return re.valid(n) ? new re(n) : Y.near(n);
|
|
10789
10789
|
}
|
|
10790
10790
|
}
|
|
10791
10791
|
function db(t) {
|
|
@@ -10845,7 +10845,7 @@ function Xr(t, e) {
|
|
|
10845
10845
|
const n = t == "vert" ? e > 0 ? "down" : "up" : e > 0 ? "right" : "left";
|
|
10846
10846
|
return function(r, o, i) {
|
|
10847
10847
|
let s = r.selection, a = e > 0 ? s.$to : s.$from, l = s.empty;
|
|
10848
|
-
if (s instanceof
|
|
10848
|
+
if (s instanceof H) {
|
|
10849
10849
|
if (!i.endOfTextblock(n) || a.depth == 0)
|
|
10850
10850
|
return !1;
|
|
10851
10851
|
l = !1, a = r.doc.resolve(e > 0 ? a.after() : a.before());
|
|
@@ -10873,13 +10873,13 @@ function mb(t, e) {
|
|
|
10873
10873
|
for (let s = r.length - 1; s >= 0; s--)
|
|
10874
10874
|
o = E.from(r[s].createAndFill(null, o));
|
|
10875
10875
|
let i = t.state.tr.replace(n.pos, n.pos, new W(o, 0, 0));
|
|
10876
|
-
return i.setSelection(
|
|
10876
|
+
return i.setSelection(H.near(i.doc.resolve(n.pos + 1))), t.dispatch(i), !1;
|
|
10877
10877
|
}
|
|
10878
10878
|
function gb(t) {
|
|
10879
10879
|
if (!(t.selection instanceof re))
|
|
10880
10880
|
return null;
|
|
10881
10881
|
let e = document.createElement("div");
|
|
10882
|
-
return e.className = "ProseMirror-gapcursor", F.create(t.doc, [
|
|
10882
|
+
return e.className = "ProseMirror-gapcursor", F.create(t.doc, [$.widget(t.selection.head, e, { key: "gapcursor" })]);
|
|
10883
10883
|
}
|
|
10884
10884
|
const yb = Q.create({
|
|
10885
10885
|
name: "gapCursor",
|
|
@@ -10890,7 +10890,7 @@ const yb = Q.create({
|
|
|
10890
10890
|
},
|
|
10891
10891
|
extendNodeSchema(t) {
|
|
10892
10892
|
return {
|
|
10893
|
-
allowGapCursor: K(
|
|
10893
|
+
allowGapCursor: K(N(t, "allowGapCursor", {
|
|
10894
10894
|
name: t.name,
|
|
10895
10895
|
options: t.options,
|
|
10896
10896
|
storage: t.storage
|
|
@@ -10996,7 +10996,7 @@ const yb = Q.create({
|
|
|
10996
10996
|
e.classList.add("ProseMirror-yjs-cursor"), e.setAttribute("style", `border-color: ${t.color}`);
|
|
10997
10997
|
const n = document.createElement("div");
|
|
10998
10998
|
return n.setAttribute("style", `background-color: ${t.color}`), n.insertBefore(document.createTextNode(t.name || t.email), null), e.insertBefore(n, null), e;
|
|
10999
|
-
}, Xd =
|
|
10999
|
+
}, Xd = J.create({
|
|
11000
11000
|
name: "doc",
|
|
11001
11001
|
topNode: !0,
|
|
11002
11002
|
content: "block+",
|
|
@@ -11013,11 +11013,11 @@ const yb = Q.create({
|
|
|
11013
11013
|
}
|
|
11014
11014
|
};
|
|
11015
11015
|
}
|
|
11016
|
-
}), Jd =
|
|
11016
|
+
}), Jd = J.create({
|
|
11017
11017
|
name: "text",
|
|
11018
11018
|
group: "inline",
|
|
11019
11019
|
inline: !0
|
|
11020
|
-
}), Ab =
|
|
11020
|
+
}), Ab = J.create({
|
|
11021
11021
|
name: "run",
|
|
11022
11022
|
group: "inline",
|
|
11023
11023
|
content: "text*",
|
|
@@ -11064,7 +11064,7 @@ function Mo(t) {
|
|
|
11064
11064
|
}
|
|
11065
11065
|
});
|
|
11066
11066
|
}
|
|
11067
|
-
const el = /^\s*([-+*])\s$/, Yd =
|
|
11067
|
+
const el = /^\s*([-+*])\s$/, Yd = J.create({
|
|
11068
11068
|
name: "bulletList",
|
|
11069
11069
|
group: "block list",
|
|
11070
11070
|
content() {
|
|
@@ -11082,7 +11082,7 @@ const el = /^\s*([-+*])\s$/, Yd = Y.create({
|
|
|
11082
11082
|
return [{ tag: "ul" }];
|
|
11083
11083
|
},
|
|
11084
11084
|
renderDOM({ htmlAttributes: t }) {
|
|
11085
|
-
return ["ul",
|
|
11085
|
+
return ["ul", D.mergeAttributes(this.options.htmlAttributes, t), 0];
|
|
11086
11086
|
},
|
|
11087
11087
|
addAttributes() {
|
|
11088
11088
|
return {
|
|
@@ -11204,10 +11204,10 @@ function Db(t) {
|
|
|
11204
11204
|
}), l = !0, w = g), f.forEach((y, S) => {
|
|
11205
11205
|
if (S === 0)
|
|
11206
11206
|
return;
|
|
11207
|
-
let { node: k, pos: M } = y, { lvlText: L, listLevel: x, listNumberingType:
|
|
11207
|
+
let { node: k, pos: M } = y, { lvlText: L, listLevel: x, listNumberingType: z } = k.attrs;
|
|
11208
11208
|
Array.isArray(w.listLevel) || (w.listLevel = JSON.parse(w.listLevel));
|
|
11209
11209
|
let _ = [...w.listLevel.slice(0, -1), w.listLevel.at(-1) + 1];
|
|
11210
|
-
if (!(L === w.lvlText &&
|
|
11210
|
+
if (!(L === w.lvlText && z === w.listNumberingType && tl(x, _))) {
|
|
11211
11211
|
let { selection: j, storedMarks: se } = r, ce = se || j.$to.parentOffset && j.$from.marks();
|
|
11212
11212
|
s.setNodeMarkup(M, void 0, {
|
|
11213
11213
|
...k.attrs,
|
|
@@ -11279,7 +11279,7 @@ function Pb({ state: t, listItems: e }) {
|
|
|
11279
11279
|
listNumberingType: s
|
|
11280
11280
|
};
|
|
11281
11281
|
}
|
|
11282
|
-
const nl = /^(\d+)\.\s$/, Zd =
|
|
11282
|
+
const nl = /^(\d+)\.\s$/, Zd = J.create({
|
|
11283
11283
|
name: "orderedList",
|
|
11284
11284
|
group: "block list",
|
|
11285
11285
|
content() {
|
|
@@ -11335,7 +11335,7 @@ const nl = /^(\d+)\.\s$/, Zd = Y.create({
|
|
|
11335
11335
|
},
|
|
11336
11336
|
renderDOM({ htmlAttributes: t }) {
|
|
11337
11337
|
const { start: e, ...n } = t;
|
|
11338
|
-
return e === 1 ? ["ol",
|
|
11338
|
+
return e === 1 ? ["ol", D.mergeAttributes(this.options.htmlAttributes, n), 0] : ["ol", D.mergeAttributes(this.options.htmlAttributes, t), 0];
|
|
11339
11339
|
},
|
|
11340
11340
|
addCommands() {
|
|
11341
11341
|
return {
|
|
@@ -11534,7 +11534,7 @@ function rl(t, e = []) {
|
|
|
11534
11534
|
style: `--marker-font-size: ${u ?? "initial"}`
|
|
11535
11535
|
}, h = {
|
|
11536
11536
|
style: `--marker-font-family: ${f ?? "initial"}`
|
|
11537
|
-
}, m =
|
|
11537
|
+
}, m = D.mergeAttributes(p, h), g = $.node(a, a + s.nodeSize, m);
|
|
11538
11538
|
o.push(g);
|
|
11539
11539
|
}), o;
|
|
11540
11540
|
}
|
|
@@ -11552,7 +11552,7 @@ function ol(t) {
|
|
|
11552
11552
|
`.trim()
|
|
11553
11553
|
};
|
|
11554
11554
|
}
|
|
11555
|
-
let a =
|
|
11555
|
+
let a = $.node(i, i + o.nodeSize, s);
|
|
11556
11556
|
n.push(a);
|
|
11557
11557
|
}), n;
|
|
11558
11558
|
}
|
|
@@ -11571,7 +11571,7 @@ function jb(t, e, n) {
|
|
|
11571
11571
|
function Wb(t) {
|
|
11572
11572
|
return t.childCount === 1 && t.firstChild?.type.name === "paragraph" && t.firstChild?.content.size === 0;
|
|
11573
11573
|
}
|
|
11574
|
-
const tu =
|
|
11574
|
+
const tu = J.create({
|
|
11575
11575
|
name: "listItem",
|
|
11576
11576
|
content: "paragraph* block*",
|
|
11577
11577
|
defining: !0,
|
|
@@ -11588,7 +11588,7 @@ const tu = Y.create({
|
|
|
11588
11588
|
return [{ tag: "li" }];
|
|
11589
11589
|
},
|
|
11590
11590
|
renderDOM({ htmlAttributes: t }) {
|
|
11591
|
-
return ["li",
|
|
11591
|
+
return ["li", D.mergeAttributes(this.options.htmlAttributes, t), 0];
|
|
11592
11592
|
},
|
|
11593
11593
|
addAttributes() {
|
|
11594
11594
|
return {
|
|
@@ -11752,7 +11752,7 @@ const tu = Y.create({
|
|
|
11752
11752
|
if (!a) return;
|
|
11753
11753
|
const l = Kb(a, o);
|
|
11754
11754
|
if (!l) return;
|
|
11755
|
-
const c =
|
|
11755
|
+
const c = $.inline(i, i + o.nodeSize, { style: l });
|
|
11756
11756
|
n.push(c);
|
|
11757
11757
|
}), F.create(t, n);
|
|
11758
11758
|
}, Kb = (t, e, n = !0) => {
|
|
@@ -11815,7 +11815,7 @@ const tu = Y.create({
|
|
|
11815
11815
|
e += `${r ? `font-family: ${r};` : ""} ${o ? `font-size: ${o};` : ""}`;
|
|
11816
11816
|
}
|
|
11817
11817
|
return e.trim();
|
|
11818
|
-
},
|
|
11818
|
+
}, jk = (t) => t?.converter ? (t.converter.linkedStyles || []).filter((n) => n.type === "paragraph" && n.definition.attrs).sort((n, r) => n.definition.attrs?.name.localeCompare(r.definition.attrs?.name)) : [], nu = J.create({
|
|
11819
11819
|
name: "paragraph",
|
|
11820
11820
|
priority: 1e3,
|
|
11821
11821
|
group: "block",
|
|
@@ -11884,9 +11884,9 @@ const tu = Y.create({
|
|
|
11884
11884
|
}];
|
|
11885
11885
|
},
|
|
11886
11886
|
renderDOM({ htmlAttributes: t }) {
|
|
11887
|
-
return ["p",
|
|
11887
|
+
return ["p", D.mergeAttributes(this.options.htmlAttributes, t), 0];
|
|
11888
11888
|
}
|
|
11889
|
-
}), ru =
|
|
11889
|
+
}), ru = J.create({
|
|
11890
11890
|
name: "heading",
|
|
11891
11891
|
group: "block",
|
|
11892
11892
|
content: "inline*",
|
|
@@ -11912,7 +11912,7 @@ const tu = Y.create({
|
|
|
11912
11912
|
}));
|
|
11913
11913
|
},
|
|
11914
11914
|
renderDOM({ node: t, htmlAttributes: e }) {
|
|
11915
|
-
return [`h${this.options.levels.includes(t.attrs.level) ? t.attrs.level : this.options.levels[0]}`,
|
|
11915
|
+
return [`h${this.options.levels.includes(t.attrs.level) ? t.attrs.level : this.options.levels[0]}`, D.mergeAttributes(this.options.htmlAttributes, e), 0];
|
|
11916
11916
|
},
|
|
11917
11917
|
addCommands() {
|
|
11918
11918
|
return {
|
|
@@ -11929,7 +11929,7 @@ const tu = Y.create({
|
|
|
11929
11929
|
{}
|
|
11930
11930
|
);
|
|
11931
11931
|
}
|
|
11932
|
-
}), Zb =
|
|
11932
|
+
}), Zb = J.create({
|
|
11933
11933
|
name: "commentRangeStart",
|
|
11934
11934
|
group: "inline",
|
|
11935
11935
|
inline: !0,
|
|
@@ -11947,7 +11947,7 @@ const tu = Y.create({
|
|
|
11947
11947
|
};
|
|
11948
11948
|
},
|
|
11949
11949
|
renderDOM({ htmlAttributes: t }) {
|
|
11950
|
-
return ["commentRangeStart",
|
|
11950
|
+
return ["commentRangeStart", D.mergeAttributes(this.options.htmlAttributes, t)];
|
|
11951
11951
|
},
|
|
11952
11952
|
addAttributes() {
|
|
11953
11953
|
return {
|
|
@@ -11960,7 +11960,7 @@ const tu = Y.create({
|
|
|
11960
11960
|
}
|
|
11961
11961
|
};
|
|
11962
11962
|
}
|
|
11963
|
-
}), Qb =
|
|
11963
|
+
}), Qb = J.create({
|
|
11964
11964
|
name: "commentRangeEnd",
|
|
11965
11965
|
group: "inline",
|
|
11966
11966
|
inline: !0,
|
|
@@ -11978,7 +11978,7 @@ const tu = Y.create({
|
|
|
11978
11978
|
return [{ tag: "commentRangeEnd" }];
|
|
11979
11979
|
},
|
|
11980
11980
|
renderDOM({ htmlAttributes: t }) {
|
|
11981
|
-
return ["commentRangeEnd",
|
|
11981
|
+
return ["commentRangeEnd", D.mergeAttributes(this.options.htmlAttributes, t)];
|
|
11982
11982
|
},
|
|
11983
11983
|
addAttributes() {
|
|
11984
11984
|
return {
|
|
@@ -11987,7 +11987,7 @@ const tu = Y.create({
|
|
|
11987
11987
|
}
|
|
11988
11988
|
};
|
|
11989
11989
|
}
|
|
11990
|
-
}), e0 =
|
|
11990
|
+
}), e0 = J.create({
|
|
11991
11991
|
name: "commentReference",
|
|
11992
11992
|
group: "inline",
|
|
11993
11993
|
inline: !0,
|
|
@@ -12005,7 +12005,7 @@ const tu = Y.create({
|
|
|
12005
12005
|
return [{ tag: "commentReference" }];
|
|
12006
12006
|
},
|
|
12007
12007
|
renderDOM({ htmlAttributes: t }) {
|
|
12008
|
-
return ["commentReference",
|
|
12008
|
+
return ["commentReference", D.mergeAttributes(this.options.htmlAttributes, t)];
|
|
12009
12009
|
},
|
|
12010
12010
|
addAttributes() {
|
|
12011
12011
|
return {
|
|
@@ -12037,9 +12037,9 @@ const tu = Y.create({
|
|
|
12037
12037
|
return [{ tag: Pe }];
|
|
12038
12038
|
},
|
|
12039
12039
|
renderDOM({ htmlAttributes: t }) {
|
|
12040
|
-
return [Pe,
|
|
12040
|
+
return [Pe, D.mergeAttributes(this.options.htmlAttributes, t)];
|
|
12041
12041
|
}
|
|
12042
|
-
}), n0 =
|
|
12042
|
+
}), n0 = J.create({
|
|
12043
12043
|
name: "tab",
|
|
12044
12044
|
group: "inline",
|
|
12045
12045
|
inline: !0,
|
|
@@ -12062,7 +12062,7 @@ const tu = Y.create({
|
|
|
12062
12062
|
return [{ tag: "span.super-doc-tab" }];
|
|
12063
12063
|
},
|
|
12064
12064
|
renderDOM({ htmlAttributes: t }) {
|
|
12065
|
-
return ["span",
|
|
12065
|
+
return ["span", D.mergeAttributes(this.options.htmlAttributes, t), 0];
|
|
12066
12066
|
},
|
|
12067
12067
|
addAttributes() {
|
|
12068
12068
|
return {
|
|
@@ -12112,7 +12112,7 @@ const tu = Y.create({
|
|
|
12112
12112
|
}
|
|
12113
12113
|
const l = i.nodeBefore?.type.name === "tab" ? ci : ci - a % ci, c = o0(i);
|
|
12114
12114
|
n.push(
|
|
12115
|
-
|
|
12115
|
+
$.node(o, o + r.nodeSize, { style: `width: ${l}px; height: ${c};` })
|
|
12116
12116
|
);
|
|
12117
12117
|
}
|
|
12118
12118
|
}), n;
|
|
@@ -12129,7 +12129,7 @@ function o0(t) {
|
|
|
12129
12129
|
const i = t.node(1).firstChild.marks.find((a) => a.type.name === "textStyle");
|
|
12130
12130
|
return `${(parseInt(i?.attrs.fontSize) * 1.333 || 16) * 1.1}px`;
|
|
12131
12131
|
}
|
|
12132
|
-
const ou =
|
|
12132
|
+
const ou = J.create({
|
|
12133
12133
|
name: "lineBreak",
|
|
12134
12134
|
group: "inline",
|
|
12135
12135
|
inline: !0,
|
|
@@ -12139,7 +12139,7 @@ const ou = Y.create({
|
|
|
12139
12139
|
renderDOM() {
|
|
12140
12140
|
return ["br", {}, 0];
|
|
12141
12141
|
}
|
|
12142
|
-
}), iu =
|
|
12142
|
+
}), iu = J.create({
|
|
12143
12143
|
name: "hardBreak",
|
|
12144
12144
|
group: "inline",
|
|
12145
12145
|
inline: !0,
|
|
@@ -12157,7 +12157,7 @@ const ou = Y.create({
|
|
|
12157
12157
|
return [{ tag: "span" }];
|
|
12158
12158
|
},
|
|
12159
12159
|
renderDOM({ htmlAttributes: t }) {
|
|
12160
|
-
return ["span",
|
|
12160
|
+
return ["span", D.mergeAttributes(this.options.htmlAttributes, t)];
|
|
12161
12161
|
}
|
|
12162
12162
|
}), es = (t, e) => e ? ["width", `${Math.max(e, t)}px`] : ["min-width", `${t}px`], i0 = ({ editor: t }) => class {
|
|
12163
12163
|
constructor(n, r) {
|
|
@@ -12207,7 +12207,7 @@ function al(t, e, n, r, o, i) {
|
|
|
12207
12207
|
a ? (n.style.width = `${s}px`, n.style.minWidth = "") : (n.style.width = "", n.style.minWidth = `${s}px`);
|
|
12208
12208
|
}
|
|
12209
12209
|
function ll(t, e, n) {
|
|
12210
|
-
const o = t.extensionService.attributes.filter((s) => s.type === "table"), i =
|
|
12210
|
+
const o = t.extensionService.attributes.filter((s) => s.type === "table"), i = D.getAttributesToRender(e, o);
|
|
12211
12211
|
Object.entries(i).forEach(([s, a]) => {
|
|
12212
12212
|
n.setAttribute(s, a);
|
|
12213
12213
|
});
|
|
@@ -12559,7 +12559,7 @@ function m0(t, e, n) {
|
|
|
12559
12559
|
return !1;
|
|
12560
12560
|
return !0;
|
|
12561
12561
|
}
|
|
12562
|
-
var X = class ht extends
|
|
12562
|
+
var X = class ht extends Y {
|
|
12563
12563
|
// A table selection is identified by its anchor and head cells. The
|
|
12564
12564
|
// positions given to this constructor should point _before_ two
|
|
12565
12565
|
// cells in the same table. They may be the same, to select a single
|
|
@@ -12588,7 +12588,7 @@ var X = class ht extends J {
|
|
|
12588
12588
|
const i = this.$anchorCell.node(-1) != r.node(-1);
|
|
12589
12589
|
return i && this.isRowSelection() ? ht.rowSelection(r, o) : i && this.isColSelection() ? ht.colSelection(r, o) : new ht(r, o);
|
|
12590
12590
|
}
|
|
12591
|
-
return
|
|
12591
|
+
return H.between(r, o);
|
|
12592
12592
|
}
|
|
12593
12593
|
// Returns a rectangular slice of table rows containing the selected
|
|
12594
12594
|
// cells.
|
|
@@ -12646,7 +12646,7 @@ var X = class ht extends J {
|
|
|
12646
12646
|
s ? W.empty : n
|
|
12647
12647
|
);
|
|
12648
12648
|
}
|
|
12649
|
-
const i =
|
|
12649
|
+
const i = Y.findFrom(
|
|
12650
12650
|
e.doc.resolve(e.mapping.slice(r).map(this.to)),
|
|
12651
12651
|
-1
|
|
12652
12652
|
);
|
|
@@ -12724,7 +12724,7 @@ var X = class ht extends J {
|
|
|
12724
12724
|
}
|
|
12725
12725
|
};
|
|
12726
12726
|
X.prototype.visible = !1;
|
|
12727
|
-
|
|
12727
|
+
Y.jsonID("cell", X);
|
|
12728
12728
|
var g0 = class cu {
|
|
12729
12729
|
constructor(e, n) {
|
|
12730
12730
|
this.anchor = e, this.head = n;
|
|
@@ -12734,7 +12734,7 @@ var g0 = class cu {
|
|
|
12734
12734
|
}
|
|
12735
12735
|
resolve(e) {
|
|
12736
12736
|
const n = e.resolve(this.anchor), r = e.resolve(this.head);
|
|
12737
|
-
return n.parent.type.spec.tableRole == "row" && r.parent.type.spec.tableRole == "row" && n.index() < n.parent.childCount && r.index() < r.parent.childCount && $s(n, r) ? new X(n, r) :
|
|
12737
|
+
return n.parent.type.spec.tableRole == "row" && r.parent.type.spec.tableRole == "row" && n.index() < n.parent.childCount && r.index() < r.parent.childCount && $s(n, r) ? new X(n, r) : Y.near(r, 1);
|
|
12738
12738
|
}
|
|
12739
12739
|
};
|
|
12740
12740
|
function y0(t) {
|
|
@@ -12742,7 +12742,7 @@ function y0(t) {
|
|
|
12742
12742
|
const e = [];
|
|
12743
12743
|
return t.selection.forEachCell((n, r) => {
|
|
12744
12744
|
e.push(
|
|
12745
|
-
|
|
12745
|
+
$.node(r, r + n.nodeSize, { class: "selectedCell" })
|
|
12746
12746
|
);
|
|
12747
12747
|
}), F.create(t.doc, e);
|
|
12748
12748
|
}
|
|
@@ -12786,7 +12786,7 @@ function v0(t, e, n) {
|
|
|
12786
12786
|
const a = oe.get(r.node), l = r.from + 1, c = l + a.map[a.width * a.height - 1];
|
|
12787
12787
|
i = X.create(o, l + 1, c);
|
|
12788
12788
|
}
|
|
12789
|
-
} else r instanceof
|
|
12789
|
+
} else r instanceof H && b0(r) ? i = H.create(o, r.from) : r instanceof H && w0(r) && (i = H.create(o, r.$from.start(), r.$from.end()));
|
|
12790
12790
|
return i && (e || (e = t.tr)).setSelection(i), e;
|
|
12791
12791
|
}
|
|
12792
12792
|
var k0 = new G("fix-tables");
|
|
@@ -13273,7 +13273,7 @@ function ml(t) {
|
|
|
13273
13273
|
if (n) {
|
|
13274
13274
|
const o = e.doc.resolve(r);
|
|
13275
13275
|
n(
|
|
13276
|
-
e.tr.setSelection(
|
|
13276
|
+
e.tr.setSelection(H.between(o, h0(o))).scrollIntoView()
|
|
13277
13277
|
);
|
|
13278
13278
|
}
|
|
13279
13279
|
return !0;
|
|
@@ -13524,7 +13524,7 @@ function Yr(t, e) {
|
|
|
13524
13524
|
return so(
|
|
13525
13525
|
n,
|
|
13526
13526
|
r,
|
|
13527
|
-
|
|
13527
|
+
Y.near(i.$headCell, e)
|
|
13528
13528
|
);
|
|
13529
13529
|
if (t != "horiz" && !i.empty) return !1;
|
|
13530
13530
|
const s = hu(o, t, e);
|
|
@@ -13533,12 +13533,12 @@ function Yr(t, e) {
|
|
|
13533
13533
|
return so(
|
|
13534
13534
|
n,
|
|
13535
13535
|
r,
|
|
13536
|
-
|
|
13536
|
+
Y.near(n.doc.resolve(i.head + e), e)
|
|
13537
13537
|
);
|
|
13538
13538
|
{
|
|
13539
13539
|
const a = n.doc.resolve(s), l = au(a, t, e);
|
|
13540
13540
|
let c;
|
|
13541
|
-
return l ? c =
|
|
13541
|
+
return l ? c = Y.near(l, 1) : e < 0 ? c = Y.near(n.doc.resolve(a.before(-1)), -1) : c = Y.near(n.doc.resolve(a.after(-1)), 1), so(n, r, c);
|
|
13542
13542
|
}
|
|
13543
13543
|
};
|
|
13544
13544
|
}
|
|
@@ -13635,7 +13635,7 @@ function q0(t, e) {
|
|
|
13635
13635
|
t.root.addEventListener("mouseup", s), t.root.addEventListener("dragstart", s), t.root.addEventListener("mousemove", a);
|
|
13636
13636
|
}
|
|
13637
13637
|
function hu(t, e, n) {
|
|
13638
|
-
if (!(t.state.selection instanceof
|
|
13638
|
+
if (!(t.state.selection instanceof H)) return null;
|
|
13639
13639
|
const { $head: r } = t.state.selection;
|
|
13640
13640
|
for (let o = r.depth - 1; o >= 0; o--) {
|
|
13641
13641
|
const i = r.node(o);
|
|
@@ -13912,14 +13912,14 @@ function rw(t, e) {
|
|
|
13912
13912
|
if ((l == s.width - 1 || s.map[d] != s.map[d + 1]) && (c == 0 || s.map[d] != s.map[d - s.width])) {
|
|
13913
13913
|
const u = s.map[d], f = a + u + i.nodeAt(u).nodeSize - 1, p = document.createElement("div");
|
|
13914
13914
|
p.className = "column-resize-handle", (n = Ee.getState(t)) != null && n.dragging && r.push(
|
|
13915
|
-
|
|
13915
|
+
$.node(
|
|
13916
13916
|
a + u,
|
|
13917
13917
|
a + u + i.nodeAt(u).nodeSize,
|
|
13918
13918
|
{
|
|
13919
13919
|
class: "column-resize-dragging"
|
|
13920
13920
|
}
|
|
13921
13921
|
)
|
|
13922
|
-
), r.push(
|
|
13922
|
+
), r.push($.widget(f, p));
|
|
13923
13923
|
}
|
|
13924
13924
|
}
|
|
13925
13925
|
return F.create(t.doc, r);
|
|
@@ -13981,7 +13981,7 @@ const iw = (t) => t instanceof X, Zr = ({ editor: t }) => {
|
|
|
13981
13981
|
left: { size: t, color: e },
|
|
13982
13982
|
bottom: { size: t, color: e },
|
|
13983
13983
|
right: { size: t, color: e }
|
|
13984
|
-
}), yu =
|
|
13984
|
+
}), yu = J.create({
|
|
13985
13985
|
name: "table",
|
|
13986
13986
|
content: "tableRow+",
|
|
13987
13987
|
group: "block",
|
|
@@ -14059,7 +14059,7 @@ const iw = (t) => t instanceof X, Zr = ({ editor: t }) => {
|
|
|
14059
14059
|
);
|
|
14060
14060
|
return [
|
|
14061
14061
|
"table",
|
|
14062
|
-
|
|
14062
|
+
D.mergeAttributes(this.options.htmlAttributes, e, {
|
|
14063
14063
|
style: r ? `width: ${r}` : `min-width: ${o}`
|
|
14064
14064
|
}),
|
|
14065
14065
|
n,
|
|
@@ -14072,7 +14072,7 @@ const iw = (t) => t instanceof X, Zr = ({ editor: t }) => {
|
|
|
14072
14072
|
const s = s0(i.schema, t, e, n);
|
|
14073
14073
|
if (o) {
|
|
14074
14074
|
const a = r.selection.from + 1;
|
|
14075
|
-
r.replaceSelectionWith(s).scrollIntoView().setSelection(
|
|
14075
|
+
r.replaceSelectionWith(s).scrollIntoView().setSelection(H.near(r.doc.resolve(a)));
|
|
14076
14076
|
}
|
|
14077
14077
|
return !0;
|
|
14078
14078
|
},
|
|
@@ -14143,14 +14143,14 @@ const iw = (t) => t instanceof X, Zr = ({ editor: t }) => {
|
|
|
14143
14143
|
},
|
|
14144
14144
|
extendNodeSchema(t) {
|
|
14145
14145
|
return {
|
|
14146
|
-
tableRole: K(
|
|
14146
|
+
tableRole: K(N(t, "tableRole", {
|
|
14147
14147
|
name: t.name,
|
|
14148
14148
|
options: t.options,
|
|
14149
14149
|
storage: t.storage
|
|
14150
14150
|
}))
|
|
14151
14151
|
};
|
|
14152
14152
|
}
|
|
14153
|
-
}), bu =
|
|
14153
|
+
}), bu = J.create({
|
|
14154
14154
|
name: "tableHeader",
|
|
14155
14155
|
content: "block+",
|
|
14156
14156
|
tableRole: "header_cell",
|
|
@@ -14184,9 +14184,9 @@ const iw = (t) => t instanceof X, Zr = ({ editor: t }) => {
|
|
|
14184
14184
|
return [{ tag: "th" }];
|
|
14185
14185
|
},
|
|
14186
14186
|
renderDOM({ htmlAttributes: t }) {
|
|
14187
|
-
return ["th",
|
|
14187
|
+
return ["th", D.mergeAttributes(this.options.htmlAttributes, t), 0];
|
|
14188
14188
|
}
|
|
14189
|
-
}), wu =
|
|
14189
|
+
}), wu = J.create({
|
|
14190
14190
|
name: "tableRow",
|
|
14191
14191
|
content: "(tableCell | tableHeader)*",
|
|
14192
14192
|
tableRole: "row",
|
|
@@ -14208,9 +14208,9 @@ const iw = (t) => t instanceof X, Zr = ({ editor: t }) => {
|
|
|
14208
14208
|
return [{ tag: "tr" }];
|
|
14209
14209
|
},
|
|
14210
14210
|
renderDOM({ htmlAttributes: t }) {
|
|
14211
|
-
return ["tr",
|
|
14211
|
+
return ["tr", D.mergeAttributes(this.options.htmlAttributes, t), 0];
|
|
14212
14212
|
}
|
|
14213
|
-
}), vu =
|
|
14213
|
+
}), vu = J.create({
|
|
14214
14214
|
name: "tableCell",
|
|
14215
14215
|
content: "block+",
|
|
14216
14216
|
tableRole: "cell",
|
|
@@ -14290,7 +14290,7 @@ const iw = (t) => t instanceof X, Zr = ({ editor: t }) => {
|
|
|
14290
14290
|
return [{ tag: "td" }];
|
|
14291
14291
|
},
|
|
14292
14292
|
renderDOM({ htmlAttributes: t }) {
|
|
14293
|
-
return ["td",
|
|
14293
|
+
return ["td", D.mergeAttributes(this.options.htmlAttributes, t), 0];
|
|
14294
14294
|
}
|
|
14295
14295
|
});
|
|
14296
14296
|
var yt, Jt;
|
|
@@ -14431,7 +14431,7 @@ yt = new WeakSet(), Jt = function({ displayLabel: e } = {}) {
|
|
|
14431
14431
|
o.classList.add(this.annotationContentClass), o.style.pointerEvents = "none", o.contentEditable = "false", e && (o.textContent = e), r.append(o);
|
|
14432
14432
|
let i = n === !1, s = [`border: 2px solid ${this.borderColor}`, "border-radius: 2px", "padding: 1px 2px", "box-sizing: border-box"].join(
|
|
14433
14433
|
"; "
|
|
14434
|
-
), a =
|
|
14434
|
+
), a = D.mergeAttributes(this.htmlAttributes, {
|
|
14435
14435
|
style: i ? "" : s
|
|
14436
14436
|
});
|
|
14437
14437
|
for (let [l, c] of Object.entries(a))
|
|
@@ -14599,7 +14599,7 @@ function co(t, e, n) {
|
|
|
14599
14599
|
});
|
|
14600
14600
|
}), r;
|
|
14601
14601
|
}
|
|
14602
|
-
const
|
|
14602
|
+
const Uk = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
14603
14603
|
__proto__: null,
|
|
14604
14604
|
findFieldAnnotations: uw,
|
|
14605
14605
|
findFieldAnnotationsBetween: co,
|
|
@@ -14684,7 +14684,7 @@ function Aw(t) {
|
|
|
14684
14684
|
};
|
|
14685
14685
|
return `#${i(e)}${i(n)}${i(r)}${o < 1 ? i(Math.round(o * 255)) : ""}`;
|
|
14686
14686
|
}
|
|
14687
|
-
const ls = "annotation", Su = "annotation-content", xu =
|
|
14687
|
+
const ls = "annotation", Su = "annotation-content", xu = J.create({
|
|
14688
14688
|
name: "fieldAnnotation",
|
|
14689
14689
|
group: "inline",
|
|
14690
14690
|
inline: !0,
|
|
@@ -14875,7 +14875,7 @@ const ls = "annotation", Su = "annotation-content", xu = Y.create({
|
|
|
14875
14875
|
renderDOM({ node: t, htmlAttributes: e }) {
|
|
14876
14876
|
let { type: n, displayLabel: r, imageSrc: o, rawHtml: i, linkUrl: s } = t.attrs, a = () => [
|
|
14877
14877
|
"span",
|
|
14878
|
-
|
|
14878
|
+
D.mergeAttributes(this.options.htmlAttributes, e),
|
|
14879
14879
|
[
|
|
14880
14880
|
"span",
|
|
14881
14881
|
{
|
|
@@ -14893,7 +14893,7 @@ const ls = "annotation", Su = "annotation-content", xu = Y.create({
|
|
|
14893
14893
|
] : r;
|
|
14894
14894
|
return [
|
|
14895
14895
|
"span",
|
|
14896
|
-
|
|
14896
|
+
D.mergeAttributes(this.options.htmlAttributes, e),
|
|
14897
14897
|
[
|
|
14898
14898
|
"span",
|
|
14899
14899
|
{
|
|
@@ -14913,7 +14913,7 @@ const ls = "annotation", Su = "annotation-content", xu = Y.create({
|
|
|
14913
14913
|
] : r;
|
|
14914
14914
|
return [
|
|
14915
14915
|
"span",
|
|
14916
|
-
|
|
14916
|
+
D.mergeAttributes(this.options.htmlAttributes, e),
|
|
14917
14917
|
[
|
|
14918
14918
|
"span",
|
|
14919
14919
|
{
|
|
@@ -14952,7 +14952,7 @@ const ls = "annotation", Su = "annotation-content", xu = Y.create({
|
|
|
14952
14952
|
let { schema: a } = r, l = s.mapping.map(t), d = i.doc.resolve(l).marks();
|
|
14953
14953
|
d = d.length ? [...d] : null;
|
|
14954
14954
|
let u = Ow(d), f = a.nodes[this.name].create({ ...e, ...u }, null, null);
|
|
14955
|
-
i.tr.insert(l, f).setSelection(
|
|
14955
|
+
i.tr.insert(l, f).setSelection(Y.near(s.doc.resolve(l + f.nodeSize))), n && this.editor.view.focus();
|
|
14956
14956
|
}
|
|
14957
14957
|
return !0;
|
|
14958
14958
|
},
|
|
@@ -15194,7 +15194,7 @@ const Ao = new G("ImagePlaceholder"), Tw = (t = {}) => new Z({
|
|
|
15194
15194
|
n = n.map(e.mapping, e.doc);
|
|
15195
15195
|
let i = e.getMeta(Ao);
|
|
15196
15196
|
if (i?.type === "add") {
|
|
15197
|
-
let s = document.createElement("placeholder"), a =
|
|
15197
|
+
let s = document.createElement("placeholder"), a = $.widget(i.pos, s, {
|
|
15198
15198
|
id: i.id
|
|
15199
15199
|
});
|
|
15200
15200
|
n = n.add(e.doc, [a]);
|
|
@@ -15207,10 +15207,10 @@ const Ao = new G("ImagePlaceholder"), Tw = (t = {}) => new Z({
|
|
|
15207
15207
|
return this.getState(e);
|
|
15208
15208
|
}
|
|
15209
15209
|
}
|
|
15210
|
-
}),
|
|
15210
|
+
}), qk = (t, e) => {
|
|
15211
15211
|
let r = Ao.getState(t)?.find(null, null, (o) => o.id === e);
|
|
15212
15212
|
return r?.length ? r[0].from : null;
|
|
15213
|
-
}, Mu =
|
|
15213
|
+
}, Mu = J.create({
|
|
15214
15214
|
name: "image",
|
|
15215
15215
|
group: "inline",
|
|
15216
15216
|
inline: !0,
|
|
@@ -15279,7 +15279,7 @@ const Ao = new G("ImagePlaceholder"), Tw = (t = {}) => new Z({
|
|
|
15279
15279
|
];
|
|
15280
15280
|
},
|
|
15281
15281
|
renderDOM({ htmlAttributes: t }) {
|
|
15282
|
-
return ["img",
|
|
15282
|
+
return ["img", D.mergeAttributes(this.options.htmlAttributes, t)];
|
|
15283
15283
|
},
|
|
15284
15284
|
addCommands() {
|
|
15285
15285
|
return {
|
|
@@ -15292,7 +15292,7 @@ const Ao = new G("ImagePlaceholder"), Tw = (t = {}) => new Z({
|
|
|
15292
15292
|
addPmPlugins() {
|
|
15293
15293
|
return [Tw()];
|
|
15294
15294
|
}
|
|
15295
|
-
}), Dw =
|
|
15295
|
+
}), Dw = J.create({
|
|
15296
15296
|
name: "bookmarkStart",
|
|
15297
15297
|
group: "inline",
|
|
15298
15298
|
content: "inline*",
|
|
@@ -15315,9 +15315,9 @@ const Ao = new G("ImagePlaceholder"), Tw = (t = {}) => new Z({
|
|
|
15315
15315
|
};
|
|
15316
15316
|
},
|
|
15317
15317
|
renderDOM({ htmlAttributes: t }) {
|
|
15318
|
-
return ["a",
|
|
15318
|
+
return ["a", D.mergeAttributes(this.options.htmlAttributes, t)];
|
|
15319
15319
|
}
|
|
15320
|
-
}), Au =
|
|
15320
|
+
}), Au = J.create({
|
|
15321
15321
|
name: "mention",
|
|
15322
15322
|
group: "inline",
|
|
15323
15323
|
inline: !0,
|
|
@@ -15345,7 +15345,7 @@ const Ao = new G("ImagePlaceholder"), Tw = (t = {}) => new Z({
|
|
|
15345
15345
|
const { name: n, email: r } = t.attrs;
|
|
15346
15346
|
return [
|
|
15347
15347
|
"span",
|
|
15348
|
-
|
|
15348
|
+
D.mergeAttributes({ "data-type": this.name || this.email }, this.options.htmlAttributes, e),
|
|
15349
15349
|
`@${n || r}`
|
|
15350
15350
|
];
|
|
15351
15351
|
},
|
|
@@ -15355,7 +15355,7 @@ const Ao = new G("ImagePlaceholder"), Tw = (t = {}) => new Z({
|
|
|
15355
15355
|
email: { default: null }
|
|
15356
15356
|
};
|
|
15357
15357
|
}
|
|
15358
|
-
}), Nw =
|
|
15358
|
+
}), Nw = J.create({
|
|
15359
15359
|
name: "page-number",
|
|
15360
15360
|
group: "inline",
|
|
15361
15361
|
inline: !0,
|
|
@@ -15371,7 +15371,25 @@ const Ao = new G("ImagePlaceholder"), Tw = (t = {}) => new Z({
|
|
|
15371
15371
|
return [{ tag: 'span[data-id="auto-page-number"' }];
|
|
15372
15372
|
},
|
|
15373
15373
|
renderDOM({ htmlAttributes: t }) {
|
|
15374
|
-
return ["span",
|
|
15374
|
+
return ["span", D.mergeAttributes(this.options.htmlAttributes, t), 0];
|
|
15375
|
+
}
|
|
15376
|
+
}), Ew = J.create({
|
|
15377
|
+
name: "total-page-number",
|
|
15378
|
+
group: "inline",
|
|
15379
|
+
inline: !0,
|
|
15380
|
+
content: "text*",
|
|
15381
|
+
addOptions() {
|
|
15382
|
+
return {
|
|
15383
|
+
htmlAttributes: {
|
|
15384
|
+
"data-id": "auto-total-pages"
|
|
15385
|
+
}
|
|
15386
|
+
};
|
|
15387
|
+
},
|
|
15388
|
+
parseDOM() {
|
|
15389
|
+
return [{ tag: 'span[data-id="auto-total-pages"' }];
|
|
15390
|
+
},
|
|
15391
|
+
renderDOM({ htmlAttributes: t }) {
|
|
15392
|
+
return ["span", D.mergeAttributes(this.options.htmlAttributes, t), 0];
|
|
15375
15393
|
}
|
|
15376
15394
|
}), Ou = Le.create({
|
|
15377
15395
|
name: "textStyle",
|
|
@@ -15392,12 +15410,12 @@ const Ao = new G("ImagePlaceholder"), Tw = (t = {}) => new Z({
|
|
|
15392
15410
|
];
|
|
15393
15411
|
},
|
|
15394
15412
|
renderDOM({ htmlAttributes: t }) {
|
|
15395
|
-
return ["span",
|
|
15413
|
+
return ["span", D.mergeAttributes(this.options.htmlAttributes, t), 0];
|
|
15396
15414
|
},
|
|
15397
15415
|
addCommands() {
|
|
15398
15416
|
return {
|
|
15399
15417
|
removeEmptyTextStyle: () => ({ state: t, commands: e }) => {
|
|
15400
|
-
const n =
|
|
15418
|
+
const n = D.getMarkAttributes(t, this.type);
|
|
15401
15419
|
return Object.entries(n).some(([, o]) => !!o) ? !0 : e.unsetMark(this.name);
|
|
15402
15420
|
}
|
|
15403
15421
|
};
|
|
@@ -15418,7 +15436,7 @@ const Ao = new G("ImagePlaceholder"), Tw = (t = {}) => new Z({
|
|
|
15418
15436
|
];
|
|
15419
15437
|
},
|
|
15420
15438
|
renderDOM({ htmlAttributes: t }) {
|
|
15421
|
-
return ["strong",
|
|
15439
|
+
return ["strong", D.mergeAttributes(this.options.htmlAttributes, t), 0];
|
|
15422
15440
|
},
|
|
15423
15441
|
//prettier-ignore
|
|
15424
15442
|
addCommands() {
|
|
@@ -15450,7 +15468,7 @@ const Ao = new G("ImagePlaceholder"), Tw = (t = {}) => new Z({
|
|
|
15450
15468
|
];
|
|
15451
15469
|
},
|
|
15452
15470
|
renderDOM({ htmlAttributes: t }) {
|
|
15453
|
-
return ["em",
|
|
15471
|
+
return ["em", D.mergeAttributes(this.options.htmlAttributes, t), 0];
|
|
15454
15472
|
},
|
|
15455
15473
|
//prettier-ignore
|
|
15456
15474
|
addCommands() {
|
|
@@ -15481,7 +15499,7 @@ const Ao = new G("ImagePlaceholder"), Tw = (t = {}) => new Z({
|
|
|
15481
15499
|
];
|
|
15482
15500
|
},
|
|
15483
15501
|
renderDOM({ htmlAttributes: t }) {
|
|
15484
|
-
return ["u",
|
|
15502
|
+
return ["u", D.mergeAttributes(this.options.htmlAttributes, t), 0];
|
|
15485
15503
|
},
|
|
15486
15504
|
addAttributes() {
|
|
15487
15505
|
return {
|
|
@@ -15527,7 +15545,7 @@ const Ao = new G("ImagePlaceholder"), Tw = (t = {}) => new Z({
|
|
|
15527
15545
|
return [{ tag: "mark" }];
|
|
15528
15546
|
},
|
|
15529
15547
|
renderDOM({ htmlAttributes: t }) {
|
|
15530
|
-
return ["mark",
|
|
15548
|
+
return ["mark", D.mergeAttributes(this.options.htmlAttributes, t), 0];
|
|
15531
15549
|
},
|
|
15532
15550
|
//prettier-ignore
|
|
15533
15551
|
addCommands() {
|
|
@@ -15557,7 +15575,7 @@ const Ao = new G("ImagePlaceholder"), Tw = (t = {}) => new Z({
|
|
|
15557
15575
|
];
|
|
15558
15576
|
},
|
|
15559
15577
|
renderDOM({ htmlAttributes: t }) {
|
|
15560
|
-
return ["s",
|
|
15578
|
+
return ["s", D.mergeAttributes(this.options.htmlAttributes, t), 0];
|
|
15561
15579
|
},
|
|
15562
15580
|
addCommands() {
|
|
15563
15581
|
return {
|
|
@@ -15590,7 +15608,7 @@ const Ao = new G("ImagePlaceholder"), Tw = (t = {}) => new Z({
|
|
|
15590
15608
|
return [{ tag: "a" }];
|
|
15591
15609
|
},
|
|
15592
15610
|
renderDOM({ htmlAttributes: t }) {
|
|
15593
|
-
return Ml(t.href, this.options.protocols) ? ["a",
|
|
15611
|
+
return Ml(t.href, this.options.protocols) ? ["a", D.mergeAttributes(this.options.htmlAttributes, t), 0] : ["a", mergeAttributes(this.options.htmlAttributes, { ...t, href: "" }), 0];
|
|
15594
15612
|
},
|
|
15595
15613
|
addAttributes() {
|
|
15596
15614
|
return {
|
|
@@ -15622,22 +15640,22 @@ const Ao = new G("ImagePlaceholder"), Tw = (t = {}) => new Z({
|
|
|
15622
15640
|
toggleLink: ({ href: t }) => ({ commands: e }) => t ? e.setLink({ href: t }) : e.unsetLink()
|
|
15623
15641
|
};
|
|
15624
15642
|
}
|
|
15625
|
-
}),
|
|
15643
|
+
}), Iw = /[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g;
|
|
15626
15644
|
function Ml(t, e) {
|
|
15627
15645
|
const n = ["http", "https", "mailto"];
|
|
15628
15646
|
return e && e.forEach((r) => {
|
|
15629
15647
|
const o = typeof r == "string" ? r : r.scheme;
|
|
15630
15648
|
o && n.push(o);
|
|
15631
|
-
}), !t || t.replace(
|
|
15649
|
+
}), !t || t.replace(Iw, "").match(new RegExp(`^(?:(?:${n.join("|")}):|[^a-z]|[a-z+.-]+(?:[^a-z+.-:]|$))`, "i"));
|
|
15632
15650
|
}
|
|
15633
|
-
const
|
|
15651
|
+
const Pw = "track-insert", Ru = Le.create({
|
|
15634
15652
|
name: $e,
|
|
15635
15653
|
group: "track",
|
|
15636
15654
|
inclusive: !1,
|
|
15637
15655
|
addOptions() {
|
|
15638
15656
|
return {
|
|
15639
15657
|
htmlAttributes: {
|
|
15640
|
-
class:
|
|
15658
|
+
class: Pw
|
|
15641
15659
|
}
|
|
15642
15660
|
};
|
|
15643
15661
|
},
|
|
@@ -15677,16 +15695,16 @@ const Iw = "track-insert", Ru = Le.create({
|
|
|
15677
15695
|
return !1;
|
|
15678
15696
|
},
|
|
15679
15697
|
renderDOM({ htmlAttributes: t }) {
|
|
15680
|
-
return ["span",
|
|
15698
|
+
return ["span", D.mergeAttributes(this.options.htmlAttributes, t), 0];
|
|
15681
15699
|
}
|
|
15682
|
-
}),
|
|
15700
|
+
}), Rw = "track-delete", Lu = Le.create({
|
|
15683
15701
|
name: ue,
|
|
15684
15702
|
group: "track",
|
|
15685
15703
|
inclusive: !1,
|
|
15686
15704
|
addOptions() {
|
|
15687
15705
|
return {
|
|
15688
15706
|
htmlAttributes: {
|
|
15689
|
-
class:
|
|
15707
|
+
class: Rw
|
|
15690
15708
|
}
|
|
15691
15709
|
};
|
|
15692
15710
|
},
|
|
@@ -15726,7 +15744,7 @@ const Iw = "track-insert", Ru = Le.create({
|
|
|
15726
15744
|
return !1;
|
|
15727
15745
|
},
|
|
15728
15746
|
renderDOM({ htmlAttributes: t }) {
|
|
15729
|
-
return ["span",
|
|
15747
|
+
return ["span", D.mergeAttributes(this.options.htmlAttributes, t), 0];
|
|
15730
15748
|
}
|
|
15731
15749
|
}), cs = (t) => {
|
|
15732
15750
|
if (!t) return [];
|
|
@@ -15737,7 +15755,7 @@ const Iw = "track-insert", Ru = Le.create({
|
|
|
15737
15755
|
return [];
|
|
15738
15756
|
}
|
|
15739
15757
|
return Array.isArray(e) ? e.filter((n) => Object.hasOwn(n, "type") && Object.hasOwn(n, "attrs")) : [];
|
|
15740
|
-
},
|
|
15758
|
+
}, Kk = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
15741
15759
|
__proto__: null,
|
|
15742
15760
|
addMarkStep: Dd,
|
|
15743
15761
|
documentHelpers: Hy,
|
|
@@ -15751,14 +15769,14 @@ const Iw = "track-insert", Ru = Le.create({
|
|
|
15751
15769
|
replaceAroundStep: rb,
|
|
15752
15770
|
replaceStep: Td,
|
|
15753
15771
|
trackedTransaction: Ed
|
|
15754
|
-
}, Symbol.toStringTag, { value: "Module" })),
|
|
15772
|
+
}, Symbol.toStringTag, { value: "Module" })), Lw = "track-format", Fu = Le.create({
|
|
15755
15773
|
name: Se,
|
|
15756
15774
|
group: "track",
|
|
15757
15775
|
inclusive: !1,
|
|
15758
15776
|
addOptions() {
|
|
15759
15777
|
return {
|
|
15760
15778
|
htmlAttributes: {
|
|
15761
|
-
class:
|
|
15779
|
+
class: Lw
|
|
15762
15780
|
}
|
|
15763
15781
|
};
|
|
15764
15782
|
},
|
|
@@ -15820,9 +15838,9 @@ const Iw = "track-insert", Ru = Le.create({
|
|
|
15820
15838
|
return !1;
|
|
15821
15839
|
},
|
|
15822
15840
|
renderDOM({ htmlAttributes: t }) {
|
|
15823
|
-
return ["span",
|
|
15841
|
+
return ["span", D.mergeAttributes(this.options.htmlAttributes, t), 0];
|
|
15824
15842
|
}
|
|
15825
|
-
}),
|
|
15843
|
+
}), Fw = Q.create({
|
|
15826
15844
|
name: "trackChanges",
|
|
15827
15845
|
addCommands() {
|
|
15828
15846
|
return {
|
|
@@ -15992,7 +16010,7 @@ const Iw = "track-insert", Ru = Le.create({
|
|
|
15992
16010
|
const o = n[r], i = n[r - 1], s = n[r + 1];
|
|
15993
16011
|
let a;
|
|
15994
16012
|
return i && o.start === i.end ? a = i : s && o.end === s.start && (a = s), [o, a].filter(Boolean);
|
|
15995
|
-
},
|
|
16013
|
+
}, Bw = Q.create({
|
|
15996
16014
|
name: "placeholder",
|
|
15997
16015
|
addOptions() {
|
|
15998
16016
|
return {
|
|
@@ -16002,7 +16020,7 @@ const Iw = "track-insert", Ru = Le.create({
|
|
|
16002
16020
|
addPmPlugins() {
|
|
16003
16021
|
const t = (n) => {
|
|
16004
16022
|
if (n.doc.textBetween(0, n.doc.content.size, " ", " ") !== "") return F.empty;
|
|
16005
|
-
const { $from: o } = n.selection, i =
|
|
16023
|
+
const { $from: o } = n.selection, i = $.node(o.before(), o.after(), {
|
|
16006
16024
|
"data-placeholder": this.options.placeholder,
|
|
16007
16025
|
class: "super-editor-placeholder"
|
|
16008
16026
|
});
|
|
@@ -16022,11 +16040,11 @@ const Iw = "track-insert", Ru = Le.create({
|
|
|
16022
16040
|
})];
|
|
16023
16041
|
}
|
|
16024
16042
|
});
|
|
16025
|
-
var Te = "top", We = "bottom", Ue = "right", De = "left", Vs = "auto", Ir = [Te, We, Ue, De], Pn = "start", Cr = "end",
|
|
16043
|
+
var Te = "top", We = "bottom", Ue = "right", De = "left", Vs = "auto", Ir = [Te, We, Ue, De], Pn = "start", Cr = "end", _w = "clippingParents", Bu = "viewport", Jn = "popper", zw = "reference", Ol = /* @__PURE__ */ Ir.reduce(function(t, e) {
|
|
16026
16044
|
return t.concat([e + "-" + Pn, e + "-" + Cr]);
|
|
16027
16045
|
}, []), _u = /* @__PURE__ */ [].concat(Ir, [Vs]).reduce(function(t, e) {
|
|
16028
16046
|
return t.concat([e, e + "-" + Pn, e + "-" + Cr]);
|
|
16029
|
-
}, []),
|
|
16047
|
+
}, []), $w = "beforeRead", Vw = "read", Hw = "afterRead", jw = "beforeMain", Ww = "main", Uw = "afterMain", qw = "beforeWrite", Kw = "write", Xw = "afterWrite", Jw = [$w, Vw, Hw, jw, Ww, Uw, qw, Kw, Xw];
|
|
16030
16048
|
function st(t) {
|
|
16031
16049
|
return t ? (t.nodeName || "").toLowerCase() : null;
|
|
16032
16050
|
}
|
|
@@ -16053,7 +16071,7 @@ function Hs(t) {
|
|
|
16053
16071
|
var e = Re(t).ShadowRoot;
|
|
16054
16072
|
return t instanceof e || t instanceof ShadowRoot;
|
|
16055
16073
|
}
|
|
16056
|
-
function
|
|
16074
|
+
function Yw(t) {
|
|
16057
16075
|
var e = t.state;
|
|
16058
16076
|
Object.keys(e.elements).forEach(function(n) {
|
|
16059
16077
|
var r = e.styles[n] || {}, o = e.attributes[n] || {}, i = e.elements[n];
|
|
@@ -16063,7 +16081,7 @@ function Jw(t) {
|
|
|
16063
16081
|
}));
|
|
16064
16082
|
});
|
|
16065
16083
|
}
|
|
16066
|
-
function
|
|
16084
|
+
function Gw(t) {
|
|
16067
16085
|
var e = t.state, n = {
|
|
16068
16086
|
popper: {
|
|
16069
16087
|
position: e.options.strategy,
|
|
@@ -16091,8 +16109,8 @@ const zu = {
|
|
|
16091
16109
|
name: "applyStyles",
|
|
16092
16110
|
enabled: !0,
|
|
16093
16111
|
phase: "write",
|
|
16094
|
-
fn:
|
|
16095
|
-
effect:
|
|
16112
|
+
fn: Yw,
|
|
16113
|
+
effect: Gw,
|
|
16096
16114
|
requires: ["computeStyles"]
|
|
16097
16115
|
};
|
|
16098
16116
|
function rt(t) {
|
|
@@ -16150,7 +16168,7 @@ function Vu(t, e) {
|
|
|
16150
16168
|
function St(t) {
|
|
16151
16169
|
return Re(t).getComputedStyle(t);
|
|
16152
16170
|
}
|
|
16153
|
-
function
|
|
16171
|
+
function Zw(t) {
|
|
16154
16172
|
return ["table", "td", "th"].indexOf(st(t)) >= 0;
|
|
16155
16173
|
}
|
|
16156
16174
|
function Wt(t) {
|
|
@@ -16175,7 +16193,7 @@ function Tl(t) {
|
|
|
16175
16193
|
return !je(t) || // https://github.com/popperjs/popper-core/issues/837
|
|
16176
16194
|
St(t).position === "fixed" ? null : t.offsetParent;
|
|
16177
16195
|
}
|
|
16178
|
-
function
|
|
16196
|
+
function Qw(t) {
|
|
16179
16197
|
var e = /firefox/i.test(ds()), n = /Trident/i.test(ds());
|
|
16180
16198
|
if (n && je(t)) {
|
|
16181
16199
|
var r = St(t);
|
|
@@ -16192,9 +16210,9 @@ function Zw(t) {
|
|
|
16192
16210
|
return null;
|
|
16193
16211
|
}
|
|
16194
16212
|
function Pr(t) {
|
|
16195
|
-
for (var e = Re(t), n = Tl(t); n &&
|
|
16213
|
+
for (var e = Re(t), n = Tl(t); n && Zw(n) && St(n).position === "static"; )
|
|
16196
16214
|
n = Tl(n);
|
|
16197
|
-
return n && (st(n) === "html" || st(n) === "body" && St(n).position === "static") ? e : n ||
|
|
16215
|
+
return n && (st(n) === "html" || st(n) === "body" && St(n).position === "static") ? e : n || Qw(t) || e;
|
|
16198
16216
|
}
|
|
16199
16217
|
function Ws(t) {
|
|
16200
16218
|
return ["top", "bottom"].indexOf(t) >= 0 ? "x" : "y";
|
|
@@ -16202,7 +16220,7 @@ function Ws(t) {
|
|
|
16202
16220
|
function ir(t, e, n) {
|
|
16203
16221
|
return on(t, Oo(e, n));
|
|
16204
16222
|
}
|
|
16205
|
-
function
|
|
16223
|
+
function ev(t, e, n) {
|
|
16206
16224
|
var r = ir(t, e, n);
|
|
16207
16225
|
return r > n ? n : r;
|
|
16208
16226
|
}
|
|
@@ -16222,41 +16240,41 @@ function Wu(t, e) {
|
|
|
16222
16240
|
return n[r] = t, n;
|
|
16223
16241
|
}, {});
|
|
16224
16242
|
}
|
|
16225
|
-
var
|
|
16243
|
+
var tv = function(e, n) {
|
|
16226
16244
|
return e = typeof e == "function" ? e(Object.assign({}, n.rects, {
|
|
16227
16245
|
placement: n.placement
|
|
16228
16246
|
})) : e, ju(typeof e != "number" ? e : Wu(e, Ir));
|
|
16229
16247
|
};
|
|
16230
|
-
function
|
|
16248
|
+
function nv(t) {
|
|
16231
16249
|
var e, n = t.state, r = t.name, o = t.options, i = n.elements.arrow, s = n.modifiersData.popperOffsets, a = rt(n.placement), l = Ws(a), c = [De, Ue].indexOf(a) >= 0, d = c ? "height" : "width";
|
|
16232
16250
|
if (!(!i || !s)) {
|
|
16233
|
-
var u =
|
|
16251
|
+
var u = tv(o.padding, n), f = js(i), p = l === "y" ? Te : De, h = l === "y" ? We : Ue, m = n.rects.reference[d] + n.rects.reference[l] - s[l] - n.rects.popper[d], g = s[l] - n.rects.reference[l], b = Pr(i), w = b ? l === "y" ? b.clientHeight || 0 : b.clientWidth || 0 : 0, C = m / 2 - g / 2, y = u[p], S = w - f[d] - u[h], k = w / 2 - f[d] / 2 + C, M = ir(y, k, S), L = l;
|
|
16234
16252
|
n.modifiersData[r] = (e = {}, e[L] = M, e.centerOffset = M - k, e);
|
|
16235
16253
|
}
|
|
16236
16254
|
}
|
|
16237
|
-
function
|
|
16255
|
+
function rv(t) {
|
|
16238
16256
|
var e = t.state, n = t.options, r = n.element, o = r === void 0 ? "[data-popper-arrow]" : r;
|
|
16239
16257
|
o != null && (typeof o == "string" && (o = e.elements.popper.querySelector(o), !o) || Vu(e.elements.popper, o) && (e.elements.arrow = o));
|
|
16240
16258
|
}
|
|
16241
|
-
const
|
|
16259
|
+
const ov = {
|
|
16242
16260
|
name: "arrow",
|
|
16243
16261
|
enabled: !0,
|
|
16244
16262
|
phase: "main",
|
|
16245
|
-
fn:
|
|
16246
|
-
effect:
|
|
16263
|
+
fn: nv,
|
|
16264
|
+
effect: rv,
|
|
16247
16265
|
requires: ["popperOffsets"],
|
|
16248
16266
|
requiresIfExists: ["preventOverflow"]
|
|
16249
16267
|
};
|
|
16250
16268
|
function Fn(t) {
|
|
16251
16269
|
return t.split("-")[1];
|
|
16252
16270
|
}
|
|
16253
|
-
var
|
|
16271
|
+
var iv = {
|
|
16254
16272
|
top: "auto",
|
|
16255
16273
|
right: "auto",
|
|
16256
16274
|
bottom: "auto",
|
|
16257
16275
|
left: "auto"
|
|
16258
16276
|
};
|
|
16259
|
-
function
|
|
16277
|
+
function sv(t, e) {
|
|
16260
16278
|
var n = t.x, r = t.y, o = e.devicePixelRatio || 1;
|
|
16261
16279
|
return {
|
|
16262
16280
|
x: Rn(n * o) / o || 0,
|
|
@@ -16285,29 +16303,29 @@ function Dl(t) {
|
|
|
16285
16303
|
}
|
|
16286
16304
|
if (o === De || (o === Te || o === We) && i === Cr) {
|
|
16287
16305
|
C = Ue;
|
|
16288
|
-
var
|
|
16306
|
+
var z = u && k === S && S.visualViewport ? S.visualViewport.width : (
|
|
16289
16307
|
// $FlowFixMe[prop-missing]
|
|
16290
16308
|
k[L]
|
|
16291
16309
|
);
|
|
16292
|
-
p -=
|
|
16310
|
+
p -= z - r.width, p *= l ? 1 : -1;
|
|
16293
16311
|
}
|
|
16294
16312
|
}
|
|
16295
16313
|
var _ = Object.assign({
|
|
16296
16314
|
position: a
|
|
16297
|
-
}, c &&
|
|
16315
|
+
}, c && iv), V = d === !0 ? sv({
|
|
16298
16316
|
x: p,
|
|
16299
16317
|
y: m
|
|
16300
16318
|
}, Re(n)) : {
|
|
16301
16319
|
x: p,
|
|
16302
16320
|
y: m
|
|
16303
16321
|
};
|
|
16304
|
-
if (p =
|
|
16322
|
+
if (p = V.x, m = V.y, l) {
|
|
16305
16323
|
var j;
|
|
16306
16324
|
return Object.assign({}, _, (j = {}, j[y] = w ? "0" : "", j[C] = b ? "0" : "", j.transform = (S.devicePixelRatio || 1) <= 1 ? "translate(" + p + "px, " + m + "px)" : "translate3d(" + p + "px, " + m + "px, 0)", j));
|
|
16307
16325
|
}
|
|
16308
16326
|
return Object.assign({}, _, (e = {}, e[y] = w ? m + "px" : "", e[C] = b ? p + "px" : "", e.transform = "", e));
|
|
16309
16327
|
}
|
|
16310
|
-
function
|
|
16328
|
+
function av(t) {
|
|
16311
16329
|
var e = t.state, n = t.options, r = n.gpuAcceleration, o = r === void 0 ? !0 : r, i = n.adaptive, s = i === void 0 ? !0 : i, a = n.roundOffsets, l = a === void 0 ? !0 : a, c = {
|
|
16312
16330
|
placement: rt(e.placement),
|
|
16313
16331
|
variation: Fn(e.placement),
|
|
@@ -16330,17 +16348,17 @@ function sv(t) {
|
|
|
16330
16348
|
"data-popper-placement": e.placement
|
|
16331
16349
|
});
|
|
16332
16350
|
}
|
|
16333
|
-
const
|
|
16351
|
+
const lv = {
|
|
16334
16352
|
name: "computeStyles",
|
|
16335
16353
|
enabled: !0,
|
|
16336
16354
|
phase: "beforeWrite",
|
|
16337
|
-
fn:
|
|
16355
|
+
fn: av,
|
|
16338
16356
|
data: {}
|
|
16339
16357
|
};
|
|
16340
16358
|
var Qr = {
|
|
16341
16359
|
passive: !0
|
|
16342
16360
|
};
|
|
16343
|
-
function
|
|
16361
|
+
function cv(t) {
|
|
16344
16362
|
var e = t.state, n = t.instance, r = t.options, o = r.scroll, i = o === void 0 ? !0 : o, s = r.resize, a = s === void 0 ? !0 : s, l = Re(e.elements.popper), c = [].concat(e.scrollParents.reference, e.scrollParents.popper);
|
|
16345
16363
|
return i && c.forEach(function(d) {
|
|
16346
16364
|
d.addEventListener("scroll", n.update, Qr);
|
|
@@ -16350,16 +16368,16 @@ function lv(t) {
|
|
|
16350
16368
|
}), a && l.removeEventListener("resize", n.update, Qr);
|
|
16351
16369
|
};
|
|
16352
16370
|
}
|
|
16353
|
-
const
|
|
16371
|
+
const dv = {
|
|
16354
16372
|
name: "eventListeners",
|
|
16355
16373
|
enabled: !0,
|
|
16356
16374
|
phase: "write",
|
|
16357
16375
|
fn: function() {
|
|
16358
16376
|
},
|
|
16359
|
-
effect:
|
|
16377
|
+
effect: cv,
|
|
16360
16378
|
data: {}
|
|
16361
16379
|
};
|
|
16362
|
-
var
|
|
16380
|
+
var uv = {
|
|
16363
16381
|
left: "right",
|
|
16364
16382
|
right: "left",
|
|
16365
16383
|
bottom: "top",
|
|
@@ -16367,16 +16385,16 @@ var dv = {
|
|
|
16367
16385
|
};
|
|
16368
16386
|
function uo(t) {
|
|
16369
16387
|
return t.replace(/left|right|bottom|top/g, function(e) {
|
|
16370
|
-
return
|
|
16388
|
+
return uv[e];
|
|
16371
16389
|
});
|
|
16372
16390
|
}
|
|
16373
|
-
var
|
|
16391
|
+
var fv = {
|
|
16374
16392
|
start: "end",
|
|
16375
16393
|
end: "start"
|
|
16376
16394
|
};
|
|
16377
16395
|
function Nl(t) {
|
|
16378
16396
|
return t.replace(/start|end/g, function(e) {
|
|
16379
|
-
return
|
|
16397
|
+
return fv[e];
|
|
16380
16398
|
});
|
|
16381
16399
|
}
|
|
16382
16400
|
function Us(t) {
|
|
@@ -16389,7 +16407,7 @@ function Us(t) {
|
|
|
16389
16407
|
function qs(t) {
|
|
16390
16408
|
return Ln(Wt(t)).left + Us(t).scrollLeft;
|
|
16391
16409
|
}
|
|
16392
|
-
function
|
|
16410
|
+
function pv(t, e) {
|
|
16393
16411
|
var n = Re(t), r = Wt(t), o = n.visualViewport, i = r.clientWidth, s = r.clientHeight, a = 0, l = 0;
|
|
16394
16412
|
if (o) {
|
|
16395
16413
|
i = o.width, s = o.height;
|
|
@@ -16403,7 +16421,7 @@ function fv(t, e) {
|
|
|
16403
16421
|
y: l
|
|
16404
16422
|
};
|
|
16405
16423
|
}
|
|
16406
|
-
function
|
|
16424
|
+
function hv(t) {
|
|
16407
16425
|
var e, n = Wt(t), r = Us(t), o = (e = t.ownerDocument) == null ? void 0 : e.body, i = on(n.scrollWidth, n.clientWidth, o ? o.scrollWidth : 0, o ? o.clientWidth : 0), s = on(n.scrollHeight, n.clientHeight, o ? o.scrollHeight : 0, o ? o.clientHeight : 0), a = -r.scrollLeft + qs(t), l = -r.scrollTop;
|
|
16408
16426
|
return St(o || n).direction === "rtl" && (a += on(n.clientWidth, o ? o.clientWidth : 0) - i), {
|
|
16409
16427
|
width: i,
|
|
@@ -16436,21 +16454,21 @@ function us(t) {
|
|
|
16436
16454
|
bottom: t.y + t.height
|
|
16437
16455
|
});
|
|
16438
16456
|
}
|
|
16439
|
-
function
|
|
16457
|
+
function mv(t, e) {
|
|
16440
16458
|
var n = Ln(t, !1, e === "fixed");
|
|
16441
16459
|
return n.top = n.top + t.clientTop, n.left = n.left + t.clientLeft, n.bottom = n.top + t.clientHeight, n.right = n.left + t.clientWidth, n.width = t.clientWidth, n.height = t.clientHeight, n.x = n.left, n.y = n.top, n;
|
|
16442
16460
|
}
|
|
16443
16461
|
function El(t, e, n) {
|
|
16444
|
-
return e === Bu ? us(
|
|
16462
|
+
return e === Bu ? us(pv(t, n)) : dn(e) ? mv(e, n) : us(hv(Wt(t)));
|
|
16445
16463
|
}
|
|
16446
|
-
function
|
|
16464
|
+
function gv(t) {
|
|
16447
16465
|
var e = sr(zo(t)), n = ["absolute", "fixed"].indexOf(St(t).position) >= 0, r = n && je(t) ? Pr(t) : t;
|
|
16448
16466
|
return dn(r) ? e.filter(function(o) {
|
|
16449
16467
|
return dn(o) && Vu(o, r) && st(o) !== "body";
|
|
16450
16468
|
}) : [];
|
|
16451
16469
|
}
|
|
16452
|
-
function
|
|
16453
|
-
var o = e === "clippingParents" ?
|
|
16470
|
+
function yv(t, e, n, r) {
|
|
16471
|
+
var o = e === "clippingParents" ? gv(t) : [].concat(e), i = [].concat(o, [n]), s = i[0], a = i.reduce(function(l, c) {
|
|
16454
16472
|
var d = El(t, c, r);
|
|
16455
16473
|
return l.top = on(d.top, l.top), l.right = Oo(d.right, l.right), l.bottom = Oo(d.bottom, l.bottom), l.left = on(d.left, l.left), l;
|
|
16456
16474
|
}, El(t, s, r));
|
|
@@ -16505,26 +16523,26 @@ function qu(t) {
|
|
|
16505
16523
|
}
|
|
16506
16524
|
function Sr(t, e) {
|
|
16507
16525
|
e === void 0 && (e = {});
|
|
16508
|
-
var n = e, r = n.placement, o = r === void 0 ? t.placement : r, i = n.strategy, s = i === void 0 ? t.strategy : i, a = n.boundary, l = a === void 0 ?
|
|
16526
|
+
var n = e, r = n.placement, o = r === void 0 ? t.placement : r, i = n.strategy, s = i === void 0 ? t.strategy : i, a = n.boundary, l = a === void 0 ? _w : a, c = n.rootBoundary, d = c === void 0 ? Bu : c, u = n.elementContext, f = u === void 0 ? Jn : u, p = n.altBoundary, h = p === void 0 ? !1 : p, m = n.padding, g = m === void 0 ? 0 : m, b = ju(typeof g != "number" ? g : Wu(g, Ir)), w = f === Jn ? zw : Jn, C = t.rects.popper, y = t.elements[h ? w : f], S = yv(dn(y) ? y : y.contextElement || Wt(t.elements.popper), l, d, s), k = Ln(t.elements.reference), M = qu({
|
|
16509
16527
|
reference: k,
|
|
16510
16528
|
element: C,
|
|
16511
16529
|
placement: o
|
|
16512
|
-
}), L = us(Object.assign({}, C, M)), x = f === Jn ? L : k,
|
|
16530
|
+
}), L = us(Object.assign({}, C, M)), x = f === Jn ? L : k, z = {
|
|
16513
16531
|
top: S.top - x.top + b.top,
|
|
16514
16532
|
bottom: x.bottom - S.bottom + b.bottom,
|
|
16515
16533
|
left: S.left - x.left + b.left,
|
|
16516
16534
|
right: x.right - S.right + b.right
|
|
16517
16535
|
}, _ = t.modifiersData.offset;
|
|
16518
16536
|
if (f === Jn && _) {
|
|
16519
|
-
var
|
|
16520
|
-
Object.keys(
|
|
16537
|
+
var V = _[o];
|
|
16538
|
+
Object.keys(z).forEach(function(j) {
|
|
16521
16539
|
var se = [Ue, We].indexOf(j) >= 0 ? 1 : -1, ce = [Te, We].indexOf(j) >= 0 ? "y" : "x";
|
|
16522
|
-
|
|
16540
|
+
z[j] += V[ce] * se;
|
|
16523
16541
|
});
|
|
16524
16542
|
}
|
|
16525
|
-
return
|
|
16543
|
+
return z;
|
|
16526
16544
|
}
|
|
16527
|
-
function
|
|
16545
|
+
function bv(t, e) {
|
|
16528
16546
|
e === void 0 && (e = {});
|
|
16529
16547
|
var n = e, r = n.placement, o = n.boundary, i = n.rootBoundary, s = n.padding, a = n.flipVariations, l = n.allowedAutoPlacements, c = l === void 0 ? _u : l, d = Fn(r), u = d ? a ? Ol : Ol.filter(function(h) {
|
|
16530
16548
|
return Fn(h) === d;
|
|
@@ -16544,17 +16562,17 @@ function yv(t, e) {
|
|
|
16544
16562
|
return p[h] - p[m];
|
|
16545
16563
|
});
|
|
16546
16564
|
}
|
|
16547
|
-
function
|
|
16565
|
+
function wv(t) {
|
|
16548
16566
|
if (rt(t) === Vs)
|
|
16549
16567
|
return [];
|
|
16550
16568
|
var e = uo(t);
|
|
16551
16569
|
return [Nl(t), e, Nl(e)];
|
|
16552
16570
|
}
|
|
16553
|
-
function
|
|
16571
|
+
function vv(t) {
|
|
16554
16572
|
var e = t.state, n = t.options, r = t.name;
|
|
16555
16573
|
if (!e.modifiersData[r]._skip) {
|
|
16556
|
-
for (var o = n.mainAxis, i = o === void 0 ? !0 : o, s = n.altAxis, a = s === void 0 ? !0 : s, l = n.fallbackPlacements, c = n.padding, d = n.boundary, u = n.rootBoundary, f = n.altBoundary, p = n.flipVariations, h = p === void 0 ? !0 : p, m = n.allowedAutoPlacements, g = e.options.placement, b = rt(g), w = b === g, C = l || (w || !h ? [uo(g)] :
|
|
16557
|
-
return qe.concat(rt(Ne) === Vs ?
|
|
16574
|
+
for (var o = n.mainAxis, i = o === void 0 ? !0 : o, s = n.altAxis, a = s === void 0 ? !0 : s, l = n.fallbackPlacements, c = n.padding, d = n.boundary, u = n.rootBoundary, f = n.altBoundary, p = n.flipVariations, h = p === void 0 ? !0 : p, m = n.allowedAutoPlacements, g = e.options.placement, b = rt(g), w = b === g, C = l || (w || !h ? [uo(g)] : wv(g)), y = [g].concat(C).reduce(function(qe, Ne) {
|
|
16575
|
+
return qe.concat(rt(Ne) === Vs ? bv(e, {
|
|
16558
16576
|
placement: Ne,
|
|
16559
16577
|
boundary: d,
|
|
16560
16578
|
rootBoundary: u,
|
|
@@ -16562,8 +16580,8 @@ function wv(t) {
|
|
|
16562
16580
|
flipVariations: h,
|
|
16563
16581
|
allowedAutoPlacements: m
|
|
16564
16582
|
}) : Ne);
|
|
16565
|
-
}, []), S = e.rects.reference, k = e.rects.popper, M = /* @__PURE__ */ new Map(), L = !0, x = y[0],
|
|
16566
|
-
var _ = y[
|
|
16583
|
+
}, []), S = e.rects.reference, k = e.rects.popper, M = /* @__PURE__ */ new Map(), L = !0, x = y[0], z = 0; z < y.length; z++) {
|
|
16584
|
+
var _ = y[z], V = rt(_), j = Fn(_) === Pn, se = [Te, We].indexOf(V) >= 0, ce = se ? "width" : "height", ae = Sr(e, {
|
|
16567
16585
|
placement: _,
|
|
16568
16586
|
boundary: d,
|
|
16569
16587
|
rootBoundary: u,
|
|
@@ -16572,7 +16590,7 @@ function wv(t) {
|
|
|
16572
16590
|
}), ee = se ? j ? Ue : De : j ? We : Te;
|
|
16573
16591
|
S[ce] > k[ce] && (ee = uo(ee));
|
|
16574
16592
|
var ne = uo(ee), ve = [];
|
|
16575
|
-
if (i && ve.push(ae[
|
|
16593
|
+
if (i && ve.push(ae[V] <= 0), a && ve.push(ae[ee] <= 0, ae[ne] <= 0), ve.every(function(qe) {
|
|
16576
16594
|
return qe;
|
|
16577
16595
|
})) {
|
|
16578
16596
|
x = _, L = !1;
|
|
@@ -16598,11 +16616,11 @@ function wv(t) {
|
|
|
16598
16616
|
e.placement !== x && (e.modifiersData[r]._skip = !0, e.placement = x, e.reset = !0);
|
|
16599
16617
|
}
|
|
16600
16618
|
}
|
|
16601
|
-
const
|
|
16619
|
+
const kv = {
|
|
16602
16620
|
name: "flip",
|
|
16603
16621
|
enabled: !0,
|
|
16604
16622
|
phase: "main",
|
|
16605
|
-
fn:
|
|
16623
|
+
fn: vv,
|
|
16606
16624
|
requiresIfExists: ["offset"],
|
|
16607
16625
|
data: {
|
|
16608
16626
|
_skip: !1
|
|
@@ -16624,7 +16642,7 @@ function Pl(t) {
|
|
|
16624
16642
|
return t[e] >= 0;
|
|
16625
16643
|
});
|
|
16626
16644
|
}
|
|
16627
|
-
function
|
|
16645
|
+
function Cv(t) {
|
|
16628
16646
|
var e = t.state, n = t.name, r = e.rects.reference, o = e.rects.popper, i = e.modifiersData.preventOverflow, s = Sr(e, {
|
|
16629
16647
|
elementContext: "reference"
|
|
16630
16648
|
}), a = Sr(e, {
|
|
@@ -16640,14 +16658,14 @@ function kv(t) {
|
|
|
16640
16658
|
"data-popper-escaped": u
|
|
16641
16659
|
});
|
|
16642
16660
|
}
|
|
16643
|
-
const
|
|
16661
|
+
const Sv = {
|
|
16644
16662
|
name: "hide",
|
|
16645
16663
|
enabled: !0,
|
|
16646
16664
|
phase: "main",
|
|
16647
16665
|
requiresIfExists: ["preventOverflow"],
|
|
16648
|
-
fn:
|
|
16666
|
+
fn: Cv
|
|
16649
16667
|
};
|
|
16650
|
-
function
|
|
16668
|
+
function xv(t, e, n) {
|
|
16651
16669
|
var r = rt(t), o = [De, Te].indexOf(r) >= 0 ? -1 : 1, i = typeof n == "function" ? n(Object.assign({}, e, {
|
|
16652
16670
|
placement: t
|
|
16653
16671
|
})) : n, s = i[0], a = i[1];
|
|
@@ -16659,20 +16677,20 @@ function Sv(t, e, n) {
|
|
|
16659
16677
|
y: a
|
|
16660
16678
|
};
|
|
16661
16679
|
}
|
|
16662
|
-
function
|
|
16680
|
+
function Mv(t) {
|
|
16663
16681
|
var e = t.state, n = t.options, r = t.name, o = n.offset, i = o === void 0 ? [0, 0] : o, s = _u.reduce(function(d, u) {
|
|
16664
|
-
return d[u] =
|
|
16682
|
+
return d[u] = xv(u, e.rects, i), d;
|
|
16665
16683
|
}, {}), a = s[e.placement], l = a.x, c = a.y;
|
|
16666
16684
|
e.modifiersData.popperOffsets != null && (e.modifiersData.popperOffsets.x += l, e.modifiersData.popperOffsets.y += c), e.modifiersData[r] = s;
|
|
16667
16685
|
}
|
|
16668
|
-
const
|
|
16686
|
+
const Av = {
|
|
16669
16687
|
name: "offset",
|
|
16670
16688
|
enabled: !0,
|
|
16671
16689
|
phase: "main",
|
|
16672
16690
|
requires: ["popperOffsets"],
|
|
16673
|
-
fn:
|
|
16691
|
+
fn: Mv
|
|
16674
16692
|
};
|
|
16675
|
-
function
|
|
16693
|
+
function Ov(t) {
|
|
16676
16694
|
var e = t.state, n = t.name;
|
|
16677
16695
|
e.modifiersData[n] = qu({
|
|
16678
16696
|
reference: e.rects.reference,
|
|
@@ -16680,31 +16698,31 @@ function Av(t) {
|
|
|
16680
16698
|
placement: e.placement
|
|
16681
16699
|
});
|
|
16682
16700
|
}
|
|
16683
|
-
const
|
|
16701
|
+
const Tv = {
|
|
16684
16702
|
name: "popperOffsets",
|
|
16685
16703
|
enabled: !0,
|
|
16686
16704
|
phase: "read",
|
|
16687
|
-
fn:
|
|
16705
|
+
fn: Ov,
|
|
16688
16706
|
data: {}
|
|
16689
16707
|
};
|
|
16690
|
-
function
|
|
16708
|
+
function Dv(t) {
|
|
16691
16709
|
return t === "x" ? "y" : "x";
|
|
16692
16710
|
}
|
|
16693
|
-
function
|
|
16711
|
+
function Nv(t) {
|
|
16694
16712
|
var e = t.state, n = t.options, r = t.name, o = n.mainAxis, i = o === void 0 ? !0 : o, s = n.altAxis, a = s === void 0 ? !1 : s, l = n.boundary, c = n.rootBoundary, d = n.altBoundary, u = n.padding, f = n.tether, p = f === void 0 ? !0 : f, h = n.tetherOffset, m = h === void 0 ? 0 : h, g = Sr(e, {
|
|
16695
16713
|
boundary: l,
|
|
16696
16714
|
rootBoundary: c,
|
|
16697
16715
|
padding: u,
|
|
16698
16716
|
altBoundary: d
|
|
16699
|
-
}), b = rt(e.placement), w = Fn(e.placement), C = !w, y = Ws(b), S =
|
|
16717
|
+
}), b = rt(e.placement), w = Fn(e.placement), C = !w, y = Ws(b), S = Dv(y), k = e.modifiersData.popperOffsets, M = e.rects.reference, L = e.rects.popper, x = typeof m == "function" ? m(Object.assign({}, e.rects, {
|
|
16700
16718
|
placement: e.placement
|
|
16701
|
-
})) : m,
|
|
16719
|
+
})) : m, z = typeof x == "number" ? {
|
|
16702
16720
|
mainAxis: x,
|
|
16703
16721
|
altAxis: x
|
|
16704
16722
|
} : Object.assign({
|
|
16705
16723
|
mainAxis: 0,
|
|
16706
16724
|
altAxis: 0
|
|
16707
|
-
}, x), _ = e.modifiersData.offset ? e.modifiersData.offset[e.placement] : null,
|
|
16725
|
+
}, x), _ = e.modifiersData.offset ? e.modifiersData.offset[e.placement] : null, V = {
|
|
16708
16726
|
x: 0,
|
|
16709
16727
|
y: 0
|
|
16710
16728
|
};
|
|
@@ -16713,39 +16731,39 @@ function Dv(t) {
|
|
|
16713
16731
|
var j, se = y === "y" ? Te : De, ce = y === "y" ? We : Ue, ae = y === "y" ? "height" : "width", ee = k[y], ne = ee + g[se], ve = ee - g[ce], ke = p ? -L[ae] / 2 : 0, lt = w === Pn ? M[ae] : L[ae], Fe = w === Pn ? -L[ae] : -M[ae], ct = e.elements.arrow, qe = p && ct ? js(ct) : {
|
|
16714
16732
|
width: 0,
|
|
16715
16733
|
height: 0
|
|
16716
|
-
}, Ne = e.modifiersData["arrow#persistent"] ? e.modifiersData["arrow#persistent"].padding : Hu(), Ke = Ne[se], Mt = Ne[ce], dt = ir(0, M[ae], qe[ae]), un = C ? M[ae] / 2 - ke - dt - Ke -
|
|
16717
|
-
k[y] = jn,
|
|
16734
|
+
}, Ne = e.modifiersData["arrow#persistent"] ? e.modifiersData["arrow#persistent"].padding : Hu(), Ke = Ne[se], Mt = Ne[ce], dt = ir(0, M[ae], qe[ae]), un = C ? M[ae] / 2 - ke - dt - Ke - z.mainAxis : lt - dt - Ke - z.mainAxis, At = C ? -M[ae] / 2 + ke + dt + Mt + z.mainAxis : Fe + dt + Mt + z.mainAxis, fn = e.elements.arrow && Pr(e.elements.arrow), Lr = fn ? y === "y" ? fn.clientTop || 0 : fn.clientLeft || 0 : 0, Hn = (j = _?.[y]) != null ? j : 0, Fr = ee + un - Hn - Lr, Br = ee + At - Hn, jn = ir(p ? Oo(ne, Fr) : ne, ee, p ? on(ve, Br) : ve);
|
|
16735
|
+
k[y] = jn, V[y] = jn - ee;
|
|
16718
16736
|
}
|
|
16719
16737
|
if (a) {
|
|
16720
|
-
var Wn, _r = y === "x" ? Te : De, zr = y === "x" ? We : Ue, ut = k[S], Ot = S === "y" ? "height" : "width", Un = ut + g[_r], Ut = ut - g[zr], qn = [Te, De].indexOf(b) !== -1, $r = (Wn = _?.[S]) != null ? Wn : 0, Vr = qn ? Un : ut - M[Ot] - L[Ot] - $r +
|
|
16721
|
-
k[S] = jr,
|
|
16738
|
+
var Wn, _r = y === "x" ? Te : De, zr = y === "x" ? We : Ue, ut = k[S], Ot = S === "y" ? "height" : "width", Un = ut + g[_r], Ut = ut - g[zr], qn = [Te, De].indexOf(b) !== -1, $r = (Wn = _?.[S]) != null ? Wn : 0, Vr = qn ? Un : ut - M[Ot] - L[Ot] - $r + z.altAxis, Hr = qn ? ut + M[Ot] + L[Ot] - $r - z.altAxis : Ut, jr = p && qn ? ev(Vr, ut, Hr) : ir(p ? Vr : Un, ut, p ? Hr : Ut);
|
|
16739
|
+
k[S] = jr, V[S] = jr - ut;
|
|
16722
16740
|
}
|
|
16723
|
-
e.modifiersData[r] =
|
|
16741
|
+
e.modifiersData[r] = V;
|
|
16724
16742
|
}
|
|
16725
16743
|
}
|
|
16726
|
-
const
|
|
16744
|
+
const Ev = {
|
|
16727
16745
|
name: "preventOverflow",
|
|
16728
16746
|
enabled: !0,
|
|
16729
16747
|
phase: "main",
|
|
16730
|
-
fn:
|
|
16748
|
+
fn: Nv,
|
|
16731
16749
|
requiresIfExists: ["offset"]
|
|
16732
16750
|
};
|
|
16733
|
-
function
|
|
16751
|
+
function Iv(t) {
|
|
16734
16752
|
return {
|
|
16735
16753
|
scrollLeft: t.scrollLeft,
|
|
16736
16754
|
scrollTop: t.scrollTop
|
|
16737
16755
|
};
|
|
16738
16756
|
}
|
|
16739
|
-
function Iv(t) {
|
|
16740
|
-
return t === Re(t) || !je(t) ? Us(t) : Ev(t);
|
|
16741
|
-
}
|
|
16742
16757
|
function Pv(t) {
|
|
16758
|
+
return t === Re(t) || !je(t) ? Us(t) : Iv(t);
|
|
16759
|
+
}
|
|
16760
|
+
function Rv(t) {
|
|
16743
16761
|
var e = t.getBoundingClientRect(), n = Rn(e.width) / t.offsetWidth || 1, r = Rn(e.height) / t.offsetHeight || 1;
|
|
16744
16762
|
return n !== 1 || r !== 1;
|
|
16745
16763
|
}
|
|
16746
|
-
function
|
|
16764
|
+
function Lv(t, e, n) {
|
|
16747
16765
|
n === void 0 && (n = !1);
|
|
16748
|
-
var r = je(e), o = je(e) &&
|
|
16766
|
+
var r = je(e), o = je(e) && Rv(e), i = Wt(e), s = Ln(t, o, n), a = {
|
|
16749
16767
|
scrollLeft: 0,
|
|
16750
16768
|
scrollTop: 0
|
|
16751
16769
|
}, l = {
|
|
@@ -16753,14 +16771,14 @@ function Rv(t, e, n) {
|
|
|
16753
16771
|
y: 0
|
|
16754
16772
|
};
|
|
16755
16773
|
return (r || !r && !n) && ((st(e) !== "body" || // https://github.com/popperjs/popper-core/issues/1078
|
|
16756
|
-
Ks(i)) && (a =
|
|
16774
|
+
Ks(i)) && (a = Pv(e)), je(e) ? (l = Ln(e, !0), l.x += e.clientLeft, l.y += e.clientTop) : i && (l.x = qs(i))), {
|
|
16757
16775
|
x: s.left + a.scrollLeft - l.x,
|
|
16758
16776
|
y: s.top + a.scrollTop - l.y,
|
|
16759
16777
|
width: s.width,
|
|
16760
16778
|
height: s.height
|
|
16761
16779
|
};
|
|
16762
16780
|
}
|
|
16763
|
-
function
|
|
16781
|
+
function Fv(t) {
|
|
16764
16782
|
var e = /* @__PURE__ */ new Map(), n = /* @__PURE__ */ new Set(), r = [];
|
|
16765
16783
|
t.forEach(function(i) {
|
|
16766
16784
|
e.set(i.name, i);
|
|
@@ -16779,15 +16797,15 @@ function Lv(t) {
|
|
|
16779
16797
|
n.has(i.name) || o(i);
|
|
16780
16798
|
}), r;
|
|
16781
16799
|
}
|
|
16782
|
-
function
|
|
16783
|
-
var e =
|
|
16784
|
-
return
|
|
16800
|
+
function Bv(t) {
|
|
16801
|
+
var e = Fv(t);
|
|
16802
|
+
return Jw.reduce(function(n, r) {
|
|
16785
16803
|
return n.concat(e.filter(function(o) {
|
|
16786
16804
|
return o.phase === r;
|
|
16787
16805
|
}));
|
|
16788
16806
|
}, []);
|
|
16789
16807
|
}
|
|
16790
|
-
function
|
|
16808
|
+
function _v(t) {
|
|
16791
16809
|
var e;
|
|
16792
16810
|
return function() {
|
|
16793
16811
|
return e || (e = new Promise(function(n) {
|
|
@@ -16797,7 +16815,7 @@ function Bv(t) {
|
|
|
16797
16815
|
})), e;
|
|
16798
16816
|
};
|
|
16799
16817
|
}
|
|
16800
|
-
function
|
|
16818
|
+
function zv(t) {
|
|
16801
16819
|
var e = t.reduce(function(n, r) {
|
|
16802
16820
|
var o = n[r.name];
|
|
16803
16821
|
return n[r.name] = o ? Object.assign({}, o, r, {
|
|
@@ -16821,7 +16839,7 @@ function Ll() {
|
|
|
16821
16839
|
return !(r && typeof r.getBoundingClientRect == "function");
|
|
16822
16840
|
});
|
|
16823
16841
|
}
|
|
16824
|
-
function
|
|
16842
|
+
function $v(t) {
|
|
16825
16843
|
t === void 0 && (t = {});
|
|
16826
16844
|
var e = t, n = e.defaultModifiers, r = n === void 0 ? [] : n, o = e.defaultOptions, i = o === void 0 ? Rl : o;
|
|
16827
16845
|
return function(a, l, c) {
|
|
@@ -16845,7 +16863,7 @@ function zv(t) {
|
|
|
16845
16863
|
reference: dn(a) ? sr(a) : a.contextElement ? sr(a.contextElement) : [],
|
|
16846
16864
|
popper: sr(l)
|
|
16847
16865
|
};
|
|
16848
|
-
var C =
|
|
16866
|
+
var C = Bv(zv([].concat(r, d.options.modifiers)));
|
|
16849
16867
|
return d.orderedModifiers = C.filter(function(y) {
|
|
16850
16868
|
return y.enabled;
|
|
16851
16869
|
}), h(), p.update();
|
|
@@ -16860,10 +16878,10 @@ function zv(t) {
|
|
|
16860
16878
|
var b = d.elements, w = b.reference, C = b.popper;
|
|
16861
16879
|
if (Ll(w, C)) {
|
|
16862
16880
|
d.rects = {
|
|
16863
|
-
reference:
|
|
16881
|
+
reference: Lv(w, Pr(C), d.options.strategy === "fixed"),
|
|
16864
16882
|
popper: js(C)
|
|
16865
|
-
}, d.reset = !1, d.placement = d.options.placement, d.orderedModifiers.forEach(function(
|
|
16866
|
-
return d.modifiersData[
|
|
16883
|
+
}, d.reset = !1, d.placement = d.options.placement, d.orderedModifiers.forEach(function(z) {
|
|
16884
|
+
return d.modifiersData[z.name] = Object.assign({}, z.data);
|
|
16867
16885
|
});
|
|
16868
16886
|
for (var y = 0; y < d.orderedModifiers.length; y++) {
|
|
16869
16887
|
if (d.reset === !0) {
|
|
@@ -16883,7 +16901,7 @@ function zv(t) {
|
|
|
16883
16901
|
},
|
|
16884
16902
|
// Async and optimistically optimized update – it will not be executed if
|
|
16885
16903
|
// not necessary (debounced to run at most once-per-tick)
|
|
16886
|
-
update:
|
|
16904
|
+
update: _v(function() {
|
|
16887
16905
|
return new Promise(function(g) {
|
|
16888
16906
|
p.forceUpdate(), g(d);
|
|
16889
16907
|
});
|
|
@@ -16920,15 +16938,15 @@ function zv(t) {
|
|
|
16920
16938
|
return p;
|
|
16921
16939
|
};
|
|
16922
16940
|
}
|
|
16923
|
-
var
|
|
16924
|
-
defaultModifiers:
|
|
16925
|
-
}),
|
|
16941
|
+
var Vv = [dv, Tv, lv, zu, Av, kv, Ev, ov, Sv], Hv = /* @__PURE__ */ $v({
|
|
16942
|
+
defaultModifiers: Vv
|
|
16943
|
+
}), jv = "tippy-box", Ku = "tippy-content", Wv = "tippy-backdrop", Xu = "tippy-arrow", Ju = "tippy-svg-arrow", Yt = {
|
|
16926
16944
|
passive: !0,
|
|
16927
16945
|
capture: !0
|
|
16928
16946
|
}, Yu = function() {
|
|
16929
16947
|
return document.body;
|
|
16930
16948
|
};
|
|
16931
|
-
function
|
|
16949
|
+
function Uv(t, e) {
|
|
16932
16950
|
return {}.hasOwnProperty.call(t, e);
|
|
16933
16951
|
}
|
|
16934
16952
|
function ui(t, e, n) {
|
|
@@ -16955,13 +16973,13 @@ function Fl(t, e) {
|
|
|
16955
16973
|
}, e);
|
|
16956
16974
|
};
|
|
16957
16975
|
}
|
|
16958
|
-
function
|
|
16976
|
+
function qv(t, e) {
|
|
16959
16977
|
var n = Object.assign({}, t);
|
|
16960
16978
|
return e.forEach(function(r) {
|
|
16961
16979
|
delete n[r];
|
|
16962
16980
|
}), n;
|
|
16963
16981
|
}
|
|
16964
|
-
function
|
|
16982
|
+
function Kv(t) {
|
|
16965
16983
|
return t.split(/\s+/).filter(Boolean);
|
|
16966
16984
|
}
|
|
16967
16985
|
function xn(t) {
|
|
@@ -16970,12 +16988,12 @@ function xn(t) {
|
|
|
16970
16988
|
function Bl(t, e) {
|
|
16971
16989
|
t.indexOf(e) === -1 && t.push(e);
|
|
16972
16990
|
}
|
|
16973
|
-
function
|
|
16991
|
+
function Xv(t) {
|
|
16974
16992
|
return t.filter(function(e, n) {
|
|
16975
16993
|
return t.indexOf(e) === n;
|
|
16976
16994
|
});
|
|
16977
16995
|
}
|
|
16978
|
-
function
|
|
16996
|
+
function Jv(t) {
|
|
16979
16997
|
return t.split("-")[0];
|
|
16980
16998
|
}
|
|
16981
16999
|
function To(t) {
|
|
@@ -16994,17 +17012,17 @@ function xr(t) {
|
|
|
16994
17012
|
return Xs(t, e);
|
|
16995
17013
|
});
|
|
16996
17014
|
}
|
|
16997
|
-
function
|
|
17015
|
+
function Yv(t) {
|
|
16998
17016
|
return Xs(t, "NodeList");
|
|
16999
17017
|
}
|
|
17000
|
-
function
|
|
17018
|
+
function Gv(t) {
|
|
17001
17019
|
return Xs(t, "MouseEvent");
|
|
17002
17020
|
}
|
|
17003
|
-
function
|
|
17021
|
+
function Zv(t) {
|
|
17004
17022
|
return !!(t && t._tippy && t._tippy.reference === t);
|
|
17005
17023
|
}
|
|
17006
|
-
function
|
|
17007
|
-
return xr(t) ? [t] :
|
|
17024
|
+
function Qv(t) {
|
|
17025
|
+
return xr(t) ? [t] : Yv(t) ? To(t) : Array.isArray(t) ? t : To(document.querySelectorAll(t));
|
|
17008
17026
|
}
|
|
17009
17027
|
function fi(t, e) {
|
|
17010
17028
|
t.forEach(function(n) {
|
|
@@ -17016,14 +17034,14 @@ function zl(t, e) {
|
|
|
17016
17034
|
n && n.setAttribute("data-state", e);
|
|
17017
17035
|
});
|
|
17018
17036
|
}
|
|
17019
|
-
function
|
|
17037
|
+
function ek(t) {
|
|
17020
17038
|
var e, n = xn(t), r = n[0];
|
|
17021
17039
|
return r != null && (e = r.ownerDocument) != null && e.body ? r.ownerDocument : document;
|
|
17022
17040
|
}
|
|
17023
|
-
function
|
|
17041
|
+
function tk(t, e) {
|
|
17024
17042
|
var n = e.clientX, r = e.clientY;
|
|
17025
17043
|
return t.every(function(o) {
|
|
17026
|
-
var i = o.popperRect, s = o.popperState, a = o.props, l = a.interactiveBorder, c =
|
|
17044
|
+
var i = o.popperRect, s = o.popperState, a = o.props, l = a.interactiveBorder, c = Jv(s.placement), d = s.modifiersData.offset;
|
|
17027
17045
|
if (!d)
|
|
17028
17046
|
return !0;
|
|
17029
17047
|
var u = c === "bottom" ? d.top.y : 0, f = c === "top" ? d.bottom.y : 0, p = c === "right" ? d.left.x : 0, h = c === "left" ? d.right.x : 0, m = i.top - r + u > l, g = r - i.bottom - f > l, b = i.left - n + p > l, w = n - i.right - h > l;
|
|
@@ -17048,24 +17066,24 @@ function $l(t, e) {
|
|
|
17048
17066
|
var tt = {
|
|
17049
17067
|
isTouch: !1
|
|
17050
17068
|
}, Vl = 0;
|
|
17051
|
-
function
|
|
17069
|
+
function nk() {
|
|
17052
17070
|
tt.isTouch || (tt.isTouch = !0, window.performance && document.addEventListener("mousemove", Zu));
|
|
17053
17071
|
}
|
|
17054
17072
|
function Zu() {
|
|
17055
17073
|
var t = performance.now();
|
|
17056
17074
|
t - Vl < 20 && (tt.isTouch = !1, document.removeEventListener("mousemove", Zu)), Vl = t;
|
|
17057
17075
|
}
|
|
17058
|
-
function
|
|
17076
|
+
function rk() {
|
|
17059
17077
|
var t = document.activeElement;
|
|
17060
|
-
if (
|
|
17078
|
+
if (Zv(t)) {
|
|
17061
17079
|
var e = t._tippy;
|
|
17062
17080
|
t.blur && !e.state.isVisible && t.blur();
|
|
17063
17081
|
}
|
|
17064
17082
|
}
|
|
17065
|
-
function
|
|
17066
|
-
document.addEventListener("touchstart",
|
|
17083
|
+
function ok() {
|
|
17084
|
+
document.addEventListener("touchstart", nk, Yt), window.addEventListener("blur", rk);
|
|
17067
17085
|
}
|
|
17068
|
-
var
|
|
17086
|
+
var ik = typeof window < "u" && typeof document < "u", sk = ik ? (
|
|
17069
17087
|
// @ts-ignore
|
|
17070
17088
|
!!window.msCrypto
|
|
17071
17089
|
) : !1;
|
|
@@ -17077,7 +17095,7 @@ function Hl(t) {
|
|
|
17077
17095
|
var e = /[ \t]{2,}/g, n = /^[ \t]*/gm;
|
|
17078
17096
|
return t.replace(e, " ").replace(n, "").trim();
|
|
17079
17097
|
}
|
|
17080
|
-
function
|
|
17098
|
+
function ak(t) {
|
|
17081
17099
|
return Hl(`
|
|
17082
17100
|
%ctippy.js
|
|
17083
17101
|
|
|
@@ -17088,7 +17106,7 @@ function sk(t) {
|
|
|
17088
17106
|
}
|
|
17089
17107
|
function Qu(t) {
|
|
17090
17108
|
return [
|
|
17091
|
-
|
|
17109
|
+
ak(t),
|
|
17092
17110
|
// title
|
|
17093
17111
|
"color: #00C584; font-size: 1.3em; font-weight: bold;",
|
|
17094
17112
|
// message
|
|
@@ -17098,8 +17116,8 @@ function Qu(t) {
|
|
|
17098
17116
|
];
|
|
17099
17117
|
}
|
|
17100
17118
|
var Mr;
|
|
17101
|
-
ie.env.NODE_ENV !== "production" &&
|
|
17102
|
-
function
|
|
17119
|
+
ie.env.NODE_ENV !== "production" && lk();
|
|
17120
|
+
function lk() {
|
|
17103
17121
|
Mr = /* @__PURE__ */ new Set();
|
|
17104
17122
|
}
|
|
17105
17123
|
function gt(t, e) {
|
|
@@ -17114,7 +17132,7 @@ function fs(t, e) {
|
|
|
17114
17132
|
Mr.add(e), (n = console).error.apply(n, Qu(e));
|
|
17115
17133
|
}
|
|
17116
17134
|
}
|
|
17117
|
-
function
|
|
17135
|
+
function ck(t) {
|
|
17118
17136
|
var e = !t, n = Object.prototype.toString.call(t) === "[object Object]" && !t.addEventListener;
|
|
17119
17137
|
fs(e, ["tippy() was passed", "`" + String(t) + "`", "as its targets (first) argument. Valid types are: String, Element,", "Element[], or NodeList."].join(" ")), fs(n, ["tippy() was passed a plain object which is not supported as an argument", "for virtual positioning. Use props.getReferenceClientRect instead."].join(" "));
|
|
17120
17138
|
}
|
|
@@ -17123,7 +17141,7 @@ var ef = {
|
|
|
17123
17141
|
followCursor: !1,
|
|
17124
17142
|
inlinePositioning: !1,
|
|
17125
17143
|
sticky: !1
|
|
17126
|
-
},
|
|
17144
|
+
}, dk = {
|
|
17127
17145
|
allowHTML: !1,
|
|
17128
17146
|
animation: "fade",
|
|
17129
17147
|
arrow: !0,
|
|
@@ -17181,7 +17199,7 @@ var ef = {
|
|
|
17181
17199
|
touch: !0,
|
|
17182
17200
|
trigger: "mouseenter focus",
|
|
17183
17201
|
triggerTarget: null
|
|
17184
|
-
}, ef,
|
|
17202
|
+
}, ef, dk), uk = Object.keys(Ie), fk = function(e) {
|
|
17185
17203
|
ie.env.NODE_ENV !== "production" && nf(e, []);
|
|
17186
17204
|
var n = Object.keys(e);
|
|
17187
17205
|
n.forEach(function(r) {
|
|
@@ -17199,10 +17217,10 @@ function tf(t) {
|
|
|
17199
17217
|
}, {});
|
|
17200
17218
|
return Object.assign({}, t, n);
|
|
17201
17219
|
}
|
|
17202
|
-
function
|
|
17220
|
+
function pk(t, e) {
|
|
17203
17221
|
var n = e ? Object.keys(tf(Object.assign({}, Ie, {
|
|
17204
17222
|
plugins: e
|
|
17205
|
-
}))) :
|
|
17223
|
+
}))) : uk, r = n.reduce(function(o, i) {
|
|
17206
17224
|
var s = (t.getAttribute("data-tippy-" + i) || "").trim();
|
|
17207
17225
|
if (!s)
|
|
17208
17226
|
return o;
|
|
@@ -17221,7 +17239,7 @@ function fk(t, e) {
|
|
|
17221
17239
|
function jl(t, e) {
|
|
17222
17240
|
var n = Object.assign({}, e, {
|
|
17223
17241
|
content: Gu(e.content, [t])
|
|
17224
|
-
}, e.ignoreAttributes ? {} :
|
|
17242
|
+
}, e.ignoreAttributes ? {} : pk(t, e.plugins));
|
|
17225
17243
|
return n.aria = Object.assign({}, Ie.aria, n.aria), n.aria = {
|
|
17226
17244
|
expanded: n.aria.expanded === "auto" ? e.interactive : n.aria.expanded,
|
|
17227
17245
|
content: n.aria.content === "auto" ? e.interactive ? null : "describedby" : n.aria.content
|
|
@@ -17231,7 +17249,7 @@ function nf(t, e) {
|
|
|
17231
17249
|
t === void 0 && (t = {}), e === void 0 && (e = []);
|
|
17232
17250
|
var n = Object.keys(t);
|
|
17233
17251
|
n.forEach(function(r) {
|
|
17234
|
-
var o =
|
|
17252
|
+
var o = qv(Ie, Object.keys(ef)), i = !Uv(o, r);
|
|
17235
17253
|
i && (i = e.filter(function(s) {
|
|
17236
17254
|
return s.name === r;
|
|
17237
17255
|
}).length === 0), gt(i, ["`" + r + "`", "is not a valid prop. You may have spelled it incorrectly, or if it's", "a plugin, forgot to pass it in an array as props.plugins.", `
|
|
@@ -17240,11 +17258,11 @@ function nf(t, e) {
|
|
|
17240
17258
|
`, "Plugins: https://atomiks.github.io/tippyjs/v6/plugins/"].join(" "));
|
|
17241
17259
|
});
|
|
17242
17260
|
}
|
|
17243
|
-
var
|
|
17261
|
+
var hk = function() {
|
|
17244
17262
|
return "innerHTML";
|
|
17245
17263
|
};
|
|
17246
17264
|
function ps(t, e) {
|
|
17247
|
-
t[
|
|
17265
|
+
t[hk()] = e;
|
|
17248
17266
|
}
|
|
17249
17267
|
function Wl(t) {
|
|
17250
17268
|
var e = ar();
|
|
@@ -17264,13 +17282,13 @@ function hs(t) {
|
|
|
17264
17282
|
return r.classList.contains(Xu) || r.classList.contains(Ju);
|
|
17265
17283
|
}),
|
|
17266
17284
|
backdrop: n.find(function(r) {
|
|
17267
|
-
return r.classList.contains(
|
|
17285
|
+
return r.classList.contains(Wv);
|
|
17268
17286
|
})
|
|
17269
17287
|
};
|
|
17270
17288
|
}
|
|
17271
17289
|
function rf(t) {
|
|
17272
17290
|
var e = ar(), n = ar();
|
|
17273
|
-
n.className =
|
|
17291
|
+
n.className = jv, n.setAttribute("data-state", "hidden"), n.setAttribute("tabindex", "-1");
|
|
17274
17292
|
var r = ar();
|
|
17275
17293
|
r.className = Ku, r.setAttribute("data-state", "hidden"), Ul(r, t.props), e.appendChild(n), n.appendChild(r), o(t.props, t.props);
|
|
17276
17294
|
function o(i, s) {
|
|
@@ -17283,9 +17301,9 @@ function rf(t) {
|
|
|
17283
17301
|
};
|
|
17284
17302
|
}
|
|
17285
17303
|
rf.$$tippy = !0;
|
|
17286
|
-
var
|
|
17287
|
-
function
|
|
17288
|
-
var n = jl(t, Object.assign({}, Ie, tf(_l(e)))), r, o, i, s = !1, a = !1, l = !1, c = !1, d, u, f, p = [], h = Fl(Fr, n.interactiveDebounce), m, g =
|
|
17304
|
+
var mk = 1, eo = [], hi = [];
|
|
17305
|
+
function gk(t, e) {
|
|
17306
|
+
var n = jl(t, Object.assign({}, Ie, tf(_l(e)))), r, o, i, s = !1, a = !1, l = !1, c = !1, d, u, f, p = [], h = Fl(Fr, n.interactiveDebounce), m, g = mk++, b = null, w = Xv(n.plugins), C = {
|
|
17289
17307
|
// Is the instance currently enabled?
|
|
17290
17308
|
isEnabled: !0,
|
|
17291
17309
|
// Is the tippy currently showing and not transitioning out?
|
|
@@ -17329,14 +17347,14 @@ function mk(t, e) {
|
|
|
17329
17347
|
}), k.addEventListener("mouseleave", function() {
|
|
17330
17348
|
y.props.interactive && y.props.trigger.indexOf("mouseenter") >= 0 && se().addEventListener("mousemove", h);
|
|
17331
17349
|
}), y;
|
|
17332
|
-
function
|
|
17350
|
+
function z() {
|
|
17333
17351
|
var v = y.props.touch;
|
|
17334
17352
|
return Array.isArray(v) ? v : [v, 0];
|
|
17335
17353
|
}
|
|
17336
17354
|
function _() {
|
|
17337
|
-
return
|
|
17355
|
+
return z()[0] === "hold";
|
|
17338
17356
|
}
|
|
17339
|
-
function
|
|
17357
|
+
function V() {
|
|
17340
17358
|
var v;
|
|
17341
17359
|
return !!((v = y.props.render) != null && v.$$tippy);
|
|
17342
17360
|
}
|
|
@@ -17345,7 +17363,7 @@ function mk(t, e) {
|
|
|
17345
17363
|
}
|
|
17346
17364
|
function se() {
|
|
17347
17365
|
var v = j().parentNode;
|
|
17348
|
-
return v ?
|
|
17366
|
+
return v ? ek(v) : document;
|
|
17349
17367
|
}
|
|
17350
17368
|
function ce() {
|
|
17351
17369
|
return hs(k);
|
|
@@ -17457,14 +17475,14 @@ function mk(t, e) {
|
|
|
17457
17475
|
passive: !0
|
|
17458
17476
|
}), At("touchend", Br, {
|
|
17459
17477
|
passive: !0
|
|
17460
|
-
})),
|
|
17478
|
+
})), Kv(y.props.trigger).forEach(function(v) {
|
|
17461
17479
|
if (v !== "manual")
|
|
17462
17480
|
switch (At(v, Hn), v) {
|
|
17463
17481
|
case "mouseenter":
|
|
17464
17482
|
At("mouseleave", Br);
|
|
17465
17483
|
break;
|
|
17466
17484
|
case "focus":
|
|
17467
|
-
At(
|
|
17485
|
+
At(sk ? "focusout" : "blur", jn);
|
|
17468
17486
|
break;
|
|
17469
17487
|
case "focusin":
|
|
17470
17488
|
At("focusout", jn);
|
|
@@ -17482,7 +17500,7 @@ function mk(t, e) {
|
|
|
17482
17500
|
var A, R = !1;
|
|
17483
17501
|
if (!(!y.state.isEnabled || Wn(v) || a)) {
|
|
17484
17502
|
var q = ((A = d) == null ? void 0 : A.type) === "focus";
|
|
17485
|
-
d = v, m = v.currentTarget, ke(), !y.state.isVisible &&
|
|
17503
|
+
d = v, m = v.currentTarget, ke(), !y.state.isVisible && Gv(v) && eo.forEach(function(U) {
|
|
17486
17504
|
return U(v);
|
|
17487
17505
|
}), v.type === "click" && (y.props.trigger.indexOf("mouseenter") < 0 || s) && y.props.hideOnClick !== !1 && y.state.isVisible ? R = !0 : Un(v), v.type === "click" && (s = !R), R && !q && Ut(v);
|
|
17488
17506
|
}
|
|
@@ -17498,7 +17516,7 @@ function mk(t, e) {
|
|
|
17498
17516
|
props: n
|
|
17499
17517
|
} : null;
|
|
17500
17518
|
}).filter(Boolean);
|
|
17501
|
-
|
|
17519
|
+
tk(q, v) && (lt(), Ut(v));
|
|
17502
17520
|
}
|
|
17503
17521
|
}
|
|
17504
17522
|
function Br(v) {
|
|
@@ -17519,7 +17537,7 @@ function mk(t, e) {
|
|
|
17519
17537
|
}
|
|
17520
17538
|
function _r() {
|
|
17521
17539
|
zr();
|
|
17522
|
-
var v = y.props, A = v.popperOptions, R = v.placement, q = v.offset, U = v.getReferenceClientRect, Ce = v.moveTransition, Be =
|
|
17540
|
+
var v = y.props, A = v.popperOptions, R = v.placement, q = v.offset, U = v.getReferenceClientRect, Ce = v.moveTransition, Be = V() ? hs(k).arrow : null, pn = U ? {
|
|
17523
17541
|
getBoundingClientRect: U,
|
|
17524
17542
|
contextElement: U.contextElement || j()
|
|
17525
17543
|
} : t, Ys = {
|
|
@@ -17529,7 +17547,7 @@ function mk(t, e) {
|
|
|
17529
17547
|
requires: ["computeStyles"],
|
|
17530
17548
|
fn: function(Wr) {
|
|
17531
17549
|
var hn = Wr.state;
|
|
17532
|
-
if (
|
|
17550
|
+
if (V()) {
|
|
17533
17551
|
var df = ce(), Vo = df.box;
|
|
17534
17552
|
["placement", "reference-hidden", "escaped"].forEach(function(Ur) {
|
|
17535
17553
|
Ur === "placement" ? Vo.setAttribute("data-placement", hn.placement) : hn.attributes.popper["data-popper-" + Ur] ? Vo.setAttribute("data-" + Ur, "") : Vo.removeAttribute("data-" + Ur);
|
|
@@ -17562,13 +17580,13 @@ function mk(t, e) {
|
|
|
17562
17580
|
adaptive: !Ce
|
|
17563
17581
|
}
|
|
17564
17582
|
}, Ys];
|
|
17565
|
-
|
|
17583
|
+
V() && Be && qt.push({
|
|
17566
17584
|
name: "arrow",
|
|
17567
17585
|
options: {
|
|
17568
17586
|
element: Be,
|
|
17569
17587
|
padding: 3
|
|
17570
17588
|
}
|
|
17571
|
-
}), qt.push.apply(qt, A?.modifiers || []), y.popperInstance =
|
|
17589
|
+
}), qt.push.apply(qt, A?.modifiers || []), y.popperInstance = Hv(pn, k, Object.assign({}, A, {
|
|
17572
17590
|
placement: R,
|
|
17573
17591
|
onFirstUpdate: f,
|
|
17574
17592
|
modifiers: qt
|
|
@@ -17592,7 +17610,7 @@ function mk(t, e) {
|
|
|
17592
17610
|
}
|
|
17593
17611
|
function Un(v) {
|
|
17594
17612
|
y.clearDelayTimeouts(), v && ne("onTrigger", [y, v]), Ne();
|
|
17595
|
-
var A = ae(!0), R =
|
|
17613
|
+
var A = ae(!0), R = z(), q = R[0], U = R[1];
|
|
17596
17614
|
tt.isTouch && q === "hold" && U && (A = U), A ? r = setTimeout(function() {
|
|
17597
17615
|
y.show();
|
|
17598
17616
|
}, A) : y.show();
|
|
@@ -17642,18 +17660,18 @@ function mk(t, e) {
|
|
|
17642
17660
|
ie.env.NODE_ENV !== "production" && gt(y.state.isDestroyed, wn("show"));
|
|
17643
17661
|
var v = y.state.isVisible, A = y.state.isDestroyed, R = !y.state.isEnabled, q = tt.isTouch && !y.props.touch, U = ui(y.props.duration, 0, Ie.duration);
|
|
17644
17662
|
if (!(v || A || R || q) && !j().hasAttribute("disabled") && (ne("onShow", [y], !1), y.props.onShow(y) !== !1)) {
|
|
17645
|
-
if (y.state.isVisible = !0,
|
|
17663
|
+
if (y.state.isVisible = !0, V() && (k.style.visibility = "visible"), ee(), Ne(), y.state.isMounted || (k.style.transition = "none"), V()) {
|
|
17646
17664
|
var Ce = ce(), Be = Ce.box, pn = Ce.content;
|
|
17647
17665
|
fi([Be, pn], 0);
|
|
17648
17666
|
}
|
|
17649
17667
|
f = function() {
|
|
17650
17668
|
var qt;
|
|
17651
17669
|
if (!(!y.state.isVisible || c)) {
|
|
17652
|
-
if (c = !0, k.offsetHeight, k.style.transition = y.props.moveTransition,
|
|
17670
|
+
if (c = !0, k.offsetHeight, k.style.transition = y.props.moveTransition, V() && y.props.animation) {
|
|
17653
17671
|
var $o = ce(), Wr = $o.box, hn = $o.content;
|
|
17654
17672
|
fi([Wr, hn], U), zl([Wr, hn], "visible");
|
|
17655
17673
|
}
|
|
17656
|
-
ve(), ke(), Bl(hi, y), (qt = y.popperInstance) == null || qt.forceUpdate(), ne("onMount", [y]), y.props.animation &&
|
|
17674
|
+
ve(), ke(), Bl(hi, y), (qt = y.popperInstance) == null || qt.forceUpdate(), ne("onMount", [y]), y.props.animation && V() && dt(U, function() {
|
|
17657
17675
|
y.state.isShown = !0, ne("onShown", [y]);
|
|
17658
17676
|
});
|
|
17659
17677
|
}
|
|
@@ -17664,11 +17682,11 @@ function mk(t, e) {
|
|
|
17664
17682
|
ie.env.NODE_ENV !== "production" && gt(y.state.isDestroyed, wn("hide"));
|
|
17665
17683
|
var v = !y.state.isVisible, A = y.state.isDestroyed, R = !y.state.isEnabled, q = ui(y.props.duration, 1, Ie.duration);
|
|
17666
17684
|
if (!(v || A || R) && (ne("onHide", [y], !1), y.props.onHide(y) !== !1)) {
|
|
17667
|
-
if (y.state.isVisible = !1, y.state.isShown = !1, c = !1, s = !1,
|
|
17685
|
+
if (y.state.isVisible = !1, y.state.isShown = !1, c = !1, s = !1, V() && (k.style.visibility = "hidden"), lt(), Ke(), ee(!0), V()) {
|
|
17668
17686
|
var U = ce(), Ce = U.box, Be = U.content;
|
|
17669
17687
|
y.props.animation && (fi([Ce, Be], q), zl([Ce, Be], "hidden"));
|
|
17670
17688
|
}
|
|
17671
|
-
ve(), ke(), y.props.animation ?
|
|
17689
|
+
ve(), ke(), y.props.animation ? V() && Mt(q, y.unmount) : y.unmount();
|
|
17672
17690
|
}
|
|
17673
17691
|
}
|
|
17674
17692
|
function af(v) {
|
|
@@ -17688,10 +17706,10 @@ function mk(t, e) {
|
|
|
17688
17706
|
function Rr(t, e) {
|
|
17689
17707
|
e === void 0 && (e = {});
|
|
17690
17708
|
var n = Ie.plugins.concat(e.plugins || []);
|
|
17691
|
-
ie.env.NODE_ENV !== "production" && (
|
|
17709
|
+
ie.env.NODE_ENV !== "production" && (ck(t), nf(e, n)), ok();
|
|
17692
17710
|
var r = Object.assign({}, e, {
|
|
17693
17711
|
plugins: n
|
|
17694
|
-
}), o =
|
|
17712
|
+
}), o = Qv(t);
|
|
17695
17713
|
if (ie.env.NODE_ENV !== "production") {
|
|
17696
17714
|
var i = xr(r.content), s = o.length > 1;
|
|
17697
17715
|
gt(i && s, ["tippy() was passed an Element as the `content` prop, but more than", "one tippy instance was created by this invocation. This means the", "content element will only be appended to the last tippy instance.", `
|
|
@@ -17702,13 +17720,13 @@ function Rr(t, e) {
|
|
|
17702
17720
|
`, "2) content: () => element.cloneNode(true)"].join(" "));
|
|
17703
17721
|
}
|
|
17704
17722
|
var a = o.reduce(function(l, c) {
|
|
17705
|
-
var d = c &&
|
|
17723
|
+
var d = c && gk(c, r);
|
|
17706
17724
|
return d && l.push(d), l;
|
|
17707
17725
|
}, []);
|
|
17708
17726
|
return xr(t) ? a[0] : a;
|
|
17709
17727
|
}
|
|
17710
17728
|
Rr.defaultProps = Ie;
|
|
17711
|
-
Rr.setDefaultProps =
|
|
17729
|
+
Rr.setDefaultProps = fk;
|
|
17712
17730
|
Rr.currentInput = tt;
|
|
17713
17731
|
Object.assign({}, zu, {
|
|
17714
17732
|
effect: function(e) {
|
|
@@ -17730,12 +17748,12 @@ Object.assign({}, zu, {
|
|
|
17730
17748
|
Rr.setDefaultProps({
|
|
17731
17749
|
render: rf
|
|
17732
17750
|
});
|
|
17733
|
-
const
|
|
17751
|
+
const yk = (t, e) => {
|
|
17734
17752
|
const n = t.__vccOpts || t;
|
|
17735
17753
|
for (const [r, o] of e)
|
|
17736
17754
|
n[r] = o;
|
|
17737
17755
|
return n;
|
|
17738
|
-
},
|
|
17756
|
+
}, bk = ["onClick", "onMouseenter"], wk = { key: 0 }, vk = { key: 0 }, kk = { key: 1 }, Ck = { key: 1 }, Sk = {
|
|
17739
17757
|
__name: "Mentions",
|
|
17740
17758
|
props: {
|
|
17741
17759
|
users: {
|
|
@@ -17787,16 +17805,16 @@ const gk = (t, e) => {
|
|
|
17787
17805
|
key: d.email,
|
|
17788
17806
|
class: Tf(["user-row", { selected: r.value === u }])
|
|
17789
17807
|
}, [
|
|
17790
|
-
d.name ? (Xt(), Kt("div",
|
|
17791
|
-
d.name ? (Xt(), Kt("span",
|
|
17792
|
-
d.name && d.email ? (Xt(), Kt("span",
|
|
17793
|
-
])) : (Xt(), Kt("div",
|
|
17808
|
+
d.name ? (Xt(), Kt("div", wk, [
|
|
17809
|
+
d.name ? (Xt(), Kt("span", vk, Xo(d.name), 1)) : ea("", !0),
|
|
17810
|
+
d.name && d.email ? (Xt(), Kt("span", kk, " (" + Xo(d.email) + ")", 1)) : ea("", !0)
|
|
17811
|
+
])) : (Xt(), Kt("div", Ck, [
|
|
17794
17812
|
Df("span", null, Xo(d.email), 1)
|
|
17795
17813
|
]))
|
|
17796
|
-
], 42,
|
|
17814
|
+
], 42, bk))), 128))
|
|
17797
17815
|
], 544));
|
|
17798
17816
|
}
|
|
17799
|
-
},
|
|
17817
|
+
}, xk = /* @__PURE__ */ yk(Sk, [["__scopeId", "data-v-0a2a8b4e"]]), ql = new G("popoverPlugin"), Mk = Q.create({
|
|
17800
17818
|
name: "popoverPlugin",
|
|
17801
17819
|
addPmPlugins() {
|
|
17802
17820
|
return [new Z({
|
|
@@ -17809,7 +17827,7 @@ const gk = (t, e) => {
|
|
|
17809
17827
|
}
|
|
17810
17828
|
},
|
|
17811
17829
|
view: (e) => {
|
|
17812
|
-
const n = new
|
|
17830
|
+
const n = new Ak(e, this.editor);
|
|
17813
17831
|
return {
|
|
17814
17832
|
update: (r, o) => {
|
|
17815
17833
|
ql.getState(r.state).shouldUpdate && n.update(r, o);
|
|
@@ -17822,7 +17840,7 @@ const gk = (t, e) => {
|
|
|
17822
17840
|
})];
|
|
17823
17841
|
}
|
|
17824
17842
|
});
|
|
17825
|
-
class
|
|
17843
|
+
class Ak {
|
|
17826
17844
|
constructor(e, n) {
|
|
17827
17845
|
P(this, "handleKeyDown", (e) => {
|
|
17828
17846
|
const n = e.key === "ArrowDown" || e.key === "ArrowUp";
|
|
@@ -17859,7 +17877,7 @@ class Mk {
|
|
|
17859
17877
|
if (this.isShowMentions) {
|
|
17860
17878
|
const { from: i } = this.state.selection, s = this.getMentionText(i);
|
|
17861
17879
|
o = {
|
|
17862
|
-
component:
|
|
17880
|
+
component: xk,
|
|
17863
17881
|
props: {
|
|
17864
17882
|
users: this.editor.users,
|
|
17865
17883
|
mention: s,
|
|
@@ -17901,7 +17919,7 @@ class Mk {
|
|
|
17901
17919
|
this.tippyInstance.destroy(), this.popover.remove();
|
|
17902
17920
|
}
|
|
17903
17921
|
}
|
|
17904
|
-
const
|
|
17922
|
+
const Ok = !1, Tk = Q.create({
|
|
17905
17923
|
name: "pagination",
|
|
17906
17924
|
addStorage() {
|
|
17907
17925
|
return {
|
|
@@ -17935,7 +17953,7 @@ const Ak = !1, Ok = Q.create({
|
|
|
17935
17953
|
return {
|
|
17936
17954
|
isReadyToInit: !1,
|
|
17937
17955
|
decorations: F.empty,
|
|
17938
|
-
isDebugging:
|
|
17956
|
+
isDebugging: Ok
|
|
17939
17957
|
};
|
|
17940
17958
|
},
|
|
17941
17959
|
apply(s, a, l, c) {
|
|
@@ -17970,7 +17988,7 @@ const Ak = !1, Ok = Q.create({
|
|
|
17970
17988
|
let a = F.empty;
|
|
17971
17989
|
return {
|
|
17972
17990
|
update: (l) => {
|
|
17973
|
-
!n || e || (e = !0, r = !0,
|
|
17991
|
+
!n || e || (e = !0, r = !0, Dk(t, l, a), e = !1, n = !1);
|
|
17974
17992
|
}
|
|
17975
17993
|
};
|
|
17976
17994
|
},
|
|
@@ -17983,12 +18001,13 @@ const Ak = !1, Ok = Q.create({
|
|
|
17983
18001
|
}
|
|
17984
18002
|
}), vn = (t, e, n) => {
|
|
17985
18003
|
const { alternateHeaders: r } = n.converter.pageStyles, o = n.converter[e];
|
|
17986
|
-
if (
|
|
18004
|
+
if (o?.titlePg && !o.first && t === 1) return null;
|
|
17987
18005
|
const i = o.even, s = o.odd, a = o.first, l = o.default;
|
|
18006
|
+
if (o?.titlePg && a && t === 1) return a;
|
|
17988
18007
|
let c = o.default;
|
|
17989
18008
|
return r && (t === 1 ? c = a : t % 2 === 0 ? c = i || l : c = s || l), c;
|
|
17990
|
-
},
|
|
17991
|
-
const r = t.storage.pagination.sectionData, o =
|
|
18009
|
+
}, Dk = (t, e, n) => {
|
|
18010
|
+
const r = t.storage.pagination.sectionData, o = Nk(e, t, r);
|
|
17992
18011
|
if (!n.eq(o)) {
|
|
17993
18012
|
const i = e.state.tr.setMeta(
|
|
17994
18013
|
rn,
|
|
@@ -17997,7 +18016,7 @@ const Ak = !1, Ok = Q.create({
|
|
|
17997
18016
|
e.dispatch(i);
|
|
17998
18017
|
}
|
|
17999
18018
|
t.emit("paginationUpdate");
|
|
18000
|
-
},
|
|
18019
|
+
}, Nk = (t, e, n) => {
|
|
18001
18020
|
if (!e.converter) return F.empty;
|
|
18002
18021
|
const r = e.converter.pageStyles?.pageSize, { width: o, height: i } = r;
|
|
18003
18022
|
if (!o || !i) return F.empty;
|
|
@@ -18016,26 +18035,26 @@ const Ak = !1, Ok = Q.create({
|
|
|
18016
18035
|
}
|
|
18017
18036
|
});
|
|
18018
18037
|
e.initDefaultStyles(c);
|
|
18019
|
-
const p =
|
|
18038
|
+
const p = Ek(l.doc, f, e, n);
|
|
18020
18039
|
return f.destroy(), document.body.removeChild(c), F.create(t.state.doc, p);
|
|
18021
18040
|
};
|
|
18022
|
-
function
|
|
18041
|
+
function Ek(t, e, n, r) {
|
|
18023
18042
|
const o = [], { pageSize: i, pageMargins: s } = n.converter.pageStyles, a = i.height * 96;
|
|
18024
18043
|
n.options.scale;
|
|
18025
18044
|
let l = 1, c = a, d = null, u = null;
|
|
18026
18045
|
const f = vn(l, "headerIds", n), p = mi(s, i, r, f), h = yi({ editor: n, header: p, isFirstHeader: !0 });
|
|
18027
|
-
o.push(
|
|
18046
|
+
o.push($.widget(0, h, { key: "stable-key" }));
|
|
18028
18047
|
const m = vn(l, "footerIds", n), g = gi(s, i, r, m);
|
|
18029
18048
|
c -= p.headerHeight + g.footerHeight;
|
|
18030
18049
|
let b = e?.coordsAtPos(t.content.size);
|
|
18031
18050
|
if (!b) return [];
|
|
18032
|
-
t.descendants((
|
|
18033
|
-
let
|
|
18051
|
+
t.descendants((z, _) => {
|
|
18052
|
+
let V = z, j = _;
|
|
18034
18053
|
if (b = e?.coordsAtPos(j), !b) return;
|
|
18035
18054
|
let se = b.bottom > c;
|
|
18036
|
-
const ce =
|
|
18037
|
-
if (
|
|
18038
|
-
const ee = io.getState(n.state)?.styles?.find((ne) => ne.id ===
|
|
18055
|
+
const ce = V.type.name === "hardBreak";
|
|
18056
|
+
if (V.type.name === "paragraph" && V.attrs.styleId) {
|
|
18057
|
+
const ee = io.getState(n.state)?.styles?.find((ne) => ne.id === V.attrs.styleId);
|
|
18039
18058
|
if (ee) {
|
|
18040
18059
|
const { definition: ne = {} } = ee, { pageBreakBefore: ve, pageBreakAfter: ke } = ne.attrs || {};
|
|
18041
18060
|
(ve || ke) && (se = !0);
|
|
@@ -18043,28 +18062,31 @@ function Nk(t, e, n, r) {
|
|
|
18043
18062
|
}
|
|
18044
18063
|
if (ce || se) {
|
|
18045
18064
|
const ae = e.state.doc.resolve(j), ee = Bo(ae, (Mt) => Mt.type.name === "tableRow");
|
|
18046
|
-
ee && (
|
|
18065
|
+
ee && (V = ee.node, j = ee.pos);
|
|
18047
18066
|
const {
|
|
18048
18067
|
top: ne,
|
|
18049
18068
|
bottom: ve,
|
|
18050
18069
|
pos: ke
|
|
18051
|
-
} =
|
|
18070
|
+
} = Ik(e, j, c);
|
|
18052
18071
|
l++;
|
|
18053
18072
|
const lt = vn(l, "headerIds", n), Fe = vn(l, "footerIds", n);
|
|
18054
18073
|
u = mi(s, i, r, lt), d = gi(s, i, r, Fe, l - 1);
|
|
18055
|
-
const ct = c - ve, { node: qe } = Kl(ct), Ne =
|
|
18074
|
+
const ct = c - ve, { node: qe } = Kl(ct), Ne = $.widget(ke, qe, { key: "stable-key" });
|
|
18056
18075
|
o.push(Ne);
|
|
18057
18076
|
const Ke = yi({ editor: n, header: u, footer: d });
|
|
18058
|
-
o.push(
|
|
18077
|
+
o.push($.widget(ke, Ke, { key: "stable-key" })), c = ve + (a - u.headerHeight - d.footerHeight);
|
|
18059
18078
|
}
|
|
18060
18079
|
});
|
|
18061
18080
|
let w = t.content.size;
|
|
18062
18081
|
const C = e.coordsAtPos(w), y = vn(l, "headerIds", n), S = vn(l, "footerIds", n);
|
|
18063
18082
|
u = mi(s, i, r, y), d = gi(s, i, r, S, l);
|
|
18064
|
-
const k = c - C.bottom, { node: M } = Kl(k), L =
|
|
18083
|
+
const k = c - C.bottom, { node: M } = Kl(k), L = $.widget(t.content.size, M, { key: "stable-key" });
|
|
18065
18084
|
o.push(L);
|
|
18066
18085
|
const x = yi({ editor: n, footer: d, isLastFooter: !0 });
|
|
18067
|
-
return o.push(
|
|
18086
|
+
return o.push($.widget(t.content.size, x, { key: "stable-key" })), o.forEach((z) => {
|
|
18087
|
+
const V = z.type.toDOM?.querySelector('span[data-id="auto-total-pages"]');
|
|
18088
|
+
V && (V.innerText = l);
|
|
18089
|
+
}), o;
|
|
18068
18090
|
}
|
|
18069
18091
|
function Kl(t) {
|
|
18070
18092
|
const e = document.createElement("div");
|
|
@@ -18101,7 +18123,7 @@ function yi({ editor: t, header: e, footer: n, footerBottom: r = null, isFirstHe
|
|
|
18101
18123
|
}
|
|
18102
18124
|
return e && (d.appendChild(e.section), l += e.headerHeight), c.style.height = l + "px", c.style.minHeight = l + "px", c.style.maxHeight = l + "px", d.style.height = l + "px", c.style.width = "100px", c.style.marginLeft = a.left * -96 + "px", r !== null && (c.style.position = "absolute", c.style.bottom = r + "px"), c;
|
|
18103
18125
|
}
|
|
18104
|
-
function
|
|
18126
|
+
function Ik(t, e, n) {
|
|
18105
18127
|
let r = e - 1;
|
|
18106
18128
|
const o = { top: 0, bottom: 0, pos: 0 };
|
|
18107
18129
|
for (; r > 0; ) {
|
|
@@ -18119,7 +18141,7 @@ const Xl = (t) => {
|
|
|
18119
18141
|
const e = t.view.state.tr;
|
|
18120
18142
|
e.setMeta("forceUpdatePagination", !0), t.view.dispatch(e);
|
|
18121
18143
|
});
|
|
18122
|
-
},
|
|
18144
|
+
}, Pk = () => [
|
|
18123
18145
|
Tu,
|
|
18124
18146
|
Yd,
|
|
18125
18147
|
$d,
|
|
@@ -18142,8 +18164,8 @@ const Xl = (t) => {
|
|
|
18142
18164
|
Wd,
|
|
18143
18165
|
Ou,
|
|
18144
18166
|
Nu,
|
|
18145
|
-
|
|
18146
|
-
|
|
18167
|
+
Bw,
|
|
18168
|
+
Mk,
|
|
18147
18169
|
Au,
|
|
18148
18170
|
Eu,
|
|
18149
18171
|
qd,
|
|
@@ -18157,7 +18179,7 @@ const Xl = (t) => {
|
|
|
18157
18179
|
Lu,
|
|
18158
18180
|
Fu,
|
|
18159
18181
|
Mu
|
|
18160
|
-
],
|
|
18182
|
+
], Rk = () => [
|
|
18161
18183
|
Tu,
|
|
18162
18184
|
Yd,
|
|
18163
18185
|
$d,
|
|
@@ -18199,39 +18221,40 @@ const Xl = (t) => {
|
|
|
18199
18221
|
Au,
|
|
18200
18222
|
wb,
|
|
18201
18223
|
xb,
|
|
18202
|
-
|
|
18224
|
+
Fw,
|
|
18203
18225
|
Ru,
|
|
18204
18226
|
Lu,
|
|
18205
18227
|
Fu,
|
|
18206
18228
|
t0,
|
|
18207
|
-
|
|
18229
|
+
Tk,
|
|
18208
18230
|
Eu,
|
|
18209
18231
|
Ub,
|
|
18210
|
-
Nw
|
|
18232
|
+
Nw,
|
|
18233
|
+
Ew
|
|
18211
18234
|
];
|
|
18212
18235
|
export {
|
|
18213
|
-
|
|
18236
|
+
D as A,
|
|
18214
18237
|
he as C,
|
|
18215
18238
|
ji as E,
|
|
18216
18239
|
Ao as I,
|
|
18217
|
-
|
|
18218
|
-
|
|
18240
|
+
J as N,
|
|
18241
|
+
Bw as P,
|
|
18219
18242
|
de as T,
|
|
18220
|
-
|
|
18221
|
-
|
|
18243
|
+
yk as _,
|
|
18244
|
+
jk as a,
|
|
18222
18245
|
Kb as b,
|
|
18223
18246
|
He as c,
|
|
18224
18247
|
Ef as d,
|
|
18225
|
-
|
|
18226
|
-
|
|
18248
|
+
Rk as e,
|
|
18249
|
+
qk as f,
|
|
18227
18250
|
Go as g,
|
|
18228
|
-
|
|
18251
|
+
Pk as h,
|
|
18229
18252
|
Cd as i,
|
|
18230
18253
|
Q as j,
|
|
18231
18254
|
Sd as k,
|
|
18232
|
-
|
|
18233
|
-
|
|
18255
|
+
Uk as l,
|
|
18256
|
+
Kk as m,
|
|
18234
18257
|
No as n,
|
|
18235
|
-
|
|
18236
|
-
|
|
18258
|
+
Vk as r,
|
|
18259
|
+
$k as u
|
|
18237
18260
|
};
|