simple-web-lib 0.0.3 → 0.0.5
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/lib/components/simple-button/index.d.ts +8 -0
- package/lib/components/simple-button/src/SimpleButton.vue.d.ts +2 -0
- package/lib/components/simple-card/index.d.ts +8 -0
- package/lib/components/simple-card/src/SimpleCard.vue.d.ts +9 -0
- package/lib/index.d.ts +12 -0
- package/lib/locales/index.d.ts +20 -0
- package/lib/simple-web-lib.es.js +1458 -1549
- package/lib/simple-web-lib.umd.js +18 -18
- package/package.json +28 -19
package/lib/simple-web-lib.es.js
CHANGED
|
@@ -1,131 +1,111 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
const
|
|
1
|
+
import { defineComponent as ut, ref as Se, createElementBlock as Vn, openBlock as $n, toDisplayString as gt, createElementVNode as mt, renderSlot as Sr, effectScope as Pr, shallowRef as Wn, computed as me, watch as Rt, isRef as Dr, getCurrentInstance as st, h as Gn, Fragment as xn, inject as Rr, onBeforeMount as kr, onMounted as yr, onUnmounted as Mr, createVNode as Fr, Text as Ur } from "vue";
|
|
2
|
+
const wr = {
|
|
3
3
|
name: "SimpleButton"
|
|
4
|
-
},
|
|
5
|
-
...
|
|
4
|
+
}, Vr = /* @__PURE__ */ ut({
|
|
5
|
+
...wr,
|
|
6
6
|
setup(e) {
|
|
7
|
-
const t =
|
|
7
|
+
const t = Se(0), n = () => {
|
|
8
8
|
t.value++;
|
|
9
9
|
};
|
|
10
|
-
return (a, s) => (
|
|
10
|
+
return (a, s) => ($n(), Vn("button", {
|
|
11
11
|
class: "simple-button",
|
|
12
12
|
onClick: n
|
|
13
|
-
},
|
|
13
|
+
}, gt(a.$t("simpleButton.clickMe")) + " (" + gt(t.value) + ") ", 1));
|
|
14
14
|
}
|
|
15
|
-
}),
|
|
15
|
+
}), Hn = (e, t) => {
|
|
16
16
|
const n = e.__vccOpts || e;
|
|
17
17
|
for (const [a, s] of t)
|
|
18
18
|
n[a] = s;
|
|
19
19
|
return n;
|
|
20
|
-
},
|
|
21
|
-
function
|
|
22
|
-
e.component(
|
|
20
|
+
}, zt = /* @__PURE__ */ Hn(Vr, [["__scopeId", "data-v-916874a8"]]);
|
|
21
|
+
function $r(e) {
|
|
22
|
+
e.component(zt.name || "SimpleButton", zt);
|
|
23
23
|
}
|
|
24
|
-
const
|
|
25
|
-
install:
|
|
26
|
-
},
|
|
24
|
+
const Wr = {
|
|
25
|
+
install: $r
|
|
26
|
+
}, Gr = { class: "simple-card" }, xr = { class: "simple-card__header" }, Hr = { class: "simple-card__body" }, Yr = {
|
|
27
27
|
name: "SimpleCard"
|
|
28
|
-
},
|
|
29
|
-
...
|
|
28
|
+
}, Br = /* @__PURE__ */ ut({
|
|
29
|
+
...Yr,
|
|
30
30
|
setup(e) {
|
|
31
|
-
return (t, n) => (
|
|
32
|
-
|
|
33
|
-
|
|
31
|
+
return (t, n) => ($n(), Vn("div", Gr, [
|
|
32
|
+
mt("div", xr, [
|
|
33
|
+
mt("h3", null, gt(t.$t("simpleCard.title")), 1)
|
|
34
34
|
]),
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
35
|
+
mt("div", Hr, [
|
|
36
|
+
mt("p", null, gt(t.$t("simpleCard.content")), 1),
|
|
37
|
+
Sr(t.$slots, "default", {}, void 0, !0)
|
|
38
38
|
])
|
|
39
39
|
]));
|
|
40
40
|
}
|
|
41
|
-
}),
|
|
42
|
-
function
|
|
43
|
-
e.component(
|
|
41
|
+
}), en = /* @__PURE__ */ Hn(Br, [["__scopeId", "data-v-df720db0"]]);
|
|
42
|
+
function Xr(e) {
|
|
43
|
+
e.component(en.name || "SimpleCard", en);
|
|
44
44
|
}
|
|
45
|
-
const
|
|
46
|
-
install:
|
|
45
|
+
const jr = {
|
|
46
|
+
install: Xr
|
|
47
47
|
};
|
|
48
48
|
/*!
|
|
49
|
-
* shared v9.14.
|
|
50
|
-
* (c)
|
|
49
|
+
* shared v9.14.0
|
|
50
|
+
* (c) 2024 kazuya kawaguchi
|
|
51
51
|
* Released under the MIT License.
|
|
52
52
|
*/
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
}
|
|
56
|
-
const on = {};
|
|
57
|
-
function qn(e) {
|
|
58
|
-
on[e] || (on[e] = !0, Z(e));
|
|
59
|
-
}
|
|
60
|
-
const de = typeof window < "u";
|
|
61
|
-
let ie, ke;
|
|
53
|
+
const _e = typeof window < "u";
|
|
54
|
+
let oe, Pe;
|
|
62
55
|
if (process.env.NODE_ENV !== "production") {
|
|
63
|
-
const e =
|
|
56
|
+
const e = _e && window.performance;
|
|
64
57
|
e && e.mark && e.measure && e.clearMarks && // @ts-ignore browser compat
|
|
65
|
-
e.clearMeasures && (
|
|
58
|
+
e.clearMeasures && (oe = (t) => {
|
|
66
59
|
e.mark(t);
|
|
67
|
-
},
|
|
60
|
+
}, Pe = (t, n, a) => {
|
|
68
61
|
e.measure(t, n, a), e.clearMarks(n), e.clearMarks(a);
|
|
69
62
|
});
|
|
70
63
|
}
|
|
71
|
-
const
|
|
72
|
-
function
|
|
73
|
-
return t.length === 1 &&
|
|
64
|
+
const Kr = /\{([0-9a-zA-Z]+)\}/g;
|
|
65
|
+
function Ht(e, ...t) {
|
|
66
|
+
return t.length === 1 && $(t[0]) && (t = t[0]), (!t || !t.hasOwnProperty) && (t = {}), e.replace(Kr, (n, a) => t.hasOwnProperty(a) ? t[a] : "");
|
|
74
67
|
}
|
|
75
|
-
const
|
|
76
|
-
let
|
|
77
|
-
const
|
|
78
|
-
function
|
|
79
|
-
return e.replace(
|
|
68
|
+
const Ee = (e, t = !1) => t ? Symbol.for(e) : Symbol(e), Jr = (e, t, n) => Qr({ l: e, k: t, s: n }), Qr = (e) => JSON.stringify(e).replace(/\u2028/g, "\\u2028").replace(/\u2029/g, "\\u2029").replace(/\u0027/g, "\\u0027"), Q = (e) => typeof e == "number" && isFinite(e), qr = (e) => Bn(e) === "[object Date]", Le = (e) => Bn(e) === "[object RegExp]", Ot = (e) => F(e) && Object.keys(e).length === 0, ee = Object.assign;
|
|
69
|
+
let tn;
|
|
70
|
+
const pe = () => tn || (tn = typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : typeof global < "u" ? global : {});
|
|
71
|
+
function nn(e) {
|
|
72
|
+
return e.replace(/</g, "<").replace(/>/g, ">").replace(/"/g, """).replace(/'/g, "'");
|
|
80
73
|
}
|
|
81
|
-
|
|
82
|
-
|
|
74
|
+
const Zr = Object.prototype.hasOwnProperty;
|
|
75
|
+
function Nt(e, t) {
|
|
76
|
+
return Zr.call(e, t);
|
|
83
77
|
}
|
|
84
|
-
function
|
|
85
|
-
|
|
86
|
-
// In href, src, action, formaction attributes
|
|
87
|
-
/(\s+(?:href|src|action|formaction)\s*=\s*["']?)\s*javascript:/gi,
|
|
88
|
-
// In style attributes within url()
|
|
89
|
-
/(style\s*=\s*["'][^"']*url\s*\(\s*)javascript:/gi
|
|
90
|
-
].forEach((a) => {
|
|
91
|
-
e = e.replace(a, "$1javascript:");
|
|
92
|
-
}), e;
|
|
93
|
-
}
|
|
94
|
-
const ga = Object.prototype.hasOwnProperty;
|
|
95
|
-
function me(e, t) {
|
|
96
|
-
return ga.call(e, t);
|
|
97
|
-
}
|
|
98
|
-
const K = Array.isArray, x = (e) => typeof e == "function", h = (e) => typeof e == "string", U = (e) => typeof e == "boolean", V = (e) => e !== null && typeof e == "object", Na = (e) => V(e) && x(e.then) && x(e.catch), Zn = Object.prototype.toString, zn = (e) => Zn.call(e), F = (e) => {
|
|
99
|
-
if (!V(e))
|
|
78
|
+
const X = Array.isArray, H = (e) => typeof e == "function", A = (e) => typeof e == "string", U = (e) => typeof e == "boolean", $ = (e) => e !== null && typeof e == "object", zr = (e) => $(e) && H(e.then) && H(e.catch), Yn = Object.prototype.toString, Bn = (e) => Yn.call(e), F = (e) => {
|
|
79
|
+
if (!$(e))
|
|
100
80
|
return !1;
|
|
101
81
|
const t = Object.getPrototypeOf(e);
|
|
102
82
|
return t === null || t.constructor === Object;
|
|
103
|
-
},
|
|
104
|
-
function
|
|
83
|
+
}, ea = (e) => e == null ? "" : X(e) || F(e) && e.toString === Yn ? JSON.stringify(e, null, 2) : String(e);
|
|
84
|
+
function ta(e, t = "") {
|
|
105
85
|
return e.reduce((n, a, s) => s === 0 ? n + a : n + t + a, "");
|
|
106
86
|
}
|
|
107
|
-
const
|
|
108
|
-
function
|
|
87
|
+
const rn = 2;
|
|
88
|
+
function na(e, t = 0, n = e.length) {
|
|
109
89
|
const a = e.split(/\r?\n/);
|
|
110
90
|
let s = 0;
|
|
111
91
|
const r = [];
|
|
112
92
|
for (let l = 0; l < a.length; l++)
|
|
113
93
|
if (s += a[l].length + 1, s >= t) {
|
|
114
|
-
for (let
|
|
115
|
-
if (
|
|
94
|
+
for (let i = l - rn; i <= l + rn || n > s; i++) {
|
|
95
|
+
if (i < 0 || i >= a.length)
|
|
116
96
|
continue;
|
|
117
|
-
const u =
|
|
118
|
-
r.push(`${u}${" ".repeat(3 - String(u).length)}| ${a[
|
|
119
|
-
const
|
|
120
|
-
if (
|
|
121
|
-
const p = t - (s -
|
|
97
|
+
const u = i + 1;
|
|
98
|
+
r.push(`${u}${" ".repeat(3 - String(u).length)}| ${a[i]}`);
|
|
99
|
+
const f = a[i].length;
|
|
100
|
+
if (i === l) {
|
|
101
|
+
const p = t - (s - f) + 1, T = Math.max(1, n > s ? f - p : n - t);
|
|
122
102
|
r.push(" | " + " ".repeat(p) + "^".repeat(T));
|
|
123
|
-
} else if (
|
|
103
|
+
} else if (i > l) {
|
|
124
104
|
if (n > s) {
|
|
125
|
-
const p = Math.max(Math.min(n - s,
|
|
105
|
+
const p = Math.max(Math.min(n - s, f), 1);
|
|
126
106
|
r.push(" | " + "^".repeat(p));
|
|
127
107
|
}
|
|
128
|
-
s +=
|
|
108
|
+
s += f + 1;
|
|
129
109
|
}
|
|
130
110
|
}
|
|
131
111
|
break;
|
|
@@ -133,11 +113,18 @@ function Oa(e, t = 0, n = e.length) {
|
|
|
133
113
|
return r.join(`
|
|
134
114
|
`);
|
|
135
115
|
}
|
|
136
|
-
function
|
|
116
|
+
function Lt(e) {
|
|
137
117
|
let t = e;
|
|
138
118
|
return () => ++t;
|
|
139
119
|
}
|
|
140
|
-
function
|
|
120
|
+
function q(e, t) {
|
|
121
|
+
typeof console < "u" && (console.warn("[intlify] " + e), t && console.warn(t.stack));
|
|
122
|
+
}
|
|
123
|
+
const an = {};
|
|
124
|
+
function Xn(e) {
|
|
125
|
+
an[e] || (an[e] = !0, q(e));
|
|
126
|
+
}
|
|
127
|
+
function Yt() {
|
|
141
128
|
const e = /* @__PURE__ */ new Map();
|
|
142
129
|
return {
|
|
143
130
|
events: e,
|
|
@@ -154,45 +141,45 @@ function Jt() {
|
|
|
154
141
|
}
|
|
155
142
|
};
|
|
156
143
|
}
|
|
157
|
-
const
|
|
158
|
-
function
|
|
159
|
-
if (
|
|
144
|
+
const dt = (e) => !$(e) || X(e);
|
|
145
|
+
function Et(e, t) {
|
|
146
|
+
if (dt(e) || dt(t))
|
|
160
147
|
throw new Error("Invalid value");
|
|
161
148
|
const n = [{ src: e, des: t }];
|
|
162
149
|
for (; n.length; ) {
|
|
163
150
|
const { src: a, des: s } = n.pop();
|
|
164
151
|
Object.keys(a).forEach((r) => {
|
|
165
|
-
|
|
152
|
+
dt(a[r]) || dt(s[r]) ? s[r] = a[r] : n.push({ src: a[r], des: s[r] });
|
|
166
153
|
});
|
|
167
154
|
}
|
|
168
155
|
}
|
|
169
156
|
/*!
|
|
170
|
-
* message-compiler v9.14.
|
|
171
|
-
* (c)
|
|
157
|
+
* message-compiler v9.14.0
|
|
158
|
+
* (c) 2024 kazuya kawaguchi
|
|
172
159
|
* Released under the MIT License.
|
|
173
160
|
*/
|
|
174
|
-
function
|
|
161
|
+
function ra(e, t, n) {
|
|
175
162
|
return { line: e, column: t, offset: n };
|
|
176
163
|
}
|
|
177
|
-
function
|
|
164
|
+
function pt(e, t, n) {
|
|
178
165
|
return { start: e, end: t };
|
|
179
166
|
}
|
|
180
|
-
const
|
|
181
|
-
function
|
|
182
|
-
return t.length === 1 &&
|
|
167
|
+
const aa = /\{([0-9a-zA-Z]+)\}/g;
|
|
168
|
+
function jn(e, ...t) {
|
|
169
|
+
return t.length === 1 && sa(t[0]) && (t = t[0]), (!t || !t.hasOwnProperty) && (t = {}), e.replace(aa, (n, a) => t.hasOwnProperty(a) ? t[a] : "");
|
|
183
170
|
}
|
|
184
|
-
const
|
|
185
|
-
function
|
|
171
|
+
const Kn = Object.assign, sn = (e) => typeof e == "string", sa = (e) => e !== null && typeof e == "object";
|
|
172
|
+
function Jn(e, t = "") {
|
|
186
173
|
return e.reduce((n, a, s) => s === 0 ? n + a : n + t + a, "");
|
|
187
174
|
}
|
|
188
|
-
const
|
|
175
|
+
const vt = {
|
|
189
176
|
USE_MODULO_SYNTAX: 1,
|
|
190
177
|
__EXTEND_POINT__: 2
|
|
191
|
-
},
|
|
192
|
-
[
|
|
178
|
+
}, la = {
|
|
179
|
+
[vt.USE_MODULO_SYNTAX]: "Use modulo before '{{0}}'."
|
|
193
180
|
};
|
|
194
|
-
function
|
|
195
|
-
const a =
|
|
181
|
+
function oa(e, t, ...n) {
|
|
182
|
+
const a = jn(la[e], ...n || []), s = { message: String(a), code: e };
|
|
196
183
|
return t && (s.location = t), s;
|
|
197
184
|
}
|
|
198
185
|
const M = {
|
|
@@ -220,7 +207,7 @@ const M = {
|
|
|
220
207
|
// to avoid collision of error codes. This should always be kept as the last
|
|
221
208
|
// item.
|
|
222
209
|
__EXTEND_POINT__: 17
|
|
223
|
-
},
|
|
210
|
+
}, ia = {
|
|
224
211
|
// tokenizer error messages
|
|
225
212
|
[M.EXPECTED_TOKEN]: "Expected token: '{0}'",
|
|
226
213
|
[M.INVALID_TOKEN_IN_PLACEHOLDER]: "Invalid token in placeholder: '{0}'",
|
|
@@ -242,23 +229,23 @@ const M = {
|
|
|
242
229
|
// minimizer error messages
|
|
243
230
|
[M.UNHANDLED_MINIFIER_NODE_TYPE]: "unhandled mimifier node type: '{0}'"
|
|
244
231
|
};
|
|
245
|
-
function
|
|
246
|
-
const { domain: a, messages: s, args: r } = n, l =
|
|
247
|
-
return
|
|
232
|
+
function Ge(e, t, n = {}) {
|
|
233
|
+
const { domain: a, messages: s, args: r } = n, l = jn((s || ia)[e] || "", ...r || []), i = new SyntaxError(String(l));
|
|
234
|
+
return i.code = e, t && (i.location = t), i.domain = a, i;
|
|
248
235
|
}
|
|
249
|
-
function
|
|
236
|
+
function ca(e) {
|
|
250
237
|
throw e;
|
|
251
238
|
}
|
|
252
|
-
const
|
|
253
|
-
`,
|
|
254
|
-
function
|
|
239
|
+
const ua = /<\/?[\w\s="/.':;#-\/]+>/, _a = (e) => ua.test(e), ge = " ", fa = "\r", ne = `
|
|
240
|
+
`, ma = "\u2028", da = "\u2029";
|
|
241
|
+
function Ea(e) {
|
|
255
242
|
const t = e;
|
|
256
243
|
let n = 0, a = 1, s = 1, r = 0;
|
|
257
|
-
const l = (v) => t[v] ===
|
|
244
|
+
const l = (v) => t[v] === fa && t[v + 1] === ne, i = (v) => t[v] === ne, u = (v) => t[v] === da, f = (v) => t[v] === ma, p = (v) => l(v) || i(v) || u(v) || f(v), T = () => n, d = () => a, h = () => s, D = () => r, S = (v) => l(v) || u(v) || f(v) ? ne : t[v], P = () => S(n), y = () => S(n + r);
|
|
258
245
|
function R() {
|
|
259
246
|
return r = 0, p(n) && (a++, s = 0), l(n) && n++, n++, s++, t[n];
|
|
260
247
|
}
|
|
261
|
-
function
|
|
248
|
+
function _() {
|
|
262
249
|
return l(n + r) && r++, r++, t[n + r];
|
|
263
250
|
}
|
|
264
251
|
function E() {
|
|
@@ -276,174 +263,174 @@ function ya(e) {
|
|
|
276
263
|
return {
|
|
277
264
|
index: T,
|
|
278
265
|
line: d,
|
|
279
|
-
column:
|
|
266
|
+
column: h,
|
|
280
267
|
peekOffset: D,
|
|
281
|
-
charAt:
|
|
282
|
-
currentChar:
|
|
268
|
+
charAt: S,
|
|
269
|
+
currentChar: P,
|
|
283
270
|
currentPeek: y,
|
|
284
271
|
next: R,
|
|
285
|
-
peek:
|
|
272
|
+
peek: _,
|
|
286
273
|
reset: E,
|
|
287
274
|
resetPeek: L,
|
|
288
275
|
skipToPeek: g
|
|
289
276
|
};
|
|
290
277
|
}
|
|
291
|
-
const
|
|
292
|
-
function
|
|
293
|
-
const n = t.location !== !1, a =
|
|
278
|
+
const Oe = void 0, ga = ".", ln = "'", Na = "tokenizer";
|
|
279
|
+
function pa(e, t = {}) {
|
|
280
|
+
const n = t.location !== !1, a = Ea(e), s = () => a.index(), r = () => ra(a.line(), a.column(), a.index()), l = r(), i = s(), u = {
|
|
294
281
|
currentType: 14,
|
|
295
|
-
offset:
|
|
282
|
+
offset: i,
|
|
296
283
|
startLoc: l,
|
|
297
284
|
endLoc: l,
|
|
298
285
|
lastType: 14,
|
|
299
|
-
lastOffset:
|
|
286
|
+
lastOffset: i,
|
|
300
287
|
lastStartLoc: l,
|
|
301
288
|
lastEndLoc: l,
|
|
302
289
|
braceNest: 0,
|
|
303
290
|
inLinked: !1,
|
|
304
291
|
text: ""
|
|
305
|
-
},
|
|
306
|
-
function T(
|
|
307
|
-
const
|
|
292
|
+
}, f = () => u, { onError: p } = t;
|
|
293
|
+
function T(o, c, N, ...k) {
|
|
294
|
+
const j = f();
|
|
308
295
|
if (c.column += N, c.offset += N, p) {
|
|
309
|
-
const
|
|
310
|
-
domain:
|
|
296
|
+
const Y = n ? pt(j.startLoc, c) : null, x = Ge(o, Y, {
|
|
297
|
+
domain: Na,
|
|
311
298
|
args: k
|
|
312
299
|
});
|
|
313
|
-
p(
|
|
300
|
+
p(x);
|
|
314
301
|
}
|
|
315
302
|
}
|
|
316
|
-
function d(
|
|
317
|
-
|
|
303
|
+
function d(o, c, N) {
|
|
304
|
+
o.endLoc = r(), o.currentType = c;
|
|
318
305
|
const k = { type: c };
|
|
319
|
-
return n && (k.loc =
|
|
306
|
+
return n && (k.loc = pt(o.startLoc, o.endLoc)), N != null && (k.value = N), k;
|
|
320
307
|
}
|
|
321
|
-
const
|
|
322
|
-
|
|
308
|
+
const h = (o) => d(
|
|
309
|
+
o,
|
|
323
310
|
14
|
|
324
311
|
/* TokenTypes.EOF */
|
|
325
312
|
);
|
|
326
|
-
function D(
|
|
327
|
-
return
|
|
313
|
+
function D(o, c) {
|
|
314
|
+
return o.currentChar() === c ? (o.next(), c) : (T(M.EXPECTED_TOKEN, r(), 0, c), "");
|
|
328
315
|
}
|
|
329
|
-
function
|
|
316
|
+
function S(o) {
|
|
330
317
|
let c = "";
|
|
331
|
-
for (;
|
|
332
|
-
c +=
|
|
318
|
+
for (; o.currentPeek() === ge || o.currentPeek() === ne; )
|
|
319
|
+
c += o.currentPeek(), o.peek();
|
|
333
320
|
return c;
|
|
334
321
|
}
|
|
335
|
-
function
|
|
336
|
-
const c =
|
|
337
|
-
return
|
|
322
|
+
function P(o) {
|
|
323
|
+
const c = S(o);
|
|
324
|
+
return o.skipToPeek(), c;
|
|
338
325
|
}
|
|
339
|
-
function y(
|
|
340
|
-
if (
|
|
326
|
+
function y(o) {
|
|
327
|
+
if (o === Oe)
|
|
341
328
|
return !1;
|
|
342
|
-
const c =
|
|
329
|
+
const c = o.charCodeAt(0);
|
|
343
330
|
return c >= 97 && c <= 122 || // a-z
|
|
344
331
|
c >= 65 && c <= 90 || // A-Z
|
|
345
332
|
c === 95;
|
|
346
333
|
}
|
|
347
|
-
function R(
|
|
348
|
-
if (
|
|
334
|
+
function R(o) {
|
|
335
|
+
if (o === Oe)
|
|
349
336
|
return !1;
|
|
350
|
-
const c =
|
|
337
|
+
const c = o.charCodeAt(0);
|
|
351
338
|
return c >= 48 && c <= 57;
|
|
352
339
|
}
|
|
353
|
-
function
|
|
340
|
+
function _(o, c) {
|
|
354
341
|
const { currentType: N } = c;
|
|
355
342
|
if (N !== 2)
|
|
356
343
|
return !1;
|
|
357
|
-
|
|
358
|
-
const k = y(
|
|
359
|
-
return
|
|
344
|
+
S(o);
|
|
345
|
+
const k = y(o.currentPeek());
|
|
346
|
+
return o.resetPeek(), k;
|
|
360
347
|
}
|
|
361
|
-
function E(
|
|
348
|
+
function E(o, c) {
|
|
362
349
|
const { currentType: N } = c;
|
|
363
350
|
if (N !== 2)
|
|
364
351
|
return !1;
|
|
365
|
-
|
|
366
|
-
const k =
|
|
367
|
-
return
|
|
352
|
+
S(o);
|
|
353
|
+
const k = o.currentPeek() === "-" ? o.peek() : o.currentPeek(), j = R(k);
|
|
354
|
+
return o.resetPeek(), j;
|
|
368
355
|
}
|
|
369
|
-
function L(
|
|
356
|
+
function L(o, c) {
|
|
370
357
|
const { currentType: N } = c;
|
|
371
358
|
if (N !== 2)
|
|
372
359
|
return !1;
|
|
373
|
-
|
|
374
|
-
const k =
|
|
375
|
-
return
|
|
360
|
+
S(o);
|
|
361
|
+
const k = o.currentPeek() === ln;
|
|
362
|
+
return o.resetPeek(), k;
|
|
376
363
|
}
|
|
377
|
-
function g(
|
|
364
|
+
function g(o, c) {
|
|
378
365
|
const { currentType: N } = c;
|
|
379
366
|
if (N !== 8)
|
|
380
367
|
return !1;
|
|
381
|
-
|
|
382
|
-
const k =
|
|
383
|
-
return
|
|
368
|
+
S(o);
|
|
369
|
+
const k = o.currentPeek() === ".";
|
|
370
|
+
return o.resetPeek(), k;
|
|
384
371
|
}
|
|
385
|
-
function v(
|
|
372
|
+
function v(o, c) {
|
|
386
373
|
const { currentType: N } = c;
|
|
387
374
|
if (N !== 9)
|
|
388
375
|
return !1;
|
|
389
|
-
|
|
390
|
-
const k = y(
|
|
391
|
-
return
|
|
376
|
+
S(o);
|
|
377
|
+
const k = y(o.currentPeek());
|
|
378
|
+
return o.resetPeek(), k;
|
|
392
379
|
}
|
|
393
|
-
function C(
|
|
380
|
+
function C(o, c) {
|
|
394
381
|
const { currentType: N } = c;
|
|
395
382
|
if (!(N === 8 || N === 12))
|
|
396
383
|
return !1;
|
|
397
|
-
|
|
398
|
-
const k =
|
|
399
|
-
return
|
|
384
|
+
S(o);
|
|
385
|
+
const k = o.currentPeek() === ":";
|
|
386
|
+
return o.resetPeek(), k;
|
|
400
387
|
}
|
|
401
|
-
function I(
|
|
388
|
+
function I(o, c) {
|
|
402
389
|
const { currentType: N } = c;
|
|
403
390
|
if (N !== 10)
|
|
404
391
|
return !1;
|
|
405
392
|
const k = () => {
|
|
406
|
-
const
|
|
407
|
-
return
|
|
408
|
-
},
|
|
409
|
-
return
|
|
410
|
-
}
|
|
411
|
-
function
|
|
412
|
-
|
|
413
|
-
const c =
|
|
414
|
-
return
|
|
415
|
-
}
|
|
416
|
-
function
|
|
417
|
-
const c =
|
|
418
|
-
return
|
|
393
|
+
const Y = o.currentPeek();
|
|
394
|
+
return Y === "{" ? y(o.peek()) : Y === "@" || Y === "%" || Y === "|" || Y === ":" || Y === "." || Y === ge || !Y ? !1 : Y === ne ? (o.peek(), k()) : w(o, !1);
|
|
395
|
+
}, j = k();
|
|
396
|
+
return o.resetPeek(), j;
|
|
397
|
+
}
|
|
398
|
+
function B(o) {
|
|
399
|
+
S(o);
|
|
400
|
+
const c = o.currentPeek() === "|";
|
|
401
|
+
return o.resetPeek(), c;
|
|
402
|
+
}
|
|
403
|
+
function le(o) {
|
|
404
|
+
const c = S(o), N = o.currentPeek() === "%" && o.peek() === "{";
|
|
405
|
+
return o.resetPeek(), {
|
|
419
406
|
isModulo: N,
|
|
420
407
|
hasSpace: c.length > 0
|
|
421
408
|
};
|
|
422
409
|
}
|
|
423
|
-
function w(
|
|
424
|
-
const N = (
|
|
425
|
-
const m =
|
|
426
|
-
return m === "{" ?
|
|
410
|
+
function w(o, c = !0) {
|
|
411
|
+
const N = (j = !1, Y = "", x = !1) => {
|
|
412
|
+
const m = o.currentPeek();
|
|
413
|
+
return m === "{" ? Y === "%" ? !1 : j : m === "@" || !m ? Y === "%" ? !0 : j : m === "%" ? (o.peek(), N(j, "%", !0)) : m === "|" ? Y === "%" || x ? !0 : !(Y === ge || Y === ne) : m === ge ? (o.peek(), N(!0, ge, x)) : m === ne ? (o.peek(), N(!0, ne, x)) : !0;
|
|
427
414
|
}, k = N();
|
|
428
|
-
return c &&
|
|
415
|
+
return c && o.resetPeek(), k;
|
|
429
416
|
}
|
|
430
|
-
function
|
|
431
|
-
const N =
|
|
432
|
-
return N ===
|
|
417
|
+
function te(o, c) {
|
|
418
|
+
const N = o.currentChar();
|
|
419
|
+
return N === Oe ? Oe : c(N) ? (o.next(), N) : null;
|
|
433
420
|
}
|
|
434
|
-
function
|
|
435
|
-
const c =
|
|
421
|
+
function xe(o) {
|
|
422
|
+
const c = o.charCodeAt(0);
|
|
436
423
|
return c >= 97 && c <= 122 || // a-z
|
|
437
424
|
c >= 65 && c <= 90 || // A-Z
|
|
438
425
|
c >= 48 && c <= 57 || // 0-9
|
|
439
426
|
c === 95 || // _
|
|
440
427
|
c === 36;
|
|
441
428
|
}
|
|
442
|
-
function
|
|
443
|
-
return
|
|
429
|
+
function He(o) {
|
|
430
|
+
return te(o, xe);
|
|
444
431
|
}
|
|
445
|
-
function
|
|
446
|
-
const c =
|
|
432
|
+
function fe(o) {
|
|
433
|
+
const c = o.charCodeAt(0);
|
|
447
434
|
return c >= 97 && c <= 122 || // a-z
|
|
448
435
|
c >= 65 && c <= 90 || // A-Z
|
|
449
436
|
c >= 48 && c <= 57 || // 0-9
|
|
@@ -451,261 +438,261 @@ function Ua(e, t = {}) {
|
|
|
451
438
|
c === 36 || // $
|
|
452
439
|
c === 45;
|
|
453
440
|
}
|
|
454
|
-
function
|
|
455
|
-
return
|
|
441
|
+
function Ye(o) {
|
|
442
|
+
return te(o, fe);
|
|
456
443
|
}
|
|
457
|
-
function
|
|
458
|
-
const c =
|
|
444
|
+
function Be(o) {
|
|
445
|
+
const c = o.charCodeAt(0);
|
|
459
446
|
return c >= 48 && c <= 57;
|
|
460
447
|
}
|
|
461
|
-
function
|
|
462
|
-
return
|
|
448
|
+
function Xe(o) {
|
|
449
|
+
return te(o, Be);
|
|
463
450
|
}
|
|
464
|
-
function
|
|
465
|
-
const c =
|
|
451
|
+
function je(o) {
|
|
452
|
+
const c = o.charCodeAt(0);
|
|
466
453
|
return c >= 48 && c <= 57 || // 0-9
|
|
467
454
|
c >= 65 && c <= 70 || // A-F
|
|
468
455
|
c >= 97 && c <= 102;
|
|
469
456
|
}
|
|
470
|
-
function
|
|
471
|
-
return
|
|
457
|
+
function Ke(o) {
|
|
458
|
+
return te(o, je);
|
|
472
459
|
}
|
|
473
|
-
function
|
|
460
|
+
function ie(o) {
|
|
474
461
|
let c = "", N = "";
|
|
475
|
-
for (; c =
|
|
462
|
+
for (; c = Xe(o); )
|
|
476
463
|
N += c;
|
|
477
464
|
return N;
|
|
478
465
|
}
|
|
479
|
-
function
|
|
480
|
-
|
|
481
|
-
const c =
|
|
482
|
-
return c !== "%" && T(M.EXPECTED_TOKEN, r(), 0, c),
|
|
466
|
+
function ke(o) {
|
|
467
|
+
P(o);
|
|
468
|
+
const c = o.currentChar();
|
|
469
|
+
return c !== "%" && T(M.EXPECTED_TOKEN, r(), 0, c), o.next(), "%";
|
|
483
470
|
}
|
|
484
|
-
function
|
|
471
|
+
function ye(o) {
|
|
485
472
|
let c = "";
|
|
486
473
|
for (; ; ) {
|
|
487
|
-
const N =
|
|
474
|
+
const N = o.currentChar();
|
|
488
475
|
if (N === "{" || N === "}" || N === "@" || N === "|" || !N)
|
|
489
476
|
break;
|
|
490
477
|
if (N === "%")
|
|
491
|
-
if (w(
|
|
492
|
-
c += N,
|
|
478
|
+
if (w(o))
|
|
479
|
+
c += N, o.next();
|
|
493
480
|
else
|
|
494
481
|
break;
|
|
495
|
-
else if (N ===
|
|
496
|
-
if (w(
|
|
497
|
-
c += N,
|
|
482
|
+
else if (N === ge || N === ne)
|
|
483
|
+
if (w(o))
|
|
484
|
+
c += N, o.next();
|
|
498
485
|
else {
|
|
499
|
-
if (
|
|
486
|
+
if (B(o))
|
|
500
487
|
break;
|
|
501
|
-
c += N,
|
|
488
|
+
c += N, o.next();
|
|
502
489
|
}
|
|
503
490
|
else
|
|
504
|
-
c += N,
|
|
491
|
+
c += N, o.next();
|
|
505
492
|
}
|
|
506
493
|
return c;
|
|
507
494
|
}
|
|
508
|
-
function
|
|
509
|
-
|
|
495
|
+
function Je(o) {
|
|
496
|
+
P(o);
|
|
510
497
|
let c = "", N = "";
|
|
511
|
-
for (; c =
|
|
498
|
+
for (; c = Ye(o); )
|
|
512
499
|
N += c;
|
|
513
|
-
return
|
|
500
|
+
return o.currentChar() === Oe && T(M.UNTERMINATED_CLOSING_BRACE, r(), 0), N;
|
|
514
501
|
}
|
|
515
|
-
function
|
|
516
|
-
|
|
502
|
+
function Qe(o) {
|
|
503
|
+
P(o);
|
|
517
504
|
let c = "";
|
|
518
|
-
return
|
|
505
|
+
return o.currentChar() === "-" ? (o.next(), c += `-${ie(o)}`) : c += ie(o), o.currentChar() === Oe && T(M.UNTERMINATED_CLOSING_BRACE, r(), 0), c;
|
|
519
506
|
}
|
|
520
|
-
function
|
|
521
|
-
return
|
|
507
|
+
function qe(o) {
|
|
508
|
+
return o !== ln && o !== ne;
|
|
522
509
|
}
|
|
523
|
-
function
|
|
524
|
-
|
|
510
|
+
function _t(o) {
|
|
511
|
+
P(o), D(o, "'");
|
|
525
512
|
let c = "", N = "";
|
|
526
|
-
for (; c =
|
|
527
|
-
c === "\\" ? N +=
|
|
528
|
-
const k =
|
|
529
|
-
return k ===
|
|
513
|
+
for (; c = te(o, qe); )
|
|
514
|
+
c === "\\" ? N += Ze(o) : N += c;
|
|
515
|
+
const k = o.currentChar();
|
|
516
|
+
return k === ne || k === Oe ? (T(M.UNTERMINATED_SINGLE_QUOTE_IN_PLACEHOLDER, r(), 0), k === ne && (o.next(), D(o, "'")), N) : (D(o, "'"), N);
|
|
530
517
|
}
|
|
531
|
-
function
|
|
532
|
-
const c =
|
|
518
|
+
function Ze(o) {
|
|
519
|
+
const c = o.currentChar();
|
|
533
520
|
switch (c) {
|
|
534
521
|
case "\\":
|
|
535
522
|
case "'":
|
|
536
|
-
return
|
|
523
|
+
return o.next(), `\\${c}`;
|
|
537
524
|
case "u":
|
|
538
|
-
return
|
|
525
|
+
return Me(o, c, 4);
|
|
539
526
|
case "U":
|
|
540
|
-
return
|
|
527
|
+
return Me(o, c, 6);
|
|
541
528
|
default:
|
|
542
529
|
return T(M.UNKNOWN_ESCAPE_SEQUENCE, r(), 0, c), "";
|
|
543
530
|
}
|
|
544
531
|
}
|
|
545
|
-
function
|
|
546
|
-
D(
|
|
532
|
+
function Me(o, c, N) {
|
|
533
|
+
D(o, c);
|
|
547
534
|
let k = "";
|
|
548
|
-
for (let
|
|
549
|
-
const
|
|
550
|
-
if (!
|
|
551
|
-
T(M.INVALID_UNICODE_ESCAPE_SEQUENCE, r(), 0, `\\${c}${k}${
|
|
535
|
+
for (let j = 0; j < N; j++) {
|
|
536
|
+
const Y = Ke(o);
|
|
537
|
+
if (!Y) {
|
|
538
|
+
T(M.INVALID_UNICODE_ESCAPE_SEQUENCE, r(), 0, `\\${c}${k}${o.currentChar()}`);
|
|
552
539
|
break;
|
|
553
540
|
}
|
|
554
|
-
k +=
|
|
541
|
+
k += Y;
|
|
555
542
|
}
|
|
556
543
|
return `\\${c}${k}`;
|
|
557
544
|
}
|
|
558
|
-
function
|
|
559
|
-
return
|
|
545
|
+
function ze(o) {
|
|
546
|
+
return o !== "{" && o !== "}" && o !== ge && o !== ne;
|
|
560
547
|
}
|
|
561
|
-
function
|
|
562
|
-
|
|
548
|
+
function et(o) {
|
|
549
|
+
P(o);
|
|
563
550
|
let c = "", N = "";
|
|
564
|
-
for (; c =
|
|
551
|
+
for (; c = te(o, ze); )
|
|
565
552
|
N += c;
|
|
566
553
|
return N;
|
|
567
554
|
}
|
|
568
|
-
function
|
|
555
|
+
function tt(o) {
|
|
569
556
|
let c = "", N = "";
|
|
570
|
-
for (; c =
|
|
557
|
+
for (; c = He(o); )
|
|
571
558
|
N += c;
|
|
572
559
|
return N;
|
|
573
560
|
}
|
|
574
|
-
function b(
|
|
561
|
+
function b(o) {
|
|
575
562
|
const c = (N) => {
|
|
576
|
-
const k =
|
|
577
|
-
return k === "{" || k === "%" || k === "@" || k === "|" || k === "(" || k === ")" || !k || k ===
|
|
563
|
+
const k = o.currentChar();
|
|
564
|
+
return k === "{" || k === "%" || k === "@" || k === "|" || k === "(" || k === ")" || !k || k === ge ? N : (N += k, o.next(), c(N));
|
|
578
565
|
};
|
|
579
566
|
return c("");
|
|
580
567
|
}
|
|
581
|
-
function W(
|
|
582
|
-
|
|
568
|
+
function W(o) {
|
|
569
|
+
P(o);
|
|
583
570
|
const c = D(
|
|
584
|
-
|
|
571
|
+
o,
|
|
585
572
|
"|"
|
|
586
573
|
/* TokenChars.Pipe */
|
|
587
574
|
);
|
|
588
|
-
return
|
|
575
|
+
return P(o), c;
|
|
589
576
|
}
|
|
590
|
-
function
|
|
577
|
+
function nt(o, c) {
|
|
591
578
|
let N = null;
|
|
592
|
-
switch (
|
|
579
|
+
switch (o.currentChar()) {
|
|
593
580
|
case "{":
|
|
594
|
-
return c.braceNest >= 1 && T(M.NOT_ALLOW_NEST_PLACEHOLDER, r(), 0),
|
|
581
|
+
return c.braceNest >= 1 && T(M.NOT_ALLOW_NEST_PLACEHOLDER, r(), 0), o.next(), N = d(
|
|
595
582
|
c,
|
|
596
583
|
2,
|
|
597
584
|
"{"
|
|
598
585
|
/* TokenChars.BraceLeft */
|
|
599
|
-
),
|
|
586
|
+
), P(o), c.braceNest++, N;
|
|
600
587
|
case "}":
|
|
601
|
-
return c.braceNest > 0 && c.currentType === 2 && T(M.EMPTY_PLACEHOLDER, r(), 0),
|
|
588
|
+
return c.braceNest > 0 && c.currentType === 2 && T(M.EMPTY_PLACEHOLDER, r(), 0), o.next(), N = d(
|
|
602
589
|
c,
|
|
603
590
|
3,
|
|
604
591
|
"}"
|
|
605
592
|
/* TokenChars.BraceRight */
|
|
606
|
-
), c.braceNest--, c.braceNest > 0 &&
|
|
593
|
+
), c.braceNest--, c.braceNest > 0 && P(o), c.inLinked && c.braceNest === 0 && (c.inLinked = !1), N;
|
|
607
594
|
case "@":
|
|
608
|
-
return c.braceNest > 0 && T(M.UNTERMINATED_CLOSING_BRACE, r(), 0), N =
|
|
595
|
+
return c.braceNest > 0 && T(M.UNTERMINATED_CLOSING_BRACE, r(), 0), N = be(o, c) || h(c), c.braceNest = 0, N;
|
|
609
596
|
default: {
|
|
610
|
-
let
|
|
611
|
-
if (
|
|
612
|
-
return c.braceNest > 0 && T(M.UNTERMINATED_CLOSING_BRACE, r(), 0), N = d(c, 1, W(
|
|
597
|
+
let j = !0, Y = !0, x = !0;
|
|
598
|
+
if (B(o))
|
|
599
|
+
return c.braceNest > 0 && T(M.UNTERMINATED_CLOSING_BRACE, r(), 0), N = d(c, 1, W(o)), c.braceNest = 0, c.inLinked = !1, N;
|
|
613
600
|
if (c.braceNest > 0 && (c.currentType === 5 || c.currentType === 6 || c.currentType === 7))
|
|
614
|
-
return T(M.UNTERMINATED_CLOSING_BRACE, r(), 0), c.braceNest = 0,
|
|
615
|
-
if (
|
|
616
|
-
return N = d(c, 5,
|
|
617
|
-
if (
|
|
618
|
-
return N = d(c, 6,
|
|
619
|
-
if (
|
|
620
|
-
return N = d(c, 7,
|
|
621
|
-
if (!
|
|
622
|
-
return N = d(c, 13,
|
|
601
|
+
return T(M.UNTERMINATED_CLOSING_BRACE, r(), 0), c.braceNest = 0, rt(o, c);
|
|
602
|
+
if (j = _(o, c))
|
|
603
|
+
return N = d(c, 5, Je(o)), P(o), N;
|
|
604
|
+
if (Y = E(o, c))
|
|
605
|
+
return N = d(c, 6, Qe(o)), P(o), N;
|
|
606
|
+
if (x = L(o, c))
|
|
607
|
+
return N = d(c, 7, _t(o)), P(o), N;
|
|
608
|
+
if (!j && !Y && !x)
|
|
609
|
+
return N = d(c, 13, et(o)), T(M.INVALID_TOKEN_IN_PLACEHOLDER, r(), 0, N.value), P(o), N;
|
|
623
610
|
break;
|
|
624
611
|
}
|
|
625
612
|
}
|
|
626
613
|
return N;
|
|
627
614
|
}
|
|
628
|
-
function
|
|
615
|
+
function be(o, c) {
|
|
629
616
|
const { currentType: N } = c;
|
|
630
617
|
let k = null;
|
|
631
|
-
const
|
|
632
|
-
switch ((N === 8 || N === 9 || N === 12 || N === 10) && (
|
|
618
|
+
const j = o.currentChar();
|
|
619
|
+
switch ((N === 8 || N === 9 || N === 12 || N === 10) && (j === ne || j === ge) && T(M.INVALID_LINKED_FORMAT, r(), 0), j) {
|
|
633
620
|
case "@":
|
|
634
|
-
return
|
|
621
|
+
return o.next(), k = d(
|
|
635
622
|
c,
|
|
636
623
|
8,
|
|
637
624
|
"@"
|
|
638
625
|
/* TokenChars.LinkedAlias */
|
|
639
626
|
), c.inLinked = !0, k;
|
|
640
627
|
case ".":
|
|
641
|
-
return
|
|
628
|
+
return P(o), o.next(), d(
|
|
642
629
|
c,
|
|
643
630
|
9,
|
|
644
631
|
"."
|
|
645
632
|
/* TokenChars.LinkedDot */
|
|
646
633
|
);
|
|
647
634
|
case ":":
|
|
648
|
-
return
|
|
635
|
+
return P(o), o.next(), d(
|
|
649
636
|
c,
|
|
650
637
|
10,
|
|
651
638
|
":"
|
|
652
639
|
/* TokenChars.LinkedDelimiter */
|
|
653
640
|
);
|
|
654
641
|
default:
|
|
655
|
-
return
|
|
642
|
+
return B(o) ? (k = d(c, 1, W(o)), c.braceNest = 0, c.inLinked = !1, k) : g(o, c) || C(o, c) ? (P(o), be(o, c)) : v(o, c) ? (P(o), d(c, 12, tt(o))) : I(o, c) ? (P(o), j === "{" ? nt(o, c) || k : d(c, 11, b(o))) : (N === 8 && T(M.INVALID_LINKED_FORMAT, r(), 0), c.braceNest = 0, c.inLinked = !1, rt(o, c));
|
|
656
643
|
}
|
|
657
644
|
}
|
|
658
|
-
function
|
|
645
|
+
function rt(o, c) {
|
|
659
646
|
let N = {
|
|
660
647
|
type: 14
|
|
661
648
|
/* TokenTypes.EOF */
|
|
662
649
|
};
|
|
663
650
|
if (c.braceNest > 0)
|
|
664
|
-
return
|
|
651
|
+
return nt(o, c) || h(c);
|
|
665
652
|
if (c.inLinked)
|
|
666
|
-
return
|
|
667
|
-
switch (
|
|
653
|
+
return be(o, c) || h(c);
|
|
654
|
+
switch (o.currentChar()) {
|
|
668
655
|
case "{":
|
|
669
|
-
return
|
|
656
|
+
return nt(o, c) || h(c);
|
|
670
657
|
case "}":
|
|
671
|
-
return T(M.UNBALANCED_CLOSING_BRACE, r(), 0),
|
|
658
|
+
return T(M.UNBALANCED_CLOSING_BRACE, r(), 0), o.next(), d(
|
|
672
659
|
c,
|
|
673
660
|
3,
|
|
674
661
|
"}"
|
|
675
662
|
/* TokenChars.BraceRight */
|
|
676
663
|
);
|
|
677
664
|
case "@":
|
|
678
|
-
return
|
|
665
|
+
return be(o, c) || h(c);
|
|
679
666
|
default: {
|
|
680
|
-
if (
|
|
681
|
-
return N = d(c, 1, W(
|
|
682
|
-
const { isModulo:
|
|
683
|
-
if (
|
|
684
|
-
return
|
|
685
|
-
if (w(
|
|
686
|
-
return d(c, 0,
|
|
667
|
+
if (B(o))
|
|
668
|
+
return N = d(c, 1, W(o)), c.braceNest = 0, c.inLinked = !1, N;
|
|
669
|
+
const { isModulo: j, hasSpace: Y } = le(o);
|
|
670
|
+
if (j)
|
|
671
|
+
return Y ? d(c, 0, ye(o)) : d(c, 4, ke(o));
|
|
672
|
+
if (w(o))
|
|
673
|
+
return d(c, 0, ye(o));
|
|
687
674
|
break;
|
|
688
675
|
}
|
|
689
676
|
}
|
|
690
677
|
return N;
|
|
691
678
|
}
|
|
692
|
-
function
|
|
693
|
-
const { currentType:
|
|
694
|
-
return u.lastType =
|
|
679
|
+
function At() {
|
|
680
|
+
const { currentType: o, offset: c, startLoc: N, endLoc: k } = u;
|
|
681
|
+
return u.lastType = o, u.lastOffset = c, u.lastStartLoc = N, u.lastEndLoc = k, u.offset = s(), u.startLoc = r(), a.currentChar() === Oe ? d(
|
|
695
682
|
u,
|
|
696
683
|
14
|
|
697
684
|
/* TokenTypes.EOF */
|
|
698
|
-
) :
|
|
685
|
+
) : rt(a, u);
|
|
699
686
|
}
|
|
700
687
|
return {
|
|
701
|
-
nextToken:
|
|
688
|
+
nextToken: At,
|
|
702
689
|
currentOffset: s,
|
|
703
690
|
currentPosition: r,
|
|
704
|
-
context:
|
|
691
|
+
context: f
|
|
705
692
|
};
|
|
706
693
|
}
|
|
707
|
-
const
|
|
708
|
-
function
|
|
694
|
+
const Ta = "parser", Oa = /(?:\\\\|\\'|\\u([0-9a-fA-F]{4})|\\U([0-9a-fA-F]{6}))/g;
|
|
695
|
+
function La(e, t, n) {
|
|
709
696
|
switch (e) {
|
|
710
697
|
case "\\\\":
|
|
711
698
|
return "\\";
|
|
@@ -717,177 +704,177 @@ function $a(e, t, n) {
|
|
|
717
704
|
}
|
|
718
705
|
}
|
|
719
706
|
}
|
|
720
|
-
function
|
|
707
|
+
function va(e = {}) {
|
|
721
708
|
const t = e.location !== !1, { onError: n, onWarn: a } = e;
|
|
722
|
-
function s(
|
|
723
|
-
const C =
|
|
709
|
+
function s(_, E, L, g, ...v) {
|
|
710
|
+
const C = _.currentPosition();
|
|
724
711
|
if (C.offset += g, C.column += g, n) {
|
|
725
|
-
const I = t ?
|
|
726
|
-
domain:
|
|
712
|
+
const I = t ? pt(L, C) : null, B = Ge(E, I, {
|
|
713
|
+
domain: Ta,
|
|
727
714
|
args: v
|
|
728
715
|
});
|
|
729
|
-
n(
|
|
716
|
+
n(B);
|
|
730
717
|
}
|
|
731
718
|
}
|
|
732
|
-
function r(
|
|
733
|
-
const C =
|
|
719
|
+
function r(_, E, L, g, ...v) {
|
|
720
|
+
const C = _.currentPosition();
|
|
734
721
|
if (C.offset += g, C.column += g, a) {
|
|
735
|
-
const I = t ?
|
|
736
|
-
a(
|
|
722
|
+
const I = t ? pt(L, C) : null;
|
|
723
|
+
a(oa(E, I, v));
|
|
737
724
|
}
|
|
738
725
|
}
|
|
739
|
-
function l(
|
|
740
|
-
const g = { type:
|
|
726
|
+
function l(_, E, L) {
|
|
727
|
+
const g = { type: _ };
|
|
741
728
|
return t && (g.start = E, g.end = E, g.loc = { start: L, end: L }), g;
|
|
742
729
|
}
|
|
743
|
-
function
|
|
744
|
-
t && (
|
|
730
|
+
function i(_, E, L, g) {
|
|
731
|
+
t && (_.end = E, _.loc && (_.loc.end = L));
|
|
745
732
|
}
|
|
746
|
-
function u(
|
|
747
|
-
const L =
|
|
748
|
-
return g.value = E,
|
|
733
|
+
function u(_, E) {
|
|
734
|
+
const L = _.context(), g = l(3, L.offset, L.startLoc);
|
|
735
|
+
return g.value = E, i(g, _.currentOffset(), _.currentPosition()), g;
|
|
749
736
|
}
|
|
750
|
-
function _
|
|
751
|
-
const L =
|
|
752
|
-
return C.index = parseInt(E, 10),
|
|
737
|
+
function f(_, E) {
|
|
738
|
+
const L = _.context(), { lastOffset: g, lastStartLoc: v } = L, C = l(5, g, v);
|
|
739
|
+
return C.index = parseInt(E, 10), _.nextToken(), i(C, _.currentOffset(), _.currentPosition()), C;
|
|
753
740
|
}
|
|
754
|
-
function p(
|
|
755
|
-
const g =
|
|
756
|
-
return I.key = E, L === !0 && (I.modulo = !0),
|
|
741
|
+
function p(_, E, L) {
|
|
742
|
+
const g = _.context(), { lastOffset: v, lastStartLoc: C } = g, I = l(4, v, C);
|
|
743
|
+
return I.key = E, L === !0 && (I.modulo = !0), _.nextToken(), i(I, _.currentOffset(), _.currentPosition()), I;
|
|
757
744
|
}
|
|
758
|
-
function T(
|
|
759
|
-
const L =
|
|
760
|
-
return C.value = E.replace(
|
|
745
|
+
function T(_, E) {
|
|
746
|
+
const L = _.context(), { lastOffset: g, lastStartLoc: v } = L, C = l(9, g, v);
|
|
747
|
+
return C.value = E.replace(Oa, La), _.nextToken(), i(C, _.currentOffset(), _.currentPosition()), C;
|
|
761
748
|
}
|
|
762
|
-
function d(
|
|
763
|
-
const E =
|
|
764
|
-
return E.type !== 12 ? (s(
|
|
749
|
+
function d(_) {
|
|
750
|
+
const E = _.nextToken(), L = _.context(), { lastOffset: g, lastStartLoc: v } = L, C = l(8, g, v);
|
|
751
|
+
return E.type !== 12 ? (s(_, M.UNEXPECTED_EMPTY_LINKED_MODIFIER, L.lastStartLoc, 0), C.value = "", i(C, g, v), {
|
|
765
752
|
nextConsumeToken: E,
|
|
766
753
|
node: C
|
|
767
|
-
}) : (E.value == null && s(
|
|
754
|
+
}) : (E.value == null && s(_, M.UNEXPECTED_LEXICAL_ANALYSIS, L.lastStartLoc, 0, ue(E)), C.value = E.value || "", i(C, _.currentOffset(), _.currentPosition()), {
|
|
768
755
|
node: C
|
|
769
756
|
});
|
|
770
757
|
}
|
|
771
|
-
function
|
|
772
|
-
const L =
|
|
773
|
-
return g.value = E,
|
|
758
|
+
function h(_, E) {
|
|
759
|
+
const L = _.context(), g = l(7, L.offset, L.startLoc);
|
|
760
|
+
return g.value = E, i(g, _.currentOffset(), _.currentPosition()), g;
|
|
774
761
|
}
|
|
775
|
-
function D(
|
|
776
|
-
const E =
|
|
777
|
-
let g =
|
|
762
|
+
function D(_) {
|
|
763
|
+
const E = _.context(), L = l(6, E.offset, E.startLoc);
|
|
764
|
+
let g = _.nextToken();
|
|
778
765
|
if (g.type === 9) {
|
|
779
|
-
const v = d(
|
|
780
|
-
L.modifier = v.node, g = v.nextConsumeToken ||
|
|
766
|
+
const v = d(_);
|
|
767
|
+
L.modifier = v.node, g = v.nextConsumeToken || _.nextToken();
|
|
781
768
|
}
|
|
782
|
-
switch (g.type !== 10 && s(
|
|
769
|
+
switch (g.type !== 10 && s(_, M.UNEXPECTED_LEXICAL_ANALYSIS, E.lastStartLoc, 0, ue(g)), g = _.nextToken(), g.type === 2 && (g = _.nextToken()), g.type) {
|
|
783
770
|
case 11:
|
|
784
|
-
g.value == null && s(
|
|
771
|
+
g.value == null && s(_, M.UNEXPECTED_LEXICAL_ANALYSIS, E.lastStartLoc, 0, ue(g)), L.key = h(_, g.value || "");
|
|
785
772
|
break;
|
|
786
773
|
case 5:
|
|
787
|
-
g.value == null && s(
|
|
774
|
+
g.value == null && s(_, M.UNEXPECTED_LEXICAL_ANALYSIS, E.lastStartLoc, 0, ue(g)), L.key = p(_, g.value || "");
|
|
788
775
|
break;
|
|
789
776
|
case 6:
|
|
790
|
-
g.value == null && s(
|
|
777
|
+
g.value == null && s(_, M.UNEXPECTED_LEXICAL_ANALYSIS, E.lastStartLoc, 0, ue(g)), L.key = f(_, g.value || "");
|
|
791
778
|
break;
|
|
792
779
|
case 7:
|
|
793
|
-
g.value == null && s(
|
|
780
|
+
g.value == null && s(_, M.UNEXPECTED_LEXICAL_ANALYSIS, E.lastStartLoc, 0, ue(g)), L.key = T(_, g.value || "");
|
|
794
781
|
break;
|
|
795
782
|
default: {
|
|
796
|
-
s(
|
|
797
|
-
const v =
|
|
798
|
-
return C.value = "",
|
|
783
|
+
s(_, M.UNEXPECTED_EMPTY_LINKED_KEY, E.lastStartLoc, 0);
|
|
784
|
+
const v = _.context(), C = l(7, v.offset, v.startLoc);
|
|
785
|
+
return C.value = "", i(C, v.offset, v.startLoc), L.key = C, i(L, v.offset, v.startLoc), {
|
|
799
786
|
nextConsumeToken: g,
|
|
800
787
|
node: L
|
|
801
788
|
};
|
|
802
789
|
}
|
|
803
790
|
}
|
|
804
|
-
return
|
|
791
|
+
return i(L, _.currentOffset(), _.currentPosition()), {
|
|
805
792
|
node: L
|
|
806
793
|
};
|
|
807
794
|
}
|
|
808
|
-
function
|
|
809
|
-
const E =
|
|
795
|
+
function S(_) {
|
|
796
|
+
const E = _.context(), L = E.currentType === 1 ? _.currentOffset() : E.offset, g = E.currentType === 1 ? E.endLoc : E.startLoc, v = l(2, L, g);
|
|
810
797
|
v.items = [];
|
|
811
798
|
let C = null, I = null;
|
|
812
799
|
do {
|
|
813
|
-
const w = C ||
|
|
800
|
+
const w = C || _.nextToken();
|
|
814
801
|
switch (C = null, w.type) {
|
|
815
802
|
case 0:
|
|
816
|
-
w.value == null && s(
|
|
803
|
+
w.value == null && s(_, M.UNEXPECTED_LEXICAL_ANALYSIS, E.lastStartLoc, 0, ue(w)), v.items.push(u(_, w.value || ""));
|
|
817
804
|
break;
|
|
818
805
|
case 6:
|
|
819
|
-
w.value == null && s(
|
|
806
|
+
w.value == null && s(_, M.UNEXPECTED_LEXICAL_ANALYSIS, E.lastStartLoc, 0, ue(w)), v.items.push(f(_, w.value || ""));
|
|
820
807
|
break;
|
|
821
808
|
case 4:
|
|
822
809
|
I = !0;
|
|
823
810
|
break;
|
|
824
811
|
case 5:
|
|
825
|
-
w.value == null && s(
|
|
812
|
+
w.value == null && s(_, M.UNEXPECTED_LEXICAL_ANALYSIS, E.lastStartLoc, 0, ue(w)), v.items.push(p(_, w.value || "", !!I)), I && (r(_, vt.USE_MODULO_SYNTAX, E.lastStartLoc, 0, ue(w)), I = null);
|
|
826
813
|
break;
|
|
827
814
|
case 7:
|
|
828
|
-
w.value == null && s(
|
|
815
|
+
w.value == null && s(_, M.UNEXPECTED_LEXICAL_ANALYSIS, E.lastStartLoc, 0, ue(w)), v.items.push(T(_, w.value || ""));
|
|
829
816
|
break;
|
|
830
817
|
case 8: {
|
|
831
|
-
const
|
|
832
|
-
v.items.push(
|
|
818
|
+
const te = D(_);
|
|
819
|
+
v.items.push(te.node), C = te.nextConsumeToken || null;
|
|
833
820
|
break;
|
|
834
821
|
}
|
|
835
822
|
}
|
|
836
823
|
} while (E.currentType !== 14 && E.currentType !== 1);
|
|
837
|
-
const
|
|
838
|
-
return
|
|
824
|
+
const B = E.currentType === 1 ? E.lastOffset : _.currentOffset(), le = E.currentType === 1 ? E.lastEndLoc : _.currentPosition();
|
|
825
|
+
return i(v, B, le), v;
|
|
839
826
|
}
|
|
840
|
-
function
|
|
841
|
-
const v =
|
|
827
|
+
function P(_, E, L, g) {
|
|
828
|
+
const v = _.context();
|
|
842
829
|
let C = g.items.length === 0;
|
|
843
830
|
const I = l(1, E, L);
|
|
844
831
|
I.cases = [], I.cases.push(g);
|
|
845
832
|
do {
|
|
846
|
-
const
|
|
847
|
-
C || (C =
|
|
833
|
+
const B = S(_);
|
|
834
|
+
C || (C = B.items.length === 0), I.cases.push(B);
|
|
848
835
|
} while (v.currentType !== 14);
|
|
849
|
-
return C && s(
|
|
836
|
+
return C && s(_, M.MUST_HAVE_MESSAGES_IN_PLURAL, L, 0), i(I, _.currentOffset(), _.currentPosition()), I;
|
|
850
837
|
}
|
|
851
|
-
function y(
|
|
852
|
-
const E =
|
|
853
|
-
return E.currentType === 14 ? v :
|
|
838
|
+
function y(_) {
|
|
839
|
+
const E = _.context(), { offset: L, startLoc: g } = E, v = S(_);
|
|
840
|
+
return E.currentType === 14 ? v : P(_, L, g, v);
|
|
854
841
|
}
|
|
855
|
-
function R(
|
|
856
|
-
const E =
|
|
857
|
-
return t && g.loc && (g.loc.source =
|
|
842
|
+
function R(_) {
|
|
843
|
+
const E = pa(_, Kn({}, e)), L = E.context(), g = l(0, L.offset, L.startLoc);
|
|
844
|
+
return t && g.loc && (g.loc.source = _), g.body = y(E), e.onCacheKey && (g.cacheKey = e.onCacheKey(_)), L.currentType !== 14 && s(E, M.UNEXPECTED_LEXICAL_ANALYSIS, L.lastStartLoc, 0, _[L.offset] || ""), i(g, E.currentOffset(), E.currentPosition()), g;
|
|
858
845
|
}
|
|
859
846
|
return { parse: R };
|
|
860
847
|
}
|
|
861
|
-
function
|
|
848
|
+
function ue(e) {
|
|
862
849
|
if (e.type === 14)
|
|
863
850
|
return "EOF";
|
|
864
851
|
const t = (e.value || "").replace(/\r?\n/gu, "\\n");
|
|
865
852
|
return t.length > 10 ? t.slice(0, 9) + "…" : t;
|
|
866
853
|
}
|
|
867
|
-
function
|
|
854
|
+
function Ia(e, t = {}) {
|
|
868
855
|
const n = {
|
|
869
856
|
ast: e,
|
|
870
857
|
helpers: /* @__PURE__ */ new Set()
|
|
871
858
|
};
|
|
872
859
|
return { context: () => n, helper: (r) => (n.helpers.add(r), r) };
|
|
873
860
|
}
|
|
874
|
-
function
|
|
861
|
+
function on(e, t) {
|
|
875
862
|
for (let n = 0; n < e.length; n++)
|
|
876
|
-
|
|
863
|
+
Bt(e[n], t);
|
|
877
864
|
}
|
|
878
|
-
function
|
|
865
|
+
function Bt(e, t) {
|
|
879
866
|
switch (e.type) {
|
|
880
867
|
case 1:
|
|
881
|
-
|
|
868
|
+
on(e.cases, t), t.helper(
|
|
882
869
|
"plural"
|
|
883
870
|
/* HelperNameMap.PLURAL */
|
|
884
871
|
);
|
|
885
872
|
break;
|
|
886
873
|
case 2:
|
|
887
|
-
|
|
874
|
+
on(e.items, t);
|
|
888
875
|
break;
|
|
889
876
|
case 6: {
|
|
890
|
-
|
|
877
|
+
Bt(e.key, t), t.helper(
|
|
891
878
|
"linked"
|
|
892
879
|
/* HelperNameMap.LINKED */
|
|
893
880
|
), t.helper(
|
|
@@ -916,20 +903,20 @@ function Qt(e, t) {
|
|
|
916
903
|
break;
|
|
917
904
|
}
|
|
918
905
|
}
|
|
919
|
-
function
|
|
920
|
-
const n =
|
|
906
|
+
function ba(e, t = {}) {
|
|
907
|
+
const n = Ia(e);
|
|
921
908
|
n.helper(
|
|
922
909
|
"normalize"
|
|
923
910
|
/* HelperNameMap.NORMALIZE */
|
|
924
|
-
), e.body &&
|
|
911
|
+
), e.body && Bt(e.body, n);
|
|
925
912
|
const a = n.context();
|
|
926
913
|
e.helpers = Array.from(a.helpers);
|
|
927
914
|
}
|
|
928
|
-
function
|
|
915
|
+
function ha(e) {
|
|
929
916
|
const t = e.body;
|
|
930
|
-
return t.type === 2 ?
|
|
917
|
+
return t.type === 2 ? cn(t) : t.cases.forEach((n) => cn(n)), e;
|
|
931
918
|
}
|
|
932
|
-
function
|
|
919
|
+
function cn(e) {
|
|
933
920
|
if (e.items.length === 1) {
|
|
934
921
|
const t = e.items[0];
|
|
935
922
|
(t.type === 3 || t.type === 9) && (e.static = t.value, delete t.value);
|
|
@@ -942,7 +929,7 @@ function gn(e) {
|
|
|
942
929
|
t.push(a.value);
|
|
943
930
|
}
|
|
944
931
|
if (t.length === e.items.length) {
|
|
945
|
-
e.static =
|
|
932
|
+
e.static = Jn(t);
|
|
946
933
|
for (let n = 0; n < e.items.length; n++) {
|
|
947
934
|
const a = e.items[n];
|
|
948
935
|
(a.type === 3 || a.type === 9) && delete a.value;
|
|
@@ -950,25 +937,25 @@ function gn(e) {
|
|
|
950
937
|
}
|
|
951
938
|
}
|
|
952
939
|
}
|
|
953
|
-
const
|
|
954
|
-
function
|
|
940
|
+
const Aa = "minifier";
|
|
941
|
+
function we(e) {
|
|
955
942
|
switch (e.t = e.type, e.type) {
|
|
956
943
|
case 0: {
|
|
957
944
|
const t = e;
|
|
958
|
-
|
|
945
|
+
we(t.body), t.b = t.body, delete t.body;
|
|
959
946
|
break;
|
|
960
947
|
}
|
|
961
948
|
case 1: {
|
|
962
949
|
const t = e, n = t.cases;
|
|
963
950
|
for (let a = 0; a < n.length; a++)
|
|
964
|
-
|
|
951
|
+
we(n[a]);
|
|
965
952
|
t.c = n, delete t.cases;
|
|
966
953
|
break;
|
|
967
954
|
}
|
|
968
955
|
case 2: {
|
|
969
956
|
const t = e, n = t.items;
|
|
970
957
|
for (let a = 0; a < n.length; a++)
|
|
971
|
-
|
|
958
|
+
we(n[a]);
|
|
972
959
|
t.i = n, delete t.items, t.static && (t.s = t.static, delete t.static);
|
|
973
960
|
break;
|
|
974
961
|
}
|
|
@@ -982,7 +969,7 @@ function We(e) {
|
|
|
982
969
|
}
|
|
983
970
|
case 6: {
|
|
984
971
|
const t = e;
|
|
985
|
-
|
|
972
|
+
we(t.key), t.k = t.key, delete t.key, t.modifier && (we(t.modifier), t.m = t.modifier, delete t.modifier);
|
|
986
973
|
break;
|
|
987
974
|
}
|
|
988
975
|
case 5: {
|
|
@@ -996,15 +983,15 @@ function We(e) {
|
|
|
996
983
|
break;
|
|
997
984
|
}
|
|
998
985
|
default:
|
|
999
|
-
throw
|
|
1000
|
-
domain:
|
|
986
|
+
throw Ge(M.UNHANDLED_MINIFIER_NODE_TYPE, null, {
|
|
987
|
+
domain: Aa,
|
|
1001
988
|
args: [e.type]
|
|
1002
989
|
});
|
|
1003
990
|
}
|
|
1004
991
|
delete e.type;
|
|
1005
992
|
}
|
|
1006
|
-
const
|
|
1007
|
-
function
|
|
993
|
+
const Ca = "parser";
|
|
994
|
+
function Sa(e, t) {
|
|
1008
995
|
const { filename: n, breakLineCode: a, needIndent: s } = t, r = t.location !== !1, l = {
|
|
1009
996
|
filename: n,
|
|
1010
997
|
code: "",
|
|
@@ -1017,54 +1004,54 @@ function ja(e, t) {
|
|
|
1017
1004
|
indentLevel: 0
|
|
1018
1005
|
};
|
|
1019
1006
|
r && e.loc && (l.source = e.loc.source);
|
|
1020
|
-
const
|
|
1021
|
-
function u(
|
|
1022
|
-
l.code +=
|
|
1007
|
+
const i = () => l;
|
|
1008
|
+
function u(S, P) {
|
|
1009
|
+
l.code += S;
|
|
1023
1010
|
}
|
|
1024
|
-
function
|
|
1025
|
-
const y =
|
|
1026
|
-
u(s ? y + " ".repeat(
|
|
1011
|
+
function f(S, P = !0) {
|
|
1012
|
+
const y = P ? a : "";
|
|
1013
|
+
u(s ? y + " ".repeat(S) : y);
|
|
1027
1014
|
}
|
|
1028
|
-
function p(
|
|
1029
|
-
const
|
|
1030
|
-
|
|
1015
|
+
function p(S = !0) {
|
|
1016
|
+
const P = ++l.indentLevel;
|
|
1017
|
+
S && f(P);
|
|
1031
1018
|
}
|
|
1032
|
-
function T(
|
|
1033
|
-
const
|
|
1034
|
-
|
|
1019
|
+
function T(S = !0) {
|
|
1020
|
+
const P = --l.indentLevel;
|
|
1021
|
+
S && f(P);
|
|
1035
1022
|
}
|
|
1036
1023
|
function d() {
|
|
1037
|
-
|
|
1024
|
+
f(l.indentLevel);
|
|
1038
1025
|
}
|
|
1039
1026
|
return {
|
|
1040
|
-
context:
|
|
1027
|
+
context: i,
|
|
1041
1028
|
push: u,
|
|
1042
1029
|
indent: p,
|
|
1043
1030
|
deindent: T,
|
|
1044
1031
|
newline: d,
|
|
1045
|
-
helper: (
|
|
1032
|
+
helper: (S) => `_${S}`,
|
|
1046
1033
|
needIndent: () => l.needIndent
|
|
1047
1034
|
};
|
|
1048
1035
|
}
|
|
1049
|
-
function
|
|
1036
|
+
function Pa(e, t) {
|
|
1050
1037
|
const { helper: n } = e;
|
|
1051
1038
|
e.push(`${n(
|
|
1052
1039
|
"linked"
|
|
1053
1040
|
/* HelperNameMap.LINKED */
|
|
1054
|
-
)}(`),
|
|
1041
|
+
)}(`), $e(e, t.key), t.modifier ? (e.push(", "), $e(e, t.modifier), e.push(", _type")) : e.push(", undefined, _type"), e.push(")");
|
|
1055
1042
|
}
|
|
1056
|
-
function
|
|
1043
|
+
function Da(e, t) {
|
|
1057
1044
|
const { helper: n, needIndent: a } = e;
|
|
1058
1045
|
e.push(`${n(
|
|
1059
1046
|
"normalize"
|
|
1060
1047
|
/* HelperNameMap.NORMALIZE */
|
|
1061
1048
|
)}([`), e.indent(a());
|
|
1062
1049
|
const s = t.items.length;
|
|
1063
|
-
for (let r = 0; r < s && (
|
|
1050
|
+
for (let r = 0; r < s && ($e(e, t.items[r]), r !== s - 1); r++)
|
|
1064
1051
|
e.push(", ");
|
|
1065
1052
|
e.deindent(a()), e.push("])");
|
|
1066
1053
|
}
|
|
1067
|
-
function
|
|
1054
|
+
function Ra(e, t) {
|
|
1068
1055
|
const { helper: n, needIndent: a } = e;
|
|
1069
1056
|
if (t.cases.length > 1) {
|
|
1070
1057
|
e.push(`${n(
|
|
@@ -1072,28 +1059,28 @@ function Ja(e, t) {
|
|
|
1072
1059
|
/* HelperNameMap.PLURAL */
|
|
1073
1060
|
)}([`), e.indent(a());
|
|
1074
1061
|
const s = t.cases.length;
|
|
1075
|
-
for (let r = 0; r < s && (
|
|
1062
|
+
for (let r = 0; r < s && ($e(e, t.cases[r]), r !== s - 1); r++)
|
|
1076
1063
|
e.push(", ");
|
|
1077
1064
|
e.deindent(a()), e.push("])");
|
|
1078
1065
|
}
|
|
1079
1066
|
}
|
|
1080
|
-
function
|
|
1081
|
-
t.body ?
|
|
1067
|
+
function ka(e, t) {
|
|
1068
|
+
t.body ? $e(e, t.body) : e.push("null");
|
|
1082
1069
|
}
|
|
1083
|
-
function
|
|
1070
|
+
function $e(e, t) {
|
|
1084
1071
|
const { helper: n } = e;
|
|
1085
1072
|
switch (t.type) {
|
|
1086
1073
|
case 0:
|
|
1087
|
-
|
|
1074
|
+
ka(e, t);
|
|
1088
1075
|
break;
|
|
1089
1076
|
case 1:
|
|
1090
|
-
|
|
1077
|
+
Ra(e, t);
|
|
1091
1078
|
break;
|
|
1092
1079
|
case 2:
|
|
1093
|
-
|
|
1080
|
+
Da(e, t);
|
|
1094
1081
|
break;
|
|
1095
1082
|
case 6:
|
|
1096
|
-
|
|
1083
|
+
Pa(e, t);
|
|
1097
1084
|
break;
|
|
1098
1085
|
case 8:
|
|
1099
1086
|
e.push(JSON.stringify(t.value), t);
|
|
@@ -1126,109 +1113,44 @@ function He(e, t) {
|
|
|
1126
1113
|
e.push(JSON.stringify(t.value), t);
|
|
1127
1114
|
break;
|
|
1128
1115
|
default:
|
|
1129
|
-
throw
|
|
1130
|
-
domain:
|
|
1116
|
+
throw Ge(M.UNHANDLED_CODEGEN_NODE_TYPE, null, {
|
|
1117
|
+
domain: Ca,
|
|
1131
1118
|
args: [t.type]
|
|
1132
1119
|
});
|
|
1133
1120
|
}
|
|
1134
1121
|
}
|
|
1135
|
-
const
|
|
1136
|
-
const n =
|
|
1122
|
+
const ya = (e, t = {}) => {
|
|
1123
|
+
const n = sn(t.mode) ? t.mode : "normal", a = sn(t.filename) ? t.filename : "message.intl";
|
|
1137
1124
|
t.sourceMap;
|
|
1138
1125
|
const s = t.breakLineCode != null ? t.breakLineCode : n === "arrow" ? ";" : `
|
|
1139
|
-
`, r = t.needIndent ? t.needIndent : n !== "arrow", l = e.helpers || [],
|
|
1126
|
+
`, r = t.needIndent ? t.needIndent : n !== "arrow", l = e.helpers || [], i = Sa(e, {
|
|
1140
1127
|
filename: a,
|
|
1141
1128
|
breakLineCode: s,
|
|
1142
1129
|
needIndent: r
|
|
1143
1130
|
});
|
|
1144
|
-
|
|
1145
|
-
const { code: u, map:
|
|
1131
|
+
i.push(n === "normal" ? "function __msg__ (ctx) {" : "(ctx) => {"), i.indent(r), l.length > 0 && (i.push(`const { ${Jn(l.map((p) => `${p}: _${p}`), ", ")} } = ctx`), i.newline()), i.push("return "), $e(i, e), i.deindent(r), i.push("}"), delete e.helpers;
|
|
1132
|
+
const { code: u, map: f } = i.context();
|
|
1146
1133
|
return {
|
|
1147
1134
|
ast: e,
|
|
1148
1135
|
code: u,
|
|
1149
|
-
map:
|
|
1136
|
+
map: f ? f.toJSON() : void 0
|
|
1150
1137
|
// eslint-disable-line @typescript-eslint/no-explicit-any
|
|
1151
1138
|
};
|
|
1152
1139
|
};
|
|
1153
|
-
function
|
|
1154
|
-
const n =
|
|
1155
|
-
return a ? (r &&
|
|
1140
|
+
function Ma(e, t = {}) {
|
|
1141
|
+
const n = Kn({}, t), a = !!n.jit, s = !!n.minify, r = n.optimize == null ? !0 : n.optimize, i = va(n).parse(e);
|
|
1142
|
+
return a ? (r && ha(i), s && we(i), { ast: i, code: "" }) : (ba(i, n), ya(i, n));
|
|
1156
1143
|
}
|
|
1157
1144
|
/*!
|
|
1158
|
-
* core-base v9.14.
|
|
1159
|
-
* (c)
|
|
1145
|
+
* core-base v9.14.0
|
|
1146
|
+
* (c) 2024 kazuya kawaguchi
|
|
1160
1147
|
* Released under the MIT License.
|
|
1161
1148
|
*/
|
|
1162
|
-
function
|
|
1163
|
-
typeof __INTLIFY_PROD_DEVTOOLS__ != "boolean" && (
|
|
1164
|
-
}
|
|
1165
|
-
function fe(e) {
|
|
1166
|
-
return V(e) && qt(e) === 0 && (me(e, "b") || me(e, "body"));
|
|
1167
|
-
}
|
|
1168
|
-
const rr = ["b", "body"];
|
|
1169
|
-
function es(e) {
|
|
1170
|
-
return he(e, rr);
|
|
1171
|
-
}
|
|
1172
|
-
const ar = ["c", "cases"];
|
|
1173
|
-
function ts(e) {
|
|
1174
|
-
return he(e, ar, []);
|
|
1175
|
-
}
|
|
1176
|
-
const sr = ["s", "static"];
|
|
1177
|
-
function ns(e) {
|
|
1178
|
-
return he(e, sr);
|
|
1179
|
-
}
|
|
1180
|
-
const lr = ["i", "items"];
|
|
1181
|
-
function rs(e) {
|
|
1182
|
-
return he(e, lr, []);
|
|
1183
|
-
}
|
|
1184
|
-
const or = ["t", "type"];
|
|
1185
|
-
function qt(e) {
|
|
1186
|
-
return he(e, or);
|
|
1187
|
-
}
|
|
1188
|
-
const ir = ["v", "value"];
|
|
1189
|
-
function Tt(e, t) {
|
|
1190
|
-
const n = he(e, ir);
|
|
1191
|
-
if (n != null)
|
|
1192
|
-
return n;
|
|
1193
|
-
throw ct(t);
|
|
1194
|
-
}
|
|
1195
|
-
const cr = ["m", "modifier"];
|
|
1196
|
-
function as(e) {
|
|
1197
|
-
return he(e, cr);
|
|
1198
|
-
}
|
|
1199
|
-
const ur = ["k", "key"];
|
|
1200
|
-
function ss(e) {
|
|
1201
|
-
const t = he(e, ur);
|
|
1202
|
-
if (t)
|
|
1203
|
-
return t;
|
|
1204
|
-
throw ct(
|
|
1205
|
-
6
|
|
1206
|
-
/* NodeTypes.Linked */
|
|
1207
|
-
);
|
|
1149
|
+
function Fa() {
|
|
1150
|
+
typeof __INTLIFY_PROD_DEVTOOLS__ != "boolean" && (pe().__INTLIFY_PROD_DEVTOOLS__ = !1), typeof __INTLIFY_JIT_COMPILATION__ != "boolean" && (pe().__INTLIFY_JIT_COMPILATION__ = !1), typeof __INTLIFY_DROP_MESSAGE_COMPILER__ != "boolean" && (pe().__INTLIFY_DROP_MESSAGE_COMPILER__ = !1);
|
|
1208
1151
|
}
|
|
1209
|
-
|
|
1210
|
-
|
|
1211
|
-
const s = t[a];
|
|
1212
|
-
if (me(e, s) && e[s] != null)
|
|
1213
|
-
return e[s];
|
|
1214
|
-
}
|
|
1215
|
-
return n;
|
|
1216
|
-
}
|
|
1217
|
-
const fr = [
|
|
1218
|
-
...rr,
|
|
1219
|
-
...ar,
|
|
1220
|
-
...sr,
|
|
1221
|
-
...lr,
|
|
1222
|
-
...ur,
|
|
1223
|
-
...cr,
|
|
1224
|
-
...ir,
|
|
1225
|
-
...or
|
|
1226
|
-
];
|
|
1227
|
-
function ct(e) {
|
|
1228
|
-
return new Error(`unhandled node type: ${e}`);
|
|
1229
|
-
}
|
|
1230
|
-
const Ae = [];
|
|
1231
|
-
Ae[
|
|
1152
|
+
const Ie = [];
|
|
1153
|
+
Ie[
|
|
1232
1154
|
0
|
|
1233
1155
|
/* States.BEFORE_PATH */
|
|
1234
1156
|
] = {
|
|
@@ -1250,7 +1172,7 @@ Ae[
|
|
|
1250
1172
|
/* States.AFTER_PATH */
|
|
1251
1173
|
]
|
|
1252
1174
|
};
|
|
1253
|
-
|
|
1175
|
+
Ie[
|
|
1254
1176
|
1
|
|
1255
1177
|
/* States.IN_PATH */
|
|
1256
1178
|
] = {
|
|
@@ -1271,7 +1193,7 @@ Ae[
|
|
|
1271
1193
|
/* States.AFTER_PATH */
|
|
1272
1194
|
]
|
|
1273
1195
|
};
|
|
1274
|
-
|
|
1196
|
+
Ie[
|
|
1275
1197
|
2
|
|
1276
1198
|
/* States.BEFORE_IDENT */
|
|
1277
1199
|
] = {
|
|
@@ -1290,7 +1212,7 @@ Ae[
|
|
|
1290
1212
|
/* Actions.APPEND */
|
|
1291
1213
|
]
|
|
1292
1214
|
};
|
|
1293
|
-
|
|
1215
|
+
Ie[
|
|
1294
1216
|
3
|
|
1295
1217
|
/* States.IN_IDENT */
|
|
1296
1218
|
] = {
|
|
@@ -1325,7 +1247,7 @@ Ae[
|
|
|
1325
1247
|
/* Actions.PUSH */
|
|
1326
1248
|
]
|
|
1327
1249
|
};
|
|
1328
|
-
|
|
1250
|
+
Ie[
|
|
1329
1251
|
4
|
|
1330
1252
|
/* States.IN_SUB_PATH */
|
|
1331
1253
|
] = {
|
|
@@ -1356,7 +1278,7 @@ Ae[
|
|
|
1356
1278
|
/* Actions.APPEND */
|
|
1357
1279
|
]
|
|
1358
1280
|
};
|
|
1359
|
-
|
|
1281
|
+
Ie[
|
|
1360
1282
|
5
|
|
1361
1283
|
/* States.IN_SINGLE_QUOTE */
|
|
1362
1284
|
] = {
|
|
@@ -1372,7 +1294,7 @@ Ae[
|
|
|
1372
1294
|
/* Actions.APPEND */
|
|
1373
1295
|
]
|
|
1374
1296
|
};
|
|
1375
|
-
|
|
1297
|
+
Ie[
|
|
1376
1298
|
6
|
|
1377
1299
|
/* States.IN_DOUBLE_QUOTE */
|
|
1378
1300
|
] = {
|
|
@@ -1388,15 +1310,15 @@ Ae[
|
|
|
1388
1310
|
/* Actions.APPEND */
|
|
1389
1311
|
]
|
|
1390
1312
|
};
|
|
1391
|
-
const
|
|
1392
|
-
function
|
|
1393
|
-
return
|
|
1313
|
+
const Ua = /^\s?(?:true|false|-?[\d.]+|'[^']*'|"[^"]*")\s?$/;
|
|
1314
|
+
function wa(e) {
|
|
1315
|
+
return Ua.test(e);
|
|
1394
1316
|
}
|
|
1395
|
-
function
|
|
1317
|
+
function Va(e) {
|
|
1396
1318
|
const t = e.charCodeAt(0), n = e.charCodeAt(e.length - 1);
|
|
1397
1319
|
return t === n && (t === 34 || t === 39) ? e.slice(1, -1) : e;
|
|
1398
1320
|
}
|
|
1399
|
-
function
|
|
1321
|
+
function $a(e) {
|
|
1400
1322
|
if (e == null)
|
|
1401
1323
|
return "o";
|
|
1402
1324
|
switch (e.charCodeAt(0)) {
|
|
@@ -1421,19 +1343,19 @@ function cs(e) {
|
|
|
1421
1343
|
}
|
|
1422
1344
|
return "i";
|
|
1423
1345
|
}
|
|
1424
|
-
function
|
|
1346
|
+
function Wa(e) {
|
|
1425
1347
|
const t = e.trim();
|
|
1426
|
-
return e.charAt(0) === "0" && isNaN(parseInt(e)) ? !1 :
|
|
1348
|
+
return e.charAt(0) === "0" && isNaN(parseInt(e)) ? !1 : wa(t) ? Va(t) : "*" + t;
|
|
1427
1349
|
}
|
|
1428
|
-
function
|
|
1350
|
+
function Ga(e) {
|
|
1429
1351
|
const t = [];
|
|
1430
|
-
let n = -1, a = 0, s = 0, r, l,
|
|
1352
|
+
let n = -1, a = 0, s = 0, r, l, i, u, f, p, T;
|
|
1431
1353
|
const d = [];
|
|
1432
1354
|
d[
|
|
1433
1355
|
0
|
|
1434
1356
|
/* Actions.APPEND */
|
|
1435
1357
|
] = () => {
|
|
1436
|
-
l === void 0 ? l =
|
|
1358
|
+
l === void 0 ? l = i : l += i;
|
|
1437
1359
|
}, d[
|
|
1438
1360
|
1
|
|
1439
1361
|
/* Actions.PUSH */
|
|
@@ -1457,7 +1379,7 @@ function fs(e) {
|
|
|
1457
1379
|
/* Actions.APPEND */
|
|
1458
1380
|
]();
|
|
1459
1381
|
else {
|
|
1460
|
-
if (s = 0, l === void 0 || (l =
|
|
1382
|
+
if (s = 0, l === void 0 || (l = Wa(l), l === !1))
|
|
1461
1383
|
return !1;
|
|
1462
1384
|
d[
|
|
1463
1385
|
1
|
|
@@ -1465,302 +1387,298 @@ function fs(e) {
|
|
|
1465
1387
|
]();
|
|
1466
1388
|
}
|
|
1467
1389
|
};
|
|
1468
|
-
function
|
|
1390
|
+
function h() {
|
|
1469
1391
|
const D = e[n + 1];
|
|
1470
1392
|
if (a === 5 && D === "'" || a === 6 && D === '"')
|
|
1471
|
-
return n++,
|
|
1393
|
+
return n++, i = "\\" + D, d[
|
|
1472
1394
|
0
|
|
1473
1395
|
/* Actions.APPEND */
|
|
1474
1396
|
](), !0;
|
|
1475
1397
|
}
|
|
1476
1398
|
for (; a !== null; )
|
|
1477
|
-
if (n++, r = e[n], !(r === "\\" &&
|
|
1478
|
-
if (u =
|
|
1399
|
+
if (n++, r = e[n], !(r === "\\" && h())) {
|
|
1400
|
+
if (u = $a(r), T = Ie[a], f = T[u] || T.l || 8, f === 8 || (a = f[0], f[1] !== void 0 && (p = d[f[1]], p && (i = r, p() === !1))))
|
|
1479
1401
|
return;
|
|
1480
1402
|
if (a === 7)
|
|
1481
1403
|
return t;
|
|
1482
1404
|
}
|
|
1483
1405
|
}
|
|
1484
|
-
const
|
|
1485
|
-
function
|
|
1486
|
-
return
|
|
1406
|
+
const un = /* @__PURE__ */ new Map();
|
|
1407
|
+
function xa(e, t) {
|
|
1408
|
+
return $(e) ? e[t] : null;
|
|
1487
1409
|
}
|
|
1488
|
-
function
|
|
1489
|
-
if (
|
|
1410
|
+
function Ha(e, t) {
|
|
1411
|
+
if (!$(e))
|
|
1490
1412
|
return null;
|
|
1491
|
-
let n =
|
|
1492
|
-
if (n || (n =
|
|
1413
|
+
let n = un.get(t);
|
|
1414
|
+
if (n || (n = Ga(t), n && un.set(t, n)), !n)
|
|
1493
1415
|
return null;
|
|
1494
1416
|
const a = n.length;
|
|
1495
1417
|
let s = e, r = 0;
|
|
1496
1418
|
for (; r < a; ) {
|
|
1497
|
-
const l = n[r];
|
|
1498
|
-
if (
|
|
1499
|
-
return null;
|
|
1500
|
-
const o = s[l];
|
|
1501
|
-
if (o === void 0 || x(s))
|
|
1419
|
+
const l = s[n[r]];
|
|
1420
|
+
if (l === void 0 || H(s))
|
|
1502
1421
|
return null;
|
|
1503
|
-
s =
|
|
1422
|
+
s = l, r++;
|
|
1504
1423
|
}
|
|
1505
1424
|
return s;
|
|
1506
1425
|
}
|
|
1507
|
-
const
|
|
1508
|
-
function
|
|
1426
|
+
const Ya = (e) => e, Ba = (e) => "", Xa = "text", ja = (e) => e.length === 0 ? "" : ta(e), Ka = ea;
|
|
1427
|
+
function _n(e, t) {
|
|
1509
1428
|
return e = Math.abs(e), t === 2 ? e ? e > 1 ? 1 : 0 : 1 : e ? Math.min(e, 2) : 0;
|
|
1510
1429
|
}
|
|
1511
|
-
function
|
|
1512
|
-
const t =
|
|
1513
|
-
return e.named && (
|
|
1430
|
+
function Ja(e) {
|
|
1431
|
+
const t = Q(e.pluralIndex) ? e.pluralIndex : -1;
|
|
1432
|
+
return e.named && (Q(e.named.count) || Q(e.named.n)) ? Q(e.named.count) ? e.named.count : Q(e.named.n) ? e.named.n : t : t;
|
|
1514
1433
|
}
|
|
1515
|
-
function
|
|
1434
|
+
function Qa(e, t) {
|
|
1516
1435
|
t.count || (t.count = e), t.n || (t.n = e);
|
|
1517
1436
|
}
|
|
1518
|
-
function
|
|
1519
|
-
const t = e.locale, n =
|
|
1520
|
-
|
|
1521
|
-
const
|
|
1437
|
+
function qa(e = {}) {
|
|
1438
|
+
const t = e.locale, n = Ja(e), a = $(e.pluralRules) && A(t) && H(e.pluralRules[t]) ? e.pluralRules[t] : _n, s = $(e.pluralRules) && A(t) && H(e.pluralRules[t]) ? _n : void 0, r = (y) => y[a(n, y.length, s)], l = e.list || [], i = (y) => l[y], u = e.named || {};
|
|
1439
|
+
Q(e.pluralIndex) && Qa(n, u);
|
|
1440
|
+
const f = (y) => u[y];
|
|
1522
1441
|
function p(y) {
|
|
1523
|
-
const R =
|
|
1524
|
-
return R || (e.parent ? e.parent.message(y) :
|
|
1442
|
+
const R = H(e.messages) ? e.messages(y) : $(e.messages) ? e.messages[y] : !1;
|
|
1443
|
+
return R || (e.parent ? e.parent.message(y) : Ba);
|
|
1525
1444
|
}
|
|
1526
|
-
const T = (y) => e.modifiers ? e.modifiers[y] :
|
|
1527
|
-
list:
|
|
1528
|
-
named:
|
|
1445
|
+
const T = (y) => e.modifiers ? e.modifiers[y] : Ya, d = F(e.processor) && H(e.processor.normalize) ? e.processor.normalize : ja, h = F(e.processor) && H(e.processor.interpolate) ? e.processor.interpolate : Ka, D = F(e.processor) && A(e.processor.type) ? e.processor.type : Xa, P = {
|
|
1446
|
+
list: i,
|
|
1447
|
+
named: f,
|
|
1529
1448
|
plural: r,
|
|
1530
1449
|
linked: (y, ...R) => {
|
|
1531
|
-
const [
|
|
1450
|
+
const [_, E] = R;
|
|
1532
1451
|
let L = "text", g = "";
|
|
1533
|
-
R.length === 1 ?
|
|
1534
|
-
const v = p(y)(
|
|
1452
|
+
R.length === 1 ? $(_) ? (g = _.modifier || g, L = _.type || L) : A(_) && (g = _ || g) : R.length === 2 && (A(_) && (g = _ || g), A(E) && (L = E || L));
|
|
1453
|
+
const v = p(y)(P), C = (
|
|
1535
1454
|
// The message in vnode resolved with linked are returned as an array by processor.nomalize
|
|
1536
|
-
L === "vnode" &&
|
|
1455
|
+
L === "vnode" && X(v) && g ? v[0] : v
|
|
1537
1456
|
);
|
|
1538
1457
|
return g ? T(g)(C, L) : C;
|
|
1539
1458
|
},
|
|
1540
1459
|
message: p,
|
|
1541
1460
|
type: D,
|
|
1542
|
-
interpolate:
|
|
1461
|
+
interpolate: h,
|
|
1543
1462
|
normalize: d,
|
|
1544
|
-
values:
|
|
1463
|
+
values: ee({}, l, u)
|
|
1545
1464
|
};
|
|
1546
|
-
return
|
|
1465
|
+
return P;
|
|
1547
1466
|
}
|
|
1548
|
-
let
|
|
1549
|
-
function
|
|
1550
|
-
|
|
1467
|
+
let lt = null;
|
|
1468
|
+
function Za(e) {
|
|
1469
|
+
lt = e;
|
|
1551
1470
|
}
|
|
1552
|
-
function
|
|
1553
|
-
|
|
1471
|
+
function za(e, t, n) {
|
|
1472
|
+
lt && lt.emit("i18n:init", {
|
|
1554
1473
|
timestamp: Date.now(),
|
|
1555
1474
|
i18n: e,
|
|
1556
1475
|
version: t,
|
|
1557
1476
|
meta: n
|
|
1558
1477
|
});
|
|
1559
1478
|
}
|
|
1560
|
-
const
|
|
1479
|
+
const es = /* @__PURE__ */ ts(
|
|
1561
1480
|
"function:translate"
|
|
1562
1481
|
/* IntlifyDevToolsHooks.FunctionTranslate */
|
|
1563
1482
|
);
|
|
1564
|
-
function
|
|
1565
|
-
return (t) =>
|
|
1483
|
+
function ts(e) {
|
|
1484
|
+
return (t) => lt && lt.emit(e, t);
|
|
1566
1485
|
}
|
|
1567
|
-
const
|
|
1568
|
-
NOT_FOUND_KEY:
|
|
1486
|
+
const Qn = vt.__EXTEND_POINT__, Ae = Lt(Qn), re = {
|
|
1487
|
+
NOT_FOUND_KEY: Qn,
|
|
1569
1488
|
// 2
|
|
1570
|
-
FALLBACK_TO_TRANSLATE:
|
|
1489
|
+
FALLBACK_TO_TRANSLATE: Ae(),
|
|
1571
1490
|
// 3
|
|
1572
|
-
CANNOT_FORMAT_NUMBER:
|
|
1491
|
+
CANNOT_FORMAT_NUMBER: Ae(),
|
|
1573
1492
|
// 4
|
|
1574
|
-
FALLBACK_TO_NUMBER_FORMAT:
|
|
1493
|
+
FALLBACK_TO_NUMBER_FORMAT: Ae(),
|
|
1575
1494
|
// 5
|
|
1576
|
-
CANNOT_FORMAT_DATE:
|
|
1495
|
+
CANNOT_FORMAT_DATE: Ae(),
|
|
1577
1496
|
// 6
|
|
1578
|
-
FALLBACK_TO_DATE_FORMAT:
|
|
1497
|
+
FALLBACK_TO_DATE_FORMAT: Ae(),
|
|
1579
1498
|
// 7
|
|
1580
|
-
EXPERIMENTAL_CUSTOM_MESSAGE_COMPILER:
|
|
1499
|
+
EXPERIMENTAL_CUSTOM_MESSAGE_COMPILER: Ae(),
|
|
1581
1500
|
// 8
|
|
1582
|
-
__EXTEND_POINT__:
|
|
1501
|
+
__EXTEND_POINT__: Ae()
|
|
1583
1502
|
// 9
|
|
1584
|
-
},
|
|
1585
|
-
[
|
|
1586
|
-
[
|
|
1587
|
-
[
|
|
1588
|
-
[
|
|
1589
|
-
[
|
|
1590
|
-
[
|
|
1591
|
-
[
|
|
1503
|
+
}, ns = {
|
|
1504
|
+
[re.NOT_FOUND_KEY]: "Not found '{key}' key in '{locale}' locale messages.",
|
|
1505
|
+
[re.FALLBACK_TO_TRANSLATE]: "Fall back to translate '{key}' key with '{target}' locale.",
|
|
1506
|
+
[re.CANNOT_FORMAT_NUMBER]: "Cannot format a number value due to not supported Intl.NumberFormat.",
|
|
1507
|
+
[re.FALLBACK_TO_NUMBER_FORMAT]: "Fall back to number format '{key}' key with '{target}' locale.",
|
|
1508
|
+
[re.CANNOT_FORMAT_DATE]: "Cannot format a date value due to not supported Intl.DateTimeFormat.",
|
|
1509
|
+
[re.FALLBACK_TO_DATE_FORMAT]: "Fall back to datetime format '{key}' key with '{target}' locale.",
|
|
1510
|
+
[re.EXPERIMENTAL_CUSTOM_MESSAGE_COMPILER]: "This project is using Custom Message Compiler, which is an experimental feature. It may receive breaking changes or be removed in the future."
|
|
1592
1511
|
};
|
|
1593
|
-
function
|
|
1594
|
-
return
|
|
1512
|
+
function De(e, ...t) {
|
|
1513
|
+
return Ht(ns[e], ...t);
|
|
1595
1514
|
}
|
|
1596
|
-
const
|
|
1597
|
-
INVALID_ARGUMENT:
|
|
1515
|
+
const qn = M.__EXTEND_POINT__, Ce = Lt(qn), z = {
|
|
1516
|
+
INVALID_ARGUMENT: qn,
|
|
1598
1517
|
// 17
|
|
1599
|
-
INVALID_DATE_ARGUMENT:
|
|
1518
|
+
INVALID_DATE_ARGUMENT: Ce(),
|
|
1600
1519
|
// 18
|
|
1601
|
-
INVALID_ISO_DATE_ARGUMENT:
|
|
1520
|
+
INVALID_ISO_DATE_ARGUMENT: Ce(),
|
|
1602
1521
|
// 19
|
|
1603
|
-
NOT_SUPPORT_NON_STRING_MESSAGE:
|
|
1522
|
+
NOT_SUPPORT_NON_STRING_MESSAGE: Ce(),
|
|
1604
1523
|
// 20
|
|
1605
|
-
NOT_SUPPORT_LOCALE_PROMISE_VALUE:
|
|
1524
|
+
NOT_SUPPORT_LOCALE_PROMISE_VALUE: Ce(),
|
|
1606
1525
|
// 21
|
|
1607
|
-
NOT_SUPPORT_LOCALE_ASYNC_FUNCTION:
|
|
1526
|
+
NOT_SUPPORT_LOCALE_ASYNC_FUNCTION: Ce(),
|
|
1608
1527
|
// 22
|
|
1609
|
-
NOT_SUPPORT_LOCALE_TYPE:
|
|
1528
|
+
NOT_SUPPORT_LOCALE_TYPE: Ce(),
|
|
1610
1529
|
// 23
|
|
1611
|
-
__EXTEND_POINT__:
|
|
1530
|
+
__EXTEND_POINT__: Ce()
|
|
1612
1531
|
// 24
|
|
1613
1532
|
};
|
|
1614
|
-
function
|
|
1615
|
-
return
|
|
1616
|
-
}
|
|
1617
|
-
const
|
|
1618
|
-
[
|
|
1619
|
-
[
|
|
1620
|
-
[
|
|
1621
|
-
[
|
|
1622
|
-
[
|
|
1623
|
-
[
|
|
1624
|
-
[
|
|
1533
|
+
function de(e) {
|
|
1534
|
+
return Ge(e, null, process.env.NODE_ENV !== "production" ? { messages: rs } : void 0);
|
|
1535
|
+
}
|
|
1536
|
+
const rs = {
|
|
1537
|
+
[z.INVALID_ARGUMENT]: "Invalid arguments",
|
|
1538
|
+
[z.INVALID_DATE_ARGUMENT]: "The date provided is an invalid Date object.Make sure your Date represents a valid date.",
|
|
1539
|
+
[z.INVALID_ISO_DATE_ARGUMENT]: "The argument provided is not a valid ISO date string",
|
|
1540
|
+
[z.NOT_SUPPORT_NON_STRING_MESSAGE]: "Not support non-string message",
|
|
1541
|
+
[z.NOT_SUPPORT_LOCALE_PROMISE_VALUE]: "cannot support promise value",
|
|
1542
|
+
[z.NOT_SUPPORT_LOCALE_ASYNC_FUNCTION]: "cannot support async function",
|
|
1543
|
+
[z.NOT_SUPPORT_LOCALE_TYPE]: "cannot support locale type"
|
|
1625
1544
|
};
|
|
1626
|
-
function
|
|
1627
|
-
return t.locale != null ?
|
|
1545
|
+
function Xt(e, t) {
|
|
1546
|
+
return t.locale != null ? fn(t.locale) : fn(e.locale);
|
|
1628
1547
|
}
|
|
1629
|
-
let
|
|
1630
|
-
function
|
|
1631
|
-
if (
|
|
1548
|
+
let Ct;
|
|
1549
|
+
function fn(e) {
|
|
1550
|
+
if (A(e))
|
|
1632
1551
|
return e;
|
|
1633
|
-
if (
|
|
1634
|
-
if (e.resolvedOnce &&
|
|
1635
|
-
return
|
|
1552
|
+
if (H(e)) {
|
|
1553
|
+
if (e.resolvedOnce && Ct != null)
|
|
1554
|
+
return Ct;
|
|
1636
1555
|
if (e.constructor.name === "Function") {
|
|
1637
1556
|
const t = e();
|
|
1638
|
-
if (
|
|
1639
|
-
throw
|
|
1640
|
-
return
|
|
1557
|
+
if (zr(t))
|
|
1558
|
+
throw de(z.NOT_SUPPORT_LOCALE_PROMISE_VALUE);
|
|
1559
|
+
return Ct = t;
|
|
1641
1560
|
} else
|
|
1642
|
-
throw
|
|
1561
|
+
throw de(z.NOT_SUPPORT_LOCALE_ASYNC_FUNCTION);
|
|
1643
1562
|
} else
|
|
1644
|
-
throw
|
|
1563
|
+
throw de(z.NOT_SUPPORT_LOCALE_TYPE);
|
|
1645
1564
|
}
|
|
1646
|
-
function
|
|
1565
|
+
function as(e, t, n) {
|
|
1647
1566
|
return [.../* @__PURE__ */ new Set([
|
|
1648
1567
|
n,
|
|
1649
|
-
...
|
|
1568
|
+
...X(t) ? t : $(t) ? Object.keys(t) : A(t) ? [t] : [n]
|
|
1650
1569
|
])];
|
|
1651
1570
|
}
|
|
1652
|
-
function
|
|
1653
|
-
const a =
|
|
1571
|
+
function Zn(e, t, n) {
|
|
1572
|
+
const a = A(n) ? n : We, s = e;
|
|
1654
1573
|
s.__localeChainCache || (s.__localeChainCache = /* @__PURE__ */ new Map());
|
|
1655
1574
|
let r = s.__localeChainCache.get(a);
|
|
1656
1575
|
if (!r) {
|
|
1657
1576
|
r = [];
|
|
1658
1577
|
let l = [n];
|
|
1659
|
-
for (;
|
|
1660
|
-
l =
|
|
1661
|
-
const
|
|
1662
|
-
l =
|
|
1578
|
+
for (; X(l); )
|
|
1579
|
+
l = mn(r, l, t);
|
|
1580
|
+
const i = X(t) || !F(t) ? t : t.default ? t.default : null;
|
|
1581
|
+
l = A(i) ? [i] : i, X(l) && mn(r, l, !1), s.__localeChainCache.set(a, r);
|
|
1663
1582
|
}
|
|
1664
1583
|
return r;
|
|
1665
1584
|
}
|
|
1666
|
-
function
|
|
1585
|
+
function mn(e, t, n) {
|
|
1667
1586
|
let a = !0;
|
|
1668
1587
|
for (let s = 0; s < t.length && U(a); s++) {
|
|
1669
1588
|
const r = t[s];
|
|
1670
|
-
|
|
1589
|
+
A(r) && (a = ss(e, t[s], n));
|
|
1671
1590
|
}
|
|
1672
1591
|
return a;
|
|
1673
1592
|
}
|
|
1674
|
-
function
|
|
1593
|
+
function ss(e, t, n) {
|
|
1675
1594
|
let a;
|
|
1676
1595
|
const s = t.split("-");
|
|
1677
1596
|
do {
|
|
1678
1597
|
const r = s.join("-");
|
|
1679
|
-
a =
|
|
1598
|
+
a = ls(e, r, n), s.splice(-1, 1);
|
|
1680
1599
|
} while (s.length && a === !0);
|
|
1681
1600
|
return a;
|
|
1682
1601
|
}
|
|
1683
|
-
function
|
|
1602
|
+
function ls(e, t, n) {
|
|
1684
1603
|
let a = !1;
|
|
1685
1604
|
if (!e.includes(t) && (a = !0, t)) {
|
|
1686
1605
|
a = t[t.length - 1] !== "!";
|
|
1687
1606
|
const s = t.replace(/!/g, "");
|
|
1688
|
-
e.push(s), (
|
|
1607
|
+
e.push(s), (X(n) || F(n)) && n[s] && (a = n[s]);
|
|
1689
1608
|
}
|
|
1690
1609
|
return a;
|
|
1691
1610
|
}
|
|
1692
|
-
const
|
|
1693
|
-
function
|
|
1611
|
+
const os = "9.14.0", It = -1, We = "en-US", Tt = "", dn = (e) => `${e.charAt(0).toLocaleUpperCase()}${e.substr(1)}`;
|
|
1612
|
+
function is() {
|
|
1694
1613
|
return {
|
|
1695
|
-
upper: (e, t) => t === "text" &&
|
|
1696
|
-
lower: (e, t) => t === "text" &&
|
|
1697
|
-
capitalize: (e, t) => t === "text" &&
|
|
1614
|
+
upper: (e, t) => t === "text" && A(e) ? e.toUpperCase() : t === "vnode" && $(e) && "__v_isVNode" in e ? e.children.toUpperCase() : e,
|
|
1615
|
+
lower: (e, t) => t === "text" && A(e) ? e.toLowerCase() : t === "vnode" && $(e) && "__v_isVNode" in e ? e.children.toLowerCase() : e,
|
|
1616
|
+
capitalize: (e, t) => t === "text" && A(e) ? dn(e) : t === "vnode" && $(e) && "__v_isVNode" in e ? dn(e.children) : e
|
|
1698
1617
|
};
|
|
1699
1618
|
}
|
|
1700
|
-
let
|
|
1701
|
-
function
|
|
1702
|
-
|
|
1703
|
-
}
|
|
1704
|
-
let
|
|
1705
|
-
function
|
|
1706
|
-
|
|
1707
|
-
}
|
|
1708
|
-
let
|
|
1709
|
-
function
|
|
1710
|
-
|
|
1711
|
-
}
|
|
1712
|
-
let
|
|
1713
|
-
const
|
|
1714
|
-
|
|
1715
|
-
},
|
|
1716
|
-
let
|
|
1717
|
-
const
|
|
1718
|
-
|
|
1719
|
-
},
|
|
1720
|
-
let
|
|
1721
|
-
function
|
|
1722
|
-
const t =
|
|
1723
|
-
process.env.NODE_ENV !== "production" &&
|
|
1724
|
-
const L =
|
|
1725
|
-
|
|
1619
|
+
let zn;
|
|
1620
|
+
function En(e) {
|
|
1621
|
+
zn = e;
|
|
1622
|
+
}
|
|
1623
|
+
let er;
|
|
1624
|
+
function cs(e) {
|
|
1625
|
+
er = e;
|
|
1626
|
+
}
|
|
1627
|
+
let tr;
|
|
1628
|
+
function us(e) {
|
|
1629
|
+
tr = e;
|
|
1630
|
+
}
|
|
1631
|
+
let nr = null;
|
|
1632
|
+
const _s = /* @__NO_SIDE_EFFECTS__ */ (e) => {
|
|
1633
|
+
nr = e;
|
|
1634
|
+
}, fs = /* @__NO_SIDE_EFFECTS__ */ () => nr;
|
|
1635
|
+
let rr = null;
|
|
1636
|
+
const gn = (e) => {
|
|
1637
|
+
rr = e;
|
|
1638
|
+
}, ms = () => rr;
|
|
1639
|
+
let Nn = 0;
|
|
1640
|
+
function ds(e = {}) {
|
|
1641
|
+
const t = H(e.onWarn) ? e.onWarn : q, n = A(e.version) ? e.version : os, a = A(e.locale) || H(e.locale) ? e.locale : We, s = H(a) ? We : a, r = X(e.fallbackLocale) || F(e.fallbackLocale) || A(e.fallbackLocale) || e.fallbackLocale === !1 ? e.fallbackLocale : s, l = F(e.messages) ? e.messages : { [s]: {} }, i = F(e.datetimeFormats) ? e.datetimeFormats : { [s]: {} }, u = F(e.numberFormats) ? e.numberFormats : { [s]: {} }, f = ee({}, e.modifiers || {}, is()), p = e.pluralRules || {}, T = H(e.missing) ? e.missing : null, d = U(e.missingWarn) || Le(e.missingWarn) ? e.missingWarn : !0, h = U(e.fallbackWarn) || Le(e.fallbackWarn) ? e.fallbackWarn : !0, D = !!e.fallbackFormat, S = !!e.unresolving, P = H(e.postTranslation) ? e.postTranslation : null, y = F(e.processor) ? e.processor : null, R = U(e.warnHtmlMessage) ? e.warnHtmlMessage : !0, _ = !!e.escapeParameter, E = H(e.messageCompiler) ? e.messageCompiler : zn;
|
|
1642
|
+
process.env.NODE_ENV !== "production" && H(e.messageCompiler) && Xn(De(re.EXPERIMENTAL_CUSTOM_MESSAGE_COMPILER));
|
|
1643
|
+
const L = H(e.messageResolver) ? e.messageResolver : er || xa, g = H(e.localeFallbacker) ? e.localeFallbacker : tr || as, v = $(e.fallbackContext) ? e.fallbackContext : void 0, C = e, I = $(C.__datetimeFormatters) ? C.__datetimeFormatters : /* @__PURE__ */ new Map(), B = $(C.__numberFormatters) ? C.__numberFormatters : /* @__PURE__ */ new Map(), le = $(C.__meta) ? C.__meta : {};
|
|
1644
|
+
Nn++;
|
|
1726
1645
|
const w = {
|
|
1727
1646
|
version: n,
|
|
1728
|
-
cid:
|
|
1647
|
+
cid: Nn,
|
|
1729
1648
|
locale: a,
|
|
1730
1649
|
fallbackLocale: r,
|
|
1731
1650
|
messages: l,
|
|
1732
|
-
modifiers:
|
|
1651
|
+
modifiers: f,
|
|
1733
1652
|
pluralRules: p,
|
|
1734
1653
|
missing: T,
|
|
1735
1654
|
missingWarn: d,
|
|
1736
|
-
fallbackWarn:
|
|
1655
|
+
fallbackWarn: h,
|
|
1737
1656
|
fallbackFormat: D,
|
|
1738
|
-
unresolving:
|
|
1739
|
-
postTranslation:
|
|
1657
|
+
unresolving: S,
|
|
1658
|
+
postTranslation: P,
|
|
1740
1659
|
processor: y,
|
|
1741
1660
|
warnHtmlMessage: R,
|
|
1742
|
-
escapeParameter:
|
|
1661
|
+
escapeParameter: _,
|
|
1743
1662
|
messageCompiler: E,
|
|
1744
1663
|
messageResolver: L,
|
|
1745
1664
|
localeFallbacker: g,
|
|
1746
1665
|
fallbackContext: v,
|
|
1747
1666
|
onWarn: t,
|
|
1748
|
-
__meta:
|
|
1667
|
+
__meta: le
|
|
1749
1668
|
};
|
|
1750
|
-
return w.datetimeFormats =
|
|
1669
|
+
return w.datetimeFormats = i, w.numberFormats = u, w.__datetimeFormatters = I, w.__numberFormatters = B, process.env.NODE_ENV !== "production" && (w.__v_emitter = C.__v_emitter != null ? C.__v_emitter : void 0), (process.env.NODE_ENV !== "production" || __INTLIFY_PROD_DEVTOOLS__) && za(w, n, le), w;
|
|
1751
1670
|
}
|
|
1752
|
-
|
|
1753
|
-
function Pt(e, t) {
|
|
1671
|
+
function bt(e, t) {
|
|
1754
1672
|
return e instanceof RegExp ? e.test(t) : e;
|
|
1755
1673
|
}
|
|
1756
|
-
function
|
|
1674
|
+
function ar(e, t) {
|
|
1757
1675
|
return e instanceof RegExp ? e.test(t) : e;
|
|
1758
1676
|
}
|
|
1759
|
-
function
|
|
1677
|
+
function jt(e, t, n, a, s) {
|
|
1760
1678
|
const { missing: r, onWarn: l } = e;
|
|
1761
1679
|
if (process.env.NODE_ENV !== "production") {
|
|
1762
|
-
const
|
|
1763
|
-
|
|
1680
|
+
const i = e.__v_emitter;
|
|
1681
|
+
i && i.emit("missing", {
|
|
1764
1682
|
locale: n,
|
|
1765
1683
|
key: t,
|
|
1766
1684
|
type: s,
|
|
@@ -1768,234 +1686,229 @@ function zt(e, t, n, a, s) {
|
|
|
1768
1686
|
});
|
|
1769
1687
|
}
|
|
1770
1688
|
if (r !== null) {
|
|
1771
|
-
const
|
|
1772
|
-
return
|
|
1689
|
+
const i = r(e, n, t, s);
|
|
1690
|
+
return A(i) ? i : t;
|
|
1773
1691
|
} else
|
|
1774
|
-
return process.env.NODE_ENV !== "production" &&
|
|
1692
|
+
return process.env.NODE_ENV !== "production" && ar(a, t) && l(De(re.NOT_FOUND_KEY, { key: t, locale: n })), t;
|
|
1775
1693
|
}
|
|
1776
|
-
function
|
|
1694
|
+
function at(e, t, n) {
|
|
1777
1695
|
const a = e;
|
|
1778
1696
|
a.__localeChainCache = /* @__PURE__ */ new Map(), e.localeFallbacker(e, n, t);
|
|
1779
1697
|
}
|
|
1780
|
-
function
|
|
1698
|
+
function sr(e, t) {
|
|
1781
1699
|
return e === t ? !1 : e.split("-")[0] === t.split("-")[0];
|
|
1782
1700
|
}
|
|
1783
|
-
function
|
|
1701
|
+
function Es(e, t) {
|
|
1784
1702
|
const n = t.indexOf(e);
|
|
1785
1703
|
if (n === -1)
|
|
1786
1704
|
return !1;
|
|
1787
1705
|
for (let a = n + 1; a < t.length; a++)
|
|
1788
|
-
if (
|
|
1706
|
+
if (sr(e, t[a]))
|
|
1789
1707
|
return !0;
|
|
1790
1708
|
return !1;
|
|
1791
1709
|
}
|
|
1792
|
-
function
|
|
1793
|
-
return (n) =>
|
|
1710
|
+
function St(e) {
|
|
1711
|
+
return (n) => gs(n, e);
|
|
1794
1712
|
}
|
|
1795
|
-
function
|
|
1796
|
-
const n =
|
|
1797
|
-
if (n
|
|
1798
|
-
|
|
1799
|
-
|
|
1800
|
-
|
|
1801
|
-
|
|
1802
|
-
if (qt(n) === 1) {
|
|
1803
|
-
const r = ts(n);
|
|
1804
|
-
return e.plural(r.reduce((l, o) => [
|
|
1805
|
-
...l,
|
|
1806
|
-
hn(e, o)
|
|
1713
|
+
function gs(e, t) {
|
|
1714
|
+
const n = t.b || t.body;
|
|
1715
|
+
if ((n.t || n.type) === 1) {
|
|
1716
|
+
const a = n, s = a.c || a.cases;
|
|
1717
|
+
return e.plural(s.reduce((r, l) => [
|
|
1718
|
+
...r,
|
|
1719
|
+
pn(e, l)
|
|
1807
1720
|
], []));
|
|
1808
1721
|
} else
|
|
1809
|
-
return
|
|
1722
|
+
return pn(e, n);
|
|
1810
1723
|
}
|
|
1811
|
-
function
|
|
1812
|
-
const n =
|
|
1813
|
-
if (n
|
|
1724
|
+
function pn(e, t) {
|
|
1725
|
+
const n = t.s || t.static;
|
|
1726
|
+
if (n)
|
|
1814
1727
|
return e.type === "text" ? n : e.normalize([n]);
|
|
1815
1728
|
{
|
|
1816
|
-
const a =
|
|
1729
|
+
const a = (t.i || t.items).reduce((s, r) => [...s, kt(e, r)], []);
|
|
1817
1730
|
return e.normalize(a);
|
|
1818
1731
|
}
|
|
1819
1732
|
}
|
|
1820
|
-
function
|
|
1821
|
-
const n =
|
|
1733
|
+
function kt(e, t) {
|
|
1734
|
+
const n = t.t || t.type;
|
|
1822
1735
|
switch (n) {
|
|
1823
|
-
case 3:
|
|
1824
|
-
|
|
1825
|
-
|
|
1826
|
-
|
|
1736
|
+
case 3: {
|
|
1737
|
+
const a = t;
|
|
1738
|
+
return a.v || a.value;
|
|
1739
|
+
}
|
|
1740
|
+
case 9: {
|
|
1741
|
+
const a = t;
|
|
1742
|
+
return a.v || a.value;
|
|
1743
|
+
}
|
|
1827
1744
|
case 4: {
|
|
1828
1745
|
const a = t;
|
|
1829
|
-
|
|
1830
|
-
return e.interpolate(e.named(a.k));
|
|
1831
|
-
if (me(a, "key") && a.key)
|
|
1832
|
-
return e.interpolate(e.named(a.key));
|
|
1833
|
-
throw ct(n);
|
|
1746
|
+
return e.interpolate(e.named(a.k || a.key));
|
|
1834
1747
|
}
|
|
1835
1748
|
case 5: {
|
|
1836
1749
|
const a = t;
|
|
1837
|
-
|
|
1838
|
-
return e.interpolate(e.list(a.i));
|
|
1839
|
-
if (me(a, "index") && q(a.index))
|
|
1840
|
-
return e.interpolate(e.list(a.index));
|
|
1841
|
-
throw ct(n);
|
|
1750
|
+
return e.interpolate(e.list(a.i != null ? a.i : a.index));
|
|
1842
1751
|
}
|
|
1843
1752
|
case 6: {
|
|
1844
|
-
const a = t, s =
|
|
1845
|
-
return e.linked(
|
|
1753
|
+
const a = t, s = a.m || a.modifier;
|
|
1754
|
+
return e.linked(kt(e, a.k || a.key), s ? kt(e, s) : void 0, e.type);
|
|
1755
|
+
}
|
|
1756
|
+
case 7: {
|
|
1757
|
+
const a = t;
|
|
1758
|
+
return a.v || a.value;
|
|
1759
|
+
}
|
|
1760
|
+
case 8: {
|
|
1761
|
+
const a = t;
|
|
1762
|
+
return a.v || a.value;
|
|
1846
1763
|
}
|
|
1847
|
-
case 7:
|
|
1848
|
-
return Tt(t, n);
|
|
1849
|
-
case 8:
|
|
1850
|
-
return Tt(t, n);
|
|
1851
1764
|
default:
|
|
1852
|
-
throw new Error(`unhandled node on format message part: ${n}`);
|
|
1765
|
+
throw new Error(`unhandled node type on format message part: ${n}`);
|
|
1853
1766
|
}
|
|
1854
1767
|
}
|
|
1855
|
-
const
|
|
1856
|
-
function
|
|
1857
|
-
t &&
|
|
1768
|
+
const Ns = "Detected HTML in '{source}' message. Recommend not using HTML messages to avoid XSS.";
|
|
1769
|
+
function lr(e, t) {
|
|
1770
|
+
t && _a(e) && q(Ht(Ns, { source: e }));
|
|
1858
1771
|
}
|
|
1859
|
-
const
|
|
1860
|
-
let
|
|
1861
|
-
function
|
|
1862
|
-
e.code ===
|
|
1772
|
+
const or = (e) => e;
|
|
1773
|
+
let Ve = /* @__PURE__ */ Object.create(null);
|
|
1774
|
+
function ir(e) {
|
|
1775
|
+
e.code === vt.USE_MODULO_SYNTAX && q(`The use of named interpolation with modulo syntax is deprecated. It will be removed in v10.
|
|
1863
1776
|
reference: https://vue-i18n.intlify.dev/guide/essentials/syntax#rails-i18n-format
|
|
1864
1777
|
(message compiler warning message: ${e.message})`);
|
|
1865
1778
|
}
|
|
1866
|
-
|
|
1779
|
+
const ve = (e) => $(e) && (e.t === 0 || e.type === 0) && ("b" in e || "body" in e);
|
|
1780
|
+
function cr(e, t = {}) {
|
|
1867
1781
|
let n = !1;
|
|
1868
|
-
const a = t.onError ||
|
|
1782
|
+
const a = t.onError || ca;
|
|
1869
1783
|
return t.onError = (s) => {
|
|
1870
1784
|
n = !0, a(s);
|
|
1871
|
-
}, { ...
|
|
1785
|
+
}, { ...Ma(e, t), detectError: n };
|
|
1872
1786
|
}
|
|
1873
|
-
const
|
|
1874
|
-
if (!
|
|
1875
|
-
throw
|
|
1876
|
-
process.env.NODE_ENV !== "production" && (t.onWarn =
|
|
1787
|
+
const ps = /* @__NO_SIDE_EFFECTS__ */ (e, t) => {
|
|
1788
|
+
if (!A(e))
|
|
1789
|
+
throw de(z.NOT_SUPPORT_NON_STRING_MESSAGE);
|
|
1790
|
+
process.env.NODE_ENV !== "production" && (t.onWarn = ir);
|
|
1877
1791
|
{
|
|
1878
1792
|
const n = U(t.warnHtmlMessage) ? t.warnHtmlMessage : !0;
|
|
1879
|
-
process.env.NODE_ENV !== "production" &&
|
|
1880
|
-
const s = (t.onCacheKey ||
|
|
1793
|
+
process.env.NODE_ENV !== "production" && lr(e, n);
|
|
1794
|
+
const s = (t.onCacheKey || or)(e), r = Ve[s];
|
|
1881
1795
|
if (r)
|
|
1882
1796
|
return r;
|
|
1883
|
-
const { code: l, detectError:
|
|
1884
|
-
return
|
|
1797
|
+
const { code: l, detectError: i } = cr(e, t), u = new Function(`return ${l}`)();
|
|
1798
|
+
return i ? u : Ve[s] = u;
|
|
1885
1799
|
}
|
|
1886
1800
|
};
|
|
1887
|
-
function
|
|
1888
|
-
if (process.env.NODE_ENV !== "production" && (t.onWarn =
|
|
1801
|
+
function Ts(e, t) {
|
|
1802
|
+
if (process.env.NODE_ENV !== "production" && (t.onWarn = ir), __INTLIFY_JIT_COMPILATION__ && !__INTLIFY_DROP_MESSAGE_COMPILER__ && A(e)) {
|
|
1889
1803
|
const n = U(t.warnHtmlMessage) ? t.warnHtmlMessage : !0;
|
|
1890
|
-
process.env.NODE_ENV !== "production" &&
|
|
1891
|
-
const s = (t.onCacheKey ||
|
|
1804
|
+
process.env.NODE_ENV !== "production" && lr(e, n);
|
|
1805
|
+
const s = (t.onCacheKey || or)(e), r = Ve[s];
|
|
1892
1806
|
if (r)
|
|
1893
1807
|
return r;
|
|
1894
|
-
const { ast: l, detectError:
|
|
1808
|
+
const { ast: l, detectError: i } = cr(e, {
|
|
1895
1809
|
...t,
|
|
1896
1810
|
location: process.env.NODE_ENV !== "production",
|
|
1897
1811
|
jit: !0
|
|
1898
|
-
}), u =
|
|
1899
|
-
return
|
|
1812
|
+
}), u = St(l);
|
|
1813
|
+
return i ? u : Ve[s] = u;
|
|
1900
1814
|
} else {
|
|
1901
|
-
if (process.env.NODE_ENV !== "production" && !
|
|
1902
|
-
return
|
|
1815
|
+
if (process.env.NODE_ENV !== "production" && !ve(e))
|
|
1816
|
+
return q(`the message that is resolve with key '${t.key}' is not supported for jit compilation`), () => e;
|
|
1903
1817
|
const n = e.cacheKey;
|
|
1904
1818
|
if (n) {
|
|
1905
|
-
const a =
|
|
1906
|
-
return a || (
|
|
1819
|
+
const a = Ve[n];
|
|
1820
|
+
return a || (Ve[n] = St(e));
|
|
1907
1821
|
} else
|
|
1908
|
-
return
|
|
1822
|
+
return St(e);
|
|
1909
1823
|
}
|
|
1910
1824
|
}
|
|
1911
|
-
const
|
|
1912
|
-
function
|
|
1913
|
-
const { fallbackFormat: n, postTranslation: a, unresolving: s, messageCompiler: r, fallbackLocale: l, messages:
|
|
1914
|
-
d &&
|
|
1915
|
-
let [y, R,
|
|
1825
|
+
const Tn = () => "", ce = (e) => H(e);
|
|
1826
|
+
function On(e, ...t) {
|
|
1827
|
+
const { fallbackFormat: n, postTranslation: a, unresolving: s, messageCompiler: r, fallbackLocale: l, messages: i } = e, [u, f] = yt(...t), p = U(f.missingWarn) ? f.missingWarn : e.missingWarn, T = U(f.fallbackWarn) ? f.fallbackWarn : e.fallbackWarn, d = U(f.escapeParameter) ? f.escapeParameter : e.escapeParameter, h = !!f.resolvedMessage, D = A(f.default) || U(f.default) ? U(f.default) ? r ? u : () => u : f.default : n ? r ? u : () => u : "", S = n || D !== "", P = Xt(e, f);
|
|
1828
|
+
d && Os(f);
|
|
1829
|
+
let [y, R, _] = h ? [
|
|
1916
1830
|
u,
|
|
1917
|
-
|
|
1918
|
-
|
|
1919
|
-
] :
|
|
1920
|
-
if (!
|
|
1921
|
-
return s ?
|
|
1922
|
-
if (process.env.NODE_ENV !== "production" &&
|
|
1923
|
-
return
|
|
1831
|
+
P,
|
|
1832
|
+
i[P] || {}
|
|
1833
|
+
] : ur(e, u, P, l, T, p), E = y, L = u;
|
|
1834
|
+
if (!h && !(A(E) || ve(E) || ce(E)) && S && (E = D, L = E), !h && (!(A(E) || ve(E) || ce(E)) || !A(R)))
|
|
1835
|
+
return s ? It : u;
|
|
1836
|
+
if (process.env.NODE_ENV !== "production" && A(E) && e.messageCompiler == null)
|
|
1837
|
+
return q(`The message format compilation is not supported in this build. Because message compiler isn't included. You need to pre-compilation all message format. So translate function return '${u}'.`), u;
|
|
1924
1838
|
let g = !1;
|
|
1925
1839
|
const v = () => {
|
|
1926
1840
|
g = !0;
|
|
1927
|
-
}, C =
|
|
1841
|
+
}, C = ce(E) ? E : _r(e, u, R, E, L, v);
|
|
1928
1842
|
if (g)
|
|
1929
1843
|
return E;
|
|
1930
|
-
const I =
|
|
1931
|
-
|
|
1932
|
-
|
|
1933
|
-
const ne = {
|
|
1844
|
+
const I = bs(e, R, _, f), B = qa(I), le = Ls(e, C, B), w = a ? a(le, u) : le;
|
|
1845
|
+
if (process.env.NODE_ENV !== "production" || __INTLIFY_PROD_DEVTOOLS__) {
|
|
1846
|
+
const te = {
|
|
1934
1847
|
timestamp: Date.now(),
|
|
1935
|
-
key:
|
|
1936
|
-
locale: R || (
|
|
1937
|
-
format:
|
|
1848
|
+
key: A(u) ? u : ce(E) ? E.key : "",
|
|
1849
|
+
locale: R || (ce(E) ? E.locale : ""),
|
|
1850
|
+
format: A(E) ? E : ce(E) ? E.source : "",
|
|
1938
1851
|
message: w
|
|
1939
1852
|
};
|
|
1940
|
-
|
|
1853
|
+
te.meta = ee({}, e.__meta, /* @__PURE__ */ fs() || {}), es(te);
|
|
1941
1854
|
}
|
|
1942
1855
|
return w;
|
|
1943
1856
|
}
|
|
1944
|
-
function
|
|
1945
|
-
|
|
1946
|
-
|
|
1857
|
+
function Os(e) {
|
|
1858
|
+
X(e.list) ? e.list = e.list.map((t) => A(t) ? nn(t) : t) : $(e.named) && Object.keys(e.named).forEach((t) => {
|
|
1859
|
+
A(e.named[t]) && (e.named[t] = nn(e.named[t]));
|
|
1947
1860
|
});
|
|
1948
1861
|
}
|
|
1949
|
-
function
|
|
1950
|
-
const { messages: l, onWarn:
|
|
1951
|
-
let T =
|
|
1952
|
-
const
|
|
1862
|
+
function ur(e, t, n, a, s, r) {
|
|
1863
|
+
const { messages: l, onWarn: i, messageResolver: u, localeFallbacker: f } = e, p = f(e, a, n);
|
|
1864
|
+
let T = {}, d, h = null, D = n, S = null;
|
|
1865
|
+
const P = "translate";
|
|
1953
1866
|
for (let y = 0; y < p.length; y++) {
|
|
1954
|
-
if (d =
|
|
1867
|
+
if (d = S = p[y], process.env.NODE_ENV !== "production" && n !== d && !sr(n, d) && bt(s, t) && i(De(re.FALLBACK_TO_TRANSLATE, {
|
|
1955
1868
|
key: t,
|
|
1956
1869
|
target: d
|
|
1957
1870
|
})), process.env.NODE_ENV !== "production" && n !== d) {
|
|
1958
1871
|
const L = e.__v_emitter;
|
|
1959
1872
|
L && L.emit("fallback", {
|
|
1960
|
-
type:
|
|
1873
|
+
type: P,
|
|
1961
1874
|
key: t,
|
|
1962
1875
|
from: D,
|
|
1963
|
-
to:
|
|
1964
|
-
groupId: `${
|
|
1876
|
+
to: S,
|
|
1877
|
+
groupId: `${P}:${t}`
|
|
1965
1878
|
});
|
|
1966
1879
|
}
|
|
1967
|
-
T = l[d] ||
|
|
1968
|
-
let R = null,
|
|
1969
|
-
if (process.env.NODE_ENV !== "production" &&
|
|
1880
|
+
T = l[d] || {};
|
|
1881
|
+
let R = null, _, E;
|
|
1882
|
+
if (process.env.NODE_ENV !== "production" && _e && (R = window.performance.now(), _ = "intlify-message-resolve-start", E = "intlify-message-resolve-end", oe && oe(_)), (h = u(T, t)) === null && (h = T[t]), process.env.NODE_ENV !== "production" && _e) {
|
|
1970
1883
|
const L = window.performance.now(), g = e.__v_emitter;
|
|
1971
|
-
g && R &&
|
|
1884
|
+
g && R && h && g.emit("message-resolve", {
|
|
1972
1885
|
type: "message-resolve",
|
|
1973
1886
|
key: t,
|
|
1974
|
-
message:
|
|
1887
|
+
message: h,
|
|
1975
1888
|
time: L - R,
|
|
1976
|
-
groupId: `${
|
|
1977
|
-
}),
|
|
1889
|
+
groupId: `${P}:${t}`
|
|
1890
|
+
}), _ && E && oe && Pe && (oe(E), Pe("intlify message resolve", _, E));
|
|
1978
1891
|
}
|
|
1979
|
-
if (h
|
|
1892
|
+
if (A(h) || ve(h) || ce(h))
|
|
1980
1893
|
break;
|
|
1981
|
-
if (
|
|
1982
|
-
const L =
|
|
1894
|
+
if (!Es(d, p)) {
|
|
1895
|
+
const L = jt(
|
|
1983
1896
|
e,
|
|
1984
1897
|
// eslint-disable-line @typescript-eslint/no-explicit-any
|
|
1985
1898
|
t,
|
|
1986
1899
|
d,
|
|
1987
1900
|
r,
|
|
1988
|
-
|
|
1901
|
+
P
|
|
1989
1902
|
);
|
|
1990
|
-
L !== t && (
|
|
1903
|
+
L !== t && (h = L);
|
|
1991
1904
|
}
|
|
1992
|
-
D =
|
|
1905
|
+
D = S;
|
|
1993
1906
|
}
|
|
1994
|
-
return [
|
|
1907
|
+
return [h, d, T];
|
|
1995
1908
|
}
|
|
1996
|
-
function
|
|
1997
|
-
const { messageCompiler: l, warnHtmlMessage:
|
|
1998
|
-
if (
|
|
1909
|
+
function _r(e, t, n, a, s, r) {
|
|
1910
|
+
const { messageCompiler: l, warnHtmlMessage: i } = e;
|
|
1911
|
+
if (ce(a)) {
|
|
1999
1912
|
const d = a;
|
|
2000
1913
|
return d.locale = d.locale || n, d.key = d.key || t, d;
|
|
2001
1914
|
}
|
|
@@ -2003,117 +1916,118 @@ function Cr(e, t, n, a, s, r) {
|
|
|
2003
1916
|
const d = () => a;
|
|
2004
1917
|
return d.locale = n, d.key = t, d;
|
|
2005
1918
|
}
|
|
2006
|
-
let u = null,
|
|
2007
|
-
process.env.NODE_ENV !== "production" &&
|
|
2008
|
-
const T = l(a,
|
|
2009
|
-
if (process.env.NODE_ENV !== "production" &&
|
|
2010
|
-
const d = window.performance.now(),
|
|
2011
|
-
|
|
1919
|
+
let u = null, f, p;
|
|
1920
|
+
process.env.NODE_ENV !== "production" && _e && (u = window.performance.now(), f = "intlify-message-compilation-start", p = "intlify-message-compilation-end", oe && oe(f));
|
|
1921
|
+
const T = l(a, vs(e, n, s, a, i, r));
|
|
1922
|
+
if (process.env.NODE_ENV !== "production" && _e) {
|
|
1923
|
+
const d = window.performance.now(), h = e.__v_emitter;
|
|
1924
|
+
h && u && h.emit("message-compilation", {
|
|
2012
1925
|
type: "message-compilation",
|
|
2013
1926
|
message: a,
|
|
2014
1927
|
time: d - u,
|
|
2015
1928
|
groupId: `translate:${t}`
|
|
2016
|
-
}),
|
|
1929
|
+
}), f && p && oe && Pe && (oe(p), Pe("intlify message compilation", f, p));
|
|
2017
1930
|
}
|
|
2018
1931
|
return T.locale = n, T.key = t, T.source = a, T;
|
|
2019
1932
|
}
|
|
2020
|
-
function
|
|
1933
|
+
function Ls(e, t, n) {
|
|
2021
1934
|
let a = null, s, r;
|
|
2022
|
-
process.env.NODE_ENV !== "production" &&
|
|
1935
|
+
process.env.NODE_ENV !== "production" && _e && (a = window.performance.now(), s = "intlify-message-evaluation-start", r = "intlify-message-evaluation-end", oe && oe(s));
|
|
2023
1936
|
const l = t(n);
|
|
2024
|
-
if (process.env.NODE_ENV !== "production" &&
|
|
2025
|
-
const
|
|
1937
|
+
if (process.env.NODE_ENV !== "production" && _e) {
|
|
1938
|
+
const i = window.performance.now(), u = e.__v_emitter;
|
|
2026
1939
|
u && a && u.emit("message-evaluation", {
|
|
2027
1940
|
type: "message-evaluation",
|
|
2028
1941
|
value: l,
|
|
2029
|
-
time:
|
|
1942
|
+
time: i - a,
|
|
2030
1943
|
groupId: `translate:${t.key}`
|
|
2031
|
-
}), s && r &&
|
|
1944
|
+
}), s && r && oe && Pe && (oe(r), Pe("intlify message evaluation", s, r));
|
|
2032
1945
|
}
|
|
2033
1946
|
return l;
|
|
2034
1947
|
}
|
|
2035
|
-
function
|
|
2036
|
-
const [t, n, a] = e, s =
|
|
2037
|
-
if (!
|
|
2038
|
-
throw
|
|
2039
|
-
const r =
|
|
2040
|
-
return
|
|
1948
|
+
function yt(...e) {
|
|
1949
|
+
const [t, n, a] = e, s = {};
|
|
1950
|
+
if (!A(t) && !Q(t) && !ce(t) && !ve(t))
|
|
1951
|
+
throw de(z.INVALID_ARGUMENT);
|
|
1952
|
+
const r = Q(t) ? String(t) : (ce(t), t);
|
|
1953
|
+
return Q(n) ? s.plural = n : A(n) ? s.default = n : F(n) && !Ot(n) ? s.named = n : X(n) && (s.list = n), Q(a) ? s.plural = a : A(a) ? s.default = a : F(a) && ee(s, a), [r, s];
|
|
2041
1954
|
}
|
|
2042
|
-
function
|
|
1955
|
+
function vs(e, t, n, a, s, r) {
|
|
2043
1956
|
return {
|
|
2044
1957
|
locale: t,
|
|
2045
1958
|
key: n,
|
|
2046
1959
|
warnHtmlMessage: s,
|
|
2047
1960
|
onError: (l) => {
|
|
2048
1961
|
if (r && r(l), process.env.NODE_ENV !== "production") {
|
|
2049
|
-
const
|
|
2050
|
-
p &&
|
|
2051
|
-
message:
|
|
1962
|
+
const i = Is(a), u = `Message compilation error: ${l.message}`, f = l.location && i && na(i, l.location.start.offset, l.location.end.offset), p = e.__v_emitter;
|
|
1963
|
+
p && i && p.emit("compile-error", {
|
|
1964
|
+
message: i,
|
|
2052
1965
|
error: l.message,
|
|
2053
1966
|
start: l.location && l.location.start.offset,
|
|
2054
1967
|
end: l.location && l.location.end.offset,
|
|
2055
1968
|
groupId: `translate:${n}`
|
|
2056
|
-
}), console.error(
|
|
2057
|
-
${
|
|
1969
|
+
}), console.error(f ? `${u}
|
|
1970
|
+
${f}` : u);
|
|
2058
1971
|
} else
|
|
2059
1972
|
throw l;
|
|
2060
1973
|
},
|
|
2061
|
-
onCacheKey: (l) =>
|
|
1974
|
+
onCacheKey: (l) => Jr(t, n, l)
|
|
2062
1975
|
};
|
|
2063
1976
|
}
|
|
2064
|
-
function
|
|
2065
|
-
if (
|
|
1977
|
+
function Is(e) {
|
|
1978
|
+
if (A(e))
|
|
2066
1979
|
return e;
|
|
2067
1980
|
if (e.loc && e.loc.source)
|
|
2068
1981
|
return e.loc.source;
|
|
2069
1982
|
}
|
|
2070
|
-
function
|
|
2071
|
-
const { modifiers: s, pluralRules: r, messageResolver: l, fallbackLocale:
|
|
1983
|
+
function bs(e, t, n, a) {
|
|
1984
|
+
const { modifiers: s, pluralRules: r, messageResolver: l, fallbackLocale: i, fallbackWarn: u, missingWarn: f, fallbackContext: p } = e, d = {
|
|
2072
1985
|
locale: t,
|
|
2073
1986
|
modifiers: s,
|
|
2074
1987
|
pluralRules: r,
|
|
2075
|
-
messages: (
|
|
2076
|
-
let D = l(n,
|
|
1988
|
+
messages: (h) => {
|
|
1989
|
+
let D = l(n, h);
|
|
2077
1990
|
if (D == null && p) {
|
|
2078
|
-
const [, ,
|
|
2079
|
-
D = l(
|
|
1991
|
+
const [, , S] = ur(p, h, t, i, u, f);
|
|
1992
|
+
D = l(S, h);
|
|
2080
1993
|
}
|
|
2081
|
-
if (
|
|
2082
|
-
let
|
|
2083
|
-
const y =
|
|
2084
|
-
|
|
1994
|
+
if (A(D) || ve(D)) {
|
|
1995
|
+
let S = !1;
|
|
1996
|
+
const y = _r(e, h, t, D, h, () => {
|
|
1997
|
+
S = !0;
|
|
2085
1998
|
});
|
|
2086
|
-
return
|
|
2087
|
-
} else
|
|
1999
|
+
return S ? Tn : y;
|
|
2000
|
+
} else
|
|
2001
|
+
return ce(D) ? D : Tn;
|
|
2088
2002
|
}
|
|
2089
2003
|
};
|
|
2090
|
-
return e.processor && (d.processor = e.processor), a.list && (d.list = a.list), a.named && (d.named = a.named),
|
|
2004
|
+
return e.processor && (d.processor = e.processor), a.list && (d.list = a.list), a.named && (d.named = a.named), Q(a.plural) && (d.pluralIndex = a.plural), d;
|
|
2091
2005
|
}
|
|
2092
|
-
const
|
|
2093
|
-
dateTimeFormat:
|
|
2094
|
-
numberFormat:
|
|
2006
|
+
const Ln = typeof Intl < "u", fr = {
|
|
2007
|
+
dateTimeFormat: Ln && typeof Intl.DateTimeFormat < "u",
|
|
2008
|
+
numberFormat: Ln && typeof Intl.NumberFormat < "u"
|
|
2095
2009
|
};
|
|
2096
|
-
function
|
|
2097
|
-
const { datetimeFormats: n, unresolving: a, fallbackLocale: s, onWarn: r, localeFallbacker: l } = e, { __datetimeFormatters:
|
|
2098
|
-
if (process.env.NODE_ENV !== "production" && !
|
|
2099
|
-
return r(
|
|
2100
|
-
const [u,
|
|
2010
|
+
function vn(e, ...t) {
|
|
2011
|
+
const { datetimeFormats: n, unresolving: a, fallbackLocale: s, onWarn: r, localeFallbacker: l } = e, { __datetimeFormatters: i } = e;
|
|
2012
|
+
if (process.env.NODE_ENV !== "production" && !fr.dateTimeFormat)
|
|
2013
|
+
return r(De(re.CANNOT_FORMAT_DATE)), Tt;
|
|
2014
|
+
const [u, f, p, T] = Mt(...t), d = U(p.missingWarn) ? p.missingWarn : e.missingWarn, h = U(p.fallbackWarn) ? p.fallbackWarn : e.fallbackWarn, D = !!p.part, S = Xt(e, p), P = l(
|
|
2101
2015
|
e,
|
|
2102
2016
|
// eslint-disable-line @typescript-eslint/no-explicit-any
|
|
2103
2017
|
s,
|
|
2104
|
-
|
|
2018
|
+
S
|
|
2105
2019
|
);
|
|
2106
|
-
if (!
|
|
2107
|
-
return new Intl.DateTimeFormat(
|
|
2108
|
-
let y = {}, R,
|
|
2020
|
+
if (!A(u) || u === "")
|
|
2021
|
+
return new Intl.DateTimeFormat(S, T).format(f);
|
|
2022
|
+
let y = {}, R, _ = null, E = S, L = null;
|
|
2109
2023
|
const g = "datetime format";
|
|
2110
|
-
for (let I = 0; I <
|
|
2111
|
-
if (R = L =
|
|
2024
|
+
for (let I = 0; I < P.length; I++) {
|
|
2025
|
+
if (R = L = P[I], process.env.NODE_ENV !== "production" && S !== R && bt(h, u) && r(De(re.FALLBACK_TO_DATE_FORMAT, {
|
|
2112
2026
|
key: u,
|
|
2113
2027
|
target: R
|
|
2114
|
-
})), process.env.NODE_ENV !== "production" &&
|
|
2115
|
-
const
|
|
2116
|
-
|
|
2028
|
+
})), process.env.NODE_ENV !== "production" && S !== R) {
|
|
2029
|
+
const B = e.__v_emitter;
|
|
2030
|
+
B && B.emit("fallback", {
|
|
2117
2031
|
type: g,
|
|
2118
2032
|
key: u,
|
|
2119
2033
|
from: E,
|
|
@@ -2121,18 +2035,18 @@ function Sn(e, ...t) {
|
|
|
2121
2035
|
groupId: `${g}:${u}`
|
|
2122
2036
|
});
|
|
2123
2037
|
}
|
|
2124
|
-
if (y = n[R] || {},
|
|
2038
|
+
if (y = n[R] || {}, _ = y[u], F(_))
|
|
2125
2039
|
break;
|
|
2126
|
-
|
|
2040
|
+
jt(e, u, R, d, g), E = L;
|
|
2127
2041
|
}
|
|
2128
|
-
if (!F(
|
|
2129
|
-
return a ?
|
|
2042
|
+
if (!F(_) || !A(R))
|
|
2043
|
+
return a ? It : u;
|
|
2130
2044
|
let v = `${R}__${u}`;
|
|
2131
|
-
|
|
2132
|
-
let C =
|
|
2133
|
-
return C || (C = new Intl.DateTimeFormat(R,
|
|
2045
|
+
Ot(T) || (v = `${v}__${JSON.stringify(T)}`);
|
|
2046
|
+
let C = i.get(v);
|
|
2047
|
+
return C || (C = new Intl.DateTimeFormat(R, ee({}, _, T)), i.set(v, C)), D ? C.formatToParts(f) : C.format(f);
|
|
2134
2048
|
}
|
|
2135
|
-
const
|
|
2049
|
+
const mr = [
|
|
2136
2050
|
"localeMatcher",
|
|
2137
2051
|
"weekday",
|
|
2138
2052
|
"era",
|
|
@@ -2154,60 +2068,60 @@ const Sr = [
|
|
|
2154
2068
|
"hourCycle",
|
|
2155
2069
|
"fractionalSecondDigits"
|
|
2156
2070
|
];
|
|
2157
|
-
function
|
|
2158
|
-
const [t, n, a, s] = e, r =
|
|
2159
|
-
let l =
|
|
2160
|
-
if (
|
|
2071
|
+
function Mt(...e) {
|
|
2072
|
+
const [t, n, a, s] = e, r = {};
|
|
2073
|
+
let l = {}, i;
|
|
2074
|
+
if (A(t)) {
|
|
2161
2075
|
const u = t.match(/(\d{4}-\d{2}-\d{2})(T|\s)?(.*)/);
|
|
2162
2076
|
if (!u)
|
|
2163
|
-
throw
|
|
2164
|
-
const
|
|
2165
|
-
|
|
2077
|
+
throw de(z.INVALID_ISO_DATE_ARGUMENT);
|
|
2078
|
+
const f = u[3] ? u[3].trim().startsWith("T") ? `${u[1].trim()}${u[3].trim()}` : `${u[1].trim()}T${u[3].trim()}` : u[1].trim();
|
|
2079
|
+
i = new Date(f);
|
|
2166
2080
|
try {
|
|
2167
|
-
|
|
2081
|
+
i.toISOString();
|
|
2168
2082
|
} catch {
|
|
2169
|
-
throw
|
|
2083
|
+
throw de(z.INVALID_ISO_DATE_ARGUMENT);
|
|
2170
2084
|
}
|
|
2171
|
-
} else if (
|
|
2085
|
+
} else if (qr(t)) {
|
|
2172
2086
|
if (isNaN(t.getTime()))
|
|
2173
|
-
throw
|
|
2174
|
-
|
|
2175
|
-
} else if (
|
|
2176
|
-
|
|
2087
|
+
throw de(z.INVALID_DATE_ARGUMENT);
|
|
2088
|
+
i = t;
|
|
2089
|
+
} else if (Q(t))
|
|
2090
|
+
i = t;
|
|
2177
2091
|
else
|
|
2178
|
-
throw
|
|
2179
|
-
return
|
|
2180
|
-
|
|
2181
|
-
}),
|
|
2092
|
+
throw de(z.INVALID_ARGUMENT);
|
|
2093
|
+
return A(n) ? r.key = n : F(n) && Object.keys(n).forEach((u) => {
|
|
2094
|
+
mr.includes(u) ? l[u] = n[u] : r[u] = n[u];
|
|
2095
|
+
}), A(a) ? r.locale = a : F(a) && (l = a), F(s) && (l = s), [r.key || "", i, r, l];
|
|
2182
2096
|
}
|
|
2183
|
-
function
|
|
2097
|
+
function In(e, t, n) {
|
|
2184
2098
|
const a = e;
|
|
2185
2099
|
for (const s in n) {
|
|
2186
2100
|
const r = `${t}__${s}`;
|
|
2187
2101
|
a.__datetimeFormatters.has(r) && a.__datetimeFormatters.delete(r);
|
|
2188
2102
|
}
|
|
2189
2103
|
}
|
|
2190
|
-
function
|
|
2191
|
-
const { numberFormats: n, unresolving: a, fallbackLocale: s, onWarn: r, localeFallbacker: l } = e, { __numberFormatters:
|
|
2192
|
-
if (process.env.NODE_ENV !== "production" && !
|
|
2193
|
-
return r(
|
|
2194
|
-
const [u,
|
|
2104
|
+
function bn(e, ...t) {
|
|
2105
|
+
const { numberFormats: n, unresolving: a, fallbackLocale: s, onWarn: r, localeFallbacker: l } = e, { __numberFormatters: i } = e;
|
|
2106
|
+
if (process.env.NODE_ENV !== "production" && !fr.numberFormat)
|
|
2107
|
+
return r(De(re.CANNOT_FORMAT_NUMBER)), Tt;
|
|
2108
|
+
const [u, f, p, T] = Ft(...t), d = U(p.missingWarn) ? p.missingWarn : e.missingWarn, h = U(p.fallbackWarn) ? p.fallbackWarn : e.fallbackWarn, D = !!p.part, S = Xt(e, p), P = l(
|
|
2195
2109
|
e,
|
|
2196
2110
|
// eslint-disable-line @typescript-eslint/no-explicit-any
|
|
2197
2111
|
s,
|
|
2198
|
-
|
|
2112
|
+
S
|
|
2199
2113
|
);
|
|
2200
|
-
if (!
|
|
2201
|
-
return new Intl.NumberFormat(
|
|
2202
|
-
let y = {}, R,
|
|
2114
|
+
if (!A(u) || u === "")
|
|
2115
|
+
return new Intl.NumberFormat(S, T).format(f);
|
|
2116
|
+
let y = {}, R, _ = null, E = S, L = null;
|
|
2203
2117
|
const g = "number format";
|
|
2204
|
-
for (let I = 0; I <
|
|
2205
|
-
if (R = L =
|
|
2118
|
+
for (let I = 0; I < P.length; I++) {
|
|
2119
|
+
if (R = L = P[I], process.env.NODE_ENV !== "production" && S !== R && bt(h, u) && r(De(re.FALLBACK_TO_NUMBER_FORMAT, {
|
|
2206
2120
|
key: u,
|
|
2207
2121
|
target: R
|
|
2208
|
-
})), process.env.NODE_ENV !== "production" &&
|
|
2209
|
-
const
|
|
2210
|
-
|
|
2122
|
+
})), process.env.NODE_ENV !== "production" && S !== R) {
|
|
2123
|
+
const B = e.__v_emitter;
|
|
2124
|
+
B && B.emit("fallback", {
|
|
2211
2125
|
type: g,
|
|
2212
2126
|
key: u,
|
|
2213
2127
|
from: E,
|
|
@@ -2215,18 +2129,18 @@ function Rn(e, ...t) {
|
|
|
2215
2129
|
groupId: `${g}:${u}`
|
|
2216
2130
|
});
|
|
2217
2131
|
}
|
|
2218
|
-
if (y = n[R] || {},
|
|
2132
|
+
if (y = n[R] || {}, _ = y[u], F(_))
|
|
2219
2133
|
break;
|
|
2220
|
-
|
|
2134
|
+
jt(e, u, R, d, g), E = L;
|
|
2221
2135
|
}
|
|
2222
|
-
if (!F(
|
|
2223
|
-
return a ?
|
|
2136
|
+
if (!F(_) || !A(R))
|
|
2137
|
+
return a ? It : u;
|
|
2224
2138
|
let v = `${R}__${u}`;
|
|
2225
|
-
|
|
2226
|
-
let C =
|
|
2227
|
-
return C || (C = new Intl.NumberFormat(R,
|
|
2139
|
+
Ot(T) || (v = `${v}__${JSON.stringify(T)}`);
|
|
2140
|
+
let C = i.get(v);
|
|
2141
|
+
return C || (C = new Intl.NumberFormat(R, ee({}, _, T)), i.set(v, C)), D ? C.formatToParts(f) : C.format(f);
|
|
2228
2142
|
}
|
|
2229
|
-
const
|
|
2143
|
+
const dr = [
|
|
2230
2144
|
"localeMatcher",
|
|
2231
2145
|
"style",
|
|
2232
2146
|
"currency",
|
|
@@ -2248,53 +2162,53 @@ const Dr = [
|
|
|
2248
2162
|
"roundingIncrement",
|
|
2249
2163
|
"trailingZeroDisplay"
|
|
2250
2164
|
];
|
|
2251
|
-
function
|
|
2252
|
-
const [t, n, a, s] = e, r =
|
|
2253
|
-
let l =
|
|
2254
|
-
if (!
|
|
2255
|
-
throw
|
|
2256
|
-
const
|
|
2257
|
-
return
|
|
2258
|
-
|
|
2259
|
-
}),
|
|
2260
|
-
}
|
|
2261
|
-
function
|
|
2165
|
+
function Ft(...e) {
|
|
2166
|
+
const [t, n, a, s] = e, r = {};
|
|
2167
|
+
let l = {};
|
|
2168
|
+
if (!Q(t))
|
|
2169
|
+
throw de(z.INVALID_ARGUMENT);
|
|
2170
|
+
const i = t;
|
|
2171
|
+
return A(n) ? r.key = n : F(n) && Object.keys(n).forEach((u) => {
|
|
2172
|
+
dr.includes(u) ? l[u] = n[u] : r[u] = n[u];
|
|
2173
|
+
}), A(a) ? r.locale = a : F(a) && (l = a), F(s) && (l = s), [r.key || "", i, r, l];
|
|
2174
|
+
}
|
|
2175
|
+
function hn(e, t, n) {
|
|
2262
2176
|
const a = e;
|
|
2263
2177
|
for (const s in n) {
|
|
2264
2178
|
const r = `${t}__${s}`;
|
|
2265
2179
|
a.__numberFormatters.has(r) && a.__numberFormatters.delete(r);
|
|
2266
2180
|
}
|
|
2267
2181
|
}
|
|
2268
|
-
|
|
2269
|
-
function
|
|
2270
|
-
return
|
|
2182
|
+
Fa();
|
|
2183
|
+
function hs() {
|
|
2184
|
+
return Er().__VUE_DEVTOOLS_GLOBAL_HOOK__;
|
|
2271
2185
|
}
|
|
2272
|
-
function
|
|
2186
|
+
function Er() {
|
|
2273
2187
|
return typeof navigator < "u" && typeof window < "u" ? window : typeof globalThis < "u" ? globalThis : {};
|
|
2274
2188
|
}
|
|
2275
|
-
const
|
|
2276
|
-
let
|
|
2277
|
-
function
|
|
2189
|
+
const As = typeof Proxy == "function", Cs = "devtools-plugin:setup", Ss = "plugin:settings:set";
|
|
2190
|
+
let Ue, Ut;
|
|
2191
|
+
function Ps() {
|
|
2278
2192
|
var e;
|
|
2279
|
-
return
|
|
2193
|
+
return Ue !== void 0 || (typeof window < "u" && window.performance ? (Ue = !0, Ut = window.performance) : typeof globalThis < "u" && (!((e = globalThis.perf_hooks) === null || e === void 0) && e.performance) ? (Ue = !0, Ut = globalThis.perf_hooks.performance) : Ue = !1), Ue;
|
|
2280
2194
|
}
|
|
2281
|
-
function
|
|
2282
|
-
return
|
|
2195
|
+
function Ds() {
|
|
2196
|
+
return Ps() ? Ut.now() : Date.now();
|
|
2283
2197
|
}
|
|
2284
|
-
class
|
|
2198
|
+
class Rs {
|
|
2285
2199
|
constructor(t, n) {
|
|
2286
2200
|
this.target = null, this.targetQueue = [], this.onQueue = [], this.plugin = t, this.hook = n;
|
|
2287
2201
|
const a = {};
|
|
2288
2202
|
if (t.settings)
|
|
2289
2203
|
for (const l in t.settings) {
|
|
2290
|
-
const
|
|
2291
|
-
a[l] =
|
|
2204
|
+
const i = t.settings[l];
|
|
2205
|
+
a[l] = i.defaultValue;
|
|
2292
2206
|
}
|
|
2293
2207
|
const s = `__vue-devtools-plugin-settings__${t.id}`;
|
|
2294
2208
|
let r = Object.assign({}, a);
|
|
2295
2209
|
try {
|
|
2296
|
-
const l = localStorage.getItem(s),
|
|
2297
|
-
Object.assign(r,
|
|
2210
|
+
const l = localStorage.getItem(s), i = JSON.parse(l);
|
|
2211
|
+
Object.assign(r, i);
|
|
2298
2212
|
} catch {
|
|
2299
2213
|
}
|
|
2300
2214
|
this.fallbacks = {
|
|
@@ -2309,28 +2223,28 @@ class tl {
|
|
|
2309
2223
|
r = l;
|
|
2310
2224
|
},
|
|
2311
2225
|
now() {
|
|
2312
|
-
return
|
|
2226
|
+
return Ds();
|
|
2313
2227
|
}
|
|
2314
|
-
}, n && n.on(
|
|
2315
|
-
l === this.plugin.id && this.fallbacks.setSettings(
|
|
2228
|
+
}, n && n.on(Ss, (l, i) => {
|
|
2229
|
+
l === this.plugin.id && this.fallbacks.setSettings(i);
|
|
2316
2230
|
}), this.proxiedOn = new Proxy({}, {
|
|
2317
|
-
get: (l,
|
|
2231
|
+
get: (l, i) => this.target ? this.target.on[i] : (...u) => {
|
|
2318
2232
|
this.onQueue.push({
|
|
2319
|
-
method:
|
|
2233
|
+
method: i,
|
|
2320
2234
|
args: u
|
|
2321
2235
|
});
|
|
2322
2236
|
}
|
|
2323
2237
|
}), this.proxiedTarget = new Proxy({}, {
|
|
2324
|
-
get: (l,
|
|
2325
|
-
method:
|
|
2238
|
+
get: (l, i) => this.target ? this.target[i] : i === "on" ? this.proxiedOn : Object.keys(this.fallbacks).includes(i) ? (...u) => (this.targetQueue.push({
|
|
2239
|
+
method: i,
|
|
2326
2240
|
args: u,
|
|
2327
2241
|
resolve: () => {
|
|
2328
2242
|
}
|
|
2329
|
-
}), this.fallbacks[
|
|
2243
|
+
}), this.fallbacks[i](...u)) : (...u) => new Promise((f) => {
|
|
2330
2244
|
this.targetQueue.push({
|
|
2331
|
-
method:
|
|
2245
|
+
method: i,
|
|
2332
2246
|
args: u,
|
|
2333
|
-
resolve:
|
|
2247
|
+
resolve: f
|
|
2334
2248
|
});
|
|
2335
2249
|
})
|
|
2336
2250
|
});
|
|
@@ -2343,12 +2257,12 @@ class tl {
|
|
|
2343
2257
|
n.resolve(await this.target[n.method](...n.args));
|
|
2344
2258
|
}
|
|
2345
2259
|
}
|
|
2346
|
-
function
|
|
2347
|
-
const n = e, a =
|
|
2260
|
+
function ks(e, t) {
|
|
2261
|
+
const n = e, a = Er(), s = hs(), r = As && n.enableEarlyProxy;
|
|
2348
2262
|
if (s && (a.__VUE_DEVTOOLS_PLUGIN_API_AVAILABLE__ || !r))
|
|
2349
|
-
s.emit(
|
|
2263
|
+
s.emit(Cs, e, t);
|
|
2350
2264
|
else {
|
|
2351
|
-
const l = r ? new
|
|
2265
|
+
const l = r ? new Rs(n, s) : null;
|
|
2352
2266
|
(a.__VUE_DEVTOOLS_PLUGINS__ = a.__VUE_DEVTOOLS_PLUGINS__ || []).push({
|
|
2353
2267
|
pluginDescriptor: n,
|
|
2354
2268
|
setupFn: t,
|
|
@@ -2357,159 +2271,154 @@ function nl(e, t) {
|
|
|
2357
2271
|
}
|
|
2358
2272
|
}
|
|
2359
2273
|
/*!
|
|
2360
|
-
* vue-i18n v9.14.
|
|
2361
|
-
* (c)
|
|
2274
|
+
* vue-i18n v9.14.0
|
|
2275
|
+
* (c) 2024 kazuya kawaguchi
|
|
2362
2276
|
* Released under the MIT License.
|
|
2363
2277
|
*/
|
|
2364
|
-
const
|
|
2365
|
-
function
|
|
2366
|
-
typeof __VUE_I18N_FULL_INSTALL__ != "boolean" && (
|
|
2278
|
+
const ys = "9.14.0";
|
|
2279
|
+
function Ms() {
|
|
2280
|
+
typeof __VUE_I18N_FULL_INSTALL__ != "boolean" && (pe().__VUE_I18N_FULL_INSTALL__ = !0), typeof __VUE_I18N_LEGACY_API__ != "boolean" && (pe().__VUE_I18N_LEGACY_API__ = !0), typeof __INTLIFY_JIT_COMPILATION__ != "boolean" && (pe().__INTLIFY_JIT_COMPILATION__ = !1), typeof __INTLIFY_DROP_MESSAGE_COMPILER__ != "boolean" && (pe().__INTLIFY_DROP_MESSAGE_COMPILER__ = !1), typeof __INTLIFY_PROD_DEVTOOLS__ != "boolean" && (pe().__INTLIFY_PROD_DEVTOOLS__ = !1);
|
|
2367
2281
|
}
|
|
2368
|
-
const
|
|
2369
|
-
FALLBACK_TO_ROOT:
|
|
2282
|
+
const gr = re.__EXTEND_POINT__, Ne = Lt(gr), K = {
|
|
2283
|
+
FALLBACK_TO_ROOT: gr,
|
|
2370
2284
|
// 9
|
|
2371
|
-
NOT_SUPPORTED_PRESERVE:
|
|
2285
|
+
NOT_SUPPORTED_PRESERVE: Ne(),
|
|
2372
2286
|
// 10
|
|
2373
|
-
NOT_SUPPORTED_FORMATTER:
|
|
2287
|
+
NOT_SUPPORTED_FORMATTER: Ne(),
|
|
2374
2288
|
// 11
|
|
2375
|
-
NOT_SUPPORTED_PRESERVE_DIRECTIVE:
|
|
2289
|
+
NOT_SUPPORTED_PRESERVE_DIRECTIVE: Ne(),
|
|
2376
2290
|
// 12
|
|
2377
|
-
NOT_SUPPORTED_GET_CHOICE_INDEX:
|
|
2291
|
+
NOT_SUPPORTED_GET_CHOICE_INDEX: Ne(),
|
|
2378
2292
|
// 13
|
|
2379
|
-
COMPONENT_NAME_LEGACY_COMPATIBLE:
|
|
2293
|
+
COMPONENT_NAME_LEGACY_COMPATIBLE: Ne(),
|
|
2380
2294
|
// 14
|
|
2381
|
-
NOT_FOUND_PARENT_SCOPE:
|
|
2295
|
+
NOT_FOUND_PARENT_SCOPE: Ne(),
|
|
2382
2296
|
// 15
|
|
2383
|
-
IGNORE_OBJ_FLATTEN:
|
|
2297
|
+
IGNORE_OBJ_FLATTEN: Ne(),
|
|
2384
2298
|
// 16
|
|
2385
|
-
NOTICE_DROP_ALLOW_COMPOSITION:
|
|
2299
|
+
NOTICE_DROP_ALLOW_COMPOSITION: Ne(),
|
|
2386
2300
|
// 17
|
|
2387
|
-
NOTICE_DROP_TRANSLATE_EXIST_COMPATIBLE_FLAG:
|
|
2301
|
+
NOTICE_DROP_TRANSLATE_EXIST_COMPATIBLE_FLAG: Ne()
|
|
2388
2302
|
// 18
|
|
2389
|
-
},
|
|
2390
|
-
[
|
|
2391
|
-
[
|
|
2392
|
-
[
|
|
2393
|
-
[
|
|
2394
|
-
[
|
|
2395
|
-
[
|
|
2396
|
-
[
|
|
2397
|
-
[
|
|
2398
|
-
[
|
|
2399
|
-
[
|
|
2303
|
+
}, Fs = {
|
|
2304
|
+
[K.FALLBACK_TO_ROOT]: "Fall back to {type} '{key}' with root locale.",
|
|
2305
|
+
[K.NOT_SUPPORTED_PRESERVE]: "Not supported 'preserve'.",
|
|
2306
|
+
[K.NOT_SUPPORTED_FORMATTER]: "Not supported 'formatter'.",
|
|
2307
|
+
[K.NOT_SUPPORTED_PRESERVE_DIRECTIVE]: "Not supported 'preserveDirectiveContent'.",
|
|
2308
|
+
[K.NOT_SUPPORTED_GET_CHOICE_INDEX]: "Not supported 'getChoiceIndex'.",
|
|
2309
|
+
[K.COMPONENT_NAME_LEGACY_COMPATIBLE]: "Component name legacy compatible: '{name}' -> 'i18n'",
|
|
2310
|
+
[K.NOT_FOUND_PARENT_SCOPE]: "Not found parent scope. use the global scope.",
|
|
2311
|
+
[K.IGNORE_OBJ_FLATTEN]: "Ignore object flatten: '{key}' key has an string value",
|
|
2312
|
+
[K.NOTICE_DROP_ALLOW_COMPOSITION]: "'allowComposition' option will be dropped in the next major version. For more information, please see 👉 https://tinyurl.com/2p97mcze",
|
|
2313
|
+
[K.NOTICE_DROP_TRANSLATE_EXIST_COMPATIBLE_FLAG]: "'translateExistCompatible' option will be dropped in the next major version."
|
|
2400
2314
|
};
|
|
2401
|
-
function
|
|
2402
|
-
return
|
|
2315
|
+
function se(e, ...t) {
|
|
2316
|
+
return Ht(Fs[e], ...t);
|
|
2403
2317
|
}
|
|
2404
|
-
const
|
|
2318
|
+
const Nr = z.__EXTEND_POINT__, ae = Lt(Nr), V = {
|
|
2405
2319
|
// composer module errors
|
|
2406
|
-
UNEXPECTED_RETURN_TYPE:
|
|
2320
|
+
UNEXPECTED_RETURN_TYPE: Nr,
|
|
2407
2321
|
// 24
|
|
2408
2322
|
// legacy module errors
|
|
2409
|
-
INVALID_ARGUMENT:
|
|
2323
|
+
INVALID_ARGUMENT: ae(),
|
|
2410
2324
|
// 25
|
|
2411
2325
|
// i18n module errors
|
|
2412
|
-
MUST_BE_CALL_SETUP_TOP:
|
|
2326
|
+
MUST_BE_CALL_SETUP_TOP: ae(),
|
|
2413
2327
|
// 26
|
|
2414
|
-
NOT_INSTALLED:
|
|
2328
|
+
NOT_INSTALLED: ae(),
|
|
2415
2329
|
// 27
|
|
2416
|
-
NOT_AVAILABLE_IN_LEGACY_MODE:
|
|
2330
|
+
NOT_AVAILABLE_IN_LEGACY_MODE: ae(),
|
|
2417
2331
|
// 28
|
|
2418
2332
|
// directive module errors
|
|
2419
|
-
REQUIRED_VALUE:
|
|
2333
|
+
REQUIRED_VALUE: ae(),
|
|
2420
2334
|
// 29
|
|
2421
|
-
INVALID_VALUE:
|
|
2335
|
+
INVALID_VALUE: ae(),
|
|
2422
2336
|
// 30
|
|
2423
2337
|
// vue-devtools errors
|
|
2424
|
-
CANNOT_SETUP_VUE_DEVTOOLS_PLUGIN:
|
|
2338
|
+
CANNOT_SETUP_VUE_DEVTOOLS_PLUGIN: ae(),
|
|
2425
2339
|
// 31
|
|
2426
|
-
NOT_INSTALLED_WITH_PROVIDE:
|
|
2340
|
+
NOT_INSTALLED_WITH_PROVIDE: ae(),
|
|
2427
2341
|
// 32
|
|
2428
2342
|
// unexpected error
|
|
2429
|
-
UNEXPECTED_ERROR:
|
|
2343
|
+
UNEXPECTED_ERROR: ae(),
|
|
2430
2344
|
// 33
|
|
2431
2345
|
// not compatible legacy vue-i18n constructor
|
|
2432
|
-
NOT_COMPATIBLE_LEGACY_VUE_I18N:
|
|
2346
|
+
NOT_COMPATIBLE_LEGACY_VUE_I18N: ae(),
|
|
2433
2347
|
// 34
|
|
2434
2348
|
// bridge support vue 2.x only
|
|
2435
|
-
BRIDGE_SUPPORT_VUE_2_ONLY:
|
|
2349
|
+
BRIDGE_SUPPORT_VUE_2_ONLY: ae(),
|
|
2436
2350
|
// 35
|
|
2437
2351
|
// need to define `i18n` option in `allowComposition: true` and `useScope: 'local' at `useI18n``
|
|
2438
|
-
MUST_DEFINE_I18N_OPTION_IN_ALLOW_COMPOSITION:
|
|
2352
|
+
MUST_DEFINE_I18N_OPTION_IN_ALLOW_COMPOSITION: ae(),
|
|
2439
2353
|
// 36
|
|
2440
2354
|
// Not available Compostion API in Legacy API mode. Please make sure that the legacy API mode is working properly
|
|
2441
|
-
NOT_AVAILABLE_COMPOSITION_IN_LEGACY:
|
|
2355
|
+
NOT_AVAILABLE_COMPOSITION_IN_LEGACY: ae(),
|
|
2442
2356
|
// 37
|
|
2443
2357
|
// for enhancement
|
|
2444
|
-
__EXTEND_POINT__:
|
|
2358
|
+
__EXTEND_POINT__: ae()
|
|
2445
2359
|
// 38
|
|
2446
2360
|
};
|
|
2447
|
-
function
|
|
2448
|
-
return
|
|
2449
|
-
}
|
|
2450
|
-
const
|
|
2451
|
-
[
|
|
2452
|
-
[
|
|
2453
|
-
[
|
|
2454
|
-
[
|
|
2455
|
-
[
|
|
2456
|
-
[
|
|
2457
|
-
[
|
|
2458
|
-
[
|
|
2459
|
-
[
|
|
2460
|
-
[
|
|
2461
|
-
[
|
|
2462
|
-
[
|
|
2463
|
-
[
|
|
2464
|
-
[
|
|
2465
|
-
},
|
|
2466
|
-
function
|
|
2467
|
-
if (
|
|
2361
|
+
function Z(e, ...t) {
|
|
2362
|
+
return Ge(e, null, process.env.NODE_ENV !== "production" ? { messages: Us, args: t } : void 0);
|
|
2363
|
+
}
|
|
2364
|
+
const Us = {
|
|
2365
|
+
[V.UNEXPECTED_RETURN_TYPE]: "Unexpected return type in composer",
|
|
2366
|
+
[V.INVALID_ARGUMENT]: "Invalid argument",
|
|
2367
|
+
[V.MUST_BE_CALL_SETUP_TOP]: "Must be called at the top of a `setup` function",
|
|
2368
|
+
[V.NOT_INSTALLED]: "Need to install with `app.use` function",
|
|
2369
|
+
[V.UNEXPECTED_ERROR]: "Unexpected error",
|
|
2370
|
+
[V.NOT_AVAILABLE_IN_LEGACY_MODE]: "Not available in legacy mode",
|
|
2371
|
+
[V.REQUIRED_VALUE]: "Required in value: {0}",
|
|
2372
|
+
[V.INVALID_VALUE]: "Invalid value",
|
|
2373
|
+
[V.CANNOT_SETUP_VUE_DEVTOOLS_PLUGIN]: "Cannot setup vue-devtools plugin",
|
|
2374
|
+
[V.NOT_INSTALLED_WITH_PROVIDE]: "Need to install with `provide` function",
|
|
2375
|
+
[V.NOT_COMPATIBLE_LEGACY_VUE_I18N]: "Not compatible legacy VueI18n.",
|
|
2376
|
+
[V.BRIDGE_SUPPORT_VUE_2_ONLY]: "vue-i18n-bridge support Vue 2.x only",
|
|
2377
|
+
[V.MUST_DEFINE_I18N_OPTION_IN_ALLOW_COMPOSITION]: "Must define ‘i18n’ option or custom block in Composition API with using local scope in Legacy API mode",
|
|
2378
|
+
[V.NOT_AVAILABLE_COMPOSITION_IN_LEGACY]: "Not available Compostion API in Legacy API mode. Please make sure that the legacy API mode is working properly"
|
|
2379
|
+
}, wt = /* @__PURE__ */ Ee("__translateVNode"), Vt = /* @__PURE__ */ Ee("__datetimeParts"), $t = /* @__PURE__ */ Ee("__numberParts"), Re = /* @__PURE__ */ Ee("__enableEmitter"), ot = /* @__PURE__ */ Ee("__disableEmitter"), pr = Ee("__setPluralRules"), Tr = /* @__PURE__ */ Ee("__injectWithOption"), Wt = /* @__PURE__ */ Ee("__dispose");
|
|
2380
|
+
function it(e) {
|
|
2381
|
+
if (!$(e))
|
|
2468
2382
|
return e;
|
|
2469
2383
|
for (const t in e)
|
|
2470
|
-
if (
|
|
2384
|
+
if (Nt(e, t))
|
|
2471
2385
|
if (!t.includes("."))
|
|
2472
|
-
|
|
2386
|
+
$(e[t]) && it(e[t]);
|
|
2473
2387
|
else {
|
|
2474
2388
|
const n = t.split("."), a = n.length - 1;
|
|
2475
2389
|
let s = e, r = !1;
|
|
2476
2390
|
for (let l = 0; l < a; l++) {
|
|
2477
|
-
if (n[l]
|
|
2478
|
-
|
|
2479
|
-
if (n[l] in s || (s[n[l]] = Y()), !V(s[n[l]])) {
|
|
2480
|
-
process.env.NODE_ENV !== "production" && Z(le(J.IGNORE_OBJ_FLATTEN, {
|
|
2391
|
+
if (n[l] in s || (s[n[l]] = {}), !$(s[n[l]])) {
|
|
2392
|
+
process.env.NODE_ENV !== "production" && q(se(K.IGNORE_OBJ_FLATTEN, {
|
|
2481
2393
|
key: n[l]
|
|
2482
2394
|
})), r = !0;
|
|
2483
2395
|
break;
|
|
2484
2396
|
}
|
|
2485
2397
|
s = s[n[l]];
|
|
2486
2398
|
}
|
|
2487
|
-
|
|
2488
|
-
const l = s[n[a]];
|
|
2489
|
-
V(l) && _t(l);
|
|
2490
|
-
}
|
|
2399
|
+
r || (s[n[a]] = e[t], delete e[t]), $(s[n[a]]) && it(s[n[a]]);
|
|
2491
2400
|
}
|
|
2492
2401
|
return e;
|
|
2493
2402
|
}
|
|
2494
|
-
function
|
|
2495
|
-
const { messages: n, __i18n: a, messageResolver: s, flatJson: r } = t, l = F(n) ? n :
|
|
2496
|
-
if (
|
|
2497
|
-
if ("locale" in
|
|
2498
|
-
const { locale: u, resource:
|
|
2499
|
-
u ? (l[u] = l[u] ||
|
|
2403
|
+
function ht(e, t) {
|
|
2404
|
+
const { messages: n, __i18n: a, messageResolver: s, flatJson: r } = t, l = F(n) ? n : X(a) ? {} : { [e]: {} };
|
|
2405
|
+
if (X(a) && a.forEach((i) => {
|
|
2406
|
+
if ("locale" in i && "resource" in i) {
|
|
2407
|
+
const { locale: u, resource: f } = i;
|
|
2408
|
+
u ? (l[u] = l[u] || {}, Et(f, l[u])) : Et(f, l);
|
|
2500
2409
|
} else
|
|
2501
|
-
|
|
2410
|
+
A(i) && Et(JSON.parse(i), l);
|
|
2502
2411
|
}), s == null && r)
|
|
2503
|
-
for (const
|
|
2504
|
-
|
|
2412
|
+
for (const i in l)
|
|
2413
|
+
Nt(l, i) && it(l[i]);
|
|
2505
2414
|
return l;
|
|
2506
2415
|
}
|
|
2507
|
-
function
|
|
2416
|
+
function Or(e) {
|
|
2508
2417
|
return e.type;
|
|
2509
2418
|
}
|
|
2510
|
-
function
|
|
2511
|
-
let a =
|
|
2512
|
-
"__i18nGlobal" in n && (a =
|
|
2419
|
+
function Lr(e, t, n) {
|
|
2420
|
+
let a = $(t.messages) ? t.messages : {};
|
|
2421
|
+
"__i18nGlobal" in n && (a = ht(e.locale.value, {
|
|
2513
2422
|
messages: a,
|
|
2514
2423
|
__i18n: n.__i18nGlobal
|
|
2515
2424
|
}));
|
|
@@ -2518,13 +2427,13 @@ function wr(e, t, n) {
|
|
|
2518
2427
|
e.mergeLocaleMessage(r, a[r]);
|
|
2519
2428
|
});
|
|
2520
2429
|
{
|
|
2521
|
-
if (
|
|
2430
|
+
if ($(t.datetimeFormats)) {
|
|
2522
2431
|
const r = Object.keys(t.datetimeFormats);
|
|
2523
2432
|
r.length && r.forEach((l) => {
|
|
2524
2433
|
e.mergeDateTimeFormat(l, t.datetimeFormats[l]);
|
|
2525
2434
|
});
|
|
2526
2435
|
}
|
|
2527
|
-
if (
|
|
2436
|
+
if ($(t.numberFormats)) {
|
|
2528
2437
|
const r = Object.keys(t.numberFormats);
|
|
2529
2438
|
r.length && r.forEach((l) => {
|
|
2530
2439
|
e.mergeNumberFormat(l, t.numberFormats[l]);
|
|
@@ -2532,45 +2441,45 @@ function wr(e, t, n) {
|
|
|
2532
2441
|
}
|
|
2533
2442
|
}
|
|
2534
2443
|
}
|
|
2535
|
-
function
|
|
2536
|
-
return
|
|
2444
|
+
function An(e) {
|
|
2445
|
+
return Fr(Ur, null, e, 0);
|
|
2537
2446
|
}
|
|
2538
|
-
const
|
|
2539
|
-
let
|
|
2540
|
-
function
|
|
2541
|
-
return (t, n, a, s) => e(n, a,
|
|
2447
|
+
const Cn = "__INTLIFY_META__", Sn = () => [], ws = () => !1;
|
|
2448
|
+
let Pn = 0;
|
|
2449
|
+
function Dn(e) {
|
|
2450
|
+
return (t, n, a, s) => e(n, a, st() || void 0, s);
|
|
2542
2451
|
}
|
|
2543
|
-
const
|
|
2544
|
-
const e =
|
|
2452
|
+
const Vs = /* @__NO_SIDE_EFFECTS__ */ () => {
|
|
2453
|
+
const e = st();
|
|
2545
2454
|
let t = null;
|
|
2546
|
-
return e && (t =
|
|
2455
|
+
return e && (t = Or(e)[Cn]) ? { [Cn]: t } : null;
|
|
2547
2456
|
};
|
|
2548
|
-
function
|
|
2549
|
-
const { __root: n, __injectWithOption: a } = e, s = n === void 0, r = e.flatJson, l =
|
|
2550
|
-
process.env.NODE_ENV !== "production" &&
|
|
2457
|
+
function Kt(e = {}, t) {
|
|
2458
|
+
const { __root: n, __injectWithOption: a } = e, s = n === void 0, r = e.flatJson, l = _e ? Se : Wn, i = !!e.translateExistCompatible;
|
|
2459
|
+
process.env.NODE_ENV !== "production" && i && Xn(se(K.NOTICE_DROP_TRANSLATE_EXIST_COMPATIBLE_FLAG));
|
|
2551
2460
|
let u = U(e.inheritLocale) ? e.inheritLocale : !0;
|
|
2552
|
-
const
|
|
2461
|
+
const f = l(
|
|
2553
2462
|
// prettier-ignore
|
|
2554
|
-
n && u ? n.locale.value :
|
|
2463
|
+
n && u ? n.locale.value : A(e.locale) ? e.locale : We
|
|
2555
2464
|
), p = l(
|
|
2556
2465
|
// prettier-ignore
|
|
2557
|
-
n && u ? n.fallbackLocale.value :
|
|
2558
|
-
), T = l(
|
|
2559
|
-
let D = n ? n.missingWarn : U(e.missingWarn) ||
|
|
2466
|
+
n && u ? n.fallbackLocale.value : A(e.fallbackLocale) || X(e.fallbackLocale) || F(e.fallbackLocale) || e.fallbackLocale === !1 ? e.fallbackLocale : f.value
|
|
2467
|
+
), T = l(ht(f.value, e)), d = l(F(e.datetimeFormats) ? e.datetimeFormats : { [f.value]: {} }), h = l(F(e.numberFormats) ? e.numberFormats : { [f.value]: {} });
|
|
2468
|
+
let D = n ? n.missingWarn : U(e.missingWarn) || Le(e.missingWarn) ? e.missingWarn : !0, S = n ? n.fallbackWarn : U(e.fallbackWarn) || Le(e.fallbackWarn) ? e.fallbackWarn : !0, P = n ? n.fallbackRoot : U(e.fallbackRoot) ? e.fallbackRoot : !0, y = !!e.fallbackFormat, R = H(e.missing) ? e.missing : null, _ = H(e.missing) ? Dn(e.missing) : null, E = H(e.postTranslation) ? e.postTranslation : null, L = n ? n.warnHtmlMessage : U(e.warnHtmlMessage) ? e.warnHtmlMessage : !0, g = !!e.escapeParameter;
|
|
2560
2469
|
const v = n ? n.modifiers : F(e.modifiers) ? e.modifiers : {};
|
|
2561
2470
|
let C = e.pluralRules || n && n.pluralRules, I;
|
|
2562
2471
|
I = (() => {
|
|
2563
|
-
s &&
|
|
2472
|
+
s && gn(null);
|
|
2564
2473
|
const m = {
|
|
2565
|
-
version:
|
|
2566
|
-
locale:
|
|
2474
|
+
version: ys,
|
|
2475
|
+
locale: f.value,
|
|
2567
2476
|
fallbackLocale: p.value,
|
|
2568
2477
|
messages: T.value,
|
|
2569
2478
|
modifiers: v,
|
|
2570
2479
|
pluralRules: C,
|
|
2571
|
-
missing:
|
|
2480
|
+
missing: _ === null ? void 0 : _,
|
|
2572
2481
|
missingWarn: D,
|
|
2573
|
-
fallbackWarn:
|
|
2482
|
+
fallbackWarn: S,
|
|
2574
2483
|
fallbackFormat: y,
|
|
2575
2484
|
unresolving: !0,
|
|
2576
2485
|
postTranslation: E === null ? void 0 : E,
|
|
@@ -2580,224 +2489,224 @@ function en(e = {}, t) {
|
|
|
2580
2489
|
messageCompiler: e.messageCompiler,
|
|
2581
2490
|
__meta: { framework: "vue" }
|
|
2582
2491
|
};
|
|
2583
|
-
m.datetimeFormats = d.value, m.numberFormats =
|
|
2584
|
-
const O =
|
|
2585
|
-
return s &&
|
|
2586
|
-
})(),
|
|
2587
|
-
function
|
|
2492
|
+
m.datetimeFormats = d.value, m.numberFormats = h.value, m.__datetimeFormatters = F(I) ? I.__datetimeFormatters : void 0, m.__numberFormatters = F(I) ? I.__numberFormatters : void 0, process.env.NODE_ENV !== "production" && (m.__v_emitter = F(I) ? I.__v_emitter : void 0);
|
|
2493
|
+
const O = ds(m);
|
|
2494
|
+
return s && gn(O), O;
|
|
2495
|
+
})(), at(I, f.value, p.value);
|
|
2496
|
+
function le() {
|
|
2588
2497
|
return [
|
|
2589
|
-
|
|
2498
|
+
f.value,
|
|
2590
2499
|
p.value,
|
|
2591
2500
|
T.value,
|
|
2592
2501
|
d.value,
|
|
2593
|
-
|
|
2502
|
+
h.value
|
|
2594
2503
|
];
|
|
2595
2504
|
}
|
|
2596
|
-
const w =
|
|
2597
|
-
get: () =>
|
|
2505
|
+
const w = me({
|
|
2506
|
+
get: () => f.value,
|
|
2598
2507
|
set: (m) => {
|
|
2599
|
-
|
|
2508
|
+
f.value = m, I.locale = f.value;
|
|
2600
2509
|
}
|
|
2601
|
-
}),
|
|
2510
|
+
}), te = me({
|
|
2602
2511
|
get: () => p.value,
|
|
2603
2512
|
set: (m) => {
|
|
2604
|
-
p.value = m, I.fallbackLocale = p.value,
|
|
2513
|
+
p.value = m, I.fallbackLocale = p.value, at(I, f.value, m);
|
|
2605
2514
|
}
|
|
2606
|
-
}),
|
|
2607
|
-
function
|
|
2608
|
-
return
|
|
2515
|
+
}), xe = me(() => T.value), He = /* @__PURE__ */ me(() => d.value), fe = /* @__PURE__ */ me(() => h.value);
|
|
2516
|
+
function Ye() {
|
|
2517
|
+
return H(E) ? E : null;
|
|
2609
2518
|
}
|
|
2610
|
-
function
|
|
2519
|
+
function Be(m) {
|
|
2611
2520
|
E = m, I.postTranslation = m;
|
|
2612
2521
|
}
|
|
2613
|
-
function
|
|
2522
|
+
function Xe() {
|
|
2614
2523
|
return R;
|
|
2615
2524
|
}
|
|
2616
|
-
function
|
|
2617
|
-
m !== null && (
|
|
2525
|
+
function je(m) {
|
|
2526
|
+
m !== null && (_ = Dn(m)), R = m, I.missing = _;
|
|
2618
2527
|
}
|
|
2619
|
-
function
|
|
2528
|
+
function Ke(m, O) {
|
|
2620
2529
|
return m !== "translate" || !O.resolvedMessage;
|
|
2621
2530
|
}
|
|
2622
|
-
const
|
|
2623
|
-
|
|
2624
|
-
let
|
|
2531
|
+
const ie = (m, O, G, J, Te, ft) => {
|
|
2532
|
+
le();
|
|
2533
|
+
let Fe;
|
|
2625
2534
|
try {
|
|
2626
|
-
process.env.NODE_ENV !== "production" || __INTLIFY_PROD_DEVTOOLS__, s || (I.fallbackContext = n ?
|
|
2535
|
+
process.env.NODE_ENV !== "production" || __INTLIFY_PROD_DEVTOOLS__, s || (I.fallbackContext = n ? ms() : void 0), Fe = m(I);
|
|
2627
2536
|
} finally {
|
|
2628
2537
|
process.env.NODE_ENV !== "production" || __INTLIFY_PROD_DEVTOOLS__, s || (I.fallbackContext = void 0);
|
|
2629
2538
|
}
|
|
2630
2539
|
if (G !== "translate exists" && // for not `te` (e.g `t`)
|
|
2631
|
-
|
|
2632
|
-
const [
|
|
2633
|
-
if (process.env.NODE_ENV !== "production" && n &&
|
|
2634
|
-
key:
|
|
2540
|
+
Q(Fe) && Fe === It || G === "translate exists" && !Fe) {
|
|
2541
|
+
const [he, Cr] = O();
|
|
2542
|
+
if (process.env.NODE_ENV !== "production" && n && A(he) && Ke(G, Cr) && (P && (bt(S, he) || ar(D, he)) && q(se(K.FALLBACK_TO_ROOT, {
|
|
2543
|
+
key: he,
|
|
2635
2544
|
type: G
|
|
2636
2545
|
})), process.env.NODE_ENV !== "production")) {
|
|
2637
|
-
const { __v_emitter:
|
|
2638
|
-
|
|
2546
|
+
const { __v_emitter: Zt } = I;
|
|
2547
|
+
Zt && P && Zt.emit("fallback", {
|
|
2639
2548
|
type: G,
|
|
2640
|
-
key:
|
|
2549
|
+
key: he,
|
|
2641
2550
|
to: "global",
|
|
2642
|
-
groupId: `${G}:${
|
|
2551
|
+
groupId: `${G}:${he}`
|
|
2643
2552
|
});
|
|
2644
2553
|
}
|
|
2645
|
-
return n &&
|
|
2554
|
+
return n && P ? J(n) : Te(he);
|
|
2646
2555
|
} else {
|
|
2647
|
-
if (
|
|
2648
|
-
return
|
|
2649
|
-
throw
|
|
2556
|
+
if (ft(Fe))
|
|
2557
|
+
return Fe;
|
|
2558
|
+
throw Z(V.UNEXPECTED_RETURN_TYPE);
|
|
2650
2559
|
}
|
|
2651
2560
|
};
|
|
2652
|
-
function
|
|
2653
|
-
return
|
|
2561
|
+
function ke(...m) {
|
|
2562
|
+
return ie((O) => Reflect.apply(On, null, [O, ...m]), () => yt(...m), "translate", (O) => Reflect.apply(O.t, O, [...m]), (O) => O, (O) => A(O));
|
|
2654
2563
|
}
|
|
2655
|
-
function
|
|
2656
|
-
const [O, G,
|
|
2657
|
-
if (
|
|
2658
|
-
throw
|
|
2659
|
-
return
|
|
2564
|
+
function ye(...m) {
|
|
2565
|
+
const [O, G, J] = m;
|
|
2566
|
+
if (J && !$(J))
|
|
2567
|
+
throw Z(V.INVALID_ARGUMENT);
|
|
2568
|
+
return ke(O, G, ee({ resolvedMessage: !0 }, J || {}));
|
|
2660
2569
|
}
|
|
2661
|
-
function
|
|
2662
|
-
return
|
|
2570
|
+
function Je(...m) {
|
|
2571
|
+
return ie((O) => Reflect.apply(vn, null, [O, ...m]), () => Mt(...m), "datetime format", (O) => Reflect.apply(O.d, O, [...m]), () => Tt, (O) => A(O));
|
|
2663
2572
|
}
|
|
2664
|
-
function
|
|
2665
|
-
return
|
|
2573
|
+
function Qe(...m) {
|
|
2574
|
+
return ie((O) => Reflect.apply(bn, null, [O, ...m]), () => Ft(...m), "number format", (O) => Reflect.apply(O.n, O, [...m]), () => Tt, (O) => A(O));
|
|
2666
2575
|
}
|
|
2667
|
-
function
|
|
2668
|
-
return m.map((O) =>
|
|
2576
|
+
function qe(m) {
|
|
2577
|
+
return m.map((O) => A(O) || Q(O) || U(O) ? An(String(O)) : O);
|
|
2669
2578
|
}
|
|
2670
|
-
const
|
|
2671
|
-
normalize:
|
|
2579
|
+
const Ze = {
|
|
2580
|
+
normalize: qe,
|
|
2672
2581
|
interpolate: (m) => m,
|
|
2673
2582
|
type: "vnode"
|
|
2674
2583
|
};
|
|
2675
|
-
function
|
|
2676
|
-
return
|
|
2584
|
+
function Me(...m) {
|
|
2585
|
+
return ie(
|
|
2677
2586
|
(O) => {
|
|
2678
2587
|
let G;
|
|
2679
|
-
const
|
|
2588
|
+
const J = O;
|
|
2680
2589
|
try {
|
|
2681
|
-
|
|
2590
|
+
J.processor = Ze, G = Reflect.apply(On, null, [J, ...m]);
|
|
2682
2591
|
} finally {
|
|
2683
|
-
|
|
2592
|
+
J.processor = null;
|
|
2684
2593
|
}
|
|
2685
2594
|
return G;
|
|
2686
2595
|
},
|
|
2687
|
-
() =>
|
|
2596
|
+
() => yt(...m),
|
|
2688
2597
|
"translate",
|
|
2689
2598
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
2690
|
-
(O) => O[
|
|
2691
|
-
(O) => [
|
|
2692
|
-
(O) =>
|
|
2599
|
+
(O) => O[wt](...m),
|
|
2600
|
+
(O) => [An(O)],
|
|
2601
|
+
(O) => X(O)
|
|
2693
2602
|
);
|
|
2694
2603
|
}
|
|
2695
|
-
function
|
|
2696
|
-
return
|
|
2697
|
-
(O) => Reflect.apply(
|
|
2698
|
-
() =>
|
|
2604
|
+
function ze(...m) {
|
|
2605
|
+
return ie(
|
|
2606
|
+
(O) => Reflect.apply(bn, null, [O, ...m]),
|
|
2607
|
+
() => Ft(...m),
|
|
2699
2608
|
"number format",
|
|
2700
2609
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
2701
|
-
(O) => O[
|
|
2702
|
-
|
|
2703
|
-
(O) =>
|
|
2610
|
+
(O) => O[$t](...m),
|
|
2611
|
+
Sn,
|
|
2612
|
+
(O) => A(O) || X(O)
|
|
2704
2613
|
);
|
|
2705
2614
|
}
|
|
2706
|
-
function
|
|
2707
|
-
return
|
|
2708
|
-
(O) => Reflect.apply(
|
|
2709
|
-
() =>
|
|
2615
|
+
function et(...m) {
|
|
2616
|
+
return ie(
|
|
2617
|
+
(O) => Reflect.apply(vn, null, [O, ...m]),
|
|
2618
|
+
() => Mt(...m),
|
|
2710
2619
|
"datetime format",
|
|
2711
2620
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
2712
|
-
(O) => O[
|
|
2713
|
-
|
|
2714
|
-
(O) =>
|
|
2621
|
+
(O) => O[Vt](...m),
|
|
2622
|
+
Sn,
|
|
2623
|
+
(O) => A(O) || X(O)
|
|
2715
2624
|
);
|
|
2716
2625
|
}
|
|
2717
|
-
function
|
|
2626
|
+
function tt(m) {
|
|
2718
2627
|
C = m, I.pluralRules = C;
|
|
2719
2628
|
}
|
|
2720
2629
|
function b(m, O) {
|
|
2721
|
-
return
|
|
2630
|
+
return ie(() => {
|
|
2722
2631
|
if (!m)
|
|
2723
2632
|
return !1;
|
|
2724
|
-
const G =
|
|
2725
|
-
return
|
|
2726
|
-
}, () => [m], "translate exists", (G) => Reflect.apply(G.te, G, [m, O]),
|
|
2633
|
+
const G = A(O) ? O : f.value, J = be(G), Te = I.messageResolver(J, m);
|
|
2634
|
+
return i ? Te != null : ve(Te) || ce(Te) || A(Te);
|
|
2635
|
+
}, () => [m], "translate exists", (G) => Reflect.apply(G.te, G, [m, O]), ws, (G) => U(G));
|
|
2727
2636
|
}
|
|
2728
2637
|
function W(m) {
|
|
2729
2638
|
let O = null;
|
|
2730
|
-
const G =
|
|
2731
|
-
for (let
|
|
2732
|
-
const
|
|
2733
|
-
if (
|
|
2734
|
-
O =
|
|
2639
|
+
const G = Zn(I, p.value, f.value);
|
|
2640
|
+
for (let J = 0; J < G.length; J++) {
|
|
2641
|
+
const Te = T.value[G[J]] || {}, ft = I.messageResolver(Te, m);
|
|
2642
|
+
if (ft != null) {
|
|
2643
|
+
O = ft;
|
|
2735
2644
|
break;
|
|
2736
2645
|
}
|
|
2737
2646
|
}
|
|
2738
2647
|
return O;
|
|
2739
2648
|
}
|
|
2740
|
-
function
|
|
2649
|
+
function nt(m) {
|
|
2741
2650
|
const O = W(m);
|
|
2742
2651
|
return O ?? (n ? n.tm(m) || {} : {});
|
|
2743
2652
|
}
|
|
2744
|
-
function
|
|
2653
|
+
function be(m) {
|
|
2745
2654
|
return T.value[m] || {};
|
|
2746
2655
|
}
|
|
2747
|
-
function
|
|
2656
|
+
function rt(m, O) {
|
|
2748
2657
|
if (r) {
|
|
2749
2658
|
const G = { [m]: O };
|
|
2750
|
-
for (const
|
|
2751
|
-
|
|
2659
|
+
for (const J in G)
|
|
2660
|
+
Nt(G, J) && it(G[J]);
|
|
2752
2661
|
O = G[m];
|
|
2753
2662
|
}
|
|
2754
2663
|
T.value[m] = O, I.messages = T.value;
|
|
2755
2664
|
}
|
|
2756
|
-
function
|
|
2665
|
+
function At(m, O) {
|
|
2757
2666
|
T.value[m] = T.value[m] || {};
|
|
2758
2667
|
const G = { [m]: O };
|
|
2759
2668
|
if (r)
|
|
2760
|
-
for (const
|
|
2761
|
-
|
|
2762
|
-
O = G[m],
|
|
2669
|
+
for (const J in G)
|
|
2670
|
+
Nt(G, J) && it(G[J]);
|
|
2671
|
+
O = G[m], Et(O, T.value[m]), I.messages = T.value;
|
|
2763
2672
|
}
|
|
2764
|
-
function
|
|
2673
|
+
function o(m) {
|
|
2765
2674
|
return d.value[m] || {};
|
|
2766
2675
|
}
|
|
2767
2676
|
function c(m, O) {
|
|
2768
|
-
d.value[m] = O, I.datetimeFormats = d.value,
|
|
2677
|
+
d.value[m] = O, I.datetimeFormats = d.value, In(I, m, O);
|
|
2769
2678
|
}
|
|
2770
2679
|
function N(m, O) {
|
|
2771
|
-
d.value[m] =
|
|
2680
|
+
d.value[m] = ee(d.value[m] || {}, O), I.datetimeFormats = d.value, In(I, m, O);
|
|
2772
2681
|
}
|
|
2773
2682
|
function k(m) {
|
|
2774
|
-
return
|
|
2683
|
+
return h.value[m] || {};
|
|
2775
2684
|
}
|
|
2776
|
-
function
|
|
2777
|
-
|
|
2685
|
+
function j(m, O) {
|
|
2686
|
+
h.value[m] = O, I.numberFormats = h.value, hn(I, m, O);
|
|
2778
2687
|
}
|
|
2779
|
-
function
|
|
2780
|
-
|
|
2688
|
+
function Y(m, O) {
|
|
2689
|
+
h.value[m] = ee(h.value[m] || {}, O), I.numberFormats = h.value, hn(I, m, O);
|
|
2781
2690
|
}
|
|
2782
|
-
|
|
2783
|
-
u && (
|
|
2784
|
-
}),
|
|
2785
|
-
u && (p.value = m, I.fallbackLocale = m,
|
|
2691
|
+
Pn++, n && _e && (Rt(n.locale, (m) => {
|
|
2692
|
+
u && (f.value = m, I.locale = m, at(I, f.value, p.value));
|
|
2693
|
+
}), Rt(n.fallbackLocale, (m) => {
|
|
2694
|
+
u && (p.value = m, I.fallbackLocale = m, at(I, f.value, p.value));
|
|
2786
2695
|
}));
|
|
2787
|
-
const
|
|
2788
|
-
id:
|
|
2696
|
+
const x = {
|
|
2697
|
+
id: Pn,
|
|
2789
2698
|
locale: w,
|
|
2790
|
-
fallbackLocale:
|
|
2699
|
+
fallbackLocale: te,
|
|
2791
2700
|
get inheritLocale() {
|
|
2792
2701
|
return u;
|
|
2793
2702
|
},
|
|
2794
2703
|
set inheritLocale(m) {
|
|
2795
|
-
u = m, m && n && (
|
|
2704
|
+
u = m, m && n && (f.value = n.locale.value, p.value = n.fallbackLocale.value, at(I, f.value, p.value));
|
|
2796
2705
|
},
|
|
2797
2706
|
get availableLocales() {
|
|
2798
2707
|
return Object.keys(T.value).sort();
|
|
2799
2708
|
},
|
|
2800
|
-
messages:
|
|
2709
|
+
messages: xe,
|
|
2801
2710
|
get modifiers() {
|
|
2802
2711
|
return v;
|
|
2803
2712
|
},
|
|
@@ -2814,16 +2723,16 @@ function en(e = {}, t) {
|
|
|
2814
2723
|
D = m, I.missingWarn = D;
|
|
2815
2724
|
},
|
|
2816
2725
|
get fallbackWarn() {
|
|
2817
|
-
return
|
|
2726
|
+
return S;
|
|
2818
2727
|
},
|
|
2819
2728
|
set fallbackWarn(m) {
|
|
2820
|
-
|
|
2729
|
+
S = m, I.fallbackWarn = S;
|
|
2821
2730
|
},
|
|
2822
2731
|
get fallbackRoot() {
|
|
2823
|
-
return
|
|
2732
|
+
return P;
|
|
2824
2733
|
},
|
|
2825
2734
|
set fallbackRoot(m) {
|
|
2826
|
-
|
|
2735
|
+
P = m;
|
|
2827
2736
|
},
|
|
2828
2737
|
get fallbackFormat() {
|
|
2829
2738
|
return y;
|
|
@@ -2843,62 +2752,62 @@ function en(e = {}, t) {
|
|
|
2843
2752
|
set escapeParameter(m) {
|
|
2844
2753
|
g = m, I.escapeParameter = m;
|
|
2845
2754
|
},
|
|
2846
|
-
t:
|
|
2847
|
-
getLocaleMessage:
|
|
2848
|
-
setLocaleMessage:
|
|
2849
|
-
mergeLocaleMessage:
|
|
2850
|
-
getPostTranslationHandler:
|
|
2851
|
-
setPostTranslationHandler:
|
|
2852
|
-
getMissingHandler:
|
|
2853
|
-
setMissingHandler:
|
|
2854
|
-
[
|
|
2755
|
+
t: ke,
|
|
2756
|
+
getLocaleMessage: be,
|
|
2757
|
+
setLocaleMessage: rt,
|
|
2758
|
+
mergeLocaleMessage: At,
|
|
2759
|
+
getPostTranslationHandler: Ye,
|
|
2760
|
+
setPostTranslationHandler: Be,
|
|
2761
|
+
getMissingHandler: Xe,
|
|
2762
|
+
setMissingHandler: je,
|
|
2763
|
+
[pr]: tt
|
|
2855
2764
|
};
|
|
2856
|
-
return
|
|
2765
|
+
return x.datetimeFormats = He, x.numberFormats = fe, x.rt = ye, x.te = b, x.tm = nt, x.d = Je, x.n = Qe, x.getDateTimeFormat = o, x.setDateTimeFormat = c, x.mergeDateTimeFormat = N, x.getNumberFormat = k, x.setNumberFormat = j, x.mergeNumberFormat = Y, x[Tr] = a, x[wt] = Me, x[Vt] = et, x[$t] = ze, process.env.NODE_ENV !== "production" && (x[Re] = (m) => {
|
|
2857
2766
|
I.__v_emitter = m;
|
|
2858
|
-
},
|
|
2767
|
+
}, x[ot] = () => {
|
|
2859
2768
|
I.__v_emitter = void 0;
|
|
2860
|
-
}),
|
|
2769
|
+
}), x;
|
|
2861
2770
|
}
|
|
2862
|
-
function
|
|
2863
|
-
const t =
|
|
2864
|
-
process.env.NODE_ENV !== "production" && e.formatter &&
|
|
2771
|
+
function $s(e) {
|
|
2772
|
+
const t = A(e.locale) ? e.locale : We, n = A(e.fallbackLocale) || X(e.fallbackLocale) || F(e.fallbackLocale) || e.fallbackLocale === !1 ? e.fallbackLocale : t, a = H(e.missing) ? e.missing : void 0, s = U(e.silentTranslationWarn) || Le(e.silentTranslationWarn) ? !e.silentTranslationWarn : !0, r = U(e.silentFallbackWarn) || Le(e.silentFallbackWarn) ? !e.silentFallbackWarn : !0, l = U(e.fallbackRoot) ? e.fallbackRoot : !0, i = !!e.formatFallbackMessages, u = F(e.modifiers) ? e.modifiers : {}, f = e.pluralizationRules, p = H(e.postTranslation) ? e.postTranslation : void 0, T = A(e.warnHtmlInMessage) ? e.warnHtmlInMessage !== "off" : !0, d = !!e.escapeParameterHtml, h = U(e.sync) ? e.sync : !0;
|
|
2773
|
+
process.env.NODE_ENV !== "production" && e.formatter && q(se(K.NOT_SUPPORTED_FORMATTER)), process.env.NODE_ENV !== "production" && e.preserveDirectiveContent && q(se(K.NOT_SUPPORTED_PRESERVE_DIRECTIVE));
|
|
2865
2774
|
let D = e.messages;
|
|
2866
2775
|
if (F(e.sharedMessages)) {
|
|
2867
2776
|
const g = e.sharedMessages;
|
|
2868
2777
|
D = Object.keys(g).reduce((C, I) => {
|
|
2869
|
-
const
|
|
2870
|
-
return
|
|
2778
|
+
const B = C[I] || (C[I] = {});
|
|
2779
|
+
return ee(B, g[I]), C;
|
|
2871
2780
|
}, D || {});
|
|
2872
2781
|
}
|
|
2873
|
-
const { __i18n:
|
|
2782
|
+
const { __i18n: S, __root: P, __injectWithOption: y } = e, R = e.datetimeFormats, _ = e.numberFormats, E = e.flatJson, L = e.translateExistCompatible;
|
|
2874
2783
|
return {
|
|
2875
2784
|
locale: t,
|
|
2876
2785
|
fallbackLocale: n,
|
|
2877
2786
|
messages: D,
|
|
2878
2787
|
flatJson: E,
|
|
2879
2788
|
datetimeFormats: R,
|
|
2880
|
-
numberFormats:
|
|
2789
|
+
numberFormats: _,
|
|
2881
2790
|
missing: a,
|
|
2882
2791
|
missingWarn: s,
|
|
2883
2792
|
fallbackWarn: r,
|
|
2884
2793
|
fallbackRoot: l,
|
|
2885
|
-
fallbackFormat:
|
|
2794
|
+
fallbackFormat: i,
|
|
2886
2795
|
modifiers: u,
|
|
2887
|
-
pluralRules:
|
|
2796
|
+
pluralRules: f,
|
|
2888
2797
|
postTranslation: p,
|
|
2889
2798
|
warnHtmlMessage: T,
|
|
2890
2799
|
escapeParameter: d,
|
|
2891
2800
|
messageResolver: e.messageResolver,
|
|
2892
|
-
inheritLocale:
|
|
2801
|
+
inheritLocale: h,
|
|
2893
2802
|
translateExistCompatible: L,
|
|
2894
|
-
__i18n:
|
|
2895
|
-
__root:
|
|
2803
|
+
__i18n: S,
|
|
2804
|
+
__root: P,
|
|
2896
2805
|
__injectWithOption: y
|
|
2897
2806
|
};
|
|
2898
2807
|
}
|
|
2899
|
-
function
|
|
2808
|
+
function Gt(e = {}, t) {
|
|
2900
2809
|
{
|
|
2901
|
-
const n =
|
|
2810
|
+
const n = Kt($s(e)), { __extender: a } = e, s = {
|
|
2902
2811
|
// id
|
|
2903
2812
|
id: n.id,
|
|
2904
2813
|
// locale
|
|
@@ -2933,14 +2842,14 @@ function jt(e = {}, t) {
|
|
|
2933
2842
|
},
|
|
2934
2843
|
// formatter
|
|
2935
2844
|
get formatter() {
|
|
2936
|
-
return process.env.NODE_ENV !== "production" &&
|
|
2845
|
+
return process.env.NODE_ENV !== "production" && q(se(K.NOT_SUPPORTED_FORMATTER)), {
|
|
2937
2846
|
interpolate() {
|
|
2938
2847
|
return [];
|
|
2939
2848
|
}
|
|
2940
2849
|
};
|
|
2941
2850
|
},
|
|
2942
2851
|
set formatter(r) {
|
|
2943
|
-
process.env.NODE_ENV !== "production" &&
|
|
2852
|
+
process.env.NODE_ENV !== "production" && q(se(K.NOT_SUPPORTED_FORMATTER));
|
|
2944
2853
|
},
|
|
2945
2854
|
// missing
|
|
2946
2855
|
get missing() {
|
|
@@ -3004,10 +2913,10 @@ function jt(e = {}, t) {
|
|
|
3004
2913
|
},
|
|
3005
2914
|
// preserveDirectiveContent
|
|
3006
2915
|
get preserveDirectiveContent() {
|
|
3007
|
-
return process.env.NODE_ENV !== "production" &&
|
|
2916
|
+
return process.env.NODE_ENV !== "production" && q(se(K.NOT_SUPPORTED_PRESERVE_DIRECTIVE)), !0;
|
|
3008
2917
|
},
|
|
3009
2918
|
set preserveDirectiveContent(r) {
|
|
3010
|
-
process.env.NODE_ENV !== "production" &&
|
|
2919
|
+
process.env.NODE_ENV !== "production" && q(se(K.NOT_SUPPORTED_PRESERVE_DIRECTIVE));
|
|
3011
2920
|
},
|
|
3012
2921
|
// pluralizationRules
|
|
3013
2922
|
get pluralizationRules() {
|
|
@@ -3017,15 +2926,15 @@ function jt(e = {}, t) {
|
|
|
3017
2926
|
__composer: n,
|
|
3018
2927
|
// t
|
|
3019
2928
|
t(...r) {
|
|
3020
|
-
const [l,
|
|
2929
|
+
const [l, i, u] = r, f = {};
|
|
3021
2930
|
let p = null, T = null;
|
|
3022
|
-
if (!
|
|
3023
|
-
throw
|
|
2931
|
+
if (!A(l))
|
|
2932
|
+
throw Z(V.INVALID_ARGUMENT);
|
|
3024
2933
|
const d = l;
|
|
3025
|
-
return
|
|
2934
|
+
return A(i) ? f.locale = i : X(i) ? p = i : F(i) && (T = i), X(u) ? p = u : F(u) && (T = u), Reflect.apply(n.t, n, [
|
|
3026
2935
|
d,
|
|
3027
2936
|
p || T || {},
|
|
3028
|
-
|
|
2937
|
+
f
|
|
3029
2938
|
]);
|
|
3030
2939
|
},
|
|
3031
2940
|
rt(...r) {
|
|
@@ -3033,15 +2942,15 @@ function jt(e = {}, t) {
|
|
|
3033
2942
|
},
|
|
3034
2943
|
// tc
|
|
3035
2944
|
tc(...r) {
|
|
3036
|
-
const [l,
|
|
2945
|
+
const [l, i, u] = r, f = { plural: 1 };
|
|
3037
2946
|
let p = null, T = null;
|
|
3038
|
-
if (!
|
|
3039
|
-
throw
|
|
2947
|
+
if (!A(l))
|
|
2948
|
+
throw Z(V.INVALID_ARGUMENT);
|
|
3040
2949
|
const d = l;
|
|
3041
|
-
return
|
|
2950
|
+
return A(i) ? f.locale = i : Q(i) ? f.plural = i : X(i) ? p = i : F(i) && (T = i), A(u) ? f.locale = u : X(u) ? p = u : F(u) && (T = u), Reflect.apply(n.t, n, [
|
|
3042
2951
|
d,
|
|
3043
2952
|
p || T || {},
|
|
3044
|
-
|
|
2953
|
+
f
|
|
3045
2954
|
]);
|
|
3046
2955
|
},
|
|
3047
2956
|
// te
|
|
@@ -3099,19 +3008,19 @@ function jt(e = {}, t) {
|
|
|
3099
3008
|
// getChoiceIndex
|
|
3100
3009
|
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
3101
3010
|
getChoiceIndex(r, l) {
|
|
3102
|
-
return process.env.NODE_ENV !== "production" &&
|
|
3011
|
+
return process.env.NODE_ENV !== "production" && q(se(K.NOT_SUPPORTED_GET_CHOICE_INDEX)), -1;
|
|
3103
3012
|
}
|
|
3104
3013
|
};
|
|
3105
3014
|
return s.__extender = a, process.env.NODE_ENV !== "production" && (s.__enableEmitter = (r) => {
|
|
3106
3015
|
const l = n;
|
|
3107
|
-
l[
|
|
3016
|
+
l[Re] && l[Re](r);
|
|
3108
3017
|
}, s.__disableEmitter = () => {
|
|
3109
3018
|
const r = n;
|
|
3110
|
-
r[
|
|
3019
|
+
r[ot] && r[ot]();
|
|
3111
3020
|
}), s;
|
|
3112
3021
|
}
|
|
3113
3022
|
}
|
|
3114
|
-
const
|
|
3023
|
+
const Jt = {
|
|
3115
3024
|
tag: {
|
|
3116
3025
|
type: [String, Object]
|
|
3117
3026
|
},
|
|
@@ -3129,23 +3038,23 @@ const tn = {
|
|
|
3129
3038
|
type: Object
|
|
3130
3039
|
}
|
|
3131
3040
|
};
|
|
3132
|
-
function
|
|
3041
|
+
function Ws({ slots: e }, t) {
|
|
3133
3042
|
return t.length === 1 && t[0] === "default" ? (e.default ? e.default() : []).reduce((a, s) => [
|
|
3134
3043
|
...a,
|
|
3135
3044
|
// prettier-ignore
|
|
3136
|
-
...s.type ===
|
|
3045
|
+
...s.type === xn ? s.children : [s]
|
|
3137
3046
|
], []) : t.reduce((n, a) => {
|
|
3138
3047
|
const s = e[a];
|
|
3139
3048
|
return s && (n[a] = s()), n;
|
|
3140
|
-
},
|
|
3049
|
+
}, {});
|
|
3141
3050
|
}
|
|
3142
|
-
function
|
|
3143
|
-
return
|
|
3051
|
+
function vr(e) {
|
|
3052
|
+
return xn;
|
|
3144
3053
|
}
|
|
3145
|
-
const
|
|
3054
|
+
const Gs = /* @__PURE__ */ ut({
|
|
3146
3055
|
/* eslint-disable */
|
|
3147
3056
|
name: "i18n-t",
|
|
3148
|
-
props:
|
|
3057
|
+
props: ee({
|
|
3149
3058
|
keypath: {
|
|
3150
3059
|
type: String,
|
|
3151
3060
|
required: !0
|
|
@@ -3153,47 +3062,47 @@ const fl = /* @__PURE__ */ dt({
|
|
|
3153
3062
|
plural: {
|
|
3154
3063
|
type: [Number, String],
|
|
3155
3064
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
3156
|
-
validator: (e) =>
|
|
3065
|
+
validator: (e) => Q(e) || !isNaN(e)
|
|
3157
3066
|
}
|
|
3158
|
-
},
|
|
3067
|
+
}, Jt),
|
|
3159
3068
|
/* eslint-enable */
|
|
3160
3069
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
3161
3070
|
setup(e, t) {
|
|
3162
|
-
const { slots: n, attrs: a } = t, s = e.i18n ||
|
|
3071
|
+
const { slots: n, attrs: a } = t, s = e.i18n || qt({
|
|
3163
3072
|
useScope: e.scope,
|
|
3164
3073
|
__useComponent: !0
|
|
3165
3074
|
});
|
|
3166
3075
|
return () => {
|
|
3167
|
-
const r = Object.keys(n).filter((T) => T !== "_"), l =
|
|
3168
|
-
e.locale && (l.locale = e.locale), e.plural !== void 0 && (l.plural =
|
|
3169
|
-
const
|
|
3170
|
-
return
|
|
3076
|
+
const r = Object.keys(n).filter((T) => T !== "_"), l = {};
|
|
3077
|
+
e.locale && (l.locale = e.locale), e.plural !== void 0 && (l.plural = A(e.plural) ? +e.plural : e.plural);
|
|
3078
|
+
const i = Ws(t, r), u = s[wt](e.keypath, i, l), f = ee({}, a), p = A(e.tag) || $(e.tag) ? e.tag : vr();
|
|
3079
|
+
return Gn(p, f, u);
|
|
3171
3080
|
};
|
|
3172
3081
|
}
|
|
3173
|
-
}),
|
|
3174
|
-
function
|
|
3175
|
-
return
|
|
3082
|
+
}), Pt = Gs;
|
|
3083
|
+
function xs(e) {
|
|
3084
|
+
return X(e) && !A(e[0]);
|
|
3176
3085
|
}
|
|
3177
|
-
function
|
|
3086
|
+
function Ir(e, t, n, a) {
|
|
3178
3087
|
const { slots: s, attrs: r } = t;
|
|
3179
3088
|
return () => {
|
|
3180
3089
|
const l = { part: !0 };
|
|
3181
|
-
let
|
|
3182
|
-
e.locale && (l.locale = e.locale),
|
|
3183
|
-
const u = a(e.value, l,
|
|
3184
|
-
let
|
|
3185
|
-
|
|
3186
|
-
const D = s[d.type],
|
|
3187
|
-
return
|
|
3188
|
-
}) :
|
|
3189
|
-
const p =
|
|
3190
|
-
return
|
|
3090
|
+
let i = {};
|
|
3091
|
+
e.locale && (l.locale = e.locale), A(e.format) ? l.key = e.format : $(e.format) && (A(e.format.key) && (l.key = e.format.key), i = Object.keys(e.format).reduce((d, h) => n.includes(h) ? ee({}, d, { [h]: e.format[h] }) : d, {}));
|
|
3092
|
+
const u = a(e.value, l, i);
|
|
3093
|
+
let f = [l.key];
|
|
3094
|
+
X(u) ? f = u.map((d, h) => {
|
|
3095
|
+
const D = s[d.type], S = D ? D({ [d.type]: d.value, index: h, parts: u }) : [d.value];
|
|
3096
|
+
return xs(S) && (S[0].key = `${d.type}-${h}`), S;
|
|
3097
|
+
}) : A(u) && (f = [u]);
|
|
3098
|
+
const p = ee({}, r), T = A(e.tag) || $(e.tag) ? e.tag : vr();
|
|
3099
|
+
return Gn(T, p, f);
|
|
3191
3100
|
};
|
|
3192
3101
|
}
|
|
3193
|
-
const
|
|
3102
|
+
const Hs = /* @__PURE__ */ ut({
|
|
3194
3103
|
/* eslint-disable */
|
|
3195
3104
|
name: "i18n-n",
|
|
3196
|
-
props:
|
|
3105
|
+
props: ee({
|
|
3197
3106
|
value: {
|
|
3198
3107
|
type: Number,
|
|
3199
3108
|
required: !0
|
|
@@ -3201,23 +3110,23 @@ const ml = /* @__PURE__ */ dt({
|
|
|
3201
3110
|
format: {
|
|
3202
3111
|
type: [String, Object]
|
|
3203
3112
|
}
|
|
3204
|
-
},
|
|
3113
|
+
}, Jt),
|
|
3205
3114
|
/* eslint-enable */
|
|
3206
3115
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
3207
3116
|
setup(e, t) {
|
|
3208
|
-
const n = e.i18n ||
|
|
3117
|
+
const n = e.i18n || qt({
|
|
3209
3118
|
useScope: e.scope,
|
|
3210
3119
|
__useComponent: !0
|
|
3211
3120
|
});
|
|
3212
|
-
return
|
|
3121
|
+
return Ir(e, t, dr, (...a) => (
|
|
3213
3122
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
3214
|
-
n[
|
|
3123
|
+
n[$t](...a)
|
|
3215
3124
|
));
|
|
3216
3125
|
}
|
|
3217
|
-
}),
|
|
3126
|
+
}), Rn = Hs, Ys = /* @__PURE__ */ ut({
|
|
3218
3127
|
/* eslint-disable */
|
|
3219
3128
|
name: "i18n-d",
|
|
3220
|
-
props:
|
|
3129
|
+
props: ee({
|
|
3221
3130
|
value: {
|
|
3222
3131
|
type: [Number, Date],
|
|
3223
3132
|
required: !0
|
|
@@ -3225,21 +3134,21 @@ const ml = /* @__PURE__ */ dt({
|
|
|
3225
3134
|
format: {
|
|
3226
3135
|
type: [String, Object]
|
|
3227
3136
|
}
|
|
3228
|
-
},
|
|
3137
|
+
}, Jt),
|
|
3229
3138
|
/* eslint-enable */
|
|
3230
3139
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
3231
3140
|
setup(e, t) {
|
|
3232
|
-
const n = e.i18n ||
|
|
3141
|
+
const n = e.i18n || qt({
|
|
3233
3142
|
useScope: e.scope,
|
|
3234
3143
|
__useComponent: !0
|
|
3235
3144
|
});
|
|
3236
|
-
return
|
|
3145
|
+
return Ir(e, t, mr, (...a) => (
|
|
3237
3146
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
3238
|
-
n[
|
|
3147
|
+
n[Vt](...a)
|
|
3239
3148
|
));
|
|
3240
3149
|
}
|
|
3241
|
-
}),
|
|
3242
|
-
function
|
|
3150
|
+
}), kn = Ys;
|
|
3151
|
+
function Bs(e, t) {
|
|
3243
3152
|
const n = e;
|
|
3244
3153
|
if (e.mode === "composition")
|
|
3245
3154
|
return n.__getInstance(t) || e.global;
|
|
@@ -3248,129 +3157,129 @@ function El(e, t) {
|
|
|
3248
3157
|
return a != null ? a.__composer : e.global.__composer;
|
|
3249
3158
|
}
|
|
3250
3159
|
}
|
|
3251
|
-
function
|
|
3160
|
+
function Xs(e) {
|
|
3252
3161
|
const t = (l) => {
|
|
3253
|
-
const { instance:
|
|
3254
|
-
if (!
|
|
3255
|
-
throw
|
|
3256
|
-
const p =
|
|
3257
|
-
process.env.NODE_ENV !== "production" && u.preserve &&
|
|
3258
|
-
const T =
|
|
3162
|
+
const { instance: i, modifiers: u, value: f } = l;
|
|
3163
|
+
if (!i || !i.$)
|
|
3164
|
+
throw Z(V.UNEXPECTED_ERROR);
|
|
3165
|
+
const p = Bs(e, i.$);
|
|
3166
|
+
process.env.NODE_ENV !== "production" && u.preserve && q(se(K.NOT_SUPPORTED_PRESERVE));
|
|
3167
|
+
const T = yn(f);
|
|
3259
3168
|
return [
|
|
3260
|
-
Reflect.apply(p.t, p, [...
|
|
3169
|
+
Reflect.apply(p.t, p, [...Mn(T)]),
|
|
3261
3170
|
p
|
|
3262
3171
|
];
|
|
3263
3172
|
};
|
|
3264
3173
|
return {
|
|
3265
|
-
created: (l,
|
|
3266
|
-
const [u,
|
|
3267
|
-
|
|
3268
|
-
|
|
3269
|
-
})), l.__composer =
|
|
3174
|
+
created: (l, i) => {
|
|
3175
|
+
const [u, f] = t(i);
|
|
3176
|
+
_e && e.global === f && (l.__i18nWatcher = Rt(f.locale, () => {
|
|
3177
|
+
i.instance && i.instance.$forceUpdate();
|
|
3178
|
+
})), l.__composer = f, l.textContent = u;
|
|
3270
3179
|
},
|
|
3271
3180
|
unmounted: (l) => {
|
|
3272
|
-
|
|
3181
|
+
_e && l.__i18nWatcher && (l.__i18nWatcher(), l.__i18nWatcher = void 0, delete l.__i18nWatcher), l.__composer && (l.__composer = void 0, delete l.__composer);
|
|
3273
3182
|
},
|
|
3274
|
-
beforeUpdate: (l, { value:
|
|
3183
|
+
beforeUpdate: (l, { value: i }) => {
|
|
3275
3184
|
if (l.__composer) {
|
|
3276
|
-
const u = l.__composer,
|
|
3185
|
+
const u = l.__composer, f = yn(i);
|
|
3277
3186
|
l.textContent = Reflect.apply(u.t, u, [
|
|
3278
|
-
...
|
|
3187
|
+
...Mn(f)
|
|
3279
3188
|
]);
|
|
3280
3189
|
}
|
|
3281
3190
|
},
|
|
3282
3191
|
getSSRProps: (l) => {
|
|
3283
|
-
const [
|
|
3284
|
-
return { textContent:
|
|
3192
|
+
const [i] = t(l);
|
|
3193
|
+
return { textContent: i };
|
|
3285
3194
|
}
|
|
3286
3195
|
};
|
|
3287
3196
|
}
|
|
3288
|
-
function
|
|
3289
|
-
if (
|
|
3197
|
+
function yn(e) {
|
|
3198
|
+
if (A(e))
|
|
3290
3199
|
return { path: e };
|
|
3291
3200
|
if (F(e)) {
|
|
3292
3201
|
if (!("path" in e))
|
|
3293
|
-
throw
|
|
3202
|
+
throw Z(V.REQUIRED_VALUE, "path");
|
|
3294
3203
|
return e;
|
|
3295
3204
|
} else
|
|
3296
|
-
throw
|
|
3205
|
+
throw Z(V.INVALID_VALUE);
|
|
3297
3206
|
}
|
|
3298
|
-
function
|
|
3299
|
-
const { path: t, locale: n, args: a, choice: s, plural: r } = e, l = {},
|
|
3300
|
-
return
|
|
3207
|
+
function Mn(e) {
|
|
3208
|
+
const { path: t, locale: n, args: a, choice: s, plural: r } = e, l = {}, i = a || {};
|
|
3209
|
+
return A(n) && (l.locale = n), Q(s) && (l.plural = s), Q(r) && (l.plural = r), [t, i, l];
|
|
3301
3210
|
}
|
|
3302
|
-
function
|
|
3211
|
+
function js(e, t, ...n) {
|
|
3303
3212
|
const a = F(n[0]) ? n[0] : {}, s = !!a.useI18nComponentName, r = U(a.globalInstall) ? a.globalInstall : !0;
|
|
3304
|
-
process.env.NODE_ENV !== "production" && r && s &&
|
|
3305
|
-
name:
|
|
3306
|
-
})), r && ([s ? "i18n" :
|
|
3213
|
+
process.env.NODE_ENV !== "production" && r && s && q(se(K.COMPONENT_NAME_LEGACY_COMPATIBLE, {
|
|
3214
|
+
name: Pt.name
|
|
3215
|
+
})), r && ([s ? "i18n" : Pt.name, "I18nT"].forEach((l) => e.component(l, Pt)), [Rn.name, "I18nN"].forEach((l) => e.component(l, Rn)), [kn.name, "I18nD"].forEach((l) => e.component(l, kn))), e.directive("t", Xs(t));
|
|
3307
3216
|
}
|
|
3308
|
-
const
|
|
3217
|
+
const Dt = {
|
|
3309
3218
|
"vue-devtools-plugin-vue-i18n": "Vue I18n devtools",
|
|
3310
3219
|
"vue-i18n-resource-inspector": "I18n Resources",
|
|
3311
3220
|
"vue-i18n-timeline": "Vue I18n"
|
|
3312
|
-
},
|
|
3221
|
+
}, Ks = {
|
|
3313
3222
|
"vue-i18n-resource-inspector": "Search for scopes ..."
|
|
3314
|
-
},
|
|
3223
|
+
}, Js = {
|
|
3315
3224
|
"vue-i18n-timeline": 16764185
|
|
3316
|
-
},
|
|
3317
|
-
let
|
|
3318
|
-
async function
|
|
3225
|
+
}, br = "vue-i18n: composer properties";
|
|
3226
|
+
let xt;
|
|
3227
|
+
async function Qs(e, t) {
|
|
3319
3228
|
return new Promise((n, a) => {
|
|
3320
3229
|
try {
|
|
3321
|
-
|
|
3230
|
+
ks({
|
|
3322
3231
|
id: "vue-devtools-plugin-vue-i18n",
|
|
3323
|
-
label:
|
|
3232
|
+
label: Dt[
|
|
3324
3233
|
"vue-devtools-plugin-vue-i18n"
|
|
3325
3234
|
/* VueDevToolsIDs.PLUGIN */
|
|
3326
3235
|
],
|
|
3327
3236
|
packageName: "vue-i18n",
|
|
3328
3237
|
homepage: "https://vue-i18n.intlify.dev",
|
|
3329
3238
|
logo: "https://vue-i18n.intlify.dev/vue-i18n-devtools-logo.png",
|
|
3330
|
-
componentStateTypes: [
|
|
3239
|
+
componentStateTypes: [br],
|
|
3331
3240
|
app: e
|
|
3332
3241
|
// eslint-disable-line @typescript-eslint/no-explicit-any
|
|
3333
3242
|
}, (s) => {
|
|
3334
|
-
|
|
3335
|
-
|
|
3336
|
-
}), s.on.inspectComponent(({ componentInstance: l, instanceData:
|
|
3337
|
-
l.vnode.el && l.vnode.el.__VUE_I18N__ &&
|
|
3243
|
+
xt = s, s.on.visitComponentTree(({ componentInstance: l, treeNode: i }) => {
|
|
3244
|
+
qs(l, i, t);
|
|
3245
|
+
}), s.on.inspectComponent(({ componentInstance: l, instanceData: i }) => {
|
|
3246
|
+
l.vnode.el && l.vnode.el.__VUE_I18N__ && i && (t.mode === "legacy" ? l.vnode.el.__VUE_I18N__ !== t.global.__composer && Fn(i, l.vnode.el.__VUE_I18N__) : Fn(i, l.vnode.el.__VUE_I18N__));
|
|
3338
3247
|
}), s.addInspector({
|
|
3339
3248
|
id: "vue-i18n-resource-inspector",
|
|
3340
|
-
label:
|
|
3249
|
+
label: Dt[
|
|
3341
3250
|
"vue-i18n-resource-inspector"
|
|
3342
3251
|
/* VueDevToolsIDs.CUSTOM_INSPECTOR */
|
|
3343
3252
|
],
|
|
3344
3253
|
icon: "language",
|
|
3345
|
-
treeFilterPlaceholder:
|
|
3254
|
+
treeFilterPlaceholder: Ks[
|
|
3346
3255
|
"vue-i18n-resource-inspector"
|
|
3347
3256
|
/* VueDevToolsIDs.CUSTOM_INSPECTOR */
|
|
3348
3257
|
]
|
|
3349
3258
|
}), s.on.getInspectorTree((l) => {
|
|
3350
|
-
l.app === e && l.inspectorId === "vue-i18n-resource-inspector" &&
|
|
3259
|
+
l.app === e && l.inspectorId === "vue-i18n-resource-inspector" && nl(l, t);
|
|
3351
3260
|
});
|
|
3352
3261
|
const r = /* @__PURE__ */ new Map();
|
|
3353
3262
|
s.on.getInspectorState(async (l) => {
|
|
3354
3263
|
if (l.app === e && l.inspectorId === "vue-i18n-resource-inspector")
|
|
3355
|
-
if (s.unhighlightElement(),
|
|
3264
|
+
if (s.unhighlightElement(), al(l, t), l.nodeId === "global") {
|
|
3356
3265
|
if (!r.has(l.app)) {
|
|
3357
|
-
const [
|
|
3358
|
-
r.set(l.app,
|
|
3266
|
+
const [i] = await s.getComponentInstances(l.app);
|
|
3267
|
+
r.set(l.app, i);
|
|
3359
3268
|
}
|
|
3360
3269
|
s.highlightElement(r.get(l.app));
|
|
3361
3270
|
} else {
|
|
3362
|
-
const
|
|
3363
|
-
|
|
3271
|
+
const i = rl(l.nodeId, t);
|
|
3272
|
+
i && s.highlightElement(i);
|
|
3364
3273
|
}
|
|
3365
3274
|
}), s.on.editInspectorState((l) => {
|
|
3366
|
-
l.app === e && l.inspectorId === "vue-i18n-resource-inspector" &&
|
|
3275
|
+
l.app === e && l.inspectorId === "vue-i18n-resource-inspector" && ll(l, t);
|
|
3367
3276
|
}), s.addTimelineLayer({
|
|
3368
3277
|
id: "vue-i18n-timeline",
|
|
3369
|
-
label:
|
|
3278
|
+
label: Dt[
|
|
3370
3279
|
"vue-i18n-timeline"
|
|
3371
3280
|
/* VueDevToolsIDs.TIMELINE */
|
|
3372
3281
|
],
|
|
3373
|
-
color:
|
|
3282
|
+
color: Js[
|
|
3374
3283
|
"vue-i18n-timeline"
|
|
3375
3284
|
/* VueDevToolsIDs.TIMELINE */
|
|
3376
3285
|
]
|
|
@@ -3381,22 +3290,22 @@ async function Ol(e, t) {
|
|
|
3381
3290
|
}
|
|
3382
3291
|
});
|
|
3383
3292
|
}
|
|
3384
|
-
function
|
|
3293
|
+
function hr(e) {
|
|
3385
3294
|
return e.type.name || e.type.displayName || e.type.__file || "Anonymous";
|
|
3386
3295
|
}
|
|
3387
|
-
function
|
|
3296
|
+
function qs(e, t, n) {
|
|
3388
3297
|
const a = n.mode === "composition" ? n.global : n.global.__composer;
|
|
3389
3298
|
if (e && e.vnode.el && e.vnode.el.__VUE_I18N__ && e.vnode.el.__VUE_I18N__ !== a) {
|
|
3390
3299
|
const s = {
|
|
3391
|
-
label: `i18n (${
|
|
3300
|
+
label: `i18n (${hr(e)} Scope)`,
|
|
3392
3301
|
textColor: 0,
|
|
3393
3302
|
backgroundColor: 16764185
|
|
3394
3303
|
};
|
|
3395
3304
|
t.tags.push(s);
|
|
3396
3305
|
}
|
|
3397
3306
|
}
|
|
3398
|
-
function
|
|
3399
|
-
const n =
|
|
3307
|
+
function Fn(e, t) {
|
|
3308
|
+
const n = br;
|
|
3400
3309
|
e.state.push({
|
|
3401
3310
|
type: n,
|
|
3402
3311
|
key: "locale",
|
|
@@ -3421,7 +3330,7 @@ function Hn(e, t) {
|
|
|
3421
3330
|
type: n,
|
|
3422
3331
|
key: "messages",
|
|
3423
3332
|
editable: !1,
|
|
3424
|
-
value:
|
|
3333
|
+
value: Qt(t.messages.value)
|
|
3425
3334
|
}), e.state.push({
|
|
3426
3335
|
type: n,
|
|
3427
3336
|
key: "datetimeFormats",
|
|
@@ -3434,34 +3343,34 @@ function Hn(e, t) {
|
|
|
3434
3343
|
value: t.numberFormats.value
|
|
3435
3344
|
});
|
|
3436
3345
|
}
|
|
3437
|
-
function
|
|
3346
|
+
function Qt(e) {
|
|
3438
3347
|
const t = {};
|
|
3439
3348
|
return Object.keys(e).forEach((n) => {
|
|
3440
3349
|
const a = e[n];
|
|
3441
|
-
|
|
3350
|
+
H(a) && "source" in a ? t[n] = tl(a) : ve(a) && a.loc && a.loc.source ? t[n] = a.loc.source : $(a) ? t[n] = Qt(a) : t[n] = a;
|
|
3442
3351
|
}), t;
|
|
3443
3352
|
}
|
|
3444
|
-
const
|
|
3353
|
+
const Zs = {
|
|
3445
3354
|
"<": "<",
|
|
3446
3355
|
">": ">",
|
|
3447
3356
|
'"': """,
|
|
3448
3357
|
"&": "&"
|
|
3449
3358
|
};
|
|
3450
|
-
function
|
|
3451
|
-
return e.replace(/[<>"&]/g,
|
|
3359
|
+
function zs(e) {
|
|
3360
|
+
return e.replace(/[<>"&]/g, el);
|
|
3452
3361
|
}
|
|
3453
|
-
function
|
|
3454
|
-
return
|
|
3362
|
+
function el(e) {
|
|
3363
|
+
return Zs[e] || e;
|
|
3455
3364
|
}
|
|
3456
|
-
function
|
|
3365
|
+
function tl(e) {
|
|
3457
3366
|
return {
|
|
3458
3367
|
_custom: {
|
|
3459
3368
|
type: "function",
|
|
3460
|
-
display: `<span>ƒ</span> ${e.source ? `("${
|
|
3369
|
+
display: `<span>ƒ</span> ${e.source ? `("${zs(e.source)}")` : "(?)"}`
|
|
3461
3370
|
}
|
|
3462
3371
|
};
|
|
3463
3372
|
}
|
|
3464
|
-
function
|
|
3373
|
+
function nl(e, t) {
|
|
3465
3374
|
e.rootNodes.push({
|
|
3466
3375
|
id: "global",
|
|
3467
3376
|
label: "Global Scope"
|
|
@@ -3471,11 +3380,11 @@ function Al(e, t) {
|
|
|
3471
3380
|
const r = t.mode === "composition" ? s : s.__composer;
|
|
3472
3381
|
n !== r && e.rootNodes.push({
|
|
3473
3382
|
id: r.id.toString(),
|
|
3474
|
-
label: `${
|
|
3383
|
+
label: `${hr(a)} Scope`
|
|
3475
3384
|
});
|
|
3476
3385
|
}
|
|
3477
3386
|
}
|
|
3478
|
-
function
|
|
3387
|
+
function rl(e, t) {
|
|
3479
3388
|
let n = null;
|
|
3480
3389
|
if (e !== "global") {
|
|
3481
3390
|
for (const [a, s] of t.__instances.entries())
|
|
@@ -3486,7 +3395,7 @@ function Cl(e, t) {
|
|
|
3486
3395
|
}
|
|
3487
3396
|
return n;
|
|
3488
3397
|
}
|
|
3489
|
-
function
|
|
3398
|
+
function Ar(e, t) {
|
|
3490
3399
|
if (e === "global")
|
|
3491
3400
|
return t.mode === "composition" ? t.global : t.global.__composer;
|
|
3492
3401
|
{
|
|
@@ -3494,11 +3403,11 @@ function Hr(e, t) {
|
|
|
3494
3403
|
return n ? t.mode === "composition" ? n : n.__composer : null;
|
|
3495
3404
|
}
|
|
3496
3405
|
}
|
|
3497
|
-
function
|
|
3498
|
-
const n =
|
|
3499
|
-
return n && (e.state =
|
|
3406
|
+
function al(e, t) {
|
|
3407
|
+
const n = Ar(e.nodeId, t);
|
|
3408
|
+
return n && (e.state = sl(n)), null;
|
|
3500
3409
|
}
|
|
3501
|
-
function
|
|
3410
|
+
function sl(e) {
|
|
3502
3411
|
const t = {}, n = "Locale related info", a = [
|
|
3503
3412
|
{
|
|
3504
3413
|
type: n,
|
|
@@ -3531,12 +3440,12 @@ function Sl(e) {
|
|
|
3531
3440
|
type: s,
|
|
3532
3441
|
key: "messages",
|
|
3533
3442
|
editable: !1,
|
|
3534
|
-
value:
|
|
3443
|
+
value: Qt(e.messages.value)
|
|
3535
3444
|
}
|
|
3536
3445
|
];
|
|
3537
3446
|
t[s] = r;
|
|
3538
3447
|
{
|
|
3539
|
-
const l = "Datetime formats info",
|
|
3448
|
+
const l = "Datetime formats info", i = [
|
|
3540
3449
|
{
|
|
3541
3450
|
type: l,
|
|
3542
3451
|
key: "datetimeFormats",
|
|
@@ -3544,8 +3453,8 @@ function Sl(e) {
|
|
|
3544
3453
|
value: e.datetimeFormats.value
|
|
3545
3454
|
}
|
|
3546
3455
|
];
|
|
3547
|
-
t[l] =
|
|
3548
|
-
const u = "Datetime formats info",
|
|
3456
|
+
t[l] = i;
|
|
3457
|
+
const u = "Datetime formats info", f = [
|
|
3549
3458
|
{
|
|
3550
3459
|
type: u,
|
|
3551
3460
|
key: "numberFormats",
|
|
@@ -3553,14 +3462,14 @@ function Sl(e) {
|
|
|
3553
3462
|
value: e.numberFormats.value
|
|
3554
3463
|
}
|
|
3555
3464
|
];
|
|
3556
|
-
t[u] =
|
|
3465
|
+
t[u] = f;
|
|
3557
3466
|
}
|
|
3558
3467
|
return t;
|
|
3559
3468
|
}
|
|
3560
|
-
function
|
|
3561
|
-
if (
|
|
3469
|
+
function ct(e, t) {
|
|
3470
|
+
if (xt) {
|
|
3562
3471
|
let n;
|
|
3563
|
-
t && "groupId" in t && (n = t.groupId, delete t.groupId),
|
|
3472
|
+
t && "groupId" in t && (n = t.groupId, delete t.groupId), xt.addTimelineEvent({
|
|
3564
3473
|
layerId: "vue-i18n-timeline",
|
|
3565
3474
|
event: {
|
|
3566
3475
|
title: e,
|
|
@@ -3573,34 +3482,34 @@ function mt(e, t) {
|
|
|
3573
3482
|
});
|
|
3574
3483
|
}
|
|
3575
3484
|
}
|
|
3576
|
-
function
|
|
3577
|
-
const n =
|
|
3485
|
+
function ll(e, t) {
|
|
3486
|
+
const n = Ar(e.nodeId, t);
|
|
3578
3487
|
if (n) {
|
|
3579
3488
|
const [a] = e.path;
|
|
3580
|
-
a === "locale" &&
|
|
3489
|
+
a === "locale" && A(e.state.value) ? n.locale.value = e.state.value : a === "fallbackLocale" && (A(e.state.value) || X(e.state.value) || $(e.state.value)) ? n.fallbackLocale.value = e.state.value : a === "inheritLocale" && U(e.state.value) && (n.inheritLocale = e.state.value);
|
|
3581
3490
|
}
|
|
3582
3491
|
}
|
|
3583
|
-
function
|
|
3492
|
+
function ol(e, t, n) {
|
|
3584
3493
|
return {
|
|
3585
3494
|
beforeCreate() {
|
|
3586
|
-
const a =
|
|
3495
|
+
const a = st();
|
|
3587
3496
|
if (!a)
|
|
3588
|
-
throw
|
|
3497
|
+
throw Z(V.UNEXPECTED_ERROR);
|
|
3589
3498
|
const s = this.$options;
|
|
3590
3499
|
if (s.i18n) {
|
|
3591
3500
|
const r = s.i18n;
|
|
3592
3501
|
if (s.__i18n && (r.__i18n = s.__i18n), r.__root = t, this === this.$root)
|
|
3593
|
-
this.$i18n =
|
|
3502
|
+
this.$i18n = Un(e, r);
|
|
3594
3503
|
else {
|
|
3595
|
-
r.__injectWithOption = !0, r.__extender = n.__vueI18nExtend, this.$i18n =
|
|
3504
|
+
r.__injectWithOption = !0, r.__extender = n.__vueI18nExtend, this.$i18n = Gt(r);
|
|
3596
3505
|
const l = this.$i18n;
|
|
3597
3506
|
l.__extender && (l.__disposer = l.__extender(this.$i18n));
|
|
3598
3507
|
}
|
|
3599
3508
|
} else if (s.__i18n)
|
|
3600
3509
|
if (this === this.$root)
|
|
3601
|
-
this.$i18n =
|
|
3510
|
+
this.$i18n = Un(e, s);
|
|
3602
3511
|
else {
|
|
3603
|
-
this.$i18n =
|
|
3512
|
+
this.$i18n = Gt({
|
|
3604
3513
|
__i18n: s.__i18n,
|
|
3605
3514
|
__injectWithOption: !0,
|
|
3606
3515
|
__extender: n.__vueI18nExtend,
|
|
@@ -3611,42 +3520,42 @@ function Rl(e, t, n) {
|
|
|
3611
3520
|
}
|
|
3612
3521
|
else
|
|
3613
3522
|
this.$i18n = e;
|
|
3614
|
-
s.__i18nGlobal &&
|
|
3523
|
+
s.__i18nGlobal && Lr(t, s, s), this.$t = (...r) => this.$i18n.t(...r), this.$rt = (...r) => this.$i18n.rt(...r), this.$tc = (...r) => this.$i18n.tc(...r), this.$te = (r, l) => this.$i18n.te(r, l), this.$d = (...r) => this.$i18n.d(...r), this.$n = (...r) => this.$i18n.n(...r), this.$tm = (r) => this.$i18n.tm(r), n.__setInstance(a, this.$i18n);
|
|
3615
3524
|
},
|
|
3616
3525
|
mounted() {
|
|
3617
3526
|
if (process.env.NODE_ENV !== "production" && this.$el && this.$i18n) {
|
|
3618
3527
|
const a = this.$i18n;
|
|
3619
3528
|
this.$el.__VUE_I18N__ = a.__composer;
|
|
3620
|
-
const s = this.__v_emitter =
|
|
3621
|
-
a.__enableEmitter && a.__enableEmitter(s), s.on("*",
|
|
3529
|
+
const s = this.__v_emitter = Yt();
|
|
3530
|
+
a.__enableEmitter && a.__enableEmitter(s), s.on("*", ct);
|
|
3622
3531
|
}
|
|
3623
3532
|
},
|
|
3624
3533
|
unmounted() {
|
|
3625
|
-
const a =
|
|
3534
|
+
const a = st();
|
|
3626
3535
|
if (!a)
|
|
3627
|
-
throw
|
|
3536
|
+
throw Z(V.UNEXPECTED_ERROR);
|
|
3628
3537
|
const s = this.$i18n;
|
|
3629
|
-
process.env.NODE_ENV !== "production" && this.$el && this.$el.__VUE_I18N__ && (this.__v_emitter && (this.__v_emitter.off("*",
|
|
3538
|
+
process.env.NODE_ENV !== "production" && this.$el && this.$el.__VUE_I18N__ && (this.__v_emitter && (this.__v_emitter.off("*", ct), delete this.__v_emitter), this.$i18n && (s.__disableEmitter && s.__disableEmitter(), delete this.$el.__VUE_I18N__)), delete this.$t, delete this.$rt, delete this.$tc, delete this.$te, delete this.$d, delete this.$n, delete this.$tm, s.__disposer && (s.__disposer(), delete s.__disposer, delete s.__extender), n.__deleteInstance(a), delete this.$i18n;
|
|
3630
3539
|
}
|
|
3631
3540
|
};
|
|
3632
3541
|
}
|
|
3633
|
-
function
|
|
3634
|
-
e.locale = t.locale || e.locale, e.fallbackLocale = t.fallbackLocale || e.fallbackLocale, e.missing = t.missing || e.missing, e.silentTranslationWarn = t.silentTranslationWarn || e.silentFallbackWarn, e.silentFallbackWarn = t.silentFallbackWarn || e.silentFallbackWarn, e.formatFallbackMessages = t.formatFallbackMessages || e.formatFallbackMessages, e.postTranslation = t.postTranslation || e.postTranslation, e.warnHtmlInMessage = t.warnHtmlInMessage || e.warnHtmlInMessage, e.escapeParameterHtml = t.escapeParameterHtml || e.escapeParameterHtml, e.sync = t.sync || e.sync, e.__composer[
|
|
3635
|
-
const n =
|
|
3542
|
+
function Un(e, t) {
|
|
3543
|
+
e.locale = t.locale || e.locale, e.fallbackLocale = t.fallbackLocale || e.fallbackLocale, e.missing = t.missing || e.missing, e.silentTranslationWarn = t.silentTranslationWarn || e.silentFallbackWarn, e.silentFallbackWarn = t.silentFallbackWarn || e.silentFallbackWarn, e.formatFallbackMessages = t.formatFallbackMessages || e.formatFallbackMessages, e.postTranslation = t.postTranslation || e.postTranslation, e.warnHtmlInMessage = t.warnHtmlInMessage || e.warnHtmlInMessage, e.escapeParameterHtml = t.escapeParameterHtml || e.escapeParameterHtml, e.sync = t.sync || e.sync, e.__composer[pr](t.pluralizationRules || e.pluralizationRules);
|
|
3544
|
+
const n = ht(e.locale, {
|
|
3636
3545
|
messages: t.messages,
|
|
3637
3546
|
__i18n: t.__i18n
|
|
3638
3547
|
});
|
|
3639
3548
|
return Object.keys(n).forEach((a) => e.mergeLocaleMessage(a, n[a])), t.datetimeFormats && Object.keys(t.datetimeFormats).forEach((a) => e.mergeDateTimeFormat(a, t.datetimeFormats[a])), t.numberFormats && Object.keys(t.numberFormats).forEach((a) => e.mergeNumberFormat(a, t.numberFormats[a])), e;
|
|
3640
3549
|
}
|
|
3641
|
-
const
|
|
3642
|
-
function
|
|
3643
|
-
const n = __VUE_I18N_LEGACY_API__ && U(e.legacy) ? e.legacy : __VUE_I18N_LEGACY_API__, a = U(e.globalInjection) ? e.globalInjection : !0, s = __VUE_I18N_LEGACY_API__ && n ? !!e.allowComposition : !0, r = /* @__PURE__ */ new Map(), [l,
|
|
3644
|
-
process.env.NODE_ENV !== "production" && n && s &&
|
|
3645
|
-
function
|
|
3550
|
+
const il = /* @__PURE__ */ Ee("global-vue-i18n");
|
|
3551
|
+
function cl(e = {}, t) {
|
|
3552
|
+
const n = __VUE_I18N_LEGACY_API__ && U(e.legacy) ? e.legacy : __VUE_I18N_LEGACY_API__, a = U(e.globalInjection) ? e.globalInjection : !0, s = __VUE_I18N_LEGACY_API__ && n ? !!e.allowComposition : !0, r = /* @__PURE__ */ new Map(), [l, i] = ul(e, n), u = /* @__PURE__ */ Ee(process.env.NODE_ENV !== "production" ? "vue-i18n" : "");
|
|
3553
|
+
process.env.NODE_ENV !== "production" && n && s && q(se(K.NOTICE_DROP_ALLOW_COMPOSITION));
|
|
3554
|
+
function f(d) {
|
|
3646
3555
|
return r.get(d) || null;
|
|
3647
3556
|
}
|
|
3648
|
-
function p(d,
|
|
3649
|
-
r.set(d,
|
|
3557
|
+
function p(d, h) {
|
|
3558
|
+
r.set(d, h);
|
|
3650
3559
|
}
|
|
3651
3560
|
function T(d) {
|
|
3652
3561
|
r.delete(d);
|
|
@@ -3662,33 +3571,33 @@ function yl(e = {}, t) {
|
|
|
3662
3571
|
return s;
|
|
3663
3572
|
},
|
|
3664
3573
|
// install plugin
|
|
3665
|
-
async install(
|
|
3666
|
-
if (process.env.NODE_ENV !== "production" && (
|
|
3574
|
+
async install(h, ...D) {
|
|
3575
|
+
if (process.env.NODE_ENV !== "production" && (h.__VUE_I18N__ = d), h.__VUE_I18N_SYMBOL__ = u, h.provide(h.__VUE_I18N_SYMBOL__, d), F(D[0])) {
|
|
3667
3576
|
const y = D[0];
|
|
3668
3577
|
d.__composerExtend = y.__composerExtend, d.__vueI18nExtend = y.__vueI18nExtend;
|
|
3669
3578
|
}
|
|
3670
|
-
let
|
|
3671
|
-
!n && a && (
|
|
3672
|
-
const
|
|
3673
|
-
if (
|
|
3674
|
-
|
|
3579
|
+
let S = null;
|
|
3580
|
+
!n && a && (S = Tl(h, d.global)), __VUE_I18N_FULL_INSTALL__ && js(h, d, ...D), __VUE_I18N_LEGACY_API__ && n && h.mixin(ol(i, i.__composer, d));
|
|
3581
|
+
const P = h.unmount;
|
|
3582
|
+
if (h.unmount = () => {
|
|
3583
|
+
S && S(), d.dispose(), P();
|
|
3675
3584
|
}, process.env.NODE_ENV !== "production") {
|
|
3676
|
-
if (!await
|
|
3677
|
-
throw
|
|
3678
|
-
const R =
|
|
3585
|
+
if (!await Qs(h, d))
|
|
3586
|
+
throw Z(V.CANNOT_SETUP_VUE_DEVTOOLS_PLUGIN);
|
|
3587
|
+
const R = Yt();
|
|
3679
3588
|
if (n) {
|
|
3680
|
-
const
|
|
3681
|
-
|
|
3589
|
+
const _ = i;
|
|
3590
|
+
_.__enableEmitter && _.__enableEmitter(R);
|
|
3682
3591
|
} else {
|
|
3683
|
-
const
|
|
3684
|
-
|
|
3592
|
+
const _ = i;
|
|
3593
|
+
_[Re] && _[Re](R);
|
|
3685
3594
|
}
|
|
3686
|
-
R.on("*",
|
|
3595
|
+
R.on("*", ct);
|
|
3687
3596
|
}
|
|
3688
3597
|
},
|
|
3689
3598
|
// global accessor
|
|
3690
3599
|
get global() {
|
|
3691
|
-
return
|
|
3600
|
+
return i;
|
|
3692
3601
|
},
|
|
3693
3602
|
dispose() {
|
|
3694
3603
|
l.stop();
|
|
@@ -3696,7 +3605,7 @@ function yl(e = {}, t) {
|
|
|
3696
3605
|
// @internal
|
|
3697
3606
|
__instances: r,
|
|
3698
3607
|
// @internal
|
|
3699
|
-
__getInstance:
|
|
3608
|
+
__getInstance: f,
|
|
3700
3609
|
// @internal
|
|
3701
3610
|
__setInstance: p,
|
|
3702
3611
|
// @internal
|
|
@@ -3705,66 +3614,66 @@ function yl(e = {}, t) {
|
|
|
3705
3614
|
return d;
|
|
3706
3615
|
}
|
|
3707
3616
|
}
|
|
3708
|
-
function
|
|
3709
|
-
const t =
|
|
3617
|
+
function qt(e = {}) {
|
|
3618
|
+
const t = st();
|
|
3710
3619
|
if (t == null)
|
|
3711
|
-
throw
|
|
3620
|
+
throw Z(V.MUST_BE_CALL_SETUP_TOP);
|
|
3712
3621
|
if (!t.isCE && t.appContext.app != null && !t.appContext.app.__VUE_I18N_SYMBOL__)
|
|
3713
|
-
throw
|
|
3714
|
-
const n =
|
|
3622
|
+
throw Z(V.NOT_INSTALLED);
|
|
3623
|
+
const n = _l(t), a = ml(n), s = Or(t), r = fl(e, s);
|
|
3715
3624
|
if (__VUE_I18N_LEGACY_API__ && n.mode === "legacy" && !e.__useComponent) {
|
|
3716
3625
|
if (!n.allowComposition)
|
|
3717
|
-
throw
|
|
3718
|
-
return
|
|
3626
|
+
throw Z(V.NOT_AVAILABLE_IN_LEGACY_MODE);
|
|
3627
|
+
return Nl(t, r, a, e);
|
|
3719
3628
|
}
|
|
3720
3629
|
if (r === "global")
|
|
3721
|
-
return
|
|
3630
|
+
return Lr(a, e, s), a;
|
|
3722
3631
|
if (r === "parent") {
|
|
3723
|
-
let u =
|
|
3724
|
-
return u == null && (process.env.NODE_ENV !== "production" &&
|
|
3632
|
+
let u = dl(n, t, e.__useComponent);
|
|
3633
|
+
return u == null && (process.env.NODE_ENV !== "production" && q(se(K.NOT_FOUND_PARENT_SCOPE)), u = a), u;
|
|
3725
3634
|
}
|
|
3726
3635
|
const l = n;
|
|
3727
|
-
let
|
|
3728
|
-
if (
|
|
3729
|
-
const u =
|
|
3730
|
-
"__i18n" in s && (u.__i18n = s.__i18n), a && (u.__root = a),
|
|
3636
|
+
let i = l.__getInstance(t);
|
|
3637
|
+
if (i == null) {
|
|
3638
|
+
const u = ee({}, e);
|
|
3639
|
+
"__i18n" in s && (u.__i18n = s.__i18n), a && (u.__root = a), i = Kt(u), l.__composerExtend && (i[Wt] = l.__composerExtend(i)), gl(l, t, i), l.__setInstance(t, i);
|
|
3731
3640
|
}
|
|
3732
|
-
return
|
|
3641
|
+
return i;
|
|
3733
3642
|
}
|
|
3734
|
-
function
|
|
3735
|
-
const a =
|
|
3643
|
+
function ul(e, t, n) {
|
|
3644
|
+
const a = Pr();
|
|
3736
3645
|
{
|
|
3737
|
-
const s = __VUE_I18N_LEGACY_API__ && t ? a.run(() =>
|
|
3646
|
+
const s = __VUE_I18N_LEGACY_API__ && t ? a.run(() => Gt(e)) : a.run(() => Kt(e));
|
|
3738
3647
|
if (s == null)
|
|
3739
|
-
throw
|
|
3648
|
+
throw Z(V.UNEXPECTED_ERROR);
|
|
3740
3649
|
return [a, s];
|
|
3741
3650
|
}
|
|
3742
3651
|
}
|
|
3743
|
-
function
|
|
3652
|
+
function _l(e) {
|
|
3744
3653
|
{
|
|
3745
|
-
const t =
|
|
3654
|
+
const t = Rr(e.isCE ? il : e.appContext.app.__VUE_I18N_SYMBOL__);
|
|
3746
3655
|
if (!t)
|
|
3747
|
-
throw
|
|
3656
|
+
throw Z(e.isCE ? V.NOT_INSTALLED_WITH_PROVIDE : V.UNEXPECTED_ERROR);
|
|
3748
3657
|
return t;
|
|
3749
3658
|
}
|
|
3750
3659
|
}
|
|
3751
|
-
function
|
|
3752
|
-
return
|
|
3660
|
+
function fl(e, t) {
|
|
3661
|
+
return Ot(e) ? "__i18n" in t ? "local" : "global" : e.useScope ? e.useScope : "local";
|
|
3753
3662
|
}
|
|
3754
|
-
function
|
|
3663
|
+
function ml(e) {
|
|
3755
3664
|
return e.mode === "composition" ? e.global : e.global.__composer;
|
|
3756
3665
|
}
|
|
3757
|
-
function
|
|
3666
|
+
function dl(e, t, n = !1) {
|
|
3758
3667
|
let a = null;
|
|
3759
3668
|
const s = t.root;
|
|
3760
|
-
let r =
|
|
3669
|
+
let r = El(t, n);
|
|
3761
3670
|
for (; r != null; ) {
|
|
3762
3671
|
const l = e;
|
|
3763
3672
|
if (e.mode === "composition")
|
|
3764
3673
|
a = l.__getInstance(r);
|
|
3765
3674
|
else if (__VUE_I18N_LEGACY_API__) {
|
|
3766
|
-
const
|
|
3767
|
-
|
|
3675
|
+
const i = l.__getInstance(r);
|
|
3676
|
+
i != null && (a = i.__composer, n && a && !a[Tr] && (a = null));
|
|
3768
3677
|
}
|
|
3769
3678
|
if (a != null || s === r)
|
|
3770
3679
|
break;
|
|
@@ -3772,124 +3681,124 @@ function Vl(e, t, n = !1) {
|
|
|
3772
3681
|
}
|
|
3773
3682
|
return a;
|
|
3774
3683
|
}
|
|
3775
|
-
function
|
|
3684
|
+
function El(e, t = !1) {
|
|
3776
3685
|
return e == null ? null : t && e.vnode.ctx || e.parent;
|
|
3777
3686
|
}
|
|
3778
|
-
function
|
|
3687
|
+
function gl(e, t, n) {
|
|
3779
3688
|
let a = null;
|
|
3780
|
-
|
|
3689
|
+
yr(() => {
|
|
3781
3690
|
if (process.env.NODE_ENV !== "production" && t.vnode.el) {
|
|
3782
|
-
t.vnode.el.__VUE_I18N__ = n, a =
|
|
3691
|
+
t.vnode.el.__VUE_I18N__ = n, a = Yt();
|
|
3783
3692
|
const s = n;
|
|
3784
|
-
s[
|
|
3693
|
+
s[Re] && s[Re](a), a.on("*", ct);
|
|
3785
3694
|
}
|
|
3786
|
-
}, t),
|
|
3695
|
+
}, t), Mr(() => {
|
|
3787
3696
|
const s = n;
|
|
3788
|
-
process.env.NODE_ENV !== "production" && t.vnode.el && t.vnode.el.__VUE_I18N__ && (a && a.off("*",
|
|
3789
|
-
const r = s[
|
|
3790
|
-
r && (r(), delete s[
|
|
3697
|
+
process.env.NODE_ENV !== "production" && t.vnode.el && t.vnode.el.__VUE_I18N__ && (a && a.off("*", ct), s[ot] && s[ot](), delete t.vnode.el.__VUE_I18N__), e.__deleteInstance(t);
|
|
3698
|
+
const r = s[Wt];
|
|
3699
|
+
r && (r(), delete s[Wt]);
|
|
3791
3700
|
}, t);
|
|
3792
3701
|
}
|
|
3793
|
-
function
|
|
3794
|
-
const s = t === "local", r =
|
|
3702
|
+
function Nl(e, t, n, a = {}) {
|
|
3703
|
+
const s = t === "local", r = Wn(null);
|
|
3795
3704
|
if (s && e.proxy && !(e.proxy.$options.i18n || e.proxy.$options.__i18n))
|
|
3796
|
-
throw
|
|
3797
|
-
const l = U(a.inheritLocale) ? a.inheritLocale : !
|
|
3705
|
+
throw Z(V.MUST_DEFINE_I18N_OPTION_IN_ALLOW_COMPOSITION);
|
|
3706
|
+
const l = U(a.inheritLocale) ? a.inheritLocale : !A(a.locale), i = Se(
|
|
3798
3707
|
// prettier-ignore
|
|
3799
|
-
!s || l ? n.locale.value :
|
|
3800
|
-
), u =
|
|
3708
|
+
!s || l ? n.locale.value : A(a.locale) ? a.locale : We
|
|
3709
|
+
), u = Se(
|
|
3801
3710
|
// prettier-ignore
|
|
3802
|
-
!s || l ? n.fallbackLocale.value :
|
|
3803
|
-
),
|
|
3711
|
+
!s || l ? n.fallbackLocale.value : A(a.fallbackLocale) || X(a.fallbackLocale) || F(a.fallbackLocale) || a.fallbackLocale === !1 ? a.fallbackLocale : i.value
|
|
3712
|
+
), f = Se(ht(i.value, a)), p = Se(F(a.datetimeFormats) ? a.datetimeFormats : { [i.value]: {} }), T = Se(F(a.numberFormats) ? a.numberFormats : { [i.value]: {} }), d = s ? n.missingWarn : U(a.missingWarn) || Le(a.missingWarn) ? a.missingWarn : !0, h = s ? n.fallbackWarn : U(a.fallbackWarn) || Le(a.fallbackWarn) ? a.fallbackWarn : !0, D = s ? n.fallbackRoot : U(a.fallbackRoot) ? a.fallbackRoot : !0, S = !!a.fallbackFormat, P = H(a.missing) ? a.missing : null, y = H(a.postTranslation) ? a.postTranslation : null, R = s ? n.warnHtmlMessage : U(a.warnHtmlMessage) ? a.warnHtmlMessage : !0, _ = !!a.escapeParameter, E = s ? n.modifiers : F(a.modifiers) ? a.modifiers : {}, L = a.pluralRules || s && n.pluralRules;
|
|
3804
3713
|
function g() {
|
|
3805
3714
|
return [
|
|
3806
|
-
|
|
3715
|
+
i.value,
|
|
3807
3716
|
u.value,
|
|
3808
|
-
|
|
3717
|
+
f.value,
|
|
3809
3718
|
p.value,
|
|
3810
3719
|
T.value
|
|
3811
3720
|
];
|
|
3812
3721
|
}
|
|
3813
|
-
const v =
|
|
3814
|
-
get: () => r.value ? r.value.locale.value :
|
|
3722
|
+
const v = me({
|
|
3723
|
+
get: () => r.value ? r.value.locale.value : i.value,
|
|
3815
3724
|
set: (b) => {
|
|
3816
|
-
r.value && (r.value.locale.value = b),
|
|
3725
|
+
r.value && (r.value.locale.value = b), i.value = b;
|
|
3817
3726
|
}
|
|
3818
|
-
}), C =
|
|
3727
|
+
}), C = me({
|
|
3819
3728
|
get: () => r.value ? r.value.fallbackLocale.value : u.value,
|
|
3820
3729
|
set: (b) => {
|
|
3821
3730
|
r.value && (r.value.fallbackLocale.value = b), u.value = b;
|
|
3822
3731
|
}
|
|
3823
|
-
}), I =
|
|
3732
|
+
}), I = me(() => r.value ? r.value.messages.value : f.value), B = me(() => p.value), le = me(() => T.value);
|
|
3824
3733
|
function w() {
|
|
3825
3734
|
return r.value ? r.value.getPostTranslationHandler() : y;
|
|
3826
3735
|
}
|
|
3827
|
-
function
|
|
3736
|
+
function te(b) {
|
|
3828
3737
|
r.value && r.value.setPostTranslationHandler(b);
|
|
3829
3738
|
}
|
|
3830
|
-
function
|
|
3831
|
-
return r.value ? r.value.getMissingHandler() :
|
|
3739
|
+
function xe() {
|
|
3740
|
+
return r.value ? r.value.getMissingHandler() : P;
|
|
3832
3741
|
}
|
|
3833
|
-
function
|
|
3742
|
+
function He(b) {
|
|
3834
3743
|
r.value && r.value.setMissingHandler(b);
|
|
3835
3744
|
}
|
|
3836
|
-
function
|
|
3745
|
+
function fe(b) {
|
|
3837
3746
|
return g(), b();
|
|
3838
3747
|
}
|
|
3839
|
-
function
|
|
3840
|
-
return r.value ?
|
|
3748
|
+
function Ye(...b) {
|
|
3749
|
+
return r.value ? fe(() => Reflect.apply(r.value.t, null, [...b])) : fe(() => "");
|
|
3841
3750
|
}
|
|
3842
|
-
function
|
|
3751
|
+
function Be(...b) {
|
|
3843
3752
|
return r.value ? Reflect.apply(r.value.rt, null, [...b]) : "";
|
|
3844
3753
|
}
|
|
3845
|
-
function
|
|
3846
|
-
return r.value ?
|
|
3754
|
+
function Xe(...b) {
|
|
3755
|
+
return r.value ? fe(() => Reflect.apply(r.value.d, null, [...b])) : fe(() => "");
|
|
3847
3756
|
}
|
|
3848
|
-
function
|
|
3849
|
-
return r.value ?
|
|
3757
|
+
function je(...b) {
|
|
3758
|
+
return r.value ? fe(() => Reflect.apply(r.value.n, null, [...b])) : fe(() => "");
|
|
3850
3759
|
}
|
|
3851
|
-
function
|
|
3760
|
+
function Ke(b) {
|
|
3852
3761
|
return r.value ? r.value.tm(b) : {};
|
|
3853
3762
|
}
|
|
3854
|
-
function
|
|
3763
|
+
function ie(b, W) {
|
|
3855
3764
|
return r.value ? r.value.te(b, W) : !1;
|
|
3856
3765
|
}
|
|
3857
|
-
function
|
|
3766
|
+
function ke(b) {
|
|
3858
3767
|
return r.value ? r.value.getLocaleMessage(b) : {};
|
|
3859
3768
|
}
|
|
3860
|
-
function
|
|
3861
|
-
r.value && (r.value.setLocaleMessage(b, W),
|
|
3769
|
+
function ye(b, W) {
|
|
3770
|
+
r.value && (r.value.setLocaleMessage(b, W), f.value[b] = W);
|
|
3862
3771
|
}
|
|
3863
|
-
function
|
|
3772
|
+
function Je(b, W) {
|
|
3864
3773
|
r.value && r.value.mergeLocaleMessage(b, W);
|
|
3865
3774
|
}
|
|
3866
|
-
function
|
|
3775
|
+
function Qe(b) {
|
|
3867
3776
|
return r.value ? r.value.getDateTimeFormat(b) : {};
|
|
3868
3777
|
}
|
|
3869
|
-
function
|
|
3778
|
+
function qe(b, W) {
|
|
3870
3779
|
r.value && (r.value.setDateTimeFormat(b, W), p.value[b] = W);
|
|
3871
3780
|
}
|
|
3872
|
-
function
|
|
3781
|
+
function _t(b, W) {
|
|
3873
3782
|
r.value && r.value.mergeDateTimeFormat(b, W);
|
|
3874
3783
|
}
|
|
3875
|
-
function
|
|
3784
|
+
function Ze(b) {
|
|
3876
3785
|
return r.value ? r.value.getNumberFormat(b) : {};
|
|
3877
3786
|
}
|
|
3878
|
-
function
|
|
3787
|
+
function Me(b, W) {
|
|
3879
3788
|
r.value && (r.value.setNumberFormat(b, W), T.value[b] = W);
|
|
3880
3789
|
}
|
|
3881
|
-
function
|
|
3790
|
+
function ze(b, W) {
|
|
3882
3791
|
r.value && r.value.mergeNumberFormat(b, W);
|
|
3883
3792
|
}
|
|
3884
|
-
const
|
|
3793
|
+
const et = {
|
|
3885
3794
|
get id() {
|
|
3886
3795
|
return r.value ? r.value.id : -1;
|
|
3887
3796
|
},
|
|
3888
3797
|
locale: v,
|
|
3889
3798
|
fallbackLocale: C,
|
|
3890
3799
|
messages: I,
|
|
3891
|
-
datetimeFormats:
|
|
3892
|
-
numberFormats:
|
|
3800
|
+
datetimeFormats: B,
|
|
3801
|
+
numberFormats: le,
|
|
3893
3802
|
get inheritLocale() {
|
|
3894
3803
|
return r.value ? r.value.inheritLocale : l;
|
|
3895
3804
|
},
|
|
@@ -3897,7 +3806,7 @@ function Gl(e, t, n, a = {}) {
|
|
|
3897
3806
|
r.value && (r.value.inheritLocale = b);
|
|
3898
3807
|
},
|
|
3899
3808
|
get availableLocales() {
|
|
3900
|
-
return r.value ? r.value.availableLocales : Object.keys(
|
|
3809
|
+
return r.value ? r.value.availableLocales : Object.keys(f.value);
|
|
3901
3810
|
},
|
|
3902
3811
|
get modifiers() {
|
|
3903
3812
|
return r.value ? r.value.modifiers : E;
|
|
@@ -3915,7 +3824,7 @@ function Gl(e, t, n, a = {}) {
|
|
|
3915
3824
|
r.value && (r.value.missingWarn = b);
|
|
3916
3825
|
},
|
|
3917
3826
|
get fallbackWarn() {
|
|
3918
|
-
return r.value ? r.value.fallbackWarn :
|
|
3827
|
+
return r.value ? r.value.fallbackWarn : h;
|
|
3919
3828
|
},
|
|
3920
3829
|
set fallbackWarn(b) {
|
|
3921
3830
|
r.value && (r.value.missingWarn = b);
|
|
@@ -3927,7 +3836,7 @@ function Gl(e, t, n, a = {}) {
|
|
|
3927
3836
|
r.value && (r.value.fallbackRoot = b);
|
|
3928
3837
|
},
|
|
3929
3838
|
get fallbackFormat() {
|
|
3930
|
-
return r.value ? r.value.fallbackFormat :
|
|
3839
|
+
return r.value ? r.value.fallbackFormat : S;
|
|
3931
3840
|
},
|
|
3932
3841
|
set fallbackFormat(b) {
|
|
3933
3842
|
r.value && (r.value.fallbackFormat = b);
|
|
@@ -3939,65 +3848,65 @@ function Gl(e, t, n, a = {}) {
|
|
|
3939
3848
|
r.value && (r.value.warnHtmlMessage = b);
|
|
3940
3849
|
},
|
|
3941
3850
|
get escapeParameter() {
|
|
3942
|
-
return r.value ? r.value.escapeParameter :
|
|
3851
|
+
return r.value ? r.value.escapeParameter : _;
|
|
3943
3852
|
},
|
|
3944
3853
|
set escapeParameter(b) {
|
|
3945
3854
|
r.value && (r.value.escapeParameter = b);
|
|
3946
3855
|
},
|
|
3947
|
-
t:
|
|
3856
|
+
t: Ye,
|
|
3948
3857
|
getPostTranslationHandler: w,
|
|
3949
|
-
setPostTranslationHandler:
|
|
3950
|
-
getMissingHandler:
|
|
3951
|
-
setMissingHandler:
|
|
3952
|
-
rt:
|
|
3953
|
-
d:
|
|
3954
|
-
n:
|
|
3955
|
-
tm:
|
|
3956
|
-
te:
|
|
3957
|
-
getLocaleMessage:
|
|
3958
|
-
setLocaleMessage:
|
|
3959
|
-
mergeLocaleMessage:
|
|
3960
|
-
getDateTimeFormat:
|
|
3961
|
-
setDateTimeFormat:
|
|
3962
|
-
mergeDateTimeFormat:
|
|
3963
|
-
getNumberFormat:
|
|
3964
|
-
setNumberFormat:
|
|
3965
|
-
mergeNumberFormat:
|
|
3858
|
+
setPostTranslationHandler: te,
|
|
3859
|
+
getMissingHandler: xe,
|
|
3860
|
+
setMissingHandler: He,
|
|
3861
|
+
rt: Be,
|
|
3862
|
+
d: Xe,
|
|
3863
|
+
n: je,
|
|
3864
|
+
tm: Ke,
|
|
3865
|
+
te: ie,
|
|
3866
|
+
getLocaleMessage: ke,
|
|
3867
|
+
setLocaleMessage: ye,
|
|
3868
|
+
mergeLocaleMessage: Je,
|
|
3869
|
+
getDateTimeFormat: Qe,
|
|
3870
|
+
setDateTimeFormat: qe,
|
|
3871
|
+
mergeDateTimeFormat: _t,
|
|
3872
|
+
getNumberFormat: Ze,
|
|
3873
|
+
setNumberFormat: Me,
|
|
3874
|
+
mergeNumberFormat: ze
|
|
3966
3875
|
};
|
|
3967
|
-
function
|
|
3968
|
-
b.locale.value =
|
|
3969
|
-
b.mergeLocaleMessage(W,
|
|
3876
|
+
function tt(b) {
|
|
3877
|
+
b.locale.value = i.value, b.fallbackLocale.value = u.value, Object.keys(f.value).forEach((W) => {
|
|
3878
|
+
b.mergeLocaleMessage(W, f.value[W]);
|
|
3970
3879
|
}), Object.keys(p.value).forEach((W) => {
|
|
3971
3880
|
b.mergeDateTimeFormat(W, p.value[W]);
|
|
3972
3881
|
}), Object.keys(T.value).forEach((W) => {
|
|
3973
3882
|
b.mergeNumberFormat(W, T.value[W]);
|
|
3974
|
-
}), b.escapeParameter =
|
|
3883
|
+
}), b.escapeParameter = _, b.fallbackFormat = S, b.fallbackRoot = D, b.fallbackWarn = h, b.missingWarn = d, b.warnHtmlMessage = R;
|
|
3975
3884
|
}
|
|
3976
|
-
return
|
|
3885
|
+
return kr(() => {
|
|
3977
3886
|
if (e.proxy == null || e.proxy.$i18n == null)
|
|
3978
|
-
throw
|
|
3887
|
+
throw Z(V.NOT_AVAILABLE_COMPOSITION_IN_LEGACY);
|
|
3979
3888
|
const b = r.value = e.proxy.$i18n.__composer;
|
|
3980
|
-
t === "global" ? (
|
|
3981
|
-
}),
|
|
3889
|
+
t === "global" ? (i.value = b.locale.value, u.value = b.fallbackLocale.value, f.value = b.messages.value, p.value = b.datetimeFormats.value, T.value = b.numberFormats.value) : s && tt(b);
|
|
3890
|
+
}), et;
|
|
3982
3891
|
}
|
|
3983
|
-
const
|
|
3892
|
+
const pl = [
|
|
3984
3893
|
"locale",
|
|
3985
3894
|
"fallbackLocale",
|
|
3986
3895
|
"availableLocales"
|
|
3987
|
-
],
|
|
3988
|
-
function
|
|
3896
|
+
], wn = ["t", "rt", "d", "n", "tm", "te"];
|
|
3897
|
+
function Tl(e, t) {
|
|
3989
3898
|
const n = /* @__PURE__ */ Object.create(null);
|
|
3990
|
-
return
|
|
3899
|
+
return pl.forEach((s) => {
|
|
3991
3900
|
const r = Object.getOwnPropertyDescriptor(t, s);
|
|
3992
3901
|
if (!r)
|
|
3993
|
-
throw
|
|
3994
|
-
const l =
|
|
3902
|
+
throw Z(V.UNEXPECTED_ERROR);
|
|
3903
|
+
const l = Dr(r.value) ? {
|
|
3995
3904
|
get() {
|
|
3996
3905
|
return r.value.value;
|
|
3997
3906
|
},
|
|
3998
3907
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
3999
|
-
set(
|
|
4000
|
-
r.value.value =
|
|
3908
|
+
set(i) {
|
|
3909
|
+
r.value.value = i;
|
|
4001
3910
|
}
|
|
4002
3911
|
} : {
|
|
4003
3912
|
get() {
|
|
@@ -4005,27 +3914,27 @@ function xl(e, t) {
|
|
|
4005
3914
|
}
|
|
4006
3915
|
};
|
|
4007
3916
|
Object.defineProperty(n, s, l);
|
|
4008
|
-
}), e.config.globalProperties.$i18n = n,
|
|
3917
|
+
}), e.config.globalProperties.$i18n = n, wn.forEach((s) => {
|
|
4009
3918
|
const r = Object.getOwnPropertyDescriptor(t, s);
|
|
4010
3919
|
if (!r || !r.value)
|
|
4011
|
-
throw
|
|
3920
|
+
throw Z(V.UNEXPECTED_ERROR);
|
|
4012
3921
|
Object.defineProperty(e.config.globalProperties, `$${s}`, r);
|
|
4013
3922
|
}), () => {
|
|
4014
|
-
delete e.config.globalProperties.$i18n,
|
|
3923
|
+
delete e.config.globalProperties.$i18n, wn.forEach((s) => {
|
|
4015
3924
|
delete e.config.globalProperties[`$${s}`];
|
|
4016
3925
|
});
|
|
4017
3926
|
};
|
|
4018
3927
|
}
|
|
4019
|
-
|
|
4020
|
-
__INTLIFY_JIT_COMPILATION__ ?
|
|
4021
|
-
|
|
4022
|
-
|
|
3928
|
+
Ms();
|
|
3929
|
+
__INTLIFY_JIT_COMPILATION__ ? En(Ts) : En(ps);
|
|
3930
|
+
cs(Ha);
|
|
3931
|
+
us(Zn);
|
|
4023
3932
|
if (process.env.NODE_ENV !== "production" || __INTLIFY_PROD_DEVTOOLS__) {
|
|
4024
|
-
const e =
|
|
4025
|
-
e.__INTLIFY__ = !0,
|
|
3933
|
+
const e = pe();
|
|
3934
|
+
e.__INTLIFY__ = !0, Za(e.__INTLIFY_DEVTOOLS_GLOBAL_HOOK__);
|
|
4026
3935
|
}
|
|
4027
3936
|
process.env.NODE_ENV;
|
|
4028
|
-
const
|
|
3937
|
+
const Ol = {
|
|
4029
3938
|
simpleButton: {
|
|
4030
3939
|
clickMe: "点击我",
|
|
4031
3940
|
clicked: "已点击 {count} 次"
|
|
@@ -4034,7 +3943,7 @@ const Yl = {
|
|
|
4034
3943
|
title: "简单卡片",
|
|
4035
3944
|
content: "这是一个简单的卡片组件"
|
|
4036
3945
|
}
|
|
4037
|
-
},
|
|
3946
|
+
}, Ll = {
|
|
4038
3947
|
simpleButton: {
|
|
4039
3948
|
clickMe: "Click Me",
|
|
4040
3949
|
clicked: "Clicked {count} times"
|
|
@@ -4043,20 +3952,20 @@ const Yl = {
|
|
|
4043
3952
|
title: "Simple Card",
|
|
4044
3953
|
content: "This is a simple card component"
|
|
4045
3954
|
}
|
|
4046
|
-
},
|
|
4047
|
-
|
|
4048
|
-
|
|
4049
|
-
],
|
|
4050
|
-
|
|
3955
|
+
}, vl = [
|
|
3956
|
+
Wr,
|
|
3957
|
+
jr
|
|
3958
|
+
], Il = (e) => {
|
|
3959
|
+
vl.forEach((s) => {
|
|
4051
3960
|
e.use(s);
|
|
4052
3961
|
});
|
|
4053
|
-
const t =
|
|
3962
|
+
const t = cl({
|
|
4054
3963
|
legacy: !1,
|
|
4055
3964
|
locale: "zh_CN",
|
|
4056
3965
|
fallbackLocale: "zh_CN",
|
|
4057
3966
|
messages: {
|
|
4058
|
-
zh_CN:
|
|
4059
|
-
en_US:
|
|
3967
|
+
zh_CN: Ol,
|
|
3968
|
+
en_US: Ll
|
|
4060
3969
|
}
|
|
4061
3970
|
});
|
|
4062
3971
|
e.use(t), t.global.locale.value = "zh_CN", Object.assign(t, { switchLocale: (s) => {
|
|
@@ -4064,10 +3973,10 @@ const Yl = {
|
|
|
4064
3973
|
}, mergeLocaleMessage: (s, r) => {
|
|
4065
3974
|
t.global.mergeLocaleMessage(s, r);
|
|
4066
3975
|
} });
|
|
4067
|
-
},
|
|
3976
|
+
}, hl = { install: Il };
|
|
4068
3977
|
export {
|
|
4069
|
-
|
|
4070
|
-
|
|
4071
|
-
|
|
4072
|
-
|
|
3978
|
+
Wr as SimpleButton,
|
|
3979
|
+
jr as SimpleCard,
|
|
3980
|
+
hl as default,
|
|
3981
|
+
Il as install
|
|
4073
3982
|
};
|