@everymatrix/prize-engine-list 0.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,4892 @@
1
+ var Mr = Object.defineProperty, Nr = Object.defineProperties;
2
+ var jr = Object.getOwnPropertyDescriptors;
3
+ var mt = Object.getOwnPropertySymbols;
4
+ var Rr = Object.prototype.hasOwnProperty, $r = Object.prototype.propertyIsEnumerable;
5
+ var Re = (e, t, r) => t in e ? Mr(e, t, { enumerable: !0, configurable: !0, writable: !0, value: r }) : e[t] = r, $e = (e, t) => {
6
+ for (var r in t || (t = {}))
7
+ Rr.call(t, r) && Re(e, r, t[r]);
8
+ if (mt)
9
+ for (var r of mt(t))
10
+ $r.call(t, r) && Re(e, r, t[r]);
11
+ return e;
12
+ }, bt = (e, t) => Nr(e, jr(t));
13
+ var L = (e, t, r) => (Re(e, typeof t != "symbol" ? t + "" : t, r), r);
14
+ var oe = (e, t, r) => new Promise((n, i) => {
15
+ var o = (l) => {
16
+ try {
17
+ a(r.next(l));
18
+ } catch (u) {
19
+ i(u);
20
+ }
21
+ }, s = (l) => {
22
+ try {
23
+ a(r.throw(l));
24
+ } catch (u) {
25
+ i(u);
26
+ }
27
+ }, a = (l) => l.done ? n(l.value) : Promise.resolve(l.value).then(o, s);
28
+ a((r = r.apply(e, t)).next());
29
+ });
30
+ import "../stencil/ui-skeleton-xXZA3rYO.js";
31
+ function I() {
32
+ }
33
+ const zt = (e) => e;
34
+ function Xt(e) {
35
+ return e();
36
+ }
37
+ function gt() {
38
+ return /* @__PURE__ */ Object.create(null);
39
+ }
40
+ function de(e) {
41
+ e.forEach(Xt);
42
+ }
43
+ function Ie(e) {
44
+ return typeof e == "function";
45
+ }
46
+ function Zt(e, t) {
47
+ return e != e ? t == t : e !== t || e && typeof e == "object" || typeof e == "function";
48
+ }
49
+ function Ur(e) {
50
+ return Object.keys(e).length === 0;
51
+ }
52
+ function Yt(e, ...t) {
53
+ if (e == null) {
54
+ for (const n of t)
55
+ n(void 0);
56
+ return I;
57
+ }
58
+ const r = e.subscribe(...t);
59
+ return r.unsubscribe ? () => r.unsubscribe() : r;
60
+ }
61
+ function Dr(e, t, r) {
62
+ e.$$.on_destroy.push(Yt(t, r));
63
+ }
64
+ const Qt = typeof window != "undefined";
65
+ let kr = Qt ? () => window.performance.now() : () => Date.now(), ct = Qt ? (e) => requestAnimationFrame(e) : I;
66
+ const Q = /* @__PURE__ */ new Set();
67
+ function Jt(e) {
68
+ Q.forEach((t) => {
69
+ t.c(e) || (Q.delete(t), t.f());
70
+ }), Q.size !== 0 && ct(Jt);
71
+ }
72
+ function Gr(e) {
73
+ let t;
74
+ return Q.size === 0 && ct(Jt), {
75
+ promise: new Promise((r) => {
76
+ Q.add(t = { c: e, f: r });
77
+ }),
78
+ abort() {
79
+ Q.delete(t);
80
+ }
81
+ };
82
+ }
83
+ function E(e, t) {
84
+ e.appendChild(t);
85
+ }
86
+ function Fr(e, t, r) {
87
+ const n = ft(e);
88
+ if (!n.getElementById(t)) {
89
+ const i = S("style");
90
+ i.id = t, i.textContent = r, qt(n, i);
91
+ }
92
+ }
93
+ function ft(e) {
94
+ if (!e)
95
+ return document;
96
+ const t = e.getRootNode ? e.getRootNode() : e.ownerDocument;
97
+ return t && /** @type {ShadowRoot} */
98
+ t.host ? (
99
+ /** @type {ShadowRoot} */
100
+ t
101
+ ) : e.ownerDocument;
102
+ }
103
+ function Vr(e) {
104
+ const t = S("style");
105
+ return t.textContent = "/* empty */", qt(ft(e), t), t.sheet;
106
+ }
107
+ function qt(e, t) {
108
+ return E(
109
+ /** @type {Document} */
110
+ e.head || e,
111
+ t
112
+ ), t.sheet;
113
+ }
114
+ function F(e, t, r) {
115
+ e.insertBefore(t, r || null);
116
+ }
117
+ function $(e) {
118
+ e.parentNode && e.parentNode.removeChild(e);
119
+ }
120
+ function Kt(e, t) {
121
+ for (let r = 0; r < e.length; r += 1)
122
+ e[r] && e[r].d(t);
123
+ }
124
+ function S(e) {
125
+ return document.createElement(e);
126
+ }
127
+ function ue(e) {
128
+ return document.createTextNode(e);
129
+ }
130
+ function X() {
131
+ return ue(" ");
132
+ }
133
+ function Wr(e, t, r, n) {
134
+ return e.addEventListener(t, r, n), () => e.removeEventListener(t, r, n);
135
+ }
136
+ function A(e, t, r) {
137
+ r == null ? e.removeAttribute(t) : e.getAttribute(t) !== r && e.setAttribute(t, r);
138
+ }
139
+ function zr(e) {
140
+ return Array.from(e.childNodes);
141
+ }
142
+ function Se(e, t) {
143
+ t = "" + t, e.data !== t && (e.data = /** @type {string} */
144
+ t);
145
+ }
146
+ function vt(e, t, r, n) {
147
+ r == null ? e.style.removeProperty(t) : e.style.setProperty(t, r, "");
148
+ }
149
+ function er(e, t, r) {
150
+ e.classList.toggle(t, !!r);
151
+ }
152
+ function Xr(e, t, { bubbles: r = !1, cancelable: n = !1 } = {}) {
153
+ return new CustomEvent(e, { detail: t, bubbles: r, cancelable: n });
154
+ }
155
+ function Zr(e) {
156
+ const t = {};
157
+ return e.childNodes.forEach(
158
+ /** @param {Element} node */
159
+ (r) => {
160
+ t[r.slot || "default"] = !0;
161
+ }
162
+ ), t;
163
+ }
164
+ const Te = /* @__PURE__ */ new Map();
165
+ let Ae = 0;
166
+ function Yr(e) {
167
+ let t = 5381, r = e.length;
168
+ for (; r--; )
169
+ t = (t << 5) - t ^ e.charCodeAt(r);
170
+ return t >>> 0;
171
+ }
172
+ function Qr(e, t) {
173
+ const r = { stylesheet: Vr(t), rules: {} };
174
+ return Te.set(e, r), r;
175
+ }
176
+ function Jr(e, t, r, n, i, o, s, a = 0) {
177
+ const l = 16.666 / n;
178
+ let u = `{
179
+ `;
180
+ for (let y = 0; y <= 1; y += l) {
181
+ const C = t + (r - t) * o(y);
182
+ u += y * 100 + `%{${s(C, 1 - C)}}
183
+ `;
184
+ }
185
+ const h = u + `100% {${s(r, 1 - r)}}
186
+ }`, c = `__svelte_${Yr(h)}_${a}`, f = ft(e), { stylesheet: p, rules: b } = Te.get(f) || Qr(f, e);
187
+ b[c] || (b[c] = !0, p.insertRule(`@keyframes ${c} ${h}`, p.cssRules.length));
188
+ const d = e.style.animation || "";
189
+ return e.style.animation = `${d ? `${d}, ` : ""}${c} ${n}ms linear ${i}ms 1 both`, Ae += 1, c;
190
+ }
191
+ function yt(e, t) {
192
+ const r = (e.style.animation || "").split(", "), n = r.filter(
193
+ t ? (o) => o.indexOf(t) < 0 : (o) => o.indexOf("__svelte") === -1
194
+ // remove all Svelte animations
195
+ ), i = r.length - n.length;
196
+ i && (e.style.animation = n.join(", "), Ae -= i, Ae || qr());
197
+ }
198
+ function qr() {
199
+ ct(() => {
200
+ Ae || (Te.forEach((e) => {
201
+ const { ownerNode: t } = e.stylesheet;
202
+ t && $(t);
203
+ }), Te.clear());
204
+ });
205
+ }
206
+ let he;
207
+ function le(e) {
208
+ he = e;
209
+ }
210
+ function Kr() {
211
+ if (!he)
212
+ throw new Error("Function called outside component initialization");
213
+ return he;
214
+ }
215
+ function en(e) {
216
+ Kr().$$.on_mount.push(e);
217
+ }
218
+ const Z = [], Xe = [];
219
+ let J = [];
220
+ const xt = [], tn = /* @__PURE__ */ Promise.resolve();
221
+ let Ze = !1;
222
+ function rn() {
223
+ Ze || (Ze = !0, tn.then(j));
224
+ }
225
+ function ce(e) {
226
+ J.push(e);
227
+ }
228
+ const Ue = /* @__PURE__ */ new Set();
229
+ let W = 0;
230
+ function j() {
231
+ if (W !== 0)
232
+ return;
233
+ const e = he;
234
+ do {
235
+ try {
236
+ for (; W < Z.length; ) {
237
+ const t = Z[W];
238
+ W++, le(t), nn(t.$$);
239
+ }
240
+ } catch (t) {
241
+ throw Z.length = 0, W = 0, t;
242
+ }
243
+ for (le(null), Z.length = 0, W = 0; Xe.length; )
244
+ Xe.pop()();
245
+ for (let t = 0; t < J.length; t += 1) {
246
+ const r = J[t];
247
+ Ue.has(r) || (Ue.add(r), r());
248
+ }
249
+ J.length = 0;
250
+ } while (Z.length);
251
+ for (; xt.length; )
252
+ xt.pop()();
253
+ Ze = !1, Ue.clear(), le(e);
254
+ }
255
+ function nn(e) {
256
+ if (e.fragment !== null) {
257
+ e.update(), de(e.before_update);
258
+ const t = e.dirty;
259
+ e.dirty = [-1], e.fragment && e.fragment.p(e.ctx, t), e.after_update.forEach(ce);
260
+ }
261
+ }
262
+ function on(e) {
263
+ const t = [], r = [];
264
+ J.forEach((n) => e.indexOf(n) === -1 ? t.push(n) : r.push(n)), r.forEach((n) => n()), J = t;
265
+ }
266
+ let se;
267
+ function sn() {
268
+ return se || (se = Promise.resolve(), se.then(() => {
269
+ se = null;
270
+ })), se;
271
+ }
272
+ function _t(e, t, r) {
273
+ e.dispatchEvent(Xr(`intro${r}`));
274
+ }
275
+ const an = /* @__PURE__ */ new Set();
276
+ function ln(e, t) {
277
+ e && e.i && (an.delete(e), e.i(t));
278
+ }
279
+ const un = { duration: 0 };
280
+ function hn(e, t, r) {
281
+ const n = { direction: "in" };
282
+ let i = t(e, r, n), o = !1, s, a, l = 0;
283
+ function u() {
284
+ s && yt(e, s);
285
+ }
286
+ function h() {
287
+ const {
288
+ delay: f = 0,
289
+ duration: p = 300,
290
+ easing: b = zt,
291
+ tick: d = I,
292
+ css: y
293
+ } = i || un;
294
+ y && (s = Jr(e, 0, 1, p, f, b, y, l++)), d(0, 1);
295
+ const C = kr() + f, O = C + p;
296
+ a && a.abort(), o = !0, ce(() => _t(e, !0, "start")), a = Gr((T) => {
297
+ if (o) {
298
+ if (T >= O)
299
+ return d(1, 0), _t(e, !0, "end"), u(), o = !1;
300
+ if (T >= C) {
301
+ const B = b((T - C) / p);
302
+ d(B, 1 - B);
303
+ }
304
+ }
305
+ return o;
306
+ });
307
+ }
308
+ let c = !1;
309
+ return {
310
+ start() {
311
+ c || (c = !0, yt(e), Ie(i) ? (i = i(n), sn().then(h)) : h());
312
+ },
313
+ invalidate() {
314
+ c = !1;
315
+ },
316
+ end() {
317
+ o && (u(), o = !1);
318
+ }
319
+ };
320
+ }
321
+ function Ye(e) {
322
+ return (e == null ? void 0 : e.length) !== void 0 ? e : Array.from(e);
323
+ }
324
+ function cn(e, t, r) {
325
+ const { fragment: n, after_update: i } = e.$$;
326
+ n && n.m(t, r), ce(() => {
327
+ const o = e.$$.on_mount.map(Xt).filter(Ie);
328
+ e.$$.on_destroy ? e.$$.on_destroy.push(...o) : de(o), e.$$.on_mount = [];
329
+ }), i.forEach(ce);
330
+ }
331
+ function fn(e, t) {
332
+ const r = e.$$;
333
+ r.fragment !== null && (on(r.after_update), de(r.on_destroy), r.fragment && r.fragment.d(t), r.on_destroy = r.fragment = null, r.ctx = []);
334
+ }
335
+ function pn(e, t) {
336
+ e.$$.dirty[0] === -1 && (Z.push(e), rn(), e.$$.dirty.fill(0)), e.$$.dirty[t / 31 | 0] |= 1 << t % 31;
337
+ }
338
+ function dn(e, t, r, n, i, o, s = null, a = [-1]) {
339
+ const l = he;
340
+ le(e);
341
+ const u = e.$$ = {
342
+ fragment: null,
343
+ ctx: [],
344
+ // state
345
+ props: o,
346
+ update: I,
347
+ not_equal: i,
348
+ bound: gt(),
349
+ // lifecycle
350
+ on_mount: [],
351
+ on_destroy: [],
352
+ on_disconnect: [],
353
+ before_update: [],
354
+ after_update: [],
355
+ context: new Map(t.context || (l ? l.$$.context : [])),
356
+ // everything else
357
+ callbacks: gt(),
358
+ dirty: a,
359
+ skip_bound: !1,
360
+ root: t.target || l.$$.root
361
+ };
362
+ s && s(u.root);
363
+ let h = !1;
364
+ if (u.ctx = r ? r(e, t.props || {}, (c, f, ...p) => {
365
+ const b = p.length ? p[0] : f;
366
+ return u.ctx && i(u.ctx[c], u.ctx[c] = b) && (!u.skip_bound && u.bound[c] && u.bound[c](b), h && pn(e, c)), f;
367
+ }) : [], u.update(), h = !0, de(u.before_update), u.fragment = n ? n(u.ctx) : !1, t.target) {
368
+ if (t.hydrate) {
369
+ const c = zr(t.target);
370
+ u.fragment && u.fragment.l(c), c.forEach($);
371
+ } else
372
+ u.fragment && u.fragment.c();
373
+ t.intro && ln(e.$$.fragment), cn(e, t.target, t.anchor), j();
374
+ }
375
+ le(l);
376
+ }
377
+ let tr;
378
+ typeof HTMLElement == "function" && (tr = class extends HTMLElement {
379
+ constructor(t, r, n) {
380
+ super();
381
+ /** The Svelte component constructor */
382
+ L(this, "$$ctor");
383
+ /** Slots */
384
+ L(this, "$$s");
385
+ /** The Svelte component instance */
386
+ L(this, "$$c");
387
+ /** Whether or not the custom element is connected */
388
+ L(this, "$$cn", !1);
389
+ /** Component props data */
390
+ L(this, "$$d", {});
391
+ /** `true` if currently in the process of reflecting component props back to attributes */
392
+ L(this, "$$r", !1);
393
+ /** @type {Record<string, CustomElementPropDefinition>} Props definition (name, reflected, type etc) */
394
+ L(this, "$$p_d", {});
395
+ /** @type {Record<string, Function[]>} Event listeners */
396
+ L(this, "$$l", {});
397
+ /** @type {Map<Function, Function>} Event listener unsubscribe functions */
398
+ L(this, "$$l_u", /* @__PURE__ */ new Map());
399
+ this.$$ctor = t, this.$$s = r, n && this.attachShadow({ mode: "open" });
400
+ }
401
+ addEventListener(t, r, n) {
402
+ if (this.$$l[t] = this.$$l[t] || [], this.$$l[t].push(r), this.$$c) {
403
+ const i = this.$$c.$on(t, r);
404
+ this.$$l_u.set(r, i);
405
+ }
406
+ super.addEventListener(t, r, n);
407
+ }
408
+ removeEventListener(t, r, n) {
409
+ if (super.removeEventListener(t, r, n), this.$$c) {
410
+ const i = this.$$l_u.get(r);
411
+ i && (i(), this.$$l_u.delete(r));
412
+ }
413
+ }
414
+ connectedCallback() {
415
+ return oe(this, null, function* () {
416
+ if (this.$$cn = !0, !this.$$c) {
417
+ let t = function(o) {
418
+ return () => {
419
+ let s;
420
+ return {
421
+ c: function() {
422
+ s = S("slot"), o !== "default" && A(s, "name", o);
423
+ },
424
+ /**
425
+ * @param {HTMLElement} target
426
+ * @param {HTMLElement} [anchor]
427
+ */
428
+ m: function(u, h) {
429
+ F(u, s, h);
430
+ },
431
+ d: function(u) {
432
+ u && $(s);
433
+ }
434
+ };
435
+ };
436
+ };
437
+ if (yield Promise.resolve(), !this.$$cn || this.$$c)
438
+ return;
439
+ const r = {}, n = Zr(this);
440
+ for (const o of this.$$s)
441
+ o in n && (r[o] = [t(o)]);
442
+ for (const o of this.attributes) {
443
+ const s = this.$$g_p(o.name);
444
+ s in this.$$d || (this.$$d[s] = xe(s, o.value, this.$$p_d, "toProp"));
445
+ }
446
+ for (const o in this.$$p_d)
447
+ !(o in this.$$d) && this[o] !== void 0 && (this.$$d[o] = this[o], delete this[o]);
448
+ this.$$c = new this.$$ctor({
449
+ target: this.shadowRoot || this,
450
+ props: bt($e({}, this.$$d), {
451
+ $$slots: r,
452
+ $$scope: {
453
+ ctx: []
454
+ }
455
+ })
456
+ });
457
+ const i = () => {
458
+ this.$$r = !0;
459
+ for (const o in this.$$p_d)
460
+ if (this.$$d[o] = this.$$c.$$.ctx[this.$$c.$$.props[o]], this.$$p_d[o].reflect) {
461
+ const s = xe(
462
+ o,
463
+ this.$$d[o],
464
+ this.$$p_d,
465
+ "toAttribute"
466
+ );
467
+ s == null ? this.removeAttribute(this.$$p_d[o].attribute || o) : this.setAttribute(this.$$p_d[o].attribute || o, s);
468
+ }
469
+ this.$$r = !1;
470
+ };
471
+ this.$$c.$$.after_update.push(i), i();
472
+ for (const o in this.$$l)
473
+ for (const s of this.$$l[o]) {
474
+ const a = this.$$c.$on(o, s);
475
+ this.$$l_u.set(s, a);
476
+ }
477
+ this.$$l = {};
478
+ }
479
+ });
480
+ }
481
+ // We don't need this when working within Svelte code, but for compatibility of people using this outside of Svelte
482
+ // and setting attributes through setAttribute etc, this is helpful
483
+ attributeChangedCallback(t, r, n) {
484
+ var i;
485
+ this.$$r || (t = this.$$g_p(t), this.$$d[t] = xe(t, n, this.$$p_d, "toProp"), (i = this.$$c) == null || i.$set({ [t]: this.$$d[t] }));
486
+ }
487
+ disconnectedCallback() {
488
+ this.$$cn = !1, Promise.resolve().then(() => {
489
+ !this.$$cn && this.$$c && (this.$$c.$destroy(), this.$$c = void 0);
490
+ });
491
+ }
492
+ $$g_p(t) {
493
+ return Object.keys(this.$$p_d).find(
494
+ (r) => this.$$p_d[r].attribute === t || !this.$$p_d[r].attribute && r.toLowerCase() === t
495
+ ) || t;
496
+ }
497
+ });
498
+ function xe(e, t, r, n) {
499
+ var o;
500
+ const i = (o = r[e]) == null ? void 0 : o.type;
501
+ if (t = i === "Boolean" && typeof t != "boolean" ? t != null : t, !n || !r[e])
502
+ return t;
503
+ if (n === "toAttribute")
504
+ switch (i) {
505
+ case "Object":
506
+ case "Array":
507
+ return t == null ? null : JSON.stringify(t);
508
+ case "Boolean":
509
+ return t ? "" : null;
510
+ case "Number":
511
+ return t == null ? null : t;
512
+ default:
513
+ return t;
514
+ }
515
+ else
516
+ switch (i) {
517
+ case "Object":
518
+ case "Array":
519
+ return t && JSON.parse(t);
520
+ case "Boolean":
521
+ return t;
522
+ case "Number":
523
+ return t != null ? +t : t;
524
+ default:
525
+ return t;
526
+ }
527
+ }
528
+ function mn(e, t, r, n, i, o) {
529
+ let s = class extends tr {
530
+ constructor() {
531
+ super(e, r, i), this.$$p_d = t;
532
+ }
533
+ static get observedAttributes() {
534
+ return Object.keys(t).map(
535
+ (a) => (t[a].attribute || a).toLowerCase()
536
+ );
537
+ }
538
+ };
539
+ return Object.keys(t).forEach((a) => {
540
+ Object.defineProperty(s.prototype, a, {
541
+ get() {
542
+ return this.$$c && a in this.$$c ? this.$$c[a] : this.$$d[a];
543
+ },
544
+ set(l) {
545
+ var u;
546
+ l = xe(a, l, t), this.$$d[a] = l, (u = this.$$c) == null || u.$set({ [a]: l });
547
+ }
548
+ });
549
+ }), n.forEach((a) => {
550
+ Object.defineProperty(s.prototype, a, {
551
+ get() {
552
+ var l;
553
+ return (l = this.$$c) == null ? void 0 : l[a];
554
+ }
555
+ });
556
+ }), e.element = /** @type {any} */
557
+ s, s;
558
+ }
559
+ class bn {
560
+ constructor() {
561
+ /**
562
+ * ### PRIVATE API
563
+ *
564
+ * Do not use, may change at any time
565
+ *
566
+ * @type {any}
567
+ */
568
+ L(this, "$$");
569
+ /**
570
+ * ### PRIVATE API
571
+ *
572
+ * Do not use, may change at any time
573
+ *
574
+ * @type {any}
575
+ */
576
+ L(this, "$$set");
577
+ }
578
+ /** @returns {void} */
579
+ $destroy() {
580
+ fn(this, 1), this.$destroy = I;
581
+ }
582
+ /**
583
+ * @template {Extract<keyof Events, string>} K
584
+ * @param {K} type
585
+ * @param {((e: Events[K]) => void) | null | undefined} callback
586
+ * @returns {() => void}
587
+ */
588
+ $on(t, r) {
589
+ if (!Ie(r))
590
+ return I;
591
+ const n = this.$$.callbacks[t] || (this.$$.callbacks[t] = []);
592
+ return n.push(r), () => {
593
+ const i = n.indexOf(r);
594
+ i !== -1 && n.splice(i, 1);
595
+ };
596
+ }
597
+ /**
598
+ * @param {Partial<Props>} props
599
+ * @returns {void}
600
+ */
601
+ $set(t) {
602
+ this.$$set && !Ur(t) && (this.$$.skip_bound = !0, this.$$set(t), this.$$.skip_bound = !1);
603
+ }
604
+ }
605
+ const gn = "4";
606
+ typeof window != "undefined" && (window.__svelte || (window.__svelte = { v: /* @__PURE__ */ new Set() })).v.add(gn);
607
+ function vn(e, { delay: t = 0, duration: r = 400, easing: n = zt } = {}) {
608
+ const i = +getComputedStyle(e).opacity;
609
+ return {
610
+ delay: t,
611
+ duration: r,
612
+ easing: n,
613
+ css: (o) => `opacity: ${o * i}`
614
+ };
615
+ }
616
+ const Y = "__WIDGET_GLOBAL_STYLE_CACHE__";
617
+ function yn(e, t) {
618
+ if (e) {
619
+ const r = document.createElement("style");
620
+ r.innerHTML = t, e.appendChild(r);
621
+ }
622
+ }
623
+ function xn(e, t) {
624
+ if (!e || !t)
625
+ return;
626
+ const r = new URL(t);
627
+ fetch(r.href).then((n) => n.text()).then((n) => {
628
+ const i = document.createElement("style");
629
+ i.innerHTML = n, e && e.appendChild(i);
630
+ }).catch((n) => {
631
+ console.error("There was an error while trying to load client styling from URL", n);
632
+ });
633
+ }
634
+ function _n(e, t, r, n = !1) {
635
+ if (!window.emMessageBus)
636
+ return;
637
+ if (!("adoptedStyleSheets" in Document.prototype) || !n)
638
+ return r = En(e, t), r;
639
+ window[Y] || (window[Y] = {}), r = wn(e, t);
640
+ const o = r.unsubscribe.bind(r), s = () => {
641
+ if (window[Y][t]) {
642
+ const a = window[Y][t];
643
+ a.refCount > 1 ? a.refCount = a.refCount - 1 : delete window[Y][t];
644
+ }
645
+ o();
646
+ };
647
+ return r.unsubscribe = s, r;
648
+ }
649
+ function En(e, t) {
650
+ const r = document.createElement("style");
651
+ return window.emMessageBus.subscribe(t, (n) => {
652
+ e && (r.innerHTML = n, e.appendChild(r));
653
+ });
654
+ }
655
+ function wn(e, t) {
656
+ return window.emMessageBus.subscribe(t, (r) => {
657
+ if (!e)
658
+ return;
659
+ const n = e.getRootNode(), i = window[Y];
660
+ let o = i[t] && i[t].sheet;
661
+ o ? i[t].refCount = i[t].refCount + 1 : (o = new CSSStyleSheet(), o.replaceSync(r), i[t] = {
662
+ sheet: o,
663
+ refCount: 1
664
+ });
665
+ const s = n.adoptedStyleSheets || [];
666
+ s.includes(o) || (n.adoptedStyleSheets = [...s, o]);
667
+ });
668
+ }
669
+ /*! *****************************************************************************
670
+ Copyright (c) Microsoft Corporation.
671
+
672
+ Permission to use, copy, modify, and/or distribute this software for any
673
+ purpose with or without fee is hereby granted.
674
+
675
+ THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
676
+ REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
677
+ AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
678
+ INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
679
+ LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
680
+ OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
681
+ PERFORMANCE OF THIS SOFTWARE.
682
+ ***************************************************************************** */
683
+ var Qe = function(e, t) {
684
+ return Qe = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(r, n) {
685
+ r.__proto__ = n;
686
+ } || function(r, n) {
687
+ for (var i in n)
688
+ Object.prototype.hasOwnProperty.call(n, i) && (r[i] = n[i]);
689
+ }, Qe(e, t);
690
+ };
691
+ function me(e, t) {
692
+ if (typeof t != "function" && t !== null)
693
+ throw new TypeError("Class extends value " + String(t) + " is not a constructor or null");
694
+ Qe(e, t);
695
+ function r() {
696
+ this.constructor = e;
697
+ }
698
+ e.prototype = t === null ? Object.create(t) : (r.prototype = t.prototype, new r());
699
+ }
700
+ function Je(e) {
701
+ var t = typeof Symbol == "function" && Symbol.iterator, r = t && e[t], n = 0;
702
+ if (r)
703
+ return r.call(e);
704
+ if (e && typeof e.length == "number")
705
+ return {
706
+ next: function() {
707
+ return e && n >= e.length && (e = void 0), { value: e && e[n++], done: !e };
708
+ }
709
+ };
710
+ throw new TypeError(t ? "Object is not iterable." : "Symbol.iterator is not defined.");
711
+ }
712
+ function qe(e, t) {
713
+ var r = typeof Symbol == "function" && e[Symbol.iterator];
714
+ if (!r)
715
+ return e;
716
+ var n = r.call(e), i, o = [], s;
717
+ try {
718
+ for (; (t === void 0 || t-- > 0) && !(i = n.next()).done; )
719
+ o.push(i.value);
720
+ } catch (a) {
721
+ s = { error: a };
722
+ } finally {
723
+ try {
724
+ i && !i.done && (r = n.return) && r.call(n);
725
+ } finally {
726
+ if (s)
727
+ throw s.error;
728
+ }
729
+ }
730
+ return o;
731
+ }
732
+ function Ke(e, t, r) {
733
+ if (arguments.length === 2)
734
+ for (var n = 0, i = t.length, o; n < i; n++)
735
+ (o || !(n in t)) && (o || (o = Array.prototype.slice.call(t, 0, n)), o[n] = t[n]);
736
+ return e.concat(o || t);
737
+ }
738
+ function U(e) {
739
+ return typeof e == "function";
740
+ }
741
+ function rr(e) {
742
+ var t = function(n) {
743
+ Error.call(n), n.stack = new Error().stack;
744
+ }, r = e(t);
745
+ return r.prototype = Object.create(Error.prototype), r.prototype.constructor = r, r;
746
+ }
747
+ var De = rr(function(e) {
748
+ return function(r) {
749
+ e(this), this.message = r ? r.length + ` errors occurred during unsubscription:
750
+ ` + r.map(function(n, i) {
751
+ return i + 1 + ") " + n.toString();
752
+ }).join(`
753
+ `) : "", this.name = "UnsubscriptionError", this.errors = r;
754
+ };
755
+ });
756
+ function et(e, t) {
757
+ if (e) {
758
+ var r = e.indexOf(t);
759
+ 0 <= r && e.splice(r, 1);
760
+ }
761
+ }
762
+ var Oe = function() {
763
+ function e(t) {
764
+ this.initialTeardown = t, this.closed = !1, this._parentage = null, this._finalizers = null;
765
+ }
766
+ return e.prototype.unsubscribe = function() {
767
+ var t, r, n, i, o;
768
+ if (!this.closed) {
769
+ this.closed = !0;
770
+ var s = this._parentage;
771
+ if (s)
772
+ if (this._parentage = null, Array.isArray(s))
773
+ try {
774
+ for (var a = Je(s), l = a.next(); !l.done; l = a.next()) {
775
+ var u = l.value;
776
+ u.remove(this);
777
+ }
778
+ } catch (d) {
779
+ t = { error: d };
780
+ } finally {
781
+ try {
782
+ l && !l.done && (r = a.return) && r.call(a);
783
+ } finally {
784
+ if (t)
785
+ throw t.error;
786
+ }
787
+ }
788
+ else
789
+ s.remove(this);
790
+ var h = this.initialTeardown;
791
+ if (U(h))
792
+ try {
793
+ h();
794
+ } catch (d) {
795
+ o = d instanceof De ? d.errors : [d];
796
+ }
797
+ var c = this._finalizers;
798
+ if (c) {
799
+ this._finalizers = null;
800
+ try {
801
+ for (var f = Je(c), p = f.next(); !p.done; p = f.next()) {
802
+ var b = p.value;
803
+ try {
804
+ Et(b);
805
+ } catch (d) {
806
+ o = o != null ? o : [], d instanceof De ? o = Ke(Ke([], qe(o)), qe(d.errors)) : o.push(d);
807
+ }
808
+ }
809
+ } catch (d) {
810
+ n = { error: d };
811
+ } finally {
812
+ try {
813
+ p && !p.done && (i = f.return) && i.call(f);
814
+ } finally {
815
+ if (n)
816
+ throw n.error;
817
+ }
818
+ }
819
+ }
820
+ if (o)
821
+ throw new De(o);
822
+ }
823
+ }, e.prototype.add = function(t) {
824
+ var r;
825
+ if (t && t !== this)
826
+ if (this.closed)
827
+ Et(t);
828
+ else {
829
+ if (t instanceof e) {
830
+ if (t.closed || t._hasParent(this))
831
+ return;
832
+ t._addParent(this);
833
+ }
834
+ (this._finalizers = (r = this._finalizers) !== null && r !== void 0 ? r : []).push(t);
835
+ }
836
+ }, e.prototype._hasParent = function(t) {
837
+ var r = this._parentage;
838
+ return r === t || Array.isArray(r) && r.includes(t);
839
+ }, e.prototype._addParent = function(t) {
840
+ var r = this._parentage;
841
+ this._parentage = Array.isArray(r) ? (r.push(t), r) : r ? [r, t] : t;
842
+ }, e.prototype._removeParent = function(t) {
843
+ var r = this._parentage;
844
+ r === t ? this._parentage = null : Array.isArray(r) && et(r, t);
845
+ }, e.prototype.remove = function(t) {
846
+ var r = this._finalizers;
847
+ r && et(r, t), t instanceof e && t._removeParent(this);
848
+ }, e.EMPTY = function() {
849
+ var t = new e();
850
+ return t.closed = !0, t;
851
+ }(), e;
852
+ }(), nr = Oe.EMPTY;
853
+ function ir(e) {
854
+ return e instanceof Oe || e && "closed" in e && U(e.remove) && U(e.add) && U(e.unsubscribe);
855
+ }
856
+ function Et(e) {
857
+ U(e) ? e() : e.unsubscribe();
858
+ }
859
+ var Sn = {
860
+ Promise: void 0
861
+ }, Tn = {
862
+ setTimeout: function(e, t) {
863
+ for (var r = [], n = 2; n < arguments.length; n++)
864
+ r[n - 2] = arguments[n];
865
+ return setTimeout.apply(void 0, Ke([e, t], qe(r)));
866
+ },
867
+ clearTimeout: function(e) {
868
+ return clearTimeout(e);
869
+ },
870
+ delegate: void 0
871
+ };
872
+ function An(e) {
873
+ Tn.setTimeout(function() {
874
+ throw e;
875
+ });
876
+ }
877
+ function wt() {
878
+ }
879
+ function _e(e) {
880
+ e();
881
+ }
882
+ var or = function(e) {
883
+ me(t, e);
884
+ function t(r) {
885
+ var n = e.call(this) || this;
886
+ return n.isStopped = !1, r ? (n.destination = r, ir(r) && r.add(n)) : n.destination = Bn, n;
887
+ }
888
+ return t.create = function(r, n, i) {
889
+ return new tt(r, n, i);
890
+ }, t.prototype.next = function(r) {
891
+ this.isStopped || this._next(r);
892
+ }, t.prototype.error = function(r) {
893
+ this.isStopped || (this.isStopped = !0, this._error(r));
894
+ }, t.prototype.complete = function() {
895
+ this.isStopped || (this.isStopped = !0, this._complete());
896
+ }, t.prototype.unsubscribe = function() {
897
+ this.closed || (this.isStopped = !0, e.prototype.unsubscribe.call(this), this.destination = null);
898
+ }, t.prototype._next = function(r) {
899
+ this.destination.next(r);
900
+ }, t.prototype._error = function(r) {
901
+ try {
902
+ this.destination.error(r);
903
+ } finally {
904
+ this.unsubscribe();
905
+ }
906
+ }, t.prototype._complete = function() {
907
+ try {
908
+ this.destination.complete();
909
+ } finally {
910
+ this.unsubscribe();
911
+ }
912
+ }, t;
913
+ }(Oe), Cn = function() {
914
+ function e(t) {
915
+ this.partialObserver = t;
916
+ }
917
+ return e.prototype.next = function(t) {
918
+ var r = this.partialObserver;
919
+ if (r.next)
920
+ try {
921
+ r.next(t);
922
+ } catch (n) {
923
+ ve(n);
924
+ }
925
+ }, e.prototype.error = function(t) {
926
+ var r = this.partialObserver;
927
+ if (r.error)
928
+ try {
929
+ r.error(t);
930
+ } catch (n) {
931
+ ve(n);
932
+ }
933
+ else
934
+ ve(t);
935
+ }, e.prototype.complete = function() {
936
+ var t = this.partialObserver;
937
+ if (t.complete)
938
+ try {
939
+ t.complete();
940
+ } catch (r) {
941
+ ve(r);
942
+ }
943
+ }, e;
944
+ }(), tt = function(e) {
945
+ me(t, e);
946
+ function t(r, n, i) {
947
+ var o = e.call(this) || this, s;
948
+ return U(r) || !r ? s = {
949
+ next: r != null ? r : void 0,
950
+ error: n != null ? n : void 0,
951
+ complete: i != null ? i : void 0
952
+ } : s = r, o.destination = new Cn(s), o;
953
+ }
954
+ return t;
955
+ }(or);
956
+ function ve(e) {
957
+ An(e);
958
+ }
959
+ function Hn(e) {
960
+ throw e;
961
+ }
962
+ var Bn = {
963
+ closed: !0,
964
+ next: wt,
965
+ error: Hn,
966
+ complete: wt
967
+ }, In = function() {
968
+ return typeof Symbol == "function" && Symbol.observable || "@@observable";
969
+ }();
970
+ function On(e) {
971
+ return e;
972
+ }
973
+ function Pn(e) {
974
+ return e.length === 0 ? On : e.length === 1 ? e[0] : function(r) {
975
+ return e.reduce(function(n, i) {
976
+ return i(n);
977
+ }, r);
978
+ };
979
+ }
980
+ var St = function() {
981
+ function e(t) {
982
+ t && (this._subscribe = t);
983
+ }
984
+ return e.prototype.lift = function(t) {
985
+ var r = new e();
986
+ return r.source = this, r.operator = t, r;
987
+ }, e.prototype.subscribe = function(t, r, n) {
988
+ var i = this, o = Mn(t) ? t : new tt(t, r, n);
989
+ return _e(function() {
990
+ var s = i, a = s.operator, l = s.source;
991
+ o.add(a ? a.call(o, l) : l ? i._subscribe(o) : i._trySubscribe(o));
992
+ }), o;
993
+ }, e.prototype._trySubscribe = function(t) {
994
+ try {
995
+ return this._subscribe(t);
996
+ } catch (r) {
997
+ t.error(r);
998
+ }
999
+ }, e.prototype.forEach = function(t, r) {
1000
+ var n = this;
1001
+ return r = Tt(r), new r(function(i, o) {
1002
+ var s = new tt({
1003
+ next: function(a) {
1004
+ try {
1005
+ t(a);
1006
+ } catch (l) {
1007
+ o(l), s.unsubscribe();
1008
+ }
1009
+ },
1010
+ error: o,
1011
+ complete: i
1012
+ });
1013
+ n.subscribe(s);
1014
+ });
1015
+ }, e.prototype._subscribe = function(t) {
1016
+ var r;
1017
+ return (r = this.source) === null || r === void 0 ? void 0 : r.subscribe(t);
1018
+ }, e.prototype[In] = function() {
1019
+ return this;
1020
+ }, e.prototype.pipe = function() {
1021
+ for (var t = [], r = 0; r < arguments.length; r++)
1022
+ t[r] = arguments[r];
1023
+ return Pn(t)(this);
1024
+ }, e.prototype.toPromise = function(t) {
1025
+ var r = this;
1026
+ return t = Tt(t), new t(function(n, i) {
1027
+ var o;
1028
+ r.subscribe(function(s) {
1029
+ return o = s;
1030
+ }, function(s) {
1031
+ return i(s);
1032
+ }, function() {
1033
+ return n(o);
1034
+ });
1035
+ });
1036
+ }, e.create = function(t) {
1037
+ return new e(t);
1038
+ }, e;
1039
+ }();
1040
+ function Tt(e) {
1041
+ var t;
1042
+ return (t = e != null ? e : Sn.Promise) !== null && t !== void 0 ? t : Promise;
1043
+ }
1044
+ function Ln(e) {
1045
+ return e && U(e.next) && U(e.error) && U(e.complete);
1046
+ }
1047
+ function Mn(e) {
1048
+ return e && e instanceof or || Ln(e) && ir(e);
1049
+ }
1050
+ var Nn = rr(function(e) {
1051
+ return function() {
1052
+ e(this), this.name = "ObjectUnsubscribedError", this.message = "object unsubscribed";
1053
+ };
1054
+ }), sr = function(e) {
1055
+ me(t, e);
1056
+ function t() {
1057
+ var r = e.call(this) || this;
1058
+ return r.closed = !1, r.currentObservers = null, r.observers = [], r.isStopped = !1, r.hasError = !1, r.thrownError = null, r;
1059
+ }
1060
+ return t.prototype.lift = function(r) {
1061
+ var n = new At(this, this);
1062
+ return n.operator = r, n;
1063
+ }, t.prototype._throwIfClosed = function() {
1064
+ if (this.closed)
1065
+ throw new Nn();
1066
+ }, t.prototype.next = function(r) {
1067
+ var n = this;
1068
+ _e(function() {
1069
+ var i, o;
1070
+ if (n._throwIfClosed(), !n.isStopped) {
1071
+ n.currentObservers || (n.currentObservers = Array.from(n.observers));
1072
+ try {
1073
+ for (var s = Je(n.currentObservers), a = s.next(); !a.done; a = s.next()) {
1074
+ var l = a.value;
1075
+ l.next(r);
1076
+ }
1077
+ } catch (u) {
1078
+ i = { error: u };
1079
+ } finally {
1080
+ try {
1081
+ a && !a.done && (o = s.return) && o.call(s);
1082
+ } finally {
1083
+ if (i)
1084
+ throw i.error;
1085
+ }
1086
+ }
1087
+ }
1088
+ });
1089
+ }, t.prototype.error = function(r) {
1090
+ var n = this;
1091
+ _e(function() {
1092
+ if (n._throwIfClosed(), !n.isStopped) {
1093
+ n.hasError = n.isStopped = !0, n.thrownError = r;
1094
+ for (var i = n.observers; i.length; )
1095
+ i.shift().error(r);
1096
+ }
1097
+ });
1098
+ }, t.prototype.complete = function() {
1099
+ var r = this;
1100
+ _e(function() {
1101
+ if (r._throwIfClosed(), !r.isStopped) {
1102
+ r.isStopped = !0;
1103
+ for (var n = r.observers; n.length; )
1104
+ n.shift().complete();
1105
+ }
1106
+ });
1107
+ }, t.prototype.unsubscribe = function() {
1108
+ this.isStopped = this.closed = !0, this.observers = this.currentObservers = null;
1109
+ }, Object.defineProperty(t.prototype, "observed", {
1110
+ get: function() {
1111
+ var r;
1112
+ return ((r = this.observers) === null || r === void 0 ? void 0 : r.length) > 0;
1113
+ },
1114
+ enumerable: !1,
1115
+ configurable: !0
1116
+ }), t.prototype._trySubscribe = function(r) {
1117
+ return this._throwIfClosed(), e.prototype._trySubscribe.call(this, r);
1118
+ }, t.prototype._subscribe = function(r) {
1119
+ return this._throwIfClosed(), this._checkFinalizedStatuses(r), this._innerSubscribe(r);
1120
+ }, t.prototype._innerSubscribe = function(r) {
1121
+ var n = this, i = this, o = i.hasError, s = i.isStopped, a = i.observers;
1122
+ return o || s ? nr : (this.currentObservers = null, a.push(r), new Oe(function() {
1123
+ n.currentObservers = null, et(a, r);
1124
+ }));
1125
+ }, t.prototype._checkFinalizedStatuses = function(r) {
1126
+ var n = this, i = n.hasError, o = n.thrownError, s = n.isStopped;
1127
+ i ? r.error(o) : s && r.complete();
1128
+ }, t.prototype.asObservable = function() {
1129
+ var r = new St();
1130
+ return r.source = this, r;
1131
+ }, t.create = function(r, n) {
1132
+ return new At(r, n);
1133
+ }, t;
1134
+ }(St), At = function(e) {
1135
+ me(t, e);
1136
+ function t(r, n) {
1137
+ var i = e.call(this) || this;
1138
+ return i.destination = r, i.source = n, i;
1139
+ }
1140
+ return t.prototype.next = function(r) {
1141
+ var n, i;
1142
+ (i = (n = this.destination) === null || n === void 0 ? void 0 : n.next) === null || i === void 0 || i.call(n, r);
1143
+ }, t.prototype.error = function(r) {
1144
+ var n, i;
1145
+ (i = (n = this.destination) === null || n === void 0 ? void 0 : n.error) === null || i === void 0 || i.call(n, r);
1146
+ }, t.prototype.complete = function() {
1147
+ var r, n;
1148
+ (n = (r = this.destination) === null || r === void 0 ? void 0 : r.complete) === null || n === void 0 || n.call(r);
1149
+ }, t.prototype._subscribe = function(r) {
1150
+ var n, i;
1151
+ return (i = (n = this.source) === null || n === void 0 ? void 0 : n.subscribe(r)) !== null && i !== void 0 ? i : nr;
1152
+ }, t;
1153
+ }(sr), ar = {
1154
+ now: function() {
1155
+ return (ar.delegate || Date).now();
1156
+ },
1157
+ delegate: void 0
1158
+ }, jn = function(e) {
1159
+ me(t, e);
1160
+ function t(r, n, i) {
1161
+ r === void 0 && (r = 1 / 0), n === void 0 && (n = 1 / 0), i === void 0 && (i = ar);
1162
+ var o = e.call(this) || this;
1163
+ return o._bufferSize = r, o._windowTime = n, o._timestampProvider = i, o._buffer = [], o._infiniteTimeWindow = !0, o._infiniteTimeWindow = n === 1 / 0, o._bufferSize = Math.max(1, r), o._windowTime = Math.max(1, n), o;
1164
+ }
1165
+ return t.prototype.next = function(r) {
1166
+ var n = this, i = n.isStopped, o = n._buffer, s = n._infiniteTimeWindow, a = n._timestampProvider, l = n._windowTime;
1167
+ i || (o.push(r), !s && o.push(a.now() + l)), this._trimBuffer(), e.prototype.next.call(this, r);
1168
+ }, t.prototype._subscribe = function(r) {
1169
+ this._throwIfClosed(), this._trimBuffer();
1170
+ for (var n = this._innerSubscribe(r), i = this, o = i._infiniteTimeWindow, s = i._buffer, a = s.slice(), l = 0; l < a.length && !r.closed; l += o ? 1 : 2)
1171
+ r.next(a[l]);
1172
+ return this._checkFinalizedStatuses(r), n;
1173
+ }, t.prototype._trimBuffer = function() {
1174
+ var r = this, n = r._bufferSize, i = r._timestampProvider, o = r._buffer, s = r._infiniteTimeWindow, a = (s ? 1 : 2) * n;
1175
+ if (n < 1 / 0 && a < o.length && o.splice(0, o.length - a), !s) {
1176
+ for (var l = i.now(), u = 0, h = 1; h < o.length && o[h] <= l; h += 2)
1177
+ u = h;
1178
+ u && o.splice(0, u + 1);
1179
+ }
1180
+ }, t;
1181
+ }(sr);
1182
+ const Ct = [], Ht = {}, Rn = (e, t = 0) => {
1183
+ if (Ct.indexOf(e) == -1) {
1184
+ const r = new jn(t);
1185
+ Ht[e] = r, Ct.push(e);
1186
+ }
1187
+ return Ht[e];
1188
+ }, z = [];
1189
+ function $n(e, t) {
1190
+ return {
1191
+ subscribe: Pe(e, t).subscribe
1192
+ };
1193
+ }
1194
+ function Pe(e, t = I) {
1195
+ let r;
1196
+ const n = /* @__PURE__ */ new Set();
1197
+ function i(a) {
1198
+ if (Zt(e, a) && (e = a, r)) {
1199
+ const l = !z.length;
1200
+ for (const u of n)
1201
+ u[1](), z.push(u, e);
1202
+ if (l) {
1203
+ for (let u = 0; u < z.length; u += 2)
1204
+ z[u][0](z[u + 1]);
1205
+ z.length = 0;
1206
+ }
1207
+ }
1208
+ }
1209
+ function o(a) {
1210
+ i(a(e));
1211
+ }
1212
+ function s(a, l = I) {
1213
+ const u = [a, l];
1214
+ return n.add(u), n.size === 1 && (r = t(i, o) || I), a(e), () => {
1215
+ n.delete(u), n.size === 0 && r && (r(), r = null);
1216
+ };
1217
+ }
1218
+ return { set: i, update: o, subscribe: s };
1219
+ }
1220
+ function re(e, t, r) {
1221
+ const n = !Array.isArray(e), i = n ? [e] : e;
1222
+ if (!i.every(Boolean))
1223
+ throw new Error("derived() expects stores as input, got a falsy value");
1224
+ const o = t.length < 2;
1225
+ return $n(r, (s, a) => {
1226
+ let l = !1;
1227
+ const u = [];
1228
+ let h = 0, c = I;
1229
+ const f = () => {
1230
+ if (h)
1231
+ return;
1232
+ c();
1233
+ const b = t(n ? u[0] : u, s, a);
1234
+ o ? s(b) : c = Ie(b) ? b : I;
1235
+ }, p = i.map(
1236
+ (b, d) => Yt(
1237
+ b,
1238
+ (y) => {
1239
+ u[d] = y, h &= ~(1 << d), l && f();
1240
+ },
1241
+ () => {
1242
+ h |= 1 << d;
1243
+ }
1244
+ )
1245
+ );
1246
+ return l = !0, f(), function() {
1247
+ de(p), c(), l = !1;
1248
+ };
1249
+ });
1250
+ }
1251
+ function Un(e) {
1252
+ return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
1253
+ }
1254
+ var Dn = function(t) {
1255
+ return kn(t) && !Gn(t);
1256
+ };
1257
+ function kn(e) {
1258
+ return !!e && typeof e == "object";
1259
+ }
1260
+ function Gn(e) {
1261
+ var t = Object.prototype.toString.call(e);
1262
+ return t === "[object RegExp]" || t === "[object Date]" || Wn(e);
1263
+ }
1264
+ var Fn = typeof Symbol == "function" && Symbol.for, Vn = Fn ? Symbol.for("react.element") : 60103;
1265
+ function Wn(e) {
1266
+ return e.$$typeof === Vn;
1267
+ }
1268
+ function zn(e) {
1269
+ return Array.isArray(e) ? [] : {};
1270
+ }
1271
+ function fe(e, t) {
1272
+ return t.clone !== !1 && t.isMergeableObject(e) ? q(zn(e), e, t) : e;
1273
+ }
1274
+ function Xn(e, t, r) {
1275
+ return e.concat(t).map(function(n) {
1276
+ return fe(n, r);
1277
+ });
1278
+ }
1279
+ function Zn(e, t) {
1280
+ if (!t.customMerge)
1281
+ return q;
1282
+ var r = t.customMerge(e);
1283
+ return typeof r == "function" ? r : q;
1284
+ }
1285
+ function Yn(e) {
1286
+ return Object.getOwnPropertySymbols ? Object.getOwnPropertySymbols(e).filter(function(t) {
1287
+ return Object.propertyIsEnumerable.call(e, t);
1288
+ }) : [];
1289
+ }
1290
+ function Bt(e) {
1291
+ return Object.keys(e).concat(Yn(e));
1292
+ }
1293
+ function lr(e, t) {
1294
+ try {
1295
+ return t in e;
1296
+ } catch (r) {
1297
+ return !1;
1298
+ }
1299
+ }
1300
+ function Qn(e, t) {
1301
+ return lr(e, t) && !(Object.hasOwnProperty.call(e, t) && Object.propertyIsEnumerable.call(e, t));
1302
+ }
1303
+ function Jn(e, t, r) {
1304
+ var n = {};
1305
+ return r.isMergeableObject(e) && Bt(e).forEach(function(i) {
1306
+ n[i] = fe(e[i], r);
1307
+ }), Bt(t).forEach(function(i) {
1308
+ Qn(e, i) || (lr(e, i) && r.isMergeableObject(t[i]) ? n[i] = Zn(i, r)(e[i], t[i], r) : n[i] = fe(t[i], r));
1309
+ }), n;
1310
+ }
1311
+ function q(e, t, r) {
1312
+ r = r || {}, r.arrayMerge = r.arrayMerge || Xn, r.isMergeableObject = r.isMergeableObject || Dn, r.cloneUnlessOtherwiseSpecified = fe;
1313
+ var n = Array.isArray(t), i = Array.isArray(e), o = n === i;
1314
+ return o ? n ? r.arrayMerge(e, t, r) : Jn(e, t, r) : fe(t, r);
1315
+ }
1316
+ q.all = function(t, r) {
1317
+ if (!Array.isArray(t))
1318
+ throw new Error("first argument should be an array");
1319
+ return t.reduce(function(n, i) {
1320
+ return q(n, i, r);
1321
+ }, {});
1322
+ };
1323
+ var qn = q, Kn = qn;
1324
+ const ei = /* @__PURE__ */ Un(Kn);
1325
+ var rt = function(e, t) {
1326
+ return rt = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(r, n) {
1327
+ r.__proto__ = n;
1328
+ } || function(r, n) {
1329
+ for (var i in n)
1330
+ Object.prototype.hasOwnProperty.call(n, i) && (r[i] = n[i]);
1331
+ }, rt(e, t);
1332
+ };
1333
+ function Le(e, t) {
1334
+ if (typeof t != "function" && t !== null)
1335
+ throw new TypeError("Class extends value " + String(t) + " is not a constructor or null");
1336
+ rt(e, t);
1337
+ function r() {
1338
+ this.constructor = e;
1339
+ }
1340
+ e.prototype = t === null ? Object.create(t) : (r.prototype = t.prototype, new r());
1341
+ }
1342
+ var R = function() {
1343
+ return R = Object.assign || function(t) {
1344
+ for (var r, n = 1, i = arguments.length; n < i; n++) {
1345
+ r = arguments[n];
1346
+ for (var o in r)
1347
+ Object.prototype.hasOwnProperty.call(r, o) && (t[o] = r[o]);
1348
+ }
1349
+ return t;
1350
+ }, R.apply(this, arguments);
1351
+ };
1352
+ function ti(e, t) {
1353
+ var r = {};
1354
+ for (var n in e)
1355
+ Object.prototype.hasOwnProperty.call(e, n) && t.indexOf(n) < 0 && (r[n] = e[n]);
1356
+ if (e != null && typeof Object.getOwnPropertySymbols == "function")
1357
+ for (var i = 0, n = Object.getOwnPropertySymbols(e); i < n.length; i++)
1358
+ t.indexOf(n[i]) < 0 && Object.prototype.propertyIsEnumerable.call(e, n[i]) && (r[n[i]] = e[n[i]]);
1359
+ return r;
1360
+ }
1361
+ function ke(e, t, r) {
1362
+ if (r || arguments.length === 2)
1363
+ for (var n = 0, i = t.length, o; n < i; n++)
1364
+ (o || !(n in t)) && (o || (o = Array.prototype.slice.call(t, 0, n)), o[n] = t[n]);
1365
+ return e.concat(o || Array.prototype.slice.call(t));
1366
+ }
1367
+ function Ge(e, t) {
1368
+ var r = t && t.cache ? t.cache : li, n = t && t.serializer ? t.serializer : si, i = t && t.strategy ? t.strategy : ii;
1369
+ return i(e, {
1370
+ cache: r,
1371
+ serializer: n
1372
+ });
1373
+ }
1374
+ function ri(e) {
1375
+ return e == null || typeof e == "number" || typeof e == "boolean";
1376
+ }
1377
+ function ni(e, t, r, n) {
1378
+ var i = ri(n) ? n : r(n), o = t.get(i);
1379
+ return typeof o == "undefined" && (o = e.call(this, n), t.set(i, o)), o;
1380
+ }
1381
+ function ur(e, t, r) {
1382
+ var n = Array.prototype.slice.call(arguments, 3), i = r(n), o = t.get(i);
1383
+ return typeof o == "undefined" && (o = e.apply(this, n), t.set(i, o)), o;
1384
+ }
1385
+ function hr(e, t, r, n, i) {
1386
+ return r.bind(t, e, n, i);
1387
+ }
1388
+ function ii(e, t) {
1389
+ var r = e.length === 1 ? ni : ur;
1390
+ return hr(e, this, r, t.cache.create(), t.serializer);
1391
+ }
1392
+ function oi(e, t) {
1393
+ return hr(e, this, ur, t.cache.create(), t.serializer);
1394
+ }
1395
+ var si = function() {
1396
+ return JSON.stringify(arguments);
1397
+ }, ai = (
1398
+ /** @class */
1399
+ function() {
1400
+ function e() {
1401
+ this.cache = /* @__PURE__ */ Object.create(null);
1402
+ }
1403
+ return e.prototype.get = function(t) {
1404
+ return this.cache[t];
1405
+ }, e.prototype.set = function(t, r) {
1406
+ this.cache[t] = r;
1407
+ }, e;
1408
+ }()
1409
+ ), li = {
1410
+ create: function() {
1411
+ return new ai();
1412
+ }
1413
+ }, Fe = {
1414
+ variadic: oi
1415
+ }, Ce = function() {
1416
+ return Ce = Object.assign || function(t) {
1417
+ for (var r, n = 1, i = arguments.length; n < i; n++) {
1418
+ r = arguments[n];
1419
+ for (var o in r)
1420
+ Object.prototype.hasOwnProperty.call(r, o) && (t[o] = r[o]);
1421
+ }
1422
+ return t;
1423
+ }, Ce.apply(this, arguments);
1424
+ };
1425
+ var g;
1426
+ (function(e) {
1427
+ e[e.EXPECT_ARGUMENT_CLOSING_BRACE = 1] = "EXPECT_ARGUMENT_CLOSING_BRACE", e[e.EMPTY_ARGUMENT = 2] = "EMPTY_ARGUMENT", e[e.MALFORMED_ARGUMENT = 3] = "MALFORMED_ARGUMENT", e[e.EXPECT_ARGUMENT_TYPE = 4] = "EXPECT_ARGUMENT_TYPE", e[e.INVALID_ARGUMENT_TYPE = 5] = "INVALID_ARGUMENT_TYPE", e[e.EXPECT_ARGUMENT_STYLE = 6] = "EXPECT_ARGUMENT_STYLE", e[e.INVALID_NUMBER_SKELETON = 7] = "INVALID_NUMBER_SKELETON", e[e.INVALID_DATE_TIME_SKELETON = 8] = "INVALID_DATE_TIME_SKELETON", e[e.EXPECT_NUMBER_SKELETON = 9] = "EXPECT_NUMBER_SKELETON", e[e.EXPECT_DATE_TIME_SKELETON = 10] = "EXPECT_DATE_TIME_SKELETON", e[e.UNCLOSED_QUOTE_IN_ARGUMENT_STYLE = 11] = "UNCLOSED_QUOTE_IN_ARGUMENT_STYLE", e[e.EXPECT_SELECT_ARGUMENT_OPTIONS = 12] = "EXPECT_SELECT_ARGUMENT_OPTIONS", e[e.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE = 13] = "EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE", e[e.INVALID_PLURAL_ARGUMENT_OFFSET_VALUE = 14] = "INVALID_PLURAL_ARGUMENT_OFFSET_VALUE", e[e.EXPECT_SELECT_ARGUMENT_SELECTOR = 15] = "EXPECT_SELECT_ARGUMENT_SELECTOR", e[e.EXPECT_PLURAL_ARGUMENT_SELECTOR = 16] = "EXPECT_PLURAL_ARGUMENT_SELECTOR", e[e.EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT = 17] = "EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT", e[e.EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT = 18] = "EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT", e[e.INVALID_PLURAL_ARGUMENT_SELECTOR = 19] = "INVALID_PLURAL_ARGUMENT_SELECTOR", e[e.DUPLICATE_PLURAL_ARGUMENT_SELECTOR = 20] = "DUPLICATE_PLURAL_ARGUMENT_SELECTOR", e[e.DUPLICATE_SELECT_ARGUMENT_SELECTOR = 21] = "DUPLICATE_SELECT_ARGUMENT_SELECTOR", e[e.MISSING_OTHER_CLAUSE = 22] = "MISSING_OTHER_CLAUSE", e[e.INVALID_TAG = 23] = "INVALID_TAG", e[e.INVALID_TAG_NAME = 25] = "INVALID_TAG_NAME", e[e.UNMATCHED_CLOSING_TAG = 26] = "UNMATCHED_CLOSING_TAG", e[e.UNCLOSED_TAG = 27] = "UNCLOSED_TAG";
1428
+ })(g || (g = {}));
1429
+ var _;
1430
+ (function(e) {
1431
+ e[e.literal = 0] = "literal", e[e.argument = 1] = "argument", e[e.number = 2] = "number", e[e.date = 3] = "date", e[e.time = 4] = "time", e[e.select = 5] = "select", e[e.plural = 6] = "plural", e[e.pound = 7] = "pound", e[e.tag = 8] = "tag";
1432
+ })(_ || (_ = {}));
1433
+ var K;
1434
+ (function(e) {
1435
+ e[e.number = 0] = "number", e[e.dateTime = 1] = "dateTime";
1436
+ })(K || (K = {}));
1437
+ function It(e) {
1438
+ return e.type === _.literal;
1439
+ }
1440
+ function ui(e) {
1441
+ return e.type === _.argument;
1442
+ }
1443
+ function cr(e) {
1444
+ return e.type === _.number;
1445
+ }
1446
+ function fr(e) {
1447
+ return e.type === _.date;
1448
+ }
1449
+ function pr(e) {
1450
+ return e.type === _.time;
1451
+ }
1452
+ function dr(e) {
1453
+ return e.type === _.select;
1454
+ }
1455
+ function mr(e) {
1456
+ return e.type === _.plural;
1457
+ }
1458
+ function hi(e) {
1459
+ return e.type === _.pound;
1460
+ }
1461
+ function br(e) {
1462
+ return e.type === _.tag;
1463
+ }
1464
+ function gr(e) {
1465
+ return !!(e && typeof e == "object" && e.type === K.number);
1466
+ }
1467
+ function nt(e) {
1468
+ return !!(e && typeof e == "object" && e.type === K.dateTime);
1469
+ }
1470
+ var vr = /[ \xA0\u1680\u2000-\u200A\u202F\u205F\u3000]/, ci = /(?:[Eec]{1,6}|G{1,5}|[Qq]{1,5}|(?:[yYur]+|U{1,5})|[ML]{1,5}|d{1,2}|D{1,3}|F{1}|[abB]{1,5}|[hkHK]{1,2}|w{1,2}|W{1}|m{1,2}|s{1,2}|[zZOvVxX]{1,4})(?=([^']*'[^']*')*[^']*$)/g;
1471
+ function fi(e) {
1472
+ var t = {};
1473
+ return e.replace(ci, function(r) {
1474
+ var n = r.length;
1475
+ switch (r[0]) {
1476
+ case "G":
1477
+ t.era = n === 4 ? "long" : n === 5 ? "narrow" : "short";
1478
+ break;
1479
+ case "y":
1480
+ t.year = n === 2 ? "2-digit" : "numeric";
1481
+ break;
1482
+ case "Y":
1483
+ case "u":
1484
+ case "U":
1485
+ case "r":
1486
+ throw new RangeError("`Y/u/U/r` (year) patterns are not supported, use `y` instead");
1487
+ case "q":
1488
+ case "Q":
1489
+ throw new RangeError("`q/Q` (quarter) patterns are not supported");
1490
+ case "M":
1491
+ case "L":
1492
+ t.month = ["numeric", "2-digit", "short", "long", "narrow"][n - 1];
1493
+ break;
1494
+ case "w":
1495
+ case "W":
1496
+ throw new RangeError("`w/W` (week) patterns are not supported");
1497
+ case "d":
1498
+ t.day = ["numeric", "2-digit"][n - 1];
1499
+ break;
1500
+ case "D":
1501
+ case "F":
1502
+ case "g":
1503
+ throw new RangeError("`D/F/g` (day) patterns are not supported, use `d` instead");
1504
+ case "E":
1505
+ t.weekday = n === 4 ? "long" : n === 5 ? "narrow" : "short";
1506
+ break;
1507
+ case "e":
1508
+ if (n < 4)
1509
+ throw new RangeError("`e..eee` (weekday) patterns are not supported");
1510
+ t.weekday = ["short", "long", "narrow", "short"][n - 4];
1511
+ break;
1512
+ case "c":
1513
+ if (n < 4)
1514
+ throw new RangeError("`c..ccc` (weekday) patterns are not supported");
1515
+ t.weekday = ["short", "long", "narrow", "short"][n - 4];
1516
+ break;
1517
+ case "a":
1518
+ t.hour12 = !0;
1519
+ break;
1520
+ case "b":
1521
+ case "B":
1522
+ throw new RangeError("`b/B` (period) patterns are not supported, use `a` instead");
1523
+ case "h":
1524
+ t.hourCycle = "h12", t.hour = ["numeric", "2-digit"][n - 1];
1525
+ break;
1526
+ case "H":
1527
+ t.hourCycle = "h23", t.hour = ["numeric", "2-digit"][n - 1];
1528
+ break;
1529
+ case "K":
1530
+ t.hourCycle = "h11", t.hour = ["numeric", "2-digit"][n - 1];
1531
+ break;
1532
+ case "k":
1533
+ t.hourCycle = "h24", t.hour = ["numeric", "2-digit"][n - 1];
1534
+ break;
1535
+ case "j":
1536
+ case "J":
1537
+ case "C":
1538
+ throw new RangeError("`j/J/C` (hour) patterns are not supported, use `h/H/K/k` instead");
1539
+ case "m":
1540
+ t.minute = ["numeric", "2-digit"][n - 1];
1541
+ break;
1542
+ case "s":
1543
+ t.second = ["numeric", "2-digit"][n - 1];
1544
+ break;
1545
+ case "S":
1546
+ case "A":
1547
+ throw new RangeError("`S/A` (second) patterns are not supported, use `s` instead");
1548
+ case "z":
1549
+ t.timeZoneName = n < 4 ? "short" : "long";
1550
+ break;
1551
+ case "Z":
1552
+ case "O":
1553
+ case "v":
1554
+ case "V":
1555
+ case "X":
1556
+ case "x":
1557
+ throw new RangeError("`Z/O/v/V/X/x` (timeZone) patterns are not supported, use `z` instead");
1558
+ }
1559
+ return "";
1560
+ }), t;
1561
+ }
1562
+ var w = function() {
1563
+ return w = Object.assign || function(t) {
1564
+ for (var r, n = 1, i = arguments.length; n < i; n++) {
1565
+ r = arguments[n];
1566
+ for (var o in r)
1567
+ Object.prototype.hasOwnProperty.call(r, o) && (t[o] = r[o]);
1568
+ }
1569
+ return t;
1570
+ }, w.apply(this, arguments);
1571
+ };
1572
+ var pi = /[\t-\r \x85\u200E\u200F\u2028\u2029]/i;
1573
+ function di(e) {
1574
+ if (e.length === 0)
1575
+ throw new Error("Number skeleton cannot be empty");
1576
+ for (var t = e.split(pi).filter(function(f) {
1577
+ return f.length > 0;
1578
+ }), r = [], n = 0, i = t; n < i.length; n++) {
1579
+ var o = i[n], s = o.split("/");
1580
+ if (s.length === 0)
1581
+ throw new Error("Invalid number skeleton");
1582
+ for (var a = s[0], l = s.slice(1), u = 0, h = l; u < h.length; u++) {
1583
+ var c = h[u];
1584
+ if (c.length === 0)
1585
+ throw new Error("Invalid number skeleton");
1586
+ }
1587
+ r.push({ stem: a, options: l });
1588
+ }
1589
+ return r;
1590
+ }
1591
+ function mi(e) {
1592
+ return e.replace(/^(.*?)-/, "");
1593
+ }
1594
+ var Ot = /^\.(?:(0+)(\*)?|(#+)|(0+)(#+))$/g, yr = /^(@+)?(\+|#+)?[rs]?$/g, bi = /(\*)(0+)|(#+)(0+)|(0+)/g, xr = /^(0+)$/;
1595
+ function Pt(e) {
1596
+ var t = {};
1597
+ return e[e.length - 1] === "r" ? t.roundingPriority = "morePrecision" : e[e.length - 1] === "s" && (t.roundingPriority = "lessPrecision"), e.replace(yr, function(r, n, i) {
1598
+ return typeof i != "string" ? (t.minimumSignificantDigits = n.length, t.maximumSignificantDigits = n.length) : i === "+" ? t.minimumSignificantDigits = n.length : n[0] === "#" ? t.maximumSignificantDigits = n.length : (t.minimumSignificantDigits = n.length, t.maximumSignificantDigits = n.length + (typeof i == "string" ? i.length : 0)), "";
1599
+ }), t;
1600
+ }
1601
+ function _r(e) {
1602
+ switch (e) {
1603
+ case "sign-auto":
1604
+ return {
1605
+ signDisplay: "auto"
1606
+ };
1607
+ case "sign-accounting":
1608
+ case "()":
1609
+ return {
1610
+ currencySign: "accounting"
1611
+ };
1612
+ case "sign-always":
1613
+ case "+!":
1614
+ return {
1615
+ signDisplay: "always"
1616
+ };
1617
+ case "sign-accounting-always":
1618
+ case "()!":
1619
+ return {
1620
+ signDisplay: "always",
1621
+ currencySign: "accounting"
1622
+ };
1623
+ case "sign-except-zero":
1624
+ case "+?":
1625
+ return {
1626
+ signDisplay: "exceptZero"
1627
+ };
1628
+ case "sign-accounting-except-zero":
1629
+ case "()?":
1630
+ return {
1631
+ signDisplay: "exceptZero",
1632
+ currencySign: "accounting"
1633
+ };
1634
+ case "sign-never":
1635
+ case "+_":
1636
+ return {
1637
+ signDisplay: "never"
1638
+ };
1639
+ }
1640
+ }
1641
+ function gi(e) {
1642
+ var t;
1643
+ if (e[0] === "E" && e[1] === "E" ? (t = {
1644
+ notation: "engineering"
1645
+ }, e = e.slice(2)) : e[0] === "E" && (t = {
1646
+ notation: "scientific"
1647
+ }, e = e.slice(1)), t) {
1648
+ var r = e.slice(0, 2);
1649
+ if (r === "+!" ? (t.signDisplay = "always", e = e.slice(2)) : r === "+?" && (t.signDisplay = "exceptZero", e = e.slice(2)), !xr.test(e))
1650
+ throw new Error("Malformed concise eng/scientific notation");
1651
+ t.minimumIntegerDigits = e.length;
1652
+ }
1653
+ return t;
1654
+ }
1655
+ function Lt(e) {
1656
+ var t = {}, r = _r(e);
1657
+ return r || t;
1658
+ }
1659
+ function vi(e) {
1660
+ for (var t = {}, r = 0, n = e; r < n.length; r++) {
1661
+ var i = n[r];
1662
+ switch (i.stem) {
1663
+ case "percent":
1664
+ case "%":
1665
+ t.style = "percent";
1666
+ continue;
1667
+ case "%x100":
1668
+ t.style = "percent", t.scale = 100;
1669
+ continue;
1670
+ case "currency":
1671
+ t.style = "currency", t.currency = i.options[0];
1672
+ continue;
1673
+ case "group-off":
1674
+ case ",_":
1675
+ t.useGrouping = !1;
1676
+ continue;
1677
+ case "precision-integer":
1678
+ case ".":
1679
+ t.maximumFractionDigits = 0;
1680
+ continue;
1681
+ case "measure-unit":
1682
+ case "unit":
1683
+ t.style = "unit", t.unit = mi(i.options[0]);
1684
+ continue;
1685
+ case "compact-short":
1686
+ case "K":
1687
+ t.notation = "compact", t.compactDisplay = "short";
1688
+ continue;
1689
+ case "compact-long":
1690
+ case "KK":
1691
+ t.notation = "compact", t.compactDisplay = "long";
1692
+ continue;
1693
+ case "scientific":
1694
+ t = w(w(w({}, t), { notation: "scientific" }), i.options.reduce(function(l, u) {
1695
+ return w(w({}, l), Lt(u));
1696
+ }, {}));
1697
+ continue;
1698
+ case "engineering":
1699
+ t = w(w(w({}, t), { notation: "engineering" }), i.options.reduce(function(l, u) {
1700
+ return w(w({}, l), Lt(u));
1701
+ }, {}));
1702
+ continue;
1703
+ case "notation-simple":
1704
+ t.notation = "standard";
1705
+ continue;
1706
+ case "unit-width-narrow":
1707
+ t.currencyDisplay = "narrowSymbol", t.unitDisplay = "narrow";
1708
+ continue;
1709
+ case "unit-width-short":
1710
+ t.currencyDisplay = "code", t.unitDisplay = "short";
1711
+ continue;
1712
+ case "unit-width-full-name":
1713
+ t.currencyDisplay = "name", t.unitDisplay = "long";
1714
+ continue;
1715
+ case "unit-width-iso-code":
1716
+ t.currencyDisplay = "symbol";
1717
+ continue;
1718
+ case "scale":
1719
+ t.scale = parseFloat(i.options[0]);
1720
+ continue;
1721
+ case "rounding-mode-floor":
1722
+ t.roundingMode = "floor";
1723
+ continue;
1724
+ case "rounding-mode-ceiling":
1725
+ t.roundingMode = "ceil";
1726
+ continue;
1727
+ case "rounding-mode-down":
1728
+ t.roundingMode = "trunc";
1729
+ continue;
1730
+ case "rounding-mode-up":
1731
+ t.roundingMode = "expand";
1732
+ continue;
1733
+ case "rounding-mode-half-even":
1734
+ t.roundingMode = "halfEven";
1735
+ continue;
1736
+ case "rounding-mode-half-down":
1737
+ t.roundingMode = "halfTrunc";
1738
+ continue;
1739
+ case "rounding-mode-half-up":
1740
+ t.roundingMode = "halfExpand";
1741
+ continue;
1742
+ case "integer-width":
1743
+ if (i.options.length > 1)
1744
+ throw new RangeError("integer-width stems only accept a single optional option");
1745
+ i.options[0].replace(bi, function(l, u, h, c, f, p) {
1746
+ if (u)
1747
+ t.minimumIntegerDigits = h.length;
1748
+ else {
1749
+ if (c && f)
1750
+ throw new Error("We currently do not support maximum integer digits");
1751
+ if (p)
1752
+ throw new Error("We currently do not support exact integer digits");
1753
+ }
1754
+ return "";
1755
+ });
1756
+ continue;
1757
+ }
1758
+ if (xr.test(i.stem)) {
1759
+ t.minimumIntegerDigits = i.stem.length;
1760
+ continue;
1761
+ }
1762
+ if (Ot.test(i.stem)) {
1763
+ if (i.options.length > 1)
1764
+ throw new RangeError("Fraction-precision stems only accept a single optional option");
1765
+ i.stem.replace(Ot, function(l, u, h, c, f, p) {
1766
+ return h === "*" ? t.minimumFractionDigits = u.length : c && c[0] === "#" ? t.maximumFractionDigits = c.length : f && p ? (t.minimumFractionDigits = f.length, t.maximumFractionDigits = f.length + p.length) : (t.minimumFractionDigits = u.length, t.maximumFractionDigits = u.length), "";
1767
+ });
1768
+ var o = i.options[0];
1769
+ o === "w" ? t = w(w({}, t), { trailingZeroDisplay: "stripIfInteger" }) : o && (t = w(w({}, t), Pt(o)));
1770
+ continue;
1771
+ }
1772
+ if (yr.test(i.stem)) {
1773
+ t = w(w({}, t), Pt(i.stem));
1774
+ continue;
1775
+ }
1776
+ var s = _r(i.stem);
1777
+ s && (t = w(w({}, t), s));
1778
+ var a = gi(i.stem);
1779
+ a && (t = w(w({}, t), a));
1780
+ }
1781
+ return t;
1782
+ }
1783
+ var ye = {
1784
+ "001": [
1785
+ "H",
1786
+ "h"
1787
+ ],
1788
+ 419: [
1789
+ "h",
1790
+ "H",
1791
+ "hB",
1792
+ "hb"
1793
+ ],
1794
+ AC: [
1795
+ "H",
1796
+ "h",
1797
+ "hb",
1798
+ "hB"
1799
+ ],
1800
+ AD: [
1801
+ "H",
1802
+ "hB"
1803
+ ],
1804
+ AE: [
1805
+ "h",
1806
+ "hB",
1807
+ "hb",
1808
+ "H"
1809
+ ],
1810
+ AF: [
1811
+ "H",
1812
+ "hb",
1813
+ "hB",
1814
+ "h"
1815
+ ],
1816
+ AG: [
1817
+ "h",
1818
+ "hb",
1819
+ "H",
1820
+ "hB"
1821
+ ],
1822
+ AI: [
1823
+ "H",
1824
+ "h",
1825
+ "hb",
1826
+ "hB"
1827
+ ],
1828
+ AL: [
1829
+ "h",
1830
+ "H",
1831
+ "hB"
1832
+ ],
1833
+ AM: [
1834
+ "H",
1835
+ "hB"
1836
+ ],
1837
+ AO: [
1838
+ "H",
1839
+ "hB"
1840
+ ],
1841
+ AR: [
1842
+ "h",
1843
+ "H",
1844
+ "hB",
1845
+ "hb"
1846
+ ],
1847
+ AS: [
1848
+ "h",
1849
+ "H"
1850
+ ],
1851
+ AT: [
1852
+ "H",
1853
+ "hB"
1854
+ ],
1855
+ AU: [
1856
+ "h",
1857
+ "hb",
1858
+ "H",
1859
+ "hB"
1860
+ ],
1861
+ AW: [
1862
+ "H",
1863
+ "hB"
1864
+ ],
1865
+ AX: [
1866
+ "H"
1867
+ ],
1868
+ AZ: [
1869
+ "H",
1870
+ "hB",
1871
+ "h"
1872
+ ],
1873
+ BA: [
1874
+ "H",
1875
+ "hB",
1876
+ "h"
1877
+ ],
1878
+ BB: [
1879
+ "h",
1880
+ "hb",
1881
+ "H",
1882
+ "hB"
1883
+ ],
1884
+ BD: [
1885
+ "h",
1886
+ "hB",
1887
+ "H"
1888
+ ],
1889
+ BE: [
1890
+ "H",
1891
+ "hB"
1892
+ ],
1893
+ BF: [
1894
+ "H",
1895
+ "hB"
1896
+ ],
1897
+ BG: [
1898
+ "H",
1899
+ "hB",
1900
+ "h"
1901
+ ],
1902
+ BH: [
1903
+ "h",
1904
+ "hB",
1905
+ "hb",
1906
+ "H"
1907
+ ],
1908
+ BI: [
1909
+ "H",
1910
+ "h"
1911
+ ],
1912
+ BJ: [
1913
+ "H",
1914
+ "hB"
1915
+ ],
1916
+ BL: [
1917
+ "H",
1918
+ "hB"
1919
+ ],
1920
+ BM: [
1921
+ "h",
1922
+ "hb",
1923
+ "H",
1924
+ "hB"
1925
+ ],
1926
+ BN: [
1927
+ "hb",
1928
+ "hB",
1929
+ "h",
1930
+ "H"
1931
+ ],
1932
+ BO: [
1933
+ "h",
1934
+ "H",
1935
+ "hB",
1936
+ "hb"
1937
+ ],
1938
+ BQ: [
1939
+ "H"
1940
+ ],
1941
+ BR: [
1942
+ "H",
1943
+ "hB"
1944
+ ],
1945
+ BS: [
1946
+ "h",
1947
+ "hb",
1948
+ "H",
1949
+ "hB"
1950
+ ],
1951
+ BT: [
1952
+ "h",
1953
+ "H"
1954
+ ],
1955
+ BW: [
1956
+ "H",
1957
+ "h",
1958
+ "hb",
1959
+ "hB"
1960
+ ],
1961
+ BY: [
1962
+ "H",
1963
+ "h"
1964
+ ],
1965
+ BZ: [
1966
+ "H",
1967
+ "h",
1968
+ "hb",
1969
+ "hB"
1970
+ ],
1971
+ CA: [
1972
+ "h",
1973
+ "hb",
1974
+ "H",
1975
+ "hB"
1976
+ ],
1977
+ CC: [
1978
+ "H",
1979
+ "h",
1980
+ "hb",
1981
+ "hB"
1982
+ ],
1983
+ CD: [
1984
+ "hB",
1985
+ "H"
1986
+ ],
1987
+ CF: [
1988
+ "H",
1989
+ "h",
1990
+ "hB"
1991
+ ],
1992
+ CG: [
1993
+ "H",
1994
+ "hB"
1995
+ ],
1996
+ CH: [
1997
+ "H",
1998
+ "hB",
1999
+ "h"
2000
+ ],
2001
+ CI: [
2002
+ "H",
2003
+ "hB"
2004
+ ],
2005
+ CK: [
2006
+ "H",
2007
+ "h",
2008
+ "hb",
2009
+ "hB"
2010
+ ],
2011
+ CL: [
2012
+ "h",
2013
+ "H",
2014
+ "hB",
2015
+ "hb"
2016
+ ],
2017
+ CM: [
2018
+ "H",
2019
+ "h",
2020
+ "hB"
2021
+ ],
2022
+ CN: [
2023
+ "H",
2024
+ "hB",
2025
+ "hb",
2026
+ "h"
2027
+ ],
2028
+ CO: [
2029
+ "h",
2030
+ "H",
2031
+ "hB",
2032
+ "hb"
2033
+ ],
2034
+ CP: [
2035
+ "H"
2036
+ ],
2037
+ CR: [
2038
+ "h",
2039
+ "H",
2040
+ "hB",
2041
+ "hb"
2042
+ ],
2043
+ CU: [
2044
+ "h",
2045
+ "H",
2046
+ "hB",
2047
+ "hb"
2048
+ ],
2049
+ CV: [
2050
+ "H",
2051
+ "hB"
2052
+ ],
2053
+ CW: [
2054
+ "H",
2055
+ "hB"
2056
+ ],
2057
+ CX: [
2058
+ "H",
2059
+ "h",
2060
+ "hb",
2061
+ "hB"
2062
+ ],
2063
+ CY: [
2064
+ "h",
2065
+ "H",
2066
+ "hb",
2067
+ "hB"
2068
+ ],
2069
+ CZ: [
2070
+ "H"
2071
+ ],
2072
+ DE: [
2073
+ "H",
2074
+ "hB"
2075
+ ],
2076
+ DG: [
2077
+ "H",
2078
+ "h",
2079
+ "hb",
2080
+ "hB"
2081
+ ],
2082
+ DJ: [
2083
+ "h",
2084
+ "H"
2085
+ ],
2086
+ DK: [
2087
+ "H"
2088
+ ],
2089
+ DM: [
2090
+ "h",
2091
+ "hb",
2092
+ "H",
2093
+ "hB"
2094
+ ],
2095
+ DO: [
2096
+ "h",
2097
+ "H",
2098
+ "hB",
2099
+ "hb"
2100
+ ],
2101
+ DZ: [
2102
+ "h",
2103
+ "hB",
2104
+ "hb",
2105
+ "H"
2106
+ ],
2107
+ EA: [
2108
+ "H",
2109
+ "h",
2110
+ "hB",
2111
+ "hb"
2112
+ ],
2113
+ EC: [
2114
+ "h",
2115
+ "H",
2116
+ "hB",
2117
+ "hb"
2118
+ ],
2119
+ EE: [
2120
+ "H",
2121
+ "hB"
2122
+ ],
2123
+ EG: [
2124
+ "h",
2125
+ "hB",
2126
+ "hb",
2127
+ "H"
2128
+ ],
2129
+ EH: [
2130
+ "h",
2131
+ "hB",
2132
+ "hb",
2133
+ "H"
2134
+ ],
2135
+ ER: [
2136
+ "h",
2137
+ "H"
2138
+ ],
2139
+ ES: [
2140
+ "H",
2141
+ "hB",
2142
+ "h",
2143
+ "hb"
2144
+ ],
2145
+ ET: [
2146
+ "hB",
2147
+ "hb",
2148
+ "h",
2149
+ "H"
2150
+ ],
2151
+ FI: [
2152
+ "H"
2153
+ ],
2154
+ FJ: [
2155
+ "h",
2156
+ "hb",
2157
+ "H",
2158
+ "hB"
2159
+ ],
2160
+ FK: [
2161
+ "H",
2162
+ "h",
2163
+ "hb",
2164
+ "hB"
2165
+ ],
2166
+ FM: [
2167
+ "h",
2168
+ "hb",
2169
+ "H",
2170
+ "hB"
2171
+ ],
2172
+ FO: [
2173
+ "H",
2174
+ "h"
2175
+ ],
2176
+ FR: [
2177
+ "H",
2178
+ "hB"
2179
+ ],
2180
+ GA: [
2181
+ "H",
2182
+ "hB"
2183
+ ],
2184
+ GB: [
2185
+ "H",
2186
+ "h",
2187
+ "hb",
2188
+ "hB"
2189
+ ],
2190
+ GD: [
2191
+ "h",
2192
+ "hb",
2193
+ "H",
2194
+ "hB"
2195
+ ],
2196
+ GE: [
2197
+ "H",
2198
+ "hB",
2199
+ "h"
2200
+ ],
2201
+ GF: [
2202
+ "H",
2203
+ "hB"
2204
+ ],
2205
+ GG: [
2206
+ "H",
2207
+ "h",
2208
+ "hb",
2209
+ "hB"
2210
+ ],
2211
+ GH: [
2212
+ "h",
2213
+ "H"
2214
+ ],
2215
+ GI: [
2216
+ "H",
2217
+ "h",
2218
+ "hb",
2219
+ "hB"
2220
+ ],
2221
+ GL: [
2222
+ "H",
2223
+ "h"
2224
+ ],
2225
+ GM: [
2226
+ "h",
2227
+ "hb",
2228
+ "H",
2229
+ "hB"
2230
+ ],
2231
+ GN: [
2232
+ "H",
2233
+ "hB"
2234
+ ],
2235
+ GP: [
2236
+ "H",
2237
+ "hB"
2238
+ ],
2239
+ GQ: [
2240
+ "H",
2241
+ "hB",
2242
+ "h",
2243
+ "hb"
2244
+ ],
2245
+ GR: [
2246
+ "h",
2247
+ "H",
2248
+ "hb",
2249
+ "hB"
2250
+ ],
2251
+ GT: [
2252
+ "h",
2253
+ "H",
2254
+ "hB",
2255
+ "hb"
2256
+ ],
2257
+ GU: [
2258
+ "h",
2259
+ "hb",
2260
+ "H",
2261
+ "hB"
2262
+ ],
2263
+ GW: [
2264
+ "H",
2265
+ "hB"
2266
+ ],
2267
+ GY: [
2268
+ "h",
2269
+ "hb",
2270
+ "H",
2271
+ "hB"
2272
+ ],
2273
+ HK: [
2274
+ "h",
2275
+ "hB",
2276
+ "hb",
2277
+ "H"
2278
+ ],
2279
+ HN: [
2280
+ "h",
2281
+ "H",
2282
+ "hB",
2283
+ "hb"
2284
+ ],
2285
+ HR: [
2286
+ "H",
2287
+ "hB"
2288
+ ],
2289
+ HU: [
2290
+ "H",
2291
+ "h"
2292
+ ],
2293
+ IC: [
2294
+ "H",
2295
+ "h",
2296
+ "hB",
2297
+ "hb"
2298
+ ],
2299
+ ID: [
2300
+ "H"
2301
+ ],
2302
+ IE: [
2303
+ "H",
2304
+ "h",
2305
+ "hb",
2306
+ "hB"
2307
+ ],
2308
+ IL: [
2309
+ "H",
2310
+ "hB"
2311
+ ],
2312
+ IM: [
2313
+ "H",
2314
+ "h",
2315
+ "hb",
2316
+ "hB"
2317
+ ],
2318
+ IN: [
2319
+ "h",
2320
+ "H"
2321
+ ],
2322
+ IO: [
2323
+ "H",
2324
+ "h",
2325
+ "hb",
2326
+ "hB"
2327
+ ],
2328
+ IQ: [
2329
+ "h",
2330
+ "hB",
2331
+ "hb",
2332
+ "H"
2333
+ ],
2334
+ IR: [
2335
+ "hB",
2336
+ "H"
2337
+ ],
2338
+ IS: [
2339
+ "H"
2340
+ ],
2341
+ IT: [
2342
+ "H",
2343
+ "hB"
2344
+ ],
2345
+ JE: [
2346
+ "H",
2347
+ "h",
2348
+ "hb",
2349
+ "hB"
2350
+ ],
2351
+ JM: [
2352
+ "h",
2353
+ "hb",
2354
+ "H",
2355
+ "hB"
2356
+ ],
2357
+ JO: [
2358
+ "h",
2359
+ "hB",
2360
+ "hb",
2361
+ "H"
2362
+ ],
2363
+ JP: [
2364
+ "H",
2365
+ "K",
2366
+ "h"
2367
+ ],
2368
+ KE: [
2369
+ "hB",
2370
+ "hb",
2371
+ "H",
2372
+ "h"
2373
+ ],
2374
+ KG: [
2375
+ "H",
2376
+ "h",
2377
+ "hB",
2378
+ "hb"
2379
+ ],
2380
+ KH: [
2381
+ "hB",
2382
+ "h",
2383
+ "H",
2384
+ "hb"
2385
+ ],
2386
+ KI: [
2387
+ "h",
2388
+ "hb",
2389
+ "H",
2390
+ "hB"
2391
+ ],
2392
+ KM: [
2393
+ "H",
2394
+ "h",
2395
+ "hB",
2396
+ "hb"
2397
+ ],
2398
+ KN: [
2399
+ "h",
2400
+ "hb",
2401
+ "H",
2402
+ "hB"
2403
+ ],
2404
+ KP: [
2405
+ "h",
2406
+ "H",
2407
+ "hB",
2408
+ "hb"
2409
+ ],
2410
+ KR: [
2411
+ "h",
2412
+ "H",
2413
+ "hB",
2414
+ "hb"
2415
+ ],
2416
+ KW: [
2417
+ "h",
2418
+ "hB",
2419
+ "hb",
2420
+ "H"
2421
+ ],
2422
+ KY: [
2423
+ "h",
2424
+ "hb",
2425
+ "H",
2426
+ "hB"
2427
+ ],
2428
+ KZ: [
2429
+ "H",
2430
+ "hB"
2431
+ ],
2432
+ LA: [
2433
+ "H",
2434
+ "hb",
2435
+ "hB",
2436
+ "h"
2437
+ ],
2438
+ LB: [
2439
+ "h",
2440
+ "hB",
2441
+ "hb",
2442
+ "H"
2443
+ ],
2444
+ LC: [
2445
+ "h",
2446
+ "hb",
2447
+ "H",
2448
+ "hB"
2449
+ ],
2450
+ LI: [
2451
+ "H",
2452
+ "hB",
2453
+ "h"
2454
+ ],
2455
+ LK: [
2456
+ "H",
2457
+ "h",
2458
+ "hB",
2459
+ "hb"
2460
+ ],
2461
+ LR: [
2462
+ "h",
2463
+ "hb",
2464
+ "H",
2465
+ "hB"
2466
+ ],
2467
+ LS: [
2468
+ "h",
2469
+ "H"
2470
+ ],
2471
+ LT: [
2472
+ "H",
2473
+ "h",
2474
+ "hb",
2475
+ "hB"
2476
+ ],
2477
+ LU: [
2478
+ "H",
2479
+ "h",
2480
+ "hB"
2481
+ ],
2482
+ LV: [
2483
+ "H",
2484
+ "hB",
2485
+ "hb",
2486
+ "h"
2487
+ ],
2488
+ LY: [
2489
+ "h",
2490
+ "hB",
2491
+ "hb",
2492
+ "H"
2493
+ ],
2494
+ MA: [
2495
+ "H",
2496
+ "h",
2497
+ "hB",
2498
+ "hb"
2499
+ ],
2500
+ MC: [
2501
+ "H",
2502
+ "hB"
2503
+ ],
2504
+ MD: [
2505
+ "H",
2506
+ "hB"
2507
+ ],
2508
+ ME: [
2509
+ "H",
2510
+ "hB",
2511
+ "h"
2512
+ ],
2513
+ MF: [
2514
+ "H",
2515
+ "hB"
2516
+ ],
2517
+ MG: [
2518
+ "H",
2519
+ "h"
2520
+ ],
2521
+ MH: [
2522
+ "h",
2523
+ "hb",
2524
+ "H",
2525
+ "hB"
2526
+ ],
2527
+ MK: [
2528
+ "H",
2529
+ "h",
2530
+ "hb",
2531
+ "hB"
2532
+ ],
2533
+ ML: [
2534
+ "H"
2535
+ ],
2536
+ MM: [
2537
+ "hB",
2538
+ "hb",
2539
+ "H",
2540
+ "h"
2541
+ ],
2542
+ MN: [
2543
+ "H",
2544
+ "h",
2545
+ "hb",
2546
+ "hB"
2547
+ ],
2548
+ MO: [
2549
+ "h",
2550
+ "hB",
2551
+ "hb",
2552
+ "H"
2553
+ ],
2554
+ MP: [
2555
+ "h",
2556
+ "hb",
2557
+ "H",
2558
+ "hB"
2559
+ ],
2560
+ MQ: [
2561
+ "H",
2562
+ "hB"
2563
+ ],
2564
+ MR: [
2565
+ "h",
2566
+ "hB",
2567
+ "hb",
2568
+ "H"
2569
+ ],
2570
+ MS: [
2571
+ "H",
2572
+ "h",
2573
+ "hb",
2574
+ "hB"
2575
+ ],
2576
+ MT: [
2577
+ "H",
2578
+ "h"
2579
+ ],
2580
+ MU: [
2581
+ "H",
2582
+ "h"
2583
+ ],
2584
+ MV: [
2585
+ "H",
2586
+ "h"
2587
+ ],
2588
+ MW: [
2589
+ "h",
2590
+ "hb",
2591
+ "H",
2592
+ "hB"
2593
+ ],
2594
+ MX: [
2595
+ "h",
2596
+ "H",
2597
+ "hB",
2598
+ "hb"
2599
+ ],
2600
+ MY: [
2601
+ "hb",
2602
+ "hB",
2603
+ "h",
2604
+ "H"
2605
+ ],
2606
+ MZ: [
2607
+ "H",
2608
+ "hB"
2609
+ ],
2610
+ NA: [
2611
+ "h",
2612
+ "H",
2613
+ "hB",
2614
+ "hb"
2615
+ ],
2616
+ NC: [
2617
+ "H",
2618
+ "hB"
2619
+ ],
2620
+ NE: [
2621
+ "H"
2622
+ ],
2623
+ NF: [
2624
+ "H",
2625
+ "h",
2626
+ "hb",
2627
+ "hB"
2628
+ ],
2629
+ NG: [
2630
+ "H",
2631
+ "h",
2632
+ "hb",
2633
+ "hB"
2634
+ ],
2635
+ NI: [
2636
+ "h",
2637
+ "H",
2638
+ "hB",
2639
+ "hb"
2640
+ ],
2641
+ NL: [
2642
+ "H",
2643
+ "hB"
2644
+ ],
2645
+ NO: [
2646
+ "H",
2647
+ "h"
2648
+ ],
2649
+ NP: [
2650
+ "H",
2651
+ "h",
2652
+ "hB"
2653
+ ],
2654
+ NR: [
2655
+ "H",
2656
+ "h",
2657
+ "hb",
2658
+ "hB"
2659
+ ],
2660
+ NU: [
2661
+ "H",
2662
+ "h",
2663
+ "hb",
2664
+ "hB"
2665
+ ],
2666
+ NZ: [
2667
+ "h",
2668
+ "hb",
2669
+ "H",
2670
+ "hB"
2671
+ ],
2672
+ OM: [
2673
+ "h",
2674
+ "hB",
2675
+ "hb",
2676
+ "H"
2677
+ ],
2678
+ PA: [
2679
+ "h",
2680
+ "H",
2681
+ "hB",
2682
+ "hb"
2683
+ ],
2684
+ PE: [
2685
+ "h",
2686
+ "H",
2687
+ "hB",
2688
+ "hb"
2689
+ ],
2690
+ PF: [
2691
+ "H",
2692
+ "h",
2693
+ "hB"
2694
+ ],
2695
+ PG: [
2696
+ "h",
2697
+ "H"
2698
+ ],
2699
+ PH: [
2700
+ "h",
2701
+ "hB",
2702
+ "hb",
2703
+ "H"
2704
+ ],
2705
+ PK: [
2706
+ "h",
2707
+ "hB",
2708
+ "H"
2709
+ ],
2710
+ PL: [
2711
+ "H",
2712
+ "h"
2713
+ ],
2714
+ PM: [
2715
+ "H",
2716
+ "hB"
2717
+ ],
2718
+ PN: [
2719
+ "H",
2720
+ "h",
2721
+ "hb",
2722
+ "hB"
2723
+ ],
2724
+ PR: [
2725
+ "h",
2726
+ "H",
2727
+ "hB",
2728
+ "hb"
2729
+ ],
2730
+ PS: [
2731
+ "h",
2732
+ "hB",
2733
+ "hb",
2734
+ "H"
2735
+ ],
2736
+ PT: [
2737
+ "H",
2738
+ "hB"
2739
+ ],
2740
+ PW: [
2741
+ "h",
2742
+ "H"
2743
+ ],
2744
+ PY: [
2745
+ "h",
2746
+ "H",
2747
+ "hB",
2748
+ "hb"
2749
+ ],
2750
+ QA: [
2751
+ "h",
2752
+ "hB",
2753
+ "hb",
2754
+ "H"
2755
+ ],
2756
+ RE: [
2757
+ "H",
2758
+ "hB"
2759
+ ],
2760
+ RO: [
2761
+ "H",
2762
+ "hB"
2763
+ ],
2764
+ RS: [
2765
+ "H",
2766
+ "hB",
2767
+ "h"
2768
+ ],
2769
+ RU: [
2770
+ "H"
2771
+ ],
2772
+ RW: [
2773
+ "H",
2774
+ "h"
2775
+ ],
2776
+ SA: [
2777
+ "h",
2778
+ "hB",
2779
+ "hb",
2780
+ "H"
2781
+ ],
2782
+ SB: [
2783
+ "h",
2784
+ "hb",
2785
+ "H",
2786
+ "hB"
2787
+ ],
2788
+ SC: [
2789
+ "H",
2790
+ "h",
2791
+ "hB"
2792
+ ],
2793
+ SD: [
2794
+ "h",
2795
+ "hB",
2796
+ "hb",
2797
+ "H"
2798
+ ],
2799
+ SE: [
2800
+ "H"
2801
+ ],
2802
+ SG: [
2803
+ "h",
2804
+ "hb",
2805
+ "H",
2806
+ "hB"
2807
+ ],
2808
+ SH: [
2809
+ "H",
2810
+ "h",
2811
+ "hb",
2812
+ "hB"
2813
+ ],
2814
+ SI: [
2815
+ "H",
2816
+ "hB"
2817
+ ],
2818
+ SJ: [
2819
+ "H"
2820
+ ],
2821
+ SK: [
2822
+ "H"
2823
+ ],
2824
+ SL: [
2825
+ "h",
2826
+ "hb",
2827
+ "H",
2828
+ "hB"
2829
+ ],
2830
+ SM: [
2831
+ "H",
2832
+ "h",
2833
+ "hB"
2834
+ ],
2835
+ SN: [
2836
+ "H",
2837
+ "h",
2838
+ "hB"
2839
+ ],
2840
+ SO: [
2841
+ "h",
2842
+ "H"
2843
+ ],
2844
+ SR: [
2845
+ "H",
2846
+ "hB"
2847
+ ],
2848
+ SS: [
2849
+ "h",
2850
+ "hb",
2851
+ "H",
2852
+ "hB"
2853
+ ],
2854
+ ST: [
2855
+ "H",
2856
+ "hB"
2857
+ ],
2858
+ SV: [
2859
+ "h",
2860
+ "H",
2861
+ "hB",
2862
+ "hb"
2863
+ ],
2864
+ SX: [
2865
+ "H",
2866
+ "h",
2867
+ "hb",
2868
+ "hB"
2869
+ ],
2870
+ SY: [
2871
+ "h",
2872
+ "hB",
2873
+ "hb",
2874
+ "H"
2875
+ ],
2876
+ SZ: [
2877
+ "h",
2878
+ "hb",
2879
+ "H",
2880
+ "hB"
2881
+ ],
2882
+ TA: [
2883
+ "H",
2884
+ "h",
2885
+ "hb",
2886
+ "hB"
2887
+ ],
2888
+ TC: [
2889
+ "h",
2890
+ "hb",
2891
+ "H",
2892
+ "hB"
2893
+ ],
2894
+ TD: [
2895
+ "h",
2896
+ "H",
2897
+ "hB"
2898
+ ],
2899
+ TF: [
2900
+ "H",
2901
+ "h",
2902
+ "hB"
2903
+ ],
2904
+ TG: [
2905
+ "H",
2906
+ "hB"
2907
+ ],
2908
+ TH: [
2909
+ "H",
2910
+ "h"
2911
+ ],
2912
+ TJ: [
2913
+ "H",
2914
+ "h"
2915
+ ],
2916
+ TL: [
2917
+ "H",
2918
+ "hB",
2919
+ "hb",
2920
+ "h"
2921
+ ],
2922
+ TM: [
2923
+ "H",
2924
+ "h"
2925
+ ],
2926
+ TN: [
2927
+ "h",
2928
+ "hB",
2929
+ "hb",
2930
+ "H"
2931
+ ],
2932
+ TO: [
2933
+ "h",
2934
+ "H"
2935
+ ],
2936
+ TR: [
2937
+ "H",
2938
+ "hB"
2939
+ ],
2940
+ TT: [
2941
+ "h",
2942
+ "hb",
2943
+ "H",
2944
+ "hB"
2945
+ ],
2946
+ TW: [
2947
+ "hB",
2948
+ "hb",
2949
+ "h",
2950
+ "H"
2951
+ ],
2952
+ TZ: [
2953
+ "hB",
2954
+ "hb",
2955
+ "H",
2956
+ "h"
2957
+ ],
2958
+ UA: [
2959
+ "H",
2960
+ "hB",
2961
+ "h"
2962
+ ],
2963
+ UG: [
2964
+ "hB",
2965
+ "hb",
2966
+ "H",
2967
+ "h"
2968
+ ],
2969
+ UM: [
2970
+ "h",
2971
+ "hb",
2972
+ "H",
2973
+ "hB"
2974
+ ],
2975
+ US: [
2976
+ "h",
2977
+ "hb",
2978
+ "H",
2979
+ "hB"
2980
+ ],
2981
+ UY: [
2982
+ "h",
2983
+ "H",
2984
+ "hB",
2985
+ "hb"
2986
+ ],
2987
+ UZ: [
2988
+ "H",
2989
+ "hB",
2990
+ "h"
2991
+ ],
2992
+ VA: [
2993
+ "H",
2994
+ "h",
2995
+ "hB"
2996
+ ],
2997
+ VC: [
2998
+ "h",
2999
+ "hb",
3000
+ "H",
3001
+ "hB"
3002
+ ],
3003
+ VE: [
3004
+ "h",
3005
+ "H",
3006
+ "hB",
3007
+ "hb"
3008
+ ],
3009
+ VG: [
3010
+ "h",
3011
+ "hb",
3012
+ "H",
3013
+ "hB"
3014
+ ],
3015
+ VI: [
3016
+ "h",
3017
+ "hb",
3018
+ "H",
3019
+ "hB"
3020
+ ],
3021
+ VN: [
3022
+ "H",
3023
+ "h"
3024
+ ],
3025
+ VU: [
3026
+ "h",
3027
+ "H"
3028
+ ],
3029
+ WF: [
3030
+ "H",
3031
+ "hB"
3032
+ ],
3033
+ WS: [
3034
+ "h",
3035
+ "H"
3036
+ ],
3037
+ XK: [
3038
+ "H",
3039
+ "hB",
3040
+ "h"
3041
+ ],
3042
+ YE: [
3043
+ "h",
3044
+ "hB",
3045
+ "hb",
3046
+ "H"
3047
+ ],
3048
+ YT: [
3049
+ "H",
3050
+ "hB"
3051
+ ],
3052
+ ZA: [
3053
+ "H",
3054
+ "h",
3055
+ "hb",
3056
+ "hB"
3057
+ ],
3058
+ ZM: [
3059
+ "h",
3060
+ "hb",
3061
+ "H",
3062
+ "hB"
3063
+ ],
3064
+ ZW: [
3065
+ "H",
3066
+ "h"
3067
+ ],
3068
+ "af-ZA": [
3069
+ "H",
3070
+ "h",
3071
+ "hB",
3072
+ "hb"
3073
+ ],
3074
+ "ar-001": [
3075
+ "h",
3076
+ "hB",
3077
+ "hb",
3078
+ "H"
3079
+ ],
3080
+ "ca-ES": [
3081
+ "H",
3082
+ "h",
3083
+ "hB"
3084
+ ],
3085
+ "en-001": [
3086
+ "h",
3087
+ "hb",
3088
+ "H",
3089
+ "hB"
3090
+ ],
3091
+ "en-HK": [
3092
+ "h",
3093
+ "hb",
3094
+ "H",
3095
+ "hB"
3096
+ ],
3097
+ "en-IL": [
3098
+ "H",
3099
+ "h",
3100
+ "hb",
3101
+ "hB"
3102
+ ],
3103
+ "en-MY": [
3104
+ "h",
3105
+ "hb",
3106
+ "H",
3107
+ "hB"
3108
+ ],
3109
+ "es-BR": [
3110
+ "H",
3111
+ "h",
3112
+ "hB",
3113
+ "hb"
3114
+ ],
3115
+ "es-ES": [
3116
+ "H",
3117
+ "h",
3118
+ "hB",
3119
+ "hb"
3120
+ ],
3121
+ "es-GQ": [
3122
+ "H",
3123
+ "h",
3124
+ "hB",
3125
+ "hb"
3126
+ ],
3127
+ "fr-CA": [
3128
+ "H",
3129
+ "h",
3130
+ "hB"
3131
+ ],
3132
+ "gl-ES": [
3133
+ "H",
3134
+ "h",
3135
+ "hB"
3136
+ ],
3137
+ "gu-IN": [
3138
+ "hB",
3139
+ "hb",
3140
+ "h",
3141
+ "H"
3142
+ ],
3143
+ "hi-IN": [
3144
+ "hB",
3145
+ "h",
3146
+ "H"
3147
+ ],
3148
+ "it-CH": [
3149
+ "H",
3150
+ "h",
3151
+ "hB"
3152
+ ],
3153
+ "it-IT": [
3154
+ "H",
3155
+ "h",
3156
+ "hB"
3157
+ ],
3158
+ "kn-IN": [
3159
+ "hB",
3160
+ "h",
3161
+ "H"
3162
+ ],
3163
+ "ml-IN": [
3164
+ "hB",
3165
+ "h",
3166
+ "H"
3167
+ ],
3168
+ "mr-IN": [
3169
+ "hB",
3170
+ "hb",
3171
+ "h",
3172
+ "H"
3173
+ ],
3174
+ "pa-IN": [
3175
+ "hB",
3176
+ "hb",
3177
+ "h",
3178
+ "H"
3179
+ ],
3180
+ "ta-IN": [
3181
+ "hB",
3182
+ "h",
3183
+ "hb",
3184
+ "H"
3185
+ ],
3186
+ "te-IN": [
3187
+ "hB",
3188
+ "h",
3189
+ "H"
3190
+ ],
3191
+ "zu-ZA": [
3192
+ "H",
3193
+ "hB",
3194
+ "hb",
3195
+ "h"
3196
+ ]
3197
+ };
3198
+ function yi(e, t) {
3199
+ for (var r = "", n = 0; n < e.length; n++) {
3200
+ var i = e.charAt(n);
3201
+ if (i === "j") {
3202
+ for (var o = 0; n + 1 < e.length && e.charAt(n + 1) === i; )
3203
+ o++, n++;
3204
+ var s = 1 + (o & 1), a = o < 2 ? 1 : 3 + (o >> 1), l = "a", u = xi(t);
3205
+ for ((u == "H" || u == "k") && (a = 0); a-- > 0; )
3206
+ r += l;
3207
+ for (; s-- > 0; )
3208
+ r = u + r;
3209
+ } else
3210
+ i === "J" ? r += "H" : r += i;
3211
+ }
3212
+ return r;
3213
+ }
3214
+ function xi(e) {
3215
+ var t = e.hourCycle;
3216
+ if (t === void 0 && // @ts-ignore hourCycle(s) is not identified yet
3217
+ e.hourCycles && // @ts-ignore
3218
+ e.hourCycles.length && (t = e.hourCycles[0]), t)
3219
+ switch (t) {
3220
+ case "h24":
3221
+ return "k";
3222
+ case "h23":
3223
+ return "H";
3224
+ case "h12":
3225
+ return "h";
3226
+ case "h11":
3227
+ return "K";
3228
+ default:
3229
+ throw new Error("Invalid hourCycle");
3230
+ }
3231
+ var r = e.language, n;
3232
+ r !== "root" && (n = e.maximize().region);
3233
+ var i = ye[n || ""] || ye[r || ""] || ye["".concat(r, "-001")] || ye["001"];
3234
+ return i[0];
3235
+ }
3236
+ var Ve, _i = new RegExp("^".concat(vr.source, "*")), Ei = new RegExp("".concat(vr.source, "*$"));
3237
+ function v(e, t) {
3238
+ return { start: e, end: t };
3239
+ }
3240
+ var wi = !!String.prototype.startsWith && "_a".startsWith("a", 1), Si = !!String.fromCodePoint, Ti = !!Object.fromEntries, Ai = !!String.prototype.codePointAt, Ci = !!String.prototype.trimStart, Hi = !!String.prototype.trimEnd, Bi = !!Number.isSafeInteger, Ii = Bi ? Number.isSafeInteger : function(e) {
3241
+ return typeof e == "number" && isFinite(e) && Math.floor(e) === e && Math.abs(e) <= 9007199254740991;
3242
+ }, it = !0;
3243
+ try {
3244
+ var Oi = wr("([^\\p{White_Space}\\p{Pattern_Syntax}]*)", "yu");
3245
+ it = ((Ve = Oi.exec("a")) === null || Ve === void 0 ? void 0 : Ve[0]) === "a";
3246
+ } catch (e) {
3247
+ it = !1;
3248
+ }
3249
+ var Mt = wi ? (
3250
+ // Native
3251
+ function(t, r, n) {
3252
+ return t.startsWith(r, n);
3253
+ }
3254
+ ) : (
3255
+ // For IE11
3256
+ function(t, r, n) {
3257
+ return t.slice(n, n + r.length) === r;
3258
+ }
3259
+ ), ot = Si ? String.fromCodePoint : (
3260
+ // IE11
3261
+ function() {
3262
+ for (var t = [], r = 0; r < arguments.length; r++)
3263
+ t[r] = arguments[r];
3264
+ for (var n = "", i = t.length, o = 0, s; i > o; ) {
3265
+ if (s = t[o++], s > 1114111)
3266
+ throw RangeError(s + " is not a valid code point");
3267
+ n += s < 65536 ? String.fromCharCode(s) : String.fromCharCode(((s -= 65536) >> 10) + 55296, s % 1024 + 56320);
3268
+ }
3269
+ return n;
3270
+ }
3271
+ ), Nt = (
3272
+ // native
3273
+ Ti ? Object.fromEntries : (
3274
+ // Ponyfill
3275
+ function(t) {
3276
+ for (var r = {}, n = 0, i = t; n < i.length; n++) {
3277
+ var o = i[n], s = o[0], a = o[1];
3278
+ r[s] = a;
3279
+ }
3280
+ return r;
3281
+ }
3282
+ )
3283
+ ), Er = Ai ? (
3284
+ // Native
3285
+ function(t, r) {
3286
+ return t.codePointAt(r);
3287
+ }
3288
+ ) : (
3289
+ // IE 11
3290
+ function(t, r) {
3291
+ var n = t.length;
3292
+ if (!(r < 0 || r >= n)) {
3293
+ var i = t.charCodeAt(r), o;
3294
+ return i < 55296 || i > 56319 || r + 1 === n || (o = t.charCodeAt(r + 1)) < 56320 || o > 57343 ? i : (i - 55296 << 10) + (o - 56320) + 65536;
3295
+ }
3296
+ }
3297
+ ), Pi = Ci ? (
3298
+ // Native
3299
+ function(t) {
3300
+ return t.trimStart();
3301
+ }
3302
+ ) : (
3303
+ // Ponyfill
3304
+ function(t) {
3305
+ return t.replace(_i, "");
3306
+ }
3307
+ ), Li = Hi ? (
3308
+ // Native
3309
+ function(t) {
3310
+ return t.trimEnd();
3311
+ }
3312
+ ) : (
3313
+ // Ponyfill
3314
+ function(t) {
3315
+ return t.replace(Ei, "");
3316
+ }
3317
+ );
3318
+ function wr(e, t) {
3319
+ return new RegExp(e, t);
3320
+ }
3321
+ var st;
3322
+ if (it) {
3323
+ var jt = wr("([^\\p{White_Space}\\p{Pattern_Syntax}]*)", "yu");
3324
+ st = function(t, r) {
3325
+ var n;
3326
+ jt.lastIndex = r;
3327
+ var i = jt.exec(t);
3328
+ return (n = i[1]) !== null && n !== void 0 ? n : "";
3329
+ };
3330
+ } else
3331
+ st = function(t, r) {
3332
+ for (var n = []; ; ) {
3333
+ var i = Er(t, r);
3334
+ if (i === void 0 || Sr(i) || Ri(i))
3335
+ break;
3336
+ n.push(i), r += i >= 65536 ? 2 : 1;
3337
+ }
3338
+ return ot.apply(void 0, n);
3339
+ };
3340
+ var Mi = (
3341
+ /** @class */
3342
+ function() {
3343
+ function e(t, r) {
3344
+ r === void 0 && (r = {}), this.message = t, this.position = { offset: 0, line: 1, column: 1 }, this.ignoreTag = !!r.ignoreTag, this.locale = r.locale, this.requiresOtherClause = !!r.requiresOtherClause, this.shouldParseSkeletons = !!r.shouldParseSkeletons;
3345
+ }
3346
+ return e.prototype.parse = function() {
3347
+ if (this.offset() !== 0)
3348
+ throw Error("parser can only be used once");
3349
+ return this.parseMessage(0, "", !1);
3350
+ }, e.prototype.parseMessage = function(t, r, n) {
3351
+ for (var i = []; !this.isEOF(); ) {
3352
+ var o = this.char();
3353
+ if (o === 123) {
3354
+ var s = this.parseArgument(t, n);
3355
+ if (s.err)
3356
+ return s;
3357
+ i.push(s.val);
3358
+ } else {
3359
+ if (o === 125 && t > 0)
3360
+ break;
3361
+ if (o === 35 && (r === "plural" || r === "selectordinal")) {
3362
+ var a = this.clonePosition();
3363
+ this.bump(), i.push({
3364
+ type: _.pound,
3365
+ location: v(a, this.clonePosition())
3366
+ });
3367
+ } else if (o === 60 && !this.ignoreTag && this.peek() === 47) {
3368
+ if (n)
3369
+ break;
3370
+ return this.error(g.UNMATCHED_CLOSING_TAG, v(this.clonePosition(), this.clonePosition()));
3371
+ } else if (o === 60 && !this.ignoreTag && at(this.peek() || 0)) {
3372
+ var s = this.parseTag(t, r);
3373
+ if (s.err)
3374
+ return s;
3375
+ i.push(s.val);
3376
+ } else {
3377
+ var s = this.parseLiteral(t, r);
3378
+ if (s.err)
3379
+ return s;
3380
+ i.push(s.val);
3381
+ }
3382
+ }
3383
+ }
3384
+ return { val: i, err: null };
3385
+ }, e.prototype.parseTag = function(t, r) {
3386
+ var n = this.clonePosition();
3387
+ this.bump();
3388
+ var i = this.parseTagName();
3389
+ if (this.bumpSpace(), this.bumpIf("/>"))
3390
+ return {
3391
+ val: {
3392
+ type: _.literal,
3393
+ value: "<".concat(i, "/>"),
3394
+ location: v(n, this.clonePosition())
3395
+ },
3396
+ err: null
3397
+ };
3398
+ if (this.bumpIf(">")) {
3399
+ var o = this.parseMessage(t + 1, r, !0);
3400
+ if (o.err)
3401
+ return o;
3402
+ var s = o.val, a = this.clonePosition();
3403
+ if (this.bumpIf("</")) {
3404
+ if (this.isEOF() || !at(this.char()))
3405
+ return this.error(g.INVALID_TAG, v(a, this.clonePosition()));
3406
+ var l = this.clonePosition(), u = this.parseTagName();
3407
+ return i !== u ? this.error(g.UNMATCHED_CLOSING_TAG, v(l, this.clonePosition())) : (this.bumpSpace(), this.bumpIf(">") ? {
3408
+ val: {
3409
+ type: _.tag,
3410
+ value: i,
3411
+ children: s,
3412
+ location: v(n, this.clonePosition())
3413
+ },
3414
+ err: null
3415
+ } : this.error(g.INVALID_TAG, v(a, this.clonePosition())));
3416
+ } else
3417
+ return this.error(g.UNCLOSED_TAG, v(n, this.clonePosition()));
3418
+ } else
3419
+ return this.error(g.INVALID_TAG, v(n, this.clonePosition()));
3420
+ }, e.prototype.parseTagName = function() {
3421
+ var t = this.offset();
3422
+ for (this.bump(); !this.isEOF() && ji(this.char()); )
3423
+ this.bump();
3424
+ return this.message.slice(t, this.offset());
3425
+ }, e.prototype.parseLiteral = function(t, r) {
3426
+ for (var n = this.clonePosition(), i = ""; ; ) {
3427
+ var o = this.tryParseQuote(r);
3428
+ if (o) {
3429
+ i += o;
3430
+ continue;
3431
+ }
3432
+ var s = this.tryParseUnquoted(t, r);
3433
+ if (s) {
3434
+ i += s;
3435
+ continue;
3436
+ }
3437
+ var a = this.tryParseLeftAngleBracket();
3438
+ if (a) {
3439
+ i += a;
3440
+ continue;
3441
+ }
3442
+ break;
3443
+ }
3444
+ var l = v(n, this.clonePosition());
3445
+ return {
3446
+ val: { type: _.literal, value: i, location: l },
3447
+ err: null
3448
+ };
3449
+ }, e.prototype.tryParseLeftAngleBracket = function() {
3450
+ return !this.isEOF() && this.char() === 60 && (this.ignoreTag || // If at the opening tag or closing tag position, bail.
3451
+ !Ni(this.peek() || 0)) ? (this.bump(), "<") : null;
3452
+ }, e.prototype.tryParseQuote = function(t) {
3453
+ if (this.isEOF() || this.char() !== 39)
3454
+ return null;
3455
+ switch (this.peek()) {
3456
+ case 39:
3457
+ return this.bump(), this.bump(), "'";
3458
+ case 123:
3459
+ case 60:
3460
+ case 62:
3461
+ case 125:
3462
+ break;
3463
+ case 35:
3464
+ if (t === "plural" || t === "selectordinal")
3465
+ break;
3466
+ return null;
3467
+ default:
3468
+ return null;
3469
+ }
3470
+ this.bump();
3471
+ var r = [this.char()];
3472
+ for (this.bump(); !this.isEOF(); ) {
3473
+ var n = this.char();
3474
+ if (n === 39)
3475
+ if (this.peek() === 39)
3476
+ r.push(39), this.bump();
3477
+ else {
3478
+ this.bump();
3479
+ break;
3480
+ }
3481
+ else
3482
+ r.push(n);
3483
+ this.bump();
3484
+ }
3485
+ return ot.apply(void 0, r);
3486
+ }, e.prototype.tryParseUnquoted = function(t, r) {
3487
+ if (this.isEOF())
3488
+ return null;
3489
+ var n = this.char();
3490
+ return n === 60 || n === 123 || n === 35 && (r === "plural" || r === "selectordinal") || n === 125 && t > 0 ? null : (this.bump(), ot(n));
3491
+ }, e.prototype.parseArgument = function(t, r) {
3492
+ var n = this.clonePosition();
3493
+ if (this.bump(), this.bumpSpace(), this.isEOF())
3494
+ return this.error(g.EXPECT_ARGUMENT_CLOSING_BRACE, v(n, this.clonePosition()));
3495
+ if (this.char() === 125)
3496
+ return this.bump(), this.error(g.EMPTY_ARGUMENT, v(n, this.clonePosition()));
3497
+ var i = this.parseIdentifierIfPossible().value;
3498
+ if (!i)
3499
+ return this.error(g.MALFORMED_ARGUMENT, v(n, this.clonePosition()));
3500
+ if (this.bumpSpace(), this.isEOF())
3501
+ return this.error(g.EXPECT_ARGUMENT_CLOSING_BRACE, v(n, this.clonePosition()));
3502
+ switch (this.char()) {
3503
+ case 125:
3504
+ return this.bump(), {
3505
+ val: {
3506
+ type: _.argument,
3507
+ // value does not include the opening and closing braces.
3508
+ value: i,
3509
+ location: v(n, this.clonePosition())
3510
+ },
3511
+ err: null
3512
+ };
3513
+ case 44:
3514
+ return this.bump(), this.bumpSpace(), this.isEOF() ? this.error(g.EXPECT_ARGUMENT_CLOSING_BRACE, v(n, this.clonePosition())) : this.parseArgumentOptions(t, r, i, n);
3515
+ default:
3516
+ return this.error(g.MALFORMED_ARGUMENT, v(n, this.clonePosition()));
3517
+ }
3518
+ }, e.prototype.parseIdentifierIfPossible = function() {
3519
+ var t = this.clonePosition(), r = this.offset(), n = st(this.message, r), i = r + n.length;
3520
+ this.bumpTo(i);
3521
+ var o = this.clonePosition(), s = v(t, o);
3522
+ return { value: n, location: s };
3523
+ }, e.prototype.parseArgumentOptions = function(t, r, n, i) {
3524
+ var o, s = this.clonePosition(), a = this.parseIdentifierIfPossible().value, l = this.clonePosition();
3525
+ switch (a) {
3526
+ case "":
3527
+ return this.error(g.EXPECT_ARGUMENT_TYPE, v(s, l));
3528
+ case "number":
3529
+ case "date":
3530
+ case "time": {
3531
+ this.bumpSpace();
3532
+ var u = null;
3533
+ if (this.bumpIf(",")) {
3534
+ this.bumpSpace();
3535
+ var h = this.clonePosition(), c = this.parseSimpleArgStyleIfPossible();
3536
+ if (c.err)
3537
+ return c;
3538
+ var f = Li(c.val);
3539
+ if (f.length === 0)
3540
+ return this.error(g.EXPECT_ARGUMENT_STYLE, v(this.clonePosition(), this.clonePosition()));
3541
+ var p = v(h, this.clonePosition());
3542
+ u = { style: f, styleLocation: p };
3543
+ }
3544
+ var b = this.tryParseArgumentClose(i);
3545
+ if (b.err)
3546
+ return b;
3547
+ var d = v(i, this.clonePosition());
3548
+ if (u && Mt(u == null ? void 0 : u.style, "::", 0)) {
3549
+ var y = Pi(u.style.slice(2));
3550
+ if (a === "number") {
3551
+ var c = this.parseNumberSkeletonFromString(y, u.styleLocation);
3552
+ return c.err ? c : {
3553
+ val: { type: _.number, value: n, location: d, style: c.val },
3554
+ err: null
3555
+ };
3556
+ } else {
3557
+ if (y.length === 0)
3558
+ return this.error(g.EXPECT_DATE_TIME_SKELETON, d);
3559
+ var C = y;
3560
+ this.locale && (C = yi(y, this.locale));
3561
+ var f = {
3562
+ type: K.dateTime,
3563
+ pattern: C,
3564
+ location: u.styleLocation,
3565
+ parsedOptions: this.shouldParseSkeletons ? fi(C) : {}
3566
+ }, O = a === "date" ? _.date : _.time;
3567
+ return {
3568
+ val: { type: O, value: n, location: d, style: f },
3569
+ err: null
3570
+ };
3571
+ }
3572
+ }
3573
+ return {
3574
+ val: {
3575
+ type: a === "number" ? _.number : a === "date" ? _.date : _.time,
3576
+ value: n,
3577
+ location: d,
3578
+ style: (o = u == null ? void 0 : u.style) !== null && o !== void 0 ? o : null
3579
+ },
3580
+ err: null
3581
+ };
3582
+ }
3583
+ case "plural":
3584
+ case "selectordinal":
3585
+ case "select": {
3586
+ var T = this.clonePosition();
3587
+ if (this.bumpSpace(), !this.bumpIf(","))
3588
+ return this.error(g.EXPECT_SELECT_ARGUMENT_OPTIONS, v(T, Ce({}, T)));
3589
+ this.bumpSpace();
3590
+ var B = this.parseIdentifierIfPossible(), x = 0;
3591
+ if (a !== "select" && B.value === "offset") {
3592
+ if (!this.bumpIf(":"))
3593
+ return this.error(g.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE, v(this.clonePosition(), this.clonePosition()));
3594
+ this.bumpSpace();
3595
+ var c = this.tryParseDecimalInteger(g.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE, g.INVALID_PLURAL_ARGUMENT_OFFSET_VALUE);
3596
+ if (c.err)
3597
+ return c;
3598
+ this.bumpSpace(), B = this.parseIdentifierIfPossible(), x = c.val;
3599
+ }
3600
+ var D = this.tryParsePluralOrSelectOptions(t, a, r, B);
3601
+ if (D.err)
3602
+ return D;
3603
+ var b = this.tryParseArgumentClose(i);
3604
+ if (b.err)
3605
+ return b;
3606
+ var m = v(i, this.clonePosition());
3607
+ return a === "select" ? {
3608
+ val: {
3609
+ type: _.select,
3610
+ value: n,
3611
+ options: Nt(D.val),
3612
+ location: m
3613
+ },
3614
+ err: null
3615
+ } : {
3616
+ val: {
3617
+ type: _.plural,
3618
+ value: n,
3619
+ options: Nt(D.val),
3620
+ offset: x,
3621
+ pluralType: a === "plural" ? "cardinal" : "ordinal",
3622
+ location: m
3623
+ },
3624
+ err: null
3625
+ };
3626
+ }
3627
+ default:
3628
+ return this.error(g.INVALID_ARGUMENT_TYPE, v(s, l));
3629
+ }
3630
+ }, e.prototype.tryParseArgumentClose = function(t) {
3631
+ return this.isEOF() || this.char() !== 125 ? this.error(g.EXPECT_ARGUMENT_CLOSING_BRACE, v(t, this.clonePosition())) : (this.bump(), { val: !0, err: null });
3632
+ }, e.prototype.parseSimpleArgStyleIfPossible = function() {
3633
+ for (var t = 0, r = this.clonePosition(); !this.isEOF(); ) {
3634
+ var n = this.char();
3635
+ switch (n) {
3636
+ case 39: {
3637
+ this.bump();
3638
+ var i = this.clonePosition();
3639
+ if (!this.bumpUntil("'"))
3640
+ return this.error(g.UNCLOSED_QUOTE_IN_ARGUMENT_STYLE, v(i, this.clonePosition()));
3641
+ this.bump();
3642
+ break;
3643
+ }
3644
+ case 123: {
3645
+ t += 1, this.bump();
3646
+ break;
3647
+ }
3648
+ case 125: {
3649
+ if (t > 0)
3650
+ t -= 1;
3651
+ else
3652
+ return {
3653
+ val: this.message.slice(r.offset, this.offset()),
3654
+ err: null
3655
+ };
3656
+ break;
3657
+ }
3658
+ default:
3659
+ this.bump();
3660
+ break;
3661
+ }
3662
+ }
3663
+ return {
3664
+ val: this.message.slice(r.offset, this.offset()),
3665
+ err: null
3666
+ };
3667
+ }, e.prototype.parseNumberSkeletonFromString = function(t, r) {
3668
+ var n = [];
3669
+ try {
3670
+ n = di(t);
3671
+ } catch (i) {
3672
+ return this.error(g.INVALID_NUMBER_SKELETON, r);
3673
+ }
3674
+ return {
3675
+ val: {
3676
+ type: K.number,
3677
+ tokens: n,
3678
+ location: r,
3679
+ parsedOptions: this.shouldParseSkeletons ? vi(n) : {}
3680
+ },
3681
+ err: null
3682
+ };
3683
+ }, e.prototype.tryParsePluralOrSelectOptions = function(t, r, n, i) {
3684
+ for (var o, s = !1, a = [], l = /* @__PURE__ */ new Set(), u = i.value, h = i.location; ; ) {
3685
+ if (u.length === 0) {
3686
+ var c = this.clonePosition();
3687
+ if (r !== "select" && this.bumpIf("=")) {
3688
+ var f = this.tryParseDecimalInteger(g.EXPECT_PLURAL_ARGUMENT_SELECTOR, g.INVALID_PLURAL_ARGUMENT_SELECTOR);
3689
+ if (f.err)
3690
+ return f;
3691
+ h = v(c, this.clonePosition()), u = this.message.slice(c.offset, this.offset());
3692
+ } else
3693
+ break;
3694
+ }
3695
+ if (l.has(u))
3696
+ return this.error(r === "select" ? g.DUPLICATE_SELECT_ARGUMENT_SELECTOR : g.DUPLICATE_PLURAL_ARGUMENT_SELECTOR, h);
3697
+ u === "other" && (s = !0), this.bumpSpace();
3698
+ var p = this.clonePosition();
3699
+ if (!this.bumpIf("{"))
3700
+ return this.error(r === "select" ? g.EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT : g.EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT, v(this.clonePosition(), this.clonePosition()));
3701
+ var b = this.parseMessage(t + 1, r, n);
3702
+ if (b.err)
3703
+ return b;
3704
+ var d = this.tryParseArgumentClose(p);
3705
+ if (d.err)
3706
+ return d;
3707
+ a.push([
3708
+ u,
3709
+ {
3710
+ value: b.val,
3711
+ location: v(p, this.clonePosition())
3712
+ }
3713
+ ]), l.add(u), this.bumpSpace(), o = this.parseIdentifierIfPossible(), u = o.value, h = o.location;
3714
+ }
3715
+ return a.length === 0 ? this.error(r === "select" ? g.EXPECT_SELECT_ARGUMENT_SELECTOR : g.EXPECT_PLURAL_ARGUMENT_SELECTOR, v(this.clonePosition(), this.clonePosition())) : this.requiresOtherClause && !s ? this.error(g.MISSING_OTHER_CLAUSE, v(this.clonePosition(), this.clonePosition())) : { val: a, err: null };
3716
+ }, e.prototype.tryParseDecimalInteger = function(t, r) {
3717
+ var n = 1, i = this.clonePosition();
3718
+ this.bumpIf("+") || this.bumpIf("-") && (n = -1);
3719
+ for (var o = !1, s = 0; !this.isEOF(); ) {
3720
+ var a = this.char();
3721
+ if (a >= 48 && a <= 57)
3722
+ o = !0, s = s * 10 + (a - 48), this.bump();
3723
+ else
3724
+ break;
3725
+ }
3726
+ var l = v(i, this.clonePosition());
3727
+ return o ? (s *= n, Ii(s) ? { val: s, err: null } : this.error(r, l)) : this.error(t, l);
3728
+ }, e.prototype.offset = function() {
3729
+ return this.position.offset;
3730
+ }, e.prototype.isEOF = function() {
3731
+ return this.offset() === this.message.length;
3732
+ }, e.prototype.clonePosition = function() {
3733
+ return {
3734
+ offset: this.position.offset,
3735
+ line: this.position.line,
3736
+ column: this.position.column
3737
+ };
3738
+ }, e.prototype.char = function() {
3739
+ var t = this.position.offset;
3740
+ if (t >= this.message.length)
3741
+ throw Error("out of bound");
3742
+ var r = Er(this.message, t);
3743
+ if (r === void 0)
3744
+ throw Error("Offset ".concat(t, " is at invalid UTF-16 code unit boundary"));
3745
+ return r;
3746
+ }, e.prototype.error = function(t, r) {
3747
+ return {
3748
+ val: null,
3749
+ err: {
3750
+ kind: t,
3751
+ message: this.message,
3752
+ location: r
3753
+ }
3754
+ };
3755
+ }, e.prototype.bump = function() {
3756
+ if (!this.isEOF()) {
3757
+ var t = this.char();
3758
+ t === 10 ? (this.position.line += 1, this.position.column = 1, this.position.offset += 1) : (this.position.column += 1, this.position.offset += t < 65536 ? 1 : 2);
3759
+ }
3760
+ }, e.prototype.bumpIf = function(t) {
3761
+ if (Mt(this.message, t, this.offset())) {
3762
+ for (var r = 0; r < t.length; r++)
3763
+ this.bump();
3764
+ return !0;
3765
+ }
3766
+ return !1;
3767
+ }, e.prototype.bumpUntil = function(t) {
3768
+ var r = this.offset(), n = this.message.indexOf(t, r);
3769
+ return n >= 0 ? (this.bumpTo(n), !0) : (this.bumpTo(this.message.length), !1);
3770
+ }, e.prototype.bumpTo = function(t) {
3771
+ if (this.offset() > t)
3772
+ throw Error("targetOffset ".concat(t, " must be greater than or equal to the current offset ").concat(this.offset()));
3773
+ for (t = Math.min(t, this.message.length); ; ) {
3774
+ var r = this.offset();
3775
+ if (r === t)
3776
+ break;
3777
+ if (r > t)
3778
+ throw Error("targetOffset ".concat(t, " is at invalid UTF-16 code unit boundary"));
3779
+ if (this.bump(), this.isEOF())
3780
+ break;
3781
+ }
3782
+ }, e.prototype.bumpSpace = function() {
3783
+ for (; !this.isEOF() && Sr(this.char()); )
3784
+ this.bump();
3785
+ }, e.prototype.peek = function() {
3786
+ if (this.isEOF())
3787
+ return null;
3788
+ var t = this.char(), r = this.offset(), n = this.message.charCodeAt(r + (t >= 65536 ? 2 : 1));
3789
+ return n != null ? n : null;
3790
+ }, e;
3791
+ }()
3792
+ );
3793
+ function at(e) {
3794
+ return e >= 97 && e <= 122 || e >= 65 && e <= 90;
3795
+ }
3796
+ function Ni(e) {
3797
+ return at(e) || e === 47;
3798
+ }
3799
+ function ji(e) {
3800
+ return e === 45 || e === 46 || e >= 48 && e <= 57 || e === 95 || e >= 97 && e <= 122 || e >= 65 && e <= 90 || e == 183 || e >= 192 && e <= 214 || e >= 216 && e <= 246 || e >= 248 && e <= 893 || e >= 895 && e <= 8191 || e >= 8204 && e <= 8205 || e >= 8255 && e <= 8256 || e >= 8304 && e <= 8591 || e >= 11264 && e <= 12271 || e >= 12289 && e <= 55295 || e >= 63744 && e <= 64975 || e >= 65008 && e <= 65533 || e >= 65536 && e <= 983039;
3801
+ }
3802
+ function Sr(e) {
3803
+ return e >= 9 && e <= 13 || e === 32 || e === 133 || e >= 8206 && e <= 8207 || e === 8232 || e === 8233;
3804
+ }
3805
+ function Ri(e) {
3806
+ return e >= 33 && e <= 35 || e === 36 || e >= 37 && e <= 39 || e === 40 || e === 41 || e === 42 || e === 43 || e === 44 || e === 45 || e >= 46 && e <= 47 || e >= 58 && e <= 59 || e >= 60 && e <= 62 || e >= 63 && e <= 64 || e === 91 || e === 92 || e === 93 || e === 94 || e === 96 || e === 123 || e === 124 || e === 125 || e === 126 || e === 161 || e >= 162 && e <= 165 || e === 166 || e === 167 || e === 169 || e === 171 || e === 172 || e === 174 || e === 176 || e === 177 || e === 182 || e === 187 || e === 191 || e === 215 || e === 247 || e >= 8208 && e <= 8213 || e >= 8214 && e <= 8215 || e === 8216 || e === 8217 || e === 8218 || e >= 8219 && e <= 8220 || e === 8221 || e === 8222 || e === 8223 || e >= 8224 && e <= 8231 || e >= 8240 && e <= 8248 || e === 8249 || e === 8250 || e >= 8251 && e <= 8254 || e >= 8257 && e <= 8259 || e === 8260 || e === 8261 || e === 8262 || e >= 8263 && e <= 8273 || e === 8274 || e === 8275 || e >= 8277 && e <= 8286 || e >= 8592 && e <= 8596 || e >= 8597 && e <= 8601 || e >= 8602 && e <= 8603 || e >= 8604 && e <= 8607 || e === 8608 || e >= 8609 && e <= 8610 || e === 8611 || e >= 8612 && e <= 8613 || e === 8614 || e >= 8615 && e <= 8621 || e === 8622 || e >= 8623 && e <= 8653 || e >= 8654 && e <= 8655 || e >= 8656 && e <= 8657 || e === 8658 || e === 8659 || e === 8660 || e >= 8661 && e <= 8691 || e >= 8692 && e <= 8959 || e >= 8960 && e <= 8967 || e === 8968 || e === 8969 || e === 8970 || e === 8971 || e >= 8972 && e <= 8991 || e >= 8992 && e <= 8993 || e >= 8994 && e <= 9e3 || e === 9001 || e === 9002 || e >= 9003 && e <= 9083 || e === 9084 || e >= 9085 && e <= 9114 || e >= 9115 && e <= 9139 || e >= 9140 && e <= 9179 || e >= 9180 && e <= 9185 || e >= 9186 && e <= 9254 || e >= 9255 && e <= 9279 || e >= 9280 && e <= 9290 || e >= 9291 && e <= 9311 || e >= 9472 && e <= 9654 || e === 9655 || e >= 9656 && e <= 9664 || e === 9665 || e >= 9666 && e <= 9719 || e >= 9720 && e <= 9727 || e >= 9728 && e <= 9838 || e === 9839 || e >= 9840 && e <= 10087 || e === 10088 || e === 10089 || e === 10090 || e === 10091 || e === 10092 || e === 10093 || e === 10094 || e === 10095 || e === 10096 || e === 10097 || e === 10098 || e === 10099 || e === 10100 || e === 10101 || e >= 10132 && e <= 10175 || e >= 10176 && e <= 10180 || e === 10181 || e === 10182 || e >= 10183 && e <= 10213 || e === 10214 || e === 10215 || e === 10216 || e === 10217 || e === 10218 || e === 10219 || e === 10220 || e === 10221 || e === 10222 || e === 10223 || e >= 10224 && e <= 10239 || e >= 10240 && e <= 10495 || e >= 10496 && e <= 10626 || e === 10627 || e === 10628 || e === 10629 || e === 10630 || e === 10631 || e === 10632 || e === 10633 || e === 10634 || e === 10635 || e === 10636 || e === 10637 || e === 10638 || e === 10639 || e === 10640 || e === 10641 || e === 10642 || e === 10643 || e === 10644 || e === 10645 || e === 10646 || e === 10647 || e === 10648 || e >= 10649 && e <= 10711 || e === 10712 || e === 10713 || e === 10714 || e === 10715 || e >= 10716 && e <= 10747 || e === 10748 || e === 10749 || e >= 10750 && e <= 11007 || e >= 11008 && e <= 11055 || e >= 11056 && e <= 11076 || e >= 11077 && e <= 11078 || e >= 11079 && e <= 11084 || e >= 11085 && e <= 11123 || e >= 11124 && e <= 11125 || e >= 11126 && e <= 11157 || e === 11158 || e >= 11159 && e <= 11263 || e >= 11776 && e <= 11777 || e === 11778 || e === 11779 || e === 11780 || e === 11781 || e >= 11782 && e <= 11784 || e === 11785 || e === 11786 || e === 11787 || e === 11788 || e === 11789 || e >= 11790 && e <= 11798 || e === 11799 || e >= 11800 && e <= 11801 || e === 11802 || e === 11803 || e === 11804 || e === 11805 || e >= 11806 && e <= 11807 || e === 11808 || e === 11809 || e === 11810 || e === 11811 || e === 11812 || e === 11813 || e === 11814 || e === 11815 || e === 11816 || e === 11817 || e >= 11818 && e <= 11822 || e === 11823 || e >= 11824 && e <= 11833 || e >= 11834 && e <= 11835 || e >= 11836 && e <= 11839 || e === 11840 || e === 11841 || e === 11842 || e >= 11843 && e <= 11855 || e >= 11856 && e <= 11857 || e === 11858 || e >= 11859 && e <= 11903 || e >= 12289 && e <= 12291 || e === 12296 || e === 12297 || e === 12298 || e === 12299 || e === 12300 || e === 12301 || e === 12302 || e === 12303 || e === 12304 || e === 12305 || e >= 12306 && e <= 12307 || e === 12308 || e === 12309 || e === 12310 || e === 12311 || e === 12312 || e === 12313 || e === 12314 || e === 12315 || e === 12316 || e === 12317 || e >= 12318 && e <= 12319 || e === 12320 || e === 12336 || e === 64830 || e === 64831 || e >= 65093 && e <= 65094;
3807
+ }
3808
+ function lt(e) {
3809
+ e.forEach(function(t) {
3810
+ if (delete t.location, dr(t) || mr(t))
3811
+ for (var r in t.options)
3812
+ delete t.options[r].location, lt(t.options[r].value);
3813
+ else
3814
+ cr(t) && gr(t.style) || (fr(t) || pr(t)) && nt(t.style) ? delete t.style.location : br(t) && lt(t.children);
3815
+ });
3816
+ }
3817
+ function $i(e, t) {
3818
+ t === void 0 && (t = {}), t = Ce({ shouldParseSkeletons: !0, requiresOtherClause: !0 }, t);
3819
+ var r = new Mi(e, t).parse();
3820
+ if (r.err) {
3821
+ var n = SyntaxError(g[r.err.kind]);
3822
+ throw n.location = r.err.location, n.originalMessage = r.err.message, n;
3823
+ }
3824
+ return t != null && t.captureLocation || lt(r.val), r.val;
3825
+ }
3826
+ var ee;
3827
+ (function(e) {
3828
+ e.MISSING_VALUE = "MISSING_VALUE", e.INVALID_VALUE = "INVALID_VALUE", e.MISSING_INTL_API = "MISSING_INTL_API";
3829
+ })(ee || (ee = {}));
3830
+ var Me = (
3831
+ /** @class */
3832
+ function(e) {
3833
+ Le(t, e);
3834
+ function t(r, n, i) {
3835
+ var o = e.call(this, r) || this;
3836
+ return o.code = n, o.originalMessage = i, o;
3837
+ }
3838
+ return t.prototype.toString = function() {
3839
+ return "[formatjs Error: ".concat(this.code, "] ").concat(this.message);
3840
+ }, t;
3841
+ }(Error)
3842
+ ), Rt = (
3843
+ /** @class */
3844
+ function(e) {
3845
+ Le(t, e);
3846
+ function t(r, n, i, o) {
3847
+ return e.call(this, 'Invalid values for "'.concat(r, '": "').concat(n, '". Options are "').concat(Object.keys(i).join('", "'), '"'), ee.INVALID_VALUE, o) || this;
3848
+ }
3849
+ return t;
3850
+ }(Me)
3851
+ ), Ui = (
3852
+ /** @class */
3853
+ function(e) {
3854
+ Le(t, e);
3855
+ function t(r, n, i) {
3856
+ return e.call(this, 'Value for "'.concat(r, '" must be of type ').concat(n), ee.INVALID_VALUE, i) || this;
3857
+ }
3858
+ return t;
3859
+ }(Me)
3860
+ ), Di = (
3861
+ /** @class */
3862
+ function(e) {
3863
+ Le(t, e);
3864
+ function t(r, n) {
3865
+ return e.call(this, 'The intl string context variable "'.concat(r, '" was not provided to the string "').concat(n, '"'), ee.MISSING_VALUE, n) || this;
3866
+ }
3867
+ return t;
3868
+ }(Me)
3869
+ ), H;
3870
+ (function(e) {
3871
+ e[e.literal = 0] = "literal", e[e.object = 1] = "object";
3872
+ })(H || (H = {}));
3873
+ function ki(e) {
3874
+ return e.length < 2 ? e : e.reduce(function(t, r) {
3875
+ var n = t[t.length - 1];
3876
+ return !n || n.type !== H.literal || r.type !== H.literal ? t.push(r) : n.value += r.value, t;
3877
+ }, []);
3878
+ }
3879
+ function Gi(e) {
3880
+ return typeof e == "function";
3881
+ }
3882
+ function Ee(e, t, r, n, i, o, s) {
3883
+ if (e.length === 1 && It(e[0]))
3884
+ return [
3885
+ {
3886
+ type: H.literal,
3887
+ value: e[0].value
3888
+ }
3889
+ ];
3890
+ for (var a = [], l = 0, u = e; l < u.length; l++) {
3891
+ var h = u[l];
3892
+ if (It(h)) {
3893
+ a.push({
3894
+ type: H.literal,
3895
+ value: h.value
3896
+ });
3897
+ continue;
3898
+ }
3899
+ if (hi(h)) {
3900
+ typeof o == "number" && a.push({
3901
+ type: H.literal,
3902
+ value: r.getNumberFormat(t).format(o)
3903
+ });
3904
+ continue;
3905
+ }
3906
+ var c = h.value;
3907
+ if (!(i && c in i))
3908
+ throw new Di(c, s);
3909
+ var f = i[c];
3910
+ if (ui(h)) {
3911
+ (!f || typeof f == "string" || typeof f == "number") && (f = typeof f == "string" || typeof f == "number" ? String(f) : ""), a.push({
3912
+ type: typeof f == "string" ? H.literal : H.object,
3913
+ value: f
3914
+ });
3915
+ continue;
3916
+ }
3917
+ if (fr(h)) {
3918
+ var p = typeof h.style == "string" ? n.date[h.style] : nt(h.style) ? h.style.parsedOptions : void 0;
3919
+ a.push({
3920
+ type: H.literal,
3921
+ value: r.getDateTimeFormat(t, p).format(f)
3922
+ });
3923
+ continue;
3924
+ }
3925
+ if (pr(h)) {
3926
+ var p = typeof h.style == "string" ? n.time[h.style] : nt(h.style) ? h.style.parsedOptions : n.time.medium;
3927
+ a.push({
3928
+ type: H.literal,
3929
+ value: r.getDateTimeFormat(t, p).format(f)
3930
+ });
3931
+ continue;
3932
+ }
3933
+ if (cr(h)) {
3934
+ var p = typeof h.style == "string" ? n.number[h.style] : gr(h.style) ? h.style.parsedOptions : void 0;
3935
+ p && p.scale && (f = f * (p.scale || 1)), a.push({
3936
+ type: H.literal,
3937
+ value: r.getNumberFormat(t, p).format(f)
3938
+ });
3939
+ continue;
3940
+ }
3941
+ if (br(h)) {
3942
+ var b = h.children, d = h.value, y = i[d];
3943
+ if (!Gi(y))
3944
+ throw new Ui(d, "function", s);
3945
+ var C = Ee(b, t, r, n, i, o), O = y(C.map(function(x) {
3946
+ return x.value;
3947
+ }));
3948
+ Array.isArray(O) || (O = [O]), a.push.apply(a, O.map(function(x) {
3949
+ return {
3950
+ type: typeof x == "string" ? H.literal : H.object,
3951
+ value: x
3952
+ };
3953
+ }));
3954
+ }
3955
+ if (dr(h)) {
3956
+ var T = h.options[f] || h.options.other;
3957
+ if (!T)
3958
+ throw new Rt(h.value, f, Object.keys(h.options), s);
3959
+ a.push.apply(a, Ee(T.value, t, r, n, i));
3960
+ continue;
3961
+ }
3962
+ if (mr(h)) {
3963
+ var T = h.options["=".concat(f)];
3964
+ if (!T) {
3965
+ if (!Intl.PluralRules)
3966
+ throw new Me(`Intl.PluralRules is not available in this environment.
3967
+ Try polyfilling it using "@formatjs/intl-pluralrules"
3968
+ `, ee.MISSING_INTL_API, s);
3969
+ var B = r.getPluralRules(t, { type: h.pluralType }).select(f - (h.offset || 0));
3970
+ T = h.options[B] || h.options.other;
3971
+ }
3972
+ if (!T)
3973
+ throw new Rt(h.value, f, Object.keys(h.options), s);
3974
+ a.push.apply(a, Ee(T.value, t, r, n, i, f - (h.offset || 0)));
3975
+ continue;
3976
+ }
3977
+ }
3978
+ return ki(a);
3979
+ }
3980
+ function Fi(e, t) {
3981
+ return t ? R(R(R({}, e || {}), t || {}), Object.keys(e).reduce(function(r, n) {
3982
+ return r[n] = R(R({}, e[n]), t[n] || {}), r;
3983
+ }, {})) : e;
3984
+ }
3985
+ function Vi(e, t) {
3986
+ return t ? Object.keys(e).reduce(function(r, n) {
3987
+ return r[n] = Fi(e[n], t[n]), r;
3988
+ }, R({}, e)) : e;
3989
+ }
3990
+ function We(e) {
3991
+ return {
3992
+ create: function() {
3993
+ return {
3994
+ get: function(t) {
3995
+ return e[t];
3996
+ },
3997
+ set: function(t, r) {
3998
+ e[t] = r;
3999
+ }
4000
+ };
4001
+ }
4002
+ };
4003
+ }
4004
+ function Wi(e) {
4005
+ return e === void 0 && (e = {
4006
+ number: {},
4007
+ dateTime: {},
4008
+ pluralRules: {}
4009
+ }), {
4010
+ getNumberFormat: Ge(function() {
4011
+ for (var t, r = [], n = 0; n < arguments.length; n++)
4012
+ r[n] = arguments[n];
4013
+ return new ((t = Intl.NumberFormat).bind.apply(t, ke([void 0], r, !1)))();
4014
+ }, {
4015
+ cache: We(e.number),
4016
+ strategy: Fe.variadic
4017
+ }),
4018
+ getDateTimeFormat: Ge(function() {
4019
+ for (var t, r = [], n = 0; n < arguments.length; n++)
4020
+ r[n] = arguments[n];
4021
+ return new ((t = Intl.DateTimeFormat).bind.apply(t, ke([void 0], r, !1)))();
4022
+ }, {
4023
+ cache: We(e.dateTime),
4024
+ strategy: Fe.variadic
4025
+ }),
4026
+ getPluralRules: Ge(function() {
4027
+ for (var t, r = [], n = 0; n < arguments.length; n++)
4028
+ r[n] = arguments[n];
4029
+ return new ((t = Intl.PluralRules).bind.apply(t, ke([void 0], r, !1)))();
4030
+ }, {
4031
+ cache: We(e.pluralRules),
4032
+ strategy: Fe.variadic
4033
+ })
4034
+ };
4035
+ }
4036
+ var zi = (
4037
+ /** @class */
4038
+ function() {
4039
+ function e(t, r, n, i) {
4040
+ r === void 0 && (r = e.defaultLocale);
4041
+ var o = this;
4042
+ if (this.formatterCache = {
4043
+ number: {},
4044
+ dateTime: {},
4045
+ pluralRules: {}
4046
+ }, this.format = function(l) {
4047
+ var u = o.formatToParts(l);
4048
+ if (u.length === 1)
4049
+ return u[0].value;
4050
+ var h = u.reduce(function(c, f) {
4051
+ return !c.length || f.type !== H.literal || typeof c[c.length - 1] != "string" ? c.push(f.value) : c[c.length - 1] += f.value, c;
4052
+ }, []);
4053
+ return h.length <= 1 ? h[0] || "" : h;
4054
+ }, this.formatToParts = function(l) {
4055
+ return Ee(o.ast, o.locales, o.formatters, o.formats, l, void 0, o.message);
4056
+ }, this.resolvedOptions = function() {
4057
+ var l;
4058
+ return {
4059
+ locale: ((l = o.resolvedLocale) === null || l === void 0 ? void 0 : l.toString()) || Intl.NumberFormat.supportedLocalesOf(o.locales)[0]
4060
+ };
4061
+ }, this.getAst = function() {
4062
+ return o.ast;
4063
+ }, this.locales = r, this.resolvedLocale = e.resolveLocale(r), typeof t == "string") {
4064
+ if (this.message = t, !e.__parse)
4065
+ throw new TypeError("IntlMessageFormat.__parse must be set to process `message` of type `string`");
4066
+ var s = i || {};
4067
+ s.formatters;
4068
+ var a = ti(s, ["formatters"]);
4069
+ this.ast = e.__parse(t, R(R({}, a), { locale: this.resolvedLocale }));
4070
+ } else
4071
+ this.ast = t;
4072
+ if (!Array.isArray(this.ast))
4073
+ throw new TypeError("A message must be provided as a String or AST.");
4074
+ this.formats = Vi(e.formats, n), this.formatters = i && i.formatters || Wi(this.formatterCache);
4075
+ }
4076
+ return Object.defineProperty(e, "defaultLocale", {
4077
+ get: function() {
4078
+ return e.memoizedDefaultLocale || (e.memoizedDefaultLocale = new Intl.NumberFormat().resolvedOptions().locale), e.memoizedDefaultLocale;
4079
+ },
4080
+ enumerable: !1,
4081
+ configurable: !0
4082
+ }), e.memoizedDefaultLocale = null, e.resolveLocale = function(t) {
4083
+ if (typeof Intl.Locale != "undefined") {
4084
+ var r = Intl.NumberFormat.supportedLocalesOf(t);
4085
+ return r.length > 0 ? new Intl.Locale(r[0]) : new Intl.Locale(typeof t == "string" ? t : t[0]);
4086
+ }
4087
+ }, e.__parse = $i, e.formats = {
4088
+ number: {
4089
+ integer: {
4090
+ maximumFractionDigits: 0
4091
+ },
4092
+ currency: {
4093
+ style: "currency"
4094
+ },
4095
+ percent: {
4096
+ style: "percent"
4097
+ }
4098
+ },
4099
+ date: {
4100
+ short: {
4101
+ month: "numeric",
4102
+ day: "numeric",
4103
+ year: "2-digit"
4104
+ },
4105
+ medium: {
4106
+ month: "short",
4107
+ day: "numeric",
4108
+ year: "numeric"
4109
+ },
4110
+ long: {
4111
+ month: "long",
4112
+ day: "numeric",
4113
+ year: "numeric"
4114
+ },
4115
+ full: {
4116
+ weekday: "long",
4117
+ month: "long",
4118
+ day: "numeric",
4119
+ year: "numeric"
4120
+ }
4121
+ },
4122
+ time: {
4123
+ short: {
4124
+ hour: "numeric",
4125
+ minute: "numeric"
4126
+ },
4127
+ medium: {
4128
+ hour: "numeric",
4129
+ minute: "numeric",
4130
+ second: "numeric"
4131
+ },
4132
+ long: {
4133
+ hour: "numeric",
4134
+ minute: "numeric",
4135
+ second: "numeric",
4136
+ timeZoneName: "short"
4137
+ },
4138
+ full: {
4139
+ hour: "numeric",
4140
+ minute: "numeric",
4141
+ second: "numeric",
4142
+ timeZoneName: "short"
4143
+ }
4144
+ }
4145
+ }, e;
4146
+ }()
4147
+ );
4148
+ function Xi(e, t) {
4149
+ if (t == null)
4150
+ return;
4151
+ if (t in e)
4152
+ return e[t];
4153
+ const r = t.split(".");
4154
+ let n = e;
4155
+ for (let i = 0; i < r.length; i++)
4156
+ if (typeof n == "object") {
4157
+ if (i > 0) {
4158
+ const o = r.slice(i, r.length).join(".");
4159
+ if (o in n) {
4160
+ n = n[o];
4161
+ break;
4162
+ }
4163
+ }
4164
+ n = n[r[i]];
4165
+ } else
4166
+ n = void 0;
4167
+ return n;
4168
+ }
4169
+ const k = {}, Zi = (e, t, r) => r && (t in k || (k[t] = {}), e in k[t] || (k[t][e] = r), r), Tr = (e, t) => {
4170
+ if (t == null)
4171
+ return;
4172
+ if (t in k && e in k[t])
4173
+ return k[t][e];
4174
+ const r = Ne(t);
4175
+ for (let n = 0; n < r.length; n++) {
4176
+ const i = r[n], o = Qi(i, e);
4177
+ if (o)
4178
+ return Zi(e, t, o);
4179
+ }
4180
+ };
4181
+ let pt;
4182
+ const ne = Pe({});
4183
+ function Yi(e) {
4184
+ return pt[e] || null;
4185
+ }
4186
+ function Ar(e) {
4187
+ return e in pt;
4188
+ }
4189
+ function Qi(e, t) {
4190
+ if (!Ar(e))
4191
+ return null;
4192
+ const r = Yi(e);
4193
+ return Xi(r, t);
4194
+ }
4195
+ function Ji(e) {
4196
+ if (e == null)
4197
+ return;
4198
+ const t = Ne(e);
4199
+ for (let r = 0; r < t.length; r++) {
4200
+ const n = t[r];
4201
+ if (Ar(n))
4202
+ return n;
4203
+ }
4204
+ }
4205
+ function Cr(e, ...t) {
4206
+ delete k[e], ne.update((r) => (r[e] = ei.all([r[e] || {}, ...t]), r));
4207
+ }
4208
+ re(
4209
+ [ne],
4210
+ ([e]) => Object.keys(e)
4211
+ );
4212
+ ne.subscribe((e) => pt = e);
4213
+ const we = {};
4214
+ function qi(e, t) {
4215
+ we[e].delete(t), we[e].size === 0 && delete we[e];
4216
+ }
4217
+ function Hr(e) {
4218
+ return we[e];
4219
+ }
4220
+ function Ki(e) {
4221
+ return Ne(e).map((t) => {
4222
+ const r = Hr(t);
4223
+ return [t, r ? [...r] : []];
4224
+ }).filter(([, t]) => t.length > 0);
4225
+ }
4226
+ function ut(e) {
4227
+ return e == null ? !1 : Ne(e).some(
4228
+ (t) => {
4229
+ var r;
4230
+ return (r = Hr(t)) == null ? void 0 : r.size;
4231
+ }
4232
+ );
4233
+ }
4234
+ function eo(e, t) {
4235
+ return Promise.all(
4236
+ t.map((n) => (qi(e, n), n().then((i) => i.default || i)))
4237
+ ).then((n) => Cr(e, ...n));
4238
+ }
4239
+ const ae = {};
4240
+ function Br(e) {
4241
+ if (!ut(e))
4242
+ return e in ae ? ae[e] : Promise.resolve();
4243
+ const t = Ki(e);
4244
+ return ae[e] = Promise.all(
4245
+ t.map(
4246
+ ([r, n]) => eo(r, n)
4247
+ )
4248
+ ).then(() => {
4249
+ if (ut(e))
4250
+ return Br(e);
4251
+ delete ae[e];
4252
+ }), ae[e];
4253
+ }
4254
+ const to = {
4255
+ number: {
4256
+ scientific: { notation: "scientific" },
4257
+ engineering: { notation: "engineering" },
4258
+ compactLong: { notation: "compact", compactDisplay: "long" },
4259
+ compactShort: { notation: "compact", compactDisplay: "short" }
4260
+ },
4261
+ date: {
4262
+ short: { month: "numeric", day: "numeric", year: "2-digit" },
4263
+ medium: { month: "short", day: "numeric", year: "numeric" },
4264
+ long: { month: "long", day: "numeric", year: "numeric" },
4265
+ full: { weekday: "long", month: "long", day: "numeric", year: "numeric" }
4266
+ },
4267
+ time: {
4268
+ short: { hour: "numeric", minute: "numeric" },
4269
+ medium: { hour: "numeric", minute: "numeric", second: "numeric" },
4270
+ long: {
4271
+ hour: "numeric",
4272
+ minute: "numeric",
4273
+ second: "numeric",
4274
+ timeZoneName: "short"
4275
+ },
4276
+ full: {
4277
+ hour: "numeric",
4278
+ minute: "numeric",
4279
+ second: "numeric",
4280
+ timeZoneName: "short"
4281
+ }
4282
+ }
4283
+ }, ro = {
4284
+ fallbackLocale: null,
4285
+ loadingDelay: 200,
4286
+ formats: to,
4287
+ warnOnMissingMessages: !0,
4288
+ handleMissingMessage: void 0,
4289
+ ignoreTag: !0
4290
+ }, no = ro;
4291
+ function te() {
4292
+ return no;
4293
+ }
4294
+ const ze = Pe(!1);
4295
+ var io = Object.defineProperty, oo = Object.defineProperties, so = Object.getOwnPropertyDescriptors, $t = Object.getOwnPropertySymbols, ao = Object.prototype.hasOwnProperty, lo = Object.prototype.propertyIsEnumerable, Ut = (e, t, r) => t in e ? io(e, t, { enumerable: !0, configurable: !0, writable: !0, value: r }) : e[t] = r, uo = (e, t) => {
4296
+ for (var r in t || (t = {}))
4297
+ ao.call(t, r) && Ut(e, r, t[r]);
4298
+ if ($t)
4299
+ for (var r of $t(t))
4300
+ lo.call(t, r) && Ut(e, r, t[r]);
4301
+ return e;
4302
+ }, ho = (e, t) => oo(e, so(t));
4303
+ let ht;
4304
+ const He = Pe(null);
4305
+ function Dt(e) {
4306
+ return e.split("-").map((t, r, n) => n.slice(0, r + 1).join("-")).reverse();
4307
+ }
4308
+ function Ne(e, t = te().fallbackLocale) {
4309
+ const r = Dt(e);
4310
+ return t ? [.../* @__PURE__ */ new Set([...r, ...Dt(t)])] : r;
4311
+ }
4312
+ function V() {
4313
+ return ht != null ? ht : void 0;
4314
+ }
4315
+ He.subscribe((e) => {
4316
+ ht = e != null ? e : void 0, typeof window != "undefined" && e != null && document.documentElement.setAttribute("lang", e);
4317
+ });
4318
+ const co = (e) => {
4319
+ if (e && Ji(e) && ut(e)) {
4320
+ const { loadingDelay: t } = te();
4321
+ let r;
4322
+ return typeof window != "undefined" && V() != null && t ? r = window.setTimeout(
4323
+ () => ze.set(!0),
4324
+ t
4325
+ ) : ze.set(!0), Br(e).then(() => {
4326
+ He.set(e);
4327
+ }).finally(() => {
4328
+ clearTimeout(r), ze.set(!1);
4329
+ });
4330
+ }
4331
+ return He.set(e);
4332
+ }, G = ho(uo({}, He), {
4333
+ set: co
4334
+ }), je = (e) => {
4335
+ const t = /* @__PURE__ */ Object.create(null);
4336
+ return (n) => {
4337
+ const i = JSON.stringify(n);
4338
+ return i in t ? t[i] : t[i] = e(n);
4339
+ };
4340
+ };
4341
+ var fo = Object.defineProperty, Be = Object.getOwnPropertySymbols, Ir = Object.prototype.hasOwnProperty, Or = Object.prototype.propertyIsEnumerable, kt = (e, t, r) => t in e ? fo(e, t, { enumerable: !0, configurable: !0, writable: !0, value: r }) : e[t] = r, dt = (e, t) => {
4342
+ for (var r in t || (t = {}))
4343
+ Ir.call(t, r) && kt(e, r, t[r]);
4344
+ if (Be)
4345
+ for (var r of Be(t))
4346
+ Or.call(t, r) && kt(e, r, t[r]);
4347
+ return e;
4348
+ }, ie = (e, t) => {
4349
+ var r = {};
4350
+ for (var n in e)
4351
+ Ir.call(e, n) && t.indexOf(n) < 0 && (r[n] = e[n]);
4352
+ if (e != null && Be)
4353
+ for (var n of Be(e))
4354
+ t.indexOf(n) < 0 && Or.call(e, n) && (r[n] = e[n]);
4355
+ return r;
4356
+ };
4357
+ const pe = (e, t) => {
4358
+ const { formats: r } = te();
4359
+ if (e in r && t in r[e])
4360
+ return r[e][t];
4361
+ throw new Error(`[svelte-i18n] Unknown "${t}" ${e} format.`);
4362
+ }, po = je(
4363
+ (e) => {
4364
+ var t = e, { locale: r, format: n } = t, i = ie(t, ["locale", "format"]);
4365
+ if (r == null)
4366
+ throw new Error('[svelte-i18n] A "locale" must be set to format numbers');
4367
+ return n && (i = pe("number", n)), new Intl.NumberFormat(r, i);
4368
+ }
4369
+ ), mo = je(
4370
+ (e) => {
4371
+ var t = e, { locale: r, format: n } = t, i = ie(t, ["locale", "format"]);
4372
+ if (r == null)
4373
+ throw new Error('[svelte-i18n] A "locale" must be set to format dates');
4374
+ return n ? i = pe("date", n) : Object.keys(i).length === 0 && (i = pe("date", "short")), new Intl.DateTimeFormat(r, i);
4375
+ }
4376
+ ), bo = je(
4377
+ (e) => {
4378
+ var t = e, { locale: r, format: n } = t, i = ie(t, ["locale", "format"]);
4379
+ if (r == null)
4380
+ throw new Error(
4381
+ '[svelte-i18n] A "locale" must be set to format time values'
4382
+ );
4383
+ return n ? i = pe("time", n) : Object.keys(i).length === 0 && (i = pe("time", "short")), new Intl.DateTimeFormat(r, i);
4384
+ }
4385
+ ), go = (e = {}) => {
4386
+ var t = e, {
4387
+ locale: r = V()
4388
+ } = t, n = ie(t, [
4389
+ "locale"
4390
+ ]);
4391
+ return po(dt({ locale: r }, n));
4392
+ }, vo = (e = {}) => {
4393
+ var t = e, {
4394
+ locale: r = V()
4395
+ } = t, n = ie(t, [
4396
+ "locale"
4397
+ ]);
4398
+ return mo(dt({ locale: r }, n));
4399
+ }, yo = (e = {}) => {
4400
+ var t = e, {
4401
+ locale: r = V()
4402
+ } = t, n = ie(t, [
4403
+ "locale"
4404
+ ]);
4405
+ return bo(dt({ locale: r }, n));
4406
+ }, xo = je(
4407
+ // eslint-disable-next-line @typescript-eslint/no-non-null-assertion
4408
+ (e, t = V()) => new zi(e, t, te().formats, {
4409
+ ignoreTag: te().ignoreTag
4410
+ })
4411
+ ), _o = (e, t = {}) => {
4412
+ var r, n, i, o;
4413
+ let s = t;
4414
+ typeof e == "object" && (s = e, e = s.id);
4415
+ const {
4416
+ values: a,
4417
+ locale: l = V(),
4418
+ default: u
4419
+ } = s;
4420
+ if (l == null)
4421
+ throw new Error(
4422
+ "[svelte-i18n] Cannot format a message without first setting the initial locale."
4423
+ );
4424
+ let h = Tr(e, l);
4425
+ if (!h)
4426
+ h = (o = (i = (n = (r = te()).handleMissingMessage) == null ? void 0 : n.call(r, { locale: l, id: e, defaultValue: u })) != null ? i : u) != null ? o : e;
4427
+ else if (typeof h != "string")
4428
+ return console.warn(
4429
+ `[svelte-i18n] Message with id "${e}" must be of type "string", found: "${typeof h}". Gettin its value through the "$format" method is deprecated; use the "json" method instead.`
4430
+ ), h;
4431
+ if (!a)
4432
+ return h;
4433
+ let c = h;
4434
+ try {
4435
+ c = xo(h, l).format(a);
4436
+ } catch (f) {
4437
+ f instanceof Error && console.warn(
4438
+ `[svelte-i18n] Message "${e}" has syntax error:`,
4439
+ f.message
4440
+ );
4441
+ }
4442
+ return c;
4443
+ }, Eo = (e, t) => yo(t).format(e), wo = (e, t) => vo(t).format(e), So = (e, t) => go(t).format(e), To = (e, t = V()) => Tr(e, t), Ao = re([G, ne], () => _o);
4444
+ re([G], () => Eo);
4445
+ re([G], () => wo);
4446
+ re([G], () => So);
4447
+ re([G, ne], () => To);
4448
+ window.emWidgets = { topic: Rn };
4449
+ const Co = (e) => !!(e.toLowerCase().match(/android/i) || e.toLowerCase().match(/blackberry|bb/i) || e.toLowerCase().match(/iphone|ipad|ipod/i) || e.toLowerCase().match(/windows phone|windows mobile|iemobile|wpdesktop/i));
4450
+ String(Number.MAX_SAFE_INTEGER).length;
4451
+ const Gt = {
4452
+ en: {
4453
+ Title: "Prize Games",
4454
+ RemainingTimes: "Remaining Times",
4455
+ NoContent: "No games available at the moment",
4456
+ Loading: "Loading games...",
4457
+ Error: "Failed to load games",
4458
+ WheelOfFortune: "Lucky Wheel",
4459
+ MysteryChest: "Mystery Chest",
4460
+ FlipCoin: "Flip Coin",
4461
+ Dice: "Dices"
4462
+ }
4463
+ };
4464
+ function Ho({ withLocale: e, translations: t }) {
4465
+ G.subscribe((r) => {
4466
+ r == null && (ne.set(t), G.set(e));
4467
+ });
4468
+ }
4469
+ function Pr(e, t) {
4470
+ Cr(e, t);
4471
+ }
4472
+ function Bo(e) {
4473
+ G.set(e);
4474
+ }
4475
+ const Io = () => {
4476
+ Ho({ withLocale: "en", translations: {} }), Object.keys(Gt).forEach((e) => {
4477
+ Pr(e, Gt[e]);
4478
+ });
4479
+ }, Oo = (n) => oe(void 0, [n], function* ({ endpoint: e, session: t, types: r }) {
4480
+ const i = new URL(`${e}/v1/wof/lotteries`);
4481
+ r && r.length > 0 && r.forEach((s) => i.searchParams.append("filter", `Types[]=${s}`));
4482
+ const o = yield fetch(i.toString(), {
4483
+ method: "GET",
4484
+ headers: $e({
4485
+ "Content-Type": "application/json",
4486
+ Accept: "text/plain"
4487
+ }, t ? { "x-SessionId": t } : {})
4488
+ });
4489
+ if (!o.ok)
4490
+ throw new Error(`Failed to fetch lotteries: ${o.statusText}`);
4491
+ return o.json();
4492
+ }), Po = {
4493
+ lotteries: (e, t, r) => oe(void 0, null, function* () {
4494
+ const n = yield Oo({ endpoint: e, session: t, types: r });
4495
+ return (n == null ? void 0 : n.items) || [];
4496
+ })
4497
+ }, Lo = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABIAAAASCAYAAABWzo5XAAAACXBIWXMAABCcAAAQnAEmzTo0AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAMVSURBVHgBbVTNThNRGD3fnSmYYNLizhVl4ZriC9AhcUFcWDYmbsQuiCsT0aioJJRogrJhacJC0MSwMsALMIUHsDQxYSeDCVspiWA7befz3Jm2AnGSm7k/3+85517Bf75F9fMOoikXjTzHkIO6OAgrnFcdNLaK8mjzso+cX5S0kk2h9ZHGeUNnOtY4MlzDRVjjP801DBpBG83xorwMur6mO3ml33MCqSg0r4h2Beo9kduDCtDYHDyUKc5lPAI+03z4CvTbFy3lLgSa1f2sC9dngWk6HjbQLjyTW+VOyb2qp2W6LGg95rRGu0EX2F7X2WwvkEG/z0oyHCesJNuHlF9SP2PPNA6hcbBVXeWeTQh7FgiiwRS344Sv9ehOhMami+aag7MZ/n3iMGLQrKZw4hloxUFTB3B2k7j4BD5HvPZa+O0NoL1BEsYitMdNC1qQOLP5VJLRWgunHtdVZssp+ivEbYhVDocwv2hGTEzQguMVpVSL+WExKeh9kxxK7a3ciDEpicdgraLGTant3zoEBHm30+NQF7O78mbHQI6ZKC/P9UjdmN7mgYM/pDxU0svew7QgXHgqEwvW6YOuUhoh2w6HDMJD6+PEo06iQvp3ACXl5p+4RJN9rXaDGBjLKiuUAIh6NCQfhcGKWEkzvSjZa93t97pbYFYC2ThwUd/heYGZM8wcOEiNFqVY69p+1RfHBDww7K9saZzT/XxH3ZkIMt+xGya4U8yYkViYFrNTf1WXY2ms6xx9lNqTPWPgrHFCEJ15G4RZfbY2wsL3BIaB9CfPgz7oKH33OEZctBmsxKsjUzxjDnfLLMp1Iq87QDtPx4plMSI2Z6R4RiaCJAlg23HQ5zFwlUlyV5D6Qck8YNJgUpY2Y4BTkCI3KHvN8n8c4qpnZYCeqhPwE2xangWccA/y7JgBvN4VKclwYBKD+A7143R5SbfHOhxq94qs6Ar33A3ECVFjB+OT8i5ImD73LfIZiXgNqKMsWeo+HZlEJ3XOwzTX9nkpU3fFe+eekQuBLtFfsHeOziNO/DaRYkqB/zU+bOXLPn8BG6xnv5+RMCQAAAAASUVORK5CYII=", Mo = "data:image/svg+xml,%3csvg%20width='18'%20height='18'%20viewBox='0%200%2018%2018'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M16.5384%203.18261L14.3222%200.9673C13.3202%20-0.0332963%2011.7009%20-0.26734%209.75715%200.310586C7.83938%200.880634%205.79092%202.18711%203.98901%203.98902C2.18711%205.79092%200.88063%207.83939%200.310582%209.75716C-0.26688%2011.7%20-0.0337635%2013.3211%200.965442%2014.3194C0.980736%2014.3361%200.99742%2014.3491%201.01967%2014.362L3.1826%2016.5384C3.83422%2017.1891%204.73749%2017.4996%205.78675%2017.4996C8.0382%2017.4996%2010.9621%2016.0703%2013.5167%2013.5167C17.2605%209.77199%2018.5878%205.23292%2016.5384%203.18261ZM13.2979%205.31681C12.764%206.90692%2011.6378%208.61521%2010.127%2010.1261C8.6152%2011.6369%206.90738%2012.764%205.31681%2013.2979C3.8991%2013.7744%202.71173%2013.7188%202.14169%2013.1469C1.57118%2012.5768%201.5151%2011.3904%201.99153%209.9722C2.52589%208.38209%203.65254%206.67426%205.1634%205.16341C6.67426%203.65209%208.38255%202.52589%209.97312%201.99153C10.6118%201.77649%2011.2031%201.67036%2011.7129%201.67036C12.3349%201.67036%2012.8345%201.8284%2013.1478%202.14169C13.7178%202.7122%2013.7744%203.89911%2013.2979%205.31681ZM12.3423%2012.3414C9.09859%2015.5846%205.53231%2016.5375%204.35699%2015.3622L4.23696%2015.2426C6.4481%2014.9914%209.06753%2013.5343%2011.3014%2011.3014C13.5343%209.06754%2014.9914%206.4481%2015.2426%204.23696L15.3622%204.357C16.5365%205.53093%2015.5846%209.09859%2012.3423%2012.3414Z'%20fill='url(%23paint0_linear_875_137)'/%3e%3cdefs%3e%3clinearGradient%20id='paint0_linear_875_137'%20x1='0'%20y1='8.7498'%20x2='17.5'%20y2='8.7498'%20gradientUnits='userSpaceOnUse'%3e%3cstop%20stop-color='%2375FFE9'/%3e%3cstop%20offset='1'%20stop-color='%23B2FF6D'/%3e%3c/linearGradient%3e%3c/defs%3e%3c/svg%3e", No = "data:image/svg+xml,%3csvg%20width='32'%20height='32'%20viewBox='0%200%2032%2032'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M12.1978%2013.2348C12.1978%209.60751%2015.1383%206.66699%2018.7656%206.66699C22.3929%206.66699%2025.3334%209.60751%2025.3334%2013.2348C25.3334%2016.8621%2022.3929%2019.8026%2018.7656%2019.8026C18.467%2019.8026%2018.1725%2019.7826%2017.8835%2019.7438C17.6825%2019.7168%2017.557%2019.7001%2017.4658%2019.6909C17.4218%2019.7326%2017.3626%2019.7916%2017.2673%2019.8869L12.5565%2024.5977C12.5457%2024.6085%2012.5344%2024.6198%2012.5229%2024.6315C12.4009%2024.7542%2012.2356%2024.9205%2012.0329%2025.0448C11.8576%2025.1522%2011.6665%2025.2313%2011.4666%2025.2793C11.2354%2025.3348%2011.001%2025.3341%2010.8279%2025.3335C10.8115%2025.3335%2010.7956%2025.3334%2010.7803%2025.3334L9.14719%2025.3334C8.91663%2025.3335%208.68571%2025.3335%208.48899%2025.3174C8.27114%2025.2996%208.00565%2025.2571%207.7365%2025.1199C7.36793%2024.9321%207.06826%2024.6325%206.88046%2024.2639C6.74332%2023.9948%206.70076%2023.7293%206.68297%2023.5114C6.66689%2023.3147%206.66693%2023.0838%206.66696%2022.8532L6.66696%2021.2201C6.66696%2021.2049%206.66691%2021.189%206.66686%2021.1725C6.66631%2020.9994%206.66557%2020.765%206.72109%2020.5338C6.76907%2020.3339%206.84822%2020.1428%206.95562%2019.9676C7.07986%2019.7648%207.24617%2019.5995%207.36894%2019.4776C7.3806%2019.466%207.39188%2019.4548%207.40268%2019.4439L12.1135%2014.7331C12.2088%2014.6378%2012.2678%2014.5786%2012.3095%2014.5346C12.3003%2014.4434%2012.2836%2014.3179%2012.2566%2014.1169C12.2178%2013.8279%2012.1978%2013.5334%2012.1978%2013.2348ZM18.7656%208.74104C16.2837%208.74104%2014.2718%2010.753%2014.2718%2013.2348C14.2718%2013.4408%2014.2856%2013.6429%2014.3122%2013.8406L14.3146%2013.8585C14.3394%2014.0432%2014.3618%2014.2097%2014.3749%2014.3451C14.3874%2014.4747%2014.4011%2014.6598%2014.3736%2014.8525C14.3367%2015.1105%2014.2715%2015.3033%2014.1443%2015.5308C14.0078%2015.7751%2013.7931%2015.9881%2013.629%2016.151C13.6121%2016.1678%2013.5958%2016.184%2013.5801%2016.1997L8.86926%2020.9105C8.82845%2020.9513%208.79718%2020.9826%208.77036%2021.0099C8.75929%2021.0212%208.74992%2021.0308%208.74194%2021.0392C8.7417%2021.0507%208.74151%2021.0641%208.74137%2021.0799C8.74102%2021.1182%208.74101%2021.1624%208.74101%2021.2201V22.8215C8.74101%2023.0268%208.74146%2023.1591%208.74514%2023.2553C8.84132%2023.2589%208.97362%2023.2594%209.17887%2023.2594H10.7803C10.838%2023.2594%2010.8822%2023.2594%2010.9205%2023.259C10.9363%2023.2589%2010.9497%2023.2587%2010.9613%2023.2585C10.9696%2023.2505%2010.9792%2023.2411%2010.9905%2023.2301C11.0178%2023.2032%2011.0491%2023.172%2011.0899%2023.1312L15.8007%2018.4203C15.8164%2018.4046%2015.8327%2018.3883%2015.8494%2018.3714C16.0123%2018.2073%2016.2253%2017.9926%2016.4696%2017.8561C16.6971%2017.7289%2016.8899%2017.6638%2017.1479%2017.6268C17.3406%2017.5993%2017.5257%2017.613%2017.6553%2017.6255C17.7907%2017.6386%2017.9572%2017.661%2018.1419%2017.6858L18.1598%2017.6882C18.3575%2017.7148%2018.5597%2017.7286%2018.7656%2017.7286C21.2474%2017.7286%2023.2594%2015.7167%2023.2594%2013.2348C23.2594%2010.753%2021.2474%208.74104%2018.7656%208.74104ZM17.7286%2013.2348C17.7286%2012.6621%2018.1929%2012.1978%2018.7656%2012.1978H18.7748C19.3475%2012.1978%2019.8118%2012.6621%2019.8118%2013.2348C19.8118%2013.8076%2019.3475%2014.2718%2018.7748%2014.2718H18.7656C18.1929%2014.2718%2017.7286%2013.8076%2017.7286%2013.2348Z'%20fill='url(%23paint0_linear_714_605)'/%3e%3cdefs%3e%3clinearGradient%20id='paint0_linear_714_605'%20x1='6.66675'%20y1='16.0003'%20x2='25.3334'%20y2='16.0003'%20gradientUnits='userSpaceOnUse'%3e%3cstop%20stop-color='%2375FFE9'/%3e%3cstop%20offset='1'%20stop-color='%23B2FF6D'/%3e%3c/linearGradient%3e%3c/defs%3e%3c/svg%3e";
4498
+ function jo(e) {
4499
+ Fr(e, "svelte-ljc7r7", `:host{display:block;height:100%;flex-grow:1}.PrizeListContent.svelte-ljc7r7.svelte-ljc7r7{width:100%;height:100%;display:flex;flex-direction:column;font-family:var(--emw--font-family-primary, "Ubuntu", sans-serif)}.ListScrollArea.svelte-ljc7r7.svelte-ljc7r7{flex-grow:1;overflow-y:auto}.ListScrollArea.svelte-ljc7r7.svelte-ljc7r7::-webkit-scrollbar{width:4px}.ListScrollArea.svelte-ljc7r7.svelte-ljc7r7::-webkit-scrollbar-thumb{background:var(--emw--color-gray-105, #1b2e31);border-radius:2px}.LuckyWheelList.svelte-ljc7r7.svelte-ljc7r7{display:flex;flex-direction:column;gap:24px;padding:0;margin:0;list-style:none}.LuckyWheelListItem.svelte-ljc7r7.svelte-ljc7r7{width:100%}.ItemButton.svelte-ljc7r7.svelte-ljc7r7{padding:16px;border-radius:16px;border:1px solid var(--emw--color-teal-10, rgba(117, 255, 233, 0.1019607843));color:var(--emw--color-primary, #d3ffed);width:100%;height:110px;display:flex;flex-direction:column;justify-content:center;gap:8px;box-sizing:border-box;cursor:pointer;text-align:left;transition:all 0.2s cubic-bezier(0.4, 0, 0.2, 1);background:var(--emw--color-teal-05, rgba(117, 255, 233, 0.0509803922));position:relative}.ItemButton.svelte-ljc7r7.svelte-ljc7r7:hover,.ItemButton.svelte-ljc7r7.svelte-ljc7r7:active{background:var(--emw--color-teal-08, rgba(117, 255, 233, 0.0784313725));border:1px solid transparent;background-image:linear-gradient(var(--emw--color-background, #213841), var(--emw--color-background, #213841)), linear-gradient(90deg, var(--emw--color-teal, #75ffe9) 0%, var(--emw--color-green, #b2ff6d) 100%);background-origin:border-box;background-clip:padding-box, border-box}.ItemButton.svelte-ljc7r7:hover .IconButton.Chevron.svelte-ljc7r7,.ItemButton.svelte-ljc7r7:active .IconButton.Chevron.svelte-ljc7r7{background-color:var(--emw--color-green, #b2ff6d);background-image:url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none"><path d="M9 18L15 12L9 6" stroke="%230C1A1C" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/></svg>');border-radius:50%}.ItemTitleRow.svelte-ljc7r7.svelte-ljc7r7{display:flex;justify-content:space-between;align-items:center;width:100%}.ItemTitle.svelte-ljc7r7.svelte-ljc7r7{font-weight:700;font-size:var(--emw--font-size-medium-plus, 18px);background:linear-gradient(90deg, var(--emw--color-teal, #75ffe9) 0%, var(--emw--color-green, #b2ff6d) 100%);-webkit-background-clip:text;background-clip:text;-webkit-text-fill-color:transparent}.ItemDetails.svelte-ljc7r7.svelte-ljc7r7{display:flex;gap:12px;align-items:center}.ItemKeys.svelte-ljc7r7.svelte-ljc7r7,.ItemValidity.svelte-ljc7r7.svelte-ljc7r7{display:flex;gap:4px;align-items:center;font-size:14px;font-weight:400;color:var(--emw--color-secondary-variant, #729787)}.ItemKeys.svelte-ljc7r7 span.svelte-ljc7r7:last-child,.ItemValidity.svelte-ljc7r7 span.svelte-ljc7r7:last-child{color:var(--emw--color-primary, #d3ffed)}.SmallIcon.svelte-ljc7r7.svelte-ljc7r7{width:24px;height:24px;display:flex;align-items:center;justify-content:center;color:var(--emw--color-secondary-variant, #729787);flex-shrink:0}.SmallIcon.Wheel.svelte-ljc7r7.svelte-ljc7r7{background-position:center;background-repeat:no-repeat;background-size:16px 16px;width:16px;height:16px}.IconButton.Chevron.svelte-ljc7r7.svelte-ljc7r7{width:30px;height:30px;border:0;cursor:pointer;background-color:transparent;background:center/18px 18px url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none"><path d="M9 18L15 12L9 6" stroke="%23729787" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/></svg>') no-repeat}.LoaderWrap.svelte-ljc7r7.svelte-ljc7r7{display:flex;flex-direction:column;width:100%}.LoaderWrap.svelte-ljc7r7 .Skeleton{border-radius:var(--emw--border-radius-small, 12px);--emw-skeleton-primary-color:var(--emw--color-primary, #d9d9d9);--emw-skeleton-secondary-color:var(--emw--color-secondary, #999999)}.LoaderWrap.svelte-ljc7r7 .WheelLoader.svelte-ljc7r7{border-radius:var(--emw--border-radius-large, 28px);display:flex;padding:45px 48px;background:var(--emw--color-background-secondary, #233e42);border:1px solid var(--emw--button-border-color-secondary, #244346);justify-content:space-between;line-height:35px;overflow:hidden;margin-bottom:24px}.LoaderWrap.Mobile.svelte-ljc7r7 .WheelLoader.svelte-ljc7r7{border-radius:16px;padding:25px 20px;line-height:15px}.LoaderWrap.Mobile.svelte-ljc7r7 .Skeleton.SkeletonText{width:135px}.EmptyState.svelte-ljc7r7.svelte-ljc7r7{width:100%;display:flex;flex-direction:column;color:var(--emw--color-secondary-variant, #a9ccbe);font-size:var(--emw--font-size-medium, 16px);align-items:center;justify-content:center;height:200px}.Mobile.svelte-ljc7r7 .ItemButton.svelte-ljc7r7{height:72px;padding:16px 20px;border-radius:16px}.Mobile.svelte-ljc7r7 .ItemButton .ItemTitle.svelte-ljc7r7{font-size:var(--emw--font-size-medium, 16px)}.Mobile.svelte-ljc7r7 .ItemButton .ItemDetails.svelte-ljc7r7{font-size:var(--emw--font-size-x-small, 12px)}.Mobile.svelte-ljc7r7 .IconButton.Chevron.svelte-ljc7r7{width:24px;height:24px;background-size:14px 14px}.Mobile.svelte-ljc7r7 .SmallIcon.Wheel.svelte-ljc7r7{background-size:14px 14px;width:14px;height:14px}`);
4500
+ }
4501
+ function Ft(e, t, r) {
4502
+ const n = e.slice();
4503
+ return n[23] = t[r], n;
4504
+ }
4505
+ function Ro(e, t, r) {
4506
+ const n = e.slice();
4507
+ return n[20] = t[r], n;
4508
+ }
4509
+ function $o(e) {
4510
+ let t, r, n = (
4511
+ /*$_*/
4512
+ e[5]("NoContent") + ""
4513
+ ), i;
4514
+ return {
4515
+ c() {
4516
+ t = S("div"), r = S("p"), i = ue(n), A(t, "class", "EmptyState svelte-ljc7r7");
4517
+ },
4518
+ m(o, s) {
4519
+ F(o, t, s), E(t, r), E(r, i);
4520
+ },
4521
+ p(o, s) {
4522
+ s & /*$_*/
4523
+ 32 && n !== (n = /*$_*/
4524
+ o[5]("NoContent") + "") && Se(i, n);
4525
+ },
4526
+ d(o) {
4527
+ o && $(t);
4528
+ }
4529
+ };
4530
+ }
4531
+ function Uo(e) {
4532
+ let t, r = Ye(
4533
+ /*programs*/
4534
+ e[3]
4535
+ ), n = [];
4536
+ for (let i = 0; i < r.length; i += 1)
4537
+ n[i] = Wt(Ft(e, r, i));
4538
+ return {
4539
+ c() {
4540
+ t = S("ul");
4541
+ for (let i = 0; i < n.length; i += 1)
4542
+ n[i].c();
4543
+ A(t, "class", "LuckyWheelList svelte-ljc7r7");
4544
+ },
4545
+ m(i, o) {
4546
+ F(i, t, o);
4547
+ for (let s = 0; s < n.length; s += 1)
4548
+ n[s] && n[s].m(t, null);
4549
+ },
4550
+ p(i, o) {
4551
+ if (o & /*openGame, programs, formatValidity, dynamicIcon, lang*/
4552
+ 409) {
4553
+ r = Ye(
4554
+ /*programs*/
4555
+ i[3]
4556
+ );
4557
+ let s;
4558
+ for (s = 0; s < r.length; s += 1) {
4559
+ const a = Ft(i, r, s);
4560
+ n[s] ? n[s].p(a, o) : (n[s] = Wt(a), n[s].c(), n[s].m(t, null));
4561
+ }
4562
+ for (; s < n.length; s += 1)
4563
+ n[s].d(1);
4564
+ n.length = r.length;
4565
+ }
4566
+ },
4567
+ d(i) {
4568
+ i && $(t), Kt(n, i);
4569
+ }
4570
+ };
4571
+ }
4572
+ function Do(e) {
4573
+ let t, r = Ye([1, 2, 3, 4, 5]), n = [];
4574
+ for (let i = 0; i < 5; i += 1)
4575
+ n[i] = ko(Ro(e, r, i));
4576
+ return {
4577
+ c() {
4578
+ t = S("div");
4579
+ for (let i = 0; i < 5; i += 1)
4580
+ n[i].c();
4581
+ A(t, "class", "LoaderWrap svelte-ljc7r7"), er(
4582
+ t,
4583
+ "Mobile",
4584
+ /*mobileView*/
4585
+ e[6]
4586
+ );
4587
+ },
4588
+ m(i, o) {
4589
+ F(i, t, o);
4590
+ for (let s = 0; s < 5; s += 1)
4591
+ n[s] && n[s].m(t, null);
4592
+ },
4593
+ p: I,
4594
+ d(i) {
4595
+ i && $(t), Kt(n, i);
4596
+ }
4597
+ };
4598
+ }
4599
+ function Vt(e) {
4600
+ let t, r, n, i, o = (
4601
+ /*formatValidity*/
4602
+ e[7](
4603
+ /*program*/
4604
+ e[23].current.expiryTime
4605
+ ) + ""
4606
+ ), s;
4607
+ return {
4608
+ c() {
4609
+ t = S("div"), r = S("span"), r.innerHTML = '<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg"><circle cx="12" cy="14" r="7" stroke="currentColor" stroke-width="1.5"></circle><path d="M12 11V14L14 16" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 4V7" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M9 4H15" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M17 7L18 8" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M7 7L6 8" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path></svg>', n = X(), i = S("span"), s = ue(o), A(r, "class", "SmallIcon Timer svelte-ljc7r7"), A(i, "class", "svelte-ljc7r7"), A(t, "class", "ItemValidity svelte-ljc7r7");
4610
+ },
4611
+ m(a, l) {
4612
+ F(a, t, l), E(t, r), E(t, n), E(t, i), E(i, s);
4613
+ },
4614
+ p(a, l) {
4615
+ l & /*programs*/
4616
+ 8 && o !== (o = /*formatValidity*/
4617
+ a[7](
4618
+ /*program*/
4619
+ a[23].current.expiryTime
4620
+ ) + "") && Se(s, o);
4621
+ },
4622
+ d(a) {
4623
+ a && $(t);
4624
+ }
4625
+ };
4626
+ }
4627
+ function Wt(e) {
4628
+ var m, M;
4629
+ let t, r, n, i, o = (
4630
+ /*program*/
4631
+ (e[23].program.name[
4632
+ /*lang*/
4633
+ e[0]
4634
+ ] || /*program*/
4635
+ e[23].program.name["*"] || "Unknown Game") + ""
4636
+ ), s, a, l, u, h, c, f, p, b, d = (
4637
+ /*program*/
4638
+ (((m = e[23].current) == null ? void 0 : m.remainingTimes) || 0) + ""
4639
+ ), y, C, O, T, B, x = (
4640
+ /*program*/
4641
+ ((M = e[23].current) == null ? void 0 : M.expiryTime) && Vt(e)
4642
+ );
4643
+ function D() {
4644
+ return (
4645
+ /*click_handler*/
4646
+ e[16](
4647
+ /*program*/
4648
+ e[23]
4649
+ )
4650
+ );
4651
+ }
4652
+ return {
4653
+ c() {
4654
+ t = S("li"), r = S("button"), n = S("div"), i = S("span"), s = ue(o), a = X(), l = S("span"), u = X(), h = S("div"), c = S("div"), f = S("span"), p = X(), b = S("span"), y = ue(d), C = X(), x && x.c(), O = X(), A(i, "class", "ItemTitle svelte-ljc7r7"), A(l, "class", "IconButton Chevron svelte-ljc7r7"), A(n, "class", "ItemTitleRow svelte-ljc7r7"), A(f, "class", "SmallIcon Wheel svelte-ljc7r7"), vt(f, "background-image", "url(" + /*dynamicIcon*/
4655
+ e[4] + ")"), A(b, "class", "svelte-ljc7r7"), A(c, "class", "ItemKeys svelte-ljc7r7"), A(h, "class", "ItemDetails svelte-ljc7r7"), A(r, "type", "button"), A(r, "class", "ItemButton svelte-ljc7r7"), A(t, "class", "LuckyWheelListItem svelte-ljc7r7");
4656
+ },
4657
+ m(P, N) {
4658
+ F(P, t, N), E(t, r), E(r, n), E(n, i), E(i, s), E(n, a), E(n, l), E(r, u), E(r, h), E(h, c), E(c, f), E(c, p), E(c, b), E(b, y), E(h, C), x && x.m(h, null), E(t, O), T || (B = Wr(r, "click", D), T = !0);
4659
+ },
4660
+ p(P, N) {
4661
+ var be, ge;
4662
+ e = P, N & /*programs, lang*/
4663
+ 9 && o !== (o = /*program*/
4664
+ (e[23].program.name[
4665
+ /*lang*/
4666
+ e[0]
4667
+ ] || /*program*/
4668
+ e[23].program.name["*"] || "Unknown Game") + "") && Se(s, o), N & /*dynamicIcon*/
4669
+ 16 && vt(f, "background-image", "url(" + /*dynamicIcon*/
4670
+ e[4] + ")"), N & /*programs*/
4671
+ 8 && d !== (d = /*program*/
4672
+ (((be = e[23].current) == null ? void 0 : be.remainingTimes) || 0) + "") && Se(y, d), /*program*/
4673
+ (ge = e[23].current) != null && ge.expiryTime ? x ? x.p(e, N) : (x = Vt(e), x.c(), x.m(h, null)) : x && (x.d(1), x = null);
4674
+ },
4675
+ d(P) {
4676
+ P && $(t), x && x.d(), T = !1, B();
4677
+ }
4678
+ };
4679
+ }
4680
+ function ko(e) {
4681
+ let t;
4682
+ return {
4683
+ c() {
4684
+ t = S("div"), t.innerHTML = '<ui-skeleton structure="text" height="16px"></ui-skeleton> <ui-skeleton structure="rectangle" width="50px" height="16px"></ui-skeleton> ', A(t, "class", "WheelLoader svelte-ljc7r7");
4685
+ },
4686
+ m(r, n) {
4687
+ F(r, t, n);
4688
+ },
4689
+ p: I,
4690
+ d(r) {
4691
+ r && $(t);
4692
+ }
4693
+ };
4694
+ }
4695
+ function Go(e) {
4696
+ let t, r, n;
4697
+ function i(a, l) {
4698
+ return (
4699
+ /*loading*/
4700
+ a[2] ? Do : (
4701
+ /*programs*/
4702
+ a[3].length > 0 ? Uo : $o
4703
+ )
4704
+ );
4705
+ }
4706
+ let o = i(e), s = o(e);
4707
+ return {
4708
+ c() {
4709
+ t = S("div"), r = S("div"), s.c(), A(r, "class", "ListScrollArea svelte-ljc7r7"), A(t, "class", "PrizeListContent svelte-ljc7r7"), er(
4710
+ t,
4711
+ "Mobile",
4712
+ /*mobileView*/
4713
+ e[6]
4714
+ );
4715
+ },
4716
+ m(a, l) {
4717
+ F(a, t, l), E(t, r), s.m(r, null), e[17](t);
4718
+ },
4719
+ p(a, [l]) {
4720
+ o === (o = i(a)) && s ? s.p(a, l) : (s.d(1), s = o(a), s && (s.c(), s.m(r, null)));
4721
+ },
4722
+ i(a) {
4723
+ a && (n || ce(() => {
4724
+ n = hn(t, vn, { duration: 300 }), n.start();
4725
+ }));
4726
+ },
4727
+ o: I,
4728
+ d(a) {
4729
+ a && $(t), s.d(), e[17](null);
4730
+ }
4731
+ };
4732
+ }
4733
+ let Fo = null;
4734
+ function Vo(e, t, r) {
4735
+ let n, i;
4736
+ Dr(e, Ao, (m) => r(5, i = m));
4737
+ let { endpoint: o = "" } = t, { session: s = "" } = t, { lang: a = "en" } = t, { clientstyling: l = "" } = t, { clientstylingurl: u = "" } = t, { translationurl: h = "" } = t, { mbsource: c = "" } = t, { type: f = "wheelOfFortune" } = t, p;
4738
+ const b = Co(window.navigator.userAgent);
4739
+ let d = !0, y = [];
4740
+ Io();
4741
+ const C = () => {
4742
+ fetch(h).then((M) => M.json()).then((M) => {
4743
+ Object.keys(M).forEach((P) => {
4744
+ Pr(P, M[P]);
4745
+ });
4746
+ });
4747
+ }, O = (m) => {
4748
+ if (!m)
4749
+ return "";
4750
+ const M = new Date(m).getTime(), P = Date.now(), N = M - P;
4751
+ if (N <= 0)
4752
+ return "";
4753
+ const be = Math.floor(N / (1e3 * 60 * 60 * 24)), ge = Math.floor(N % (1e3 * 60 * 60 * 24) / (1e3 * 60 * 60)), Lr = Math.floor(N % (1e3 * 60 * 60) / (1e3 * 60));
4754
+ return `${be.toString().padStart(2, "0")}d:${ge.toString().padStart(2, "0")}h:${Lr.toString().padStart(2, "0")}m`;
4755
+ }, T = () => oe(this, null, function* () {
4756
+ if (!(!o || !s)) {
4757
+ r(2, d = !0);
4758
+ try {
4759
+ const m = yield Po.lotteries(o, s, [f]);
4760
+ window.postMessage(
4761
+ {
4762
+ type: "PrizeProgramsLoaded",
4763
+ data: m
4764
+ },
4765
+ "*"
4766
+ ), r(3, y = m.filter((M) => {
4767
+ var P;
4768
+ return (Number((P = M.current) == null ? void 0 : P.remainingTimes) || 0) > 0;
4769
+ }));
4770
+ } catch (m) {
4771
+ console.error("[PrizeEngineList] Fetch failed", m);
4772
+ } finally {
4773
+ r(2, d = !1);
4774
+ }
4775
+ }
4776
+ }), B = (m) => {
4777
+ window.postMessage({ type: "OpenPrizeGame", data: m }, "*");
4778
+ };
4779
+ en(() => () => {
4780
+ });
4781
+ const x = (m) => B(m);
4782
+ function D(m) {
4783
+ Xe[m ? "unshift" : "push"](() => {
4784
+ p = m, r(1, p);
4785
+ });
4786
+ }
4787
+ return e.$$set = (m) => {
4788
+ "endpoint" in m && r(9, o = m.endpoint), "session" in m && r(10, s = m.session), "lang" in m && r(0, a = m.lang), "clientstyling" in m && r(11, l = m.clientstyling), "clientstylingurl" in m && r(12, u = m.clientstylingurl), "translationurl" in m && r(13, h = m.translationurl), "mbsource" in m && r(14, c = m.mbsource), "type" in m && r(15, f = m.type);
4789
+ }, e.$$.update = () => {
4790
+ e.$$.dirty & /*lang*/
4791
+ 1 && a && Bo(a), e.$$.dirty & /*translationurl*/
4792
+ 8192 && h && C(), e.$$.dirty & /*type*/
4793
+ 32768 && r(4, n = f === "flipCoin" ? Mo : f === "mysteryChest" ? No : Lo), e.$$.dirty & /*endpoint, session, type*/
4794
+ 34304 && o && s && f && T(), e.$$.dirty & /*clientstyling, rootContainer*/
4795
+ 2050 && l && p && yn(p, l), e.$$.dirty & /*clientstylingurl, rootContainer*/
4796
+ 4098 && u && p && xn(p, u), e.$$.dirty & /*mbsource, rootContainer*/
4797
+ 16386 && c && p && _n(p, `${c}.Style`, Fo);
4798
+ }, [
4799
+ a,
4800
+ p,
4801
+ d,
4802
+ y,
4803
+ n,
4804
+ i,
4805
+ b,
4806
+ O,
4807
+ B,
4808
+ o,
4809
+ s,
4810
+ l,
4811
+ u,
4812
+ h,
4813
+ c,
4814
+ f,
4815
+ x,
4816
+ D
4817
+ ];
4818
+ }
4819
+ class Wo extends bn {
4820
+ constructor(t) {
4821
+ super(), dn(
4822
+ this,
4823
+ t,
4824
+ Vo,
4825
+ Go,
4826
+ Zt,
4827
+ {
4828
+ endpoint: 9,
4829
+ session: 10,
4830
+ lang: 0,
4831
+ clientstyling: 11,
4832
+ clientstylingurl: 12,
4833
+ translationurl: 13,
4834
+ mbsource: 14,
4835
+ type: 15
4836
+ },
4837
+ jo
4838
+ );
4839
+ }
4840
+ get endpoint() {
4841
+ return this.$$.ctx[9];
4842
+ }
4843
+ set endpoint(t) {
4844
+ this.$$set({ endpoint: t }), j();
4845
+ }
4846
+ get session() {
4847
+ return this.$$.ctx[10];
4848
+ }
4849
+ set session(t) {
4850
+ this.$$set({ session: t }), j();
4851
+ }
4852
+ get lang() {
4853
+ return this.$$.ctx[0];
4854
+ }
4855
+ set lang(t) {
4856
+ this.$$set({ lang: t }), j();
4857
+ }
4858
+ get clientstyling() {
4859
+ return this.$$.ctx[11];
4860
+ }
4861
+ set clientstyling(t) {
4862
+ this.$$set({ clientstyling: t }), j();
4863
+ }
4864
+ get clientstylingurl() {
4865
+ return this.$$.ctx[12];
4866
+ }
4867
+ set clientstylingurl(t) {
4868
+ this.$$set({ clientstylingurl: t }), j();
4869
+ }
4870
+ get translationurl() {
4871
+ return this.$$.ctx[13];
4872
+ }
4873
+ set translationurl(t) {
4874
+ this.$$set({ translationurl: t }), j();
4875
+ }
4876
+ get mbsource() {
4877
+ return this.$$.ctx[14];
4878
+ }
4879
+ set mbsource(t) {
4880
+ this.$$set({ mbsource: t }), j();
4881
+ }
4882
+ get type() {
4883
+ return this.$$.ctx[15];
4884
+ }
4885
+ set type(t) {
4886
+ this.$$set({ type: t }), j();
4887
+ }
4888
+ }
4889
+ customElements.define("prize-engine-list", mn(Wo, { endpoint: {}, session: {}, lang: {}, clientstyling: {}, clientstylingurl: {}, translationurl: {}, mbsource: {}, type: {} }, [], [], !0));
4890
+ export {
4891
+ Wo as default
4892
+ };