@fileverse-dev/ddoc 3.0.30 → 3.0.31-patch-1
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.
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
var rCe = Object.defineProperty;
|
|
2
2
|
var oCe = (e, t, n) => t in e ? rCe(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
|
|
3
|
-
var
|
|
3
|
+
var ct = (e, t, n) => oCe(e, typeof t != "symbol" ? t + "" : t, n);
|
|
4
4
|
import * as W from "react";
|
|
5
|
-
import _e, { createRef as nu, memo as D1, createContext as Gn, createElement as rt, useContext as Et, version as NV, useRef as Qe, useState as Re, useDebugValue as XI, useEffect as He, forwardRef as Pn, useLayoutEffect as es, useCallback as
|
|
5
|
+
import _e, { createRef as nu, memo as D1, createContext as Gn, createElement as rt, useContext as Et, version as NV, useRef as Qe, useState as Re, useDebugValue as XI, useEffect as He, forwardRef as Pn, useLayoutEffect as es, useCallback as We, useMemo as jt, useId as Wg, Children as Rie, isValidElement as Pie, useInsertionEffect as Ow, Fragment as m0, Suspense as iCe, Component as JI, useReducer as aCe, cloneElement as zie, useImperativeHandle as Uie } from "react";
|
|
6
6
|
import * as l6 from "react-dom";
|
|
7
7
|
import QI, { flushSync as sCe, createPortal as Rw } from "react-dom";
|
|
8
8
|
var en = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
|
|
@@ -303,7 +303,7 @@ function uCe() {
|
|
|
303
303
|
} finally {
|
|
304
304
|
ue = !1, K.current = Dt, te(), Error.prepareStackTrace = bt;
|
|
305
305
|
}
|
|
306
|
-
var
|
|
306
|
+
var pt = Q ? Q.displayName || Q.name : "", Yt = pt ? ae(pt) : "";
|
|
307
307
|
return typeof Q == "function" && P.set(Q, Yt), Yt;
|
|
308
308
|
}
|
|
309
309
|
function fe(Q, Ee, Pe) {
|
|
@@ -487,23 +487,23 @@ function uCe() {
|
|
|
487
487
|
return Ae(Q, gt, bn, bt, Ye, Z.current, yt);
|
|
488
488
|
}
|
|
489
489
|
}
|
|
490
|
-
var
|
|
490
|
+
var Ve = y.ReactCurrentOwner, $e = y.ReactDebugCurrentFrame;
|
|
491
491
|
function Ke(Q) {
|
|
492
492
|
if (Q) {
|
|
493
493
|
var Ee = Q._owner, Pe = le(Q.type, Q._source, Ee ? Ee.type : null);
|
|
494
|
-
|
|
494
|
+
$e.setExtraStackFrame(Pe);
|
|
495
495
|
} else
|
|
496
|
-
|
|
496
|
+
$e.setExtraStackFrame(null);
|
|
497
497
|
}
|
|
498
|
-
var
|
|
499
|
-
|
|
498
|
+
var ut;
|
|
499
|
+
ut = !1;
|
|
500
500
|
function Oe(Q) {
|
|
501
501
|
return typeof Q == "object" && Q !== null && Q.$$typeof === t;
|
|
502
502
|
}
|
|
503
503
|
function ze() {
|
|
504
504
|
{
|
|
505
|
-
if (
|
|
506
|
-
var Q = L(
|
|
505
|
+
if (Ve.current) {
|
|
506
|
+
var Q = L(Ve.current.type);
|
|
507
507
|
if (Q)
|
|
508
508
|
return `
|
|
509
509
|
|
|
@@ -528,7 +528,7 @@ Check the top-level render call using <` + Pe + ">.");
|
|
|
528
528
|
return Ee;
|
|
529
529
|
}
|
|
530
530
|
}
|
|
531
|
-
function
|
|
531
|
+
function ht(Q, Ee) {
|
|
532
532
|
{
|
|
533
533
|
if (!Q._store || Q._store.validated || Q.key != null)
|
|
534
534
|
return;
|
|
@@ -538,7 +538,7 @@ Check the top-level render call using <` + Pe + ">.");
|
|
|
538
538
|
return;
|
|
539
539
|
at[Pe] = !0;
|
|
540
540
|
var Ye = "";
|
|
541
|
-
Q && Q._owner && Q._owner !==
|
|
541
|
+
Q && Q._owner && Q._owner !== Ve.current && (Ye = " It was passed a child from " + L(Q._owner.type) + "."), Ke(Q), b('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', Pe, Ye), Ke(null);
|
|
542
542
|
}
|
|
543
543
|
}
|
|
544
544
|
function Mt(Q, Ee) {
|
|
@@ -548,7 +548,7 @@ Check the top-level render call using <` + Pe + ">.");
|
|
|
548
548
|
if (ge(Q))
|
|
549
549
|
for (var Pe = 0; Pe < Q.length; Pe++) {
|
|
550
550
|
var Ye = Q[Pe];
|
|
551
|
-
Oe(Ye) &&
|
|
551
|
+
Oe(Ye) && ht(Ye, Ee);
|
|
552
552
|
}
|
|
553
553
|
else if (Oe(Q))
|
|
554
554
|
Q._store && (Q._store.validated = !0);
|
|
@@ -556,7 +556,7 @@ Check the top-level render call using <` + Pe + ">.");
|
|
|
556
556
|
var bt = m(Q);
|
|
557
557
|
if (typeof bt == "function" && bt !== Q.entries)
|
|
558
558
|
for (var Dt = bt.call(Q), yt; !(yt = Dt.next()).done; )
|
|
559
|
-
Oe(yt.value) &&
|
|
559
|
+
Oe(yt.value) && ht(yt.value, Ee);
|
|
560
560
|
}
|
|
561
561
|
}
|
|
562
562
|
}
|
|
@@ -577,8 +577,8 @@ Check the top-level render call using <` + Pe + ">.");
|
|
|
577
577
|
if (Pe) {
|
|
578
578
|
var Ye = L(Ee);
|
|
579
579
|
Fe(Pe, Q.props, "prop", Ye, Q);
|
|
580
|
-
} else if (Ee.PropTypes !== void 0 && !
|
|
581
|
-
|
|
580
|
+
} else if (Ee.PropTypes !== void 0 && !ut) {
|
|
581
|
+
ut = !0;
|
|
582
582
|
var bt = L(Ee);
|
|
583
583
|
b("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", bt || "Unknown");
|
|
584
584
|
}
|
|
@@ -617,8 +617,8 @@ Check the top-level render call using <` + Pe + ">.");
|
|
|
617
617
|
if (Ne !== void 0)
|
|
618
618
|
if (Ye)
|
|
619
619
|
if (ge(Ne)) {
|
|
620
|
-
for (var
|
|
621
|
-
Mt(Ne[
|
|
620
|
+
for (var pt = 0; pt < Ne.length; pt++)
|
|
621
|
+
Mt(Ne[pt], Q);
|
|
622
622
|
Object.freeze && Object.freeze(Ne);
|
|
623
623
|
} else
|
|
624
624
|
b("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");
|
|
@@ -1307,7 +1307,7 @@ let Wn = class hj {
|
|
|
1307
1307
|
Wn.none = [];
|
|
1308
1308
|
class U8 extends Error {
|
|
1309
1309
|
}
|
|
1310
|
-
class
|
|
1310
|
+
class ft {
|
|
1311
1311
|
/**
|
|
1312
1312
|
Create a slice. When specifying a non-zero open depth, you must
|
|
1313
1313
|
make sure that there are nodes of at least that depth at the
|
|
@@ -1334,13 +1334,13 @@ class dt {
|
|
|
1334
1334
|
*/
|
|
1335
1335
|
insertAt(t, n) {
|
|
1336
1336
|
let r = $ie(this.content, t + this.openStart, n);
|
|
1337
|
-
return r && new
|
|
1337
|
+
return r && new ft(r, this.openStart, this.openEnd);
|
|
1338
1338
|
}
|
|
1339
1339
|
/**
|
|
1340
1340
|
@internal
|
|
1341
1341
|
*/
|
|
1342
1342
|
removeBetween(t, n) {
|
|
1343
|
-
return new
|
|
1343
|
+
return new ft(Wie(this.content, t + this.openStart, n + this.openStart), this.openStart, this.openEnd);
|
|
1344
1344
|
}
|
|
1345
1345
|
/**
|
|
1346
1346
|
Tests whether this slice is equal to another slice.
|
|
@@ -1368,11 +1368,11 @@ class dt {
|
|
|
1368
1368
|
*/
|
|
1369
1369
|
static fromJSON(t, n) {
|
|
1370
1370
|
if (!n)
|
|
1371
|
-
return
|
|
1371
|
+
return ft.empty;
|
|
1372
1372
|
let r = n.openStart || 0, o = n.openEnd || 0;
|
|
1373
1373
|
if (typeof r != "number" || typeof o != "number")
|
|
1374
1374
|
throw new RangeError("Invalid input for Slice.fromJSON");
|
|
1375
|
-
return new
|
|
1375
|
+
return new ft(Ze.fromJSON(t, n.content), r, o);
|
|
1376
1376
|
}
|
|
1377
1377
|
/**
|
|
1378
1378
|
Create a slice from a fragment by taking the maximum possible
|
|
@@ -1384,10 +1384,10 @@ class dt {
|
|
|
1384
1384
|
r++;
|
|
1385
1385
|
for (let i = t.lastChild; i && !i.isLeaf && (n || !i.type.spec.isolating); i = i.lastChild)
|
|
1386
1386
|
o++;
|
|
1387
|
-
return new
|
|
1387
|
+
return new ft(t, r, o);
|
|
1388
1388
|
}
|
|
1389
1389
|
}
|
|
1390
|
-
|
|
1390
|
+
ft.empty = new ft(Ze.empty, 0, 0);
|
|
1391
1391
|
function Wie(e, t, n) {
|
|
1392
1392
|
let { index: r, offset: o } = e.findIndex(t), i = e.maybeChild(r), { index: a, offset: s } = e.findIndex(n);
|
|
1393
1393
|
if (o == t || i.isText) {
|
|
@@ -1913,9 +1913,9 @@ let Sd = class gj {
|
|
|
1913
1913
|
*/
|
|
1914
1914
|
slice(t, n = this.content.size, r = !1) {
|
|
1915
1915
|
if (t == n)
|
|
1916
|
-
return
|
|
1916
|
+
return ft.empty;
|
|
1917
1917
|
let o = this.resolve(t), i = this.resolve(n), a = r ? 0 : o.sharedDepth(n), s = o.start(a), u = o.node(a).content.cut(o.pos - s, i.pos - s);
|
|
1918
|
-
return new
|
|
1918
|
+
return new ft(u, o.depth - a, i.depth - a);
|
|
1919
1919
|
}
|
|
1920
1920
|
/**
|
|
1921
1921
|
Replace the part of the document between the given positions with
|
|
@@ -2942,7 +2942,7 @@ let _f = class yj {
|
|
|
2942
2942
|
*/
|
|
2943
2943
|
parseSlice(t, n = {}) {
|
|
2944
2944
|
let r = new VV(this, n, !0);
|
|
2945
|
-
return r.addAll(t, Wn.none, n.from, n.to),
|
|
2945
|
+
return r.addAll(t, Wn.none, n.from, n.to), ft.maxOpen(r.finish());
|
|
2946
2946
|
}
|
|
2947
2947
|
/**
|
|
2948
2948
|
@internal
|
|
@@ -3929,7 +3929,7 @@ class xd extends hi {
|
|
|
3929
3929
|
super(), this.from = t, this.to = n, this.mark = r;
|
|
3930
3930
|
}
|
|
3931
3931
|
apply(t) {
|
|
3932
|
-
let n = t.slice(this.from, this.to), r = t.resolve(this.from), o = r.node(r.sharedDepth(this.to)), i = new
|
|
3932
|
+
let n = t.slice(this.from, this.to), r = t.resolve(this.from), o = r.node(r.sharedDepth(this.to)), i = new ft(tB(n.content, (a, s) => !a.isAtom || !s.type.allowsMarkType(this.mark.type) ? a : a.mark(this.mark.addToSet(a.marks)), o), n.openStart, n.openEnd);
|
|
3933
3933
|
return ro.fromReplace(t, this.from, this.to, i);
|
|
3934
3934
|
}
|
|
3935
3935
|
invert() {
|
|
@@ -3968,7 +3968,7 @@ class cl extends hi {
|
|
|
3968
3968
|
super(), this.from = t, this.to = n, this.mark = r;
|
|
3969
3969
|
}
|
|
3970
3970
|
apply(t) {
|
|
3971
|
-
let n = t.slice(this.from, this.to), r = new
|
|
3971
|
+
let n = t.slice(this.from, this.to), r = new ft(tB(n.content, (o) => o.mark(this.mark.removeFromSet(o.marks)), t), n.openStart, n.openEnd);
|
|
3972
3972
|
return ro.fromReplace(t, this.from, this.to, r);
|
|
3973
3973
|
}
|
|
3974
3974
|
invert() {
|
|
@@ -4011,7 +4011,7 @@ class wd extends hi {
|
|
|
4011
4011
|
if (!n)
|
|
4012
4012
|
return ro.fail("No node at mark step's position");
|
|
4013
4013
|
let r = n.type.create(n.attrs, null, this.mark.addToSet(n.marks));
|
|
4014
|
-
return ro.fromReplace(t, this.pos, this.pos + 1, new
|
|
4014
|
+
return ro.fromReplace(t, this.pos, this.pos + 1, new ft(Ze.from(r), 0, n.isLeaf ? 0 : 1));
|
|
4015
4015
|
}
|
|
4016
4016
|
invert(t) {
|
|
4017
4017
|
let n = t.nodeAt(this.pos);
|
|
@@ -4055,7 +4055,7 @@ class Jf extends hi {
|
|
|
4055
4055
|
if (!n)
|
|
4056
4056
|
return ro.fail("No node at mark step's position");
|
|
4057
4057
|
let r = n.type.create(n.attrs, null, this.mark.removeFromSet(n.marks));
|
|
4058
|
-
return ro.fromReplace(t, this.pos, this.pos + 1, new
|
|
4058
|
+
return ro.fromReplace(t, this.pos, this.pos + 1, new ft(Ze.from(r), 0, n.isLeaf ? 0 : 1));
|
|
4059
4059
|
}
|
|
4060
4060
|
invert(t) {
|
|
4061
4061
|
let n = t.nodeAt(this.pos);
|
|
@@ -4108,10 +4108,10 @@ class ko extends hi {
|
|
|
4108
4108
|
if (!(t instanceof ko) || t.structure || this.structure)
|
|
4109
4109
|
return null;
|
|
4110
4110
|
if (this.from + this.slice.size == t.from && !this.slice.openEnd && !t.slice.openStart) {
|
|
4111
|
-
let n = this.slice.size + t.slice.size == 0 ?
|
|
4111
|
+
let n = this.slice.size + t.slice.size == 0 ? ft.empty : new ft(this.slice.content.append(t.slice.content), this.slice.openStart, t.slice.openEnd);
|
|
4112
4112
|
return new ko(this.from, this.to + (t.to - t.from), n, this.structure);
|
|
4113
4113
|
} else if (t.to == this.from && !this.slice.openStart && !t.slice.openEnd) {
|
|
4114
|
-
let n = this.slice.size + t.slice.size == 0 ?
|
|
4114
|
+
let n = this.slice.size + t.slice.size == 0 ? ft.empty : new ft(t.slice.content.append(this.slice.content), t.slice.openStart, this.slice.openEnd);
|
|
4115
4115
|
return new ko(t.from, this.to, n, this.structure);
|
|
4116
4116
|
} else
|
|
4117
4117
|
return null;
|
|
@@ -4126,7 +4126,7 @@ class ko extends hi {
|
|
|
4126
4126
|
static fromJSON(t, n) {
|
|
4127
4127
|
if (typeof n.from != "number" || typeof n.to != "number")
|
|
4128
4128
|
throw new RangeError("Invalid input for ReplaceStep.fromJSON");
|
|
4129
|
-
return new ko(n.from, n.to,
|
|
4129
|
+
return new ko(n.from, n.to, ft.fromJSON(t, n.slice), !!n.structure);
|
|
4130
4130
|
}
|
|
4131
4131
|
}
|
|
4132
4132
|
hi.jsonID("replace", ko);
|
|
@@ -4184,7 +4184,7 @@ class Co extends hi {
|
|
|
4184
4184
|
static fromJSON(t, n) {
|
|
4185
4185
|
if (typeof n.from != "number" || typeof n.to != "number" || typeof n.gapFrom != "number" || typeof n.gapTo != "number" || typeof n.insert != "number")
|
|
4186
4186
|
throw new RangeError("Invalid input for ReplaceAroundStep.fromJSON");
|
|
4187
|
-
return new Co(n.from, n.to, n.gapFrom, n.gapTo,
|
|
4187
|
+
return new Co(n.from, n.to, n.gapFrom, n.gapTo, ft.fromJSON(t, n.slice), n.insert, !!n.structure);
|
|
4188
4188
|
}
|
|
4189
4189
|
}
|
|
4190
4190
|
hi.jsonID("replaceAround", Co);
|
|
@@ -4246,7 +4246,7 @@ function nB(e, t, n, r = n.contentMatch, o = !0) {
|
|
|
4246
4246
|
for (let l = 0; l < i.childCount; l++) {
|
|
4247
4247
|
let u = i.child(l), c = s + u.nodeSize, d = r.matchType(u.type);
|
|
4248
4248
|
if (!d)
|
|
4249
|
-
a.push(new ko(s, c,
|
|
4249
|
+
a.push(new ko(s, c, ft.empty));
|
|
4250
4250
|
else {
|
|
4251
4251
|
r = d;
|
|
4252
4252
|
for (let f = 0; f < u.marks.length; f++)
|
|
@@ -4254,14 +4254,14 @@ function nB(e, t, n, r = n.contentMatch, o = !0) {
|
|
|
4254
4254
|
if (o && u.isText && n.whitespace != "pre") {
|
|
4255
4255
|
let f, h = /\r?\n|\r/g, p;
|
|
4256
4256
|
for (; f = h.exec(u.text); )
|
|
4257
|
-
p || (p = new
|
|
4257
|
+
p || (p = new ft(Ze.from(n.schema.text(" ", n.allowedMarks(u.marks))), 0, 0)), a.push(new ko(s + f.index, s + f.index + f[0].length, p));
|
|
4258
4258
|
}
|
|
4259
4259
|
}
|
|
4260
4260
|
s = c;
|
|
4261
4261
|
}
|
|
4262
4262
|
if (!r.validEnd) {
|
|
4263
4263
|
let l = r.fillBefore(Ze.empty, !0);
|
|
4264
|
-
e.replace(s, s, new
|
|
4264
|
+
e.replace(s, s, new ft(l, 0, 0));
|
|
4265
4265
|
}
|
|
4266
4266
|
for (let l = a.length - 1; l >= 0; l--)
|
|
4267
4267
|
e.step(a[l]);
|
|
@@ -4288,7 +4288,7 @@ function UCe(e, t, n) {
|
|
|
4288
4288
|
let f = Ze.empty, h = 0;
|
|
4289
4289
|
for (let p = i, g = !1; p > n; p--)
|
|
4290
4290
|
g || o.after(p + 1) < o.end(p) ? (g = !0, f = Ze.from(o.node(p).copy(f)), h++) : u++;
|
|
4291
|
-
e.step(new Co(l, u, a, s, new
|
|
4291
|
+
e.step(new Co(l, u, a, s, new ft(c.append(f), d, h), c.size - d, !0));
|
|
4292
4292
|
}
|
|
4293
4293
|
function rB(e, t, n = null, r = e) {
|
|
4294
4294
|
let o = HCe(e, t), i = o && qCe(r, t);
|
|
@@ -4324,7 +4324,7 @@ function VCe(e, t, n) {
|
|
|
4324
4324
|
r = Ze.from(n[a].type.create(n[a].attrs, r));
|
|
4325
4325
|
}
|
|
4326
4326
|
let o = t.start, i = t.end;
|
|
4327
|
-
e.step(new Co(o, i, o, i, new
|
|
4327
|
+
e.step(new Co(o, i, o, i, new ft(r, 0, 0), n.length, !0));
|
|
4328
4328
|
}
|
|
4329
4329
|
function WCe(e, t, n, r, o) {
|
|
4330
4330
|
if (!r.isTextblock)
|
|
@@ -4340,7 +4340,7 @@ function WCe(e, t, n, r, o) {
|
|
|
4340
4340
|
}
|
|
4341
4341
|
u === !1 && fae(e, a, s, i), nB(e, e.mapping.slice(i).map(s, 1), r, void 0, u === null);
|
|
4342
4342
|
let c = e.mapping.slice(i), d = c.map(s, 1), f = c.map(s + a.nodeSize, 1);
|
|
4343
|
-
return e.step(new Co(d, f, d + 1, f - 1, new
|
|
4343
|
+
return e.step(new Co(d, f, d + 1, f - 1, new ft(Ze.from(r.create(l, null, a.marks)), 0, 0), 1, !0)), u === !0 && dae(e, a, s, i), !1;
|
|
4344
4344
|
}
|
|
4345
4345
|
});
|
|
4346
4346
|
}
|
|
@@ -4378,7 +4378,7 @@ function GCe(e, t, n, r, o) {
|
|
|
4378
4378
|
return e.replaceWith(t, t + i.nodeSize, a);
|
|
4379
4379
|
if (!n.validContent(i.content))
|
|
4380
4380
|
throw new RangeError("Invalid content for node type " + n.name);
|
|
4381
|
-
e.step(new Co(t, t + i.nodeSize, t + 1, t + i.nodeSize - 1, new
|
|
4381
|
+
e.step(new Co(t, t + i.nodeSize, t + 1, t + i.nodeSize - 1, new ft(Ze.from(a), 0, 0), 1, !0));
|
|
4382
4382
|
}
|
|
4383
4383
|
function Vc(e, t, n = 1, r) {
|
|
4384
4384
|
let o = e.resolve(t), i = o.depth - n, a = r && r[r.length - 1] || o.parent;
|
|
@@ -4404,7 +4404,7 @@ function ZCe(e, t, n = 1, r) {
|
|
|
4404
4404
|
let c = r && r[u];
|
|
4405
4405
|
a = Ze.from(c ? c.type.create(c.attrs, a) : o.node(s).copy(a));
|
|
4406
4406
|
}
|
|
4407
|
-
e.step(new ko(t, t, new
|
|
4407
|
+
e.step(new ko(t, t, new ft(i.append(a), n, n), !0));
|
|
4408
4408
|
}
|
|
4409
4409
|
function b0(e, t) {
|
|
4410
4410
|
let n = e.resolve(t), r = n.index();
|
|
@@ -4447,7 +4447,7 @@ function YCe(e, t, n) {
|
|
|
4447
4447
|
}
|
|
4448
4448
|
a.inlineContent && nB(e, t + n - 1, a, i.node().contentMatchAt(i.index()), r == null);
|
|
4449
4449
|
let l = e.mapping.slice(s), u = l.map(t - n);
|
|
4450
|
-
if (e.step(new ko(u, l.map(t + n, -1),
|
|
4450
|
+
if (e.step(new ko(u, l.map(t + n, -1), ft.empty, !0)), r === !0) {
|
|
4451
4451
|
let c = e.doc.resolve(u);
|
|
4452
4452
|
dae(e, c.node(), c.before(), e.steps.length);
|
|
4453
4453
|
}
|
|
@@ -4496,7 +4496,7 @@ function pae(e, t, n) {
|
|
|
4496
4496
|
}
|
|
4497
4497
|
return null;
|
|
4498
4498
|
}
|
|
4499
|
-
function Uw(e, t, n = t, r =
|
|
4499
|
+
function Uw(e, t, n = t, r = ft.empty) {
|
|
4500
4500
|
if (t == n && !r.size)
|
|
4501
4501
|
return null;
|
|
4502
4502
|
let o = e.resolve(t), i = e.resolve(n);
|
|
@@ -4532,7 +4532,7 @@ class JCe {
|
|
|
4532
4532
|
let i = this.placed, a = r.depth, s = o.depth;
|
|
4533
4533
|
for (; a && s && i.childCount == 1; )
|
|
4534
4534
|
i = i.firstChild.content, a--, s--;
|
|
4535
|
-
let l = new
|
|
4535
|
+
let l = new ft(i, a, s);
|
|
4536
4536
|
return t > -1 ? new Co(r.pos, t, this.$to.pos, this.$to.end(), l, n) : l.size || r.pos != this.$to.pos ? new ko(r.pos, o.pos, l) : null;
|
|
4537
4537
|
}
|
|
4538
4538
|
// Find a position on the start spine of `this.unplaced` that has
|
|
@@ -4566,15 +4566,15 @@ class JCe {
|
|
|
4566
4566
|
}
|
|
4567
4567
|
openMore() {
|
|
4568
4568
|
let { content: t, openStart: n, openEnd: r } = this.unplaced, o = VD(t, n);
|
|
4569
|
-
return !o.childCount || o.firstChild.isLeaf ? !1 : (this.unplaced = new
|
|
4569
|
+
return !o.childCount || o.firstChild.isLeaf ? !1 : (this.unplaced = new ft(t, n + 1, Math.max(r, o.size + n >= t.size - r ? n + 1 : 0)), !0);
|
|
4570
4570
|
}
|
|
4571
4571
|
dropNode() {
|
|
4572
4572
|
let { content: t, openStart: n, openEnd: r } = this.unplaced, o = VD(t, n);
|
|
4573
4573
|
if (o.childCount <= 1 && n > 0) {
|
|
4574
4574
|
let i = t.size - n <= n + o.size;
|
|
4575
|
-
this.unplaced = new
|
|
4575
|
+
this.unplaced = new ft(R3(t, n - 1, 1), n - 1, i ? n - 1 : r);
|
|
4576
4576
|
} else
|
|
4577
|
-
this.unplaced = new
|
|
4577
|
+
this.unplaced = new ft(R3(t, n, 1), n, r);
|
|
4578
4578
|
}
|
|
4579
4579
|
// Move content from the unplaced slice at `sliceDepth` to the
|
|
4580
4580
|
// frontier node at `frontierDepth`. Close that frontier node when
|
|
@@ -4604,7 +4604,7 @@ class JCe {
|
|
|
4604
4604
|
let y = m.lastChild;
|
|
4605
4605
|
this.frontier.push({ type: y.type, match: y.contentMatchAt(y.childCount) }), m = y.content;
|
|
4606
4606
|
}
|
|
4607
|
-
this.unplaced = p ? t == 0 ?
|
|
4607
|
+
this.unplaced = p ? t == 0 ? ft.empty : new ft(R3(a.content, t - 1, 1), t - 1, h < 0 ? a.openEnd : t - 1) : new ft(R3(a.content, t, u), a.openStart, a.openEnd);
|
|
4608
4608
|
}
|
|
4609
4609
|
mustMoveInline() {
|
|
4610
4610
|
if (!this.$to.parent.isTextblock)
|
|
@@ -4723,7 +4723,7 @@ function tDe(e, t, n, r) {
|
|
|
4723
4723
|
m < 0 && (y = !1, m = -m);
|
|
4724
4724
|
let b = o.node(m - 1), v = o.index(m - 1);
|
|
4725
4725
|
if (b.canReplaceWith(v, v, p.type, p.marks))
|
|
4726
|
-
return e.replace(o.before(m), y ? i.after(m) : n, new
|
|
4726
|
+
return e.replace(o.before(m), y ? i.after(m) : n, new ft(yae(r.content, 0, r.openStart, h), h, r.openEnd));
|
|
4727
4727
|
}
|
|
4728
4728
|
}
|
|
4729
4729
|
let d = e.steps.length;
|
|
@@ -4748,7 +4748,7 @@ function nDe(e, t, n, r) {
|
|
|
4748
4748
|
let o = XCe(e.doc, t, r.type);
|
|
4749
4749
|
o != null && (t = n = o);
|
|
4750
4750
|
}
|
|
4751
|
-
e.replaceRange(t, n, new
|
|
4751
|
+
e.replaceRange(t, n, new ft(Ze.from(r), 0, 0));
|
|
4752
4752
|
}
|
|
4753
4753
|
function rDe(e, t, n) {
|
|
4754
4754
|
let r = e.doc.resolve(t), o = e.doc.resolve(n), i = bae(r, o);
|
|
@@ -4790,7 +4790,7 @@ class y2 extends hi {
|
|
|
4790
4790
|
r[i] = n.attrs[i];
|
|
4791
4791
|
r[this.attr] = this.value;
|
|
4792
4792
|
let o = n.type.create(r, null, n.marks);
|
|
4793
|
-
return ro.fromReplace(t, this.pos, this.pos + 1, new
|
|
4793
|
+
return ro.fromReplace(t, this.pos, this.pos + 1, new ft(Ze.from(o), 0, n.isLeaf ? 0 : 1));
|
|
4794
4794
|
}
|
|
4795
4795
|
getMap() {
|
|
4796
4796
|
return Ia.empty;
|
|
@@ -4903,7 +4903,7 @@ class oB {
|
|
|
4903
4903
|
Replace the part of the document between `from` and `to` with the
|
|
4904
4904
|
given `slice`.
|
|
4905
4905
|
*/
|
|
4906
|
-
replace(t, n = t, r =
|
|
4906
|
+
replace(t, n = t, r = ft.empty) {
|
|
4907
4907
|
let o = Uw(this.doc, t, n, r);
|
|
4908
4908
|
return o && this.step(o), this;
|
|
4909
4909
|
}
|
|
@@ -4912,13 +4912,13 @@ class oB {
|
|
|
4912
4912
|
fragment, node, or array of nodes.
|
|
4913
4913
|
*/
|
|
4914
4914
|
replaceWith(t, n, r) {
|
|
4915
|
-
return this.replace(t, n, new
|
|
4915
|
+
return this.replace(t, n, new ft(Ze.from(r), 0, 0));
|
|
4916
4916
|
}
|
|
4917
4917
|
/**
|
|
4918
4918
|
Delete the content between the given positions.
|
|
4919
4919
|
*/
|
|
4920
4920
|
delete(t, n) {
|
|
4921
|
-
return this.replace(t, n,
|
|
4921
|
+
return this.replace(t, n, ft.empty);
|
|
4922
4922
|
}
|
|
4923
4923
|
/**
|
|
4924
4924
|
Insert the given content at the given position.
|
|
@@ -5146,14 +5146,14 @@ class Vt {
|
|
|
5146
5146
|
Replace the selection with a slice or, if no slice is given,
|
|
5147
5147
|
delete the selection. Will append to the given transaction.
|
|
5148
5148
|
*/
|
|
5149
|
-
replace(t, n =
|
|
5149
|
+
replace(t, n = ft.empty) {
|
|
5150
5150
|
let r = n.content.lastChild, o = null;
|
|
5151
5151
|
for (let s = 0; s < n.openEnd; s++)
|
|
5152
5152
|
o = r, r = r.lastChild;
|
|
5153
5153
|
let i = t.steps.length, a = this.ranges;
|
|
5154
5154
|
for (let s = 0; s < a.length; s++) {
|
|
5155
5155
|
let { $from: l, $to: u } = a[s], c = t.mapping.slice(i);
|
|
5156
|
-
t.replaceRange(c.map(l.pos), c.map(u.pos), s ?
|
|
5156
|
+
t.replaceRange(c.map(l.pos), c.map(u.pos), s ? ft.empty : n), s == 0 && QV(t, i, (r ? r.isInline : o && o.isTextblock) ? -1 : 1);
|
|
5157
5157
|
}
|
|
5158
5158
|
}
|
|
5159
5159
|
/**
|
|
@@ -5279,8 +5279,8 @@ class kt extends Vt {
|
|
|
5279
5279
|
let o = t.resolve(n.map(this.anchor));
|
|
5280
5280
|
return new kt(o.parent.inlineContent ? o : r, r);
|
|
5281
5281
|
}
|
|
5282
|
-
replace(t, n =
|
|
5283
|
-
if (super.replace(t, n), n ==
|
|
5282
|
+
replace(t, n = ft.empty) {
|
|
5283
|
+
if (super.replace(t, n), n == ft.empty) {
|
|
5284
5284
|
let r = this.$from.marksAcross(this.$to);
|
|
5285
5285
|
r && t.ensureMarks(r);
|
|
5286
5286
|
}
|
|
@@ -5355,7 +5355,7 @@ class Ct extends Vt {
|
|
|
5355
5355
|
return r ? Vt.near(i) : new Ct(i);
|
|
5356
5356
|
}
|
|
5357
5357
|
content() {
|
|
5358
|
-
return new
|
|
5358
|
+
return new ft(Ze.from(this.node), 0, 0);
|
|
5359
5359
|
}
|
|
5360
5360
|
eq(t) {
|
|
5361
5361
|
return t instanceof Ct && t.anchor == this.anchor;
|
|
@@ -5410,8 +5410,8 @@ class ra extends Vt {
|
|
|
5410
5410
|
constructor(t) {
|
|
5411
5411
|
super(t.resolve(0), t.resolve(t.content.size));
|
|
5412
5412
|
}
|
|
5413
|
-
replace(t, n =
|
|
5414
|
-
if (n ==
|
|
5413
|
+
replace(t, n = ft.empty) {
|
|
5414
|
+
if (n == ft.empty) {
|
|
5415
5415
|
t.delete(0, t.doc.content.size);
|
|
5416
5416
|
let r = Vt.atStart(t.doc);
|
|
5417
5417
|
r.eq(t.selection) || t.setSelection(r);
|
|
@@ -5908,7 +5908,7 @@ const kae = (e, t, n) => {
|
|
|
5908
5908
|
return !0;
|
|
5909
5909
|
if (r.parent.content.size == 0 && (q2(i, "end") || Ct.isSelectable(i)))
|
|
5910
5910
|
for (let a = r.depth; ; a--) {
|
|
5911
|
-
let s = Uw(e.doc, r.before(a), r.after(a),
|
|
5911
|
+
let s = Uw(e.doc, r.before(a), r.after(a), ft.empty);
|
|
5912
5912
|
if (s && s.slice.size < s.to - s.from) {
|
|
5913
5913
|
if (t) {
|
|
5914
5914
|
let l = e.tr.step(s);
|
|
@@ -5952,7 +5952,7 @@ function Fae(e, t, n) {
|
|
|
5952
5952
|
return !1;
|
|
5953
5953
|
s = c;
|
|
5954
5954
|
}
|
|
5955
|
-
let u = Uw(e.doc, i, l,
|
|
5955
|
+
let u = Uw(e.doc, i, l, ft.empty);
|
|
5956
5956
|
if (!u || u.from != i || u instanceof ko && u.slice.size >= l - i)
|
|
5957
5957
|
return !1;
|
|
5958
5958
|
if (n) {
|
|
@@ -6007,7 +6007,7 @@ const Mae = (e, t, n) => {
|
|
|
6007
6007
|
if (jae(e, o, t, 1))
|
|
6008
6008
|
return !0;
|
|
6009
6009
|
if (r.parent.content.size == 0 && (q2(i, "start") || Ct.isSelectable(i))) {
|
|
6010
|
-
let a = Uw(e.doc, r.before(), r.after(),
|
|
6010
|
+
let a = Uw(e.doc, r.before(), r.after(), ft.empty);
|
|
6011
6011
|
if (a && a.slice.size < a.to - a.from) {
|
|
6012
6012
|
if (t) {
|
|
6013
6013
|
let s = e.tr.step(a);
|
|
@@ -6162,7 +6162,7 @@ function jae(e, t, n, r) {
|
|
|
6162
6162
|
for (let y = a.length - 1; y >= 0; y--)
|
|
6163
6163
|
p = Ze.from(a[y].create(null, p));
|
|
6164
6164
|
p = Ze.from(o.copy(p));
|
|
6165
|
-
let g = e.tr.step(new Co(t.pos - 1, h, t.pos, h, new
|
|
6165
|
+
let g = e.tr.step(new Co(t.pos - 1, h, t.pos, h, new ft(p, 1, 0), a.length, !0)), m = g.doc.resolve(h + 2 * a.length);
|
|
6166
6166
|
m.nodeAfter && m.nodeAfter.type == o.type && b0(g.doc, m.pos) && g.join(m.pos), n(g.scrollIntoView());
|
|
6167
6167
|
}
|
|
6168
6168
|
return !0;
|
|
@@ -6182,7 +6182,7 @@ function jae(e, t, n, r) {
|
|
|
6182
6182
|
let y = Ze.empty;
|
|
6183
6183
|
for (let v = p.length - 1; v >= 0; v--)
|
|
6184
6184
|
y = Ze.from(p[v].copy(y));
|
|
6185
|
-
let b = e.tr.step(new Co(t.pos - p.length, t.pos + i.nodeSize, t.pos + m, t.pos + i.nodeSize - m, new
|
|
6185
|
+
let b = e.tr.step(new Co(t.pos - p.length, t.pos + i.nodeSize, t.pos + m, t.pos + i.nodeSize - m, new ft(y, p.length, 0), 0, !0));
|
|
6186
6186
|
n(b.scrollIntoView());
|
|
6187
6187
|
}
|
|
6188
6188
|
return !0;
|
|
@@ -6274,7 +6274,7 @@ function kDe(e, t, n, r, o) {
|
|
|
6274
6274
|
let i = Ze.empty;
|
|
6275
6275
|
for (let c = n.length - 1; c >= 0; c--)
|
|
6276
6276
|
i = Ze.from(n[c].type.create(n[c].attrs, i));
|
|
6277
|
-
e.step(new Co(t.start - (r ? 2 : 0), t.end, t.start, t.end, new
|
|
6277
|
+
e.step(new Co(t.start - (r ? 2 : 0), t.end, t.start, t.end, new ft(i, 0, 0), n.length, !0));
|
|
6278
6278
|
let a = 0;
|
|
6279
6279
|
for (let c = 0; c < n.length; c++)
|
|
6280
6280
|
n[c].type == o && (a = c + 1);
|
|
@@ -6291,7 +6291,7 @@ function FDe(e) {
|
|
|
6291
6291
|
}
|
|
6292
6292
|
function CDe(e, t, n, r) {
|
|
6293
6293
|
let o = e.tr, i = r.end, a = r.$to.end(r.depth);
|
|
6294
|
-
i < a && (o.step(new Co(i - 1, a, i, a, new
|
|
6294
|
+
i < a && (o.step(new Co(i - 1, a, i, a, new ft(Ze.from(n.create(null, r.parent.copy())), 1, 0), 1, !0)), r = new q8(o.doc.resolve(r.$from.pos), o.doc.resolve(a), r.depth));
|
|
6295
6295
|
const s = $g(r);
|
|
6296
6296
|
if (s == null)
|
|
6297
6297
|
return !1;
|
|
@@ -6310,7 +6310,7 @@ function DDe(e, t, n) {
|
|
|
6310
6310
|
if (!u.canReplace(c + (s ? 0 : 1), c + 1, a.content.append(l ? Ze.empty : Ze.from(o))))
|
|
6311
6311
|
return !1;
|
|
6312
6312
|
let d = i.pos, f = d + a.nodeSize;
|
|
6313
|
-
return r.step(new Co(d - (s ? 1 : 0), f + (l ? 1 : 0), d + 1, f - 1, new
|
|
6313
|
+
return r.step(new Co(d - (s ? 1 : 0), f + (l ? 1 : 0), d + 1, f - 1, new ft((s ? Ze.empty : Ze.from(o.copy(Ze.empty))).append(l ? Ze.empty : Ze.from(o.copy(Ze.empty))), s ? 0 : 1, l ? 0 : 1), s ? 0 : 1)), t(r.scrollIntoView()), !0;
|
|
6314
6314
|
}
|
|
6315
6315
|
function MDe(e) {
|
|
6316
6316
|
return function(t, n) {
|
|
@@ -6324,7 +6324,7 @@ function MDe(e) {
|
|
|
6324
6324
|
if (l.type != e)
|
|
6325
6325
|
return !1;
|
|
6326
6326
|
if (n) {
|
|
6327
|
-
let u = l.lastChild && l.lastChild.type == s.type, c = Ze.from(u ? e.create() : null), d = new
|
|
6327
|
+
let u = l.lastChild && l.lastChild.type == s.type, c = Ze.from(u ? e.create() : null), d = new ft(Ze.from(e.create(null, Ze.from(s.type.create(null, c)))), u ? 3 : 1, 0), f = i.start, h = i.end;
|
|
6328
6328
|
n(t.tr.step(new Co(f - (u ? 3 : 1), h, f, h, d, 1, !0)).scrollIntoView());
|
|
6329
6329
|
}
|
|
6330
6330
|
return !0;
|
|
@@ -8213,7 +8213,7 @@ function Yae(e, t, n, r, o) {
|
|
|
8213
8213
|
if (e.someProp("transformPastedText", (f) => {
|
|
8214
8214
|
t = f(t, i || r, e);
|
|
8215
8215
|
}), i)
|
|
8216
|
-
return s = new
|
|
8216
|
+
return s = new ft(Ze.from(e.state.schema.text(t.replace(/\r\n?/g, `
|
|
8217
8217
|
`))), 0, 0), e.someProp("transformPasted", (f) => {
|
|
8218
8218
|
s = f(s, e, !0);
|
|
8219
8219
|
}), s;
|
|
@@ -8249,7 +8249,7 @@ function Yae(e, t, n, r, o) {
|
|
|
8249
8249
|
}
|
|
8250
8250
|
})), c)
|
|
8251
8251
|
s = wMe(CW(s, +c[1], +c[2]), c[4]);
|
|
8252
|
-
else if (s =
|
|
8252
|
+
else if (s = ft.maxOpen(yMe(s.content, o), !0), s.openStart || s.openEnd) {
|
|
8253
8253
|
let d = 0, f = 0;
|
|
8254
8254
|
for (let h = s.content.firstChild; d < s.openStart && !h.type.spec.isolating; d++, h = h.firstChild)
|
|
8255
8255
|
;
|
|
@@ -8310,7 +8310,7 @@ function Sj(e, t, n, r, o, i) {
|
|
|
8310
8310
|
return e.childCount > 1 && (i = 0), o < r - 1 && (s = Sj(s, t, n, r, o + 1, i)), o >= n && (s = t < 0 ? a.contentMatchAt(0).fillBefore(s, i <= o).append(s) : s.append(a.contentMatchAt(a.childCount).fillBefore(Ze.empty, !0))), e.replaceChild(t < 0 ? 0 : e.childCount - 1, a.copy(s));
|
|
8311
8311
|
}
|
|
8312
8312
|
function CW(e, t, n) {
|
|
8313
|
-
return t < e.openStart && (e = new
|
|
8313
|
+
return t < e.openStart && (e = new ft(Sj(e.content, -1, t, e.openStart, 0, e.openEnd), t, e.openEnd)), n < e.openEnd && (e = new ft(Sj(e.content, 1, n, e.openEnd, 0, 0), e.openStart, n)), e;
|
|
8314
8314
|
}
|
|
8315
8315
|
const ese = {
|
|
8316
8316
|
thead: ["table"],
|
|
@@ -8364,7 +8364,7 @@ function wMe(e, t) {
|
|
|
8364
8364
|
break;
|
|
8365
8365
|
o = Ze.from(l.create(r[s + 1], o)), i++, a++;
|
|
8366
8366
|
}
|
|
8367
|
-
return new
|
|
8367
|
+
return new ft(o, i, a);
|
|
8368
8368
|
}
|
|
8369
8369
|
const Ni = {}, _i = {}, kMe = { touchstart: !0, touchmove: !0 };
|
|
8370
8370
|
class FMe {
|
|
@@ -8680,7 +8680,7 @@ function UMe(e, t) {
|
|
|
8680
8680
|
}
|
|
8681
8681
|
function n4(e, t, n, r, o) {
|
|
8682
8682
|
let i = Yae(e, t, n, r, e.state.selection.$from);
|
|
8683
|
-
if (e.someProp("handlePaste", (l) => l(e, o, i ||
|
|
8683
|
+
if (e.someProp("handlePaste", (l) => l(e, o, i || ft.empty)))
|
|
8684
8684
|
return !0;
|
|
8685
8685
|
if (!i)
|
|
8686
8686
|
return !1;
|
|
@@ -8746,7 +8746,7 @@ _i.drop = (e, t) => {
|
|
|
8746
8746
|
a = p(a, e, !1);
|
|
8747
8747
|
}) : a = Yae(e, ase(n.dataTransfer), t4 ? null : n.dataTransfer.getData("text/html"), !1, i);
|
|
8748
8748
|
let s = !!(r && lse(e, n));
|
|
8749
|
-
if (e.someProp("handleDrop", (p) => p(e, n, a ||
|
|
8749
|
+
if (e.someProp("handleDrop", (p) => p(e, n, a || ft.empty, s))) {
|
|
8750
8750
|
n.preventDefault();
|
|
8751
8751
|
return;
|
|
8752
8752
|
}
|
|
@@ -11510,7 +11510,7 @@ var AAe = ({ keepMarks: e = !0 } = {}) => ({ tr: t, state: n, dispatch: r, edito
|
|
|
11510
11510
|
}, k = ((a = s.contentMatch.defaultType) == null ? void 0 : a.createAndFill(x)) || void 0;
|
|
11511
11511
|
y = y.append(Ze.from(s.createAndFill(null, k) || void 0));
|
|
11512
11512
|
const F = l.before(l.depth - (b - 1));
|
|
11513
|
-
n.replace(F, l.after(-v), new
|
|
11513
|
+
n.replace(F, l.after(-v), new ft(y, 4 - b, 0));
|
|
11514
11514
|
let C = -1;
|
|
11515
11515
|
n.doc.nodesBetween(F, n.doc.content.size, (D, T) => {
|
|
11516
11516
|
if (C > -1)
|
|
@@ -16126,16 +16126,16 @@ var rr = class Mc extends Vt {
|
|
|
16126
16126
|
a.push(t.child(l).copy(Ze.from(u)));
|
|
16127
16127
|
}
|
|
16128
16128
|
const s = this.isColSelection() && this.isRowSelection() ? t : a;
|
|
16129
|
-
return new
|
|
16129
|
+
return new ft(Ze.from(s), 1, 1);
|
|
16130
16130
|
}
|
|
16131
|
-
replace(t, n =
|
|
16131
|
+
replace(t, n = ft.empty) {
|
|
16132
16132
|
const r = t.steps.length, o = this.ranges;
|
|
16133
16133
|
for (let a = 0; a < o.length; a++) {
|
|
16134
16134
|
const { $from: s, $to: l } = o[a], u = t.mapping.slice(r);
|
|
16135
16135
|
t.replace(
|
|
16136
16136
|
u.map(s.pos),
|
|
16137
16137
|
u.map(l.pos),
|
|
16138
|
-
a ?
|
|
16138
|
+
a ? ft.empty : n
|
|
16139
16139
|
);
|
|
16140
16140
|
}
|
|
16141
16141
|
const i = Vt.findFrom(
|
|
@@ -16145,7 +16145,7 @@ var rr = class Mc extends Vt {
|
|
|
16145
16145
|
i && t.setSelection(i);
|
|
16146
16146
|
}
|
|
16147
16147
|
replaceWith(t, n) {
|
|
16148
|
-
this.replace(t, new
|
|
16148
|
+
this.replace(t, new ft(Ze.from(n), 0, 0));
|
|
16149
16149
|
}
|
|
16150
16150
|
forEachCell(t) {
|
|
16151
16151
|
const n = this.$anchorCell.node(-1), r = Ur.get(n), o = this.$anchorCell.start(-1), i = r.cellsInRect(
|
|
@@ -16789,7 +16789,7 @@ function ev(e, t) {
|
|
|
16789
16789
|
i.content.eq(o) || r.replace(
|
|
16790
16790
|
r.mapping.map(a + 1),
|
|
16791
16791
|
r.mapping.map(a + i.nodeSize - 1),
|
|
16792
|
-
new
|
|
16792
|
+
new ft(o, 0, 0)
|
|
16793
16793
|
);
|
|
16794
16794
|
}), r.docChanged && t(r);
|
|
16795
16795
|
}
|
|
@@ -16807,14 +16807,14 @@ function KTe(e) {
|
|
|
16807
16807
|
const c = l ? 0 : Math.max(0, n - 1), d = l < t.childCount - 1 ? 0 : Math.max(0, r - 1);
|
|
16808
16808
|
(c || d) && (u = Wj(
|
|
16809
16809
|
di(a).row,
|
|
16810
|
-
new
|
|
16810
|
+
new ft(u, c, d)
|
|
16811
16811
|
).content), s.push(u);
|
|
16812
16812
|
}
|
|
16813
16813
|
else if (i == "cell" || i == "header_cell")
|
|
16814
16814
|
s.push(
|
|
16815
16815
|
n || r ? Wj(
|
|
16816
16816
|
di(a).row,
|
|
16817
|
-
new
|
|
16817
|
+
new ft(t, n, r)
|
|
16818
16818
|
).content : t
|
|
16819
16819
|
);
|
|
16820
16820
|
else
|
|
@@ -16981,7 +16981,7 @@ function p$(e, t, n, r, o) {
|
|
|
16981
16981
|
d.replace(
|
|
16982
16982
|
d.mapping.slice(f).map(g + n),
|
|
16983
16983
|
d.mapping.slice(f).map(m + n),
|
|
16984
|
-
new
|
|
16984
|
+
new ft(o.rows[p - s], 0, 0)
|
|
16985
16985
|
);
|
|
16986
16986
|
}
|
|
16987
16987
|
h(), d.setSelection(
|
|
@@ -18184,7 +18184,7 @@ function wje() {
|
|
|
18184
18184
|
} finally {
|
|
18185
18185
|
ue = !1, K.current = Dt, te(), Error.prepareStackTrace = bt;
|
|
18186
18186
|
}
|
|
18187
|
-
var
|
|
18187
|
+
var pt = Q ? Q.displayName || Q.name : "", Yt = pt ? ae(pt) : "";
|
|
18188
18188
|
return typeof Q == "function" && P.set(Q, Yt), Yt;
|
|
18189
18189
|
}
|
|
18190
18190
|
function fe(Q, Ee, Pe) {
|
|
@@ -18368,23 +18368,23 @@ function wje() {
|
|
|
18368
18368
|
return Ae(Q, gt, bn, bt, Ye, Z.current, yt);
|
|
18369
18369
|
}
|
|
18370
18370
|
}
|
|
18371
|
-
var
|
|
18371
|
+
var Ve = y.ReactCurrentOwner, $e = y.ReactDebugCurrentFrame;
|
|
18372
18372
|
function Ke(Q) {
|
|
18373
18373
|
if (Q) {
|
|
18374
18374
|
var Ee = Q._owner, Pe = le(Q.type, Q._source, Ee ? Ee.type : null);
|
|
18375
|
-
|
|
18375
|
+
$e.setExtraStackFrame(Pe);
|
|
18376
18376
|
} else
|
|
18377
|
-
|
|
18377
|
+
$e.setExtraStackFrame(null);
|
|
18378
18378
|
}
|
|
18379
|
-
var
|
|
18380
|
-
|
|
18379
|
+
var ut;
|
|
18380
|
+
ut = !1;
|
|
18381
18381
|
function Oe(Q) {
|
|
18382
18382
|
return typeof Q == "object" && Q !== null && Q.$$typeof === t;
|
|
18383
18383
|
}
|
|
18384
18384
|
function ze() {
|
|
18385
18385
|
{
|
|
18386
|
-
if (
|
|
18387
|
-
var Q = L(
|
|
18386
|
+
if (Ve.current) {
|
|
18387
|
+
var Q = L(Ve.current.type);
|
|
18388
18388
|
if (Q)
|
|
18389
18389
|
return `
|
|
18390
18390
|
|
|
@@ -18409,7 +18409,7 @@ Check the top-level render call using <` + Pe + ">.");
|
|
|
18409
18409
|
return Ee;
|
|
18410
18410
|
}
|
|
18411
18411
|
}
|
|
18412
|
-
function
|
|
18412
|
+
function ht(Q, Ee) {
|
|
18413
18413
|
{
|
|
18414
18414
|
if (!Q._store || Q._store.validated || Q.key != null)
|
|
18415
18415
|
return;
|
|
@@ -18419,7 +18419,7 @@ Check the top-level render call using <` + Pe + ">.");
|
|
|
18419
18419
|
return;
|
|
18420
18420
|
at[Pe] = !0;
|
|
18421
18421
|
var Ye = "";
|
|
18422
|
-
Q && Q._owner && Q._owner !==
|
|
18422
|
+
Q && Q._owner && Q._owner !== Ve.current && (Ye = " It was passed a child from " + L(Q._owner.type) + "."), Ke(Q), b('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', Pe, Ye), Ke(null);
|
|
18423
18423
|
}
|
|
18424
18424
|
}
|
|
18425
18425
|
function Mt(Q, Ee) {
|
|
@@ -18429,7 +18429,7 @@ Check the top-level render call using <` + Pe + ">.");
|
|
|
18429
18429
|
if (ge(Q))
|
|
18430
18430
|
for (var Pe = 0; Pe < Q.length; Pe++) {
|
|
18431
18431
|
var Ye = Q[Pe];
|
|
18432
|
-
Oe(Ye) &&
|
|
18432
|
+
Oe(Ye) && ht(Ye, Ee);
|
|
18433
18433
|
}
|
|
18434
18434
|
else if (Oe(Q))
|
|
18435
18435
|
Q._store && (Q._store.validated = !0);
|
|
@@ -18437,7 +18437,7 @@ Check the top-level render call using <` + Pe + ">.");
|
|
|
18437
18437
|
var bt = m(Q);
|
|
18438
18438
|
if (typeof bt == "function" && bt !== Q.entries)
|
|
18439
18439
|
for (var Dt = bt.call(Q), yt; !(yt = Dt.next()).done; )
|
|
18440
|
-
Oe(yt.value) &&
|
|
18440
|
+
Oe(yt.value) && ht(yt.value, Ee);
|
|
18441
18441
|
}
|
|
18442
18442
|
}
|
|
18443
18443
|
}
|
|
@@ -18458,8 +18458,8 @@ Check the top-level render call using <` + Pe + ">.");
|
|
|
18458
18458
|
if (Pe) {
|
|
18459
18459
|
var Ye = L(Ee);
|
|
18460
18460
|
Fe(Pe, Q.props, "prop", Ye, Q);
|
|
18461
|
-
} else if (Ee.PropTypes !== void 0 && !
|
|
18462
|
-
|
|
18461
|
+
} else if (Ee.PropTypes !== void 0 && !ut) {
|
|
18462
|
+
ut = !0;
|
|
18463
18463
|
var bt = L(Ee);
|
|
18464
18464
|
b("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", bt || "Unknown");
|
|
18465
18465
|
}
|
|
@@ -18498,8 +18498,8 @@ Check the top-level render call using <` + Pe + ">.");
|
|
|
18498
18498
|
if (Ne !== void 0)
|
|
18499
18499
|
if (Ye)
|
|
18500
18500
|
if (ge(Ne)) {
|
|
18501
|
-
for (var
|
|
18502
|
-
Mt(Ne[
|
|
18501
|
+
for (var pt = 0; pt < Ne.length; pt++)
|
|
18502
|
+
Mt(Ne[pt], Q);
|
|
18503
18503
|
Object.freeze && Object.freeze(Ne);
|
|
18504
18504
|
} else
|
|
18505
18505
|
b("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");
|
|
@@ -49664,7 +49664,7 @@ function QEt({ children: e, isPresent: t }) {
|
|
|
49664
49664
|
}, [t]), A.jsx(JEt, { isPresent: t, childRef: r, sizeRef: o, children: W.cloneElement(e, { ref: r }) });
|
|
49665
49665
|
}
|
|
49666
49666
|
const eAt = ({ children: e, initial: t, isPresent: n, onExitComplete: r, custom: o, presenceAffectsLayout: i, mode: a }) => {
|
|
49667
|
-
const s = tO(tAt), l = Wg(), u =
|
|
49667
|
+
const s = tO(tAt), l = Wg(), u = We((d) => {
|
|
49668
49668
|
s.set(d, !0);
|
|
49669
49669
|
for (const f of s.values())
|
|
49670
49670
|
if (!f)
|
|
@@ -49703,7 +49703,7 @@ function Lue(e = !0) {
|
|
|
49703
49703
|
He(() => {
|
|
49704
49704
|
e && o(i);
|
|
49705
49705
|
}, [e]);
|
|
49706
|
-
const a =
|
|
49706
|
+
const a = We(() => e && r && r(i), [i, r, e]);
|
|
49707
49707
|
return !n && r ? [!1, a] : [!0];
|
|
49708
49708
|
}
|
|
49709
49709
|
const sv = (e) => e.key || "";
|
|
@@ -49980,7 +49980,7 @@ function Yp(e) {
|
|
|
49980
49980
|
return e && typeof e == "object" && Object.prototype.hasOwnProperty.call(e, "current");
|
|
49981
49981
|
}
|
|
49982
49982
|
function pAt(e, t, n) {
|
|
49983
|
-
return
|
|
49983
|
+
return We(
|
|
49984
49984
|
(r) => {
|
|
49985
49985
|
r && e.onMount && e.onMount(r), t && (r ? t.mount(r) : t.unmount()), n && (typeof n == "function" ? n(r) : Yp(n) && (n.current = r));
|
|
49986
49986
|
},
|
|
@@ -60918,15 +60918,15 @@ function sOt({ open: e, onOpenChange: t, children: n, onDrag: r, onRelease: o, s
|
|
|
60918
60918
|
const [j = !1, N] = kfe({
|
|
60919
60919
|
defaultProp: k,
|
|
60920
60920
|
prop: e,
|
|
60921
|
-
onChange: (
|
|
60922
|
-
t == null || t(
|
|
60923
|
-
_ == null || _(
|
|
60924
|
-
}, Ar.DURATION * 1e3),
|
|
60921
|
+
onChange: ($e) => {
|
|
60922
|
+
t == null || t($e), !$e && !b && Z(), setTimeout(() => {
|
|
60923
|
+
_ == null || _($e);
|
|
60924
|
+
}, Ar.DURATION * 1e3), $e && !m && typeof window < "u" && window.requestAnimationFrame(() => {
|
|
60925
60925
|
document.body.style.pointerEvents = "auto";
|
|
60926
|
-
}),
|
|
60926
|
+
}), $e || (document.body.style.pointerEvents = "auto");
|
|
60927
60927
|
}
|
|
60928
|
-
}), [O, B] = _e.useState(!1), [U, $] = _e.useState(!1), [q, z] = _e.useState(!1), Y = _e.useRef(null), oe = _e.useRef(null), te = _e.useRef(null), K = _e.useRef(null), ne = _e.useRef(null), ae = _e.useRef(!1), ue = _e.useRef(null), P = _e.useRef(0), J = _e.useRef(!1), re = _e.useRef(!k), fe = _e.useRef(0), R = _e.useRef(null), le = _e.useRef(((L = R.current) == null ? void 0 : L.getBoundingClientRect().height) || 0), ce = _e.useRef(((M = R.current) == null ? void 0 : M.getBoundingClientRect().width) || 0), ee = _e.useRef(0), X = _e.useCallback((
|
|
60929
|
-
i &&
|
|
60928
|
+
}), [O, B] = _e.useState(!1), [U, $] = _e.useState(!1), [q, z] = _e.useState(!1), Y = _e.useRef(null), oe = _e.useRef(null), te = _e.useRef(null), K = _e.useRef(null), ne = _e.useRef(null), ae = _e.useRef(!1), ue = _e.useRef(null), P = _e.useRef(0), J = _e.useRef(!1), re = _e.useRef(!k), fe = _e.useRef(0), R = _e.useRef(null), le = _e.useRef(((L = R.current) == null ? void 0 : L.getBoundingClientRect().height) || 0), ce = _e.useRef(((M = R.current) == null ? void 0 : M.getBoundingClientRect().width) || 0), ee = _e.useRef(0), X = _e.useCallback(($e) => {
|
|
60929
|
+
i && $e === pe.length - 1 && (oe.current = /* @__PURE__ */ new Date());
|
|
60930
60930
|
}, []), { activeSnapPoint: de, activeSnapPointIndex: Fe, setActiveSnapPoint: Me, onRelease: ge, snapPointsOffset: pe, onDrag: me, shouldFade: be, getPercentageDragged: H } = rOt({
|
|
60931
60931
|
snapPoints: i,
|
|
60932
60932
|
activeSnapPointProp: h,
|
|
@@ -60953,16 +60953,16 @@ function sOt({ open: e, onOpenChange: t, children: n, onDrag: r, onRelease: o, s
|
|
|
60953
60953
|
function se() {
|
|
60954
60954
|
return (window.innerWidth - jL) / window.innerWidth;
|
|
60955
60955
|
}
|
|
60956
|
-
function ye(
|
|
60957
|
-
var Ke,
|
|
60958
|
-
!c && !i || R.current && !R.current.contains(
|
|
60956
|
+
function ye($e) {
|
|
60957
|
+
var Ke, ut;
|
|
60958
|
+
!c && !i || R.current && !R.current.contains($e.target) || (le.current = ((Ke = R.current) == null ? void 0 : Ke.getBoundingClientRect().height) || 0, ce.current = ((ut = R.current) == null ? void 0 : ut.getBoundingClientRect().width) || 0, $(!0), te.current = /* @__PURE__ */ new Date(), gfe() && window.addEventListener("touchend", () => ae.current = !1, {
|
|
60959
60959
|
once: !0
|
|
60960
|
-
}),
|
|
60960
|
+
}), $e.target.setPointerCapture($e.pointerId), P.current = to(x) ? $e.pageY : $e.pageX);
|
|
60961
60961
|
}
|
|
60962
|
-
function we(
|
|
60963
|
-
var
|
|
60964
|
-
let Oe =
|
|
60965
|
-
const ze = (
|
|
60962
|
+
function we($e, Ke) {
|
|
60963
|
+
var ut;
|
|
60964
|
+
let Oe = $e;
|
|
60965
|
+
const ze = (ut = window.getSelection()) == null ? void 0 : ut.toString(), Ge = R.current ? bv(R.current, x) : null, at = /* @__PURE__ */ new Date();
|
|
60966
60966
|
if (Oe.tagName === "SELECT" || Oe.hasAttribute("data-vaul-no-drag") || Oe.closest("[data-vaul-no-drag]"))
|
|
60967
60967
|
return !1;
|
|
60968
60968
|
if (x === "right" || x === "left")
|
|
@@ -60986,33 +60986,33 @@ function sOt({ open: e, onOpenChange: t, children: n, onDrag: r, onRelease: o, s
|
|
|
60986
60986
|
}
|
|
60987
60987
|
return !0;
|
|
60988
60988
|
}
|
|
60989
|
-
function xe(
|
|
60989
|
+
function xe($e) {
|
|
60990
60990
|
if (R.current && U) {
|
|
60991
|
-
const Ke = x === "bottom" || x === "right" ? 1 : -1,
|
|
60991
|
+
const Ke = x === "bottom" || x === "right" ? 1 : -1, ut = (P.current - (to(x) ? $e.pageY : $e.pageX)) * Ke, Oe = ut > 0, ze = i && !c && !Oe;
|
|
60992
60992
|
if (ze && Fe === 0) return;
|
|
60993
|
-
const Ge = Math.abs(
|
|
60994
|
-
let
|
|
60993
|
+
const Ge = Math.abs(ut), at = document.querySelector("[data-vaul-drawer-wrapper]"), st = x === "bottom" || x === "top" ? le.current : ce.current;
|
|
60994
|
+
let ht = Ge / st;
|
|
60995
60995
|
const Mt = H(Ge, Oe);
|
|
60996
|
-
if (Mt !== null && (
|
|
60996
|
+
if (Mt !== null && (ht = Mt), ze && ht >= 1 || !ae.current && !we($e.target, Oe)) return;
|
|
60997
60997
|
if (R.current.classList.add(HM), ae.current = !0, co(R.current, {
|
|
60998
60998
|
transition: "none"
|
|
60999
60999
|
}), co(Y.current, {
|
|
61000
61000
|
transition: "none"
|
|
61001
61001
|
}), i && me({
|
|
61002
|
-
draggedDistance:
|
|
61002
|
+
draggedDistance: ut
|
|
61003
61003
|
}), Oe && !i) {
|
|
61004
|
-
const Lt = JBt(
|
|
61004
|
+
const Lt = JBt(ut), Nt = Math.min(Lt * -1, 0) * Ke;
|
|
61005
61005
|
co(R.current, {
|
|
61006
61006
|
transform: to(x) ? `translate3d(0, ${Nt}px, 0)` : `translate3d(${Nt}px, 0, 0)`
|
|
61007
61007
|
});
|
|
61008
61008
|
return;
|
|
61009
61009
|
}
|
|
61010
|
-
const At = 1 -
|
|
61011
|
-
if ((be || f && Fe === f - 1) && (r == null || r(
|
|
61010
|
+
const At = 1 - ht;
|
|
61011
|
+
if ((be || f && Fe === f - 1) && (r == null || r($e, ht), co(Y.current, {
|
|
61012
61012
|
opacity: `${At}`,
|
|
61013
61013
|
transition: "none"
|
|
61014
61014
|
}, !0)), at && Y.current && a) {
|
|
61015
|
-
const Lt = Math.min(se() +
|
|
61015
|
+
const Lt = Math.min(se() + ht * (1 - se()), 1), Nt = 8 - ht * 8, ln = Math.max(0, 14 - ht * 14);
|
|
61016
61016
|
co(at, {
|
|
61017
61017
|
borderRadius: `${Nt}px`,
|
|
61018
61018
|
transform: to(x) ? `scale(${Lt}) translate3d(0, ${ln}px, 0)` : `scale(${Lt}) translate3d(${ln}px, 0, 0)`,
|
|
@@ -61032,15 +61032,15 @@ function sOt({ open: e, onOpenChange: t, children: n, onDrag: r, onRelease: o, s
|
|
|
61032
61032
|
re.current = !0;
|
|
61033
61033
|
});
|
|
61034
61034
|
}, []), _e.useEffect(() => {
|
|
61035
|
-
var
|
|
61035
|
+
var $e;
|
|
61036
61036
|
function Ke() {
|
|
61037
61037
|
if (!R.current || !T) return;
|
|
61038
|
-
const
|
|
61039
|
-
if (TL(
|
|
61038
|
+
const ut = document.activeElement;
|
|
61039
|
+
if (TL(ut) || J.current) {
|
|
61040
61040
|
var Oe;
|
|
61041
61041
|
const ze = ((Oe = window.visualViewport) == null ? void 0 : Oe.height) || 0, Ge = window.innerHeight;
|
|
61042
61042
|
let at = Ge - ze;
|
|
61043
|
-
const st = R.current.getBoundingClientRect().height || 0,
|
|
61043
|
+
const st = R.current.getBoundingClientRect().height || 0, ht = st > Ge * 0.8;
|
|
61044
61044
|
ee.current || (ee.current = st);
|
|
61045
61045
|
const Mt = R.current.getBoundingClientRect().top;
|
|
61046
61046
|
if (Math.abs(fe.current - at) > 60 && (J.current = !J.current), i && i.length > 0 && pe && Fe) {
|
|
@@ -61050,35 +61050,35 @@ function sOt({ open: e, onOpenChange: t, children: n, onDrag: r, onRelease: o, s
|
|
|
61050
61050
|
if (fe.current = at, st > ze || J.current) {
|
|
61051
61051
|
const At = R.current.getBoundingClientRect().height;
|
|
61052
61052
|
let Lt = At;
|
|
61053
|
-
At > ze && (Lt = ze - (
|
|
61053
|
+
At > ze && (Lt = ze - (ht ? Mt : jL)), g ? R.current.style.height = `${At - Math.max(at, 0)}px` : R.current.style.height = `${Math.max(Lt, ze - Mt)}px`;
|
|
61054
61054
|
} else PBt() || (R.current.style.height = `${ee.current}px`);
|
|
61055
61055
|
i && i.length > 0 && !J.current ? R.current.style.bottom = "0px" : R.current.style.bottom = `${Math.max(at, 0)}px`;
|
|
61056
61056
|
}
|
|
61057
61057
|
}
|
|
61058
|
-
return (
|
|
61059
|
-
var
|
|
61060
|
-
return (
|
|
61058
|
+
return ($e = window.visualViewport) == null || $e.addEventListener("resize", Ke), () => {
|
|
61059
|
+
var ut;
|
|
61060
|
+
return (ut = window.visualViewport) == null ? void 0 : ut.removeEventListener("resize", Ke);
|
|
61061
61061
|
};
|
|
61062
61062
|
}, [
|
|
61063
61063
|
Fe,
|
|
61064
61064
|
i,
|
|
61065
61065
|
pe
|
|
61066
61066
|
]);
|
|
61067
|
-
function Se(
|
|
61068
|
-
ve(), y == null || y(),
|
|
61067
|
+
function Se($e) {
|
|
61068
|
+
ve(), y == null || y(), $e || N(!1), setTimeout(() => {
|
|
61069
61069
|
i && Me(i[0]);
|
|
61070
61070
|
}, Ar.DURATION * 1e3);
|
|
61071
61071
|
}
|
|
61072
61072
|
function Le() {
|
|
61073
61073
|
if (!R.current) return;
|
|
61074
|
-
const
|
|
61074
|
+
const $e = document.querySelector("[data-vaul-drawer-wrapper]"), Ke = bv(R.current, x);
|
|
61075
61075
|
co(R.current, {
|
|
61076
61076
|
transform: "translate3d(0, 0, 0)",
|
|
61077
61077
|
transition: `transform ${Ar.DURATION}s cubic-bezier(${Ar.EASE.join(",")})`
|
|
61078
61078
|
}), co(Y.current, {
|
|
61079
61079
|
transition: `opacity ${Ar.DURATION}s cubic-bezier(${Ar.EASE.join(",")})`,
|
|
61080
61080
|
opacity: "1"
|
|
61081
|
-
}), a && Ke && Ke > 0 && j && co(
|
|
61081
|
+
}), a && Ke && Ke > 0 && j && co($e, {
|
|
61082
61082
|
borderRadius: `${xfe}px`,
|
|
61083
61083
|
overflow: "hidden",
|
|
61084
61084
|
...to(x) ? {
|
|
@@ -61096,12 +61096,12 @@ function sOt({ open: e, onOpenChange: t, children: n, onDrag: r, onRelease: o, s
|
|
|
61096
61096
|
function ve() {
|
|
61097
61097
|
!U || !R.current || (R.current.classList.remove(HM), ae.current = !1, $(!1), K.current = /* @__PURE__ */ new Date());
|
|
61098
61098
|
}
|
|
61099
|
-
function Be(
|
|
61099
|
+
function Be($e) {
|
|
61100
61100
|
if (!U || !R.current) return;
|
|
61101
61101
|
R.current.classList.remove(HM), ae.current = !1, $(!1), K.current = /* @__PURE__ */ new Date();
|
|
61102
61102
|
const Ke = bv(R.current, x);
|
|
61103
|
-
if (
|
|
61104
|
-
const
|
|
61103
|
+
if (!$e || !we($e.target, !1) || !Ke || Number.isNaN(Ke) || te.current === null) return;
|
|
61104
|
+
const ut = K.current.getTime() - te.current.getTime(), Oe = P.current - (to(x) ? $e.pageY : $e.pageX), ze = Math.abs(Oe) / ut;
|
|
61105
61105
|
if (ze > 0.05 && (z(!0), setTimeout(() => {
|
|
61106
61106
|
z(!1);
|
|
61107
61107
|
}, 200)), i) {
|
|
@@ -61110,26 +61110,26 @@ function sOt({ open: e, onOpenChange: t, children: n, onDrag: r, onRelease: o, s
|
|
|
61110
61110
|
closeDrawer: Se,
|
|
61111
61111
|
velocity: ze,
|
|
61112
61112
|
dismissible: c
|
|
61113
|
-
}), o == null || o(
|
|
61113
|
+
}), o == null || o($e, !0);
|
|
61114
61114
|
return;
|
|
61115
61115
|
}
|
|
61116
61116
|
if (x === "bottom" || x === "right" ? Oe > 0 : Oe < 0) {
|
|
61117
|
-
Le(), o == null || o(
|
|
61117
|
+
Le(), o == null || o($e, !0);
|
|
61118
61118
|
return;
|
|
61119
61119
|
}
|
|
61120
61120
|
if (ze > vfe) {
|
|
61121
|
-
Se(), o == null || o(
|
|
61121
|
+
Se(), o == null || o($e, !1);
|
|
61122
61122
|
return;
|
|
61123
61123
|
}
|
|
61124
61124
|
var Ge;
|
|
61125
61125
|
const at = Math.min((Ge = R.current.getBoundingClientRect().height) != null ? Ge : 0, window.innerHeight);
|
|
61126
61126
|
var st;
|
|
61127
|
-
const
|
|
61128
|
-
if (Math.abs(Ke) >= (Mt ?
|
|
61129
|
-
Se(), o == null || o(
|
|
61127
|
+
const ht = Math.min((st = R.current.getBoundingClientRect().width) != null ? st : 0, window.innerWidth), Mt = x === "left" || x === "right";
|
|
61128
|
+
if (Math.abs(Ke) >= (Mt ? ht : at) * l) {
|
|
61129
|
+
Se(), o == null || o($e, !1);
|
|
61130
61130
|
return;
|
|
61131
61131
|
}
|
|
61132
|
-
o == null || o(
|
|
61132
|
+
o == null || o($e, !0), Le();
|
|
61133
61133
|
}
|
|
61134
61134
|
_e.useEffect(() => (j && (co(document.documentElement, {
|
|
61135
61135
|
scrollBehavior: "auto"
|
|
@@ -61138,12 +61138,12 @@ function sOt({ open: e, onOpenChange: t, children: n, onDrag: r, onRelease: o, s
|
|
|
61138
61138
|
}), [
|
|
61139
61139
|
j
|
|
61140
61140
|
]);
|
|
61141
|
-
function Ae(
|
|
61142
|
-
const Ke =
|
|
61141
|
+
function Ae($e) {
|
|
61142
|
+
const Ke = $e ? (window.innerWidth - V0) / window.innerWidth : 1, ut = $e ? -V0 : 0;
|
|
61143
61143
|
ue.current && window.clearTimeout(ue.current), co(R.current, {
|
|
61144
61144
|
transition: `transform ${Ar.DURATION}s cubic-bezier(${Ar.EASE.join(",")})`,
|
|
61145
|
-
transform: to(x) ? `scale(${Ke}) translate3d(0, ${
|
|
61146
|
-
}),
|
|
61145
|
+
transform: to(x) ? `scale(${Ke}) translate3d(0, ${ut}px, 0)` : `scale(${Ke}) translate3d(${ut}px, 0, 0)`
|
|
61146
|
+
}), !$e && R.current && (ue.current = setTimeout(() => {
|
|
61147
61147
|
const Oe = bv(R.current, x);
|
|
61148
61148
|
co(R.current, {
|
|
61149
61149
|
transition: "none",
|
|
@@ -61151,16 +61151,16 @@ function sOt({ open: e, onOpenChange: t, children: n, onDrag: r, onRelease: o, s
|
|
|
61151
61151
|
});
|
|
61152
61152
|
}, 500));
|
|
61153
61153
|
}
|
|
61154
|
-
function Ue(
|
|
61154
|
+
function Ue($e, Ke) {
|
|
61155
61155
|
if (Ke < 0) return;
|
|
61156
|
-
const
|
|
61156
|
+
const ut = (window.innerWidth - V0) / window.innerWidth, Oe = ut + Ke * (1 - ut), ze = -V0 + Ke * V0;
|
|
61157
61157
|
co(R.current, {
|
|
61158
61158
|
transform: to(x) ? `scale(${Oe}) translate3d(0, ${ze}px, 0)` : `scale(${Oe}) translate3d(${ze}px, 0, 0)`,
|
|
61159
61159
|
transition: "none"
|
|
61160
61160
|
});
|
|
61161
61161
|
}
|
|
61162
|
-
function $e
|
|
61163
|
-
const
|
|
61162
|
+
function Ve($e, Ke) {
|
|
61163
|
+
const ut = to(x) ? window.innerHeight : window.innerWidth, Oe = Ke ? (ut - V0) / ut : 1, ze = Ke ? -V0 : 0;
|
|
61164
61164
|
Ke && co(R.current, {
|
|
61165
61165
|
transition: `transform ${Ar.DURATION}s cubic-bezier(${Ar.EASE.join(",")})`,
|
|
61166
61166
|
transform: to(x) ? `scale(${Oe}) translate3d(0, ${ze}px, 0)` : `scale(${Oe}) translate3d(${ze}px, 0, 0)`
|
|
@@ -61174,8 +61174,8 @@ function sOt({ open: e, onOpenChange: t, children: n, onDrag: r, onRelease: o, s
|
|
|
61174
61174
|
m
|
|
61175
61175
|
]), /* @__PURE__ */ _e.createElement(Rk, {
|
|
61176
61176
|
defaultOpen: k,
|
|
61177
|
-
onOpenChange: (
|
|
61178
|
-
!c &&
|
|
61177
|
+
onOpenChange: ($e) => {
|
|
61178
|
+
!c && !$e || ($e ? B(!0) : Se(!0), N($e));
|
|
61179
61179
|
},
|
|
61180
61180
|
open: j
|
|
61181
61181
|
}, /* @__PURE__ */ _e.createElement(pfe.Provider, {
|
|
@@ -61198,7 +61198,7 @@ function sOt({ open: e, onOpenChange: t, children: n, onDrag: r, onRelease: o, s
|
|
|
61198
61198
|
closeDrawer: Se,
|
|
61199
61199
|
onNestedDrag: Ue,
|
|
61200
61200
|
onNestedOpenChange: Ae,
|
|
61201
|
-
onNestedRelease:
|
|
61201
|
+
onNestedRelease: Ve,
|
|
61202
61202
|
keyboardIsOpen: J,
|
|
61203
61203
|
modal: m,
|
|
61204
61204
|
snapPointsOffset: pe,
|
|
@@ -62300,12 +62300,12 @@ const Pr = ({
|
|
|
62300
62300
|
onClose: o,
|
|
62301
62301
|
...i
|
|
62302
62302
|
}) => {
|
|
62303
|
-
const [a, s] = Re(!1), l =
|
|
62303
|
+
const [a, s] = Re(!1), l = We(
|
|
62304
62304
|
(d) => {
|
|
62305
62305
|
n || (s((f) => !f), _e.isValidElement(t) && t.props.onClick && t.props.onClick(d));
|
|
62306
62306
|
},
|
|
62307
62307
|
[n, t]
|
|
62308
|
-
), u =
|
|
62308
|
+
), u = We(
|
|
62309
62309
|
(d) => {
|
|
62310
62310
|
const f = d.target;
|
|
62311
62311
|
!f.closest(".popover-trigger") && !f.closest(".popover-content") && (n || s(!1), o == null || o());
|
|
@@ -80370,7 +80370,7 @@ function uPt(e, t) {
|
|
|
80370
80370
|
}
|
|
80371
80371
|
function cPt() {
|
|
80372
80372
|
var e = rs();
|
|
80373
|
-
return
|
|
80373
|
+
return We(function(t) {
|
|
80374
80374
|
requestAnimationFrame(function() {
|
|
80375
80375
|
e.current && (e.current.scrollTop = t);
|
|
80376
80376
|
});
|
|
@@ -80459,7 +80459,7 @@ function bPt(e) {
|
|
|
80459
80459
|
return f[c] ? f[c] : (t = f.at(0)) != null ? t : null;
|
|
80460
80460
|
}
|
|
80461
80461
|
function Hh() {
|
|
80462
|
-
var e = im(), t = e[0], n = e[1], r = j6(), o = r[0], i = r[1], a =
|
|
80462
|
+
var e = im(), t = e[0], n = e[1], r = j6(), o = r[0], i = r[1], a = We(function() {
|
|
80463
80463
|
t && n(null), o && i(!1);
|
|
80464
80464
|
}, [t, o, n, i]);
|
|
80465
80465
|
return a;
|
|
@@ -80505,19 +80505,19 @@ function xPt() {
|
|
|
80505
80505
|
}
|
|
80506
80506
|
function qh() {
|
|
80507
80507
|
var e = D0();
|
|
80508
|
-
return
|
|
80508
|
+
return We(function() {
|
|
80509
80509
|
ns(e.current);
|
|
80510
80510
|
}, [e]);
|
|
80511
80511
|
}
|
|
80512
80512
|
function wPt() {
|
|
80513
80513
|
var e = mR();
|
|
80514
|
-
return
|
|
80514
|
+
return We(function() {
|
|
80515
80515
|
e.current && Che(e.current);
|
|
80516
80516
|
}, [e]);
|
|
80517
80517
|
}
|
|
80518
80518
|
function Lhe() {
|
|
80519
80519
|
var e = yR();
|
|
80520
|
-
return
|
|
80520
|
+
return We(function() {
|
|
80521
80521
|
e.current && Che(e.current);
|
|
80522
80522
|
}, [e]);
|
|
80523
80523
|
}
|
|
@@ -80818,13 +80818,13 @@ function BPt() {
|
|
|
80818
80818
|
}
|
|
80819
80819
|
function Bhe() {
|
|
80820
80820
|
var e = Lhe(), t = tF(), n = rs();
|
|
80821
|
-
return
|
|
80821
|
+
return We(function() {
|
|
80822
80822
|
return t ? oF(n.current) : e();
|
|
80823
80823
|
}, [n, e, t]);
|
|
80824
80824
|
}
|
|
80825
80825
|
function OPt() {
|
|
80826
80826
|
var e = qh(), t = Lhe(), n = tF();
|
|
80827
|
-
return
|
|
80827
|
+
return We(function() {
|
|
80828
80828
|
return n ? e() : t();
|
|
80829
80829
|
}, [e, n, t]);
|
|
80830
80830
|
}
|
|
@@ -81220,7 +81220,7 @@ function Xhe(e) {
|
|
|
81220
81220
|
return e.imgUrl !== void 0;
|
|
81221
81221
|
}
|
|
81222
81222
|
function Jhe(e, t) {
|
|
81223
|
-
var n = Qe(), r = _he(), o = sRt(), i = im(), a = i[1], s = Hh(), l = fR(), u = l[0], c = ZRt(t), d = ohe(), f = d[1], h = lm(), p = sm(), g =
|
|
81223
|
+
var n = Qe(), r = _he(), o = sRt(), i = im(), a = i[1], s = Hh(), l = fR(), u = l[0], c = ZRt(t), d = ohe(), f = d[1], h = lm(), p = sm(), g = We(function(b) {
|
|
81224
81224
|
if (!o.current) {
|
|
81225
81225
|
s();
|
|
81226
81226
|
var v = BZ(b), x = v[0], k = v[1];
|
|
@@ -81229,14 +81229,14 @@ function Jhe(e, t) {
|
|
|
81229
81229
|
f(), ERt(x, F), c(ezt(x, F, p, h), b);
|
|
81230
81230
|
}
|
|
81231
81231
|
}
|
|
81232
|
-
}, [u, s, o, c, f, h, p]), m =
|
|
81232
|
+
}, [u, s, o, c, f, h, p]), m = We(function(b) {
|
|
81233
81233
|
var v;
|
|
81234
81234
|
n.current && clearTimeout(n.current);
|
|
81235
81235
|
var x = BZ(b), k = x[0];
|
|
81236
81236
|
!k || !am(k) || (n.current = (v = window) == null ? void 0 : v.setTimeout(function() {
|
|
81237
81237
|
o.current = !0, n.current = void 0, s(), r(b.target), a(k);
|
|
81238
81238
|
}, 500));
|
|
81239
|
-
}, [o, s, r, a]), y =
|
|
81239
|
+
}, [o, s, r, a]), y = We(function() {
|
|
81240
81240
|
n.current ? (clearTimeout(n.current), n.current = void 0) : o.current && requestAnimationFrame(function() {
|
|
81241
81241
|
o.current = !1;
|
|
81242
81242
|
});
|
|
@@ -81621,7 +81621,7 @@ function hzt(e, t) {
|
|
|
81621
81621
|
}
|
|
81622
81622
|
var pzt = 32;
|
|
81623
81623
|
function gzt(e) {
|
|
81624
|
-
var t = Mhe(), n = Uh(), r = n[0], o = um(), i = Qe(), a = hR(), s = a[0], l = Re(), u = l[0], c = l[1], d =
|
|
81624
|
+
var t = Mhe(), n = Uh(), r = n[0], o = um(), i = Qe(), a = hR(), s = a[0], l = Re(), u = l[0], c = l[1], d = We(function() {
|
|
81625
81625
|
var f, h = t.current;
|
|
81626
81626
|
if (h) {
|
|
81627
81627
|
var p = h.querySelector(C4), g = p == null ? void 0 : p.clientHeight, m = (f = g ?? i.current) != null ? f : pzt;
|
|
@@ -86164,13 +86164,13 @@ var VL = /* @__PURE__ */ ((e) => (e.LIST = "LIST", e.CARD = "CARD", e))(VL || {}
|
|
|
86164
86164
|
const VVt = ({
|
|
86165
86165
|
delay: e = 2e3
|
|
86166
86166
|
}) => {
|
|
86167
|
-
const [t, n] = Re(!1), [r, o] = Re(!1), i = Qe(null), a =
|
|
86167
|
+
const [t, n] = Re(!1), [r, o] = Re(!1), i = Qe(null), a = We(() => {
|
|
86168
86168
|
i.current && clearTimeout(i.current), i.current = setTimeout(() => {
|
|
86169
86169
|
n(!0), o(!0);
|
|
86170
86170
|
}, e);
|
|
86171
|
-
}, [e]), s =
|
|
86171
|
+
}, [e]), s = We(() => {
|
|
86172
86172
|
r || n(!1), i.current && clearTimeout(i.current), o(!1);
|
|
86173
|
-
}, [r]), l =
|
|
86173
|
+
}, [r]), l = We(() => n(!0), []), u = We(() => n(!1), []), c = We(() => a(), [a]), d = We(() => s(), [s]);
|
|
86174
86174
|
return {
|
|
86175
86175
|
onMouseEnter: l,
|
|
86176
86176
|
onMouseLeave: u,
|
|
@@ -87373,17 +87373,17 @@ function _Wt(e, t, n, r, o, i, a) {
|
|
|
87373
87373
|
scrollLooper: Be,
|
|
87374
87374
|
slideLooper: Ae,
|
|
87375
87375
|
dragHandler: Ue,
|
|
87376
|
-
animation:
|
|
87377
|
-
eventHandler:
|
|
87376
|
+
animation: Ve,
|
|
87377
|
+
eventHandler: $e,
|
|
87378
87378
|
scrollBounds: Ke,
|
|
87379
87379
|
options: {
|
|
87380
|
-
loop:
|
|
87380
|
+
loop: ut
|
|
87381
87381
|
}
|
|
87382
87382
|
}, Oe) => {
|
|
87383
|
-
const ze = we.settled(), Ge = !Ke.shouldConstrain(), at =
|
|
87384
|
-
st &&
|
|
87385
|
-
const
|
|
87386
|
-
Le.set(
|
|
87383
|
+
const ze = we.settled(), Ge = !Ke.shouldConstrain(), at = ut ? ze : ze && Ge, st = at && !Ue.pointerDown();
|
|
87384
|
+
st && Ve.stop();
|
|
87385
|
+
const ht = Se.get() * Oe + ve.get() * (1 - Oe);
|
|
87386
|
+
Le.set(ht), ut && (Be.loop(we.direction()), Ae.loop()), xe.to(Le.get()), st && $e.emit("settle"), at || $e.emit("scroll");
|
|
87387
87387
|
}, R = dWt(r, o, () => re(ye), (we) => fe(ye, we)), le = 0.68, ce = ne[ue.get()], ee = $3(ce), X = $3(ce), de = $3(ce), Fe = $3(ce), Me = bWt(ee, de, X, Fe, f, le), ge = MWt(d, ne, oe, ae, Fe), pe = EWt(R, ue, P, Me, ge, Fe, a), me = FWt(ae), be = j4(), H = jWt(t, n, a, g), {
|
|
87388
87388
|
slideRegistry: Z
|
|
87389
87389
|
} = DWt(j, b, ne, K, q, J), se = AWt(e, n, Z, pe, Me, be, a, F), ye = {
|
|
@@ -87634,7 +87634,7 @@ function M9(e, t, n) {
|
|
|
87634
87634
|
}
|
|
87635
87635
|
M9.globalOptions = void 0;
|
|
87636
87636
|
function GR(e = {}, t = []) {
|
|
87637
|
-
const n = Qe(e), r = Qe(t), [o, i] = Re(), [a, s] = Re(), l =
|
|
87637
|
+
const n = Qe(e), r = Qe(t), [o, i] = Re(), [a, s] = Re(), l = We(() => {
|
|
87638
87638
|
o && o.reInit(n.current, r.current);
|
|
87639
87639
|
}, [o]);
|
|
87640
87640
|
return He(() => {
|
|
@@ -87674,13 +87674,13 @@ const Kpe = Pn(
|
|
|
87674
87674
|
axis: e === "horizontal" ? "x" : "y"
|
|
87675
87675
|
},
|
|
87676
87676
|
r
|
|
87677
|
-
), [c, d] = Re(!1), [f, h] = Re(!1), p =
|
|
87677
|
+
), [c, d] = Re(!1), [f, h] = Re(!1), p = We((b) => {
|
|
87678
87678
|
b && (d(b.canScrollPrev()), h(b.canScrollNext()));
|
|
87679
|
-
}, []), g =
|
|
87679
|
+
}, []), g = We(() => {
|
|
87680
87680
|
u == null || u.scrollPrev();
|
|
87681
|
-
}, [u]), m =
|
|
87681
|
+
}, [u]), m = We(() => {
|
|
87682
87682
|
u == null || u.scrollNext();
|
|
87683
|
-
}, [u]), y =
|
|
87683
|
+
}, [u]), y = We(
|
|
87684
87684
|
(b) => {
|
|
87685
87685
|
b.key === "ArrowLeft" ? (b.preventDefault(), g()) : b.key === "ArrowRight" && (b.preventDefault(), m());
|
|
87686
87686
|
},
|
|
@@ -87760,14 +87760,14 @@ const ZL = Pn(
|
|
|
87760
87760
|
);
|
|
87761
87761
|
ZL.displayName = "CarouselItem";
|
|
87762
87762
|
const Xpe = Pn(({ index: e, className: t, ...n }, r) => {
|
|
87763
|
-
const { api: o } = U6(), [i, a] = Re(0), [, s] = Re([]), l =
|
|
87763
|
+
const { api: o } = U6(), [i, a] = Re(0), [, s] = Re([]), l = We(
|
|
87764
87764
|
(f) => {
|
|
87765
87765
|
o && o.scrollTo(f);
|
|
87766
87766
|
},
|
|
87767
87767
|
[o]
|
|
87768
|
-
), u =
|
|
87768
|
+
), u = We((f) => {
|
|
87769
87769
|
f && s(f.scrollSnapList());
|
|
87770
|
-
}, []), c =
|
|
87770
|
+
}, []), c = We((f) => {
|
|
87771
87771
|
f && a(f.selectedScrollSnap());
|
|
87772
87772
|
}, []);
|
|
87773
87773
|
He(() => {
|
|
@@ -93963,7 +93963,7 @@ async function SF(e, t) {
|
|
|
93963
93963
|
});
|
|
93964
93964
|
return te === "0x" ? { data: void 0 } : { data: te };
|
|
93965
93965
|
} catch (O) {
|
|
93966
|
-
const B = IKt(O), { offchainLookup: U, offchainLookupSignature: $ } = await import("./ccip-
|
|
93966
|
+
const B = IKt(O), { offchainLookup: U, offchainLookupSignature: $ } = await import("./ccip-B-L2blGd.mjs");
|
|
93967
93967
|
if (e.ccipRead !== !1 && (B == null ? void 0 : B.slice(0, 10)) === $ && x)
|
|
93968
93968
|
return { data: await U(e, { data: B, to: x }) };
|
|
93969
93969
|
throw I && (B == null ? void 0 : B.slice(0, 10)) === "0x101bb98d" ? new pZt({ factory: f }) : Sge(O, {
|
|
@@ -99305,7 +99305,7 @@ class Dme {
|
|
|
99305
99305
|
}), this.client);
|
|
99306
99306
|
}
|
|
99307
99307
|
}
|
|
99308
|
-
|
|
99308
|
+
ct(Dme, "client");
|
|
99309
99309
|
const Mme = Gn(void 0), nQt = ({
|
|
99310
99310
|
children: e,
|
|
99311
99311
|
editor: t,
|
|
@@ -99336,7 +99336,7 @@ const Mme = Gn(void 0), nQt = ({
|
|
|
99336
99336
|
handleClick: !1
|
|
99337
99337
|
}), ae = localStorage.getItem("ensCache"), [ue, P] = Re(
|
|
99338
99338
|
ae ? JSON.parse(ae) : {}
|
|
99339
|
-
), [J, re] = Re([]), fe =
|
|
99339
|
+
), [J, re] = Re([]), fe = We(
|
|
99340
99340
|
async (Ae, Ue) => {
|
|
99341
99341
|
if (J.includes(Ae)) {
|
|
99342
99342
|
Ue({
|
|
@@ -99359,23 +99359,23 @@ const Mme = Gn(void 0), nQt = ({
|
|
|
99359
99359
|
return;
|
|
99360
99360
|
}
|
|
99361
99361
|
try {
|
|
99362
|
-
re((
|
|
99363
|
-
const { name:
|
|
99362
|
+
re((ut) => [...ut, Ae]);
|
|
99363
|
+
const { name: Ve, isEns: $e, resolved: Ke } = await eQt(
|
|
99364
99364
|
Ae,
|
|
99365
99365
|
d
|
|
99366
99366
|
// Add definite assignment assertion if ensResolutionUrl is guaranteed
|
|
99367
99367
|
);
|
|
99368
|
-
Ke && P((
|
|
99368
|
+
Ke && P((ut) => {
|
|
99369
99369
|
const Oe = {
|
|
99370
|
-
...
|
|
99371
|
-
[Ae]: { name:
|
|
99370
|
+
...ut,
|
|
99371
|
+
[Ae]: { name: Ve, isEns: $e }
|
|
99372
99372
|
};
|
|
99373
99373
|
return localStorage.setItem("ensCache", JSON.stringify(Oe)), Oe;
|
|
99374
99374
|
}), re(
|
|
99375
|
-
(
|
|
99376
|
-
), Ue({ name:
|
|
99377
|
-
} catch (
|
|
99378
|
-
console.error("Error fetching ENS name:",
|
|
99375
|
+
(ut) => ut.filter((Oe) => Oe !== Ae)
|
|
99376
|
+
), Ue({ name: Ve, isEns: $e });
|
|
99377
|
+
} catch (Ve) {
|
|
99378
|
+
console.error("Error fetching ENS name:", Ve), Ue({
|
|
99379
99379
|
name: Ae || "Anonymous",
|
|
99380
99380
|
isEns: !1
|
|
99381
99381
|
});
|
|
@@ -99388,14 +99388,24 @@ const Mme = Gn(void 0), nQt = ({
|
|
|
99388
99388
|
);
|
|
99389
99389
|
ZR([q, z, Y], () => {
|
|
99390
99390
|
U && $(!1);
|
|
99391
|
-
})
|
|
99392
|
-
|
|
99393
|
-
const
|
|
99394
|
-
|
|
99395
|
-
|
|
99396
|
-
|
|
99391
|
+
}), He(() => {
|
|
99392
|
+
if (!t) return;
|
|
99393
|
+
const Ae = ({ event: Ue }) => {
|
|
99394
|
+
var $e, Ke, ut;
|
|
99395
|
+
const Ve = Ue.relatedTarget;
|
|
99396
|
+
Ve && (($e = q.current) != null && $e.contains(Ve) || (Ke = Y.current) != null && Ke.contains(Ve) || (ut = z.current) != null && ut.contains(Ve)) || $(!1);
|
|
99397
|
+
};
|
|
99398
|
+
return t.on("blur", Ae), () => {
|
|
99399
|
+
t.off("blur", Ae);
|
|
99400
|
+
};
|
|
99401
|
+
}, [t]);
|
|
99402
|
+
const le = We(() => {
|
|
99403
|
+
const { state: Ae } = t, { from: Ue, to: Ve } = Ae.selection, $e = Ae.doc.textBetween(Ue, Ve, " ");
|
|
99404
|
+
oe ? R && B(R.selectedContent || "") : B($e), $(!0), x == null || x();
|
|
99405
|
+
}, [t, oe, R, x]), ce = We(
|
|
99406
|
+
(Ae, Ue = "", Ve) => ({
|
|
99397
99407
|
id: `comment-${Nd()}`,
|
|
99398
|
-
username:
|
|
99408
|
+
username: Ve,
|
|
99399
99409
|
selectedContent: Ae,
|
|
99400
99410
|
// Preserve line breaks in content
|
|
99401
99411
|
content: Ue || "",
|
|
@@ -99403,11 +99413,11 @@ const Mme = Gn(void 0), nQt = ({
|
|
|
99403
99413
|
createdAt: /* @__PURE__ */ new Date()
|
|
99404
99414
|
}),
|
|
99405
99415
|
[]
|
|
99406
|
-
), ee =
|
|
99416
|
+
), ee = We(
|
|
99407
99417
|
(Ae, Ue) => {
|
|
99408
99418
|
if (!t) return;
|
|
99409
|
-
const { state:
|
|
99410
|
-
|
|
99419
|
+
const { state: Ve } = t, { from: $e, to: Ke } = Ve.selection, ut = Ve.doc.textBetween($e, Ke, " "), Oe = ce(
|
|
99420
|
+
ut,
|
|
99411
99421
|
Ae,
|
|
99412
99422
|
Ue || o
|
|
99413
99423
|
);
|
|
@@ -99421,25 +99431,25 @@ const Mme = Gn(void 0), nQt = ({
|
|
|
99421
99431
|
l,
|
|
99422
99432
|
u
|
|
99423
99433
|
]
|
|
99424
|
-
), X =
|
|
99434
|
+
), X = We(
|
|
99425
99435
|
(Ae) => {
|
|
99426
99436
|
t.commands.resolveComment(Ae), f == null || f(Ae);
|
|
99427
99437
|
},
|
|
99428
99438
|
[t, f]
|
|
99429
|
-
), de =
|
|
99439
|
+
), de = We(
|
|
99430
99440
|
(Ae) => {
|
|
99431
99441
|
t.commands.unresolveComment(Ae), h == null || h(Ae);
|
|
99432
99442
|
},
|
|
99433
99443
|
[t, h]
|
|
99434
|
-
), Fe =
|
|
99444
|
+
), Fe = We(
|
|
99435
99445
|
(Ae) => {
|
|
99436
99446
|
t.commands.unsetComment(Ae), p == null || p(Ae);
|
|
99437
99447
|
},
|
|
99438
99448
|
[t, p]
|
|
99439
|
-
), Me =
|
|
99440
|
-
(Ae, Ue,
|
|
99449
|
+
), Me = We(
|
|
99450
|
+
(Ae, Ue, Ve) => {
|
|
99441
99451
|
if (!Ue.trim()) return;
|
|
99442
|
-
const
|
|
99452
|
+
const $e = {
|
|
99443
99453
|
id: `reply-${Nd()}`,
|
|
99444
99454
|
content: Ue,
|
|
99445
99455
|
username: o,
|
|
@@ -99447,13 +99457,13 @@ const Mme = Gn(void 0), nQt = ({
|
|
|
99447
99457
|
createdAt: /* @__PURE__ */ new Date(),
|
|
99448
99458
|
selectedContent: ""
|
|
99449
99459
|
};
|
|
99450
|
-
|
|
99460
|
+
Ve == null || Ve(Ae, $e);
|
|
99451
99461
|
},
|
|
99452
99462
|
[o]
|
|
99453
|
-
), ge =
|
|
99463
|
+
), ge = We(
|
|
99454
99464
|
(Ae) => {
|
|
99455
|
-
var $e
|
|
99456
|
-
if (!t || !((
|
|
99465
|
+
var Ve, $e;
|
|
99466
|
+
if (!t || !((Ve = t.view) != null && Ve.dom) || !n.length) return;
|
|
99457
99467
|
const Ue = n.find((Ke) => Ke.id === Ae);
|
|
99458
99468
|
if (Ue) {
|
|
99459
99469
|
if (Ue.selectedContent) {
|
|
@@ -99461,8 +99471,8 @@ const Mme = Gn(void 0), nQt = ({
|
|
|
99461
99471
|
`[data-comment-id="${Ae}"]`
|
|
99462
99472
|
);
|
|
99463
99473
|
if (Ke) {
|
|
99464
|
-
const
|
|
99465
|
-
t.commands.setTextSelection({ from:
|
|
99474
|
+
const ut = t.view.posAtDOM(Ke, 0), Oe = ut + ((($e = Ke.textContent) == null ? void 0 : $e.length) ?? 0);
|
|
99475
|
+
t.commands.setTextSelection({ from: ut, to: Oe });
|
|
99466
99476
|
const Ge = [
|
|
99467
99477
|
document.querySelector(".ProseMirror"),
|
|
99468
99478
|
document.getElementById("editor-canvas"),
|
|
@@ -99473,9 +99483,9 @@ const Mme = Gn(void 0), nQt = ({
|
|
|
99473
99483
|
(at) => at && (at.scrollHeight > at.clientHeight || window.getComputedStyle(at).overflow === "auto" || window.getComputedStyle(at).overflowY === "auto")
|
|
99474
99484
|
);
|
|
99475
99485
|
Ge && requestAnimationFrame(() => {
|
|
99476
|
-
const at = Ge.getBoundingClientRect(), st = Ke.getBoundingClientRect(),
|
|
99486
|
+
const at = Ge.getBoundingClientRect(), st = Ke.getBoundingClientRect(), ht = st.top - at.top - at.height / 2 + st.height / 2;
|
|
99477
99487
|
Ge.scrollBy({
|
|
99478
|
-
top:
|
|
99488
|
+
top: ht,
|
|
99479
99489
|
behavior: "smooth"
|
|
99480
99490
|
});
|
|
99481
99491
|
});
|
|
@@ -99485,19 +99495,19 @@ const Mme = Gn(void 0), nQt = ({
|
|
|
99485
99495
|
}
|
|
99486
99496
|
},
|
|
99487
99497
|
[t, n, s]
|
|
99488
|
-
), pe =
|
|
99498
|
+
), pe = We(
|
|
99489
99499
|
(Ae) => {
|
|
99490
99500
|
const Ue = Ae.target.value;
|
|
99491
99501
|
_(Ue), Ue || (Ae.target.style.height = "40px");
|
|
99492
99502
|
},
|
|
99493
99503
|
[]
|
|
99494
|
-
), me =
|
|
99504
|
+
), me = We(
|
|
99495
99505
|
(Ae) => {
|
|
99496
99506
|
const Ue = Ae.target.value;
|
|
99497
99507
|
S(Ue), Ue || (Ae.target.style.height = "40px");
|
|
99498
99508
|
},
|
|
99499
99509
|
[]
|
|
99500
|
-
), be =
|
|
99510
|
+
), be = We(() => {
|
|
99501
99511
|
if (!I.trim() || !o) return;
|
|
99502
99512
|
const Ae = {
|
|
99503
99513
|
id: `comment-${Nd()}`,
|
|
@@ -99522,29 +99532,29 @@ const Mme = Gn(void 0), nQt = ({
|
|
|
99522
99532
|
s,
|
|
99523
99533
|
k,
|
|
99524
99534
|
j
|
|
99525
|
-
]), H =
|
|
99535
|
+
]), H = We(
|
|
99526
99536
|
(Ae) => {
|
|
99527
99537
|
Ae.key === "Enter" && !Ae.shiftKey && (Ae.preventDefault(), be());
|
|
99528
99538
|
},
|
|
99529
99539
|
[be]
|
|
99530
|
-
), Z =
|
|
99540
|
+
), Z = We(() => {
|
|
99531
99541
|
!a || !T.trim() || (Me(a, T, c), _(""));
|
|
99532
|
-
}, [a, T, Me, c]), se =
|
|
99542
|
+
}, [a, T, Me, c]), se = We(
|
|
99533
99543
|
(Ae) => {
|
|
99534
99544
|
Ae.key === "Enter" && !Ae.shiftKey && (Ae.preventDefault(), Z());
|
|
99535
99545
|
},
|
|
99536
99546
|
[Z]
|
|
99537
|
-
), ye =
|
|
99547
|
+
), ye = We(() => {
|
|
99538
99548
|
D((Ae) => !Ae);
|
|
99539
|
-
}, []), we =
|
|
99549
|
+
}, []), we = We(
|
|
99540
99550
|
(Ae, Ue) => {
|
|
99541
99551
|
Ae.currentTarget.style.height = "auto";
|
|
99542
|
-
const
|
|
99552
|
+
const Ve = Math.min(
|
|
99543
99553
|
Math.max(40, Ae.currentTarget.scrollHeight),
|
|
99544
99554
|
Ue.length > 30 || Ue.includes(`
|
|
99545
99555
|
`) ? 96 : 40
|
|
99546
99556
|
);
|
|
99547
|
-
Ae.currentTarget.style.height = `${
|
|
99557
|
+
Ae.currentTarget.style.height = `${Ve}px`;
|
|
99548
99558
|
},
|
|
99549
99559
|
[]
|
|
99550
99560
|
), xe = jt(
|
|
@@ -99555,26 +99565,26 @@ const Mme = Gn(void 0), nQt = ({
|
|
|
99555
99565
|
), Se = jt(
|
|
99556
99566
|
() => xe.findIndex((Ae) => Ae.id === a),
|
|
99557
99567
|
[xe, a]
|
|
99558
|
-
), Le =
|
|
99568
|
+
), Le = We(() => {
|
|
99559
99569
|
var Ae, Ue;
|
|
99560
99570
|
if ((Ae = t.view) != null && Ae.dom && Se > 0) {
|
|
99561
|
-
const
|
|
99562
|
-
`[data-comment-id="${
|
|
99571
|
+
const Ve = xe[Se - 1], $e = t.view.dom.querySelector(
|
|
99572
|
+
`[data-comment-id="${Ve.id}"]`
|
|
99563
99573
|
);
|
|
99564
|
-
if (
|
|
99565
|
-
const Ke = t.view.posAtDOM(
|
|
99566
|
-
t.commands.setTextSelection({ from: Ke, to:
|
|
99574
|
+
if ($e) {
|
|
99575
|
+
const Ke = t.view.posAtDOM($e, 0), ut = Ke + (((Ue = $e.textContent) == null ? void 0 : Ue.length) ?? 0);
|
|
99576
|
+
t.commands.setTextSelection({ from: Ke, to: ut }), ge(Ve.id || "");
|
|
99567
99577
|
}
|
|
99568
99578
|
}
|
|
99569
|
-
}, [Se, xe, t, ge]), ve =
|
|
99579
|
+
}, [Se, xe, t, ge]), ve = We(() => {
|
|
99570
99580
|
var Ae, Ue;
|
|
99571
99581
|
if ((Ae = t.view) != null && Ae.dom && Se < xe.length - 1) {
|
|
99572
|
-
const
|
|
99573
|
-
`[data-comment-id="${
|
|
99582
|
+
const Ve = xe[Se + 1], $e = t.view.dom.querySelector(
|
|
99583
|
+
`[data-comment-id="${Ve.id}"]`
|
|
99574
99584
|
);
|
|
99575
|
-
if (
|
|
99576
|
-
const Ke = t.view.posAtDOM(
|
|
99577
|
-
t.commands.setTextSelection({ from: Ke, to:
|
|
99585
|
+
if ($e) {
|
|
99586
|
+
const Ke = t.view.posAtDOM($e, 0), ut = Ke + (((Ue = $e.textContent) == null ? void 0 : Ue.length) ?? 0);
|
|
99587
|
+
t.commands.setTextSelection({ from: Ke, to: ut }), ge(Ve.id || "");
|
|
99578
99588
|
}
|
|
99579
99589
|
}
|
|
99580
99590
|
}, [Se, xe, t, ge]), Be = jt(
|
|
@@ -103013,20 +103023,20 @@ function t3e() {
|
|
|
103013
103023
|
const we = mn({}, ["audio", "video", "img", "source", "image", "track"]);
|
|
103014
103024
|
let xe = null;
|
|
103015
103025
|
const Se = mn({}, ["alt", "class", "for", "id", "label", "name", "pattern", "placeholder", "role", "summary", "title", "value", "style", "xmlns"]), Le = "http://www.w3.org/1998/Math/MathML", ve = "http://www.w3.org/2000/svg", Be = "http://www.w3.org/1999/xhtml";
|
|
103016
|
-
let Ae = Be, Ue = !1,
|
|
103017
|
-
const
|
|
103018
|
-
let Ke = mn({}, ["mi", "mo", "mn", "ms", "mtext"]),
|
|
103026
|
+
let Ae = Be, Ue = !1, Ve = null;
|
|
103027
|
+
const $e = mn({}, [Le, ve, Be], _E);
|
|
103028
|
+
let Ke = mn({}, ["mi", "mo", "mn", "ms", "mtext"]), ut = mn({}, ["annotation-xml"]);
|
|
103019
103029
|
const Oe = mn({}, ["title", "style", "font", "a", "script"]);
|
|
103020
103030
|
let ze = null;
|
|
103021
103031
|
const Ge = ["application/xhtml+xml", "text/html"], at = "text/html";
|
|
103022
|
-
let st = null,
|
|
103032
|
+
let st = null, ht = null;
|
|
103023
103033
|
const Mt = n.createElement("form"), At = function(Ce) {
|
|
103024
103034
|
return Ce instanceof RegExp || Ce instanceof Function;
|
|
103025
103035
|
}, Lt = function() {
|
|
103026
103036
|
let Ce = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
|
|
103027
|
-
if (!(
|
|
103037
|
+
if (!(ht && ht === Ce)) {
|
|
103028
103038
|
if ((!Ce || typeof Ce != "object") && (Ce = {}), Ce = Ec(Ce), ze = // eslint-disable-next-line unicorn/prefer-includes
|
|
103029
|
-
Ge.indexOf(Ce.PARSER_MEDIA_TYPE) === -1 ? at : Ce.PARSER_MEDIA_TYPE, st = ze === "application/xhtml+xml" ? _E : f8, q = el(Ce, "ALLOWED_TAGS") ? mn({}, Ce.ALLOWED_TAGS, st) : z, Y = el(Ce, "ALLOWED_ATTR") ? mn({}, Ce.ALLOWED_ATTR, st) : oe,
|
|
103039
|
+
Ge.indexOf(Ce.PARSER_MEDIA_TYPE) === -1 ? at : Ce.PARSER_MEDIA_TYPE, st = ze === "application/xhtml+xml" ? _E : f8, q = el(Ce, "ALLOWED_TAGS") ? mn({}, Ce.ALLOWED_TAGS, st) : z, Y = el(Ce, "ALLOWED_ATTR") ? mn({}, Ce.ALLOWED_ATTR, st) : oe, Ve = el(Ce, "ALLOWED_NAMESPACES") ? mn({}, Ce.ALLOWED_NAMESPACES, _E) : $e, xe = el(Ce, "ADD_URI_SAFE_ATTR") ? mn(Ec(Se), Ce.ADD_URI_SAFE_ATTR, st) : Se, ye = el(Ce, "ADD_DATA_URI_TAGS") ? mn(Ec(we), Ce.ADD_DATA_URI_TAGS, st) : we, Z = el(Ce, "FORBID_CONTENTS") ? mn({}, Ce.FORBID_CONTENTS, st) : se, K = el(Ce, "FORBID_TAGS") ? mn({}, Ce.FORBID_TAGS, st) : Ec({}), ne = el(Ce, "FORBID_ATTR") ? mn({}, Ce.FORBID_ATTR, st) : Ec({}), H = el(Ce, "USE_PROFILES") ? Ce.USE_PROFILES : !1, ue = Ce.ALLOW_ARIA_ATTR !== !1, P = Ce.ALLOW_DATA_ATTR !== !1, J = Ce.ALLOW_UNKNOWN_PROTOCOLS || !1, re = Ce.ALLOW_SELF_CLOSE_IN_ATTR !== !1, fe = Ce.SAFE_FOR_TEMPLATES || !1, R = Ce.SAFE_FOR_XML !== !1, le = Ce.WHOLE_DOCUMENT || !1, X = Ce.RETURN_DOM || !1, de = Ce.RETURN_DOM_FRAGMENT || !1, Fe = Ce.RETURN_TRUSTED_TYPE || !1, ee = Ce.FORCE_BODY || !1, Me = Ce.SANITIZE_DOM !== !1, ge = Ce.SANITIZE_NAMED_PROPS || !1, me = Ce.KEEP_CONTENT !== !1, be = Ce.IN_PLACE || !1, $ = Ce.ALLOWED_URI_REGEXP || Qme, Ae = Ce.NAMESPACE || Be, Ke = Ce.MATHML_TEXT_INTEGRATION_POINTS || Ke, ut = Ce.HTML_INTEGRATION_POINTS || ut, te = Ce.CUSTOM_ELEMENT_HANDLING || {}, Ce.CUSTOM_ELEMENT_HANDLING && At(Ce.CUSTOM_ELEMENT_HANDLING.tagNameCheck) && (te.tagNameCheck = Ce.CUSTOM_ELEMENT_HANDLING.tagNameCheck), Ce.CUSTOM_ELEMENT_HANDLING && At(Ce.CUSTOM_ELEMENT_HANDLING.attributeNameCheck) && (te.attributeNameCheck = Ce.CUSTOM_ELEMENT_HANDLING.attributeNameCheck), Ce.CUSTOM_ELEMENT_HANDLING && typeof Ce.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements == "boolean" && (te.allowCustomizedBuiltInElements = Ce.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements), fe && (P = !1), de && (X = !0), H && (q = mn({}, MY), Y = [], H.html === !0 && (mn(q, DY), mn(Y, EY)), H.svg === !0 && (mn(q, BE), mn(Y, PE), mn(Y, Tv)), H.svgFilters === !0 && (mn(q, OE), mn(Y, PE), mn(Y, Tv)), H.mathMl === !0 && (mn(q, RE), mn(Y, AY), mn(Y, Tv))), Ce.ADD_TAGS && (typeof Ce.ADD_TAGS == "function" ? ae.tagCheck = Ce.ADD_TAGS : (q === z && (q = Ec(q)), mn(q, Ce.ADD_TAGS, st))), Ce.ADD_ATTR && (typeof Ce.ADD_ATTR == "function" ? ae.attributeCheck = Ce.ADD_ATTR : (Y === oe && (Y = Ec(Y)), mn(Y, Ce.ADD_ATTR, st))), Ce.ADD_URI_SAFE_ATTR && mn(xe, Ce.ADD_URI_SAFE_ATTR, st), Ce.FORBID_CONTENTS && (Z === se && (Z = Ec(Z)), mn(Z, Ce.FORBID_CONTENTS, st)), me && (q["#text"] = !0), le && mn(q, ["html", "head", "body"]), q.table && (mn(q, ["tbody"]), delete K.tbody), Ce.TRUSTED_TYPES_POLICY) {
|
|
103030
103040
|
if (typeof Ce.TRUSTED_TYPES_POLICY.createHTML != "function")
|
|
103031
103041
|
throw d3('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');
|
|
103032
103042
|
if (typeof Ce.TRUSTED_TYPES_POLICY.createScriptURL != "function")
|
|
@@ -103034,7 +103044,7 @@ function t3e() {
|
|
|
103034
103044
|
x = Ce.TRUSTED_TYPES_POLICY, k = x.createHTML("");
|
|
103035
103045
|
} else
|
|
103036
103046
|
x === void 0 && (x = lnn(h, o)), x !== null && typeof k == "string" && (k = x.createHTML(""));
|
|
103037
|
-
Ii && Ii(Ce),
|
|
103047
|
+
Ii && Ii(Ce), ht = Ce;
|
|
103038
103048
|
}
|
|
103039
103049
|
}, Nt = mn({}, [...BE, ...OE, ...Xtn]), ln = mn({}, [...RE, ...Jtn]), Tn = function(Ce) {
|
|
103040
103050
|
let Ne = v(Ce);
|
|
@@ -103042,8 +103052,8 @@ function t3e() {
|
|
|
103042
103052
|
namespaceURI: Ae,
|
|
103043
103053
|
tagName: "template"
|
|
103044
103054
|
});
|
|
103045
|
-
const
|
|
103046
|
-
return
|
|
103055
|
+
const pt = f8(Ce.tagName), Yt = f8(Ne.tagName);
|
|
103056
|
+
return Ve[Ce.namespaceURI] ? Ce.namespaceURI === ve ? Ne.namespaceURI === Be ? pt === "svg" : Ne.namespaceURI === Le ? pt === "svg" && (Yt === "annotation-xml" || Ke[Yt]) : !!Nt[pt] : Ce.namespaceURI === Le ? Ne.namespaceURI === Be ? pt === "math" : Ne.namespaceURI === ve ? pt === "math" && ut[Yt] : !!ln[pt] : Ce.namespaceURI === Be ? Ne.namespaceURI === ve && !ut[Yt] || Ne.namespaceURI === Le && !Ke[Yt] ? !1 : !ln[pt] && (Oe[pt] || !Nt[pt]) : !!(ze === "application/xhtml+xml" && Ve[Ce.namespaceURI]) : !1;
|
|
103047
103057
|
}, Dn = function(Ce) {
|
|
103048
103058
|
u3(t.removed, {
|
|
103049
103059
|
element: Ce
|
|
@@ -103077,12 +103087,12 @@ function t3e() {
|
|
|
103077
103087
|
} catch {
|
|
103078
103088
|
}
|
|
103079
103089
|
}, dr = function(Ce) {
|
|
103080
|
-
let Ne = null,
|
|
103090
|
+
let Ne = null, pt = null;
|
|
103081
103091
|
if (ee)
|
|
103082
103092
|
Ce = "<remove></remove>" + Ce;
|
|
103083
103093
|
else {
|
|
103084
103094
|
const Un = IE(Ce, /^[\r\n\t ]+/);
|
|
103085
|
-
|
|
103095
|
+
pt = Un && Un[0];
|
|
103086
103096
|
}
|
|
103087
103097
|
ze === "application/xhtml+xml" && Ae === Be && (Ce = '<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>' + Ce + "</body></html>");
|
|
103088
103098
|
const Yt = x ? x.createHTML(Ce) : Ce;
|
|
@@ -103099,7 +103109,7 @@ function t3e() {
|
|
|
103099
103109
|
}
|
|
103100
103110
|
}
|
|
103101
103111
|
const Ut = Ne.body || Ne.documentElement;
|
|
103102
|
-
return Ce &&
|
|
103112
|
+
return Ce && pt && Ut.insertBefore(n.createTextNode(pt), Ut.childNodes[0] || null), Ae === Be ? T.call(Ne, le ? "html" : "body")[0] : le ? Ne.documentElement : Ut;
|
|
103103
103113
|
}, Q = function(Ce) {
|
|
103104
103114
|
return C.call(
|
|
103105
103115
|
Ce.ownerDocument || Ce,
|
|
@@ -103114,24 +103124,24 @@ function t3e() {
|
|
|
103114
103124
|
return typeof s == "function" && Ce instanceof s;
|
|
103115
103125
|
};
|
|
103116
103126
|
function Ye(et, Ce, Ne) {
|
|
103117
|
-
Sv(et, (
|
|
103118
|
-
|
|
103127
|
+
Sv(et, (pt) => {
|
|
103128
|
+
pt.call(t, Ce, Ne, ht);
|
|
103119
103129
|
});
|
|
103120
103130
|
}
|
|
103121
103131
|
const bt = function(Ce) {
|
|
103122
103132
|
let Ne = null;
|
|
103123
103133
|
if (Ye(I.beforeSanitizeElements, Ce, null), Ee(Ce))
|
|
103124
103134
|
return Dn(Ce), !0;
|
|
103125
|
-
const
|
|
103135
|
+
const pt = st(Ce.nodeName);
|
|
103126
103136
|
if (Ye(I.uponSanitizeElement, Ce, {
|
|
103127
|
-
tagName:
|
|
103137
|
+
tagName: pt,
|
|
103128
103138
|
allowedTags: q
|
|
103129
103139
|
}), R && Ce.hasChildNodes() && !Pe(Ce.firstElementChild) && bi(/<[/\w!]/g, Ce.innerHTML) && bi(/<[/\w!]/g, Ce.textContent) || Ce.nodeType === h3.progressingInstruction || R && Ce.nodeType === h3.comment && bi(/<[/\w]/g, Ce.data))
|
|
103130
103140
|
return Dn(Ce), !0;
|
|
103131
|
-
if (!(ae.tagCheck instanceof Function && ae.tagCheck(
|
|
103132
|
-
if (!K[
|
|
103141
|
+
if (!(ae.tagCheck instanceof Function && ae.tagCheck(pt)) && (!q[pt] || K[pt])) {
|
|
103142
|
+
if (!K[pt] && yt(pt) && (te.tagNameCheck instanceof RegExp && bi(te.tagNameCheck, pt) || te.tagNameCheck instanceof Function && te.tagNameCheck(pt)))
|
|
103133
103143
|
return !1;
|
|
103134
|
-
if (me && !Z[
|
|
103144
|
+
if (me && !Z[pt]) {
|
|
103135
103145
|
const Yt = v(Ce) || Ce.parentNode, Ut = b(Ce) || Ce.childNodes;
|
|
103136
103146
|
if (Ut && Yt) {
|
|
103137
103147
|
const Un = Ut.length;
|
|
@@ -103143,13 +103153,13 @@ function t3e() {
|
|
|
103143
103153
|
}
|
|
103144
103154
|
return Dn(Ce), !0;
|
|
103145
103155
|
}
|
|
103146
|
-
return Ce instanceof l && !Tn(Ce) || (
|
|
103156
|
+
return Ce instanceof l && !Tn(Ce) || (pt === "noscript" || pt === "noembed" || pt === "noframes") && bi(/<\/no(script|embed|frames)/i, Ce.innerHTML) ? (Dn(Ce), !0) : (fe && Ce.nodeType === h3.text && (Ne = Ce.textContent, Sv([S, L, M], (Yt) => {
|
|
103147
103157
|
Ne = c3(Ne, Yt, " ");
|
|
103148
103158
|
}), Ce.textContent !== Ne && (u3(t.removed, {
|
|
103149
103159
|
element: Ce.cloneNode()
|
|
103150
103160
|
}), Ce.textContent = Ne)), Ye(I.afterSanitizeElements, Ce, null), !1);
|
|
103151
|
-
}, Dt = function(Ce, Ne,
|
|
103152
|
-
if (Me && (Ne === "id" || Ne === "name") && (
|
|
103161
|
+
}, Dt = function(Ce, Ne, pt) {
|
|
103162
|
+
if (Me && (Ne === "id" || Ne === "name") && (pt in n || pt in Mt))
|
|
103153
103163
|
return !1;
|
|
103154
103164
|
if (!(P && !ne[Ne] && bi(j, Ne))) {
|
|
103155
103165
|
if (!(ue && bi(N, Ne))) {
|
|
@@ -103161,13 +103171,13 @@ function t3e() {
|
|
|
103161
103171
|
// and c) if the attribute name passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.attributeNameCheck
|
|
103162
103172
|
!(yt(Ce) && (te.tagNameCheck instanceof RegExp && bi(te.tagNameCheck, Ce) || te.tagNameCheck instanceof Function && te.tagNameCheck(Ce)) && (te.attributeNameCheck instanceof RegExp && bi(te.attributeNameCheck, Ne) || te.attributeNameCheck instanceof Function && te.attributeNameCheck(Ne, Ce)) || // Alternative, second condition checks if it's an `is`-attribute, AND
|
|
103163
103173
|
// the value passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.tagNameCheck
|
|
103164
|
-
Ne === "is" && te.allowCustomizedBuiltInElements && (te.tagNameCheck instanceof RegExp && bi(te.tagNameCheck,
|
|
103174
|
+
Ne === "is" && te.allowCustomizedBuiltInElements && (te.tagNameCheck instanceof RegExp && bi(te.tagNameCheck, pt) || te.tagNameCheck instanceof Function && te.tagNameCheck(pt)))
|
|
103165
103175
|
) return !1;
|
|
103166
103176
|
} else if (!xe[Ne]) {
|
|
103167
|
-
if (!bi($, c3(
|
|
103168
|
-
if (!((Ne === "src" || Ne === "xlink:href" || Ne === "href") && Ce !== "script" && Gtn(
|
|
103169
|
-
if (!(J && !bi(O, c3(
|
|
103170
|
-
if (
|
|
103177
|
+
if (!bi($, c3(pt, B, ""))) {
|
|
103178
|
+
if (!((Ne === "src" || Ne === "xlink:href" || Ne === "href") && Ce !== "script" && Gtn(pt, "data:") === 0 && ye[Ce])) {
|
|
103179
|
+
if (!(J && !bi(O, c3(pt, B, "")))) {
|
|
103180
|
+
if (pt)
|
|
103171
103181
|
return !1;
|
|
103172
103182
|
}
|
|
103173
103183
|
}
|
|
@@ -103186,7 +103196,7 @@ function t3e() {
|
|
|
103186
103196
|
} = Ce;
|
|
103187
103197
|
if (!Ne || Ee(Ce))
|
|
103188
103198
|
return;
|
|
103189
|
-
const
|
|
103199
|
+
const pt = {
|
|
103190
103200
|
attrName: "",
|
|
103191
103201
|
attrValue: "",
|
|
103192
103202
|
keepAttr: !0,
|
|
@@ -103201,7 +103211,7 @@ function t3e() {
|
|
|
103201
103211
|
value: yi
|
|
103202
103212
|
} = Ut, q1 = st(Un), Vm = yi;
|
|
103203
103213
|
let uo = Un === "value" ? Vm : Ztn(Vm);
|
|
103204
|
-
if (
|
|
103214
|
+
if (pt.attrName = q1, pt.attrValue = uo, pt.keepAttr = !0, pt.forceKeepAttr = void 0, Ye(I.uponSanitizeAttribute, Ce, pt), uo = pt.attrValue, ge && (q1 === "id" || q1 === "name") && (zn(Un, Ce), uo = pe + uo), R && bi(/((--!?|])>)|<\/(style|title|textarea)/i, uo)) {
|
|
103205
103215
|
zn(Un, Ce);
|
|
103206
103216
|
continue;
|
|
103207
103217
|
}
|
|
@@ -103209,9 +103219,9 @@ function t3e() {
|
|
|
103209
103219
|
zn(Un, Ce);
|
|
103210
103220
|
continue;
|
|
103211
103221
|
}
|
|
103212
|
-
if (
|
|
103222
|
+
if (pt.forceKeepAttr)
|
|
103213
103223
|
continue;
|
|
103214
|
-
if (!
|
|
103224
|
+
if (!pt.keepAttr) {
|
|
103215
103225
|
zn(Un, Ce);
|
|
103216
103226
|
continue;
|
|
103217
103227
|
}
|
|
@@ -103248,13 +103258,13 @@ function t3e() {
|
|
|
103248
103258
|
Ye(I.afterSanitizeAttributes, Ce, null);
|
|
103249
103259
|
}, bn = function et(Ce) {
|
|
103250
103260
|
let Ne = null;
|
|
103251
|
-
const
|
|
103252
|
-
for (Ye(I.beforeSanitizeShadowDOM, Ce, null); Ne =
|
|
103261
|
+
const pt = Q(Ce);
|
|
103262
|
+
for (Ye(I.beforeSanitizeShadowDOM, Ce, null); Ne = pt.nextNode(); )
|
|
103253
103263
|
Ye(I.uponSanitizeShadowNode, Ne, null), bt(Ne), gt(Ne), Ne.content instanceof i && et(Ne.content);
|
|
103254
103264
|
Ye(I.afterSanitizeShadowDOM, Ce, null);
|
|
103255
103265
|
};
|
|
103256
103266
|
return t.sanitize = function(et) {
|
|
103257
|
-
let Ce = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, Ne = null,
|
|
103267
|
+
let Ce = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, Ne = null, pt = null, Yt = null, Ut = null;
|
|
103258
103268
|
if (Ue = !et, Ue && (et = "<!-->"), typeof et != "string" && !Pe(et))
|
|
103259
103269
|
if (typeof et.toString == "function") {
|
|
103260
103270
|
if (et = et.toString(), typeof et != "string")
|
|
@@ -103270,7 +103280,7 @@ function t3e() {
|
|
|
103270
103280
|
throw d3("root node is forbidden and cannot be sanitized in-place");
|
|
103271
103281
|
}
|
|
103272
103282
|
} else if (et instanceof s)
|
|
103273
|
-
Ne = dr("<!---->"),
|
|
103283
|
+
Ne = dr("<!---->"), pt = Ne.ownerDocument.importNode(et, !0), pt.nodeType === h3.element && pt.nodeName === "BODY" || pt.nodeName === "HTML" ? Ne = pt : Ne.appendChild(pt);
|
|
103274
103284
|
else {
|
|
103275
103285
|
if (!X && !fe && !le && // eslint-disable-next-line unicorn/prefer-includes
|
|
103276
103286
|
et.indexOf("<") === -1)
|
|
@@ -103301,11 +103311,11 @@ function t3e() {
|
|
|
103301
103311
|
let et = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
|
|
103302
103312
|
Lt(et), ce = !0;
|
|
103303
103313
|
}, t.clearConfig = function() {
|
|
103304
|
-
|
|
103314
|
+
ht = null, ce = !1;
|
|
103305
103315
|
}, t.isValidAttribute = function(et, Ce, Ne) {
|
|
103306
|
-
|
|
103307
|
-
const
|
|
103308
|
-
return Dt(
|
|
103316
|
+
ht || Lt({});
|
|
103317
|
+
const pt = st(et), Yt = st(Ce);
|
|
103318
|
+
return Dt(pt, Yt, Ne);
|
|
103309
103319
|
}, t.addHook = function(et, Ce) {
|
|
103310
103320
|
typeof Ce == "function" && u3(I[et], Ce);
|
|
103311
103321
|
}, t.removeHook = function(et, Ce) {
|
|
@@ -107833,7 +107843,7 @@ const $E = (e) => {
|
|
|
107833
107843
|
setIsLinkPopupOpen: o,
|
|
107834
107844
|
onError: i
|
|
107835
107845
|
}) => {
|
|
107836
|
-
const [a, s] = Re(t.getAttributes("link").href), l =
|
|
107846
|
+
const [a, s] = Re(t.getAttributes("link").href), l = We(() => {
|
|
107837
107847
|
if (a === "" || a === void 0) {
|
|
107838
107848
|
t.chain().focus().extendMarkRange("link").unsetLink().run();
|
|
107839
107849
|
return;
|
|
@@ -109023,7 +109033,7 @@ const $E = (e) => {
|
|
|
109023
109033
|
const N = m.current.closest('[role="dialog"]');
|
|
109024
109034
|
N && N.remove();
|
|
109025
109035
|
}
|
|
109026
|
-
}, M =
|
|
109036
|
+
}, M = We(() => {
|
|
109027
109037
|
if (!(o != null && o.length)) return null;
|
|
109028
109038
|
let j = o.sort(
|
|
109029
109039
|
(N, O) => new Date(N.createdAt || /* @__PURE__ */ new Date()).getTime() - new Date(O.createdAt || /* @__PURE__ */ new Date()).getTime()
|
|
@@ -109870,12 +109880,12 @@ const rin = /* @__PURE__ */ y0(nin), y3 = () => {
|
|
|
109870
109880
|
});
|
|
109871
109881
|
}), !h;
|
|
109872
109882
|
}, P3e = (e) => {
|
|
109873
|
-
const t =
|
|
109883
|
+
const t = We(
|
|
109874
109884
|
(o) => {
|
|
109875
109885
|
e && e.chain().focus().setFontSize(o).run();
|
|
109876
109886
|
},
|
|
109877
109887
|
[e]
|
|
109878
|
-
), n =
|
|
109888
|
+
), n = We(
|
|
109879
109889
|
(o) => {
|
|
109880
109890
|
if (!e) return;
|
|
109881
109891
|
const { from: i, to: a } = e.state.selection;
|
|
@@ -110715,8 +110725,8 @@ class Z9 extends Vt {
|
|
|
110715
110725
|
constructor(n) {
|
|
110716
110726
|
const { $from: r, $to: o } = n;
|
|
110717
110727
|
super(r, o);
|
|
110718
|
-
|
|
110719
|
-
|
|
110728
|
+
ct(this, "_$from");
|
|
110729
|
+
ct(this, "_$to");
|
|
110720
110730
|
this._$from = r, this._$to = o;
|
|
110721
110731
|
}
|
|
110722
110732
|
get $from() {
|
|
@@ -110906,16 +110916,16 @@ pin.displayName = "Toolbar.Divider";
|
|
|
110906
110916
|
const gin = {
|
|
110907
110917
|
Wrapper: W3e
|
|
110908
110918
|
}, min = ({ editor: e, appendTo: t }) => {
|
|
110909
|
-
const n =
|
|
110919
|
+
const n = We(() => hin(e, "columns"), [e]), r = We(() => {
|
|
110910
110920
|
const l = !e.isEditable;
|
|
110911
110921
|
return e.isActive("columns") && !l;
|
|
110912
|
-
}, [e]), o =
|
|
110922
|
+
}, [e]), o = We(() => {
|
|
110913
110923
|
e.chain().focus().setLayout(of.AlignLeft).run();
|
|
110914
|
-
}, [e]), i =
|
|
110924
|
+
}, [e]), i = We(() => {
|
|
110915
110925
|
e.chain().focus().setLayout(of.AlignRight).run();
|
|
110916
|
-
}, [e]), a =
|
|
110926
|
+
}, [e]), a = We(() => {
|
|
110917
110927
|
e.chain().focus().setLayout(of.AlignCenter).run();
|
|
110918
|
-
}, [e]), s =
|
|
110928
|
+
}, [e]), s = We(() => {
|
|
110919
110929
|
e.chain().focus().deleteNode("columns").run();
|
|
110920
110930
|
}, [e]);
|
|
110921
110931
|
return /* @__PURE__ */ E.jsx(
|
|
@@ -111065,7 +111075,7 @@ function bin({ children: e, isPresent: t }) {
|
|
|
111065
111075
|
}, [t]), E.jsx(yin, { isPresent: t, childRef: r, sizeRef: o, children: W.cloneElement(e, { ref: r }) });
|
|
111066
111076
|
}
|
|
111067
111077
|
const vin = ({ children: e, initial: t, isPresent: n, onExitComplete: r, custom: o, presenceAffectsLayout: i, mode: a }) => {
|
|
111068
|
-
const s = JP(xin), l = Wg(), u =
|
|
111078
|
+
const s = JP(xin), l = Wg(), u = We((d) => {
|
|
111069
111079
|
s.set(d, !0);
|
|
111070
111080
|
for (const f of s.values())
|
|
111071
111081
|
if (!f)
|
|
@@ -111104,7 +111114,7 @@ function G3e(e = !0) {
|
|
|
111104
111114
|
He(() => {
|
|
111105
111115
|
e && o(i);
|
|
111106
111116
|
}, [e]);
|
|
111107
|
-
const a =
|
|
111117
|
+
const a = We(() => e && r && r(i), [i, r, e]);
|
|
111108
111118
|
return !n && r ? [!1, a] : [!0];
|
|
111109
111119
|
}
|
|
111110
111120
|
const Nv = (e) => e.key || "";
|
|
@@ -111381,7 +111391,7 @@ function i2(e) {
|
|
|
111381
111391
|
return e && typeof e == "object" && Object.prototype.hasOwnProperty.call(e, "current");
|
|
111382
111392
|
}
|
|
111383
111393
|
function Lin(e, t, n) {
|
|
111384
|
-
return
|
|
111394
|
+
return We(
|
|
111385
111395
|
(r) => {
|
|
111386
111396
|
r && e.onMount && e.onMount(r), t && (r ? t.mount(r) : t.unmount()), n && (typeof n == "function" ? n(r) : i2(n) && (n.current = r));
|
|
111387
111397
|
},
|
|
@@ -116242,7 +116252,7 @@ const Uun = (e, t) => az(e) ? new zun(t) : new Pun(t, {
|
|
|
116242
116252
|
/* @__PURE__ */ E.jsx(
|
|
116243
116253
|
"span",
|
|
116244
116254
|
{
|
|
116245
|
-
className: "text-body-sm line-clamp-1",
|
|
116255
|
+
className: "text-body-sm line-clamp-1 break-all",
|
|
116246
116256
|
style: {
|
|
116247
116257
|
fontFamily: Y == null ? void 0 : Y.value
|
|
116248
116258
|
},
|
|
@@ -116285,10 +116295,15 @@ const Uun = (e, t) => az(e) ? new zun(t) : new Pun(t, {
|
|
|
116285
116295
|
anchorTrigger: /* @__PURE__ */ E.jsxs(
|
|
116286
116296
|
"button",
|
|
116287
116297
|
{
|
|
116288
|
-
className: "bg-transparent hover:!color-bg-default-hover rounded gap-2 p-2 flex items-center justify-
|
|
116298
|
+
className: "bg-transparent hover:!color-bg-default-hover rounded gap-2 p-2 flex items-center justify-between w-[108px]",
|
|
116289
116299
|
onClick: () => y(lt.HEADING),
|
|
116290
116300
|
children: [
|
|
116291
|
-
/* @__PURE__ */ E.
|
|
116301
|
+
/* @__PURE__ */ E.jsxs("span", { className: "text-body-sm line-clamp-1", children: [
|
|
116302
|
+
(e == null ? void 0 : e.isActive("heading", { level: 1 })) && "Heading 1",
|
|
116303
|
+
(e == null ? void 0 : e.isActive("heading", { level: 2 })) && "Heading 2",
|
|
116304
|
+
(e == null ? void 0 : e.isActive("heading", { level: 3 })) && "Heading 3",
|
|
116305
|
+
!(e != null && e.isActive("heading")) && "Text"
|
|
116306
|
+
] }),
|
|
116292
116307
|
/* @__PURE__ */ E.jsx(qe, { name: "ChevronDown", size: "sm" })
|
|
116293
116308
|
]
|
|
116294
116309
|
}
|
|
@@ -122963,7 +122978,7 @@ class n0n {
|
|
|
122963
122978
|
).filter((r) => r !== null), n = this._tr.replace(
|
|
122964
122979
|
0,
|
|
122965
122980
|
this.prosemirrorView.state.doc.content.size,
|
|
122966
|
-
new
|
|
122981
|
+
new ft(Ze.from(t), 0, 0)
|
|
122967
122982
|
);
|
|
122968
122983
|
n.setMeta(jr, { snapshot: null, prevSnapshot: null }), this.prosemirrorView.dispatch(n);
|
|
122969
122984
|
});
|
|
@@ -122980,7 +122995,7 @@ class n0n {
|
|
|
122980
122995
|
).filter((o) => o !== null), r = this._tr.replace(
|
|
122981
122996
|
0,
|
|
122982
122997
|
this.prosemirrorView.state.doc.content.size,
|
|
122983
|
-
new
|
|
122998
|
+
new ft(Ze.from(n), 0, 0)
|
|
122984
122999
|
);
|
|
122985
123000
|
if (t) {
|
|
122986
123001
|
const o = Yc(jl(t.anchor, 0), r.doc.content.size), i = Yc(jl(t.head, 0), r.doc.content.size);
|
|
@@ -123045,7 +123060,7 @@ class n0n {
|
|
|
123045
123060
|
) : null).filter((d) => d !== null), c = this._tr.replace(
|
|
123046
123061
|
0,
|
|
123047
123062
|
this.prosemirrorView.state.doc.content.size,
|
|
123048
|
-
new
|
|
123063
|
+
new ft(Ze.from(u), 0, 0)
|
|
123049
123064
|
);
|
|
123050
123065
|
this.prosemirrorView.dispatch(
|
|
123051
123066
|
c.setMeta(jr, { isChangeOrigin: !0 })
|
|
@@ -123091,7 +123106,7 @@ class n0n {
|
|
|
123091
123106
|
let a = this._tr.replace(
|
|
123092
123107
|
0,
|
|
123093
123108
|
this.prosemirrorView.state.doc.content.size,
|
|
123094
|
-
new
|
|
123109
|
+
new ft(Ze.from(i), 0, 0)
|
|
123095
123110
|
);
|
|
123096
123111
|
e0n(a, this.beforeTransactionSelection, this), a = a.setMeta(jr, { isChangeOrigin: !0, isUndoRedoOperation: n.origin instanceof Q4e }), this.beforeTransactionSelection !== null && this._isLocalCursorInView() && a.scrollIntoView(), this.prosemirrorView.dispatch(a);
|
|
123097
123112
|
});
|
|
@@ -126453,7 +126468,7 @@ class zr extends Vt {
|
|
|
126453
126468
|
return zr.valid(r) ? new zr(r) : Vt.near(r);
|
|
126454
126469
|
}
|
|
126455
126470
|
content() {
|
|
126456
|
-
return
|
|
126471
|
+
return ft.empty;
|
|
126457
126472
|
}
|
|
126458
126473
|
eq(t) {
|
|
126459
126474
|
return t instanceof zr && t.head == this.head;
|
|
@@ -126628,7 +126643,7 @@ function Ufn(e, t) {
|
|
|
126628
126643
|
let o = Ze.empty;
|
|
126629
126644
|
for (let a = r.length - 1; a >= 0; a--)
|
|
126630
126645
|
o = Ze.from(r[a].createAndFill(null, o));
|
|
126631
|
-
let i = e.state.tr.replace(n.pos, n.pos, new
|
|
126646
|
+
let i = e.state.tr.replace(n.pos, n.pos, new ft(o, 0, 0));
|
|
126632
126647
|
return i.setSelection(kt.near(i.doc.resolve(n.pos + 1))), e.dispatch(i), !1;
|
|
126633
126648
|
}
|
|
126634
126649
|
function Hfn(e) {
|
|
@@ -129740,7 +129755,7 @@ const zA = _e.use || // This extra generic is to avoid TypeScript mixing up the
|
|
|
129740
129755
|
}, [
|
|
129741
129756
|
r,
|
|
129742
129757
|
y
|
|
129743
|
-
]), B = u6.useSyncExternalStore(
|
|
129758
|
+
]), B = u6.useSyncExternalStore(We(
|
|
129744
129759
|
(fe) => S(y, (R, le) => {
|
|
129745
129760
|
N(le, R) || fe();
|
|
129746
129761
|
}),
|
|
@@ -129749,7 +129764,7 @@ const zA = _e.use || // This extra generic is to avoid TypeScript mixing up the
|
|
|
129749
129764
|
r,
|
|
129750
129765
|
y
|
|
129751
129766
|
]
|
|
129752
|
-
), O[0], O[1]), U = !v.current, $ = h[y] && h[y].length > 0, q = B.data, z = Mn(q) ? j && k6e(j) ? zA(j) : j : q, Y = B.error, oe = Qe(z), te = f ? Mn(q) ? Mn(oe.current) ? z : oe.current : q : z, K = $ && !Mn(Y) ? !1 : U && !Mn(s) ? s : D().isPaused() ? !1 : i ? Mn(z) ? !1 : l : Mn(z) || l, ne = !!(y && t && U && K), ae = Mn(B.isValidating) ? ne : B.isValidating, ue = Mn(B.isLoading) ? ne : B.isLoading, P =
|
|
129767
|
+
), O[0], O[1]), U = !v.current, $ = h[y] && h[y].length > 0, q = B.data, z = Mn(q) ? j && k6e(j) ? zA(j) : j : q, Y = B.error, oe = Qe(z), te = f ? Mn(q) ? Mn(oe.current) ? z : oe.current : q : z, K = $ && !Mn(Y) ? !1 : U && !Mn(s) ? s : D().isPaused() ? !1 : i ? Mn(z) ? !1 : l : Mn(z) || l, ne = !!(y && t && U && K), ae = Mn(B.isValidating) ? ne : B.isValidating, ue = Mn(B.isLoading) ? ne : B.isLoading, P = We(
|
|
129753
129768
|
async (fe) => {
|
|
129754
129769
|
const R = F.current;
|
|
129755
129770
|
if (!y || !R || x.current || D().isPaused())
|
|
@@ -129812,7 +129827,7 @@ const zA = _e.use || // This extra generic is to avoid TypeScript mixing up the
|
|
|
129812
129827
|
y,
|
|
129813
129828
|
r
|
|
129814
129829
|
]
|
|
129815
|
-
), J =
|
|
129830
|
+
), J = We(
|
|
129816
129831
|
// Use callback to make sure `keyRef.current` returns latest result every time
|
|
129817
129832
|
(...fe) => C6e(r, k.current, ...fe),
|
|
129818
129833
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
@@ -130041,7 +130056,7 @@ const mgn = ({
|
|
|
130041
130056
|
n.off("update", y), l.current && (cancelAnimationFrame(l.current), l.current = null);
|
|
130042
130057
|
};
|
|
130043
130058
|
}, [n]);
|
|
130044
|
-
const u =
|
|
130059
|
+
const u = We(() => {
|
|
130045
130060
|
const { doc: y } = n.state, b = y.content.content.filter(
|
|
130046
130061
|
(C) => {
|
|
130047
130062
|
var D, T, _;
|
|
@@ -130060,7 +130075,7 @@ const mgn = ({
|
|
|
130060
130075
|
headingCount: b
|
|
130061
130076
|
};
|
|
130062
130077
|
return o.current = F, i.current = v, bp = F, kQ = x, F;
|
|
130063
|
-
}, [n]), c =
|
|
130078
|
+
}, [n]), c = We((y) => {
|
|
130064
130079
|
var F;
|
|
130065
130080
|
const { doc: b } = y.state, v = /* @__PURE__ */ new Map(), x = [];
|
|
130066
130081
|
let k = 0;
|
|
@@ -130155,7 +130170,7 @@ const mgn = ({
|
|
|
130155
130170
|
u,
|
|
130156
130171
|
e.content,
|
|
130157
130172
|
a
|
|
130158
|
-
]), m =
|
|
130173
|
+
]), m = We(() => {
|
|
130159
130174
|
var C;
|
|
130160
130175
|
if (!h) return;
|
|
130161
130176
|
const y = t(), { headingMap: b } = u(), v = b.get(h);
|
|
@@ -130241,7 +130256,7 @@ const mgn = ({
|
|
|
130241
130256
|
}
|
|
130242
130257
|
};
|
|
130243
130258
|
function bgn(e) {
|
|
130244
|
-
const t = Qe(!1), n = Qe(e), r =
|
|
130259
|
+
const t = Qe(!1), n = Qe(e), r = We(() => {
|
|
130245
130260
|
if (!n.current) {
|
|
130246
130261
|
t.current = !1;
|
|
130247
130262
|
return;
|
|
@@ -130270,10 +130285,10 @@ function bgn(e) {
|
|
|
130270
130285
|
);
|
|
130271
130286
|
}
|
|
130272
130287
|
const vgn = (e, t, n) => {
|
|
130273
|
-
const r = bgn(e), o =
|
|
130288
|
+
const r = bgn(e), o = We(() => {
|
|
130274
130289
|
const l = e.chain();
|
|
130275
130290
|
l.setNodeSelection(n).unsetAllMarks(), (t == null ? void 0 : t.type.name) !== "paragraph" && l.setParagraph(), l.run();
|
|
130276
|
-
}, [e, n, t == null ? void 0 : t.type.name]), i =
|
|
130291
|
+
}, [e, n, t == null ? void 0 : t.type.name]), i = We(() => {
|
|
130277
130292
|
if (r)
|
|
130278
130293
|
return;
|
|
130279
130294
|
e.commands.setNodeSelection(n);
|
|
@@ -130282,12 +130297,12 @@ const vgn = (e, t, n) => {
|
|
|
130282
130297
|
n + ((t == null ? void 0 : t.nodeSize) || 0),
|
|
130283
130298
|
u.toJSON()
|
|
130284
130299
|
).run();
|
|
130285
|
-
}, [e, n, t == null ? void 0 : t.nodeSize]), a =
|
|
130300
|
+
}, [e, n, t == null ? void 0 : t.nodeSize]), a = We(() => {
|
|
130286
130301
|
e.chain().setMeta("hideDragHandle", !0).setNodeSelection(n).run(), document.execCommand("copy"), ld({
|
|
130287
130302
|
title: "Copied to clipboard",
|
|
130288
130303
|
variant: "success"
|
|
130289
130304
|
});
|
|
130290
|
-
}, [e, n]), s =
|
|
130305
|
+
}, [e, n]), s = We(() => {
|
|
130291
130306
|
ygn(e, n), e.chain().setMeta("hideDragHandle", !0).setNodeSelection(n).deleteSelection().run();
|
|
130292
130307
|
}, [e, n]);
|
|
130293
130308
|
return {
|
|
@@ -133619,7 +133634,7 @@ const Xgn = _e.memo(
|
|
|
133619
133634
|
node: e,
|
|
133620
133635
|
getPos: t,
|
|
133621
133636
|
editor: n
|
|
133622
|
-
}), C =
|
|
133637
|
+
}), C = We(() => {
|
|
133623
133638
|
const { content: P } = e.content, J = P[0].attrs.id, re = P[0].content.content[0].text, fe = bU(re), R = J.replace(/-/g, "").substring(0, 8), le = `heading=${fe}-${R}`;
|
|
133624
133639
|
i == null || i(le);
|
|
133625
133640
|
}, [e.content, i]), D = jt(() => {
|
|
@@ -133685,31 +133700,31 @@ const Xgn = _e.memo(
|
|
|
133685
133700
|
}, L = (P, J) => {
|
|
133686
133701
|
const re = t(), fe = re + e.nodeSize;
|
|
133687
133702
|
P === "img" ? n == null || n.chain().focus(re).deleteRange({ from: re === 0 ? re : re + 1, to: fe }).setMedia({ src: J, "media-type": "img" }).run() : P !== "secure-img" && (n == null || n.chain().focus(re).deleteRange({ from: re === 0 ? re : re + 1, to: fe }).setIframe({ src: J, width: 640, height: 360 }).run());
|
|
133688
|
-
}, M =
|
|
133703
|
+
}, M = We((P) => {
|
|
133689
133704
|
P.altKey ? N() : j();
|
|
133690
|
-
}, []), j =
|
|
133705
|
+
}, []), j = We(() => {
|
|
133691
133706
|
const P = t() + e.nodeSize;
|
|
133692
133707
|
n.commands.insertContentAt(P, {
|
|
133693
133708
|
type: "dBlock",
|
|
133694
133709
|
content: [{ type: "paragraph" }]
|
|
133695
133710
|
});
|
|
133696
|
-
}, [t, n, e.nodeSize]), N =
|
|
133711
|
+
}, [t, n, e.nodeSize]), N = We(() => {
|
|
133697
133712
|
const P = t();
|
|
133698
133713
|
n.commands.insertContentAt(P, {
|
|
133699
133714
|
type: "dBlock",
|
|
133700
133715
|
content: [{ type: "paragraph" }]
|
|
133701
133716
|
});
|
|
133702
|
-
}, [t, n]), O =
|
|
133717
|
+
}, [t, n]), O = We(
|
|
133703
133718
|
(P) => {
|
|
133704
133719
|
P.altKey ? r() : l((J) => !J);
|
|
133705
133720
|
},
|
|
133706
133721
|
[r]
|
|
133707
|
-
), B =
|
|
133722
|
+
), B = We(() => {
|
|
133708
133723
|
S();
|
|
133709
133724
|
}, [T, I]), U = jt(
|
|
133710
133725
|
() => yU(B, 1e3),
|
|
133711
133726
|
[B]
|
|
133712
|
-
), $ =
|
|
133727
|
+
), $ = We(
|
|
133713
133728
|
(P) => {
|
|
133714
133729
|
const J = t() + e.nodeSize;
|
|
133715
133730
|
n.commands.insertContentAt(J - 4, P);
|
|
@@ -133721,7 +133736,7 @@ const Xgn = _e.memo(
|
|
|
133721
133736
|
), z = jt(
|
|
133722
133737
|
() => Fgn($),
|
|
133723
133738
|
[$]
|
|
133724
|
-
), Y =
|
|
133739
|
+
), Y = We(() => {
|
|
133725
133740
|
c(!u), f(u ? 2 : z.length);
|
|
133726
133741
|
}, [u, z.length]), oe = jt(() => {
|
|
133727
133742
|
switch (F) {
|
|
@@ -134354,12 +134369,12 @@ function jQ(e, t, n, r, o, i) {
|
|
|
134354
134369
|
}
|
|
134355
134370
|
class Jgn {
|
|
134356
134371
|
constructor(t, n) {
|
|
134357
|
-
|
|
134358
|
-
|
|
134359
|
-
|
|
134360
|
-
|
|
134361
|
-
|
|
134362
|
-
|
|
134372
|
+
ct(this, "node");
|
|
134373
|
+
ct(this, "cellMinWidth");
|
|
134374
|
+
ct(this, "dom");
|
|
134375
|
+
ct(this, "table");
|
|
134376
|
+
ct(this, "colgroup");
|
|
134377
|
+
ct(this, "contentDOM");
|
|
134363
134378
|
this.node = t, this.cellMinWidth = n, this.dom = document.createElement("div"), this.dom.className = "tableWrapper", this.table = this.dom.appendChild(document.createElement("table")), this.colgroup = this.table.appendChild(document.createElement("colgroup")), jQ(t, this.colgroup, this.table, n), this.contentDOM = this.table.appendChild(document.createElement("tbody"));
|
|
134364
134379
|
}
|
|
134365
134380
|
update(t) {
|
|
@@ -135885,8 +135900,8 @@ function B3n(e, t) {
|
|
|
135885
135900
|
ve === void 0 && (ve = !1), F.style.pointerEvents = x.props.interactive && !ve ? "" : "none", F.style.zIndex = "" + x.props.zIndex;
|
|
135886
135901
|
}
|
|
135887
135902
|
function B(ve, Be, Ae) {
|
|
135888
|
-
if (Ae === void 0 && (Ae = !0), D.forEach(function(
|
|
135889
|
-
|
|
135903
|
+
if (Ae === void 0 && (Ae = !0), D.forEach(function(Ve) {
|
|
135904
|
+
Ve[ve] && Ve[ve].apply(Ve, Be);
|
|
135890
135905
|
}), Ae) {
|
|
135891
135906
|
var Ue;
|
|
135892
135907
|
(Ue = x.props)[ve].apply(Ue, Be);
|
|
@@ -135896,13 +135911,13 @@ function B3n(e, t) {
|
|
|
135896
135911
|
var ve = x.props.aria;
|
|
135897
135912
|
if (ve.content) {
|
|
135898
135913
|
var Be = "aria-" + ve.content, Ae = F.id, Ue = Up(x.props.triggerTarget || e);
|
|
135899
|
-
Ue.forEach(function(
|
|
135900
|
-
var
|
|
135914
|
+
Ue.forEach(function(Ve) {
|
|
135915
|
+
var $e = Ve.getAttribute(Be);
|
|
135901
135916
|
if (x.state.isVisible)
|
|
135902
|
-
|
|
135917
|
+
Ve.setAttribute(Be, $e ? $e + " " + Ae : Ae);
|
|
135903
135918
|
else {
|
|
135904
|
-
var Ke =
|
|
135905
|
-
Ke ?
|
|
135919
|
+
var Ke = $e && $e.replace(Ae, "").trim();
|
|
135920
|
+
Ke ? Ve.setAttribute(Be, Ke) : Ve.removeAttribute(Be);
|
|
135906
135921
|
}
|
|
135907
135922
|
});
|
|
135908
135923
|
}
|
|
@@ -135961,8 +135976,8 @@ function B3n(e, t) {
|
|
|
135961
135976
|
}
|
|
135962
135977
|
function ue(ve, Be) {
|
|
135963
135978
|
var Ae = j().box;
|
|
135964
|
-
function Ue(
|
|
135965
|
-
|
|
135979
|
+
function Ue(Ve) {
|
|
135980
|
+
Ve.target === Ae && ($A(Ae, "remove", Ue), Be());
|
|
135966
135981
|
}
|
|
135967
135982
|
if (ve === 0)
|
|
135968
135983
|
return Be();
|
|
@@ -135971,9 +135986,9 @@ function B3n(e, t) {
|
|
|
135971
135986
|
function P(ve, Be, Ae) {
|
|
135972
135987
|
Ae === void 0 && (Ae = !1);
|
|
135973
135988
|
var Ue = Up(x.props.triggerTarget || e);
|
|
135974
|
-
Ue.forEach(function(
|
|
135975
|
-
|
|
135976
|
-
node:
|
|
135989
|
+
Ue.forEach(function(Ve) {
|
|
135990
|
+
Ve.addEventListener(ve, Be, Ae), h.push({
|
|
135991
|
+
node: Ve,
|
|
135977
135992
|
eventType: ve,
|
|
135978
135993
|
handler: Be,
|
|
135979
135994
|
options: Ae
|
|
@@ -136002,27 +136017,27 @@ function B3n(e, t) {
|
|
|
136002
136017
|
}
|
|
136003
136018
|
function re() {
|
|
136004
136019
|
h.forEach(function(ve) {
|
|
136005
|
-
var Be = ve.node, Ae = ve.eventType, Ue = ve.handler,
|
|
136006
|
-
Be.removeEventListener(Ae, Ue,
|
|
136020
|
+
var Be = ve.node, Ae = ve.eventType, Ue = ve.handler, Ve = ve.options;
|
|
136021
|
+
Be.removeEventListener(Ae, Ue, Ve);
|
|
136007
136022
|
}), h = [];
|
|
136008
136023
|
}
|
|
136009
136024
|
function fe(ve) {
|
|
136010
136025
|
var Be, Ae = !1;
|
|
136011
136026
|
if (!(!x.state.isEnabled || ee(ve) || s)) {
|
|
136012
136027
|
var Ue = ((Be = c) == null ? void 0 : Be.type) === "focus";
|
|
136013
|
-
c = ve, g = ve.currentTarget, $(), !x.state.isVisible && y3n(ve) && Jv.forEach(function(
|
|
136014
|
-
return
|
|
136028
|
+
c = ve, g = ve.currentTarget, $(), !x.state.isVisible && y3n(ve) && Jv.forEach(function(Ve) {
|
|
136029
|
+
return Ve(ve);
|
|
136015
136030
|
}), ve.type === "click" && (x.props.trigger.indexOf("mouseenter") < 0 || a) && x.props.hideOnClick !== !1 && x.state.isVisible ? Ae = !0 : ge(ve), ve.type === "click" && (a = !Ae), Ae && !Ue && pe(ve);
|
|
136016
136031
|
}
|
|
136017
136032
|
}
|
|
136018
136033
|
function R(ve) {
|
|
136019
136034
|
var Be = ve.target, Ae = L().contains(Be) || F.contains(Be);
|
|
136020
136035
|
if (!(ve.type === "mousemove" && Ae)) {
|
|
136021
|
-
var Ue = Me().concat(F).map(function(
|
|
136022
|
-
var
|
|
136023
|
-
return
|
|
136024
|
-
popperRect:
|
|
136025
|
-
popperState:
|
|
136036
|
+
var Ue = Me().concat(F).map(function(Ve) {
|
|
136037
|
+
var $e, Ke = Ve._tippy, ut = ($e = Ke.popperInstance) == null ? void 0 : $e.state;
|
|
136038
|
+
return ut ? {
|
|
136039
|
+
popperRect: Ve.getBoundingClientRect(),
|
|
136040
|
+
popperState: ut,
|
|
136026
136041
|
props: n
|
|
136027
136042
|
} : null;
|
|
136028
136043
|
}).filter(Boolean);
|
|
@@ -136047,9 +136062,9 @@ function B3n(e, t) {
|
|
|
136047
136062
|
}
|
|
136048
136063
|
function X() {
|
|
136049
136064
|
de();
|
|
136050
|
-
var ve = x.props, Be = ve.popperOptions, Ae = ve.placement, Ue = ve.offset,
|
|
136051
|
-
getBoundingClientRect:
|
|
136052
|
-
contextElement:
|
|
136065
|
+
var ve = x.props, Be = ve.popperOptions, Ae = ve.placement, Ue = ve.offset, Ve = ve.getReferenceClientRect, $e = ve.moveTransition, Ke = S() ? q_(F).arrow : null, ut = Ve ? {
|
|
136066
|
+
getBoundingClientRect: Ve,
|
|
136067
|
+
contextElement: Ve.contextElement || L()
|
|
136053
136068
|
} : e, Oe = {
|
|
136054
136069
|
name: "$$tippy",
|
|
136055
136070
|
enabled: !0,
|
|
@@ -136058,7 +136073,7 @@ function B3n(e, t) {
|
|
|
136058
136073
|
fn: function(at) {
|
|
136059
136074
|
var st = at.state;
|
|
136060
136075
|
if (S()) {
|
|
136061
|
-
var
|
|
136076
|
+
var ht = j(), Mt = ht.box;
|
|
136062
136077
|
["placement", "reference-hidden", "escaped"].forEach(function(At) {
|
|
136063
136078
|
At === "placement" ? Mt.setAttribute("data-placement", st.placement) : st.attributes.popper["data-popper-" + At] ? Mt.setAttribute("data-" + At, "") : Mt.removeAttribute("data-" + At);
|
|
136064
136079
|
}), st.attributes.popper = {};
|
|
@@ -136087,7 +136102,7 @@ function B3n(e, t) {
|
|
|
136087
136102
|
}, {
|
|
136088
136103
|
name: "computeStyles",
|
|
136089
136104
|
options: {
|
|
136090
|
-
adaptive:
|
|
136105
|
+
adaptive: !$e
|
|
136091
136106
|
}
|
|
136092
136107
|
}, Oe];
|
|
136093
136108
|
S() && Ke && ze.push({
|
|
@@ -136096,7 +136111,7 @@ function B3n(e, t) {
|
|
|
136096
136111
|
element: Ke,
|
|
136097
136112
|
padding: 3
|
|
136098
136113
|
}
|
|
136099
|
-
}), ze.push.apply(ze, (Be == null ? void 0 : Be.modifiers) || []), x.popperInstance = l3n(
|
|
136114
|
+
}), ze.push.apply(ze, (Be == null ? void 0 : Be.modifiers) || []), x.popperInstance = l3n(ut, F, Object.assign({}, Be, {
|
|
136100
136115
|
placement: Ae,
|
|
136101
136116
|
onFirstUpdate: f,
|
|
136102
136117
|
modifiers: ze
|
|
@@ -136120,8 +136135,8 @@ function B3n(e, t) {
|
|
|
136120
136135
|
}
|
|
136121
136136
|
function ge(ve) {
|
|
136122
136137
|
x.clearDelayTimeouts(), ve && B("onTrigger", [x, ve]), te();
|
|
136123
|
-
var Be = N(!0), Ae = _(), Ue = Ae[0],
|
|
136124
|
-
lu.isTouch && Ue === "hold" &&
|
|
136138
|
+
var Be = N(!0), Ae = _(), Ue = Ae[0], Ve = Ae[1];
|
|
136139
|
+
lu.isTouch && Ue === "hold" && Ve && (Be = Ve), Be ? r = setTimeout(function() {
|
|
136125
136140
|
x.show();
|
|
136126
136141
|
}, Be) : x.show();
|
|
136127
136142
|
}
|
|
@@ -136168,20 +136183,20 @@ function B3n(e, t) {
|
|
|
136168
136183
|
}
|
|
136169
136184
|
function ye() {
|
|
136170
136185
|
process.env.NODE_ENV !== "production" && jc(x.state.isDestroyed, vp("show"));
|
|
136171
|
-
var ve = x.state.isVisible, Be = x.state.isDestroyed, Ae = !x.state.isEnabled, Ue = lu.isTouch && !x.props.touch,
|
|
136186
|
+
var ve = x.state.isVisible, Be = x.state.isDestroyed, Ae = !x.state.isEnabled, Ue = lu.isTouch && !x.props.touch, Ve = VA(x.props.duration, 0, Ra.duration);
|
|
136172
136187
|
if (!(ve || Be || Ae || Ue) && !L().hasAttribute("disabled") && (B("onShow", [x], !1), x.props.onShow(x) !== !1)) {
|
|
136173
136188
|
if (x.state.isVisible = !0, S() && (F.style.visibility = "visible"), O(), te(), x.state.isMounted || (F.style.transition = "none"), S()) {
|
|
136174
|
-
var
|
|
136175
|
-
WA([Ke,
|
|
136189
|
+
var $e = j(), Ke = $e.box, ut = $e.content;
|
|
136190
|
+
WA([Ke, ut], 0);
|
|
136176
136191
|
}
|
|
136177
136192
|
f = function() {
|
|
136178
136193
|
var ze;
|
|
136179
136194
|
if (!(!x.state.isVisible || u)) {
|
|
136180
136195
|
if (u = !0, F.offsetHeight, F.style.transition = x.props.moveTransition, S() && x.props.animation) {
|
|
136181
136196
|
var Ge = j(), at = Ge.box, st = Ge.content;
|
|
136182
|
-
WA([at, st],
|
|
136197
|
+
WA([at, st], Ve), WQ([at, st], "visible");
|
|
136183
136198
|
}
|
|
136184
|
-
U(), $(), qQ(GA, x), (ze = x.popperInstance) == null || ze.forceUpdate(), B("onMount", [x]), x.props.animation && S() && ae(
|
|
136199
|
+
U(), $(), qQ(GA, x), (ze = x.popperInstance) == null || ze.forceUpdate(), B("onMount", [x]), x.props.animation && S() && ae(Ve, function() {
|
|
136185
136200
|
x.state.isShown = !0, B("onShown", [x]);
|
|
136186
136201
|
});
|
|
136187
136202
|
}
|
|
@@ -136193,8 +136208,8 @@ function B3n(e, t) {
|
|
|
136193
136208
|
var ve = !x.state.isVisible, Be = x.state.isDestroyed, Ae = !x.state.isEnabled, Ue = VA(x.props.duration, 1, Ra.duration);
|
|
136194
136209
|
if (!(ve || Be || Ae) && (B("onHide", [x], !1), x.props.onHide(x) !== !1)) {
|
|
136195
136210
|
if (x.state.isVisible = !1, x.state.isShown = !1, u = !1, a = !1, S() && (F.style.visibility = "hidden"), q(), K(), O(!0), S()) {
|
|
136196
|
-
var
|
|
136197
|
-
x.props.animation && (WA([
|
|
136211
|
+
var Ve = j(), $e = Ve.box, Ke = Ve.content;
|
|
136212
|
+
x.props.animation && (WA([$e, Ke], Ue), WQ([$e, Ke], "hidden"));
|
|
136198
136213
|
}
|
|
136199
136214
|
U(), $(), x.props.animation ? S() && ne(Ue, x.unmount) : x.unmount();
|
|
136200
136215
|
}
|
|
@@ -139010,7 +139025,7 @@ Expected it to be ${r}.`;
|
|
|
139010
139025
|
var gbn = class extends Error {
|
|
139011
139026
|
constructor(n) {
|
|
139012
139027
|
super(pbn(n));
|
|
139013
|
-
|
|
139028
|
+
ct(this, "name", "InvalidDocError");
|
|
139014
139029
|
this.doc = n;
|
|
139015
139030
|
}
|
|
139016
139031
|
}, jg = gbn, uee = {};
|
|
@@ -139980,12 +139995,12 @@ function b6n(e) {
|
|
|
139980
139995
|
var I5e = class extends Error {
|
|
139981
139996
|
constructor() {
|
|
139982
139997
|
super(...arguments);
|
|
139983
|
-
|
|
139998
|
+
ct(this, "name", "ConfigError");
|
|
139984
139999
|
}
|
|
139985
140000
|
}, hee = class extends Error {
|
|
139986
140001
|
constructor() {
|
|
139987
140002
|
super(...arguments);
|
|
139988
|
-
|
|
140003
|
+
ct(this, "name", "UndefinedParserError");
|
|
139989
140004
|
}
|
|
139990
140005
|
}, v6n = { checkIgnorePragma: { category: "Special", type: "boolean", default: !1, description: "Check whether the file's first docblock comment contains '@noprettier' or '@noformat' to determine if it should be formatted.", cliCategory: "Other" }, cursorOffset: { category: "Special", type: "int", default: -1, range: { start: -1, end: 1 / 0, step: 1 }, description: "Print (to stderr) where a cursor at the given position would move to after formatting.", cliCategory: "Editor" }, endOfLine: { category: "Global", type: "choice", default: "lf", description: "Which end of line characters to apply.", choices: [{ value: "lf", description: "Line Feed only (\\n), common on Linux and macOS as well as inside git repos" }, { value: "crlf", description: "Carriage Return + Line Feed characters (\\r\\n), common on Windows" }, { value: "cr", description: "Carriage Return character only (\\r), used very rarely" }, { value: "auto", description: `Maintain existing
|
|
139991
140006
|
(mixed values within one file are normalised by looking at what's used after the first line)` }] }, filepath: { category: "Special", type: "path", description: "Specify the input filepath. This will be used to do parser inference.", cliName: "stdin-filepath", cliCategory: "Other", cliDescription: "Path to the file to pretend that stdin comes from." }, insertPragma: { category: "Special", type: "boolean", default: !1, description: "Insert @format pragma into file's first docblock comment.", cliCategory: "Other" }, parser: { category: "Global", type: "choice", default: void 0, description: "Which parser to use.", exception: (e) => typeof e == "string" || typeof e == "function", choices: [{ value: "flow", description: "Flow" }, { value: "babel", description: "JavaScript" }, { value: "babel-flow", description: "Flow" }, { value: "babel-ts", description: "TypeScript" }, { value: "typescript", description: "TypeScript" }, { value: "acorn", description: "JavaScript" }, { value: "espree", description: "JavaScript" }, { value: "meriyah", description: "JavaScript" }, { value: "css", description: "CSS" }, { value: "less", description: "Less" }, { value: "scss", description: "SCSS" }, { value: "json", description: "JSON" }, { value: "json5", description: "JSON5" }, { value: "jsonc", description: "JSON with Comments" }, { value: "json-stringify", description: "JSON.stringify" }, { value: "graphql", description: "GraphQL" }, { value: "markdown", description: "Markdown" }, { value: "mdx", description: "MDX" }, { value: "vue", description: "Vue" }, { value: "yaml", description: "YAML" }, { value: "glimmer", description: "Ember / Handlebars" }, { value: "html", description: "HTML" }, { value: "angular", description: "Angular" }, { value: "lwc", description: "Lightning Web Components" }, { value: "mjml", description: "MJML" }] }, plugins: { type: "path", array: !0, default: [{ value: [] }], category: "Global", description: "Add a plugin. Multiple plugins can be passed as separate `--plugin`s.", exception: (e) => typeof e == "string" || typeof e == "object", cliName: "plugin", cliCategory: "Config" }, printWidth: { category: "Global", type: "int", default: 80, description: "The line length where Prettier will try wrap.", range: { start: 0, end: 1 / 0, step: 1 } }, rangeEnd: { category: "Special", type: "int", default: 1 / 0, range: { start: 0, end: 1 / 0, step: 1 }, description: `Format code ending at a given character offset (exclusive).
|
|
@@ -141007,7 +141022,7 @@ Expected it to be ${r}.`;
|
|
|
141007
141022
|
var Cvn = class extends Error {
|
|
141008
141023
|
constructor(t) {
|
|
141009
141024
|
super(Fvn(t));
|
|
141010
|
-
|
|
141025
|
+
ct(this, "name", "InvalidDocError");
|
|
141011
141026
|
this.doc = t;
|
|
141012
141027
|
}
|
|
141013
141028
|
}, Dvn = Cvn;
|
|
@@ -141158,7 +141173,7 @@ var Rvn = Ovn, Pvn = [" ", `
|
|
|
141158
141173
|
`, "\f", "\r", " "], zvn = new Rvn(Pvn), m1 = zvn, Uvn = class extends Error {
|
|
141159
141174
|
constructor(t, n, r = "type") {
|
|
141160
141175
|
super(`Unexpected ${n} node ${r}: ${JSON.stringify(t[r])}.`);
|
|
141161
|
-
|
|
141176
|
+
ct(this, "name", "UnexpectedNodeError");
|
|
141162
141177
|
this.node = t;
|
|
141163
141178
|
}
|
|
141164
141179
|
}, Hvn = Uvn;
|
|
@@ -150687,9 +150702,9 @@ https://github.com/nodeca/pako/blob/main/LICENSE
|
|
|
150687
150702
|
for (de.max_code = Z, Fe = X.heap_len >> 1; 1 <= Fe; Fe--) J(X, pe, Fe);
|
|
150688
150703
|
for (ge = H; Fe = X.heap[1], X.heap[1] = X.heap[X.heap_len--], J(X, pe, 1), Me = X.heap[1], X.heap[--X.heap_max] = Fe, X.heap[--X.heap_max] = Me, pe[2 * ge] = pe[2 * Fe] + pe[2 * Me], X.depth[ge] = (X.depth[Fe] >= X.depth[Me] ? X.depth[Fe] : X.depth[Me]) + 1, pe[2 * Fe + 1] = pe[2 * Me + 1] = ge, X.heap[1] = ge++, J(X, pe, 1), 2 <= X.heap_len; ) ;
|
|
150689
150704
|
X.heap[--X.heap_max] = X.heap[1], function(se, ye) {
|
|
150690
|
-
var we, xe, Se, Le, ve, Be, Ae = ye.dyn_tree, Ue = ye.max_code,
|
|
150705
|
+
var we, xe, Se, Le, ve, Be, Ae = ye.dyn_tree, Ue = ye.max_code, Ve = ye.stat_desc.static_tree, $e = ye.stat_desc.has_stree, Ke = ye.stat_desc.extra_bits, ut = ye.stat_desc.extra_base, Oe = ye.stat_desc.max_length, ze = 0;
|
|
150691
150706
|
for (Le = 0; Le <= m; Le++) se.bl_count[Le] = 0;
|
|
150692
|
-
for (Ae[2 * se.heap[se.heap_max] + 1] = 0, we = se.heap_max + 1; we < g; we++) Oe < (Le = Ae[2 * Ae[2 * (xe = se.heap[we]) + 1] + 1] + 1) && (Le = Oe, ze++), Ae[2 * xe + 1] = Le, Ue < xe || (se.bl_count[Le]++, ve = 0,
|
|
150707
|
+
for (Ae[2 * se.heap[se.heap_max] + 1] = 0, we = se.heap_max + 1; we < g; we++) Oe < (Le = Ae[2 * Ae[2 * (xe = se.heap[we]) + 1] + 1] + 1) && (Le = Oe, ze++), Ae[2 * xe + 1] = Le, Ue < xe || (se.bl_count[Le]++, ve = 0, ut <= xe && (ve = Ke[xe - ut]), Be = Ae[2 * xe], se.opt_len += Be * (Le + ve), $e && (se.static_len += Be * (Ve[2 * xe + 1] + ve)));
|
|
150693
150708
|
if (ze !== 0) {
|
|
150694
150709
|
do {
|
|
150695
150710
|
for (Le = Oe - 1; se.bl_count[Le] === 0; ) Le--;
|
|
@@ -163472,7 +163487,7 @@ var mI = {
|
|
|
163472
163487
|
o !== n && (r *= o.sizeMultiplier / n.sizeMultiplier);
|
|
163473
163488
|
}
|
|
163474
163489
|
return Math.min(t.number * r, n.maxSize);
|
|
163475
|
-
},
|
|
163490
|
+
}, dt = function(t) {
|
|
163476
163491
|
return +t.toFixed(4) + "em";
|
|
163477
163492
|
}, f0 = function(t) {
|
|
163478
163493
|
return t.filter((n) => n).join(" ");
|
|
@@ -163592,7 +163607,7 @@ class $s {
|
|
|
163592
163607
|
*/
|
|
163593
163608
|
toNode() {
|
|
163594
163609
|
var t = document.createTextNode(this.text), n = null;
|
|
163595
|
-
this.italic > 0 && (n = document.createElement("span"), n.style.marginRight =
|
|
163610
|
+
this.italic > 0 && (n = document.createElement("span"), n.style.marginRight = dt(this.italic)), this.classes.length > 0 && (n = n || document.createElement("span"), n.className = f0(this.classes));
|
|
163596
163611
|
for (var r in this.style)
|
|
163597
163612
|
this.style.hasOwnProperty(r) && (n = n || document.createElement("span"), n.style[r] = this.style[r]);
|
|
163598
163613
|
return n ? (n.appendChild(t), n) : t;
|
|
@@ -164522,7 +164537,7 @@ var yx = [
|
|
|
164522
164537
|
return Nq(i), i;
|
|
164523
164538
|
}, k7e = (e, t, n, r) => new O5(e, t, n, r), fMn = function(t, n, r) {
|
|
164524
164539
|
var o = Hi([t], [], n);
|
|
164525
|
-
return o.height = Math.max(r || n.fontMetrics().defaultRuleThickness, n.minRuleThickness), o.style.borderBottomWidth =
|
|
164540
|
+
return o.height = Math.max(r || n.fontMetrics().defaultRuleThickness, n.minRuleThickness), o.style.borderBottomWidth = dt(o.height), o.maxFontSize = 1, o;
|
|
164526
164541
|
}, hMn = function(t, n, r, o) {
|
|
164527
164542
|
var i = new Lq(t, n, r, o);
|
|
164528
164543
|
return Nq(i), i;
|
|
@@ -164582,23 +164597,23 @@ var yx = [
|
|
|
164582
164597
|
}
|
|
164583
164598
|
i += 2;
|
|
164584
164599
|
var u = Hi(["pstrut"], []);
|
|
164585
|
-
u.style.height =
|
|
164600
|
+
u.style.height = dt(i);
|
|
164586
164601
|
for (var c = [], d = o, f = o, h = o, p = 0; p < r.length; p++) {
|
|
164587
164602
|
var g = r[p];
|
|
164588
164603
|
if (g.type === "kern")
|
|
164589
164604
|
h += g.size;
|
|
164590
164605
|
else {
|
|
164591
164606
|
var m = g.elem, y = g.wrapperClasses || [], b = g.wrapperStyle || {}, v = Hi(y, [u, m], void 0, b);
|
|
164592
|
-
v.style.top =
|
|
164607
|
+
v.style.top = dt(-i - h - m.depth), g.marginLeft && (v.style.marginLeft = g.marginLeft), g.marginRight && (v.style.marginRight = g.marginRight), c.push(v), h += m.height + m.depth;
|
|
164593
164608
|
}
|
|
164594
164609
|
d = Math.min(d, h), f = Math.max(f, h);
|
|
164595
164610
|
}
|
|
164596
164611
|
var x = Hi(["vlist"], c);
|
|
164597
|
-
x.style.height =
|
|
164612
|
+
x.style.height = dt(f);
|
|
164598
164613
|
var k;
|
|
164599
164614
|
if (d < 0) {
|
|
164600
164615
|
var F = Hi([], []), C = Hi(["vlist"], [F]);
|
|
164601
|
-
C.style.height =
|
|
164616
|
+
C.style.height = dt(-d);
|
|
164602
164617
|
var D = Hi(["vlist-s"], [new $s("")]);
|
|
164603
164618
|
k = [Hi(["vlist-r"], [x, D]), Hi(["vlist-r"], [C])];
|
|
164604
164619
|
} else
|
|
@@ -164607,7 +164622,7 @@ var yx = [
|
|
|
164607
164622
|
return k.length === 2 && T.classes.push("vlist-t2"), T.height = f, T.depth = -d, T;
|
|
164608
164623
|
}, yMn = (e, t) => {
|
|
164609
164624
|
var n = Hi(["mspace"], [], t), r = Lr(e, t);
|
|
164610
|
-
return n.style.marginRight =
|
|
164625
|
+
return n.style.marginRight = dt(r), n;
|
|
164611
164626
|
}, bx = function(t, n, r) {
|
|
164612
164627
|
var o = "";
|
|
164613
164628
|
switch (t) {
|
|
@@ -164693,14 +164708,14 @@ var yx = [
|
|
|
164693
164708
|
oiiintSize2: ["oiiintSize2", 1.98, 0.659]
|
|
164694
164709
|
}, bMn = function(t, n) {
|
|
164695
164710
|
var [r, o, i] = D7e[t], a = new h0(r), s = new w1([a], {
|
|
164696
|
-
width:
|
|
164697
|
-
height:
|
|
164711
|
+
width: dt(o),
|
|
164712
|
+
height: dt(i),
|
|
164698
164713
|
// Override CSS rule `.katex svg { width: 100% }`
|
|
164699
|
-
style: "width:" +
|
|
164714
|
+
style: "width:" + dt(o),
|
|
164700
164715
|
viewBox: "0 0 " + 1e3 * o + " " + 1e3 * i,
|
|
164701
164716
|
preserveAspectRatio: "xMinYMin"
|
|
164702
164717
|
}), l = k7e(["overlay"], [s], n);
|
|
164703
|
-
return l.height = i, l.style.height =
|
|
164718
|
+
return l.height = i, l.style.height = dt(i), l.style.width = dt(o), l;
|
|
164704
164719
|
}, Ie = {
|
|
164705
164720
|
fontMap: C7e,
|
|
164706
164721
|
makeSymbol: ol,
|
|
@@ -164938,7 +164953,7 @@ var vw = function(t) {
|
|
|
164938
164953
|
};
|
|
164939
164954
|
function vx(e, t) {
|
|
164940
164955
|
var n = k1(["base"], e, t), r = k1(["strut"]);
|
|
164941
|
-
return r.style.height =
|
|
164956
|
+
return r.style.height = dt(n.height + n.depth), n.depth && (r.style.verticalAlign = dt(-n.depth)), n.children.unshift(r), n;
|
|
164942
164957
|
}
|
|
164943
164958
|
function xI(e, t) {
|
|
164944
164959
|
var n = null;
|
|
@@ -164957,7 +164972,7 @@ function xI(e, t) {
|
|
|
164957
164972
|
var c = k1(["katex-html"], i);
|
|
164958
164973
|
if (c.setAttribute("aria-hidden", "true"), u) {
|
|
164959
164974
|
var d = u.children[0];
|
|
164960
|
-
d.style.height =
|
|
164975
|
+
d.style.height = dt(c.height + c.depth), c.depth && (d.style.verticalAlign = dt(-c.depth));
|
|
164961
164976
|
}
|
|
164962
164977
|
return c;
|
|
164963
164978
|
}
|
|
@@ -165056,13 +165071,13 @@ class MMn {
|
|
|
165056
165071
|
if (this.character)
|
|
165057
165072
|
return document.createTextNode(this.character);
|
|
165058
165073
|
var t = document.createElementNS("http://www.w3.org/1998/Math/MathML", "mspace");
|
|
165059
|
-
return t.setAttribute("width",
|
|
165074
|
+
return t.setAttribute("width", dt(this.width)), t;
|
|
165060
165075
|
}
|
|
165061
165076
|
/**
|
|
165062
165077
|
* Converts the math node into an HTML markup string.
|
|
165063
165078
|
*/
|
|
165064
165079
|
toMarkup() {
|
|
165065
|
-
return this.character ? "<mtext>" + this.character + "</mtext>" : '<mspace width="' +
|
|
165080
|
+
return this.character ? "<mtext>" + this.character + "</mtext>" : '<mspace width="' + dt(this.width) + '"/>';
|
|
165066
165081
|
}
|
|
165067
165082
|
/**
|
|
165068
165083
|
* Converts the math node into a string, similar to innerText.
|
|
@@ -165323,7 +165338,7 @@ var S7e = function(t) {
|
|
|
165323
165338
|
}
|
|
165324
165339
|
var g = new h0(f), m = new w1([g], {
|
|
165325
165340
|
width: "100%",
|
|
165326
|
-
height:
|
|
165341
|
+
height: dt(h),
|
|
165327
165342
|
viewBox: "0 0 " + s + " " + d,
|
|
165328
165343
|
preserveAspectRatio: "none"
|
|
165329
165344
|
});
|
|
@@ -165347,7 +165362,7 @@ var S7e = function(t) {
|
|
|
165347
165362
|
for (var I = 0; I < C; I++) {
|
|
165348
165363
|
var S = new h0(v[I]), L = new w1([S], {
|
|
165349
165364
|
width: "400em",
|
|
165350
|
-
height:
|
|
165365
|
+
height: dt(F),
|
|
165351
165366
|
viewBox: "0 0 " + s + " " + k,
|
|
165352
165367
|
preserveAspectRatio: T[I] + " slice"
|
|
165353
165368
|
}), M = Ie.makeSvgSpan([D[I]], [L], n);
|
|
@@ -165357,7 +165372,7 @@ var S7e = function(t) {
|
|
|
165357
165372
|
minWidth: x,
|
|
165358
165373
|
height: F
|
|
165359
165374
|
};
|
|
165360
|
-
M.style.height =
|
|
165375
|
+
M.style.height = dt(F), y.push(M);
|
|
165361
165376
|
}
|
|
165362
165377
|
return {
|
|
165363
165378
|
span: Ie.makeSpan(["stretchy"], y, n),
|
|
@@ -165371,7 +165386,7 @@ var S7e = function(t) {
|
|
|
165371
165386
|
minWidth: i,
|
|
165372
165387
|
height: a
|
|
165373
165388
|
} = r();
|
|
165374
|
-
return o.height = a, o.style.height =
|
|
165389
|
+
return o.height = a, o.style.height = dt(a), i > 0 && (o.style.minWidth = dt(i)), o;
|
|
165375
165390
|
}, _Mn = function(t, n, r, o, i) {
|
|
165376
165391
|
var a, s = t.height + t.depth + r + o;
|
|
165377
165392
|
if (/fbox|color|angl/.test(n)) {
|
|
@@ -165396,11 +165411,11 @@ var S7e = function(t) {
|
|
|
165396
165411
|
}));
|
|
165397
165412
|
var c = new w1(u, {
|
|
165398
165413
|
width: "100%",
|
|
165399
|
-
height:
|
|
165414
|
+
height: dt(s)
|
|
165400
165415
|
});
|
|
165401
165416
|
a = Ie.makeSvgSpan([], [c], i);
|
|
165402
165417
|
}
|
|
165403
|
-
return a.height = s, a.style.height =
|
|
165418
|
+
return a.height = s, a.style.height = dt(s), a;
|
|
165404
165419
|
}, F1 = {
|
|
165405
165420
|
encloseSpan: _Mn,
|
|
165406
165421
|
mathMLnode: TMn,
|
|
@@ -165440,8 +165455,8 @@ var Oq = (e, t) => {
|
|
|
165440
165455
|
elem: f,
|
|
165441
165456
|
wrapperClasses: ["svg-align"],
|
|
165442
165457
|
wrapperStyle: s > 0 ? {
|
|
165443
|
-
width: "calc(100% - " +
|
|
165444
|
-
marginLeft:
|
|
165458
|
+
width: "calc(100% - " + dt(2 * s) + ")",
|
|
165459
|
+
marginLeft: dt(2 * s)
|
|
165445
165460
|
} : void 0
|
|
165446
165461
|
}]
|
|
165447
165462
|
}, t);
|
|
@@ -165454,7 +165469,7 @@ var Oq = (e, t) => {
|
|
|
165454
165469
|
var g = r.label === "\\textcircled";
|
|
165455
165470
|
g && (f.classes.push("accent-full"), d = i.height);
|
|
165456
165471
|
var m = s;
|
|
165457
|
-
g || (m -= p / 2), f.style.left =
|
|
165472
|
+
g || (m -= p / 2), f.style.left = dt(m), r.label === "\\textcircled" && (f.style.top = ".2em"), f = Ie.makeVList({
|
|
165458
165473
|
positionType: "firstBaseline",
|
|
165459
165474
|
children: [{
|
|
165460
165475
|
type: "elem",
|
|
@@ -165944,7 +165959,7 @@ vt({
|
|
|
165944
165959
|
},
|
|
165945
165960
|
htmlBuilder(e, t) {
|
|
165946
165961
|
var n = t.havingStyle(t.style.sup()), r = Ie.wrapFragment(An(e.label, n, t), t);
|
|
165947
|
-
return r.classes.push("cd-label-" + e.side), r.style.bottom =
|
|
165962
|
+
return r.classes.push("cd-label-" + e.side), r.style.bottom = dt(0.8 - r.depth), r.height = 0, r.depth = 0, r;
|
|
165948
165963
|
},
|
|
165949
165964
|
mathmlBuilder(e, t) {
|
|
165950
165965
|
var n = new nt.MathNode("mrow", [or(e.label, t)]);
|
|
@@ -166078,11 +166093,11 @@ vt({
|
|
|
166078
166093
|
// not within tabular/array environments.
|
|
166079
166094
|
htmlBuilder(e, t) {
|
|
166080
166095
|
var n = Ie.makeSpan(["mspace"], [], t);
|
|
166081
|
-
return e.newLine && (n.classes.push("newline"), e.size && (n.style.marginTop =
|
|
166096
|
+
return e.newLine && (n.classes.push("newline"), e.size && (n.style.marginTop = dt(Lr(e.size, t)))), n;
|
|
166082
166097
|
},
|
|
166083
166098
|
mathmlBuilder(e, t) {
|
|
166084
166099
|
var n = new nt.MathNode("mspace");
|
|
166085
|
-
return e.newLine && (n.setAttribute("linebreak", "newline"), e.size && n.setAttribute("height",
|
|
166100
|
+
return e.newLine && (n.setAttribute("linebreak", "newline"), e.size && n.setAttribute("height", dt(Lr(e.size, t)))), n;
|
|
166086
166101
|
}
|
|
166087
166102
|
});
|
|
166088
166103
|
var wI = {
|
|
@@ -166238,7 +166253,7 @@ var ty = function(t, n, r) {
|
|
|
166238
166253
|
return a.height *= s, a.depth *= s, a.maxFontSize = i.sizeMultiplier, a;
|
|
166239
166254
|
}, R7e = function(t, n, r) {
|
|
166240
166255
|
var o = n.havingBaseStyle(r), i = (1 - n.sizeMultiplier / o.sizeMultiplier) * n.fontMetrics().axisHeight;
|
|
166241
|
-
t.classes.push("delimcenter"), t.style.top =
|
|
166256
|
+
t.classes.push("delimcenter"), t.style.top = dt(i), t.height -= i, t.depth += i;
|
|
166242
166257
|
}, HMn = function(t, n, r, o, i, a) {
|
|
166243
166258
|
var s = Ie.makeSymbol(t, "Main-Regular", i, o), l = Rq(s, n, o, a);
|
|
166244
166259
|
return r && R7e(l, o, n), l;
|
|
@@ -166257,14 +166272,14 @@ var ty = function(t, n, r) {
|
|
|
166257
166272
|
};
|
|
166258
166273
|
}, AT = function(t, n, r) {
|
|
166259
166274
|
var o = wu["Size4-Regular"][t.charCodeAt(0)] ? wu["Size4-Regular"][t.charCodeAt(0)][4] : wu["Size1-Regular"][t.charCodeAt(0)][4], i = new h0("inner", ZDn(t, Math.round(1e3 * n))), a = new w1([i], {
|
|
166260
|
-
width:
|
|
166261
|
-
height:
|
|
166275
|
+
width: dt(o),
|
|
166276
|
+
height: dt(n),
|
|
166262
166277
|
// Override CSS rule `.katex svg { width: 100% }`
|
|
166263
|
-
style: "width:" +
|
|
166278
|
+
style: "width:" + dt(o),
|
|
166264
166279
|
viewBox: "0 0 " + 1e3 * o + " " + Math.round(1e3 * n),
|
|
166265
166280
|
preserveAspectRatio: "xMinYMin"
|
|
166266
166281
|
}), s = Ie.makeSvgSpan([], [a], r);
|
|
166267
|
-
return s.height = n, s.style.height =
|
|
166282
|
+
return s.height = n, s.style.height = dt(n), s.style.width = dt(o), {
|
|
166268
166283
|
type: "elem",
|
|
166269
166284
|
elem: s
|
|
166270
166285
|
};
|
|
@@ -166314,14 +166329,14 @@ var ty = function(t, n, r) {
|
|
|
166314
166329
|
var a = GDn(t, o, r), s = new h0(t, a), l = new w1([s], {
|
|
166315
166330
|
// Note: 1000:1 ratio of viewBox to document em width.
|
|
166316
166331
|
width: "400em",
|
|
166317
|
-
height:
|
|
166332
|
+
height: dt(n),
|
|
166318
166333
|
viewBox: "0 0 400000 " + r,
|
|
166319
166334
|
preserveAspectRatio: "xMinYMin slice"
|
|
166320
166335
|
});
|
|
166321
166336
|
return Ie.makeSvgSpan(["hide-tail"], [l], i);
|
|
166322
166337
|
}, $Mn = function(t, n) {
|
|
166323
166338
|
var r = n.havingBaseSizing(), o = V7e("\\surd", t * r.sizeMultiplier, q7e, r), i = r.sizeMultiplier, a = Math.max(0, n.minRuleThickness - n.fontMetrics().sqrtRuleThickness), s, l = 0, u = 0, c = 0, d;
|
|
166324
|
-
return o.type === "small" ? (c = 1e3 + 1e3 * a + ST, t < 1 ? i = 1 : t < 1.4 && (i = 0.7), l = (1 + a + TT) / i, u = (1 + a) / i, s = jT("sqrtMain", l, c, a, n), s.style.minWidth = "0.853em", d = 0.833 / i) : o.type === "large" ? (c = (1e3 + ST) * $y[o.size], u = ($y[o.size] + a) / i, l = ($y[o.size] + a + TT) / i, s = jT("sqrtSize" + o.size, l, c, a, n), s.style.minWidth = "1.02em", d = 1 / i) : (l = t + a + TT, u = t + a, c = Math.floor(1e3 * t + a) + ST, s = jT("sqrtTall", l, c, a, n), s.style.minWidth = "0.742em", d = 1.056), s.height = u, s.style.height =
|
|
166339
|
+
return o.type === "small" ? (c = 1e3 + 1e3 * a + ST, t < 1 ? i = 1 : t < 1.4 && (i = 0.7), l = (1 + a + TT) / i, u = (1 + a) / i, s = jT("sqrtMain", l, c, a, n), s.style.minWidth = "0.853em", d = 0.833 / i) : o.type === "large" ? (c = (1e3 + ST) * $y[o.size], u = ($y[o.size] + a) / i, l = ($y[o.size] + a + TT) / i, s = jT("sqrtSize" + o.size, l, c, a, n), s.style.minWidth = "1.02em", d = 1 / i) : (l = t + a + TT, u = t + a, c = Math.floor(1e3 * t + a) + ST, s = jT("sqrtTall", l, c, a, n), s.style.minWidth = "0.742em", d = 1.056), s.height = u, s.style.height = dt(l), {
|
|
166325
166340
|
span: s,
|
|
166326
166341
|
advanceWidth: d,
|
|
166327
166342
|
// Calculate the actual line width.
|
|
@@ -166532,7 +166547,7 @@ vt({
|
|
|
166532
166547
|
e.delim !== "." && t.push(Gs(e.delim, e.mode));
|
|
166533
166548
|
var n = new nt.MathNode("mo", t);
|
|
166534
166549
|
e.mclass === "mopen" || e.mclass === "mclose" ? n.setAttribute("fence", "true") : n.setAttribute("fence", "false"), n.setAttribute("stretchy", "true");
|
|
166535
|
-
var r =
|
|
166550
|
+
var r = dt(t1.sizeToMaxHeight[e.size]);
|
|
166536
166551
|
return n.setAttribute("minsize", r), n.setAttribute("maxsize", r), n;
|
|
166537
166552
|
}
|
|
166538
166553
|
});
|
|
@@ -166666,14 +166681,14 @@ var Pq = (e, t) => {
|
|
|
166666
166681
|
}, t), c = t.havingBaseSizing();
|
|
166667
166682
|
o = o / c.sizeMultiplier;
|
|
166668
166683
|
var d = n.height + n.depth + l + u;
|
|
166669
|
-
n.style.paddingLeft =
|
|
166684
|
+
n.style.paddingLeft = dt(d / 2 + l);
|
|
166670
166685
|
var f = Math.floor(1e3 * d * o), h = WDn(f), p = new w1([new h0("phase", h)], {
|
|
166671
166686
|
width: "400em",
|
|
166672
|
-
height:
|
|
166687
|
+
height: dt(f / 1e3),
|
|
166673
166688
|
viewBox: "0 0 400000 " + f,
|
|
166674
166689
|
preserveAspectRatio: "xMinYMin slice"
|
|
166675
166690
|
});
|
|
166676
|
-
i = Ie.makeSvgSpan(["hide-tail"], [p], t), i.style.height =
|
|
166691
|
+
i = Ie.makeSvgSpan(["hide-tail"], [p], t), i.style.height = dt(d), a = n.depth + l + u;
|
|
166677
166692
|
} else {
|
|
166678
166693
|
/cancel/.test(r) ? s || n.classes.push("cancel-pad") : r === "angl" ? n.classes.push("anglpad") : n.classes.push("boxpad");
|
|
166679
166694
|
var g = 0, m = 0, y = 0;
|
|
@@ -166682,7 +166697,7 @@ var Pq = (e, t) => {
|
|
|
166682
166697
|
// default
|
|
166683
166698
|
t.minRuleThickness
|
|
166684
166699
|
// User override.
|
|
166685
|
-
), g = t.fontMetrics().fboxsep + (r === "colorbox" ? 0 : y), m = g) : r === "angl" ? (y = Math.max(t.fontMetrics().defaultRuleThickness, t.minRuleThickness), g = 4 * y, m = Math.max(0, 0.25 - n.depth)) : (g = s ? 0.2 : 0, m = g), i = F1.encloseSpan(n, r, g, m, t), /fbox|boxed|fcolorbox/.test(r) ? (i.style.borderStyle = "solid", i.style.borderWidth =
|
|
166700
|
+
), g = t.fontMetrics().fboxsep + (r === "colorbox" ? 0 : y), m = g) : r === "angl" ? (y = Math.max(t.fontMetrics().defaultRuleThickness, t.minRuleThickness), g = 4 * y, m = Math.max(0, 0.25 - n.depth)) : (g = s ? 0.2 : 0, m = g), i = F1.encloseSpan(n, r, g, m, t), /fbox|boxed|fcolorbox/.test(r) ? (i.style.borderStyle = "solid", i.style.borderWidth = dt(y)) : r === "angl" && y !== 0.049 && (i.style.borderTopWidth = dt(y), i.style.borderRightWidth = dt(y)), a = n.depth + m, e.backgroundColor && (i.style.backgroundColor = e.backgroundColor, e.borderColor && (i.style.borderColor = e.borderColor));
|
|
166686
166701
|
}
|
|
166687
166702
|
var b;
|
|
166688
166703
|
if (e.backgroundColor)
|
|
@@ -167039,18 +167054,18 @@ var cc = function(t, n) {
|
|
|
167039
167054
|
++o, ++N
|
|
167040
167055
|
) {
|
|
167041
167056
|
for (var z = L[N] || {}, Y = !0; z.type === "separator"; ) {
|
|
167042
|
-
if (Y || (j = Ie.makeSpan(["arraycolsep"], []), j.style.width =
|
|
167057
|
+
if (Y || (j = Ie.makeSpan(["arraycolsep"], []), j.style.width = dt(n.fontMetrics().doubleRuleSep), M.push(j)), z.separator === "|" || z.separator === ":") {
|
|
167043
167058
|
var oe = z.separator === "|" ? "solid" : "dashed", te = Ie.makeSpan(["vertical-separator"], [], n);
|
|
167044
|
-
te.style.height =
|
|
167059
|
+
te.style.height = dt(v), te.style.borderRightWidth = dt(c), te.style.borderRightStyle = oe, te.style.margin = "0 " + dt(-c / 2);
|
|
167045
167060
|
var K = v - S;
|
|
167046
|
-
K && (te.style.verticalAlign =
|
|
167061
|
+
K && (te.style.verticalAlign = dt(-K)), M.push(te);
|
|
167047
167062
|
} else
|
|
167048
167063
|
throw new it("Invalid separator type: " + z.separator);
|
|
167049
167064
|
N++, z = L[N] || {}, Y = !1;
|
|
167050
167065
|
}
|
|
167051
167066
|
if (!(o >= s)) {
|
|
167052
167067
|
var ne = void 0;
|
|
167053
|
-
(o > 0 || t.hskipBeforeAndAfter) && (ne = In.deflt(z.pregap, f), ne !== 0 && (j = Ie.makeSpan(["arraycolsep"], []), j.style.width =
|
|
167068
|
+
(o > 0 || t.hskipBeforeAndAfter) && (ne = In.deflt(z.pregap, f), ne !== 0 && (j = Ie.makeSpan(["arraycolsep"], []), j.style.width = dt(ne), M.push(j)));
|
|
167054
167069
|
var ae = [];
|
|
167055
167070
|
for (r = 0; r < i; ++r) {
|
|
167056
167071
|
var ue = l[r], P = ue[o];
|
|
@@ -167066,7 +167081,7 @@ var cc = function(t, n) {
|
|
|
167066
167081
|
ae = Ie.makeVList({
|
|
167067
167082
|
positionType: "individualShift",
|
|
167068
167083
|
children: ae
|
|
167069
|
-
}, n), ae = Ie.makeSpan(["col-align-" + (z.align || "c")], [ae]), M.push(ae), (o < s - 1 || t.hskipBeforeAndAfter) && (ne = In.deflt(z.postgap, f), ne !== 0 && (j = Ie.makeSpan(["arraycolsep"], []), j.style.width =
|
|
167084
|
+
}, n), ae = Ie.makeSpan(["col-align-" + (z.align || "c")], [ae]), M.push(ae), (o < s - 1 || t.hskipBeforeAndAfter) && (ne = In.deflt(z.postgap, f), ne !== 0 && (j = Ie.makeSpan(["arraycolsep"], []), j.style.width = dt(ne), M.push(j)));
|
|
167070
167085
|
}
|
|
167071
167086
|
}
|
|
167072
167087
|
if (l = Ie.makeSpan(["mtable"], M), u.length > 0) {
|
|
@@ -167109,7 +167124,7 @@ var cc = function(t, n) {
|
|
|
167109
167124
|
t.tags && t.tags[a] && (l.unshift(o), l.push(o), t.leqno ? l.unshift(i) : l.push(i)), r.push(new nt.MathNode("mtr", l));
|
|
167110
167125
|
}
|
|
167111
167126
|
var c = new nt.MathNode("mtable", r), d = t.arraystretch === 0.5 ? 0.1 : 0.16 + t.arraystretch - 1 + (t.addJot ? 0.09 : 0);
|
|
167112
|
-
c.setAttribute("rowspacing",
|
|
167127
|
+
c.setAttribute("rowspacing", dt(d));
|
|
167113
167128
|
var f = "", h = "";
|
|
167114
167129
|
if (t.cols && t.cols.length > 0) {
|
|
167115
167130
|
var p = t.cols, g = "", m = !1, y = 0, b = p.length;
|
|
@@ -167644,7 +167659,7 @@ var X7e = (e, t) => {
|
|
|
167644
167659
|
n.setAttribute("linethickness", "0px");
|
|
167645
167660
|
else if (e.barSize) {
|
|
167646
167661
|
var r = Lr(e.barSize, t);
|
|
167647
|
-
n.setAttribute("linethickness",
|
|
167662
|
+
n.setAttribute("linethickness", dt(r));
|
|
167648
167663
|
}
|
|
167649
167664
|
var o = X7e(e.size, t.style);
|
|
167650
167665
|
if (o.size !== t.style.size) {
|
|
@@ -168253,9 +168268,9 @@ vt({
|
|
|
168253
168268
|
var o = 0;
|
|
168254
168269
|
e.width.number > 0 && (o = Lr(e.width, t));
|
|
168255
168270
|
var i = {
|
|
168256
|
-
height:
|
|
168271
|
+
height: dt(n + r)
|
|
168257
168272
|
};
|
|
168258
|
-
o > 0 && (i.width =
|
|
168273
|
+
o > 0 && (i.width = dt(o)), r > 0 && (i.verticalAlign = dt(-r));
|
|
168259
168274
|
var a = new tMn(e.src, e.alt, i);
|
|
168260
168275
|
return a.height = n, a.depth = r, a;
|
|
168261
168276
|
},
|
|
@@ -168263,9 +168278,9 @@ vt({
|
|
|
168263
168278
|
var n = new nt.MathNode("mglyph", []);
|
|
168264
168279
|
n.setAttribute("alt", e.alt);
|
|
168265
168280
|
var r = Lr(e.height, t), o = 0;
|
|
168266
|
-
if (e.totalheight.number > 0 && (o = Lr(e.totalheight, t) - r, n.setAttribute("valign",
|
|
168281
|
+
if (e.totalheight.number > 0 && (o = Lr(e.totalheight, t) - r, n.setAttribute("valign", dt(-o))), n.setAttribute("height", dt(r + o)), e.width.number > 0) {
|
|
168267
168282
|
var i = Lr(e.width, t);
|
|
168268
|
-
n.setAttribute("width",
|
|
168283
|
+
n.setAttribute("width", dt(i));
|
|
168269
168284
|
}
|
|
168270
168285
|
return n.setAttribute("src", e.src), n;
|
|
168271
168286
|
}
|
|
@@ -168325,7 +168340,7 @@ vt({
|
|
|
168325
168340
|
var n;
|
|
168326
168341
|
e.alignment === "clap" ? (n = Ie.makeSpan([], [An(e.body, t)]), n = Ie.makeSpan(["inner"], [n], t)) : n = Ie.makeSpan(["inner"], [An(e.body, t)]);
|
|
168327
168342
|
var r = Ie.makeSpan(["fix"], []), o = Ie.makeSpan([e.alignment], [n, r], t), i = Ie.makeSpan(["strut"]);
|
|
168328
|
-
return i.style.height =
|
|
168343
|
+
return i.style.height = dt(o.height + o.depth), o.depth && (i.style.verticalAlign = dt(-o.depth)), o.children.unshift(i), o = Ie.makeSpan(["thinbox"], [o], t), Ie.makeSpan(["mord", "vbox"], [o], t);
|
|
168329
168344
|
},
|
|
168330
168345
|
mathmlBuilder: (e, t) => {
|
|
168331
168346
|
var n = new nt.MathNode("mpadded", [or(e.body, t)]);
|
|
@@ -168444,7 +168459,7 @@ var Q7e = (e, t, n, r, o, i, a) => {
|
|
|
168444
168459
|
}, {
|
|
168445
168460
|
type: "elem",
|
|
168446
168461
|
elem: l.elem,
|
|
168447
|
-
marginLeft:
|
|
168462
|
+
marginLeft: dt(-i)
|
|
168448
168463
|
}, {
|
|
168449
168464
|
type: "kern",
|
|
168450
168465
|
size: l.kern
|
|
@@ -168457,7 +168472,7 @@ var Q7e = (e, t, n, r, o, i, a) => {
|
|
|
168457
168472
|
}, {
|
|
168458
168473
|
type: "elem",
|
|
168459
168474
|
elem: u.elem,
|
|
168460
|
-
marginLeft:
|
|
168475
|
+
marginLeft: dt(i)
|
|
168461
168476
|
}, {
|
|
168462
168477
|
type: "kern",
|
|
168463
168478
|
size: r.fontMetrics().bigOpSpacing5
|
|
@@ -168474,7 +168489,7 @@ var Q7e = (e, t, n, r, o, i, a) => {
|
|
|
168474
168489
|
}, {
|
|
168475
168490
|
type: "elem",
|
|
168476
168491
|
elem: l.elem,
|
|
168477
|
-
marginLeft:
|
|
168492
|
+
marginLeft: dt(-i)
|
|
168478
168493
|
}, {
|
|
168479
168494
|
type: "kern",
|
|
168480
168495
|
size: l.kern
|
|
@@ -168497,7 +168512,7 @@ var Q7e = (e, t, n, r, o, i, a) => {
|
|
|
168497
168512
|
}, {
|
|
168498
168513
|
type: "elem",
|
|
168499
168514
|
elem: u.elem,
|
|
168500
|
-
marginLeft:
|
|
168515
|
+
marginLeft: dt(i)
|
|
168501
168516
|
}, {
|
|
168502
168517
|
type: "kern",
|
|
168503
168518
|
size: r.fontMetrics().bigOpSpacing5
|
|
@@ -168508,7 +168523,7 @@ var Q7e = (e, t, n, r, o, i, a) => {
|
|
|
168508
168523
|
var m = [f];
|
|
168509
168524
|
if (l && i !== 0 && !s) {
|
|
168510
168525
|
var y = Ie.makeSpan(["mspace"], [], r);
|
|
168511
|
-
y.style.marginRight =
|
|
168526
|
+
y.style.marginRight = dt(i), m.unshift(y);
|
|
168512
168527
|
}
|
|
168513
168528
|
return Ie.makeSpan(["mop", "op-limits"], m, r);
|
|
168514
168529
|
}, ewe = ["\\smallint"], Pm = (e, t) => {
|
|
@@ -168543,7 +168558,7 @@ var Q7e = (e, t, n, r, o, i, a) => {
|
|
|
168543
168558
|
l = Ie.makeSpan(["mop"], p, t);
|
|
168544
168559
|
}
|
|
168545
168560
|
var m = 0, y = 0;
|
|
168546
|
-
return (l instanceof $s || i.name === "\\oiint" || i.name === "\\oiiint") && !i.suppressBaseShift && (m = (l.height - l.depth) / 2 - t.fontMetrics().axisHeight, y = l.italic), o ? Q7e(l, n, r, t, a, y, m) : (m && (l.style.position = "relative", l.style.top =
|
|
168561
|
+
return (l instanceof $s || i.name === "\\oiint" || i.name === "\\oiiint") && !i.suppressBaseShift && (m = (l.height - l.depth) / 2 - t.fontMetrics().axisHeight, y = l.italic), o ? Q7e(l, n, r, t, a, y, m) : (m && (l.style.position = "relative", l.style.top = dt(m)), l);
|
|
168547
168562
|
}, R5 = (e, t) => {
|
|
168548
168563
|
var n;
|
|
168549
168564
|
if (e.symbol)
|
|
@@ -168983,13 +168998,13 @@ vt({
|
|
|
168983
168998
|
},
|
|
168984
168999
|
htmlBuilder(e, t) {
|
|
168985
169000
|
var n = Ie.makeSpan(["mord", "rule"], [], t), r = Lr(e.width, t), o = Lr(e.height, t), i = e.shift ? Lr(e.shift, t) : 0;
|
|
168986
|
-
return n.style.borderRightWidth =
|
|
169001
|
+
return n.style.borderRightWidth = dt(r), n.style.borderTopWidth = dt(o), n.style.bottom = dt(i), n.width = r, n.height = o + i, n.depth = -i, n.maxFontSize = o * 1.125 * t.sizeMultiplier, n;
|
|
168987
169002
|
},
|
|
168988
169003
|
mathmlBuilder(e, t) {
|
|
168989
169004
|
var n = Lr(e.width, t), r = Lr(e.height, t), o = e.shift ? Lr(e.shift, t) : 0, i = t.color && t.getColor() || "black", a = new nt.MathNode("mspace");
|
|
168990
|
-
a.setAttribute("mathbackground", i), a.setAttribute("width",
|
|
169005
|
+
a.setAttribute("mathbackground", i), a.setAttribute("width", dt(n)), a.setAttribute("height", dt(r));
|
|
168991
169006
|
var s = new nt.MathNode("mpadded", [a]);
|
|
168992
|
-
return o >= 0 ? s.setAttribute("height",
|
|
169007
|
+
return o >= 0 ? s.setAttribute("height", dt(o)) : (s.setAttribute("height", dt(o)), s.setAttribute("depth", dt(-o))), s.setAttribute("voffset", dt(o)), s;
|
|
168993
169008
|
}
|
|
168994
169009
|
});
|
|
168995
169010
|
function nwe(e, t, n) {
|
|
@@ -169027,7 +169042,7 @@ vt({
|
|
|
169027
169042
|
htmlBuilder: iEn,
|
|
169028
169043
|
mathmlBuilder: (e, t) => {
|
|
169029
169044
|
var n = t.havingSize(e.size), r = Da(e.body, n), o = new nt.MathNode("mstyle", r);
|
|
169030
|
-
return o.setAttribute("mathsize",
|
|
169045
|
+
return o.setAttribute("mathsize", dt(n.sizeMultiplier)), o;
|
|
169031
169046
|
}
|
|
169032
169047
|
});
|
|
169033
169048
|
vt({
|
|
@@ -169119,7 +169134,7 @@ vt({
|
|
|
169119
169134
|
} = t1.sqrtImage(s, t), d = l.height - u;
|
|
169120
169135
|
d > n.height + n.depth + a && (a = (a + d - n.height - n.depth) / 2);
|
|
169121
169136
|
var f = l.height - n.height - a - u;
|
|
169122
|
-
n.style.paddingLeft =
|
|
169137
|
+
n.style.paddingLeft = dt(c);
|
|
169123
169138
|
var h = Ie.makeVList({
|
|
169124
169139
|
positionType: "firstBaseline",
|
|
169125
169140
|
children: [{
|
|
@@ -169242,10 +169257,10 @@ tp({
|
|
|
169242
169257
|
}
|
|
169243
169258
|
var g;
|
|
169244
169259
|
t.style === Rt.DISPLAY ? g = u.sup1 : t.style.cramped ? g = u.sup3 : g = u.sup2;
|
|
169245
|
-
var m = t.sizeMultiplier, y =
|
|
169260
|
+
var m = t.sizeMultiplier, y = dt(0.5 / u.ptPerEm / m), b = null;
|
|
169246
169261
|
if (l) {
|
|
169247
169262
|
var v = e.base && e.base.type === "op" && e.base.name && (e.base.name === "\\oiint" || e.base.name === "\\oiiint");
|
|
169248
|
-
(a instanceof $s || v) && (b =
|
|
169263
|
+
(a instanceof $s || v) && (b = dt(-a.italic));
|
|
169249
169264
|
}
|
|
169250
169265
|
var x;
|
|
169251
169266
|
if (s && l) {
|
|
@@ -170043,7 +170058,7 @@ he("\\pmod", "\\pod{{\\rm mod}\\mkern6mu#1}");
|
|
|
170043
170058
|
he("\\mod", "\\allowbreak\\mathchoice{\\mkern18mu}{\\mkern12mu}{\\mkern12mu}{\\mkern12mu}{\\rm mod}\\,\\,#1");
|
|
170044
170059
|
he("\\newline", "\\\\\\relax");
|
|
170045
170060
|
he("\\TeX", "\\textrm{\\html@mathml{T\\kern-.1667em\\raisebox{-.5ex}{E}\\kern-.125emX}{TeX}}");
|
|
170046
|
-
var iwe =
|
|
170061
|
+
var iwe = dt(wu["Main-Regular"][84][1] - 0.7 * wu["Main-Regular"][65][1]);
|
|
170047
170062
|
he("\\LaTeX", "\\textrm{\\html@mathml{" + ("L\\kern-.36em\\raisebox{" + iwe + "}{\\scriptstyle A}") + "\\kern-.15em\\TeX}{LaTeX}}");
|
|
170048
170063
|
he("\\KaTeX", "\\textrm{\\html@mathml{" + ("K\\kern-.17em\\raisebox{" + iwe + "}{\\scriptstyle A}") + "\\kern-.15em\\TeX}{KaTeX}}");
|
|
170049
170064
|
he("\\hspace", "\\@ifstar\\@hspacer\\@hspace");
|
|
@@ -173346,7 +173361,7 @@ const jAn = ({
|
|
|
173346
173361
|
d.type.name === "callout" || d.type.name === "dBlock" ? c.push(...a(d.content)) : c.push(d);
|
|
173347
173362
|
}), c;
|
|
173348
173363
|
}, s = a(t.content), l = Ze.fromArray(s);
|
|
173349
|
-
return new
|
|
173364
|
+
return new ft(l, 0, 0);
|
|
173350
173365
|
}
|
|
173351
173366
|
}
|
|
173352
173367
|
})
|
|
@@ -188096,19 +188111,19 @@ function cjn({
|
|
|
188096
188111
|
var Kwe = cjn;
|
|
188097
188112
|
const Ywe = Pn(
|
|
188098
188113
|
(e, t) => {
|
|
188099
|
-
const [n, r] = Re(0), o =
|
|
188114
|
+
const [n, r] = Re(0), o = We(
|
|
188100
188115
|
(l) => {
|
|
188101
188116
|
const u = e.items[l];
|
|
188102
188117
|
u && e.command(u);
|
|
188103
188118
|
},
|
|
188104
188119
|
[e]
|
|
188105
|
-
), i =
|
|
188120
|
+
), i = We(() => {
|
|
188106
188121
|
r(
|
|
188107
188122
|
(l) => (l + e.items.length - 1) % e.items.length
|
|
188108
188123
|
);
|
|
188109
|
-
}, [e.items.length]), a =
|
|
188124
|
+
}, [e.items.length]), a = We(() => {
|
|
188110
188125
|
r((l) => (l + 1) % e.items.length);
|
|
188111
|
-
}, [e.items.length]), s =
|
|
188126
|
+
}, [e.items.length]), s = We(() => {
|
|
188112
188127
|
o(n);
|
|
188113
188128
|
}, [o, n]);
|
|
188114
188129
|
return He(() => {
|
|
@@ -248690,7 +248705,7 @@ const kjn = ({
|
|
|
248690
248705
|
command: t,
|
|
248691
248706
|
editor: n
|
|
248692
248707
|
}) => {
|
|
248693
|
-
const [r, o] = Re(0), [i, a] = Re(e), s = Hr("(max-width: 640px)"), l = Lx(n, "callout"), u = Lx(n, "codeBlock"), c = Lx(n, "column"), d = Lx(n, "table"), f =
|
|
248708
|
+
const [r, o] = Re(0), [i, a] = Re(e), s = Hr("(max-width: 640px)"), l = Lx(n, "callout"), u = Lx(n, "codeBlock"), c = Lx(n, "column"), d = Lx(n, "table"), f = We(
|
|
248694
248709
|
(p) => {
|
|
248695
248710
|
const g = i[p];
|
|
248696
248711
|
g && (g.title === "Continue writing" || t(g));
|
|
@@ -249387,7 +249402,7 @@ function lke(e) {
|
|
|
249387
249402
|
}
|
|
249388
249403
|
const mf = class mf {
|
|
249389
249404
|
constructor() {
|
|
249390
|
-
|
|
249405
|
+
ct(this, "_currentZoom", "1");
|
|
249391
249406
|
}
|
|
249392
249407
|
static getInstance() {
|
|
249393
249408
|
return mf.instance || (mf.instance = new mf()), mf.instance;
|
|
@@ -249416,7 +249431,7 @@ const mf = class mf {
|
|
|
249416
249431
|
), !window.matchMedia("(max-width: 1280px)").matches && n in r && t.classList.add(r[n]);
|
|
249417
249432
|
}
|
|
249418
249433
|
};
|
|
249419
|
-
|
|
249434
|
+
ct(mf, "instance");
|
|
249420
249435
|
let MI = mf;
|
|
249421
249436
|
const VT = MI.getInstance(), nLn = (e) => ({
|
|
249422
249437
|
type: "dBlock",
|
|
@@ -250525,7 +250540,7 @@ const Aoe = () => {
|
|
|
250525
250540
|
}, [u]), He(() => {
|
|
250526
250541
|
c(T), f(!!_);
|
|
250527
250542
|
}, [T, _]);
|
|
250528
|
-
const z =
|
|
250543
|
+
const z = We(() => {
|
|
250529
250544
|
var ye, we;
|
|
250530
250545
|
if (!k) return "";
|
|
250531
250546
|
const X = t.getJSON();
|
|
@@ -250557,7 +250572,7 @@ const Aoe = () => {
|
|
|
250557
250572
|
}
|
|
250558
250573
|
return Me = (pe + H).trim(), Me && (Me = `Document context (${me} chars before, ${Z} chars after):
|
|
250559
250574
|
${Me}`), Me;
|
|
250560
|
-
}, [t, n, k]), Y =
|
|
250575
|
+
}, [t, n, k]), Y = We(async () => {
|
|
250561
250576
|
var X;
|
|
250562
250577
|
if (u.trim())
|
|
250563
250578
|
try {
|
|
@@ -250614,7 +250629,7 @@ User prompt: ${u} /no_think` : `${u} /no_think`;
|
|
|
250614
250629
|
z,
|
|
250615
250630
|
k,
|
|
250616
250631
|
r
|
|
250617
|
-
]), oe =
|
|
250632
|
+
]), oe = We(() => {
|
|
250618
250633
|
if (B.current) {
|
|
250619
250634
|
B.current.abort(), l(!1), a(!1);
|
|
250620
250635
|
const X = setTimeout(() => {
|
|
@@ -250626,7 +250641,7 @@ User prompt: ${u} /no_think` : `${u} /no_think`;
|
|
|
250626
250641
|
}, 0);
|
|
250627
250642
|
return () => clearTimeout(X);
|
|
250628
250643
|
}
|
|
250629
|
-
}, []), te =
|
|
250644
|
+
}, []), te = We(() => {
|
|
250630
250645
|
if (typeof n == "function") {
|
|
250631
250646
|
m(!0);
|
|
250632
250647
|
const X = setTimeout(() => {
|
|
@@ -250645,7 +250660,7 @@ User prompt: ${u} /no_think` : `${u} /no_think`;
|
|
|
250645
250660
|
}, 150);
|
|
250646
250661
|
return () => clearTimeout(X);
|
|
250647
250662
|
}
|
|
250648
|
-
}, [n, t, e.nodeSize, _, o]), K =
|
|
250663
|
+
}, [n, t, e.nodeSize, _, o]), K = We(() => {
|
|
250649
250664
|
if (typeof n == "function") {
|
|
250650
250665
|
m(!0);
|
|
250651
250666
|
const X = setTimeout(() => {
|
|
@@ -250664,14 +250679,14 @@ User prompt: ${u} /no_think` : `${u} /no_think`;
|
|
|
250664
250679
|
}, 150);
|
|
250665
250680
|
return () => clearTimeout(X);
|
|
250666
250681
|
}
|
|
250667
|
-
}, [n, t, e.nodeSize, o]), ne =
|
|
250682
|
+
}, [n, t, e.nodeSize, o]), ne = We(
|
|
250668
250683
|
(X) => {
|
|
250669
250684
|
c(X.target.value);
|
|
250670
250685
|
},
|
|
250671
250686
|
[]
|
|
250672
|
-
), ae =
|
|
250687
|
+
), ae = We(() => {
|
|
250673
250688
|
r && u !== T && r({ prompt: u });
|
|
250674
|
-
}, [r, u, T]), ue =
|
|
250689
|
+
}, [r, u, T]), ue = We(
|
|
250675
250690
|
(X) => {
|
|
250676
250691
|
r == null || r({ model: X });
|
|
250677
250692
|
const de = O == null ? void 0 : O.defaultModels.find(
|
|
@@ -250680,22 +250695,22 @@ User prompt: ${u} /no_think` : `${u} /no_think`;
|
|
|
250680
250695
|
de && (O != null && O.setActiveModel) && O.setActiveModel(de);
|
|
250681
250696
|
},
|
|
250682
250697
|
[r, O]
|
|
250683
|
-
), P =
|
|
250698
|
+
), P = We(() => {
|
|
250684
250699
|
var de, Fe;
|
|
250685
250700
|
if (r == null || r({ content: "" }), f(!1), p(""), !I.current) return;
|
|
250686
250701
|
(de = I.current) == null || de.focus();
|
|
250687
250702
|
const X = I.current.value.length;
|
|
250688
250703
|
(Fe = I.current) == null || Fe.setSelectionRange(X, X), I.current.scrollTop = I.current.scrollHeight;
|
|
250689
|
-
}, [r]), J =
|
|
250704
|
+
}, [r]), J = We(() => {
|
|
250690
250705
|
b(!0);
|
|
250691
|
-
}, []), re =
|
|
250706
|
+
}, []), re = We(() => {
|
|
250692
250707
|
if (q) {
|
|
250693
250708
|
const X = q.getHTML();
|
|
250694
250709
|
b(!1), r == null || r({ content: X }), p(X);
|
|
250695
250710
|
}
|
|
250696
|
-
}, [q, r]), fe =
|
|
250711
|
+
}, [q, r]), fe = We(() => {
|
|
250697
250712
|
b(!1), q && q.commands.setContent(h || _ || "");
|
|
250698
|
-
}, [q, h, _]), R =
|
|
250713
|
+
}, [q, h, _]), R = We(
|
|
250699
250714
|
(X) => {
|
|
250700
250715
|
X.key === "Enter" && (X.ctrlKey || X.metaKey) && !X.shiftKey ? (X.preventDefault(), d && te()) : X.key === "Enter" && !X.shiftKey && !y ? (X.preventDefault(), u.trim() && Y()) : X.key === "Escape" ? (X.preventDefault(), s ? oe() : K()) : X.key === " " && !u.trim() ? (X.preventDefault(), K()) : X.key === "r" && (X.ctrlKey || X.metaKey) ? (X.preventDefault(), P()) : X.key === "e" && (X.ctrlKey || X.metaKey) && (X.preventDefault(), J());
|
|
250701
250716
|
},
|
|
@@ -250711,7 +250726,7 @@ User prompt: ${u} /no_think` : `${u} /no_think`;
|
|
|
250711
250726
|
s,
|
|
250712
250727
|
oe
|
|
250713
250728
|
]
|
|
250714
|
-
), le =
|
|
250729
|
+
), le = We((X) => {
|
|
250715
250730
|
X ? localStorage.setItem("include-ddoc-context", "true") : localStorage.removeItem("include-ddoc-context");
|
|
250716
250731
|
}, []);
|
|
250717
250732
|
He(() => {
|
|
@@ -250745,7 +250760,7 @@ User prompt: ${u} /no_think` : `${u} /no_think`;
|
|
|
250745
250760
|
return () => clearInterval(X);
|
|
250746
250761
|
}
|
|
250747
250762
|
}, [i]);
|
|
250748
|
-
const ce =
|
|
250763
|
+
const ce = We(
|
|
250749
250764
|
() => /* @__PURE__ */ E.jsx("span", { className: "text-body-sm color-text-secondary pt-1 flex items-center gap-1", children: /* @__PURE__ */ E.jsx(ym, { mode: "wait", children: /* @__PURE__ */ E.jsxs(
|
|
250750
250765
|
"span",
|
|
250751
250766
|
{
|
|
@@ -255790,17 +255805,17 @@ var FV = class extends Event {
|
|
|
255790
255805
|
// biome-ignore lint/suspicious/noExplicitAny: vibes
|
|
255791
255806
|
constructor(t, n) {
|
|
255792
255807
|
super("error", n);
|
|
255793
|
-
|
|
255794
|
-
|
|
255808
|
+
ct(this, "message");
|
|
255809
|
+
ct(this, "error");
|
|
255795
255810
|
this.message = t.message, this.error = t;
|
|
255796
255811
|
}
|
|
255797
255812
|
}, hFe = class extends Event {
|
|
255798
255813
|
// biome-ignore lint/suspicious/noExplicitAny: legacy
|
|
255799
255814
|
constructor(t = 1e3, n = "", r) {
|
|
255800
255815
|
super("close", r);
|
|
255801
|
-
|
|
255802
|
-
|
|
255803
|
-
|
|
255816
|
+
ct(this, "code");
|
|
255817
|
+
ct(this, "reason");
|
|
255818
|
+
ct(this, "wasClean", !0);
|
|
255804
255819
|
this.code = t, this.reason = n;
|
|
255805
255820
|
}
|
|
255806
255821
|
}, oj = {
|
|
@@ -255835,37 +255850,37 @@ var Yoe, O_n = typeof process < "u" && typeof ((Yoe = process.versions) == null
|
|
|
255835
255850
|
}, Xoe = !1, R_n = class df extends EventTarget {
|
|
255836
255851
|
constructor(n, r, o = {}) {
|
|
255837
255852
|
super();
|
|
255838
|
-
|
|
255839
|
-
|
|
255840
|
-
|
|
255841
|
-
|
|
255842
|
-
|
|
255843
|
-
|
|
255844
|
-
|
|
255845
|
-
|
|
255846
|
-
|
|
255847
|
-
|
|
255848
|
-
|
|
255849
|
-
|
|
255850
|
-
|
|
255853
|
+
ct(this, "_ws");
|
|
255854
|
+
ct(this, "_retryCount", -1);
|
|
255855
|
+
ct(this, "_uptimeTimeout");
|
|
255856
|
+
ct(this, "_connectTimeout");
|
|
255857
|
+
ct(this, "_shouldReconnect", !0);
|
|
255858
|
+
ct(this, "_connectLock", !1);
|
|
255859
|
+
ct(this, "_binaryType", "blob");
|
|
255860
|
+
ct(this, "_closeCalled", !1);
|
|
255861
|
+
ct(this, "_messageQueue", []);
|
|
255862
|
+
ct(this, "_debugLogger", console.log.bind(console));
|
|
255863
|
+
ct(this, "_url");
|
|
255864
|
+
ct(this, "_protocols");
|
|
255865
|
+
ct(this, "_options");
|
|
255851
255866
|
/**
|
|
255852
255867
|
* An event listener to be called when the WebSocket connection's readyState changes to CLOSED
|
|
255853
255868
|
*/
|
|
255854
|
-
|
|
255869
|
+
ct(this, "onclose", null);
|
|
255855
255870
|
/**
|
|
255856
255871
|
* An event listener to be called when an error occurs
|
|
255857
255872
|
*/
|
|
255858
|
-
|
|
255873
|
+
ct(this, "onerror", null);
|
|
255859
255874
|
/**
|
|
255860
255875
|
* An event listener to be called when a message is received from the server
|
|
255861
255876
|
*/
|
|
255862
|
-
|
|
255877
|
+
ct(this, "onmessage", null);
|
|
255863
255878
|
/**
|
|
255864
255879
|
* An event listener to be called when the WebSocket connection's readyState changes to OPEN;
|
|
255865
255880
|
* this indicates that the connection is ready to send and receive data
|
|
255866
255881
|
*/
|
|
255867
|
-
|
|
255868
|
-
|
|
255882
|
+
ct(this, "onopen", null);
|
|
255883
|
+
ct(this, "_handleOpen", (n) => {
|
|
255869
255884
|
this._debug("open event");
|
|
255870
255885
|
const { minUptime: r = Q0.minUptime } = this._options;
|
|
255871
255886
|
clearTimeout(this._connectTimeout), this._uptimeTimeout = setTimeout(() => this._acceptOpen(), r), __n(this._ws, "WebSocket is not defined"), this._ws.binaryType = this._binaryType, this._messageQueue.forEach((o) => {
|
|
@@ -255873,13 +255888,13 @@ var Yoe, O_n = typeof process < "u" && typeof ((Yoe = process.versions) == null
|
|
|
255873
255888
|
(i = this._ws) == null || i.send(o);
|
|
255874
255889
|
}), this._messageQueue = [], this.onopen && this.onopen(n), this.dispatchEvent(qx(n));
|
|
255875
255890
|
});
|
|
255876
|
-
|
|
255891
|
+
ct(this, "_handleMessage", (n) => {
|
|
255877
255892
|
this._debug("message event"), this.onmessage && this.onmessage(n), this.dispatchEvent(qx(n));
|
|
255878
255893
|
});
|
|
255879
|
-
|
|
255894
|
+
ct(this, "_handleError", (n) => {
|
|
255880
255895
|
this._debug("error event", n.message), this._disconnect(void 0, n.message === "TIMEOUT" ? "timeout" : void 0), this.onerror && this.onerror(n), this._debug("exec error listeners"), this.dispatchEvent(qx(n)), this._connect();
|
|
255881
255896
|
});
|
|
255882
|
-
|
|
255897
|
+
ct(this, "_handleClose", (n) => {
|
|
255883
255898
|
this._debug("close event"), this._clearTimeouts(), this._shouldReconnect && this._connect(), this.onclose && this.onclose(n), this.dispatchEvent(qx(n));
|
|
255884
255899
|
});
|
|
255885
255900
|
this._url = n, this._protocols = r, this._options = o, this._options.startClosed && (this._shouldReconnect = !1), this._options.debugLogger && (this._debugLogger = this._options.debugLogger), this._connect();
|
|
@@ -257278,8 +257293,8 @@ var MFe = {};
|
|
|
257278
257293
|
ne[P] = ae[P] - ue[P];
|
|
257279
257294
|
}
|
|
257280
257295
|
function C(ne, ae, ue) {
|
|
257281
|
-
let P, J, re = 0, fe = 0, R = 0, le = 0, ce = 0, ee = 0, X = 0, de = 0, Fe = 0, Me = 0, ge = 0, pe = 0, me = 0, be = 0, H = 0, Z = 0, se = 0, ye = 0, we = 0, xe = 0, Se = 0, Le = 0, ve = 0, Be = 0, Ae = 0, Ue = 0,
|
|
257282
|
-
P = ae[0], re += P * ze, fe += P * Ge, R += P * at, le += P * st, ce += P *
|
|
257296
|
+
let P, J, re = 0, fe = 0, R = 0, le = 0, ce = 0, ee = 0, X = 0, de = 0, Fe = 0, Me = 0, ge = 0, pe = 0, me = 0, be = 0, H = 0, Z = 0, se = 0, ye = 0, we = 0, xe = 0, Se = 0, Le = 0, ve = 0, Be = 0, Ae = 0, Ue = 0, Ve = 0, $e = 0, Ke = 0, ut = 0, Oe = 0, ze = ue[0], Ge = ue[1], at = ue[2], st = ue[3], ht = ue[4], Mt = ue[5], At = ue[6], Lt = ue[7], Nt = ue[8], ln = ue[9], Tn = ue[10], Dn = ue[11], zn = ue[12], dr = ue[13], Q = ue[14], Ee = ue[15];
|
|
257297
|
+
P = ae[0], re += P * ze, fe += P * Ge, R += P * at, le += P * st, ce += P * ht, ee += P * Mt, X += P * At, de += P * Lt, Fe += P * Nt, Me += P * ln, ge += P * Tn, pe += P * Dn, me += P * zn, be += P * dr, H += P * Q, Z += P * Ee, P = ae[1], fe += P * ze, R += P * Ge, le += P * at, ce += P * st, ee += P * ht, X += P * Mt, de += P * At, Fe += P * Lt, Me += P * Nt, ge += P * ln, pe += P * Tn, me += P * Dn, be += P * zn, H += P * dr, Z += P * Q, se += P * Ee, P = ae[2], R += P * ze, le += P * Ge, ce += P * at, ee += P * st, X += P * ht, de += P * Mt, Fe += P * At, Me += P * Lt, ge += P * Nt, pe += P * ln, me += P * Tn, be += P * Dn, H += P * zn, Z += P * dr, se += P * Q, ye += P * Ee, P = ae[3], le += P * ze, ce += P * Ge, ee += P * at, X += P * st, de += P * ht, Fe += P * Mt, Me += P * At, ge += P * Lt, pe += P * Nt, me += P * ln, be += P * Tn, H += P * Dn, Z += P * zn, se += P * dr, ye += P * Q, we += P * Ee, P = ae[4], ce += P * ze, ee += P * Ge, X += P * at, de += P * st, Fe += P * ht, Me += P * Mt, ge += P * At, pe += P * Lt, me += P * Nt, be += P * ln, H += P * Tn, Z += P * Dn, se += P * zn, ye += P * dr, we += P * Q, xe += P * Ee, P = ae[5], ee += P * ze, X += P * Ge, de += P * at, Fe += P * st, Me += P * ht, ge += P * Mt, pe += P * At, me += P * Lt, be += P * Nt, H += P * ln, Z += P * Tn, se += P * Dn, ye += P * zn, we += P * dr, xe += P * Q, Se += P * Ee, P = ae[6], X += P * ze, de += P * Ge, Fe += P * at, Me += P * st, ge += P * ht, pe += P * Mt, me += P * At, be += P * Lt, H += P * Nt, Z += P * ln, se += P * Tn, ye += P * Dn, we += P * zn, xe += P * dr, Se += P * Q, Le += P * Ee, P = ae[7], de += P * ze, Fe += P * Ge, Me += P * at, ge += P * st, pe += P * ht, me += P * Mt, be += P * At, H += P * Lt, Z += P * Nt, se += P * ln, ye += P * Tn, we += P * Dn, xe += P * zn, Se += P * dr, Le += P * Q, ve += P * Ee, P = ae[8], Fe += P * ze, Me += P * Ge, ge += P * at, pe += P * st, me += P * ht, be += P * Mt, H += P * At, Z += P * Lt, se += P * Nt, ye += P * ln, we += P * Tn, xe += P * Dn, Se += P * zn, Le += P * dr, ve += P * Q, Be += P * Ee, P = ae[9], Me += P * ze, ge += P * Ge, pe += P * at, me += P * st, be += P * ht, H += P * Mt, Z += P * At, se += P * Lt, ye += P * Nt, we += P * ln, xe += P * Tn, Se += P * Dn, Le += P * zn, ve += P * dr, Be += P * Q, Ae += P * Ee, P = ae[10], ge += P * ze, pe += P * Ge, me += P * at, be += P * st, H += P * ht, Z += P * Mt, se += P * At, ye += P * Lt, we += P * Nt, xe += P * ln, Se += P * Tn, Le += P * Dn, ve += P * zn, Be += P * dr, Ae += P * Q, Ue += P * Ee, P = ae[11], pe += P * ze, me += P * Ge, be += P * at, H += P * st, Z += P * ht, se += P * Mt, ye += P * At, we += P * Lt, xe += P * Nt, Se += P * ln, Le += P * Tn, ve += P * Dn, Be += P * zn, Ae += P * dr, Ue += P * Q, Ve += P * Ee, P = ae[12], me += P * ze, be += P * Ge, H += P * at, Z += P * st, se += P * ht, ye += P * Mt, we += P * At, xe += P * Lt, Se += P * Nt, Le += P * ln, ve += P * Tn, Be += P * Dn, Ae += P * zn, Ue += P * dr, Ve += P * Q, $e += P * Ee, P = ae[13], be += P * ze, H += P * Ge, Z += P * at, se += P * st, ye += P * ht, we += P * Mt, xe += P * At, Se += P * Lt, Le += P * Nt, ve += P * ln, Be += P * Tn, Ae += P * Dn, Ue += P * zn, Ve += P * dr, $e += P * Q, Ke += P * Ee, P = ae[14], H += P * ze, Z += P * Ge, se += P * at, ye += P * st, we += P * ht, xe += P * Mt, Se += P * At, Le += P * Lt, ve += P * Nt, Be += P * ln, Ae += P * Tn, Ue += P * Dn, Ve += P * zn, $e += P * dr, Ke += P * Q, ut += P * Ee, P = ae[15], Z += P * ze, se += P * Ge, ye += P * at, we += P * st, xe += P * ht, Se += P * Mt, Le += P * At, ve += P * Lt, Be += P * Nt, Ae += P * ln, Ue += P * Tn, Ve += P * Dn, $e += P * zn, Ke += P * dr, ut += P * Q, Oe += P * Ee, re += 38 * se, fe += 38 * ye, R += 38 * we, le += 38 * xe, ce += 38 * Se, ee += 38 * Le, X += 38 * ve, de += 38 * Be, Fe += 38 * Ae, Me += 38 * Ue, ge += 38 * Ve, pe += 38 * $e, me += 38 * Ke, be += 38 * ut, H += 38 * Oe, J = 1, P = re + J + 65535, J = Math.floor(P / 65536), re = P - J * 65536, P = fe + J + 65535, J = Math.floor(P / 65536), fe = P - J * 65536, P = R + J + 65535, J = Math.floor(P / 65536), R = P - J * 65536, P = le + J + 65535, J = Math.floor(P / 65536), le = P - J * 65536, P = ce + J + 65535, J = Math.floor(P / 65536), ce = P - J * 65536, P = ee + J + 65535, J = Math.floor(P / 65536), ee = P - J * 65536, P = X + J + 65535, J = Math.floor(P / 65536), X = P - J * 65536, P = de + J + 65535, J = Math.floor(P / 65536), de = P - J * 65536, P = Fe + J + 65535, J = Math.floor(P / 65536), Fe = P - J * 65536, P = Me + J + 65535, J = Math.floor(P / 65536), Me = P - J * 65536, P = ge + J + 65535, J = Math.floor(P / 65536), ge = P - J * 65536, P = pe + J + 65535, J = Math.floor(P / 65536), pe = P - J * 65536, P = me + J + 65535, J = Math.floor(P / 65536), me = P - J * 65536, P = be + J + 65535, J = Math.floor(P / 65536), be = P - J * 65536, P = H + J + 65535, J = Math.floor(P / 65536), H = P - J * 65536, P = Z + J + 65535, J = Math.floor(P / 65536), Z = P - J * 65536, re += J - 1 + 37 * (J - 1), J = 1, P = re + J + 65535, J = Math.floor(P / 65536), re = P - J * 65536, P = fe + J + 65535, J = Math.floor(P / 65536), fe = P - J * 65536, P = R + J + 65535, J = Math.floor(P / 65536), R = P - J * 65536, P = le + J + 65535, J = Math.floor(P / 65536), le = P - J * 65536, P = ce + J + 65535, J = Math.floor(P / 65536), ce = P - J * 65536, P = ee + J + 65535, J = Math.floor(P / 65536), ee = P - J * 65536, P = X + J + 65535, J = Math.floor(P / 65536), X = P - J * 65536, P = de + J + 65535, J = Math.floor(P / 65536), de = P - J * 65536, P = Fe + J + 65535, J = Math.floor(P / 65536), Fe = P - J * 65536, P = Me + J + 65535, J = Math.floor(P / 65536), Me = P - J * 65536, P = ge + J + 65535, J = Math.floor(P / 65536), ge = P - J * 65536, P = pe + J + 65535, J = Math.floor(P / 65536), pe = P - J * 65536, P = me + J + 65535, J = Math.floor(P / 65536), me = P - J * 65536, P = be + J + 65535, J = Math.floor(P / 65536), be = P - J * 65536, P = H + J + 65535, J = Math.floor(P / 65536), H = P - J * 65536, P = Z + J + 65535, J = Math.floor(P / 65536), Z = P - J * 65536, re += J - 1 + 37 * (J - 1), ne[0] = re, ne[1] = fe, ne[2] = R, ne[3] = le, ne[4] = ce, ne[5] = ee, ne[6] = X, ne[7] = de, ne[8] = Fe, ne[9] = Me, ne[10] = ge, ne[11] = pe, ne[12] = me, ne[13] = be, ne[14] = H, ne[15] = Z;
|
|
257283
257298
|
}
|
|
257284
257299
|
function D(ne, ae) {
|
|
257285
257300
|
C(ne, ae, ae);
|
|
@@ -257740,8 +257755,8 @@ var NFe = { exports: {} };
|
|
|
257740
257755
|
var se = H.length, ye = Z.length, we = se + ye, xe = y(we), Se = r, Le, ve, Be, Ae, Ue;
|
|
257741
257756
|
for (Be = 0; Be < se; ++Be) {
|
|
257742
257757
|
Ae = H[Be];
|
|
257743
|
-
for (var
|
|
257744
|
-
Ue = Z[
|
|
257758
|
+
for (var Ve = 0; Ve < ye; ++Ve)
|
|
257759
|
+
Ue = Z[Ve], Le = Ae * Ue + xe[Be + Ve], ve = Math.floor(Le / Se), xe[Be + Ve] = Le - ve * Se, xe[Be + Ve + 1] += ve;
|
|
257745
257760
|
}
|
|
257746
257761
|
return m(xe), xe;
|
|
257747
257762
|
}
|
|
@@ -257810,14 +257825,14 @@ var NFe = { exports: {} };
|
|
|
257810
257825
|
return new f(this.value * this.value);
|
|
257811
257826
|
};
|
|
257812
257827
|
function N(H, Z) {
|
|
257813
|
-
var se = H.length, ye = Z.length, we = r, xe = y(Z.length), Se = Z[ye - 1], Le = Math.ceil(we / (2 * Se)), ve = _(H, Le), Be = _(Z, Le), Ae, Ue, $e,
|
|
257828
|
+
var se = H.length, ye = Z.length, we = r, xe = y(Z.length), Se = Z[ye - 1], Le = Math.ceil(we / (2 * Se)), ve = _(H, Le), Be = _(Z, Le), Ae, Ue, Ve, $e, Ke, ut, Oe;
|
|
257814
257829
|
for (ve.length <= se && ve.push(0), Be.push(0), Se = Be[ye - 1], Ue = se - ye; Ue >= 0; Ue--) {
|
|
257815
|
-
for (Ae = we - 1, ve[Ue + ye] !== Se && (Ae = Math.floor((ve[Ue + ye] * we + ve[Ue + ye - 1]) / Se)),
|
|
257816
|
-
|
|
257817
|
-
for (;
|
|
257818
|
-
for (Ae -= 1,
|
|
257819
|
-
|
|
257820
|
-
|
|
257830
|
+
for (Ae = we - 1, ve[Ue + ye] !== Se && (Ae = Math.floor((ve[Ue + ye] * we + ve[Ue + ye - 1]) / Se)), Ve = 0, $e = 0, ut = Be.length, Ke = 0; Ke < ut; Ke++)
|
|
257831
|
+
Ve += Ae * Be[Ke], Oe = Math.floor(Ve / we), $e += ve[Ue + Ke] - (Ve - Oe * we), Ve = Oe, $e < 0 ? (ve[Ue + Ke] = $e + we, $e = -1) : (ve[Ue + Ke] = $e, $e = 0);
|
|
257832
|
+
for (; $e !== 0; ) {
|
|
257833
|
+
for (Ae -= 1, Ve = 0, Ke = 0; Ke < ut; Ke++)
|
|
257834
|
+
Ve += ve[Ue + Ke] - we + Be[Ke], Ve < 0 ? (ve[Ue + Ke] = Ve + we, Ve = 0) : (ve[Ue + Ke] = Ve, Ve = 1);
|
|
257835
|
+
$e += Ve;
|
|
257821
257836
|
}
|
|
257822
257837
|
xe[Ue] = Ae;
|
|
257823
257838
|
}
|
|
@@ -257867,8 +257882,8 @@ var NFe = { exports: {} };
|
|
|
257867
257882
|
if (Be === -1) return [u[0], H];
|
|
257868
257883
|
if (Be === 0) return [u[H.sign === ye.sign ? 1 : -1], u[0]];
|
|
257869
257884
|
we.length + xe.length <= 200 ? se = N(we, xe) : se = O(we, xe), Se = se[0];
|
|
257870
|
-
var Ae = H.sign !== ye.sign, Ue = se[1],
|
|
257871
|
-
return typeof Se == "number" ? (Ae && (Se = -Se), Se = new d(Se)) : Se = new c(Se, Ae), typeof Ue == "number" ? (
|
|
257885
|
+
var Ae = H.sign !== ye.sign, Ue = se[1], Ve = H.sign;
|
|
257886
|
+
return typeof Se == "number" ? (Ae && (Se = -Se), Se = new d(Se)) : Se = new c(Se, Ae), typeof Ue == "number" ? (Ve && (Ue = -Ue), Ue = new d(Ue)) : Ue = new c(Ue, Ve), [Se, Ue];
|
|
257872
257887
|
}
|
|
257873
257888
|
c.prototype.divmod = function(H) {
|
|
257874
257889
|
var Z = U(this, H);
|
|
@@ -258088,9 +258103,9 @@ var NFe = { exports: {} };
|
|
|
258088
258103
|
Z = me(Z);
|
|
258089
258104
|
for (var ye = H.isNegative(), we = Z.isNegative(), xe = ye ? H.not() : H, Se = we ? Z.not() : Z, Le = 0, ve = 0, Be = null, Ae = null, Ue = []; !xe.isZero() || !Se.isZero(); )
|
|
258090
258105
|
Be = U(xe, te), Le = Be[1].toJSNumber(), ye && (Le = te - 1 - Le), Ae = U(Se, te), ve = Ae[1].toJSNumber(), we && (ve = te - 1 - ve), xe = Be[0], Se = Ae[0], Ue.push(se(Le, ve));
|
|
258091
|
-
for (var
|
|
258092
|
-
|
|
258093
|
-
return
|
|
258106
|
+
for (var Ve = se(ye ? 1 : 0, we ? 1 : 0) !== 0 ? t(-1) : t(0), $e = Ue.length - 1; $e >= 0; $e -= 1)
|
|
258107
|
+
Ve = Ve.multiply(te).add(t(Ue[$e]));
|
|
258108
|
+
return Ve;
|
|
258094
258109
|
}
|
|
258095
258110
|
c.prototype.not = function() {
|
|
258096
258111
|
return this.negate().prev();
|
|
@@ -258152,8 +258167,8 @@ var NFe = { exports: {} };
|
|
|
258152
258167
|
var ye = se || Math.random, we = fe(H, Z), xe = re(H, Z), Se = xe.subtract(we).add(1);
|
|
258153
258168
|
if (Se.isSmall) return we.add(Math.floor(ye() * Se));
|
|
258154
258169
|
for (var Le = Fe(Se, r).value, ve = [], Be = !0, Ae = 0; Ae < Le.length; Ae++) {
|
|
258155
|
-
var Ue = Be ? Le[Ae] + (Ae + 1 < Le.length ? Le[Ae + 1] / r : 0) : r,
|
|
258156
|
-
ve.push(
|
|
258170
|
+
var Ue = Be ? Le[Ae] + (Ae + 1 < Le.length ? Le[Ae + 1] / r : 0) : r, Ve = b(ye() * Ue);
|
|
258171
|
+
ve.push(Ve), Ve < Le[Ae] && (Be = !1);
|
|
258157
258172
|
}
|
|
258158
258173
|
return we.add(u.fromArray(ve, r, !1));
|
|
258159
258174
|
}
|
|
@@ -259670,25 +259685,25 @@ class qOn {
|
|
|
259670
259685
|
// indicates whether the hash was finalized
|
|
259671
259686
|
constructor() {
|
|
259672
259687
|
/** Length of hash output */
|
|
259673
|
-
|
|
259688
|
+
ct(this, "digestLength", HOn);
|
|
259674
259689
|
/** Block size */
|
|
259675
|
-
|
|
259690
|
+
ct(this, "blockSize", yie);
|
|
259676
259691
|
// Note: Int32Array is used instead of Uint32Array for performance reasons.
|
|
259677
|
-
|
|
259692
|
+
ct(this, "_stateHi", new Int32Array(8));
|
|
259678
259693
|
// hash state, high bytes
|
|
259679
|
-
|
|
259694
|
+
ct(this, "_stateLo", new Int32Array(8));
|
|
259680
259695
|
// hash state, low bytes
|
|
259681
|
-
|
|
259696
|
+
ct(this, "_tempHi", new Int32Array(16));
|
|
259682
259697
|
// temporary state, high bytes
|
|
259683
|
-
|
|
259698
|
+
ct(this, "_tempLo", new Int32Array(16));
|
|
259684
259699
|
// temporary state, low bytes
|
|
259685
|
-
|
|
259700
|
+
ct(this, "_buffer", new Uint8Array(256));
|
|
259686
259701
|
// buffer for data to hash
|
|
259687
|
-
|
|
259702
|
+
ct(this, "_bufferLength", 0);
|
|
259688
259703
|
// number of bytes in buffer
|
|
259689
|
-
|
|
259704
|
+
ct(this, "_bytesHashed", 0);
|
|
259690
259705
|
// number of total bytes hashed
|
|
259691
|
-
|
|
259706
|
+
ct(this, "_finished", !1);
|
|
259692
259707
|
this.reset();
|
|
259693
259708
|
}
|
|
259694
259709
|
_initState() {
|
|
@@ -260165,32 +260180,32 @@ function QOn(e) {
|
|
|
260165
260180
|
}
|
|
260166
260181
|
class eRn {
|
|
260167
260182
|
constructor(t) {
|
|
260168
|
-
|
|
260169
|
-
|
|
260170
|
-
|
|
260171
|
-
|
|
260172
|
-
|
|
260173
|
-
|
|
260174
|
-
|
|
260175
|
-
|
|
260176
|
-
|
|
260177
|
-
|
|
260178
|
-
|
|
260179
|
-
|
|
260180
|
-
|
|
260181
|
-
|
|
260182
|
-
|
|
260183
|
-
|
|
260184
|
-
|
|
260185
|
-
|
|
260186
|
-
|
|
260187
|
-
|
|
260188
|
-
|
|
260189
|
-
|
|
260190
|
-
|
|
260183
|
+
ct(this, "_websocketUrl");
|
|
260184
|
+
ct(this, "_machineEventHandler", null);
|
|
260185
|
+
ct(this, "_onConnect", null);
|
|
260186
|
+
ct(this, "_onDisconnection", null);
|
|
260187
|
+
ct(this, "_onHandShakeError", null);
|
|
260188
|
+
ct(this, "_sequenceCallbackMap", {});
|
|
260189
|
+
ct(this, "_webSocketStatus", Io.CLOSED);
|
|
260190
|
+
ct(this, "_webSocket", null);
|
|
260191
|
+
ct(this, "_websocketServiceDid", "");
|
|
260192
|
+
ct(this, "roomId", "");
|
|
260193
|
+
ct(this, "roomMembers", []);
|
|
260194
|
+
ct(this, "collaborationKeyPair", null);
|
|
260195
|
+
ct(this, "ownerKeyPair");
|
|
260196
|
+
ct(this, "contractAddress");
|
|
260197
|
+
ct(this, "ownerUcan");
|
|
260198
|
+
ct(this, "collaborationUcan");
|
|
260199
|
+
ct(this, "ownerAddress");
|
|
260200
|
+
ct(this, "roomKey");
|
|
260201
|
+
ct(this, "roomInfo");
|
|
260202
|
+
ct(this, "awareness", null);
|
|
260203
|
+
ct(this, "_onError", null);
|
|
260204
|
+
ct(this, "_onCollaborationConnectCallback", null);
|
|
260205
|
+
ct(this, "disconnect", (t, n) => {
|
|
260191
260206
|
this._webSocketStatus = Io.CLOSED, this._webSocket && (this._webSocket.onopen = null, this._webSocket.removeEventListener("message", this._processMessage), this._webSocket.close(n, t), this._webSocketStatus = Io.CLOSED);
|
|
260192
260207
|
});
|
|
260193
|
-
|
|
260208
|
+
ct(this, "terminateSession", async () => {
|
|
260194
260209
|
var r;
|
|
260195
260210
|
const n = {
|
|
260196
260211
|
ownerToken: await this.getOwnerToken(),
|
|
@@ -260200,7 +260215,7 @@ class eRn {
|
|
|
260200
260215
|
};
|
|
260201
260216
|
await this._buildRequest("/documents/terminate", n), this.disconnect("Session terminated", 1e3);
|
|
260202
260217
|
});
|
|
260203
|
-
|
|
260218
|
+
ct(this, "buildSessionToken", async () => {
|
|
260204
260219
|
if (!this._websocketServiceDid)
|
|
260205
260220
|
throw new Error(
|
|
260206
260221
|
"SocketClient: Server did not response with the server DID"
|
|
@@ -260225,7 +260240,7 @@ class eRn {
|
|
|
260225
260240
|
]
|
|
260226
260241
|
}), za(this.collaborationUcan);
|
|
260227
260242
|
});
|
|
260228
|
-
|
|
260243
|
+
ct(this, "_handleHandShake", async (t) => {
|
|
260229
260244
|
var s, l, u, c;
|
|
260230
260245
|
if (this._websocketServiceDid = t.data.server_did, this._webSocketStatus !== Io.CONNECTED || !this.roomId)
|
|
260231
260246
|
throw new Error(
|
|
@@ -260262,14 +260277,14 @@ class eRn {
|
|
|
260262
260277
|
}
|
|
260263
260278
|
(c = this._onConnect) == null || c.call(this);
|
|
260264
260279
|
});
|
|
260265
|
-
|
|
260280
|
+
ct(this, "_executeRequestCallback", (t) => {
|
|
260266
260281
|
const n = this._getSequenceIdCallback(t.seqId);
|
|
260267
260282
|
if (n && typeof n.callback == "function") {
|
|
260268
260283
|
this._removeSequenceIdFromMap(t.seqId), delete t.seqId, n.callback(t);
|
|
260269
260284
|
return;
|
|
260270
260285
|
}
|
|
260271
260286
|
});
|
|
260272
|
-
|
|
260287
|
+
ct(this, "_dispatchEventHandler", async (t) => {
|
|
260273
260288
|
switch (t.type) {
|
|
260274
260289
|
case "ROOM_UPDATE": {
|
|
260275
260290
|
t.event_type === "ROOM_MEMBERSHIP_CHANGE" && await this._fetchRoomMembers();
|
|
@@ -260281,10 +260296,10 @@ class eRn {
|
|
|
260281
260296
|
}
|
|
260282
260297
|
}
|
|
260283
260298
|
});
|
|
260284
|
-
|
|
260299
|
+
ct(this, "_onSessionTerminated", () => {
|
|
260285
260300
|
this.disconnect("Session terminated", 1e3), this.resetSocketClient();
|
|
260286
260301
|
});
|
|
260287
|
-
|
|
260302
|
+
ct(this, "resetSocketClient", () => {
|
|
260288
260303
|
this._webSocketStatus = Io.CLOSED, this._webSocket = null, this._websocketServiceDid = "", this.roomId = "", this.roomMembers = [];
|
|
260289
260304
|
});
|
|
260290
260305
|
this._websocketUrl = t.wsUrl || "ws://localhost:5000", this._processMessage = this._processMessage.bind(this);
|
|
@@ -261285,11 +261300,11 @@ function HRn(e) {
|
|
|
261285
261300
|
function qRn(e) {
|
|
261286
261301
|
for (var t = [], n = 1; n < arguments.length; n++)
|
|
261287
261302
|
t[n - 1] = arguments[n];
|
|
261288
|
-
var r = URn(t, 1), o = r[0], i = o === void 0 ? {} : o, a = ORn(e, i), s =
|
|
261303
|
+
var r = URn(t, 1), o = r[0], i = o === void 0 ? {} : o, a = ORn(e, i), s = We(function() {
|
|
261289
261304
|
return a.status === Er.NotStarted ? i.state ? ja.create(i.state) : a.machine.initialState : a.getSnapshot();
|
|
261290
|
-
}, [a]), l =
|
|
261305
|
+
}, [a]), l = We(function(d, f) {
|
|
261291
261306
|
return zRn(a, d, f);
|
|
261292
|
-
}, [a]), u =
|
|
261307
|
+
}, [a]), u = We(function(d) {
|
|
261293
261308
|
var f = a.subscribe(d).unsubscribe;
|
|
261294
261309
|
return f;
|
|
261295
261310
|
}, [a]), c = LB.useSyncExternalStoreWithSelector(u, s, s, HRn, l);
|
|
@@ -261316,10 +261331,10 @@ var WRn = function(e, t) {
|
|
|
261316
261331
|
};
|
|
261317
261332
|
function B3(e, t, n, r) {
|
|
261318
261333
|
n === void 0 && (n = WRn);
|
|
261319
|
-
var o = Qe(null), i =
|
|
261334
|
+
var o = Qe(null), i = We(function(l) {
|
|
261320
261335
|
var u = e.subscribe(l).unsubscribe;
|
|
261321
261336
|
return u;
|
|
261322
|
-
}, [e]), a =
|
|
261337
|
+
}, [e]), a = We(function() {
|
|
261323
261338
|
return $Rn(e, o);
|
|
261324
261339
|
}, [e, r]), s = LB.useSyncExternalStoreWithSelector(i, a, a, t, n);
|
|
261325
261340
|
return s;
|
|
@@ -261814,7 +261829,7 @@ const FPn = (e) => e.context.awareness, CPn = (e) => !!(e.context.isReady && e.c
|
|
|
261814
261829
|
}), r = B3(n, FPn), o = B3(n, CPn), i = B3(n, DPn), a = B3(n, MPn), s = B3(
|
|
261815
261830
|
n,
|
|
261816
261831
|
EPn
|
|
261817
|
-
), l =
|
|
261832
|
+
), l = We(
|
|
261818
261833
|
(d) => {
|
|
261819
261834
|
t({
|
|
261820
261835
|
type: "CONNECT",
|
|
@@ -261826,12 +261841,12 @@ const FPn = (e) => e.context.awareness, CPn = (e) => !!(e.context.isReady && e.c
|
|
|
261826
261841
|
},
|
|
261827
261842
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
261828
261843
|
[e.ydoc]
|
|
261829
|
-
), u =
|
|
261844
|
+
), u = We(() => {
|
|
261830
261845
|
t({
|
|
261831
261846
|
type: "DISCONNECT",
|
|
261832
261847
|
data: {}
|
|
261833
261848
|
});
|
|
261834
|
-
}, [t]), c =
|
|
261849
|
+
}, [t]), c = We(() => {
|
|
261835
261850
|
t({
|
|
261836
261851
|
type: "TERMINATE_SESSION",
|
|
261837
261852
|
data: {}
|
|
@@ -261926,7 +261941,7 @@ const FPn = (e) => e.context.awareness, CPn = (e) => !!(e.context.isReady && e.c
|
|
|
261926
261941
|
onIndexedDbError: I,
|
|
261927
261942
|
...S
|
|
261928
261943
|
}) => {
|
|
261929
|
-
var Ke,
|
|
261944
|
+
var Ke, ut;
|
|
261930
261945
|
const [L, M] = Re(!0), [j, N] = Re(!0), [O] = Re(new rc()), {
|
|
261931
261946
|
connect: B,
|
|
261932
261947
|
isReady: U,
|
|
@@ -262006,17 +262021,17 @@ const FPn = (e) => e.context.awareness, CPn = (e) => !!(e.context.isReady && e.c
|
|
|
262006
262021
|
let at = !1;
|
|
262007
262022
|
return Oe.doc.nodesBetween(ze, Ge, (st) => {
|
|
262008
262023
|
st.marks && st.marks.some(
|
|
262009
|
-
(
|
|
262024
|
+
(ht) => ht.type.name === "highlight" && ht.attrs.color === "yellow"
|
|
262010
262025
|
) && (at = !0);
|
|
262011
262026
|
}), at;
|
|
262012
262027
|
}, ee = (Oe, ze) => {
|
|
262013
262028
|
var at;
|
|
262014
262029
|
const Ge = ze.target;
|
|
262015
262030
|
if (Ge && Ge.nodeName === "MARK" && Ge.dataset.color && ((at = Ge == null ? void 0 : Ge.dataset) == null ? void 0 : at.color) === "yellow") {
|
|
262016
|
-
const st = Ge.textContent,
|
|
262017
|
-
if (
|
|
262031
|
+
const st = Ge.textContent, ht = Oe.posAtCoords({ left: ze.clientX, top: ze.clientY });
|
|
262032
|
+
if (ht) {
|
|
262018
262033
|
const { state: Mt } = Oe;
|
|
262019
|
-
let At =
|
|
262034
|
+
let At = ht.pos, Lt = ht.pos;
|
|
262020
262035
|
if (Mt.doc.nodesBetween(At, Lt, (Nt, ln) => {
|
|
262021
262036
|
Nt.marks && Nt.marks.length && Nt.marks.forEach((Tn) => {
|
|
262022
262037
|
Tn.type.name === "highlight" && (At = ln, Lt = ln + Nt.nodeSize);
|
|
@@ -262035,11 +262050,11 @@ const FPn = (e) => e.context.awareness, CPn = (e) => !!(e.context.isReady && e.c
|
|
|
262035
262050
|
}, X = (Oe, ze, Ge) => {
|
|
262036
262051
|
ee(Oe, Ge);
|
|
262037
262052
|
}, de = jt(() => J, [J]), Fe = Qe(null), Me = (Oe, ze) => {
|
|
262038
|
-
const { state: Ge } = Oe, { selection: at } = Ge, { from: st, to:
|
|
262053
|
+
const { state: Ge } = Oe, { selection: at } = Ge, { from: st, to: ht, empty: Mt } = at;
|
|
262039
262054
|
if (ze.key === "Backspace" || ze.key === "Delete") {
|
|
262040
262055
|
let At = !1;
|
|
262041
262056
|
if (!Mt)
|
|
262042
|
-
Ge.doc.nodesBetween(st,
|
|
262057
|
+
Ge.doc.nodesBetween(st, ht, (Lt) => {
|
|
262043
262058
|
Lt.type.name === "reminderBlock" && (At = !0);
|
|
262044
262059
|
});
|
|
262045
262060
|
else {
|
|
@@ -262073,8 +262088,8 @@ const FPn = (e) => e.context.awareness, CPn = (e) => !!(e.context.isReady && e.c
|
|
|
262073
262088
|
}
|
|
262074
262089
|
},
|
|
262075
262090
|
handleClick: (Oe, ze, Ge) => {
|
|
262076
|
-
const at = Ge.metaKey || Ge.ctrlKey,
|
|
262077
|
-
return at &&
|
|
262091
|
+
const at = Ge.metaKey || Ge.ctrlKey, ht = Ge.target.closest("a");
|
|
262092
|
+
return at && ht && ht.href && ht.textContent.match(Bw) ? (window.open(ht.href, "_blank"), !0) : (ht && ht.href && !ht.textContent.match(Bw) && window.open(ht.href, "_blank"), X ? X(Oe, ze, Ge) : !1);
|
|
262078
262093
|
},
|
|
262079
262094
|
attributes: {
|
|
262080
262095
|
spellCheck: "true"
|
|
@@ -262186,7 +262201,7 @@ const FPn = (e) => e.context.awareness, CPn = (e) => !!(e.context.isReady && e.c
|
|
|
262186
262201
|
}, ye = (Oe) => {
|
|
262187
262202
|
const ze = Oe.map((Ge) => ir(Ge));
|
|
262188
262203
|
h1(O, vu(ze), "self");
|
|
262189
|
-
}, we = (Oe) => Array.isArray(Oe) || typeof Oe == "string" && !lke(Oe), xe = (Oe) => Oe === null, Se = window.location.hash.startsWith("#") ? window.location.hash.substring(1) : window.location.hash, Le = new URLSearchParams(Se), ve = Le.get("heading"), Be = ve == null ? void 0 : ve.split("-").pop(), { isNativeMobile: Ae } = j1(), Ue =
|
|
262204
|
+
}, we = (Oe) => Array.isArray(Oe) || typeof Oe == "string" && !lke(Oe), xe = (Oe) => Oe === null, Se = window.location.hash.startsWith("#") ? window.location.hash.substring(1) : window.location.hash, Le = new URLSearchParams(Se), ve = Le.get("heading"), Be = ve == null ? void 0 : ve.split("-").pop(), { isNativeMobile: Ae } = j1(), Ue = We(
|
|
262190
262205
|
(Oe) => {
|
|
262191
262206
|
if (ge)
|
|
262192
262207
|
try {
|
|
@@ -262201,8 +262216,8 @@ const FPn = (e) => e.context.awareness, CPn = (e) => !!(e.context.isReady && e.c
|
|
|
262201
262216
|
Ge == null ? void 0 : Ge.textContent
|
|
262202
262217
|
), st = ve == null ? void 0 : ve.split("-").slice(0, -1).join("-");
|
|
262203
262218
|
at !== st && (Le.set("heading", `${at}-${Oe}`), window.location.hash = Le.toString());
|
|
262204
|
-
const
|
|
262205
|
-
Mt.setSelection(new kt(Mt.doc.resolve(
|
|
262219
|
+
const ht = ge.view.posAtDOM(Ge, 0), Mt = ge.view.state.tr;
|
|
262220
|
+
Mt.setSelection(new kt(Mt.doc.resolve(ht))), ge.view.dispatch(Mt);
|
|
262206
262221
|
const Lt = [
|
|
262207
262222
|
document.querySelector(".ProseMirror"),
|
|
262208
262223
|
document.getElementById("editor-canvas"),
|
|
@@ -262283,7 +262298,7 @@ const FPn = (e) => e.context.awareness, CPn = (e) => !!(e.context.isReady && e.c
|
|
|
262283
262298
|
})
|
|
262284
262299
|
);
|
|
262285
262300
|
o == null || o(Oe);
|
|
262286
|
-
}, [(
|
|
262301
|
+
}, [(ut = (Ke = ge == null ? void 0 : ge.storage) == null ? void 0 : Ke.collaborationCaret) == null ? void 0 : ut.users]), He(() => {
|
|
262287
262302
|
s && s((ge == null ? void 0 : ge.storage.characterCount.characters()) ?? 0), l && l((ge == null ? void 0 : ge.storage.characterCount.words()) ?? 0);
|
|
262288
262303
|
}, [
|
|
262289
262304
|
ge == null ? void 0 : ge.storage.characterCount.characters(),
|
|
@@ -262309,18 +262324,18 @@ const FPn = (e) => e.context.awareness, CPn = (e) => !!(e.context.isReady && e.c
|
|
|
262309
262324
|
ze.state.doc.nodesBetween(
|
|
262310
262325
|
Ge,
|
|
262311
262326
|
at,
|
|
262312
|
-
(
|
|
262313
|
-
|
|
262327
|
+
(ht, Mt) => {
|
|
262328
|
+
ht.marks && ht.marks.forEach((At) => {
|
|
262314
262329
|
At.type.name === "textStyle" && At.attrs.color && st.push({
|
|
262315
262330
|
from: Mt,
|
|
262316
|
-
to: Mt +
|
|
262331
|
+
to: Mt + ht.nodeSize,
|
|
262317
262332
|
mark: At
|
|
262318
262333
|
});
|
|
262319
262334
|
});
|
|
262320
262335
|
}
|
|
262321
|
-
), ze.chain().setTextSelection({ from: Ge, to: at }).setColor("").run(), st.forEach(({ from:
|
|
262336
|
+
), ze.chain().setTextSelection({ from: Ge, to: at }).setColor("").run(), st.forEach(({ from: ht, to: Mt, mark: At }) => {
|
|
262322
262337
|
const Lt = At.attrs.color;
|
|
262323
|
-
$Y(Lt) || ze.chain().setTextSelection({ from:
|
|
262338
|
+
$Y(Lt) || ze.chain().setTextSelection({ from: ht, to: Mt }).setColor(Lt).run();
|
|
262324
262339
|
}), ze.commands.setTextSelection(at);
|
|
262325
262340
|
}, 0);
|
|
262326
262341
|
};
|
|
@@ -262328,29 +262343,29 @@ const FPn = (e) => e.context.awareness, CPn = (e) => !!(e.context.isReady && e.c
|
|
|
262328
262343
|
ge.off("paste", Oe);
|
|
262329
262344
|
};
|
|
262330
262345
|
}, [ge]);
|
|
262331
|
-
const
|
|
262346
|
+
const Ve = Qe(localStorage.getItem("theme") !== null), $e = Qe(!1);
|
|
262332
262347
|
return He(() => {
|
|
262333
|
-
if (!(!ge || L ||
|
|
262348
|
+
if (!(!ge || L || !Ve.current || $e.current))
|
|
262334
262349
|
if (t) {
|
|
262335
262350
|
const Oe = setTimeout(() => {
|
|
262336
262351
|
if (!ge) return;
|
|
262337
262352
|
const { from: ze, to: Ge } = ge.state.selection, at = [];
|
|
262338
|
-
ge.state.doc.descendants((st,
|
|
262353
|
+
ge.state.doc.descendants((st, ht) => {
|
|
262339
262354
|
st.marks && st.marks.forEach((Mt) => {
|
|
262340
262355
|
Mt.type.name === "textStyle" && Mt.attrs.color && at.push({
|
|
262341
|
-
from:
|
|
262342
|
-
to:
|
|
262356
|
+
from: ht,
|
|
262357
|
+
to: ht + st.nodeSize,
|
|
262343
262358
|
mark: Mt
|
|
262344
262359
|
});
|
|
262345
262360
|
});
|
|
262346
|
-
}), at.length > 0 && (ge.chain().selectAll().setColor("").run(), at.forEach(({ from: st, to:
|
|
262361
|
+
}), at.length > 0 && (ge.chain().selectAll().setColor("").run(), at.forEach(({ from: st, to: ht, mark: Mt }) => {
|
|
262347
262362
|
const At = Mt.attrs.color;
|
|
262348
|
-
$Y(At) || ge.chain().setTextSelection({ from: st, to:
|
|
262349
|
-
}), ge.commands.setTextSelection({ from: ze, to: Ge })),
|
|
262363
|
+
$Y(At) || ge.chain().setTextSelection({ from: st, to: ht }).setColor(At).run();
|
|
262364
|
+
}), ge.commands.setTextSelection({ from: ze, to: Ge })), $e.current = !0;
|
|
262350
262365
|
}, 100);
|
|
262351
262366
|
return () => clearTimeout(Oe);
|
|
262352
262367
|
} else
|
|
262353
|
-
|
|
262368
|
+
$e.current = !0;
|
|
262354
262369
|
}, [ge, t, L]), {
|
|
262355
262370
|
editor: ge,
|
|
262356
262371
|
isContentLoading: Y && !(_ != null && _.isOwner) && j || L,
|
|
@@ -263200,7 +263215,7 @@ const WPn = ({
|
|
|
263200
263215
|
].includes(Y.name)
|
|
263201
263216
|
),
|
|
263202
263217
|
editable: !s
|
|
263203
|
-
}), [s]), N =
|
|
263218
|
+
}), [s]), N = We(async () => {
|
|
263204
263219
|
var ae;
|
|
263205
263220
|
if (!e || !((ae = e.view) != null && ae.dom)) return;
|
|
263206
263221
|
if (!s && e.view.dom.querySelector(".is-editor-empty")) {
|
|
@@ -263243,13 +263258,13 @@ const WPn = ({
|
|
|
263243
263258
|
He(() => {
|
|
263244
263259
|
N();
|
|
263245
263260
|
}, [e.state.doc]);
|
|
263246
|
-
const O =
|
|
263261
|
+
const O = We(() => {
|
|
263247
263262
|
C ? r((Y) => !Y) : document.fullscreenElement ? document.exitFullscreen ? document.exitFullscreen().then(() => r(!1)).catch(() => {
|
|
263248
263263
|
r(!1);
|
|
263249
263264
|
}) : r(!1) : document.documentElement.requestFullscreen ? document.documentElement.requestFullscreen().then(() => r(!0)).catch(() => {
|
|
263250
263265
|
r(!0);
|
|
263251
263266
|
}) : r(!0);
|
|
263252
|
-
}, [C]), B =
|
|
263267
|
+
}, [C]), B = We(
|
|
263253
263268
|
(Y) => {
|
|
263254
263269
|
Y.key === "ArrowRight" || Y.key === "ArrowDown" || Y.code === "Space" ? (Y.preventDefault(), Y.stopPropagation(), M("forward"), x((oe) => Math.min(oe + 1, c.length - 1))) : Y.key === "ArrowLeft" || Y.key === "ArrowUp" ? (M("backward"), x((oe) => Math.max(oe - 1, 0))) : Y.key === "Escape" ? !s && t() : (Y.key === "f" || Y.key === "F") && O();
|
|
263255
263270
|
},
|
|
@@ -263267,7 +263282,7 @@ const WPn = ({
|
|
|
263267
263282
|
I(null), T(Y.targetTouches[0].clientX);
|
|
263268
263283
|
}, $ = (Y) => {
|
|
263269
263284
|
I(Y.targetTouches[0].clientX);
|
|
263270
|
-
}, q =
|
|
263285
|
+
}, q = We(() => {
|
|
263271
263286
|
if (!D || !_) return;
|
|
263272
263287
|
const Y = D - _, oe = Y > S, te = Y < -S;
|
|
263273
263288
|
oe && (M("forward"), x((K) => Math.min(K + 1, c.length - 1))), te && (M("backward"), x((K) => Math.max(K - 1, 0)));
|
|
@@ -264017,7 +264032,7 @@ const WPn = ({
|
|
|
264017
264032
|
orientation: r
|
|
264018
264033
|
// onItemRemove,
|
|
264019
264034
|
}) => {
|
|
264020
|
-
const o =
|
|
264035
|
+
const o = We(
|
|
264021
264036
|
(s) => {
|
|
264022
264037
|
s.preventDefault(), s.stopPropagation(), t(s, e.id);
|
|
264023
264038
|
},
|
|
@@ -264059,7 +264074,7 @@ const JFe = D1(
|
|
|
264059
264074
|
const [o, i] = Re(null), a = Hr("(max-width: 1280px)"), s = Qe(null), l = Qe(0), u = Qe(null), c = jt(() => e.map((m) => ({
|
|
264060
264075
|
...m,
|
|
264061
264076
|
isActive: m.id === o
|
|
264062
|
-
})), [e, o]), d =
|
|
264077
|
+
})), [e, o]), d = We(() => {
|
|
264063
264078
|
var m;
|
|
264064
264079
|
if (t && ((m = t.view) != null && m.dom) && (!s.current || Date.now() - l.current > 250)) {
|
|
264065
264080
|
const y = /* @__PURE__ */ new Map();
|
|
@@ -264081,7 +264096,7 @@ const JFe = D1(
|
|
|
264081
264096
|
t.off("update", m), t.off("selectionUpdate", m), u.current && cancelAnimationFrame(u.current);
|
|
264082
264097
|
};
|
|
264083
264098
|
}, [t, d]);
|
|
264084
|
-
const f =
|
|
264099
|
+
const f = We(
|
|
264085
264100
|
(m) => {
|
|
264086
264101
|
if (!t) return;
|
|
264087
264102
|
const { doc: y } = t.state;
|
|
@@ -264096,7 +264111,7 @@ const JFe = D1(
|
|
|
264096
264111
|
}), b !== -1 && t.chain().setNodeSelection(b).updateAttributes("heading", { isCollapsed: !1 }).run();
|
|
264097
264112
|
},
|
|
264098
264113
|
[t]
|
|
264099
|
-
), h =
|
|
264114
|
+
), h = We(
|
|
264100
264115
|
(m) => {
|
|
264101
264116
|
if (!t) return;
|
|
264102
264117
|
f(m);
|
|
@@ -264124,7 +264139,7 @@ const JFe = D1(
|
|
|
264124
264139
|
}
|
|
264125
264140
|
},
|
|
264126
264141
|
[e, t, f]
|
|
264127
|
-
), p =
|
|
264142
|
+
), p = We(
|
|
264128
264143
|
(m, y) => {
|
|
264129
264144
|
var b;
|
|
264130
264145
|
if (m.preventDefault(), m.stopPropagation(), i(y), t && ((b = t.view) != null && b.dom)) {
|
|
@@ -264159,7 +264174,7 @@ const JFe = D1(
|
|
|
264159
264174
|
}
|
|
264160
264175
|
},
|
|
264161
264176
|
[t, h, d, a]
|
|
264162
|
-
), g =
|
|
264177
|
+
), g = We(
|
|
264163
264178
|
(m, y) => {
|
|
264164
264179
|
m.preventDefault(), m.stopPropagation(), n((b) => {
|
|
264165
264180
|
var k;
|
|
@@ -264323,15 +264338,15 @@ const Bie = _e.memo(JFe), QPn = ({
|
|
|
264323
264338
|
)) return !1;
|
|
264324
264339
|
const { state: f } = u, { selection: h } = f, p = Zw(h.$from, u.schema.marks.link);
|
|
264325
264340
|
return p ? f.doc.textBetween(p.from, p.to) === c : !1;
|
|
264326
|
-
}, i =
|
|
264341
|
+
}, i = We(() => {
|
|
264327
264342
|
const u = e.state.selection.to, c = e.getAttributes("link").href;
|
|
264328
264343
|
e.commands.extendMarkRange("link", { href: c }), e.chain().focus().setTextSelection(u).unsetMark("link").insertContent(" ").run();
|
|
264329
|
-
}, [e]), a =
|
|
264344
|
+
}, [e]), a = We(
|
|
264330
264345
|
(u) => {
|
|
264331
264346
|
r.current && r.current.contains(u.target) || i();
|
|
264332
264347
|
},
|
|
264333
264348
|
[i]
|
|
264334
|
-
), s =
|
|
264349
|
+
), s = We(
|
|
264335
264350
|
(u) => {
|
|
264336
264351
|
var p, g;
|
|
264337
264352
|
const { key: c } = u, d = document.activeElement;
|
|
@@ -264482,17 +264497,17 @@ const Bie = _e.memo(JFe), QPn = ({
|
|
|
264482
264497
|
footerHeight: Be,
|
|
264483
264498
|
ipfsImageFetchFn: Ae,
|
|
264484
264499
|
fetchV1ImageFn: Ue,
|
|
264485
|
-
activeModel:
|
|
264486
|
-
maxTokens:
|
|
264500
|
+
activeModel: Ve,
|
|
264501
|
+
maxTokens: $e,
|
|
264487
264502
|
isAIAgentEnabled: Ke,
|
|
264488
|
-
collaborationKey:
|
|
264503
|
+
collaborationKey: ut,
|
|
264489
264504
|
collaborationKeyPair: Oe,
|
|
264490
264505
|
collabConfig: ze,
|
|
264491
264506
|
// Document styling object
|
|
264492
264507
|
documentStyling: Ge,
|
|
264493
264508
|
...at
|
|
264494
264509
|
}, st) => {
|
|
264495
|
-
const [
|
|
264510
|
+
const [ht, Mt] = Re(!1), [At, Lt] = Re(!1), ln = (() => {
|
|
264496
264511
|
if (!Ge)
|
|
264497
264512
|
return { canvas: void 0, background: void 0 };
|
|
264498
264513
|
const un = {}, tn = {};
|
|
@@ -264517,7 +264532,7 @@ const Bie = _e.memo(JFe), QPn = ({
|
|
|
264517
264532
|
}, [k]);
|
|
264518
264533
|
const {
|
|
264519
264534
|
editor: Ne,
|
|
264520
|
-
ref:
|
|
264535
|
+
ref: pt,
|
|
264521
264536
|
isContentLoading: Yt,
|
|
264522
264537
|
ydoc: Ut,
|
|
264523
264538
|
refreshYjsIndexedDbProvider: Un,
|
|
@@ -264565,10 +264580,10 @@ const Bie = _e.memo(JFe), QPn = ({
|
|
|
264565
264580
|
extensions: Le,
|
|
264566
264581
|
onCopyHeadingLink: ve,
|
|
264567
264582
|
isConnected: me,
|
|
264568
|
-
activeModel:
|
|
264569
|
-
maxTokens:
|
|
264583
|
+
activeModel: Ve,
|
|
264584
|
+
maxTokens: $e,
|
|
264570
264585
|
isAIAgentEnabled: Ke,
|
|
264571
|
-
collaborationKey:
|
|
264586
|
+
collaborationKey: ut,
|
|
264572
264587
|
collaborationKeyPair: Oe,
|
|
264573
264588
|
collabConfig: ze,
|
|
264574
264589
|
...at
|
|
@@ -264688,7 +264703,7 @@ const Bie = _e.memo(JFe), QPn = ({
|
|
|
264688
264703
|
const un = Ne.view.dom;
|
|
264689
264704
|
if (!un) return;
|
|
264690
264705
|
const tn = () => {
|
|
264691
|
-
|
|
264706
|
+
pt.current && pt.current.scrollIntoView();
|
|
264692
264707
|
};
|
|
264693
264708
|
return un.addEventListener("resize", tn), () => {
|
|
264694
264709
|
un.removeEventListener("resize", tn);
|
|
@@ -264696,7 +264711,7 @@ const Bie = _e.memo(JFe), QPn = ({
|
|
|
264696
264711
|
} catch {
|
|
264697
264712
|
return;
|
|
264698
264713
|
}
|
|
264699
|
-
}, [Ne,
|
|
264714
|
+
}, [Ne, pt, bt]);
|
|
264700
264715
|
const jV = Hr("(max-width: 768px)"), LV = () => {
|
|
264701
264716
|
var un, tn;
|
|
264702
264717
|
return /* @__PURE__ */ E.jsx(ym, { children: /* @__PURE__ */ E.jsxs(E.Fragment, { children: [
|
|
@@ -264809,7 +264824,7 @@ const Bie = _e.memo(JFe), QPn = ({
|
|
|
264809
264824
|
children: /* @__PURE__ */ E.jsxs(
|
|
264810
264825
|
"div",
|
|
264811
264826
|
{
|
|
264812
|
-
ref:
|
|
264827
|
+
ref: pt,
|
|
264813
264828
|
className: St(
|
|
264814
264829
|
"w-full h-full pt-8 md:pt-0",
|
|
264815
264830
|
{ "custom-ios-padding": Dt },
|
|
@@ -264853,7 +264868,7 @@ const Bie = _e.memo(JFe), QPn = ({
|
|
|
264853
264868
|
),
|
|
264854
264869
|
/* @__PURE__ */ E.jsx(nzn, { editor: Ne })
|
|
264855
264870
|
] }),
|
|
264856
|
-
Ne && /* @__PURE__ */ E.jsx(min, { editor: Ne, appendTo:
|
|
264871
|
+
Ne && /* @__PURE__ */ E.jsx(min, { editor: Ne, appendTo: pt })
|
|
264857
264872
|
] }),
|
|
264858
264873
|
!Ne || Yt ? Fi(
|
|
264859
264874
|
/* @__PURE__ */ E.jsxs("div", { className: `${jV ? "mx-10 mt-10" : "mx-20"}`, children: [
|
|
@@ -264949,7 +264964,7 @@ const Bie = _e.memo(JFe), QPn = ({
|
|
|
264949
264964
|
className: St(
|
|
264950
264965
|
"w-full h-auto",
|
|
264951
264966
|
e && "preview-mode",
|
|
264952
|
-
|
|
264967
|
+
Ve !== void 0 && Ke && "has-available-models",
|
|
264953
264968
|
we && "hide-inline-comments"
|
|
264954
264969
|
),
|
|
264955
264970
|
...Tn() && {
|
|
@@ -264986,7 +265001,7 @@ const Bie = _e.memo(JFe), QPn = ({
|
|
|
264986
265001
|
{
|
|
264987
265002
|
className: St(
|
|
264988
265003
|
"flex mobile:hidden items-center w-full h-[52px] fixed left-0 z-10 px-4 color-bg-default transition-all duration-300 ease-in-out border-b border-color-default",
|
|
264989
|
-
|
|
265004
|
+
ht && "hidden",
|
|
264990
265005
|
{ "top-14": O, "top-0": !O }
|
|
264991
265006
|
),
|
|
264992
265007
|
children: /* @__PURE__ */ E.jsx(
|
|
@@ -264994,7 +265009,7 @@ const Bie = _e.memo(JFe), QPn = ({
|
|
|
264994
265009
|
{
|
|
264995
265010
|
onError: y,
|
|
264996
265011
|
editor: Ne,
|
|
264997
|
-
isKeyboardVisible:
|
|
265012
|
+
isKeyboardVisible: ht,
|
|
264998
265013
|
isNavbarVisible: O,
|
|
264999
265014
|
setIsNavbarVisible: B,
|
|
265000
265015
|
ipfsImageUploadFn: g,
|
|
@@ -265441,7 +265456,7 @@ const Bie = _e.memo(JFe), QPn = ({
|
|
|
265441
265456
|
({ node: e, editor: t, deleteNode: n }) => {
|
|
265442
265457
|
const r = e.attrs.reminder, [o, i] = Re(
|
|
265443
265458
|
r != null && r.timestamp ? new Date(r.timestamp).getTime() < Date.now() : !1
|
|
265444
|
-
), a = t.isEditable === !1, s =
|
|
265459
|
+
), a = t.isEditable === !1, s = We(() => {
|
|
265445
265460
|
const c = [];
|
|
265446
265461
|
return t.state.doc.descendants((d) => {
|
|
265447
265462
|
d.type.name === "reminderBlock" && c.push({
|
|
@@ -265451,7 +265466,7 @@ const Bie = _e.memo(JFe), QPn = ({
|
|
|
265451
265466
|
}), c.sort(
|
|
265452
265467
|
(d, f) => new Date(d.timestamp).getTime() - new Date(f.timestamp).getTime()
|
|
265453
265468
|
);
|
|
265454
|
-
}, [t]), l =
|
|
265469
|
+
}, [t]), l = We(
|
|
265455
265470
|
(c) => {
|
|
265456
265471
|
const d = s(), f = d.findIndex((g) => g.id === r.id);
|
|
265457
265472
|
if (f === -1) return;
|
|
@@ -265484,7 +265499,7 @@ const Bie = _e.memo(JFe), QPn = ({
|
|
|
265484
265499
|
return () => clearTimeout(h);
|
|
265485
265500
|
}
|
|
265486
265501
|
}, [o, r.timestamp]);
|
|
265487
|
-
const u =
|
|
265502
|
+
const u = We(() => {
|
|
265488
265503
|
var d;
|
|
265489
265504
|
const c = (d = t.extensionManager.extensions.find(
|
|
265490
265505
|
(f) => f.name === "reminderBlock"
|