@telia-ace/widget-components-area-flamingo 1.1.70-rc.11 → 1.1.70-rc.13

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,2253 @@
1
+ /**
2
+ * @license
3
+ * Copyright 2019 Google LLC
4
+ * SPDX-License-Identifier: BSD-3-Clause
5
+ */
6
+ const W = globalThis, gt = W.ShadowRoot && (W.ShadyCSS === void 0 || W.ShadyCSS.nativeShadow) && "adoptedStyleSheets" in Document.prototype && "replace" in CSSStyleSheet.prototype, vt = Symbol(), Ct = /* @__PURE__ */ new WeakMap();
7
+ let Zt = class {
8
+ constructor(t, e, i) {
9
+ if (this._$cssResult$ = !0, i !== vt)
10
+ throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");
11
+ this.cssText = t, this.t = e;
12
+ }
13
+ get styleSheet() {
14
+ let t = this.o;
15
+ const e = this.t;
16
+ if (gt && t === void 0) {
17
+ const i = e !== void 0 && e.length === 1;
18
+ i && (t = Ct.get(e)), t === void 0 && ((this.o = t = new CSSStyleSheet()).replaceSync(this.cssText), i && Ct.set(e, t));
19
+ }
20
+ return t;
21
+ }
22
+ toString() {
23
+ return this.cssText;
24
+ }
25
+ };
26
+ const fe = (s) => new Zt(typeof s == "string" ? s : s + "", void 0, vt), E = (s, ...t) => {
27
+ const e = s.length === 1 ? s[0] : t.reduce((i, r, n) => i + ((o) => {
28
+ if (o._$cssResult$ === !0)
29
+ return o.cssText;
30
+ if (typeof o == "number")
31
+ return o;
32
+ throw Error("Value passed to 'css' function must be a 'css' function result: " + o + ". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.");
33
+ })(r) + s[n + 1], s[0]);
34
+ return new Zt(e, s, vt);
35
+ }, ge = (s, t) => {
36
+ if (gt)
37
+ s.adoptedStyleSheets = t.map((e) => e instanceof CSSStyleSheet ? e : e.styleSheet);
38
+ else
39
+ for (const e of t) {
40
+ const i = document.createElement("style"), r = W.litNonce;
41
+ r !== void 0 && i.setAttribute("nonce", r), i.textContent = e.cssText, s.appendChild(i);
42
+ }
43
+ }, St = gt ? (s) => s : (s) => s instanceof CSSStyleSheet ? ((t) => {
44
+ let e = "";
45
+ for (const i of t.cssRules)
46
+ e += i.cssText;
47
+ return fe(e);
48
+ })(s) : s;
49
+ /**
50
+ * @license
51
+ * Copyright 2017 Google LLC
52
+ * SPDX-License-Identifier: BSD-3-Clause
53
+ */
54
+ const { is: ve, defineProperty: me, getOwnPropertyDescriptor: ye, getOwnPropertyNames: be, getOwnPropertySymbols: $e, getPrototypeOf: _e } = Object, $ = globalThis, Et = $.trustedTypes, we = Et ? Et.emptyScript : "", et = $.reactiveElementPolyfillSupport, R = (s, t) => s, q = { toAttribute(s, t) {
55
+ switch (t) {
56
+ case Boolean:
57
+ s = s ? we : null;
58
+ break;
59
+ case Object:
60
+ case Array:
61
+ s = s == null ? s : JSON.stringify(s);
62
+ }
63
+ return s;
64
+ }, fromAttribute(s, t) {
65
+ let e = s;
66
+ switch (t) {
67
+ case Boolean:
68
+ e = s !== null;
69
+ break;
70
+ case Number:
71
+ e = s === null ? null : Number(s);
72
+ break;
73
+ case Object:
74
+ case Array:
75
+ try {
76
+ e = JSON.parse(s);
77
+ } catch {
78
+ e = null;
79
+ }
80
+ }
81
+ return e;
82
+ } }, mt = (s, t) => !ve(s, t), Pt = { attribute: !0, type: String, converter: q, reflect: !1, hasChanged: mt };
83
+ Symbol.metadata ?? (Symbol.metadata = Symbol("metadata")), $.litPropertyMetadata ?? ($.litPropertyMetadata = /* @__PURE__ */ new WeakMap());
84
+ let T = class extends HTMLElement {
85
+ static addInitializer(t) {
86
+ this._$Ei(), (this.l ?? (this.l = [])).push(t);
87
+ }
88
+ static get observedAttributes() {
89
+ return this.finalize(), this._$Eh && [...this._$Eh.keys()];
90
+ }
91
+ static createProperty(t, e = Pt) {
92
+ if (e.state && (e.attribute = !1), this._$Ei(), this.elementProperties.set(t, e), !e.noAccessor) {
93
+ const i = Symbol(), r = this.getPropertyDescriptor(t, i, e);
94
+ r !== void 0 && me(this.prototype, t, r);
95
+ }
96
+ }
97
+ static getPropertyDescriptor(t, e, i) {
98
+ const { get: r, set: n } = ye(this.prototype, t) ?? { get() {
99
+ return this[e];
100
+ }, set(o) {
101
+ this[e] = o;
102
+ } };
103
+ return { get() {
104
+ return r == null ? void 0 : r.call(this);
105
+ }, set(o) {
106
+ const a = r == null ? void 0 : r.call(this);
107
+ n.call(this, o), this.requestUpdate(t, a, i);
108
+ }, configurable: !0, enumerable: !0 };
109
+ }
110
+ static getPropertyOptions(t) {
111
+ return this.elementProperties.get(t) ?? Pt;
112
+ }
113
+ static _$Ei() {
114
+ if (this.hasOwnProperty(R("elementProperties")))
115
+ return;
116
+ const t = _e(this);
117
+ t.finalize(), t.l !== void 0 && (this.l = [...t.l]), this.elementProperties = new Map(t.elementProperties);
118
+ }
119
+ static finalize() {
120
+ if (this.hasOwnProperty(R("finalized")))
121
+ return;
122
+ if (this.finalized = !0, this._$Ei(), this.hasOwnProperty(R("properties"))) {
123
+ const e = this.properties, i = [...be(e), ...$e(e)];
124
+ for (const r of i)
125
+ this.createProperty(r, e[r]);
126
+ }
127
+ const t = this[Symbol.metadata];
128
+ if (t !== null) {
129
+ const e = litPropertyMetadata.get(t);
130
+ if (e !== void 0)
131
+ for (const [i, r] of e)
132
+ this.elementProperties.set(i, r);
133
+ }
134
+ this._$Eh = /* @__PURE__ */ new Map();
135
+ for (const [e, i] of this.elementProperties) {
136
+ const r = this._$Eu(e, i);
137
+ r !== void 0 && this._$Eh.set(r, e);
138
+ }
139
+ this.elementStyles = this.finalizeStyles(this.styles);
140
+ }
141
+ static finalizeStyles(t) {
142
+ const e = [];
143
+ if (Array.isArray(t)) {
144
+ const i = new Set(t.flat(1 / 0).reverse());
145
+ for (const r of i)
146
+ e.unshift(St(r));
147
+ } else
148
+ t !== void 0 && e.push(St(t));
149
+ return e;
150
+ }
151
+ static _$Eu(t, e) {
152
+ const i = e.attribute;
153
+ return i === !1 ? void 0 : typeof i == "string" ? i : typeof t == "string" ? t.toLowerCase() : void 0;
154
+ }
155
+ constructor() {
156
+ super(), this._$Ep = void 0, this.isUpdatePending = !1, this.hasUpdated = !1, this._$Em = null, this._$Ev();
157
+ }
158
+ _$Ev() {
159
+ var t;
160
+ this._$ES = new Promise((e) => this.enableUpdating = e), this._$AL = /* @__PURE__ */ new Map(), this._$E_(), this.requestUpdate(), (t = this.constructor.l) == null || t.forEach((e) => e(this));
161
+ }
162
+ addController(t) {
163
+ var e;
164
+ (this._$EO ?? (this._$EO = /* @__PURE__ */ new Set())).add(t), this.renderRoot !== void 0 && this.isConnected && ((e = t.hostConnected) == null || e.call(t));
165
+ }
166
+ removeController(t) {
167
+ var e;
168
+ (e = this._$EO) == null || e.delete(t);
169
+ }
170
+ _$E_() {
171
+ const t = /* @__PURE__ */ new Map(), e = this.constructor.elementProperties;
172
+ for (const i of e.keys())
173
+ this.hasOwnProperty(i) && (t.set(i, this[i]), delete this[i]);
174
+ t.size > 0 && (this._$Ep = t);
175
+ }
176
+ createRenderRoot() {
177
+ const t = this.shadowRoot ?? this.attachShadow(this.constructor.shadowRootOptions);
178
+ return ge(t, this.constructor.elementStyles), t;
179
+ }
180
+ connectedCallback() {
181
+ var t;
182
+ this.renderRoot ?? (this.renderRoot = this.createRenderRoot()), this.enableUpdating(!0), (t = this._$EO) == null || t.forEach((e) => {
183
+ var i;
184
+ return (i = e.hostConnected) == null ? void 0 : i.call(e);
185
+ });
186
+ }
187
+ enableUpdating(t) {
188
+ }
189
+ disconnectedCallback() {
190
+ var t;
191
+ (t = this._$EO) == null || t.forEach((e) => {
192
+ var i;
193
+ return (i = e.hostDisconnected) == null ? void 0 : i.call(e);
194
+ });
195
+ }
196
+ attributeChangedCallback(t, e, i) {
197
+ this._$AK(t, i);
198
+ }
199
+ _$EC(t, e) {
200
+ var n;
201
+ const i = this.constructor.elementProperties.get(t), r = this.constructor._$Eu(t, i);
202
+ if (r !== void 0 && i.reflect === !0) {
203
+ const o = (((n = i.converter) == null ? void 0 : n.toAttribute) !== void 0 ? i.converter : q).toAttribute(e, i.type);
204
+ this._$Em = t, o == null ? this.removeAttribute(r) : this.setAttribute(r, o), this._$Em = null;
205
+ }
206
+ }
207
+ _$AK(t, e) {
208
+ var n;
209
+ const i = this.constructor, r = i._$Eh.get(t);
210
+ if (r !== void 0 && this._$Em !== r) {
211
+ const o = i.getPropertyOptions(r), a = typeof o.converter == "function" ? { fromAttribute: o.converter } : ((n = o.converter) == null ? void 0 : n.fromAttribute) !== void 0 ? o.converter : q;
212
+ this._$Em = r, this[r] = a.fromAttribute(e, o.type), this._$Em = null;
213
+ }
214
+ }
215
+ requestUpdate(t, e, i) {
216
+ if (t !== void 0) {
217
+ if (i ?? (i = this.constructor.getPropertyOptions(t)), !(i.hasChanged ?? mt)(this[t], e))
218
+ return;
219
+ this.P(t, e, i);
220
+ }
221
+ this.isUpdatePending === !1 && (this._$ES = this._$ET());
222
+ }
223
+ P(t, e, i) {
224
+ this._$AL.has(t) || this._$AL.set(t, e), i.reflect === !0 && this._$Em !== t && (this._$Ej ?? (this._$Ej = /* @__PURE__ */ new Set())).add(t);
225
+ }
226
+ async _$ET() {
227
+ this.isUpdatePending = !0;
228
+ try {
229
+ await this._$ES;
230
+ } catch (e) {
231
+ Promise.reject(e);
232
+ }
233
+ const t = this.scheduleUpdate();
234
+ return t != null && await t, !this.isUpdatePending;
235
+ }
236
+ scheduleUpdate() {
237
+ return this.performUpdate();
238
+ }
239
+ performUpdate() {
240
+ var i;
241
+ if (!this.isUpdatePending)
242
+ return;
243
+ if (!this.hasUpdated) {
244
+ if (this.renderRoot ?? (this.renderRoot = this.createRenderRoot()), this._$Ep) {
245
+ for (const [n, o] of this._$Ep)
246
+ this[n] = o;
247
+ this._$Ep = void 0;
248
+ }
249
+ const r = this.constructor.elementProperties;
250
+ if (r.size > 0)
251
+ for (const [n, o] of r)
252
+ o.wrapped !== !0 || this._$AL.has(n) || this[n] === void 0 || this.P(n, this[n], o);
253
+ }
254
+ let t = !1;
255
+ const e = this._$AL;
256
+ try {
257
+ t = this.shouldUpdate(e), t ? (this.willUpdate(e), (i = this._$EO) == null || i.forEach((r) => {
258
+ var n;
259
+ return (n = r.hostUpdate) == null ? void 0 : n.call(r);
260
+ }), this.update(e)) : this._$EU();
261
+ } catch (r) {
262
+ throw t = !1, this._$EU(), r;
263
+ }
264
+ t && this._$AE(e);
265
+ }
266
+ willUpdate(t) {
267
+ }
268
+ _$AE(t) {
269
+ var e;
270
+ (e = this._$EO) == null || e.forEach((i) => {
271
+ var r;
272
+ return (r = i.hostUpdated) == null ? void 0 : r.call(i);
273
+ }), this.hasUpdated || (this.hasUpdated = !0, this.firstUpdated(t)), this.updated(t);
274
+ }
275
+ _$EU() {
276
+ this._$AL = /* @__PURE__ */ new Map(), this.isUpdatePending = !1;
277
+ }
278
+ get updateComplete() {
279
+ return this.getUpdateComplete();
280
+ }
281
+ getUpdateComplete() {
282
+ return this._$ES;
283
+ }
284
+ shouldUpdate(t) {
285
+ return !0;
286
+ }
287
+ update(t) {
288
+ this._$Ej && (this._$Ej = this._$Ej.forEach((e) => this._$EC(e, this[e]))), this._$EU();
289
+ }
290
+ updated(t) {
291
+ }
292
+ firstUpdated(t) {
293
+ }
294
+ };
295
+ T.elementStyles = [], T.shadowRootOptions = { mode: "open" }, T[R("elementProperties")] = /* @__PURE__ */ new Map(), T[R("finalized")] = /* @__PURE__ */ new Map(), et == null || et({ ReactiveElement: T }), ($.reactiveElementVersions ?? ($.reactiveElementVersions = [])).push("2.0.4");
296
+ /**
297
+ * @license
298
+ * Copyright 2017 Google LLC
299
+ * SPDX-License-Identifier: BSD-3-Clause
300
+ */
301
+ const j = globalThis, Z = j.trustedTypes, Ot = Z ? Z.createPolicy("lit-html", { createHTML: (s) => s }) : void 0, Kt = "$lit$", b = `lit$${(Math.random() + "").slice(9)}$`, Gt = "?" + b, Ae = `<${Gt}>`, C = document, N = () => C.createComment(""), L = (s) => s === null || typeof s != "object" && typeof s != "function", Xt = Array.isArray, xe = (s) => Xt(s) || typeof (s == null ? void 0 : s[Symbol.iterator]) == "function", it = `[
302
+ \f\r]`, k = /<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g, Tt = /-->/g, Ut = />/g, _ = RegExp(`>|${it}(?:([^\\s"'>=/]+)(${it}*=${it}*(?:[^
303
+ \f\r"'\`<>=]|("|')|))|$)`, "g"), kt = /'/g, Rt = /"/g, Jt = /^(?:script|style|textarea|title)$/i, Ce = (s) => (t, ...e) => ({ _$litType$: s, strings: t, values: e }), A = Ce(1), S = Symbol.for("lit-noChange"), u = Symbol.for("lit-nothing"), jt = /* @__PURE__ */ new WeakMap(), x = C.createTreeWalker(C, 129);
304
+ function Qt(s, t) {
305
+ if (!Array.isArray(s) || !s.hasOwnProperty("raw"))
306
+ throw Error("invalid template strings array");
307
+ return Ot !== void 0 ? Ot.createHTML(t) : t;
308
+ }
309
+ const Se = (s, t) => {
310
+ const e = s.length - 1, i = [];
311
+ let r, n = t === 2 ? "<svg>" : "", o = k;
312
+ for (let a = 0; a < e; a++) {
313
+ const c = s[a];
314
+ let l, h, p = -1, d = 0;
315
+ for (; d < c.length && (o.lastIndex = d, h = o.exec(c), h !== null); )
316
+ d = o.lastIndex, o === k ? h[1] === "!--" ? o = Tt : h[1] !== void 0 ? o = Ut : h[2] !== void 0 ? (Jt.test(h[2]) && (r = RegExp("</" + h[2], "g")), o = _) : h[3] !== void 0 && (o = _) : o === _ ? h[0] === ">" ? (o = r ?? k, p = -1) : h[1] === void 0 ? p = -2 : (p = o.lastIndex - h[2].length, l = h[1], o = h[3] === void 0 ? _ : h[3] === '"' ? Rt : kt) : o === Rt || o === kt ? o = _ : o === Tt || o === Ut ? o = k : (o = _, r = void 0);
317
+ const f = o === _ && s[a + 1].startsWith("/>") ? " " : "";
318
+ n += o === k ? c + Ae : p >= 0 ? (i.push(l), c.slice(0, p) + Kt + c.slice(p) + b + f) : c + b + (p === -2 ? a : f);
319
+ }
320
+ return [Qt(s, n + (s[e] || "<?>") + (t === 2 ? "</svg>" : "")), i];
321
+ };
322
+ class H {
323
+ constructor({ strings: t, _$litType$: e }, i) {
324
+ let r;
325
+ this.parts = [];
326
+ let n = 0, o = 0;
327
+ const a = t.length - 1, c = this.parts, [l, h] = Se(t, e);
328
+ if (this.el = H.createElement(l, i), x.currentNode = this.el.content, e === 2) {
329
+ const p = this.el.content.firstChild;
330
+ p.replaceWith(...p.childNodes);
331
+ }
332
+ for (; (r = x.nextNode()) !== null && c.length < a; ) {
333
+ if (r.nodeType === 1) {
334
+ if (r.hasAttributes())
335
+ for (const p of r.getAttributeNames())
336
+ if (p.endsWith(Kt)) {
337
+ const d = h[o++], f = r.getAttribute(p).split(b), O = /([.?@])?(.*)/.exec(d);
338
+ c.push({ type: 1, index: n, name: O[2], strings: f, ctor: O[1] === "." ? Pe : O[1] === "?" ? Oe : O[1] === "@" ? Te : J }), r.removeAttribute(p);
339
+ } else
340
+ p.startsWith(b) && (c.push({ type: 6, index: n }), r.removeAttribute(p));
341
+ if (Jt.test(r.tagName)) {
342
+ const p = r.textContent.split(b), d = p.length - 1;
343
+ if (d > 0) {
344
+ r.textContent = Z ? Z.emptyScript : "";
345
+ for (let f = 0; f < d; f++)
346
+ r.append(p[f], N()), x.nextNode(), c.push({ type: 2, index: ++n });
347
+ r.append(p[d], N());
348
+ }
349
+ }
350
+ } else if (r.nodeType === 8)
351
+ if (r.data === Gt)
352
+ c.push({ type: 2, index: n });
353
+ else {
354
+ let p = -1;
355
+ for (; (p = r.data.indexOf(b, p + 1)) !== -1; )
356
+ c.push({ type: 7, index: n }), p += b.length - 1;
357
+ }
358
+ n++;
359
+ }
360
+ }
361
+ static createElement(t, e) {
362
+ const i = C.createElement("template");
363
+ return i.innerHTML = t, i;
364
+ }
365
+ }
366
+ function U(s, t, e = s, i) {
367
+ var o, a;
368
+ if (t === S)
369
+ return t;
370
+ let r = i !== void 0 ? (o = e._$Co) == null ? void 0 : o[i] : e._$Cl;
371
+ const n = L(t) ? void 0 : t._$litDirective$;
372
+ return (r == null ? void 0 : r.constructor) !== n && ((a = r == null ? void 0 : r._$AO) == null || a.call(r, !1), n === void 0 ? r = void 0 : (r = new n(s), r._$AT(s, e, i)), i !== void 0 ? (e._$Co ?? (e._$Co = []))[i] = r : e._$Cl = r), r !== void 0 && (t = U(s, r._$AS(s, t.values), r, i)), t;
373
+ }
374
+ class Ee {
375
+ constructor(t, e) {
376
+ this._$AV = [], this._$AN = void 0, this._$AD = t, this._$AM = e;
377
+ }
378
+ get parentNode() {
379
+ return this._$AM.parentNode;
380
+ }
381
+ get _$AU() {
382
+ return this._$AM._$AU;
383
+ }
384
+ u(t) {
385
+ const { el: { content: e }, parts: i } = this._$AD, r = ((t == null ? void 0 : t.creationScope) ?? C).importNode(e, !0);
386
+ x.currentNode = r;
387
+ let n = x.nextNode(), o = 0, a = 0, c = i[0];
388
+ for (; c !== void 0; ) {
389
+ if (o === c.index) {
390
+ let l;
391
+ c.type === 2 ? l = new I(n, n.nextSibling, this, t) : c.type === 1 ? l = new c.ctor(n, c.name, c.strings, this, t) : c.type === 6 && (l = new Ue(n, this, t)), this._$AV.push(l), c = i[++a];
392
+ }
393
+ o !== (c == null ? void 0 : c.index) && (n = x.nextNode(), o++);
394
+ }
395
+ return x.currentNode = C, r;
396
+ }
397
+ p(t) {
398
+ let e = 0;
399
+ for (const i of this._$AV)
400
+ i !== void 0 && (i.strings !== void 0 ? (i._$AI(t, i, e), e += i.strings.length - 2) : i._$AI(t[e])), e++;
401
+ }
402
+ }
403
+ class I {
404
+ get _$AU() {
405
+ var t;
406
+ return ((t = this._$AM) == null ? void 0 : t._$AU) ?? this._$Cv;
407
+ }
408
+ constructor(t, e, i, r) {
409
+ this.type = 2, this._$AH = u, this._$AN = void 0, this._$AA = t, this._$AB = e, this._$AM = i, this.options = r, this._$Cv = (r == null ? void 0 : r.isConnected) ?? !0;
410
+ }
411
+ get parentNode() {
412
+ let t = this._$AA.parentNode;
413
+ const e = this._$AM;
414
+ return e !== void 0 && (t == null ? void 0 : t.nodeType) === 11 && (t = e.parentNode), t;
415
+ }
416
+ get startNode() {
417
+ return this._$AA;
418
+ }
419
+ get endNode() {
420
+ return this._$AB;
421
+ }
422
+ _$AI(t, e = this) {
423
+ t = U(this, t, e), L(t) ? t === u || t == null || t === "" ? (this._$AH !== u && this._$AR(), this._$AH = u) : t !== this._$AH && t !== S && this._(t) : t._$litType$ !== void 0 ? this.$(t) : t.nodeType !== void 0 ? this.T(t) : xe(t) ? this.k(t) : this._(t);
424
+ }
425
+ S(t) {
426
+ return this._$AA.parentNode.insertBefore(t, this._$AB);
427
+ }
428
+ T(t) {
429
+ this._$AH !== t && (this._$AR(), this._$AH = this.S(t));
430
+ }
431
+ _(t) {
432
+ this._$AH !== u && L(this._$AH) ? this._$AA.nextSibling.data = t : this.T(C.createTextNode(t)), this._$AH = t;
433
+ }
434
+ $(t) {
435
+ var n;
436
+ const { values: e, _$litType$: i } = t, r = typeof i == "number" ? this._$AC(t) : (i.el === void 0 && (i.el = H.createElement(Qt(i.h, i.h[0]), this.options)), i);
437
+ if (((n = this._$AH) == null ? void 0 : n._$AD) === r)
438
+ this._$AH.p(e);
439
+ else {
440
+ const o = new Ee(r, this), a = o.u(this.options);
441
+ o.p(e), this.T(a), this._$AH = o;
442
+ }
443
+ }
444
+ _$AC(t) {
445
+ let e = jt.get(t.strings);
446
+ return e === void 0 && jt.set(t.strings, e = new H(t)), e;
447
+ }
448
+ k(t) {
449
+ Xt(this._$AH) || (this._$AH = [], this._$AR());
450
+ const e = this._$AH;
451
+ let i, r = 0;
452
+ for (const n of t)
453
+ r === e.length ? e.push(i = new I(this.S(N()), this.S(N()), this, this.options)) : i = e[r], i._$AI(n), r++;
454
+ r < e.length && (this._$AR(i && i._$AB.nextSibling, r), e.length = r);
455
+ }
456
+ _$AR(t = this._$AA.nextSibling, e) {
457
+ var i;
458
+ for ((i = this._$AP) == null ? void 0 : i.call(this, !1, !0, e); t && t !== this._$AB; ) {
459
+ const r = t.nextSibling;
460
+ t.remove(), t = r;
461
+ }
462
+ }
463
+ setConnected(t) {
464
+ var e;
465
+ this._$AM === void 0 && (this._$Cv = t, (e = this._$AP) == null || e.call(this, t));
466
+ }
467
+ }
468
+ class J {
469
+ get tagName() {
470
+ return this.element.tagName;
471
+ }
472
+ get _$AU() {
473
+ return this._$AM._$AU;
474
+ }
475
+ constructor(t, e, i, r, n) {
476
+ this.type = 1, this._$AH = u, this._$AN = void 0, this.element = t, this.name = e, this._$AM = r, this.options = n, i.length > 2 || i[0] !== "" || i[1] !== "" ? (this._$AH = Array(i.length - 1).fill(new String()), this.strings = i) : this._$AH = u;
477
+ }
478
+ _$AI(t, e = this, i, r) {
479
+ const n = this.strings;
480
+ let o = !1;
481
+ if (n === void 0)
482
+ t = U(this, t, e, 0), o = !L(t) || t !== this._$AH && t !== S, o && (this._$AH = t);
483
+ else {
484
+ const a = t;
485
+ let c, l;
486
+ for (t = n[0], c = 0; c < n.length - 1; c++)
487
+ l = U(this, a[i + c], e, c), l === S && (l = this._$AH[c]), o || (o = !L(l) || l !== this._$AH[c]), l === u ? t = u : t !== u && (t += (l ?? "") + n[c + 1]), this._$AH[c] = l;
488
+ }
489
+ o && !r && this.j(t);
490
+ }
491
+ j(t) {
492
+ t === u ? this.element.removeAttribute(this.name) : this.element.setAttribute(this.name, t ?? "");
493
+ }
494
+ }
495
+ class Pe extends J {
496
+ constructor() {
497
+ super(...arguments), this.type = 3;
498
+ }
499
+ j(t) {
500
+ this.element[this.name] = t === u ? void 0 : t;
501
+ }
502
+ }
503
+ class Oe extends J {
504
+ constructor() {
505
+ super(...arguments), this.type = 4;
506
+ }
507
+ j(t) {
508
+ this.element.toggleAttribute(this.name, !!t && t !== u);
509
+ }
510
+ }
511
+ class Te extends J {
512
+ constructor(t, e, i, r, n) {
513
+ super(t, e, i, r, n), this.type = 5;
514
+ }
515
+ _$AI(t, e = this) {
516
+ if ((t = U(this, t, e, 0) ?? u) === S)
517
+ return;
518
+ const i = this._$AH, r = t === u && i !== u || t.capture !== i.capture || t.once !== i.once || t.passive !== i.passive, n = t !== u && (i === u || r);
519
+ r && this.element.removeEventListener(this.name, this, i), n && this.element.addEventListener(this.name, this, t), this._$AH = t;
520
+ }
521
+ handleEvent(t) {
522
+ var e;
523
+ typeof this._$AH == "function" ? this._$AH.call(((e = this.options) == null ? void 0 : e.host) ?? this.element, t) : this._$AH.handleEvent(t);
524
+ }
525
+ }
526
+ class Ue {
527
+ constructor(t, e, i) {
528
+ this.element = t, this.type = 6, this._$AN = void 0, this._$AM = e, this.options = i;
529
+ }
530
+ get _$AU() {
531
+ return this._$AM._$AU;
532
+ }
533
+ _$AI(t) {
534
+ U(this, t);
535
+ }
536
+ }
537
+ const st = j.litHtmlPolyfillSupport;
538
+ st == null || st(H, I), (j.litHtmlVersions ?? (j.litHtmlVersions = [])).push("3.1.2");
539
+ const ke = (s, t, e) => {
540
+ const i = (e == null ? void 0 : e.renderBefore) ?? t;
541
+ let r = i._$litPart$;
542
+ if (r === void 0) {
543
+ const n = (e == null ? void 0 : e.renderBefore) ?? null;
544
+ i._$litPart$ = r = new I(t.insertBefore(N(), n), n, void 0, e ?? {});
545
+ }
546
+ return r._$AI(s), r;
547
+ };
548
+ /**
549
+ * @license
550
+ * Copyright 2017 Google LLC
551
+ * SPDX-License-Identifier: BSD-3-Clause
552
+ */
553
+ let m = class extends T {
554
+ constructor() {
555
+ super(...arguments), this.renderOptions = { host: this }, this._$Do = void 0;
556
+ }
557
+ createRenderRoot() {
558
+ var e;
559
+ const t = super.createRenderRoot();
560
+ return (e = this.renderOptions).renderBefore ?? (e.renderBefore = t.firstChild), t;
561
+ }
562
+ update(t) {
563
+ const e = this.render();
564
+ this.hasUpdated || (this.renderOptions.isConnected = this.isConnected), super.update(t), this._$Do = ke(e, this.renderRoot, this.renderOptions);
565
+ }
566
+ connectedCallback() {
567
+ var t;
568
+ super.connectedCallback(), (t = this._$Do) == null || t.setConnected(!0);
569
+ }
570
+ disconnectedCallback() {
571
+ var t;
572
+ super.disconnectedCallback(), (t = this._$Do) == null || t.setConnected(!1);
573
+ }
574
+ render() {
575
+ return S;
576
+ }
577
+ };
578
+ var qt;
579
+ m._$litElement$ = !0, m.finalized = !0, (qt = globalThis.litElementHydrateSupport) == null || qt.call(globalThis, { LitElement: m });
580
+ const rt = globalThis.litElementPolyfillSupport;
581
+ rt == null || rt({ LitElement: m });
582
+ (globalThis.litElementVersions ?? (globalThis.litElementVersions = [])).push("4.0.4");
583
+ /**
584
+ * @license
585
+ * Copyright 2021 Google LLC
586
+ * SPDX-License-Identifier: BSD-3-Clause
587
+ */
588
+ function* te(s, t) {
589
+ if (s !== void 0) {
590
+ let e = 0;
591
+ for (const i of s)
592
+ yield t(i, e++);
593
+ }
594
+ }
595
+ var ht = function(s, t) {
596
+ return ht = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(e, i) {
597
+ e.__proto__ = i;
598
+ } || function(e, i) {
599
+ for (var r in i)
600
+ Object.prototype.hasOwnProperty.call(i, r) && (e[r] = i[r]);
601
+ }, ht(s, t);
602
+ };
603
+ function D(s, t) {
604
+ if (typeof t != "function" && t !== null)
605
+ throw new TypeError("Class extends value " + String(t) + " is not a constructor or null");
606
+ ht(s, t);
607
+ function e() {
608
+ this.constructor = s;
609
+ }
610
+ s.prototype = t === null ? Object.create(t) : (e.prototype = t.prototype, new e());
611
+ }
612
+ function pt(s) {
613
+ var t = typeof Symbol == "function" && Symbol.iterator, e = t && s[t], i = 0;
614
+ if (e)
615
+ return e.call(s);
616
+ if (s && typeof s.length == "number")
617
+ return {
618
+ next: function() {
619
+ return s && i >= s.length && (s = void 0), { value: s && s[i++], done: !s };
620
+ }
621
+ };
622
+ throw new TypeError(t ? "Object is not iterable." : "Symbol.iterator is not defined.");
623
+ }
624
+ function K(s, t) {
625
+ var e = typeof Symbol == "function" && s[Symbol.iterator];
626
+ if (!e)
627
+ return s;
628
+ var i = e.call(s), r, n = [], o;
629
+ try {
630
+ for (; (t === void 0 || t-- > 0) && !(r = i.next()).done; )
631
+ n.push(r.value);
632
+ } catch (a) {
633
+ o = { error: a };
634
+ } finally {
635
+ try {
636
+ r && !r.done && (e = i.return) && e.call(i);
637
+ } finally {
638
+ if (o)
639
+ throw o.error;
640
+ }
641
+ }
642
+ return n;
643
+ }
644
+ function G(s, t, e) {
645
+ if (e || arguments.length === 2)
646
+ for (var i = 0, r = t.length, n; i < r; i++)
647
+ (n || !(i in t)) && (n || (n = Array.prototype.slice.call(t, 0, i)), n[i] = t[i]);
648
+ return s.concat(n || Array.prototype.slice.call(t));
649
+ }
650
+ function y(s) {
651
+ return typeof s == "function";
652
+ }
653
+ function ee(s) {
654
+ var t = function(i) {
655
+ Error.call(i), i.stack = new Error().stack;
656
+ }, e = s(t);
657
+ return e.prototype = Object.create(Error.prototype), e.prototype.constructor = e, e;
658
+ }
659
+ var nt = ee(function(s) {
660
+ return function(e) {
661
+ s(this), this.message = e ? e.length + ` errors occurred during unsubscription:
662
+ ` + e.map(function(i, r) {
663
+ return r + 1 + ") " + i.toString();
664
+ }).join(`
665
+ `) : "", this.name = "UnsubscriptionError", this.errors = e;
666
+ };
667
+ });
668
+ function ut(s, t) {
669
+ if (s) {
670
+ var e = s.indexOf(t);
671
+ 0 <= e && s.splice(e, 1);
672
+ }
673
+ }
674
+ var Q = function() {
675
+ function s(t) {
676
+ this.initialTeardown = t, this.closed = !1, this._parentage = null, this._finalizers = null;
677
+ }
678
+ return s.prototype.unsubscribe = function() {
679
+ var t, e, i, r, n;
680
+ if (!this.closed) {
681
+ this.closed = !0;
682
+ var o = this._parentage;
683
+ if (o)
684
+ if (this._parentage = null, Array.isArray(o))
685
+ try {
686
+ for (var a = pt(o), c = a.next(); !c.done; c = a.next()) {
687
+ var l = c.value;
688
+ l.remove(this);
689
+ }
690
+ } catch (v) {
691
+ t = { error: v };
692
+ } finally {
693
+ try {
694
+ c && !c.done && (e = a.return) && e.call(a);
695
+ } finally {
696
+ if (t)
697
+ throw t.error;
698
+ }
699
+ }
700
+ else
701
+ o.remove(this);
702
+ var h = this.initialTeardown;
703
+ if (y(h))
704
+ try {
705
+ h();
706
+ } catch (v) {
707
+ n = v instanceof nt ? v.errors : [v];
708
+ }
709
+ var p = this._finalizers;
710
+ if (p) {
711
+ this._finalizers = null;
712
+ try {
713
+ for (var d = pt(p), f = d.next(); !f.done; f = d.next()) {
714
+ var O = f.value;
715
+ try {
716
+ Mt(O);
717
+ } catch (v) {
718
+ n = n ?? [], v instanceof nt ? n = G(G([], K(n)), K(v.errors)) : n.push(v);
719
+ }
720
+ }
721
+ } catch (v) {
722
+ i = { error: v };
723
+ } finally {
724
+ try {
725
+ f && !f.done && (r = d.return) && r.call(d);
726
+ } finally {
727
+ if (i)
728
+ throw i.error;
729
+ }
730
+ }
731
+ }
732
+ if (n)
733
+ throw new nt(n);
734
+ }
735
+ }, s.prototype.add = function(t) {
736
+ var e;
737
+ if (t && t !== this)
738
+ if (this.closed)
739
+ Mt(t);
740
+ else {
741
+ if (t instanceof s) {
742
+ if (t.closed || t._hasParent(this))
743
+ return;
744
+ t._addParent(this);
745
+ }
746
+ (this._finalizers = (e = this._finalizers) !== null && e !== void 0 ? e : []).push(t);
747
+ }
748
+ }, s.prototype._hasParent = function(t) {
749
+ var e = this._parentage;
750
+ return e === t || Array.isArray(e) && e.includes(t);
751
+ }, s.prototype._addParent = function(t) {
752
+ var e = this._parentage;
753
+ this._parentage = Array.isArray(e) ? (e.push(t), e) : e ? [e, t] : t;
754
+ }, s.prototype._removeParent = function(t) {
755
+ var e = this._parentage;
756
+ e === t ? this._parentage = null : Array.isArray(e) && ut(e, t);
757
+ }, s.prototype.remove = function(t) {
758
+ var e = this._finalizers;
759
+ e && ut(e, t), t instanceof s && t._removeParent(this);
760
+ }, s.EMPTY = function() {
761
+ var t = new s();
762
+ return t.closed = !0, t;
763
+ }(), s;
764
+ }(), ie = Q.EMPTY;
765
+ function se(s) {
766
+ return s instanceof Q || s && "closed" in s && y(s.remove) && y(s.add) && y(s.unsubscribe);
767
+ }
768
+ function Mt(s) {
769
+ y(s) ? s() : s.unsubscribe();
770
+ }
771
+ var re = {
772
+ onUnhandledError: null,
773
+ onStoppedNotification: null,
774
+ Promise: void 0,
775
+ useDeprecatedSynchronousErrorHandling: !1,
776
+ useDeprecatedNextContext: !1
777
+ }, dt = {
778
+ setTimeout: function(s, t) {
779
+ for (var e = [], i = 2; i < arguments.length; i++)
780
+ e[i - 2] = arguments[i];
781
+ var r = dt.delegate;
782
+ return r != null && r.setTimeout ? r.setTimeout.apply(r, G([s, t], K(e))) : setTimeout.apply(void 0, G([s, t], K(e)));
783
+ },
784
+ clearTimeout: function(s) {
785
+ var t = dt.delegate;
786
+ return ((t == null ? void 0 : t.clearTimeout) || clearTimeout)(s);
787
+ },
788
+ delegate: void 0
789
+ };
790
+ function Re(s) {
791
+ dt.setTimeout(function() {
792
+ throw s;
793
+ });
794
+ }
795
+ function Nt() {
796
+ }
797
+ function V(s) {
798
+ s();
799
+ }
800
+ var ne = function(s) {
801
+ D(t, s);
802
+ function t(e) {
803
+ var i = s.call(this) || this;
804
+ return i.isStopped = !1, e ? (i.destination = e, se(e) && e.add(i)) : i.destination = Le, i;
805
+ }
806
+ return t.create = function(e, i, r) {
807
+ return new ft(e, i, r);
808
+ }, t.prototype.next = function(e) {
809
+ this.isStopped || this._next(e);
810
+ }, t.prototype.error = function(e) {
811
+ this.isStopped || (this.isStopped = !0, this._error(e));
812
+ }, t.prototype.complete = function() {
813
+ this.isStopped || (this.isStopped = !0, this._complete());
814
+ }, t.prototype.unsubscribe = function() {
815
+ this.closed || (this.isStopped = !0, s.prototype.unsubscribe.call(this), this.destination = null);
816
+ }, t.prototype._next = function(e) {
817
+ this.destination.next(e);
818
+ }, t.prototype._error = function(e) {
819
+ try {
820
+ this.destination.error(e);
821
+ } finally {
822
+ this.unsubscribe();
823
+ }
824
+ }, t.prototype._complete = function() {
825
+ try {
826
+ this.destination.complete();
827
+ } finally {
828
+ this.unsubscribe();
829
+ }
830
+ }, t;
831
+ }(Q), je = Function.prototype.bind;
832
+ function ot(s, t) {
833
+ return je.call(s, t);
834
+ }
835
+ var Me = function() {
836
+ function s(t) {
837
+ this.partialObserver = t;
838
+ }
839
+ return s.prototype.next = function(t) {
840
+ var e = this.partialObserver;
841
+ if (e.next)
842
+ try {
843
+ e.next(t);
844
+ } catch (i) {
845
+ F(i);
846
+ }
847
+ }, s.prototype.error = function(t) {
848
+ var e = this.partialObserver;
849
+ if (e.error)
850
+ try {
851
+ e.error(t);
852
+ } catch (i) {
853
+ F(i);
854
+ }
855
+ else
856
+ F(t);
857
+ }, s.prototype.complete = function() {
858
+ var t = this.partialObserver;
859
+ if (t.complete)
860
+ try {
861
+ t.complete();
862
+ } catch (e) {
863
+ F(e);
864
+ }
865
+ }, s;
866
+ }(), ft = function(s) {
867
+ D(t, s);
868
+ function t(e, i, r) {
869
+ var n = s.call(this) || this, o;
870
+ if (y(e) || !e)
871
+ o = {
872
+ next: e ?? void 0,
873
+ error: i ?? void 0,
874
+ complete: r ?? void 0
875
+ };
876
+ else {
877
+ var a;
878
+ n && re.useDeprecatedNextContext ? (a = Object.create(e), a.unsubscribe = function() {
879
+ return n.unsubscribe();
880
+ }, o = {
881
+ next: e.next && ot(e.next, a),
882
+ error: e.error && ot(e.error, a),
883
+ complete: e.complete && ot(e.complete, a)
884
+ }) : o = e;
885
+ }
886
+ return n.destination = new Me(o), n;
887
+ }
888
+ return t;
889
+ }(ne);
890
+ function F(s) {
891
+ Re(s);
892
+ }
893
+ function Ne(s) {
894
+ throw s;
895
+ }
896
+ var Le = {
897
+ closed: !0,
898
+ next: Nt,
899
+ error: Ne,
900
+ complete: Nt
901
+ }, He = function() {
902
+ return typeof Symbol == "function" && Symbol.observable || "@@observable";
903
+ }();
904
+ function Ie(s) {
905
+ return s;
906
+ }
907
+ function De(s) {
908
+ return s.length === 0 ? Ie : s.length === 1 ? s[0] : function(e) {
909
+ return s.reduce(function(i, r) {
910
+ return r(i);
911
+ }, e);
912
+ };
913
+ }
914
+ var Lt = function() {
915
+ function s(t) {
916
+ t && (this._subscribe = t);
917
+ }
918
+ return s.prototype.lift = function(t) {
919
+ var e = new s();
920
+ return e.source = this, e.operator = t, e;
921
+ }, s.prototype.subscribe = function(t, e, i) {
922
+ var r = this, n = ze(t) ? t : new ft(t, e, i);
923
+ return V(function() {
924
+ var o = r, a = o.operator, c = o.source;
925
+ n.add(a ? a.call(n, c) : c ? r._subscribe(n) : r._trySubscribe(n));
926
+ }), n;
927
+ }, s.prototype._trySubscribe = function(t) {
928
+ try {
929
+ return this._subscribe(t);
930
+ } catch (e) {
931
+ t.error(e);
932
+ }
933
+ }, s.prototype.forEach = function(t, e) {
934
+ var i = this;
935
+ return e = Ht(e), new e(function(r, n) {
936
+ var o = new ft({
937
+ next: function(a) {
938
+ try {
939
+ t(a);
940
+ } catch (c) {
941
+ n(c), o.unsubscribe();
942
+ }
943
+ },
944
+ error: n,
945
+ complete: r
946
+ });
947
+ i.subscribe(o);
948
+ });
949
+ }, s.prototype._subscribe = function(t) {
950
+ var e;
951
+ return (e = this.source) === null || e === void 0 ? void 0 : e.subscribe(t);
952
+ }, s.prototype[He] = function() {
953
+ return this;
954
+ }, s.prototype.pipe = function() {
955
+ for (var t = [], e = 0; e < arguments.length; e++)
956
+ t[e] = arguments[e];
957
+ return De(t)(this);
958
+ }, s.prototype.toPromise = function(t) {
959
+ var e = this;
960
+ return t = Ht(t), new t(function(i, r) {
961
+ var n;
962
+ e.subscribe(function(o) {
963
+ return n = o;
964
+ }, function(o) {
965
+ return r(o);
966
+ }, function() {
967
+ return i(n);
968
+ });
969
+ });
970
+ }, s.create = function(t) {
971
+ return new s(t);
972
+ }, s;
973
+ }();
974
+ function Ht(s) {
975
+ var t;
976
+ return (t = s ?? re.Promise) !== null && t !== void 0 ? t : Promise;
977
+ }
978
+ function Be(s) {
979
+ return s && y(s.next) && y(s.error) && y(s.complete);
980
+ }
981
+ function ze(s) {
982
+ return s && s instanceof ne || Be(s) && se(s);
983
+ }
984
+ var Fe = ee(function(s) {
985
+ return function() {
986
+ s(this), this.name = "ObjectUnsubscribedError", this.message = "object unsubscribed";
987
+ };
988
+ }), yt = function(s) {
989
+ D(t, s);
990
+ function t() {
991
+ var e = s.call(this) || this;
992
+ return e.closed = !1, e.currentObservers = null, e.observers = [], e.isStopped = !1, e.hasError = !1, e.thrownError = null, e;
993
+ }
994
+ return t.prototype.lift = function(e) {
995
+ var i = new It(this, this);
996
+ return i.operator = e, i;
997
+ }, t.prototype._throwIfClosed = function() {
998
+ if (this.closed)
999
+ throw new Fe();
1000
+ }, t.prototype.next = function(e) {
1001
+ var i = this;
1002
+ V(function() {
1003
+ var r, n;
1004
+ if (i._throwIfClosed(), !i.isStopped) {
1005
+ i.currentObservers || (i.currentObservers = Array.from(i.observers));
1006
+ try {
1007
+ for (var o = pt(i.currentObservers), a = o.next(); !a.done; a = o.next()) {
1008
+ var c = a.value;
1009
+ c.next(e);
1010
+ }
1011
+ } catch (l) {
1012
+ r = { error: l };
1013
+ } finally {
1014
+ try {
1015
+ a && !a.done && (n = o.return) && n.call(o);
1016
+ } finally {
1017
+ if (r)
1018
+ throw r.error;
1019
+ }
1020
+ }
1021
+ }
1022
+ });
1023
+ }, t.prototype.error = function(e) {
1024
+ var i = this;
1025
+ V(function() {
1026
+ if (i._throwIfClosed(), !i.isStopped) {
1027
+ i.hasError = i.isStopped = !0, i.thrownError = e;
1028
+ for (var r = i.observers; r.length; )
1029
+ r.shift().error(e);
1030
+ }
1031
+ });
1032
+ }, t.prototype.complete = function() {
1033
+ var e = this;
1034
+ V(function() {
1035
+ if (e._throwIfClosed(), !e.isStopped) {
1036
+ e.isStopped = !0;
1037
+ for (var i = e.observers; i.length; )
1038
+ i.shift().complete();
1039
+ }
1040
+ });
1041
+ }, t.prototype.unsubscribe = function() {
1042
+ this.isStopped = this.closed = !0, this.observers = this.currentObservers = null;
1043
+ }, Object.defineProperty(t.prototype, "observed", {
1044
+ get: function() {
1045
+ var e;
1046
+ return ((e = this.observers) === null || e === void 0 ? void 0 : e.length) > 0;
1047
+ },
1048
+ enumerable: !1,
1049
+ configurable: !0
1050
+ }), t.prototype._trySubscribe = function(e) {
1051
+ return this._throwIfClosed(), s.prototype._trySubscribe.call(this, e);
1052
+ }, t.prototype._subscribe = function(e) {
1053
+ return this._throwIfClosed(), this._checkFinalizedStatuses(e), this._innerSubscribe(e);
1054
+ }, t.prototype._innerSubscribe = function(e) {
1055
+ var i = this, r = this, n = r.hasError, o = r.isStopped, a = r.observers;
1056
+ return n || o ? ie : (this.currentObservers = null, a.push(e), new Q(function() {
1057
+ i.currentObservers = null, ut(a, e);
1058
+ }));
1059
+ }, t.prototype._checkFinalizedStatuses = function(e) {
1060
+ var i = this, r = i.hasError, n = i.thrownError, o = i.isStopped;
1061
+ r ? e.error(n) : o && e.complete();
1062
+ }, t.prototype.asObservable = function() {
1063
+ var e = new Lt();
1064
+ return e.source = this, e;
1065
+ }, t.create = function(e, i) {
1066
+ return new It(e, i);
1067
+ }, t;
1068
+ }(Lt), It = function(s) {
1069
+ D(t, s);
1070
+ function t(e, i) {
1071
+ var r = s.call(this) || this;
1072
+ return r.destination = e, r.source = i, r;
1073
+ }
1074
+ return t.prototype.next = function(e) {
1075
+ var i, r;
1076
+ (r = (i = this.destination) === null || i === void 0 ? void 0 : i.next) === null || r === void 0 || r.call(i, e);
1077
+ }, t.prototype.error = function(e) {
1078
+ var i, r;
1079
+ (r = (i = this.destination) === null || i === void 0 ? void 0 : i.error) === null || r === void 0 || r.call(i, e);
1080
+ }, t.prototype.complete = function() {
1081
+ var e, i;
1082
+ (i = (e = this.destination) === null || e === void 0 ? void 0 : e.complete) === null || i === void 0 || i.call(e);
1083
+ }, t.prototype._subscribe = function(e) {
1084
+ var i, r;
1085
+ return (r = (i = this.source) === null || i === void 0 ? void 0 : i.subscribe(e)) !== null && r !== void 0 ? r : ie;
1086
+ }, t;
1087
+ }(yt), Ye = function(s) {
1088
+ D(t, s);
1089
+ function t(e) {
1090
+ var i = s.call(this) || this;
1091
+ return i._value = e, i;
1092
+ }
1093
+ return Object.defineProperty(t.prototype, "value", {
1094
+ get: function() {
1095
+ return this.getValue();
1096
+ },
1097
+ enumerable: !1,
1098
+ configurable: !0
1099
+ }), t.prototype._subscribe = function(e) {
1100
+ var i = s.prototype._subscribe.call(this, e);
1101
+ return !i.closed && e.next(this._value), i;
1102
+ }, t.prototype.getValue = function() {
1103
+ var e = this, i = e.hasError, r = e.thrownError, n = e._value;
1104
+ if (i)
1105
+ throw r;
1106
+ return this._throwIfClosed(), n;
1107
+ }, t.prototype.next = function(e) {
1108
+ s.prototype.next.call(this, this._value = e);
1109
+ }, t;
1110
+ }(yt);
1111
+ /**
1112
+ * @license
1113
+ * Copyright 2017 Google LLC
1114
+ * SPDX-License-Identifier: BSD-3-Clause
1115
+ */
1116
+ const We = { attribute: !0, type: String, converter: q, reflect: !1, hasChanged: mt }, Ve = (s = We, t, e) => {
1117
+ const { kind: i, metadata: r } = e;
1118
+ let n = globalThis.litPropertyMetadata.get(r);
1119
+ if (n === void 0 && globalThis.litPropertyMetadata.set(r, n = /* @__PURE__ */ new Map()), n.set(e.name, s), i === "accessor") {
1120
+ const { name: o } = e;
1121
+ return { set(a) {
1122
+ const c = t.get.call(this);
1123
+ t.set.call(this, a), this.requestUpdate(o, c, s);
1124
+ }, init(a) {
1125
+ return a !== void 0 && this.P(o, void 0, s), a;
1126
+ } };
1127
+ }
1128
+ if (i === "setter") {
1129
+ const { name: o } = e;
1130
+ return function(a) {
1131
+ const c = this[o];
1132
+ t.call(this, a), this.requestUpdate(o, c, s);
1133
+ };
1134
+ }
1135
+ throw Error("Unsupported decorator location: " + i);
1136
+ };
1137
+ function g(s) {
1138
+ return (t, e) => typeof e == "object" ? Ve(s, t, e) : ((i, r, n) => {
1139
+ const o = r.hasOwnProperty(n);
1140
+ return r.constructor.createProperty(n, o ? { ...i, wrapped: !0 } : i), o ? Object.getOwnPropertyDescriptor(r, n) : void 0;
1141
+ })(s, t, e);
1142
+ }
1143
+ /**
1144
+ * @license
1145
+ * Copyright 2017 Google LLC
1146
+ * SPDX-License-Identifier: BSD-3-Clause
1147
+ */
1148
+ function B(s) {
1149
+ return g({ ...s, state: !0, attribute: !1 });
1150
+ }
1151
+ var qe = Object.defineProperty, Ze = Object.getOwnPropertyDescriptor, Ke = (s, t, e, i) => {
1152
+ for (var r = i > 1 ? void 0 : i ? Ze(t, e) : t, n = s.length - 1, o; n >= 0; n--)
1153
+ (o = s[n]) && (r = (i ? o(t, e, r) : o(r)) || r);
1154
+ return i && r && qe(t, e, r), r;
1155
+ };
1156
+ class bt extends m {
1157
+ constructor() {
1158
+ super(...arguments), this.anchor = "BottomRight";
1159
+ }
1160
+ appendChild(t) {
1161
+ var e;
1162
+ return (e = this.shadowRoot) == null || e.appendChild(t), t;
1163
+ }
1164
+ render() {
1165
+ return this.anchor === "BottomLeft" ? this.renderRoot.host.classList.add("bottom-left") : this.anchor === "BottomRight" && this.renderRoot.host.classList.add("bottom-right"), u;
1166
+ }
1167
+ }
1168
+ bt.styles = [
1169
+ E`
1170
+ :host {
1171
+ position: fixed;
1172
+ display: flex;
1173
+ align-items: center;
1174
+ gap: 1rem;
1175
+ }
1176
+
1177
+ :host(.bottom-right) {
1178
+ bottom: 20px;
1179
+ right: 20px;
1180
+ }
1181
+ :host(.bottom-left) {
1182
+ bottom: 20px;
1183
+ left: 20px;
1184
+ }
1185
+ `
1186
+ ];
1187
+ Ke([
1188
+ g({ attribute: !0 })
1189
+ ], bt.prototype, "anchor", 2);
1190
+ /**
1191
+ * @license
1192
+ * Copyright 2017 Google LLC
1193
+ * SPDX-License-Identifier: BSD-3-Clause
1194
+ */
1195
+ const $t = { ATTRIBUTE: 1, CHILD: 2, PROPERTY: 3, BOOLEAN_ATTRIBUTE: 4, EVENT: 5, ELEMENT: 6 }, _t = (s) => (...t) => ({ _$litDirective$: s, values: t });
1196
+ let oe = class {
1197
+ constructor(t) {
1198
+ }
1199
+ get _$AU() {
1200
+ return this._$AM._$AU;
1201
+ }
1202
+ _$AT(t, e, i) {
1203
+ this._$Ct = t, this._$AM = e, this._$Ci = i;
1204
+ }
1205
+ _$AS(t, e) {
1206
+ return this.update(t, e);
1207
+ }
1208
+ update(t, e) {
1209
+ return this.render(...e);
1210
+ }
1211
+ };
1212
+ /**
1213
+ * @license
1214
+ * Copyright 2020 Google LLC
1215
+ * SPDX-License-Identifier: BSD-3-Clause
1216
+ */
1217
+ const Ge = (s) => s.strings === void 0;
1218
+ /**
1219
+ * @license
1220
+ * Copyright 2017 Google LLC
1221
+ * SPDX-License-Identifier: BSD-3-Clause
1222
+ */
1223
+ const M = (s, t) => {
1224
+ var i;
1225
+ const e = s._$AN;
1226
+ if (e === void 0)
1227
+ return !1;
1228
+ for (const r of e)
1229
+ (i = r._$AO) == null || i.call(r, t, !1), M(r, t);
1230
+ return !0;
1231
+ }, X = (s) => {
1232
+ let t, e;
1233
+ do {
1234
+ if ((t = s._$AM) === void 0)
1235
+ break;
1236
+ e = t._$AN, e.delete(s), s = t;
1237
+ } while ((e == null ? void 0 : e.size) === 0);
1238
+ }, ae = (s) => {
1239
+ for (let t; t = s._$AM; s = t) {
1240
+ let e = t._$AN;
1241
+ if (e === void 0)
1242
+ t._$AN = e = /* @__PURE__ */ new Set();
1243
+ else if (e.has(s))
1244
+ break;
1245
+ e.add(s), Qe(t);
1246
+ }
1247
+ };
1248
+ function Xe(s) {
1249
+ this._$AN !== void 0 ? (X(this), this._$AM = s, ae(this)) : this._$AM = s;
1250
+ }
1251
+ function Je(s, t = !1, e = 0) {
1252
+ const i = this._$AH, r = this._$AN;
1253
+ if (r !== void 0 && r.size !== 0)
1254
+ if (t)
1255
+ if (Array.isArray(i))
1256
+ for (let n = e; n < i.length; n++)
1257
+ M(i[n], !1), X(i[n]);
1258
+ else
1259
+ i != null && (M(i, !1), X(i));
1260
+ else
1261
+ M(this, s);
1262
+ }
1263
+ const Qe = (s) => {
1264
+ s.type == $t.CHILD && (s._$AP ?? (s._$AP = Je), s._$AQ ?? (s._$AQ = Xe));
1265
+ };
1266
+ class ce extends oe {
1267
+ constructor() {
1268
+ super(...arguments), this._$AN = void 0;
1269
+ }
1270
+ _$AT(t, e, i) {
1271
+ super._$AT(t, e, i), ae(this), this.isConnected = t._$AU;
1272
+ }
1273
+ _$AO(t, e = !0) {
1274
+ var i, r;
1275
+ t !== this.isConnected && (this.isConnected = t, t ? (i = this.reconnected) == null || i.call(this) : (r = this.disconnected) == null || r.call(this)), e && (M(this, t), X(this));
1276
+ }
1277
+ setValue(t) {
1278
+ if (Ge(this._$Ct))
1279
+ this._$Ct._$AI(t, this);
1280
+ else {
1281
+ const e = [...this._$Ct._$AH];
1282
+ e[this._$Ci] = t, this._$Ct._$AI(e, this, 0);
1283
+ }
1284
+ }
1285
+ disconnected() {
1286
+ }
1287
+ reconnected() {
1288
+ }
1289
+ }
1290
+ const ti = /* @__PURE__ */ new WeakMap();
1291
+ let Dt = 0;
1292
+ const at = /* @__PURE__ */ new Map(), Bt = /* @__PURE__ */ new WeakSet(), zt = () => new Promise((s) => requestAnimationFrame(s)), ei = [{ transform: "translateX(100%) scale(0)", opacity: 0 }], Ft = (s, t) => {
1293
+ const e = s - t;
1294
+ return e === 0 ? void 0 : e;
1295
+ }, Yt = (s, t) => {
1296
+ const e = s / t;
1297
+ return e === 1 ? void 0 : e;
1298
+ }, ct = { left: (s, t) => {
1299
+ const e = Ft(s, t);
1300
+ return { value: e, transform: e == null || isNaN(e) ? void 0 : `translateX(${e}px)` };
1301
+ }, top: (s, t) => {
1302
+ const e = Ft(s, t);
1303
+ return { value: e, transform: e == null || isNaN(e) ? void 0 : `translateY(${e}px)` };
1304
+ }, width: (s, t) => {
1305
+ let e;
1306
+ t === 0 && (t = 1, e = { width: "1px" });
1307
+ const i = Yt(s, t);
1308
+ return { value: i, overrideFrom: e, transform: i == null || isNaN(i) ? void 0 : `scaleX(${i})` };
1309
+ }, height: (s, t) => {
1310
+ let e;
1311
+ t === 0 && (t = 1, e = { height: "1px" });
1312
+ const i = Yt(s, t);
1313
+ return { value: i, overrideFrom: e, transform: i == null || isNaN(i) ? void 0 : `scaleY(${i})` };
1314
+ } }, ii = { duration: 333, easing: "ease-in-out" }, si = ["left", "top", "width", "height", "opacity", "color", "background"], Wt = /* @__PURE__ */ new WeakMap();
1315
+ class ri extends ce {
1316
+ constructor(t) {
1317
+ if (super(t), this.t = !1, this.i = null, this.o = null, this.h = !0, this.shouldLog = !1, t.type === $t.CHILD)
1318
+ throw Error("The `animate` directive must be used in attribute position.");
1319
+ this.createFinished();
1320
+ }
1321
+ createFinished() {
1322
+ var t;
1323
+ (t = this.resolveFinished) == null || t.call(this), this.finished = new Promise((e) => {
1324
+ this.l = e;
1325
+ });
1326
+ }
1327
+ async resolveFinished() {
1328
+ var t;
1329
+ (t = this.l) == null || t.call(this), this.l = void 0;
1330
+ }
1331
+ render(t) {
1332
+ return u;
1333
+ }
1334
+ getController() {
1335
+ return ti.get(this.u);
1336
+ }
1337
+ isDisabled() {
1338
+ var t;
1339
+ return this.options.disabled || ((t = this.getController()) == null ? void 0 : t.disabled);
1340
+ }
1341
+ update(t, [e]) {
1342
+ var r;
1343
+ const i = this.u === void 0;
1344
+ return i && (this.u = (r = t.options) == null ? void 0 : r.host, this.u.addController(this), this.u.updateComplete.then((n) => this.t = !0), this.element = t.element, Wt.set(this.element, this)), this.optionsOrCallback = e, (i || typeof e != "function") && this.p(e), this.render(e);
1345
+ }
1346
+ p(t) {
1347
+ t = t ?? {};
1348
+ const e = this.getController();
1349
+ e !== void 0 && ((t = { ...e.defaultOptions, ...t }).keyframeOptions = { ...e.defaultOptions.keyframeOptions, ...t.keyframeOptions }), t.properties ?? (t.properties = si), this.options = t;
1350
+ }
1351
+ m() {
1352
+ const t = {}, e = this.element.getBoundingClientRect(), i = getComputedStyle(this.element);
1353
+ return this.options.properties.forEach((r) => {
1354
+ const n = e[r] ?? (ct[r] ? void 0 : i[r]), o = Number(n);
1355
+ t[r] = isNaN(o) ? n + "" : o;
1356
+ }), t;
1357
+ }
1358
+ v() {
1359
+ let t, e = !0;
1360
+ return this.options.guard && (t = this.options.guard(), e = ((i, r) => {
1361
+ if (Array.isArray(i)) {
1362
+ if (Array.isArray(r) && r.length === i.length && i.every((n, o) => n === r[o]))
1363
+ return !1;
1364
+ } else if (r === i)
1365
+ return !1;
1366
+ return !0;
1367
+ })(t, this._)), this.h = this.t && !this.isDisabled() && !this.isAnimating() && e && this.element.isConnected, this.h && (this._ = Array.isArray(t) ? Array.from(t) : t), this.h;
1368
+ }
1369
+ hostUpdate() {
1370
+ typeof this.optionsOrCallback == "function" && this.p(this.optionsOrCallback()), this.v() && (this.A = this.m(), this.i = this.i ?? this.element.parentNode, this.o = this.element.nextSibling);
1371
+ }
1372
+ async hostUpdated() {
1373
+ if (!this.h || !this.element.isConnected || this.options.skipInitial && !this.isHostRendered)
1374
+ return;
1375
+ let t;
1376
+ this.prepare(), await zt;
1377
+ const e = this.O(), i = this.j(this.options.keyframeOptions, e), r = this.m();
1378
+ if (this.A !== void 0) {
1379
+ const { from: n, to: o } = this.N(this.A, r, e);
1380
+ this.log("measured", [this.A, r, n, o]), t = this.calculateKeyframes(n, o);
1381
+ } else {
1382
+ const n = at.get(this.options.inId);
1383
+ if (n) {
1384
+ at.delete(this.options.inId);
1385
+ const { from: o, to: a } = this.N(n, r, e);
1386
+ t = this.calculateKeyframes(o, a), t = this.options.in ? [{ ...this.options.in[0], ...t[0] }, ...this.options.in.slice(1), t[1]] : t, Dt++, t.forEach((c) => c.zIndex = Dt);
1387
+ } else
1388
+ this.options.in && (t = [...this.options.in, {}]);
1389
+ }
1390
+ this.animate(t, i);
1391
+ }
1392
+ resetStyles() {
1393
+ this.P !== void 0 && (this.element.setAttribute("style", this.P ?? ""), this.P = void 0);
1394
+ }
1395
+ commitStyles() {
1396
+ var t, e;
1397
+ this.P = this.element.getAttribute("style"), (t = this.webAnimation) == null || t.commitStyles(), (e = this.webAnimation) == null || e.cancel();
1398
+ }
1399
+ reconnected() {
1400
+ }
1401
+ async disconnected() {
1402
+ var e;
1403
+ if (!this.h || (this.options.id !== void 0 && at.set(this.options.id, this.A), this.options.out === void 0))
1404
+ return;
1405
+ if (this.prepare(), await zt(), (e = this.i) == null ? void 0 : e.isConnected) {
1406
+ const i = this.o && this.o.parentNode === this.i ? this.o : null;
1407
+ if (this.i.insertBefore(this.element, i), this.options.stabilizeOut) {
1408
+ const r = this.m();
1409
+ this.log("stabilizing out");
1410
+ const n = this.A.left - r.left, o = this.A.top - r.top;
1411
+ getComputedStyle(this.element).position !== "static" || n === 0 && o === 0 || (this.element.style.position = "relative"), n !== 0 && (this.element.style.left = n + "px"), o !== 0 && (this.element.style.top = o + "px");
1412
+ }
1413
+ }
1414
+ const t = this.j(this.options.keyframeOptions);
1415
+ await this.animate(this.options.out, t), this.element.remove();
1416
+ }
1417
+ prepare() {
1418
+ this.createFinished();
1419
+ }
1420
+ start() {
1421
+ var t, e;
1422
+ (e = (t = this.options).onStart) == null || e.call(t, this);
1423
+ }
1424
+ didFinish(t) {
1425
+ var e, i;
1426
+ t && ((i = (e = this.options).onComplete) == null || i.call(e, this)), this.A = void 0, this.animatingProperties = void 0, this.frames = void 0, this.resolveFinished();
1427
+ }
1428
+ O() {
1429
+ const t = [];
1430
+ for (let e = this.element.parentNode; e; e = e == null ? void 0 : e.parentNode) {
1431
+ const i = Wt.get(e);
1432
+ i && !i.isDisabled() && i && t.push(i);
1433
+ }
1434
+ return t;
1435
+ }
1436
+ get isHostRendered() {
1437
+ const t = Bt.has(this.u);
1438
+ return t || this.u.updateComplete.then(() => {
1439
+ Bt.add(this.u);
1440
+ }), t;
1441
+ }
1442
+ j(t, e = this.O()) {
1443
+ const i = { ...ii };
1444
+ return e.forEach((r) => Object.assign(i, r.options.keyframeOptions)), Object.assign(i, t), i;
1445
+ }
1446
+ N(t, e, i) {
1447
+ t = { ...t }, e = { ...e };
1448
+ const r = i.map((a) => a.animatingProperties).filter((a) => a !== void 0);
1449
+ let n = 1, o = 1;
1450
+ return r.length > 0 && (r.forEach((a) => {
1451
+ a.width && (n /= a.width), a.height && (o /= a.height);
1452
+ }), t.left !== void 0 && e.left !== void 0 && (t.left = n * t.left, e.left = n * e.left), t.top !== void 0 && e.top !== void 0 && (t.top = o * t.top, e.top = o * e.top)), { from: t, to: e };
1453
+ }
1454
+ calculateKeyframes(t, e, i = !1) {
1455
+ const r = {}, n = {};
1456
+ let o = !1;
1457
+ const a = {};
1458
+ for (const c in e) {
1459
+ const l = t[c], h = e[c];
1460
+ if (c in ct) {
1461
+ const p = ct[c];
1462
+ if (l === void 0 || h === void 0)
1463
+ continue;
1464
+ const d = p(l, h);
1465
+ d.transform !== void 0 && (a[c] = d.value, o = !0, r.transform = `${r.transform ?? ""} ${d.transform}`, d.overrideFrom !== void 0 && Object.assign(r, d.overrideFrom));
1466
+ } else
1467
+ l !== h && l !== void 0 && h !== void 0 && (o = !0, r[c] = l, n[c] = h);
1468
+ }
1469
+ return r.transformOrigin = n.transformOrigin = i ? "center center" : "top left", this.animatingProperties = a, o ? [r, n] : void 0;
1470
+ }
1471
+ async animate(t, e = this.options.keyframeOptions) {
1472
+ this.start(), this.frames = t;
1473
+ let i = !1;
1474
+ if (!this.isAnimating() && !this.isDisabled() && (this.options.onFrames && (this.frames = t = this.options.onFrames(this), this.log("modified frames", t)), t !== void 0)) {
1475
+ this.log("animate", [t, e]), i = !0, this.webAnimation = this.element.animate(t, e);
1476
+ const r = this.getController();
1477
+ r == null || r.add(this);
1478
+ try {
1479
+ await this.webAnimation.finished;
1480
+ } catch {
1481
+ }
1482
+ r == null || r.remove(this);
1483
+ }
1484
+ return this.didFinish(i), i;
1485
+ }
1486
+ isAnimating() {
1487
+ var t, e;
1488
+ return ((t = this.webAnimation) == null ? void 0 : t.playState) === "running" || ((e = this.webAnimation) == null ? void 0 : e.pending);
1489
+ }
1490
+ log(t, e) {
1491
+ this.shouldLog && !this.isDisabled() && console.log(t, this.options.id, e);
1492
+ }
1493
+ }
1494
+ const ni = _t(ri), oi = { name: "question", svg: '<svg viewBox="0 0 64 64" xmlns="http://www.w3.org/2000/svg" fill="currentColor"><path fill-rule="evenodd" clip-rule="evenodd" d="M32 4C16.536 4 4 16.536 4 32C4 47.464 16.536 60 32 60C47.464 60 60 47.464 60 32C59.9827 16.5432 47.4568 4.01731 32 4ZM32 55.6923C18.9151 55.6923 8.30769 45.0849 8.30769 32C8.30769 18.9151 18.9151 8.30769 32 8.30769C45.0849 8.30769 55.6923 18.9151 55.6923 32C55.6775 45.0788 45.0788 55.6775 32 55.6923Z"/><path fill-rule="evenodd" clip-rule="evenodd" d="M31.9423 37.5723L36.311 32.9068L36.7354 32.4448C39.7555 29.1161 40.7645 27.0647 40.7645 24.5087C40.7645 23.1091 40.4251 21.7942 39.7041 20.6491C38.3044 18.3587 35.6323 16.9166 32.2816 16.9166C28.7565 16.9166 25.3125 18.7414 23.2581 21.6772L23.1201 21.8791C22.8232 22.3032 22.696 22.6849 22.696 22.9818C22.696 23.7029 23.926 25.9932 25.2833 25.9932C25.5378 25.9932 25.7922 25.9084 26.0467 25.7388C26.2588 25.5691 26.5981 25.2298 27.0647 24.7208C28.8885 22.6849 30.1185 21.9215 31.7726 21.9215C33.6813 21.9215 35.081 23.1939 35.081 24.8905C35.081 26.375 34.2751 27.7746 32.3664 29.8529L28.2523 34.2216C27.9554 34.6033 27.7857 34.9426 27.7857 35.282C27.7857 35.6213 27.9978 36.1726 28.4219 36.8937C29.0581 37.8692 29.7368 38.3782 30.4578 38.3782C30.9244 38.3782 31.3909 38.1237 31.9423 37.5723ZM30.882 47.4972C29.2278 47.4972 27.6585 44.7403 27.6585 43.6799C27.6585 42.1954 30.0761 40.6261 32.4089 40.6261C33.6389 40.6261 34.2751 41.1775 34.2751 42.3227C34.2751 44.0616 33.4692 45.843 32.4513 46.7761C31.9423 47.2427 31.4334 47.4972 30.882 47.4972Z"/></svg>' };
1495
+ /**
1496
+ * @license
1497
+ * Copyright 2018 Google LLC
1498
+ * SPDX-License-Identifier: BSD-3-Clause
1499
+ */
1500
+ const ai = _t(class extends oe {
1501
+ constructor(s) {
1502
+ var t;
1503
+ if (super(s), s.type !== $t.ATTRIBUTE || s.name !== "class" || ((t = s.strings) == null ? void 0 : t.length) > 2)
1504
+ throw Error("`classMap()` can only be used in the `class` attribute and must be the only part in the attribute.");
1505
+ }
1506
+ render(s) {
1507
+ return " " + Object.keys(s).filter((t) => s[t]).join(" ") + " ";
1508
+ }
1509
+ update(s, [t]) {
1510
+ var i, r;
1511
+ if (this.st === void 0) {
1512
+ this.st = /* @__PURE__ */ new Set(), s.strings !== void 0 && (this.nt = new Set(s.strings.join(" ").split(/\s/).filter((n) => n !== "")));
1513
+ for (const n in t)
1514
+ t[n] && !((i = this.nt) != null && i.has(n)) && this.st.add(n);
1515
+ return this.render(t);
1516
+ }
1517
+ const e = s.element.classList;
1518
+ for (const n of this.st)
1519
+ n in t || (e.remove(n), this.st.delete(n));
1520
+ for (const n in t) {
1521
+ const o = !!t[n];
1522
+ o === this.st.has(n) || (r = this.nt) != null && r.has(n) || (o ? (e.add(n), this.st.add(n)) : (e.remove(n), this.st.delete(n)));
1523
+ }
1524
+ return S;
1525
+ }
1526
+ }), Y = (s, t, e) => {
1527
+ s && e.style.setProperty(t, s);
1528
+ }, le = (s, t) => {
1529
+ var e, i, r, n;
1530
+ Y((e = s.colors) == null ? void 0 : e.primaryBackground, "--primary-background", t), Y(
1531
+ (i = s.colors) == null ? void 0 : i.textOnPrimaryBackground,
1532
+ "--text-on-primary-background",
1533
+ t
1534
+ ), Y(
1535
+ (r = s.colors) == null ? void 0 : r.secondaryBackground,
1536
+ "--secondary-background",
1537
+ t
1538
+ ), Y(
1539
+ (n = s.colors) == null ? void 0 : n.textOnSecondaryBackground,
1540
+ "--text-on-secondary-background",
1541
+ t
1542
+ );
1543
+ };
1544
+ /**
1545
+ * @license
1546
+ * Copyright 2020 Google LLC
1547
+ * SPDX-License-Identifier: BSD-3-Clause
1548
+ */
1549
+ const he = () => new ci();
1550
+ class ci {
1551
+ }
1552
+ const lt = /* @__PURE__ */ new WeakMap(), pe = _t(class extends ce {
1553
+ render(s) {
1554
+ return u;
1555
+ }
1556
+ update(s, [t]) {
1557
+ var i;
1558
+ const e = t !== this.Y;
1559
+ return e && this.Y !== void 0 && this.rt(void 0), (e || this.lt !== this.ct) && (this.Y = t, this.ht = (i = s.options) == null ? void 0 : i.host, this.rt(this.ct = s.element)), u;
1560
+ }
1561
+ rt(s) {
1562
+ if (typeof this.Y == "function") {
1563
+ const t = this.ht ?? globalThis;
1564
+ let e = lt.get(t);
1565
+ e === void 0 && (e = /* @__PURE__ */ new WeakMap(), lt.set(t, e)), e.get(this.Y) !== void 0 && this.Y.call(this.ht, void 0), e.set(this.Y, s), s !== void 0 && this.Y.call(this.ht, s);
1566
+ } else
1567
+ this.Y.value = s;
1568
+ }
1569
+ get lt() {
1570
+ var s, t;
1571
+ return typeof this.Y == "function" ? (s = lt.get(this.ht ?? globalThis)) == null ? void 0 : s.get(this.Y) : (t = this.Y) == null ? void 0 : t.value;
1572
+ }
1573
+ disconnected() {
1574
+ this.lt === this.ct && this.rt(void 0);
1575
+ }
1576
+ reconnected() {
1577
+ this.rt(this.ct);
1578
+ }
1579
+ });
1580
+ var li = Object.defineProperty, hi = Object.getOwnPropertyDescriptor, tt = (s, t, e, i) => {
1581
+ for (var r = i > 1 ? void 0 : i ? hi(t, e) : t, n = s.length - 1, o; n >= 0; n--)
1582
+ (o = s[n]) && (r = (i ? o(t, e, r) : o(r)) || r);
1583
+ return i && r && li(t, e, r), r;
1584
+ };
1585
+ class P extends m {
1586
+ constructor() {
1587
+ super(...arguments), this.active = !1, this.loaded = !1, this.containerRef = he(), this.widgetActive$ = new Ye(!1), this.componentIsDestroyed$ = new yt();
1588
+ }
1589
+ async connectedCallback() {
1590
+ super.connectedCallback(), this.icon = await this._renderSymbol(), this.loaded = !0, this._applyBranding();
1591
+ }
1592
+ disconnectedCallback() {
1593
+ super.disconnectedCallback(), this.componentIsDestroyed$.next(), this.componentIsDestroyed$.complete();
1594
+ }
1595
+ toggleActive() {
1596
+ var t;
1597
+ if (!((t = this.application) != null && t.root)) {
1598
+ console.warn(
1599
+ "Could not activate widget. No root element assigned to widget."
1600
+ );
1601
+ return;
1602
+ }
1603
+ this.active = !this.active, this.active ? (this.application.appendToDOM(), this.widgetActive$.next(!0)) : (this.application.hide(), this.widgetActive$.next(!1));
1604
+ }
1605
+ _applyBranding() {
1606
+ var t;
1607
+ (t = this.application) != null && t.settings && le(this.application.settings.branding, this);
1608
+ }
1609
+ async _renderSymbol() {
1610
+ var a, c, l;
1611
+ const t = (a = this.application) == null ? void 0 : a.branding(), e = (c = t == null ? void 0 : t.graphics) == null ? void 0 : c.trigger;
1612
+ if (e)
1613
+ return A` <img src=${e} class="trigger-icon" alt="" /> `;
1614
+ const i = (l = this.application) == null ? void 0 : l.triggerIcon;
1615
+ if (!i)
1616
+ return u;
1617
+ const r = async (h) => oi, { type: n, content: o } = i;
1618
+ switch (n) {
1619
+ case "Telia": {
1620
+ const h = await r();
1621
+ return h ? A`<telia-icon
1622
+ class="trigger-icon"
1623
+ svg=${h.svg}
1624
+ size="lg"
1625
+ ></telia-icon>` : u;
1626
+ }
1627
+ default:
1628
+ return u;
1629
+ }
1630
+ }
1631
+ render() {
1632
+ var t, e, i, r;
1633
+ return A`<div class="trigger-container" ${pe(this.containerRef)}>
1634
+ ${!this.active && ((r = (i = (e = (t = this.application) == null ? void 0 : t.settings) == null ? void 0 : e.branding) == null ? void 0 : i.other) != null && r.showButtonLabel) ? A`
1635
+ <button
1636
+ label="${this.application.settings.branding.other.buttonLabelText ?? "Widget trigger"}"
1637
+ class="trigger-label"
1638
+ @click=${this.toggleActive}
1639
+ ${ni({
1640
+ keyframeOptions: {},
1641
+ in: ei,
1642
+ stabilizeOut: !0,
1643
+ skipInitial: !1
1644
+ })}
1645
+ >
1646
+ ${this.application.settings.branding.other.buttonLabelText}
1647
+ </button>
1648
+ ` : u}
1649
+
1650
+ <button
1651
+ label="Widget trigger"
1652
+ class=${ai({
1653
+ trigger: !0,
1654
+ active: this.active,
1655
+ rendered: this.loaded
1656
+ })}
1657
+ @click=${this.toggleActive}
1658
+ >
1659
+ ${this.icon}
1660
+ <span class="trigger-close">
1661
+ <svg
1662
+ width="18"
1663
+ height="9"
1664
+ viewBox="0 0 18 9"
1665
+ fill="none"
1666
+ xmlns="http://www.w3.org/2000/svg"
1667
+ >
1668
+ <path
1669
+ d="M9 9C8.81794 9.00045 8.63759 8.96634 8.46939 8.89965C8.3012 8.83295 8.14851 8.735 8.02015 8.61145L0.194523 1.12367C0.068294 0.99862 -0.00155266 0.831133 2.61958e-05 0.657285C0.00160506 0.483436 0.0744832 0.317136 0.202964 0.194202C0.331445 0.0712675 0.505249 0.00153576 0.686941 2.50649e-05C0.868634 -0.00148563 1.04368 0.0653456 1.17437 0.186125L9 7.6739L16.8256 0.186125C16.9563 0.0653456 17.1314 -0.00148563 17.3131 2.50649e-05C17.4948 0.00153576 17.6686 0.0712675 17.797 0.194202C17.9255 0.317136 17.9984 0.483436 18 0.657285C18.0016 0.831133 17.9317 0.99862 17.8055 1.12367L9.97985 8.61145C9.85149 8.735 9.6988 8.83295 9.53061 8.89965C9.36241 8.96634 9.18206 9.00045 9 9Z"
1670
+ fill="white"
1671
+ />
1672
+ </svg>
1673
+ </span>
1674
+ <span class="trigger-loader">
1675
+ <svg viewBox="25 25 50 50">
1676
+ <circle
1677
+ cx="50"
1678
+ cy="50"
1679
+ r="20"
1680
+ fill="none"
1681
+ stroke="#000"
1682
+ stroke-width="2"
1683
+ stroke-miterlimit="10"
1684
+ />
1685
+ </svg>
1686
+ </span>
1687
+ </button>
1688
+ </div>`;
1689
+ }
1690
+ }
1691
+ P.styles = [
1692
+ E`
1693
+ :host {
1694
+ --voca-rem-multiplier: 0.625;
1695
+ --trigger-label-bg: #f5e0ff;
1696
+ --trigger-label-text-color: rgba(0, 0, 0, 0.8);
1697
+ display: block;
1698
+ box-sizing: border-box;
1699
+ /* font-family: var(--font-family); */
1700
+ font-family: TeliaSans, Helvetica, Arial, Lucida Grande, sans-serif;
1701
+ }
1702
+
1703
+ .trigger-container {
1704
+ display: flex;
1705
+ align-items: center;
1706
+ gap: 1rem;
1707
+ }
1708
+
1709
+ .trigger {
1710
+ transform: scale(0);
1711
+ box-shadow: rgba(0, 0, 0, 0.16) 0px 5px 40px;
1712
+ z-index: 5;
1713
+ display: flex;
1714
+ align-items: center;
1715
+ justify-content: center;
1716
+ border: none;
1717
+ line-height: 55px;
1718
+ height: 55px;
1719
+ width: 55px;
1720
+ border-radius: 55px;
1721
+ cursor: pointer;
1722
+ background-color: var(--trigger-bg, var(--primary-background));
1723
+ font-family: Lato;
1724
+ text-decoration: none;
1725
+ border: 3px dashed transparent;
1726
+ box-sizing: border-box;
1727
+ transition: transform 200ms ease-out;
1728
+ }
1729
+ .trigger:active {
1730
+ transform: scale(0.8) !important;
1731
+ }
1732
+ .trigger:hover:not(:active) {
1733
+ transform: scale(1.1) !important;
1734
+ }
1735
+ .trigger.rendered {
1736
+ transform: scale(1);
1737
+ }
1738
+ .trigger.active .trigger-icon {
1739
+ opacity: 0;
1740
+ transform: rotate(-180deg) scale(0);
1741
+ }
1742
+ .trigger.active .trigger-close {
1743
+ opacity: 1;
1744
+ transform: rotate(0deg) scale(1);
1745
+ }
1746
+
1747
+ .trigger-icon {
1748
+ display: inline-block;
1749
+ line-height: inherit;
1750
+ text-align: center;
1751
+ opacity: 1;
1752
+ transform: rotate(0deg) scale(1);
1753
+ transition: opacity 200ms ease-out, transform 200ms ease-out;
1754
+ color: var(--trigger-text-color, var(--text-on-primary-background));
1755
+ }
1756
+ .trigger-close {
1757
+ opacity: 0;
1758
+ transition: transform 200ms ease-out;
1759
+ transform: rotate(180deg) scale(0);
1760
+ position: absolute;
1761
+ top: 0;
1762
+ bottom: 0;
1763
+ left: 0;
1764
+ right: 0;
1765
+ display: flex;
1766
+ justify-content: center;
1767
+ align-items: center;
1768
+ }
1769
+ .trigger-close svg path {
1770
+ fill: var(--trigger-text-color, var(--text-on-primary-background));
1771
+ }
1772
+
1773
+ img {
1774
+ max-width: 100%;
1775
+ }
1776
+
1777
+ .trigger-label {
1778
+ box-shadow: 0px 1px 4px 0px rgba(0, 0, 0, 0.1);
1779
+ background-color: var(--trigger-label-bg);
1780
+ color: var(--trigger-label-text-color);
1781
+ white-space: nowrap;
1782
+ padding: 0.7rem 1rem;
1783
+ border-radius: 0.3rem;
1784
+ font-weight: 500;
1785
+ display: flex;
1786
+ justify-content: center;
1787
+ align-items: center;
1788
+ cursor: pointer;
1789
+ border: none;
1790
+ font-size: 1rem;
1791
+ font-family: inherit;
1792
+ transition: all 300ms ease-in-out;
1793
+ }
1794
+
1795
+ .trigger-label:hover {
1796
+ opacity: 0.8;
1797
+ }
1798
+ `
1799
+ ];
1800
+ tt([
1801
+ g({ attribute: !1 })
1802
+ ], P.prototype, "application", 2);
1803
+ tt([
1804
+ B()
1805
+ ], P.prototype, "active", 2);
1806
+ tt([
1807
+ B()
1808
+ ], P.prototype, "loaded", 2);
1809
+ tt([
1810
+ B()
1811
+ ], P.prototype, "icon", 2);
1812
+ var pi = Object.defineProperty, ui = Object.getOwnPropertyDescriptor, w = (s, t, e, i) => {
1813
+ for (var r = i > 1 ? void 0 : i ? ui(t, e) : t, n = s.length - 1, o; n >= 0; n--)
1814
+ (o = s[n]) && (r = (i ? o(t, e, r) : o(r)) || r);
1815
+ return i && r && pi(t, e, r), r;
1816
+ };
1817
+ const ue = (s) => {
1818
+ class t extends s {
1819
+ constructor() {
1820
+ super(...arguments), this.properties = {}, this.context = {}, this.layout = {}, this.nodes = [];
1821
+ }
1822
+ writeProperties(i) {
1823
+ this.properties = i;
1824
+ }
1825
+ writeLayout(i) {
1826
+ this.layout = i;
1827
+ }
1828
+ writeContext(i) {
1829
+ this.context = i;
1830
+ }
1831
+ addChild(i) {
1832
+ i.parent = this, this.nodes.push(i);
1833
+ }
1834
+ connectedCallback() {
1835
+ super.connectedCallback(), this.renderRoot.host.style.setProperty(
1836
+ "--width",
1837
+ this.layout.size === "full" ? "var(--columns, 1)" : `min(${this.layout.size || "var(--columns)"}, var(--columns))`
1838
+ ), this.application.mountComponent(this);
1839
+ }
1840
+ }
1841
+ return t.styles = [
1842
+ // (superClass as unknown as typeof LitElement).styles ?? [],
1843
+ E`
1844
+ :host {
1845
+ font-family: var(--font-family);
1846
+ grid-column: span var(--width);
1847
+ max-width: 100%;
1848
+ overflow: hidden;
1849
+ box-sizing: border-box;
1850
+ display: block;
1851
+ }
1852
+ * {
1853
+ box-sizing: border-box;
1854
+ }
1855
+ `
1856
+ ], w([
1857
+ g()
1858
+ ], t.prototype, "properties", 2), w([
1859
+ g()
1860
+ ], t.prototype, "context", 2), w([
1861
+ g()
1862
+ ], t.prototype, "layout", 2), w([
1863
+ g()
1864
+ ], t.prototype, "name", 2), w([
1865
+ g()
1866
+ ], t.prototype, "type", 2), w([
1867
+ g({ attribute: !1 })
1868
+ ], t.prototype, "application", 2), w([
1869
+ g({ attribute: !1 })
1870
+ ], t.prototype, "parent", 2), t;
1871
+ };
1872
+ class de extends ue(m) {
1873
+ render() {
1874
+ return A`Non resolved component`;
1875
+ }
1876
+ }
1877
+ de.styles = [
1878
+ E`
1879
+ :host {
1880
+ display: block;
1881
+ }
1882
+ `
1883
+ ];
1884
+ var wt = /* @__PURE__ */ ((s) => (s.Inline = "inline", s.Trigger = "trigger", s))(wt || {});
1885
+ /**
1886
+ * @license
1887
+ * Copyright 2021 Google LLC
1888
+ * SPDX-License-Identifier: BSD-3-Clause
1889
+ */
1890
+ let di = class extends Event {
1891
+ constructor(t, e, i) {
1892
+ super("context-request", { bubbles: !0, composed: !0 }), this.context = t, this.callback = e, this.subscribe = i ?? !1;
1893
+ }
1894
+ };
1895
+ /**
1896
+ * @license
1897
+ * Copyright 2021 Google LLC
1898
+ * SPDX-License-Identifier: BSD-3-Clause
1899
+ */
1900
+ /**
1901
+ * @license
1902
+ * Copyright 2021 Google LLC
1903
+ * SPDX-License-Identifier: BSD-3-Clause
1904
+ */
1905
+ class fi {
1906
+ get value() {
1907
+ return this.o;
1908
+ }
1909
+ set value(t) {
1910
+ this.setValue(t);
1911
+ }
1912
+ setValue(t, e = !1) {
1913
+ const i = e || !Object.is(t, this.o);
1914
+ this.o = t, i && this.updateObservers();
1915
+ }
1916
+ constructor(t) {
1917
+ this.subscriptions = /* @__PURE__ */ new Map(), this.updateObservers = () => {
1918
+ for (const [e, { disposer: i }] of this.subscriptions)
1919
+ e(this.o, i);
1920
+ }, t !== void 0 && (this.value = t);
1921
+ }
1922
+ addCallback(t, e, i) {
1923
+ if (!i)
1924
+ return void t(this.value);
1925
+ this.subscriptions.has(t) || this.subscriptions.set(t, { disposer: () => {
1926
+ this.subscriptions.delete(t);
1927
+ }, consumerHost: e });
1928
+ const { disposer: r } = this.subscriptions.get(t);
1929
+ t(this.value, r);
1930
+ }
1931
+ clearCallbacks() {
1932
+ this.subscriptions.clear();
1933
+ }
1934
+ }
1935
+ /**
1936
+ * @license
1937
+ * Copyright 2021 Google LLC
1938
+ * SPDX-License-Identifier: BSD-3-Clause
1939
+ */
1940
+ let gi = class extends Event {
1941
+ constructor(t) {
1942
+ super("context-provider", { bubbles: !0, composed: !0 }), this.context = t;
1943
+ }
1944
+ };
1945
+ class Vt extends fi {
1946
+ constructor(t, e, i) {
1947
+ var r, n;
1948
+ super(e.context !== void 0 ? e.initialValue : i), this.onContextRequest = (o) => {
1949
+ const a = o.composedPath()[0];
1950
+ o.context === this.context && a !== this.host && (o.stopPropagation(), this.addCallback(o.callback, a, o.subscribe));
1951
+ }, this.onProviderRequest = (o) => {
1952
+ const a = o.composedPath()[0];
1953
+ if (o.context !== this.context || a === this.host)
1954
+ return;
1955
+ const c = /* @__PURE__ */ new Set();
1956
+ for (const [l, { consumerHost: h }] of this.subscriptions)
1957
+ c.has(l) || (c.add(l), h.dispatchEvent(new di(this.context, l, !0)));
1958
+ o.stopPropagation();
1959
+ }, this.host = t, e.context !== void 0 ? this.context = e.context : this.context = e, this.attachListeners(), (n = (r = this.host).addController) == null || n.call(r, this);
1960
+ }
1961
+ attachListeners() {
1962
+ this.host.addEventListener("context-request", this.onContextRequest), this.host.addEventListener("context-provider", this.onProviderRequest);
1963
+ }
1964
+ hostConnected() {
1965
+ this.host.dispatchEvent(new gi(this.context));
1966
+ }
1967
+ }
1968
+ /**
1969
+ * @license
1970
+ * Copyright 2017 Google LLC
1971
+ * SPDX-License-Identifier: BSD-3-Clause
1972
+ */
1973
+ function vi({ context: s }) {
1974
+ return (t, e) => {
1975
+ const i = /* @__PURE__ */ new WeakMap();
1976
+ if (typeof e == "object")
1977
+ return e.addInitializer(function() {
1978
+ i.set(this, new Vt(this, { context: s }));
1979
+ }), { get() {
1980
+ return t.get.call(this);
1981
+ }, set(r) {
1982
+ var n;
1983
+ return (n = i.get(this)) == null || n.setValue(r), t.set.call(this, r);
1984
+ }, init(r) {
1985
+ var n;
1986
+ return (n = i.get(this)) == null || n.setValue(r), r;
1987
+ } };
1988
+ {
1989
+ t.constructor.addInitializer((o) => {
1990
+ i.set(o, new Vt(o, { context: s }));
1991
+ });
1992
+ const r = Object.getOwnPropertyDescriptor(t, e);
1993
+ let n;
1994
+ if (r === void 0) {
1995
+ const o = /* @__PURE__ */ new WeakMap();
1996
+ n = { get: function() {
1997
+ return o.get(this);
1998
+ }, set: function(a) {
1999
+ i.get(this).setValue(a), o.set(this, a);
2000
+ }, configurable: !0, enumerable: !0 };
2001
+ } else {
2002
+ const o = r.set;
2003
+ n = { ...r, set: function(a) {
2004
+ i.get(this).setValue(a), o == null || o.call(this, a);
2005
+ } };
2006
+ }
2007
+ return void Object.defineProperty(t, e, n);
2008
+ }
2009
+ };
2010
+ }
2011
+ var mi = Object.defineProperty, yi = Object.getOwnPropertyDescriptor, bi = (s, t, e, i) => {
2012
+ for (var r = i > 1 ? void 0 : i ? yi(t, e) : t, n = s.length - 1, o; n >= 0; n--)
2013
+ (o = s[n]) && (r = (i ? o(t, e, r) : o(r)) || r);
2014
+ return i && r && mi(t, e, r), r;
2015
+ };
2016
+ const $i = "application";
2017
+ class At extends m {
2018
+ constructor() {
2019
+ super(...arguments), this.nodes = [], this.wrapperRef = he();
2020
+ }
2021
+ addChild(t) {
2022
+ t.parent = this, this.nodes.push(t);
2023
+ }
2024
+ applyBranding() {
2025
+ if (!this.wrapperRef.value)
2026
+ return;
2027
+ const t = this.application.settings;
2028
+ t != null && t.branding && le(t.branding, this.wrapperRef.value);
2029
+ }
2030
+ applyStyles() {
2031
+ if (!this.wrapperRef.value)
2032
+ return;
2033
+ const t = this.application.styles(), e = this.wrapperRef.value;
2034
+ Object.entries(t).forEach(([i, r]) => {
2035
+ e.style.setProperty(`--${i}`, r);
2036
+ });
2037
+ }
2038
+ firstUpdated(t) {
2039
+ this.applyBranding(), this.applyStyles();
2040
+ }
2041
+ render() {
2042
+ return this.application.renderStrategy === wt.Trigger && (this.renderRoot.host.classList.add("floating"), this.application.anchor === "BottomLeft" ? this.renderRoot.host.classList.add("bottom-left") : this.application.anchor === "BottomRight" && this.renderRoot.host.classList.add("bottom-right")), A`<div class="widget-container" ${pe(this.wrapperRef)}>
2043
+ ${te(this.nodes, (t) => t)}
2044
+ </div>`;
2045
+ }
2046
+ }
2047
+ At.styles = E`
2048
+ :host {
2049
+ --font-family: TeliaSans, Helvetica, Arial, Lucida Grande, sans-serif;
2050
+ --spacing-xs: 0.2rem;
2051
+ --spacing-sm: 0.5rem;
2052
+ --spacing-md: 1rem;
2053
+ --spacing-lg: 1.2rem;
2054
+ --spacing-xl: 1.8rem;
2055
+
2056
+ --inverted-spacing-lg: -1.2rem;
2057
+
2058
+ --text-color: #222222;
2059
+ --link-color: #990ae3;
2060
+ --gray-color: #f3f3f8;
2061
+ --white-color: #fff;
2062
+ --gray-dark-color: #a6a6a6;
2063
+
2064
+ --box-shadow: rgba(149, 157, 165, 0.2) 0px 8px 24px;
2065
+ --border-radius: var(--spacing-sm);
2066
+ --border-radius-sm: var(--spacing-sm);
2067
+ --border-radius-lg: var(--spacing-lg);
2068
+ --border-radius-xl: var(--spacing-xl);
2069
+ --gap: var(--spacing-sm);
2070
+
2071
+ --header-height: 69px;
2072
+ }
2073
+ :host {
2074
+ --voca-rem-multiplier: 0.625;
2075
+ box-sizing: border-box;
2076
+ display: block;
2077
+ }
2078
+
2079
+ :host(.inline) {
2080
+ height: 100%;
2081
+ position: fixed;
2082
+ inset: 0 0 0 0;
2083
+ }
2084
+
2085
+ :host(.floating) {
2086
+ z-index: 6;
2087
+ position: fixed;
2088
+ }
2089
+ @media screen and (max-width: 800px) {
2090
+ :host(.floating) {
2091
+ inset: 0 0 95px 0;
2092
+ }
2093
+ }
2094
+ @media screen and (min-width: 801px) {
2095
+ :host(.floating) {
2096
+ inset: auto 20px 95px auto;
2097
+ max-height: calc(100vh - 120px);
2098
+ width: 400px;
2099
+ height: 700px;
2100
+ }
2101
+ :host(.floating.bottom-right) {
2102
+ inset: auto 20px 95px auto;
2103
+ }
2104
+ :host(.floating.bottom-left) {
2105
+ inset: auto auto 95px 20px;
2106
+ }
2107
+ }
2108
+
2109
+ :host(.floating) .widget-container {
2110
+ box-shadow: rgba(0, 0, 0, 0.16) 0px 5px 40px;
2111
+ border-radius: 0.7rem;
2112
+ }
2113
+
2114
+ * {
2115
+ box-sizing: border-box;
2116
+ }
2117
+ .widget-container {
2118
+ height: 100%;
2119
+ background-color: var(--primary-background);
2120
+ padding: var(--spacing-sm);
2121
+ border: var(--widget-border, none);
2122
+ }
2123
+ @keyframes slideDown {
2124
+ from {
2125
+ transform: translateY(0);
2126
+ opacity: 1;
2127
+ }
2128
+ to {
2129
+ transform: translateY(100%);
2130
+ opacity: 0;
2131
+ }
2132
+ }
2133
+ @keyframes slideUp {
2134
+ from {
2135
+ transform: translateY(100%);
2136
+ opacity: 0;
2137
+ }
2138
+ to {
2139
+ transform: translateY(0);
2140
+ opacity: 1;
2141
+ }
2142
+ }
2143
+ :host(.expanded) {
2144
+ opacity: 1;
2145
+ animation: slideUp 0.3s linear;
2146
+ }
2147
+ :host(.hidden) {
2148
+ opacity: 0;
2149
+ animation: slideDown 0.3s linear;
2150
+ }
2151
+ `;
2152
+ bi([
2153
+ g({ attribute: !1 }),
2154
+ vi({ context: $i })
2155
+ ], At.prototype, "application", 2);
2156
+ var _i = Object.defineProperty, wi = Object.getOwnPropertyDescriptor, xt = (s, t, e, i) => {
2157
+ for (var r = i > 1 ? void 0 : i ? wi(t, e) : t, n = s.length - 1, o; n >= 0; n--)
2158
+ (o = s[n]) && (r = (i ? o(t, e, r) : o(r)) || r);
2159
+ return i && r && _i(t, e, r), r;
2160
+ };
2161
+ class z extends m {
2162
+ constructor() {
2163
+ super(), this.status = "deactivated", this.addEventListener("environment-created", this.onEnvironmentCreated);
2164
+ }
2165
+ async connectedCallback() {
2166
+ super.connectedCallback(), await this.getGlobalEnvironment();
2167
+ }
2168
+ disconnectedCallback() {
2169
+ super.disconnectedCallback(), this.removeEventListener("environment-created", this.onEnvironmentCreated);
2170
+ }
2171
+ async onEnvironmentCreated(t) {
2172
+ this.widget = t.detail.widget, await this.activate(), this.requestUpdate();
2173
+ }
2174
+ async activate() {
2175
+ this.widget && (await this.widget.activate(), this.status = "activated");
2176
+ }
2177
+ async getGlobalEnvironment() {
2178
+ const t = globalThis.widgets;
2179
+ t && (this.widget = t.applications.find(
2180
+ (e) => e.name === this.name
2181
+ ), await this.activate());
2182
+ }
2183
+ render() {
2184
+ if (!this.widget || this.status !== "activated")
2185
+ return u;
2186
+ if (this.widget.renderStrategy === wt.Trigger) {
2187
+ const t = new P();
2188
+ return t.application = this.widget, t;
2189
+ }
2190
+ return this.widget.render();
2191
+ }
2192
+ }
2193
+ z.styles = [
2194
+ E`
2195
+ :host {
2196
+ display: block;
2197
+ }
2198
+ `
2199
+ ];
2200
+ xt([
2201
+ g({ attribute: !0 })
2202
+ ], z.prototype, "name", 2);
2203
+ xt([
2204
+ B()
2205
+ ], z.prototype, "widget", 2);
2206
+ xt([
2207
+ B()
2208
+ ], z.prototype, "status", 2);
2209
+ customElements.get("ace-trigger-slot") || customElements.define("ace-trigger-slot", bt);
2210
+ customElements.get("ace-trigger") || customElements.define("ace-trigger", P);
2211
+ customElements.get("ace-unresolved-component") || customElements.define("ace-unresolved-component", de);
2212
+ customElements.get("ace-wrapper") || customElements.define("ace-wrapper", At);
2213
+ customElements.get("ace-widget") || customElements.define("ace-widget", z);
2214
+ const Ai = (s) => {
2215
+ const t = {};
2216
+ return Object.keys(s).forEach((e) => {
2217
+ e.indexOf("css-") > -1 && (t[e] = s[e]);
2218
+ }), t;
2219
+ }, xi = (s, t) => {
2220
+ const e = Ai(t);
2221
+ Object.entries(e).forEach(([i, r]) => {
2222
+ s.style.setProperty(i.replace("css-", ""), r);
2223
+ });
2224
+ };
2225
+ class Ci extends ue(m) {
2226
+ constructor() {
2227
+ super(...arguments), this.nodes = [];
2228
+ }
2229
+ render() {
2230
+ var t;
2231
+ return xi(this.renderRoot.host, this.properties), this.renderRoot.host.style.setProperty(
2232
+ "--columns",
2233
+ ((t = this.properties.columns) == null ? void 0 : t.toString()) || "1"
2234
+ ), A`${te(this.nodes, (e) => e)}`;
2235
+ }
2236
+ }
2237
+ Ci.styles = [
2238
+ E`
2239
+ :host {
2240
+ height: 100%;
2241
+ display: grid;
2242
+ justify-content: center;
2243
+ grid-auto-rows: max-content;
2244
+ grid-template-rows: auto;
2245
+ grid-template-columns: repeat(var(--columns), 1fr);
2246
+ gap: var(--gap);
2247
+ }
2248
+ `
2249
+ ];
2250
+ export {
2251
+ Ci as Area,
2252
+ Ci as default
2253
+ };