@feedmepos/mf-hrm-portal 2.3.2-dev.11 → 2.3.2-dev.12
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{ApprovalCodeList-DoNoFW6w.js → ApprovalCodeList-CCh9mNJh.js} +7 -7
- package/dist/AuditLogList-DCADUZ5s.js +2019 -0
- package/dist/{ConditionBuilderForm.vue_vue_type_script_setup_true_lang-C1dLOPFb.js → ConditionBuilderForm.vue_vue_type_script_setup_true_lang-BZQNDOg7.js} +10 -10
- package/dist/{EmployeeList-BX9gy9WG.js → EmployeeList-CRI7XjzX.js} +8 -8
- package/dist/{FormSection.vue_vue_type_script_setup_true_lang-iCgTyICI.js → FormSection.vue_vue_type_script_setup_true_lang-y9_hxba6.js} +1 -1
- package/dist/{GrantUserList-DNvmmlDI.js → GrantUserList-DbMngkpK.js} +8 -8
- package/dist/{Main-BHmY7VHC.js → Main-BsFUfsmP.js} +29 -29
- package/dist/{Main-SzU5H5uC.js → Main-CrnM6wr8.js} +623 -629
- package/dist/{Main-2NivoQNg.js → Main-D4Zq5AXi.js} +5 -5
- package/dist/{MyPosProfile-2W5mT5d5.js → MyPosProfile-B4cE47im.js} +1 -1
- package/dist/{PermissionSetList-BCAm8rHm.js → PermissionSetList-D_2x-mDD.js} +112 -113
- package/dist/PortalPermissionEditor.vue_vue_type_script_setup_true_lang-BM9Von-l.js +4212 -0
- package/dist/{PortalUserSearcher.vue_vue_type_style_index_0_scoped_827dfd60_lang-DYbfmF2P.js → PortalUserSearcher.vue_vue_type_style_index_0_scoped_827dfd60_lang-COX-N0k6.js} +33 -33
- package/dist/{RoleForm.vue_vue_type_script_setup_true_lang-o4mXv2hT.js → RoleForm.vue_vue_type_script_setup_true_lang-D8V8KWiL.js} +41 -41
- package/dist/{RoleList-BXkyCeH0.js → RoleList-BC-c7fqn.js} +105 -96
- package/dist/{ScheduleAddPositionModal.vue_vue_type_script_setup_true_lang-DOxRdHY1.js → ScheduleAddPositionModal.vue_vue_type_script_setup_true_lang-DBbuSrXV.js} +1 -1
- package/dist/{ScheduleGeneralPage-4hV53-q6.js → ScheduleGeneralPage-eytzOZQr.js} +2 -2
- package/dist/{ScheduleModal.vue_vue_type_script_setup_true_lang-D5jOHLA1.js → ScheduleModal.vue_vue_type_script_setup_true_lang-CP-kToVO.js} +4 -4
- package/dist/{SchedulePage-CqNa_p32.js → SchedulePage-B0QirzAk.js} +17 -17
- package/dist/{SchedulePositionPage-7xYBe1xd.js → SchedulePositionPage-BAE-NQvL.js} +3 -3
- package/dist/{SelectFilter-Dy2Nv1_D.js → SelectFilter-DrLJhxt6.js} +1 -1
- package/dist/TeamMemberList-CHkiL_q9.js +2083 -0
- package/dist/TimesheetList-BZuddmzy.js +402 -0
- package/dist/TimesheetList.vue_vue_type_style_index_0_scoped_63294af2_lang-LCUO-ogb.js +58 -0
- package/dist/{app-C37qvNnc.js → app-B9qAxMj1.js} +3516 -3470
- package/dist/app.js +1 -1
- package/dist/{approval-code-B7rpc4Oe.js → approval-code-CTgj9q6m.js} +1 -1
- package/dist/{dayjs.min-D35yhU4A.js → dayjs.min-giCSI3N8.js} +22 -22
- package/dist/employee-BD3NXG8h.js +210 -0
- package/dist/{grant-user-CostZ0Md.js → grant-user-jeTFzGU1.js} +1 -1
- package/dist/{index-DPiNc7mn.js → iteration-Tyg43nH0.js} +726 -698
- package/dist/{lodash-C8MGI_QW.js → lodash-CZsDR_DU.js} +1 -1
- package/dist/{member-grant-CktOoicv.js → member-grant-DsEMLN1N.js} +2 -2
- package/dist/restaurant-CDJ3VjdH.js +49 -0
- package/dist/role-BDRWt87n.js +91 -0
- package/dist/{rule-EYBPBkv_.js → rule-EiO87cJJ.js} +309 -313
- package/dist/src/api/employee/index.d.ts +2 -1
- package/dist/src/api/timesheet/index.d.ts +1 -1
- package/dist/src/composables/useTenant.d.ts +11 -0
- package/dist/src/router/courtGuard.d.ts +4 -0
- package/dist/src/stores/employee.d.ts +7 -1
- package/dist/src/stores/restaurant.d.ts +1 -61
- package/dist/src/stores/team.d.ts +1 -1
- package/dist/src/stores/timesheet.d.ts +51 -66
- package/dist/src/types/timesheet.d.ts +0 -3
- package/dist/style.css +1 -1
- package/dist/tsconfig.app.tsbuildinfo +1 -1
- package/dist/{useAppStore-BmBJPo1_.js → useAppStore-CkUZ2H5h.js} +1 -1
- package/dist/{useLoading-BtyGXkm_.js → useLoading-DJHJM5E0.js} +1 -1
- package/dist/useReportPermissions-2dfIX21b.js +80 -0
- package/dist/{useSsoProviders-CZrTNgfp.js → useSsoProviders-BarGHndw.js} +1 -1
- package/package.json +2 -2
- package/dist/AuditLogList-D5M0cl8g.js +0 -2026
- package/dist/PortalPermissionEditor.vue_vue_type_script_setup_true_lang-e2vu_Mcn.js +0 -4208
- package/dist/TeamMemberList-okhiXdLg.js +0 -2087
- package/dist/TimesheetList-BKj9OnJW.js +0 -437
- package/dist/employee-Bn6HTMxg.js +0 -172
- package/dist/iteration-CcXrOMQe.js +0 -30
- package/dist/restaurant-BgvuJL8G.js +0 -52
- package/dist/role-D8G5QOG1.js +0 -98
- package/dist/timesheet-D6jBeR-V.js +0 -76
- package/dist/useReportPermissions-C8z7EA7v.js +0 -82
|
@@ -1,4208 +0,0 @@
|
|
|
1
|
-
import { getCurrentInstance as Yt, inject as ur, ref as st, shallowRef as mr, computed as K, watch as Mt, onMounted as xn, onUnmounted as dr, defineComponent as Re, h as Vn, createVNode as oe, Text as fr, Fragment as Me, resolveComponent as De, createBlock as Ne, openBlock as $, withCtx as ce, createElementVNode as ie, createElementBlock as re, toDisplayString as Oe, unref as B, renderList as Ee, toRef as qt, normalizeStyle as rt, renderSlot as Le, createCommentVNode as Ce, normalizeClass as Ie, createTextVNode as _r, useSlots as pr, createSlots as tt, mergeModels as en, useModel as vr } from "vue";
|
|
2
|
-
import { useI18n as Ke, useCoreStore as hr } from "@feedmepos/mf-common";
|
|
3
|
-
import { useDialog as br, useBreakpoints as gr } from "@feedmepos/ui-library";
|
|
4
|
-
import "@vue/devtools-api";
|
|
5
|
-
import { p as Gn, N as Wn, Y as tn, V as yr, a as Ir, j as Er, Q as Cr, A as Nr, D as Tr, C as Or } from "./rule-EYBPBkv_.js";
|
|
6
|
-
import { _ as Xt, a as Lr, b as nn, u as Sr } from "./ConditionBuilderForm.vue_vue_type_script_setup_true_lang-C1dLOPFb.js";
|
|
7
|
-
import { u as Rr, v as Ar, g as kr, b as Mr, P as Zn, S as Dt, A as nt, m as Ye, j as rn } from "./app-C37qvNnc.js";
|
|
8
|
-
import { c as Yn } from "./iteration-CcXrOMQe.js";
|
|
9
|
-
import { r as Dr, s as Xn } from "./string-DZQ1uNjn.js";
|
|
10
|
-
import "./index-DPiNc7mn.js";
|
|
11
|
-
import { W as wr } from "./member-grant-CktOoicv.js";
|
|
12
|
-
import { u as Fr } from "./role-D8G5QOG1.js";
|
|
13
|
-
function Lt(e, t, n) {
|
|
14
|
-
const r = /* @__PURE__ */ new Map();
|
|
15
|
-
return e.forEach(
|
|
16
|
-
({ name: a, permissions: o }) => o.forEach(({ conditions: f, actions: d }) => {
|
|
17
|
-
var b, E;
|
|
18
|
-
const i = JSON.parse(f || "{}");
|
|
19
|
-
(b = i[t]) != null && b.$in ? (E = i[t]) == null || E.$in.forEach(
|
|
20
|
-
(N) => (r.get(N) ?? r.set(N, /* @__PURE__ */ new Set()).get(N)).add(a)
|
|
21
|
-
) : d[0] === "manage" && n.forEach((N) => {
|
|
22
|
-
(r.get(N) ?? r.set(N, /* @__PURE__ */ new Set()).get(N)).add(a);
|
|
23
|
-
});
|
|
24
|
-
})
|
|
25
|
-
), [...r].map(([a, o]) => ({
|
|
26
|
-
id: a,
|
|
27
|
-
setNames: [...o]
|
|
28
|
-
}));
|
|
29
|
-
}
|
|
30
|
-
/*!
|
|
31
|
-
* shared v10.0.5
|
|
32
|
-
* (c) 2024 kazuya kawaguchi
|
|
33
|
-
* Released under the MIT License.
|
|
34
|
-
*/
|
|
35
|
-
const sn = typeof window < "u", ze = (e, t = !1) => t ? Symbol.for(e) : Symbol(e), Pr = (e, t, n) => jr({ l: e, k: t, s: n }), jr = (e) => JSON.stringify(e).replace(/\u2028/g, "\\u2028").replace(/\u2029/g, "\\u2029").replace(/\u0027/g, "\\u0027"), be = (e) => typeof e == "number" && isFinite(e), Ur = (e) => Bt(e) === "[object Date]", It = (e) => Bt(e) === "[object RegExp]", Ct = (e) => q(e) && Object.keys(e).length === 0, ge = Object.assign, xr = Object.create, se = (e = null) => xr(e);
|
|
36
|
-
let an;
|
|
37
|
-
const Je = () => an || (an = typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : typeof global < "u" ? global : se());
|
|
38
|
-
function on(e) {
|
|
39
|
-
return e.replace(/</g, "<").replace(/>/g, ">").replace(/"/g, """).replace(/'/g, "'");
|
|
40
|
-
}
|
|
41
|
-
const Vr = Object.prototype.hasOwnProperty;
|
|
42
|
-
function Se(e, t) {
|
|
43
|
-
return Vr.call(e, t);
|
|
44
|
-
}
|
|
45
|
-
const pe = Array.isArray, ue = (e) => typeof e == "function", G = (e) => typeof e == "string", _e = (e) => typeof e == "boolean", ee = (e) => e !== null && typeof e == "object", Gr = (e) => ee(e) && ue(e.then) && ue(e.catch), Bn = Object.prototype.toString, Bt = (e) => Bn.call(e), q = (e) => Bt(e) === "[object Object]", Wr = (e) => e == null ? "" : pe(e) || q(e) && e.toString === Bn ? JSON.stringify(e, null, 2) : String(e);
|
|
46
|
-
function Ht(e, t = "") {
|
|
47
|
-
return e.reduce((n, r, a) => a === 0 ? n + r : n + t + r, "");
|
|
48
|
-
}
|
|
49
|
-
function Zr(e, t) {
|
|
50
|
-
typeof console < "u" && (console.warn("[intlify] " + e), t && console.warn(t.stack));
|
|
51
|
-
}
|
|
52
|
-
const ft = (e) => !ee(e) || pe(e);
|
|
53
|
-
function yt(e, t) {
|
|
54
|
-
if (ft(e) || ft(t))
|
|
55
|
-
throw new Error("Invalid value");
|
|
56
|
-
const n = [{ src: e, des: t }];
|
|
57
|
-
for (; n.length; ) {
|
|
58
|
-
const { src: r, des: a } = n.pop();
|
|
59
|
-
Object.keys(r).forEach((o) => {
|
|
60
|
-
o !== "__proto__" && (ee(r[o]) && !ee(a[o]) && (a[o] = Array.isArray(r[o]) ? [] : se()), ft(a[o]) || ft(r[o]) ? a[o] = r[o] : n.push({ src: r[o], des: a[o] }));
|
|
61
|
-
});
|
|
62
|
-
}
|
|
63
|
-
}
|
|
64
|
-
function Yr(e, t, n) {
|
|
65
|
-
return { line: e, column: t, offset: n };
|
|
66
|
-
}
|
|
67
|
-
function wt(e, t, n) {
|
|
68
|
-
return { start: e, end: t };
|
|
69
|
-
}
|
|
70
|
-
const ne = {
|
|
71
|
-
// tokenizer error codes
|
|
72
|
-
EXPECTED_TOKEN: 1,
|
|
73
|
-
INVALID_TOKEN_IN_PLACEHOLDER: 2,
|
|
74
|
-
UNTERMINATED_SINGLE_QUOTE_IN_PLACEHOLDER: 3,
|
|
75
|
-
UNKNOWN_ESCAPE_SEQUENCE: 4,
|
|
76
|
-
INVALID_UNICODE_ESCAPE_SEQUENCE: 5,
|
|
77
|
-
UNBALANCED_CLOSING_BRACE: 6,
|
|
78
|
-
UNTERMINATED_CLOSING_BRACE: 7,
|
|
79
|
-
EMPTY_PLACEHOLDER: 8,
|
|
80
|
-
NOT_ALLOW_NEST_PLACEHOLDER: 9,
|
|
81
|
-
INVALID_LINKED_FORMAT: 10,
|
|
82
|
-
// parser error codes
|
|
83
|
-
MUST_HAVE_MESSAGES_IN_PLURAL: 11,
|
|
84
|
-
UNEXPECTED_EMPTY_LINKED_MODIFIER: 12,
|
|
85
|
-
UNEXPECTED_EMPTY_LINKED_KEY: 13,
|
|
86
|
-
UNEXPECTED_LEXICAL_ANALYSIS: 14
|
|
87
|
-
}, Xr = 17;
|
|
88
|
-
function Nt(e, t, n = {}) {
|
|
89
|
-
const { domain: r, messages: a, args: o } = n, f = e, d = new SyntaxError(String(f));
|
|
90
|
-
return d.code = e, t && (d.location = t), d.domain = r, d;
|
|
91
|
-
}
|
|
92
|
-
function Br(e) {
|
|
93
|
-
throw e;
|
|
94
|
-
}
|
|
95
|
-
const je = " ", Hr = "\r", ye = `
|
|
96
|
-
`, $r = "\u2028", Jr = "\u2029";
|
|
97
|
-
function Kr(e) {
|
|
98
|
-
const t = e;
|
|
99
|
-
let n = 0, r = 1, a = 1, o = 0;
|
|
100
|
-
const f = (v) => t[v] === Hr && t[v + 1] === ye, d = (v) => t[v] === ye, i = (v) => t[v] === Jr, b = (v) => t[v] === $r, E = (v) => f(v) || d(v) || i(v) || b(v), N = () => n, T = () => r, D = () => a, k = () => o, R = (v) => f(v) || i(v) || b(v) ? ye : t[v], M = () => R(n), p = () => R(n + o);
|
|
101
|
-
function h() {
|
|
102
|
-
return o = 0, E(n) && (r++, a = 0), f(n) && n++, n++, a++, t[n];
|
|
103
|
-
}
|
|
104
|
-
function L() {
|
|
105
|
-
return f(n + o) && o++, o++, t[n + o];
|
|
106
|
-
}
|
|
107
|
-
function m() {
|
|
108
|
-
n = 0, r = 1, a = 1, o = 0;
|
|
109
|
-
}
|
|
110
|
-
function g(v = 0) {
|
|
111
|
-
o = v;
|
|
112
|
-
}
|
|
113
|
-
function I() {
|
|
114
|
-
const v = n + o;
|
|
115
|
-
for (; v !== n; )
|
|
116
|
-
h();
|
|
117
|
-
o = 0;
|
|
118
|
-
}
|
|
119
|
-
return {
|
|
120
|
-
index: N,
|
|
121
|
-
line: T,
|
|
122
|
-
column: D,
|
|
123
|
-
peekOffset: k,
|
|
124
|
-
charAt: R,
|
|
125
|
-
currentChar: M,
|
|
126
|
-
currentPeek: p,
|
|
127
|
-
next: h,
|
|
128
|
-
peek: L,
|
|
129
|
-
reset: m,
|
|
130
|
-
resetPeek: g,
|
|
131
|
-
skipToPeek: I
|
|
132
|
-
};
|
|
133
|
-
}
|
|
134
|
-
const Ze = void 0, zr = ".", ln = "'", Qr = "tokenizer";
|
|
135
|
-
function qr(e, t = {}) {
|
|
136
|
-
const n = t.location !== !1, r = Kr(e), a = () => r.index(), o = () => Yr(r.line(), r.column(), r.index()), f = o(), d = a(), i = {
|
|
137
|
-
currentType: 13,
|
|
138
|
-
offset: d,
|
|
139
|
-
startLoc: f,
|
|
140
|
-
endLoc: f,
|
|
141
|
-
lastType: 13,
|
|
142
|
-
lastOffset: d,
|
|
143
|
-
lastStartLoc: f,
|
|
144
|
-
lastEndLoc: f,
|
|
145
|
-
braceNest: 0,
|
|
146
|
-
inLinked: !1,
|
|
147
|
-
text: ""
|
|
148
|
-
}, b = () => i, { onError: E } = t;
|
|
149
|
-
function N(l, s, c, ...y) {
|
|
150
|
-
const U = b();
|
|
151
|
-
if (s.column += c, s.offset += c, E) {
|
|
152
|
-
const W = n ? wt(U.startLoc, s) : null, u = Nt(l, W, {
|
|
153
|
-
domain: Qr,
|
|
154
|
-
args: y
|
|
155
|
-
});
|
|
156
|
-
E(u);
|
|
157
|
-
}
|
|
158
|
-
}
|
|
159
|
-
function T(l, s, c) {
|
|
160
|
-
l.endLoc = o(), l.currentType = s;
|
|
161
|
-
const y = { type: s };
|
|
162
|
-
return n && (y.loc = wt(l.startLoc, l.endLoc)), c != null && (y.value = c), y;
|
|
163
|
-
}
|
|
164
|
-
const D = (l) => T(
|
|
165
|
-
l,
|
|
166
|
-
13
|
|
167
|
-
/* TokenTypes.EOF */
|
|
168
|
-
);
|
|
169
|
-
function k(l, s) {
|
|
170
|
-
return l.currentChar() === s ? (l.next(), s) : (N(ne.EXPECTED_TOKEN, o(), 0, s), "");
|
|
171
|
-
}
|
|
172
|
-
function R(l) {
|
|
173
|
-
let s = "";
|
|
174
|
-
for (; l.currentPeek() === je || l.currentPeek() === ye; )
|
|
175
|
-
s += l.currentPeek(), l.peek();
|
|
176
|
-
return s;
|
|
177
|
-
}
|
|
178
|
-
function M(l) {
|
|
179
|
-
const s = R(l);
|
|
180
|
-
return l.skipToPeek(), s;
|
|
181
|
-
}
|
|
182
|
-
function p(l) {
|
|
183
|
-
if (l === Ze)
|
|
184
|
-
return !1;
|
|
185
|
-
const s = l.charCodeAt(0);
|
|
186
|
-
return s >= 97 && s <= 122 || // a-z
|
|
187
|
-
s >= 65 && s <= 90 || // A-Z
|
|
188
|
-
s === 95;
|
|
189
|
-
}
|
|
190
|
-
function h(l) {
|
|
191
|
-
if (l === Ze)
|
|
192
|
-
return !1;
|
|
193
|
-
const s = l.charCodeAt(0);
|
|
194
|
-
return s >= 48 && s <= 57;
|
|
195
|
-
}
|
|
196
|
-
function L(l, s) {
|
|
197
|
-
const { currentType: c } = s;
|
|
198
|
-
if (c !== 2)
|
|
199
|
-
return !1;
|
|
200
|
-
R(l);
|
|
201
|
-
const y = p(l.currentPeek());
|
|
202
|
-
return l.resetPeek(), y;
|
|
203
|
-
}
|
|
204
|
-
function m(l, s) {
|
|
205
|
-
const { currentType: c } = s;
|
|
206
|
-
if (c !== 2)
|
|
207
|
-
return !1;
|
|
208
|
-
R(l);
|
|
209
|
-
const y = l.currentPeek() === "-" ? l.peek() : l.currentPeek(), U = h(y);
|
|
210
|
-
return l.resetPeek(), U;
|
|
211
|
-
}
|
|
212
|
-
function g(l, s) {
|
|
213
|
-
const { currentType: c } = s;
|
|
214
|
-
if (c !== 2)
|
|
215
|
-
return !1;
|
|
216
|
-
R(l);
|
|
217
|
-
const y = l.currentPeek() === ln;
|
|
218
|
-
return l.resetPeek(), y;
|
|
219
|
-
}
|
|
220
|
-
function I(l, s) {
|
|
221
|
-
const { currentType: c } = s;
|
|
222
|
-
if (c !== 7)
|
|
223
|
-
return !1;
|
|
224
|
-
R(l);
|
|
225
|
-
const y = l.currentPeek() === ".";
|
|
226
|
-
return l.resetPeek(), y;
|
|
227
|
-
}
|
|
228
|
-
function v(l, s) {
|
|
229
|
-
const { currentType: c } = s;
|
|
230
|
-
if (c !== 8)
|
|
231
|
-
return !1;
|
|
232
|
-
R(l);
|
|
233
|
-
const y = p(l.currentPeek());
|
|
234
|
-
return l.resetPeek(), y;
|
|
235
|
-
}
|
|
236
|
-
function A(l, s) {
|
|
237
|
-
const { currentType: c } = s;
|
|
238
|
-
if (!(c === 7 || c === 11))
|
|
239
|
-
return !1;
|
|
240
|
-
R(l);
|
|
241
|
-
const y = l.currentPeek() === ":";
|
|
242
|
-
return l.resetPeek(), y;
|
|
243
|
-
}
|
|
244
|
-
function S(l, s) {
|
|
245
|
-
const { currentType: c } = s;
|
|
246
|
-
if (c !== 9)
|
|
247
|
-
return !1;
|
|
248
|
-
const y = () => {
|
|
249
|
-
const W = l.currentPeek();
|
|
250
|
-
return W === "{" ? p(l.peek()) : W === "@" || W === "|" || W === ":" || W === "." || W === je || !W ? !1 : W === ye ? (l.peek(), y()) : x(l, !1);
|
|
251
|
-
}, U = y();
|
|
252
|
-
return l.resetPeek(), U;
|
|
253
|
-
}
|
|
254
|
-
function H(l) {
|
|
255
|
-
R(l);
|
|
256
|
-
const s = l.currentPeek() === "|";
|
|
257
|
-
return l.resetPeek(), s;
|
|
258
|
-
}
|
|
259
|
-
function x(l, s = !0) {
|
|
260
|
-
const c = (U = !1, W = "") => {
|
|
261
|
-
const u = l.currentPeek();
|
|
262
|
-
return u === "{" || u === "@" || !u ? U : u === "|" ? !(W === je || W === ye) : u === je ? (l.peek(), c(!0, je)) : u === ye ? (l.peek(), c(!0, ye)) : !0;
|
|
263
|
-
}, y = c();
|
|
264
|
-
return s && l.resetPeek(), y;
|
|
265
|
-
}
|
|
266
|
-
function _(l, s) {
|
|
267
|
-
const c = l.currentChar();
|
|
268
|
-
return c === Ze ? Ze : s(c) ? (l.next(), c) : null;
|
|
269
|
-
}
|
|
270
|
-
function O(l) {
|
|
271
|
-
const s = l.charCodeAt(0);
|
|
272
|
-
return s >= 97 && s <= 122 || // a-z
|
|
273
|
-
s >= 65 && s <= 90 || // A-Z
|
|
274
|
-
s >= 48 && s <= 57 || // 0-9
|
|
275
|
-
s === 95 || // _
|
|
276
|
-
s === 36;
|
|
277
|
-
}
|
|
278
|
-
function P(l) {
|
|
279
|
-
return _(l, O);
|
|
280
|
-
}
|
|
281
|
-
function F(l) {
|
|
282
|
-
const s = l.charCodeAt(0);
|
|
283
|
-
return s >= 97 && s <= 122 || // a-z
|
|
284
|
-
s >= 65 && s <= 90 || // A-Z
|
|
285
|
-
s >= 48 && s <= 57 || // 0-9
|
|
286
|
-
s === 95 || // _
|
|
287
|
-
s === 36 || // $
|
|
288
|
-
s === 45;
|
|
289
|
-
}
|
|
290
|
-
function w(l) {
|
|
291
|
-
return _(l, F);
|
|
292
|
-
}
|
|
293
|
-
function V(l) {
|
|
294
|
-
const s = l.charCodeAt(0);
|
|
295
|
-
return s >= 48 && s <= 57;
|
|
296
|
-
}
|
|
297
|
-
function j(l) {
|
|
298
|
-
return _(l, V);
|
|
299
|
-
}
|
|
300
|
-
function Z(l) {
|
|
301
|
-
const s = l.charCodeAt(0);
|
|
302
|
-
return s >= 48 && s <= 57 || // 0-9
|
|
303
|
-
s >= 65 && s <= 70 || // A-F
|
|
304
|
-
s >= 97 && s <= 102;
|
|
305
|
-
}
|
|
306
|
-
function X(l) {
|
|
307
|
-
return _(l, Z);
|
|
308
|
-
}
|
|
309
|
-
function te(l) {
|
|
310
|
-
let s = "", c = "";
|
|
311
|
-
for (; s = j(l); )
|
|
312
|
-
c += s;
|
|
313
|
-
return c;
|
|
314
|
-
}
|
|
315
|
-
function z(l) {
|
|
316
|
-
let s = "";
|
|
317
|
-
for (; ; ) {
|
|
318
|
-
const c = l.currentChar();
|
|
319
|
-
if (c === "{" || c === "}" || c === "@" || c === "|" || !c)
|
|
320
|
-
break;
|
|
321
|
-
if (c === je || c === ye)
|
|
322
|
-
if (x(l))
|
|
323
|
-
s += c, l.next();
|
|
324
|
-
else {
|
|
325
|
-
if (H(l))
|
|
326
|
-
break;
|
|
327
|
-
s += c, l.next();
|
|
328
|
-
}
|
|
329
|
-
else
|
|
330
|
-
s += c, l.next();
|
|
331
|
-
}
|
|
332
|
-
return s;
|
|
333
|
-
}
|
|
334
|
-
function de(l) {
|
|
335
|
-
M(l);
|
|
336
|
-
let s = "", c = "";
|
|
337
|
-
for (; s = w(l); )
|
|
338
|
-
c += s;
|
|
339
|
-
return l.currentChar() === Ze && N(ne.UNTERMINATED_CLOSING_BRACE, o(), 0), c;
|
|
340
|
-
}
|
|
341
|
-
function ve(l) {
|
|
342
|
-
M(l);
|
|
343
|
-
let s = "";
|
|
344
|
-
return l.currentChar() === "-" ? (l.next(), s += `-${te(l)}`) : s += te(l), l.currentChar() === Ze && N(ne.UNTERMINATED_CLOSING_BRACE, o(), 0), s;
|
|
345
|
-
}
|
|
346
|
-
function he(l) {
|
|
347
|
-
return l !== ln && l !== ye;
|
|
348
|
-
}
|
|
349
|
-
function ae(l) {
|
|
350
|
-
M(l), k(l, "'");
|
|
351
|
-
let s = "", c = "";
|
|
352
|
-
for (; s = _(l, he); )
|
|
353
|
-
s === "\\" ? c += le(l) : c += s;
|
|
354
|
-
const y = l.currentChar();
|
|
355
|
-
return y === ye || y === Ze ? (N(ne.UNTERMINATED_SINGLE_QUOTE_IN_PLACEHOLDER, o(), 0), y === ye && (l.next(), k(l, "'")), c) : (k(l, "'"), c);
|
|
356
|
-
}
|
|
357
|
-
function le(l) {
|
|
358
|
-
const s = l.currentChar();
|
|
359
|
-
switch (s) {
|
|
360
|
-
case "\\":
|
|
361
|
-
case "'":
|
|
362
|
-
return l.next(), `\\${s}`;
|
|
363
|
-
case "u":
|
|
364
|
-
return Ae(l, s, 4);
|
|
365
|
-
case "U":
|
|
366
|
-
return Ae(l, s, 6);
|
|
367
|
-
default:
|
|
368
|
-
return N(ne.UNKNOWN_ESCAPE_SEQUENCE, o(), 0, s), "";
|
|
369
|
-
}
|
|
370
|
-
}
|
|
371
|
-
function Ae(l, s, c) {
|
|
372
|
-
k(l, s);
|
|
373
|
-
let y = "";
|
|
374
|
-
for (let U = 0; U < c; U++) {
|
|
375
|
-
const W = X(l);
|
|
376
|
-
if (!W) {
|
|
377
|
-
N(ne.INVALID_UNICODE_ESCAPE_SEQUENCE, o(), 0, `\\${s}${y}${l.currentChar()}`);
|
|
378
|
-
break;
|
|
379
|
-
}
|
|
380
|
-
y += W;
|
|
381
|
-
}
|
|
382
|
-
return `\\${s}${y}`;
|
|
383
|
-
}
|
|
384
|
-
function Y(l) {
|
|
385
|
-
return l !== "{" && l !== "}" && l !== je && l !== ye;
|
|
386
|
-
}
|
|
387
|
-
function fe(l) {
|
|
388
|
-
M(l);
|
|
389
|
-
let s = "", c = "";
|
|
390
|
-
for (; s = _(l, Y); )
|
|
391
|
-
c += s;
|
|
392
|
-
return c;
|
|
393
|
-
}
|
|
394
|
-
function $e(l) {
|
|
395
|
-
let s = "", c = "";
|
|
396
|
-
for (; s = P(l); )
|
|
397
|
-
c += s;
|
|
398
|
-
return c;
|
|
399
|
-
}
|
|
400
|
-
function Qe(l) {
|
|
401
|
-
const s = (c) => {
|
|
402
|
-
const y = l.currentChar();
|
|
403
|
-
return y === "{" || y === "@" || y === "|" || y === "(" || y === ")" || !y || y === je ? c : (c += y, l.next(), s(c));
|
|
404
|
-
};
|
|
405
|
-
return s("");
|
|
406
|
-
}
|
|
407
|
-
function Ve(l) {
|
|
408
|
-
M(l);
|
|
409
|
-
const s = k(
|
|
410
|
-
l,
|
|
411
|
-
"|"
|
|
412
|
-
/* TokenChars.Pipe */
|
|
413
|
-
);
|
|
414
|
-
return M(l), s;
|
|
415
|
-
}
|
|
416
|
-
function we(l, s) {
|
|
417
|
-
let c = null;
|
|
418
|
-
switch (l.currentChar()) {
|
|
419
|
-
case "{":
|
|
420
|
-
return s.braceNest >= 1 && N(ne.NOT_ALLOW_NEST_PLACEHOLDER, o(), 0), l.next(), c = T(
|
|
421
|
-
s,
|
|
422
|
-
2,
|
|
423
|
-
"{"
|
|
424
|
-
/* TokenChars.BraceLeft */
|
|
425
|
-
), M(l), s.braceNest++, c;
|
|
426
|
-
case "}":
|
|
427
|
-
return s.braceNest > 0 && s.currentType === 2 && N(ne.EMPTY_PLACEHOLDER, o(), 0), l.next(), c = T(
|
|
428
|
-
s,
|
|
429
|
-
3,
|
|
430
|
-
"}"
|
|
431
|
-
/* TokenChars.BraceRight */
|
|
432
|
-
), s.braceNest--, s.braceNest > 0 && M(l), s.inLinked && s.braceNest === 0 && (s.inLinked = !1), c;
|
|
433
|
-
case "@":
|
|
434
|
-
return s.braceNest > 0 && N(ne.UNTERMINATED_CLOSING_BRACE, o(), 0), c = Fe(l, s) || D(s), s.braceNest = 0, c;
|
|
435
|
-
default: {
|
|
436
|
-
let U = !0, W = !0, u = !0;
|
|
437
|
-
if (H(l))
|
|
438
|
-
return s.braceNest > 0 && N(ne.UNTERMINATED_CLOSING_BRACE, o(), 0), c = T(s, 1, Ve(l)), s.braceNest = 0, s.inLinked = !1, c;
|
|
439
|
-
if (s.braceNest > 0 && (s.currentType === 4 || s.currentType === 5 || s.currentType === 6))
|
|
440
|
-
return N(ne.UNTERMINATED_CLOSING_BRACE, o(), 0), s.braceNest = 0, Ge(l, s);
|
|
441
|
-
if (U = L(l, s))
|
|
442
|
-
return c = T(s, 4, de(l)), M(l), c;
|
|
443
|
-
if (W = m(l, s))
|
|
444
|
-
return c = T(s, 5, ve(l)), M(l), c;
|
|
445
|
-
if (u = g(l, s))
|
|
446
|
-
return c = T(s, 6, ae(l)), M(l), c;
|
|
447
|
-
if (!U && !W && !u)
|
|
448
|
-
return c = T(s, 12, fe(l)), N(ne.INVALID_TOKEN_IN_PLACEHOLDER, o(), 0, c.value), M(l), c;
|
|
449
|
-
break;
|
|
450
|
-
}
|
|
451
|
-
}
|
|
452
|
-
return c;
|
|
453
|
-
}
|
|
454
|
-
function Fe(l, s) {
|
|
455
|
-
const { currentType: c } = s;
|
|
456
|
-
let y = null;
|
|
457
|
-
const U = l.currentChar();
|
|
458
|
-
switch ((c === 7 || c === 8 || c === 11 || c === 9) && (U === ye || U === je) && N(ne.INVALID_LINKED_FORMAT, o(), 0), U) {
|
|
459
|
-
case "@":
|
|
460
|
-
return l.next(), y = T(
|
|
461
|
-
s,
|
|
462
|
-
7,
|
|
463
|
-
"@"
|
|
464
|
-
/* TokenChars.LinkedAlias */
|
|
465
|
-
), s.inLinked = !0, y;
|
|
466
|
-
case ".":
|
|
467
|
-
return M(l), l.next(), T(
|
|
468
|
-
s,
|
|
469
|
-
8,
|
|
470
|
-
"."
|
|
471
|
-
/* TokenChars.LinkedDot */
|
|
472
|
-
);
|
|
473
|
-
case ":":
|
|
474
|
-
return M(l), l.next(), T(
|
|
475
|
-
s,
|
|
476
|
-
9,
|
|
477
|
-
":"
|
|
478
|
-
/* TokenChars.LinkedDelimiter */
|
|
479
|
-
);
|
|
480
|
-
default:
|
|
481
|
-
return H(l) ? (y = T(s, 1, Ve(l)), s.braceNest = 0, s.inLinked = !1, y) : I(l, s) || A(l, s) ? (M(l), Fe(l, s)) : v(l, s) ? (M(l), T(s, 11, $e(l))) : S(l, s) ? (M(l), U === "{" ? we(l, s) || y : T(s, 10, Qe(l))) : (c === 7 && N(ne.INVALID_LINKED_FORMAT, o(), 0), s.braceNest = 0, s.inLinked = !1, Ge(l, s));
|
|
482
|
-
}
|
|
483
|
-
}
|
|
484
|
-
function Ge(l, s) {
|
|
485
|
-
let c = {
|
|
486
|
-
type: 13
|
|
487
|
-
/* TokenTypes.EOF */
|
|
488
|
-
};
|
|
489
|
-
if (s.braceNest > 0)
|
|
490
|
-
return we(l, s) || D(s);
|
|
491
|
-
if (s.inLinked)
|
|
492
|
-
return Fe(l, s) || D(s);
|
|
493
|
-
switch (l.currentChar()) {
|
|
494
|
-
case "{":
|
|
495
|
-
return we(l, s) || D(s);
|
|
496
|
-
case "}":
|
|
497
|
-
return N(ne.UNBALANCED_CLOSING_BRACE, o(), 0), l.next(), T(
|
|
498
|
-
s,
|
|
499
|
-
3,
|
|
500
|
-
"}"
|
|
501
|
-
/* TokenChars.BraceRight */
|
|
502
|
-
);
|
|
503
|
-
case "@":
|
|
504
|
-
return Fe(l, s) || D(s);
|
|
505
|
-
default: {
|
|
506
|
-
if (H(l))
|
|
507
|
-
return c = T(s, 1, Ve(l)), s.braceNest = 0, s.inLinked = !1, c;
|
|
508
|
-
if (x(l))
|
|
509
|
-
return T(s, 0, z(l));
|
|
510
|
-
break;
|
|
511
|
-
}
|
|
512
|
-
}
|
|
513
|
-
return c;
|
|
514
|
-
}
|
|
515
|
-
function Pe() {
|
|
516
|
-
const { currentType: l, offset: s, startLoc: c, endLoc: y } = i;
|
|
517
|
-
return i.lastType = l, i.lastOffset = s, i.lastStartLoc = c, i.lastEndLoc = y, i.offset = a(), i.startLoc = o(), r.currentChar() === Ze ? T(
|
|
518
|
-
i,
|
|
519
|
-
13
|
|
520
|
-
/* TokenTypes.EOF */
|
|
521
|
-
) : Ge(r, i);
|
|
522
|
-
}
|
|
523
|
-
return {
|
|
524
|
-
nextToken: Pe,
|
|
525
|
-
currentOffset: a,
|
|
526
|
-
currentPosition: o,
|
|
527
|
-
context: b
|
|
528
|
-
};
|
|
529
|
-
}
|
|
530
|
-
const es = "parser", ts = /(?:\\\\|\\'|\\u([0-9a-fA-F]{4})|\\U([0-9a-fA-F]{6}))/g;
|
|
531
|
-
function ns(e, t, n) {
|
|
532
|
-
switch (e) {
|
|
533
|
-
case "\\\\":
|
|
534
|
-
return "\\";
|
|
535
|
-
case "\\'":
|
|
536
|
-
return "'";
|
|
537
|
-
default: {
|
|
538
|
-
const r = parseInt(t || n, 16);
|
|
539
|
-
return r <= 55295 || r >= 57344 ? String.fromCodePoint(r) : "�";
|
|
540
|
-
}
|
|
541
|
-
}
|
|
542
|
-
}
|
|
543
|
-
function rs(e = {}) {
|
|
544
|
-
const t = e.location !== !1, { onError: n } = e;
|
|
545
|
-
function r(p, h, L, m, ...g) {
|
|
546
|
-
const I = p.currentPosition();
|
|
547
|
-
if (I.offset += m, I.column += m, n) {
|
|
548
|
-
const v = t ? wt(L, I) : null, A = Nt(h, v, {
|
|
549
|
-
domain: es,
|
|
550
|
-
args: g
|
|
551
|
-
});
|
|
552
|
-
n(A);
|
|
553
|
-
}
|
|
554
|
-
}
|
|
555
|
-
function a(p, h, L) {
|
|
556
|
-
const m = { type: p };
|
|
557
|
-
return t && (m.start = h, m.end = h, m.loc = { start: L, end: L }), m;
|
|
558
|
-
}
|
|
559
|
-
function o(p, h, L, m) {
|
|
560
|
-
t && (p.end = h, p.loc && (p.loc.end = L));
|
|
561
|
-
}
|
|
562
|
-
function f(p, h) {
|
|
563
|
-
const L = p.context(), m = a(3, L.offset, L.startLoc);
|
|
564
|
-
return m.value = h, o(m, p.currentOffset(), p.currentPosition()), m;
|
|
565
|
-
}
|
|
566
|
-
function d(p, h) {
|
|
567
|
-
const L = p.context(), { lastOffset: m, lastStartLoc: g } = L, I = a(5, m, g);
|
|
568
|
-
return I.index = parseInt(h, 10), p.nextToken(), o(I, p.currentOffset(), p.currentPosition()), I;
|
|
569
|
-
}
|
|
570
|
-
function i(p, h) {
|
|
571
|
-
const L = p.context(), { lastOffset: m, lastStartLoc: g } = L, I = a(4, m, g);
|
|
572
|
-
return I.key = h, p.nextToken(), o(I, p.currentOffset(), p.currentPosition()), I;
|
|
573
|
-
}
|
|
574
|
-
function b(p, h) {
|
|
575
|
-
const L = p.context(), { lastOffset: m, lastStartLoc: g } = L, I = a(9, m, g);
|
|
576
|
-
return I.value = h.replace(ts, ns), p.nextToken(), o(I, p.currentOffset(), p.currentPosition()), I;
|
|
577
|
-
}
|
|
578
|
-
function E(p) {
|
|
579
|
-
const h = p.nextToken(), L = p.context(), { lastOffset: m, lastStartLoc: g } = L, I = a(8, m, g);
|
|
580
|
-
return h.type !== 11 ? (r(p, ne.UNEXPECTED_EMPTY_LINKED_MODIFIER, L.lastStartLoc, 0), I.value = "", o(I, m, g), {
|
|
581
|
-
nextConsumeToken: h,
|
|
582
|
-
node: I
|
|
583
|
-
}) : (h.value == null && r(p, ne.UNEXPECTED_LEXICAL_ANALYSIS, L.lastStartLoc, 0, ke(h)), I.value = h.value || "", o(I, p.currentOffset(), p.currentPosition()), {
|
|
584
|
-
node: I
|
|
585
|
-
});
|
|
586
|
-
}
|
|
587
|
-
function N(p, h) {
|
|
588
|
-
const L = p.context(), m = a(7, L.offset, L.startLoc);
|
|
589
|
-
return m.value = h, o(m, p.currentOffset(), p.currentPosition()), m;
|
|
590
|
-
}
|
|
591
|
-
function T(p) {
|
|
592
|
-
const h = p.context(), L = a(6, h.offset, h.startLoc);
|
|
593
|
-
let m = p.nextToken();
|
|
594
|
-
if (m.type === 8) {
|
|
595
|
-
const g = E(p);
|
|
596
|
-
L.modifier = g.node, m = g.nextConsumeToken || p.nextToken();
|
|
597
|
-
}
|
|
598
|
-
switch (m.type !== 9 && r(p, ne.UNEXPECTED_LEXICAL_ANALYSIS, h.lastStartLoc, 0, ke(m)), m = p.nextToken(), m.type === 2 && (m = p.nextToken()), m.type) {
|
|
599
|
-
case 10:
|
|
600
|
-
m.value == null && r(p, ne.UNEXPECTED_LEXICAL_ANALYSIS, h.lastStartLoc, 0, ke(m)), L.key = N(p, m.value || "");
|
|
601
|
-
break;
|
|
602
|
-
case 4:
|
|
603
|
-
m.value == null && r(p, ne.UNEXPECTED_LEXICAL_ANALYSIS, h.lastStartLoc, 0, ke(m)), L.key = i(p, m.value || "");
|
|
604
|
-
break;
|
|
605
|
-
case 5:
|
|
606
|
-
m.value == null && r(p, ne.UNEXPECTED_LEXICAL_ANALYSIS, h.lastStartLoc, 0, ke(m)), L.key = d(p, m.value || "");
|
|
607
|
-
break;
|
|
608
|
-
case 6:
|
|
609
|
-
m.value == null && r(p, ne.UNEXPECTED_LEXICAL_ANALYSIS, h.lastStartLoc, 0, ke(m)), L.key = b(p, m.value || "");
|
|
610
|
-
break;
|
|
611
|
-
default: {
|
|
612
|
-
r(p, ne.UNEXPECTED_EMPTY_LINKED_KEY, h.lastStartLoc, 0);
|
|
613
|
-
const g = p.context(), I = a(7, g.offset, g.startLoc);
|
|
614
|
-
return I.value = "", o(I, g.offset, g.startLoc), L.key = I, o(L, g.offset, g.startLoc), {
|
|
615
|
-
nextConsumeToken: m,
|
|
616
|
-
node: L
|
|
617
|
-
};
|
|
618
|
-
}
|
|
619
|
-
}
|
|
620
|
-
return o(L, p.currentOffset(), p.currentPosition()), {
|
|
621
|
-
node: L
|
|
622
|
-
};
|
|
623
|
-
}
|
|
624
|
-
function D(p) {
|
|
625
|
-
const h = p.context(), L = h.currentType === 1 ? p.currentOffset() : h.offset, m = h.currentType === 1 ? h.endLoc : h.startLoc, g = a(2, L, m);
|
|
626
|
-
g.items = [];
|
|
627
|
-
let I = null;
|
|
628
|
-
do {
|
|
629
|
-
const S = I || p.nextToken();
|
|
630
|
-
switch (I = null, S.type) {
|
|
631
|
-
case 0:
|
|
632
|
-
S.value == null && r(p, ne.UNEXPECTED_LEXICAL_ANALYSIS, h.lastStartLoc, 0, ke(S)), g.items.push(f(p, S.value || ""));
|
|
633
|
-
break;
|
|
634
|
-
case 5:
|
|
635
|
-
S.value == null && r(p, ne.UNEXPECTED_LEXICAL_ANALYSIS, h.lastStartLoc, 0, ke(S)), g.items.push(d(p, S.value || ""));
|
|
636
|
-
break;
|
|
637
|
-
case 4:
|
|
638
|
-
S.value == null && r(p, ne.UNEXPECTED_LEXICAL_ANALYSIS, h.lastStartLoc, 0, ke(S)), g.items.push(i(p, S.value || ""));
|
|
639
|
-
break;
|
|
640
|
-
case 6:
|
|
641
|
-
S.value == null && r(p, ne.UNEXPECTED_LEXICAL_ANALYSIS, h.lastStartLoc, 0, ke(S)), g.items.push(b(p, S.value || ""));
|
|
642
|
-
break;
|
|
643
|
-
case 7: {
|
|
644
|
-
const H = T(p);
|
|
645
|
-
g.items.push(H.node), I = H.nextConsumeToken || null;
|
|
646
|
-
break;
|
|
647
|
-
}
|
|
648
|
-
}
|
|
649
|
-
} while (h.currentType !== 13 && h.currentType !== 1);
|
|
650
|
-
const v = h.currentType === 1 ? h.lastOffset : p.currentOffset(), A = h.currentType === 1 ? h.lastEndLoc : p.currentPosition();
|
|
651
|
-
return o(g, v, A), g;
|
|
652
|
-
}
|
|
653
|
-
function k(p, h, L, m) {
|
|
654
|
-
const g = p.context();
|
|
655
|
-
let I = m.items.length === 0;
|
|
656
|
-
const v = a(1, h, L);
|
|
657
|
-
v.cases = [], v.cases.push(m);
|
|
658
|
-
do {
|
|
659
|
-
const A = D(p);
|
|
660
|
-
I || (I = A.items.length === 0), v.cases.push(A);
|
|
661
|
-
} while (g.currentType !== 13);
|
|
662
|
-
return I && r(p, ne.MUST_HAVE_MESSAGES_IN_PLURAL, L, 0), o(v, p.currentOffset(), p.currentPosition()), v;
|
|
663
|
-
}
|
|
664
|
-
function R(p) {
|
|
665
|
-
const h = p.context(), { offset: L, startLoc: m } = h, g = D(p);
|
|
666
|
-
return h.currentType === 13 ? g : k(p, L, m, g);
|
|
667
|
-
}
|
|
668
|
-
function M(p) {
|
|
669
|
-
const h = qr(p, ge({}, e)), L = h.context(), m = a(0, L.offset, L.startLoc);
|
|
670
|
-
return t && m.loc && (m.loc.source = p), m.body = R(h), e.onCacheKey && (m.cacheKey = e.onCacheKey(p)), L.currentType !== 13 && r(h, ne.UNEXPECTED_LEXICAL_ANALYSIS, L.lastStartLoc, 0, p[L.offset] || ""), o(m, h.currentOffset(), h.currentPosition()), m;
|
|
671
|
-
}
|
|
672
|
-
return { parse: M };
|
|
673
|
-
}
|
|
674
|
-
function ke(e) {
|
|
675
|
-
if (e.type === 13)
|
|
676
|
-
return "EOF";
|
|
677
|
-
const t = (e.value || "").replace(/\r?\n/gu, "\\n");
|
|
678
|
-
return t.length > 10 ? t.slice(0, 9) + "…" : t;
|
|
679
|
-
}
|
|
680
|
-
function ss(e, t = {}) {
|
|
681
|
-
const n = {
|
|
682
|
-
ast: e,
|
|
683
|
-
helpers: /* @__PURE__ */ new Set()
|
|
684
|
-
};
|
|
685
|
-
return { context: () => n, helper: (o) => (n.helpers.add(o), o) };
|
|
686
|
-
}
|
|
687
|
-
function cn(e, t) {
|
|
688
|
-
for (let n = 0; n < e.length; n++)
|
|
689
|
-
$t(e[n], t);
|
|
690
|
-
}
|
|
691
|
-
function $t(e, t) {
|
|
692
|
-
switch (e.type) {
|
|
693
|
-
case 1:
|
|
694
|
-
cn(e.cases, t), t.helper(
|
|
695
|
-
"plural"
|
|
696
|
-
/* HelperNameMap.PLURAL */
|
|
697
|
-
);
|
|
698
|
-
break;
|
|
699
|
-
case 2:
|
|
700
|
-
cn(e.items, t);
|
|
701
|
-
break;
|
|
702
|
-
case 6: {
|
|
703
|
-
$t(e.key, t), t.helper(
|
|
704
|
-
"linked"
|
|
705
|
-
/* HelperNameMap.LINKED */
|
|
706
|
-
), t.helper(
|
|
707
|
-
"type"
|
|
708
|
-
/* HelperNameMap.TYPE */
|
|
709
|
-
);
|
|
710
|
-
break;
|
|
711
|
-
}
|
|
712
|
-
case 5:
|
|
713
|
-
t.helper(
|
|
714
|
-
"interpolate"
|
|
715
|
-
/* HelperNameMap.INTERPOLATE */
|
|
716
|
-
), t.helper(
|
|
717
|
-
"list"
|
|
718
|
-
/* HelperNameMap.LIST */
|
|
719
|
-
);
|
|
720
|
-
break;
|
|
721
|
-
case 4:
|
|
722
|
-
t.helper(
|
|
723
|
-
"interpolate"
|
|
724
|
-
/* HelperNameMap.INTERPOLATE */
|
|
725
|
-
), t.helper(
|
|
726
|
-
"named"
|
|
727
|
-
/* HelperNameMap.NAMED */
|
|
728
|
-
);
|
|
729
|
-
break;
|
|
730
|
-
}
|
|
731
|
-
}
|
|
732
|
-
function as(e, t = {}) {
|
|
733
|
-
const n = ss(e);
|
|
734
|
-
n.helper(
|
|
735
|
-
"normalize"
|
|
736
|
-
/* HelperNameMap.NORMALIZE */
|
|
737
|
-
), e.body && $t(e.body, n);
|
|
738
|
-
const r = n.context();
|
|
739
|
-
e.helpers = Array.from(r.helpers);
|
|
740
|
-
}
|
|
741
|
-
function os(e) {
|
|
742
|
-
const t = e.body;
|
|
743
|
-
return t.type === 2 ? un(t) : t.cases.forEach((n) => un(n)), e;
|
|
744
|
-
}
|
|
745
|
-
function un(e) {
|
|
746
|
-
if (e.items.length === 1) {
|
|
747
|
-
const t = e.items[0];
|
|
748
|
-
(t.type === 3 || t.type === 9) && (e.static = t.value, delete t.value);
|
|
749
|
-
} else {
|
|
750
|
-
const t = [];
|
|
751
|
-
for (let n = 0; n < e.items.length; n++) {
|
|
752
|
-
const r = e.items[n];
|
|
753
|
-
if (!(r.type === 3 || r.type === 9) || r.value == null)
|
|
754
|
-
break;
|
|
755
|
-
t.push(r.value);
|
|
756
|
-
}
|
|
757
|
-
if (t.length === e.items.length) {
|
|
758
|
-
e.static = Ht(t);
|
|
759
|
-
for (let n = 0; n < e.items.length; n++) {
|
|
760
|
-
const r = e.items[n];
|
|
761
|
-
(r.type === 3 || r.type === 9) && delete r.value;
|
|
762
|
-
}
|
|
763
|
-
}
|
|
764
|
-
}
|
|
765
|
-
}
|
|
766
|
-
function et(e) {
|
|
767
|
-
switch (e.t = e.type, e.type) {
|
|
768
|
-
case 0: {
|
|
769
|
-
const t = e;
|
|
770
|
-
et(t.body), t.b = t.body, delete t.body;
|
|
771
|
-
break;
|
|
772
|
-
}
|
|
773
|
-
case 1: {
|
|
774
|
-
const t = e, n = t.cases;
|
|
775
|
-
for (let r = 0; r < n.length; r++)
|
|
776
|
-
et(n[r]);
|
|
777
|
-
t.c = n, delete t.cases;
|
|
778
|
-
break;
|
|
779
|
-
}
|
|
780
|
-
case 2: {
|
|
781
|
-
const t = e, n = t.items;
|
|
782
|
-
for (let r = 0; r < n.length; r++)
|
|
783
|
-
et(n[r]);
|
|
784
|
-
t.i = n, delete t.items, t.static && (t.s = t.static, delete t.static);
|
|
785
|
-
break;
|
|
786
|
-
}
|
|
787
|
-
case 3:
|
|
788
|
-
case 9:
|
|
789
|
-
case 8:
|
|
790
|
-
case 7: {
|
|
791
|
-
const t = e;
|
|
792
|
-
t.value && (t.v = t.value, delete t.value);
|
|
793
|
-
break;
|
|
794
|
-
}
|
|
795
|
-
case 6: {
|
|
796
|
-
const t = e;
|
|
797
|
-
et(t.key), t.k = t.key, delete t.key, t.modifier && (et(t.modifier), t.m = t.modifier, delete t.modifier);
|
|
798
|
-
break;
|
|
799
|
-
}
|
|
800
|
-
case 5: {
|
|
801
|
-
const t = e;
|
|
802
|
-
t.i = t.index, delete t.index;
|
|
803
|
-
break;
|
|
804
|
-
}
|
|
805
|
-
case 4: {
|
|
806
|
-
const t = e;
|
|
807
|
-
t.k = t.key, delete t.key;
|
|
808
|
-
break;
|
|
809
|
-
}
|
|
810
|
-
}
|
|
811
|
-
delete e.type;
|
|
812
|
-
}
|
|
813
|
-
function ls(e, t) {
|
|
814
|
-
const { filename: n, breakLineCode: r, needIndent: a } = t, o = t.location !== !1, f = {
|
|
815
|
-
filename: n,
|
|
816
|
-
code: "",
|
|
817
|
-
column: 1,
|
|
818
|
-
line: 1,
|
|
819
|
-
offset: 0,
|
|
820
|
-
map: void 0,
|
|
821
|
-
breakLineCode: r,
|
|
822
|
-
needIndent: a,
|
|
823
|
-
indentLevel: 0
|
|
824
|
-
};
|
|
825
|
-
o && e.loc && (f.source = e.loc.source);
|
|
826
|
-
const d = () => f;
|
|
827
|
-
function i(R, M) {
|
|
828
|
-
f.code += R;
|
|
829
|
-
}
|
|
830
|
-
function b(R, M = !0) {
|
|
831
|
-
const p = M ? r : "";
|
|
832
|
-
i(a ? p + " ".repeat(R) : p);
|
|
833
|
-
}
|
|
834
|
-
function E(R = !0) {
|
|
835
|
-
const M = ++f.indentLevel;
|
|
836
|
-
R && b(M);
|
|
837
|
-
}
|
|
838
|
-
function N(R = !0) {
|
|
839
|
-
const M = --f.indentLevel;
|
|
840
|
-
R && b(M);
|
|
841
|
-
}
|
|
842
|
-
function T() {
|
|
843
|
-
b(f.indentLevel);
|
|
844
|
-
}
|
|
845
|
-
return {
|
|
846
|
-
context: d,
|
|
847
|
-
push: i,
|
|
848
|
-
indent: E,
|
|
849
|
-
deindent: N,
|
|
850
|
-
newline: T,
|
|
851
|
-
helper: (R) => `_${R}`,
|
|
852
|
-
needIndent: () => f.needIndent
|
|
853
|
-
};
|
|
854
|
-
}
|
|
855
|
-
function is(e, t) {
|
|
856
|
-
const { helper: n } = e;
|
|
857
|
-
e.push(`${n(
|
|
858
|
-
"linked"
|
|
859
|
-
/* HelperNameMap.LINKED */
|
|
860
|
-
)}(`), at(e, t.key), t.modifier ? (e.push(", "), at(e, t.modifier), e.push(", _type")) : e.push(", undefined, _type"), e.push(")");
|
|
861
|
-
}
|
|
862
|
-
function cs(e, t) {
|
|
863
|
-
const { helper: n, needIndent: r } = e;
|
|
864
|
-
e.push(`${n(
|
|
865
|
-
"normalize"
|
|
866
|
-
/* HelperNameMap.NORMALIZE */
|
|
867
|
-
)}([`), e.indent(r());
|
|
868
|
-
const a = t.items.length;
|
|
869
|
-
for (let o = 0; o < a && (at(e, t.items[o]), o !== a - 1); o++)
|
|
870
|
-
e.push(", ");
|
|
871
|
-
e.deindent(r()), e.push("])");
|
|
872
|
-
}
|
|
873
|
-
function us(e, t) {
|
|
874
|
-
const { helper: n, needIndent: r } = e;
|
|
875
|
-
if (t.cases.length > 1) {
|
|
876
|
-
e.push(`${n(
|
|
877
|
-
"plural"
|
|
878
|
-
/* HelperNameMap.PLURAL */
|
|
879
|
-
)}([`), e.indent(r());
|
|
880
|
-
const a = t.cases.length;
|
|
881
|
-
for (let o = 0; o < a && (at(e, t.cases[o]), o !== a - 1); o++)
|
|
882
|
-
e.push(", ");
|
|
883
|
-
e.deindent(r()), e.push("])");
|
|
884
|
-
}
|
|
885
|
-
}
|
|
886
|
-
function ms(e, t) {
|
|
887
|
-
t.body ? at(e, t.body) : e.push("null");
|
|
888
|
-
}
|
|
889
|
-
function at(e, t) {
|
|
890
|
-
const { helper: n } = e;
|
|
891
|
-
switch (t.type) {
|
|
892
|
-
case 0:
|
|
893
|
-
ms(e, t);
|
|
894
|
-
break;
|
|
895
|
-
case 1:
|
|
896
|
-
us(e, t);
|
|
897
|
-
break;
|
|
898
|
-
case 2:
|
|
899
|
-
cs(e, t);
|
|
900
|
-
break;
|
|
901
|
-
case 6:
|
|
902
|
-
is(e, t);
|
|
903
|
-
break;
|
|
904
|
-
case 8:
|
|
905
|
-
e.push(JSON.stringify(t.value), t);
|
|
906
|
-
break;
|
|
907
|
-
case 7:
|
|
908
|
-
e.push(JSON.stringify(t.value), t);
|
|
909
|
-
break;
|
|
910
|
-
case 5:
|
|
911
|
-
e.push(`${n(
|
|
912
|
-
"interpolate"
|
|
913
|
-
/* HelperNameMap.INTERPOLATE */
|
|
914
|
-
)}(${n(
|
|
915
|
-
"list"
|
|
916
|
-
/* HelperNameMap.LIST */
|
|
917
|
-
)}(${t.index}))`, t);
|
|
918
|
-
break;
|
|
919
|
-
case 4:
|
|
920
|
-
e.push(`${n(
|
|
921
|
-
"interpolate"
|
|
922
|
-
/* HelperNameMap.INTERPOLATE */
|
|
923
|
-
)}(${n(
|
|
924
|
-
"named"
|
|
925
|
-
/* HelperNameMap.NAMED */
|
|
926
|
-
)}(${JSON.stringify(t.key)}))`, t);
|
|
927
|
-
break;
|
|
928
|
-
case 9:
|
|
929
|
-
e.push(JSON.stringify(t.value), t);
|
|
930
|
-
break;
|
|
931
|
-
case 3:
|
|
932
|
-
e.push(JSON.stringify(t.value), t);
|
|
933
|
-
break;
|
|
934
|
-
}
|
|
935
|
-
}
|
|
936
|
-
const ds = (e, t = {}) => {
|
|
937
|
-
const n = G(t.mode) ? t.mode : "normal", r = G(t.filename) ? t.filename : "message.intl";
|
|
938
|
-
t.sourceMap;
|
|
939
|
-
const a = t.breakLineCode != null ? t.breakLineCode : n === "arrow" ? ";" : `
|
|
940
|
-
`, o = t.needIndent ? t.needIndent : n !== "arrow", f = e.helpers || [], d = ls(e, {
|
|
941
|
-
filename: r,
|
|
942
|
-
breakLineCode: a,
|
|
943
|
-
needIndent: o
|
|
944
|
-
});
|
|
945
|
-
d.push(n === "normal" ? "function __msg__ (ctx) {" : "(ctx) => {"), d.indent(o), f.length > 0 && (d.push(`const { ${Ht(f.map((E) => `${E}: _${E}`), ", ")} } = ctx`), d.newline()), d.push("return "), at(d, e), d.deindent(o), d.push("}"), delete e.helpers;
|
|
946
|
-
const { code: i, map: b } = d.context();
|
|
947
|
-
return {
|
|
948
|
-
ast: e,
|
|
949
|
-
code: i,
|
|
950
|
-
map: b ? b.toJSON() : void 0
|
|
951
|
-
// eslint-disable-line @typescript-eslint/no-explicit-any
|
|
952
|
-
};
|
|
953
|
-
};
|
|
954
|
-
function fs(e, t = {}) {
|
|
955
|
-
const n = ge({}, t), r = !!n.jit, a = !!n.minify, o = n.optimize == null ? !0 : n.optimize, d = rs(n).parse(e);
|
|
956
|
-
return r ? (o && os(d), a && et(d), { ast: d, code: "" }) : (as(d, n), ds(d, n));
|
|
957
|
-
}
|
|
958
|
-
var _s = { env: { NODE_ENV: "production" } };
|
|
959
|
-
function ps() {
|
|
960
|
-
typeof __INTLIFY_PROD_DEVTOOLS__ != "boolean" && (Je().__INTLIFY_PROD_DEVTOOLS__ = !1), typeof __INTLIFY_DROP_MESSAGE_COMPILER__ != "boolean" && (Je().__INTLIFY_DROP_MESSAGE_COMPILER__ = !1);
|
|
961
|
-
}
|
|
962
|
-
function St(e) {
|
|
963
|
-
return (n) => vs(n, e);
|
|
964
|
-
}
|
|
965
|
-
function vs(e, t) {
|
|
966
|
-
const n = bs(t);
|
|
967
|
-
if (n == null)
|
|
968
|
-
throw ct(
|
|
969
|
-
0
|
|
970
|
-
/* NodeTypes.Resource */
|
|
971
|
-
);
|
|
972
|
-
if (Jt(n) === 1) {
|
|
973
|
-
const o = ys(n);
|
|
974
|
-
return e.plural(o.reduce((f, d) => [
|
|
975
|
-
...f,
|
|
976
|
-
mn(e, d)
|
|
977
|
-
], []));
|
|
978
|
-
} else
|
|
979
|
-
return mn(e, n);
|
|
980
|
-
}
|
|
981
|
-
const hs = ["b", "body"];
|
|
982
|
-
function bs(e) {
|
|
983
|
-
return Be(e, hs);
|
|
984
|
-
}
|
|
985
|
-
const gs = ["c", "cases"];
|
|
986
|
-
function ys(e) {
|
|
987
|
-
return Be(e, gs, []);
|
|
988
|
-
}
|
|
989
|
-
function mn(e, t) {
|
|
990
|
-
const n = Es(t);
|
|
991
|
-
if (n != null)
|
|
992
|
-
return e.type === "text" ? n : e.normalize([n]);
|
|
993
|
-
{
|
|
994
|
-
const r = Ns(t).reduce((a, o) => [...a, Ft(e, o)], []);
|
|
995
|
-
return e.normalize(r);
|
|
996
|
-
}
|
|
997
|
-
}
|
|
998
|
-
const Is = ["s", "static"];
|
|
999
|
-
function Es(e) {
|
|
1000
|
-
return Be(e, Is);
|
|
1001
|
-
}
|
|
1002
|
-
const Cs = ["i", "items"];
|
|
1003
|
-
function Ns(e) {
|
|
1004
|
-
return Be(e, Cs, []);
|
|
1005
|
-
}
|
|
1006
|
-
function Ft(e, t) {
|
|
1007
|
-
const n = Jt(t);
|
|
1008
|
-
switch (n) {
|
|
1009
|
-
case 3:
|
|
1010
|
-
return _t(t, n);
|
|
1011
|
-
case 9:
|
|
1012
|
-
return _t(t, n);
|
|
1013
|
-
case 4: {
|
|
1014
|
-
const r = t;
|
|
1015
|
-
if (Se(r, "k") && r.k)
|
|
1016
|
-
return e.interpolate(e.named(r.k));
|
|
1017
|
-
if (Se(r, "key") && r.key)
|
|
1018
|
-
return e.interpolate(e.named(r.key));
|
|
1019
|
-
throw ct(n);
|
|
1020
|
-
}
|
|
1021
|
-
case 5: {
|
|
1022
|
-
const r = t;
|
|
1023
|
-
if (Se(r, "i") && be(r.i))
|
|
1024
|
-
return e.interpolate(e.list(r.i));
|
|
1025
|
-
if (Se(r, "index") && be(r.index))
|
|
1026
|
-
return e.interpolate(e.list(r.index));
|
|
1027
|
-
throw ct(n);
|
|
1028
|
-
}
|
|
1029
|
-
case 6: {
|
|
1030
|
-
const r = t, a = Ss(r), o = As(r);
|
|
1031
|
-
return e.linked(Ft(e, o), a ? Ft(e, a) : void 0, e.type);
|
|
1032
|
-
}
|
|
1033
|
-
case 7:
|
|
1034
|
-
return _t(t, n);
|
|
1035
|
-
case 8:
|
|
1036
|
-
return _t(t, n);
|
|
1037
|
-
default:
|
|
1038
|
-
throw new Error(`unhandled node on format message part: ${n}`);
|
|
1039
|
-
}
|
|
1040
|
-
}
|
|
1041
|
-
const Ts = ["t", "type"];
|
|
1042
|
-
function Jt(e) {
|
|
1043
|
-
return Be(e, Ts);
|
|
1044
|
-
}
|
|
1045
|
-
const Os = ["v", "value"];
|
|
1046
|
-
function _t(e, t) {
|
|
1047
|
-
const n = Be(e, Os);
|
|
1048
|
-
if (n)
|
|
1049
|
-
return n;
|
|
1050
|
-
throw ct(t);
|
|
1051
|
-
}
|
|
1052
|
-
const Ls = ["m", "modifier"];
|
|
1053
|
-
function Ss(e) {
|
|
1054
|
-
return Be(e, Ls);
|
|
1055
|
-
}
|
|
1056
|
-
const Rs = ["k", "key"];
|
|
1057
|
-
function As(e) {
|
|
1058
|
-
const t = Be(e, Rs);
|
|
1059
|
-
if (t)
|
|
1060
|
-
return t;
|
|
1061
|
-
throw ct(
|
|
1062
|
-
6
|
|
1063
|
-
/* NodeTypes.Linked */
|
|
1064
|
-
);
|
|
1065
|
-
}
|
|
1066
|
-
function Be(e, t, n) {
|
|
1067
|
-
for (let r = 0; r < t.length; r++) {
|
|
1068
|
-
const a = t[r];
|
|
1069
|
-
if (Se(e, a) && e[a] != null)
|
|
1070
|
-
return e[a];
|
|
1071
|
-
}
|
|
1072
|
-
return n;
|
|
1073
|
-
}
|
|
1074
|
-
function ct(e) {
|
|
1075
|
-
return new Error(`unhandled node type: ${e}`);
|
|
1076
|
-
}
|
|
1077
|
-
const ks = (e) => e;
|
|
1078
|
-
let pt = se();
|
|
1079
|
-
function ot(e) {
|
|
1080
|
-
return ee(e) && Jt(e) === 0 && (Se(e, "b") || Se(e, "body"));
|
|
1081
|
-
}
|
|
1082
|
-
function Ms(e, t = {}) {
|
|
1083
|
-
let n = !1;
|
|
1084
|
-
const r = t.onError || Br;
|
|
1085
|
-
return t.onError = (a) => {
|
|
1086
|
-
n = !0, r(a);
|
|
1087
|
-
}, { ...fs(e, t), detectError: n };
|
|
1088
|
-
}
|
|
1089
|
-
// @__NO_SIDE_EFFECTS__
|
|
1090
|
-
function Ds(e, t) {
|
|
1091
|
-
if (!__INTLIFY_DROP_MESSAGE_COMPILER__ && G(e)) {
|
|
1092
|
-
_e(t.warnHtmlMessage) && t.warnHtmlMessage;
|
|
1093
|
-
const r = (t.onCacheKey || ks)(e), a = pt[r];
|
|
1094
|
-
if (a)
|
|
1095
|
-
return a;
|
|
1096
|
-
const { ast: o, detectError: f } = Ms(e, {
|
|
1097
|
-
...t,
|
|
1098
|
-
location: _s.env.NODE_ENV !== "production",
|
|
1099
|
-
jit: !0
|
|
1100
|
-
}), d = St(o);
|
|
1101
|
-
return f ? d : pt[r] = d;
|
|
1102
|
-
} else {
|
|
1103
|
-
const n = e.cacheKey;
|
|
1104
|
-
if (n) {
|
|
1105
|
-
const r = pt[n];
|
|
1106
|
-
return r || (pt[n] = St(e));
|
|
1107
|
-
} else
|
|
1108
|
-
return St(e);
|
|
1109
|
-
}
|
|
1110
|
-
}
|
|
1111
|
-
let ut = null;
|
|
1112
|
-
function ws(e) {
|
|
1113
|
-
ut = e;
|
|
1114
|
-
}
|
|
1115
|
-
function Fs(e, t, n) {
|
|
1116
|
-
ut && ut.emit("i18n:init", {
|
|
1117
|
-
timestamp: Date.now(),
|
|
1118
|
-
i18n: e,
|
|
1119
|
-
version: t,
|
|
1120
|
-
meta: n
|
|
1121
|
-
});
|
|
1122
|
-
}
|
|
1123
|
-
const Ps = /* @__PURE__ */ js("function:translate");
|
|
1124
|
-
function js(e) {
|
|
1125
|
-
return (t) => ut && ut.emit(e, t);
|
|
1126
|
-
}
|
|
1127
|
-
const Ue = {
|
|
1128
|
-
INVALID_ARGUMENT: Xr,
|
|
1129
|
-
// 17
|
|
1130
|
-
INVALID_DATE_ARGUMENT: 18,
|
|
1131
|
-
INVALID_ISO_DATE_ARGUMENT: 19,
|
|
1132
|
-
NOT_SUPPORT_LOCALE_PROMISE_VALUE: 21,
|
|
1133
|
-
NOT_SUPPORT_LOCALE_ASYNC_FUNCTION: 22,
|
|
1134
|
-
NOT_SUPPORT_LOCALE_TYPE: 23
|
|
1135
|
-
}, Us = 24;
|
|
1136
|
-
function xe(e) {
|
|
1137
|
-
return Nt(e, null, void 0);
|
|
1138
|
-
}
|
|
1139
|
-
function Kt(e, t) {
|
|
1140
|
-
return t.locale != null ? dn(t.locale) : dn(e.locale);
|
|
1141
|
-
}
|
|
1142
|
-
let Rt;
|
|
1143
|
-
function dn(e) {
|
|
1144
|
-
if (G(e))
|
|
1145
|
-
return e;
|
|
1146
|
-
if (ue(e)) {
|
|
1147
|
-
if (e.resolvedOnce && Rt != null)
|
|
1148
|
-
return Rt;
|
|
1149
|
-
if (e.constructor.name === "Function") {
|
|
1150
|
-
const t = e();
|
|
1151
|
-
if (Gr(t))
|
|
1152
|
-
throw xe(Ue.NOT_SUPPORT_LOCALE_PROMISE_VALUE);
|
|
1153
|
-
return Rt = t;
|
|
1154
|
-
} else
|
|
1155
|
-
throw xe(Ue.NOT_SUPPORT_LOCALE_ASYNC_FUNCTION);
|
|
1156
|
-
} else
|
|
1157
|
-
throw xe(Ue.NOT_SUPPORT_LOCALE_TYPE);
|
|
1158
|
-
}
|
|
1159
|
-
function xs(e, t, n) {
|
|
1160
|
-
return [.../* @__PURE__ */ new Set([
|
|
1161
|
-
n,
|
|
1162
|
-
...pe(t) ? t : ee(t) ? Object.keys(t) : G(t) ? [t] : [n]
|
|
1163
|
-
])];
|
|
1164
|
-
}
|
|
1165
|
-
function Hn(e, t, n) {
|
|
1166
|
-
const r = G(n) ? n : Et, a = e;
|
|
1167
|
-
a.__localeChainCache || (a.__localeChainCache = /* @__PURE__ */ new Map());
|
|
1168
|
-
let o = a.__localeChainCache.get(r);
|
|
1169
|
-
if (!o) {
|
|
1170
|
-
o = [];
|
|
1171
|
-
let f = [n];
|
|
1172
|
-
for (; pe(f); )
|
|
1173
|
-
f = fn(o, f, t);
|
|
1174
|
-
const d = pe(t) || !q(t) ? t : t.default ? t.default : null;
|
|
1175
|
-
f = G(d) ? [d] : d, pe(f) && fn(o, f, !1), a.__localeChainCache.set(r, o);
|
|
1176
|
-
}
|
|
1177
|
-
return o;
|
|
1178
|
-
}
|
|
1179
|
-
function fn(e, t, n) {
|
|
1180
|
-
let r = !0;
|
|
1181
|
-
for (let a = 0; a < t.length && _e(r); a++) {
|
|
1182
|
-
const o = t[a];
|
|
1183
|
-
G(o) && (r = Vs(e, t[a], n));
|
|
1184
|
-
}
|
|
1185
|
-
return r;
|
|
1186
|
-
}
|
|
1187
|
-
function Vs(e, t, n) {
|
|
1188
|
-
let r;
|
|
1189
|
-
const a = t.split("-");
|
|
1190
|
-
do {
|
|
1191
|
-
const o = a.join("-");
|
|
1192
|
-
r = Gs(e, o, n), a.splice(-1, 1);
|
|
1193
|
-
} while (a.length && r === !0);
|
|
1194
|
-
return r;
|
|
1195
|
-
}
|
|
1196
|
-
function Gs(e, t, n) {
|
|
1197
|
-
let r = !1;
|
|
1198
|
-
if (!e.includes(t) && (r = !0, t)) {
|
|
1199
|
-
r = t[t.length - 1] !== "!";
|
|
1200
|
-
const a = t.replace(/!/g, "");
|
|
1201
|
-
e.push(a), (pe(n) || q(n)) && n[a] && (r = n[a]);
|
|
1202
|
-
}
|
|
1203
|
-
return r;
|
|
1204
|
-
}
|
|
1205
|
-
const He = [];
|
|
1206
|
-
He[
|
|
1207
|
-
0
|
|
1208
|
-
/* States.BEFORE_PATH */
|
|
1209
|
-
] = {
|
|
1210
|
-
w: [
|
|
1211
|
-
0
|
|
1212
|
-
/* States.BEFORE_PATH */
|
|
1213
|
-
],
|
|
1214
|
-
i: [
|
|
1215
|
-
3,
|
|
1216
|
-
0
|
|
1217
|
-
/* Actions.APPEND */
|
|
1218
|
-
],
|
|
1219
|
-
"[": [
|
|
1220
|
-
4
|
|
1221
|
-
/* States.IN_SUB_PATH */
|
|
1222
|
-
],
|
|
1223
|
-
o: [
|
|
1224
|
-
7
|
|
1225
|
-
/* States.AFTER_PATH */
|
|
1226
|
-
]
|
|
1227
|
-
};
|
|
1228
|
-
He[
|
|
1229
|
-
1
|
|
1230
|
-
/* States.IN_PATH */
|
|
1231
|
-
] = {
|
|
1232
|
-
w: [
|
|
1233
|
-
1
|
|
1234
|
-
/* States.IN_PATH */
|
|
1235
|
-
],
|
|
1236
|
-
".": [
|
|
1237
|
-
2
|
|
1238
|
-
/* States.BEFORE_IDENT */
|
|
1239
|
-
],
|
|
1240
|
-
"[": [
|
|
1241
|
-
4
|
|
1242
|
-
/* States.IN_SUB_PATH */
|
|
1243
|
-
],
|
|
1244
|
-
o: [
|
|
1245
|
-
7
|
|
1246
|
-
/* States.AFTER_PATH */
|
|
1247
|
-
]
|
|
1248
|
-
};
|
|
1249
|
-
He[
|
|
1250
|
-
2
|
|
1251
|
-
/* States.BEFORE_IDENT */
|
|
1252
|
-
] = {
|
|
1253
|
-
w: [
|
|
1254
|
-
2
|
|
1255
|
-
/* States.BEFORE_IDENT */
|
|
1256
|
-
],
|
|
1257
|
-
i: [
|
|
1258
|
-
3,
|
|
1259
|
-
0
|
|
1260
|
-
/* Actions.APPEND */
|
|
1261
|
-
],
|
|
1262
|
-
0: [
|
|
1263
|
-
3,
|
|
1264
|
-
0
|
|
1265
|
-
/* Actions.APPEND */
|
|
1266
|
-
]
|
|
1267
|
-
};
|
|
1268
|
-
He[
|
|
1269
|
-
3
|
|
1270
|
-
/* States.IN_IDENT */
|
|
1271
|
-
] = {
|
|
1272
|
-
i: [
|
|
1273
|
-
3,
|
|
1274
|
-
0
|
|
1275
|
-
/* Actions.APPEND */
|
|
1276
|
-
],
|
|
1277
|
-
0: [
|
|
1278
|
-
3,
|
|
1279
|
-
0
|
|
1280
|
-
/* Actions.APPEND */
|
|
1281
|
-
],
|
|
1282
|
-
w: [
|
|
1283
|
-
1,
|
|
1284
|
-
1
|
|
1285
|
-
/* Actions.PUSH */
|
|
1286
|
-
],
|
|
1287
|
-
".": [
|
|
1288
|
-
2,
|
|
1289
|
-
1
|
|
1290
|
-
/* Actions.PUSH */
|
|
1291
|
-
],
|
|
1292
|
-
"[": [
|
|
1293
|
-
4,
|
|
1294
|
-
1
|
|
1295
|
-
/* Actions.PUSH */
|
|
1296
|
-
],
|
|
1297
|
-
o: [
|
|
1298
|
-
7,
|
|
1299
|
-
1
|
|
1300
|
-
/* Actions.PUSH */
|
|
1301
|
-
]
|
|
1302
|
-
};
|
|
1303
|
-
He[
|
|
1304
|
-
4
|
|
1305
|
-
/* States.IN_SUB_PATH */
|
|
1306
|
-
] = {
|
|
1307
|
-
"'": [
|
|
1308
|
-
5,
|
|
1309
|
-
0
|
|
1310
|
-
/* Actions.APPEND */
|
|
1311
|
-
],
|
|
1312
|
-
'"': [
|
|
1313
|
-
6,
|
|
1314
|
-
0
|
|
1315
|
-
/* Actions.APPEND */
|
|
1316
|
-
],
|
|
1317
|
-
"[": [
|
|
1318
|
-
4,
|
|
1319
|
-
2
|
|
1320
|
-
/* Actions.INC_SUB_PATH_DEPTH */
|
|
1321
|
-
],
|
|
1322
|
-
"]": [
|
|
1323
|
-
1,
|
|
1324
|
-
3
|
|
1325
|
-
/* Actions.PUSH_SUB_PATH */
|
|
1326
|
-
],
|
|
1327
|
-
o: 8,
|
|
1328
|
-
l: [
|
|
1329
|
-
4,
|
|
1330
|
-
0
|
|
1331
|
-
/* Actions.APPEND */
|
|
1332
|
-
]
|
|
1333
|
-
};
|
|
1334
|
-
He[
|
|
1335
|
-
5
|
|
1336
|
-
/* States.IN_SINGLE_QUOTE */
|
|
1337
|
-
] = {
|
|
1338
|
-
"'": [
|
|
1339
|
-
4,
|
|
1340
|
-
0
|
|
1341
|
-
/* Actions.APPEND */
|
|
1342
|
-
],
|
|
1343
|
-
o: 8,
|
|
1344
|
-
l: [
|
|
1345
|
-
5,
|
|
1346
|
-
0
|
|
1347
|
-
/* Actions.APPEND */
|
|
1348
|
-
]
|
|
1349
|
-
};
|
|
1350
|
-
He[
|
|
1351
|
-
6
|
|
1352
|
-
/* States.IN_DOUBLE_QUOTE */
|
|
1353
|
-
] = {
|
|
1354
|
-
'"': [
|
|
1355
|
-
4,
|
|
1356
|
-
0
|
|
1357
|
-
/* Actions.APPEND */
|
|
1358
|
-
],
|
|
1359
|
-
o: 8,
|
|
1360
|
-
l: [
|
|
1361
|
-
6,
|
|
1362
|
-
0
|
|
1363
|
-
/* Actions.APPEND */
|
|
1364
|
-
]
|
|
1365
|
-
};
|
|
1366
|
-
const Ws = /^\s?(?:true|false|-?[\d.]+|'[^']*'|"[^"]*")\s?$/;
|
|
1367
|
-
function Zs(e) {
|
|
1368
|
-
return Ws.test(e);
|
|
1369
|
-
}
|
|
1370
|
-
function Ys(e) {
|
|
1371
|
-
const t = e.charCodeAt(0), n = e.charCodeAt(e.length - 1);
|
|
1372
|
-
return t === n && (t === 34 || t === 39) ? e.slice(1, -1) : e;
|
|
1373
|
-
}
|
|
1374
|
-
function Xs(e) {
|
|
1375
|
-
if (e == null)
|
|
1376
|
-
return "o";
|
|
1377
|
-
switch (e.charCodeAt(0)) {
|
|
1378
|
-
case 91:
|
|
1379
|
-
case 93:
|
|
1380
|
-
case 46:
|
|
1381
|
-
case 34:
|
|
1382
|
-
case 39:
|
|
1383
|
-
return e;
|
|
1384
|
-
case 95:
|
|
1385
|
-
case 36:
|
|
1386
|
-
case 45:
|
|
1387
|
-
return "i";
|
|
1388
|
-
case 9:
|
|
1389
|
-
case 10:
|
|
1390
|
-
case 13:
|
|
1391
|
-
case 160:
|
|
1392
|
-
case 65279:
|
|
1393
|
-
case 8232:
|
|
1394
|
-
case 8233:
|
|
1395
|
-
return "w";
|
|
1396
|
-
}
|
|
1397
|
-
return "i";
|
|
1398
|
-
}
|
|
1399
|
-
function Bs(e) {
|
|
1400
|
-
const t = e.trim();
|
|
1401
|
-
return e.charAt(0) === "0" && isNaN(parseInt(e)) ? !1 : Zs(t) ? Ys(t) : "*" + t;
|
|
1402
|
-
}
|
|
1403
|
-
function Hs(e) {
|
|
1404
|
-
const t = [];
|
|
1405
|
-
let n = -1, r = 0, a = 0, o, f, d, i, b, E, N;
|
|
1406
|
-
const T = [];
|
|
1407
|
-
T[
|
|
1408
|
-
0
|
|
1409
|
-
/* Actions.APPEND */
|
|
1410
|
-
] = () => {
|
|
1411
|
-
f === void 0 ? f = d : f += d;
|
|
1412
|
-
}, T[
|
|
1413
|
-
1
|
|
1414
|
-
/* Actions.PUSH */
|
|
1415
|
-
] = () => {
|
|
1416
|
-
f !== void 0 && (t.push(f), f = void 0);
|
|
1417
|
-
}, T[
|
|
1418
|
-
2
|
|
1419
|
-
/* Actions.INC_SUB_PATH_DEPTH */
|
|
1420
|
-
] = () => {
|
|
1421
|
-
T[
|
|
1422
|
-
0
|
|
1423
|
-
/* Actions.APPEND */
|
|
1424
|
-
](), a++;
|
|
1425
|
-
}, T[
|
|
1426
|
-
3
|
|
1427
|
-
/* Actions.PUSH_SUB_PATH */
|
|
1428
|
-
] = () => {
|
|
1429
|
-
if (a > 0)
|
|
1430
|
-
a--, r = 4, T[
|
|
1431
|
-
0
|
|
1432
|
-
/* Actions.APPEND */
|
|
1433
|
-
]();
|
|
1434
|
-
else {
|
|
1435
|
-
if (a = 0, f === void 0 || (f = Bs(f), f === !1))
|
|
1436
|
-
return !1;
|
|
1437
|
-
T[
|
|
1438
|
-
1
|
|
1439
|
-
/* Actions.PUSH */
|
|
1440
|
-
]();
|
|
1441
|
-
}
|
|
1442
|
-
};
|
|
1443
|
-
function D() {
|
|
1444
|
-
const k = e[n + 1];
|
|
1445
|
-
if (r === 5 && k === "'" || r === 6 && k === '"')
|
|
1446
|
-
return n++, d = "\\" + k, T[
|
|
1447
|
-
0
|
|
1448
|
-
/* Actions.APPEND */
|
|
1449
|
-
](), !0;
|
|
1450
|
-
}
|
|
1451
|
-
for (; r !== null; )
|
|
1452
|
-
if (n++, o = e[n], !(o === "\\" && D())) {
|
|
1453
|
-
if (i = Xs(o), N = He[r], b = N[i] || N.l || 8, b === 8 || (r = b[0], b[1] !== void 0 && (E = T[b[1]], E && (d = o, E() === !1))))
|
|
1454
|
-
return;
|
|
1455
|
-
if (r === 7)
|
|
1456
|
-
return t;
|
|
1457
|
-
}
|
|
1458
|
-
}
|
|
1459
|
-
const _n = /* @__PURE__ */ new Map();
|
|
1460
|
-
function $s(e, t) {
|
|
1461
|
-
return ee(e) ? e[t] : null;
|
|
1462
|
-
}
|
|
1463
|
-
function Js(e, t) {
|
|
1464
|
-
if (!ee(e))
|
|
1465
|
-
return null;
|
|
1466
|
-
let n = _n.get(t);
|
|
1467
|
-
if (n || (n = Hs(t), n && _n.set(t, n)), !n)
|
|
1468
|
-
return null;
|
|
1469
|
-
const r = n.length;
|
|
1470
|
-
let a = e, o = 0;
|
|
1471
|
-
for (; o < r; ) {
|
|
1472
|
-
const f = a[n[o]];
|
|
1473
|
-
if (f === void 0 || ue(a))
|
|
1474
|
-
return null;
|
|
1475
|
-
a = f, o++;
|
|
1476
|
-
}
|
|
1477
|
-
return a;
|
|
1478
|
-
}
|
|
1479
|
-
const Ks = "10.0.5", Tt = -1, Et = "en-US", pn = "", vn = (e) => `${e.charAt(0).toLocaleUpperCase()}${e.substr(1)}`;
|
|
1480
|
-
function zs() {
|
|
1481
|
-
return {
|
|
1482
|
-
upper: (e, t) => t === "text" && G(e) ? e.toUpperCase() : t === "vnode" && ee(e) && "__v_isVNode" in e ? e.children.toUpperCase() : e,
|
|
1483
|
-
lower: (e, t) => t === "text" && G(e) ? e.toLowerCase() : t === "vnode" && ee(e) && "__v_isVNode" in e ? e.children.toLowerCase() : e,
|
|
1484
|
-
capitalize: (e, t) => t === "text" && G(e) ? vn(e) : t === "vnode" && ee(e) && "__v_isVNode" in e ? vn(e.children) : e
|
|
1485
|
-
};
|
|
1486
|
-
}
|
|
1487
|
-
let $n;
|
|
1488
|
-
function Qs(e) {
|
|
1489
|
-
$n = e;
|
|
1490
|
-
}
|
|
1491
|
-
let Jn;
|
|
1492
|
-
function qs(e) {
|
|
1493
|
-
Jn = e;
|
|
1494
|
-
}
|
|
1495
|
-
let Kn;
|
|
1496
|
-
function ea(e) {
|
|
1497
|
-
Kn = e;
|
|
1498
|
-
}
|
|
1499
|
-
let zn = null;
|
|
1500
|
-
const ta = /* @__NO_SIDE_EFFECTS__ */ (e) => {
|
|
1501
|
-
zn = e;
|
|
1502
|
-
}, na = /* @__NO_SIDE_EFFECTS__ */ () => zn;
|
|
1503
|
-
let Qn = null;
|
|
1504
|
-
const hn = (e) => {
|
|
1505
|
-
Qn = e;
|
|
1506
|
-
}, ra = () => Qn;
|
|
1507
|
-
let bn = 0;
|
|
1508
|
-
function sa(e = {}) {
|
|
1509
|
-
const t = ue(e.onWarn) ? e.onWarn : Zr, n = G(e.version) ? e.version : Ks, r = G(e.locale) || ue(e.locale) ? e.locale : Et, a = ue(r) ? Et : r, o = pe(e.fallbackLocale) || q(e.fallbackLocale) || G(e.fallbackLocale) || e.fallbackLocale === !1 ? e.fallbackLocale : a, f = q(e.messages) ? e.messages : At(a), d = q(e.datetimeFormats) ? e.datetimeFormats : At(a), i = q(e.numberFormats) ? e.numberFormats : At(a), b = ge(se(), e.modifiers, zs()), E = e.pluralRules || se(), N = ue(e.missing) ? e.missing : null, T = _e(e.missingWarn) || It(e.missingWarn) ? e.missingWarn : !0, D = _e(e.fallbackWarn) || It(e.fallbackWarn) ? e.fallbackWarn : !0, k = !!e.fallbackFormat, R = !!e.unresolving, M = ue(e.postTranslation) ? e.postTranslation : null, p = q(e.processor) ? e.processor : null, h = _e(e.warnHtmlMessage) ? e.warnHtmlMessage : !0, L = !!e.escapeParameter, m = ue(e.messageCompiler) ? e.messageCompiler : $n, g = ue(e.messageResolver) ? e.messageResolver : Jn || $s, I = ue(e.localeFallbacker) ? e.localeFallbacker : Kn || xs, v = ee(e.fallbackContext) ? e.fallbackContext : void 0, A = e, S = ee(A.__datetimeFormatters) ? A.__datetimeFormatters : /* @__PURE__ */ new Map(), H = ee(A.__numberFormatters) ? A.__numberFormatters : /* @__PURE__ */ new Map(), x = ee(A.__meta) ? A.__meta : {};
|
|
1510
|
-
bn++;
|
|
1511
|
-
const _ = {
|
|
1512
|
-
version: n,
|
|
1513
|
-
cid: bn,
|
|
1514
|
-
locale: r,
|
|
1515
|
-
fallbackLocale: o,
|
|
1516
|
-
messages: f,
|
|
1517
|
-
modifiers: b,
|
|
1518
|
-
pluralRules: E,
|
|
1519
|
-
missing: N,
|
|
1520
|
-
missingWarn: T,
|
|
1521
|
-
fallbackWarn: D,
|
|
1522
|
-
fallbackFormat: k,
|
|
1523
|
-
unresolving: R,
|
|
1524
|
-
postTranslation: M,
|
|
1525
|
-
processor: p,
|
|
1526
|
-
warnHtmlMessage: h,
|
|
1527
|
-
escapeParameter: L,
|
|
1528
|
-
messageCompiler: m,
|
|
1529
|
-
messageResolver: g,
|
|
1530
|
-
localeFallbacker: I,
|
|
1531
|
-
fallbackContext: v,
|
|
1532
|
-
onWarn: t,
|
|
1533
|
-
__meta: x
|
|
1534
|
-
};
|
|
1535
|
-
return _.datetimeFormats = d, _.numberFormats = i, _.__datetimeFormatters = S, _.__numberFormatters = H, __INTLIFY_PROD_DEVTOOLS__ && Fs(_, n, x), _;
|
|
1536
|
-
}
|
|
1537
|
-
const At = (e) => ({ [e]: se() });
|
|
1538
|
-
function zt(e, t, n, r, a) {
|
|
1539
|
-
const { missing: o, onWarn: f } = e;
|
|
1540
|
-
if (o !== null) {
|
|
1541
|
-
const d = o(e, n, t, a);
|
|
1542
|
-
return G(d) ? d : t;
|
|
1543
|
-
} else
|
|
1544
|
-
return t;
|
|
1545
|
-
}
|
|
1546
|
-
function it(e, t, n) {
|
|
1547
|
-
const r = e;
|
|
1548
|
-
r.__localeChainCache = /* @__PURE__ */ new Map(), e.localeFallbacker(e, n, t);
|
|
1549
|
-
}
|
|
1550
|
-
function aa(e, t) {
|
|
1551
|
-
return e === t ? !1 : e.split("-")[0] === t.split("-")[0];
|
|
1552
|
-
}
|
|
1553
|
-
function oa(e, t) {
|
|
1554
|
-
const n = t.indexOf(e);
|
|
1555
|
-
if (n === -1)
|
|
1556
|
-
return !1;
|
|
1557
|
-
for (let r = n + 1; r < t.length; r++)
|
|
1558
|
-
if (aa(e, t[r]))
|
|
1559
|
-
return !0;
|
|
1560
|
-
return !1;
|
|
1561
|
-
}
|
|
1562
|
-
function gn(e, ...t) {
|
|
1563
|
-
const { datetimeFormats: n, unresolving: r, fallbackLocale: a, onWarn: o, localeFallbacker: f } = e, { __datetimeFormatters: d } = e, [i, b, E, N] = Pt(...t), T = _e(E.missingWarn) ? E.missingWarn : e.missingWarn;
|
|
1564
|
-
_e(E.fallbackWarn) ? E.fallbackWarn : e.fallbackWarn;
|
|
1565
|
-
const D = !!E.part, k = Kt(e, E), R = f(
|
|
1566
|
-
e,
|
|
1567
|
-
// eslint-disable-line @typescript-eslint/no-explicit-any
|
|
1568
|
-
a,
|
|
1569
|
-
k
|
|
1570
|
-
);
|
|
1571
|
-
if (!G(i) || i === "")
|
|
1572
|
-
return new Intl.DateTimeFormat(k, N).format(b);
|
|
1573
|
-
let M = {}, p, h = null;
|
|
1574
|
-
const L = "datetime format";
|
|
1575
|
-
for (let I = 0; I < R.length && (p = R[I], M = n[p] || {}, h = M[i], !q(h)); I++)
|
|
1576
|
-
zt(e, i, p, T, L);
|
|
1577
|
-
if (!q(h) || !G(p))
|
|
1578
|
-
return r ? Tt : i;
|
|
1579
|
-
let m = `${p}__${i}`;
|
|
1580
|
-
Ct(N) || (m = `${m}__${JSON.stringify(N)}`);
|
|
1581
|
-
let g = d.get(m);
|
|
1582
|
-
return g || (g = new Intl.DateTimeFormat(p, ge({}, h, N)), d.set(m, g)), D ? g.formatToParts(b) : g.format(b);
|
|
1583
|
-
}
|
|
1584
|
-
const qn = [
|
|
1585
|
-
"localeMatcher",
|
|
1586
|
-
"weekday",
|
|
1587
|
-
"era",
|
|
1588
|
-
"year",
|
|
1589
|
-
"month",
|
|
1590
|
-
"day",
|
|
1591
|
-
"hour",
|
|
1592
|
-
"minute",
|
|
1593
|
-
"second",
|
|
1594
|
-
"timeZoneName",
|
|
1595
|
-
"formatMatcher",
|
|
1596
|
-
"hour12",
|
|
1597
|
-
"timeZone",
|
|
1598
|
-
"dateStyle",
|
|
1599
|
-
"timeStyle",
|
|
1600
|
-
"calendar",
|
|
1601
|
-
"dayPeriod",
|
|
1602
|
-
"numberingSystem",
|
|
1603
|
-
"hourCycle",
|
|
1604
|
-
"fractionalSecondDigits"
|
|
1605
|
-
];
|
|
1606
|
-
function Pt(...e) {
|
|
1607
|
-
const [t, n, r, a] = e, o = se();
|
|
1608
|
-
let f = se(), d;
|
|
1609
|
-
if (G(t)) {
|
|
1610
|
-
const i = t.match(/(\d{4}-\d{2}-\d{2})(T|\s)?(.*)/);
|
|
1611
|
-
if (!i)
|
|
1612
|
-
throw xe(Ue.INVALID_ISO_DATE_ARGUMENT);
|
|
1613
|
-
const b = i[3] ? i[3].trim().startsWith("T") ? `${i[1].trim()}${i[3].trim()}` : `${i[1].trim()}T${i[3].trim()}` : i[1].trim();
|
|
1614
|
-
d = new Date(b);
|
|
1615
|
-
try {
|
|
1616
|
-
d.toISOString();
|
|
1617
|
-
} catch {
|
|
1618
|
-
throw xe(Ue.INVALID_ISO_DATE_ARGUMENT);
|
|
1619
|
-
}
|
|
1620
|
-
} else if (Ur(t)) {
|
|
1621
|
-
if (isNaN(t.getTime()))
|
|
1622
|
-
throw xe(Ue.INVALID_DATE_ARGUMENT);
|
|
1623
|
-
d = t;
|
|
1624
|
-
} else if (be(t))
|
|
1625
|
-
d = t;
|
|
1626
|
-
else
|
|
1627
|
-
throw xe(Ue.INVALID_ARGUMENT);
|
|
1628
|
-
return G(n) ? o.key = n : q(n) && Object.keys(n).forEach((i) => {
|
|
1629
|
-
qn.includes(i) ? f[i] = n[i] : o[i] = n[i];
|
|
1630
|
-
}), G(r) ? o.locale = r : q(r) && (f = r), q(a) && (f = a), [o.key || "", d, o, f];
|
|
1631
|
-
}
|
|
1632
|
-
function yn(e, t, n) {
|
|
1633
|
-
const r = e;
|
|
1634
|
-
for (const a in n) {
|
|
1635
|
-
const o = `${t}__${a}`;
|
|
1636
|
-
r.__datetimeFormatters.has(o) && r.__datetimeFormatters.delete(o);
|
|
1637
|
-
}
|
|
1638
|
-
}
|
|
1639
|
-
function In(e, ...t) {
|
|
1640
|
-
const { numberFormats: n, unresolving: r, fallbackLocale: a, onWarn: o, localeFallbacker: f } = e, { __numberFormatters: d } = e, [i, b, E, N] = jt(...t), T = _e(E.missingWarn) ? E.missingWarn : e.missingWarn;
|
|
1641
|
-
_e(E.fallbackWarn) ? E.fallbackWarn : e.fallbackWarn;
|
|
1642
|
-
const D = !!E.part, k = Kt(e, E), R = f(
|
|
1643
|
-
e,
|
|
1644
|
-
// eslint-disable-line @typescript-eslint/no-explicit-any
|
|
1645
|
-
a,
|
|
1646
|
-
k
|
|
1647
|
-
);
|
|
1648
|
-
if (!G(i) || i === "")
|
|
1649
|
-
return new Intl.NumberFormat(k, N).format(b);
|
|
1650
|
-
let M = {}, p, h = null;
|
|
1651
|
-
const L = "number format";
|
|
1652
|
-
for (let I = 0; I < R.length && (p = R[I], M = n[p] || {}, h = M[i], !q(h)); I++)
|
|
1653
|
-
zt(e, i, p, T, L);
|
|
1654
|
-
if (!q(h) || !G(p))
|
|
1655
|
-
return r ? Tt : i;
|
|
1656
|
-
let m = `${p}__${i}`;
|
|
1657
|
-
Ct(N) || (m = `${m}__${JSON.stringify(N)}`);
|
|
1658
|
-
let g = d.get(m);
|
|
1659
|
-
return g || (g = new Intl.NumberFormat(p, ge({}, h, N)), d.set(m, g)), D ? g.formatToParts(b) : g.format(b);
|
|
1660
|
-
}
|
|
1661
|
-
const er = [
|
|
1662
|
-
"localeMatcher",
|
|
1663
|
-
"style",
|
|
1664
|
-
"currency",
|
|
1665
|
-
"currencyDisplay",
|
|
1666
|
-
"currencySign",
|
|
1667
|
-
"useGrouping",
|
|
1668
|
-
"minimumIntegerDigits",
|
|
1669
|
-
"minimumFractionDigits",
|
|
1670
|
-
"maximumFractionDigits",
|
|
1671
|
-
"minimumSignificantDigits",
|
|
1672
|
-
"maximumSignificantDigits",
|
|
1673
|
-
"compactDisplay",
|
|
1674
|
-
"notation",
|
|
1675
|
-
"signDisplay",
|
|
1676
|
-
"unit",
|
|
1677
|
-
"unitDisplay",
|
|
1678
|
-
"roundingMode",
|
|
1679
|
-
"roundingPriority",
|
|
1680
|
-
"roundingIncrement",
|
|
1681
|
-
"trailingZeroDisplay"
|
|
1682
|
-
];
|
|
1683
|
-
function jt(...e) {
|
|
1684
|
-
const [t, n, r, a] = e, o = se();
|
|
1685
|
-
let f = se();
|
|
1686
|
-
if (!be(t))
|
|
1687
|
-
throw xe(Ue.INVALID_ARGUMENT);
|
|
1688
|
-
const d = t;
|
|
1689
|
-
return G(n) ? o.key = n : q(n) && Object.keys(n).forEach((i) => {
|
|
1690
|
-
er.includes(i) ? f[i] = n[i] : o[i] = n[i];
|
|
1691
|
-
}), G(r) ? o.locale = r : q(r) && (f = r), q(a) && (f = a), [o.key || "", d, o, f];
|
|
1692
|
-
}
|
|
1693
|
-
function En(e, t, n) {
|
|
1694
|
-
const r = e;
|
|
1695
|
-
for (const a in n) {
|
|
1696
|
-
const o = `${t}__${a}`;
|
|
1697
|
-
r.__numberFormatters.has(o) && r.__numberFormatters.delete(o);
|
|
1698
|
-
}
|
|
1699
|
-
}
|
|
1700
|
-
const la = (e) => e, ia = (e) => "", ca = "text", ua = (e) => e.length === 0 ? "" : Ht(e), ma = Wr;
|
|
1701
|
-
function Cn(e, t) {
|
|
1702
|
-
return e = Math.abs(e), t === 2 ? e ? e > 1 ? 1 : 0 : 1 : e ? Math.min(e, 2) : 0;
|
|
1703
|
-
}
|
|
1704
|
-
function da(e) {
|
|
1705
|
-
const t = be(e.pluralIndex) ? e.pluralIndex : -1;
|
|
1706
|
-
return e.named && (be(e.named.count) || be(e.named.n)) ? be(e.named.count) ? e.named.count : be(e.named.n) ? e.named.n : t : t;
|
|
1707
|
-
}
|
|
1708
|
-
function fa(e, t) {
|
|
1709
|
-
t.count || (t.count = e), t.n || (t.n = e);
|
|
1710
|
-
}
|
|
1711
|
-
function _a(e = {}) {
|
|
1712
|
-
const t = e.locale, n = da(e), r = ee(e.pluralRules) && G(t) && ue(e.pluralRules[t]) ? e.pluralRules[t] : Cn, a = ee(e.pluralRules) && G(t) && ue(e.pluralRules[t]) ? Cn : void 0, o = (p) => p[r(n, p.length, a)], f = e.list || [], d = (p) => f[p], i = e.named || se();
|
|
1713
|
-
be(e.pluralIndex) && fa(n, i);
|
|
1714
|
-
const b = (p) => i[p];
|
|
1715
|
-
function E(p, h) {
|
|
1716
|
-
const L = ue(e.messages) ? e.messages(p, !!h) : ee(e.messages) ? e.messages[p] : !1;
|
|
1717
|
-
return L || (e.parent ? e.parent.message(p) : ia);
|
|
1718
|
-
}
|
|
1719
|
-
const N = (p) => e.modifiers ? e.modifiers[p] : la, T = q(e.processor) && ue(e.processor.normalize) ? e.processor.normalize : ua, D = q(e.processor) && ue(e.processor.interpolate) ? e.processor.interpolate : ma, k = q(e.processor) && G(e.processor.type) ? e.processor.type : ca, M = {
|
|
1720
|
-
list: d,
|
|
1721
|
-
named: b,
|
|
1722
|
-
plural: o,
|
|
1723
|
-
linked: (p, ...h) => {
|
|
1724
|
-
const [L, m] = h;
|
|
1725
|
-
let g = "text", I = "";
|
|
1726
|
-
h.length === 1 ? ee(L) ? (I = L.modifier || I, g = L.type || g) : G(L) && (I = L || I) : h.length === 2 && (G(L) && (I = L || I), G(m) && (g = m || g));
|
|
1727
|
-
const v = E(p, !0)(M), A = (
|
|
1728
|
-
// The message in vnode resolved with linked are returned as an array by processor.nomalize
|
|
1729
|
-
g === "vnode" && pe(v) && I ? v[0] : v
|
|
1730
|
-
);
|
|
1731
|
-
return I ? N(I)(A, g) : A;
|
|
1732
|
-
},
|
|
1733
|
-
message: E,
|
|
1734
|
-
type: k,
|
|
1735
|
-
interpolate: D,
|
|
1736
|
-
normalize: T,
|
|
1737
|
-
values: ge(se(), f, i)
|
|
1738
|
-
};
|
|
1739
|
-
return M;
|
|
1740
|
-
}
|
|
1741
|
-
const Nn = () => "", Te = (e) => ue(e);
|
|
1742
|
-
function Tn(e, ...t) {
|
|
1743
|
-
const { fallbackFormat: n, postTranslation: r, unresolving: a, messageCompiler: o, fallbackLocale: f, messages: d } = e, [i, b] = Ut(...t), E = _e(b.missingWarn) ? b.missingWarn : e.missingWarn, N = _e(b.fallbackWarn) ? b.fallbackWarn : e.fallbackWarn, T = _e(b.escapeParameter) ? b.escapeParameter : e.escapeParameter, D = !!b.resolvedMessage, k = G(b.default) || _e(b.default) ? _e(b.default) ? o ? i : () => i : b.default : n ? o ? i : () => i : null, R = n || k != null && (G(k) || ue(k)), M = Kt(e, b);
|
|
1744
|
-
T && pa(b);
|
|
1745
|
-
let [p, h, L] = D ? [
|
|
1746
|
-
i,
|
|
1747
|
-
M,
|
|
1748
|
-
d[M] || se()
|
|
1749
|
-
] : tr(e, i, M, f, N, E), m = p, g = i;
|
|
1750
|
-
if (!D && !(G(m) || ot(m) || Te(m)) && R && (m = k, g = m), !D && (!(G(m) || ot(m) || Te(m)) || !G(h)))
|
|
1751
|
-
return a ? Tt : i;
|
|
1752
|
-
let I = !1;
|
|
1753
|
-
const v = () => {
|
|
1754
|
-
I = !0;
|
|
1755
|
-
}, A = Te(m) ? m : nr(e, i, h, m, g, v);
|
|
1756
|
-
if (I)
|
|
1757
|
-
return m;
|
|
1758
|
-
const S = ba(e, h, L, b), H = _a(S), x = va(e, A, H), _ = r ? r(x, i) : x;
|
|
1759
|
-
if (__INTLIFY_PROD_DEVTOOLS__) {
|
|
1760
|
-
const O = {
|
|
1761
|
-
timestamp: Date.now(),
|
|
1762
|
-
key: G(i) ? i : Te(m) ? m.key : "",
|
|
1763
|
-
locale: h || (Te(m) ? m.locale : ""),
|
|
1764
|
-
format: G(m) ? m : Te(m) ? m.source : "",
|
|
1765
|
-
message: _
|
|
1766
|
-
};
|
|
1767
|
-
O.meta = ge({}, e.__meta, /* @__PURE__ */ na() || {}), Ps(O);
|
|
1768
|
-
}
|
|
1769
|
-
return _;
|
|
1770
|
-
}
|
|
1771
|
-
function pa(e) {
|
|
1772
|
-
pe(e.list) ? e.list = e.list.map((t) => G(t) ? on(t) : t) : ee(e.named) && Object.keys(e.named).forEach((t) => {
|
|
1773
|
-
G(e.named[t]) && (e.named[t] = on(e.named[t]));
|
|
1774
|
-
});
|
|
1775
|
-
}
|
|
1776
|
-
function tr(e, t, n, r, a, o) {
|
|
1777
|
-
const { messages: f, onWarn: d, messageResolver: i, localeFallbacker: b } = e, E = b(e, r, n);
|
|
1778
|
-
let N = se(), T, D = null;
|
|
1779
|
-
const k = "translate";
|
|
1780
|
-
for (let R = 0; R < E.length && (T = E[R], N = f[T] || se(), (D = i(N, t)) === null && (D = N[t]), !(G(D) || ot(D) || Te(D))); R++)
|
|
1781
|
-
if (!oa(T, E)) {
|
|
1782
|
-
const M = zt(
|
|
1783
|
-
e,
|
|
1784
|
-
// eslint-disable-line @typescript-eslint/no-explicit-any
|
|
1785
|
-
t,
|
|
1786
|
-
T,
|
|
1787
|
-
o,
|
|
1788
|
-
k
|
|
1789
|
-
);
|
|
1790
|
-
M !== t && (D = M);
|
|
1791
|
-
}
|
|
1792
|
-
return [D, T, N];
|
|
1793
|
-
}
|
|
1794
|
-
function nr(e, t, n, r, a, o) {
|
|
1795
|
-
const { messageCompiler: f, warnHtmlMessage: d } = e;
|
|
1796
|
-
if (Te(r)) {
|
|
1797
|
-
const b = r;
|
|
1798
|
-
return b.locale = b.locale || n, b.key = b.key || t, b;
|
|
1799
|
-
}
|
|
1800
|
-
if (f == null) {
|
|
1801
|
-
const b = () => r;
|
|
1802
|
-
return b.locale = n, b.key = t, b;
|
|
1803
|
-
}
|
|
1804
|
-
const i = f(r, ha(e, n, a, r, d, o));
|
|
1805
|
-
return i.locale = n, i.key = t, i.source = r, i;
|
|
1806
|
-
}
|
|
1807
|
-
function va(e, t, n) {
|
|
1808
|
-
return t(n);
|
|
1809
|
-
}
|
|
1810
|
-
function Ut(...e) {
|
|
1811
|
-
const [t, n, r] = e, a = se();
|
|
1812
|
-
if (!G(t) && !be(t) && !Te(t) && !ot(t))
|
|
1813
|
-
throw xe(Ue.INVALID_ARGUMENT);
|
|
1814
|
-
const o = be(t) ? String(t) : (Te(t), t);
|
|
1815
|
-
return be(n) ? a.plural = n : G(n) ? a.default = n : q(n) && !Ct(n) ? a.named = n : pe(n) && (a.list = n), be(r) ? a.plural = r : G(r) ? a.default = r : q(r) && ge(a, r), [o, a];
|
|
1816
|
-
}
|
|
1817
|
-
function ha(e, t, n, r, a, o) {
|
|
1818
|
-
return {
|
|
1819
|
-
locale: t,
|
|
1820
|
-
key: n,
|
|
1821
|
-
warnHtmlMessage: a,
|
|
1822
|
-
onError: (f) => {
|
|
1823
|
-
throw o && o(f), f;
|
|
1824
|
-
},
|
|
1825
|
-
onCacheKey: (f) => Pr(t, n, f)
|
|
1826
|
-
};
|
|
1827
|
-
}
|
|
1828
|
-
function ba(e, t, n, r) {
|
|
1829
|
-
const { modifiers: a, pluralRules: o, messageResolver: f, fallbackLocale: d, fallbackWarn: i, missingWarn: b, fallbackContext: E } = e, T = {
|
|
1830
|
-
locale: t,
|
|
1831
|
-
modifiers: a,
|
|
1832
|
-
pluralRules: o,
|
|
1833
|
-
messages: (D, k) => {
|
|
1834
|
-
let R = f(n, D);
|
|
1835
|
-
if (R == null && (E || k)) {
|
|
1836
|
-
const [, , M] = tr(
|
|
1837
|
-
E || e,
|
|
1838
|
-
// NOTE: if has fallbackContext, fallback to root, else if use linked, fallback to local context
|
|
1839
|
-
D,
|
|
1840
|
-
t,
|
|
1841
|
-
d,
|
|
1842
|
-
i,
|
|
1843
|
-
b
|
|
1844
|
-
);
|
|
1845
|
-
R = f(M, D);
|
|
1846
|
-
}
|
|
1847
|
-
if (G(R) || ot(R)) {
|
|
1848
|
-
let M = !1;
|
|
1849
|
-
const h = nr(e, D, t, R, D, () => {
|
|
1850
|
-
M = !0;
|
|
1851
|
-
});
|
|
1852
|
-
return M ? Nn : h;
|
|
1853
|
-
} else return Te(R) ? R : Nn;
|
|
1854
|
-
}
|
|
1855
|
-
};
|
|
1856
|
-
return e.processor && (T.processor = e.processor), r.list && (T.list = r.list), r.named && (T.named = r.named), be(r.plural) && (T.pluralIndex = r.plural), T;
|
|
1857
|
-
}
|
|
1858
|
-
ps();
|
|
1859
|
-
var ga = { env: { GITHUB_STATE: "/home/runner/work/_temp/_runner_file_commands/save_state_c8e66e05-10fa-45eb-aebb-34c3296d2aa4", DOTNET_NOLOGO: "1", USER: "runner", npm_config_always_auth: "", npm_config_user_agent: "pnpm/10.8.0 npm/? node/v24.5.0 linux x64", CI: "true", USE_BAZEL_FALLBACK_VERSION: "silent:", RUNNER_ENVIRONMENT: "github-hosted", GITHUB_ENV: "/home/runner/work/_temp/_runner_file_commands/set_env_c8e66e05-10fa-45eb-aebb-34c3296d2aa4", PIPX_HOME: "/opt/pipx", npm_node_execpath: "/opt/hostedtoolcache/node/24.5.0/x64/bin/node", NODE_AUTH_TOKEN: "XXXXX-XXXXX-XXXXX-XXXXX", SHLVL: "1", HCA_CLOUD_PROVIDER: "azure", HOME: "/home/runner", RUNNER_TEMP: "/home/runner/work/_temp", GITHUB_EVENT_PATH: "/home/runner/work/_temp/_github_workflow/event.json", 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.8.2", ANDROID_NDK_LATEST_HOME: "/usr/local/lib/android/sdk/ndk/30.0.16248370", JAVA_HOME_21_X64: "/usr/lib/jvm/temurin-21-jdk-amd64", GITHUB_RETENTION_DAYS: "90", GITHUB_REPOSITORY_OWNER_ID: "54831515", POWERSHELL_DISTRIBUTION_CHANNEL: "GitHub-Actions-Linux", AZURE_EXTENSION_DIR: "/opt/az/azcliextensions", GITHUB_HEAD_REF: "", npm_config_userconfig: "/home/runner/work/_temp/.npmrc", SYSTEMD_EXEC_PID: "1817", ACTIONS_ORCHESTRATION_ID: "008c9e70-0497-4918-88ac-b177402c16ff.publish.publish.__default", npm_config_engine_strict: "true", GITHUB_GRAPHQL_URL: "https://api.github.com/graphql", JAVA_HOME_25_X64: "/usr/lib/jvm/temurin-25-jdk-amd64", NVM_DIR: "/home/runner/.nvm", npm_config_prefer_workspace_packages: "true", DOTNET_SKIP_FIRST_TIME_EXPERIENCE: "1", JAVA_HOME_17_X64: "/usr/lib/jvm/temurin-17-jdk-amd64", ImageVersion: "20261026.180.1", LOGNAME: "runner", RUNNER_OS: "Linux", GITHUB_API_URL: "https://api.github.com", GITHUB_ARTIFACTS: "/home/runner/work/_temp/_runner_file_commands/artifacts_c8e66e05-10fa-45eb-aebb-34c3296d2aa4", SWIFT_PATH: "/usr/share/swift/usr/bin", CHROMEWEBDRIVER: "/usr/local/share/chromedriver-linux64", JOURNAL_STREAM: "10:14635", GITHUB_WORKFLOW: "Publish hrm-portal", _: "/home/runner/setup-pnpm/node_modules/.bin/pnpm", 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_config_registry: "https://registry.npmjs.org/", ACTIONS_RUNNER_ACTION_ARCHIVE_CACHE: "/opt/actionarchivecache", GOROOT_1_25_X64: "/opt/hostedtoolcache/go/1.25.14/x64", GITHUB_RUN_ID: "40666208353", GITHUB_REF_TYPE: "branch", BOOTSTRAP_HASKELL_NONINTERACTIVE: "1", GITHUB_WORKFLOW_SHA: "fe7f1b05b99e6288650adf5329b6e18972d5411d", GOROOT_1_26_X64: "/opt/hostedtoolcache/go/1.26.10/x64", GITHUB_BASE_REF: "", ImageOS: "ubuntu26", GITHUB_WORKFLOW_REF: "feedmepos/hrm-service/.github/workflows/publish-hrm-portal-trusted.yml@refs/heads/dev", ACTIONS_ID_TOKEN_REQUEST_TOKEN: "eyJhbGciOiJSUzI1NiIsImtpZCI6IjM4ODI2YjE3LTZhMzAtNWY5Yi1iMTY5LThiZWI4MjAyZjcyMyIsInR5cCI6IkpXVCIsIng1dCI6InlrTmFZNHFNX3RhNGsyVGdaT0NFWUxrY1lsQSJ9.eyJJZGVudGl0eVR5cGVDbGFpbSI6IlN5c3RlbTpTZXJ2aWNlSWRlbnRpdHkiLCJhYyI6Ilt7XCJTY29wZVwiOlwicmVmcy9oZWFkcy9kZXZcIixcIlBlcm1pc3Npb25cIjozfSx7XCJTY29wZVwiOlwicmVmcy9oZWFkcy9tYWluXCIsXCJQZXJtaXNzaW9uXCI6MX1dIiwiYWNzbCI6IjEwIiwiYXVkIjoidnNvOjZmOTZmYTg5LWI3YmYtNDg3OC1iYWQzLTg5ODAwNjU2NmI2ZSIsImJpbGxpbmdfb3duZXJfaWQiOiJFX2tnRE9BQUpvWVEiLCJleHAiOjE3OTMyMDI2OTUsImh0dHA6Ly9zY2hlbWFzLm1pY3Jvc29mdC5jb20vd3MvMjAwOC8wNi9pZGVudGl0eS9jbGFpbXMvcHJpbWFyeXNpZCI6ImRkZGRkZGRkLWRkZGQtZGRkZC1kZGRkLWRkZGRkZGRkZGRkZCIsImh0dHA6Ly9zY2hlbWFzLnhtbHNvYXAub3JnL3dzLzIwMDUvMDUvaWRlbnRpdHkvY2xhaW1zL3NpZCI6ImRkZGRkZGRkLWRkZGQtZGRkZC1kZGRkLWRkZGRkZGRkZGRkZCIsImlhdCI6MTc5MzE4MDQ5NSwiaXNzIjoiaHR0cHM6Ly90b2tlbi5hY3Rpb25zLmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImpvYl9pZCI6ImFkMjdjNDE4LWRjMzMtNTZlNy1hNDg2LWM5MGRhZTBlODkyMiIsImpvYl93b3JrZmxvd19yZWYiOiJmZWVkbWVwb3MvYWN0aW9ucy8uZ2l0aHViL3dvcmtmbG93cy9wdWJsaXNoLW5wbS1naXRodWIueWFtbEByZWZzL2hlYWRzL21haW4iLCJqb2Jfd29ya2Zsb3dfc2hhIjoiNTBmOTYzNDk4MWZjYjJjYTcwZjRlMTFkODNhMzM2Y2VhYmZjOGI3YSIsIm5hbWVpZCI6ImRkZGRkZGRkLWRkZGQtZGRkZC1kZGRkLWRkZGRkZGRkZGRkZCIsIm5iZiI6MTc5MzE4MDE5NSwib2lkY19leHRyYSI6IntcImFjdG9yXCI6XCJNaXJvb245OVwiLFwiYWN0b3JfaWRcIjpcIjY1NjM3NDIxXCIsXCJiYXNlX3JlZlwiOlwiXCIsXCJjaGVja19ydW5faWRcIjpcIjEyMjc0MTI2NjUwNlwiLFwiZXZlbnRfbmFtZVwiOlwid29ya2Zsb3dfZGlzcGF0Y2hcIixcImhlYWRfcmVmXCI6XCJcIixcImpvYl93b3JrZmxvd19yZWZcIjpcImZlZWRtZXBvcy9hY3Rpb25zLy5naXRodWIvd29ya2Zsb3dzL3B1Ymxpc2gtbnBtLWdpdGh1Yi55YW1sQHJlZnMvaGVhZHMvbWFpblwiLFwiam9iX3dvcmtmbG93X3NoYVwiOlwiNTBmOTYzNDk4MWZjYjJjYTcwZjRlMTFkODNhMzM2Y2VhYmZjOGI3YVwiLFwicmVmXCI6XCJyZWZzL2hlYWRzL2RldlwiLFwicmVmX3Byb3RlY3RlZFwiOlwiZmFsc2VcIixcInJlZl90eXBlXCI6XCJicmFuY2hcIixcInJlcG9zaXRvcnlcIjpcImZlZWRtZXBvcy9ocm0tc2VydmljZVwiLFwicmVwb3NpdG9yeV9pZFwiOlwiMTEyNDY3MjIzNVwiLFwicmVwb3NpdG9yeV9vd25lclwiOlwiZmVlZG1lcG9zXCIsXCJyZXBvc2l0b3J5X293bmVyX2lkXCI6XCI1NDgzMTUxNVwiLFwicmVwb3NpdG9yeV92aXNpYmlsaXR5XCI6XCJwcml2YXRlXCIsXCJydW5fYXR0ZW1wdFwiOlwiMVwiLFwicnVuX2lkXCI6XCI0MDY2NjIwODM1M1wiLFwicnVuX251bWJlclwiOlwiMjM2XCIsXCJydW5uZXJfZW52aXJvbm1lbnRcIjpcImdpdGh1Yi1ob3N0ZWRcIixcInNoYVwiOlwiZmU3ZjFiMDViOTllNjI4ODY1MGFkZjUzMjliNmUxODk3MmQ1NDExZFwiLFwid29ya2Zsb3dcIjpcIlB1Ymxpc2ggaHJtLXBvcnRhbFwiLFwid29ya2Zsb3dfcmVmXCI6XCJmZWVkbWVwb3MvaHJtLXNlcnZpY2UvLmdpdGh1Yi93b3JrZmxvd3MvcHVibGlzaC1ocm0tcG9ydGFsLXRydXN0ZWQueW1sQHJlZnMvaGVhZHMvZGV2XCIsXCJ3b3JrZmxvd19zaGFcIjpcImZlN2YxYjA1Yjk5ZTYyODg2NTBhZGY1MzI5YjZlMTg5NzJkNTQxMWRcIn0iLCJvaWRjX3N1YiI6InJlcG86ZmVlZG1lcG9zL2hybS1zZXJ2aWNlOnJlZjpyZWZzL2hlYWRzL2RldiIsIm9yY2hfaWQiOiIwMDhjOWU3MC0wNDk3LTQ5MTgtODhhYy1iMTc3NDAyYzE2ZmYucHVibGlzaC5wdWJsaXNoLl9fZGVmYXVsdCIsIm93bmVyX2lkIjoiRV9rZ0RPQUFKb1lRIiwicGxhbl9pZCI6IjAwOGM5ZTcwLTA0OTctNDkxOC04OGFjLWIxNzc0MDJjMTZmZiIsInJlcG9zaXRvcnlfaWQiOiIxMTI0NjcyMjM1IiwicmVwb3NpdG9yeV9vd25lcl9pZCI6IjU0ODMxNTE1IiwicmVwb3NpdG9yeV92aXNpYmlsaXR5IjoicHJpdmF0ZSIsInJ1bl9pZCI6IjQwNjY2MjA4MzUzIiwicnVuX251bWJlciI6IjIzNiIsInJ1bl90eXBlIjoiZnVsbCIsInJ1bm5lcl9pZCI6IjEwMDAyMzQ2MDciLCJydW5uZXJfdHlwZSI6Imhvc3RlZCIsInNjcCI6IkFjdGlvbnMuUmVzdWx0czowMDhjOWU3MC0wNDk3LTQ5MTgtODhhYy1iMTc3NDAyYzE2ZmY6YWQyN2M0MTgtZGMzMy01NmU3LWE0ODYtYzkwZGFlMGU4OTIyIEFjdGlvbnMuUnVubmVyOjAwOGM5ZTcwLTA0OTctNDkxOC04OGFjLWIxNzc0MDJjMTZmZjphZDI3YzQxOC1kYzMzLTU2ZTctYTQ4Ni1jOTBkYWUwZTg5MjIgQWN0aW9ucy5VcGxvYWRBcnRpZmFjdHM6MDA4YzllNzAtMDQ5Ny00OTE4LTg4YWMtYjE3NzQwMmMxNmZmOmFkMjdjNDE4LWRjMzMtNTZlNy1hNDg2LWM5MGRhZTBlODkyMiBnZW5lcmF0ZV9pZF90b2tlbjowMDhjOWU3MC0wNDk3LTQ5MTgtODhhYy1iMTc3NDAyYzE2ZmY6YWQyN2M0MTgtZGMzMy01NmU3LWE0ODYtYzkwZGFlMGU4OTIyIEFjdGlvbnMuR2VuZXJpY1JlYWQ6MDAwMDAwMDAtMDAwMC0wMDAwLTAwMDAtMDAwMDAwMDAwMDAwIiwic2hhIjoiZmU3ZjFiMDViOTllNjI4ODY1MGFkZjUzMjliNmUxODk3MmQ1NDExZCIsInRydXN0X3RpZXIiOiIxIn0.5GHRUFwdHzlrDkVlygGO1rJ2W_040QI5oeenowLHxHL1oFYyZziKozLXZack5mOrJhL5C90SrCQueOaEmmN90gYuvYcQxLzixk3PCHLCGHNjZMvr3AFjWPKDhg_vNrh4HXoI4exhHzUwQ9BJtxXaAgGr5IfQIxvXl2CxyXZHR4Z2AhE3CgzDwjpb5xb_5g5lfIO40x48CTXD3qA20OLClWwFQBTtlqemeg80iFuPZO2Eu9DLa6WG2uDVLHCl8QHtFaXgUq9pU7z4g2RNLyTt4h9_DKSjEa19uQV8XIj3unuh7i-jccvZXOJiGScP4uvdSh7Zz1aCrPHyxG8b3zILXA", GITHUB_ACTION_REPOSITORY: "", ENABLE_RUNNER_TRACING: "true", npm_config_node_gyp: "/home/runner/setup-pnpm/node_modules/.pnpm/pnpm@10.8.0/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@10.8.0/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@10.8.0/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_eb2c035e-f1e5-4f16-bf7e-6e8987cec911", INVOCATION_ID: "c8922d94fe3947c082d6dad12899af82", 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_5", GITHUB_RUN_NUMBER: "236", GITHUB_TRIGGERING_ACTOR: "Miroon99", RUNNER_ARCH: "X64", XDG_RUNTIME_DIR: "/run/user/1001", AGENT_TOOLSDIRECTORY: "/opt/hostedtoolcache", npm_config_frozen_lockfile: "", LANG: "C.UTF-8", VCPKG_INSTALLATION_ROOT: "/usr/local/share/vcpkg", RUNNER_NAME: "GitHub Actions 1000234607", XDG_CONFIG_HOME: "/home/runner/.config", GITHUB_REF_NAME: "dev", GITHUB_REPOSITORY: "feedmepos/hrm-service", 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", 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@10.8.0/node_modules/pnpm/bin/node_modules:/home/runner/setup-pnpm/node_modules/.pnpm/pnpm@10.8.0/node_modules/pnpm/node_modules:/home/runner/setup-pnpm/node_modules/.pnpm/pnpm@10.8.0/node_modules:/home/runner/setup-pnpm/node_modules/.pnpm/node_modules:/home/runner/setup-pnpm/node_modules/.pnpm/pnpm@10.8.0/node_modules/pnpm/bin/node_modules:/home/runner/setup-pnpm/node_modules/.pnpm/pnpm@10.8.0/node_modules/pnpm/node_modules:/home/runner/setup-pnpm/node_modules/.pnpm/pnpm@10.8.0/node_modules:/home/runner/setup-pnpm/node_modules/.pnpm/node_modules", npm_package_version: "2.3.2-dev.11", npm_config_verify_deps_before_run: "false", npm_lifecycle_event: "build:mf", GITHUB_REF_PROTECTED: "false", GITHUB_WORKSPACE: "/home/runner/work/hrm-service/hrm-service", ACCEPT_EULA: "Y", GITHUB_JOB: "publish", npm_config_overrides: '{"proxy-addr":">=2.0.8 <3","@fastify/busboy":">=3.2.1 <4","@grpc/grpc-js":">=1.14.5 <2","brace-expansion@^2":"^2.1.6","js-yaml@^4":"^4.3.2","source-map-js":"^1.2.2","dompurify":">=3.4.17 <4","undici@^6":">=6.29.1 <7","body-parser@^1":">=1.20.9 <2","multer":">=2.5.0 <3"}', npm_config_package_extensions: '{"@feedmepos/entity":{"dependencies":{"@feedmepos/core":"2.14.52"}}}', GITHUB_SHA: "fe7f1b05b99e6288650adf5329b6e18972d5411d", GITHUB_RUN_ATTEMPT: "1", ACTIONS_RUNNER_RETURN_JOB_RESULT_FOR_HOSTED: "1", GITHUB_REF: "refs/heads/dev", GITHUB_ACTOR: "Miroon99", ANDROID_SDK_ROOT: "/usr/local/lib/android/sdk", VITE_TARGET_ENV: "dev", GITHUB_PATH: "/home/runner/work/_temp/_runner_file_commands/add_path_c8e66e05-10fa-45eb-aebb-34c3296d2aa4", JAVA_HOME: "/usr/lib/jvm/temurin-25-jdk-amd64", PWD: "/home/runner/work/hrm-service/hrm-service/apps/hrm-portal", GITHUB_ACTOR_ID: "65637421", RUNNER_WORKSPACE: "/home/runner/work/hrm-service", npm_config_link_workspace_packages: "true", npm_execpath: "/home/runner/setup-pnpm/node_modules/.pnpm/pnpm@10.8.0/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/39//idtoken/008c9e70-0497-4918-88ac-b177402c16ff/ad27c418-dc33-56e7-a486-c90dae0e8922?api-version=2.0", GHCUP_INSTALL_BASE_PREFIX: "/usr/local", GITHUB_OUTPUT: "/home/runner/work/_temp/_runner_file_commands/set_output_c8e66e05-10fa-45eb-aebb-34c3296d2aa4", EDGEWEBDRIVER: "/usr/local/share/edge_driver", PNPM_SCRIPT_SRC_DIR: "/home/runner/work/hrm-service/hrm-service/apps/hrm-portal", npm_command: "run-script", ANDROID_NDK: "/usr/local/lib/android/sdk/ndk/27.3.13750724", GITHUB_ARTIFACTS_LIST: "/home/runner/work/_temp/_runner_file_commands/artifacts_list_c8e66e05-10fa-45eb-aebb-34c3296d2aa4", SGX_AESM_ADDR: "1", PSModulePath: "/root/.local/share/powershell/Modules:/usr/local/share/powershell/Modules:/opt/microsoft/powershell/7/Modules:/usr/share/az_15.6.1", 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_c8e66e05-10fa-45eb-aebb-34c3296d2aa4", INIT_CWD: "/home/runner/work/hrm-service/hrm-service/apps/hrm-portal", NODE_ENV: "production" } };
|
|
1860
|
-
const ya = "10.0.5";
|
|
1861
|
-
function Ia() {
|
|
1862
|
-
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);
|
|
1863
|
-
}
|
|
1864
|
-
const lt = {
|
|
1865
|
-
// composer module errors
|
|
1866
|
-
UNEXPECTED_RETURN_TYPE: Us,
|
|
1867
|
-
// 24
|
|
1868
|
-
// legacy module errors
|
|
1869
|
-
INVALID_ARGUMENT: 25,
|
|
1870
|
-
// i18n module errors
|
|
1871
|
-
MUST_BE_CALL_SETUP_TOP: 26,
|
|
1872
|
-
NOT_INSTALLED: 27,
|
|
1873
|
-
NOT_INSTALLED_WITH_PROVIDE: 31,
|
|
1874
|
-
// unexpected error
|
|
1875
|
-
UNEXPECTED_ERROR: 32
|
|
1876
|
-
};
|
|
1877
|
-
function mt(e, ...t) {
|
|
1878
|
-
return Nt(e, null, void 0);
|
|
1879
|
-
}
|
|
1880
|
-
const xt = /* @__PURE__ */ ze("__translateVNode"), Vt = /* @__PURE__ */ ze("__datetimeParts"), Gt = /* @__PURE__ */ ze("__numberParts"), Ea = ze("__setPluralRules"), rr = /* @__PURE__ */ ze("__injectWithOption"), Wt = /* @__PURE__ */ ze("__dispose");
|
|
1881
|
-
function dt(e) {
|
|
1882
|
-
if (!ee(e))
|
|
1883
|
-
return e;
|
|
1884
|
-
for (const t in e)
|
|
1885
|
-
if (Se(e, t))
|
|
1886
|
-
if (!t.includes("."))
|
|
1887
|
-
ee(e[t]) && dt(e[t]);
|
|
1888
|
-
else {
|
|
1889
|
-
const n = t.split("."), r = n.length - 1;
|
|
1890
|
-
let a = e, o = !1;
|
|
1891
|
-
for (let f = 0; f < r; f++) {
|
|
1892
|
-
if (n[f] in a || (a[n[f]] = se()), !ee(a[n[f]])) {
|
|
1893
|
-
o = !0;
|
|
1894
|
-
break;
|
|
1895
|
-
}
|
|
1896
|
-
a = a[n[f]];
|
|
1897
|
-
}
|
|
1898
|
-
o || (a[n[r]] = e[t], delete e[t]), ee(a[n[r]]) && dt(a[n[r]]);
|
|
1899
|
-
}
|
|
1900
|
-
return e;
|
|
1901
|
-
}
|
|
1902
|
-
function sr(e, t) {
|
|
1903
|
-
const { messages: n, __i18n: r, messageResolver: a, flatJson: o } = t, f = q(n) ? n : pe(r) ? se() : { [e]: se() };
|
|
1904
|
-
if (pe(r) && r.forEach((d) => {
|
|
1905
|
-
if ("locale" in d && "resource" in d) {
|
|
1906
|
-
const { locale: i, resource: b } = d;
|
|
1907
|
-
i ? (f[i] = f[i] || se(), yt(b, f[i])) : yt(b, f);
|
|
1908
|
-
} else
|
|
1909
|
-
G(d) && yt(JSON.parse(d), f);
|
|
1910
|
-
}), a == null && o)
|
|
1911
|
-
for (const d in f)
|
|
1912
|
-
Se(f, d) && dt(f[d]);
|
|
1913
|
-
return f;
|
|
1914
|
-
}
|
|
1915
|
-
function ar(e) {
|
|
1916
|
-
return e.type;
|
|
1917
|
-
}
|
|
1918
|
-
function Ca(e, t, n) {
|
|
1919
|
-
let r = ee(t.messages) ? t.messages : se();
|
|
1920
|
-
"__i18nGlobal" in n && (r = sr(e.locale.value, {
|
|
1921
|
-
messages: r,
|
|
1922
|
-
__i18n: n.__i18nGlobal
|
|
1923
|
-
}));
|
|
1924
|
-
const a = Object.keys(r);
|
|
1925
|
-
a.length && a.forEach((o) => {
|
|
1926
|
-
e.mergeLocaleMessage(o, r[o]);
|
|
1927
|
-
});
|
|
1928
|
-
{
|
|
1929
|
-
if (ee(t.datetimeFormats)) {
|
|
1930
|
-
const o = Object.keys(t.datetimeFormats);
|
|
1931
|
-
o.length && o.forEach((f) => {
|
|
1932
|
-
e.mergeDateTimeFormat(f, t.datetimeFormats[f]);
|
|
1933
|
-
});
|
|
1934
|
-
}
|
|
1935
|
-
if (ee(t.numberFormats)) {
|
|
1936
|
-
const o = Object.keys(t.numberFormats);
|
|
1937
|
-
o.length && o.forEach((f) => {
|
|
1938
|
-
e.mergeNumberFormat(f, t.numberFormats[f]);
|
|
1939
|
-
});
|
|
1940
|
-
}
|
|
1941
|
-
}
|
|
1942
|
-
}
|
|
1943
|
-
function On(e) {
|
|
1944
|
-
return oe(fr, null, e, 0);
|
|
1945
|
-
}
|
|
1946
|
-
const Ln = "__INTLIFY_META__", Sn = () => [], Na = () => !1;
|
|
1947
|
-
let Rn = 0;
|
|
1948
|
-
function An(e) {
|
|
1949
|
-
return (t, n, r, a) => e(n, r, Yt() || void 0, a);
|
|
1950
|
-
}
|
|
1951
|
-
const Ta = /* @__NO_SIDE_EFFECTS__ */ () => {
|
|
1952
|
-
const e = Yt();
|
|
1953
|
-
let t = null;
|
|
1954
|
-
return e && (t = ar(e)[Ln]) ? { [Ln]: t } : null;
|
|
1955
|
-
};
|
|
1956
|
-
function Oa(e = {}) {
|
|
1957
|
-
const { __root: t, __injectWithOption: n } = e, r = t === void 0, a = e.flatJson, o = sn ? st : mr;
|
|
1958
|
-
let f = _e(e.inheritLocale) ? e.inheritLocale : !0;
|
|
1959
|
-
const d = o(
|
|
1960
|
-
// prettier-ignore
|
|
1961
|
-
t && f ? t.locale.value : G(e.locale) ? e.locale : Et
|
|
1962
|
-
), i = o(
|
|
1963
|
-
// prettier-ignore
|
|
1964
|
-
t && f ? t.fallbackLocale.value : G(e.fallbackLocale) || pe(e.fallbackLocale) || q(e.fallbackLocale) || e.fallbackLocale === !1 ? e.fallbackLocale : d.value
|
|
1965
|
-
), b = o(sr(d.value, e)), E = o(q(e.datetimeFormats) ? e.datetimeFormats : { [d.value]: {} }), N = o(q(e.numberFormats) ? e.numberFormats : { [d.value]: {} });
|
|
1966
|
-
let T = t ? t.missingWarn : _e(e.missingWarn) || It(e.missingWarn) ? e.missingWarn : !0, D = t ? t.fallbackWarn : _e(e.fallbackWarn) || It(e.fallbackWarn) ? e.fallbackWarn : !0, k = t ? t.fallbackRoot : _e(e.fallbackRoot) ? e.fallbackRoot : !0, R = !!e.fallbackFormat, M = ue(e.missing) ? e.missing : null, p = ue(e.missing) ? An(e.missing) : null, h = ue(e.postTranslation) ? e.postTranslation : null, L = t ? t.warnHtmlMessage : _e(e.warnHtmlMessage) ? e.warnHtmlMessage : !0, m = !!e.escapeParameter;
|
|
1967
|
-
const g = t ? t.modifiers : q(e.modifiers) ? e.modifiers : {};
|
|
1968
|
-
let I = e.pluralRules || t && t.pluralRules, v;
|
|
1969
|
-
v = (() => {
|
|
1970
|
-
r && hn(null);
|
|
1971
|
-
const u = {
|
|
1972
|
-
version: ya,
|
|
1973
|
-
locale: d.value,
|
|
1974
|
-
fallbackLocale: i.value,
|
|
1975
|
-
messages: b.value,
|
|
1976
|
-
modifiers: g,
|
|
1977
|
-
pluralRules: I,
|
|
1978
|
-
missing: p === null ? void 0 : p,
|
|
1979
|
-
missingWarn: T,
|
|
1980
|
-
fallbackWarn: D,
|
|
1981
|
-
fallbackFormat: R,
|
|
1982
|
-
unresolving: !0,
|
|
1983
|
-
postTranslation: h === null ? void 0 : h,
|
|
1984
|
-
warnHtmlMessage: L,
|
|
1985
|
-
escapeParameter: m,
|
|
1986
|
-
messageResolver: e.messageResolver,
|
|
1987
|
-
messageCompiler: e.messageCompiler,
|
|
1988
|
-
__meta: { framework: "vue" }
|
|
1989
|
-
};
|
|
1990
|
-
u.datetimeFormats = E.value, u.numberFormats = N.value, u.__datetimeFormatters = q(v) ? v.__datetimeFormatters : void 0, u.__numberFormatters = q(v) ? v.__numberFormatters : void 0;
|
|
1991
|
-
const C = sa(u);
|
|
1992
|
-
return r && hn(C), C;
|
|
1993
|
-
})(), it(v, d.value, i.value);
|
|
1994
|
-
function S() {
|
|
1995
|
-
return [
|
|
1996
|
-
d.value,
|
|
1997
|
-
i.value,
|
|
1998
|
-
b.value,
|
|
1999
|
-
E.value,
|
|
2000
|
-
N.value
|
|
2001
|
-
];
|
|
2002
|
-
}
|
|
2003
|
-
const H = K({
|
|
2004
|
-
get: () => d.value,
|
|
2005
|
-
set: (u) => {
|
|
2006
|
-
d.value = u, v.locale = d.value;
|
|
2007
|
-
}
|
|
2008
|
-
}), x = K({
|
|
2009
|
-
get: () => i.value,
|
|
2010
|
-
set: (u) => {
|
|
2011
|
-
i.value = u, v.fallbackLocale = i.value, it(v, d.value, u);
|
|
2012
|
-
}
|
|
2013
|
-
}), _ = K(() => b.value), O = /* @__PURE__ */ K(() => E.value), P = /* @__PURE__ */ K(() => N.value);
|
|
2014
|
-
function F() {
|
|
2015
|
-
return ue(h) ? h : null;
|
|
2016
|
-
}
|
|
2017
|
-
function w(u) {
|
|
2018
|
-
h = u, v.postTranslation = u;
|
|
2019
|
-
}
|
|
2020
|
-
function V() {
|
|
2021
|
-
return M;
|
|
2022
|
-
}
|
|
2023
|
-
function j(u) {
|
|
2024
|
-
u !== null && (p = An(u)), M = u, v.missing = p;
|
|
2025
|
-
}
|
|
2026
|
-
const Z = (u, C, Q, J, me, We) => {
|
|
2027
|
-
S();
|
|
2028
|
-
let qe;
|
|
2029
|
-
try {
|
|
2030
|
-
ga.env.NODE_ENV !== "production" || __INTLIFY_PROD_DEVTOOLS__, r || (v.fallbackContext = t ? ra() : void 0), qe = u(v);
|
|
2031
|
-
} finally {
|
|
2032
|
-
__INTLIFY_PROD_DEVTOOLS__, r || (v.fallbackContext = void 0);
|
|
2033
|
-
}
|
|
2034
|
-
if (Q !== "translate exists" && // for not `te` (e.g `t`)
|
|
2035
|
-
be(qe) && qe === Tt || Q === "translate exists" && !qe) {
|
|
2036
|
-
const [cr, po] = C();
|
|
2037
|
-
return t && k ? J(t) : me(cr);
|
|
2038
|
-
} else {
|
|
2039
|
-
if (We(qe))
|
|
2040
|
-
return qe;
|
|
2041
|
-
throw mt(lt.UNEXPECTED_RETURN_TYPE);
|
|
2042
|
-
}
|
|
2043
|
-
};
|
|
2044
|
-
function X(...u) {
|
|
2045
|
-
return Z((C) => Reflect.apply(Tn, null, [C, ...u]), () => Ut(...u), "translate", (C) => Reflect.apply(C.t, C, [...u]), (C) => C, (C) => G(C));
|
|
2046
|
-
}
|
|
2047
|
-
function te(...u) {
|
|
2048
|
-
const [C, Q, J] = u;
|
|
2049
|
-
if (J && !ee(J))
|
|
2050
|
-
throw mt(lt.INVALID_ARGUMENT);
|
|
2051
|
-
return X(C, Q, ge({ resolvedMessage: !0 }, J || {}));
|
|
2052
|
-
}
|
|
2053
|
-
function z(...u) {
|
|
2054
|
-
return Z((C) => Reflect.apply(gn, null, [C, ...u]), () => Pt(...u), "datetime format", (C) => Reflect.apply(C.d, C, [...u]), () => pn, (C) => G(C));
|
|
2055
|
-
}
|
|
2056
|
-
function de(...u) {
|
|
2057
|
-
return Z((C) => Reflect.apply(In, null, [C, ...u]), () => jt(...u), "number format", (C) => Reflect.apply(C.n, C, [...u]), () => pn, (C) => G(C));
|
|
2058
|
-
}
|
|
2059
|
-
function ve(u) {
|
|
2060
|
-
return u.map((C) => G(C) || be(C) || _e(C) ? On(String(C)) : C);
|
|
2061
|
-
}
|
|
2062
|
-
const ae = {
|
|
2063
|
-
normalize: ve,
|
|
2064
|
-
interpolate: (u) => u,
|
|
2065
|
-
type: "vnode"
|
|
2066
|
-
};
|
|
2067
|
-
function le(...u) {
|
|
2068
|
-
return Z((C) => {
|
|
2069
|
-
let Q;
|
|
2070
|
-
const J = C;
|
|
2071
|
-
try {
|
|
2072
|
-
J.processor = ae, Q = Reflect.apply(Tn, null, [J, ...u]);
|
|
2073
|
-
} finally {
|
|
2074
|
-
J.processor = null;
|
|
2075
|
-
}
|
|
2076
|
-
return Q;
|
|
2077
|
-
}, () => Ut(...u), "translate", (C) => C[xt](...u), (C) => [On(C)], (C) => pe(C));
|
|
2078
|
-
}
|
|
2079
|
-
function Ae(...u) {
|
|
2080
|
-
return Z((C) => Reflect.apply(In, null, [C, ...u]), () => jt(...u), "number format", (C) => C[Gt](...u), Sn, (C) => G(C) || pe(C));
|
|
2081
|
-
}
|
|
2082
|
-
function Y(...u) {
|
|
2083
|
-
return Z((C) => Reflect.apply(gn, null, [C, ...u]), () => Pt(...u), "datetime format", (C) => C[Vt](...u), Sn, (C) => G(C) || pe(C));
|
|
2084
|
-
}
|
|
2085
|
-
function fe(u) {
|
|
2086
|
-
I = u, v.pluralRules = I;
|
|
2087
|
-
}
|
|
2088
|
-
function $e(u, C) {
|
|
2089
|
-
return Z(() => {
|
|
2090
|
-
if (!u)
|
|
2091
|
-
return !1;
|
|
2092
|
-
const Q = G(C) ? C : d.value, J = we(Q), me = v.messageResolver(J, u);
|
|
2093
|
-
return ot(me) || Te(me) || G(me);
|
|
2094
|
-
}, () => [u], "translate exists", (Q) => Reflect.apply(Q.te, Q, [u, C]), Na, (Q) => _e(Q));
|
|
2095
|
-
}
|
|
2096
|
-
function Qe(u) {
|
|
2097
|
-
let C = null;
|
|
2098
|
-
const Q = Hn(v, i.value, d.value);
|
|
2099
|
-
for (let J = 0; J < Q.length; J++) {
|
|
2100
|
-
const me = b.value[Q[J]] || {}, We = v.messageResolver(me, u);
|
|
2101
|
-
if (We != null) {
|
|
2102
|
-
C = We;
|
|
2103
|
-
break;
|
|
2104
|
-
}
|
|
2105
|
-
}
|
|
2106
|
-
return C;
|
|
2107
|
-
}
|
|
2108
|
-
function Ve(u) {
|
|
2109
|
-
const C = Qe(u);
|
|
2110
|
-
return C ?? (t ? t.tm(u) || {} : {});
|
|
2111
|
-
}
|
|
2112
|
-
function we(u) {
|
|
2113
|
-
return b.value[u] || {};
|
|
2114
|
-
}
|
|
2115
|
-
function Fe(u, C) {
|
|
2116
|
-
if (a) {
|
|
2117
|
-
const Q = { [u]: C };
|
|
2118
|
-
for (const J in Q)
|
|
2119
|
-
Se(Q, J) && dt(Q[J]);
|
|
2120
|
-
C = Q[u];
|
|
2121
|
-
}
|
|
2122
|
-
b.value[u] = C, v.messages = b.value;
|
|
2123
|
-
}
|
|
2124
|
-
function Ge(u, C) {
|
|
2125
|
-
b.value[u] = b.value[u] || {};
|
|
2126
|
-
const Q = { [u]: C };
|
|
2127
|
-
if (a)
|
|
2128
|
-
for (const J in Q)
|
|
2129
|
-
Se(Q, J) && dt(Q[J]);
|
|
2130
|
-
C = Q[u], yt(C, b.value[u]), v.messages = b.value;
|
|
2131
|
-
}
|
|
2132
|
-
function Pe(u) {
|
|
2133
|
-
return E.value[u] || {};
|
|
2134
|
-
}
|
|
2135
|
-
function l(u, C) {
|
|
2136
|
-
E.value[u] = C, v.datetimeFormats = E.value, yn(v, u, C);
|
|
2137
|
-
}
|
|
2138
|
-
function s(u, C) {
|
|
2139
|
-
E.value[u] = ge(E.value[u] || {}, C), v.datetimeFormats = E.value, yn(v, u, C);
|
|
2140
|
-
}
|
|
2141
|
-
function c(u) {
|
|
2142
|
-
return N.value[u] || {};
|
|
2143
|
-
}
|
|
2144
|
-
function y(u, C) {
|
|
2145
|
-
N.value[u] = C, v.numberFormats = N.value, En(v, u, C);
|
|
2146
|
-
}
|
|
2147
|
-
function U(u, C) {
|
|
2148
|
-
N.value[u] = ge(N.value[u] || {}, C), v.numberFormats = N.value, En(v, u, C);
|
|
2149
|
-
}
|
|
2150
|
-
Rn++, t && sn && (Mt(t.locale, (u) => {
|
|
2151
|
-
f && (d.value = u, v.locale = u, it(v, d.value, i.value));
|
|
2152
|
-
}), Mt(t.fallbackLocale, (u) => {
|
|
2153
|
-
f && (i.value = u, v.fallbackLocale = u, it(v, d.value, i.value));
|
|
2154
|
-
}));
|
|
2155
|
-
const W = {
|
|
2156
|
-
id: Rn,
|
|
2157
|
-
locale: H,
|
|
2158
|
-
fallbackLocale: x,
|
|
2159
|
-
get inheritLocale() {
|
|
2160
|
-
return f;
|
|
2161
|
-
},
|
|
2162
|
-
set inheritLocale(u) {
|
|
2163
|
-
f = u, u && t && (d.value = t.locale.value, i.value = t.fallbackLocale.value, it(v, d.value, i.value));
|
|
2164
|
-
},
|
|
2165
|
-
get availableLocales() {
|
|
2166
|
-
return Object.keys(b.value).sort();
|
|
2167
|
-
},
|
|
2168
|
-
messages: _,
|
|
2169
|
-
get modifiers() {
|
|
2170
|
-
return g;
|
|
2171
|
-
},
|
|
2172
|
-
get pluralRules() {
|
|
2173
|
-
return I || {};
|
|
2174
|
-
},
|
|
2175
|
-
get isGlobal() {
|
|
2176
|
-
return r;
|
|
2177
|
-
},
|
|
2178
|
-
get missingWarn() {
|
|
2179
|
-
return T;
|
|
2180
|
-
},
|
|
2181
|
-
set missingWarn(u) {
|
|
2182
|
-
T = u, v.missingWarn = T;
|
|
2183
|
-
},
|
|
2184
|
-
get fallbackWarn() {
|
|
2185
|
-
return D;
|
|
2186
|
-
},
|
|
2187
|
-
set fallbackWarn(u) {
|
|
2188
|
-
D = u, v.fallbackWarn = D;
|
|
2189
|
-
},
|
|
2190
|
-
get fallbackRoot() {
|
|
2191
|
-
return k;
|
|
2192
|
-
},
|
|
2193
|
-
set fallbackRoot(u) {
|
|
2194
|
-
k = u;
|
|
2195
|
-
},
|
|
2196
|
-
get fallbackFormat() {
|
|
2197
|
-
return R;
|
|
2198
|
-
},
|
|
2199
|
-
set fallbackFormat(u) {
|
|
2200
|
-
R = u, v.fallbackFormat = R;
|
|
2201
|
-
},
|
|
2202
|
-
get warnHtmlMessage() {
|
|
2203
|
-
return L;
|
|
2204
|
-
},
|
|
2205
|
-
set warnHtmlMessage(u) {
|
|
2206
|
-
L = u, v.warnHtmlMessage = u;
|
|
2207
|
-
},
|
|
2208
|
-
get escapeParameter() {
|
|
2209
|
-
return m;
|
|
2210
|
-
},
|
|
2211
|
-
set escapeParameter(u) {
|
|
2212
|
-
m = u, v.escapeParameter = u;
|
|
2213
|
-
},
|
|
2214
|
-
t: X,
|
|
2215
|
-
getLocaleMessage: we,
|
|
2216
|
-
setLocaleMessage: Fe,
|
|
2217
|
-
mergeLocaleMessage: Ge,
|
|
2218
|
-
getPostTranslationHandler: F,
|
|
2219
|
-
setPostTranslationHandler: w,
|
|
2220
|
-
getMissingHandler: V,
|
|
2221
|
-
setMissingHandler: j,
|
|
2222
|
-
[Ea]: fe
|
|
2223
|
-
};
|
|
2224
|
-
return W.datetimeFormats = O, W.numberFormats = P, W.rt = te, W.te = $e, W.tm = Ve, W.d = z, W.n = de, W.getDateTimeFormat = Pe, W.setDateTimeFormat = l, W.mergeDateTimeFormat = s, W.getNumberFormat = c, W.setNumberFormat = y, W.mergeNumberFormat = U, W[rr] = n, W[xt] = le, W[Vt] = Y, W[Gt] = Ae, W;
|
|
2225
|
-
}
|
|
2226
|
-
const Qt = {
|
|
2227
|
-
tag: {
|
|
2228
|
-
type: [String, Object]
|
|
2229
|
-
},
|
|
2230
|
-
locale: {
|
|
2231
|
-
type: String
|
|
2232
|
-
},
|
|
2233
|
-
scope: {
|
|
2234
|
-
type: String,
|
|
2235
|
-
// NOTE: avoid https://github.com/microsoft/rushstack/issues/1050
|
|
2236
|
-
validator: (e) => e === "parent" || e === "global",
|
|
2237
|
-
default: "parent"
|
|
2238
|
-
/* ComponentI18nScope */
|
|
2239
|
-
},
|
|
2240
|
-
i18n: {
|
|
2241
|
-
type: Object
|
|
2242
|
-
}
|
|
2243
|
-
};
|
|
2244
|
-
function La({ slots: e }, t) {
|
|
2245
|
-
return t.length === 1 && t[0] === "default" ? (e.default ? e.default() : []).reduce((r, a) => [
|
|
2246
|
-
...r,
|
|
2247
|
-
// prettier-ignore
|
|
2248
|
-
...a.type === Me ? a.children : [a]
|
|
2249
|
-
], []) : t.reduce((n, r) => {
|
|
2250
|
-
const a = e[r];
|
|
2251
|
-
return a && (n[r] = a()), n;
|
|
2252
|
-
}, se());
|
|
2253
|
-
}
|
|
2254
|
-
function or() {
|
|
2255
|
-
return Me;
|
|
2256
|
-
}
|
|
2257
|
-
ge({
|
|
2258
|
-
keypath: {
|
|
2259
|
-
type: String,
|
|
2260
|
-
required: !0
|
|
2261
|
-
},
|
|
2262
|
-
plural: {
|
|
2263
|
-
type: [Number, String],
|
|
2264
|
-
validator: (e) => be(e) || !isNaN(e)
|
|
2265
|
-
}
|
|
2266
|
-
}, Qt);
|
|
2267
|
-
function Sa(e) {
|
|
2268
|
-
return pe(e) && !G(e[0]);
|
|
2269
|
-
}
|
|
2270
|
-
function lr(e, t, n, r) {
|
|
2271
|
-
const { slots: a, attrs: o } = t;
|
|
2272
|
-
return () => {
|
|
2273
|
-
const f = { part: !0 };
|
|
2274
|
-
let d = se();
|
|
2275
|
-
e.locale && (f.locale = e.locale), G(e.format) ? f.key = e.format : ee(e.format) && (G(e.format.key) && (f.key = e.format.key), d = Object.keys(e.format).reduce((T, D) => n.includes(D) ? ge(se(), T, { [D]: e.format[D] }) : T, se()));
|
|
2276
|
-
const i = r(e.value, f, d);
|
|
2277
|
-
let b = [f.key];
|
|
2278
|
-
pe(i) ? b = i.map((T, D) => {
|
|
2279
|
-
const k = a[T.type], R = k ? k({ [T.type]: T.value, index: D, parts: i }) : [T.value];
|
|
2280
|
-
return Sa(R) && (R[0].key = `${T.type}-${D}`), R;
|
|
2281
|
-
}) : G(i) && (b = [i]);
|
|
2282
|
-
const E = ge(se(), o), N = G(e.tag) || ee(e.tag) ? e.tag : or();
|
|
2283
|
-
return Vn(N, E, b);
|
|
2284
|
-
};
|
|
2285
|
-
}
|
|
2286
|
-
ge({
|
|
2287
|
-
value: {
|
|
2288
|
-
type: Number,
|
|
2289
|
-
required: !0
|
|
2290
|
-
},
|
|
2291
|
-
format: {
|
|
2292
|
-
type: [String, Object]
|
|
2293
|
-
}
|
|
2294
|
-
}, Qt);
|
|
2295
|
-
ge({
|
|
2296
|
-
value: {
|
|
2297
|
-
type: [Number, Date],
|
|
2298
|
-
required: !0
|
|
2299
|
-
},
|
|
2300
|
-
format: {
|
|
2301
|
-
type: [String, Object]
|
|
2302
|
-
}
|
|
2303
|
-
}, Qt);
|
|
2304
|
-
const Ra = /* @__PURE__ */ ze("global-vue-i18n");
|
|
2305
|
-
function Ot(e = {}) {
|
|
2306
|
-
const t = Yt();
|
|
2307
|
-
if (t == null)
|
|
2308
|
-
throw mt(lt.MUST_BE_CALL_SETUP_TOP);
|
|
2309
|
-
if (!t.isCE && t.appContext.app != null && !t.appContext.app.__VUE_I18N_SYMBOL__)
|
|
2310
|
-
throw mt(lt.NOT_INSTALLED);
|
|
2311
|
-
const n = Aa(t), r = Ma(n), a = ar(t), o = ka(e, a);
|
|
2312
|
-
if (o === "global")
|
|
2313
|
-
return Ca(r, e, a), r;
|
|
2314
|
-
if (o === "parent") {
|
|
2315
|
-
let i = Da(n, t, e.__useComponent);
|
|
2316
|
-
return i == null && (i = r), i;
|
|
2317
|
-
}
|
|
2318
|
-
const f = n;
|
|
2319
|
-
let d = f.__getInstance(t);
|
|
2320
|
-
if (d == null) {
|
|
2321
|
-
const i = ge({}, e);
|
|
2322
|
-
"__i18n" in a && (i.__i18n = a.__i18n), r && (i.__root = r), d = Oa(i), f.__composerExtend && (d[Wt] = f.__composerExtend(d)), Fa(f, t, d), f.__setInstance(t, d);
|
|
2323
|
-
}
|
|
2324
|
-
return d;
|
|
2325
|
-
}
|
|
2326
|
-
function Aa(e) {
|
|
2327
|
-
const t = ur(e.isCE ? Ra : e.appContext.app.__VUE_I18N_SYMBOL__);
|
|
2328
|
-
if (!t)
|
|
2329
|
-
throw mt(e.isCE ? lt.NOT_INSTALLED_WITH_PROVIDE : lt.UNEXPECTED_ERROR);
|
|
2330
|
-
return t;
|
|
2331
|
-
}
|
|
2332
|
-
function ka(e, t) {
|
|
2333
|
-
return Ct(e) ? "__i18n" in t ? "local" : "global" : e.useScope ? e.useScope : "local";
|
|
2334
|
-
}
|
|
2335
|
-
function Ma(e) {
|
|
2336
|
-
return e.mode === "composition" ? e.global : e.global.__composer;
|
|
2337
|
-
}
|
|
2338
|
-
function Da(e, t, n = !1) {
|
|
2339
|
-
let r = null;
|
|
2340
|
-
const a = t.root;
|
|
2341
|
-
let o = wa(t, n);
|
|
2342
|
-
for (; o != null; ) {
|
|
2343
|
-
const f = e;
|
|
2344
|
-
if (e.mode === "composition")
|
|
2345
|
-
r = f.__getInstance(o);
|
|
2346
|
-
else if (__VUE_I18N_LEGACY_API__) {
|
|
2347
|
-
const d = f.__getInstance(o);
|
|
2348
|
-
d != null && (r = d.__composer, n && r && !r[rr] && (r = null));
|
|
2349
|
-
}
|
|
2350
|
-
if (r != null || a === o)
|
|
2351
|
-
break;
|
|
2352
|
-
o = o.parent;
|
|
2353
|
-
}
|
|
2354
|
-
return r;
|
|
2355
|
-
}
|
|
2356
|
-
function wa(e, t = !1) {
|
|
2357
|
-
return e == null ? null : t && e.vnode.ctx || e.parent;
|
|
2358
|
-
}
|
|
2359
|
-
function Fa(e, t, n) {
|
|
2360
|
-
xn(() => {
|
|
2361
|
-
}, t), dr(() => {
|
|
2362
|
-
const r = n;
|
|
2363
|
-
e.__deleteInstance(t);
|
|
2364
|
-
const a = r[Wt];
|
|
2365
|
-
a && (a(), delete r[Wt]);
|
|
2366
|
-
}, t);
|
|
2367
|
-
}
|
|
2368
|
-
Ia();
|
|
2369
|
-
Qs(Ds);
|
|
2370
|
-
qs(Js);
|
|
2371
|
-
ea(Hn);
|
|
2372
|
-
if (__INTLIFY_PROD_DEVTOOLS__) {
|
|
2373
|
-
const e = Je();
|
|
2374
|
-
e.__INTLIFY__ = !0, ws(e.__INTLIFY_DEVTOOLS_GLOBAL_HOOK__);
|
|
2375
|
-
}
|
|
2376
|
-
const vt = /* @__PURE__ */ Re({
|
|
2377
|
-
__name: "InheritPermissionTooltip",
|
|
2378
|
-
props: {
|
|
2379
|
-
item: {
|
|
2380
|
-
type: Object,
|
|
2381
|
-
required: !0
|
|
2382
|
-
}
|
|
2383
|
-
},
|
|
2384
|
-
setup(e) {
|
|
2385
|
-
const { t } = Ot();
|
|
2386
|
-
return (n, r) => {
|
|
2387
|
-
const a = De("FmIcon"), o = De("FmTooltip");
|
|
2388
|
-
return $(), Ne(o, {
|
|
2389
|
-
variant: "plain",
|
|
2390
|
-
placement: "right",
|
|
2391
|
-
"z-index": 50
|
|
2392
|
-
}, {
|
|
2393
|
-
content: ce(() => [
|
|
2394
|
-
ie("div", null, Oe(B(t)("team.memberForm.permissions.inherited")), 1),
|
|
2395
|
-
($(!0), re(Me, null, Ee(e.item.setNames, (f) => ($(), re("div", { key: f }, [
|
|
2396
|
-
ie("div", null, "- " + Oe(f), 1)
|
|
2397
|
-
]))), 128))
|
|
2398
|
-
]),
|
|
2399
|
-
default: ce(() => [
|
|
2400
|
-
oe(a, {
|
|
2401
|
-
name: "admin_panel_settings",
|
|
2402
|
-
size: "sm",
|
|
2403
|
-
class: "ml-1 text-fm-color-typo-info"
|
|
2404
|
-
})
|
|
2405
|
-
]),
|
|
2406
|
-
_: 1
|
|
2407
|
-
});
|
|
2408
|
-
};
|
|
2409
|
-
}
|
|
2410
|
-
});
|
|
2411
|
-
function kn(e, t, n) {
|
|
2412
|
-
const r = n.filter((d) => d !== "manage");
|
|
2413
|
-
if (r.length === 0) return;
|
|
2414
|
-
const a = e.findIndex((d) => d.subject === t && !d.inverted);
|
|
2415
|
-
if (a < 0) return;
|
|
2416
|
-
const o = new Set(e[a].actions), f = r.every((d) => o.has(d));
|
|
2417
|
-
f && !o.has("manage") ? (o.add("manage"), e[a] = {
|
|
2418
|
-
...e[a],
|
|
2419
|
-
actions: Array.from(o)
|
|
2420
|
-
}) : !f && o.has("manage") && (o.delete("manage"), o.size === 0 ? e.splice(a, 1) : e[a] = {
|
|
2421
|
-
...e[a],
|
|
2422
|
-
actions: Array.from(o)
|
|
2423
|
-
});
|
|
2424
|
-
}
|
|
2425
|
-
const Mn = Object.values(Ar), Pa = {
|
|
2426
|
-
read: "View",
|
|
2427
|
-
create: "Duplicate",
|
|
2428
|
-
update: "Edit"
|
|
2429
|
-
};
|
|
2430
|
-
function ja(e, t, n, r) {
|
|
2431
|
-
const { t: a } = Ke(), { getFlagValue: o, getFlag: f } = Rr(), d = K(() => {
|
|
2432
|
-
var w;
|
|
2433
|
-
const _ = /* @__PURE__ */ new Map(), O = /* @__PURE__ */ new Map(), P = /* @__PURE__ */ new Map();
|
|
2434
|
-
for (const V of t.value) {
|
|
2435
|
-
const j = V.category;
|
|
2436
|
-
if (!j) continue;
|
|
2437
|
-
const Z = V.subject;
|
|
2438
|
-
if (n.value.includes(V.subject) || V.showByFeatureFlag && ((w = f(V.showByFeatureFlag)) == null ? void 0 : w.enabled) === !1 && o(V.showByFeatureFlag) === "true")
|
|
2439
|
-
continue;
|
|
2440
|
-
_.has(j) || _.set(j, []);
|
|
2441
|
-
const X = P.get(Z) ?? 0;
|
|
2442
|
-
P.set(Z, X + 1), _.get(j).push({
|
|
2443
|
-
label: a(`permissionSet.permissionLabels.${Z}`, V.label),
|
|
2444
|
-
value: Z,
|
|
2445
|
-
optionKey: `${Z}::${X}`
|
|
2446
|
-
}), O.has(Z) || O.set(Z, V);
|
|
2447
|
-
}
|
|
2448
|
-
return [..._.keys()].sort((V, j) => {
|
|
2449
|
-
const Z = Mn.indexOf(V), X = Mn.indexOf(j);
|
|
2450
|
-
return Z === -1 && X === -1 ? V.localeCompare(j) : Z === -1 ? 1 : X === -1 ? -1 : Z - X;
|
|
2451
|
-
}).map((V) => {
|
|
2452
|
-
const j = _.get(V), Z = a(`permissionSet.categoryLabels.${V}`, V), X = /* @__PURE__ */ new Map();
|
|
2453
|
-
for (const Y of j) {
|
|
2454
|
-
const fe = O.get(Y.value);
|
|
2455
|
-
fe && X.set(Y.value, fe.actions);
|
|
2456
|
-
}
|
|
2457
|
-
const te = j.some((Y) => {
|
|
2458
|
-
const fe = X.get(Y.value);
|
|
2459
|
-
return fe && fe.length > 1;
|
|
2460
|
-
}), z = te ? [
|
|
2461
|
-
...new Set(
|
|
2462
|
-
j.flatMap((Y) => X.get(Y.value) ?? []).filter((Y) => Y !== "manage")
|
|
2463
|
-
)
|
|
2464
|
-
] : [], de = /* @__PURE__ */ new Map();
|
|
2465
|
-
for (const Y of e.value)
|
|
2466
|
-
j.some((fe) => fe.value === Y.subject) && !Y.inverted && de.set(Y.subject, new Set(Y.actions));
|
|
2467
|
-
const ve = te ? e.value.filter(
|
|
2468
|
-
(Y) => j.some((fe) => fe.value === Y.subject) && !Y.inverted && Y.actions.includes("manage")
|
|
2469
|
-
).map((Y) => Y.subject) : e.value.filter((Y) => j.some((fe) => fe.value === Y.subject) && !Y.inverted).map((Y) => Y.subject), he = j.find((Y) => {
|
|
2470
|
-
var fe;
|
|
2471
|
-
return (fe = O.get(Y.value)) == null ? void 0 : fe.isCategoryCover;
|
|
2472
|
-
}), ae = (he == null ? void 0 : he.value) ?? null, le = ae ? de.get(ae) ?? /* @__PURE__ */ new Set() : /* @__PURE__ */ new Set(), Ae = le.has("manage");
|
|
2473
|
-
return {
|
|
2474
|
-
category: V,
|
|
2475
|
-
label: Z,
|
|
2476
|
-
options: j,
|
|
2477
|
-
selectedSubjects: ve,
|
|
2478
|
-
isMultiAction: te,
|
|
2479
|
-
actionColumns: z,
|
|
2480
|
-
permissionActionsMap: X,
|
|
2481
|
-
selectedActionsMap: de,
|
|
2482
|
-
coverSubject: ae,
|
|
2483
|
-
coverSelectedActions: le,
|
|
2484
|
-
coverCoversAll: Ae
|
|
2485
|
-
};
|
|
2486
|
-
});
|
|
2487
|
-
});
|
|
2488
|
-
function i(_, O) {
|
|
2489
|
-
const P = d.value.find((z) => z.category === _), F = (P == null ? void 0 : P.options) ?? [], w = new Set(F.map((z) => z.value)), V = new Set(O), j = /* @__PURE__ */ new Map();
|
|
2490
|
-
for (const z of e.value)
|
|
2491
|
-
w.has(z.subject) && !z.inverted && j.set(z.subject, z.conditions);
|
|
2492
|
-
const Z = P != null && P.coverSubject ? j.get(P.coverSubject) : void 0, X = /* @__PURE__ */ new Set(), te = t.value.flatMap(
|
|
2493
|
-
({ category: z, showByFeatureFlag: de, isCategoryCover: ve, ...he }) => {
|
|
2494
|
-
const ae = he.subject;
|
|
2495
|
-
if (!V.has(ae) || X.has(ae)) return [];
|
|
2496
|
-
X.add(ae);
|
|
2497
|
-
let le;
|
|
2498
|
-
return j.has(ae) ? le = j.get(ae) : P != null && P.coverSubject && ae !== P.coverSubject && (le = Z), [
|
|
2499
|
-
{ ...he, ...le !== void 0 && { conditions: le } }
|
|
2500
|
-
];
|
|
2501
|
-
}
|
|
2502
|
-
);
|
|
2503
|
-
r("update:model-value", [
|
|
2504
|
-
...e.value.filter((z) => !w.has(z.subject)),
|
|
2505
|
-
...te
|
|
2506
|
-
]);
|
|
2507
|
-
}
|
|
2508
|
-
function b(_, O) {
|
|
2509
|
-
return D(_, O) || m(_, O);
|
|
2510
|
-
}
|
|
2511
|
-
function E(_) {
|
|
2512
|
-
return _.options.length > 0 && _.options.every((O) => b(_, O.value));
|
|
2513
|
-
}
|
|
2514
|
-
function N(_) {
|
|
2515
|
-
return _.options.length === 0 || E(_) ? !1 : _.options.some(
|
|
2516
|
-
(O) => b(_, O.value) || k(_, O.value).length > 0
|
|
2517
|
-
);
|
|
2518
|
-
}
|
|
2519
|
-
function T(_) {
|
|
2520
|
-
const O = new Set(_.options.map((F) => F.value)), P = e.value.filter((F) => !O.has(F.subject));
|
|
2521
|
-
if (E(_))
|
|
2522
|
-
r("update:model-value", P);
|
|
2523
|
-
else {
|
|
2524
|
-
const F = /* @__PURE__ */ new Map();
|
|
2525
|
-
for (const Z of e.value)
|
|
2526
|
-
O.has(Z.subject) && !Z.inverted && F.set(Z.subject, Z.conditions);
|
|
2527
|
-
const w = _.coverSubject ? F.get(_.coverSubject) : void 0, V = /* @__PURE__ */ new Set(), j = t.value.flatMap(
|
|
2528
|
-
({ category: Z, showByFeatureFlag: X, isCategoryCover: te, ...z }) => {
|
|
2529
|
-
const de = z.subject;
|
|
2530
|
-
if (!O.has(de) || V.has(de)) return [];
|
|
2531
|
-
V.add(de);
|
|
2532
|
-
let ve;
|
|
2533
|
-
return F.has(de) ? ve = F.get(de) : _.coverSubject && de !== _.coverSubject && (ve = w), [
|
|
2534
|
-
{ ...z, ...ve !== void 0 && { conditions: ve } }
|
|
2535
|
-
];
|
|
2536
|
-
}
|
|
2537
|
-
);
|
|
2538
|
-
r("update:model-value", [...P, ...j]);
|
|
2539
|
-
}
|
|
2540
|
-
}
|
|
2541
|
-
function D(_, O) {
|
|
2542
|
-
const P = _.selectedActionsMap.get(O);
|
|
2543
|
-
return P ? P.has("manage") : !1;
|
|
2544
|
-
}
|
|
2545
|
-
function k(_, O) {
|
|
2546
|
-
const P = _.permissionActionsMap.get(O);
|
|
2547
|
-
return P ? P.filter((w) => w !== "manage").filter(
|
|
2548
|
-
(w) => L(_, O, w) || g(_, O, w)
|
|
2549
|
-
) : [];
|
|
2550
|
-
}
|
|
2551
|
-
function R(_, O) {
|
|
2552
|
-
return m(_, O) ? !1 : !D(_, O) && k(_, O).length > 0;
|
|
2553
|
-
}
|
|
2554
|
-
function M(_, O) {
|
|
2555
|
-
if (!_.coverSubject || O === _.coverSubject) return;
|
|
2556
|
-
const P = e.value.find(
|
|
2557
|
-
(F) => !F.inverted && F.subject === _.coverSubject
|
|
2558
|
-
);
|
|
2559
|
-
return (P == null ? void 0 : P.conditions) || void 0;
|
|
2560
|
-
}
|
|
2561
|
-
function p(_, O, P) {
|
|
2562
|
-
if (P) {
|
|
2563
|
-
const F = t.value.find((z) => z.subject === O);
|
|
2564
|
-
if (!F) return;
|
|
2565
|
-
const {
|
|
2566
|
-
category: w,
|
|
2567
|
-
showByFeatureFlag: V,
|
|
2568
|
-
isCategoryCover: j,
|
|
2569
|
-
...Z
|
|
2570
|
-
} = F, X = M(_, O), te = e.value.filter((z) => z.subject !== O);
|
|
2571
|
-
te.push({
|
|
2572
|
-
...Z,
|
|
2573
|
-
...X !== void 0 && { conditions: X }
|
|
2574
|
-
}), r("update:model-value", te);
|
|
2575
|
-
} else
|
|
2576
|
-
r(
|
|
2577
|
-
"update:model-value",
|
|
2578
|
-
e.value.filter((F) => F.subject !== O)
|
|
2579
|
-
);
|
|
2580
|
-
}
|
|
2581
|
-
function h(_, O) {
|
|
2582
|
-
const P = _.permissionActionsMap.get(O);
|
|
2583
|
-
return P ? P.some((F) => F !== "manage") : !1;
|
|
2584
|
-
}
|
|
2585
|
-
function L(_, O, P) {
|
|
2586
|
-
const F = _.selectedActionsMap.get(O);
|
|
2587
|
-
return F ? F.has(P) : !1;
|
|
2588
|
-
}
|
|
2589
|
-
function m(_, O) {
|
|
2590
|
-
return !_.coverSubject || O === _.coverSubject ? !1 : _.coverCoversAll;
|
|
2591
|
-
}
|
|
2592
|
-
function g(_, O, P) {
|
|
2593
|
-
return !_.coverSubject || O === _.coverSubject ? !1 : _.coverCoversAll ? !0 : _.coverSelectedActions.has(P);
|
|
2594
|
-
}
|
|
2595
|
-
function I(_, O, P) {
|
|
2596
|
-
const F = _.permissionActionsMap.get(O);
|
|
2597
|
-
return F ? F.includes(P) : !1;
|
|
2598
|
-
}
|
|
2599
|
-
function v(_, O, P) {
|
|
2600
|
-
const F = [...e.value], w = F.findIndex((j) => j.subject === _ && !j.inverted);
|
|
2601
|
-
if (P)
|
|
2602
|
-
if (w >= 0) {
|
|
2603
|
-
const j = { ...F[w] }, Z = new Set(j.actions);
|
|
2604
|
-
Z.add(O), j.actions = Array.from(Z), F[w] = j;
|
|
2605
|
-
} else {
|
|
2606
|
-
const j = t.value.find((he) => he.subject === _);
|
|
2607
|
-
if (!j) return;
|
|
2608
|
-
const {
|
|
2609
|
-
category: Z,
|
|
2610
|
-
showByFeatureFlag: X,
|
|
2611
|
-
isCategoryCover: te,
|
|
2612
|
-
...z
|
|
2613
|
-
} = j, de = d.value.find(
|
|
2614
|
-
(he) => he.options.some((ae) => ae.value === _)
|
|
2615
|
-
), ve = de ? M(de, _) : void 0;
|
|
2616
|
-
F.push({
|
|
2617
|
-
...z,
|
|
2618
|
-
actions: [O],
|
|
2619
|
-
...ve !== void 0 && { conditions: ve }
|
|
2620
|
-
});
|
|
2621
|
-
}
|
|
2622
|
-
else if (w >= 0) {
|
|
2623
|
-
const j = { ...F[w] }, Z = j.actions.filter((X) => X !== O);
|
|
2624
|
-
Z.length === 0 ? F.splice(w, 1) : (j.actions = Z, F[w] = j);
|
|
2625
|
-
}
|
|
2626
|
-
const V = t.value.find((j) => j.subject === _);
|
|
2627
|
-
V && kn(F, _, V.actions), r("update:model-value", F);
|
|
2628
|
-
}
|
|
2629
|
-
function A(_, O) {
|
|
2630
|
-
const P = _.options.filter(
|
|
2631
|
-
(F) => I(_, F.value, O)
|
|
2632
|
-
);
|
|
2633
|
-
return P.length === 0 ? !1 : P.every(
|
|
2634
|
-
(F) => L(_, F.value, O) || g(_, F.value, O)
|
|
2635
|
-
);
|
|
2636
|
-
}
|
|
2637
|
-
function S(_, O) {
|
|
2638
|
-
const P = _.options.filter(
|
|
2639
|
-
(w) => I(_, w.value, O)
|
|
2640
|
-
);
|
|
2641
|
-
if (P.length === 0) return !1;
|
|
2642
|
-
const F = P.filter(
|
|
2643
|
-
(w) => L(_, w.value, O) || g(_, w.value, O)
|
|
2644
|
-
).length;
|
|
2645
|
-
return F > 0 && F < P.length;
|
|
2646
|
-
}
|
|
2647
|
-
function H(_, O, P) {
|
|
2648
|
-
const F = [...e.value];
|
|
2649
|
-
for (const w of _.options) {
|
|
2650
|
-
if (!I(_, w.value, O)) continue;
|
|
2651
|
-
const V = w.value, j = F.findIndex(
|
|
2652
|
-
(X) => X.subject === V && !X.inverted
|
|
2653
|
-
);
|
|
2654
|
-
if (P)
|
|
2655
|
-
if (j >= 0) {
|
|
2656
|
-
const X = { ...F[j] }, te = new Set(X.actions);
|
|
2657
|
-
te.add(O), X.actions = Array.from(te), F[j] = X;
|
|
2658
|
-
} else {
|
|
2659
|
-
const X = t.value.find((ae) => ae.subject === V);
|
|
2660
|
-
if (!X) continue;
|
|
2661
|
-
const {
|
|
2662
|
-
category: te,
|
|
2663
|
-
showByFeatureFlag: z,
|
|
2664
|
-
isCategoryCover: de,
|
|
2665
|
-
...ve
|
|
2666
|
-
} = X, he = M(_, V);
|
|
2667
|
-
F.push({
|
|
2668
|
-
...ve,
|
|
2669
|
-
actions: [O],
|
|
2670
|
-
...he !== void 0 && { conditions: he }
|
|
2671
|
-
});
|
|
2672
|
-
}
|
|
2673
|
-
else if (j >= 0) {
|
|
2674
|
-
const X = { ...F[j] }, te = X.actions.filter((z) => z !== O);
|
|
2675
|
-
te.length === 0 ? F.splice(j, 1) : (X.actions = te, F[j] = X);
|
|
2676
|
-
}
|
|
2677
|
-
const Z = t.value.find((X) => X.subject === V);
|
|
2678
|
-
Z && kn(F, V, Z.actions);
|
|
2679
|
-
}
|
|
2680
|
-
r("update:model-value", F);
|
|
2681
|
-
}
|
|
2682
|
-
function x(_) {
|
|
2683
|
-
const O = `permissionSet.actionLabels.${_}`, P = Pa[_] ?? _.charAt(0).toUpperCase() + _.slice(1);
|
|
2684
|
-
return a(O, P);
|
|
2685
|
-
}
|
|
2686
|
-
return {
|
|
2687
|
-
categoryGroups: d,
|
|
2688
|
-
toggleCategory: i,
|
|
2689
|
-
isAllManageChecked: E,
|
|
2690
|
-
isAllManageIndeterminate: N,
|
|
2691
|
-
toggleAllManage: T,
|
|
2692
|
-
isManageChecked: D,
|
|
2693
|
-
isManageIndeterminate: R,
|
|
2694
|
-
toggleManage: p,
|
|
2695
|
-
hasNonManageActions: h,
|
|
2696
|
-
isActionChecked: L,
|
|
2697
|
-
isRowFullyCoveredByCover: m,
|
|
2698
|
-
isActionCoveredByCover: g,
|
|
2699
|
-
permissionDefinesAction: I,
|
|
2700
|
-
toggleAction: v,
|
|
2701
|
-
isAllActionChecked: A,
|
|
2702
|
-
isAllActionIndeterminate: S,
|
|
2703
|
-
toggleAllAction: H,
|
|
2704
|
-
actionLabel: x
|
|
2705
|
-
};
|
|
2706
|
-
}
|
|
2707
|
-
const Ua = { class: "flex flex-col gap-16" }, xa = { class: "mt-16" }, Va = { class: "text-center text-sm font-semibold text-fm-color-typo-primary" }, Ga = ["onClick"], Wa = { class: "flex justify-center" }, Za = { class: "flex items-center min-w-0 gap-8" }, Ya = ["title", "onClick"], Xa = { class: "flex justify-center" }, Ba = /* @__PURE__ */ Re({
|
|
2708
|
-
__name: "BasePermission",
|
|
2709
|
-
props: {
|
|
2710
|
-
modelValue: {
|
|
2711
|
-
type: Array,
|
|
2712
|
-
required: !0
|
|
2713
|
-
},
|
|
2714
|
-
disable: {
|
|
2715
|
-
type: Boolean,
|
|
2716
|
-
default: !1
|
|
2717
|
-
},
|
|
2718
|
-
excludedSubjects: {
|
|
2719
|
-
type: Array,
|
|
2720
|
-
required: !0
|
|
2721
|
-
},
|
|
2722
|
-
additionalPermissions: {
|
|
2723
|
-
type: Array,
|
|
2724
|
-
default: () => []
|
|
2725
|
-
},
|
|
2726
|
-
/** 'leading': the member sheet's layout, collapsed with the count under each category. */
|
|
2727
|
-
layout: {
|
|
2728
|
-
type: String,
|
|
2729
|
-
default: "trailing"
|
|
2730
|
-
}
|
|
2731
|
-
},
|
|
2732
|
-
emits: ["update:model-value"],
|
|
2733
|
-
setup(e, { emit: t }) {
|
|
2734
|
-
const n = e, r = t, { t: a } = Ke(), o = K(() => [...Gn, ...n.additionalPermissions]), {
|
|
2735
|
-
categoryGroups: f,
|
|
2736
|
-
isAllManageChecked: d,
|
|
2737
|
-
isAllManageIndeterminate: i,
|
|
2738
|
-
toggleAllManage: b,
|
|
2739
|
-
isManageChecked: E,
|
|
2740
|
-
isManageIndeterminate: N,
|
|
2741
|
-
toggleManage: T,
|
|
2742
|
-
isActionChecked: D,
|
|
2743
|
-
isRowFullyCoveredByCover: k,
|
|
2744
|
-
isActionCoveredByCover: R,
|
|
2745
|
-
permissionDefinesAction: M,
|
|
2746
|
-
toggleAction: p,
|
|
2747
|
-
isAllActionChecked: h,
|
|
2748
|
-
isAllActionIndeterminate: L,
|
|
2749
|
-
toggleAllAction: m,
|
|
2750
|
-
actionLabel: g
|
|
2751
|
-
} = ja(
|
|
2752
|
-
qt(n, "modelValue"),
|
|
2753
|
-
o,
|
|
2754
|
-
qt(n, "excludedSubjects"),
|
|
2755
|
-
(A, S) => r("update:model-value", S)
|
|
2756
|
-
);
|
|
2757
|
-
function I(A) {
|
|
2758
|
-
const S = A.selectedSubjects.length;
|
|
2759
|
-
return S === 0 && n.layout !== "leading" ? "" : a("team.memberForm.permissions.allowedCount", { count: S });
|
|
2760
|
-
}
|
|
2761
|
-
function v(A, S) {
|
|
2762
|
-
return E(A, S) || k(A, S) ? !0 : A.actionColumns.some(
|
|
2763
|
-
(H) => M(A, S, H) && (D(A, S, H) || R(A, S, H))
|
|
2764
|
-
);
|
|
2765
|
-
}
|
|
2766
|
-
return (A, S) => {
|
|
2767
|
-
const H = De("FmCheckbox");
|
|
2768
|
-
return $(), re("div", Ua, [
|
|
2769
|
-
($(!0), re(Me, null, Ee(B(f), (x) => ($(), Ne(Xt, {
|
|
2770
|
-
key: x.category,
|
|
2771
|
-
subtitle: I(x),
|
|
2772
|
-
layout: e.layout,
|
|
2773
|
-
"initially-collapsed": e.layout === "leading"
|
|
2774
|
-
}, {
|
|
2775
|
-
title: ce(() => [
|
|
2776
|
-
ie("p", {
|
|
2777
|
-
class: Ie(e.layout === "leading" ? "text-[18px] font-semibold leading-[24px] tracking-[-0.27px]" : "fm-typo-en-title-sm-600")
|
|
2778
|
-
}, Oe(x.label), 3)
|
|
2779
|
-
]),
|
|
2780
|
-
default: ce(() => [
|
|
2781
|
-
ie("div", xa, [
|
|
2782
|
-
ie("div", {
|
|
2783
|
-
class: "grid items-center px-12 py-8",
|
|
2784
|
-
style: rt({
|
|
2785
|
-
gridTemplateColumns: `minmax(0, 1fr) repeat(${x.actionColumns.length + 1}, 80px)`
|
|
2786
|
-
})
|
|
2787
|
-
}, [
|
|
2788
|
-
S[0] || (S[0] = ie("div", null, null, -1)),
|
|
2789
|
-
ie("div", Va, Oe(B(a)("team.memberForm.permissions.columnManage")), 1),
|
|
2790
|
-
($(!0), re(Me, null, Ee(x.actionColumns, (_) => ($(), re("div", {
|
|
2791
|
-
key: `header-${_}`,
|
|
2792
|
-
class: "text-center text-sm font-semibold text-fm-color-typo-primary"
|
|
2793
|
-
}, Oe(B(g)(_)), 1))), 128))
|
|
2794
|
-
], 4),
|
|
2795
|
-
ie("div", {
|
|
2796
|
-
class: "grid items-center bg-fm-color-neutral-gray-100 px-12 py-8",
|
|
2797
|
-
style: rt({
|
|
2798
|
-
gridTemplateColumns: `minmax(0, 1fr) repeat(${x.actionColumns.length + 1}, 80px)`
|
|
2799
|
-
})
|
|
2800
|
-
}, [
|
|
2801
|
-
ie("div", {
|
|
2802
|
-
class: "cursor-pointer font-semibold",
|
|
2803
|
-
onClick: (_) => !e.disable && B(b)(x)
|
|
2804
|
-
}, Oe(B(a)("team.labels.all")), 9, Ga),
|
|
2805
|
-
ie("div", Wa, [
|
|
2806
|
-
oe(H, {
|
|
2807
|
-
"model-value": B(d)(x),
|
|
2808
|
-
indeterminate: B(i)(x),
|
|
2809
|
-
value: !0,
|
|
2810
|
-
disabled: e.disable,
|
|
2811
|
-
size: "sm",
|
|
2812
|
-
dense: "",
|
|
2813
|
-
"onUpdate:modelValue": (_) => B(b)(x)
|
|
2814
|
-
}, null, 8, ["model-value", "indeterminate", "disabled", "onUpdate:modelValue"])
|
|
2815
|
-
]),
|
|
2816
|
-
($(!0), re(Me, null, Ee(x.actionColumns, (_) => ($(), re("div", {
|
|
2817
|
-
key: `all-${_}`,
|
|
2818
|
-
class: "flex justify-center"
|
|
2819
|
-
}, [
|
|
2820
|
-
oe(H, {
|
|
2821
|
-
"model-value": B(h)(x, _),
|
|
2822
|
-
indeterminate: B(L)(x, _),
|
|
2823
|
-
value: _,
|
|
2824
|
-
disabled: e.disable,
|
|
2825
|
-
size: "sm",
|
|
2826
|
-
dense: "",
|
|
2827
|
-
"onUpdate:modelValue": (O) => B(m)(x, _, O)
|
|
2828
|
-
}, null, 8, ["model-value", "indeterminate", "value", "disabled", "onUpdate:modelValue"])
|
|
2829
|
-
]))), 128))
|
|
2830
|
-
], 4),
|
|
2831
|
-
S[1] || (S[1] = ie("div", { class: "h-px bg-fm-color-neutral-gray-200" }, null, -1)),
|
|
2832
|
-
($(!0), re(Me, null, Ee(x.options, (_) => ($(), re("div", {
|
|
2833
|
-
key: _.optionKey,
|
|
2834
|
-
class: "grid items-center rounded px-12 py-8 transition-colors hover:bg-fm-color-neutral-gray-100",
|
|
2835
|
-
style: rt({
|
|
2836
|
-
gridTemplateColumns: `minmax(0, 1fr) repeat(${x.actionColumns.length + 1}, 80px)`
|
|
2837
|
-
})
|
|
2838
|
-
}, [
|
|
2839
|
-
ie("div", Za, [
|
|
2840
|
-
ie("span", {
|
|
2841
|
-
class: "block truncate cursor-pointer",
|
|
2842
|
-
title: _.label,
|
|
2843
|
-
onClick: (O) => !e.disable && !B(k)(x, _.value) && B(T)(x, _.value, !B(E)(x, _.value))
|
|
2844
|
-
}, Oe(_.label), 9, Ya),
|
|
2845
|
-
Le(A.$slots, `checkbox-${_.value}-append`, {
|
|
2846
|
-
option: _,
|
|
2847
|
-
isEffectiveSelected: v(x, _.value),
|
|
2848
|
-
isCoveredByCover: B(k)(x, _.value) || x.actionColumns.some((O) => B(R)(x, _.value, O))
|
|
2849
|
-
}),
|
|
2850
|
-
Le(A.$slots, `checkbox-${_.value}-icon`, {
|
|
2851
|
-
option: _,
|
|
2852
|
-
isEffectiveSelected: v(x, _.value),
|
|
2853
|
-
isCoveredByCover: B(k)(x, _.value) || x.actionColumns.some((O) => B(R)(x, _.value, O))
|
|
2854
|
-
})
|
|
2855
|
-
]),
|
|
2856
|
-
ie("div", Xa, [
|
|
2857
|
-
oe(H, {
|
|
2858
|
-
"model-value": B(E)(x, _.value) || B(k)(x, _.value),
|
|
2859
|
-
value: _.value,
|
|
2860
|
-
disabled: e.disable || B(k)(x, _.value),
|
|
2861
|
-
indeterminate: B(N)(x, _.value),
|
|
2862
|
-
size: "sm",
|
|
2863
|
-
"onUpdate:modelValue": (O) => B(T)(x, _.value, O)
|
|
2864
|
-
}, null, 8, ["model-value", "value", "disabled", "indeterminate", "onUpdate:modelValue"])
|
|
2865
|
-
]),
|
|
2866
|
-
($(!0), re(Me, null, Ee(x.actionColumns, (O) => ($(), re("div", {
|
|
2867
|
-
key: `${_.optionKey}-${O}`,
|
|
2868
|
-
class: "flex justify-center"
|
|
2869
|
-
}, [
|
|
2870
|
-
B(M)(x, _.value, O) ? ($(), Ne(H, {
|
|
2871
|
-
key: 0,
|
|
2872
|
-
"model-value": B(D)(x, _.value, O) || B(R)(x, _.value, O),
|
|
2873
|
-
value: O,
|
|
2874
|
-
disabled: e.disable || B(R)(x, _.value, O),
|
|
2875
|
-
size: "sm",
|
|
2876
|
-
"onUpdate:modelValue": (P) => B(p)(_.value, O, P)
|
|
2877
|
-
}, null, 8, ["model-value", "value", "disabled", "onUpdate:modelValue"])) : Ce("", !0)
|
|
2878
|
-
]))), 128))
|
|
2879
|
-
], 4))), 128))
|
|
2880
|
-
])
|
|
2881
|
-
]),
|
|
2882
|
-
_: 2
|
|
2883
|
-
}, 1032, ["subtitle", "layout", "initially-collapsed"]))), 128))
|
|
2884
|
-
]);
|
|
2885
|
-
};
|
|
2886
|
-
}
|
|
2887
|
-
}), Ha = { class: "space-y-16" }, $a = {
|
|
2888
|
-
key: 0,
|
|
2889
|
-
class: "flex fm-typo-en-title-sm-600"
|
|
2890
|
-
}, Ja = {
|
|
2891
|
-
key: 0,
|
|
2892
|
-
class: "q-mr-xs text-red col"
|
|
2893
|
-
}, Ka = { class: "form-input" }, za = /* @__PURE__ */ Re({
|
|
2894
|
-
__name: "AppForm",
|
|
2895
|
-
props: {
|
|
2896
|
-
title: {
|
|
2897
|
-
type: String,
|
|
2898
|
-
default: void 0
|
|
2899
|
-
},
|
|
2900
|
-
required: {
|
|
2901
|
-
type: [Boolean, String],
|
|
2902
|
-
default: !1
|
|
2903
|
-
},
|
|
2904
|
-
inline: {
|
|
2905
|
-
type: Boolean,
|
|
2906
|
-
default: !1
|
|
2907
|
-
}
|
|
2908
|
-
},
|
|
2909
|
-
setup(e) {
|
|
2910
|
-
const t = e;
|
|
2911
|
-
return (n, r) => ($(), re("div", Ha, [
|
|
2912
|
-
Le(n.$slots, "top", {}, () => [
|
|
2913
|
-
t.title ? ($(), re("div", $a, [
|
|
2914
|
-
ie("div", null, [
|
|
2915
|
-
t.required ? ($(), re("span", Ja, "*")) : Ce("", !0),
|
|
2916
|
-
_r(Oe(t.title), 1)
|
|
2917
|
-
]),
|
|
2918
|
-
Le(n.$slots, "title-right")
|
|
2919
|
-
])) : Ce("", !0)
|
|
2920
|
-
]),
|
|
2921
|
-
ie("div", Ka, [
|
|
2922
|
-
Le(n.$slots, "default")
|
|
2923
|
-
])
|
|
2924
|
-
]));
|
|
2925
|
-
}
|
|
2926
|
-
}), Qa = { class: "col flex items-center" }, qa = {
|
|
2927
|
-
key: 1,
|
|
2928
|
-
class: "q-pa-sm form-error-message text-error"
|
|
2929
|
-
}, ir = /* @__PURE__ */ Re({
|
|
2930
|
-
__name: "CheckboxInput",
|
|
2931
|
-
props: {
|
|
2932
|
-
options: {
|
|
2933
|
-
type: Array,
|
|
2934
|
-
required: !0
|
|
2935
|
-
},
|
|
2936
|
-
title: {
|
|
2937
|
-
type: String,
|
|
2938
|
-
required: !0
|
|
2939
|
-
},
|
|
2940
|
-
modelValue: {
|
|
2941
|
-
type: Array,
|
|
2942
|
-
required: !0
|
|
2943
|
-
},
|
|
2944
|
-
showAllToggle: {
|
|
2945
|
-
type: [Boolean, String],
|
|
2946
|
-
default: !0
|
|
2947
|
-
},
|
|
2948
|
-
includeDisabledOptionsWhenSelectAll: {
|
|
2949
|
-
type: Boolean,
|
|
2950
|
-
default: !1
|
|
2951
|
-
},
|
|
2952
|
-
disable: {
|
|
2953
|
-
type: Boolean,
|
|
2954
|
-
default: !1
|
|
2955
|
-
},
|
|
2956
|
-
min: {
|
|
2957
|
-
type: Number,
|
|
2958
|
-
default: 0
|
|
2959
|
-
},
|
|
2960
|
-
max: {
|
|
2961
|
-
type: Number,
|
|
2962
|
-
default: void 0
|
|
2963
|
-
},
|
|
2964
|
-
showIntermediate: {
|
|
2965
|
-
type: Boolean,
|
|
2966
|
-
default: !0
|
|
2967
|
-
},
|
|
2968
|
-
gutter: {
|
|
2969
|
-
type: Number,
|
|
2970
|
-
default: void 0
|
|
2971
|
-
},
|
|
2972
|
-
falsyShowSlot: {
|
|
2973
|
-
type: Boolean,
|
|
2974
|
-
default: !1
|
|
2975
|
-
},
|
|
2976
|
-
bottomSlotIndent: {
|
|
2977
|
-
type: String,
|
|
2978
|
-
default: "36px"
|
|
2979
|
-
},
|
|
2980
|
-
alignCenter: {
|
|
2981
|
-
type: Boolean,
|
|
2982
|
-
default: !0
|
|
2983
|
-
}
|
|
2984
|
-
},
|
|
2985
|
-
emits: ["update:model-value"],
|
|
2986
|
-
setup(e, { emit: t }) {
|
|
2987
|
-
const n = e, r = t, { t: a } = Ke(), o = st(!1), f = pr(), d = K(() => n.modelValue.length < n.min ? `Min selection ${n.min}` : n.max !== void 0 && n.modelValue.length > n.max ? `Max selection ${n.max}` : !0), i = `checkbox-${Dr(6)}`, b = K(() => d.value !== !0), E = K(
|
|
2988
|
-
() => n.modelValue.filter((R) => n.options.some((M) => M.value === R))
|
|
2989
|
-
), N = K(
|
|
2990
|
-
() => typeof n.showAllToggle == "boolean" ? a("team.labels.all") : n.showAllToggle
|
|
2991
|
-
), T = K(() => n.options.length > 0 && n.options.length === E.value.length);
|
|
2992
|
-
function D() {
|
|
2993
|
-
const R = n.modelValue.filter((M) => !E.value.includes(M));
|
|
2994
|
-
if (T.value === !0)
|
|
2995
|
-
r("update:model-value", R);
|
|
2996
|
-
else {
|
|
2997
|
-
const M = n.includeDisabledOptionsWhenSelectAll ? n.options.map((p) => p.value) : n.options.filter((p) => !p.disabled).map((p) => p.value);
|
|
2998
|
-
r("update:model-value", [...R, ...M]);
|
|
2999
|
-
}
|
|
3000
|
-
}
|
|
3001
|
-
function k(R, M) {
|
|
3002
|
-
let p = Yn(n.modelValue);
|
|
3003
|
-
M ? p.every((h) => h !== R) && p.push(R) : p = p.filter((h) => h !== R), r("update:model-value", p);
|
|
3004
|
-
}
|
|
3005
|
-
return (R, M) => {
|
|
3006
|
-
const p = De("FmCheckbox");
|
|
3007
|
-
return $(), Ne(za, {
|
|
3008
|
-
id: i,
|
|
3009
|
-
title: e.title,
|
|
3010
|
-
required: !1
|
|
3011
|
-
}, {
|
|
3012
|
-
top: ce(() => [
|
|
3013
|
-
Le(R.$slots, "top")
|
|
3014
|
-
]),
|
|
3015
|
-
default: ce(() => [
|
|
3016
|
-
n.showAllToggle ? ($(), Ne(p, {
|
|
3017
|
-
key: 0,
|
|
3018
|
-
"model-value": T.value,
|
|
3019
|
-
disabled: e.disable,
|
|
3020
|
-
label: N.value,
|
|
3021
|
-
style: rt(`margin-bottom: ${n.gutter}px`),
|
|
3022
|
-
size: "sm",
|
|
3023
|
-
dense: "",
|
|
3024
|
-
value: N.value,
|
|
3025
|
-
"onUpdate:modelValue": D
|
|
3026
|
-
}, null, 8, ["model-value", "disabled", "label", "style", "value"])) : Ce("", !0),
|
|
3027
|
-
($(!0), re(Me, null, Ee(e.options, (h, L) => ($(), re("div", {
|
|
3028
|
-
key: h.value,
|
|
3029
|
-
style: rt(`margin-bottom: ${L < e.options.length - 1 ? n.gutter : 0}px`),
|
|
3030
|
-
class: Ie(L < e.options.length - 1 ? "q-mb-sm" : "")
|
|
3031
|
-
}, [
|
|
3032
|
-
ie("div", {
|
|
3033
|
-
class: Ie(["row justify-between", e.alignCenter ? "items-center" : "items-start"])
|
|
3034
|
-
}, [
|
|
3035
|
-
ie("div", Qa, [
|
|
3036
|
-
oe(p, {
|
|
3037
|
-
"model-value": e.modelValue.includes(h.value),
|
|
3038
|
-
disabled: e.disable || h.disabled,
|
|
3039
|
-
size: "sm",
|
|
3040
|
-
label: h.label,
|
|
3041
|
-
value: h.label,
|
|
3042
|
-
"onUpdate:modelValue": (m) => k(h.value, m)
|
|
3043
|
-
}, null, 8, ["model-value", "disabled", "label", "value", "onUpdate:modelValue"]),
|
|
3044
|
-
Le(R.$slots, `checkbox-${h.key || h.value}-append`, {
|
|
3045
|
-
option: h,
|
|
3046
|
-
selected: e.modelValue.includes(h.value)
|
|
3047
|
-
})
|
|
3048
|
-
]),
|
|
3049
|
-
B(f)[`checkbox-${h.key || h.value}-end`] && (e.modelValue.includes(h.value) || e.falsyShowSlot) ? ($(), re("div", {
|
|
3050
|
-
key: 0,
|
|
3051
|
-
class: Ie([{ "q-checkbox disabled": e.disable || h.disabled }, "col"])
|
|
3052
|
-
}, [
|
|
3053
|
-
Le(R.$slots, `checkbox-${h.key || h.value}-end`, {
|
|
3054
|
-
option: h,
|
|
3055
|
-
value: e.modelValue.includes(h.value),
|
|
3056
|
-
disable: e.disable || h.disabled
|
|
3057
|
-
})
|
|
3058
|
-
], 2)) : Ce("", !0)
|
|
3059
|
-
], 2),
|
|
3060
|
-
B(f)[`checkbox-${h.key || h.value}-bottom`] && (e.modelValue.includes(h.value) || e.falsyShowSlot) ? ($(), re("div", {
|
|
3061
|
-
key: 0,
|
|
3062
|
-
class: Ie(["q-mt-sm", { "q-checkbox disabled": e.disable || h.disabled }]),
|
|
3063
|
-
style: rt(`margin-left: ${e.bottomSlotIndent}`)
|
|
3064
|
-
}, [
|
|
3065
|
-
Le(R.$slots, `checkbox-${h.key || h.value}-bottom`, {
|
|
3066
|
-
option: h,
|
|
3067
|
-
disable: e.disable || h.disabled,
|
|
3068
|
-
value: e.modelValue.includes(h.value)
|
|
3069
|
-
})
|
|
3070
|
-
], 6)) : Ce("", !0)
|
|
3071
|
-
], 6))), 128)),
|
|
3072
|
-
o.value && b.value ? ($(), re("div", qa, Oe(d.value), 1)) : Ce("", !0)
|
|
3073
|
-
]),
|
|
3074
|
-
_: 3
|
|
3075
|
-
}, 8, ["title"]);
|
|
3076
|
-
};
|
|
3077
|
-
}
|
|
3078
|
-
}), ht = "includedFuture", Dn = /* @__PURE__ */ Re({
|
|
3079
|
-
__name: "ConditionPermission",
|
|
3080
|
-
props: {
|
|
3081
|
-
modelValue: {
|
|
3082
|
-
type: Array,
|
|
3083
|
-
default: null
|
|
3084
|
-
},
|
|
3085
|
-
options: {
|
|
3086
|
-
type: Array,
|
|
3087
|
-
required: !0
|
|
3088
|
-
},
|
|
3089
|
-
disable: {
|
|
3090
|
-
type: Boolean,
|
|
3091
|
-
default: !1
|
|
3092
|
-
},
|
|
3093
|
-
context: {
|
|
3094
|
-
type: String,
|
|
3095
|
-
required: !0
|
|
3096
|
-
},
|
|
3097
|
-
/** 'leading': the member sheet's layout, with the chosen names under the title. */
|
|
3098
|
-
layout: {
|
|
3099
|
-
type: String,
|
|
3100
|
-
default: "trailing"
|
|
3101
|
-
}
|
|
3102
|
-
},
|
|
3103
|
-
emits: ["update:model-value"],
|
|
3104
|
-
setup(e, { emit: t }) {
|
|
3105
|
-
const n = e, r = t, { t: a } = Ke(), o = K(() => [
|
|
3106
|
-
{
|
|
3107
|
-
label: a("team.memberForm.permissions.includedFuture", { context: n.context }),
|
|
3108
|
-
value: ht,
|
|
3109
|
-
// Can only be selected if all other options are selected
|
|
3110
|
-
disabled: !!n.modelValue && n.options.length > n.modelValue.length
|
|
3111
|
-
},
|
|
3112
|
-
...n.options.filter(
|
|
3113
|
-
(E) => E.label.toLocaleLowerCase().includes(b.value.toLocaleLowerCase())
|
|
3114
|
-
)
|
|
3115
|
-
]), f = K(() => n.modelValue ? n.modelValue : [ht, ...n.options.map((E) => E.value)]), d = K(() => {
|
|
3116
|
-
if (n.layout === "leading") {
|
|
3117
|
-
const N = n.modelValue ? n.options.filter((T) => n.modelValue.includes(T.value)).map((T) => T.label) : null;
|
|
3118
|
-
return Xn(N, {
|
|
3119
|
-
all: a("team.labels.all"),
|
|
3120
|
-
none: a("team.labels.none"),
|
|
3121
|
-
more: (T) => a("team.labels.more", { count: T })
|
|
3122
|
-
});
|
|
3123
|
-
}
|
|
3124
|
-
const E = f.value.filter((N) => N !== ht).length;
|
|
3125
|
-
return E === 0 ? "" : a("team.memberForm.permissions.allowedCount", { count: E });
|
|
3126
|
-
});
|
|
3127
|
-
function i(E) {
|
|
3128
|
-
const N = E.length === o.value.length;
|
|
3129
|
-
r("update:model-value", N ? null : E.filter((T) => T !== ht));
|
|
3130
|
-
}
|
|
3131
|
-
const b = st("");
|
|
3132
|
-
return (E, N) => {
|
|
3133
|
-
const T = De("fm-search");
|
|
3134
|
-
return $(), Ne(Xt, {
|
|
3135
|
-
subtitle: d.value,
|
|
3136
|
-
layout: e.layout,
|
|
3137
|
-
"initially-collapsed": e.layout === "leading"
|
|
3138
|
-
}, {
|
|
3139
|
-
title: ce(() => [
|
|
3140
|
-
ie("p", {
|
|
3141
|
-
class: Ie(
|
|
3142
|
-
e.layout === "leading" ? "text-[18px] font-semibold leading-[24px] tracking-[-0.27px]" : "fm-typo-en-title-sm-600"
|
|
3143
|
-
)
|
|
3144
|
-
}, Oe(B(a)("team.memberForm.permissions.manageable", { context: e.context })), 3)
|
|
3145
|
-
]),
|
|
3146
|
-
default: ce(() => [
|
|
3147
|
-
e.options.length > 1 ? ($(), Ne(T, {
|
|
3148
|
-
key: 0,
|
|
3149
|
-
modelValue: b.value,
|
|
3150
|
-
"onUpdate:modelValue": N[0] || (N[0] = (D) => b.value = D),
|
|
3151
|
-
class: "mt-16",
|
|
3152
|
-
placeholder: B(a)("team.memberForm.permissions.search", { context: e.context })
|
|
3153
|
-
}, null, 8, ["modelValue", "placeholder"])) : Ce("", !0),
|
|
3154
|
-
oe(ir, {
|
|
3155
|
-
"model-value": f.value,
|
|
3156
|
-
options: o.value,
|
|
3157
|
-
"show-intermediate": !1,
|
|
3158
|
-
"show-all-toggle": !0,
|
|
3159
|
-
disable: e.disable,
|
|
3160
|
-
"include-disabled-options-when-select-all": !0,
|
|
3161
|
-
title: "",
|
|
3162
|
-
class: "mt-16",
|
|
3163
|
-
"onUpdate:modelValue": i
|
|
3164
|
-
}, tt({ _: 2 }, [
|
|
3165
|
-
Ee(o.value, (D) => ({
|
|
3166
|
-
name: `checkbox-${D.value}-append`,
|
|
3167
|
-
fn: ce(({ option: k }) => [
|
|
3168
|
-
Le(E.$slots, `checkbox-${D.value}-append`, { option: k })
|
|
3169
|
-
])
|
|
3170
|
-
}))
|
|
3171
|
-
]), 1032, ["model-value", "options", "disable"])
|
|
3172
|
-
]),
|
|
3173
|
-
_: 3
|
|
3174
|
-
}, 8, ["subtitle", "layout", "initially-collapsed"]);
|
|
3175
|
-
};
|
|
3176
|
-
}
|
|
3177
|
-
}), bt = "includedNewRole", eo = /* @__PURE__ */ Re({
|
|
3178
|
-
__name: "PosRolePermission",
|
|
3179
|
-
props: {
|
|
3180
|
-
modelValue: {
|
|
3181
|
-
type: Array,
|
|
3182
|
-
default: null
|
|
3183
|
-
},
|
|
3184
|
-
roles: {
|
|
3185
|
-
type: Array,
|
|
3186
|
-
required: !0
|
|
3187
|
-
},
|
|
3188
|
-
restaurantIds: {
|
|
3189
|
-
type: Array,
|
|
3190
|
-
default: null
|
|
3191
|
-
},
|
|
3192
|
-
disable: {
|
|
3193
|
-
type: Boolean,
|
|
3194
|
-
default: !1
|
|
3195
|
-
},
|
|
3196
|
-
/** 'leading': the member sheet's layout, with the chosen roles under the title. */
|
|
3197
|
-
layout: {
|
|
3198
|
-
type: String,
|
|
3199
|
-
default: "trailing"
|
|
3200
|
-
}
|
|
3201
|
-
},
|
|
3202
|
-
emits: ["update:model-value"],
|
|
3203
|
-
setup(e, { emit: t }) {
|
|
3204
|
-
const n = e, r = t, { t: a } = Ke(), o = K(() => {
|
|
3205
|
-
const b = n.restaurantIds;
|
|
3206
|
-
return [
|
|
3207
|
-
{
|
|
3208
|
-
label: a("team.memberForm.permissions.includedNewRole"),
|
|
3209
|
-
value: bt,
|
|
3210
|
-
disabled: !!n.modelValue && n.roles.length > n.modelValue.length
|
|
3211
|
-
},
|
|
3212
|
-
...n.roles.map((E) => ({
|
|
3213
|
-
label: E.name,
|
|
3214
|
-
value: E._id,
|
|
3215
|
-
disabled: !!b && E.restaurants.every(({ id: N }) => !b.includes(N))
|
|
3216
|
-
}))
|
|
3217
|
-
];
|
|
3218
|
-
}), f = K(() => n.modelValue ? n.modelValue : [bt, ...n.roles.map((b) => b._id)]), d = K(() => {
|
|
3219
|
-
if (n.layout === "leading") {
|
|
3220
|
-
const E = n.modelValue ? n.roles.filter((N) => n.modelValue.includes(N._id)).map((N) => N.name) : null;
|
|
3221
|
-
return Xn(E, {
|
|
3222
|
-
all: a("team.labels.all"),
|
|
3223
|
-
none: a("team.labels.none"),
|
|
3224
|
-
more: (N) => a("team.labels.more", { count: N })
|
|
3225
|
-
});
|
|
3226
|
-
}
|
|
3227
|
-
const b = f.value.filter((E) => E !== bt).length;
|
|
3228
|
-
return b === 0 ? "" : a("team.memberForm.permissions.allowedCount", { count: b });
|
|
3229
|
-
});
|
|
3230
|
-
function i(b) {
|
|
3231
|
-
const E = b.length === o.value.length;
|
|
3232
|
-
r("update:model-value", E ? null : b.filter((N) => N !== bt));
|
|
3233
|
-
}
|
|
3234
|
-
return (b, E) => ($(), Ne(Xt, {
|
|
3235
|
-
subtitle: d.value,
|
|
3236
|
-
layout: e.layout,
|
|
3237
|
-
"initially-collapsed": e.layout === "leading"
|
|
3238
|
-
}, {
|
|
3239
|
-
title: ce(() => [
|
|
3240
|
-
ie("p", {
|
|
3241
|
-
class: Ie(
|
|
3242
|
-
e.layout === "leading" ? "text-[18px] font-semibold leading-[24px] tracking-[-0.27px]" : "fm-typo-en-title-sm-600"
|
|
3243
|
-
)
|
|
3244
|
-
}, Oe(B(a)("team.memberForm.permissions.roles")), 3)
|
|
3245
|
-
]),
|
|
3246
|
-
default: ce(() => [
|
|
3247
|
-
oe(ir, {
|
|
3248
|
-
"model-value": f.value,
|
|
3249
|
-
options: o.value,
|
|
3250
|
-
"show-intermediate": !1,
|
|
3251
|
-
"show-all-toggle": !1,
|
|
3252
|
-
disable: e.disable,
|
|
3253
|
-
title: "",
|
|
3254
|
-
class: "mt-16",
|
|
3255
|
-
"onUpdate:modelValue": i
|
|
3256
|
-
}, tt({ _: 2 }, [
|
|
3257
|
-
Ee(o.value, (N) => ({
|
|
3258
|
-
name: `checkbox-${N.value}-append`,
|
|
3259
|
-
fn: ce(({ option: T }) => [
|
|
3260
|
-
Le(b.$slots, `checkbox-${N.value}-append`, { option: T })
|
|
3261
|
-
])
|
|
3262
|
-
}))
|
|
3263
|
-
]), 1032, ["model-value", "options", "disable"])
|
|
3264
|
-
]),
|
|
3265
|
-
_: 3
|
|
3266
|
-
}, 8, ["subtitle", "layout", "initially-collapsed"]));
|
|
3267
|
-
}
|
|
3268
|
-
}), to = {
|
|
3269
|
-
key: 0,
|
|
3270
|
-
class: "flex flex-col gap-8"
|
|
3271
|
-
}, no = {
|
|
3272
|
-
key: 0,
|
|
3273
|
-
class: "ml-32",
|
|
3274
|
-
style: { "font-size": "12px", "line-height": "16px", color: "#8a8f98", "font-weight": "400" }
|
|
3275
|
-
}, ro = {
|
|
3276
|
-
key: 0,
|
|
3277
|
-
class: "ml-32"
|
|
3278
|
-
}, wn = /* @__PURE__ */ Re({
|
|
3279
|
-
__name: "PortalConditionForm",
|
|
3280
|
-
props: {
|
|
3281
|
-
entry: {},
|
|
3282
|
-
builders: {},
|
|
3283
|
-
subject: {},
|
|
3284
|
-
timeZone: {},
|
|
3285
|
-
coverOverride: {},
|
|
3286
|
-
inheritModeFor: {},
|
|
3287
|
-
formValueFor: {},
|
|
3288
|
-
hasChanges: { type: Boolean },
|
|
3289
|
-
disable: { type: Boolean, default: !1 },
|
|
3290
|
-
fullWidth: { type: Boolean, default: !1 },
|
|
3291
|
-
title: { default: "" }
|
|
3292
|
-
},
|
|
3293
|
-
emits: ["update-inherit-mode", "update-form", "apply"],
|
|
3294
|
-
setup(e, { emit: t }) {
|
|
3295
|
-
const n = t, { t: r } = Ke();
|
|
3296
|
-
return (a, o) => {
|
|
3297
|
-
const f = De("FmRadio"), d = De("FmRadioGroup");
|
|
3298
|
-
return $(), Ne(Lr, {
|
|
3299
|
-
title: e.title,
|
|
3300
|
-
builders: e.builders,
|
|
3301
|
-
"form-value-for": e.formValueFor,
|
|
3302
|
-
"has-changes": e.hasChanges,
|
|
3303
|
-
disable: e.disable,
|
|
3304
|
-
"full-width": e.fullWidth,
|
|
3305
|
-
onUpdateForm: o[0] || (o[0] = (i) => n("update-form", i)),
|
|
3306
|
-
onApply: o[1] || (o[1] = (i) => n("apply"))
|
|
3307
|
-
}, {
|
|
3308
|
-
section: ce(({ builder: i }) => [
|
|
3309
|
-
e.coverOverride.shouldShowInheritToggle(e.entry, i) ? ($(), re("div", to, [
|
|
3310
|
-
oe(d, {
|
|
3311
|
-
"model-value": e.inheritModeFor(i),
|
|
3312
|
-
disabled: e.disable,
|
|
3313
|
-
"onUpdate:modelValue": (b) => n("update-inherit-mode", { builder: i, mode: b })
|
|
3314
|
-
}, {
|
|
3315
|
-
default: ce(() => [
|
|
3316
|
-
ie("div", null, [
|
|
3317
|
-
oe(f, {
|
|
3318
|
-
value: "inherit",
|
|
3319
|
-
label: B(r)("team.memberForm.permissions.conditionCover.inherit", {
|
|
3320
|
-
cover: e.coverOverride.coverLabel(e.subject)
|
|
3321
|
-
})
|
|
3322
|
-
}, null, 8, ["label"]),
|
|
3323
|
-
e.coverOverride.inheritedSummary(e.entry, i, e.timeZone) ? ($(), re("p", no, " (" + Oe(B(r)(
|
|
3324
|
-
e.coverOverride.inheritedSummary(e.entry, i, e.timeZone).labelKey,
|
|
3325
|
-
e.coverOverride.inheritedSummary(e.entry, i, e.timeZone).params ?? {}
|
|
3326
|
-
)) + ") ", 1)) : Ce("", !0)
|
|
3327
|
-
]),
|
|
3328
|
-
oe(f, {
|
|
3329
|
-
value: "custom",
|
|
3330
|
-
label: B(r)("team.memberForm.permissions.conditionCover.custom")
|
|
3331
|
-
}, null, 8, ["label"])
|
|
3332
|
-
]),
|
|
3333
|
-
_: 2
|
|
3334
|
-
}, 1032, ["model-value", "disabled", "onUpdate:modelValue"]),
|
|
3335
|
-
e.inheritModeFor(i) === "custom" ? ($(), re("div", ro, [
|
|
3336
|
-
oe(nn, {
|
|
3337
|
-
builder: i,
|
|
3338
|
-
"model-value": e.formValueFor(i),
|
|
3339
|
-
disable: e.disable,
|
|
3340
|
-
"onUpdate:modelValue": (b) => n("update-form", { builder: i, form: b })
|
|
3341
|
-
}, null, 8, ["builder", "model-value", "disable", "onUpdate:modelValue"])
|
|
3342
|
-
])) : Ce("", !0)
|
|
3343
|
-
])) : ($(), Ne(nn, {
|
|
3344
|
-
key: 1,
|
|
3345
|
-
builder: i,
|
|
3346
|
-
"model-value": e.formValueFor(i),
|
|
3347
|
-
disable: e.disable,
|
|
3348
|
-
"onUpdate:modelValue": (b) => n("update-form", { builder: i, form: b })
|
|
3349
|
-
}, null, 8, ["builder", "model-value", "disable", "onUpdate:modelValue"]))
|
|
3350
|
-
]),
|
|
3351
|
-
_: 1
|
|
3352
|
-
}, 8, ["title", "builders", "form-value-for", "has-changes", "disable", "full-width"]);
|
|
3353
|
-
};
|
|
3354
|
-
}
|
|
3355
|
-
}), so = {
|
|
3356
|
-
async readWarehouses() {
|
|
3357
|
-
return kr(await Mr().get("/warehouses"));
|
|
3358
|
-
}
|
|
3359
|
-
};
|
|
3360
|
-
function Fn(e, t) {
|
|
3361
|
-
return Wn(e, Zn).some(
|
|
3362
|
-
(n) => n.subject === t && !n.inverted && n.actions.includes("manage")
|
|
3363
|
-
);
|
|
3364
|
-
}
|
|
3365
|
-
function Pn(e, t) {
|
|
3366
|
-
return e.some((n) => n.subject === t && n.inverted) ? e : [...e, { subject: t, actions: ["manage"], inverted: !0 }];
|
|
3367
|
-
}
|
|
3368
|
-
function jn(e, t, n) {
|
|
3369
|
-
const { category: r, showByFeatureFlag: a, isCategoryCover: o, ...f } = e;
|
|
3370
|
-
return {
|
|
3371
|
-
...f,
|
|
3372
|
-
actions: t,
|
|
3373
|
-
...n !== void 0 && { conditions: n }
|
|
3374
|
-
};
|
|
3375
|
-
}
|
|
3376
|
-
function ao(e, t, n, r) {
|
|
3377
|
-
const a = new Set(
|
|
3378
|
-
e.filter((i) => !i.inverted).map((i) => i.subject)
|
|
3379
|
-
), o = new Set(
|
|
3380
|
-
t.filter((i) => !i.inverted).map((i) => i.subject)
|
|
3381
|
-
), f = new Set(
|
|
3382
|
-
n.filter((i) => !i.inverted).map((i) => i.subject)
|
|
3383
|
-
);
|
|
3384
|
-
let d = [...n];
|
|
3385
|
-
for (const i of a)
|
|
3386
|
-
o.has(i) || (f.has(i) && (d = d.filter((E) => E.subject !== i)), (!f.has(i) || Fn(d, i)) && (d = Pn(d, i)));
|
|
3387
|
-
for (const i of o)
|
|
3388
|
-
if (!a.has(i)) {
|
|
3389
|
-
const b = d.some((E) => E.subject === i && E.inverted);
|
|
3390
|
-
if (d = d.filter((E) => !(E.subject === i && E.inverted)), !b && !f.has(i)) {
|
|
3391
|
-
const E = t.find(
|
|
3392
|
-
(T) => T.subject === i && !T.inverted
|
|
3393
|
-
), N = r(i);
|
|
3394
|
-
N && E && d.push(jn(N, E.actions, E.conditions));
|
|
3395
|
-
}
|
|
3396
|
-
}
|
|
3397
|
-
for (const i of o) {
|
|
3398
|
-
if (!a.has(i)) continue;
|
|
3399
|
-
const b = e.find((k) => k.subject === i && !k.inverted), E = t.find((k) => k.subject === i && !k.inverted);
|
|
3400
|
-
if (!b || !E) continue;
|
|
3401
|
-
const N = new Set(b.actions), T = new Set(E.actions);
|
|
3402
|
-
if (N.size === T.size && [...N].every((k) => T.has(k)))
|
|
3403
|
-
continue;
|
|
3404
|
-
const D = d.findIndex((k) => k.subject === i && !k.inverted);
|
|
3405
|
-
if (D >= 0)
|
|
3406
|
-
d[D] = {
|
|
3407
|
-
...d[D],
|
|
3408
|
-
actions: Array.from(T)
|
|
3409
|
-
};
|
|
3410
|
-
else {
|
|
3411
|
-
const k = r(i);
|
|
3412
|
-
k && d.push(jn(k, Array.from(T)));
|
|
3413
|
-
}
|
|
3414
|
-
N.has("manage") && !T.has("manage") && Fn(d, i) && (d = Pn(d, i)), !N.has("manage") && T.has("manage") && (d = d.filter((k) => !(k.subject === i && k.inverted)));
|
|
3415
|
-
}
|
|
3416
|
-
return d;
|
|
3417
|
-
}
|
|
3418
|
-
const oo = {
|
|
3419
|
-
MY: "Asia/Kuala_Lumpur",
|
|
3420
|
-
SG: "Asia/Singapore",
|
|
3421
|
-
TH: "Asia/Bangkok",
|
|
3422
|
-
ID: "Asia/Jakarta",
|
|
3423
|
-
MO: "Asia/Macau",
|
|
3424
|
-
BN: "Asia/Brunei",
|
|
3425
|
-
PK: "Asia/Karachi",
|
|
3426
|
-
MV: "Indian/Maldives",
|
|
3427
|
-
VN: "Asia/Ho_Chi_Minh",
|
|
3428
|
-
JP: "Asia/Tokyo",
|
|
3429
|
-
AU: "Australia/Sydney",
|
|
3430
|
-
AE: "Asia/Dubai",
|
|
3431
|
-
UK: "Europe/London"
|
|
3432
|
-
};
|
|
3433
|
-
function lo(e) {
|
|
3434
|
-
const t = (e || "").toUpperCase();
|
|
3435
|
-
return oo[t] ?? Intl.DateTimeFormat().resolvedOptions().timeZone;
|
|
3436
|
-
}
|
|
3437
|
-
function io(e, t) {
|
|
3438
|
-
return e != null && e.timezone ? e.timezone : e != null && e.timeZone ? e.timeZone : lo((e == null ? void 0 : e.country) ?? t);
|
|
3439
|
-
}
|
|
3440
|
-
function gt(e, t) {
|
|
3441
|
-
return `${e}::${t.builderKey}`;
|
|
3442
|
-
}
|
|
3443
|
-
function Xe(e) {
|
|
3444
|
-
try {
|
|
3445
|
-
return e.conditions ? JSON.parse(e.conditions) : void 0;
|
|
3446
|
-
} catch {
|
|
3447
|
-
return;
|
|
3448
|
-
}
|
|
3449
|
-
}
|
|
3450
|
-
function co(e, t) {
|
|
3451
|
-
return e.find((n) => !n.inverted && n.subject === t);
|
|
3452
|
-
}
|
|
3453
|
-
function kt(e, t) {
|
|
3454
|
-
const n = new Set(e.actions);
|
|
3455
|
-
return n.has(Ye.Action.manage) ? !0 : t.actions.every((r) => n.has(r));
|
|
3456
|
-
}
|
|
3457
|
-
function Zt(e, t) {
|
|
3458
|
-
const n = Xe(e);
|
|
3459
|
-
return Dt(n, [{ builder: t, formValue: t.fromCondition(void 0) }]);
|
|
3460
|
-
}
|
|
3461
|
-
function Un(e, t, n) {
|
|
3462
|
-
return {
|
|
3463
|
-
...Zt(e, n),
|
|
3464
|
-
...nt(Xe(t), n)
|
|
3465
|
-
};
|
|
3466
|
-
}
|
|
3467
|
-
function uo(e, t, n) {
|
|
3468
|
-
const r = st(/* @__PURE__ */ new Set());
|
|
3469
|
-
function a(m) {
|
|
3470
|
-
return yr(m, t.value);
|
|
3471
|
-
}
|
|
3472
|
-
function o(m) {
|
|
3473
|
-
return t.value.find((g) => g.subject === m);
|
|
3474
|
-
}
|
|
3475
|
-
function f(m) {
|
|
3476
|
-
var I;
|
|
3477
|
-
const g = a(m);
|
|
3478
|
-
return g ? (I = o(g)) == null ? void 0 : I.label : void 0;
|
|
3479
|
-
}
|
|
3480
|
-
function d(m) {
|
|
3481
|
-
return co(e.value, m);
|
|
3482
|
-
}
|
|
3483
|
-
function i(m, g) {
|
|
3484
|
-
return nt(Xe(m), g);
|
|
3485
|
-
}
|
|
3486
|
-
function b(m, g) {
|
|
3487
|
-
var A;
|
|
3488
|
-
if (!(((A = g.appliesToActions) == null ? void 0 : A.call(g, m.actions)) ?? !0)) return !1;
|
|
3489
|
-
const I = a(m.subject);
|
|
3490
|
-
if (!I) return !1;
|
|
3491
|
-
const v = d(I);
|
|
3492
|
-
return v ? Object.keys(i(v, g)).length > 0 : !1;
|
|
3493
|
-
}
|
|
3494
|
-
function E(m, g) {
|
|
3495
|
-
if (!b(m, g) || r.value.has(gt(m.subject, g))) return "custom";
|
|
3496
|
-
if (m.index === null) return "inherit";
|
|
3497
|
-
const I = e.value[m.index], v = a(m.subject), A = v ? d(v) : void 0;
|
|
3498
|
-
if (I && A) {
|
|
3499
|
-
const S = nt(Xe(I), g), H = i(A, g);
|
|
3500
|
-
if (JSON.stringify(S) === JSON.stringify(H)) return "inherit";
|
|
3501
|
-
}
|
|
3502
|
-
return "custom";
|
|
3503
|
-
}
|
|
3504
|
-
function N(m, g, I) {
|
|
3505
|
-
if (!g.summarizeForm) return;
|
|
3506
|
-
const v = a(m.subject);
|
|
3507
|
-
if (!v) return;
|
|
3508
|
-
const A = d(v);
|
|
3509
|
-
if (!A) return;
|
|
3510
|
-
const S = g.fromCondition(i(A, g));
|
|
3511
|
-
return g.summarizeForm(S, { timeZone: I });
|
|
3512
|
-
}
|
|
3513
|
-
function T(m, g) {
|
|
3514
|
-
if (m.index === null) return;
|
|
3515
|
-
const I = [...e.value], v = { ...I[m.index] }, A = Zt(v, g), S = Object.keys(A).length === 0, H = a(m.subject), x = H ? d(H) : void 0, _ = x ? kt(x, v) : !1;
|
|
3516
|
-
if (S && _)
|
|
3517
|
-
I.splice(m.index, 1);
|
|
3518
|
-
else if (x) {
|
|
3519
|
-
const O = Un(v, x, g);
|
|
3520
|
-
Object.keys(O).length === 0 ? delete v.conditions : v.conditions = JSON.stringify(O), I[m.index] = v;
|
|
3521
|
-
} else
|
|
3522
|
-
S ? delete v.conditions : v.conditions = JSON.stringify(A), I[m.index] = v;
|
|
3523
|
-
n(I);
|
|
3524
|
-
}
|
|
3525
|
-
function D(m, g, I) {
|
|
3526
|
-
const v = gt(m.subject, g);
|
|
3527
|
-
if (I === "inherit") {
|
|
3528
|
-
const S = new Set(r.value);
|
|
3529
|
-
S.delete(v), r.value = S, T(m, g);
|
|
3530
|
-
return;
|
|
3531
|
-
}
|
|
3532
|
-
const A = new Set(r.value);
|
|
3533
|
-
A.add(v), r.value = A, m.index === null && h(m, g, g.fromCondition(void 0), {
|
|
3534
|
-
forceCreateRule: !0
|
|
3535
|
-
});
|
|
3536
|
-
}
|
|
3537
|
-
function k(m) {
|
|
3538
|
-
const g = a(m);
|
|
3539
|
-
if (!g) return [];
|
|
3540
|
-
const I = d(g);
|
|
3541
|
-
return (I == null ? void 0 : I.actions) ?? [];
|
|
3542
|
-
}
|
|
3543
|
-
function R(m, g) {
|
|
3544
|
-
return e.value.filter((I) => {
|
|
3545
|
-
if (I.inverted) return !1;
|
|
3546
|
-
const v = I.subject;
|
|
3547
|
-
return v === m || a(v) !== m ? !1 : r.value.has(gt(v, g)) ? !0 : Object.keys(nt(Xe(I), g)).length > 0;
|
|
3548
|
-
});
|
|
3549
|
-
}
|
|
3550
|
-
function M(m, g) {
|
|
3551
|
-
const I = `::${g.builderKey}`, v = new Set(r.value);
|
|
3552
|
-
for (const A of v) {
|
|
3553
|
-
if (!A.endsWith(I)) continue;
|
|
3554
|
-
const S = A.slice(0, -I.length);
|
|
3555
|
-
a(S) === m && v.delete(A);
|
|
3556
|
-
}
|
|
3557
|
-
r.value = v;
|
|
3558
|
-
}
|
|
3559
|
-
function p(m, g, I) {
|
|
3560
|
-
const v = g.subject;
|
|
3561
|
-
return m.reduce((A, S) => {
|
|
3562
|
-
if (S.inverted)
|
|
3563
|
-
return A.push(S), A;
|
|
3564
|
-
const H = S.subject;
|
|
3565
|
-
if (H === v || a(H) !== v)
|
|
3566
|
-
return A.push(S), A;
|
|
3567
|
-
if (kt(g, S) && Object.keys(Zt(S, I)).length === 0)
|
|
3568
|
-
return A;
|
|
3569
|
-
const _ = Un(S, g, I);
|
|
3570
|
-
if (Object.keys(_).length === 0) {
|
|
3571
|
-
const { conditions: O, ...P } = S;
|
|
3572
|
-
A.push(P);
|
|
3573
|
-
} else
|
|
3574
|
-
A.push({ ...S, conditions: JSON.stringify(_) });
|
|
3575
|
-
return A;
|
|
3576
|
-
}, []);
|
|
3577
|
-
}
|
|
3578
|
-
function h(m, g, I, v = {}) {
|
|
3579
|
-
var F;
|
|
3580
|
-
const A = [...e.value];
|
|
3581
|
-
let S = m.index;
|
|
3582
|
-
const H = g.toCondition(I), x = Object.keys(H).length > 0;
|
|
3583
|
-
if (S === null && !x && !v.forceCreateRule) return;
|
|
3584
|
-
if (S === null) {
|
|
3585
|
-
const w = A.findIndex((V) => !V.inverted && V.subject === m.subject);
|
|
3586
|
-
if (w !== -1)
|
|
3587
|
-
S = w;
|
|
3588
|
-
else {
|
|
3589
|
-
const V = t.value.find((z) => z.subject === m.subject);
|
|
3590
|
-
if (!V) return;
|
|
3591
|
-
const {
|
|
3592
|
-
category: j,
|
|
3593
|
-
showByFeatureFlag: Z,
|
|
3594
|
-
isCategoryCover: X,
|
|
3595
|
-
...te
|
|
3596
|
-
} = V;
|
|
3597
|
-
A.push({
|
|
3598
|
-
...te,
|
|
3599
|
-
actions: m.actions.length > 0 ? m.actions : te.actions
|
|
3600
|
-
}), S = A.length - 1;
|
|
3601
|
-
}
|
|
3602
|
-
}
|
|
3603
|
-
const _ = { ...A[S] };
|
|
3604
|
-
_.actions = [
|
|
3605
|
-
.../* @__PURE__ */ new Set([..._.actions, ...m.actions])
|
|
3606
|
-
];
|
|
3607
|
-
const O = Xe(_), P = Dt(O, [{ builder: g, formValue: I }]);
|
|
3608
|
-
if (Object.keys(P).length === 0 ? delete _.conditions : _.conditions = JSON.stringify(P), A[S] = _, tn(m.subject, t.value)) {
|
|
3609
|
-
const w = R(m.subject, g), V = () => {
|
|
3610
|
-
var Z;
|
|
3611
|
-
M(m.subject, g), n(p(A, _, g)), (Z = v.afterCommit) == null || Z.call(v);
|
|
3612
|
-
}, j = () => {
|
|
3613
|
-
var Z;
|
|
3614
|
-
n(A), (Z = v.afterCommit) == null || Z.call(v);
|
|
3615
|
-
};
|
|
3616
|
-
if (w.length === 0) {
|
|
3617
|
-
V();
|
|
3618
|
-
return;
|
|
3619
|
-
}
|
|
3620
|
-
v.onOverridesConflict ? v.onOverridesConflict({ override: V, keep: j }) : j();
|
|
3621
|
-
return;
|
|
3622
|
-
}
|
|
3623
|
-
n(A), (F = v.afterCommit) == null || F.call(v);
|
|
3624
|
-
}
|
|
3625
|
-
function L(m, g, I = {}) {
|
|
3626
|
-
if (g.length === 0) return;
|
|
3627
|
-
const v = [...e.value];
|
|
3628
|
-
let A = v.findIndex((w) => !w.inverted && w.subject === m.subject), S = A === -1 ? void 0 : { ...v[A] }, H = Xe(S ?? {}) ?? {};
|
|
3629
|
-
for (const w of g) {
|
|
3630
|
-
const V = w.mode === "inherit" ? w.builder.fromCondition(void 0) : w.form;
|
|
3631
|
-
H = Dt(H, [{ builder: w.builder, formValue: V }]);
|
|
3632
|
-
}
|
|
3633
|
-
const x = g.some((w) => w.mode === "custom");
|
|
3634
|
-
if (!S && (Object.keys(H).length > 0 || x)) {
|
|
3635
|
-
const w = t.value.find((te) => te.subject === m.subject);
|
|
3636
|
-
if (!w) return;
|
|
3637
|
-
const {
|
|
3638
|
-
category: V,
|
|
3639
|
-
showByFeatureFlag: j,
|
|
3640
|
-
isCategoryCover: Z,
|
|
3641
|
-
...X
|
|
3642
|
-
} = w;
|
|
3643
|
-
S = {
|
|
3644
|
-
...X,
|
|
3645
|
-
actions: m.actions.length > 0 ? m.actions : X.actions
|
|
3646
|
-
}, v.push(S), A = v.length - 1;
|
|
3647
|
-
}
|
|
3648
|
-
if (S) {
|
|
3649
|
-
const w = a(m.subject), V = w ? d(w) : void 0;
|
|
3650
|
-
if (!x && Object.keys(H).length === 0 && !!V && kt(V, S))
|
|
3651
|
-
v.splice(A, 1), S = void 0;
|
|
3652
|
-
else {
|
|
3653
|
-
if (S.actions = [
|
|
3654
|
-
.../* @__PURE__ */ new Set([...S.actions, ...m.actions])
|
|
3655
|
-
], V)
|
|
3656
|
-
for (const Z of g)
|
|
3657
|
-
Z.mode === "inherit" && (H = {
|
|
3658
|
-
...H,
|
|
3659
|
-
...nt(Xe(V), Z.builder)
|
|
3660
|
-
});
|
|
3661
|
-
Object.keys(H).length === 0 ? delete S.conditions : S.conditions = JSON.stringify(H), v[A] = S;
|
|
3662
|
-
}
|
|
3663
|
-
}
|
|
3664
|
-
const _ = () => {
|
|
3665
|
-
const w = new Set(r.value);
|
|
3666
|
-
for (const V of g) {
|
|
3667
|
-
const j = gt(m.subject, V.builder);
|
|
3668
|
-
V.mode === "custom" ? w.add(j) : w.delete(j);
|
|
3669
|
-
}
|
|
3670
|
-
r.value = w;
|
|
3671
|
-
}, O = (w) => {
|
|
3672
|
-
var V;
|
|
3673
|
-
_(), n(w), (V = I.afterCommit) == null || V.call(I);
|
|
3674
|
-
};
|
|
3675
|
-
if (!tn(m.subject, t.value) || !S) {
|
|
3676
|
-
O(v);
|
|
3677
|
-
return;
|
|
3678
|
-
}
|
|
3679
|
-
const P = g.map((w) => w.builder).filter((w) => R(m.subject, w).length > 0), F = () => {
|
|
3680
|
-
let w = v;
|
|
3681
|
-
for (const V of g.map((j) => j.builder))
|
|
3682
|
-
M(m.subject, V), w = p(w, S, V);
|
|
3683
|
-
O(w);
|
|
3684
|
-
};
|
|
3685
|
-
if (P.length > 0 && I.onOverridesConflict) {
|
|
3686
|
-
I.onOverridesConflict({ override: F, keep: () => O(v) });
|
|
3687
|
-
return;
|
|
3688
|
-
}
|
|
3689
|
-
P.length > 0 ? O(v) : F();
|
|
3690
|
-
}
|
|
3691
|
-
return {
|
|
3692
|
-
getCoverSubject: a,
|
|
3693
|
-
coverLabel: f,
|
|
3694
|
-
shouldShowInheritToggle: b,
|
|
3695
|
-
inheritMode: E,
|
|
3696
|
-
setInheritMode: D,
|
|
3697
|
-
inheritedSummary: N,
|
|
3698
|
-
getEffectiveActions: k,
|
|
3699
|
-
updateBuilderCondition: h,
|
|
3700
|
-
applyConditionDrafts: L
|
|
3701
|
-
};
|
|
3702
|
-
}
|
|
3703
|
-
const mo = { class: "h-[24px] w-[24px] flex items-center justify-center" }, fo = { class: "h-[24px] w-[24px] flex items-center justify-center" }, _o = "condition-form-select-menu", So = /* @__PURE__ */ Re({
|
|
3704
|
-
__name: "PortalPermissionEditor",
|
|
3705
|
-
props: /* @__PURE__ */ en({
|
|
3706
|
-
disable: {
|
|
3707
|
-
type: Boolean,
|
|
3708
|
-
default: !1
|
|
3709
|
-
},
|
|
3710
|
-
inheritPermissions: {
|
|
3711
|
-
type: Array,
|
|
3712
|
-
default: () => []
|
|
3713
|
-
},
|
|
3714
|
-
/**
|
|
3715
|
-
* 'all': every section in its own box (permission roles page).
|
|
3716
|
-
* 'workplace': only manageable restaurant / warehouse / usable POS roles ("Where they work").
|
|
3717
|
-
* 'portal': only the portal permission categories ("Portal access").
|
|
3718
|
-
* The member sheet renders the two parts in separate cards over the same rules.
|
|
3719
|
-
*/
|
|
3720
|
-
part: {
|
|
3721
|
-
type: String,
|
|
3722
|
-
default: "all"
|
|
3723
|
-
}
|
|
3724
|
-
}, {
|
|
3725
|
-
modelValue: { default: () => [] },
|
|
3726
|
-
modelModifiers: {}
|
|
3727
|
-
}),
|
|
3728
|
-
emits: /* @__PURE__ */ en(["permissionChanged"], ["update:modelValue"]),
|
|
3729
|
-
setup(e, { emit: t }) {
|
|
3730
|
-
const n = vr(e, "modelValue"), r = e, a = K(() => r.part === "all" ? "trailing" : "leading"), o = K(
|
|
3731
|
-
() => r.part === "all" ? "p-16 fm-corner-radius-lg border border-fm-color-neutral-gray-200" : ""
|
|
3732
|
-
), f = t, { t: d } = Ke(), i = hr(), b = br(), { breakpoints: E } = gr(), N = K(() => E.value.xs || E.value.sm), {
|
|
3733
|
-
fetchCustomReportPermissions: T,
|
|
3734
|
-
customReportPermissions: D
|
|
3735
|
-
} = Ir(), k = K(() => [
|
|
3736
|
-
...Gn,
|
|
3737
|
-
...D.value
|
|
3738
|
-
]), R = K(() => {
|
|
3739
|
-
const s = i.currentBusiness.value, c = i.currentCountry.value, y = c instanceof Object ? c.code : c;
|
|
3740
|
-
return io(s, y);
|
|
3741
|
-
});
|
|
3742
|
-
function M(s) {
|
|
3743
|
-
return k.value.find((c) => c.subject === s);
|
|
3744
|
-
}
|
|
3745
|
-
function p(s, c) {
|
|
3746
|
-
return rn(s).filter(
|
|
3747
|
-
(y) => {
|
|
3748
|
-
var U;
|
|
3749
|
-
return ((U = y.appliesToActions) == null ? void 0 : U.call(y, c)) ?? !0;
|
|
3750
|
-
}
|
|
3751
|
-
);
|
|
3752
|
-
}
|
|
3753
|
-
const h = K(() => {
|
|
3754
|
-
const s = k.value.filter((y) => !I.includes(y.subject)).map((y) => y.subject);
|
|
3755
|
-
return Er(
|
|
3756
|
-
r.inheritPermissions.map((y) => ({
|
|
3757
|
-
...y,
|
|
3758
|
-
permissions: y.permissions.filter((U) => s.includes(U.subject))
|
|
3759
|
-
}))
|
|
3760
|
-
).map((y) => ({
|
|
3761
|
-
id: y.subject,
|
|
3762
|
-
setNames: y.setNames
|
|
3763
|
-
}));
|
|
3764
|
-
}), L = K(() => {
|
|
3765
|
-
const s = r.inheritPermissions.map((c) => ({
|
|
3766
|
-
...c,
|
|
3767
|
-
permissions: c.permissions.filter(
|
|
3768
|
-
(y) => y.subject === Ye.Subject.Business.inventory_stock
|
|
3769
|
-
)
|
|
3770
|
-
}));
|
|
3771
|
-
return Lt(
|
|
3772
|
-
s,
|
|
3773
|
-
"warehouseId",
|
|
3774
|
-
A.value.map((c) => c._id)
|
|
3775
|
-
);
|
|
3776
|
-
}), m = K(() => {
|
|
3777
|
-
const s = r.inheritPermissions.map((c) => ({
|
|
3778
|
-
...c,
|
|
3779
|
-
permissions: c.permissions.filter(
|
|
3780
|
-
(y) => y.subject === Ye.Subject.Restaurant.restaurant
|
|
3781
|
-
)
|
|
3782
|
-
}));
|
|
3783
|
-
return Lt(
|
|
3784
|
-
s,
|
|
3785
|
-
"restaurantId",
|
|
3786
|
-
_.value.map((c) => c._id)
|
|
3787
|
-
);
|
|
3788
|
-
}), g = K(() => {
|
|
3789
|
-
const s = r.inheritPermissions.map((c) => ({
|
|
3790
|
-
...c,
|
|
3791
|
-
permissions: c.permissions.filter((y) => y.subject === Ye.Subject.Business.role)
|
|
3792
|
-
}));
|
|
3793
|
-
return Lt(
|
|
3794
|
-
s,
|
|
3795
|
-
"roleId",
|
|
3796
|
-
O.value.map((c) => c._id)
|
|
3797
|
-
);
|
|
3798
|
-
}), I = [...wr], v = K(() => {
|
|
3799
|
-
var c;
|
|
3800
|
-
const s = (c = n.value) == null ? void 0 : c.find(
|
|
3801
|
-
(y) => y.subject === Ye.Subject.Business.inventory_stock
|
|
3802
|
-
);
|
|
3803
|
-
return s ? s.conditions ? JSON.parse(s.conditions).warehouseId.$in : null : [];
|
|
3804
|
-
}), A = st([]), S = K(() => A.value.map((s) => ({
|
|
3805
|
-
label: s.profile.name,
|
|
3806
|
-
value: s._id
|
|
3807
|
-
})));
|
|
3808
|
-
function H(s) {
|
|
3809
|
-
const c = x(n.value, s);
|
|
3810
|
-
n.value = c;
|
|
3811
|
-
}
|
|
3812
|
-
function x(s, c) {
|
|
3813
|
-
let y = Yn(
|
|
3814
|
-
s.filter((U) => U.subject !== Ye.Subject.Business.inventory_stock)
|
|
3815
|
-
);
|
|
3816
|
-
if (!c || c.length > 0) {
|
|
3817
|
-
const U = {
|
|
3818
|
-
actions: [Ye.Action.manage],
|
|
3819
|
-
subject: Ye.Subject.Business.inventory_stock
|
|
3820
|
-
};
|
|
3821
|
-
c && (U.conditions = JSON.stringify({ warehouseId: { $in: c } })), y.push(U);
|
|
3822
|
-
}
|
|
3823
|
-
return y;
|
|
3824
|
-
}
|
|
3825
|
-
const { restaurants: _ } = i, O = Fr().roles, P = K(() => _.value.map((s) => ({
|
|
3826
|
-
label: `${s.profile.code ? s.profile.code + "-" : ""}${s.profile.name}`,
|
|
3827
|
-
value: s._id
|
|
3828
|
-
}))), F = K(() => _.value.reduce((s, c) => (s[c._id] = O.value.filter((y) => y.restaurants.some((U) => U.id === c._id)).map((y) => y._id), s), {})), w = K(() => Cr(n.value));
|
|
3829
|
-
function V(s) {
|
|
3830
|
-
const c = Z(n.value, s);
|
|
3831
|
-
n.value = c;
|
|
3832
|
-
}
|
|
3833
|
-
const j = K(() => Nr(n.value));
|
|
3834
|
-
function Z(s, c) {
|
|
3835
|
-
return Tr(s, c, {
|
|
3836
|
-
restaurantRoles: F.value,
|
|
3837
|
-
allRoleIds: O.value.map((y) => y._id)
|
|
3838
|
-
});
|
|
3839
|
-
}
|
|
3840
|
-
function X(s) {
|
|
3841
|
-
const c = te(n.value, s);
|
|
3842
|
-
n.value = c;
|
|
3843
|
-
}
|
|
3844
|
-
function te(s, c) {
|
|
3845
|
-
return Or(s, c);
|
|
3846
|
-
}
|
|
3847
|
-
xn(async () => {
|
|
3848
|
-
await Promise.all([
|
|
3849
|
-
r.part !== "portal" && so.readWarehouses().then((s) => A.value = s),
|
|
3850
|
-
T()
|
|
3851
|
-
]);
|
|
3852
|
-
});
|
|
3853
|
-
const z = K(() => Wn(
|
|
3854
|
-
n.value,
|
|
3855
|
-
Zn
|
|
3856
|
-
).filter((y) => {
|
|
3857
|
-
const U = y.source;
|
|
3858
|
-
return (U == null ? void 0 : U.type) !== "systemPermissionSet" ? !0 : y.actions.includes("manage");
|
|
3859
|
-
}).map((y) => {
|
|
3860
|
-
if (y.inverted) return y;
|
|
3861
|
-
const U = y.actions;
|
|
3862
|
-
if (!U.includes("manage")) return y;
|
|
3863
|
-
const W = M(y.subject);
|
|
3864
|
-
if (!W) return y;
|
|
3865
|
-
const u = W.actions;
|
|
3866
|
-
return u.length <= 1 || u.filter((Q) => !U.includes(Q)).length === 0 ? y : { ...y, actions: [...u] };
|
|
3867
|
-
}));
|
|
3868
|
-
function de(s) {
|
|
3869
|
-
n.value = ao(
|
|
3870
|
-
z.value,
|
|
3871
|
-
s,
|
|
3872
|
-
n.value,
|
|
3873
|
-
M
|
|
3874
|
-
);
|
|
3875
|
-
}
|
|
3876
|
-
const ve = K(() => new Set(
|
|
3877
|
-
k.value.filter((s) => rn(s.subject).length > 0).map((s) => s.subject)
|
|
3878
|
-
)), he = K(() => {
|
|
3879
|
-
const s = /* @__PURE__ */ new Map();
|
|
3880
|
-
return z.value.map((c) => ({
|
|
3881
|
-
rule: c,
|
|
3882
|
-
index: n.value.findIndex(
|
|
3883
|
-
(y) => !y.inverted && y.subject === c.subject
|
|
3884
|
-
)
|
|
3885
|
-
})).filter(({ rule: c }) => !c.inverted).forEach(({ rule: c, index: y }) => {
|
|
3886
|
-
var C;
|
|
3887
|
-
const U = c.actions, W = p(c.subject, U);
|
|
3888
|
-
if (W.length === 0) return;
|
|
3889
|
-
let u;
|
|
3890
|
-
try {
|
|
3891
|
-
u = c.conditions ? JSON.parse(c.conditions) : void 0;
|
|
3892
|
-
} catch {
|
|
3893
|
-
u = void 0;
|
|
3894
|
-
}
|
|
3895
|
-
s.set(c.subject, {
|
|
3896
|
-
index: y >= 0 ? y : null,
|
|
3897
|
-
subject: c.subject,
|
|
3898
|
-
label: ((C = M(c.subject)) == null ? void 0 : C.label) ?? c.subject,
|
|
3899
|
-
actions: U,
|
|
3900
|
-
// Each builder only ever sees its own slice of the stored condition.
|
|
3901
|
-
sections: W.map((Q) => ({
|
|
3902
|
-
builder: Q,
|
|
3903
|
-
formValue: Q.fromCondition(nt(u, Q))
|
|
3904
|
-
}))
|
|
3905
|
-
});
|
|
3906
|
-
}), s;
|
|
3907
|
-
}), ae = uo(n, k, (s) => {
|
|
3908
|
-
n.value = s;
|
|
3909
|
-
}), le = Sr(n), Ae = st(null);
|
|
3910
|
-
function Y(s, c) {
|
|
3911
|
-
const y = he.value.get(s);
|
|
3912
|
-
if (y) return y;
|
|
3913
|
-
const U = ae.getEffectiveActions(s), W = p(s, U);
|
|
3914
|
-
if (W.length !== 0)
|
|
3915
|
-
return {
|
|
3916
|
-
index: null,
|
|
3917
|
-
subject: s,
|
|
3918
|
-
label: c,
|
|
3919
|
-
actions: U,
|
|
3920
|
-
sections: W.map((u) => ({
|
|
3921
|
-
builder: u,
|
|
3922
|
-
formValue: u.fromCondition(void 0)
|
|
3923
|
-
}))
|
|
3924
|
-
};
|
|
3925
|
-
}
|
|
3926
|
-
function fe(s, c) {
|
|
3927
|
-
const y = le.getDraft({ subject: s.subject, builderKey: c.builderKey });
|
|
3928
|
-
if (y) return y.formValue;
|
|
3929
|
-
const U = s.sections.find((W) => W.builder.builderKey === c.builderKey);
|
|
3930
|
-
return U == null ? void 0 : U.formValue;
|
|
3931
|
-
}
|
|
3932
|
-
function $e(s, c) {
|
|
3933
|
-
const y = le.getDraft({ subject: s.subject, builderKey: c.builderKey });
|
|
3934
|
-
return y != null && y.inheritMode ? y.inheritMode : ae.inheritMode(s, c);
|
|
3935
|
-
}
|
|
3936
|
-
function Qe(s, c, y) {
|
|
3937
|
-
const U = le.getDraft({
|
|
3938
|
-
subject: s.subject,
|
|
3939
|
-
builderKey: c.builderKey
|
|
3940
|
-
});
|
|
3941
|
-
le.setDraft(
|
|
3942
|
-
{ subject: s.subject, builderKey: c.builderKey },
|
|
3943
|
-
{
|
|
3944
|
-
formValue: y,
|
|
3945
|
-
inheritMode: (U == null ? void 0 : U.inheritMode) ?? $e(s, c)
|
|
3946
|
-
}
|
|
3947
|
-
);
|
|
3948
|
-
}
|
|
3949
|
-
function Ve(s, c, y) {
|
|
3950
|
-
const U = le.getDraft({
|
|
3951
|
-
subject: s.subject,
|
|
3952
|
-
builderKey: c.builderKey
|
|
3953
|
-
}), W = s.sections.find((u) => u.builder.builderKey === c.builderKey);
|
|
3954
|
-
le.setDraft(
|
|
3955
|
-
{ subject: s.subject, builderKey: c.builderKey },
|
|
3956
|
-
{
|
|
3957
|
-
formValue: (U == null ? void 0 : U.formValue) ?? (W == null ? void 0 : W.formValue),
|
|
3958
|
-
inheritMode: y
|
|
3959
|
-
}
|
|
3960
|
-
);
|
|
3961
|
-
}
|
|
3962
|
-
function we(s) {
|
|
3963
|
-
return le.hasDraftsForSubject(s);
|
|
3964
|
-
}
|
|
3965
|
-
function Fe(s, c) {
|
|
3966
|
-
const y = s.sections.flatMap((U) => {
|
|
3967
|
-
const W = le.getDraft({
|
|
3968
|
-
subject: s.subject,
|
|
3969
|
-
builderKey: U.builder.builderKey
|
|
3970
|
-
});
|
|
3971
|
-
return W ? [{ builder: U.builder, form: W.formValue, mode: W.inheritMode ?? "custom" }] : [];
|
|
3972
|
-
});
|
|
3973
|
-
ae.applyConditionDrafts(s, y, {
|
|
3974
|
-
afterCommit: () => {
|
|
3975
|
-
le.clearDraftsForSubject(s.subject), c();
|
|
3976
|
-
},
|
|
3977
|
-
onOverridesConflict: l(s).onOverridesConflict
|
|
3978
|
-
});
|
|
3979
|
-
}
|
|
3980
|
-
function Ge(s) {
|
|
3981
|
-
return s.sections.some((c) => ae.shouldShowInheritToggle(s, c.builder) ? ae.inheritMode(s, c.builder) === "custom" : Object.keys(c.builder.toCondition(c.formValue)).length > 0);
|
|
3982
|
-
}
|
|
3983
|
-
let Pe = !1;
|
|
3984
|
-
function l(s, c = {}) {
|
|
3985
|
-
return {
|
|
3986
|
-
...c,
|
|
3987
|
-
onOverridesConflict: ({ override: y, keep: U }) => {
|
|
3988
|
-
Pe || (Pe = !0, b.open({
|
|
3989
|
-
title: d("team.memberForm.permissions.conditionCover.confirmTitle"),
|
|
3990
|
-
message: d("team.memberForm.permissions.conditionCover.confirmMessage", {
|
|
3991
|
-
cover: s.label
|
|
3992
|
-
}),
|
|
3993
|
-
minWidth: E.value.lg ? 588 : 0,
|
|
3994
|
-
zIndex: 200,
|
|
3995
|
-
primaryActions: {
|
|
3996
|
-
text: d("team.memberForm.permissions.conditionCover.override"),
|
|
3997
|
-
close: !1
|
|
3998
|
-
},
|
|
3999
|
-
secondaryActions: {
|
|
4000
|
-
text: d("team.memberForm.permissions.conditionCover.keep"),
|
|
4001
|
-
close: !1
|
|
4002
|
-
}
|
|
4003
|
-
}).onPrimary(() => {
|
|
4004
|
-
y(), Pe = !1, b.close();
|
|
4005
|
-
}).onSecondary(() => {
|
|
4006
|
-
U(), Pe = !1, b.close();
|
|
4007
|
-
}).onClose(() => {
|
|
4008
|
-
Pe = !1;
|
|
4009
|
-
}));
|
|
4010
|
-
}
|
|
4011
|
-
};
|
|
4012
|
-
}
|
|
4013
|
-
return Mt(
|
|
4014
|
-
n,
|
|
4015
|
-
(s) => {
|
|
4016
|
-
f("permissionChanged", s);
|
|
4017
|
-
},
|
|
4018
|
-
{ deep: !0 }
|
|
4019
|
-
), (s, c) => {
|
|
4020
|
-
const y = De("FmIcon"), U = De("FmBottomSheet"), W = De("FmPopover");
|
|
4021
|
-
return $(), re("div", {
|
|
4022
|
-
class: Ie(["flex flex-col", e.part === "all" ? "gap-32" : "gap-16"])
|
|
4023
|
-
}, [
|
|
4024
|
-
e.part !== "workplace" ? ($(), re("div", {
|
|
4025
|
-
key: 0,
|
|
4026
|
-
class: Ie(o.value)
|
|
4027
|
-
}, [
|
|
4028
|
-
oe(Ba, {
|
|
4029
|
-
"model-value": z.value,
|
|
4030
|
-
"excluded-subjects": I,
|
|
4031
|
-
"additional-permissions": B(D),
|
|
4032
|
-
layout: a.value,
|
|
4033
|
-
"onUpdate:modelValue": de
|
|
4034
|
-
}, tt({ _: 2 }, [
|
|
4035
|
-
Ee(h.value, (u) => ({
|
|
4036
|
-
name: `checkbox-${u.id}-append`,
|
|
4037
|
-
fn: ce(() => [
|
|
4038
|
-
oe(vt, { item: u }, null, 8, ["item"])
|
|
4039
|
-
])
|
|
4040
|
-
})),
|
|
4041
|
-
Ee(ve.value, (u) => ({
|
|
4042
|
-
name: `checkbox-${u}-icon`,
|
|
4043
|
-
fn: ce(({ option: C, isEffectiveSelected: Q }) => [
|
|
4044
|
-
Q && Y(u, C.label) ? ($(), re(Me, { key: 0 }, [
|
|
4045
|
-
N.value ? ($(), Ne(U, {
|
|
4046
|
-
key: 0,
|
|
4047
|
-
"model-value": Ae.value === u,
|
|
4048
|
-
header: B(d)("team.memberForm.permissions.conditionTitle", {
|
|
4049
|
-
context: Y(u, C.label).label
|
|
4050
|
-
}),
|
|
4051
|
-
"dismiss-away": "",
|
|
4052
|
-
"z-index": 100,
|
|
4053
|
-
class: "h-5 flex items-center",
|
|
4054
|
-
"onUpdate:modelValue": (J) => {
|
|
4055
|
-
Ae.value = J ? u : null, J || B(le).clearDraftsForSubject(u);
|
|
4056
|
-
}
|
|
4057
|
-
}, {
|
|
4058
|
-
"bottom-sheet-button": ce(() => [
|
|
4059
|
-
ie("div", mo, [
|
|
4060
|
-
oe(y, {
|
|
4061
|
-
name: "settings",
|
|
4062
|
-
size: "sm",
|
|
4063
|
-
class: Ie([
|
|
4064
|
-
"cursor-pointer transition-colors",
|
|
4065
|
-
Ge(Y(u, C.label)) ? "text-fm-color-primary-main" : "text-fm-color-neutral-gray-400 hover:text-fm-color-neutral-gray-600"
|
|
4066
|
-
])
|
|
4067
|
-
}, null, 8, ["class"])
|
|
4068
|
-
])
|
|
4069
|
-
]),
|
|
4070
|
-
default: ce(() => [
|
|
4071
|
-
oe(wn, {
|
|
4072
|
-
entry: Y(u, C.label),
|
|
4073
|
-
builders: Y(u, C.label).sections.map((J) => J.builder),
|
|
4074
|
-
subject: u,
|
|
4075
|
-
"time-zone": R.value,
|
|
4076
|
-
"cover-override": B(ae),
|
|
4077
|
-
"inherit-mode-for": (J) => $e(Y(u, C.label), J),
|
|
4078
|
-
"form-value-for": (J) => fe(Y(u, C.label), J),
|
|
4079
|
-
"has-changes": we(u),
|
|
4080
|
-
disable: e.disable,
|
|
4081
|
-
"full-width": !0,
|
|
4082
|
-
onUpdateInheritMode: ({ builder: J, mode: me }) => Ve(Y(u, C.label), J, me),
|
|
4083
|
-
onUpdateForm: ({ builder: J, form: me }) => Qe(Y(u, C.label), J, me),
|
|
4084
|
-
onApply: (J) => Fe(Y(u, C.label), () => Ae.value = null)
|
|
4085
|
-
}, null, 8, ["entry", "builders", "subject", "time-zone", "cover-override", "inherit-mode-for", "form-value-for", "has-changes", "disable", "onUpdateInheritMode", "onUpdateForm", "onApply"])
|
|
4086
|
-
]),
|
|
4087
|
-
_: 2
|
|
4088
|
-
}, 1032, ["model-value", "header", "onUpdate:modelValue"])) : ($(), Ne(W, {
|
|
4089
|
-
key: 1,
|
|
4090
|
-
disabled: e.disable,
|
|
4091
|
-
"z-index": 100,
|
|
4092
|
-
"exclude-el-from-click-outside": [_o],
|
|
4093
|
-
class: "h-5 flex items-center",
|
|
4094
|
-
onPopoverChanged: (J) => {
|
|
4095
|
-
J || B(le).clearDraftsForSubject(u);
|
|
4096
|
-
}
|
|
4097
|
-
}, {
|
|
4098
|
-
"popover-button": ce(() => [
|
|
4099
|
-
ie("div", fo, [
|
|
4100
|
-
oe(y, {
|
|
4101
|
-
name: "settings",
|
|
4102
|
-
size: "sm",
|
|
4103
|
-
class: Ie([
|
|
4104
|
-
"cursor-pointer transition-colors",
|
|
4105
|
-
Ge(Y(u, C.label)) ? "text-fm-color-primary-main" : "text-fm-color-neutral-gray-400 hover:text-fm-color-neutral-gray-600"
|
|
4106
|
-
])
|
|
4107
|
-
}, null, 8, ["class"])
|
|
4108
|
-
])
|
|
4109
|
-
]),
|
|
4110
|
-
default: ce(({ hide: J }) => [
|
|
4111
|
-
oe(wn, {
|
|
4112
|
-
entry: Y(u, C.label),
|
|
4113
|
-
builders: Y(u, C.label).sections.map((me) => me.builder),
|
|
4114
|
-
subject: u,
|
|
4115
|
-
"time-zone": R.value,
|
|
4116
|
-
"cover-override": B(ae),
|
|
4117
|
-
title: B(d)("team.memberForm.permissions.conditionTitle", {
|
|
4118
|
-
context: Y(u, C.label).label
|
|
4119
|
-
}),
|
|
4120
|
-
"inherit-mode-for": (me) => $e(Y(u, C.label), me),
|
|
4121
|
-
"form-value-for": (me) => fe(Y(u, C.label), me),
|
|
4122
|
-
"has-changes": we(u),
|
|
4123
|
-
disable: e.disable,
|
|
4124
|
-
onUpdateInheritMode: ({ builder: me, mode: We }) => Ve(
|
|
4125
|
-
Y(u, C.label),
|
|
4126
|
-
me,
|
|
4127
|
-
We
|
|
4128
|
-
),
|
|
4129
|
-
onUpdateForm: ({ builder: me, form: We }) => Qe(Y(u, C.label), me, We),
|
|
4130
|
-
onApply: (me) => Fe(Y(u, C.label), J)
|
|
4131
|
-
}, null, 8, ["entry", "builders", "subject", "time-zone", "cover-override", "title", "inherit-mode-for", "form-value-for", "has-changes", "disable", "onUpdateInheritMode", "onUpdateForm", "onApply"])
|
|
4132
|
-
]),
|
|
4133
|
-
_: 2
|
|
4134
|
-
}, 1032, ["disabled", "exclude-el-from-click-outside", "onPopoverChanged"]))
|
|
4135
|
-
], 64)) : ($(), Ne(y, {
|
|
4136
|
-
key: 1,
|
|
4137
|
-
name: "settings",
|
|
4138
|
-
size: "sm",
|
|
4139
|
-
class: "invisible"
|
|
4140
|
-
}))
|
|
4141
|
-
])
|
|
4142
|
-
}))
|
|
4143
|
-
]), 1032, ["model-value", "additional-permissions", "layout"])
|
|
4144
|
-
], 2)) : Ce("", !0),
|
|
4145
|
-
e.part !== "portal" ? ($(), re("div", {
|
|
4146
|
-
key: 1,
|
|
4147
|
-
class: Ie(o.value)
|
|
4148
|
-
}, [
|
|
4149
|
-
oe(Dn, {
|
|
4150
|
-
"model-value": v.value,
|
|
4151
|
-
options: S.value,
|
|
4152
|
-
context: B(d)("team.labels.warehouse"),
|
|
4153
|
-
layout: a.value,
|
|
4154
|
-
"onUpdate:modelValue": H
|
|
4155
|
-
}, tt({ _: 2 }, [
|
|
4156
|
-
Ee(L.value, (u) => ({
|
|
4157
|
-
name: `checkbox-${u.id}-append`,
|
|
4158
|
-
fn: ce(() => [
|
|
4159
|
-
oe(vt, { item: u }, null, 8, ["item"])
|
|
4160
|
-
])
|
|
4161
|
-
}))
|
|
4162
|
-
]), 1032, ["model-value", "options", "context", "layout"])
|
|
4163
|
-
], 2)) : Ce("", !0),
|
|
4164
|
-
e.part !== "portal" ? ($(), re("div", {
|
|
4165
|
-
key: 2,
|
|
4166
|
-
class: Ie([o.value, { "order-first": e.part === "workplace" }])
|
|
4167
|
-
}, [
|
|
4168
|
-
oe(Dn, {
|
|
4169
|
-
"model-value": w.value,
|
|
4170
|
-
options: P.value,
|
|
4171
|
-
context: B(d)("team.labels.restaurant"),
|
|
4172
|
-
layout: a.value,
|
|
4173
|
-
"onUpdate:modelValue": V
|
|
4174
|
-
}, tt({ _: 2 }, [
|
|
4175
|
-
Ee(m.value, (u) => ({
|
|
4176
|
-
name: `checkbox-${u.id}-append`,
|
|
4177
|
-
fn: ce(() => [
|
|
4178
|
-
oe(vt, { item: u }, null, 8, ["item"])
|
|
4179
|
-
])
|
|
4180
|
-
}))
|
|
4181
|
-
]), 1032, ["model-value", "options", "context", "layout"])
|
|
4182
|
-
], 2)) : Ce("", !0),
|
|
4183
|
-
e.part !== "portal" ? ($(), re("div", {
|
|
4184
|
-
key: 3,
|
|
4185
|
-
class: Ie(o.value)
|
|
4186
|
-
}, [
|
|
4187
|
-
oe(eo, {
|
|
4188
|
-
roles: B(O),
|
|
4189
|
-
"model-value": j.value,
|
|
4190
|
-
"restaurant-ids": w.value,
|
|
4191
|
-
layout: a.value,
|
|
4192
|
-
"onUpdate:modelValue": X
|
|
4193
|
-
}, tt({ _: 2 }, [
|
|
4194
|
-
Ee(g.value, (u) => ({
|
|
4195
|
-
name: `checkbox-${u.id}-append`,
|
|
4196
|
-
fn: ce(() => [
|
|
4197
|
-
oe(vt, { item: u }, null, 8, ["item"])
|
|
4198
|
-
])
|
|
4199
|
-
}))
|
|
4200
|
-
]), 1032, ["roles", "model-value", "restaurant-ids", "layout"])
|
|
4201
|
-
], 2)) : Ce("", !0)
|
|
4202
|
-
], 2);
|
|
4203
|
-
};
|
|
4204
|
-
}
|
|
4205
|
-
});
|
|
4206
|
-
export {
|
|
4207
|
-
So as _
|
|
4208
|
-
};
|