@vc-shell/framework 1.1.80 → 1.1.82
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/CHANGELOG.md +8 -0
- package/core/plugins/signalR/index.ts +1 -1
- package/dist/assets/{b291dc35a17511f7.woff → 105efd028edc1dfe.woff} +0 -0
- package/dist/assets/19275e398ae57130.woff2 +0 -0
- package/dist/assets/3d892965ab4f1cbb.woff2 +0 -0
- package/dist/assets/{327511cd4a7ba7f9.woff → 489710fb710e73f0.woff} +0 -0
- package/dist/assets/{a617e11804bbacb7.woff → 54cda5482c6c9218.woff} +0 -0
- package/dist/assets/550f52072e8ccafe.woff2 +0 -0
- package/dist/assets/686d4077c1e26876.woff2 +0 -0
- package/dist/assets/{91eee1aa81f72683.woff → 91fe94e424323d61.woff} +0 -0
- package/dist/assets/{f276d55184e05a07.woff → a03cdcd8da5bb987.woff} +0 -0
- package/dist/assets/c9191b638a10f67b.woff2 +0 -0
- package/dist/assets/{fcb1c1ffb5640194.woff → dceaf3b39091e6a4.woff} +0 -0
- package/dist/assets/{a47034e65dbcc3d7.woff → e2ad5b3428289141.woff} +0 -0
- package/dist/assets/f239394367fcf005.woff2 +0 -0
- package/dist/assets/fc829e3f399b70e0.woff2 +0 -0
- package/dist/framework.js +2138 -2121
- package/dist/index.css +1 -1
- package/dist/shared/modules/assets-manager/components/assets-manager/assets-manager.vue.d.ts +2 -1
- package/dist/shared/modules/assets-manager/components/assets-manager/assets-manager.vue.d.ts.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/dist/{vendor-core-js-DFA7rceR.js → vendor-core-js-azBmvlGv.js} +10 -10
- package/dist/{vendor-cypress-signalr-mock-CdKwIhWw.js → vendor-cypress-signalr-mock-DjBxJHA6.js} +15 -15
- package/dist/vendor-dompurify-C-JbJ3KX.js +536 -0
- package/dist/vendor-floating-ui-core-Cl9nBI4j.js +349 -0
- package/dist/vendor-floating-ui-dom-3z44E4mf.js +395 -0
- package/dist/vendor-floating-ui-vue-ClrgkeO5.js +107 -0
- package/dist/{vendor-headlessui-vue-Dg0Llidi.js → vendor-headlessui-vue-D7tzx4PC.js} +2 -2
- package/dist/{vendor-intlify-core-base-txnziOTW.js → vendor-intlify-core-base-Da62SG4M.js} +6 -6
- package/dist/{vendor-intlify-message-compiler-XquMv3aB.js → vendor-intlify-message-compiler-CHvGSH2u.js} +236 -231
- package/dist/{vendor-intlify-shared-CE1Dfvjf.js → vendor-intlify-shared-jWBPd9WB.js} +1 -1
- package/dist/{vendor-lodash-es-CrYlgAi8.js → vendor-lodash-es-BqkGj3Jl.js} +14 -14
- package/dist/{vendor-markdown-it-RJo-N9ov.js → vendor-markdown-it-Czg9qJTh.js} +1 -1
- package/dist/{vendor-microsoft-applicationinsights-analytics-js-CauId95v.js → vendor-microsoft-applicationinsights-analytics-js-BNSkz9ia.js} +20 -20
- package/dist/{vendor-microsoft-applicationinsights-cfgsync-js-DGfB75It.js → vendor-microsoft-applicationinsights-cfgsync-js-Dp8OU6ZE.js} +5 -5
- package/dist/{vendor-microsoft-applicationinsights-channel-js-B4PYlGv8.js → vendor-microsoft-applicationinsights-channel-js-Bc73N-5y.js} +18 -18
- package/dist/{vendor-microsoft-applicationinsights-common-Bj6sQeoz.js → vendor-microsoft-applicationinsights-common-DcnOqpgL.js} +25 -25
- package/dist/{vendor-microsoft-applicationinsights-core-js-Cga21Mpw.js → vendor-microsoft-applicationinsights-core-js-CX4NA2hM.js} +21 -21
- package/dist/{vendor-microsoft-applicationinsights-dependencies-js-CH87Sln6.js → vendor-microsoft-applicationinsights-dependencies-js-C_DhEOae.js} +10 -10
- package/dist/{vendor-microsoft-applicationinsights-properties-js-CLE2OEt_.js → vendor-microsoft-applicationinsights-properties-js-COczDd7b.js} +24 -24
- package/dist/{vendor-microsoft-applicationinsights-web-8IaeIl22.js → vendor-microsoft-applicationinsights-web-DtOQojwf.js} +10 -10
- package/dist/{vendor-microsoft-signalr-qIrag5xx.js → vendor-microsoft-signalr-Bgpbb4fW.js} +1 -1
- package/dist/{vendor-moment-CwOqp704.js → vendor-moment-DMLRxgRE.js} +8 -8
- package/dist/{vendor-nevware21-ts-async-DadHEt7N.js → vendor-nevware21-ts-async-DFUnZ_sN.js} +2 -2
- package/dist/{vendor-prettier-DaiSFsWE.js → vendor-prettier-cZc5sCiS.js} +2 -2
- package/dist/{vendor-prosemirror-commands-DKHyfRYE.js → vendor-prosemirror-commands-DlSOsoOz.js} +3 -3
- package/dist/{vendor-prosemirror-dropcursor-Dro-INCI.js → vendor-prosemirror-dropcursor-CqLA3EZY.js} +2 -2
- package/dist/{vendor-prosemirror-gapcursor-BgyglWtH.js → vendor-prosemirror-gapcursor-3PaVPyUV.js} +4 -4
- package/dist/{vendor-prosemirror-history-B4ei16kP.js → vendor-prosemirror-history-DzP74u0n.js} +3 -3
- package/dist/{vendor-prosemirror-keymap-21y6bXc_.js → vendor-prosemirror-keymap-CN6Hkrq2.js} +1 -1
- package/dist/{vendor-prosemirror-markdown-CuzWQ2N6.js → vendor-prosemirror-markdown-BBPyARPh.js} +2 -2
- package/dist/{vendor-prosemirror-model-CVTn1Stc.js → vendor-prosemirror-model-CiCy9gkA.js} +2 -2
- package/dist/{vendor-prosemirror-schema-list-Dmi4oPas.js → vendor-prosemirror-schema-list-asS28-n3.js} +2 -2
- package/dist/{vendor-prosemirror-state-6jGEPgrP.js → vendor-prosemirror-state-DUZYoLys.js} +2 -2
- package/dist/{vendor-prosemirror-tables-U7ypaxJu.js → vendor-prosemirror-tables-CezTPhzU.js} +5 -5
- package/dist/{vendor-prosemirror-transform-Dk6c_eg4.js → vendor-prosemirror-transform-BOkRqJ32.js} +1 -1
- package/dist/vendor-prosemirror-view-CzsD5m3e.js +3750 -0
- package/dist/vendor-punycode-js-CgGegfA_.js +133 -0
- package/dist/{vendor-rope-sequence-sEGCUMi8.js → vendor-rope-sequence-BWC2FSrq.js} +4 -4
- package/dist/{vendor-semver-FuwqpOls.js → vendor-semver-B87_S22g.js} +2 -2
- package/dist/{vendor-tiptap-core-CtNT-ozM.js → vendor-tiptap-core-rgc3Sj5Y.js} +258 -250
- package/dist/{vendor-tiptap-extension-blockquote-25QerT8O.js → vendor-tiptap-extension-blockquote-DgzMeNpc.js} +1 -1
- package/dist/{vendor-tiptap-extension-bold-B-B75KIy.js → vendor-tiptap-extension-bold-DZbX5Qiw.js} +1 -1
- package/dist/{vendor-tiptap-extension-code-CEZA5x7I.js → vendor-tiptap-extension-code-BcakHaXe.js} +1 -1
- package/dist/{vendor-tiptap-extension-code-block-BFDiCj59.js → vendor-tiptap-extension-code-block-B0U7g1XA.js} +2 -2
- package/dist/{vendor-tiptap-extension-document-C8JdW_kC.js → vendor-tiptap-extension-document-BBhadLNS.js} +1 -1
- package/dist/{vendor-tiptap-extension-hard-break-D9Nzegu6.js → vendor-tiptap-extension-hard-break-eyl10A9U.js} +1 -1
- package/dist/{vendor-tiptap-extension-heading-TmkrHpE2.js → vendor-tiptap-extension-heading-BmX_Abvh.js} +1 -1
- package/dist/{vendor-tiptap-extension-horizontal-rule-BC1YMUau.js → vendor-tiptap-extension-horizontal-rule-DyYIWV6W.js} +2 -2
- package/dist/{vendor-tiptap-extension-image-BQnBpg7z.js → vendor-tiptap-extension-image-C06iDyEi.js} +1 -1
- package/dist/{vendor-tiptap-extension-italic-mSCwLnXY.js → vendor-tiptap-extension-italic-B2YDHBEe.js} +1 -1
- package/dist/{vendor-tiptap-extension-link-CQ0Mw6gd.js → vendor-tiptap-extension-link-Bw8_3Rr4.js} +2 -2
- package/dist/{vendor-tiptap-extension-list-BwidYizT.js → vendor-tiptap-extension-list-qHzpj6eq.js} +1 -1
- package/dist/{vendor-tiptap-extension-paragraph-C_OQHUNe.js → vendor-tiptap-extension-paragraph-BnCRfXCL.js} +1 -1
- package/dist/vendor-tiptap-extension-placeholder-BVZ1jBA2.js +1 -0
- package/dist/{vendor-tiptap-extension-strike-Bfc-eud8.js → vendor-tiptap-extension-strike-Naksm43m.js} +1 -1
- package/dist/{vendor-tiptap-extension-table-D26aUVrb.js → vendor-tiptap-extension-table-Cguez3tu.js} +3 -3
- package/dist/vendor-tiptap-extension-table-cell-lniviH1T.js +1 -0
- package/dist/vendor-tiptap-extension-table-header-lniviH1T.js +1 -0
- package/dist/vendor-tiptap-extension-table-row-lniviH1T.js +1 -0
- package/dist/{vendor-tiptap-extension-text-DrXC1h34.js → vendor-tiptap-extension-text-CixjyWfN.js} +1 -1
- package/dist/{vendor-tiptap-extension-text-style-vv6u__7g.js → vendor-tiptap-extension-text-style-CVsjuWJ4.js} +1 -1
- package/dist/{vendor-tiptap-extension-underline-BfygI164.js → vendor-tiptap-extension-underline-Rwkvga0F.js} +1 -1
- package/dist/{vendor-tiptap-extensions-_4zopegS.js → vendor-tiptap-extensions-F9A02hii.js} +6 -6
- package/dist/{vendor-tiptap-markdown-pGf8MOss.js → vendor-tiptap-markdown-BSUpswXr.js} +5 -5
- package/dist/vendor-tiptap-pm-BUxx7nt1.js +1 -0
- package/dist/{vendor-tiptap-starter-kit-DPG4_B0q.js → vendor-tiptap-starter-kit-BUgq7S1_.js} +17 -17
- package/dist/{vendor-tiptap-vue-3-Ctgrxv1U.js → vendor-tiptap-vue-3-UHrHfZLG.js} +1 -1
- package/dist/{vendor-vue-i18n-BeXi5L3e.js → vendor-vue-i18n-CO5LWKE0.js} +6 -6
- package/dist/{vendor-vue3-application-insights-C8xbxXXX.js → vendor-vue3-application-insights-CE6eo4vj.js} +2 -2
- package/dist/{vendor-vue3-touch-events-8Pa3HHlV.js → vendor-vue3-touch-events-DqysuuWh.js} +2 -2
- package/package.json +4 -4
- package/shared/modules/assets-manager/components/assets-manager/assets-manager.vue +24 -4
- package/dist/assets/42df4e2d6fa3fd2a.woff2 +0 -0
- package/dist/assets/52610491f372cb0c.woff2 +0 -0
- package/dist/assets/5b3661be8be679d0.woff2 +0 -0
- package/dist/assets/5d96cfcc5bedd917.woff2 +0 -0
- package/dist/assets/6619e9e10beea0e7.woff2 +0 -0
- package/dist/assets/bfbe205759295eca.woff2 +0 -0
- package/dist/assets/d80b05788e407de7.woff2 +0 -0
- package/dist/vendor-dompurify-eYFoHPwR.js +0 -528
- package/dist/vendor-floating-ui-vue-C1Zscv9o.js +0 -836
- package/dist/vendor-prosemirror-view-Bfe9EVLy.js +0 -1489
- package/dist/vendor-punycode-js-CNI-zL6U.js +0 -133
- package/dist/vendor-tiptap-extension-placeholder-BIojfRhh.js +0 -1
- package/dist/vendor-tiptap-extension-table-cell-DuWy52BP.js +0 -1
- package/dist/vendor-tiptap-extension-table-header-DuWy52BP.js +0 -1
- package/dist/vendor-tiptap-extension-table-row-DuWy52BP.js +0 -1
- package/dist/vendor-tiptap-pm-B2DY8bDS.js +0 -7681
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { l as Se, e as
|
|
1
|
+
import { l as Se, e as re, a as z, v as se } from "./vendor-intlify-shared-jWBPd9WB.js";
|
|
2
2
|
/*!
|
|
3
|
-
* message-compiler v11.1.
|
|
3
|
+
* message-compiler v11.1.12
|
|
4
4
|
* (c) 2025 kazuya kawaguchi
|
|
5
5
|
* Released under the MIT License.
|
|
6
6
|
*/
|
|
@@ -60,12 +60,12 @@ function G(r, n, c = {}) {
|
|
|
60
60
|
function je(r) {
|
|
61
61
|
throw r;
|
|
62
62
|
}
|
|
63
|
-
const Pe = /<\/?[\w\s="/.':;#-\/]+>/, Ze = (r) => Pe.test(r),
|
|
63
|
+
const Pe = /<\/?[\w\s="/.':;#-\/]+>/, Ze = (r) => Pe.test(r), M = " ", Oe = "\r", O = `
|
|
64
64
|
`, me = "\u2028", ye = "\u2029";
|
|
65
65
|
function be(r) {
|
|
66
66
|
const n = r;
|
|
67
67
|
let c = 0, a = 1, _ = 1, u = 0;
|
|
68
|
-
const h = (p) => n[p] === Oe && n[p + 1] ===
|
|
68
|
+
const h = (p) => n[p] === Oe && n[p + 1] === O, I = (p) => n[p] === O, D = (p) => n[p] === ye, m = (p) => n[p] === me, b = (p) => h(p) || I(p) || D(p) || m(p), S = () => c, T = () => a, R = () => _, v = () => u, A = (p) => h(p) || D(p) || m(p) ? O : n[p], C = () => A(c), i = () => A(c + u);
|
|
69
69
|
function l() {
|
|
70
70
|
return u = 0, b(c) && (a++, _ = 0), h(c) && c++, c++, _++, n[c];
|
|
71
71
|
}
|
|
@@ -85,13 +85,13 @@ function be(r) {
|
|
|
85
85
|
u = 0;
|
|
86
86
|
}
|
|
87
87
|
return {
|
|
88
|
-
index:
|
|
88
|
+
index: S,
|
|
89
89
|
line: T,
|
|
90
90
|
column: R,
|
|
91
91
|
peekOffset: v,
|
|
92
92
|
charAt: A,
|
|
93
93
|
currentChar: C,
|
|
94
|
-
currentPeek:
|
|
94
|
+
currentPeek: i,
|
|
95
95
|
next: l,
|
|
96
96
|
peek: E,
|
|
97
97
|
reset: o,
|
|
@@ -99,9 +99,9 @@ function be(r) {
|
|
|
99
99
|
skipToPeek: N
|
|
100
100
|
};
|
|
101
101
|
}
|
|
102
|
-
const
|
|
102
|
+
const w = void 0, Re = ".", ee = "'", Ue = "tokenizer";
|
|
103
103
|
function ve(r, n = {}) {
|
|
104
|
-
const c = n.location !== !1, a = be(r), _ = () => a.index(), u = () => ke(a.line(), a.column(), a.index()), h = u(), I = _(),
|
|
104
|
+
const c = n.location !== !1, a = be(r), _ = () => a.index(), u = () => ke(a.line(), a.column(), a.index()), h = u(), I = _(), D = {
|
|
105
105
|
currentType: 13,
|
|
106
106
|
offset: I,
|
|
107
107
|
startLoc: h,
|
|
@@ -113,21 +113,21 @@ function ve(r, n = {}) {
|
|
|
113
113
|
braceNest: 0,
|
|
114
114
|
inLinked: !1,
|
|
115
115
|
text: ""
|
|
116
|
-
},
|
|
117
|
-
function
|
|
118
|
-
const
|
|
119
|
-
if (t.column +=
|
|
120
|
-
const P = c ? q(
|
|
116
|
+
}, m = () => D, { onError: b } = n;
|
|
117
|
+
function S(e, t, s, ...f) {
|
|
118
|
+
const k = m();
|
|
119
|
+
if (t.column += s, t.offset += s, b) {
|
|
120
|
+
const P = c ? q(k.startLoc, t) : null, U = G(e, P, {
|
|
121
121
|
domain: Ue,
|
|
122
122
|
args: f
|
|
123
123
|
});
|
|
124
124
|
b(U);
|
|
125
125
|
}
|
|
126
126
|
}
|
|
127
|
-
function T(e, t,
|
|
127
|
+
function T(e, t, s) {
|
|
128
128
|
e.endLoc = u(), e.currentType = t;
|
|
129
129
|
const f = { type: t };
|
|
130
|
-
return c && (f.loc = q(e.startLoc, e.endLoc)),
|
|
130
|
+
return c && (f.loc = q(e.startLoc, e.endLoc)), s != null && (f.value = s), f;
|
|
131
131
|
}
|
|
132
132
|
const R = (e) => T(
|
|
133
133
|
e,
|
|
@@ -135,11 +135,11 @@ function ve(r, n = {}) {
|
|
|
135
135
|
/* TokenTypes.EOF */
|
|
136
136
|
);
|
|
137
137
|
function v(e, t) {
|
|
138
|
-
return e.currentChar() === t ? (e.next(), t) : (
|
|
138
|
+
return e.currentChar() === t ? (e.next(), t) : (S(d.EXPECTED_TOKEN, u(), 0, t), "");
|
|
139
139
|
}
|
|
140
140
|
function A(e) {
|
|
141
141
|
let t = "";
|
|
142
|
-
for (; e.currentPeek() ===
|
|
142
|
+
for (; e.currentPeek() === M || e.currentPeek() === O; )
|
|
143
143
|
t += e.currentPeek(), e.peek();
|
|
144
144
|
return t;
|
|
145
145
|
}
|
|
@@ -147,8 +147,8 @@ function ve(r, n = {}) {
|
|
|
147
147
|
const t = A(e);
|
|
148
148
|
return e.skipToPeek(), t;
|
|
149
149
|
}
|
|
150
|
-
function
|
|
151
|
-
if (e ===
|
|
150
|
+
function i(e) {
|
|
151
|
+
if (e === w)
|
|
152
152
|
return !1;
|
|
153
153
|
const t = e.charCodeAt(0);
|
|
154
154
|
return t >= 97 && t <= 122 || // a-z
|
|
@@ -156,86 +156,86 @@ function ve(r, n = {}) {
|
|
|
156
156
|
t === 95;
|
|
157
157
|
}
|
|
158
158
|
function l(e) {
|
|
159
|
-
if (e ===
|
|
159
|
+
if (e === w)
|
|
160
160
|
return !1;
|
|
161
161
|
const t = e.charCodeAt(0);
|
|
162
162
|
return t >= 48 && t <= 57;
|
|
163
163
|
}
|
|
164
164
|
function E(e, t) {
|
|
165
|
-
const { currentType:
|
|
166
|
-
if (
|
|
165
|
+
const { currentType: s } = t;
|
|
166
|
+
if (s !== 2)
|
|
167
167
|
return !1;
|
|
168
168
|
A(e);
|
|
169
|
-
const f =
|
|
169
|
+
const f = i(e.currentPeek());
|
|
170
170
|
return e.resetPeek(), f;
|
|
171
171
|
}
|
|
172
172
|
function o(e, t) {
|
|
173
|
-
const { currentType:
|
|
174
|
-
if (
|
|
173
|
+
const { currentType: s } = t;
|
|
174
|
+
if (s !== 2)
|
|
175
175
|
return !1;
|
|
176
176
|
A(e);
|
|
177
|
-
const f = e.currentPeek() === "-" ? e.peek() : e.currentPeek(),
|
|
178
|
-
return e.resetPeek(),
|
|
177
|
+
const f = e.currentPeek() === "-" ? e.peek() : e.currentPeek(), k = l(f);
|
|
178
|
+
return e.resetPeek(), k;
|
|
179
179
|
}
|
|
180
180
|
function L(e, t) {
|
|
181
|
-
const { currentType:
|
|
182
|
-
if (
|
|
181
|
+
const { currentType: s } = t;
|
|
182
|
+
if (s !== 2)
|
|
183
183
|
return !1;
|
|
184
184
|
A(e);
|
|
185
|
-
const f = e.currentPeek() ===
|
|
185
|
+
const f = e.currentPeek() === ee;
|
|
186
186
|
return e.resetPeek(), f;
|
|
187
187
|
}
|
|
188
188
|
function N(e, t) {
|
|
189
|
-
const { currentType:
|
|
190
|
-
if (
|
|
189
|
+
const { currentType: s } = t;
|
|
190
|
+
if (s !== 7)
|
|
191
191
|
return !1;
|
|
192
192
|
A(e);
|
|
193
193
|
const f = e.currentPeek() === ".";
|
|
194
194
|
return e.resetPeek(), f;
|
|
195
195
|
}
|
|
196
196
|
function p(e, t) {
|
|
197
|
-
const { currentType:
|
|
198
|
-
if (
|
|
197
|
+
const { currentType: s } = t;
|
|
198
|
+
if (s !== 8)
|
|
199
199
|
return !1;
|
|
200
200
|
A(e);
|
|
201
|
-
const f =
|
|
201
|
+
const f = i(e.currentPeek());
|
|
202
202
|
return e.resetPeek(), f;
|
|
203
203
|
}
|
|
204
|
-
function
|
|
205
|
-
const { currentType:
|
|
206
|
-
if (!(
|
|
204
|
+
function H(e, t) {
|
|
205
|
+
const { currentType: s } = t;
|
|
206
|
+
if (!(s === 7 || s === 11))
|
|
207
207
|
return !1;
|
|
208
208
|
A(e);
|
|
209
209
|
const f = e.currentPeek() === ":";
|
|
210
210
|
return e.resetPeek(), f;
|
|
211
211
|
}
|
|
212
|
-
function
|
|
213
|
-
const { currentType:
|
|
214
|
-
if (
|
|
212
|
+
function y(e, t) {
|
|
213
|
+
const { currentType: s } = t;
|
|
214
|
+
if (s !== 9)
|
|
215
215
|
return !1;
|
|
216
216
|
const f = () => {
|
|
217
217
|
const P = e.currentPeek();
|
|
218
|
-
return P === "{" ?
|
|
219
|
-
},
|
|
220
|
-
return e.resetPeek(),
|
|
218
|
+
return P === "{" ? i(e.peek()) : P === "@" || P === "|" || P === ":" || P === "." || P === M || !P ? !1 : P === O ? (e.peek(), f()) : F(e, !1);
|
|
219
|
+
}, k = f();
|
|
220
|
+
return e.resetPeek(), k;
|
|
221
221
|
}
|
|
222
|
-
function
|
|
222
|
+
function Y(e) {
|
|
223
223
|
A(e);
|
|
224
224
|
const t = e.currentPeek() === "|";
|
|
225
225
|
return e.resetPeek(), t;
|
|
226
226
|
}
|
|
227
227
|
function F(e, t = !0) {
|
|
228
|
-
const
|
|
228
|
+
const s = (k = !1, P = "") => {
|
|
229
229
|
const U = e.currentPeek();
|
|
230
|
-
return U === "{" || U === "@" || !U ?
|
|
231
|
-
}, f =
|
|
230
|
+
return U === "{" || U === "@" || !U ? k : U === "|" ? !(P === M || P === O) : U === M ? (e.peek(), s(!0, M)) : U === O ? (e.peek(), s(!0, O)) : !0;
|
|
231
|
+
}, f = s();
|
|
232
232
|
return t && e.resetPeek(), f;
|
|
233
233
|
}
|
|
234
|
-
function
|
|
235
|
-
const
|
|
236
|
-
return
|
|
234
|
+
function g(e, t) {
|
|
235
|
+
const s = e.currentChar();
|
|
236
|
+
return s === w ? w : t(s) ? (e.next(), s) : null;
|
|
237
237
|
}
|
|
238
|
-
function
|
|
238
|
+
function ie(e) {
|
|
239
239
|
const t = e.charCodeAt(0);
|
|
240
240
|
return t >= 97 && t <= 122 || // a-z
|
|
241
241
|
t >= 65 && t <= 90 || // A-Z
|
|
@@ -243,10 +243,10 @@ function ve(r, n = {}) {
|
|
|
243
243
|
t === 95 || // _
|
|
244
244
|
t === 36;
|
|
245
245
|
}
|
|
246
|
-
function ie(e) {
|
|
247
|
-
return H(e, se);
|
|
248
|
-
}
|
|
249
246
|
function ce(e) {
|
|
247
|
+
return g(e, ie);
|
|
248
|
+
}
|
|
249
|
+
function ue(e) {
|
|
250
250
|
const t = e.charCodeAt(0);
|
|
251
251
|
return t >= 97 && t <= 122 || // a-z
|
|
252
252
|
t >= 65 && t <= 90 || // A-Z
|
|
@@ -255,74 +255,79 @@ function ve(r, n = {}) {
|
|
|
255
255
|
t === 36 || // $
|
|
256
256
|
t === 45;
|
|
257
257
|
}
|
|
258
|
-
function ue(e) {
|
|
259
|
-
return H(e, ce);
|
|
260
|
-
}
|
|
261
258
|
function ae(e) {
|
|
262
|
-
|
|
263
|
-
return t >= 48 && t <= 57;
|
|
259
|
+
return g(e, ue);
|
|
264
260
|
}
|
|
265
261
|
function oe(e) {
|
|
266
|
-
|
|
262
|
+
const t = e.charCodeAt(0);
|
|
263
|
+
return t >= 48 && t <= 57;
|
|
267
264
|
}
|
|
268
265
|
function le(e) {
|
|
266
|
+
return g(e, oe);
|
|
267
|
+
}
|
|
268
|
+
function fe(e) {
|
|
269
269
|
const t = e.charCodeAt(0);
|
|
270
270
|
return t >= 48 && t <= 57 || // 0-9
|
|
271
271
|
t >= 65 && t <= 70 || // A-F
|
|
272
272
|
t >= 97 && t <= 102;
|
|
273
273
|
}
|
|
274
|
-
function
|
|
275
|
-
return
|
|
274
|
+
function Ee(e) {
|
|
275
|
+
return g(e, fe);
|
|
276
276
|
}
|
|
277
277
|
function J(e) {
|
|
278
|
-
let t = "",
|
|
279
|
-
for (; t =
|
|
280
|
-
|
|
281
|
-
return
|
|
278
|
+
let t = "", s = "";
|
|
279
|
+
for (; t = le(e); )
|
|
280
|
+
s += t;
|
|
281
|
+
return s;
|
|
282
282
|
}
|
|
283
|
-
function
|
|
283
|
+
function de(e) {
|
|
284
284
|
let t = "";
|
|
285
285
|
for (; ; ) {
|
|
286
|
-
const
|
|
287
|
-
if (
|
|
286
|
+
const s = e.currentChar();
|
|
287
|
+
if (s === "{" || s === "}" || s === "@" || s === "|" || !s)
|
|
288
288
|
break;
|
|
289
|
-
if (
|
|
289
|
+
if (s === M || s === O)
|
|
290
290
|
if (F(e))
|
|
291
|
-
t +=
|
|
291
|
+
t += s, e.next();
|
|
292
292
|
else {
|
|
293
|
-
if (
|
|
293
|
+
if (Y(e))
|
|
294
294
|
break;
|
|
295
|
-
t +=
|
|
295
|
+
t += s, e.next();
|
|
296
296
|
}
|
|
297
297
|
else
|
|
298
|
-
t +=
|
|
298
|
+
t += s, e.next();
|
|
299
299
|
}
|
|
300
300
|
return t;
|
|
301
301
|
}
|
|
302
|
-
function de(e) {
|
|
303
|
-
C(e);
|
|
304
|
-
let t = "", i = "";
|
|
305
|
-
for (; t = ue(e); )
|
|
306
|
-
i += t;
|
|
307
|
-
return e.currentChar() === Y && k(d.UNTERMINATED_CLOSING_BRACE, u(), 0), i;
|
|
308
|
-
}
|
|
309
302
|
function Le(e) {
|
|
310
303
|
C(e);
|
|
311
|
-
let t = "";
|
|
312
|
-
|
|
304
|
+
let t = "", s = "";
|
|
305
|
+
for (; t = ae(e); )
|
|
306
|
+
s += t;
|
|
307
|
+
const f = e.currentChar();
|
|
308
|
+
if (f && f !== "}" && f !== w && f !== M && f !== O && f !== " ") {
|
|
309
|
+
const k = Z(e);
|
|
310
|
+
return S(d.INVALID_TOKEN_IN_PLACEHOLDER, u(), 0, s + k), s + k;
|
|
311
|
+
}
|
|
312
|
+
return e.currentChar() === w && S(d.UNTERMINATED_CLOSING_BRACE, u(), 0), s;
|
|
313
313
|
}
|
|
314
314
|
function Ne(e) {
|
|
315
|
-
|
|
315
|
+
C(e);
|
|
316
|
+
let t = "";
|
|
317
|
+
return e.currentChar() === "-" ? (e.next(), t += `-${J(e)}`) : t += J(e), e.currentChar() === w && S(d.UNTERMINATED_CLOSING_BRACE, u(), 0), t;
|
|
316
318
|
}
|
|
317
319
|
function _e(e) {
|
|
320
|
+
return e !== ee && e !== O;
|
|
321
|
+
}
|
|
322
|
+
function pe(e) {
|
|
318
323
|
C(e), v(e, "'");
|
|
319
|
-
let t = "",
|
|
320
|
-
for (; t =
|
|
321
|
-
t === "\\" ?
|
|
324
|
+
let t = "", s = "";
|
|
325
|
+
for (; t = g(e, _e); )
|
|
326
|
+
t === "\\" ? s += Ie(e) : s += t;
|
|
322
327
|
const f = e.currentChar();
|
|
323
|
-
return f ===
|
|
328
|
+
return f === O || f === w ? (S(d.UNTERMINATED_SINGLE_QUOTE_IN_PLACEHOLDER, u(), 0), f === O && (e.next(), v(e, "'")), s) : (v(e, "'"), s);
|
|
324
329
|
}
|
|
325
|
-
function
|
|
330
|
+
function Ie(e) {
|
|
326
331
|
const t = e.currentChar();
|
|
327
332
|
switch (t) {
|
|
328
333
|
case "\\":
|
|
@@ -333,42 +338,42 @@ function ve(r, n = {}) {
|
|
|
333
338
|
case "U":
|
|
334
339
|
return j(e, t, 6);
|
|
335
340
|
default:
|
|
336
|
-
return
|
|
341
|
+
return S(d.UNKNOWN_ESCAPE_SEQUENCE, u(), 0, t), "";
|
|
337
342
|
}
|
|
338
343
|
}
|
|
339
|
-
function j(e, t,
|
|
344
|
+
function j(e, t, s) {
|
|
340
345
|
v(e, t);
|
|
341
346
|
let f = "";
|
|
342
|
-
for (let
|
|
343
|
-
const P =
|
|
347
|
+
for (let k = 0; k < s; k++) {
|
|
348
|
+
const P = Ee(e);
|
|
344
349
|
if (!P) {
|
|
345
|
-
|
|
350
|
+
S(d.INVALID_UNICODE_ESCAPE_SEQUENCE, u(), 0, `\\${t}${f}${e.currentChar()}`);
|
|
346
351
|
break;
|
|
347
352
|
}
|
|
348
353
|
f += P;
|
|
349
354
|
}
|
|
350
355
|
return `\\${t}${f}`;
|
|
351
356
|
}
|
|
352
|
-
function Ie(e) {
|
|
353
|
-
return e !== "{" && e !== "}" && e !== X && e !== y;
|
|
354
|
-
}
|
|
355
357
|
function Ce(e) {
|
|
358
|
+
return e !== "{" && e !== "}" && e !== M && e !== O;
|
|
359
|
+
}
|
|
360
|
+
function Z(e) {
|
|
356
361
|
C(e);
|
|
357
|
-
let t = "",
|
|
358
|
-
for (; t =
|
|
359
|
-
|
|
360
|
-
return
|
|
362
|
+
let t = "", s = "";
|
|
363
|
+
for (; t = g(e, Ce); )
|
|
364
|
+
s += t;
|
|
365
|
+
return s;
|
|
361
366
|
}
|
|
362
367
|
function he(e) {
|
|
363
|
-
let t = "",
|
|
364
|
-
for (; t =
|
|
365
|
-
|
|
366
|
-
return
|
|
368
|
+
let t = "", s = "";
|
|
369
|
+
for (; t = ce(e); )
|
|
370
|
+
s += t;
|
|
371
|
+
return s;
|
|
367
372
|
}
|
|
368
373
|
function Te(e) {
|
|
369
|
-
const t = (
|
|
374
|
+
const t = (s) => {
|
|
370
375
|
const f = e.currentChar();
|
|
371
|
-
return f === "{" || f === "@" || f === "|" || f === "(" || f === ")" || !f || f ===
|
|
376
|
+
return f === "{" || f === "@" || f === "|" || f === "(" || f === ")" || !f || f === M ? s : (s += f, e.next(), t(s));
|
|
372
377
|
};
|
|
373
378
|
return t("");
|
|
374
379
|
}
|
|
@@ -382,48 +387,48 @@ function ve(r, n = {}) {
|
|
|
382
387
|
return C(e), t;
|
|
383
388
|
}
|
|
384
389
|
function B(e, t) {
|
|
385
|
-
let
|
|
390
|
+
let s = null;
|
|
386
391
|
switch (e.currentChar()) {
|
|
387
392
|
case "{":
|
|
388
|
-
return t.braceNest >= 1 &&
|
|
393
|
+
return t.braceNest >= 1 && S(d.NOT_ALLOW_NEST_PLACEHOLDER, u(), 0), e.next(), s = T(
|
|
389
394
|
t,
|
|
390
395
|
2,
|
|
391
396
|
"{"
|
|
392
397
|
/* TokenChars.BraceLeft */
|
|
393
|
-
), C(e), t.braceNest++,
|
|
398
|
+
), C(e), t.braceNest++, s;
|
|
394
399
|
case "}":
|
|
395
|
-
return t.braceNest > 0 && t.currentType === 2 &&
|
|
400
|
+
return t.braceNest > 0 && t.currentType === 2 && S(d.EMPTY_PLACEHOLDER, u(), 0), e.next(), s = T(
|
|
396
401
|
t,
|
|
397
402
|
3,
|
|
398
403
|
"}"
|
|
399
404
|
/* TokenChars.BraceRight */
|
|
400
|
-
), t.braceNest--, t.braceNest > 0 && C(e), t.inLinked && t.braceNest === 0 && (t.inLinked = !1),
|
|
405
|
+
), t.braceNest--, t.braceNest > 0 && C(e), t.inLinked && t.braceNest === 0 && (t.inLinked = !1), s;
|
|
401
406
|
case "@":
|
|
402
|
-
return t.braceNest > 0 &&
|
|
407
|
+
return t.braceNest > 0 && S(d.UNTERMINATED_CLOSING_BRACE, u(), 0), s = $(e, t) || R(t), t.braceNest = 0, s;
|
|
403
408
|
default: {
|
|
404
|
-
let
|
|
405
|
-
if (
|
|
406
|
-
return t.braceNest > 0 &&
|
|
409
|
+
let k = !0, P = !0, U = !0;
|
|
410
|
+
if (Y(e))
|
|
411
|
+
return t.braceNest > 0 && S(d.UNTERMINATED_CLOSING_BRACE, u(), 0), s = T(t, 1, V(e)), t.braceNest = 0, t.inLinked = !1, s;
|
|
407
412
|
if (t.braceNest > 0 && (t.currentType === 4 || t.currentType === 5 || t.currentType === 6))
|
|
408
|
-
return
|
|
409
|
-
if (
|
|
410
|
-
return
|
|
413
|
+
return S(d.UNTERMINATED_CLOSING_BRACE, u(), 0), t.braceNest = 0, Q(e, t);
|
|
414
|
+
if (k = E(e, t))
|
|
415
|
+
return s = T(t, 4, Le(e)), C(e), s;
|
|
411
416
|
if (P = o(e, t))
|
|
412
|
-
return
|
|
417
|
+
return s = T(t, 5, Ne(e)), C(e), s;
|
|
413
418
|
if (U = L(e, t))
|
|
414
|
-
return
|
|
415
|
-
if (!
|
|
416
|
-
return
|
|
419
|
+
return s = T(t, 6, pe(e)), C(e), s;
|
|
420
|
+
if (!k && !P && !U)
|
|
421
|
+
return s = T(t, 12, Z(e)), S(d.INVALID_TOKEN_IN_PLACEHOLDER, u(), 0, s.value), C(e), s;
|
|
417
422
|
break;
|
|
418
423
|
}
|
|
419
424
|
}
|
|
420
|
-
return
|
|
425
|
+
return s;
|
|
421
426
|
}
|
|
422
427
|
function $(e, t) {
|
|
423
|
-
const { currentType:
|
|
428
|
+
const { currentType: s } = t;
|
|
424
429
|
let f = null;
|
|
425
|
-
const
|
|
426
|
-
switch ((
|
|
430
|
+
const k = e.currentChar();
|
|
431
|
+
switch ((s === 7 || s === 8 || s === 11 || s === 9) && (k === O || k === M) && S(d.INVALID_LINKED_FORMAT, u(), 0), k) {
|
|
427
432
|
case "@":
|
|
428
433
|
return e.next(), f = T(
|
|
429
434
|
t,
|
|
@@ -446,11 +451,11 @@ function ve(r, n = {}) {
|
|
|
446
451
|
/* TokenChars.LinkedDelimiter */
|
|
447
452
|
);
|
|
448
453
|
default:
|
|
449
|
-
return
|
|
454
|
+
return Y(e) ? (f = T(t, 1, V(e)), t.braceNest = 0, t.inLinked = !1, f) : N(e, t) || H(e, t) ? (C(e), $(e, t)) : p(e, t) ? (C(e), T(t, 11, he(e))) : y(e, t) ? (C(e), k === "{" ? B(e, t) || f : T(t, 10, Te(e))) : (s === 7 && S(d.INVALID_LINKED_FORMAT, u(), 0), t.braceNest = 0, t.inLinked = !1, Q(e, t));
|
|
450
455
|
}
|
|
451
456
|
}
|
|
452
457
|
function Q(e, t) {
|
|
453
|
-
let
|
|
458
|
+
let s = {
|
|
454
459
|
type: 13
|
|
455
460
|
/* TokenTypes.EOF */
|
|
456
461
|
};
|
|
@@ -462,7 +467,7 @@ function ve(r, n = {}) {
|
|
|
462
467
|
case "{":
|
|
463
468
|
return B(e, t) || R(t);
|
|
464
469
|
case "}":
|
|
465
|
-
return
|
|
470
|
+
return S(d.UNBALANCED_CLOSING_BRACE, u(), 0), e.next(), T(
|
|
466
471
|
t,
|
|
467
472
|
3,
|
|
468
473
|
"}"
|
|
@@ -471,28 +476,28 @@ function ve(r, n = {}) {
|
|
|
471
476
|
case "@":
|
|
472
477
|
return $(e, t) || R(t);
|
|
473
478
|
default: {
|
|
474
|
-
if (
|
|
475
|
-
return
|
|
479
|
+
if (Y(e))
|
|
480
|
+
return s = T(t, 1, V(e)), t.braceNest = 0, t.inLinked = !1, s;
|
|
476
481
|
if (F(e))
|
|
477
|
-
return T(t, 0,
|
|
482
|
+
return T(t, 0, de(e));
|
|
478
483
|
break;
|
|
479
484
|
}
|
|
480
485
|
}
|
|
481
|
-
return
|
|
486
|
+
return s;
|
|
482
487
|
}
|
|
483
488
|
function Ae() {
|
|
484
|
-
const { currentType: e, offset: t, startLoc:
|
|
485
|
-
return
|
|
486
|
-
|
|
489
|
+
const { currentType: e, offset: t, startLoc: s, endLoc: f } = D;
|
|
490
|
+
return D.lastType = e, D.lastOffset = t, D.lastStartLoc = s, D.lastEndLoc = f, D.offset = _(), D.startLoc = u(), a.currentChar() === w ? T(
|
|
491
|
+
D,
|
|
487
492
|
13
|
|
488
493
|
/* TokenTypes.EOF */
|
|
489
|
-
) : Q(a,
|
|
494
|
+
) : Q(a, D);
|
|
490
495
|
}
|
|
491
496
|
return {
|
|
492
497
|
nextToken: Ae,
|
|
493
498
|
currentOffset: _,
|
|
494
499
|
currentPosition: u,
|
|
495
|
-
context:
|
|
500
|
+
context: m
|
|
496
501
|
};
|
|
497
502
|
}
|
|
498
503
|
const Me = "parser", Xe = /(?:\\\\|\\'|\\u([0-9a-fA-F]{4})|\\U([0-9a-fA-F]{6}))/g;
|
|
@@ -509,164 +514,164 @@ function we(r, n, c) {
|
|
|
509
514
|
}
|
|
510
515
|
}
|
|
511
516
|
}
|
|
512
|
-
function
|
|
517
|
+
function He(r = {}) {
|
|
513
518
|
const n = r.location !== !1, { onError: c } = r;
|
|
514
|
-
function a(
|
|
515
|
-
const N =
|
|
519
|
+
function a(i, l, E, o, ...L) {
|
|
520
|
+
const N = i.currentPosition();
|
|
516
521
|
if (N.offset += o, N.column += o, c) {
|
|
517
|
-
const p = n ? q(E, N) : null,
|
|
522
|
+
const p = n ? q(E, N) : null, H = G(l, p, {
|
|
518
523
|
domain: Me,
|
|
519
524
|
args: L
|
|
520
525
|
});
|
|
521
|
-
c(
|
|
526
|
+
c(H);
|
|
522
527
|
}
|
|
523
528
|
}
|
|
524
|
-
function _(
|
|
525
|
-
const o = { type:
|
|
529
|
+
function _(i, l, E) {
|
|
530
|
+
const o = { type: i };
|
|
526
531
|
return n && (o.start = l, o.end = l, o.loc = { start: E, end: E }), o;
|
|
527
532
|
}
|
|
528
|
-
function u(
|
|
529
|
-
n && (
|
|
533
|
+
function u(i, l, E, o) {
|
|
534
|
+
n && (i.end = l, i.loc && (i.loc.end = E));
|
|
530
535
|
}
|
|
531
|
-
function h(
|
|
532
|
-
const E =
|
|
533
|
-
return o.value = l, u(o,
|
|
536
|
+
function h(i, l) {
|
|
537
|
+
const E = i.context(), o = _(3, E.offset, E.startLoc);
|
|
538
|
+
return o.value = l, u(o, i.currentOffset(), i.currentPosition()), o;
|
|
534
539
|
}
|
|
535
|
-
function I(
|
|
536
|
-
const E =
|
|
537
|
-
return N.index = parseInt(l, 10),
|
|
540
|
+
function I(i, l) {
|
|
541
|
+
const E = i.context(), { lastOffset: o, lastStartLoc: L } = E, N = _(5, o, L);
|
|
542
|
+
return N.index = parseInt(l, 10), i.nextToken(), u(N, i.currentOffset(), i.currentPosition()), N;
|
|
538
543
|
}
|
|
539
|
-
function
|
|
540
|
-
const E =
|
|
541
|
-
return N.key = l,
|
|
544
|
+
function D(i, l) {
|
|
545
|
+
const E = i.context(), { lastOffset: o, lastStartLoc: L } = E, N = _(4, o, L);
|
|
546
|
+
return N.key = l, i.nextToken(), u(N, i.currentOffset(), i.currentPosition()), N;
|
|
542
547
|
}
|
|
543
|
-
function
|
|
544
|
-
const E =
|
|
545
|
-
return N.value = l.replace(Xe, we),
|
|
548
|
+
function m(i, l) {
|
|
549
|
+
const E = i.context(), { lastOffset: o, lastStartLoc: L } = E, N = _(9, o, L);
|
|
550
|
+
return N.value = l.replace(Xe, we), i.nextToken(), u(N, i.currentOffset(), i.currentPosition()), N;
|
|
546
551
|
}
|
|
547
|
-
function b(
|
|
548
|
-
const l =
|
|
549
|
-
return l.type !== 11 ? (a(
|
|
552
|
+
function b(i) {
|
|
553
|
+
const l = i.nextToken(), E = i.context(), { lastOffset: o, lastStartLoc: L } = E, N = _(8, o, L);
|
|
554
|
+
return l.type !== 11 ? (a(i, d.UNEXPECTED_EMPTY_LINKED_MODIFIER, E.lastStartLoc, 0), N.value = "", u(N, o, L), {
|
|
550
555
|
nextConsumeToken: l,
|
|
551
556
|
node: N
|
|
552
|
-
}) : (l.value == null && a(
|
|
557
|
+
}) : (l.value == null && a(i, d.UNEXPECTED_LEXICAL_ANALYSIS, E.lastStartLoc, 0, X(l)), N.value = l.value || "", u(N, i.currentOffset(), i.currentPosition()), {
|
|
553
558
|
node: N
|
|
554
559
|
});
|
|
555
560
|
}
|
|
556
|
-
function
|
|
557
|
-
const E =
|
|
558
|
-
return o.value = l, u(o,
|
|
561
|
+
function S(i, l) {
|
|
562
|
+
const E = i.context(), o = _(7, E.offset, E.startLoc);
|
|
563
|
+
return o.value = l, u(o, i.currentOffset(), i.currentPosition()), o;
|
|
559
564
|
}
|
|
560
|
-
function T(
|
|
561
|
-
const l =
|
|
562
|
-
let o =
|
|
565
|
+
function T(i) {
|
|
566
|
+
const l = i.context(), E = _(6, l.offset, l.startLoc);
|
|
567
|
+
let o = i.nextToken();
|
|
563
568
|
if (o.type === 8) {
|
|
564
|
-
const L = b(
|
|
565
|
-
E.modifier = L.node, o = L.nextConsumeToken ||
|
|
569
|
+
const L = b(i);
|
|
570
|
+
E.modifier = L.node, o = L.nextConsumeToken || i.nextToken();
|
|
566
571
|
}
|
|
567
|
-
switch (o.type !== 9 && a(
|
|
572
|
+
switch (o.type !== 9 && a(i, d.UNEXPECTED_LEXICAL_ANALYSIS, l.lastStartLoc, 0, X(o)), o = i.nextToken(), o.type === 2 && (o = i.nextToken()), o.type) {
|
|
568
573
|
case 10:
|
|
569
|
-
o.value == null && a(
|
|
574
|
+
o.value == null && a(i, d.UNEXPECTED_LEXICAL_ANALYSIS, l.lastStartLoc, 0, X(o)), E.key = S(i, o.value || "");
|
|
570
575
|
break;
|
|
571
576
|
case 4:
|
|
572
|
-
o.value == null && a(
|
|
577
|
+
o.value == null && a(i, d.UNEXPECTED_LEXICAL_ANALYSIS, l.lastStartLoc, 0, X(o)), E.key = D(i, o.value || "");
|
|
573
578
|
break;
|
|
574
579
|
case 5:
|
|
575
|
-
o.value == null && a(
|
|
580
|
+
o.value == null && a(i, d.UNEXPECTED_LEXICAL_ANALYSIS, l.lastStartLoc, 0, X(o)), E.key = I(i, o.value || "");
|
|
576
581
|
break;
|
|
577
582
|
case 6:
|
|
578
|
-
o.value == null && a(
|
|
583
|
+
o.value == null && a(i, d.UNEXPECTED_LEXICAL_ANALYSIS, l.lastStartLoc, 0, X(o)), E.key = m(i, o.value || "");
|
|
579
584
|
break;
|
|
580
585
|
default: {
|
|
581
|
-
a(
|
|
582
|
-
const L =
|
|
586
|
+
a(i, d.UNEXPECTED_EMPTY_LINKED_KEY, l.lastStartLoc, 0);
|
|
587
|
+
const L = i.context(), N = _(7, L.offset, L.startLoc);
|
|
583
588
|
return N.value = "", u(N, L.offset, L.startLoc), E.key = N, u(E, L.offset, L.startLoc), {
|
|
584
589
|
nextConsumeToken: o,
|
|
585
590
|
node: E
|
|
586
591
|
};
|
|
587
592
|
}
|
|
588
593
|
}
|
|
589
|
-
return u(E,
|
|
594
|
+
return u(E, i.currentOffset(), i.currentPosition()), {
|
|
590
595
|
node: E
|
|
591
596
|
};
|
|
592
597
|
}
|
|
593
|
-
function R(
|
|
594
|
-
const l =
|
|
598
|
+
function R(i) {
|
|
599
|
+
const l = i.context(), E = l.currentType === 1 ? i.currentOffset() : l.offset, o = l.currentType === 1 ? l.endLoc : l.startLoc, L = _(2, E, o);
|
|
595
600
|
L.items = [];
|
|
596
601
|
let N = null;
|
|
597
602
|
do {
|
|
598
|
-
const
|
|
599
|
-
switch (N = null,
|
|
603
|
+
const y = N || i.nextToken();
|
|
604
|
+
switch (N = null, y.type) {
|
|
600
605
|
case 0:
|
|
601
|
-
|
|
606
|
+
y.value == null && a(i, d.UNEXPECTED_LEXICAL_ANALYSIS, l.lastStartLoc, 0, X(y)), L.items.push(h(i, y.value || ""));
|
|
602
607
|
break;
|
|
603
608
|
case 5:
|
|
604
|
-
|
|
609
|
+
y.value == null && a(i, d.UNEXPECTED_LEXICAL_ANALYSIS, l.lastStartLoc, 0, X(y)), L.items.push(I(i, y.value || ""));
|
|
605
610
|
break;
|
|
606
611
|
case 4:
|
|
607
|
-
|
|
612
|
+
y.value == null && a(i, d.UNEXPECTED_LEXICAL_ANALYSIS, l.lastStartLoc, 0, X(y)), L.items.push(D(i, y.value || ""));
|
|
608
613
|
break;
|
|
609
614
|
case 6:
|
|
610
|
-
|
|
615
|
+
y.value == null && a(i, d.UNEXPECTED_LEXICAL_ANALYSIS, l.lastStartLoc, 0, X(y)), L.items.push(m(i, y.value || ""));
|
|
611
616
|
break;
|
|
612
617
|
case 7: {
|
|
613
|
-
const
|
|
614
|
-
L.items.push(
|
|
618
|
+
const Y = T(i);
|
|
619
|
+
L.items.push(Y.node), N = Y.nextConsumeToken || null;
|
|
615
620
|
break;
|
|
616
621
|
}
|
|
617
622
|
}
|
|
618
623
|
} while (l.currentType !== 13 && l.currentType !== 1);
|
|
619
|
-
const p = l.currentType === 1 ? l.lastOffset :
|
|
620
|
-
return u(L, p,
|
|
624
|
+
const p = l.currentType === 1 ? l.lastOffset : i.currentOffset(), H = l.currentType === 1 ? l.lastEndLoc : i.currentPosition();
|
|
625
|
+
return u(L, p, H), L;
|
|
621
626
|
}
|
|
622
|
-
function v(
|
|
623
|
-
const L =
|
|
627
|
+
function v(i, l, E, o) {
|
|
628
|
+
const L = i.context();
|
|
624
629
|
let N = o.items.length === 0;
|
|
625
630
|
const p = _(1, l, E);
|
|
626
631
|
p.cases = [], p.cases.push(o);
|
|
627
632
|
do {
|
|
628
|
-
const
|
|
629
|
-
N || (N =
|
|
633
|
+
const H = R(i);
|
|
634
|
+
N || (N = H.items.length === 0), p.cases.push(H);
|
|
630
635
|
} while (L.currentType !== 13);
|
|
631
|
-
return N && a(
|
|
636
|
+
return N && a(i, d.MUST_HAVE_MESSAGES_IN_PLURAL, E, 0), u(p, i.currentOffset(), i.currentPosition()), p;
|
|
632
637
|
}
|
|
633
|
-
function A(
|
|
634
|
-
const l =
|
|
635
|
-
return l.currentType === 13 ? L : v(
|
|
638
|
+
function A(i) {
|
|
639
|
+
const l = i.context(), { offset: E, startLoc: o } = l, L = R(i);
|
|
640
|
+
return l.currentType === 13 ? L : v(i, E, o, L);
|
|
636
641
|
}
|
|
637
|
-
function C(
|
|
638
|
-
const l = ve(
|
|
639
|
-
return n && o.loc && (o.loc.source =
|
|
642
|
+
function C(i) {
|
|
643
|
+
const l = ve(i, re({}, r)), E = l.context(), o = _(0, E.offset, E.startLoc);
|
|
644
|
+
return n && o.loc && (o.loc.source = i), o.body = A(l), r.onCacheKey && (o.cacheKey = r.onCacheKey(i)), E.currentType !== 13 && a(l, d.UNEXPECTED_LEXICAL_ANALYSIS, E.lastStartLoc, 0, i[E.offset] || ""), u(o, l.currentOffset(), l.currentPosition()), o;
|
|
640
645
|
}
|
|
641
646
|
return { parse: C };
|
|
642
647
|
}
|
|
643
|
-
function
|
|
648
|
+
function X(r) {
|
|
644
649
|
if (r.type === 13)
|
|
645
650
|
return "EOF";
|
|
646
651
|
const n = (r.value || "").replace(/\r?\n/gu, "\\n");
|
|
647
652
|
return n.length > 10 ? n.slice(0, 9) + "…" : n;
|
|
648
653
|
}
|
|
649
|
-
function
|
|
654
|
+
function Ye(r, n = {}) {
|
|
650
655
|
const c = {
|
|
651
656
|
ast: r,
|
|
652
657
|
helpers: /* @__PURE__ */ new Set()
|
|
653
658
|
};
|
|
654
659
|
return { context: () => c, helper: (u) => (c.helpers.add(u), u) };
|
|
655
660
|
}
|
|
656
|
-
function
|
|
661
|
+
function te(r, n) {
|
|
657
662
|
for (let c = 0; c < r.length; c++)
|
|
658
663
|
W(r[c], n);
|
|
659
664
|
}
|
|
660
665
|
function W(r, n) {
|
|
661
666
|
switch (r.type) {
|
|
662
667
|
case 1:
|
|
663
|
-
|
|
668
|
+
te(r.cases, n), n.helper(
|
|
664
669
|
"plural"
|
|
665
670
|
/* HelperNameMap.PLURAL */
|
|
666
671
|
);
|
|
667
672
|
break;
|
|
668
673
|
case 2:
|
|
669
|
-
|
|
674
|
+
te(r.items, n);
|
|
670
675
|
break;
|
|
671
676
|
case 6: {
|
|
672
677
|
W(r.key, n), n.helper(
|
|
@@ -698,8 +703,8 @@ function W(r, n) {
|
|
|
698
703
|
break;
|
|
699
704
|
}
|
|
700
705
|
}
|
|
701
|
-
function
|
|
702
|
-
const c =
|
|
706
|
+
function ge(r, n = {}) {
|
|
707
|
+
const c = Ye(r);
|
|
703
708
|
c.helper(
|
|
704
709
|
"normalize"
|
|
705
710
|
/* HelperNameMap.NORMALIZE */
|
|
@@ -709,9 +714,9 @@ function He(r, n = {}) {
|
|
|
709
714
|
}
|
|
710
715
|
function Ke(r) {
|
|
711
716
|
const n = r.body;
|
|
712
|
-
return n.type === 2 ?
|
|
717
|
+
return n.type === 2 ? ne(n) : n.cases.forEach((c) => ne(c)), r;
|
|
713
718
|
}
|
|
714
|
-
function
|
|
719
|
+
function ne(r) {
|
|
715
720
|
if (r.items.length === 1) {
|
|
716
721
|
const n = r.items[0];
|
|
717
722
|
(n.type === 3 || n.type === 9) && (r.static = n.value, delete n.value);
|
|
@@ -724,7 +729,7 @@ function te(r) {
|
|
|
724
729
|
n.push(a.value);
|
|
725
730
|
}
|
|
726
731
|
if (n.length === r.items.length) {
|
|
727
|
-
r.static =
|
|
732
|
+
r.static = se(n);
|
|
728
733
|
for (let c = 0; c < r.items.length; c++) {
|
|
729
734
|
const a = r.items[c];
|
|
730
735
|
(a.type === 3 || a.type === 9) && delete a.value;
|
|
@@ -801,29 +806,29 @@ function Ge(r, n) {
|
|
|
801
806
|
};
|
|
802
807
|
u && r.loc && (h.source = r.loc.source);
|
|
803
808
|
const I = () => h;
|
|
804
|
-
function
|
|
809
|
+
function D(A, C) {
|
|
805
810
|
h.code += A;
|
|
806
811
|
}
|
|
807
|
-
function
|
|
808
|
-
const
|
|
809
|
-
|
|
812
|
+
function m(A, C = !0) {
|
|
813
|
+
const i = C ? a : "";
|
|
814
|
+
D(_ ? i + " ".repeat(A) : i);
|
|
810
815
|
}
|
|
811
816
|
function b(A = !0) {
|
|
812
817
|
const C = ++h.indentLevel;
|
|
813
|
-
A &&
|
|
818
|
+
A && m(C);
|
|
814
819
|
}
|
|
815
|
-
function
|
|
820
|
+
function S(A = !0) {
|
|
816
821
|
const C = --h.indentLevel;
|
|
817
|
-
A &&
|
|
822
|
+
A && m(C);
|
|
818
823
|
}
|
|
819
824
|
function T() {
|
|
820
|
-
|
|
825
|
+
m(h.indentLevel);
|
|
821
826
|
}
|
|
822
827
|
return {
|
|
823
828
|
context: I,
|
|
824
|
-
push:
|
|
829
|
+
push: D,
|
|
825
830
|
indent: b,
|
|
826
|
-
deindent:
|
|
831
|
+
deindent: S,
|
|
827
832
|
newline: T,
|
|
828
833
|
helper: (A) => `_${A}`,
|
|
829
834
|
needIndent: () => h.needIndent
|
|
@@ -917,7 +922,7 @@ function x(r, n) {
|
|
|
917
922
|
}
|
|
918
923
|
}
|
|
919
924
|
const qe = (r, n = {}) => {
|
|
920
|
-
const c =
|
|
925
|
+
const c = z(n.mode) ? n.mode : "normal", a = z(n.filename) ? n.filename : "message.intl";
|
|
921
926
|
n.sourceMap;
|
|
922
927
|
const _ = n.breakLineCode != null ? n.breakLineCode : c === "arrow" ? ";" : `
|
|
923
928
|
`, u = n.needIndent ? n.needIndent : c !== "arrow", h = r.helpers || [], I = Ge(r, {
|
|
@@ -925,18 +930,18 @@ const qe = (r, n = {}) => {
|
|
|
925
930
|
breakLineCode: _,
|
|
926
931
|
needIndent: u
|
|
927
932
|
});
|
|
928
|
-
I.push(c === "normal" ? "function __msg__ (ctx) {" : "(ctx) => {"), I.indent(u), h.length > 0 && (I.push(`const { ${
|
|
929
|
-
const { code:
|
|
933
|
+
I.push(c === "normal" ? "function __msg__ (ctx) {" : "(ctx) => {"), I.indent(u), h.length > 0 && (I.push(`const { ${se(h.map((b) => `${b}: _${b}`), ", ")} } = ctx`), I.newline()), I.push("return "), x(I, r), I.deindent(u), I.push("}"), delete r.helpers;
|
|
934
|
+
const { code: D, map: m } = I.context();
|
|
930
935
|
return {
|
|
931
936
|
ast: r,
|
|
932
|
-
code:
|
|
933
|
-
map:
|
|
937
|
+
code: D,
|
|
938
|
+
map: m ? m.toJSON() : void 0
|
|
934
939
|
// eslint-disable-line @typescript-eslint/no-explicit-any
|
|
935
940
|
};
|
|
936
941
|
};
|
|
937
942
|
function ze(r, n = {}) {
|
|
938
|
-
const c =
|
|
939
|
-
return a ? (u && Ke(I), _ && K(I), { ast: I, code: "" }) : (
|
|
943
|
+
const c = re({}, n), a = !!c.jit, _ = !!c.minify, u = c.optimize == null ? !0 : c.optimize, I = He(c).parse(r);
|
|
944
|
+
return a ? (u && Ke(I), _ && K(I), { ast: I, code: "" }) : (ge(I, c), qe(I, c));
|
|
940
945
|
}
|
|
941
946
|
export {
|
|
942
947
|
Je as C,
|