@langsword/trace 0.1.30 → 0.1.31
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/trace.css +1 -1
- package/dist/trace.es.js +752 -750
- package/dist/trace.umd.js +29 -29
- package/package.json +1 -1
package/dist/trace.es.js
CHANGED
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
var
|
|
1
|
+
var nh = Object.defineProperty;
|
|
2
2
|
var uu = (o) => {
|
|
3
3
|
throw TypeError(o);
|
|
4
4
|
};
|
|
5
|
-
var
|
|
6
|
-
var Qe = (o, t, r) =>
|
|
5
|
+
var rh = (o, t, r) => t in o ? nh(o, t, { enumerable: !0, configurable: !0, writable: !0, value: r }) : o[t] = r;
|
|
6
|
+
var Qe = (o, t, r) => rh(o, typeof t != "symbol" ? t + "" : t, r), ih = (o, t, r) => t.has(o) || uu("Cannot " + r);
|
|
7
7
|
var cu = (o, t, r) => t.has(o) ? uu("Cannot add the same private member more than once") : t instanceof WeakSet ? t.add(o) : t.set(o, r);
|
|
8
|
-
var ga = (o, t, r) => (
|
|
9
|
-
import { defineStore as
|
|
10
|
-
import
|
|
11
|
-
import
|
|
12
|
-
var
|
|
13
|
-
function
|
|
8
|
+
var ga = (o, t, r) => (ih(o, t, "access private method"), r);
|
|
9
|
+
import { defineStore as ah } from "pinia";
|
|
10
|
+
import sh from "axios";
|
|
11
|
+
import oh from "vue";
|
|
12
|
+
var fc = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
|
|
13
|
+
function lh(o) {
|
|
14
14
|
return o && o.__esModule && Object.prototype.hasOwnProperty.call(o, "default") ? o.default : o;
|
|
15
15
|
}
|
|
16
|
-
function
|
|
16
|
+
function uh(o) {
|
|
17
17
|
if (o.__esModule) return o;
|
|
18
18
|
var t = o.default;
|
|
19
19
|
if (typeof t == "function") {
|
|
@@ -37,7 +37,7 @@ function Vt() {
|
|
|
37
37
|
return fu || (fu = 1, function(o, t) {
|
|
38
38
|
(function(r, l) {
|
|
39
39
|
o.exports = l();
|
|
40
|
-
})(
|
|
40
|
+
})(fc, function() {
|
|
41
41
|
var r = navigator.userAgent, l = navigator.platform, u = /gecko\/\d/i.test(r), f = /MSIE \d/.test(r), h = /Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(r), v = /Edge\/(\d+)/.exec(r), m = f || h || v, x = m && (f ? document.documentMode || 6 : +(v || h)[1]), S = !v && /WebKit\//.test(r), R = S && /Qt\/\d+\.\d+/.test(r), L = !v && /Chrome\/(\d+)/.exec(r), W = L && +L[1], z = /Opera\//.test(r), O = /Apple Computer/.test(navigator.vendor), M = /Mac OS X 1\d\D([8-9]|\d\d)\D/.test(r), A = /PhantomJS/.test(r), N = O && (/Mobile\/\w+/.test(r) || navigator.maxTouchPoints > 2), H = /Android/.test(r), V = N || H || /webOS|BlackBerry|Opera Mini|Opera Mobi|IEMobile/i.test(r), ne = N || /Mac/.test(l), ue = /\bCrOS\b/.test(r), se = /win/i.test(l), de = z && r.match(/Version\/(\d*\.\d*)/);
|
|
42
42
|
de && (de = Number(de[1])), de && de >= 15 && (z = !1, S = !0);
|
|
43
43
|
var Oe = ne && (R || z && (de == null || de < 12.11)), Re = u || m && x >= 9;
|
|
@@ -695,9 +695,9 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
695
695
|
if (n.line < e.first)
|
|
696
696
|
return P(e.first, 0);
|
|
697
697
|
var a = e.first + e.size - 1;
|
|
698
|
-
return n.line > a ? P(a, ce(e, a).text.length) :
|
|
698
|
+
return n.line > a ? P(a, ce(e, a).text.length) : nf(n, ce(e, n.line).text.length);
|
|
699
699
|
}
|
|
700
|
-
function
|
|
700
|
+
function nf(e, n) {
|
|
701
701
|
var a = e.ch;
|
|
702
702
|
return a == null || a > n ? P(e.line, n) : a < 0 ? P(e.line, 0) : e;
|
|
703
703
|
}
|
|
@@ -776,7 +776,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
776
776
|
var i = e.doc, s = e.display;
|
|
777
777
|
if (!i.mode.startState)
|
|
778
778
|
return new pn(i, !0, n);
|
|
779
|
-
var c =
|
|
779
|
+
var c = rf(e, n, a), d = c > i.first && ce(i, c - 1).stateAfter, p = d ? pn.fromSaved(i, d, c) : new pn(i, mr(i.mode), c);
|
|
780
780
|
return i.iter(c, n, function(g) {
|
|
781
781
|
za(e, g.text, p);
|
|
782
782
|
var y = p.line;
|
|
@@ -850,7 +850,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
850
850
|
s(B, y), g = B;
|
|
851
851
|
}
|
|
852
852
|
}
|
|
853
|
-
function
|
|
853
|
+
function rf(e, n, a) {
|
|
854
854
|
for (var i, s, c = e.doc, d = a ? -1 : n - (e.doc.mode.innerMode ? 1e3 : 100), p = n; p > d; --p) {
|
|
855
855
|
if (p <= c.first)
|
|
856
856
|
return c.first;
|
|
@@ -862,7 +862,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
862
862
|
}
|
|
863
863
|
return s;
|
|
864
864
|
}
|
|
865
|
-
function
|
|
865
|
+
function af(e, n) {
|
|
866
866
|
if (e.modeFrontier = Math.min(e.modeFrontier, n), !(e.highlightFrontier < n - 10)) {
|
|
867
867
|
for (var a = e.first, i = n - 1; i > a; i--) {
|
|
868
868
|
var s = ce(e, i).stateAfter;
|
|
@@ -875,10 +875,10 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
875
875
|
}
|
|
876
876
|
}
|
|
877
877
|
var bo = !1, kn = !1;
|
|
878
|
-
function
|
|
878
|
+
function sf() {
|
|
879
879
|
bo = !0;
|
|
880
880
|
}
|
|
881
|
-
function
|
|
881
|
+
function of() {
|
|
882
882
|
kn = !0;
|
|
883
883
|
}
|
|
884
884
|
function Bi(e, n, a) {
|
|
@@ -892,16 +892,16 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
892
892
|
return i;
|
|
893
893
|
}
|
|
894
894
|
}
|
|
895
|
-
function
|
|
895
|
+
function lf(e, n) {
|
|
896
896
|
for (var a, i = 0; i < e.length; ++i)
|
|
897
897
|
e[i] != n && (a || (a = [])).push(e[i]);
|
|
898
898
|
return a;
|
|
899
899
|
}
|
|
900
|
-
function
|
|
900
|
+
function uf(e, n, a) {
|
|
901
901
|
var i = a && window.WeakSet && (a.markedSpans || (a.markedSpans = /* @__PURE__ */ new WeakSet()));
|
|
902
902
|
i && e.markedSpans && i.has(e.markedSpans) ? e.markedSpans.push(n) : (e.markedSpans = e.markedSpans ? e.markedSpans.concat([n]) : [n], i && i.add(e.markedSpans)), n.marker.attachLine(e);
|
|
903
903
|
}
|
|
904
|
-
function
|
|
904
|
+
function cf(e, n, a) {
|
|
905
905
|
var i;
|
|
906
906
|
if (e)
|
|
907
907
|
for (var s = 0; s < e.length; ++s) {
|
|
@@ -913,7 +913,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
913
913
|
}
|
|
914
914
|
return i;
|
|
915
915
|
}
|
|
916
|
-
function
|
|
916
|
+
function ff(e, n, a) {
|
|
917
917
|
var i;
|
|
918
918
|
if (e)
|
|
919
919
|
for (var s = 0; s < e.length; ++s) {
|
|
@@ -935,7 +935,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
935
935
|
var a = q(e, n.from.line) && ce(e, n.from.line).markedSpans, i = q(e, n.to.line) && ce(e, n.to.line).markedSpans;
|
|
936
936
|
if (!a && !i)
|
|
937
937
|
return null;
|
|
938
|
-
var s = n.from.ch, c = n.to.ch, d = re(n.from, n.to) == 0, p =
|
|
938
|
+
var s = n.from.ch, c = n.to.ch, d = re(n.from, n.to) == 0, p = cf(a, s, d), g = ff(i, c, d), y = n.text.length == 1, C = be(n.text).length + (y ? s : 0);
|
|
939
939
|
if (p)
|
|
940
940
|
for (var _ = 0; _ < p.length; ++_) {
|
|
941
941
|
var F = p[_];
|
|
@@ -973,7 +973,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
973
973
|
}
|
|
974
974
|
return e.length ? e : null;
|
|
975
975
|
}
|
|
976
|
-
function
|
|
976
|
+
function df(e, n, a) {
|
|
977
977
|
var i = null;
|
|
978
978
|
if (e.iter(n.line, a.line + 1, function(D) {
|
|
979
979
|
if (D.markedSpans)
|
|
@@ -1037,7 +1037,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
1037
1037
|
function ji(e) {
|
|
1038
1038
|
return So(e, !1);
|
|
1039
1039
|
}
|
|
1040
|
-
function
|
|
1040
|
+
function hf(e, n) {
|
|
1041
1041
|
var a = kn && e.markedSpans, i;
|
|
1042
1042
|
if (a)
|
|
1043
1043
|
for (var s = 0; s < a.length; ++s) {
|
|
@@ -1063,12 +1063,12 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
1063
1063
|
e = n.find(-1, !0).line;
|
|
1064
1064
|
return e;
|
|
1065
1065
|
}
|
|
1066
|
-
function
|
|
1066
|
+
function pf(e) {
|
|
1067
1067
|
for (var n; n = ji(e); )
|
|
1068
1068
|
e = n.find(1, !0).line;
|
|
1069
1069
|
return e;
|
|
1070
1070
|
}
|
|
1071
|
-
function
|
|
1071
|
+
function gf(e) {
|
|
1072
1072
|
for (var n, a; n = ji(e); )
|
|
1073
1073
|
e = n.find(1, !0).line, (a || (a = [])).push(e);
|
|
1074
1074
|
return a;
|
|
@@ -1153,19 +1153,19 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
1153
1153
|
yr.prototype.lineNo = function() {
|
|
1154
1154
|
return b(this);
|
|
1155
1155
|
}, en(yr);
|
|
1156
|
-
function
|
|
1156
|
+
function mf(e, n, a, i) {
|
|
1157
1157
|
e.text = n, e.stateAfter && (e.stateAfter = null), e.styles && (e.styles = null), e.order != null && (e.order = null), wo(e), ko(e, a);
|
|
1158
1158
|
var s = i ? i(e) : 1;
|
|
1159
1159
|
s != e.height && qt(e, s);
|
|
1160
1160
|
}
|
|
1161
|
-
function
|
|
1161
|
+
function vf(e) {
|
|
1162
1162
|
e.parent = null, wo(e);
|
|
1163
1163
|
}
|
|
1164
|
-
var
|
|
1164
|
+
var yf = {}, bf = {};
|
|
1165
1165
|
function Lo(e, n) {
|
|
1166
1166
|
if (!e || /^\s*$/.test(e))
|
|
1167
1167
|
return null;
|
|
1168
|
-
var a = n.addModeClass ?
|
|
1168
|
+
var a = n.addModeClass ? bf : yf;
|
|
1169
1169
|
return a[e] || (a[e] = e.replace(/\S+/g, "cm-$&"));
|
|
1170
1170
|
}
|
|
1171
1171
|
function Eo(e, n) {
|
|
@@ -1181,9 +1181,9 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
1181
1181
|
n.measure = {};
|
|
1182
1182
|
for (var s = 0; s <= (n.rest ? n.rest.length : 0); s++) {
|
|
1183
1183
|
var c = s ? n.rest[s - 1] : n.line, d = void 0;
|
|
1184
|
-
i.pos = 0, i.addToken =
|
|
1184
|
+
i.pos = 0, i.addToken = wf, Nn(e.display.measure) && (d = $e(c, e.doc.direction)) && (i.addToken = Sf(i.addToken, d)), i.map = [];
|
|
1185
1185
|
var p = n != e.display.externalMeasured && b(c);
|
|
1186
|
-
|
|
1186
|
+
Cf(c, i, ho(e, c, p)), c.styleClasses && (c.styleClasses.bgClass && (i.bgClass = he(c.styleClasses.bgClass, i.bgClass || "")), c.styleClasses.textClass && (i.textClass = he(c.styleClasses.textClass, i.textClass || ""))), i.map.length == 0 && i.map.push(0, 0, i.content.appendChild(Mi(e.display.measure))), s == 0 ? (n.measure.map = i.map, n.measure.cache = {}) : ((n.measure.maps || (n.measure.maps = [])).push(i.map), (n.measure.caches || (n.measure.caches = [])).push({}));
|
|
1187
1187
|
}
|
|
1188
1188
|
if (S) {
|
|
1189
1189
|
var g = i.content.lastChild;
|
|
@@ -1191,13 +1191,13 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
1191
1191
|
}
|
|
1192
1192
|
return Ye(e, "renderLine", e, n.line, i.pre), i.pre.className && (i.textClass = he(i.pre.className, i.textClass || "")), i;
|
|
1193
1193
|
}
|
|
1194
|
-
function
|
|
1194
|
+
function xf(e) {
|
|
1195
1195
|
var n = k("span", "•", "cm-invalidchar");
|
|
1196
1196
|
return n.title = "\\u" + e.charCodeAt(0).toString(16), n.setAttribute("aria-label", n.title), n;
|
|
1197
1197
|
}
|
|
1198
|
-
function
|
|
1198
|
+
function wf(e, n, a, i, s, c, d) {
|
|
1199
1199
|
if (n) {
|
|
1200
|
-
var p = e.splitSpaces ?
|
|
1200
|
+
var p = e.splitSpaces ? kf(n, e.trailingSpace) : n, g = e.cm.state.specialChars, y = !1, C;
|
|
1201
1201
|
if (!g.test(n))
|
|
1202
1202
|
e.col += n.length, C = document.createTextNode(p), e.map.push(e.pos, e.pos + n.length, C), m && x < 9 && (y = !0), e.pos += n.length;
|
|
1203
1203
|
else {
|
|
@@ -1233,7 +1233,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
1233
1233
|
e.content.appendChild(C);
|
|
1234
1234
|
}
|
|
1235
1235
|
}
|
|
1236
|
-
function
|
|
1236
|
+
function kf(e, n) {
|
|
1237
1237
|
if (e.length > 1 && !/ /.test(e))
|
|
1238
1238
|
return e;
|
|
1239
1239
|
for (var a = n, i = "", s = 0; s < e.length; s++) {
|
|
@@ -1242,7 +1242,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
1242
1242
|
}
|
|
1243
1243
|
return i;
|
|
1244
1244
|
}
|
|
1245
|
-
function
|
|
1245
|
+
function Sf(e, n) {
|
|
1246
1246
|
return function(a, i, s, c, d, p, g) {
|
|
1247
1247
|
s = s ? s + " cm-force-border" : "cm-force-border";
|
|
1248
1248
|
for (var y = a.pos, C = y + i.length; ; ) {
|
|
@@ -1258,7 +1258,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
1258
1258
|
var s = !i && a.widgetNode;
|
|
1259
1259
|
s && e.map.push(e.pos, e.pos + n, s), !i && e.cm.display.input.needsContentAttribute && (s || (s = e.content.appendChild(document.createElement("span"))), s.setAttribute("cm-marker", a.id)), s && (e.cm.display.input.setUneditable(s), e.content.appendChild(s)), e.pos += n, e.trailingSpace = !1;
|
|
1260
1260
|
}
|
|
1261
|
-
function
|
|
1261
|
+
function Cf(e, n, a) {
|
|
1262
1262
|
var i = e.markedSpans, s = e.text, c = 0;
|
|
1263
1263
|
if (!i) {
|
|
1264
1264
|
for (var d = 1; d < a.length; d += 2)
|
|
@@ -1324,7 +1324,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
1324
1324
|
}
|
|
1325
1325
|
}
|
|
1326
1326
|
function Io(e, n, a) {
|
|
1327
|
-
this.line = n, this.rest =
|
|
1327
|
+
this.line = n, this.rest = gf(n), this.size = this.rest ? b(be(this.rest)) - a + 1 : 1, this.node = this.text = null, this.hidden = $n(e, n);
|
|
1328
1328
|
}
|
|
1329
1329
|
function Ui(e, n, a) {
|
|
1330
1330
|
for (var i = [], s, c = n; c < a; c = s) {
|
|
@@ -1334,13 +1334,13 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
1334
1334
|
return i;
|
|
1335
1335
|
}
|
|
1336
1336
|
var br = null;
|
|
1337
|
-
function
|
|
1337
|
+
function Tf(e) {
|
|
1338
1338
|
br ? br.ops.push(e) : e.ownsGroup = br = {
|
|
1339
1339
|
ops: [e],
|
|
1340
1340
|
delayedCallbacks: []
|
|
1341
1341
|
};
|
|
1342
1342
|
}
|
|
1343
|
-
function
|
|
1343
|
+
function _f(e) {
|
|
1344
1344
|
var n = e.delayedCallbacks, a = 0;
|
|
1345
1345
|
do {
|
|
1346
1346
|
for (; a < n.length; a++)
|
|
@@ -1353,11 +1353,11 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
1353
1353
|
}
|
|
1354
1354
|
} while (a < n.length);
|
|
1355
1355
|
}
|
|
1356
|
-
function
|
|
1356
|
+
function Lf(e, n) {
|
|
1357
1357
|
var a = e.ownsGroup;
|
|
1358
1358
|
if (a)
|
|
1359
1359
|
try {
|
|
1360
|
-
|
|
1360
|
+
_f(a);
|
|
1361
1361
|
} finally {
|
|
1362
1362
|
br = null, n(a);
|
|
1363
1363
|
}
|
|
@@ -1367,7 +1367,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
1367
1367
|
var a = xn(e, n);
|
|
1368
1368
|
if (a.length) {
|
|
1369
1369
|
var i = Array.prototype.slice.call(arguments, 2), s;
|
|
1370
|
-
br ? s = br.delayedCallbacks : Yr ? s = Yr : (s = Yr = [], setTimeout(
|
|
1370
|
+
br ? s = br.delayedCallbacks : Yr ? s = Yr : (s = Yr = [], setTimeout(Ef, 0));
|
|
1371
1371
|
for (var c = function(p) {
|
|
1372
1372
|
s.push(function() {
|
|
1373
1373
|
return a[p].apply(null, i);
|
|
@@ -1376,7 +1376,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
1376
1376
|
c(d);
|
|
1377
1377
|
}
|
|
1378
1378
|
}
|
|
1379
|
-
function
|
|
1379
|
+
function Ef() {
|
|
1380
1380
|
var e = Yr;
|
|
1381
1381
|
Yr = null;
|
|
1382
1382
|
for (var n = 0; n < e.length; ++n)
|
|
@@ -1385,14 +1385,14 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
1385
1385
|
function Oo(e, n, a, i) {
|
|
1386
1386
|
for (var s = 0; s < n.changes.length; s++) {
|
|
1387
1387
|
var c = n.changes[s];
|
|
1388
|
-
c == "text" ?
|
|
1388
|
+
c == "text" ? If(e, n) : c == "gutter" ? No(e, n, a, i) : c == "class" ? Ga(e, n) : c == "widget" && Of(e, n, i);
|
|
1389
1389
|
}
|
|
1390
1390
|
n.changes = null;
|
|
1391
1391
|
}
|
|
1392
1392
|
function Zr(e) {
|
|
1393
1393
|
return e.node == e.text && (e.node = k("div", null, null, "position: relative"), e.text.parentNode && e.text.parentNode.replaceChild(e.node, e.text), e.node.appendChild(e.text), m && x < 8 && (e.node.style.zIndex = 2)), e.node;
|
|
1394
1394
|
}
|
|
1395
|
-
function
|
|
1395
|
+
function Af(e, n) {
|
|
1396
1396
|
var a = n.bgClass ? n.bgClass + " " + (n.line.bgClass || "") : n.line.bgClass;
|
|
1397
1397
|
if (a && (a += " CodeMirror-linebackground"), n.background)
|
|
1398
1398
|
a ? n.background.className = a : (n.background.parentNode.removeChild(n.background), n.background = null);
|
|
@@ -1405,12 +1405,12 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
1405
1405
|
var a = e.display.externalMeasured;
|
|
1406
1406
|
return a && a.line == n.line ? (e.display.externalMeasured = null, n.measure = a.measure, a.built) : Eo(e, n);
|
|
1407
1407
|
}
|
|
1408
|
-
function
|
|
1408
|
+
function If(e, n) {
|
|
1409
1409
|
var a = n.text.className, i = Do(e, n);
|
|
1410
1410
|
n.text == n.node && (n.node = i.pre), n.text.parentNode.replaceChild(i.pre, n.text), n.text = i.pre, i.bgClass != n.bgClass || i.textClass != n.textClass ? (n.bgClass = i.bgClass, n.textClass = i.textClass, Ga(e, n)) : a && (n.text.className = a);
|
|
1411
1411
|
}
|
|
1412
1412
|
function Ga(e, n) {
|
|
1413
|
-
|
|
1413
|
+
Af(e, n), n.line.wrapClass ? Zr(n).className = n.line.wrapClass : n.node != n.text && (n.node.className = "");
|
|
1414
1414
|
var a = n.textClass ? n.textClass + " " + (n.line.textClass || "") : n.line.textClass;
|
|
1415
1415
|
n.text.className = a || "";
|
|
1416
1416
|
}
|
|
@@ -1446,13 +1446,13 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
1446
1446
|
}
|
|
1447
1447
|
}
|
|
1448
1448
|
}
|
|
1449
|
-
function
|
|
1449
|
+
function Of(e, n, a) {
|
|
1450
1450
|
n.alignable && (n.alignable = null);
|
|
1451
1451
|
for (var i = ie("CodeMirror-linewidget"), s = n.node.firstChild, c = void 0; s; s = c)
|
|
1452
1452
|
c = s.nextSibling, i.test(s.className) && n.node.removeChild(s);
|
|
1453
1453
|
Ro(e, n, a);
|
|
1454
1454
|
}
|
|
1455
|
-
function
|
|
1455
|
+
function Df(e, n, a, i) {
|
|
1456
1456
|
var s = Do(e, n);
|
|
1457
1457
|
return n.text = n.node = s.pre, s.bgClass && (n.bgClass = s.bgClass), s.textClass && (n.textClass = s.textClass), Ga(e, n), No(e, n, a, i), Ro(e, n, i), n.node;
|
|
1458
1458
|
}
|
|
@@ -1465,10 +1465,10 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
1465
1465
|
if (n.widgets)
|
|
1466
1466
|
for (var c = Zr(a), d = 0, p = n.widgets; d < p.length; ++d) {
|
|
1467
1467
|
var g = p[d], y = k("div", [g.node], "CodeMirror-linewidget" + (g.className ? " " + g.className : ""));
|
|
1468
|
-
g.handleMouseEvents || y.setAttribute("cm-ignore-events", "true"),
|
|
1468
|
+
g.handleMouseEvents || y.setAttribute("cm-ignore-events", "true"), Nf(g, y, a, i), e.display.input.setUneditable(y), s && g.above ? c.insertBefore(y, a.gutter || a.text) : c.appendChild(y), gt(g, "redraw");
|
|
1469
1469
|
}
|
|
1470
1470
|
}
|
|
1471
|
-
function
|
|
1471
|
+
function Nf(e, n, a, i) {
|
|
1472
1472
|
if (e.noHScroll) {
|
|
1473
1473
|
(a.alignable || (a.alignable = [])).push(n);
|
|
1474
1474
|
var s = i.wrapperWidth;
|
|
@@ -1514,7 +1514,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
1514
1514
|
function Va(e) {
|
|
1515
1515
|
return e.display.scroller.clientHeight - gn(e) - e.display.barHeight;
|
|
1516
1516
|
}
|
|
1517
|
-
function
|
|
1517
|
+
function Rf(e, n, a) {
|
|
1518
1518
|
var i = e.options.lineWrapping, s = i && Vn(e);
|
|
1519
1519
|
if (!n.measure.heights || i && n.measure.width != s) {
|
|
1520
1520
|
var c = n.measure.heights = [];
|
|
@@ -1540,7 +1540,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
1540
1540
|
return { map: e.measure.maps[s], cache: e.measure.caches[s], before: !0 };
|
|
1541
1541
|
}
|
|
1542
1542
|
}
|
|
1543
|
-
function
|
|
1543
|
+
function Ff(e, n) {
|
|
1544
1544
|
n = sn(n);
|
|
1545
1545
|
var a = b(n), i = e.display.externalMeasured = new Io(e.doc, n, a);
|
|
1546
1546
|
i.lineN = a;
|
|
@@ -1559,7 +1559,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
1559
1559
|
}
|
|
1560
1560
|
function xr(e, n) {
|
|
1561
1561
|
var a = b(n), i = Qa(e, a);
|
|
1562
|
-
i && !i.text ? i = null : i && i.changes && (Oo(e, i, a, es(e)), e.curOp.forceUpdate = !0), i || (i =
|
|
1562
|
+
i && !i.text ? i = null : i && i.changes && (Oo(e, i, a, es(e)), e.curOp.forceUpdate = !0), i || (i = Ff(e, n));
|
|
1563
1563
|
var s = Mo(i, n, a);
|
|
1564
1564
|
return {
|
|
1565
1565
|
line: n,
|
|
@@ -1574,7 +1574,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
1574
1574
|
function mn(e, n, a, i, s) {
|
|
1575
1575
|
n.before && (a = -1);
|
|
1576
1576
|
var c = a + (i || ""), d;
|
|
1577
|
-
return n.cache.hasOwnProperty(c) ? d = n.cache[c] : (n.rect || (n.rect = n.view.text.getBoundingClientRect()), n.hasHeights || (
|
|
1577
|
+
return n.cache.hasOwnProperty(c) ? d = n.cache[c] : (n.rect || (n.rect = n.view.text.getBoundingClientRect()), n.hasHeights || (Rf(e, n.view, n.rect), n.hasHeights = !0), d = Mf(e, n, a, i), d.bogus || (n.cache[c] = d)), {
|
|
1578
1578
|
left: d.left,
|
|
1579
1579
|
right: d.right,
|
|
1580
1580
|
top: s ? d.rtop : d.top,
|
|
@@ -1595,7 +1595,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
1595
1595
|
}
|
|
1596
1596
|
return { node: i, start: s, end: c, collapse: d, coverStart: p, coverEnd: g };
|
|
1597
1597
|
}
|
|
1598
|
-
function
|
|
1598
|
+
function $f(e, n) {
|
|
1599
1599
|
var a = zo;
|
|
1600
1600
|
if (n == "left")
|
|
1601
1601
|
for (var i = 0; i < e.length && (a = e[i]).left == a.right; i++)
|
|
@@ -1605,7 +1605,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
1605
1605
|
;
|
|
1606
1606
|
return a;
|
|
1607
1607
|
}
|
|
1608
|
-
function
|
|
1608
|
+
function Mf(e, n, a, i) {
|
|
1609
1609
|
var s = Bo(n.map, a, i), c = s.node, d = s.start, p = s.end, g = s.collapse, y;
|
|
1610
1610
|
if (c.nodeType == 3) {
|
|
1611
1611
|
for (var C = 0; C < 4; C++) {
|
|
@@ -1613,11 +1613,11 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
1613
1613
|
--d;
|
|
1614
1614
|
for (; s.coverStart + p < s.coverEnd && Ae(n.line.text.charAt(s.coverStart + p)); )
|
|
1615
1615
|
++p;
|
|
1616
|
-
if (m && x < 9 && d == 0 && p == s.coverEnd - s.coverStart ? y = c.parentNode.getBoundingClientRect() : y =
|
|
1616
|
+
if (m && x < 9 && d == 0 && p == s.coverEnd - s.coverStart ? y = c.parentNode.getBoundingClientRect() : y = $f(G(c, d, p).getClientRects(), i), y.left || y.right || d == 0)
|
|
1617
1617
|
break;
|
|
1618
1618
|
p = d, d = d - 1, g = "right";
|
|
1619
1619
|
}
|
|
1620
|
-
m && x < 11 && (y =
|
|
1620
|
+
m && x < 11 && (y = Pf(e.display.measure, y));
|
|
1621
1621
|
} else {
|
|
1622
1622
|
d > 0 && (g = i = "right");
|
|
1623
1623
|
var _;
|
|
@@ -1637,7 +1637,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
1637
1637
|
};
|
|
1638
1638
|
return !y.left && !y.right && (le.bogus = !0), e.options.singleCursorHeightPerLine || (le.rtop = D, le.rbottom = B), le;
|
|
1639
1639
|
}
|
|
1640
|
-
function
|
|
1640
|
+
function Pf(e, n) {
|
|
1641
1641
|
if (!window.screen || screen.logicalXDPI == null || screen.logicalXDPI == screen.deviceXDPI || !Pa(e))
|
|
1642
1642
|
return n;
|
|
1643
1643
|
var a = screen.logicalXDPI / screen.deviceXDPI, i = screen.logicalYDPI / screen.deviceYDPI;
|
|
@@ -1742,7 +1742,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
1742
1742
|
return Ja(i.first + i.size - 1, ce(i, c).text.length, null, 1, 1);
|
|
1743
1743
|
n < 0 && (n = 0);
|
|
1744
1744
|
for (var d = ce(i, s); ; ) {
|
|
1745
|
-
var p =
|
|
1745
|
+
var p = zf(e, d, s, n, a), g = hf(d, p.ch + (p.xRel > 0 || p.outside > 0 ? 1 : 0));
|
|
1746
1746
|
if (!g)
|
|
1747
1747
|
return p;
|
|
1748
1748
|
var y = g.find(1);
|
|
@@ -1768,11 +1768,11 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
1768
1768
|
function Za(e, n, a, i) {
|
|
1769
1769
|
return e.bottom <= a ? !1 : e.top > a ? !0 : (i ? e.left : e.right) > n;
|
|
1770
1770
|
}
|
|
1771
|
-
function
|
|
1771
|
+
function zf(e, n, a, i, s) {
|
|
1772
1772
|
s -= Sn(n);
|
|
1773
1773
|
var c = xr(e, n), d = Xa(n), p = 0, g = n.text.length, y = !0, C = $e(n, e.doc.direction);
|
|
1774
1774
|
if (C) {
|
|
1775
|
-
var _ = (e.options.lineWrapping ?
|
|
1775
|
+
var _ = (e.options.lineWrapping ? Hf : Bf)(e, n, a, c, C, i, s);
|
|
1776
1776
|
y = _.level != 1, p = y ? _.from : _.to - 1, g = y ? _.to : _.from - 1;
|
|
1777
1777
|
}
|
|
1778
1778
|
var F = null, D = null, B = Qt(function(ve) {
|
|
@@ -1789,7 +1789,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
1789
1789
|
}
|
|
1790
1790
|
return B = Pt(n.text, B, 1), Ja(a, B, X, ee, i - U);
|
|
1791
1791
|
}
|
|
1792
|
-
function
|
|
1792
|
+
function Bf(e, n, a, i, s, c, d) {
|
|
1793
1793
|
var p = Qt(function(_) {
|
|
1794
1794
|
var F = s[_], D = F.level != 1;
|
|
1795
1795
|
return Za(on(
|
|
@@ -1812,7 +1812,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
1812
1812
|
}
|
|
1813
1813
|
return g;
|
|
1814
1814
|
}
|
|
1815
|
-
function
|
|
1815
|
+
function Hf(e, n, a, i, s, c, d) {
|
|
1816
1816
|
var p = Ko(e, n, i, d), g = p.begin, y = p.end;
|
|
1817
1817
|
/\s/.test(n.text.charAt(y - 1)) && y--;
|
|
1818
1818
|
for (var C = null, _ = null, F = 0; F < s.length; F++) {
|
|
@@ -1963,7 +1963,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
1963
1963
|
}
|
|
1964
1964
|
return { index: s, lineN: a };
|
|
1965
1965
|
}
|
|
1966
|
-
function
|
|
1966
|
+
function Wf(e, n, a) {
|
|
1967
1967
|
var i = e.display, s = i.view;
|
|
1968
1968
|
s.length == 0 || n >= i.viewTo || a <= i.viewFrom ? (i.view = Ui(e, n, a), i.viewFrom = n) : (i.viewFrom > n ? i.view = Ui(e, n, i.viewFrom).concat(i.view) : i.viewFrom < n && (i.view = i.view.slice(Jn(e, n))), i.viewFrom = n, i.viewTo < a ? i.view = i.view.concat(Ui(e, i.viewTo, a)) : i.viewTo > a && (i.view = i.view.slice(0, Jn(e, a)))), i.viewTo = a;
|
|
1969
1969
|
}
|
|
@@ -1990,7 +1990,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
1990
1990
|
var C = d(e, g);
|
|
1991
1991
|
C && rs(e, C, s);
|
|
1992
1992
|
} else (y || e.options.showCursorWhenSelecting) && rs(e, g.head, s);
|
|
1993
|
-
y ||
|
|
1993
|
+
y || jf(e, g, c);
|
|
1994
1994
|
}
|
|
1995
1995
|
}
|
|
1996
1996
|
return i;
|
|
@@ -2009,7 +2009,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
2009
2009
|
function Xi(e, n) {
|
|
2010
2010
|
return e.top - n.top || e.left - n.left;
|
|
2011
2011
|
}
|
|
2012
|
-
function
|
|
2012
|
+
function jf(e, n, a) {
|
|
2013
2013
|
var i = e.display, s = e.doc, c = document.createDocumentFragment(), d = $o(e.display), p = d.left, g = Math.max(i.sizerWidth, Vn(e) - i.sizer.offsetLeft) - d.right, y = s.direction == "ltr";
|
|
2014
2014
|
function C(te, le, ve, ge) {
|
|
2015
2015
|
le < 0 && (le = 0), le = Math.round(le), ge = Math.round(ge), c.appendChild(k("div", null, "CodeMirror-selected", "position: absolute; left: " + te + `px;
|
|
@@ -2115,7 +2115,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
2115
2115
|
}
|
|
2116
2116
|
return { from: c, to: Math.max(d, c + 1) };
|
|
2117
2117
|
}
|
|
2118
|
-
function
|
|
2118
|
+
function qf(e, n) {
|
|
2119
2119
|
if (!Ze(e, "scrollCursorIntoView")) {
|
|
2120
2120
|
var a = e.display, i = a.sizer.getBoundingClientRect(), s = null, c = a.wrapper.ownerDocument;
|
|
2121
2121
|
if (n.top + i.top < 0 ? s = !0 : n.bottom + i.top > (c.defaultView.innerHeight || c.documentElement.clientHeight) && (s = !1), s != null && !A) {
|
|
@@ -2127,7 +2127,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
2127
2127
|
}
|
|
2128
2128
|
}
|
|
2129
2129
|
}
|
|
2130
|
-
function
|
|
2130
|
+
function Uf(e, n, a, i) {
|
|
2131
2131
|
i == null && (i = 0);
|
|
2132
2132
|
var s;
|
|
2133
2133
|
!e.options.lineWrapping && n == a && (a = n.sticky == "before" ? P(n.line, n.ch + 1, "before") : n, n = n.ch ? P(n.line, n.sticky == "before" ? n.ch - 1 : n.ch, "after") : n);
|
|
@@ -2145,7 +2145,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
2145
2145
|
}
|
|
2146
2146
|
return s;
|
|
2147
2147
|
}
|
|
2148
|
-
function
|
|
2148
|
+
function Gf(e, n) {
|
|
2149
2149
|
var a = os(e, n);
|
|
2150
2150
|
a.scrollTop != null && ii(e, a.scrollTop), a.scrollLeft != null && Yn(e, a.scrollLeft);
|
|
2151
2151
|
}
|
|
@@ -2175,7 +2175,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
2175
2175
|
function ri(e, n, a) {
|
|
2176
2176
|
(n != null || a != null) && Zi(e), n != null && (e.curOp.scrollLeft = n), a != null && (e.curOp.scrollTop = a);
|
|
2177
2177
|
}
|
|
2178
|
-
function
|
|
2178
|
+
function Kf(e, n) {
|
|
2179
2179
|
Zi(e), e.curOp.scrollToPos = n;
|
|
2180
2180
|
}
|
|
2181
2181
|
function Zi(e) {
|
|
@@ -2292,7 +2292,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
2292
2292
|
a == "horizontal" ? Yn(e, n) : ii(e, n);
|
|
2293
2293
|
}, e), e.display.scrollbars.addClass && K(e.display.wrapper, e.display.scrollbars.addClass);
|
|
2294
2294
|
}
|
|
2295
|
-
var
|
|
2295
|
+
var Vf = 0;
|
|
2296
2296
|
function er(e) {
|
|
2297
2297
|
e.curOp = {
|
|
2298
2298
|
cm: e,
|
|
@@ -2322,59 +2322,59 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
2322
2322
|
scrollToPos: null,
|
|
2323
2323
|
// Used to scroll to a specific position
|
|
2324
2324
|
focus: !1,
|
|
2325
|
-
id: ++
|
|
2325
|
+
id: ++Vf,
|
|
2326
2326
|
// Unique ID
|
|
2327
2327
|
markArrays: null
|
|
2328
2328
|
// Used by addMarkedSpan
|
|
2329
|
-
},
|
|
2329
|
+
}, Tf(e.curOp);
|
|
2330
2330
|
}
|
|
2331
2331
|
function tr(e) {
|
|
2332
2332
|
var n = e.curOp;
|
|
2333
|
-
n &&
|
|
2333
|
+
n && Lf(n, function(a) {
|
|
2334
2334
|
for (var i = 0; i < a.ops.length; i++)
|
|
2335
2335
|
a.ops[i].cm.curOp = null;
|
|
2336
|
-
|
|
2336
|
+
Qf(a);
|
|
2337
2337
|
});
|
|
2338
2338
|
}
|
|
2339
|
-
function
|
|
2339
|
+
function Qf(e) {
|
|
2340
2340
|
for (var n = e.ops, a = 0; a < n.length; a++)
|
|
2341
|
-
|
|
2341
|
+
Xf(n[a]);
|
|
2342
2342
|
for (var i = 0; i < n.length; i++)
|
|
2343
|
-
|
|
2343
|
+
Jf(n[i]);
|
|
2344
2344
|
for (var s = 0; s < n.length; s++)
|
|
2345
|
-
|
|
2345
|
+
Yf(n[s]);
|
|
2346
2346
|
for (var c = 0; c < n.length; c++)
|
|
2347
|
-
|
|
2347
|
+
Zf(n[c]);
|
|
2348
2348
|
for (var d = 0; d < n.length; d++)
|
|
2349
|
-
|
|
2349
|
+
ed(n[d]);
|
|
2350
2350
|
}
|
|
2351
|
-
function
|
|
2351
|
+
function Xf(e) {
|
|
2352
2352
|
var n = e.cm, a = n.display;
|
|
2353
|
-
|
|
2353
|
+
nd(n), e.updateMaxLine && Ua(n), e.mustUpdate = e.viewChanged || e.forceUpdate || e.scrollTop != null || e.scrollToPos && (e.scrollToPos.from.line < a.viewFrom || e.scrollToPos.to.line >= a.viewTo) || a.maxLineChanged && n.options.lineWrapping, e.update = e.mustUpdate && new ea(n, e.mustUpdate && { top: e.scrollTop, ensure: e.scrollToPos }, e.forceUpdate);
|
|
2354
2354
|
}
|
|
2355
|
-
function
|
|
2355
|
+
function Jf(e) {
|
|
2356
2356
|
e.updatedDisplay = e.mustUpdate && us(e.cm, e.update);
|
|
2357
2357
|
}
|
|
2358
|
-
function
|
|
2358
|
+
function Yf(e) {
|
|
2359
2359
|
var n = e.cm, a = n.display;
|
|
2360
2360
|
e.updatedDisplay && Ji(n), e.barMeasure = ai(n), a.maxLineChanged && !n.options.lineWrapping && (e.adjustWidthTo = Po(n, a.maxLine, a.maxLine.text.length).left + 3, n.display.sizerWidth = e.adjustWidthTo, e.barMeasure.scrollWidth = Math.max(a.scroller.clientWidth, a.sizer.offsetLeft + e.adjustWidthTo + gn(n) + n.display.barWidth), e.maxScrollLeft = Math.max(0, a.sizer.offsetLeft + e.adjustWidthTo - Vn(n))), (e.updatedDisplay || e.selectionChanged) && (e.preparedSelection = a.input.prepareSelection());
|
|
2361
2361
|
}
|
|
2362
|
-
function
|
|
2362
|
+
function Zf(e) {
|
|
2363
2363
|
var n = e.cm;
|
|
2364
2364
|
e.adjustWidthTo != null && (n.display.sizer.style.minWidth = e.adjustWidthTo + "px", e.maxScrollLeft < n.doc.scrollLeft && Yn(n, Math.min(n.display.scroller.scrollLeft, e.maxScrollLeft), !0), n.display.maxLineChanged = !1);
|
|
2365
2365
|
var a = e.focus && e.focus == $(oe(n));
|
|
2366
2366
|
e.preparedSelection && n.display.input.showSelection(e.preparedSelection, a), (e.updatedDisplay || e.startHeight != n.doc.height) && Tr(n, e.barMeasure), e.updatedDisplay && ds(n, e.barMeasure), e.selectionChanged && is(n), n.state.focused && e.updateInput && n.display.input.reset(e.typing), a && Yo(e.cm);
|
|
2367
2367
|
}
|
|
2368
|
-
function
|
|
2368
|
+
function ed(e) {
|
|
2369
2369
|
var n = e.cm, a = n.display, i = n.doc;
|
|
2370
2370
|
if (e.updatedDisplay && al(n, e.update), a.wheelStartX != null && (e.scrollTop != null || e.scrollLeft != null || e.scrollToPos) && (a.wheelStartX = a.wheelStartY = null), e.scrollTop != null && tl(n, e.scrollTop, e.forceScroll), e.scrollLeft != null && Yn(n, e.scrollLeft, !0, !0), e.scrollToPos) {
|
|
2371
|
-
var s =
|
|
2371
|
+
var s = Uf(
|
|
2372
2372
|
n,
|
|
2373
2373
|
Ce(i, e.scrollToPos.from),
|
|
2374
2374
|
Ce(i, e.scrollToPos.to),
|
|
2375
2375
|
e.scrollToPos.margin
|
|
2376
2376
|
);
|
|
2377
|
-
|
|
2377
|
+
qf(n, s);
|
|
2378
2378
|
}
|
|
2379
2379
|
var c = e.maybeHiddenMarkers, d = e.maybeUnhiddenMarkers;
|
|
2380
2380
|
if (c)
|
|
@@ -2433,9 +2433,9 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
2433
2433
|
};
|
|
2434
2434
|
}
|
|
2435
2435
|
function oi(e, n) {
|
|
2436
|
-
e.doc.highlightFrontier < e.display.viewTo && e.state.highlight.set(n, fe(
|
|
2436
|
+
e.doc.highlightFrontier < e.display.viewTo && e.state.highlight.set(n, fe(td, e));
|
|
2437
2437
|
}
|
|
2438
|
-
function
|
|
2438
|
+
function td(e) {
|
|
2439
2439
|
var n = e.doc;
|
|
2440
2440
|
if (!(n.highlightFrontier >= e.display.viewTo)) {
|
|
2441
2441
|
var a = +/* @__PURE__ */ new Date() + e.options.workTime, i = Xr(e, n.highlightFrontier), s = [];
|
|
@@ -2468,11 +2468,11 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
2468
2468
|
for (var e = 0; e < this.events.length; e++)
|
|
2469
2469
|
Ye.apply(null, this.events[e]);
|
|
2470
2470
|
};
|
|
2471
|
-
function
|
|
2471
|
+
function nd(e) {
|
|
2472
2472
|
var n = e.display;
|
|
2473
2473
|
!n.scrollbarsClipped && n.scroller.offsetWidth && (n.nativeBarWidth = n.scroller.offsetWidth - n.scroller.clientWidth, n.heightForcer.style.height = gn(e) + "px", n.sizer.style.marginBottom = -n.nativeBarWidth + "px", n.sizer.style.borderRightWidth = gn(e) + "px", n.scrollbarsClipped = !0);
|
|
2474
2474
|
}
|
|
2475
|
-
function
|
|
2475
|
+
function rd(e) {
|
|
2476
2476
|
if (e.hasFocus())
|
|
2477
2477
|
return null;
|
|
2478
2478
|
var n = $(oe(e));
|
|
@@ -2485,7 +2485,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
2485
2485
|
}
|
|
2486
2486
|
return a;
|
|
2487
2487
|
}
|
|
2488
|
-
function
|
|
2488
|
+
function id(e) {
|
|
2489
2489
|
if (!(!e || !e.activeElt || e.activeElt == $(Te(e.activeElt))) && (e.activeElt.focus(), !/^(INPUT|TEXTAREA)$/.test(e.activeElt.nodeName) && e.anchorNode && I(document.body, e.anchorNode) && I(document.body, e.focusNode))) {
|
|
2490
2490
|
var n = e.activeElt.ownerDocument, a = n.defaultView.getSelection(), i = n.createRange();
|
|
2491
2491
|
i.setEnd(e.anchorNode, e.anchorOffset), i.collapse(!1), a.removeAllRanges(), a.addRange(i), a.extend(e.focusNode, e.focusOffset);
|
|
@@ -2501,12 +2501,12 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
2501
2501
|
var s = i.first + i.size, c = Math.max(n.visible.from - e.options.viewportMargin, i.first), d = Math.min(s, n.visible.to + e.options.viewportMargin);
|
|
2502
2502
|
a.viewFrom < c && c - a.viewFrom < 20 && (c = Math.max(i.first, a.viewFrom)), a.viewTo > d && a.viewTo - d < 20 && (d = Math.min(s, a.viewTo)), kn && (c = ja(e.doc, c), d = _o(e.doc, d));
|
|
2503
2503
|
var p = c != a.viewFrom || d != a.viewTo || a.lastWrapHeight != n.wrapperHeight || a.lastWrapWidth != n.wrapperWidth;
|
|
2504
|
-
|
|
2504
|
+
Wf(e, c, d), a.viewOffset = Sn(ce(e.doc, a.viewFrom)), e.display.mover.style.top = a.viewOffset + "px";
|
|
2505
2505
|
var g = Xo(e);
|
|
2506
2506
|
if (!p && g == 0 && !n.force && a.renderedView == a.view && (a.updateLineNumbers == null || a.updateLineNumbers >= a.viewTo))
|
|
2507
2507
|
return !1;
|
|
2508
|
-
var y =
|
|
2509
|
-
return g > 4 && (a.lineDiv.style.display = "none"),
|
|
2508
|
+
var y = rd(e);
|
|
2509
|
+
return g > 4 && (a.lineDiv.style.display = "none"), ad(e, a.updateLineNumbers, n.dims), g > 4 && (a.lineDiv.style.display = ""), a.renderedView = a.view, id(y), j(a.cursorDiv), j(a.selectionDiv), a.gutters.style.height = a.sizer.style.minHeight = 0, p && (a.lastWrapHeight = n.wrapperHeight, a.lastWrapWidth = n.wrapperWidth, oi(e, 400)), a.updateLineNumbers = null, !0;
|
|
2510
2510
|
}
|
|
2511
2511
|
function al(e, n) {
|
|
2512
2512
|
for (var a = n.viewport, i = !0; ; i = !1) {
|
|
@@ -2530,7 +2530,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
2530
2530
|
ni(e), Tr(e, i), ds(e, i), a.finish();
|
|
2531
2531
|
}
|
|
2532
2532
|
}
|
|
2533
|
-
function
|
|
2533
|
+
function ad(e, n, a) {
|
|
2534
2534
|
var i = e.display, s = e.options.lineNumbers, c = i.lineDiv, d = c.firstChild;
|
|
2535
2535
|
function p(B) {
|
|
2536
2536
|
var U = B.nextSibling;
|
|
@@ -2539,7 +2539,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
2539
2539
|
for (var g = i.view, y = i.viewFrom, C = 0; C < g.length; C++) {
|
|
2540
2540
|
var _ = g[C];
|
|
2541
2541
|
if (!_.hidden) if (!_.node || _.node.parentNode != c) {
|
|
2542
|
-
var F =
|
|
2542
|
+
var F = Df(e, _, y, a);
|
|
2543
2543
|
c.insertBefore(F, d);
|
|
2544
2544
|
} else {
|
|
2545
2545
|
for (; d != _.node; )
|
|
@@ -2611,7 +2611,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
2611
2611
|
function li(e) {
|
|
2612
2612
|
ll(e.display), Ot(e), sl(e);
|
|
2613
2613
|
}
|
|
2614
|
-
function
|
|
2614
|
+
function sd(e, n, a, i) {
|
|
2615
2615
|
var s = this;
|
|
2616
2616
|
this.input = a, s.scrollbarFiller = k("div", null, "CodeMirror-scrollbar-filler"), s.scrollbarFiller.setAttribute("cm-not-content", "true"), s.gutterFiller = k("div", null, "CodeMirror-gutter-filler"), s.gutterFiller.setAttribute("cm-not-content", "true"), s.lineDiv = J("div", null, "CodeMirror-code"), s.selectionDiv = k("div", null, null, "position: relative; z-index: 1"), s.cursorDiv = k("div", null, "CodeMirror-cursors"), s.measure = k("div", null, "CodeMirror-measure"), s.lineMeasure = k("div", null, "CodeMirror-measure"), s.lineSpace = J(
|
|
2617
2617
|
"div",
|
|
@@ -2628,7 +2628,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
2628
2628
|
var n = e.wheelDeltaX, a = e.wheelDeltaY;
|
|
2629
2629
|
return n == null && e.detail && e.axis == e.HORIZONTAL_AXIS && (n = e.detail), a == null && e.detail && e.axis == e.VERTICAL_AXIS ? a = e.detail : a == null && (a = e.wheelDelta), { x: n, y: a };
|
|
2630
2630
|
}
|
|
2631
|
-
function
|
|
2631
|
+
function od(e) {
|
|
2632
2632
|
var n = ul(e);
|
|
2633
2633
|
return n.x *= Tn, n.y *= Tn, n;
|
|
2634
2634
|
}
|
|
@@ -2752,7 +2752,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
2752
2752
|
function dl(e, n, a) {
|
|
2753
2753
|
return e.line == n.line ? P(a.line, e.ch - n.ch + a.ch) : P(a.line + (e.line - n.line), e.ch);
|
|
2754
2754
|
}
|
|
2755
|
-
function
|
|
2755
|
+
function ld(e, n, a) {
|
|
2756
2756
|
for (var i = [], s = P(e.first, 0), c = s, d = 0; d < n.length; d++) {
|
|
2757
2757
|
var p = n[d], g = dl(p.from, s, c), y = dl(Bn(p), s, c);
|
|
2758
2758
|
if (s = p.to, c = y, a == "around") {
|
|
@@ -2779,7 +2779,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
2779
2779
|
return a ? a[ae] : null;
|
|
2780
2780
|
}
|
|
2781
2781
|
function c(ae, te, le) {
|
|
2782
|
-
|
|
2782
|
+
mf(ae, te, le, i), gt(ae, "change", ae, n);
|
|
2783
2783
|
}
|
|
2784
2784
|
function d(ae, te) {
|
|
2785
2785
|
for (var le = [], ve = ae; ve < te; ++ve)
|
|
@@ -2829,7 +2829,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
2829
2829
|
function gl(e) {
|
|
2830
2830
|
(e.doc.direction == "rtl" ? K : Me)(e.display.lineDiv, "CodeMirror-rtl");
|
|
2831
2831
|
}
|
|
2832
|
-
function
|
|
2832
|
+
function ud(e) {
|
|
2833
2833
|
Bt(e, function() {
|
|
2834
2834
|
gl(e), Ot(e);
|
|
2835
2835
|
});
|
|
@@ -2852,7 +2852,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
2852
2852
|
break;
|
|
2853
2853
|
}
|
|
2854
2854
|
}
|
|
2855
|
-
function
|
|
2855
|
+
function cd(e, n) {
|
|
2856
2856
|
if (n)
|
|
2857
2857
|
return ml(e.done), be(e.done);
|
|
2858
2858
|
if (e.done.length && !be(e.done).ranges)
|
|
@@ -2864,7 +2864,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
2864
2864
|
var s = e.history;
|
|
2865
2865
|
s.undone.length = 0;
|
|
2866
2866
|
var c = +/* @__PURE__ */ new Date(), d, p;
|
|
2867
|
-
if ((s.lastOp == i || s.lastOrigin == n.origin && n.origin && (n.origin.charAt(0) == "+" && s.lastModTime > c - (e.cm ? e.cm.options.historyEventDelay : 500) || n.origin.charAt(0) == "*")) && (d =
|
|
2867
|
+
if ((s.lastOp == i || s.lastOrigin == n.origin && n.origin && (n.origin.charAt(0) == "+" && s.lastModTime > c - (e.cm ? e.cm.options.historyEventDelay : 500) || n.origin.charAt(0) == "*")) && (d = cd(s, s.lastOp == i)))
|
|
2868
2868
|
p = be(d.changes), re(n.from, n.to) == 0 && re(n.from, p.to) == 0 ? p.to = Bn(n) : d.changes.push(vs(e, n));
|
|
2869
2869
|
else {
|
|
2870
2870
|
var g = be(s.done);
|
|
@@ -2876,13 +2876,13 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
2876
2876
|
}
|
|
2877
2877
|
s.done.push(a), s.generation = ++s.maxGeneration, s.lastModTime = s.lastSelTime = c, s.lastOp = s.lastSelOp = i, s.lastOrigin = s.lastSelOrigin = n.origin, p || Ye(e, "historyAdded");
|
|
2878
2878
|
}
|
|
2879
|
-
function
|
|
2879
|
+
function fd(e, n, a, i) {
|
|
2880
2880
|
var s = n.charAt(0);
|
|
2881
2881
|
return s == "*" || s == "+" && a.ranges.length == i.ranges.length && a.somethingSelected() == i.somethingSelected() && /* @__PURE__ */ new Date() - e.history.lastSelTime <= (e.cm ? e.cm.options.historyEventDelay : 500);
|
|
2882
2882
|
}
|
|
2883
|
-
function
|
|
2883
|
+
function dd(e, n, a, i) {
|
|
2884
2884
|
var s = e.history, c = i && i.origin;
|
|
2885
|
-
a == s.lastSelOp || c && s.lastSelOrigin == c && (s.lastModTime == s.lastSelTime && s.lastOrigin == c ||
|
|
2885
|
+
a == s.lastSelOp || c && s.lastSelOrigin == c && (s.lastModTime == s.lastSelTime && s.lastOrigin == c || fd(e, c, be(s.done), n)) ? s.done[s.done.length - 1] = n : ra(n, s.done), s.lastSelTime = +/* @__PURE__ */ new Date(), s.lastSelOrigin = c, s.lastSelOp = a, i && i.clearRedo !== !1 && ml(s.undone);
|
|
2886
2886
|
}
|
|
2887
2887
|
function ra(e, n) {
|
|
2888
2888
|
var a = be(n);
|
|
@@ -2894,23 +2894,23 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
2894
2894
|
d.markedSpans && ((s || (s = n["spans_" + e.id] = {}))[c] = d.markedSpans), ++c;
|
|
2895
2895
|
});
|
|
2896
2896
|
}
|
|
2897
|
-
function
|
|
2897
|
+
function hd(e) {
|
|
2898
2898
|
if (!e)
|
|
2899
2899
|
return null;
|
|
2900
2900
|
for (var n, a = 0; a < e.length; ++a)
|
|
2901
2901
|
e[a].marker.explicitlyCleared ? n || (n = e.slice(0, a)) : n && n.push(e[a]);
|
|
2902
2902
|
return n ? n.length ? n : null : e;
|
|
2903
2903
|
}
|
|
2904
|
-
function
|
|
2904
|
+
function pd(e, n) {
|
|
2905
2905
|
var a = n["spans_" + e.id];
|
|
2906
2906
|
if (!a)
|
|
2907
2907
|
return null;
|
|
2908
2908
|
for (var i = [], s = 0; s < n.text.length; ++s)
|
|
2909
|
-
i.push(
|
|
2909
|
+
i.push(hd(a[s]));
|
|
2910
2910
|
return i;
|
|
2911
2911
|
}
|
|
2912
2912
|
function bl(e, n) {
|
|
2913
|
-
var a =
|
|
2913
|
+
var a = pd(e, n), i = Ha(e, n);
|
|
2914
2914
|
if (!a)
|
|
2915
2915
|
return i;
|
|
2916
2916
|
if (!i)
|
|
@@ -2973,7 +2973,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
2973
2973
|
function wl(e, n, a, i) {
|
|
2974
2974
|
Tt(e, zn(n, a), i);
|
|
2975
2975
|
}
|
|
2976
|
-
function
|
|
2976
|
+
function gd(e, n, a) {
|
|
2977
2977
|
var i = {
|
|
2978
2978
|
ranges: n.ranges,
|
|
2979
2979
|
update: function(s) {
|
|
@@ -2993,10 +2993,10 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
2993
2993
|
s && s.ranges ? (i[i.length - 1] = n, aa(e, n, a)) : Tt(e, n, a);
|
|
2994
2994
|
}
|
|
2995
2995
|
function Tt(e, n, a) {
|
|
2996
|
-
aa(e, n, a),
|
|
2996
|
+
aa(e, n, a), dd(e, e.sel, e.cm ? e.cm.curOp.id : NaN, a);
|
|
2997
2997
|
}
|
|
2998
2998
|
function aa(e, n, a) {
|
|
2999
|
-
(zt(e, "beforeSelectionChange") || e.cm && zt(e.cm, "beforeSelectionChange")) && (n =
|
|
2999
|
+
(zt(e, "beforeSelectionChange") || e.cm && zt(e.cm, "beforeSelectionChange")) && (n = gd(e, n, a));
|
|
3000
3000
|
var i = a && a.bias || (re(n.primary().head, e.sel.primary().head) < 0 ? -1 : 1);
|
|
3001
3001
|
Sl(e, Tl(e, n, i, !0)), !(a && a.scroll === !1) && e.cm && e.cm.getOption("readOnly") != "nocursor" && Cr(e.cm);
|
|
3002
3002
|
}
|
|
@@ -3071,7 +3071,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
3071
3071
|
return;
|
|
3072
3072
|
}
|
|
3073
3073
|
if (!((zt(e, "beforeChange") || e.cm && zt(e.cm, "beforeChange")) && (n = El(e, n, !0), !n))) {
|
|
3074
|
-
var i = bo && !a &&
|
|
3074
|
+
var i = bo && !a && df(e, n.from, n.to);
|
|
3075
3075
|
if (i)
|
|
3076
3076
|
for (var s = i.length - 1; s >= 0; --s)
|
|
3077
3077
|
Al(e, { from: i[s].from, to: i[s].to, text: s ? [""] : n.text, origin: n.origin });
|
|
@@ -3162,10 +3162,10 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
3162
3162
|
to: P(c, ce(e, c).text.length),
|
|
3163
3163
|
text: [n.text[0]],
|
|
3164
3164
|
origin: n.origin
|
|
3165
|
-
}), n.removed = wn(e, n.from, n.to), a || (a = ps(e, n)), e.cm ?
|
|
3165
|
+
}), n.removed = wn(e, n.from, n.to), a || (a = ps(e, n)), e.cm ? md(e.cm, n, i) : ms(e, n, i), aa(e, a, ut), e.cantEdit && sa(e, P(e.firstLine(), 0)) && (e.cantEdit = !1);
|
|
3166
3166
|
}
|
|
3167
3167
|
}
|
|
3168
|
-
function
|
|
3168
|
+
function md(e, n, a) {
|
|
3169
3169
|
var i = e.doc, s = e.display, c = n.from, d = n.to, p = !1, g = c.line;
|
|
3170
3170
|
e.options.lineWrapping || (g = b(sn(ce(i, c.line))), i.iter(g, d.line + 1, function(D) {
|
|
3171
3171
|
if (D == s.maxLine)
|
|
@@ -3173,7 +3173,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
3173
3173
|
})), i.sel.contains(n.from, n.to) > -1 && Xt(e), ms(i, n, a, Qo(e)), e.options.lineWrapping || (i.iter(g, c.line + n.text.length, function(D) {
|
|
3174
3174
|
var B = qi(D);
|
|
3175
3175
|
B > s.maxLineLength && (s.maxLine = D, s.maxLineLength = B, s.maxLineChanged = !0, p = !1);
|
|
3176
|
-
}), p && (e.curOp.updateMaxLine = !0)),
|
|
3176
|
+
}), p && (e.curOp.updateMaxLine = !0)), af(i, c.line), oi(e, 400);
|
|
3177
3177
|
var y = n.text.length - (d.line - c.line) - 1;
|
|
3178
3178
|
n.full ? Ot(e) : c.line == d.line && n.text.length == 1 && !hl(e.doc, n) ? Mn(e, c.line, "text") : Ot(e, c.line, d.line + 1, y);
|
|
3179
3179
|
var C = zt(e, "changes"), _ = zt(e, "change");
|
|
@@ -3239,7 +3239,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
3239
3239
|
removeInner: function(e, n) {
|
|
3240
3240
|
for (var a = e, i = e + n; a < i; ++a) {
|
|
3241
3241
|
var s = this.lines[a];
|
|
3242
|
-
this.height -= s.height,
|
|
3242
|
+
this.height -= s.height, vf(s), gt(s, "delete");
|
|
3243
3243
|
}
|
|
3244
3244
|
this.lines.splice(e, n);
|
|
3245
3245
|
},
|
|
@@ -3373,7 +3373,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
3373
3373
|
function Rl(e, n, a) {
|
|
3374
3374
|
Sn(n) < (e.curOp && e.curOp.scrollTop || e.doc.scrollTop) && ls(e, a);
|
|
3375
3375
|
}
|
|
3376
|
-
function
|
|
3376
|
+
function vd(e, n, a, i) {
|
|
3377
3377
|
var s = new pi(e, a, i), c = e.cm;
|
|
3378
3378
|
return c && s.noHScroll && (c.display.alignWidgets = !0), fi(e, n, "widget", function(d) {
|
|
3379
3379
|
var p = d.widgets || (d.widgets = []);
|
|
@@ -3396,7 +3396,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
3396
3396
|
}
|
|
3397
3397
|
for (var i = null, s = null, c = 0; c < this.lines.length; ++c) {
|
|
3398
3398
|
var d = this.lines[c], p = Jr(d.markedSpans, this);
|
|
3399
|
-
e && !this.collapsed ? Mn(e, b(d), "text") : e && (p.to != null && (s = b(d)), p.from != null && (i = b(d))), d.markedSpans =
|
|
3399
|
+
e && !this.collapsed ? Mn(e, b(d), "text") : e && (p.to != null && (s = b(d)), p.from != null && (i = b(d))), d.markedSpans = lf(d.markedSpans, p), p.from == null && this.collapsed && !$n(this.doc, d) && e && qt(d, wr(e.display));
|
|
3400
3400
|
}
|
|
3401
3401
|
if (e && this.collapsed && !e.options.lineWrapping)
|
|
3402
3402
|
for (var g = 0; g < this.lines.length; ++g) {
|
|
@@ -3441,7 +3441,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
3441
3441
|
}, en(Wn);
|
|
3442
3442
|
function Ir(e, n, a, i, s) {
|
|
3443
3443
|
if (i && i.shared)
|
|
3444
|
-
return
|
|
3444
|
+
return yd(e, n, a, i, s);
|
|
3445
3445
|
if (e.cm && !e.cm.curOp)
|
|
3446
3446
|
return mt(e.cm, Ir)(e, n, a, i, s);
|
|
3447
3447
|
var c = new Wn(e, s), d = re(n, a);
|
|
@@ -3450,12 +3450,12 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
3450
3450
|
if (c.replacedWith && (c.collapsed = !0, c.widgetNode = J("span", [c.replacedWith], "CodeMirror-widget"), i.handleMouseEvents || c.widgetNode.setAttribute("cm-ignore-events", "true"), i.insertLeft && (c.widgetNode.insertLeft = !0)), c.collapsed) {
|
|
3451
3451
|
if (To(e, n.line, n, a, c) || n.line != a.line && To(e, a.line, n, a, c))
|
|
3452
3452
|
throw new Error("Inserting collapsed marker partially overlapping an existing one");
|
|
3453
|
-
|
|
3453
|
+
of();
|
|
3454
3454
|
}
|
|
3455
3455
|
c.addToHistory && vl(e, { from: n, to: a, origin: "markText" }, e.sel, NaN);
|
|
3456
3456
|
var p = n.line, g = e.cm, y;
|
|
3457
3457
|
if (e.iter(p, a.line + 1, function(_) {
|
|
3458
|
-
g && c.collapsed && !g.options.lineWrapping && sn(_) == g.display.maxLine && (y = !0), c.collapsed && p != n.line && qt(_, 0),
|
|
3458
|
+
g && c.collapsed && !g.options.lineWrapping && sn(_) == g.display.maxLine && (y = !0), c.collapsed && p != n.line && qt(_, 0), uf(_, new Bi(
|
|
3459
3459
|
c,
|
|
3460
3460
|
p == n.line ? n.ch : null,
|
|
3461
3461
|
p == a.line ? a.ch : null
|
|
@@ -3464,7 +3464,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
3464
3464
|
$n(e, _) && qt(_, 0);
|
|
3465
3465
|
}), c.clearOnEnter && me(c, "beforeCursorEnter", function() {
|
|
3466
3466
|
return c.clear();
|
|
3467
|
-
}), c.readOnly && (
|
|
3467
|
+
}), c.readOnly && (sf(), (e.history.done.length || e.history.undone.length) && e.clearHistory()), c.collapsed && (c.id = ++Fl, c.atomic = !0), g) {
|
|
3468
3468
|
if (y && (g.curOp.updateMaxLine = !0), c.collapsed)
|
|
3469
3469
|
Ot(g, n.line, a.line + 1);
|
|
3470
3470
|
else if (c.className || c.startStyle || c.endStyle || c.css || c.attributes || c.title)
|
|
@@ -3489,7 +3489,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
3489
3489
|
}, gi.prototype.find = function(e, n) {
|
|
3490
3490
|
return this.primary.find(e, n);
|
|
3491
3491
|
}, en(gi);
|
|
3492
|
-
function
|
|
3492
|
+
function yd(e, n, a, i, s) {
|
|
3493
3493
|
i = ke(i), i.shared = !1;
|
|
3494
3494
|
var c = [Ir(e, n, a, i, s)], d = c[0], p = i.widgetNode;
|
|
3495
3495
|
return Hn(e, function(g) {
|
|
@@ -3505,7 +3505,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
3505
3505
|
return n.parent;
|
|
3506
3506
|
});
|
|
3507
3507
|
}
|
|
3508
|
-
function
|
|
3508
|
+
function bd(e, n) {
|
|
3509
3509
|
for (var a = 0; a < n.length; a++) {
|
|
3510
3510
|
var i = n[a], s = i.find(), c = e.clipPos(s.from), d = e.clipPos(s.to);
|
|
3511
3511
|
if (re(c, d)) {
|
|
@@ -3514,7 +3514,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
3514
3514
|
}
|
|
3515
3515
|
}
|
|
3516
3516
|
}
|
|
3517
|
-
function
|
|
3517
|
+
function xd(e) {
|
|
3518
3518
|
for (var n = function(i) {
|
|
3519
3519
|
var s = e[i], c = [s.primary.doc];
|
|
3520
3520
|
Hn(s.primary.doc, function(g) {
|
|
@@ -3526,12 +3526,12 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
3526
3526
|
}
|
|
3527
3527
|
}, a = 0; a < e.length; a++) n(a);
|
|
3528
3528
|
}
|
|
3529
|
-
var
|
|
3529
|
+
var wd = 0, Dt = function(e, n, a, i, s) {
|
|
3530
3530
|
if (!(this instanceof Dt))
|
|
3531
3531
|
return new Dt(e, n, a, i, s);
|
|
3532
3532
|
a == null && (a = 0), hi.call(this, [new di([new yr("", null)])]), this.first = a, this.scrollTop = this.scrollLeft = 0, this.cantEdit = !1, this.cleanGeneration = 1, this.modeFrontier = this.highlightFrontier = a;
|
|
3533
3533
|
var c = P(a, 0);
|
|
3534
|
-
this.sel = zn(c), this.history = new na(null), this.id = ++
|
|
3534
|
+
this.sel = zn(c), this.history = new na(null), this.id = ++wd, this.modeOption = n, this.lineSep = i, this.direction = s == "rtl" ? "rtl" : "ltr", this.extend = !1, typeof e == "string" && (e = this.splitLines(e)), ms(this, { from: c, to: c, text: e }), Tt(this, zn(c), ut);
|
|
3535
3535
|
};
|
|
3536
3536
|
Dt.prototype = Un(hi.prototype, {
|
|
3537
3537
|
constructor: Dt,
|
|
@@ -3664,7 +3664,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
3664
3664
|
var d = s.ranges[c];
|
|
3665
3665
|
i[c] = { from: d.from(), to: d.to(), text: this.splitLines(e[c]), origin: a };
|
|
3666
3666
|
}
|
|
3667
|
-
for (var p = n && n != "end" &&
|
|
3667
|
+
for (var p = n && n != "end" && ld(this, i, n), g = i.length - 1; g >= 0; g--)
|
|
3668
3668
|
Er(this, i[g]);
|
|
3669
3669
|
p ? kl(this, p) : this.cm && Cr(this.cm);
|
|
3670
3670
|
}),
|
|
@@ -3781,7 +3781,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
3781
3781
|
});
|
|
3782
3782
|
}),
|
|
3783
3783
|
addLineWidget: vt(function(e, n, a) {
|
|
3784
|
-
return
|
|
3784
|
+
return vd(this, e, n, a);
|
|
3785
3785
|
}),
|
|
3786
3786
|
removeLineWidget: function(e) {
|
|
3787
3787
|
e.clear();
|
|
@@ -3865,14 +3865,14 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
3865
3865
|
var n = this.first, a = this.first + this.size;
|
|
3866
3866
|
e.from != null && e.from > n && (n = e.from), e.to != null && e.to < a && (a = e.to);
|
|
3867
3867
|
var i = new Dt(Qr(this, n, a), e.mode || this.modeOption, n, this.lineSep, this.direction);
|
|
3868
|
-
return e.sharedHist && (i.history = this.history), (this.linked || (this.linked = [])).push({ doc: i, sharedHist: e.sharedHist }), i.linked = [{ doc: this, isParent: !0, sharedHist: e.sharedHist }],
|
|
3868
|
+
return e.sharedHist && (i.history = this.history), (this.linked || (this.linked = [])).push({ doc: i, sharedHist: e.sharedHist }), i.linked = [{ doc: this, isParent: !0, sharedHist: e.sharedHist }], bd(i, $l(this)), i;
|
|
3869
3869
|
},
|
|
3870
3870
|
unlinkDoc: function(e) {
|
|
3871
3871
|
if (e instanceof Ve && (e = e.doc), this.linked)
|
|
3872
3872
|
for (var n = 0; n < this.linked.length; ++n) {
|
|
3873
3873
|
var a = this.linked[n];
|
|
3874
3874
|
if (a.doc == e) {
|
|
3875
|
-
this.linked.splice(n, 1), e.unlinkDoc(this),
|
|
3875
|
+
this.linked.splice(n, 1), e.unlinkDoc(this), xd($l(this));
|
|
3876
3876
|
break;
|
|
3877
3877
|
}
|
|
3878
3878
|
}
|
|
@@ -3902,11 +3902,11 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
3902
3902
|
setDirection: vt(function(e) {
|
|
3903
3903
|
e != "rtl" && (e = "ltr"), e != this.direction && (this.direction = e, this.iter(function(n) {
|
|
3904
3904
|
return n.order = null;
|
|
3905
|
-
}), this.cm &&
|
|
3905
|
+
}), this.cm && ud(this.cm));
|
|
3906
3906
|
})
|
|
3907
3907
|
}), Dt.prototype.eachLine = Dt.prototype.iter;
|
|
3908
3908
|
var Ml = 0;
|
|
3909
|
-
function
|
|
3909
|
+
function kd(e) {
|
|
3910
3910
|
var n = this;
|
|
3911
3911
|
if (Pl(n), !(Ze(n, e) || Cn(n.display, e))) {
|
|
3912
3912
|
Ct(e), m && (Ml = +/* @__PURE__ */ new Date());
|
|
@@ -3967,7 +3967,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
3967
3967
|
}
|
|
3968
3968
|
}
|
|
3969
3969
|
}
|
|
3970
|
-
function
|
|
3970
|
+
function Sd(e, n) {
|
|
3971
3971
|
if (m && (!e.state.draggingText || +/* @__PURE__ */ new Date() - Ml < 100)) {
|
|
3972
3972
|
Dn(n);
|
|
3973
3973
|
return;
|
|
@@ -3977,7 +3977,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
3977
3977
|
a.src = "data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==", z && (a.width = a.height = 1, e.display.wrapper.appendChild(a), a._top = a.offsetTop), n.dataTransfer.setDragImage(a, 0, 0), z && a.parentNode.removeChild(a);
|
|
3978
3978
|
}
|
|
3979
3979
|
}
|
|
3980
|
-
function
|
|
3980
|
+
function Cd(e, n) {
|
|
3981
3981
|
var a = Xn(e, n);
|
|
3982
3982
|
if (a) {
|
|
3983
3983
|
var i = document.createDocumentFragment();
|
|
@@ -4000,20 +4000,20 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
4000
4000
|
}
|
|
4001
4001
|
}
|
|
4002
4002
|
var Bl = !1;
|
|
4003
|
-
function
|
|
4004
|
-
Bl || (
|
|
4003
|
+
function Td() {
|
|
4004
|
+
Bl || (_d(), Bl = !0);
|
|
4005
4005
|
}
|
|
4006
|
-
function
|
|
4006
|
+
function _d() {
|
|
4007
4007
|
var e;
|
|
4008
4008
|
me(window, "resize", function() {
|
|
4009
4009
|
e == null && (e = setTimeout(function() {
|
|
4010
|
-
e = null, zl(
|
|
4010
|
+
e = null, zl(Ld);
|
|
4011
4011
|
}, 100));
|
|
4012
4012
|
}), me(window, "blur", function() {
|
|
4013
4013
|
return zl(Sr);
|
|
4014
4014
|
});
|
|
4015
4015
|
}
|
|
4016
|
-
function
|
|
4016
|
+
function Ld(e) {
|
|
4017
4017
|
var n = e.display;
|
|
4018
4018
|
n.cachedCharWidth = n.cachedTextHeight = n.cachedPaddingH = null, n.scrollbarsClipped = !1, e.setSize();
|
|
4019
4019
|
}
|
|
@@ -4174,7 +4174,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
4174
4174
|
"Ctrl-Down": "goDocEnd",
|
|
4175
4175
|
fallthrough: ["basic", "emacsy"]
|
|
4176
4176
|
}, _n.default = ne ? _n.macDefault : _n.pcDefault;
|
|
4177
|
-
function
|
|
4177
|
+
function Ed(e) {
|
|
4178
4178
|
var n = e.split(/-(?!$)/);
|
|
4179
4179
|
e = n[n.length - 1];
|
|
4180
4180
|
for (var a, i, s, c, d = 0; d < n.length - 1; d++) {
|
|
@@ -4192,7 +4192,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
4192
4192
|
}
|
|
4193
4193
|
return a && (e = "Alt-" + e), i && (e = "Ctrl-" + e), c && (e = "Cmd-" + e), s && (e = "Shift-" + e), e;
|
|
4194
4194
|
}
|
|
4195
|
-
function
|
|
4195
|
+
function Ad(e) {
|
|
4196
4196
|
var n = {};
|
|
4197
4197
|
for (var a in e)
|
|
4198
4198
|
if (e.hasOwnProperty(a)) {
|
|
@@ -4203,7 +4203,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
4203
4203
|
delete e[a];
|
|
4204
4204
|
continue;
|
|
4205
4205
|
}
|
|
4206
|
-
for (var s = wt(a.split(" "),
|
|
4206
|
+
for (var s = wt(a.split(" "), Ed), c = 0; c < s.length; c++) {
|
|
4207
4207
|
var d = void 0, p = void 0;
|
|
4208
4208
|
c == s.length - 1 ? (p = s.join(" "), d = i) : (p = s.slice(0, c + 1).join(" "), d = "...");
|
|
4209
4209
|
var g = n[p];
|
|
@@ -4299,7 +4299,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
4299
4299
|
}
|
|
4300
4300
|
return new P(i, s < 0 ? a.text.length : 0, s < 0 ? "before" : "after");
|
|
4301
4301
|
}
|
|
4302
|
-
function
|
|
4302
|
+
function Id(e, n, a, i) {
|
|
4303
4303
|
var s = $e(n, e.doc.direction);
|
|
4304
4304
|
if (!s)
|
|
4305
4305
|
return ws(n, a, i);
|
|
@@ -4412,7 +4412,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
4412
4412
|
goLineEnd: function(e) {
|
|
4413
4413
|
return e.extendSelectionsBy(
|
|
4414
4414
|
function(n) {
|
|
4415
|
-
return
|
|
4415
|
+
return Od(e, n.head.line);
|
|
4416
4416
|
},
|
|
4417
4417
|
{ origin: "+move", bias: -1 }
|
|
4418
4418
|
);
|
|
@@ -4568,8 +4568,8 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
4568
4568
|
var a = ce(e.doc, n), i = sn(a);
|
|
4569
4569
|
return i != a && (n = b(i)), ks(!0, e, i, n, 1);
|
|
4570
4570
|
}
|
|
4571
|
-
function
|
|
4572
|
-
var a = ce(e.doc, n), i =
|
|
4571
|
+
function Od(e, n) {
|
|
4572
|
+
var a = ce(e.doc, n), i = pf(a);
|
|
4573
4573
|
return i != a && (n = b(i)), ks(!0, e, a, n, -1);
|
|
4574
4574
|
}
|
|
4575
4575
|
function Ul(e, n) {
|
|
@@ -4592,7 +4592,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
4592
4592
|
}
|
|
4593
4593
|
return s;
|
|
4594
4594
|
}
|
|
4595
|
-
function
|
|
4595
|
+
function Dd(e, n, a) {
|
|
4596
4596
|
for (var i = 0; i < e.state.keyMaps.length; i++) {
|
|
4597
4597
|
var s = Or(n, e.state.keyMaps[i], a, e);
|
|
4598
4598
|
if (s)
|
|
@@ -4600,13 +4600,13 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
4600
4600
|
}
|
|
4601
4601
|
return e.options.extraKeys && Or(n, e.options.extraKeys, a, e) || Or(n, e.options.keyMap, a, e);
|
|
4602
4602
|
}
|
|
4603
|
-
var
|
|
4603
|
+
var Nd = new lt();
|
|
4604
4604
|
function bi(e, n, a, i) {
|
|
4605
4605
|
var s = e.state.keySeq;
|
|
4606
4606
|
if (s) {
|
|
4607
4607
|
if (Hl(n))
|
|
4608
4608
|
return "handled";
|
|
4609
|
-
if (/\'$/.test(n) ? e.state.keySeq = null :
|
|
4609
|
+
if (/\'$/.test(n) ? e.state.keySeq = null : Nd.set(50, function() {
|
|
4610
4610
|
e.state.keySeq == s && (e.state.keySeq = null, e.display.input.reset());
|
|
4611
4611
|
}), Gl(e, s + " " + n, a, i))
|
|
4612
4612
|
return !0;
|
|
@@ -4614,7 +4614,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
4614
4614
|
return Gl(e, n, a, i);
|
|
4615
4615
|
}
|
|
4616
4616
|
function Gl(e, n, a, i) {
|
|
4617
|
-
var s =
|
|
4617
|
+
var s = Dd(e, n, i);
|
|
4618
4618
|
return s == "multi" && (e.state.keySeq = n), s == "handled" && gt(e, "keyHandled", e, n, a), (s == "handled" || s == "multi") && (Ct(a), is(e)), !!s;
|
|
4619
4619
|
}
|
|
4620
4620
|
function Kl(e, n) {
|
|
@@ -4628,7 +4628,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
4628
4628
|
return ca(e, i);
|
|
4629
4629
|
}) : !1;
|
|
4630
4630
|
}
|
|
4631
|
-
function
|
|
4631
|
+
function Rd(e, n, a) {
|
|
4632
4632
|
return bi(e, "'" + a + "'", n, function(i) {
|
|
4633
4633
|
return ca(e, i, !0);
|
|
4634
4634
|
});
|
|
@@ -4641,10 +4641,10 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
4641
4641
|
var a = e.keyCode;
|
|
4642
4642
|
n.display.shift = a == 16 || e.shiftKey;
|
|
4643
4643
|
var i = Kl(n, e);
|
|
4644
|
-
z && (Ss = i ? a : null, !i && a == 88 && !Pi && (ne ? e.metaKey : e.ctrlKey) && n.replaceSelection("", null, "cut")), u && !ne && !i && a == 46 && e.shiftKey && !e.ctrlKey && document.execCommand && document.execCommand("cut"), a == 18 && !/\bCodeMirror-crosshair\b/.test(n.display.lineDiv.className) &&
|
|
4644
|
+
z && (Ss = i ? a : null, !i && a == 88 && !Pi && (ne ? e.metaKey : e.ctrlKey) && n.replaceSelection("", null, "cut")), u && !ne && !i && a == 46 && e.shiftKey && !e.ctrlKey && document.execCommand && document.execCommand("cut"), a == 18 && !/\bCodeMirror-crosshair\b/.test(n.display.lineDiv.className) && Fd(n);
|
|
4645
4645
|
}
|
|
4646
4646
|
}
|
|
4647
|
-
function
|
|
4647
|
+
function Fd(e) {
|
|
4648
4648
|
var n = e.display.lineDiv;
|
|
4649
4649
|
K(n, "CodeMirror-crosshair");
|
|
4650
4650
|
function a(i) {
|
|
@@ -4665,18 +4665,18 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
4665
4665
|
}
|
|
4666
4666
|
if (!(z && (!e.which || e.which < 10) && Kl(n, e))) {
|
|
4667
4667
|
var s = String.fromCharCode(i ?? a);
|
|
4668
|
-
s != "\b" && (
|
|
4668
|
+
s != "\b" && (Rd(n, e, s) || n.display.input.onKeyPress(e));
|
|
4669
4669
|
}
|
|
4670
4670
|
}
|
|
4671
4671
|
}
|
|
4672
|
-
var
|
|
4672
|
+
var $d = 400, Cs = function(e, n, a) {
|
|
4673
4673
|
this.time = e, this.pos = n, this.button = a;
|
|
4674
4674
|
};
|
|
4675
4675
|
Cs.prototype.compare = function(e, n, a) {
|
|
4676
|
-
return this.time +
|
|
4676
|
+
return this.time + $d > e && re(n, this.pos) == 0 && a == this.button;
|
|
4677
4677
|
};
|
|
4678
4678
|
var xi, wi;
|
|
4679
|
-
function
|
|
4679
|
+
function Md(e, n) {
|
|
4680
4680
|
var a = +/* @__PURE__ */ new Date();
|
|
4681
4681
|
return wi && wi.compare(a, e, n) ? (xi = wi = null, "triple") : xi && xi.compare(a, e, n) ? (wi = new Cs(a, e, n), xi = null, "double") : (xi = new Cs(a, e, n), wi = null, "single");
|
|
4682
4682
|
}
|
|
@@ -4690,14 +4690,14 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
4690
4690
|
return;
|
|
4691
4691
|
}
|
|
4692
4692
|
if (!Ts(n, e)) {
|
|
4693
|
-
var i = Xn(n, e), s = tn(e), c = i ?
|
|
4694
|
-
Z(n).focus(), s == 1 && n.state.selectingText && n.state.selectingText(e), !(i &&
|
|
4693
|
+
var i = Xn(n, e), s = tn(e), c = i ? Md(i, s) : "single";
|
|
4694
|
+
Z(n).focus(), s == 1 && n.state.selectingText && n.state.selectingText(e), !(i && Pd(n, s, i, c, e)) && (s == 1 ? i ? Bd(n, i, c, e) : Gr(e) == a.scroller && Ct(e) : s == 2 ? (i && ia(n.doc, i), setTimeout(function() {
|
|
4695
4695
|
return a.input.focus();
|
|
4696
4696
|
}, 20)) : s == 3 && (Re ? n.display.input.onContextMenu(e) : as(n)));
|
|
4697
4697
|
}
|
|
4698
4698
|
}
|
|
4699
4699
|
}
|
|
4700
|
-
function
|
|
4700
|
+
function Pd(e, n, a, i, s) {
|
|
4701
4701
|
var c = "Click";
|
|
4702
4702
|
return i == "double" ? c = "Double" + c : i == "triple" && (c = "Triple" + c), c = (n == 1 ? "Left" : n == 2 ? "Middle" : "Right") + c, bi(e, Wl(c, s), s, function(d) {
|
|
4703
4703
|
if (typeof d == "string" && (d = yi[d]), !d)
|
|
@@ -4711,7 +4711,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
4711
4711
|
return p;
|
|
4712
4712
|
});
|
|
4713
4713
|
}
|
|
4714
|
-
function
|
|
4714
|
+
function zd(e, n, a) {
|
|
4715
4715
|
var i = e.getOption("configureMouse"), s = i ? i(e, n, a) : {};
|
|
4716
4716
|
if (s.unit == null) {
|
|
4717
4717
|
var c = ue ? a.shiftKey && a.metaKey : a.altKey;
|
|
@@ -4719,12 +4719,12 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
4719
4719
|
}
|
|
4720
4720
|
return (s.extend == null || e.doc.extend) && (s.extend = e.doc.extend || a.shiftKey), s.addNew == null && (s.addNew = ne ? a.metaKey : a.ctrlKey), s.moveOnDrag == null && (s.moveOnDrag = !(ne ? a.altKey : a.ctrlKey)), s;
|
|
4721
4721
|
}
|
|
4722
|
-
function
|
|
4722
|
+
function Bd(e, n, a, i) {
|
|
4723
4723
|
m ? setTimeout(fe(Yo, e), 0) : e.curOp.focus = $(oe(e));
|
|
4724
|
-
var s =
|
|
4725
|
-
e.options.dragDrop && Ma && !e.isReadOnly() && a == "single" && (d = c.contains(n)) > -1 && (re((d = c.ranges[d]).from(), n) < 0 || n.xRel > 0) && (re(d.to(), n) > 0 || n.xRel < 0) ?
|
|
4724
|
+
var s = zd(e, a, i), c = e.doc.sel, d;
|
|
4725
|
+
e.options.dragDrop && Ma && !e.isReadOnly() && a == "single" && (d = c.contains(n)) > -1 && (re((d = c.ranges[d]).from(), n) < 0 || n.xRel > 0) && (re(d.to(), n) > 0 || n.xRel < 0) ? Hd(e, i, n, s) : Wd(e, i, n, s);
|
|
4726
4726
|
}
|
|
4727
|
-
function
|
|
4727
|
+
function Hd(e, n, a, i) {
|
|
4728
4728
|
var s = e.display, c = !1, d = mt(e, function(y) {
|
|
4729
4729
|
S && (s.scroller.draggable = !1), e.state.draggingText = !1, e.state.delayingBlurEvent && (e.hasFocus() ? e.state.delayingBlurEvent = !1 : as(e)), St(s.wrapper.ownerDocument, "mouseup", d), St(s.wrapper.ownerDocument, "mousemove", p), St(s.scroller, "dragstart", g), St(s.scroller, "drop", d), c || (Ct(y), i.addNew || ia(e.doc, a, null, null, i.extend), S && !O || m && x == 9 ? setTimeout(function() {
|
|
4730
4730
|
s.wrapper.ownerDocument.body.focus({ preventScroll: !0 }), s.input.focus();
|
|
@@ -4748,7 +4748,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
4748
4748
|
var i = a(e, n);
|
|
4749
4749
|
return new ze(i.from, i.to);
|
|
4750
4750
|
}
|
|
4751
|
-
function
|
|
4751
|
+
function Wd(e, n, a, i) {
|
|
4752
4752
|
m && as(e);
|
|
4753
4753
|
var s = e.display, c = e.doc;
|
|
4754
4754
|
Ct(n);
|
|
@@ -4785,7 +4785,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
4785
4785
|
var Rt = d, kt = Yl(e, te, i.unit), dt = Rt.anchor, st;
|
|
4786
4786
|
re(kt.anchor, dt) > 0 ? (st = kt.head, dt = vr(Rt.from(), kt.anchor)) : (st = kt.anchor, dt = It(Rt.to(), kt.head));
|
|
4787
4787
|
var tt = g.ranges.slice(0);
|
|
4788
|
-
tt[p] =
|
|
4788
|
+
tt[p] = jd(e, new ze(Ce(c, dt), st)), Tt(c, ln(e, tt, p), Mt);
|
|
4789
4789
|
}
|
|
4790
4790
|
}
|
|
4791
4791
|
var D = s.wrapper.getBoundingClientRect(), B = 0;
|
|
@@ -4813,7 +4813,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
4813
4813
|
}), ae = mt(e, X);
|
|
4814
4814
|
e.state.selectingText = ae, me(s.wrapper.ownerDocument, "mousemove", ee), me(s.wrapper.ownerDocument, "mouseup", ae);
|
|
4815
4815
|
}
|
|
4816
|
-
function
|
|
4816
|
+
function jd(e, n) {
|
|
4817
4817
|
var a = n.anchor, i = n.head, s = ce(e.doc, a.line);
|
|
4818
4818
|
if (re(a, i) == 0 && a.sticky == i.sticky)
|
|
4819
4819
|
return n;
|
|
@@ -4865,9 +4865,9 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
4865
4865
|
return Zl(e, n, "gutterClick", !0);
|
|
4866
4866
|
}
|
|
4867
4867
|
function eu(e, n) {
|
|
4868
|
-
Cn(e.display, n) ||
|
|
4868
|
+
Cn(e.display, n) || qd(e, n) || Ze(e, n, "contextmenu") || Re || e.display.input.onContextMenu(n);
|
|
4869
4869
|
}
|
|
4870
|
-
function
|
|
4870
|
+
function qd(e, n) {
|
|
4871
4871
|
return zt(e, "gutterContextMenu") ? Zl(e, n, "gutterContextMenu", !1) : !1;
|
|
4872
4872
|
}
|
|
4873
4873
|
function tu(e) {
|
|
@@ -4876,7 +4876,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
4876
4876
|
var Nr = { toString: function() {
|
|
4877
4877
|
return "CodeMirror.Init";
|
|
4878
4878
|
} }, nu = {}, fa = {};
|
|
4879
|
-
function
|
|
4879
|
+
function Ud(e) {
|
|
4880
4880
|
var n = e.optionHandlers;
|
|
4881
4881
|
function a(i, s, c, d) {
|
|
4882
4882
|
e.defaults[i] = s, c && (n[i] = d ? function(p, g, y) {
|
|
@@ -4906,7 +4906,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
4906
4906
|
}
|
|
4907
4907
|
}), a("specialChars", /[\u0000-\u001f\u007f-\u009f\u00ad\u061c\u200b\u200e\u200f\u2028\u2029\u202d\u202e\u2066\u2067\u2069\ufeff\ufff9-\ufffc]/g, function(i, s, c) {
|
|
4908
4908
|
i.state.specialChars = new RegExp(s.source + (s.test(" ") ? "" : "| "), "g"), c != Nr && i.refresh();
|
|
4909
|
-
}), a("specialCharPlaceholder",
|
|
4909
|
+
}), a("specialCharPlaceholder", xf, function(i) {
|
|
4910
4910
|
return i.refresh();
|
|
4911
4911
|
}, !0), a("electricChars", !0), a("inputStyle", V ? "contenteditable" : "textarea", function() {
|
|
4912
4912
|
throw new Error("inputStyle can not (yet) be changed in a running editor");
|
|
@@ -4921,7 +4921,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
4921
4921
|
}, !0), a("keyMap", "default", function(i, s, c) {
|
|
4922
4922
|
var d = ua(s), p = c != Nr && ua(c);
|
|
4923
4923
|
p && p.detach && p.detach(i, d), d.attach && d.attach(i, p || null);
|
|
4924
|
-
}), a("extraKeys", null), a("configureMouse", null), a("lineWrapping", !1,
|
|
4924
|
+
}), a("extraKeys", null), a("configureMouse", null), a("lineWrapping", !1, Kd, !0), a("gutters", [], function(i, s) {
|
|
4925
4925
|
i.display.gutterSpecs = hs(s, i.options.lineNumbers), li(i);
|
|
4926
4926
|
}, !0), a("fixedGutter", !0, function(i, s) {
|
|
4927
4927
|
i.display.gutters.style.left = s ? ts(i.display) + "px" : "0", i.refresh();
|
|
@@ -4939,7 +4939,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
4939
4939
|
s = s === "" ? null : s, i.display.input.screenReaderLabelChanged(s);
|
|
4940
4940
|
}), a("disableInput", !1, function(i, s) {
|
|
4941
4941
|
s || i.display.input.reset();
|
|
4942
|
-
}, !0), a("dragDrop", !0,
|
|
4942
|
+
}, !0), a("dragDrop", !0, Gd), a("allowDropFileTypes", null), a("cursorBlinkRate", 530), a("cursorScrollMargin", 0), a("cursorHeight", 1, ni, !0), a("singleCursorHeightPerLine", !0, ni, !0), a("workTime", 100), a("workDelay", 100), a("flattenSpans", !0, ui, !0), a("addModeClass", !1, ui, !0), a("pollInterval", 100), a("undoDepth", 200, function(i, s) {
|
|
4943
4943
|
return i.doc.history.undoDepth = s;
|
|
4944
4944
|
}), a("historyEventDelay", 1250), a("viewportMargin", 10, function(i) {
|
|
4945
4945
|
return i.refresh();
|
|
@@ -4951,14 +4951,14 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
4951
4951
|
return i.doc.setDirection(s);
|
|
4952
4952
|
}, !0), a("phrases", null);
|
|
4953
4953
|
}
|
|
4954
|
-
function
|
|
4954
|
+
function Gd(e, n, a) {
|
|
4955
4955
|
var i = a && a != Nr;
|
|
4956
4956
|
if (!n != !i) {
|
|
4957
4957
|
var s = e.display.dragFunctions, c = n ? me : St;
|
|
4958
4958
|
c(e.display.scroller, "dragstart", s.start), c(e.display.scroller, "dragenter", s.enter), c(e.display.scroller, "dragover", s.over), c(e.display.scroller, "dragleave", s.leave), c(e.display.scroller, "drop", s.drop);
|
|
4959
4959
|
}
|
|
4960
4960
|
}
|
|
4961
|
-
function
|
|
4961
|
+
function Kd(e) {
|
|
4962
4962
|
e.options.lineWrapping ? (K(e.display.wrapper, "CodeMirror-wrap"), e.display.sizer.style.minWidth = "", e.display.sizerWidth = null) : (Me(e.display.wrapper, "CodeMirror-wrap"), Ua(e)), ns(e), Ot(e), ti(e), setTimeout(function() {
|
|
4963
4963
|
return Tr(e);
|
|
4964
4964
|
}, 100);
|
|
@@ -4970,7 +4970,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
4970
4970
|
this.options = n = n ? ke(n) : {}, ke(nu, n, !1);
|
|
4971
4971
|
var i = n.value;
|
|
4972
4972
|
typeof i == "string" ? i = new Dt(i, n.mode, null, n.lineSeparator, n.direction) : n.mode && (i.modeOption = n.mode), this.doc = i;
|
|
4973
|
-
var s = new Ve.inputStyles[n.inputStyle](this), c = this.display = new
|
|
4973
|
+
var s = new Ve.inputStyles[n.inputStyle](this), c = this.display = new sd(e, i, s, n);
|
|
4974
4974
|
c.wrapper.CodeMirror = this, tu(this), n.lineWrapping && (this.display.wrapper.className += " CodeMirror-wrap"), il(this), this.state = {
|
|
4975
4975
|
keyMaps: [],
|
|
4976
4976
|
// stores maps added by addKeyMap
|
|
@@ -4995,7 +4995,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
4995
4995
|
specialChars: null
|
|
4996
4996
|
}, n.autofocus && !V && c.input.focus(), m && x < 11 && setTimeout(function() {
|
|
4997
4997
|
return a.display.input.reset(!0);
|
|
4998
|
-
}, 20),
|
|
4998
|
+
}, 20), Vd(this), Td(), er(this), this.curOp.forceUpdate = !0, pl(this, i), n.autofocus && !V || this.hasFocus() ? setTimeout(function() {
|
|
4999
4999
|
a.hasFocus() && !a.state.focused && ss(a);
|
|
5000
5000
|
}, 20) : Sr(this);
|
|
5001
5001
|
for (var d in fa)
|
|
@@ -5006,7 +5006,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
5006
5006
|
tr(this), S && n.lineWrapping && getComputedStyle(c.lineDiv).textRendering == "optimizelegibility" && (c.lineDiv.style.textRendering = "auto");
|
|
5007
5007
|
}
|
|
5008
5008
|
Ve.defaults = nu, Ve.optionHandlers = fa;
|
|
5009
|
-
function
|
|
5009
|
+
function Vd(e) {
|
|
5010
5010
|
var n = e.display;
|
|
5011
5011
|
me(n.scroller, "mousedown", mt(e, Jl)), m && x < 11 ? me(n.scroller, "dblclick", mt(e, function(g) {
|
|
5012
5012
|
if (!Ze(e, g)) {
|
|
@@ -5074,12 +5074,12 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
5074
5074
|
Ze(e, g) || Dn(g);
|
|
5075
5075
|
},
|
|
5076
5076
|
over: function(g) {
|
|
5077
|
-
Ze(e, g) || (
|
|
5077
|
+
Ze(e, g) || (Cd(e, g), Dn(g));
|
|
5078
5078
|
},
|
|
5079
5079
|
start: function(g) {
|
|
5080
|
-
return
|
|
5080
|
+
return Sd(e, g);
|
|
5081
5081
|
},
|
|
5082
|
-
drop: mt(e,
|
|
5082
|
+
drop: mt(e, kd),
|
|
5083
5083
|
leave: function(g) {
|
|
5084
5084
|
Ze(e, g) || Pl(e);
|
|
5085
5085
|
}
|
|
@@ -5198,7 +5198,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
5198
5198
|
var e = k("textarea", null, null, "position: absolute; bottom: -1em; padding: 0; width: 1px; height: 1em; min-height: 1em; outline: none"), n = k("div", [e], null, "overflow: hidden; position: relative; width: 3px; height: 0px;");
|
|
5199
5199
|
return S ? e.style.width = "1000px" : e.setAttribute("wrap", "off"), N && (e.style.border = "1px solid black"), n;
|
|
5200
5200
|
}
|
|
5201
|
-
function
|
|
5201
|
+
function Qd(e) {
|
|
5202
5202
|
var n = e.optionHandlers, a = e.helpers = {};
|
|
5203
5203
|
e.prototype = {
|
|
5204
5204
|
constructor: e,
|
|
@@ -5366,7 +5366,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
5366
5366
|
var _ = Math.max(g.wrapper.clientHeight, this.doc.height), F = Math.max(g.sizer.clientWidth, g.lineSpace.clientWidth);
|
|
5367
5367
|
(d == "above" || i.bottom + s.offsetHeight > _) && i.top > s.offsetHeight ? y = i.top - s.offsetHeight : i.bottom + s.offsetHeight <= _ && (y = i.bottom), C + s.offsetWidth > F && (C = F - s.offsetWidth);
|
|
5368
5368
|
}
|
|
5369
|
-
s.style.top = y + "px", s.style.left = s.style.right = "", p == "right" ? (C = g.sizer.clientWidth - s.offsetWidth, s.style.right = "0px") : (p == "left" ? C = 0 : p == "middle" && (C = (g.sizer.clientWidth - s.offsetWidth) / 2), s.style.left = C + "px"), c &&
|
|
5369
|
+
s.style.top = y + "px", s.style.left = s.style.right = "", p == "right" ? (C = g.sizer.clientWidth - s.offsetWidth, s.style.right = "0px") : (p == "left" ? C = 0 : p == "middle" && (C = (g.sizer.clientWidth - s.offsetWidth) / 2), s.style.left = C + "px"), c && Gf(this, { left: C, top: y, right: C + s.offsetWidth, bottom: y + s.offsetHeight });
|
|
5370
5370
|
},
|
|
5371
5371
|
triggerOnKeyDown: Lt(Vl),
|
|
5372
5372
|
triggerOnKeyPress: Lt(Xl),
|
|
@@ -5465,7 +5465,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
5465
5465
|
};
|
|
5466
5466
|
},
|
|
5467
5467
|
scrollIntoView: Lt(function(i, s) {
|
|
5468
|
-
i == null ? (i = { from: this.doc.sel.primary().head, to: null }, s == null && (s = this.options.cursorScrollMargin)) : typeof i == "number" ? i = { from: P(i, 0), to: null } : i.from == null && (i = { from: i, to: null }), i.to || (i.to = i.from), i.margin = s || 0, i.from.line != null ?
|
|
5468
|
+
i == null ? (i = { from: this.doc.sel.primary().head, to: null }, s == null && (s = this.options.cursorScrollMargin)) : typeof i == "number" ? i = { from: P(i, 0), to: null } : i.from == null && (i = { from: i, to: null }), i.to || (i.to = i.from), i.margin = s || 0, i.from.line != null ? Kf(this, i) : el(this, i.from, i.to, i.margin);
|
|
5469
5469
|
}),
|
|
5470
5470
|
setSize: Lt(function(i, s) {
|
|
5471
5471
|
var c = this, d = function(g) {
|
|
@@ -5539,7 +5539,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
5539
5539
|
var ve = a > 0 ? le >= 55296 && le < 56320 : le >= 56320 && le < 57343;
|
|
5540
5540
|
te = new P(n.line, Math.max(0, Math.min(p.text.length, n.ch + a * (ve ? 2 : 1))), -a);
|
|
5541
5541
|
}
|
|
5542
|
-
} else s ? te =
|
|
5542
|
+
} else s ? te = Id(e.cm, p, n, a) : te = ws(p, n, a);
|
|
5543
5543
|
if (te == null)
|
|
5544
5544
|
if (!ae && y())
|
|
5545
5545
|
n = ks(s, e.cm, p, n.line, g);
|
|
@@ -5719,7 +5719,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
5719
5719
|
}, He.prototype.pollSelection = function() {
|
|
5720
5720
|
if (!(this.readDOMTimeout != null || this.gracePeriod || !this.selectionChanged())) {
|
|
5721
5721
|
var e = this.getSelection(), n = this.cm;
|
|
5722
|
-
if (H && L && this.cm.display.gutterSpecs.length &&
|
|
5722
|
+
if (H && L && this.cm.display.gutterSpecs.length && Xd(e.anchorNode)) {
|
|
5723
5723
|
this.cm.triggerOnKeyDown({ type: "keydown", keyCode: 8, preventDefault: Math.abs }), this.blur(), this.focus();
|
|
5724
5724
|
return;
|
|
5725
5725
|
}
|
|
@@ -5741,7 +5741,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
5741
5741
|
var g = Jn(e, s.line), y, C;
|
|
5742
5742
|
if (g == n.view.length - 1 ? (y = n.viewTo - 1, C = n.lineDiv.lastChild) : (y = b(n.view[g + 1].line) - 1, C = n.view[g + 1].node.previousSibling), !p)
|
|
5743
5743
|
return !1;
|
|
5744
|
-
for (var _ = e.doc.splitLines(
|
|
5744
|
+
for (var _ = e.doc.splitLines(Jd(e, p, C, d, y)), F = wn(e.doc, P(d, 0), P(y, ce(e.doc, y).text.length)); _.length > 1 && F.length > 1; )
|
|
5745
5745
|
if (be(_) == be(F))
|
|
5746
5746
|
_.pop(), F.pop(), y--;
|
|
5747
5747
|
else if (_[0] == F[0])
|
|
@@ -5804,7 +5804,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
5804
5804
|
var g = Bo(s.map, n.ch, d);
|
|
5805
5805
|
return g.offset = g.collapse == "right" ? g.end : g.start, g;
|
|
5806
5806
|
}
|
|
5807
|
-
function
|
|
5807
|
+
function Xd(e) {
|
|
5808
5808
|
for (var n = e; n; n = n.parentNode)
|
|
5809
5809
|
if (/CodeMirror-gutter-wrapper/.test(n.className))
|
|
5810
5810
|
return !0;
|
|
@@ -5813,7 +5813,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
5813
5813
|
function Rr(e, n) {
|
|
5814
5814
|
return n && (e.bad = !0), e;
|
|
5815
5815
|
}
|
|
5816
|
-
function
|
|
5816
|
+
function Jd(e, n, a, i, s) {
|
|
5817
5817
|
var c = "", d = !1, p = e.doc.lineSeparator(), g = !1;
|
|
5818
5818
|
function y(D) {
|
|
5819
5819
|
return function(B) {
|
|
@@ -5870,10 +5870,10 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
5870
5870
|
for (var s = 0; s < e.display.view.length; s++) {
|
|
5871
5871
|
var c = e.display.view[s];
|
|
5872
5872
|
if (c.node == i)
|
|
5873
|
-
return
|
|
5873
|
+
return Yd(c, n, a);
|
|
5874
5874
|
}
|
|
5875
5875
|
}
|
|
5876
|
-
function
|
|
5876
|
+
function Yd(e, n, a) {
|
|
5877
5877
|
var i = e.text.firstChild, s = !1;
|
|
5878
5878
|
if (!n || !I(i, n))
|
|
5879
5879
|
return Rr(P(b(e.line), 0), !0);
|
|
@@ -6091,7 +6091,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
6091
6091
|
e || this.reset(), this.textarea.disabled = e == "nocursor", this.textarea.readOnly = !!e;
|
|
6092
6092
|
}, rt.prototype.setUneditable = function() {
|
|
6093
6093
|
}, rt.prototype.needsContentAttribute = !1;
|
|
6094
|
-
function
|
|
6094
|
+
function Zd(e, n) {
|
|
6095
6095
|
if (n = n ? ke(n) : {}, n.value = e.value, !n.tabindex && e.tabIndex && (n.tabindex = e.tabIndex), !n.placeholder && e.placeholder && (n.placeholder = e.placeholder), n.autofocus == null) {
|
|
6096
6096
|
var a = $(Te(e));
|
|
6097
6097
|
n.autofocus = a == e || e.getAttribute("autofocus") != null && a == document.body;
|
|
@@ -6125,13 +6125,13 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
6125
6125
|
);
|
|
6126
6126
|
return p;
|
|
6127
6127
|
}
|
|
6128
|
-
function
|
|
6129
|
-
e.off = St, e.on = me, e.wheelEventPixels =
|
|
6128
|
+
function eh(e) {
|
|
6129
|
+
e.off = St, e.on = me, e.wheelEventPixels = od, e.Doc = Dt, e.splitLines = Jt, e.countColumn = _e, e.findColumn = ft, e.isWordChar = ye, e.Pass = qe, e.signal = Ye, e.Line = yr, e.changeEnd = Bn, e.scrollbarModel = rl, e.Pos = P, e.cmpPos = re, e.modes = dr, e.mimeModes = rn, e.resolveMode = hr, e.getMode = pr, e.modeExtensions = Fn, e.extendMode = gr, e.copyState = hn, e.startState = mr, e.innerMode = Vr, e.commands = yi, e.keyMap = _n, e.keyName = jl, e.isModifierKey = Hl, e.lookupKey = Or, e.normalizeKeyMap = Ad, e.StringStream = et, e.SharedTextMarker = gi, e.TextMarker = Wn, e.LineWidget = pi, e.e_preventDefault = Ct, e.e_stopPropagation = cr, e.e_stop = Dn, e.addClass = K, e.contains = I, e.rmClass = Me, e.keyNames = jn;
|
|
6130
6130
|
}
|
|
6131
|
-
|
|
6132
|
-
var
|
|
6131
|
+
Ud(Ve), Qd(Ve);
|
|
6132
|
+
var th = "iter insert remove copy getEditor constructor".split(" ");
|
|
6133
6133
|
for (var pa in Dt.prototype)
|
|
6134
|
-
Dt.prototype.hasOwnProperty(pa) && we(
|
|
6134
|
+
Dt.prototype.hasOwnProperty(pa) && we(th, pa) < 0 && (Ve.prototype[pa] = /* @__PURE__ */ function(e) {
|
|
6135
6135
|
return function() {
|
|
6136
6136
|
return e.apply(this.doc, arguments);
|
|
6137
6137
|
};
|
|
@@ -6146,7 +6146,7 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
6146
6146
|
Ve.prototype[e] = n;
|
|
6147
6147
|
}, Ve.defineDocExtension = function(e, n) {
|
|
6148
6148
|
Dt.prototype[e] = n;
|
|
6149
|
-
}, Ve.fromTextArea =
|
|
6149
|
+
}, Ve.fromTextArea = Zd, eh(Ve), Ve.version = "5.65.20", Ve;
|
|
6150
6150
|
});
|
|
6151
6151
|
}(Ds)), Ds.exports;
|
|
6152
6152
|
}
|
|
@@ -7066,118 +7066,120 @@ b`.split(/\n/).length != 3 ? function(e) {
|
|
|
7066
7066
|
});
|
|
7067
7067
|
});
|
|
7068
7068
|
})();
|
|
7069
|
-
var
|
|
7070
|
-
|
|
7071
|
-
(function(
|
|
7072
|
-
|
|
7073
|
-
|
|
7074
|
-
function
|
|
7075
|
-
|
|
7076
|
-
|
|
7077
|
-
|
|
7078
|
-
|
|
7079
|
-
|
|
7080
|
-
|
|
7081
|
-
|
|
7082
|
-
|
|
7083
|
-
|
|
7084
|
-
|
|
7085
|
-
|
|
7086
|
-
|
|
7087
|
-
|
|
7088
|
-
if (
|
|
7089
|
-
|
|
7090
|
-
|
|
7091
|
-
|
|
7092
|
-
|
|
7093
|
-
|
|
7094
|
-
|
|
7095
|
-
|
|
7096
|
-
|
|
7097
|
-
|
|
7098
|
-
|
|
7099
|
-
|
|
7069
|
+
var du = { exports: {} }, hu;
|
|
7070
|
+
function dc() {
|
|
7071
|
+
return hu || (hu = 1, function(o, t) {
|
|
7072
|
+
(function(r) {
|
|
7073
|
+
r(Vt());
|
|
7074
|
+
})(function(r) {
|
|
7075
|
+
function l(v, m, x, S) {
|
|
7076
|
+
if (x && x.call) {
|
|
7077
|
+
var R = x;
|
|
7078
|
+
x = null;
|
|
7079
|
+
} else
|
|
7080
|
+
var R = h(v, x, "rangeFinder");
|
|
7081
|
+
typeof m == "number" && (m = r.Pos(m, 0));
|
|
7082
|
+
var L = h(v, x, "minFoldSize");
|
|
7083
|
+
function W(A) {
|
|
7084
|
+
var N = R(v, m);
|
|
7085
|
+
if (!N || N.to.line - N.from.line < L) return null;
|
|
7086
|
+
if (S === "fold") return N;
|
|
7087
|
+
for (var H = v.findMarksAt(N.from), V = 0; V < H.length; ++V)
|
|
7088
|
+
if (H[V].__isFold) {
|
|
7089
|
+
if (!A) return null;
|
|
7090
|
+
N.cleared = !0, H[V].clear();
|
|
7091
|
+
}
|
|
7092
|
+
return N;
|
|
7093
|
+
}
|
|
7094
|
+
var z = W(!0);
|
|
7095
|
+
if (h(v, x, "scanUp")) for (; !z && m.line > v.firstLine(); )
|
|
7096
|
+
m = r.Pos(m.line - 1, 0), z = W(!1);
|
|
7097
|
+
if (!(!z || z.cleared || S === "unfold")) {
|
|
7098
|
+
var O = u(v, x, z);
|
|
7099
|
+
r.on(O, "mousedown", function(A) {
|
|
7100
|
+
M.clear(), r.e_preventDefault(A);
|
|
7101
|
+
});
|
|
7102
|
+
var M = v.markText(z.from, z.to, {
|
|
7103
|
+
replacedWith: O,
|
|
7104
|
+
clearOnEnter: h(v, x, "clearOnEnter"),
|
|
7105
|
+
__isFold: !0
|
|
7106
|
+
});
|
|
7107
|
+
M.on("clear", function(A, N) {
|
|
7108
|
+
r.signal(v, "unfold", v, A, N);
|
|
7109
|
+
}), r.signal(v, "fold", v, z.from, z.to);
|
|
7110
|
+
}
|
|
7111
|
+
}
|
|
7112
|
+
function u(v, m, x) {
|
|
7113
|
+
var S = h(v, m, "widget");
|
|
7114
|
+
if (typeof S == "function" && (S = S(x.from, x.to)), typeof S == "string") {
|
|
7115
|
+
var R = document.createTextNode(S);
|
|
7116
|
+
S = document.createElement("span"), S.appendChild(R), S.className = "CodeMirror-foldmarker";
|
|
7117
|
+
} else S && (S = S.cloneNode(!0));
|
|
7118
|
+
return S;
|
|
7119
|
+
}
|
|
7120
|
+
r.newFoldFunction = function(v, m) {
|
|
7121
|
+
return function(x, S) {
|
|
7122
|
+
l(x, S, { rangeFinder: v, widget: m });
|
|
7123
|
+
};
|
|
7124
|
+
}, r.defineExtension("foldCode", function(v, m, x) {
|
|
7125
|
+
l(this, v, m, x);
|
|
7126
|
+
}), r.defineExtension("isFolded", function(v) {
|
|
7127
|
+
for (var m = this.findMarksAt(v), x = 0; x < m.length; ++x)
|
|
7128
|
+
if (m[x].__isFold) return !0;
|
|
7129
|
+
}), r.commands.toggleFold = function(v) {
|
|
7130
|
+
v.foldCode(v.getCursor());
|
|
7131
|
+
}, r.commands.fold = function(v) {
|
|
7132
|
+
v.foldCode(v.getCursor(), null, "fold");
|
|
7133
|
+
}, r.commands.unfold = function(v) {
|
|
7134
|
+
v.foldCode(v.getCursor(), { scanUp: !1 }, "unfold");
|
|
7135
|
+
}, r.commands.foldAll = function(v) {
|
|
7136
|
+
v.operation(function() {
|
|
7137
|
+
for (var m = v.firstLine(), x = v.lastLine(); m <= x; m++)
|
|
7138
|
+
v.foldCode(r.Pos(m, 0), { scanUp: !1 }, "fold");
|
|
7100
7139
|
});
|
|
7101
|
-
|
|
7102
|
-
|
|
7103
|
-
|
|
7104
|
-
|
|
7140
|
+
}, r.commands.unfoldAll = function(v) {
|
|
7141
|
+
v.operation(function() {
|
|
7142
|
+
for (var m = v.firstLine(), x = v.lastLine(); m <= x; m++)
|
|
7143
|
+
v.foldCode(r.Pos(m, 0), { scanUp: !1 }, "unfold");
|
|
7105
7144
|
});
|
|
7106
|
-
|
|
7107
|
-
|
|
7108
|
-
|
|
7109
|
-
|
|
7110
|
-
|
|
7111
|
-
|
|
7112
|
-
|
|
7113
|
-
|
|
7114
|
-
|
|
7115
|
-
|
|
7116
|
-
|
|
7117
|
-
return S;
|
|
7118
|
-
}
|
|
7119
|
-
r.newFoldFunction = function(v, m) {
|
|
7120
|
-
return function(x, S) {
|
|
7121
|
-
l(x, S, { rangeFinder: v, widget: m });
|
|
7122
|
-
};
|
|
7123
|
-
}, r.defineExtension("foldCode", function(v, m, x) {
|
|
7124
|
-
l(this, v, m, x);
|
|
7125
|
-
}), r.defineExtension("isFolded", function(v) {
|
|
7126
|
-
for (var m = this.findMarksAt(v), x = 0; x < m.length; ++x)
|
|
7127
|
-
if (m[x].__isFold) return !0;
|
|
7128
|
-
}), r.commands.toggleFold = function(v) {
|
|
7129
|
-
v.foldCode(v.getCursor());
|
|
7130
|
-
}, r.commands.fold = function(v) {
|
|
7131
|
-
v.foldCode(v.getCursor(), null, "fold");
|
|
7132
|
-
}, r.commands.unfold = function(v) {
|
|
7133
|
-
v.foldCode(v.getCursor(), { scanUp: !1 }, "unfold");
|
|
7134
|
-
}, r.commands.foldAll = function(v) {
|
|
7135
|
-
v.operation(function() {
|
|
7136
|
-
for (var m = v.firstLine(), x = v.lastLine(); m <= x; m++)
|
|
7137
|
-
v.foldCode(r.Pos(m, 0), { scanUp: !1 }, "fold");
|
|
7138
|
-
});
|
|
7139
|
-
}, r.commands.unfoldAll = function(v) {
|
|
7140
|
-
v.operation(function() {
|
|
7141
|
-
for (var m = v.firstLine(), x = v.lastLine(); m <= x; m++)
|
|
7142
|
-
v.foldCode(r.Pos(m, 0), { scanUp: !1 }, "unfold");
|
|
7143
|
-
});
|
|
7144
|
-
}, r.registerHelper("fold", "combine", function() {
|
|
7145
|
-
var v = Array.prototype.slice.call(arguments, 0);
|
|
7146
|
-
return function(m, x) {
|
|
7147
|
-
for (var S = 0; S < v.length; ++S) {
|
|
7148
|
-
var R = v[S](m, x);
|
|
7145
|
+
}, r.registerHelper("fold", "combine", function() {
|
|
7146
|
+
var v = Array.prototype.slice.call(arguments, 0);
|
|
7147
|
+
return function(m, x) {
|
|
7148
|
+
for (var S = 0; S < v.length; ++S) {
|
|
7149
|
+
var R = v[S](m, x);
|
|
7150
|
+
if (R) return R;
|
|
7151
|
+
}
|
|
7152
|
+
};
|
|
7153
|
+
}), r.registerHelper("fold", "auto", function(v, m) {
|
|
7154
|
+
for (var x = v.getHelpers(m, "fold"), S = 0; S < x.length; S++) {
|
|
7155
|
+
var R = x[S](v, m);
|
|
7149
7156
|
if (R) return R;
|
|
7150
7157
|
}
|
|
7158
|
+
});
|
|
7159
|
+
var f = {
|
|
7160
|
+
rangeFinder: r.fold.auto,
|
|
7161
|
+
widget: "↔",
|
|
7162
|
+
minFoldSize: 0,
|
|
7163
|
+
scanUp: !1,
|
|
7164
|
+
clearOnEnter: !0
|
|
7151
7165
|
};
|
|
7152
|
-
|
|
7153
|
-
|
|
7154
|
-
|
|
7155
|
-
|
|
7156
|
-
|
|
7157
|
-
|
|
7158
|
-
|
|
7159
|
-
|
|
7160
|
-
|
|
7161
|
-
|
|
7162
|
-
scanUp: !1,
|
|
7163
|
-
clearOnEnter: !0
|
|
7164
|
-
};
|
|
7165
|
-
r.defineOption("foldOptions", null);
|
|
7166
|
-
function h(v, m, x) {
|
|
7167
|
-
if (m && m[x] !== void 0)
|
|
7168
|
-
return m[x];
|
|
7169
|
-
var S = v.options.foldOptions;
|
|
7170
|
-
return S && S[x] !== void 0 ? S[x] : f[x];
|
|
7171
|
-
}
|
|
7172
|
-
r.defineExtension("foldOption", function(v, m) {
|
|
7173
|
-
return h(this, v, m);
|
|
7166
|
+
r.defineOption("foldOptions", null);
|
|
7167
|
+
function h(v, m, x) {
|
|
7168
|
+
if (m && m[x] !== void 0)
|
|
7169
|
+
return m[x];
|
|
7170
|
+
var S = v.options.foldOptions;
|
|
7171
|
+
return S && S[x] !== void 0 ? S[x] : f[x];
|
|
7172
|
+
}
|
|
7173
|
+
r.defineExtension("foldOption", function(v, m) {
|
|
7174
|
+
return h(this, v, m);
|
|
7175
|
+
});
|
|
7174
7176
|
});
|
|
7175
|
-
});
|
|
7176
|
-
}
|
|
7177
|
-
|
|
7177
|
+
}()), du.exports;
|
|
7178
|
+
}
|
|
7179
|
+
dc();
|
|
7178
7180
|
(function(o, t) {
|
|
7179
7181
|
(function(r) {
|
|
7180
|
-
r(Vt(),
|
|
7182
|
+
r(Vt(), dc());
|
|
7181
7183
|
})(function(r) {
|
|
7182
7184
|
r.defineOption("foldGutter", !1, function(M, A, N) {
|
|
7183
7185
|
N && N != r.Init && (M.clearGutter(M.state.foldGutter.options.gutter), M.state.foldGutter = null, M.off("gutterClick", R), M.off("changes", W), M.off("viewportChange", z), M.off("fold", O), M.off("unfold", O), M.off("swapDoc", W), M.off("optionChange", L)), A && (M.state.foldGutter = new u(f(A)), S(M), M.on("gutterClick", R), M.on("changes", W), M.on("viewportChange", z), M.on("fold", O), M.on("unfold", O), M.on("swapDoc", W), M.on("optionChange", L));
|
|
@@ -7413,7 +7415,7 @@ var lh = oh.exports;
|
|
|
7413
7415
|
}
|
|
7414
7416
|
});
|
|
7415
7417
|
})();
|
|
7416
|
-
const
|
|
7418
|
+
const ch = ah("trace", {
|
|
7417
7419
|
state: () => ({
|
|
7418
7420
|
traces: [],
|
|
7419
7421
|
currentTrace: null
|
|
@@ -7432,7 +7434,7 @@ const uh = nh("trace", {
|
|
|
7432
7434
|
}
|
|
7433
7435
|
});
|
|
7434
7436
|
var qs = { exports: {} };
|
|
7435
|
-
const
|
|
7437
|
+
const hc = (o) => typeof o == "object" && o !== null, pc = Symbol("skip"), pu = (o) => hc(o) && !(o instanceof RegExp) && !(o instanceof Error) && !(o instanceof Date), Ms = (o, t, r, l = /* @__PURE__ */ new WeakMap()) => {
|
|
7436
7438
|
if (r = {
|
|
7437
7439
|
deep: !1,
|
|
7438
7440
|
target: {},
|
|
@@ -7442,25 +7444,25 @@ const cc = (o) => typeof o == "object" && o !== null, fc = Symbol("skip"), du =
|
|
|
7442
7444
|
l.set(o, r.target);
|
|
7443
7445
|
const { target: u } = r;
|
|
7444
7446
|
delete r.target;
|
|
7445
|
-
const f = (h) => h.map((v) =>
|
|
7447
|
+
const f = (h) => h.map((v) => pu(v) ? Ms(v, t, r, l) : v);
|
|
7446
7448
|
if (Array.isArray(o))
|
|
7447
7449
|
return f(o);
|
|
7448
7450
|
for (const [h, v] of Object.entries(o)) {
|
|
7449
7451
|
const m = t(h, v, o);
|
|
7450
|
-
if (m ===
|
|
7452
|
+
if (m === pc)
|
|
7451
7453
|
continue;
|
|
7452
7454
|
let [x, S, { shouldRecurse: R = !0 } = {}] = m;
|
|
7453
|
-
x !== "__proto__" && (r.deep && R &&
|
|
7455
|
+
x !== "__proto__" && (r.deep && R && pu(S) && (S = Array.isArray(S) ? f(S) : Ms(S, t, r, l)), u[x] = S);
|
|
7454
7456
|
}
|
|
7455
7457
|
return u;
|
|
7456
7458
|
};
|
|
7457
7459
|
qs.exports = (o, t, r) => {
|
|
7458
|
-
if (!
|
|
7460
|
+
if (!hc(o))
|
|
7459
7461
|
throw new TypeError(`Expected an object, got \`${o}\` (${typeof o})`);
|
|
7460
7462
|
return Ms(o, t, r);
|
|
7461
7463
|
};
|
|
7462
|
-
qs.exports.mapObjectSkip =
|
|
7463
|
-
var
|
|
7464
|
+
qs.exports.mapObjectSkip = pc;
|
|
7465
|
+
var fh = qs.exports, Ta = function() {
|
|
7464
7466
|
return Ta = Object.assign || function(t) {
|
|
7465
7467
|
for (var r, l = 1, u = arguments.length; l < u; l++) {
|
|
7466
7468
|
r = arguments[l];
|
|
@@ -7469,66 +7471,66 @@ var ch = qs.exports, Ta = function() {
|
|
|
7469
7471
|
return t;
|
|
7470
7472
|
}, Ta.apply(this, arguments);
|
|
7471
7473
|
};
|
|
7472
|
-
function
|
|
7474
|
+
function dh(o) {
|
|
7473
7475
|
return o.toLowerCase();
|
|
7474
7476
|
}
|
|
7475
|
-
var
|
|
7476
|
-
function
|
|
7477
|
+
var hh = [/([a-z0-9])([A-Z])/g, /([A-Z])([A-Z][a-z])/g], ph = /[^A-Z0-9]+/gi;
|
|
7478
|
+
function gh(o, t) {
|
|
7477
7479
|
t === void 0 && (t = {});
|
|
7478
|
-
for (var r = t.splitRegexp, l = r === void 0 ?
|
|
7480
|
+
for (var r = t.splitRegexp, l = r === void 0 ? hh : r, u = t.stripRegexp, f = u === void 0 ? ph : u, h = t.transform, v = h === void 0 ? dh : h, m = t.delimiter, x = m === void 0 ? " " : m, S = gu(gu(o, l, "$1\0$2"), f, "\0"), R = 0, L = S.length; S.charAt(R) === "\0"; )
|
|
7479
7481
|
R++;
|
|
7480
7482
|
for (; S.charAt(L - 1) === "\0"; )
|
|
7481
7483
|
L--;
|
|
7482
7484
|
return S.slice(R, L).split("\0").map(v).join(x);
|
|
7483
7485
|
}
|
|
7484
|
-
function
|
|
7486
|
+
function gu(o, t, r) {
|
|
7485
7487
|
return t instanceof RegExp ? o.replace(t, r) : t.reduce(function(l, u) {
|
|
7486
7488
|
return l.replace(u, r);
|
|
7487
7489
|
}, o);
|
|
7488
7490
|
}
|
|
7489
|
-
function gh(o, t) {
|
|
7490
|
-
return t === void 0 && (t = {}), ph(o, Ta({ delimiter: "." }, t));
|
|
7491
|
-
}
|
|
7492
7491
|
function mh(o, t) {
|
|
7493
|
-
return t === void 0 && (t = {}), gh(o, Ta({ delimiter: "
|
|
7492
|
+
return t === void 0 && (t = {}), gh(o, Ta({ delimiter: "." }, t));
|
|
7493
|
+
}
|
|
7494
|
+
function vh(o, t) {
|
|
7495
|
+
return t === void 0 && (t = {}), mh(o, Ta({ delimiter: "_" }, t));
|
|
7494
7496
|
}
|
|
7495
|
-
const
|
|
7497
|
+
const yh = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
7496
7498
|
__proto__: null,
|
|
7497
|
-
snakeCase:
|
|
7498
|
-
}, Symbol.toStringTag, { value: "Module" })),
|
|
7499
|
-
var
|
|
7499
|
+
snakeCase: vh
|
|
7500
|
+
}, Symbol.toStringTag, { value: "Module" })), bh = /* @__PURE__ */ uh(yh), xh = fh, { snakeCase: wh } = bh, mu = {}.constructor;
|
|
7501
|
+
var kh = function(o, t) {
|
|
7500
7502
|
if (Array.isArray(o)) {
|
|
7501
|
-
if (o.some((l) => l.constructor !==
|
|
7503
|
+
if (o.some((l) => l.constructor !== mu))
|
|
7502
7504
|
throw new Error("obj must be array of plain objects");
|
|
7503
|
-
} else if (o.constructor !==
|
|
7505
|
+
} else if (o.constructor !== mu)
|
|
7504
7506
|
throw new Error("obj must be an plain object");
|
|
7505
7507
|
t = Object.assign({ deep: !0, exclude: [], parsingOptions: {} }, t);
|
|
7506
|
-
const r = t.snakeCase || ((l) =>
|
|
7507
|
-
return
|
|
7508
|
+
const r = t.snakeCase || ((l) => wh(l, t.parsingOptions));
|
|
7509
|
+
return xh(o, function(l, u) {
|
|
7508
7510
|
return [
|
|
7509
|
-
|
|
7511
|
+
Sh(t.exclude, l) ? l : r(l),
|
|
7510
7512
|
u,
|
|
7511
|
-
|
|
7513
|
+
Ch(l, u, t)
|
|
7512
7514
|
];
|
|
7513
7515
|
}, t);
|
|
7514
7516
|
};
|
|
7515
|
-
function
|
|
7517
|
+
function Sh(o, t) {
|
|
7516
7518
|
return o.some(function(r) {
|
|
7517
7519
|
return typeof r == "string" ? r === t : r.test(t);
|
|
7518
7520
|
});
|
|
7519
7521
|
}
|
|
7520
|
-
function
|
|
7522
|
+
function Ch(o, t, r) {
|
|
7521
7523
|
return r.shouldRecurse ? { shouldRecurse: r.shouldRecurse(o, t) } : void 0;
|
|
7522
7524
|
}
|
|
7523
|
-
const
|
|
7525
|
+
const Th = /* @__PURE__ */ lh(kh), gc = () => {
|
|
7524
7526
|
var o;
|
|
7525
7527
|
return typeof window < "u" && ((o = window.GF_LOCAL_CONFIG) != null && o.TRACE_API_BASE_URL) ? window.GF_LOCAL_CONFIG.TRACE_API_BASE_URL : "/tracing";
|
|
7526
7528
|
}, _a = (o) => {
|
|
7527
7529
|
if (!o || typeof o != "string") return "";
|
|
7528
|
-
const t =
|
|
7530
|
+
const t = gc(), r = typeof window < "u" && t.startsWith("/") ? window.location.origin : "";
|
|
7529
7531
|
return `${t.startsWith("http") ? t : r + t}/v1/file/download?url=${encodeURIComponent(o)}`;
|
|
7530
|
-
}, $t =
|
|
7531
|
-
baseURL:
|
|
7532
|
+
}, $t = sh.create({
|
|
7533
|
+
baseURL: gc(),
|
|
7532
7534
|
timeout: 36e5
|
|
7533
7535
|
}), xt = {
|
|
7534
7536
|
getExperiments() {
|
|
@@ -7579,14 +7581,14 @@ const Ch = /* @__PURE__ */ ah(wh), dc = () => {
|
|
|
7579
7581
|
return $t.post("/v1/trace/getPromptTokens", o).then((t) => t.data);
|
|
7580
7582
|
},
|
|
7581
7583
|
advancedSearchTrace(o) {
|
|
7582
|
-
return $t.post("/v1/trace/advancedSearch",
|
|
7584
|
+
return $t.post("/v1/trace/advancedSearch", Th(o, { deep: !0 })).then((t) => t.data);
|
|
7583
7585
|
},
|
|
7584
7586
|
getTagKeys(o) {
|
|
7585
7587
|
const t = {};
|
|
7586
7588
|
return o && (t.experimentId = o), $t.get("/v1/trace/tagKeys", { params: t }).then((r) => r.data);
|
|
7587
7589
|
}
|
|
7588
7590
|
};
|
|
7589
|
-
function
|
|
7591
|
+
function _h(o) {
|
|
7590
7592
|
const t = document.createElement("textarea");
|
|
7591
7593
|
t.value = o, t.setAttribute("readonly", ""), t.style.position = "fixed", t.style.left = "-9999px", t.style.top = "0", document.body.appendChild(t), t.select();
|
|
7592
7594
|
try {
|
|
@@ -7602,22 +7604,22 @@ function La(o, t) {
|
|
|
7602
7604
|
return;
|
|
7603
7605
|
}
|
|
7604
7606
|
const r = String(o);
|
|
7605
|
-
|
|
7607
|
+
_h(r) ? t.$message.success(t.$t("debug.copySuccess")) : t.$message.error(t.$t("debug.copyFailed"));
|
|
7606
7608
|
}
|
|
7607
|
-
function
|
|
7609
|
+
function mc(o) {
|
|
7608
7610
|
if (!o) return "-";
|
|
7609
7611
|
const t = o / 1e6;
|
|
7610
7612
|
return t < 1e3 ? `${t.toFixed(2)}ms` : t < 6e4 ? `${(t / 1e3).toFixed(2)}s` : `${(t / 6e4).toFixed(2)}min`;
|
|
7611
7613
|
}
|
|
7612
|
-
function
|
|
7614
|
+
function vu(o) {
|
|
7613
7615
|
if (!o) return "-";
|
|
7614
7616
|
const t = o / 1e6, r = new Date(t), l = r.getFullYear(), u = String(r.getMonth() + 1).padStart(2, "0"), f = String(r.getDate()).padStart(2, "0"), h = String(r.getHours()).padStart(2, "0"), v = String(r.getMinutes()).padStart(2, "0"), m = String(r.getSeconds()).padStart(2, "0");
|
|
7615
7617
|
return `${l}/${u}/${f} ${h}:${v}:${m}`;
|
|
7616
7618
|
}
|
|
7617
|
-
function
|
|
7618
|
-
return !o || !t ? "-" : `${
|
|
7619
|
+
function Lh(o, t, r = "-") {
|
|
7620
|
+
return !o || !t ? "-" : `${vu(o)} ${r} ${vu(t)}`;
|
|
7619
7621
|
}
|
|
7620
|
-
function
|
|
7622
|
+
function vc(o) {
|
|
7621
7623
|
const t = {
|
|
7622
7624
|
SERVER: "primary",
|
|
7623
7625
|
CHAT_MODEL: "success",
|
|
@@ -7633,16 +7635,16 @@ function pc(o) {
|
|
|
7633
7635
|
};
|
|
7634
7636
|
return t[o] !== void 0 ? t[o] : "info";
|
|
7635
7637
|
}
|
|
7636
|
-
function
|
|
7638
|
+
function yc(o) {
|
|
7637
7639
|
return {
|
|
7638
7640
|
CLIENT: "rgb(141 252 245)",
|
|
7639
7641
|
EMBEDDING: "rgb(248 246 130)"
|
|
7640
7642
|
}[o] || void 0;
|
|
7641
7643
|
}
|
|
7642
|
-
function
|
|
7644
|
+
function bc(o) {
|
|
7643
7645
|
return o.status_description ? o.status_description : "";
|
|
7644
7646
|
}
|
|
7645
|
-
function
|
|
7647
|
+
function xc(o, t, r) {
|
|
7646
7648
|
if (!t || !r || t === r)
|
|
7647
7649
|
return { width: "100%" };
|
|
7648
7650
|
const l = r - t, u = o.start_time_unix_nano - t, f = o.duration_ns, h = u / l * 100, v = f / l * 100;
|
|
@@ -7651,11 +7653,11 @@ function vc(o, t, r) {
|
|
|
7651
7653
|
width: `${v}%`
|
|
7652
7654
|
};
|
|
7653
7655
|
}
|
|
7654
|
-
var
|
|
7656
|
+
var wc = { exports: {} };
|
|
7655
7657
|
(function(o, t) {
|
|
7656
7658
|
(function(r, l) {
|
|
7657
7659
|
o.exports = l(Vt());
|
|
7658
|
-
})(
|
|
7660
|
+
})(fc, function(r) {
|
|
7659
7661
|
return function(l) {
|
|
7660
7662
|
function u(h) {
|
|
7661
7663
|
if (f[h]) return f[h].exports;
|
|
@@ -7801,8 +7803,8 @@ var yc = { exports: {} };
|
|
|
7801
7803
|
u.a = m;
|
|
7802
7804
|
}]);
|
|
7803
7805
|
});
|
|
7804
|
-
})(
|
|
7805
|
-
var Us =
|
|
7806
|
+
})(wc);
|
|
7807
|
+
var Us = wc.exports;
|
|
7806
7808
|
function Gs() {
|
|
7807
7809
|
return {
|
|
7808
7810
|
async: !1,
|
|
@@ -7818,42 +7820,42 @@ function Gs() {
|
|
|
7818
7820
|
};
|
|
7819
7821
|
}
|
|
7820
7822
|
let lr = Gs();
|
|
7821
|
-
function
|
|
7823
|
+
function kc(o) {
|
|
7822
7824
|
lr = o;
|
|
7823
7825
|
}
|
|
7824
|
-
const
|
|
7826
|
+
const Sc = /[&<>"']/, Eh = new RegExp(Sc.source, "g"), Cc = /[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/, Ah = new RegExp(Cc.source, "g"), Ih = {
|
|
7825
7827
|
"&": "&",
|
|
7826
7828
|
"<": "<",
|
|
7827
7829
|
">": ">",
|
|
7828
7830
|
'"': """,
|
|
7829
7831
|
"'": "'"
|
|
7830
|
-
},
|
|
7832
|
+
}, yu = (o) => Ih[o];
|
|
7831
7833
|
function Gt(o, t) {
|
|
7832
7834
|
if (t) {
|
|
7833
|
-
if (
|
|
7834
|
-
return o.replace(
|
|
7835
|
-
} else if (
|
|
7836
|
-
return o.replace(
|
|
7835
|
+
if (Sc.test(o))
|
|
7836
|
+
return o.replace(Eh, yu);
|
|
7837
|
+
} else if (Cc.test(o))
|
|
7838
|
+
return o.replace(Ah, yu);
|
|
7837
7839
|
return o;
|
|
7838
7840
|
}
|
|
7839
|
-
const
|
|
7840
|
-
function
|
|
7841
|
-
return o.replace(
|
|
7841
|
+
const Oh = /&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig;
|
|
7842
|
+
function Dh(o) {
|
|
7843
|
+
return o.replace(Oh, (t, r) => (r = r.toLowerCase(), r === "colon" ? ":" : r.charAt(0) === "#" ? r.charAt(1) === "x" ? String.fromCharCode(parseInt(r.substring(2), 16)) : String.fromCharCode(+r.substring(1)) : ""));
|
|
7842
7844
|
}
|
|
7843
|
-
const
|
|
7845
|
+
const Nh = /(^|[^\[])\^/g;
|
|
7844
7846
|
function je(o, t) {
|
|
7845
7847
|
let r = typeof o == "string" ? o : o.source;
|
|
7846
7848
|
t = t || "";
|
|
7847
7849
|
const l = {
|
|
7848
7850
|
replace: (u, f) => {
|
|
7849
7851
|
let h = typeof f == "string" ? f : f.source;
|
|
7850
|
-
return h = h.replace(
|
|
7852
|
+
return h = h.replace(Nh, "$1"), r = r.replace(u, h), l;
|
|
7851
7853
|
},
|
|
7852
7854
|
getRegex: () => new RegExp(r, t)
|
|
7853
7855
|
};
|
|
7854
7856
|
return l;
|
|
7855
7857
|
}
|
|
7856
|
-
function
|
|
7858
|
+
function bu(o) {
|
|
7857
7859
|
try {
|
|
7858
7860
|
o = encodeURI(o).replace(/%25/g, "%");
|
|
7859
7861
|
} catch {
|
|
@@ -7862,7 +7864,7 @@ function vu(o) {
|
|
|
7862
7864
|
return o;
|
|
7863
7865
|
}
|
|
7864
7866
|
const Li = { exec: () => null };
|
|
7865
|
-
function
|
|
7867
|
+
function xu(o, t) {
|
|
7866
7868
|
const r = o.replace(/\|/g, (f, h, v) => {
|
|
7867
7869
|
let m = !1, x = h;
|
|
7868
7870
|
for (; --x >= 0 && v[x] === "\\"; )
|
|
@@ -7889,7 +7891,7 @@ function ma(o, t, r) {
|
|
|
7889
7891
|
u++;
|
|
7890
7892
|
return o.slice(0, l - u);
|
|
7891
7893
|
}
|
|
7892
|
-
function
|
|
7894
|
+
function Rh(o, t) {
|
|
7893
7895
|
if (o.indexOf(t[1]) === -1)
|
|
7894
7896
|
return -1;
|
|
7895
7897
|
let r = 0;
|
|
@@ -7902,7 +7904,7 @@ function Nh(o, t) {
|
|
|
7902
7904
|
return l;
|
|
7903
7905
|
return -1;
|
|
7904
7906
|
}
|
|
7905
|
-
function
|
|
7907
|
+
function wu(o, t, r, l) {
|
|
7906
7908
|
const u = t.href, f = t.title ? Gt(t.title) : null, h = o[1].replace(/\\([\[\]])/g, "$1");
|
|
7907
7909
|
if (o[0].charAt(0) !== "!") {
|
|
7908
7910
|
l.state.inLink = !0;
|
|
@@ -7924,7 +7926,7 @@ function bu(o, t, r, l) {
|
|
|
7924
7926
|
text: Gt(h)
|
|
7925
7927
|
};
|
|
7926
7928
|
}
|
|
7927
|
-
function
|
|
7929
|
+
function Fh(o, t) {
|
|
7928
7930
|
const r = o.match(/^(\s+)(?:```)/);
|
|
7929
7931
|
if (r === null)
|
|
7930
7932
|
return t;
|
|
@@ -7972,7 +7974,7 @@ class Ea {
|
|
|
7972
7974
|
fences(t) {
|
|
7973
7975
|
const r = this.rules.block.fences.exec(t);
|
|
7974
7976
|
if (r) {
|
|
7975
|
-
const l = r[0], u =
|
|
7977
|
+
const l = r[0], u = Fh(l, r[3] || "");
|
|
7976
7978
|
return {
|
|
7977
7979
|
type: "code",
|
|
7978
7980
|
raw: l,
|
|
@@ -8119,7 +8121,7 @@ class Ea {
|
|
|
8119
8121
|
const r = this.rules.block.table.exec(t);
|
|
8120
8122
|
if (!r || !/[:|]/.test(r[2]))
|
|
8121
8123
|
return;
|
|
8122
|
-
const l =
|
|
8124
|
+
const l = xu(r[1]), u = r[2].replace(/^\||\| *$/g, "").split("|"), f = r[3] && r[3].trim() ? r[3].replace(/\n[ \t]*$/, "").split(`
|
|
8123
8125
|
`) : [], h = {
|
|
8124
8126
|
type: "table",
|
|
8125
8127
|
raw: r[0],
|
|
@@ -8136,7 +8138,7 @@ class Ea {
|
|
|
8136
8138
|
tokens: this.lexer.inline(v)
|
|
8137
8139
|
});
|
|
8138
8140
|
for (const v of f)
|
|
8139
|
-
h.rows.push(
|
|
8141
|
+
h.rows.push(xu(v, h.header.length).map((m) => ({
|
|
8140
8142
|
text: m,
|
|
8141
8143
|
tokens: this.lexer.inline(m)
|
|
8142
8144
|
})));
|
|
@@ -8209,7 +8211,7 @@ class Ea {
|
|
|
8209
8211
|
if ((l.length - h.length) % 2 === 0)
|
|
8210
8212
|
return;
|
|
8211
8213
|
} else {
|
|
8212
|
-
const h =
|
|
8214
|
+
const h = Rh(r[2], "()");
|
|
8213
8215
|
if (h > -1) {
|
|
8214
8216
|
const m = (r[0].indexOf("!") === 0 ? 5 : 4) + r[1].length + h;
|
|
8215
8217
|
r[2] = r[2].substring(0, h), r[0] = r[0].substring(0, m).trim(), r[3] = "";
|
|
@@ -8221,7 +8223,7 @@ class Ea {
|
|
|
8221
8223
|
h && (u = h[1], f = h[3]);
|
|
8222
8224
|
} else
|
|
8223
8225
|
f = r[3] ? r[3].slice(1, -1) : "";
|
|
8224
|
-
return u = u.trim(), /^</.test(u) && (this.options.pedantic && !/>$/.test(l) ? u = u.slice(1) : u = u.slice(1, -1)),
|
|
8226
|
+
return u = u.trim(), /^</.test(u) && (this.options.pedantic && !/>$/.test(l) ? u = u.slice(1) : u = u.slice(1, -1)), wu(r, {
|
|
8225
8227
|
href: u && u.replace(this.rules.inline.anyPunctuation, "$1"),
|
|
8226
8228
|
title: f && f.replace(this.rules.inline.anyPunctuation, "$1")
|
|
8227
8229
|
}, r[0], this.lexer);
|
|
@@ -8239,7 +8241,7 @@ class Ea {
|
|
|
8239
8241
|
text: h
|
|
8240
8242
|
};
|
|
8241
8243
|
}
|
|
8242
|
-
return
|
|
8244
|
+
return wu(l, f, l[0], this.lexer);
|
|
8243
8245
|
}
|
|
8244
8246
|
}
|
|
8245
8247
|
emStrong(t, r, l = "") {
|
|
@@ -8373,25 +8375,25 @@ class Ea {
|
|
|
8373
8375
|
}
|
|
8374
8376
|
}
|
|
8375
8377
|
}
|
|
8376
|
-
const
|
|
8377
|
-
blockquote:
|
|
8378
|
-
code:
|
|
8379
|
-
def:
|
|
8380
|
-
fences:
|
|
8381
|
-
heading:
|
|
8378
|
+
const $h = /^(?: *(?:\n|$))+/, Mh = /^( {4}[^\n]+(?:\n(?: *(?:\n|$))*)?)+/, Ph = /^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/, Ri = /^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/, zh = /^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/, Tc = /(?:[*+-]|\d{1,9}[.)])/, _c = je(/^(?!bull )((?:.|\n(?!\s*?\n|bull ))+?)\n {0,3}(=+|-+) *(?:\n+|$)/).replace(/bull/g, Tc).getRegex(), Ks = /^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/, Bh = /^[^\n]+/, Vs = /(?!\s*\])(?:\\.|[^\[\]\\])+/, Hh = je(/^ {0,3}\[(label)\]: *(?:\n *)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n *)?| *\n *)(title))? *(?:\n+|$)/).replace("label", Vs).replace("title", /(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(), Wh = je(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g, Tc).getRegex(), Ra = "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|section|source|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul", Qs = /<!--(?!-?>)[\s\S]*?(?:-->|$)/, jh = je("^ {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", Qs).replace("tag", Ra).replace("attribute", / +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(), Lc = je(Ks).replace("hr", Ri).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", Ra).getRegex(), qh = je(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph", Lc).getRegex(), Xs = {
|
|
8379
|
+
blockquote: qh,
|
|
8380
|
+
code: Mh,
|
|
8381
|
+
def: Hh,
|
|
8382
|
+
fences: Ph,
|
|
8383
|
+
heading: zh,
|
|
8382
8384
|
hr: Ri,
|
|
8383
|
-
html:
|
|
8384
|
-
lheading:
|
|
8385
|
-
list:
|
|
8386
|
-
newline:
|
|
8387
|
-
paragraph:
|
|
8385
|
+
html: jh,
|
|
8386
|
+
lheading: _c,
|
|
8387
|
+
list: Wh,
|
|
8388
|
+
newline: $h,
|
|
8389
|
+
paragraph: Lc,
|
|
8388
8390
|
table: Li,
|
|
8389
|
-
text:
|
|
8390
|
-
},
|
|
8391
|
+
text: Bh
|
|
8392
|
+
}, ku = je("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr", Ri).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("blockquote", " {0,3}>").replace("code", " {4}[^\\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", Ra).getRegex(), Uh = {
|
|
8391
8393
|
...Xs,
|
|
8392
|
-
table:
|
|
8393
|
-
paragraph: je(Ks).replace("hr", Ri).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("|lheading", "").replace("table",
|
|
8394
|
-
},
|
|
8394
|
+
table: ku,
|
|
8395
|
+
paragraph: je(Ks).replace("hr", Ri).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("|lheading", "").replace("table", ku).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", Ra).getRegex()
|
|
8396
|
+
}, Gh = {
|
|
8395
8397
|
...Xs,
|
|
8396
8398
|
html: je(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment", Qs).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(),
|
|
8397
8399
|
def: /^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,
|
|
@@ -8400,52 +8402,52 @@ const Fh = /^(?: *(?:\n|$))+/, $h = /^( {4}[^\n]+(?:\n(?: *(?:\n|$))*)?)+/, Mh =
|
|
|
8400
8402
|
// fences not supported
|
|
8401
8403
|
lheading: /^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,
|
|
8402
8404
|
paragraph: je(Ks).replace("hr", Ri).replace("heading", ` *#{1,6} *[^
|
|
8403
|
-
]`).replace("lheading",
|
|
8404
|
-
},
|
|
8405
|
+
]`).replace("lheading", _c).replace("|table", "").replace("blockquote", " {0,3}>").replace("|fences", "").replace("|list", "").replace("|html", "").replace("|tag", "").getRegex()
|
|
8406
|
+
}, Ec = /^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/, Kh = /^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/, Ac = /^( {2,}|\\)\n(?!\s*$)/, Vh = /^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/, Fi = "\\p{P}$+<=>`^|~", Qh = je(/^((?![*_])[\spunctuation])/, "u").replace(/punctuation/g, Fi).getRegex(), Xh = /\[[^[\]]*?\]\([^\(\)]*?\)|`[^`]*?`|<[^<>]*?>/g, Jh = je(/^(?:\*+(?:((?!\*)[punct])|[^\s*]))|^_+(?:((?!_)[punct])|([^\s_]))/, "u").replace(/punct/g, Fi).getRegex(), Yh = je("^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)[punct](\\*+)(?=[\\s]|$)|[^punct\\s](\\*+)(?!\\*)(?=[punct\\s]|$)|(?!\\*)[punct\\s](\\*+)(?=[^punct\\s])|[\\s](\\*+)(?!\\*)(?=[punct])|(?!\\*)[punct](\\*+)(?!\\*)(?=[punct])|[^punct\\s](\\*+)(?=[^punct\\s])", "gu").replace(/punct/g, Fi).getRegex(), Zh = je("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)[punct](_+)(?=[\\s]|$)|[^punct\\s](_+)(?!_)(?=[punct\\s]|$)|(?!_)[punct\\s](_+)(?=[^punct\\s])|[\\s](_+)(?!_)(?=[punct])|(?!_)[punct](_+)(?!_)(?=[punct])", "gu").replace(/punct/g, Fi).getRegex(), ep = je(/\\([punct])/, "gu").replace(/punct/g, Fi).getRegex(), tp = je(/^<(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(), np = je(Qs).replace("(?:-->|$)", "-->").getRegex(), rp = je("^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", np).replace("attribute", /\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(), Aa = /(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/, ip = je(/^!?\[(label)\]\(\s*(href)(?:\s+(title))?\s*\)/).replace("label", Aa).replace("href", /<(?:\\.|[^\n<>\\])+>|[^\s\x00-\x1f]*/).replace("title", /"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(), Ic = je(/^!?\[(label)\]\[(ref)\]/).replace("label", Aa).replace("ref", Vs).getRegex(), Oc = je(/^!?\[(ref)\](?:\[\])?/).replace("ref", Vs).getRegex(), ap = je("reflink|nolink(?!\\()", "g").replace("reflink", Ic).replace("nolink", Oc).getRegex(), Js = {
|
|
8405
8407
|
_backpedal: Li,
|
|
8406
8408
|
// only used for GFM url
|
|
8407
|
-
anyPunctuation:
|
|
8408
|
-
autolink:
|
|
8409
|
-
blockSkip:
|
|
8410
|
-
br:
|
|
8411
|
-
code:
|
|
8409
|
+
anyPunctuation: ep,
|
|
8410
|
+
autolink: tp,
|
|
8411
|
+
blockSkip: Xh,
|
|
8412
|
+
br: Ac,
|
|
8413
|
+
code: Kh,
|
|
8412
8414
|
del: Li,
|
|
8413
|
-
emStrongLDelim:
|
|
8414
|
-
emStrongRDelimAst:
|
|
8415
|
-
emStrongRDelimUnd:
|
|
8416
|
-
escape:
|
|
8417
|
-
link:
|
|
8418
|
-
nolink:
|
|
8419
|
-
punctuation:
|
|
8420
|
-
reflink:
|
|
8421
|
-
reflinkSearch:
|
|
8422
|
-
tag:
|
|
8423
|
-
text:
|
|
8415
|
+
emStrongLDelim: Jh,
|
|
8416
|
+
emStrongRDelimAst: Yh,
|
|
8417
|
+
emStrongRDelimUnd: Zh,
|
|
8418
|
+
escape: Ec,
|
|
8419
|
+
link: ip,
|
|
8420
|
+
nolink: Oc,
|
|
8421
|
+
punctuation: Qh,
|
|
8422
|
+
reflink: Ic,
|
|
8423
|
+
reflinkSearch: ap,
|
|
8424
|
+
tag: rp,
|
|
8425
|
+
text: Vh,
|
|
8424
8426
|
url: Li
|
|
8425
|
-
},
|
|
8427
|
+
}, sp = {
|
|
8426
8428
|
...Js,
|
|
8427
8429
|
link: je(/^!?\[(label)\]\((.*?)\)/).replace("label", Aa).getRegex(),
|
|
8428
8430
|
reflink: je(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label", Aa).getRegex()
|
|
8429
8431
|
}, Ps = {
|
|
8430
8432
|
...Js,
|
|
8431
|
-
escape: je(
|
|
8433
|
+
escape: je(Ec).replace("])", "~|])").getRegex(),
|
|
8432
8434
|
url: je(/^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/, "i").replace("email", /[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/).getRegex(),
|
|
8433
8435
|
_backpedal: /(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,
|
|
8434
8436
|
del: /^(~~?)(?=[^\s~])([\s\S]*?[^\s~])\1(?=[^~]|$)/,
|
|
8435
8437
|
text: /^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|https?:\/\/|ftp:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/
|
|
8436
|
-
},
|
|
8438
|
+
}, op = {
|
|
8437
8439
|
...Ps,
|
|
8438
|
-
br: je(
|
|
8440
|
+
br: je(Ac).replace("{2,}", "*").getRegex(),
|
|
8439
8441
|
text: je(Ps.text).replace("\\b_", "\\b_| {2,}\\n").replace(/\{2,\}/g, "*").getRegex()
|
|
8440
8442
|
}, va = {
|
|
8441
8443
|
normal: Xs,
|
|
8442
|
-
gfm:
|
|
8443
|
-
pedantic:
|
|
8444
|
+
gfm: Uh,
|
|
8445
|
+
pedantic: Gh
|
|
8444
8446
|
}, Si = {
|
|
8445
8447
|
normal: Js,
|
|
8446
8448
|
gfm: Ps,
|
|
8447
|
-
breaks:
|
|
8448
|
-
pedantic:
|
|
8449
|
+
breaks: op,
|
|
8450
|
+
pedantic: sp
|
|
8449
8451
|
};
|
|
8450
8452
|
class yn {
|
|
8451
8453
|
constructor(t) {
|
|
@@ -8752,7 +8754,7 @@ ${t}</tr>
|
|
|
8752
8754
|
return `<del>${t}</del>`;
|
|
8753
8755
|
}
|
|
8754
8756
|
link(t, r, l) {
|
|
8755
|
-
const u =
|
|
8757
|
+
const u = bu(t);
|
|
8756
8758
|
if (u === null)
|
|
8757
8759
|
return l;
|
|
8758
8760
|
t = u;
|
|
@@ -8760,7 +8762,7 @@ ${t}</tr>
|
|
|
8760
8762
|
return r && (f += ' title="' + r + '"'), f += ">" + l + "</a>", f;
|
|
8761
8763
|
}
|
|
8762
8764
|
image(t, r, l) {
|
|
8763
|
-
const u =
|
|
8765
|
+
const u = bu(t);
|
|
8764
8766
|
if (u === null)
|
|
8765
8767
|
return l;
|
|
8766
8768
|
t = u;
|
|
@@ -8843,7 +8845,7 @@ class bn {
|
|
|
8843
8845
|
}
|
|
8844
8846
|
case "heading": {
|
|
8845
8847
|
const h = f;
|
|
8846
|
-
l += this.renderer.heading(this.parseInline(h.tokens), h.depth,
|
|
8848
|
+
l += this.renderer.heading(this.parseInline(h.tokens), h.depth, Dh(this.parseInline(h.tokens, this.textRenderer)));
|
|
8847
8849
|
continue;
|
|
8848
8850
|
}
|
|
8849
8851
|
case "code": {
|
|
@@ -9024,8 +9026,8 @@ Qe(Ei, "passThroughHooks", /* @__PURE__ */ new Set([
|
|
|
9024
9026
|
"postprocess",
|
|
9025
9027
|
"processAllTokens"
|
|
9026
9028
|
]));
|
|
9027
|
-
var or, zs,
|
|
9028
|
-
class
|
|
9029
|
+
var or, zs, Dc;
|
|
9030
|
+
class lp {
|
|
9029
9031
|
constructor(...t) {
|
|
9030
9032
|
cu(this, or);
|
|
9031
9033
|
Qe(this, "defaults", Gs());
|
|
@@ -9167,7 +9169,7 @@ or = new WeakSet(), zs = function(t, r) {
|
|
|
9167
9169
|
return (l, u) => {
|
|
9168
9170
|
const f = { ...u }, h = { ...this.defaults, ...f };
|
|
9169
9171
|
this.defaults.async === !0 && f.async === !1 && (h.silent || console.warn("marked(): The async option was set to true by an extension. The async: false option sent to parse will be ignored."), h.async = !0);
|
|
9170
|
-
const v = ga(this, or,
|
|
9172
|
+
const v = ga(this, or, Dc).call(this, !!h.silent, !!h.async);
|
|
9171
9173
|
if (typeof l > "u" || l === null)
|
|
9172
9174
|
return v(new Error("marked(): input parameter is undefined or null"));
|
|
9173
9175
|
if (typeof l != "string")
|
|
@@ -9184,7 +9186,7 @@ or = new WeakSet(), zs = function(t, r) {
|
|
|
9184
9186
|
return v(m);
|
|
9185
9187
|
}
|
|
9186
9188
|
};
|
|
9187
|
-
},
|
|
9189
|
+
}, Dc = function(t, r) {
|
|
9188
9190
|
return (l) => {
|
|
9189
9191
|
if (l.message += `
|
|
9190
9192
|
Please report this to https://github.com/markedjs/marked.`, t) {
|
|
@@ -9196,17 +9198,17 @@ Please report this to https://github.com/markedjs/marked.`, t) {
|
|
|
9196
9198
|
throw l;
|
|
9197
9199
|
};
|
|
9198
9200
|
};
|
|
9199
|
-
const sr = new
|
|
9201
|
+
const sr = new lp();
|
|
9200
9202
|
function Se(o, t) {
|
|
9201
9203
|
return sr.parse(o, t);
|
|
9202
9204
|
}
|
|
9203
9205
|
Se.options = Se.setOptions = function(o) {
|
|
9204
|
-
return sr.setOptions(o), Se.defaults = sr.defaults,
|
|
9206
|
+
return sr.setOptions(o), Se.defaults = sr.defaults, kc(Se.defaults), Se;
|
|
9205
9207
|
};
|
|
9206
9208
|
Se.getDefaults = Gs;
|
|
9207
9209
|
Se.defaults = lr;
|
|
9208
9210
|
Se.use = function(...o) {
|
|
9209
|
-
return sr.use(...o), Se.defaults = sr.defaults,
|
|
9211
|
+
return sr.use(...o), Se.defaults = sr.defaults, kc(Se.defaults), Se;
|
|
9210
9212
|
};
|
|
9211
9213
|
Se.walkTokens = function(o, t) {
|
|
9212
9214
|
return sr.walkTokens(o, t);
|
|
@@ -9235,7 +9237,7 @@ function dn(o, t, r, l, u, f, h, v) {
|
|
|
9235
9237
|
options: m
|
|
9236
9238
|
};
|
|
9237
9239
|
}
|
|
9238
|
-
const
|
|
9240
|
+
const up = {
|
|
9239
9241
|
name: "TimelineHeader",
|
|
9240
9242
|
props: {
|
|
9241
9243
|
timeRange: {
|
|
@@ -9260,18 +9262,18 @@ const lp = {
|
|
|
9260
9262
|
}
|
|
9261
9263
|
}
|
|
9262
9264
|
};
|
|
9263
|
-
var
|
|
9265
|
+
var cp = function() {
|
|
9264
9266
|
var t = this, r = t._self._c;
|
|
9265
9267
|
return r("div", { staticClass: "timeline-header" }, [r("div", { staticClass: "time-scale" }, [r("span", { staticClass: "time-range" }, [t._v(t._s(t.timeRange))])]), r("div", { staticClass: "header-actions" }, [t.viewMode === "tree" ? r("el-tooltip", { attrs: { content: t.allExpanded ? "合上所有节点" : "展开所有节点", placement: "top" } }, [r("i", { staticClass: "action-icon", class: t.allExpanded ? "el-icon-arrow-down" : "el-icon-arrow-right", on: { click: t.handleToggleExpand } })]) : t._e(), r("el-tooltip", { attrs: { content: t.viewMode === "list" ? "切换到树形视图" : "切换到列表视图", placement: "top" } }, [r("i", { staticClass: "action-icon", class: t.viewMode === "list" ? "el-icon-menu" : "el-icon-s-operation", on: { click: t.handleToggleView } })])], 1)]);
|
|
9266
|
-
},
|
|
9267
|
-
lp,
|
|
9268
|
+
}, fp = [], dp = /* @__PURE__ */ dn(
|
|
9268
9269
|
up,
|
|
9269
9270
|
cp,
|
|
9271
|
+
fp,
|
|
9270
9272
|
!1,
|
|
9271
9273
|
null,
|
|
9272
9274
|
"a6b357e5"
|
|
9273
9275
|
);
|
|
9274
|
-
const
|
|
9276
|
+
const hp = dp.exports, pp = {
|
|
9275
9277
|
name: "TimelineBar",
|
|
9276
9278
|
props: {
|
|
9277
9279
|
barStyle: {
|
|
@@ -9296,21 +9298,21 @@ const dp = fp.exports, hp = {
|
|
|
9296
9298
|
}
|
|
9297
9299
|
}
|
|
9298
9300
|
};
|
|
9299
|
-
var
|
|
9301
|
+
var gp = function() {
|
|
9300
9302
|
var t = this, r = t._self._c;
|
|
9301
9303
|
return r("el-tooltip", { attrs: { content: t.statusDescription, disabled: !t.statusDescription, placement: "top", "popper-class": "span-status-tooltip" } }, [r("div", { staticClass: "timeline-bar-wrapper" }, [r("div", { staticClass: "timeline-bar", class: { selected: t.selected, error: t.error, "has-events": t.hasEvents }, style: t.barStyle })])]);
|
|
9302
|
-
},
|
|
9303
|
-
hp,
|
|
9304
|
+
}, mp = [], vp = /* @__PURE__ */ dn(
|
|
9304
9305
|
pp,
|
|
9305
9306
|
gp,
|
|
9307
|
+
mp,
|
|
9306
9308
|
!1,
|
|
9307
9309
|
null,
|
|
9308
9310
|
"00a350c8"
|
|
9309
9311
|
);
|
|
9310
|
-
const
|
|
9312
|
+
const Nc = vp.exports, yp = {
|
|
9311
9313
|
name: "SpanTreeNode",
|
|
9312
9314
|
components: {
|
|
9313
|
-
TimelineBar:
|
|
9315
|
+
TimelineBar: Nc
|
|
9314
9316
|
},
|
|
9315
9317
|
props: {
|
|
9316
9318
|
node: {
|
|
@@ -9360,7 +9362,7 @@ const Ic = mp.exports, vp = {
|
|
|
9360
9362
|
return this.isRootNode ? !0 : this.isExpanded;
|
|
9361
9363
|
},
|
|
9362
9364
|
duration() {
|
|
9363
|
-
return
|
|
9365
|
+
return mc(this.node.duration_ns);
|
|
9364
9366
|
},
|
|
9365
9367
|
typeLabel() {
|
|
9366
9368
|
const o = this.node.type;
|
|
@@ -9369,16 +9371,16 @@ const Ic = mp.exports, vp = {
|
|
|
9369
9371
|
return t ? t.label : o;
|
|
9370
9372
|
},
|
|
9371
9373
|
typeColor() {
|
|
9372
|
-
return
|
|
9374
|
+
return vc(this.node.type);
|
|
9373
9375
|
},
|
|
9374
9376
|
typeCustomColor() {
|
|
9375
|
-
return
|
|
9377
|
+
return yc(this.node.type);
|
|
9376
9378
|
},
|
|
9377
9379
|
statusDescription() {
|
|
9378
|
-
return
|
|
9380
|
+
return bc(this.node);
|
|
9379
9381
|
},
|
|
9380
9382
|
barStyle() {
|
|
9381
|
-
return
|
|
9383
|
+
return xc(this.node, this.traceStartTime, this.traceEndTime);
|
|
9382
9384
|
},
|
|
9383
9385
|
error() {
|
|
9384
9386
|
return this.node.status === "ERROR";
|
|
@@ -9399,7 +9401,7 @@ const Ic = mp.exports, vp = {
|
|
|
9399
9401
|
}
|
|
9400
9402
|
}
|
|
9401
9403
|
};
|
|
9402
|
-
var
|
|
9404
|
+
var bp = function() {
|
|
9403
9405
|
var t = this, r = t._self._c;
|
|
9404
9406
|
return r("div", [r("div", { staticClass: "timeline-node", class: { selected: t.selected, error: t.error, "child-node": t.isChild }, on: { click: t.handleClick } }, [r("div", { staticClass: "node-row" }, [r("div", { staticClass: "node-info" }, [t.hasChildren && !t.isRootNode ? r("i", { staticClass: "expand-icon", class: t.isExpanded ? "el-icon-arrow-down" : "el-icon-arrow-right", on: { click: function(l) {
|
|
9405
9407
|
return l.stopPropagation(), t.handleToggleExpand.apply(null, arguments);
|
|
@@ -9410,18 +9412,18 @@ var yp = function() {
|
|
|
9410
9412
|
return t.$emit("toggle-expand", u);
|
|
9411
9413
|
} } });
|
|
9412
9414
|
}), 1) : t._e()]);
|
|
9413
|
-
},
|
|
9414
|
-
vp,
|
|
9415
|
+
}, xp = [], wp = /* @__PURE__ */ dn(
|
|
9415
9416
|
yp,
|
|
9416
9417
|
bp,
|
|
9418
|
+
xp,
|
|
9417
9419
|
!1,
|
|
9418
9420
|
null,
|
|
9419
9421
|
"d10c241e"
|
|
9420
9422
|
);
|
|
9421
|
-
const
|
|
9423
|
+
const kp = wp.exports, Sp = {
|
|
9422
9424
|
name: "SpanListNode",
|
|
9423
9425
|
components: {
|
|
9424
|
-
TimelineBar:
|
|
9426
|
+
TimelineBar: Nc
|
|
9425
9427
|
},
|
|
9426
9428
|
props: {
|
|
9427
9429
|
node: {
|
|
@@ -9447,7 +9449,7 @@ const wp = xp.exports, kp = {
|
|
|
9447
9449
|
},
|
|
9448
9450
|
computed: {
|
|
9449
9451
|
duration() {
|
|
9450
|
-
return
|
|
9452
|
+
return mc(this.node.duration_ns);
|
|
9451
9453
|
},
|
|
9452
9454
|
typeLabel() {
|
|
9453
9455
|
const o = this.node.type;
|
|
@@ -9456,16 +9458,16 @@ const wp = xp.exports, kp = {
|
|
|
9456
9458
|
return t ? t.label : o;
|
|
9457
9459
|
},
|
|
9458
9460
|
typeColor() {
|
|
9459
|
-
return
|
|
9461
|
+
return vc(this.node.type);
|
|
9460
9462
|
},
|
|
9461
9463
|
typeCustomColor() {
|
|
9462
|
-
return
|
|
9464
|
+
return yc(this.node.type);
|
|
9463
9465
|
},
|
|
9464
9466
|
statusDescription() {
|
|
9465
|
-
return
|
|
9467
|
+
return bc(this.node);
|
|
9466
9468
|
},
|
|
9467
9469
|
barStyle() {
|
|
9468
|
-
return
|
|
9470
|
+
return xc(this.node, this.traceStartTime, this.traceEndTime);
|
|
9469
9471
|
},
|
|
9470
9472
|
error() {
|
|
9471
9473
|
return this.node.status === "ERROR";
|
|
@@ -9480,23 +9482,23 @@ const wp = xp.exports, kp = {
|
|
|
9480
9482
|
}
|
|
9481
9483
|
}
|
|
9482
9484
|
};
|
|
9483
|
-
var
|
|
9485
|
+
var Cp = function() {
|
|
9484
9486
|
var t = this, r = t._self._c;
|
|
9485
9487
|
return r("div", { staticClass: "timeline-node", class: { selected: t.selected, error: t.error }, on: { click: t.handleClick } }, [r("div", { staticClass: "node-row" }, [r("div", { staticClass: "node-info" }, [r("el-tag", { staticClass: "type-tag", attrs: { type: t.typeColor, color: t.typeCustomColor, size: "mini" } }, [t._v(" " + t._s(t.typeLabel) + " ")]), r("el-tooltip", { attrs: { content: t.node.name, placement: "top", "open-delay": 300 } }, [r("span", { staticClass: "node-name" }, [t._v(t._s(t.node.name))])])], 1), r("div", { staticClass: "node-duration" }, [t._v(" " + t._s(t.duration) + " ")])]), r("TimelineBar", { attrs: { "bar-style": t.barStyle, "status-description": t.statusDescription, selected: t.selected, error: t.error, "has-events": t.hasEvents } })], 1);
|
|
9486
|
-
},
|
|
9487
|
-
kp,
|
|
9488
|
+
}, Tp = [], _p = /* @__PURE__ */ dn(
|
|
9488
9489
|
Sp,
|
|
9489
9490
|
Cp,
|
|
9491
|
+
Tp,
|
|
9490
9492
|
!1,
|
|
9491
9493
|
null,
|
|
9492
9494
|
"111b6031"
|
|
9493
9495
|
);
|
|
9494
|
-
const
|
|
9496
|
+
const Lp = _p.exports, Ep = {
|
|
9495
9497
|
name: "TraceSpanTree",
|
|
9496
9498
|
components: {
|
|
9497
|
-
TimelineHeader:
|
|
9498
|
-
SpanTreeNode:
|
|
9499
|
-
SpanListNode:
|
|
9499
|
+
TimelineHeader: hp,
|
|
9500
|
+
SpanTreeNode: kp,
|
|
9501
|
+
SpanListNode: Lp
|
|
9500
9502
|
},
|
|
9501
9503
|
props: {
|
|
9502
9504
|
spans: {
|
|
@@ -9539,7 +9541,7 @@ const _p = Tp.exports, Lp = {
|
|
|
9539
9541
|
},
|
|
9540
9542
|
timeRange() {
|
|
9541
9543
|
const o = this.$t ? this.$t("trace.to") : "-";
|
|
9542
|
-
return
|
|
9544
|
+
return Lh(this.traceStartTime, this.traceEndTime, o);
|
|
9543
9545
|
}
|
|
9544
9546
|
},
|
|
9545
9547
|
watch: {
|
|
@@ -9620,26 +9622,26 @@ const _p = Tp.exports, Lp = {
|
|
|
9620
9622
|
}
|
|
9621
9623
|
}
|
|
9622
9624
|
};
|
|
9623
|
-
var
|
|
9625
|
+
var Ap = function() {
|
|
9624
9626
|
var t = this, r = t._self._c;
|
|
9625
9627
|
return r("div", { staticClass: "span-tree-container" }, [t.treeData.length === 0 ? r("div", { staticClass: "empty-state" }, [r("el-empty", { attrs: { description: "暂无 Span 数据" } })], 1) : r("div", { staticClass: "timeline-wrapper" }, [r("TimelineHeader", { attrs: { "time-range": t.timeRange, "all-expanded": t.allExpanded, "view-mode": t.viewMode }, on: { "toggle-expand": t.toggleAllExpand, "toggle-view": t.toggleViewMode } }), r("div", { ref: "timelineContent", staticClass: "timeline-content" }, [t.viewMode === "tree" ? t._l(t.treeData, function(l) {
|
|
9626
9628
|
return r("SpanTreeNode", { key: l.span_id, attrs: { node: l, selected: t.selectedSpanId === l.span_id, "selected-span-id": t.selectedSpanId, "expanded-nodes": t.expandedNodes, depth: 0, "trace-start-time": t.traceStartTime, "trace-end-time": t.traceEndTime, "span-type-list": t.spanTypeList }, on: { "node-click": t.handleNodeClick, "toggle-expand": t.toggleExpand } });
|
|
9627
9629
|
}) : t._l(t.flatListData, function(l) {
|
|
9628
9630
|
return r("SpanListNode", { key: l.span_id, attrs: { node: l, selected: t.selectedSpanId === l.span_id, "trace-start-time": t.traceStartTime, "trace-end-time": t.traceEndTime, "span-type-list": t.spanTypeList }, on: { "node-click": t.handleNodeClick } });
|
|
9629
9631
|
})], 2)], 1)]);
|
|
9630
|
-
},
|
|
9631
|
-
Lp,
|
|
9632
|
+
}, Ip = [], Op = /* @__PURE__ */ dn(
|
|
9632
9633
|
Ep,
|
|
9633
9634
|
Ap,
|
|
9635
|
+
Ip,
|
|
9634
9636
|
!1,
|
|
9635
9637
|
null,
|
|
9636
9638
|
"0cf980e1"
|
|
9637
9639
|
);
|
|
9638
|
-
const
|
|
9639
|
-
function
|
|
9640
|
+
const Rc = Op.exports;
|
|
9641
|
+
function Dp() {
|
|
9640
9642
|
return window.pdfjsLib;
|
|
9641
9643
|
}
|
|
9642
|
-
const
|
|
9644
|
+
const Np = {
|
|
9643
9645
|
name: "FilePdfViewer",
|
|
9644
9646
|
props: {
|
|
9645
9647
|
element: {
|
|
@@ -9694,7 +9696,7 @@ const Dp = {
|
|
|
9694
9696
|
}
|
|
9695
9697
|
this.loading = !0, this.error = null, this.cancelRender(), this.pdfDoc && (this.pdfDoc.destroy(), this.pdfDoc = null);
|
|
9696
9698
|
try {
|
|
9697
|
-
const l =
|
|
9699
|
+
const l = Dp();
|
|
9698
9700
|
if (!l) {
|
|
9699
9701
|
this.error = "PDF.js not loaded";
|
|
9700
9702
|
return;
|
|
@@ -9748,19 +9750,19 @@ const Dp = {
|
|
|
9748
9750
|
}
|
|
9749
9751
|
}
|
|
9750
9752
|
};
|
|
9751
|
-
var
|
|
9753
|
+
var Rp = function() {
|
|
9752
9754
|
var l;
|
|
9753
9755
|
var t = this, r = t._self._c;
|
|
9754
9756
|
return r("div", { staticClass: "file-pdf-content" }, [t.element.label ? r("div", { staticClass: "image-label" }, [t._v(t._s(t.element.label))]) : t._e(), r("div", { staticClass: "file-pdf-toolbar" }, [r("el-button", { attrs: { size: "mini", disabled: t.currentPage <= 1 }, on: { click: t.prevPage } }, [t._v(t._s(t.$t("trace.pdfPrevPage")))]), r("span", { staticClass: "file-pdf-page-indicator" }, [t._v(t._s(t.formatPageIndicator))]), r("el-button", { attrs: { size: "mini", disabled: t.totalPages > 0 && t.currentPage >= t.totalPages }, on: { click: t.nextPage } }, [t._v(t._s(t.$t("trace.pdfNextPage")))]), r("div", { staticClass: "file-pdf-zoom" }, [r("span", { staticClass: "file-pdf-zoom-btn", class: { disabled: t.pdfScale <= t.scaleMin }, on: { click: t.zoomOut } }, [r("i", { staticClass: "el-icon-minus" })]), r("span", { staticClass: "file-pdf-zoom-btn", class: { disabled: t.pdfScale >= t.scaleMax }, on: { click: t.zoomIn } }, [r("i", { staticClass: "el-icon-plus" })])]), r("el-button", { attrs: { size: "mini", type: "primary", disabled: !((l = t.element) != null && l.downloadUrl) }, on: { click: t.downloadFile } }, [t._v(t._s(t.$t("trace.pdfDownload")))])], 1), r("div", { staticClass: "file-pdf-viewer" }, [t.loading ? r("div", { staticClass: "file-pdf-loading" }, [t._v(t._s(t.$t("trace.pdfLoading")))]) : t.error ? r("div", { staticClass: "file-pdf-error" }, [t._v(t._s(t.error))]) : r("canvas", { ref: "canvasRef", staticClass: "file-pdf-canvas" })])]);
|
|
9755
|
-
},
|
|
9756
|
-
Dp,
|
|
9757
|
+
}, Fp = [], $p = /* @__PURE__ */ dn(
|
|
9757
9758
|
Np,
|
|
9758
9759
|
Rp,
|
|
9760
|
+
Fp,
|
|
9759
9761
|
!1,
|
|
9760
9762
|
null,
|
|
9761
9763
|
"fbe9d6b8"
|
|
9762
9764
|
);
|
|
9763
|
-
const Zs =
|
|
9765
|
+
const Zs = $p.exports;
|
|
9764
9766
|
/*!
|
|
9765
9767
|
* Viewer.js v1.11.7
|
|
9766
9768
|
* https://fengyuanchen.github.io/viewerjs
|
|
@@ -9770,29 +9772,29 @@ const Zs = Fp.exports;
|
|
|
9770
9772
|
*
|
|
9771
9773
|
* Date: 2024-11-24T04:32:19.116Z
|
|
9772
9774
|
*/
|
|
9773
|
-
function
|
|
9775
|
+
function Mp(o, t) {
|
|
9774
9776
|
if (!(o instanceof t)) throw new TypeError("Cannot call a class as a function");
|
|
9775
9777
|
}
|
|
9776
|
-
function
|
|
9778
|
+
function Su(o, t) {
|
|
9777
9779
|
for (var r = 0; r < t.length; r++) {
|
|
9778
9780
|
var l = t[r];
|
|
9779
|
-
l.enumerable = l.enumerable || !1, l.configurable = !0, "value" in l && (l.writable = !0), Object.defineProperty(o,
|
|
9781
|
+
l.enumerable = l.enumerable || !1, l.configurable = !0, "value" in l && (l.writable = !0), Object.defineProperty(o, Fc(l.key), l);
|
|
9780
9782
|
}
|
|
9781
9783
|
}
|
|
9782
|
-
function
|
|
9783
|
-
return t &&
|
|
9784
|
+
function Pp(o, t, r) {
|
|
9785
|
+
return t && Su(o.prototype, t), r && Su(o, r), Object.defineProperty(o, "prototype", {
|
|
9784
9786
|
writable: !1
|
|
9785
9787
|
}), o;
|
|
9786
9788
|
}
|
|
9787
|
-
function
|
|
9788
|
-
return (t =
|
|
9789
|
+
function zp(o, t, r) {
|
|
9790
|
+
return (t = Fc(t)) in o ? Object.defineProperty(o, t, {
|
|
9789
9791
|
value: r,
|
|
9790
9792
|
enumerable: !0,
|
|
9791
9793
|
configurable: !0,
|
|
9792
9794
|
writable: !0
|
|
9793
9795
|
}) : o[t] = r, o;
|
|
9794
9796
|
}
|
|
9795
|
-
function
|
|
9797
|
+
function Cu(o, t) {
|
|
9796
9798
|
var r = Object.keys(o);
|
|
9797
9799
|
if (Object.getOwnPropertySymbols) {
|
|
9798
9800
|
var l = Object.getOwnPropertySymbols(o);
|
|
@@ -9805,15 +9807,15 @@ function ku(o, t) {
|
|
|
9805
9807
|
function eo(o) {
|
|
9806
9808
|
for (var t = 1; t < arguments.length; t++) {
|
|
9807
9809
|
var r = arguments[t] != null ? arguments[t] : {};
|
|
9808
|
-
t % 2 ?
|
|
9809
|
-
|
|
9810
|
-
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(o, Object.getOwnPropertyDescriptors(r)) :
|
|
9810
|
+
t % 2 ? Cu(Object(r), !0).forEach(function(l) {
|
|
9811
|
+
zp(o, l, r[l]);
|
|
9812
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(o, Object.getOwnPropertyDescriptors(r)) : Cu(Object(r)).forEach(function(l) {
|
|
9811
9813
|
Object.defineProperty(o, l, Object.getOwnPropertyDescriptor(r, l));
|
|
9812
9814
|
});
|
|
9813
9815
|
}
|
|
9814
9816
|
return o;
|
|
9815
9817
|
}
|
|
9816
|
-
function
|
|
9818
|
+
function Bp(o, t) {
|
|
9817
9819
|
if (typeof o != "object" || !o) return o;
|
|
9818
9820
|
var r = o[Symbol.toPrimitive];
|
|
9819
9821
|
if (r !== void 0) {
|
|
@@ -9823,8 +9825,8 @@ function zp(o, t) {
|
|
|
9823
9825
|
}
|
|
9824
9826
|
return String(o);
|
|
9825
9827
|
}
|
|
9826
|
-
function
|
|
9827
|
-
var t =
|
|
9828
|
+
function Fc(o) {
|
|
9829
|
+
var t = Bp(o, "string");
|
|
9828
9830
|
return typeof t == "symbol" ? t : t + "";
|
|
9829
9831
|
}
|
|
9830
9832
|
function Bs(o) {
|
|
@@ -9835,7 +9837,7 @@ function Bs(o) {
|
|
|
9835
9837
|
return t && typeof Symbol == "function" && t.constructor === Symbol && t !== Symbol.prototype ? "symbol" : typeof t;
|
|
9836
9838
|
}, Bs(o);
|
|
9837
9839
|
}
|
|
9838
|
-
var
|
|
9840
|
+
var Tu = {
|
|
9839
9841
|
/**
|
|
9840
9842
|
* Enable a modal backdrop, specify `static` for a backdrop
|
|
9841
9843
|
* which doesn't close the modal on click.
|
|
@@ -10040,13 +10042,13 @@ var Su = {
|
|
|
10040
10042
|
zoomed: null,
|
|
10041
10043
|
play: null,
|
|
10042
10044
|
stop: null
|
|
10043
|
-
},
|
|
10045
|
+
}, Hp = '<div class="viewer-container" tabindex="-1" touch-action="none"><div class="viewer-canvas"></div><div class="viewer-footer"><div class="viewer-title"></div><div class="viewer-toolbar"></div><div class="viewer-navbar"><ul class="viewer-list" role="navigation"></ul></div></div><div class="viewer-tooltip" role="alert" aria-hidden="true"></div><div class="viewer-button" data-viewer-action="mix" role="button"></div><div class="viewer-player"></div></div>', Fa = typeof window < "u" && typeof window.document < "u", En = Fa ? window : {}, Wr = Fa && En.document.documentElement ? "ontouchstart" in En.document.documentElement : !1, to = Fa ? "PointerEvent" in En : !1, Ne = "viewer", ka = "move", $c = "switch", Ti = "zoom", ya = "".concat(Ne, "-active"), Wp = "".concat(Ne, "-close"), Sa = "".concat(Ne, "-fade"), Hs = "".concat(Ne, "-fixed"), jp = "".concat(Ne, "-fullscreen"), _u = "".concat(Ne, "-fullscreen-exit"), ir = "".concat(Ne, "-hide"), qp = "".concat(Ne, "-hide-md-down"), Up = "".concat(Ne, "-hide-sm-down"), Gp = "".concat(Ne, "-hide-xs-down"), Yt = "".concat(Ne, "-in"), Ai = "".concat(Ne, "-invisible"), jr = "".concat(Ne, "-loading"), Kp = "".concat(Ne, "-move"), Lu = "".concat(Ne, "-open"), Mr = "".concat(Ne, "-show"), it = "".concat(Ne, "-transition"), qr = "click", Ws = "dblclick", Eu = "dragstart", Au = "focusin", Iu = "keydown", Zt = "load", ar = "error", Vp = Wr ? "touchend touchcancel" : "mouseup", Qp = Wr ? "touchmove" : "mousemove", Xp = Wr ? "touchstart" : "mousedown", Ou = to ? "pointerdown" : Xp, Du = to ? "pointermove" : Qp, Nu = to ? "pointerup pointercancel" : Vp, Ru = "resize", cn = "transitionend", Fu = "wheel", $u = "ready", Mu = "show", Pu = "shown", zu = "hide", Bu = "hidden", Hu = "view", Oi = "viewed", Wu = "move", ju = "moved", qu = "rotate", Uu = "rotated", Gu = "scale", Ku = "scaled", Vu = "zoom", Qu = "zoomed", Xu = "play", Ju = "stop", Oa = "".concat(Ne, "Action"), no = /\s\s*/, ba = ["zoom-in", "zoom-out", "one-to-one", "reset", "prev", "play", "next", "rotate-left", "rotate-right", "flip-horizontal", "flip-vertical"];
|
|
10044
10046
|
function Di(o) {
|
|
10045
10047
|
return typeof o == "string";
|
|
10046
10048
|
}
|
|
10047
|
-
var
|
|
10049
|
+
var Jp = Number.isNaN || En.isNaN;
|
|
10048
10050
|
function nt(o) {
|
|
10049
|
-
return typeof o == "number" && !
|
|
10051
|
+
return typeof o == "number" && !Jp(o);
|
|
10050
10052
|
}
|
|
10051
10053
|
function zr(o) {
|
|
10052
10054
|
return typeof o > "u";
|
|
@@ -10054,13 +10056,13 @@ function zr(o) {
|
|
|
10054
10056
|
function Ur(o) {
|
|
10055
10057
|
return Bs(o) === "object" && o !== null;
|
|
10056
10058
|
}
|
|
10057
|
-
var
|
|
10059
|
+
var Yp = Object.prototype.hasOwnProperty;
|
|
10058
10060
|
function Br(o) {
|
|
10059
10061
|
if (!Ur(o))
|
|
10060
10062
|
return !1;
|
|
10061
10063
|
try {
|
|
10062
10064
|
var t = o.constructor, r = t.prototype;
|
|
10063
|
-
return t && r &&
|
|
10065
|
+
return t && r && Yp.call(r, "isPrototypeOf");
|
|
10064
10066
|
} catch {
|
|
10065
10067
|
return !1;
|
|
10066
10068
|
}
|
|
@@ -10087,14 +10089,14 @@ var Kt = Object.assign || function(t) {
|
|
|
10087
10089
|
t[h] = f[h];
|
|
10088
10090
|
});
|
|
10089
10091
|
}), t;
|
|
10090
|
-
},
|
|
10092
|
+
}, Zp = /^(?:width|height|left|top|marginLeft|marginTop)$/;
|
|
10091
10093
|
function fn(o, t) {
|
|
10092
10094
|
var r = o.style;
|
|
10093
10095
|
Ke(t, function(l, u) {
|
|
10094
|
-
|
|
10096
|
+
Zp.test(u) && nt(l) && (l += "px"), r[u] = l;
|
|
10095
10097
|
});
|
|
10096
10098
|
}
|
|
10097
|
-
function
|
|
10099
|
+
function eg(o) {
|
|
10098
10100
|
return Di(o) ? o.replace(/&(?!amp;|quot;|#39;|lt;|gt;)/g, "&").replace(/"/g, """).replace(/'/g, "'").replace(/</g, "<").replace(/>/g, ">") : o;
|
|
10099
10101
|
}
|
|
10100
10102
|
function Pr(o, t) {
|
|
@@ -10142,9 +10144,9 @@ function Ni(o, t, r) {
|
|
|
10142
10144
|
r ? Le(o, t) : Be(o, t);
|
|
10143
10145
|
}
|
|
10144
10146
|
}
|
|
10145
|
-
var
|
|
10147
|
+
var tg = /([a-z\d])([A-Z])/g;
|
|
10146
10148
|
function ro(o) {
|
|
10147
|
-
return o.replace(
|
|
10149
|
+
return o.replace(tg, "$1-$2").toLowerCase();
|
|
10148
10150
|
}
|
|
10149
10151
|
function Hr(o, t) {
|
|
10150
10152
|
return Ur(o[t]) ? o[t] : o.dataset ? o.dataset[t] : o.getAttribute("data-".concat(ro(t)));
|
|
@@ -10152,7 +10154,7 @@ function Hr(o, t) {
|
|
|
10152
10154
|
function js(o, t, r) {
|
|
10153
10155
|
Ur(r) ? o[t] = r : o.dataset ? o.dataset[t] = r : o.setAttribute("data-".concat(ro(t)), r);
|
|
10154
10156
|
}
|
|
10155
|
-
var
|
|
10157
|
+
var Mc = function() {
|
|
10156
10158
|
var o = !1;
|
|
10157
10159
|
if (Fa) {
|
|
10158
10160
|
var t = !1, r = function() {
|
|
@@ -10176,7 +10178,7 @@ var Rc = function() {
|
|
|
10176
10178
|
function Ge(o, t, r) {
|
|
10177
10179
|
var l = arguments.length > 3 && arguments[3] !== void 0 ? arguments[3] : {}, u = r;
|
|
10178
10180
|
t.trim().split(no).forEach(function(f) {
|
|
10179
|
-
if (!
|
|
10181
|
+
if (!Mc) {
|
|
10180
10182
|
var h = o.listeners;
|
|
10181
10183
|
h && h[f] && h[f][r] && (u = h[f][r], delete h[f][r], Object.keys(h[f]).length === 0 && delete h[f], Object.keys(h).length === 0 && delete o.listeners);
|
|
10182
10184
|
}
|
|
@@ -10186,7 +10188,7 @@ function Ge(o, t, r) {
|
|
|
10186
10188
|
function Ee(o, t, r) {
|
|
10187
10189
|
var l = arguments.length > 3 && arguments[3] !== void 0 ? arguments[3] : {}, u = r;
|
|
10188
10190
|
t.trim().split(no).forEach(function(f) {
|
|
10189
|
-
if (l.once && !
|
|
10191
|
+
if (l.once && !Mc) {
|
|
10190
10192
|
var h = o.listeners, v = h === void 0 ? {} : h;
|
|
10191
10193
|
u = function() {
|
|
10192
10194
|
delete v[f][r], o.removeEventListener(f, u, l);
|
|
@@ -10206,7 +10208,7 @@ function ot(o, t, r, l) {
|
|
|
10206
10208
|
detail: r
|
|
10207
10209
|
}, l)) : (u = document.createEvent("CustomEvent"), u.initCustomEvent(t, !0, !0, r)), o.dispatchEvent(u);
|
|
10208
10210
|
}
|
|
10209
|
-
function
|
|
10211
|
+
function ng(o) {
|
|
10210
10212
|
var t = o.getBoundingClientRect();
|
|
10211
10213
|
return {
|
|
10212
10214
|
left: t.left + (window.pageXOffset - document.documentElement.clientLeft),
|
|
@@ -10223,11 +10225,11 @@ function Ca(o) {
|
|
|
10223
10225
|
transform: v
|
|
10224
10226
|
};
|
|
10225
10227
|
}
|
|
10226
|
-
function
|
|
10228
|
+
function rg(o) {
|
|
10227
10229
|
return Di(o) ? decodeURIComponent(o.replace(/^.*\//, "").replace(/[?&#].*$/, "")) : "";
|
|
10228
10230
|
}
|
|
10229
10231
|
var Ns = En.navigator && /Version\/\d+(\.\d+)+?\s+Safari/i.test(En.navigator.userAgent);
|
|
10230
|
-
function
|
|
10232
|
+
function Pc(o, t, r) {
|
|
10231
10233
|
var l = document.createElement("img");
|
|
10232
10234
|
if (o.naturalWidth && !Ns)
|
|
10233
10235
|
return r(o.naturalWidth, o.naturalHeight), l;
|
|
@@ -10242,16 +10244,16 @@ function Fc(o, t, r) {
|
|
|
10242
10244
|
function xa(o) {
|
|
10243
10245
|
switch (o) {
|
|
10244
10246
|
case 2:
|
|
10245
|
-
return
|
|
10247
|
+
return Gp;
|
|
10246
10248
|
case 3:
|
|
10247
|
-
return
|
|
10249
|
+
return Up;
|
|
10248
10250
|
case 4:
|
|
10249
|
-
return
|
|
10251
|
+
return qp;
|
|
10250
10252
|
default:
|
|
10251
10253
|
return "";
|
|
10252
10254
|
}
|
|
10253
10255
|
}
|
|
10254
|
-
function
|
|
10256
|
+
function ig(o) {
|
|
10255
10257
|
var t = eo({}, o), r = [];
|
|
10256
10258
|
return Ke(o, function(l, u) {
|
|
10257
10259
|
delete t[u], Ke(t, function(f) {
|
|
@@ -10273,7 +10275,7 @@ function wa(o, t) {
|
|
|
10273
10275
|
startY: l
|
|
10274
10276
|
}, u);
|
|
10275
10277
|
}
|
|
10276
|
-
function
|
|
10278
|
+
function ag(o) {
|
|
10277
10279
|
var t = 0, r = 0, l = 0;
|
|
10278
10280
|
return Ke(o, function(u) {
|
|
10279
10281
|
var f = u.startX, h = u.startY;
|
|
@@ -10283,7 +10285,7 @@ function ig(o) {
|
|
|
10283
10285
|
pageY: r
|
|
10284
10286
|
};
|
|
10285
10287
|
}
|
|
10286
|
-
var
|
|
10288
|
+
var sg = {
|
|
10287
10289
|
render: function() {
|
|
10288
10290
|
this.initContainer(), this.initViewer(), this.initList(), this.renderViewer();
|
|
10289
10291
|
},
|
|
@@ -10310,7 +10312,7 @@ var ag = {
|
|
|
10310
10312
|
initList: function() {
|
|
10311
10313
|
var t = this, r = this.element, l = this.options, u = this.list, f = [];
|
|
10312
10314
|
u.innerHTML = "", Ke(this.images, function(h, v) {
|
|
10313
|
-
var m = h.src, x = h.alt ||
|
|
10315
|
+
var m = h.src, x = h.alt || rg(m), S = t.getImageURL(h);
|
|
10314
10316
|
if (m || S) {
|
|
10315
10317
|
var R = document.createElement("li"), L = document.createElement("img");
|
|
10316
10318
|
Ke(l.inheritedAttributes, function(W) {
|
|
@@ -10358,7 +10360,7 @@ var ag = {
|
|
|
10358
10360
|
abort: function() {
|
|
10359
10361
|
S.onload = null;
|
|
10360
10362
|
}
|
|
10361
|
-
}, S =
|
|
10363
|
+
}, S = Pc(u, l, function(R, L) {
|
|
10362
10364
|
var W = R / L, z = Math.max(0, Math.min(1, l.initialCoverage)), O = v, M = m;
|
|
10363
10365
|
r.imageInitializing = !1, m * W > v ? M = v / W : O = m * W, z = nt(z) ? z : 0.9, O = Math.min(O * z, R), M = Math.min(M * z, L);
|
|
10364
10366
|
var A = (v - O) / 2, N = (m - M) / 2, H = {
|
|
@@ -10404,22 +10406,22 @@ var ag = {
|
|
|
10404
10406
|
var t = this.image;
|
|
10405
10407
|
t && (this.viewing && this.viewing.abort(), t.parentNode.removeChild(t), this.image = null, this.title.innerHTML = "");
|
|
10406
10408
|
}
|
|
10407
|
-
},
|
|
10409
|
+
}, og = {
|
|
10408
10410
|
bind: function() {
|
|
10409
10411
|
var t = this.options, r = this.viewer, l = this.canvas, u = this.element.ownerDocument;
|
|
10410
|
-
Ee(r, qr, this.onClick = this.click.bind(this)), Ee(r,
|
|
10412
|
+
Ee(r, qr, this.onClick = this.click.bind(this)), Ee(r, Eu, this.onDragStart = this.dragstart.bind(this)), Ee(l, Ou, this.onPointerDown = this.pointerdown.bind(this)), Ee(u, Du, this.onPointerMove = this.pointermove.bind(this)), Ee(u, Nu, this.onPointerUp = this.pointerup.bind(this)), Ee(u, Iu, this.onKeyDown = this.keydown.bind(this)), Ee(window, Ru, this.onResize = this.resize.bind(this)), t.zoomable && t.zoomOnWheel && Ee(r, Fu, this.onWheel = this.wheel.bind(this), {
|
|
10411
10413
|
passive: !1,
|
|
10412
10414
|
capture: !0
|
|
10413
10415
|
}), t.toggleOnDblclick && Ee(l, Ws, this.onDblclick = this.dblclick.bind(this));
|
|
10414
10416
|
},
|
|
10415
10417
|
unbind: function() {
|
|
10416
10418
|
var t = this.options, r = this.viewer, l = this.canvas, u = this.element.ownerDocument;
|
|
10417
|
-
Ge(r, qr, this.onClick), Ge(r,
|
|
10419
|
+
Ge(r, qr, this.onClick), Ge(r, Eu, this.onDragStart), Ge(l, Ou, this.onPointerDown), Ge(u, Du, this.onPointerMove), Ge(u, Nu, this.onPointerUp), Ge(u, Iu, this.onKeyDown), Ge(window, Ru, this.onResize), t.zoomable && t.zoomOnWheel && Ge(r, Fu, this.onWheel, {
|
|
10418
10420
|
passive: !1,
|
|
10419
10421
|
capture: !0
|
|
10420
10422
|
}), t.toggleOnDblclick && Ge(l, Ws, this.onDblclick);
|
|
10421
10423
|
}
|
|
10422
|
-
},
|
|
10424
|
+
}, lg = {
|
|
10423
10425
|
click: function(t) {
|
|
10424
10426
|
var r = this.options, l = this.imageData, u = t.target, f = Hr(u, Oa);
|
|
10425
10427
|
switch (!f && u.localName === "img" && u.parentElement.localName === "li" && (u = u.parentElement, f = Hr(u, Oa)), Wr && t.isTrusted && u === this.canvas && clearTimeout(this.clickCanvasTimeout), f) {
|
|
@@ -10477,7 +10479,7 @@ var ag = {
|
|
|
10477
10479
|
this.timeout && (clearTimeout(this.timeout), this.timeout = !1);
|
|
10478
10480
|
var r = this.element, l = this.options, u = this.image, f = this.index, h = this.viewerData;
|
|
10479
10481
|
Be(u, Ai), l.loading && Be(this.canvas, jr), u.style.cssText = "height:0;" + "margin-left:".concat(h.width / 2, "px;") + "margin-top:".concat(h.height / 2, "px;") + "max-width:none!important;position:relative;width:0;", this.initImage(function() {
|
|
10480
|
-
Ni(u,
|
|
10482
|
+
Ni(u, Kp, l.movable), Ni(u, it, l.transition), t.renderImage(function() {
|
|
10481
10483
|
t.viewed = !0, t.viewing = !1, Ue(l.viewed) && Ee(r, Oi, l.viewed, {
|
|
10482
10484
|
once: !0
|
|
10483
10485
|
}), ot(r, Oi, {
|
|
@@ -10492,7 +10494,7 @@ var ag = {
|
|
|
10492
10494
|
},
|
|
10493
10495
|
loadImage: function(t) {
|
|
10494
10496
|
var r = t.target, l = r.parentNode, u = l.offsetWidth || 30, f = l.offsetHeight || 50, h = !!Hr(r, "filled");
|
|
10495
|
-
|
|
10497
|
+
Pc(r, this.options, function(v, m) {
|
|
10496
10498
|
var x = v / m, S = u, R = f;
|
|
10497
10499
|
f * x > u ? h ? S = f * x : R = u / x : h ? R = u / x : S = f * x, fn(r, Kt({
|
|
10498
10500
|
width: S,
|
|
@@ -10550,7 +10552,7 @@ var ag = {
|
|
|
10550
10552
|
l[v.identifier] = wa(v);
|
|
10551
10553
|
}) : l[t.pointerId || 0] = wa(t);
|
|
10552
10554
|
var h = r.movable ? ka : !1;
|
|
10553
|
-
r.zoomOnTouch && r.zoomable && Object.keys(l).length > 1 ? h = Ti : r.slideOnTouch && (t.pointerType === "touch" || t.type === "touchstart") && this.isSwitchable() && (h =
|
|
10555
|
+
r.zoomOnTouch && r.zoomable && Object.keys(l).length > 1 ? h = Ti : r.slideOnTouch && (t.pointerType === "touch" || t.type === "touchstart") && this.isSwitchable() && (h = $c), r.transition && (h === ka || h === Ti) && Be(this.image, it), this.action = h;
|
|
10554
10556
|
}
|
|
10555
10557
|
},
|
|
10556
10558
|
pointermove: function(t) {
|
|
@@ -10601,7 +10603,7 @@ var ag = {
|
|
|
10601
10603
|
t.deltaY ? u = t.deltaY > 0 ? 1 : -1 : t.wheelDelta ? u = -t.wheelDelta / 120 : t.detail && (u = t.detail > 0 ? 1 : -1), this.zoom(-u * l, !0, null, t);
|
|
10602
10604
|
}
|
|
10603
10605
|
}
|
|
10604
|
-
},
|
|
10606
|
+
}, ug = {
|
|
10605
10607
|
/** Show the viewer (only available in modal mode)
|
|
10606
10608
|
* @param {boolean} [immediate=false] - Indicates if show the viewer immediately or not.
|
|
10607
10609
|
* @returns {Viewer} this
|
|
@@ -10612,9 +10614,9 @@ var ag = {
|
|
|
10612
10614
|
return this;
|
|
10613
10615
|
if (!this.ready)
|
|
10614
10616
|
return this.build(), this.ready && this.show(t), this;
|
|
10615
|
-
if (Ue(l.show) && Ee(r,
|
|
10617
|
+
if (Ue(l.show) && Ee(r, Mu, l.show, {
|
|
10616
10618
|
once: !0
|
|
10617
|
-
}), ot(r,
|
|
10619
|
+
}), ot(r, Mu) === !1 || !this.ready)
|
|
10618
10620
|
return this;
|
|
10619
10621
|
this.hiding && this.transitioning.abort(), this.showing = !0, this.open();
|
|
10620
10622
|
var u = this.viewer;
|
|
@@ -10640,9 +10642,9 @@ var ag = {
|
|
|
10640
10642
|
var t = this, r = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : !1, l = this.element, u = this.options;
|
|
10641
10643
|
if (u.inline || this.hiding || !(this.isShown || this.showing))
|
|
10642
10644
|
return this;
|
|
10643
|
-
if (Ue(u.hide) && Ee(l,
|
|
10645
|
+
if (Ue(u.hide) && Ee(l, zu, u.hide, {
|
|
10644
10646
|
once: !0
|
|
10645
|
-
}), ot(l,
|
|
10647
|
+
}), ot(l, zu) === !1)
|
|
10646
10648
|
return this;
|
|
10647
10649
|
this.showing && this.transitioning.abort(), this.hiding = !0, this.played ? this.stop() : this.viewing && this.viewing.abort();
|
|
10648
10650
|
var f = this.viewer, h = this.image, v = function() {
|
|
@@ -10681,9 +10683,9 @@ var ag = {
|
|
|
10681
10683
|
if (Ke(u.inheritedAttributes, function(M) {
|
|
10682
10684
|
var A = m.getAttribute(M);
|
|
10683
10685
|
A !== null && R.setAttribute(M, A);
|
|
10684
|
-
}), R.src = x, R.alt = S, Ue(u.view) && Ee(l,
|
|
10686
|
+
}), R.src = x, R.alt = S, Ue(u.view) && Ee(l, Hu, u.view, {
|
|
10685
10687
|
once: !0
|
|
10686
|
-
}), ot(l,
|
|
10688
|
+
}), ot(l, Hu, {
|
|
10687
10689
|
originalImage: this.images[r],
|
|
10688
10690
|
index: r,
|
|
10689
10691
|
image: R
|
|
@@ -10693,7 +10695,7 @@ var ag = {
|
|
|
10693
10695
|
L && (Be(L, ya), L.removeAttribute("aria-selected")), Le(v, ya), v.setAttribute("aria-selected", !0), u.focus && v.focus(), this.image = R, this.viewed = !1, this.index = r, this.imageData = {}, Le(R, Ai), u.loading && Le(h, jr), h.innerHTML = "", h.appendChild(R), this.renderList(), f.innerHTML = "";
|
|
10694
10696
|
var W = function() {
|
|
10695
10697
|
var A = t.imageData, N = Array.isArray(u.title) ? u.title[1] : u.title;
|
|
10696
|
-
f.innerHTML =
|
|
10698
|
+
f.innerHTML = eg(Ue(N) ? N.call(t, R, A) : "".concat(S, " (").concat(A.naturalWidth, " × ").concat(A.naturalHeight, ")"));
|
|
10697
10699
|
}, z, O;
|
|
10698
10700
|
return Ee(l, Oi, W, {
|
|
10699
10701
|
once: !0
|
|
@@ -10755,9 +10757,9 @@ var ag = {
|
|
|
10755
10757
|
if (t = Number(t), l = Number(l), this.viewed && !this.played && h.movable) {
|
|
10756
10758
|
var m = v.x, x = v.y, S = !1;
|
|
10757
10759
|
if (nt(t) ? S = !0 : t = m, nt(l) ? S = !0 : l = x, S) {
|
|
10758
|
-
if (Ue(h.move) && Ee(f,
|
|
10760
|
+
if (Ue(h.move) && Ee(f, Wu, h.move, {
|
|
10759
10761
|
once: !0
|
|
10760
|
-
}), ot(f,
|
|
10762
|
+
}), ot(f, Wu, {
|
|
10761
10763
|
x: t,
|
|
10762
10764
|
y: l,
|
|
10763
10765
|
oldX: m,
|
|
@@ -10766,9 +10768,9 @@ var ag = {
|
|
|
10766
10768
|
}) === !1)
|
|
10767
10769
|
return this;
|
|
10768
10770
|
v.x = t, v.y = l, v.left = t, v.top = l, this.moving = !0, this.renderImage(function() {
|
|
10769
|
-
r.moving = !1, Ue(h.moved) && Ee(f,
|
|
10771
|
+
r.moving = !1, Ue(h.moved) && Ee(f, ju, h.moved, {
|
|
10770
10772
|
once: !0
|
|
10771
|
-
}), ot(f,
|
|
10773
|
+
}), ot(f, ju, {
|
|
10772
10774
|
x: t,
|
|
10773
10775
|
y: l,
|
|
10774
10776
|
oldX: m,
|
|
@@ -10799,17 +10801,17 @@ var ag = {
|
|
|
10799
10801
|
var r = this, l = this.element, u = this.options, f = this.imageData;
|
|
10800
10802
|
if (t = Number(t), nt(t) && this.viewed && !this.played && u.rotatable) {
|
|
10801
10803
|
var h = f.rotate;
|
|
10802
|
-
if (Ue(u.rotate) && Ee(l,
|
|
10804
|
+
if (Ue(u.rotate) && Ee(l, qu, u.rotate, {
|
|
10803
10805
|
once: !0
|
|
10804
|
-
}), ot(l,
|
|
10806
|
+
}), ot(l, qu, {
|
|
10805
10807
|
degree: t,
|
|
10806
10808
|
oldDegree: h
|
|
10807
10809
|
}) === !1)
|
|
10808
10810
|
return this;
|
|
10809
10811
|
f.rotate = t, this.rotating = !0, this.renderImage(function() {
|
|
10810
|
-
r.rotating = !1, Ue(u.rotated) && Ee(l,
|
|
10812
|
+
r.rotating = !1, Ue(u.rotated) && Ee(l, Uu, u.rotated, {
|
|
10811
10813
|
once: !0
|
|
10812
|
-
}), ot(l,
|
|
10814
|
+
}), ot(l, Uu, {
|
|
10813
10815
|
degree: t,
|
|
10814
10816
|
oldDegree: h
|
|
10815
10817
|
}, {
|
|
@@ -10846,9 +10848,9 @@ var ag = {
|
|
|
10846
10848
|
if (t = Number(t), l = Number(l), this.viewed && !this.played && f.scalable) {
|
|
10847
10849
|
var v = h.scaleX, m = h.scaleY, x = !1;
|
|
10848
10850
|
if (nt(t) ? x = !0 : t = v, nt(l) ? x = !0 : l = m, x) {
|
|
10849
|
-
if (Ue(f.scale) && Ee(u,
|
|
10851
|
+
if (Ue(f.scale) && Ee(u, Gu, f.scale, {
|
|
10850
10852
|
once: !0
|
|
10851
|
-
}), ot(u,
|
|
10853
|
+
}), ot(u, Gu, {
|
|
10852
10854
|
scaleX: t,
|
|
10853
10855
|
scaleY: l,
|
|
10854
10856
|
oldScaleX: v,
|
|
@@ -10856,9 +10858,9 @@ var ag = {
|
|
|
10856
10858
|
}) === !1)
|
|
10857
10859
|
return this;
|
|
10858
10860
|
h.scaleX = t, h.scaleY = l, this.scaling = !0, this.renderImage(function() {
|
|
10859
|
-
r.scaling = !1, Ue(f.scaled) && Ee(u,
|
|
10861
|
+
r.scaling = !1, Ue(f.scaled) && Ee(u, Ku, f.scaled, {
|
|
10860
10862
|
once: !0
|
|
10861
|
-
}), ot(u,
|
|
10863
|
+
}), ot(u, Ku, {
|
|
10862
10864
|
scaleX: t,
|
|
10863
10865
|
scaleY: l,
|
|
10864
10866
|
oldScaleX: v,
|
|
@@ -10911,25 +10913,25 @@ var ag = {
|
|
|
10911
10913
|
break;
|
|
10912
10914
|
}
|
|
10913
10915
|
var H = O * t, V = M * t, ne = H - W, ue = V - z, se = S.ratio;
|
|
10914
|
-
if (Ue(m.zoom) && Ee(v,
|
|
10916
|
+
if (Ue(m.zoom) && Ee(v, Vu, m.zoom, {
|
|
10915
10917
|
once: !0
|
|
10916
|
-
}), ot(v,
|
|
10918
|
+
}), ot(v, Vu, {
|
|
10917
10919
|
ratio: t,
|
|
10918
10920
|
oldRatio: se,
|
|
10919
10921
|
originalEvent: f
|
|
10920
10922
|
}) === !1)
|
|
10921
10923
|
return this;
|
|
10922
10924
|
if (this.zooming = !0, f) {
|
|
10923
|
-
var de =
|
|
10925
|
+
var de = ng(this.viewer), Oe = x && Object.keys(x).length > 0 ? ag(x) : {
|
|
10924
10926
|
pageX: f.pageX,
|
|
10925
10927
|
pageY: f.pageY
|
|
10926
10928
|
};
|
|
10927
10929
|
S.x -= ne * ((Oe.pageX - de.left - R) / W), S.y -= ue * ((Oe.pageY - de.top - L) / z);
|
|
10928
10930
|
} else Br(u) && nt(u.x) && nt(u.y) ? (S.x -= ne * ((u.x - R) / W), S.y -= ue * ((u.y - L) / z)) : (S.x -= ne / 2, S.y -= ue / 2);
|
|
10929
10931
|
S.left = S.x, S.top = S.y, S.width = H, S.height = V, S.oldRatio = se, S.ratio = t, this.renderImage(function() {
|
|
10930
|
-
r.zooming = !1, Ue(m.zoomed) && Ee(v,
|
|
10932
|
+
r.zooming = !1, Ue(m.zoomed) && Ee(v, Qu, m.zoomed, {
|
|
10931
10933
|
once: !0
|
|
10932
|
-
}), ot(v,
|
|
10934
|
+
}), ot(v, Qu, {
|
|
10933
10935
|
ratio: t,
|
|
10934
10936
|
oldRatio: se,
|
|
10935
10937
|
originalEvent: f
|
|
@@ -10950,9 +10952,9 @@ var ag = {
|
|
|
10950
10952
|
if (!this.isShown || this.played)
|
|
10951
10953
|
return this;
|
|
10952
10954
|
var l = this.element, u = this.options;
|
|
10953
|
-
if (Ue(u.play) && Ee(l,
|
|
10955
|
+
if (Ue(u.play) && Ee(l, Xu, u.play, {
|
|
10954
10956
|
once: !0
|
|
10955
|
-
}), ot(l,
|
|
10957
|
+
}), ot(l, Xu) === !1)
|
|
10956
10958
|
return this;
|
|
10957
10959
|
var f = this.player, h = this.loadImage.bind(this), v = [], m = 0, x = 0;
|
|
10958
10960
|
if (this.played = !0, this.onLoadWhenPlay = h, r && this.requestFullscreen(r), Le(f, Mr), Ke(this.items, function(L, W) {
|
|
@@ -10980,9 +10982,9 @@ var ag = {
|
|
|
10980
10982
|
if (!this.played)
|
|
10981
10983
|
return this;
|
|
10982
10984
|
var r = this.element, l = this.options;
|
|
10983
|
-
if (Ue(l.stop) && Ee(r,
|
|
10985
|
+
if (Ue(l.stop) && Ee(r, Ju, l.stop, {
|
|
10984
10986
|
once: !0
|
|
10985
|
-
}), ot(r,
|
|
10987
|
+
}), ot(r, Ju) === !1)
|
|
10986
10988
|
return this;
|
|
10987
10989
|
var u = this.player;
|
|
10988
10990
|
return clearTimeout(this.playing.timeout), this.playing = !1, this.played = !1, Ke(u.getElementsByTagName("img"), function(f) {
|
|
@@ -10992,7 +10994,7 @@ var ag = {
|
|
|
10992
10994
|
// Enter modal mode (only available in inline mode)
|
|
10993
10995
|
full: function() {
|
|
10994
10996
|
var t = this, r = this.options, l = this.viewer, u = this.image, f = this.list;
|
|
10995
|
-
return !this.isShown || this.played || this.fulled || !r.inline ? this : (this.fulled = !0, this.open(), Le(this.button,
|
|
10997
|
+
return !this.isShown || this.played || this.fulled || !r.inline ? this : (this.fulled = !0, this.open(), Le(this.button, _u), r.transition && (Be(f, it), this.viewed && Be(u, it)), Le(l, Hs), l.setAttribute("role", "dialog"), l.setAttribute("aria-labelledby", this.title.id), l.setAttribute("aria-modal", !0), l.removeAttribute("style"), fn(l, {
|
|
10996
10998
|
zIndex: r.zIndex
|
|
10997
10999
|
}), r.focus && this.enforceFocus(), this.initContainer(), this.viewerData = Kt({}, this.containerData), this.renderList(), this.viewed && this.initImage(function() {
|
|
10998
11000
|
t.renderImage(function() {
|
|
@@ -11005,7 +11007,7 @@ var ag = {
|
|
|
11005
11007
|
// Exit modal mode (only available in inline mode)
|
|
11006
11008
|
exit: function() {
|
|
11007
11009
|
var t = this, r = this.options, l = this.viewer, u = this.image, f = this.list;
|
|
11008
|
-
return !this.isShown || this.played || !this.fulled || !r.inline ? this : (this.fulled = !1, this.close(), Be(this.button,
|
|
11010
|
+
return !this.isShown || this.played || !this.fulled || !r.inline ? this : (this.fulled = !1, this.close(), Be(this.button, _u), r.transition && (Be(f, it), this.viewed && Be(u, it)), r.focus && this.clearEnforceFocus(), l.removeAttribute("role"), l.removeAttribute("aria-labelledby"), l.removeAttribute("aria-modal"), Be(l, Hs), fn(l, {
|
|
11009
11011
|
zIndex: r.zIndexInline
|
|
11010
11012
|
}), this.viewerData = Kt({}, this.parentData), this.renderViewer(), this.renderList(), this.viewed && this.initImage(function() {
|
|
11011
11013
|
t.renderImage(function() {
|
|
@@ -11078,14 +11080,14 @@ var ag = {
|
|
|
11078
11080
|
var t = this.element, r = this.options;
|
|
11079
11081
|
return t[Ne] ? (this.destroyed = !0, this.ready ? (this.played && this.stop(), r.inline ? (this.fulled && this.exit(), this.unbind()) : this.isShown ? (this.viewing && (this.imageRendering ? this.imageRendering.abort() : this.imageInitializing && this.imageInitializing.abort()), this.hiding && this.transitioning.abort(), this.hidden()) : this.showing && (this.transitioning.abort(), this.hidden()), this.ready = !1, this.viewer.parentNode.removeChild(this.viewer)) : r.inline && (this.delaying ? this.delaying.abort() : this.initializing && this.initializing.abort()), r.inline || Ge(t, qr, this.onStart), t[Ne] = void 0, this) : this;
|
|
11080
11082
|
}
|
|
11081
|
-
},
|
|
11083
|
+
}, cg = {
|
|
11082
11084
|
getImageURL: function(t) {
|
|
11083
11085
|
var r = this.options.url;
|
|
11084
11086
|
return Di(r) ? r = t.getAttribute(r) : Ue(r) ? r = r.call(this, t) : r = "", r;
|
|
11085
11087
|
},
|
|
11086
11088
|
enforceFocus: function() {
|
|
11087
11089
|
var t = this;
|
|
11088
|
-
this.clearEnforceFocus(), Ee(document,
|
|
11090
|
+
this.clearEnforceFocus(), Ee(document, Au, this.onFocusin = function(r) {
|
|
11089
11091
|
var l = t.viewer, u = r.target;
|
|
11090
11092
|
if (!(u === document || u === l || l.contains(u))) {
|
|
11091
11093
|
for (; u; ) {
|
|
@@ -11098,27 +11100,27 @@ var ag = {
|
|
|
11098
11100
|
});
|
|
11099
11101
|
},
|
|
11100
11102
|
clearEnforceFocus: function() {
|
|
11101
|
-
this.onFocusin && (Ge(document,
|
|
11103
|
+
this.onFocusin && (Ge(document, Au, this.onFocusin), this.onFocusin = null);
|
|
11102
11104
|
},
|
|
11103
11105
|
open: function() {
|
|
11104
11106
|
var t = this.body;
|
|
11105
|
-
Le(t,
|
|
11107
|
+
Le(t, Lu), this.scrollbarWidth > 0 && (t.style.paddingRight = "".concat(this.scrollbarWidth + (parseFloat(this.initialBodyComputedPaddingRight) || 0), "px"));
|
|
11106
11108
|
},
|
|
11107
11109
|
close: function() {
|
|
11108
11110
|
var t = this.body;
|
|
11109
|
-
Be(t,
|
|
11111
|
+
Be(t, Lu), this.scrollbarWidth > 0 && (t.style.paddingRight = this.initialBodyPaddingRight);
|
|
11110
11112
|
},
|
|
11111
11113
|
shown: function() {
|
|
11112
11114
|
var t = this.element, r = this.options, l = this.viewer;
|
|
11113
|
-
this.fulled = !0, this.isShown = !0, this.render(), this.bind(), this.showing = !1, r.focus && (l.focus(), this.enforceFocus()), Ue(r.shown) && Ee(t,
|
|
11115
|
+
this.fulled = !0, this.isShown = !0, this.render(), this.bind(), this.showing = !1, r.focus && (l.focus(), this.enforceFocus()), Ue(r.shown) && Ee(t, Pu, r.shown, {
|
|
11114
11116
|
once: !0
|
|
11115
|
-
}), ot(t,
|
|
11117
|
+
}), ot(t, Pu) !== !1 && this.ready && this.isShown && !this.hiding && this.view(this.index);
|
|
11116
11118
|
},
|
|
11117
11119
|
hidden: function() {
|
|
11118
11120
|
var t = this.element, r = this.options, l = this.viewer;
|
|
11119
|
-
r.fucus && this.clearEnforceFocus(), this.close(), this.unbind(), Le(l, ir), l.removeAttribute("role"), l.removeAttribute("aria-labelledby"), l.removeAttribute("aria-modal"), l.setAttribute("aria-hidden", !0), this.resetList(), this.resetImage(), this.fulled = !1, this.viewed = !1, this.isShown = !1, this.hiding = !1, this.destroyed || (Ue(r.hidden) && Ee(t,
|
|
11121
|
+
r.fucus && this.clearEnforceFocus(), this.close(), this.unbind(), Le(l, ir), l.removeAttribute("role"), l.removeAttribute("aria-labelledby"), l.removeAttribute("aria-modal"), l.setAttribute("aria-hidden", !0), this.resetList(), this.resetImage(), this.fulled = !1, this.viewed = !1, this.isShown = !1, this.hiding = !1, this.destroyed || (Ue(r.hidden) && Ee(t, Bu, r.hidden, {
|
|
11120
11122
|
once: !0
|
|
11121
|
-
}), ot(t,
|
|
11123
|
+
}), ot(t, Bu, null, {
|
|
11122
11124
|
cancelable: !1
|
|
11123
11125
|
}));
|
|
11124
11126
|
},
|
|
@@ -11142,9 +11144,9 @@ var ag = {
|
|
|
11142
11144
|
(f !== 0 || h !== 0) && (this.pointerMoved = !0, this.move(f, h, t));
|
|
11143
11145
|
break;
|
|
11144
11146
|
case Ti:
|
|
11145
|
-
this.zoom(
|
|
11147
|
+
this.zoom(ig(l), !1, null, t);
|
|
11146
11148
|
break;
|
|
11147
|
-
case
|
|
11149
|
+
case $c: {
|
|
11148
11150
|
this.action = "switched";
|
|
11149
11151
|
var v = Math.abs(f);
|
|
11150
11152
|
v > 1 && v > Math.abs(h) && (this.pointers = {}, f > 1 ? this.prev(r.loop) : f < -1 && this.next(r.loop));
|
|
@@ -11160,18 +11162,18 @@ var ag = {
|
|
|
11160
11162
|
var t = this.imageData, r = this.viewerData;
|
|
11161
11163
|
return this.length > 1 && t.x >= 0 && t.y >= 0 && t.width <= r.width && t.height <= r.height;
|
|
11162
11164
|
}
|
|
11163
|
-
},
|
|
11165
|
+
}, fg = En.Viewer, dg = /* @__PURE__ */ function(o) {
|
|
11164
11166
|
return function() {
|
|
11165
11167
|
return o += 1, o;
|
|
11166
11168
|
};
|
|
11167
|
-
}(-1),
|
|
11169
|
+
}(-1), zc = /* @__PURE__ */ function() {
|
|
11168
11170
|
function o(t) {
|
|
11169
11171
|
var r = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {};
|
|
11170
|
-
if (
|
|
11172
|
+
if (Mp(this, o), !t || t.nodeType !== 1)
|
|
11171
11173
|
throw new Error("The first argument is required and must be an element.");
|
|
11172
|
-
this.element = t, this.options = Kt({},
|
|
11174
|
+
this.element = t, this.options = Kt({}, Tu, Br(r) && r), this.action = !1, this.fading = !1, this.fulled = !1, this.hiding = !1, this.imageClicked = !1, this.imageData = {}, this.index = this.options.initialViewIndex, this.isImg = !1, this.isShown = !1, this.length = 0, this.moving = !1, this.played = !1, this.playing = !1, this.pointers = {}, this.ready = !1, this.rotating = !1, this.scaling = !1, this.showing = !1, this.timeout = !1, this.tooltipping = !1, this.viewed = !1, this.viewing = !1, this.wheeling = !1, this.zooming = !1, this.pointerMoved = !1, this.id = dg(), this.init();
|
|
11173
11175
|
}
|
|
11174
|
-
return
|
|
11176
|
+
return Pp(o, [{
|
|
11175
11177
|
key: "init",
|
|
11176
11178
|
value: function() {
|
|
11177
11179
|
var r = this, l = this.element, u = this.options;
|
|
@@ -11227,7 +11229,7 @@ var ag = {
|
|
|
11227
11229
|
value: function() {
|
|
11228
11230
|
if (!this.ready) {
|
|
11229
11231
|
var r = this.element, l = this.options, u = r.parentNode, f = document.createElement("div");
|
|
11230
|
-
f.innerHTML =
|
|
11232
|
+
f.innerHTML = Hp;
|
|
11231
11233
|
var h = f.querySelector(".".concat(Ne, "-container")), v = h.querySelector(".".concat(Ne, "-title")), m = h.querySelector(".".concat(Ne, "-toolbar")), x = h.querySelector(".".concat(Ne, "-navbar")), S = h.querySelector(".".concat(Ne, "-button")), R = h.querySelector(".".concat(Ne, "-canvas"));
|
|
11232
11234
|
if (this.parent = u, this.viewer = h, this.title = v, this.toolbar = m, this.navbar = x, this.button = S, this.canvas = R, this.footer = h.querySelector(".".concat(Ne, "-footer")), this.tooltipBox = h.querySelector(".".concat(Ne, "-tooltip")), this.player = h.querySelector(".".concat(Ne, "-player")), this.list = h.querySelector(".".concat(Ne, "-list")), h.id = "".concat(Ne).concat(this.id), v.id = "".concat(Ne, "Title").concat(this.id), Le(v, l.title ? xa(Array.isArray(l.title) ? l.title[0] : l.title) : ir), Le(x, l.navbar ? xa(l.navbar) : ir), Ni(S, ir, !l.button), l.keyboard && S.setAttribute("tabindex", 0), l.backdrop && (Le(h, "".concat(Ne, "-backdrop")), !l.inline && l.backdrop !== "static" && js(R, Oa, "hide")), Di(l.className) && l.className && l.className.split(no).forEach(function(H) {
|
|
11233
11235
|
Le(h, H);
|
|
@@ -11249,21 +11251,21 @@ var ag = {
|
|
|
11249
11251
|
});
|
|
11250
11252
|
}
|
|
11251
11253
|
if (l.inline)
|
|
11252
|
-
Le(S,
|
|
11254
|
+
Le(S, jp), fn(h, {
|
|
11253
11255
|
zIndex: l.zIndexInline
|
|
11254
11256
|
}), window.getComputedStyle(u).position === "static" && fn(u, {
|
|
11255
11257
|
position: "relative"
|
|
11256
11258
|
}), u.insertBefore(h, r.nextSibling);
|
|
11257
11259
|
else {
|
|
11258
|
-
Le(S,
|
|
11260
|
+
Le(S, Wp), Le(h, Hs), Le(h, Sa), Le(h, ir), fn(h, {
|
|
11259
11261
|
zIndex: l.zIndex
|
|
11260
11262
|
});
|
|
11261
11263
|
var N = l.container;
|
|
11262
11264
|
Di(N) && (N = r.ownerDocument.querySelector(N)), N || (N = this.body), N.appendChild(h);
|
|
11263
11265
|
}
|
|
11264
|
-
if (l.inline && (this.render(), this.bind(), this.isShown = !0), this.ready = !0, Ue(l.ready) && Ee(r,
|
|
11266
|
+
if (l.inline && (this.render(), this.bind(), this.isShown = !0), this.ready = !0, Ue(l.ready) && Ee(r, $u, l.ready, {
|
|
11265
11267
|
once: !0
|
|
11266
|
-
}), ot(r,
|
|
11268
|
+
}), ot(r, $u) === !1) {
|
|
11267
11269
|
this.ready = !1;
|
|
11268
11270
|
return;
|
|
11269
11271
|
}
|
|
@@ -11277,7 +11279,7 @@ var ag = {
|
|
|
11277
11279
|
}], [{
|
|
11278
11280
|
key: "noConflict",
|
|
11279
11281
|
value: function() {
|
|
11280
|
-
return window.Viewer =
|
|
11282
|
+
return window.Viewer = fg, o;
|
|
11281
11283
|
}
|
|
11282
11284
|
/**
|
|
11283
11285
|
* Change the default options.
|
|
@@ -11286,60 +11288,60 @@ var ag = {
|
|
|
11286
11288
|
}, {
|
|
11287
11289
|
key: "setDefaults",
|
|
11288
11290
|
value: function(r) {
|
|
11289
|
-
Kt(
|
|
11291
|
+
Kt(Tu, Br(r) && r);
|
|
11290
11292
|
}
|
|
11291
11293
|
}]);
|
|
11292
11294
|
}();
|
|
11293
|
-
Kt(
|
|
11294
|
-
var
|
|
11295
|
-
function
|
|
11296
|
-
var t =
|
|
11295
|
+
Kt(zc.prototype, sg, og, lg, ug, cg);
|
|
11296
|
+
var hg = typeof global == "object" && global && global.Object === Object && global, Bc = hg, pg = typeof self == "object" && self && self.Object === Object && self, gg = Bc || pg || Function("return this")(), io = gg, mg = io.Symbol, Da = mg, Hc = Object.prototype, vg = Hc.hasOwnProperty, yg = Hc.toString, Ci = Da ? Da.toStringTag : void 0;
|
|
11297
|
+
function bg(o) {
|
|
11298
|
+
var t = vg.call(o, Ci), r = o[Ci];
|
|
11297
11299
|
try {
|
|
11298
11300
|
o[Ci] = void 0;
|
|
11299
11301
|
var l = !0;
|
|
11300
11302
|
} catch {
|
|
11301
11303
|
}
|
|
11302
|
-
var u =
|
|
11304
|
+
var u = yg.call(o);
|
|
11303
11305
|
return l && (t ? o[Ci] = r : delete o[Ci]), u;
|
|
11304
11306
|
}
|
|
11305
|
-
var
|
|
11306
|
-
function
|
|
11307
|
-
return
|
|
11307
|
+
var xg = Object.prototype, wg = xg.toString;
|
|
11308
|
+
function kg(o) {
|
|
11309
|
+
return wg.call(o);
|
|
11308
11310
|
}
|
|
11309
|
-
var
|
|
11311
|
+
var Sg = "[object Null]", Cg = "[object Undefined]", Yu = Da ? Da.toStringTag : void 0;
|
|
11310
11312
|
function ao(o) {
|
|
11311
|
-
return o == null ? o === void 0 ?
|
|
11313
|
+
return o == null ? o === void 0 ? Cg : Sg : Yu && Yu in Object(o) ? bg(o) : kg(o);
|
|
11312
11314
|
}
|
|
11313
11315
|
function so(o) {
|
|
11314
11316
|
return o != null && typeof o == "object";
|
|
11315
11317
|
}
|
|
11316
|
-
var
|
|
11318
|
+
var Tg = Array.isArray, _g = Tg;
|
|
11317
11319
|
function oo(o) {
|
|
11318
11320
|
var t = typeof o;
|
|
11319
11321
|
return o != null && (t == "object" || t == "function");
|
|
11320
11322
|
}
|
|
11321
|
-
function
|
|
11323
|
+
function Wc(o) {
|
|
11322
11324
|
return o;
|
|
11323
11325
|
}
|
|
11324
|
-
var
|
|
11325
|
-
function
|
|
11326
|
+
var Lg = "[object AsyncFunction]", Eg = "[object Function]", Ag = "[object GeneratorFunction]", Ig = "[object Proxy]";
|
|
11327
|
+
function jc(o) {
|
|
11326
11328
|
if (!oo(o))
|
|
11327
11329
|
return !1;
|
|
11328
11330
|
var t = ao(o);
|
|
11329
|
-
return t ==
|
|
11331
|
+
return t == Eg || t == Ag || t == Lg || t == Ig;
|
|
11330
11332
|
}
|
|
11331
|
-
var
|
|
11333
|
+
var Og = io["__core-js_shared__"], Rs = Og, Zu = function() {
|
|
11332
11334
|
var o = /[^.]+$/.exec(Rs && Rs.keys && Rs.keys.IE_PROTO || "");
|
|
11333
11335
|
return o ? "Symbol(src)_1." + o : "";
|
|
11334
11336
|
}();
|
|
11335
|
-
function
|
|
11336
|
-
return !!
|
|
11337
|
+
function Dg(o) {
|
|
11338
|
+
return !!Zu && Zu in o;
|
|
11337
11339
|
}
|
|
11338
|
-
var
|
|
11339
|
-
function
|
|
11340
|
+
var Ng = Function.prototype, Rg = Ng.toString;
|
|
11341
|
+
function Fg(o) {
|
|
11340
11342
|
if (o != null) {
|
|
11341
11343
|
try {
|
|
11342
|
-
return
|
|
11344
|
+
return Rg.call(o);
|
|
11343
11345
|
} catch {
|
|
11344
11346
|
}
|
|
11345
11347
|
try {
|
|
@@ -11349,23 +11351,23 @@ function Rg(o) {
|
|
|
11349
11351
|
}
|
|
11350
11352
|
return "";
|
|
11351
11353
|
}
|
|
11352
|
-
var
|
|
11353
|
-
"^" +
|
|
11354
|
+
var $g = /[\\^$.*+?()[\]{}|]/g, Mg = /^\[object .+?Constructor\]$/, Pg = Function.prototype, zg = Object.prototype, Bg = Pg.toString, Hg = zg.hasOwnProperty, Wg = RegExp(
|
|
11355
|
+
"^" + Bg.call(Hg).replace($g, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"
|
|
11354
11356
|
);
|
|
11355
|
-
function
|
|
11356
|
-
if (!oo(o) ||
|
|
11357
|
+
function jg(o) {
|
|
11358
|
+
if (!oo(o) || Dg(o))
|
|
11357
11359
|
return !1;
|
|
11358
|
-
var t =
|
|
11359
|
-
return t.test(
|
|
11360
|
+
var t = jc(o) ? Wg : Mg;
|
|
11361
|
+
return t.test(Fg(o));
|
|
11360
11362
|
}
|
|
11361
|
-
function
|
|
11363
|
+
function qg(o, t) {
|
|
11362
11364
|
return o == null ? void 0 : o[t];
|
|
11363
11365
|
}
|
|
11364
|
-
function
|
|
11365
|
-
var r =
|
|
11366
|
-
return
|
|
11366
|
+
function Ug(o, t) {
|
|
11367
|
+
var r = qg(o, t);
|
|
11368
|
+
return jg(r) ? r : void 0;
|
|
11367
11369
|
}
|
|
11368
|
-
function
|
|
11370
|
+
function Gg(o, t, r) {
|
|
11369
11371
|
switch (r.length) {
|
|
11370
11372
|
case 0:
|
|
11371
11373
|
return o.call(t);
|
|
@@ -11378,43 +11380,43 @@ function Ug(o, t, r) {
|
|
|
11378
11380
|
}
|
|
11379
11381
|
return o.apply(t, r);
|
|
11380
11382
|
}
|
|
11381
|
-
var
|
|
11382
|
-
function
|
|
11383
|
+
var Kg = 800, Vg = 16, Qg = Date.now;
|
|
11384
|
+
function Xg(o) {
|
|
11383
11385
|
var t = 0, r = 0;
|
|
11384
11386
|
return function() {
|
|
11385
|
-
var l =
|
|
11387
|
+
var l = Qg(), u = Vg - (l - r);
|
|
11386
11388
|
if (r = l, u > 0) {
|
|
11387
|
-
if (++t >=
|
|
11389
|
+
if (++t >= Kg)
|
|
11388
11390
|
return arguments[0];
|
|
11389
11391
|
} else
|
|
11390
11392
|
t = 0;
|
|
11391
11393
|
return o.apply(void 0, arguments);
|
|
11392
11394
|
};
|
|
11393
11395
|
}
|
|
11394
|
-
function
|
|
11396
|
+
function Jg(o) {
|
|
11395
11397
|
return function() {
|
|
11396
11398
|
return o;
|
|
11397
11399
|
};
|
|
11398
11400
|
}
|
|
11399
|
-
var
|
|
11401
|
+
var Yg = function() {
|
|
11400
11402
|
try {
|
|
11401
|
-
var o =
|
|
11403
|
+
var o = Ug(Object, "defineProperty");
|
|
11402
11404
|
return o({}, "", {}), o;
|
|
11403
11405
|
} catch {
|
|
11404
11406
|
}
|
|
11405
|
-
}(), Na =
|
|
11407
|
+
}(), Na = Yg, Zg = Na ? function(o, t) {
|
|
11406
11408
|
return Na(o, "toString", {
|
|
11407
11409
|
configurable: !0,
|
|
11408
11410
|
enumerable: !1,
|
|
11409
|
-
value:
|
|
11411
|
+
value: Jg(t),
|
|
11410
11412
|
writable: !0
|
|
11411
11413
|
});
|
|
11412
|
-
} :
|
|
11413
|
-
function
|
|
11414
|
+
} : Wc, em = Zg, tm = Xg(em), nm = tm, rm = 9007199254740991, im = /^(?:0|[1-9]\d*)$/;
|
|
11415
|
+
function qc(o, t) {
|
|
11414
11416
|
var r = typeof o;
|
|
11415
|
-
return t = t ??
|
|
11417
|
+
return t = t ?? rm, !!t && (r == "number" || r != "symbol" && im.test(o)) && o > -1 && o % 1 == 0 && o < t;
|
|
11416
11418
|
}
|
|
11417
|
-
function
|
|
11419
|
+
function Uc(o, t, r) {
|
|
11418
11420
|
t == "__proto__" && Na ? Na(o, t, {
|
|
11419
11421
|
configurable: !0,
|
|
11420
11422
|
enumerable: !0,
|
|
@@ -11422,136 +11424,136 @@ function Wc(o, t, r) {
|
|
|
11422
11424
|
writable: !0
|
|
11423
11425
|
}) : o[t] = r;
|
|
11424
11426
|
}
|
|
11425
|
-
function
|
|
11427
|
+
function Gc(o, t) {
|
|
11426
11428
|
return o === t || o !== o && t !== t;
|
|
11427
11429
|
}
|
|
11428
|
-
var
|
|
11429
|
-
function
|
|
11430
|
+
var am = Object.prototype, sm = am.hasOwnProperty;
|
|
11431
|
+
function Kc(o, t, r) {
|
|
11430
11432
|
var l = o[t];
|
|
11431
|
-
(!(
|
|
11433
|
+
(!(sm.call(o, t) && Gc(l, r)) || r === void 0 && !(t in o)) && Uc(o, t, r);
|
|
11432
11434
|
}
|
|
11433
|
-
function
|
|
11435
|
+
function om(o, t, r, l) {
|
|
11434
11436
|
var u = !r;
|
|
11435
11437
|
r || (r = {});
|
|
11436
11438
|
for (var f = -1, h = t.length; ++f < h; ) {
|
|
11437
11439
|
var v = t[f], m = void 0;
|
|
11438
|
-
m === void 0 && (m = o[v]), u ?
|
|
11440
|
+
m === void 0 && (m = o[v]), u ? Uc(r, v, m) : Kc(r, v, m);
|
|
11439
11441
|
}
|
|
11440
11442
|
return r;
|
|
11441
11443
|
}
|
|
11442
|
-
var
|
|
11443
|
-
function
|
|
11444
|
-
return t =
|
|
11445
|
-
for (var l = arguments, u = -1, f =
|
|
11444
|
+
var ec = Math.max;
|
|
11445
|
+
function lm(o, t, r) {
|
|
11446
|
+
return t = ec(t === void 0 ? o.length - 1 : t, 0), function() {
|
|
11447
|
+
for (var l = arguments, u = -1, f = ec(l.length - t, 0), h = Array(f); ++u < f; )
|
|
11446
11448
|
h[u] = l[t + u];
|
|
11447
11449
|
u = -1;
|
|
11448
11450
|
for (var v = Array(t + 1); ++u < t; )
|
|
11449
11451
|
v[u] = l[u];
|
|
11450
|
-
return v[t] = r(h),
|
|
11452
|
+
return v[t] = r(h), Gg(o, this, v);
|
|
11451
11453
|
};
|
|
11452
11454
|
}
|
|
11453
|
-
function
|
|
11454
|
-
return
|
|
11455
|
+
function um(o, t) {
|
|
11456
|
+
return nm(lm(o, t, Wc), o + "");
|
|
11455
11457
|
}
|
|
11456
|
-
var
|
|
11457
|
-
function
|
|
11458
|
-
return typeof o == "number" && o > -1 && o % 1 == 0 && o <=
|
|
11458
|
+
var cm = 9007199254740991;
|
|
11459
|
+
function Vc(o) {
|
|
11460
|
+
return typeof o == "number" && o > -1 && o % 1 == 0 && o <= cm;
|
|
11459
11461
|
}
|
|
11460
11462
|
function lo(o) {
|
|
11461
|
-
return o != null &&
|
|
11463
|
+
return o != null && Vc(o.length) && !jc(o);
|
|
11462
11464
|
}
|
|
11463
|
-
function
|
|
11465
|
+
function fm(o, t, r) {
|
|
11464
11466
|
if (!oo(r))
|
|
11465
11467
|
return !1;
|
|
11466
11468
|
var l = typeof t;
|
|
11467
|
-
return (l == "number" ? lo(r) &&
|
|
11469
|
+
return (l == "number" ? lo(r) && qc(t, r.length) : l == "string" && t in r) ? Gc(r[t], o) : !1;
|
|
11468
11470
|
}
|
|
11469
|
-
function
|
|
11470
|
-
return
|
|
11471
|
+
function dm(o) {
|
|
11472
|
+
return um(function(t, r) {
|
|
11471
11473
|
var l = -1, u = r.length, f = u > 1 ? r[u - 1] : void 0, h = u > 2 ? r[2] : void 0;
|
|
11472
|
-
for (f = o.length > 3 && typeof f == "function" ? (u--, f) : void 0, h &&
|
|
11474
|
+
for (f = o.length > 3 && typeof f == "function" ? (u--, f) : void 0, h && fm(r[0], r[1], h) && (f = u < 3 ? void 0 : f, u = 1), t = Object(t); ++l < u; ) {
|
|
11473
11475
|
var v = r[l];
|
|
11474
11476
|
v && o(t, v, l, f);
|
|
11475
11477
|
}
|
|
11476
11478
|
return t;
|
|
11477
11479
|
});
|
|
11478
11480
|
}
|
|
11479
|
-
var
|
|
11480
|
-
function
|
|
11481
|
-
var t = o && o.constructor, r = typeof t == "function" && t.prototype ||
|
|
11481
|
+
var hm = Object.prototype;
|
|
11482
|
+
function Qc(o) {
|
|
11483
|
+
var t = o && o.constructor, r = typeof t == "function" && t.prototype || hm;
|
|
11482
11484
|
return o === r;
|
|
11483
11485
|
}
|
|
11484
|
-
function
|
|
11486
|
+
function pm(o, t) {
|
|
11485
11487
|
for (var r = -1, l = Array(o); ++r < o; )
|
|
11486
11488
|
l[r] = t(r);
|
|
11487
11489
|
return l;
|
|
11488
11490
|
}
|
|
11489
|
-
var
|
|
11490
|
-
function
|
|
11491
|
-
return so(o) && ao(o) ==
|
|
11491
|
+
var gm = "[object Arguments]";
|
|
11492
|
+
function tc(o) {
|
|
11493
|
+
return so(o) && ao(o) == gm;
|
|
11492
11494
|
}
|
|
11493
|
-
var
|
|
11495
|
+
var Xc = Object.prototype, mm = Xc.hasOwnProperty, vm = Xc.propertyIsEnumerable, ym = tc(/* @__PURE__ */ function() {
|
|
11494
11496
|
return arguments;
|
|
11495
|
-
}()) ?
|
|
11496
|
-
return so(o) &&
|
|
11497
|
-
},
|
|
11498
|
-
function
|
|
11497
|
+
}()) ? tc : function(o) {
|
|
11498
|
+
return so(o) && mm.call(o, "callee") && !vm.call(o, "callee");
|
|
11499
|
+
}, bm = ym;
|
|
11500
|
+
function xm() {
|
|
11499
11501
|
return !1;
|
|
11500
11502
|
}
|
|
11501
|
-
var
|
|
11502
|
-
Xe[
|
|
11503
|
-
Xe[
|
|
11504
|
-
function Vm(o) {
|
|
11505
|
-
return so(o) && Uc(o.length) && !!Xe[ao(o)];
|
|
11506
|
-
}
|
|
11503
|
+
var Jc = typeof exports == "object" && exports && !exports.nodeType && exports, nc = Jc && typeof module == "object" && module && !module.nodeType && module, wm = nc && nc.exports === Jc, rc = wm ? io.Buffer : void 0, km = rc ? rc.isBuffer : void 0, Sm = km || xm, Cm = Sm, Tm = "[object Arguments]", _m = "[object Array]", Lm = "[object Boolean]", Em = "[object Date]", Am = "[object Error]", Im = "[object Function]", Om = "[object Map]", Dm = "[object Number]", Nm = "[object Object]", Rm = "[object RegExp]", Fm = "[object Set]", $m = "[object String]", Mm = "[object WeakMap]", Pm = "[object ArrayBuffer]", zm = "[object DataView]", Bm = "[object Float32Array]", Hm = "[object Float64Array]", Wm = "[object Int8Array]", jm = "[object Int16Array]", qm = "[object Int32Array]", Um = "[object Uint8Array]", Gm = "[object Uint8ClampedArray]", Km = "[object Uint16Array]", Vm = "[object Uint32Array]", Xe = {};
|
|
11504
|
+
Xe[Bm] = Xe[Hm] = Xe[Wm] = Xe[jm] = Xe[qm] = Xe[Um] = Xe[Gm] = Xe[Km] = Xe[Vm] = !0;
|
|
11505
|
+
Xe[Tm] = Xe[_m] = Xe[Pm] = Xe[Lm] = Xe[zm] = Xe[Em] = Xe[Am] = Xe[Im] = Xe[Om] = Xe[Dm] = Xe[Nm] = Xe[Rm] = Xe[Fm] = Xe[$m] = Xe[Mm] = !1;
|
|
11507
11506
|
function Qm(o) {
|
|
11507
|
+
return so(o) && Vc(o.length) && !!Xe[ao(o)];
|
|
11508
|
+
}
|
|
11509
|
+
function Xm(o) {
|
|
11508
11510
|
return function(t) {
|
|
11509
11511
|
return o(t);
|
|
11510
11512
|
};
|
|
11511
11513
|
}
|
|
11512
|
-
var
|
|
11514
|
+
var Yc = typeof exports == "object" && exports && !exports.nodeType && exports, Ii = Yc && typeof module == "object" && module && !module.nodeType && module, Jm = Ii && Ii.exports === Yc, Fs = Jm && Bc.process, Ym = function() {
|
|
11513
11515
|
try {
|
|
11514
11516
|
var o = Ii && Ii.require && Ii.require("util").types;
|
|
11515
11517
|
return o || Fs && Fs.binding && Fs.binding("util");
|
|
11516
11518
|
} catch {
|
|
11517
11519
|
}
|
|
11518
|
-
}(),
|
|
11519
|
-
function
|
|
11520
|
-
var r =
|
|
11520
|
+
}(), ic = Ym, ac = ic && ic.isTypedArray, Zm = ac ? Xm(ac) : Qm, ev = Zm, tv = Object.prototype, nv = tv.hasOwnProperty;
|
|
11521
|
+
function rv(o, t) {
|
|
11522
|
+
var r = _g(o), l = !r && bm(o), u = !r && !l && Cm(o), f = !r && !l && !u && ev(o), h = r || l || u || f, v = h ? pm(o.length, String) : [], m = v.length;
|
|
11521
11523
|
for (var x in o)
|
|
11522
|
-
|
|
11524
|
+
nv.call(o, x) && !(h && (x == "length" || u && (x == "offset" || x == "parent") || f && (x == "buffer" || x == "byteLength" || x == "byteOffset") || qc(x, m))) && v.push(x);
|
|
11523
11525
|
return v;
|
|
11524
11526
|
}
|
|
11525
|
-
function
|
|
11527
|
+
function iv(o, t) {
|
|
11526
11528
|
return function(r) {
|
|
11527
11529
|
return o(t(r));
|
|
11528
11530
|
};
|
|
11529
11531
|
}
|
|
11530
|
-
var
|
|
11531
|
-
function
|
|
11532
|
-
if (!
|
|
11533
|
-
return
|
|
11532
|
+
var av = iv(Object.keys, Object), sv = av, ov = Object.prototype, lv = ov.hasOwnProperty;
|
|
11533
|
+
function uv(o) {
|
|
11534
|
+
if (!Qc(o))
|
|
11535
|
+
return sv(o);
|
|
11534
11536
|
var t = [];
|
|
11535
11537
|
for (var r in Object(o))
|
|
11536
|
-
|
|
11538
|
+
lv.call(o, r) && r != "constructor" && t.push(r);
|
|
11537
11539
|
return t;
|
|
11538
11540
|
}
|
|
11539
|
-
function
|
|
11540
|
-
return lo(o) ?
|
|
11541
|
+
function cv(o) {
|
|
11542
|
+
return lo(o) ? rv(o) : uv(o);
|
|
11541
11543
|
}
|
|
11542
|
-
var
|
|
11543
|
-
if (
|
|
11544
|
-
|
|
11544
|
+
var fv = Object.prototype, dv = fv.hasOwnProperty, hv = dm(function(o, t) {
|
|
11545
|
+
if (Qc(t) || lo(t)) {
|
|
11546
|
+
om(t, cv(t), o);
|
|
11545
11547
|
return;
|
|
11546
11548
|
}
|
|
11547
11549
|
for (var r in t)
|
|
11548
|
-
|
|
11549
|
-
}),
|
|
11550
|
-
const
|
|
11551
|
-
t =
|
|
11550
|
+
dv.call(t, r) && Kc(o, r, t[r]);
|
|
11551
|
+
}), pv = hv;
|
|
11552
|
+
const Zc = ({ images: o = [], options: t = {} } = {}) => {
|
|
11553
|
+
t = pv(t, {
|
|
11552
11554
|
inline: !1
|
|
11553
11555
|
});
|
|
11554
|
-
const r =
|
|
11556
|
+
const r = oh.extend({
|
|
11555
11557
|
render(h) {
|
|
11556
11558
|
return h(
|
|
11557
11559
|
"div",
|
|
@@ -11571,7 +11573,7 @@ const Xc = ({ images: o = [], options: t = {} } = {}) => {
|
|
|
11571
11573
|
}
|
|
11572
11574
|
}), l = new r();
|
|
11573
11575
|
l.$mount(), document.body.appendChild(l.$el);
|
|
11574
|
-
const u = new
|
|
11576
|
+
const u = new zc(l.$el, t), f = u.destroy.bind(u);
|
|
11575
11577
|
return u.destroy = function() {
|
|
11576
11578
|
return f(), l.$destroy(), document.body.removeChild(l.$el), u;
|
|
11577
11579
|
}, u.show(), l.$el.addEventListener("hidden", function() {
|
|
@@ -12133,7 +12135,7 @@ const Xc = ({ images: o = [], options: t = {} } = {}) => {
|
|
|
12133
12135
|
Se.setOptions({
|
|
12134
12136
|
breaks: !0
|
|
12135
12137
|
});
|
|
12136
|
-
const
|
|
12138
|
+
const gv = {
|
|
12137
12139
|
name: "OutputViewer",
|
|
12138
12140
|
components: {
|
|
12139
12141
|
codemirror: Us.codemirror,
|
|
@@ -12290,7 +12292,7 @@ const pv = {
|
|
|
12290
12292
|
return t[o] ? this.$t(t[o]) : o;
|
|
12291
12293
|
},
|
|
12292
12294
|
handleImageClick(o) {
|
|
12293
|
-
|
|
12295
|
+
Zc({
|
|
12294
12296
|
options: this.viewerOptions,
|
|
12295
12297
|
images: [o]
|
|
12296
12298
|
});
|
|
@@ -12450,7 +12452,7 @@ const pv = {
|
|
|
12450
12452
|
}
|
|
12451
12453
|
}
|
|
12452
12454
|
};
|
|
12453
|
-
var
|
|
12455
|
+
var mv = function() {
|
|
12454
12456
|
var t = this, r = t._self._c;
|
|
12455
12457
|
return r("div", { staticClass: "output-viewer" }, [t.title || t.$slots.title ? r("div", { staticClass: "output-viewer-header" }, [r("div", { staticClass: "output-viewer-title-row" }, [r("span", { staticClass: "output-viewer-title" }, [t._t("title", function() {
|
|
12456
12458
|
return [t._v(t._s(t.title))];
|
|
@@ -12487,18 +12489,18 @@ var gv = function() {
|
|
|
12487
12489
|
return t.handleImageClick(l.downloadUrl);
|
|
12488
12490
|
} } })]) : l.type === "file-pdf" ? r("div", [r("FilePdfViewer", { attrs: { element: l } })], 1) : l.type === "file-download" ? r("div", { staticClass: "file-download-content" }, [r("a", { staticClass: "file-download-link", attrs: { href: l.downloadUrl, target: "_blank", rel: "noopener noreferrer" } }, [t._v(t._s(l.filename))]), r("span", { staticClass: "file-download-hint" }, [t._v(t._s(t.$t("trace.clickToDownload")))])]) : t._e()]);
|
|
12489
12491
|
}), 0) : t._e()])]);
|
|
12490
|
-
},
|
|
12491
|
-
pv,
|
|
12492
|
+
}, vv = [], yv = /* @__PURE__ */ dn(
|
|
12492
12493
|
gv,
|
|
12493
12494
|
mv,
|
|
12495
|
+
vv,
|
|
12494
12496
|
!1,
|
|
12495
12497
|
null,
|
|
12496
12498
|
"889b8c5a"
|
|
12497
12499
|
);
|
|
12498
|
-
const
|
|
12499
|
-
var
|
|
12500
|
-
function
|
|
12501
|
-
return
|
|
12500
|
+
const ef = yv.exports;
|
|
12501
|
+
var sc = { exports: {} }, oc;
|
|
12502
|
+
function bv() {
|
|
12503
|
+
return oc || (oc = 1, function(o, t) {
|
|
12502
12504
|
(function(r) {
|
|
12503
12505
|
r(Vt());
|
|
12504
12506
|
})(function(r) {
|
|
@@ -12785,11 +12787,11 @@ function yv() {
|
|
|
12785
12787
|
};
|
|
12786
12788
|
}), r.defineMIME("text/xml", "xml"), r.defineMIME("application/xml", "xml"), r.mimeModes.hasOwnProperty("text/html") || r.defineMIME("text/html", { name: "xml", htmlMode: !0 });
|
|
12787
12789
|
});
|
|
12788
|
-
}()),
|
|
12790
|
+
}()), sc.exports;
|
|
12789
12791
|
}
|
|
12790
|
-
var
|
|
12791
|
-
function
|
|
12792
|
-
return
|
|
12792
|
+
var lc = { exports: {} }, uc;
|
|
12793
|
+
function xv() {
|
|
12794
|
+
return uc || (uc = 1, function(o, t) {
|
|
12793
12795
|
(function(r) {
|
|
12794
12796
|
r(Vt());
|
|
12795
12797
|
})(function(r) {
|
|
@@ -13007,11 +13009,11 @@ function bv() {
|
|
|
13007
13009
|
}
|
|
13008
13010
|
};
|
|
13009
13011
|
});
|
|
13010
|
-
}()),
|
|
13012
|
+
}()), lc.exports;
|
|
13011
13013
|
}
|
|
13012
13014
|
(function(o, t) {
|
|
13013
13015
|
(function(r) {
|
|
13014
|
-
r(Vt(),
|
|
13016
|
+
r(Vt(), bv(), xv());
|
|
13015
13017
|
})(function(r) {
|
|
13016
13018
|
r.defineMode("markdown", function(l, u) {
|
|
13017
13019
|
var f = r.getMode(l, "text/html"), h = f.name == "null";
|
|
@@ -13389,12 +13391,12 @@ function bv() {
|
|
|
13389
13391
|
}, "xml"), r.defineMIME("text/markdown", "markdown"), r.defineMIME("text/x-markdown", "markdown");
|
|
13390
13392
|
});
|
|
13391
13393
|
})();
|
|
13392
|
-
const
|
|
13394
|
+
const wv = {
|
|
13393
13395
|
name: "DebugTab",
|
|
13394
13396
|
components: {
|
|
13395
13397
|
codemirror: Us.codemirror,
|
|
13396
13398
|
FilePdfViewer: Zs,
|
|
13397
|
-
OutputViewer:
|
|
13399
|
+
OutputViewer: ef
|
|
13398
13400
|
},
|
|
13399
13401
|
props: {
|
|
13400
13402
|
selectedSpan: {
|
|
@@ -13787,7 +13789,7 @@ const xv = {
|
|
|
13787
13789
|
}
|
|
13788
13790
|
}
|
|
13789
13791
|
};
|
|
13790
|
-
var
|
|
13792
|
+
var kv = function() {
|
|
13791
13793
|
var t = this, r = t._self._c;
|
|
13792
13794
|
return r("div", { staticClass: "debug-content" }, [t.selectedSpan.type === "CLIENT" || t.selectedSpan.type === "EMBEDDING" ? r("div", { staticClass: "debug-client-form" }, [r("el-form", { attrs: { model: t.debugForm, "label-width": "60px", size: "small" } }, [t._l(t.debugForm.params, function(l, u) {
|
|
13793
13795
|
return r("div", { key: u, staticClass: "debug-form-row" }, [r("el-form-item", { attrs: { label: `${t.$t("debug.paramLabel")} ${u + 1}` } }, [r("el-row", { attrs: { gutter: 10, type: "flex", align: "middle" } }, [r("el-col", { attrs: { span: 8 } }, [r("el-input", { attrs: { placeholder: t.$t("debug.paramName") }, on: { input: t.handleDebugParamChange }, model: { value: l.key, callback: function(f) {
|
|
@@ -13822,26 +13824,26 @@ var wv = function() {
|
|
|
13822
13824
|
return t.removeDebugParam(u);
|
|
13823
13825
|
} } })], 1)], 1)], 1)], 1);
|
|
13824
13826
|
}), r("el-form-item", [r("el-button", { attrs: { type: "primary", icon: "el-icon-plus", size: "small" }, on: { click: t.addDebugParam } }, [t._v(t._s(t.$t("debug.addParam")))]), r("el-button", { attrs: { type: "warning", icon: "el-icon-refresh", size: "small" }, on: { click: t.resetDebugForm } }, [t._v(t._s(t.$t("debug.reset")))]), r("el-button", { attrs: { type: "success", icon: "el-icon-check", size: "small", loading: t.debugSubmitting }, on: { click: t.submitDebugChatModel } }, [t._v(t._s(t.$t("debug.submit")))]), t.tokenCounterEnabled ? r("el-tooltip", { attrs: { content: t.$t("debug.calculateTokensTooltip"), placement: "top" } }, [r("el-button", { attrs: { type: "info", icon: "el-icon-cpu", size: "small", loading: t.tokenCalculating }, on: { click: t.calculatePromptTokens } }, [t._v(t._s(t.$t("debug.calculateTokens")))])], 1) : t._e()], 1)], 2), t.promptTokensResult !== null ? r("div", { staticClass: "token-result-section" }, [r("div", { staticClass: "token-result-header" }, [t._v(t._s(t.$t("debug.tokenResultTitle")))]), r("el-table", { attrs: { data: t.promptTokensTableData, size: "small", border: "" } }, [r("el-table-column", { attrs: { prop: "name", label: t.$t("debug.tokenType"), width: "140" } }), r("el-table-column", { attrs: { prop: "value", label: t.$t("debug.tokenCount") } })], 1)], 1) : t._e(), t.debugResponse !== null ? r("div", { staticClass: "debug-response" }, [r("OutputViewer", { attrs: { value: t.debugResponse, "show-raw-toggle": !0, "is-error-response": t.debugResponseIsError, "preview-markdown": t.responsePreview, "support-file-elements": !0, title: t.$t("debug.responseResult"), "content-key": `${t.selectedSpanId}-${t.debugResponseKey}` }, on: { copy: t.handleOutputCopy } })], 1) : t._e()], 1) : t._e()]);
|
|
13825
|
-
},
|
|
13826
|
-
xv,
|
|
13827
|
+
}, Sv = [], Cv = /* @__PURE__ */ dn(
|
|
13827
13828
|
wv,
|
|
13828
13829
|
kv,
|
|
13830
|
+
Sv,
|
|
13829
13831
|
!1,
|
|
13830
13832
|
null,
|
|
13831
13833
|
"131292bb"
|
|
13832
13834
|
);
|
|
13833
|
-
const
|
|
13835
|
+
const Tv = Cv.exports;
|
|
13834
13836
|
Se.setOptions({
|
|
13835
13837
|
breaks: !0
|
|
13836
13838
|
});
|
|
13837
|
-
const
|
|
13839
|
+
const _v = {
|
|
13838
13840
|
name: "TraceDetailDrawer",
|
|
13839
13841
|
components: {
|
|
13840
|
-
TraceSpanTree:
|
|
13841
|
-
DebugTab:
|
|
13842
|
+
TraceSpanTree: Rc,
|
|
13843
|
+
DebugTab: Tv,
|
|
13842
13844
|
codemirror: Us.codemirror,
|
|
13843
13845
|
FilePdfViewer: Zs,
|
|
13844
|
-
OutputViewer:
|
|
13846
|
+
OutputViewer: ef
|
|
13845
13847
|
},
|
|
13846
13848
|
props: {
|
|
13847
13849
|
visible: {
|
|
@@ -14445,7 +14447,7 @@ const Tv = {
|
|
|
14445
14447
|
return o ? o.startsWith("data:image") ? o : o.startsWith("/9j/") ? `data:image/jpeg;base64,${o}` : o.startsWith("iVBOR") ? `data:image/png;base64,${o}` : o.startsWith("R0lGOD") ? `data:image/gif;base64,${o}` : `data:image/jpeg;base64,${o}` : "";
|
|
14446
14448
|
},
|
|
14447
14449
|
handleImageClick(o) {
|
|
14448
|
-
|
|
14450
|
+
Zc({
|
|
14449
14451
|
options: this.viewerOptions,
|
|
14450
14452
|
images: [o]
|
|
14451
14453
|
});
|
|
@@ -14480,7 +14482,7 @@ const Tv = {
|
|
|
14480
14482
|
}
|
|
14481
14483
|
}
|
|
14482
14484
|
};
|
|
14483
|
-
var
|
|
14485
|
+
var Lv = function() {
|
|
14484
14486
|
var l, u, f, h, v, m, x, S, R, L, W, z;
|
|
14485
14487
|
var t = this, r = t._self._c;
|
|
14486
14488
|
return r("el-drawer", { attrs: { visible: t.localVisible, "with-header": !0, title: t.drawerTitle, size: "90%", direction: "rtl", "before-close": t.handleClose }, on: { "update:visible": function(O) {
|
|
@@ -14550,15 +14552,15 @@ var _v = function() {
|
|
|
14550
14552
|
return [r("el-tooltip", { attrs: { placement: "top", "open-delay": 500, "popper-class": "attribute-tooltip" } }, [r("div", { staticClass: "attribute-tooltip-content", attrs: { slot: "content" }, slot: "content" }, [t._v(t._s(A.row.value))]), r("div", { staticClass: "attribute-value" }, [t._v(t._s(A.row.value))])])];
|
|
14551
14553
|
} }], null, !0) })], 1)], 1)])], 2);
|
|
14552
14554
|
}), 1), t.spanEvents.length === 0 ? r("div", { staticClass: "empty-events" }, [r("el-empty", { attrs: { description: t.$t("trace.noEvents") } })], 1) : t._e()], 1) : t._e()]) : t._e()], 1)], 1) : r("el-empty", { attrs: { description: t.$t("trace.selectSpan") } })], 1)], 1)], 1)], 1) : t._e()]);
|
|
14553
|
-
},
|
|
14554
|
-
Tv,
|
|
14555
|
+
}, Ev = [], Av = /* @__PURE__ */ dn(
|
|
14555
14556
|
_v,
|
|
14556
14557
|
Lv,
|
|
14558
|
+
Ev,
|
|
14557
14559
|
!1,
|
|
14558
14560
|
null,
|
|
14559
14561
|
"3e9fab4f"
|
|
14560
14562
|
);
|
|
14561
|
-
const
|
|
14563
|
+
const Iv = Av.exports, Ov = {
|
|
14562
14564
|
name: "AdvancedQuery",
|
|
14563
14565
|
props: {
|
|
14564
14566
|
tagKeyOptions: {
|
|
@@ -14698,7 +14700,7 @@ const Av = Ev.exports, Iv = {
|
|
|
14698
14700
|
}
|
|
14699
14701
|
}
|
|
14700
14702
|
};
|
|
14701
|
-
var
|
|
14703
|
+
var Dv = function() {
|
|
14702
14704
|
var t = this, r = t._self._c;
|
|
14703
14705
|
return r("div", { staticClass: "advanced-query-container" }, [t._l(t.conditionGroups, function(l, u) {
|
|
14704
14706
|
return r("div", { key: u, staticClass: "condition-group" }, [r("div", { staticClass: "group-header" }, [u > 0 ? r("el-tag", { staticClass: "logic-tag", attrs: { size: "mini", type: "info" } }, [t._v(" " + t._s(l.logic === "OR" ? t.$t("advancedQuery.or") : t.$t("advancedQuery.and")) + " ")]) : t._e(), r("el-radio-group", { staticClass: "logic-switch", attrs: { size: "mini" }, model: { value: l.logic, callback: function(f) {
|
|
@@ -14743,19 +14745,19 @@ var Ov = function() {
|
|
|
14743
14745
|
return t.addNestedGroup(u);
|
|
14744
14746
|
} } }, [r("i", { staticClass: "el-icon-folder-add" }), t._v(" " + t._s(t.$t("advancedQuery.addConditionGroup")) + " ")])], 1)], 2)]);
|
|
14745
14747
|
}), r("div", { staticClass: "action-row" }, [r("el-button", { attrs: { type: "primary", size: "mini" }, on: { click: t.handleSearch } }, [t._v(" " + t._s(t.$t("advancedQuery.search")) + " ")]), r("el-button", { attrs: { size: "mini" }, on: { click: t.handleReset } }, [t._v(" " + t._s(t.$t("advancedQuery.reset")) + " ")])], 1)], 2);
|
|
14746
|
-
},
|
|
14747
|
-
Iv,
|
|
14748
|
+
}, Nv = [], Rv = /* @__PURE__ */ dn(
|
|
14748
14749
|
Ov,
|
|
14749
14750
|
Dv,
|
|
14751
|
+
Nv,
|
|
14750
14752
|
!1,
|
|
14751
14753
|
null,
|
|
14752
14754
|
"8520d641"
|
|
14753
14755
|
);
|
|
14754
|
-
const
|
|
14756
|
+
const Fv = Rv.exports, $v = {
|
|
14755
14757
|
name: "Trace",
|
|
14756
14758
|
components: {
|
|
14757
|
-
TraceDetailDrawer:
|
|
14758
|
-
AdvancedQuery:
|
|
14759
|
+
TraceDetailDrawer: Iv,
|
|
14760
|
+
AdvancedQuery: Fv
|
|
14759
14761
|
},
|
|
14760
14762
|
data() {
|
|
14761
14763
|
return {
|
|
@@ -14924,7 +14926,7 @@ const Rv = Nv.exports, Fv = {
|
|
|
14924
14926
|
},
|
|
14925
14927
|
viewDetail(o) {
|
|
14926
14928
|
const t = o == null ? void 0 : o.trace_id;
|
|
14927
|
-
t && (this.currentTraceId = t, this.traceInfo = { ...o }, (o == null ? void 0 : o.status) === "WARN" && (this.spanHasEvents = 1), this.drawerVisible = !0, this.loadTraceSpans(t));
|
|
14929
|
+
t && (this.currentTraceId = t, this.traceInfo = { ...o }, (o == null ? void 0 : o.status) === "WARN" && (this.spanHasEvents = 1, this.spanOnlyFailed = !0), this.drawerVisible = !0, this.loadTraceSpans(t));
|
|
14928
14930
|
},
|
|
14929
14931
|
async loadTraceSpans(o) {
|
|
14930
14932
|
var t, r, l;
|
|
@@ -15393,7 +15395,7 @@ const Rv = Nv.exports, Fv = {
|
|
|
15393
15395
|
}
|
|
15394
15396
|
}
|
|
15395
15397
|
};
|
|
15396
|
-
var
|
|
15398
|
+
var Mv = function() {
|
|
15397
15399
|
var t = this, r = t._self._c;
|
|
15398
15400
|
return r("div", { staticClass: "trace-list-container" }, [r("el-card", [r("div", { staticClass: "trace-content-wrapper" }, [r("div", { staticClass: "trace-toolbar" }, [r("el-select", { staticClass: "toolbar-select", attrs: { placeholder: t.$t("trace.selectApplication"), clearable: "", size: "mini" }, on: { change: t.handleExperimentChange }, model: { value: t.selectedExperimentId, callback: function(l) {
|
|
15399
15401
|
t.selectedExperimentId = l;
|
|
@@ -15476,26 +15478,26 @@ var $v = function() {
|
|
|
15476
15478
|
}, close: t.handleDrawerClose, "span-search": t.handleSpanSearch, "span-select": t.handleSpanSelect, "span-load-more": t.loadMoreSpans } }), r("el-dialog", { attrs: { title: t.$t("advancedQuery.title"), visible: t.showAdvancedQuery, width: "800px", "close-on-click-modal": !1 }, on: { "update:visible": function(l) {
|
|
15477
15479
|
t.showAdvancedQuery = l;
|
|
15478
15480
|
} } }, [r("AdvancedQuery", { ref: "advancedQuery", attrs: { "tag-key-options": t.tagKeyOptions }, on: { search: t.handleAdvancedSearch, reset: t.handleAdvancedQueryReset } })], 1)], 1);
|
|
15479
|
-
},
|
|
15480
|
-
Fv,
|
|
15481
|
+
}, Pv = [], zv = /* @__PURE__ */ dn(
|
|
15481
15482
|
$v,
|
|
15482
15483
|
Mv,
|
|
15484
|
+
Pv,
|
|
15483
15485
|
!1,
|
|
15484
15486
|
null,
|
|
15485
|
-
"
|
|
15487
|
+
"805b1c31"
|
|
15486
15488
|
);
|
|
15487
|
-
const
|
|
15489
|
+
const tf = zv.exports, Bv = {
|
|
15488
15490
|
routes: [
|
|
15489
15491
|
{
|
|
15490
15492
|
path: "/trace",
|
|
15491
15493
|
name: "trace",
|
|
15492
|
-
component:
|
|
15494
|
+
component: tf
|
|
15493
15495
|
}
|
|
15494
15496
|
],
|
|
15495
15497
|
beforeEach: (o, t, r) => {
|
|
15496
15498
|
r();
|
|
15497
15499
|
}
|
|
15498
|
-
},
|
|
15500
|
+
}, Hv = {
|
|
15499
15501
|
common: {
|
|
15500
15502
|
home: "首页",
|
|
15501
15503
|
todos: "待办事项",
|
|
@@ -15649,7 +15651,7 @@ const Yc = Pv.exports, zv = {
|
|
|
15649
15651
|
reset: "重置",
|
|
15650
15652
|
noValidConditions: "请至少添加一个有效的查询条件"
|
|
15651
15653
|
}
|
|
15652
|
-
},
|
|
15654
|
+
}, Wv = {
|
|
15653
15655
|
common: {
|
|
15654
15656
|
home: "Home",
|
|
15655
15657
|
todos: "Todos",
|
|
@@ -15804,37 +15806,37 @@ This operation cannot be undone. Are you sure you want to continue?`,
|
|
|
15804
15806
|
noValidConditions: "Please add at least one valid condition"
|
|
15805
15807
|
}
|
|
15806
15808
|
}, _i = {
|
|
15807
|
-
"zh-CN":
|
|
15808
|
-
"en-US":
|
|
15809
|
+
"zh-CN": Hv,
|
|
15810
|
+
"en-US": Wv
|
|
15809
15811
|
};
|
|
15810
15812
|
let $s = !1;
|
|
15811
|
-
const
|
|
15813
|
+
const cc = (o) => {
|
|
15812
15814
|
!o || $s || (o.mergeLocaleMessage ? (Object.keys(_i).forEach((t) => {
|
|
15813
15815
|
o.mergeLocaleMessage(t, _i[t]);
|
|
15814
15816
|
}), $s = !0) : o.messages && (Object.keys(_i).forEach((t) => {
|
|
15815
15817
|
o.messages[t] || (o.messages[t] = {}), Object.assign(o.messages[t], _i[t]);
|
|
15816
15818
|
}), $s = !0));
|
|
15817
|
-
},
|
|
15818
|
-
store:
|
|
15819
|
-
router:
|
|
15819
|
+
}, Kv = {
|
|
15820
|
+
store: ch,
|
|
15821
|
+
router: Bv,
|
|
15820
15822
|
components: {
|
|
15821
|
-
Trace:
|
|
15822
|
-
TraceSpanTree:
|
|
15823
|
+
Trace: tf,
|
|
15824
|
+
TraceSpanTree: Rc
|
|
15823
15825
|
},
|
|
15824
15826
|
api: xt,
|
|
15825
15827
|
locales: _i,
|
|
15826
15828
|
setI18n(o) {
|
|
15827
|
-
|
|
15829
|
+
cc(o);
|
|
15828
15830
|
},
|
|
15829
|
-
registerLocales:
|
|
15831
|
+
registerLocales: cc
|
|
15830
15832
|
};
|
|
15831
15833
|
export {
|
|
15832
|
-
|
|
15833
|
-
|
|
15834
|
-
|
|
15835
|
-
|
|
15834
|
+
tf as Trace,
|
|
15835
|
+
Rc as TraceSpanTree,
|
|
15836
|
+
Kv as default,
|
|
15837
|
+
Wv as enUS,
|
|
15836
15838
|
xt as traceApi,
|
|
15837
|
-
|
|
15838
|
-
|
|
15839
|
-
|
|
15839
|
+
Bv as traceRouter,
|
|
15840
|
+
ch as traceStore,
|
|
15841
|
+
Hv as zhCN
|
|
15840
15842
|
};
|