gc_i18n 1.2.13 → 1.3.0
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/lang/index.js +2 -2
- package/lang/index.json +60 -0
- package/lib/gc_i18n.css +1 -1
- package/lib/gc_i18n.js +423 -416
- package/lib/gc_i18n.umd.cjs +10 -10
- package/package.json +3 -1
- package/packages/components/config.vue +7 -9
- package/packages/index.js +16 -4
- package/packages/libs/service.js +7 -2
- package/packages/libs/utils.js +10 -1
- package/src/view/Home.vue +12 -1
package/lib/gc_i18n.js
CHANGED
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
import './gc_i18n.css';
|
|
2
|
-
import
|
|
3
|
-
import _n, { Message as tt
|
|
2
|
+
import Va from "keyboardjs";
|
|
3
|
+
import _n, { Message as tt } from "view-ui-plus";
|
|
4
4
|
import "view-ui-plus/dist/styles/viewuiplus.css";
|
|
5
|
-
import { defineComponent as Xt, h as
|
|
5
|
+
import { defineComponent as Xt, h as zn, getCurrentInstance as Ye, effectScope as $a, inject as Wa, onMounted as xa, onUnmounted as Ga, Fragment as Jt, ref as Ka, shallowRef as Ha, computed as Ge, watch as Mt, isRef as Ya, createVNode as re, Text as Ba, resolveComponent as z, resolveDirective as ja, createBlock as _e, openBlock as se, withCtx as ne, createElementBlock as mn, createCommentVNode as dn, createElementVNode as Ne, withDirectives as Xa, createTextVNode as Ct, renderList as Ja, toDisplayString as gn, nextTick as Qa, createApp as qa } from "vue";
|
|
6
6
|
import $ from "lodash-es";
|
|
7
7
|
import it from "axios";
|
|
8
|
-
import
|
|
8
|
+
import ce from "store2";
|
|
9
9
|
import { jws as Za } from "jsrsasign";
|
|
10
10
|
/*!
|
|
11
11
|
* shared v11.1.3
|
|
12
12
|
* (c) 2025 kazuya kawaguchi
|
|
13
13
|
* Released under the MIT License.
|
|
14
14
|
*/
|
|
15
|
-
const
|
|
15
|
+
const fe = typeof window < "u";
|
|
16
16
|
let ae, Ae;
|
|
17
17
|
if (process.env.NODE_ENV !== "production") {
|
|
18
|
-
const e =
|
|
18
|
+
const e = fe && window.performance;
|
|
19
19
|
e && e.mark && e.measure && e.clearMarks && // @ts-ignore browser compat
|
|
20
20
|
e.clearMeasures && (ae = (t) => {
|
|
21
21
|
e.mark(t);
|
|
@@ -27,17 +27,17 @@ const za = /\{([0-9a-zA-Z]+)\}/g;
|
|
|
27
27
|
function ct(e, ...t) {
|
|
28
28
|
return t.length === 1 && M(t[0]) && (t = t[0]), (!t || !t.hasOwnProperty) && (t = {}), e.replace(za, (n, a) => t.hasOwnProperty(a) ? t[a] : "");
|
|
29
29
|
}
|
|
30
|
-
const
|
|
30
|
+
const ge = (e, t = !1) => t ? Symbol.for(e) : Symbol(e), es = (e, t, n) => ts({ l: e, k: t, s: n }), ts = (e) => JSON.stringify(e).replace(/\u2028/g, "\\u2028").replace(/\u2029/g, "\\u2029").replace(/\u0027/g, "\\u0027"), j = (e) => typeof e == "number" && isFinite(e), ns = (e) => Qt(e) === "[object Date]", Fe = (e) => Qt(e) === "[object RegExp]", ut = (e) => P(e) && Object.keys(e).length === 0, Q = Object.assign, as = Object.create, W = (e = null) => as(e);
|
|
31
31
|
let En;
|
|
32
32
|
const Se = () => En || (En = typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : typeof global < "u" ? global : W());
|
|
33
33
|
function pn(e) {
|
|
34
34
|
return e.replace(/</g, "<").replace(/>/g, ">").replace(/"/g, """).replace(/'/g, "'");
|
|
35
35
|
}
|
|
36
36
|
const ss = Object.prototype.hasOwnProperty;
|
|
37
|
-
function
|
|
37
|
+
function ue(e, t) {
|
|
38
38
|
return ss.call(e, t);
|
|
39
39
|
}
|
|
40
|
-
const B = Array.isArray, x = (e) => typeof e == "function", I = (e) => typeof e == "string", F = (e) => typeof e == "boolean", M = (e) => e !== null && typeof e == "object", rs = (e) => M(e) && x(e.then) && x(e.catch),
|
|
40
|
+
const B = Array.isArray, x = (e) => typeof e == "function", I = (e) => typeof e == "string", F = (e) => typeof e == "boolean", M = (e) => e !== null && typeof e == "object", rs = (e) => M(e) && x(e.then) && x(e.catch), ea = Object.prototype.toString, Qt = (e) => ea.call(e), P = (e) => Qt(e) === "[object Object]", os = (e) => e == null ? "" : B(e) || P(e) && e.toString === ea ? JSON.stringify(e, null, 2) : String(e);
|
|
41
41
|
function qt(e, t = "") {
|
|
42
42
|
return e.reduce((n, a, s) => s === 0 ? n + a : n + t + a, "");
|
|
43
43
|
}
|
|
@@ -55,8 +55,8 @@ function ls(e, t = 0, n = e.length) {
|
|
|
55
55
|
r.push(`${u}${" ".repeat(3 - String(u).length)}| ${a[l]}`);
|
|
56
56
|
const _ = a[l].length;
|
|
57
57
|
if (l === o) {
|
|
58
|
-
const E = t - (s - _) + 1,
|
|
59
|
-
r.push(" | " + " ".repeat(E) + "^".repeat(
|
|
58
|
+
const E = t - (s - _) + 1, h = Math.max(1, n > s ? _ - E : n - t);
|
|
59
|
+
r.push(" | " + " ".repeat(E) + "^".repeat(h));
|
|
60
60
|
} else if (l > o) {
|
|
61
61
|
if (n > s) {
|
|
62
62
|
const E = Math.max(Math.min(n - s, _), 1);
|
|
@@ -167,12 +167,12 @@ function Ue(e, t, n = {}) {
|
|
|
167
167
|
function fs(e) {
|
|
168
168
|
throw e;
|
|
169
169
|
}
|
|
170
|
-
const _s = /<\/?[\w\s="/.':;#-\/]+>/, ms = (e) => _s.test(e),
|
|
170
|
+
const _s = /<\/?[\w\s="/.':;#-\/]+>/, ms = (e) => _s.test(e), pe = " ", ds = "\r", Z = `
|
|
171
171
|
`, gs = "\u2028", Es = "\u2029";
|
|
172
172
|
function ps(e) {
|
|
173
173
|
const t = e;
|
|
174
174
|
let n = 0, a = 1, s = 1, r = 0;
|
|
175
|
-
const o = (
|
|
175
|
+
const o = (N) => t[N] === ds && t[N + 1] === Z, l = (N) => t[N] === Z, u = (N) => t[N] === Es, _ = (N) => t[N] === gs, E = (N) => o(N) || l(N) || u(N) || _(N), h = () => n, p = () => a, S = () => s, D = () => r, v = (N) => o(N) || u(N) || _(N) ? Z : t[N], A = () => v(n), f = () => v(n + r);
|
|
176
176
|
function g() {
|
|
177
177
|
return r = 0, E(n) && (a++, s = 0), o(n) && n++, n++, s++, t[n];
|
|
178
178
|
}
|
|
@@ -182,17 +182,17 @@ function ps(e) {
|
|
|
182
182
|
function m() {
|
|
183
183
|
n = 0, a = 1, s = 1, r = 0;
|
|
184
184
|
}
|
|
185
|
-
function O(
|
|
186
|
-
r =
|
|
185
|
+
function O(N = 0) {
|
|
186
|
+
r = N;
|
|
187
187
|
}
|
|
188
188
|
function y() {
|
|
189
|
-
const
|
|
190
|
-
for (;
|
|
189
|
+
const N = n + r;
|
|
190
|
+
for (; N !== n; )
|
|
191
191
|
g();
|
|
192
192
|
r = 0;
|
|
193
193
|
}
|
|
194
194
|
return {
|
|
195
|
-
index:
|
|
195
|
+
index: h,
|
|
196
196
|
line: p,
|
|
197
197
|
column: S,
|
|
198
198
|
peekOffset: D,
|
|
@@ -221,10 +221,10 @@ function Ts(e, t = {}) {
|
|
|
221
221
|
inLinked: !1,
|
|
222
222
|
text: ""
|
|
223
223
|
}, _ = () => u, { onError: E } = t;
|
|
224
|
-
function
|
|
224
|
+
function h(i, c, T, ...C) {
|
|
225
225
|
const K = _();
|
|
226
226
|
if (c.column += T, c.offset += T, E) {
|
|
227
|
-
const
|
|
227
|
+
const H = n ? Ft(K.startLoc, c) : null, w = Ue(i, H, {
|
|
228
228
|
domain: Ns,
|
|
229
229
|
args: C
|
|
230
230
|
});
|
|
@@ -242,11 +242,11 @@ function Ts(e, t = {}) {
|
|
|
242
242
|
/* TokenTypes.EOF */
|
|
243
243
|
);
|
|
244
244
|
function D(i, c) {
|
|
245
|
-
return i.currentChar() === c ? (i.next(), c) : (
|
|
245
|
+
return i.currentChar() === c ? (i.next(), c) : (h(k.EXPECTED_TOKEN, r(), 0, c), "");
|
|
246
246
|
}
|
|
247
247
|
function v(i) {
|
|
248
248
|
let c = "";
|
|
249
|
-
for (; i.currentPeek() ===
|
|
249
|
+
for (; i.currentPeek() === pe || i.currentPeek() === Z; )
|
|
250
250
|
c += i.currentPeek(), i.peek();
|
|
251
251
|
return c;
|
|
252
252
|
}
|
|
@@ -300,7 +300,7 @@ function Ts(e, t = {}) {
|
|
|
300
300
|
const C = i.currentPeek() === ".";
|
|
301
301
|
return i.resetPeek(), C;
|
|
302
302
|
}
|
|
303
|
-
function
|
|
303
|
+
function N(i, c) {
|
|
304
304
|
const { currentType: T } = c;
|
|
305
305
|
if (T !== 8)
|
|
306
306
|
return !1;
|
|
@@ -321,8 +321,8 @@ function Ts(e, t = {}) {
|
|
|
321
321
|
if (T !== 9)
|
|
322
322
|
return !1;
|
|
323
323
|
const C = () => {
|
|
324
|
-
const
|
|
325
|
-
return
|
|
324
|
+
const H = i.currentPeek();
|
|
325
|
+
return H === "{" ? f(i.peek()) : H === "@" || H === "|" || H === ":" || H === "." || H === pe || !H ? !1 : H === Z ? (i.peek(), C()) : ie(i, !1);
|
|
326
326
|
}, K = C();
|
|
327
327
|
return i.resetPeek(), K;
|
|
328
328
|
}
|
|
@@ -332,9 +332,9 @@ function Ts(e, t = {}) {
|
|
|
332
332
|
return i.resetPeek(), c;
|
|
333
333
|
}
|
|
334
334
|
function ie(i, c = !0) {
|
|
335
|
-
const T = (K = !1,
|
|
335
|
+
const T = (K = !1, H = "") => {
|
|
336
336
|
const w = i.currentPeek();
|
|
337
|
-
return w === "{" || w === "@" || !w ? K : w === "|" ? !(
|
|
337
|
+
return w === "{" || w === "@" || !w ? K : w === "|" ? !(H === pe || H === Z) : w === pe ? (i.peek(), T(!0, pe)) : w === Z ? (i.peek(), T(!0, Z)) : !0;
|
|
338
338
|
}, C = T();
|
|
339
339
|
return c && i.resetPeek(), C;
|
|
340
340
|
}
|
|
@@ -378,7 +378,7 @@ function Ts(e, t = {}) {
|
|
|
378
378
|
c >= 65 && c <= 70 || // A-F
|
|
379
379
|
c >= 97 && c <= 102;
|
|
380
380
|
}
|
|
381
|
-
function
|
|
381
|
+
function Ee(i) {
|
|
382
382
|
return J(i, ht);
|
|
383
383
|
}
|
|
384
384
|
function Ve(i) {
|
|
@@ -393,7 +393,7 @@ function Ts(e, t = {}) {
|
|
|
393
393
|
const T = i.currentChar();
|
|
394
394
|
if (T === "{" || T === "}" || T === "@" || T === "|" || !T)
|
|
395
395
|
break;
|
|
396
|
-
if (T ===
|
|
396
|
+
if (T === pe || T === Z)
|
|
397
397
|
if (ie(i))
|
|
398
398
|
c += T, i.next();
|
|
399
399
|
else {
|
|
@@ -411,12 +411,12 @@ function Ts(e, t = {}) {
|
|
|
411
411
|
let c = "", T = "";
|
|
412
412
|
for (; c = gt(i); )
|
|
413
413
|
T += c;
|
|
414
|
-
return i.currentChar() === Te &&
|
|
414
|
+
return i.currentChar() === Te && h(k.UNTERMINATED_CLOSING_BRACE, r(), 0), T;
|
|
415
415
|
}
|
|
416
416
|
function Lt(i) {
|
|
417
417
|
A(i);
|
|
418
418
|
let c = "";
|
|
419
|
-
return i.currentChar() === "-" ? (i.next(), c += `-${Ve(i)}`) : c += Ve(i), i.currentChar() === Te &&
|
|
419
|
+
return i.currentChar() === "-" ? (i.next(), c += `-${Ve(i)}`) : c += Ve(i), i.currentChar() === Te && h(k.UNTERMINATED_CLOSING_BRACE, r(), 0), c;
|
|
420
420
|
}
|
|
421
421
|
function bt(i) {
|
|
422
422
|
return i !== Tn && i !== Z;
|
|
@@ -427,7 +427,7 @@ function Ts(e, t = {}) {
|
|
|
427
427
|
for (; c = J(i, bt); )
|
|
428
428
|
c === "\\" ? T += Ot(i) : T += c;
|
|
429
429
|
const C = i.currentChar();
|
|
430
|
-
return C === Z || C === Te ? (
|
|
430
|
+
return C === Z || C === Te ? (h(k.UNTERMINATED_SINGLE_QUOTE_IN_PLACEHOLDER, r(), 0), C === Z && (i.next(), D(i, "'")), T) : (D(i, "'"), T);
|
|
431
431
|
}
|
|
432
432
|
function Ot(i) {
|
|
433
433
|
const c = i.currentChar();
|
|
@@ -440,24 +440,24 @@ function Ts(e, t = {}) {
|
|
|
440
440
|
case "U":
|
|
441
441
|
return ze(i, c, 6);
|
|
442
442
|
default:
|
|
443
|
-
return
|
|
443
|
+
return h(k.UNKNOWN_ESCAPE_SEQUENCE, r(), 0, c), "";
|
|
444
444
|
}
|
|
445
445
|
}
|
|
446
446
|
function ze(i, c, T) {
|
|
447
447
|
D(i, c);
|
|
448
448
|
let C = "";
|
|
449
449
|
for (let K = 0; K < T; K++) {
|
|
450
|
-
const
|
|
451
|
-
if (!
|
|
452
|
-
|
|
450
|
+
const H = Ee(i);
|
|
451
|
+
if (!H) {
|
|
452
|
+
h(k.INVALID_UNICODE_ESCAPE_SEQUENCE, r(), 0, `\\${c}${C}${i.currentChar()}`);
|
|
453
453
|
break;
|
|
454
454
|
}
|
|
455
|
-
C +=
|
|
455
|
+
C += H;
|
|
456
456
|
}
|
|
457
457
|
return `\\${c}${C}`;
|
|
458
458
|
}
|
|
459
459
|
function It(i) {
|
|
460
|
-
return i !== "{" && i !== "}" && i !==
|
|
460
|
+
return i !== "{" && i !== "}" && i !== pe && i !== Z;
|
|
461
461
|
}
|
|
462
462
|
function vt(i) {
|
|
463
463
|
A(i);
|
|
@@ -475,11 +475,11 @@ function Ts(e, t = {}) {
|
|
|
475
475
|
function St(i) {
|
|
476
476
|
const c = (T) => {
|
|
477
477
|
const C = i.currentChar();
|
|
478
|
-
return C === "{" || C === "@" || C === "|" || C === "(" || C === ")" || !C || C ===
|
|
478
|
+
return C === "{" || C === "@" || C === "|" || C === "(" || C === ")" || !C || C === pe ? T : (T += C, i.next(), c(T));
|
|
479
479
|
};
|
|
480
480
|
return c("");
|
|
481
481
|
}
|
|
482
|
-
function
|
|
482
|
+
function $e(i) {
|
|
483
483
|
A(i);
|
|
484
484
|
const c = D(
|
|
485
485
|
i,
|
|
@@ -488,39 +488,39 @@ function Ts(e, t = {}) {
|
|
|
488
488
|
);
|
|
489
489
|
return A(i), c;
|
|
490
490
|
}
|
|
491
|
-
function
|
|
491
|
+
function We(i, c) {
|
|
492
492
|
let T = null;
|
|
493
493
|
switch (i.currentChar()) {
|
|
494
494
|
case "{":
|
|
495
|
-
return c.braceNest >= 1 &&
|
|
495
|
+
return c.braceNest >= 1 && h(k.NOT_ALLOW_NEST_PLACEHOLDER, r(), 0), i.next(), T = p(
|
|
496
496
|
c,
|
|
497
497
|
2,
|
|
498
498
|
"{"
|
|
499
499
|
/* TokenChars.BraceLeft */
|
|
500
500
|
), A(i), c.braceNest++, T;
|
|
501
501
|
case "}":
|
|
502
|
-
return c.braceNest > 0 && c.currentType === 2 &&
|
|
502
|
+
return c.braceNest > 0 && c.currentType === 2 && h(k.EMPTY_PLACEHOLDER, r(), 0), i.next(), T = p(
|
|
503
503
|
c,
|
|
504
504
|
3,
|
|
505
505
|
"}"
|
|
506
506
|
/* TokenChars.BraceRight */
|
|
507
507
|
), c.braceNest--, c.braceNest > 0 && A(i), c.inLinked && c.braceNest === 0 && (c.inLinked = !1), T;
|
|
508
508
|
case "@":
|
|
509
|
-
return c.braceNest > 0 &&
|
|
509
|
+
return c.braceNest > 0 && h(k.UNTERMINATED_CLOSING_BRACE, r(), 0), T = Ie(i, c) || S(c), c.braceNest = 0, T;
|
|
510
510
|
default: {
|
|
511
|
-
let K = !0,
|
|
511
|
+
let K = !0, H = !0, w = !0;
|
|
512
512
|
if (X(i))
|
|
513
|
-
return c.braceNest > 0 &&
|
|
513
|
+
return c.braceNest > 0 && h(k.UNTERMINATED_CLOSING_BRACE, r(), 0), T = p(c, 1, $e(i)), c.braceNest = 0, c.inLinked = !1, T;
|
|
514
514
|
if (c.braceNest > 0 && (c.currentType === 4 || c.currentType === 5 || c.currentType === 6))
|
|
515
|
-
return
|
|
515
|
+
return h(k.UNTERMINATED_CLOSING_BRACE, r(), 0), c.braceNest = 0, xe(i, c);
|
|
516
516
|
if (K = b(i, c))
|
|
517
517
|
return T = p(c, 4, Tt(i)), A(i), T;
|
|
518
|
-
if (
|
|
518
|
+
if (H = m(i, c))
|
|
519
519
|
return T = p(c, 5, Lt(i)), A(i), T;
|
|
520
520
|
if (w = O(i, c))
|
|
521
521
|
return T = p(c, 6, un(i)), A(i), T;
|
|
522
|
-
if (!K && !
|
|
523
|
-
return T = p(c, 12, vt(i)),
|
|
522
|
+
if (!K && !H && !w)
|
|
523
|
+
return T = p(c, 12, vt(i)), h(k.INVALID_TOKEN_IN_PLACEHOLDER, r(), 0, T.value), A(i), T;
|
|
524
524
|
break;
|
|
525
525
|
}
|
|
526
526
|
}
|
|
@@ -530,7 +530,7 @@ function Ts(e, t = {}) {
|
|
|
530
530
|
const { currentType: T } = c;
|
|
531
531
|
let C = null;
|
|
532
532
|
const K = i.currentChar();
|
|
533
|
-
switch ((T === 7 || T === 8 || T === 11 || T === 9) && (K === Z || K ===
|
|
533
|
+
switch ((T === 7 || T === 8 || T === 11 || T === 9) && (K === Z || K === pe) && h(k.INVALID_LINKED_FORMAT, r(), 0), K) {
|
|
534
534
|
case "@":
|
|
535
535
|
return i.next(), C = p(
|
|
536
536
|
c,
|
|
@@ -553,7 +553,7 @@ function Ts(e, t = {}) {
|
|
|
553
553
|
/* TokenChars.LinkedDelimiter */
|
|
554
554
|
);
|
|
555
555
|
default:
|
|
556
|
-
return X(i) ? (C = p(c, 1,
|
|
556
|
+
return X(i) ? (C = p(c, 1, $e(i)), c.braceNest = 0, c.inLinked = !1, C) : y(i, c) || R(i, c) ? (A(i), Ie(i, c)) : N(i, c) ? (A(i), p(c, 11, yt(i))) : U(i, c) ? (A(i), K === "{" ? We(i, c) || C : p(c, 10, St(i))) : (T === 7 && h(k.INVALID_LINKED_FORMAT, r(), 0), c.braceNest = 0, c.inLinked = !1, xe(i, c));
|
|
557
557
|
}
|
|
558
558
|
}
|
|
559
559
|
function xe(i, c) {
|
|
@@ -562,14 +562,14 @@ function Ts(e, t = {}) {
|
|
|
562
562
|
/* TokenTypes.EOF */
|
|
563
563
|
};
|
|
564
564
|
if (c.braceNest > 0)
|
|
565
|
-
return
|
|
565
|
+
return We(i, c) || S(c);
|
|
566
566
|
if (c.inLinked)
|
|
567
567
|
return Ie(i, c) || S(c);
|
|
568
568
|
switch (i.currentChar()) {
|
|
569
569
|
case "{":
|
|
570
|
-
return
|
|
570
|
+
return We(i, c) || S(c);
|
|
571
571
|
case "}":
|
|
572
|
-
return
|
|
572
|
+
return h(k.UNBALANCED_CLOSING_BRACE, r(), 0), i.next(), p(
|
|
573
573
|
c,
|
|
574
574
|
3,
|
|
575
575
|
"}"
|
|
@@ -579,7 +579,7 @@ function Ts(e, t = {}) {
|
|
|
579
579
|
return Ie(i, c) || S(c);
|
|
580
580
|
default: {
|
|
581
581
|
if (X(i))
|
|
582
|
-
return T = p(c, 1,
|
|
582
|
+
return T = p(c, 1, $e(i)), c.braceNest = 0, c.inLinked = !1, T;
|
|
583
583
|
if (ie(i))
|
|
584
584
|
return p(c, 0, Nt(i));
|
|
585
585
|
break;
|
|
@@ -621,7 +621,7 @@ function Is(e = {}) {
|
|
|
621
621
|
function a(f, g, b, m, ...O) {
|
|
622
622
|
const y = f.currentPosition();
|
|
623
623
|
if (y.offset += m, y.column += m, n) {
|
|
624
|
-
const
|
|
624
|
+
const N = t ? Ft(b, y) : null, R = Ue(g, N, {
|
|
625
625
|
domain: Ls,
|
|
626
626
|
args: O
|
|
627
627
|
});
|
|
@@ -656,11 +656,11 @@ function Is(e = {}) {
|
|
|
656
656
|
return g.type !== 11 ? (a(f, k.UNEXPECTED_EMPTY_LINKED_MODIFIER, b.lastStartLoc, 0), y.value = "", r(y, m, O), {
|
|
657
657
|
nextConsumeToken: g,
|
|
658
658
|
node: y
|
|
659
|
-
}) : (g.value == null && a(f, k.UNEXPECTED_LEXICAL_ANALYSIS, b.lastStartLoc, 0,
|
|
659
|
+
}) : (g.value == null && a(f, k.UNEXPECTED_LEXICAL_ANALYSIS, b.lastStartLoc, 0, me(g)), y.value = g.value || "", r(y, f.currentOffset(), f.currentPosition()), {
|
|
660
660
|
node: y
|
|
661
661
|
});
|
|
662
662
|
}
|
|
663
|
-
function
|
|
663
|
+
function h(f, g) {
|
|
664
664
|
const b = f.context(), m = s(7, b.offset, b.startLoc);
|
|
665
665
|
return m.value = g, r(m, f.currentOffset(), f.currentPosition()), m;
|
|
666
666
|
}
|
|
@@ -671,18 +671,18 @@ function Is(e = {}) {
|
|
|
671
671
|
const O = E(f);
|
|
672
672
|
b.modifier = O.node, m = O.nextConsumeToken || f.nextToken();
|
|
673
673
|
}
|
|
674
|
-
switch (m.type !== 9 && a(f, k.UNEXPECTED_LEXICAL_ANALYSIS, g.lastStartLoc, 0,
|
|
674
|
+
switch (m.type !== 9 && a(f, k.UNEXPECTED_LEXICAL_ANALYSIS, g.lastStartLoc, 0, me(m)), m = f.nextToken(), m.type === 2 && (m = f.nextToken()), m.type) {
|
|
675
675
|
case 10:
|
|
676
|
-
m.value == null && a(f, k.UNEXPECTED_LEXICAL_ANALYSIS, g.lastStartLoc, 0,
|
|
676
|
+
m.value == null && a(f, k.UNEXPECTED_LEXICAL_ANALYSIS, g.lastStartLoc, 0, me(m)), b.key = h(f, m.value || "");
|
|
677
677
|
break;
|
|
678
678
|
case 4:
|
|
679
|
-
m.value == null && a(f, k.UNEXPECTED_LEXICAL_ANALYSIS, g.lastStartLoc, 0,
|
|
679
|
+
m.value == null && a(f, k.UNEXPECTED_LEXICAL_ANALYSIS, g.lastStartLoc, 0, me(m)), b.key = u(f, m.value || "");
|
|
680
680
|
break;
|
|
681
681
|
case 5:
|
|
682
|
-
m.value == null && a(f, k.UNEXPECTED_LEXICAL_ANALYSIS, g.lastStartLoc, 0,
|
|
682
|
+
m.value == null && a(f, k.UNEXPECTED_LEXICAL_ANALYSIS, g.lastStartLoc, 0, me(m)), b.key = l(f, m.value || "");
|
|
683
683
|
break;
|
|
684
684
|
case 6:
|
|
685
|
-
m.value == null && a(f, k.UNEXPECTED_LEXICAL_ANALYSIS, g.lastStartLoc, 0,
|
|
685
|
+
m.value == null && a(f, k.UNEXPECTED_LEXICAL_ANALYSIS, g.lastStartLoc, 0, me(m)), b.key = _(f, m.value || "");
|
|
686
686
|
break;
|
|
687
687
|
default: {
|
|
688
688
|
a(f, k.UNEXPECTED_EMPTY_LINKED_KEY, g.lastStartLoc, 0);
|
|
@@ -705,16 +705,16 @@ function Is(e = {}) {
|
|
|
705
705
|
const U = y || f.nextToken();
|
|
706
706
|
switch (y = null, U.type) {
|
|
707
707
|
case 0:
|
|
708
|
-
U.value == null && a(f, k.UNEXPECTED_LEXICAL_ANALYSIS, g.lastStartLoc, 0,
|
|
708
|
+
U.value == null && a(f, k.UNEXPECTED_LEXICAL_ANALYSIS, g.lastStartLoc, 0, me(U)), O.items.push(o(f, U.value || ""));
|
|
709
709
|
break;
|
|
710
710
|
case 5:
|
|
711
|
-
U.value == null && a(f, k.UNEXPECTED_LEXICAL_ANALYSIS, g.lastStartLoc, 0,
|
|
711
|
+
U.value == null && a(f, k.UNEXPECTED_LEXICAL_ANALYSIS, g.lastStartLoc, 0, me(U)), O.items.push(l(f, U.value || ""));
|
|
712
712
|
break;
|
|
713
713
|
case 4:
|
|
714
|
-
U.value == null && a(f, k.UNEXPECTED_LEXICAL_ANALYSIS, g.lastStartLoc, 0,
|
|
714
|
+
U.value == null && a(f, k.UNEXPECTED_LEXICAL_ANALYSIS, g.lastStartLoc, 0, me(U)), O.items.push(u(f, U.value || ""));
|
|
715
715
|
break;
|
|
716
716
|
case 6:
|
|
717
|
-
U.value == null && a(f, k.UNEXPECTED_LEXICAL_ANALYSIS, g.lastStartLoc, 0,
|
|
717
|
+
U.value == null && a(f, k.UNEXPECTED_LEXICAL_ANALYSIS, g.lastStartLoc, 0, me(U)), O.items.push(_(f, U.value || ""));
|
|
718
718
|
break;
|
|
719
719
|
case 7: {
|
|
720
720
|
const X = p(f);
|
|
@@ -723,19 +723,19 @@ function Is(e = {}) {
|
|
|
723
723
|
}
|
|
724
724
|
}
|
|
725
725
|
} while (g.currentType !== 13 && g.currentType !== 1);
|
|
726
|
-
const
|
|
727
|
-
return r(O,
|
|
726
|
+
const N = g.currentType === 1 ? g.lastOffset : f.currentOffset(), R = g.currentType === 1 ? g.lastEndLoc : f.currentPosition();
|
|
727
|
+
return r(O, N, R), O;
|
|
728
728
|
}
|
|
729
729
|
function D(f, g, b, m) {
|
|
730
730
|
const O = f.context();
|
|
731
731
|
let y = m.items.length === 0;
|
|
732
|
-
const
|
|
733
|
-
|
|
732
|
+
const N = s(1, g, b);
|
|
733
|
+
N.cases = [], N.cases.push(m);
|
|
734
734
|
do {
|
|
735
735
|
const R = S(f);
|
|
736
|
-
y || (y = R.items.length === 0),
|
|
736
|
+
y || (y = R.items.length === 0), N.cases.push(R);
|
|
737
737
|
} while (O.currentType !== 13);
|
|
738
|
-
return y && a(f, k.MUST_HAVE_MESSAGES_IN_PLURAL, b, 0), r(
|
|
738
|
+
return y && a(f, k.MUST_HAVE_MESSAGES_IN_PLURAL, b, 0), r(N, f.currentOffset(), f.currentPosition()), N;
|
|
739
739
|
}
|
|
740
740
|
function v(f) {
|
|
741
741
|
const g = f.context(), { offset: b, startLoc: m } = g, O = S(f);
|
|
@@ -747,7 +747,7 @@ function Is(e = {}) {
|
|
|
747
747
|
}
|
|
748
748
|
return { parse: A };
|
|
749
749
|
}
|
|
750
|
-
function
|
|
750
|
+
function me(e) {
|
|
751
751
|
if (e.type === 13)
|
|
752
752
|
return "EOF";
|
|
753
753
|
const t = (e.value || "").replace(/\r?\n/gu, "\\n");
|
|
@@ -919,7 +919,7 @@ function Ds(e, t) {
|
|
|
919
919
|
const A = ++o.indentLevel;
|
|
920
920
|
v && _(A);
|
|
921
921
|
}
|
|
922
|
-
function
|
|
922
|
+
function h(v = !0) {
|
|
923
923
|
const A = --o.indentLevel;
|
|
924
924
|
v && _(A);
|
|
925
925
|
}
|
|
@@ -930,7 +930,7 @@ function Ds(e, t) {
|
|
|
930
930
|
context: l,
|
|
931
931
|
push: u,
|
|
932
932
|
indent: E,
|
|
933
|
-
deindent:
|
|
933
|
+
deindent: h,
|
|
934
934
|
newline: p,
|
|
935
935
|
helper: (v) => `_${v}`,
|
|
936
936
|
needIndent: () => o.needIndent
|
|
@@ -1054,42 +1054,42 @@ function Us() {
|
|
|
1054
1054
|
typeof __INTLIFY_PROD_DEVTOOLS__ != "boolean" && (Se().__INTLIFY_PROD_DEVTOOLS__ = !1), typeof __INTLIFY_DROP_MESSAGE_COMPILER__ != "boolean" && (Se().__INTLIFY_DROP_MESSAGE_COMPILER__ = !1);
|
|
1055
1055
|
}
|
|
1056
1056
|
function le(e) {
|
|
1057
|
-
return M(e) && tn(e) === 0 && (
|
|
1057
|
+
return M(e) && tn(e) === 0 && (ue(e, "b") || ue(e, "body"));
|
|
1058
1058
|
}
|
|
1059
|
-
const
|
|
1059
|
+
const ta = ["b", "body"];
|
|
1060
1060
|
function Vs(e) {
|
|
1061
|
-
return be(e,
|
|
1061
|
+
return be(e, ta);
|
|
1062
1062
|
}
|
|
1063
|
-
const
|
|
1064
|
-
function Ws(e) {
|
|
1065
|
-
return be(e, ta, []);
|
|
1066
|
-
}
|
|
1067
|
-
const na = ["s", "static"];
|
|
1063
|
+
const na = ["c", "cases"];
|
|
1068
1064
|
function $s(e) {
|
|
1069
|
-
return be(e, na);
|
|
1065
|
+
return be(e, na, []);
|
|
1066
|
+
}
|
|
1067
|
+
const aa = ["s", "static"];
|
|
1068
|
+
function Ws(e) {
|
|
1069
|
+
return be(e, aa);
|
|
1070
1070
|
}
|
|
1071
|
-
const
|
|
1071
|
+
const sa = ["i", "items"];
|
|
1072
1072
|
function xs(e) {
|
|
1073
|
-
return be(e,
|
|
1073
|
+
return be(e, sa, []);
|
|
1074
1074
|
}
|
|
1075
|
-
const
|
|
1075
|
+
const ra = ["t", "type"];
|
|
1076
1076
|
function tn(e) {
|
|
1077
|
-
return be(e,
|
|
1077
|
+
return be(e, ra);
|
|
1078
1078
|
}
|
|
1079
|
-
const
|
|
1079
|
+
const oa = ["v", "value"];
|
|
1080
1080
|
function at(e, t) {
|
|
1081
|
-
const n = be(e,
|
|
1081
|
+
const n = be(e, oa);
|
|
1082
1082
|
if (n != null)
|
|
1083
1083
|
return n;
|
|
1084
1084
|
throw Be(t);
|
|
1085
1085
|
}
|
|
1086
|
-
const
|
|
1086
|
+
const la = ["m", "modifier"];
|
|
1087
1087
|
function Gs(e) {
|
|
1088
|
-
return be(e,
|
|
1088
|
+
return be(e, la);
|
|
1089
1089
|
}
|
|
1090
|
-
const
|
|
1090
|
+
const ia = ["k", "key"];
|
|
1091
1091
|
function Ks(e) {
|
|
1092
|
-
const t = be(e,
|
|
1092
|
+
const t = be(e, ia);
|
|
1093
1093
|
if (t)
|
|
1094
1094
|
return t;
|
|
1095
1095
|
throw Be(
|
|
@@ -1100,28 +1100,28 @@ function Ks(e) {
|
|
|
1100
1100
|
function be(e, t, n) {
|
|
1101
1101
|
for (let a = 0; a < t.length; a++) {
|
|
1102
1102
|
const s = t[a];
|
|
1103
|
-
if (
|
|
1103
|
+
if (ue(e, s) && e[s] != null)
|
|
1104
1104
|
return e[s];
|
|
1105
1105
|
}
|
|
1106
1106
|
return n;
|
|
1107
1107
|
}
|
|
1108
|
-
const
|
|
1109
|
-
...ea,
|
|
1108
|
+
const ca = [
|
|
1110
1109
|
...ta,
|
|
1111
1110
|
...na,
|
|
1112
1111
|
...aa,
|
|
1112
|
+
...sa,
|
|
1113
|
+
...ia,
|
|
1113
1114
|
...la,
|
|
1114
1115
|
...oa,
|
|
1115
|
-
...ra
|
|
1116
|
-
...sa
|
|
1116
|
+
...ra
|
|
1117
1117
|
];
|
|
1118
1118
|
function Be(e) {
|
|
1119
1119
|
return new Error(`unhandled node type: ${e}`);
|
|
1120
1120
|
}
|
|
1121
1121
|
function Dt(e) {
|
|
1122
|
-
return (n) =>
|
|
1122
|
+
return (n) => Hs(n, e);
|
|
1123
1123
|
}
|
|
1124
|
-
function
|
|
1124
|
+
function Hs(e, t) {
|
|
1125
1125
|
const n = Vs(t);
|
|
1126
1126
|
if (n == null)
|
|
1127
1127
|
throw Be(
|
|
@@ -1129,7 +1129,7 @@ function Ys(e, t) {
|
|
|
1129
1129
|
/* NodeTypes.Resource */
|
|
1130
1130
|
);
|
|
1131
1131
|
if (tn(n) === 1) {
|
|
1132
|
-
const r =
|
|
1132
|
+
const r = $s(n);
|
|
1133
1133
|
return e.plural(r.reduce((o, l) => [
|
|
1134
1134
|
...o,
|
|
1135
1135
|
On(e, l)
|
|
@@ -1138,7 +1138,7 @@ function Ys(e, t) {
|
|
|
1138
1138
|
return On(e, n);
|
|
1139
1139
|
}
|
|
1140
1140
|
function On(e, t) {
|
|
1141
|
-
const n =
|
|
1141
|
+
const n = Ws(t);
|
|
1142
1142
|
if (n != null)
|
|
1143
1143
|
return e.type === "text" ? n : e.normalize([n]);
|
|
1144
1144
|
{
|
|
@@ -1155,17 +1155,17 @@ function wt(e, t) {
|
|
|
1155
1155
|
return at(t, n);
|
|
1156
1156
|
case 4: {
|
|
1157
1157
|
const a = t;
|
|
1158
|
-
if (
|
|
1158
|
+
if (ue(a, "k") && a.k)
|
|
1159
1159
|
return e.interpolate(e.named(a.k));
|
|
1160
|
-
if (
|
|
1160
|
+
if (ue(a, "key") && a.key)
|
|
1161
1161
|
return e.interpolate(e.named(a.key));
|
|
1162
1162
|
throw Be(n);
|
|
1163
1163
|
}
|
|
1164
1164
|
case 5: {
|
|
1165
1165
|
const a = t;
|
|
1166
|
-
if (
|
|
1166
|
+
if (ue(a, "i") && j(a.i))
|
|
1167
1167
|
return e.interpolate(e.list(a.i));
|
|
1168
|
-
if (
|
|
1168
|
+
if (ue(a, "index") && j(a.index))
|
|
1169
1169
|
return e.interpolate(e.list(a.index));
|
|
1170
1170
|
throw Be(n);
|
|
1171
1171
|
}
|
|
@@ -1181,9 +1181,9 @@ function wt(e, t) {
|
|
|
1181
1181
|
throw new Error(`unhandled node on format message part: ${n}`);
|
|
1182
1182
|
}
|
|
1183
1183
|
}
|
|
1184
|
-
const
|
|
1184
|
+
const Ys = "Detected HTML in '{source}' message. Recommend not using HTML messages to avoid XSS.";
|
|
1185
1185
|
function Bs(e, t) {
|
|
1186
|
-
t && ms(e) && Le(ct(
|
|
1186
|
+
t && ms(e) && Le(ct(Ys, { source: e }));
|
|
1187
1187
|
}
|
|
1188
1188
|
const js = (e) => e;
|
|
1189
1189
|
let st = W();
|
|
@@ -1283,7 +1283,7 @@ function nr(e, t, n) {
|
|
|
1283
1283
|
...B(t) ? t : M(t) ? Object.keys(t) : I(t) ? [t] : [n]
|
|
1284
1284
|
])];
|
|
1285
1285
|
}
|
|
1286
|
-
function
|
|
1286
|
+
function ua(e, t, n) {
|
|
1287
1287
|
const a = I(n) ? n : Xe, s = e;
|
|
1288
1288
|
s.__localeChainCache || (s.__localeChainCache = /* @__PURE__ */ new Map());
|
|
1289
1289
|
let r = s.__localeChainCache.get(a);
|
|
@@ -1535,7 +1535,7 @@ function cr(e) {
|
|
|
1535
1535
|
}
|
|
1536
1536
|
function ur(e) {
|
|
1537
1537
|
const t = [];
|
|
1538
|
-
let n = -1, a = 0, s = 0, r, o, l, u, _, E,
|
|
1538
|
+
let n = -1, a = 0, s = 0, r, o, l, u, _, E, h;
|
|
1539
1539
|
const p = [];
|
|
1540
1540
|
p[
|
|
1541
1541
|
0
|
|
@@ -1583,7 +1583,7 @@ function ur(e) {
|
|
|
1583
1583
|
}
|
|
1584
1584
|
for (; a !== null; )
|
|
1585
1585
|
if (n++, r = e[n], !(r === "\\" && S())) {
|
|
1586
|
-
if (u = ir(r),
|
|
1586
|
+
if (u = ir(r), h = Oe[a], _ = h[u] || h.l || 8, _ === 8 || (a = _[0], _[1] !== void 0 && (E = p[_[1]], E && (l = r, E() === !1))))
|
|
1587
1587
|
return;
|
|
1588
1588
|
if (a === 7)
|
|
1589
1589
|
return t;
|
|
@@ -1603,7 +1603,7 @@ function _r(e, t) {
|
|
|
1603
1603
|
let s = e, r = 0;
|
|
1604
1604
|
for (; r < a; ) {
|
|
1605
1605
|
const o = n[r];
|
|
1606
|
-
if (
|
|
1606
|
+
if (ca.includes(o) && le(s))
|
|
1607
1607
|
return null;
|
|
1608
1608
|
const l = s[o];
|
|
1609
1609
|
if (l === void 0 || x(s))
|
|
@@ -1640,31 +1640,31 @@ function Er() {
|
|
|
1640
1640
|
capitalize: (e, t) => t === "text" && I(e) ? Sn(e) : t === "vnode" && M(e) && "__v_isVNode" in e ? Sn(e.children) : e
|
|
1641
1641
|
};
|
|
1642
1642
|
}
|
|
1643
|
-
let ua;
|
|
1644
|
-
function pr(e) {
|
|
1645
|
-
ua = e;
|
|
1646
|
-
}
|
|
1647
1643
|
let fa;
|
|
1648
|
-
function
|
|
1644
|
+
function pr(e) {
|
|
1649
1645
|
fa = e;
|
|
1650
1646
|
}
|
|
1651
1647
|
let _a;
|
|
1652
|
-
function
|
|
1648
|
+
function hr(e) {
|
|
1653
1649
|
_a = e;
|
|
1654
1650
|
}
|
|
1655
|
-
let ma
|
|
1656
|
-
|
|
1651
|
+
let ma;
|
|
1652
|
+
function Nr(e) {
|
|
1657
1653
|
ma = e;
|
|
1658
|
-
}
|
|
1654
|
+
}
|
|
1659
1655
|
let da = null;
|
|
1660
|
-
const
|
|
1656
|
+
const Tr = /* @__NO_SIDE_EFFECTS__ */ (e) => {
|
|
1661
1657
|
da = e;
|
|
1662
|
-
},
|
|
1658
|
+
}, Lr = /* @__NO_SIDE_EFFECTS__ */ () => da;
|
|
1659
|
+
let ga = null;
|
|
1660
|
+
const An = (e) => {
|
|
1661
|
+
ga = e;
|
|
1662
|
+
}, br = () => ga;
|
|
1663
1663
|
let Cn = 0;
|
|
1664
1664
|
function Or(e = {}) {
|
|
1665
|
-
const t = x(e.onWarn) ? e.onWarn : Le, n = I(e.version) ? e.version : gr, a = I(e.locale) || x(e.locale) ? e.locale : Xe, s = x(a) ? Xe : a, r = B(e.fallbackLocale) || P(e.fallbackLocale) || I(e.fallbackLocale) || e.fallbackLocale === !1 ? e.fallbackLocale : s, o = P(e.messages) ? e.messages : Rt(s), l = P(e.datetimeFormats) ? e.datetimeFormats : Rt(s), u = P(e.numberFormats) ? e.numberFormats : Rt(s), _ = Q(W(), e.modifiers, Er()), E = e.pluralRules || W(),
|
|
1665
|
+
const t = x(e.onWarn) ? e.onWarn : Le, n = I(e.version) ? e.version : gr, a = I(e.locale) || x(e.locale) ? e.locale : Xe, s = x(a) ? Xe : a, r = B(e.fallbackLocale) || P(e.fallbackLocale) || I(e.fallbackLocale) || e.fallbackLocale === !1 ? e.fallbackLocale : s, o = P(e.messages) ? e.messages : Rt(s), l = P(e.datetimeFormats) ? e.datetimeFormats : Rt(s), u = P(e.numberFormats) ? e.numberFormats : Rt(s), _ = Q(W(), e.modifiers, Er()), E = e.pluralRules || W(), h = x(e.missing) ? e.missing : null, p = F(e.missingWarn) || Fe(e.missingWarn) ? e.missingWarn : !0, S = F(e.fallbackWarn) || Fe(e.fallbackWarn) ? e.fallbackWarn : !0, D = !!e.fallbackFormat, v = !!e.unresolving, A = x(e.postTranslation) ? e.postTranslation : null, f = P(e.processor) ? e.processor : null, g = F(e.warnHtmlMessage) ? e.warnHtmlMessage : !0, b = !!e.escapeParameter, m = x(e.messageCompiler) ? e.messageCompiler : fa;
|
|
1666
1666
|
process.env.NODE_ENV !== "production" && x(e.messageCompiler) && Zt(Ce(ee.EXPERIMENTAL_CUSTOM_MESSAGE_COMPILER));
|
|
1667
|
-
const O = x(e.messageResolver) ? e.messageResolver :
|
|
1667
|
+
const O = x(e.messageResolver) ? e.messageResolver : _a || fr, y = x(e.localeFallbacker) ? e.localeFallbacker : ma || nr, N = M(e.fallbackContext) ? e.fallbackContext : void 0, R = e, U = M(R.__datetimeFormatters) ? R.__datetimeFormatters : /* @__PURE__ */ new Map(), X = M(R.__numberFormatters) ? R.__numberFormatters : /* @__PURE__ */ new Map(), ie = M(R.__meta) ? R.__meta : {};
|
|
1668
1668
|
Cn++;
|
|
1669
1669
|
const J = {
|
|
1670
1670
|
version: n,
|
|
@@ -1674,7 +1674,7 @@ function Or(e = {}) {
|
|
|
1674
1674
|
messages: o,
|
|
1675
1675
|
modifiers: _,
|
|
1676
1676
|
pluralRules: E,
|
|
1677
|
-
missing:
|
|
1677
|
+
missing: h,
|
|
1678
1678
|
missingWarn: p,
|
|
1679
1679
|
fallbackWarn: S,
|
|
1680
1680
|
fallbackFormat: D,
|
|
@@ -1686,7 +1686,7 @@ function Or(e = {}) {
|
|
|
1686
1686
|
messageCompiler: m,
|
|
1687
1687
|
messageResolver: O,
|
|
1688
1688
|
localeFallbacker: y,
|
|
1689
|
-
fallbackContext:
|
|
1689
|
+
fallbackContext: N,
|
|
1690
1690
|
onWarn: t,
|
|
1691
1691
|
__meta: ie
|
|
1692
1692
|
};
|
|
@@ -1696,7 +1696,7 @@ const Rt = (e) => ({ [e]: W() });
|
|
|
1696
1696
|
function _t(e, t) {
|
|
1697
1697
|
return e instanceof RegExp ? e.test(t) : e;
|
|
1698
1698
|
}
|
|
1699
|
-
function
|
|
1699
|
+
function Ea(e, t) {
|
|
1700
1700
|
return e instanceof RegExp ? e.test(t) : e;
|
|
1701
1701
|
}
|
|
1702
1702
|
function an(e, t, n, a, s) {
|
|
@@ -1714,13 +1714,13 @@ function an(e, t, n, a, s) {
|
|
|
1714
1714
|
const l = r(e, n, t, s);
|
|
1715
1715
|
return I(l) ? l : t;
|
|
1716
1716
|
} else
|
|
1717
|
-
return process.env.NODE_ENV !== "production" &&
|
|
1717
|
+
return process.env.NODE_ENV !== "production" && Ea(a, t) && o(Ce(ee.NOT_FOUND_KEY, { key: t, locale: n })), t;
|
|
1718
1718
|
}
|
|
1719
1719
|
function Ke(e, t, n) {
|
|
1720
1720
|
const a = e;
|
|
1721
1721
|
a.__localeChainCache = /* @__PURE__ */ new Map(), e.localeFallbacker(e, n, t);
|
|
1722
1722
|
}
|
|
1723
|
-
function
|
|
1723
|
+
function pa(e, t) {
|
|
1724
1724
|
return e === t ? !1 : e.split("-")[0] === t.split("-")[0];
|
|
1725
1725
|
}
|
|
1726
1726
|
function Ir(e, t) {
|
|
@@ -1728,26 +1728,26 @@ function Ir(e, t) {
|
|
|
1728
1728
|
if (n === -1)
|
|
1729
1729
|
return !1;
|
|
1730
1730
|
for (let a = n + 1; a < t.length; a++)
|
|
1731
|
-
if (
|
|
1731
|
+
if (pa(e, t[a]))
|
|
1732
1732
|
return !0;
|
|
1733
1733
|
return !1;
|
|
1734
1734
|
}
|
|
1735
|
-
const Dn = typeof Intl < "u",
|
|
1735
|
+
const Dn = typeof Intl < "u", ha = {
|
|
1736
1736
|
dateTimeFormat: Dn && typeof Intl.DateTimeFormat < "u",
|
|
1737
1737
|
numberFormat: Dn && typeof Intl.NumberFormat < "u"
|
|
1738
1738
|
};
|
|
1739
1739
|
function kn(e, ...t) {
|
|
1740
1740
|
const { datetimeFormats: n, unresolving: a, fallbackLocale: s, onWarn: r, localeFallbacker: o } = e, { __datetimeFormatters: l } = e;
|
|
1741
|
-
if (process.env.NODE_ENV !== "production" && !
|
|
1741
|
+
if (process.env.NODE_ENV !== "production" && !ha.dateTimeFormat)
|
|
1742
1742
|
return r(Ce(ee.CANNOT_FORMAT_DATE)), ot;
|
|
1743
|
-
const [u, _, E,
|
|
1743
|
+
const [u, _, E, h] = Ut(...t), p = F(E.missingWarn) ? E.missingWarn : e.missingWarn, S = F(E.fallbackWarn) ? E.fallbackWarn : e.fallbackWarn, D = !!E.part, v = nn(e, E), A = o(
|
|
1744
1744
|
e,
|
|
1745
1745
|
// eslint-disable-line @typescript-eslint/no-explicit-any
|
|
1746
1746
|
s,
|
|
1747
1747
|
v
|
|
1748
1748
|
);
|
|
1749
1749
|
if (!I(u) || u === "")
|
|
1750
|
-
return new Intl.DateTimeFormat(v,
|
|
1750
|
+
return new Intl.DateTimeFormat(v, h).format(_);
|
|
1751
1751
|
let f = {}, g, b = null, m = v, O = null;
|
|
1752
1752
|
const y = "datetime format";
|
|
1753
1753
|
for (let U = 0; U < A.length; U++) {
|
|
@@ -1770,12 +1770,12 @@ function kn(e, ...t) {
|
|
|
1770
1770
|
}
|
|
1771
1771
|
if (!P(b) || !I(g))
|
|
1772
1772
|
return a ? ft : u;
|
|
1773
|
-
let
|
|
1774
|
-
ut(
|
|
1775
|
-
let R = l.get(
|
|
1776
|
-
return R || (R = new Intl.DateTimeFormat(g, Q({}, b,
|
|
1773
|
+
let N = `${g}__${u}`;
|
|
1774
|
+
ut(h) || (N = `${N}__${JSON.stringify(h)}`);
|
|
1775
|
+
let R = l.get(N);
|
|
1776
|
+
return R || (R = new Intl.DateTimeFormat(g, Q({}, b, h)), l.set(N, R)), D ? R.formatToParts(_) : R.format(_);
|
|
1777
1777
|
}
|
|
1778
|
-
const
|
|
1778
|
+
const Na = [
|
|
1779
1779
|
"localeMatcher",
|
|
1780
1780
|
"weekday",
|
|
1781
1781
|
"era",
|
|
@@ -1820,7 +1820,7 @@ function Ut(...e) {
|
|
|
1820
1820
|
else
|
|
1821
1821
|
throw he(q.INVALID_ARGUMENT);
|
|
1822
1822
|
return I(n) ? r.key = n : P(n) && Object.keys(n).forEach((u) => {
|
|
1823
|
-
|
|
1823
|
+
Na.includes(u) ? o[u] = n[u] : r[u] = n[u];
|
|
1824
1824
|
}), I(a) ? r.locale = a : P(a) && (o = a), P(s) && (o = s), [r.key || "", l, r, o];
|
|
1825
1825
|
}
|
|
1826
1826
|
function Rn(e, t, n) {
|
|
@@ -1832,16 +1832,16 @@ function Rn(e, t, n) {
|
|
|
1832
1832
|
}
|
|
1833
1833
|
function Pn(e, ...t) {
|
|
1834
1834
|
const { numberFormats: n, unresolving: a, fallbackLocale: s, onWarn: r, localeFallbacker: o } = e, { __numberFormatters: l } = e;
|
|
1835
|
-
if (process.env.NODE_ENV !== "production" && !
|
|
1835
|
+
if (process.env.NODE_ENV !== "production" && !ha.numberFormat)
|
|
1836
1836
|
return r(Ce(ee.CANNOT_FORMAT_NUMBER)), ot;
|
|
1837
|
-
const [u, _, E,
|
|
1837
|
+
const [u, _, E, h] = Vt(...t), p = F(E.missingWarn) ? E.missingWarn : e.missingWarn, S = F(E.fallbackWarn) ? E.fallbackWarn : e.fallbackWarn, D = !!E.part, v = nn(e, E), A = o(
|
|
1838
1838
|
e,
|
|
1839
1839
|
// eslint-disable-line @typescript-eslint/no-explicit-any
|
|
1840
1840
|
s,
|
|
1841
1841
|
v
|
|
1842
1842
|
);
|
|
1843
1843
|
if (!I(u) || u === "")
|
|
1844
|
-
return new Intl.NumberFormat(v,
|
|
1844
|
+
return new Intl.NumberFormat(v, h).format(_);
|
|
1845
1845
|
let f = {}, g, b = null, m = v, O = null;
|
|
1846
1846
|
const y = "number format";
|
|
1847
1847
|
for (let U = 0; U < A.length; U++) {
|
|
@@ -1864,12 +1864,12 @@ function Pn(e, ...t) {
|
|
|
1864
1864
|
}
|
|
1865
1865
|
if (!P(b) || !I(g))
|
|
1866
1866
|
return a ? ft : u;
|
|
1867
|
-
let
|
|
1868
|
-
ut(
|
|
1869
|
-
let R = l.get(
|
|
1870
|
-
return R || (R = new Intl.NumberFormat(g, Q({}, b,
|
|
1867
|
+
let N = `${g}__${u}`;
|
|
1868
|
+
ut(h) || (N = `${N}__${JSON.stringify(h)}`);
|
|
1869
|
+
let R = l.get(N);
|
|
1870
|
+
return R || (R = new Intl.NumberFormat(g, Q({}, b, h)), l.set(N, R)), D ? R.formatToParts(_) : R.format(_);
|
|
1871
1871
|
}
|
|
1872
|
-
const
|
|
1872
|
+
const Ta = [
|
|
1873
1873
|
"localeMatcher",
|
|
1874
1874
|
"style",
|
|
1875
1875
|
"currency",
|
|
@@ -1898,7 +1898,7 @@ function Vt(...e) {
|
|
|
1898
1898
|
throw he(q.INVALID_ARGUMENT);
|
|
1899
1899
|
const l = t;
|
|
1900
1900
|
return I(n) ? r.key = n : P(n) && Object.keys(n).forEach((u) => {
|
|
1901
|
-
|
|
1901
|
+
Ta.includes(u) ? o[u] = n[u] : r[u] = n[u];
|
|
1902
1902
|
}), I(a) ? r.locale = a : P(a) && (o = a), P(s) && (o = s), [r.key || "", l, r, o];
|
|
1903
1903
|
}
|
|
1904
1904
|
function Mn(e, t, n) {
|
|
@@ -1927,7 +1927,7 @@ function Rr(e = {}) {
|
|
|
1927
1927
|
const b = x(e.messages) ? e.messages(f, !!g) : M(e.messages) ? e.messages[f] : !1;
|
|
1928
1928
|
return b || (e.parent ? e.parent.message(f) : yr);
|
|
1929
1929
|
}
|
|
1930
|
-
const
|
|
1930
|
+
const h = (f) => e.modifiers ? e.modifiers[f] : vr, p = P(e.processor) && x(e.processor.normalize) ? e.processor.normalize : Ar, S = P(e.processor) && x(e.processor.interpolate) ? e.processor.interpolate : Cr, D = P(e.processor) && I(e.processor.type) ? e.processor.type : Sr, A = {
|
|
1931
1931
|
list: l,
|
|
1932
1932
|
named: _,
|
|
1933
1933
|
plural: r,
|
|
@@ -1935,11 +1935,11 @@ function Rr(e = {}) {
|
|
|
1935
1935
|
const [b, m] = g;
|
|
1936
1936
|
let O = "text", y = "";
|
|
1937
1937
|
g.length === 1 ? M(b) ? (y = b.modifier || y, O = b.type || O) : I(b) && (y = b || y) : g.length === 2 && (I(b) && (y = b || y), I(m) && (O = m || O));
|
|
1938
|
-
const
|
|
1938
|
+
const N = E(f, !0)(A), R = (
|
|
1939
1939
|
// The message in vnode resolved with linked are returned as an array by processor.nomalize
|
|
1940
|
-
O === "vnode" && B(
|
|
1940
|
+
O === "vnode" && B(N) && y ? N[0] : N
|
|
1941
1941
|
);
|
|
1942
|
-
return y ?
|
|
1942
|
+
return y ? h(y)(R, O) : R;
|
|
1943
1943
|
},
|
|
1944
1944
|
message: E,
|
|
1945
1945
|
type: D,
|
|
@@ -1951,21 +1951,21 @@ function Rr(e = {}) {
|
|
|
1951
1951
|
}
|
|
1952
1952
|
const wn = () => "", oe = (e) => x(e);
|
|
1953
1953
|
function Un(e, ...t) {
|
|
1954
|
-
const { fallbackFormat: n, postTranslation: a, unresolving: s, messageCompiler: r, fallbackLocale: o, messages: l } = e, [u, _] =
|
|
1954
|
+
const { fallbackFormat: n, postTranslation: a, unresolving: s, messageCompiler: r, fallbackLocale: o, messages: l } = e, [u, _] = $t(...t), E = F(_.missingWarn) ? _.missingWarn : e.missingWarn, h = F(_.fallbackWarn) ? _.fallbackWarn : e.fallbackWarn, p = F(_.escapeParameter) ? _.escapeParameter : e.escapeParameter, S = !!_.resolvedMessage, D = I(_.default) || F(_.default) ? F(_.default) ? r ? u : () => u : _.default : n ? r ? u : () => u : null, v = n || D != null && (I(D) || x(D)), A = nn(e, _);
|
|
1955
1955
|
p && Pr(_);
|
|
1956
1956
|
let [f, g, b] = S ? [
|
|
1957
1957
|
u,
|
|
1958
1958
|
A,
|
|
1959
1959
|
l[A] || W()
|
|
1960
|
-
] :
|
|
1960
|
+
] : La(e, u, A, o, h, E), m = f, O = u;
|
|
1961
1961
|
if (!S && !(I(m) || le(m) || oe(m)) && v && (m = D, O = m), !S && (!(I(m) || le(m) || oe(m)) || !I(g)))
|
|
1962
1962
|
return s ? ft : u;
|
|
1963
1963
|
if (process.env.NODE_ENV !== "production" && I(m) && e.messageCompiler == null)
|
|
1964
1964
|
return Le(`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;
|
|
1965
1965
|
let y = !1;
|
|
1966
|
-
const
|
|
1966
|
+
const N = () => {
|
|
1967
1967
|
y = !0;
|
|
1968
|
-
}, R = oe(m) ? m :
|
|
1968
|
+
}, R = oe(m) ? m : ba(e, u, g, m, O, N);
|
|
1969
1969
|
if (y)
|
|
1970
1970
|
return m;
|
|
1971
1971
|
const U = Ur(e, g, b, _), X = Rr(U), ie = Mr(e, R, X), J = a ? a(ie, u) : ie;
|
|
@@ -1986,12 +1986,12 @@ function Pr(e) {
|
|
|
1986
1986
|
I(e.named[t]) && (e.named[t] = pn(e.named[t]));
|
|
1987
1987
|
});
|
|
1988
1988
|
}
|
|
1989
|
-
function
|
|
1989
|
+
function La(e, t, n, a, s, r) {
|
|
1990
1990
|
const { messages: o, onWarn: l, messageResolver: u, localeFallbacker: _ } = e, E = _(e, a, n);
|
|
1991
|
-
let
|
|
1991
|
+
let h = W(), p, S = null, D = n, v = null;
|
|
1992
1992
|
const A = "translate";
|
|
1993
1993
|
for (let f = 0; f < E.length; f++) {
|
|
1994
|
-
if (p = v = E[f], process.env.NODE_ENV !== "production" && n !== p && !
|
|
1994
|
+
if (p = v = E[f], process.env.NODE_ENV !== "production" && n !== p && !pa(n, p) && _t(s, t) && l(Ce(ee.FALLBACK_TO_TRANSLATE, {
|
|
1995
1995
|
key: t,
|
|
1996
1996
|
target: p
|
|
1997
1997
|
})), process.env.NODE_ENV !== "production" && n !== p) {
|
|
@@ -2004,9 +2004,9 @@ function Ta(e, t, n, a, s, r) {
|
|
|
2004
2004
|
groupId: `${A}:${t}`
|
|
2005
2005
|
});
|
|
2006
2006
|
}
|
|
2007
|
-
|
|
2007
|
+
h = o[p] || W();
|
|
2008
2008
|
let g = null, b, m;
|
|
2009
|
-
if (process.env.NODE_ENV !== "production" &&
|
|
2009
|
+
if (process.env.NODE_ENV !== "production" && fe && (g = window.performance.now(), b = "intlify-message-resolve-start", m = "intlify-message-resolve-end", ae && ae(b)), (S = u(h, t)) === null && (S = h[t]), process.env.NODE_ENV !== "production" && fe) {
|
|
2010
2010
|
const O = window.performance.now(), y = e.__v_emitter;
|
|
2011
2011
|
y && g && S && y.emit("message-resolve", {
|
|
2012
2012
|
type: "message-resolve",
|
|
@@ -2031,9 +2031,9 @@ function Ta(e, t, n, a, s, r) {
|
|
|
2031
2031
|
}
|
|
2032
2032
|
D = v;
|
|
2033
2033
|
}
|
|
2034
|
-
return [S, p,
|
|
2034
|
+
return [S, p, h];
|
|
2035
2035
|
}
|
|
2036
|
-
function
|
|
2036
|
+
function ba(e, t, n, a, s, r) {
|
|
2037
2037
|
const { messageCompiler: o, warnHtmlMessage: l } = e;
|
|
2038
2038
|
if (oe(a)) {
|
|
2039
2039
|
const p = a;
|
|
@@ -2044,9 +2044,9 @@ function La(e, t, n, a, s, r) {
|
|
|
2044
2044
|
return p.locale = n, p.key = t, p;
|
|
2045
2045
|
}
|
|
2046
2046
|
let u = null, _, E;
|
|
2047
|
-
process.env.NODE_ENV !== "production" &&
|
|
2048
|
-
const
|
|
2049
|
-
if (process.env.NODE_ENV !== "production" &&
|
|
2047
|
+
process.env.NODE_ENV !== "production" && fe && (u = window.performance.now(), _ = "intlify-message-compilation-start", E = "intlify-message-compilation-end", ae && ae(_));
|
|
2048
|
+
const h = o(a, Fr(e, n, s, a, l, r));
|
|
2049
|
+
if (process.env.NODE_ENV !== "production" && fe) {
|
|
2050
2050
|
const p = window.performance.now(), S = e.__v_emitter;
|
|
2051
2051
|
S && u && S.emit("message-compilation", {
|
|
2052
2052
|
type: "message-compilation",
|
|
@@ -2055,13 +2055,13 @@ function La(e, t, n, a, s, r) {
|
|
|
2055
2055
|
groupId: `translate:${t}`
|
|
2056
2056
|
}), _ && E && ae && Ae && (ae(E), Ae("intlify message compilation", _, E));
|
|
2057
2057
|
}
|
|
2058
|
-
return
|
|
2058
|
+
return h.locale = n, h.key = t, h.source = a, h;
|
|
2059
2059
|
}
|
|
2060
2060
|
function Mr(e, t, n) {
|
|
2061
2061
|
let a = null, s, r;
|
|
2062
|
-
process.env.NODE_ENV !== "production" &&
|
|
2062
|
+
process.env.NODE_ENV !== "production" && fe && (a = window.performance.now(), s = "intlify-message-evaluation-start", r = "intlify-message-evaluation-end", ae && ae(s));
|
|
2063
2063
|
const o = t(n);
|
|
2064
|
-
if (process.env.NODE_ENV !== "production" &&
|
|
2064
|
+
if (process.env.NODE_ENV !== "production" && fe) {
|
|
2065
2065
|
const l = window.performance.now(), u = e.__v_emitter;
|
|
2066
2066
|
u && a && u.emit("message-evaluation", {
|
|
2067
2067
|
type: "message-evaluation",
|
|
@@ -2072,7 +2072,7 @@ function Mr(e, t, n) {
|
|
|
2072
2072
|
}
|
|
2073
2073
|
return o;
|
|
2074
2074
|
}
|
|
2075
|
-
function
|
|
2075
|
+
function $t(...e) {
|
|
2076
2076
|
const [t, n, a] = e, s = W();
|
|
2077
2077
|
if (!I(t) && !j(t) && !oe(t) && !le(t))
|
|
2078
2078
|
throw he(q.INVALID_ARGUMENT);
|
|
@@ -2115,7 +2115,7 @@ function Ur(e, t, n, a) {
|
|
|
2115
2115
|
messages: (S, D) => {
|
|
2116
2116
|
let v = o(n, S);
|
|
2117
2117
|
if (v == null && (E || D)) {
|
|
2118
|
-
const [, , A] =
|
|
2118
|
+
const [, , A] = La(
|
|
2119
2119
|
E || e,
|
|
2120
2120
|
// NOTE: if has fallbackContext, fallback to root, else if use linked, fallback to local context
|
|
2121
2121
|
S,
|
|
@@ -2128,7 +2128,7 @@ function Ur(e, t, n, a) {
|
|
|
2128
2128
|
}
|
|
2129
2129
|
if (I(v) || le(v)) {
|
|
2130
2130
|
let A = !1;
|
|
2131
|
-
const g =
|
|
2131
|
+
const g = ba(e, S, t, v, S, () => {
|
|
2132
2132
|
A = !0;
|
|
2133
2133
|
});
|
|
2134
2134
|
return A ? wn : g;
|
|
@@ -2139,21 +2139,21 @@ function Ur(e, t, n, a) {
|
|
|
2139
2139
|
}
|
|
2140
2140
|
Us();
|
|
2141
2141
|
function Vr() {
|
|
2142
|
-
return
|
|
2142
|
+
return Oa().__VUE_DEVTOOLS_GLOBAL_HOOK__;
|
|
2143
2143
|
}
|
|
2144
|
-
function
|
|
2144
|
+
function Oa() {
|
|
2145
2145
|
return typeof navigator < "u" && typeof window < "u" ? window : typeof globalThis < "u" ? globalThis : {};
|
|
2146
2146
|
}
|
|
2147
|
-
const
|
|
2148
|
-
let Pe,
|
|
2147
|
+
const $r = typeof Proxy == "function", Wr = "devtools-plugin:setup", xr = "plugin:settings:set";
|
|
2148
|
+
let Pe, Wt;
|
|
2149
2149
|
function Gr() {
|
|
2150
2150
|
var e;
|
|
2151
|
-
return Pe !== void 0 || (typeof window < "u" && window.performance ? (Pe = !0,
|
|
2151
|
+
return Pe !== void 0 || (typeof window < "u" && window.performance ? (Pe = !0, Wt = window.performance) : typeof globalThis < "u" && (!((e = globalThis.perf_hooks) === null || e === void 0) && e.performance) ? (Pe = !0, Wt = globalThis.perf_hooks.performance) : Pe = !1), Pe;
|
|
2152
2152
|
}
|
|
2153
2153
|
function Kr() {
|
|
2154
|
-
return Gr() ?
|
|
2154
|
+
return Gr() ? Wt.now() : Date.now();
|
|
2155
2155
|
}
|
|
2156
|
-
class
|
|
2156
|
+
class Hr {
|
|
2157
2157
|
constructor(t, n) {
|
|
2158
2158
|
this.target = null, this.targetQueue = [], this.onQueue = [], this.plugin = t, this.hook = n;
|
|
2159
2159
|
const a = {};
|
|
@@ -2215,12 +2215,12 @@ class Yr {
|
|
|
2215
2215
|
n.resolve(await this.target[n.method](...n.args));
|
|
2216
2216
|
}
|
|
2217
2217
|
}
|
|
2218
|
-
function
|
|
2219
|
-
const n = e, a =
|
|
2218
|
+
function Yr(e, t) {
|
|
2219
|
+
const n = e, a = Oa(), s = Vr(), r = $r && n.enableEarlyProxy;
|
|
2220
2220
|
if (s && (a.__VUE_DEVTOOLS_PLUGIN_API_AVAILABLE__ || !r))
|
|
2221
|
-
s.emit(
|
|
2221
|
+
s.emit(Wr, e, t);
|
|
2222
2222
|
else {
|
|
2223
|
-
const o = r ? new
|
|
2223
|
+
const o = r ? new Hr(n, s) : null;
|
|
2224
2224
|
(a.__VUE_DEVTOOLS_PLUGINS__ = a.__VUE_DEVTOOLS_PLUGINS__ || []).push({
|
|
2225
2225
|
pluginDescriptor: n,
|
|
2226
2226
|
setupFn: t,
|
|
@@ -2274,7 +2274,7 @@ const Xr = {
|
|
|
2274
2274
|
[G.NOT_INSTALLED_WITH_PROVIDE]: "Need to install with `provide` function",
|
|
2275
2275
|
[G.NOT_COMPATIBLE_LEGACY_VUE_I18N]: "Not compatible legacy VueI18n.",
|
|
2276
2276
|
[G.NOT_AVAILABLE_COMPOSITION_IN_LEGACY]: "Not available Compostion API in Legacy API mode. Please make sure that the legacy API mode is working properly"
|
|
2277
|
-
}, xt = /* @__PURE__ */
|
|
2277
|
+
}, xt = /* @__PURE__ */ ge("__translateVNode"), Gt = /* @__PURE__ */ ge("__datetimeParts"), Kt = /* @__PURE__ */ ge("__numberParts"), De = /* @__PURE__ */ ge("__enableEmitter"), Je = /* @__PURE__ */ ge("__disableEmitter"), Ia = ge("__setPluralRules"), va = /* @__PURE__ */ ge("__injectWithOption"), Ht = /* @__PURE__ */ ge("__dispose"), de = {
|
|
2278
2278
|
FALLBACK_TO_ROOT: mr,
|
|
2279
2279
|
// 8
|
|
2280
2280
|
NOT_FOUND_PARENT_SCOPE: 9,
|
|
@@ -2288,18 +2288,18 @@ const Xr = {
|
|
|
2288
2288
|
*/
|
|
2289
2289
|
DEPRECATE_TRANSLATE_CUSTOME_DIRECTIVE: 12
|
|
2290
2290
|
}, Jr = {
|
|
2291
|
-
[
|
|
2292
|
-
[
|
|
2293
|
-
[
|
|
2291
|
+
[de.FALLBACK_TO_ROOT]: "Fall back to {type} '{key}' with root locale.",
|
|
2292
|
+
[de.NOT_FOUND_PARENT_SCOPE]: "Not found parent scope. use the global scope.",
|
|
2293
|
+
[de.IGNORE_OBJ_FLATTEN]: "Ignore object flatten: '{key}' key has an string value",
|
|
2294
2294
|
/**
|
|
2295
2295
|
* @deprecated will be removed at vue-i18n v12
|
|
2296
2296
|
*/
|
|
2297
|
-
[
|
|
2297
|
+
[de.DEPRECATE_LEGACY_MODE]: `Legacy API mode has been deprecated in v11. Use Composition API mode instead.
|
|
2298
2298
|
About how to use the Composition API mode, see https://vue-i18n.intlify.dev/guide/advanced/composition.html`,
|
|
2299
2299
|
/**
|
|
2300
2300
|
* @deprecated will be removed at vue-i18n v12
|
|
2301
2301
|
*/
|
|
2302
|
-
[
|
|
2302
|
+
[de.DEPRECATE_TRANSLATE_CUSTOME_DIRECTIVE]: "'v-t' has been deprecated in v11. Use translate APIs ('t' or '$t') instead."
|
|
2303
2303
|
};
|
|
2304
2304
|
function Ze(e, ...t) {
|
|
2305
2305
|
return ct(Jr[e], ...t);
|
|
@@ -2308,7 +2308,7 @@ function Qe(e) {
|
|
|
2308
2308
|
if (!M(e) || le(e))
|
|
2309
2309
|
return e;
|
|
2310
2310
|
for (const t in e)
|
|
2311
|
-
if (
|
|
2311
|
+
if (ue(e, t))
|
|
2312
2312
|
if (!t.includes("."))
|
|
2313
2313
|
M(e[t]) && Qe(e[t]);
|
|
2314
2314
|
else {
|
|
@@ -2318,14 +2318,14 @@ function Qe(e) {
|
|
|
2318
2318
|
if (n[o] === "__proto__")
|
|
2319
2319
|
throw new Error(`unsafe key: ${n[o]}`);
|
|
2320
2320
|
if (n[o] in s || (s[n[o]] = W()), !M(s[n[o]])) {
|
|
2321
|
-
process.env.NODE_ENV !== "production" && Le(Ze(
|
|
2321
|
+
process.env.NODE_ENV !== "production" && Le(Ze(de.IGNORE_OBJ_FLATTEN, {
|
|
2322
2322
|
key: n[o]
|
|
2323
2323
|
})), r = !0;
|
|
2324
2324
|
break;
|
|
2325
2325
|
}
|
|
2326
2326
|
s = s[n[o]];
|
|
2327
2327
|
}
|
|
2328
|
-
if (r || (le(s) ?
|
|
2328
|
+
if (r || (le(s) ? ca.includes(n[a]) || delete e[t] : (s[n[a]] = e[t], delete e[t])), !le(s)) {
|
|
2329
2329
|
const o = s[n[a]];
|
|
2330
2330
|
M(o) && Qe(o);
|
|
2331
2331
|
}
|
|
@@ -2342,13 +2342,13 @@ function sn(e, t) {
|
|
|
2342
2342
|
I(l) && rt(JSON.parse(l), o);
|
|
2343
2343
|
}), s == null && r)
|
|
2344
2344
|
for (const l in o)
|
|
2345
|
-
|
|
2345
|
+
ue(o, l) && Qe(o[l]);
|
|
2346
2346
|
return o;
|
|
2347
2347
|
}
|
|
2348
|
-
function
|
|
2348
|
+
function ya(e) {
|
|
2349
2349
|
return e.type;
|
|
2350
2350
|
}
|
|
2351
|
-
function
|
|
2351
|
+
function Sa(e, t, n) {
|
|
2352
2352
|
let a = M(t.messages) ? t.messages : W();
|
|
2353
2353
|
"__i18nGlobal" in n && (a = sn(e.locale.value, {
|
|
2354
2354
|
messages: a,
|
|
@@ -2376,18 +2376,18 @@ function ya(e, t, n) {
|
|
|
2376
2376
|
function Vn(e) {
|
|
2377
2377
|
return re(Ba, null, e, 0);
|
|
2378
2378
|
}
|
|
2379
|
-
const
|
|
2379
|
+
const $n = "__INTLIFY_META__", Wn = () => [], Qr = () => !1;
|
|
2380
2380
|
let xn = 0;
|
|
2381
2381
|
function Gn(e) {
|
|
2382
|
-
return (t, n, a, s) => e(n, a,
|
|
2382
|
+
return (t, n, a, s) => e(n, a, Ye() || void 0, s);
|
|
2383
2383
|
}
|
|
2384
2384
|
const qr = /* @__NO_SIDE_EFFECTS__ */ () => {
|
|
2385
|
-
const e =
|
|
2385
|
+
const e = Ye();
|
|
2386
2386
|
let t = null;
|
|
2387
|
-
return e && (t =
|
|
2387
|
+
return e && (t = ya(e)[$n]) ? { [$n]: t } : null;
|
|
2388
2388
|
};
|
|
2389
2389
|
function rn(e = {}) {
|
|
2390
|
-
const { __root: t, __injectWithOption: n } = e, a = t === void 0, s = e.flatJson, r =
|
|
2390
|
+
const { __root: t, __injectWithOption: n } = e, a = t === void 0, s = e.flatJson, r = fe ? Ka : Ha;
|
|
2391
2391
|
let o = F(e.inheritLocale) ? e.inheritLocale : !0;
|
|
2392
2392
|
const l = r(
|
|
2393
2393
|
// prettier-ignore
|
|
@@ -2395,11 +2395,11 @@ function rn(e = {}) {
|
|
|
2395
2395
|
), u = r(
|
|
2396
2396
|
// prettier-ignore
|
|
2397
2397
|
t && o ? t.fallbackLocale.value : I(e.fallbackLocale) || B(e.fallbackLocale) || P(e.fallbackLocale) || e.fallbackLocale === !1 ? e.fallbackLocale : l.value
|
|
2398
|
-
), _ = r(sn(l.value, e)), E = r(P(e.datetimeFormats) ? e.datetimeFormats : { [l.value]: {} }),
|
|
2398
|
+
), _ = r(sn(l.value, e)), E = r(P(e.datetimeFormats) ? e.datetimeFormats : { [l.value]: {} }), h = r(P(e.numberFormats) ? e.numberFormats : { [l.value]: {} });
|
|
2399
2399
|
let p = t ? t.missingWarn : F(e.missingWarn) || Fe(e.missingWarn) ? e.missingWarn : !0, S = t ? t.fallbackWarn : F(e.fallbackWarn) || Fe(e.fallbackWarn) ? e.fallbackWarn : !0, D = t ? t.fallbackRoot : F(e.fallbackRoot) ? e.fallbackRoot : !0, v = !!e.fallbackFormat, A = x(e.missing) ? e.missing : null, f = x(e.missing) ? Gn(e.missing) : null, g = x(e.postTranslation) ? e.postTranslation : null, b = t ? t.warnHtmlMessage : F(e.warnHtmlMessage) ? e.warnHtmlMessage : !0, m = !!e.escapeParameter;
|
|
2400
2400
|
const O = t ? t.modifiers : P(e.modifiers) ? e.modifiers : {};
|
|
2401
|
-
let y = e.pluralRules || t && t.pluralRules,
|
|
2402
|
-
|
|
2401
|
+
let y = e.pluralRules || t && t.pluralRules, N;
|
|
2402
|
+
N = (() => {
|
|
2403
2403
|
a && An(null);
|
|
2404
2404
|
const d = {
|
|
2405
2405
|
version: Br,
|
|
@@ -2420,61 +2420,61 @@ function rn(e = {}) {
|
|
|
2420
2420
|
messageCompiler: e.messageCompiler,
|
|
2421
2421
|
__meta: { framework: "vue" }
|
|
2422
2422
|
};
|
|
2423
|
-
d.datetimeFormats = E.value, d.numberFormats =
|
|
2423
|
+
d.datetimeFormats = E.value, d.numberFormats = h.value, d.__datetimeFormatters = P(N) ? N.__datetimeFormatters : void 0, d.__numberFormatters = P(N) ? N.__numberFormatters : void 0, process.env.NODE_ENV !== "production" && (d.__v_emitter = P(N) ? N.__v_emitter : void 0);
|
|
2424
2424
|
const L = Or(d);
|
|
2425
2425
|
return a && An(L), L;
|
|
2426
|
-
})(), Ke(
|
|
2426
|
+
})(), Ke(N, l.value, u.value);
|
|
2427
2427
|
function U() {
|
|
2428
2428
|
return [
|
|
2429
2429
|
l.value,
|
|
2430
2430
|
u.value,
|
|
2431
2431
|
_.value,
|
|
2432
2432
|
E.value,
|
|
2433
|
-
|
|
2433
|
+
h.value
|
|
2434
2434
|
];
|
|
2435
2435
|
}
|
|
2436
2436
|
const X = Ge({
|
|
2437
2437
|
get: () => l.value,
|
|
2438
2438
|
set: (d) => {
|
|
2439
|
-
|
|
2439
|
+
N.locale = d, l.value = d;
|
|
2440
2440
|
}
|
|
2441
2441
|
}), ie = Ge({
|
|
2442
2442
|
get: () => u.value,
|
|
2443
2443
|
set: (d) => {
|
|
2444
|
-
|
|
2444
|
+
N.fallbackLocale = d, u.value = d, Ke(N, l.value, d);
|
|
2445
2445
|
}
|
|
2446
|
-
}), J = Ge(() => _.value), ke = /* @__PURE__ */ Ge(() => E.value), mt = /* @__PURE__ */ Ge(() =>
|
|
2446
|
+
}), J = Ge(() => _.value), ke = /* @__PURE__ */ Ge(() => E.value), mt = /* @__PURE__ */ Ge(() => h.value);
|
|
2447
2447
|
function dt() {
|
|
2448
2448
|
return x(g) ? g : null;
|
|
2449
2449
|
}
|
|
2450
2450
|
function gt(d) {
|
|
2451
|
-
g = d,
|
|
2451
|
+
g = d, N.postTranslation = d;
|
|
2452
2452
|
}
|
|
2453
2453
|
function Et() {
|
|
2454
2454
|
return A;
|
|
2455
2455
|
}
|
|
2456
2456
|
function pt(d) {
|
|
2457
|
-
d !== null && (f = Gn(d)), A = d,
|
|
2457
|
+
d !== null && (f = Gn(d)), A = d, N.missing = f;
|
|
2458
2458
|
}
|
|
2459
2459
|
function ht(d, L) {
|
|
2460
2460
|
return d !== "translate" || !L.resolvedMessage;
|
|
2461
2461
|
}
|
|
2462
|
-
const
|
|
2462
|
+
const Ee = (d, L, V, Y, ve, et) => {
|
|
2463
2463
|
U();
|
|
2464
2464
|
let Re;
|
|
2465
2465
|
try {
|
|
2466
|
-
process.env.NODE_ENV !== "production" || __INTLIFY_PROD_DEVTOOLS__, a || (
|
|
2466
|
+
process.env.NODE_ENV !== "production" || __INTLIFY_PROD_DEVTOOLS__, a || (N.fallbackContext = t ? br() : void 0), Re = d(N);
|
|
2467
2467
|
} finally {
|
|
2468
|
-
process.env.NODE_ENV !== "production" || __INTLIFY_PROD_DEVTOOLS__, a || (
|
|
2468
|
+
process.env.NODE_ENV !== "production" || __INTLIFY_PROD_DEVTOOLS__, a || (N.fallbackContext = void 0);
|
|
2469
2469
|
}
|
|
2470
2470
|
if (V !== "translate exists" && // for not `te` (e.g `t`)
|
|
2471
2471
|
j(Re) && Re === ft || V === "translate exists" && !Re) {
|
|
2472
|
-
const [ye,
|
|
2473
|
-
if (process.env.NODE_ENV !== "production" && t && I(ye) && ht(V,
|
|
2472
|
+
const [ye, Ua] = L();
|
|
2473
|
+
if (process.env.NODE_ENV !== "production" && t && I(ye) && ht(V, Ua) && (D && (_t(S, ye) || Ea(p, ye)) && Le(Ze(de.FALLBACK_TO_ROOT, {
|
|
2474
2474
|
key: ye,
|
|
2475
2475
|
type: V
|
|
2476
2476
|
})), process.env.NODE_ENV !== "production")) {
|
|
2477
|
-
const { __v_emitter: fn } =
|
|
2477
|
+
const { __v_emitter: fn } = N;
|
|
2478
2478
|
fn && D && fn.emit("fallback", {
|
|
2479
2479
|
type: V,
|
|
2480
2480
|
key: ye,
|
|
@@ -2482,7 +2482,7 @@ function rn(e = {}) {
|
|
|
2482
2482
|
groupId: `${V}:${ye}`
|
|
2483
2483
|
});
|
|
2484
2484
|
}
|
|
2485
|
-
return t && D ?
|
|
2485
|
+
return t && D ? Y(t) : ve(ye);
|
|
2486
2486
|
} else {
|
|
2487
2487
|
if (et(Re))
|
|
2488
2488
|
return Re;
|
|
@@ -2490,19 +2490,19 @@ function rn(e = {}) {
|
|
|
2490
2490
|
}
|
|
2491
2491
|
};
|
|
2492
2492
|
function Ve(...d) {
|
|
2493
|
-
return
|
|
2493
|
+
return Ee((L) => Reflect.apply(Un, null, [L, ...d]), () => $t(...d), "translate", (L) => Reflect.apply(L.t, L, [...d]), (L) => L, (L) => I(L));
|
|
2494
2494
|
}
|
|
2495
2495
|
function Nt(...d) {
|
|
2496
|
-
const [L, V,
|
|
2497
|
-
if (
|
|
2496
|
+
const [L, V, Y] = d;
|
|
2497
|
+
if (Y && !M(Y))
|
|
2498
2498
|
throw te(G.INVALID_ARGUMENT);
|
|
2499
|
-
return Ve(L, V, Q({ resolvedMessage: !0 },
|
|
2499
|
+
return Ve(L, V, Q({ resolvedMessage: !0 }, Y || {}));
|
|
2500
2500
|
}
|
|
2501
2501
|
function Tt(...d) {
|
|
2502
|
-
return
|
|
2502
|
+
return Ee((L) => Reflect.apply(kn, null, [L, ...d]), () => Ut(...d), "datetime format", (L) => Reflect.apply(L.d, L, [...d]), () => ot, (L) => I(L));
|
|
2503
2503
|
}
|
|
2504
2504
|
function Lt(...d) {
|
|
2505
|
-
return
|
|
2505
|
+
return Ee((L) => Reflect.apply(Pn, null, [L, ...d]), () => Vt(...d), "number format", (L) => Reflect.apply(L.n, L, [...d]), () => ot, (L) => I(L));
|
|
2506
2506
|
}
|
|
2507
2507
|
function bt(d) {
|
|
2508
2508
|
return d.map((L) => I(L) || j(L) || F(L) ? Vn(String(L)) : L);
|
|
@@ -2513,39 +2513,39 @@ function rn(e = {}) {
|
|
|
2513
2513
|
type: "vnode"
|
|
2514
2514
|
};
|
|
2515
2515
|
function ze(...d) {
|
|
2516
|
-
return
|
|
2516
|
+
return Ee((L) => {
|
|
2517
2517
|
let V;
|
|
2518
|
-
const
|
|
2518
|
+
const Y = L;
|
|
2519
2519
|
try {
|
|
2520
|
-
|
|
2520
|
+
Y.processor = Ot, V = Reflect.apply(Un, null, [Y, ...d]);
|
|
2521
2521
|
} finally {
|
|
2522
|
-
|
|
2522
|
+
Y.processor = null;
|
|
2523
2523
|
}
|
|
2524
2524
|
return V;
|
|
2525
|
-
}, () =>
|
|
2525
|
+
}, () => $t(...d), "translate", (L) => L[xt](...d), (L) => [Vn(L)], (L) => B(L));
|
|
2526
2526
|
}
|
|
2527
2527
|
function It(...d) {
|
|
2528
|
-
return
|
|
2528
|
+
return Ee((L) => Reflect.apply(Pn, null, [L, ...d]), () => Vt(...d), "number format", (L) => L[Kt](...d), Wn, (L) => I(L) || B(L));
|
|
2529
2529
|
}
|
|
2530
2530
|
function vt(...d) {
|
|
2531
|
-
return
|
|
2531
|
+
return Ee((L) => Reflect.apply(kn, null, [L, ...d]), () => Ut(...d), "datetime format", (L) => L[Gt](...d), Wn, (L) => I(L) || B(L));
|
|
2532
2532
|
}
|
|
2533
2533
|
function yt(d) {
|
|
2534
|
-
y = d,
|
|
2534
|
+
y = d, N.pluralRules = y;
|
|
2535
2535
|
}
|
|
2536
2536
|
function St(d, L) {
|
|
2537
|
-
return
|
|
2537
|
+
return Ee(() => {
|
|
2538
2538
|
if (!d)
|
|
2539
2539
|
return !1;
|
|
2540
|
-
const V = I(L) ? L : l.value,
|
|
2540
|
+
const V = I(L) ? L : l.value, Y = Ie(V), ve = N.messageResolver(Y, d);
|
|
2541
2541
|
return le(ve) || oe(ve) || I(ve);
|
|
2542
2542
|
}, () => [d], "translate exists", (V) => Reflect.apply(V.te, V, [d, L]), Qr, (V) => F(V));
|
|
2543
2543
|
}
|
|
2544
|
-
function
|
|
2544
|
+
function $e(d) {
|
|
2545
2545
|
let L = null;
|
|
2546
|
-
const V =
|
|
2547
|
-
for (let
|
|
2548
|
-
const ve = _.value[V[
|
|
2546
|
+
const V = ua(N, u.value, l.value);
|
|
2547
|
+
for (let Y = 0; Y < V.length; Y++) {
|
|
2548
|
+
const ve = _.value[V[Y]] || {}, et = N.messageResolver(ve, d);
|
|
2549
2549
|
if (et != null) {
|
|
2550
2550
|
L = et;
|
|
2551
2551
|
break;
|
|
@@ -2553,8 +2553,8 @@ function rn(e = {}) {
|
|
|
2553
2553
|
}
|
|
2554
2554
|
return L;
|
|
2555
2555
|
}
|
|
2556
|
-
function
|
|
2557
|
-
const L =
|
|
2556
|
+
function We(d) {
|
|
2557
|
+
const L = $e(d);
|
|
2558
2558
|
return L ?? (t ? t.tm(d) || {} : {});
|
|
2559
2559
|
}
|
|
2560
2560
|
function Ie(d) {
|
|
@@ -2563,42 +2563,42 @@ function rn(e = {}) {
|
|
|
2563
2563
|
function xe(d, L) {
|
|
2564
2564
|
if (s) {
|
|
2565
2565
|
const V = { [d]: L };
|
|
2566
|
-
for (const
|
|
2567
|
-
|
|
2566
|
+
for (const Y in V)
|
|
2567
|
+
ue(V, Y) && Qe(V[Y]);
|
|
2568
2568
|
L = V[d];
|
|
2569
2569
|
}
|
|
2570
|
-
_.value[d] = L,
|
|
2570
|
+
_.value[d] = L, N.messages = _.value;
|
|
2571
2571
|
}
|
|
2572
2572
|
function At(d, L) {
|
|
2573
2573
|
_.value[d] = _.value[d] || {};
|
|
2574
2574
|
const V = { [d]: L };
|
|
2575
2575
|
if (s)
|
|
2576
|
-
for (const
|
|
2577
|
-
|
|
2578
|
-
L = V[d], rt(L, _.value[d]),
|
|
2576
|
+
for (const Y in V)
|
|
2577
|
+
ue(V, Y) && Qe(V[Y]);
|
|
2578
|
+
L = V[d], rt(L, _.value[d]), N.messages = _.value;
|
|
2579
2579
|
}
|
|
2580
2580
|
function i(d) {
|
|
2581
2581
|
return E.value[d] || {};
|
|
2582
2582
|
}
|
|
2583
2583
|
function c(d, L) {
|
|
2584
|
-
E.value[d] = L,
|
|
2584
|
+
E.value[d] = L, N.datetimeFormats = E.value, Rn(N, d, L);
|
|
2585
2585
|
}
|
|
2586
2586
|
function T(d, L) {
|
|
2587
|
-
E.value[d] = Q(E.value[d] || {}, L),
|
|
2587
|
+
E.value[d] = Q(E.value[d] || {}, L), N.datetimeFormats = E.value, Rn(N, d, L);
|
|
2588
2588
|
}
|
|
2589
2589
|
function C(d) {
|
|
2590
|
-
return
|
|
2590
|
+
return h.value[d] || {};
|
|
2591
2591
|
}
|
|
2592
2592
|
function K(d, L) {
|
|
2593
|
-
|
|
2593
|
+
h.value[d] = L, N.numberFormats = h.value, Mn(N, d, L);
|
|
2594
2594
|
}
|
|
2595
|
-
function
|
|
2596
|
-
|
|
2595
|
+
function H(d, L) {
|
|
2596
|
+
h.value[d] = Q(h.value[d] || {}, L), N.numberFormats = h.value, Mn(N, d, L);
|
|
2597
2597
|
}
|
|
2598
|
-
xn++, t &&
|
|
2599
|
-
o && (l.value = d,
|
|
2598
|
+
xn++, t && fe && (Mt(t.locale, (d) => {
|
|
2599
|
+
o && (l.value = d, N.locale = d, Ke(N, l.value, u.value));
|
|
2600
2600
|
}), Mt(t.fallbackLocale, (d) => {
|
|
2601
|
-
o && (u.value = d,
|
|
2601
|
+
o && (u.value = d, N.fallbackLocale = d, Ke(N, l.value, u.value));
|
|
2602
2602
|
}));
|
|
2603
2603
|
const w = {
|
|
2604
2604
|
id: xn,
|
|
@@ -2608,7 +2608,7 @@ function rn(e = {}) {
|
|
|
2608
2608
|
return o;
|
|
2609
2609
|
},
|
|
2610
2610
|
set inheritLocale(d) {
|
|
2611
|
-
o = d, d && t && (l.value = t.locale.value, u.value = t.fallbackLocale.value, Ke(
|
|
2611
|
+
o = d, d && t && (l.value = t.locale.value, u.value = t.fallbackLocale.value, Ke(N, l.value, u.value));
|
|
2612
2612
|
},
|
|
2613
2613
|
get availableLocales() {
|
|
2614
2614
|
return Object.keys(_.value).sort();
|
|
@@ -2627,13 +2627,13 @@ function rn(e = {}) {
|
|
|
2627
2627
|
return p;
|
|
2628
2628
|
},
|
|
2629
2629
|
set missingWarn(d) {
|
|
2630
|
-
p = d,
|
|
2630
|
+
p = d, N.missingWarn = p;
|
|
2631
2631
|
},
|
|
2632
2632
|
get fallbackWarn() {
|
|
2633
2633
|
return S;
|
|
2634
2634
|
},
|
|
2635
2635
|
set fallbackWarn(d) {
|
|
2636
|
-
S = d,
|
|
2636
|
+
S = d, N.fallbackWarn = S;
|
|
2637
2637
|
},
|
|
2638
2638
|
get fallbackRoot() {
|
|
2639
2639
|
return D;
|
|
@@ -2645,19 +2645,19 @@ function rn(e = {}) {
|
|
|
2645
2645
|
return v;
|
|
2646
2646
|
},
|
|
2647
2647
|
set fallbackFormat(d) {
|
|
2648
|
-
v = d,
|
|
2648
|
+
v = d, N.fallbackFormat = v;
|
|
2649
2649
|
},
|
|
2650
2650
|
get warnHtmlMessage() {
|
|
2651
2651
|
return b;
|
|
2652
2652
|
},
|
|
2653
2653
|
set warnHtmlMessage(d) {
|
|
2654
|
-
b = d,
|
|
2654
|
+
b = d, N.warnHtmlMessage = d;
|
|
2655
2655
|
},
|
|
2656
2656
|
get escapeParameter() {
|
|
2657
2657
|
return m;
|
|
2658
2658
|
},
|
|
2659
2659
|
set escapeParameter(d) {
|
|
2660
|
-
m = d,
|
|
2660
|
+
m = d, N.escapeParameter = d;
|
|
2661
2661
|
},
|
|
2662
2662
|
t: Ve,
|
|
2663
2663
|
getLocaleMessage: Ie,
|
|
@@ -2667,15 +2667,15 @@ function rn(e = {}) {
|
|
|
2667
2667
|
setPostTranslationHandler: gt,
|
|
2668
2668
|
getMissingHandler: Et,
|
|
2669
2669
|
setMissingHandler: pt,
|
|
2670
|
-
[
|
|
2670
|
+
[Ia]: yt
|
|
2671
2671
|
};
|
|
2672
|
-
return w.datetimeFormats = ke, w.numberFormats = mt, w.rt = Nt, w.te = St, w.tm =
|
|
2673
|
-
|
|
2672
|
+
return w.datetimeFormats = ke, w.numberFormats = mt, w.rt = Nt, w.te = St, w.tm = We, w.d = Tt, w.n = Lt, w.getDateTimeFormat = i, w.setDateTimeFormat = c, w.mergeDateTimeFormat = T, w.getNumberFormat = C, w.setNumberFormat = K, w.mergeNumberFormat = H, w[va] = n, w[xt] = ze, w[Gt] = vt, w[Kt] = It, process.env.NODE_ENV !== "production" && (w[De] = (d) => {
|
|
2673
|
+
N.__v_emitter = d;
|
|
2674
2674
|
}, w[Je] = () => {
|
|
2675
|
-
|
|
2675
|
+
N.__v_emitter = void 0;
|
|
2676
2676
|
}), w;
|
|
2677
2677
|
}
|
|
2678
|
-
const
|
|
2678
|
+
const Aa = "vue-i18n: composer properties", Pt = {
|
|
2679
2679
|
"vue-devtools-plugin-vue-i18n": "Vue I18n DevTools",
|
|
2680
2680
|
"vue-i18n-resource-inspector": "Vue I18n DevTools",
|
|
2681
2681
|
"vue-i18n-timeline": "Vue I18n"
|
|
@@ -2684,21 +2684,21 @@ const Sa = "vue-i18n: composer properties", Pt = {
|
|
|
2684
2684
|
}, zr = {
|
|
2685
2685
|
"vue-i18n-timeline": 16764185
|
|
2686
2686
|
};
|
|
2687
|
-
let
|
|
2687
|
+
let Yt;
|
|
2688
2688
|
async function eo(e, t) {
|
|
2689
2689
|
return new Promise((n, a) => {
|
|
2690
2690
|
try {
|
|
2691
|
-
|
|
2691
|
+
Yr({
|
|
2692
2692
|
id: "vue-devtools-plugin-vue-i18n",
|
|
2693
2693
|
label: Pt["vue-devtools-plugin-vue-i18n"],
|
|
2694
2694
|
packageName: "vue-i18n",
|
|
2695
2695
|
homepage: "https://vue-i18n.intlify.dev",
|
|
2696
2696
|
logo: "https://vue-i18n.intlify.dev/vue-i18n-devtools-logo.png",
|
|
2697
|
-
componentStateTypes: [
|
|
2697
|
+
componentStateTypes: [Aa],
|
|
2698
2698
|
app: e
|
|
2699
2699
|
// eslint-disable-line @typescript-eslint/no-explicit-any
|
|
2700
2700
|
}, (s) => {
|
|
2701
|
-
|
|
2701
|
+
Yt = s, s.on.visitComponentTree(({ componentInstance: o, treeNode: l }) => {
|
|
2702
2702
|
to(o, l, t);
|
|
2703
2703
|
}), s.on.inspectComponent(({ componentInstance: o, instanceData: l }) => {
|
|
2704
2704
|
o.vnode.el && o.vnode.el.__VUE_I18N__ && l && (t.mode === "legacy" ? o.vnode.el.__VUE_I18N__ !== t.global.__composer && Kn(l, o.vnode.el.__VUE_I18N__) : Kn(l, o.vnode.el.__VUE_I18N__));
|
|
@@ -2736,14 +2736,14 @@ async function eo(e, t) {
|
|
|
2736
2736
|
}
|
|
2737
2737
|
});
|
|
2738
2738
|
}
|
|
2739
|
-
function
|
|
2739
|
+
function Ca(e) {
|
|
2740
2740
|
return e.type.name || e.type.displayName || e.type.__file || "Anonymous";
|
|
2741
2741
|
}
|
|
2742
2742
|
function to(e, t, n) {
|
|
2743
2743
|
const a = n.mode === "composition" ? n.global : n.global.__composer;
|
|
2744
2744
|
if (e && e.vnode.el && e.vnode.el.__VUE_I18N__ && e.vnode.el.__VUE_I18N__ !== a) {
|
|
2745
2745
|
const s = {
|
|
2746
|
-
label: `i18n (${
|
|
2746
|
+
label: `i18n (${Ca(e)} Scope)`,
|
|
2747
2747
|
textColor: 0,
|
|
2748
2748
|
backgroundColor: 16764185
|
|
2749
2749
|
};
|
|
@@ -2751,7 +2751,7 @@ function to(e, t, n) {
|
|
|
2751
2751
|
}
|
|
2752
2752
|
}
|
|
2753
2753
|
function Kn(e, t) {
|
|
2754
|
-
const n =
|
|
2754
|
+
const n = Aa;
|
|
2755
2755
|
e.state.push({
|
|
2756
2756
|
type: n,
|
|
2757
2757
|
key: "locale",
|
|
@@ -2826,7 +2826,7 @@ function oo(e, t) {
|
|
|
2826
2826
|
const r = t.mode === "composition" ? s : s.__composer;
|
|
2827
2827
|
n !== r && e.rootNodes.push({
|
|
2828
2828
|
id: r.id.toString(),
|
|
2829
|
-
label: `${
|
|
2829
|
+
label: `${Ca(a)} Scope`
|
|
2830
2830
|
});
|
|
2831
2831
|
}
|
|
2832
2832
|
}
|
|
@@ -2841,7 +2841,7 @@ function lo(e, t) {
|
|
|
2841
2841
|
}
|
|
2842
2842
|
return n;
|
|
2843
2843
|
}
|
|
2844
|
-
function
|
|
2844
|
+
function Da(e, t) {
|
|
2845
2845
|
if (e === "global")
|
|
2846
2846
|
return t.mode === "composition" ? t.global : t.global.__composer;
|
|
2847
2847
|
{
|
|
@@ -2850,7 +2850,7 @@ function Ca(e, t) {
|
|
|
2850
2850
|
}
|
|
2851
2851
|
}
|
|
2852
2852
|
function io(e, t) {
|
|
2853
|
-
const n =
|
|
2853
|
+
const n = Da(e.nodeId, t);
|
|
2854
2854
|
return n && (e.state = co(n)), null;
|
|
2855
2855
|
}
|
|
2856
2856
|
function co(e) {
|
|
@@ -2913,9 +2913,9 @@ function co(e) {
|
|
|
2913
2913
|
return t;
|
|
2914
2914
|
}
|
|
2915
2915
|
function qe(e, t) {
|
|
2916
|
-
if (
|
|
2916
|
+
if (Yt) {
|
|
2917
2917
|
let n;
|
|
2918
|
-
t && "groupId" in t && (n = t.groupId, delete t.groupId),
|
|
2918
|
+
t && "groupId" in t && (n = t.groupId, delete t.groupId), Yt.addTimelineEvent({
|
|
2919
2919
|
layerId: "vue-i18n-timeline",
|
|
2920
2920
|
event: {
|
|
2921
2921
|
title: e,
|
|
@@ -2929,20 +2929,20 @@ function qe(e, t) {
|
|
|
2929
2929
|
}
|
|
2930
2930
|
}
|
|
2931
2931
|
function uo(e, t) {
|
|
2932
|
-
const n =
|
|
2932
|
+
const n = Da(e.nodeId, t);
|
|
2933
2933
|
if (n) {
|
|
2934
2934
|
const [a] = e.path;
|
|
2935
2935
|
a === "locale" && I(e.state.value) ? n.locale.value = e.state.value : a === "fallbackLocale" && (I(e.state.value) || B(e.state.value) || M(e.state.value)) ? n.fallbackLocale.value = e.state.value : a === "inheritLocale" && F(e.state.value) && (n.inheritLocale = e.state.value);
|
|
2936
2936
|
}
|
|
2937
2937
|
}
|
|
2938
2938
|
function fo(e) {
|
|
2939
|
-
const t = I(e.locale) ? e.locale : Xe, n = I(e.fallbackLocale) || B(e.fallbackLocale) || P(e.fallbackLocale) || e.fallbackLocale === !1 ? e.fallbackLocale : t, a = x(e.missing) ? e.missing : void 0, s = F(e.silentTranslationWarn) || Fe(e.silentTranslationWarn) ? !e.silentTranslationWarn : !0, r = F(e.silentFallbackWarn) || Fe(e.silentFallbackWarn) ? !e.silentFallbackWarn : !0, o = F(e.fallbackRoot) ? e.fallbackRoot : !0, l = !!e.formatFallbackMessages, u = P(e.modifiers) ? e.modifiers : {}, _ = e.pluralizationRules, E = x(e.postTranslation) ? e.postTranslation : void 0,
|
|
2939
|
+
const t = I(e.locale) ? e.locale : Xe, n = I(e.fallbackLocale) || B(e.fallbackLocale) || P(e.fallbackLocale) || e.fallbackLocale === !1 ? e.fallbackLocale : t, a = x(e.missing) ? e.missing : void 0, s = F(e.silentTranslationWarn) || Fe(e.silentTranslationWarn) ? !e.silentTranslationWarn : !0, r = F(e.silentFallbackWarn) || Fe(e.silentFallbackWarn) ? !e.silentFallbackWarn : !0, o = F(e.fallbackRoot) ? e.fallbackRoot : !0, l = !!e.formatFallbackMessages, u = P(e.modifiers) ? e.modifiers : {}, _ = e.pluralizationRules, E = x(e.postTranslation) ? e.postTranslation : void 0, h = I(e.warnHtmlInMessage) ? e.warnHtmlInMessage !== "off" : !0, p = !!e.escapeParameterHtml, S = F(e.sync) ? e.sync : !0;
|
|
2940
2940
|
let D = e.messages;
|
|
2941
2941
|
if (P(e.sharedMessages)) {
|
|
2942
2942
|
const O = e.sharedMessages;
|
|
2943
|
-
D = Object.keys(O).reduce((
|
|
2944
|
-
const U =
|
|
2945
|
-
return Q(U, O[R]),
|
|
2943
|
+
D = Object.keys(O).reduce((N, R) => {
|
|
2944
|
+
const U = N[R] || (N[R] = {});
|
|
2945
|
+
return Q(U, O[R]), N;
|
|
2946
2946
|
}, D || {});
|
|
2947
2947
|
}
|
|
2948
2948
|
const { __i18n: v, __root: A, __injectWithOption: f } = e, g = e.datetimeFormats, b = e.numberFormats, m = e.flatJson;
|
|
@@ -2961,7 +2961,7 @@ function fo(e) {
|
|
|
2961
2961
|
modifiers: u,
|
|
2962
2962
|
pluralRules: _,
|
|
2963
2963
|
postTranslation: E,
|
|
2964
|
-
warnHtmlMessage:
|
|
2964
|
+
warnHtmlMessage: h,
|
|
2965
2965
|
escapeParameter: p,
|
|
2966
2966
|
messageResolver: e.messageResolver,
|
|
2967
2967
|
inheritLocale: S,
|
|
@@ -3142,14 +3142,14 @@ function Bt(e = {}) {
|
|
|
3142
3142
|
function _o(e, t, n) {
|
|
3143
3143
|
return {
|
|
3144
3144
|
beforeCreate() {
|
|
3145
|
-
const a =
|
|
3145
|
+
const a = Ye();
|
|
3146
3146
|
if (!a)
|
|
3147
3147
|
throw te(G.UNEXPECTED_ERROR);
|
|
3148
3148
|
const s = this.$options;
|
|
3149
3149
|
if (s.i18n) {
|
|
3150
3150
|
const r = s.i18n;
|
|
3151
3151
|
if (s.__i18n && (r.__i18n = s.__i18n), r.__root = t, this === this.$root)
|
|
3152
|
-
this.$i18n =
|
|
3152
|
+
this.$i18n = Hn(e, r);
|
|
3153
3153
|
else {
|
|
3154
3154
|
r.__injectWithOption = !0, r.__extender = n.__vueI18nExtend, this.$i18n = Bt(r);
|
|
3155
3155
|
const o = this.$i18n;
|
|
@@ -3157,7 +3157,7 @@ function _o(e, t, n) {
|
|
|
3157
3157
|
}
|
|
3158
3158
|
} else if (s.__i18n)
|
|
3159
3159
|
if (this === this.$root)
|
|
3160
|
-
this.$i18n =
|
|
3160
|
+
this.$i18n = Hn(e, s);
|
|
3161
3161
|
else {
|
|
3162
3162
|
this.$i18n = Bt({
|
|
3163
3163
|
__i18n: s.__i18n,
|
|
@@ -3170,7 +3170,7 @@ function _o(e, t, n) {
|
|
|
3170
3170
|
}
|
|
3171
3171
|
else
|
|
3172
3172
|
this.$i18n = e;
|
|
3173
|
-
s.__i18nGlobal &&
|
|
3173
|
+
s.__i18nGlobal && Sa(t, s, s), this.$t = (...r) => this.$i18n.t(...r), this.$rt = (...r) => this.$i18n.rt(...r), this.$te = (r, o) => this.$i18n.te(r, o), 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);
|
|
3174
3174
|
},
|
|
3175
3175
|
mounted() {
|
|
3176
3176
|
if (process.env.NODE_ENV !== "production" && this.$el && this.$i18n) {
|
|
@@ -3181,7 +3181,7 @@ function _o(e, t, n) {
|
|
|
3181
3181
|
}
|
|
3182
3182
|
},
|
|
3183
3183
|
unmounted() {
|
|
3184
|
-
const a =
|
|
3184
|
+
const a = Ye();
|
|
3185
3185
|
if (!a)
|
|
3186
3186
|
throw te(G.UNEXPECTED_ERROR);
|
|
3187
3187
|
const s = this.$i18n;
|
|
@@ -3189,8 +3189,8 @@ function _o(e, t, n) {
|
|
|
3189
3189
|
}
|
|
3190
3190
|
};
|
|
3191
3191
|
}
|
|
3192
|
-
function
|
|
3193
|
-
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[
|
|
3192
|
+
function Hn(e, t) {
|
|
3193
|
+
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[Ia](t.pluralizationRules || e.pluralizationRules);
|
|
3194
3194
|
const n = sn(e.locale, {
|
|
3195
3195
|
messages: t.messages,
|
|
3196
3196
|
__i18n: t.__i18n
|
|
@@ -3225,7 +3225,7 @@ function mo({ slots: e }, t) {
|
|
|
3225
3225
|
return s && (n[a] = s()), n;
|
|
3226
3226
|
}, W());
|
|
3227
3227
|
}
|
|
3228
|
-
function
|
|
3228
|
+
function ka() {
|
|
3229
3229
|
return Jt;
|
|
3230
3230
|
}
|
|
3231
3231
|
const go = /* @__PURE__ */ Xt({
|
|
@@ -3249,17 +3249,17 @@ const go = /* @__PURE__ */ Xt({
|
|
|
3249
3249
|
__useComponent: !0
|
|
3250
3250
|
});
|
|
3251
3251
|
return () => {
|
|
3252
|
-
const r = Object.keys(n).filter((
|
|
3252
|
+
const r = Object.keys(n).filter((h) => h !== "_"), o = W();
|
|
3253
3253
|
e.locale && (o.locale = e.locale), e.plural !== void 0 && (o.plural = I(e.plural) ? +e.plural : e.plural);
|
|
3254
|
-
const l = mo(t, r), u = s[xt](e.keypath, l, o), _ = Q(W(), a), E = I(e.tag) || M(e.tag) ? e.tag :
|
|
3255
|
-
return
|
|
3254
|
+
const l = mo(t, r), u = s[xt](e.keypath, l, o), _ = Q(W(), a), E = I(e.tag) || M(e.tag) ? e.tag : ka();
|
|
3255
|
+
return zn(E, _, u);
|
|
3256
3256
|
};
|
|
3257
3257
|
}
|
|
3258
|
-
}),
|
|
3258
|
+
}), Yn = go;
|
|
3259
3259
|
function Eo(e) {
|
|
3260
3260
|
return B(e) && !I(e[0]);
|
|
3261
3261
|
}
|
|
3262
|
-
function
|
|
3262
|
+
function Ra(e, t, n, a) {
|
|
3263
3263
|
const { slots: s, attrs: r } = t;
|
|
3264
3264
|
return () => {
|
|
3265
3265
|
const o = { part: !0 };
|
|
@@ -3271,8 +3271,8 @@ function ka(e, t, n, a) {
|
|
|
3271
3271
|
const D = s[p.type], v = D ? D({ [p.type]: p.value, index: S, parts: u }) : [p.value];
|
|
3272
3272
|
return Eo(v) && (v[0].key = `${p.type}-${S}`), v;
|
|
3273
3273
|
}) : I(u) && (_ = [u]);
|
|
3274
|
-
const E = Q(W(), r),
|
|
3275
|
-
return
|
|
3274
|
+
const E = Q(W(), r), h = I(e.tag) || M(e.tag) ? e.tag : ka();
|
|
3275
|
+
return zn(h, E, _);
|
|
3276
3276
|
};
|
|
3277
3277
|
}
|
|
3278
3278
|
const po = /* @__PURE__ */ Xt({
|
|
@@ -3294,7 +3294,7 @@ const po = /* @__PURE__ */ Xt({
|
|
|
3294
3294
|
useScope: e.scope,
|
|
3295
3295
|
__useComponent: !0
|
|
3296
3296
|
});
|
|
3297
|
-
return
|
|
3297
|
+
return Ra(e, t, Ta, (...a) => (
|
|
3298
3298
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
3299
3299
|
n[Kt](...a)
|
|
3300
3300
|
));
|
|
@@ -3311,7 +3311,7 @@ function ho(e, t) {
|
|
|
3311
3311
|
}
|
|
3312
3312
|
function No(e) {
|
|
3313
3313
|
const t = (o) => {
|
|
3314
|
-
process.env.NODE_ENV !== "production" && Zt(Ze(
|
|
3314
|
+
process.env.NODE_ENV !== "production" && Zt(Ze(de.DEPRECATE_TRANSLATE_CUSTOME_DIRECTIVE));
|
|
3315
3315
|
const { instance: l, value: u } = o;
|
|
3316
3316
|
if (!l || !l.$)
|
|
3317
3317
|
throw te(G.UNEXPECTED_ERROR);
|
|
@@ -3324,12 +3324,12 @@ function No(e) {
|
|
|
3324
3324
|
return {
|
|
3325
3325
|
created: (o, l) => {
|
|
3326
3326
|
const [u, _] = t(l);
|
|
3327
|
-
|
|
3327
|
+
fe && e.global === _ && (o.__i18nWatcher = Mt(_.locale, () => {
|
|
3328
3328
|
l.instance && l.instance.$forceUpdate();
|
|
3329
3329
|
})), o.__composer = _, o.textContent = u;
|
|
3330
3330
|
},
|
|
3331
3331
|
unmounted: (o) => {
|
|
3332
|
-
|
|
3332
|
+
fe && o.__i18nWatcher && (o.__i18nWatcher(), o.__i18nWatcher = void 0, delete o.__i18nWatcher), o.__composer && (o.__composer = void 0, delete o.__composer);
|
|
3333
3333
|
},
|
|
3334
3334
|
beforeUpdate: (o, { value: l }) => {
|
|
3335
3335
|
if (o.__composer) {
|
|
@@ -3361,21 +3361,21 @@ function Xn(e) {
|
|
|
3361
3361
|
}
|
|
3362
3362
|
function To(e, t, ...n) {
|
|
3363
3363
|
const a = P(n[0]) ? n[0] : {};
|
|
3364
|
-
(F(a.globalInstall) ? a.globalInstall : !0) && ([
|
|
3364
|
+
(F(a.globalInstall) ? a.globalInstall : !0) && ([Yn.name, "I18nT"].forEach((r) => e.component(r, Yn)), [Bn.name, "I18nN"].forEach((r) => e.component(r, Bn)), [Qn.name, "I18nD"].forEach((r) => e.component(r, Qn))), e.directive("t", No(t));
|
|
3365
3365
|
}
|
|
3366
|
-
const Lo = /* @__PURE__ */
|
|
3366
|
+
const Lo = /* @__PURE__ */ ge("global-vue-i18n");
|
|
3367
3367
|
function bo(e = {}) {
|
|
3368
3368
|
const t = __VUE_I18N_LEGACY_API__ && F(e.legacy) ? e.legacy : __VUE_I18N_LEGACY_API__;
|
|
3369
|
-
process.env.NODE_ENV !== "production" && t && Zt(Ze(
|
|
3370
|
-
const n = F(e.globalInjection) ? e.globalInjection : !0, a = /* @__PURE__ */ new Map(), [s, r] = Oo(e, t), o = /* @__PURE__ */
|
|
3371
|
-
function l(
|
|
3372
|
-
return a.get(
|
|
3369
|
+
process.env.NODE_ENV !== "production" && t && Zt(Ze(de.DEPRECATE_LEGACY_MODE));
|
|
3370
|
+
const n = F(e.globalInjection) ? e.globalInjection : !0, a = /* @__PURE__ */ new Map(), [s, r] = Oo(e, t), o = /* @__PURE__ */ ge(process.env.NODE_ENV !== "production" ? "vue-i18n" : "");
|
|
3371
|
+
function l(h) {
|
|
3372
|
+
return a.get(h) || null;
|
|
3373
3373
|
}
|
|
3374
|
-
function u(
|
|
3375
|
-
a.set(
|
|
3374
|
+
function u(h, p) {
|
|
3375
|
+
a.set(h, p);
|
|
3376
3376
|
}
|
|
3377
|
-
function _(
|
|
3378
|
-
a.delete(
|
|
3377
|
+
function _(h) {
|
|
3378
|
+
a.delete(h);
|
|
3379
3379
|
}
|
|
3380
3380
|
const E = {
|
|
3381
3381
|
// mode
|
|
@@ -3383,18 +3383,18 @@ function bo(e = {}) {
|
|
|
3383
3383
|
return __VUE_I18N_LEGACY_API__ && t ? "legacy" : "composition";
|
|
3384
3384
|
},
|
|
3385
3385
|
// install plugin
|
|
3386
|
-
async install(
|
|
3387
|
-
if (process.env.NODE_ENV !== "production" && (
|
|
3386
|
+
async install(h, ...p) {
|
|
3387
|
+
if (process.env.NODE_ENV !== "production" && (h.__VUE_I18N__ = E), h.__VUE_I18N_SYMBOL__ = o, h.provide(h.__VUE_I18N_SYMBOL__, E), P(p[0])) {
|
|
3388
3388
|
const v = p[0];
|
|
3389
3389
|
E.__composerExtend = v.__composerExtend, E.__vueI18nExtend = v.__vueI18nExtend;
|
|
3390
3390
|
}
|
|
3391
3391
|
let S = null;
|
|
3392
|
-
!t && n && (S = ko(
|
|
3393
|
-
const D =
|
|
3394
|
-
if (
|
|
3392
|
+
!t && n && (S = ko(h, E.global)), __VUE_I18N_FULL_INSTALL__ && To(h, E, ...p), __VUE_I18N_LEGACY_API__ && t && h.mixin(_o(r, r.__composer, E));
|
|
3393
|
+
const D = h.unmount;
|
|
3394
|
+
if (h.unmount = () => {
|
|
3395
3395
|
S && S(), E.dispose(), D();
|
|
3396
3396
|
}, process.env.NODE_ENV !== "production") {
|
|
3397
|
-
if (!await eo(
|
|
3397
|
+
if (!await eo(h, E))
|
|
3398
3398
|
throw te(G.CANNOT_SETUP_VUE_DEVTOOLS_PLUGIN);
|
|
3399
3399
|
const A = zt();
|
|
3400
3400
|
if (t) {
|
|
@@ -3426,34 +3426,34 @@ function bo(e = {}) {
|
|
|
3426
3426
|
return E;
|
|
3427
3427
|
}
|
|
3428
3428
|
function cn(e = {}) {
|
|
3429
|
-
const t =
|
|
3429
|
+
const t = Ye();
|
|
3430
3430
|
if (t == null)
|
|
3431
3431
|
throw te(G.MUST_BE_CALL_SETUP_TOP);
|
|
3432
3432
|
if (!t.isCE && t.appContext.app != null && !t.appContext.app.__VUE_I18N_SYMBOL__)
|
|
3433
3433
|
throw te(G.NOT_INSTALLED);
|
|
3434
|
-
const n = Io(t), a = yo(n), s =
|
|
3434
|
+
const n = Io(t), a = yo(n), s = ya(t), r = vo(e, s);
|
|
3435
3435
|
if (r === "global")
|
|
3436
|
-
return
|
|
3436
|
+
return Sa(a, e, s), a;
|
|
3437
3437
|
if (r === "parent") {
|
|
3438
3438
|
let u = So(n, t, e.__useComponent);
|
|
3439
|
-
return u == null && (process.env.NODE_ENV !== "production" && Le(Ze(
|
|
3439
|
+
return u == null && (process.env.NODE_ENV !== "production" && Le(Ze(de.NOT_FOUND_PARENT_SCOPE)), u = a), u;
|
|
3440
3440
|
}
|
|
3441
3441
|
const o = n;
|
|
3442
3442
|
let l = o.__getInstance(t);
|
|
3443
3443
|
if (l == null) {
|
|
3444
3444
|
const u = Q({}, e);
|
|
3445
|
-
"__i18n" in s && (u.__i18n = s.__i18n), a && (u.__root = a), l = rn(u), o.__composerExtend && (l[
|
|
3445
|
+
"__i18n" in s && (u.__i18n = s.__i18n), a && (u.__root = a), l = rn(u), o.__composerExtend && (l[Ht] = o.__composerExtend(l)), Co(o, t, l), o.__setInstance(t, l);
|
|
3446
3446
|
}
|
|
3447
3447
|
return l;
|
|
3448
3448
|
}
|
|
3449
3449
|
function Oo(e, t) {
|
|
3450
|
-
const n =
|
|
3450
|
+
const n = $a(), a = __VUE_I18N_LEGACY_API__ && t ? n.run(() => Bt(e)) : n.run(() => rn(e));
|
|
3451
3451
|
if (a == null)
|
|
3452
3452
|
throw te(G.UNEXPECTED_ERROR);
|
|
3453
3453
|
return [n, a];
|
|
3454
3454
|
}
|
|
3455
3455
|
function Io(e) {
|
|
3456
|
-
const t =
|
|
3456
|
+
const t = Wa(e.isCE ? Lo : e.appContext.app.__VUE_I18N_SYMBOL__);
|
|
3457
3457
|
if (!t)
|
|
3458
3458
|
throw te(e.isCE ? G.NOT_INSTALLED_WITH_PROVIDE : G.UNEXPECTED_ERROR);
|
|
3459
3459
|
return t;
|
|
@@ -3474,7 +3474,7 @@ function So(e, t, n = !1) {
|
|
|
3474
3474
|
a = o.__getInstance(r);
|
|
3475
3475
|
else if (__VUE_I18N_LEGACY_API__) {
|
|
3476
3476
|
const l = o.__getInstance(r);
|
|
3477
|
-
l != null && (a = l.__composer, n && a && !a[
|
|
3477
|
+
l != null && (a = l.__composer, n && a && !a[va] && (a = null));
|
|
3478
3478
|
}
|
|
3479
3479
|
if (a != null || s === r)
|
|
3480
3480
|
break;
|
|
@@ -3496,8 +3496,8 @@ function Co(e, t, n) {
|
|
|
3496
3496
|
}, t), Ga(() => {
|
|
3497
3497
|
const s = n;
|
|
3498
3498
|
process.env.NODE_ENV !== "production" && t.vnode.el && t.vnode.el.__VUE_I18N__ && (a && a.off("*", qe), s[Je] && s[Je](), delete t.vnode.el.__VUE_I18N__), e.__deleteInstance(t);
|
|
3499
|
-
const r = s[
|
|
3500
|
-
r && (r(), delete s[
|
|
3499
|
+
const r = s[Ht];
|
|
3500
|
+
r && (r(), delete s[Ht]);
|
|
3501
3501
|
}, t);
|
|
3502
3502
|
}
|
|
3503
3503
|
const Do = [
|
|
@@ -3511,7 +3511,7 @@ function ko(e, t) {
|
|
|
3511
3511
|
const r = Object.getOwnPropertyDescriptor(t, s);
|
|
3512
3512
|
if (!r)
|
|
3513
3513
|
throw te(G.UNEXPECTED_ERROR);
|
|
3514
|
-
const o =
|
|
3514
|
+
const o = Ya(r.value) ? {
|
|
3515
3515
|
get() {
|
|
3516
3516
|
return r.value.value;
|
|
3517
3517
|
},
|
|
@@ -3555,7 +3555,7 @@ const Ro = /* @__PURE__ */ Xt({
|
|
|
3555
3555
|
useScope: e.scope,
|
|
3556
3556
|
__useComponent: !0
|
|
3557
3557
|
});
|
|
3558
|
-
return
|
|
3558
|
+
return Ra(e, t, Na, (...a) => (
|
|
3559
3559
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
3560
3560
|
n[Gt](...a)
|
|
3561
3561
|
));
|
|
@@ -3564,7 +3564,7 @@ const Ro = /* @__PURE__ */ Xt({
|
|
|
3564
3564
|
jr();
|
|
3565
3565
|
pr(Js);
|
|
3566
3566
|
hr(_r);
|
|
3567
|
-
Nr(
|
|
3567
|
+
Nr(ua);
|
|
3568
3568
|
if (process.env.NODE_ENV !== "production" || __INTLIFY_PROD_DEVTOOLS__) {
|
|
3569
3569
|
const e = Se();
|
|
3570
3570
|
e.__INTLIFY__ = !0, Qs(e.__INTLIFY_DEVTOOLS_GLOBAL_HOOK__);
|
|
@@ -3575,10 +3575,13 @@ const Po = (e) => {
|
|
|
3575
3575
|
for (const n of e)
|
|
3576
3576
|
t[n.key] = n.value;
|
|
3577
3577
|
return t;
|
|
3578
|
-
}, Mo = (e, t) => (t.forEach((
|
|
3579
|
-
|
|
3580
|
-
|
|
3581
|
-
|
|
3578
|
+
}, Mo = (e, t, n) => (t.forEach((a) => {
|
|
3579
|
+
console.log("obj2.key ", a.key);
|
|
3580
|
+
const s = a.key.split(".");
|
|
3581
|
+
s[0] === "common" && $.find(e, { key: `${n}.${s[1]}` }) && $.remove(e, { key: `${n}.${s[1]}` });
|
|
3582
|
+
const r = $.find(e, { key: a.key });
|
|
3583
|
+
r ? $.merge(r, a) : e.push(a);
|
|
3584
|
+
}), e), Pa = async ({ baseUrl: e, token: t }) => it.get(e + "/i18n-web/sysoption/getsupportedlangs", {
|
|
3582
3585
|
headers: {
|
|
3583
3586
|
Authorization: t
|
|
3584
3587
|
}
|
|
@@ -3619,32 +3622,37 @@ const Po = (e) => {
|
|
|
3619
3622
|
baseUrl: e,
|
|
3620
3623
|
appCode: t,
|
|
3621
3624
|
language: n = "zh-CN",
|
|
3622
|
-
token: a
|
|
3623
|
-
|
|
3624
|
-
|
|
3625
|
+
token: a,
|
|
3626
|
+
routerName: s
|
|
3627
|
+
}) => new Promise(async (r, o) => {
|
|
3628
|
+
const l = ce.namespace(`I18N_${$.toUpper(t)}`), u = {
|
|
3625
3629
|
baseUrl: e,
|
|
3626
3630
|
appCode: t,
|
|
3627
3631
|
language: n,
|
|
3628
3632
|
token: a
|
|
3629
|
-
},
|
|
3630
|
-
if (!
|
|
3631
|
-
const
|
|
3632
|
-
|
|
3633
|
+
}, _ = l.get(n);
|
|
3634
|
+
if (!_ || !_.lastPullDate) {
|
|
3635
|
+
const E = await qn(u);
|
|
3636
|
+
E && (l.set(n, E), r(E.translatesDTOs));
|
|
3633
3637
|
} else {
|
|
3634
|
-
const { lastPullDate:
|
|
3635
|
-
...
|
|
3636
|
-
lastPullDate:
|
|
3638
|
+
const { lastPullDate: E } = _, h = await qn({
|
|
3639
|
+
...u,
|
|
3640
|
+
lastPullDate: E
|
|
3637
3641
|
});
|
|
3638
|
-
if (
|
|
3639
|
-
const
|
|
3640
|
-
if ($.isEmpty(
|
|
3641
|
-
|
|
3642
|
+
if (h) {
|
|
3643
|
+
const p = $.get(_, "translatesDTOs");
|
|
3644
|
+
if ($.isEmpty(h.translatesDTOs))
|
|
3645
|
+
r(p);
|
|
3642
3646
|
else {
|
|
3643
|
-
const
|
|
3644
|
-
|
|
3645
|
-
translatesDTOs
|
|
3647
|
+
const S = Mo(
|
|
3648
|
+
p,
|
|
3649
|
+
h.translatesDTOs,
|
|
3650
|
+
s
|
|
3651
|
+
), D = {
|
|
3652
|
+
lastPullDate: h.lastPullDate,
|
|
3653
|
+
translatesDTOs: S
|
|
3646
3654
|
};
|
|
3647
|
-
|
|
3655
|
+
ce.namespace(`I18N_${$.toUpper(t)}`).set(n, D, ":"), r(S);
|
|
3648
3656
|
}
|
|
3649
3657
|
}
|
|
3650
3658
|
}
|
|
@@ -3716,10 +3724,10 @@ const Po = (e) => {
|
|
|
3716
3724
|
onOnChange: (u) => {
|
|
3717
3725
|
const _ = u.target.value, {
|
|
3718
3726
|
dictKey: E
|
|
3719
|
-
} = s,
|
|
3727
|
+
} = s, h = $.findIndex(this.mySaveData, {
|
|
3720
3728
|
dictKey: E
|
|
3721
3729
|
});
|
|
3722
|
-
|
|
3730
|
+
h > -1 ? this.mySaveData[h][n] = _ : this.mySaveData.push({
|
|
3723
3731
|
...s,
|
|
3724
3732
|
[n]: _,
|
|
3725
3733
|
page: this.type === "loginData" ? this.loginRouteName : this.type === "pageData" ? this.name : "common"
|
|
@@ -3733,6 +3741,7 @@ const Po = (e) => {
|
|
|
3733
3741
|
},
|
|
3734
3742
|
props: {
|
|
3735
3743
|
appCode: String,
|
|
3744
|
+
router: Object,
|
|
3736
3745
|
setLanguage: Function,
|
|
3737
3746
|
token: String,
|
|
3738
3747
|
baseUrl: String,
|
|
@@ -3753,7 +3762,7 @@ const Po = (e) => {
|
|
|
3753
3762
|
methods: {
|
|
3754
3763
|
saveLanguageSetting(e) {
|
|
3755
3764
|
const t = $.map($.filter(this.languages, (n) => n.checked), "code");
|
|
3756
|
-
|
|
3765
|
+
ce.set("I18N_LANGUAGE_SETTING", t);
|
|
3757
3766
|
},
|
|
3758
3767
|
handleLanguageSettingOpen() {
|
|
3759
3768
|
this.LanguageSettingVisible = !this.LanguageSettingVisible;
|
|
@@ -3805,15 +3814,7 @@ const Po = (e) => {
|
|
|
3805
3814
|
});
|
|
3806
3815
|
a && a.data.result === 0 ? (tt.success({
|
|
3807
3816
|
content: e || a.data.msg
|
|
3808
|
-
}), this.setLanguage(), this.initialData = $.cloneDeep(this.data.datas), this.mySaveData = [],
|
|
3809
|
-
title: "是否刷新页面",
|
|
3810
|
-
onOk: () => {
|
|
3811
|
-
window.location.reload();
|
|
3812
|
-
},
|
|
3813
|
-
onCancel: () => {
|
|
3814
|
-
t && this.closeModal();
|
|
3815
|
-
}
|
|
3816
|
-
})) : tt.error({
|
|
3817
|
+
}), this.setLanguage(), this.initialData = $.cloneDeep(this.data.datas), this.mySaveData = [], this.router.go(0)) : tt.error({
|
|
3817
3818
|
content: a.data.msg || "保存失败"
|
|
3818
3819
|
});
|
|
3819
3820
|
},
|
|
@@ -3868,11 +3869,11 @@ const Po = (e) => {
|
|
|
3868
3869
|
this.loading = !1;
|
|
3869
3870
|
},
|
|
3870
3871
|
changeTab(e) {
|
|
3871
|
-
this.type = e, e === "data" ? this.search() : e === "pageData" ? this.getPageData() : e === "loginData" && this.getLoginData();
|
|
3872
|
+
this.type = e, this.mySaveData = [], e === "data" ? this.search() : e === "pageData" ? this.getPageData() : e === "loginData" && this.getLoginData();
|
|
3872
3873
|
},
|
|
3873
3874
|
async init() {
|
|
3874
|
-
let e =
|
|
3875
|
-
const t = await
|
|
3875
|
+
let e = ce.get("I18N_LANGUAGE_SETTING");
|
|
3876
|
+
const t = await Pa({
|
|
3876
3877
|
token: this.token,
|
|
3877
3878
|
baseUrl: this.baseUrl
|
|
3878
3879
|
});
|
|
@@ -3885,15 +3886,15 @@ const Po = (e) => {
|
|
|
3885
3886
|
tt.error("获取语言失败,出错了");
|
|
3886
3887
|
}
|
|
3887
3888
|
}
|
|
3888
|
-
},
|
|
3889
|
+
}, $o = (e, t) => {
|
|
3889
3890
|
const n = e.__vccOpts || e;
|
|
3890
3891
|
for (const [a, s] of t)
|
|
3891
3892
|
n[a] = s;
|
|
3892
3893
|
return n;
|
|
3893
|
-
},
|
|
3894
|
-
function
|
|
3895
|
-
const o = z("Spin"), l = z("Table"), u = z("TabPane"), _ = z("Icon"), E = z("Checkbox"),
|
|
3896
|
-
return se(),
|
|
3894
|
+
}, Wo = { key: 0 }, xo = { class: "extra" }, Go = { class: "gc_i18n_page" }, Ko = { style: { display: "flex" } };
|
|
3895
|
+
function Ho(e, t, n, a, s, r) {
|
|
3896
|
+
const o = z("Spin"), l = z("Table"), u = z("TabPane"), _ = z("Icon"), E = z("Checkbox"), h = z("DropdownItem"), p = z("DropdownMenu"), S = z("Dropdown"), D = z("Input"), v = z("Tabs"), A = z("Page"), f = z("Button"), g = z("Modal"), b = ja("click-away");
|
|
3897
|
+
return se(), _e(g, {
|
|
3897
3898
|
modelValue: s.isModalVisible,
|
|
3898
3899
|
"onUpdate:modelValue": t[4] || (t[4] = (m) => s.isModalVisible = m),
|
|
3899
3900
|
"mask-closable": !1,
|
|
@@ -3903,7 +3904,7 @@ function Yo(e, t, n, a, s, r) {
|
|
|
3903
3904
|
onOnCancel: r.closeModal
|
|
3904
3905
|
}, {
|
|
3905
3906
|
default: ne(() => [
|
|
3906
|
-
s.isModalVisible ? (se(), mn("div",
|
|
3907
|
+
s.isModalVisible ? (se(), mn("div", Wo, [
|
|
3907
3908
|
re(v, {
|
|
3908
3909
|
modelValue: s.type,
|
|
3909
3910
|
"onUpdate:modelValue": t[2] || (t[2] = (m) => s.type = m),
|
|
@@ -3913,7 +3914,7 @@ function Yo(e, t, n, a, s, r) {
|
|
|
3913
3914
|
}, {
|
|
3914
3915
|
extra: ne(() => [
|
|
3915
3916
|
Ne("div", xo, [
|
|
3916
|
-
Xa((se(),
|
|
3917
|
+
Xa((se(), _e(S, {
|
|
3917
3918
|
style: { width: "80px" },
|
|
3918
3919
|
transfer: "",
|
|
3919
3920
|
trigger: "custom",
|
|
@@ -3923,7 +3924,7 @@ function Yo(e, t, n, a, s, r) {
|
|
|
3923
3924
|
list: ne(() => [
|
|
3924
3925
|
re(p, null, {
|
|
3925
3926
|
default: ne(() => [
|
|
3926
|
-
(se(!0), mn(Jt, null, Ja(s.languages, (m) => (se(),
|
|
3927
|
+
(se(!0), mn(Jt, null, Ja(s.languages, (m) => (se(), _e(h, {
|
|
3927
3928
|
key: m.code
|
|
3928
3929
|
}, {
|
|
3929
3930
|
default: ne(() => [
|
|
@@ -3975,10 +3976,10 @@ function Yo(e, t, n, a, s, r) {
|
|
|
3975
3976
|
label: "当前页面"
|
|
3976
3977
|
}, {
|
|
3977
3978
|
default: ne(() => [
|
|
3978
|
-
s.loading ? (se(),
|
|
3979
|
+
s.loading ? (se(), _e(o, {
|
|
3979
3980
|
key: 0,
|
|
3980
3981
|
class: "gc_i18n_spin"
|
|
3981
|
-
})) : (se(),
|
|
3982
|
+
})) : (se(), _e(l, {
|
|
3982
3983
|
key: 1,
|
|
3983
3984
|
border: "",
|
|
3984
3985
|
height: 380,
|
|
@@ -3993,10 +3994,10 @@ function Yo(e, t, n, a, s, r) {
|
|
|
3993
3994
|
label: "当前应用"
|
|
3994
3995
|
}, {
|
|
3995
3996
|
default: ne(() => [
|
|
3996
|
-
s.loading ? (se(),
|
|
3997
|
+
s.loading ? (se(), _e(o, {
|
|
3997
3998
|
key: 0,
|
|
3998
3999
|
class: "gc_i18n_spin"
|
|
3999
|
-
})) : (se(),
|
|
4000
|
+
})) : (se(), _e(l, {
|
|
4000
4001
|
key: 1,
|
|
4001
4002
|
border: "",
|
|
4002
4003
|
height: 380,
|
|
@@ -4006,16 +4007,16 @@ function Yo(e, t, n, a, s, r) {
|
|
|
4006
4007
|
]),
|
|
4007
4008
|
_: 1
|
|
4008
4009
|
}),
|
|
4009
|
-
n.login ? (se(),
|
|
4010
|
+
n.login ? (se(), _e(u, {
|
|
4010
4011
|
key: 0,
|
|
4011
4012
|
name: "loginData",
|
|
4012
4013
|
label: "登录页面"
|
|
4013
4014
|
}, {
|
|
4014
4015
|
default: ne(() => [
|
|
4015
|
-
s.loading ? (se(),
|
|
4016
|
+
s.loading ? (se(), _e(o, {
|
|
4016
4017
|
key: 0,
|
|
4017
4018
|
class: "gc_i18n_spin"
|
|
4018
|
-
})) : (se(),
|
|
4019
|
+
})) : (se(), _e(l, {
|
|
4019
4020
|
key: 1,
|
|
4020
4021
|
border: "",
|
|
4021
4022
|
height: 380,
|
|
@@ -4069,7 +4070,7 @@ function Yo(e, t, n, a, s, r) {
|
|
|
4069
4070
|
_: 1
|
|
4070
4071
|
}, 8, ["modelValue", "onOnCancel"]);
|
|
4071
4072
|
}
|
|
4072
|
-
const
|
|
4073
|
+
const Yo = /* @__PURE__ */ $o(Vo, [["render", Ho], ["__scopeId", "data-v-1f438196"]]);
|
|
4073
4074
|
function jt(e) {
|
|
4074
4075
|
const t = [], n = /(?:\$t|_ctx\.\$t)\s*\(\s*(['"])([^'"]+?)\1/gs;
|
|
4075
4076
|
if (e.template) {
|
|
@@ -4119,31 +4120,31 @@ function Bo(e) {
|
|
|
4119
4120
|
});
|
|
4120
4121
|
} };
|
|
4121
4122
|
}
|
|
4122
|
-
const
|
|
4123
|
+
const Ma = function() {
|
|
4123
4124
|
return document.ontouchstart !== null ? "click" : "touchstart";
|
|
4124
|
-
}, lt = "__vue_click_away__",
|
|
4125
|
-
|
|
4125
|
+
}, lt = "__vue_click_away__", Fa = function(e, t, n) {
|
|
4126
|
+
wa(e);
|
|
4126
4127
|
let a = n.context, s = t.value, r = !1;
|
|
4127
4128
|
setTimeout(function() {
|
|
4128
4129
|
r = !0;
|
|
4129
4130
|
}, 0), e[lt] = function(o) {
|
|
4130
4131
|
if ((!e || !e.contains(o.target)) && s && r && typeof s == "function")
|
|
4131
4132
|
return s.call(a, o);
|
|
4132
|
-
}, document.addEventListener(
|
|
4133
|
-
},
|
|
4134
|
-
document.removeEventListener(
|
|
4133
|
+
}, document.addEventListener(Ma(), e[lt], !1);
|
|
4134
|
+
}, wa = function(e) {
|
|
4135
|
+
document.removeEventListener(Ma(), e[lt], !1), delete e[lt];
|
|
4135
4136
|
}, jo = function(e, t, n) {
|
|
4136
|
-
t.value !== t.oldValue &&
|
|
4137
|
+
t.value !== t.oldValue && Fa(e, t, n);
|
|
4137
4138
|
}, Xo = {
|
|
4138
4139
|
install: function(e) {
|
|
4139
4140
|
e.directive("click-away", Jo);
|
|
4140
4141
|
}
|
|
4141
4142
|
}, Jo = {
|
|
4142
|
-
mounted:
|
|
4143
|
+
mounted: Fa,
|
|
4143
4144
|
updated: jo,
|
|
4144
|
-
unmounted:
|
|
4145
|
+
unmounted: wa
|
|
4145
4146
|
};
|
|
4146
|
-
function
|
|
4147
|
+
function Zn(e) {
|
|
4147
4148
|
const t = {
|
|
4148
4149
|
alg: "HS512"
|
|
4149
4150
|
// 算法
|
|
@@ -4152,7 +4153,7 @@ function Qo(e) {
|
|
|
4152
4153
|
}, a = JSON.stringify(t), s = JSON.stringify(n);
|
|
4153
4154
|
return Za.JWS.sign("HS512", a, s, "");
|
|
4154
4155
|
}
|
|
4155
|
-
class
|
|
4156
|
+
class He {
|
|
4156
4157
|
constructor(t = {}) {
|
|
4157
4158
|
const {
|
|
4158
4159
|
router: n,
|
|
@@ -4164,7 +4165,7 @@ class Ye {
|
|
|
4164
4165
|
login: u,
|
|
4165
4166
|
keyboard: _
|
|
4166
4167
|
} = t;
|
|
4167
|
-
this.token = r ||
|
|
4168
|
+
this.token = r || Zn(o) || ce.get("I18N_TOKEN"), this.loadI18n = !0, this.appCode = a, this.router = n, this.locale = ce.get("I18N_LANGUAGE") || navigator.language || "zh-CN", this.name = "", this.messages = s || {}, this.translationKeys = [], this.translationKeySet = /* @__PURE__ */ new Set(), this.loginRouteName = l || "login", this.login = u, this.loginTranslationKeys = [], this.keyboard = _ || "shift>t", this.baseUrl = t.dev ? "https://test.ihotel.cn" : "https://trans.ihotel.cn", this.initRouterGuards(), this.initI18n(t), Va.bind(this.keyboard, (E) => {
|
|
4168
4169
|
!this.configInstance && this.name != this.loginRouteName && (this.translationKeys = Array.from(this.translationKeySet), this.configInstance = this.createModal(this.name), this.configInstance.openModal({ name: this.name }));
|
|
4169
4170
|
}), this.setupLanguageChangeListener();
|
|
4170
4171
|
}
|
|
@@ -4177,7 +4178,7 @@ class Ye {
|
|
|
4177
4178
|
}
|
|
4178
4179
|
// 初始化路由守卫
|
|
4179
4180
|
initRouterGuards() {
|
|
4180
|
-
|
|
4181
|
+
He._routerGuardRegistered || (He._routerGuardRegistered = !0, this.router.beforeEach(async (t, n, a) => {
|
|
4181
4182
|
const { language: s, token: r } = t.query;
|
|
4182
4183
|
this.configInstance && this.configInstance.closeModal(), this.name = t.name, this.translationKeySet = /* @__PURE__ */ new Set(), r && this.setToken(r), this.loadI18n && await this.setLanguage(s || this.locale), this.loadI18n = !1;
|
|
4183
4184
|
const o = this.router.getRoutes().find((l) => l.name === this.loginRouteName || l.path === `/${this.loginRouteName}`);
|
|
@@ -4212,7 +4213,7 @@ class Ye {
|
|
|
4212
4213
|
this.translationKeys = l;
|
|
4213
4214
|
}
|
|
4214
4215
|
a();
|
|
4215
|
-
}),
|
|
4216
|
+
}), He._afterEachGuardRegistered || (He._afterEachGuardRegistered = !0, this.router.afterEach(async () => {
|
|
4216
4217
|
var s, r, o;
|
|
4217
4218
|
await Qa();
|
|
4218
4219
|
const t = Array.from(this.translationKeySet), n = Array.from(
|
|
@@ -4243,35 +4244,39 @@ class Ye {
|
|
|
4243
4244
|
if (E !== _ && !$.isEmpty(E))
|
|
4244
4245
|
return E;
|
|
4245
4246
|
{
|
|
4246
|
-
const
|
|
4247
|
-
return p !==
|
|
4247
|
+
const h = `common.${a}`, p = n(h);
|
|
4248
|
+
return p !== h ? p : n(a, s);
|
|
4248
4249
|
}
|
|
4249
4250
|
} else
|
|
4250
4251
|
return n(a, s);
|
|
4252
|
+
}, globalThis.$i18nLogin = async (a) => {
|
|
4253
|
+
this.setToken(Zn(a)), this.clearI18n(), await this.setLanguage(this.locale), location.reload();
|
|
4254
|
+
}, globalThis.$i18nLogout = (a) => {
|
|
4255
|
+
this.clearI18n(), location.reload();
|
|
4251
4256
|
}, globalThis.$deepScan = function(a) {
|
|
4252
4257
|
return a;
|
|
4253
|
-
}, globalThis.$clearI18n = () => {
|
|
4254
|
-
|
|
4258
|
+
}, globalThis.$clearI18n = this.clearI18n = () => {
|
|
4259
|
+
ce.namespace(`I18N_${$.toUpper(this.appCode)}`).clearAll();
|
|
4255
4260
|
}, globalThis.$changeLocale = this.changeLocale = this.i18n.global.changeLocale = async (a) => {
|
|
4256
4261
|
await this.setLanguage(a || this.locale);
|
|
4257
4262
|
};
|
|
4258
4263
|
}
|
|
4259
4264
|
setToken(t) {
|
|
4260
|
-
this.token = t;
|
|
4265
|
+
this.token = t, ce.set("I18N_TOKEN", t);
|
|
4261
4266
|
}
|
|
4262
4267
|
async getLanguages(t = !1) {
|
|
4263
|
-
const n =
|
|
4268
|
+
const n = ce.get("I18N_LANGUAGES");
|
|
4264
4269
|
if (n && !t)
|
|
4265
4270
|
return n;
|
|
4266
4271
|
{
|
|
4267
|
-
const a = await
|
|
4272
|
+
const a = await Pa({
|
|
4268
4273
|
baseUrl: this.baseUrl,
|
|
4269
4274
|
appCode: this.appCode,
|
|
4270
4275
|
token: this.token
|
|
4271
4276
|
});
|
|
4272
4277
|
if (a.data) {
|
|
4273
4278
|
const s = $.get(a.data, "retVal");
|
|
4274
|
-
return
|
|
4279
|
+
return ce.set("I18N_LANGUAGES", s), s;
|
|
4275
4280
|
}
|
|
4276
4281
|
}
|
|
4277
4282
|
}
|
|
@@ -4281,7 +4286,8 @@ class Ye {
|
|
|
4281
4286
|
baseUrl: this.baseUrl,
|
|
4282
4287
|
appCode: this.appCode,
|
|
4283
4288
|
language: t || this.locale,
|
|
4284
|
-
token: this.token
|
|
4289
|
+
token: this.token,
|
|
4290
|
+
routerName: this.name
|
|
4285
4291
|
});
|
|
4286
4292
|
if (s) {
|
|
4287
4293
|
const r = Po(s), o = $.assign(
|
|
@@ -4291,15 +4297,16 @@ class Ye {
|
|
|
4291
4297
|
);
|
|
4292
4298
|
this.i18n.global.setLocaleMessage(t, o);
|
|
4293
4299
|
}
|
|
4294
|
-
this.locale = t, this.i18n.global.locale.value = t,
|
|
4300
|
+
this.locale = t, this.i18n.global.locale.value = t, ce.set("I18N_LANGUAGE", t), n(!0);
|
|
4295
4301
|
});
|
|
4296
4302
|
}
|
|
4297
4303
|
createModal(t) {
|
|
4298
4304
|
const n = Bo();
|
|
4299
4305
|
return n.on("closeModal", (a) => {
|
|
4300
4306
|
this.configInstance = null;
|
|
4301
|
-
}), qa(
|
|
4307
|
+
}), qa(Yo, {
|
|
4302
4308
|
appCode: this.appCode,
|
|
4309
|
+
router: this.router,
|
|
4303
4310
|
token: this.token,
|
|
4304
4311
|
setLanguage: this.setLanguage.bind(this, this.locale),
|
|
4305
4312
|
name: t || this.name,
|
|
@@ -4321,5 +4328,5 @@ class Ye {
|
|
|
4321
4328
|
}
|
|
4322
4329
|
}
|
|
4323
4330
|
export {
|
|
4324
|
-
|
|
4331
|
+
He as default
|
|
4325
4332
|
};
|