superdoc 0.34.4 → 0.34.6-RC1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/chunks/{PdfViewer-CcDvbfeP.cjs → PdfViewer-Cdq6hWaP.cjs} +2 -2
- package/dist/chunks/{PdfViewer-CL_-YyBC.es.js → PdfViewer-Yy390Dyv.es.js} +2 -2
- package/dist/chunks/{eventemitter3-hYlnBzSA.es.js → eventemitter3-BZXKb7j7.es.js} +1 -1
- package/dist/chunks/{eventemitter3-DmHNHvFX.cjs → eventemitter3-CFCpOk3d.cjs} +1 -1
- package/dist/chunks/{index-oLU8CBCH.es.js → index-M9d0bJ9k.es.js} +12 -7
- package/dist/chunks/{index-Cp_Yy4vP.cjs → index-QkGtTLUE.cjs} +12 -7
- package/dist/chunks/{index-DPjn4rpi-Bs9-iTbY.cjs → index-_8cQcYzu-CB4RkW2W.cjs} +1 -1
- package/dist/chunks/{index-DPjn4rpi-BwmVppCt.es.js → index-_8cQcYzu-Dj8Emsl2.es.js} +1 -1
- package/dist/chunks/{jszip-BP2FTbpi.cjs → jszip-B99MTu59.cjs} +1 -1
- package/dist/chunks/{jszip-jKrsZoMS.es.js → jszip-Duxs2YMV.es.js} +1 -1
- package/dist/chunks/{super-editor.es-C2FJLfJa.cjs → super-editor.es-C-hpEM8j.cjs} +794 -636
- package/dist/chunks/{super-editor.es-C350__qM.es.js → super-editor.es-kNY6AOSu.es.js} +747 -589
- package/dist/chunks/{vue-Cwv-wUpm.cjs → vue-ARQSyfaw.cjs} +2401 -2360
- package/dist/chunks/{vue-CKmzTNVs.es.js → vue-B5QAf5pA.es.js} +2401 -2360
- package/dist/chunks/xml-js-CVyfrKaV.es.js +2 -0
- package/dist/chunks/xml-js-DQa4Ye5C.cjs +3 -0
- package/dist/packages/superdoc/src/components/CommentsLayer/use-comment.d.ts.map +1 -1
- package/dist/packages/superdoc/src/core/SuperDoc.d.ts.map +1 -1
- package/dist/packages/superdoc/src/core/types/index.d.ts.map +1 -1
- package/dist/packages/superdoc/src/stores/comments-store.d.ts.map +1 -1
- package/dist/super-editor/ai-writer.es.js +2 -2
- package/dist/super-editor/chunks/{converter-KW3z-Mzc.js → converter-Ddl2ZmKy.js} +416 -301
- package/dist/super-editor/chunks/{docx-zipper-CYtxqNuc.js → docx-zipper-D1BgiAWm.js} +1 -1
- package/dist/super-editor/chunks/{editor-CTHJwQNA.js → editor-B2T2u3JG.js} +65 -22
- package/dist/super-editor/chunks/{index-DPjn4rpi.js → index-_8cQcYzu.js} +1 -1
- package/dist/super-editor/chunks/{toolbar-BUz0UuKQ.js → toolbar-hyRTdNjv.js} +2 -2
- package/dist/super-editor/converter.es.js +1 -1
- package/dist/super-editor/docx-zipper.es.js +2 -2
- package/dist/super-editor/editor.es.js +3 -3
- package/dist/super-editor/file-zipper.es.js +1 -1
- package/dist/super-editor/super-editor/src/core/super-converter/helpers.d.ts.map +1 -1
- package/dist/super-editor/super-editor/src/core/super-converter/v2/exporter/commentsExporter.d.ts.map +1 -1
- package/dist/super-editor/super-editor/src/core/super-converter/v3/handlers/w/del/del-translator.d.ts.map +1 -1
- package/dist/super-editor/super-editor/src/core/super-converter/v3/handlers/w/ins/ins-translator.d.ts.map +1 -1
- package/dist/super-editor/super-editor/src/extensions/structured-content/structured-content-commands.d.ts +5 -0
- package/dist/super-editor/super-editor/src/extensions/structured-content/structured-content-commands.d.ts.map +1 -1
- package/dist/super-editor/super-editor/src/extensions/track-changes/permission-helpers.d.ts.map +1 -1
- package/dist/super-editor/super-editor.es.js +6 -6
- package/dist/super-editor/toolbar.es.js +2 -2
- package/dist/super-editor.cjs +2 -2
- package/dist/super-editor.es.js +2 -2
- package/dist/superdoc.cjs +2 -2
- package/dist/superdoc.es.js +2 -2
- package/dist/superdoc.umd.js +1141 -938
- package/dist/superdoc.umd.js.map +1 -1
- package/package.json +1 -1
- package/dist/chunks/xml-js-BSDu25I7.cjs +0 -3
- package/dist/chunks/xml-js-CBrRls0f.es.js +0 -2
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { g as global$2, r as ref$1, c as createApp, a as computed, b as createElementBlock, o as openBlock, F as Fragment$1, d as renderList, n as normalizeClass, w as withModifiers, e as createCommentVNode, t as toDisplayString, f as createBaseVNode, i as inject, h as onBeforeMount, j as onMounted, k as onBeforeUnmount, l as watch, m as defineComponent, p as getCurrentInstance, q as onDeactivated, s as nextTick, u as createBlock, v as createVNode, x as unref, y as h
|
|
1
|
+
import { g as global$2, r as ref$1, c as createApp, a as computed, b as createElementBlock, o as openBlock, F as Fragment$1, d as renderList, n as normalizeClass, w as withModifiers, e as createCommentVNode, t as toDisplayString, f as createBaseVNode, i as inject, h as onBeforeMount, j as onMounted, k as onBeforeUnmount, l as watch, m as defineComponent, p as getCurrentInstance, q as onDeactivated, s as nextTick, u as createBlock, v as createVNode, x as unref, y as h, z as mergeProps, A as shallowRef, B as withCtx, C as createTextVNode, D as normalizeStyle, E as toRef, G as provide, H as cloneVNode, T as Text$2, I as withDirectives, J as watchEffect, K as vModelText, L as withKeys, M as reactive, N as readonly, O as Transition, P as vShow, Q as Comment, R as renderSlot, S as onActivated, U as Teleport, V as isVNode, W as onUnmounted, X as resolveDynamicComponent, Y as normalizeProps, Z as guardReactiveProps, _ as markRaw } from "./vue-B5QAf5pA.es.js";
|
|
2
2
|
import * as Y from "yjs";
|
|
3
3
|
import { UndoManager, Item as Item$2, ContentType, Text as Text$1, XmlElement, encodeStateAsUpdate } from "yjs";
|
|
4
4
|
var __defProp$2 = Object.defineProperty;
|
|
@@ -416,17 +416,17 @@ ieee754.write = function(buffer2, value, offset2, isLE, mLen, nBytes) {
|
|
|
416
416
|
);
|
|
417
417
|
}
|
|
418
418
|
if (a === b2) return 0;
|
|
419
|
-
let
|
|
419
|
+
let x2 = a.length;
|
|
420
420
|
let y2 = b2.length;
|
|
421
|
-
for (let i = 0, len = Math.min(
|
|
421
|
+
for (let i = 0, len = Math.min(x2, y2); i < len; ++i) {
|
|
422
422
|
if (a[i] !== b2[i]) {
|
|
423
|
-
|
|
423
|
+
x2 = a[i];
|
|
424
424
|
y2 = b2[i];
|
|
425
425
|
break;
|
|
426
426
|
}
|
|
427
427
|
}
|
|
428
|
-
if (
|
|
429
|
-
if (y2 <
|
|
428
|
+
if (x2 < y2) return -1;
|
|
429
|
+
if (y2 < x2) return 1;
|
|
430
430
|
return 0;
|
|
431
431
|
};
|
|
432
432
|
Buffer3.isEncoding = function isEncoding(encoding) {
|
|
@@ -675,20 +675,20 @@ ieee754.write = function(buffer2, value, offset2, isLE, mLen, nBytes) {
|
|
|
675
675
|
thisStart >>>= 0;
|
|
676
676
|
thisEnd >>>= 0;
|
|
677
677
|
if (this === target) return 0;
|
|
678
|
-
let
|
|
678
|
+
let x2 = thisEnd - thisStart;
|
|
679
679
|
let y2 = end2 - start2;
|
|
680
|
-
const len = Math.min(
|
|
680
|
+
const len = Math.min(x2, y2);
|
|
681
681
|
const thisCopy = this.slice(thisStart, thisEnd);
|
|
682
682
|
const targetCopy = target.slice(start2, end2);
|
|
683
683
|
for (let i = 0; i < len; ++i) {
|
|
684
684
|
if (thisCopy[i] !== targetCopy[i]) {
|
|
685
|
-
|
|
685
|
+
x2 = thisCopy[i];
|
|
686
686
|
y2 = targetCopy[i];
|
|
687
687
|
break;
|
|
688
688
|
}
|
|
689
689
|
}
|
|
690
|
-
if (
|
|
691
|
-
if (y2 <
|
|
690
|
+
if (x2 < y2) return -1;
|
|
691
|
+
if (y2 < x2) return 1;
|
|
692
692
|
return 0;
|
|
693
693
|
};
|
|
694
694
|
function bidirectionalIndexOf(buffer2, val, byteOffset, encoding, dir) {
|
|
@@ -1778,8 +1778,8 @@ ieee754.write = function(buffer2, value, offset2, isLE, mLen, nBytes) {
|
|
|
1778
1778
|
})(buffer);
|
|
1779
1779
|
const Buffer2 = buffer.Buffer;
|
|
1780
1780
|
var commonjsGlobal = typeof globalThis !== "undefined" ? globalThis : typeof window !== "undefined" ? window : typeof global$2 !== "undefined" ? global$2 : typeof self !== "undefined" ? self : {};
|
|
1781
|
-
function getDefaultExportFromCjs$2(
|
|
1782
|
-
return
|
|
1781
|
+
function getDefaultExportFromCjs$2(x2) {
|
|
1782
|
+
return x2 && x2.__esModule && Object.prototype.hasOwnProperty.call(x2, "default") ? x2["default"] : x2;
|
|
1783
1783
|
}
|
|
1784
1784
|
var sax = {};
|
|
1785
1785
|
var events$1 = { exports: {} };
|
|
@@ -1787,13 +1787,13 @@ var hasRequiredEvents;
|
|
|
1787
1787
|
function requireEvents() {
|
|
1788
1788
|
if (hasRequiredEvents) return events$1.exports;
|
|
1789
1789
|
hasRequiredEvents = 1;
|
|
1790
|
-
var
|
|
1791
|
-
var ReflectApply =
|
|
1790
|
+
var R = typeof Reflect === "object" ? Reflect : null;
|
|
1791
|
+
var ReflectApply = R && typeof R.apply === "function" ? R.apply : function ReflectApply2(target, receiver, args) {
|
|
1792
1792
|
return Function.prototype.apply.call(target, receiver, args);
|
|
1793
1793
|
};
|
|
1794
1794
|
var ReflectOwnKeys;
|
|
1795
|
-
if (
|
|
1796
|
-
ReflectOwnKeys =
|
|
1795
|
+
if (R && typeof R.ownKeys === "function") {
|
|
1796
|
+
ReflectOwnKeys = R.ownKeys;
|
|
1797
1797
|
} else if (Object.getOwnPropertySymbols) {
|
|
1798
1798
|
ReflectOwnKeys = function ReflectOwnKeys2(target) {
|
|
1799
1799
|
return Object.getOwnPropertyNames(target).concat(Object.getOwnPropertySymbols(target));
|
|
@@ -2183,8 +2183,8 @@ function requireInherits_browser() {
|
|
|
2183
2183
|
}
|
|
2184
2184
|
return inherits_browser.exports;
|
|
2185
2185
|
}
|
|
2186
|
-
function getDefaultExportFromCjs$1(
|
|
2187
|
-
return
|
|
2186
|
+
function getDefaultExportFromCjs$1(x2) {
|
|
2187
|
+
return x2 && x2.__esModule && Object.prototype.hasOwnProperty.call(x2, "default") ? x2["default"] : x2;
|
|
2188
2188
|
}
|
|
2189
2189
|
var browser$1 = { exports: {} };
|
|
2190
2190
|
var process$1 = browser$1.exports = {};
|
|
@@ -2765,17 +2765,17 @@ function requireDist() {
|
|
|
2765
2765
|
);
|
|
2766
2766
|
}
|
|
2767
2767
|
if (a === b2) return 0;
|
|
2768
|
-
let
|
|
2768
|
+
let x2 = a.length;
|
|
2769
2769
|
let y2 = b2.length;
|
|
2770
|
-
for (let i2 = 0, len2 = Math.min(
|
|
2770
|
+
for (let i2 = 0, len2 = Math.min(x2, y2); i2 < len2; ++i2) {
|
|
2771
2771
|
if (a[i2] !== b2[i2]) {
|
|
2772
|
-
|
|
2772
|
+
x2 = a[i2];
|
|
2773
2773
|
y2 = b2[i2];
|
|
2774
2774
|
break;
|
|
2775
2775
|
}
|
|
2776
2776
|
}
|
|
2777
|
-
if (
|
|
2778
|
-
if (y2 <
|
|
2777
|
+
if (x2 < y2) return -1;
|
|
2778
|
+
if (y2 < x2) return 1;
|
|
2779
2779
|
return 0;
|
|
2780
2780
|
};
|
|
2781
2781
|
Buffer4.isEncoding = function isEncoding(encoding) {
|
|
@@ -3024,20 +3024,20 @@ function requireDist() {
|
|
|
3024
3024
|
thisStart >>>= 0;
|
|
3025
3025
|
thisEnd >>>= 0;
|
|
3026
3026
|
if (this === target) return 0;
|
|
3027
|
-
let
|
|
3027
|
+
let x2 = thisEnd - thisStart;
|
|
3028
3028
|
let y2 = end2 - start2;
|
|
3029
|
-
const len2 = Math.min(
|
|
3029
|
+
const len2 = Math.min(x2, y2);
|
|
3030
3030
|
const thisCopy = this.slice(thisStart, thisEnd);
|
|
3031
3031
|
const targetCopy = target.slice(start2, end2);
|
|
3032
3032
|
for (let i2 = 0; i2 < len2; ++i2) {
|
|
3033
3033
|
if (thisCopy[i2] !== targetCopy[i2]) {
|
|
3034
|
-
|
|
3034
|
+
x2 = thisCopy[i2];
|
|
3035
3035
|
y2 = targetCopy[i2];
|
|
3036
3036
|
break;
|
|
3037
3037
|
}
|
|
3038
3038
|
}
|
|
3039
|
-
if (
|
|
3040
|
-
if (y2 <
|
|
3039
|
+
if (x2 < y2) return -1;
|
|
3040
|
+
if (y2 < x2) return 1;
|
|
3041
3041
|
return 0;
|
|
3042
3042
|
};
|
|
3043
3043
|
function bidirectionalIndexOf(buffer3, val, byteOffset, encoding, dir) {
|
|
@@ -4609,15 +4609,15 @@ function requireGetProto() {
|
|
|
4609
4609
|
var reflectGetProto = requireReflect_getPrototypeOf();
|
|
4610
4610
|
var originalGetProto = requireObject_getPrototypeOf();
|
|
4611
4611
|
var getDunderProto = /* @__PURE__ */ requireGet();
|
|
4612
|
-
getProto = reflectGetProto ? function getProto2(
|
|
4613
|
-
return reflectGetProto(
|
|
4614
|
-
} : originalGetProto ? function getProto2(
|
|
4615
|
-
if (!
|
|
4612
|
+
getProto = reflectGetProto ? function getProto2(O) {
|
|
4613
|
+
return reflectGetProto(O);
|
|
4614
|
+
} : originalGetProto ? function getProto2(O) {
|
|
4615
|
+
if (!O || typeof O !== "object" && typeof O !== "function") {
|
|
4616
4616
|
throw new TypeError("getProto: not an object");
|
|
4617
4617
|
}
|
|
4618
|
-
return originalGetProto(
|
|
4619
|
-
} : getDunderProto ? function getProto2(
|
|
4620
|
-
return getDunderProto(
|
|
4618
|
+
return originalGetProto(O);
|
|
4619
|
+
} : getDunderProto ? function getProto2(O) {
|
|
4620
|
+
return getDunderProto(O);
|
|
4621
4621
|
} : null;
|
|
4622
4622
|
return getProto;
|
|
4623
4623
|
}
|
|
@@ -5295,8 +5295,8 @@ function requireForEach() {
|
|
|
5295
5295
|
}
|
|
5296
5296
|
}
|
|
5297
5297
|
};
|
|
5298
|
-
function isArray2(
|
|
5299
|
-
return toStr.call(
|
|
5298
|
+
function isArray2(x2) {
|
|
5299
|
+
return toStr.call(x2) === "[object Array]";
|
|
5300
5300
|
}
|
|
5301
5301
|
forEach = function forEach22(list, iterator, thisArg) {
|
|
5302
5302
|
if (!isCallable2(iterator)) {
|
|
@@ -5905,10 +5905,10 @@ function requireUtil() {
|
|
|
5905
5905
|
var i = 1;
|
|
5906
5906
|
var args = arguments;
|
|
5907
5907
|
var len = args.length;
|
|
5908
|
-
var str = String(f2).replace(formatRegExp, function(
|
|
5909
|
-
if (
|
|
5910
|
-
if (i >= len) return
|
|
5911
|
-
switch (
|
|
5908
|
+
var str = String(f2).replace(formatRegExp, function(x3) {
|
|
5909
|
+
if (x3 === "%%") return "%";
|
|
5910
|
+
if (i >= len) return x3;
|
|
5911
|
+
switch (x3) {
|
|
5912
5912
|
case "%s":
|
|
5913
5913
|
return String(args[i++]);
|
|
5914
5914
|
case "%d":
|
|
@@ -5920,14 +5920,14 @@ function requireUtil() {
|
|
|
5920
5920
|
return "[Circular]";
|
|
5921
5921
|
}
|
|
5922
5922
|
default:
|
|
5923
|
-
return
|
|
5923
|
+
return x3;
|
|
5924
5924
|
}
|
|
5925
5925
|
});
|
|
5926
|
-
for (var
|
|
5927
|
-
if (isNull(
|
|
5928
|
-
str += " " +
|
|
5926
|
+
for (var x2 = args[i]; i < len; x2 = args[++i]) {
|
|
5927
|
+
if (isNull(x2) || !isObject2(x2)) {
|
|
5928
|
+
str += " " + x2;
|
|
5929
5929
|
} else {
|
|
5930
|
-
str += " " + inspect(
|
|
5930
|
+
str += " " + inspect(x2);
|
|
5931
5931
|
}
|
|
5932
5932
|
}
|
|
5933
5933
|
return str;
|
|
@@ -7492,6 +7492,7 @@ function require_stream_duplex() {
|
|
|
7492
7492
|
}
|
|
7493
7493
|
var string_decoder = {};
|
|
7494
7494
|
var safeBuffer = { exports: {} };
|
|
7495
|
+
/*! safe-buffer. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */
|
|
7495
7496
|
var hasRequiredSafeBuffer;
|
|
7496
7497
|
function requireSafeBuffer() {
|
|
7497
7498
|
if (hasRequiredSafeBuffer) return safeBuffer.exports;
|
|
@@ -7513,6 +7514,7 @@ function requireSafeBuffer() {
|
|
|
7513
7514
|
function SafeBuffer(arg, encodingOrOffset, length2) {
|
|
7514
7515
|
return Buffer3(arg, encodingOrOffset, length2);
|
|
7515
7516
|
}
|
|
7517
|
+
SafeBuffer.prototype = Object.create(Buffer3.prototype);
|
|
7516
7518
|
copyProps(Buffer3, SafeBuffer);
|
|
7517
7519
|
SafeBuffer.from = function(arg, encodingOrOffset, length2) {
|
|
7518
7520
|
if (typeof arg === "number") {
|
|
@@ -8790,9 +8792,9 @@ function require_stream_readable() {
|
|
|
8790
8792
|
return from2(Readable, iterable, opts);
|
|
8791
8793
|
};
|
|
8792
8794
|
}
|
|
8793
|
-
function indexOf(xs,
|
|
8795
|
+
function indexOf(xs, x2) {
|
|
8794
8796
|
for (var i = 0, l3 = xs.length; i < l3; i++) {
|
|
8795
|
-
if (xs[i] ===
|
|
8797
|
+
if (xs[i] === x2) return i;
|
|
8796
8798
|
}
|
|
8797
8799
|
return -1;
|
|
8798
8800
|
}
|
|
@@ -9250,27 +9252,27 @@ function requireSax() {
|
|
|
9250
9252
|
this._parser = new SAXParser(strict, opt);
|
|
9251
9253
|
this.writable = true;
|
|
9252
9254
|
this.readable = true;
|
|
9253
|
-
var
|
|
9255
|
+
var me2 = this;
|
|
9254
9256
|
this._parser.onend = function() {
|
|
9255
|
-
|
|
9257
|
+
me2.emit("end");
|
|
9256
9258
|
};
|
|
9257
9259
|
this._parser.onerror = function(er) {
|
|
9258
|
-
|
|
9259
|
-
|
|
9260
|
+
me2.emit("error", er);
|
|
9261
|
+
me2._parser.error = null;
|
|
9260
9262
|
};
|
|
9261
9263
|
this._decoder = null;
|
|
9262
9264
|
streamWraps.forEach(function(ev) {
|
|
9263
|
-
Object.defineProperty(
|
|
9265
|
+
Object.defineProperty(me2, "on" + ev, {
|
|
9264
9266
|
get: function() {
|
|
9265
|
-
return
|
|
9267
|
+
return me2._parser["on" + ev];
|
|
9266
9268
|
},
|
|
9267
9269
|
set: function(h2) {
|
|
9268
9270
|
if (!h2) {
|
|
9269
|
-
|
|
9270
|
-
|
|
9271
|
+
me2.removeAllListeners(ev);
|
|
9272
|
+
me2._parser["on" + ev] = h2;
|
|
9271
9273
|
return h2;
|
|
9272
9274
|
}
|
|
9273
|
-
|
|
9275
|
+
me2.on(ev, h2);
|
|
9274
9276
|
},
|
|
9275
9277
|
enumerable: true,
|
|
9276
9278
|
configurable: false
|
|
@@ -9302,15 +9304,15 @@ function requireSax() {
|
|
|
9302
9304
|
return true;
|
|
9303
9305
|
};
|
|
9304
9306
|
SAXStream.prototype.on = function(ev, handler2) {
|
|
9305
|
-
var
|
|
9306
|
-
if (!
|
|
9307
|
-
|
|
9307
|
+
var me2 = this;
|
|
9308
|
+
if (!me2._parser["on" + ev] && streamWraps.indexOf(ev) !== -1) {
|
|
9309
|
+
me2._parser["on" + ev] = function() {
|
|
9308
9310
|
var args = arguments.length === 1 ? [arguments[0]] : Array.apply(null, arguments);
|
|
9309
9311
|
args.splice(0, 0, ev);
|
|
9310
|
-
|
|
9312
|
+
me2.emit.apply(me2, args);
|
|
9311
9313
|
};
|
|
9312
9314
|
}
|
|
9313
|
-
return Stream.prototype.on.call(
|
|
9315
|
+
return Stream.prototype.on.call(me2, ev, handler2);
|
|
9314
9316
|
};
|
|
9315
9317
|
var CDATA = "[CDATA[";
|
|
9316
9318
|
var DOCTYPE = "DOCTYPE";
|
|
@@ -9902,9 +9904,9 @@ function requireSax() {
|
|
|
9902
9904
|
var tag = parser.tag = parser.tags.pop();
|
|
9903
9905
|
parser.tagName = parser.tag.name;
|
|
9904
9906
|
emitNode(parser, "onclosetag", parser.tagName);
|
|
9905
|
-
var
|
|
9907
|
+
var x2 = {};
|
|
9906
9908
|
for (var i in tag.ns) {
|
|
9907
|
-
|
|
9909
|
+
x2[i] = tag.ns[i];
|
|
9908
9910
|
}
|
|
9909
9911
|
var parent = parser.tags[parser.tags.length - 1] || parser;
|
|
9910
9912
|
if (parser.opt.xmlns && tag.ns !== parent.ns) {
|
|
@@ -11384,8 +11386,8 @@ function v4(options, buf, offset2) {
|
|
|
11384
11386
|
rnds[8] = rnds[8] & 63 | 128;
|
|
11385
11387
|
return unsafeStringify(rnds);
|
|
11386
11388
|
}
|
|
11387
|
-
function getDefaultExportFromCjs(
|
|
11388
|
-
return
|
|
11389
|
+
function getDefaultExportFromCjs(x2) {
|
|
11390
|
+
return x2 && x2.__esModule && Object.prototype.hasOwnProperty.call(x2, "default") ? x2["default"] : x2;
|
|
11389
11391
|
}
|
|
11390
11392
|
const CRC_TABLE = new Int32Array([
|
|
11391
11393
|
0,
|
|
@@ -15201,8 +15203,8 @@ function polygonToObj(polygonNode) {
|
|
|
15201
15203
|
const points = [];
|
|
15202
15204
|
polygonNode.elements.forEach((element) => {
|
|
15203
15205
|
if (["wp:start", "wp:lineTo"].includes(element.name)) {
|
|
15204
|
-
const { x, y: y2 } = element.attributes;
|
|
15205
|
-
points.push([polygonUnitsToPixels(
|
|
15206
|
+
const { x: x2, y: y2 } = element.attributes;
|
|
15207
|
+
points.push([polygonUnitsToPixels(x2), polygonUnitsToPixels(y2)]);
|
|
15206
15208
|
}
|
|
15207
15209
|
});
|
|
15208
15210
|
if (points.length > 1) {
|
|
@@ -15225,13 +15227,13 @@ function objToPolygon(points) {
|
|
|
15225
15227
|
elements: []
|
|
15226
15228
|
};
|
|
15227
15229
|
points.forEach((point, index2) => {
|
|
15228
|
-
const [
|
|
15230
|
+
const [x2, y2] = point;
|
|
15229
15231
|
const tagName = index2 === 0 ? "wp:start" : "wp:lineTo";
|
|
15230
15232
|
const pointNode = {
|
|
15231
15233
|
name: tagName,
|
|
15232
15234
|
type: tagName,
|
|
15233
15235
|
attributes: {
|
|
15234
|
-
x: pixelsToPolygonUnits(
|
|
15236
|
+
x: pixelsToPolygonUnits(x2),
|
|
15235
15237
|
y: pixelsToPolygonUnits(y2)
|
|
15236
15238
|
}
|
|
15237
15239
|
};
|
|
@@ -15380,6 +15382,9 @@ const getLineHeightValueString = (lineHeight2, defaultUnit, lineRule = "", isObj
|
|
|
15380
15382
|
let [value, unit] = parseSizeUnit(lineHeight2);
|
|
15381
15383
|
if (Number.isNaN(value) || value === 0) return {};
|
|
15382
15384
|
if (lineRule === "atLeast" && value < 1) return {};
|
|
15385
|
+
if (!unit && value < 1) {
|
|
15386
|
+
value = 1;
|
|
15387
|
+
}
|
|
15383
15388
|
unit = unit ? unit : defaultUnit;
|
|
15384
15389
|
return isObject2 ? { ["line-height"]: `${value}${unit}` } : `line-height: ${value}${unit}`;
|
|
15385
15390
|
};
|
|
@@ -22893,7 +22898,7 @@ function posToDOMRect(view, from2, to) {
|
|
|
22893
22898
|
const right2 = Math.max(start2.right, end2.right);
|
|
22894
22899
|
const width = right2 - left2;
|
|
22895
22900
|
const height = bottom2 - top2;
|
|
22896
|
-
const
|
|
22901
|
+
const x2 = left2;
|
|
22897
22902
|
const y2 = top2;
|
|
22898
22903
|
const data = {
|
|
22899
22904
|
top: top2,
|
|
@@ -22902,7 +22907,7 @@ function posToDOMRect(view, from2, to) {
|
|
|
22902
22907
|
right: right2,
|
|
22903
22908
|
width,
|
|
22904
22909
|
height,
|
|
22905
|
-
x,
|
|
22910
|
+
x: x2,
|
|
22906
22911
|
y: y2
|
|
22907
22912
|
};
|
|
22908
22913
|
return {
|
|
@@ -22991,25 +22996,31 @@ function createDocFromHTML(content, schema, options = {}) {
|
|
|
22991
22996
|
function L() {
|
|
22992
22997
|
return { async: false, breaks: false, extensions: null, gfm: true, hooks: null, pedantic: false, renderer: null, silent: false, tokenizer: null, walkTokens: null };
|
|
22993
22998
|
}
|
|
22994
|
-
var
|
|
22999
|
+
var T = L();
|
|
22995
23000
|
function G(l3) {
|
|
22996
|
-
|
|
23001
|
+
T = l3;
|
|
22997
23002
|
}
|
|
22998
23003
|
var E = { exec: () => null };
|
|
22999
|
-
function
|
|
23004
|
+
function d$1(l3, e = "") {
|
|
23000
23005
|
let t = typeof l3 == "string" ? l3 : l3.source, n = { replace: (r2, i) => {
|
|
23001
23006
|
let s2 = typeof i == "string" ? i : i.source;
|
|
23002
23007
|
return s2 = s2.replace(m.caret, "$1"), t = t.replace(r2, s2), n;
|
|
23003
23008
|
}, getRegex: () => new RegExp(t, e) };
|
|
23004
23009
|
return n;
|
|
23005
23010
|
}
|
|
23006
|
-
var
|
|
23007
|
-
|
|
23008
|
-
|
|
23011
|
+
var be = (() => {
|
|
23012
|
+
try {
|
|
23013
|
+
return !!new RegExp("(?<=1)(?<!1)");
|
|
23014
|
+
} catch {
|
|
23015
|
+
return false;
|
|
23016
|
+
}
|
|
23017
|
+
})(), m = { codeRemoveIndent: /^(?: {1,4}| {0,3}\t)/gm, outputLinkReplace: /\\([\[\]])/g, indentCodeCompensation: /^(\s+)(?:```)/, beginningSpace: /^\s+/, endingHash: /#$/, startingSpaceChar: /^ /, endingSpaceChar: / $/, nonSpaceChar: /[^ ]/, newLineCharGlobal: /\n/g, tabCharGlobal: /\t/g, multipleSpaceGlobal: /\s+/g, blankLine: /^[ \t]*$/, doubleBlankLine: /\n[ \t]*\n[ \t]*$/, blockquoteStart: /^ {0,3}>/, blockquoteSetextReplace: /\n {0,3}((?:=+|-+) *)(?=\n|$)/g, blockquoteSetextReplace2: /^ {0,3}>[ \t]?/gm, listReplaceTabs: /^\t+/, listReplaceNesting: /^ {1,4}(?=( {4})*[^ ])/g, listIsTask: /^\[[ xX]\] /, listReplaceTask: /^\[[ xX]\] +/, anyLine: /\n.*\n/, hrefBrackets: /^<(.*)>$/, tableDelimiter: /[:|]/, tableAlignChars: /^\||\| *$/g, tableRowBlankLine: /\n[ \t]*$/, tableAlignRight: /^ *-+: *$/, tableAlignCenter: /^ *:-+: *$/, tableAlignLeft: /^ *:-+ *$/, startATag: /^<a /i, endATag: /^<\/a>/i, startPreScriptTag: /^<(pre|code|kbd|script)(\s|>)/i, endPreScriptTag: /^<\/(pre|code|kbd|script)(\s|>)/i, startAngleBracket: /^</, endAngleBracket: />$/, pedanticHrefTitle: /^([^'"]*[^\s])\s+(['"])(.*)\2/, unicodeAlphaNumeric: /[\p{L}\p{N}]/u, escapeTest: /[&<>"']/, escapeReplace: /[&<>"']/g, escapeTestNoEncode: /[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/, escapeReplaceNoEncode: /[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g, unescapeTest: /&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig, caret: /(^|[^\[])\^/g, percentDecode: /%25/g, findPipe: /\|/g, splitPipe: / \|/, slashPipe: /\\\|/g, carriageReturn: /\r\n|\r/g, spaceLine: /^ +$/gm, notSpaceStart: /^\S*/, endingNewline: /\n$/, listItemRegex: (l3) => new RegExp(`^( {0,3}${l3})((?:[ ][^\\n]*)?(?:\\n|$))`), nextBulletRegex: (l3) => new RegExp(`^ {0,${Math.min(3, l3 - 1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`), hrRegex: (l3) => new RegExp(`^ {0,${Math.min(3, l3 - 1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`), fencesBeginRegex: (l3) => new RegExp(`^ {0,${Math.min(3, l3 - 1)}}(?:\`\`\`|~~~)`), headingBeginRegex: (l3) => new RegExp(`^ {0,${Math.min(3, l3 - 1)}}#`), htmlBeginRegex: (l3) => new RegExp(`^ {0,${Math.min(3, l3 - 1)}}<(?:[a-z].*>|!--)`, "i") }, Re = /^(?:[ \t]*(?:\n|$))+/, Te = /^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/, Oe = /^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/, I = /^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/, we = /^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/, F = /(?:[*+-]|\d{1,9}[.)])/, ie$2 = /^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/, oe = d$1(ie$2).replace(/bull/g, F).replace(/blockCode/g, /(?: {4}| {0,3}\t)/).replace(/fences/g, / {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g, / {0,3}>/).replace(/heading/g, / {0,3}#{1,6}/).replace(/html/g, / {0,3}<[^\n>]+>\n/).replace(/\|table/g, "").getRegex(), ye = d$1(ie$2).replace(/bull/g, F).replace(/blockCode/g, /(?: {4}| {0,3}\t)/).replace(/fences/g, / {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g, / {0,3}>/).replace(/heading/g, / {0,3}#{1,6}/).replace(/html/g, / {0,3}<[^\n>]+>\n/).replace(/table/g, / {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(), j = /^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/, Pe = /^[^\n]+/, Q = /(?!\s*\])(?:\\[\s\S]|[^\[\]\\])+/, Se = d$1(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label", Q).replace("title", /(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(), $e = d$1(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g, F).getRegex(), v = "address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul", U = /<!--(?:-?>|[\s\S]*?(?:-->|$))/, _e = d$1("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$))", "i").replace("comment", U).replace("tag", v).replace("attribute", / +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(), ae = d$1(j).replace("hr", I).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("|lheading", "").replace("|table", "").replace("blockquote", " {0,3}>").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)]) ").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", v).getRegex(), Le = d$1(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph", ae).getRegex(), K$1 = { blockquote: Le, code: Te, def: Se, fences: Oe, heading: we, hr: I, html: _e, lheading: oe, list: $e, newline: Re, paragraph: ae, table: E, text: Pe }, re = d$1("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr", I).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("blockquote", " {0,3}>").replace("code", "(?: {4}| {0,3} )[^\\n]").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)]) ").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", v).getRegex(), Me = { ...K$1, lheading: ye, table: re, paragraph: d$1(j).replace("hr", I).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("|lheading", "").replace("table", re).replace("blockquote", " {0,3}>").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)]) ").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", v).getRegex() }, ze = { ...K$1, html: d$1(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment", U).replace(/tag/g, "(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(), def: /^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/, heading: /^(#{1,6})(.*)(?:\n+|$)/, fences: E, lheading: /^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/, paragraph: d$1(j).replace("hr", I).replace("heading", ` *#{1,6} *[^
|
|
23018
|
+
]`).replace("lheading", oe).replace("|table", "").replace("blockquote", " {0,3}>").replace("|fences", "").replace("|list", "").replace("|html", "").replace("|tag", "").getRegex() }, Ae = /^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/, Ee = /^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/, le = /^( {2,}|\\)\n(?!\s*$)/, Ie = /^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/, D = /[\p{P}\p{S}]/u, W = /[\s\p{P}\p{S}]/u, ue = /[^\s\p{P}\p{S}]/u, Ce = d$1(/^((?![*_])punctSpace)/, "u").replace(/punctSpace/g, W).getRegex(), pe = /(?!~)[\p{P}\p{S}]/u, Be = /(?!~)[\s\p{P}\p{S}]/u, qe = /(?:[^\s\p{P}\p{S}]|~)/u, ve = d$1(/link|precode-code|html/, "g").replace("link", /\[(?:[^\[\]`]|(?<a>`+)[^`]+\k<a>(?!`))*?\]\((?:\\[\s\S]|[^\\\(\)]|\((?:\\[\s\S]|[^\\\(\)])*\))*\)/).replace("precode-", be ? "(?<!`)()" : "(^^|[^`])").replace("code", /(?<b>`+)[^`]+\k<b>(?!`)/).replace("html", /<(?! )[^<>]*?>/).getRegex(), ce = /^(?:\*+(?:((?!\*)punct)|[^\s*]))|^_+(?:((?!_)punct)|([^\s_]))/, De = d$1(ce, "u").replace(/punct/g, D).getRegex(), He = d$1(ce, "u").replace(/punct/g, pe).getRegex(), he$3 = "^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)", Ze = d$1(he$3, "gu").replace(/notPunctSpace/g, ue).replace(/punctSpace/g, W).replace(/punct/g, D).getRegex(), Ge = d$1(he$3, "gu").replace(/notPunctSpace/g, qe).replace(/punctSpace/g, Be).replace(/punct/g, pe).getRegex(), Ne = d$1("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)", "gu").replace(/notPunctSpace/g, ue).replace(/punctSpace/g, W).replace(/punct/g, D).getRegex(), Fe = d$1(/\\(punct)/, "gu").replace(/punct/g, D).getRegex(), je = d$1(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace("scheme", /[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace("email", /[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex(), Qe = d$1(U).replace("(?:-->|$)", "-->").getRegex(), Ue = d$1("^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>").replace("comment", Qe).replace("attribute", /\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(), q = /(?:\[(?:\\[\s\S]|[^\[\]\\])*\]|\\[\s\S]|`+[^`]*?`+(?!`)|[^\[\]\\`])*?/, Ke = d$1(/^!?\[(label)\]\(\s*(href)(?:(?:[ \t]*(?:\n[ \t]*)?)(title))?\s*\)/).replace("label", q).replace("href", /<(?:\\.|[^\n<>\\])+>|[^ \t\n\x00-\x1f]*/).replace("title", /"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(), de = d$1(/^!?\[(label)\]\[(ref)\]/).replace("label", q).replace("ref", Q).getRegex(), ke = d$1(/^!?\[(ref)\](?:\[\])?/).replace("ref", Q).getRegex(), We = d$1("reflink|nolink(?!\\()", "g").replace("reflink", de).replace("nolink", ke).getRegex(), se = /[hH][tT][tT][pP][sS]?|[fF][tT][pP]/, X = { _backpedal: E, anyPunctuation: Fe, autolink: je, blockSkip: ve, br: le, code: Ee, del: E, emStrongLDelim: De, emStrongRDelimAst: Ze, emStrongRDelimUnd: Ne, escape: Ae, link: Ke, nolink: ke, punctuation: Ce, reflink: de, reflinkSearch: We, tag: Ue, text: Ie, url: E }, Xe = { ...X, link: d$1(/^!?\[(label)\]\((.*?)\)/).replace("label", q).getRegex(), reflink: d$1(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label", q).getRegex() }, N = { ...X, emStrongRDelimAst: Ge, emStrongLDelim: He, url: d$1(/^((?:protocol):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/).replace("protocol", se).replace("email", /[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/).getRegex(), _backpedal: /(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/, del: /^(~~?)(?=[^\s~])((?:\\[\s\S]|[^\\])*?(?:\\[\s\S]|[^\s~\\]))\1(?=[^~]|$)/, text: d$1(/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|protocol:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/).replace("protocol", se).getRegex() }, Je = { ...N, br: d$1(le).replace("{2,}", "*").getRegex(), text: d$1(N.text).replace("\\b_", "\\b_| {2,}\\n").replace(/\{2,\}/g, "*").getRegex() }, C = { normal: K$1, gfm: Me, pedantic: ze }, M$1 = { normal: X, gfm: N, breaks: Je, pedantic: Xe };
|
|
23019
|
+
var Ve = { "&": "&", "<": "<", ">": ">", '"': """, "'": "'" }, ge = (l3) => Ve[l3];
|
|
23009
23020
|
function w(l3, e) {
|
|
23010
23021
|
if (e) {
|
|
23011
|
-
if (m.escapeTest.test(l3)) return l3.replace(m.escapeReplace,
|
|
23012
|
-
} else if (m.escapeTestNoEncode.test(l3)) return l3.replace(m.escapeReplaceNoEncode,
|
|
23022
|
+
if (m.escapeTest.test(l3)) return l3.replace(m.escapeReplace, ge);
|
|
23023
|
+
} else if (m.escapeTestNoEncode.test(l3)) return l3.replace(m.escapeReplaceNoEncode, ge);
|
|
23013
23024
|
return l3;
|
|
23014
23025
|
}
|
|
23015
23026
|
function J(l3) {
|
|
@@ -23021,10 +23032,10 @@ function J(l3) {
|
|
|
23021
23032
|
return l3;
|
|
23022
23033
|
}
|
|
23023
23034
|
function V(l3, e) {
|
|
23024
|
-
let t = l3.replace(m.findPipe, (i, s2,
|
|
23025
|
-
let
|
|
23026
|
-
for (; --
|
|
23027
|
-
return
|
|
23035
|
+
let t = l3.replace(m.findPipe, (i, s2, a) => {
|
|
23036
|
+
let o = false, p = s2;
|
|
23037
|
+
for (; --p >= 0 && a[p] === "\\"; ) o = !o;
|
|
23038
|
+
return o ? "|" : " |";
|
|
23028
23039
|
}), n = t.split(m.splitPipe), r2 = 0;
|
|
23029
23040
|
if (n[0].trim() || n.shift(), n.length > 0 && !n.at(-1)?.trim() && n.pop(), e) if (n.length > e) n.splice(e);
|
|
23030
23041
|
else for (; n.length < e; ) n.push("");
|
|
@@ -23042,7 +23053,7 @@ function z(l3, e, t) {
|
|
|
23042
23053
|
}
|
|
23043
23054
|
return l3.slice(0, n - r2);
|
|
23044
23055
|
}
|
|
23045
|
-
function
|
|
23056
|
+
function fe(l3, e) {
|
|
23046
23057
|
if (l3.indexOf(e[1]) === -1) return -1;
|
|
23047
23058
|
let t = 0;
|
|
23048
23059
|
for (let n = 0; n < l3.length; n++) if (l3[n] === "\\") n++;
|
|
@@ -23050,13 +23061,13 @@ function ge(l3, e) {
|
|
|
23050
23061
|
else if (l3[n] === e[1] && (t--, t < 0)) return n;
|
|
23051
23062
|
return t > 0 ? -2 : -1;
|
|
23052
23063
|
}
|
|
23053
|
-
function
|
|
23054
|
-
let i = e.href, s2 = e.title || null,
|
|
23064
|
+
function me(l3, e, t, n, r2) {
|
|
23065
|
+
let i = e.href, s2 = e.title || null, a = l3[1].replace(r2.other.outputLinkReplace, "$1");
|
|
23055
23066
|
n.state.inLink = true;
|
|
23056
|
-
let
|
|
23057
|
-
return n.state.inLink = false,
|
|
23067
|
+
let o = { type: l3[0].charAt(0) === "!" ? "image" : "link", raw: t, href: i, title: s2, text: a, tokens: n.inlineTokens(a) };
|
|
23068
|
+
return n.state.inLink = false, o;
|
|
23058
23069
|
}
|
|
23059
|
-
function
|
|
23070
|
+
function Ye(l3, e, t) {
|
|
23060
23071
|
let n = l3.match(t.other.indentCodeCompensation);
|
|
23061
23072
|
if (n === null) return e;
|
|
23062
23073
|
let r2 = n[1];
|
|
@@ -23064,8 +23075,8 @@ function Je(l3, e, t) {
|
|
|
23064
23075
|
`).map((i) => {
|
|
23065
23076
|
let s2 = i.match(t.other.beginningSpace);
|
|
23066
23077
|
if (s2 === null) return i;
|
|
23067
|
-
let [
|
|
23068
|
-
return
|
|
23078
|
+
let [a] = s2;
|
|
23079
|
+
return a.length >= r2.length ? i.slice(r2.length) : i;
|
|
23069
23080
|
}).join(`
|
|
23070
23081
|
`);
|
|
23071
23082
|
}
|
|
@@ -23074,7 +23085,7 @@ var y = class {
|
|
|
23074
23085
|
__publicField$2(this, "options");
|
|
23075
23086
|
__publicField$2(this, "rules");
|
|
23076
23087
|
__publicField$2(this, "lexer");
|
|
23077
|
-
this.options = e ||
|
|
23088
|
+
this.options = e || T;
|
|
23078
23089
|
}
|
|
23079
23090
|
space(e) {
|
|
23080
23091
|
let t = this.rules.block.newline.exec(e);
|
|
@@ -23091,7 +23102,7 @@ var y = class {
|
|
|
23091
23102
|
fences(e) {
|
|
23092
23103
|
let t = this.rules.block.fences.exec(e);
|
|
23093
23104
|
if (t) {
|
|
23094
|
-
let n = t[0], r2 =
|
|
23105
|
+
let n = t[0], r2 = Ye(n, t[3] || "", this.rules);
|
|
23095
23106
|
return { type: "code", raw: n, lang: t[2] ? t[2].trim().replace(this.rules.inline.anyPunctuation, "$1") : t[2], text: r2 };
|
|
23096
23107
|
}
|
|
23097
23108
|
}
|
|
@@ -23118,32 +23129,32 @@ var y = class {
|
|
|
23118
23129
|
`).split(`
|
|
23119
23130
|
`), r2 = "", i = "", s2 = [];
|
|
23120
23131
|
for (; n.length > 0; ) {
|
|
23121
|
-
let
|
|
23122
|
-
for (
|
|
23123
|
-
else if (!
|
|
23132
|
+
let a = false, o = [], p;
|
|
23133
|
+
for (p = 0; p < n.length; p++) if (this.rules.other.blockquoteStart.test(n[p])) o.push(n[p]), a = true;
|
|
23134
|
+
else if (!a) o.push(n[p]);
|
|
23124
23135
|
else break;
|
|
23125
|
-
n = n.slice(
|
|
23126
|
-
let
|
|
23127
|
-
`), c2 =
|
|
23136
|
+
n = n.slice(p);
|
|
23137
|
+
let u = o.join(`
|
|
23138
|
+
`), c2 = u.replace(this.rules.other.blockquoteSetextReplace, `
|
|
23128
23139
|
$1`).replace(this.rules.other.blockquoteSetextReplace2, "");
|
|
23129
23140
|
r2 = r2 ? `${r2}
|
|
23130
|
-
${
|
|
23141
|
+
${u}` : u, i = i ? `${i}
|
|
23131
23142
|
${c2}` : c2;
|
|
23132
|
-
let
|
|
23133
|
-
if (this.lexer.state.top = true, this.lexer.blockTokens(c2, s2, true), this.lexer.state.top =
|
|
23134
|
-
let
|
|
23135
|
-
if (
|
|
23136
|
-
if (
|
|
23137
|
-
let
|
|
23143
|
+
let g = this.lexer.state.top;
|
|
23144
|
+
if (this.lexer.state.top = true, this.lexer.blockTokens(c2, s2, true), this.lexer.state.top = g, n.length === 0) break;
|
|
23145
|
+
let h2 = s2.at(-1);
|
|
23146
|
+
if (h2?.type === "code") break;
|
|
23147
|
+
if (h2?.type === "blockquote") {
|
|
23148
|
+
let R = h2, f2 = R.raw + `
|
|
23138
23149
|
` + n.join(`
|
|
23139
|
-
`),
|
|
23140
|
-
s2[s2.length - 1] =
|
|
23150
|
+
`), O = this.blockquote(f2);
|
|
23151
|
+
s2[s2.length - 1] = O, r2 = r2.substring(0, r2.length - R.raw.length) + O.raw, i = i.substring(0, i.length - R.text.length) + O.text;
|
|
23141
23152
|
break;
|
|
23142
|
-
} else if (
|
|
23143
|
-
let
|
|
23153
|
+
} else if (h2?.type === "list") {
|
|
23154
|
+
let R = h2, f2 = R.raw + `
|
|
23144
23155
|
` + n.join(`
|
|
23145
|
-
`),
|
|
23146
|
-
s2[s2.length - 1] =
|
|
23156
|
+
`), O = this.list(f2);
|
|
23157
|
+
s2[s2.length - 1] = O, r2 = r2.substring(0, r2.length - h2.raw.length) + O.raw, i = i.substring(0, i.length - R.raw.length) + O.raw, n = f2.substring(s2.at(-1).raw.length).split(`
|
|
23147
23158
|
`);
|
|
23148
23159
|
continue;
|
|
23149
23160
|
}
|
|
@@ -23156,45 +23167,45 @@ ${c2}` : c2;
|
|
|
23156
23167
|
if (t) {
|
|
23157
23168
|
let n = t[1].trim(), r2 = n.length > 1, i = { type: "list", raw: "", ordered: r2, start: r2 ? +n.slice(0, -1) : "", loose: false, items: [] };
|
|
23158
23169
|
n = r2 ? `\\d{1,9}\\${n.slice(-1)}` : `\\${n}`, this.options.pedantic && (n = r2 ? n : "[*+-]");
|
|
23159
|
-
let s2 = this.rules.other.listItemRegex(n),
|
|
23170
|
+
let s2 = this.rules.other.listItemRegex(n), a = false;
|
|
23160
23171
|
for (; e; ) {
|
|
23161
|
-
let
|
|
23172
|
+
let p = false, u = "", c2 = "";
|
|
23162
23173
|
if (!(t = s2.exec(e)) || this.rules.block.hr.test(e)) break;
|
|
23163
|
-
|
|
23164
|
-
let
|
|
23165
|
-
`, 1)[0].replace(this.rules.other.listReplaceTabs, (H) => " ".repeat(3 * H.length)),
|
|
23166
|
-
`, 1)[0],
|
|
23167
|
-
if (this.options.pedantic ? (
|
|
23168
|
-
`, e = e.substring(
|
|
23169
|
-
let H = this.rules.other.nextBulletRegex(
|
|
23174
|
+
u = t[0], e = e.substring(u.length);
|
|
23175
|
+
let g = t[2].split(`
|
|
23176
|
+
`, 1)[0].replace(this.rules.other.listReplaceTabs, (H) => " ".repeat(3 * H.length)), h2 = e.split(`
|
|
23177
|
+
`, 1)[0], R = !g.trim(), f2 = 0;
|
|
23178
|
+
if (this.options.pedantic ? (f2 = 2, c2 = g.trimStart()) : R ? f2 = t[1].length + 1 : (f2 = t[2].search(this.rules.other.nonSpaceChar), f2 = f2 > 4 ? 1 : f2, c2 = g.slice(f2), f2 += t[1].length), R && this.rules.other.blankLine.test(h2) && (u += h2 + `
|
|
23179
|
+
`, e = e.substring(h2.length + 1), p = true), !p) {
|
|
23180
|
+
let H = this.rules.other.nextBulletRegex(f2), ee = this.rules.other.hrRegex(f2), te = this.rules.other.fencesBeginRegex(f2), ne = this.rules.other.headingBeginRegex(f2), xe = this.rules.other.htmlBeginRegex(f2);
|
|
23170
23181
|
for (; e; ) {
|
|
23171
23182
|
let Z = e.split(`
|
|
23172
23183
|
`, 1)[0], A2;
|
|
23173
|
-
if (
|
|
23174
|
-
if (A2.search(this.rules.other.nonSpaceChar) >=
|
|
23175
|
-
` + A2.slice(
|
|
23184
|
+
if (h2 = Z, this.options.pedantic ? (h2 = h2.replace(this.rules.other.listReplaceNesting, " "), A2 = h2) : A2 = h2.replace(this.rules.other.tabCharGlobal, " "), te.test(h2) || ne.test(h2) || xe.test(h2) || H.test(h2) || ee.test(h2)) break;
|
|
23185
|
+
if (A2.search(this.rules.other.nonSpaceChar) >= f2 || !h2.trim()) c2 += `
|
|
23186
|
+
` + A2.slice(f2);
|
|
23176
23187
|
else {
|
|
23177
|
-
if (
|
|
23188
|
+
if (R || g.replace(this.rules.other.tabCharGlobal, " ").search(this.rules.other.nonSpaceChar) >= 4 || te.test(g) || ne.test(g) || ee.test(g)) break;
|
|
23178
23189
|
c2 += `
|
|
23179
|
-
` +
|
|
23190
|
+
` + h2;
|
|
23180
23191
|
}
|
|
23181
|
-
!
|
|
23182
|
-
`, e = e.substring(Z.length + 1),
|
|
23192
|
+
!R && !h2.trim() && (R = true), u += Z + `
|
|
23193
|
+
`, e = e.substring(Z.length + 1), g = A2.slice(f2);
|
|
23183
23194
|
}
|
|
23184
23195
|
}
|
|
23185
|
-
i.loose || (
|
|
23186
|
-
let
|
|
23187
|
-
this.options.gfm && (
|
|
23196
|
+
i.loose || (a ? i.loose = true : this.rules.other.doubleBlankLine.test(u) && (a = true));
|
|
23197
|
+
let O = null, Y2;
|
|
23198
|
+
this.options.gfm && (O = this.rules.other.listIsTask.exec(c2), O && (Y2 = O[0] !== "[ ] ", c2 = c2.replace(this.rules.other.listReplaceTask, ""))), i.items.push({ type: "list_item", raw: u, task: !!O, checked: Y2, loose: false, text: c2, tokens: [] }), i.raw += u;
|
|
23188
23199
|
}
|
|
23189
|
-
let
|
|
23190
|
-
if (
|
|
23200
|
+
let o = i.items.at(-1);
|
|
23201
|
+
if (o) o.raw = o.raw.trimEnd(), o.text = o.text.trimEnd();
|
|
23191
23202
|
else return;
|
|
23192
23203
|
i.raw = i.raw.trimEnd();
|
|
23193
|
-
for (let
|
|
23194
|
-
let
|
|
23204
|
+
for (let p = 0; p < i.items.length; p++) if (this.lexer.state.top = false, i.items[p].tokens = this.lexer.blockTokens(i.items[p].text, []), !i.loose) {
|
|
23205
|
+
let u = i.items[p].tokens.filter((g) => g.type === "space"), c2 = u.length > 0 && u.some((g) => this.rules.other.anyLine.test(g.raw));
|
|
23195
23206
|
i.loose = c2;
|
|
23196
23207
|
}
|
|
23197
|
-
if (i.loose) for (let
|
|
23208
|
+
if (i.loose) for (let p = 0; p < i.items.length; p++) i.items[p].loose = true;
|
|
23198
23209
|
return i;
|
|
23199
23210
|
}
|
|
23200
23211
|
}
|
|
@@ -23215,9 +23226,9 @@ ${c2}` : c2;
|
|
|
23215
23226
|
let n = V(t[1]), r2 = t[2].replace(this.rules.other.tableAlignChars, "").split("|"), i = t[3]?.trim() ? t[3].replace(this.rules.other.tableRowBlankLine, "").split(`
|
|
23216
23227
|
`) : [], s2 = { type: "table", raw: t[0], header: [], align: [], rows: [] };
|
|
23217
23228
|
if (n.length === r2.length) {
|
|
23218
|
-
for (let
|
|
23219
|
-
for (let
|
|
23220
|
-
for (let
|
|
23229
|
+
for (let a of r2) this.rules.other.tableAlignRight.test(a) ? s2.align.push("right") : this.rules.other.tableAlignCenter.test(a) ? s2.align.push("center") : this.rules.other.tableAlignLeft.test(a) ? s2.align.push("left") : s2.align.push(null);
|
|
23230
|
+
for (let a = 0; a < n.length; a++) s2.header.push({ text: n[a], tokens: this.lexer.inline(n[a]), header: true, align: s2.align[a] });
|
|
23231
|
+
for (let a of i) s2.rows.push(V(a, s2.header.length).map((o, p) => ({ text: o, tokens: this.lexer.inline(o), header: false, align: s2.align[p] })));
|
|
23221
23232
|
return s2;
|
|
23222
23233
|
}
|
|
23223
23234
|
}
|
|
@@ -23254,11 +23265,11 @@ ${c2}` : c2;
|
|
|
23254
23265
|
let s2 = z(n.slice(0, -1), "\\");
|
|
23255
23266
|
if ((n.length - s2.length) % 2 === 0) return;
|
|
23256
23267
|
} else {
|
|
23257
|
-
let s2 =
|
|
23268
|
+
let s2 = fe(t[2], "()");
|
|
23258
23269
|
if (s2 === -2) return;
|
|
23259
23270
|
if (s2 > -1) {
|
|
23260
|
-
let
|
|
23261
|
-
t[2] = t[2].substring(0, s2), t[0] = t[0].substring(0,
|
|
23271
|
+
let o = (t[0].indexOf("!") === 0 ? 5 : 4) + t[1].length + s2;
|
|
23272
|
+
t[2] = t[2].substring(0, s2), t[0] = t[0].substring(0, o).trim(), t[3] = "";
|
|
23262
23273
|
}
|
|
23263
23274
|
}
|
|
23264
23275
|
let r2 = t[2], i = "";
|
|
@@ -23266,7 +23277,7 @@ ${c2}` : c2;
|
|
|
23266
23277
|
let s2 = this.rules.other.pedanticHrefTitle.exec(r2);
|
|
23267
23278
|
s2 && (r2 = s2[1], i = s2[3]);
|
|
23268
23279
|
} else i = t[3] ? t[3].slice(1, -1) : "";
|
|
23269
|
-
return r2 = r2.trim(), this.rules.other.startAngleBracket.test(r2) && (this.options.pedantic && !this.rules.other.endAngleBracket.test(n) ? r2 = r2.slice(1) : r2 = r2.slice(1, -1)),
|
|
23280
|
+
return r2 = r2.trim(), this.rules.other.startAngleBracket.test(r2) && (this.options.pedantic && !this.rules.other.endAngleBracket.test(n) ? r2 = r2.slice(1) : r2 = r2.slice(1, -1)), me(t, { href: r2 && r2.replace(this.rules.inline.anyPunctuation, "$1"), title: i && i.replace(this.rules.inline.anyPunctuation, "$1") }, t[0], this.lexer, this.rules);
|
|
23270
23281
|
}
|
|
23271
23282
|
}
|
|
23272
23283
|
reflink(e, t) {
|
|
@@ -23277,32 +23288,32 @@ ${c2}` : c2;
|
|
|
23277
23288
|
let s2 = n[0].charAt(0);
|
|
23278
23289
|
return { type: "text", raw: s2, text: s2 };
|
|
23279
23290
|
}
|
|
23280
|
-
return
|
|
23291
|
+
return me(n, i, n[0], this.lexer, this.rules);
|
|
23281
23292
|
}
|
|
23282
23293
|
}
|
|
23283
23294
|
emStrong(e, t, n = "") {
|
|
23284
23295
|
let r2 = this.rules.inline.emStrongLDelim.exec(e);
|
|
23285
23296
|
if (!r2 || r2[3] && n.match(this.rules.other.unicodeAlphaNumeric)) return;
|
|
23286
23297
|
if (!(r2[1] || r2[2] || "") || !n || this.rules.inline.punctuation.exec(n)) {
|
|
23287
|
-
let s2 = [...r2[0]].length - 1,
|
|
23298
|
+
let s2 = [...r2[0]].length - 1, a, o, p = s2, u = 0, c2 = r2[0][0] === "*" ? this.rules.inline.emStrongRDelimAst : this.rules.inline.emStrongRDelimUnd;
|
|
23288
23299
|
for (c2.lastIndex = 0, t = t.slice(-1 * e.length + s2); (r2 = c2.exec(t)) != null; ) {
|
|
23289
|
-
if (
|
|
23290
|
-
if (
|
|
23291
|
-
|
|
23300
|
+
if (a = r2[1] || r2[2] || r2[3] || r2[4] || r2[5] || r2[6], !a) continue;
|
|
23301
|
+
if (o = [...a].length, r2[3] || r2[4]) {
|
|
23302
|
+
p += o;
|
|
23292
23303
|
continue;
|
|
23293
|
-
} else if ((r2[5] || r2[6]) && s2 % 3 && !((s2 +
|
|
23294
|
-
|
|
23304
|
+
} else if ((r2[5] || r2[6]) && s2 % 3 && !((s2 + o) % 3)) {
|
|
23305
|
+
u += o;
|
|
23295
23306
|
continue;
|
|
23296
23307
|
}
|
|
23297
|
-
if (
|
|
23298
|
-
|
|
23299
|
-
let
|
|
23300
|
-
if (Math.min(s2,
|
|
23301
|
-
let
|
|
23302
|
-
return { type: "em", raw:
|
|
23308
|
+
if (p -= o, p > 0) continue;
|
|
23309
|
+
o = Math.min(o, o + p + u);
|
|
23310
|
+
let g = [...r2[0]][0].length, h2 = e.slice(0, s2 + r2.index + g + o);
|
|
23311
|
+
if (Math.min(s2, o) % 2) {
|
|
23312
|
+
let f2 = h2.slice(1, -1);
|
|
23313
|
+
return { type: "em", raw: h2, text: f2, tokens: this.lexer.inlineTokens(f2) };
|
|
23303
23314
|
}
|
|
23304
|
-
let
|
|
23305
|
-
return { type: "strong", raw:
|
|
23315
|
+
let R = h2.slice(2, -2);
|
|
23316
|
+
return { type: "strong", raw: h2, text: R, tokens: this.lexer.inlineTokens(R) };
|
|
23306
23317
|
}
|
|
23307
23318
|
}
|
|
23308
23319
|
}
|
|
@@ -23351,19 +23362,19 @@ ${c2}` : c2;
|
|
|
23351
23362
|
}
|
|
23352
23363
|
}
|
|
23353
23364
|
};
|
|
23354
|
-
var
|
|
23365
|
+
var x = class l {
|
|
23355
23366
|
constructor(e) {
|
|
23356
23367
|
__publicField$2(this, "tokens");
|
|
23357
23368
|
__publicField$2(this, "options");
|
|
23358
23369
|
__publicField$2(this, "state");
|
|
23359
23370
|
__publicField$2(this, "tokenizer");
|
|
23360
23371
|
__publicField$2(this, "inlineQueue");
|
|
23361
|
-
this.tokens = [], this.tokens.links = /* @__PURE__ */ Object.create(null), this.options = e ||
|
|
23362
|
-
let t = { other: m, block:
|
|
23363
|
-
this.options.pedantic ? (t.block =
|
|
23372
|
+
this.tokens = [], this.tokens.links = /* @__PURE__ */ Object.create(null), this.options = e || T, this.options.tokenizer = this.options.tokenizer || new y(), this.tokenizer = this.options.tokenizer, this.tokenizer.options = this.options, this.tokenizer.lexer = this, this.inlineQueue = [], this.state = { inLink: false, inRawBlock: false, top: true };
|
|
23373
|
+
let t = { other: m, block: C.normal, inline: M$1.normal };
|
|
23374
|
+
this.options.pedantic ? (t.block = C.pedantic, t.inline = M$1.pedantic) : this.options.gfm && (t.block = C.gfm, this.options.breaks ? t.inline = M$1.breaks : t.inline = M$1.gfm), this.tokenizer.rules = t;
|
|
23364
23375
|
}
|
|
23365
23376
|
static get rules() {
|
|
23366
|
-
return { block:
|
|
23377
|
+
return { block: C, inline: M$1 };
|
|
23367
23378
|
}
|
|
23368
23379
|
static lex(e, t) {
|
|
23369
23380
|
return new l(t).lex(e);
|
|
@@ -23443,9 +23454,9 @@ var b = class l {
|
|
|
23443
23454
|
}
|
|
23444
23455
|
let i = e;
|
|
23445
23456
|
if (this.options.extensions?.startBlock) {
|
|
23446
|
-
let s2 = 1 / 0,
|
|
23447
|
-
this.options.extensions.startBlock.forEach((
|
|
23448
|
-
|
|
23457
|
+
let s2 = 1 / 0, a = e.slice(1), o;
|
|
23458
|
+
this.options.extensions.startBlock.forEach((p) => {
|
|
23459
|
+
o = p.call({ lexer: this }, a), typeof o == "number" && o >= 0 && (s2 = Math.min(s2, o));
|
|
23449
23460
|
}), s2 < 1 / 0 && s2 >= 0 && (i = e.substring(0, s2 + 1));
|
|
23450
23461
|
}
|
|
23451
23462
|
if (this.state.top && (r2 = this.tokenizer.paragraph(i))) {
|
|
@@ -23485,11 +23496,12 @@ var b = class l {
|
|
|
23485
23496
|
if (o.length > 0) for (; (r2 = this.tokenizer.rules.inline.reflinkSearch.exec(n)) != null; ) o.includes(r2[0].slice(r2[0].lastIndexOf("[") + 1, -1)) && (n = n.slice(0, r2.index) + "[" + "a".repeat(r2[0].length - 2) + "]" + n.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex));
|
|
23486
23497
|
}
|
|
23487
23498
|
for (; (r2 = this.tokenizer.rules.inline.anyPunctuation.exec(n)) != null; ) n = n.slice(0, r2.index) + "++" + n.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);
|
|
23488
|
-
|
|
23499
|
+
let i;
|
|
23500
|
+
for (; (r2 = this.tokenizer.rules.inline.blockSkip.exec(n)) != null; ) i = r2[2] ? r2[2].length : 0, n = n.slice(0, r2.index + i) + "[" + "a".repeat(r2[0].length - i - 2) + "]" + n.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);
|
|
23489
23501
|
n = this.options.hooks?.emStrongMask?.call({ lexer: this }, n) ?? n;
|
|
23490
|
-
let
|
|
23502
|
+
let s2 = false, a = "";
|
|
23491
23503
|
for (; e; ) {
|
|
23492
|
-
|
|
23504
|
+
s2 || (a = ""), s2 = false;
|
|
23493
23505
|
let o;
|
|
23494
23506
|
if (this.options.extensions?.inline?.some((u) => (o = u.call({ lexer: this }, e, t)) ? (e = e.substring(o.raw.length), t.push(o), true) : false)) continue;
|
|
23495
23507
|
if (o = this.tokenizer.escape(e)) {
|
|
@@ -23510,7 +23522,7 @@ var b = class l {
|
|
|
23510
23522
|
o.type === "text" && u?.type === "text" ? (u.raw += o.raw, u.text += o.text) : t.push(o);
|
|
23511
23523
|
continue;
|
|
23512
23524
|
}
|
|
23513
|
-
if (o = this.tokenizer.emStrong(e, n,
|
|
23525
|
+
if (o = this.tokenizer.emStrong(e, n, a)) {
|
|
23514
23526
|
e = e.substring(o.raw.length), t.push(o);
|
|
23515
23527
|
continue;
|
|
23516
23528
|
}
|
|
@@ -23534,15 +23546,15 @@ var b = class l {
|
|
|
23534
23546
|
e = e.substring(o.raw.length), t.push(o);
|
|
23535
23547
|
continue;
|
|
23536
23548
|
}
|
|
23537
|
-
let
|
|
23549
|
+
let p = e;
|
|
23538
23550
|
if (this.options.extensions?.startInline) {
|
|
23539
|
-
let u = 1 / 0,
|
|
23540
|
-
this.options.extensions.startInline.forEach((
|
|
23541
|
-
|
|
23542
|
-
}), u < 1 / 0 && u >= 0 && (
|
|
23551
|
+
let u = 1 / 0, c2 = e.slice(1), g;
|
|
23552
|
+
this.options.extensions.startInline.forEach((h2) => {
|
|
23553
|
+
g = h2.call({ lexer: this }, c2), typeof g == "number" && g >= 0 && (u = Math.min(u, g));
|
|
23554
|
+
}), u < 1 / 0 && u >= 0 && (p = e.substring(0, u + 1));
|
|
23543
23555
|
}
|
|
23544
|
-
if (o = this.tokenizer.inlineText(
|
|
23545
|
-
e = e.substring(o.raw.length), o.raw.slice(-1) !== "_" && (
|
|
23556
|
+
if (o = this.tokenizer.inlineText(p)) {
|
|
23557
|
+
e = e.substring(o.raw.length), o.raw.slice(-1) !== "_" && (a = o.raw.slice(-1)), s2 = true;
|
|
23546
23558
|
let u = t.at(-1);
|
|
23547
23559
|
u?.type === "text" ? (u.raw += o.raw, u.text += o.text) : t.push(o);
|
|
23548
23560
|
continue;
|
|
@@ -23562,7 +23574,7 @@ var P = class {
|
|
|
23562
23574
|
constructor(e) {
|
|
23563
23575
|
__publicField$2(this, "options");
|
|
23564
23576
|
__publicField$2(this, "parser");
|
|
23565
|
-
this.options = e ||
|
|
23577
|
+
this.options = e || T;
|
|
23566
23578
|
}
|
|
23567
23579
|
space(e) {
|
|
23568
23580
|
return "";
|
|
@@ -23595,9 +23607,9 @@ ${this.parser.parse(e)}</blockquote>
|
|
|
23595
23607
|
}
|
|
23596
23608
|
list(e) {
|
|
23597
23609
|
let t = e.ordered, n = e.start, r2 = "";
|
|
23598
|
-
for (let
|
|
23599
|
-
let
|
|
23600
|
-
r2 += this.listitem(
|
|
23610
|
+
for (let a = 0; a < e.items.length; a++) {
|
|
23611
|
+
let o = e.items[a];
|
|
23612
|
+
r2 += this.listitem(o);
|
|
23601
23613
|
}
|
|
23602
23614
|
let i = t ? "ol" : "ul", s2 = t && n !== 1 ? ' start="' + n + '"' : "";
|
|
23603
23615
|
return "<" + i + s2 + `>
|
|
@@ -23628,7 +23640,7 @@ ${this.parser.parse(e)}</blockquote>
|
|
|
23628
23640
|
for (let i = 0; i < e.rows.length; i++) {
|
|
23629
23641
|
let s2 = e.rows[i];
|
|
23630
23642
|
n = "";
|
|
23631
|
-
for (let
|
|
23643
|
+
for (let a = 0; a < s2.length; a++) n += this.tablecell(s2[a]);
|
|
23632
23644
|
r2 += this.tablerow({ text: n });
|
|
23633
23645
|
}
|
|
23634
23646
|
return r2 && (r2 = `<tbody>${r2}</tbody>`), `<table>
|
|
@@ -23710,12 +23722,12 @@ var $ = class {
|
|
|
23710
23722
|
return "";
|
|
23711
23723
|
}
|
|
23712
23724
|
};
|
|
23713
|
-
var
|
|
23725
|
+
var b = class l2 {
|
|
23714
23726
|
constructor(e) {
|
|
23715
23727
|
__publicField$2(this, "options");
|
|
23716
23728
|
__publicField$2(this, "renderer");
|
|
23717
23729
|
__publicField$2(this, "textRenderer");
|
|
23718
|
-
this.options = e ||
|
|
23730
|
+
this.options = e || T, this.options.renderer = this.options.renderer || new P(), this.renderer = this.options.renderer, this.renderer.options = this.options, this.renderer.parser = this, this.textRenderer = new $();
|
|
23719
23731
|
}
|
|
23720
23732
|
static parse(e, t) {
|
|
23721
23733
|
return new l2(t).parse(e);
|
|
@@ -23728,9 +23740,9 @@ var R = class l2 {
|
|
|
23728
23740
|
for (let r2 = 0; r2 < e.length; r2++) {
|
|
23729
23741
|
let i = e[r2];
|
|
23730
23742
|
if (this.options.extensions?.renderers?.[i.type]) {
|
|
23731
|
-
let
|
|
23732
|
-
if (
|
|
23733
|
-
n +=
|
|
23743
|
+
let a = i, o = this.options.extensions.renderers[a.type].call({ parser: this }, a);
|
|
23744
|
+
if (o !== false || !["space", "hr", "heading", "code", "table", "blockquote", "list", "html", "def", "paragraph", "text"].includes(a.type)) {
|
|
23745
|
+
n += o || "";
|
|
23734
23746
|
continue;
|
|
23735
23747
|
}
|
|
23736
23748
|
}
|
|
@@ -23777,16 +23789,16 @@ var R = class l2 {
|
|
|
23777
23789
|
continue;
|
|
23778
23790
|
}
|
|
23779
23791
|
case "text": {
|
|
23780
|
-
let
|
|
23781
|
-
for (; r2 + 1 < e.length && e[r2 + 1].type === "text"; )
|
|
23782
|
-
` + this.renderer.text(
|
|
23783
|
-
t ? n += this.renderer.paragraph({ type: "paragraph", raw:
|
|
23792
|
+
let a = s2, o = this.renderer.text(a);
|
|
23793
|
+
for (; r2 + 1 < e.length && e[r2 + 1].type === "text"; ) a = e[++r2], o += `
|
|
23794
|
+
` + this.renderer.text(a);
|
|
23795
|
+
t ? n += this.renderer.paragraph({ type: "paragraph", raw: o, text: o, tokens: [{ type: "text", raw: o, text: o, escaped: true }] }) : n += o;
|
|
23784
23796
|
continue;
|
|
23785
23797
|
}
|
|
23786
23798
|
default: {
|
|
23787
|
-
let
|
|
23788
|
-
if (this.options.silent) return console.error(
|
|
23789
|
-
throw new Error(
|
|
23799
|
+
let a = 'Token with "' + s2.type + '" type was not found.';
|
|
23800
|
+
if (this.options.silent) return console.error(a), "";
|
|
23801
|
+
throw new Error(a);
|
|
23790
23802
|
}
|
|
23791
23803
|
}
|
|
23792
23804
|
}
|
|
@@ -23797,9 +23809,9 @@ var R = class l2 {
|
|
|
23797
23809
|
for (let r2 = 0; r2 < e.length; r2++) {
|
|
23798
23810
|
let i = e[r2];
|
|
23799
23811
|
if (this.options.extensions?.renderers?.[i.type]) {
|
|
23800
|
-
let
|
|
23801
|
-
if (
|
|
23802
|
-
n +=
|
|
23812
|
+
let a = this.options.extensions.renderers[i.type].call({ parser: this }, i);
|
|
23813
|
+
if (a !== false || !["escape", "html", "link", "image", "strong", "em", "codespan", "br", "del", "text"].includes(i.type)) {
|
|
23814
|
+
n += a || "";
|
|
23803
23815
|
continue;
|
|
23804
23816
|
}
|
|
23805
23817
|
}
|
|
@@ -23846,9 +23858,9 @@ var R = class l2 {
|
|
|
23846
23858
|
break;
|
|
23847
23859
|
}
|
|
23848
23860
|
default: {
|
|
23849
|
-
let
|
|
23850
|
-
if (this.options.silent) return console.error(
|
|
23851
|
-
throw new Error(
|
|
23861
|
+
let a = 'Token with "' + s2.type + '" type was not found.';
|
|
23862
|
+
if (this.options.silent) return console.error(a), "";
|
|
23863
|
+
throw new Error(a);
|
|
23852
23864
|
}
|
|
23853
23865
|
}
|
|
23854
23866
|
}
|
|
@@ -23859,7 +23871,7 @@ var S = (_a = class {
|
|
|
23859
23871
|
constructor(e) {
|
|
23860
23872
|
__publicField$2(this, "options");
|
|
23861
23873
|
__publicField$2(this, "block");
|
|
23862
|
-
this.options = e ||
|
|
23874
|
+
this.options = e || T;
|
|
23863
23875
|
}
|
|
23864
23876
|
preprocess(e) {
|
|
23865
23877
|
return e;
|
|
@@ -23874,10 +23886,10 @@ var S = (_a = class {
|
|
|
23874
23886
|
return e;
|
|
23875
23887
|
}
|
|
23876
23888
|
provideLexer() {
|
|
23877
|
-
return this.block ?
|
|
23889
|
+
return this.block ? x.lex : x.lexInline;
|
|
23878
23890
|
}
|
|
23879
23891
|
provideParser() {
|
|
23880
|
-
return this.block ?
|
|
23892
|
+
return this.block ? b.parse : b.parseInline;
|
|
23881
23893
|
}
|
|
23882
23894
|
}, __publicField$2(_a, "passThroughHooks", /* @__PURE__ */ new Set(["preprocess", "postprocess", "processAllTokens", "emStrongMask"])), __publicField$2(_a, "passThroughHooksRespectAsync", /* @__PURE__ */ new Set(["preprocess", "postprocess", "processAllTokens"])), _a);
|
|
23883
23895
|
var B = class {
|
|
@@ -23886,10 +23898,10 @@ var B = class {
|
|
|
23886
23898
|
__publicField$2(this, "options", this.setOptions);
|
|
23887
23899
|
__publicField$2(this, "parse", this.parseMarkdown(true));
|
|
23888
23900
|
__publicField$2(this, "parseInline", this.parseMarkdown(false));
|
|
23889
|
-
__publicField$2(this, "Parser",
|
|
23901
|
+
__publicField$2(this, "Parser", b);
|
|
23890
23902
|
__publicField$2(this, "Renderer", P);
|
|
23891
23903
|
__publicField$2(this, "TextRenderer", $);
|
|
23892
|
-
__publicField$2(this, "Lexer",
|
|
23904
|
+
__publicField$2(this, "Lexer", x);
|
|
23893
23905
|
__publicField$2(this, "Tokenizer", y);
|
|
23894
23906
|
__publicField$2(this, "Hooks", S);
|
|
23895
23907
|
this.use(...e);
|
|
@@ -23900,7 +23912,7 @@ var B = class {
|
|
|
23900
23912
|
case "table": {
|
|
23901
23913
|
let i = r2;
|
|
23902
23914
|
for (let s2 of i.header) n = n.concat(this.walkTokens(s2.tokens, t));
|
|
23903
|
-
for (let s2 of i.rows) for (let
|
|
23915
|
+
for (let s2 of i.rows) for (let a of s2) n = n.concat(this.walkTokens(a.tokens, t));
|
|
23904
23916
|
break;
|
|
23905
23917
|
}
|
|
23906
23918
|
case "list": {
|
|
@@ -23911,8 +23923,8 @@ var B = class {
|
|
|
23911
23923
|
default: {
|
|
23912
23924
|
let i = r2;
|
|
23913
23925
|
this.defaults.extensions?.childTokens?.[i.type] ? this.defaults.extensions.childTokens[i.type].forEach((s2) => {
|
|
23914
|
-
let
|
|
23915
|
-
n = n.concat(this.walkTokens(
|
|
23926
|
+
let a = i[s2].flat(1 / 0);
|
|
23927
|
+
n = n.concat(this.walkTokens(a, t));
|
|
23916
23928
|
}) : i.tokens && (n = n.concat(this.walkTokens(i.tokens, t)));
|
|
23917
23929
|
}
|
|
23918
23930
|
}
|
|
@@ -23926,9 +23938,9 @@ var B = class {
|
|
|
23926
23938
|
if (!i.name) throw new Error("extension name required");
|
|
23927
23939
|
if ("renderer" in i) {
|
|
23928
23940
|
let s2 = t.renderers[i.name];
|
|
23929
|
-
s2 ? t.renderers[i.name] = function(...
|
|
23930
|
-
let
|
|
23931
|
-
return
|
|
23941
|
+
s2 ? t.renderers[i.name] = function(...a) {
|
|
23942
|
+
let o = i.renderer.apply(this, a);
|
|
23943
|
+
return o === false && (o = s2.apply(this, a)), o;
|
|
23932
23944
|
} : t.renderers[i.name] = i.renderer;
|
|
23933
23945
|
}
|
|
23934
23946
|
if ("tokenizer" in i) {
|
|
@@ -23942,10 +23954,10 @@ var B = class {
|
|
|
23942
23954
|
for (let s2 in n.renderer) {
|
|
23943
23955
|
if (!(s2 in i)) throw new Error(`renderer '${s2}' does not exist`);
|
|
23944
23956
|
if (["options", "parser"].includes(s2)) continue;
|
|
23945
|
-
let
|
|
23946
|
-
i[
|
|
23947
|
-
let c2 =
|
|
23948
|
-
return c2 === false && (c2 =
|
|
23957
|
+
let a = s2, o = n.renderer[a], p = i[a];
|
|
23958
|
+
i[a] = (...u) => {
|
|
23959
|
+
let c2 = o.apply(i, u);
|
|
23960
|
+
return c2 === false && (c2 = p.apply(i, u)), c2 || "";
|
|
23949
23961
|
};
|
|
23950
23962
|
}
|
|
23951
23963
|
r2.renderer = i;
|
|
@@ -23955,10 +23967,10 @@ var B = class {
|
|
|
23955
23967
|
for (let s2 in n.tokenizer) {
|
|
23956
23968
|
if (!(s2 in i)) throw new Error(`tokenizer '${s2}' does not exist`);
|
|
23957
23969
|
if (["options", "rules", "lexer"].includes(s2)) continue;
|
|
23958
|
-
let
|
|
23959
|
-
i[
|
|
23960
|
-
let c2 =
|
|
23961
|
-
return c2 === false && (c2 =
|
|
23970
|
+
let a = s2, o = n.tokenizer[a], p = i[a];
|
|
23971
|
+
i[a] = (...u) => {
|
|
23972
|
+
let c2 = o.apply(i, u);
|
|
23973
|
+
return c2 === false && (c2 = p.apply(i, u)), c2;
|
|
23962
23974
|
};
|
|
23963
23975
|
}
|
|
23964
23976
|
r2.tokenizer = i;
|
|
@@ -23968,23 +23980,30 @@ var B = class {
|
|
|
23968
23980
|
for (let s2 in n.hooks) {
|
|
23969
23981
|
if (!(s2 in i)) throw new Error(`hook '${s2}' does not exist`);
|
|
23970
23982
|
if (["options", "block"].includes(s2)) continue;
|
|
23971
|
-
let
|
|
23972
|
-
S.passThroughHooks.has(s2) ? i[
|
|
23973
|
-
if (this.defaults.async && S.passThroughHooksRespectAsync.has(s2)) return
|
|
23974
|
-
|
|
23975
|
-
|
|
23976
|
-
|
|
23977
|
-
let c2 =
|
|
23978
|
-
return
|
|
23983
|
+
let a = s2, o = n.hooks[a], p = i[a];
|
|
23984
|
+
S.passThroughHooks.has(s2) ? i[a] = (u) => {
|
|
23985
|
+
if (this.defaults.async && S.passThroughHooksRespectAsync.has(s2)) return (async () => {
|
|
23986
|
+
let g = await o.call(i, u);
|
|
23987
|
+
return p.call(i, g);
|
|
23988
|
+
})();
|
|
23989
|
+
let c2 = o.call(i, u);
|
|
23990
|
+
return p.call(i, c2);
|
|
23991
|
+
} : i[a] = (...u) => {
|
|
23992
|
+
if (this.defaults.async) return (async () => {
|
|
23993
|
+
let g = await o.apply(i, u);
|
|
23994
|
+
return g === false && (g = await p.apply(i, u)), g;
|
|
23995
|
+
})();
|
|
23996
|
+
let c2 = o.apply(i, u);
|
|
23997
|
+
return c2 === false && (c2 = p.apply(i, u)), c2;
|
|
23979
23998
|
};
|
|
23980
23999
|
}
|
|
23981
24000
|
r2.hooks = i;
|
|
23982
24001
|
}
|
|
23983
24002
|
if (n.walkTokens) {
|
|
23984
24003
|
let i = this.defaults.walkTokens, s2 = n.walkTokens;
|
|
23985
|
-
r2.walkTokens = function(
|
|
23986
|
-
let
|
|
23987
|
-
return
|
|
24004
|
+
r2.walkTokens = function(a) {
|
|
24005
|
+
let o = [];
|
|
24006
|
+
return o.push(s2.call(this, a)), i && (o = o.concat(i.call(this, a))), o;
|
|
23988
24007
|
};
|
|
23989
24008
|
}
|
|
23990
24009
|
this.defaults = { ...this.defaults, ...r2 };
|
|
@@ -23994,28 +24013,31 @@ var B = class {
|
|
|
23994
24013
|
return this.defaults = { ...this.defaults, ...e }, this;
|
|
23995
24014
|
}
|
|
23996
24015
|
lexer(e, t) {
|
|
23997
|
-
return
|
|
24016
|
+
return x.lex(e, t ?? this.defaults);
|
|
23998
24017
|
}
|
|
23999
24018
|
parser(e, t) {
|
|
24000
|
-
return
|
|
24019
|
+
return b.parse(e, t ?? this.defaults);
|
|
24001
24020
|
}
|
|
24002
24021
|
parseMarkdown(e) {
|
|
24003
24022
|
return (n, r2) => {
|
|
24004
|
-
let i = { ...r2 }, s2 = { ...this.defaults, ...i },
|
|
24005
|
-
if (this.defaults.async === true && i.async === false) return
|
|
24006
|
-
if (typeof n > "u" || n === null) return
|
|
24007
|
-
if (typeof n != "string") return
|
|
24008
|
-
s2.hooks && (s2.hooks.options = s2, s2.hooks.block = e)
|
|
24009
|
-
|
|
24010
|
-
|
|
24023
|
+
let i = { ...r2 }, s2 = { ...this.defaults, ...i }, a = this.onError(!!s2.silent, !!s2.async);
|
|
24024
|
+
if (this.defaults.async === true && i.async === false) return a(new Error("marked(): The async option was set to true by an extension. Remove async: false from the parse options object to return a Promise."));
|
|
24025
|
+
if (typeof n > "u" || n === null) return a(new Error("marked(): input parameter is undefined or null"));
|
|
24026
|
+
if (typeof n != "string") return a(new Error("marked(): input parameter is of type " + Object.prototype.toString.call(n) + ", string expected"));
|
|
24027
|
+
if (s2.hooks && (s2.hooks.options = s2, s2.hooks.block = e), s2.async) return (async () => {
|
|
24028
|
+
let o = s2.hooks ? await s2.hooks.preprocess(n) : n, u = await (s2.hooks ? await s2.hooks.provideLexer() : e ? x.lex : x.lexInline)(o, s2), c2 = s2.hooks ? await s2.hooks.processAllTokens(u) : u;
|
|
24029
|
+
s2.walkTokens && await Promise.all(this.walkTokens(c2, s2.walkTokens));
|
|
24030
|
+
let h2 = await (s2.hooks ? await s2.hooks.provideParser() : e ? b.parse : b.parseInline)(c2, s2);
|
|
24031
|
+
return s2.hooks ? await s2.hooks.postprocess(h2) : h2;
|
|
24032
|
+
})().catch(a);
|
|
24011
24033
|
try {
|
|
24012
24034
|
s2.hooks && (n = s2.hooks.preprocess(n));
|
|
24013
|
-
let p =
|
|
24035
|
+
let p = (s2.hooks ? s2.hooks.provideLexer() : e ? x.lex : x.lexInline)(n, s2);
|
|
24014
24036
|
s2.hooks && (p = s2.hooks.processAllTokens(p)), s2.walkTokens && this.walkTokens(p, s2.walkTokens);
|
|
24015
|
-
let c2 =
|
|
24037
|
+
let c2 = (s2.hooks ? s2.hooks.provideParser() : e ? b.parse : b.parseInline)(p, s2);
|
|
24016
24038
|
return s2.hooks && (c2 = s2.hooks.postprocess(c2)), c2;
|
|
24017
|
-
} catch (
|
|
24018
|
-
return o
|
|
24039
|
+
} catch (o) {
|
|
24040
|
+
return a(o);
|
|
24019
24041
|
}
|
|
24020
24042
|
};
|
|
24021
24043
|
}
|
|
@@ -24032,38 +24054,38 @@ Please report this to https://github.com/markedjs/marked.`, e) {
|
|
|
24032
24054
|
}
|
|
24033
24055
|
};
|
|
24034
24056
|
var _ = new B();
|
|
24035
|
-
function
|
|
24057
|
+
function k$1(l3, e) {
|
|
24036
24058
|
return _.parse(l3, e);
|
|
24037
24059
|
}
|
|
24038
|
-
|
|
24039
|
-
return _.setOptions(l3),
|
|
24060
|
+
k$1.options = k$1.setOptions = function(l3) {
|
|
24061
|
+
return _.setOptions(l3), k$1.defaults = _.defaults, G(k$1.defaults), k$1;
|
|
24040
24062
|
};
|
|
24041
|
-
|
|
24042
|
-
|
|
24043
|
-
|
|
24044
|
-
return _.use(...l3),
|
|
24063
|
+
k$1.getDefaults = L;
|
|
24064
|
+
k$1.defaults = T;
|
|
24065
|
+
k$1.use = function(...l3) {
|
|
24066
|
+
return _.use(...l3), k$1.defaults = _.defaults, G(k$1.defaults), k$1;
|
|
24045
24067
|
};
|
|
24046
|
-
|
|
24068
|
+
k$1.walkTokens = function(l3, e) {
|
|
24047
24069
|
return _.walkTokens(l3, e);
|
|
24048
24070
|
};
|
|
24049
|
-
|
|
24050
|
-
|
|
24051
|
-
|
|
24052
|
-
|
|
24053
|
-
|
|
24054
|
-
|
|
24055
|
-
|
|
24056
|
-
|
|
24057
|
-
|
|
24058
|
-
|
|
24059
|
-
|
|
24060
|
-
|
|
24061
|
-
|
|
24062
|
-
|
|
24063
|
-
|
|
24064
|
-
|
|
24065
|
-
|
|
24066
|
-
|
|
24071
|
+
k$1.parseInline = _.parseInline;
|
|
24072
|
+
k$1.Parser = b;
|
|
24073
|
+
k$1.parser = b.parse;
|
|
24074
|
+
k$1.Renderer = P;
|
|
24075
|
+
k$1.TextRenderer = $;
|
|
24076
|
+
k$1.Lexer = x;
|
|
24077
|
+
k$1.lexer = x.lex;
|
|
24078
|
+
k$1.Tokenizer = y;
|
|
24079
|
+
k$1.Hooks = S;
|
|
24080
|
+
k$1.parse = k$1;
|
|
24081
|
+
k$1.options;
|
|
24082
|
+
k$1.setOptions;
|
|
24083
|
+
k$1.use;
|
|
24084
|
+
k$1.walkTokens;
|
|
24085
|
+
k$1.parseInline;
|
|
24086
|
+
b.parse;
|
|
24087
|
+
x.lex;
|
|
24088
|
+
k$1.use({
|
|
24067
24089
|
breaks: false,
|
|
24068
24090
|
// Use proper paragraphs, not <br> tags
|
|
24069
24091
|
gfm: true
|
|
@@ -24074,7 +24096,7 @@ function createDocFromMarkdown(markdown, schema, options = {}) {
|
|
|
24074
24096
|
return createDocFromHTML(html, schema, options);
|
|
24075
24097
|
}
|
|
24076
24098
|
function convertMarkdownToHTML(markdown) {
|
|
24077
|
-
let html =
|
|
24099
|
+
let html = k$1.parse(markdown, { async: false });
|
|
24078
24100
|
return html.replace(/<\/p>\n<ul>/g, "</p>\n<p> </p>\n<ul>").replace(/<\/p>\n<ol>/g, "</p>\n<p> </p>\n<ol>").replace(/<\/ul>\n<h/g, "</ul>\n<p> </p>\n<h").replace(/<\/ol>\n<h/g, "</ol>\n<p> </p>\n<h");
|
|
24079
24101
|
}
|
|
24080
24102
|
function processContent({ content, type: type2, schema }) {
|
|
@@ -28698,18 +28720,18 @@ const handleShapeGroup = (params2, node, graphicData, size2, padding, marginOffs
|
|
|
28698
28720
|
const rawY = shapeOff?.attributes?.["y"] ? parseFloat(shapeOff.attributes["y"]) : 0;
|
|
28699
28721
|
const rawWidth = shapeExt?.attributes?.["cx"] ? parseFloat(shapeExt.attributes["cx"]) : 914400;
|
|
28700
28722
|
const rawHeight = shapeExt?.attributes?.["cy"] ? parseFloat(shapeExt.attributes["cy"]) : 914400;
|
|
28701
|
-
let
|
|
28723
|
+
let x2, y2, width, height;
|
|
28702
28724
|
if (groupTransform.childWidth && groupTransform.childHeight) {
|
|
28703
28725
|
const scaleX = groupTransform.width / groupTransform.childWidth;
|
|
28704
28726
|
const scaleY = groupTransform.height / groupTransform.childHeight;
|
|
28705
28727
|
const childOriginX = groupTransform.childOriginXEmu || 0;
|
|
28706
28728
|
const childOriginY = groupTransform.childOriginYEmu || 0;
|
|
28707
|
-
|
|
28729
|
+
x2 = groupTransform.x + emuToPixels((rawX - childOriginX) * scaleX);
|
|
28708
28730
|
y2 = groupTransform.y + emuToPixels((rawY - childOriginY) * scaleY);
|
|
28709
28731
|
width = emuToPixels(rawWidth * scaleX);
|
|
28710
28732
|
height = emuToPixels(rawHeight * scaleY);
|
|
28711
28733
|
} else {
|
|
28712
|
-
|
|
28734
|
+
x2 = emuToPixels(rawX);
|
|
28713
28735
|
y2 = emuToPixels(rawY);
|
|
28714
28736
|
width = emuToPixels(rawWidth);
|
|
28715
28737
|
height = emuToPixels(rawHeight);
|
|
@@ -28728,7 +28750,7 @@ const handleShapeGroup = (params2, node, graphicData, size2, padding, marginOffs
|
|
|
28728
28750
|
shapeType: "vectorShape",
|
|
28729
28751
|
attrs: {
|
|
28730
28752
|
kind: shapeKind,
|
|
28731
|
-
x,
|
|
28753
|
+
x: x2,
|
|
28732
28754
|
y: y2,
|
|
28733
28755
|
width,
|
|
28734
28756
|
height,
|
|
@@ -32341,8 +32363,15 @@ const encode$4 = (params2, encodedAttrs = {}) => {
|
|
|
32341
32363
|
});
|
|
32342
32364
|
encodedAttrs.importedAuthor = `${encodedAttrs.author} (imported)`;
|
|
32343
32365
|
subs.forEach((subElement) => {
|
|
32344
|
-
|
|
32345
|
-
subElement
|
|
32366
|
+
subElement.marks = [];
|
|
32367
|
+
if (subElement?.content?.[0]) {
|
|
32368
|
+
if (subElement.content[0].marks === void 0) {
|
|
32369
|
+
subElement.content[0].marks = [];
|
|
32370
|
+
}
|
|
32371
|
+
if (subElement.content[0].type === "text") {
|
|
32372
|
+
subElement.content[0].marks.push({ type: "trackDelete", attrs: encodedAttrs });
|
|
32373
|
+
}
|
|
32374
|
+
}
|
|
32346
32375
|
});
|
|
32347
32376
|
return subs;
|
|
32348
32377
|
};
|
|
@@ -32401,8 +32430,15 @@ const encode$3 = (params2, encodedAttrs = {}) => {
|
|
|
32401
32430
|
});
|
|
32402
32431
|
encodedAttrs.importedAuthor = `${encodedAttrs.author} (imported)`;
|
|
32403
32432
|
subs.forEach((subElement) => {
|
|
32404
|
-
|
|
32405
|
-
subElement
|
|
32433
|
+
subElement.marks = [];
|
|
32434
|
+
if (subElement?.content?.[0]) {
|
|
32435
|
+
if (subElement.content[0].marks === void 0) {
|
|
32436
|
+
subElement.content[0].marks = [];
|
|
32437
|
+
}
|
|
32438
|
+
if (subElement.content[0].type === "text") {
|
|
32439
|
+
subElement.content[0].marks.push({ type: "trackInsert", attrs: encodedAttrs });
|
|
32440
|
+
}
|
|
32441
|
+
}
|
|
32406
32442
|
});
|
|
32407
32443
|
return subs;
|
|
32408
32444
|
};
|
|
@@ -33132,7 +33168,11 @@ function importCommentData({ docx, editor, converter }) {
|
|
|
33132
33168
|
const generateCommentsWithExtendedData = ({ docx, comments }) => {
|
|
33133
33169
|
if (!comments?.length) return [];
|
|
33134
33170
|
const commentsExtended = docx["word/commentsExtended.xml"];
|
|
33135
|
-
if (!commentsExtended)
|
|
33171
|
+
if (!commentsExtended) {
|
|
33172
|
+
const commentRanges = extractCommentRangesFromDocument(docx);
|
|
33173
|
+
const commentsWithThreading = detectThreadingFromRanges(comments, commentRanges);
|
|
33174
|
+
return commentsWithThreading.map((comment) => ({ ...comment, isDone: comment.isDone ?? false }));
|
|
33175
|
+
}
|
|
33136
33176
|
const { elements: initialElements = [] } = commentsExtended;
|
|
33137
33177
|
if (!initialElements?.length) return comments.map((comment) => ({ ...comment, isDone: comment.isDone ?? false }));
|
|
33138
33178
|
const { elements = [] } = initialElements[0] ?? {};
|
|
@@ -33158,6 +33198,79 @@ const getExtendedDetails = (commentEx) => {
|
|
|
33158
33198
|
const paraIdParent = attributes["w15:paraIdParent"];
|
|
33159
33199
|
return { paraId, isDone, paraIdParent };
|
|
33160
33200
|
};
|
|
33201
|
+
const extractCommentRangesFromDocument = (docx) => {
|
|
33202
|
+
const documentXml = docx["word/document.xml"];
|
|
33203
|
+
if (!documentXml) {
|
|
33204
|
+
return [];
|
|
33205
|
+
}
|
|
33206
|
+
const pendingComments = [];
|
|
33207
|
+
const walkElements = (elements) => {
|
|
33208
|
+
if (!elements || !Array.isArray(elements)) return;
|
|
33209
|
+
elements.forEach((element) => {
|
|
33210
|
+
if (element.name === "w:commentRangeStart") {
|
|
33211
|
+
const commentId = element.attributes?.["w:id"];
|
|
33212
|
+
if (commentId !== void 0) {
|
|
33213
|
+
pendingComments.push({
|
|
33214
|
+
type: "start",
|
|
33215
|
+
commentId: String(commentId)
|
|
33216
|
+
});
|
|
33217
|
+
}
|
|
33218
|
+
} else if (element.name === "w:commentRangeEnd") {
|
|
33219
|
+
const commentId = element.attributes?.["w:id"];
|
|
33220
|
+
if (commentId !== void 0) {
|
|
33221
|
+
pendingComments.push({
|
|
33222
|
+
type: "end",
|
|
33223
|
+
commentId: String(commentId)
|
|
33224
|
+
});
|
|
33225
|
+
}
|
|
33226
|
+
}
|
|
33227
|
+
if (element.elements && Array.isArray(element.elements)) {
|
|
33228
|
+
walkElements(element.elements);
|
|
33229
|
+
}
|
|
33230
|
+
});
|
|
33231
|
+
};
|
|
33232
|
+
if (documentXml.elements && documentXml.elements.length > 0) {
|
|
33233
|
+
const body = documentXml.elements[0];
|
|
33234
|
+
if (body.elements) {
|
|
33235
|
+
walkElements(body.elements);
|
|
33236
|
+
}
|
|
33237
|
+
}
|
|
33238
|
+
return pendingComments;
|
|
33239
|
+
};
|
|
33240
|
+
const detectThreadingFromRanges = (comments, rangeEvents) => {
|
|
33241
|
+
if (!rangeEvents || rangeEvents.length === 0) {
|
|
33242
|
+
return comments;
|
|
33243
|
+
}
|
|
33244
|
+
const openRanges = [];
|
|
33245
|
+
const parentMap = /* @__PURE__ */ new Map();
|
|
33246
|
+
rangeEvents.forEach((event) => {
|
|
33247
|
+
if (event.type === "start") {
|
|
33248
|
+
if (openRanges.length > 0) {
|
|
33249
|
+
const parentCommentId = openRanges[openRanges.length - 1];
|
|
33250
|
+
parentMap.set(event.commentId, parentCommentId);
|
|
33251
|
+
}
|
|
33252
|
+
openRanges.push(event.commentId);
|
|
33253
|
+
} else if (event.type === "end") {
|
|
33254
|
+
const index2 = openRanges.lastIndexOf(event.commentId);
|
|
33255
|
+
if (index2 !== -1) {
|
|
33256
|
+
openRanges.splice(index2, 1);
|
|
33257
|
+
}
|
|
33258
|
+
}
|
|
33259
|
+
});
|
|
33260
|
+
return comments.map((comment) => {
|
|
33261
|
+
const parentCommentId = parentMap.get(comment.importedId);
|
|
33262
|
+
if (parentCommentId) {
|
|
33263
|
+
const parentComment = comments.find((c2) => c2.importedId === parentCommentId);
|
|
33264
|
+
if (parentComment) {
|
|
33265
|
+
return {
|
|
33266
|
+
...comment,
|
|
33267
|
+
parentCommentId: parentComment.commentId
|
|
33268
|
+
};
|
|
33269
|
+
}
|
|
33270
|
+
}
|
|
33271
|
+
return comment;
|
|
33272
|
+
});
|
|
33273
|
+
};
|
|
33161
33274
|
const RELATIONSHIP_TYPES = (
|
|
33162
33275
|
/** @type {const} */
|
|
33163
33276
|
{
|
|
@@ -35343,7 +35456,7 @@ const prepareCommentParaIds = (comment) => {
|
|
|
35343
35456
|
return newComment;
|
|
35344
35457
|
};
|
|
35345
35458
|
const getCommentDefinition = (comment, commentId, allComments, editor) => {
|
|
35346
|
-
const translatedText =
|
|
35459
|
+
const translatedText = translator$1p.decode({ editor, node: comment.commentJSON });
|
|
35347
35460
|
const attributes = {
|
|
35348
35461
|
"w:id": String(commentId),
|
|
35349
35462
|
"w:author": comment.creatorName || comment.importedAuthor?.name,
|
|
@@ -35382,10 +35495,12 @@ const toIsoNoFractional = (unixMillis) => {
|
|
|
35382
35495
|
const updateCommentsXml = (commentDefs = [], commentsXml) => {
|
|
35383
35496
|
const newCommentsXml = carbonCopy(commentsXml);
|
|
35384
35497
|
commentDefs.forEach((commentDef) => {
|
|
35385
|
-
const
|
|
35498
|
+
const paraNode = commentDef.elements[0];
|
|
35499
|
+
if (!paraNode.attributes) paraNode.attributes = {};
|
|
35500
|
+
const elements = paraNode.elements;
|
|
35386
35501
|
elements.unshift(COMMENT_REF);
|
|
35387
35502
|
const paraId = commentDef.attributes["w15:paraId"];
|
|
35388
|
-
|
|
35503
|
+
paraNode.attributes["w14:paraId"] = paraId;
|
|
35389
35504
|
commentDef.attributes = {
|
|
35390
35505
|
"w:id": commentDef.attributes["w:id"],
|
|
35391
35506
|
"w:author": commentDef.attributes["w:author"],
|
|
@@ -35445,7 +35560,7 @@ const updateCommentsIdsAndExtensible = (comments = [], commentsIds, extensible)
|
|
|
35445
35560
|
name: "w16cex:commentExtensible",
|
|
35446
35561
|
attributes: {
|
|
35447
35562
|
"w16cex:durableId": newDurableId,
|
|
35448
|
-
"w16cex:dateUtc": toIsoNoFractional()
|
|
35563
|
+
"w16cex:dateUtc": toIsoNoFractional(comment.createdTime)
|
|
35449
35564
|
}
|
|
35450
35565
|
};
|
|
35451
35566
|
extensibleUpdated.elements[0].elements.push(newExtensible);
|
|
@@ -35758,7 +35873,7 @@ const _SuperConverter = class _SuperConverter2 {
|
|
|
35758
35873
|
static getStoredSuperdocVersion(docx) {
|
|
35759
35874
|
return _SuperConverter2.getStoredCustomProperty(docx, "SuperdocVersion");
|
|
35760
35875
|
}
|
|
35761
|
-
static setStoredSuperdocVersion(docx = this.convertedXml, version2 = "0.34.
|
|
35876
|
+
static setStoredSuperdocVersion(docx = this.convertedXml, version2 = "0.34.6-RC1") {
|
|
35762
35877
|
return _SuperConverter2.setStoredCustomProperty(docx, "SuperdocVersion", version2, false);
|
|
35763
35878
|
}
|
|
35764
35879
|
/**
|
|
@@ -36149,7 +36264,7 @@ prepareCommentsXmlFilesForExport_fn = function({ defs, exportType, commentsWithP
|
|
|
36149
36264
|
};
|
|
36150
36265
|
exportProcessHeadersFooters_fn = function({ isFinalDoc = false }) {
|
|
36151
36266
|
const relsData = this.convertedXml["word/_rels/document.xml.rels"];
|
|
36152
|
-
const relationships = relsData.elements.find((
|
|
36267
|
+
const relationships = relsData.elements.find((x2) => x2.name === "Relationships");
|
|
36153
36268
|
const newDocRels = [];
|
|
36154
36269
|
Object.entries(this.headers).forEach(([id, header], index2) => {
|
|
36155
36270
|
const fileName = relationships.elements.find((el) => el.attributes.Id === id)?.attributes.Target || `header${index2 + 1}.xml`;
|
|
@@ -36190,7 +36305,7 @@ exportProcessHeadersFooters_fn = function({ isFinalDoc = false }) {
|
|
|
36190
36305
|
}
|
|
36191
36306
|
this.convertedXml[`word/${fileName}`].elements[0].elements = bodyContent;
|
|
36192
36307
|
if (params2.relationships.length) {
|
|
36193
|
-
const relationships2 = this.convertedXml[`word/_rels/${fileName}.rels`]?.elements?.find((
|
|
36308
|
+
const relationships2 = this.convertedXml[`word/_rels/${fileName}.rels`]?.elements?.find((x2) => x2.name === "Relationships")?.elements || [];
|
|
36194
36309
|
this.convertedXml[`word/_rels/${fileName}.rels`] = {
|
|
36195
36310
|
declaration: this.initialJSON?.declaration,
|
|
36196
36311
|
elements: [
|
|
@@ -36244,7 +36359,7 @@ exportProcessHeadersFooters_fn = function({ isFinalDoc = false }) {
|
|
|
36244
36359
|
}
|
|
36245
36360
|
this.convertedXml[`word/${fileName}`].elements[0].elements = bodyContent;
|
|
36246
36361
|
if (params2.relationships.length) {
|
|
36247
|
-
const relationships2 = this.convertedXml[`word/_rels/${fileName}.rels`]?.elements?.find((
|
|
36362
|
+
const relationships2 = this.convertedXml[`word/_rels/${fileName}.rels`]?.elements?.find((x2) => x2.name === "Relationships")?.elements || [];
|
|
36248
36363
|
this.convertedXml[`word/_rels/${fileName}.rels`] = {
|
|
36249
36364
|
declaration: this.initialJSON?.declaration,
|
|
36250
36365
|
elements: [
|
|
@@ -36263,7 +36378,7 @@ exportProcessHeadersFooters_fn = function({ isFinalDoc = false }) {
|
|
|
36263
36378
|
};
|
|
36264
36379
|
exportProcessNewRelationships_fn = function(rels = []) {
|
|
36265
36380
|
const relsData = this.convertedXml["word/_rels/document.xml.rels"];
|
|
36266
|
-
const relationships = relsData.elements.find((
|
|
36381
|
+
const relationships = relsData.elements.find((x2) => x2.name === "Relationships");
|
|
36267
36382
|
relationships.elements = mergeRelationshipElements(relationships.elements, rels);
|
|
36268
36383
|
};
|
|
36269
36384
|
exportProcessMediaFiles_fn = async function(media = {}) {
|
|
@@ -36459,8 +36574,8 @@ function requireJszip_min() {
|
|
|
36459
36574
|
return n2;
|
|
36460
36575
|
}
|
|
36461
36576
|
function n(e2, t2, r22, n2, i2, s22) {
|
|
36462
|
-
var a, o, h2 = e2.file, u = e2.compression, l3 = s22 !==
|
|
36463
|
-
t2 && !r22 || (
|
|
36577
|
+
var a, o, h2 = e2.file, u = e2.compression, l3 = s22 !== O.utf8encode, f2 = I2.transformTo("string", s22(h2.name)), c2 = I2.transformTo("string", O.utf8encode(h2.name)), d2 = h2.comment, p = I2.transformTo("string", s22(d2)), m2 = I2.transformTo("string", O.utf8encode(d2)), _2 = c2.length !== h2.name.length, g = m2.length !== d2.length, b2 = "", v2 = "", y2 = "", w2 = h2.dir, k2 = h2.date, x2 = { crc32: 0, compressedSize: 0, uncompressedSize: 0 };
|
|
36578
|
+
t2 && !r22 || (x2.crc32 = e2.crc32, x2.compressedSize = e2.compressedSize, x2.uncompressedSize = e2.uncompressedSize);
|
|
36464
36579
|
var S2 = 0;
|
|
36465
36580
|
t2 && (S2 |= 8), l3 || !_2 && !g || (S2 |= 2048);
|
|
36466
36581
|
var z2 = 0, C2 = 0;
|
|
@@ -36471,9 +36586,9 @@ function requireJszip_min() {
|
|
|
36471
36586
|
return 63 & (e3 || 0);
|
|
36472
36587
|
})(h2.dosPermissions)), a = k2.getUTCHours(), a <<= 6, a |= k2.getUTCMinutes(), a <<= 5, a |= k2.getUTCSeconds() / 2, o = k2.getUTCFullYear() - 1980, o <<= 4, o |= k2.getUTCMonth() + 1, o <<= 5, o |= k2.getUTCDate(), _2 && (v2 = A2(1, 1) + A2(B2(f2), 4) + c2, b2 += "up" + A2(v2.length, 2) + v2), g && (y2 = A2(1, 1) + A2(B2(p), 4) + m2, b2 += "uc" + A2(y2.length, 2) + y2);
|
|
36473
36588
|
var E2 = "";
|
|
36474
|
-
return E2 += "\n\0", E2 += A2(S2, 2), E2 += u.magic, E2 += A2(a, 2), E2 += A2(o, 2), E2 += A2(
|
|
36589
|
+
return E2 += "\n\0", E2 += A2(S2, 2), E2 += u.magic, E2 += A2(a, 2), E2 += A2(o, 2), E2 += A2(x2.crc32, 4), E2 += A2(x2.compressedSize, 4), E2 += A2(x2.uncompressedSize, 4), E2 += A2(f2.length, 2), E2 += A2(b2.length, 2), { fileRecord: R.LOCAL_FILE_HEADER + E2 + f2 + b2, dirRecord: R.CENTRAL_FILE_HEADER + A2(C2, 2) + E2 + A2(p.length, 2) + "\0\0\0\0" + A2(z2, 4) + A2(n2, 4) + f2 + b2 + p };
|
|
36475
36590
|
}
|
|
36476
|
-
var I2 = e("../utils"), i = e("../stream/GenericWorker"),
|
|
36591
|
+
var I2 = e("../utils"), i = e("../stream/GenericWorker"), O = e("../utf8"), B2 = e("../crc32"), R = e("../signature");
|
|
36477
36592
|
function s2(e2, t2, r22, n2) {
|
|
36478
36593
|
i.call(this, "ZipFileWorker"), this.bytesWritten = 0, this.zipComment = t2, this.zipPlatform = r22, this.encodeFileName = n2, this.streamFiles = e2, this.accumulate = false, this.contentBuffer = [], this.dirRecords = [], this.currentSourceOffset = 0, this.entriesCount = 0, this.currentFile = null, this._sources = [];
|
|
36479
36594
|
}
|
|
@@ -36491,7 +36606,7 @@ function requireJszip_min() {
|
|
|
36491
36606
|
this.accumulate = false;
|
|
36492
36607
|
var t2 = this.streamFiles && !e2.file.dir, r22 = n(e2, t2, true, this.currentSourceOffset, this.zipPlatform, this.encodeFileName);
|
|
36493
36608
|
if (this.dirRecords.push(r22.dirRecord), t2) this.push({ data: (function(e3) {
|
|
36494
|
-
return
|
|
36609
|
+
return R.DATA_DESCRIPTOR + A2(e3.crc32, 4) + A2(e3.compressedSize, 4) + A2(e3.uncompressedSize, 4);
|
|
36495
36610
|
})(e2), meta: { percent: 100 } });
|
|
36496
36611
|
else for (this.push({ data: r22.fileRecord, meta: { percent: 0 } }); this.contentBuffer.length; ) this.push(this.contentBuffer.shift());
|
|
36497
36612
|
this.currentFile = null;
|
|
@@ -36499,7 +36614,7 @@ function requireJszip_min() {
|
|
|
36499
36614
|
for (var e2 = this.bytesWritten, t2 = 0; t2 < this.dirRecords.length; t2++) this.push({ data: this.dirRecords[t2], meta: { percent: 100 } });
|
|
36500
36615
|
var r22 = this.bytesWritten - e2, n2 = (function(e3, t3, r3, n3, i2) {
|
|
36501
36616
|
var s22 = I2.transformTo("string", i2(n3));
|
|
36502
|
-
return
|
|
36617
|
+
return R.CENTRAL_DIRECTORY_END + "\0\0\0\0" + A2(e3, 2) + A2(e3, 2) + A2(t3, 4) + A2(r3, 4) + A2(s22.length, 2) + s22;
|
|
36503
36618
|
})(this.dirRecords.length, r22, e2, this.zipComment, this.encodeFileName);
|
|
36504
36619
|
this.push({ data: n2, meta: { percent: 100 } });
|
|
36505
36620
|
}, s2.prototype.prepareNextSource = function() {
|
|
@@ -37699,11 +37814,11 @@ function requireJszip_min() {
|
|
|
37699
37814
|
return -1 ^ e2;
|
|
37700
37815
|
};
|
|
37701
37816
|
}, {}], 46: [function(e, t, r2) {
|
|
37702
|
-
var h2, c2 = e("../utils/common"), u = e("./trees"), d2 = e("./adler32"), p = e("./crc32"), n = e("./messages"), l3 = 0, f2 = 4, m2 = 0, _2 = -2, g = -1, b2 = 4, i = 2, v2 = 8, y2 = 9, s2 = 286, a = 30, o = 19, w2 = 2 * s2 + 1, k2 = 15,
|
|
37703
|
-
function
|
|
37817
|
+
var h2, c2 = e("../utils/common"), u = e("./trees"), d2 = e("./adler32"), p = e("./crc32"), n = e("./messages"), l3 = 0, f2 = 4, m2 = 0, _2 = -2, g = -1, b2 = 4, i = 2, v2 = 8, y2 = 9, s2 = 286, a = 30, o = 19, w2 = 2 * s2 + 1, k2 = 15, x2 = 3, S2 = 258, z2 = S2 + x2 + 1, C2 = 42, E2 = 113, A2 = 1, I2 = 2, O = 3, B2 = 4;
|
|
37818
|
+
function R(e2, t2) {
|
|
37704
37819
|
return e2.msg = n[t2], t2;
|
|
37705
37820
|
}
|
|
37706
|
-
function
|
|
37821
|
+
function T2(e2) {
|
|
37707
37822
|
return (e2 << 1) - (4 < e2 ? 9 : 0);
|
|
37708
37823
|
}
|
|
37709
37824
|
function D2(e2) {
|
|
@@ -37747,7 +37862,7 @@ function requireJszip_min() {
|
|
|
37747
37862
|
i2 += f22;
|
|
37748
37863
|
}
|
|
37749
37864
|
if (0 === e2.strm.avail_in) break;
|
|
37750
|
-
if (a2 = e2.strm, o2 = e2.window, h22 = e2.strstart + e2.lookahead, u2 = i2, l22 = void 0, l22 = a2.avail_in, u2 < l22 && (l22 = u2), r22 = 0 === l22 ? 0 : (a2.avail_in -= l22, c2.arraySet(o2, a2.input, a2.next_in, l22, h22), 1 === a2.state.wrap ? a2.adler = d2(a2.adler, o2, l22, h22) : 2 === a2.state.wrap && (a2.adler = p(a2.adler, o2, l22, h22)), a2.next_in += l22, a2.total_in += l22, l22), e2.lookahead += r22, e2.lookahead + e2.insert >=
|
|
37865
|
+
if (a2 = e2.strm, o2 = e2.window, h22 = e2.strstart + e2.lookahead, u2 = i2, l22 = void 0, l22 = a2.avail_in, u2 < l22 && (l22 = u2), r22 = 0 === l22 ? 0 : (a2.avail_in -= l22, c2.arraySet(o2, a2.input, a2.next_in, l22, h22), 1 === a2.state.wrap ? a2.adler = d2(a2.adler, o2, l22, h22) : 2 === a2.state.wrap && (a2.adler = p(a2.adler, o2, l22, h22)), a2.next_in += l22, a2.total_in += l22, l22), e2.lookahead += r22, e2.lookahead + e2.insert >= x2) for (s22 = e2.strstart - e2.insert, e2.ins_h = e2.window[s22], e2.ins_h = (e2.ins_h << e2.hash_shift ^ e2.window[s22 + 1]) & e2.hash_mask; e2.insert && (e2.ins_h = (e2.ins_h << e2.hash_shift ^ e2.window[s22 + x2 - 1]) & e2.hash_mask, e2.prev[s22 & e2.w_mask] = e2.head[e2.ins_h], e2.head[e2.ins_h] = s22, s22++, e2.insert--, !(e2.lookahead + e2.insert < x2)); ) ;
|
|
37751
37866
|
} while (e2.lookahead < z2 && 0 !== e2.strm.avail_in);
|
|
37752
37867
|
}
|
|
37753
37868
|
function Z(e2, t2) {
|
|
@@ -37756,14 +37871,14 @@ function requireJszip_min() {
|
|
|
37756
37871
|
if (j2(e2), e2.lookahead < z2 && t2 === l3) return A2;
|
|
37757
37872
|
if (0 === e2.lookahead) break;
|
|
37758
37873
|
}
|
|
37759
|
-
if (r22 = 0, e2.lookahead >=
|
|
37760
|
-
for (e2.match_length--; e2.strstart++, e2.ins_h = (e2.ins_h << e2.hash_shift ^ e2.window[e2.strstart +
|
|
37874
|
+
if (r22 = 0, e2.lookahead >= x2 && (e2.ins_h = (e2.ins_h << e2.hash_shift ^ e2.window[e2.strstart + x2 - 1]) & e2.hash_mask, r22 = e2.prev[e2.strstart & e2.w_mask] = e2.head[e2.ins_h], e2.head[e2.ins_h] = e2.strstart), 0 !== r22 && e2.strstart - r22 <= e2.w_size - z2 && (e2.match_length = L2(e2, r22)), e2.match_length >= x2) if (n2 = u._tr_tally(e2, e2.strstart - e2.match_start, e2.match_length - x2), e2.lookahead -= e2.match_length, e2.match_length <= e2.max_lazy_match && e2.lookahead >= x2) {
|
|
37875
|
+
for (e2.match_length--; e2.strstart++, e2.ins_h = (e2.ins_h << e2.hash_shift ^ e2.window[e2.strstart + x2 - 1]) & e2.hash_mask, r22 = e2.prev[e2.strstart & e2.w_mask] = e2.head[e2.ins_h], e2.head[e2.ins_h] = e2.strstart, 0 != --e2.match_length; ) ;
|
|
37761
37876
|
e2.strstart++;
|
|
37762
37877
|
} else e2.strstart += e2.match_length, e2.match_length = 0, e2.ins_h = e2.window[e2.strstart], e2.ins_h = (e2.ins_h << e2.hash_shift ^ e2.window[e2.strstart + 1]) & e2.hash_mask;
|
|
37763
37878
|
else n2 = u._tr_tally(e2, 0, e2.window[e2.strstart]), e2.lookahead--, e2.strstart++;
|
|
37764
37879
|
if (n2 && (N2(e2, false), 0 === e2.strm.avail_out)) return A2;
|
|
37765
37880
|
}
|
|
37766
|
-
return e2.insert = e2.strstart <
|
|
37881
|
+
return e2.insert = e2.strstart < x2 - 1 ? e2.strstart : x2 - 1, t2 === f2 ? (N2(e2, true), 0 === e2.strm.avail_out ? O : B2) : e2.last_lit && (N2(e2, false), 0 === e2.strm.avail_out) ? A2 : I2;
|
|
37767
37882
|
}
|
|
37768
37883
|
function W2(e2, t2) {
|
|
37769
37884
|
for (var r22, n2, i2; ; ) {
|
|
@@ -37771,14 +37886,14 @@ function requireJszip_min() {
|
|
|
37771
37886
|
if (j2(e2), e2.lookahead < z2 && t2 === l3) return A2;
|
|
37772
37887
|
if (0 === e2.lookahead) break;
|
|
37773
37888
|
}
|
|
37774
|
-
if (r22 = 0, e2.lookahead >=
|
|
37775
|
-
for (i2 = e2.strstart + e2.lookahead -
|
|
37776
|
-
if (e2.match_available = 0, e2.match_length =
|
|
37889
|
+
if (r22 = 0, e2.lookahead >= x2 && (e2.ins_h = (e2.ins_h << e2.hash_shift ^ e2.window[e2.strstart + x2 - 1]) & e2.hash_mask, r22 = e2.prev[e2.strstart & e2.w_mask] = e2.head[e2.ins_h], e2.head[e2.ins_h] = e2.strstart), e2.prev_length = e2.match_length, e2.prev_match = e2.match_start, e2.match_length = x2 - 1, 0 !== r22 && e2.prev_length < e2.max_lazy_match && e2.strstart - r22 <= e2.w_size - z2 && (e2.match_length = L2(e2, r22), e2.match_length <= 5 && (1 === e2.strategy || e2.match_length === x2 && 4096 < e2.strstart - e2.match_start) && (e2.match_length = x2 - 1)), e2.prev_length >= x2 && e2.match_length <= e2.prev_length) {
|
|
37890
|
+
for (i2 = e2.strstart + e2.lookahead - x2, n2 = u._tr_tally(e2, e2.strstart - 1 - e2.prev_match, e2.prev_length - x2), e2.lookahead -= e2.prev_length - 1, e2.prev_length -= 2; ++e2.strstart <= i2 && (e2.ins_h = (e2.ins_h << e2.hash_shift ^ e2.window[e2.strstart + x2 - 1]) & e2.hash_mask, r22 = e2.prev[e2.strstart & e2.w_mask] = e2.head[e2.ins_h], e2.head[e2.ins_h] = e2.strstart), 0 != --e2.prev_length; ) ;
|
|
37891
|
+
if (e2.match_available = 0, e2.match_length = x2 - 1, e2.strstart++, n2 && (N2(e2, false), 0 === e2.strm.avail_out)) return A2;
|
|
37777
37892
|
} else if (e2.match_available) {
|
|
37778
37893
|
if ((n2 = u._tr_tally(e2, 0, e2.window[e2.strstart - 1])) && N2(e2, false), e2.strstart++, e2.lookahead--, 0 === e2.strm.avail_out) return A2;
|
|
37779
37894
|
} else e2.match_available = 1, e2.strstart++, e2.lookahead--;
|
|
37780
37895
|
}
|
|
37781
|
-
return e2.match_available && (n2 = u._tr_tally(e2, 0, e2.window[e2.strstart - 1]), e2.match_available = 0), e2.insert = e2.strstart <
|
|
37896
|
+
return e2.match_available && (n2 = u._tr_tally(e2, 0, e2.window[e2.strstart - 1]), e2.match_available = 0), e2.insert = e2.strstart < x2 - 1 ? e2.strstart : x2 - 1, t2 === f2 ? (N2(e2, true), 0 === e2.strm.avail_out ? O : B2) : e2.last_lit && (N2(e2, false), 0 === e2.strm.avail_out) ? A2 : I2;
|
|
37782
37897
|
}
|
|
37783
37898
|
function M2(e2, t2, r22, n2, i2) {
|
|
37784
37899
|
this.good_length = e2, this.max_lazy = t2, this.nice_length = r22, this.max_chain = n2, this.func = i2;
|
|
@@ -37788,21 +37903,21 @@ function requireJszip_min() {
|
|
|
37788
37903
|
}
|
|
37789
37904
|
function G2(e2) {
|
|
37790
37905
|
var t2;
|
|
37791
|
-
return e2 && e2.state ? (e2.total_in = e2.total_out = 0, e2.data_type = i, (t2 = e2.state).pending = 0, t2.pending_out = 0, t2.wrap < 0 && (t2.wrap = -t2.wrap), t2.status = t2.wrap ? C2 : E2, e2.adler = 2 === t2.wrap ? 0 : 1, t2.last_flush = l3, u._tr_init(t2), m2) :
|
|
37906
|
+
return e2 && e2.state ? (e2.total_in = e2.total_out = 0, e2.data_type = i, (t2 = e2.state).pending = 0, t2.pending_out = 0, t2.wrap < 0 && (t2.wrap = -t2.wrap), t2.status = t2.wrap ? C2 : E2, e2.adler = 2 === t2.wrap ? 0 : 1, t2.last_flush = l3, u._tr_init(t2), m2) : R(e2, _2);
|
|
37792
37907
|
}
|
|
37793
37908
|
function K2(e2) {
|
|
37794
37909
|
var t2 = G2(e2);
|
|
37795
37910
|
return t2 === m2 && (function(e3) {
|
|
37796
|
-
e3.window_size = 2 * e3.w_size, D2(e3.head), e3.max_lazy_match = h2[e3.level].max_lazy, e3.good_match = h2[e3.level].good_length, e3.nice_match = h2[e3.level].nice_length, e3.max_chain_length = h2[e3.level].max_chain, e3.strstart = 0, e3.block_start = 0, e3.lookahead = 0, e3.insert = 0, e3.match_length = e3.prev_length =
|
|
37911
|
+
e3.window_size = 2 * e3.w_size, D2(e3.head), e3.max_lazy_match = h2[e3.level].max_lazy, e3.good_match = h2[e3.level].good_length, e3.nice_match = h2[e3.level].nice_length, e3.max_chain_length = h2[e3.level].max_chain, e3.strstart = 0, e3.block_start = 0, e3.lookahead = 0, e3.insert = 0, e3.match_length = e3.prev_length = x2 - 1, e3.match_available = 0, e3.ins_h = 0;
|
|
37797
37912
|
})(e2.state), t2;
|
|
37798
37913
|
}
|
|
37799
37914
|
function Y2(e2, t2, r22, n2, i2, s22) {
|
|
37800
37915
|
if (!e2) return _2;
|
|
37801
37916
|
var a2 = 1;
|
|
37802
|
-
if (t2 === g && (t2 = 6), n2 < 0 ? (a2 = 0, n2 = -n2) : 15 < n2 && (a2 = 2, n2 -= 16), i2 < 1 || y2 < i2 || r22 !== v2 || n2 < 8 || 15 < n2 || t2 < 0 || 9 < t2 || s22 < 0 || b2 < s22) return
|
|
37917
|
+
if (t2 === g && (t2 = 6), n2 < 0 ? (a2 = 0, n2 = -n2) : 15 < n2 && (a2 = 2, n2 -= 16), i2 < 1 || y2 < i2 || r22 !== v2 || n2 < 8 || 15 < n2 || t2 < 0 || 9 < t2 || s22 < 0 || b2 < s22) return R(e2, _2);
|
|
37803
37918
|
8 === n2 && (n2 = 9);
|
|
37804
37919
|
var o2 = new H();
|
|
37805
|
-
return (e2.state = o2).strm = e2, o2.wrap = a2, o2.gzhead = null, o2.w_bits = n2, o2.w_size = 1 << o2.w_bits, o2.w_mask = o2.w_size - 1, o2.hash_bits = i2 + 7, o2.hash_size = 1 << o2.hash_bits, o2.hash_mask = o2.hash_size - 1, o2.hash_shift = ~~((o2.hash_bits +
|
|
37920
|
+
return (e2.state = o2).strm = e2, o2.wrap = a2, o2.gzhead = null, o2.w_bits = n2, o2.w_size = 1 << o2.w_bits, o2.w_mask = o2.w_size - 1, o2.hash_bits = i2 + 7, o2.hash_size = 1 << o2.hash_bits, o2.hash_mask = o2.hash_size - 1, o2.hash_shift = ~~((o2.hash_bits + x2 - 1) / x2), o2.window = new c2.Buf8(2 * o2.w_size), o2.head = new c2.Buf16(o2.hash_size), o2.prev = new c2.Buf16(o2.w_size), o2.lit_bufsize = 1 << i2 + 6, o2.pending_buf_size = 4 * o2.lit_bufsize, o2.pending_buf = new c2.Buf8(o2.pending_buf_size), o2.d_buf = 1 * o2.lit_bufsize, o2.l_buf = 3 * o2.lit_bufsize, o2.level = t2, o2.strategy = s22, o2.method = r22, K2(e2);
|
|
37806
37921
|
}
|
|
37807
37922
|
h2 = [new M2(0, 0, 0, 0, function(e2, t2) {
|
|
37808
37923
|
var r22 = 65535;
|
|
@@ -37816,15 +37931,15 @@ function requireJszip_min() {
|
|
|
37816
37931
|
if ((0 === e2.strstart || e2.strstart >= n2) && (e2.lookahead = e2.strstart - n2, e2.strstart = n2, N2(e2, false), 0 === e2.strm.avail_out)) return A2;
|
|
37817
37932
|
if (e2.strstart - e2.block_start >= e2.w_size - z2 && (N2(e2, false), 0 === e2.strm.avail_out)) return A2;
|
|
37818
37933
|
}
|
|
37819
|
-
return e2.insert = 0, t2 === f2 ? (N2(e2, true), 0 === e2.strm.avail_out ?
|
|
37934
|
+
return e2.insert = 0, t2 === f2 ? (N2(e2, true), 0 === e2.strm.avail_out ? O : B2) : (e2.strstart > e2.block_start && (N2(e2, false), e2.strm.avail_out), A2);
|
|
37820
37935
|
}), new M2(4, 4, 8, 4, Z), new M2(4, 5, 16, 8, Z), new M2(4, 6, 32, 32, Z), new M2(4, 4, 16, 16, W2), new M2(8, 16, 32, 32, W2), new M2(8, 16, 128, 128, W2), new M2(8, 32, 128, 256, W2), new M2(32, 128, 258, 1024, W2), new M2(32, 258, 258, 4096, W2)], r2.deflateInit = function(e2, t2) {
|
|
37821
37936
|
return Y2(e2, t2, v2, 15, 8, 0);
|
|
37822
37937
|
}, r2.deflateInit2 = Y2, r2.deflateReset = K2, r2.deflateResetKeep = G2, r2.deflateSetHeader = function(e2, t2) {
|
|
37823
37938
|
return e2 && e2.state ? 2 !== e2.state.wrap ? _2 : (e2.state.gzhead = t2, m2) : _2;
|
|
37824
37939
|
}, r2.deflate = function(e2, t2) {
|
|
37825
37940
|
var r22, n2, i2, s22;
|
|
37826
|
-
if (!e2 || !e2.state || 5 < t2 || t2 < 0) return e2 ?
|
|
37827
|
-
if (n2 = e2.state, !e2.output || !e2.input && 0 !== e2.avail_in || 666 === n2.status && t2 !== f2) return
|
|
37941
|
+
if (!e2 || !e2.state || 5 < t2 || t2 < 0) return e2 ? R(e2, _2) : _2;
|
|
37942
|
+
if (n2 = e2.state, !e2.output || !e2.input && 0 !== e2.avail_in || 666 === n2.status && t2 !== f2) return R(e2, 0 === e2.avail_out ? -5 : _2);
|
|
37828
37943
|
if (n2.strm = e2, r22 = n2.last_flush, n2.last_flush = t2, n2.status === C2) if (2 === n2.wrap) e2.adler = 0, U2(n2, 31), U2(n2, 139), U2(n2, 8), n2.gzhead ? (U2(n2, (n2.gzhead.text ? 1 : 0) + (n2.gzhead.hcrc ? 2 : 0) + (n2.gzhead.extra ? 4 : 0) + (n2.gzhead.name ? 8 : 0) + (n2.gzhead.comment ? 16 : 0)), U2(n2, 255 & n2.gzhead.time), U2(n2, n2.gzhead.time >> 8 & 255), U2(n2, n2.gzhead.time >> 16 & 255), U2(n2, n2.gzhead.time >> 24 & 255), U2(n2, 9 === n2.level ? 2 : 2 <= n2.strategy || n2.level < 2 ? 4 : 0), U2(n2, 255 & n2.gzhead.os), n2.gzhead.extra && n2.gzhead.extra.length && (U2(n2, 255 & n2.gzhead.extra.length), U2(n2, n2.gzhead.extra.length >> 8 & 255)), n2.gzhead.hcrc && (e2.adler = p(e2.adler, n2.pending_buf, n2.pending, 0)), n2.gzindex = 0, n2.status = 69) : (U2(n2, 0), U2(n2, 0), U2(n2, 0), U2(n2, 0), U2(n2, 0), U2(n2, 9 === n2.level ? 2 : 2 <= n2.strategy || n2.level < 2 ? 4 : 0), U2(n2, 3), n2.status = E2);
|
|
37829
37944
|
else {
|
|
37830
37945
|
var a2 = v2 + (n2.w_bits - 8 << 4) << 8;
|
|
@@ -37858,8 +37973,8 @@ function requireJszip_min() {
|
|
|
37858
37973
|
} else n2.status = 103;
|
|
37859
37974
|
if (103 === n2.status && (n2.gzhead.hcrc ? (n2.pending + 2 > n2.pending_buf_size && F2(e2), n2.pending + 2 <= n2.pending_buf_size && (U2(n2, 255 & e2.adler), U2(n2, e2.adler >> 8 & 255), e2.adler = 0, n2.status = E2)) : n2.status = E2), 0 !== n2.pending) {
|
|
37860
37975
|
if (F2(e2), 0 === e2.avail_out) return n2.last_flush = -1, m2;
|
|
37861
|
-
} else if (0 === e2.avail_in &&
|
|
37862
|
-
if (666 === n2.status && 0 !== e2.avail_in) return
|
|
37976
|
+
} else if (0 === e2.avail_in && T2(t2) <= T2(r22) && t2 !== f2) return R(e2, -5);
|
|
37977
|
+
if (666 === n2.status && 0 !== e2.avail_in) return R(e2, -5);
|
|
37863
37978
|
if (0 !== e2.avail_in || 0 !== n2.lookahead || t2 !== l3 && 666 !== n2.status) {
|
|
37864
37979
|
var o2 = 2 === n2.strategy ? (function(e3, t3) {
|
|
37865
37980
|
for (var r3; ; ) {
|
|
@@ -37869,39 +37984,39 @@ function requireJszip_min() {
|
|
|
37869
37984
|
}
|
|
37870
37985
|
if (e3.match_length = 0, r3 = u._tr_tally(e3, 0, e3.window[e3.strstart]), e3.lookahead--, e3.strstart++, r3 && (N2(e3, false), 0 === e3.strm.avail_out)) return A2;
|
|
37871
37986
|
}
|
|
37872
|
-
return e3.insert = 0, t3 === f2 ? (N2(e3, true), 0 === e3.strm.avail_out ?
|
|
37987
|
+
return e3.insert = 0, t3 === f2 ? (N2(e3, true), 0 === e3.strm.avail_out ? O : B2) : e3.last_lit && (N2(e3, false), 0 === e3.strm.avail_out) ? A2 : I2;
|
|
37873
37988
|
})(n2, t2) : 3 === n2.strategy ? (function(e3, t3) {
|
|
37874
37989
|
for (var r3, n3, i3, s3, a3 = e3.window; ; ) {
|
|
37875
37990
|
if (e3.lookahead <= S2) {
|
|
37876
37991
|
if (j2(e3), e3.lookahead <= S2 && t3 === l3) return A2;
|
|
37877
37992
|
if (0 === e3.lookahead) break;
|
|
37878
37993
|
}
|
|
37879
|
-
if (e3.match_length = 0, e3.lookahead >=
|
|
37994
|
+
if (e3.match_length = 0, e3.lookahead >= x2 && 0 < e3.strstart && (n3 = a3[i3 = e3.strstart - 1]) === a3[++i3] && n3 === a3[++i3] && n3 === a3[++i3]) {
|
|
37880
37995
|
s3 = e3.strstart + S2;
|
|
37881
37996
|
do {
|
|
37882
37997
|
} while (n3 === a3[++i3] && n3 === a3[++i3] && n3 === a3[++i3] && n3 === a3[++i3] && n3 === a3[++i3] && n3 === a3[++i3] && n3 === a3[++i3] && n3 === a3[++i3] && i3 < s3);
|
|
37883
37998
|
e3.match_length = S2 - (s3 - i3), e3.match_length > e3.lookahead && (e3.match_length = e3.lookahead);
|
|
37884
37999
|
}
|
|
37885
|
-
if (e3.match_length >=
|
|
38000
|
+
if (e3.match_length >= x2 ? (r3 = u._tr_tally(e3, 1, e3.match_length - x2), e3.lookahead -= e3.match_length, e3.strstart += e3.match_length, e3.match_length = 0) : (r3 = u._tr_tally(e3, 0, e3.window[e3.strstart]), e3.lookahead--, e3.strstart++), r3 && (N2(e3, false), 0 === e3.strm.avail_out)) return A2;
|
|
37886
38001
|
}
|
|
37887
|
-
return e3.insert = 0, t3 === f2 ? (N2(e3, true), 0 === e3.strm.avail_out ?
|
|
38002
|
+
return e3.insert = 0, t3 === f2 ? (N2(e3, true), 0 === e3.strm.avail_out ? O : B2) : e3.last_lit && (N2(e3, false), 0 === e3.strm.avail_out) ? A2 : I2;
|
|
37888
38003
|
})(n2, t2) : h2[n2.level].func(n2, t2);
|
|
37889
|
-
if (o2 !==
|
|
38004
|
+
if (o2 !== O && o2 !== B2 || (n2.status = 666), o2 === A2 || o2 === O) return 0 === e2.avail_out && (n2.last_flush = -1), m2;
|
|
37890
38005
|
if (o2 === I2 && (1 === t2 ? u._tr_align(n2) : 5 !== t2 && (u._tr_stored_block(n2, 0, 0, false), 3 === t2 && (D2(n2.head), 0 === n2.lookahead && (n2.strstart = 0, n2.block_start = 0, n2.insert = 0))), F2(e2), 0 === e2.avail_out)) return n2.last_flush = -1, m2;
|
|
37891
38006
|
}
|
|
37892
38007
|
return t2 !== f2 ? m2 : n2.wrap <= 0 ? 1 : (2 === n2.wrap ? (U2(n2, 255 & e2.adler), U2(n2, e2.adler >> 8 & 255), U2(n2, e2.adler >> 16 & 255), U2(n2, e2.adler >> 24 & 255), U2(n2, 255 & e2.total_in), U2(n2, e2.total_in >> 8 & 255), U2(n2, e2.total_in >> 16 & 255), U2(n2, e2.total_in >> 24 & 255)) : (P2(n2, e2.adler >>> 16), P2(n2, 65535 & e2.adler)), F2(e2), 0 < n2.wrap && (n2.wrap = -n2.wrap), 0 !== n2.pending ? m2 : 1);
|
|
37893
38008
|
}, r2.deflateEnd = function(e2) {
|
|
37894
38009
|
var t2;
|
|
37895
|
-
return e2 && e2.state ? (t2 = e2.state.status) !== C2 && 69 !== t2 && 73 !== t2 && 91 !== t2 && 103 !== t2 && t2 !== E2 && 666 !== t2 ?
|
|
38010
|
+
return e2 && e2.state ? (t2 = e2.state.status) !== C2 && 69 !== t2 && 73 !== t2 && 91 !== t2 && 103 !== t2 && t2 !== E2 && 666 !== t2 ? R(e2, _2) : (e2.state = null, t2 === E2 ? R(e2, -3) : m2) : _2;
|
|
37896
38011
|
}, r2.deflateSetDictionary = function(e2, t2) {
|
|
37897
38012
|
var r22, n2, i2, s22, a2, o2, h22, u2, l22 = t2.length;
|
|
37898
38013
|
if (!e2 || !e2.state) return _2;
|
|
37899
38014
|
if (2 === (s22 = (r22 = e2.state).wrap) || 1 === s22 && r22.status !== C2 || r22.lookahead) return _2;
|
|
37900
|
-
for (1 === s22 && (e2.adler = d2(e2.adler, t2, l22, 0)), r22.wrap = 0, l22 >= r22.w_size && (0 === s22 && (D2(r22.head), r22.strstart = 0, r22.block_start = 0, r22.insert = 0), u2 = new c2.Buf8(r22.w_size), c2.arraySet(u2, t2, l22 - r22.w_size, r22.w_size, 0), t2 = u2, l22 = r22.w_size), a2 = e2.avail_in, o2 = e2.next_in, h22 = e2.input, e2.avail_in = l22, e2.next_in = 0, e2.input = t2, j2(r22); r22.lookahead >=
|
|
37901
|
-
for (n2 = r22.strstart, i2 = r22.lookahead - (
|
|
37902
|
-
r22.strstart = n2, r22.lookahead =
|
|
38015
|
+
for (1 === s22 && (e2.adler = d2(e2.adler, t2, l22, 0)), r22.wrap = 0, l22 >= r22.w_size && (0 === s22 && (D2(r22.head), r22.strstart = 0, r22.block_start = 0, r22.insert = 0), u2 = new c2.Buf8(r22.w_size), c2.arraySet(u2, t2, l22 - r22.w_size, r22.w_size, 0), t2 = u2, l22 = r22.w_size), a2 = e2.avail_in, o2 = e2.next_in, h22 = e2.input, e2.avail_in = l22, e2.next_in = 0, e2.input = t2, j2(r22); r22.lookahead >= x2; ) {
|
|
38016
|
+
for (n2 = r22.strstart, i2 = r22.lookahead - (x2 - 1); r22.ins_h = (r22.ins_h << r22.hash_shift ^ r22.window[n2 + x2 - 1]) & r22.hash_mask, r22.prev[n2 & r22.w_mask] = r22.head[r22.ins_h], r22.head[r22.ins_h] = n2, n2++, --i2; ) ;
|
|
38017
|
+
r22.strstart = n2, r22.lookahead = x2 - 1, j2(r22);
|
|
37903
38018
|
}
|
|
37904
|
-
return r22.strstart += r22.lookahead, r22.block_start = r22.strstart, r22.insert = r22.lookahead, r22.lookahead = 0, r22.match_length = r22.prev_length =
|
|
38019
|
+
return r22.strstart += r22.lookahead, r22.block_start = r22.strstart, r22.insert = r22.lookahead, r22.lookahead = 0, r22.match_length = r22.prev_length = x2 - 1, r22.match_available = 0, e2.next_in = o2, e2.input = h22, e2.avail_in = a2, r22.wrap = s22, m2;
|
|
37905
38020
|
}, r2.deflateInfo = "pako deflate (from Nodeca project)";
|
|
37906
38021
|
}, { "../utils/common": 41, "./adler32": 43, "./crc32": 45, "./messages": 51, "./trees": 52 }], 47: [function(e, t, r2) {
|
|
37907
38022
|
t.exports = function() {
|
|
@@ -37909,7 +38024,7 @@ function requireJszip_min() {
|
|
|
37909
38024
|
};
|
|
37910
38025
|
}, {}], 48: [function(e, t, r2) {
|
|
37911
38026
|
t.exports = function(e2, t2) {
|
|
37912
|
-
var r22, n, i, s2, a, o, h2, u, l3, f2, c2, d2, p, m2, _2, g, b2, v2, y2, w2, k2,
|
|
38027
|
+
var r22, n, i, s2, a, o, h2, u, l3, f2, c2, d2, p, m2, _2, g, b2, v2, y2, w2, k2, x2, S2, z2, C2;
|
|
37913
38028
|
r22 = e2.state, n = e2.next_in, z2 = e2.input, i = n + (e2.avail_in - 5), s2 = e2.next_out, C2 = e2.output, a = s2 - (t2 - e2.avail_out), o = s2 + (e2.avail_out - 257), h2 = r22.dmax, u = r22.wsize, l3 = r22.whave, f2 = r22.wnext, c2 = r22.window, d2 = r22.hold, p = r22.bits, m2 = r22.lencode, _2 = r22.distcode, g = (1 << r22.lenbits) - 1, b2 = (1 << r22.distbits) - 1;
|
|
37914
38029
|
e: do {
|
|
37915
38030
|
p < 15 && (d2 += z2[n++] << p, p += 8, d2 += z2[n++] << p, p += 8), v2 = m2[d2 & g];
|
|
@@ -37947,28 +38062,28 @@ function requireJszip_min() {
|
|
|
37947
38062
|
e2.msg = "invalid distance too far back", r22.mode = 30;
|
|
37948
38063
|
break e;
|
|
37949
38064
|
}
|
|
37950
|
-
if (S2 = c2, (
|
|
37951
|
-
if (
|
|
37952
|
-
for (w2 -= y2; C2[s2++] = c2[
|
|
37953
|
-
|
|
38065
|
+
if (S2 = c2, (x2 = 0) === f2) {
|
|
38066
|
+
if (x2 += u - y2, y2 < w2) {
|
|
38067
|
+
for (w2 -= y2; C2[s2++] = c2[x2++], --y2; ) ;
|
|
38068
|
+
x2 = s2 - k2, S2 = C2;
|
|
37954
38069
|
}
|
|
37955
38070
|
} else if (f2 < y2) {
|
|
37956
|
-
if (
|
|
37957
|
-
for (w2 -= y2; C2[s2++] = c2[
|
|
37958
|
-
if (
|
|
37959
|
-
for (w2 -= y2 = f2; C2[s2++] = c2[
|
|
37960
|
-
|
|
38071
|
+
if (x2 += u + f2 - y2, (y2 -= f2) < w2) {
|
|
38072
|
+
for (w2 -= y2; C2[s2++] = c2[x2++], --y2; ) ;
|
|
38073
|
+
if (x2 = 0, f2 < w2) {
|
|
38074
|
+
for (w2 -= y2 = f2; C2[s2++] = c2[x2++], --y2; ) ;
|
|
38075
|
+
x2 = s2 - k2, S2 = C2;
|
|
37961
38076
|
}
|
|
37962
38077
|
}
|
|
37963
|
-
} else if (
|
|
37964
|
-
for (w2 -= y2; C2[s2++] = c2[
|
|
37965
|
-
|
|
38078
|
+
} else if (x2 += f2 - y2, y2 < w2) {
|
|
38079
|
+
for (w2 -= y2; C2[s2++] = c2[x2++], --y2; ) ;
|
|
38080
|
+
x2 = s2 - k2, S2 = C2;
|
|
37966
38081
|
}
|
|
37967
|
-
for (; 2 < w2; ) C2[s2++] = S2[
|
|
37968
|
-
w2 && (C2[s2++] = S2[
|
|
38082
|
+
for (; 2 < w2; ) C2[s2++] = S2[x2++], C2[s2++] = S2[x2++], C2[s2++] = S2[x2++], w2 -= 3;
|
|
38083
|
+
w2 && (C2[s2++] = S2[x2++], 1 < w2 && (C2[s2++] = S2[x2++]));
|
|
37969
38084
|
} else {
|
|
37970
|
-
for (
|
|
37971
|
-
w2 && (C2[s2++] = C2[
|
|
38085
|
+
for (x2 = s2 - k2; C2[s2++] = C2[x2++], C2[s2++] = C2[x2++], C2[s2++] = C2[x2++], 2 < (w2 -= 3); ) ;
|
|
38086
|
+
w2 && (C2[s2++] = C2[x2++], 1 < w2 && (C2[s2++] = C2[x2++]));
|
|
37972
38087
|
}
|
|
37973
38088
|
break;
|
|
37974
38089
|
}
|
|
@@ -37979,7 +38094,7 @@ function requireJszip_min() {
|
|
|
37979
38094
|
n -= w2 = p >> 3, d2 &= (1 << (p -= w2 << 3)) - 1, e2.next_in = n, e2.next_out = s2, e2.avail_in = n < i ? i - n + 5 : 5 - (n - i), e2.avail_out = s2 < o ? o - s2 + 257 : 257 - (s2 - o), r22.hold = d2, r22.bits = p;
|
|
37980
38095
|
};
|
|
37981
38096
|
}, {}], 49: [function(e, t, r2) {
|
|
37982
|
-
var I2 = e("../utils/common"),
|
|
38097
|
+
var I2 = e("../utils/common"), O = e("./adler32"), B2 = e("./crc32"), R = e("./inffast"), T2 = e("./inftrees"), D2 = 1, F2 = 2, N2 = 0, U2 = -2, P2 = 1, n = 852, i = 592;
|
|
37983
38098
|
function L2(e2) {
|
|
37984
38099
|
return (e2 >>> 24 & 255) + (e2 >>> 8 & 65280) + ((65280 & e2) << 8) + ((255 & e2) << 24);
|
|
37985
38100
|
}
|
|
@@ -38010,8 +38125,8 @@ function requireJszip_min() {
|
|
|
38010
38125
|
for (; t2 < 256; ) e2.lens[t2++] = 9;
|
|
38011
38126
|
for (; t2 < 280; ) e2.lens[t2++] = 7;
|
|
38012
38127
|
for (; t2 < 288; ) e2.lens[t2++] = 8;
|
|
38013
|
-
for (
|
|
38014
|
-
|
|
38128
|
+
for (T2(D2, e2.lens, 0, 288, l3, 0, e2.work, { bits: 9 }), t2 = 0; t2 < 32; ) e2.lens[t2++] = 5;
|
|
38129
|
+
T2(F2, e2.lens, 0, 32, f2, 0, e2.work, { bits: 5 }), c2 = false;
|
|
38015
38130
|
}
|
|
38016
38131
|
e2.lencode = l3, e2.lenbits = 9, e2.distcode = f2, e2.distbits = 5;
|
|
38017
38132
|
}
|
|
@@ -38022,9 +38137,9 @@ function requireJszip_min() {
|
|
|
38022
38137
|
r2.inflateReset = o, r2.inflateReset2 = h2, r2.inflateResetKeep = a, r2.inflateInit = function(e2) {
|
|
38023
38138
|
return u(e2, 15);
|
|
38024
38139
|
}, r2.inflateInit2 = u, r2.inflate = function(e2, t2) {
|
|
38025
|
-
var r22, n2, i2, s22, a2, o2, h22, u2, l22, f22, c22, d2, p, m2, _2, g, b2, v2, y2, w2, k2,
|
|
38140
|
+
var r22, n2, i2, s22, a2, o2, h22, u2, l22, f22, c22, d2, p, m2, _2, g, b2, v2, y2, w2, k2, x2, S2, z2, C2 = 0, E2 = new I2.Buf8(4), A2 = [16, 17, 18, 0, 8, 7, 9, 6, 10, 5, 11, 4, 12, 3, 13, 2, 14, 1, 15];
|
|
38026
38141
|
if (!e2 || !e2.state || !e2.output || !e2.input && 0 !== e2.avail_in) return U2;
|
|
38027
|
-
12 === (r22 = e2.state).mode && (r22.mode = 13), a2 = e2.next_out, i2 = e2.output, h22 = e2.avail_out, s22 = e2.next_in, n2 = e2.input, o2 = e2.avail_in, u2 = r22.hold, l22 = r22.bits, f22 = o2, c22 = h22,
|
|
38142
|
+
12 === (r22 = e2.state).mode && (r22.mode = 13), a2 = e2.next_out, i2 = e2.output, h22 = e2.avail_out, s22 = e2.next_in, n2 = e2.input, o2 = e2.avail_in, u2 = r22.hold, l22 = r22.bits, f22 = o2, c22 = h22, x2 = N2;
|
|
38028
38143
|
e: for (; ; ) switch (r22.mode) {
|
|
38029
38144
|
case P2:
|
|
38030
38145
|
if (0 === r22.wrap) {
|
|
@@ -38195,7 +38310,7 @@ function requireJszip_min() {
|
|
|
38195
38310
|
r22.lens[A2[r22.have++]] = 7 & u2, u2 >>>= 3, l22 -= 3;
|
|
38196
38311
|
}
|
|
38197
38312
|
for (; r22.have < 19; ) r22.lens[A2[r22.have++]] = 0;
|
|
38198
|
-
if (r22.lencode = r22.lendyn, r22.lenbits = 7, S2 = { bits: r22.lenbits },
|
|
38313
|
+
if (r22.lencode = r22.lendyn, r22.lenbits = 7, S2 = { bits: r22.lenbits }, x2 = T2(0, r22.lens, 0, 19, r22.lencode, 0, r22.work, S2), r22.lenbits = S2.bits, x2) {
|
|
38199
38314
|
e2.msg = "invalid code lengths set", r22.mode = 30;
|
|
38200
38315
|
break;
|
|
38201
38316
|
}
|
|
@@ -38243,11 +38358,11 @@ function requireJszip_min() {
|
|
|
38243
38358
|
e2.msg = "invalid code -- missing end-of-block", r22.mode = 30;
|
|
38244
38359
|
break;
|
|
38245
38360
|
}
|
|
38246
|
-
if (r22.lenbits = 9, S2 = { bits: r22.lenbits },
|
|
38361
|
+
if (r22.lenbits = 9, S2 = { bits: r22.lenbits }, x2 = T2(D2, r22.lens, 0, r22.nlen, r22.lencode, 0, r22.work, S2), r22.lenbits = S2.bits, x2) {
|
|
38247
38362
|
e2.msg = "invalid literal/lengths set", r22.mode = 30;
|
|
38248
38363
|
break;
|
|
38249
38364
|
}
|
|
38250
|
-
if (r22.distbits = 6, r22.distcode = r22.distdyn, S2 = { bits: r22.distbits },
|
|
38365
|
+
if (r22.distbits = 6, r22.distcode = r22.distdyn, S2 = { bits: r22.distbits }, x2 = T2(F2, r22.lens, r22.nlen, r22.ndist, r22.distcode, 0, r22.work, S2), r22.distbits = S2.bits, x2) {
|
|
38251
38366
|
e2.msg = "invalid distances set", r22.mode = 30;
|
|
38252
38367
|
break;
|
|
38253
38368
|
}
|
|
@@ -38256,7 +38371,7 @@ function requireJszip_min() {
|
|
|
38256
38371
|
r22.mode = 21;
|
|
38257
38372
|
case 21:
|
|
38258
38373
|
if (6 <= o2 && 258 <= h22) {
|
|
38259
|
-
e2.next_out = a2, e2.avail_out = h22, e2.next_in = s22, e2.avail_in = o2, r22.hold = u2, r22.bits = l22,
|
|
38374
|
+
e2.next_out = a2, e2.avail_out = h22, e2.next_in = s22, e2.avail_in = o2, r22.hold = u2, r22.bits = l22, R(e2, c22), a2 = e2.next_out, i2 = e2.output, h22 = e2.avail_out, s22 = e2.next_in, n2 = e2.input, o2 = e2.avail_in, u2 = r22.hold, l22 = r22.bits, 12 === r22.mode && (r22.back = -1);
|
|
38260
38375
|
break;
|
|
38261
38376
|
}
|
|
38262
38377
|
for (r22.back = 0; g = (C2 = r22.lencode[u2 & (1 << r22.lenbits) - 1]) >>> 16 & 255, b2 = 65535 & C2, !((_2 = C2 >>> 24) <= l22); ) {
|
|
@@ -38344,7 +38459,7 @@ function requireJszip_min() {
|
|
|
38344
38459
|
if (0 === o2) break e;
|
|
38345
38460
|
o2--, u2 |= n2[s22++] << l22, l22 += 8;
|
|
38346
38461
|
}
|
|
38347
|
-
if (c22 -= h22, e2.total_out += c22, r22.total += c22, c22 && (e2.adler = r22.check = r22.flags ? B2(r22.check, i2, c22, a2 - c22) :
|
|
38462
|
+
if (c22 -= h22, e2.total_out += c22, r22.total += c22, c22 && (e2.adler = r22.check = r22.flags ? B2(r22.check, i2, c22, a2 - c22) : O(r22.check, i2, c22, a2 - c22)), c22 = h22, (r22.flags ? u2 : L2(u2)) !== r22.check) {
|
|
38348
38463
|
e2.msg = "incorrect data check", r22.mode = 30;
|
|
38349
38464
|
break;
|
|
38350
38465
|
}
|
|
@@ -38365,10 +38480,10 @@ function requireJszip_min() {
|
|
|
38365
38480
|
}
|
|
38366
38481
|
r22.mode = 29;
|
|
38367
38482
|
case 29:
|
|
38368
|
-
|
|
38483
|
+
x2 = 1;
|
|
38369
38484
|
break e;
|
|
38370
38485
|
case 30:
|
|
38371
|
-
|
|
38486
|
+
x2 = -3;
|
|
38372
38487
|
break e;
|
|
38373
38488
|
case 31:
|
|
38374
38489
|
return -4;
|
|
@@ -38376,7 +38491,7 @@ function requireJszip_min() {
|
|
|
38376
38491
|
default:
|
|
38377
38492
|
return U2;
|
|
38378
38493
|
}
|
|
38379
|
-
return e2.next_out = a2, e2.avail_out = h22, e2.next_in = s22, e2.avail_in = o2, r22.hold = u2, r22.bits = l22, (r22.wsize || c22 !== e2.avail_out && r22.mode < 30 && (r22.mode < 27 || 4 !== t2)) && Z(e2, e2.output, e2.next_out, c22 - e2.avail_out) ? (r22.mode = 31, -4) : (f22 -= e2.avail_in, c22 -= e2.avail_out, e2.total_in += f22, e2.total_out += c22, r22.total += c22, r22.wrap && c22 && (e2.adler = r22.check = r22.flags ? B2(r22.check, i2, c22, e2.next_out - c22) :
|
|
38494
|
+
return e2.next_out = a2, e2.avail_out = h22, e2.next_in = s22, e2.avail_in = o2, r22.hold = u2, r22.bits = l22, (r22.wsize || c22 !== e2.avail_out && r22.mode < 30 && (r22.mode < 27 || 4 !== t2)) && Z(e2, e2.output, e2.next_out, c22 - e2.avail_out) ? (r22.mode = 31, -4) : (f22 -= e2.avail_in, c22 -= e2.avail_out, e2.total_in += f22, e2.total_out += c22, r22.total += c22, r22.wrap && c22 && (e2.adler = r22.check = r22.flags ? B2(r22.check, i2, c22, e2.next_out - c22) : O(r22.check, i2, c22, e2.next_out - c22)), e2.data_type = r22.bits + (r22.last ? 64 : 0) + (12 === r22.mode ? 128 : 0) + (20 === r22.mode || 15 === r22.mode ? 256 : 0), (0 == f22 && 0 === c22 || 4 === t2) && x2 === N2 && (x2 = -5), x2);
|
|
38380
38495
|
}, r2.inflateEnd = function(e2) {
|
|
38381
38496
|
if (!e2 || !e2.state) return U2;
|
|
38382
38497
|
var t2 = e2.state;
|
|
@@ -38386,33 +38501,33 @@ function requireJszip_min() {
|
|
|
38386
38501
|
return e2 && e2.state ? 0 == (2 & (r22 = e2.state).wrap) ? U2 : ((r22.head = t2).done = false, N2) : U2;
|
|
38387
38502
|
}, r2.inflateSetDictionary = function(e2, t2) {
|
|
38388
38503
|
var r22, n2 = t2.length;
|
|
38389
|
-
return e2 && e2.state ? 0 !== (r22 = e2.state).wrap && 11 !== r22.mode ? U2 : 11 === r22.mode &&
|
|
38504
|
+
return e2 && e2.state ? 0 !== (r22 = e2.state).wrap && 11 !== r22.mode ? U2 : 11 === r22.mode && O(1, t2, n2, 0) !== r22.check ? -3 : Z(e2, t2, n2, n2) ? (r22.mode = 31, -4) : (r22.havedict = 1, N2) : U2;
|
|
38390
38505
|
}, r2.inflateInfo = "pako inflate (from Nodeca project)";
|
|
38391
38506
|
}, { "../utils/common": 41, "./adler32": 43, "./crc32": 45, "./inffast": 48, "./inftrees": 50 }], 50: [function(e, t, r2) {
|
|
38392
38507
|
var D2 = e("../utils/common"), F2 = [3, 4, 5, 6, 7, 8, 9, 10, 11, 13, 15, 17, 19, 23, 27, 31, 35, 43, 51, 59, 67, 83, 99, 115, 131, 163, 195, 227, 258, 0, 0], N2 = [16, 16, 16, 16, 16, 16, 16, 16, 17, 17, 17, 17, 18, 18, 18, 18, 19, 19, 19, 19, 20, 20, 20, 20, 21, 21, 21, 21, 16, 72, 78], U2 = [1, 2, 3, 4, 5, 7, 9, 13, 17, 25, 33, 49, 65, 97, 129, 193, 257, 385, 513, 769, 1025, 1537, 2049, 3073, 4097, 6145, 8193, 12289, 16385, 24577, 0, 0], P2 = [16, 16, 16, 16, 17, 17, 18, 18, 19, 19, 20, 20, 21, 21, 22, 22, 23, 23, 24, 24, 25, 25, 26, 26, 27, 27, 28, 28, 29, 29, 64, 64];
|
|
38393
38508
|
t.exports = function(e2, t2, r22, n, i, s2, a, o) {
|
|
38394
|
-
var h2, u, l3, f2, c2, d2, p, m2, _2, g = o.bits, b2 = 0, v2 = 0, y2 = 0, w2 = 0, k2 = 0,
|
|
38395
|
-
for (b2 = 0; b2 <= 15; b2++)
|
|
38396
|
-
for (v2 = 0; v2 < n; v2++)
|
|
38397
|
-
for (k2 = g, w2 = 15; 1 <= w2 && 0 ===
|
|
38509
|
+
var h2, u, l3, f2, c2, d2, p, m2, _2, g = o.bits, b2 = 0, v2 = 0, y2 = 0, w2 = 0, k2 = 0, x2 = 0, S2 = 0, z2 = 0, C2 = 0, E2 = 0, A2 = null, I2 = 0, O = new D2.Buf16(16), B2 = new D2.Buf16(16), R = null, T2 = 0;
|
|
38510
|
+
for (b2 = 0; b2 <= 15; b2++) O[b2] = 0;
|
|
38511
|
+
for (v2 = 0; v2 < n; v2++) O[t2[r22 + v2]]++;
|
|
38512
|
+
for (k2 = g, w2 = 15; 1 <= w2 && 0 === O[w2]; w2--) ;
|
|
38398
38513
|
if (w2 < k2 && (k2 = w2), 0 === w2) return i[s2++] = 20971520, i[s2++] = 20971520, o.bits = 1, 0;
|
|
38399
|
-
for (y2 = 1; y2 < w2 && 0 ===
|
|
38400
|
-
for (k2 < y2 && (k2 = y2), b2 = z2 = 1; b2 <= 15; b2++) if (z2 <<= 1, (z2 -=
|
|
38514
|
+
for (y2 = 1; y2 < w2 && 0 === O[y2]; y2++) ;
|
|
38515
|
+
for (k2 < y2 && (k2 = y2), b2 = z2 = 1; b2 <= 15; b2++) if (z2 <<= 1, (z2 -= O[b2]) < 0) return -1;
|
|
38401
38516
|
if (0 < z2 && (0 === e2 || 1 !== w2)) return -1;
|
|
38402
|
-
for (B2[1] = 0, b2 = 1; b2 < 15; b2++) B2[b2 + 1] = B2[b2] +
|
|
38517
|
+
for (B2[1] = 0, b2 = 1; b2 < 15; b2++) B2[b2 + 1] = B2[b2] + O[b2];
|
|
38403
38518
|
for (v2 = 0; v2 < n; v2++) 0 !== t2[r22 + v2] && (a[B2[t2[r22 + v2]]++] = v2);
|
|
38404
|
-
if (d2 = 0 === e2 ? (A2 =
|
|
38519
|
+
if (d2 = 0 === e2 ? (A2 = R = a, 19) : 1 === e2 ? (A2 = F2, I2 -= 257, R = N2, T2 -= 257, 256) : (A2 = U2, R = P2, -1), b2 = y2, c2 = s2, S2 = v2 = E2 = 0, l3 = -1, f2 = (C2 = 1 << (x2 = k2)) - 1, 1 === e2 && 852 < C2 || 2 === e2 && 592 < C2) return 1;
|
|
38405
38520
|
for (; ; ) {
|
|
38406
|
-
for (p = b2 - S2, _2 = a[v2] < d2 ? (m2 = 0, a[v2]) : a[v2] > d2 ? (m2 =
|
|
38521
|
+
for (p = b2 - S2, _2 = a[v2] < d2 ? (m2 = 0, a[v2]) : a[v2] > d2 ? (m2 = R[T2 + a[v2]], A2[I2 + a[v2]]) : (m2 = 96, 0), h2 = 1 << b2 - S2, y2 = u = 1 << x2; i[c2 + (E2 >> S2) + (u -= h2)] = p << 24 | m2 << 16 | _2 | 0, 0 !== u; ) ;
|
|
38407
38522
|
for (h2 = 1 << b2 - 1; E2 & h2; ) h2 >>= 1;
|
|
38408
|
-
if (0 !== h2 ? (E2 &= h2 - 1, E2 += h2) : E2 = 0, v2++, 0 == --
|
|
38523
|
+
if (0 !== h2 ? (E2 &= h2 - 1, E2 += h2) : E2 = 0, v2++, 0 == --O[b2]) {
|
|
38409
38524
|
if (b2 === w2) break;
|
|
38410
38525
|
b2 = t2[r22 + a[v2]];
|
|
38411
38526
|
}
|
|
38412
38527
|
if (k2 < b2 && (E2 & f2) !== l3) {
|
|
38413
|
-
for (0 === S2 && (S2 = k2), c2 += y2, z2 = 1 << (
|
|
38414
|
-
if (C2 += 1 <<
|
|
38415
|
-
i[l3 = E2 & f2] = k2 << 24 |
|
|
38528
|
+
for (0 === S2 && (S2 = k2), c2 += y2, z2 = 1 << (x2 = b2 - S2); x2 + S2 < w2 && !((z2 -= O[x2 + S2]) <= 0); ) x2++, z2 <<= 1;
|
|
38529
|
+
if (C2 += 1 << x2, 1 === e2 && 852 < C2 || 2 === e2 && 592 < C2) return 1;
|
|
38530
|
+
i[l3 = E2 & f2] = k2 << 24 | x2 << 16 | c2 - s2 | 0;
|
|
38416
38531
|
}
|
|
38417
38532
|
}
|
|
38418
38533
|
return 0 !== E2 && (i[c2 + E2] = b2 - S2 << 24 | 64 << 16 | 0), o.bits = k2, 0;
|
|
@@ -38424,7 +38539,7 @@ function requireJszip_min() {
|
|
|
38424
38539
|
function n(e2) {
|
|
38425
38540
|
for (var t2 = e2.length; 0 <= --t2; ) e2[t2] = 0;
|
|
38426
38541
|
}
|
|
38427
|
-
var s2 = 0, a = 29, u = 256, l3 = u + 1 + a, f2 = 30, c2 = 19, _2 = 2 * l3 + 1, g = 15, d2 = 16, p = 7, m2 = 256, b2 = 16, v2 = 17, y2 = 18, w2 = [0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 2, 2, 2, 2, 3, 3, 3, 3, 4, 4, 4, 4, 5, 5, 5, 5, 0], k2 = [0, 0, 0, 0, 1, 1, 2, 2, 3, 3, 4, 4, 5, 5, 6, 6, 7, 7, 8, 8, 9, 9, 10, 10, 11, 11, 12, 12, 13, 13],
|
|
38542
|
+
var s2 = 0, a = 29, u = 256, l3 = u + 1 + a, f2 = 30, c2 = 19, _2 = 2 * l3 + 1, g = 15, d2 = 16, p = 7, m2 = 256, b2 = 16, v2 = 17, y2 = 18, w2 = [0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 2, 2, 2, 2, 3, 3, 3, 3, 4, 4, 4, 4, 5, 5, 5, 5, 0], k2 = [0, 0, 0, 0, 1, 1, 2, 2, 3, 3, 4, 4, 5, 5, 6, 6, 7, 7, 8, 8, 9, 9, 10, 10, 11, 11, 12, 12, 13, 13], x2 = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 3, 7], S2 = [16, 17, 18, 0, 8, 7, 9, 6, 10, 5, 11, 4, 12, 3, 13, 2, 14, 1, 15], z2 = new Array(2 * (l3 + 2));
|
|
38428
38543
|
n(z2);
|
|
38429
38544
|
var C2 = new Array(2 * f2);
|
|
38430
38545
|
n(C2);
|
|
@@ -38434,7 +38549,7 @@ function requireJszip_min() {
|
|
|
38434
38549
|
n(A2);
|
|
38435
38550
|
var I2 = new Array(a);
|
|
38436
38551
|
n(I2);
|
|
38437
|
-
var
|
|
38552
|
+
var O, B2, R, T2 = new Array(f2);
|
|
38438
38553
|
function D2(e2, t2, r22, n2, i2) {
|
|
38439
38554
|
this.static_tree = e2, this.extra_bits = t2, this.extra_base = r22, this.elems = n2, this.max_length = i2, this.has_stree = e2 && e2.length;
|
|
38440
38555
|
}
|
|
@@ -38485,7 +38600,7 @@ function requireJszip_min() {
|
|
|
38485
38600
|
}
|
|
38486
38601
|
function K2(e2, t2, r22) {
|
|
38487
38602
|
var n2, i2, s22, a2, o2 = 0;
|
|
38488
|
-
if (0 !== e2.last_lit) for (; n2 = e2.pending_buf[e2.d_buf + 2 * o2] << 8 | e2.pending_buf[e2.d_buf + 2 * o2 + 1], i2 = e2.pending_buf[e2.l_buf + o2], o2++, 0 === n2 ? L2(e2, i2, t2) : (L2(e2, (s22 = A2[i2]) + u + 1, t2), 0 !== (a2 = w2[s22]) && P2(e2, i2 -= I2[s22], a2), L2(e2, s22 = N2(--n2), r22), 0 !== (a2 = k2[s22]) && P2(e2, n2 -=
|
|
38603
|
+
if (0 !== e2.last_lit) for (; n2 = e2.pending_buf[e2.d_buf + 2 * o2] << 8 | e2.pending_buf[e2.d_buf + 2 * o2 + 1], i2 = e2.pending_buf[e2.l_buf + o2], o2++, 0 === n2 ? L2(e2, i2, t2) : (L2(e2, (s22 = A2[i2]) + u + 1, t2), 0 !== (a2 = w2[s22]) && P2(e2, i2 -= I2[s22], a2), L2(e2, s22 = N2(--n2), r22), 0 !== (a2 = k2[s22]) && P2(e2, n2 -= T2[s22], a2)), o2 < e2.last_lit; ) ;
|
|
38489
38604
|
L2(e2, m2, t2);
|
|
38490
38605
|
}
|
|
38491
38606
|
function Y2(e2, t2) {
|
|
@@ -38519,7 +38634,7 @@ function requireJszip_min() {
|
|
|
38519
38634
|
s22 = i2, u2 = (o2 = 0) === a2 ? (h22 = 138, 3) : i2 === a2 ? (h22 = 6, 3) : (h22 = 7, 4);
|
|
38520
38635
|
}
|
|
38521
38636
|
}
|
|
38522
|
-
n(
|
|
38637
|
+
n(T2);
|
|
38523
38638
|
var q2 = false;
|
|
38524
38639
|
function J2(e2, t2, r22, n2) {
|
|
38525
38640
|
P2(e2, (s2 << 1) + (n2 ? 1 : 0), 3), (function(e3, t3, r3, n3) {
|
|
@@ -38530,16 +38645,16 @@ function requireJszip_min() {
|
|
|
38530
38645
|
q2 || ((function() {
|
|
38531
38646
|
var e3, t2, r22, n2, i2, s22 = new Array(g + 1);
|
|
38532
38647
|
for (n2 = r22 = 0; n2 < a - 1; n2++) for (I2[n2] = r22, e3 = 0; e3 < 1 << w2[n2]; e3++) A2[r22++] = n2;
|
|
38533
|
-
for (A2[r22 - 1] = n2, n2 = i2 = 0; n2 < 16; n2++) for (
|
|
38534
|
-
for (i2 >>= 7; n2 < f2; n2++) for (
|
|
38648
|
+
for (A2[r22 - 1] = n2, n2 = i2 = 0; n2 < 16; n2++) for (T2[n2] = i2, e3 = 0; e3 < 1 << k2[n2]; e3++) E2[i2++] = n2;
|
|
38649
|
+
for (i2 >>= 7; n2 < f2; n2++) for (T2[n2] = i2 << 7, e3 = 0; e3 < 1 << k2[n2] - 7; e3++) E2[256 + i2++] = n2;
|
|
38535
38650
|
for (t2 = 0; t2 <= g; t2++) s22[t2] = 0;
|
|
38536
38651
|
for (e3 = 0; e3 <= 143; ) z2[2 * e3 + 1] = 8, e3++, s22[8]++;
|
|
38537
38652
|
for (; e3 <= 255; ) z2[2 * e3 + 1] = 9, e3++, s22[9]++;
|
|
38538
38653
|
for (; e3 <= 279; ) z2[2 * e3 + 1] = 7, e3++, s22[7]++;
|
|
38539
38654
|
for (; e3 <= 287; ) z2[2 * e3 + 1] = 8, e3++, s22[8]++;
|
|
38540
38655
|
for (Z(z2, l3 + 1, s22), e3 = 0; e3 < f2; e3++) C2[2 * e3 + 1] = 5, C2[2 * e3] = j2(e3, 5);
|
|
38541
|
-
|
|
38542
|
-
})(), q2 = true), e2.l_desc = new F2(e2.dyn_ltree,
|
|
38656
|
+
O = new D2(z2, w2, u + 1, l3, g), B2 = new D2(C2, k2, 0, f2, g), R = new D2(new Array(0), x2, 0, c2, p);
|
|
38657
|
+
})(), q2 = true), e2.l_desc = new F2(e2.dyn_ltree, O), e2.d_desc = new F2(e2.dyn_dtree, B2), e2.bl_desc = new F2(e2.bl_tree, R), e2.bi_buf = 0, e2.bi_valid = 0, W2(e2);
|
|
38543
38658
|
}, r2._tr_stored_block = J2, r2._tr_flush_block = function(e2, t2, r22, n2) {
|
|
38544
38659
|
var i2, s22, a2 = 0;
|
|
38545
38660
|
0 < e2.level ? (2 === e2.strm.data_type && (e2.strm.data_type = (function(e3) {
|
|
@@ -39615,17 +39730,17 @@ function deepActiveElement(doc2) {
|
|
|
39615
39730
|
elt = elt.shadowRoot.activeElement;
|
|
39616
39731
|
return elt;
|
|
39617
39732
|
}
|
|
39618
|
-
function caretFromPoint(doc2,
|
|
39733
|
+
function caretFromPoint(doc2, x2, y2) {
|
|
39619
39734
|
if (doc2.caretPositionFromPoint) {
|
|
39620
39735
|
try {
|
|
39621
|
-
let pos = doc2.caretPositionFromPoint(
|
|
39736
|
+
let pos = doc2.caretPositionFromPoint(x2, y2);
|
|
39622
39737
|
if (pos)
|
|
39623
39738
|
return { node: pos.offsetNode, offset: Math.min(nodeSize(pos.offsetNode), pos.offset) };
|
|
39624
39739
|
} catch (_2) {
|
|
39625
39740
|
}
|
|
39626
39741
|
}
|
|
39627
39742
|
if (doc2.caretRangeFromPoint) {
|
|
39628
|
-
let range2 = doc2.caretRangeFromPoint(
|
|
39743
|
+
let range2 = doc2.caretRangeFromPoint(x2, y2);
|
|
39629
39744
|
if (range2)
|
|
39630
39745
|
return { node: range2.startContainer, offset: Math.min(nodeSize(range2.startContainer), range2.startOffset) };
|
|
39631
39746
|
}
|
|
@@ -39724,8 +39839,8 @@ function scrollRectIntoView(view, rect, startDOM) {
|
|
|
39724
39839
|
function storeScrollPos(view) {
|
|
39725
39840
|
let rect = view.dom.getBoundingClientRect(), startY = Math.max(0, rect.top);
|
|
39726
39841
|
let refDOM, refTop;
|
|
39727
|
-
for (let
|
|
39728
|
-
let dom = view.root.elementFromPoint(
|
|
39842
|
+
for (let x2 = (rect.left + rect.right) / 2, y2 = startY + 1; y2 < Math.min(innerHeight, rect.bottom); y2 += 5) {
|
|
39843
|
+
let dom = view.root.elementFromPoint(x2, y2);
|
|
39729
39844
|
if (!dom || dom == view.dom || !view.dom.contains(dom))
|
|
39730
39845
|
continue;
|
|
39731
39846
|
let localRect = dom.getBoundingClientRect();
|
|
@@ -39827,17 +39942,20 @@ function findOffsetInNode(node, coords) {
|
|
|
39827
39942
|
}
|
|
39828
39943
|
function findOffsetInText(node, coords) {
|
|
39829
39944
|
let len = node.nodeValue.length;
|
|
39830
|
-
let range2 = document.createRange();
|
|
39945
|
+
let range2 = document.createRange(), result;
|
|
39831
39946
|
for (let i = 0; i < len; i++) {
|
|
39832
39947
|
range2.setEnd(node, i + 1);
|
|
39833
39948
|
range2.setStart(node, i);
|
|
39834
39949
|
let rect = singleRect(range2, 1);
|
|
39835
39950
|
if (rect.top == rect.bottom)
|
|
39836
39951
|
continue;
|
|
39837
|
-
if (inRect(coords, rect))
|
|
39838
|
-
|
|
39952
|
+
if (inRect(coords, rect)) {
|
|
39953
|
+
result = { node, offset: i + (coords.left >= (rect.left + rect.right) / 2 ? 1 : 0) };
|
|
39954
|
+
break;
|
|
39955
|
+
}
|
|
39839
39956
|
}
|
|
39840
|
-
|
|
39957
|
+
range2.detach();
|
|
39958
|
+
return result || { node, offset: 0 };
|
|
39841
39959
|
}
|
|
39842
39960
|
function inRect(coords, rect) {
|
|
39843
39961
|
return coords.left >= rect.left - 1 && coords.left <= rect.right + 1 && coords.top >= rect.top - 1 && coords.top <= rect.bottom + 1;
|
|
@@ -40021,8 +40139,8 @@ function coordsAtPos(view, pos, side) {
|
|
|
40021
40139
|
function flattenV(rect, left2) {
|
|
40022
40140
|
if (rect.width == 0)
|
|
40023
40141
|
return rect;
|
|
40024
|
-
let
|
|
40025
|
-
return { top: rect.top, bottom: rect.bottom, left:
|
|
40142
|
+
let x2 = left2 ? rect.left : rect.right;
|
|
40143
|
+
return { top: rect.top, bottom: rect.bottom, left: x2, right: x2 };
|
|
40026
40144
|
}
|
|
40027
40145
|
function flattenH(rect, top2) {
|
|
40028
40146
|
if (rect.height == 0)
|
|
@@ -42584,7 +42702,7 @@ editHandlers.compositionstart = editHandlers.compositionupdate = (view) => {
|
|
|
42584
42702
|
if (!view.composing) {
|
|
42585
42703
|
view.domObserver.flush();
|
|
42586
42704
|
let { state: state2 } = view, $pos = state2.selection.$to;
|
|
42587
|
-
if (state2.selection instanceof TextSelection$1 && (state2.storedMarks || !$pos.textOffset && $pos.parentOffset && $pos.nodeBefore.marks.some((m2) => m2.type.spec.inclusive === false))) {
|
|
42705
|
+
if (state2.selection instanceof TextSelection$1 && (state2.storedMarks || !$pos.textOffset && $pos.parentOffset && $pos.nodeBefore.marks.some((m2) => m2.type.spec.inclusive === false) || chrome && windows$1 && selectionBeforeUneditable(view))) {
|
|
42588
42706
|
view.markCursor = view.state.storedMarks || $pos.marks();
|
|
42589
42707
|
endComposition(view, true);
|
|
42590
42708
|
view.markCursor = null;
|
|
@@ -42612,6 +42730,13 @@ editHandlers.compositionstart = editHandlers.compositionupdate = (view) => {
|
|
|
42612
42730
|
}
|
|
42613
42731
|
scheduleComposeEnd(view, timeoutComposition);
|
|
42614
42732
|
};
|
|
42733
|
+
function selectionBeforeUneditable(view) {
|
|
42734
|
+
let { focusNode, focusOffset } = view.domSelectionRange();
|
|
42735
|
+
if (!focusNode || focusNode.nodeType != 1 || focusOffset >= focusNode.childNodes.length)
|
|
42736
|
+
return false;
|
|
42737
|
+
let next = focusNode.childNodes[focusOffset];
|
|
42738
|
+
return next.nodeType == 1 && next.contentEditable == "false";
|
|
42739
|
+
}
|
|
42615
42740
|
editHandlers.compositionend = (view, event) => {
|
|
42616
42741
|
if (view.composing) {
|
|
42617
42742
|
view.input.composing = false;
|
|
@@ -42815,10 +42940,14 @@ handlers.dragend = (view) => {
|
|
|
42815
42940
|
}, 50);
|
|
42816
42941
|
};
|
|
42817
42942
|
editHandlers.dragover = editHandlers.dragenter = (_2, e) => e.preventDefault();
|
|
42818
|
-
editHandlers.drop = (view,
|
|
42819
|
-
|
|
42820
|
-
|
|
42821
|
-
|
|
42943
|
+
editHandlers.drop = (view, event) => {
|
|
42944
|
+
try {
|
|
42945
|
+
handleDrop(view, event, view.dragging);
|
|
42946
|
+
} finally {
|
|
42947
|
+
view.dragging = null;
|
|
42948
|
+
}
|
|
42949
|
+
};
|
|
42950
|
+
function handleDrop(view, event, dragging) {
|
|
42822
42951
|
if (!event.dataTransfer)
|
|
42823
42952
|
return;
|
|
42824
42953
|
let eventPos = view.posAtCoords(eventCoords(event));
|
|
@@ -42871,7 +43000,7 @@ editHandlers.drop = (view, _event) => {
|
|
|
42871
43000
|
}
|
|
42872
43001
|
view.focus();
|
|
42873
43002
|
view.dispatch(tr.setMeta("uiEvent", "drop"));
|
|
42874
|
-
}
|
|
43003
|
+
}
|
|
42875
43004
|
handlers.focus = (view) => {
|
|
42876
43005
|
view.input.lastFocus = Date.now();
|
|
42877
43006
|
if (!view.focused) {
|
|
@@ -43721,6 +43850,13 @@ class DOMObserver {
|
|
|
43721
43850
|
br.remove();
|
|
43722
43851
|
}
|
|
43723
43852
|
}
|
|
43853
|
+
} else if ((chrome || safari) && added.some((n) => n.nodeName == "BR") && (view.input.lastKeyCode == 8 || view.input.lastKeyCode == 46)) {
|
|
43854
|
+
for (let node of added)
|
|
43855
|
+
if (node.nodeName == "BR" && node.parentNode) {
|
|
43856
|
+
let after = node.nextSibling;
|
|
43857
|
+
if (after && after.nodeType == 1 && after.contentEditable == "false")
|
|
43858
|
+
node.parentNode.removeChild(node);
|
|
43859
|
+
}
|
|
43724
43860
|
}
|
|
43725
43861
|
let readSel = null;
|
|
43726
43862
|
if (from2 < 0 && newSel && view.input.lastFocus > Date.now() - 200 && Math.max(view.input.lastTouch, view.input.lastClick.time) < Date.now() - 300 && selectionCollapsed(sel) && (readSel = selectionFromDOM(view)) && readSel.eq(Selection.near(view.state.doc.resolve(0), 1))) {
|
|
@@ -45029,10 +45165,10 @@ const createTimeoutClass = (clearFunction) => class TT {
|
|
|
45029
45165
|
const Timeout = createTimeoutClass(clearTimeout);
|
|
45030
45166
|
const timeout = (timeout2, callback) => new Timeout(setTimeout(callback, timeout2));
|
|
45031
45167
|
const rotr = (w2, shift2) => w2 >>> shift2 | w2 << 32 - shift2;
|
|
45032
|
-
const sum0to256 = (
|
|
45033
|
-
const sum1to256 = (
|
|
45034
|
-
const sigma0to256 = (
|
|
45035
|
-
const sigma1to256 = (
|
|
45168
|
+
const sum0to256 = (x2) => rotr(x2, 2) ^ rotr(x2, 13) ^ rotr(x2, 22);
|
|
45169
|
+
const sum1to256 = (x2) => rotr(x2, 6) ^ rotr(x2, 11) ^ rotr(x2, 25);
|
|
45170
|
+
const sigma0to256 = (x2) => rotr(x2, 7) ^ rotr(x2, 18) ^ x2 >>> 3;
|
|
45171
|
+
const sigma1to256 = (x2) => rotr(x2, 17) ^ rotr(x2, 19) ^ x2 >>> 10;
|
|
45036
45172
|
const K = new Uint32Array([
|
|
45037
45173
|
1116352408,
|
|
45038
45174
|
1899447441,
|
|
@@ -54054,7 +54190,7 @@ const _Editor = class _Editor2 extends EventEmitter$1 {
|
|
|
54054
54190
|
{ default: remarkStringify },
|
|
54055
54191
|
{ default: remarkGfm }
|
|
54056
54192
|
] = await Promise.all([
|
|
54057
|
-
import("./index-
|
|
54193
|
+
import("./index-_8cQcYzu-Dj8Emsl2.es.js"),
|
|
54058
54194
|
import("./index-DRCvimau-Cw339678.es.js"),
|
|
54059
54195
|
import("./index-C_x_N6Uh-DJn8hIEt.es.js"),
|
|
54060
54196
|
import("./index-D_sWOSiG-DE96TaT5.es.js"),
|
|
@@ -54272,7 +54408,7 @@ const _Editor = class _Editor2 extends EventEmitter$1 {
|
|
|
54272
54408
|
* @returns {Object | void} Migration results
|
|
54273
54409
|
*/
|
|
54274
54410
|
processCollaborationMigrations() {
|
|
54275
|
-
console.debug("[checkVersionMigrations] Current editor version", "0.34.
|
|
54411
|
+
console.debug("[checkVersionMigrations] Current editor version", "0.34.6-RC1");
|
|
54276
54412
|
if (!this.options.ydoc) return;
|
|
54277
54413
|
const metaMap = this.options.ydoc.getMap("meta");
|
|
54278
54414
|
let docVersion = metaMap.get("version");
|
|
@@ -56151,16 +56287,16 @@ function getCursorPositionRelativeToContainer(view, eventLocation) {
|
|
|
56151
56287
|
const { state: state2, dom } = view;
|
|
56152
56288
|
const { selection } = state2;
|
|
56153
56289
|
const containerRect = dom.getBoundingClientRect();
|
|
56154
|
-
let
|
|
56290
|
+
let x2, y2;
|
|
56155
56291
|
if (typeof eventLocation.clientX === "number" && typeof eventLocation.clientY === "number") {
|
|
56156
|
-
|
|
56292
|
+
x2 = eventLocation.clientX - containerRect.left;
|
|
56157
56293
|
y2 = eventLocation.clientY - containerRect.top;
|
|
56158
56294
|
} else {
|
|
56159
56295
|
const cursorCoords = view.coordsAtPos(selection.from);
|
|
56160
|
-
|
|
56296
|
+
x2 = cursorCoords.left - containerRect.left;
|
|
56161
56297
|
y2 = cursorCoords.top - containerRect.top;
|
|
56162
56298
|
}
|
|
56163
|
-
return { left:
|
|
56299
|
+
return { left: x2, top: y2 };
|
|
56164
56300
|
}
|
|
56165
56301
|
const SlashMenuPluginKey = new PluginKey("slashMenu");
|
|
56166
56302
|
const SlashMenu = Extension.create({
|
|
@@ -56439,17 +56575,17 @@ class StructuredContentViewBase {
|
|
|
56439
56575
|
if (!this.dom || this.contentDOM?.contains(target) || !dragHandle) {
|
|
56440
56576
|
return;
|
|
56441
56577
|
}
|
|
56442
|
-
let
|
|
56578
|
+
let x2 = 0;
|
|
56443
56579
|
let y2 = 0;
|
|
56444
56580
|
if (this.dom !== dragHandle) {
|
|
56445
56581
|
const domBox = this.dom.getBoundingClientRect();
|
|
56446
56582
|
const handleBox = dragHandle.getBoundingClientRect();
|
|
56447
56583
|
const offsetX = event.offsetX ?? event.nativeEvent?.offsetX;
|
|
56448
56584
|
const offsetY = event.offsetY ?? event.nativeEvent?.offsetY;
|
|
56449
|
-
|
|
56585
|
+
x2 = handleBox.x - domBox.x + offsetX;
|
|
56450
56586
|
y2 = handleBox.y - domBox.y + offsetY;
|
|
56451
56587
|
}
|
|
56452
|
-
event.dataTransfer?.setDragImage(this.dom,
|
|
56588
|
+
event.dataTransfer?.setDragImage(this.dom, x2, y2);
|
|
56453
56589
|
const pos = this.getPos();
|
|
56454
56590
|
if (typeof pos !== "number") {
|
|
56455
56591
|
return;
|
|
@@ -56909,7 +57045,7 @@ const StructuredContentCommands = Extension.create({
|
|
|
56909
57045
|
* @param {string} id - Unique identifier of the field
|
|
56910
57046
|
* @param {StructuredContentUpdate} options
|
|
56911
57047
|
* @example
|
|
56912
|
-
* editor.commands.updateStructuredContentById('123', { text: 'Jane Doe' });
|
|
57048
|
+
* editor.commands.updateStructuredContentById('123', { text: 'Jane Doe', keepTextNodeStyles: true });
|
|
56913
57049
|
* editor.commands.updateStructuredContentById('123', {
|
|
56914
57050
|
* json: { type: 'text', text: 'Jane Doe' },
|
|
56915
57051
|
* });
|
|
@@ -56930,7 +57066,9 @@ const StructuredContentCommands = Extension.create({
|
|
|
56930
57066
|
const posTo = pos + node.nodeSize;
|
|
56931
57067
|
let content = null;
|
|
56932
57068
|
if (options.text) {
|
|
56933
|
-
|
|
57069
|
+
const firstTextNode = options.keepTextNodeStyles === true ? node.content.content.find((n) => n.type.name === "text") : null;
|
|
57070
|
+
const textMarks = firstTextNode ? firstTextNode.marks : [];
|
|
57071
|
+
content = schema.text(options.text, textMarks);
|
|
56934
57072
|
}
|
|
56935
57073
|
if (options.html) {
|
|
56936
57074
|
const html = htmlHandler(options.html, editor);
|
|
@@ -56944,6 +57082,13 @@ const StructuredContentCommands = Extension.create({
|
|
|
56944
57082
|
content = node.content;
|
|
56945
57083
|
}
|
|
56946
57084
|
const updatedNode = node.type.create({ ...node.attrs, ...options.attrs }, content, node.marks);
|
|
57085
|
+
try {
|
|
57086
|
+
const nodeForValidation = editor.validateJSON(updatedNode.toJSON());
|
|
57087
|
+
nodeForValidation.check();
|
|
57088
|
+
} catch (error) {
|
|
57089
|
+
console.error("Invalid content.", "Passed value:", content, "Error:", error);
|
|
57090
|
+
return false;
|
|
57091
|
+
}
|
|
56947
57092
|
tr.replaceWith(posFrom, posTo, updatedNode);
|
|
56948
57093
|
}
|
|
56949
57094
|
return true;
|
|
@@ -57028,7 +57173,7 @@ const StructuredContentCommands = Extension.create({
|
|
|
57028
57173
|
* @param {StructuredContentUpdate} options
|
|
57029
57174
|
* @example
|
|
57030
57175
|
* // Update all fields in the customer-info group
|
|
57031
|
-
* editor.commands.updateStructuredContentByGroup('customer-info', { text: 'Jane Doe' });
|
|
57176
|
+
* editor.commands.updateStructuredContentByGroup('customer-info', { text: 'Jane Doe', keepTextNodeStyles: true });
|
|
57032
57177
|
*
|
|
57033
57178
|
* // Update block content in a group
|
|
57034
57179
|
* editor.commands.updateStructuredContentByGroup('terms-section', {
|
|
@@ -57042,13 +57187,14 @@ const StructuredContentCommands = Extension.create({
|
|
|
57042
57187
|
}
|
|
57043
57188
|
const { schema } = editor;
|
|
57044
57189
|
if (dispatch) {
|
|
57045
|
-
|
|
57190
|
+
const updates = [];
|
|
57191
|
+
for (const structuredContent of structuredContentTags) {
|
|
57046
57192
|
const { pos, node } = structuredContent;
|
|
57047
|
-
const posFrom = tr.mapping.map(pos);
|
|
57048
|
-
const posTo = tr.mapping.map(pos + node.nodeSize);
|
|
57049
57193
|
let content = null;
|
|
57050
57194
|
if (options.text) {
|
|
57051
|
-
|
|
57195
|
+
const firstTextNode = options.keepTextNodeStyles === true ? node.content.content.find((n) => n.type.name === "text") : null;
|
|
57196
|
+
const textMarks = firstTextNode ? firstTextNode.marks : [];
|
|
57197
|
+
content = schema.text(options.text, textMarks);
|
|
57052
57198
|
}
|
|
57053
57199
|
if (options.html) {
|
|
57054
57200
|
const html = htmlHandler(options.html, editor);
|
|
@@ -57062,11 +57208,23 @@ const StructuredContentCommands = Extension.create({
|
|
|
57062
57208
|
content = node.content;
|
|
57063
57209
|
}
|
|
57064
57210
|
const updatedNode = node.type.create({ ...node.attrs, ...options.attrs }, content, node.marks);
|
|
57211
|
+
try {
|
|
57212
|
+
const nodeForValidation = editor.validateJSON(updatedNode.toJSON());
|
|
57213
|
+
nodeForValidation.check();
|
|
57214
|
+
} catch (error) {
|
|
57215
|
+
console.error("Invalid content.", "Passed value:", content, "Error:", error);
|
|
57216
|
+
return false;
|
|
57217
|
+
}
|
|
57218
|
+
updates.push({ pos, node, updatedNode });
|
|
57219
|
+
}
|
|
57220
|
+
for (const { pos, node, updatedNode } of updates) {
|
|
57221
|
+
const posFrom = tr.mapping.map(pos);
|
|
57222
|
+
const posTo = tr.mapping.map(pos + node.nodeSize);
|
|
57065
57223
|
const currentNode = tr.doc.nodeAt(posFrom);
|
|
57066
57224
|
if (currentNode && node.eq(currentNode)) {
|
|
57067
57225
|
tr.replaceWith(posFrom, posTo, updatedNode);
|
|
57068
57226
|
}
|
|
57069
|
-
}
|
|
57227
|
+
}
|
|
57070
57228
|
}
|
|
57071
57229
|
return true;
|
|
57072
57230
|
},
|
|
@@ -64685,17 +64843,17 @@ function parseToRgba(color) {
|
|
|
64685
64843
|
const reducedHexMatch = reducedHexRegex.exec(normalizedColor);
|
|
64686
64844
|
if (reducedHexMatch) {
|
|
64687
64845
|
const arr = Array.from(reducedHexMatch).slice(1);
|
|
64688
|
-
return [...arr.slice(0, 3).map((
|
|
64846
|
+
return [...arr.slice(0, 3).map((x2) => parseInt(r$1(x2, 2), 16)), parseInt(r$1(arr[3] || "f", 2), 16) / 255];
|
|
64689
64847
|
}
|
|
64690
64848
|
const hexMatch = hexRegex$1.exec(normalizedColor);
|
|
64691
64849
|
if (hexMatch) {
|
|
64692
64850
|
const arr = Array.from(hexMatch).slice(1);
|
|
64693
|
-
return [...arr.slice(0, 3).map((
|
|
64851
|
+
return [...arr.slice(0, 3).map((x2) => parseInt(x2, 16)), parseInt(arr[3] || "ff", 16) / 255];
|
|
64694
64852
|
}
|
|
64695
64853
|
const rgbaMatch = rgbaRegex$1.exec(normalizedColor);
|
|
64696
64854
|
if (rgbaMatch) {
|
|
64697
64855
|
const arr = Array.from(rgbaMatch).slice(1);
|
|
64698
|
-
return [...arr.slice(0, 3).map((
|
|
64856
|
+
return [...arr.slice(0, 3).map((x2) => parseInt(x2, 10)), parseFloat(arr[3] || "1")];
|
|
64699
64857
|
}
|
|
64700
64858
|
const hslaMatch = hslaRegex$1.exec(normalizedColor);
|
|
64701
64859
|
if (hslaMatch) {
|
|
@@ -64714,7 +64872,7 @@ function hash$2(str) {
|
|
|
64714
64872
|
}
|
|
64715
64873
|
return (hash2 >>> 0) % 2341;
|
|
64716
64874
|
}
|
|
64717
|
-
const colorToInt = (
|
|
64875
|
+
const colorToInt = (x2) => parseInt(x2.replace(/_/g, ""), 36);
|
|
64718
64876
|
const compressedColorMap = "1q29ehhb 1n09sgk7 1kl1ekf_ _yl4zsno 16z9eiv3 1p29lhp8 _bd9zg04 17u0____ _iw9zhe5 _to73___ _r45e31e _7l6g016 _jh8ouiv _zn3qba8 1jy4zshs 11u87k0u 1ro9yvyo 1aj3xael 1gz9zjz0 _3w8l4xo 1bf1ekf_ _ke3v___ _4rrkb__ 13j776yz _646mbhl _nrjr4__ _le6mbhl 1n37ehkb _m75f91n _qj3bzfz 1939yygw 11i5z6x8 _1k5f8xs 1509441m 15t5lwgf _ae2th1n _tg1ugcv 1lp1ugcv 16e14up_ _h55rw7n _ny9yavn _7a11xb_ 1ih442g9 _pv442g9 1mv16xof 14e6y7tu 1oo9zkds 17d1cisi _4v9y70f _y98m8kc 1019pq0v 12o9zda8 _348j4f4 1et50i2o _8epa8__ _ts6senj 1o350i2o 1mi9eiuo 1259yrp0 1ln80gnw _632xcoy 1cn9zldc _f29edu4 1n490c8q _9f9ziet 1b94vk74 _m49zkct 1kz6s73a 1eu9dtog _q58s1rz 1dy9sjiq __u89jo3 _aj5nkwg _ld89jo3 13h9z6wx _qa9z2ii _l119xgq _bs5arju 1hj4nwk9 1qt4nwk9 1ge6wau6 14j9zlcw 11p1edc_ _ms1zcxe _439shk6 _jt9y70f _754zsow 1la40eju _oq5p___ _x279qkz 1fa5r3rv _yd2d9ip _424tcku _8y1di2_ _zi2uabw _yy7rn9h 12yz980_ __39ljp6 1b59zg0x _n39zfzp 1fy9zest _b33k___ _hp9wq92 1il50hz4 _io472ub _lj9z3eo 19z9ykg0 _8t8iu3a 12b9bl4a 1ak5yw0o _896v4ku _tb8k8lv _s59zi6t _c09ze0p 1lg80oqn 1id9z8wb _238nba5 1kq6wgdi _154zssg _tn3zk49 _da9y6tc 1sg7cv4f _r12jvtt 1gq5fmkz 1cs9rvci _lp9jn1c _xw1tdnb 13f9zje6 16f6973h _vo7ir40 _bt5arjf _rc45e4t _hr4e100 10v4e100 _hc9zke2 _w91egv_ _sj2r1kk 13c87yx8 _vqpds__ _ni8ggk8 _tj9yqfb 1ia2j4r4 _7x9b10u 1fc9ld4j 1eq9zldr _5j9lhpx _ez9zl6o _md61fzm".split(" ").reduce((acc, next) => {
|
|
64719
64877
|
const key2 = colorToInt(next.substring(0, 3));
|
|
64720
64878
|
const hex2 = colorToInt(next.substring(3)).toString(16);
|
|
@@ -64778,8 +64936,8 @@ const hslToRgb = (hue, saturation, lightness) => {
|
|
|
64778
64936
|
};
|
|
64779
64937
|
function toHex(color) {
|
|
64780
64938
|
const [r2, g, b2, a] = parseToRgba(color);
|
|
64781
|
-
let hex2 = (
|
|
64782
|
-
const h2 = guard(0, 255,
|
|
64939
|
+
let hex2 = (x2) => {
|
|
64940
|
+
const h2 = guard(0, 255, x2).toString(16);
|
|
64783
64941
|
return h2.length === 1 ? `0${h2}` : h2;
|
|
64784
64942
|
};
|
|
64785
64943
|
return `#${hex2(r2)}${hex2(g)}${hex2(b2)}${a < 1 ? hex2(Math.round(a * 255)) : ""}`;
|
|
@@ -66883,10 +67041,10 @@ const Image = Node$1.create({
|
|
|
66883
67041
|
let minX = 0;
|
|
66884
67042
|
let minY = 0;
|
|
66885
67043
|
let maxY = 0;
|
|
66886
|
-
attrs.polygon.forEach(([
|
|
66887
|
-
if (floatRight &&
|
|
66888
|
-
if (
|
|
66889
|
-
if (
|
|
67044
|
+
attrs.polygon.forEach(([x2, y2]) => {
|
|
67045
|
+
if (floatRight && x2 < horizontalOffset) horizontalOffset = x2;
|
|
67046
|
+
if (x2 > maxX) maxX = x2;
|
|
67047
|
+
if (x2 < minX) minX = x2;
|
|
66890
67048
|
if (y2 > maxY) maxY = y2;
|
|
66891
67049
|
if (y2 < minY) minY = y2;
|
|
66892
67050
|
});
|
|
@@ -66895,7 +67053,7 @@ const Image = Node$1.create({
|
|
|
66895
67053
|
const scaleWidth = Math.min(1, size2.width / originalWidth);
|
|
66896
67054
|
const scaleHeight = Math.min(1, size2.height / originalHeight);
|
|
66897
67055
|
const verticalOffset = Math.max(0, marginOffset.top);
|
|
66898
|
-
const points = attrs.polygon.map(([
|
|
67056
|
+
const points = attrs.polygon.map(([x2, y2]) => `${horizontalOffset + x2 * scaleWidth}px ${verticalOffset + y2 * scaleHeight}px`).join(", ");
|
|
66899
67057
|
style2 += `shape-outside: polygon(${points});`;
|
|
66900
67058
|
}
|
|
66901
67059
|
break;
|
|
@@ -70549,13 +70707,13 @@ class ShapeGroupView {
|
|
|
70549
70707
|
createShapeElement(shape) {
|
|
70550
70708
|
const attrs = shape.attrs;
|
|
70551
70709
|
if (!attrs) return null;
|
|
70552
|
-
const
|
|
70710
|
+
const x2 = attrs.x || 0;
|
|
70553
70711
|
const y2 = attrs.y || 0;
|
|
70554
70712
|
const width = attrs.width || 100;
|
|
70555
70713
|
const height = attrs.height || 100;
|
|
70556
70714
|
const g = document.createElementNS("http://www.w3.org/2000/svg", "g");
|
|
70557
70715
|
const transforms = [];
|
|
70558
|
-
transforms.push(`translate(${
|
|
70716
|
+
transforms.push(`translate(${x2}, ${y2})`);
|
|
70559
70717
|
if (attrs.rotation !== 0) {
|
|
70560
70718
|
transforms.push(`rotate(${attrs.rotation} ${width / 2} ${height / 2})`);
|
|
70561
70719
|
}
|
|
@@ -72282,7 +72440,7 @@ function getBoundingClientRect$1(element, includeScale, isFixedStrategy) {
|
|
|
72282
72440
|
}
|
|
72283
72441
|
var _ref = isElement$2(element) ? getWindow$1(element) : window, visualViewport = _ref.visualViewport;
|
|
72284
72442
|
var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;
|
|
72285
|
-
var
|
|
72443
|
+
var x2 = (clientRect2.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;
|
|
72286
72444
|
var y2 = (clientRect2.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;
|
|
72287
72445
|
var width = clientRect2.width / scaleX;
|
|
72288
72446
|
var height = clientRect2.height / scaleY;
|
|
@@ -72290,10 +72448,10 @@ function getBoundingClientRect$1(element, includeScale, isFixedStrategy) {
|
|
|
72290
72448
|
width,
|
|
72291
72449
|
height,
|
|
72292
72450
|
top: y2,
|
|
72293
|
-
right:
|
|
72451
|
+
right: x2 + width,
|
|
72294
72452
|
bottom: y2 + height,
|
|
72295
|
-
left:
|
|
72296
|
-
x,
|
|
72453
|
+
left: x2,
|
|
72454
|
+
x: x2,
|
|
72297
72455
|
y: y2
|
|
72298
72456
|
};
|
|
72299
72457
|
}
|
|
@@ -72494,25 +72652,25 @@ var unsetSides = {
|
|
|
72494
72652
|
left: "auto"
|
|
72495
72653
|
};
|
|
72496
72654
|
function roundOffsetsByDPR(_ref, win) {
|
|
72497
|
-
var
|
|
72655
|
+
var x2 = _ref.x, y2 = _ref.y;
|
|
72498
72656
|
var dpr = win.devicePixelRatio || 1;
|
|
72499
72657
|
return {
|
|
72500
|
-
x: round$1(
|
|
72658
|
+
x: round$1(x2 * dpr) / dpr || 0,
|
|
72501
72659
|
y: round$1(y2 * dpr) / dpr || 0
|
|
72502
72660
|
};
|
|
72503
72661
|
}
|
|
72504
72662
|
function mapToStyles(_ref2) {
|
|
72505
72663
|
var _Object$assign2;
|
|
72506
72664
|
var popper2 = _ref2.popper, popperRect = _ref2.popperRect, placement = _ref2.placement, variation = _ref2.variation, offsets = _ref2.offsets, position = _ref2.position, gpuAcceleration = _ref2.gpuAcceleration, adaptive = _ref2.adaptive, roundOffsets = _ref2.roundOffsets, isFixed = _ref2.isFixed;
|
|
72507
|
-
var _offsets$x = offsets.x,
|
|
72665
|
+
var _offsets$x = offsets.x, x2 = _offsets$x === void 0 ? 0 : _offsets$x, _offsets$y = offsets.y, y2 = _offsets$y === void 0 ? 0 : _offsets$y;
|
|
72508
72666
|
var _ref3 = typeof roundOffsets === "function" ? roundOffsets({
|
|
72509
|
-
x,
|
|
72667
|
+
x: x2,
|
|
72510
72668
|
y: y2
|
|
72511
72669
|
}) : {
|
|
72512
|
-
x,
|
|
72670
|
+
x: x2,
|
|
72513
72671
|
y: y2
|
|
72514
72672
|
};
|
|
72515
|
-
|
|
72673
|
+
x2 = _ref3.x;
|
|
72516
72674
|
y2 = _ref3.y;
|
|
72517
72675
|
var hasX = offsets.hasOwnProperty("x");
|
|
72518
72676
|
var hasY = offsets.hasOwnProperty("y");
|
|
@@ -72546,27 +72704,27 @@ function mapToStyles(_ref2) {
|
|
|
72546
72704
|
// $FlowFixMe[prop-missing]
|
|
72547
72705
|
offsetParent[widthProp]
|
|
72548
72706
|
);
|
|
72549
|
-
|
|
72550
|
-
|
|
72707
|
+
x2 -= offsetX - popperRect.width;
|
|
72708
|
+
x2 *= gpuAcceleration ? 1 : -1;
|
|
72551
72709
|
}
|
|
72552
72710
|
}
|
|
72553
72711
|
var commonStyles = Object.assign({
|
|
72554
72712
|
position
|
|
72555
72713
|
}, adaptive && unsetSides);
|
|
72556
72714
|
var _ref4 = roundOffsets === true ? roundOffsetsByDPR({
|
|
72557
|
-
x,
|
|
72715
|
+
x: x2,
|
|
72558
72716
|
y: y2
|
|
72559
72717
|
}, getWindow$1(popper2)) : {
|
|
72560
|
-
x,
|
|
72718
|
+
x: x2,
|
|
72561
72719
|
y: y2
|
|
72562
72720
|
};
|
|
72563
|
-
|
|
72721
|
+
x2 = _ref4.x;
|
|
72564
72722
|
y2 = _ref4.y;
|
|
72565
72723
|
if (gpuAcceleration) {
|
|
72566
72724
|
var _Object$assign;
|
|
72567
|
-
return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? "0" : "", _Object$assign[sideX] = hasX ? "0" : "", _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? "translate(" +
|
|
72725
|
+
return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? "0" : "", _Object$assign[sideX] = hasX ? "0" : "", _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? "translate(" + x2 + "px, " + y2 + "px)" : "translate3d(" + x2 + "px, " + y2 + "px, 0)", _Object$assign));
|
|
72568
72726
|
}
|
|
72569
|
-
return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y2 + "px" : "", _Object$assign2[sideX] = hasX ?
|
|
72727
|
+
return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y2 + "px" : "", _Object$assign2[sideX] = hasX ? x2 + "px" : "", _Object$assign2.transform = "", _Object$assign2));
|
|
72570
72728
|
}
|
|
72571
72729
|
function computeStyles(_ref5) {
|
|
72572
72730
|
var state2 = _ref5.state, options = _ref5.options;
|
|
@@ -72680,21 +72838,21 @@ function getViewportRect$1(element, strategy) {
|
|
|
72680
72838
|
var visualViewport = win.visualViewport;
|
|
72681
72839
|
var width = html.clientWidth;
|
|
72682
72840
|
var height = html.clientHeight;
|
|
72683
|
-
var
|
|
72841
|
+
var x2 = 0;
|
|
72684
72842
|
var y2 = 0;
|
|
72685
72843
|
if (visualViewport) {
|
|
72686
72844
|
width = visualViewport.width;
|
|
72687
72845
|
height = visualViewport.height;
|
|
72688
72846
|
var layoutViewport = isLayoutViewport();
|
|
72689
72847
|
if (layoutViewport || !layoutViewport && strategy === "fixed") {
|
|
72690
|
-
|
|
72848
|
+
x2 = visualViewport.offsetLeft;
|
|
72691
72849
|
y2 = visualViewport.offsetTop;
|
|
72692
72850
|
}
|
|
72693
72851
|
}
|
|
72694
72852
|
return {
|
|
72695
72853
|
width,
|
|
72696
72854
|
height,
|
|
72697
|
-
x:
|
|
72855
|
+
x: x2 + getWindowScrollBarX$1(element),
|
|
72698
72856
|
y: y2
|
|
72699
72857
|
};
|
|
72700
72858
|
}
|
|
@@ -72705,15 +72863,15 @@ function getDocumentRect$1(element) {
|
|
|
72705
72863
|
var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;
|
|
72706
72864
|
var width = max$1(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);
|
|
72707
72865
|
var height = max$1(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);
|
|
72708
|
-
var
|
|
72866
|
+
var x2 = -winScroll.scrollLeft + getWindowScrollBarX$1(element);
|
|
72709
72867
|
var y2 = -winScroll.scrollTop;
|
|
72710
72868
|
if (getComputedStyle$2(body || html).direction === "rtl") {
|
|
72711
|
-
|
|
72869
|
+
x2 += max$1(html.clientWidth, body ? body.clientWidth : 0) - width;
|
|
72712
72870
|
}
|
|
72713
72871
|
return {
|
|
72714
72872
|
width,
|
|
72715
72873
|
height,
|
|
72716
|
-
x,
|
|
72874
|
+
x: x2,
|
|
72717
72875
|
y: y2
|
|
72718
72876
|
};
|
|
72719
72877
|
}
|
|
@@ -73090,9 +73248,9 @@ function offset(_ref2) {
|
|
|
73090
73248
|
acc[placement] = distanceAndSkiddingToXY(placement, state2.rects, offset2);
|
|
73091
73249
|
return acc;
|
|
73092
73250
|
}, {});
|
|
73093
|
-
var _data$state$placement = data[state2.placement],
|
|
73251
|
+
var _data$state$placement = data[state2.placement], x2 = _data$state$placement.x, y2 = _data$state$placement.y;
|
|
73094
73252
|
if (state2.modifiersData.popperOffsets != null) {
|
|
73095
|
-
state2.modifiersData.popperOffsets.x +=
|
|
73253
|
+
state2.modifiersData.popperOffsets.x += x2;
|
|
73096
73254
|
state2.modifiersData.popperOffsets.y += y2;
|
|
73097
73255
|
}
|
|
73098
73256
|
state2.modifiersData[name] = data;
|
|
@@ -75043,7 +75201,7 @@ function getPaddingObject(padding) {
|
|
|
75043
75201
|
}
|
|
75044
75202
|
function rectToClientRect(rect) {
|
|
75045
75203
|
const {
|
|
75046
|
-
x,
|
|
75204
|
+
x: x2,
|
|
75047
75205
|
y: y2,
|
|
75048
75206
|
width,
|
|
75049
75207
|
height
|
|
@@ -75052,10 +75210,10 @@ function rectToClientRect(rect) {
|
|
|
75052
75210
|
width,
|
|
75053
75211
|
height,
|
|
75054
75212
|
top: y2,
|
|
75055
|
-
left:
|
|
75056
|
-
right:
|
|
75213
|
+
left: x2,
|
|
75214
|
+
right: x2 + width,
|
|
75057
75215
|
bottom: y2 + height,
|
|
75058
|
-
x,
|
|
75216
|
+
x: x2,
|
|
75059
75217
|
y: y2
|
|
75060
75218
|
};
|
|
75061
75219
|
}
|
|
@@ -75129,7 +75287,7 @@ const computePosition$1 = async (reference2, floating, config2) => {
|
|
|
75129
75287
|
strategy
|
|
75130
75288
|
});
|
|
75131
75289
|
let {
|
|
75132
|
-
x,
|
|
75290
|
+
x: x2,
|
|
75133
75291
|
y: y2
|
|
75134
75292
|
} = computeCoordsFromPlacement(rects, placement, rtl);
|
|
75135
75293
|
let statefulPlacement = placement;
|
|
@@ -75146,7 +75304,7 @@ const computePosition$1 = async (reference2, floating, config2) => {
|
|
|
75146
75304
|
data,
|
|
75147
75305
|
reset
|
|
75148
75306
|
} = await fn2({
|
|
75149
|
-
x,
|
|
75307
|
+
x: x2,
|
|
75150
75308
|
y: y2,
|
|
75151
75309
|
initialPlacement: placement,
|
|
75152
75310
|
placement: statefulPlacement,
|
|
@@ -75159,7 +75317,7 @@ const computePosition$1 = async (reference2, floating, config2) => {
|
|
|
75159
75317
|
floating
|
|
75160
75318
|
}
|
|
75161
75319
|
});
|
|
75162
|
-
|
|
75320
|
+
x2 = nextX != null ? nextX : x2;
|
|
75163
75321
|
y2 = nextY != null ? nextY : y2;
|
|
75164
75322
|
middlewareData = {
|
|
75165
75323
|
...middlewareData,
|
|
@@ -75182,7 +75340,7 @@ const computePosition$1 = async (reference2, floating, config2) => {
|
|
|
75182
75340
|
}) : reset.rects;
|
|
75183
75341
|
}
|
|
75184
75342
|
({
|
|
75185
|
-
x,
|
|
75343
|
+
x: x2,
|
|
75186
75344
|
y: y2
|
|
75187
75345
|
} = computeCoordsFromPlacement(rects, statefulPlacement, rtl));
|
|
75188
75346
|
}
|
|
@@ -75190,7 +75348,7 @@ const computePosition$1 = async (reference2, floating, config2) => {
|
|
|
75190
75348
|
}
|
|
75191
75349
|
}
|
|
75192
75350
|
return {
|
|
75193
|
-
x,
|
|
75351
|
+
x: x2,
|
|
75194
75352
|
y: y2,
|
|
75195
75353
|
placement: statefulPlacement,
|
|
75196
75354
|
strategy,
|
|
@@ -75203,7 +75361,7 @@ async function detectOverflow(state2, options) {
|
|
|
75203
75361
|
options = {};
|
|
75204
75362
|
}
|
|
75205
75363
|
const {
|
|
75206
|
-
x,
|
|
75364
|
+
x: x2,
|
|
75207
75365
|
y: y2,
|
|
75208
75366
|
platform: platform2,
|
|
75209
75367
|
rects,
|
|
@@ -75227,7 +75385,7 @@ async function detectOverflow(state2, options) {
|
|
|
75227
75385
|
strategy
|
|
75228
75386
|
}));
|
|
75229
75387
|
const rect = elementContext === "floating" ? {
|
|
75230
|
-
x,
|
|
75388
|
+
x: x2,
|
|
75231
75389
|
y: y2,
|
|
75232
75390
|
width: rects.floating.width,
|
|
75233
75391
|
height: rects.floating.height
|
|
@@ -75496,16 +75654,16 @@ function getScale(element) {
|
|
|
75496
75654
|
height,
|
|
75497
75655
|
$: $2
|
|
75498
75656
|
} = getCssDimensions(domElement);
|
|
75499
|
-
let
|
|
75657
|
+
let x2 = ($2 ? round(rect.width) : rect.width) / width;
|
|
75500
75658
|
let y2 = ($2 ? round(rect.height) : rect.height) / height;
|
|
75501
|
-
if (!
|
|
75502
|
-
|
|
75659
|
+
if (!x2 || !Number.isFinite(x2)) {
|
|
75660
|
+
x2 = 1;
|
|
75503
75661
|
}
|
|
75504
75662
|
if (!y2 || !Number.isFinite(y2)) {
|
|
75505
75663
|
y2 = 1;
|
|
75506
75664
|
}
|
|
75507
75665
|
return {
|
|
75508
|
-
x,
|
|
75666
|
+
x: x2,
|
|
75509
75667
|
y: y2
|
|
75510
75668
|
};
|
|
75511
75669
|
}
|
|
@@ -75549,7 +75707,7 @@ function getBoundingClientRect(element, includeScale, isFixedStrategy, offsetPar
|
|
|
75549
75707
|
}
|
|
75550
75708
|
}
|
|
75551
75709
|
const visualOffsets = shouldAddVisualOffsets(domElement, isFixedStrategy, offsetParent) ? getVisualOffsets(domElement) : createCoords(0);
|
|
75552
|
-
let
|
|
75710
|
+
let x2 = (clientRect2.left + visualOffsets.x) / scale.x;
|
|
75553
75711
|
let y2 = (clientRect2.top + visualOffsets.y) / scale.y;
|
|
75554
75712
|
let width = clientRect2.width / scale.x;
|
|
75555
75713
|
let height = clientRect2.height / scale.y;
|
|
@@ -75564,11 +75722,11 @@ function getBoundingClientRect(element, includeScale, isFixedStrategy, offsetPar
|
|
|
75564
75722
|
const css = getComputedStyle$1(currentIFrame);
|
|
75565
75723
|
const left2 = iframeRect.left + (currentIFrame.clientLeft + parseFloat(css.paddingLeft)) * iframeScale.x;
|
|
75566
75724
|
const top2 = iframeRect.top + (currentIFrame.clientTop + parseFloat(css.paddingTop)) * iframeScale.y;
|
|
75567
|
-
|
|
75725
|
+
x2 *= iframeScale.x;
|
|
75568
75726
|
y2 *= iframeScale.y;
|
|
75569
75727
|
width *= iframeScale.x;
|
|
75570
75728
|
height *= iframeScale.y;
|
|
75571
|
-
|
|
75729
|
+
x2 += left2;
|
|
75572
75730
|
y2 += top2;
|
|
75573
75731
|
currentWin = getWindow(currentIFrame);
|
|
75574
75732
|
currentIFrame = getFrameElement(currentWin);
|
|
@@ -75577,7 +75735,7 @@ function getBoundingClientRect(element, includeScale, isFixedStrategy, offsetPar
|
|
|
75577
75735
|
return rectToClientRect({
|
|
75578
75736
|
width,
|
|
75579
75737
|
height,
|
|
75580
|
-
x,
|
|
75738
|
+
x: x2,
|
|
75581
75739
|
y: y2
|
|
75582
75740
|
});
|
|
75583
75741
|
}
|
|
@@ -75590,10 +75748,10 @@ function getWindowScrollBarX(element, rect) {
|
|
|
75590
75748
|
}
|
|
75591
75749
|
function getHTMLOffset(documentElement, scroll) {
|
|
75592
75750
|
const htmlRect = documentElement.getBoundingClientRect();
|
|
75593
|
-
const
|
|
75751
|
+
const x2 = htmlRect.left + scroll.scrollLeft - getWindowScrollBarX(documentElement, htmlRect);
|
|
75594
75752
|
const y2 = htmlRect.top + scroll.scrollTop;
|
|
75595
75753
|
return {
|
|
75596
|
-
x,
|
|
75754
|
+
x: x2,
|
|
75597
75755
|
y: y2
|
|
75598
75756
|
};
|
|
75599
75757
|
}
|
|
@@ -75645,15 +75803,15 @@ function getDocumentRect(element) {
|
|
|
75645
75803
|
const body = element.ownerDocument.body;
|
|
75646
75804
|
const width = max(html.scrollWidth, html.clientWidth, body.scrollWidth, body.clientWidth);
|
|
75647
75805
|
const height = max(html.scrollHeight, html.clientHeight, body.scrollHeight, body.clientHeight);
|
|
75648
|
-
let
|
|
75806
|
+
let x2 = -scroll.scrollLeft + getWindowScrollBarX(element);
|
|
75649
75807
|
const y2 = -scroll.scrollTop;
|
|
75650
75808
|
if (getComputedStyle$1(body).direction === "rtl") {
|
|
75651
|
-
|
|
75809
|
+
x2 += max(html.clientWidth, body.clientWidth) - width;
|
|
75652
75810
|
}
|
|
75653
75811
|
return {
|
|
75654
75812
|
width,
|
|
75655
75813
|
height,
|
|
75656
|
-
x,
|
|
75814
|
+
x: x2,
|
|
75657
75815
|
y: y2
|
|
75658
75816
|
};
|
|
75659
75817
|
}
|
|
@@ -75664,14 +75822,14 @@ function getViewportRect(element, strategy) {
|
|
|
75664
75822
|
const visualViewport = win.visualViewport;
|
|
75665
75823
|
let width = html.clientWidth;
|
|
75666
75824
|
let height = html.clientHeight;
|
|
75667
|
-
let
|
|
75825
|
+
let x2 = 0;
|
|
75668
75826
|
let y2 = 0;
|
|
75669
75827
|
if (visualViewport) {
|
|
75670
75828
|
width = visualViewport.width;
|
|
75671
75829
|
height = visualViewport.height;
|
|
75672
75830
|
const visualViewportBased = isWebKit();
|
|
75673
75831
|
if (!visualViewportBased || visualViewportBased && strategy === "fixed") {
|
|
75674
|
-
|
|
75832
|
+
x2 = visualViewport.offsetLeft;
|
|
75675
75833
|
y2 = visualViewport.offsetTop;
|
|
75676
75834
|
}
|
|
75677
75835
|
}
|
|
@@ -75691,7 +75849,7 @@ function getViewportRect(element, strategy) {
|
|
|
75691
75849
|
return {
|
|
75692
75850
|
width,
|
|
75693
75851
|
height,
|
|
75694
|
-
x,
|
|
75852
|
+
x: x2,
|
|
75695
75853
|
y: y2
|
|
75696
75854
|
};
|
|
75697
75855
|
}
|
|
@@ -75703,12 +75861,12 @@ function getInnerBoundingClientRect(element, strategy) {
|
|
|
75703
75861
|
const scale = isHTMLElement$2(element) ? getScale(element) : createCoords(1);
|
|
75704
75862
|
const width = element.clientWidth * scale.x;
|
|
75705
75863
|
const height = element.clientHeight * scale.y;
|
|
75706
|
-
const
|
|
75864
|
+
const x2 = left2 * scale.x;
|
|
75707
75865
|
const y2 = top2 * scale.y;
|
|
75708
75866
|
return {
|
|
75709
75867
|
width,
|
|
75710
75868
|
height,
|
|
75711
|
-
x,
|
|
75869
|
+
x: x2,
|
|
75712
75870
|
y: y2
|
|
75713
75871
|
};
|
|
75714
75872
|
}
|
|
@@ -75828,10 +75986,10 @@ function getRectRelativeToOffsetParent(element, offsetParent, strategy) {
|
|
|
75828
75986
|
setLeftRTLScrollbarOffset();
|
|
75829
75987
|
}
|
|
75830
75988
|
const htmlOffset = documentElement && !isOffsetParentAnElement && !isFixed ? getHTMLOffset(documentElement, scroll) : createCoords(0);
|
|
75831
|
-
const
|
|
75989
|
+
const x2 = rect.left + scroll.scrollLeft - offsets.x - htmlOffset.x;
|
|
75832
75990
|
const y2 = rect.top + scroll.scrollTop - offsets.y - htmlOffset.y;
|
|
75833
75991
|
return {
|
|
75834
|
-
x,
|
|
75992
|
+
x: x2,
|
|
75835
75993
|
y: y2,
|
|
75836
75994
|
width: rect.width,
|
|
75837
75995
|
height: rect.height
|
|
@@ -76710,22 +76868,22 @@ function createFloatingSeparator(separator, editor) {
|
|
|
76710
76868
|
const rect = elements.reference.getBoundingClientRect();
|
|
76711
76869
|
const containerRect = editorElement.getBoundingClientRect();
|
|
76712
76870
|
const scaleFactor = getScaleFactor(editorElement);
|
|
76713
|
-
const
|
|
76871
|
+
const x2 = Math.round((rect.left - containerRect.left) / scaleFactor);
|
|
76714
76872
|
const y2 = Math.round((rect.top - containerRect.top) / scaleFactor);
|
|
76715
76873
|
const width = Math.round(rect.width / scaleFactor);
|
|
76716
76874
|
const height = Math.round(rect.height / scaleFactor);
|
|
76717
76875
|
return {
|
|
76718
|
-
x,
|
|
76876
|
+
x: x2,
|
|
76719
76877
|
y: y2,
|
|
76720
76878
|
data: { width, height }
|
|
76721
76879
|
};
|
|
76722
76880
|
}
|
|
76723
76881
|
}
|
|
76724
76882
|
]
|
|
76725
|
-
}).then(({ x, y: y2, middlewareData }) => {
|
|
76883
|
+
}).then(({ x: x2, y: y2, middlewareData }) => {
|
|
76726
76884
|
Object.assign(floatingSeparator.style, {
|
|
76727
76885
|
top: `${y2}px`,
|
|
76728
|
-
left: `${
|
|
76886
|
+
left: `${x2}px`,
|
|
76729
76887
|
width: `${middlewareData.copy.width}px`,
|
|
76730
76888
|
height: `${middlewareData.copy.height}px`,
|
|
76731
76889
|
visibility: middlewareData.hide?.referenceHidden ? "hidden" : "visible"
|
|
@@ -79784,14 +79942,14 @@ function ensureViewBoundingRect() {
|
|
|
79784
79942
|
}
|
|
79785
79943
|
return viewMeasurer.getBoundingClientRect();
|
|
79786
79944
|
}
|
|
79787
|
-
function getPointRect(
|
|
79945
|
+
function getPointRect(x2, y2) {
|
|
79788
79946
|
const viewRect = ensureViewBoundingRect();
|
|
79789
79947
|
return {
|
|
79790
79948
|
top: y2,
|
|
79791
|
-
left:
|
|
79949
|
+
left: x2,
|
|
79792
79950
|
height: 0,
|
|
79793
79951
|
width: 0,
|
|
79794
|
-
right: viewRect.width -
|
|
79952
|
+
right: viewRect.width - x2,
|
|
79795
79953
|
bottom: viewRect.height - y2
|
|
79796
79954
|
};
|
|
79797
79955
|
}
|
|
@@ -80197,7 +80355,7 @@ const LazyTeleport = defineComponent({
|
|
|
80197
80355
|
};
|
|
80198
80356
|
},
|
|
80199
80357
|
render() {
|
|
80200
|
-
return this.showTeleport ? this.disabled ? getSlot("lazy-teleport", this.$slots) : h
|
|
80358
|
+
return this.showTeleport ? this.disabled ? getSlot("lazy-teleport", this.$slots) : h(Teleport, {
|
|
80201
80359
|
disabled: this.disabled,
|
|
80202
80360
|
to: this.mergedTo
|
|
80203
80361
|
}, getSlot("lazy-teleport", this.$slots)) : null;
|
|
@@ -80629,8 +80787,8 @@ const VFollower = defineComponent({
|
|
|
80629
80787
|
if (follower === null)
|
|
80630
80788
|
return;
|
|
80631
80789
|
const target = VBinder.targetRef;
|
|
80632
|
-
const { x, y: y2, overlap } = props;
|
|
80633
|
-
const targetRect =
|
|
80790
|
+
const { x: x2, y: y2, overlap } = props;
|
|
80791
|
+
const targetRect = x2 !== void 0 && y2 !== void 0 ? getPointRect(x2, y2) : getRect(target);
|
|
80634
80792
|
follower.style.setProperty("--v-target-width", `${Math.round(targetRect.width)}px`);
|
|
80635
80793
|
follower.style.setProperty("--v-target-height", `${Math.round(targetRect.height)}px`);
|
|
80636
80794
|
const { width, minWidth, placement, internalShift, flip: flip2 } = props;
|
|
@@ -80725,18 +80883,18 @@ const VFollower = defineComponent({
|
|
|
80725
80883
|
};
|
|
80726
80884
|
},
|
|
80727
80885
|
render() {
|
|
80728
|
-
return h
|
|
80886
|
+
return h(LazyTeleport, {
|
|
80729
80887
|
show: this.show,
|
|
80730
80888
|
to: this.mergedTo,
|
|
80731
80889
|
disabled: this.teleportDisabled
|
|
80732
80890
|
}, {
|
|
80733
80891
|
default: () => {
|
|
80734
80892
|
var _a2, _b;
|
|
80735
|
-
const vNode = h
|
|
80893
|
+
const vNode = h("div", {
|
|
80736
80894
|
class: ["v-binder-follower-container", this.containerClass],
|
|
80737
80895
|
ref: "offsetContainerRef"
|
|
80738
80896
|
}, [
|
|
80739
|
-
h
|
|
80897
|
+
h("div", {
|
|
80740
80898
|
class: "v-binder-follower-content",
|
|
80741
80899
|
ref: "followerRef"
|
|
80742
80900
|
}, (_b = (_a2 = this.$slots).default) === null || _b === void 0 ? void 0 : _b.call(_a2))
|
|
@@ -80800,8 +80958,8 @@ var ResizeObserverSize = /* @__PURE__ */ (function() {
|
|
|
80800
80958
|
return ResizeObserverSize2;
|
|
80801
80959
|
})();
|
|
80802
80960
|
var DOMRectReadOnly = (function() {
|
|
80803
|
-
function DOMRectReadOnly2(
|
|
80804
|
-
this.x =
|
|
80961
|
+
function DOMRectReadOnly2(x2, y2, width, height) {
|
|
80962
|
+
this.x = x2;
|
|
80805
80963
|
this.y = y2;
|
|
80806
80964
|
this.width = width;
|
|
80807
80965
|
this.height = height;
|
|
@@ -80812,8 +80970,8 @@ var DOMRectReadOnly = (function() {
|
|
|
80812
80970
|
return freeze(this);
|
|
80813
80971
|
}
|
|
80814
80972
|
DOMRectReadOnly2.prototype.toJSON = function() {
|
|
80815
|
-
var _a2 = this,
|
|
80816
|
-
return { x, y: y2, top: top2, right: right2, bottom: bottom2, left: left2, width, height };
|
|
80973
|
+
var _a2 = this, x2 = _a2.x, y2 = _a2.y, top2 = _a2.top, right2 = _a2.right, bottom2 = _a2.bottom, left2 = _a2.left, width = _a2.width, height = _a2.height;
|
|
80974
|
+
return { x: x2, y: y2, top: top2, right: right2, bottom: bottom2, left: left2, width, height };
|
|
80817
80975
|
};
|
|
80818
80976
|
DOMRectReadOnly2.fromRect = function(rectangle) {
|
|
80819
80977
|
return new DOMRectReadOnly2(rectangle.x, rectangle.y, rectangle.width, rectangle.height);
|
|
@@ -81568,8 +81726,8 @@ const FocusTrap = defineComponent({
|
|
|
81568
81726
|
if (this.disabled)
|
|
81569
81727
|
return defaultSlot();
|
|
81570
81728
|
const { active, focusableStyle } = this;
|
|
81571
|
-
return h
|
|
81572
|
-
h
|
|
81729
|
+
return h(Fragment$1, null, [
|
|
81730
|
+
h("div", {
|
|
81573
81731
|
"aria-hidden": "true",
|
|
81574
81732
|
tabindex: active ? "0" : "-1",
|
|
81575
81733
|
ref: "focusableStartRef",
|
|
@@ -81577,7 +81735,7 @@ const FocusTrap = defineComponent({
|
|
|
81577
81735
|
onFocus: this.handleStartFocus
|
|
81578
81736
|
}),
|
|
81579
81737
|
defaultSlot(),
|
|
81580
|
-
h
|
|
81738
|
+
h("div", {
|
|
81581
81739
|
"aria-hidden": "true",
|
|
81582
81740
|
style: focusableStyle,
|
|
81583
81741
|
ref: "focusableEndRef",
|
|
@@ -83281,11 +83439,11 @@ useTheme.props = {
|
|
|
83281
83439
|
const ChevronRightIcon = defineComponent({
|
|
83282
83440
|
name: "ChevronRight",
|
|
83283
83441
|
render() {
|
|
83284
|
-
return h
|
|
83442
|
+
return h("svg", {
|
|
83285
83443
|
viewBox: "0 0 16 16",
|
|
83286
83444
|
fill: "none",
|
|
83287
83445
|
xmlns: "http://www.w3.org/2000/svg"
|
|
83288
|
-
}, h
|
|
83446
|
+
}, h("path", {
|
|
83289
83447
|
d: "M5.64645 3.14645C5.45118 3.34171 5.45118 3.65829 5.64645 3.85355L9.79289 8L5.64645 12.1464C5.45118 12.3417 5.45118 12.6583 5.64645 12.8536C5.84171 13.0488 6.15829 13.0488 6.35355 12.8536L10.8536 8.35355C11.0488 8.15829 11.0488 7.84171 10.8536 7.64645L6.35355 3.14645C6.15829 2.95118 5.84171 2.95118 5.64645 3.14645Z",
|
|
83290
83448
|
fill: "currentColor"
|
|
83291
83449
|
}));
|
|
@@ -84258,16 +84416,16 @@ const Scrollbar = defineComponent({
|
|
|
84258
84416
|
if (!this.scrollable) return (_a2 = $slots.default) === null || _a2 === void 0 ? void 0 : _a2.call($slots);
|
|
84259
84417
|
const triggerIsNone = this.trigger === "none";
|
|
84260
84418
|
const createYRail = (className, style2) => {
|
|
84261
|
-
return h
|
|
84419
|
+
return h("div", {
|
|
84262
84420
|
ref: "yRailRef",
|
|
84263
84421
|
class: [`${mergedClsPrefix}-scrollbar-rail`, `${mergedClsPrefix}-scrollbar-rail--vertical`, `${mergedClsPrefix}-scrollbar-rail--vertical--${yPlacement}`, className],
|
|
84264
84422
|
"data-scrollbar-rail": true,
|
|
84265
84423
|
style: [style2 || "", this.verticalRailStyle],
|
|
84266
84424
|
"aria-hidden": true
|
|
84267
|
-
}, h
|
|
84425
|
+
}, h(triggerIsNone ? Wrapper : Transition, triggerIsNone ? null : {
|
|
84268
84426
|
name: "fade-in-transition"
|
|
84269
84427
|
}, {
|
|
84270
|
-
default: () => this.needYBar && this.isShowYBar && !this.isIos ? h
|
|
84428
|
+
default: () => this.needYBar && this.isShowYBar && !this.isIos ? h("div", {
|
|
84271
84429
|
class: `${mergedClsPrefix}-scrollbar-rail__scrollbar`,
|
|
84272
84430
|
style: {
|
|
84273
84431
|
height: this.yBarSizePx,
|
|
@@ -84280,24 +84438,24 @@ const Scrollbar = defineComponent({
|
|
|
84280
84438
|
const createChildren = () => {
|
|
84281
84439
|
var _a22, _b;
|
|
84282
84440
|
(_a22 = this.onRender) === null || _a22 === void 0 ? void 0 : _a22.call(this);
|
|
84283
|
-
return h
|
|
84441
|
+
return h("div", mergeProps(this.$attrs, {
|
|
84284
84442
|
role: "none",
|
|
84285
84443
|
ref: "wrapperRef",
|
|
84286
84444
|
class: [`${mergedClsPrefix}-scrollbar`, this.themeClass, rtlEnabled && `${mergedClsPrefix}-scrollbar--rtl`],
|
|
84287
84445
|
style: this.cssVars,
|
|
84288
84446
|
onMouseenter: triggerDisplayManually ? void 0 : this.handleMouseEnterWrapper,
|
|
84289
84447
|
onMouseleave: triggerDisplayManually ? void 0 : this.handleMouseLeaveWrapper
|
|
84290
|
-
}), [this.container ? (_b = $slots.default) === null || _b === void 0 ? void 0 : _b.call($slots) : h
|
|
84448
|
+
}), [this.container ? (_b = $slots.default) === null || _b === void 0 ? void 0 : _b.call($slots) : h("div", {
|
|
84291
84449
|
role: "none",
|
|
84292
84450
|
ref: "containerRef",
|
|
84293
84451
|
class: [`${mergedClsPrefix}-scrollbar-container`, this.containerClass],
|
|
84294
84452
|
style: this.containerStyle,
|
|
84295
84453
|
onScroll: this.handleScroll,
|
|
84296
84454
|
onWheel: this.onWheel
|
|
84297
|
-
}, h
|
|
84455
|
+
}, h(VResizeObserver, {
|
|
84298
84456
|
onResize: this.handleContentResize
|
|
84299
84457
|
}, {
|
|
84300
|
-
default: () => h
|
|
84458
|
+
default: () => h("div", {
|
|
84301
84459
|
ref: "contentRef",
|
|
84302
84460
|
role: "none",
|
|
84303
84461
|
style: [{
|
|
@@ -84305,16 +84463,16 @@ const Scrollbar = defineComponent({
|
|
|
84305
84463
|
}, this.contentStyle],
|
|
84306
84464
|
class: [`${mergedClsPrefix}-scrollbar-content`, this.contentClass]
|
|
84307
84465
|
}, $slots)
|
|
84308
|
-
})), internalHoistYRail ? null : createYRail(void 0, void 0), xScrollable && h
|
|
84466
|
+
})), internalHoistYRail ? null : createYRail(void 0, void 0), xScrollable && h("div", {
|
|
84309
84467
|
ref: "xRailRef",
|
|
84310
84468
|
class: [`${mergedClsPrefix}-scrollbar-rail`, `${mergedClsPrefix}-scrollbar-rail--horizontal`, `${mergedClsPrefix}-scrollbar-rail--horizontal--${xPlacement}`],
|
|
84311
84469
|
style: this.horizontalRailStyle,
|
|
84312
84470
|
"data-scrollbar-rail": true,
|
|
84313
84471
|
"aria-hidden": true
|
|
84314
|
-
}, h
|
|
84472
|
+
}, h(triggerIsNone ? Wrapper : Transition, triggerIsNone ? null : {
|
|
84315
84473
|
name: "fade-in-transition"
|
|
84316
84474
|
}, {
|
|
84317
|
-
default: () => this.needXBar && this.isShowXBar && !this.isIos ? h
|
|
84475
|
+
default: () => this.needXBar && this.isShowXBar && !this.isIos ? h("div", {
|
|
84318
84476
|
class: `${mergedClsPrefix}-scrollbar-rail__scrollbar`,
|
|
84319
84477
|
style: {
|
|
84320
84478
|
width: this.xBarSizePx,
|
|
@@ -84325,13 +84483,13 @@ const Scrollbar = defineComponent({
|
|
|
84325
84483
|
}) : null
|
|
84326
84484
|
}))]);
|
|
84327
84485
|
};
|
|
84328
|
-
const scrollbarNode = this.container ? createChildren() : h
|
|
84486
|
+
const scrollbarNode = this.container ? createChildren() : h(VResizeObserver, {
|
|
84329
84487
|
onResize: this.handleContainerResize
|
|
84330
84488
|
}, {
|
|
84331
84489
|
default: createChildren
|
|
84332
84490
|
});
|
|
84333
84491
|
if (internalHoistYRail) {
|
|
84334
|
-
return h
|
|
84492
|
+
return h(Fragment$1, null, scrollbarNode, createYRail(this.themeClass, this.cssVars));
|
|
84335
84493
|
} else {
|
|
84336
84494
|
return scrollbarNode;
|
|
84337
84495
|
}
|
|
@@ -85221,11 +85379,11 @@ function renderArrow({
|
|
|
85221
85379
|
arrowWrapperStyle,
|
|
85222
85380
|
clsPrefix
|
|
85223
85381
|
}) {
|
|
85224
|
-
return h
|
|
85382
|
+
return h("div", {
|
|
85225
85383
|
key: "__popover-arrow__",
|
|
85226
85384
|
style: arrowWrapperStyle,
|
|
85227
85385
|
class: [`${clsPrefix}-popover-arrow-wrapper`, arrowWrapperClass]
|
|
85228
|
-
}, h
|
|
85386
|
+
}, h("div", {
|
|
85229
85387
|
class: [`${clsPrefix}-popover-arrow`, arrowClass],
|
|
85230
85388
|
style: arrowStyle
|
|
85231
85389
|
}));
|
|
@@ -85423,26 +85581,26 @@ const NPopoverBody = defineComponent({
|
|
|
85423
85581
|
const hasHeaderOrFooter = !isSlotEmpty(slots.header) || !isSlotEmpty(slots.footer);
|
|
85424
85582
|
const renderContentInnerNode = () => {
|
|
85425
85583
|
var _a2, _b;
|
|
85426
|
-
const body = hasHeaderOrFooter ? h
|
|
85427
|
-
return children ? h
|
|
85584
|
+
const body = hasHeaderOrFooter ? h(Fragment$1, null, resolveWrappedSlot(slots.header, (children) => {
|
|
85585
|
+
return children ? h("div", {
|
|
85428
85586
|
class: [`${mergedClsPrefix}-popover__header`, props.headerClass],
|
|
85429
85587
|
style: props.headerStyle
|
|
85430
85588
|
}, children) : null;
|
|
85431
85589
|
}), resolveWrappedSlot(slots.default, (children) => {
|
|
85432
|
-
return children ? h
|
|
85590
|
+
return children ? h("div", {
|
|
85433
85591
|
class: [`${mergedClsPrefix}-popover__content`, props.contentClass],
|
|
85434
85592
|
style: props.contentStyle
|
|
85435
85593
|
}, slots) : null;
|
|
85436
85594
|
}), resolveWrappedSlot(slots.footer, (children) => {
|
|
85437
|
-
return children ? h
|
|
85595
|
+
return children ? h("div", {
|
|
85438
85596
|
class: [`${mergedClsPrefix}-popover__footer`, props.footerClass],
|
|
85439
85597
|
style: props.footerStyle
|
|
85440
85598
|
}, children) : null;
|
|
85441
|
-
})) : props.scrollable ? (_a2 = slots.default) === null || _a2 === void 0 ? void 0 : _a2.call(slots) : h
|
|
85599
|
+
})) : props.scrollable ? (_a2 = slots.default) === null || _a2 === void 0 ? void 0 : _a2.call(slots) : h("div", {
|
|
85442
85600
|
class: [`${mergedClsPrefix}-popover__content`, props.contentClass],
|
|
85443
85601
|
style: props.contentStyle
|
|
85444
85602
|
}, slots);
|
|
85445
|
-
const maybeScrollableBody = props.scrollable ? h
|
|
85603
|
+
const maybeScrollableBody = props.scrollable ? h(XScrollbar, {
|
|
85446
85604
|
themeOverrides: themeRef.value.peerOverrides.Scrollbar,
|
|
85447
85605
|
theme: themeRef.value.peers.Scrollbar,
|
|
85448
85606
|
contentClass: hasHeaderOrFooter ? void 0 : `${mergedClsPrefix}-popover__content ${(_b = props.contentClass) !== null && _b !== void 0 ? _b : ""}`,
|
|
@@ -85459,7 +85617,7 @@ const NPopoverBody = defineComponent({
|
|
|
85459
85617
|
}) : null;
|
|
85460
85618
|
return [maybeScrollableBody, arrow2];
|
|
85461
85619
|
};
|
|
85462
|
-
contentNode = h
|
|
85620
|
+
contentNode = h("div", mergeProps({
|
|
85463
85621
|
class: [`${mergedClsPrefix}-popover`, `${mergedClsPrefix}-popover-shared`, (rtlEnabledRef === null || rtlEnabledRef === void 0 ? void 0 : rtlEnabledRef.value) && `${mergedClsPrefix}-popover--rtl`, themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.themeClass.value, extraClass.map((v2) => `${mergedClsPrefix}-${v2}`), {
|
|
85464
85622
|
[`${mergedClsPrefix}-popover--scrollable`]: props.scrollable,
|
|
85465
85623
|
[`${mergedClsPrefix}-popover--show-header-or-footer`]: hasHeaderOrFooter,
|
|
@@ -85473,7 +85631,7 @@ const NPopoverBody = defineComponent({
|
|
|
85473
85631
|
onKeydown: NPopover2.handleKeydown,
|
|
85474
85632
|
onMouseenter: handleMouseEnter,
|
|
85475
85633
|
onMouseleave: handleMouseLeave2
|
|
85476
|
-
}, attrs), internalTrapFocus ? h
|
|
85634
|
+
}, attrs), internalTrapFocus ? h(FocusTrap, {
|
|
85477
85635
|
active: props.show,
|
|
85478
85636
|
autoFocus: true
|
|
85479
85637
|
}, {
|
|
@@ -85505,7 +85663,7 @@ const NPopoverBody = defineComponent({
|
|
|
85505
85663
|
};
|
|
85506
85664
|
},
|
|
85507
85665
|
render() {
|
|
85508
|
-
return h
|
|
85666
|
+
return h(VFollower, {
|
|
85509
85667
|
ref: "followerRef",
|
|
85510
85668
|
zIndex: this.zIndex,
|
|
85511
85669
|
show: this.show,
|
|
@@ -85521,7 +85679,7 @@ const NPopoverBody = defineComponent({
|
|
|
85521
85679
|
teleportDisabled: this.adjustedTo === useAdjustedTo.tdkey
|
|
85522
85680
|
}, {
|
|
85523
85681
|
default: () => {
|
|
85524
|
-
return this.animated ? h
|
|
85682
|
+
return this.animated ? h(Transition, {
|
|
85525
85683
|
name: "popover-transition",
|
|
85526
85684
|
appear: this.isMounted,
|
|
85527
85685
|
// Don't use watch to enable follower, since the transition may
|
|
@@ -85909,7 +86067,7 @@ const NPopover = defineComponent({
|
|
|
85909
86067
|
triggerVNode = getFirstSlotVNode(slots, "trigger");
|
|
85910
86068
|
if (triggerVNode) {
|
|
85911
86069
|
triggerVNode = cloneVNode(triggerVNode);
|
|
85912
|
-
triggerVNode = triggerVNode.type === Text$2 ? h
|
|
86070
|
+
triggerVNode = triggerVNode.type === Text$2 ? h("span", [triggerVNode]) : triggerVNode;
|
|
85913
86071
|
const handlers2 = {
|
|
85914
86072
|
onClick: this.handleClick,
|
|
85915
86073
|
onMouseenter: this.handleMouseEnter,
|
|
@@ -85967,7 +86125,7 @@ const NPopover = defineComponent({
|
|
|
85967
86125
|
}
|
|
85968
86126
|
}
|
|
85969
86127
|
}
|
|
85970
|
-
return h
|
|
86128
|
+
return h(Binder, {
|
|
85971
86129
|
ref: "binderInstRef",
|
|
85972
86130
|
syncTarget: !popoverInside,
|
|
85973
86131
|
syncTargetWithParent: this.internalSyncTargetWithParent
|
|
@@ -85975,7 +86133,7 @@ const NPopover = defineComponent({
|
|
|
85975
86133
|
default: () => {
|
|
85976
86134
|
void this.mergedShowConsideringDisabledProp;
|
|
85977
86135
|
const mergedShow = this.getMergedShow();
|
|
85978
|
-
return [this.internalTrapFocus && mergedShow ? withDirectives(h
|
|
86136
|
+
return [this.internalTrapFocus && mergedShow ? withDirectives(h("div", {
|
|
85979
86137
|
style: {
|
|
85980
86138
|
position: "fixed",
|
|
85981
86139
|
top: 0,
|
|
@@ -85986,9 +86144,9 @@ const NPopover = defineComponent({
|
|
|
85986
86144
|
}), [[zindexable, {
|
|
85987
86145
|
enabled: mergedShow,
|
|
85988
86146
|
zIndex: this.zIndex
|
|
85989
|
-
}]]) : null, positionManually ? null : h
|
|
86147
|
+
}]]) : null, positionManually ? null : h(VTarget, null, {
|
|
85990
86148
|
default: () => triggerVNode
|
|
85991
|
-
}), h
|
|
86149
|
+
}), h(NPopoverBody, keep(this.$props, bodyPropKeys, Object.assign(Object.assign({}, this.$attrs), {
|
|
85992
86150
|
showArrow: this.mergedShowArrow,
|
|
85993
86151
|
show: mergedShow
|
|
85994
86152
|
})), {
|
|
@@ -86156,7 +86314,7 @@ const NTooltip = defineComponent({
|
|
|
86156
86314
|
mergedTheme,
|
|
86157
86315
|
internalExtraClass
|
|
86158
86316
|
} = this;
|
|
86159
|
-
return h
|
|
86317
|
+
return h(NPopover, Object.assign(Object.assign({}, this.$props), {
|
|
86160
86318
|
theme: mergedTheme.peers.Popover,
|
|
86161
86319
|
themeOverrides: mergedTheme.peerOverrides.Popover,
|
|
86162
86320
|
builtinThemeOverrides: this.popoverThemeOverrides,
|
|
@@ -86177,7 +86335,7 @@ const NDropdownDivider = defineComponent({
|
|
|
86177
86335
|
}
|
|
86178
86336
|
},
|
|
86179
86337
|
render() {
|
|
86180
|
-
return h
|
|
86338
|
+
return h("div", {
|
|
86181
86339
|
class: `${this.clsPrefix}-dropdown-divider`
|
|
86182
86340
|
});
|
|
86183
86341
|
}
|
|
@@ -86227,17 +86385,17 @@ const NDropdownGroupHeader = defineComponent({
|
|
|
86227
86385
|
const {
|
|
86228
86386
|
rawNode
|
|
86229
86387
|
} = this.tmNode;
|
|
86230
|
-
const node = h
|
|
86388
|
+
const node = h("div", Object.assign({
|
|
86231
86389
|
class: `${clsPrefix}-dropdown-option`
|
|
86232
|
-
}, nodeProps === null || nodeProps === void 0 ? void 0 : nodeProps(rawNode)), h
|
|
86390
|
+
}, nodeProps === null || nodeProps === void 0 ? void 0 : nodeProps(rawNode)), h("div", {
|
|
86233
86391
|
class: `${clsPrefix}-dropdown-option-body ${clsPrefix}-dropdown-option-body--group`
|
|
86234
|
-
}, h
|
|
86392
|
+
}, h("div", {
|
|
86235
86393
|
"data-dropdown-option": true,
|
|
86236
86394
|
class: [`${clsPrefix}-dropdown-option-body__prefix`, showIcon && `${clsPrefix}-dropdown-option-body__prefix--show-icon`]
|
|
86237
|
-
}, render(rawNode.icon)), h
|
|
86395
|
+
}, render(rawNode.icon)), h("div", {
|
|
86238
86396
|
class: `${clsPrefix}-dropdown-option-body__label`,
|
|
86239
86397
|
"data-dropdown-option": true
|
|
86240
|
-
}, renderLabel ? renderLabel(rawNode) : render((_a2 = rawNode.title) !== null && _a2 !== void 0 ? _a2 : rawNode[this.labelField])), h
|
|
86398
|
+
}, renderLabel ? renderLabel(rawNode) : render((_a2 = rawNode.title) !== null && _a2 !== void 0 ? _a2 : rawNode[this.labelField])), h("div", {
|
|
86241
86399
|
class: [`${clsPrefix}-dropdown-option-body__suffix`, hasSubmenu && `${clsPrefix}-dropdown-option-body__suffix--has-submenu`],
|
|
86242
86400
|
"data-dropdown-option": true
|
|
86243
86401
|
})));
|
|
@@ -86367,14 +86525,14 @@ const NIcon = defineComponent({
|
|
|
86367
86525
|
warn("icon", "don't wrap `n-icon` inside `n-icon`");
|
|
86368
86526
|
}
|
|
86369
86527
|
onRender === null || onRender === void 0 ? void 0 : onRender();
|
|
86370
|
-
return h
|
|
86528
|
+
return h("i", mergeProps(this.$attrs, {
|
|
86371
86529
|
role: "img",
|
|
86372
86530
|
class: [`${mergedClsPrefix}-icon`, themeClass, {
|
|
86373
86531
|
[`${mergedClsPrefix}-icon--depth`]: depth,
|
|
86374
86532
|
[`${mergedClsPrefix}-icon--color-transition`]: depth !== void 0
|
|
86375
86533
|
}],
|
|
86376
86534
|
style: [this.cssVars, this.mergedStyle]
|
|
86377
|
-
}), component ? h
|
|
86535
|
+
}), component ? h(component) : this.$slots);
|
|
86378
86536
|
}
|
|
86379
86537
|
});
|
|
86380
86538
|
function isSubmenuNode(rawNode, childrenField) {
|
|
@@ -86610,7 +86768,7 @@ const NDropdownOption = defineComponent({
|
|
|
86610
86768
|
let submenuVNode = null;
|
|
86611
86769
|
if (mergedShowSubmenu) {
|
|
86612
86770
|
const submenuNodeProps = (_a2 = this.menuProps) === null || _a2 === void 0 ? void 0 : _a2.call(this, rawNode, rawNode.children);
|
|
86613
|
-
submenuVNode = h
|
|
86771
|
+
submenuVNode = h(NDropdownMenu, Object.assign({}, submenuNodeProps, {
|
|
86614
86772
|
clsPrefix,
|
|
86615
86773
|
scrollable: this.scrollable,
|
|
86616
86774
|
tmNodes: this.tmNode.children,
|
|
@@ -86625,33 +86783,33 @@ const NDropdownOption = defineComponent({
|
|
|
86625
86783
|
onClick: this.handleClick
|
|
86626
86784
|
};
|
|
86627
86785
|
const optionNodeProps = nodeProps === null || nodeProps === void 0 ? void 0 : nodeProps(rawNode);
|
|
86628
|
-
const node = h
|
|
86786
|
+
const node = h("div", Object.assign({
|
|
86629
86787
|
class: [`${clsPrefix}-dropdown-option`, optionNodeProps === null || optionNodeProps === void 0 ? void 0 : optionNodeProps.class],
|
|
86630
86788
|
"data-dropdown-option": true
|
|
86631
|
-
}, optionNodeProps), h
|
|
86789
|
+
}, optionNodeProps), h("div", mergeProps(builtinProps, props), [h("div", {
|
|
86632
86790
|
class: [`${clsPrefix}-dropdown-option-body__prefix`, siblingHasIcon && `${clsPrefix}-dropdown-option-body__prefix--show-icon`]
|
|
86633
|
-
}, [renderIcon ? renderIcon(rawNode) : render(rawNode.icon)]), h
|
|
86791
|
+
}, [renderIcon ? renderIcon(rawNode) : render(rawNode.icon)]), h("div", {
|
|
86634
86792
|
"data-dropdown-option": true,
|
|
86635
86793
|
class: `${clsPrefix}-dropdown-option-body__label`
|
|
86636
|
-
}, renderLabel ? renderLabel(rawNode) : render((_b = rawNode[this.labelField]) !== null && _b !== void 0 ? _b : rawNode.title)), h
|
|
86794
|
+
}, renderLabel ? renderLabel(rawNode) : render((_b = rawNode[this.labelField]) !== null && _b !== void 0 ? _b : rawNode.title)), h("div", {
|
|
86637
86795
|
"data-dropdown-option": true,
|
|
86638
86796
|
class: [`${clsPrefix}-dropdown-option-body__suffix`, siblingHasSubmenu && `${clsPrefix}-dropdown-option-body__suffix--has-submenu`]
|
|
86639
|
-
}, this.hasSubmenu ? h
|
|
86640
|
-
default: () => h
|
|
86641
|
-
}) : null)]), this.hasSubmenu ? h
|
|
86642
|
-
default: () => [h
|
|
86643
|
-
default: () => h
|
|
86797
|
+
}, this.hasSubmenu ? h(NIcon, null, {
|
|
86798
|
+
default: () => h(ChevronRightIcon, null)
|
|
86799
|
+
}) : null)]), this.hasSubmenu ? h(Binder, null, {
|
|
86800
|
+
default: () => [h(VTarget, null, {
|
|
86801
|
+
default: () => h("div", {
|
|
86644
86802
|
class: `${clsPrefix}-dropdown-offset-container`
|
|
86645
|
-
}, h
|
|
86803
|
+
}, h(VFollower, {
|
|
86646
86804
|
show: this.mergedShowSubmenu,
|
|
86647
86805
|
placement: this.placement,
|
|
86648
86806
|
to: scrollable ? this.popoverBody || void 0 : void 0,
|
|
86649
86807
|
teleportDisabled: !scrollable
|
|
86650
86808
|
}, {
|
|
86651
86809
|
default: () => {
|
|
86652
|
-
return h
|
|
86810
|
+
return h("div", {
|
|
86653
86811
|
class: `${clsPrefix}-dropdown-menu-wrapper`
|
|
86654
|
-
}, animated ? h
|
|
86812
|
+
}, animated ? h(Transition, {
|
|
86655
86813
|
onBeforeEnter: this.handleSubmenuBeforeEnter,
|
|
86656
86814
|
onAfterEnter: this.handleSubmenuAfterEnter,
|
|
86657
86815
|
name: "fade-in-scale-up-transition",
|
|
@@ -86697,7 +86855,7 @@ const NDropdownGroup = defineComponent({
|
|
|
86697
86855
|
const {
|
|
86698
86856
|
children
|
|
86699
86857
|
} = tmNode;
|
|
86700
|
-
return h
|
|
86858
|
+
return h(Fragment$1, null, h(NDropdownGroupHeader, {
|
|
86701
86859
|
clsPrefix,
|
|
86702
86860
|
tmNode,
|
|
86703
86861
|
key: tmNode.key
|
|
@@ -86707,7 +86865,7 @@ const NDropdownGroup = defineComponent({
|
|
|
86707
86865
|
} = child;
|
|
86708
86866
|
if (rawNode.show === false) return null;
|
|
86709
86867
|
if (isDividerNode(rawNode)) {
|
|
86710
|
-
return h
|
|
86868
|
+
return h(NDropdownDivider, {
|
|
86711
86869
|
clsPrefix,
|
|
86712
86870
|
key: child.key
|
|
86713
86871
|
});
|
|
@@ -86716,7 +86874,7 @@ const NDropdownGroup = defineComponent({
|
|
|
86716
86874
|
warn("dropdown", "`group` node is not allowed to be put in `group` node.");
|
|
86717
86875
|
return null;
|
|
86718
86876
|
}
|
|
86719
|
-
return h
|
|
86877
|
+
return h(NDropdownOption, {
|
|
86720
86878
|
clsPrefix,
|
|
86721
86879
|
tmNode: child,
|
|
86722
86880
|
parentKey,
|
|
@@ -86740,7 +86898,7 @@ const NDropdownRenderOption = defineComponent({
|
|
|
86740
86898
|
props
|
|
86741
86899
|
}
|
|
86742
86900
|
} = this.tmNode;
|
|
86743
|
-
return h
|
|
86901
|
+
return h("div", props, [render2 === null || render2 === void 0 ? void 0 : render2()]);
|
|
86744
86902
|
}
|
|
86745
86903
|
});
|
|
86746
86904
|
const NDropdownMenu = defineComponent({
|
|
@@ -86821,26 +86979,26 @@ const NDropdownMenu = defineComponent({
|
|
|
86821
86979
|
} = tmNode;
|
|
86822
86980
|
if (rawNode.show === false) return null;
|
|
86823
86981
|
if (isRenderNode(rawNode)) {
|
|
86824
|
-
return h
|
|
86982
|
+
return h(NDropdownRenderOption, {
|
|
86825
86983
|
tmNode,
|
|
86826
86984
|
key: tmNode.key
|
|
86827
86985
|
});
|
|
86828
86986
|
}
|
|
86829
86987
|
if (isDividerNode(rawNode)) {
|
|
86830
|
-
return h
|
|
86988
|
+
return h(NDropdownDivider, {
|
|
86831
86989
|
clsPrefix,
|
|
86832
86990
|
key: tmNode.key
|
|
86833
86991
|
});
|
|
86834
86992
|
}
|
|
86835
86993
|
if (isGroupNode(rawNode)) {
|
|
86836
|
-
return h
|
|
86994
|
+
return h(NDropdownGroup, {
|
|
86837
86995
|
clsPrefix,
|
|
86838
86996
|
tmNode,
|
|
86839
86997
|
parentKey,
|
|
86840
86998
|
key: tmNode.key
|
|
86841
86999
|
});
|
|
86842
87000
|
}
|
|
86843
|
-
return h
|
|
87001
|
+
return h(NDropdownOption, {
|
|
86844
87002
|
clsPrefix,
|
|
86845
87003
|
tmNode,
|
|
86846
87004
|
parentKey,
|
|
@@ -86849,10 +87007,10 @@ const NDropdownMenu = defineComponent({
|
|
|
86849
87007
|
scrollable
|
|
86850
87008
|
});
|
|
86851
87009
|
});
|
|
86852
|
-
return h
|
|
87010
|
+
return h("div", {
|
|
86853
87011
|
class: [`${clsPrefix}-dropdown-menu`, scrollable && `${clsPrefix}-dropdown-menu--scrollable`],
|
|
86854
87012
|
ref: "bodyRef"
|
|
86855
|
-
}, scrollable ? h
|
|
87013
|
+
}, scrollable ? h(XScrollbar, {
|
|
86856
87014
|
contentClass: `${clsPrefix}-dropdown-menu__content`
|
|
86857
87015
|
}, {
|
|
86858
87016
|
default: () => menuOptionsNode
|
|
@@ -87320,7 +87478,7 @@ const NDropdown = defineComponent({
|
|
|
87320
87478
|
onMouseenter,
|
|
87321
87479
|
onMouseleave
|
|
87322
87480
|
};
|
|
87323
|
-
return h
|
|
87481
|
+
return h(NDropdownMenu, mergeProps(this.$attrs, dropdownProps2, menuNodeProps));
|
|
87324
87482
|
};
|
|
87325
87483
|
const {
|
|
87326
87484
|
mergedTheme
|
|
@@ -87334,7 +87492,7 @@ const NDropdown = defineComponent({
|
|
|
87334
87492
|
onUpdateShow: this.doUpdateShow,
|
|
87335
87493
|
"onUpdate:show": void 0
|
|
87336
87494
|
};
|
|
87337
|
-
return h
|
|
87495
|
+
return h(NPopover, Object.assign({}, keep(this.$props, popoverPropKeys), popoverProps2), {
|
|
87338
87496
|
trigger: () => {
|
|
87339
87497
|
var _a2, _b;
|
|
87340
87498
|
return (_b = (_a2 = this.$slots).default) === null || _b === void 0 ? void 0 : _b.call(_a2);
|
|
@@ -87476,12 +87634,12 @@ const NSkeleton = defineComponent({
|
|
|
87476
87634
|
mergedClsPrefix,
|
|
87477
87635
|
$attrs
|
|
87478
87636
|
} = this;
|
|
87479
|
-
const child = h
|
|
87637
|
+
const child = h("div", mergeProps({
|
|
87480
87638
|
class: `${mergedClsPrefix}-skeleton`,
|
|
87481
87639
|
style: style2
|
|
87482
87640
|
}, $attrs));
|
|
87483
87641
|
if (repeatProp > 1) {
|
|
87484
|
-
return h
|
|
87642
|
+
return h(Fragment$1, null, repeat(repeatProp, null).map((_2) => [child, "\n"]));
|
|
87485
87643
|
}
|
|
87486
87644
|
return child;
|
|
87487
87645
|
}
|
|
@@ -89395,8 +89553,8 @@ const renderColorOptions = (superToolbar, button, customIcons = [], hasNoneIcon
|
|
|
89395
89553
|
superToolbar.emitCommand({ item: button, argument: e });
|
|
89396
89554
|
closeDropdown$1(button);
|
|
89397
89555
|
};
|
|
89398
|
-
return h
|
|
89399
|
-
h
|
|
89556
|
+
return h("div", {}, [
|
|
89557
|
+
h(IconGrid, {
|
|
89400
89558
|
icons,
|
|
89401
89559
|
customIcons,
|
|
89402
89560
|
activeColor: button.iconColor,
|
|
@@ -89868,8 +90026,8 @@ const makeDefaultItems = ({
|
|
|
89868
90026
|
const handleClose = () => {
|
|
89869
90027
|
closeDropdown(aiButton);
|
|
89870
90028
|
};
|
|
89871
|
-
return h
|
|
89872
|
-
h
|
|
90029
|
+
return h("div", {}, [
|
|
90030
|
+
h(AIWriter, {
|
|
89873
90031
|
handleClose,
|
|
89874
90032
|
selectedText,
|
|
89875
90033
|
editor: superToolbar.activeEditor,
|
|
@@ -90045,8 +90203,8 @@ const makeDefaultItems = ({
|
|
|
90045
90203
|
const handleSubmit = ({ value }) => {
|
|
90046
90204
|
superToolbar.activeEditor.commands.search(value);
|
|
90047
90205
|
};
|
|
90048
|
-
return h
|
|
90049
|
-
h
|
|
90206
|
+
return h("div", {}, [
|
|
90207
|
+
h(SearchInput, {
|
|
90050
90208
|
onSubmit: handleSubmit,
|
|
90051
90209
|
searchRef
|
|
90052
90210
|
})
|
|
@@ -90078,8 +90236,8 @@ const makeDefaultItems = ({
|
|
|
90078
90236
|
}
|
|
90079
90237
|
});
|
|
90080
90238
|
function renderLinkDropdown(link2) {
|
|
90081
|
-
return h
|
|
90082
|
-
h
|
|
90239
|
+
return h("div", {}, [
|
|
90240
|
+
h(LinkInput, {
|
|
90083
90241
|
editor: superToolbar.activeEditor,
|
|
90084
90242
|
closePopover: () => closeDropdown(link2),
|
|
90085
90243
|
goToAnchor: () => {
|
|
@@ -90136,8 +90294,8 @@ const makeDefaultItems = ({
|
|
|
90136
90294
|
superToolbar.emitCommand({ item: tableItem2, argument: e });
|
|
90137
90295
|
closeDropdown(tableItem2);
|
|
90138
90296
|
};
|
|
90139
|
-
return h
|
|
90140
|
-
h
|
|
90297
|
+
return h("div", {}, [
|
|
90298
|
+
h(TableGrid, {
|
|
90141
90299
|
onSelect: handleSelect
|
|
90142
90300
|
})
|
|
90143
90301
|
]);
|
|
@@ -90264,7 +90422,7 @@ const makeDefaultItems = ({
|
|
|
90264
90422
|
}
|
|
90265
90423
|
];
|
|
90266
90424
|
function renderTableActions(tableActionsItem2) {
|
|
90267
|
-
return h
|
|
90425
|
+
return h(TableActions, {
|
|
90268
90426
|
options: tableActionsOptions2,
|
|
90269
90427
|
onSelect: (event) => {
|
|
90270
90428
|
closeDropdown(tableActionsItem2);
|
|
@@ -90297,8 +90455,8 @@ const makeDefaultItems = ({
|
|
|
90297
90455
|
superToolbar.emitCommand({ item: buttonWithCommand, argument: e });
|
|
90298
90456
|
setAlignmentIcon(alignment2, e);
|
|
90299
90457
|
};
|
|
90300
|
-
return h
|
|
90301
|
-
h
|
|
90458
|
+
return h("div", {}, [
|
|
90459
|
+
h(AlignmentButtons, {
|
|
90302
90460
|
onSelect: handleSelect
|
|
90303
90461
|
})
|
|
90304
90462
|
]);
|
|
@@ -90574,7 +90732,7 @@ const makeDefaultItems = ({
|
|
|
90574
90732
|
];
|
|
90575
90733
|
function renderDocumentMode(renderDocumentButton) {
|
|
90576
90734
|
const optionsAfterRole = getDocumentOptionsAfterRole(role, documentOptions);
|
|
90577
|
-
return h
|
|
90735
|
+
return h(DocumentMode, {
|
|
90578
90736
|
options: optionsAfterRole,
|
|
90579
90737
|
onSelect: (item) => {
|
|
90580
90738
|
closeDropdown(renderDocumentButton);
|
|
@@ -90645,8 +90803,8 @@ const makeDefaultItems = ({
|
|
|
90645
90803
|
superToolbar.emitCommand({ item: itemWithCommand, argument: style2 });
|
|
90646
90804
|
selectedLinkedStyle.value = style2.id;
|
|
90647
90805
|
};
|
|
90648
|
-
return h
|
|
90649
|
-
h
|
|
90806
|
+
return h("div", {}, [
|
|
90807
|
+
h(LinkedStyle, {
|
|
90650
90808
|
editor: superToolbar.activeEditor,
|
|
90651
90809
|
onSelect: handleSelect,
|
|
90652
90810
|
selectedOption: selectedLinkedStyle.value
|
|
@@ -90668,7 +90826,7 @@ const makeDefaultItems = ({
|
|
|
90668
90826
|
});
|
|
90669
90827
|
const renderIcon = (value, selectedValue) => {
|
|
90670
90828
|
if (selectedValue.value.toString() !== value) return;
|
|
90671
|
-
return h
|
|
90829
|
+
return h("div", { innerHTML: checkIconSvg, class: "dropdown-select-icon" });
|
|
90672
90830
|
};
|
|
90673
90831
|
const lineHeight2 = useToolbarItem({
|
|
90674
90832
|
type: "dropdown",
|