jaml-ui 0.31.0 → 0.32.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +193 -61
- package/assets/fonts/README.md +14 -0
- package/assets/fonts/m6x11.ttf +0 -0
- package/assets/fonts/m6x11plus.ttf +0 -0
- package/dist/.gitkeep +0 -0
- package/dist/assets/searchPoolWorker-Ck5flXVS.js +40 -0
- package/dist/assets/searchPoolWorker-Ck5flXVS.js.map +1 -0
- package/dist/assets.d.ts +1 -1
- package/dist/chunks/{assets-D80i9sMq.js → assets-Bb6wV80_.js} +3 -3
- package/dist/chunks/assets-Bb6wV80_.js.map +1 -0
- package/dist/chunks/jamlSeeds-3ILzc_rj.js +66 -0
- package/dist/chunks/jamlSeeds-3ILzc_rj.js.map +1 -0
- package/dist/chunks/motelyItemFormats-CNrFzcCI.js +1836 -0
- package/dist/chunks/motelyItemFormats-CNrFzcCI.js.map +1 -0
- package/dist/chunks/{searchPoolWorker-DUope_8B.js → searchPoolWorker-gPdRA_pa.js} +2 -2
- package/dist/chunks/searchPoolWorker-gPdRA_pa.js.map +1 -0
- package/dist/chunks/{spriteMapper-C4_5G1Z6.js → spriteMapper-CajFGgUU.js} +2 -2
- package/dist/chunks/spriteMapper-CajFGgUU.js.map +1 -0
- package/dist/chunks/tokens-Qrhlekc4.js.map +1 -1
- package/dist/chunks/{ui-DRov81qO.js → ui-CgjJDJdZ.js} +1346 -1195
- package/dist/chunks/ui-CgjJDJdZ.js.map +1 -0
- package/dist/components/CardFan.d.ts +0 -9
- package/dist/components/JamlAestheticSelector.d.ts +3 -3
- package/dist/components/JamlIde.d.ts +1 -4
- package/dist/components/JamlSeedSpinner.d.ts +3 -1
- package/dist/components/Jamlyzer.d.ts +5 -8
- package/dist/components/MotelyHello.d.ts +5 -0
- package/dist/components/SeedFinderApp.d.ts +7 -0
- package/dist/components/StandardCard.d.ts +14 -0
- package/dist/components/cardEnums.d.ts +48 -0
- package/dist/components/jamlMap/JokerPicker.d.ts +2 -1
- package/dist/components/jamlMap/MysterySlot.d.ts +2 -1
- package/dist/core.d.ts +1 -0
- package/dist/core.js +7 -7
- package/dist/core.js.map +1 -1
- package/dist/hooks/useAnalyzer.d.ts +1 -1
- package/dist/hooks/useSearchPool.d.ts +1 -1
- package/dist/index.d.ts +6 -4
- package/dist/index.js +3870 -3591
- package/dist/index.js.map +1 -1
- package/dist/lib/data/constants.d.ts +3 -3
- package/dist/lib/jaml/jamlData.d.ts +1 -0
- package/dist/lib/jaml/jamlSchema.d.ts +10 -60
- package/dist/lib/jaml/jamlSeeds.d.ts +7 -0
- package/dist/lib/types.d.ts +3 -2
- package/dist/motely.d.ts +1 -2
- package/dist/motely.js +125 -1999
- package/dist/motely.js.map +1 -1
- package/dist/r3f.js +1 -1
- package/dist/r3f.js.map +1 -1
- package/dist/ui/JimboBadge.d.ts +1 -1
- package/dist/ui/{footer.d.ts → JimboBalatroFooter.d.ts} +4 -2
- package/dist/ui/JimboCopyButton.d.ts +27 -0
- package/dist/ui/JimboDeckAndStakeSelectorModal.d.ts +30 -0
- package/dist/ui/JimboIconButton.d.ts +8 -3
- package/dist/ui/JimboInlineEdit.d.ts +16 -0
- package/dist/ui/JimboListItem.d.ts +11 -0
- package/dist/ui/JimboPanelSplitter.d.ts +8 -0
- package/dist/ui/JimboSeedCopyChip.d.ts +16 -0
- package/dist/ui/JimboSelect.d.ts +15 -3
- package/dist/ui/JimboSpinner.d.ts +18 -0
- package/dist/ui/JimboStepper.d.ts +19 -7
- package/dist/ui/JimboValueBadge.d.ts +19 -0
- package/dist/ui/codeBlock.d.ts +4 -0
- package/dist/ui/hooks.d.ts +30 -3
- package/dist/ui/jimbo.css +1 -1
- package/dist/ui/jimboApp.d.ts +2 -2
- package/dist/ui/jimboBackground.d.ts +12 -5
- package/dist/ui/jimboCopyRow.d.ts +2 -2
- package/dist/ui/jimboInset.d.ts +3 -3
- package/dist/ui/jimboLayout.d.ts +25 -0
- package/dist/ui/jimboLink.d.ts +12 -0
- package/dist/ui/jimboTabs.d.ts +6 -6
- package/dist/ui/jimboText.d.ts +2 -3
- package/dist/ui.d.ts +12 -4
- package/dist/ui.js +3 -3
- package/fonts.css +20 -5
- package/package.json +7 -6
- package/assets/fonts/m6x11plusplus.otf +0 -0
- package/dist/assets/searchPoolWorker-BPJ3Mf0o.js +0 -40
- package/dist/assets/searchPoolWorker-BPJ3Mf0o.js.map +0 -1
- package/dist/chunks/Layer-Ckd_T6Fw.js +0 -17
- package/dist/chunks/Layer-Ckd_T6Fw.js.map +0 -1
- package/dist/chunks/assets-D80i9sMq.js.map +0 -1
- package/dist/chunks/runtime-C-It0krH.js +0 -10
- package/dist/chunks/runtime-C-It0krH.js.map +0 -1
- package/dist/chunks/searchPoolWorker-DUope_8B.js.map +0 -1
- package/dist/chunks/spriteMapper-C4_5G1Z6.js.map +0 -1
- package/dist/chunks/ui-DRov81qO.js.map +0 -1
- package/dist/components/CardList.d.ts +0 -8
- package/dist/components/Standardcard.d.ts +0 -18
- package/dist/config.d.ts +0 -10
- package/dist/fonts/m6x11plus.otf +0 -0
- package/dist/hooks/useMotelyRuntime.d.ts +0 -11
- package/dist/providers/MotelyProvider.d.ts +0 -11
- package/dist/ui/JimboFloating.d.ts +0 -8
- package/dist/ui/PanelSplitter.d.ts +0 -8
- package/jaml.schema.json +0 -1219
|
@@ -1,17 +1,18 @@
|
|
|
1
1
|
import { n as e, t } from "./tokens-Qrhlekc4.js";
|
|
2
|
-
import { n } from "./assets-
|
|
3
|
-
import { n as r, p as i, r as a, t as o } from "./spriteMapper-
|
|
2
|
+
import { n } from "./assets-Bb6wV80_.js";
|
|
3
|
+
import { n as r, p as i, r as a, t as o } from "./spriteMapper-CajFGgUU.js";
|
|
4
4
|
import s, { createContext as c, createElement as l, forwardRef as u, memo as d, useCallback as f, useContext as p, useEffect as m, useLayoutEffect as h, useMemo as g, useRef as _, useState as v } from "react";
|
|
5
5
|
import { Fragment as y, jsx as b, jsxs as x } from "react/jsx-runtime";
|
|
6
|
-
import {
|
|
6
|
+
import { FiCheck as S, FiCopy as C } from "react-icons/fi";
|
|
7
|
+
import { createPortal as w } from "react-dom";
|
|
7
8
|
//#region src/ui/hooks.ts
|
|
8
|
-
function
|
|
9
|
+
function T(e) {
|
|
9
10
|
return new Promise((t) => {
|
|
10
11
|
let n = new window.Image();
|
|
11
12
|
n.addEventListener("load", () => t(n)), n.addEventListener("error", () => t(null)), n.src = e;
|
|
12
13
|
});
|
|
13
14
|
}
|
|
14
|
-
function
|
|
15
|
+
function E(e, t, n, r, i) {
|
|
15
16
|
if (!n || !r || !r?.pos) return 0;
|
|
16
17
|
let a = n.width / r.columns, o = n.height / r.rows, s = e.style;
|
|
17
18
|
if (r.order === 0 && (e.width = a, e.height = o, s.width = `${a}px`, s.height = `${o}px`), s.imageRendering = "pixelated", t.imageSmoothingEnabled = !0, t.save(), r.animated && i) {
|
|
@@ -20,7 +21,7 @@ function ee(e, t, n, r, i) {
|
|
|
20
21
|
}
|
|
21
22
|
return t.drawImage(n, r.pos.x * a, r.pos.y * o, a, o, 0, 0, e.width, e.height), t.restore(), a / o;
|
|
22
23
|
}
|
|
23
|
-
function
|
|
24
|
+
function D(e) {
|
|
24
25
|
let n = _(null);
|
|
25
26
|
return m(() => {
|
|
26
27
|
if (!e || !n.current) return;
|
|
@@ -33,27 +34,69 @@ function w(e) {
|
|
|
33
34
|
};
|
|
34
35
|
}, [e]), n;
|
|
35
36
|
}
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
37
|
+
var O = {
|
|
38
|
+
primary: [
|
|
39
|
+
1,
|
|
40
|
+
.2,
|
|
41
|
+
.2
|
|
42
|
+
],
|
|
43
|
+
secondary: [
|
|
44
|
+
0,
|
|
45
|
+
.5,
|
|
46
|
+
1
|
|
47
|
+
],
|
|
48
|
+
dark: [
|
|
49
|
+
.05,
|
|
50
|
+
.08,
|
|
51
|
+
.1
|
|
52
|
+
],
|
|
53
|
+
speed: 1,
|
|
54
|
+
spinRotation: -2,
|
|
55
|
+
spinAmount: .35,
|
|
56
|
+
pixelFilter: 740 * .33,
|
|
57
|
+
contrast: 4.5,
|
|
58
|
+
lighting: .5,
|
|
59
|
+
transitionMs: 800
|
|
60
|
+
};
|
|
61
|
+
function k(e, t) {
|
|
62
|
+
if (!e) return t;
|
|
63
|
+
if (Array.isArray(e)) return [
|
|
64
|
+
e[0],
|
|
65
|
+
e[1],
|
|
66
|
+
e[2]
|
|
67
|
+
];
|
|
68
|
+
let n = e.trim().replace(/^#/, "");
|
|
69
|
+
if (n.length === 3 && (n = n.split("").map((e) => e + e).join("")), n.length !== 6) return t;
|
|
70
|
+
let r = parseInt(n, 16);
|
|
71
|
+
return Number.isNaN(r) ? t : [
|
|
72
|
+
(r >> 16 & 255) / 255,
|
|
73
|
+
(r >> 8 & 255) / 255,
|
|
74
|
+
(r & 255) / 255
|
|
75
|
+
];
|
|
76
|
+
}
|
|
77
|
+
function A(e = {}) {
|
|
78
|
+
let t = _(null), n = _(e);
|
|
79
|
+
return h(() => {
|
|
80
|
+
n.current = e;
|
|
81
|
+
}), m(() => {
|
|
82
|
+
let e = t.current;
|
|
83
|
+
if (!e) return;
|
|
84
|
+
let r = e.getContext("webgl");
|
|
85
|
+
if (!r) return;
|
|
86
|
+
let i = (e, t) => {
|
|
87
|
+
let n = r.createShader(e);
|
|
88
|
+
return n ? (r.shaderSource(n, t), r.compileShader(n), r.getShaderParameter(n, r.COMPILE_STATUS) ? n : (console.error("[JimboBackground] shader compile error:", r.getShaderInfoLog(n)), r.deleteShader(n), null)) : null;
|
|
89
|
+
}, a = i(r.VERTEX_SHADER, "\n attribute vec2 position;\n void main() {\n gl_Position = vec4(position, 0.0, 1.0);\n }\n "), o = i(r.FRAGMENT_SHADER, "\n precision mediump float;\n\n uniform float u_time;\n uniform vec2 u_resolution;\n uniform vec3 u_color1;\n uniform vec3 u_color2;\n uniform vec3 u_color3;\n uniform float u_spinRotation;\n uniform float u_spinSpeed;\n uniform float u_spinAmount;\n uniform float u_pixelFilter;\n uniform float u_contrast;\n uniform float u_lighting;\n\n void main() {\n vec2 screenSize = u_resolution;\n float pixel_size = length(screenSize.xy) / max(1.0, u_pixelFilter);\n vec2 uv = (floor(gl_FragCoord.xy*(1.0/pixel_size))*pixel_size - 0.5*screenSize.xy)/length(screenSize.xy);\n float uv_len = length(uv);\n\n float speed = (u_spinRotation * 0.2) + 302.2;\n float new_pixel_angle = atan(uv.y, uv.x) + speed - 20.0*(u_spinAmount*uv_len + (1.0 - u_spinAmount));\n\n vec2 mid = (screenSize.xy/length(screenSize.xy))/2.0;\n uv = (vec2((uv_len * cos(new_pixel_angle) + mid.x), (uv_len * sin(new_pixel_angle) + mid.y)) - mid);\n\n uv *= 30.0;\n speed = u_time * u_spinSpeed;\n vec2 uv2 = vec2(uv.x, uv.y);\n\n for(int i=0; i < 5; i++) {\n uv2 += sin(max(uv.x, uv.y)) + uv;\n uv += 0.5*vec2(cos(5.1123314 + 0.353*uv2.y + speed*0.131121), sin(uv2.x - 0.113*speed));\n uv -= 1.0*cos(uv.x + uv.y) - 1.0*sin(uv.x*0.711 - uv.y);\n }\n\n float contrast_mod = (0.25*u_contrast + 0.5*u_spinAmount + 1.2);\n float paint_res = min(2.0, max(0.0, length(uv)*(0.035)*contrast_mod));\n float c1p = max(0.0, 1.0 - contrast_mod*abs(1.0 - paint_res));\n float c2p = max(0.0, 1.0 - contrast_mod*abs(paint_res));\n float c3p = 1.0 - min(1.0, c1p + c2p);\n float light = (u_lighting - 0.2)*max(c1p*5.0 - 4.0, 0.0) + u_lighting*max(c2p*5.0 - 4.0, 0.0);\n\n vec3 base = (0.3/u_contrast)*u_color1 + (1.0 - 0.3/u_contrast)*(u_color1*c1p + u_color2*c2p + c3p*u_color3) + vec3(light);\n gl_FragColor = vec4(base, 1.0);\n }\n ");
|
|
90
|
+
if (!a || !o) return;
|
|
91
|
+
let s = r.createProgram();
|
|
92
|
+
if (!s) return;
|
|
93
|
+
if (r.attachShader(s, a), r.attachShader(s, o), r.linkProgram(s), !r.getProgramParameter(s, r.LINK_STATUS)) {
|
|
94
|
+
console.error("[JimboBackground] program link error:", r.getProgramInfoLog(s));
|
|
52
95
|
return;
|
|
53
96
|
}
|
|
54
|
-
|
|
55
|
-
let
|
|
56
|
-
|
|
97
|
+
r.useProgram(s);
|
|
98
|
+
let c = r.createBuffer();
|
|
99
|
+
r.bindBuffer(r.ARRAY_BUFFER, c), r.bufferData(r.ARRAY_BUFFER, new Float32Array([
|
|
57
100
|
-1,
|
|
58
101
|
-1,
|
|
59
102
|
1,
|
|
@@ -66,21 +109,42 @@ function te() {
|
|
|
66
109
|
-1,
|
|
67
110
|
1,
|
|
68
111
|
1
|
|
69
|
-
]),
|
|
70
|
-
let
|
|
71
|
-
|
|
72
|
-
let
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
112
|
+
]), r.STATIC_DRAW);
|
|
113
|
+
let l = r.getAttribLocation(s, "position");
|
|
114
|
+
r.enableVertexAttribArray(l), r.vertexAttribPointer(l, 2, r.FLOAT, !1, 0, 0);
|
|
115
|
+
let u = r.getUniformLocation(s, "u_time"), d = r.getUniformLocation(s, "u_resolution"), f = r.getUniformLocation(s, "u_color1"), p = r.getUniformLocation(s, "u_color2"), m = r.getUniformLocation(s, "u_color3"), h = r.getUniformLocation(s, "u_spinRotation"), g = r.getUniformLocation(s, "u_spinSpeed"), _ = r.getUniformLocation(s, "u_spinAmount"), v = r.getUniformLocation(s, "u_pixelFilter"), y = r.getUniformLocation(s, "u_contrast"), b = r.getUniformLocation(s, "u_lighting"), x = (e) => ({
|
|
116
|
+
spinRotation: e.spinRotation ?? O.spinRotation,
|
|
117
|
+
spinSpeed: 4.5 * (e.speed ?? O.speed),
|
|
118
|
+
spinAmount: e.spinAmount ?? O.spinAmount,
|
|
119
|
+
pixelFilter: e.pixelFilter ?? O.pixelFilter,
|
|
120
|
+
contrast: e.contrast ?? O.contrast,
|
|
121
|
+
lighting: e.lighting ?? O.lighting
|
|
122
|
+
}), S = n.current, C = [
|
|
123
|
+
k(S.primary, O.primary),
|
|
124
|
+
k(S.secondary, O.secondary),
|
|
125
|
+
k(S.dark, O.dark)
|
|
126
|
+
], w = x(S), T = performance.now(), E = T, D = 0, A = () => {
|
|
127
|
+
let t = performance.now(), i = Math.max(0, t - E);
|
|
128
|
+
E = t;
|
|
129
|
+
let a = n.current, o = [
|
|
130
|
+
k(a.primary, O.primary),
|
|
131
|
+
k(a.secondary, O.secondary),
|
|
132
|
+
k(a.dark, O.dark)
|
|
133
|
+
], s = x(a), c = Math.max(1, a.transitionMs ?? O.transitionMs), l = 1 - Math.exp(-i / c);
|
|
134
|
+
for (let e = 0; e < 3; e++) for (let t = 0; t < 3; t++) C[e][t] += (o[e][t] - C[e][t]) * l;
|
|
135
|
+
let S = (e) => {
|
|
136
|
+
w[e] += (s[e] - w[e]) * l;
|
|
137
|
+
};
|
|
138
|
+
S("spinRotation"), S("spinSpeed"), S("spinAmount"), S("pixelFilter"), S("contrast"), S("lighting");
|
|
139
|
+
let j = e.clientWidth, M = e.clientHeight;
|
|
140
|
+
(e.width !== j || e.height !== M) && (e.width = j, e.height = M, r.viewport(0, 0, r.drawingBufferWidth, r.drawingBufferHeight)), r.uniform1f(u, (t - T) / 1e3), r.uniform2f(d, e.width, e.height), r.uniform3f(f, C[0][0], C[0][1], C[0][2]), r.uniform3f(p, C[1][0], C[1][1], C[1][2]), r.uniform3f(m, C[2][0], C[2][1], C[2][2]), r.uniform1f(h, w.spinRotation), r.uniform1f(g, w.spinSpeed), r.uniform1f(_, w.spinAmount), r.uniform1f(v, w.pixelFilter), r.uniform1f(y, w.contrast), r.uniform1f(b, w.lighting), r.drawArrays(r.TRIANGLES, 0, 6), D = requestAnimationFrame(A);
|
|
77
141
|
};
|
|
78
|
-
return
|
|
79
|
-
cancelAnimationFrame(
|
|
142
|
+
return D = requestAnimationFrame(A), () => {
|
|
143
|
+
cancelAnimationFrame(D), r.deleteProgram(s), r.deleteShader(a), r.deleteShader(o), r.deleteBuffer(c);
|
|
80
144
|
};
|
|
81
|
-
}, []),
|
|
145
|
+
}, []), t;
|
|
82
146
|
}
|
|
83
|
-
function
|
|
147
|
+
function j({ mode: e = "snap", placement: t = "auto", delay: n = 80, disabled: r = !1 }) {
|
|
84
148
|
let [i, a] = v(!1), [o, s] = v(null), c = _(null), l = _(null), u = _(null), d = f(() => {
|
|
85
149
|
r || (u.current && clearTimeout(u.current), u.current = setTimeout(() => a(!0), n));
|
|
86
150
|
}, [r, n]), p = f(() => {
|
|
@@ -123,7 +187,7 @@ function T({ mode: e = "snap", placement: t = "auto", delay: n = 80, disabled: r
|
|
|
123
187
|
}, [e])
|
|
124
188
|
};
|
|
125
189
|
}
|
|
126
|
-
function
|
|
190
|
+
function M({ layers: e, invert: t = !1, hoverTilt: n = !1 }) {
|
|
127
191
|
let r = _(null), a = _(null), o = _(/* @__PURE__ */ new Map()), [s, c] = v(3 / 4), [, l] = v(0), u = _(null), d = _({
|
|
128
192
|
rx: 0,
|
|
129
193
|
ry: 0,
|
|
@@ -136,7 +200,7 @@ function E({ layers: e, invert: t = !1, hoverTilt: n = !1 }) {
|
|
|
136
200
|
m(() => {
|
|
137
201
|
let e = !1, t = o.current;
|
|
138
202
|
return (async () => {
|
|
139
|
-
let n = Array.from(new Set(Object.values(i).map((e) => e.src))), r = await Promise.all(n.map((e) =>
|
|
203
|
+
let n = Array.from(new Set(Object.values(i).map((e) => e.src))), r = await Promise.all(n.map((e) => T(e)));
|
|
140
204
|
e || (r.forEach((e, r) => {
|
|
141
205
|
e && t.set(n[r], e);
|
|
142
206
|
}), l((e) => e + 1));
|
|
@@ -152,14 +216,14 @@ function E({ layers: e, invert: t = !1, hoverTilt: n = !1 }) {
|
|
|
152
216
|
i.clearRect(0, 0, n.width, n.height), [...e].sort((e, t) => e.order - t.order).forEach((e) => {
|
|
153
217
|
let t = o.current.get(e.source);
|
|
154
218
|
if (t) {
|
|
155
|
-
let a =
|
|
219
|
+
let a = E(n, i, t, e, h ? r : void 0);
|
|
156
220
|
e.order === 0 && c(a);
|
|
157
221
|
return;
|
|
158
222
|
}
|
|
159
|
-
|
|
223
|
+
T(e.source).then((t) => {
|
|
160
224
|
if (!(a || !t)) {
|
|
161
225
|
if (o.current.set(e.source, t), !h) {
|
|
162
|
-
let r =
|
|
226
|
+
let r = E(n, i, t, e);
|
|
163
227
|
e.order === 0 && c(r);
|
|
164
228
|
}
|
|
165
229
|
l((e) => e + 1);
|
|
@@ -232,7 +296,7 @@ function E({ layers: e, invert: t = !1, hoverTilt: n = !1 }) {
|
|
|
232
296
|
}
|
|
233
297
|
};
|
|
234
298
|
}
|
|
235
|
-
function
|
|
299
|
+
function ee(e, t, n) {
|
|
236
300
|
let [r, i] = v(null), [a, o] = v(null), [s, c] = v(null), l = f((e, t, n) => {
|
|
237
301
|
let r = "touches" in e ? e.touches[0] : e, i = e.currentTarget.getBoundingClientRect();
|
|
238
302
|
o({
|
|
@@ -301,7 +365,7 @@ function D(e, t, n) {
|
|
|
301
365
|
}
|
|
302
366
|
//#endregion
|
|
303
367
|
//#region src/ui/sprites.tsx
|
|
304
|
-
function
|
|
368
|
+
function te({ name: e, sheet: t, width: i = 40, height: s, style: c }) {
|
|
305
369
|
let l = a(e), u = t ?? l?.type ?? "Jokers", d = o[u], f = r(u), p = l?.pos ?? f.pos, m = i;
|
|
306
370
|
[
|
|
307
371
|
"Jokers",
|
|
@@ -327,7 +391,7 @@ function O({ name: e, sheet: t, width: i = 40, height: s, style: c }) {
|
|
|
327
391
|
...c
|
|
328
392
|
} });
|
|
329
393
|
}
|
|
330
|
-
var
|
|
394
|
+
var ne = [
|
|
331
395
|
"White",
|
|
332
396
|
"Red",
|
|
333
397
|
"Green",
|
|
@@ -337,8 +401,8 @@ var k = [
|
|
|
337
401
|
"Orange",
|
|
338
402
|
"Gold"
|
|
339
403
|
];
|
|
340
|
-
function
|
|
341
|
-
let a =
|
|
404
|
+
function re({ stake: e, width: t = 29, height: r, style: i }) {
|
|
405
|
+
let a = ne.indexOf(e.replace(" Stake", "")), o = a >= 0 ? a : 0, s = o % 5, c = Math.floor(o / 5), l = r ?? t, u = t * 5, d = l * 2;
|
|
342
406
|
return /* @__PURE__ */ b("div", { style: {
|
|
343
407
|
width: t,
|
|
344
408
|
height: l,
|
|
@@ -351,33 +415,49 @@ function A({ stake: e, width: t = 29, height: r, style: i }) {
|
|
|
351
415
|
...i
|
|
352
416
|
} });
|
|
353
417
|
}
|
|
354
|
-
var
|
|
355
|
-
Red:
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
418
|
+
var ie = {
|
|
419
|
+
Red: {
|
|
420
|
+
x: 0,
|
|
421
|
+
y: 0
|
|
422
|
+
},
|
|
423
|
+
Blue: {
|
|
424
|
+
x: 0,
|
|
425
|
+
y: 2
|
|
426
|
+
},
|
|
427
|
+
Yellow: {
|
|
428
|
+
x: 1,
|
|
429
|
+
y: 2
|
|
430
|
+
},
|
|
431
|
+
Green: {
|
|
432
|
+
x: 2,
|
|
433
|
+
y: 2
|
|
434
|
+
},
|
|
435
|
+
Black: {
|
|
436
|
+
x: 3,
|
|
437
|
+
y: 2
|
|
438
|
+
},
|
|
439
|
+
Magic: {
|
|
440
|
+
x: 4,
|
|
441
|
+
y: 2
|
|
442
|
+
}
|
|
363
443
|
};
|
|
364
|
-
function
|
|
365
|
-
let
|
|
444
|
+
function ae({ deck: e, width: t = 71, height: r, style: a }) {
|
|
445
|
+
let o = ie[e.replace(" Deck", "")] ?? ie.Red, s = r ?? t * 95 / 71, c = i.enhancers;
|
|
366
446
|
return /* @__PURE__ */ b("div", { style: {
|
|
367
447
|
width: t,
|
|
368
|
-
height:
|
|
448
|
+
height: s,
|
|
369
449
|
flexShrink: 0,
|
|
370
|
-
backgroundImage: `url(${n(
|
|
371
|
-
backgroundSize: `${
|
|
372
|
-
backgroundPosition:
|
|
450
|
+
backgroundImage: `url(${n(c.asset)})`,
|
|
451
|
+
backgroundSize: `${t * c.columns}px ${s * c.rows}px`,
|
|
452
|
+
backgroundPosition: `${-o.x * t}px ${-o.y * s}px`,
|
|
373
453
|
backgroundRepeat: "no-repeat",
|
|
374
454
|
imageRendering: "pixelated",
|
|
375
|
-
...
|
|
455
|
+
...a
|
|
376
456
|
} });
|
|
377
457
|
}
|
|
378
458
|
//#endregion
|
|
379
459
|
//#region src/ui/jimboText.tsx
|
|
380
|
-
function
|
|
460
|
+
function N({ tone: e = "default", size: t = "md", shadow: n = !0, dance: r = !1, letterSpacing: i, as: a = "span", className: o = "", style: s, children: c, ...l }) {
|
|
381
461
|
let u = `j-text--${t}`, d = `j-text--${e}`, f = n ? "" : "j-text--no-shadow", p = r ? "j-text--dance-container" : "", m = {};
|
|
382
462
|
i != null && (m.letterSpacing = i), s && Object.assign(m, s);
|
|
383
463
|
let h = c;
|
|
@@ -393,9 +473,17 @@ function j({ tone: e = "default", size: t = "md", shadow: n = !0, dance: r = !1,
|
|
|
393
473
|
});
|
|
394
474
|
}
|
|
395
475
|
//#endregion
|
|
396
|
-
//#region src/ui/
|
|
397
|
-
var
|
|
398
|
-
|
|
476
|
+
//#region src/ui/JimboTextInput.tsx
|
|
477
|
+
var oe = s.forwardRef(function({ className: e = "", invalid: t = !1, "aria-invalid": n, ...r }, i) {
|
|
478
|
+
return /* @__PURE__ */ b("input", {
|
|
479
|
+
ref: i,
|
|
480
|
+
className: `j-text-input ${e}`.trim(),
|
|
481
|
+
"aria-invalid": n ?? t,
|
|
482
|
+
"data-invalid": t,
|
|
483
|
+
...r
|
|
484
|
+
});
|
|
485
|
+
}), se = d(({ children: e, className: t = "", sway: n = !1, onBack: r, hideBack: i = !1, style: a, ...o }) => /* @__PURE__ */ x("div", {
|
|
486
|
+
ref: D(n),
|
|
399
487
|
className: `j-panel ${t}`,
|
|
400
488
|
style: a,
|
|
401
489
|
...o,
|
|
@@ -404,18 +492,18 @@ var M = d(({ children: e, className: t = "", sway: n = !1, onBack: r, hideBack:
|
|
|
404
492
|
children: e
|
|
405
493
|
}), r && !i && /* @__PURE__ */ b("div", {
|
|
406
494
|
className: "j-panel__back",
|
|
407
|
-
children: /* @__PURE__ */ b(
|
|
495
|
+
children: /* @__PURE__ */ b(le, { onClick: r })
|
|
408
496
|
})]
|
|
409
497
|
}));
|
|
410
|
-
|
|
411
|
-
var
|
|
498
|
+
se.displayName = "JimboPanel";
|
|
499
|
+
var ce = d(({ children: e, className: t = "", style: n, ...r }) => /* @__PURE__ */ b("div", {
|
|
412
500
|
className: `j-inner-panel ${t}`,
|
|
413
501
|
style: n,
|
|
414
502
|
...r,
|
|
415
503
|
children: e
|
|
416
504
|
}));
|
|
417
|
-
|
|
418
|
-
function
|
|
505
|
+
ce.displayName = "JimboInnerPanel";
|
|
506
|
+
function P({ tone: e = "orange", size: t = "md", fullWidth: n = !1, disabled: r = !1, onClick: i, style: a, className: o = "", children: s, ...c }) {
|
|
419
507
|
let l = t === "xs" ? "xs" : t === "sm" ? "sm" : t === "lg" ? "lg" : "md";
|
|
420
508
|
return /* @__PURE__ */ b("button", {
|
|
421
509
|
type: "button",
|
|
@@ -426,17 +514,17 @@ function N({ tone: e = "orange", size: t = "md", fullWidth: n = !1, disabled: r
|
|
|
426
514
|
...c,
|
|
427
515
|
children: /* @__PURE__ */ b("div", {
|
|
428
516
|
className: "j-btn__face",
|
|
429
|
-
children: /* @__PURE__ */ b(
|
|
517
|
+
children: /* @__PURE__ */ b(N, {
|
|
430
518
|
size: l,
|
|
431
519
|
children: s
|
|
432
520
|
})
|
|
433
521
|
})
|
|
434
522
|
});
|
|
435
523
|
}
|
|
436
|
-
function
|
|
524
|
+
function le({ onClick: e, size: t = "sm" }) {
|
|
437
525
|
return /* @__PURE__ */ b("div", {
|
|
438
526
|
className: "j-back-btn-wrap j-flex j-justify-center j-w-full",
|
|
439
|
-
children: /* @__PURE__ */ b(
|
|
527
|
+
children: /* @__PURE__ */ b(P, {
|
|
440
528
|
tone: "orange",
|
|
441
529
|
size: t,
|
|
442
530
|
fullWidth: !0,
|
|
@@ -446,16 +534,16 @@ function ae({ onClick: e, size: t = "md" }) {
|
|
|
446
534
|
})
|
|
447
535
|
});
|
|
448
536
|
}
|
|
449
|
-
function
|
|
537
|
+
function ue({ children: e, open: t, onClose: n, title: r, className: i, showBack: a = !0 }) {
|
|
450
538
|
return t ? /* @__PURE__ */ b("div", {
|
|
451
539
|
className: "j-modal-overlay",
|
|
452
|
-
children: /* @__PURE__ */ x(
|
|
540
|
+
children: /* @__PURE__ */ x(se, {
|
|
453
541
|
onBack: a ? n : void 0,
|
|
454
542
|
className: `j-modal ${i ?? ""}`,
|
|
455
543
|
children: [r && /* @__PURE__ */ b("div", {
|
|
456
544
|
className: "j-modal__title-wrap",
|
|
457
545
|
"aria-hidden": !1,
|
|
458
|
-
children: /* @__PURE__ */ b(
|
|
546
|
+
children: /* @__PURE__ */ b(N, {
|
|
459
547
|
as: "h2",
|
|
460
548
|
size: "lg",
|
|
461
549
|
className: "j-modal__title",
|
|
@@ -467,67 +555,105 @@ function oe({ children: e, open: t, onClose: n, title: r, className: i, showBack
|
|
|
467
555
|
}
|
|
468
556
|
//#endregion
|
|
469
557
|
//#region src/ui/jimboTabs.tsx
|
|
470
|
-
function
|
|
558
|
+
function de({ tabs: e, activeTab: t, onTabChange: n, className: r = "", style: i }) {
|
|
471
559
|
return /* @__PURE__ */ b("div", {
|
|
472
560
|
className: `j-tabs ${r}`,
|
|
473
561
|
style: i,
|
|
474
|
-
children: e.map((e) => /* @__PURE__ */ b(ce, {
|
|
475
|
-
label: e.label,
|
|
476
|
-
active: t === e.id,
|
|
477
|
-
onClick: () => n(e.id)
|
|
478
|
-
}, e.id))
|
|
479
|
-
});
|
|
480
|
-
}
|
|
481
|
-
function ce({ label: e, active: t, onClick: n }) {
|
|
482
|
-
return /* @__PURE__ */ x("div", {
|
|
483
|
-
className: "j-tab",
|
|
484
|
-
"data-active": t,
|
|
485
|
-
children: [/* @__PURE__ */ b("div", {
|
|
486
|
-
className: "j-tab__indicator",
|
|
487
|
-
"data-active": t,
|
|
488
|
-
"aria-hidden": !0,
|
|
489
|
-
children: /* @__PURE__ */ b("svg", {
|
|
490
|
-
width: 14,
|
|
491
|
-
height: 10,
|
|
492
|
-
viewBox: "0 0 14 10",
|
|
493
|
-
children: /* @__PURE__ */ b("polygon", { points: "7,10 0,0 14,0" })
|
|
494
|
-
})
|
|
495
|
-
}), /* @__PURE__ */ b("button", {
|
|
496
|
-
type: "button",
|
|
497
|
-
className: "j-tab__btn",
|
|
498
|
-
"data-active": t,
|
|
499
|
-
onClick: n,
|
|
500
|
-
children: /* @__PURE__ */ b(j, {
|
|
501
|
-
size: "sm",
|
|
502
|
-
tone: "default",
|
|
503
|
-
children: e
|
|
504
|
-
})
|
|
505
|
-
})]
|
|
506
|
-
});
|
|
507
|
-
}
|
|
508
|
-
function le({ tabs: e, activeTab: t, onTabChange: n, className: r = "", style: i }) {
|
|
509
|
-
return /* @__PURE__ */ b("div", {
|
|
510
|
-
className: `j-vtabs ${r}`,
|
|
511
|
-
style: i,
|
|
512
562
|
children: e.map((e) => {
|
|
513
563
|
let r = t === e.id;
|
|
514
|
-
return /* @__PURE__ */
|
|
515
|
-
|
|
516
|
-
className: "j-vtab",
|
|
564
|
+
return /* @__PURE__ */ x("div", {
|
|
565
|
+
className: "j-tab",
|
|
517
566
|
"data-active": r,
|
|
518
|
-
|
|
519
|
-
|
|
567
|
+
children: [/* @__PURE__ */ b("div", {
|
|
568
|
+
className: "j-tab__indicator",
|
|
569
|
+
"data-active": r,
|
|
570
|
+
"aria-hidden": !0,
|
|
571
|
+
children: /* @__PURE__ */ b("svg", {
|
|
572
|
+
width: 14,
|
|
573
|
+
height: 10,
|
|
574
|
+
viewBox: "0 0 14 10",
|
|
575
|
+
children: /* @__PURE__ */ b("polygon", { points: "7,10 0,0 14,0" })
|
|
576
|
+
})
|
|
577
|
+
}), /* @__PURE__ */ b(P, {
|
|
578
|
+
tone: "red",
|
|
520
579
|
size: "sm",
|
|
521
|
-
|
|
580
|
+
onClick: () => n(e.id),
|
|
522
581
|
children: e.label
|
|
523
|
-
})
|
|
582
|
+
})]
|
|
524
583
|
}, e.id);
|
|
525
584
|
})
|
|
526
585
|
});
|
|
527
586
|
}
|
|
528
587
|
//#endregion
|
|
588
|
+
//#region src/ui/JimboIconButton.tsx
|
|
589
|
+
var F = e, fe = {
|
|
590
|
+
xs: 22,
|
|
591
|
+
sm: 26,
|
|
592
|
+
md: 30
|
|
593
|
+
}, pe = {
|
|
594
|
+
default: {
|
|
595
|
+
rest: F.DARKEST,
|
|
596
|
+
hover: F.DARK_GREY,
|
|
597
|
+
border: F.PANEL_EDGE
|
|
598
|
+
},
|
|
599
|
+
destructive: {
|
|
600
|
+
rest: F.RED,
|
|
601
|
+
hover: F.ORANGE,
|
|
602
|
+
border: F.BLACK
|
|
603
|
+
}
|
|
604
|
+
};
|
|
605
|
+
function me({ onClick: e, onMouseDown: t, onTouchStart: n, title: r, "aria-label": i, disabled: a = !1, size: o = "md", tone: s = "default", children: c }) {
|
|
606
|
+
let [l, u] = v(!1), d = fe[o], f = pe[s], p = s === "destructive" ? 2 : 1, m = s === "destructive" ? `inset 0 1px 0 rgba(255,255,255,.2), 0 2px 0 ${F.BLACK}` : void 0;
|
|
607
|
+
return /* @__PURE__ */ b("button", {
|
|
608
|
+
"aria-label": i ?? r,
|
|
609
|
+
disabled: a,
|
|
610
|
+
onClick: (t) => !a && e?.(t),
|
|
611
|
+
onMouseDown: t,
|
|
612
|
+
onTouchStart: n,
|
|
613
|
+
onMouseEnter: () => u(!0),
|
|
614
|
+
onMouseLeave: () => u(!1),
|
|
615
|
+
style: {
|
|
616
|
+
width: d,
|
|
617
|
+
height: d,
|
|
618
|
+
display: "inline-flex",
|
|
619
|
+
alignItems: "center",
|
|
620
|
+
justifyContent: "center",
|
|
621
|
+
background: l && !a ? f.hover : f.rest,
|
|
622
|
+
color: F.WHITE,
|
|
623
|
+
border: `${p}px solid ${f.border}`,
|
|
624
|
+
borderRadius: 4,
|
|
625
|
+
boxShadow: m,
|
|
626
|
+
cursor: a ? "not-allowed" : "pointer",
|
|
627
|
+
opacity: a ? .55 : 1,
|
|
628
|
+
padding: 0,
|
|
629
|
+
fontSize: 14,
|
|
630
|
+
lineHeight: 1,
|
|
631
|
+
transition: "background 80ms ease"
|
|
632
|
+
},
|
|
633
|
+
title: r,
|
|
634
|
+
type: "button",
|
|
635
|
+
children: c
|
|
636
|
+
});
|
|
637
|
+
}
|
|
638
|
+
//#endregion
|
|
639
|
+
//#region src/ui/JimboInlineEdit.tsx
|
|
640
|
+
var he = s.forwardRef(function({ size: e = "md", tone: t = "white", dim: n = !1, className: r = "", ...i }, a) {
|
|
641
|
+
return /* @__PURE__ */ b("input", {
|
|
642
|
+
ref: a,
|
|
643
|
+
type: "text",
|
|
644
|
+
className: [
|
|
645
|
+
"j-inline-edit",
|
|
646
|
+
`j-inline-edit--${e}`,
|
|
647
|
+
`j-inline-edit--${t}`,
|
|
648
|
+
n ? "j-inline-edit--dim" : null,
|
|
649
|
+
r || null
|
|
650
|
+
].filter(Boolean).join(" "),
|
|
651
|
+
...i
|
|
652
|
+
});
|
|
653
|
+
});
|
|
654
|
+
//#endregion
|
|
529
655
|
//#region src/ui/JimboBadge.tsx
|
|
530
|
-
function
|
|
656
|
+
function ge({ size: e = "sm", tone: t = "dark", className: n, children: r, ...i }) {
|
|
531
657
|
return /* @__PURE__ */ b("span", {
|
|
532
658
|
className: `j-badge j-badge--${e} j-badge--${t} ${n ?? ""}`,
|
|
533
659
|
...i,
|
|
@@ -536,12 +662,12 @@ function ue({ size: e = "sm", tone: t = "dark", className: n, children: r, ...i
|
|
|
536
662
|
}
|
|
537
663
|
//#endregion
|
|
538
664
|
//#region src/ui/jimboFlankNav.tsx
|
|
539
|
-
function
|
|
665
|
+
function _e({ onPrev: e, onNext: t, canPrev: n = !0, canNext: r = !0, prevLabel: i = "Previous", nextLabel: a = "Next", children: o, className: s = "", style: c }) {
|
|
540
666
|
return /* @__PURE__ */ x("div", {
|
|
541
667
|
className: `j-flank ${s}`,
|
|
542
668
|
style: c,
|
|
543
669
|
children: [
|
|
544
|
-
/* @__PURE__ */ b(
|
|
670
|
+
/* @__PURE__ */ b(ve, {
|
|
545
671
|
direction: "left",
|
|
546
672
|
onClick: e,
|
|
547
673
|
disabled: !n,
|
|
@@ -551,7 +677,7 @@ function de({ onPrev: e, onNext: t, canPrev: n = !0, canNext: r = !0, prevLabel:
|
|
|
551
677
|
className: "j-flank__content",
|
|
552
678
|
children: o
|
|
553
679
|
}),
|
|
554
|
-
/* @__PURE__ */ b(
|
|
680
|
+
/* @__PURE__ */ b(ve, {
|
|
555
681
|
direction: "right",
|
|
556
682
|
onClick: t,
|
|
557
683
|
disabled: !r,
|
|
@@ -560,7 +686,7 @@ function de({ onPrev: e, onNext: t, canPrev: n = !0, canNext: r = !0, prevLabel:
|
|
|
560
686
|
]
|
|
561
687
|
});
|
|
562
688
|
}
|
|
563
|
-
function
|
|
689
|
+
function ve({ direction: e, onClick: t, disabled: n, "aria-label": r }) {
|
|
564
690
|
let [i, a] = s.useState(!1);
|
|
565
691
|
return /* @__PURE__ */ b("button", {
|
|
566
692
|
type: "button",
|
|
@@ -575,10 +701,10 @@ function fe({ direction: e, onClick: t, disabled: n, "aria-label": r }) {
|
|
|
575
701
|
onMouseLeave: () => a(!1),
|
|
576
702
|
onTouchStart: () => !n && a(!0),
|
|
577
703
|
onTouchEnd: () => a(!1),
|
|
578
|
-
children: /* @__PURE__ */ b(
|
|
704
|
+
children: /* @__PURE__ */ b(ye, { direction: e })
|
|
579
705
|
});
|
|
580
706
|
}
|
|
581
|
-
function
|
|
707
|
+
function ye({ direction: e }) {
|
|
582
708
|
return /* @__PURE__ */ b("svg", {
|
|
583
709
|
width: 28,
|
|
584
710
|
height: 28,
|
|
@@ -593,21 +719,104 @@ function pe({ direction: e }) {
|
|
|
593
719
|
});
|
|
594
720
|
}
|
|
595
721
|
//#endregion
|
|
596
|
-
//#region src/ui/
|
|
597
|
-
function
|
|
598
|
-
let
|
|
599
|
-
|
|
600
|
-
|
|
601
|
-
|
|
602
|
-
|
|
603
|
-
|
|
604
|
-
|
|
722
|
+
//#region src/ui/JimboSeedCopyChip.tsx
|
|
723
|
+
function be({ value: e, placeholder: t = "--------", disabled: n = !1, copiedLabel: r = "Copied!", copiedDurationMs: i = 2e3, onCopy: a, className: o = "", style: s }) {
|
|
724
|
+
let [c, l] = v(!1), u = e.trim(), d = !n && u.length > 0;
|
|
725
|
+
return /* @__PURE__ */ x("button", {
|
|
726
|
+
type: "button",
|
|
727
|
+
className: ["j-seed-copy", o].filter(Boolean).join(" "),
|
|
728
|
+
style: s,
|
|
729
|
+
onClick: async () => {
|
|
730
|
+
if (d) {
|
|
731
|
+
try {
|
|
732
|
+
typeof navigator < "u" && navigator.clipboard?.writeText && await navigator.clipboard.writeText(u);
|
|
733
|
+
} catch {}
|
|
734
|
+
l(!0), a?.(u), window.setTimeout(() => l(!1), i);
|
|
735
|
+
}
|
|
736
|
+
},
|
|
737
|
+
disabled: !d,
|
|
738
|
+
"data-copied": c,
|
|
739
|
+
"aria-label": d ? `Copy seed ${u}` : "Seed unavailable",
|
|
740
|
+
children: [/* @__PURE__ */ b("span", {
|
|
741
|
+
className: "j-seed-copy__icon",
|
|
742
|
+
"aria-hidden": !0,
|
|
743
|
+
children: b(c ? S : C, { size: 18 })
|
|
744
|
+
}), /* @__PURE__ */ b("span", {
|
|
745
|
+
className: "j-seed-copy__text",
|
|
746
|
+
children: c ? r : u || t
|
|
747
|
+
})]
|
|
748
|
+
});
|
|
749
|
+
}
|
|
750
|
+
//#endregion
|
|
751
|
+
//#region src/ui/JimboSpinner.tsx
|
|
752
|
+
function xe({ value: e, label: t, onPrev: n, onNext: r, canPrev: i = !0, canNext: a = !0, className: o = "" }) {
|
|
753
|
+
return /* @__PURE__ */ x("div", {
|
|
754
|
+
className: `j-spinner-wrap ${o}`,
|
|
755
|
+
children: [t && /* @__PURE__ */ b("div", {
|
|
756
|
+
className: "j-spinner__label",
|
|
757
|
+
children: /* @__PURE__ */ b(N, {
|
|
758
|
+
size: "sm",
|
|
759
|
+
tone: "white",
|
|
760
|
+
children: t
|
|
761
|
+
})
|
|
762
|
+
}), /* @__PURE__ */ x("div", {
|
|
763
|
+
className: "j-spinner",
|
|
764
|
+
children: [
|
|
765
|
+
/* @__PURE__ */ b(P, {
|
|
766
|
+
tone: "red",
|
|
767
|
+
size: "sm",
|
|
768
|
+
onClick: n,
|
|
769
|
+
disabled: !i,
|
|
770
|
+
"aria-label": `Previous ${t ?? "value"}`,
|
|
771
|
+
children: "<"
|
|
772
|
+
}),
|
|
773
|
+
/* @__PURE__ */ b("div", {
|
|
774
|
+
className: "j-spinner__value",
|
|
775
|
+
children: /* @__PURE__ */ b(N, {
|
|
776
|
+
size: "sm",
|
|
777
|
+
tone: "white",
|
|
778
|
+
children: e
|
|
779
|
+
})
|
|
780
|
+
}),
|
|
781
|
+
/* @__PURE__ */ b(P, {
|
|
782
|
+
tone: "red",
|
|
783
|
+
size: "sm",
|
|
784
|
+
onClick: r,
|
|
785
|
+
disabled: !a,
|
|
786
|
+
"aria-label": `Next ${t ?? "value"}`,
|
|
787
|
+
children: ">"
|
|
788
|
+
})
|
|
789
|
+
]
|
|
790
|
+
})]
|
|
791
|
+
});
|
|
792
|
+
}
|
|
793
|
+
//#endregion
|
|
794
|
+
//#region src/ui/jimboApp.tsx
|
|
795
|
+
function Se({ children: e, fluid: t, className: n = "", ...r }) {
|
|
796
|
+
return /* @__PURE__ */ b("div", {
|
|
797
|
+
className: `j-app${t ? " j-app--fluid" : ""} ${n}`.trim(),
|
|
798
|
+
...r,
|
|
799
|
+
children: e
|
|
800
|
+
});
|
|
801
|
+
}
|
|
802
|
+
function Ce({ children: e, className: t = "", ...n }) {
|
|
803
|
+
return /* @__PURE__ */ b("div", {
|
|
804
|
+
className: `j-app__scroll ${t}`,
|
|
805
|
+
...n,
|
|
806
|
+
children: e
|
|
807
|
+
});
|
|
808
|
+
}
|
|
809
|
+
function we({ children: e, className: t = "", ...n }) {
|
|
810
|
+
return /* @__PURE__ */ b("div", {
|
|
811
|
+
className: `j-app__footer ${t}`,
|
|
812
|
+
...n,
|
|
813
|
+
children: e
|
|
605
814
|
});
|
|
606
815
|
}
|
|
607
816
|
//#endregion
|
|
608
817
|
//#region src/ui/JimboToggleList.tsx
|
|
609
|
-
function
|
|
610
|
-
return /* @__PURE__ */ b(
|
|
818
|
+
function Te({ items: e, onToggle: t, title: n, variant: r = "row" }) {
|
|
819
|
+
return /* @__PURE__ */ b(se, { children: /* @__PURE__ */ x("div", {
|
|
611
820
|
className: `j-toggle-list j-toggle-list--${r}`,
|
|
612
821
|
children: [n && /* @__PURE__ */ b("div", {
|
|
613
822
|
className: "j-toggle-list__title",
|
|
@@ -630,7 +839,7 @@ function he({ items: e, onToggle: t, title: n, variant: r = "row" }) {
|
|
|
630
839
|
}
|
|
631
840
|
//#endregion
|
|
632
841
|
//#region src/ui/jimboFilterBar.tsx
|
|
633
|
-
function
|
|
842
|
+
function Ee({ search: e, onSearchChange: t, searchPlaceholder: n = "Search...", searchLabel: r = "Search", sort: i, onSortChange: a, sortLabel: o = "Sort By", sortOptions: s, className: c = "", style: l }) {
|
|
634
843
|
return /* @__PURE__ */ x("div", {
|
|
635
844
|
className: `j-filter-bar ${c}`,
|
|
636
845
|
style: l,
|
|
@@ -638,7 +847,7 @@ function ge({ search: e, onSearchChange: t, searchPlaceholder: n = "Search...",
|
|
|
638
847
|
className: "j-filter-bar__field",
|
|
639
848
|
children: [/* @__PURE__ */ b("div", {
|
|
640
849
|
className: "j-filter-bar__pill",
|
|
641
|
-
children: /* @__PURE__ */ b(
|
|
850
|
+
children: /* @__PURE__ */ b(N, {
|
|
642
851
|
size: "xs",
|
|
643
852
|
children: r
|
|
644
853
|
})
|
|
@@ -646,7 +855,7 @@ function ge({ search: e, onSearchChange: t, searchPlaceholder: n = "Search...",
|
|
|
646
855
|
className: "j-relative",
|
|
647
856
|
children: [/* @__PURE__ */ b("div", {
|
|
648
857
|
className: "j-filter-bar__search-icon",
|
|
649
|
-
children: /* @__PURE__ */ b(
|
|
858
|
+
children: /* @__PURE__ */ b(De, {})
|
|
650
859
|
}), /* @__PURE__ */ b("input", {
|
|
651
860
|
type: "text",
|
|
652
861
|
value: e ?? "",
|
|
@@ -659,7 +868,7 @@ function ge({ search: e, onSearchChange: t, searchPlaceholder: n = "Search...",
|
|
|
659
868
|
className: "j-filter-bar__field",
|
|
660
869
|
children: [/* @__PURE__ */ b("div", {
|
|
661
870
|
className: "j-filter-bar__pill",
|
|
662
|
-
children: /* @__PURE__ */ b(
|
|
871
|
+
children: /* @__PURE__ */ b(N, {
|
|
663
872
|
size: "xs",
|
|
664
873
|
children: o
|
|
665
874
|
})
|
|
@@ -675,13 +884,13 @@ function ge({ search: e, onSearchChange: t, searchPlaceholder: n = "Search...",
|
|
|
675
884
|
}, e.value))
|
|
676
885
|
}), /* @__PURE__ */ b("div", {
|
|
677
886
|
className: "j-filter-bar__sort-icon",
|
|
678
|
-
children: /* @__PURE__ */ b(
|
|
887
|
+
children: /* @__PURE__ */ b(Oe, {})
|
|
679
888
|
})]
|
|
680
889
|
})]
|
|
681
890
|
}) : null]
|
|
682
891
|
});
|
|
683
892
|
}
|
|
684
|
-
function
|
|
893
|
+
function De() {
|
|
685
894
|
return /* @__PURE__ */ x("svg", {
|
|
686
895
|
width: 24,
|
|
687
896
|
height: 24,
|
|
@@ -704,7 +913,7 @@ function _e() {
|
|
|
704
913
|
})]
|
|
705
914
|
});
|
|
706
915
|
}
|
|
707
|
-
function
|
|
916
|
+
function Oe() {
|
|
708
917
|
return /* @__PURE__ */ x("svg", {
|
|
709
918
|
width: 20,
|
|
710
919
|
height: 20,
|
|
@@ -724,8 +933,22 @@ function ve() {
|
|
|
724
933
|
});
|
|
725
934
|
}
|
|
726
935
|
//#endregion
|
|
727
|
-
//#region src/ui/
|
|
728
|
-
function
|
|
936
|
+
//#region src/ui/jimboLink.tsx
|
|
937
|
+
function ke({ external: e = !0, className: t = "", children: n, ...r }) {
|
|
938
|
+
let i = e ? {
|
|
939
|
+
target: "_blank",
|
|
940
|
+
rel: "noopener noreferrer"
|
|
941
|
+
} : {};
|
|
942
|
+
return /* @__PURE__ */ b("a", {
|
|
943
|
+
className: `j-link ${t}`.trim(),
|
|
944
|
+
...i,
|
|
945
|
+
...r,
|
|
946
|
+
children: n
|
|
947
|
+
});
|
|
948
|
+
}
|
|
949
|
+
//#endregion
|
|
950
|
+
//#region src/ui/JimboBalatroFooter.tsx
|
|
951
|
+
function Ae({ hidden: e = !1, className: t = "", children: n }) {
|
|
729
952
|
return e ? null : /* @__PURE__ */ b("div", {
|
|
730
953
|
className: ["j-footer", t].filter(Boolean).join(" "),
|
|
731
954
|
children: /* @__PURE__ */ b("div", {
|
|
@@ -741,11 +964,8 @@ function ye({ hidden: e = !1, className: t = "", children: n }) {
|
|
|
741
964
|
className: "j-footer__chunk j-footer__chunk--credit",
|
|
742
965
|
children: [
|
|
743
966
|
"Made for the ",
|
|
744
|
-
/* @__PURE__ */ b(
|
|
745
|
-
className: "j-footer__link",
|
|
967
|
+
/* @__PURE__ */ b(ke, {
|
|
746
968
|
href: "https://playbalatro.com",
|
|
747
|
-
target: "_blank",
|
|
748
|
-
rel: "noopener noreferrer",
|
|
749
969
|
children: "Balatro"
|
|
750
970
|
}),
|
|
751
971
|
" community"
|
|
@@ -762,9 +982,9 @@ function ye({ hidden: e = !1, className: t = "", children: n }) {
|
|
|
762
982
|
}
|
|
763
983
|
//#endregion
|
|
764
984
|
//#region src/ui/jimboBackground.tsx
|
|
765
|
-
function
|
|
985
|
+
function je({ hideFooter: e = !1, ...t }) {
|
|
766
986
|
return /* @__PURE__ */ x(y, { children: [/* @__PURE__ */ b("canvas", {
|
|
767
|
-
ref:
|
|
987
|
+
ref: A(t),
|
|
768
988
|
"aria-hidden": !0,
|
|
769
989
|
style: {
|
|
770
990
|
position: "fixed",
|
|
@@ -774,21 +994,21 @@ function be() {
|
|
|
774
994
|
zIndex: -10,
|
|
775
995
|
pointerEvents: "none"
|
|
776
996
|
}
|
|
777
|
-
}), /* @__PURE__ */ b(
|
|
997
|
+
}), !e && /* @__PURE__ */ b(Ae, {})] });
|
|
778
998
|
}
|
|
779
999
|
//#endregion
|
|
780
1000
|
//#region src/ui/jimboTooltip.tsx
|
|
781
|
-
function
|
|
1001
|
+
function Me(e, t) {
|
|
782
1002
|
typeof e == "function" ? e(t) : e && typeof e == "object" && (e.current = t);
|
|
783
1003
|
}
|
|
784
|
-
function
|
|
785
|
-
let { visible: u, pos: d, targetRef: p, tooltipRef: m, show: h, hide: g, handleMouseMove: _ } =
|
|
1004
|
+
function Ne({ content: e, badge: t, variant: n = "dark", children: r, mode: i = "snap", placement: a = "auto", delay: o = 80, maxWidth: c = 280, disabled: l = !1 }) {
|
|
1005
|
+
let { visible: u, pos: d, targetRef: p, tooltipRef: m, show: h, hide: g, handleMouseMove: _ } = j({
|
|
786
1006
|
mode: i,
|
|
787
1007
|
placement: a,
|
|
788
1008
|
delay: o,
|
|
789
1009
|
disabled: l
|
|
790
1010
|
}), v = s.Children.only(r), S = v.ref, C = f((e) => {
|
|
791
|
-
p.current = e,
|
|
1011
|
+
p.current = e, Me(S, e);
|
|
792
1012
|
}, [S, p]);
|
|
793
1013
|
return /* @__PURE__ */ x(y, { children: [s.cloneElement(v, {
|
|
794
1014
|
ref: C,
|
|
@@ -827,57 +1047,46 @@ function Se({ content: e, badge: t, variant: n = "dark", children: r, mode: i =
|
|
|
827
1047
|
}) : null] });
|
|
828
1048
|
}
|
|
829
1049
|
//#endregion
|
|
1050
|
+
//#region src/ui/JimboCopyButton.tsx
|
|
1051
|
+
function Pe({ value: e, label: t = "Copy", copiedLabel: n = "Copied", tone: r = "blue", size: i = "sm", copiedDurationMs: a = 1500, onCopy: o, className: s }) {
|
|
1052
|
+
let [c, l] = v(!1);
|
|
1053
|
+
function u() {
|
|
1054
|
+
navigator.clipboard.writeText(e).then(() => {
|
|
1055
|
+
l(!0), o?.(), window.setTimeout(() => l(!1), a);
|
|
1056
|
+
});
|
|
1057
|
+
}
|
|
1058
|
+
return /* @__PURE__ */ b(P, {
|
|
1059
|
+
tone: r,
|
|
1060
|
+
size: i,
|
|
1061
|
+
onClick: u,
|
|
1062
|
+
className: s,
|
|
1063
|
+
children: c ? n : t
|
|
1064
|
+
});
|
|
1065
|
+
}
|
|
1066
|
+
//#endregion
|
|
830
1067
|
//#region src/ui/codeBlock.tsx
|
|
831
|
-
function
|
|
832
|
-
let
|
|
1068
|
+
function Fe({ code: e, language: t, filename: n, className: r = "" }) {
|
|
1069
|
+
let i = n?.toLowerCase().endsWith(".jaml") ? "JAML" : t?.toLowerCase() === "yaml" ? void 0 : t;
|
|
833
1070
|
return /* @__PURE__ */ x("div", {
|
|
834
1071
|
className: `j-code-block ${r}`,
|
|
835
1072
|
children: [/* @__PURE__ */ x("div", {
|
|
836
1073
|
className: "j-code-block__header",
|
|
837
1074
|
children: [/* @__PURE__ */ x("div", {
|
|
838
1075
|
className: "j-code-block__meta",
|
|
839
|
-
children: [n && /* @__PURE__ */ b(
|
|
1076
|
+
children: [n && /* @__PURE__ */ b(N, {
|
|
1077
|
+
size: "xs",
|
|
1078
|
+
tone: "grey",
|
|
840
1079
|
className: "j-code-block__filename",
|
|
841
1080
|
children: n
|
|
842
|
-
}),
|
|
1081
|
+
}), i && /* @__PURE__ */ b("span", {
|
|
843
1082
|
className: "j-code-block__lang",
|
|
844
|
-
children:
|
|
1083
|
+
children: /* @__PURE__ */ b(N, {
|
|
1084
|
+
size: "micro",
|
|
1085
|
+
tone: "blue",
|
|
1086
|
+
children: i
|
|
1087
|
+
})
|
|
845
1088
|
})]
|
|
846
|
-
}), /* @__PURE__ */ b(
|
|
847
|
-
onClick: () => {
|
|
848
|
-
navigator.clipboard.writeText(e), a(!0), setTimeout(() => a(!1), 2e3);
|
|
849
|
-
},
|
|
850
|
-
title: "Copy",
|
|
851
|
-
className: "j-code-block__copy",
|
|
852
|
-
"data-copied": i,
|
|
853
|
-
children: i ? /* @__PURE__ */ b("svg", {
|
|
854
|
-
width: "14",
|
|
855
|
-
height: "14",
|
|
856
|
-
viewBox: "0 0 24 24",
|
|
857
|
-
fill: "none",
|
|
858
|
-
stroke: "currentColor",
|
|
859
|
-
strokeWidth: "2.5",
|
|
860
|
-
strokeLinecap: "round",
|
|
861
|
-
strokeLinejoin: "round",
|
|
862
|
-
children: /* @__PURE__ */ b("polyline", { points: "20 6 9 17 4 12" })
|
|
863
|
-
}) : /* @__PURE__ */ x("svg", {
|
|
864
|
-
width: "14",
|
|
865
|
-
height: "14",
|
|
866
|
-
viewBox: "0 0 24 24",
|
|
867
|
-
fill: "none",
|
|
868
|
-
stroke: "currentColor",
|
|
869
|
-
strokeWidth: "2",
|
|
870
|
-
strokeLinecap: "round",
|
|
871
|
-
strokeLinejoin: "round",
|
|
872
|
-
children: [/* @__PURE__ */ b("rect", {
|
|
873
|
-
x: "9",
|
|
874
|
-
y: "9",
|
|
875
|
-
width: "13",
|
|
876
|
-
height: "13",
|
|
877
|
-
rx: "2"
|
|
878
|
-
}), /* @__PURE__ */ b("path", { d: "M5 15H4a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h9a2 2 0 0 1 2 2v1" })]
|
|
879
|
-
})
|
|
880
|
-
})]
|
|
1089
|
+
}), /* @__PURE__ */ b(Pe, { value: e })]
|
|
881
1090
|
}), /* @__PURE__ */ b("pre", {
|
|
882
1091
|
className: "j-code-block__pre",
|
|
883
1092
|
children: /* @__PURE__ */ b("code", { children: e })
|
|
@@ -885,31 +1094,8 @@ function Ce({ code: e, language: t, filename: n, className: r = "" }) {
|
|
|
885
1094
|
});
|
|
886
1095
|
}
|
|
887
1096
|
//#endregion
|
|
888
|
-
//#region src/ui/jimboApp.tsx
|
|
889
|
-
function we({ children: e, fluid: t, className: n = "", ...r }) {
|
|
890
|
-
return /* @__PURE__ */ b("div", {
|
|
891
|
-
className: `j-app${t ? " j-app--fluid" : ""} ${n}`.trim(),
|
|
892
|
-
...r,
|
|
893
|
-
children: e
|
|
894
|
-
});
|
|
895
|
-
}
|
|
896
|
-
function Te({ children: e, className: t = "", ...n }) {
|
|
897
|
-
return /* @__PURE__ */ b("div", {
|
|
898
|
-
className: `j-app__scroll ${t}`,
|
|
899
|
-
...n,
|
|
900
|
-
children: e
|
|
901
|
-
});
|
|
902
|
-
}
|
|
903
|
-
function Ee({ children: e, className: t = "", ...n }) {
|
|
904
|
-
return /* @__PURE__ */ b("div", {
|
|
905
|
-
className: `j-app__footer ${t}`,
|
|
906
|
-
...n,
|
|
907
|
-
children: e
|
|
908
|
-
});
|
|
909
|
-
}
|
|
910
|
-
//#endregion
|
|
911
1097
|
//#region src/ui/jimboSectionHeader.tsx
|
|
912
|
-
function
|
|
1098
|
+
function Ie({ label: e, tone: t = "blue", className: n = "" }) {
|
|
913
1099
|
return /* @__PURE__ */ x("div", {
|
|
914
1100
|
className: `j-section-header ${n}`,
|
|
915
1101
|
children: [/* @__PURE__ */ b("div", {
|
|
@@ -920,7 +1106,7 @@ function De({ label: e, tone: t = "blue", className: n = "" }) {
|
|
|
920
1106
|
}
|
|
921
1107
|
//#endregion
|
|
922
1108
|
//#region src/ui/jimboInfoCard.tsx
|
|
923
|
-
function
|
|
1109
|
+
function Le({ tone: e, children: t, className: n = "", ...r }) {
|
|
924
1110
|
return /* @__PURE__ */ b("div", {
|
|
925
1111
|
className: `j-info-card ${e ? `j-border--${e}` : ""} ${n}`,
|
|
926
1112
|
style: e ? { borderColor: void 0 } : void 0,
|
|
@@ -928,25 +1114,25 @@ function Oe({ tone: e, children: t, className: n = "", ...r }) {
|
|
|
928
1114
|
children: t
|
|
929
1115
|
});
|
|
930
1116
|
}
|
|
931
|
-
function
|
|
1117
|
+
function Re({ children: e, className: t = "" }) {
|
|
932
1118
|
return /* @__PURE__ */ b("div", {
|
|
933
1119
|
className: `j-info-card__body ${t}`,
|
|
934
1120
|
children: e
|
|
935
1121
|
});
|
|
936
1122
|
}
|
|
937
|
-
function
|
|
1123
|
+
function ze({ children: e, className: t = "" }) {
|
|
938
1124
|
return /* @__PURE__ */ b("div", {
|
|
939
1125
|
className: `j-info-card__title ${t}`,
|
|
940
1126
|
children: e
|
|
941
1127
|
});
|
|
942
1128
|
}
|
|
943
|
-
function
|
|
1129
|
+
function Be({ children: e, className: t = "" }) {
|
|
944
1130
|
return /* @__PURE__ */ b("div", {
|
|
945
1131
|
className: `j-info-card__sub ${t}`,
|
|
946
1132
|
children: e
|
|
947
1133
|
});
|
|
948
1134
|
}
|
|
949
|
-
function
|
|
1135
|
+
function Ve({ children: e, className: t = "" }) {
|
|
950
1136
|
return /* @__PURE__ */ b("div", {
|
|
951
1137
|
className: `j-info-card__aside ${t}`,
|
|
952
1138
|
children: e
|
|
@@ -954,263 +1140,380 @@ function Me({ children: e, className: t = "" }) {
|
|
|
954
1140
|
}
|
|
955
1141
|
//#endregion
|
|
956
1142
|
//#region src/ui/showcase.tsx
|
|
957
|
-
function
|
|
958
|
-
return /* @__PURE__ */ x(
|
|
959
|
-
|
|
960
|
-
|
|
961
|
-
|
|
962
|
-
|
|
963
|
-
|
|
964
|
-
|
|
965
|
-
|
|
966
|
-
|
|
967
|
-
|
|
968
|
-
|
|
969
|
-
|
|
970
|
-
|
|
971
|
-
|
|
972
|
-
|
|
973
|
-
|
|
974
|
-
|
|
975
|
-
|
|
976
|
-
|
|
977
|
-
|
|
978
|
-
|
|
979
|
-
|
|
980
|
-
|
|
981
|
-
|
|
1143
|
+
function He({ title: e = "Balatro", subtitle: t = "Seed Curator", hotFilters: n = [], recentFinds: r = [], mcpInfo: i, onNewSearch: a, onBrowseFilters: o, onFilterClick: s }) {
|
|
1144
|
+
return /* @__PURE__ */ x(Se, { children: [/* @__PURE__ */ x("div", {
|
|
1145
|
+
style: {
|
|
1146
|
+
padding: "12px 12px 8px",
|
|
1147
|
+
display: "flex",
|
|
1148
|
+
flexDirection: "column",
|
|
1149
|
+
gap: 6
|
|
1150
|
+
},
|
|
1151
|
+
children: [
|
|
1152
|
+
/* @__PURE__ */ x("div", {
|
|
1153
|
+
className: "j-text-center",
|
|
1154
|
+
children: [/* @__PURE__ */ b(N, {
|
|
1155
|
+
size: "display",
|
|
1156
|
+
tone: "gold",
|
|
1157
|
+
children: e
|
|
1158
|
+
}), /* @__PURE__ */ b(N, {
|
|
1159
|
+
size: "micro",
|
|
1160
|
+
tone: "grey",
|
|
1161
|
+
style: { letterSpacing: 1 },
|
|
1162
|
+
children: t
|
|
1163
|
+
})]
|
|
1164
|
+
}),
|
|
1165
|
+
i && /* @__PURE__ */ x("div", {
|
|
1166
|
+
className: "j-flex j-justify-between",
|
|
1167
|
+
style: {
|
|
1168
|
+
padding: "3px 8px",
|
|
1169
|
+
background: "var(--j-surface-inset)",
|
|
1170
|
+
borderRadius: 4,
|
|
1171
|
+
border: "1px solid var(--j-panel-edge)"
|
|
1172
|
+
},
|
|
1173
|
+
children: [/* @__PURE__ */ b(N, {
|
|
1174
|
+
size: "micro",
|
|
1175
|
+
tone: "purple",
|
|
1176
|
+
children: i.engine
|
|
1177
|
+
}), /* @__PURE__ */ b(N, {
|
|
1178
|
+
size: "micro",
|
|
1179
|
+
tone: "white",
|
|
1180
|
+
children: i.features
|
|
1181
|
+
})]
|
|
1182
|
+
}),
|
|
1183
|
+
n.length > 0 && /* @__PURE__ */ x(y, { children: [/* @__PURE__ */ b(Ie, {
|
|
1184
|
+
label: "Filters",
|
|
1185
|
+
tone: "blue"
|
|
1186
|
+
}), /* @__PURE__ */ b("div", {
|
|
1187
|
+
className: "j-flex-col",
|
|
1188
|
+
style: { gap: 4 },
|
|
1189
|
+
children: n.slice(0, 4).map((e, t) => /* @__PURE__ */ x(Le, {
|
|
1190
|
+
tone: e.tone,
|
|
1191
|
+
onClick: () => s?.(e, t),
|
|
1192
|
+
style: { cursor: s ? "pointer" : void 0 },
|
|
1193
|
+
children: [
|
|
1194
|
+
/* @__PURE__ */ b("div", {
|
|
1195
|
+
className: "j-flex j-gap-xs",
|
|
1196
|
+
children: e.sample.slice(0, 2).map((e, t) => /* @__PURE__ */ b("div", {
|
|
1197
|
+
style: {
|
|
1198
|
+
width: 22,
|
|
1199
|
+
height: 28,
|
|
1200
|
+
display: "flex",
|
|
1201
|
+
alignItems: "center",
|
|
1202
|
+
justifyContent: "center"
|
|
1203
|
+
},
|
|
1204
|
+
children: /* @__PURE__ */ b(te, {
|
|
1205
|
+
name: e,
|
|
1206
|
+
width: 20
|
|
1207
|
+
})
|
|
1208
|
+
}, t))
|
|
1209
|
+
}),
|
|
1210
|
+
/* @__PURE__ */ x(Re, { children: [/* @__PURE__ */ b(ze, { children: e.name }), /* @__PURE__ */ x(Be, { children: ["by ", e.author] })] }),
|
|
1211
|
+
/* @__PURE__ */ b(Ve, { children: /* @__PURE__ */ b(N, {
|
|
1212
|
+
size: "xs",
|
|
1213
|
+
tone: e.tone === "gold" ? "gold" : e.tone,
|
|
1214
|
+
children: e.hits
|
|
1215
|
+
}) })
|
|
1216
|
+
]
|
|
1217
|
+
}, t))
|
|
1218
|
+
})] }),
|
|
1219
|
+
r.length > 0 && /* @__PURE__ */ x(y, { children: [/* @__PURE__ */ b(Ie, {
|
|
1220
|
+
label: "Recent",
|
|
1221
|
+
tone: "green"
|
|
1222
|
+
}), /* @__PURE__ */ b("div", {
|
|
1223
|
+
style: {
|
|
1224
|
+
background: "var(--j-surface-inset)",
|
|
1225
|
+
borderRadius: "var(--j-radius-md)",
|
|
1226
|
+
padding: "6px 8px",
|
|
1227
|
+
lineHeight: 1.5
|
|
1228
|
+
},
|
|
1229
|
+
children: r.slice(0, 3).map((e, t) => /* @__PURE__ */ x("div", {
|
|
1230
|
+
className: "j-flex j-gap-sm",
|
|
982
1231
|
style: {
|
|
983
|
-
|
|
984
|
-
|
|
985
|
-
|
|
986
|
-
border: "1px solid var(--j-panel-edge)"
|
|
1232
|
+
background: t % 2 == 1 ? "var(--j-surface-inset-alt)" : "transparent",
|
|
1233
|
+
borderRadius: "var(--j-radius-sm)",
|
|
1234
|
+
padding: "1px 4px"
|
|
987
1235
|
},
|
|
988
|
-
children: [
|
|
989
|
-
|
|
990
|
-
|
|
991
|
-
|
|
992
|
-
|
|
993
|
-
|
|
994
|
-
|
|
995
|
-
|
|
996
|
-
|
|
997
|
-
|
|
998
|
-
|
|
999
|
-
|
|
1000
|
-
|
|
1001
|
-
|
|
1002
|
-
|
|
1003
|
-
|
|
1004
|
-
|
|
1005
|
-
|
|
1006
|
-
|
|
1007
|
-
|
|
1008
|
-
|
|
1009
|
-
|
|
1010
|
-
|
|
1011
|
-
|
|
1012
|
-
|
|
1013
|
-
|
|
1014
|
-
|
|
1015
|
-
|
|
1016
|
-
|
|
1017
|
-
|
|
1018
|
-
|
|
1019
|
-
|
|
1020
|
-
|
|
1021
|
-
width: 20
|
|
1022
|
-
})
|
|
1023
|
-
}, t))
|
|
1024
|
-
}),
|
|
1025
|
-
/* @__PURE__ */ x(ke, { children: [/* @__PURE__ */ b(Ae, { children: e.name }), /* @__PURE__ */ x(je, { children: ["by ", e.author] })] }),
|
|
1026
|
-
/* @__PURE__ */ b(Me, { children: /* @__PURE__ */ b(j, {
|
|
1027
|
-
size: "xs",
|
|
1028
|
-
tone: e.tone === "gold" ? "gold" : e.tone,
|
|
1029
|
-
children: e.hits
|
|
1030
|
-
}) })
|
|
1031
|
-
]
|
|
1032
|
-
}, t))
|
|
1033
|
-
})] }),
|
|
1034
|
-
r.length > 0 && /* @__PURE__ */ x(y, { children: [/* @__PURE__ */ b(De, {
|
|
1035
|
-
label: "Recent",
|
|
1036
|
-
tone: "green"
|
|
1037
|
-
}), /* @__PURE__ */ b("div", {
|
|
1038
|
-
style: { lineHeight: 1.5 },
|
|
1039
|
-
children: r.slice(0, 3).map((e, t) => /* @__PURE__ */ x("div", {
|
|
1040
|
-
className: "j-flex j-gap-sm",
|
|
1041
|
-
children: [
|
|
1042
|
-
/* @__PURE__ */ b(j, {
|
|
1043
|
-
size: "micro",
|
|
1044
|
-
tone: "gold",
|
|
1045
|
-
children: e.seed
|
|
1046
|
-
}),
|
|
1047
|
-
/* @__PURE__ */ b(j, {
|
|
1048
|
-
size: "micro",
|
|
1049
|
-
tone: "grey",
|
|
1050
|
-
children: e.filterName
|
|
1051
|
-
}),
|
|
1052
|
-
e.score > 0 && /* @__PURE__ */ x(j, {
|
|
1053
|
-
size: "micro",
|
|
1054
|
-
tone: "green",
|
|
1055
|
-
children: ["+", e.score]
|
|
1056
|
-
})
|
|
1057
|
-
]
|
|
1058
|
-
}, t))
|
|
1059
|
-
})] })
|
|
1060
|
-
]
|
|
1061
|
-
}),
|
|
1062
|
-
/* @__PURE__ */ x(Ee, { children: [/* @__PURE__ */ b(N, {
|
|
1063
|
-
tone: "red",
|
|
1064
|
-
fullWidth: !0,
|
|
1065
|
-
size: "lg",
|
|
1066
|
-
onClick: a,
|
|
1067
|
-
children: "New Search"
|
|
1068
|
-
}), /* @__PURE__ */ b(N, {
|
|
1069
|
-
tone: "blue",
|
|
1070
|
-
fullWidth: !0,
|
|
1071
|
-
size: "lg",
|
|
1072
|
-
onClick: o,
|
|
1073
|
-
children: "Browse Filters"
|
|
1074
|
-
})] }),
|
|
1075
|
-
/* @__PURE__ */ b(ye, {})
|
|
1076
|
-
] });
|
|
1236
|
+
children: [
|
|
1237
|
+
/* @__PURE__ */ b(N, {
|
|
1238
|
+
size: "micro",
|
|
1239
|
+
tone: "gold",
|
|
1240
|
+
children: e.seed
|
|
1241
|
+
}),
|
|
1242
|
+
/* @__PURE__ */ b(N, {
|
|
1243
|
+
size: "micro",
|
|
1244
|
+
tone: "grey",
|
|
1245
|
+
children: e.filterName
|
|
1246
|
+
}),
|
|
1247
|
+
e.score > 0 && /* @__PURE__ */ x(N, {
|
|
1248
|
+
size: "micro",
|
|
1249
|
+
tone: "green",
|
|
1250
|
+
children: ["+", e.score]
|
|
1251
|
+
})
|
|
1252
|
+
]
|
|
1253
|
+
}, t))
|
|
1254
|
+
})] })
|
|
1255
|
+
]
|
|
1256
|
+
}), /* @__PURE__ */ x(we, { children: [/* @__PURE__ */ b(P, {
|
|
1257
|
+
tone: "red",
|
|
1258
|
+
fullWidth: !0,
|
|
1259
|
+
size: "lg",
|
|
1260
|
+
onClick: a,
|
|
1261
|
+
children: "New Search"
|
|
1262
|
+
}), /* @__PURE__ */ b(P, {
|
|
1263
|
+
tone: "blue",
|
|
1264
|
+
fullWidth: !0,
|
|
1265
|
+
size: "lg",
|
|
1266
|
+
onClick: o,
|
|
1267
|
+
children: "Browse Filters"
|
|
1268
|
+
})] })] });
|
|
1077
1269
|
}
|
|
1078
1270
|
//#endregion
|
|
1079
1271
|
//#region src/ui/jimboCopyRow.tsx
|
|
1080
|
-
function
|
|
1081
|
-
let [n, r] = v(!1);
|
|
1082
|
-
function i() {
|
|
1083
|
-
navigator.clipboard.writeText(e).then(() => {
|
|
1084
|
-
r(!0), setTimeout(() => r(!1), 1500);
|
|
1085
|
-
});
|
|
1086
|
-
}
|
|
1272
|
+
function Ue({ value: e, label: t }) {
|
|
1087
1273
|
return /* @__PURE__ */ x("div", {
|
|
1088
1274
|
className: "j-copy-row",
|
|
1089
|
-
children: [t
|
|
1275
|
+
children: [t ? /* @__PURE__ */ b(N, {
|
|
1090
1276
|
size: "xs",
|
|
1091
1277
|
tone: "grey",
|
|
1092
1278
|
className: "j-copy-row__label",
|
|
1093
1279
|
children: t
|
|
1094
|
-
}), /* @__PURE__ */
|
|
1095
|
-
|
|
1096
|
-
|
|
1097
|
-
|
|
1098
|
-
|
|
1099
|
-
|
|
1100
|
-
|
|
1280
|
+
}) : null, /* @__PURE__ */ b(be, { value: e })]
|
|
1281
|
+
});
|
|
1282
|
+
}
|
|
1283
|
+
//#endregion
|
|
1284
|
+
//#region src/ui/jimboWordmark.tsx
|
|
1285
|
+
function We({ title: e, subtitle: t, className: n = "" }) {
|
|
1286
|
+
return /* @__PURE__ */ x("div", {
|
|
1287
|
+
className: `j-wordmark ${n}`,
|
|
1288
|
+
children: [/* @__PURE__ */ b("div", {
|
|
1289
|
+
className: "j-wordmark__title",
|
|
1290
|
+
children: e
|
|
1291
|
+
}), t && /* @__PURE__ */ b("div", {
|
|
1292
|
+
className: "j-wordmark__sub",
|
|
1293
|
+
children: t
|
|
1294
|
+
})]
|
|
1295
|
+
});
|
|
1296
|
+
}
|
|
1297
|
+
//#endregion
|
|
1298
|
+
//#region src/ui/jimboStatGrid.tsx
|
|
1299
|
+
function Ge({ items: e, className: t = "", ...n }) {
|
|
1300
|
+
return /* @__PURE__ */ b("div", {
|
|
1301
|
+
className: `j-stat-grid ${t}`,
|
|
1302
|
+
...n,
|
|
1303
|
+
children: e.map((e) => /* @__PURE__ */ x("div", { children: [/* @__PURE__ */ b("div", {
|
|
1304
|
+
className: "j-stat-grid__value",
|
|
1305
|
+
children: e.value
|
|
1306
|
+
}), /* @__PURE__ */ b("div", {
|
|
1307
|
+
className: "j-stat-grid__label",
|
|
1308
|
+
children: e.label
|
|
1309
|
+
})] }, e.label))
|
|
1310
|
+
});
|
|
1311
|
+
}
|
|
1312
|
+
//#endregion
|
|
1313
|
+
//#region src/ui/jimboLayout.tsx
|
|
1314
|
+
function Ke({ gap: e, align: t, justify: n, className: r = "", ...i }) {
|
|
1315
|
+
return /* @__PURE__ */ b("div", {
|
|
1316
|
+
className: [
|
|
1317
|
+
"j-stack",
|
|
1318
|
+
e && `j-stack--gap-${e}`,
|
|
1319
|
+
t && `j-stack--align-${t}`,
|
|
1320
|
+
n && `j-stack--justify-${n}`,
|
|
1321
|
+
r
|
|
1322
|
+
].filter(Boolean).join(" "),
|
|
1323
|
+
...i
|
|
1324
|
+
});
|
|
1325
|
+
}
|
|
1326
|
+
function qe({ gap: e, align: t, justify: n, wrap: r = !1, className: i = "", ...a }) {
|
|
1327
|
+
return /* @__PURE__ */ b("div", {
|
|
1328
|
+
className: [
|
|
1329
|
+
"j-row",
|
|
1330
|
+
e && `j-row--gap-${e}`,
|
|
1331
|
+
t && `j-row--align-${t}`,
|
|
1332
|
+
n && `j-row--justify-${n}`,
|
|
1333
|
+
r && "j-row--wrap",
|
|
1334
|
+
i
|
|
1335
|
+
].filter(Boolean).join(" "),
|
|
1336
|
+
...a
|
|
1337
|
+
});
|
|
1338
|
+
}
|
|
1339
|
+
//#endregion
|
|
1340
|
+
//#region src/ui/jimboInset.tsx
|
|
1341
|
+
function Je({ children: e, className: t = "", ...n }) {
|
|
1342
|
+
return /* @__PURE__ */ b("div", {
|
|
1343
|
+
className: `j-inset ${t}`.trim(),
|
|
1344
|
+
...n,
|
|
1345
|
+
children: e
|
|
1346
|
+
});
|
|
1347
|
+
}
|
|
1348
|
+
//#endregion
|
|
1349
|
+
//#region src/ui/JimboPanelSpinner.tsx
|
|
1350
|
+
function Ye({ label: e, title: t, description: n, media: r, meta: i, className: a = "", style: o, onPrev: s, onNext: c, prevDisabled: l = !1, nextDisabled: u = !1 }) {
|
|
1351
|
+
return /* @__PURE__ */ x("div", {
|
|
1352
|
+
className: `j-panel-spinner ${a}`.trim(),
|
|
1353
|
+
style: o,
|
|
1354
|
+
children: [e ? /* @__PURE__ */ b("div", {
|
|
1355
|
+
className: "j-panel-spinner__label",
|
|
1356
|
+
children: /* @__PURE__ */ b(N, {
|
|
1357
|
+
size: "xs",
|
|
1358
|
+
tone: "grey",
|
|
1359
|
+
children: e
|
|
1360
|
+
})
|
|
1361
|
+
}) : null, /* @__PURE__ */ x("div", {
|
|
1362
|
+
className: "j-panel-spinner__row",
|
|
1363
|
+
children: [
|
|
1364
|
+
/* @__PURE__ */ b(P, {
|
|
1365
|
+
tone: "red",
|
|
1366
|
+
size: "lg",
|
|
1367
|
+
className: "j-panel-spinner__arrow j-panel-spinner__arrow--left",
|
|
1368
|
+
onClick: s,
|
|
1369
|
+
disabled: l,
|
|
1370
|
+
"aria-label": "Previous",
|
|
1371
|
+
children: "<"
|
|
1372
|
+
}),
|
|
1373
|
+
/* @__PURE__ */ x("div", {
|
|
1374
|
+
className: "j-panel-spinner__panel",
|
|
1375
|
+
children: [
|
|
1376
|
+
r ? /* @__PURE__ */ b("div", {
|
|
1377
|
+
className: "j-panel-spinner__media",
|
|
1378
|
+
children: r
|
|
1379
|
+
}) : null,
|
|
1380
|
+
/* @__PURE__ */ b("div", {
|
|
1381
|
+
className: "j-panel-spinner__title",
|
|
1382
|
+
children: /* @__PURE__ */ b(N, {
|
|
1383
|
+
size: "md",
|
|
1384
|
+
tone: "white",
|
|
1385
|
+
children: t
|
|
1386
|
+
})
|
|
1387
|
+
}),
|
|
1388
|
+
i ? /* @__PURE__ */ b("div", {
|
|
1389
|
+
className: "j-panel-spinner__meta",
|
|
1390
|
+
children: i
|
|
1391
|
+
}) : null,
|
|
1392
|
+
n ? /* @__PURE__ */ b("div", {
|
|
1393
|
+
className: "j-panel-spinner__description",
|
|
1394
|
+
children: /* @__PURE__ */ b(N, {
|
|
1395
|
+
size: "micro",
|
|
1396
|
+
tone: "grey",
|
|
1397
|
+
children: n
|
|
1398
|
+
})
|
|
1399
|
+
}) : null
|
|
1400
|
+
]
|
|
1401
|
+
}),
|
|
1402
|
+
/* @__PURE__ */ b(P, {
|
|
1403
|
+
tone: "red",
|
|
1404
|
+
size: "lg",
|
|
1405
|
+
className: "j-panel-spinner__arrow j-panel-spinner__arrow--right",
|
|
1406
|
+
onClick: c,
|
|
1407
|
+
disabled: u,
|
|
1408
|
+
"aria-label": "Next",
|
|
1409
|
+
children: ">"
|
|
1101
1410
|
})
|
|
1102
|
-
|
|
1103
|
-
type: "button",
|
|
1104
|
-
className: "j-copy-row__btn",
|
|
1105
|
-
"data-copied": n,
|
|
1106
|
-
onClick: i,
|
|
1107
|
-
children: n ? "Copied" : "Copy"
|
|
1108
|
-
})]
|
|
1109
|
-
})]
|
|
1110
|
-
});
|
|
1111
|
-
}
|
|
1112
|
-
//#endregion
|
|
1113
|
-
//#region src/ui/jimboWordmark.tsx
|
|
1114
|
-
function Fe({ title: e, subtitle: t, className: n = "" }) {
|
|
1115
|
-
return /* @__PURE__ */ x("div", {
|
|
1116
|
-
className: `j-wordmark ${n}`,
|
|
1117
|
-
children: [/* @__PURE__ */ b("div", {
|
|
1118
|
-
className: "j-wordmark__title",
|
|
1119
|
-
children: e
|
|
1120
|
-
}), t && /* @__PURE__ */ b("div", {
|
|
1121
|
-
className: "j-wordmark__sub",
|
|
1122
|
-
children: t
|
|
1411
|
+
]
|
|
1123
1412
|
})]
|
|
1124
1413
|
});
|
|
1125
1414
|
}
|
|
1126
1415
|
//#endregion
|
|
1127
|
-
//#region src/ui/
|
|
1128
|
-
function
|
|
1129
|
-
|
|
1130
|
-
|
|
1131
|
-
...n,
|
|
1132
|
-
children: e.map((e) => /* @__PURE__ */ x("div", { children: [/* @__PURE__ */ b("div", {
|
|
1133
|
-
className: "j-stat-grid__value",
|
|
1134
|
-
children: e.value
|
|
1135
|
-
}), /* @__PURE__ */ b("div", {
|
|
1136
|
-
className: "j-stat-grid__label",
|
|
1137
|
-
children: e.label
|
|
1138
|
-
})] }, e.label))
|
|
1139
|
-
});
|
|
1416
|
+
//#region src/ui/JimboDeckAndStakeSelectorModal.tsx
|
|
1417
|
+
function Xe(e, t, n) {
|
|
1418
|
+
let r = e.indexOf(t);
|
|
1419
|
+
return r < 0 ? e[0] ?? t : e[(r + n + e.length) % e.length] ?? t;
|
|
1140
1420
|
}
|
|
1141
|
-
|
|
1142
|
-
|
|
1143
|
-
|
|
1144
|
-
|
|
1145
|
-
|
|
1146
|
-
|
|
1147
|
-
|
|
1421
|
+
function Ze({ open: e, onClose: t, decks: n, stakes: r, deck: i, stake: a, onDeckChange: o, onStakeChange: s, title: c = "Search seeds for", deckDescription: l, stakeDescription: u }) {
|
|
1422
|
+
return /* @__PURE__ */ b(ue, {
|
|
1423
|
+
open: e,
|
|
1424
|
+
onClose: t,
|
|
1425
|
+
title: c,
|
|
1426
|
+
children: /* @__PURE__ */ x(Ke, {
|
|
1427
|
+
gap: "md",
|
|
1428
|
+
align: "stretch",
|
|
1429
|
+
children: [/* @__PURE__ */ b(Ye, {
|
|
1430
|
+
label: "Deck",
|
|
1431
|
+
title: `${i} Deck`,
|
|
1432
|
+
description: l ? l(i) : " ",
|
|
1433
|
+
media: /* @__PURE__ */ b(ae, {
|
|
1434
|
+
deck: i,
|
|
1435
|
+
width: 64
|
|
1436
|
+
}),
|
|
1437
|
+
onPrev: () => o(Xe(n, i, -1)),
|
|
1438
|
+
onNext: () => o(Xe(n, i, 1))
|
|
1439
|
+
}), /* @__PURE__ */ b(Ye, {
|
|
1440
|
+
label: "Stake",
|
|
1441
|
+
title: `${a} Stake`,
|
|
1442
|
+
description: u ? u(a) : " ",
|
|
1443
|
+
media: /* @__PURE__ */ b(re, {
|
|
1444
|
+
stake: a,
|
|
1445
|
+
width: 48
|
|
1446
|
+
}),
|
|
1447
|
+
onPrev: () => s(Xe(r, a, -1)),
|
|
1448
|
+
onNext: () => s(Xe(r, a, 1))
|
|
1449
|
+
})]
|
|
1450
|
+
})
|
|
1148
1451
|
});
|
|
1149
1452
|
}
|
|
1150
1453
|
//#endregion
|
|
1151
1454
|
//#region node_modules/.pnpm/js-yaml@4.1.1/node_modules/js-yaml/dist/js-yaml.mjs
|
|
1152
|
-
function
|
|
1455
|
+
function Qe(e) {
|
|
1153
1456
|
return e == null;
|
|
1154
1457
|
}
|
|
1155
|
-
function
|
|
1458
|
+
function $e(e) {
|
|
1156
1459
|
return typeof e == "object" && !!e;
|
|
1157
1460
|
}
|
|
1158
|
-
function
|
|
1159
|
-
return Array.isArray(e) ? e :
|
|
1461
|
+
function et(e) {
|
|
1462
|
+
return Array.isArray(e) ? e : Qe(e) ? [] : [e];
|
|
1160
1463
|
}
|
|
1161
|
-
function
|
|
1464
|
+
function tt(e, t) {
|
|
1162
1465
|
var n, r, i, a;
|
|
1163
1466
|
if (t) for (a = Object.keys(t), n = 0, r = a.length; n < r; n += 1) i = a[n], e[i] = t[i];
|
|
1164
1467
|
return e;
|
|
1165
1468
|
}
|
|
1166
|
-
function
|
|
1469
|
+
function nt(e, t) {
|
|
1167
1470
|
var n = "", r;
|
|
1168
1471
|
for (r = 0; r < t; r += 1) n += e;
|
|
1169
1472
|
return n;
|
|
1170
1473
|
}
|
|
1171
|
-
function
|
|
1474
|
+
function rt(e) {
|
|
1172
1475
|
return e === 0 && 1 / e == -Infinity;
|
|
1173
1476
|
}
|
|
1174
|
-
var
|
|
1175
|
-
isNothing:
|
|
1176
|
-
isObject:
|
|
1177
|
-
toArray:
|
|
1178
|
-
repeat:
|
|
1179
|
-
isNegativeZero:
|
|
1180
|
-
extend:
|
|
1477
|
+
var I = {
|
|
1478
|
+
isNothing: Qe,
|
|
1479
|
+
isObject: $e,
|
|
1480
|
+
toArray: et,
|
|
1481
|
+
repeat: nt,
|
|
1482
|
+
isNegativeZero: rt,
|
|
1483
|
+
extend: tt
|
|
1181
1484
|
};
|
|
1182
|
-
function
|
|
1485
|
+
function it(e, t) {
|
|
1183
1486
|
var n = "", r = e.reason || "(unknown reason)";
|
|
1184
1487
|
return e.mark ? (e.mark.name && (n += "in \"" + e.mark.name + "\" "), n += "(" + (e.mark.line + 1) + ":" + (e.mark.column + 1) + ")", !t && e.mark.snippet && (n += "\n\n" + e.mark.snippet), r + " " + n) : r;
|
|
1185
1488
|
}
|
|
1186
|
-
function
|
|
1187
|
-
Error.call(this), this.name = "YAMLException", this.reason = e, this.mark = t, this.message =
|
|
1489
|
+
function at(e, t) {
|
|
1490
|
+
Error.call(this), this.name = "YAMLException", this.reason = e, this.mark = t, this.message = it(this, !1), Error.captureStackTrace ? Error.captureStackTrace(this, this.constructor) : this.stack = (/* @__PURE__ */ Error()).stack || "";
|
|
1188
1491
|
}
|
|
1189
|
-
|
|
1190
|
-
return this.name + ": " +
|
|
1492
|
+
at.prototype = Object.create(Error.prototype), at.prototype.constructor = at, at.prototype.toString = function(e) {
|
|
1493
|
+
return this.name + ": " + it(this, e);
|
|
1191
1494
|
};
|
|
1192
|
-
var
|
|
1193
|
-
function
|
|
1495
|
+
var L = at;
|
|
1496
|
+
function ot(e, t, n, r, i) {
|
|
1194
1497
|
var a = "", o = "", s = Math.floor(i / 2) - 1;
|
|
1195
1498
|
return r - t > s && (a = " ... ", t = r - s + a.length), n - r > s && (o = " ...", n = r + s - o.length), {
|
|
1196
1499
|
str: a + e.slice(t, n).replace(/\t/g, "→") + o,
|
|
1197
1500
|
pos: r - t + a.length
|
|
1198
1501
|
};
|
|
1199
1502
|
}
|
|
1200
|
-
function
|
|
1201
|
-
return
|
|
1503
|
+
function st(e, t) {
|
|
1504
|
+
return I.repeat(" ", t - e.length) + e;
|
|
1202
1505
|
}
|
|
1203
|
-
function
|
|
1506
|
+
function ct(e, t) {
|
|
1204
1507
|
if (t = Object.create(t || null), !e.buffer) return null;
|
|
1205
1508
|
t.maxLength ||= 79, typeof t.indent != "number" && (t.indent = 1), typeof t.linesBefore != "number" && (t.linesBefore = 3), typeof t.linesAfter != "number" && (t.linesAfter = 2);
|
|
1206
1509
|
for (var n = /\r?\n|\r|\0/g, r = [0], i = [], a, o = -1; a = n.exec(e.buffer);) i.push(a.index), r.push(a.index + a[0].length), e.position <= a.index && o < 0 && (o = r.length - 2);
|
|
1207
1510
|
o < 0 && (o = r.length - 1);
|
|
1208
1511
|
var s = "", c, l, u = Math.min(e.line + t.linesAfter, i.length).toString().length, d = t.maxLength - (t.indent + u + 3);
|
|
1209
|
-
for (c = 1; c <= t.linesBefore && !(o - c < 0); c++) l =
|
|
1210
|
-
for (l =
|
|
1512
|
+
for (c = 1; c <= t.linesBefore && !(o - c < 0); c++) l = ot(e.buffer, r[o - c], i[o - c], e.position - (r[o] - r[o - c]), d), s = I.repeat(" ", t.indent) + st((e.line - c + 1).toString(), u) + " | " + l.str + "\n" + s;
|
|
1513
|
+
for (l = ot(e.buffer, r[o], i[o], e.position, d), s += I.repeat(" ", t.indent) + st((e.line + 1).toString(), u) + " | " + l.str + "\n", s += I.repeat("-", t.indent + u + 3 + l.pos) + "^\n", c = 1; c <= t.linesAfter && !(o + c >= i.length); c++) l = ot(e.buffer, r[o + c], i[o + c], e.position - (r[o] - r[o + c]), d), s += I.repeat(" ", t.indent) + st((e.line + c + 1).toString(), u) + " | " + l.str + "\n";
|
|
1211
1514
|
return s.replace(/\n$/, "");
|
|
1212
1515
|
}
|
|
1213
|
-
var
|
|
1516
|
+
var lt = ct, ut = [
|
|
1214
1517
|
"kind",
|
|
1215
1518
|
"multi",
|
|
1216
1519
|
"resolve",
|
|
@@ -1221,12 +1524,12 @@ var Je = qe, Ye = [
|
|
|
1221
1524
|
"representName",
|
|
1222
1525
|
"defaultStyle",
|
|
1223
1526
|
"styleAliases"
|
|
1224
|
-
],
|
|
1527
|
+
], dt = [
|
|
1225
1528
|
"scalar",
|
|
1226
1529
|
"sequence",
|
|
1227
1530
|
"mapping"
|
|
1228
1531
|
];
|
|
1229
|
-
function
|
|
1532
|
+
function ft(e) {
|
|
1230
1533
|
var t = {};
|
|
1231
1534
|
return e !== null && Object.keys(e).forEach(function(n) {
|
|
1232
1535
|
e[n].forEach(function(e) {
|
|
@@ -1234,17 +1537,17 @@ function Ze(e) {
|
|
|
1234
1537
|
});
|
|
1235
1538
|
}), t;
|
|
1236
1539
|
}
|
|
1237
|
-
function
|
|
1540
|
+
function pt(e, t) {
|
|
1238
1541
|
if (t ||= {}, Object.keys(t).forEach(function(t) {
|
|
1239
|
-
if (
|
|
1542
|
+
if (ut.indexOf(t) === -1) throw new L("Unknown option \"" + t + "\" is met in definition of \"" + e + "\" YAML type.");
|
|
1240
1543
|
}), this.options = t, this.tag = e, this.kind = t.kind || null, this.resolve = t.resolve || function() {
|
|
1241
1544
|
return !0;
|
|
1242
1545
|
}, this.construct = t.construct || function(e) {
|
|
1243
1546
|
return e;
|
|
1244
|
-
}, this.instanceOf = t.instanceOf || null, this.predicate = t.predicate || null, this.represent = t.represent || null, this.representName = t.representName || null, this.defaultStyle = t.defaultStyle || null, this.multi = t.multi || !1, this.styleAliases =
|
|
1547
|
+
}, this.instanceOf = t.instanceOf || null, this.predicate = t.predicate || null, this.represent = t.represent || null, this.representName = t.representName || null, this.defaultStyle = t.defaultStyle || null, this.multi = t.multi || !1, this.styleAliases = ft(t.styleAliases || null), dt.indexOf(this.kind) === -1) throw new L("Unknown kind \"" + this.kind + "\" is specified for \"" + e + "\" YAML type.");
|
|
1245
1548
|
}
|
|
1246
|
-
var
|
|
1247
|
-
function
|
|
1549
|
+
var R = pt;
|
|
1550
|
+
function mt(e, t) {
|
|
1248
1551
|
var n = [];
|
|
1249
1552
|
return e[t].forEach(function(e) {
|
|
1250
1553
|
var t = n.length;
|
|
@@ -1253,7 +1556,7 @@ function $e(e, t) {
|
|
|
1253
1556
|
}), n[t] = e;
|
|
1254
1557
|
}), n;
|
|
1255
1558
|
}
|
|
1256
|
-
function
|
|
1559
|
+
function ht() {
|
|
1257
1560
|
var e = {
|
|
1258
1561
|
scalar: {},
|
|
1259
1562
|
sequence: {},
|
|
@@ -1272,61 +1575,61 @@ function et() {
|
|
|
1272
1575
|
for (t = 0, n = arguments.length; t < n; t += 1) arguments[t].forEach(r);
|
|
1273
1576
|
return e;
|
|
1274
1577
|
}
|
|
1275
|
-
function
|
|
1578
|
+
function gt(e) {
|
|
1276
1579
|
return this.extend(e);
|
|
1277
1580
|
}
|
|
1278
|
-
|
|
1581
|
+
gt.prototype.extend = function(e) {
|
|
1279
1582
|
var t = [], n = [];
|
|
1280
|
-
if (e instanceof
|
|
1583
|
+
if (e instanceof R) n.push(e);
|
|
1281
1584
|
else if (Array.isArray(e)) n = n.concat(e);
|
|
1282
1585
|
else if (e && (Array.isArray(e.implicit) || Array.isArray(e.explicit))) e.implicit && (t = t.concat(e.implicit)), e.explicit && (n = n.concat(e.explicit));
|
|
1283
|
-
else throw new
|
|
1586
|
+
else throw new L("Schema.extend argument should be a Type, [ Type ], or a schema definition ({ implicit: [...], explicit: [...] })");
|
|
1284
1587
|
t.forEach(function(e) {
|
|
1285
|
-
if (!(e instanceof
|
|
1286
|
-
if (e.loadKind && e.loadKind !== "scalar") throw new
|
|
1287
|
-
if (e.multi) throw new
|
|
1588
|
+
if (!(e instanceof R)) throw new L("Specified list of YAML types (or a single Type object) contains a non-Type object.");
|
|
1589
|
+
if (e.loadKind && e.loadKind !== "scalar") throw new L("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.");
|
|
1590
|
+
if (e.multi) throw new L("There is a multi type in the implicit list of a schema. Multi tags can only be listed as explicit.");
|
|
1288
1591
|
}), n.forEach(function(e) {
|
|
1289
|
-
if (!(e instanceof
|
|
1592
|
+
if (!(e instanceof R)) throw new L("Specified list of YAML types (or a single Type object) contains a non-Type object.");
|
|
1290
1593
|
});
|
|
1291
|
-
var r = Object.create(
|
|
1292
|
-
return r.implicit = (this.implicit || []).concat(t), r.explicit = (this.explicit || []).concat(n), r.compiledImplicit =
|
|
1594
|
+
var r = Object.create(gt.prototype);
|
|
1595
|
+
return r.implicit = (this.implicit || []).concat(t), r.explicit = (this.explicit || []).concat(n), r.compiledImplicit = mt(r, "implicit"), r.compiledExplicit = mt(r, "explicit"), r.compiledTypeMap = ht(r.compiledImplicit, r.compiledExplicit), r;
|
|
1293
1596
|
};
|
|
1294
|
-
var
|
|
1597
|
+
var _t = gt, vt = new R("tag:yaml.org,2002:str", {
|
|
1295
1598
|
kind: "scalar",
|
|
1296
1599
|
construct: function(e) {
|
|
1297
1600
|
return e === null ? "" : e;
|
|
1298
1601
|
}
|
|
1299
|
-
}),
|
|
1602
|
+
}), yt = new R("tag:yaml.org,2002:seq", {
|
|
1300
1603
|
kind: "sequence",
|
|
1301
1604
|
construct: function(e) {
|
|
1302
1605
|
return e === null ? [] : e;
|
|
1303
1606
|
}
|
|
1304
|
-
}),
|
|
1607
|
+
}), bt = new R("tag:yaml.org,2002:map", {
|
|
1305
1608
|
kind: "mapping",
|
|
1306
1609
|
construct: function(e) {
|
|
1307
1610
|
return e === null ? {} : e;
|
|
1308
1611
|
}
|
|
1309
|
-
}),
|
|
1310
|
-
|
|
1311
|
-
|
|
1312
|
-
|
|
1612
|
+
}), xt = new _t({ explicit: [
|
|
1613
|
+
vt,
|
|
1614
|
+
yt,
|
|
1615
|
+
bt
|
|
1313
1616
|
] });
|
|
1314
|
-
function
|
|
1617
|
+
function St(e) {
|
|
1315
1618
|
if (e === null) return !0;
|
|
1316
1619
|
var t = e.length;
|
|
1317
1620
|
return t === 1 && e === "~" || t === 4 && (e === "null" || e === "Null" || e === "NULL");
|
|
1318
1621
|
}
|
|
1319
|
-
function
|
|
1622
|
+
function Ct() {
|
|
1320
1623
|
return null;
|
|
1321
1624
|
}
|
|
1322
|
-
function
|
|
1625
|
+
function wt(e) {
|
|
1323
1626
|
return e === null;
|
|
1324
1627
|
}
|
|
1325
|
-
var
|
|
1628
|
+
var Tt = new R("tag:yaml.org,2002:null", {
|
|
1326
1629
|
kind: "scalar",
|
|
1327
|
-
resolve:
|
|
1328
|
-
construct:
|
|
1329
|
-
predicate:
|
|
1630
|
+
resolve: St,
|
|
1631
|
+
construct: Ct,
|
|
1632
|
+
predicate: wt,
|
|
1330
1633
|
represent: {
|
|
1331
1634
|
canonical: function() {
|
|
1332
1635
|
return "~";
|
|
@@ -1346,22 +1649,22 @@ var ut = new L("tag:yaml.org,2002:null", {
|
|
|
1346
1649
|
},
|
|
1347
1650
|
defaultStyle: "lowercase"
|
|
1348
1651
|
});
|
|
1349
|
-
function
|
|
1652
|
+
function Et(e) {
|
|
1350
1653
|
if (e === null) return !1;
|
|
1351
1654
|
var t = e.length;
|
|
1352
1655
|
return t === 4 && (e === "true" || e === "True" || e === "TRUE") || t === 5 && (e === "false" || e === "False" || e === "FALSE");
|
|
1353
1656
|
}
|
|
1354
|
-
function
|
|
1657
|
+
function Dt(e) {
|
|
1355
1658
|
return e === "true" || e === "True" || e === "TRUE";
|
|
1356
1659
|
}
|
|
1357
|
-
function
|
|
1660
|
+
function Ot(e) {
|
|
1358
1661
|
return Object.prototype.toString.call(e) === "[object Boolean]";
|
|
1359
1662
|
}
|
|
1360
|
-
var
|
|
1663
|
+
var kt = new R("tag:yaml.org,2002:bool", {
|
|
1361
1664
|
kind: "scalar",
|
|
1362
|
-
resolve:
|
|
1363
|
-
construct:
|
|
1364
|
-
predicate:
|
|
1665
|
+
resolve: Et,
|
|
1666
|
+
construct: Dt,
|
|
1667
|
+
predicate: Ot,
|
|
1365
1668
|
represent: {
|
|
1366
1669
|
lowercase: function(e) {
|
|
1367
1670
|
return e ? "true" : "false";
|
|
@@ -1375,16 +1678,16 @@ var mt = new L("tag:yaml.org,2002:bool", {
|
|
|
1375
1678
|
},
|
|
1376
1679
|
defaultStyle: "lowercase"
|
|
1377
1680
|
});
|
|
1378
|
-
function
|
|
1681
|
+
function At(e) {
|
|
1379
1682
|
return 48 <= e && e <= 57 || 65 <= e && e <= 70 || 97 <= e && e <= 102;
|
|
1380
1683
|
}
|
|
1381
|
-
function
|
|
1684
|
+
function jt(e) {
|
|
1382
1685
|
return 48 <= e && e <= 55;
|
|
1383
1686
|
}
|
|
1384
|
-
function
|
|
1687
|
+
function Mt(e) {
|
|
1385
1688
|
return 48 <= e && e <= 57;
|
|
1386
1689
|
}
|
|
1387
|
-
function
|
|
1690
|
+
function Nt(e) {
|
|
1388
1691
|
if (e === null) return !1;
|
|
1389
1692
|
var t = e.length, n = 0, r = !1, i;
|
|
1390
1693
|
if (!t) return !1;
|
|
@@ -1399,14 +1702,14 @@ function vt(e) {
|
|
|
1399
1702
|
}
|
|
1400
1703
|
if (i === "x") {
|
|
1401
1704
|
for (n++; n < t; n++) if (i = e[n], i !== "_") {
|
|
1402
|
-
if (!
|
|
1705
|
+
if (!At(e.charCodeAt(n))) return !1;
|
|
1403
1706
|
r = !0;
|
|
1404
1707
|
}
|
|
1405
1708
|
return r && i !== "_";
|
|
1406
1709
|
}
|
|
1407
1710
|
if (i === "o") {
|
|
1408
1711
|
for (n++; n < t; n++) if (i = e[n], i !== "_") {
|
|
1409
|
-
if (!
|
|
1712
|
+
if (!jt(e.charCodeAt(n))) return !1;
|
|
1410
1713
|
r = !0;
|
|
1411
1714
|
}
|
|
1412
1715
|
return r && i !== "_";
|
|
@@ -1414,12 +1717,12 @@ function vt(e) {
|
|
|
1414
1717
|
}
|
|
1415
1718
|
if (i === "_") return !1;
|
|
1416
1719
|
for (; n < t; n++) if (i = e[n], i !== "_") {
|
|
1417
|
-
if (!
|
|
1720
|
+
if (!Mt(e.charCodeAt(n))) return !1;
|
|
1418
1721
|
r = !0;
|
|
1419
1722
|
}
|
|
1420
1723
|
return !(!r || i === "_");
|
|
1421
1724
|
}
|
|
1422
|
-
function
|
|
1725
|
+
function Pt(e) {
|
|
1423
1726
|
var t = e, n = 1, r;
|
|
1424
1727
|
if (t.indexOf("_") !== -1 && (t = t.replace(/_/g, "")), r = t[0], (r === "-" || r === "+") && (r === "-" && (n = -1), t = t.slice(1), r = t[0]), t === "0") return 0;
|
|
1425
1728
|
if (r === "0") {
|
|
@@ -1429,14 +1732,14 @@ function yt(e) {
|
|
|
1429
1732
|
}
|
|
1430
1733
|
return n * parseInt(t, 10);
|
|
1431
1734
|
}
|
|
1432
|
-
function
|
|
1433
|
-
return Object.prototype.toString.call(e) === "[object Number]" && e % 1 == 0 && !
|
|
1735
|
+
function Ft(e) {
|
|
1736
|
+
return Object.prototype.toString.call(e) === "[object Number]" && e % 1 == 0 && !I.isNegativeZero(e);
|
|
1434
1737
|
}
|
|
1435
|
-
var
|
|
1738
|
+
var It = new R("tag:yaml.org,2002:int", {
|
|
1436
1739
|
kind: "scalar",
|
|
1437
|
-
resolve:
|
|
1438
|
-
construct:
|
|
1439
|
-
predicate:
|
|
1740
|
+
resolve: Nt,
|
|
1741
|
+
construct: Pt,
|
|
1742
|
+
predicate: Ft,
|
|
1440
1743
|
represent: {
|
|
1441
1744
|
binary: function(e) {
|
|
1442
1745
|
return e >= 0 ? "0b" + e.toString(2) : "-0b" + e.toString(2).slice(1);
|
|
@@ -1458,16 +1761,16 @@ var xt = new L("tag:yaml.org,2002:int", {
|
|
|
1458
1761
|
decimal: [10, "dec"],
|
|
1459
1762
|
hexadecimal: [16, "hex"]
|
|
1460
1763
|
}
|
|
1461
|
-
}),
|
|
1462
|
-
function
|
|
1463
|
-
return !(e === null || !
|
|
1764
|
+
}), Lt = /* @__PURE__ */ RegExp("^(?:[-+]?(?:[0-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$");
|
|
1765
|
+
function Rt(e) {
|
|
1766
|
+
return !(e === null || !Lt.test(e) || e[e.length - 1] === "_");
|
|
1464
1767
|
}
|
|
1465
|
-
function
|
|
1768
|
+
function zt(e) {
|
|
1466
1769
|
var t = e.replace(/_/g, "").toLowerCase(), n = t[0] === "-" ? -1 : 1;
|
|
1467
1770
|
return "+-".indexOf(t[0]) >= 0 && (t = t.slice(1)), t === ".inf" ? n === 1 ? Infinity : -Infinity : t === ".nan" ? NaN : n * parseFloat(t, 10);
|
|
1468
1771
|
}
|
|
1469
|
-
var
|
|
1470
|
-
function
|
|
1772
|
+
var Bt = /^[-+]?[0-9]+e/;
|
|
1773
|
+
function Vt(e, t) {
|
|
1471
1774
|
var n;
|
|
1472
1775
|
if (isNaN(e)) switch (t) {
|
|
1473
1776
|
case "lowercase": return ".nan";
|
|
@@ -1484,31 +1787,31 @@ function Et(e, t) {
|
|
|
1484
1787
|
case "uppercase": return "-.INF";
|
|
1485
1788
|
case "camelcase": return "-.Inf";
|
|
1486
1789
|
}
|
|
1487
|
-
else if (
|
|
1488
|
-
return n = e.toString(10),
|
|
1790
|
+
else if (I.isNegativeZero(e)) return "-0.0";
|
|
1791
|
+
return n = e.toString(10), Bt.test(n) ? n.replace("e", ".e") : n;
|
|
1489
1792
|
}
|
|
1490
|
-
function
|
|
1491
|
-
return Object.prototype.toString.call(e) === "[object Number]" && (e % 1 != 0 ||
|
|
1793
|
+
function Ht(e) {
|
|
1794
|
+
return Object.prototype.toString.call(e) === "[object Number]" && (e % 1 != 0 || I.isNegativeZero(e));
|
|
1492
1795
|
}
|
|
1493
|
-
var
|
|
1796
|
+
var Ut = new R("tag:yaml.org,2002:float", {
|
|
1494
1797
|
kind: "scalar",
|
|
1495
|
-
resolve:
|
|
1496
|
-
construct:
|
|
1497
|
-
predicate:
|
|
1498
|
-
represent:
|
|
1798
|
+
resolve: Rt,
|
|
1799
|
+
construct: zt,
|
|
1800
|
+
predicate: Ht,
|
|
1801
|
+
represent: Vt,
|
|
1499
1802
|
defaultStyle: "lowercase"
|
|
1500
|
-
}),
|
|
1501
|
-
|
|
1502
|
-
|
|
1503
|
-
|
|
1504
|
-
|
|
1505
|
-
] }),
|
|
1506
|
-
function
|
|
1507
|
-
return e === null ? !1 :
|
|
1803
|
+
}), Wt = xt.extend({ implicit: [
|
|
1804
|
+
Tt,
|
|
1805
|
+
kt,
|
|
1806
|
+
It,
|
|
1807
|
+
Ut
|
|
1808
|
+
] }), Gt = Wt, Kt = /* @__PURE__ */ RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"), qt = /* @__PURE__ */ RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$");
|
|
1809
|
+
function Jt(e) {
|
|
1810
|
+
return e === null ? !1 : Kt.exec(e) !== null || qt.exec(e) !== null;
|
|
1508
1811
|
}
|
|
1509
|
-
function
|
|
1812
|
+
function Yt(e) {
|
|
1510
1813
|
var t, n, r, i, a, o, s, c = 0, l = null, u, d, f;
|
|
1511
|
-
if (t =
|
|
1814
|
+
if (t = Kt.exec(e), t === null && (t = qt.exec(e)), t === null) throw Error("Date resolve error");
|
|
1512
1815
|
if (n = +t[1], r = t[2] - 1, i = +t[3], !t[4]) return new Date(Date.UTC(n, r, i));
|
|
1513
1816
|
if (a = +t[4], o = +t[5], s = +t[6], t[7]) {
|
|
1514
1817
|
for (c = t[7].slice(0, 3); c.length < 3;) c += "0";
|
|
@@ -1516,58 +1819,58 @@ function Pt(e) {
|
|
|
1516
1819
|
}
|
|
1517
1820
|
return t[9] && (u = +t[10], d = +(t[11] || 0), l = (u * 60 + d) * 6e4, t[9] === "-" && (l = -l)), f = new Date(Date.UTC(n, r, i, a, o, s, c)), l && f.setTime(f.getTime() - l), f;
|
|
1518
1821
|
}
|
|
1519
|
-
function
|
|
1822
|
+
function Xt(e) {
|
|
1520
1823
|
return e.toISOString();
|
|
1521
1824
|
}
|
|
1522
|
-
var
|
|
1825
|
+
var Zt = new R("tag:yaml.org,2002:timestamp", {
|
|
1523
1826
|
kind: "scalar",
|
|
1524
|
-
resolve:
|
|
1525
|
-
construct:
|
|
1827
|
+
resolve: Jt,
|
|
1828
|
+
construct: Yt,
|
|
1526
1829
|
instanceOf: Date,
|
|
1527
|
-
represent:
|
|
1830
|
+
represent: Xt
|
|
1528
1831
|
});
|
|
1529
|
-
function
|
|
1832
|
+
function Qt(e) {
|
|
1530
1833
|
return e === "<<" || e === null;
|
|
1531
1834
|
}
|
|
1532
|
-
var
|
|
1835
|
+
var $t = new R("tag:yaml.org,2002:merge", {
|
|
1533
1836
|
kind: "scalar",
|
|
1534
|
-
resolve:
|
|
1535
|
-
}),
|
|
1536
|
-
function
|
|
1837
|
+
resolve: Qt
|
|
1838
|
+
}), en = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=\n\r";
|
|
1839
|
+
function tn(e) {
|
|
1537
1840
|
if (e === null) return !1;
|
|
1538
|
-
var t, n, r = 0, i = e.length, a =
|
|
1841
|
+
var t, n, r = 0, i = e.length, a = en;
|
|
1539
1842
|
for (n = 0; n < i; n++) if (t = a.indexOf(e.charAt(n)), !(t > 64)) {
|
|
1540
1843
|
if (t < 0) return !1;
|
|
1541
1844
|
r += 6;
|
|
1542
1845
|
}
|
|
1543
1846
|
return r % 8 == 0;
|
|
1544
1847
|
}
|
|
1545
|
-
function
|
|
1546
|
-
var t, n, r = e.replace(/[\r\n=]/g, ""), i = r.length, a =
|
|
1848
|
+
function nn(e) {
|
|
1849
|
+
var t, n, r = e.replace(/[\r\n=]/g, ""), i = r.length, a = en, o = 0, s = [];
|
|
1547
1850
|
for (t = 0; t < i; t++) t % 4 == 0 && t && (s.push(o >> 16 & 255), s.push(o >> 8 & 255), s.push(o & 255)), o = o << 6 | a.indexOf(r.charAt(t));
|
|
1548
1851
|
return n = i % 4 * 6, n === 0 ? (s.push(o >> 16 & 255), s.push(o >> 8 & 255), s.push(o & 255)) : n === 18 ? (s.push(o >> 10 & 255), s.push(o >> 2 & 255)) : n === 12 && s.push(o >> 4 & 255), new Uint8Array(s);
|
|
1549
1852
|
}
|
|
1550
|
-
function
|
|
1551
|
-
var t = "", n = 0, r, i, a = e.length, o =
|
|
1853
|
+
function rn(e) {
|
|
1854
|
+
var t = "", n = 0, r, i, a = e.length, o = en;
|
|
1552
1855
|
for (r = 0; r < a; r++) r % 3 == 0 && r && (t += o[n >> 18 & 63], t += o[n >> 12 & 63], t += o[n >> 6 & 63], t += o[n & 63]), n = (n << 8) + e[r];
|
|
1553
1856
|
return i = a % 3, i === 0 ? (t += o[n >> 18 & 63], t += o[n >> 12 & 63], t += o[n >> 6 & 63], t += o[n & 63]) : i === 2 ? (t += o[n >> 10 & 63], t += o[n >> 4 & 63], t += o[n << 2 & 63], t += o[64]) : i === 1 && (t += o[n >> 2 & 63], t += o[n << 4 & 63], t += o[64], t += o[64]), t;
|
|
1554
1857
|
}
|
|
1555
|
-
function
|
|
1858
|
+
function an(e) {
|
|
1556
1859
|
return Object.prototype.toString.call(e) === "[object Uint8Array]";
|
|
1557
1860
|
}
|
|
1558
|
-
var
|
|
1861
|
+
var on = new R("tag:yaml.org,2002:binary", {
|
|
1559
1862
|
kind: "scalar",
|
|
1560
|
-
resolve:
|
|
1561
|
-
construct:
|
|
1562
|
-
predicate:
|
|
1563
|
-
represent:
|
|
1564
|
-
}),
|
|
1565
|
-
function
|
|
1863
|
+
resolve: tn,
|
|
1864
|
+
construct: nn,
|
|
1865
|
+
predicate: an,
|
|
1866
|
+
represent: rn
|
|
1867
|
+
}), sn = Object.prototype.hasOwnProperty, cn = Object.prototype.toString;
|
|
1868
|
+
function ln(e) {
|
|
1566
1869
|
if (e === null) return !0;
|
|
1567
1870
|
var t = [], n, r, i, a, o, s = e;
|
|
1568
1871
|
for (n = 0, r = s.length; n < r; n += 1) {
|
|
1569
|
-
if (i = s[n], o = !1,
|
|
1570
|
-
for (a in i) if (
|
|
1872
|
+
if (i = s[n], o = !1, cn.call(i) !== "[object Object]") return !1;
|
|
1873
|
+
for (a in i) if (sn.call(i, a)) if (!o) o = !0;
|
|
1571
1874
|
else return !1;
|
|
1572
1875
|
if (!o) return !1;
|
|
1573
1876
|
if (t.indexOf(a) === -1) t.push(a);
|
|
@@ -1575,88 +1878,88 @@ function qt(e) {
|
|
|
1575
1878
|
}
|
|
1576
1879
|
return !0;
|
|
1577
1880
|
}
|
|
1578
|
-
function
|
|
1881
|
+
function un(e) {
|
|
1579
1882
|
return e === null ? [] : e;
|
|
1580
1883
|
}
|
|
1581
|
-
var
|
|
1884
|
+
var dn = new R("tag:yaml.org,2002:omap", {
|
|
1582
1885
|
kind: "sequence",
|
|
1583
|
-
resolve:
|
|
1584
|
-
construct:
|
|
1585
|
-
}),
|
|
1586
|
-
function
|
|
1886
|
+
resolve: ln,
|
|
1887
|
+
construct: un
|
|
1888
|
+
}), fn = Object.prototype.toString;
|
|
1889
|
+
function pn(e) {
|
|
1587
1890
|
if (e === null) return !0;
|
|
1588
1891
|
var t, n, r, i, a, o = e;
|
|
1589
1892
|
for (a = Array(o.length), t = 0, n = o.length; t < n; t += 1) {
|
|
1590
|
-
if (r = o[t],
|
|
1893
|
+
if (r = o[t], fn.call(r) !== "[object Object]" || (i = Object.keys(r), i.length !== 1)) return !1;
|
|
1591
1894
|
a[t] = [i[0], r[i[0]]];
|
|
1592
1895
|
}
|
|
1593
1896
|
return !0;
|
|
1594
1897
|
}
|
|
1595
|
-
function
|
|
1898
|
+
function mn(e) {
|
|
1596
1899
|
if (e === null) return [];
|
|
1597
1900
|
var t, n, r, i, a, o = e;
|
|
1598
1901
|
for (a = Array(o.length), t = 0, n = o.length; t < n; t += 1) r = o[t], i = Object.keys(r), a[t] = [i[0], r[i[0]]];
|
|
1599
1902
|
return a;
|
|
1600
1903
|
}
|
|
1601
|
-
var
|
|
1904
|
+
var hn = new R("tag:yaml.org,2002:pairs", {
|
|
1602
1905
|
kind: "sequence",
|
|
1603
|
-
resolve:
|
|
1604
|
-
construct:
|
|
1605
|
-
}),
|
|
1606
|
-
function
|
|
1906
|
+
resolve: pn,
|
|
1907
|
+
construct: mn
|
|
1908
|
+
}), gn = Object.prototype.hasOwnProperty;
|
|
1909
|
+
function _n(e) {
|
|
1607
1910
|
if (e === null) return !0;
|
|
1608
1911
|
var t, n = e;
|
|
1609
|
-
for (t in n) if (
|
|
1912
|
+
for (t in n) if (gn.call(n, t) && n[t] !== null) return !1;
|
|
1610
1913
|
return !0;
|
|
1611
1914
|
}
|
|
1612
|
-
function
|
|
1915
|
+
function vn(e) {
|
|
1613
1916
|
return e === null ? {} : e;
|
|
1614
1917
|
}
|
|
1615
|
-
var
|
|
1918
|
+
var yn = new R("tag:yaml.org,2002:set", {
|
|
1616
1919
|
kind: "mapping",
|
|
1617
|
-
resolve:
|
|
1618
|
-
construct:
|
|
1619
|
-
}),
|
|
1620
|
-
implicit: [
|
|
1920
|
+
resolve: _n,
|
|
1921
|
+
construct: vn
|
|
1922
|
+
}), bn = Gt.extend({
|
|
1923
|
+
implicit: [Zt, $t],
|
|
1621
1924
|
explicit: [
|
|
1622
|
-
|
|
1623
|
-
|
|
1624
|
-
|
|
1625
|
-
|
|
1925
|
+
on,
|
|
1926
|
+
dn,
|
|
1927
|
+
hn,
|
|
1928
|
+
yn
|
|
1626
1929
|
]
|
|
1627
|
-
}),
|
|
1628
|
-
function
|
|
1930
|
+
}), z = Object.prototype.hasOwnProperty, xn = 1, Sn = 2, Cn = 3, wn = 4, Tn = 1, En = 2, Dn = 3, On = /[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/, kn = /[\x85\u2028\u2029]/, An = /[,\[\]\{\}]/, jn = /^(?:!|!!|![a-z\-]+!)$/i, Mn = /^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i;
|
|
1931
|
+
function Nn(e) {
|
|
1629
1932
|
return Object.prototype.toString.call(e);
|
|
1630
1933
|
}
|
|
1631
|
-
function
|
|
1934
|
+
function B(e) {
|
|
1632
1935
|
return e === 10 || e === 13;
|
|
1633
1936
|
}
|
|
1634
|
-
function
|
|
1937
|
+
function V(e) {
|
|
1635
1938
|
return e === 9 || e === 32;
|
|
1636
1939
|
}
|
|
1637
|
-
function
|
|
1940
|
+
function H(e) {
|
|
1638
1941
|
return e === 9 || e === 32 || e === 10 || e === 13;
|
|
1639
1942
|
}
|
|
1640
|
-
function
|
|
1943
|
+
function U(e) {
|
|
1641
1944
|
return e === 44 || e === 91 || e === 93 || e === 123 || e === 125;
|
|
1642
1945
|
}
|
|
1643
|
-
function
|
|
1946
|
+
function Pn(e) {
|
|
1644
1947
|
var t;
|
|
1645
1948
|
return 48 <= e && e <= 57 ? e - 48 : (t = e | 32, 97 <= t && t <= 102 ? t - 97 + 10 : -1);
|
|
1646
1949
|
}
|
|
1647
|
-
function
|
|
1950
|
+
function Fn(e) {
|
|
1648
1951
|
return e === 120 ? 2 : e === 117 ? 4 : e === 85 ? 8 : 0;
|
|
1649
1952
|
}
|
|
1650
|
-
function
|
|
1953
|
+
function In(e) {
|
|
1651
1954
|
return 48 <= e && e <= 57 ? e - 48 : -1;
|
|
1652
1955
|
}
|
|
1653
|
-
function
|
|
1956
|
+
function Ln(e) {
|
|
1654
1957
|
return e === 48 ? "\0" : e === 97 ? "\x07" : e === 98 ? "\b" : e === 116 || e === 9 ? " " : e === 110 ? "\n" : e === 118 ? "\v" : e === 102 ? "\f" : e === 114 ? "\r" : e === 101 ? "\x1B" : e === 32 ? " " : e === 34 ? "\"" : e === 47 ? "/" : e === 92 ? "\\" : e === 78 ? "
" : e === 95 ? "\xA0" : e === 76 ? "\u2028" : e === 80 ? "\u2029" : "";
|
|
1655
1958
|
}
|
|
1656
|
-
function
|
|
1959
|
+
function Rn(e) {
|
|
1657
1960
|
return e <= 65535 ? String.fromCharCode(e) : String.fromCharCode((e - 65536 >> 10) + 55296, (e - 65536 & 1023) + 56320);
|
|
1658
1961
|
}
|
|
1659
|
-
function
|
|
1962
|
+
function zn(e, t, n) {
|
|
1660
1963
|
t === "__proto__" ? Object.defineProperty(e, t, {
|
|
1661
1964
|
configurable: !0,
|
|
1662
1965
|
enumerable: !0,
|
|
@@ -1664,11 +1967,11 @@ function wn(e, t, n) {
|
|
|
1664
1967
|
value: n
|
|
1665
1968
|
}) : e[t] = n;
|
|
1666
1969
|
}
|
|
1667
|
-
for (var
|
|
1668
|
-
function
|
|
1669
|
-
this.input = e, this.filename = t.filename || null, this.schema = t.schema ||
|
|
1970
|
+
for (var Bn = Array(256), Vn = Array(256), W = 0; W < 256; W++) Bn[W] = +!!Ln(W), Vn[W] = Ln(W);
|
|
1971
|
+
function Hn(e, t) {
|
|
1972
|
+
this.input = e, this.filename = t.filename || null, this.schema = t.schema || bn, this.onWarning = t.onWarning || null, this.legacy = t.legacy || !1, this.json = t.json || !1, this.listener = t.listener || null, this.implicitTypes = this.schema.compiledImplicit, this.typeMap = this.schema.compiledTypeMap, this.length = e.length, this.position = 0, this.line = 0, this.lineStart = 0, this.lineIndent = 0, this.firstTabInLine = -1, this.documents = [];
|
|
1670
1973
|
}
|
|
1671
|
-
function
|
|
1974
|
+
function Un(e, t) {
|
|
1672
1975
|
var n = {
|
|
1673
1976
|
name: e.filename,
|
|
1674
1977
|
buffer: e.input.slice(0, -1),
|
|
@@ -1676,292 +1979,292 @@ function On(e, t) {
|
|
|
1676
1979
|
line: e.line,
|
|
1677
1980
|
column: e.position - e.lineStart
|
|
1678
1981
|
};
|
|
1679
|
-
return n.snippet =
|
|
1982
|
+
return n.snippet = lt(n), new L(t, n);
|
|
1680
1983
|
}
|
|
1681
|
-
function
|
|
1682
|
-
throw
|
|
1984
|
+
function G(e, t) {
|
|
1985
|
+
throw Un(e, t);
|
|
1683
1986
|
}
|
|
1684
|
-
function
|
|
1685
|
-
e.onWarning && e.onWarning.call(null,
|
|
1987
|
+
function Wn(e, t) {
|
|
1988
|
+
e.onWarning && e.onWarning.call(null, Un(e, t));
|
|
1686
1989
|
}
|
|
1687
|
-
var
|
|
1990
|
+
var Gn = {
|
|
1688
1991
|
YAML: function(e, t, n) {
|
|
1689
1992
|
var r, i, a;
|
|
1690
|
-
e.version !== null &&
|
|
1993
|
+
e.version !== null && G(e, "duplication of %YAML directive"), n.length !== 1 && G(e, "YAML directive accepts exactly one argument"), r = /^([0-9]+)\.([0-9]+)$/.exec(n[0]), r === null && G(e, "ill-formed argument of the YAML directive"), i = parseInt(r[1], 10), a = parseInt(r[2], 10), i !== 1 && G(e, "unacceptable YAML version of the document"), e.version = n[0], e.checkLineBreaks = a < 2, a !== 1 && a !== 2 && Wn(e, "unsupported YAML version of the document");
|
|
1691
1994
|
},
|
|
1692
1995
|
TAG: function(e, t, n) {
|
|
1693
1996
|
var r, i;
|
|
1694
|
-
n.length !== 2 &&
|
|
1997
|
+
n.length !== 2 && G(e, "TAG directive accepts exactly two arguments"), r = n[0], i = n[1], jn.test(r) || G(e, "ill-formed tag handle (first argument) of the TAG directive"), z.call(e.tagMap, r) && G(e, "there is a previously declared suffix for \"" + r + "\" tag handle"), Mn.test(i) || G(e, "ill-formed tag prefix (second argument) of the TAG directive");
|
|
1695
1998
|
try {
|
|
1696
1999
|
i = decodeURIComponent(i);
|
|
1697
2000
|
} catch {
|
|
1698
|
-
|
|
2001
|
+
G(e, "tag prefix is malformed: " + i);
|
|
1699
2002
|
}
|
|
1700
2003
|
e.tagMap[r] = i;
|
|
1701
2004
|
}
|
|
1702
2005
|
};
|
|
1703
|
-
function
|
|
2006
|
+
function K(e, t, n, r) {
|
|
1704
2007
|
var i, a, o, s;
|
|
1705
2008
|
if (t < n) {
|
|
1706
|
-
if (s = e.input.slice(t, n), r) for (i = 0, a = s.length; i < a; i += 1) o = s.charCodeAt(i), o === 9 || 32 <= o && o <= 1114111 ||
|
|
1707
|
-
else
|
|
2009
|
+
if (s = e.input.slice(t, n), r) for (i = 0, a = s.length; i < a; i += 1) o = s.charCodeAt(i), o === 9 || 32 <= o && o <= 1114111 || G(e, "expected valid JSON character");
|
|
2010
|
+
else On.test(s) && G(e, "the stream contains non-printable characters");
|
|
1708
2011
|
e.result += s;
|
|
1709
2012
|
}
|
|
1710
2013
|
}
|
|
1711
|
-
function
|
|
2014
|
+
function Kn(e, t, n, r) {
|
|
1712
2015
|
var i, a, o, s;
|
|
1713
|
-
for (
|
|
2016
|
+
for (I.isObject(n) || G(e, "cannot merge mappings; the provided source object is unacceptable"), i = Object.keys(n), o = 0, s = i.length; o < s; o += 1) a = i[o], z.call(t, a) || (zn(t, a, n[a]), r[a] = !0);
|
|
1714
2017
|
}
|
|
1715
|
-
function
|
|
2018
|
+
function q(e, t, n, r, i, a, o, s, c) {
|
|
1716
2019
|
var l, u;
|
|
1717
|
-
if (Array.isArray(i)) for (i = Array.prototype.slice.call(i), l = 0, u = i.length; l < u; l += 1) Array.isArray(i[l]) &&
|
|
1718
|
-
if (typeof i == "object" &&
|
|
1719
|
-
else
|
|
1720
|
-
else !e.json && !
|
|
2020
|
+
if (Array.isArray(i)) for (i = Array.prototype.slice.call(i), l = 0, u = i.length; l < u; l += 1) Array.isArray(i[l]) && G(e, "nested arrays are not supported inside keys"), typeof i == "object" && Nn(i[l]) === "[object Object]" && (i[l] = "[object Object]");
|
|
2021
|
+
if (typeof i == "object" && Nn(i) === "[object Object]" && (i = "[object Object]"), i = String(i), t === null && (t = {}), r === "tag:yaml.org,2002:merge") if (Array.isArray(a)) for (l = 0, u = a.length; l < u; l += 1) Kn(e, t, a[l], n);
|
|
2022
|
+
else Kn(e, t, a, n);
|
|
2023
|
+
else !e.json && !z.call(n, i) && z.call(t, i) && (e.line = o || e.line, e.lineStart = s || e.lineStart, e.position = c || e.position, G(e, "duplicated mapping key")), zn(t, i, a), delete n[i];
|
|
1721
2024
|
return t;
|
|
1722
2025
|
}
|
|
1723
|
-
function
|
|
2026
|
+
function qn(e) {
|
|
1724
2027
|
var t = e.input.charCodeAt(e.position);
|
|
1725
|
-
t === 10 ? e.position++ : t === 13 ? (e.position++, e.input.charCodeAt(e.position) === 10 && e.position++) :
|
|
2028
|
+
t === 10 ? e.position++ : t === 13 ? (e.position++, e.input.charCodeAt(e.position) === 10 && e.position++) : G(e, "a line break is expected"), e.line += 1, e.lineStart = e.position, e.firstTabInLine = -1;
|
|
1726
2029
|
}
|
|
1727
|
-
function
|
|
2030
|
+
function J(e, t, n) {
|
|
1728
2031
|
for (var r = 0, i = e.input.charCodeAt(e.position); i !== 0;) {
|
|
1729
|
-
for (;
|
|
2032
|
+
for (; V(i);) i === 9 && e.firstTabInLine === -1 && (e.firstTabInLine = e.position), i = e.input.charCodeAt(++e.position);
|
|
1730
2033
|
if (t && i === 35) do
|
|
1731
2034
|
i = e.input.charCodeAt(++e.position);
|
|
1732
2035
|
while (i !== 10 && i !== 13 && i !== 0);
|
|
1733
|
-
if (
|
|
2036
|
+
if (B(i)) for (qn(e), i = e.input.charCodeAt(e.position), r++, e.lineIndent = 0; i === 32;) e.lineIndent++, i = e.input.charCodeAt(++e.position);
|
|
1734
2037
|
else break;
|
|
1735
2038
|
}
|
|
1736
|
-
return n !== -1 && r !== 0 && e.lineIndent < n &&
|
|
2039
|
+
return n !== -1 && r !== 0 && e.lineIndent < n && Wn(e, "deficient indentation"), r;
|
|
1737
2040
|
}
|
|
1738
|
-
function
|
|
2041
|
+
function Jn(e) {
|
|
1739
2042
|
var t = e.position, n = e.input.charCodeAt(t);
|
|
1740
|
-
return !!((n === 45 || n === 46) && n === e.input.charCodeAt(t + 1) && n === e.input.charCodeAt(t + 2) && (t += 3, n = e.input.charCodeAt(t), n === 0 ||
|
|
2043
|
+
return !!((n === 45 || n === 46) && n === e.input.charCodeAt(t + 1) && n === e.input.charCodeAt(t + 2) && (t += 3, n = e.input.charCodeAt(t), n === 0 || H(n)));
|
|
1741
2044
|
}
|
|
1742
|
-
function
|
|
1743
|
-
t === 1 ? e.result += " " : t > 1 && (e.result +=
|
|
2045
|
+
function Yn(e, t) {
|
|
2046
|
+
t === 1 ? e.result += " " : t > 1 && (e.result += I.repeat("\n", t - 1));
|
|
1744
2047
|
}
|
|
1745
|
-
function
|
|
2048
|
+
function Xn(e, t, n) {
|
|
1746
2049
|
var r, i, a, o, s, c, l, u, d = e.kind, f = e.result, p = e.input.charCodeAt(e.position);
|
|
1747
|
-
if (
|
|
2050
|
+
if (H(p) || U(p) || p === 35 || p === 38 || p === 42 || p === 33 || p === 124 || p === 62 || p === 39 || p === 34 || p === 37 || p === 64 || p === 96 || (p === 63 || p === 45) && (i = e.input.charCodeAt(e.position + 1), H(i) || n && U(i))) return !1;
|
|
1748
2051
|
for (e.kind = "scalar", e.result = "", a = o = e.position, s = !1; p !== 0;) {
|
|
1749
2052
|
if (p === 58) {
|
|
1750
|
-
if (i = e.input.charCodeAt(e.position + 1),
|
|
2053
|
+
if (i = e.input.charCodeAt(e.position + 1), H(i) || n && U(i)) break;
|
|
1751
2054
|
} else if (p === 35) {
|
|
1752
|
-
if (r = e.input.charCodeAt(e.position - 1),
|
|
1753
|
-
} else if (e.position === e.lineStart &&
|
|
1754
|
-
else if (
|
|
2055
|
+
if (r = e.input.charCodeAt(e.position - 1), H(r)) break;
|
|
2056
|
+
} else if (e.position === e.lineStart && Jn(e) || n && U(p)) break;
|
|
2057
|
+
else if (B(p)) if (c = e.line, l = e.lineStart, u = e.lineIndent, J(e, !1, -1), e.lineIndent >= t) {
|
|
1755
2058
|
s = !0, p = e.input.charCodeAt(e.position);
|
|
1756
2059
|
continue;
|
|
1757
2060
|
} else {
|
|
1758
2061
|
e.position = o, e.line = c, e.lineStart = l, e.lineIndent = u;
|
|
1759
2062
|
break;
|
|
1760
2063
|
}
|
|
1761
|
-
s &&= (
|
|
2064
|
+
s &&= (K(e, a, o, !1), Yn(e, e.line - c), a = o = e.position, !1), V(p) || (o = e.position + 1), p = e.input.charCodeAt(++e.position);
|
|
1762
2065
|
}
|
|
1763
|
-
return
|
|
2066
|
+
return K(e, a, o, !1), e.result ? !0 : (e.kind = d, e.result = f, !1);
|
|
1764
2067
|
}
|
|
1765
|
-
function
|
|
2068
|
+
function Zn(e, t) {
|
|
1766
2069
|
var n = e.input.charCodeAt(e.position), r, i;
|
|
1767
2070
|
if (n !== 39) return !1;
|
|
1768
|
-
for (e.kind = "scalar", e.result = "", e.position++, r = i = e.position; (n = e.input.charCodeAt(e.position)) !== 0;) if (n === 39) if (
|
|
2071
|
+
for (e.kind = "scalar", e.result = "", e.position++, r = i = e.position; (n = e.input.charCodeAt(e.position)) !== 0;) if (n === 39) if (K(e, r, e.position, !0), n = e.input.charCodeAt(++e.position), n === 39) r = e.position, e.position++, i = e.position;
|
|
1769
2072
|
else return !0;
|
|
1770
|
-
else
|
|
1771
|
-
|
|
2073
|
+
else B(n) ? (K(e, r, i, !0), Yn(e, J(e, !1, t)), r = i = e.position) : e.position === e.lineStart && Jn(e) ? G(e, "unexpected end of the document within a single quoted scalar") : (e.position++, i = e.position);
|
|
2074
|
+
G(e, "unexpected end of the stream within a single quoted scalar");
|
|
1772
2075
|
}
|
|
1773
|
-
function
|
|
2076
|
+
function Qn(e, t) {
|
|
1774
2077
|
var n, r, i, a, o, s = e.input.charCodeAt(e.position);
|
|
1775
2078
|
if (s !== 34) return !1;
|
|
1776
|
-
for (e.kind = "scalar", e.result = "", e.position++, n = r = e.position; (s = e.input.charCodeAt(e.position)) !== 0;) if (s === 34) return
|
|
2079
|
+
for (e.kind = "scalar", e.result = "", e.position++, n = r = e.position; (s = e.input.charCodeAt(e.position)) !== 0;) if (s === 34) return K(e, n, e.position, !0), e.position++, !0;
|
|
1777
2080
|
else if (s === 92) {
|
|
1778
|
-
if (
|
|
1779
|
-
else if (s < 256 &&
|
|
1780
|
-
else if ((o =
|
|
1781
|
-
for (i = o, a = 0; i > 0; i--) s = e.input.charCodeAt(++e.position), (o =
|
|
1782
|
-
e.result +=
|
|
1783
|
-
} else
|
|
2081
|
+
if (K(e, n, e.position, !0), s = e.input.charCodeAt(++e.position), B(s)) J(e, !1, t);
|
|
2082
|
+
else if (s < 256 && Bn[s]) e.result += Vn[s], e.position++;
|
|
2083
|
+
else if ((o = Fn(s)) > 0) {
|
|
2084
|
+
for (i = o, a = 0; i > 0; i--) s = e.input.charCodeAt(++e.position), (o = Pn(s)) >= 0 ? a = (a << 4) + o : G(e, "expected hexadecimal character");
|
|
2085
|
+
e.result += Rn(a), e.position++;
|
|
2086
|
+
} else G(e, "unknown escape sequence");
|
|
1784
2087
|
n = r = e.position;
|
|
1785
|
-
} else
|
|
1786
|
-
|
|
2088
|
+
} else B(s) ? (K(e, n, r, !0), Yn(e, J(e, !1, t)), n = r = e.position) : e.position === e.lineStart && Jn(e) ? G(e, "unexpected end of the document within a double quoted scalar") : (e.position++, r = e.position);
|
|
2089
|
+
G(e, "unexpected end of the stream within a double quoted scalar");
|
|
1787
2090
|
}
|
|
1788
|
-
function
|
|
2091
|
+
function $n(e, t) {
|
|
1789
2092
|
var n = !0, r, i, a, o = e.tag, s, c = e.anchor, l, u, d, f, p, m = Object.create(null), h, g, _, v = e.input.charCodeAt(e.position);
|
|
1790
2093
|
if (v === 91) u = 93, p = !1, s = [];
|
|
1791
2094
|
else if (v === 123) u = 125, p = !0, s = {};
|
|
1792
2095
|
else return !1;
|
|
1793
2096
|
for (e.anchor !== null && (e.anchorMap[e.anchor] = s), v = e.input.charCodeAt(++e.position); v !== 0;) {
|
|
1794
|
-
if (
|
|
1795
|
-
n ? v === 44 &&
|
|
2097
|
+
if (J(e, !0, t), v = e.input.charCodeAt(e.position), v === u) return e.position++, e.tag = o, e.anchor = c, e.kind = p ? "mapping" : "sequence", e.result = s, !0;
|
|
2098
|
+
n ? v === 44 && G(e, "expected the node content, but found ','") : G(e, "missed comma between flow collection entries"), g = h = _ = null, d = f = !1, v === 63 && (l = e.input.charCodeAt(e.position + 1), H(l) && (d = f = !0, e.position++, J(e, !0, t))), r = e.line, i = e.lineStart, a = e.position, Y(e, t, xn, !1, !0), g = e.tag, h = e.result, J(e, !0, t), v = e.input.charCodeAt(e.position), (f || e.line === r) && v === 58 && (d = !0, v = e.input.charCodeAt(++e.position), J(e, !0, t), Y(e, t, xn, !1, !0), _ = e.result), p ? q(e, s, m, g, h, _, r, i, a) : d ? s.push(q(e, null, m, g, h, _, r, i, a)) : s.push(h), J(e, !0, t), v = e.input.charCodeAt(e.position), v === 44 ? (n = !0, v = e.input.charCodeAt(++e.position)) : n = !1;
|
|
1796
2099
|
}
|
|
1797
|
-
|
|
2100
|
+
G(e, "unexpected end of the stream within a flow collection");
|
|
1798
2101
|
}
|
|
1799
|
-
function
|
|
1800
|
-
var n, r, i =
|
|
2102
|
+
function er(e, t) {
|
|
2103
|
+
var n, r, i = Tn, a = !1, o = !1, s = t, c = 0, l = !1, u, d = e.input.charCodeAt(e.position);
|
|
1801
2104
|
if (d === 124) r = !1;
|
|
1802
2105
|
else if (d === 62) r = !0;
|
|
1803
2106
|
else return !1;
|
|
1804
|
-
for (e.kind = "scalar", e.result = ""; d !== 0;) if (d = e.input.charCodeAt(++e.position), d === 43 || d === 45)
|
|
1805
|
-
else if ((u =
|
|
2107
|
+
for (e.kind = "scalar", e.result = ""; d !== 0;) if (d = e.input.charCodeAt(++e.position), d === 43 || d === 45) Tn === i ? i = d === 43 ? Dn : En : G(e, "repeat of a chomping mode identifier");
|
|
2108
|
+
else if ((u = In(d)) >= 0) u === 0 ? G(e, "bad explicit indentation width of a block scalar; it cannot be less than one") : o ? G(e, "repeat of an indentation width identifier") : (s = t + u - 1, o = !0);
|
|
1806
2109
|
else break;
|
|
1807
|
-
if (
|
|
2110
|
+
if (V(d)) {
|
|
1808
2111
|
do
|
|
1809
2112
|
d = e.input.charCodeAt(++e.position);
|
|
1810
|
-
while (
|
|
2113
|
+
while (V(d));
|
|
1811
2114
|
if (d === 35) do
|
|
1812
2115
|
d = e.input.charCodeAt(++e.position);
|
|
1813
|
-
while (!
|
|
2116
|
+
while (!B(d) && d !== 0);
|
|
1814
2117
|
}
|
|
1815
2118
|
for (; d !== 0;) {
|
|
1816
|
-
for (
|
|
1817
|
-
if (!o && e.lineIndent > s && (s = e.lineIndent),
|
|
2119
|
+
for (qn(e), e.lineIndent = 0, d = e.input.charCodeAt(e.position); (!o || e.lineIndent < s) && d === 32;) e.lineIndent++, d = e.input.charCodeAt(++e.position);
|
|
2120
|
+
if (!o && e.lineIndent > s && (s = e.lineIndent), B(d)) {
|
|
1818
2121
|
c++;
|
|
1819
2122
|
continue;
|
|
1820
2123
|
}
|
|
1821
2124
|
if (e.lineIndent < s) {
|
|
1822
|
-
i ===
|
|
2125
|
+
i === Dn ? e.result += I.repeat("\n", a ? 1 + c : c) : i === Tn && a && (e.result += "\n");
|
|
1823
2126
|
break;
|
|
1824
2127
|
}
|
|
1825
|
-
for (r ?
|
|
1826
|
-
|
|
2128
|
+
for (r ? V(d) ? (l = !0, e.result += I.repeat("\n", a ? 1 + c : c)) : l ? (l = !1, e.result += I.repeat("\n", c + 1)) : c === 0 ? a && (e.result += " ") : e.result += I.repeat("\n", c) : e.result += I.repeat("\n", a ? 1 + c : c), a = !0, o = !0, c = 0, n = e.position; !B(d) && d !== 0;) d = e.input.charCodeAt(++e.position);
|
|
2129
|
+
K(e, n, e.position, !1);
|
|
1827
2130
|
}
|
|
1828
2131
|
return !0;
|
|
1829
2132
|
}
|
|
1830
|
-
function
|
|
2133
|
+
function tr(e, t) {
|
|
1831
2134
|
var n, r = e.tag, i = e.anchor, a = [], o, s = !1, c;
|
|
1832
2135
|
if (e.firstTabInLine !== -1) return !1;
|
|
1833
|
-
for (e.anchor !== null && (e.anchorMap[e.anchor] = a), c = e.input.charCodeAt(e.position); c !== 0 && (e.firstTabInLine !== -1 && (e.position = e.firstTabInLine,
|
|
1834
|
-
if (s = !0, e.position++,
|
|
2136
|
+
for (e.anchor !== null && (e.anchorMap[e.anchor] = a), c = e.input.charCodeAt(e.position); c !== 0 && (e.firstTabInLine !== -1 && (e.position = e.firstTabInLine, G(e, "tab characters must not be used in indentation")), !(c !== 45 || (o = e.input.charCodeAt(e.position + 1), !H(o))));) {
|
|
2137
|
+
if (s = !0, e.position++, J(e, !0, -1) && e.lineIndent <= t) {
|
|
1835
2138
|
a.push(null), c = e.input.charCodeAt(e.position);
|
|
1836
2139
|
continue;
|
|
1837
2140
|
}
|
|
1838
|
-
if (n = e.line,
|
|
2141
|
+
if (n = e.line, Y(e, t, Cn, !1, !0), a.push(e.result), J(e, !0, -1), c = e.input.charCodeAt(e.position), (e.line === n || e.lineIndent > t) && c !== 0) G(e, "bad indentation of a sequence entry");
|
|
1839
2142
|
else if (e.lineIndent < t) break;
|
|
1840
2143
|
}
|
|
1841
2144
|
return s ? (e.tag = r, e.anchor = i, e.kind = "sequence", e.result = a, !0) : !1;
|
|
1842
2145
|
}
|
|
1843
|
-
function
|
|
2146
|
+
function nr(e, t, n) {
|
|
1844
2147
|
var r, i, a, o, s, c, l = e.tag, u = e.anchor, d = {}, f = Object.create(null), p = null, m = null, h = null, g = !1, _ = !1, v;
|
|
1845
2148
|
if (e.firstTabInLine !== -1) return !1;
|
|
1846
2149
|
for (e.anchor !== null && (e.anchorMap[e.anchor] = d), v = e.input.charCodeAt(e.position); v !== 0;) {
|
|
1847
|
-
if (!g && e.firstTabInLine !== -1 && (e.position = e.firstTabInLine,
|
|
2150
|
+
if (!g && e.firstTabInLine !== -1 && (e.position = e.firstTabInLine, G(e, "tab characters must not be used in indentation")), r = e.input.charCodeAt(e.position + 1), a = e.line, (v === 63 || v === 58) && H(r)) v === 63 ? (g && (q(e, d, f, p, m, null, o, s, c), p = m = h = null), _ = !0, g = !0, i = !0) : g ? (g = !1, i = !0) : G(e, "incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line"), e.position += 1, v = r;
|
|
1848
2151
|
else {
|
|
1849
|
-
if (o = e.line, s = e.lineStart, c = e.position, !
|
|
2152
|
+
if (o = e.line, s = e.lineStart, c = e.position, !Y(e, n, Sn, !1, !0)) break;
|
|
1850
2153
|
if (e.line === a) {
|
|
1851
|
-
for (v = e.input.charCodeAt(e.position);
|
|
1852
|
-
if (v === 58) v = e.input.charCodeAt(++e.position),
|
|
1853
|
-
else if (_)
|
|
2154
|
+
for (v = e.input.charCodeAt(e.position); V(v);) v = e.input.charCodeAt(++e.position);
|
|
2155
|
+
if (v === 58) v = e.input.charCodeAt(++e.position), H(v) || G(e, "a whitespace character is expected after the key-value separator within a block mapping"), g && (q(e, d, f, p, m, null, o, s, c), p = m = h = null), _ = !0, g = !1, i = !1, p = e.tag, m = e.result;
|
|
2156
|
+
else if (_) G(e, "can not read an implicit mapping pair; a colon is missed");
|
|
1854
2157
|
else return e.tag = l, e.anchor = u, !0;
|
|
1855
|
-
} else if (_)
|
|
2158
|
+
} else if (_) G(e, "can not read a block mapping entry; a multiline key may not be an implicit key");
|
|
1856
2159
|
else return e.tag = l, e.anchor = u, !0;
|
|
1857
2160
|
}
|
|
1858
|
-
if ((e.line === a || e.lineIndent > t) && (g && (o = e.line, s = e.lineStart, c = e.position),
|
|
2161
|
+
if ((e.line === a || e.lineIndent > t) && (g && (o = e.line, s = e.lineStart, c = e.position), Y(e, t, wn, !0, i) && (g ? m = e.result : h = e.result), g || (q(e, d, f, p, m, h, o, s, c), p = m = h = null), J(e, !0, -1), v = e.input.charCodeAt(e.position)), (e.line === a || e.lineIndent > t) && v !== 0) G(e, "bad indentation of a mapping entry");
|
|
1859
2162
|
else if (e.lineIndent < t) break;
|
|
1860
2163
|
}
|
|
1861
|
-
return g &&
|
|
2164
|
+
return g && q(e, d, f, p, m, null, o, s, c), _ && (e.tag = l, e.anchor = u, e.kind = "mapping", e.result = d), _;
|
|
1862
2165
|
}
|
|
1863
|
-
function
|
|
2166
|
+
function rr(e) {
|
|
1864
2167
|
var t, n = !1, r = !1, i, a, o = e.input.charCodeAt(e.position);
|
|
1865
2168
|
if (o !== 33) return !1;
|
|
1866
|
-
if (e.tag !== null &&
|
|
2169
|
+
if (e.tag !== null && G(e, "duplication of a tag property"), o = e.input.charCodeAt(++e.position), o === 60 ? (n = !0, o = e.input.charCodeAt(++e.position)) : o === 33 ? (r = !0, i = "!!", o = e.input.charCodeAt(++e.position)) : i = "!", t = e.position, n) {
|
|
1867
2170
|
do
|
|
1868
2171
|
o = e.input.charCodeAt(++e.position);
|
|
1869
2172
|
while (o !== 0 && o !== 62);
|
|
1870
|
-
e.position < e.length ? (a = e.input.slice(t, e.position), o = e.input.charCodeAt(++e.position)) :
|
|
2173
|
+
e.position < e.length ? (a = e.input.slice(t, e.position), o = e.input.charCodeAt(++e.position)) : G(e, "unexpected end of the stream within a verbatim tag");
|
|
1871
2174
|
} else {
|
|
1872
|
-
for (; o !== 0 && !
|
|
1873
|
-
a = e.input.slice(t, e.position),
|
|
2175
|
+
for (; o !== 0 && !H(o);) o === 33 && (r ? G(e, "tag suffix cannot contain exclamation marks") : (i = e.input.slice(t - 1, e.position + 1), jn.test(i) || G(e, "named tag handle cannot contain such characters"), r = !0, t = e.position + 1)), o = e.input.charCodeAt(++e.position);
|
|
2176
|
+
a = e.input.slice(t, e.position), An.test(a) && G(e, "tag suffix cannot contain flow indicator characters");
|
|
1874
2177
|
}
|
|
1875
|
-
a && !
|
|
2178
|
+
a && !Mn.test(a) && G(e, "tag name cannot contain such characters: " + a);
|
|
1876
2179
|
try {
|
|
1877
2180
|
a = decodeURIComponent(a);
|
|
1878
2181
|
} catch {
|
|
1879
|
-
|
|
2182
|
+
G(e, "tag name is malformed: " + a);
|
|
1880
2183
|
}
|
|
1881
|
-
return n ? e.tag = a :
|
|
2184
|
+
return n ? e.tag = a : z.call(e.tagMap, i) ? e.tag = e.tagMap[i] + a : i === "!" ? e.tag = "!" + a : i === "!!" ? e.tag = "tag:yaml.org,2002:" + a : G(e, "undeclared tag handle \"" + i + "\""), !0;
|
|
1882
2185
|
}
|
|
1883
|
-
function
|
|
2186
|
+
function ir(e) {
|
|
1884
2187
|
var t, n = e.input.charCodeAt(e.position);
|
|
1885
2188
|
if (n !== 38) return !1;
|
|
1886
|
-
for (e.anchor !== null &&
|
|
1887
|
-
return e.position === t &&
|
|
2189
|
+
for (e.anchor !== null && G(e, "duplication of an anchor property"), n = e.input.charCodeAt(++e.position), t = e.position; n !== 0 && !H(n) && !U(n);) n = e.input.charCodeAt(++e.position);
|
|
2190
|
+
return e.position === t && G(e, "name of an anchor node must contain at least one character"), e.anchor = e.input.slice(t, e.position), !0;
|
|
1888
2191
|
}
|
|
1889
|
-
function
|
|
2192
|
+
function ar(e) {
|
|
1890
2193
|
var t, n, r = e.input.charCodeAt(e.position);
|
|
1891
2194
|
if (r !== 42) return !1;
|
|
1892
|
-
for (r = e.input.charCodeAt(++e.position), t = e.position; r !== 0 && !
|
|
1893
|
-
return e.position === t &&
|
|
2195
|
+
for (r = e.input.charCodeAt(++e.position), t = e.position; r !== 0 && !H(r) && !U(r);) r = e.input.charCodeAt(++e.position);
|
|
2196
|
+
return e.position === t && G(e, "name of an alias node must contain at least one character"), n = e.input.slice(t, e.position), z.call(e.anchorMap, n) || G(e, "unidentified alias \"" + n + "\""), e.result = e.anchorMap[n], J(e, !0, -1), !0;
|
|
1894
2197
|
}
|
|
1895
|
-
function
|
|
2198
|
+
function Y(e, t, n, r, i) {
|
|
1896
2199
|
var a, o, s, c = 1, l = !1, u = !1, d, f, p, m, h, g;
|
|
1897
|
-
if (e.listener !== null && e.listener("open", e), e.tag = null, e.anchor = null, e.kind = null, e.result = null, a = o = s =
|
|
1898
|
-
if (s &&= l || i, (c === 1 ||
|
|
2200
|
+
if (e.listener !== null && e.listener("open", e), e.tag = null, e.anchor = null, e.kind = null, e.result = null, a = o = s = wn === n || Cn === n, r && J(e, !0, -1) && (l = !0, e.lineIndent > t ? c = 1 : e.lineIndent === t ? c = 0 : e.lineIndent < t && (c = -1)), c === 1) for (; rr(e) || ir(e);) J(e, !0, -1) ? (l = !0, s = a, e.lineIndent > t ? c = 1 : e.lineIndent === t ? c = 0 : e.lineIndent < t && (c = -1)) : s = !1;
|
|
2201
|
+
if (s &&= l || i, (c === 1 || wn === n) && (h = xn === n || Sn === n ? t : t + 1, g = e.position - e.lineStart, c === 1 ? s && (tr(e, g) || nr(e, g, h)) || $n(e, h) ? u = !0 : (o && er(e, h) || Zn(e, h) || Qn(e, h) ? u = !0 : ar(e) ? (u = !0, (e.tag !== null || e.anchor !== null) && G(e, "alias node should not have any properties")) : Xn(e, h, xn === n) && (u = !0, e.tag === null && (e.tag = "?")), e.anchor !== null && (e.anchorMap[e.anchor] = e.result)) : c === 0 && (u = s && tr(e, g))), e.tag === null) e.anchor !== null && (e.anchorMap[e.anchor] = e.result);
|
|
1899
2202
|
else if (e.tag === "?") {
|
|
1900
|
-
for (e.result !== null && e.kind !== "scalar" &&
|
|
2203
|
+
for (e.result !== null && e.kind !== "scalar" && G(e, "unacceptable node kind for !<?> tag; it should be \"scalar\", not \"" + e.kind + "\""), d = 0, f = e.implicitTypes.length; d < f; d += 1) if (m = e.implicitTypes[d], m.resolve(e.result)) {
|
|
1901
2204
|
e.result = m.construct(e.result), e.tag = m.tag, e.anchor !== null && (e.anchorMap[e.anchor] = e.result);
|
|
1902
2205
|
break;
|
|
1903
2206
|
}
|
|
1904
2207
|
} else if (e.tag !== "!") {
|
|
1905
|
-
if (
|
|
2208
|
+
if (z.call(e.typeMap[e.kind || "fallback"], e.tag)) m = e.typeMap[e.kind || "fallback"][e.tag];
|
|
1906
2209
|
else for (m = null, p = e.typeMap.multi[e.kind || "fallback"], d = 0, f = p.length; d < f; d += 1) if (e.tag.slice(0, p[d].tag.length) === p[d].tag) {
|
|
1907
2210
|
m = p[d];
|
|
1908
2211
|
break;
|
|
1909
2212
|
}
|
|
1910
|
-
m ||
|
|
2213
|
+
m || G(e, "unknown tag !<" + e.tag + ">"), e.result !== null && m.kind !== e.kind && G(e, "unacceptable node kind for !<" + e.tag + "> tag; it should be \"" + m.kind + "\", not \"" + e.kind + "\""), m.resolve(e.result, e.tag) ? (e.result = m.construct(e.result, e.tag), e.anchor !== null && (e.anchorMap[e.anchor] = e.result)) : G(e, "cannot resolve a node with !<" + e.tag + "> explicit tag");
|
|
1911
2214
|
}
|
|
1912
2215
|
return e.listener !== null && e.listener("close", e), e.tag !== null || e.anchor !== null || u;
|
|
1913
2216
|
}
|
|
1914
|
-
function
|
|
2217
|
+
function or(e) {
|
|
1915
2218
|
var t = e.position, n, r, i, a = !1, o;
|
|
1916
|
-
for (e.version = null, e.checkLineBreaks = e.legacy, e.tagMap = Object.create(null), e.anchorMap = Object.create(null); (o = e.input.charCodeAt(e.position)) !== 0 && (
|
|
1917
|
-
for (a = !0, o = e.input.charCodeAt(++e.position), n = e.position; o !== 0 && !
|
|
1918
|
-
for (r = e.input.slice(n, e.position), i = [], r.length < 1 &&
|
|
1919
|
-
for (;
|
|
2219
|
+
for (e.version = null, e.checkLineBreaks = e.legacy, e.tagMap = Object.create(null), e.anchorMap = Object.create(null); (o = e.input.charCodeAt(e.position)) !== 0 && (J(e, !0, -1), o = e.input.charCodeAt(e.position), !(e.lineIndent > 0 || o !== 37));) {
|
|
2220
|
+
for (a = !0, o = e.input.charCodeAt(++e.position), n = e.position; o !== 0 && !H(o);) o = e.input.charCodeAt(++e.position);
|
|
2221
|
+
for (r = e.input.slice(n, e.position), i = [], r.length < 1 && G(e, "directive name must not be less than one character in length"); o !== 0;) {
|
|
2222
|
+
for (; V(o);) o = e.input.charCodeAt(++e.position);
|
|
1920
2223
|
if (o === 35) {
|
|
1921
2224
|
do
|
|
1922
2225
|
o = e.input.charCodeAt(++e.position);
|
|
1923
|
-
while (o !== 0 && !
|
|
2226
|
+
while (o !== 0 && !B(o));
|
|
1924
2227
|
break;
|
|
1925
2228
|
}
|
|
1926
|
-
if (
|
|
1927
|
-
for (n = e.position; o !== 0 && !
|
|
2229
|
+
if (B(o)) break;
|
|
2230
|
+
for (n = e.position; o !== 0 && !H(o);) o = e.input.charCodeAt(++e.position);
|
|
1928
2231
|
i.push(e.input.slice(n, e.position));
|
|
1929
2232
|
}
|
|
1930
|
-
o !== 0 &&
|
|
2233
|
+
o !== 0 && qn(e), z.call(Gn, r) ? Gn[r](e, r, i) : Wn(e, "unknown document directive \"" + r + "\"");
|
|
1931
2234
|
}
|
|
1932
|
-
if (
|
|
1933
|
-
e.input.charCodeAt(e.position) === 46 && (e.position += 3,
|
|
2235
|
+
if (J(e, !0, -1), e.lineIndent === 0 && e.input.charCodeAt(e.position) === 45 && e.input.charCodeAt(e.position + 1) === 45 && e.input.charCodeAt(e.position + 2) === 45 ? (e.position += 3, J(e, !0, -1)) : a && G(e, "directives end mark is expected"), Y(e, e.lineIndent - 1, wn, !1, !0), J(e, !0, -1), e.checkLineBreaks && kn.test(e.input.slice(t, e.position)) && Wn(e, "non-ASCII line breaks are interpreted as content"), e.documents.push(e.result), e.position === e.lineStart && Jn(e)) {
|
|
2236
|
+
e.input.charCodeAt(e.position) === 46 && (e.position += 3, J(e, !0, -1));
|
|
1934
2237
|
return;
|
|
1935
2238
|
}
|
|
1936
|
-
if (e.position < e.length - 1)
|
|
2239
|
+
if (e.position < e.length - 1) G(e, "end of the stream or a document separator is expected");
|
|
1937
2240
|
else return;
|
|
1938
2241
|
}
|
|
1939
|
-
function
|
|
2242
|
+
function sr(e, t) {
|
|
1940
2243
|
e = String(e), t ||= {}, e.length !== 0 && (e.charCodeAt(e.length - 1) !== 10 && e.charCodeAt(e.length - 1) !== 13 && (e += "\n"), e.charCodeAt(0) === 65279 && (e = e.slice(1)));
|
|
1941
|
-
var n = new
|
|
1942
|
-
for (r !== -1 && (n.position = r,
|
|
1943
|
-
for (; n.position < n.length - 1;)
|
|
2244
|
+
var n = new Hn(e, t), r = e.indexOf("\0");
|
|
2245
|
+
for (r !== -1 && (n.position = r, G(n, "null byte is not allowed in input")), n.input += "\0"; n.input.charCodeAt(n.position) === 32;) n.lineIndent += 1, n.position += 1;
|
|
2246
|
+
for (; n.position < n.length - 1;) or(n);
|
|
1944
2247
|
return n.documents;
|
|
1945
2248
|
}
|
|
1946
|
-
function
|
|
2249
|
+
function cr(e, t, n) {
|
|
1947
2250
|
typeof t == "object" && t && n === void 0 && (n = t, t = null);
|
|
1948
|
-
var r =
|
|
2251
|
+
var r = sr(e, n);
|
|
1949
2252
|
if (typeof t != "function") return r;
|
|
1950
2253
|
for (var i = 0, a = r.length; i < a; i += 1) t(r[i]);
|
|
1951
2254
|
}
|
|
1952
|
-
function
|
|
1953
|
-
var n =
|
|
2255
|
+
function lr(e, t) {
|
|
2256
|
+
var n = sr(e, t);
|
|
1954
2257
|
if (n.length !== 0) {
|
|
1955
2258
|
if (n.length === 1) return n[0];
|
|
1956
|
-
throw new
|
|
2259
|
+
throw new L("expected a single document in the stream, but found more");
|
|
1957
2260
|
}
|
|
1958
2261
|
}
|
|
1959
|
-
var
|
|
1960
|
-
loadAll:
|
|
1961
|
-
load:
|
|
1962
|
-
},
|
|
1963
|
-
|
|
1964
|
-
var
|
|
2262
|
+
var ur = {
|
|
2263
|
+
loadAll: cr,
|
|
2264
|
+
load: lr
|
|
2265
|
+
}, dr = Object.prototype.toString, fr = Object.prototype.hasOwnProperty, pr = 65279, mr = 9, hr = 10, gr = 13, _r = 32, vr = 33, yr = 34, br = 35, xr = 37, Sr = 38, Cr = 39, wr = 42, Tr = 44, Er = 45, Dr = 58, Or = 61, kr = 62, Ar = 63, jr = 64, Mr = 91, Nr = 93, Pr = 96, Fr = 123, Ir = 124, Lr = 125, X = {};
|
|
2266
|
+
X[0] = "\\0", X[7] = "\\a", X[8] = "\\b", X[9] = "\\t", X[10] = "\\n", X[11] = "\\v", X[12] = "\\f", X[13] = "\\r", X[27] = "\\e", X[34] = "\\\"", X[92] = "\\\\", X[133] = "\\N", X[160] = "\\_", X[8232] = "\\L", X[8233] = "\\P";
|
|
2267
|
+
var Rr = [
|
|
1965
2268
|
"y",
|
|
1966
2269
|
"Y",
|
|
1967
2270
|
"yes",
|
|
@@ -1978,236 +2281,236 @@ var Cr = [
|
|
|
1978
2281
|
"off",
|
|
1979
2282
|
"Off",
|
|
1980
2283
|
"OFF"
|
|
1981
|
-
],
|
|
1982
|
-
function
|
|
2284
|
+
], zr = /^[-+]?[0-9_]+(?::[0-9_]+)+(?:\.[0-9_]*)?$/;
|
|
2285
|
+
function Br(e, t) {
|
|
1983
2286
|
var n, r, i, a, o, s, c;
|
|
1984
2287
|
if (t === null) return {};
|
|
1985
|
-
for (n = {}, r = Object.keys(t), i = 0, a = r.length; i < a; i += 1) o = r[i], s = String(t[o]), o.slice(0, 2) === "!!" && (o = "tag:yaml.org,2002:" + o.slice(2)), c = e.compiledTypeMap.fallback[o], c &&
|
|
2288
|
+
for (n = {}, r = Object.keys(t), i = 0, a = r.length; i < a; i += 1) o = r[i], s = String(t[o]), o.slice(0, 2) === "!!" && (o = "tag:yaml.org,2002:" + o.slice(2)), c = e.compiledTypeMap.fallback[o], c && fr.call(c.styleAliases, s) && (s = c.styleAliases[s]), n[o] = s;
|
|
1986
2289
|
return n;
|
|
1987
2290
|
}
|
|
1988
|
-
function
|
|
2291
|
+
function Vr(e) {
|
|
1989
2292
|
var t = e.toString(16).toUpperCase(), n, r;
|
|
1990
2293
|
if (e <= 255) n = "x", r = 2;
|
|
1991
2294
|
else if (e <= 65535) n = "u", r = 4;
|
|
1992
2295
|
else if (e <= 4294967295) n = "U", r = 8;
|
|
1993
|
-
else throw new
|
|
1994
|
-
return "\\" + n +
|
|
2296
|
+
else throw new L("code point within a string may not be greater than 0xFFFFFFFF");
|
|
2297
|
+
return "\\" + n + I.repeat("0", r - t.length) + t;
|
|
1995
2298
|
}
|
|
1996
|
-
var
|
|
1997
|
-
function
|
|
1998
|
-
this.schema = e.schema ||
|
|
2299
|
+
var Hr = 1, Ur = 2;
|
|
2300
|
+
function Wr(e) {
|
|
2301
|
+
this.schema = e.schema || bn, this.indent = Math.max(1, e.indent || 2), this.noArrayIndent = e.noArrayIndent || !1, this.skipInvalid = e.skipInvalid || !1, this.flowLevel = I.isNothing(e.flowLevel) ? -1 : e.flowLevel, this.styleMap = Br(this.schema, e.styles || null), this.sortKeys = e.sortKeys || !1, this.lineWidth = e.lineWidth || 80, this.noRefs = e.noRefs || !1, this.noCompatMode = e.noCompatMode || !1, this.condenseFlow = e.condenseFlow || !1, this.quotingType = e.quotingType === "\"" ? Ur : Hr, this.forceQuotes = e.forceQuotes || !1, this.replacer = typeof e.replacer == "function" ? e.replacer : null, this.implicitTypes = this.schema.compiledImplicit, this.explicitTypes = this.schema.compiledExplicit, this.tag = null, this.result = "", this.duplicates = [], this.usedDuplicates = null;
|
|
1999
2302
|
}
|
|
2000
|
-
function
|
|
2001
|
-
for (var n =
|
|
2303
|
+
function Gr(e, t) {
|
|
2304
|
+
for (var n = I.repeat(" ", t), r = 0, i = -1, a = "", o, s = e.length; r < s;) i = e.indexOf("\n", r), i === -1 ? (o = e.slice(r), r = s) : (o = e.slice(r, i + 1), r = i + 1), o.length && o !== "\n" && (a += n), a += o;
|
|
2002
2305
|
return a;
|
|
2003
2306
|
}
|
|
2004
|
-
function
|
|
2005
|
-
return "\n" +
|
|
2307
|
+
function Kr(e, t) {
|
|
2308
|
+
return "\n" + I.repeat(" ", e.indent * t);
|
|
2006
2309
|
}
|
|
2007
|
-
function
|
|
2310
|
+
function qr(e, t) {
|
|
2008
2311
|
var n, r, i;
|
|
2009
2312
|
for (n = 0, r = e.implicitTypes.length; n < r; n += 1) if (i = e.implicitTypes[n], i.resolve(t)) return !0;
|
|
2010
2313
|
return !1;
|
|
2011
2314
|
}
|
|
2012
|
-
function
|
|
2013
|
-
return e ===
|
|
2315
|
+
function Jr(e) {
|
|
2316
|
+
return e === _r || e === mr;
|
|
2014
2317
|
}
|
|
2015
|
-
function
|
|
2016
|
-
return 32 <= e && e <= 126 || 161 <= e && e <= 55295 && e !== 8232 && e !== 8233 || 57344 <= e && e <= 65533 && e !==
|
|
2318
|
+
function Yr(e) {
|
|
2319
|
+
return 32 <= e && e <= 126 || 161 <= e && e <= 55295 && e !== 8232 && e !== 8233 || 57344 <= e && e <= 65533 && e !== pr || 65536 <= e && e <= 1114111;
|
|
2017
2320
|
}
|
|
2018
|
-
function
|
|
2019
|
-
return
|
|
2321
|
+
function Xr(e) {
|
|
2322
|
+
return Yr(e) && e !== pr && e !== gr && e !== hr;
|
|
2020
2323
|
}
|
|
2021
|
-
function
|
|
2022
|
-
var r =
|
|
2023
|
-
return (n ? r : r && e !==
|
|
2324
|
+
function Zr(e, t, n) {
|
|
2325
|
+
var r = Xr(e), i = r && !Jr(e);
|
|
2326
|
+
return (n ? r : r && e !== Tr && e !== Mr && e !== Nr && e !== Fr && e !== Lr) && e !== br && !(t === Dr && !i) || Xr(t) && !Jr(t) && e === br || t === Dr && i;
|
|
2024
2327
|
}
|
|
2025
|
-
function
|
|
2026
|
-
return
|
|
2328
|
+
function Qr(e) {
|
|
2329
|
+
return Yr(e) && e !== pr && !Jr(e) && e !== Er && e !== Ar && e !== Dr && e !== Tr && e !== Mr && e !== Nr && e !== Fr && e !== Lr && e !== br && e !== Sr && e !== wr && e !== vr && e !== Ir && e !== Or && e !== kr && e !== Cr && e !== yr && e !== xr && e !== jr && e !== Pr;
|
|
2027
2330
|
}
|
|
2028
|
-
function
|
|
2029
|
-
return !
|
|
2331
|
+
function $r(e) {
|
|
2332
|
+
return !Jr(e) && e !== Dr;
|
|
2030
2333
|
}
|
|
2031
|
-
function
|
|
2334
|
+
function ei(e, t) {
|
|
2032
2335
|
var n = e.charCodeAt(t), r;
|
|
2033
2336
|
return n >= 55296 && n <= 56319 && t + 1 < e.length && (r = e.charCodeAt(t + 1), r >= 56320 && r <= 57343) ? (n - 55296) * 1024 + r - 56320 + 65536 : n;
|
|
2034
2337
|
}
|
|
2035
|
-
function
|
|
2338
|
+
function ti(e) {
|
|
2036
2339
|
return /^\n* /.test(e);
|
|
2037
2340
|
}
|
|
2038
|
-
var
|
|
2039
|
-
function
|
|
2040
|
-
var c, l = 0, u = null, d = !1, f = !1, p = r !== -1, m = -1, h =
|
|
2341
|
+
var ni = 1, ri = 2, ii = 3, ai = 4, Z = 5;
|
|
2342
|
+
function oi(e, t, n, r, i, a, o, s) {
|
|
2343
|
+
var c, l = 0, u = null, d = !1, f = !1, p = r !== -1, m = -1, h = Qr(ei(e, 0)) && $r(ei(e, e.length - 1));
|
|
2041
2344
|
if (t || o) for (c = 0; c < e.length; l >= 65536 ? c += 2 : c++) {
|
|
2042
|
-
if (l =
|
|
2043
|
-
h &&=
|
|
2345
|
+
if (l = ei(e, c), !Yr(l)) return Z;
|
|
2346
|
+
h &&= Zr(l, u, s), u = l;
|
|
2044
2347
|
}
|
|
2045
2348
|
else {
|
|
2046
2349
|
for (c = 0; c < e.length; l >= 65536 ? c += 2 : c++) {
|
|
2047
|
-
if (l =
|
|
2048
|
-
else if (!
|
|
2049
|
-
h &&=
|
|
2350
|
+
if (l = ei(e, c), l === hr) d = !0, p && (f ||= c - m - 1 > r && e[m + 1] !== " ", m = c);
|
|
2351
|
+
else if (!Yr(l)) return Z;
|
|
2352
|
+
h &&= Zr(l, u, s), u = l;
|
|
2050
2353
|
}
|
|
2051
2354
|
f ||= p && c - m - 1 > r && e[m + 1] !== " ";
|
|
2052
2355
|
}
|
|
2053
|
-
return !d && !f ? h && !o && !i(e) ?
|
|
2356
|
+
return !d && !f ? h && !o && !i(e) ? ni : a === Ur ? Z : ri : n > 9 && ti(e) ? Z : o ? a === Ur ? Z : ri : f ? ai : ii;
|
|
2054
2357
|
}
|
|
2055
|
-
function
|
|
2358
|
+
function si(e, t, n, r, i) {
|
|
2056
2359
|
e.dump = function() {
|
|
2057
|
-
if (t.length === 0) return e.quotingType ===
|
|
2058
|
-
if (!e.noCompatMode && (
|
|
2360
|
+
if (t.length === 0) return e.quotingType === Ur ? "\"\"" : "''";
|
|
2361
|
+
if (!e.noCompatMode && (Rr.indexOf(t) !== -1 || zr.test(t))) return e.quotingType === Ur ? "\"" + t + "\"" : "'" + t + "'";
|
|
2059
2362
|
var a = e.indent * Math.max(1, n), o = e.lineWidth === -1 ? -1 : Math.max(Math.min(e.lineWidth, 40), e.lineWidth - a), s = r || e.flowLevel > -1 && n >= e.flowLevel;
|
|
2060
2363
|
function c(t) {
|
|
2061
|
-
return
|
|
2364
|
+
return qr(e, t);
|
|
2062
2365
|
}
|
|
2063
|
-
switch (
|
|
2064
|
-
case
|
|
2065
|
-
case
|
|
2066
|
-
case
|
|
2067
|
-
case
|
|
2068
|
-
case
|
|
2069
|
-
default: throw new
|
|
2366
|
+
switch (oi(t, s, e.indent, o, c, e.quotingType, e.forceQuotes && !r, i)) {
|
|
2367
|
+
case ni: return t;
|
|
2368
|
+
case ri: return "'" + t.replace(/'/g, "''") + "'";
|
|
2369
|
+
case ii: return "|" + ci(t, e.indent) + li(Gr(t, a));
|
|
2370
|
+
case ai: return ">" + ci(t, e.indent) + li(Gr(ui(t, o), a));
|
|
2371
|
+
case Z: return "\"" + fi(t) + "\"";
|
|
2372
|
+
default: throw new L("impossible error: invalid scalar style");
|
|
2070
2373
|
}
|
|
2071
2374
|
}();
|
|
2072
2375
|
}
|
|
2073
|
-
function
|
|
2074
|
-
var n =
|
|
2376
|
+
function ci(e, t) {
|
|
2377
|
+
var n = ti(e) ? String(t) : "", r = e[e.length - 1] === "\n";
|
|
2075
2378
|
return n + (r && (e[e.length - 2] === "\n" || e === "\n") ? "+" : r ? "" : "-") + "\n";
|
|
2076
2379
|
}
|
|
2077
|
-
function
|
|
2380
|
+
function li(e) {
|
|
2078
2381
|
return e[e.length - 1] === "\n" ? e.slice(0, -1) : e;
|
|
2079
2382
|
}
|
|
2080
|
-
function
|
|
2383
|
+
function ui(e, t) {
|
|
2081
2384
|
for (var n = /(\n+)([^\n]*)/g, r = function() {
|
|
2082
2385
|
var r = e.indexOf("\n");
|
|
2083
|
-
return r = r === -1 ? e.length : r, n.lastIndex = r,
|
|
2386
|
+
return r = r === -1 ? e.length : r, n.lastIndex = r, di(e.slice(0, r), t);
|
|
2084
2387
|
}(), i = e[0] === "\n" || e[0] === " ", a, o; o = n.exec(e);) {
|
|
2085
2388
|
var s = o[1], c = o[2];
|
|
2086
|
-
a = c[0] === " ", r += s + (!i && !a && c !== "" ? "\n" : "") +
|
|
2389
|
+
a = c[0] === " ", r += s + (!i && !a && c !== "" ? "\n" : "") + di(c, t), i = a;
|
|
2087
2390
|
}
|
|
2088
2391
|
return r;
|
|
2089
2392
|
}
|
|
2090
|
-
function
|
|
2393
|
+
function di(e, t) {
|
|
2091
2394
|
if (e === "" || e[0] === " ") return e;
|
|
2092
2395
|
for (var n = / [^ ]/g, r, i = 0, a, o = 0, s = 0, c = ""; r = n.exec(e);) s = r.index, s - i > t && (a = o > i ? o : s, c += "\n" + e.slice(i, a), i = a + 1), o = s;
|
|
2093
2396
|
return c += "\n", e.length - i > t && o > i ? c += e.slice(i, o) + "\n" + e.slice(o + 1) : c += e.slice(i), c.slice(1);
|
|
2094
2397
|
}
|
|
2095
|
-
function
|
|
2096
|
-
for (var t = "", n = 0, r, i = 0; i < e.length; n >= 65536 ? i += 2 : i++) n =
|
|
2398
|
+
function fi(e) {
|
|
2399
|
+
for (var t = "", n = 0, r, i = 0; i < e.length; n >= 65536 ? i += 2 : i++) n = ei(e, i), r = X[n], !r && Yr(n) ? (t += e[i], n >= 65536 && (t += e[i + 1])) : t += r || Vr(n);
|
|
2097
2400
|
return t;
|
|
2098
2401
|
}
|
|
2099
|
-
function
|
|
2402
|
+
function pi(e, t, n) {
|
|
2100
2403
|
var r = "", i = e.tag, a, o, s;
|
|
2101
|
-
for (a = 0, o = n.length; a < o; a += 1) s = n[a], e.replacer && (s = e.replacer.call(n, String(a), s)), (
|
|
2404
|
+
for (a = 0, o = n.length; a < o; a += 1) s = n[a], e.replacer && (s = e.replacer.call(n, String(a), s)), (Q(e, t, s, !1, !1) || s === void 0 && Q(e, t, null, !1, !1)) && (r !== "" && (r += "," + (e.condenseFlow ? "" : " ")), r += e.dump);
|
|
2102
2405
|
e.tag = i, e.dump = "[" + r + "]";
|
|
2103
2406
|
}
|
|
2104
|
-
function
|
|
2407
|
+
function mi(e, t, n, r) {
|
|
2105
2408
|
var i = "", a = e.tag, o, s, c;
|
|
2106
|
-
for (o = 0, s = n.length; o < s; o += 1) c = n[o], e.replacer && (c = e.replacer.call(n, String(o), c)), (
|
|
2409
|
+
for (o = 0, s = n.length; o < s; o += 1) c = n[o], e.replacer && (c = e.replacer.call(n, String(o), c)), (Q(e, t + 1, c, !0, !0, !1, !0) || c === void 0 && Q(e, t + 1, null, !0, !0, !1, !0)) && ((!r || i !== "") && (i += Kr(e, t)), e.dump && hr === e.dump.charCodeAt(0) ? i += "-" : i += "- ", i += e.dump);
|
|
2107
2410
|
e.tag = a, e.dump = i || "[]";
|
|
2108
2411
|
}
|
|
2109
|
-
function
|
|
2412
|
+
function hi(e, t, n) {
|
|
2110
2413
|
var r = "", i = e.tag, a = Object.keys(n), o, s, c, l, u;
|
|
2111
|
-
for (o = 0, s = a.length; o < s; o += 1) u = "", r !== "" && (u += ", "), e.condenseFlow && (u += "\""), c = a[o], l = n[c], e.replacer && (l = e.replacer.call(n, c, l)),
|
|
2414
|
+
for (o = 0, s = a.length; o < s; o += 1) u = "", r !== "" && (u += ", "), e.condenseFlow && (u += "\""), c = a[o], l = n[c], e.replacer && (l = e.replacer.call(n, c, l)), Q(e, t, c, !1, !1) && (e.dump.length > 1024 && (u += "? "), u += e.dump + (e.condenseFlow ? "\"" : "") + ":" + (e.condenseFlow ? "" : " "), Q(e, t, l, !1, !1) && (u += e.dump, r += u));
|
|
2112
2415
|
e.tag = i, e.dump = "{" + r + "}";
|
|
2113
2416
|
}
|
|
2114
|
-
function
|
|
2417
|
+
function gi(e, t, n, r) {
|
|
2115
2418
|
var i = "", a = e.tag, o = Object.keys(n), s, c, l, u, d, f;
|
|
2116
2419
|
if (e.sortKeys === !0) o.sort();
|
|
2117
2420
|
else if (typeof e.sortKeys == "function") o.sort(e.sortKeys);
|
|
2118
|
-
else if (e.sortKeys) throw new
|
|
2119
|
-
for (s = 0, c = o.length; s < c; s += 1) f = "", (!r || i !== "") && (f +=
|
|
2421
|
+
else if (e.sortKeys) throw new L("sortKeys must be a boolean or a function");
|
|
2422
|
+
for (s = 0, c = o.length; s < c; s += 1) f = "", (!r || i !== "") && (f += Kr(e, t)), l = o[s], u = n[l], e.replacer && (u = e.replacer.call(n, l, u)), Q(e, t + 1, l, !0, !0, !0) && (d = e.tag !== null && e.tag !== "?" || e.dump && e.dump.length > 1024, d && (e.dump && hr === e.dump.charCodeAt(0) ? f += "?" : f += "? "), f += e.dump, d && (f += Kr(e, t)), Q(e, t + 1, u, !0, d) && (e.dump && hr === e.dump.charCodeAt(0) ? f += ":" : f += ": ", f += e.dump, i += f));
|
|
2120
2423
|
e.tag = a, e.dump = i || "{}";
|
|
2121
2424
|
}
|
|
2122
|
-
function
|
|
2425
|
+
function _i(e, t, n) {
|
|
2123
2426
|
var r, i = n ? e.explicitTypes : e.implicitTypes, a, o, s, c;
|
|
2124
2427
|
for (a = 0, o = i.length; a < o; a += 1) if (s = i[a], (s.instanceOf || s.predicate) && (!s.instanceOf || typeof t == "object" && t instanceof s.instanceOf) && (!s.predicate || s.predicate(t))) {
|
|
2125
2428
|
if (n ? s.multi && s.representName ? e.tag = s.representName(t) : e.tag = s.tag : e.tag = "?", s.represent) {
|
|
2126
|
-
if (c = e.styleMap[s.tag] || s.defaultStyle,
|
|
2127
|
-
else if (
|
|
2128
|
-
else throw new
|
|
2429
|
+
if (c = e.styleMap[s.tag] || s.defaultStyle, dr.call(s.represent) === "[object Function]") r = s.represent(t, c);
|
|
2430
|
+
else if (fr.call(s.represent, c)) r = s.represent[c](t, c);
|
|
2431
|
+
else throw new L("!<" + s.tag + "> tag resolver accepts not \"" + c + "\" style");
|
|
2129
2432
|
e.dump = r;
|
|
2130
2433
|
}
|
|
2131
2434
|
return !0;
|
|
2132
2435
|
}
|
|
2133
2436
|
return !1;
|
|
2134
2437
|
}
|
|
2135
|
-
function
|
|
2136
|
-
e.tag = null, e.dump = n,
|
|
2137
|
-
var s =
|
|
2438
|
+
function Q(e, t, n, r, i, a, o) {
|
|
2439
|
+
e.tag = null, e.dump = n, _i(e, n, !1) || _i(e, n, !0);
|
|
2440
|
+
var s = dr.call(e.dump), c = r, l;
|
|
2138
2441
|
r &&= e.flowLevel < 0 || e.flowLevel > t;
|
|
2139
2442
|
var u = s === "[object Object]" || s === "[object Array]", d, f;
|
|
2140
2443
|
if (u && (d = e.duplicates.indexOf(n), f = d !== -1), (e.tag !== null && e.tag !== "?" || f || e.indent !== 2 && t > 0) && (i = !1), f && e.usedDuplicates[d]) e.dump = "*ref_" + d;
|
|
2141
2444
|
else {
|
|
2142
|
-
if (u && f && !e.usedDuplicates[d] && (e.usedDuplicates[d] = !0), s === "[object Object]") r && Object.keys(e.dump).length !== 0 ? (
|
|
2143
|
-
else if (s === "[object Array]") r && e.dump.length !== 0 ? (e.noArrayIndent && !o && t > 0 ?
|
|
2144
|
-
else if (s === "[object String]") e.tag !== "?" &&
|
|
2445
|
+
if (u && f && !e.usedDuplicates[d] && (e.usedDuplicates[d] = !0), s === "[object Object]") r && Object.keys(e.dump).length !== 0 ? (gi(e, t, e.dump, i), f && (e.dump = "&ref_" + d + e.dump)) : (hi(e, t, e.dump), f && (e.dump = "&ref_" + d + " " + e.dump));
|
|
2446
|
+
else if (s === "[object Array]") r && e.dump.length !== 0 ? (e.noArrayIndent && !o && t > 0 ? mi(e, t - 1, e.dump, i) : mi(e, t, e.dump, i), f && (e.dump = "&ref_" + d + e.dump)) : (pi(e, t, e.dump), f && (e.dump = "&ref_" + d + " " + e.dump));
|
|
2447
|
+
else if (s === "[object String]") e.tag !== "?" && si(e, e.dump, t, a, c);
|
|
2145
2448
|
else if (s === "[object Undefined]") return !1;
|
|
2146
2449
|
else {
|
|
2147
2450
|
if (e.skipInvalid) return !1;
|
|
2148
|
-
throw new
|
|
2451
|
+
throw new L("unacceptable kind of an object to dump " + s);
|
|
2149
2452
|
}
|
|
2150
2453
|
e.tag !== null && e.tag !== "?" && (l = encodeURI(e.tag[0] === "!" ? e.tag.slice(1) : e.tag).replace(/!/g, "%21"), l = e.tag[0] === "!" ? "!" + l : l.slice(0, 18) === "tag:yaml.org,2002:" ? "!!" + l.slice(18) : "!<" + l + ">", e.dump = l + " " + e.dump);
|
|
2151
2454
|
}
|
|
2152
2455
|
return !0;
|
|
2153
2456
|
}
|
|
2154
|
-
function
|
|
2457
|
+
function vi(e, t) {
|
|
2155
2458
|
var n = [], r = [], i, a;
|
|
2156
|
-
for (
|
|
2459
|
+
for (yi(e, n, r), i = 0, a = r.length; i < a; i += 1) t.duplicates.push(n[r[i]]);
|
|
2157
2460
|
t.usedDuplicates = Array(a);
|
|
2158
2461
|
}
|
|
2159
|
-
function
|
|
2462
|
+
function yi(e, t, n) {
|
|
2160
2463
|
var r, i, a;
|
|
2161
2464
|
if (typeof e == "object" && e) if (i = t.indexOf(e), i !== -1) n.indexOf(i) === -1 && n.push(i);
|
|
2162
|
-
else if (t.push(e), Array.isArray(e)) for (i = 0, a = e.length; i < a; i += 1)
|
|
2163
|
-
else for (r = Object.keys(e), i = 0, a = r.length; i < a; i += 1)
|
|
2465
|
+
else if (t.push(e), Array.isArray(e)) for (i = 0, a = e.length; i < a; i += 1) yi(e[i], t, n);
|
|
2466
|
+
else for (r = Object.keys(e), i = 0, a = r.length; i < a; i += 1) yi(e[r[i]], t, n);
|
|
2164
2467
|
}
|
|
2165
|
-
function
|
|
2468
|
+
function bi(e, t) {
|
|
2166
2469
|
t ||= {};
|
|
2167
|
-
var n = new
|
|
2168
|
-
n.noRefs ||
|
|
2470
|
+
var n = new Wr(t);
|
|
2471
|
+
n.noRefs || vi(e, n);
|
|
2169
2472
|
var r = e;
|
|
2170
|
-
return n.replacer && (r = n.replacer.call({ "": r }, "", r)),
|
|
2473
|
+
return n.replacer && (r = n.replacer.call({ "": r }, "", r)), Q(n, 0, r, !0, !0) ? n.dump + "\n" : "";
|
|
2171
2474
|
}
|
|
2172
|
-
var
|
|
2173
|
-
function
|
|
2475
|
+
var xi = { dump: bi };
|
|
2476
|
+
function Si(e, t) {
|
|
2174
2477
|
return function() {
|
|
2175
2478
|
throw Error("Function yaml." + e + " is removed in js-yaml 4. Use yaml." + t + " instead, which is now safe by default.");
|
|
2176
2479
|
};
|
|
2177
2480
|
}
|
|
2178
|
-
var
|
|
2179
|
-
Type:
|
|
2180
|
-
Schema:
|
|
2181
|
-
FAILSAFE_SCHEMA:
|
|
2182
|
-
JSON_SCHEMA:
|
|
2183
|
-
CORE_SCHEMA:
|
|
2184
|
-
DEFAULT_SCHEMA:
|
|
2185
|
-
load:
|
|
2186
|
-
loadAll:
|
|
2187
|
-
dump:
|
|
2188
|
-
YAMLException:
|
|
2481
|
+
var Ci = {
|
|
2482
|
+
Type: R,
|
|
2483
|
+
Schema: _t,
|
|
2484
|
+
FAILSAFE_SCHEMA: xt,
|
|
2485
|
+
JSON_SCHEMA: Wt,
|
|
2486
|
+
CORE_SCHEMA: Gt,
|
|
2487
|
+
DEFAULT_SCHEMA: bn,
|
|
2488
|
+
load: ur.load,
|
|
2489
|
+
loadAll: ur.loadAll,
|
|
2490
|
+
dump: xi.dump,
|
|
2491
|
+
YAMLException: L,
|
|
2189
2492
|
types: {
|
|
2190
|
-
binary:
|
|
2191
|
-
float:
|
|
2192
|
-
map:
|
|
2193
|
-
null:
|
|
2194
|
-
pairs:
|
|
2195
|
-
set:
|
|
2196
|
-
timestamp:
|
|
2197
|
-
bool:
|
|
2198
|
-
int:
|
|
2199
|
-
merge:
|
|
2200
|
-
omap:
|
|
2201
|
-
seq:
|
|
2202
|
-
str:
|
|
2493
|
+
binary: on,
|
|
2494
|
+
float: Ut,
|
|
2495
|
+
map: bt,
|
|
2496
|
+
null: Tt,
|
|
2497
|
+
pairs: hn,
|
|
2498
|
+
set: yn,
|
|
2499
|
+
timestamp: Zt,
|
|
2500
|
+
bool: kt,
|
|
2501
|
+
int: It,
|
|
2502
|
+
merge: $t,
|
|
2503
|
+
omap: dn,
|
|
2504
|
+
seq: yt,
|
|
2505
|
+
str: vt
|
|
2203
2506
|
},
|
|
2204
|
-
safeLoad:
|
|
2205
|
-
safeLoadAll:
|
|
2206
|
-
safeDump:
|
|
2207
|
-
},
|
|
2208
|
-
let t =
|
|
2507
|
+
safeLoad: Si("safeLoad", "load"),
|
|
2508
|
+
safeLoadAll: Si("safeLoadAll", "loadAll"),
|
|
2509
|
+
safeDump: Si("safeDump", "dump")
|
|
2510
|
+
}, wi = (...e) => e.filter((e, t, n) => !!e && e.trim() !== "" && n.indexOf(e) === t).join(" ").trim(), Ti = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1-$2").toLowerCase(), Ei = (e) => e.replace(/^([A-Z])|[\s-_]+(\w)/g, (e, t, n) => n ? n.toUpperCase() : t.toLowerCase()), Di = (e) => {
|
|
2511
|
+
let t = Ei(e);
|
|
2209
2512
|
return t.charAt(0).toUpperCase() + t.slice(1);
|
|
2210
|
-
},
|
|
2513
|
+
}, Oi = {
|
|
2211
2514
|
xmlns: "http://www.w3.org/2000/svg",
|
|
2212
2515
|
width: 24,
|
|
2213
2516
|
height: 24,
|
|
@@ -2217,135 +2520,58 @@ var ci = {
|
|
|
2217
2520
|
strokeWidth: 2,
|
|
2218
2521
|
strokeLinecap: "round",
|
|
2219
2522
|
strokeLinejoin: "round"
|
|
2220
|
-
},
|
|
2523
|
+
}, ki = (e) => {
|
|
2221
2524
|
for (let t in e) if (t.startsWith("aria-") || t === "role" || t === "title") return !0;
|
|
2222
2525
|
return !1;
|
|
2223
|
-
},
|
|
2224
|
-
let { size: u = 24, strokeWidth: d = 2, absoluteStrokeWidth: f = !1, color: p = "currentColor", className: m = "" } =
|
|
2526
|
+
}, Ai = c({}), ji = () => p(Ai), Mi = u(({ color: e, size: t, strokeWidth: n, absoluteStrokeWidth: r, className: i = "", children: a, iconNode: o, ...s }, c) => {
|
|
2527
|
+
let { size: u = 24, strokeWidth: d = 2, absoluteStrokeWidth: f = !1, color: p = "currentColor", className: m = "" } = ji() ?? {}, h = r ?? f ? Number(n ?? d) * 24 / Number(t ?? u) : n ?? d;
|
|
2225
2528
|
return l("svg", {
|
|
2226
2529
|
ref: c,
|
|
2227
|
-
...
|
|
2228
|
-
width: t ?? u ??
|
|
2229
|
-
height: t ?? u ??
|
|
2530
|
+
...Oi,
|
|
2531
|
+
width: t ?? u ?? Oi.width,
|
|
2532
|
+
height: t ?? u ?? Oi.height,
|
|
2230
2533
|
stroke: e ?? p,
|
|
2231
2534
|
strokeWidth: h,
|
|
2232
|
-
className:
|
|
2233
|
-
...!a && !
|
|
2535
|
+
className: wi("lucide", m, i),
|
|
2536
|
+
...!a && !ki(s) && { "aria-hidden": "true" },
|
|
2234
2537
|
...s
|
|
2235
2538
|
}, [...o.map(([e, t]) => l(e, t)), ...Array.isArray(a) ? a : [a]]);
|
|
2236
|
-
}),
|
|
2237
|
-
let n = u(({ className: n, ...r }, i) => l(
|
|
2539
|
+
}), Ni = (e, t) => {
|
|
2540
|
+
let n = u(({ className: n, ...r }, i) => l(Mi, {
|
|
2238
2541
|
ref: i,
|
|
2239
2542
|
iconNode: t,
|
|
2240
|
-
className:
|
|
2543
|
+
className: wi(`lucide-${Ti(Di(e))}`, `lucide-${e}`, n),
|
|
2241
2544
|
...r
|
|
2242
2545
|
}));
|
|
2243
|
-
return n.displayName =
|
|
2244
|
-
},
|
|
2546
|
+
return n.displayName = Di(e), n;
|
|
2547
|
+
}, Pi = Ni("check", [["path", {
|
|
2245
2548
|
d: "M20 6 9 17l-5-5",
|
|
2246
2549
|
key: "1gmf2c"
|
|
2247
|
-
}]]),
|
|
2550
|
+
}]]), Fi = Ni("minus", [["path", {
|
|
2248
2551
|
d: "M5 12h14",
|
|
2249
2552
|
key: "1ays0h"
|
|
2250
|
-
}]]),
|
|
2553
|
+
}]]), Ii = Ni("plus", [["path", {
|
|
2251
2554
|
d: "M5 12h14",
|
|
2252
2555
|
key: "1ays0h"
|
|
2253
2556
|
}], ["path", {
|
|
2254
2557
|
d: "M12 5v14",
|
|
2255
2558
|
key: "s699le"
|
|
2256
|
-
}]]),
|
|
2257
|
-
$schema: "https://json-schema.org/draft/2020-12/schema",
|
|
2258
|
-
$id: "https://seedfinder.app/jaml.schema.json",
|
|
2259
|
-
title: "JAML — Jimbo's Ante Markup Language",
|
|
2260
|
-
description: "Declarative filter language for Balatro seed searches. A JAML document specifies the criteria a seed must satisfy; the Motely engine compiles and runs it.",
|
|
2261
|
-
version: "17.4.5",
|
|
2262
|
-
type: "object",
|
|
2263
|
-
additionalProperties: !1,
|
|
2264
|
-
properties: {
|
|
2265
|
-
id: { type: "string" },
|
|
2266
|
-
name: { type: "string" },
|
|
2267
|
-
author: { type: "string" },
|
|
2268
|
-
dateCreated: { type: "string" },
|
|
2269
|
-
description: { type: "string" },
|
|
2270
|
-
deck: { $ref: "#/$defs/MotelyDeck" },
|
|
2271
|
-
stake: { $ref: "#/$defs/MotelyStake" },
|
|
2272
|
-
defaults: { $ref: "#/$defs/JamlDefaults" },
|
|
2273
|
-
must: {
|
|
2274
|
-
type: "array",
|
|
2275
|
-
items: { $ref: "#/$defs/JamlClauseUnion" }
|
|
2276
|
-
},
|
|
2277
|
-
should: {
|
|
2278
|
-
type: "array",
|
|
2279
|
-
items: { $ref: "#/$defs/JamlClauseUnion" }
|
|
2280
|
-
},
|
|
2281
|
-
mustNot: {
|
|
2282
|
-
type: "array",
|
|
2283
|
-
items: { $ref: "#/$defs/JamlClauseUnion" }
|
|
2284
|
-
},
|
|
2285
|
-
hashtags: {
|
|
2286
|
-
type: "array",
|
|
2287
|
-
items: { type: "string" }
|
|
2288
|
-
},
|
|
2289
|
-
seeds: {
|
|
2290
|
-
type: "array",
|
|
2291
|
-
items: { type: "string" }
|
|
2292
|
-
}
|
|
2293
|
-
},
|
|
2294
|
-
$defs: /* @__PURE__ */ JSON.parse("{\"JamlDefaults\":{\"type\":\"object\",\"additionalProperties\":false,\"properties\":{\"antes\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"boosterPacks\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"shopItems\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"score\":{\"type\":\"integer\"}}},\"JamlClauseUnion\":{\"type\":\"object\",\"additionalProperties\":false,\"properties\":{\"joker\":{\"oneOf\":[{\"const\":\"any\"},{\"$ref\":\"#/$defs/MotelyJoker\"}]},\"jokers\":{\"type\":\"array\",\"items\":{\"$ref\":\"#/$defs/MotelyJoker\"}},\"commonJoker\":{\"oneOf\":[{\"const\":\"any\"},{\"$ref\":\"#/$defs/MotelyJokerCommon\"}]},\"commonJokers\":{\"type\":\"array\",\"items\":{\"$ref\":\"#/$defs/MotelyJokerCommon\"}},\"uncommonJoker\":{\"oneOf\":[{\"const\":\"any\"},{\"$ref\":\"#/$defs/MotelyJokerUncommon\"}]},\"uncommonJokers\":{\"type\":\"array\",\"items\":{\"$ref\":\"#/$defs/MotelyJokerUncommon\"}},\"rareJoker\":{\"oneOf\":[{\"const\":\"any\"},{\"$ref\":\"#/$defs/MotelyJokerRare\"}]},\"rareJokers\":{\"type\":\"array\",\"items\":{\"$ref\":\"#/$defs/MotelyJokerRare\"}},\"legendaryJoker\":{\"oneOf\":[{\"const\":\"any\"},{\"$ref\":\"#/$defs/MotelyJokerLegendary\"}]},\"legendaryJokers\":{\"type\":\"array\",\"items\":{\"$ref\":\"#/$defs/MotelyJokerLegendary\"}},\"voucher\":{\"$ref\":\"#/$defs/MotelyVoucher\"},\"vouchers\":{\"type\":\"array\",\"items\":{\"$ref\":\"#/$defs/MotelyVoucher\"}},\"tarotCard\":{\"$ref\":\"#/$defs/MotelyTarotCard\"},\"tarotCards\":{\"type\":\"array\",\"items\":{\"$ref\":\"#/$defs/MotelyTarotCard\"}},\"spectralCard\":{\"$ref\":\"#/$defs/MotelySpectralCard\"},\"spectralCards\":{\"type\":\"array\",\"items\":{\"$ref\":\"#/$defs/MotelySpectralCard\"}},\"planetCard\":{\"$ref\":\"#/$defs/MotelyPlanetCard\"},\"boss\":{\"$ref\":\"#/$defs/MotelyBossBlind\"},\"tag\":{\"$ref\":\"#/$defs/MotelyTag\"},\"smallBlindTag\":{\"$ref\":\"#/$defs/MotelyTag\"},\"bigBlindTag\":{\"$ref\":\"#/$defs/MotelyTag\"},\"standardCard\":{\"oneOf\":[{\"type\":\"string\"},{\"$ref\":\"#/$defs/StandardCardConfig\"}]},\"standardCards\":{\"type\":\"array\",\"items\":{\"oneOf\":[{\"type\":\"string\"},{\"$ref\":\"#/$defs/StandardCardConfig\"}]}},\"erraticRank\":{\"type\":\"string\"},\"erraticSuit\":{\"type\":\"string\"},\"erraticCard\":{\"type\":\"string\"},\"startingDraw\":{\"type\":\"string\"},\"event\":{\"$ref\":\"#/$defs/MotelyEventType\"},\"luckyMoney\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"luckyMult\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"misprintMult\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"wheelOfFortune\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"cavendishExtinct\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"grosMichelExtinct\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"spaceLevelup\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"businessPayout\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"bloodstoneTrigger\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"parkingPayout\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"glassDestroy\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"wheelStaysFlipped\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"antes\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"score\":{\"type\":\"integer\"},\"min\":{\"type\":\"integer\"},\"max\":{\"type\":\"integer\"},\"label\":{\"type\":\"string\"},\"edition\":{\"$ref\":\"#/$defs/MotelyItemEdition\"},\"stickers\":{\"type\":\"array\",\"items\":{\"$ref\":\"#/$defs/MotelyJokerSticker\"}},\"seal\":{\"$ref\":\"#/$defs/MotelyItemSeal\"},\"enhancement\":{\"$ref\":\"#/$defs/MotelyItemEnhancement\"},\"rank\":{\"type\":\"string\"},\"suit\":{\"type\":\"string\"},\"rolls\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"soulEditionRolls\":{\"type\":\"integer\"},\"soulCardOnly\":{\"type\":\"boolean\"},\"and\":{\"type\":\"array\",\"items\":{\"$ref\":\"#/$defs/JamlClauseUnion\"}},\"or\":{\"type\":\"array\",\"items\":{\"$ref\":\"#/$defs/JamlClauseUnion\"}},\"clauses\":{\"type\":\"array\",\"items\":{\"$ref\":\"#/$defs/JamlClauseUnion\"}},\"mode\":{\"type\":\"string\"},\"judgement\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"wraith\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"rareTag\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"uncommonTag\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"shopItems\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"boosterPacks\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"minShopItem\":{\"type\":\"integer\"},\"maxShopItem\":{\"type\":\"integer\"},\"sources\":{\"$ref\":\"#/$defs/JamlSources\"}}},\"MotelyJoker\":{\"type\":\"string\",\"enum\":[\"Joker\",\"GreedyJoker\",\"LustyJoker\",\"WrathfulJoker\",\"GluttonousJoker\",\"JollyJoker\",\"ZanyJoker\",\"MadJoker\",\"CrazyJoker\",\"DrollJoker\",\"SlyJoker\",\"WilyJoker\",\"CleverJoker\",\"DeviousJoker\",\"CraftyJoker\",\"HalfJoker\",\"CreditCard\",\"Banner\",\"MysticSummit\",\"EightBall\",\"Misprint\",\"RaisedFist\",\"ChaostheClown\",\"ScaryFace\",\"AbstractJoker\",\"DelayedGratification\",\"GrosMichel\",\"EvenSteven\",\"OddTodd\",\"Scholar\",\"BusinessCard\",\"Supernova\",\"RideTheBus\",\"Egg\",\"Runner\",\"IceCream\",\"Splash\",\"BlueJoker\",\"FacelessJoker\",\"GreenJoker\",\"Superposition\",\"ToDoList\",\"Cavendish\",\"RedCard\",\"SquareJoker\",\"RiffRaff\",\"Photograph\",\"ReservedParking\",\"MailInRebate\",\"Hallucination\",\"FortuneTeller\",\"Juggler\",\"Drunkard\",\"GoldenJoker\",\"Popcorn\",\"WalkieTalkie\",\"SmileyFace\",\"GoldenTicket\",\"Swashbuckler\",\"HangingChad\",\"ShootTheMoon\",\"JokerStencil\",\"FourFingers\",\"Mime\",\"CeremonialDagger\",\"MarbleJoker\",\"LoyaltyCard\",\"Dusk\",\"Fibonacci\",\"SteelJoker\",\"Hack\",\"Pareidolia\",\"SpaceJoker\",\"Burglar\",\"Blackboard\",\"SixthSense\",\"Constellation\",\"Hiker\",\"CardSharp\",\"Madness\",\"Seance\",\"Vampire\",\"Shortcut\",\"Hologram\",\"Cloud9\",\"Rocket\",\"MidasMask\",\"Luchador\",\"GiftCard\",\"TurtleBean\",\"Erosion\",\"ToTheMoon\",\"StoneJoker\",\"LuckyCat\",\"Bull\",\"DietCola\",\"TradingCard\",\"FlashCard\",\"SpareTrousers\",\"Ramen\",\"Seltzer\",\"Castle\",\"MrBones\",\"Acrobat\",\"SockAndBuskin\",\"Troubadour\",\"Certificate\",\"SmearedJoker\",\"Throwback\",\"RoughGem\",\"Bloodstone\",\"Arrowhead\",\"OnyxAgate\",\"GlassJoker\",\"Showman\",\"FlowerPot\",\"MerryAndy\",\"OopsAll6s\",\"TheIdol\",\"SeeingDouble\",\"Matador\",\"Satellite\",\"Cartomancer\",\"Astronomer\",\"Bootstraps\",\"DNA\",\"Vagabond\",\"Baron\",\"Obelisk\",\"BaseballCard\",\"AncientJoker\",\"Campfire\",\"Blueprint\",\"WeeJoker\",\"HitTheRoad\",\"TheDuo\",\"TheTrio\",\"TheFamily\",\"TheOrder\",\"TheTribe\",\"Stuntman\",\"InvisibleJoker\",\"Brainstorm\",\"DriversLicense\",\"BurntJoker\",\"Canio\",\"Triboulet\",\"Yorick\",\"Chicot\",\"Perkeo\"]},\"MotelyJokerCommon\":{\"type\":\"string\",\"enum\":[\"Joker\",\"GreedyJoker\",\"LustyJoker\",\"WrathfulJoker\",\"GluttonousJoker\",\"JollyJoker\",\"ZanyJoker\",\"MadJoker\",\"CrazyJoker\",\"DrollJoker\",\"SlyJoker\",\"WilyJoker\",\"CleverJoker\",\"DeviousJoker\",\"CraftyJoker\",\"HalfJoker\",\"CreditCard\",\"Banner\",\"MysticSummit\",\"EightBall\",\"Misprint\",\"RaisedFist\",\"ChaostheClown\",\"ScaryFace\",\"AbstractJoker\",\"DelayedGratification\",\"GrosMichel\",\"EvenSteven\",\"OddTodd\",\"Scholar\",\"BusinessCard\",\"Supernova\",\"RideTheBus\",\"Egg\",\"Runner\",\"IceCream\",\"Splash\",\"BlueJoker\",\"FacelessJoker\",\"GreenJoker\",\"Superposition\",\"ToDoList\",\"Cavendish\",\"RedCard\",\"SquareJoker\",\"RiffRaff\",\"Photograph\",\"ReservedParking\",\"MailInRebate\",\"Hallucination\",\"FortuneTeller\",\"Juggler\",\"Drunkard\",\"GoldenJoker\",\"Popcorn\",\"WalkieTalkie\",\"SmileyFace\",\"GoldenTicket\",\"Swashbuckler\",\"HangingChad\",\"ShootTheMoon\"]},\"MotelyJokerUncommon\":{\"type\":\"string\",\"enum\":[\"JokerStencil\",\"FourFingers\",\"Mime\",\"CeremonialDagger\",\"MarbleJoker\",\"LoyaltyCard\",\"Dusk\",\"Fibonacci\",\"SteelJoker\",\"Hack\",\"Pareidolia\",\"SpaceJoker\",\"Burglar\",\"Blackboard\",\"SixthSense\",\"Constellation\",\"Hiker\",\"CardSharp\",\"Madness\",\"Seance\",\"Vampire\",\"Shortcut\",\"Hologram\",\"Cloud9\",\"Rocket\",\"MidasMask\",\"Luchador\",\"GiftCard\",\"TurtleBean\",\"Erosion\",\"ToTheMoon\",\"StoneJoker\",\"LuckyCat\",\"Bull\",\"DietCola\",\"TradingCard\",\"FlashCard\",\"SpareTrousers\",\"Ramen\",\"Seltzer\",\"Castle\",\"MrBones\",\"Acrobat\",\"SockAndBuskin\",\"Troubadour\",\"Certificate\",\"SmearedJoker\",\"Throwback\",\"RoughGem\",\"Bloodstone\",\"Arrowhead\",\"OnyxAgate\",\"GlassJoker\",\"Showman\",\"FlowerPot\",\"MerryAndy\",\"OopsAll6s\",\"TheIdol\",\"SeeingDouble\",\"Matador\",\"Satellite\",\"Cartomancer\",\"Astronomer\",\"Bootstraps\"]},\"MotelyJokerRare\":{\"type\":\"string\",\"enum\":[\"DNA\",\"Vagabond\",\"Baron\",\"Obelisk\",\"BaseballCard\",\"AncientJoker\",\"Campfire\",\"Blueprint\",\"WeeJoker\",\"HitTheRoad\",\"TheDuo\",\"TheTrio\",\"TheFamily\",\"TheOrder\",\"TheTribe\",\"Stuntman\",\"InvisibleJoker\",\"Brainstorm\",\"DriversLicense\",\"BurntJoker\"]},\"MotelyJokerLegendary\":{\"type\":\"string\",\"enum\":[\"Canio\",\"Triboulet\",\"Yorick\",\"Chicot\",\"Perkeo\"]},\"MotelyVoucher\":{\"type\":\"string\",\"enum\":[\"Overstock\",\"OverstockPlus\",\"ClearanceSale\",\"Liquidation\",\"Hone\",\"GlowUp\",\"RerollSurplus\",\"RerollGlut\",\"CrystalBall\",\"OmenGlobe\",\"Telescope\",\"Observatory\",\"Grabber\",\"NachoTong\",\"Wasteful\",\"Recyclomancy\",\"TarotMerchant\",\"TarotTycoon\",\"PlanetMerchant\",\"PlanetTycoon\",\"SeedMoney\",\"MoneyTree\",\"Blank\",\"Antimatter\",\"MagicTrick\",\"Illusion\",\"Hieroglyph\",\"Petroglyph\",\"DirectorsCut\",\"Retcon\",\"PaintBrush\",\"Palette\"]},\"MotelyTarotCard\":{\"type\":\"string\",\"enum\":[\"TheFool\",\"TheMagician\",\"TheHighPriestess\",\"TheEmpress\",\"TheEmperor\",\"TheHierophant\",\"TheLovers\",\"TheChariot\",\"Justice\",\"TheHermit\",\"TheWheelOfFortune\",\"Strength\",\"TheHangedMan\",\"Death\",\"Temperance\",\"TheDevil\",\"TheTower\",\"TheStar\",\"TheMoon\",\"TheSun\",\"Judgement\",\"TheWorld\"]},\"MotelySpectralCard\":{\"type\":\"string\",\"enum\":[\"Familiar\",\"Grim\",\"Incantation\",\"Talisman\",\"Aura\",\"Wraith\",\"Sigil\",\"Ouija\",\"Ectoplasm\",\"Immolate\",\"Ankh\",\"DejaVu\",\"Hex\",\"Trance\",\"Medium\",\"Cryptid\",\"TheSoul\",\"BlackHole\"]},\"MotelyPlanetCard\":{\"type\":\"string\",\"enum\":[\"Mercury\",\"Venus\",\"Earth\",\"Mars\",\"Jupiter\",\"Saturn\",\"Uranus\",\"Neptune\",\"Pluto\",\"PlanetX\",\"Ceres\",\"Eris\"]},\"MotelyBossBlind\":{\"type\":\"string\",\"enum\":[\"TheClub\",\"TheGoad\",\"TheHead\",\"TheHook\",\"TheManacle\",\"ThePillar\",\"ThePsychic\",\"TheWindow\",\"TheArm\",\"TheFish\",\"TheFlint\",\"TheHouse\",\"TheMark\",\"TheMouth\",\"TheNeedle\",\"TheWall\",\"TheWater\",\"TheWheel\",\"TheEye\",\"TheTooth\",\"ThePlant\",\"TheSerpent\",\"TheOx\",\"AmberAcorn\",\"CeruleanBell\",\"CrimsonHeart\",\"VerdantLeaf\",\"VioletVessel\"]},\"MotelyTag\":{\"type\":\"string\",\"enum\":[\"UncommonTag\",\"RareTag\",\"NegativeTag\",\"FoilTag\",\"HolographicTag\",\"PolychromeTag\",\"InvestmentTag\",\"VoucherTag\",\"BossTag\",\"StandardTag\",\"CharmTag\",\"MeteorTag\",\"BuffoonTag\",\"HandyTag\",\"GarbageTag\",\"EtherealTag\",\"CouponTag\",\"DoubleTag\",\"JuggleTag\",\"D6Tag\",\"TopupTag\",\"SpeedTag\",\"OrbitalTag\",\"EconomyTag\"]},\"StandardCardConfig\":{\"type\":\"object\",\"additionalProperties\":false,\"properties\":{\"rank\":{\"type\":\"string\"},\"suit\":{\"type\":\"string\"},\"seal\":{\"$ref\":\"#/$defs/MotelyItemSeal\"},\"enhancement\":{\"$ref\":\"#/$defs/MotelyItemEnhancement\"},\"edition\":{\"$ref\":\"#/$defs/MotelyItemEdition\"},\"sources\":{\"$ref\":\"#/$defs/JamlSources\"}}},\"MotelyItemSeal\":{\"type\":\"string\",\"enum\":[\"None\",\"Gold\",\"Red\",\"Blue\",\"Purple\"]},\"MotelyItemEnhancement\":{\"type\":\"string\",\"enum\":[\"None\",\"Bonus\",\"Mult\",\"Wild\",\"Glass\",\"Steel\",\"Stone\",\"Gold\",\"Lucky\"]},\"MotelyItemEdition\":{\"type\":\"string\",\"enum\":[\"None\",\"Foil\",\"Holographic\",\"Polychrome\",\"Negative\"]},\"JamlSources\":{\"type\":\"object\",\"additionalProperties\":false,\"properties\":{\"shopItems\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"boosterPacks\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"minShopItem\":{\"type\":\"integer\"},\"maxShopItem\":{\"type\":\"integer\"},\"tags\":{\"type\":\"boolean\"},\"requireMega\":{\"type\":\"boolean\"},\"charmTag\":{\"type\":\"boolean\"},\"etherealTag\":{\"type\":\"boolean\"},\"judgement\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"rareTag\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"uncommonTag\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"wraith\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"soulCard\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"arcanaPacks\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"spectralPacks\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"riffRaff\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"purpleSealOrEightBall\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"emperor\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"sixthSense\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"seance\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"certificate\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"incantation\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"familiar\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"grim\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"deckDraw\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"uncommonShopJokers\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"rareShopJokers\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"commonShopJokers\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}},\"allShopJokers\":{\"type\":\"array\",\"items\":{\"type\":\"integer\"}}}},\"MotelyEventType\":{\"type\":\"string\",\"enum\":[\"LuckyMoney\",\"LuckyMult\",\"MisprintMult\",\"WheelOfFortune\",\"CavendishExtinct\",\"GrosMichelExtinct\",\"SpaceLevelup\",\"BusinessPayout\",\"BloodstoneTrigger\",\"ParkingPayout\",\"GlassDestroy\",\"WheelStaysFlipped\"]},\"MotelyJokerSticker\":{\"type\":\"string\",\"enum\":[\"None\",\"Eternal\",\"Perishable\",\"Rental\"]},\"MotelyDeck\":{\"type\":\"string\",\"enum\":[\"Red\",\"Blue\",\"Yellow\",\"Green\",\"Black\",\"Magic\",\"Nebula\",\"Ghost\",\"Abandoned\",\"Checkered\",\"Zodiac\",\"Painted\",\"Anaglyph\",\"Plasma\",\"Erratic\"]},\"MotelyStake\":{\"type\":\"string\",\"enum\":[\"White\",\"Red\",\"Green\",\"Black\",\"Blue\",\"Purple\",\"Orange\",\"Gold\"]}}")
|
|
2295
|
-
}, Ci = Si.definitions?.clause?.properties ?? {};
|
|
2296
|
-
Si.version;
|
|
2297
|
-
var wi = [
|
|
2298
|
-
"id",
|
|
2299
|
-
"name",
|
|
2300
|
-
"description",
|
|
2301
|
-
"author",
|
|
2302
|
-
"dateCreated",
|
|
2303
|
-
"deck",
|
|
2304
|
-
"stake",
|
|
2305
|
-
"seeds",
|
|
2306
|
-
"hashtags",
|
|
2307
|
-
"aesthetics",
|
|
2308
|
-
"defaults"
|
|
2309
|
-
], Ti = [
|
|
2310
|
-
"must",
|
|
2311
|
-
"should",
|
|
2312
|
-
"mustNot"
|
|
2313
|
-
], Ei = Ci.type?.enum ?? [], Di = Object.keys(Ci), Oi = (() => {
|
|
2314
|
-
let e = Ci.sources?.properties;
|
|
2315
|
-
return e ? Object.keys(e) : ["shopItems", "boosterPacks"];
|
|
2316
|
-
})();
|
|
2317
|
-
function Q(e) {
|
|
2318
|
-
let t = Si.properties?.[e];
|
|
2319
|
-
if (t?.enum) return t.enum;
|
|
2320
|
-
if (t?.items?.enum) return t.items.enum;
|
|
2321
|
-
let n = Ci[e];
|
|
2322
|
-
return n?.enum ? n.enum : n?.items?.enum ? n.items.enum : null;
|
|
2323
|
-
}
|
|
2324
|
-
Q("deck"), Q("stake"), Q("edition"), Q("seal"), Q("enhancement"), Q("rank"), Q("suit"), Q("stickers"), [
|
|
2325
|
-
...Ti,
|
|
2326
|
-
...wi,
|
|
2327
|
-
...Ei,
|
|
2328
|
-
...Di,
|
|
2329
|
-
...Oi
|
|
2330
|
-
];
|
|
2331
|
-
//#endregion
|
|
2332
|
-
//#region src/lib/jaml/jamlData.ts
|
|
2333
|
-
var ki = [...Ei], Ai = [
|
|
2559
|
+
}]]), Li = [.../* @__PURE__ */ "joker.jokers.commonJoker.commonJokers.uncommonJoker.uncommonJokers.rareJoker.rareJokers.legendaryJoker.legendaryJokers.voucher.vouchers.tarotCard.tarotCards.spectralCard.spectralCards.planetCard.boss.tag.smallBlindTag.bigBlindTag.standardCard.standardCards.erraticRank.erraticSuit.erraticCard.startingDraw.event.luckyMoney.luckyMult.misprintMult.wheelOfFortune.cavendishExtinct.grosMichelExtinct.spaceLevelup.businessPayout.bloodstoneTrigger.parkingPayout.glassDestroy.wheelStaysFlipped.and.or.clauses".split(".")], Ri = [
|
|
2334
2560
|
"antes",
|
|
2335
2561
|
"tags",
|
|
2336
2562
|
"labels"
|
|
2337
|
-
],
|
|
2563
|
+
], zi = [
|
|
2338
2564
|
"must",
|
|
2339
2565
|
"should",
|
|
2340
2566
|
"mustNot",
|
|
2341
2567
|
"any",
|
|
2342
2568
|
"Any",
|
|
2343
|
-
...
|
|
2344
|
-
...
|
|
2345
|
-
],
|
|
2569
|
+
...Li,
|
|
2570
|
+
...Ri
|
|
2571
|
+
], Bi = class {
|
|
2346
2572
|
static getCompletions(e) {
|
|
2347
2573
|
let t = e.toLowerCase();
|
|
2348
|
-
return
|
|
2574
|
+
return zi.filter((e) => e.toLowerCase().includes(t)).map((e) => ({
|
|
2349
2575
|
text: e,
|
|
2350
2576
|
displayText: e,
|
|
2351
2577
|
type: "keyword"
|
|
@@ -2363,14 +2589,14 @@ var ki = [...Ei], Ai = [
|
|
|
2363
2589
|
gold: "#efb82d",
|
|
2364
2590
|
editorBg: "#0f1416",
|
|
2365
2591
|
editorBgAlt: "#1c2629"
|
|
2366
|
-
},
|
|
2592
|
+
}, Vi = "# My JAML Filter\nname: My Filter\ndeck: Red\nstake: White\n\nmust:\n - joker: Blueprint\n edition: Negative\n antes: [1, 2, 3]\n\nshould:\n - soulJoker: Any\n score: 5\n", Hi = [
|
|
2367
2593
|
"name",
|
|
2368
2594
|
"author",
|
|
2369
2595
|
"description",
|
|
2370
2596
|
"deck",
|
|
2371
2597
|
"stake",
|
|
2372
2598
|
"label"
|
|
2373
|
-
],
|
|
2599
|
+
], Ui = [
|
|
2374
2600
|
"joker",
|
|
2375
2601
|
"soulJoker",
|
|
2376
2602
|
"voucher",
|
|
@@ -2382,7 +2608,7 @@ var ki = [...Ei], Ai = [
|
|
|
2382
2608
|
"boss",
|
|
2383
2609
|
"event"
|
|
2384
2610
|
];
|
|
2385
|
-
function
|
|
2611
|
+
function Wi({ suggestions: e, selectedIndex: t, onSelect: n, onHover: r }) {
|
|
2386
2612
|
return e.length === 0 ? /* @__PURE__ */ b("div", {
|
|
2387
2613
|
className: "p-2 text-xs text-white/40 italic",
|
|
2388
2614
|
children: "No suggestions..."
|
|
@@ -2406,7 +2632,7 @@ function Ii({ suggestions: e, selectedIndex: t, onSelect: n, onHover: r }) {
|
|
|
2406
2632
|
})
|
|
2407
2633
|
});
|
|
2408
2634
|
}
|
|
2409
|
-
function
|
|
2635
|
+
function Gi({ values: e, onToggle: t, color: n }) {
|
|
2410
2636
|
let [r, i] = v(!1), a = new Set(e.map((e) => parseInt(e, 10)).filter((e) => !isNaN(e)));
|
|
2411
2637
|
return r ? /* @__PURE__ */ x("div", {
|
|
2412
2638
|
className: "flex flex-row items-center",
|
|
@@ -2429,7 +2655,7 @@ function Li({ values: e, onToggle: t, color: n }) {
|
|
|
2429
2655
|
}), /* @__PURE__ */ b("div", {
|
|
2430
2656
|
onClick: () => i(!1),
|
|
2431
2657
|
className: "jaml-block jaml-antes-confirm",
|
|
2432
|
-
children: /* @__PURE__ */ b(
|
|
2658
|
+
children: /* @__PURE__ */ b(Pi, {
|
|
2433
2659
|
size: 16,
|
|
2434
2660
|
strokeWidth: 3
|
|
2435
2661
|
})
|
|
@@ -2453,7 +2679,7 @@ function Li({ values: e, onToggle: t, color: n }) {
|
|
|
2453
2679
|
})()
|
|
2454
2680
|
});
|
|
2455
2681
|
}
|
|
2456
|
-
function
|
|
2682
|
+
function Ki(e, t) {
|
|
2457
2683
|
let [n, r] = v(null);
|
|
2458
2684
|
return m(() => {
|
|
2459
2685
|
if (!t || !e.current) {
|
|
@@ -2474,7 +2700,7 @@ function Ri(e, t) {
|
|
|
2474
2700
|
};
|
|
2475
2701
|
}, [t, e]), n;
|
|
2476
2702
|
}
|
|
2477
|
-
function
|
|
2703
|
+
function qi({ initialJaml: e, onJamlChange: t, className: n }) {
|
|
2478
2704
|
let [r, i] = v([]), [a, o] = v(null), [s, c] = v(null), [l, u] = v(null), d = _(null), p = f((e) => {
|
|
2479
2705
|
let t = e.split("\n"), n;
|
|
2480
2706
|
return t.map((e, t) => {
|
|
@@ -2483,9 +2709,9 @@ function zi({ initialJaml: e, onJamlChange: t, className: n }) {
|
|
|
2483
2709
|
let e = i.indexOf(":"), t = i.slice(o ? 2 : 0, e).trim(), n = i.slice(e + 1).trim();
|
|
2484
2710
|
s = t, c = n || void 0, c && c.startsWith("[") && c.endsWith("]") && (l = !0, u = c.slice(1, -1).split(",").map((e) => e.trim()).filter((e) => e));
|
|
2485
2711
|
}
|
|
2486
|
-
r === 0 && !o && (n = void 0), o && s &&
|
|
2712
|
+
r === 0 && !o && (n = void 0), o && s && Ui.includes(s) && (n = s);
|
|
2487
2713
|
let d = "complete", f = !1;
|
|
2488
|
-
return s && (
|
|
2714
|
+
return s && (Hi.includes(s) ? d = "metadata" : Ui.includes(s) ? d = c ? "complete" : "required-incomplete" : !c && s !== "must" && s !== "should" && s !== "mustNot" && (d = "optional-incomplete"), c && c.startsWith("~") && c.endsWith("~") && (f = !0, d = "invalid")), {
|
|
2489
2715
|
id: `line-${t}`,
|
|
2490
2716
|
raw: e,
|
|
2491
2717
|
indent: r,
|
|
@@ -2504,7 +2730,7 @@ function zi({ initialJaml: e, onJamlChange: t, className: n }) {
|
|
|
2504
2730
|
}, []), m = f((e) => e.map((e) => e.raw).join("\n"), []), [h, y] = v(e);
|
|
2505
2731
|
if (e !== h) {
|
|
2506
2732
|
y(e);
|
|
2507
|
-
let t = e ||
|
|
2733
|
+
let t = e || Vi;
|
|
2508
2734
|
(r.length === 0 || m(r) !== t) && i(p(t));
|
|
2509
2735
|
}
|
|
2510
2736
|
let S = f((e, n, a) => {
|
|
@@ -2524,7 +2750,7 @@ function zi({ initialJaml: e, onJamlChange: t, className: n }) {
|
|
|
2524
2750
|
i(o);
|
|
2525
2751
|
let s = m(o);
|
|
2526
2752
|
if (t) try {
|
|
2527
|
-
t(s,
|
|
2753
|
+
t(s, Ci.load(s), !0);
|
|
2528
2754
|
} catch {
|
|
2529
2755
|
t(s, null, !1);
|
|
2530
2756
|
}
|
|
@@ -2548,7 +2774,7 @@ function zi({ initialJaml: e, onJamlChange: t, className: n }) {
|
|
|
2548
2774
|
i(o);
|
|
2549
2775
|
let s = m(o);
|
|
2550
2776
|
if (t) try {
|
|
2551
|
-
t(s,
|
|
2777
|
+
t(s, Ci.load(s), !0);
|
|
2552
2778
|
} catch {
|
|
2553
2779
|
t(s, null, !1);
|
|
2554
2780
|
}
|
|
@@ -2556,7 +2782,7 @@ function zi({ initialJaml: e, onJamlChange: t, className: n }) {
|
|
|
2556
2782
|
r,
|
|
2557
2783
|
m,
|
|
2558
2784
|
t
|
|
2559
|
-
]),
|
|
2785
|
+
]), w = f((e, n) => {
|
|
2560
2786
|
let a = r.map((t) => {
|
|
2561
2787
|
if (t.id !== e) return t;
|
|
2562
2788
|
let r = [...t.arrayValues || [], n], i = `[${r.join(", ")}]`, a = `${" ".repeat(t.indent)}${t.isArrayItem ? "- " : ""}${t.key}: ${i}`;
|
|
@@ -2571,7 +2797,7 @@ function zi({ initialJaml: e, onJamlChange: t, className: n }) {
|
|
|
2571
2797
|
i(a);
|
|
2572
2798
|
let o = m(a);
|
|
2573
2799
|
if (t) try {
|
|
2574
|
-
t(o,
|
|
2800
|
+
t(o, Ci.load(o), !0);
|
|
2575
2801
|
} catch {
|
|
2576
2802
|
t(o, null, !1);
|
|
2577
2803
|
}
|
|
@@ -2579,7 +2805,7 @@ function zi({ initialJaml: e, onJamlChange: t, className: n }) {
|
|
|
2579
2805
|
r,
|
|
2580
2806
|
m,
|
|
2581
2807
|
t
|
|
2582
|
-
]),
|
|
2808
|
+
]), T = f((e, n) => {
|
|
2583
2809
|
let a = r.map((t) => {
|
|
2584
2810
|
if (t.id !== e || !t.arrayValues) return t;
|
|
2585
2811
|
let r = t.arrayValues.filter((e, t) => t !== n), i = r.length > 0 ? `[${r.join(", ")}]` : "", a = `${" ".repeat(t.indent)}${t.isArrayItem ? "- " : ""}${t.key}: ${i}`;
|
|
@@ -2594,7 +2820,7 @@ function zi({ initialJaml: e, onJamlChange: t, className: n }) {
|
|
|
2594
2820
|
i(a);
|
|
2595
2821
|
let o = m(a);
|
|
2596
2822
|
if (t) try {
|
|
2597
|
-
t(o,
|
|
2823
|
+
t(o, Ci.load(o), !0);
|
|
2598
2824
|
} catch {
|
|
2599
2825
|
t(o, null, !1);
|
|
2600
2826
|
}
|
|
@@ -2602,7 +2828,7 @@ function zi({ initialJaml: e, onJamlChange: t, className: n }) {
|
|
|
2602
2828
|
r,
|
|
2603
2829
|
m,
|
|
2604
2830
|
t
|
|
2605
|
-
]),
|
|
2831
|
+
]), E = f((e) => {
|
|
2606
2832
|
let n = r.filter((t) => t.id !== e).map((e, t) => ({
|
|
2607
2833
|
...e,
|
|
2608
2834
|
lineNumber: t,
|
|
@@ -2611,7 +2837,7 @@ function zi({ initialJaml: e, onJamlChange: t, className: n }) {
|
|
|
2611
2837
|
i(n);
|
|
2612
2838
|
let a = m(n);
|
|
2613
2839
|
if (t) try {
|
|
2614
|
-
t(a,
|
|
2840
|
+
t(a, Ci.load(a), !0);
|
|
2615
2841
|
} catch {
|
|
2616
2842
|
t(a, null, !1);
|
|
2617
2843
|
}
|
|
@@ -2619,7 +2845,7 @@ function zi({ initialJaml: e, onJamlChange: t, className: n }) {
|
|
|
2619
2845
|
r,
|
|
2620
2846
|
m,
|
|
2621
2847
|
t
|
|
2622
|
-
]),
|
|
2848
|
+
]), D = g(() => {
|
|
2623
2849
|
let e = {};
|
|
2624
2850
|
for (let t of r) t.key && (e[t.indent] = Math.min(Math.max(e[t.indent] || 0, t.key.length), 12));
|
|
2625
2851
|
return e;
|
|
@@ -2630,9 +2856,9 @@ function zi({ initialJaml: e, onJamlChange: t, className: n }) {
|
|
|
2630
2856
|
tabIndex: 0,
|
|
2631
2857
|
children: [/* @__PURE__ */ b("div", {
|
|
2632
2858
|
className: "flex flex-col gap-0.5",
|
|
2633
|
-
children: r.map((e) => /* @__PURE__ */ b(
|
|
2859
|
+
children: r.map((e) => /* @__PURE__ */ b(Ji, {
|
|
2634
2860
|
line: e,
|
|
2635
|
-
keyWidth:
|
|
2861
|
+
keyWidth: D[e.indent] || 8,
|
|
2636
2862
|
isEditing: a === e.id,
|
|
2637
2863
|
editingPart: a === e.id ? s : null,
|
|
2638
2864
|
editingArrayIndex: a === e.id ? l : null,
|
|
@@ -2644,9 +2870,9 @@ function zi({ initialJaml: e, onJamlChange: t, className: n }) {
|
|
|
2644
2870
|
},
|
|
2645
2871
|
onChange: (t, n) => S(e.id, t, n),
|
|
2646
2872
|
onArrayItemChange: (t, n) => C(e.id, t, n),
|
|
2647
|
-
onArrayItemAdd: (t) =>
|
|
2648
|
-
onArrayItemRemove: (t) =>
|
|
2649
|
-
onDelete: () =>
|
|
2873
|
+
onArrayItemAdd: (t) => w(e.id, t),
|
|
2874
|
+
onArrayItemRemove: (t) => T(e.id, t),
|
|
2875
|
+
onDelete: () => E(e.id)
|
|
2650
2876
|
}, e.id))
|
|
2651
2877
|
}), /* @__PURE__ */ x("div", {
|
|
2652
2878
|
className: "mt-4 p-2 bg-black/40 rounded border border-white/5 flex flex-wrap gap-4 text-[12px] text-white/50 font-mono",
|
|
@@ -2675,28 +2901,28 @@ function zi({ initialJaml: e, onJamlChange: t, className: n }) {
|
|
|
2675
2901
|
})]
|
|
2676
2902
|
});
|
|
2677
2903
|
}
|
|
2678
|
-
function
|
|
2679
|
-
let [f, p] = v(0), [h, y] = v(""), [
|
|
2904
|
+
function Ji({ line: e, keyWidth: t, isEditing: n, editingPart: r, editingArrayIndex: i, onStartEdit: a, onEndEdit: o, onChange: s, onArrayItemChange: c, onArrayItemAdd: l, onArrayItemRemove: u, onDelete: d }) {
|
|
2905
|
+
let [f, p] = v(0), [h, y] = v(""), [S, C] = v(""), [T, E] = v({
|
|
2680
2906
|
isEditing: n,
|
|
2681
2907
|
editingPart: r,
|
|
2682
2908
|
editingArrayIndex: i,
|
|
2683
2909
|
lineRaw: e.raw
|
|
2684
2910
|
});
|
|
2685
|
-
(n !==
|
|
2911
|
+
(n !== T.isEditing || r !== T.editingPart || i !== T.editingArrayIndex || e.raw !== T.lineRaw) && (E({
|
|
2686
2912
|
isEditing: n,
|
|
2687
2913
|
editingPart: r,
|
|
2688
2914
|
editingArrayIndex: i,
|
|
2689
2915
|
lineRaw: e.raw
|
|
2690
2916
|
}), n && y(r === "key" ? e.key || "" : r === "value" ? (e.value || "").replace(/^~|~$/g, "") : r === "arrayItem" && i !== null && e.arrayValues?.[i] || ""));
|
|
2691
|
-
let
|
|
2917
|
+
let D = g(() => !n || !r ? "" : r === "value" && e.key ? `${e.key}: ${h}` : r === "key" ? h : e.raw, [
|
|
2692
2918
|
n,
|
|
2693
2919
|
r,
|
|
2694
2920
|
h,
|
|
2695
2921
|
e.raw,
|
|
2696
2922
|
e.key
|
|
2697
|
-
]),
|
|
2698
|
-
|
|
2699
|
-
let
|
|
2923
|
+
]), O = g(() => D ? Bi.getCompletions(D).slice(0, 10) : [], [D]);
|
|
2924
|
+
D !== S && (C(D), p(0));
|
|
2925
|
+
let k = _(null), A = _(null), j = Ki(A, n && O.length > 0), M = () => {
|
|
2700
2926
|
switch (e.validationState) {
|
|
2701
2927
|
case "required-incomplete": return $.red;
|
|
2702
2928
|
case "optional-incomplete": return $.blue;
|
|
@@ -2705,7 +2931,7 @@ function Bi({ line: e, keyWidth: t, isEditing: n, editingPart: r, editingArrayIn
|
|
|
2705
2931
|
case "metadata": return $.purple;
|
|
2706
2932
|
default: return "#888";
|
|
2707
2933
|
}
|
|
2708
|
-
},
|
|
2934
|
+
}, ee = () => {
|
|
2709
2935
|
switch (e.validationState) {
|
|
2710
2936
|
case "required-incomplete": return $.red;
|
|
2711
2937
|
case "optional-incomplete": return $.blue;
|
|
@@ -2716,14 +2942,14 @@ function Bi({ line: e, keyWidth: t, isEditing: n, editingPart: r, editingArrayIn
|
|
|
2716
2942
|
}
|
|
2717
2943
|
};
|
|
2718
2944
|
m(() => {
|
|
2719
|
-
n &&
|
|
2945
|
+
n && k.current && k.current.focus();
|
|
2720
2946
|
}, [n]);
|
|
2721
|
-
let
|
|
2947
|
+
let te = (t) => {
|
|
2722
2948
|
if (t.key === "Enter") {
|
|
2723
2949
|
t.preventDefault();
|
|
2724
|
-
let n =
|
|
2950
|
+
let n = O.length > 0 && f >= 0 ? O[f].text : h;
|
|
2725
2951
|
r === "key" ? s("key", n) : r === "value" ? s("value", n) : r === "arrayItem" && (i >= (e.arrayValues?.length || 0) ? l(n) : c(i, n)), o();
|
|
2726
|
-
} else t.key === "ArrowDown" ? (t.preventDefault(), p(Math.min(f + 1,
|
|
2952
|
+
} else t.key === "ArrowDown" ? (t.preventDefault(), p(Math.min(f + 1, O.length - 1))) : t.key === "ArrowUp" ? (t.preventDefault(), p(Math.max(f - 1, 0))) : t.key === "Escape" ? o() : t.key === "Backspace" && h === "" && r === "arrayItem" && (u(i), o());
|
|
2727
2953
|
};
|
|
2728
2954
|
if (e.isComment) return /* @__PURE__ */ b("div", {
|
|
2729
2955
|
className: "pl-8 text-stone-400 italic text-xs py-0.5",
|
|
@@ -2735,10 +2961,10 @@ function Bi({ line: e, keyWidth: t, isEditing: n, editingPart: r, editingArrayIn
|
|
|
2735
2961
|
style: { "--jaml-color": e.key === "must" ? $.red : $.blue },
|
|
2736
2962
|
children: e.raw
|
|
2737
2963
|
});
|
|
2738
|
-
let
|
|
2739
|
-
"--popover-top": `${
|
|
2740
|
-
"--popover-left": `${
|
|
2741
|
-
"--popover-transform":
|
|
2964
|
+
let ne = " ".repeat(e.indent), re = e.isArrayItem ? "- " : "", ie = j ? {
|
|
2965
|
+
"--popover-top": `${j.top}px`,
|
|
2966
|
+
"--popover-left": `${j.left}px`,
|
|
2967
|
+
"--popover-transform": j.position === "top" ? "translateY(-100%)" : "none"
|
|
2742
2968
|
} : {};
|
|
2743
2969
|
return /* @__PURE__ */ x("div", {
|
|
2744
2970
|
className: "relative flex items-center py-0.5 group",
|
|
@@ -2748,43 +2974,43 @@ function Bi({ line: e, keyWidth: t, isEditing: n, editingPart: r, editingArrayIn
|
|
|
2748
2974
|
onClick: (e) => {
|
|
2749
2975
|
e.stopPropagation(), d();
|
|
2750
2976
|
},
|
|
2751
|
-
children: /* @__PURE__ */ b(
|
|
2977
|
+
children: /* @__PURE__ */ b(Fi, {
|
|
2752
2978
|
size: 12,
|
|
2753
2979
|
className: "text-orange-500 hover:bg-orange-100 rounded"
|
|
2754
2980
|
})
|
|
2755
2981
|
}),
|
|
2756
2982
|
/* @__PURE__ */ x("span", {
|
|
2757
2983
|
className: "whitespace-pre text-stone-400",
|
|
2758
|
-
children: [
|
|
2984
|
+
children: [ne, re]
|
|
2759
2985
|
}),
|
|
2760
2986
|
e.key && /* @__PURE__ */ x("div", {
|
|
2761
2987
|
className: "relative",
|
|
2762
2988
|
children: [/* @__PURE__ */ b("div", {
|
|
2763
|
-
ref: r === "key" ?
|
|
2989
|
+
ref: r === "key" ? A : null,
|
|
2764
2990
|
onClick: (e) => {
|
|
2765
2991
|
e.stopPropagation(), a("key");
|
|
2766
2992
|
},
|
|
2767
2993
|
className: "jaml-block jaml-block--start",
|
|
2768
2994
|
style: {
|
|
2769
2995
|
"--jaml-min-w": `${t}ch`,
|
|
2770
|
-
"--jaml-color": n && r === "key" ?
|
|
2771
|
-
"--jaml-bg": n && r === "key" ? `${
|
|
2996
|
+
"--jaml-color": n && r === "key" ? ee() : M(),
|
|
2997
|
+
"--jaml-bg": n && r === "key" ? `${ee()}15` : "transparent"
|
|
2772
2998
|
},
|
|
2773
2999
|
children: n && r === "key" ? /* @__PURE__ */ b("input", {
|
|
2774
|
-
ref:
|
|
3000
|
+
ref: k,
|
|
2775
3001
|
title: "Edit key",
|
|
2776
3002
|
value: h,
|
|
2777
3003
|
onChange: (e) => y(e.target.value),
|
|
2778
|
-
onKeyDown:
|
|
3004
|
+
onKeyDown: te,
|
|
2779
3005
|
onBlur: () => setTimeout(o, 200),
|
|
2780
3006
|
className: "jaml-inline-input",
|
|
2781
|
-
style: { "--jaml-color":
|
|
3007
|
+
style: { "--jaml-color": ee() }
|
|
2782
3008
|
}) : e.key
|
|
2783
|
-
}), n && r === "key" &&
|
|
3009
|
+
}), n && r === "key" && O.length > 0 && j && w(/* @__PURE__ */ b("div", {
|
|
2784
3010
|
className: "jaml-suggestion-popover",
|
|
2785
3011
|
style: ie,
|
|
2786
|
-
children: /* @__PURE__ */ b(
|
|
2787
|
-
suggestions:
|
|
3012
|
+
children: /* @__PURE__ */ b(Wi, {
|
|
3013
|
+
suggestions: O,
|
|
2788
3014
|
selectedIndex: f,
|
|
2789
3015
|
onHover: p,
|
|
2790
3016
|
onSelect: (e) => {
|
|
@@ -2797,13 +3023,13 @@ function Bi({ line: e, keyWidth: t, isEditing: n, editingPart: r, editingArrayIn
|
|
|
2797
3023
|
className: "text-stone-400 mr-1",
|
|
2798
3024
|
children: ":"
|
|
2799
3025
|
}),
|
|
2800
|
-
e.key && (e.isArrayValue && e.arrayValues ? e.key === "antes" ? /* @__PURE__ */ b(
|
|
3026
|
+
e.key && (e.isArrayValue && e.arrayValues ? e.key === "antes" ? /* @__PURE__ */ b(Gi, {
|
|
2801
3027
|
values: e.arrayValues,
|
|
2802
3028
|
onToggle: (t) => {
|
|
2803
3029
|
let n = e.arrayValues.indexOf(t);
|
|
2804
3030
|
n >= 0 ? u(n) : l(t);
|
|
2805
3031
|
},
|
|
2806
|
-
color:
|
|
3032
|
+
color: ee()
|
|
2807
3033
|
}) : /* @__PURE__ */ x("div", {
|
|
2808
3034
|
className: "flex gap-0.5 items-center",
|
|
2809
3035
|
children: [e.arrayValues.map((e, t) => /* @__PURE__ */ b("div", {
|
|
@@ -2813,16 +3039,16 @@ function Bi({ line: e, keyWidth: t, isEditing: n, editingPart: r, editingArrayIn
|
|
|
2813
3039
|
className: "jaml-block",
|
|
2814
3040
|
style: {
|
|
2815
3041
|
"--jaml-min-w": "24px",
|
|
2816
|
-
"--jaml-bg": `${
|
|
2817
|
-
"--jaml-border": `1px solid ${
|
|
2818
|
-
"--jaml-color":
|
|
3042
|
+
"--jaml-bg": `${M()}15`,
|
|
3043
|
+
"--jaml-border": `1px solid ${M()}40`,
|
|
3044
|
+
"--jaml-color": M()
|
|
2819
3045
|
},
|
|
2820
3046
|
children: n && r === "arrayItem" && i === t ? /* @__PURE__ */ b("input", {
|
|
2821
|
-
ref:
|
|
3047
|
+
ref: k,
|
|
2822
3048
|
title: "Edit array item",
|
|
2823
3049
|
value: h,
|
|
2824
3050
|
onChange: (e) => y(e.target.value),
|
|
2825
|
-
onKeyDown:
|
|
3051
|
+
onKeyDown: te,
|
|
2826
3052
|
onBlur: () => setTimeout(o, 200),
|
|
2827
3053
|
className: "bg-transparent w-[3ch] text-center outline-none"
|
|
2828
3054
|
}) : e
|
|
@@ -2837,41 +3063,41 @@ function Bi({ line: e, keyWidth: t, isEditing: n, editingPart: r, editingArrayIn
|
|
|
2837
3063
|
"--jaml-border": `1px solid ${$.green}40`,
|
|
2838
3064
|
"--jaml-color": $.green
|
|
2839
3065
|
},
|
|
2840
|
-
children: /* @__PURE__ */ b(
|
|
3066
|
+
children: /* @__PURE__ */ b(Ii, { size: 12 })
|
|
2841
3067
|
})]
|
|
2842
3068
|
}) : /* @__PURE__ */ x("div", {
|
|
2843
3069
|
className: "relative",
|
|
2844
3070
|
children: [/* @__PURE__ */ b("div", {
|
|
2845
|
-
ref: r === "value" ?
|
|
3071
|
+
ref: r === "value" ? A : null,
|
|
2846
3072
|
onClick: (e) => {
|
|
2847
3073
|
e.stopPropagation(), a("value");
|
|
2848
3074
|
},
|
|
2849
3075
|
className: "jaml-block",
|
|
2850
3076
|
style: {
|
|
2851
3077
|
"--jaml-min-w": e.value ? void 0 : "60px",
|
|
2852
|
-
"--jaml-color": e.isInvalidValue ? $.red : e.value ?
|
|
2853
|
-
"--jaml-bg": e.isInvalidValue ? `${$.red}15` : e.value ? `${
|
|
2854
|
-
"--jaml-border": `1px solid ${e.isInvalidValue ? `${$.red}60` : e.value ? `${
|
|
3078
|
+
"--jaml-color": e.isInvalidValue ? $.red : e.value ? M() : $.red,
|
|
3079
|
+
"--jaml-bg": e.isInvalidValue ? `${$.red}15` : e.value ? `${M()}10` : `${$.red}08`,
|
|
3080
|
+
"--jaml-border": `1px solid ${e.isInvalidValue ? `${$.red}60` : e.value ? `${M()}40` : `${$.red}40`}`,
|
|
2855
3081
|
"--jaml-text-decoration": e.isInvalidValue ? "line-through" : "none"
|
|
2856
3082
|
},
|
|
2857
3083
|
children: n && r === "value" ? /* @__PURE__ */ b("input", {
|
|
2858
|
-
ref:
|
|
3084
|
+
ref: k,
|
|
2859
3085
|
title: "Edit value",
|
|
2860
3086
|
value: h,
|
|
2861
3087
|
onChange: (e) => y(e.target.value),
|
|
2862
|
-
onKeyDown:
|
|
3088
|
+
onKeyDown: te,
|
|
2863
3089
|
onBlur: () => setTimeout(o, 200),
|
|
2864
3090
|
className: "jaml-inline-input jaml-inline-input--sized",
|
|
2865
3091
|
style: {
|
|
2866
|
-
"--jaml-color":
|
|
3092
|
+
"--jaml-color": M(),
|
|
2867
3093
|
"--jaml-input-w": `${Math.max(h.length, 4)}ch`
|
|
2868
3094
|
}
|
|
2869
3095
|
}) : e.isInvalidValue ? e.value?.replace(/~/g, "") : e.value || "???"
|
|
2870
|
-
}), n && r === "value" &&
|
|
3096
|
+
}), n && r === "value" && O.length > 0 && j && w(/* @__PURE__ */ b("div", {
|
|
2871
3097
|
className: "jaml-suggestion-popover",
|
|
2872
3098
|
style: ie,
|
|
2873
|
-
children: /* @__PURE__ */ b(
|
|
2874
|
-
suggestions:
|
|
3099
|
+
children: /* @__PURE__ */ b(Wi, {
|
|
3100
|
+
suggestions: O,
|
|
2875
3101
|
selectedIndex: f,
|
|
2876
3102
|
onHover: p,
|
|
2877
3103
|
onSelect: (e) => {
|
|
@@ -2884,52 +3110,8 @@ function Bi({ line: e, keyWidth: t, isEditing: n, editingPart: r, editingArrayIn
|
|
|
2884
3110
|
});
|
|
2885
3111
|
}
|
|
2886
3112
|
//#endregion
|
|
2887
|
-
//#region src/ui/JimboIconButton.tsx
|
|
2888
|
-
var Vi = e;
|
|
2889
|
-
function Hi({ onClick: e, title: t, "aria-label": n, disabled: r = !1, size: i = "md", children: a }) {
|
|
2890
|
-
let [o, s] = v(!1), c = i === "sm" ? 26 : 30;
|
|
2891
|
-
return /* @__PURE__ */ b("button", {
|
|
2892
|
-
"aria-label": n ?? t,
|
|
2893
|
-
disabled: r,
|
|
2894
|
-
onClick: () => !r && e?.(),
|
|
2895
|
-
onMouseEnter: () => s(!0),
|
|
2896
|
-
onMouseLeave: () => s(!1),
|
|
2897
|
-
style: {
|
|
2898
|
-
width: c,
|
|
2899
|
-
height: c,
|
|
2900
|
-
display: "inline-flex",
|
|
2901
|
-
alignItems: "center",
|
|
2902
|
-
justifyContent: "center",
|
|
2903
|
-
background: o && !r ? Vi.DARK_GREY : Vi.DARKEST,
|
|
2904
|
-
color: Vi.WHITE,
|
|
2905
|
-
border: `1px solid ${Vi.PANEL_EDGE}`,
|
|
2906
|
-
borderRadius: 4,
|
|
2907
|
-
cursor: r ? "not-allowed" : "pointer",
|
|
2908
|
-
opacity: r ? .55 : 1,
|
|
2909
|
-
padding: 0,
|
|
2910
|
-
fontSize: 14,
|
|
2911
|
-
lineHeight: 1,
|
|
2912
|
-
transition: "background 80ms ease"
|
|
2913
|
-
},
|
|
2914
|
-
title: t,
|
|
2915
|
-
type: "button",
|
|
2916
|
-
children: a
|
|
2917
|
-
});
|
|
2918
|
-
}
|
|
2919
|
-
//#endregion
|
|
2920
|
-
//#region src/ui/JimboTextInput.tsx
|
|
2921
|
-
var Ui = s.forwardRef(function({ className: e = "", invalid: t = !1, "aria-invalid": n, ...r }, i) {
|
|
2922
|
-
return /* @__PURE__ */ b("input", {
|
|
2923
|
-
ref: i,
|
|
2924
|
-
className: `j-text-input ${e}`.trim(),
|
|
2925
|
-
"aria-invalid": n ?? t,
|
|
2926
|
-
"data-invalid": t,
|
|
2927
|
-
...r
|
|
2928
|
-
});
|
|
2929
|
-
});
|
|
2930
|
-
//#endregion
|
|
2931
3113
|
//#region src/ui/JimboInputModal.tsx
|
|
2932
|
-
function
|
|
3114
|
+
function Yi({ open: e, title: t, message: n, placeholder: r, initialValue: i = "", confirmLabel: a = "Confirm", cancelLabel: o = "Cancel", validate: s, onConfirm: c, onCancel: l }) {
|
|
2933
3115
|
let [u, d] = v(i), [f, p] = v(null), h = _(null), [g, y] = v(e);
|
|
2934
3116
|
e !== g && (y(e), e && (d(i), p(null))), m(() => {
|
|
2935
3117
|
if (e) {
|
|
@@ -2945,18 +3127,18 @@ function Wi({ open: e, title: t, message: n, placeholder: r, initialValue: i = "
|
|
|
2945
3127
|
}
|
|
2946
3128
|
c(u);
|
|
2947
3129
|
}
|
|
2948
|
-
return /* @__PURE__ */ x(
|
|
3130
|
+
return /* @__PURE__ */ x(ue, {
|
|
2949
3131
|
onClose: l,
|
|
2950
3132
|
open: e,
|
|
2951
3133
|
title: t,
|
|
2952
3134
|
children: [
|
|
2953
|
-
n && /* @__PURE__ */ b(
|
|
3135
|
+
n && /* @__PURE__ */ b(N, {
|
|
2954
3136
|
size: "sm",
|
|
2955
3137
|
className: "j-input-modal__message",
|
|
2956
3138
|
tone: "grey",
|
|
2957
3139
|
children: n
|
|
2958
3140
|
}),
|
|
2959
|
-
/* @__PURE__ */ b(
|
|
3141
|
+
/* @__PURE__ */ b(oe, {
|
|
2960
3142
|
invalid: !!f,
|
|
2961
3143
|
onChange: (e) => {
|
|
2962
3144
|
d(e.target.value), f && p(null);
|
|
@@ -2969,7 +3151,7 @@ function Wi({ open: e, title: t, message: n, placeholder: r, initialValue: i = "
|
|
|
2969
3151
|
type: "text",
|
|
2970
3152
|
value: u
|
|
2971
3153
|
}),
|
|
2972
|
-
f && /* @__PURE__ */ b(
|
|
3154
|
+
f && /* @__PURE__ */ b(N, {
|
|
2973
3155
|
size: "sm",
|
|
2974
3156
|
className: "j-input-modal__error",
|
|
2975
3157
|
tone: "red",
|
|
@@ -2977,12 +3159,12 @@ function Wi({ open: e, title: t, message: n, placeholder: r, initialValue: i = "
|
|
|
2977
3159
|
}),
|
|
2978
3160
|
/* @__PURE__ */ x("div", {
|
|
2979
3161
|
className: "j-input-modal__actions",
|
|
2980
|
-
children: [/* @__PURE__ */ b(
|
|
3162
|
+
children: [/* @__PURE__ */ b(P, {
|
|
2981
3163
|
onClick: l,
|
|
2982
3164
|
size: "sm",
|
|
2983
3165
|
tone: "red",
|
|
2984
3166
|
children: o
|
|
2985
|
-
}), /* @__PURE__ */ b(
|
|
3167
|
+
}), /* @__PURE__ */ b(P, {
|
|
2986
3168
|
onClick: S,
|
|
2987
3169
|
size: "sm",
|
|
2988
3170
|
tone: "blue",
|
|
@@ -2993,167 +3175,133 @@ function Wi({ open: e, title: t, message: n, placeholder: r, initialValue: i = "
|
|
|
2993
3175
|
});
|
|
2994
3176
|
}
|
|
2995
3177
|
//#endregion
|
|
2996
|
-
//#region src/ui/
|
|
2997
|
-
|
|
2998
|
-
return /* @__PURE__ */
|
|
2999
|
-
|
|
3000
|
-
|
|
3001
|
-
|
|
3002
|
-
|
|
3003
|
-
|
|
3004
|
-
|
|
3005
|
-
tone: "grey",
|
|
3006
|
-
children: e
|
|
3007
|
-
})
|
|
3008
|
-
}) : null, /* @__PURE__ */ x("div", {
|
|
3009
|
-
className: "j-panel-spinner__row",
|
|
3010
|
-
children: [
|
|
3011
|
-
/* @__PURE__ */ b(N, {
|
|
3012
|
-
tone: "red",
|
|
3013
|
-
size: "lg",
|
|
3014
|
-
className: "j-panel-spinner__arrow j-panel-spinner__arrow--left",
|
|
3015
|
-
onClick: s,
|
|
3016
|
-
disabled: l,
|
|
3017
|
-
"aria-label": "Previous",
|
|
3018
|
-
children: "<"
|
|
3019
|
-
}),
|
|
3020
|
-
/* @__PURE__ */ x("div", {
|
|
3021
|
-
className: "j-panel-spinner__panel",
|
|
3022
|
-
children: [
|
|
3023
|
-
r ? /* @__PURE__ */ b("div", {
|
|
3024
|
-
className: "j-panel-spinner__media",
|
|
3025
|
-
children: r
|
|
3026
|
-
}) : null,
|
|
3027
|
-
/* @__PURE__ */ b("div", {
|
|
3028
|
-
className: "j-panel-spinner__title",
|
|
3029
|
-
children: /* @__PURE__ */ b(j, {
|
|
3030
|
-
size: "md",
|
|
3031
|
-
tone: "white",
|
|
3032
|
-
children: t
|
|
3033
|
-
})
|
|
3034
|
-
}),
|
|
3035
|
-
i ? /* @__PURE__ */ b("div", {
|
|
3036
|
-
className: "j-panel-spinner__meta",
|
|
3037
|
-
children: i
|
|
3038
|
-
}) : null,
|
|
3039
|
-
n ? /* @__PURE__ */ b("div", {
|
|
3040
|
-
className: "j-panel-spinner__description",
|
|
3041
|
-
children: /* @__PURE__ */ b(j, {
|
|
3042
|
-
size: "micro",
|
|
3043
|
-
tone: "grey",
|
|
3044
|
-
children: n
|
|
3045
|
-
})
|
|
3046
|
-
}) : null
|
|
3047
|
-
]
|
|
3048
|
-
}),
|
|
3049
|
-
/* @__PURE__ */ b(N, {
|
|
3050
|
-
tone: "red",
|
|
3051
|
-
size: "lg",
|
|
3052
|
-
className: "j-panel-spinner__arrow j-panel-spinner__arrow--right",
|
|
3053
|
-
onClick: c,
|
|
3054
|
-
disabled: u,
|
|
3055
|
-
"aria-label": "Next",
|
|
3056
|
-
children: ">"
|
|
3057
|
-
})
|
|
3058
|
-
]
|
|
3059
|
-
})]
|
|
3178
|
+
//#region src/ui/JimboListItem.tsx
|
|
3179
|
+
var Xi = s.forwardRef(function({ active: e = !1, className: t = "", children: n, ...r }, i) {
|
|
3180
|
+
return /* @__PURE__ */ b("button", {
|
|
3181
|
+
ref: i,
|
|
3182
|
+
type: "button",
|
|
3183
|
+
className: `j-list-item ${t}`.trim(),
|
|
3184
|
+
"data-active": e,
|
|
3185
|
+
...r,
|
|
3186
|
+
children: n
|
|
3060
3187
|
});
|
|
3061
|
-
}
|
|
3188
|
+
});
|
|
3062
3189
|
//#endregion
|
|
3063
3190
|
//#region src/ui/JimboSelect.tsx
|
|
3064
|
-
|
|
3065
|
-
|
|
3066
|
-
|
|
3067
|
-
|
|
3068
|
-
|
|
3069
|
-
|
|
3070
|
-
|
|
3071
|
-
|
|
3072
|
-
|
|
3073
|
-
|
|
3074
|
-
|
|
3075
|
-
|
|
3076
|
-
|
|
3077
|
-
|
|
3078
|
-
|
|
3079
|
-
|
|
3080
|
-
|
|
3081
|
-
fontFamily: "m6x11plus, monospace",
|
|
3082
|
-
cursor: i ? "not-allowed" : "pointer",
|
|
3083
|
-
opacity: i ? .55 : 1,
|
|
3084
|
-
appearance: "none",
|
|
3085
|
-
backgroundImage: "linear-gradient(45deg, transparent 50%, " + Ki.GOLD_TEXT + " 50%), linear-gradient(135deg, " + Ki.GOLD_TEXT + " 50%, transparent 50%)",
|
|
3086
|
-
backgroundPosition: "calc(100% - 12px) 50%, calc(100% - 7px) 50%",
|
|
3087
|
-
backgroundSize: "5px 5px, 5px 5px",
|
|
3088
|
-
backgroundRepeat: "no-repeat",
|
|
3089
|
-
paddingRight: 22,
|
|
3090
|
-
...s
|
|
3091
|
-
},
|
|
3092
|
-
value: e,
|
|
3093
|
-
children: [r !== void 0 && /* @__PURE__ */ b("option", {
|
|
3094
|
-
disabled: !0,
|
|
3095
|
-
value: "",
|
|
3096
|
-
children: r
|
|
3097
|
-
}), l.map((e) => /* @__PURE__ */ b("option", {
|
|
3098
|
-
disabled: e.disabled,
|
|
3099
|
-
value: e.value,
|
|
3100
|
-
children: e.label ?? e.value
|
|
3101
|
-
}, e.value))]
|
|
3191
|
+
function Zi({ value: e, options: t, onChange: n, disabled: r = !1, label: i, "aria-label": a, style: o }) {
|
|
3192
|
+
let s = (t.length === 0 ? [] : typeof t[0] == "string" ? t.map((e) => ({ value: e })) : t).filter((e) => !e.disabled), c = Math.max(0, s.findIndex((t) => t.value === e)), l = s[c] ?? s[0];
|
|
3193
|
+
if (!l) return null;
|
|
3194
|
+
function u(e) {
|
|
3195
|
+
r || s.length === 0 || n(s[(c + e + s.length) % s.length].value);
|
|
3196
|
+
}
|
|
3197
|
+
return /* @__PURE__ */ b("div", {
|
|
3198
|
+
style: o,
|
|
3199
|
+
"aria-label": a,
|
|
3200
|
+
children: /* @__PURE__ */ b(xe, {
|
|
3201
|
+
label: i,
|
|
3202
|
+
value: l.label ?? l.value,
|
|
3203
|
+
onPrev: () => u(-1),
|
|
3204
|
+
onNext: () => u(1),
|
|
3205
|
+
canPrev: !r && s.length > 1,
|
|
3206
|
+
canNext: !r && s.length > 1
|
|
3207
|
+
})
|
|
3102
3208
|
});
|
|
3103
3209
|
}
|
|
3104
3210
|
//#endregion
|
|
3105
3211
|
//#region src/ui/JimboStepper.tsx
|
|
3106
|
-
function
|
|
3107
|
-
|
|
3108
|
-
|
|
3109
|
-
|
|
3110
|
-
|
|
3111
|
-
|
|
3112
|
-
|
|
3113
|
-
|
|
3114
|
-
|
|
3115
|
-
|
|
3116
|
-
|
|
3117
|
-
|
|
3118
|
-
|
|
3119
|
-
|
|
3120
|
-
|
|
3121
|
-
|
|
3122
|
-
|
|
3123
|
-
|
|
3124
|
-
|
|
3125
|
-
|
|
3126
|
-
|
|
3127
|
-
|
|
3128
|
-
|
|
3129
|
-
|
|
3130
|
-
|
|
3131
|
-
|
|
3132
|
-
|
|
3133
|
-
|
|
3134
|
-
|
|
3135
|
-
|
|
3136
|
-
|
|
3137
|
-
|
|
3138
|
-
|
|
3139
|
-
|
|
3140
|
-
|
|
3141
|
-
|
|
3142
|
-
|
|
3143
|
-
|
|
3144
|
-
|
|
3212
|
+
function Qi({ count: e, index: t, onIndexChange: n, ariaLabel: r = "Page indicator", className: i = "", style: a }) {
|
|
3213
|
+
if (e <= 1) return null;
|
|
3214
|
+
let o = !!n;
|
|
3215
|
+
return /* @__PURE__ */ b("div", {
|
|
3216
|
+
className: `j-stepper ${i}`,
|
|
3217
|
+
role: "tablist",
|
|
3218
|
+
"aria-label": r,
|
|
3219
|
+
style: a,
|
|
3220
|
+
children: Array.from({ length: e }).map((r, i) => {
|
|
3221
|
+
let a = i === t, s = /* @__PURE__ */ b("span", {
|
|
3222
|
+
className: "j-stepper__dot",
|
|
3223
|
+
"data-active": a,
|
|
3224
|
+
"aria-hidden": !0
|
|
3225
|
+
});
|
|
3226
|
+
return o ? /* @__PURE__ */ b("button", {
|
|
3227
|
+
type: "button",
|
|
3228
|
+
className: "j-stepper__hit",
|
|
3229
|
+
role: "tab",
|
|
3230
|
+
"aria-selected": a,
|
|
3231
|
+
"aria-label": `Page ${i + 1} of ${e}`,
|
|
3232
|
+
onClick: () => n?.(i),
|
|
3233
|
+
children: s
|
|
3234
|
+
}, i) : /* @__PURE__ */ b("span", {
|
|
3235
|
+
role: "tab",
|
|
3236
|
+
"aria-selected": a,
|
|
3237
|
+
children: s
|
|
3238
|
+
}, i);
|
|
3239
|
+
})
|
|
3240
|
+
});
|
|
3241
|
+
}
|
|
3242
|
+
//#endregion
|
|
3243
|
+
//#region src/ui/JimboValueBadge.tsx
|
|
3244
|
+
function $i({ value: e, onChange: t, min: n = 0, max: r = 100, step: i = 1, unit: a, readOnly: o = !1, className: s = "", style: c }) {
|
|
3245
|
+
let [l, u] = v(!1), [d, f] = v(String(e)), p = _(null);
|
|
3246
|
+
m(() => {
|
|
3247
|
+
l && (p.current?.focus(), p.current?.select());
|
|
3248
|
+
}, [l]);
|
|
3249
|
+
function h() {
|
|
3250
|
+
f(String(e)), u(!0);
|
|
3251
|
+
}
|
|
3252
|
+
function g() {
|
|
3253
|
+
let e = Number(d);
|
|
3254
|
+
if (Number.isFinite(e)) {
|
|
3255
|
+
let a = Math.min(r, Math.max(n, e)), o = i > 0 ? Math.round(a / i) * i : a;
|
|
3256
|
+
t?.(o);
|
|
3257
|
+
}
|
|
3258
|
+
u(!1);
|
|
3259
|
+
}
|
|
3260
|
+
function y() {
|
|
3261
|
+
f(String(e)), u(!1);
|
|
3262
|
+
}
|
|
3263
|
+
let x = !o && !!t, S = a ? `${Math.round(e)}${a}` : String(Math.round(e));
|
|
3264
|
+
return l ? /* @__PURE__ */ b("div", {
|
|
3265
|
+
className: `j-value-badge j-value-badge--editing ${s}`,
|
|
3266
|
+
style: c,
|
|
3267
|
+
children: /* @__PURE__ */ b("input", {
|
|
3268
|
+
ref: p,
|
|
3269
|
+
className: "j-value-badge__input",
|
|
3270
|
+
type: "number",
|
|
3271
|
+
min: n,
|
|
3272
|
+
max: r,
|
|
3273
|
+
step: i,
|
|
3274
|
+
value: d,
|
|
3275
|
+
onChange: (e) => f(e.currentTarget.value),
|
|
3276
|
+
onBlur: g,
|
|
3277
|
+
onKeyDown: (e) => {
|
|
3278
|
+
e.key === "Enter" ? g() : e.key === "Escape" && y();
|
|
3279
|
+
}
|
|
3280
|
+
})
|
|
3281
|
+
}) : /* @__PURE__ */ b("button", {
|
|
3282
|
+
type: "button",
|
|
3283
|
+
className: `j-value-badge ${x ? "" : "j-value-badge--static"} ${s}`,
|
|
3284
|
+
style: c,
|
|
3285
|
+
onClick: x ? h : void 0,
|
|
3286
|
+
disabled: !x,
|
|
3287
|
+
tabIndex: x ? 0 : -1,
|
|
3288
|
+
children: /* @__PURE__ */ b(N, {
|
|
3289
|
+
size: "xs",
|
|
3290
|
+
tone: "white",
|
|
3291
|
+
children: S
|
|
3292
|
+
})
|
|
3145
3293
|
});
|
|
3146
3294
|
}
|
|
3147
3295
|
//#endregion
|
|
3148
3296
|
//#region src/ui/JimboSlider.tsx
|
|
3149
|
-
function
|
|
3297
|
+
function ea({ value: e, min: t = 0, max: n = 100, step: r = 1, label: i, onChange: a, className: o = "", id: c }) {
|
|
3150
3298
|
let l = n === t ? 0 : (e - t) / (n - t) * 100, u = s.useId(), d = c ?? u;
|
|
3151
3299
|
return /* @__PURE__ */ x("div", {
|
|
3152
3300
|
className: `j-slider-wrap ${o}`,
|
|
3153
3301
|
children: [i && /* @__PURE__ */ b("label", {
|
|
3154
3302
|
htmlFor: d,
|
|
3155
3303
|
className: "j-slider__label",
|
|
3156
|
-
children: /* @__PURE__ */ b(
|
|
3304
|
+
children: /* @__PURE__ */ b(N, {
|
|
3157
3305
|
size: "sm",
|
|
3158
3306
|
tone: "white",
|
|
3159
3307
|
children: i
|
|
@@ -3180,11 +3328,14 @@ function Yi({ value: e, min: t = 0, max: n = 100, step: r = 1, label: i, onChang
|
|
|
3180
3328
|
onChange: (e) => a?.(Number(e.currentTarget.value))
|
|
3181
3329
|
}),
|
|
3182
3330
|
/* @__PURE__ */ b("div", {
|
|
3183
|
-
className: "j-
|
|
3184
|
-
|
|
3185
|
-
|
|
3186
|
-
|
|
3187
|
-
|
|
3331
|
+
className: "j-slider__thumb",
|
|
3332
|
+
style: { left: `${l}%` },
|
|
3333
|
+
children: /* @__PURE__ */ b($i, {
|
|
3334
|
+
value: e,
|
|
3335
|
+
min: t,
|
|
3336
|
+
max: n,
|
|
3337
|
+
step: r,
|
|
3338
|
+
onChange: a
|
|
3188
3339
|
})
|
|
3189
3340
|
})
|
|
3190
3341
|
]
|
|
@@ -3193,19 +3344,19 @@ function Yi({ value: e, min: t = 0, max: n = 100, step: r = 1, label: i, onChang
|
|
|
3193
3344
|
}
|
|
3194
3345
|
//#endregion
|
|
3195
3346
|
//#region src/ui/JimboDualChip.tsx
|
|
3196
|
-
function
|
|
3347
|
+
function ta({ left: e, right: t, className: n = "" }) {
|
|
3197
3348
|
return /* @__PURE__ */ x("div", {
|
|
3198
3349
|
className: `j-dual-chip ${n}`,
|
|
3199
3350
|
children: [/* @__PURE__ */ b("div", {
|
|
3200
3351
|
className: `j-dual-chip__half j-dual-chip__half--left j-dual-chip__half--${e.tone}`,
|
|
3201
|
-
children: /* @__PURE__ */ b(
|
|
3352
|
+
children: /* @__PURE__ */ b(N, {
|
|
3202
3353
|
size: "md",
|
|
3203
3354
|
tone: e.tone === "gold" ? "default" : "white",
|
|
3204
3355
|
children: e.value
|
|
3205
3356
|
})
|
|
3206
3357
|
}), /* @__PURE__ */ b("div", {
|
|
3207
3358
|
className: `j-dual-chip__half j-dual-chip__half--${t.tone}`,
|
|
3208
|
-
children: /* @__PURE__ */ b(
|
|
3359
|
+
children: /* @__PURE__ */ b(N, {
|
|
3209
3360
|
size: "md",
|
|
3210
3361
|
tone: t.tone === "gold" ? "default" : "white",
|
|
3211
3362
|
children: t.value
|
|
@@ -3214,8 +3365,8 @@ function Xi({ left: e, right: t, className: n = "" }) {
|
|
|
3214
3365
|
});
|
|
3215
3366
|
}
|
|
3216
3367
|
//#endregion
|
|
3217
|
-
//#region src/ui/
|
|
3218
|
-
function
|
|
3368
|
+
//#region src/ui/JimboPanelSplitter.tsx
|
|
3369
|
+
function na({ orientation: e = "vertical", onDrag: t, onKeyAdjust: n, className: r = "", "aria-label": i }) {
|
|
3219
3370
|
let a = _(!1), o = _(0), s = _(t);
|
|
3220
3371
|
h(() => {
|
|
3221
3372
|
s.current = t;
|
|
@@ -3249,6 +3400,6 @@ function Zi({ orientation: e = "vertical", onDrag: t, onKeyAdjust: n, className:
|
|
|
3249
3400
|
});
|
|
3250
3401
|
}
|
|
3251
3402
|
//#endregion
|
|
3252
|
-
export {
|
|
3403
|
+
export { M as $, ke as A, he as B, ze as C, Ne as D, Pe as E, Ce as F, ce as G, de as H, xe as I, oe as J, ue as K, be as L, Te as M, Se as N, je as O, we as P, re as Q, _e as R, Be as S, Fe as T, le as U, me as V, P as W, ae as X, N as Y, te as Z, Ue as _, Qi as a, Ve as b, Yi as c, Ye as d, ee as et, Je as f, We as g, Ge as h, $i as i, Ee as j, Ae as k, qi as l, Ke as m, ta as n, Zi as o, qe as p, se as q, ea as r, Xi as s, na as t, Ze as u, He as v, Ie as w, Re as x, Le as y, ge as z };
|
|
3253
3404
|
|
|
3254
|
-
//# sourceMappingURL=ui-
|
|
3405
|
+
//# sourceMappingURL=ui-CgjJDJdZ.js.map
|