gc_i18n 1.0.1 → 1.0.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/gc_i18n.js +685 -676
- package/lib/gc_i18n.umd.cjs +12 -12
- package/package.json +3 -2
- package/packages/components/config.vue +16 -8
- package/packages/index.js +19 -11
- package/packages/libs/http.js +0 -5
- package/packages/libs/service.js +18 -14
- package/src/main.js +1 -6
- package/src/view/Home.vue +2 -2
package/lib/gc_i18n.js
CHANGED
|
@@ -1,19 +1,18 @@
|
|
|
1
1
|
import './gc_i18n.css';
|
|
2
2
|
import fn, { Message as _e } from "view-ui-plus";
|
|
3
|
-
import { effectScope as
|
|
4
|
-
import
|
|
5
|
-
import j from "lodash-es";
|
|
3
|
+
import { effectScope as kr, ref as Sr, shallowRef as Dr, computed as je, watch as Rt, isRef as Pr, defineComponent as Xt, getCurrentInstance as qe, h as Zn, Fragment as zn, inject as Rr, onMounted as Mr, onUnmounted as wr, createVNode as ue, Text as Fr, resolveComponent as fe, createBlock as er, openBlock as lt, withCtx as ve, createElementVNode as Ke, toDisplayString as Kr, createTextVNode as Mt, createElementBlock as _n, nextTick as Ur, createApp as Vr } from "vue";
|
|
4
|
+
import X from "lodash-es";
|
|
6
5
|
import Re from "axios";
|
|
7
6
|
var dn = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
|
|
8
|
-
function
|
|
7
|
+
function tr(e) {
|
|
9
8
|
return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
|
|
10
9
|
}
|
|
11
|
-
var ct = { exports: {} },
|
|
12
|
-
function
|
|
10
|
+
var ct = { exports: {} }, xr = ct.exports, mn;
|
|
11
|
+
function $r() {
|
|
13
12
|
return mn || (mn = 1, function(e, t) {
|
|
14
13
|
(function(n, r) {
|
|
15
14
|
e.exports = r();
|
|
16
|
-
})(
|
|
15
|
+
})(xr, function() {
|
|
17
16
|
function n(o) {
|
|
18
17
|
"@babel/helpers - typeof";
|
|
19
18
|
return typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? n = function(m) {
|
|
@@ -39,20 +38,20 @@ function Gr() {
|
|
|
39
38
|
return c(o) || f(o) || p(o) || N();
|
|
40
39
|
}
|
|
41
40
|
function c(o) {
|
|
42
|
-
if (Array.isArray(o)) return
|
|
41
|
+
if (Array.isArray(o)) return y(o);
|
|
43
42
|
}
|
|
44
43
|
function f(o) {
|
|
45
44
|
if (typeof Symbol < "u" && Symbol.iterator in Object(o)) return Array.from(o);
|
|
46
45
|
}
|
|
47
46
|
function p(o, m) {
|
|
48
47
|
if (o) {
|
|
49
|
-
if (typeof o == "string") return
|
|
48
|
+
if (typeof o == "string") return y(o, m);
|
|
50
49
|
var l = Object.prototype.toString.call(o).slice(8, -1);
|
|
51
50
|
if (l === "Object" && o.constructor && (l = o.constructor.name), l === "Map" || l === "Set") return Array.from(o);
|
|
52
|
-
if (l === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(l)) return
|
|
51
|
+
if (l === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(l)) return y(o, m);
|
|
53
52
|
}
|
|
54
53
|
}
|
|
55
|
-
function
|
|
54
|
+
function y(o, m) {
|
|
56
55
|
(m == null || m > o.length) && (m = o.length);
|
|
57
56
|
for (var l = 0, u = new Array(m); l < m; l++) u[l] = o[l];
|
|
58
57
|
return u;
|
|
@@ -61,7 +60,7 @@ function Gr() {
|
|
|
61
60
|
throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
62
61
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
|
|
63
62
|
}
|
|
64
|
-
var
|
|
63
|
+
var v = /* @__PURE__ */ function() {
|
|
65
64
|
function o(m) {
|
|
66
65
|
r(this, o), this.sourceStr = m, this.subCombos = o.parseComboStr(m), this.keyNames = this.subCombos.reduce(function(l, u) {
|
|
67
66
|
return l.concat(u);
|
|
@@ -111,11 +110,11 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
111
110
|
}
|
|
112
111
|
}]), o;
|
|
113
112
|
}();
|
|
114
|
-
|
|
115
|
-
for (var m =
|
|
116
|
-
l.push(
|
|
113
|
+
v.comboDeliminator = ">", v.keyDeliminator = "+", v.parseComboStr = function(o) {
|
|
114
|
+
for (var m = v._splitStr(o, v.comboDeliminator), l = [], u = 0; u < m.length; u += 1)
|
|
115
|
+
l.push(v._splitStr(m[u], v.keyDeliminator));
|
|
117
116
|
return l;
|
|
118
|
-
},
|
|
117
|
+
}, v._splitStr = function(o, m) {
|
|
119
118
|
for (var l = o, u = m, d = "", E = [], g = 0; g < l.length; g += 1)
|
|
120
119
|
g > 0 && l[g] === u && l[g - 1] !== "\\" && (E.push(d.trim()), d = "", g += 1), d += l[g];
|
|
121
120
|
return d && E.push(d.trim()), E;
|
|
@@ -136,7 +135,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
136
135
|
var d = null;
|
|
137
136
|
typeof u == "function" && (d = u, u = null);
|
|
138
137
|
var E = {
|
|
139
|
-
keyCombo: new
|
|
138
|
+
keyCombo: new v(l),
|
|
140
139
|
keyNames: u,
|
|
141
140
|
handler: d
|
|
142
141
|
};
|
|
@@ -256,7 +255,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
256
255
|
return this;
|
|
257
256
|
}
|
|
258
257
|
return this._listeners.push({
|
|
259
|
-
keyCombo: l ? new
|
|
258
|
+
keyCombo: l ? new v(l) : null,
|
|
260
259
|
pressHandler: u || null,
|
|
261
260
|
releaseHandler: d || null,
|
|
262
261
|
preventRepeat: !1,
|
|
@@ -485,12 +484,12 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
485
484
|
m.match("Mac") && (l.match("Safari") || l.match("Chrome")) ? (M = 91, B = 93) : m.match("Mac") && l.match("Opera") ? (M = 17, B = 17) : m.match("Mac") && l.match("Firefox") && (M = 224, B = 224), o.bindKeyCode(g, ["semicolon", ";"]), o.bindKeyCode(O, ["dash", "-"]), o.bindKeyCode(P, ["equal", "equalsign", "="]), o.bindKeyCode(M, ["command", "windows", "win", "super", "leftcommand", "leftwindows", "leftwin", "leftsuper"]), o.bindKeyCode(B, ["command", "windows", "win", "super", "rightcommand", "rightwindows", "rightwin", "rightsuper"]), o.setKillKey("command");
|
|
486
485
|
}
|
|
487
486
|
var k = new D();
|
|
488
|
-
return k.setLocale("us", A), k.Keyboard = D, k.Locale = C, k.KeyCombo =
|
|
487
|
+
return k.setLocale("us", A), k.Keyboard = D, k.Locale = C, k.KeyCombo = v, k;
|
|
489
488
|
});
|
|
490
489
|
}(ct)), ct.exports;
|
|
491
490
|
}
|
|
492
|
-
var
|
|
493
|
-
const
|
|
491
|
+
var Wr = $r();
|
|
492
|
+
const Gr = /* @__PURE__ */ tr(Wr);
|
|
494
493
|
/*!
|
|
495
494
|
* shared v11.1.1
|
|
496
495
|
* (c) 2025 kazuya kawaguchi
|
|
@@ -507,26 +506,26 @@ if (process.env.NODE_ENV !== "production") {
|
|
|
507
506
|
e.measure(t, n, r), e.clearMarks(n), e.clearMarks(r);
|
|
508
507
|
});
|
|
509
508
|
}
|
|
510
|
-
const
|
|
509
|
+
const Br = /\{([0-9a-zA-Z]+)\}/g;
|
|
511
510
|
function dt(e, ...t) {
|
|
512
|
-
return t.length === 1 && F(t[0]) && (t = t[0]), (!t || !t.hasOwnProperty) && (t = {}), e.replace(
|
|
511
|
+
return t.length === 1 && F(t[0]) && (t = t[0]), (!t || !t.hasOwnProperty) && (t = {}), e.replace(Br, (n, r) => t.hasOwnProperty(r) ? t[r] : "");
|
|
513
512
|
}
|
|
514
|
-
const me = (e, t = !1) => t ? Symbol.for(e) : Symbol(e),
|
|
513
|
+
const me = (e, t = !1) => t ? Symbol.for(e) : Symbol(e), Yr = (e, t, n) => Hr({ l: e, k: t, s: n }), Hr = (e) => JSON.stringify(e).replace(/\u2028/g, "\\u2028").replace(/\u2029/g, "\\u2029").replace(/\u0027/g, "\\u0027"), J = (e) => typeof e == "number" && isFinite(e), jr = (e) => qt(e) === "[object Date]", Ve = (e) => qt(e) === "[object RegExp]", mt = (e) => w(e) && Object.keys(e).length === 0, Q = Object.assign, Xr = Object.create, $ = (e = null) => Xr(e);
|
|
515
514
|
let hn;
|
|
516
515
|
const ke = () => hn || (hn = typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : typeof global < "u" ? global : $());
|
|
517
516
|
function gn(e) {
|
|
518
517
|
return e.replace(/</g, "<").replace(/>/g, ">").replace(/"/g, """).replace(/'/g, "'");
|
|
519
518
|
}
|
|
520
|
-
const
|
|
519
|
+
const qr = Object.prototype.hasOwnProperty;
|
|
521
520
|
function ae(e, t) {
|
|
522
|
-
return
|
|
521
|
+
return qr.call(e, t);
|
|
523
522
|
}
|
|
524
|
-
const
|
|
523
|
+
const q = Array.isArray, W = (e) => typeof e == "function", I = (e) => typeof e == "string", K = (e) => typeof e == "boolean", F = (e) => e !== null && typeof e == "object", Jr = (e) => F(e) && W(e.then) && W(e.catch), nr = Object.prototype.toString, qt = (e) => nr.call(e), w = (e) => qt(e) === "[object Object]", Qr = (e) => e == null ? "" : q(e) || w(e) && e.toString === nr ? JSON.stringify(e, null, 2) : String(e);
|
|
525
524
|
function Jt(e, t = "") {
|
|
526
525
|
return e.reduce((n, r, a) => a === 0 ? n + r : n + t + r, "");
|
|
527
526
|
}
|
|
528
527
|
const pn = 2;
|
|
529
|
-
function
|
|
528
|
+
function Zr(e, t = 0, n = e.length) {
|
|
530
529
|
const r = e.split(/\r?\n/);
|
|
531
530
|
let a = 0;
|
|
532
531
|
const s = [];
|
|
@@ -539,12 +538,12 @@ function es(e, t = 0, n = e.length) {
|
|
|
539
538
|
s.push(`${f}${" ".repeat(3 - String(f).length)}| ${r[c]}`);
|
|
540
539
|
const p = r[c].length;
|
|
541
540
|
if (c === i) {
|
|
542
|
-
const
|
|
543
|
-
s.push(" | " + " ".repeat(
|
|
541
|
+
const y = t - (a - p) + 1, N = Math.max(1, n > a ? p - y : n - t);
|
|
542
|
+
s.push(" | " + " ".repeat(y) + "^".repeat(N));
|
|
544
543
|
} else if (c > i) {
|
|
545
544
|
if (n > a) {
|
|
546
|
-
const
|
|
547
|
-
s.push(" | " + "^".repeat(
|
|
545
|
+
const y = Math.max(Math.min(n - a, p), 1);
|
|
546
|
+
s.push(" | " + "^".repeat(y));
|
|
548
547
|
}
|
|
549
548
|
a += p + 1;
|
|
550
549
|
}
|
|
@@ -558,10 +557,10 @@ function Ne(e, t) {
|
|
|
558
557
|
typeof console < "u" && (console.warn("[intlify] " + e), t && console.warn(t.stack));
|
|
559
558
|
}
|
|
560
559
|
const En = {};
|
|
561
|
-
function
|
|
560
|
+
function Qt(e) {
|
|
562
561
|
En[e] || (En[e] = !0, Ne(e));
|
|
563
562
|
}
|
|
564
|
-
function
|
|
563
|
+
function Zt() {
|
|
565
564
|
const e = /* @__PURE__ */ new Map();
|
|
566
565
|
return {
|
|
567
566
|
events: e,
|
|
@@ -578,7 +577,7 @@ function Qt() {
|
|
|
578
577
|
}
|
|
579
578
|
};
|
|
580
579
|
}
|
|
581
|
-
const at = (e) => !F(e) ||
|
|
580
|
+
const at = (e) => !F(e) || q(e);
|
|
582
581
|
function ut(e, t) {
|
|
583
582
|
if (at(e) || at(t))
|
|
584
583
|
throw new Error("Invalid value");
|
|
@@ -595,7 +594,7 @@ function ut(e, t) {
|
|
|
595
594
|
* (c) 2025 kazuya kawaguchi
|
|
596
595
|
* Released under the MIT License.
|
|
597
596
|
*/
|
|
598
|
-
function
|
|
597
|
+
function zr(e, t, n) {
|
|
599
598
|
return { line: e, column: t, offset: n };
|
|
600
599
|
}
|
|
601
600
|
function wt(e, t, n) {
|
|
@@ -622,7 +621,7 @@ const R = {
|
|
|
622
621
|
UNHANDLED_CODEGEN_NODE_TYPE: 15,
|
|
623
622
|
// minifier error codes
|
|
624
623
|
UNHANDLED_MINIFIER_NODE_TYPE: 16
|
|
625
|
-
},
|
|
624
|
+
}, es = 17, ts = {
|
|
626
625
|
// tokenizer error messages
|
|
627
626
|
[R.EXPECTED_TOKEN]: "Expected token: '{0}'",
|
|
628
627
|
[R.INVALID_TOKEN_IN_PLACEHOLDER]: "Invalid token in placeholder: '{0}'",
|
|
@@ -645,20 +644,20 @@ const R = {
|
|
|
645
644
|
[R.UNHANDLED_MINIFIER_NODE_TYPE]: "unhandled mimifier node type: '{0}'"
|
|
646
645
|
};
|
|
647
646
|
function $e(e, t, n = {}) {
|
|
648
|
-
const { domain: r, messages: a, args: s } = n, i = process.env.NODE_ENV !== "production" ? dt((a ||
|
|
647
|
+
const { domain: r, messages: a, args: s } = n, i = process.env.NODE_ENV !== "production" ? dt((a || ts)[e] || "", ...s || []) : e, c = new SyntaxError(String(i));
|
|
649
648
|
return c.code = e, t && (c.location = t), c.domain = r, c;
|
|
650
649
|
}
|
|
651
|
-
function
|
|
650
|
+
function ns(e) {
|
|
652
651
|
throw e;
|
|
653
652
|
}
|
|
654
|
-
const
|
|
655
|
-
`,
|
|
656
|
-
function
|
|
653
|
+
const rs = /<\/?[\w\s="/.':;#-\/]+>/, ss = (e) => rs.test(e), ge = " ", as = "\r", z = `
|
|
654
|
+
`, is = "\u2028", os = "\u2029";
|
|
655
|
+
function ls(e) {
|
|
657
656
|
const t = e;
|
|
658
657
|
let n = 0, r = 1, a = 1, s = 0;
|
|
659
|
-
const i = (g) => t[g] ===
|
|
658
|
+
const i = (g) => t[g] === as && t[g + 1] === z, c = (g) => t[g] === z, f = (g) => t[g] === os, p = (g) => t[g] === is, y = (g) => i(g) || c(g) || f(g) || p(g), N = () => n, v = () => r, C = () => a, D = () => s, A = (g) => i(g) || f(g) || p(g) ? z : t[g], k = () => A(n), o = () => A(n + s);
|
|
660
659
|
function m() {
|
|
661
|
-
return s = 0,
|
|
660
|
+
return s = 0, y(n) && (r++, a = 0), i(n) && n++, n++, a++, t[n];
|
|
662
661
|
}
|
|
663
662
|
function l() {
|
|
664
663
|
return i(n + s) && s++, s++, t[n + s];
|
|
@@ -677,7 +676,7 @@ function us(e) {
|
|
|
677
676
|
}
|
|
678
677
|
return {
|
|
679
678
|
index: N,
|
|
680
|
-
line:
|
|
679
|
+
line: v,
|
|
681
680
|
column: C,
|
|
682
681
|
peekOffset: D,
|
|
683
682
|
charAt: A,
|
|
@@ -690,9 +689,9 @@ function us(e) {
|
|
|
690
689
|
skipToPeek: E
|
|
691
690
|
};
|
|
692
691
|
}
|
|
693
|
-
const be = void 0,
|
|
694
|
-
function
|
|
695
|
-
const n = t.location !== !1, r =
|
|
692
|
+
const be = void 0, cs = ".", bn = "'", us = "tokenizer";
|
|
693
|
+
function fs(e, t = {}) {
|
|
694
|
+
const n = t.location !== !1, r = ls(e), a = () => r.index(), s = () => zr(r.line(), r.column(), r.index()), i = s(), c = a(), f = {
|
|
696
695
|
currentType: 13,
|
|
697
696
|
offset: c,
|
|
698
697
|
startLoc: i,
|
|
@@ -704,23 +703,23 @@ function ds(e, t = {}) {
|
|
|
704
703
|
braceNest: 0,
|
|
705
704
|
inLinked: !1,
|
|
706
705
|
text: ""
|
|
707
|
-
}, p = () => f, { onError:
|
|
706
|
+
}, p = () => f, { onError: y } = t;
|
|
708
707
|
function N(_, h, T, ...S) {
|
|
709
708
|
const Y = p();
|
|
710
|
-
if (h.column += T, h.offset += T,
|
|
711
|
-
const H = n ? wt(Y.startLoc, h) : null,
|
|
712
|
-
domain:
|
|
709
|
+
if (h.column += T, h.offset += T, y) {
|
|
710
|
+
const H = n ? wt(Y.startLoc, h) : null, U = $e(_, H, {
|
|
711
|
+
domain: us,
|
|
713
712
|
args: S
|
|
714
713
|
});
|
|
715
|
-
|
|
714
|
+
y(U);
|
|
716
715
|
}
|
|
717
716
|
}
|
|
718
|
-
function
|
|
717
|
+
function v(_, h, T) {
|
|
719
718
|
_.endLoc = s(), _.currentType = h;
|
|
720
719
|
const S = { type: h };
|
|
721
720
|
return n && (S.loc = wt(_.startLoc, _.endLoc)), T != null && (S.value = T), S;
|
|
722
721
|
}
|
|
723
|
-
const C = (_) =>
|
|
722
|
+
const C = (_) => v(
|
|
724
723
|
_,
|
|
725
724
|
13
|
|
726
725
|
/* TokenTypes.EOF */
|
|
@@ -817,8 +816,8 @@ function ds(e, t = {}) {
|
|
|
817
816
|
}
|
|
818
817
|
function B(_, h = !0) {
|
|
819
818
|
const T = (Y = !1, H = "") => {
|
|
820
|
-
const
|
|
821
|
-
return
|
|
819
|
+
const U = _.currentPeek();
|
|
820
|
+
return U === "{" || U === "@" || !U ? Y : U === "|" ? !(H === ge || H === z) : U === ge ? (_.peek(), T(!0, ge)) : U === z ? (_.peek(), T(!0, z)) : !0;
|
|
822
821
|
}, S = T();
|
|
823
822
|
return h && _.resetPeek(), S;
|
|
824
823
|
}
|
|
@@ -976,14 +975,14 @@ function ds(e, t = {}) {
|
|
|
976
975
|
let T = null;
|
|
977
976
|
switch (_.currentChar()) {
|
|
978
977
|
case "{":
|
|
979
|
-
return h.braceNest >= 1 && N(R.NOT_ALLOW_NEST_PLACEHOLDER, s(), 0), _.next(), T =
|
|
978
|
+
return h.braceNest >= 1 && N(R.NOT_ALLOW_NEST_PLACEHOLDER, s(), 0), _.next(), T = v(
|
|
980
979
|
h,
|
|
981
980
|
2,
|
|
982
981
|
"{"
|
|
983
982
|
/* TokenChars.BraceLeft */
|
|
984
983
|
), k(_), h.braceNest++, T;
|
|
985
984
|
case "}":
|
|
986
|
-
return h.braceNest > 0 && h.currentType === 2 && N(R.EMPTY_PLACEHOLDER, s(), 0), _.next(), T =
|
|
985
|
+
return h.braceNest > 0 && h.currentType === 2 && N(R.EMPTY_PLACEHOLDER, s(), 0), _.next(), T = v(
|
|
987
986
|
h,
|
|
988
987
|
3,
|
|
989
988
|
"}"
|
|
@@ -992,19 +991,19 @@ function ds(e, t = {}) {
|
|
|
992
991
|
case "@":
|
|
993
992
|
return h.braceNest > 0 && N(R.UNTERMINATED_CLOSING_BRACE, s(), 0), T = Ce(_, h) || C(h), h.braceNest = 0, T;
|
|
994
993
|
default: {
|
|
995
|
-
let Y = !0, H = !0,
|
|
994
|
+
let Y = !0, H = !0, U = !0;
|
|
996
995
|
if (M(_))
|
|
997
|
-
return h.braceNest > 0 && N(R.UNTERMINATED_CLOSING_BRACE, s(), 0), T =
|
|
996
|
+
return h.braceNest > 0 && N(R.UNTERMINATED_CLOSING_BRACE, s(), 0), T = v(h, 1, Be(_)), h.braceNest = 0, h.inLinked = !1, T;
|
|
998
997
|
if (h.braceNest > 0 && (h.currentType === 4 || h.currentType === 5 || h.currentType === 6))
|
|
999
998
|
return N(R.UNTERMINATED_CLOSING_BRACE, s(), 0), h.braceNest = 0, He(_, h);
|
|
1000
999
|
if (Y = l(_, h))
|
|
1001
|
-
return T =
|
|
1000
|
+
return T = v(h, 4, bt(_)), k(_), T;
|
|
1002
1001
|
if (H = u(_, h))
|
|
1003
|
-
return T =
|
|
1004
|
-
if (
|
|
1005
|
-
return T =
|
|
1006
|
-
if (!Y && !H && !
|
|
1007
|
-
return T =
|
|
1002
|
+
return T = v(h, 5, vt(_)), k(_), T;
|
|
1003
|
+
if (U = d(_, h))
|
|
1004
|
+
return T = v(h, 6, cn(_)), k(_), T;
|
|
1005
|
+
if (!Y && !H && !U)
|
|
1006
|
+
return T = v(h, 12, Lt(_)), N(R.INVALID_TOKEN_IN_PLACEHOLDER, s(), 0, T.value), k(_), T;
|
|
1008
1007
|
break;
|
|
1009
1008
|
}
|
|
1010
1009
|
}
|
|
@@ -1016,28 +1015,28 @@ function ds(e, t = {}) {
|
|
|
1016
1015
|
const Y = _.currentChar();
|
|
1017
1016
|
switch ((T === 7 || T === 8 || T === 11 || T === 9) && (Y === z || Y === ge) && N(R.INVALID_LINKED_FORMAT, s(), 0), Y) {
|
|
1018
1017
|
case "@":
|
|
1019
|
-
return _.next(), S =
|
|
1018
|
+
return _.next(), S = v(
|
|
1020
1019
|
h,
|
|
1021
1020
|
7,
|
|
1022
1021
|
"@"
|
|
1023
1022
|
/* TokenChars.LinkedAlias */
|
|
1024
1023
|
), h.inLinked = !0, S;
|
|
1025
1024
|
case ".":
|
|
1026
|
-
return k(_), _.next(),
|
|
1025
|
+
return k(_), _.next(), v(
|
|
1027
1026
|
h,
|
|
1028
1027
|
8,
|
|
1029
1028
|
"."
|
|
1030
1029
|
/* TokenChars.LinkedDot */
|
|
1031
1030
|
);
|
|
1032
1031
|
case ":":
|
|
1033
|
-
return k(_), _.next(),
|
|
1032
|
+
return k(_), _.next(), v(
|
|
1034
1033
|
h,
|
|
1035
1034
|
9,
|
|
1036
1035
|
":"
|
|
1037
1036
|
/* TokenChars.LinkedDelimiter */
|
|
1038
1037
|
);
|
|
1039
1038
|
default:
|
|
1040
|
-
return M(_) ? (S =
|
|
1039
|
+
return M(_) ? (S = v(h, 1, Be(_)), h.braceNest = 0, h.inLinked = !1, S) : E(_, h) || O(_, h) ? (k(_), Ce(_, h)) : g(_, h) ? (k(_), v(h, 11, Ot(_))) : P(_, h) ? (k(_), Y === "{" ? Ye(_, h) || S : v(h, 10, Ct(_))) : (T === 7 && N(R.INVALID_LINKED_FORMAT, s(), 0), h.braceNest = 0, h.inLinked = !1, He(_, h));
|
|
1041
1040
|
}
|
|
1042
1041
|
}
|
|
1043
1042
|
function He(_, h) {
|
|
@@ -1053,7 +1052,7 @@ function ds(e, t = {}) {
|
|
|
1053
1052
|
case "{":
|
|
1054
1053
|
return Ye(_, h) || C(h);
|
|
1055
1054
|
case "}":
|
|
1056
|
-
return N(R.UNBALANCED_CLOSING_BRACE, s(), 0), _.next(),
|
|
1055
|
+
return N(R.UNBALANCED_CLOSING_BRACE, s(), 0), _.next(), v(
|
|
1057
1056
|
h,
|
|
1058
1057
|
3,
|
|
1059
1058
|
"}"
|
|
@@ -1063,9 +1062,9 @@ function ds(e, t = {}) {
|
|
|
1063
1062
|
return Ce(_, h) || C(h);
|
|
1064
1063
|
default: {
|
|
1065
1064
|
if (M(_))
|
|
1066
|
-
return T =
|
|
1065
|
+
return T = v(h, 1, Be(_)), h.braceNest = 0, h.inLinked = !1, T;
|
|
1067
1066
|
if (B(_))
|
|
1068
|
-
return
|
|
1067
|
+
return v(h, 0, Et(_));
|
|
1069
1068
|
break;
|
|
1070
1069
|
}
|
|
1071
1070
|
}
|
|
@@ -1073,7 +1072,7 @@ function ds(e, t = {}) {
|
|
|
1073
1072
|
}
|
|
1074
1073
|
function It() {
|
|
1075
1074
|
const { currentType: _, offset: h, startLoc: T, endLoc: S } = f;
|
|
1076
|
-
return f.lastType = _, f.lastOffset = h, f.lastStartLoc = T, f.lastEndLoc = S, f.offset = a(), f.startLoc = s(), r.currentChar() === be ?
|
|
1075
|
+
return f.lastType = _, f.lastOffset = h, f.lastStartLoc = T, f.lastEndLoc = S, f.offset = a(), f.startLoc = s(), r.currentChar() === be ? v(
|
|
1077
1076
|
f,
|
|
1078
1077
|
13
|
|
1079
1078
|
/* TokenTypes.EOF */
|
|
@@ -1086,8 +1085,8 @@ function ds(e, t = {}) {
|
|
|
1086
1085
|
context: p
|
|
1087
1086
|
};
|
|
1088
1087
|
}
|
|
1089
|
-
const
|
|
1090
|
-
function
|
|
1088
|
+
const _s = "parser", ds = /(?:\\\\|\\'|\\u([0-9a-fA-F]{4})|\\U([0-9a-fA-F]{6}))/g;
|
|
1089
|
+
function ms(e, t, n) {
|
|
1091
1090
|
switch (e) {
|
|
1092
1091
|
case "\\\\":
|
|
1093
1092
|
return "\\";
|
|
@@ -1100,13 +1099,13 @@ function gs(e, t, n) {
|
|
|
1100
1099
|
}
|
|
1101
1100
|
}
|
|
1102
1101
|
}
|
|
1103
|
-
function
|
|
1102
|
+
function hs(e = {}) {
|
|
1104
1103
|
const t = e.location !== !1, { onError: n } = e;
|
|
1105
1104
|
function r(o, m, l, u, ...d) {
|
|
1106
1105
|
const E = o.currentPosition();
|
|
1107
1106
|
if (E.offset += u, E.column += u, n) {
|
|
1108
1107
|
const g = t ? wt(l, E) : null, O = $e(m, g, {
|
|
1109
|
-
domain:
|
|
1108
|
+
domain: _s,
|
|
1110
1109
|
args: d
|
|
1111
1110
|
});
|
|
1112
1111
|
n(O);
|
|
@@ -1133,9 +1132,9 @@ function ps(e = {}) {
|
|
|
1133
1132
|
}
|
|
1134
1133
|
function p(o, m) {
|
|
1135
1134
|
const l = o.context(), { lastOffset: u, lastStartLoc: d } = l, E = a(9, u, d);
|
|
1136
|
-
return E.value = m.replace(
|
|
1135
|
+
return E.value = m.replace(ds, ms), o.nextToken(), s(E, o.currentOffset(), o.currentPosition()), E;
|
|
1137
1136
|
}
|
|
1138
|
-
function
|
|
1137
|
+
function y(o) {
|
|
1139
1138
|
const m = o.nextToken(), l = o.context(), { lastOffset: u, lastStartLoc: d } = l, E = a(8, u, d);
|
|
1140
1139
|
return m.type !== 11 ? (r(o, R.UNEXPECTED_EMPTY_LINKED_MODIFIER, l.lastStartLoc, 0), E.value = "", s(E, u, d), {
|
|
1141
1140
|
nextConsumeToken: m,
|
|
@@ -1148,11 +1147,11 @@ function ps(e = {}) {
|
|
|
1148
1147
|
const l = o.context(), u = a(7, l.offset, l.startLoc);
|
|
1149
1148
|
return u.value = m, s(u, o.currentOffset(), o.currentPosition()), u;
|
|
1150
1149
|
}
|
|
1151
|
-
function
|
|
1150
|
+
function v(o) {
|
|
1152
1151
|
const m = o.context(), l = a(6, m.offset, m.startLoc);
|
|
1153
1152
|
let u = o.nextToken();
|
|
1154
1153
|
if (u.type === 8) {
|
|
1155
|
-
const d =
|
|
1154
|
+
const d = y(o);
|
|
1156
1155
|
l.modifier = d.node, u = d.nextConsumeToken || o.nextToken();
|
|
1157
1156
|
}
|
|
1158
1157
|
switch (u.type !== 9 && r(o, R.UNEXPECTED_LEXICAL_ANALYSIS, m.lastStartLoc, 0, ce(u)), u = o.nextToken(), u.type === 2 && (u = o.nextToken()), u.type) {
|
|
@@ -1201,7 +1200,7 @@ function ps(e = {}) {
|
|
|
1201
1200
|
P.value == null && r(o, R.UNEXPECTED_LEXICAL_ANALYSIS, m.lastStartLoc, 0, ce(P)), d.items.push(p(o, P.value || ""));
|
|
1202
1201
|
break;
|
|
1203
1202
|
case 7: {
|
|
1204
|
-
const M =
|
|
1203
|
+
const M = v(o);
|
|
1205
1204
|
d.items.push(M.node), E = M.nextConsumeToken || null;
|
|
1206
1205
|
break;
|
|
1207
1206
|
}
|
|
@@ -1226,7 +1225,7 @@ function ps(e = {}) {
|
|
|
1226
1225
|
return m.currentType === 13 ? d : D(o, l, u, d);
|
|
1227
1226
|
}
|
|
1228
1227
|
function k(o) {
|
|
1229
|
-
const m =
|
|
1228
|
+
const m = fs(o, Q({}, e)), l = m.context(), u = a(0, l.offset, l.startLoc);
|
|
1230
1229
|
return t && u.loc && (u.loc.source = o), u.body = A(m), e.onCacheKey && (u.cacheKey = e.onCacheKey(o)), l.currentType !== 13 && r(m, R.UNEXPECTED_LEXICAL_ANALYSIS, l.lastStartLoc, 0, o[l.offset] || ""), s(u, m.currentOffset(), m.currentPosition()), u;
|
|
1231
1230
|
}
|
|
1232
1231
|
return { parse: k };
|
|
@@ -1237,7 +1236,7 @@ function ce(e) {
|
|
|
1237
1236
|
const t = (e.value || "").replace(/\r?\n/gu, "\\n");
|
|
1238
1237
|
return t.length > 10 ? t.slice(0, 9) + "…" : t;
|
|
1239
1238
|
}
|
|
1240
|
-
function
|
|
1239
|
+
function gs(e, t = {}) {
|
|
1241
1240
|
const n = {
|
|
1242
1241
|
ast: e,
|
|
1243
1242
|
helpers: /* @__PURE__ */ new Set()
|
|
@@ -1246,9 +1245,9 @@ function Es(e, t = {}) {
|
|
|
1246
1245
|
}
|
|
1247
1246
|
function vn(e, t) {
|
|
1248
1247
|
for (let n = 0; n < e.length; n++)
|
|
1249
|
-
|
|
1248
|
+
zt(e[n], t);
|
|
1250
1249
|
}
|
|
1251
|
-
function
|
|
1250
|
+
function zt(e, t) {
|
|
1252
1251
|
switch (e.type) {
|
|
1253
1252
|
case 1:
|
|
1254
1253
|
vn(e.cases, t), t.helper(
|
|
@@ -1260,7 +1259,7 @@ function Zt(e, t) {
|
|
|
1260
1259
|
vn(e.items, t);
|
|
1261
1260
|
break;
|
|
1262
1261
|
case 6: {
|
|
1263
|
-
|
|
1262
|
+
zt(e.key, t), t.helper(
|
|
1264
1263
|
"linked"
|
|
1265
1264
|
/* HelperNameMap.LINKED */
|
|
1266
1265
|
), t.helper(
|
|
@@ -1289,16 +1288,16 @@ function Zt(e, t) {
|
|
|
1289
1288
|
break;
|
|
1290
1289
|
}
|
|
1291
1290
|
}
|
|
1292
|
-
function
|
|
1293
|
-
const n =
|
|
1291
|
+
function ps(e, t = {}) {
|
|
1292
|
+
const n = gs(e);
|
|
1294
1293
|
n.helper(
|
|
1295
1294
|
"normalize"
|
|
1296
1295
|
/* HelperNameMap.NORMALIZE */
|
|
1297
|
-
), e.body &&
|
|
1296
|
+
), e.body && zt(e.body, n);
|
|
1298
1297
|
const r = n.context();
|
|
1299
1298
|
e.helpers = Array.from(r.helpers);
|
|
1300
1299
|
}
|
|
1301
|
-
function
|
|
1300
|
+
function Es(e) {
|
|
1302
1301
|
const t = e.body;
|
|
1303
1302
|
return t.type === 2 ? yn(t) : t.cases.forEach((n) => yn(n)), e;
|
|
1304
1303
|
}
|
|
@@ -1323,25 +1322,25 @@ function yn(e) {
|
|
|
1323
1322
|
}
|
|
1324
1323
|
}
|
|
1325
1324
|
}
|
|
1326
|
-
const
|
|
1327
|
-
function
|
|
1325
|
+
const bs = "minifier";
|
|
1326
|
+
function Ue(e) {
|
|
1328
1327
|
switch (e.t = e.type, e.type) {
|
|
1329
1328
|
case 0: {
|
|
1330
1329
|
const t = e;
|
|
1331
|
-
|
|
1330
|
+
Ue(t.body), t.b = t.body, delete t.body;
|
|
1332
1331
|
break;
|
|
1333
1332
|
}
|
|
1334
1333
|
case 1: {
|
|
1335
1334
|
const t = e, n = t.cases;
|
|
1336
1335
|
for (let r = 0; r < n.length; r++)
|
|
1337
|
-
|
|
1336
|
+
Ue(n[r]);
|
|
1338
1337
|
t.c = n, delete t.cases;
|
|
1339
1338
|
break;
|
|
1340
1339
|
}
|
|
1341
1340
|
case 2: {
|
|
1342
1341
|
const t = e, n = t.items;
|
|
1343
1342
|
for (let r = 0; r < n.length; r++)
|
|
1344
|
-
|
|
1343
|
+
Ue(n[r]);
|
|
1345
1344
|
t.i = n, delete t.items, t.static && (t.s = t.static, delete t.static);
|
|
1346
1345
|
break;
|
|
1347
1346
|
}
|
|
@@ -1355,7 +1354,7 @@ function Ke(e) {
|
|
|
1355
1354
|
}
|
|
1356
1355
|
case 6: {
|
|
1357
1356
|
const t = e;
|
|
1358
|
-
|
|
1357
|
+
Ue(t.key), t.k = t.key, delete t.key, t.modifier && (Ue(t.modifier), t.m = t.modifier, delete t.modifier);
|
|
1359
1358
|
break;
|
|
1360
1359
|
}
|
|
1361
1360
|
case 5: {
|
|
@@ -1371,14 +1370,14 @@ function Ke(e) {
|
|
|
1371
1370
|
default:
|
|
1372
1371
|
if (process.env.NODE_ENV !== "production")
|
|
1373
1372
|
throw $e(R.UNHANDLED_MINIFIER_NODE_TYPE, null, {
|
|
1374
|
-
domain:
|
|
1373
|
+
domain: bs,
|
|
1375
1374
|
args: [e.type]
|
|
1376
1375
|
});
|
|
1377
1376
|
}
|
|
1378
1377
|
delete e.type;
|
|
1379
1378
|
}
|
|
1380
|
-
const
|
|
1381
|
-
function
|
|
1379
|
+
const vs = "parser";
|
|
1380
|
+
function ys(e, t) {
|
|
1382
1381
|
const { filename: n, breakLineCode: r, needIndent: a } = t, s = t.location !== !1, i = {
|
|
1383
1382
|
filename: n,
|
|
1384
1383
|
code: "",
|
|
@@ -1399,7 +1398,7 @@ function Ts(e, t) {
|
|
|
1399
1398
|
const o = k ? r : "";
|
|
1400
1399
|
f(a ? o + " ".repeat(A) : o);
|
|
1401
1400
|
}
|
|
1402
|
-
function
|
|
1401
|
+
function y(A = !0) {
|
|
1403
1402
|
const k = ++i.indentLevel;
|
|
1404
1403
|
A && p(k);
|
|
1405
1404
|
}
|
|
@@ -1407,27 +1406,27 @@ function Ts(e, t) {
|
|
|
1407
1406
|
const k = --i.indentLevel;
|
|
1408
1407
|
A && p(k);
|
|
1409
1408
|
}
|
|
1410
|
-
function
|
|
1409
|
+
function v() {
|
|
1411
1410
|
p(i.indentLevel);
|
|
1412
1411
|
}
|
|
1413
1412
|
return {
|
|
1414
1413
|
context: c,
|
|
1415
1414
|
push: f,
|
|
1416
|
-
indent:
|
|
1415
|
+
indent: y,
|
|
1417
1416
|
deindent: N,
|
|
1418
|
-
newline:
|
|
1417
|
+
newline: v,
|
|
1419
1418
|
helper: (A) => `_${A}`,
|
|
1420
1419
|
needIndent: () => i.needIndent
|
|
1421
1420
|
};
|
|
1422
1421
|
}
|
|
1423
|
-
function
|
|
1422
|
+
function Ns(e, t) {
|
|
1424
1423
|
const { helper: n } = e;
|
|
1425
1424
|
e.push(`${n(
|
|
1426
1425
|
"linked"
|
|
1427
1426
|
/* HelperNameMap.LINKED */
|
|
1428
1427
|
)}(`), xe(e, t.key), t.modifier ? (e.push(", "), xe(e, t.modifier), e.push(", _type")) : e.push(", undefined, _type"), e.push(")");
|
|
1429
1428
|
}
|
|
1430
|
-
function
|
|
1429
|
+
function Ts(e, t) {
|
|
1431
1430
|
const { helper: n, needIndent: r } = e;
|
|
1432
1431
|
e.push(`${n(
|
|
1433
1432
|
"normalize"
|
|
@@ -1438,7 +1437,7 @@ function Os(e, t) {
|
|
|
1438
1437
|
e.push(", ");
|
|
1439
1438
|
e.deindent(r()), e.push("])");
|
|
1440
1439
|
}
|
|
1441
|
-
function
|
|
1440
|
+
function Ls(e, t) {
|
|
1442
1441
|
const { helper: n, needIndent: r } = e;
|
|
1443
1442
|
if (t.cases.length > 1) {
|
|
1444
1443
|
e.push(`${n(
|
|
@@ -1451,23 +1450,23 @@ function Cs(e, t) {
|
|
|
1451
1450
|
e.deindent(r()), e.push("])");
|
|
1452
1451
|
}
|
|
1453
1452
|
}
|
|
1454
|
-
function
|
|
1453
|
+
function Os(e, t) {
|
|
1455
1454
|
t.body ? xe(e, t.body) : e.push("null");
|
|
1456
1455
|
}
|
|
1457
1456
|
function xe(e, t) {
|
|
1458
1457
|
const { helper: n } = e;
|
|
1459
1458
|
switch (t.type) {
|
|
1460
1459
|
case 0:
|
|
1461
|
-
|
|
1460
|
+
Os(e, t);
|
|
1462
1461
|
break;
|
|
1463
1462
|
case 1:
|
|
1464
|
-
|
|
1463
|
+
Ls(e, t);
|
|
1465
1464
|
break;
|
|
1466
1465
|
case 2:
|
|
1467
|
-
|
|
1466
|
+
Ts(e, t);
|
|
1468
1467
|
break;
|
|
1469
1468
|
case 6:
|
|
1470
|
-
|
|
1469
|
+
Ns(e, t);
|
|
1471
1470
|
break;
|
|
1472
1471
|
case 8:
|
|
1473
1472
|
e.push(JSON.stringify(t.value), t);
|
|
@@ -1502,21 +1501,21 @@ function xe(e, t) {
|
|
|
1502
1501
|
default:
|
|
1503
1502
|
if (process.env.NODE_ENV !== "production")
|
|
1504
1503
|
throw $e(R.UNHANDLED_CODEGEN_NODE_TYPE, null, {
|
|
1505
|
-
domain:
|
|
1504
|
+
domain: vs,
|
|
1506
1505
|
args: [t.type]
|
|
1507
1506
|
});
|
|
1508
1507
|
}
|
|
1509
1508
|
}
|
|
1510
|
-
const
|
|
1509
|
+
const Cs = (e, t = {}) => {
|
|
1511
1510
|
const n = I(t.mode) ? t.mode : "normal", r = I(t.filename) ? t.filename : "message.intl";
|
|
1512
1511
|
t.sourceMap;
|
|
1513
1512
|
const a = t.breakLineCode != null ? t.breakLineCode : n === "arrow" ? ";" : `
|
|
1514
|
-
`, s = t.needIndent ? t.needIndent : n !== "arrow", i = e.helpers || [], c =
|
|
1513
|
+
`, s = t.needIndent ? t.needIndent : n !== "arrow", i = e.helpers || [], c = ys(e, {
|
|
1515
1514
|
filename: r,
|
|
1516
1515
|
breakLineCode: a,
|
|
1517
1516
|
needIndent: s
|
|
1518
1517
|
});
|
|
1519
|
-
c.push(n === "normal" ? "function __msg__ (ctx) {" : "(ctx) => {"), c.indent(s), i.length > 0 && (c.push(`const { ${Jt(i.map((
|
|
1518
|
+
c.push(n === "normal" ? "function __msg__ (ctx) {" : "(ctx) => {"), c.indent(s), i.length > 0 && (c.push(`const { ${Jt(i.map((y) => `${y}: _${y}`), ", ")} } = ctx`), c.newline()), c.push("return "), xe(c, e), c.deindent(s), c.push("}"), delete e.helpers;
|
|
1520
1519
|
const { code: f, map: p } = c.context();
|
|
1521
1520
|
return {
|
|
1522
1521
|
ast: e,
|
|
@@ -1525,30 +1524,30 @@ const As = (e, t = {}) => {
|
|
|
1525
1524
|
// eslint-disable-line @typescript-eslint/no-explicit-any
|
|
1526
1525
|
};
|
|
1527
1526
|
};
|
|
1528
|
-
function
|
|
1529
|
-
const n = Q({}, t), r = !!n.jit, a = !!n.minify, s = n.optimize == null ? !0 : n.optimize, c =
|
|
1530
|
-
return r ? (s &&
|
|
1527
|
+
function Is(e, t = {}) {
|
|
1528
|
+
const n = Q({}, t), r = !!n.jit, a = !!n.minify, s = n.optimize == null ? !0 : n.optimize, c = hs(n).parse(e);
|
|
1529
|
+
return r ? (s && Es(c), a && Ue(c), { ast: c, code: "" }) : (ps(c, n), Cs(c, n));
|
|
1531
1530
|
}
|
|
1532
1531
|
/*!
|
|
1533
1532
|
* core-base v11.1.1
|
|
1534
1533
|
* (c) 2025 kazuya kawaguchi
|
|
1535
1534
|
* Released under the MIT License.
|
|
1536
1535
|
*/
|
|
1537
|
-
function
|
|
1536
|
+
function As() {
|
|
1538
1537
|
typeof __INTLIFY_PROD_DEVTOOLS__ != "boolean" && (ke().__INTLIFY_PROD_DEVTOOLS__ = !1), typeof __INTLIFY_DROP_MESSAGE_COMPILER__ != "boolean" && (ke().__INTLIFY_DROP_MESSAGE_COMPILER__ = !1);
|
|
1539
1538
|
}
|
|
1540
1539
|
function At(e) {
|
|
1541
|
-
return (n) =>
|
|
1540
|
+
return (n) => ks(n, e);
|
|
1542
1541
|
}
|
|
1543
|
-
function
|
|
1544
|
-
const n =
|
|
1542
|
+
function ks(e, t) {
|
|
1543
|
+
const n = Ds(t);
|
|
1545
1544
|
if (n == null)
|
|
1546
|
-
throw
|
|
1545
|
+
throw Je(
|
|
1547
1546
|
0
|
|
1548
1547
|
/* NodeTypes.Resource */
|
|
1549
1548
|
);
|
|
1550
|
-
if (
|
|
1551
|
-
const s =
|
|
1549
|
+
if (en(n) === 1) {
|
|
1550
|
+
const s = Rs(n);
|
|
1552
1551
|
return e.plural(s.reduce((i, c) => [
|
|
1553
1552
|
...i,
|
|
1554
1553
|
Nn(e, c)
|
|
@@ -1556,33 +1555,33 @@ function Ds(e, t) {
|
|
|
1556
1555
|
} else
|
|
1557
1556
|
return Nn(e, n);
|
|
1558
1557
|
}
|
|
1559
|
-
const
|
|
1560
|
-
function
|
|
1561
|
-
return Te(e,
|
|
1558
|
+
const Ss = ["b", "body"];
|
|
1559
|
+
function Ds(e) {
|
|
1560
|
+
return Te(e, Ss);
|
|
1562
1561
|
}
|
|
1563
|
-
const
|
|
1564
|
-
function
|
|
1565
|
-
return Te(e,
|
|
1562
|
+
const Ps = ["c", "cases"];
|
|
1563
|
+
function Rs(e) {
|
|
1564
|
+
return Te(e, Ps, []);
|
|
1566
1565
|
}
|
|
1567
1566
|
function Nn(e, t) {
|
|
1568
|
-
const n =
|
|
1567
|
+
const n = ws(t);
|
|
1569
1568
|
if (n != null)
|
|
1570
1569
|
return e.type === "text" ? n : e.normalize([n]);
|
|
1571
1570
|
{
|
|
1572
|
-
const r =
|
|
1571
|
+
const r = Ks(t).reduce((a, s) => [...a, Ft(e, s)], []);
|
|
1573
1572
|
return e.normalize(r);
|
|
1574
1573
|
}
|
|
1575
1574
|
}
|
|
1576
|
-
const
|
|
1577
|
-
function
|
|
1578
|
-
return Te(e,
|
|
1575
|
+
const Ms = ["s", "static"];
|
|
1576
|
+
function ws(e) {
|
|
1577
|
+
return Te(e, Ms);
|
|
1579
1578
|
}
|
|
1580
|
-
const
|
|
1581
|
-
function
|
|
1582
|
-
return Te(e,
|
|
1579
|
+
const Fs = ["i", "items"];
|
|
1580
|
+
function Ks(e) {
|
|
1581
|
+
return Te(e, Fs, []);
|
|
1583
1582
|
}
|
|
1584
1583
|
function Ft(e, t) {
|
|
1585
|
-
const n =
|
|
1584
|
+
const n = en(t);
|
|
1586
1585
|
switch (n) {
|
|
1587
1586
|
case 3:
|
|
1588
1587
|
return it(t, n);
|
|
@@ -1594,18 +1593,18 @@ function Ft(e, t) {
|
|
|
1594
1593
|
return e.interpolate(e.named(r.k));
|
|
1595
1594
|
if (ae(r, "key") && r.key)
|
|
1596
1595
|
return e.interpolate(e.named(r.key));
|
|
1597
|
-
throw
|
|
1596
|
+
throw Je(n);
|
|
1598
1597
|
}
|
|
1599
1598
|
case 5: {
|
|
1600
1599
|
const r = t;
|
|
1601
|
-
if (ae(r, "i") &&
|
|
1600
|
+
if (ae(r, "i") && J(r.i))
|
|
1602
1601
|
return e.interpolate(e.list(r.i));
|
|
1603
|
-
if (ae(r, "index") &&
|
|
1602
|
+
if (ae(r, "index") && J(r.index))
|
|
1604
1603
|
return e.interpolate(e.list(r.index));
|
|
1605
|
-
throw
|
|
1604
|
+
throw Je(n);
|
|
1606
1605
|
}
|
|
1607
1606
|
case 6: {
|
|
1608
|
-
const r = t, a =
|
|
1607
|
+
const r = t, a = $s(r), s = Gs(r);
|
|
1609
1608
|
return e.linked(Ft(e, s), a ? Ft(e, a) : void 0, e.type);
|
|
1610
1609
|
}
|
|
1611
1610
|
case 7:
|
|
@@ -1616,27 +1615,27 @@ function Ft(e, t) {
|
|
|
1616
1615
|
throw new Error(`unhandled node on format message part: ${n}`);
|
|
1617
1616
|
}
|
|
1618
1617
|
}
|
|
1619
|
-
const
|
|
1620
|
-
function
|
|
1621
|
-
return Te(e,
|
|
1618
|
+
const Us = ["t", "type"];
|
|
1619
|
+
function en(e) {
|
|
1620
|
+
return Te(e, Us);
|
|
1622
1621
|
}
|
|
1623
|
-
const
|
|
1622
|
+
const Vs = ["v", "value"];
|
|
1624
1623
|
function it(e, t) {
|
|
1625
|
-
const n = Te(e,
|
|
1624
|
+
const n = Te(e, Vs);
|
|
1626
1625
|
if (n)
|
|
1627
1626
|
return n;
|
|
1628
|
-
throw
|
|
1627
|
+
throw Je(t);
|
|
1629
1628
|
}
|
|
1630
|
-
const
|
|
1631
|
-
function
|
|
1632
|
-
return Te(e,
|
|
1629
|
+
const xs = ["m", "modifier"];
|
|
1630
|
+
function $s(e) {
|
|
1631
|
+
return Te(e, xs);
|
|
1633
1632
|
}
|
|
1634
|
-
const
|
|
1635
|
-
function
|
|
1636
|
-
const t = Te(e,
|
|
1633
|
+
const Ws = ["k", "key"];
|
|
1634
|
+
function Gs(e) {
|
|
1635
|
+
const t = Te(e, Ws);
|
|
1637
1636
|
if (t)
|
|
1638
1637
|
return t;
|
|
1639
|
-
throw
|
|
1638
|
+
throw Je(
|
|
1640
1639
|
6
|
|
1641
1640
|
/* NodeTypes.Linked */
|
|
1642
1641
|
);
|
|
@@ -1649,34 +1648,34 @@ function Te(e, t, n) {
|
|
|
1649
1648
|
}
|
|
1650
1649
|
return n;
|
|
1651
1650
|
}
|
|
1652
|
-
function
|
|
1651
|
+
function Je(e) {
|
|
1653
1652
|
return new Error(`unhandled node type: ${e}`);
|
|
1654
1653
|
}
|
|
1655
|
-
const
|
|
1656
|
-
function
|
|
1657
|
-
t &&
|
|
1654
|
+
const Bs = "Detected HTML in '{source}' message. Recommend not using HTML messages to avoid XSS.";
|
|
1655
|
+
function Ys(e, t) {
|
|
1656
|
+
t && ss(e) && Ne(dt(Bs, { source: e }));
|
|
1658
1657
|
}
|
|
1659
|
-
const
|
|
1658
|
+
const Hs = (e) => e;
|
|
1660
1659
|
let ot = $();
|
|
1661
1660
|
function ye(e) {
|
|
1662
|
-
return F(e) &&
|
|
1661
|
+
return F(e) && en(e) === 0 && (ae(e, "b") || ae(e, "body"));
|
|
1663
1662
|
}
|
|
1664
|
-
function
|
|
1663
|
+
function js(e, t = {}) {
|
|
1665
1664
|
let n = !1;
|
|
1666
|
-
const r = t.onError ||
|
|
1665
|
+
const r = t.onError || ns;
|
|
1667
1666
|
return t.onError = (a) => {
|
|
1668
1667
|
n = !0, r(a);
|
|
1669
|
-
}, { ...
|
|
1668
|
+
}, { ...Is(e, t), detectError: n };
|
|
1670
1669
|
}
|
|
1671
1670
|
// @__NO_SIDE_EFFECTS__
|
|
1672
|
-
function
|
|
1671
|
+
function Xs(e, t) {
|
|
1673
1672
|
if (!__INTLIFY_DROP_MESSAGE_COMPILER__ && I(e)) {
|
|
1674
|
-
const n =
|
|
1675
|
-
process.env.NODE_ENV !== "production" &&
|
|
1676
|
-
const a = (t.onCacheKey ||
|
|
1673
|
+
const n = K(t.warnHtmlMessage) ? t.warnHtmlMessage : !0;
|
|
1674
|
+
process.env.NODE_ENV !== "production" && Ys(e, n);
|
|
1675
|
+
const a = (t.onCacheKey || Hs)(e), s = ot[a];
|
|
1677
1676
|
if (s)
|
|
1678
1677
|
return s;
|
|
1679
|
-
const { ast: i, detectError: c } =
|
|
1678
|
+
const { ast: i, detectError: c } = js(e, {
|
|
1680
1679
|
...t,
|
|
1681
1680
|
location: process.env.NODE_ENV !== "production",
|
|
1682
1681
|
jit: !0
|
|
@@ -1694,10 +1693,10 @@ function qs(e, t) {
|
|
|
1694
1693
|
}
|
|
1695
1694
|
}
|
|
1696
1695
|
let Qe = null;
|
|
1697
|
-
function
|
|
1696
|
+
function qs(e) {
|
|
1698
1697
|
Qe = e;
|
|
1699
1698
|
}
|
|
1700
|
-
function
|
|
1699
|
+
function Js(e, t, n) {
|
|
1701
1700
|
Qe && Qe.emit("i18n:init", {
|
|
1702
1701
|
timestamp: Date.now(),
|
|
1703
1702
|
i18n: e,
|
|
@@ -1705,12 +1704,12 @@ function Zs(e, t, n) {
|
|
|
1705
1704
|
meta: n
|
|
1706
1705
|
});
|
|
1707
1706
|
}
|
|
1708
|
-
const
|
|
1709
|
-
function
|
|
1707
|
+
const Qs = /* @__PURE__ */ Zs("function:translate");
|
|
1708
|
+
function Zs(e) {
|
|
1710
1709
|
return (t) => Qe && Qe.emit(e, t);
|
|
1711
1710
|
}
|
|
1712
1711
|
const Z = {
|
|
1713
|
-
INVALID_ARGUMENT:
|
|
1712
|
+
INVALID_ARGUMENT: es,
|
|
1714
1713
|
// 17
|
|
1715
1714
|
INVALID_DATE_ARGUMENT: 18,
|
|
1716
1715
|
INVALID_ISO_DATE_ARGUMENT: 19,
|
|
@@ -1718,11 +1717,11 @@ const Z = {
|
|
|
1718
1717
|
NOT_SUPPORT_LOCALE_PROMISE_VALUE: 21,
|
|
1719
1718
|
NOT_SUPPORT_LOCALE_ASYNC_FUNCTION: 22,
|
|
1720
1719
|
NOT_SUPPORT_LOCALE_TYPE: 23
|
|
1721
|
-
},
|
|
1720
|
+
}, zs = 24;
|
|
1722
1721
|
function pe(e) {
|
|
1723
|
-
return $e(e, null, process.env.NODE_ENV !== "production" ? { messages:
|
|
1722
|
+
return $e(e, null, process.env.NODE_ENV !== "production" ? { messages: ea } : void 0);
|
|
1724
1723
|
}
|
|
1725
|
-
const
|
|
1724
|
+
const ea = {
|
|
1726
1725
|
[Z.INVALID_ARGUMENT]: "Invalid arguments",
|
|
1727
1726
|
[Z.INVALID_DATE_ARGUMENT]: "The date provided is an invalid Date object.Make sure your Date represents a valid date.",
|
|
1728
1727
|
[Z.INVALID_ISO_DATE_ARGUMENT]: "The argument provided is not a valid ISO date string",
|
|
@@ -1731,7 +1730,7 @@ const na = {
|
|
|
1731
1730
|
[Z.NOT_SUPPORT_LOCALE_ASYNC_FUNCTION]: "cannot support async function",
|
|
1732
1731
|
[Z.NOT_SUPPORT_LOCALE_TYPE]: "cannot support locale type"
|
|
1733
1732
|
};
|
|
1734
|
-
function
|
|
1733
|
+
function tn(e, t) {
|
|
1735
1734
|
return t.locale != null ? Tn(t.locale) : Tn(e.locale);
|
|
1736
1735
|
}
|
|
1737
1736
|
let kt;
|
|
@@ -1743,7 +1742,7 @@ function Tn(e) {
|
|
|
1743
1742
|
return kt;
|
|
1744
1743
|
if (e.constructor.name === "Function") {
|
|
1745
1744
|
const t = e();
|
|
1746
|
-
if (
|
|
1745
|
+
if (Jr(t))
|
|
1747
1746
|
throw pe(Z.NOT_SUPPORT_LOCALE_PROMISE_VALUE);
|
|
1748
1747
|
return kt = t;
|
|
1749
1748
|
} else
|
|
@@ -1751,49 +1750,49 @@ function Tn(e) {
|
|
|
1751
1750
|
} else
|
|
1752
1751
|
throw pe(Z.NOT_SUPPORT_LOCALE_TYPE);
|
|
1753
1752
|
}
|
|
1754
|
-
function
|
|
1753
|
+
function ta(e, t, n) {
|
|
1755
1754
|
return [.../* @__PURE__ */ new Set([
|
|
1756
1755
|
n,
|
|
1757
|
-
...
|
|
1756
|
+
...q(t) ? t : F(t) ? Object.keys(t) : I(t) ? [t] : [n]
|
|
1758
1757
|
])];
|
|
1759
1758
|
}
|
|
1760
|
-
function
|
|
1759
|
+
function rr(e, t, n) {
|
|
1761
1760
|
const r = I(n) ? n : Ze, a = e;
|
|
1762
1761
|
a.__localeChainCache || (a.__localeChainCache = /* @__PURE__ */ new Map());
|
|
1763
1762
|
let s = a.__localeChainCache.get(r);
|
|
1764
1763
|
if (!s) {
|
|
1765
1764
|
s = [];
|
|
1766
1765
|
let i = [n];
|
|
1767
|
-
for (;
|
|
1766
|
+
for (; q(i); )
|
|
1768
1767
|
i = Ln(s, i, t);
|
|
1769
|
-
const c =
|
|
1770
|
-
i = I(c) ? [c] : c,
|
|
1768
|
+
const c = q(t) || !w(t) ? t : t.default ? t.default : null;
|
|
1769
|
+
i = I(c) ? [c] : c, q(i) && Ln(s, i, !1), a.__localeChainCache.set(r, s);
|
|
1771
1770
|
}
|
|
1772
1771
|
return s;
|
|
1773
1772
|
}
|
|
1774
1773
|
function Ln(e, t, n) {
|
|
1775
1774
|
let r = !0;
|
|
1776
|
-
for (let a = 0; a < t.length &&
|
|
1775
|
+
for (let a = 0; a < t.length && K(r); a++) {
|
|
1777
1776
|
const s = t[a];
|
|
1778
|
-
I(s) && (r =
|
|
1777
|
+
I(s) && (r = na(e, t[a], n));
|
|
1779
1778
|
}
|
|
1780
1779
|
return r;
|
|
1781
1780
|
}
|
|
1782
|
-
function
|
|
1781
|
+
function na(e, t, n) {
|
|
1783
1782
|
let r;
|
|
1784
1783
|
const a = t.split("-");
|
|
1785
1784
|
do {
|
|
1786
1785
|
const s = a.join("-");
|
|
1787
|
-
r =
|
|
1786
|
+
r = ra(e, s, n), a.splice(-1, 1);
|
|
1788
1787
|
} while (a.length && r === !0);
|
|
1789
1788
|
return r;
|
|
1790
1789
|
}
|
|
1791
|
-
function
|
|
1790
|
+
function ra(e, t, n) {
|
|
1792
1791
|
let r = !1;
|
|
1793
1792
|
if (!e.includes(t) && (r = !0, t)) {
|
|
1794
1793
|
r = t[t.length - 1] !== "!";
|
|
1795
1794
|
const a = t.replace(/!/g, "");
|
|
1796
|
-
e.push(a), (
|
|
1795
|
+
e.push(a), (q(n) || w(n)) && n[a] && (r = n[a]);
|
|
1797
1796
|
}
|
|
1798
1797
|
return r;
|
|
1799
1798
|
}
|
|
@@ -1958,15 +1957,15 @@ Le[
|
|
|
1958
1957
|
/* Actions.APPEND */
|
|
1959
1958
|
]
|
|
1960
1959
|
};
|
|
1961
|
-
const
|
|
1962
|
-
function
|
|
1963
|
-
return
|
|
1960
|
+
const sa = /^\s?(?:true|false|-?[\d.]+|'[^']*'|"[^"]*")\s?$/;
|
|
1961
|
+
function aa(e) {
|
|
1962
|
+
return sa.test(e);
|
|
1964
1963
|
}
|
|
1965
|
-
function
|
|
1964
|
+
function ia(e) {
|
|
1966
1965
|
const t = e.charCodeAt(0), n = e.charCodeAt(e.length - 1);
|
|
1967
1966
|
return t === n && (t === 34 || t === 39) ? e.slice(1, -1) : e;
|
|
1968
1967
|
}
|
|
1969
|
-
function
|
|
1968
|
+
function oa(e) {
|
|
1970
1969
|
if (e == null)
|
|
1971
1970
|
return "o";
|
|
1972
1971
|
switch (e.charCodeAt(0)) {
|
|
@@ -2003,45 +2002,45 @@ function ca(e) {
|
|
|
2003
2002
|
}
|
|
2004
2003
|
return "i";
|
|
2005
2004
|
}
|
|
2006
|
-
function
|
|
2005
|
+
function la(e) {
|
|
2007
2006
|
const t = e.trim();
|
|
2008
|
-
return e.charAt(0) === "0" && isNaN(parseInt(e)) ? !1 :
|
|
2007
|
+
return e.charAt(0) === "0" && isNaN(parseInt(e)) ? !1 : aa(t) ? ia(t) : "*" + t;
|
|
2009
2008
|
}
|
|
2010
|
-
function
|
|
2009
|
+
function ca(e) {
|
|
2011
2010
|
const t = [];
|
|
2012
|
-
let n = -1, r = 0, a = 0, s, i, c, f, p,
|
|
2013
|
-
const
|
|
2014
|
-
|
|
2011
|
+
let n = -1, r = 0, a = 0, s, i, c, f, p, y, N;
|
|
2012
|
+
const v = [];
|
|
2013
|
+
v[
|
|
2015
2014
|
0
|
|
2016
2015
|
/* Actions.APPEND */
|
|
2017
2016
|
] = () => {
|
|
2018
2017
|
i === void 0 ? i = c : i += c;
|
|
2019
|
-
},
|
|
2018
|
+
}, v[
|
|
2020
2019
|
1
|
|
2021
2020
|
/* Actions.PUSH */
|
|
2022
2021
|
] = () => {
|
|
2023
2022
|
i !== void 0 && (t.push(i), i = void 0);
|
|
2024
|
-
},
|
|
2023
|
+
}, v[
|
|
2025
2024
|
2
|
|
2026
2025
|
/* Actions.INC_SUB_PATH_DEPTH */
|
|
2027
2026
|
] = () => {
|
|
2028
|
-
|
|
2027
|
+
v[
|
|
2029
2028
|
0
|
|
2030
2029
|
/* Actions.APPEND */
|
|
2031
2030
|
](), a++;
|
|
2032
|
-
},
|
|
2031
|
+
}, v[
|
|
2033
2032
|
3
|
|
2034
2033
|
/* Actions.PUSH_SUB_PATH */
|
|
2035
2034
|
] = () => {
|
|
2036
2035
|
if (a > 0)
|
|
2037
|
-
a--, r = 4,
|
|
2036
|
+
a--, r = 4, v[
|
|
2038
2037
|
0
|
|
2039
2038
|
/* Actions.APPEND */
|
|
2040
2039
|
]();
|
|
2041
2040
|
else {
|
|
2042
|
-
if (a = 0, i === void 0 || (i =
|
|
2041
|
+
if (a = 0, i === void 0 || (i = la(i), i === !1))
|
|
2043
2042
|
return !1;
|
|
2044
|
-
|
|
2043
|
+
v[
|
|
2045
2044
|
1
|
|
2046
2045
|
/* Actions.PUSH */
|
|
2047
2046
|
]();
|
|
@@ -2050,28 +2049,28 @@ function fa(e) {
|
|
|
2050
2049
|
function C() {
|
|
2051
2050
|
const D = e[n + 1];
|
|
2052
2051
|
if (r === 5 && D === "'" || r === 6 && D === '"')
|
|
2053
|
-
return n++, c = "\\" + D,
|
|
2052
|
+
return n++, c = "\\" + D, v[
|
|
2054
2053
|
0
|
|
2055
2054
|
/* Actions.APPEND */
|
|
2056
2055
|
](), !0;
|
|
2057
2056
|
}
|
|
2058
2057
|
for (; r !== null; )
|
|
2059
2058
|
if (n++, s = e[n], !(s === "\\" && C())) {
|
|
2060
|
-
if (f =
|
|
2059
|
+
if (f = oa(s), N = Le[r], p = N[f] || N.l || 8, p === 8 || (r = p[0], p[1] !== void 0 && (y = v[p[1]], y && (c = s, y() === !1))))
|
|
2061
2060
|
return;
|
|
2062
2061
|
if (r === 7)
|
|
2063
2062
|
return t;
|
|
2064
2063
|
}
|
|
2065
2064
|
}
|
|
2066
2065
|
const On = /* @__PURE__ */ new Map();
|
|
2067
|
-
function
|
|
2066
|
+
function ua(e, t) {
|
|
2068
2067
|
return F(e) ? e[t] : null;
|
|
2069
2068
|
}
|
|
2070
|
-
function
|
|
2069
|
+
function fa(e, t) {
|
|
2071
2070
|
if (!F(e))
|
|
2072
2071
|
return null;
|
|
2073
2072
|
let n = On.get(t);
|
|
2074
|
-
if (n || (n =
|
|
2073
|
+
if (n || (n = ca(t), n && On.set(t, n)), !n)
|
|
2075
2074
|
return null;
|
|
2076
2075
|
const r = n.length;
|
|
2077
2076
|
let a = e, s = 0;
|
|
@@ -2091,7 +2090,7 @@ const te = {
|
|
|
2091
2090
|
CANNOT_FORMAT_DATE: 5,
|
|
2092
2091
|
FALLBACK_TO_DATE_FORMAT: 6,
|
|
2093
2092
|
EXPERIMENTAL_CUSTOM_MESSAGE_COMPILER: 7
|
|
2094
|
-
},
|
|
2093
|
+
}, _a = 8, da = {
|
|
2095
2094
|
[te.NOT_FOUND_KEY]: "Not found '{key}' key in '{locale}' locale messages.",
|
|
2096
2095
|
[te.FALLBACK_TO_TRANSLATE]: "Fall back to translate '{key}' key with '{target}' locale.",
|
|
2097
2096
|
[te.CANNOT_FORMAT_NUMBER]: "Cannot format a number value due to not supported Intl.NumberFormat.",
|
|
@@ -2101,41 +2100,41 @@ const te = {
|
|
|
2101
2100
|
[te.EXPERIMENTAL_CUSTOM_MESSAGE_COMPILER]: "This project is using Custom Message Compiler, which is an experimental feature. It may receive breaking changes or be removed in the future."
|
|
2102
2101
|
};
|
|
2103
2102
|
function De(e, ...t) {
|
|
2104
|
-
return dt(
|
|
2103
|
+
return dt(da[e], ...t);
|
|
2105
2104
|
}
|
|
2106
|
-
const
|
|
2107
|
-
function
|
|
2105
|
+
const ma = "11.1.1", ht = -1, Ze = "en-US", _t = "", Cn = (e) => `${e.charAt(0).toLocaleUpperCase()}${e.substr(1)}`;
|
|
2106
|
+
function ha() {
|
|
2108
2107
|
return {
|
|
2109
2108
|
upper: (e, t) => t === "text" && I(e) ? e.toUpperCase() : t === "vnode" && F(e) && "__v_isVNode" in e ? e.children.toUpperCase() : e,
|
|
2110
2109
|
lower: (e, t) => t === "text" && I(e) ? e.toLowerCase() : t === "vnode" && F(e) && "__v_isVNode" in e ? e.children.toLowerCase() : e,
|
|
2111
2110
|
capitalize: (e, t) => t === "text" && I(e) ? Cn(e) : t === "vnode" && F(e) && "__v_isVNode" in e ? Cn(e.children) : e
|
|
2112
2111
|
};
|
|
2113
2112
|
}
|
|
2113
|
+
let sr;
|
|
2114
|
+
function ga(e) {
|
|
2115
|
+
sr = e;
|
|
2116
|
+
}
|
|
2114
2117
|
let ar;
|
|
2115
|
-
function
|
|
2118
|
+
function pa(e) {
|
|
2116
2119
|
ar = e;
|
|
2117
2120
|
}
|
|
2118
2121
|
let ir;
|
|
2119
|
-
function
|
|
2122
|
+
function Ea(e) {
|
|
2120
2123
|
ir = e;
|
|
2121
2124
|
}
|
|
2122
|
-
let or;
|
|
2123
|
-
|
|
2125
|
+
let or = null;
|
|
2126
|
+
const ba = /* @__NO_SIDE_EFFECTS__ */ (e) => {
|
|
2124
2127
|
or = e;
|
|
2125
|
-
}
|
|
2128
|
+
}, va = /* @__NO_SIDE_EFFECTS__ */ () => or;
|
|
2126
2129
|
let lr = null;
|
|
2127
|
-
const ya = /* @__NO_SIDE_EFFECTS__ */ (e) => {
|
|
2128
|
-
lr = e;
|
|
2129
|
-
}, Na = /* @__NO_SIDE_EFFECTS__ */ () => lr;
|
|
2130
|
-
let cr = null;
|
|
2131
2130
|
const In = (e) => {
|
|
2132
|
-
|
|
2133
|
-
},
|
|
2131
|
+
lr = e;
|
|
2132
|
+
}, ya = () => lr;
|
|
2134
2133
|
let An = 0;
|
|
2135
|
-
function
|
|
2136
|
-
const t = W(e.onWarn) ? e.onWarn : Ne, n = I(e.version) ? e.version :
|
|
2137
|
-
process.env.NODE_ENV !== "production" && W(e.messageCompiler) &&
|
|
2138
|
-
const d = W(e.messageResolver) ? e.messageResolver :
|
|
2134
|
+
function Na(e = {}) {
|
|
2135
|
+
const t = W(e.onWarn) ? e.onWarn : Ne, n = I(e.version) ? e.version : ma, r = I(e.locale) || W(e.locale) ? e.locale : Ze, a = W(r) ? Ze : r, s = q(e.fallbackLocale) || w(e.fallbackLocale) || I(e.fallbackLocale) || e.fallbackLocale === !1 ? e.fallbackLocale : a, i = w(e.messages) ? e.messages : St(a), c = w(e.datetimeFormats) ? e.datetimeFormats : St(a), f = w(e.numberFormats) ? e.numberFormats : St(a), p = Q($(), e.modifiers, ha()), y = e.pluralRules || $(), N = W(e.missing) ? e.missing : null, v = K(e.missingWarn) || Ve(e.missingWarn) ? e.missingWarn : !0, C = K(e.fallbackWarn) || Ve(e.fallbackWarn) ? e.fallbackWarn : !0, D = !!e.fallbackFormat, A = !!e.unresolving, k = W(e.postTranslation) ? e.postTranslation : null, o = w(e.processor) ? e.processor : null, m = K(e.warnHtmlMessage) ? e.warnHtmlMessage : !0, l = !!e.escapeParameter, u = W(e.messageCompiler) ? e.messageCompiler : sr;
|
|
2136
|
+
process.env.NODE_ENV !== "production" && W(e.messageCompiler) && Qt(De(te.EXPERIMENTAL_CUSTOM_MESSAGE_COMPILER));
|
|
2137
|
+
const d = W(e.messageResolver) ? e.messageResolver : ar || ua, E = W(e.localeFallbacker) ? e.localeFallbacker : ir || ta, g = F(e.fallbackContext) ? e.fallbackContext : void 0, O = e, P = F(O.__datetimeFormatters) ? O.__datetimeFormatters : /* @__PURE__ */ new Map(), M = F(O.__numberFormatters) ? O.__numberFormatters : /* @__PURE__ */ new Map(), B = F(O.__meta) ? O.__meta : {};
|
|
2139
2138
|
An++;
|
|
2140
2139
|
const x = {
|
|
2141
2140
|
version: n,
|
|
@@ -2144,9 +2143,9 @@ function La(e = {}) {
|
|
|
2144
2143
|
fallbackLocale: s,
|
|
2145
2144
|
messages: i,
|
|
2146
2145
|
modifiers: p,
|
|
2147
|
-
pluralRules:
|
|
2146
|
+
pluralRules: y,
|
|
2148
2147
|
missing: N,
|
|
2149
|
-
missingWarn:
|
|
2148
|
+
missingWarn: v,
|
|
2150
2149
|
fallbackWarn: C,
|
|
2151
2150
|
fallbackFormat: D,
|
|
2152
2151
|
unresolving: A,
|
|
@@ -2161,16 +2160,16 @@ function La(e = {}) {
|
|
|
2161
2160
|
onWarn: t,
|
|
2162
2161
|
__meta: B
|
|
2163
2162
|
};
|
|
2164
|
-
return x.datetimeFormats = c, x.numberFormats = f, x.__datetimeFormatters = P, x.__numberFormatters = M, process.env.NODE_ENV !== "production" && (x.__v_emitter = O.__v_emitter != null ? O.__v_emitter : void 0), (process.env.NODE_ENV !== "production" || __INTLIFY_PROD_DEVTOOLS__) &&
|
|
2163
|
+
return x.datetimeFormats = c, x.numberFormats = f, x.__datetimeFormatters = P, x.__numberFormatters = M, process.env.NODE_ENV !== "production" && (x.__v_emitter = O.__v_emitter != null ? O.__v_emitter : void 0), (process.env.NODE_ENV !== "production" || __INTLIFY_PROD_DEVTOOLS__) && Js(x, n, B), x;
|
|
2165
2164
|
}
|
|
2166
2165
|
const St = (e) => ({ [e]: $() });
|
|
2167
2166
|
function gt(e, t) {
|
|
2168
2167
|
return e instanceof RegExp ? e.test(t) : e;
|
|
2169
2168
|
}
|
|
2170
|
-
function
|
|
2169
|
+
function cr(e, t) {
|
|
2171
2170
|
return e instanceof RegExp ? e.test(t) : e;
|
|
2172
2171
|
}
|
|
2173
|
-
function
|
|
2172
|
+
function nn(e, t, n, r, a) {
|
|
2174
2173
|
const { missing: s, onWarn: i } = e;
|
|
2175
2174
|
if (process.env.NODE_ENV !== "production") {
|
|
2176
2175
|
const c = e.__v_emitter;
|
|
@@ -2185,33 +2184,33 @@ function tn(e, t, n, r, a) {
|
|
|
2185
2184
|
const c = s(e, n, t, a);
|
|
2186
2185
|
return I(c) ? c : t;
|
|
2187
2186
|
} else
|
|
2188
|
-
return process.env.NODE_ENV !== "production" &&
|
|
2187
|
+
return process.env.NODE_ENV !== "production" && cr(r, t) && i(De(te.NOT_FOUND_KEY, { key: t, locale: n })), t;
|
|
2189
2188
|
}
|
|
2190
|
-
function
|
|
2189
|
+
function Xe(e, t, n) {
|
|
2191
2190
|
const r = e;
|
|
2192
2191
|
r.__localeChainCache = /* @__PURE__ */ new Map(), e.localeFallbacker(e, n, t);
|
|
2193
2192
|
}
|
|
2194
|
-
function
|
|
2193
|
+
function ur(e, t) {
|
|
2195
2194
|
return e === t ? !1 : e.split("-")[0] === t.split("-")[0];
|
|
2196
2195
|
}
|
|
2197
|
-
function
|
|
2196
|
+
function Ta(e, t) {
|
|
2198
2197
|
const n = t.indexOf(e);
|
|
2199
2198
|
if (n === -1)
|
|
2200
2199
|
return !1;
|
|
2201
2200
|
for (let r = n + 1; r < t.length; r++)
|
|
2202
|
-
if (
|
|
2201
|
+
if (ur(e, t[r]))
|
|
2203
2202
|
return !0;
|
|
2204
2203
|
return !1;
|
|
2205
2204
|
}
|
|
2206
|
-
const kn = typeof Intl < "u",
|
|
2205
|
+
const kn = typeof Intl < "u", fr = {
|
|
2207
2206
|
dateTimeFormat: kn && typeof Intl.DateTimeFormat < "u",
|
|
2208
2207
|
numberFormat: kn && typeof Intl.NumberFormat < "u"
|
|
2209
2208
|
};
|
|
2210
2209
|
function Sn(e, ...t) {
|
|
2211
2210
|
const { datetimeFormats: n, unresolving: r, fallbackLocale: a, onWarn: s, localeFallbacker: i } = e, { __datetimeFormatters: c } = e;
|
|
2212
|
-
if (process.env.NODE_ENV !== "production" && !
|
|
2211
|
+
if (process.env.NODE_ENV !== "production" && !fr.dateTimeFormat)
|
|
2213
2212
|
return s(De(te.CANNOT_FORMAT_DATE)), _t;
|
|
2214
|
-
const [f, p,
|
|
2213
|
+
const [f, p, y, N] = Kt(...t), v = K(y.missingWarn) ? y.missingWarn : e.missingWarn, C = K(y.fallbackWarn) ? y.fallbackWarn : e.fallbackWarn, D = !!y.part, A = tn(e, y), k = i(
|
|
2215
2214
|
e,
|
|
2216
2215
|
// eslint-disable-line @typescript-eslint/no-explicit-any
|
|
2217
2216
|
a,
|
|
@@ -2237,7 +2236,7 @@ function Sn(e, ...t) {
|
|
|
2237
2236
|
}
|
|
2238
2237
|
if (o = n[m] || {}, l = o[f], w(l))
|
|
2239
2238
|
break;
|
|
2240
|
-
|
|
2239
|
+
nn(e, f, m, v, E), u = d;
|
|
2241
2240
|
}
|
|
2242
2241
|
if (!w(l) || !I(m))
|
|
2243
2242
|
return r ? ht : f;
|
|
@@ -2246,7 +2245,7 @@ function Sn(e, ...t) {
|
|
|
2246
2245
|
let O = c.get(g);
|
|
2247
2246
|
return O || (O = new Intl.DateTimeFormat(m, Q({}, l, N)), c.set(g, O)), D ? O.formatToParts(p) : O.format(p);
|
|
2248
2247
|
}
|
|
2249
|
-
const
|
|
2248
|
+
const _r = [
|
|
2250
2249
|
"localeMatcher",
|
|
2251
2250
|
"weekday",
|
|
2252
2251
|
"era",
|
|
@@ -2268,7 +2267,7 @@ const dr = [
|
|
|
2268
2267
|
"hourCycle",
|
|
2269
2268
|
"fractionalSecondDigits"
|
|
2270
2269
|
];
|
|
2271
|
-
function
|
|
2270
|
+
function Kt(...e) {
|
|
2272
2271
|
const [t, n, r, a] = e, s = $();
|
|
2273
2272
|
let i = $(), c;
|
|
2274
2273
|
if (I(t)) {
|
|
@@ -2282,16 +2281,16 @@ function Ut(...e) {
|
|
|
2282
2281
|
} catch {
|
|
2283
2282
|
throw pe(Z.INVALID_ISO_DATE_ARGUMENT);
|
|
2284
2283
|
}
|
|
2285
|
-
} else if (
|
|
2284
|
+
} else if (jr(t)) {
|
|
2286
2285
|
if (isNaN(t.getTime()))
|
|
2287
2286
|
throw pe(Z.INVALID_DATE_ARGUMENT);
|
|
2288
2287
|
c = t;
|
|
2289
|
-
} else if (
|
|
2288
|
+
} else if (J(t))
|
|
2290
2289
|
c = t;
|
|
2291
2290
|
else
|
|
2292
2291
|
throw pe(Z.INVALID_ARGUMENT);
|
|
2293
2292
|
return I(n) ? s.key = n : w(n) && Object.keys(n).forEach((f) => {
|
|
2294
|
-
|
|
2293
|
+
_r.includes(f) ? i[f] = n[f] : s[f] = n[f];
|
|
2295
2294
|
}), I(r) ? s.locale = r : w(r) && (i = r), w(a) && (i = a), [s.key || "", c, s, i];
|
|
2296
2295
|
}
|
|
2297
2296
|
function Dn(e, t, n) {
|
|
@@ -2303,9 +2302,9 @@ function Dn(e, t, n) {
|
|
|
2303
2302
|
}
|
|
2304
2303
|
function Pn(e, ...t) {
|
|
2305
2304
|
const { numberFormats: n, unresolving: r, fallbackLocale: a, onWarn: s, localeFallbacker: i } = e, { __numberFormatters: c } = e;
|
|
2306
|
-
if (process.env.NODE_ENV !== "production" && !
|
|
2305
|
+
if (process.env.NODE_ENV !== "production" && !fr.numberFormat)
|
|
2307
2306
|
return s(De(te.CANNOT_FORMAT_NUMBER)), _t;
|
|
2308
|
-
const [f, p,
|
|
2307
|
+
const [f, p, y, N] = Ut(...t), v = K(y.missingWarn) ? y.missingWarn : e.missingWarn, C = K(y.fallbackWarn) ? y.fallbackWarn : e.fallbackWarn, D = !!y.part, A = tn(e, y), k = i(
|
|
2309
2308
|
e,
|
|
2310
2309
|
// eslint-disable-line @typescript-eslint/no-explicit-any
|
|
2311
2310
|
a,
|
|
@@ -2331,7 +2330,7 @@ function Pn(e, ...t) {
|
|
|
2331
2330
|
}
|
|
2332
2331
|
if (o = n[m] || {}, l = o[f], w(l))
|
|
2333
2332
|
break;
|
|
2334
|
-
|
|
2333
|
+
nn(e, f, m, v, E), u = d;
|
|
2335
2334
|
}
|
|
2336
2335
|
if (!w(l) || !I(m))
|
|
2337
2336
|
return r ? ht : f;
|
|
@@ -2340,7 +2339,7 @@ function Pn(e, ...t) {
|
|
|
2340
2339
|
let O = c.get(g);
|
|
2341
2340
|
return O || (O = new Intl.NumberFormat(m, Q({}, l, N)), c.set(g, O)), D ? O.formatToParts(p) : O.format(p);
|
|
2342
2341
|
}
|
|
2343
|
-
const
|
|
2342
|
+
const dr = [
|
|
2344
2343
|
"localeMatcher",
|
|
2345
2344
|
"style",
|
|
2346
2345
|
"currency",
|
|
@@ -2362,14 +2361,14 @@ const mr = [
|
|
|
2362
2361
|
"roundingIncrement",
|
|
2363
2362
|
"trailingZeroDisplay"
|
|
2364
2363
|
];
|
|
2365
|
-
function
|
|
2364
|
+
function Ut(...e) {
|
|
2366
2365
|
const [t, n, r, a] = e, s = $();
|
|
2367
2366
|
let i = $();
|
|
2368
|
-
if (!
|
|
2367
|
+
if (!J(t))
|
|
2369
2368
|
throw pe(Z.INVALID_ARGUMENT);
|
|
2370
2369
|
const c = t;
|
|
2371
2370
|
return I(n) ? s.key = n : w(n) && Object.keys(n).forEach((f) => {
|
|
2372
|
-
|
|
2371
|
+
dr.includes(f) ? i[f] = n[f] : s[f] = n[f];
|
|
2373
2372
|
}), I(r) ? s.locale = r : w(r) && (i = r), w(a) && (i = a), [s.key || "", c, s, i];
|
|
2374
2373
|
}
|
|
2375
2374
|
function Rn(e, t, n) {
|
|
@@ -2379,26 +2378,26 @@ function Rn(e, t, n) {
|
|
|
2379
2378
|
r.__numberFormatters.has(s) && r.__numberFormatters.delete(s);
|
|
2380
2379
|
}
|
|
2381
2380
|
}
|
|
2382
|
-
const
|
|
2381
|
+
const La = (e) => e, Oa = (e) => "", Ca = "text", Ia = (e) => e.length === 0 ? "" : Jt(e), Aa = Qr;
|
|
2383
2382
|
function Mn(e, t) {
|
|
2384
2383
|
return e = Math.abs(e), t === 2 ? e ? e > 1 ? 1 : 0 : 1 : e ? Math.min(e, 2) : 0;
|
|
2385
2384
|
}
|
|
2386
|
-
function
|
|
2387
|
-
const t =
|
|
2388
|
-
return e.named && (
|
|
2385
|
+
function ka(e) {
|
|
2386
|
+
const t = J(e.pluralIndex) ? e.pluralIndex : -1;
|
|
2387
|
+
return e.named && (J(e.named.count) || J(e.named.n)) ? J(e.named.count) ? e.named.count : J(e.named.n) ? e.named.n : t : t;
|
|
2389
2388
|
}
|
|
2390
|
-
function
|
|
2389
|
+
function Sa(e, t) {
|
|
2391
2390
|
t.count || (t.count = e), t.n || (t.n = e);
|
|
2392
2391
|
}
|
|
2393
|
-
function
|
|
2394
|
-
const t = e.locale, n =
|
|
2395
|
-
|
|
2392
|
+
function Da(e = {}) {
|
|
2393
|
+
const t = e.locale, n = ka(e), r = F(e.pluralRules) && I(t) && W(e.pluralRules[t]) ? e.pluralRules[t] : Mn, a = F(e.pluralRules) && I(t) && W(e.pluralRules[t]) ? Mn : void 0, s = (o) => o[r(n, o.length, a)], i = e.list || [], c = (o) => i[o], f = e.named || $();
|
|
2394
|
+
J(e.pluralIndex) && Sa(n, f);
|
|
2396
2395
|
const p = (o) => f[o];
|
|
2397
|
-
function
|
|
2396
|
+
function y(o, m) {
|
|
2398
2397
|
const l = W(e.messages) ? e.messages(o, !!m) : F(e.messages) ? e.messages[o] : !1;
|
|
2399
|
-
return l || (e.parent ? e.parent.message(o) :
|
|
2398
|
+
return l || (e.parent ? e.parent.message(o) : Oa);
|
|
2400
2399
|
}
|
|
2401
|
-
const N = (o) => e.modifiers ? e.modifiers[o] :
|
|
2400
|
+
const N = (o) => e.modifiers ? e.modifiers[o] : La, v = w(e.processor) && W(e.processor.normalize) ? e.processor.normalize : Ia, C = w(e.processor) && W(e.processor.interpolate) ? e.processor.interpolate : Aa, D = w(e.processor) && I(e.processor.type) ? e.processor.type : Ca, k = {
|
|
2402
2401
|
list: c,
|
|
2403
2402
|
named: p,
|
|
2404
2403
|
plural: s,
|
|
@@ -2406,29 +2405,29 @@ function Ra(e = {}) {
|
|
|
2406
2405
|
const [l, u] = m;
|
|
2407
2406
|
let d = "text", E = "";
|
|
2408
2407
|
m.length === 1 ? F(l) ? (E = l.modifier || E, d = l.type || d) : I(l) && (E = l || E) : m.length === 2 && (I(l) && (E = l || E), I(u) && (d = u || d));
|
|
2409
|
-
const g =
|
|
2408
|
+
const g = y(o, !0)(k), O = (
|
|
2410
2409
|
// The message in vnode resolved with linked are returned as an array by processor.nomalize
|
|
2411
|
-
d === "vnode" &&
|
|
2410
|
+
d === "vnode" && q(g) && E ? g[0] : g
|
|
2412
2411
|
);
|
|
2413
2412
|
return E ? N(E)(O, d) : O;
|
|
2414
2413
|
},
|
|
2415
|
-
message:
|
|
2414
|
+
message: y,
|
|
2416
2415
|
type: D,
|
|
2417
2416
|
interpolate: C,
|
|
2418
|
-
normalize:
|
|
2417
|
+
normalize: v,
|
|
2419
2418
|
values: Q($(), i, f)
|
|
2420
2419
|
};
|
|
2421
2420
|
return k;
|
|
2422
2421
|
}
|
|
2423
2422
|
const wn = () => "", se = (e) => W(e);
|
|
2424
2423
|
function Fn(e, ...t) {
|
|
2425
|
-
const { fallbackFormat: n, postTranslation: r, unresolving: a, messageCompiler: s, fallbackLocale: i, messages: c } = e, [f, p] = Vt(...t),
|
|
2426
|
-
|
|
2424
|
+
const { fallbackFormat: n, postTranslation: r, unresolving: a, messageCompiler: s, fallbackLocale: i, messages: c } = e, [f, p] = Vt(...t), y = K(p.missingWarn) ? p.missingWarn : e.missingWarn, N = K(p.fallbackWarn) ? p.fallbackWarn : e.fallbackWarn, v = K(p.escapeParameter) ? p.escapeParameter : e.escapeParameter, C = !!p.resolvedMessage, D = I(p.default) || K(p.default) ? K(p.default) ? s ? f : () => f : p.default : n ? s ? f : () => f : null, A = n || D != null && (I(D) || W(D)), k = tn(e, p);
|
|
2425
|
+
v && Pa(p);
|
|
2427
2426
|
let [o, m, l] = C ? [
|
|
2428
2427
|
f,
|
|
2429
2428
|
k,
|
|
2430
2429
|
c[k] || $()
|
|
2431
|
-
] :
|
|
2430
|
+
] : mr(e, f, k, i, N, y), u = o, d = f;
|
|
2432
2431
|
if (!C && !(I(u) || ye(u) || se(u)) && A && (u = D, d = u), !C && (!(I(u) || ye(u) || se(u)) || !I(m)))
|
|
2433
2432
|
return a ? ht : f;
|
|
2434
2433
|
if (process.env.NODE_ENV !== "production" && I(u) && e.messageCompiler == null)
|
|
@@ -2436,10 +2435,10 @@ function Fn(e, ...t) {
|
|
|
2436
2435
|
let E = !1;
|
|
2437
2436
|
const g = () => {
|
|
2438
2437
|
E = !0;
|
|
2439
|
-
}, O = se(u) ? u :
|
|
2438
|
+
}, O = se(u) ? u : hr(e, f, m, u, d, g);
|
|
2440
2439
|
if (E)
|
|
2441
2440
|
return u;
|
|
2442
|
-
const P =
|
|
2441
|
+
const P = Fa(e, m, l, p), M = Da(P), B = Ra(e, O, M), x = r ? r(B, f) : B;
|
|
2443
2442
|
if (process.env.NODE_ENV !== "production" || __INTLIFY_PROD_DEVTOOLS__) {
|
|
2444
2443
|
const oe = {
|
|
2445
2444
|
timestamp: Date.now(),
|
|
@@ -2448,24 +2447,24 @@ function Fn(e, ...t) {
|
|
|
2448
2447
|
format: I(u) ? u : se(u) ? u.source : "",
|
|
2449
2448
|
message: x
|
|
2450
2449
|
};
|
|
2451
|
-
oe.meta = Q({}, e.__meta, /* @__PURE__ */
|
|
2450
|
+
oe.meta = Q({}, e.__meta, /* @__PURE__ */ va() || {}), Qs(oe);
|
|
2452
2451
|
}
|
|
2453
2452
|
return x;
|
|
2454
2453
|
}
|
|
2455
|
-
function
|
|
2456
|
-
|
|
2454
|
+
function Pa(e) {
|
|
2455
|
+
q(e.list) ? e.list = e.list.map((t) => I(t) ? gn(t) : t) : F(e.named) && Object.keys(e.named).forEach((t) => {
|
|
2457
2456
|
I(e.named[t]) && (e.named[t] = gn(e.named[t]));
|
|
2458
2457
|
});
|
|
2459
2458
|
}
|
|
2460
|
-
function
|
|
2461
|
-
const { messages: i, onWarn: c, messageResolver: f, localeFallbacker: p } = e,
|
|
2462
|
-
let N = $(),
|
|
2459
|
+
function mr(e, t, n, r, a, s) {
|
|
2460
|
+
const { messages: i, onWarn: c, messageResolver: f, localeFallbacker: p } = e, y = p(e, r, n);
|
|
2461
|
+
let N = $(), v, C = null, D = n, A = null;
|
|
2463
2462
|
const k = "translate";
|
|
2464
|
-
for (let o = 0; o <
|
|
2465
|
-
if (
|
|
2463
|
+
for (let o = 0; o < y.length; o++) {
|
|
2464
|
+
if (v = A = y[o], process.env.NODE_ENV !== "production" && n !== v && !ur(n, v) && gt(a, t) && c(De(te.FALLBACK_TO_TRANSLATE, {
|
|
2466
2465
|
key: t,
|
|
2467
|
-
target:
|
|
2468
|
-
})), process.env.NODE_ENV !== "production" && n !==
|
|
2466
|
+
target: v
|
|
2467
|
+
})), process.env.NODE_ENV !== "production" && n !== v) {
|
|
2469
2468
|
const d = e.__v_emitter;
|
|
2470
2469
|
d && d.emit("fallback", {
|
|
2471
2470
|
type: k,
|
|
@@ -2475,7 +2474,7 @@ function hr(e, t, n, r, a, s) {
|
|
|
2475
2474
|
groupId: `${k}:${t}`
|
|
2476
2475
|
});
|
|
2477
2476
|
}
|
|
2478
|
-
N = i[
|
|
2477
|
+
N = i[v] || $();
|
|
2479
2478
|
let m = null, l, u;
|
|
2480
2479
|
if (process.env.NODE_ENV !== "production" && ie && (m = window.performance.now(), l = "intlify-message-resolve-start", u = "intlify-message-resolve-end", re && re(l)), (C = f(N, t)) === null && (C = N[t]), process.env.NODE_ENV !== "production" && ie) {
|
|
2481
2480
|
const d = window.performance.now(), E = e.__v_emitter;
|
|
@@ -2489,12 +2488,12 @@ function hr(e, t, n, r, a, s) {
|
|
|
2489
2488
|
}
|
|
2490
2489
|
if (I(C) || ye(C) || se(C))
|
|
2491
2490
|
break;
|
|
2492
|
-
if (!
|
|
2493
|
-
const d =
|
|
2491
|
+
if (!Ta(v, y)) {
|
|
2492
|
+
const d = nn(
|
|
2494
2493
|
e,
|
|
2495
2494
|
// eslint-disable-line @typescript-eslint/no-explicit-any
|
|
2496
2495
|
t,
|
|
2497
|
-
|
|
2496
|
+
v,
|
|
2498
2497
|
s,
|
|
2499
2498
|
k
|
|
2500
2499
|
);
|
|
@@ -2502,33 +2501,33 @@ function hr(e, t, n, r, a, s) {
|
|
|
2502
2501
|
}
|
|
2503
2502
|
D = A;
|
|
2504
2503
|
}
|
|
2505
|
-
return [C,
|
|
2504
|
+
return [C, v, N];
|
|
2506
2505
|
}
|
|
2507
|
-
function
|
|
2506
|
+
function hr(e, t, n, r, a, s) {
|
|
2508
2507
|
const { messageCompiler: i, warnHtmlMessage: c } = e;
|
|
2509
2508
|
if (se(r)) {
|
|
2510
|
-
const
|
|
2511
|
-
return
|
|
2509
|
+
const v = r;
|
|
2510
|
+
return v.locale = v.locale || n, v.key = v.key || t, v;
|
|
2512
2511
|
}
|
|
2513
2512
|
if (i == null) {
|
|
2514
|
-
const
|
|
2515
|
-
return
|
|
2513
|
+
const v = () => r;
|
|
2514
|
+
return v.locale = n, v.key = t, v;
|
|
2516
2515
|
}
|
|
2517
|
-
let f = null, p,
|
|
2518
|
-
process.env.NODE_ENV !== "production" && ie && (f = window.performance.now(), p = "intlify-message-compilation-start",
|
|
2519
|
-
const N = i(r,
|
|
2516
|
+
let f = null, p, y;
|
|
2517
|
+
process.env.NODE_ENV !== "production" && ie && (f = window.performance.now(), p = "intlify-message-compilation-start", y = "intlify-message-compilation-end", re && re(p));
|
|
2518
|
+
const N = i(r, Ma(e, n, a, r, c, s));
|
|
2520
2519
|
if (process.env.NODE_ENV !== "production" && ie) {
|
|
2521
|
-
const
|
|
2520
|
+
const v = window.performance.now(), C = e.__v_emitter;
|
|
2522
2521
|
C && f && C.emit("message-compilation", {
|
|
2523
2522
|
type: "message-compilation",
|
|
2524
2523
|
message: r,
|
|
2525
|
-
time:
|
|
2524
|
+
time: v - f,
|
|
2526
2525
|
groupId: `translate:${t}`
|
|
2527
|
-
}), p &&
|
|
2526
|
+
}), p && y && re && Se && (re(y), Se("intlify message compilation", p, y));
|
|
2528
2527
|
}
|
|
2529
2528
|
return N.locale = n, N.key = t, N.source = r, N;
|
|
2530
2529
|
}
|
|
2531
|
-
function
|
|
2530
|
+
function Ra(e, t, n) {
|
|
2532
2531
|
let r = null, a, s;
|
|
2533
2532
|
process.env.NODE_ENV !== "production" && ie && (r = window.performance.now(), a = "intlify-message-evaluation-start", s = "intlify-message-evaluation-end", re && re(a));
|
|
2534
2533
|
const i = t(n);
|
|
@@ -2545,20 +2544,20 @@ function wa(e, t, n) {
|
|
|
2545
2544
|
}
|
|
2546
2545
|
function Vt(...e) {
|
|
2547
2546
|
const [t, n, r] = e, a = $();
|
|
2548
|
-
if (!I(t) && !
|
|
2547
|
+
if (!I(t) && !J(t) && !se(t) && !ye(t))
|
|
2549
2548
|
throw pe(Z.INVALID_ARGUMENT);
|
|
2550
|
-
const s =
|
|
2551
|
-
return
|
|
2549
|
+
const s = J(t) ? String(t) : (se(t), t);
|
|
2550
|
+
return J(n) ? a.plural = n : I(n) ? a.default = n : w(n) && !mt(n) ? a.named = n : q(n) && (a.list = n), J(r) ? a.plural = r : I(r) ? a.default = r : w(r) && Q(a, r), [s, a];
|
|
2552
2551
|
}
|
|
2553
|
-
function
|
|
2552
|
+
function Ma(e, t, n, r, a, s) {
|
|
2554
2553
|
return {
|
|
2555
2554
|
locale: t,
|
|
2556
2555
|
key: n,
|
|
2557
2556
|
warnHtmlMessage: a,
|
|
2558
2557
|
onError: (i) => {
|
|
2559
2558
|
if (s && s(i), process.env.NODE_ENV !== "production") {
|
|
2560
|
-
const c =
|
|
2561
|
-
|
|
2559
|
+
const c = wa(r), f = `Message compilation error: ${i.message}`, p = i.location && c && Zr(c, i.location.start.offset, i.location.end.offset), y = e.__v_emitter;
|
|
2560
|
+
y && c && y.emit("compile-error", {
|
|
2562
2561
|
message: c,
|
|
2563
2562
|
error: i.message,
|
|
2564
2563
|
start: i.location && i.location.start.offset,
|
|
@@ -2569,25 +2568,25 @@ ${p}` : f);
|
|
|
2569
2568
|
} else
|
|
2570
2569
|
throw i;
|
|
2571
2570
|
},
|
|
2572
|
-
onCacheKey: (i) =>
|
|
2571
|
+
onCacheKey: (i) => Yr(t, n, i)
|
|
2573
2572
|
};
|
|
2574
2573
|
}
|
|
2575
|
-
function
|
|
2574
|
+
function wa(e) {
|
|
2576
2575
|
if (I(e))
|
|
2577
2576
|
return e;
|
|
2578
2577
|
if (e.loc && e.loc.source)
|
|
2579
2578
|
return e.loc.source;
|
|
2580
2579
|
}
|
|
2581
|
-
function
|
|
2582
|
-
const { modifiers: a, pluralRules: s, messageResolver: i, fallbackLocale: c, fallbackWarn: f, missingWarn: p, fallbackContext:
|
|
2580
|
+
function Fa(e, t, n, r) {
|
|
2581
|
+
const { modifiers: a, pluralRules: s, messageResolver: i, fallbackLocale: c, fallbackWarn: f, missingWarn: p, fallbackContext: y } = e, v = {
|
|
2583
2582
|
locale: t,
|
|
2584
2583
|
modifiers: a,
|
|
2585
2584
|
pluralRules: s,
|
|
2586
2585
|
messages: (C, D) => {
|
|
2587
2586
|
let A = i(n, C);
|
|
2588
|
-
if (A == null && (
|
|
2589
|
-
const [, , k] =
|
|
2590
|
-
|
|
2587
|
+
if (A == null && (y || D)) {
|
|
2588
|
+
const [, , k] = mr(
|
|
2589
|
+
y || e,
|
|
2591
2590
|
// NOTE: if has fallbackContext, fallback to root, else if use linked, fallback to local context
|
|
2592
2591
|
C,
|
|
2593
2592
|
t,
|
|
@@ -2599,32 +2598,32 @@ function Ka(e, t, n, r) {
|
|
|
2599
2598
|
}
|
|
2600
2599
|
if (I(A) || ye(A)) {
|
|
2601
2600
|
let k = !1;
|
|
2602
|
-
const m =
|
|
2601
|
+
const m = hr(e, C, t, A, C, () => {
|
|
2603
2602
|
k = !0;
|
|
2604
2603
|
});
|
|
2605
2604
|
return k ? wn : m;
|
|
2606
2605
|
} else return se(A) ? A : wn;
|
|
2607
2606
|
}
|
|
2608
2607
|
};
|
|
2609
|
-
return e.processor && (
|
|
2608
|
+
return e.processor && (v.processor = e.processor), r.list && (v.list = r.list), r.named && (v.named = r.named), J(r.plural) && (v.pluralIndex = r.plural), v;
|
|
2610
2609
|
}
|
|
2611
|
-
|
|
2612
|
-
function
|
|
2613
|
-
return
|
|
2610
|
+
As();
|
|
2611
|
+
function Ka() {
|
|
2612
|
+
return gr().__VUE_DEVTOOLS_GLOBAL_HOOK__;
|
|
2614
2613
|
}
|
|
2615
|
-
function
|
|
2614
|
+
function gr() {
|
|
2616
2615
|
return typeof navigator < "u" && typeof window < "u" ? window : typeof globalThis < "u" ? globalThis : {};
|
|
2617
2616
|
}
|
|
2618
|
-
const
|
|
2617
|
+
const Ua = typeof Proxy == "function", Va = "devtools-plugin:setup", xa = "plugin:settings:set";
|
|
2619
2618
|
let Fe, xt;
|
|
2620
|
-
function
|
|
2619
|
+
function $a() {
|
|
2621
2620
|
var e;
|
|
2622
2621
|
return Fe !== void 0 || (typeof window < "u" && window.performance ? (Fe = !0, xt = window.performance) : typeof globalThis < "u" && (!((e = globalThis.perf_hooks) === null || e === void 0) && e.performance) ? (Fe = !0, xt = globalThis.perf_hooks.performance) : Fe = !1), Fe;
|
|
2623
2622
|
}
|
|
2624
|
-
function
|
|
2625
|
-
return
|
|
2623
|
+
function Wa() {
|
|
2624
|
+
return $a() ? xt.now() : Date.now();
|
|
2626
2625
|
}
|
|
2627
|
-
class
|
|
2626
|
+
class Ga {
|
|
2628
2627
|
constructor(t, n) {
|
|
2629
2628
|
this.target = null, this.targetQueue = [], this.onQueue = [], this.plugin = t, this.hook = n;
|
|
2630
2629
|
const r = {};
|
|
@@ -2652,9 +2651,9 @@ class Ya {
|
|
|
2652
2651
|
s = i;
|
|
2653
2652
|
},
|
|
2654
2653
|
now() {
|
|
2655
|
-
return
|
|
2654
|
+
return Wa();
|
|
2656
2655
|
}
|
|
2657
|
-
}, n && n.on(
|
|
2656
|
+
}, n && n.on(xa, (i, c) => {
|
|
2658
2657
|
i === this.plugin.id && this.fallbacks.setSettings(c);
|
|
2659
2658
|
}), this.proxiedOn = new Proxy({}, {
|
|
2660
2659
|
get: (i, c) => this.target ? this.target.on[c] : (...f) => {
|
|
@@ -2686,12 +2685,12 @@ class Ya {
|
|
|
2686
2685
|
n.resolve(await this.target[n.method](...n.args));
|
|
2687
2686
|
}
|
|
2688
2687
|
}
|
|
2689
|
-
function
|
|
2690
|
-
const n = e, r =
|
|
2688
|
+
function Ba(e, t) {
|
|
2689
|
+
const n = e, r = gr(), a = Ka(), s = Ua && n.enableEarlyProxy;
|
|
2691
2690
|
if (a && (r.__VUE_DEVTOOLS_PLUGIN_API_AVAILABLE__ || !s))
|
|
2692
|
-
a.emit(
|
|
2691
|
+
a.emit(Va, e, t);
|
|
2693
2692
|
else {
|
|
2694
|
-
const i = s ? new
|
|
2693
|
+
const i = s ? new Ga(n, a) : null;
|
|
2695
2694
|
(r.__VUE_DEVTOOLS_PLUGINS__ = r.__VUE_DEVTOOLS_PLUGINS__ || []).push({
|
|
2696
2695
|
pluginDescriptor: n,
|
|
2697
2696
|
setupFn: t,
|
|
@@ -2704,13 +2703,13 @@ function Ha(e, t) {
|
|
|
2704
2703
|
* (c) 2025 kazuya kawaguchi
|
|
2705
2704
|
* Released under the MIT License.
|
|
2706
2705
|
*/
|
|
2707
|
-
const
|
|
2708
|
-
function
|
|
2706
|
+
const Ya = "11.1.1";
|
|
2707
|
+
function Ha() {
|
|
2709
2708
|
typeof __VUE_I18N_FULL_INSTALL__ != "boolean" && (ke().__VUE_I18N_FULL_INSTALL__ = !0), typeof __VUE_I18N_LEGACY_API__ != "boolean" && (ke().__VUE_I18N_LEGACY_API__ = !0), typeof __INTLIFY_DROP_MESSAGE_COMPILER__ != "boolean" && (ke().__INTLIFY_DROP_MESSAGE_COMPILER__ = !1), typeof __INTLIFY_PROD_DEVTOOLS__ != "boolean" && (ke().__INTLIFY_PROD_DEVTOOLS__ = !1);
|
|
2710
2709
|
}
|
|
2711
2710
|
const G = {
|
|
2712
2711
|
// composer module errors
|
|
2713
|
-
UNEXPECTED_RETURN_TYPE:
|
|
2712
|
+
UNEXPECTED_RETURN_TYPE: zs,
|
|
2714
2713
|
// 24
|
|
2715
2714
|
// legacy module errors
|
|
2716
2715
|
INVALID_ARGUMENT: 25,
|
|
@@ -2731,9 +2730,9 @@ const G = {
|
|
|
2731
2730
|
NOT_AVAILABLE_COMPOSITION_IN_LEGACY: 34
|
|
2732
2731
|
};
|
|
2733
2732
|
function ne(e, ...t) {
|
|
2734
|
-
return $e(e, null, process.env.NODE_ENV !== "production" ? { messages:
|
|
2733
|
+
return $e(e, null, process.env.NODE_ENV !== "production" ? { messages: ja, args: t } : void 0);
|
|
2735
2734
|
}
|
|
2736
|
-
const
|
|
2735
|
+
const ja = {
|
|
2737
2736
|
[G.UNEXPECTED_RETURN_TYPE]: "Unexpected return type in composer",
|
|
2738
2737
|
[G.INVALID_ARGUMENT]: "Invalid argument",
|
|
2739
2738
|
[G.MUST_BE_CALL_SETUP_TOP]: "Must be called at the top of a `setup` function",
|
|
@@ -2745,8 +2744,8 @@ const Ja = {
|
|
|
2745
2744
|
[G.NOT_INSTALLED_WITH_PROVIDE]: "Need to install with `provide` function",
|
|
2746
2745
|
[G.NOT_COMPATIBLE_LEGACY_VUE_I18N]: "Not compatible legacy VueI18n.",
|
|
2747
2746
|
[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"
|
|
2748
|
-
}, $t = /* @__PURE__ */ me("__translateVNode"), Wt = /* @__PURE__ */ me("__datetimeParts"), Gt = /* @__PURE__ */ me("__numberParts"), Pe = /* @__PURE__ */ me("__enableEmitter"), ze = /* @__PURE__ */ me("__disableEmitter"),
|
|
2749
|
-
FALLBACK_TO_ROOT:
|
|
2747
|
+
}, $t = /* @__PURE__ */ me("__translateVNode"), Wt = /* @__PURE__ */ me("__datetimeParts"), Gt = /* @__PURE__ */ me("__numberParts"), Pe = /* @__PURE__ */ me("__enableEmitter"), ze = /* @__PURE__ */ me("__disableEmitter"), pr = me("__setPluralRules"), Er = /* @__PURE__ */ me("__injectWithOption"), Bt = /* @__PURE__ */ me("__dispose"), de = {
|
|
2748
|
+
FALLBACK_TO_ROOT: _a,
|
|
2750
2749
|
// 8
|
|
2751
2750
|
NOT_FOUND_PARENT_SCOPE: 9,
|
|
2752
2751
|
IGNORE_OBJ_FLATTEN: 10,
|
|
@@ -2758,7 +2757,7 @@ const Ja = {
|
|
|
2758
2757
|
* @deprecated will be removed at vue-i18n v12
|
|
2759
2758
|
*/
|
|
2760
2759
|
DEPRECATE_TRANSLATE_CUSTOME_DIRECTIVE: 12
|
|
2761
|
-
},
|
|
2760
|
+
}, Xa = {
|
|
2762
2761
|
[de.FALLBACK_TO_ROOT]: "Fall back to {type} '{key}' with root locale.",
|
|
2763
2762
|
[de.NOT_FOUND_PARENT_SCOPE]: "Not found parent scope. use the global scope.",
|
|
2764
2763
|
[de.IGNORE_OBJ_FLATTEN]: "Ignore object flatten: '{key}' key has an string value",
|
|
@@ -2773,7 +2772,7 @@ About how to use the Composition API mode, see https://vue-i18n.intlify.dev/guid
|
|
|
2773
2772
|
[de.DEPRECATE_TRANSLATE_CUSTOME_DIRECTIVE]: "'v-t' has been deprecated in v11. Use translate APIs ('t' or '$t') instead."
|
|
2774
2773
|
};
|
|
2775
2774
|
function nt(e, ...t) {
|
|
2776
|
-
return dt(
|
|
2775
|
+
return dt(Xa[e], ...t);
|
|
2777
2776
|
}
|
|
2778
2777
|
function et(e) {
|
|
2779
2778
|
if (!F(e))
|
|
@@ -2798,9 +2797,9 @@ function et(e) {
|
|
|
2798
2797
|
}
|
|
2799
2798
|
return e;
|
|
2800
2799
|
}
|
|
2801
|
-
function
|
|
2802
|
-
const { messages: n, __i18n: r, messageResolver: a, flatJson: s } = t, i = w(n) ? n :
|
|
2803
|
-
if (
|
|
2800
|
+
function rn(e, t) {
|
|
2801
|
+
const { messages: n, __i18n: r, messageResolver: a, flatJson: s } = t, i = w(n) ? n : q(r) ? $() : { [e]: $() };
|
|
2802
|
+
if (q(r) && r.forEach((c) => {
|
|
2804
2803
|
if ("locale" in c && "resource" in c) {
|
|
2805
2804
|
const { locale: f, resource: p } = c;
|
|
2806
2805
|
f ? (i[f] = i[f] || $(), ut(p, i[f])) : ut(p, i);
|
|
@@ -2811,12 +2810,12 @@ function nn(e, t) {
|
|
|
2811
2810
|
ae(i, c) && et(i[c]);
|
|
2812
2811
|
return i;
|
|
2813
2812
|
}
|
|
2814
|
-
function
|
|
2813
|
+
function br(e) {
|
|
2815
2814
|
return e.type;
|
|
2816
2815
|
}
|
|
2817
|
-
function
|
|
2816
|
+
function vr(e, t, n) {
|
|
2818
2817
|
let r = F(t.messages) ? t.messages : $();
|
|
2819
|
-
"__i18nGlobal" in n && (r =
|
|
2818
|
+
"__i18nGlobal" in n && (r = rn(e.locale.value, {
|
|
2820
2819
|
messages: r,
|
|
2821
2820
|
__i18n: n.__i18nGlobal
|
|
2822
2821
|
}));
|
|
@@ -2839,43 +2838,43 @@ function yr(e, t, n) {
|
|
|
2839
2838
|
}
|
|
2840
2839
|
}
|
|
2841
2840
|
}
|
|
2842
|
-
function
|
|
2843
|
-
return ue(
|
|
2841
|
+
function Kn(e) {
|
|
2842
|
+
return ue(Fr, null, e, 0);
|
|
2844
2843
|
}
|
|
2845
|
-
const
|
|
2844
|
+
const Un = "__INTLIFY_META__", Vn = () => [], qa = () => !1;
|
|
2846
2845
|
let xn = 0;
|
|
2847
2846
|
function $n(e) {
|
|
2848
|
-
return (t, n, r, a) => e(n, r,
|
|
2847
|
+
return (t, n, r, a) => e(n, r, qe() || void 0, a);
|
|
2849
2848
|
}
|
|
2850
|
-
const
|
|
2851
|
-
const e =
|
|
2849
|
+
const Ja = /* @__NO_SIDE_EFFECTS__ */ () => {
|
|
2850
|
+
const e = qe();
|
|
2852
2851
|
let t = null;
|
|
2853
|
-
return e && (t =
|
|
2852
|
+
return e && (t = br(e)[Un]) ? { [Un]: t } : null;
|
|
2854
2853
|
};
|
|
2855
|
-
function
|
|
2856
|
-
const { __root: t, __injectWithOption: n } = e, r = t === void 0, a = e.flatJson, s = ie ?
|
|
2857
|
-
let i =
|
|
2854
|
+
function sn(e = {}) {
|
|
2855
|
+
const { __root: t, __injectWithOption: n } = e, r = t === void 0, a = e.flatJson, s = ie ? Sr : Dr;
|
|
2856
|
+
let i = K(e.inheritLocale) ? e.inheritLocale : !0;
|
|
2858
2857
|
const c = s(
|
|
2859
2858
|
// prettier-ignore
|
|
2860
2859
|
t && i ? t.locale.value : I(e.locale) ? e.locale : Ze
|
|
2861
2860
|
), f = s(
|
|
2862
2861
|
// prettier-ignore
|
|
2863
|
-
t && i ? t.fallbackLocale.value : I(e.fallbackLocale) ||
|
|
2864
|
-
), p = s(
|
|
2865
|
-
let
|
|
2862
|
+
t && i ? t.fallbackLocale.value : I(e.fallbackLocale) || q(e.fallbackLocale) || w(e.fallbackLocale) || e.fallbackLocale === !1 ? e.fallbackLocale : c.value
|
|
2863
|
+
), p = s(rn(c.value, e)), y = s(w(e.datetimeFormats) ? e.datetimeFormats : { [c.value]: {} }), N = s(w(e.numberFormats) ? e.numberFormats : { [c.value]: {} });
|
|
2864
|
+
let v = t ? t.missingWarn : K(e.missingWarn) || Ve(e.missingWarn) ? e.missingWarn : !0, C = t ? t.fallbackWarn : K(e.fallbackWarn) || Ve(e.fallbackWarn) ? e.fallbackWarn : !0, D = t ? t.fallbackRoot : K(e.fallbackRoot) ? e.fallbackRoot : !0, A = !!e.fallbackFormat, k = W(e.missing) ? e.missing : null, o = W(e.missing) ? $n(e.missing) : null, m = W(e.postTranslation) ? e.postTranslation : null, l = t ? t.warnHtmlMessage : K(e.warnHtmlMessage) ? e.warnHtmlMessage : !0, u = !!e.escapeParameter;
|
|
2866
2865
|
const d = t ? t.modifiers : w(e.modifiers) ? e.modifiers : {};
|
|
2867
2866
|
let E = e.pluralRules || t && t.pluralRules, g;
|
|
2868
2867
|
g = (() => {
|
|
2869
2868
|
r && In(null);
|
|
2870
2869
|
const b = {
|
|
2871
|
-
version:
|
|
2870
|
+
version: Ya,
|
|
2872
2871
|
locale: c.value,
|
|
2873
2872
|
fallbackLocale: f.value,
|
|
2874
2873
|
messages: p.value,
|
|
2875
2874
|
modifiers: d,
|
|
2876
2875
|
pluralRules: E,
|
|
2877
2876
|
missing: o === null ? void 0 : o,
|
|
2878
|
-
missingWarn:
|
|
2877
|
+
missingWarn: v,
|
|
2879
2878
|
fallbackWarn: C,
|
|
2880
2879
|
fallbackFormat: A,
|
|
2881
2880
|
unresolving: !0,
|
|
@@ -2886,30 +2885,30 @@ function rn(e = {}) {
|
|
|
2886
2885
|
messageCompiler: e.messageCompiler,
|
|
2887
2886
|
__meta: { framework: "vue" }
|
|
2888
2887
|
};
|
|
2889
|
-
b.datetimeFormats =
|
|
2890
|
-
const L =
|
|
2888
|
+
b.datetimeFormats = y.value, b.numberFormats = N.value, b.__datetimeFormatters = w(g) ? g.__datetimeFormatters : void 0, b.__numberFormatters = w(g) ? g.__numberFormatters : void 0, process.env.NODE_ENV !== "production" && (b.__v_emitter = w(g) ? g.__v_emitter : void 0);
|
|
2889
|
+
const L = Na(b);
|
|
2891
2890
|
return r && In(L), L;
|
|
2892
|
-
})(),
|
|
2891
|
+
})(), Xe(g, c.value, f.value);
|
|
2893
2892
|
function P() {
|
|
2894
2893
|
return [
|
|
2895
2894
|
c.value,
|
|
2896
2895
|
f.value,
|
|
2897
2896
|
p.value,
|
|
2898
|
-
|
|
2897
|
+
y.value,
|
|
2899
2898
|
N.value
|
|
2900
2899
|
];
|
|
2901
2900
|
}
|
|
2902
|
-
const M =
|
|
2901
|
+
const M = je({
|
|
2903
2902
|
get: () => c.value,
|
|
2904
2903
|
set: (b) => {
|
|
2905
2904
|
g.locale = b, c.value = b;
|
|
2906
2905
|
}
|
|
2907
|
-
}), B =
|
|
2906
|
+
}), B = je({
|
|
2908
2907
|
get: () => f.value,
|
|
2909
2908
|
set: (b) => {
|
|
2910
|
-
g.fallbackLocale = b, f.value = b,
|
|
2909
|
+
g.fallbackLocale = b, f.value = b, Xe(g, c.value, b);
|
|
2911
2910
|
}
|
|
2912
|
-
}), x =
|
|
2911
|
+
}), x = je(() => p.value), oe = /* @__PURE__ */ je(() => y.value), le = /* @__PURE__ */ je(() => N.value);
|
|
2913
2912
|
function Oe() {
|
|
2914
2913
|
return W(m) ? m : null;
|
|
2915
2914
|
}
|
|
@@ -2925,18 +2924,18 @@ function rn(e = {}) {
|
|
|
2925
2924
|
function We(b, L) {
|
|
2926
2925
|
return b !== "translate" || !L.resolvedMessage;
|
|
2927
2926
|
}
|
|
2928
|
-
const he = (b, L, V,
|
|
2927
|
+
const he = (b, L, V, j, Ie, st) => {
|
|
2929
2928
|
P();
|
|
2930
2929
|
let we;
|
|
2931
2930
|
try {
|
|
2932
|
-
process.env.NODE_ENV !== "production" || __INTLIFY_PROD_DEVTOOLS__, r || (g.fallbackContext = t ?
|
|
2931
|
+
process.env.NODE_ENV !== "production" || __INTLIFY_PROD_DEVTOOLS__, r || (g.fallbackContext = t ? ya() : void 0), we = b(g);
|
|
2933
2932
|
} finally {
|
|
2934
2933
|
process.env.NODE_ENV !== "production" || __INTLIFY_PROD_DEVTOOLS__, r || (g.fallbackContext = void 0);
|
|
2935
2934
|
}
|
|
2936
2935
|
if (V !== "translate exists" && // for not `te` (e.g `t`)
|
|
2937
|
-
|
|
2938
|
-
const [Ae,
|
|
2939
|
-
if (process.env.NODE_ENV !== "production" && t && I(Ae) && We(V,
|
|
2936
|
+
J(we) && we === ht || V === "translate exists" && !we) {
|
|
2937
|
+
const [Ae, Ar] = L();
|
|
2938
|
+
if (process.env.NODE_ENV !== "production" && t && I(Ae) && We(V, Ar) && (D && (gt(C, Ae) || cr(v, Ae)) && Ne(nt(de.FALLBACK_TO_ROOT, {
|
|
2940
2939
|
key: Ae,
|
|
2941
2940
|
type: V
|
|
2942
2941
|
})), process.env.NODE_ENV !== "production")) {
|
|
@@ -2948,7 +2947,7 @@ function rn(e = {}) {
|
|
|
2948
2947
|
groupId: `${V}:${Ae}`
|
|
2949
2948
|
});
|
|
2950
2949
|
}
|
|
2951
|
-
return t && D ?
|
|
2950
|
+
return t && D ? j(t) : Ie(Ae);
|
|
2952
2951
|
} else {
|
|
2953
2952
|
if (st(we))
|
|
2954
2953
|
return we;
|
|
@@ -2959,19 +2958,19 @@ function rn(e = {}) {
|
|
|
2959
2958
|
return he((L) => Reflect.apply(Fn, null, [L, ...b]), () => Vt(...b), "translate", (L) => Reflect.apply(L.t, L, [...b]), (L) => L, (L) => I(L));
|
|
2960
2959
|
}
|
|
2961
2960
|
function Et(...b) {
|
|
2962
|
-
const [L, V,
|
|
2963
|
-
if (
|
|
2961
|
+
const [L, V, j] = b;
|
|
2962
|
+
if (j && !F(j))
|
|
2964
2963
|
throw ne(G.INVALID_ARGUMENT);
|
|
2965
|
-
return Ge(L, V, Q({ resolvedMessage: !0 },
|
|
2964
|
+
return Ge(L, V, Q({ resolvedMessage: !0 }, j || {}));
|
|
2966
2965
|
}
|
|
2967
2966
|
function bt(...b) {
|
|
2968
|
-
return he((L) => Reflect.apply(Sn, null, [L, ...b]), () =>
|
|
2967
|
+
return he((L) => Reflect.apply(Sn, null, [L, ...b]), () => Kt(...b), "datetime format", (L) => Reflect.apply(L.d, L, [...b]), () => _t, (L) => I(L));
|
|
2969
2968
|
}
|
|
2970
2969
|
function vt(...b) {
|
|
2971
|
-
return he((L) => Reflect.apply(Pn, null, [L, ...b]), () =>
|
|
2970
|
+
return he((L) => Reflect.apply(Pn, null, [L, ...b]), () => Ut(...b), "number format", (L) => Reflect.apply(L.n, L, [...b]), () => _t, (L) => I(L));
|
|
2972
2971
|
}
|
|
2973
2972
|
function yt(b) {
|
|
2974
|
-
return b.map((L) => I(L) ||
|
|
2973
|
+
return b.map((L) => I(L) || J(L) || K(L) ? Kn(String(L)) : L);
|
|
2975
2974
|
}
|
|
2976
2975
|
const Nt = {
|
|
2977
2976
|
normalize: yt,
|
|
@@ -2981,20 +2980,20 @@ function rn(e = {}) {
|
|
|
2981
2980
|
function rt(...b) {
|
|
2982
2981
|
return he((L) => {
|
|
2983
2982
|
let V;
|
|
2984
|
-
const
|
|
2983
|
+
const j = L;
|
|
2985
2984
|
try {
|
|
2986
|
-
|
|
2985
|
+
j.processor = Nt, V = Reflect.apply(Fn, null, [j, ...b]);
|
|
2987
2986
|
} finally {
|
|
2988
|
-
|
|
2987
|
+
j.processor = null;
|
|
2989
2988
|
}
|
|
2990
2989
|
return V;
|
|
2991
|
-
}, () => Vt(...b), "translate", (L) => L[$t](...b), (L) => [
|
|
2990
|
+
}, () => Vt(...b), "translate", (L) => L[$t](...b), (L) => [Kn(L)], (L) => q(L));
|
|
2992
2991
|
}
|
|
2993
2992
|
function Tt(...b) {
|
|
2994
|
-
return he((L) => Reflect.apply(Pn, null, [L, ...b]), () =>
|
|
2993
|
+
return he((L) => Reflect.apply(Pn, null, [L, ...b]), () => Ut(...b), "number format", (L) => L[Gt](...b), Vn, (L) => I(L) || q(L));
|
|
2995
2994
|
}
|
|
2996
2995
|
function Lt(...b) {
|
|
2997
|
-
return he((L) => Reflect.apply(Sn, null, [L, ...b]), () =>
|
|
2996
|
+
return he((L) => Reflect.apply(Sn, null, [L, ...b]), () => Kt(...b), "datetime format", (L) => L[Wt](...b), Vn, (L) => I(L) || q(L));
|
|
2998
2997
|
}
|
|
2999
2998
|
function Ot(b) {
|
|
3000
2999
|
E = b, g.pluralRules = E;
|
|
@@ -3003,15 +3002,15 @@ function rn(e = {}) {
|
|
|
3003
3002
|
return he(() => {
|
|
3004
3003
|
if (!b)
|
|
3005
3004
|
return !1;
|
|
3006
|
-
const V = I(L) ? L : c.value,
|
|
3005
|
+
const V = I(L) ? L : c.value, j = Ce(V), Ie = g.messageResolver(j, b);
|
|
3007
3006
|
return ye(Ie) || se(Ie) || I(Ie);
|
|
3008
|
-
}, () => [b], "translate exists", (V) => Reflect.apply(V.te, V, [b, L]),
|
|
3007
|
+
}, () => [b], "translate exists", (V) => Reflect.apply(V.te, V, [b, L]), qa, (V) => K(V));
|
|
3009
3008
|
}
|
|
3010
3009
|
function Be(b) {
|
|
3011
3010
|
let L = null;
|
|
3012
|
-
const V =
|
|
3013
|
-
for (let
|
|
3014
|
-
const Ie = p.value[V[
|
|
3011
|
+
const V = rr(g, f.value, c.value);
|
|
3012
|
+
for (let j = 0; j < V.length; j++) {
|
|
3013
|
+
const Ie = p.value[V[j]] || {}, st = g.messageResolver(Ie, b);
|
|
3015
3014
|
if (st != null) {
|
|
3016
3015
|
L = st;
|
|
3017
3016
|
break;
|
|
@@ -3029,8 +3028,8 @@ function rn(e = {}) {
|
|
|
3029
3028
|
function He(b, L) {
|
|
3030
3029
|
if (a) {
|
|
3031
3030
|
const V = { [b]: L };
|
|
3032
|
-
for (const
|
|
3033
|
-
ae(V,
|
|
3031
|
+
for (const j in V)
|
|
3032
|
+
ae(V, j) && et(V[j]);
|
|
3034
3033
|
L = V[b];
|
|
3035
3034
|
}
|
|
3036
3035
|
p.value[b] = L, g.messages = p.value;
|
|
@@ -3039,18 +3038,18 @@ function rn(e = {}) {
|
|
|
3039
3038
|
p.value[b] = p.value[b] || {};
|
|
3040
3039
|
const V = { [b]: L };
|
|
3041
3040
|
if (a)
|
|
3042
|
-
for (const
|
|
3043
|
-
ae(V,
|
|
3041
|
+
for (const j in V)
|
|
3042
|
+
ae(V, j) && et(V[j]);
|
|
3044
3043
|
L = V[b], ut(L, p.value[b]), g.messages = p.value;
|
|
3045
3044
|
}
|
|
3046
3045
|
function _(b) {
|
|
3047
|
-
return
|
|
3046
|
+
return y.value[b] || {};
|
|
3048
3047
|
}
|
|
3049
3048
|
function h(b, L) {
|
|
3050
|
-
|
|
3049
|
+
y.value[b] = L, g.datetimeFormats = y.value, Dn(g, b, L);
|
|
3051
3050
|
}
|
|
3052
3051
|
function T(b, L) {
|
|
3053
|
-
|
|
3052
|
+
y.value[b] = Q(y.value[b] || {}, L), g.datetimeFormats = y.value, Dn(g, b, L);
|
|
3054
3053
|
}
|
|
3055
3054
|
function S(b) {
|
|
3056
3055
|
return N.value[b] || {};
|
|
@@ -3062,11 +3061,11 @@ function rn(e = {}) {
|
|
|
3062
3061
|
N.value[b] = Q(N.value[b] || {}, L), g.numberFormats = N.value, Rn(g, b, L);
|
|
3063
3062
|
}
|
|
3064
3063
|
xn++, t && ie && (Rt(t.locale, (b) => {
|
|
3065
|
-
i && (c.value = b, g.locale = b,
|
|
3064
|
+
i && (c.value = b, g.locale = b, Xe(g, c.value, f.value));
|
|
3066
3065
|
}), Rt(t.fallbackLocale, (b) => {
|
|
3067
|
-
i && (f.value = b, g.fallbackLocale = b,
|
|
3066
|
+
i && (f.value = b, g.fallbackLocale = b, Xe(g, c.value, f.value));
|
|
3068
3067
|
}));
|
|
3069
|
-
const
|
|
3068
|
+
const U = {
|
|
3070
3069
|
id: xn,
|
|
3071
3070
|
locale: M,
|
|
3072
3071
|
fallbackLocale: B,
|
|
@@ -3074,7 +3073,7 @@ function rn(e = {}) {
|
|
|
3074
3073
|
return i;
|
|
3075
3074
|
},
|
|
3076
3075
|
set inheritLocale(b) {
|
|
3077
|
-
i = b, b && t && (c.value = t.locale.value, f.value = t.fallbackLocale.value,
|
|
3076
|
+
i = b, b && t && (c.value = t.locale.value, f.value = t.fallbackLocale.value, Xe(g, c.value, f.value));
|
|
3078
3077
|
},
|
|
3079
3078
|
get availableLocales() {
|
|
3080
3079
|
return Object.keys(p.value).sort();
|
|
@@ -3090,10 +3089,10 @@ function rn(e = {}) {
|
|
|
3090
3089
|
return r;
|
|
3091
3090
|
},
|
|
3092
3091
|
get missingWarn() {
|
|
3093
|
-
return
|
|
3092
|
+
return v;
|
|
3094
3093
|
},
|
|
3095
3094
|
set missingWarn(b) {
|
|
3096
|
-
|
|
3095
|
+
v = b, g.missingWarn = v;
|
|
3097
3096
|
},
|
|
3098
3097
|
get fallbackWarn() {
|
|
3099
3098
|
return C;
|
|
@@ -3133,68 +3132,68 @@ function rn(e = {}) {
|
|
|
3133
3132
|
setPostTranslationHandler: ee,
|
|
3134
3133
|
getMissingHandler: Ee,
|
|
3135
3134
|
setMissingHandler: Me,
|
|
3136
|
-
[
|
|
3135
|
+
[pr]: Ot
|
|
3137
3136
|
};
|
|
3138
|
-
return
|
|
3137
|
+
return U.datetimeFormats = oe, U.numberFormats = le, U.rt = Et, U.te = Ct, U.tm = Ye, U.d = bt, U.n = vt, U.getDateTimeFormat = _, U.setDateTimeFormat = h, U.mergeDateTimeFormat = T, U.getNumberFormat = S, U.setNumberFormat = Y, U.mergeNumberFormat = H, U[Er] = n, U[$t] = rt, U[Wt] = Lt, U[Gt] = Tt, process.env.NODE_ENV !== "production" && (U[Pe] = (b) => {
|
|
3139
3138
|
g.__v_emitter = b;
|
|
3140
|
-
},
|
|
3139
|
+
}, U[ze] = () => {
|
|
3141
3140
|
g.__v_emitter = void 0;
|
|
3142
|
-
}),
|
|
3141
|
+
}), U;
|
|
3143
3142
|
}
|
|
3144
|
-
const
|
|
3143
|
+
const yr = "vue-i18n: composer properties", Dt = {
|
|
3145
3144
|
"vue-devtools-plugin-vue-i18n": "Vue I18n DevTools",
|
|
3146
3145
|
"vue-i18n-resource-inspector": "Vue I18n DevTools",
|
|
3147
3146
|
"vue-i18n-timeline": "Vue I18n"
|
|
3148
|
-
},
|
|
3147
|
+
}, Qa = {
|
|
3149
3148
|
"vue-i18n-resource-inspector": "Search for scopes ..."
|
|
3150
|
-
},
|
|
3149
|
+
}, Za = {
|
|
3151
3150
|
"vue-i18n-timeline": 16764185
|
|
3152
3151
|
};
|
|
3153
3152
|
let Yt;
|
|
3154
|
-
async function
|
|
3153
|
+
async function za(e, t) {
|
|
3155
3154
|
return new Promise((n, r) => {
|
|
3156
3155
|
try {
|
|
3157
|
-
|
|
3156
|
+
Ba({
|
|
3158
3157
|
id: "vue-devtools-plugin-vue-i18n",
|
|
3159
3158
|
label: Dt["vue-devtools-plugin-vue-i18n"],
|
|
3160
3159
|
packageName: "vue-i18n",
|
|
3161
3160
|
homepage: "https://vue-i18n.intlify.dev",
|
|
3162
3161
|
logo: "https://vue-i18n.intlify.dev/vue-i18n-devtools-logo.png",
|
|
3163
|
-
componentStateTypes: [
|
|
3162
|
+
componentStateTypes: [yr],
|
|
3164
3163
|
app: e
|
|
3165
3164
|
// eslint-disable-line @typescript-eslint/no-explicit-any
|
|
3166
3165
|
}, (a) => {
|
|
3167
3166
|
Yt = a, a.on.visitComponentTree(({ componentInstance: i, treeNode: c }) => {
|
|
3168
|
-
|
|
3167
|
+
ei(i, c, t);
|
|
3169
3168
|
}), a.on.inspectComponent(({ componentInstance: i, instanceData: c }) => {
|
|
3170
3169
|
i.vnode.el && i.vnode.el.__VUE_I18N__ && c && (t.mode === "legacy" ? i.vnode.el.__VUE_I18N__ !== t.global.__composer && Wn(c, i.vnode.el.__VUE_I18N__) : Wn(c, i.vnode.el.__VUE_I18N__));
|
|
3171
3170
|
}), a.addInspector({
|
|
3172
3171
|
id: "vue-i18n-resource-inspector",
|
|
3173
3172
|
label: Dt["vue-i18n-resource-inspector"],
|
|
3174
3173
|
icon: "language",
|
|
3175
|
-
treeFilterPlaceholder:
|
|
3174
|
+
treeFilterPlaceholder: Qa["vue-i18n-resource-inspector"]
|
|
3176
3175
|
}), a.on.getInspectorTree((i) => {
|
|
3177
|
-
i.app === e && i.inspectorId === "vue-i18n-resource-inspector" &&
|
|
3176
|
+
i.app === e && i.inspectorId === "vue-i18n-resource-inspector" && ai(i, t);
|
|
3178
3177
|
});
|
|
3179
3178
|
const s = /* @__PURE__ */ new Map();
|
|
3180
3179
|
a.on.getInspectorState(async (i) => {
|
|
3181
3180
|
if (i.app === e && i.inspectorId === "vue-i18n-resource-inspector")
|
|
3182
|
-
if (a.unhighlightElement(),
|
|
3181
|
+
if (a.unhighlightElement(), oi(i, t), i.nodeId === "global") {
|
|
3183
3182
|
if (!s.has(i.app)) {
|
|
3184
3183
|
const [c] = await a.getComponentInstances(i.app);
|
|
3185
3184
|
s.set(i.app, c);
|
|
3186
3185
|
}
|
|
3187
3186
|
a.highlightElement(s.get(i.app));
|
|
3188
3187
|
} else {
|
|
3189
|
-
const c =
|
|
3188
|
+
const c = ii(i.nodeId, t);
|
|
3190
3189
|
c && a.highlightElement(c);
|
|
3191
3190
|
}
|
|
3192
3191
|
}), a.on.editInspectorState((i) => {
|
|
3193
|
-
i.app === e && i.inspectorId === "vue-i18n-resource-inspector" &&
|
|
3192
|
+
i.app === e && i.inspectorId === "vue-i18n-resource-inspector" && ci(i, t);
|
|
3194
3193
|
}), a.addTimelineLayer({
|
|
3195
3194
|
id: "vue-i18n-timeline",
|
|
3196
3195
|
label: Dt["vue-i18n-timeline"],
|
|
3197
|
-
color:
|
|
3196
|
+
color: Za["vue-i18n-timeline"]
|
|
3198
3197
|
}), n(!0);
|
|
3199
3198
|
});
|
|
3200
3199
|
} catch (a) {
|
|
@@ -3202,14 +3201,14 @@ async function ti(e, t) {
|
|
|
3202
3201
|
}
|
|
3203
3202
|
});
|
|
3204
3203
|
}
|
|
3205
|
-
function
|
|
3204
|
+
function Nr(e) {
|
|
3206
3205
|
return e.type.name || e.type.displayName || e.type.__file || "Anonymous";
|
|
3207
3206
|
}
|
|
3208
|
-
function
|
|
3207
|
+
function ei(e, t, n) {
|
|
3209
3208
|
const r = n.mode === "composition" ? n.global : n.global.__composer;
|
|
3210
3209
|
if (e && e.vnode.el && e.vnode.el.__VUE_I18N__ && e.vnode.el.__VUE_I18N__ !== r) {
|
|
3211
3210
|
const a = {
|
|
3212
|
-
label: `i18n (${
|
|
3211
|
+
label: `i18n (${Nr(e)} Scope)`,
|
|
3213
3212
|
textColor: 0,
|
|
3214
3213
|
backgroundColor: 16764185
|
|
3215
3214
|
};
|
|
@@ -3217,7 +3216,7 @@ function ni(e, t, n) {
|
|
|
3217
3216
|
}
|
|
3218
3217
|
}
|
|
3219
3218
|
function Wn(e, t) {
|
|
3220
|
-
const n =
|
|
3219
|
+
const n = yr;
|
|
3221
3220
|
e.state.push({
|
|
3222
3221
|
type: n,
|
|
3223
3222
|
key: "locale",
|
|
@@ -3242,7 +3241,7 @@ function Wn(e, t) {
|
|
|
3242
3241
|
type: n,
|
|
3243
3242
|
key: "messages",
|
|
3244
3243
|
editable: !1,
|
|
3245
|
-
value:
|
|
3244
|
+
value: an(t.messages.value)
|
|
3246
3245
|
}), e.state.push({
|
|
3247
3246
|
type: n,
|
|
3248
3247
|
key: "datetimeFormats",
|
|
@@ -3255,34 +3254,34 @@ function Wn(e, t) {
|
|
|
3255
3254
|
value: t.numberFormats.value
|
|
3256
3255
|
});
|
|
3257
3256
|
}
|
|
3258
|
-
function
|
|
3257
|
+
function an(e) {
|
|
3259
3258
|
const t = {};
|
|
3260
3259
|
return Object.keys(e).forEach((n) => {
|
|
3261
3260
|
const r = e[n];
|
|
3262
|
-
W(r) && "source" in r ? t[n] =
|
|
3261
|
+
W(r) && "source" in r ? t[n] = si(r) : ye(r) && r.loc && r.loc.source ? t[n] = r.loc.source : F(r) ? t[n] = an(r) : t[n] = r;
|
|
3263
3262
|
}), t;
|
|
3264
3263
|
}
|
|
3265
|
-
const
|
|
3264
|
+
const ti = {
|
|
3266
3265
|
"<": "<",
|
|
3267
3266
|
">": ">",
|
|
3268
3267
|
'"': """,
|
|
3269
3268
|
"&": "&"
|
|
3270
3269
|
};
|
|
3271
|
-
function
|
|
3272
|
-
return e.replace(/[<>"&]/g,
|
|
3270
|
+
function ni(e) {
|
|
3271
|
+
return e.replace(/[<>"&]/g, ri);
|
|
3273
3272
|
}
|
|
3274
|
-
function
|
|
3275
|
-
return
|
|
3273
|
+
function ri(e) {
|
|
3274
|
+
return ti[e] || e;
|
|
3276
3275
|
}
|
|
3277
|
-
function
|
|
3276
|
+
function si(e) {
|
|
3278
3277
|
return {
|
|
3279
3278
|
_custom: {
|
|
3280
3279
|
type: "function",
|
|
3281
|
-
display: `<span>ƒ</span> ${e.source ? `("${
|
|
3280
|
+
display: `<span>ƒ</span> ${e.source ? `("${ni(e.source)}")` : "(?)"}`
|
|
3282
3281
|
}
|
|
3283
3282
|
};
|
|
3284
3283
|
}
|
|
3285
|
-
function
|
|
3284
|
+
function ai(e, t) {
|
|
3286
3285
|
e.rootNodes.push({
|
|
3287
3286
|
id: "global",
|
|
3288
3287
|
label: "Global Scope"
|
|
@@ -3292,11 +3291,11 @@ function oi(e, t) {
|
|
|
3292
3291
|
const s = t.mode === "composition" ? a : a.__composer;
|
|
3293
3292
|
n !== s && e.rootNodes.push({
|
|
3294
3293
|
id: s.id.toString(),
|
|
3295
|
-
label: `${
|
|
3294
|
+
label: `${Nr(r)} Scope`
|
|
3296
3295
|
});
|
|
3297
3296
|
}
|
|
3298
3297
|
}
|
|
3299
|
-
function
|
|
3298
|
+
function ii(e, t) {
|
|
3300
3299
|
let n = null;
|
|
3301
3300
|
if (e !== "global") {
|
|
3302
3301
|
for (const [r, a] of t.__instances.entries())
|
|
@@ -3307,7 +3306,7 @@ function li(e, t) {
|
|
|
3307
3306
|
}
|
|
3308
3307
|
return n;
|
|
3309
3308
|
}
|
|
3310
|
-
function
|
|
3309
|
+
function Tr(e, t) {
|
|
3311
3310
|
if (e === "global")
|
|
3312
3311
|
return t.mode === "composition" ? t.global : t.global.__composer;
|
|
3313
3312
|
{
|
|
@@ -3315,11 +3314,11 @@ function Lr(e, t) {
|
|
|
3315
3314
|
return n ? t.mode === "composition" ? n : n.__composer : null;
|
|
3316
3315
|
}
|
|
3317
3316
|
}
|
|
3318
|
-
function
|
|
3319
|
-
const n =
|
|
3320
|
-
return n && (e.state =
|
|
3317
|
+
function oi(e, t) {
|
|
3318
|
+
const n = Tr(e.nodeId, t);
|
|
3319
|
+
return n && (e.state = li(n)), null;
|
|
3321
3320
|
}
|
|
3322
|
-
function
|
|
3321
|
+
function li(e) {
|
|
3323
3322
|
const t = {}, n = "Locale related info", r = [
|
|
3324
3323
|
{
|
|
3325
3324
|
type: n,
|
|
@@ -3352,7 +3351,7 @@ function ui(e) {
|
|
|
3352
3351
|
type: a,
|
|
3353
3352
|
key: "messages",
|
|
3354
3353
|
editable: !1,
|
|
3355
|
-
value:
|
|
3354
|
+
value: an(e.messages.value)
|
|
3356
3355
|
}
|
|
3357
3356
|
];
|
|
3358
3357
|
t[a] = s;
|
|
@@ -3394,15 +3393,15 @@ function tt(e, t) {
|
|
|
3394
3393
|
});
|
|
3395
3394
|
}
|
|
3396
3395
|
}
|
|
3397
|
-
function
|
|
3398
|
-
const n =
|
|
3396
|
+
function ci(e, t) {
|
|
3397
|
+
const n = Tr(e.nodeId, t);
|
|
3399
3398
|
if (n) {
|
|
3400
3399
|
const [r] = e.path;
|
|
3401
|
-
r === "locale" && I(e.state.value) ? n.locale.value = e.state.value : r === "fallbackLocale" && (I(e.state.value) ||
|
|
3400
|
+
r === "locale" && I(e.state.value) ? n.locale.value = e.state.value : r === "fallbackLocale" && (I(e.state.value) || q(e.state.value) || F(e.state.value)) ? n.fallbackLocale.value = e.state.value : r === "inheritLocale" && K(e.state.value) && (n.inheritLocale = e.state.value);
|
|
3402
3401
|
}
|
|
3403
3402
|
}
|
|
3404
|
-
function
|
|
3405
|
-
const t = I(e.locale) ? e.locale : Ze, n = I(e.fallbackLocale) ||
|
|
3403
|
+
function ui(e) {
|
|
3404
|
+
const t = I(e.locale) ? e.locale : Ze, n = I(e.fallbackLocale) || q(e.fallbackLocale) || w(e.fallbackLocale) || e.fallbackLocale === !1 ? e.fallbackLocale : t, r = W(e.missing) ? e.missing : void 0, a = K(e.silentTranslationWarn) || Ve(e.silentTranslationWarn) ? !e.silentTranslationWarn : !0, s = K(e.silentFallbackWarn) || Ve(e.silentFallbackWarn) ? !e.silentFallbackWarn : !0, i = K(e.fallbackRoot) ? e.fallbackRoot : !0, c = !!e.formatFallbackMessages, f = w(e.modifiers) ? e.modifiers : {}, p = e.pluralizationRules, y = W(e.postTranslation) ? e.postTranslation : void 0, N = I(e.warnHtmlInMessage) ? e.warnHtmlInMessage !== "off" : !0, v = !!e.escapeParameterHtml, C = K(e.sync) ? e.sync : !0;
|
|
3406
3405
|
let D = e.messages;
|
|
3407
3406
|
if (w(e.sharedMessages)) {
|
|
3408
3407
|
const d = e.sharedMessages;
|
|
@@ -3426,9 +3425,9 @@ function _i(e) {
|
|
|
3426
3425
|
fallbackFormat: c,
|
|
3427
3426
|
modifiers: f,
|
|
3428
3427
|
pluralRules: p,
|
|
3429
|
-
postTranslation:
|
|
3428
|
+
postTranslation: y,
|
|
3430
3429
|
warnHtmlMessage: N,
|
|
3431
|
-
escapeParameter:
|
|
3430
|
+
escapeParameter: v,
|
|
3432
3431
|
messageResolver: e.messageResolver,
|
|
3433
3432
|
inheritLocale: C,
|
|
3434
3433
|
__i18n: A,
|
|
@@ -3437,7 +3436,7 @@ function _i(e) {
|
|
|
3437
3436
|
};
|
|
3438
3437
|
}
|
|
3439
3438
|
function Ht(e = {}) {
|
|
3440
|
-
const t =
|
|
3439
|
+
const t = sn(ui(e)), { __extender: n } = e, r = {
|
|
3441
3440
|
// id
|
|
3442
3441
|
id: t.id,
|
|
3443
3442
|
// locale
|
|
@@ -3479,17 +3478,17 @@ function Ht(e = {}) {
|
|
|
3479
3478
|
},
|
|
3480
3479
|
// silentTranslationWarn
|
|
3481
3480
|
get silentTranslationWarn() {
|
|
3482
|
-
return
|
|
3481
|
+
return K(t.missingWarn) ? !t.missingWarn : t.missingWarn;
|
|
3483
3482
|
},
|
|
3484
3483
|
set silentTranslationWarn(a) {
|
|
3485
|
-
t.missingWarn =
|
|
3484
|
+
t.missingWarn = K(a) ? !a : a;
|
|
3486
3485
|
},
|
|
3487
3486
|
// silentFallbackWarn
|
|
3488
3487
|
get silentFallbackWarn() {
|
|
3489
|
-
return
|
|
3488
|
+
return K(t.fallbackWarn) ? !t.fallbackWarn : t.fallbackWarn;
|
|
3490
3489
|
},
|
|
3491
3490
|
set silentFallbackWarn(a) {
|
|
3492
|
-
t.fallbackWarn =
|
|
3491
|
+
t.fallbackWarn = K(a) ? !a : a;
|
|
3493
3492
|
},
|
|
3494
3493
|
// modifiers
|
|
3495
3494
|
get modifiers() {
|
|
@@ -3605,10 +3604,10 @@ function Ht(e = {}) {
|
|
|
3605
3604
|
a[ze] && a[ze]();
|
|
3606
3605
|
}), r;
|
|
3607
3606
|
}
|
|
3608
|
-
function
|
|
3607
|
+
function fi(e, t, n) {
|
|
3609
3608
|
return {
|
|
3610
3609
|
beforeCreate() {
|
|
3611
|
-
const r =
|
|
3610
|
+
const r = qe();
|
|
3612
3611
|
if (!r)
|
|
3613
3612
|
throw ne(G.UNEXPECTED_ERROR);
|
|
3614
3613
|
const a = this.$options;
|
|
@@ -3636,18 +3635,18 @@ function di(e, t, n) {
|
|
|
3636
3635
|
}
|
|
3637
3636
|
else
|
|
3638
3637
|
this.$i18n = e;
|
|
3639
|
-
a.__i18nGlobal &&
|
|
3638
|
+
a.__i18nGlobal && vr(t, a, a), this.$t = (...s) => this.$i18n.t(...s), this.$rt = (...s) => this.$i18n.rt(...s), this.$te = (s, i) => this.$i18n.te(s, i), this.$d = (...s) => this.$i18n.d(...s), this.$n = (...s) => this.$i18n.n(...s), this.$tm = (s) => this.$i18n.tm(s), n.__setInstance(r, this.$i18n);
|
|
3640
3639
|
},
|
|
3641
3640
|
mounted() {
|
|
3642
3641
|
if (process.env.NODE_ENV !== "production" && this.$el && this.$i18n) {
|
|
3643
3642
|
const r = this.$i18n;
|
|
3644
3643
|
this.$el.__VUE_I18N__ = r.__composer;
|
|
3645
|
-
const a = this.__v_emitter =
|
|
3644
|
+
const a = this.__v_emitter = Zt();
|
|
3646
3645
|
r.__enableEmitter && r.__enableEmitter(a), a.on("*", tt);
|
|
3647
3646
|
}
|
|
3648
3647
|
},
|
|
3649
3648
|
unmounted() {
|
|
3650
|
-
const r =
|
|
3649
|
+
const r = qe();
|
|
3651
3650
|
if (!r)
|
|
3652
3651
|
throw ne(G.UNEXPECTED_ERROR);
|
|
3653
3652
|
const a = this.$i18n;
|
|
@@ -3656,14 +3655,14 @@ function di(e, t, n) {
|
|
|
3656
3655
|
};
|
|
3657
3656
|
}
|
|
3658
3657
|
function Gn(e, t) {
|
|
3659
|
-
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[
|
|
3660
|
-
const n =
|
|
3658
|
+
e.locale = t.locale || e.locale, e.fallbackLocale = t.fallbackLocale || e.fallbackLocale, e.missing = t.missing || e.missing, e.silentTranslationWarn = t.silentTranslationWarn || e.silentFallbackWarn, e.silentFallbackWarn = t.silentFallbackWarn || e.silentFallbackWarn, e.formatFallbackMessages = t.formatFallbackMessages || e.formatFallbackMessages, e.postTranslation = t.postTranslation || e.postTranslation, e.warnHtmlInMessage = t.warnHtmlInMessage || e.warnHtmlInMessage, e.escapeParameterHtml = t.escapeParameterHtml || e.escapeParameterHtml, e.sync = t.sync || e.sync, e.__composer[pr](t.pluralizationRules || e.pluralizationRules);
|
|
3659
|
+
const n = rn(e.locale, {
|
|
3661
3660
|
messages: t.messages,
|
|
3662
3661
|
__i18n: t.__i18n
|
|
3663
3662
|
});
|
|
3664
3663
|
return Object.keys(n).forEach((r) => e.mergeLocaleMessage(r, n[r])), t.datetimeFormats && Object.keys(t.datetimeFormats).forEach((r) => e.mergeDateTimeFormat(r, t.datetimeFormats[r])), t.numberFormats && Object.keys(t.numberFormats).forEach((r) => e.mergeNumberFormat(r, t.numberFormats[r])), e;
|
|
3665
3664
|
}
|
|
3666
|
-
const
|
|
3665
|
+
const on = {
|
|
3667
3666
|
tag: {
|
|
3668
3667
|
type: [String, Object]
|
|
3669
3668
|
},
|
|
@@ -3681,20 +3680,20 @@ const an = {
|
|
|
3681
3680
|
type: Object
|
|
3682
3681
|
}
|
|
3683
3682
|
};
|
|
3684
|
-
function
|
|
3683
|
+
function _i({ slots: e }, t) {
|
|
3685
3684
|
return t.length === 1 && t[0] === "default" ? (e.default ? e.default() : []).reduce((r, a) => [
|
|
3686
3685
|
...r,
|
|
3687
3686
|
// prettier-ignore
|
|
3688
|
-
...a.type ===
|
|
3687
|
+
...a.type === zn ? a.children : [a]
|
|
3689
3688
|
], []) : t.reduce((n, r) => {
|
|
3690
3689
|
const a = e[r];
|
|
3691
3690
|
return a && (n[r] = a()), n;
|
|
3692
3691
|
}, $());
|
|
3693
3692
|
}
|
|
3694
|
-
function
|
|
3695
|
-
return
|
|
3693
|
+
function Lr() {
|
|
3694
|
+
return zn;
|
|
3696
3695
|
}
|
|
3697
|
-
const
|
|
3696
|
+
const di = /* @__PURE__ */ Xt({
|
|
3698
3697
|
/* eslint-disable */
|
|
3699
3698
|
name: "i18n-t",
|
|
3700
3699
|
props: Q({
|
|
@@ -3704,44 +3703,44 @@ const hi = /* @__PURE__ */ Xt({
|
|
|
3704
3703
|
},
|
|
3705
3704
|
plural: {
|
|
3706
3705
|
type: [Number, String],
|
|
3707
|
-
validator: (e) =>
|
|
3706
|
+
validator: (e) => J(e) || !isNaN(e)
|
|
3708
3707
|
}
|
|
3709
|
-
},
|
|
3708
|
+
}, on),
|
|
3710
3709
|
/* eslint-enable */
|
|
3711
3710
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
3712
3711
|
setup(e, t) {
|
|
3713
|
-
const { slots: n, attrs: r } = t, a = e.i18n ||
|
|
3712
|
+
const { slots: n, attrs: r } = t, a = e.i18n || ln({
|
|
3714
3713
|
useScope: e.scope,
|
|
3715
3714
|
__useComponent: !0
|
|
3716
3715
|
});
|
|
3717
3716
|
return () => {
|
|
3718
3717
|
const s = Object.keys(n).filter((N) => N !== "_"), i = $();
|
|
3719
3718
|
e.locale && (i.locale = e.locale), e.plural !== void 0 && (i.plural = I(e.plural) ? +e.plural : e.plural);
|
|
3720
|
-
const c =
|
|
3721
|
-
return
|
|
3719
|
+
const c = _i(t, s), f = a[$t](e.keypath, c, i), p = Q($(), r), y = I(e.tag) || F(e.tag) ? e.tag : Lr();
|
|
3720
|
+
return Zn(y, p, f);
|
|
3722
3721
|
};
|
|
3723
3722
|
}
|
|
3724
|
-
}), Bn =
|
|
3725
|
-
function
|
|
3726
|
-
return
|
|
3723
|
+
}), Bn = di;
|
|
3724
|
+
function mi(e) {
|
|
3725
|
+
return q(e) && !I(e[0]);
|
|
3727
3726
|
}
|
|
3728
|
-
function
|
|
3727
|
+
function Or(e, t, n, r) {
|
|
3729
3728
|
const { slots: a, attrs: s } = t;
|
|
3730
3729
|
return () => {
|
|
3731
3730
|
const i = { part: !0 };
|
|
3732
3731
|
let c = $();
|
|
3733
|
-
e.locale && (i.locale = e.locale), I(e.format) ? i.key = e.format : F(e.format) && (I(e.format.key) && (i.key = e.format.key), c = Object.keys(e.format).reduce((
|
|
3732
|
+
e.locale && (i.locale = e.locale), I(e.format) ? i.key = e.format : F(e.format) && (I(e.format.key) && (i.key = e.format.key), c = Object.keys(e.format).reduce((v, C) => n.includes(C) ? Q($(), v, { [C]: e.format[C] }) : v, $()));
|
|
3734
3733
|
const f = r(e.value, i, c);
|
|
3735
3734
|
let p = [i.key];
|
|
3736
|
-
|
|
3737
|
-
const D = a[
|
|
3738
|
-
return
|
|
3735
|
+
q(f) ? p = f.map((v, C) => {
|
|
3736
|
+
const D = a[v.type], A = D ? D({ [v.type]: v.value, index: C, parts: f }) : [v.value];
|
|
3737
|
+
return mi(A) && (A[0].key = `${v.type}-${C}`), A;
|
|
3739
3738
|
}) : I(f) && (p = [f]);
|
|
3740
|
-
const
|
|
3741
|
-
return
|
|
3739
|
+
const y = Q($(), s), N = I(e.tag) || F(e.tag) ? e.tag : Lr();
|
|
3740
|
+
return Zn(N, y, p);
|
|
3742
3741
|
};
|
|
3743
3742
|
}
|
|
3744
|
-
const
|
|
3743
|
+
const hi = /* @__PURE__ */ Xt({
|
|
3745
3744
|
/* eslint-disable */
|
|
3746
3745
|
name: "i18n-n",
|
|
3747
3746
|
props: Q({
|
|
@@ -3752,21 +3751,21 @@ const pi = /* @__PURE__ */ Xt({
|
|
|
3752
3751
|
format: {
|
|
3753
3752
|
type: [String, Object]
|
|
3754
3753
|
}
|
|
3755
|
-
},
|
|
3754
|
+
}, on),
|
|
3756
3755
|
/* eslint-enable */
|
|
3757
3756
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
3758
3757
|
setup(e, t) {
|
|
3759
|
-
const n = e.i18n ||
|
|
3758
|
+
const n = e.i18n || ln({
|
|
3760
3759
|
useScope: e.scope,
|
|
3761
3760
|
__useComponent: !0
|
|
3762
3761
|
});
|
|
3763
|
-
return
|
|
3762
|
+
return Or(e, t, dr, (...r) => (
|
|
3764
3763
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
3765
3764
|
n[Gt](...r)
|
|
3766
3765
|
));
|
|
3767
3766
|
}
|
|
3768
|
-
}), Yn =
|
|
3769
|
-
function
|
|
3767
|
+
}), Yn = hi;
|
|
3768
|
+
function gi(e, t) {
|
|
3770
3769
|
const n = e;
|
|
3771
3770
|
if (e.mode === "composition")
|
|
3772
3771
|
return n.__getInstance(t) || e.global;
|
|
@@ -3775,15 +3774,15 @@ function Ei(e, t) {
|
|
|
3775
3774
|
return r != null ? r.__composer : e.global.__composer;
|
|
3776
3775
|
}
|
|
3777
3776
|
}
|
|
3778
|
-
function
|
|
3777
|
+
function pi(e) {
|
|
3779
3778
|
const t = (i) => {
|
|
3780
|
-
process.env.NODE_ENV !== "production" &&
|
|
3779
|
+
process.env.NODE_ENV !== "production" && Qt(nt(de.DEPRECATE_TRANSLATE_CUSTOME_DIRECTIVE));
|
|
3781
3780
|
const { instance: c, value: f } = i;
|
|
3782
3781
|
if (!c || !c.$)
|
|
3783
3782
|
throw ne(G.UNEXPECTED_ERROR);
|
|
3784
|
-
const p =
|
|
3783
|
+
const p = gi(e, c.$), y = Hn(f);
|
|
3785
3784
|
return [
|
|
3786
|
-
Reflect.apply(p.t, p, [...
|
|
3785
|
+
Reflect.apply(p.t, p, [...jn(y)]),
|
|
3787
3786
|
p
|
|
3788
3787
|
];
|
|
3789
3788
|
};
|
|
@@ -3801,7 +3800,7 @@ function bi(e) {
|
|
|
3801
3800
|
if (i.__composer) {
|
|
3802
3801
|
const f = i.__composer, p = Hn(c);
|
|
3803
3802
|
i.textContent = Reflect.apply(f.t, f, [
|
|
3804
|
-
...
|
|
3803
|
+
...jn(p)
|
|
3805
3804
|
]);
|
|
3806
3805
|
}
|
|
3807
3806
|
},
|
|
@@ -3821,48 +3820,48 @@ function Hn(e) {
|
|
|
3821
3820
|
} else
|
|
3822
3821
|
throw ne(G.INVALID_VALUE);
|
|
3823
3822
|
}
|
|
3824
|
-
function
|
|
3823
|
+
function jn(e) {
|
|
3825
3824
|
const { path: t, locale: n, args: r, choice: a, plural: s } = e, i = {}, c = r || {};
|
|
3826
|
-
return I(n) && (i.locale = n),
|
|
3825
|
+
return I(n) && (i.locale = n), J(a) && (i.plural = a), J(s) && (i.plural = s), [t, c, i];
|
|
3827
3826
|
}
|
|
3828
|
-
function
|
|
3827
|
+
function Ei(e, t, ...n) {
|
|
3829
3828
|
const r = w(n[0]) ? n[0] : {};
|
|
3830
|
-
(
|
|
3829
|
+
(K(r.globalInstall) ? r.globalInstall : !0) && ([Bn.name, "I18nT"].forEach((s) => e.component(s, Bn)), [Yn.name, "I18nN"].forEach((s) => e.component(s, Yn)), [qn.name, "I18nD"].forEach((s) => e.component(s, qn))), e.directive("t", pi(t));
|
|
3831
3830
|
}
|
|
3832
|
-
const
|
|
3833
|
-
function
|
|
3834
|
-
const t = __VUE_I18N_LEGACY_API__ &&
|
|
3835
|
-
process.env.NODE_ENV !== "production" && t &&
|
|
3836
|
-
const n =
|
|
3831
|
+
const bi = /* @__PURE__ */ me("global-vue-i18n");
|
|
3832
|
+
function vi(e = {}) {
|
|
3833
|
+
const t = __VUE_I18N_LEGACY_API__ && K(e.legacy) ? e.legacy : __VUE_I18N_LEGACY_API__;
|
|
3834
|
+
process.env.NODE_ENV !== "production" && t && Qt(nt(de.DEPRECATE_LEGACY_MODE));
|
|
3835
|
+
const n = K(e.globalInjection) ? e.globalInjection : !0, r = /* @__PURE__ */ new Map(), [a, s] = yi(e, t), i = /* @__PURE__ */ me(process.env.NODE_ENV !== "production" ? "vue-i18n" : "");
|
|
3837
3836
|
function c(N) {
|
|
3838
3837
|
return r.get(N) || null;
|
|
3839
3838
|
}
|
|
3840
|
-
function f(N,
|
|
3841
|
-
r.set(N,
|
|
3839
|
+
function f(N, v) {
|
|
3840
|
+
r.set(N, v);
|
|
3842
3841
|
}
|
|
3843
3842
|
function p(N) {
|
|
3844
3843
|
r.delete(N);
|
|
3845
3844
|
}
|
|
3846
|
-
const
|
|
3845
|
+
const y = {
|
|
3847
3846
|
// mode
|
|
3848
3847
|
get mode() {
|
|
3849
3848
|
return __VUE_I18N_LEGACY_API__ && t ? "legacy" : "composition";
|
|
3850
3849
|
},
|
|
3851
3850
|
// install plugin
|
|
3852
|
-
async install(N, ...
|
|
3853
|
-
if (process.env.NODE_ENV !== "production" && (N.__VUE_I18N__ =
|
|
3854
|
-
const A =
|
|
3855
|
-
|
|
3851
|
+
async install(N, ...v) {
|
|
3852
|
+
if (process.env.NODE_ENV !== "production" && (N.__VUE_I18N__ = y), N.__VUE_I18N_SYMBOL__ = i, N.provide(N.__VUE_I18N_SYMBOL__, y), w(v[0])) {
|
|
3853
|
+
const A = v[0];
|
|
3854
|
+
y.__composerExtend = A.__composerExtend, y.__vueI18nExtend = A.__vueI18nExtend;
|
|
3856
3855
|
}
|
|
3857
3856
|
let C = null;
|
|
3858
|
-
!t && n && (C =
|
|
3857
|
+
!t && n && (C = ki(N, y.global)), __VUE_I18N_FULL_INSTALL__ && Ei(N, y, ...v), __VUE_I18N_LEGACY_API__ && t && N.mixin(fi(s, s.__composer, y));
|
|
3859
3858
|
const D = N.unmount;
|
|
3860
3859
|
if (N.unmount = () => {
|
|
3861
|
-
C && C(),
|
|
3860
|
+
C && C(), y.dispose(), D();
|
|
3862
3861
|
}, process.env.NODE_ENV !== "production") {
|
|
3863
|
-
if (!await
|
|
3862
|
+
if (!await za(N, y))
|
|
3864
3863
|
throw ne(G.CANNOT_SETUP_VUE_DEVTOOLS_PLUGIN);
|
|
3865
|
-
const k =
|
|
3864
|
+
const k = Zt();
|
|
3866
3865
|
if (t) {
|
|
3867
3866
|
const o = s;
|
|
3868
3867
|
o.__enableEmitter && o.__enableEmitter(k);
|
|
@@ -3889,58 +3888,58 @@ function Ni(e = {}) {
|
|
|
3889
3888
|
// @internal
|
|
3890
3889
|
__deleteInstance: p
|
|
3891
3890
|
};
|
|
3892
|
-
return
|
|
3891
|
+
return y;
|
|
3893
3892
|
}
|
|
3894
|
-
function
|
|
3895
|
-
const t =
|
|
3893
|
+
function ln(e = {}) {
|
|
3894
|
+
const t = qe();
|
|
3896
3895
|
if (t == null)
|
|
3897
3896
|
throw ne(G.MUST_BE_CALL_SETUP_TOP);
|
|
3898
3897
|
if (!t.isCE && t.appContext.app != null && !t.appContext.app.__VUE_I18N_SYMBOL__)
|
|
3899
3898
|
throw ne(G.NOT_INSTALLED);
|
|
3900
|
-
const n =
|
|
3899
|
+
const n = Ni(t), r = Li(n), a = br(t), s = Ti(e, a);
|
|
3901
3900
|
if (s === "global")
|
|
3902
|
-
return
|
|
3901
|
+
return vr(r, e, a), r;
|
|
3903
3902
|
if (s === "parent") {
|
|
3904
|
-
let f =
|
|
3903
|
+
let f = Oi(n, t, e.__useComponent);
|
|
3905
3904
|
return f == null && (process.env.NODE_ENV !== "production" && Ne(nt(de.NOT_FOUND_PARENT_SCOPE)), f = r), f;
|
|
3906
3905
|
}
|
|
3907
3906
|
const i = n;
|
|
3908
3907
|
let c = i.__getInstance(t);
|
|
3909
3908
|
if (c == null) {
|
|
3910
3909
|
const f = Q({}, e);
|
|
3911
|
-
"__i18n" in a && (f.__i18n = a.__i18n), r && (f.__root = r), c =
|
|
3910
|
+
"__i18n" in a && (f.__i18n = a.__i18n), r && (f.__root = r), c = sn(f), i.__composerExtend && (c[Bt] = i.__composerExtend(c)), Ii(i, t, c), i.__setInstance(t, c);
|
|
3912
3911
|
}
|
|
3913
3912
|
return c;
|
|
3914
3913
|
}
|
|
3915
|
-
function
|
|
3916
|
-
const n =
|
|
3914
|
+
function yi(e, t) {
|
|
3915
|
+
const n = kr(), r = __VUE_I18N_LEGACY_API__ && t ? n.run(() => Ht(e)) : n.run(() => sn(e));
|
|
3917
3916
|
if (r == null)
|
|
3918
3917
|
throw ne(G.UNEXPECTED_ERROR);
|
|
3919
3918
|
return [n, r];
|
|
3920
3919
|
}
|
|
3921
|
-
function
|
|
3922
|
-
const t =
|
|
3920
|
+
function Ni(e) {
|
|
3921
|
+
const t = Rr(e.isCE ? bi : e.appContext.app.__VUE_I18N_SYMBOL__);
|
|
3923
3922
|
if (!t)
|
|
3924
3923
|
throw ne(e.isCE ? G.NOT_INSTALLED_WITH_PROVIDE : G.UNEXPECTED_ERROR);
|
|
3925
3924
|
return t;
|
|
3926
3925
|
}
|
|
3927
|
-
function
|
|
3926
|
+
function Ti(e, t) {
|
|
3928
3927
|
return mt(e) ? "__i18n" in t ? "local" : "global" : e.useScope ? e.useScope : "local";
|
|
3929
3928
|
}
|
|
3930
|
-
function
|
|
3929
|
+
function Li(e) {
|
|
3931
3930
|
return e.mode === "composition" ? e.global : e.global.__composer;
|
|
3932
3931
|
}
|
|
3933
|
-
function
|
|
3932
|
+
function Oi(e, t, n = !1) {
|
|
3934
3933
|
let r = null;
|
|
3935
3934
|
const a = t.root;
|
|
3936
|
-
let s =
|
|
3935
|
+
let s = Ci(t, n);
|
|
3937
3936
|
for (; s != null; ) {
|
|
3938
3937
|
const i = e;
|
|
3939
3938
|
if (e.mode === "composition")
|
|
3940
3939
|
r = i.__getInstance(s);
|
|
3941
3940
|
else if (__VUE_I18N_LEGACY_API__) {
|
|
3942
3941
|
const c = i.__getInstance(s);
|
|
3943
|
-
c != null && (r = c.__composer, n && r && !r[
|
|
3942
|
+
c != null && (r = c.__composer, n && r && !r[Er] && (r = null));
|
|
3944
3943
|
}
|
|
3945
3944
|
if (r != null || a === s)
|
|
3946
3945
|
break;
|
|
@@ -3948,36 +3947,36 @@ function Ii(e, t, n = !1) {
|
|
|
3948
3947
|
}
|
|
3949
3948
|
return r;
|
|
3950
3949
|
}
|
|
3951
|
-
function
|
|
3950
|
+
function Ci(e, t = !1) {
|
|
3952
3951
|
return e == null ? null : t && e.vnode.ctx || e.parent;
|
|
3953
3952
|
}
|
|
3954
|
-
function
|
|
3953
|
+
function Ii(e, t, n) {
|
|
3955
3954
|
let r = null;
|
|
3956
|
-
|
|
3955
|
+
Mr(() => {
|
|
3957
3956
|
if (process.env.NODE_ENV !== "production" && t.vnode.el) {
|
|
3958
|
-
t.vnode.el.__VUE_I18N__ = n, r =
|
|
3957
|
+
t.vnode.el.__VUE_I18N__ = n, r = Zt();
|
|
3959
3958
|
const a = n;
|
|
3960
3959
|
a[Pe] && a[Pe](r), r.on("*", tt);
|
|
3961
3960
|
}
|
|
3962
|
-
}, t),
|
|
3961
|
+
}, t), wr(() => {
|
|
3963
3962
|
const a = n;
|
|
3964
3963
|
process.env.NODE_ENV !== "production" && t.vnode.el && t.vnode.el.__VUE_I18N__ && (r && r.off("*", tt), a[ze] && a[ze](), delete t.vnode.el.__VUE_I18N__), e.__deleteInstance(t);
|
|
3965
3964
|
const s = a[Bt];
|
|
3966
3965
|
s && (s(), delete a[Bt]);
|
|
3967
3966
|
}, t);
|
|
3968
3967
|
}
|
|
3969
|
-
const
|
|
3968
|
+
const Ai = [
|
|
3970
3969
|
"locale",
|
|
3971
3970
|
"fallbackLocale",
|
|
3972
3971
|
"availableLocales"
|
|
3973
|
-
],
|
|
3974
|
-
function
|
|
3972
|
+
], Xn = ["t", "rt", "d", "n", "tm", "te"];
|
|
3973
|
+
function ki(e, t) {
|
|
3975
3974
|
const n = /* @__PURE__ */ Object.create(null);
|
|
3976
|
-
return
|
|
3975
|
+
return Ai.forEach((a) => {
|
|
3977
3976
|
const s = Object.getOwnPropertyDescriptor(t, a);
|
|
3978
3977
|
if (!s)
|
|
3979
3978
|
throw ne(G.UNEXPECTED_ERROR);
|
|
3980
|
-
const i =
|
|
3979
|
+
const i = Pr(s.value) ? {
|
|
3981
3980
|
get() {
|
|
3982
3981
|
return s.value.value;
|
|
3983
3982
|
},
|
|
@@ -3991,18 +3990,18 @@ function Di(e, t) {
|
|
|
3991
3990
|
}
|
|
3992
3991
|
};
|
|
3993
3992
|
Object.defineProperty(n, a, i);
|
|
3994
|
-
}), e.config.globalProperties.$i18n = n,
|
|
3993
|
+
}), e.config.globalProperties.$i18n = n, Xn.forEach((a) => {
|
|
3995
3994
|
const s = Object.getOwnPropertyDescriptor(t, a);
|
|
3996
3995
|
if (!s || !s.value)
|
|
3997
3996
|
throw ne(G.UNEXPECTED_ERROR);
|
|
3998
3997
|
Object.defineProperty(e.config.globalProperties, `$${a}`, s);
|
|
3999
3998
|
}), () => {
|
|
4000
|
-
delete e.config.globalProperties.$i18n,
|
|
3999
|
+
delete e.config.globalProperties.$i18n, Xn.forEach((a) => {
|
|
4001
4000
|
delete e.config.globalProperties[`$${a}`];
|
|
4002
4001
|
});
|
|
4003
4002
|
};
|
|
4004
4003
|
}
|
|
4005
|
-
const
|
|
4004
|
+
const Si = /* @__PURE__ */ Xt({
|
|
4006
4005
|
/* eslint-disable */
|
|
4007
4006
|
name: "i18n-d",
|
|
4008
4007
|
props: Q({
|
|
@@ -4013,35 +4012,35 @@ const Pi = /* @__PURE__ */ Xt({
|
|
|
4013
4012
|
format: {
|
|
4014
4013
|
type: [String, Object]
|
|
4015
4014
|
}
|
|
4016
|
-
},
|
|
4015
|
+
}, on),
|
|
4017
4016
|
/* eslint-enable */
|
|
4018
4017
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
4019
4018
|
setup(e, t) {
|
|
4020
|
-
const n = e.i18n ||
|
|
4019
|
+
const n = e.i18n || ln({
|
|
4021
4020
|
useScope: e.scope,
|
|
4022
4021
|
__useComponent: !0
|
|
4023
4022
|
});
|
|
4024
|
-
return
|
|
4023
|
+
return Or(e, t, _r, (...r) => (
|
|
4025
4024
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
4026
4025
|
n[Wt](...r)
|
|
4027
4026
|
));
|
|
4028
4027
|
}
|
|
4029
|
-
}),
|
|
4030
|
-
|
|
4031
|
-
|
|
4032
|
-
|
|
4033
|
-
|
|
4028
|
+
}), qn = Si;
|
|
4029
|
+
Ha();
|
|
4030
|
+
ga(Xs);
|
|
4031
|
+
pa(fa);
|
|
4032
|
+
Ea(rr);
|
|
4034
4033
|
if (process.env.NODE_ENV !== "production" || __INTLIFY_PROD_DEVTOOLS__) {
|
|
4035
4034
|
const e = ke();
|
|
4036
|
-
e.__INTLIFY__ = !0,
|
|
4035
|
+
e.__INTLIFY__ = !0, qs(e.__INTLIFY_DEVTOOLS_GLOBAL_HOOK__);
|
|
4037
4036
|
}
|
|
4038
4037
|
process.env.NODE_ENV;
|
|
4039
4038
|
var ft = { exports: {} };
|
|
4040
4039
|
/*! store2 - v2.14.4 - 2024-12-26
|
|
4041
4040
|
* Copyright (c) 2024 Nathan Bubna; Licensed MIT */
|
|
4042
|
-
var Pt = ft.exports,
|
|
4043
|
-
function
|
|
4044
|
-
return
|
|
4041
|
+
var Pt = ft.exports, Jn;
|
|
4042
|
+
function Di() {
|
|
4043
|
+
return Jn || (Jn = 1, function(e) {
|
|
4045
4044
|
(function(t, n) {
|
|
4046
4045
|
var r = {
|
|
4047
4046
|
version: "2.14.4",
|
|
@@ -4090,8 +4089,8 @@ function Ri() {
|
|
|
4090
4089
|
},
|
|
4091
4090
|
// core functions
|
|
4092
4091
|
Store: function(s, i, c) {
|
|
4093
|
-
var f = r.inherit(r.storeAPI, function(
|
|
4094
|
-
return arguments.length === 0 ? f.getAll() : typeof N == "function" ? f.transact(
|
|
4092
|
+
var f = r.inherit(r.storeAPI, function(y, N, v) {
|
|
4093
|
+
return arguments.length === 0 ? f.getAll() : typeof N == "function" ? f.transact(y, N, v) : N !== void 0 ? f.set(y, N, v) : typeof y == "string" || typeof y == "number" ? f.get(y) : typeof y == "function" ? f.each(y) : y ? f.setAll(y, N) : f.clear();
|
|
4095
4094
|
});
|
|
4096
4095
|
f._id = s;
|
|
4097
4096
|
try {
|
|
@@ -4113,8 +4112,8 @@ function Ri() {
|
|
|
4113
4112
|
return this._ns ? this._ns.substring(0, this._ns.length - c.length) : "";
|
|
4114
4113
|
var f = s, p = this[f];
|
|
4115
4114
|
if ((!p || !p.namespace) && (p = r.Store(this._id, this._area, this._ns + f + c), p._delim = c, this[f] || (this[f] = p), !i))
|
|
4116
|
-
for (var
|
|
4117
|
-
p.area(
|
|
4115
|
+
for (var y in r.areas)
|
|
4116
|
+
p.area(y, r.areas[y]);
|
|
4118
4117
|
return p;
|
|
4119
4118
|
},
|
|
4120
4119
|
isFake: function(s) {
|
|
@@ -4174,8 +4173,8 @@ function Ri() {
|
|
|
4174
4173
|
else if (f !== null) {
|
|
4175
4174
|
var p = typeof f;
|
|
4176
4175
|
if (p === typeof i && p === "object") {
|
|
4177
|
-
for (var
|
|
4178
|
-
f[
|
|
4176
|
+
for (var y in i)
|
|
4177
|
+
f[y] = i[y];
|
|
4179
4178
|
i = f;
|
|
4180
4179
|
} else
|
|
4181
4180
|
i = f + i;
|
|
@@ -4258,69 +4257,75 @@ function Ri() {
|
|
|
4258
4257
|
})(Pt, Pt && Pt.define);
|
|
4259
4258
|
}(ft)), ft.exports;
|
|
4260
4259
|
}
|
|
4261
|
-
var
|
|
4262
|
-
const
|
|
4260
|
+
var Pi = Di();
|
|
4261
|
+
const jt = /* @__PURE__ */ tr(Pi), Ri = (e) => {
|
|
4263
4262
|
const t = {};
|
|
4264
4263
|
for (const n of e)
|
|
4265
4264
|
t[n.key] = n.value;
|
|
4266
4265
|
return t;
|
|
4267
|
-
},
|
|
4268
|
-
const r =
|
|
4269
|
-
r ?
|
|
4270
|
-
}), e), pt = "https://test.ihotel.cn",
|
|
4266
|
+
}, Mi = (e, t) => (t.forEach((n) => {
|
|
4267
|
+
const r = X.find(e, { key: n.key });
|
|
4268
|
+
r ? X.merge(r, n) : e.push(n);
|
|
4269
|
+
}), e), pt = "https://test.ihotel.cn", Cr = async (e) => Re.get(pt + "/i18n-web/sysoption/getsupportedlangs", {
|
|
4271
4270
|
headers: {
|
|
4272
|
-
Authorization:
|
|
4271
|
+
Authorization: e
|
|
4273
4272
|
}
|
|
4274
|
-
}),
|
|
4273
|
+
}), Qn = async ({
|
|
4275
4274
|
appCode: e,
|
|
4276
4275
|
language: t = "zh-CN",
|
|
4277
4276
|
page: n,
|
|
4278
|
-
lastPullDate: r
|
|
4279
|
-
|
|
4280
|
-
|
|
4281
|
-
|
|
4277
|
+
lastPullDate: r,
|
|
4278
|
+
token: a
|
|
4279
|
+
}) => new Promise(async (s, i) => {
|
|
4280
|
+
const c = pt + "/i18n-web/kv_translate/kv_translates", f = r ? c + "?lastPullDate=" + r : c, p = await Re({
|
|
4281
|
+
url: f,
|
|
4282
4282
|
method: "GET",
|
|
4283
4283
|
headers: {
|
|
4284
4284
|
appCode: e,
|
|
4285
4285
|
page: n,
|
|
4286
|
-
language: t
|
|
4286
|
+
language: t,
|
|
4287
|
+
Authorization: a
|
|
4287
4288
|
}
|
|
4288
4289
|
});
|
|
4289
|
-
|
|
4290
|
-
}),
|
|
4290
|
+
p && p.result == 0 ? s(p.retVal) : s(p);
|
|
4291
|
+
}), wi = async (e, t) => Re({
|
|
4291
4292
|
url: pt + "/i18n-web/kv_translate/kv_translates",
|
|
4292
4293
|
method: "POST",
|
|
4293
4294
|
data: e,
|
|
4294
|
-
headers: { token:
|
|
4295
|
-
}),
|
|
4295
|
+
headers: { token: t }
|
|
4296
|
+
}), Fi = async (e, t) => Re({
|
|
4296
4297
|
url: pt + "/i18n-web/kv_translate/batch",
|
|
4297
4298
|
method: "POST",
|
|
4298
4299
|
data: e,
|
|
4299
|
-
headers: { token:
|
|
4300
|
-
}),
|
|
4301
|
-
const
|
|
4300
|
+
headers: { token: t }
|
|
4301
|
+
}), Ki = async ({ appCode: e, language: t = "zh-CN", token: n }) => new Promise(async (r, a) => {
|
|
4302
|
+
const s = jt.namespace(`i18n_${e}`), i = {
|
|
4302
4303
|
appCode: e,
|
|
4303
|
-
language: t
|
|
4304
|
-
|
|
4305
|
-
|
|
4306
|
-
|
|
4307
|
-
|
|
4304
|
+
language: t,
|
|
4305
|
+
token: n
|
|
4306
|
+
}, c = s.get(t);
|
|
4307
|
+
if (!c || !c.lastPullDate) {
|
|
4308
|
+
const f = await Qn(i);
|
|
4309
|
+
f && (s.set(t, f), r(f.translatesDTOs));
|
|
4308
4310
|
} else {
|
|
4309
|
-
const { lastPullDate:
|
|
4310
|
-
...
|
|
4311
|
-
lastPullDate:
|
|
4311
|
+
const { lastPullDate: f } = c, p = await Qn({
|
|
4312
|
+
...i,
|
|
4313
|
+
lastPullDate: f
|
|
4312
4314
|
});
|
|
4313
|
-
if (
|
|
4314
|
-
const
|
|
4315
|
-
if (
|
|
4316
|
-
|
|
4315
|
+
if (p) {
|
|
4316
|
+
const y = X.get(c, "translatesDTOs");
|
|
4317
|
+
if (X.isEmpty(p.translatesDTOs))
|
|
4318
|
+
r(y);
|
|
4317
4319
|
else {
|
|
4318
|
-
const
|
|
4319
|
-
|
|
4320
|
+
const N = Mi(y, p.translatesDTOs), v = {
|
|
4321
|
+
lastPullDate: p.lastPullDate,
|
|
4322
|
+
translatesDTOs: N
|
|
4323
|
+
};
|
|
4324
|
+
jt.namespace(`i18n_${e}`).set(t, v, ":"), r(N);
|
|
4320
4325
|
}
|
|
4321
4326
|
}
|
|
4322
4327
|
}
|
|
4323
|
-
}),
|
|
4328
|
+
}), Ui = {
|
|
4324
4329
|
data() {
|
|
4325
4330
|
return {
|
|
4326
4331
|
isModalVisible: !1,
|
|
@@ -4340,7 +4345,7 @@ const Qn = /* @__PURE__ */ nr(Mi), wi = (e) => {
|
|
|
4340
4345
|
width: 200,
|
|
4341
4346
|
key: "dictKey"
|
|
4342
4347
|
}];
|
|
4343
|
-
return
|
|
4348
|
+
return X.map(this.languages, (t) => {
|
|
4344
4349
|
const n = t.code;
|
|
4345
4350
|
return e.push({
|
|
4346
4351
|
title: t.name,
|
|
@@ -4365,7 +4370,8 @@ const Qn = /* @__PURE__ */ nr(Mi), wi = (e) => {
|
|
|
4365
4370
|
props: {
|
|
4366
4371
|
appCode: String,
|
|
4367
4372
|
name: String,
|
|
4368
|
-
setLanguage: Function
|
|
4373
|
+
setLanguage: Function,
|
|
4374
|
+
token: String
|
|
4369
4375
|
},
|
|
4370
4376
|
methods: {
|
|
4371
4377
|
closeModal() {
|
|
@@ -4381,8 +4387,8 @@ const Qn = /* @__PURE__ */ nr(Mi), wi = (e) => {
|
|
|
4381
4387
|
page: a,
|
|
4382
4388
|
unitCode: s
|
|
4383
4389
|
} = e, i = [];
|
|
4384
|
-
return
|
|
4385
|
-
|
|
4390
|
+
return X.forIn(e, (c, f) => {
|
|
4391
|
+
X.isEqual(c, t[f]) || i.push({
|
|
4386
4392
|
appCode: n,
|
|
4387
4393
|
key: r,
|
|
4388
4394
|
page: a,
|
|
@@ -4395,23 +4401,23 @@ const Qn = /* @__PURE__ */ nr(Mi), wi = (e) => {
|
|
|
4395
4401
|
async saveData({
|
|
4396
4402
|
msg: e = ""
|
|
4397
4403
|
}) {
|
|
4398
|
-
const t =
|
|
4404
|
+
const t = X.differenceWith(this.data.datas, this.initialData.datas, X.isEqual);
|
|
4399
4405
|
let n = [];
|
|
4400
4406
|
for (let a = 0; a < t.length; a++) {
|
|
4401
|
-
const s = t[a], i =
|
|
4407
|
+
const s = t[a], i = X.find(this.initialData.datas, {
|
|
4402
4408
|
dictKey: s.dictKey
|
|
4403
4409
|
}), c = this.findShallowStringDiff(s, i);
|
|
4404
|
-
n =
|
|
4410
|
+
n = X.concat(n, c);
|
|
4405
4411
|
}
|
|
4406
|
-
const r = await
|
|
4412
|
+
const r = await Fi({
|
|
4407
4413
|
appCode: this.appCode,
|
|
4408
4414
|
language: this.language,
|
|
4409
4415
|
data: n
|
|
4410
|
-
});
|
|
4411
|
-
r && r.result === 0 && (_e.success(e || r.msg), this.setLanguage(), this.initialData.datas =
|
|
4416
|
+
}, this.token);
|
|
4417
|
+
r && r.result === 0 && (_e.success(e || r.msg), this.setLanguage(), this.initialData.datas = X.cloneDeep(this.data.datas));
|
|
4412
4418
|
},
|
|
4413
4419
|
async saveNoEqual() {
|
|
4414
|
-
|
|
4420
|
+
X.isEqual(this.initialData, this.data) || this.saveData({
|
|
4415
4421
|
msg: "已为您自动保存"
|
|
4416
4422
|
});
|
|
4417
4423
|
},
|
|
@@ -4424,28 +4430,28 @@ const Qn = /* @__PURE__ */ nr(Mi), wi = (e) => {
|
|
|
4424
4430
|
const t = {
|
|
4425
4431
|
appCode: this.appCode,
|
|
4426
4432
|
searchBlur: this.searchText,
|
|
4427
|
-
page: this.name ?
|
|
4428
|
-
commaSeparatedLangs:
|
|
4433
|
+
page: this.name ? X.toUpper(this.name) : "HOME",
|
|
4434
|
+
commaSeparatedLangs: X.map(this.languages, "code").toString(),
|
|
4429
4435
|
firstResult: 0,
|
|
4430
4436
|
pageSize: 10,
|
|
4431
4437
|
...e
|
|
4432
|
-
}, n = await
|
|
4433
|
-
n && (this.initialData =
|
|
4438
|
+
}, n = await wi(t, this.token);
|
|
4439
|
+
n && (this.initialData = X.cloneDeep(n.retVal), this.data = n.retVal);
|
|
4434
4440
|
},
|
|
4435
4441
|
async init() {
|
|
4436
|
-
const e = await
|
|
4442
|
+
const e = await Cr(this.token);
|
|
4437
4443
|
e && e.result == 0 ? (this.languages = e.retVal, this.search()) : _e.error("获取语言失败,出错了");
|
|
4438
4444
|
}
|
|
4439
4445
|
}
|
|
4440
|
-
},
|
|
4446
|
+
}, Ir = (e, t) => {
|
|
4441
4447
|
const n = e.__vccOpts || e;
|
|
4442
4448
|
for (const [r, a] of t)
|
|
4443
4449
|
n[r] = a;
|
|
4444
4450
|
return n;
|
|
4445
|
-
},
|
|
4446
|
-
function
|
|
4447
|
-
const i = fe("Table"), c = fe("TabPane"), f = fe("Input"), p = fe("Tabs"),
|
|
4448
|
-
return lt(),
|
|
4451
|
+
}, Vi = { class: "extra" }, xi = { class: "gc_i18n_page" }, $i = { style: { display: "flex" } };
|
|
4452
|
+
function Wi(e, t, n, r, a, s) {
|
|
4453
|
+
const i = fe("Table"), c = fe("TabPane"), f = fe("Input"), p = fe("Tabs"), y = fe("Page"), N = fe("Button"), v = fe("Modal");
|
|
4454
|
+
return lt(), er(v, {
|
|
4449
4455
|
modelValue: a.isModalVisible,
|
|
4450
4456
|
"onUpdate:modelValue": t[2] || (t[2] = (C) => a.isModalVisible = C),
|
|
4451
4457
|
"mask-closable": !1,
|
|
@@ -4459,7 +4465,7 @@ function Bi(e, t, n, r, a, s) {
|
|
|
4459
4465
|
class: "gc_i18n_tabs"
|
|
4460
4466
|
}, {
|
|
4461
4467
|
extra: ve(() => [
|
|
4462
|
-
|
|
4468
|
+
Ke("div", Vi, [
|
|
4463
4469
|
ue(f, {
|
|
4464
4470
|
prefix: "ios-search",
|
|
4465
4471
|
placeholder: "请输入搜索内容",
|
|
@@ -4486,9 +4492,9 @@ function Bi(e, t, n, r, a, s) {
|
|
|
4486
4492
|
]),
|
|
4487
4493
|
_: 1
|
|
4488
4494
|
}),
|
|
4489
|
-
|
|
4490
|
-
|
|
4491
|
-
ue(
|
|
4495
|
+
Ke("div", xi, [
|
|
4496
|
+
Ke("div", $i, [
|
|
4497
|
+
ue(y, {
|
|
4492
4498
|
modelValue: s.firstResult,
|
|
4493
4499
|
"onUpdate:modelValue": t[1] || (t[1] = (C) => s.firstResult = C),
|
|
4494
4500
|
total: a.data.totalRows,
|
|
@@ -4497,9 +4503,9 @@ function Bi(e, t, n, r, a, s) {
|
|
|
4497
4503
|
"show-total": "",
|
|
4498
4504
|
onOnChange: s.changePage
|
|
4499
4505
|
}, null, 8, ["modelValue", "total", "onOnChange"]),
|
|
4500
|
-
|
|
4506
|
+
Ke("div", null, "共 " + Kr(a.data.totalRows) + " 项数据", 1)
|
|
4501
4507
|
]),
|
|
4502
|
-
|
|
4508
|
+
Ke("div", null, [
|
|
4503
4509
|
ue(N, {
|
|
4504
4510
|
style: { "margin-right": "10px" },
|
|
4505
4511
|
onClick: s.closeModal
|
|
@@ -4524,7 +4530,7 @@ function Bi(e, t, n, r, a, s) {
|
|
|
4524
4530
|
_: 1
|
|
4525
4531
|
}, 8, ["modelValue"]);
|
|
4526
4532
|
}
|
|
4527
|
-
const
|
|
4533
|
+
const Gi = /* @__PURE__ */ Ir(Ui, [["render", Wi]]), Bi = {
|
|
4528
4534
|
name: "LangChange",
|
|
4529
4535
|
data() {
|
|
4530
4536
|
return {
|
|
@@ -4540,16 +4546,16 @@ const Yi = /* @__PURE__ */ Ar(xi, [["render", Bi]]), Hi = {
|
|
|
4540
4546
|
},
|
|
4541
4547
|
async mounted() {
|
|
4542
4548
|
this.language = navigator.language || "zh-CN";
|
|
4543
|
-
const e = await
|
|
4549
|
+
const e = await Cr();
|
|
4544
4550
|
e && e.result === 0 && (this.languages = e.retVal);
|
|
4545
4551
|
}
|
|
4546
|
-
},
|
|
4547
|
-
function
|
|
4552
|
+
}, Yi = { key: 0 };
|
|
4553
|
+
function Hi(e, t, n, r, a, s) {
|
|
4548
4554
|
const i = fe("Option"), c = fe("Select");
|
|
4549
4555
|
return lt(), _n("div", null, [
|
|
4550
|
-
n.more ? (lt(), _n("div",
|
|
4551
|
-
|
|
4552
|
-
]))) : (lt(),
|
|
4556
|
+
n.more ? (lt(), _n("div", Yi, t[1] || (t[1] = [
|
|
4557
|
+
Ke("span", null, "切换语种", -1)
|
|
4558
|
+
]))) : (lt(), er(c, {
|
|
4553
4559
|
key: 1,
|
|
4554
4560
|
modelValue: a.language,
|
|
4555
4561
|
"onUpdate:modelValue": t[0] || (t[0] = (f) => a.language = f)
|
|
@@ -4566,16 +4572,13 @@ function ji(e, t, n, r, a, s) {
|
|
|
4566
4572
|
}, 8, ["modelValue"]))
|
|
4567
4573
|
]);
|
|
4568
4574
|
}
|
|
4569
|
-
const
|
|
4575
|
+
const ji = /* @__PURE__ */ Ir(Bi, [["render", Hi]]);
|
|
4570
4576
|
_e.config({
|
|
4571
4577
|
duration: 3
|
|
4572
4578
|
});
|
|
4573
4579
|
Re.defaults.timeout = 6e4;
|
|
4574
4580
|
Re.interceptors.request.use(
|
|
4575
|
-
(e) =>
|
|
4576
|
-
const t = localStorage.getItem("token");
|
|
4577
|
-
return $r.isEmpty(t) || (e.headers.Authorization = t), e.headers["Content-Type"] = "application/json", e;
|
|
4578
|
-
},
|
|
4581
|
+
(e) => (e.headers["Content-Type"] = "application/json", e),
|
|
4579
4582
|
(e) => (_e.error({
|
|
4580
4583
|
content: "请求超时!"
|
|
4581
4584
|
}), Promise.resolve(e))
|
|
@@ -4593,10 +4596,10 @@ Re.interceptors.response.use(
|
|
|
4593
4596
|
content: "请求超时!"
|
|
4594
4597
|
}) : _e.error({ content: e.message || "未知错误!" }), Promise.resolve(e))
|
|
4595
4598
|
);
|
|
4596
|
-
class
|
|
4599
|
+
class Zi {
|
|
4597
4600
|
constructor(t = {}) {
|
|
4598
|
-
const { router: n } = t;
|
|
4599
|
-
this.
|
|
4601
|
+
const { router: n, appCode: r, messages: a, token: s } = t;
|
|
4602
|
+
this.token = s || jt.get("token"), this.appCode = r, this.router = n, this.locale = navigator.language || "zh-CN", this.modalLoad = !1, this.messages = a || {}, this.i18n = vi({
|
|
4600
4603
|
locale: "zh-CN",
|
|
4601
4604
|
globalInjection: !0,
|
|
4602
4605
|
legacy: !1,
|
|
@@ -4610,52 +4613,58 @@ class eo {
|
|
|
4610
4613
|
// 屏蔽回退过程中的警告
|
|
4611
4614
|
...t
|
|
4612
4615
|
});
|
|
4613
|
-
const
|
|
4614
|
-
this.i18n.global.t = (
|
|
4615
|
-
var
|
|
4616
|
-
const
|
|
4617
|
-
if (
|
|
4618
|
-
const
|
|
4619
|
-
return
|
|
4616
|
+
const i = this.i18n.global.t;
|
|
4617
|
+
this.i18n.global.t = (c, f) => {
|
|
4618
|
+
var N, v;
|
|
4619
|
+
const p = X.toUpper((v = (N = n == null ? void 0 : n.currentRoute) == null ? void 0 : N.value) == null ? void 0 : v.name), y = i(c);
|
|
4620
|
+
if (y === c && p) {
|
|
4621
|
+
const C = `${p}.${c}`, D = i(C);
|
|
4622
|
+
return D !== C ? D : f && X.has(f, "comment") ? X.get(f, "comment") : c;
|
|
4620
4623
|
}
|
|
4621
|
-
return
|
|
4622
|
-
}, this.i18n.global.changeLocal = (
|
|
4623
|
-
this.setLanguage(
|
|
4624
|
-
}, n.
|
|
4625
|
-
const { language:
|
|
4626
|
-
this.setLanguage(
|
|
4627
|
-
|
|
4624
|
+
return y;
|
|
4625
|
+
}, this.i18n.global.changeLocal = (c) => {
|
|
4626
|
+
this.setLanguage(c || this.locale);
|
|
4627
|
+
}, n.beforeEach((c, f, p) => {
|
|
4628
|
+
const { language: y, token: N } = c.query;
|
|
4629
|
+
N && this.setToken(N), this.setLanguage(y), p();
|
|
4630
|
+
}), n.afterEach((c, f) => {
|
|
4631
|
+
Ur(() => {
|
|
4632
|
+
this.configInstance ? this.configInstance.closeModal() : this.createModal(c.name);
|
|
4628
4633
|
});
|
|
4629
4634
|
});
|
|
4630
4635
|
}
|
|
4636
|
+
setToken(t) {
|
|
4637
|
+
this.token = t;
|
|
4638
|
+
}
|
|
4631
4639
|
async setLanguage(t = "zh-CN") {
|
|
4632
|
-
|
|
4633
|
-
const n = await Vi({
|
|
4640
|
+
const n = await Ki({
|
|
4634
4641
|
appCode: this.appCode,
|
|
4635
|
-
language: t
|
|
4642
|
+
language: t,
|
|
4643
|
+
token: this.token
|
|
4636
4644
|
});
|
|
4637
4645
|
if (n) {
|
|
4638
|
-
const r =
|
|
4646
|
+
const r = Ri(n);
|
|
4639
4647
|
this.i18n.global.setLocaleMessage(
|
|
4640
4648
|
t,
|
|
4641
|
-
|
|
4649
|
+
X.assign({}, X.get(this.messages, t), r)
|
|
4642
4650
|
);
|
|
4643
4651
|
}
|
|
4644
|
-
this.i18n.global.locale.value = t;
|
|
4652
|
+
this.locale = t, this.i18n.global.locale.value = t;
|
|
4645
4653
|
}
|
|
4646
4654
|
createModal(t) {
|
|
4647
|
-
this.modalLoad = !0, this.configInstance =
|
|
4655
|
+
this.modalLoad = !0, this.configInstance = Vr(Gi, {
|
|
4648
4656
|
appCode: this.appCode,
|
|
4649
|
-
|
|
4657
|
+
token: this.token,
|
|
4658
|
+
setLanguage: this.setLanguage.bind(this, this.locale),
|
|
4650
4659
|
name: t
|
|
4651
|
-
}).use(fn).mount(document.createElement("div")),
|
|
4660
|
+
}).use(fn).mount(document.createElement("div")), Gr.bind("shift > t", (n) => {
|
|
4652
4661
|
this.configInstance.openModal();
|
|
4653
4662
|
});
|
|
4654
4663
|
}
|
|
4655
4664
|
install(t, { router: n }) {
|
|
4656
|
-
t.use(this.i18n), t.use(fn), t.component("LangChange",
|
|
4665
|
+
t.use(this.i18n), t.use(fn), t.component("LangChange", ji);
|
|
4657
4666
|
}
|
|
4658
4667
|
}
|
|
4659
4668
|
export {
|
|
4660
|
-
|
|
4669
|
+
Zi as default
|
|
4661
4670
|
};
|