@feedmepos/mf-hrm-portal 2.0.7 → 2.0.8-dev.1

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.
Files changed (27) hide show
  1. package/dist/{AuditLogList-BWzKxoBK.js → AuditLogList-YGP3G14A.js} +5 -5
  2. package/dist/{EmployeeList-CPvHmCle.js → EmployeeList-DuRlCrqN.js} +5 -5
  3. package/dist/{Main-BNywXKr0.js → Main-BfDH3uAt.js} +9 -9
  4. package/dist/{Main-BEj_iUkZ.js → Main-D4ueBOl0.js} +6 -6
  5. package/dist/{Main-BkIzKoHQ.js → Main-QpKV1hdj.js} +4 -4
  6. package/dist/{PermissionSetList-B8jSoL19.js → PermissionSetList-DfAZmUkI.js} +5 -5
  7. package/dist/PortalPermissionEditor.vue_vue_type_script_setup_true_lang-DokyDyxJ.js +3432 -0
  8. package/dist/{RoleList-BEx1B8PE.js → RoleList-D4mup6LW.js} +7 -7
  9. package/dist/{TeamMemberList-BEDwcjeT.js → TeamMemberList-D9rTKS5N.js} +8 -8
  10. package/dist/{TimesheetList-CqZG4xmE.js → TimesheetList-CBudjg1y.js} +7 -7
  11. package/dist/{app-DHtKeCwy.js → app-BO9lM0sJ.js} +4 -4
  12. package/dist/app.js +1 -1
  13. package/dist/{dayjs.min-BWWy9u8p.js → dayjs.min-lY-LRZuh.js} +1 -1
  14. package/dist/{employee-C2ys9jf0.js → employee-DXp_u8jd.js} +4 -4
  15. package/dist/{index-O9ipnK-U.js → index-BigKo-lS.js} +1 -1
  16. package/dist/{index-BwYlZrxP.js → index-DAuOIotV.js} +2 -2
  17. package/dist/{iteration-BdhU8jGb.js → iteration-DgaP-HFg.js} +2 -2
  18. package/dist/{lodash-CDSEYvRz.js → lodash-Mhrrz947.js} +1 -1
  19. package/dist/src/views/team/components/BasePermission.vue.d.ts +2 -2
  20. package/dist/{team-9CwJsJGX.js → team-oeTIbsa-.js} +1 -1
  21. package/dist/{timesheet-ChKYJtjK.js → timesheet-B4XO3Kjx.js} +3 -3
  22. package/dist/tsconfig.app.tsbuildinfo +1 -1
  23. package/dist/{useAppStore-DGzBzMIR.js → useAppStore-Cu5QCTlx.js} +1 -1
  24. package/dist/{useLoading-CzteZR_c.js → useLoading-DKnxkHGF.js} +1 -1
  25. package/dist/{useReportPermissions-CaY_wr2l.js → useReportPermissions-B_w5FiAK.js} +3 -3
  26. package/package.json +1 -1
  27. package/dist/PortalPermissionEditor.vue_vue_type_script_setup_true_lang-Ddnj8eg_.js +0 -3356
