@masonitestudios/spartanauth-widgets 1.0.3 → 1.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,114 +1,120 @@
1
- const Zt = (e, t) => e === t, He = {
2
- equals: Zt
1
+ const Qt = (e, t) => e === t, Ze = {
2
+ equals: Qt
3
3
  };
4
- let xt = Ot;
5
- const _e = 1, We = 2, St = {
4
+ let Tt = zt;
5
+ const Te = 1, Ye = 2, Ot = {
6
6
  owned: null,
7
7
  cleanups: null,
8
8
  context: null,
9
9
  owner: null
10
10
  };
11
- var ce = null;
12
- let rt = null, Yt = null, Y = null, ie = null, ke = null, et = 0;
13
- function Xt(e, t) {
14
- const n = Y, r = ce, s = e.length === 0, i = t === void 0 ? r : t, u = s ? St : {
11
+ var Q = null;
12
+ let at = null, en = null, X = null, ae = null, Be = null, nt = 0;
13
+ function tn(e, t) {
14
+ const n = X, r = Q, s = e.length === 0, i = t === void 0 ? r : t, u = s ? Ot : {
15
15
  owned: null,
16
16
  cleanups: null,
17
17
  context: i ? i.context : null,
18
18
  owner: i
19
- }, l = s ? e : () => e(() => tt(() => Ue(u)));
20
- ce = u, Y = null;
19
+ }, o = s ? e : () => e(() => rt(() => Je(u)));
20
+ Q = u, X = null;
21
21
  try {
22
- return Ve(l, !0);
22
+ return Ke(o, !0);
23
23
  } finally {
24
- Y = n, ce = r;
24
+ X = n, Q = r;
25
25
  }
26
26
  }
27
27
  function w(e, t) {
28
- t = t ? Object.assign({}, He, t) : He;
28
+ t = t ? Object.assign({}, Ze, t) : Ze;
29
29
  const n = {
30
30
  value: e,
31
31
  observers: null,
32
32
  observerSlots: null,
33
33
  comparator: t.equals || void 0
34
- }, r = (s) => (typeof s == "function" && (s = s(n.value)), Tt(n, s));
35
- return [_t.bind(n), r];
34
+ }, r = (s) => (typeof s == "function" && (s = s(n.value)), Pt(n, s));
35
+ return [It.bind(n), r];
36
36
  }
37
37
  function y(e, t, n) {
38
- const r = dt(e, t, !1, _e);
39
- Je(r);
40
- }
41
- function Qt(e, t, n) {
42
- xt = nn;
43
- const r = dt(e, t, !1, _e);
44
- r.user = !0, ke ? ke.push(r) : Je(r);
45
- }
46
- function p(e, t, n) {
47
- n = n ? Object.assign({}, He, n) : He;
48
- const r = dt(e, t, !0, 0);
49
- return r.observers = null, r.observerSlots = null, r.comparator = n.equals || void 0, Je(r), _t.bind(r);
50
- }
51
- function tt(e) {
52
- if (Y === null) return e();
53
- const t = Y;
54
- Y = null;
38
+ const r = pt(e, t, !1, Te);
39
+ Ve(r);
40
+ }
41
+ function nn(e, t, n) {
42
+ Tt = on;
43
+ const r = pt(e, t, !1, Te);
44
+ r.user = !0, Be ? Be.push(r) : Ve(r);
45
+ }
46
+ function h(e, t, n) {
47
+ n = n ? Object.assign({}, Ze, n) : Ze;
48
+ const r = pt(e, t, !0, 0);
49
+ return r.observers = null, r.observerSlots = null, r.comparator = n.equals || void 0, Ve(r), It.bind(r);
50
+ }
51
+ function rt(e) {
52
+ if (X === null) return e();
53
+ const t = X;
54
+ X = null;
55
55
  try {
56
56
  return e();
57
57
  } finally {
58
- Y = t;
58
+ X = t;
59
59
  }
60
60
  }
61
- function ct(e) {
62
- Qt(() => tt(e));
61
+ function ht(e) {
62
+ nn(() => rt(e));
63
+ }
64
+ function rn(e) {
65
+ return Q === null || (Q.cleanups === null ? Q.cleanups = [e] : Q.cleanups.push(e)), e;
66
+ }
67
+ function sn() {
68
+ return Q;
63
69
  }
64
- function _t() {
70
+ function It() {
65
71
  if (this.sources && this.state)
66
- if (this.state === _e) Je(this);
72
+ if (this.state === Te) Ve(this);
67
73
  else {
68
- const e = ie;
69
- ie = null, Ve(() => Ye(this), !1), ie = e;
74
+ const e = ae;
75
+ ae = null, Ke(() => Qe(this), !1), ae = e;
70
76
  }
71
- if (Y) {
77
+ if (X) {
72
78
  const e = this.observers ? this.observers.length : 0;
73
- Y.sources ? (Y.sources.push(this), Y.sourceSlots.push(e)) : (Y.sources = [this], Y.sourceSlots = [e]), this.observers ? (this.observers.push(Y), this.observerSlots.push(Y.sources.length - 1)) : (this.observers = [Y], this.observerSlots = [Y.sources.length - 1]);
79
+ X.sources ? (X.sources.push(this), X.sourceSlots.push(e)) : (X.sources = [this], X.sourceSlots = [e]), this.observers ? (this.observers.push(X), this.observerSlots.push(X.sources.length - 1)) : (this.observers = [X], this.observerSlots = [X.sources.length - 1]);
74
80
  }
75
81
  return this.value;
76
82
  }
77
- function Tt(e, t, n) {
83
+ function Pt(e, t, n) {
78
84
  let r = e.value;
79
- return (!e.comparator || !e.comparator(r, t)) && (e.value = t, e.observers && e.observers.length && Ve(() => {
85
+ return (!e.comparator || !e.comparator(r, t)) && (e.value = t, e.observers && e.observers.length && Ke(() => {
80
86
  for (let s = 0; s < e.observers.length; s += 1) {
81
- const i = e.observers[s], u = rt && rt.running;
82
- u && rt.disposed.has(i), (u ? !i.tState : !i.state) && (i.pure ? ie.push(i) : ke.push(i), i.observers && It(i)), u || (i.state = _e);
87
+ const i = e.observers[s], u = at && at.running;
88
+ u && at.disposed.has(i), (u ? !i.tState : !i.state) && (i.pure ? ae.push(i) : Be.push(i), i.observers && Nt(i)), u || (i.state = Te);
83
89
  }
84
- if (ie.length > 1e6)
85
- throw ie = [], new Error();
90
+ if (ae.length > 1e6)
91
+ throw ae = [], new Error();
86
92
  }, !1)), t;
87
93
  }
88
- function Je(e) {
94
+ function Ve(e) {
89
95
  if (!e.fn) return;
90
- Ue(e);
91
- const t = et;
92
- en(
96
+ Je(e);
97
+ const t = nt;
98
+ an(
93
99
  e,
94
100
  e.value,
95
101
  t
96
102
  );
97
103
  }
98
- function en(e, t, n) {
104
+ function an(e, t, n) {
99
105
  let r;
100
- const s = ce, i = Y;
101
- Y = ce = e;
106
+ const s = Q, i = X;
107
+ X = Q = e;
102
108
  try {
103
109
  r = e.fn(t);
104
110
  } catch (u) {
105
- return e.pure && (e.state = _e, e.owned && e.owned.forEach(Ue), e.owned = null), e.updatedAt = n + 1, Pt(u);
111
+ return e.pure && (e.state = Te, e.owned && e.owned.forEach(Je), e.owned = null), e.updatedAt = n + 1, Mt(u);
106
112
  } finally {
107
- Y = i, ce = s;
113
+ X = i, Q = s;
108
114
  }
109
- (!e.updatedAt || e.updatedAt <= n) && (e.updatedAt != null && "observers" in e ? Tt(e, r) : e.value = r, e.updatedAt = n);
115
+ (!e.updatedAt || e.updatedAt <= n) && (e.updatedAt != null && "observers" in e ? Pt(e, r) : e.value = r, e.updatedAt = n);
110
116
  }
111
- function dt(e, t, n, r = _e, s) {
117
+ function pt(e, t, n, r = Te, s) {
112
118
  const i = {
113
119
  fn: e,
114
120
  state: r,
@@ -118,71 +124,71 @@ function dt(e, t, n, r = _e, s) {
118
124
  sourceSlots: null,
119
125
  cleanups: null,
120
126
  value: t,
121
- owner: ce,
122
- context: ce ? ce.context : null,
127
+ owner: Q,
128
+ context: Q ? Q.context : null,
123
129
  pure: n
124
130
  };
125
- return ce === null || ce !== St && (ce.owned ? ce.owned.push(i) : ce.owned = [i]), i;
131
+ return Q === null || Q !== Ot && (Q.owned ? Q.owned.push(i) : Q.owned = [i]), i;
126
132
  }
127
- function Ze(e) {
133
+ function Xe(e) {
128
134
  if (e.state === 0) return;
129
- if (e.state === We) return Ye(e);
130
- if (e.suspense && tt(e.suspense.inFallback)) return e.suspense.effects.push(e);
135
+ if (e.state === Ye) return Qe(e);
136
+ if (e.suspense && rt(e.suspense.inFallback)) return e.suspense.effects.push(e);
131
137
  const t = [e];
132
- for (; (e = e.owner) && (!e.updatedAt || e.updatedAt < et); )
138
+ for (; (e = e.owner) && (!e.updatedAt || e.updatedAt < nt); )
133
139
  e.state && t.push(e);
134
140
  for (let n = t.length - 1; n >= 0; n--)
135
- if (e = t[n], e.state === _e)
136
- Je(e);
137
- else if (e.state === We) {
138
- const r = ie;
139
- ie = null, Ve(() => Ye(e, t[0]), !1), ie = r;
141
+ if (e = t[n], e.state === Te)
142
+ Ve(e);
143
+ else if (e.state === Ye) {
144
+ const r = ae;
145
+ ae = null, Ke(() => Qe(e, t[0]), !1), ae = r;
140
146
  }
141
147
  }
142
- function Ve(e, t) {
143
- if (ie) return e();
148
+ function Ke(e, t) {
149
+ if (ae) return e();
144
150
  let n = !1;
145
- t || (ie = []), ke ? n = !0 : ke = [], et++;
151
+ t || (ae = []), Be ? n = !0 : Be = [], nt++;
146
152
  try {
147
153
  const r = e();
148
- return tn(n), r;
154
+ return un(n), r;
149
155
  } catch (r) {
150
- n || (ke = null), ie = null, Pt(r);
156
+ n || (Be = null), ae = null, Mt(r);
151
157
  }
152
158
  }
153
- function tn(e) {
154
- if (ie && (Ot(ie), ie = null), e) return;
155
- const t = ke;
156
- ke = null, t.length && Ve(() => xt(t), !1);
159
+ function un(e) {
160
+ if (ae && (zt(ae), ae = null), e) return;
161
+ const t = Be;
162
+ Be = null, t.length && Ke(() => Tt(t), !1);
157
163
  }
158
- function Ot(e) {
159
- for (let t = 0; t < e.length; t++) Ze(e[t]);
164
+ function zt(e) {
165
+ for (let t = 0; t < e.length; t++) Xe(e[t]);
160
166
  }
161
- function nn(e) {
167
+ function on(e) {
162
168
  let t, n = 0;
163
169
  for (t = 0; t < e.length; t++) {
164
170
  const r = e[t];
165
- r.user ? e[n++] = r : Ze(r);
171
+ r.user ? e[n++] = r : Xe(r);
166
172
  }
167
- for (t = 0; t < n; t++) Ze(e[t]);
173
+ for (t = 0; t < n; t++) Xe(e[t]);
168
174
  }
169
- function Ye(e, t) {
175
+ function Qe(e, t) {
170
176
  e.state = 0;
171
177
  for (let n = 0; n < e.sources.length; n += 1) {
172
178
  const r = e.sources[n];
173
179
  if (r.sources) {
174
180
  const s = r.state;
175
- s === _e ? r !== t && (!r.updatedAt || r.updatedAt < et) && Ze(r) : s === We && Ye(r, t);
181
+ s === Te ? r !== t && (!r.updatedAt || r.updatedAt < nt) && Xe(r) : s === Ye && Qe(r, t);
176
182
  }
177
183
  }
178
184
  }
179
- function It(e) {
185
+ function Nt(e) {
180
186
  for (let t = 0; t < e.observers.length; t += 1) {
181
187
  const n = e.observers[t];
182
- n.state || (n.state = We, n.pure ? ie.push(n) : ke.push(n), n.observers && It(n));
188
+ n.state || (n.state = Ye, n.pure ? ae.push(n) : Be.push(n), n.observers && Nt(n));
183
189
  }
184
190
  }
185
- function Ue(e) {
191
+ function Je(e) {
186
192
  let t;
187
193
  if (e.sources)
188
194
  for (; e.sources.length; ) {
@@ -193,11 +199,11 @@ function Ue(e) {
193
199
  }
194
200
  }
195
201
  if (e.tOwned) {
196
- for (t = e.tOwned.length - 1; t >= 0; t--) Ue(e.tOwned[t]);
202
+ for (t = e.tOwned.length - 1; t >= 0; t--) Je(e.tOwned[t]);
197
203
  delete e.tOwned;
198
204
  }
199
205
  if (e.owned) {
200
- for (t = e.owned.length - 1; t >= 0; t--) Ue(e.owned[t]);
206
+ for (t = e.owned.length - 1; t >= 0; t--) Je(e.owned[t]);
201
207
  e.owned = null;
202
208
  }
203
209
  if (e.cleanups) {
@@ -206,80 +212,80 @@ function Ue(e) {
206
212
  }
207
213
  e.state = 0;
208
214
  }
209
- function rn(e) {
215
+ function ln(e) {
210
216
  return e instanceof Error ? e : new Error(typeof e == "string" ? e : "Unknown error", {
211
217
  cause: e
212
218
  });
213
219
  }
214
- function Pt(e, t = ce) {
215
- throw rn(e);
220
+ function Mt(e, t = Q) {
221
+ throw ln(e);
216
222
  }
217
- function sn(e, t, n) {
218
- let r = n.length, s = t.length, i = r, u = 0, l = 0, C = t[s - 1].nextSibling, $ = null;
219
- for (; u < s || l < i; ) {
220
- if (t[u] === n[l]) {
221
- u++, l++;
223
+ function cn(e, t, n) {
224
+ let r = n.length, s = t.length, i = r, u = 0, o = 0, C = t[s - 1].nextSibling, $ = null;
225
+ for (; u < s || o < i; ) {
226
+ if (t[u] === n[o]) {
227
+ u++, o++;
222
228
  continue;
223
229
  }
224
230
  for (; t[s - 1] === n[i - 1]; )
225
231
  s--, i--;
226
232
  if (s === u) {
227
- const D = i < r ? l ? n[l - 1].nextSibling : n[i - l] : C;
228
- for (; l < i; ) e.insertBefore(n[l++], D);
229
- } else if (i === l)
233
+ const D = i < r ? o ? n[o - 1].nextSibling : n[i - o] : C;
234
+ for (; o < i; ) e.insertBefore(n[o++], D);
235
+ } else if (i === o)
230
236
  for (; u < s; )
231
237
  (!$ || !$.has(t[u])) && t[u].remove(), u++;
232
- else if (t[u] === n[i - 1] && n[l] === t[s - 1]) {
238
+ else if (t[u] === n[i - 1] && n[o] === t[s - 1]) {
233
239
  const D = t[--s].nextSibling;
234
- e.insertBefore(n[l++], t[u++].nextSibling), e.insertBefore(n[--i], D), t[s] = n[i];
240
+ e.insertBefore(n[o++], t[u++].nextSibling), e.insertBefore(n[--i], D), t[s] = n[i];
235
241
  } else {
236
242
  if (!$) {
237
243
  $ = /* @__PURE__ */ new Map();
238
- let B = l;
239
- for (; B < i; ) $.set(n[B], B++);
244
+ let k = o;
245
+ for (; k < i; ) $.set(n[k], k++);
240
246
  }
241
247
  const D = $.get(t[u]);
242
248
  if (D != null)
243
- if (l < D && D < i) {
244
- let B = u, ae = 1, de;
245
- for (; ++B < s && B < i && !((de = $.get(t[B])) == null || de !== D + ae); )
246
- ae++;
247
- if (ae > D - l) {
248
- const Ee = t[u];
249
- for (; l < D; ) e.insertBefore(n[l++], Ee);
250
- } else e.replaceChild(n[l++], t[u++]);
249
+ if (o < D && D < i) {
250
+ let k = u, ue = 1, fe;
251
+ for (; ++k < s && k < i && !((fe = $.get(t[k])) == null || fe !== D + ue); )
252
+ ue++;
253
+ if (ue > D - o) {
254
+ const Fe = t[u];
255
+ for (; o < D; ) e.insertBefore(n[o++], Fe);
256
+ } else e.replaceChild(n[o++], t[u++]);
251
257
  } else u++;
252
258
  else t[u++].remove();
253
259
  }
254
260
  }
255
261
  }
256
- const gt = "_$DX_DELEGATE";
262
+ const vt = "_$DX_DELEGATE";
257
263
  function F(e, t, n, r) {
258
264
  let s;
259
265
  const i = () => {
260
- const l = document.createElement("template");
261
- return l.innerHTML = e, l.content.firstChild;
266
+ const o = document.createElement("template");
267
+ return o.innerHTML = e, o.content.firstChild;
262
268
  }, u = () => (s || (s = i())).cloneNode(!0);
263
269
  return u.cloneNode = u, u;
264
270
  }
265
- function ft(e, t = window.document) {
266
- const n = t[gt] || (t[gt] = /* @__PURE__ */ new Set());
271
+ function Dt(e, t = window.document) {
272
+ const n = t[vt] || (t[vt] = /* @__PURE__ */ new Set());
267
273
  for (let r = 0, s = e.length; r < s; r++) {
268
274
  const i = e[r];
269
- n.has(i) || (n.add(i), t.addEventListener(i, an));
275
+ n.has(i) || (n.add(i), t.addEventListener(i, dn));
270
276
  }
271
277
  }
272
- function le(e, t, n) {
278
+ function de(e, t, n) {
273
279
  n == null ? e.removeAttribute(t) : e.setAttribute(t, n);
274
280
  }
275
- function zt(e, t, n) {
276
- return tt(() => e(t, n));
281
+ function jt(e, t, n) {
282
+ return rt(() => e(t, n));
277
283
  }
278
284
  function f(e, t, n, r) {
279
- if (n !== void 0 && !r && (r = []), typeof t != "function") return Xe(e, t, r, n);
280
- y((s) => Xe(e, t(), s, n), r);
285
+ if (n !== void 0 && !r && (r = []), typeof t != "function") return et(e, t, r, n);
286
+ y((s) => et(e, t(), s, n), r);
281
287
  }
282
- function an(e) {
288
+ function dn(e) {
283
289
  let t = e.target;
284
290
  const n = `$$${e.type}`, r = e.target, s = e.currentTarget, i = (C) => Object.defineProperty(e, "target", {
285
291
  configurable: !0,
@@ -291,7 +297,7 @@ function an(e) {
291
297
  if ($ !== void 0 ? C.call(t, $, e) : C.call(t, e), e.cancelBubble) return;
292
298
  }
293
299
  return t.host && typeof t.host != "string" && !t.host._$host && t.contains(e.target) && i(t.host), !0;
294
- }, l = () => {
300
+ }, o = () => {
295
301
  for (; u() && (t = t._$host || t.parentNode || t.host); ) ;
296
302
  };
297
303
  if (Object.defineProperty(e, "currentTarget", {
@@ -304,16 +310,16 @@ function an(e) {
304
310
  i(C[0]);
305
311
  for (let $ = 0; $ < C.length - 2 && (t = C[$], !!u()); $++) {
306
312
  if (t._$host) {
307
- t = t._$host, l();
313
+ t = t._$host, o();
308
314
  break;
309
315
  }
310
316
  if (t.parentNode === s)
311
317
  break;
312
318
  }
313
- } else l();
319
+ } else o();
314
320
  i(r);
315
321
  }
316
- function Xe(e, t, n, r, s) {
322
+ function et(e, t, n, r, s) {
317
323
  for (; typeof n == "function"; ) n = n();
318
324
  if (t === n) return n;
319
325
  const i = typeof t, u = r !== void 0;
@@ -321,109 +327,109 @@ function Xe(e, t, n, r, s) {
321
327
  if (i === "number" && (t = t.toString(), t === n))
322
328
  return n;
323
329
  if (u) {
324
- let l = n[0];
325
- l && l.nodeType === 3 ? l.data !== t && (l.data = t) : l = document.createTextNode(t), n = Ne(e, n, r, l);
330
+ let o = n[0];
331
+ o && o.nodeType === 3 ? o.data !== t && (o.data = t) : o = document.createTextNode(t), n = Me(e, n, r, o);
326
332
  } else
327
333
  n !== "" && typeof n == "string" ? n = e.firstChild.data = t : n = e.textContent = t;
328
334
  } else if (t == null || i === "boolean")
329
- n = Ne(e, n, r);
335
+ n = Me(e, n, r);
330
336
  else {
331
337
  if (i === "function")
332
338
  return y(() => {
333
- let l = t();
334
- for (; typeof l == "function"; ) l = l();
335
- n = Xe(e, l, n, r);
339
+ let o = t();
340
+ for (; typeof o == "function"; ) o = o();
341
+ n = et(e, o, n, r);
336
342
  }), () => n;
337
343
  if (Array.isArray(t)) {
338
- const l = [], C = n && Array.isArray(n);
339
- if (ut(l, t, n, s))
340
- return y(() => n = Xe(e, l, n, r, !0)), () => n;
341
- if (l.length === 0) {
342
- if (n = Ne(e, n, r), u) return n;
343
- } else C ? n.length === 0 ? mt(e, l, r) : sn(e, n, l) : (n && Ne(e), mt(e, l));
344
- n = l;
344
+ const o = [], C = n && Array.isArray(n);
345
+ if (ct(o, t, n, s))
346
+ return y(() => n = et(e, o, n, r, !0)), () => n;
347
+ if (o.length === 0) {
348
+ if (n = Me(e, n, r), u) return n;
349
+ } else C ? n.length === 0 ? Ct(e, o, r) : cn(e, n, o) : (n && Me(e), Ct(e, o));
350
+ n = o;
345
351
  } else if (t.nodeType) {
346
352
  if (Array.isArray(n)) {
347
- if (u) return n = Ne(e, n, r, t);
348
- Ne(e, n, null, t);
353
+ if (u) return n = Me(e, n, r, t);
354
+ Me(e, n, null, t);
349
355
  } else n == null || n === "" || !e.firstChild ? e.appendChild(t) : e.replaceChild(t, e.firstChild);
350
356
  n = t;
351
357
  }
352
358
  }
353
359
  return n;
354
360
  }
355
- function ut(e, t, n, r) {
361
+ function ct(e, t, n, r) {
356
362
  let s = !1;
357
363
  for (let i = 0, u = t.length; i < u; i++) {
358
- let l = t[i], C = n && n[e.length], $;
359
- if (!(l == null || l === !0 || l === !1)) if (($ = typeof l) == "object" && l.nodeType)
360
- e.push(l);
361
- else if (Array.isArray(l))
362
- s = ut(e, l, C) || s;
364
+ let o = t[i], C = n && n[e.length], $;
365
+ if (!(o == null || o === !0 || o === !1)) if (($ = typeof o) == "object" && o.nodeType)
366
+ e.push(o);
367
+ else if (Array.isArray(o))
368
+ s = ct(e, o, C) || s;
363
369
  else if ($ === "function")
364
370
  if (r) {
365
- for (; typeof l == "function"; ) l = l();
366
- s = ut(
371
+ for (; typeof o == "function"; ) o = o();
372
+ s = ct(
367
373
  e,
368
- Array.isArray(l) ? l : [l],
374
+ Array.isArray(o) ? o : [o],
369
375
  Array.isArray(C) ? C : [C]
370
376
  ) || s;
371
377
  } else
372
- e.push(l), s = !0;
378
+ e.push(o), s = !0;
373
379
  else {
374
- const D = String(l);
380
+ const D = String(o);
375
381
  C && C.nodeType === 3 && C.data === D ? e.push(C) : e.push(document.createTextNode(D));
376
382
  }
377
383
  }
378
384
  return s;
379
385
  }
380
- function mt(e, t, n = null) {
386
+ function Ct(e, t, n = null) {
381
387
  for (let r = 0, s = t.length; r < s; r++) e.insertBefore(t[r], n);
382
388
  }
383
- function Ne(e, t, n, r) {
389
+ function Me(e, t, n, r) {
384
390
  if (n === void 0) return e.textContent = "";
385
391
  const s = r || document.createTextNode("");
386
392
  if (t.length) {
387
393
  let i = !1;
388
394
  for (let u = t.length - 1; u >= 0; u--) {
389
- const l = t[u];
390
- if (s !== l) {
391
- const C = l.parentNode === e;
392
- !i && !u ? C ? e.replaceChild(s, l) : e.insertBefore(s, n) : C && l.remove();
395
+ const o = t[u];
396
+ if (s !== o) {
397
+ const C = o.parentNode === e;
398
+ !i && !u ? C ? e.replaceChild(s, o) : e.insertBefore(s, n) : C && o.remove();
393
399
  } else i = !0;
394
400
  }
395
401
  } else e.insertBefore(s, n);
396
402
  return [s];
397
403
  }
398
- function un(e) {
404
+ function fn(e) {
399
405
  return Object.keys(e).reduce((n, r) => {
400
406
  const s = e[r];
401
- return n[r] = Object.assign({}, s), Mt(s.value) && !fn(s.value) && !Array.isArray(s.value) && (n[r].value = Object.assign({}, s.value)), Array.isArray(s.value) && (n[r].value = s.value.slice(0)), n;
407
+ return n[r] = Object.assign({}, s), Lt(s.value) && !mn(s.value) && !Array.isArray(s.value) && (n[r].value = Object.assign({}, s.value)), Array.isArray(s.value) && (n[r].value = s.value.slice(0)), n;
402
408
  }, {});
403
409
  }
404
- function on(e) {
410
+ function hn(e) {
405
411
  return e ? Object.keys(e).reduce((n, r) => {
406
412
  const s = e[r];
407
- return n[r] = Mt(s) && "value" in s ? s : {
413
+ return n[r] = Lt(s) && "value" in s ? s : {
408
414
  value: s
409
- }, n[r].attribute || (n[r].attribute = dn(r)), n[r].parse = "parse" in n[r] ? n[r].parse : typeof n[r].value != "string", n;
415
+ }, n[r].attribute || (n[r].attribute = gn(r)), n[r].parse = "parse" in n[r] ? n[r].parse : typeof n[r].value != "string", n;
410
416
  }, {}) : {};
411
417
  }
412
- function ln(e) {
418
+ function pn(e) {
413
419
  return Object.keys(e).reduce((n, r) => (n[r] = e[r].value, n), {});
414
420
  }
415
- function cn(e, t) {
416
- const n = un(t);
421
+ function Dn(e, t) {
422
+ const n = fn(t);
417
423
  return Object.keys(t).forEach((s) => {
418
- const i = n[s], u = e.getAttribute(i.attribute), l = e[s];
419
- u != null && (i.value = i.parse ? Nt(u) : u), l != null && (i.value = Array.isArray(l) ? l.slice(0) : l), i.reflect && bt(e, i.attribute, i.value, !!i.parse), Object.defineProperty(e, s, {
424
+ const i = n[s], u = e.getAttribute(i.attribute), o = e[s];
425
+ u != null && (i.value = i.parse ? Rt(u) : u), o != null && (i.value = Array.isArray(o) ? o.slice(0) : o), i.reflect && wt(e, i.attribute, i.value, !!i.parse), Object.defineProperty(e, s, {
420
426
  get() {
421
427
  return i.value;
422
428
  },
423
429
  set(C) {
424
430
  const $ = i.value;
425
- i.value = C, i.reflect && bt(this, i.attribute, i.value, !!i.parse);
426
- for (let D = 0, B = this.__propertyChangedCallbacks.length; D < B; D++)
431
+ i.value = C, i.reflect && wt(this, i.attribute, i.value, !!i.parse);
432
+ for (let D = 0, k = this.__propertyChangedCallbacks.length; D < k; D++)
427
433
  this.__propertyChangedCallbacks[D](s, C, $);
428
434
  },
429
435
  enumerable: !0,
@@ -431,7 +437,7 @@ function cn(e, t) {
431
437
  });
432
438
  }), n;
433
439
  }
434
- function Nt(e) {
440
+ function Rt(e) {
435
441
  if (e)
436
442
  try {
437
443
  return JSON.parse(e);
@@ -439,25 +445,25 @@ function Nt(e) {
439
445
  return e;
440
446
  }
441
447
  }
442
- function bt(e, t, n, r) {
448
+ function wt(e, t, n, r) {
443
449
  if (n == null || n === !1) return e.removeAttribute(t);
444
450
  let s = r ? JSON.stringify(n) : n;
445
451
  e.__updating[t] = !0, s === "true" && (s = ""), e.setAttribute(t, s), Promise.resolve().then(() => delete e.__updating[t]);
446
452
  }
447
- function dn(e) {
453
+ function gn(e) {
448
454
  return e.replace(/\.?([A-Z]+)/g, (t, n) => "-" + n.toLowerCase()).replace("_", "-").replace(/^-/, "");
449
455
  }
450
- function Mt(e) {
456
+ function Lt(e) {
451
457
  return e != null && (typeof e == "object" || typeof e == "function");
452
458
  }
453
- function fn(e) {
459
+ function mn(e) {
454
460
  return Object.prototype.toString.call(e) === "[object Function]";
455
461
  }
456
- function hn(e) {
462
+ function bn(e) {
457
463
  return typeof e == "function" && e.toString().indexOf("class") === 0;
458
464
  }
459
- let st;
460
- function pn(e, t) {
465
+ let ut;
466
+ function vn(e, t) {
461
467
  const n = Object.keys(t);
462
468
  return class extends e {
463
469
  static get observedAttributes() {
@@ -468,16 +474,16 @@ function pn(e, t) {
468
474
  }
469
475
  connectedCallback() {
470
476
  if (this.__initialized) return;
471
- this.__releaseCallbacks = [], this.__propertyChangedCallbacks = [], this.__updating = {}, this.props = cn(this, t);
472
- const s = ln(this.props), i = this.Component, u = st;
477
+ this.__releaseCallbacks = [], this.__propertyChangedCallbacks = [], this.__updating = {}, this.props = Dn(this, t);
478
+ const s = pn(this.props), i = this.Component, u = ut;
473
479
  try {
474
- st = this, this.__initialized = !0, hn(i) ? new i(s, {
480
+ ut = this, this.__initialized = !0, bn(i) ? new i(s, {
475
481
  element: this
476
482
  }) : i(s, {
477
483
  element: this
478
484
  });
479
485
  } finally {
480
- st = u;
486
+ ut = u;
481
487
  }
482
488
  }
483
489
  async disconnectedCallback() {
@@ -490,7 +496,7 @@ function pn(e, t) {
490
496
  attributeChangedCallback(s, i, u) {
491
497
  if (this.__initialized && !this.__updating[s] && (s = this.lookupProp(s), s in t)) {
492
498
  if (u == null && !this[s]) return;
493
- this[s] = t[s].parse ? Nt(u) : u;
499
+ this[s] = t[s].parse ? Rt(u) : u;
494
500
  }
495
501
  }
496
502
  lookupProp(s) {
@@ -510,7 +516,7 @@ function pn(e, t) {
510
516
  }
511
517
  };
512
518
  }
513
- function Dn(e, t = {}, n = {}) {
519
+ function Cn(e, t = {}, n = {}) {
514
520
  const {
515
521
  BaseElement: r = HTMLElement,
516
522
  extension: s,
@@ -518,11 +524,11 @@ function Dn(e, t = {}, n = {}) {
518
524
  } = n;
519
525
  return (u) => {
520
526
  if (!e) throw new Error("tag is required to register a Component");
521
- let l = i.get(e);
522
- return l ? (l.prototype.Component = u, l) : (l = pn(r, on(t)), l.prototype.Component = u, l.prototype.registeredTag = e, i.define(e, l, s), l);
527
+ let o = i.get(e);
528
+ return o ? (o.prototype.Component = u, o) : (o = vn(r, hn(t)), o.prototype.Component = u, o.prototype.registeredTag = e, i.define(e, o, s), o);
523
529
  };
524
530
  }
525
- function gn(e) {
531
+ function wn(e) {
526
532
  const t = Object.keys(e), n = {};
527
533
  for (let r = 0; r < t.length; r++) {
528
534
  const [s, i] = w(e[t[r]]);
@@ -535,31 +541,31 @@ function gn(e) {
535
541
  }
536
542
  return n;
537
543
  }
538
- function mn(e) {
544
+ function An(e) {
539
545
  if (e.assignedSlot && e.assignedSlot._$owner) return e.assignedSlot._$owner;
540
546
  let t = e.parentNode;
541
547
  for (; t && !t._$owner && !(t.assignedSlot && t.assignedSlot._$owner); )
542
548
  t = t.parentNode;
543
549
  return t && t.assignedSlot ? t.assignedSlot._$owner : e._$owner;
544
550
  }
545
- function bn(e) {
551
+ function En(e) {
546
552
  return (t, n) => {
547
553
  const { element: r } = n;
548
- return Xt((s) => {
549
- const i = gn(t);
550
- r.addPropertyChangedCallback((l, C) => i[l] = C), r.addReleaseCallback(() => {
554
+ return tn((s) => {
555
+ const i = wn(t);
556
+ r.addPropertyChangedCallback((o, C) => i[o] = C), r.addReleaseCallback(() => {
551
557
  r.renderRoot.textContent = "", s();
552
558
  });
553
559
  const u = e(i, n);
554
560
  return f(r.renderRoot, u);
555
- }, mn(r));
561
+ }, An(r));
556
562
  };
557
563
  }
558
- function ht(e, t, n) {
559
- return arguments.length === 2 && (n = t, t = {}), Dn(e, t)(bn(n));
564
+ function gt(e, t, n) {
565
+ return arguments.length === 2 && (n = t, t = {}), Cn(e, t)(En(n));
560
566
  }
561
- var vn = "٠١٢٣٤٥٦٧٨٩", Cn = "۰۱۲۳۴۵۶۷۸۹", wn = "൦൧൨൩൪൫൬൭൮൯", An = "೦೧೨೩೪೫೬೭೮೯", En = "໐໑໒໓໔໕໖໗໘໙", Fn = "୦୧୨୩୪୫୬୭୮୯", yn = "០១២៣៤៥៦៧៨៩", $n = "߀߁߂߃߄߅߆߇߈߉", Bn = "੦੧੨੩੪੫੬੭੮੯", kn = "૦૧૨૩૪૫૬૭૮૯", xn = "०१२३४५६७८९", Sn = "၀၁၂၃၄၅၆၇၈၉", _n = "௦௧௨௩௪௫௬௭௮௯", Tn = "౦౧౨౩౪౫౬౭౮౯", On = "๐๑๒๓๔๕๖๗๘๙", In = "༠༡༢༣༤༥༦༧༨༩", vt = { ar: vn, fa: Cn, ml: wn, kn: An, lo: En, or: Fn, kh: yn, nqo: $n, pa: Bn, gu: kn, hi: xn, my: Sn, ta: _n, te: Tn, th: On, bo: In }, Pn = ["ru"], zn = ["id"], Nn = ["id"], Mn = ["ady-cyrl"], jn = ["aeb-arab"], Rn = ["sq"], Ln = ["ru"], qn = ["zh-hant"], Un = ["es"], Jn = ["hi"], Vn = ["es"], Kn = ["ar"], Gn = ["ar"], Hn = ["ar"], Wn = ["es"], Zn = ["fr"], Yn = ["ru"], Xn = ["fr", "es", "ru"], Qn = ["hi"], er = ["es"], tr = ["fa"], nr = ["ru"], rr = ["id"], sr = ["de"], ir = ["bbc-latn"], ar = ["fa"], ur = ["fa"], or = ["bho"], lr = ["en"], cr = ["id"], dr = ["fr"], fr = ["bn"], hr = ["fa"], pr = ["fr"], Dr = ["id"], gr = ["id"], mr = ["ru"], br = ["oc"], vr = ["nan", "zh-hant"], Cr = ["ru"], wr = ["it"], Ar = ["crh-latn"], Er = ["sk"], Fr = ["pl"], yr = ["ru"], $r = ["hsb", "de"], Br = ["ms"], kr = ["ne"], xr = ["it"], Sr = ["it"], _r = ["es"], Tr = ["fr"], Or = ["fi"], Ir = ["fr"], Pr = ["fr"], zr = ["de"], Nr = ["it"], Mr = ["tr"], jr = ["gan-hant", "zh-hant", "zh-hans"], Rr = ["fr"], Lr = ["pt"], qr = ["fa"], Ur = ["es"], Jr = ["gom-deva"], Vr = ["id"], Kr = ["de"], Gr = ["es"], Hr = ["zh-hant"], Wr = ["hif-latn"], Zr = ["de"], Yr = ["dsb", "de"], Xr = ["fr"], Qr = ["hy"], es = ["zh-cn", "zh-hans"], ts = ["ru"], ns = ["eo"], rs = ["ike-cans"], ss = ["en"], is = ["da"], as = ["id"], us = ["kk-latn", "kk-cyrl"], os = ["fr"], ls = ["kbd-cyrl"], cs = ["fr"], ds = ["ur"], fs = ["tr"], hs = ["my"], ps = ["kk-cyrl"], Ds = ["da"], gs = ["ru"], ms = ["ru"], bs = ["fi"], vs = ["ks-arab"], Cs = ["de"], ws = ["ku-latn"], As = ["ru"], Es = ["ru"], Fs = ["es"], ys = ["de"], $s = ["ru"], Bs = ["ru", "az"], ks = ["nl"], xs = ["it"], Ss = ["et"], _s = ["fa"], Ts = ["it", "rm", "fur"], Os = ["pms", "eml", "lij", "vec", "it"], Is = ["fr"], Ps = ["fa"], zs = ["lv"], Ns = ["fa"], Ms = ["zh-hant"], js = ["tr"], Rs = ["id"], Ls = ["hi"], qs = ["myv", "ru"], Us = ["fr"], Js = ["mrj", "ru"], Vs = ["id"], Ks = ["my"], Gs = ["ro"], Hs = ["mhr", "ru"], Ws = ["pt"], Zs = ["mdf", "ru"], Ys = ["fa"], Xs = ["es"], Qs = ["cdo", "zh-hant"], ei = ["it"], ti = ["nn"], ni = ["de"], ri = ["id"], si = ["nb"], ii = ["fr"], ai = ["ca", "fr"], ui = ["fi"], oi = ["ru"], li = ["fr"], ci = ["de"], di = ["de"], fi = ["de"], hi = ["en"], pi = ["it"], Di = ["el"], gi = ["pt-br"], mi = ["qug", "es"], bi = ["qu", "es"], vi = ["it"], Ci = ["ro"], wi = ["uk", "ru"], Ai = ["ro"], Ei = ["ruq-latn", "ro"], Fi = ["hi"], yi = ["ru"], $i = ["it"], Bi = ["en"], ki = ["it"], xi = ["cbk", "fa"], Si = ["fr"], _i = ["fr"], Ti = ["lt"], Oi = ["bs", "sr-el", "hr"], Ii = ["fr"], Pi = ["shy-latn"], zi = ["cs"], Ni = ["skr-arab"], Mi = ["de"], ji = ["fi"], Ri = ["sr-ec"], Li = ["nl"], qi = ["de"], Ui = ["ru"], Ji = ["id"], Vi = ["pl"], Ki = ["zh-tw", "zh-hant", "zh-hans"], Gi = ["zh-tw", "zh-hant", "zh-hans"], Hi = ["kn"], Wi = ["pt"], Zi = ["tg-cyrl"], Yi = ["zh-tw", "zh-hant", "zh-hans"], Xi = ["tt-cyrl", "ru"], Qi = ["fr"], ea = ["ru"], ta = ["ru"], na = ["ug-arab"], ra = ["it"], sa = ["et"], ia = ["nl"], aa = ["de"], ua = ["fi"], oa = ["et"], la = ["fr"], ca = ["fr"], da = ["zh-hans"], fa = ["ru"], ha = ["ka"], pa = ["he"], Da = ["zh-hans"], ga = ["nl"], ma = ["kab"], ba = ["zh-hans"], jt = { ab: Pn, abs: zn, ace: Nn, ady: Mn, aeb: jn, "aeb-arab": ["ar"], aln: Rn, alt: Ln, ami: qn, an: Un, anp: Jn, arn: Vn, arq: Kn, ary: Gn, arz: Hn, ast: Wn, atj: Zn, av: Yn, avk: Xn, awa: Qn, ay: er, azb: tr, ba: nr, ban: rr, "ban-bali": ["ban"], bar: sr, bbc: ir, "bbc-latn": ["id"], bcc: ar, "be-tarask": ["be"], bgn: ur, bh: or, bi: lr, bjn: cr, bm: dr, bpy: fr, bqi: hr, br: pr, btm: Dr, bug: gr, bxr: mr, ca: br, "cbk-zam": ["es"], cdo: vr, ce: Cr, co: wr, crh: Ar, "crh-cyrl": ["ru"], cs: Er, csb: Fr, cv: yr, "de-at": ["de"], "de-ch": ["de"], "de-formal": ["de"], dsb: $r, dtp: Br, dty: kr, egl: xr, eml: Sr, "en-ca": ["en"], "en-gb": ["en"], "es-419": ["es"], "es-formal": ["es"], ext: _r, ff: Tr, fit: Or, frc: Ir, frp: Pr, frr: zr, fur: Nr, gag: Mr, gan: jr, "gan-hans": ["zh-hans"], "gan-hant": ["zh-hant", "zh-hans"], gcr: Rr, gl: Lr, glk: qr, gn: Ur, gom: Jr, "gom-deva": ["hi"], gor: Vr, gsw: Kr, guc: Gr, hak: Hr, hif: Wr, hrx: Zr, hsb: Yr, ht: Xr, "hu-formal": ["hu"], hyw: Qr, ii: es, inh: ts, io: ns, iu: rs, jam: ss, jut: is, jv: as, kaa: us, kab: os, kbd: ls, kbp: cs, khw: ds, kiu: fs, kjp: hs, kk: ps, "kk-arab": ["kk-cyrl"], "kk-cn": ["kk-arab", "kk-cyrl"], "kk-kz": ["kk-cyrl"], "kk-latn": ["kk-cyrl"], "kk-tr": ["kk-latn", "kk-cyrl"], kl: Ds, "ko-kp": ["ko"], koi: gs, krc: ms, krl: bs, ks: vs, ksh: Cs, ku: ws, "ku-arab": ["ckb"], kum: As, kv: Es, lad: Fs, lb: ys, lbe: $s, lez: Bs, li: ks, lij: xs, liv: Ss, lki: _s, lld: Ts, lmo: Os, ln: Is, lrc: Ps, ltg: zs, luz: Ns, lzh: Ms, lzz: js, mad: Rs, mai: Ls, "map-bms": ["jv", "id"], mdf: qs, mg: Us, mhr: Js, min: Vs, mnw: Ks, mo: Gs, mrj: Hs, "ms-arab": ["ms"], mwl: Ws, myv: Zs, mzn: Ys, nah: Xs, nan: Qs, nap: ei, nb: ti, nds: ni, "nds-nl": ["nl"], nia: ri, "nl-informal": ["nl"], nn: si, nrm: ii, oc: ai, olo: ui, os: oi, pcd: li, pdc: ci, pdt: di, pfl: fi, pih: hi, pms: pi, pnt: Di, pt: gi, "pt-br": ["pt"], qu: mi, qug: bi, rgn: vi, rmy: Ci, "roa-tara": ["it"], rue: wi, rup: Ai, ruq: Ei, "ruq-cyrl": ["mk"], "ruq-latn": ["ro"], sa: Fi, sah: yi, scn: $i, sco: Bi, sdc: ki, sdh: xi, ses: Si, sg: _i, sgs: Ti, sh: Oi, shi: Ii, shy: Pi, "shy-latn": ["fr"], sk: zi, skr: Ni, "skr-arab": ["ur", "pnb"], sli: Mi, smn: ji, sr: Ri, srn: Li, stq: qi, sty: Ui, su: Ji, szl: Vi, szy: Ki, tay: Gi, tcy: Hi, tet: Wi, tg: Zi, trv: Yi, tt: Xi, "tt-cyrl": ["ru"], ty: Qi, tyv: ea, udm: ta, ug: na, vec: ra, vep: sa, vls: ia, vmf: aa, vot: ua, vro: oa, wa: la, wo: ca, wuu: da, xal: fa, xmf: ha, yi: pa, za: Da, zea: ga, zgh: ma, zh: ba, "zh-cn": ["zh-hans"], "zh-hant": ["zh-hans"], "zh-hk": ["zh-hant", "zh-hans"], "zh-mo": ["zh-hk", "zh-hant", "zh-hans"], "zh-my": ["zh-sg", "zh-hans"], "zh-sg": ["zh-hans"], "zh-tw": ["zh-hant", "zh-hans"] };
562
- let he = class {
567
+ var Fn = "٠١٢٣٤٥٦٧٨٩", yn = "۰۱۲۳۴۵۶۷۸۹", $n = "൦൧൨൩൪൫൬൭൮൯", kn = "೦೧೨೩೪೫೬೭೮೯", Bn = "໐໑໒໓໔໕໖໗໘໙", xn = "୦୧୨୩୪୫୬୭୮୯", Sn = "០១២៣៤៥៦៧៨៩", _n = "߀߁߂߃߄߅߆߇߈߉", Tn = "੦੧੨੩੪੫੬੭੮੯", On = "૦૧૨૩૪૫૬૭૮૯", In = "०१२३४५६७८९", Pn = "၀၁၂၃၄၅၆၇၈၉", zn = "௦௧௨௩௪௫௬௭௮௯", Nn = "౦౧౨౩౪౫౬౭౮౯", Mn = "๐๑๒๓๔๕๖๗๘๙", jn = "༠༡༢༣༤༥༦༧༨༩", At = { ar: Fn, fa: yn, ml: $n, kn, lo: Bn, or: xn, kh: Sn, nqo: _n, pa: Tn, gu: On, hi: In, my: Pn, ta: zn, te: Nn, th: Mn, bo: jn }, Rn = ["ru"], Ln = ["id"], qn = ["id"], Un = ["ady-cyrl"], Jn = ["aeb-arab"], Vn = ["sq"], Kn = ["ru"], Gn = ["zh-hant"], Hn = ["es"], Wn = ["hi"], Zn = ["es"], Yn = ["ar"], Xn = ["ar"], Qn = ["ar"], er = ["es"], tr = ["fr"], nr = ["ru"], rr = ["fr", "es", "ru"], sr = ["hi"], ir = ["es"], ar = ["fa"], ur = ["ru"], or = ["id"], lr = ["de"], cr = ["bbc-latn"], dr = ["fa"], fr = ["fa"], hr = ["bho"], pr = ["en"], Dr = ["id"], gr = ["fr"], mr = ["bn"], br = ["fa"], vr = ["fr"], Cr = ["id"], wr = ["id"], Ar = ["ru"], Er = ["oc"], Fr = ["nan", "zh-hant"], yr = ["ru"], $r = ["it"], kr = ["crh-latn"], Br = ["sk"], xr = ["pl"], Sr = ["ru"], _r = ["hsb", "de"], Tr = ["ms"], Or = ["ne"], Ir = ["it"], Pr = ["it"], zr = ["es"], Nr = ["fr"], Mr = ["fi"], jr = ["fr"], Rr = ["fr"], Lr = ["de"], qr = ["it"], Ur = ["tr"], Jr = ["gan-hant", "zh-hant", "zh-hans"], Vr = ["fr"], Kr = ["pt"], Gr = ["fa"], Hr = ["es"], Wr = ["gom-deva"], Zr = ["id"], Yr = ["de"], Xr = ["es"], Qr = ["zh-hant"], es = ["hif-latn"], ts = ["de"], ns = ["dsb", "de"], rs = ["fr"], ss = ["hy"], is = ["zh-cn", "zh-hans"], as = ["ru"], us = ["eo"], os = ["ike-cans"], ls = ["en"], cs = ["da"], ds = ["id"], fs = ["kk-latn", "kk-cyrl"], hs = ["fr"], ps = ["kbd-cyrl"], Ds = ["fr"], gs = ["ur"], ms = ["tr"], bs = ["my"], vs = ["kk-cyrl"], Cs = ["da"], ws = ["ru"], As = ["ru"], Es = ["fi"], Fs = ["ks-arab"], ys = ["de"], $s = ["ku-latn"], ks = ["ru"], Bs = ["ru"], xs = ["es"], Ss = ["de"], _s = ["ru"], Ts = ["ru", "az"], Os = ["nl"], Is = ["it"], Ps = ["et"], zs = ["fa"], Ns = ["it", "rm", "fur"], Ms = ["pms", "eml", "lij", "vec", "it"], js = ["fr"], Rs = ["fa"], Ls = ["lv"], qs = ["fa"], Us = ["zh-hant"], Js = ["tr"], Vs = ["id"], Ks = ["hi"], Gs = ["myv", "ru"], Hs = ["fr"], Ws = ["mrj", "ru"], Zs = ["id"], Ys = ["my"], Xs = ["ro"], Qs = ["mhr", "ru"], ei = ["pt"], ti = ["mdf", "ru"], ni = ["fa"], ri = ["es"], si = ["cdo", "zh-hant"], ii = ["it"], ai = ["nn"], ui = ["de"], oi = ["id"], li = ["nb"], ci = ["fr"], di = ["ca", "fr"], fi = ["fi"], hi = ["ru"], pi = ["fr"], Di = ["de"], gi = ["de"], mi = ["de"], bi = ["en"], vi = ["it"], Ci = ["el"], wi = ["pt-br"], Ai = ["qug", "es"], Ei = ["qu", "es"], Fi = ["it"], yi = ["ro"], $i = ["uk", "ru"], ki = ["ro"], Bi = ["ruq-latn", "ro"], xi = ["hi"], Si = ["ru"], _i = ["it"], Ti = ["en"], Oi = ["it"], Ii = ["cbk", "fa"], Pi = ["fr"], zi = ["fr"], Ni = ["lt"], Mi = ["bs", "sr-el", "hr"], ji = ["fr"], Ri = ["shy-latn"], Li = ["cs"], qi = ["skr-arab"], Ui = ["de"], Ji = ["fi"], Vi = ["sr-ec"], Ki = ["nl"], Gi = ["de"], Hi = ["ru"], Wi = ["id"], Zi = ["pl"], Yi = ["zh-tw", "zh-hant", "zh-hans"], Xi = ["zh-tw", "zh-hant", "zh-hans"], Qi = ["kn"], ea = ["pt"], ta = ["tg-cyrl"], na = ["zh-tw", "zh-hant", "zh-hans"], ra = ["tt-cyrl", "ru"], sa = ["fr"], ia = ["ru"], aa = ["ru"], ua = ["ug-arab"], oa = ["it"], la = ["et"], ca = ["nl"], da = ["de"], fa = ["fi"], ha = ["et"], pa = ["fr"], Da = ["fr"], ga = ["zh-hans"], ma = ["ru"], ba = ["ka"], va = ["he"], Ca = ["zh-hans"], wa = ["nl"], Aa = ["kab"], Ea = ["zh-hans"], qt = { ab: Rn, abs: Ln, ace: qn, ady: Un, aeb: Jn, "aeb-arab": ["ar"], aln: Vn, alt: Kn, ami: Gn, an: Hn, anp: Wn, arn: Zn, arq: Yn, ary: Xn, arz: Qn, ast: er, atj: tr, av: nr, avk: rr, awa: sr, ay: ir, azb: ar, ba: ur, ban: or, "ban-bali": ["ban"], bar: lr, bbc: cr, "bbc-latn": ["id"], bcc: dr, "be-tarask": ["be"], bgn: fr, bh: hr, bi: pr, bjn: Dr, bm: gr, bpy: mr, bqi: br, br: vr, btm: Cr, bug: wr, bxr: Ar, ca: Er, "cbk-zam": ["es"], cdo: Fr, ce: yr, co: $r, crh: kr, "crh-cyrl": ["ru"], cs: Br, csb: xr, cv: Sr, "de-at": ["de"], "de-ch": ["de"], "de-formal": ["de"], dsb: _r, dtp: Tr, dty: Or, egl: Ir, eml: Pr, "en-ca": ["en"], "en-gb": ["en"], "es-419": ["es"], "es-formal": ["es"], ext: zr, ff: Nr, fit: Mr, frc: jr, frp: Rr, frr: Lr, fur: qr, gag: Ur, gan: Jr, "gan-hans": ["zh-hans"], "gan-hant": ["zh-hant", "zh-hans"], gcr: Vr, gl: Kr, glk: Gr, gn: Hr, gom: Wr, "gom-deva": ["hi"], gor: Zr, gsw: Yr, guc: Xr, hak: Qr, hif: es, hrx: ts, hsb: ns, ht: rs, "hu-formal": ["hu"], hyw: ss, ii: is, inh: as, io: us, iu: os, jam: ls, jut: cs, jv: ds, kaa: fs, kab: hs, kbd: ps, kbp: Ds, khw: gs, kiu: ms, kjp: bs, kk: vs, "kk-arab": ["kk-cyrl"], "kk-cn": ["kk-arab", "kk-cyrl"], "kk-kz": ["kk-cyrl"], "kk-latn": ["kk-cyrl"], "kk-tr": ["kk-latn", "kk-cyrl"], kl: Cs, "ko-kp": ["ko"], koi: ws, krc: As, krl: Es, ks: Fs, ksh: ys, ku: $s, "ku-arab": ["ckb"], kum: ks, kv: Bs, lad: xs, lb: Ss, lbe: _s, lez: Ts, li: Os, lij: Is, liv: Ps, lki: zs, lld: Ns, lmo: Ms, ln: js, lrc: Rs, ltg: Ls, luz: qs, lzh: Us, lzz: Js, mad: Vs, mai: Ks, "map-bms": ["jv", "id"], mdf: Gs, mg: Hs, mhr: Ws, min: Zs, mnw: Ys, mo: Xs, mrj: Qs, "ms-arab": ["ms"], mwl: ei, myv: ti, mzn: ni, nah: ri, nan: si, nap: ii, nb: ai, nds: ui, "nds-nl": ["nl"], nia: oi, "nl-informal": ["nl"], nn: li, nrm: ci, oc: di, olo: fi, os: hi, pcd: pi, pdc: Di, pdt: gi, pfl: mi, pih: bi, pms: vi, pnt: Ci, pt: wi, "pt-br": ["pt"], qu: Ai, qug: Ei, rgn: Fi, rmy: yi, "roa-tara": ["it"], rue: $i, rup: ki, ruq: Bi, "ruq-cyrl": ["mk"], "ruq-latn": ["ro"], sa: xi, sah: Si, scn: _i, sco: Ti, sdc: Oi, sdh: Ii, ses: Pi, sg: zi, sgs: Ni, sh: Mi, shi: ji, shy: Ri, "shy-latn": ["fr"], sk: Li, skr: qi, "skr-arab": ["ur", "pnb"], sli: Ui, smn: Ji, sr: Vi, srn: Ki, stq: Gi, sty: Hi, su: Wi, szl: Zi, szy: Yi, tay: Xi, tcy: Qi, tet: ea, tg: ta, trv: na, tt: ra, "tt-cyrl": ["ru"], ty: sa, tyv: ia, udm: aa, ug: ua, vec: oa, vep: la, vls: ca, vmf: da, vot: fa, vro: ha, wa: pa, wo: Da, wuu: ga, xal: ma, xmf: ba, yi: va, za: Ca, zea: wa, zgh: Aa, zh: Ea, "zh-cn": ["zh-hans"], "zh-hant": ["zh-hans"], "zh-hk": ["zh-hant", "zh-hans"], "zh-mo": ["zh-hk", "zh-hant", "zh-hans"], "zh-my": ["zh-sg", "zh-hans"], "zh-sg": ["zh-hans"], "zh-tw": ["zh-hant", "zh-hans"] };
568
+ let De = class {
563
569
  constructor(e) {
564
570
  this.locale = e;
565
571
  }
@@ -594,7 +600,7 @@ let he = class {
594
600
  }
595
601
  if (Intl.NumberFormat) {
596
602
  let s;
597
- const i = [...jt[this.locale] || [], "en"];
603
+ const i = [...qt[this.locale] || [], "en"];
598
604
  return Intl.NumberFormat.supportedLocalesOf(this.locale).length ? s = [this.locale] : s = i, r = new Intl.NumberFormat(s).format(e), r === "NaN" && (r = e), r;
599
605
  }
600
606
  }
@@ -607,9 +613,9 @@ let he = class {
607
613
  return e === "male" ? t[0] : e === "female" ? t[1] : t.length === 3 ? t[2] : t[0];
608
614
  }
609
615
  digitTransformTable(e) {
610
- return vt[e] ? vt[e].split("") : !1;
616
+ return At[e] ? At[e].split("") : !1;
611
617
  }
612
- }, va = class extends he {
618
+ }, Fa = class extends De {
613
619
  convertGrammar(e, t) {
614
620
  switch (t) {
615
621
  case "prefixed":
@@ -618,7 +624,7 @@ let he = class {
618
624
  }
619
625
  return e;
620
626
  }
621
- }, Ca = class extends he {
627
+ }, ya = class extends De {
622
628
  convertGrammar(t, n) {
623
629
  switch (n) {
624
630
  case "instrumental":
@@ -630,7 +636,7 @@ let he = class {
630
636
  }
631
637
  return t;
632
638
  }
633
- }, wa = class extends he {
639
+ }, $a = class extends De {
634
640
  convertGrammar(e, t) {
635
641
  switch (t) {
636
642
  case "instrumental":
@@ -642,7 +648,7 @@ let he = class {
642
648
  }
643
649
  return e;
644
650
  }
645
- }, Aa = class extends he {
651
+ }, ka = class extends De {
646
652
  convertGrammar(e, t) {
647
653
  switch (t) {
648
654
  case "instrumental":
@@ -654,7 +660,7 @@ let he = class {
654
660
  }
655
661
  return e;
656
662
  }
657
- }, Ea = class extends he {
663
+ }, Ba = class extends De {
658
664
  convertGrammar(e, t) {
659
665
  let n = e.match(/[aou][^äöy]*$/i);
660
666
  const r = e;
@@ -680,12 +686,12 @@ let he = class {
680
686
  }
681
687
  return e;
682
688
  }
683
- }, Fa = class extends he {
689
+ }, xa = class extends De {
684
690
  convertGrammar(e, t) {
685
691
  return t === "genitive" && (e.slice(-1) === "ь" ? e = e.slice(0, -1) + "я" : e.slice(-2) === "ия" ? e = e.slice(0, -2) + "ии" : e.slice(-2) === "ка" ? e = e.slice(0, -2) + "ки" : e.slice(-2) === "ти" ? e = e.slice(0, -2) + "тей" : e.slice(-2) === "ды" ? e = e.slice(0, -2) + "дов" : e.slice(-3) === "ник" && (e = e.slice(0, -3) + "ника")), e;
686
692
  }
687
693
  };
688
- class ya extends he {
694
+ class Sa extends De {
689
695
  convertGrammar(t, n) {
690
696
  switch (n) {
691
697
  case "mestnik":
@@ -698,7 +704,7 @@ class ya extends he {
698
704
  return t;
699
705
  }
700
706
  }
701
- let $a = class extends he {
707
+ let _a = class extends De {
702
708
  convertGrammar(e, t) {
703
709
  switch (t) {
704
710
  case "genitive":
@@ -714,12 +720,12 @@ let $a = class extends he {
714
720
  return e;
715
721
  }
716
722
  };
717
- class Ba extends he {
723
+ class Ta extends De {
718
724
  convertGrammar(t, n) {
719
725
  return n === "genitive" && (t.slice(-1) === "ա" ? t = t.slice(0, -1) + "այի" : t.slice(-1) === "ո" ? t = t.slice(0, -1) + "ոյի" : t.slice(-4) === "գիրք" ? t = t.slice(0, -4) + "գրքի" : t = t + "ի"), t;
720
726
  }
721
727
  }
722
- let ka = class extends he {
728
+ let Oa = class extends De {
723
729
  convertGrammar(e, t) {
724
730
  if (t === "ainmlae") switch (e) {
725
731
  case "an Domhnach":
@@ -746,7 +752,7 @@ let ka = class extends he {
746
752
  }
747
753
  return e;
748
754
  }
749
- }, xa = class extends he {
755
+ }, Ia = class extends De {
750
756
  convertGrammar(e, t) {
751
757
  switch (t) {
752
758
  case "rol":
@@ -761,7 +767,7 @@ let ka = class extends he {
761
767
  }
762
768
  return e;
763
769
  }
764
- }, Sa = class extends he {
770
+ }, Pa = class extends De {
765
771
  convertGrammar(e, t) {
766
772
  let n, r, s, i;
767
773
  switch (n = "мæ", r = "", s = "", i = "", e.match(/тæ$/i) ? (e = e.slice(0, -1), n = "æм") : e.match(/[аæеёиоыэюя]$/i) ? r = "й" : e.match(/у$/i) ? e.slice(-2, -1).match(/[аæеёиоыэюя]$/i) || (r = "й") : e.match(/[бвгджзйклмнопрстфхцчшщьъ]$/i) || (s = "-"), t) {
@@ -790,7 +796,7 @@ let ka = class extends he {
790
796
  return e + i;
791
797
  }
792
798
  };
793
- class _a extends he {
799
+ class za extends De {
794
800
  convertGrammar(t, n) {
795
801
  switch (n) {
796
802
  case "genitive":
@@ -803,11 +809,11 @@ class _a extends he {
803
809
  return t;
804
810
  }
805
811
  }
806
- var Ct = { bs: Ca, default: he, dsb: wa, fi: Ea, ga: ka, he: va, hsb: Aa, hu: xa, hy: Ba, la: $a, os: Sa, ru: Fa, sl: ya, uk: _a };
807
- const Ta = new RegExp("(?:([A-Za-zªµºÀ-ÖØ-öø-ʸʻ-ˁːˑˠ-ˤˮͰ-ͳͶͷͺ-ͽͿΆΈ-ΊΌΎ-ΡΣ-ϵϷ-҂Ҋ-ԯԱ-Ֆՙ-՟ա-և։ः-हऻऽ-ीॉ-ौॎ-ॐक़-ॡ।-ঀংঃঅ-ঌএঐও-নপ-রলশ-হঽ-ীেৈোৌৎৗড়ঢ়য়-ৡ০-ৱ৴-৺ਃਅ-ਊਏਐਓ-ਨਪ-ਰਲਲ਼ਵਸ਼ਸਹਾ-ੀਖ਼-ੜਫ਼੦-੯ੲ-ੴઃઅ-ઍએ-ઑઓ-નપ-રલળવ-હઽ-ીૉોૌૐૠૡ૦-૰ૹଂଃଅ-ଌଏଐଓ-ନପ-ରଲଳଵ-ହଽାୀେୈୋୌୗଡ଼ଢ଼ୟ-ୡ୦-୷ஃஅ-ஊஎ-ஐஒ-கஙசஜஞடணதந-பம-ஹாிுூெ-ைொ-ௌௐௗ௦-௲ఁ-ఃఅ-ఌఎ-ఐఒ-నప-హఽు-ౄౘ-ౚౠౡ౦-౯౿ಂಃಅ-ಌಎ-ಐಒ-ನಪ-ಳವ-ಹಽ-ೄೆ-ೈೊೋೕೖೞೠೡ೦-೯ೱೲംഃഅ-ഌഎ-ഐഒ-ഺഽ-ീെ-ൈൊ-ൌൎൗൟ-ൡ൦-൵൹-ൿංඃඅ-ඖක-නඳ-රලව-ෆා-ෑෘ-ෟ෦-෯ෲ-෴ก-ะาำเ-ๆ๏-๛ກຂຄງຈຊຍດ-ທນ-ຟມ-ຣລວສຫອ-ະາຳຽເ-ໄໆ໐-໙ໜ-ໟༀ-༗༚-༴༶༸༾-ཇཉ-ཬཿ྅ྈ-ྌ྾-࿅࿇-࿌࿎-࿚က-ာေးျြဿ-ၗၚ-ၝၡ-ၰၵ-ႁႃႄႇ-ႌႎ-ႜ႞-ჅჇჍა-ቈቊ-ቍቐ-ቖቘቚ-ቝበ-ኈኊ-ኍነ-ኰኲ-ኵኸ-ኾዀዂ-ዅወ-ዖዘ-ጐጒ-ጕጘ-ፚ፠-፼ᎀ-ᎏᎠ-Ᏽᏸ-ᏽᐁ-ᙿᚁ-ᚚᚠ-ᛸᜀ-ᜌᜎ-ᜑᜠ-ᜱ᜵᜶ᝀ-ᝑᝠ-ᝬᝮ-ᝰក-ឳាើ-ៅះៈ។-៚ៜ០-៩᠐-᠙ᠠ-ᡷᢀ-ᢨᢪᢰ-ᣵᤀ-ᤞᤣ-ᤦᤩ-ᤫᤰᤱᤳ-ᤸ᥆-ᥭᥰ-ᥴᦀ-ᦫᦰ-ᧉ᧐-᧚ᨀ-ᨖᨙᨚ᨞-ᩕᩗᩡᩣᩤᩭ-ᩲ᪀-᪉᪐-᪙᪠-᪭ᬄ-ᬳᬵᬻᬽ-ᭁᭃ-ᭋ᭐-᭪᭴-᭼ᮂ-ᮡᮦᮧ᮪ᮮ-ᯥᯧᯪ-ᯬᯮ᯲᯳᯼-ᰫᰴᰵ᰻-᱉ᱍ-᱿᳀-᳇᳓᳡ᳩ-ᳬᳮ-ᳳᳵᳶᴀ-ᶿḀ-ἕἘ-Ἕἠ-ὅὈ-Ὅὐ-ὗὙὛὝὟ-ώᾀ-ᾴᾶ-ᾼιῂ-ῄῆ-ῌῐ-ΐῖ-Ίῠ-Ῥῲ-ῴῶ-ῼ‎ⁱⁿₐ-ₜℂℇℊ-ℓℕℙ-ℝℤΩℨK-ℭℯ-ℹℼ-ℿⅅ-ⅉⅎ⅏Ⅰ-ↈ⌶-⍺⎕⒜-ⓩ⚬⠀-⣿Ⰰ-Ⱞⰰ-ⱞⱠ-ⳤⳫ-ⳮⳲⳳⴀ-ⴥⴧⴭⴰ-ⵧⵯ⵰ⶀ-ⶖⶠ-ⶦⶨ-ⶮⶰ-ⶶⶸ-ⶾⷀ-ⷆⷈ-ⷎⷐ-ⷖⷘ-ⷞ々-〇〡-〩〮〯〱-〵〸-〼ぁ-ゖゝ-ゟァ-ヺー-ヿㄅ-ㄭㄱ-ㆎ㆐-ㆺㇰ-㈜㈠-㉏㉠-㉻㉿-㊰㋀-㋋㋐-㋾㌀-㍶㍻-㏝㏠-㏾㐀-䶵一-鿕ꀀ-ꒌꓐ-ꘌꘐ-ꘫꙀ-ꙮꚀ-ꚝꚠ-ꛯ꛲-꛷Ꜣ-ꞇ꞉-ꞭꞰ-ꞷꟷ-ꠁꠃ-ꠅꠇ-ꠊꠌ-ꠤꠧ꠰-꠷ꡀ-ꡳꢀ-ꣃ꣎-꣙ꣲ-ꣽ꤀-ꤥ꤮-ꥆꥒ꥓꥟-ꥼꦃ-ꦲꦴꦵꦺꦻꦽ-꧍ꧏ-꧙꧞-ꧤꧦ-ꧾꨀ-ꨨꨯꨰꨳꨴꩀ-ꩂꩄ-ꩋꩍ꩐-꩙꩜-ꩻꩽ-ꪯꪱꪵꪶꪹ-ꪽꫀꫂꫛ-ꫫꫮ-ꫵꬁ-ꬆꬉ-ꬎꬑ-ꬖꬠ-ꬦꬨ-ꬮꬰ-ꭥꭰ-ꯤꯦꯧꯩ-꯬꯰-꯹가-힣ힰ-ퟆퟋ-ퟻ-舘並-龎ff-stﬓ-ﬗA-Za-zヲ-하-ᅦᅧ-ᅬᅭ-ᅲᅳ-ᅵ]|\uD800[\uDC00-\uDC0B]|\uD800[\uDC0D-\uDC26]|\uD800[\uDC28-\uDC3A]|𐀼|𐀽|\uD800[\uDC3F-\uDC4D]|\uD800[\uDC50-\uDC5D]|\uD800[\uDC80-\uDCFA]|𐄀|𐄂|\uD800[\uDD07-\uDD33]|\uD800[\uDD37-\uDD3F]|\uD800[\uDDD0-\uDDFC]|\uD800[\uDE80-\uDE9C]|\uD800[\uDEA0-\uDED0]|\uD800[\uDF00-\uDF23]|\uD800[\uDF30-\uDF4A]|\uD800[\uDF50-\uDF75]|\uD800[\uDF80-\uDF9D]|\uD800[\uDF9F-\uDFC3]|\uD800[\uDFC8-\uDFD5]|\uD801[\uDC00-\uDC9D]|\uD801[\uDCA0-\uDCA9]|\uD801[\uDD00-\uDD27]|\uD801[\uDD30-\uDD63]|𐕯|\uD801[\uDE00-\uDF36]|\uD801[\uDF40-\uDF55]|\uD801[\uDF60-\uDF67]|𑀀|\uD804[\uDC02-\uDC37]|\uD804[\uDC47-\uDC4D]|\uD804[\uDC66-\uDC6F]|\uD804[\uDC82-\uDCB2]|𑂷|𑂸|\uD804[\uDCBB-\uDCC1]|\uD804[\uDCD0-\uDCE8]|\uD804[\uDCF0-\uDCF9]|\uD804[\uDD03-\uDD26]|𑄬|\uD804[\uDD36-\uDD43]|\uD804[\uDD50-\uDD72]|\uD804[\uDD74-\uDD76]|\uD804[\uDD82-\uDDB5]|\uD804[\uDDBF-\uDDC9]|𑇍|\uD804[\uDDD0-\uDDDF]|\uD804[\uDDE1-\uDDF4]|\uD804[\uDE00-\uDE11]|\uD804[\uDE13-\uDE2E]|𑈲|𑈳|𑈵|\uD804[\uDE38-\uDE3D]|\uD804[\uDE80-\uDE86]|𑊈|\uD804[\uDE8A-\uDE8D]|\uD804[\uDE8F-\uDE9D]|\uD804[\uDE9F-\uDEA9]|\uD804[\uDEB0-\uDEDE]|\uD804[\uDEE0-\uDEE2]|\uD804[\uDEF0-\uDEF9]|𑌂|𑌃|\uD804[\uDF05-\uDF0C]|𑌏|𑌐|\uD804[\uDF13-\uDF28]|\uD804[\uDF2A-\uDF30]|𑌲|𑌳|\uD804[\uDF35-\uDF39]|\uD804[\uDF3D-\uDF3F]|\uD804[\uDF41-\uDF44]|𑍇|𑍈|\uD804[\uDF4B-\uDF4D]|𑍐|𑍗|\uD804[\uDF5D-\uDF63]|\uD805[\uDC80-\uDCB2]|𑒹|\uD805[\uDCBB-\uDCBE]|𑓁|\uD805[\uDCC4-\uDCC7]|\uD805[\uDCD0-\uDCD9]|\uD805[\uDD80-\uDDB1]|\uD805[\uDDB8-\uDDBB]|𑖾|\uD805[\uDDC1-\uDDDB]|\uD805[\uDE00-\uDE32]|𑘻|𑘼|𑘾|\uD805[\uDE41-\uDE44]|\uD805[\uDE50-\uDE59]|\uD805[\uDE80-\uDEAA]|𑚬|𑚮|𑚯|𑚶|\uD805[\uDEC0-\uDEC9]|\uD805[\uDF00-\uDF19]|𑜠|𑜡|𑜦|\uD805[\uDF30-\uDF3F]|\uD806[\uDCA0-\uDCF2]|𑣿|\uD806[\uDEC0-\uDEF8]|\uD808[\uDC00-\uDF99]|\uD809[\uDC00-\uDC6E]|\uD809[\uDC70-\uDC74]|\uD809[\uDC80-\uDD43]|\uD80C[\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38]|\uD81A[\uDE40-\uDE5E]|\uD81A[\uDE60-\uDE69]|𖩮|𖩯|\uD81A[\uDED0-\uDEED]|𖫵|\uD81A[\uDF00-\uDF2F]|\uD81A[\uDF37-\uDF45]|\uD81A[\uDF50-\uDF59]|\uD81A[\uDF5B-\uDF61]|\uD81A[\uDF63-\uDF77]|\uD81A[\uDF7D-\uDF8F]|\uD81B[\uDF00-\uDF44]|\uD81B[\uDF50-\uDF7E]|\uD81B[\uDF93-\uDF9F]|𛀀|𛀁|\uD82F[\uDC00-\uDC6A]|\uD82F[\uDC70-\uDC7C]|\uD82F[\uDC80-\uDC88]|\uD82F[\uDC90-\uDC99]|𛲜|𛲟|\uD834[\uDC00-\uDCF5]|\uD834[\uDD00-\uDD26]|\uD834[\uDD29-\uDD66]|\uD834[\uDD6A-\uDD72]|𝆃|𝆄|\uD834[\uDD8C-\uDDA9]|\uD834[\uDDAE-\uDDE8]|\uD834[\uDF60-\uDF71]|\uD835[\uDC00-\uDC54]|\uD835[\uDC56-\uDC9C]|𝒞|𝒟|𝒢|𝒥|𝒦|\uD835[\uDCA9-\uDCAC]|\uD835[\uDCAE-\uDCB9]|𝒻|\uD835[\uDCBD-\uDCC3]|\uD835[\uDCC5-\uDD05]|\uD835[\uDD07-\uDD0A]|\uD835[\uDD0D-\uDD14]|\uD835[\uDD16-\uDD1C]|\uD835[\uDD1E-\uDD39]|\uD835[\uDD3B-\uDD3E]|\uD835[\uDD40-\uDD44]|𝕆|\uD835[\uDD4A-\uDD50]|\uD835[\uDD52-\uDEA5]|\uD835[\uDEA8-\uDEDA]|\uD835[\uDEDC-\uDF14]|\uD835[\uDF16-\uDF4E]|\uD835[\uDF50-\uDF88]|\uD835[\uDF8A-\uDFC2]|\uD835[\uDFC4-\uDFCB]|\uD836[\uDC00-\uDDFF]|\uD836[\uDE37-\uDE3A]|\uD836[\uDE6D-\uDE74]|\uD836[\uDE76-\uDE83]|\uD836[\uDE85-\uDE8B]|\uD83C[\uDD10-\uDD2E]|\uD83C[\uDD30-\uDD69]|\uD83C[\uDD70-\uDD9A]|\uD83C[\uDDE6-\uDE02]|\uD83C[\uDE10-\uDE3A]|\uD83C[\uDE40-\uDE48]|🉐|🉑|[\uD840-\uD868][\uDC00-\uDFFF]|\uD869[\uDC00-\uDED6]|\uD869[\uDF00-\uDFFF]|[\uD86A-\uD86C][\uDC00-\uDFFF]|\uD86D[\uDC00-\uDF34]|\uD86D[\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D]|\uD86E[\uDC20-\uDFFF]|[\uD86F-\uD872][\uDC00-\uDFFF]|\uD873[\uDC00-\uDEA1]|\uD87E[\uDC00-\uDE1D]|[\uDB80-\uDBBE][\uDC00-\uDFFF]|\uDBBF[\uDC00-\uDFFD]|[\uDBC0-\uDBFE][\uDC00-\uDFFF]|\uDBFF[\uDC00-\uDFFD])|([֐־׀׃׆׈-׿߀-ߪߴߵߺ-ࠕࠚࠤࠨ࠮-ࡘ࡜-࢟‏יִײַ-ﬨשׁ-ﭏ؈؋؍؛-ي٭-ٯٱ-ەۥۦۮۯۺ-ܐܒ-ܯ݋-ޥޱ-޿ࢠ-࣢ﭐ-ﴽ﵀-﷏ﷰ-﷼﷾﷿ﹰ-﻾]|\uD802[\uDC00-\uDD1E]|\uD802[\uDD20-\uDE00]|𐨄|\uD802[\uDE07-\uDE0B]|\uD802[\uDE10-\uDE37]|\uD802[\uDE3B-\uDE3E]|\uD802[\uDE40-\uDEE4]|\uD802[\uDEE7-\uDF38]|\uD802[\uDF40-\uDFFF]|\uD803[\uDC00-\uDE5F]|\uD803[\uDE7F-\uDFFF]|\uD83A[\uDC00-\uDCCF]|\uD83A[\uDCD7-\uDFFF]|\uD83B[\uDC00-\uDDFF]|\uD83B[\uDF00-\uDFFF]|\uD83B[\uDF00-\uDFFF]|\uD83B[\uDF00-\uDFFF]|\uD83B[\uDF00-\uDFFF]|\uD83B[\uDF00-\uDFFF]|\uD83B[\uDF00-\uDFFF]|\uD83B[\uDF00-\uDFFF]|\uD83B[\uDF00-\uDFFF]|\uD83B[\uDF00-\uDFFF]|\uD83B[\uDF00-\uDFFF]|\uD83B[\uDF00-\uDFFF]|\uD83B[\uDF00-\uDFFF]|\uD83B[\uDF00-\uDFFF]|\uD83B[\uDE00-\uDEEF]|\uD83B[\uDEF2-\uDEFF]))");
808
- let Rt = class {
812
+ var Et = { bs: ya, default: De, dsb: $a, fi: Ba, ga: Oa, he: Fa, hsb: ka, hu: Ia, hy: Ta, la: _a, os: Pa, ru: xa, sl: Sa, uk: za };
813
+ const Na = new RegExp("(?:([A-Za-zªµºÀ-ÖØ-öø-ʸʻ-ˁːˑˠ-ˤˮͰ-ͳͶͷͺ-ͽͿΆΈ-ΊΌΎ-ΡΣ-ϵϷ-҂Ҋ-ԯԱ-Ֆՙ-՟ա-և։ः-हऻऽ-ीॉ-ौॎ-ॐक़-ॡ।-ঀংঃঅ-ঌএঐও-নপ-রলশ-হঽ-ীেৈোৌৎৗড়ঢ়য়-ৡ০-ৱ৴-৺ਃਅ-ਊਏਐਓ-ਨਪ-ਰਲਲ਼ਵਸ਼ਸਹਾ-ੀਖ਼-ੜਫ਼੦-੯ੲ-ੴઃઅ-ઍએ-ઑઓ-નપ-રલળવ-હઽ-ીૉોૌૐૠૡ૦-૰ૹଂଃଅ-ଌଏଐଓ-ନପ-ରଲଳଵ-ହଽାୀେୈୋୌୗଡ଼ଢ଼ୟ-ୡ୦-୷ஃஅ-ஊஎ-ஐஒ-கஙசஜஞடணதந-பம-ஹாிுூெ-ைொ-ௌௐௗ௦-௲ఁ-ఃఅ-ఌఎ-ఐఒ-నప-హఽు-ౄౘ-ౚౠౡ౦-౯౿ಂಃಅ-ಌಎ-ಐಒ-ನಪ-ಳವ-ಹಽ-ೄೆ-ೈೊೋೕೖೞೠೡ೦-೯ೱೲംഃഅ-ഌഎ-ഐഒ-ഺഽ-ീെ-ൈൊ-ൌൎൗൟ-ൡ൦-൵൹-ൿංඃඅ-ඖක-නඳ-රලව-ෆා-ෑෘ-ෟ෦-෯ෲ-෴ก-ะาำเ-ๆ๏-๛ກຂຄງຈຊຍດ-ທນ-ຟມ-ຣລວສຫອ-ະາຳຽເ-ໄໆ໐-໙ໜ-ໟༀ-༗༚-༴༶༸༾-ཇཉ-ཬཿ྅ྈ-ྌ྾-࿅࿇-࿌࿎-࿚က-ာေးျြဿ-ၗၚ-ၝၡ-ၰၵ-ႁႃႄႇ-ႌႎ-ႜ႞-ჅჇჍა-ቈቊ-ቍቐ-ቖቘቚ-ቝበ-ኈኊ-ኍነ-ኰኲ-ኵኸ-ኾዀዂ-ዅወ-ዖዘ-ጐጒ-ጕጘ-ፚ፠-፼ᎀ-ᎏᎠ-Ᏽᏸ-ᏽᐁ-ᙿᚁ-ᚚᚠ-ᛸᜀ-ᜌᜎ-ᜑᜠ-ᜱ᜵᜶ᝀ-ᝑᝠ-ᝬᝮ-ᝰក-ឳាើ-ៅះៈ។-៚ៜ០-៩᠐-᠙ᠠ-ᡷᢀ-ᢨᢪᢰ-ᣵᤀ-ᤞᤣ-ᤦᤩ-ᤫᤰᤱᤳ-ᤸ᥆-ᥭᥰ-ᥴᦀ-ᦫᦰ-ᧉ᧐-᧚ᨀ-ᨖᨙᨚ᨞-ᩕᩗᩡᩣᩤᩭ-ᩲ᪀-᪉᪐-᪙᪠-᪭ᬄ-ᬳᬵᬻᬽ-ᭁᭃ-ᭋ᭐-᭪᭴-᭼ᮂ-ᮡᮦᮧ᮪ᮮ-ᯥᯧᯪ-ᯬᯮ᯲᯳᯼-ᰫᰴᰵ᰻-᱉ᱍ-᱿᳀-᳇᳓᳡ᳩ-ᳬᳮ-ᳳᳵᳶᴀ-ᶿḀ-ἕἘ-Ἕἠ-ὅὈ-Ὅὐ-ὗὙὛὝὟ-ώᾀ-ᾴᾶ-ᾼιῂ-ῄῆ-ῌῐ-ΐῖ-Ίῠ-Ῥῲ-ῴῶ-ῼ‎ⁱⁿₐ-ₜℂℇℊ-ℓℕℙ-ℝℤΩℨK-ℭℯ-ℹℼ-ℿⅅ-ⅉⅎ⅏Ⅰ-ↈ⌶-⍺⎕⒜-ⓩ⚬⠀-⣿Ⰰ-Ⱞⰰ-ⱞⱠ-ⳤⳫ-ⳮⳲⳳⴀ-ⴥⴧⴭⴰ-ⵧⵯ⵰ⶀ-ⶖⶠ-ⶦⶨ-ⶮⶰ-ⶶⶸ-ⶾⷀ-ⷆⷈ-ⷎⷐ-ⷖⷘ-ⷞ々-〇〡-〩〮〯〱-〵〸-〼ぁ-ゖゝ-ゟァ-ヺー-ヿㄅ-ㄭㄱ-ㆎ㆐-ㆺㇰ-㈜㈠-㉏㉠-㉻㉿-㊰㋀-㋋㋐-㋾㌀-㍶㍻-㏝㏠-㏾㐀-䶵一-鿕ꀀ-ꒌꓐ-ꘌꘐ-ꘫꙀ-ꙮꚀ-ꚝꚠ-ꛯ꛲-꛷Ꜣ-ꞇ꞉-ꞭꞰ-ꞷꟷ-ꠁꠃ-ꠅꠇ-ꠊꠌ-ꠤꠧ꠰-꠷ꡀ-ꡳꢀ-ꣃ꣎-꣙ꣲ-ꣽ꤀-ꤥ꤮-ꥆꥒ꥓꥟-ꥼꦃ-ꦲꦴꦵꦺꦻꦽ-꧍ꧏ-꧙꧞-ꧤꧦ-ꧾꨀ-ꨨꨯꨰꨳꨴꩀ-ꩂꩄ-ꩋꩍ꩐-꩙꩜-ꩻꩽ-ꪯꪱꪵꪶꪹ-ꪽꫀꫂꫛ-ꫫꫮ-ꫵꬁ-ꬆꬉ-ꬎꬑ-ꬖꬠ-ꬦꬨ-ꬮꬰ-ꭥꭰ-ꯤꯦꯧꯩ-꯬꯰-꯹가-힣ힰ-ퟆퟋ-ퟻ-舘並-龎ff-stﬓ-ﬗA-Za-zヲ-하-ᅦᅧ-ᅬᅭ-ᅲᅳ-ᅵ]|\uD800[\uDC00-\uDC0B]|\uD800[\uDC0D-\uDC26]|\uD800[\uDC28-\uDC3A]|𐀼|𐀽|\uD800[\uDC3F-\uDC4D]|\uD800[\uDC50-\uDC5D]|\uD800[\uDC80-\uDCFA]|𐄀|𐄂|\uD800[\uDD07-\uDD33]|\uD800[\uDD37-\uDD3F]|\uD800[\uDDD0-\uDDFC]|\uD800[\uDE80-\uDE9C]|\uD800[\uDEA0-\uDED0]|\uD800[\uDF00-\uDF23]|\uD800[\uDF30-\uDF4A]|\uD800[\uDF50-\uDF75]|\uD800[\uDF80-\uDF9D]|\uD800[\uDF9F-\uDFC3]|\uD800[\uDFC8-\uDFD5]|\uD801[\uDC00-\uDC9D]|\uD801[\uDCA0-\uDCA9]|\uD801[\uDD00-\uDD27]|\uD801[\uDD30-\uDD63]|𐕯|\uD801[\uDE00-\uDF36]|\uD801[\uDF40-\uDF55]|\uD801[\uDF60-\uDF67]|𑀀|\uD804[\uDC02-\uDC37]|\uD804[\uDC47-\uDC4D]|\uD804[\uDC66-\uDC6F]|\uD804[\uDC82-\uDCB2]|𑂷|𑂸|\uD804[\uDCBB-\uDCC1]|\uD804[\uDCD0-\uDCE8]|\uD804[\uDCF0-\uDCF9]|\uD804[\uDD03-\uDD26]|𑄬|\uD804[\uDD36-\uDD43]|\uD804[\uDD50-\uDD72]|\uD804[\uDD74-\uDD76]|\uD804[\uDD82-\uDDB5]|\uD804[\uDDBF-\uDDC9]|𑇍|\uD804[\uDDD0-\uDDDF]|\uD804[\uDDE1-\uDDF4]|\uD804[\uDE00-\uDE11]|\uD804[\uDE13-\uDE2E]|𑈲|𑈳|𑈵|\uD804[\uDE38-\uDE3D]|\uD804[\uDE80-\uDE86]|𑊈|\uD804[\uDE8A-\uDE8D]|\uD804[\uDE8F-\uDE9D]|\uD804[\uDE9F-\uDEA9]|\uD804[\uDEB0-\uDEDE]|\uD804[\uDEE0-\uDEE2]|\uD804[\uDEF0-\uDEF9]|𑌂|𑌃|\uD804[\uDF05-\uDF0C]|𑌏|𑌐|\uD804[\uDF13-\uDF28]|\uD804[\uDF2A-\uDF30]|𑌲|𑌳|\uD804[\uDF35-\uDF39]|\uD804[\uDF3D-\uDF3F]|\uD804[\uDF41-\uDF44]|𑍇|𑍈|\uD804[\uDF4B-\uDF4D]|𑍐|𑍗|\uD804[\uDF5D-\uDF63]|\uD805[\uDC80-\uDCB2]|𑒹|\uD805[\uDCBB-\uDCBE]|𑓁|\uD805[\uDCC4-\uDCC7]|\uD805[\uDCD0-\uDCD9]|\uD805[\uDD80-\uDDB1]|\uD805[\uDDB8-\uDDBB]|𑖾|\uD805[\uDDC1-\uDDDB]|\uD805[\uDE00-\uDE32]|𑘻|𑘼|𑘾|\uD805[\uDE41-\uDE44]|\uD805[\uDE50-\uDE59]|\uD805[\uDE80-\uDEAA]|𑚬|𑚮|𑚯|𑚶|\uD805[\uDEC0-\uDEC9]|\uD805[\uDF00-\uDF19]|𑜠|𑜡|𑜦|\uD805[\uDF30-\uDF3F]|\uD806[\uDCA0-\uDCF2]|𑣿|\uD806[\uDEC0-\uDEF8]|\uD808[\uDC00-\uDF99]|\uD809[\uDC00-\uDC6E]|\uD809[\uDC70-\uDC74]|\uD809[\uDC80-\uDD43]|\uD80C[\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38]|\uD81A[\uDE40-\uDE5E]|\uD81A[\uDE60-\uDE69]|𖩮|𖩯|\uD81A[\uDED0-\uDEED]|𖫵|\uD81A[\uDF00-\uDF2F]|\uD81A[\uDF37-\uDF45]|\uD81A[\uDF50-\uDF59]|\uD81A[\uDF5B-\uDF61]|\uD81A[\uDF63-\uDF77]|\uD81A[\uDF7D-\uDF8F]|\uD81B[\uDF00-\uDF44]|\uD81B[\uDF50-\uDF7E]|\uD81B[\uDF93-\uDF9F]|𛀀|𛀁|\uD82F[\uDC00-\uDC6A]|\uD82F[\uDC70-\uDC7C]|\uD82F[\uDC80-\uDC88]|\uD82F[\uDC90-\uDC99]|𛲜|𛲟|\uD834[\uDC00-\uDCF5]|\uD834[\uDD00-\uDD26]|\uD834[\uDD29-\uDD66]|\uD834[\uDD6A-\uDD72]|𝆃|𝆄|\uD834[\uDD8C-\uDDA9]|\uD834[\uDDAE-\uDDE8]|\uD834[\uDF60-\uDF71]|\uD835[\uDC00-\uDC54]|\uD835[\uDC56-\uDC9C]|𝒞|𝒟|𝒢|𝒥|𝒦|\uD835[\uDCA9-\uDCAC]|\uD835[\uDCAE-\uDCB9]|𝒻|\uD835[\uDCBD-\uDCC3]|\uD835[\uDCC5-\uDD05]|\uD835[\uDD07-\uDD0A]|\uD835[\uDD0D-\uDD14]|\uD835[\uDD16-\uDD1C]|\uD835[\uDD1E-\uDD39]|\uD835[\uDD3B-\uDD3E]|\uD835[\uDD40-\uDD44]|𝕆|\uD835[\uDD4A-\uDD50]|\uD835[\uDD52-\uDEA5]|\uD835[\uDEA8-\uDEDA]|\uD835[\uDEDC-\uDF14]|\uD835[\uDF16-\uDF4E]|\uD835[\uDF50-\uDF88]|\uD835[\uDF8A-\uDFC2]|\uD835[\uDFC4-\uDFCB]|\uD836[\uDC00-\uDDFF]|\uD836[\uDE37-\uDE3A]|\uD836[\uDE6D-\uDE74]|\uD836[\uDE76-\uDE83]|\uD836[\uDE85-\uDE8B]|\uD83C[\uDD10-\uDD2E]|\uD83C[\uDD30-\uDD69]|\uD83C[\uDD70-\uDD9A]|\uD83C[\uDDE6-\uDE02]|\uD83C[\uDE10-\uDE3A]|\uD83C[\uDE40-\uDE48]|🉐|🉑|[\uD840-\uD868][\uDC00-\uDFFF]|\uD869[\uDC00-\uDED6]|\uD869[\uDF00-\uDFFF]|[\uD86A-\uD86C][\uDC00-\uDFFF]|\uD86D[\uDC00-\uDF34]|\uD86D[\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D]|\uD86E[\uDC20-\uDFFF]|[\uD86F-\uD872][\uDC00-\uDFFF]|\uD873[\uDC00-\uDEA1]|\uD87E[\uDC00-\uDE1D]|[\uDB80-\uDBBE][\uDC00-\uDFFF]|\uDBBF[\uDC00-\uDFFD]|[\uDBC0-\uDBFE][\uDC00-\uDFFF]|\uDBFF[\uDC00-\uDFFD])|([֐־׀׃׆׈-׿߀-ߪߴߵߺ-ࠕࠚࠤࠨ࠮-ࡘ࡜-࢟‏יִײַ-ﬨשׁ-ﭏ؈؋؍؛-ي٭-ٯٱ-ەۥۦۮۯۺ-ܐܒ-ܯ݋-ޥޱ-޿ࢠ-࣢ﭐ-ﴽ﵀-﷏ﷰ-﷼﷾﷿ﹰ-﻾]|\uD802[\uDC00-\uDD1E]|\uD802[\uDD20-\uDE00]|𐨄|\uD802[\uDE07-\uDE0B]|\uD802[\uDE10-\uDE37]|\uD802[\uDE3B-\uDE3E]|\uD802[\uDE40-\uDEE4]|\uD802[\uDEE7-\uDF38]|\uD802[\uDF40-\uDFFF]|\uD803[\uDC00-\uDE5F]|\uD803[\uDE7F-\uDFFF]|\uD83A[\uDC00-\uDCCF]|\uD83A[\uDCD7-\uDFFF]|\uD83B[\uDC00-\uDDFF]|\uD83B[\uDF00-\uDFFF]|\uD83B[\uDF00-\uDFFF]|\uD83B[\uDF00-\uDFFF]|\uD83B[\uDF00-\uDFFF]|\uD83B[\uDF00-\uDFFF]|\uD83B[\uDF00-\uDFFF]|\uD83B[\uDF00-\uDFFF]|\uD83B[\uDF00-\uDFFF]|\uD83B[\uDF00-\uDFFF]|\uD83B[\uDF00-\uDFFF]|\uD83B[\uDF00-\uDFFF]|\uD83B[\uDF00-\uDFFF]|\uD83B[\uDF00-\uDFFF]|\uD83B[\uDE00-\uDEEF]|\uD83B[\uDEF2-\uDEFF]))");
814
+ let Ut = class {
809
815
  constructor(e) {
810
- this.locale = Me(e), this.language = new (Ct[this.locale] || Ct.default)(this.locale);
816
+ this.locale = je(e), this.language = new (Et[this.locale] || Et.default)(this.locale);
811
817
  }
812
818
  emit(e, t) {
813
819
  let n, r, s;
@@ -861,7 +867,7 @@ let Rt = class {
861
867
  return `<a href="${e[0]}">${e[1]}</a>`;
862
868
  }
863
869
  bidi(e) {
864
- const t = Oa(e[0]);
870
+ const t = Ma(e[0]);
865
871
  return t === "ltr" ? "‪" + e[0] + "‬" : t === "rtl" ? "‫" + e[0] + "‬" : e[0];
866
872
  }
867
873
  formatnum(e) {
@@ -882,194 +888,194 @@ let Rt = class {
882
888
  return `<${t}${s}>${i}</${t}>`;
883
889
  }
884
890
  };
885
- function Me(e) {
891
+ function je(e) {
886
892
  return typeof e == "string" ? e.toLowerCase() : e;
887
893
  }
888
- function Oa(e) {
889
- const t = e.match(Ta);
894
+ function Ma(e) {
895
+ const t = e.match(Na);
890
896
  return t ? t[2] === void 0 ? "ltr" : "rtl" : null;
891
897
  }
892
- function Ia(e, { wikilinks: t = !1 } = {}) {
898
+ function ja(e, { wikilinks: t = !1 } = {}) {
893
899
  let n = 0;
894
900
  function r(c) {
895
901
  return () => {
896
902
  for (let m = 0; m < c.length; m++) {
897
- const O = c[m]();
898
- if (O !== null) return O;
903
+ const T = c[m]();
904
+ if (T !== null) return T;
899
905
  }
900
906
  return null;
901
907
  };
902
908
  }
903
909
  function s(c) {
904
- const m = n, O = [];
905
- for (let x = 0; x < c.length; x++) {
906
- const ee = c[x]();
907
- if (ee === null) return n = m, null;
908
- O.push(ee);
910
+ const m = n, T = [];
911
+ for (let S = 0; S < c.length; S++) {
912
+ const te = c[S]();
913
+ if (te === null) return n = m, null;
914
+ T.push(te);
909
915
  }
910
- return O;
916
+ return T;
911
917
  }
912
918
  function i(c, m) {
913
919
  return () => {
914
- const O = n, x = [];
915
- let ee = m();
916
- for (; ee !== null; ) x.push(ee), ee = m();
917
- return x.length < c ? (n = O, null) : x;
920
+ const T = n, S = [];
921
+ let te = m();
922
+ for (; te !== null; ) S.push(te), te = m();
923
+ return S.length < c ? (n = T, null) : S;
918
924
  };
919
925
  }
920
926
  function u(c) {
921
927
  const m = c.length;
922
928
  return () => {
923
- let O = null;
924
- return e.slice(n, n + m) === c && (O = c, n += m), O;
929
+ let T = null;
930
+ return e.slice(n, n + m) === c && (T = c, n += m), T;
925
931
  };
926
932
  }
927
- function l(c) {
933
+ function o(c) {
928
934
  return () => {
929
935
  const m = e.slice(n).match(c);
930
936
  return m === null ? null : (n += m[0].length, m[0]);
931
937
  };
932
938
  }
933
- const C = l(/^\s+/), $ = u("|"), D = u(":"), B = u("\\"), ae = l(/^./), de = u("$"), Ee = l(/^\d+/), L = u('"'), W = u("'"), Z = l(t ? /^[^{}[\]$<\\]/ : /^[^{}$<\\]/), ue = l(t ? /^[^{}[\]$\\|]/ : /^[^{}$\\|]/), G = l(t ? /^[^{}[\]$\s]/ : /^[^{}$\s]/);
934
- function te(c, m) {
939
+ const C = o(/^\s+/), $ = u("|"), D = u(":"), k = u("\\"), ue = o(/^./), fe = u("$"), Fe = o(/^\d+/), R = u('"'), Z = u("'"), Y = o(t ? /^[^{}[\]$<\\]/ : /^[^{}$<\\]/), oe = o(t ? /^[^{}[\]$\\|]/ : /^[^{}$\\|]/), H = o(t ? /^[^{}[\]$\s]/ : /^[^{}$\s]/);
940
+ function ne(c, m) {
935
941
  return () => {
936
- const O = c();
937
- return O === null ? null : m(O);
942
+ const T = c();
943
+ return T === null ? null : m(T);
938
944
  };
939
945
  }
940
- function J() {
941
- const c = i(1, X)();
946
+ function V() {
947
+ const c = i(1, ee)();
942
948
  return c === null ? null : c.join("");
943
949
  }
944
- function we() {
945
- const c = i(1, ye)();
950
+ function Ae() {
951
+ const c = i(1, $e)();
946
952
  return c === null ? null : c.join("");
947
953
  }
948
- const Fe = r([k, G]);
949
- function Ae() {
950
- const c = i(1, Fe)();
954
+ const ye = r([B, H]);
955
+ function Ee() {
956
+ const c = i(1, ye)();
951
957
  return c === null ? null : c.join("");
952
958
  }
953
- function k() {
954
- const c = s([B, ae]);
959
+ function B() {
960
+ const c = s([k, ue]);
955
961
  return c === null ? null : c[1];
956
962
  }
957
- const X = r([k, ue]), ye = r([k, Z]);
958
- function pe() {
959
- const c = s([de, Ee]);
963
+ const ee = r([B, oe]), $e = r([B, Y]);
964
+ function he() {
965
+ const c = s([fe, Fe]);
960
966
  return c === null ? null : ["REPLACE", parseInt(c[1], 10) - 1];
961
967
  }
962
- const De = te(l(/^[ !"$&'()*,./0-9;=?@A-Z^_`a-z~\x80-\xFF+-]+/), function(c) {
968
+ const ge = ne(o(/^[ !"$&'()*,./0-9;=?@A-Z^_`a-z~\x80-\xFF+-]+/), function(c) {
963
969
  return c.toString();
964
970
  });
965
971
  function b() {
966
- const c = s([$, i(0, H)]);
972
+ const c = s([$, i(0, K)]);
967
973
  if (c === null) return null;
968
974
  const m = c[1];
969
975
  return m.length > 1 ? ["CONCAT"].concat(m) : m[0];
970
976
  }
971
- function ge() {
972
- const c = s([De, D, pe]);
977
+ function me() {
978
+ const c = s([ge, D, he]);
973
979
  return c === null ? null : [c[0], c[2]];
974
980
  }
975
- function Re() {
976
- const c = s([De, D, H]);
981
+ function Le() {
982
+ const c = s([ge, D, K]);
977
983
  return c === null ? null : [c[0], c[2]];
978
984
  }
979
- function me() {
980
- const c = s([De, D]);
985
+ function be() {
986
+ const c = s([ge, D]);
981
987
  return c === null ? null : [c[0], ""];
982
988
  }
983
- const Pe = r([function() {
984
- const c = s([r([ge, Re, me]), i(0, b)]);
989
+ const ze = r([function() {
990
+ const c = s([r([me, Le, be]), i(0, b)]);
985
991
  return c === null ? null : c[0].concat(c[1]);
986
992
  }, function() {
987
- const c = s([De, i(0, b)]);
993
+ const c = s([ge, i(0, b)]);
988
994
  return c === null ? null : [c[0]].concat(c[1]);
989
- }]), Le = u("{{"), qe = u("}}"), Te = u("[["), Oe = u("]]"), Ie = u("["), ze = u("]");
990
- function ve() {
991
- const c = s([Le, Pe, qe]);
995
+ }]), qe = u("{{"), Ue = u("}}"), Oe = u("[["), Ie = u("]]"), Pe = u("["), Ne = u("]");
996
+ function Ce() {
997
+ const c = s([qe, ze, Ue]);
992
998
  return c === null ? null : c[1];
993
999
  }
994
1000
  function xe() {
995
- const c = s([i(1, H), $, i(1, q)]);
1001
+ const c = s([i(1, K), $, i(1, U)]);
996
1002
  return c === null ? null : [["CONCAT"].concat(c[0]), ["CONCAT"].concat(c[2])];
997
1003
  }
998
1004
  function Se() {
999
- const c = s([i(1, H)]);
1005
+ const c = s([i(1, K)]);
1000
1006
  return c === null ? null : [["CONCAT"].concat(c[0])];
1001
1007
  }
1002
1008
  const A = r([xe, Se]);
1003
1009
  function v() {
1004
1010
  let c = null;
1005
- const m = s([Te, A, Oe]);
1011
+ const m = s([Oe, A, Ie]);
1006
1012
  if (m !== null) {
1007
- const O = m[1];
1008
- c = ["WIKILINK"].concat(O);
1013
+ const T = m[1];
1014
+ c = ["WIKILINK"].concat(T);
1009
1015
  }
1010
1016
  return c;
1011
1017
  }
1012
- function S() {
1018
+ function x() {
1013
1019
  let c = null;
1014
- const m = s([Ie, i(1, V), C, i(1, q), ze]);
1020
+ const m = s([Pe, i(1, N), C, i(1, U), Ne]);
1015
1021
  return m !== null && (c = ["EXTLINK", m[1].length === 1 ? m[1][0] : ["CONCAT"].concat(m[1]), ["CONCAT"].concat(m[3])]), c;
1016
1022
  }
1017
- const R = l(/^[A-Za-z]+/);
1018
- function d(c, m, O, x = { allowedHtmlElements: ["b", "bdi", "del", "i", "ins", "u", "font", "big", "small", "sub", "sup", "h1", "h2", "h3", "h4", "h5", "h6", "cite", "code", "em", "s", "strike", "strong", "tt", "var", "div", "center", "blockquote", "ol", "ul", "dl", "table", "caption", "pre", "ruby", "rb", "rp", "rt", "rtc", "p", "span", "abbr", "dfn", "kbd", "samp", "data", "time", "mark", "li", "dt", "dd"], allowedHtmlCommonAttributes: ["id", "class", "style", "lang", "dir", "title", "aria-describedby", "aria-flowto", "aria-hidden", "aria-label", "aria-labelledby", "aria-owns", "role", "about", "property", "resource", "datatype", "typeof", "itemid", "itemprop", "itemref", "itemscope", "itemtype"], allowedHtmlAttributesByElement: {} }) {
1019
- if (c = c.toLowerCase(), m = m.toLowerCase(), c !== m || x.allowedHtmlElements.indexOf(c) === -1) return !1;
1020
- const ee = /[\000-\010\013\016-\037\177]|expression|filter\s*:|accelerator\s*:|-o-link\s*:|-o-link-source\s*:|-o-replace\s*:|url\s*\(|image\s*\(|image-set\s*\(/i;
1021
- for (let re = 0, se = O.length; re < se; re += 2) {
1022
- const fe = O[re];
1023
- if (x.allowedHtmlCommonAttributes.indexOf(fe) === -1 && (x.allowedHtmlAttributesByElement[c] || []).indexOf(fe) === -1 || fe === "style" && O[re + 1].search(ee) !== -1) return !1;
1023
+ const j = o(/^[A-Za-z]+/);
1024
+ function d(c, m, T, S = { allowedHtmlElements: ["b", "bdi", "del", "i", "ins", "u", "font", "big", "small", "sub", "sup", "h1", "h2", "h3", "h4", "h5", "h6", "cite", "code", "em", "s", "strike", "strong", "tt", "var", "div", "center", "blockquote", "ol", "ul", "dl", "table", "caption", "pre", "ruby", "rb", "rp", "rt", "rtc", "p", "span", "abbr", "dfn", "kbd", "samp", "data", "time", "mark", "li", "dt", "dd"], allowedHtmlCommonAttributes: ["id", "class", "style", "lang", "dir", "title", "aria-describedby", "aria-flowto", "aria-hidden", "aria-label", "aria-labelledby", "aria-owns", "role", "about", "property", "resource", "datatype", "typeof", "itemid", "itemprop", "itemref", "itemscope", "itemtype"], allowedHtmlAttributesByElement: {} }) {
1025
+ if (c = c.toLowerCase(), m = m.toLowerCase(), c !== m || S.allowedHtmlElements.indexOf(c) === -1) return !1;
1026
+ const te = /[\000-\010\013\016-\037\177]|expression|filter\s*:|accelerator\s*:|-o-link\s*:|-o-link-source\s*:|-o-replace\s*:|url\s*\(|image\s*\(|image-set\s*\(/i;
1027
+ for (let re = 0, se = T.length; re < se; re += 2) {
1028
+ const ce = T[re];
1029
+ if (S.allowedHtmlCommonAttributes.indexOf(ce) === -1 && (S.allowedHtmlAttributesByElement[c] || []).indexOf(ce) === -1 || ce === "style" && T[re + 1].search(te) !== -1) return !1;
1024
1030
  }
1025
1031
  return !0;
1026
1032
  }
1027
1033
  function _() {
1028
- const c = l(/^[^"]*/), m = s([L, c, L]);
1034
+ const c = o(/^[^"]*/), m = s([R, c, R]);
1029
1035
  return m === null ? null : m[1];
1030
1036
  }
1031
- function z() {
1032
- const c = l(/^[^']*/), m = s([W, c, W]);
1037
+ function I() {
1038
+ const c = o(/^[^']*/), m = s([Z, c, Z]);
1033
1039
  return m === null ? null : m[1];
1034
1040
  }
1035
- function P() {
1036
- const c = l(/^\s*=\s*/), m = s([C, R, c, r([_, z])]);
1041
+ function z() {
1042
+ const c = o(/^\s*=\s*/), m = s([C, j, c, r([_, I])]);
1037
1043
  return m === null ? null : [m[1], m[3]];
1038
1044
  }
1039
- function T() {
1040
- const c = i(0, P)();
1045
+ function L() {
1046
+ const c = i(0, z)();
1041
1047
  return Array.prototype.concat.apply(["HTMLATTRIBUTES"], c);
1042
1048
  }
1043
- function Q() {
1049
+ function q() {
1044
1050
  let c = null;
1045
- const m = n, O = u("<"), x = l(/^\/?/), ee = l(/^\s*>/), re = s([O, R, T, x, ee]);
1051
+ const m = n, T = u("<"), S = o(/^\/?/), te = o(/^\s*>/), re = s([T, j, L, S, te]);
1046
1052
  if (re === null) return null;
1047
- const se = n, fe = re[1], $e = i(0, q)(), nt = n, o = u("</"), g = s([o, R, ee]);
1048
- if (g === null) return ["CONCAT", e.slice(m, se)].concat($e);
1049
- const E = n, oe = g[1], Be = re[2], M = Be.slice(1);
1050
- if (d(fe, oe, M)) c = ["HTMLELEMENT", fe, Be].concat($e);
1053
+ const se = n, ce = re[1], ke = i(0, U)(), st = n, it = u("</"), Ge = s([it, j, te]);
1054
+ if (Ge === null) return ["CONCAT", e.slice(m, se)].concat(ke);
1055
+ const l = n, g = Ge[1], E = re[2], ie = E.slice(1);
1056
+ if (d(ce, g, ie)) c = ["HTMLELEMENT", ce, E].concat(ke);
1051
1057
  else {
1052
- const a = (h) => h.replace(/&/g, "&amp;").replace(/</g, "&lt;").replace(/>/g, "&gt;").replace(/"/g, "&quot;").replace(/'/g, "&#039;");
1053
- c = ["CONCAT", a(e.slice(m, se))].concat($e, a(e.slice(nt, E)));
1058
+ const _e = (pe) => pe.replace(/&/g, "&amp;").replace(/</g, "&lt;").replace(/>/g, "&gt;").replace(/"/g, "&quot;").replace(/'/g, "&#039;");
1059
+ c = ["CONCAT", _e(e.slice(m, se))].concat(ke, _e(e.slice(st, l)));
1054
1060
  }
1055
1061
  return c;
1056
1062
  }
1057
- const V = r([ve, pe, v, S, Ae]), q = r([ve, pe, v, S, Q, we]), H = r([ve, pe, J]);
1058
- function ne() {
1059
- const c = i(0, q)();
1063
+ const N = r([Ce, he, v, x, Ee]), U = r([Ce, he, v, x, q, Ae]), K = r([Ce, he, V]);
1064
+ function le() {
1065
+ const c = i(0, U)();
1060
1066
  return c === null ? null : ["CONCAT"].concat(c);
1061
1067
  }
1062
- const U = ne();
1063
- if (U === null || n !== e.length) throw new Error("Parse error at position " + n.toString() + " in input: " + e);
1064
- return U;
1068
+ const J = le();
1069
+ if (J === null || n !== e.length) throw new Error("Parse error at position " + n.toString() + " in input: " + e);
1070
+ return J;
1065
1071
  }
1066
- class wt {
1072
+ class Ft {
1067
1073
  constructor(t, { wikilinks: n = !1 } = {}) {
1068
- this.locale = Me(t), this.wikilinks = n, this.emitter = new Rt(this.locale);
1074
+ this.locale = je(t), this.wikilinks = n, this.emitter = new Ut(this.locale);
1069
1075
  }
1070
1076
  parse(t, n) {
1071
1077
  if (t.includes("{{") || t.includes("<") || this.wikilinks && t.includes("[")) {
1072
- const r = Ia(t, { wikilinks: this.wikilinks });
1078
+ const r = ja(t, { wikilinks: this.wikilinks });
1073
1079
  return this.emitter.emit(r, n);
1074
1080
  } else return this.simpleParse(t, n);
1075
1081
  }
@@ -1080,13 +1086,13 @@ class wt {
1080
1086
  });
1081
1087
  }
1082
1088
  }
1083
- class Pa {
1089
+ class Ra {
1084
1090
  constructor() {
1085
1091
  this.sourceMap = /* @__PURE__ */ new Map();
1086
1092
  }
1087
1093
  load(t, n) {
1088
1094
  if (typeof t != "object") throw new Error("Invalid message source. Must be an object");
1089
- if (n = Me(n), n) {
1095
+ if (n = je(n), n) {
1090
1096
  if (!/^[a-zA-Z0-9-]+$/.test(n)) throw new Error(`Invalid locale ${n}`);
1091
1097
  for (const r in t) if (r.indexOf("@") !== 0) {
1092
1098
  if (typeof t[r] == "object") return this.load(t);
@@ -1097,16 +1103,16 @@ class Pa {
1097
1103
  } else for (n in t) this.load(t[n], n);
1098
1104
  }
1099
1105
  getMessage(t, n) {
1100
- const r = this.sourceMap.get(Me(n));
1106
+ const r = this.sourceMap.get(je(n));
1101
1107
  return r ? r[t] : null;
1102
1108
  }
1103
1109
  hasLocale(t) {
1104
1110
  return this.sourceMap.has(t);
1105
1111
  }
1106
1112
  }
1107
- class za {
1113
+ class La {
1108
1114
  constructor(t, { finalFallback: n = "en", messages: r = void 0, wikilinks: s = !1 } = {}) {
1109
- this.locale = Me(t), this.parser = new wt(this.locale, { wikilinks: s }), this.messageStore = new Pa(), r && this.load(r, this.locale), this.finalFallback = n, this.wikilinks = s;
1115
+ this.locale = je(t), this.parser = new Ft(this.locale, { wikilinks: s }), this.messageStore = new Ra(), r && this.load(r, this.locale), this.finalFallback = n, this.wikilinks = s;
1110
1116
  }
1111
1117
  load(t, n) {
1112
1118
  return this.messageStore.load(t, n || this.locale);
@@ -1115,10 +1121,10 @@ class za {
1115
1121
  return this.parser.parse(this.getMessage(t), n);
1116
1122
  }
1117
1123
  setLocale(t) {
1118
- this.locale = Me(t), this.parser = new wt(this.locale, { wikilinks: this.wikilinks });
1124
+ this.locale = je(t), this.parser = new Ft(this.locale, { wikilinks: this.wikilinks });
1119
1125
  }
1120
1126
  getFallbackLocales() {
1121
- return [...jt[this.locale] || [], this.finalFallback];
1127
+ return [...qt[this.locale] || [], this.finalFallback];
1122
1128
  }
1123
1129
  getMessage(t) {
1124
1130
  let n = this.locale, r = 0;
@@ -1127,7 +1133,7 @@ class za {
1127
1133
  const i = n.split("-");
1128
1134
  let u = i.length;
1129
1135
  do {
1130
- const l = i.slice(0, u).join("-"), C = this.messageStore.getMessage(t, l);
1136
+ const o = i.slice(0, u).join("-"), C = this.messageStore.getMessage(t, o);
1131
1137
  if (typeof C == "string") return C;
1132
1138
  u--;
1133
1139
  } while (u);
@@ -1136,10 +1142,10 @@ class za {
1136
1142
  return t;
1137
1143
  }
1138
1144
  registerParserPlugin(t, n) {
1139
- Rt.prototype[t] = n;
1145
+ Ut.prototype[t] = n;
1140
1146
  }
1141
1147
  }
1142
- const Lt = {
1148
+ const Jt = {
1143
1149
  "@metadata": { authors: ["Mason Payne"], "last-updated": "2024-01-08", locale: "en" },
1144
1150
  "sa-login": "Login",
1145
1151
  "sa-username": "Email",
@@ -1225,7 +1231,7 @@ const Lt = {
1225
1231
  "sa-signup-webauthn-setup": "Set Up Passkey",
1226
1232
  "sa-signup-webauthn-done": "Skip for now",
1227
1233
  "sa-signup-webauthn-error": "Error setting up passkey. Please try again from your account settings."
1228
- }, Na = {
1234
+ }, qa = {
1229
1235
  "@metadata": { authors: ["Mason Payne"], "last-updated": "2022-05-28", locale: "fr" },
1230
1236
  "sa-login": "Connexion",
1231
1237
  "sa-username": "Adresse e-mail",
@@ -1278,7 +1284,7 @@ const Lt = {
1278
1284
  "sa-signup-webauthn-setup": "Configurer la clé d'accès",
1279
1285
  "sa-signup-webauthn-done": "Ignorer pour l'instant",
1280
1286
  "sa-signup-webauthn-error": "Erreur lors de la configuration de la clé d'accès. Veuillez réessayer depuis les paramètres de votre compte."
1281
- }, Ma = {
1287
+ }, Ua = {
1282
1288
  "@metadata": { authors: ["Mason Payne"], "last-updated": "2022-05-28", locale: "es" },
1283
1289
  "sa-login": "Acceso",
1284
1290
  "sa-username": "Correo electrónico",
@@ -1329,7 +1335,7 @@ const Lt = {
1329
1335
  "sa-signup-webauthn-setup": "Configurar clave de acceso",
1330
1336
  "sa-signup-webauthn-done": "Omitir por ahora",
1331
1337
  "sa-signup-webauthn-error": "Error al configurar la clave de acceso. Intenta de nuevo desde la configuración de tu cuenta."
1332
- }, ja = {
1338
+ }, Ja = {
1333
1339
  "@metadata": { authors: ["Mason Payne"], "last-updated": "2022-05-28", locale: "ja" },
1334
1340
  "sa-login": "ログイン",
1335
1341
  "sa-username": "メールアドレス",
@@ -1382,25 +1388,25 @@ const Lt = {
1382
1388
  "sa-signup-webauthn-setup": "パスキーを設定",
1383
1389
  "sa-signup-webauthn-done": "今はスキップ",
1384
1390
  "sa-signup-webauthn-error": "パスキーの設定中にエラーが発生しました。アカウント設定から再試行してください。"
1385
- }, Ra = {
1386
- en: Lt,
1387
- fr: Na,
1388
- es: Ma,
1389
- ja
1391
+ }, Va = {
1392
+ en: Jt,
1393
+ fr: qa,
1394
+ es: Ua,
1395
+ ja: Ja
1390
1396
  };
1391
- function pt(e) {
1392
- const t = new za("en", {
1393
- messages: Lt
1397
+ function mt(e) {
1398
+ const t = new La("en", {
1399
+ messages: Jt
1394
1400
  });
1395
- return e !== "en" && (t.load(Ra[e], e), t.setLocale(e)), t;
1401
+ return e !== "en" && (t.load(Va[e], e), t.setLocale(e)), t;
1396
1402
  }
1397
- function qt(e) {
1403
+ function Vt(e) {
1398
1404
  const t = "==".slice(0, (4 - e.length % 4) % 4), n = e.replace(/-/g, "+").replace(/_/g, "/") + t, r = atob(n), s = new ArrayBuffer(r.length), i = new Uint8Array(s);
1399
1405
  for (let u = 0; u < r.length; u++)
1400
1406
  i[u] = r.charCodeAt(u);
1401
1407
  return s;
1402
1408
  }
1403
- function Ut(e) {
1409
+ function Kt(e) {
1404
1410
  const t = new Uint8Array(e);
1405
1411
  let n = "";
1406
1412
  for (const i of t)
@@ -1410,14 +1416,14 @@ function Ut(e) {
1410
1416
  "_"
1411
1417
  ).replace(/=/g, "");
1412
1418
  }
1413
- var I = "copy", be = "convert";
1414
- function je(e, t, n) {
1415
- if (t === I)
1419
+ var O = "copy", ve = "convert";
1420
+ function Re(e, t, n) {
1421
+ if (t === O)
1416
1422
  return n;
1417
- if (t === be)
1423
+ if (t === ve)
1418
1424
  return e(n);
1419
1425
  if (t instanceof Array)
1420
- return n.map((r) => je(e, t[0], r));
1426
+ return n.map((r) => Re(e, t[0], r));
1421
1427
  if (t instanceof Object) {
1422
1428
  const r = {};
1423
1429
  for (const [s, i] of Object.entries(t)) {
@@ -1434,7 +1440,7 @@ function je(e, t, n) {
1434
1440
  r[s] = null;
1435
1441
  continue;
1436
1442
  }
1437
- r[s] = je(
1443
+ r[s] = Re(
1438
1444
  e,
1439
1445
  i.schema,
1440
1446
  n[s]
@@ -1443,144 +1449,144 @@ function je(e, t, n) {
1443
1449
  return r;
1444
1450
  }
1445
1451
  }
1446
- function ot(e, t) {
1452
+ function dt(e, t) {
1447
1453
  return {
1448
1454
  required: !0,
1449
1455
  schema: e,
1450
1456
  derive: t
1451
1457
  };
1452
1458
  }
1453
- function j(e) {
1459
+ function M(e) {
1454
1460
  return {
1455
1461
  required: !0,
1456
1462
  schema: e
1457
1463
  };
1458
1464
  }
1459
- function K(e) {
1465
+ function G(e) {
1460
1466
  return {
1461
1467
  required: !1,
1462
1468
  schema: e
1463
1469
  };
1464
1470
  }
1465
- var Jt = {
1466
- type: j(I),
1467
- id: j(be),
1468
- transports: K(I)
1469
- }, Vt = {
1470
- appid: K(I),
1471
- appidExclude: K(I),
1472
- credProps: K(I)
1473
- }, Kt = {
1474
- appid: K(I),
1475
- appidExclude: K(I),
1476
- credProps: K(I)
1477
- }, La = {
1478
- publicKey: j({
1479
- rp: j(I),
1480
- user: j({
1481
- id: j(be),
1482
- name: j(I),
1483
- displayName: j(I)
1471
+ var Gt = {
1472
+ type: M(O),
1473
+ id: M(ve),
1474
+ transports: G(O)
1475
+ }, Ht = {
1476
+ appid: G(O),
1477
+ appidExclude: G(O),
1478
+ credProps: G(O)
1479
+ }, Wt = {
1480
+ appid: G(O),
1481
+ appidExclude: G(O),
1482
+ credProps: G(O)
1483
+ }, Ka = {
1484
+ publicKey: M({
1485
+ rp: M(O),
1486
+ user: M({
1487
+ id: M(ve),
1488
+ name: M(O),
1489
+ displayName: M(O)
1484
1490
  }),
1485
- challenge: j(be),
1486
- pubKeyCredParams: j(I),
1487
- timeout: K(I),
1488
- excludeCredentials: K([Jt]),
1489
- authenticatorSelection: K(I),
1490
- attestation: K(I),
1491
- extensions: K(Vt)
1491
+ challenge: M(ve),
1492
+ pubKeyCredParams: M(O),
1493
+ timeout: G(O),
1494
+ excludeCredentials: G([Gt]),
1495
+ authenticatorSelection: G(O),
1496
+ attestation: G(O),
1497
+ extensions: G(Ht)
1492
1498
  }),
1493
- signal: K(I)
1494
- }, qa = {
1495
- type: j(I),
1496
- id: j(I),
1497
- rawId: j(be),
1498
- authenticatorAttachment: K(I),
1499
- response: j({
1500
- clientDataJSON: j(be),
1501
- attestationObject: j(be),
1502
- transports: ot(
1503
- I,
1499
+ signal: G(O)
1500
+ }, Ga = {
1501
+ type: M(O),
1502
+ id: M(O),
1503
+ rawId: M(ve),
1504
+ authenticatorAttachment: G(O),
1505
+ response: M({
1506
+ clientDataJSON: M(ve),
1507
+ attestationObject: M(ve),
1508
+ transports: dt(
1509
+ O,
1504
1510
  (e) => {
1505
1511
  var t;
1506
1512
  return ((t = e.getTransports) == null ? void 0 : t.call(e)) || [];
1507
1513
  }
1508
1514
  )
1509
1515
  }),
1510
- clientExtensionResults: ot(
1511
- Kt,
1516
+ clientExtensionResults: dt(
1517
+ Wt,
1512
1518
  (e) => e.getClientExtensionResults()
1513
1519
  )
1514
- }, Ua = {
1515
- mediation: K(I),
1516
- publicKey: j({
1517
- challenge: j(be),
1518
- timeout: K(I),
1519
- rpId: K(I),
1520
- allowCredentials: K([Jt]),
1521
- userVerification: K(I),
1522
- extensions: K(Vt)
1520
+ }, Ha = {
1521
+ mediation: G(O),
1522
+ publicKey: M({
1523
+ challenge: M(ve),
1524
+ timeout: G(O),
1525
+ rpId: G(O),
1526
+ allowCredentials: G([Gt]),
1527
+ userVerification: G(O),
1528
+ extensions: G(Ht)
1523
1529
  }),
1524
- signal: K(I)
1525
- }, Ja = {
1526
- type: j(I),
1527
- id: j(I),
1528
- rawId: j(be),
1529
- authenticatorAttachment: K(I),
1530
- response: j({
1531
- clientDataJSON: j(be),
1532
- authenticatorData: j(be),
1533
- signature: j(be),
1534
- userHandle: j(be)
1530
+ signal: G(O)
1531
+ }, Wa = {
1532
+ type: M(O),
1533
+ id: M(O),
1534
+ rawId: M(ve),
1535
+ authenticatorAttachment: G(O),
1536
+ response: M({
1537
+ clientDataJSON: M(ve),
1538
+ authenticatorData: M(ve),
1539
+ signature: M(ve),
1540
+ userHandle: M(ve)
1535
1541
  }),
1536
- clientExtensionResults: ot(
1537
- Kt,
1542
+ clientExtensionResults: dt(
1543
+ Wt,
1538
1544
  (e) => e.getClientExtensionResults()
1539
1545
  )
1540
1546
  };
1541
- function Gt(e) {
1542
- return je(qt, La, e);
1547
+ function Zt(e) {
1548
+ return Re(Vt, Ka, e);
1543
1549
  }
1544
- function Va(e) {
1545
- return je(
1546
- Ut,
1547
- qa,
1550
+ function Za(e) {
1551
+ return Re(
1552
+ Kt,
1553
+ Ga,
1548
1554
  e
1549
1555
  );
1550
1556
  }
1551
- function Ka(e) {
1552
- return je(qt, Ua, e);
1557
+ function Ya(e) {
1558
+ return Re(Vt, Ha, e);
1553
1559
  }
1554
- function Ga(e) {
1555
- return je(
1556
- Ut,
1557
- Ja,
1560
+ function Xa(e) {
1561
+ return Re(
1562
+ Kt,
1563
+ Wa,
1558
1564
  e
1559
1565
  );
1560
1566
  }
1561
- async function Ht(e) {
1567
+ async function Yt(e) {
1562
1568
  const t = await navigator.credentials.create(
1563
1569
  e
1564
1570
  );
1565
- return t.toJSON = () => Va(t), t;
1571
+ return t.toJSON = () => Za(t), t;
1566
1572
  }
1567
- async function Ha(e) {
1573
+ async function Qa(e) {
1568
1574
  const t = await navigator.credentials.get(
1569
1575
  e
1570
1576
  );
1571
- return t.toJSON = () => Ga(t), t;
1577
+ return t.toJSON = () => Xa(t), t;
1572
1578
  }
1573
- function lt(e) {
1579
+ function ft(e) {
1574
1580
  this.message = e;
1575
1581
  }
1576
- lt.prototype = new Error(), lt.prototype.name = "InvalidCharacterError";
1577
- var At = typeof window < "u" && window.atob && window.atob.bind(window) || function(e) {
1582
+ ft.prototype = new Error(), ft.prototype.name = "InvalidCharacterError";
1583
+ var yt = typeof window < "u" && window.atob && window.atob.bind(window) || function(e) {
1578
1584
  var t = String(e).replace(/=+$/, "");
1579
- if (t.length % 4 == 1) throw new lt("'atob' failed: The string to be decoded is not correctly encoded.");
1585
+ if (t.length % 4 == 1) throw new ft("'atob' failed: The string to be decoded is not correctly encoded.");
1580
1586
  for (var n, r, s = 0, i = 0, u = ""; r = t.charAt(i++); ~r && (n = s % 4 ? 64 * n + r : r, s++ % 4) ? u += String.fromCharCode(255 & n >> (-2 * s & 6)) : 0) r = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".indexOf(r);
1581
1587
  return u;
1582
1588
  };
1583
- function Wa(e) {
1589
+ function eu(e) {
1584
1590
  var t = e.replace(/-/g, "+").replace(/_/g, "/");
1585
1591
  switch (t.length % 4) {
1586
1592
  case 0:
@@ -1596,50 +1602,55 @@ function Wa(e) {
1596
1602
  }
1597
1603
  try {
1598
1604
  return function(n) {
1599
- return decodeURIComponent(At(n).replace(/(.)/g, function(r, s) {
1605
+ return decodeURIComponent(yt(n).replace(/(.)/g, function(r, s) {
1600
1606
  var i = s.charCodeAt(0).toString(16).toUpperCase();
1601
1607
  return i.length < 2 && (i = "0" + i), "%" + i;
1602
1608
  }));
1603
1609
  }(t);
1604
1610
  } catch {
1605
- return At(t);
1611
+ return yt(t);
1606
1612
  }
1607
1613
  }
1608
- function Qe(e) {
1614
+ function tt(e) {
1609
1615
  this.message = e;
1610
1616
  }
1611
- function Za(e, t) {
1612
- if (typeof e != "string") throw new Qe("Invalid token specified");
1617
+ function tu(e, t) {
1618
+ if (typeof e != "string") throw new tt("Invalid token specified");
1613
1619
  var n = (t = t || {}).header === !0 ? 0 : 1;
1614
1620
  try {
1615
- return JSON.parse(Wa(e.split(".")[n]));
1621
+ return JSON.parse(eu(e.split(".")[n]));
1616
1622
  } catch (r) {
1617
- throw new Qe("Invalid token specified: " + r.message);
1623
+ throw new tt("Invalid token specified: " + r.message);
1618
1624
  }
1619
1625
  }
1620
- Qe.prototype = new Error(), Qe.prototype.name = "InvalidTokenError";
1621
- const Ge = "spartan-token";
1622
- function Wt() {
1623
- const e = localStorage.getItem(Ge);
1626
+ tt.prototype = new Error(), tt.prototype.name = "InvalidTokenError";
1627
+ const We = "spartan-token";
1628
+ function Xt() {
1629
+ const e = localStorage.getItem(We);
1624
1630
  let t = null;
1625
1631
  if (e)
1626
1632
  try {
1627
- if (t = Za(e), t.exp > Xa())
1633
+ if (t = tu(e), t.exp > ru())
1628
1634
  return t;
1629
- localStorage.removeItem(Ge);
1635
+ localStorage.removeItem(We);
1630
1636
  } catch (n) {
1631
- console.error("Error decoding token", n), localStorage.removeItem(Ge);
1637
+ console.error("Error decoding token", n), localStorage.removeItem(We);
1632
1638
  }
1633
1639
  return null;
1634
1640
  }
1635
- function Ya() {
1636
- const e = localStorage.getItem(Ge);
1641
+ function nu() {
1642
+ const e = localStorage.getItem(We);
1637
1643
  return e || null;
1638
1644
  }
1639
- function Xa() {
1645
+ function ru() {
1640
1646
  return Math.round((/* @__PURE__ */ new Date()).getTime() / 1e3);
1641
1647
  }
1642
- var Qa = /* @__PURE__ */ F(`<form class=login-frame><style>.login-frame {
1648
+ var su = /* @__PURE__ */ F(`<div class=widget-root><form class=login-frame><style>.widget-root {
1649
+ display: block;
1650
+ position: relative;
1651
+ }
1652
+
1653
+ .login-frame {
1643
1654
  display: flex;
1644
1655
  flex-direction: column;
1645
1656
  justify-content: center;
@@ -1651,6 +1662,18 @@ var Qa = /* @__PURE__ */ F(`<form class=login-frame><style>.login-frame {
1651
1662
  background-color: rgba(255,255,255,0.9);
1652
1663
  }
1653
1664
 
1665
+ .loading-overlay {
1666
+ position: absolute;
1667
+ inset: 0;
1668
+ display: flex;
1669
+ align-items: center;
1670
+ justify-content: center;
1671
+ background-color: rgba(255, 255, 255, 0.72);
1672
+ backdrop-filter: blur(8px);
1673
+ -webkit-backdrop-filter: blur(8px);
1674
+ z-index: 10;
1675
+ }
1676
+
1654
1677
 
1655
1678
  .login-frame h1 {
1656
1679
  margin: 0;
@@ -1768,8 +1791,8 @@ var Qa = /* @__PURE__ */ F(`<form class=login-frame><style>.login-frame {
1768
1791
  margin-bottom: 0;
1769
1792
  display: block;
1770
1793
  }
1771
- </style><style></style><h1>`), eu = /* @__PURE__ */ F("<span class=error-message>"), it = /* @__PURE__ */ F("<span>"), tu = /* @__PURE__ */ F("<input type=text autocomplete=one-time-code required>"), Et = /* @__PURE__ */ F("<span class=hint>"), nu = /* @__PURE__ */ F("<input type=password autocomplete=new-password required>"), Ft = /* @__PURE__ */ F("<button type=submit>"), ru = /* @__PURE__ */ F("<span class=info-message>"), su = /* @__PURE__ */ F("<span class=success-message>"), iu = /* @__PURE__ */ F("<input type=text autocomplete=username>"), au = /* @__PURE__ */ F("<input type=password autocomplete=current-password>"), at = /* @__PURE__ */ F("<p>"), uu = /* @__PURE__ */ F("<select>"), ou = /* @__PURE__ */ F("<option> (<!>)"), lu = /* @__PURE__ */ F("<input type=text>"), yt = /* @__PURE__ */ F("<input type=text autocomplete=one-time-code>"), $t = /* @__PURE__ */ F("<input type=password autocomplete=new-password>"), cu = /* @__PURE__ */ F("<span class=checkbox-wrapper><input type=checkbox><span>&nbsp;"), du = /* @__PURE__ */ F("<button type=button>"), Ke = /* @__PURE__ */ F("<a class=centered-text href=#>"), fu = /* @__PURE__ */ F("<div class=social-divider><span>"), hu = /* @__PURE__ */ F("<button type=button class=social-btn>"), pu = /* @__PURE__ */ F('<svg width=18 height=18 viewBox="0 0 18 18"xmlns=http://www.w3.org/2000/svg><path d="M17.64 9.2c0-.637-.057-1.251-.164-1.84H9v3.481h4.844c-.209 1.125-.843 2.078-1.796 2.717v2.258h2.908c1.702-1.567 2.684-3.875 2.684-6.615z"fill=#4285F4></path><path d="M9 18c2.43 0 4.467-.806 5.956-2.184l-2.908-2.258c-.806.54-1.837.86-3.048.86-2.344 0-4.328-1.584-5.036-3.711H.957v2.332C2.438 15.983 5.482 18 9 18z"fill=#34A853></path><path d="M3.964 10.707c-.18-.54-.282-1.117-.282-1.707s.102-1.167.282-1.707V4.961H.957C.347 6.175 0 7.548 0 9s.348 2.825.957 4.039l3.007-2.332z"fill=#FBBC05></path><path d="M9 3.58c1.321 0 2.508.454 3.44 1.345l2.582-2.58C13.463.891 11.426 0 9 0 5.482 0 2.438 2.017.957 4.961L3.964 7.293C4.672 5.166 6.656 3.58 9 3.58z"fill=#EA4335>'), Du = /* @__PURE__ */ F('<svg width=18 height=18 viewBox="0 0 16 16"xmlns=http://www.w3.org/2000/svg><path fill-rule=evenodd d="M8 0C3.58 0 0 3.58 0 8c0 3.54 2.29 6.53 5.47 7.59.4.07.55-.17.55-.38 0-.19-.01-.82-.01-1.49-2.01.37-2.53-.49-2.69-.94-.09-.23-.48-.94-.82-1.13-.28-.15-.68-.52-.01-.53.63-.01 1.08.58 1.23.82.72 1.21 1.87.87 2.33.66.07-.52.28-.87.51-1.07-1.78-.2-3.64-.89-3.64-3.95 0-.87.31-1.59.82-2.15-.08-.2-.36-1.02.08-2.12 0 0 .67-.21 2.2.82.64-.18 1.32-.27 2-.27.68 0 1.36.09 2 .27 1.53-1.04 2.2-.82 2.2-.82.44 1.1.16 1.92.08 2.12.51.56.82 1.27.82 2.15 0 3.07-1.87 3.75-3.65 3.95.29.25.54.73.54 1.48 0 1.07-.01 1.93-.01 2.2 0 .21.15.46.55.38A8.013 8.013 0 0016 8c0-4.42-3.58-8-8-8z"fill=currentColor>'), gu = /* @__PURE__ */ F('<svg width=18 height=18 viewBox="20 16 16 19"xmlns=http://www.w3.org/2000/svg><path d="M28.2226562,20.3846154 C29.0546875,20.3846154 30.0976562,19.8048315 30.71875,19.0317864 C31.28125,18.3312142 31.6914062,17.352829 31.6914062,16.3744437 C31.6914062,16.2415766 31.6796875,16.1087095 31.65625,16 C30.7304687,16.0362365 29.6171875,16.640178 28.9492187,17.4494596 C28.421875,18.06548 27.9414062,19.0317864 27.9414062,20.0222505 C27.9414062,20.1671964 27.9648438,20.3121424 27.9765625,20.3604577 C28.0351562,20.3725366 28.1289062,20.3846154 28.2226562,20.3846154 Z M25.2929688,35 C26.4296875,35 26.9335938,34.214876 28.3515625,34.214876 C29.7929688,34.214876 30.109375,34.9758423 31.375,34.9758423 C32.6171875,34.9758423 33.4492188,33.792117 34.234375,32.6325493 C35.1132812,31.3038779 35.4765625,29.9993643 35.5,29.9389701 C35.4179688,29.9148125 33.0390625,28.9122695 33.0390625,26.0979021 C33.0390625,23.6579784 34.9140625,22.5588048 35.0195312,22.474253 C33.7773438,20.6382708 31.890625,20.5899555 31.375,20.5899555 C29.9804688,20.5899555 28.84375,21.4596313 28.1289062,21.4596313 C27.3554688,21.4596313 26.3359375,20.6382708 25.1289062,20.6382708 C22.8320312,20.6382708 20.5,22.5950413 20.5,26.2911634 C20.5,28.5861411 21.3671875,31.013986 22.4335938,32.5842339 C23.3476562,33.9129053 24.1445312,35 25.2929688,35 Z"fill=currentColor fill-rule=nonzero>'), mu = /* @__PURE__ */ F('<svg width=18 height=18 viewBox="0 0 24 24"xmlns=http://www.w3.org/2000/svg><path d="M12 1L3 5v6c0 5.55 3.84 10.74 9 12 5.16-1.26 9-6.45 9-12V5l-9-4zm0 4a3 3 0 110 6 3 3 0 010-6zm0 14c-2.5 0-4.71-1.28-6-3.22.03-1.99 4-3.08 6-3.08s5.97 1.09 6 3.08c-1.29 1.94-3.5 3.22-6 3.22z"fill=currentColor>');
1772
- const bu = {
1794
+ </style><style></style><h1>`), iu = /* @__PURE__ */ F("<span class=error-message>"), ot = /* @__PURE__ */ F("<span>"), au = /* @__PURE__ */ F("<input type=text autocomplete=one-time-code required>"), $t = /* @__PURE__ */ F("<span class=hint>"), uu = /* @__PURE__ */ F("<input type=password autocomplete=new-password required>"), kt = /* @__PURE__ */ F("<button type=submit>"), ou = /* @__PURE__ */ F("<span class=info-message>"), lu = /* @__PURE__ */ F("<span class=success-message>"), cu = /* @__PURE__ */ F("<input type=text autocomplete=username>"), du = /* @__PURE__ */ F("<input type=password autocomplete=current-password>"), lt = /* @__PURE__ */ F("<p>"), fu = /* @__PURE__ */ F("<select>"), hu = /* @__PURE__ */ F("<option> (<!>)"), pu = /* @__PURE__ */ F("<input type=text>"), Bt = /* @__PURE__ */ F("<input type=text autocomplete=one-time-code>"), xt = /* @__PURE__ */ F("<input type=password autocomplete=new-password>"), Du = /* @__PURE__ */ F("<span class=checkbox-wrapper><input type=checkbox><span>&nbsp;"), gu = /* @__PURE__ */ F("<button type=button>"), He = /* @__PURE__ */ F("<a class=centered-text href=#>"), mu = /* @__PURE__ */ F("<div class=social-divider><span>"), bu = /* @__PURE__ */ F("<button type=button class=social-btn>"), vu = /* @__PURE__ */ F('<svg width=18 height=18 viewBox="0 0 18 18"xmlns=http://www.w3.org/2000/svg><path d="M17.64 9.2c0-.637-.057-1.251-.164-1.84H9v3.481h4.844c-.209 1.125-.843 2.078-1.796 2.717v2.258h2.908c1.702-1.567 2.684-3.875 2.684-6.615z"fill=#4285F4></path><path d="M9 18c2.43 0 4.467-.806 5.956-2.184l-2.908-2.258c-.806.54-1.837.86-3.048.86-2.344 0-4.328-1.584-5.036-3.711H.957v2.332C2.438 15.983 5.482 18 9 18z"fill=#34A853></path><path d="M3.964 10.707c-.18-.54-.282-1.117-.282-1.707s.102-1.167.282-1.707V4.961H.957C.347 6.175 0 7.548 0 9s.348 2.825.957 4.039l3.007-2.332z"fill=#FBBC05></path><path d="M9 3.58c1.321 0 2.508.454 3.44 1.345l2.582-2.58C13.463.891 11.426 0 9 0 5.482 0 2.438 2.017.957 4.961L3.964 7.293C4.672 5.166 6.656 3.58 9 3.58z"fill=#EA4335>'), Cu = /* @__PURE__ */ F('<svg width=18 height=18 viewBox="0 0 16 16"xmlns=http://www.w3.org/2000/svg><path fill-rule=evenodd d="M8 0C3.58 0 0 3.58 0 8c0 3.54 2.29 6.53 5.47 7.59.4.07.55-.17.55-.38 0-.19-.01-.82-.01-1.49-2.01.37-2.53-.49-2.69-.94-.09-.23-.48-.94-.82-1.13-.28-.15-.68-.52-.01-.53.63-.01 1.08.58 1.23.82.72 1.21 1.87.87 2.33.66.07-.52.28-.87.51-1.07-1.78-.2-3.64-.89-3.64-3.95 0-.87.31-1.59.82-2.15-.08-.2-.36-1.02.08-2.12 0 0 .67-.21 2.2.82.64-.18 1.32-.27 2-.27.68 0 1.36.09 2 .27 1.53-1.04 2.2-.82 2.2-.82.44 1.1.16 1.92.08 2.12.51.56.82 1.27.82 2.15 0 3.07-1.87 3.75-3.65 3.95.29.25.54.73.54 1.48 0 1.07-.01 1.93-.01 2.2 0 .21.15.46.55.38A8.013 8.013 0 0016 8c0-4.42-3.58-8-8-8z"fill=currentColor>'), wu = /* @__PURE__ */ F('<svg width=18 height=18 viewBox="20 16 16 19"xmlns=http://www.w3.org/2000/svg><path d="M28.2226562,20.3846154 C29.0546875,20.3846154 30.0976562,19.8048315 30.71875,19.0317864 C31.28125,18.3312142 31.6914062,17.352829 31.6914062,16.3744437 C31.6914062,16.2415766 31.6796875,16.1087095 31.65625,16 C30.7304687,16.0362365 29.6171875,16.640178 28.9492187,17.4494596 C28.421875,18.06548 27.9414062,19.0317864 27.9414062,20.0222505 C27.9414062,20.1671964 27.9648438,20.3121424 27.9765625,20.3604577 C28.0351562,20.3725366 28.1289062,20.3846154 28.2226562,20.3846154 Z M25.2929688,35 C26.4296875,35 26.9335938,34.214876 28.3515625,34.214876 C29.7929688,34.214876 30.109375,34.9758423 31.375,34.9758423 C32.6171875,34.9758423 33.4492188,33.792117 34.234375,32.6325493 C35.1132812,31.3038779 35.4765625,29.9993643 35.5,29.9389701 C35.4179688,29.9148125 33.0390625,28.9122695 33.0390625,26.0979021 C33.0390625,23.6579784 34.9140625,22.5588048 35.0195312,22.474253 C33.7773438,20.6382708 31.890625,20.5899555 31.375,20.5899555 C29.9804688,20.5899555 28.84375,21.4596313 28.1289062,21.4596313 C27.3554688,21.4596313 26.3359375,20.6382708 25.1289062,20.6382708 C22.8320312,20.6382708 20.5,22.5950413 20.5,26.2911634 C20.5,28.5861411 21.3671875,31.013986 22.4335938,32.5842339 C23.3476562,33.9129053 24.1445312,35 25.2929688,35 Z"fill=currentColor fill-rule=nonzero>'), Au = /* @__PURE__ */ F('<svg width=18 height=18 viewBox="0 0 24 24"xmlns=http://www.w3.org/2000/svg><path d="M12 1L3 5v6c0 5.55 3.84 10.74 9 12 5.16-1.26 9-6.45 9-12V5l-9-4zm0 4a3 3 0 110 6 3 3 0 010-6zm0 14c-2.5 0-4.71-1.28-6-3.22.03-1.99 4-3.08 6-3.08s5.97 1.09 6 3.08c-1.29 1.94-3.5 3.22-6 3.22z"fill=currentColor>'), Eu = /* @__PURE__ */ F("<div class=loading-overlay part=loading-overlay><slot name=loading>");
1795
+ const Fu = {
1773
1796
  domain: "http://127.0.0.1:11000",
1774
1797
  sector: "0ad5c3e5-0186-4557-8b32-4b36f247bf09",
1775
1798
  // defaults to the admin sector
@@ -1778,27 +1801,31 @@ const bu = {
1778
1801
  locale: "en",
1779
1802
  redirect: ""
1780
1803
  };
1781
- ht("spartan-login", bu, (e) => {
1782
- const [t, n] = w((e.startMode || "password").toLowerCase()), [r, s] = w(""), [i, u] = w(""), [l, C] = w(""), [$, D] = w(""), [B] = w(e.redirect), [ae, de] = w(!1), [Ee, L] = w(!1), [W, Z] = w(!1), [ue, G] = w(""), [te, J] = w(""), [we, Fe] = w([]), [Ae, k] = w(""), [X, ye] = w([]), [pe, De] = w(""), [b, ge] = w(!1), [Re, me] = w(!1), [Pe, Le] = w(""), [qe, Te] = w(""), [Oe, Ie] = w(""), [ze, ve] = w(""), [xe, Se] = w(""), [A, v] = w(""), [S, R] = w(!1), d = pt(e.locale);
1783
- let _, z;
1804
+ gt("spartan-login", Fu, (e) => {
1805
+ const [t, n] = w((e.startMode || "password").toLowerCase()), [r, s] = w(""), [i, u] = w(""), [o, C] = w(""), [$, D] = w(""), [k] = w(e.redirect), [ue, fe] = w(!1), [Fe, R] = w(!1), [Z, Y] = w(!1), [oe, H] = w(""), [ne, V] = w(""), [Ae, ye] = w([]), [Ee, B] = w(""), [ee, $e] = w([]), [he, ge] = w(""), [b, me] = w(!1), [Le, be] = w(!1), [ze, qe] = w(""), [Ue, Oe] = w(""), [Ie, Pe] = w(""), [Ne, Ce] = w(""), [xe, Se] = w(""), [A, v] = w(""), [x, j] = w(!1), d = mt(e.locale);
1806
+ let _, I = null, z;
1807
+ const L = () => b() || !!he();
1808
+ rn(() => {
1809
+ I && clearTimeout(I);
1810
+ });
1784
1811
  try {
1785
1812
  z = e.styles;
1786
1813
  } catch {
1787
1814
  z = "";
1788
1815
  }
1789
- console.log(z), ct(async () => {
1790
- const o = new URLSearchParams(window.location.search);
1791
- if (o.get("error")) {
1816
+ console.log(z), ht(async () => {
1817
+ const l = new URLSearchParams(window.location.search);
1818
+ if (l.get("error")) {
1792
1819
  history.replaceState({}, "", window.location.pathname);
1793
- const M = o.get("error_description");
1794
- D(M || d.i18n("sa-social-error")), P(), T();
1820
+ const pe = l.get("error_description");
1821
+ D(pe || d.i18n("sa-social-error")), q(), N();
1795
1822
  return;
1796
1823
  }
1797
- const E = o.get("code");
1824
+ const E = l.get("code");
1798
1825
  if (E) {
1799
- history.replaceState({}, "", window.location.pathname), ge(!0);
1826
+ history.replaceState({}, "", window.location.pathname), me(!0);
1800
1827
  try {
1801
- const M = await fetch(`${e.domain}/api/v1/oauth/exchange`, {
1828
+ const pe = await fetch(`${e.domain}/api/v1/oauth/exchange`, {
1802
1829
  method: "POST",
1803
1830
  mode: "cors",
1804
1831
  cache: "no-cache",
@@ -1809,36 +1836,46 @@ ht("spartan-login", bu, (e) => {
1809
1836
  code: E
1810
1837
  })
1811
1838
  });
1812
- if (!M.ok) throw new Error(d.i18n("sa-social-error"));
1813
- const a = await M.json();
1814
- localStorage.setItem("spartan-token", a.token), _.getRootNode().host.dispatchEvent(new CustomEvent("spartan-login", {
1839
+ if (!pe.ok) throw new Error(d.i18n("sa-social-error"));
1840
+ const W = await pe.json();
1841
+ localStorage.setItem("spartan-token", W.token);
1842
+ const a = _.getRootNode().host;
1843
+ e.redirect !== "" ? (a.dispatchEvent(new CustomEvent("spartan-login", {
1844
+ bubbles: !0,
1845
+ cancelable: !0,
1846
+ detail: {
1847
+ token: W.token
1848
+ }
1849
+ })), window.location.href = e.redirect) : (I = setTimeout(() => {
1850
+ I = null, me(!1), q(), N();
1851
+ }, 5e3), a.dispatchEvent(new CustomEvent("spartan-login", {
1815
1852
  bubbles: !0,
1816
1853
  cancelable: !0,
1817
1854
  detail: {
1818
- token: a.token
1855
+ token: W.token
1819
1856
  }
1820
- })), e.redirect !== "" ? window.location.href = e.redirect : (ge(!1), P(), T());
1821
- } catch (M) {
1822
- D(M.message || d.i18n("sa-social-error")), ge(!1), P(), T();
1857
+ })));
1858
+ } catch (pe) {
1859
+ D(pe.message || d.i18n("sa-social-error")), me(!1), q(), N();
1823
1860
  }
1824
1861
  return;
1825
1862
  }
1826
- const oe = o.get("sub");
1827
- if (oe) {
1828
- Ie(oe);
1829
- const M = o.get("email");
1830
- M && ve(M);
1831
- const h = new URLSearchParams(window.location.hash.replace(/^#/, "")).get("otp");
1832
- h && Se(h), n("invite");
1863
+ const ie = l.get("sub");
1864
+ if (ie) {
1865
+ Pe(ie);
1866
+ const pe = l.get("email");
1867
+ pe && Ce(pe);
1868
+ const a = new URLSearchParams(window.location.hash.replace(/^#/, "")).get("otp");
1869
+ a && Se(a), n("invite");
1833
1870
  return;
1834
1871
  }
1835
- if (Wt() && e.redirect !== "" && window.location.pathname !== e.redirect) {
1872
+ if (Xt() && e.redirect !== "" && window.location.pathname !== e.redirect) {
1836
1873
  window.location.href = e.redirect;
1837
1874
  return;
1838
1875
  }
1839
- P(), T();
1876
+ q(), N();
1840
1877
  });
1841
- function P() {
1878
+ function q() {
1842
1879
  fetch(`${e.domain}/api/v1/sectors/${e.sector}/publicsettings`, {
1843
1880
  method: "GET",
1844
1881
  mode: "cors",
@@ -1846,35 +1883,35 @@ ht("spartan-login", bu, (e) => {
1846
1883
  headers: {
1847
1884
  "Content-Type": "application/json"
1848
1885
  }
1849
- }).then((o) => {
1850
- if (o.ok)
1851
- return o.json();
1886
+ }).then((l) => {
1887
+ if (l.ok)
1888
+ return l.json();
1852
1889
  throw new Error("Network response was not ok.");
1853
- }).then((o) => {
1854
- console.log(o), de(o.SelfSignUpAllowed), me(o.MFARequired || !1);
1855
- }).catch((o) => {
1856
- console.log(o), D(o.message);
1890
+ }).then((l) => {
1891
+ console.log(l), fe(l.SelfSignUpAllowed), be(l.MFARequired || !1);
1892
+ }).catch((l) => {
1893
+ console.log(l), D(l.message);
1857
1894
  });
1858
1895
  }
1859
- function T() {
1896
+ function N() {
1860
1897
  fetch(`${e.domain}/api/v1/sectors/${e.sector}/oauth/providers`, {
1861
1898
  method: "GET",
1862
1899
  mode: "cors",
1863
1900
  cache: "no-cache"
1864
- }).then((o) => {
1865
- if (o.ok) return o.json();
1901
+ }).then((l) => {
1902
+ if (l.ok) return l.json();
1866
1903
  throw new Error("Failed to load social providers");
1867
- }).then((o) => {
1868
- const g = (o.providers || []).filter((E) => E.enabled);
1869
- ye(g);
1904
+ }).then((l) => {
1905
+ const g = (l.providers || []).filter((E) => E.enabled);
1906
+ $e(g);
1870
1907
  }).catch(() => {
1871
1908
  });
1872
1909
  }
1873
- function Q(o) {
1874
- if (pe()) return;
1875
- De(o), D("");
1910
+ function U(l) {
1911
+ if (he()) return;
1912
+ ge(l), D("");
1876
1913
  const g = window.location.origin + window.location.pathname;
1877
- fetch(`${e.domain}/api/v1/oauth/${o}/initiate`, {
1914
+ fetch(`${e.domain}/api/v1/oauth/${l}/initiate`, {
1878
1915
  method: "POST",
1879
1916
  mode: "cors",
1880
1917
  cache: "no-cache",
@@ -1891,11 +1928,11 @@ ht("spartan-login", bu, (e) => {
1891
1928
  }).then((E) => {
1892
1929
  window.location.href = E.authURL;
1893
1930
  }).catch((E) => {
1894
- De(""), D(E.message);
1931
+ ge(""), D(E.message);
1895
1932
  });
1896
1933
  }
1897
- function V(o, g) {
1898
- return D(""), Te(g), fetch(`${e.domain}/api/v1/signup/mfa/begin`, {
1934
+ function K(l, g) {
1935
+ return D(""), Oe(g), fetch(`${e.domain}/api/v1/signup/mfa/begin`, {
1899
1936
  method: "POST",
1900
1937
  mode: "cors",
1901
1938
  cache: "no-cache",
@@ -1903,7 +1940,7 @@ ht("spartan-login", bu, (e) => {
1903
1940
  "Content-Type": "application/json"
1904
1941
  },
1905
1942
  body: JSON.stringify({
1906
- email: o,
1943
+ email: l,
1907
1944
  sectorID: e.sector,
1908
1945
  transactionId: g
1909
1946
  })
@@ -1916,7 +1953,7 @@ ht("spartan-login", bu, (e) => {
1916
1953
  D(E.message);
1917
1954
  });
1918
1955
  }
1919
- function q() {
1956
+ function le() {
1920
1957
  return D(""), fetch(`${e.domain}/api/v1/signup/mfa/verify`, {
1921
1958
  method: "POST",
1922
1959
  mode: "cors",
@@ -1926,73 +1963,73 @@ ht("spartan-login", bu, (e) => {
1926
1963
  },
1927
1964
  body: JSON.stringify({
1928
1965
  email: r(),
1929
- code: l().toUpperCase().trim(),
1966
+ code: o().toUpperCase().trim(),
1930
1967
  sectorID: e.sector,
1931
- transactionId: qe()
1968
+ transactionId: Ue()
1932
1969
  })
1933
- }).then((o) => {
1934
- if (o.ok) return o.json();
1935
- throw o.status === 400 ? new Error(d.i18n("sa-signup-verify-error")) : new Error(d.i18n("sa-signup-verify-error"));
1936
- }).then((o) => {
1937
- Le(o.token), localStorage.setItem("spartan-token", o.token), _.getRootNode().host.dispatchEvent(new CustomEvent("spartan-login", {
1970
+ }).then((l) => {
1971
+ if (l.ok) return l.json();
1972
+ throw l.status === 400 ? new Error(d.i18n("sa-signup-verify-error")) : new Error(d.i18n("sa-signup-verify-error"));
1973
+ }).then((l) => {
1974
+ qe(l.token), localStorage.setItem("spartan-token", l.token), _.getRootNode().host.dispatchEvent(new CustomEvent("spartan-login", {
1938
1975
  bubbles: !0,
1939
1976
  cancelable: !0,
1940
1977
  detail: {
1941
- token: o.token
1978
+ token: l.token
1942
1979
  }
1943
1980
  })), C(""), n("signup-webauthn");
1944
- }).catch((o) => {
1945
- D(o.message);
1981
+ }).catch((l) => {
1982
+ D(l.message);
1946
1983
  });
1947
1984
  }
1948
- function H() {
1949
- b() || (ge(!0), D(""), fetch(`${e.domain}/api/v1/webauthn/registration/begin`, {
1985
+ function J() {
1986
+ b() || (me(!0), D(""), fetch(`${e.domain}/api/v1/webauthn/registration/begin`, {
1950
1987
  method: "POST",
1951
1988
  mode: "cors",
1952
1989
  cache: "no-cache",
1953
1990
  headers: {
1954
1991
  "Content-Type": "application/json",
1955
- Authorization: `bearer ${Pe()}`
1992
+ Authorization: `bearer ${ze()}`
1956
1993
  },
1957
1994
  body: JSON.stringify({
1958
1995
  keyName: "Default",
1959
1996
  sectorID: e.sector
1960
1997
  })
1961
- }).then((o) => {
1962
- if (!o.ok) throw new Error(d.i18n("sa-signup-webauthn-error"));
1963
- return o.json();
1964
- }).then((o) => {
1965
- const g = Gt(o.Options);
1966
- return Ht(g).then((E) => {
1967
- let oe = JSON.parse(JSON.stringify(E));
1968
- return oe.transactionID = o.TransactionID, oe;
1998
+ }).then((l) => {
1999
+ if (!l.ok) throw new Error(d.i18n("sa-signup-webauthn-error"));
2000
+ return l.json();
2001
+ }).then((l) => {
2002
+ const g = Zt(l.Options);
2003
+ return Yt(g).then((E) => {
2004
+ let ie = JSON.parse(JSON.stringify(E));
2005
+ return ie.transactionID = l.TransactionID, ie;
1969
2006
  });
1970
- }).then((o) => fetch(`${e.domain}/api/v1/webauthn/registration/finish`, {
2007
+ }).then((l) => fetch(`${e.domain}/api/v1/webauthn/registration/finish`, {
1971
2008
  method: "POST",
1972
2009
  mode: "cors",
1973
2010
  cache: "no-cache",
1974
2011
  headers: {
1975
2012
  "Content-Type": "application/json",
1976
- Authorization: `bearer ${Pe()}`
2013
+ Authorization: `bearer ${ze()}`
1977
2014
  },
1978
- body: JSON.stringify(o)
1979
- })).then((o) => {
1980
- if (!o.ok) throw new Error(d.i18n("sa-signup-webauthn-error"));
1981
- ne();
1982
- }).catch((o) => {
1983
- D((o == null ? void 0 : o.message) || String(o));
2015
+ body: JSON.stringify(l)
2016
+ })).then((l) => {
2017
+ if (!l.ok) throw new Error(d.i18n("sa-signup-webauthn-error"));
2018
+ c();
2019
+ }).catch((l) => {
2020
+ D((l == null ? void 0 : l.message) || String(l));
1984
2021
  }).finally(() => {
1985
- ge(!1);
2022
+ me(!1);
1986
2023
  }));
1987
2024
  }
1988
- function ne() {
2025
+ function c() {
1989
2026
  n(e.startMode), e.redirect !== "" && (window.location.href = e.redirect);
1990
2027
  }
1991
- function U() {
1992
- return console.log("login"), D(""), t() === "password" ? O() : t() === "webauthn" ? m() : t() === "otp-pick" ? re(Ae()) : t() === "otp" ? se() : t() === "reset-email" ? fe() : t() === "reset-code" ? $e() : Promise.resolve();
2028
+ function m() {
2029
+ return console.log("login"), D(""), t() === "password" ? te() : t() === "webauthn" ? S() : t() === "otp-pick" ? ce(Ee()) : t() === "otp" ? ke() : t() === "reset-email" ? st() : t() === "reset-code" ? it() : Promise.resolve();
1993
2030
  }
1994
- function c() {
1995
- return console.log("signup"), D(""), L(!1), fetch(`${e.domain}/api/v1/users`, {
2031
+ function T() {
2032
+ return console.log("signup"), D(""), R(!1), fetch(`${e.domain}/api/v1/users`, {
1996
2033
  method: "POST",
1997
2034
  mode: "cors",
1998
2035
  cache: "no-cache",
@@ -2001,19 +2038,19 @@ ht("spartan-login", bu, (e) => {
2001
2038
  password: i(),
2002
2039
  sectorID: e.sector
2003
2040
  })
2004
- }).then((o) => {
2005
- if (o.ok)
2006
- return o.json();
2041
+ }).then((l) => {
2042
+ if (l.ok)
2043
+ return l.json();
2007
2044
  throw new Error(d.i18n("sa-error-creating-user"));
2008
- }).then((o) => {
2009
- if (console.log(o), Re())
2010
- return V(r(), o.enrollmentTransactionId || "");
2011
- L(!0), n(e.startMode);
2012
- }).catch((o) => {
2013
- L(!1), D(o.message), console.log(o);
2045
+ }).then((l) => {
2046
+ if (console.log(l), Le())
2047
+ return K(r(), l.enrollmentTransactionId || "");
2048
+ R(!0), n(e.startMode);
2049
+ }).catch((l) => {
2050
+ R(!1), D(l.message), console.log(l);
2014
2051
  });
2015
2052
  }
2016
- function m() {
2053
+ function S() {
2017
2054
  return console.log("webauthnLogin"), fetch(`${e.domain}/api/v1/login/webauthn/begin`, {
2018
2055
  method: "POST",
2019
2056
  mode: "cors",
@@ -2022,28 +2059,28 @@ ht("spartan-login", bu, (e) => {
2022
2059
  username: r(),
2023
2060
  sectorID: e.sector
2024
2061
  })
2025
- }).then((o) => {
2026
- if (o.ok)
2027
- return o.json();
2028
- throw o.status === 401 ? (n("password"), D(d.i18n("webauthn-not-enrolled")), new Error(d.i18n("webauthn-not-enrolled"))) : new Error(`${o.status} ${o.statusText}: Network response was not ok.`);
2029
- }).then((o) => {
2030
- console.log(o);
2031
- const g = Ka(o.CredentialAssertion);
2032
- return console.log("Parsed WebAuthn request options:", g), Ha(g).then((E) => {
2033
- const oe = JSON.stringify(E);
2034
- let Be = JSON.parse(oe);
2035
- return Be.transactionID = o.TransactionID, Be;
2062
+ }).then((l) => {
2063
+ if (l.ok)
2064
+ return l.json();
2065
+ throw l.status === 401 ? (n("password"), D(d.i18n("webauthn-not-enrolled")), new Error(d.i18n("webauthn-not-enrolled"))) : new Error(`${l.status} ${l.statusText}: Network response was not ok.`);
2066
+ }).then((l) => {
2067
+ console.log(l);
2068
+ const g = Ya(l.CredentialAssertion);
2069
+ return console.log("Parsed WebAuthn request options:", g), Qa(g).then((E) => {
2070
+ const ie = JSON.stringify(E);
2071
+ let _e = JSON.parse(ie);
2072
+ return _e.transactionID = l.TransactionID, _e;
2036
2073
  });
2037
- }).then((o) => fetch(`${e.domain}/api/v1/login/webauthn/finish`, {
2074
+ }).then((l) => fetch(`${e.domain}/api/v1/login/webauthn/finish`, {
2038
2075
  method: "POST",
2039
2076
  mode: "cors",
2040
2077
  cache: "no-cache",
2041
- body: JSON.stringify(o)
2042
- })).then(x).catch((o) => {
2043
- D(o.message), console.log(o);
2078
+ body: JSON.stringify(l)
2079
+ })).then(re).catch((l) => {
2080
+ D(l.message), console.log(l);
2044
2081
  });
2045
2082
  }
2046
- function O() {
2083
+ function te() {
2047
2084
  return console.log("password login"), fetch(e.domain + "/api/v1/login/password", {
2048
2085
  method: "post",
2049
2086
  mode: "cors",
@@ -2053,19 +2090,19 @@ ht("spartan-login", bu, (e) => {
2053
2090
  password: i(),
2054
2091
  sectorID: e.sector
2055
2092
  })
2056
- }).then(x);
2093
+ }).then(re);
2057
2094
  }
2058
- function x(o) {
2059
- return Promise.resolve(o).then((g) => {
2095
+ function re(l) {
2096
+ return Promise.resolve(l).then((g) => {
2060
2097
  if (g.ok)
2061
2098
  return g.json();
2062
2099
  throw g;
2063
2100
  }).then((g) => {
2064
2101
  if (console.log(g), localStorage.setItem("spartan-txid", g.transactionID), !g.token) {
2065
2102
  if (g.challengeType === "email_enrollment")
2066
- return V(r(), g.transactionID || "");
2103
+ return K(r(), g.transactionID || "");
2067
2104
  if (g.challengeType.indexOf("otp") !== -1)
2068
- return ee();
2105
+ return se();
2069
2106
  g.challengeType.indexOf("webauthn") !== -1 ? (n("webauthn"), D(d.i18n("sa-webauthn-required"))) : D(d.i18n("sa-unknown-challenge"));
2070
2107
  return;
2071
2108
  }
@@ -2078,16 +2115,16 @@ ht("spartan-login", bu, (e) => {
2078
2115
  transactionID: g.transactionID
2079
2116
  }
2080
2117
  });
2081
- _.getRootNode().host.dispatchEvent(E), B() !== "" && (window.location.href = B());
2118
+ _.getRootNode().host.dispatchEvent(E), k() !== "" && (window.location.href = k());
2082
2119
  }).catch((g) => g.json().then((E) => {
2083
2120
  console.log(E.message), D(E.message);
2084
2121
  }).catch((E) => {
2085
2122
  console.log(E);
2086
2123
  }));
2087
2124
  }
2088
- function ee() {
2089
- const o = localStorage.getItem("spartan-txid") || "";
2090
- return fetch(e.domain + `/api/v1/otp/${encodeURIComponent(r())}?transactionID=${encodeURIComponent(o)}&sectorID=${encodeURIComponent(e.sector)}`, {
2125
+ function se() {
2126
+ const l = localStorage.getItem("spartan-txid") || "";
2127
+ return fetch(e.domain + `/api/v1/otp/${encodeURIComponent(r())}?transactionID=${encodeURIComponent(l)}&sectorID=${encodeURIComponent(e.sector)}`, {
2091
2128
  method: "get",
2092
2129
  mode: "cors",
2093
2130
  cache: "no-cache"
@@ -2102,21 +2139,21 @@ ht("spartan-login", bu, (e) => {
2102
2139
  return;
2103
2140
  }
2104
2141
  if (E.length === 1)
2105
- return re(E[0].ID || "");
2106
- Fe(E), k(E[0].ID || ""), n("otp-pick"), D("");
2142
+ return ce(E[0].ID || "");
2143
+ ye(E), B(E[0].ID || ""), n("otp-pick"), D("");
2107
2144
  }).catch((g) => {
2108
2145
  D(g.message), console.log(g);
2109
2146
  });
2110
2147
  }
2111
- function re(o) {
2112
- return console.log("begin OTP, registrationID:", o), fetch(e.domain + "/api/v1/login/otp/begin", {
2148
+ function ce(l) {
2149
+ return console.log("begin OTP, registrationID:", l), fetch(e.domain + "/api/v1/login/otp/begin", {
2113
2150
  method: "post",
2114
2151
  mode: "cors",
2115
2152
  cache: "no-cache",
2116
2153
  body: JSON.stringify({
2117
2154
  username: r(),
2118
2155
  transactionID: localStorage.getItem("spartan-txid"),
2119
- registrationID: o,
2156
+ registrationID: l,
2120
2157
  sectorID: e.sector
2121
2158
  })
2122
2159
  }).then((g) => {
@@ -2129,21 +2166,21 @@ ht("spartan-login", bu, (e) => {
2129
2166
  D(g.message), console.log(g);
2130
2167
  });
2131
2168
  }
2132
- function se() {
2169
+ function ke() {
2133
2170
  return console.log("OTP login submit"), fetch(e.domain + "/api/v1/login/otp", {
2134
2171
  method: "post",
2135
2172
  mode: "cors",
2136
2173
  cache: "no-cache",
2137
2174
  body: JSON.stringify({
2138
2175
  username: r(),
2139
- password: l(),
2176
+ password: o(),
2140
2177
  transactionID: localStorage.getItem("spartan-txid"),
2141
2178
  sectorID: e.sector
2142
2179
  })
2143
- }).then(x);
2180
+ }).then(re);
2144
2181
  }
2145
- function fe() {
2146
- return console.log("begin password reset"), D(""), Z(!1), fetch(`${e.domain}/api/v1/password/reset/begin`, {
2182
+ function st() {
2183
+ return console.log("begin password reset"), D(""), Y(!1), fetch(`${e.domain}/api/v1/password/reset/begin`, {
2147
2184
  method: "POST",
2148
2185
  mode: "cors",
2149
2186
  cache: "no-cache",
@@ -2154,17 +2191,17 @@ ht("spartan-login", bu, (e) => {
2154
2191
  email: r(),
2155
2192
  sectorID: e.sector
2156
2193
  })
2157
- }).then((o) => {
2158
- if (o.ok)
2159
- return o.json();
2194
+ }).then((l) => {
2195
+ if (l.ok)
2196
+ return l.json();
2160
2197
  throw new Error(d.i18n("sa-reset-error"));
2161
- }).then((o) => {
2162
- console.log(o), D(d.i18n("sa-reset-email-sent")), G(""), J(""), n("reset-code");
2163
- }).catch((o) => {
2164
- D(o.message), console.log(o);
2198
+ }).then((l) => {
2199
+ console.log(l), D(d.i18n("sa-reset-email-sent")), H(""), V(""), n("reset-code");
2200
+ }).catch((l) => {
2201
+ D(l.message), console.log(l);
2165
2202
  });
2166
2203
  }
2167
- function $e() {
2204
+ function it() {
2168
2205
  return console.log("complete password reset"), D(""), fetch(`${e.domain}/api/v1/password/reset/complete`, {
2169
2206
  method: "POST",
2170
2207
  mode: "cors",
@@ -2174,21 +2211,21 @@ ht("spartan-login", bu, (e) => {
2174
2211
  },
2175
2212
  body: JSON.stringify({
2176
2213
  email: r(),
2177
- code: ue().toUpperCase().trim(),
2178
- newPassword: te(),
2214
+ code: oe().toUpperCase().trim(),
2215
+ newPassword: ne(),
2179
2216
  sectorID: e.sector
2180
2217
  })
2181
- }).then((o) => {
2182
- if (o.ok)
2183
- return o.json();
2184
- throw o.status === 400 ? new Error(d.i18n("sa-reset-error-code")) : new Error(d.i18n("sa-reset-error"));
2185
- }).then((o) => {
2186
- console.log(o), Z(!0), G(""), J(""), u(""), n(e.startMode);
2187
- }).catch((o) => {
2188
- D(o.message), console.log(o);
2218
+ }).then((l) => {
2219
+ if (l.ok)
2220
+ return l.json();
2221
+ throw l.status === 400 ? new Error(d.i18n("sa-reset-error-code")) : new Error(d.i18n("sa-reset-error"));
2222
+ }).then((l) => {
2223
+ console.log(l), Y(!0), H(""), V(""), u(""), n(e.startMode);
2224
+ }).catch((l) => {
2225
+ D(l.message), console.log(l);
2189
2226
  });
2190
2227
  }
2191
- async function nt() {
2228
+ async function Ge() {
2192
2229
  if (D(""), !xe() || xe().trim().length === 0) {
2193
2230
  D(d.i18n("sa-invite-error-otp"));
2194
2231
  return;
@@ -2197,8 +2234,8 @@ ht("spartan-login", bu, (e) => {
2197
2234
  D("Password must be at least 8 characters");
2198
2235
  return;
2199
2236
  }
2200
- const o = Oe();
2201
- if (!o) {
2237
+ const l = Ie();
2238
+ if (!l) {
2202
2239
  D("Missing invitation information");
2203
2240
  return;
2204
2241
  }
@@ -2210,7 +2247,7 @@ ht("spartan-login", bu, (e) => {
2210
2247
  "Content-Type": "application/json"
2211
2248
  },
2212
2249
  body: JSON.stringify({
2213
- sub: o,
2250
+ sub: l,
2214
2251
  otp: xe().toUpperCase().trim(),
2215
2252
  password: A(),
2216
2253
  sectorID: e.sector
@@ -2222,22 +2259,22 @@ ht("spartan-login", bu, (e) => {
2222
2259
  }
2223
2260
  if (g.ok) {
2224
2261
  history.replaceState({}, "", window.location.pathname);
2225
- const E = await g.json().catch(() => ({})), oe = _.getRootNode().host;
2226
- E.token ? (localStorage.setItem("spartan-token", E.token), oe.dispatchEvent(new CustomEvent("spartan-login", {
2262
+ const E = await g.json().catch(() => ({})), ie = _.getRootNode().host;
2263
+ E.token ? (localStorage.setItem("spartan-token", E.token), ie.dispatchEvent(new CustomEvent("spartan-login", {
2227
2264
  bubbles: !0,
2228
2265
  cancelable: !0,
2229
2266
  detail: {
2230
2267
  token: E.token
2231
2268
  }
2232
- })), B() !== "" ? window.location.href = B() : e.redirect !== "" ? window.location.href = e.redirect : (R(!1), Ie(""), ve(""), Se(""), v(""), n(e.startMode), P(), T())) : (R(!0), oe.dispatchEvent(new CustomEvent("spartan-invite-complete", {
2269
+ })), k() !== "" ? window.location.href = k() : e.redirect !== "" ? window.location.href = e.redirect : (j(!1), Pe(""), Ce(""), Se(""), v(""), n(e.startMode), q(), N())) : (j(!0), ie.dispatchEvent(new CustomEvent("spartan-invite-complete", {
2233
2270
  bubbles: !0,
2234
2271
  cancelable: !0,
2235
2272
  detail: {
2236
- sub: o,
2273
+ sub: l,
2237
2274
  success: !0
2238
2275
  }
2239
2276
  })), setTimeout(() => {
2240
- B() !== "" ? window.location.href = B() : e.redirect !== "" ? window.location.href = e.redirect : (R(!1), Ie(""), ve(""), Se(""), v(""), n(e.startMode), P(), T());
2277
+ k() !== "" ? window.location.href = k() : e.redirect !== "" ? window.location.href = e.redirect : (j(!1), Pe(""), Ce(""), Se(""), v(""), n(e.startMode), q(), N());
2241
2278
  }, 2e3));
2242
2279
  } else {
2243
2280
  const E = await g.json().catch(() => ({}));
@@ -2245,172 +2282,178 @@ ht("spartan-login", bu, (e) => {
2245
2282
  }
2246
2283
  }
2247
2284
  return (() => {
2248
- var o = Qa(), g = o.firstChild, E = g.nextSibling, oe = E.nextSibling, Be = _;
2249
- return typeof Be == "function" ? zt(Be, o) : _ = o, o.addEventListener("submit", (M) => {
2250
- if (M.preventDefault(), b()) return;
2251
- ge(!0), (t() === "sign-up" ? c() : t() === "signup-verify" ? q() : t() === "invite" ? Promise.resolve(nt()) : U()).finally(() => ge(!1));
2252
- }), f(E, z), f(oe, (() => {
2253
- var M = p(() => t() === "reset-email" || t() === "reset-code");
2254
- return () => M() ? d.i18n("sa-reset-password") : p(() => t() === "signup-verify" || t() === "signup-webauthn")() ? d.i18n("sa-signup-mfa-title") : p(() => t() === "invite")() ? d.i18n("sa-complete-invite") : d.i18n("sa-login");
2255
- })()), f(o, $ && (() => {
2256
- var M = eu();
2257
- return f(M, $), M;
2258
- })(), null), f(o, (() => {
2259
- var M = p(() => !!Ee());
2260
- return () => M() && (() => {
2261
- var a = it();
2285
+ var l = su(), g = l.firstChild, E = g.firstChild, ie = E.nextSibling, _e = ie.nextSibling, pe = _;
2286
+ return typeof pe == "function" ? jt(pe, g) : _ = g, g.addEventListener("submit", (W) => {
2287
+ if (W.preventDefault(), b()) return;
2288
+ me(!0), (t() === "sign-up" ? T() : t() === "signup-verify" ? le() : t() === "invite" ? Promise.resolve(Ge()) : m()).finally(() => me(!1));
2289
+ }), f(ie, z), f(_e, (() => {
2290
+ var W = h(() => t() === "reset-email" || t() === "reset-code");
2291
+ return () => W() ? d.i18n("sa-reset-password") : h(() => t() === "signup-verify" || t() === "signup-webauthn")() ? d.i18n("sa-signup-mfa-title") : h(() => t() === "invite")() ? d.i18n("sa-complete-invite") : d.i18n("sa-login");
2292
+ })()), f(g, $ && (() => {
2293
+ var W = iu();
2294
+ return f(W, $), W;
2295
+ })(), null), f(g, (() => {
2296
+ var W = h(() => !!Fe());
2297
+ return () => W() && (() => {
2298
+ var a = ot();
2262
2299
  return f(a, () => d.i18n("sa-signup-complete")), a;
2263
2300
  })();
2264
- })(), null), f(o, (() => {
2265
- var M = p(() => !!W());
2266
- return () => M() && (() => {
2267
- var a = it();
2301
+ })(), null), f(g, (() => {
2302
+ var W = h(() => !!Z());
2303
+ return () => W() && (() => {
2304
+ var a = ot();
2268
2305
  return f(a, () => d.i18n("sa-reset-success")), a;
2269
2306
  })();
2270
- })(), null), f(o, (() => {
2271
- var M = p(() => t() === "invite");
2272
- return () => M() && [p(() => p(() => !!ze())() && (() => {
2273
- var a = ru();
2274
- return f(a, ze), a;
2275
- })()), p(() => p(() => !!S())() && (() => {
2276
- var a = su();
2307
+ })(), null), f(g, (() => {
2308
+ var W = h(() => t() === "invite");
2309
+ return () => W() && [h(() => h(() => !!Ne())() && (() => {
2310
+ var a = ou();
2311
+ return f(a, Ne), a;
2312
+ })()), h(() => h(() => !!x())() && (() => {
2313
+ var a = lu();
2277
2314
  return f(a, () => d.i18n("sa-invite-success")), a;
2278
2315
  })()), (() => {
2279
- var a = tu();
2280
- return a.$$input = (h) => Se(h.currentTarget.value), y((h) => {
2281
- var N = d.i18n("sa-invite-otp"), Ce = b() || S();
2282
- return N !== h.e && le(a, "placeholder", h.e = N), Ce !== h.t && (a.disabled = h.t = Ce), h;
2316
+ var a = au();
2317
+ return a.$$input = (p) => Se(p.currentTarget.value), y((p) => {
2318
+ var P = d.i18n("sa-invite-otp"), we = b() || x();
2319
+ return P !== p.e && de(a, "placeholder", p.e = P), we !== p.t && (a.disabled = p.t = we), p;
2283
2320
  }, {
2284
2321
  e: void 0,
2285
2322
  t: void 0
2286
2323
  }), y(() => a.value = xe()), a;
2287
2324
  })(), (() => {
2288
- var a = Et();
2325
+ var a = $t();
2289
2326
  return f(a, () => d.i18n("sa-invite-otp-hint")), a;
2290
2327
  })(), (() => {
2291
- var a = nu();
2292
- return a.$$input = (h) => v(h.currentTarget.value), y((h) => {
2293
- var N = d.i18n("sa-invite-password"), Ce = b() || S();
2294
- return N !== h.e && le(a, "placeholder", h.e = N), Ce !== h.t && (a.disabled = h.t = Ce), h;
2328
+ var a = uu();
2329
+ return a.$$input = (p) => v(p.currentTarget.value), y((p) => {
2330
+ var P = d.i18n("sa-invite-password"), we = b() || x();
2331
+ return P !== p.e && de(a, "placeholder", p.e = P), we !== p.t && (a.disabled = p.t = we), p;
2295
2332
  }, {
2296
2333
  e: void 0,
2297
2334
  t: void 0
2298
2335
  }), y(() => a.value = A()), a;
2299
2336
  })(), (() => {
2300
- var a = Et();
2337
+ var a = $t();
2301
2338
  return f(a, () => d.i18n("sa-invite-password-hint")), a;
2302
2339
  })(), (() => {
2303
- var a = Ft();
2340
+ var a = kt();
2304
2341
  return f(a, (() => {
2305
- var h = p(() => !!b());
2306
- return () => h() ? d.i18n("sa-invite-completing") : d.i18n("sa-invite-submit");
2307
- })()), y(() => a.disabled = b() || S()), a;
2342
+ var p = h(() => !!b());
2343
+ return () => p() ? d.i18n("sa-invite-completing") : d.i18n("sa-invite-submit");
2344
+ })()), y(() => a.disabled = b() || x()), a;
2308
2345
  })()];
2309
- })(), null), f(o, (() => {
2310
- var M = p(() => t() !== "invite");
2311
- return () => M() && [(() => {
2312
- var a = iu();
2313
- return a.addEventListener("change", (h) => s(h.currentTarget.value)), a.$$input = (h) => s(h.currentTarget.value), y((h) => {
2314
- var N = d.i18n("sa-username"), Ce = t() === "otp" || t() === "otp-pick" || t() === "reset-code" || t() === "signup-verify" || t() === "signup-webauthn";
2315
- return N !== h.e && le(a, "placeholder", h.e = N), Ce !== h.t && (a.disabled = h.t = Ce), h;
2346
+ })(), null), f(g, (() => {
2347
+ var W = h(() => t() !== "invite");
2348
+ return () => W() && [(() => {
2349
+ var a = cu();
2350
+ return a.addEventListener("change", (p) => s(p.currentTarget.value)), a.$$input = (p) => s(p.currentTarget.value), y((p) => {
2351
+ var P = d.i18n("sa-username"), we = t() === "otp" || t() === "otp-pick" || t() === "reset-code" || t() === "signup-verify" || t() === "signup-webauthn";
2352
+ return P !== p.e && de(a, "placeholder", p.e = P), we !== p.t && (a.disabled = p.t = we), p;
2316
2353
  }, {
2317
2354
  e: void 0,
2318
2355
  t: void 0
2319
2356
  }), y(() => a.value = r()), a;
2320
- })(), p(() => p(() => t() !== "sign-up" && t() !== "signup-verify" && t() !== "signup-webauthn")() && [p(() => p(() => t() === "password")() && (() => {
2321
- var a = au();
2322
- return a.addEventListener("change", (h) => u(h.currentTarget.value)), a.$$input = (h) => u(h.currentTarget.value), y(() => le(a, "placeholder", d.i18n("sa-password"))), y(() => a.value = i()), a;
2323
- })()), p(() => p(() => t() === "webauthn")() && it()), p(() => p(() => t() === "otp-pick")() && [(() => {
2324
- var a = at();
2357
+ })(), h(() => h(() => t() !== "sign-up" && t() !== "signup-verify" && t() !== "signup-webauthn")() && [h(() => h(() => t() === "password")() && (() => {
2358
+ var a = du();
2359
+ return a.addEventListener("change", (p) => u(p.currentTarget.value)), a.$$input = (p) => u(p.currentTarget.value), y(() => de(a, "placeholder", d.i18n("sa-password"))), y(() => a.value = i()), a;
2360
+ })()), h(() => h(() => t() === "webauthn")() && ot()), h(() => h(() => t() === "otp-pick")() && [(() => {
2361
+ var a = lt();
2325
2362
  return f(a, () => d.i18n("sa-otp-choose")), a;
2326
2363
  })(), (() => {
2327
- var a = uu();
2328
- return a.addEventListener("change", (h) => k(h.currentTarget.value)), f(a, () => we().map((h) => (() => {
2329
- var N = ou(), Ce = N.firstChild, Dt = Ce.nextSibling;
2330
- return Dt.nextSibling, f(N, () => h.DisplayName || h.ID, Ce), f(N, () => h.Type, Dt), y(() => N.value = h.ID), N;
2331
- })())), y(() => a.value = Ae()), a;
2332
- })()]), p(() => p(() => t() === "otp")() && (() => {
2333
- var a = lu();
2334
- return a.$$input = (h) => C(h.currentTarget.value), y(() => le(a, "placeholder", d.i18n("sa-code"))), y(() => a.value = l()), a;
2335
- })()), p(() => p(() => t() === "reset-code")() && [(() => {
2336
- var a = yt();
2337
- return a.$$input = (h) => G(h.currentTarget.value), y(() => le(a, "placeholder", d.i18n("sa-reset-code"))), y(() => a.value = ue()), a;
2364
+ var a = fu();
2365
+ return a.addEventListener("change", (p) => B(p.currentTarget.value)), f(a, () => Ae().map((p) => (() => {
2366
+ var P = hu(), we = P.firstChild, bt = we.nextSibling;
2367
+ return bt.nextSibling, f(P, () => p.DisplayName || p.ID, we), f(P, () => p.Type, bt), y(() => P.value = p.ID), P;
2368
+ })())), y(() => a.value = Ee()), a;
2369
+ })()]), h(() => h(() => t() === "otp")() && (() => {
2370
+ var a = pu();
2371
+ return a.$$input = (p) => C(p.currentTarget.value), y(() => de(a, "placeholder", d.i18n("sa-code"))), y(() => a.value = o()), a;
2372
+ })()), h(() => h(() => t() === "reset-code")() && [(() => {
2373
+ var a = Bt();
2374
+ return a.$$input = (p) => H(p.currentTarget.value), y(() => de(a, "placeholder", d.i18n("sa-reset-code"))), y(() => a.value = oe()), a;
2338
2375
  })(), (() => {
2339
- var a = $t();
2340
- return a.$$input = (h) => J(h.currentTarget.value), y(() => le(a, "placeholder", d.i18n("sa-new-password"))), y(() => a.value = te()), a;
2341
- })()]), p(() => p(() => t() === "password" || t() === "webauthn")() && (() => {
2342
- var a = cu(), h = a.firstChild, N = h.nextSibling;
2343
- return N.firstChild, a.$$click = () => n(t() === "password" ? "webauthn" : "password"), f(N, () => d.i18n("sa-use-password"), null), y(() => h.checked = t() === "password"), a;
2344
- })())]), p(() => p(() => t() === "sign-up")() && (() => {
2345
- var a = $t();
2346
- return a.addEventListener("change", (h) => u(h.currentTarget.value)), a.$$input = (h) => u(h.currentTarget.value), y(() => le(a, "placeholder", d.i18n("sa-password"))), y(() => a.value = i()), a;
2347
- })()), p(() => p(() => t() === "signup-verify")() && [(() => {
2348
- var a = at();
2376
+ var a = xt();
2377
+ return a.$$input = (p) => V(p.currentTarget.value), y(() => de(a, "placeholder", d.i18n("sa-new-password"))), y(() => a.value = ne()), a;
2378
+ })()]), h(() => h(() => t() === "password" || t() === "webauthn")() && (() => {
2379
+ var a = Du(), p = a.firstChild, P = p.nextSibling;
2380
+ return P.firstChild, a.$$click = () => n(t() === "password" ? "webauthn" : "password"), f(P, () => d.i18n("sa-use-password"), null), y(() => p.checked = t() === "password"), a;
2381
+ })())]), h(() => h(() => t() === "sign-up")() && (() => {
2382
+ var a = xt();
2383
+ return a.addEventListener("change", (p) => u(p.currentTarget.value)), a.$$input = (p) => u(p.currentTarget.value), y(() => de(a, "placeholder", d.i18n("sa-password"))), y(() => a.value = i()), a;
2384
+ })()), h(() => h(() => t() === "signup-verify")() && [(() => {
2385
+ var a = lt();
2349
2386
  return f(a, () => d.i18n("sa-signup-verify-prompt")), a;
2350
2387
  })(), (() => {
2351
- var a = yt();
2352
- return a.$$input = (h) => C(h.currentTarget.value), y(() => le(a, "placeholder", d.i18n("sa-code"))), y(() => a.value = l()), a;
2353
- })()]), p(() => p(() => t() === "signup-webauthn")() && (() => {
2354
- var a = at();
2388
+ var a = Bt();
2389
+ return a.$$input = (p) => C(p.currentTarget.value), y(() => de(a, "placeholder", d.i18n("sa-code"))), y(() => a.value = o()), a;
2390
+ })()]), h(() => h(() => t() === "signup-webauthn")() && (() => {
2391
+ var a = lt();
2355
2392
  return f(a, () => d.i18n("sa-signup-webauthn-prompt")), a;
2356
- })()), p(() => p(() => t() !== "signup-webauthn")() && (() => {
2357
- var a = Ft();
2393
+ })()), h(() => h(() => t() !== "signup-webauthn")() && (() => {
2394
+ var a = kt();
2358
2395
  return f(a, (() => {
2359
- var h = p(() => !!b());
2360
- return () => h() ? d.i18n("sa-loading") : p(() => t() === "sign-up")() ? d.i18n("sa-signup") : p(() => t() === "otp-pick")() ? d.i18n("sa-otp-send-code") : p(() => t() === "otp")() ? d.i18n("sa-otp-verify") : p(() => t() === "reset-email")() ? d.i18n("sa-otp-send-code") : p(() => t() === "reset-code")() ? d.i18n("sa-reset-submit") : p(() => t() === "signup-verify")() ? d.i18n("sa-otp-verify") : d.i18n("sa-login");
2396
+ var p = h(() => !!b());
2397
+ return () => p() ? d.i18n("sa-loading") : h(() => t() === "sign-up")() ? d.i18n("sa-signup") : h(() => t() === "otp-pick")() ? d.i18n("sa-otp-send-code") : h(() => t() === "otp")() ? d.i18n("sa-otp-verify") : h(() => t() === "reset-email")() ? d.i18n("sa-otp-send-code") : h(() => t() === "reset-code")() ? d.i18n("sa-reset-submit") : h(() => t() === "signup-verify")() ? d.i18n("sa-otp-verify") : d.i18n("sa-login");
2361
2398
  })()), y(() => a.disabled = b()), a;
2362
- })()), p(() => p(() => t() === "signup-webauthn")() && [(() => {
2363
- var a = du();
2364
- return a.$$click = () => H(), f(a, (() => {
2365
- var h = p(() => !!b());
2366
- return () => h() ? d.i18n("sa-loading") : d.i18n("sa-signup-webauthn-setup");
2399
+ })()), h(() => h(() => t() === "signup-webauthn")() && [(() => {
2400
+ var a = gu();
2401
+ return a.$$click = () => J(), f(a, (() => {
2402
+ var p = h(() => !!b());
2403
+ return () => p() ? d.i18n("sa-loading") : d.i18n("sa-signup-webauthn-setup");
2367
2404
  })()), y(() => a.disabled = b()), a;
2368
2405
  })(), (() => {
2369
- var a = Ke();
2370
- return a.$$click = () => ne(), f(a, () => d.i18n("sa-signup-webauthn-done")), a;
2371
- })()]), p(() => p(() => t() === "password")() && (() => {
2372
- var a = Ke();
2406
+ var a = He();
2407
+ return a.$$click = () => c(), f(a, () => d.i18n("sa-signup-webauthn-done")), a;
2408
+ })()]), h(() => h(() => t() === "password")() && (() => {
2409
+ var a = He();
2373
2410
  return a.$$click = () => {
2374
- D(""), Z(!1), n("reset-email");
2411
+ D(""), Y(!1), n("reset-email");
2375
2412
  }, f(a, () => d.i18n("sa-forgot-password")), a;
2376
- })()), p(() => p(() => t() === "reset-email" || t() === "reset-code")() && (() => {
2377
- var a = Ke();
2413
+ })()), h(() => h(() => t() === "reset-email" || t() === "reset-code")() && (() => {
2414
+ var a = He();
2378
2415
  return a.$$click = () => {
2379
- D(""), G(""), J(""), n(e.startMode);
2416
+ D(""), H(""), V(""), n(e.startMode);
2380
2417
  }, f(a, () => d.i18n("sa-back")), a;
2381
- })()), p(() => p(() => !!(ae() && t() !== "reset-email" && t() !== "reset-code" && t() !== "signup-verify" && t() !== "signup-webauthn"))() && (() => {
2382
- var a = Ke();
2418
+ })()), h(() => h(() => !!(ue() && t() !== "reset-email" && t() !== "reset-code" && t() !== "signup-verify" && t() !== "signup-webauthn"))() && (() => {
2419
+ var a = He();
2383
2420
  return a.$$click = () => t() === "sign-up" ? n(e.startMode) : n("sign-up"), f(a, (() => {
2384
- var h = p(() => t() === "sign-up");
2385
- return () => h() ? d.i18n("sa-back") : d.i18n("sa-signup");
2421
+ var p = h(() => t() === "sign-up");
2422
+ return () => p() ? d.i18n("sa-back") : d.i18n("sa-signup");
2386
2423
  })()), a;
2387
- })()), p(() => p(() => X().length > 0 && (t() === "password" || t() === "webauthn" || t() === "sign-up"))() && [(() => {
2388
- var a = fu(), h = a.firstChild;
2389
- return f(h, () => d.i18n("sa-or")), a;
2390
- })(), p(() => X().map((a) => (() => {
2391
- var h = hu();
2392
- return h.$$click = () => Q(a.provider), f(h, (() => {
2393
- var N = p(() => a.provider === "google");
2394
- return () => N() && pu();
2395
- })(), null), f(h, (() => {
2396
- var N = p(() => a.provider === "github");
2397
- return () => N() && Du();
2398
- })(), null), f(h, (() => {
2399
- var N = p(() => a.provider === "apple");
2400
- return () => N() && gu();
2401
- })(), null), f(h, (() => {
2402
- var N = p(() => a.provider === "oidc");
2403
- return () => N() && mu();
2404
- })(), null), f(h, (() => {
2405
- var N = p(() => a.provider === "google");
2406
- return () => N() ? d.i18n("sa-social-google") : p(() => a.provider === "github")() ? d.i18n("sa-social-github") : p(() => a.provider === "apple")() ? d.i18n("sa-social-apple") : d.i18n("sa-social-oidc");
2407
- })(), null), y(() => h.disabled = !!pe() || b()), h;
2424
+ })()), h(() => h(() => ee().length > 0 && (t() === "password" || t() === "webauthn" || t() === "sign-up"))() && [(() => {
2425
+ var a = mu(), p = a.firstChild;
2426
+ return f(p, () => d.i18n("sa-or")), a;
2427
+ })(), h(() => ee().map((a) => (() => {
2428
+ var p = bu();
2429
+ return p.$$click = () => U(a.provider), f(p, (() => {
2430
+ var P = h(() => a.provider === "google");
2431
+ return () => P() && vu();
2432
+ })(), null), f(p, (() => {
2433
+ var P = h(() => a.provider === "github");
2434
+ return () => P() && Cu();
2435
+ })(), null), f(p, (() => {
2436
+ var P = h(() => a.provider === "apple");
2437
+ return () => P() && wu();
2438
+ })(), null), f(p, (() => {
2439
+ var P = h(() => a.provider === "oidc");
2440
+ return () => P() && Au();
2441
+ })(), null), f(p, (() => {
2442
+ var P = h(() => a.provider === "google");
2443
+ return () => P() ? d.i18n("sa-social-google") : h(() => a.provider === "github")() ? d.i18n("sa-social-github") : h(() => a.provider === "apple")() ? d.i18n("sa-social-apple") : d.i18n("sa-social-oidc");
2444
+ })(), null), y(() => p.disabled = !!he() || b()), p;
2408
2445
  })()))])];
2409
- })(), null), o;
2446
+ })(), null), f(l, (() => {
2447
+ var W = h(() => !!L());
2448
+ return () => W() && (() => {
2449
+ var a = Eu(), p = a.firstChild;
2450
+ return p._$owner = sn(), f(p, () => d.i18n("sa-loading")), a;
2451
+ })();
2452
+ })(), null), l;
2410
2453
  })();
2411
2454
  });
2412
- ft(["input", "click"]);
2413
- var vu = /* @__PURE__ */ F(`<div class=container><style>.container {
2455
+ Dt(["input", "click"]);
2456
+ var yu = /* @__PURE__ */ F(`<div class=container><style>.container {
2414
2457
  background-color: #ffffff;
2415
2458
  border-radius: 10px;
2416
2459
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
@@ -2588,8 +2631,8 @@ var vu = /* @__PURE__ */ F(`<div class=container><style>.container {
2588
2631
  .modal-content .btn.verify:hover {
2589
2632
  background-color: #0056b3;
2590
2633
  }
2591
- </style><style></style><h1 class=header>`), Bt = /* @__PURE__ */ F("<span class=error-message>"), Cu = /* @__PURE__ */ F("<div class=section><h2></h2><div class=security-keys>"), wu = /* @__PURE__ */ F('<div class=key-item><span></span><button class="btn remove">'), kt = /* @__PURE__ */ F("<span>"), Au = /* @__PURE__ */ F("<div class=section><div class=security-keys>"), Eu = /* @__PURE__ */ F('<button class="btn add">+ '), Fu = /* @__PURE__ */ F('<div class=add-key-form><div class=add-key-item><label for=keyName style=display:none;></label><input id=keyName type=text><button class="btn remove"></button><button class="btn add">'), yu = /* @__PURE__ */ F("<div class=section><h2></h2><table><thead><tr><th></th><th></th><th></th></tr></thead><tbody>"), $u = /* @__PURE__ */ F('<tr class=mfa-list-item><td></td><td></td><td><button class="btn remove">'), Bu = /* @__PURE__ */ F('<span>&nbsp; <button class="btn validate">'), ku = /* @__PURE__ */ F('<div class=section><div class=mfa-manage><button class="btn add">+ '), xu = /* @__PURE__ */ F('<div class=section><h2></h2><div class=mfa-manage><div class=mfa-item><label for=email></label><input id=email type=text><button class="btn add"></button></div><div class=mfa-item><label for=phone></label><input id=phone type=text><button class="btn add"></button></div><div class=mfa-item><button class="btn remove">'), Su = /* @__PURE__ */ F('<div class=modal id=mfaModal><div class=modal-content><span class=close id=closeModal>&times;</span><h2>MFA Verification</h2><p>Please enter the verification code sent to your email or phone:</p><input type=text id=mfaCode placeholder="Enter verification code"><button class="btn verify"id=verifyMfa>Verify');
2592
- const _u = {
2634
+ </style><style></style><h1 class=header>`), St = /* @__PURE__ */ F("<span class=error-message>"), $u = /* @__PURE__ */ F("<div class=section><h2></h2><div class=security-keys>"), ku = /* @__PURE__ */ F('<div class=key-item><span></span><button class="btn remove">'), _t = /* @__PURE__ */ F("<span>"), Bu = /* @__PURE__ */ F("<div class=section><div class=security-keys>"), xu = /* @__PURE__ */ F('<button class="btn add">+ '), Su = /* @__PURE__ */ F('<div class=add-key-form><div class=add-key-item><label for=keyName style=display:none;></label><input id=keyName type=text><button class="btn remove"></button><button class="btn add">'), _u = /* @__PURE__ */ F("<div class=section><h2></h2><table><thead><tr><th></th><th></th><th></th></tr></thead><tbody>"), Tu = /* @__PURE__ */ F('<tr class=mfa-list-item><td></td><td></td><td><button class="btn remove">'), Ou = /* @__PURE__ */ F('<span>&nbsp; <button class="btn validate">'), Iu = /* @__PURE__ */ F('<div class=section><div class=mfa-manage><button class="btn add">+ '), Pu = /* @__PURE__ */ F('<div class=section><h2></h2><div class=mfa-manage><div class=mfa-item><label for=email></label><input id=email type=text><button class="btn add"></button></div><div class=mfa-item><label for=phone></label><input id=phone type=text><button class="btn add"></button></div><div class=mfa-item><button class="btn remove">'), zu = /* @__PURE__ */ F('<div class=modal id=mfaModal><div class=modal-content><span class=close id=closeModal>&times;</span><h2>MFA Verification</h2><p>Please enter the verification code sent to your email or phone:</p><input type=text id=mfaCode placeholder="Enter verification code"><button class="btn verify"id=verifyMfa>Verify');
2635
+ const Nu = {
2593
2636
  domain: "http://127.0.0.1:11000",
2594
2637
  sector: "0ad5c3e5-0186-4557-8b32-4b36f247bf09",
2595
2638
  // defaults to the admin sector
@@ -2599,49 +2642,49 @@ const _u = {
2599
2642
  redirect: "/",
2600
2643
  redirectOnUnauthenticated: !0
2601
2644
  };
2602
- ht("spartan-account-settings", _u, (e) => {
2645
+ gt("spartan-account-settings", Nu, (e) => {
2603
2646
  w(""), w("");
2604
- const [t, n] = w(""), [r, s] = w(""), [i, u] = w(""), [l] = w(e.showWebAuthn), [C, $] = w(!1), [D, B] = w(!1), [ae, de] = w(!1), [Ee, L] = w(!1), [W, Z] = w(!1), [ue, G] = w([]), [te, J] = w([]), [we, Fe] = w(""), [Ae, k] = w(""), [X, ye] = w(""), [pe, De] = w(""), b = pt(e.locale);
2605
- let ge;
2647
+ const [t, n] = w(""), [r, s] = w(""), [i, u] = w(""), [o] = w(e.showWebAuthn), [C, $] = w(!1), [D, k] = w(!1), [ue, fe] = w(!1), [Fe, R] = w(!1), [Z, Y] = w(!1), [oe, H] = w([]), [ne, V] = w([]), [Ae, ye] = w(""), [Ee, B] = w(""), [ee, $e] = w(""), [he, ge] = w(""), b = mt(e.locale);
2648
+ let me;
2606
2649
  try {
2607
- ge = e.styles;
2650
+ me = e.styles;
2608
2651
  } catch {
2609
- ge = "";
2652
+ me = "";
2610
2653
  }
2611
- ct(async () => {
2612
- if (Wt())
2613
- B(!0), s("");
2654
+ ht(async () => {
2655
+ if (Xt())
2656
+ k(!0), s("");
2614
2657
  else {
2615
2658
  if (e.redirectOnUnauthenticated) {
2616
2659
  window.location.href = e.redirect;
2617
2660
  return;
2618
2661
  }
2619
- B(!1), s(b.i18n("not-authenticated"));
2662
+ k(!1), s(b.i18n("not-authenticated"));
2620
2663
  }
2621
- Re().then((v) => {
2664
+ Le().then((v) => {
2622
2665
  console.log(v);
2623
- }), await Te(), ve().then((v) => {
2624
- J(v.registrations);
2666
+ }), await Oe(), Ce().then((v) => {
2667
+ V(v.registrations);
2625
2668
  });
2626
2669
  });
2627
- async function Re() {
2628
- return await (await fetch(`${e.domain}/api/v1/users/self`, me("get"))).json();
2670
+ async function Le() {
2671
+ return await (await fetch(`${e.domain}/api/v1/users/self`, be("get"))).json();
2629
2672
  }
2630
- function me(A = "get") {
2673
+ function be(A = "get") {
2631
2674
  return {
2632
2675
  method: A,
2633
2676
  mode: "cors",
2634
2677
  cache: "no-cache",
2635
2678
  headers: {
2636
2679
  "Content-Type": "application",
2637
- Authorization: `bearer ${Ya()}`
2680
+ Authorization: `bearer ${nu()}`
2638
2681
  }
2639
2682
  };
2640
2683
  }
2641
- function Pe() {
2642
- if (W()) return;
2643
- Z(!0);
2644
- let A = me("post");
2684
+ function ze() {
2685
+ if (Z()) return;
2686
+ Y(!0);
2687
+ let A = be("post");
2645
2688
  A.body = JSON.stringify({
2646
2689
  keyName: t(),
2647
2690
  sectorID: e.sector
@@ -2649,36 +2692,36 @@ ht("spartan-account-settings", _u, (e) => {
2649
2692
  if (v.status === 200)
2650
2693
  return v.json();
2651
2694
  throw v;
2652
- }).then((v) => (console.log(v), Le(v))).catch((v) => {
2653
- v.json ? v.json().then((S) => {
2654
- s(S.message);
2695
+ }).then((v) => (console.log(v), qe(v))).catch((v) => {
2696
+ v.json ? v.json().then((x) => {
2697
+ s(x.message);
2655
2698
  }) : s(v);
2656
2699
  }).finally(() => {
2657
- Z(!1);
2700
+ Y(!1);
2658
2701
  });
2659
2702
  }
2660
- async function Le(A) {
2703
+ async function qe(A) {
2661
2704
  try {
2662
- const v = Gt(A.Options);
2705
+ const v = Zt(A.Options);
2663
2706
  console.log("Parsed WebAuthn creation options:", v);
2664
- const S = await Ht(v), R = JSON.stringify(S);
2665
- let d = JSON.parse(R);
2707
+ const x = await Yt(v), j = JSON.stringify(x);
2708
+ let d = JSON.parse(j);
2666
2709
  d.transactionID = A.TransactionID;
2667
- let _ = me("post");
2710
+ let _ = be("post");
2668
2711
  _.body = JSON.stringify(d);
2669
- const z = await fetch(`${e.domain}/api/v1/webauthn/registration/finish`, _);
2670
- if (z.status !== 200) {
2671
- const P = await z.json();
2672
- s(P.message);
2712
+ const I = await fetch(`${e.domain}/api/v1/webauthn/registration/finish`, _);
2713
+ if (I.status !== 200) {
2714
+ const z = await I.json();
2715
+ s(z.message);
2673
2716
  return;
2674
2717
  }
2675
- $(!1), n(""), Te();
2718
+ $(!1), n(""), Oe();
2676
2719
  } catch (v) {
2677
2720
  console.error("WebAuthn registration error:", v), s((v == null ? void 0 : v.message) || String(v));
2678
2721
  }
2679
2722
  }
2680
- async function qe(A) {
2681
- let v = me("delete");
2723
+ async function Ue(A) {
2724
+ let v = be("delete");
2682
2725
  v.body = JSON.stringify({
2683
2726
  ID: A
2684
2727
  });
@@ -2687,70 +2730,70 @@ ht("spartan-account-settings", _u, (e) => {
2687
2730
  s(b.i18n("error-webauthn-remove"));
2688
2731
  return;
2689
2732
  }
2690
- Te();
2691
- } catch (S) {
2692
- console.error(S), s(b.i18n("error-webauthn-remove"));
2733
+ Oe();
2734
+ } catch (x) {
2735
+ console.error(x), s(b.i18n("error-webauthn-remove"));
2693
2736
  return;
2694
2737
  }
2695
2738
  }
2696
- async function Te() {
2697
- let A = me("get");
2739
+ async function Oe() {
2740
+ let A = be("get");
2698
2741
  try {
2699
- const S = await (await fetch(`${e.domain}/api/v1/webauthn/registration/list`, A)).json();
2700
- G(S.registrations || []);
2742
+ const x = await (await fetch(`${e.domain}/api/v1/webauthn/registration/list`, A)).json();
2743
+ H(x.registrations || []);
2701
2744
  } catch (v) {
2702
- console.error(v), G([]);
2745
+ console.error(v), H([]);
2703
2746
  }
2704
2747
  }
2705
- function Oe(A, v) {
2706
- W() || (Z(!0), Ie(A, v).then((S) => {
2707
- if (S)
2708
- return ve().then((R) => {
2709
- J(R.registrations), Fe(S.transactionID), L(!0);
2748
+ function Ie(A, v) {
2749
+ Z() || (Y(!0), Pe(A, v).then((x) => {
2750
+ if (x)
2751
+ return Ce().then((j) => {
2752
+ V(j.registrations), ye(x.transactionID), R(!0);
2710
2753
  });
2711
2754
  }).finally(() => {
2712
- Z(!1);
2755
+ Y(!1);
2713
2756
  }));
2714
2757
  }
2715
- function Ie(A, v) {
2716
- let S = me("post");
2717
- return S.body = JSON.stringify({
2758
+ function Pe(A, v) {
2759
+ let x = be("post");
2760
+ return x.body = JSON.stringify({
2718
2761
  destination: A,
2719
2762
  OTPType: Se(v),
2720
2763
  sectorID: e.sector
2721
- }), fetch(`${e.domain}/api/v1/otp/begin`, S).then((R) => {
2722
- if (R.status !== 200) {
2764
+ }), fetch(`${e.domain}/api/v1/otp/begin`, x).then((j) => {
2765
+ if (j.status !== 200) {
2723
2766
  s(b.i18n("error-otp-verification"));
2724
2767
  return;
2725
2768
  }
2726
- return R.json();
2727
- }).catch((R) => {
2728
- console.error(R), s(b.i18n("error-otp-registration"));
2769
+ return j.json();
2770
+ }).catch((j) => {
2771
+ console.error(j), s(b.i18n("error-otp-registration"));
2729
2772
  });
2730
2773
  }
2731
- function ze(A, v) {
2732
- if (W()) return;
2733
- Z(!0);
2734
- let S = me("post");
2735
- S.body = JSON.stringify({
2774
+ function Ne(A, v) {
2775
+ if (Z()) return;
2776
+ Y(!0);
2777
+ let x = be("post");
2778
+ x.body = JSON.stringify({
2736
2779
  transactionID: A,
2737
2780
  password: v
2738
- }), fetch(`${e.domain}/api/v1/otp/finish`, S).then((R) => {
2739
- if (R.status !== 200) {
2781
+ }), fetch(`${e.domain}/api/v1/otp/finish`, x).then((j) => {
2782
+ if (j.status !== 200) {
2740
2783
  u(b.i18n("error-otp-verification"));
2741
2784
  return;
2742
2785
  }
2743
- return L(!1), k(""), de(!1), De(""), ye(""), ve().then((d) => {
2744
- J(d.registrations);
2745
- }), R.json();
2746
- }).catch((R) => {
2747
- console.error(R), u(b.i18n("error-otp-registration"));
2786
+ return R(!1), B(""), fe(!1), ge(""), $e(""), Ce().then((d) => {
2787
+ V(d.registrations);
2788
+ }), j.json();
2789
+ }).catch((j) => {
2790
+ console.error(j), u(b.i18n("error-otp-registration"));
2748
2791
  }).finally(() => {
2749
- Z(!1);
2792
+ Y(!1);
2750
2793
  });
2751
2794
  }
2752
- async function ve() {
2753
- let A = me("get");
2795
+ async function Ce() {
2796
+ let A = be("get");
2754
2797
  try {
2755
2798
  return await (await fetch(`${e.domain}/api/v1/otp/list`, A)).json();
2756
2799
  } catch (v) {
@@ -2759,7 +2802,7 @@ ht("spartan-account-settings", _u, (e) => {
2759
2802
  }
2760
2803
  }
2761
2804
  async function xe(A) {
2762
- let v = me("delete");
2805
+ let v = be("delete");
2763
2806
  v.body = JSON.stringify({
2764
2807
  ID: A
2765
2808
  });
@@ -2768,11 +2811,11 @@ ht("spartan-account-settings", _u, (e) => {
2768
2811
  s(b.i18n("error-otp-remove"));
2769
2812
  return;
2770
2813
  }
2771
- ve().then((R) => {
2772
- J(R.registrations);
2814
+ Ce().then((j) => {
2815
+ V(j.registrations);
2773
2816
  });
2774
- } catch (S) {
2775
- console.error(S), s(b.i18n("error-otp-remove"));
2817
+ } catch (x) {
2818
+ console.error(x), s(b.i18n("error-otp-remove"));
2776
2819
  return;
2777
2820
  }
2778
2821
  }
@@ -2780,110 +2823,110 @@ ht("spartan-account-settings", _u, (e) => {
2780
2823
  return A === "EMAIL" ? 2 : 1;
2781
2824
  }
2782
2825
  return (() => {
2783
- var A = vu(), v = A.firstChild, S = v.nextSibling, R = S.nextSibling;
2784
- return f(S, ge), f(R, () => b.i18n("sa-account-settings")), f(A, r && (() => {
2785
- var d = Bt();
2826
+ var A = yu(), v = A.firstChild, x = v.nextSibling, j = x.nextSibling;
2827
+ return f(x, me), f(j, () => b.i18n("sa-account-settings")), f(A, r && (() => {
2828
+ var d = St();
2786
2829
  return f(d, r), d;
2787
2830
  })(), null), f(A, (() => {
2788
- var d = p(() => !!(l() && ue().length));
2831
+ var d = h(() => !!(o() && oe().length));
2789
2832
  return () => d() && (() => {
2790
- var _ = Cu(), z = _.firstChild, P = z.nextSibling;
2791
- return f(z, () => b.i18n("sa-webauthn-security-keys")), f(P, () => ue().map((T) => (() => {
2792
- var Q = wu(), V = Q.firstChild, q = V.nextSibling;
2793
- return f(V, () => T.keyName), q.$$click = () => {
2794
- confirm(b.i18n("sa-confirm-delete-key")) && qe(T.keyName);
2795
- }, f(q, () => b.i18n("sa-remove")), Q;
2796
- })()), null), f(P, (() => {
2797
- var T = p(() => ue().length <= 0);
2798
- return () => T() && (() => {
2799
- var Q = kt();
2800
- return f(Q, () => b.i18n("sa-no-security-keys")), Q;
2833
+ var _ = $u(), I = _.firstChild, z = I.nextSibling;
2834
+ return f(I, () => b.i18n("sa-webauthn-security-keys")), f(z, () => oe().map((L) => (() => {
2835
+ var q = ku(), N = q.firstChild, U = N.nextSibling;
2836
+ return f(N, () => L.keyName), U.$$click = () => {
2837
+ confirm(b.i18n("sa-confirm-delete-key")) && Ue(L.keyName);
2838
+ }, f(U, () => b.i18n("sa-remove")), q;
2839
+ })()), null), f(z, (() => {
2840
+ var L = h(() => oe().length <= 0);
2841
+ return () => L() && (() => {
2842
+ var q = _t();
2843
+ return f(q, () => b.i18n("sa-no-security-keys")), q;
2801
2844
  })();
2802
2845
  })(), null), _;
2803
2846
  })();
2804
2847
  })(), null), f(A, (() => {
2805
- var d = p(() => !!l());
2848
+ var d = h(() => !!o());
2806
2849
  return () => d() && (() => {
2807
- var _ = Au(), z = _.firstChild;
2808
- return f(z, (() => {
2809
- var P = p(() => !C());
2810
- return () => P() && (() => {
2811
- var T = Eu();
2812
- return T.firstChild, T.$$click = () => $(!0), f(T, () => b.i18n("sa-add-security-key"), null), T;
2850
+ var _ = Bu(), I = _.firstChild;
2851
+ return f(I, (() => {
2852
+ var z = h(() => !C());
2853
+ return () => z() && (() => {
2854
+ var L = xu();
2855
+ return L.firstChild, L.$$click = () => $(!0), f(L, () => b.i18n("sa-add-security-key"), null), L;
2813
2856
  })();
2814
- })(), null), f(z, (() => {
2815
- var P = p(() => !!C());
2816
- return () => P() && (() => {
2817
- var T = Fu(), Q = T.firstChild, V = Q.firstChild, q = V.nextSibling, H = q.nextSibling, ne = H.nextSibling;
2818
- return f(V, () => b.i18n("sa-webauthn-key-name")), q.$$input = (U) => n(U.currentTarget.value), H.$$click = () => $(!1), f(H, () => b.i18n("sa-cancel")), ne.$$click = () => t() !== "" && Pe(), f(ne, () => b.i18n("sa-register")), y((U) => {
2819
- var c = b.i18n("sa-webauthn-key-name"), m = t() === "" || W();
2820
- return c !== U.e && le(q, "placeholder", U.e = c), m !== U.t && (ne.disabled = U.t = m), U;
2857
+ })(), null), f(I, (() => {
2858
+ var z = h(() => !!C());
2859
+ return () => z() && (() => {
2860
+ var L = Su(), q = L.firstChild, N = q.firstChild, U = N.nextSibling, K = U.nextSibling, le = K.nextSibling;
2861
+ return f(N, () => b.i18n("sa-webauthn-key-name")), U.$$input = (J) => n(J.currentTarget.value), K.$$click = () => $(!1), f(K, () => b.i18n("sa-cancel")), le.$$click = () => t() !== "" && ze(), f(le, () => b.i18n("sa-register")), y((J) => {
2862
+ var c = b.i18n("sa-webauthn-key-name"), m = t() === "" || Z();
2863
+ return c !== J.e && de(U, "placeholder", J.e = c), m !== J.t && (le.disabled = J.t = m), J;
2821
2864
  }, {
2822
2865
  e: void 0,
2823
2866
  t: void 0
2824
- }), y(() => q.value = t()), T;
2867
+ }), y(() => U.value = t()), L;
2825
2868
  })();
2826
2869
  })(), null), _;
2827
2870
  })();
2828
2871
  })(), null), f(A, (() => {
2829
- var d = p(() => te().length > 0);
2872
+ var d = h(() => ne().length > 0);
2830
2873
  return () => d() && (() => {
2831
- var _ = yu(), z = _.firstChild, P = z.nextSibling, T = P.firstChild, Q = T.firstChild, V = Q.firstChild, q = V.nextSibling, H = q.nextSibling, ne = T.nextSibling;
2832
- return f(z, () => b.i18n("sa-mfa")), f(V, () => b.i18n("sa-mfa-destination")), f(q, () => b.i18n("sa-mfa-validated")), f(H, () => b.i18n("sa-mfa-action")), f(ne, () => te().map((U) => (() => {
2833
- var c = $u(), m = c.firstChild, O = m.nextSibling, x = O.nextSibling, ee = x.firstChild;
2834
- return f(m, () => U.DisplayName), f(O, (() => {
2835
- var re = p(() => !!U.Validated);
2874
+ var _ = _u(), I = _.firstChild, z = I.nextSibling, L = z.firstChild, q = L.firstChild, N = q.firstChild, U = N.nextSibling, K = U.nextSibling, le = L.nextSibling;
2875
+ return f(I, () => b.i18n("sa-mfa")), f(N, () => b.i18n("sa-mfa-destination")), f(U, () => b.i18n("sa-mfa-validated")), f(K, () => b.i18n("sa-mfa-action")), f(le, () => ne().map((J) => (() => {
2876
+ var c = Tu(), m = c.firstChild, T = m.nextSibling, S = T.nextSibling, te = S.firstChild;
2877
+ return f(m, () => J.DisplayName), f(T, (() => {
2878
+ var re = h(() => !!J.Validated);
2836
2879
  return () => re() ? (() => {
2837
- var se = kt();
2880
+ var se = _t();
2838
2881
  return f(se, () => b.i18n("sa-yes")), se;
2839
2882
  })() : (() => {
2840
- var se = Bu(), fe = se.firstChild, $e = fe.nextSibling;
2841
- return f(se, () => b.i18n("sa-no"), fe), $e.$$click = () => {
2842
- Oe(U.DisplayName, U.Type === "email" ? "EMAIL" : "SMS");
2843
- }, f($e, () => b.i18n("sa-validate")), y(() => $e.disabled = W()), se;
2883
+ var se = Ou(), ce = se.firstChild, ke = ce.nextSibling;
2884
+ return f(se, () => b.i18n("sa-no"), ce), ke.$$click = () => {
2885
+ Ie(J.DisplayName, J.Type === "email" ? "EMAIL" : "SMS");
2886
+ }, f(ke, () => b.i18n("sa-validate")), y(() => ke.disabled = Z()), se;
2844
2887
  })();
2845
- })()), ee.$$click = () => {
2846
- confirm(b.i18n("sa-confirm-delete-key")) && xe(U.ID);
2847
- }, f(ee, () => b.i18n("sa-remove")), y(() => le(m, "title", U.DisplayName)), c;
2888
+ })()), te.$$click = () => {
2889
+ confirm(b.i18n("sa-confirm-delete-key")) && xe(J.ID);
2890
+ }, f(te, () => b.i18n("sa-remove")), y(() => de(m, "title", J.DisplayName)), c;
2848
2891
  })())), _;
2849
2892
  })();
2850
2893
  })(), null), f(A, (() => {
2851
- var d = p(() => !ae());
2894
+ var d = h(() => !ue());
2852
2895
  return () => d() && (() => {
2853
- var _ = ku(), z = _.firstChild, P = z.firstChild;
2854
- return P.firstChild, P.$$click = () => de(!0), f(P, () => b.i18n("sa-register-mfa"), null), _;
2896
+ var _ = Iu(), I = _.firstChild, z = I.firstChild;
2897
+ return z.firstChild, z.$$click = () => fe(!0), f(z, () => b.i18n("sa-register-mfa"), null), _;
2855
2898
  })();
2856
2899
  })(), null), f(A, (() => {
2857
- var d = p(() => !!ae());
2900
+ var d = h(() => !!ue());
2858
2901
  return () => d() && (() => {
2859
- var _ = xu(), z = _.firstChild, P = z.nextSibling, T = P.firstChild, Q = T.firstChild, V = Q.nextSibling, q = V.nextSibling, H = T.nextSibling, ne = H.firstChild, U = ne.nextSibling, c = U.nextSibling, m = H.nextSibling, O = m.firstChild;
2860
- return f(z, () => b.i18n("sa-add-mfa")), f(Q, () => b.i18n("sa-email")), V.$$input = (x) => ye(x.currentTarget.value), q.$$click = () => Oe(X(), "EMAIL"), f(q, () => b.i18n("sa-add-email")), f(ne, () => b.i18n("sa-phone")), U.$$input = (x) => De(x.currentTarget.value), c.$$click = () => Oe(pe(), "SMS"), f(c, () => b.i18n("sa-add-sms")), O.$$click = () => de(!1), f(O, () => b.i18n("sa-cancel")), y((x) => {
2861
- var ee = b.i18n("sa-email"), re = W(), se = b.i18n("sa-phone"), fe = W();
2862
- return ee !== x.e && le(V, "placeholder", x.e = ee), re !== x.t && (q.disabled = x.t = re), se !== x.a && le(U, "placeholder", x.a = se), fe !== x.o && (c.disabled = x.o = fe), x;
2902
+ var _ = Pu(), I = _.firstChild, z = I.nextSibling, L = z.firstChild, q = L.firstChild, N = q.nextSibling, U = N.nextSibling, K = L.nextSibling, le = K.firstChild, J = le.nextSibling, c = J.nextSibling, m = K.nextSibling, T = m.firstChild;
2903
+ return f(I, () => b.i18n("sa-add-mfa")), f(q, () => b.i18n("sa-email")), N.$$input = (S) => $e(S.currentTarget.value), U.$$click = () => Ie(ee(), "EMAIL"), f(U, () => b.i18n("sa-add-email")), f(le, () => b.i18n("sa-phone")), J.$$input = (S) => ge(S.currentTarget.value), c.$$click = () => Ie(he(), "SMS"), f(c, () => b.i18n("sa-add-sms")), T.$$click = () => fe(!1), f(T, () => b.i18n("sa-cancel")), y((S) => {
2904
+ var te = b.i18n("sa-email"), re = Z(), se = b.i18n("sa-phone"), ce = Z();
2905
+ return te !== S.e && de(N, "placeholder", S.e = te), re !== S.t && (U.disabled = S.t = re), se !== S.a && de(J, "placeholder", S.a = se), ce !== S.o && (c.disabled = S.o = ce), S;
2863
2906
  }, {
2864
2907
  e: void 0,
2865
2908
  t: void 0,
2866
2909
  a: void 0,
2867
2910
  o: void 0
2868
- }), y(() => V.value = X()), y(() => U.value = pe()), _;
2911
+ }), y(() => N.value = ee()), y(() => J.value = he()), _;
2869
2912
  })();
2870
2913
  })(), null), f(A, (() => {
2871
- var d = p(() => !!Ee());
2914
+ var d = h(() => !!Fe());
2872
2915
  return () => d() && (() => {
2873
- var _ = Su(), z = _.firstChild, P = z.firstChild, T = P.nextSibling, Q = T.nextSibling, V = Q.nextSibling, q = V.nextSibling;
2874
- return _.$$click = () => L(!1), z.$$click = (H) => H.stopPropagation(), P.$$click = () => L(!1), f(z, (() => {
2875
- var H = p(() => !!i());
2876
- return () => H() && (() => {
2877
- var ne = Bt();
2878
- return f(ne, i), ne;
2916
+ var _ = zu(), I = _.firstChild, z = I.firstChild, L = z.nextSibling, q = L.nextSibling, N = q.nextSibling, U = N.nextSibling;
2917
+ return _.$$click = () => R(!1), I.$$click = (K) => K.stopPropagation(), z.$$click = () => R(!1), f(I, (() => {
2918
+ var K = h(() => !!i());
2919
+ return () => K() && (() => {
2920
+ var le = St();
2921
+ return f(le, i), le;
2879
2922
  })();
2880
- })(), Q), V.$$input = (H) => k(H.currentTarget.value), q.$$click = () => ze(we(), Ae()), y(() => q.disabled = W()), y(() => V.value = Ae()), _;
2923
+ })(), q), N.$$input = (K) => B(K.currentTarget.value), U.$$click = () => Ne(Ae(), Ee()), y(() => U.disabled = Z()), y(() => N.value = Ee()), _;
2881
2924
  })();
2882
2925
  })(), null), A;
2883
2926
  })();
2884
2927
  });
2885
- ft(["click", "input"]);
2886
- var Tu = /* @__PURE__ */ F(`<form class=invite-frame><style>.invite-frame {
2928
+ Dt(["click", "input"]);
2929
+ var Mu = /* @__PURE__ */ F(`<form class=invite-frame><style>.invite-frame {
2887
2930
  display: flex;
2888
2931
  flex-direction: column;
2889
2932
  justify-content: center;
@@ -2943,8 +2986,8 @@ var Tu = /* @__PURE__ */ F(`<form class=invite-frame><style>.invite-frame {
2943
2986
  margin-bottom: 10px;
2944
2987
  display: block;
2945
2988
  }
2946
- </style><style></style><h1></h1><input type=text autocomplete=one-time-code required><span class=hint></span><input type=password autocomplete=new-password required minlength=8><span class=hint></span><button type=submit>`), Ou = /* @__PURE__ */ F("<span class=info-message>"), Iu = /* @__PURE__ */ F("<span class=error-message>"), Pu = /* @__PURE__ */ F("<span class=success-message>");
2947
- const zu = {
2989
+ </style><style></style><h1></h1><input type=text autocomplete=one-time-code required><span class=hint></span><input type=password autocomplete=new-password required minlength=8><span class=hint></span><button type=submit>`), ju = /* @__PURE__ */ F("<span class=info-message>"), Ru = /* @__PURE__ */ F("<span class=error-message>"), Lu = /* @__PURE__ */ F("<span class=success-message>");
2990
+ const qu = {
2948
2991
  domain: "http://127.0.0.1:11000",
2949
2992
  sector: "0ad5c3e5-0186-4557-8b32-4b36f247bf09",
2950
2993
  // defaults to the admin sector
@@ -2957,23 +3000,23 @@ const zu = {
2957
3000
  redirect: ""
2958
3001
  // where to redirect after successful completion
2959
3002
  };
2960
- ht("spartan-invite", zu, (e) => {
3003
+ gt("spartan-invite", qu, (e) => {
2961
3004
  console.warn("[spartan-invite] <spartan-invite> is deprecated. Use <spartan-login> instead — it now handles invite links by detecting ?sub= URL params automatically.");
2962
- const [t, n] = w(""), [r, s] = w(""), [i, u] = w(""), [l, C] = w(""), [$, D] = w(!1), B = pt(e.locale);
2963
- let ae, de;
3005
+ const [t, n] = w(""), [r, s] = w(""), [i, u] = w(""), [o, C] = w(""), [$, D] = w(!1), k = mt(e.locale);
3006
+ let ue, fe;
2964
3007
  try {
2965
- de = e.styles;
3008
+ fe = e.styles;
2966
3009
  } catch {
2967
- de = "";
3010
+ fe = "";
2968
3011
  }
2969
- ct(async () => {
3012
+ ht(async () => {
2970
3013
  e.sub || new URLSearchParams(window.location.search).get("sub") || u("Missing invitation information. Please use the link from your invite email.");
2971
- const W = new URLSearchParams(window.location.hash.replace("#", "")).get("otp");
2972
- W && n(W);
3014
+ const Z = new URLSearchParams(window.location.hash.replace("#", "")).get("otp");
3015
+ Z && n(Z);
2973
3016
  });
2974
- async function Ee(L) {
2975
- var ue, G;
2976
- if (L.preventDefault(), u(""), C(""), D(!0), !t() || t().trim().length === 0) {
3017
+ async function Fe(R) {
3018
+ var oe, H;
3019
+ if (R.preventDefault(), u(""), C(""), D(!0), !t() || t().trim().length === 0) {
2977
3020
  u("Please enter your verification code"), D(!1);
2978
3021
  return;
2979
3022
  }
@@ -2981,13 +3024,13 @@ ht("spartan-invite", zu, (e) => {
2981
3024
  u("Password must be at least 8 characters"), D(!1);
2982
3025
  return;
2983
3026
  }
2984
- const W = new URLSearchParams(window.location.search), Z = e.sub || W.get("sub") || "";
2985
- if (!Z) {
3027
+ const Z = new URLSearchParams(window.location.search), Y = e.sub || Z.get("sub") || "";
3028
+ if (!Y) {
2986
3029
  u("Missing invitation information"), D(!1);
2987
3030
  return;
2988
3031
  }
2989
3032
  try {
2990
- const te = await fetch(`${e.domain}/api/v1/users/invite/complete`, {
3033
+ const ne = await fetch(`${e.domain}/api/v1/users/invite/complete`, {
2991
3034
  method: "POST",
2992
3035
  mode: "cors",
2993
3036
  cache: "no-cache",
@@ -2995,67 +3038,67 @@ ht("spartan-invite", zu, (e) => {
2995
3038
  "Content-Type": "application/json"
2996
3039
  },
2997
3040
  body: JSON.stringify({
2998
- sub: Z,
3041
+ sub: Y,
2999
3042
  otp: t().toUpperCase().trim(),
3000
3043
  password: r(),
3001
3044
  sectorID: e.sector
3002
3045
  })
3003
3046
  });
3004
- if (te.ok) {
3005
- const J = await te.json();
3006
- C(B.i18n("sa-invite-success"));
3007
- const we = new CustomEvent("spartan-invite-complete", {
3047
+ if (ne.ok) {
3048
+ const V = await ne.json();
3049
+ C(k.i18n("sa-invite-success"));
3050
+ const Ae = new CustomEvent("spartan-invite-complete", {
3008
3051
  bubbles: !0,
3009
3052
  cancelable: !0,
3010
3053
  detail: {
3011
- sub: Z,
3054
+ sub: Y,
3012
3055
  success: !0
3013
3056
  }
3014
3057
  });
3015
- ae && ae.getRootNode().host.dispatchEvent(we), setTimeout(() => {
3058
+ ue && ue.getRootNode().host.dispatchEvent(Ae), setTimeout(() => {
3016
3059
  e.redirect && e.redirect !== "" && (window.location.href = e.redirect);
3017
3060
  }, 2e3);
3018
3061
  } else {
3019
- const J = await te.json().catch(() => ({}));
3020
- te.status === 400 || (ue = J.message) != null && ue.includes("invalid OTP") ? u(B.i18n("sa-invite-error-otp")) : te.status === 504 || (G = J.message) != null && G.includes("expired") ? u(B.i18n("sa-invite-error-expired")) : u(J.message || B.i18n("sa-invite-error-generic")), D(!1);
3062
+ const V = await ne.json().catch(() => ({}));
3063
+ ne.status === 400 || (oe = V.message) != null && oe.includes("invalid OTP") ? u(k.i18n("sa-invite-error-otp")) : ne.status === 504 || (H = V.message) != null && H.includes("expired") ? u(k.i18n("sa-invite-error-expired")) : u(V.message || k.i18n("sa-invite-error-generic")), D(!1);
3021
3064
  }
3022
- } catch (te) {
3023
- console.error("Error completing invite:", te), u(B.i18n("sa-invite-error-generic")), D(!1);
3065
+ } catch (ne) {
3066
+ console.error("Error completing invite:", ne), u(k.i18n("sa-invite-error-generic")), D(!1);
3024
3067
  }
3025
3068
  }
3026
3069
  return (() => {
3027
- var L = Tu(), W = L.firstChild, Z = W.nextSibling, ue = Z.nextSibling, G = ue.nextSibling, te = G.nextSibling, J = te.nextSibling, we = J.nextSibling, Fe = we.nextSibling, Ae = ae;
3028
- return typeof Ae == "function" ? zt(Ae, L) : ae = L, L.addEventListener("submit", Ee), f(Z, de), f(ue, () => B.i18n("sa-complete-invite")), f(L, (() => {
3029
- var k = p(() => !!e.email);
3030
- return () => k() && (() => {
3031
- var X = Ou();
3032
- return f(X, () => e.email), X;
3070
+ var R = Mu(), Z = R.firstChild, Y = Z.nextSibling, oe = Y.nextSibling, H = oe.nextSibling, ne = H.nextSibling, V = ne.nextSibling, Ae = V.nextSibling, ye = Ae.nextSibling, Ee = ue;
3071
+ return typeof Ee == "function" ? jt(Ee, R) : ue = R, R.addEventListener("submit", Fe), f(Y, fe), f(oe, () => k.i18n("sa-complete-invite")), f(R, (() => {
3072
+ var B = h(() => !!e.email);
3073
+ return () => B() && (() => {
3074
+ var ee = ju();
3075
+ return f(ee, () => e.email), ee;
3033
3076
  })();
3034
- })(), G), f(L, (() => {
3035
- var k = p(() => !!i());
3036
- return () => k() && (() => {
3037
- var X = Iu();
3038
- return f(X, i), X;
3077
+ })(), H), f(R, (() => {
3078
+ var B = h(() => !!i());
3079
+ return () => B() && (() => {
3080
+ var ee = Ru();
3081
+ return f(ee, i), ee;
3039
3082
  })();
3040
- })(), G), f(L, (() => {
3041
- var k = p(() => !!l());
3042
- return () => k() && (() => {
3043
- var X = Pu();
3044
- return f(X, l), X;
3083
+ })(), H), f(R, (() => {
3084
+ var B = h(() => !!o());
3085
+ return () => B() && (() => {
3086
+ var ee = Lu();
3087
+ return f(ee, o), ee;
3045
3088
  })();
3046
- })(), G), G.$$input = (k) => n(k.currentTarget.value), f(te, () => B.i18n("sa-invite-otp-hint")), J.$$input = (k) => s(k.currentTarget.value), f(we, () => B.i18n("sa-invite-password-hint")), f(Fe, (() => {
3047
- var k = p(() => !!$());
3048
- return () => k() ? B.i18n("sa-invite-completing") : B.i18n("sa-invite-submit");
3049
- })()), y((k) => {
3050
- var X = B.i18n("sa-invite-otp"), ye = $() || l() !== "", pe = B.i18n("sa-invite-password"), De = $() || l() !== "", b = $() || l() !== "";
3051
- return X !== k.e && le(G, "placeholder", k.e = X), ye !== k.t && (G.disabled = k.t = ye), pe !== k.a && le(J, "placeholder", k.a = pe), De !== k.o && (J.disabled = k.o = De), b !== k.i && (Fe.disabled = k.i = b), k;
3089
+ })(), H), H.$$input = (B) => n(B.currentTarget.value), f(ne, () => k.i18n("sa-invite-otp-hint")), V.$$input = (B) => s(B.currentTarget.value), f(Ae, () => k.i18n("sa-invite-password-hint")), f(ye, (() => {
3090
+ var B = h(() => !!$());
3091
+ return () => B() ? k.i18n("sa-invite-completing") : k.i18n("sa-invite-submit");
3092
+ })()), y((B) => {
3093
+ var ee = k.i18n("sa-invite-otp"), $e = $() || o() !== "", he = k.i18n("sa-invite-password"), ge = $() || o() !== "", b = $() || o() !== "";
3094
+ return ee !== B.e && de(H, "placeholder", B.e = ee), $e !== B.t && (H.disabled = B.t = $e), he !== B.a && de(V, "placeholder", B.a = he), ge !== B.o && (V.disabled = B.o = ge), b !== B.i && (ye.disabled = B.i = b), B;
3052
3095
  }, {
3053
3096
  e: void 0,
3054
3097
  t: void 0,
3055
3098
  a: void 0,
3056
3099
  o: void 0,
3057
3100
  i: void 0
3058
- }), y(() => G.value = t()), y(() => J.value = r()), L;
3101
+ }), y(() => H.value = t()), y(() => V.value = r()), R;
3059
3102
  })();
3060
3103
  });
3061
- ft(["input"]);
3104
+ Dt(["input"]);