@@ -0,0 +1,3432 @@
1
+ import { getCurrentInstance as Zt, inject as Bn, ref as Ue, shallowRef as Hn, computed as ee, watch as St, onMounted as xt, onUnmounted as On, defineComponent as Ne, h as Rn, createVNode as fe, Text as $n, Fragment as Ie, resolveComponent as Xe, createBlock as Se, openBlock as Y, withCtx as he, createElementVNode as se, createElementBlock as ne, toDisplayString as Ae, unref as Te, renderList as pe, renderSlot as be, createCommentVNode as Le, createTextVNode as Jn, useSlots as Kn, normalizeStyle as ct, normalizeClass as qe, createSlots as Fe, nextTick as zn, mergeModels as Qt, useModel as Qn } from "vue";
2
+ import { useI18n as _t, useCoreStore as qn } from "@feedmepos/mf-common";
3
+ import "@vue/devtools-api";
4
+ import { p as Dt, j as es, x as ts, y as yt, z as ns, l as ss, $ as Tt } from "./index-DAuOIotV.js";
5
+ import { d as ut, g as as, b as rs } from "./iteration-DgaP-HFg.js";
6
+ import { i as ls, d as ue, N as os, a as kt } from "./app-BO9lM0sJ.js";
7
+ import { u as is } from "./index-BigKo-lS.js";
8
+ import { u as cs } from "./useAppStore-Cu5QCTlx.js";
9
+ /*!
10
+ * shared v10.0.5
11
+ * (c) 2024 kazuya kawaguchi
12
+ * Released under the MIT License.
13
+ */
14
+ const qt = typeof window < "u", Ve = (e, t = !1) => t ? Symbol.for(e) : Symbol(e), us = (e, t, n) => ms({ l: e, k: t, s: n }), ms = (e) => JSON.stringify(e).replace(/\u2028/g, "\\u2028").replace(/\u2029/g, "\\u2029").replace(/\u0027/g, "\\u0027"), me = (e) => typeof e == "number" && isFinite(e), ds = (e) => Xt(e) === "[object Date]", dt = (e) => Xt(e) === "[object RegExp]", pt = (e) => H(e) && Object.keys(e).length === 0, de = Object.assign, fs = Object.create, Q = (e = null) => fs(e);
15
+ let en;
16
+ const je = () => en || (en = typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : typeof global < "u" ? global : Q());
17
+ function tn(e) {
18
+ return e.replace(/</g, "&lt;").replace(/>/g, "&gt;").replace(/"/g, "&quot;").replace(/'/g, "&apos;");
19
+ }
20
+ const _s = Object.prototype.hasOwnProperty;
21
+ function Ee(e, t) {
22
+ return _s.call(e, t);
23
+ }
24
+ const ce = Array.isArray, re = (e) => typeof e == "function", F = (e) => typeof e == "string", ie = (e) => typeof e == "boolean", $ = (e) => e !== null && typeof e == "object", ps = (e) => $(e) && re(e.then) && re(e.catch), Cn = Object.prototype.toString, Xt = (e) => Cn.call(e), H = (e) => Xt(e) === "[object Object]", hs = (e) => e == null ? "" : ce(e) || H(e) && e.toString === Cn ? JSON.stringify(e, null, 2) : String(e);
25
+ function Yt(e, t = "") {
26
+ return e.reduce((n, s, l) => l === 0 ? n + s : n + t + s, "");
27
+ }
28
+ function bs(e, t) {
29
+ typeof console < "u" && (console.warn("[intlify] " + e), t && console.warn(t.stack));
30
+ }
31
+ const rt = (e) => !$(e) || ce(e);
32
+ function mt(e, t) {
33
+ if (rt(e) || rt(t))
34
+ throw new Error("Invalid value");
35
+ const n = [{ src: e, des: t }];
36
+ for (; n.length; ) {
37
+ const { src: s, des: l } = n.pop();
38
+ Object.keys(s).forEach((a) => {
39
+ a !== "__proto__" && ($(s[a]) && !$(l[a]) && (l[a] = Array.isArray(s[a]) ? [] : Q()), rt(l[a]) || rt(s[a]) ? l[a] = s[a] : n.push({ src: s[a], des: l[a] }));
40
+ });
41
+ }
42
+ }
43
+ function gs(e, t, n) {
44
+ return { line: e, column: t, offset: n };
45
+ }
46
+ function Mt(e, t, n) {
47
+ return { start: e, end: t };
48
+ }
49
+ const z = {
50
+ // tokenizer error codes
51
+ EXPECTED_TOKEN: 1,
52
+ INVALID_TOKEN_IN_PLACEHOLDER: 2,
53
+ UNTERMINATED_SINGLE_QUOTE_IN_PLACEHOLDER: 3,
54
+ UNKNOWN_ESCAPE_SEQUENCE: 4,
55
+ INVALID_UNICODE_ESCAPE_SEQUENCE: 5,
56
+ UNBALANCED_CLOSING_BRACE: 6,
57
+ UNTERMINATED_CLOSING_BRACE: 7,
58
+ EMPTY_PLACEHOLDER: 8,
59
+ NOT_ALLOW_NEST_PLACEHOLDER: 9,
60
+ INVALID_LINKED_FORMAT: 10,
61
+ // parser error codes
62
+ MUST_HAVE_MESSAGES_IN_PLURAL: 11,
63
+ UNEXPECTED_EMPTY_LINKED_MODIFIER: 12,
64
+ UNEXPECTED_EMPTY_LINKED_KEY: 13,
65
+ UNEXPECTED_LEXICAL_ANALYSIS: 14
66
+ }, vs = 17;
67
+ function ht(e, t, n = {}) {
68
+ const { domain: s, messages: l, args: a } = n, c = e, d = new SyntaxError(String(c));
69
+ return d.code = e, t && (d.location = t), d.domain = s, d;
70
+ }
71
+ function Is(e) {
72
+ throw e;
73
+ }
74
+ const ke = " ", Es = "\r", _e = `
75
+ `, Ns = "\u2028", ys = "\u2029";
76
+ function Ts(e) {
77
+ const t = e;
78
+ let n = 0, s = 1, l = 1, a = 0;
79
+ const c = (y) => t[y] === Es && t[y + 1] === _e, d = (y) => t[y] === _e, u = (y) => t[y] === ys, h = (y) => t[y] === Ns, O = (y) => c(y) || d(y) || u(y) || h(y), C = () => n, k = () => s, j = () => l, W = () => a, R = (y) => c(y) || u(y) || h(y) ? _e : t[y], S = () => R(n), i = () => R(n + a);
80
+ function m() {
81
+ return a = 0, O(n) && (s++, l = 0), c(n) && n++, n++, l++, t[n];
82
+ }
83
+ function L() {
84
+ return c(n + a) && a++, a++, t[n + a];
85
+ }
86
+ function p() {
87
+ n = 0, s = 1, l = 1, a = 0;
88
+ }
89
+ function D(y = 0) {
90
+ a = y;
91
+ }
92
+ function A() {
93
+ const y = n + a;
94
+ for (; y !== n; )
95
+ m();
96
+ a = 0;
97
+ }
98
+ return {
99
+ index: C,
100
+ line: k,
101
+ column: j,
102
+ peekOffset: W,
103
+ charAt: R,
104
+ currentChar: S,
105
+ currentPeek: i,
106
+ next: m,
107
+ peek: L,
108
+ reset: p,
109
+ resetPeek: D,
110
+ skipToPeek: A
111
+ };
112
+ }
113
+ const Ce = void 0, ks = ".", nn = "'", Ls = "tokenizer";
114
+ function Os(e, t = {}) {
115
+ const n = t.location !== !1, s = Ts(e), l = () => s.index(), a = () => gs(s.line(), s.column(), s.index()), c = a(), d = l(), u = {
116
+ currentType: 13,
117
+ offset: d,
118
+ startLoc: c,
119
+ endLoc: c,
120
+ lastType: 13,
121
+ lastOffset: d,
122
+ lastStartLoc: c,
123
+ lastEndLoc: c,
124
+ braceNest: 0,
125
+ inLinked: !1,
126
+ text: ""
127
+ }, h = () => u, { onError: O } = t;
128
+ function C(r, o, g, ...G) {
129
+ const le = h();
130
+ if (o.column += g, o.offset += g, O) {
131
+ const x = n ? Mt(le.startLoc, o) : null, _ = ht(r, x, {
132
+ domain: Ls,
133
+ args: G
134
+ });
135
+ O(_);
136
+ }
137
+ }
138
+ function k(r, o, g) {
139
+ r.endLoc = a(), r.currentType = o;
140
+ const G = { type: o };
141
+ return n && (G.loc = Mt(r.startLoc, r.endLoc)), g != null && (G.value = g), G;
142
+ }
143
+ const j = (r) => k(
144
+ r,
145
+ 13
146
+ /* TokenTypes.EOF */
147
+ );
148
+ function W(r, o) {
149
+ return r.currentChar() === o ? (r.next(), o) : (C(z.EXPECTED_TOKEN, a(), 0, o), "");
150
+ }
151
+ function R(r) {
152
+ let o = "";
153
+ for (; r.currentPeek() === ke || r.currentPeek() === _e; )
154
+ o += r.currentPeek(), r.peek();
155
+ return o;
156
+ }
157
+ function S(r) {
158
+ const o = R(r);
159
+ return r.skipToPeek(), o;
160
+ }
161
+ function i(r) {
162
+ if (r === Ce)
163
+ return !1;
164
+ const o = r.charCodeAt(0);
165
+ return o >= 97 && o <= 122 || // a-z
166
+ o >= 65 && o <= 90 || // A-Z
167
+ o === 95;
168
+ }
169
+ function m(r) {
170
+ if (r === Ce)
171
+ return !1;
172
+ const o = r.charCodeAt(0);
173
+ return o >= 48 && o <= 57;
174
+ }
175
+ function L(r, o) {
176
+ const { currentType: g } = o;
177
+ if (g !== 2)
178
+ return !1;
179
+ R(r);
180
+ const G = i(r.currentPeek());
181
+ return r.resetPeek(), G;
182
+ }
183
+ function p(r, o) {
184
+ const { currentType: g } = o;
185
+ if (g !== 2)
186
+ return !1;
187
+ R(r);
188
+ const G = r.currentPeek() === "-" ? r.peek() : r.currentPeek(), le = m(G);
189
+ return r.resetPeek(), le;
190
+ }
191
+ function D(r, o) {
192
+ const { currentType: g } = o;
193
+ if (g !== 2)
194
+ return !1;
195
+ R(r);
196
+ const G = r.currentPeek() === nn;
197
+ return r.resetPeek(), G;
198
+ }
199
+ function A(r, o) {
200
+ const { currentType: g } = o;
201
+ if (g !== 7)
202
+ return !1;
203
+ R(r);
204
+ const G = r.currentPeek() === ".";
205
+ return r.resetPeek(), G;
206
+ }
207
+ function y(r, o) {
208
+ const { currentType: g } = o;
209
+ if (g !== 8)
210
+ return !1;
211
+ R(r);
212
+ const G = i(r.currentPeek());
213
+ return r.resetPeek(), G;
214
+ }
215
+ function te(r, o) {
216
+ const { currentType: g } = o;
217
+ if (!(g === 7 || g === 11))
218
+ return !1;
219
+ R(r);
220
+ const G = r.currentPeek() === ":";
221
+ return r.resetPeek(), G;
222
+ }
223
+ function T(r, o) {
224
+ const { currentType: g } = o;
225
+ if (g !== 9)
226
+ return !1;
227
+ const G = () => {
228
+ const x = r.currentPeek();
229
+ return x === "{" ? i(r.peek()) : x === "@" || x === "|" || x === ":" || x === "." || x === ke || !x ? !1 : x === _e ? (r.peek(), G()) : U(r, !1);
230
+ }, le = G();
231
+ return r.resetPeek(), le;
232
+ }
233
+ function w(r) {
234
+ R(r);
235
+ const o = r.currentPeek() === "|";
236
+ return r.resetPeek(), o;
237
+ }
238
+ function U(r, o = !0) {
239
+ const g = (le = !1, x = "") => {
240
+ const _ = r.currentPeek();
241
+ return _ === "{" || _ === "@" || !_ ? le : _ === "|" ? !(x === ke || x === _e) : _ === ke ? (r.peek(), g(!0, ke)) : _ === _e ? (r.peek(), g(!0, _e)) : !0;
242
+ }, G = g();
243
+ return o && r.resetPeek(), G;
244
+ }
245
+ function f(r, o) {
246
+ const g = r.currentChar();
247
+ return g === Ce ? Ce : o(g) ? (r.next(), g) : null;
248
+ }
249
+ function v(r) {
250
+ const o = r.charCodeAt(0);
251
+ return o >= 97 && o <= 122 || // a-z
252
+ o >= 65 && o <= 90 || // A-Z
253
+ o >= 48 && o <= 57 || // 0-9
254
+ o === 95 || // _
255
+ o === 36;
256
+ }
257
+ function X(r) {
258
+ return f(r, v);
259
+ }
260
+ function b(r) {
261
+ const o = r.charCodeAt(0);
262
+ return o >= 97 && o <= 122 || // a-z
263
+ o >= 65 && o <= 90 || // A-Z
264
+ o >= 48 && o <= 57 || // 0-9
265
+ o === 95 || // _
266
+ o === 36 || // $
267
+ o === 45;
268
+ }
269
+ function E(r) {
270
+ return f(r, b);
271
+ }
272
+ function I(r) {
273
+ const o = r.charCodeAt(0);
274
+ return o >= 48 && o <= 57;
275
+ }
276
+ function V(r) {
277
+ return f(r, I);
278
+ }
279
+ function P(r) {
280
+ const o = r.charCodeAt(0);
281
+ return o >= 48 && o <= 57 || // 0-9
282
+ o >= 65 && o <= 70 || // A-F
283
+ o >= 97 && o <= 102;
284
+ }
285
+ function M(r) {
286
+ return f(r, P);
287
+ }
288
+ function J(r) {
289
+ let o = "", g = "";
290
+ for (; o = V(r); )
291
+ g += o;
292
+ return g;
293
+ }
294
+ function B(r) {
295
+ let o = "";
296
+ for (; ; ) {
297
+ const g = r.currentChar();
298
+ if (g === "{" || g === "}" || g === "@" || g === "|" || !g)
299
+ break;
300
+ if (g === ke || g === _e)
301
+ if (U(r))
302
+ o += g, r.next();
303
+ else {
304
+ if (w(r))
305
+ break;
306
+ o += g, r.next();
307
+ }
308
+ else
309
+ o += g, r.next();
310
+ }
311
+ return o;
312
+ }
313
+ function Z(r) {
314
+ S(r);
315
+ let o = "", g = "";
316
+ for (; o = E(r); )
317
+ g += o;
318
+ return r.currentChar() === Ce && C(z.UNTERMINATED_CLOSING_BRACE, a(), 0), g;
319
+ }
320
+ function K(r) {
321
+ S(r);
322
+ let o = "";
323
+ return r.currentChar() === "-" ? (r.next(), o += `-${J(r)}`) : o += J(r), r.currentChar() === Ce && C(z.UNTERMINATED_CLOSING_BRACE, a(), 0), o;
324
+ }
325
+ function we(r) {
326
+ return r !== nn && r !== _e;
327
+ }
328
+ function ae(r) {
329
+ S(r), W(r, "'");
330
+ let o = "", g = "";
331
+ for (; o = f(r, we); )
332
+ o === "\\" ? g += ve(r) : g += o;
333
+ const G = r.currentChar();
334
+ return G === _e || G === Ce ? (C(z.UNTERMINATED_SINGLE_QUOTE_IN_PLACEHOLDER, a(), 0), G === _e && (r.next(), W(r, "'")), g) : (W(r, "'"), g);
335
+ }
336
+ function ve(r) {
337
+ const o = r.currentChar();
338
+ switch (o) {
339
+ case "\\":
340
+ case "'":
341
+ return r.next(), `\\${o}`;
342
+ case "u":
343
+ return $e(r, o, 4);
344
+ case "U":
345
+ return $e(r, o, 6);
346
+ default:
347
+ return C(z.UNKNOWN_ESCAPE_SEQUENCE, a(), 0, o), "";
348
+ }
349
+ }
350
+ function $e(r, o, g) {
351
+ W(r, o);
352
+ let G = "";
353
+ for (let le = 0; le < g; le++) {
354
+ const x = M(r);
355
+ if (!x) {
356
+ C(z.INVALID_UNICODE_ESCAPE_SEQUENCE, a(), 0, `\\${o}${G}${r.currentChar()}`);
357
+ break;
358
+ }
359
+ G += x;
360
+ }
361
+ return `\\${o}${G}`;
362
+ }
363
+ function Je(r) {
364
+ return r !== "{" && r !== "}" && r !== ke && r !== _e;
365
+ }
366
+ function vt(r) {
367
+ S(r);
368
+ let o = "", g = "";
369
+ for (; o = f(r, Je); )
370
+ g += o;
371
+ return g;
372
+ }
373
+ function It(r) {
374
+ let o = "", g = "";
375
+ for (; o = X(r); )
376
+ g += o;
377
+ return g;
378
+ }
379
+ function Et(r) {
380
+ const o = (g) => {
381
+ const G = r.currentChar();
382
+ return G === "{" || G === "@" || G === "|" || G === "(" || G === ")" || !G || G === ke ? g : (g += G, r.next(), o(g));
383
+ };
384
+ return o("");
385
+ }
386
+ function Ke(r) {
387
+ S(r);
388
+ const o = W(
389
+ r,
390
+ "|"
391
+ /* TokenChars.Pipe */
392
+ );
393
+ return S(r), o;
394
+ }
395
+ function Ge(r, o) {
396
+ let g = null;
397
+ switch (r.currentChar()) {
398
+ case "{":
399
+ return o.braceNest >= 1 && C(z.NOT_ALLOW_NEST_PLACEHOLDER, a(), 0), r.next(), g = k(
400
+ o,
401
+ 2,
402
+ "{"
403
+ /* TokenChars.BraceLeft */
404
+ ), S(r), o.braceNest++, g;
405
+ case "}":
406
+ return o.braceNest > 0 && o.currentType === 2 && C(z.EMPTY_PLACEHOLDER, a(), 0), r.next(), g = k(
407
+ o,
408
+ 3,
409
+ "}"
410
+ /* TokenChars.BraceRight */
411
+ ), o.braceNest--, o.braceNest > 0 && S(r), o.inLinked && o.braceNest === 0 && (o.inLinked = !1), g;
412
+ case "@":
413
+ return o.braceNest > 0 && C(z.UNTERMINATED_CLOSING_BRACE, a(), 0), g = We(r, o) || j(o), o.braceNest = 0, g;
414
+ default: {
415
+ let le = !0, x = !0, _ = !0;
416
+ if (w(r))
417
+ return o.braceNest > 0 && C(z.UNTERMINATED_CLOSING_BRACE, a(), 0), g = k(o, 1, Ke(r)), o.braceNest = 0, o.inLinked = !1, g;
418
+ if (o.braceNest > 0 && (o.currentType === 4 || o.currentType === 5 || o.currentType === 6))
419
+ return C(z.UNTERMINATED_CLOSING_BRACE, a(), 0), o.braceNest = 0, ze(r, o);
420
+ if (le = L(r, o))
421
+ return g = k(o, 4, Z(r)), S(r), g;
422
+ if (x = p(r, o))
423
+ return g = k(o, 5, K(r)), S(r), g;
424
+ if (_ = D(r, o))
425
+ return g = k(o, 6, ae(r)), S(r), g;
426
+ if (!le && !x && !_)
427
+ return g = k(o, 12, vt(r)), C(z.INVALID_TOKEN_IN_PLACEHOLDER, a(), 0, g.value), S(r), g;
428
+ break;
429
+ }
430
+ }
431
+ return g;
432
+ }
433
+ function We(r, o) {
434
+ const { currentType: g } = o;
435
+ let G = null;
436
+ const le = r.currentChar();
437
+ switch ((g === 7 || g === 8 || g === 11 || g === 9) && (le === _e || le === ke) && C(z.INVALID_LINKED_FORMAT, a(), 0), le) {
438
+ case "@":
439
+ return r.next(), G = k(
440
+ o,
441
+ 7,
442
+ "@"
443
+ /* TokenChars.LinkedAlias */
444
+ ), o.inLinked = !0, G;
445
+ case ".":
446
+ return S(r), r.next(), k(
447
+ o,
448
+ 8,
449
+ "."
450
+ /* TokenChars.LinkedDot */
451
+ );
452
+ case ":":
453
+ return S(r), r.next(), k(
454
+ o,
455
+ 9,
456
+ ":"
457
+ /* TokenChars.LinkedDelimiter */
458
+ );
459
+ default:
460
+ return w(r) ? (G = k(o, 1, Ke(r)), o.braceNest = 0, o.inLinked = !1, G) : A(r, o) || te(r, o) ? (S(r), We(r, o)) : y(r, o) ? (S(r), k(o, 11, It(r))) : T(r, o) ? (S(r), le === "{" ? Ge(r, o) || G : k(o, 10, Et(r))) : (g === 7 && C(z.INVALID_LINKED_FORMAT, a(), 0), o.braceNest = 0, o.inLinked = !1, ze(r, o));
461
+ }
462
+ }
463
+ function ze(r, o) {
464
+ let g = {
465
+ type: 13
466
+ /* TokenTypes.EOF */
467
+ };
468
+ if (o.braceNest > 0)
469
+ return Ge(r, o) || j(o);
470
+ if (o.inLinked)
471
+ return We(r, o) || j(o);
472
+ switch (r.currentChar()) {
473
+ case "{":
474
+ return Ge(r, o) || j(o);
475
+ case "}":
476
+ return C(z.UNBALANCED_CLOSING_BRACE, a(), 0), r.next(), k(
477
+ o,
478
+ 3,
479
+ "}"
480
+ /* TokenChars.BraceRight */
481
+ );
482
+ case "@":
483
+ return We(r, o) || j(o);
484
+ default: {
485
+ if (w(r))
486
+ return g = k(o, 1, Ke(r)), o.braceNest = 0, o.inLinked = !1, g;
487
+ if (U(r))
488
+ return k(o, 0, B(r));
489
+ break;
490
+ }
491
+ }
492
+ return g;
493
+ }
494
+ function Nt() {
495
+ const { currentType: r, offset: o, startLoc: g, endLoc: G } = u;
496
+ return u.lastType = r, u.lastOffset = o, u.lastStartLoc = g, u.lastEndLoc = G, u.offset = l(), u.startLoc = a(), s.currentChar() === Ce ? k(
497
+ u,
498
+ 13
499
+ /* TokenTypes.EOF */
500
+ ) : ze(s, u);
501
+ }
502
+ return {
503
+ nextToken: Nt,
504
+ currentOffset: l,
505
+ currentPosition: a,
506
+ context: h
507
+ };
508
+ }
509
+ const Rs = "parser", Cs = /(?:\\\\|\\'|\\u([0-9a-fA-F]{4})|\\U([0-9a-fA-F]{6}))/g;
510
+ function As(e, t, n) {
511
+ switch (e) {
512
+ case "\\\\":
513
+ return "\\";
514
+ case "\\'":
515
+ return "'";
516
+ default: {
517
+ const s = parseInt(t || n, 16);
518
+ return s <= 55295 || s >= 57344 ? String.fromCodePoint(s) : "�";
519
+ }
520
+ }
521
+ }
522
+ function Ss(e = {}) {
523
+ const t = e.location !== !1, { onError: n } = e;
524
+ function s(i, m, L, p, ...D) {
525
+ const A = i.currentPosition();
526
+ if (A.offset += p, A.column += p, n) {
527
+ const y = t ? Mt(L, A) : null, te = ht(m, y, {
528
+ domain: Rs,
529
+ args: D
530
+ });
531
+ n(te);
532
+ }
533
+ }
534
+ function l(i, m, L) {
535
+ const p = { type: i };
536
+ return t && (p.start = m, p.end = m, p.loc = { start: L, end: L }), p;
537
+ }
538
+ function a(i, m, L, p) {
539
+ t && (i.end = m, i.loc && (i.loc.end = L));
540
+ }
541
+ function c(i, m) {
542
+ const L = i.context(), p = l(3, L.offset, L.startLoc);
543
+ return p.value = m, a(p, i.currentOffset(), i.currentPosition()), p;
544
+ }
545
+ function d(i, m) {
546
+ const L = i.context(), { lastOffset: p, lastStartLoc: D } = L, A = l(5, p, D);
547
+ return A.index = parseInt(m, 10), i.nextToken(), a(A, i.currentOffset(), i.currentPosition()), A;
548
+ }
549
+ function u(i, m) {
550
+ const L = i.context(), { lastOffset: p, lastStartLoc: D } = L, A = l(4, p, D);
551
+ return A.key = m, i.nextToken(), a(A, i.currentOffset(), i.currentPosition()), A;
552
+ }
553
+ function h(i, m) {
554
+ const L = i.context(), { lastOffset: p, lastStartLoc: D } = L, A = l(9, p, D);
555
+ return A.value = m.replace(Cs, As), i.nextToken(), a(A, i.currentOffset(), i.currentPosition()), A;
556
+ }
557
+ function O(i) {
558
+ const m = i.nextToken(), L = i.context(), { lastOffset: p, lastStartLoc: D } = L, A = l(8, p, D);
559
+ return m.type !== 11 ? (s(i, z.UNEXPECTED_EMPTY_LINKED_MODIFIER, L.lastStartLoc, 0), A.value = "", a(A, p, D), {
560
+ nextConsumeToken: m,
561
+ node: A
562
+ }) : (m.value == null && s(i, z.UNEXPECTED_LEXICAL_ANALYSIS, L.lastStartLoc, 0, ye(m)), A.value = m.value || "", a(A, i.currentOffset(), i.currentPosition()), {
563
+ node: A
564
+ });
565
+ }
566
+ function C(i, m) {
567
+ const L = i.context(), p = l(7, L.offset, L.startLoc);
568
+ return p.value = m, a(p, i.currentOffset(), i.currentPosition()), p;
569
+ }
570
+ function k(i) {
571
+ const m = i.context(), L = l(6, m.offset, m.startLoc);
572
+ let p = i.nextToken();
573
+ if (p.type === 8) {
574
+ const D = O(i);
575
+ L.modifier = D.node, p = D.nextConsumeToken || i.nextToken();
576
+ }
577
+ switch (p.type !== 9 && s(i, z.UNEXPECTED_LEXICAL_ANALYSIS, m.lastStartLoc, 0, ye(p)), p = i.nextToken(), p.type === 2 && (p = i.nextToken()), p.type) {
578
+ case 10:
579
+ p.value == null && s(i, z.UNEXPECTED_LEXICAL_ANALYSIS, m.lastStartLoc, 0, ye(p)), L.key = C(i, p.value || "");
580
+ break;
581
+ case 4:
582
+ p.value == null && s(i, z.UNEXPECTED_LEXICAL_ANALYSIS, m.lastStartLoc, 0, ye(p)), L.key = u(i, p.value || "");
583
+ break;
584
+ case 5:
585
+ p.value == null && s(i, z.UNEXPECTED_LEXICAL_ANALYSIS, m.lastStartLoc, 0, ye(p)), L.key = d(i, p.value || "");
586
+ break;
587
+ case 6:
588
+ p.value == null && s(i, z.UNEXPECTED_LEXICAL_ANALYSIS, m.lastStartLoc, 0, ye(p)), L.key = h(i, p.value || "");
589
+ break;
590
+ default: {
591
+ s(i, z.UNEXPECTED_EMPTY_LINKED_KEY, m.lastStartLoc, 0);
592
+ const D = i.context(), A = l(7, D.offset, D.startLoc);
593
+ return A.value = "", a(A, D.offset, D.startLoc), L.key = A, a(L, D.offset, D.startLoc), {
594
+ nextConsumeToken: p,
595
+ node: L
596
+ };
597
+ }
598
+ }
599
+ return a(L, i.currentOffset(), i.currentPosition()), {
600
+ node: L
601
+ };
602
+ }
603
+ function j(i) {
604
+ const m = i.context(), L = m.currentType === 1 ? i.currentOffset() : m.offset, p = m.currentType === 1 ? m.endLoc : m.startLoc, D = l(2, L, p);
605
+ D.items = [];
606
+ let A = null;
607
+ do {
608
+ const T = A || i.nextToken();
609
+ switch (A = null, T.type) {
610
+ case 0:
611
+ T.value == null && s(i, z.UNEXPECTED_LEXICAL_ANALYSIS, m.lastStartLoc, 0, ye(T)), D.items.push(c(i, T.value || ""));
612
+ break;
613
+ case 5:
614
+ T.value == null && s(i, z.UNEXPECTED_LEXICAL_ANALYSIS, m.lastStartLoc, 0, ye(T)), D.items.push(d(i, T.value || ""));
615
+ break;
616
+ case 4:
617
+ T.value == null && s(i, z.UNEXPECTED_LEXICAL_ANALYSIS, m.lastStartLoc, 0, ye(T)), D.items.push(u(i, T.value || ""));
618
+ break;
619
+ case 6:
620
+ T.value == null && s(i, z.UNEXPECTED_LEXICAL_ANALYSIS, m.lastStartLoc, 0, ye(T)), D.items.push(h(i, T.value || ""));
621
+ break;
622
+ case 7: {
623
+ const w = k(i);
624
+ D.items.push(w.node), A = w.nextConsumeToken || null;
625
+ break;
626
+ }
627
+ }
628
+ } while (m.currentType !== 13 && m.currentType !== 1);
629
+ const y = m.currentType === 1 ? m.lastOffset : i.currentOffset(), te = m.currentType === 1 ? m.lastEndLoc : i.currentPosition();
630
+ return a(D, y, te), D;
631
+ }
632
+ function W(i, m, L, p) {
633
+ const D = i.context();
634
+ let A = p.items.length === 0;
635
+ const y = l(1, m, L);
636
+ y.cases = [], y.cases.push(p);
637
+ do {
638
+ const te = j(i);
639
+ A || (A = te.items.length === 0), y.cases.push(te);
640
+ } while (D.currentType !== 13);
641
+ return A && s(i, z.MUST_HAVE_MESSAGES_IN_PLURAL, L, 0), a(y, i.currentOffset(), i.currentPosition()), y;
642
+ }
643
+ function R(i) {
644
+ const m = i.context(), { offset: L, startLoc: p } = m, D = j(i);
645
+ return m.currentType === 13 ? D : W(i, L, p, D);
646
+ }
647
+ function S(i) {
648
+ const m = Os(i, de({}, e)), L = m.context(), p = l(0, L.offset, L.startLoc);
649
+ return t && p.loc && (p.loc.source = i), p.body = R(m), e.onCacheKey && (p.cacheKey = e.onCacheKey(i)), L.currentType !== 13 && s(m, z.UNEXPECTED_LEXICAL_ANALYSIS, L.lastStartLoc, 0, i[L.offset] || ""), a(p, m.currentOffset(), m.currentPosition()), p;
650
+ }
651
+ return { parse: S };
652
+ }
653
+ function ye(e) {
654
+ if (e.type === 13)
655
+ return "EOF";
656
+ const t = (e.value || "").replace(/\r?\n/gu, "\\n");
657
+ return t.length > 10 ? t.slice(0, 9) + "…" : t;
658
+ }
659
+ function Ds(e, t = {}) {
660
+ const n = {
661
+ ast: e,
662
+ helpers: /* @__PURE__ */ new Set()
663
+ };
664
+ return { context: () => n, helper: (a) => (n.helpers.add(a), a) };
665
+ }
666
+ function sn(e, t) {
667
+ for (let n = 0; n < e.length; n++)
668
+ Bt(e[n], t);
669
+ }
670
+ function Bt(e, t) {
671
+ switch (e.type) {
672
+ case 1:
673
+ sn(e.cases, t), t.helper(
674
+ "plural"
675
+ /* HelperNameMap.PLURAL */
676
+ );
677
+ break;
678
+ case 2:
679
+ sn(e.items, t);
680
+ break;
681
+ case 6: {
682
+ Bt(e.key, t), t.helper(
683
+ "linked"
684
+ /* HelperNameMap.LINKED */
685
+ ), t.helper(
686
+ "type"
687
+ /* HelperNameMap.TYPE */
688
+ );
689
+ break;
690
+ }
691
+ case 5:
692
+ t.helper(
693
+ "interpolate"
694
+ /* HelperNameMap.INTERPOLATE */
695
+ ), t.helper(
696
+ "list"
697
+ /* HelperNameMap.LIST */
698
+ );
699
+ break;
700
+ case 4:
701
+ t.helper(
702
+ "interpolate"
703
+ /* HelperNameMap.INTERPOLATE */
704
+ ), t.helper(
705
+ "named"
706
+ /* HelperNameMap.NAMED */
707
+ );
708
+ break;
709
+ }
710
+ }
711
+ function Ms(e, t = {}) {
712
+ const n = Ds(e);
713
+ n.helper(
714
+ "normalize"
715
+ /* HelperNameMap.NORMALIZE */
716
+ ), e.body && Bt(e.body, n);
717
+ const s = n.context();
718
+ e.helpers = Array.from(s.helpers);
719
+ }
720
+ function ws(e) {
721
+ const t = e.body;
722
+ return t.type === 2 ? an(t) : t.cases.forEach((n) => an(n)), e;
723
+ }
724
+ function an(e) {
725
+ if (e.items.length === 1) {
726
+ const t = e.items[0];
727
+ (t.type === 3 || t.type === 9) && (e.static = t.value, delete t.value);
728
+ } else {
729
+ const t = [];
730
+ for (let n = 0; n < e.items.length; n++) {
731
+ const s = e.items[n];
732
+ if (!(s.type === 3 || s.type === 9) || s.value == null)
733
+ break;
734
+ t.push(s.value);
735
+ }
736
+ if (t.length === e.items.length) {
737
+ e.static = Yt(t);
738
+ for (let n = 0; n < e.items.length; n++) {
739
+ const s = e.items[n];
740
+ (s.type === 3 || s.type === 9) && delete s.value;
741
+ }
742
+ }
743
+ }
744
+ }
745
+ function xe(e) {
746
+ switch (e.t = e.type, e.type) {
747
+ case 0: {
748
+ const t = e;
749
+ xe(t.body), t.b = t.body, delete t.body;
750
+ break;
751
+ }
752
+ case 1: {
753
+ const t = e, n = t.cases;
754
+ for (let s = 0; s < n.length; s++)
755
+ xe(n[s]);
756
+ t.c = n, delete t.cases;
757
+ break;
758
+ }
759
+ case 2: {
760
+ const t = e, n = t.items;
761
+ for (let s = 0; s < n.length; s++)
762
+ xe(n[s]);
763
+ t.i = n, delete t.items, t.static && (t.s = t.static, delete t.static);
764
+ break;
765
+ }
766
+ case 3:
767
+ case 9:
768
+ case 8:
769
+ case 7: {
770
+ const t = e;
771
+ t.value && (t.v = t.value, delete t.value);
772
+ break;
773
+ }
774
+ case 6: {
775
+ const t = e;
776
+ xe(t.key), t.k = t.key, delete t.key, t.modifier && (xe(t.modifier), t.m = t.modifier, delete t.modifier);
777
+ break;
778
+ }
779
+ case 5: {
780
+ const t = e;
781
+ t.i = t.index, delete t.index;
782
+ break;
783
+ }
784
+ case 4: {
785
+ const t = e;
786
+ t.k = t.key, delete t.key;
787
+ break;
788
+ }
789
+ }
790
+ delete e.type;
791
+ }
792
+ function Ps(e, t) {
793
+ const { filename: n, breakLineCode: s, needIndent: l } = t, a = t.location !== !1, c = {
794
+ filename: n,
795
+ code: "",
796
+ column: 1,
797
+ line: 1,
798
+ offset: 0,
799
+ map: void 0,
800
+ breakLineCode: s,
801
+ needIndent: l,
802
+ indentLevel: 0
803
+ };
804
+ a && e.loc && (c.source = e.loc.source);
805
+ const d = () => c;
806
+ function u(R, S) {
807
+ c.code += R;
808
+ }
809
+ function h(R, S = !0) {
810
+ const i = S ? s : "";
811
+ u(l ? i + " ".repeat(R) : i);
812
+ }
813
+ function O(R = !0) {
814
+ const S = ++c.indentLevel;
815
+ R && h(S);
816
+ }
817
+ function C(R = !0) {
818
+ const S = --c.indentLevel;
819
+ R && h(S);
820
+ }
821
+ function k() {
822
+ h(c.indentLevel);
823
+ }
824
+ return {
825
+ context: d,
826
+ push: u,
827
+ indent: O,
828
+ deindent: C,
829
+ newline: k,
830
+ helper: (R) => `_${R}`,
831
+ needIndent: () => c.needIndent
832
+ };
833
+ }
834
+ function Fs(e, t) {
835
+ const { helper: n } = e;
836
+ e.push(`${n(
837
+ "linked"
838
+ /* HelperNameMap.LINKED */
839
+ )}(`), Ye(e, t.key), t.modifier ? (e.push(", "), Ye(e, t.modifier), e.push(", _type")) : e.push(", undefined, _type"), e.push(")");
840
+ }
841
+ function js(e, t) {
842
+ const { helper: n, needIndent: s } = e;
843
+ e.push(`${n(
844
+ "normalize"
845
+ /* HelperNameMap.NORMALIZE */
846
+ )}([`), e.indent(s());
847
+ const l = t.items.length;
848
+ for (let a = 0; a < l && (Ye(e, t.items[a]), a !== l - 1); a++)
849
+ e.push(", ");
850
+ e.deindent(s()), e.push("])");
851
+ }
852
+ function Us(e, t) {
853
+ const { helper: n, needIndent: s } = e;
854
+ if (t.cases.length > 1) {
855
+ e.push(`${n(
856
+ "plural"
857
+ /* HelperNameMap.PLURAL */
858
+ )}([`), e.indent(s());
859
+ const l = t.cases.length;
860
+ for (let a = 0; a < l && (Ye(e, t.cases[a]), a !== l - 1); a++)
861
+ e.push(", ");
862
+ e.deindent(s()), e.push("])");
863
+ }
864
+ }
865
+ function Vs(e, t) {
866
+ t.body ? Ye(e, t.body) : e.push("null");
867
+ }
868
+ function Ye(e, t) {
869
+ const { helper: n } = e;
870
+ switch (t.type) {
871
+ case 0:
872
+ Vs(e, t);
873
+ break;
874
+ case 1:
875
+ Us(e, t);
876
+ break;
877
+ case 2:
878
+ js(e, t);
879
+ break;
880
+ case 6:
881
+ Fs(e, t);
882
+ break;
883
+ case 8:
884
+ e.push(JSON.stringify(t.value), t);
885
+ break;
886
+ case 7:
887
+ e.push(JSON.stringify(t.value), t);
888
+ break;
889
+ case 5:
890
+ e.push(`${n(
891
+ "interpolate"
892
+ /* HelperNameMap.INTERPOLATE */
893
+ )}(${n(
894
+ "list"
895
+ /* HelperNameMap.LIST */
896
+ )}(${t.index}))`, t);
897
+ break;
898
+ case 4:
899
+ e.push(`${n(
900
+ "interpolate"
901
+ /* HelperNameMap.INTERPOLATE */
902
+ )}(${n(
903
+ "named"
904
+ /* HelperNameMap.NAMED */
905
+ )}(${JSON.stringify(t.key)}))`, t);
906
+ break;
907
+ case 9:
908
+ e.push(JSON.stringify(t.value), t);
909
+ break;
910
+ case 3:
911
+ e.push(JSON.stringify(t.value), t);
912
+ break;
913
+ }
914
+ }
915
+ const Gs = (e, t = {}) => {
916
+ const n = F(t.mode) ? t.mode : "normal", s = F(t.filename) ? t.filename : "message.intl";
917
+ t.sourceMap;
918
+ const l = t.breakLineCode != null ? t.breakLineCode : n === "arrow" ? ";" : `
919
+ `, a = t.needIndent ? t.needIndent : n !== "arrow", c = e.helpers || [], d = Ps(e, {
920
+ filename: s,
921
+ breakLineCode: l,
922
+ needIndent: a
923
+ });
924
+ d.push(n === "normal" ? "function __msg__ (ctx) {" : "(ctx) => {"), d.indent(a), c.length > 0 && (d.push(`const { ${Yt(c.map((O) => `${O}: _${O}`), ", ")} } = ctx`), d.newline()), d.push("return "), Ye(d, e), d.deindent(a), d.push("}"), delete e.helpers;
925
+ const { code: u, map: h } = d.context();
926
+ return {
927
+ ast: e,
928
+ code: u,
929
+ map: h ? h.toJSON() : void 0
930
+ // eslint-disable-line @typescript-eslint/no-explicit-any
931
+ };
932
+ };
933
+ function Ws(e, t = {}) {
934
+ const n = de({}, t), s = !!n.jit, l = !!n.minify, a = n.optimize == null ? !0 : n.optimize, d = Ss(n).parse(e);
935
+ return s ? (a && ws(d), l && xe(d), { ast: d, code: "" }) : (Ms(d, n), Gs(d, n));
936
+ }
937
+ var Zs = { env: { NODE_ENV: "production" } };
938
+ function xs() {
939
+ typeof __INTLIFY_PROD_DEVTOOLS__ != "boolean" && (je().__INTLIFY_PROD_DEVTOOLS__ = !1), typeof __INTLIFY_DROP_MESSAGE_COMPILER__ != "boolean" && (je().__INTLIFY_DROP_MESSAGE_COMPILER__ = !1);
940
+ }
941
+ function Lt(e) {
942
+ return (n) => Xs(n, e);
943
+ }
944
+ function Xs(e, t) {
945
+ const n = Bs(t);
946
+ if (n == null)
947
+ throw et(
948
+ 0
949
+ /* NodeTypes.Resource */
950
+ );
951
+ if (Ht(n) === 1) {
952
+ const a = $s(n);
953
+ return e.plural(a.reduce((c, d) => [
954
+ ...c,
955
+ rn(e, d)
956
+ ], []));
957
+ } else
958
+ return rn(e, n);
959
+ }
960
+ const Ys = ["b", "body"];
961
+ function Bs(e) {
962
+ return De(e, Ys);
963
+ }
964
+ const Hs = ["c", "cases"];
965
+ function $s(e) {
966
+ return De(e, Hs, []);
967
+ }
968
+ function rn(e, t) {
969
+ const n = Ks(t);
970
+ if (n != null)
971
+ return e.type === "text" ? n : e.normalize([n]);
972
+ {
973
+ const s = Qs(t).reduce((l, a) => [...l, wt(e, a)], []);
974
+ return e.normalize(s);
975
+ }
976
+ }
977
+ const Js = ["s", "static"];
978
+ function Ks(e) {
979
+ return De(e, Js);
980
+ }
981
+ const zs = ["i", "items"];
982
+ function Qs(e) {
983
+ return De(e, zs, []);
984
+ }
985
+ function wt(e, t) {
986
+ const n = Ht(t);
987
+ switch (n) {
988
+ case 3:
989
+ return lt(t, n);
990
+ case 9:
991
+ return lt(t, n);
992
+ case 4: {
993
+ const s = t;
994
+ if (Ee(s, "k") && s.k)
995
+ return e.interpolate(e.named(s.k));
996
+ if (Ee(s, "key") && s.key)
997
+ return e.interpolate(e.named(s.key));
998
+ throw et(n);
999
+ }
1000
+ case 5: {
1001
+ const s = t;
1002
+ if (Ee(s, "i") && me(s.i))
1003
+ return e.interpolate(e.list(s.i));
1004
+ if (Ee(s, "index") && me(s.index))
1005
+ return e.interpolate(e.list(s.index));
1006
+ throw et(n);
1007
+ }
1008
+ case 6: {
1009
+ const s = t, l = na(s), a = aa(s);
1010
+ return e.linked(wt(e, a), l ? wt(e, l) : void 0, e.type);
1011
+ }
1012
+ case 7:
1013
+ return lt(t, n);
1014
+ case 8:
1015
+ return lt(t, n);
1016
+ default:
1017
+ throw new Error(`unhandled node on format message part: ${n}`);
1018
+ }
1019
+ }
1020
+ const qs = ["t", "type"];
1021
+ function Ht(e) {
1022
+ return De(e, qs);
1023
+ }
1024
+ const ea = ["v", "value"];
1025
+ function lt(e, t) {
1026
+ const n = De(e, ea);
1027
+ if (n)
1028
+ return n;
1029
+ throw et(t);
1030
+ }
1031
+ const ta = ["m", "modifier"];
1032
+ function na(e) {
1033
+ return De(e, ta);
1034
+ }
1035
+ const sa = ["k", "key"];
1036
+ function aa(e) {
1037
+ const t = De(e, sa);
1038
+ if (t)
1039
+ return t;
1040
+ throw et(
1041
+ 6
1042
+ /* NodeTypes.Linked */
1043
+ );
1044
+ }
1045
+ function De(e, t, n) {
1046
+ for (let s = 0; s < t.length; s++) {
1047
+ const l = t[s];
1048
+ if (Ee(e, l) && e[l] != null)
1049
+ return e[l];
1050
+ }
1051
+ return n;
1052
+ }
1053
+ function et(e) {
1054
+ return new Error(`unhandled node type: ${e}`);
1055
+ }
1056
+ const ra = (e) => e;
1057
+ let ot = Q();
1058
+ function Be(e) {
1059
+ return $(e) && Ht(e) === 0 && (Ee(e, "b") || Ee(e, "body"));
1060
+ }
1061
+ function la(e, t = {}) {
1062
+ let n = !1;
1063
+ const s = t.onError || Is;
1064
+ return t.onError = (l) => {
1065
+ n = !0, s(l);
1066
+ }, { ...Ws(e, t), detectError: n };
1067
+ }
1068
+ // @__NO_SIDE_EFFECTS__
1069
+ function oa(e, t) {
1070
+ if (!__INTLIFY_DROP_MESSAGE_COMPILER__ && F(e)) {
1071
+ ie(t.warnHtmlMessage) && t.warnHtmlMessage;
1072
+ const s = (t.onCacheKey || ra)(e), l = ot[s];
1073
+ if (l)
1074
+ return l;
1075
+ const { ast: a, detectError: c } = la(e, {
1076
+ ...t,
1077
+ location: Zs.env.NODE_ENV !== "production",
1078
+ jit: !0
1079
+ }), d = Lt(a);
1080
+ return c ? d : ot[s] = d;
1081
+ } else {
1082
+ const n = e.cacheKey;
1083
+ if (n) {
1084
+ const s = ot[n];
1085
+ return s || (ot[n] = Lt(e));
1086
+ } else
1087
+ return Lt(e);
1088
+ }
1089
+ }
1090
+ let tt = null;
1091
+ function ia(e) {
1092
+ tt = e;
1093
+ }
1094
+ function ca(e, t, n) {
1095
+ tt && tt.emit("i18n:init", {
1096
+ timestamp: Date.now(),
1097
+ i18n: e,
1098
+ version: t,
1099
+ meta: n
1100
+ });
1101
+ }
1102
+ const ua = /* @__PURE__ */ ma("function:translate");
1103
+ function ma(e) {
1104
+ return (t) => tt && tt.emit(e, t);
1105
+ }
1106
+ const Oe = {
1107
+ INVALID_ARGUMENT: vs,
1108
+ // 17
1109
+ INVALID_DATE_ARGUMENT: 18,
1110
+ INVALID_ISO_DATE_ARGUMENT: 19,
1111
+ NOT_SUPPORT_LOCALE_PROMISE_VALUE: 21,
1112
+ NOT_SUPPORT_LOCALE_ASYNC_FUNCTION: 22,
1113
+ NOT_SUPPORT_LOCALE_TYPE: 23
1114
+ }, da = 24;
1115
+ function Re(e) {
1116
+ return ht(e, null, void 0);
1117
+ }
1118
+ function $t(e, t) {
1119
+ return t.locale != null ? ln(t.locale) : ln(e.locale);
1120
+ }
1121
+ let Ot;
1122
+ function ln(e) {
1123
+ if (F(e))
1124
+ return e;
1125
+ if (re(e)) {
1126
+ if (e.resolvedOnce && Ot != null)
1127
+ return Ot;
1128
+ if (e.constructor.name === "Function") {
1129
+ const t = e();
1130
+ if (ps(t))
1131
+ throw Re(Oe.NOT_SUPPORT_LOCALE_PROMISE_VALUE);
1132
+ return Ot = t;
1133
+ } else
1134
+ throw Re(Oe.NOT_SUPPORT_LOCALE_ASYNC_FUNCTION);
1135
+ } else
1136
+ throw Re(Oe.NOT_SUPPORT_LOCALE_TYPE);
1137
+ }
1138
+ function fa(e, t, n) {
1139
+ return [.../* @__PURE__ */ new Set([
1140
+ n,
1141
+ ...ce(t) ? t : $(t) ? Object.keys(t) : F(t) ? [t] : [n]
1142
+ ])];
1143
+ }
1144
+ function An(e, t, n) {
1145
+ const s = F(n) ? n : ft, l = e;
1146
+ l.__localeChainCache || (l.__localeChainCache = /* @__PURE__ */ new Map());
1147
+ let a = l.__localeChainCache.get(s);
1148
+ if (!a) {
1149
+ a = [];
1150
+ let c = [n];
1151
+ for (; ce(c); )
1152
+ c = on(a, c, t);
1153
+ const d = ce(t) || !H(t) ? t : t.default ? t.default : null;
1154
+ c = F(d) ? [d] : d, ce(c) && on(a, c, !1), l.__localeChainCache.set(s, a);
1155
+ }
1156
+ return a;
1157
+ }
1158
+ function on(e, t, n) {
1159
+ let s = !0;
1160
+ for (let l = 0; l < t.length && ie(s); l++) {
1161
+ const a = t[l];
1162
+ F(a) && (s = _a(e, t[l], n));
1163
+ }
1164
+ return s;
1165
+ }
1166
+ function _a(e, t, n) {
1167
+ let s;
1168
+ const l = t.split("-");
1169
+ do {
1170
+ const a = l.join("-");
1171
+ s = pa(e, a, n), l.splice(-1, 1);
1172
+ } while (l.length && s === !0);
1173
+ return s;
1174
+ }
1175
+ function pa(e, t, n) {
1176
+ let s = !1;
1177
+ if (!e.includes(t) && (s = !0, t)) {
1178
+ s = t[t.length - 1] !== "!";
1179
+ const l = t.replace(/!/g, "");
1180
+ e.push(l), (ce(n) || H(n)) && n[l] && (s = n[l]);
1181
+ }
1182
+ return s;
1183
+ }
1184
+ const Me = [];
1185
+ Me[
1186
+ 0
1187
+ /* States.BEFORE_PATH */
1188
+ ] = {
1189
+ w: [
1190
+ 0
1191
+ /* States.BEFORE_PATH */
1192
+ ],
1193
+ i: [
1194
+ 3,
1195
+ 0
1196
+ /* Actions.APPEND */
1197
+ ],
1198
+ "[": [
1199
+ 4
1200
+ /* States.IN_SUB_PATH */
1201
+ ],
1202
+ o: [
1203
+ 7
1204
+ /* States.AFTER_PATH */
1205
+ ]
1206
+ };
1207
+ Me[
1208
+ 1
1209
+ /* States.IN_PATH */
1210
+ ] = {
1211
+ w: [
1212
+ 1
1213
+ /* States.IN_PATH */
1214
+ ],
1215
+ ".": [
1216
+ 2
1217
+ /* States.BEFORE_IDENT */
1218
+ ],
1219
+ "[": [
1220
+ 4
1221
+ /* States.IN_SUB_PATH */
1222
+ ],
1223
+ o: [
1224
+ 7
1225
+ /* States.AFTER_PATH */
1226
+ ]
1227
+ };
1228
+ Me[
1229
+ 2
1230
+ /* States.BEFORE_IDENT */
1231
+ ] = {
1232
+ w: [
1233
+ 2
1234
+ /* States.BEFORE_IDENT */
1235
+ ],
1236
+ i: [
1237
+ 3,
1238
+ 0
1239
+ /* Actions.APPEND */
1240
+ ],
1241
+ 0: [
1242
+ 3,
1243
+ 0
1244
+ /* Actions.APPEND */
1245
+ ]
1246
+ };
1247
+ Me[
1248
+ 3
1249
+ /* States.IN_IDENT */
1250
+ ] = {
1251
+ i: [
1252
+ 3,
1253
+ 0
1254
+ /* Actions.APPEND */
1255
+ ],
1256
+ 0: [
1257
+ 3,
1258
+ 0
1259
+ /* Actions.APPEND */
1260
+ ],
1261
+ w: [
1262
+ 1,
1263
+ 1
1264
+ /* Actions.PUSH */
1265
+ ],
1266
+ ".": [
1267
+ 2,
1268
+ 1
1269
+ /* Actions.PUSH */
1270
+ ],
1271
+ "[": [
1272
+ 4,
1273
+ 1
1274
+ /* Actions.PUSH */
1275
+ ],
1276
+ o: [
1277
+ 7,
1278
+ 1
1279
+ /* Actions.PUSH */
1280
+ ]
1281
+ };
1282
+ Me[
1283
+ 4
1284
+ /* States.IN_SUB_PATH */
1285
+ ] = {
1286
+ "'": [
1287
+ 5,
1288
+ 0
1289
+ /* Actions.APPEND */
1290
+ ],
1291
+ '"': [
1292
+ 6,
1293
+ 0
1294
+ /* Actions.APPEND */
1295
+ ],
1296
+ "[": [
1297
+ 4,
1298
+ 2
1299
+ /* Actions.INC_SUB_PATH_DEPTH */
1300
+ ],
1301
+ "]": [
1302
+ 1,
1303
+ 3
1304
+ /* Actions.PUSH_SUB_PATH */
1305
+ ],
1306
+ o: 8,
1307
+ l: [
1308
+ 4,
1309
+ 0
1310
+ /* Actions.APPEND */
1311
+ ]
1312
+ };
1313
+ Me[
1314
+ 5
1315
+ /* States.IN_SINGLE_QUOTE */
1316
+ ] = {
1317
+ "'": [
1318
+ 4,
1319
+ 0
1320
+ /* Actions.APPEND */
1321
+ ],
1322
+ o: 8,
1323
+ l: [
1324
+ 5,
1325
+ 0
1326
+ /* Actions.APPEND */
1327
+ ]
1328
+ };
1329
+ Me[
1330
+ 6
1331
+ /* States.IN_DOUBLE_QUOTE */
1332
+ ] = {
1333
+ '"': [
1334
+ 4,
1335
+ 0
1336
+ /* Actions.APPEND */
1337
+ ],
1338
+ o: 8,
1339
+ l: [
1340
+ 6,
1341
+ 0
1342
+ /* Actions.APPEND */
1343
+ ]
1344
+ };
1345
+ const ha = /^\s?(?:true|false|-?[\d.]+|'[^']*'|"[^"]*")\s?$/;
1346
+ function ba(e) {
1347
+ return ha.test(e);
1348
+ }
1349
+ function ga(e) {
1350
+ const t = e.charCodeAt(0), n = e.charCodeAt(e.length - 1);
1351
+ return t === n && (t === 34 || t === 39) ? e.slice(1, -1) : e;
1352
+ }
1353
+ function va(e) {
1354
+ if (e == null)
1355
+ return "o";
1356
+ switch (e.charCodeAt(0)) {
1357
+ case 91:
1358
+ case 93:
1359
+ case 46:
1360
+ case 34:
1361
+ case 39:
1362
+ return e;
1363
+ case 95:
1364
+ case 36:
1365
+ case 45:
1366
+ return "i";
1367
+ case 9:
1368
+ case 10:
1369
+ case 13:
1370
+ case 160:
1371
+ case 65279:
1372
+ case 8232:
1373
+ case 8233:
1374
+ return "w";
1375
+ }
1376
+ return "i";
1377
+ }
1378
+ function Ia(e) {
1379
+ const t = e.trim();
1380
+ return e.charAt(0) === "0" && isNaN(parseInt(e)) ? !1 : ba(t) ? ga(t) : "*" + t;
1381
+ }
1382
+ function Ea(e) {
1383
+ const t = [];
1384
+ let n = -1, s = 0, l = 0, a, c, d, u, h, O, C;
1385
+ const k = [];
1386
+ k[
1387
+ 0
1388
+ /* Actions.APPEND */
1389
+ ] = () => {
1390
+ c === void 0 ? c = d : c += d;
1391
+ }, k[
1392
+ 1
1393
+ /* Actions.PUSH */
1394
+ ] = () => {
1395
+ c !== void 0 && (t.push(c), c = void 0);
1396
+ }, k[
1397
+ 2
1398
+ /* Actions.INC_SUB_PATH_DEPTH */
1399
+ ] = () => {
1400
+ k[
1401
+ 0
1402
+ /* Actions.APPEND */
1403
+ ](), l++;
1404
+ }, k[
1405
+ 3
1406
+ /* Actions.PUSH_SUB_PATH */
1407
+ ] = () => {
1408
+ if (l > 0)
1409
+ l--, s = 4, k[
1410
+ 0
1411
+ /* Actions.APPEND */
1412
+ ]();
1413
+ else {
1414
+ if (l = 0, c === void 0 || (c = Ia(c), c === !1))
1415
+ return !1;
1416
+ k[
1417
+ 1
1418
+ /* Actions.PUSH */
1419
+ ]();
1420
+ }
1421
+ };
1422
+ function j() {
1423
+ const W = e[n + 1];
1424
+ if (s === 5 && W === "'" || s === 6 && W === '"')
1425
+ return n++, d = "\\" + W, k[
1426
+ 0
1427
+ /* Actions.APPEND */
1428
+ ](), !0;
1429
+ }
1430
+ for (; s !== null; )
1431
+ if (n++, a = e[n], !(a === "\\" && j())) {
1432
+ if (u = va(a), C = Me[s], h = C[u] || C.l || 8, h === 8 || (s = h[0], h[1] !== void 0 && (O = k[h[1]], O && (d = a, O() === !1))))
1433
+ return;
1434
+ if (s === 7)
1435
+ return t;
1436
+ }
1437
+ }
1438
+ const cn = /* @__PURE__ */ new Map();
1439
+ function Na(e, t) {
1440
+ return $(e) ? e[t] : null;
1441
+ }
1442
+ function ya(e, t) {
1443
+ if (!$(e))
1444
+ return null;
1445
+ let n = cn.get(t);
1446
+ if (n || (n = Ea(t), n && cn.set(t, n)), !n)
1447
+ return null;
1448
+ const s = n.length;
1449
+ let l = e, a = 0;
1450
+ for (; a < s; ) {
1451
+ const c = l[n[a]];
1452
+ if (c === void 0 || re(l))
1453
+ return null;
1454
+ l = c, a++;
1455
+ }
1456
+ return l;
1457
+ }
1458
+ const Ta = "10.0.5", bt = -1, ft = "en-US", un = "", mn = (e) => `${e.charAt(0).toLocaleUpperCase()}${e.substr(1)}`;
1459
+ function ka() {
1460
+ return {
1461
+ upper: (e, t) => t === "text" && F(e) ? e.toUpperCase() : t === "vnode" && $(e) && "__v_isVNode" in e ? e.children.toUpperCase() : e,
1462
+ lower: (e, t) => t === "text" && F(e) ? e.toLowerCase() : t === "vnode" && $(e) && "__v_isVNode" in e ? e.children.toLowerCase() : e,
1463
+ capitalize: (e, t) => t === "text" && F(e) ? mn(e) : t === "vnode" && $(e) && "__v_isVNode" in e ? mn(e.children) : e
1464
+ };
1465
+ }
1466
+ let Sn;
1467
+ function La(e) {
1468
+ Sn = e;
1469
+ }
1470
+ let Dn;
1471
+ function Oa(e) {
1472
+ Dn = e;
1473
+ }
1474
+ let Mn;
1475
+ function Ra(e) {
1476
+ Mn = e;
1477
+ }
1478
+ let wn = null;
1479
+ const Ca = /* @__NO_SIDE_EFFECTS__ */ (e) => {
1480
+ wn = e;
1481
+ }, Aa = /* @__NO_SIDE_EFFECTS__ */ () => wn;
1482
+ let Pn = null;
1483
+ const dn = (e) => {
1484
+ Pn = e;
1485
+ }, Sa = () => Pn;
1486
+ let fn = 0;
1487
+ function Da(e = {}) {
1488
+ const t = re(e.onWarn) ? e.onWarn : bs, n = F(e.version) ? e.version : Ta, s = F(e.locale) || re(e.locale) ? e.locale : ft, l = re(s) ? ft : s, a = ce(e.fallbackLocale) || H(e.fallbackLocale) || F(e.fallbackLocale) || e.fallbackLocale === !1 ? e.fallbackLocale : l, c = H(e.messages) ? e.messages : Rt(l), d = H(e.datetimeFormats) ? e.datetimeFormats : Rt(l), u = H(e.numberFormats) ? e.numberFormats : Rt(l), h = de(Q(), e.modifiers, ka()), O = e.pluralRules || Q(), C = re(e.missing) ? e.missing : null, k = ie(e.missingWarn) || dt(e.missingWarn) ? e.missingWarn : !0, j = ie(e.fallbackWarn) || dt(e.fallbackWarn) ? e.fallbackWarn : !0, W = !!e.fallbackFormat, R = !!e.unresolving, S = re(e.postTranslation) ? e.postTranslation : null, i = H(e.processor) ? e.processor : null, m = ie(e.warnHtmlMessage) ? e.warnHtmlMessage : !0, L = !!e.escapeParameter, p = re(e.messageCompiler) ? e.messageCompiler : Sn, D = re(e.messageResolver) ? e.messageResolver : Dn || Na, A = re(e.localeFallbacker) ? e.localeFallbacker : Mn || fa, y = $(e.fallbackContext) ? e.fallbackContext : void 0, te = e, T = $(te.__datetimeFormatters) ? te.__datetimeFormatters : /* @__PURE__ */ new Map(), w = $(te.__numberFormatters) ? te.__numberFormatters : /* @__PURE__ */ new Map(), U = $(te.__meta) ? te.__meta : {};
1489
+ fn++;
1490
+ const f = {
1491
+ version: n,
1492
+ cid: fn,
1493
+ locale: s,
1494
+ fallbackLocale: a,
1495
+ messages: c,
1496
+ modifiers: h,
1497
+ pluralRules: O,
1498
+ missing: C,
1499
+ missingWarn: k,
1500
+ fallbackWarn: j,
1501
+ fallbackFormat: W,
1502
+ unresolving: R,
1503
+ postTranslation: S,
1504
+ processor: i,
1505
+ warnHtmlMessage: m,
1506
+ escapeParameter: L,
1507
+ messageCompiler: p,
1508
+ messageResolver: D,
1509
+ localeFallbacker: A,
1510
+ fallbackContext: y,
1511
+ onWarn: t,
1512
+ __meta: U
1513
+ };
1514
+ return f.datetimeFormats = d, f.numberFormats = u, f.__datetimeFormatters = T, f.__numberFormatters = w, __INTLIFY_PROD_DEVTOOLS__ && ca(f, n, U), f;
1515
+ }
1516
+ const Rt = (e) => ({ [e]: Q() });
1517
+ function Jt(e, t, n, s, l) {
1518
+ const { missing: a, onWarn: c } = e;
1519
+ if (a !== null) {
1520
+ const d = a(e, n, t, l);
1521
+ return F(d) ? d : t;
1522
+ } else
1523
+ return t;
1524
+ }
1525
+ function Qe(e, t, n) {
1526
+ const s = e;
1527
+ s.__localeChainCache = /* @__PURE__ */ new Map(), e.localeFallbacker(e, n, t);
1528
+ }
1529
+ function Ma(e, t) {
1530
+ return e === t ? !1 : e.split("-")[0] === t.split("-")[0];
1531
+ }
1532
+ function wa(e, t) {
1533
+ const n = t.indexOf(e);
1534
+ if (n === -1)
1535
+ return !1;
1536
+ for (let s = n + 1; s < t.length; s++)
1537
+ if (Ma(e, t[s]))
1538
+ return !0;
1539
+ return !1;
1540
+ }
1541
+ function _n(e, ...t) {
1542
+ const { datetimeFormats: n, unresolving: s, fallbackLocale: l, onWarn: a, localeFallbacker: c } = e, { __datetimeFormatters: d } = e, [u, h, O, C] = Pt(...t), k = ie(O.missingWarn) ? O.missingWarn : e.missingWarn;
1543
+ ie(O.fallbackWarn) ? O.fallbackWarn : e.fallbackWarn;
1544
+ const j = !!O.part, W = $t(e, O), R = c(
1545
+ e,
1546
+ // eslint-disable-line @typescript-eslint/no-explicit-any
1547
+ l,
1548
+ W
1549
+ );
1550
+ if (!F(u) || u === "")
1551
+ return new Intl.DateTimeFormat(W, C).format(h);
1552
+ let S = {}, i, m = null;
1553
+ const L = "datetime format";
1554
+ for (let A = 0; A < R.length && (i = R[A], S = n[i] || {}, m = S[u], !H(m)); A++)
1555
+ Jt(e, u, i, k, L);
1556
+ if (!H(m) || !F(i))
1557
+ return s ? bt : u;
1558
+ let p = `${i}__${u}`;
1559
+ pt(C) || (p = `${p}__${JSON.stringify(C)}`);
1560
+ let D = d.get(p);
1561
+ return D || (D = new Intl.DateTimeFormat(i, de({}, m, C)), d.set(p, D)), j ? D.formatToParts(h) : D.format(h);
1562
+ }
1563
+ const Fn = [
1564
+ "localeMatcher",
1565
+ "weekday",
1566
+ "era",
1567
+ "year",
1568
+ "month",
1569
+ "day",
1570
+ "hour",
1571
+ "minute",
1572
+ "second",
1573
+ "timeZoneName",
1574
+ "formatMatcher",
1575
+ "hour12",
1576
+ "timeZone",
1577
+ "dateStyle",
1578
+ "timeStyle",
1579
+ "calendar",
1580
+ "dayPeriod",
1581
+ "numberingSystem",
1582
+ "hourCycle",
1583
+ "fractionalSecondDigits"
1584
+ ];
1585
+ function Pt(...e) {
1586
+ const [t, n, s, l] = e, a = Q();
1587
+ let c = Q(), d;
1588
+ if (F(t)) {
1589
+ const u = t.match(/(\d{4}-\d{2}-\d{2})(T|\s)?(.*)/);
1590
+ if (!u)
1591
+ throw Re(Oe.INVALID_ISO_DATE_ARGUMENT);
1592
+ const h = u[3] ? u[3].trim().startsWith("T") ? `${u[1].trim()}${u[3].trim()}` : `${u[1].trim()}T${u[3].trim()}` : u[1].trim();
1593
+ d = new Date(h);
1594
+ try {
1595
+ d.toISOString();
1596
+ } catch {
1597
+ throw Re(Oe.INVALID_ISO_DATE_ARGUMENT);
1598
+ }
1599
+ } else if (ds(t)) {
1600
+ if (isNaN(t.getTime()))
1601
+ throw Re(Oe.INVALID_DATE_ARGUMENT);
1602
+ d = t;
1603
+ } else if (me(t))
1604
+ d = t;
1605
+ else
1606
+ throw Re(Oe.INVALID_ARGUMENT);
1607
+ return F(n) ? a.key = n : H(n) && Object.keys(n).forEach((u) => {
1608
+ Fn.includes(u) ? c[u] = n[u] : a[u] = n[u];
1609
+ }), F(s) ? a.locale = s : H(s) && (c = s), H(l) && (c = l), [a.key || "", d, a, c];
1610
+ }
1611
+ function pn(e, t, n) {
1612
+ const s = e;
1613
+ for (const l in n) {
1614
+ const a = `${t}__${l}`;
1615
+ s.__datetimeFormatters.has(a) && s.__datetimeFormatters.delete(a);
1616
+ }
1617
+ }
1618
+ function hn(e, ...t) {
1619
+ const { numberFormats: n, unresolving: s, fallbackLocale: l, onWarn: a, localeFallbacker: c } = e, { __numberFormatters: d } = e, [u, h, O, C] = Ft(...t), k = ie(O.missingWarn) ? O.missingWarn : e.missingWarn;
1620
+ ie(O.fallbackWarn) ? O.fallbackWarn : e.fallbackWarn;
1621
+ const j = !!O.part, W = $t(e, O), R = c(
1622
+ e,
1623
+ // eslint-disable-line @typescript-eslint/no-explicit-any
1624
+ l,
1625
+ W
1626
+ );
1627
+ if (!F(u) || u === "")
1628
+ return new Intl.NumberFormat(W, C).format(h);
1629
+ let S = {}, i, m = null;
1630
+ const L = "number format";
1631
+ for (let A = 0; A < R.length && (i = R[A], S = n[i] || {}, m = S[u], !H(m)); A++)
1632
+ Jt(e, u, i, k, L);
1633
+ if (!H(m) || !F(i))
1634
+ return s ? bt : u;
1635
+ let p = `${i}__${u}`;
1636
+ pt(C) || (p = `${p}__${JSON.stringify(C)}`);
1637
+ let D = d.get(p);
1638
+ return D || (D = new Intl.NumberFormat(i, de({}, m, C)), d.set(p, D)), j ? D.formatToParts(h) : D.format(h);
1639
+ }
1640
+ const jn = [
1641
+ "localeMatcher",
1642
+ "style",
1643
+ "currency",
1644
+ "currencyDisplay",
1645
+ "currencySign",
1646
+ "useGrouping",
1647
+ "minimumIntegerDigits",
1648
+ "minimumFractionDigits",
1649
+ "maximumFractionDigits",
1650
+ "minimumSignificantDigits",
1651
+ "maximumSignificantDigits",
1652
+ "compactDisplay",
1653
+ "notation",
1654
+ "signDisplay",
1655
+ "unit",
1656
+ "unitDisplay",
1657
+ "roundingMode",
1658
+ "roundingPriority",
1659
+ "roundingIncrement",
1660
+ "trailingZeroDisplay"
1661
+ ];
1662
+ function Ft(...e) {
1663
+ const [t, n, s, l] = e, a = Q();
1664
+ let c = Q();
1665
+ if (!me(t))
1666
+ throw Re(Oe.INVALID_ARGUMENT);
1667
+ const d = t;
1668
+ return F(n) ? a.key = n : H(n) && Object.keys(n).forEach((u) => {
1669
+ jn.includes(u) ? c[u] = n[u] : a[u] = n[u];
1670
+ }), F(s) ? a.locale = s : H(s) && (c = s), H(l) && (c = l), [a.key || "", d, a, c];
1671
+ }
1672
+ function bn(e, t, n) {
1673
+ const s = e;
1674
+ for (const l in n) {
1675
+ const a = `${t}__${l}`;
1676
+ s.__numberFormatters.has(a) && s.__numberFormatters.delete(a);
1677
+ }
1678
+ }
1679
+ const Pa = (e) => e, Fa = (e) => "", ja = "text", Ua = (e) => e.length === 0 ? "" : Yt(e), Va = hs;
1680
+ function gn(e, t) {
1681
+ return e = Math.abs(e), t === 2 ? e ? e > 1 ? 1 : 0 : 1 : e ? Math.min(e, 2) : 0;
1682
+ }
1683
+ function Ga(e) {
1684
+ const t = me(e.pluralIndex) ? e.pluralIndex : -1;
1685
+ return e.named && (me(e.named.count) || me(e.named.n)) ? me(e.named.count) ? e.named.count : me(e.named.n) ? e.named.n : t : t;
1686
+ }
1687
+ function Wa(e, t) {
1688
+ t.count || (t.count = e), t.n || (t.n = e);
1689
+ }
1690
+ function Za(e = {}) {
1691
+ const t = e.locale, n = Ga(e), s = $(e.pluralRules) && F(t) && re(e.pluralRules[t]) ? e.pluralRules[t] : gn, l = $(e.pluralRules) && F(t) && re(e.pluralRules[t]) ? gn : void 0, a = (i) => i[s(n, i.length, l)], c = e.list || [], d = (i) => c[i], u = e.named || Q();
1692
+ me(e.pluralIndex) && Wa(n, u);
1693
+ const h = (i) => u[i];
1694
+ function O(i, m) {
1695
+ const L = re(e.messages) ? e.messages(i, !!m) : $(e.messages) ? e.messages[i] : !1;
1696
+ return L || (e.parent ? e.parent.message(i) : Fa);
1697
+ }
1698
+ const C = (i) => e.modifiers ? e.modifiers[i] : Pa, k = H(e.processor) && re(e.processor.normalize) ? e.processor.normalize : Ua, j = H(e.processor) && re(e.processor.interpolate) ? e.processor.interpolate : Va, W = H(e.processor) && F(e.processor.type) ? e.processor.type : ja, S = {
1699
+ list: d,
1700
+ named: h,
1701
+ plural: a,
1702
+ linked: (i, ...m) => {
1703
+ const [L, p] = m;
1704
+ let D = "text", A = "";
1705
+ m.length === 1 ? $(L) ? (A = L.modifier || A, D = L.type || D) : F(L) && (A = L || A) : m.length === 2 && (F(L) && (A = L || A), F(p) && (D = p || D));
1706
+ const y = O(i, !0)(S), te = (
1707
+ // The message in vnode resolved with linked are returned as an array by processor.nomalize
1708
+ D === "vnode" && ce(y) && A ? y[0] : y
1709
+ );
1710
+ return A ? C(A)(te, D) : te;
1711
+ },
1712
+ message: O,
1713
+ type: W,
1714
+ interpolate: j,
1715
+ normalize: k,
1716
+ values: de(Q(), c, u)
1717
+ };
1718
+ return S;
1719
+ }
1720
+ const vn = () => "", ge = (e) => re(e);
1721
+ function In(e, ...t) {
1722
+ const { fallbackFormat: n, postTranslation: s, unresolving: l, messageCompiler: a, fallbackLocale: c, messages: d } = e, [u, h] = jt(...t), O = ie(h.missingWarn) ? h.missingWarn : e.missingWarn, C = ie(h.fallbackWarn) ? h.fallbackWarn : e.fallbackWarn, k = ie(h.escapeParameter) ? h.escapeParameter : e.escapeParameter, j = !!h.resolvedMessage, W = F(h.default) || ie(h.default) ? ie(h.default) ? a ? u : () => u : h.default : n ? a ? u : () => u : null, R = n || W != null && (F(W) || re(W)), S = $t(e, h);
1723
+ k && xa(h);
1724
+ let [i, m, L] = j ? [
1725
+ u,
1726
+ S,
1727
+ d[S] || Q()
1728
+ ] : Un(e, u, S, c, C, O), p = i, D = u;
1729
+ if (!j && !(F(p) || Be(p) || ge(p)) && R && (p = W, D = p), !j && (!(F(p) || Be(p) || ge(p)) || !F(m)))
1730
+ return l ? bt : u;
1731
+ let A = !1;
1732
+ const y = () => {
1733
+ A = !0;
1734
+ }, te = ge(p) ? p : Vn(e, u, m, p, D, y);
1735
+ if (A)
1736
+ return p;
1737
+ const T = Ba(e, m, L, h), w = Za(T), U = Xa(e, te, w), f = s ? s(U, u) : U;
1738
+ if (__INTLIFY_PROD_DEVTOOLS__) {
1739
+ const v = {
1740
+ timestamp: Date.now(),
1741
+ key: F(u) ? u : ge(p) ? p.key : "",
1742
+ locale: m || (ge(p) ? p.locale : ""),
1743
+ format: F(p) ? p : ge(p) ? p.source : "",
1744
+ message: f
1745
+ };
1746
+ v.meta = de({}, e.__meta, /* @__PURE__ */ Aa() || {}), ua(v);
1747
+ }
1748
+ return f;
1749
+ }
1750
+ function xa(e) {
1751
+ ce(e.list) ? e.list = e.list.map((t) => F(t) ? tn(t) : t) : $(e.named) && Object.keys(e.named).forEach((t) => {
1752
+ F(e.named[t]) && (e.named[t] = tn(e.named[t]));
1753
+ });
1754
+ }
1755
+ function Un(e, t, n, s, l, a) {
1756
+ const { messages: c, onWarn: d, messageResolver: u, localeFallbacker: h } = e, O = h(e, s, n);
1757
+ let C = Q(), k, j = null;
1758
+ const W = "translate";
1759
+ for (let R = 0; R < O.length && (k = O[R], C = c[k] || Q(), (j = u(C, t)) === null && (j = C[t]), !(F(j) || Be(j) || ge(j))); R++)
1760
+ if (!wa(k, O)) {
1761
+ const S = Jt(
1762
+ e,
1763
+ // eslint-disable-line @typescript-eslint/no-explicit-any
1764
+ t,
1765
+ k,
1766
+ a,
1767
+ W
1768
+ );
1769
+ S !== t && (j = S);
1770
+ }
1771
+ return [j, k, C];
1772
+ }
1773
+ function Vn(e, t, n, s, l, a) {
1774
+ const { messageCompiler: c, warnHtmlMessage: d } = e;
1775
+ if (ge(s)) {
1776
+ const h = s;
1777
+ return h.locale = h.locale || n, h.key = h.key || t, h;
1778
+ }
1779
+ if (c == null) {
1780
+ const h = () => s;
1781
+ return h.locale = n, h.key = t, h;
1782
+ }
1783
+ const u = c(s, Ya(e, n, l, s, d, a));
1784
+ return u.locale = n, u.key = t, u.source = s, u;
1785
+ }
1786
+ function Xa(e, t, n) {
1787
+ return t(n);
1788
+ }
1789
+ function jt(...e) {
1790
+ const [t, n, s] = e, l = Q();
1791
+ if (!F(t) && !me(t) && !ge(t) && !Be(t))
1792
+ throw Re(Oe.INVALID_ARGUMENT);
1793
+ const a = me(t) ? String(t) : (ge(t), t);
1794
+ return me(n) ? l.plural = n : F(n) ? l.default = n : H(n) && !pt(n) ? l.named = n : ce(n) && (l.list = n), me(s) ? l.plural = s : F(s) ? l.default = s : H(s) && de(l, s), [a, l];
1795
+ }
1796
+ function Ya(e, t, n, s, l, a) {
1797
+ return {
1798
+ locale: t,
1799
+ key: n,
1800
+ warnHtmlMessage: l,
1801
+ onError: (c) => {
1802
+ throw a && a(c), c;
1803
+ },
1804
+ onCacheKey: (c) => us(t, n, c)
1805
+ };
1806
+ }
1807
+ function Ba(e, t, n, s) {
1808
+ const { modifiers: l, pluralRules: a, messageResolver: c, fallbackLocale: d, fallbackWarn: u, missingWarn: h, fallbackContext: O } = e, k = {
1809
+ locale: t,
1810
+ modifiers: l,
1811
+ pluralRules: a,
1812
+ messages: (j, W) => {
1813
+ let R = c(n, j);
1814
+ if (R == null && (O || W)) {
1815
+ const [, , S] = Un(
1816
+ O || e,
1817
+ // NOTE: if has fallbackContext, fallback to root, else if use linked, fallback to local context
1818
+ j,
1819
+ t,
1820
+ d,
1821
+ u,
1822
+ h
1823
+ );
1824
+ R = c(S, j);
1825
+ }
1826
+ if (F(R) || Be(R)) {
1827
+ let S = !1;
1828
+ const m = Vn(e, j, t, R, j, () => {
1829
+ S = !0;
1830
+ });
1831
+ return S ? vn : m;
1832
+ } else return ge(R) ? R : vn;
1833
+ }
1834
+ };
1835
+ return e.processor && (k.processor = e.processor), s.list && (k.list = s.list), s.named && (k.named = s.named), me(s.plural) && (k.pluralIndex = s.plural), k;
1836
+ }
1837
+ xs();
1838
+ var Ha = { env: { GITHUB_STATE: "/home/runner/work/_temp/_runner_file_commands/save_state_14ef9f11-46c4-4cfa-a412-d530cc27e26a", npm_package_devDependencies__types_node: "^18.17.17", DOTNET_NOLOGO: "1", npm_package_dependencies_pinia: "^2.1.7", npm_package_devDependencies_vitest: "^1.2.0", USER: "runner", npm_config_always_auth: "", npm_config_user_agent: "pnpm/9.15.9 npm/? node/v24.5.0 linux x64", CI: "true", npm_package_dependencies_vue: "^3.5.16", npm_package_devDependencies_vue_i18n: "10.0.5", USE_BAZEL_FALLBACK_VERSION: "silent:", RUNNER_ENVIRONMENT: "github-hosted", GITHUB_ENV: "/home/runner/work/_temp/_runner_file_commands/set_env_14ef9f11-46c4-4cfa-a412-d530cc27e26a", PIPX_HOME: "/opt/pipx", npm_package_devDependencies_vite: "^5.2.0", npm_node_execpath: "/opt/hostedtoolcache/node/24.5.0/x64/bin/node", JAVA_HOME_8_X64: "/usr/lib/jvm/temurin-8-jdk-amd64", NODE_AUTH_TOKEN: "XXXXX-XXXXX-XXXXX-XXXXX", SHLVL: "1", npm_package_files_0: "dist", npm_package_devDependencies_eslint_import_resolver_typescript: "^4.4.4", HOME: "/home/runner", npm_package_devDependencies__eslint_js: "^9.39.2", npm_package_devDependencies__typescript_eslint_parser: "^8.52.0", RUNNER_TEMP: "/home/runner/work/_temp", GITHUB_EVENT_PATH: "/home/runner/work/_temp/_github_workflow/event.json", npm_package_devDependencies_eslint_config_prettier: "^10.1.8", npm_config_save_workspace_protocol: "true", JAVA_HOME_11_X64: "/usr/lib/jvm/temurin-11-jdk-amd64", PIPX_BIN_DIR: "/opt/pipx_bin", GITHUB_REPOSITORY_OWNER: "feedmepos", NODE_OPTIONS: "--max-old-space-size=10240", GRADLE_HOME: "/usr/share/gradle-9.4.1", ANDROID_NDK_LATEST_HOME: "/usr/local/lib/android/sdk/ndk/29.0.14206865", JAVA_HOME_21_X64: "/usr/lib/jvm/temurin-21-jdk-amd64", GITHUB_RETENTION_DAYS: "90", npm_package_scripts_type_check: "vue-tsc --noEmit -p tsconfig.app.json --composite false", npm_package_dependencies__feedmepos_mf_common: "^1.29.10", npm_package_devDependencies_code_inspector_plugin: "^0.20.16", npm_package_devDependencies_npm_run_all2: "^6.0.6", GITHUB_REPOSITORY_OWNER_ID: "54831515", POWERSHELL_DISTRIBUTION_CHANNEL: "GitHub-Actions-ubuntu24", AZURE_EXTENSION_DIR: "/opt/az/azcliextensions", GITHUB_HEAD_REF: "", npm_config_userconfig: "/home/runner/work/_temp/.npmrc", SYSTEMD_EXEC_PID: "1843", ACTIONS_ORCHESTRATION_ID: "dad72091-aa56-43c3-8503-8e2cfed35846.publish.publish.__default", npm_package_dependencies__feedmepos_ui_library: "^1.7.0", npm_package_dependencies_dayjs: "^1.11.10", npm_package_devDependencies__tsconfig_node18: "^18.2.2", GITHUB_GRAPHQL_URL: "https://api.github.com/graphql", npm_package_scripts_build_only_dev: "VITE_TARGET_ENV=dev pnpm build:mf && pnpm build:dts", npm_package_devDependencies_tailwindcss: "^3.3.3", npm_package_devDependencies_typescript: "^5.9.3", JAVA_HOME_25_X64: "/usr/lib/jvm/temurin-25-jdk-amd64", NVM_DIR: "/home/runner/.nvm", npm_package_dependencies_xlsx: "^0.18.5", npm_package_devDependencies_vue_tsc: "^2.0.6", npm_config_prefer_workspace_packages: "true", DOTNET_SKIP_FIRST_TIME_EXPERIENCE: "1", JAVA_HOME_17_X64: "/usr/lib/jvm/temurin-17-jdk-amd64", ImageVersion: "20260413.86.1", npm_package_scripts_dev: "vite", npm_package_devDependencies_prettier: "^3.7.4", npm_package_devDependencies_sass_embedded: "^1.93.3", LOGNAME: "runner", RUNNER_OS: "Linux", GITHUB_API_URL: "https://api.github.com", GOROOT_1_22_X64: "/opt/hostedtoolcache/go/1.22.12/x64", SWIFT_PATH: "/usr/share/swift/usr/bin", npm_package_type: "module", npm_package_devDependencies__vue_tsconfig: "^0.4.0", npm_package_devDependencies_eslint_plugin_import: "^2.32.0", CHROMEWEBDRIVER: "/usr/local/share/chromedriver-linux64", GOROOT_1_23_X64: "/opt/hostedtoolcache/go/1.23.12/x64", JOURNAL_STREAM: "9:10904", GITHUB_WORKFLOW: "Publish hrm-portal", _: "/home/runner/setup-pnpm/node_modules/.bin/pnpm", npm_package_module: "./dist/app.js", npm_package_devDependencies_autoprefixer: "^10.4.16", MEMORY_PRESSURE_WATCH: "/sys/fs/cgroup/system.slice/hosted-compute-agent.service/memory.pressure", GOROOT_1_24_X64: "/opt/hostedtoolcache/go/1.24.13/x64", npm_package_scripts_lint: "eslint . --ext .vue,.js,.jsx,.cjs,.mjs,.ts,.tsx,.cts,.mts --fix --ignore-path .gitignore", npm_package_devDependencies__typescript_eslint_eslint_plugin: "^8.52.0", npm_config_registry: "https://registry.npmjs.org/", ACTIONS_RUNNER_ACTION_ARCHIVE_CACHE: "/opt/actionarchivecache", GOROOT_1_25_X64: "/opt/hostedtoolcache/go/1.25.9/x64", GITHUB_RUN_ID: "24711539108", GITHUB_REF_TYPE: "branch", BOOTSTRAP_HASKELL_NONINTERACTIVE: "1", GITHUB_WORKFLOW_SHA: "a34b1f6e73a49e22bc704776d0276e8ff95e5c83", GITHUB_BASE_REF: "", ImageOS: "ubuntu24", npm_package_exports___import: "./dist/app.js", npm_package_devDependencies__vitejs_plugin_vue: "^5.0.4", GITHUB_WORKFLOW_REF: "feedmepos/hrm-service/.github/workflows/publish-hrm-portal-trusted.yml@refs/heads/feat/select-all-add-action", ACTIONS_ID_TOKEN_REQUEST_TOKEN: "eyJhbGciOiJSUzI1NiIsImtpZCI6IjM4ODI2YjE3LTZhMzAtNWY5Yi1iMTY5LThiZWI4MjAyZjcyMyIsInR5cCI6IkpXVCIsIng1dCI6InlrTmFZNHFNX3RhNGsyVGdaT0NFWUxrY1lsQSJ9.eyJJZGVudGl0eVR5cGVDbGFpbSI6IlN5c3RlbTpTZXJ2aWNlSWRlbnRpdHkiLCJhYyI6Ilt7XCJTY29wZVwiOlwicmVmcy9oZWFkcy9mZWF0L3NlbGVjdC1hbGwtYWRkLWFjdGlvblwiLFwiUGVybWlzc2lvblwiOjN9LHtcIlNjb3BlXCI6XCJyZWZzL2hlYWRzL21haW5cIixcIlBlcm1pc3Npb25cIjoxfV0iLCJhY3NsIjoiMTAiLCJhdWQiOiJ2c286NmY5NmZhODktYjdiZi00ODc4LWJhZDMtODk4MDA2NTY2YjZlIiwiYmlsbGluZ19vd25lcl9pZCI6IkVfa2dET0FBSm9ZUSIsImV4cCI6MTc3Njc4MTMwMiwiaHR0cDovL3NjaGVtYXMubWljcm9zb2Z0LmNvbS93cy8yMDA4LzA2L2lkZW50aXR5L2NsYWltcy9wcmltYXJ5c2lkIjoiZGRkZGRkZGQtZGRkZC1kZGRkLWRkZGQtZGRkZGRkZGRkZGRkIiwiaHR0cDovL3NjaGVtYXMueG1sc29hcC5vcmcvd3MvMjAwNS8wNS9pZGVudGl0eS9jbGFpbXMvc2lkIjoiZGRkZGRkZGQtZGRkZC1kZGRkLWRkZGQtZGRkZGRkZGRkZGRkIiwiaWF0IjoxNzc2NzU5MTAyLCJpc3MiOiJodHRwczovL3Rva2VuLmFjdGlvbnMuZ2l0aHVidXNlcmNvbnRlbnQuY29tIiwiam9iX2lkIjoiZmRhZmJmMDAtY2M4Zi01NTZlLTk2OTAtNmExZmMwYzgyZmZiIiwibmFtZWlkIjoiZGRkZGRkZGQtZGRkZC1kZGRkLWRkZGQtZGRkZGRkZGRkZGRkIiwibmJmIjoxNzc2NzU4ODAyLCJvaWRjX2V4dHJhIjoie1wiYWN0b3JcIjpcIkNhc3RhLW1lcmVcIixcImFjdG9yX2lkXCI6XCI4MjI5ODAxN1wiLFwiYmFzZV9yZWZcIjpcIlwiLFwiY2hlY2tfcnVuX2lkXCI6XCI3MjI3NzE4MjUzM1wiLFwiZXZlbnRfbmFtZVwiOlwid29ya2Zsb3dfZGlzcGF0Y2hcIixcImhlYWRfcmVmXCI6XCJcIixcImpvYl93b3JrZmxvd19yZWZcIjpcImZlZWRtZXBvcy9hY3Rpb25zLy5naXRodWIvd29ya2Zsb3dzL3B1Ymxpc2gtbnBtLWdpdGh1Yi55YW1sQHJlZnMvaGVhZHMvbWFpblwiLFwiam9iX3dvcmtmbG93X3NoYVwiOlwiYTg0NzUwOGVmMWRhNmJkYWU4ZDBiZjdkOWIxY2E3YzVlYTczMGYzYVwiLFwicmVmXCI6XCJyZWZzL2hlYWRzL2ZlYXQvc2VsZWN0LWFsbC1hZGQtYWN0aW9uXCIsXCJyZWZfcHJvdGVjdGVkXCI6XCJmYWxzZVwiLFwicmVmX3R5cGVcIjpcImJyYW5jaFwiLFwicmVwb3NpdG9yeVwiOlwiZmVlZG1lcG9zL2hybS1zZXJ2aWNlXCIsXCJyZXBvc2l0b3J5X2lkXCI6XCIxMTI0NjcyMjM1XCIsXCJyZXBvc2l0b3J5X293bmVyXCI6XCJmZWVkbWVwb3NcIixcInJlcG9zaXRvcnlfb3duZXJfaWRcIjpcIjU0ODMxNTE1XCIsXCJyZXBvc2l0b3J5X3Zpc2liaWxpdHlcIjpcInByaXZhdGVcIixcInJ1bl9hdHRlbXB0XCI6XCIxXCIsXCJydW5faWRcIjpcIjI0NzExNTM5MTA4XCIsXCJydW5fbnVtYmVyXCI6XCI1NFwiLFwicnVubmVyX2Vudmlyb25tZW50XCI6XCJnaXRodWItaG9zdGVkXCIsXCJzaGFcIjpcImEzNGIxZjZlNzNhNDllMjJiYzcwNDc3NmQwMjc2ZThmZjk1ZTVjODNcIixcIndvcmtmbG93XCI6XCJQdWJsaXNoIGhybS1wb3J0YWxcIixcIndvcmtmbG93X3JlZlwiOlwiZmVlZG1lcG9zL2hybS1zZXJ2aWNlLy5naXRodWIvd29ya2Zsb3dzL3B1Ymxpc2gtaHJtLXBvcnRhbC10cnVzdGVkLnltbEByZWZzL2hlYWRzL2ZlYXQvc2VsZWN0LWFsbC1hZGQtYWN0aW9uXCIsXCJ3b3JrZmxvd19zaGFcIjpcImEzNGIxZjZlNzNhNDllMjJiYzcwNDc3NmQwMjc2ZThmZjk1ZTVjODNcIn0iLCJvaWRjX3N1YiI6InJlcG86ZmVlZG1lcG9zL2hybS1zZXJ2aWNlOnJlZjpyZWZzL2hlYWRzL2ZlYXQvc2VsZWN0LWFsbC1hZGQtYWN0aW9uIiwib3JjaF9pZCI6ImRhZDcyMDkxLWFhNTYtNDNjMy04NTAzLThlMmNmZWQzNTg0Ni5wdWJsaXNoLnB1Ymxpc2guX19kZWZhdWx0Iiwib3duZXJfaWQiOiJFX2tnRE9BQUpvWVEiLCJwbGFuX2lkIjoiZGFkNzIwOTEtYWE1Ni00M2MzLTg1MDMtOGUyY2ZlZDM1ODQ2IiwicmVwb3NpdG9yeV9pZCI6IjExMjQ2NzIyMzUiLCJydW5faWQiOiIyNDcxMTUzOTEwOCIsInJ1bl9udW1iZXIiOiI1NCIsInJ1bl90eXBlIjoiZnVsbCIsInJ1bm5lcl9pZCI6IjEwMDAwNjE5MDIiLCJydW5uZXJfdHlwZSI6Imhvc3RlZCIsInNjcCI6IkFjdGlvbnMuUmVzdWx0czpkYWQ3MjA5MS1hYTU2LTQzYzMtODUwMy04ZTJjZmVkMzU4NDY6ZmRhZmJmMDAtY2M4Zi01NTZlLTk2OTAtNmExZmMwYzgyZmZiIEFjdGlvbnMuUnVubmVyOmRhZDcyMDkxLWFhNTYtNDNjMy04NTAzLThlMmNmZWQzNTg0NjpmZGFmYmYwMC1jYzhmLTU1NmUtOTY5MC02YTFmYzBjODJmZmIgQWN0aW9ucy5VcGxvYWRBcnRpZmFjdHM6ZGFkNzIwOTEtYWE1Ni00M2MzLTg1MDMtOGUyY2ZlZDM1ODQ2OmZkYWZiZjAwLWNjOGYtNTU2ZS05NjkwLTZhMWZjMGM4MmZmYiBnZW5lcmF0ZV9pZF90b2tlbjpkYWQ3MjA5MS1hYTU2LTQzYzMtODUwMy04ZTJjZmVkMzU4NDY6ZmRhZmJmMDAtY2M4Zi01NTZlLTk2OTAtNmExZmMwYzgyZmZiIEFjdGlvbnMuR2VuZXJpY1JlYWQ6MDAwMDAwMDAtMDAwMC0wMDAwLTAwMDAtMDAwMDAwMDAwMDAwIiwic2hhIjoiYTM0YjFmNmU3M2E0OWUyMmJjNzA0Nzc2ZDAyNzZlOGZmOTVlNWM4MyIsInRydXN0X3RpZXIiOiIxIn0.jOzWc2SXGlfKTs32CR9pnDFzJt31UGD_FHLCpZBBYudb6Z5aCHl1V8_Fie0P0VVeLyxmz28GF3VDI70BC9Y9md-xQ9EBSoQUqyfyp-G-0QfOQ0JNUnJH8yS3K54M5GZ-Mhuq096HyigIWIYTtQg_z0dNb6Mmjscc0NgY8gfAO8UxZ8KSVPlKy-4WU4mjnBaglcyrFig4_bfWXG1lw-NNUqHOHnrgVByHNAgY6AsQdEIWdkf46QiNgqDvzhdFuLZktv5614o-eYN6rQWRbwKB633Hzjx5bgCrh034v_9mVDAII4iPXw2QTLZ-0i8J4VOIg609u9hBUtWRoZm3KCYK1w", GITHUB_ACTION_REPOSITORY: "", ENABLE_RUNNER_TRACING: "true", npm_package_dependencies_axios: "^1.7.7", npm_config_node_gyp: "/home/runner/setup-pnpm/node_modules/.pnpm/pnpm@9.15.9/node_modules/pnpm/dist/node_modules/node-gyp/bin/node-gyp.js", PATH: "/home/runner/work/hrm-service/hrm-service/apps/hrm-portal/node_modules/.bin:/home/runner/setup-pnpm/node_modules/.pnpm/pnpm@9.15.9/node_modules/pnpm/dist/node-gyp-bin:/home/runner/work/hrm-service/hrm-service/node_modules/.bin:/home/runner/work/hrm-service/hrm-service/apps/hrm-portal/node_modules/.bin:/home/runner/setup-pnpm/node_modules/.pnpm/pnpm@9.15.9/node_modules/pnpm/dist/node-gyp-bin:/home/runner/work/hrm-service/hrm-service/node_modules/.bin:/home/runner/setup-pnpm/node_modules/.bin:/opt/hostedtoolcache/node/24.5.0/x64/bin:/snap/bin:/home/runner/.local/bin:/opt/pipx_bin:/home/runner/.cargo/bin:/home/runner/.config/composer/vendor/bin:/usr/local/.ghcup/bin:/home/runner/.dotnet/tools:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin", ANT_HOME: "/usr/share/ant", DOTNET_MULTILEVEL_LOOKUP: "0", RUNNER_TRACKING_ID: "github_72a7467b-be49-4430-8759-3d2fbee3cc16", INVOCATION_ID: "7f7f41638259407e849f9d5e5345af29", NPM_CONFIG_USERCONFIG: "/home/runner/work/_temp/.npmrc", RUNNER_TOOL_CACHE: "/opt/hostedtoolcache", NODE: "/opt/hostedtoolcache/node/24.5.0/x64/bin/node", npm_package_name: "@feedmepos/mf-hrm-portal", GITHUB_ACTION: "__run_4", GITHUB_RUN_NUMBER: "54", GITHUB_TRIGGERING_ACTOR: "Casta-mere", RUNNER_ARCH: "X64", XDG_RUNTIME_DIR: "/run/user/1001", AGENT_TOOLSDIRECTORY: "/opt/hostedtoolcache", npm_package_scripts_build_mf: "vite build --mode fmmf", npm_package_scripts_publish_npm: "pnpm build && pnpm publish --registry https://npm.pkg.github.com/ --access public --tag latest --no-git-checks", npm_package_scripts_publish_npm_beta: "pnpm build && pnpm publish --registry https://npm.pkg.github.com/ --access public --tag beta --no-git-checks", npm_package_scripts_publish_github: "pnpm build && pnpm publish --registry https://npm.pkg.github.com/ --tag latest --no-git-checks", npm_package_scripts_publish_github_beta: "pnpm build && pnpm publish --registry https://npm.pkg.github.com/ --tag beta --no-git-checks", npm_config_frozen_lockfile: "", npm_package_devDependencies__vitest_ui: "^1.2.0", LANG: "C.UTF-8", VCPKG_INSTALLATION_ROOT: "/usr/local/share/vcpkg", npm_package_devDependencies__vue_eslint_config_typescript: "^12.0.0", npm_package_devDependencies_eslint: "^9.39.2", CONDA: "/usr/share/miniconda", RUNNER_NAME: "GitHub Actions 1000061902", XDG_CONFIG_HOME: "/home/runner/.config", GITHUB_REF_NAME: "feat/select-all-add-action", GITHUB_REPOSITORY: "feedmepos/hrm-service", npm_package_scripts_build_dts: "vue-tsc --declaration --emitDeclarationOnly -p tsconfig.app.json --outDir ./dist", npm_package_dependencies__feedmepos_core: "^2.14.36", npm_lifecycle_script: "vite build --mode fmmf", ANDROID_NDK_ROOT: "/usr/local/lib/android/sdk/ndk/27.3.13750724", GITHUB_ACTION_REF: "", DEBIAN_FRONTEND: "noninteractive", npm_package_scripts_test: "vitest", npm_package_dependencies_vue3_lottie: "^3.3.0", npm_package_devDependencies__casl_ability: "^3.4.0", npm_package_devDependencies__vitejs_plugin_vue_jsx: "^4.0.0", npm_package_devDependencies__vue_eslint_config_prettier: "^8.0.0", SHELL: "/bin/bash", GITHUB_REPOSITORY_ID: "1124672235", GITHUB_ACTIONS: "true", NODE_PATH: "/home/runner/work/hrm-service/hrm-service/node_modules/.pnpm/vite@5.4.21_@types+node@18.19.130_sass-embedded@1.97.1_sass@1.97.1_terser@5.44.1/node_modules/vite/bin/node_modules:/home/runner/work/hrm-service/hrm-service/node_modules/.pnpm/vite@5.4.21_@types+node@18.19.130_sass-embedded@1.97.1_sass@1.97.1_terser@5.44.1/node_modules/vite/node_modules:/home/runner/work/hrm-service/hrm-service/node_modules/.pnpm/vite@5.4.21_@types+node@18.19.130_sass-embedded@1.97.1_sass@1.97.1_terser@5.44.1/node_modules:/home/runner/work/hrm-service/hrm-service/node_modules/.pnpm/node_modules:/home/runner/setup-pnpm/node_modules/.pnpm/pnpm@9.15.9/node_modules/pnpm/bin/node_modules:/home/runner/setup-pnpm/node_modules/.pnpm/pnpm@9.15.9/node_modules/pnpm/node_modules:/home/runner/setup-pnpm/node_modules/.pnpm/pnpm@9.15.9/node_modules:/home/runner/setup-pnpm/node_modules/.pnpm/node_modules:/home/runner/setup-pnpm/node_modules/.pnpm/pnpm@9.15.9/node_modules/pnpm/bin/node_modules:/home/runner/setup-pnpm/node_modules/.pnpm/pnpm@9.15.9/node_modules/pnpm/node_modules:/home/runner/setup-pnpm/node_modules/.pnpm/pnpm@9.15.9/node_modules:/home/runner/setup-pnpm/node_modules/.pnpm/node_modules", npm_package_version: "2.0.8-dev.1", npm_package_scripts_build_only: "pnpm build:mf && pnpm build:dts", npm_package_dependencies__feedmepos_hrm_permission: "workspace:*", npm_package_devDependencies__rushstack_eslint_patch: "^1.3.3", npm_package_devDependencies_eslint_plugin_unused_imports: "^4.3.0", npm_package_devDependencies_jsdom: "^24.0.0", npm_lifecycle_event: "build:mf", GITHUB_REF_PROTECTED: "false", npm_package_scripts_build: 'run-p type-check "build-only {@}" --', npm_package_dependencies_uuid: "^10.0.0", GITHUB_WORKSPACE: "/home/runner/work/hrm-service/hrm-service", ACCEPT_EULA: "Y", GITHUB_JOB: "publish", npm_package_dependencies_lodash: "^4.17.21", GITHUB_SHA: "a34b1f6e73a49e22bc704776d0276e8ff95e5c83", GITHUB_RUN_ATTEMPT: "1", npm_package_exports___style: "./dist/style.css", npm_package_dependencies_vue_router: "^4.3.2", GITHUB_REF: "refs/heads/feat/select-all-add-action", GITHUB_ACTOR: "Casta-mere", ANDROID_SDK_ROOT: "/usr/local/lib/android/sdk", VITE_TARGET_ENV: "dev", npm_package_devDependencies_globals: "^16.5.0", npm_package_scripts_format: "prettier --write src/", GITHUB_PATH: "/home/runner/work/_temp/_runner_file_commands/add_path_14ef9f11-46c4-4cfa-a412-d530cc27e26a", JAVA_HOME: "/usr/lib/jvm/temurin-17-jdk-amd64", PWD: "/home/runner/work/hrm-service/hrm-service/apps/hrm-portal", GITHUB_ACTOR_ID: "82298017", RUNNER_WORKSPACE: "/home/runner/work/hrm-service", npm_package_devDependencies_vue_eslint_parser: "^10.2.0", npm_config_link_workspace_packages: "true", npm_execpath: "/home/runner/setup-pnpm/node_modules/.pnpm/pnpm@9.15.9/node_modules/pnpm/bin/pnpm.cjs", HOMEBREW_CLEANUP_PERIODIC_FULL_DAYS: "3650", GITHUB_EVENT_NAME: "workflow_dispatch", HOMEBREW_NO_AUTO_UPDATE: "1", ANDROID_HOME: "/usr/local/lib/android/sdk", GITHUB_SERVER_URL: "https://github.com", GECKOWEBDRIVER: "/usr/local/share/gecko_driver", ACTIONS_ID_TOKEN_REQUEST_URL: "https://run-actions-2-azure-eastus.actions.githubusercontent.com/70//idtoken/dad72091-aa56-43c3-8503-8e2cfed35846/fdafbf00-cc8f-556e-9690-6a1fc0c82ffb?api-version=2.0", GHCUP_INSTALL_BASE_PREFIX: "/usr/local", GITHUB_OUTPUT: "/home/runner/work/_temp/_runner_file_commands/set_output_14ef9f11-46c4-4cfa-a412-d530cc27e26a", npm_package_exports___types: "./dist/app.d.ts", npm_package_dependencies__feedmepos_auth: "^1.1.14", npm_package_dependencies__feedmepos_feature_flag: "^0.0.15", EDGEWEBDRIVER: "/usr/local/share/edge_driver", PNPM_SCRIPT_SRC_DIR: "/home/runner/work/hrm-service/hrm-service/apps/hrm-portal", npm_package_devDependencies_eslint_plugin_vue: "^9.33.0", npm_package_devDependencies_postcss: "^8.4.31", npm_command: "run-script", ANDROID_NDK: "/usr/local/lib/android/sdk/ndk/27.3.13750724", SGX_AESM_ADDR: "1", PSModulePath: "/root/.local/share/powershell/Modules:/usr/local/share/powershell/Modules:/opt/microsoft/powershell/7/Modules:/usr/share/az_14.6.0", CHROME_BIN: "/usr/bin/google-chrome", SELENIUM_JAR_PATH: "/usr/share/java/selenium-server.jar", MEMORY_PRESSURE_WRITE: "c29tZSAyMDAwMDAgMjAwMDAwMAA=", PNPM_HOME: "/home/runner/setup-pnpm/node_modules/.bin", ANDROID_NDK_HOME: "/usr/local/lib/android/sdk/ndk/27.3.13750724", GITHUB_STEP_SUMMARY: "/home/runner/work/_temp/_runner_file_commands/step_summary_14ef9f11-46c4-4cfa-a412-d530cc27e26a", INIT_CWD: "/home/runner/work/hrm-service/hrm-service/apps/hrm-portal", npm_package_dependencies_libphonenumber_js: "^1.11.1", NODE_ENV: "production" } };
1839
+ const $a = "10.0.5";
1840
+ function Ja() {
1841
+ typeof __VUE_I18N_FULL_INSTALL__ != "boolean" && (je().__VUE_I18N_FULL_INSTALL__ = !0), typeof __VUE_I18N_LEGACY_API__ != "boolean" && (je().__VUE_I18N_LEGACY_API__ = !0), typeof __INTLIFY_DROP_MESSAGE_COMPILER__ != "boolean" && (je().__INTLIFY_DROP_MESSAGE_COMPILER__ = !1), typeof __INTLIFY_PROD_DEVTOOLS__ != "boolean" && (je().__INTLIFY_PROD_DEVTOOLS__ = !1);
1842
+ }
1843
+ const He = {
1844
+ // composer module errors
1845
+ UNEXPECTED_RETURN_TYPE: da,
1846
+ // 24
1847
+ // legacy module errors
1848
+ INVALID_ARGUMENT: 25,
1849
+ // i18n module errors
1850
+ MUST_BE_CALL_SETUP_TOP: 26,
1851
+ NOT_INSTALLED: 27,
1852
+ NOT_INSTALLED_WITH_PROVIDE: 31,
1853
+ // unexpected error
1854
+ UNEXPECTED_ERROR: 32
1855
+ };
1856
+ function nt(e, ...t) {
1857
+ return ht(e, null, void 0);
1858
+ }
1859
+ const Ut = /* @__PURE__ */ Ve("__translateVNode"), Vt = /* @__PURE__ */ Ve("__datetimeParts"), Gt = /* @__PURE__ */ Ve("__numberParts"), Ka = Ve("__setPluralRules"), Gn = /* @__PURE__ */ Ve("__injectWithOption"), Wt = /* @__PURE__ */ Ve("__dispose");
1860
+ function st(e) {
1861
+ if (!$(e))
1862
+ return e;
1863
+ for (const t in e)
1864
+ if (Ee(e, t))
1865
+ if (!t.includes("."))
1866
+ $(e[t]) && st(e[t]);
1867
+ else {
1868
+ const n = t.split("."), s = n.length - 1;
1869
+ let l = e, a = !1;
1870
+ for (let c = 0; c < s; c++) {
1871
+ if (n[c] in l || (l[n[c]] = Q()), !$(l[n[c]])) {
1872
+ a = !0;
1873
+ break;
1874
+ }
1875
+ l = l[n[c]];
1876
+ }
1877
+ a || (l[n[s]] = e[t], delete e[t]), $(l[n[s]]) && st(l[n[s]]);
1878
+ }
1879
+ return e;
1880
+ }
1881
+ function Wn(e, t) {
1882
+ const { messages: n, __i18n: s, messageResolver: l, flatJson: a } = t, c = H(n) ? n : ce(s) ? Q() : { [e]: Q() };
1883
+ if (ce(s) && s.forEach((d) => {
1884
+ if ("locale" in d && "resource" in d) {
1885
+ const { locale: u, resource: h } = d;
1886
+ u ? (c[u] = c[u] || Q(), mt(h, c[u])) : mt(h, c);
1887
+ } else
1888
+ F(d) && mt(JSON.parse(d), c);
1889
+ }), l == null && a)
1890
+ for (const d in c)
1891
+ Ee(c, d) && st(c[d]);
1892
+ return c;
1893
+ }
1894
+ function Zn(e) {
1895
+ return e.type;
1896
+ }
1897
+ function za(e, t, n) {
1898
+ let s = $(t.messages) ? t.messages : Q();
1899
+ "__i18nGlobal" in n && (s = Wn(e.locale.value, {
1900
+ messages: s,
1901
+ __i18n: n.__i18nGlobal
1902
+ }));
1903
+ const l = Object.keys(s);
1904
+ l.length && l.forEach((a) => {
1905
+ e.mergeLocaleMessage(a, s[a]);
1906
+ });
1907
+ {
1908
+ if ($(t.datetimeFormats)) {
1909
+ const a = Object.keys(t.datetimeFormats);
1910
+ a.length && a.forEach((c) => {
1911
+ e.mergeDateTimeFormat(c, t.datetimeFormats[c]);
1912
+ });
1913
+ }
1914
+ if ($(t.numberFormats)) {
1915
+ const a = Object.keys(t.numberFormats);
1916
+ a.length && a.forEach((c) => {
1917
+ e.mergeNumberFormat(c, t.numberFormats[c]);
1918
+ });
1919
+ }
1920
+ }
1921
+ }
1922
+ function En(e) {
1923
+ return fe($n, null, e, 0);
1924
+ }
1925
+ const Nn = "__INTLIFY_META__", yn = () => [], Qa = () => !1;
1926
+ let Tn = 0;
1927
+ function kn(e) {
1928
+ return (t, n, s, l) => e(n, s, Zt() || void 0, l);
1929
+ }
1930
+ const qa = /* @__NO_SIDE_EFFECTS__ */ () => {
1931
+ const e = Zt();
1932
+ let t = null;
1933
+ return e && (t = Zn(e)[Nn]) ? { [Nn]: t } : null;
1934
+ };
1935
+ function er(e = {}) {
1936
+ const { __root: t, __injectWithOption: n } = e, s = t === void 0, l = e.flatJson, a = qt ? Ue : Hn;
1937
+ let c = ie(e.inheritLocale) ? e.inheritLocale : !0;
1938
+ const d = a(
1939
+ // prettier-ignore
1940
+ t && c ? t.locale.value : F(e.locale) ? e.locale : ft
1941
+ ), u = a(
1942
+ // prettier-ignore
1943
+ t && c ? t.fallbackLocale.value : F(e.fallbackLocale) || ce(e.fallbackLocale) || H(e.fallbackLocale) || e.fallbackLocale === !1 ? e.fallbackLocale : d.value
1944
+ ), h = a(Wn(d.value, e)), O = a(H(e.datetimeFormats) ? e.datetimeFormats : { [d.value]: {} }), C = a(H(e.numberFormats) ? e.numberFormats : { [d.value]: {} });
1945
+ let k = t ? t.missingWarn : ie(e.missingWarn) || dt(e.missingWarn) ? e.missingWarn : !0, j = t ? t.fallbackWarn : ie(e.fallbackWarn) || dt(e.fallbackWarn) ? e.fallbackWarn : !0, W = t ? t.fallbackRoot : ie(e.fallbackRoot) ? e.fallbackRoot : !0, R = !!e.fallbackFormat, S = re(e.missing) ? e.missing : null, i = re(e.missing) ? kn(e.missing) : null, m = re(e.postTranslation) ? e.postTranslation : null, L = t ? t.warnHtmlMessage : ie(e.warnHtmlMessage) ? e.warnHtmlMessage : !0, p = !!e.escapeParameter;
1946
+ const D = t ? t.modifiers : H(e.modifiers) ? e.modifiers : {};
1947
+ let A = e.pluralRules || t && t.pluralRules, y;
1948
+ y = (() => {
1949
+ s && dn(null);
1950
+ const _ = {
1951
+ version: $a,
1952
+ locale: d.value,
1953
+ fallbackLocale: u.value,
1954
+ messages: h.value,
1955
+ modifiers: D,
1956
+ pluralRules: A,
1957
+ missing: i === null ? void 0 : i,
1958
+ missingWarn: k,
1959
+ fallbackWarn: j,
1960
+ fallbackFormat: R,
1961
+ unresolving: !0,
1962
+ postTranslation: m === null ? void 0 : m,
1963
+ warnHtmlMessage: L,
1964
+ escapeParameter: p,
1965
+ messageResolver: e.messageResolver,
1966
+ messageCompiler: e.messageCompiler,
1967
+ __meta: { framework: "vue" }
1968
+ };
1969
+ _.datetimeFormats = O.value, _.numberFormats = C.value, _.__datetimeFormatters = H(y) ? y.__datetimeFormatters : void 0, _.__numberFormatters = H(y) ? y.__numberFormatters : void 0;
1970
+ const N = Da(_);
1971
+ return s && dn(N), N;
1972
+ })(), Qe(y, d.value, u.value);
1973
+ function T() {
1974
+ return [
1975
+ d.value,
1976
+ u.value,
1977
+ h.value,
1978
+ O.value,
1979
+ C.value
1980
+ ];
1981
+ }
1982
+ const w = ee({
1983
+ get: () => d.value,
1984
+ set: (_) => {
1985
+ d.value = _, y.locale = d.value;
1986
+ }
1987
+ }), U = ee({
1988
+ get: () => u.value,
1989
+ set: (_) => {
1990
+ u.value = _, y.fallbackLocale = u.value, Qe(y, d.value, _);
1991
+ }
1992
+ }), f = ee(() => h.value), v = /* @__PURE__ */ ee(() => O.value), X = /* @__PURE__ */ ee(() => C.value);
1993
+ function b() {
1994
+ return re(m) ? m : null;
1995
+ }
1996
+ function E(_) {
1997
+ m = _, y.postTranslation = _;
1998
+ }
1999
+ function I() {
2000
+ return S;
2001
+ }
2002
+ function V(_) {
2003
+ _ !== null && (i = kn(_)), S = _, y.missing = i;
2004
+ }
2005
+ const P = (_, N, q, oe, Pe, at) => {
2006
+ T();
2007
+ let Ze;
2008
+ try {
2009
+ Ha.env.NODE_ENV !== "production" || __INTLIFY_PROD_DEVTOOLS__, s || (y.fallbackContext = t ? Sa() : void 0), Ze = _(y);
2010
+ } finally {
2011
+ __INTLIFY_PROD_DEVTOOLS__, s || (y.fallbackContext = void 0);
2012
+ }
2013
+ if (q !== "translate exists" && // for not `te` (e.g `t`)
2014
+ me(Ze) && Ze === bt || q === "translate exists" && !Ze) {
2015
+ const [Yn, Zr] = N();
2016
+ return t && W ? oe(t) : Pe(Yn);
2017
+ } else {
2018
+ if (at(Ze))
2019
+ return Ze;
2020
+ throw nt(He.UNEXPECTED_RETURN_TYPE);
2021
+ }
2022
+ };
2023
+ function M(..._) {
2024
+ return P((N) => Reflect.apply(In, null, [N, ..._]), () => jt(..._), "translate", (N) => Reflect.apply(N.t, N, [..._]), (N) => N, (N) => F(N));
2025
+ }
2026
+ function J(..._) {
2027
+ const [N, q, oe] = _;
2028
+ if (oe && !$(oe))
2029
+ throw nt(He.INVALID_ARGUMENT);
2030
+ return M(N, q, de({ resolvedMessage: !0 }, oe || {}));
2031
+ }
2032
+ function B(..._) {
2033
+ return P((N) => Reflect.apply(_n, null, [N, ..._]), () => Pt(..._), "datetime format", (N) => Reflect.apply(N.d, N, [..._]), () => un, (N) => F(N));
2034
+ }
2035
+ function Z(..._) {
2036
+ return P((N) => Reflect.apply(hn, null, [N, ..._]), () => Ft(..._), "number format", (N) => Reflect.apply(N.n, N, [..._]), () => un, (N) => F(N));
2037
+ }
2038
+ function K(_) {
2039
+ return _.map((N) => F(N) || me(N) || ie(N) ? En(String(N)) : N);
2040
+ }
2041
+ const ae = {
2042
+ normalize: K,
2043
+ interpolate: (_) => _,
2044
+ type: "vnode"
2045
+ };
2046
+ function ve(..._) {
2047
+ return P((N) => {
2048
+ let q;
2049
+ const oe = N;
2050
+ try {
2051
+ oe.processor = ae, q = Reflect.apply(In, null, [oe, ..._]);
2052
+ } finally {
2053
+ oe.processor = null;
2054
+ }
2055
+ return q;
2056
+ }, () => jt(..._), "translate", (N) => N[Ut](..._), (N) => [En(N)], (N) => ce(N));
2057
+ }
2058
+ function $e(..._) {
2059
+ return P((N) => Reflect.apply(hn, null, [N, ..._]), () => Ft(..._), "number format", (N) => N[Gt](..._), yn, (N) => F(N) || ce(N));
2060
+ }
2061
+ function Je(..._) {
2062
+ return P((N) => Reflect.apply(_n, null, [N, ..._]), () => Pt(..._), "datetime format", (N) => N[Vt](..._), yn, (N) => F(N) || ce(N));
2063
+ }
2064
+ function vt(_) {
2065
+ A = _, y.pluralRules = A;
2066
+ }
2067
+ function It(_, N) {
2068
+ return P(() => {
2069
+ if (!_)
2070
+ return !1;
2071
+ const q = F(N) ? N : d.value, oe = Ge(q), Pe = y.messageResolver(oe, _);
2072
+ return Be(Pe) || ge(Pe) || F(Pe);
2073
+ }, () => [_], "translate exists", (q) => Reflect.apply(q.te, q, [_, N]), Qa, (q) => ie(q));
2074
+ }
2075
+ function Et(_) {
2076
+ let N = null;
2077
+ const q = An(y, u.value, d.value);
2078
+ for (let oe = 0; oe < q.length; oe++) {
2079
+ const Pe = h.value[q[oe]] || {}, at = y.messageResolver(Pe, _);
2080
+ if (at != null) {
2081
+ N = at;
2082
+ break;
2083
+ }
2084
+ }
2085
+ return N;
2086
+ }
2087
+ function Ke(_) {
2088
+ const N = Et(_);
2089
+ return N ?? (t ? t.tm(_) || {} : {});
2090
+ }
2091
+ function Ge(_) {
2092
+ return h.value[_] || {};
2093
+ }
2094
+ function We(_, N) {
2095
+ if (l) {
2096
+ const q = { [_]: N };
2097
+ for (const oe in q)
2098
+ Ee(q, oe) && st(q[oe]);
2099
+ N = q[_];
2100
+ }
2101
+ h.value[_] = N, y.messages = h.value;
2102
+ }
2103
+ function ze(_, N) {
2104
+ h.value[_] = h.value[_] || {};
2105
+ const q = { [_]: N };
2106
+ if (l)
2107
+ for (const oe in q)
2108
+ Ee(q, oe) && st(q[oe]);
2109
+ N = q[_], mt(N, h.value[_]), y.messages = h.value;
2110
+ }
2111
+ function Nt(_) {
2112
+ return O.value[_] || {};
2113
+ }
2114
+ function r(_, N) {
2115
+ O.value[_] = N, y.datetimeFormats = O.value, pn(y, _, N);
2116
+ }
2117
+ function o(_, N) {
2118
+ O.value[_] = de(O.value[_] || {}, N), y.datetimeFormats = O.value, pn(y, _, N);
2119
+ }
2120
+ function g(_) {
2121
+ return C.value[_] || {};
2122
+ }
2123
+ function G(_, N) {
2124
+ C.value[_] = N, y.numberFormats = C.value, bn(y, _, N);
2125
+ }
2126
+ function le(_, N) {
2127
+ C.value[_] = de(C.value[_] || {}, N), y.numberFormats = C.value, bn(y, _, N);
2128
+ }
2129
+ Tn++, t && qt && (St(t.locale, (_) => {
2130
+ c && (d.value = _, y.locale = _, Qe(y, d.value, u.value));
2131
+ }), St(t.fallbackLocale, (_) => {
2132
+ c && (u.value = _, y.fallbackLocale = _, Qe(y, d.value, u.value));
2133
+ }));
2134
+ const x = {
2135
+ id: Tn,
2136
+ locale: w,
2137
+ fallbackLocale: U,
2138
+ get inheritLocale() {
2139
+ return c;
2140
+ },
2141
+ set inheritLocale(_) {
2142
+ c = _, _ && t && (d.value = t.locale.value, u.value = t.fallbackLocale.value, Qe(y, d.value, u.value));
2143
+ },
2144
+ get availableLocales() {
2145
+ return Object.keys(h.value).sort();
2146
+ },
2147
+ messages: f,
2148
+ get modifiers() {
2149
+ return D;
2150
+ },
2151
+ get pluralRules() {
2152
+ return A || {};
2153
+ },
2154
+ get isGlobal() {
2155
+ return s;
2156
+ },
2157
+ get missingWarn() {
2158
+ return k;
2159
+ },
2160
+ set missingWarn(_) {
2161
+ k = _, y.missingWarn = k;
2162
+ },
2163
+ get fallbackWarn() {
2164
+ return j;
2165
+ },
2166
+ set fallbackWarn(_) {
2167
+ j = _, y.fallbackWarn = j;
2168
+ },
2169
+ get fallbackRoot() {
2170
+ return W;
2171
+ },
2172
+ set fallbackRoot(_) {
2173
+ W = _;
2174
+ },
2175
+ get fallbackFormat() {
2176
+ return R;
2177
+ },
2178
+ set fallbackFormat(_) {
2179
+ R = _, y.fallbackFormat = R;
2180
+ },
2181
+ get warnHtmlMessage() {
2182
+ return L;
2183
+ },
2184
+ set warnHtmlMessage(_) {
2185
+ L = _, y.warnHtmlMessage = _;
2186
+ },
2187
+ get escapeParameter() {
2188
+ return p;
2189
+ },
2190
+ set escapeParameter(_) {
2191
+ p = _, y.escapeParameter = _;
2192
+ },
2193
+ t: M,
2194
+ getLocaleMessage: Ge,
2195
+ setLocaleMessage: We,
2196
+ mergeLocaleMessage: ze,
2197
+ getPostTranslationHandler: b,
2198
+ setPostTranslationHandler: E,
2199
+ getMissingHandler: I,
2200
+ setMissingHandler: V,
2201
+ [Ka]: vt
2202
+ };
2203
+ return x.datetimeFormats = v, x.numberFormats = X, x.rt = J, x.te = It, x.tm = Ke, x.d = B, x.n = Z, x.getDateTimeFormat = Nt, x.setDateTimeFormat = r, x.mergeDateTimeFormat = o, x.getNumberFormat = g, x.setNumberFormat = G, x.mergeNumberFormat = le, x[Gn] = n, x[Ut] = ve, x[Vt] = Je, x[Gt] = $e, x;
2204
+ }
2205
+ const Kt = {
2206
+ tag: {
2207
+ type: [String, Object]
2208
+ },
2209
+ locale: {
2210
+ type: String
2211
+ },
2212
+ scope: {
2213
+ type: String,
2214
+ // NOTE: avoid https://github.com/microsoft/rushstack/issues/1050
2215
+ validator: (e) => e === "parent" || e === "global",
2216
+ default: "parent"
2217
+ /* ComponentI18nScope */
2218
+ },
2219
+ i18n: {
2220
+ type: Object
2221
+ }
2222
+ };
2223
+ function tr({ slots: e }, t) {
2224
+ return t.length === 1 && t[0] === "default" ? (e.default ? e.default() : []).reduce((s, l) => [
2225
+ ...s,
2226
+ // prettier-ignore
2227
+ ...l.type === Ie ? l.children : [l]
2228
+ ], []) : t.reduce((n, s) => {
2229
+ const l = e[s];
2230
+ return l && (n[s] = l()), n;
2231
+ }, Q());
2232
+ }
2233
+ function xn() {
2234
+ return Ie;
2235
+ }
2236
+ de({
2237
+ keypath: {
2238
+ type: String,
2239
+ required: !0
2240
+ },
2241
+ plural: {
2242
+ type: [Number, String],
2243
+ validator: (e) => me(e) || !isNaN(e)
2244
+ }
2245
+ }, Kt);
2246
+ function nr(e) {
2247
+ return ce(e) && !F(e[0]);
2248
+ }
2249
+ function Xn(e, t, n, s) {
2250
+ const { slots: l, attrs: a } = t;
2251
+ return () => {
2252
+ const c = { part: !0 };
2253
+ let d = Q();
2254
+ e.locale && (c.locale = e.locale), F(e.format) ? c.key = e.format : $(e.format) && (F(e.format.key) && (c.key = e.format.key), d = Object.keys(e.format).reduce((k, j) => n.includes(j) ? de(Q(), k, { [j]: e.format[j] }) : k, Q()));
2255
+ const u = s(e.value, c, d);
2256
+ let h = [c.key];
2257
+ ce(u) ? h = u.map((k, j) => {
2258
+ const W = l[k.type], R = W ? W({ [k.type]: k.value, index: j, parts: u }) : [k.value];
2259
+ return nr(R) && (R[0].key = `${k.type}-${j}`), R;
2260
+ }) : F(u) && (h = [u]);
2261
+ const O = de(Q(), a), C = F(e.tag) || $(e.tag) ? e.tag : xn();
2262
+ return Rn(C, O, h);
2263
+ };
2264
+ }
2265
+ de({
2266
+ value: {
2267
+ type: Number,
2268
+ required: !0
2269
+ },
2270
+ format: {
2271
+ type: [String, Object]
2272
+ }
2273
+ }, Kt);
2274
+ de({
2275
+ value: {
2276
+ type: [Number, Date],
2277
+ required: !0
2278
+ },
2279
+ format: {
2280
+ type: [String, Object]
2281
+ }
2282
+ }, Kt);
2283
+ const sr = /* @__PURE__ */ Ve("global-vue-i18n");
2284
+ function gt(e = {}) {
2285
+ const t = Zt();
2286
+ if (t == null)
2287
+ throw nt(He.MUST_BE_CALL_SETUP_TOP);
2288
+ if (!t.isCE && t.appContext.app != null && !t.appContext.app.__VUE_I18N_SYMBOL__)
2289
+ throw nt(He.NOT_INSTALLED);
2290
+ const n = ar(t), s = lr(n), l = Zn(t), a = rr(e, l);
2291
+ if (a === "global")
2292
+ return za(s, e, l), s;
2293
+ if (a === "parent") {
2294
+ let u = or(n, t, e.__useComponent);
2295
+ return u == null && (u = s), u;
2296
+ }
2297
+ const c = n;
2298
+ let d = c.__getInstance(t);
2299
+ if (d == null) {
2300
+ const u = de({}, e);
2301
+ "__i18n" in l && (u.__i18n = l.__i18n), s && (u.__root = s), d = er(u), c.__composerExtend && (d[Wt] = c.__composerExtend(d)), cr(c, t, d), c.__setInstance(t, d);
2302
+ }
2303
+ return d;
2304
+ }
2305
+ function ar(e) {
2306
+ const t = Bn(e.isCE ? sr : e.appContext.app.__VUE_I18N_SYMBOL__);
2307
+ if (!t)
2308
+ throw nt(e.isCE ? He.NOT_INSTALLED_WITH_PROVIDE : He.UNEXPECTED_ERROR);
2309
+ return t;
2310
+ }
2311
+ function rr(e, t) {
2312
+ return pt(e) ? "__i18n" in t ? "local" : "global" : e.useScope ? e.useScope : "local";
2313
+ }
2314
+ function lr(e) {
2315
+ return e.mode === "composition" ? e.global : e.global.__composer;
2316
+ }
2317
+ function or(e, t, n = !1) {
2318
+ let s = null;
2319
+ const l = t.root;
2320
+ let a = ir(t, n);
2321
+ for (; a != null; ) {
2322
+ const c = e;
2323
+ if (e.mode === "composition")
2324
+ s = c.__getInstance(a);
2325
+ else if (__VUE_I18N_LEGACY_API__) {
2326
+ const d = c.__getInstance(a);
2327
+ d != null && (s = d.__composer, n && s && !s[Gn] && (s = null));
2328
+ }
2329
+ if (s != null || l === a)
2330
+ break;
2331
+ a = a.parent;
2332
+ }
2333
+ return s;
2334
+ }
2335
+ function ir(e, t = !1) {
2336
+ return e == null ? null : t && e.vnode.ctx || e.parent;
2337
+ }
2338
+ function cr(e, t, n) {
2339
+ xt(() => {
2340
+ }, t), On(() => {
2341
+ const s = n;
2342
+ e.__deleteInstance(t);
2343
+ const l = s[Wt];
2344
+ l && (l(), delete s[Wt]);
2345
+ }, t);
2346
+ }
2347
+ Ja();
2348
+ La(oa);
2349
+ Oa(ya);
2350
+ Ra(An);
2351
+ if (__INTLIFY_PROD_DEVTOOLS__) {
2352
+ const e = je();
2353
+ e.__INTLIFY__ = !0, ia(e.__INTLIFY_DEVTOOLS_GLOBAL_HOOK__);
2354
+ }
2355
+ const it = /* @__PURE__ */ Ne({
2356
+ __name: "InheritPermissionTooltip",
2357
+ props: {
2358
+ item: {
2359
+ type: Object,
2360
+ required: !0
2361
+ }
2362
+ },
2363
+ setup(e) {
2364
+ const { t } = gt();
2365
+ return (n, s) => {
2366
+ const l = Xe("FmIcon"), a = Xe("FmTooltip");
2367
+ return Y(), Se(a, {
2368
+ variant: "plain",
2369
+ placement: "right",
2370
+ "z-index": 50
2371
+ }, {
2372
+ content: he(() => [
2373
+ se("div", null, Ae(Te(t)("team.memberForm.permissions.inherited")), 1),
2374
+ (Y(!0), ne(Ie, null, pe(e.item.setNames, (c) => (Y(), ne("div", { key: c }, [
2375
+ se("div", null, "- " + Ae(c), 1)
2376
+ ]))), 128))
2377
+ ]),
2378
+ default: he(() => [
2379
+ fe(l, {
2380
+ name: "admin_panel_settings",
2381
+ size: "sm",
2382
+ class: "ml-1 text-fm-color-typo-info"
2383
+ })
2384
+ ]),
2385
+ _: 1
2386
+ });
2387
+ };
2388
+ }
2389
+ }), ur = { class: "space-y-16" }, mr = {
2390
+ key: 0,
2391
+ class: "flex fm-typo-en-title-sm-600"
2392
+ }, dr = {
2393
+ key: 0,
2394
+ class: "q-mr-xs text-red col"
2395
+ }, fr = { class: "form-input" }, _r = /* @__PURE__ */ Ne({
2396
+ __name: "AppForm",
2397
+ props: {
2398
+ title: {
2399
+ type: String,
2400
+ default: void 0
2401
+ },
2402
+ required: {
2403
+ type: [Boolean, String],
2404
+ default: !1
2405
+ },
2406
+ inline: {
2407
+ type: Boolean,
2408
+ default: !1
2409
+ }
2410
+ },
2411
+ setup(e) {
2412
+ const t = e;
2413
+ return (n, s) => (Y(), ne("div", ur, [
2414
+ be(n.$slots, "top", {}, () => [
2415
+ t.title ? (Y(), ne("div", mr, [
2416
+ se("div", null, [
2417
+ t.required ? (Y(), ne("span", dr, "*")) : Le("", !0),
2418
+ Jn(Ae(t.title), 1)
2419
+ ]),
2420
+ be(n.$slots, "title-right")
2421
+ ])) : Le("", !0)
2422
+ ]),
2423
+ se("div", fr, [
2424
+ be(n.$slots, "default")
2425
+ ])
2426
+ ]));
2427
+ }
2428
+ });
2429
+ function pr(e, t) {
2430
+ let n = "", s = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";
2431
+ const l = s.length;
2432
+ for (let a = 0; a < e; a++)
2433
+ n += s.charAt(Math.floor(Math.random() * l));
2434
+ return n;
2435
+ }
2436
+ const hr = { class: "col flex items-center" }, br = {
2437
+ key: 1,
2438
+ class: "q-pa-sm form-error-message text-error"
2439
+ }, zt = /* @__PURE__ */ Ne({
2440
+ __name: "CheckboxInput",
2441
+ props: {
2442
+ options: {
2443
+ type: Array,
2444
+ required: !0
2445
+ },
2446
+ title: {
2447
+ type: String,
2448
+ required: !0
2449
+ },
2450
+ modelValue: {
2451
+ type: Array,
2452
+ required: !0
2453
+ },
2454
+ showAllToggle: {
2455
+ type: [Boolean, String],
2456
+ default: !0
2457
+ },
2458
+ includeDisabledOptionsWhenSelectAll: {
2459
+ type: Boolean,
2460
+ default: !1
2461
+ },
2462
+ disable: {
2463
+ type: Boolean,
2464
+ default: !1
2465
+ },
2466
+ min: {
2467
+ type: Number,
2468
+ default: 0
2469
+ },
2470
+ max: {
2471
+ type: Number,
2472
+ default: void 0
2473
+ },
2474
+ showIntermediate: {
2475
+ type: Boolean,
2476
+ default: !0
2477
+ },
2478
+ gutter: {
2479
+ type: Number,
2480
+ default: void 0
2481
+ },
2482
+ falsyShowSlot: {
2483
+ type: Boolean,
2484
+ default: !1
2485
+ },
2486
+ bottomSlotIndent: {
2487
+ type: String,
2488
+ default: "36px"
2489
+ },
2490
+ alignCenter: {
2491
+ type: Boolean,
2492
+ default: !0
2493
+ }
2494
+ },
2495
+ emits: ["update:model-value"],
2496
+ setup(e, { emit: t }) {
2497
+ const n = e, s = t, { t: l } = _t(), a = Ue(!1), c = Kn(), d = ee(() => n.modelValue.length < n.min ? `Min selection ${n.min}` : n.max !== void 0 && n.modelValue.length > n.max ? `Max selection ${n.max}` : !0), u = `checkbox-${pr(6)}`, h = ee(() => d.value !== !0), O = ee(
2498
+ () => n.modelValue.filter((R) => n.options.some((S) => S.value === R))
2499
+ ), C = ee(
2500
+ () => typeof n.showAllToggle == "boolean" ? l("team.labels.all") : n.showAllToggle
2501
+ ), k = ee(() => n.options.length > 0 && n.options.length === O.value.length);
2502
+ function j() {
2503
+ const R = n.modelValue.filter((S) => !O.value.includes(S));
2504
+ if (k.value === !0)
2505
+ s("update:model-value", R);
2506
+ else {
2507
+ const S = n.includeDisabledOptionsWhenSelectAll ? n.options.map((i) => i.value) : n.options.filter((i) => !i.disabled).map((i) => i.value);
2508
+ s("update:model-value", [...R, ...S]);
2509
+ }
2510
+ }
2511
+ function W(R, S) {
2512
+ let i = ut(n.modelValue);
2513
+ S ? i.every((m) => m !== R) && i.push(R) : i = i.filter((m) => m !== R), s("update:model-value", i);
2514
+ }
2515
+ return (R, S) => {
2516
+ const i = Xe("FmCheckbox");
2517
+ return Y(), Se(_r, {
2518
+ id: u,
2519
+ title: e.title,
2520
+ required: !1
2521
+ }, {
2522
+ top: he(() => [
2523
+ be(R.$slots, "top")
2524
+ ]),
2525
+ default: he(() => [
2526
+ n.showAllToggle ? (Y(), Se(i, {
2527
+ key: 0,
2528
+ "model-value": k.value,
2529
+ disabled: e.disable,
2530
+ label: C.value,
2531
+ style: ct(`margin-bottom: ${n.gutter}px`),
2532
+ size: "sm",
2533
+ dense: "",
2534
+ value: C.value,
2535
+ "onUpdate:modelValue": j
2536
+ }, null, 8, ["model-value", "disabled", "label", "style", "value"])) : Le("", !0),
2537
+ (Y(!0), ne(Ie, null, pe(e.options, (m, L) => (Y(), ne("div", {
2538
+ key: m.value,
2539
+ style: ct(`margin-bottom: ${L < e.options.length - 1 ? n.gutter : 0}px`),
2540
+ class: qe(L < e.options.length - 1 ? "q-mb-sm" : "")
2541
+ }, [
2542
+ se("div", {
2543
+ class: qe(["row justify-between", e.alignCenter ? "items-center" : "items-start"])
2544
+ }, [
2545
+ se("div", hr, [
2546
+ fe(i, {
2547
+ "model-value": e.modelValue.includes(m.value),
2548
+ disabled: e.disable || m.disabled,
2549
+ size: "sm",
2550
+ label: m.label,
2551
+ value: m.label,
2552
+ "onUpdate:modelValue": (p) => W(m.value, p)
2553
+ }, null, 8, ["model-value", "disabled", "label", "value", "onUpdate:modelValue"]),
2554
+ be(R.$slots, `checkbox-${m.key || m.value}-append`, {
2555
+ option: m,
2556
+ selected: e.modelValue.includes(m.value)
2557
+ })
2558
+ ]),
2559
+ Te(c)[`checkbox-${m.key || m.value}-end`] && (e.modelValue.includes(m.value) || e.falsyShowSlot) ? (Y(), ne("div", {
2560
+ key: 0,
2561
+ class: qe([{ "q-checkbox disabled": e.disable || m.disabled }, "col"])
2562
+ }, [
2563
+ be(R.$slots, `checkbox-${m.key || m.value}-end`, {
2564
+ option: m,
2565
+ value: e.modelValue.includes(m.value),
2566
+ disable: e.disable || m.disabled
2567
+ })
2568
+ ], 2)) : Le("", !0)
2569
+ ], 2),
2570
+ Te(c)[`checkbox-${m.key || m.value}-bottom`] && (e.modelValue.includes(m.value) || e.falsyShowSlot) ? (Y(), ne("div", {
2571
+ key: 0,
2572
+ class: qe(["q-mt-sm", { "q-checkbox disabled": e.disable || m.disabled }]),
2573
+ style: ct(`margin-left: ${e.bottomSlotIndent}`)
2574
+ }, [
2575
+ be(R.$slots, `checkbox-${m.key || m.value}-bottom`, {
2576
+ option: m,
2577
+ disable: e.disable || m.disabled,
2578
+ value: e.modelValue.includes(m.value)
2579
+ })
2580
+ ], 6)) : Le("", !0)
2581
+ ], 6))), 128)),
2582
+ a.value && h.value ? (Y(), ne("div", br, Ae(d.value), 1)) : Le("", !0)
2583
+ ]),
2584
+ _: 3
2585
+ }, 8, ["title"]);
2586
+ };
2587
+ }
2588
+ }), gr = { class: "flex flex-col gap-16" }, vr = {
2589
+ key: 1,
2590
+ class: "space-y-16"
2591
+ }, Ir = { class: "flex items-end justify-between" }, Er = { class: "fm-typo-en-title-sm-600" }, Nr = { class: "flex" }, yr = { class: "form-input" }, Tr = { class: "flex items-center justify-between q-mb-xs" }, kr = { class: "flex shrink-0" }, Lr = { class: "flex items-center justify-between gap-4" }, Or = { class: "flex items-center min-w-0 flex-1 gap-8" }, Rr = ["title", "onClick"], Cr = {
2592
+ key: 0,
2593
+ class: "flex shrink-0"
2594
+ }, Ar = /* @__PURE__ */ Ne({
2595
+ __name: "BasePermission",
2596
+ props: {
2597
+ modelValue: {
2598
+ type: Array,
2599
+ required: !0
2600
+ },
2601
+ disable: {
2602
+ type: Boolean,
2603
+ default: !1
2604
+ },
2605
+ excludedSubjects: {
2606
+ type: Array,
2607
+ required: !0
2608
+ },
2609
+ additionalPermissions: {
2610
+ type: Array,
2611
+ default: () => []
2612
+ }
2613
+ },
2614
+ emits: ["update:model-value"],
2615
+ setup(e, { emit: t }) {
2616
+ const { getFlagValue: n } = is(), s = e, l = ee(() => [...Dt, ...s.additionalPermissions]), a = t, c = Object.values(ls), d = ee(() => {
2617
+ const T = /* @__PURE__ */ new Map(), w = /* @__PURE__ */ new Map();
2618
+ for (const f of l.value) {
2619
+ const v = f.category;
2620
+ v && (s.excludedSubjects.includes(f.subject) || f.showByFeatureFlag && n(f.showByFeatureFlag) === "false" || (T.has(v) || T.set(v, []), T.get(v).push({ label: f.label, value: f.subject }), w.set(f.subject, f)));
2621
+ }
2622
+ return [...T.keys()].sort((f, v) => {
2623
+ const X = c.indexOf(f), b = c.indexOf(v);
2624
+ return X === -1 && b === -1 ? f.localeCompare(v) : X === -1 ? 1 : b === -1 ? -1 : X - b;
2625
+ }).map((f) => {
2626
+ const v = T.get(f), X = /* @__PURE__ */ new Map();
2627
+ for (const Z of v) {
2628
+ const K = w.get(Z.value);
2629
+ K && X.set(Z.value, K.actions);
2630
+ }
2631
+ const b = v.some((Z) => {
2632
+ const K = X.get(Z.value);
2633
+ return K && K.length > 1;
2634
+ }), E = b ? [
2635
+ ...new Set(
2636
+ v.flatMap((Z) => X.get(Z.value) ?? []).filter((Z) => Z !== "manage")
2637
+ )
2638
+ ] : [], I = /* @__PURE__ */ new Map();
2639
+ for (const Z of s.modelValue)
2640
+ v.some((K) => K.value === Z.subject) && !Z.inverted && I.set(Z.subject, new Set(Z.actions));
2641
+ const V = b ? s.modelValue.filter(
2642
+ (Z) => v.some((K) => K.value === Z.subject) && !Z.inverted && Z.actions.includes("manage")
2643
+ ).map((Z) => Z.subject) : s.modelValue.filter((Z) => v.some((K) => K.value === Z.subject) && !Z.inverted).map((Z) => Z.subject), P = v.find((Z) => {
2644
+ var K;
2645
+ return (K = w.get(Z.value)) == null ? void 0 : K.isCategoryCover;
2646
+ }), M = (P == null ? void 0 : P.value) ?? null, J = M ? I.get(M) ?? /* @__PURE__ */ new Set() : /* @__PURE__ */ new Set(), B = J.has("manage");
2647
+ return {
2648
+ category: f,
2649
+ options: v,
2650
+ selectedSubjects: V,
2651
+ isMultiAction: b,
2652
+ actionColumns: E,
2653
+ permissionActionsMap: X,
2654
+ selectedActionsMap: I,
2655
+ coverSubject: M,
2656
+ coverSelectedActions: J,
2657
+ coverCoversAll: B
2658
+ };
2659
+ });
2660
+ });
2661
+ function u(T, w) {
2662
+ var f;
2663
+ const U = ((f = d.value.find((v) => v.category === T)) == null ? void 0 : f.options) ?? [];
2664
+ a("update:model-value", [
2665
+ ...s.modelValue.filter((v) => !U.some((X) => X.value === v.subject)),
2666
+ ...l.value.filter((v) => w.includes(v.subject)).map(
2667
+ ({ category: v, showByFeatureFlag: X, isCategoryCover: b, ...E }) => E
2668
+ )
2669
+ ]);
2670
+ }
2671
+ function h(T) {
2672
+ return T.options.length > 0 && T.options.every((w) => T.selectedSubjects.includes(w.value));
2673
+ }
2674
+ function O(T) {
2675
+ const w = s.modelValue.filter(
2676
+ (U) => !T.options.some((f) => f.value === U.subject)
2677
+ );
2678
+ if (h(T))
2679
+ a("update:model-value", w);
2680
+ else {
2681
+ const U = l.value.filter((f) => T.options.some((v) => v.value === f.subject)).map(
2682
+ ({ category: f, showByFeatureFlag: v, isCategoryCover: X, ...b }) => b
2683
+ );
2684
+ a("update:model-value", [...w, ...U]);
2685
+ }
2686
+ }
2687
+ function C(T, w) {
2688
+ const U = T.selectedActionsMap.get(w);
2689
+ return U ? U.has("manage") : !1;
2690
+ }
2691
+ function k(T, w) {
2692
+ const U = T.permissionActionsMap.get(w);
2693
+ if (!U) return !1;
2694
+ const f = U.filter((b) => b !== "manage");
2695
+ if (f.length === 0) return !1;
2696
+ const v = T.selectedActionsMap.get(w);
2697
+ if (!v) return !1;
2698
+ const X = f.filter((b) => v.has(b));
2699
+ return X.length > 0 && X.length < f.length;
2700
+ }
2701
+ function j(T, w, U) {
2702
+ if (U) {
2703
+ const f = l.value.find((V) => V.subject === w);
2704
+ if (!f) return;
2705
+ const { category: v, showByFeatureFlag: X, isCategoryCover: b, ...E } = f, I = s.modelValue.filter((V) => V.subject !== w);
2706
+ I.push(E), a("update:model-value", I);
2707
+ } else
2708
+ a(
2709
+ "update:model-value",
2710
+ s.modelValue.filter((f) => f.subject !== w)
2711
+ );
2712
+ }
2713
+ function W(T, w) {
2714
+ const U = T.permissionActionsMap.get(w);
2715
+ return U ? U.some((f) => f !== "manage") : !1;
2716
+ }
2717
+ function R(T, w, U) {
2718
+ const f = T.selectedActionsMap.get(w);
2719
+ return f ? f.has(U) : !1;
2720
+ }
2721
+ function S(T, w) {
2722
+ return !T.coverSubject || w === T.coverSubject ? !1 : T.coverCoversAll;
2723
+ }
2724
+ function i(T, w, U) {
2725
+ return !T.coverSubject || w === T.coverSubject ? !1 : T.coverCoversAll ? !0 : T.coverSelectedActions.has(U);
2726
+ }
2727
+ function m(T, w, U) {
2728
+ const f = T.permissionActionsMap.get(w);
2729
+ return f ? f.includes(U) : !1;
2730
+ }
2731
+ function L(T, w, U) {
2732
+ const f = [...s.modelValue], v = f.findIndex((b) => b.subject === T && !b.inverted);
2733
+ if (U)
2734
+ if (v >= 0) {
2735
+ const b = { ...f[v] }, E = new Set(b.actions);
2736
+ E.add(w), b.actions = Array.from(E), f[v] = b;
2737
+ } else {
2738
+ const b = l.value.find((M) => M.subject === T);
2739
+ if (!b) return;
2740
+ const {
2741
+ category: E,
2742
+ showByFeatureFlag: I,
2743
+ isCategoryCover: V,
2744
+ ...P
2745
+ } = b;
2746
+ f.push({ ...P, actions: [w] });
2747
+ }
2748
+ else if (v >= 0) {
2749
+ const b = { ...f[v] }, E = b.actions.filter((I) => I !== w);
2750
+ E.length === 0 ? f.splice(v, 1) : (b.actions = E, f[v] = b);
2751
+ }
2752
+ const X = l.value.find((b) => b.subject === T);
2753
+ if (X) {
2754
+ const E = X.actions.filter((I) => I !== "manage");
2755
+ if (E.length > 0) {
2756
+ const I = f.findIndex((V) => V.subject === T && !V.inverted);
2757
+ if (I >= 0) {
2758
+ const V = new Set(f[I].actions), P = E.every((M) => V.has(M));
2759
+ P && !V.has("manage") ? (V.add("manage"), f[I] = {
2760
+ ...f[I],
2761
+ actions: Array.from(V)
2762
+ }) : !P && V.has("manage") && (V.delete("manage"), V.size === 0 ? f.splice(I, 1) : f[I] = {
2763
+ ...f[I],
2764
+ actions: Array.from(V)
2765
+ });
2766
+ }
2767
+ }
2768
+ }
2769
+ a("update:model-value", f);
2770
+ }
2771
+ function p(T, w) {
2772
+ return T.options.filter((U) => m(T, U.value, w)).every(
2773
+ (U) => R(T, U.value, w) || i(T, U.value, w)
2774
+ );
2775
+ }
2776
+ function D(T, w) {
2777
+ const U = T.options.filter((v) => m(T, v.value, w));
2778
+ if (U.length === 0) return !1;
2779
+ const f = U.filter(
2780
+ (v) => R(T, v.value, w) || i(T, v.value, w)
2781
+ ).length;
2782
+ return f > 0 && f < U.length;
2783
+ }
2784
+ function A(T, w, U) {
2785
+ let f = [...s.modelValue];
2786
+ for (const v of T.options) {
2787
+ if (!m(T, v.value, w)) continue;
2788
+ const X = v.value, b = f.findIndex(
2789
+ (I) => I.subject === X && !I.inverted
2790
+ );
2791
+ if (U)
2792
+ if (b >= 0) {
2793
+ const I = { ...f[b] }, V = new Set(I.actions);
2794
+ V.add(w), I.actions = Array.from(V), f[b] = I;
2795
+ } else {
2796
+ const I = l.value.find((B) => B.subject === X);
2797
+ if (!I) continue;
2798
+ const {
2799
+ category: V,
2800
+ showByFeatureFlag: P,
2801
+ isCategoryCover: M,
2802
+ ...J
2803
+ } = I;
2804
+ f.push({ ...J, actions: [w] });
2805
+ }
2806
+ else if (b >= 0) {
2807
+ const I = { ...f[b] }, V = I.actions.filter((P) => P !== w);
2808
+ V.length === 0 ? f.splice(b, 1) : (I.actions = V, f[b] = I);
2809
+ }
2810
+ const E = l.value.find((I) => I.subject === X);
2811
+ if (E) {
2812
+ const V = E.actions.filter((P) => P !== "manage");
2813
+ if (V.length > 0) {
2814
+ const P = f.findIndex(
2815
+ (M) => M.subject === X && !M.inverted
2816
+ );
2817
+ if (P >= 0) {
2818
+ const M = new Set(f[P].actions), J = V.every((B) => M.has(B));
2819
+ J && !M.has("manage") ? (M.add("manage"), f[P] = {
2820
+ ...f[P],
2821
+ actions: Array.from(M)
2822
+ }) : !J && M.has("manage") && (M.delete("manage"), M.size === 0 ? f.splice(P, 1) : f[P] = {
2823
+ ...f[P],
2824
+ actions: Array.from(M)
2825
+ });
2826
+ }
2827
+ }
2828
+ }
2829
+ }
2830
+ a("update:model-value", f);
2831
+ }
2832
+ const y = {
2833
+ read: "View",
2834
+ create: "Duplicate",
2835
+ update: "Edit"
2836
+ };
2837
+ function te(T) {
2838
+ return y[T] ?? T.charAt(0).toUpperCase() + T.slice(1);
2839
+ }
2840
+ return (T, w) => {
2841
+ const U = Xe("FmCheckbox");
2842
+ return Y(), ne("div", gr, [
2843
+ (Y(!0), ne(Ie, null, pe(d.value, (f) => (Y(), ne(Ie, {
2844
+ key: f.category
2845
+ }, [
2846
+ f.isMultiAction ? (Y(), ne("div", vr, [
2847
+ se("div", Ir, [
2848
+ se("div", Er, Ae(f.category), 1),
2849
+ se("div", Nr, [
2850
+ (Y(!0), ne(Ie, null, pe(f.actionColumns, (v) => (Y(), ne("span", {
2851
+ key: v,
2852
+ class: "w-[56px] text-center fm-typo-en-body-sm-400 text-fm-color-neutral-gray-600"
2853
+ }, Ae(te(v)), 1))), 128))
2854
+ ])
2855
+ ]),
2856
+ se("div", yr, [
2857
+ se("div", Tr, [
2858
+ fe(U, {
2859
+ "model-value": h(f),
2860
+ value: !0,
2861
+ disabled: e.disable,
2862
+ label: "All",
2863
+ size: "sm",
2864
+ dense: "",
2865
+ "onUpdate:modelValue": (v) => O(f)
2866
+ }, null, 8, ["model-value", "disabled", "onUpdate:modelValue"]),
2867
+ se("div", kr, [
2868
+ (Y(!0), ne(Ie, null, pe(f.actionColumns, (v) => (Y(), ne("div", {
2869
+ key: v,
2870
+ class: "w-[56px] flex justify-center"
2871
+ }, [
2872
+ fe(U, {
2873
+ "model-value": p(f, v),
2874
+ indeterminate: D(f, v),
2875
+ value: v,
2876
+ disabled: e.disable,
2877
+ size: "sm",
2878
+ "onUpdate:modelValue": (X) => A(f, v, X)
2879
+ }, null, 8, ["model-value", "indeterminate", "value", "disabled", "onUpdate:modelValue"])
2880
+ ]))), 128))
2881
+ ])
2882
+ ]),
2883
+ (Y(!0), ne(Ie, null, pe(f.options, (v, X) => (Y(), ne("div", {
2884
+ key: v.value,
2885
+ class: qe(X < f.options.length - 1 ? "q-mb-xs" : "")
2886
+ }, [
2887
+ se("div", Lr, [
2888
+ se("div", Or, [
2889
+ fe(U, {
2890
+ "model-value": C(f, v.value) || S(f, v.value),
2891
+ value: v.value,
2892
+ disabled: e.disable || S(f, v.value),
2893
+ indeterminate: k(f, v.value),
2894
+ size: "sm",
2895
+ class: "shrink-0",
2896
+ "onUpdate:modelValue": (b) => j(f, v.value, b)
2897
+ }, null, 8, ["model-value", "value", "disabled", "indeterminate", "onUpdate:modelValue"]),
2898
+ se("span", {
2899
+ class: "block truncate cursor-pointer",
2900
+ title: v.label,
2901
+ onClick: (b) => !e.disable && !S(f, v.value) && j(f, v.value, !C(f, v.value))
2902
+ }, Ae(v.label), 9, Rr),
2903
+ be(T.$slots, `checkbox-${v.value}-append`, { option: v })
2904
+ ]),
2905
+ W(f, v.value) ? (Y(), ne("div", Cr, [
2906
+ (Y(!0), ne(Ie, null, pe(f.actionColumns, (b) => (Y(), ne("div", {
2907
+ key: b,
2908
+ class: "w-[56px] flex justify-center"
2909
+ }, [
2910
+ m(f, v.value, b) ? (Y(), Se(U, {
2911
+ key: 0,
2912
+ "model-value": R(f, v.value, b) || i(f, v.value, b),
2913
+ value: b,
2914
+ disabled: e.disable || i(f, v.value, b),
2915
+ size: "sm",
2916
+ "onUpdate:modelValue": (E) => L(v.value, b, E)
2917
+ }, null, 8, ["model-value", "value", "disabled", "onUpdate:modelValue"])) : Le("", !0)
2918
+ ]))), 128))
2919
+ ])) : Le("", !0)
2920
+ ])
2921
+ ], 2))), 128))
2922
+ ])
2923
+ ])) : (Y(), Se(zt, {
2924
+ key: 0,
2925
+ "model-value": f.selectedSubjects,
2926
+ options: f.options,
2927
+ disable: e.disable,
2928
+ title: f.category,
2929
+ "onUpdate:modelValue": (v) => u(f.category, v)
2930
+ }, Fe({ _: 2 }, [
2931
+ pe(f.options, (v) => ({
2932
+ name: `checkbox-${v.value}-append`,
2933
+ fn: he(({ option: X }) => [
2934
+ be(T.$slots, `checkbox-${v.value}-append`, { option: X })
2935
+ ])
2936
+ }))
2937
+ ]), 1032, ["model-value", "options", "disable", "title", "onUpdate:modelValue"]))
2938
+ ], 64))), 128))
2939
+ ]);
2940
+ };
2941
+ }
2942
+ }), Sr = { class: "flex items-center" }, Dr = { class: "ml-auto" }, Mr = /* @__PURE__ */ Ne({
2943
+ __name: "CollapsibleWrapper",
2944
+ props: {
2945
+ title: { default: "" },
2946
+ initiallyCollapsed: { type: Boolean, default: !1 }
2947
+ },
2948
+ setup(e) {
2949
+ const n = Ue(e.initiallyCollapsed), s = Ue(), l = Ue(0);
2950
+ let a;
2951
+ function c() {
2952
+ n.value = !n.value;
2953
+ }
2954
+ function d() {
2955
+ s.value && (l.value = s.value.scrollHeight);
2956
+ }
2957
+ return xt(async () => {
2958
+ await zn(), s.value && (a = new ResizeObserver(() => {
2959
+ d();
2960
+ }), a.observe(s.value));
2961
+ }), On(() => {
2962
+ a == null || a.disconnect();
2963
+ }), (u, h) => {
2964
+ const O = Xe("FmButton");
2965
+ return Y(), ne(Ie, null, [
2966
+ se("div", { onClick: c }, [
2967
+ se("div", Sr, [
2968
+ be(u.$slots, "title"),
2969
+ se("div", Dr, [
2970
+ fe(O, {
2971
+ icon: n.value ? "keyboard_arrow_down" : "keyboard_arrow_up",
2972
+ "text-color": "neutral-gray-400",
2973
+ variant: "tertiary",
2974
+ size: "md"
2975
+ }, null, 8, ["icon"])
2976
+ ])
2977
+ ])
2978
+ ]),
2979
+ se("div", {
2980
+ ref_key: "contentRef",
2981
+ ref: s,
2982
+ class: "transition-all duration-300 ease-in-out overflow-hidden",
2983
+ style: ct({ maxHeight: n.value ? "0" : l.value + "px" })
2984
+ }, [
2985
+ be(u.$slots, "default")
2986
+ ], 4)
2987
+ ], 64);
2988
+ };
2989
+ }
2990
+ }), wr = { class: "fm-typo-en-title-sm-600" }, Ct = "includedFuture", Ln = /* @__PURE__ */ Ne({
2991
+ __name: "ConditionPermission",
2992
+ props: {
2993
+ modelValue: {
2994
+ type: Array,
2995
+ default: null
2996
+ },
2997
+ options: {
2998
+ type: Array,
2999
+ required: !0
3000
+ },
3001
+ disable: {
3002
+ type: Boolean,
3003
+ default: !1
3004
+ },
3005
+ context: {
3006
+ type: String,
3007
+ required: !0
3008
+ }
3009
+ },
3010
+ emits: ["update:model-value"],
3011
+ setup(e, { emit: t }) {
3012
+ const n = e, s = t, { t: l } = _t(), a = ee(() => [
3013
+ {
3014
+ label: l("team.memberForm.permissions.includedFuture", { context: n.context }),
3015
+ value: Ct,
3016
+ // Can only be selected if all other options are selected
3017
+ disable: !!n.modelValue && n.options.length > n.modelValue.length
3018
+ },
3019
+ ...n.options.filter(
3020
+ (h) => h.label.toLocaleLowerCase().includes(u.value.toLocaleLowerCase())
3021
+ )
3022
+ ]), c = ee(() => n.modelValue ? n.modelValue : [Ct, ...n.options.map((h) => h.value)]);
3023
+ function d(h) {
3024
+ const O = h.length === a.value.length;
3025
+ s("update:model-value", O ? null : h.filter((C) => C !== Ct));
3026
+ }
3027
+ const u = Ue("");
3028
+ return (h, O) => {
3029
+ const C = Xe("fm-search");
3030
+ return Y(), Se(Mr, null, {
3031
+ title: he(() => [
3032
+ se("p", wr, Ae(Te(l)("team.memberForm.permissions.manageable", { context: e.context })), 1)
3033
+ ]),
3034
+ default: he(() => [
3035
+ e.options.length > 1 ? (Y(), Se(C, {
3036
+ key: 0,
3037
+ modelValue: u.value,
3038
+ "onUpdate:modelValue": O[0] || (O[0] = (k) => u.value = k),
3039
+ class: "mt-16",
3040
+ placeholder: Te(l)("team.memberForm.permissions.search", { context: e.context })
3041
+ }, null, 8, ["modelValue", "placeholder"])) : Le("", !0),
3042
+ fe(zt, {
3043
+ "model-value": c.value,
3044
+ options: a.value,
3045
+ "show-intermediate": !1,
3046
+ "show-all-toggle": !0,
3047
+ disable: e.disable,
3048
+ "include-disabled-options-when-select-all": !0,
3049
+ title: "",
3050
+ class: "mt-16",
3051
+ "onUpdate:modelValue": d
3052
+ }, Fe({ _: 2 }, [
3053
+ pe(a.value, (k) => ({
3054
+ name: `checkbox-${k.value}-append`,
3055
+ fn: he(({ option: j }) => [
3056
+ be(h.$slots, `checkbox-${k.value}-append`, { option: j })
3057
+ ])
3058
+ }))
3059
+ ]), 1032, ["model-value", "options", "disable"])
3060
+ ]),
3061
+ _: 3
3062
+ });
3063
+ };
3064
+ }
3065
+ }), At = "includedNewRole", Pr = /* @__PURE__ */ Ne({
3066
+ __name: "PosRolePermission",
3067
+ props: {
3068
+ modelValue: {
3069
+ type: Array,
3070
+ default: null
3071
+ },
3072
+ roles: {
3073
+ type: Array,
3074
+ required: !0
3075
+ },
3076
+ restaurantIds: {
3077
+ type: Array,
3078
+ default: null
3079
+ },
3080
+ disable: {
3081
+ type: Boolean,
3082
+ default: !1
3083
+ }
3084
+ },
3085
+ emits: ["update:model-value"],
3086
+ setup(e, { emit: t }) {
3087
+ const n = e, s = t, { t: l } = _t(), a = ee(() => {
3088
+ const u = n.restaurantIds;
3089
+ return [
3090
+ {
3091
+ label: l("team.memberForm.permissions.includedNewRole"),
3092
+ value: At,
3093
+ disable: !!n.modelValue && n.roles.length > n.modelValue.length
3094
+ },
3095
+ ...n.roles.map((h) => ({
3096
+ label: h.name,
3097
+ value: h._id,
3098
+ disable: !!u && h.restaurants.every(({ id: O }) => !u.includes(O))
3099
+ }))
3100
+ ];
3101
+ }), c = ee(() => n.modelValue ? n.modelValue : [At, ...n.roles.map((u) => u._id)]);
3102
+ function d(u) {
3103
+ const h = u.length === a.value.length;
3104
+ s("update:model-value", h ? null : u.filter((O) => O !== At));
3105
+ }
3106
+ return (u, h) => (Y(), Se(zt, {
3107
+ "model-value": c.value,
3108
+ options: a.value,
3109
+ "show-intermediate": !1,
3110
+ "show-all-toggle": !1,
3111
+ disable: e.disable,
3112
+ title: Te(l)("team.memberForm.permissions.roles"),
3113
+ "onUpdate:modelValue": d
3114
+ }, Fe({ _: 2 }, [
3115
+ pe(a.value, (O) => ({
3116
+ name: `checkbox-${O.value}-append`,
3117
+ fn: he(({ option: C }) => [
3118
+ be(u.$slots, `checkbox-${O.value}-append`, { option: C })
3119
+ ])
3120
+ }))
3121
+ ]), 1032, ["model-value", "options", "disable", "title"]));
3122
+ }
3123
+ }), Fr = {
3124
+ async readWarehouses() {
3125
+ return as(await rs().get("/warehouses"));
3126
+ }
3127
+ }, jr = { class: "flex flex-col gap-32" }, Ur = { class: "p-16 fm-corner-radius-lg border border-fm-color-neutral-gray-200" }, Vr = { class: "p-16 fm-corner-radius-lg border border-fm-color-neutral-gray-200" }, Gr = { class: "p-16 fm-corner-radius-lg border border-fm-color-neutral-gray-200" }, Wr = { class: "p-16 fm-corner-radius-lg border border-fm-color-neutral-gray-200" }, zr = /* @__PURE__ */ Ne({
3128
+ __name: "PortalPermissionEditor",
3129
+ props: /* @__PURE__ */ Qt({
3130
+ disable: {
3131
+ type: Boolean,
3132
+ default: !1
3133
+ },
3134
+ inheritPermissions: {
3135
+ type: Array,
3136
+ default: () => []
3137
+ }
3138
+ }, {
3139
+ modelValue: { default: () => [] },
3140
+ modelModifiers: {}
3141
+ }),
3142
+ emits: /* @__PURE__ */ Qt(["permissionChanged"], ["update:modelValue"]),
3143
+ setup(e, { emit: t }) {
3144
+ const n = Qn(e, "modelValue"), s = e, l = t, { t: a } = _t(), { fetchCustomReportPermissions: c, customReportPermissions: d } = es();
3145
+ function u(b) {
3146
+ return Dt.find((E) => E.subject === b) ?? d.value.find((E) => E.subject === b);
3147
+ }
3148
+ const h = ee(() => {
3149
+ const b = [...Dt, ...d.value].filter((I) => !j.includes(I.subject)).map((I) => I.subject);
3150
+ return ts(
3151
+ s.inheritPermissions.map((I) => ({
3152
+ ...I,
3153
+ permissions: I.permissions.filter((V) => b.includes(V.subject))
3154
+ }))
3155
+ ).map((I) => ({
3156
+ id: I.subject,
3157
+ setNames: I.setNames
3158
+ }));
3159
+ }), O = ee(() => {
3160
+ const b = s.inheritPermissions.map((E) => ({
3161
+ ...E,
3162
+ permissions: E.permissions.filter(
3163
+ (I) => I.subject === ue.Subject.Business.inventory_stock
3164
+ )
3165
+ }));
3166
+ return yt(
3167
+ b,
3168
+ "warehouseId",
3169
+ R.value.map((E) => E._id)
3170
+ );
3171
+ }), C = ee(() => {
3172
+ const b = s.inheritPermissions.map((E) => ({
3173
+ ...E,
3174
+ permissions: E.permissions.filter(
3175
+ (I) => I.subject === ue.Subject.Restaurant.restaurant
3176
+ )
3177
+ }));
3178
+ return yt(
3179
+ b,
3180
+ "restaurantId",
3181
+ L.value.map((E) => E._id)
3182
+ );
3183
+ }), k = ee(() => {
3184
+ const b = s.inheritPermissions.map((E) => ({
3185
+ ...E,
3186
+ permissions: E.permissions.filter((I) => I.subject === ue.Subject.Business.role)
3187
+ }));
3188
+ return yt(
3189
+ b,
3190
+ "roleId",
3191
+ p.value.map((E) => E._id)
3192
+ );
3193
+ }), j = [
3194
+ ue.Subject.Business.restaurant,
3195
+ ue.Subject.Business.role,
3196
+ ue.Subject.Restaurant.restaurant,
3197
+ ue.Subject.Business.inventory_stock
3198
+ ], W = ee(() => {
3199
+ var E;
3200
+ const b = (E = n.value) == null ? void 0 : E.find(
3201
+ (I) => I.subject === ue.Subject.Business.inventory_stock
3202
+ );
3203
+ return b ? b.conditions ? JSON.parse(b.conditions).warehouseId.$in : null : [];
3204
+ }), R = Ue([]), S = ee(() => R.value.map((b) => ({
3205
+ label: b.profile.name,
3206
+ value: b._id
3207
+ })));
3208
+ function i(b) {
3209
+ const E = m(n.value, b);
3210
+ n.value = E;
3211
+ }
3212
+ function m(b, E) {
3213
+ let I = ut(
3214
+ b.filter((V) => V.subject !== ue.Subject.Business.inventory_stock)
3215
+ );
3216
+ if (!E || E.length > 0) {
3217
+ const V = {
3218
+ actions: [ue.Action.manage],
3219
+ subject: ue.Subject.Business.inventory_stock
3220
+ };
3221
+ E && (V.conditions = JSON.stringify({ warehouseId: { $in: E } })), I.push(V);
3222
+ }
3223
+ return I;
3224
+ }
3225
+ const { restaurants: L } = qn(), p = cs().roles, D = ee(() => L.value.map((b) => ({
3226
+ label: `${b.profile.code ? b.profile.code + "-" : ""}${b.profile.name}`,
3227
+ value: b._id
3228
+ }))), A = ee(() => L.value.reduce((b, E) => (b[E._id] = p.value.filter((I) => I.restaurants.some((V) => V.id === E._id)).map((I) => I._id), b), {})), y = ee(() => ns(n.value));
3229
+ function te(b) {
3230
+ const E = w(n.value, b);
3231
+ n.value = E;
3232
+ }
3233
+ const T = ee(() => ss(n.value));
3234
+ function w(b, E) {
3235
+ var V;
3236
+ let I = ut(
3237
+ b.filter(
3238
+ (P) => P.subject !== ue.Subject.Business.restaurant && P.subject !== ue.Subject.Restaurant.restaurant
3239
+ )
3240
+ );
3241
+ if (!E || E.length > 0) {
3242
+ const {
3243
+ category: P,
3244
+ showByFeatureFlag: M,
3245
+ ...J
3246
+ } = os.restaurant;
3247
+ I.push(J);
3248
+ const B = {
3249
+ actions: [ue.Action.manage],
3250
+ subject: ue.Subject.Restaurant.restaurant
3251
+ };
3252
+ E && (B.conditions = JSON.stringify({ restaurantId: { $in: E } })), I.push(B);
3253
+ }
3254
+ if (E) {
3255
+ const P = [
3256
+ ...new Set(E.map((J) => A.value[J]).flatMap((J) => J))
3257
+ ], M = p.value.map((J) => J._id);
3258
+ P.length !== M.length && (I = f(
3259
+ I,
3260
+ (V = T.value || M) == null ? void 0 : V.filter((J) => P.includes(J))
3261
+ ));
3262
+ }
3263
+ return I;
3264
+ }
3265
+ function U(b) {
3266
+ const E = f(n.value, b);
3267
+ n.value = E;
3268
+ }
3269
+ function f(b, E) {
3270
+ let I = ut(
3271
+ b.filter((V) => V.subject !== ue.Subject.Business.role)
3272
+ );
3273
+ if (E && E.length > 0) {
3274
+ const V = {
3275
+ actions: [ue.Action.manage],
3276
+ subject: ue.Subject.Business.role,
3277
+ conditions: JSON.stringify({ roleId: { $in: E } })
3278
+ };
3279
+ I.push(V);
3280
+ }
3281
+ return I;
3282
+ }
3283
+ xt(async () => {
3284
+ await Promise.all([
3285
+ Fr.readWarehouses().then((b) => R.value = b),
3286
+ c()
3287
+ ]);
3288
+ });
3289
+ const v = ee(() => Tt(
3290
+ n.value,
3291
+ kt
3292
+ ).map((E) => {
3293
+ if (E.inverted) return E;
3294
+ const I = E.actions;
3295
+ if (!I.includes("manage")) return E;
3296
+ const V = u(E.subject);
3297
+ if (!V) return E;
3298
+ const P = V.actions;
3299
+ return P.length <= 1 || P.filter((J) => !I.includes(J)).length === 0 ? E : { ...E, actions: [...P] };
3300
+ }));
3301
+ function X(b) {
3302
+ const E = new Set(
3303
+ v.value.filter((M) => !M.inverted).map((M) => M.subject)
3304
+ ), I = new Set(
3305
+ b.filter((M) => !M.inverted).map((M) => M.subject)
3306
+ ), V = new Set(
3307
+ n.value.filter((M) => !M.inverted).map((M) => M.subject)
3308
+ );
3309
+ let P = [...n.value];
3310
+ for (const M of E)
3311
+ I.has(M) || (V.has(M) && (P = P.filter((B) => B.subject !== M)), (!V.has(M) || Tt(
3312
+ P,
3313
+ kt
3314
+ ).some((B) => B.subject === M && !B.inverted)) && !P.some((B) => B.subject === M && B.inverted) && P.push({ subject: M, actions: ["manage"], inverted: !0 }));
3315
+ for (const M of I)
3316
+ if (!E.has(M)) {
3317
+ const J = P.some((B) => B.subject === M && B.inverted);
3318
+ if (P = P.filter((B) => !(B.subject === M && B.inverted)), !J && !V.has(M)) {
3319
+ const B = b.find(
3320
+ (K) => K.subject === M && !K.inverted
3321
+ ), Z = u(M);
3322
+ if (Z && B) {
3323
+ const { category: K, showByFeatureFlag: we, ...ae } = Z;
3324
+ P.push({ ...ae, actions: B.actions });
3325
+ }
3326
+ }
3327
+ }
3328
+ for (const M of I) {
3329
+ if (!E.has(M)) continue;
3330
+ const J = v.value.find(
3331
+ (ae) => ae.subject === M && !ae.inverted
3332
+ ), B = b.find((ae) => ae.subject === M && !ae.inverted);
3333
+ if (!J || !B) continue;
3334
+ const Z = new Set(J.actions), K = new Set(B.actions);
3335
+ if (Z.size === K.size && [...Z].every((ae) => K.has(ae)))
3336
+ continue;
3337
+ const we = P.findIndex((ae) => ae.subject === M && !ae.inverted);
3338
+ if (we >= 0)
3339
+ P[we] = {
3340
+ ...P[we],
3341
+ actions: Array.from(K)
3342
+ };
3343
+ else {
3344
+ const ae = u(M);
3345
+ if (ae) {
3346
+ const { category: ve, showByFeatureFlag: $e, ...Je } = ae;
3347
+ P.push({ ...Je, actions: Array.from(K) });
3348
+ }
3349
+ }
3350
+ Z.has("manage") && !K.has("manage") && Tt(
3351
+ P,
3352
+ kt
3353
+ ).some(
3354
+ (ve) => ve.subject === M && !ve.inverted && ve.actions.includes("manage")
3355
+ ) && !P.some((ve) => ve.subject === M && ve.inverted) && P.push({ subject: M, actions: ["manage"], inverted: !0 }), !Z.has("manage") && K.has("manage") && (P = P.filter((ae) => !(ae.subject === M && ae.inverted)));
3356
+ }
3357
+ n.value = P;
3358
+ }
3359
+ return St(
3360
+ n,
3361
+ (b) => {
3362
+ l("permissionChanged", b);
3363
+ },
3364
+ { deep: !0 }
3365
+ ), (b, E) => (Y(), ne("div", jr, [
3366
+ se("div", Ur, [
3367
+ fe(Ar, {
3368
+ "model-value": v.value,
3369
+ "excluded-subjects": j,
3370
+ "additional-permissions": Te(d),
3371
+ "onUpdate:modelValue": X
3372
+ }, Fe({ _: 2 }, [
3373
+ pe(h.value, (I) => ({
3374
+ name: `checkbox-${I.id}-append`,
3375
+ fn: he(() => [
3376
+ fe(it, { item: I }, null, 8, ["item"])
3377
+ ])
3378
+ }))
3379
+ ]), 1032, ["model-value", "additional-permissions"])
3380
+ ]),
3381
+ se("div", Vr, [
3382
+ fe(Ln, {
3383
+ "model-value": W.value,
3384
+ options: S.value,
3385
+ context: Te(a)("team.labels.warehouse"),
3386
+ "onUpdate:modelValue": i
3387
+ }, Fe({ _: 2 }, [
3388
+ pe(O.value, (I) => ({
3389
+ name: `checkbox-${I.id}-append`,
3390
+ fn: he(() => [
3391
+ fe(it, { item: I }, null, 8, ["item"])
3392
+ ])
3393
+ }))
3394
+ ]), 1032, ["model-value", "options", "context"])
3395
+ ]),
3396
+ se("div", Gr, [
3397
+ fe(Ln, {
3398
+ "model-value": y.value,
3399
+ options: D.value,
3400
+ context: Te(a)("team.labels.restaurant"),
3401
+ "onUpdate:modelValue": te
3402
+ }, Fe({ _: 2 }, [
3403
+ pe(C.value, (I) => ({
3404
+ name: `checkbox-${I.id}-append`,
3405
+ fn: he(() => [
3406
+ fe(it, { item: I }, null, 8, ["item"])
3407
+ ])
3408
+ }))
3409
+ ]), 1032, ["model-value", "options", "context"])
3410
+ ]),
3411
+ se("div", Wr, [
3412
+ fe(Pr, {
3413
+ roles: Te(p),
3414
+ "model-value": T.value,
3415
+ "restaurant-ids": y.value,
3416
+ "onUpdate:modelValue": U
3417
+ }, Fe({ _: 2 }, [
3418
+ pe(k.value, (I) => ({
3419
+ name: `checkbox-${I.id}-append`,
3420
+ fn: he(() => [
3421
+ fe(it, { item: I }, null, 8, ["item"])
3422
+ ])
3423
+ }))
3424
+ ]), 1032, ["roles", "model-value", "restaurant-ids"])
3425
+ ])
3426
+ ]));
3427
+ }
3428
+ });
3429
+ export {
3430
+ zt as _,
3431
+ zr as a
3432
+ };