pollcatch 2.5.7 → 2.5.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/pc.js +485 -455
package/pc.js CHANGED
@@ -3,18 +3,18 @@
3
3
  * Copyright 2019 Google LLC
4
4
  * SPDX-License-Identifier: BSD-3-Clause
5
5
  */
6
- const xt = globalThis, Ft = xt.ShadowRoot && (xt.ShadyCSS === void 0 || xt.ShadyCSS.nativeShadow) && "adoptedStyleSheets" in Document.prototype && "replace" in CSSStyleSheet.prototype, Yt = Symbol(), te = /* @__PURE__ */ new WeakMap();
7
- let ke = class {
6
+ const $t = globalThis, Yt = $t.ShadowRoot && ($t.ShadyCSS === void 0 || $t.ShadyCSS.nativeShadow) && "adoptedStyleSheets" in Document.prototype && "replace" in CSSStyleSheet.prototype, Kt = Symbol(), ee = /* @__PURE__ */ new WeakMap();
7
+ let Ee = class {
8
8
  constructor(t, o, r) {
9
- if (this._$cssResult$ = !0, r !== Yt) throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");
9
+ if (this._$cssResult$ = !0, r !== Kt) throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");
10
10
  this.cssText = t, this.t = o;
11
11
  }
12
12
  get styleSheet() {
13
13
  let t = this.o;
14
14
  const o = this.t;
15
- if (Ft && t === void 0) {
15
+ if (Yt && t === void 0) {
16
16
  const r = o !== void 0 && o.length === 1;
17
- r && (t = te.get(o)), t === void 0 && ((this.o = t = new CSSStyleSheet()).replaceSync(this.cssText), r && te.set(o, t));
17
+ r && (t = ee.get(o)), t === void 0 && ((this.o = t = new CSSStyleSheet()).replaceSync(this.cssText), r && ee.set(o, t));
18
18
  }
19
19
  return t;
20
20
  }
@@ -22,33 +22,33 @@ let ke = class {
22
22
  return this.cssText;
23
23
  }
24
24
  };
25
- const Ke = (e) => new ke(typeof e == "string" ? e : e + "", void 0, Yt), R = (e, ...t) => {
25
+ const We = (e) => new Ee(typeof e == "string" ? e : e + "", void 0, Kt), R = (e, ...t) => {
26
26
  const o = e.length === 1 ? e[0] : t.reduce((r, s, i) => r + ((a) => {
27
27
  if (a._$cssResult$ === !0) return a.cssText;
28
28
  if (typeof a == "number") return a;
29
29
  throw Error("Value passed to 'css' function must be a 'css' function result: " + a + ". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.");
30
30
  })(s) + e[i + 1], e[0]);
31
- return new ke(o, e, Yt);
32
- }, We = (e, t) => {
33
- if (Ft) e.adoptedStyleSheets = t.map((o) => o instanceof CSSStyleSheet ? o : o.styleSheet);
31
+ return new Ee(o, e, Kt);
32
+ }, Ge = (e, t) => {
33
+ if (Yt) e.adoptedStyleSheets = t.map((o) => o instanceof CSSStyleSheet ? o : o.styleSheet);
34
34
  else for (const o of t) {
35
- const r = document.createElement("style"), s = xt.litNonce;
35
+ const r = document.createElement("style"), s = $t.litNonce;
36
36
  s !== void 0 && r.setAttribute("nonce", s), r.textContent = o.cssText, e.appendChild(r);
37
37
  }
38
- }, ee = Ft ? (e) => e : (e) => e instanceof CSSStyleSheet ? ((t) => {
38
+ }, oe = Yt ? (e) => e : (e) => e instanceof CSSStyleSheet ? ((t) => {
39
39
  let o = "";
40
40
  for (const r of t.cssRules) o += r.cssText;
41
- return Ke(o);
41
+ return We(o);
42
42
  })(e) : e;
43
43
  /**
44
44
  * @license
45
45
  * Copyright 2017 Google LLC
46
46
  * SPDX-License-Identifier: BSD-3-Clause
47
47
  */
48
- const { is: Ge, defineProperty: Ze, getOwnPropertyDescriptor: Xe, getOwnPropertyNames: Je, getOwnPropertySymbols: Qe, getPrototypeOf: to } = Object, j = globalThis, oe = j.trustedTypes, eo = oe ? oe.emptyScript : "", zt = j.reactiveElementPolyfillSupport, lt = (e, t) => e, $t = { toAttribute(e, t) {
48
+ const { is: Ze, defineProperty: Xe, getOwnPropertyDescriptor: Je, getOwnPropertyNames: Qe, getOwnPropertySymbols: to, getPrototypeOf: eo } = Object, j = globalThis, re = j.trustedTypes, oo = re ? re.emptyScript : "", Mt = j.reactiveElementPolyfillSupport, ct = (e, t) => e, Ct = { toAttribute(e, t) {
49
49
  switch (t) {
50
50
  case Boolean:
51
- e = e ? eo : null;
51
+ e = e ? oo : null;
52
52
  break;
53
53
  case Object:
54
54
  case Array:
@@ -73,7 +73,7 @@ const { is: Ge, defineProperty: Ze, getOwnPropertyDescriptor: Xe, getOwnProperty
73
73
  }
74
74
  }
75
75
  return o;
76
- } }, Kt = (e, t) => !Ge(e, t), re = { attribute: !0, type: String, converter: $t, reflect: !1, hasChanged: Kt };
76
+ } }, Wt = (e, t) => !Ze(e, t), se = { attribute: !0, type: String, converter: Ct, reflect: !1, hasChanged: Wt };
77
77
  Symbol.metadata ?? (Symbol.metadata = Symbol("metadata")), j.litPropertyMetadata ?? (j.litPropertyMetadata = /* @__PURE__ */ new WeakMap());
78
78
  let et = class extends HTMLElement {
79
79
  static addInitializer(t) {
@@ -82,14 +82,14 @@ let et = class extends HTMLElement {
82
82
  static get observedAttributes() {
83
83
  return this.finalize(), this._$Eh && [...this._$Eh.keys()];
84
84
  }
85
- static createProperty(t, o = re) {
85
+ static createProperty(t, o = se) {
86
86
  if (o.state && (o.attribute = !1), this._$Ei(), this.elementProperties.set(t, o), !o.noAccessor) {
87
87
  const r = Symbol(), s = this.getPropertyDescriptor(t, r, o);
88
- s !== void 0 && Ze(this.prototype, t, s);
88
+ s !== void 0 && Xe(this.prototype, t, s);
89
89
  }
90
90
  }
91
91
  static getPropertyDescriptor(t, o, r) {
92
- const { get: s, set: i } = Xe(this.prototype, t) ?? { get() {
92
+ const { get: s, set: i } = Je(this.prototype, t) ?? { get() {
93
93
  return this[o];
94
94
  }, set(a) {
95
95
  this[o] = a;
@@ -102,17 +102,17 @@ let et = class extends HTMLElement {
102
102
  }, configurable: !0, enumerable: !0 };
103
103
  }
104
104
  static getPropertyOptions(t) {
105
- return this.elementProperties.get(t) ?? re;
105
+ return this.elementProperties.get(t) ?? se;
106
106
  }
107
107
  static _$Ei() {
108
- if (this.hasOwnProperty(lt("elementProperties"))) return;
109
- const t = to(this);
108
+ if (this.hasOwnProperty(ct("elementProperties"))) return;
109
+ const t = eo(this);
110
110
  t.finalize(), t.l !== void 0 && (this.l = [...t.l]), this.elementProperties = new Map(t.elementProperties);
111
111
  }
112
112
  static finalize() {
113
- if (this.hasOwnProperty(lt("finalized"))) return;
114
- if (this.finalized = !0, this._$Ei(), this.hasOwnProperty(lt("properties"))) {
115
- const o = this.properties, r = [...Je(o), ...Qe(o)];
113
+ if (this.hasOwnProperty(ct("finalized"))) return;
114
+ if (this.finalized = !0, this._$Ei(), this.hasOwnProperty(ct("properties"))) {
115
+ const o = this.properties, r = [...Qe(o), ...to(o)];
116
116
  for (const s of r) this.createProperty(s, o[s]);
117
117
  }
118
118
  const t = this[Symbol.metadata];
@@ -131,8 +131,8 @@ let et = class extends HTMLElement {
131
131
  const o = [];
132
132
  if (Array.isArray(t)) {
133
133
  const r = new Set(t.flat(1 / 0).reverse());
134
- for (const s of r) o.unshift(ee(s));
135
- } else t !== void 0 && o.push(ee(t));
134
+ for (const s of r) o.unshift(oe(s));
135
+ } else t !== void 0 && o.push(oe(t));
136
136
  return o;
137
137
  }
138
138
  static _$Eu(t, o) {
@@ -161,7 +161,7 @@ let et = class extends HTMLElement {
161
161
  }
162
162
  createRenderRoot() {
163
163
  const t = this.shadowRoot ?? this.attachShadow(this.constructor.shadowRootOptions);
164
- return We(t, this.constructor.elementStyles), t;
164
+ return Ge(t, this.constructor.elementStyles), t;
165
165
  }
166
166
  connectedCallback() {
167
167
  var t;
@@ -186,7 +186,7 @@ let et = class extends HTMLElement {
186
186
  var i;
187
187
  const r = this.constructor.elementProperties.get(t), s = this.constructor._$Eu(t, r);
188
188
  if (s !== void 0 && r.reflect === !0) {
189
- const a = (((i = r.converter) == null ? void 0 : i.toAttribute) !== void 0 ? r.converter : $t).toAttribute(o, r.type);
189
+ const a = (((i = r.converter) == null ? void 0 : i.toAttribute) !== void 0 ? r.converter : Ct).toAttribute(o, r.type);
190
190
  this._$Em = t, a == null ? this.removeAttribute(s) : this.setAttribute(s, a), this._$Em = null;
191
191
  }
192
192
  }
@@ -194,13 +194,13 @@ let et = class extends HTMLElement {
194
194
  var i;
195
195
  const r = this.constructor, s = r._$Eh.get(t);
196
196
  if (s !== void 0 && this._$Em !== s) {
197
- const a = r.getPropertyOptions(s), l = typeof a.converter == "function" ? { fromAttribute: a.converter } : ((i = a.converter) == null ? void 0 : i.fromAttribute) !== void 0 ? a.converter : $t;
197
+ const a = r.getPropertyOptions(s), l = typeof a.converter == "function" ? { fromAttribute: a.converter } : ((i = a.converter) == null ? void 0 : i.fromAttribute) !== void 0 ? a.converter : Ct;
198
198
  this._$Em = s, this[s] = l.fromAttribute(o, a.type), this._$Em = null;
199
199
  }
200
200
  }
201
201
  requestUpdate(t, o, r) {
202
202
  if (t !== void 0) {
203
- if (r ?? (r = this.constructor.getPropertyOptions(t)), !(r.hasChanged ?? Kt)(this[t], o)) return;
203
+ if (r ?? (r = this.constructor.getPropertyOptions(t)), !(r.hasChanged ?? Wt)(this[t], o)) return;
204
204
  this.P(t, o, r);
205
205
  }
206
206
  this.isUpdatePending === !1 && (this._$ES = this._$ET());
@@ -273,56 +273,56 @@ let et = class extends HTMLElement {
273
273
  firstUpdated(t) {
274
274
  }
275
275
  };
276
- et.elementStyles = [], et.shadowRootOptions = { mode: "open" }, et[lt("elementProperties")] = /* @__PURE__ */ new Map(), et[lt("finalized")] = /* @__PURE__ */ new Map(), zt == null || zt({ ReactiveElement: et }), (j.reactiveElementVersions ?? (j.reactiveElementVersions = [])).push("2.0.4");
276
+ et.elementStyles = [], et.shadowRootOptions = { mode: "open" }, et[ct("elementProperties")] = /* @__PURE__ */ new Map(), et[ct("finalized")] = /* @__PURE__ */ new Map(), Mt == null || Mt({ ReactiveElement: et }), (j.reactiveElementVersions ?? (j.reactiveElementVersions = [])).push("2.0.4");
277
277
  /**
278
278
  * @license
279
279
  * Copyright 2017 Google LLC
280
280
  * SPDX-License-Identifier: BSD-3-Clause
281
281
  */
282
- const ct = globalThis, St = ct.trustedTypes, se = St ? St.createPolicy("lit-html", { createHTML: (e) => e }) : void 0, Ee = "$lit$", V = `lit$${Math.random().toFixed(9).slice(2)}$`, Ae = "?" + V, oo = `<${Ae}>`, G = document, pt = () => G.createComment(""), ut = (e) => e === null || typeof e != "object" && typeof e != "function", Wt = Array.isArray, ro = (e) => Wt(e) || typeof (e == null ? void 0 : e[Symbol.iterator]) == "function", Mt = `[
283
- \f\r]`, at = /<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g, ie = /-->/g, ae = />/g, K = RegExp(`>|${Mt}(?:([^\\s"'>=/]+)(${Mt}*=${Mt}*(?:[^
284
- \f\r"'\`<>=]|("|')|))|$)`, "g"), ne = /'/g, le = /"/g, Pe = /^(?:script|style|textarea|title)$/i, so = (e) => (t, ...o) => ({ _$litType$: e, strings: t, values: o }), c = so(1), q = Symbol.for("lit-noChange"), u = Symbol.for("lit-nothing"), ce = /* @__PURE__ */ new WeakMap(), W = G.createTreeWalker(G, 129);
285
- function Te(e, t) {
286
- if (!Wt(e) || !e.hasOwnProperty("raw")) throw Error("invalid template strings array");
287
- return se !== void 0 ? se.createHTML(t) : t;
282
+ const dt = globalThis, kt = dt.trustedTypes, ie = kt ? kt.createPolicy("lit-html", { createHTML: (e) => e }) : void 0, Ae = "$lit$", V = `lit$${Math.random().toFixed(9).slice(2)}$`, Pe = "?" + V, ro = `<${Pe}>`, G = document, ut = () => G.createComment(""), ht = (e) => e === null || typeof e != "object" && typeof e != "function", Gt = Array.isArray, so = (e) => Gt(e) || typeof (e == null ? void 0 : e[Symbol.iterator]) == "function", Lt = `[
283
+ \f\r]`, nt = /<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g, ae = /-->/g, ne = />/g, K = RegExp(`>|${Lt}(?:([^\\s"'>=/]+)(${Lt}*=${Lt}*(?:[^
284
+ \f\r"'\`<>=]|("|')|))|$)`, "g"), le = /'/g, ce = /"/g, Te = /^(?:script|style|textarea|title)$/i, io = (e) => (t, ...o) => ({ _$litType$: e, strings: t, values: o }), c = io(1), q = Symbol.for("lit-noChange"), u = Symbol.for("lit-nothing"), de = /* @__PURE__ */ new WeakMap(), W = G.createTreeWalker(G, 129);
285
+ function _e(e, t) {
286
+ if (!Gt(e) || !e.hasOwnProperty("raw")) throw Error("invalid template strings array");
287
+ return ie !== void 0 ? ie.createHTML(t) : t;
288
288
  }
289
- const io = (e, t) => {
289
+ const ao = (e, t) => {
290
290
  const o = e.length - 1, r = [];
291
- let s, i = t === 2 ? "<svg>" : t === 3 ? "<math>" : "", a = at;
291
+ let s, i = t === 2 ? "<svg>" : t === 3 ? "<math>" : "", a = nt;
292
292
  for (let l = 0; l < o; l++) {
293
293
  const n = e[l];
294
294
  let d, p, h = -1, b = 0;
295
- for (; b < n.length && (a.lastIndex = b, p = a.exec(n), p !== null); ) b = a.lastIndex, a === at ? p[1] === "!--" ? a = ie : p[1] !== void 0 ? a = ae : p[2] !== void 0 ? (Pe.test(p[2]) && (s = RegExp("</" + p[2], "g")), a = K) : p[3] !== void 0 && (a = K) : a === K ? p[0] === ">" ? (a = s ?? at, h = -1) : p[1] === void 0 ? h = -2 : (h = a.lastIndex - p[2].length, d = p[1], a = p[3] === void 0 ? K : p[3] === '"' ? le : ne) : a === le || a === ne ? a = K : a === ie || a === ae ? a = at : (a = K, s = void 0);
296
- const w = a === K && e[l + 1].startsWith("/>") ? " " : "";
297
- i += a === at ? n + oo : h >= 0 ? (r.push(d), n.slice(0, h) + Ee + n.slice(h) + V + w) : n + V + (h === -2 ? l : w);
295
+ for (; b < n.length && (a.lastIndex = b, p = a.exec(n), p !== null); ) b = a.lastIndex, a === nt ? p[1] === "!--" ? a = ae : p[1] !== void 0 ? a = ne : p[2] !== void 0 ? (Te.test(p[2]) && (s = RegExp("</" + p[2], "g")), a = K) : p[3] !== void 0 && (a = K) : a === K ? p[0] === ">" ? (a = s ?? nt, h = -1) : p[1] === void 0 ? h = -2 : (h = a.lastIndex - p[2].length, d = p[1], a = p[3] === void 0 ? K : p[3] === '"' ? ce : le) : a === ce || a === le ? a = K : a === ae || a === ne ? a = nt : (a = K, s = void 0);
296
+ const x = a === K && e[l + 1].startsWith("/>") ? " " : "";
297
+ i += a === nt ? n + ro : h >= 0 ? (r.push(d), n.slice(0, h) + Ae + n.slice(h) + V + x) : n + V + (h === -2 ? l : x);
298
298
  }
299
- return [Te(e, i + (e[o] || "<?>") + (t === 2 ? "</svg>" : t === 3 ? "</math>" : "")), r];
299
+ return [_e(e, i + (e[o] || "<?>") + (t === 2 ? "</svg>" : t === 3 ? "</math>" : "")), r];
300
300
  };
301
- let Ht = class _e {
301
+ let Ft = class Oe {
302
302
  constructor({ strings: t, _$litType$: o }, r) {
303
303
  let s;
304
304
  this.parts = [];
305
305
  let i = 0, a = 0;
306
- const l = t.length - 1, n = this.parts, [d, p] = io(t, o);
307
- if (this.el = _e.createElement(d, r), W.currentNode = this.el.content, o === 2 || o === 3) {
306
+ const l = t.length - 1, n = this.parts, [d, p] = ao(t, o);
307
+ if (this.el = Oe.createElement(d, r), W.currentNode = this.el.content, o === 2 || o === 3) {
308
308
  const h = this.el.content.firstChild;
309
309
  h.replaceWith(...h.childNodes);
310
310
  }
311
311
  for (; (s = W.nextNode()) !== null && n.length < l; ) {
312
312
  if (s.nodeType === 1) {
313
- if (s.hasAttributes()) for (const h of s.getAttributeNames()) if (h.endsWith(Ee)) {
314
- const b = p[a++], w = s.getAttribute(h).split(V), E = /([.?@])?(.*)/.exec(b);
315
- n.push({ type: 1, index: i, name: E[2], strings: w, ctor: E[1] === "." ? no : E[1] === "?" ? lo : E[1] === "@" ? co : At }), s.removeAttribute(h);
313
+ if (s.hasAttributes()) for (const h of s.getAttributeNames()) if (h.endsWith(Ae)) {
314
+ const b = p[a++], x = s.getAttribute(h).split(V), E = /([.?@])?(.*)/.exec(b);
315
+ n.push({ type: 1, index: i, name: E[2], strings: x, ctor: E[1] === "." ? lo : E[1] === "?" ? co : E[1] === "@" ? po : Tt }), s.removeAttribute(h);
316
316
  } else h.startsWith(V) && (n.push({ type: 6, index: i }), s.removeAttribute(h));
317
- if (Pe.test(s.tagName)) {
317
+ if (Te.test(s.tagName)) {
318
318
  const h = s.textContent.split(V), b = h.length - 1;
319
319
  if (b > 0) {
320
- s.textContent = St ? St.emptyScript : "";
321
- for (let w = 0; w < b; w++) s.append(h[w], pt()), W.nextNode(), n.push({ type: 2, index: ++i });
322
- s.append(h[b], pt());
320
+ s.textContent = kt ? kt.emptyScript : "";
321
+ for (let x = 0; x < b; x++) s.append(h[x], ut()), W.nextNode(), n.push({ type: 2, index: ++i });
322
+ s.append(h[b], ut());
323
323
  }
324
324
  }
325
- } else if (s.nodeType === 8) if (s.data === Ae) n.push({ type: 2, index: i });
325
+ } else if (s.nodeType === 8) if (s.data === Pe) n.push({ type: 2, index: i });
326
326
  else {
327
327
  let h = -1;
328
328
  for (; (h = s.data.indexOf(V, h + 1)) !== -1; ) n.push({ type: 7, index: i }), h += V.length - 1;
@@ -339,10 +339,10 @@ function rt(e, t, o = e, r) {
339
339
  var a, l;
340
340
  if (t === q) return t;
341
341
  let s = r !== void 0 ? (a = o._$Co) == null ? void 0 : a[r] : o._$Cl;
342
- const i = ut(t) ? void 0 : t._$litDirective$;
342
+ const i = ht(t) ? void 0 : t._$litDirective$;
343
343
  return (s == null ? void 0 : s.constructor) !== i && ((l = s == null ? void 0 : s._$AO) == null || l.call(s, !1), i === void 0 ? s = void 0 : (s = new i(e), s._$AT(e, o, r)), r !== void 0 ? (o._$Co ?? (o._$Co = []))[r] = s : o._$Cl = s), s !== void 0 && (t = rt(e, s._$AS(e, t.values), s, r)), t;
344
344
  }
345
- let ao = class {
345
+ let no = class {
346
346
  constructor(t, o) {
347
347
  this._$AV = [], this._$AN = void 0, this._$AD = t, this._$AM = o;
348
348
  }
@@ -359,7 +359,7 @@ let ao = class {
359
359
  for (; n !== void 0; ) {
360
360
  if (a === n.index) {
361
361
  let d;
362
- n.type === 2 ? d = new ht(i, i.nextSibling, this, t) : n.type === 1 ? d = new n.ctor(i, n.name, n.strings, this, t) : n.type === 6 && (d = new po(i, this, t)), this._$AV.push(d), n = r[++l];
362
+ n.type === 2 ? d = new ft(i, i.nextSibling, this, t) : n.type === 1 ? d = new n.ctor(i, n.name, n.strings, this, t) : n.type === 6 && (d = new uo(i, this, t)), this._$AV.push(d), n = r[++l];
363
363
  }
364
364
  a !== (n == null ? void 0 : n.index) && (i = W.nextNode(), a++);
365
365
  }
@@ -370,7 +370,7 @@ let ao = class {
370
370
  for (const r of this._$AV) r !== void 0 && (r.strings !== void 0 ? (r._$AI(t, r, o), o += r.strings.length - 2) : r._$AI(t[o])), o++;
371
371
  }
372
372
  };
373
- class ht {
373
+ class ft {
374
374
  get _$AU() {
375
375
  var t;
376
376
  return ((t = this._$AM) == null ? void 0 : t._$AU) ?? this._$Cv;
@@ -390,7 +390,7 @@ class ht {
390
390
  return this._$AB;
391
391
  }
392
392
  _$AI(t, o = this) {
393
- t = rt(this, t, o), ut(t) ? t === u || t == null || t === "" ? (this._$AH !== u && this._$AR(), this._$AH = u) : t !== this._$AH && t !== q && this._(t) : t._$litType$ !== void 0 ? this.$(t) : t.nodeType !== void 0 ? this.T(t) : ro(t) ? this.k(t) : this._(t);
393
+ t = rt(this, t, o), ht(t) ? t === u || t == null || t === "" ? (this._$AH !== u && this._$AR(), this._$AH = u) : t !== this._$AH && t !== q && this._(t) : t._$litType$ !== void 0 ? this.$(t) : t.nodeType !== void 0 ? this.T(t) : so(t) ? this.k(t) : this._(t);
394
394
  }
395
395
  O(t) {
396
396
  return this._$AA.parentNode.insertBefore(t, this._$AB);
@@ -399,26 +399,26 @@ class ht {
399
399
  this._$AH !== t && (this._$AR(), this._$AH = this.O(t));
400
400
  }
401
401
  _(t) {
402
- this._$AH !== u && ut(this._$AH) ? this._$AA.nextSibling.data = t : this.T(G.createTextNode(t)), this._$AH = t;
402
+ this._$AH !== u && ht(this._$AH) ? this._$AA.nextSibling.data = t : this.T(G.createTextNode(t)), this._$AH = t;
403
403
  }
404
404
  $(t) {
405
405
  var i;
406
- const { values: o, _$litType$: r } = t, s = typeof r == "number" ? this._$AC(t) : (r.el === void 0 && (r.el = Ht.createElement(Te(r.h, r.h[0]), this.options)), r);
406
+ const { values: o, _$litType$: r } = t, s = typeof r == "number" ? this._$AC(t) : (r.el === void 0 && (r.el = Ft.createElement(_e(r.h, r.h[0]), this.options)), r);
407
407
  if (((i = this._$AH) == null ? void 0 : i._$AD) === s) this._$AH.p(o);
408
408
  else {
409
- const a = new ao(s, this), l = a.u(this.options);
409
+ const a = new no(s, this), l = a.u(this.options);
410
410
  a.p(o), this.T(l), this._$AH = a;
411
411
  }
412
412
  }
413
413
  _$AC(t) {
414
- let o = ce.get(t.strings);
415
- return o === void 0 && ce.set(t.strings, o = new Ht(t)), o;
414
+ let o = de.get(t.strings);
415
+ return o === void 0 && de.set(t.strings, o = new Ft(t)), o;
416
416
  }
417
417
  k(t) {
418
- Wt(this._$AH) || (this._$AH = [], this._$AR());
418
+ Gt(this._$AH) || (this._$AH = [], this._$AR());
419
419
  const o = this._$AH;
420
420
  let r, s = 0;
421
- for (const i of t) s === o.length ? o.push(r = new ht(this.O(pt()), this.O(pt()), this, this.options)) : r = o[s], r._$AI(i), s++;
421
+ for (const i of t) s === o.length ? o.push(r = new ft(this.O(ut()), this.O(ut()), this, this.options)) : r = o[s], r._$AI(i), s++;
422
422
  s < o.length && (this._$AR(r && r._$AB.nextSibling, s), o.length = s);
423
423
  }
424
424
  _$AR(t = this._$AA.nextSibling, o) {
@@ -433,7 +433,7 @@ class ht {
433
433
  this._$AM === void 0 && (this._$Cv = t, (o = this._$AP) == null || o.call(this, t));
434
434
  }
435
435
  }
436
- class At {
436
+ class Tt {
437
437
  get tagName() {
438
438
  return this.element.tagName;
439
439
  }
@@ -446,11 +446,11 @@ class At {
446
446
  _$AI(t, o = this, r, s) {
447
447
  const i = this.strings;
448
448
  let a = !1;
449
- if (i === void 0) t = rt(this, t, o, 0), a = !ut(t) || t !== this._$AH && t !== q, a && (this._$AH = t);
449
+ if (i === void 0) t = rt(this, t, o, 0), a = !ht(t) || t !== this._$AH && t !== q, a && (this._$AH = t);
450
450
  else {
451
451
  const l = t;
452
452
  let n, d;
453
- for (t = i[0], n = 0; n < i.length - 1; n++) d = rt(this, l[r + n], o, n), d === q && (d = this._$AH[n]), a || (a = !ut(d) || d !== this._$AH[n]), d === u ? t = u : t !== u && (t += (d ?? "") + i[n + 1]), this._$AH[n] = d;
453
+ for (t = i[0], n = 0; n < i.length - 1; n++) d = rt(this, l[r + n], o, n), d === q && (d = this._$AH[n]), a || (a = !ht(d) || d !== this._$AH[n]), d === u ? t = u : t !== u && (t += (d ?? "") + i[n + 1]), this._$AH[n] = d;
454
454
  }
455
455
  a && !s && this.j(t);
456
456
  }
@@ -458,7 +458,7 @@ class At {
458
458
  t === u ? this.element.removeAttribute(this.name) : this.element.setAttribute(this.name, t ?? "");
459
459
  }
460
460
  }
461
- let no = class extends At {
461
+ let lo = class extends Tt {
462
462
  constructor() {
463
463
  super(...arguments), this.type = 3;
464
464
  }
@@ -466,7 +466,7 @@ let no = class extends At {
466
466
  this.element[this.name] = t === u ? void 0 : t;
467
467
  }
468
468
  };
469
- class lo extends At {
469
+ class co extends Tt {
470
470
  constructor() {
471
471
  super(...arguments), this.type = 4;
472
472
  }
@@ -474,7 +474,7 @@ class lo extends At {
474
474
  this.element.toggleAttribute(this.name, !!t && t !== u);
475
475
  }
476
476
  }
477
- class co extends At {
477
+ class po extends Tt {
478
478
  constructor(t, o, r, s, i) {
479
479
  super(t, o, r, s, i), this.type = 5;
480
480
  }
@@ -488,7 +488,7 @@ class co extends At {
488
488
  typeof this._$AH == "function" ? this._$AH.call(((o = this.options) == null ? void 0 : o.host) ?? this.element, t) : this._$AH.handleEvent(t);
489
489
  }
490
490
  }
491
- class po {
491
+ class uo {
492
492
  constructor(t, o, r) {
493
493
  this.element = t, this.type = 6, this._$AN = void 0, this._$AM = o, this.options = r;
494
494
  }
@@ -499,14 +499,14 @@ class po {
499
499
  rt(this, t);
500
500
  }
501
501
  }
502
- const Lt = ct.litHtmlPolyfillSupport;
503
- Lt == null || Lt(Ht, ht), (ct.litHtmlVersions ?? (ct.litHtmlVersions = [])).push("3.2.1");
504
- const uo = (e, t, o) => {
502
+ const Nt = dt.litHtmlPolyfillSupport;
503
+ Nt == null || Nt(Ft, ft), (dt.litHtmlVersions ?? (dt.litHtmlVersions = [])).push("3.2.1");
504
+ const ho = (e, t, o) => {
505
505
  const r = (o == null ? void 0 : o.renderBefore) ?? t;
506
506
  let s = r._$litPart$;
507
507
  if (s === void 0) {
508
508
  const i = (o == null ? void 0 : o.renderBefore) ?? null;
509
- r._$litPart$ = s = new ht(t.insertBefore(pt(), i), i, void 0, o ?? {});
509
+ r._$litPart$ = s = new ft(t.insertBefore(ut(), i), i, void 0, o ?? {});
510
510
  }
511
511
  return s._$AI(e), s;
512
512
  };
@@ -526,7 +526,7 @@ let N = class extends et {
526
526
  }
527
527
  update(t) {
528
528
  const o = this.render();
529
- this.hasUpdated || (this.renderOptions.isConnected = this.isConnected), super.update(t), this._$Do = uo(o, this.renderRoot, this.renderOptions);
529
+ this.hasUpdated || (this.renderOptions.isConnected = this.isConnected), super.update(t), this._$Do = ho(o, this.renderRoot, this.renderOptions);
530
530
  }
531
531
  connectedCallback() {
532
532
  var t;
@@ -540,10 +540,10 @@ let N = class extends et {
540
540
  return q;
541
541
  }
542
542
  };
543
- var Ce;
544
- N._$litElement$ = !0, N.finalized = !0, (Ce = globalThis.litElementHydrateSupport) == null || Ce.call(globalThis, { LitElement: N });
545
- const Nt = globalThis.litElementPolyfillSupport;
546
- Nt == null || Nt({ LitElement: N });
543
+ var ke;
544
+ N._$litElement$ = !0, N.finalized = !0, (ke = globalThis.litElementHydrateSupport) == null || ke.call(globalThis, { LitElement: N });
545
+ const Dt = globalThis.litElementPolyfillSupport;
546
+ Dt == null || Dt({ LitElement: N });
547
547
  (globalThis.litElementVersions ?? (globalThis.litElementVersions = [])).push("4.1.1");
548
548
  /**
549
549
  * @license
@@ -560,7 +560,7 @@ const F = (e) => (t, o) => {
560
560
  * Copyright 2017 Google LLC
561
561
  * SPDX-License-Identifier: BSD-3-Clause
562
562
  */
563
- const ho = { attribute: !0, type: String, converter: $t, reflect: !1, hasChanged: Kt }, fo = (e = ho, t, o) => {
563
+ const fo = { attribute: !0, type: String, converter: Ct, reflect: !1, hasChanged: Wt }, go = (e = fo, t, o) => {
564
564
  const { kind: r, metadata: s } = o;
565
565
  let i = globalThis.litPropertyMetadata.get(s);
566
566
  if (i === void 0 && globalThis.litPropertyMetadata.set(s, i = /* @__PURE__ */ new Map()), i.set(o.name, e), r === "accessor") {
@@ -582,7 +582,7 @@ const ho = { attribute: !0, type: String, converter: $t, reflect: !1, hasChanged
582
582
  throw Error("Unsupported decorator location: " + r);
583
583
  };
584
584
  function f(e) {
585
- return (t, o) => typeof o == "object" ? fo(e, t, o) : ((r, s, i) => {
585
+ return (t, o) => typeof o == "object" ? go(e, t, o) : ((r, s, i) => {
586
586
  const a = s.hasOwnProperty(i);
587
587
  return s.constructor.createProperty(i, a ? { ...r, wrapped: !0 } : r), a ? Object.getOwnPropertyDescriptor(s, i) : void 0;
588
588
  })(e, t, o);
@@ -600,25 +600,25 @@ function k(e) {
600
600
  * Copyright 2017 Google LLC
601
601
  * SPDX-License-Identifier: BSD-3-Clause
602
602
  */
603
- const go = (e, t, o) => (o.configurable = !0, o.enumerable = !0, Reflect.decorate && typeof t != "object" && Object.defineProperty(e, t, o), o);
603
+ const mo = (e, t, o) => (o.configurable = !0, o.enumerable = !0, Reflect.decorate && typeof t != "object" && Object.defineProperty(e, t, o), o);
604
604
  /**
605
605
  * @license
606
606
  * Copyright 2017 Google LLC
607
607
  * SPDX-License-Identifier: BSD-3-Clause
608
608
  */
609
- function ft(e, t) {
609
+ function gt(e, t) {
610
610
  return (o, r, s) => {
611
611
  const i = (a) => {
612
612
  var l;
613
613
  return ((l = a.renderRoot) == null ? void 0 : l.querySelector(e)) ?? null;
614
614
  };
615
- return go(o, r, { get() {
615
+ return mo(o, r, { get() {
616
616
  return i(this);
617
617
  } });
618
618
  };
619
619
  }
620
620
  var $ = /* @__PURE__ */ ((e) => (e.reaction = "reaction", e.stars = "stars", e.poll = "poll", e.text = "text", e.nps = "nps", e))($ || {});
621
- const Gt = c`
621
+ const Zt = c`
622
622
  <svg
623
623
  xmlns="http://www.w3.org/2000/svg"
624
624
  height="24px"
@@ -628,7 +628,7 @@ const Gt = c`
628
628
  >
629
629
  <path d="M640-160v-280h160v280H640Zm-240 0v-640h160v640H400Zm-240 0v-440h160v440H160Z" />
630
630
  </svg>
631
- `, Zt = c`
631
+ `, Xt = c`
632
632
  <svg
633
633
  xmlns="http://www.w3.org/2000/svg"
634
634
  height="24px"
@@ -640,7 +640,7 @@ const Gt = c`
640
640
  d="M160-160v-440h160v440H160Zm240 0v-400l160 160v240H400Zm160-354L400-674v-126h160v286Zm240 240L640-434v-6h160v166Zm-9 219L55-791l57-57 736 736-57 57Z"
641
641
  />
642
642
  </svg>
643
- `, Ct = c`
643
+ `, Et = c`
644
644
  <svg
645
645
  xmlns="http://www.w3.org/2000/svg"
646
646
  height="24px"
@@ -652,7 +652,7 @@ const Gt = c`
652
652
  d="M200-200h57l391-391-57-57-391 391v57Zm-80 80v-170l528-527q12-11 26.5-17t30.5-6q16 0 31 6t26 18l55 56q12 11 17.5 26t5.5 30q0 16-5.5 30.5T817-647L290-120H120Zm640-584-56-56 56 56Zm-141 85-28-29 57 57-29-28Z"
653
653
  />
654
654
  </svg>
655
- `, Pt = c`
655
+ `, _t = c`
656
656
  <svg
657
657
  xmlns="http://www.w3.org/2000/svg"
658
658
  width="16"
@@ -664,7 +664,7 @@ const Gt = c`
664
664
  d="M4.646 4.646a.5.5 0 0 1 .708 0L8 7.293l2.646-2.647a.5.5 0 0 1 .708.708L8.707 8l2.647 2.646a.5.5 0 0 1-.708.708L8 8.707l-2.646 2.647a.5.5 0 0 1-.708-.708L7.293 8 4.646 5.354a.5.5 0 0 1 0-.708"
665
665
  />
666
666
  </svg>
667
- `, Oe = c`
667
+ `, Ie = c`
668
668
  <svg
669
669
  xmlns="http://www.w3.org/2000/svg"
670
670
  height="24px"
@@ -675,164 +675,164 @@ const Gt = c`
675
675
  <path d="M440-440H200v-80h240v-240h80v240h240v80H520v240h-80v-240Z" />
676
676
  </svg>
677
677
  `;
678
- var mo = { grad: 0.9, turn: 360, rad: 360 / (2 * Math.PI) }, M = function(e) {
678
+ var vo = { grad: 0.9, turn: 360, rad: 360 / (2 * Math.PI) }, M = function(e) {
679
679
  return typeof e == "string" ? e.length > 0 : typeof e == "number";
680
680
  }, S = function(e, t, o) {
681
681
  return t === void 0 && (t = 0), o === void 0 && (o = Math.pow(10, t)), Math.round(o * e) / o + 0;
682
- }, A = function(e, t, o) {
682
+ }, T = function(e, t, o) {
683
683
  return t === void 0 && (t = 0), o === void 0 && (o = 1), e > o ? o : e > t ? e : t;
684
- }, Ie = function(e) {
684
+ }, ze = function(e) {
685
685
  return (e = isFinite(e) ? e % 360 : 0) > 0 ? e : e + 360;
686
- }, de = function(e) {
687
- return { r: A(e.r, 0, 255), g: A(e.g, 0, 255), b: A(e.b, 0, 255), a: A(e.a) };
688
- }, Dt = function(e) {
686
+ }, pe = function(e) {
687
+ return { r: T(e.r, 0, 255), g: T(e.g, 0, 255), b: T(e.b, 0, 255), a: T(e.a) };
688
+ }, Rt = function(e) {
689
689
  return { r: S(e.r), g: S(e.g), b: S(e.b), a: S(e.a, 3) };
690
- }, vo = /^#([0-9a-f]{3,8})$/i, bt = function(e) {
690
+ }, bo = /^#([0-9a-f]{3,8})$/i, yt = function(e) {
691
691
  var t = e.toString(16);
692
692
  return t.length < 2 ? "0" + t : t;
693
- }, ze = function(e) {
693
+ }, Me = function(e) {
694
694
  var t = e.r, o = e.g, r = e.b, s = e.a, i = Math.max(t, o, r), a = i - Math.min(t, o, r), l = a ? i === t ? (o - r) / a : i === o ? 2 + (r - t) / a : 4 + (t - o) / a : 0;
695
695
  return { h: 60 * (l < 0 ? l + 6 : l), s: i ? a / i * 100 : 0, v: i / 255 * 100, a: s };
696
- }, Me = function(e) {
696
+ }, Le = function(e) {
697
697
  var t = e.h, o = e.s, r = e.v, s = e.a;
698
698
  t = t / 360 * 6, o /= 100, r /= 100;
699
699
  var i = Math.floor(t), a = r * (1 - o), l = r * (1 - (t - i) * o), n = r * (1 - (1 - t + i) * o), d = i % 6;
700
700
  return { r: 255 * [r, l, a, a, n, r][d], g: 255 * [n, r, r, l, a, a][d], b: 255 * [a, a, n, r, r, l][d], a: s };
701
- }, pe = function(e) {
702
- return { h: Ie(e.h), s: A(e.s, 0, 100), l: A(e.l, 0, 100), a: A(e.a) };
703
701
  }, ue = function(e) {
704
- return { h: S(e.h), s: S(e.s), l: S(e.l), a: S(e.a, 3) };
702
+ return { h: ze(e.h), s: T(e.s, 0, 100), l: T(e.l, 0, 100), a: T(e.a) };
705
703
  }, he = function(e) {
706
- return Me((o = (t = e).s, { h: t.h, s: (o *= ((r = t.l) < 50 ? r : 100 - r) / 100) > 0 ? 2 * o / (r + o) * 100 : 0, v: r + o, a: t.a }));
704
+ return { h: S(e.h), s: S(e.s), l: S(e.l), a: S(e.a, 3) };
705
+ }, fe = function(e) {
706
+ return Le((o = (t = e).s, { h: t.h, s: (o *= ((r = t.l) < 50 ? r : 100 - r) / 100) > 0 ? 2 * o / (r + o) * 100 : 0, v: r + o, a: t.a }));
707
707
  var t, o, r;
708
- }, dt = function(e) {
709
- return { h: (t = ze(e)).h, s: (s = (200 - (o = t.s)) * (r = t.v) / 100) > 0 && s < 200 ? o * r / 100 / (s <= 100 ? s : 200 - s) * 100 : 0, l: s / 2, a: t.a };
708
+ }, pt = function(e) {
709
+ return { h: (t = Me(e)).h, s: (s = (200 - (o = t.s)) * (r = t.v) / 100) > 0 && s < 200 ? o * r / 100 / (s <= 100 ? s : 200 - s) * 100 : 0, l: s / 2, a: t.a };
710
710
  var t, o, r, s;
711
- }, bo = /^hsla?\(\s*([+-]?\d*\.?\d+)(deg|rad|grad|turn)?\s*,\s*([+-]?\d*\.?\d+)%\s*,\s*([+-]?\d*\.?\d+)%\s*(?:,\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i, yo = /^hsla?\(\s*([+-]?\d*\.?\d+)(deg|rad|grad|turn)?\s+([+-]?\d*\.?\d+)%\s+([+-]?\d*\.?\d+)%\s*(?:\/\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i, xo = /^rgba?\(\s*([+-]?\d*\.?\d+)(%)?\s*,\s*([+-]?\d*\.?\d+)(%)?\s*,\s*([+-]?\d*\.?\d+)(%)?\s*(?:,\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i, wo = /^rgba?\(\s*([+-]?\d*\.?\d+)(%)?\s+([+-]?\d*\.?\d+)(%)?\s+([+-]?\d*\.?\d+)(%)?\s*(?:\/\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i, fe = { string: [[function(e) {
712
- var t = vo.exec(e);
711
+ }, yo = /^hsla?\(\s*([+-]?\d*\.?\d+)(deg|rad|grad|turn)?\s*,\s*([+-]?\d*\.?\d+)%\s*,\s*([+-]?\d*\.?\d+)%\s*(?:,\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i, xo = /^hsla?\(\s*([+-]?\d*\.?\d+)(deg|rad|grad|turn)?\s+([+-]?\d*\.?\d+)%\s+([+-]?\d*\.?\d+)%\s*(?:\/\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i, wo = /^rgba?\(\s*([+-]?\d*\.?\d+)(%)?\s*,\s*([+-]?\d*\.?\d+)(%)?\s*,\s*([+-]?\d*\.?\d+)(%)?\s*(?:,\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i, $o = /^rgba?\(\s*([+-]?\d*\.?\d+)(%)?\s+([+-]?\d*\.?\d+)(%)?\s+([+-]?\d*\.?\d+)(%)?\s*(?:\/\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i, ge = { string: [[function(e) {
712
+ var t = bo.exec(e);
713
713
  return t ? (e = t[1]).length <= 4 ? { r: parseInt(e[0] + e[0], 16), g: parseInt(e[1] + e[1], 16), b: parseInt(e[2] + e[2], 16), a: e.length === 4 ? S(parseInt(e[3] + e[3], 16) / 255, 2) : 1 } : e.length === 6 || e.length === 8 ? { r: parseInt(e.substr(0, 2), 16), g: parseInt(e.substr(2, 2), 16), b: parseInt(e.substr(4, 2), 16), a: e.length === 8 ? S(parseInt(e.substr(6, 2), 16) / 255, 2) : 1 } : null : null;
714
714
  }, "hex"], [function(e) {
715
- var t = xo.exec(e) || wo.exec(e);
716
- return t ? t[2] !== t[4] || t[4] !== t[6] ? null : de({ r: Number(t[1]) / (t[2] ? 100 / 255 : 1), g: Number(t[3]) / (t[4] ? 100 / 255 : 1), b: Number(t[5]) / (t[6] ? 100 / 255 : 1), a: t[7] === void 0 ? 1 : Number(t[7]) / (t[8] ? 100 : 1) }) : null;
715
+ var t = wo.exec(e) || $o.exec(e);
716
+ return t ? t[2] !== t[4] || t[4] !== t[6] ? null : pe({ r: Number(t[1]) / (t[2] ? 100 / 255 : 1), g: Number(t[3]) / (t[4] ? 100 / 255 : 1), b: Number(t[5]) / (t[6] ? 100 / 255 : 1), a: t[7] === void 0 ? 1 : Number(t[7]) / (t[8] ? 100 : 1) }) : null;
717
717
  }, "rgb"], [function(e) {
718
- var t = bo.exec(e) || yo.exec(e);
718
+ var t = yo.exec(e) || xo.exec(e);
719
719
  if (!t) return null;
720
- var o, r, s = pe({ h: (o = t[1], r = t[2], r === void 0 && (r = "deg"), Number(o) * (mo[r] || 1)), s: Number(t[3]), l: Number(t[4]), a: t[5] === void 0 ? 1 : Number(t[5]) / (t[6] ? 100 : 1) });
721
- return he(s);
720
+ var o, r, s = ue({ h: (o = t[1], r = t[2], r === void 0 && (r = "deg"), Number(o) * (vo[r] || 1)), s: Number(t[3]), l: Number(t[4]), a: t[5] === void 0 ? 1 : Number(t[5]) / (t[6] ? 100 : 1) });
721
+ return fe(s);
722
722
  }, "hsl"]], object: [[function(e) {
723
723
  var t = e.r, o = e.g, r = e.b, s = e.a, i = s === void 0 ? 1 : s;
724
- return M(t) && M(o) && M(r) ? de({ r: Number(t), g: Number(o), b: Number(r), a: Number(i) }) : null;
724
+ return M(t) && M(o) && M(r) ? pe({ r: Number(t), g: Number(o), b: Number(r), a: Number(i) }) : null;
725
725
  }, "rgb"], [function(e) {
726
726
  var t = e.h, o = e.s, r = e.l, s = e.a, i = s === void 0 ? 1 : s;
727
727
  if (!M(t) || !M(o) || !M(r)) return null;
728
- var a = pe({ h: Number(t), s: Number(o), l: Number(r), a: Number(i) });
729
- return he(a);
728
+ var a = ue({ h: Number(t), s: Number(o), l: Number(r), a: Number(i) });
729
+ return fe(a);
730
730
  }, "hsl"], [function(e) {
731
731
  var t = e.h, o = e.s, r = e.v, s = e.a, i = s === void 0 ? 1 : s;
732
732
  if (!M(t) || !M(o) || !M(r)) return null;
733
733
  var a = function(l) {
734
- return { h: Ie(l.h), s: A(l.s, 0, 100), v: A(l.v, 0, 100), a: A(l.a) };
734
+ return { h: ze(l.h), s: T(l.s, 0, 100), v: T(l.v, 0, 100), a: T(l.a) };
735
735
  }({ h: Number(t), s: Number(o), v: Number(r), a: Number(i) });
736
- return Me(a);
737
- }, "hsv"]] }, ge = function(e, t) {
736
+ return Le(a);
737
+ }, "hsv"]] }, me = function(e, t) {
738
738
  for (var o = 0; o < t.length; o++) {
739
739
  var r = t[o][0](e);
740
740
  if (r) return [r, t[o][1]];
741
741
  }
742
742
  return [null, void 0];
743
- }, $o = function(e) {
744
- return typeof e == "string" ? ge(e.trim(), fe.string) : typeof e == "object" && e !== null ? ge(e, fe.object) : [null, void 0];
745
- }, Rt = function(e, t) {
746
- var o = dt(e);
747
- return { h: o.h, s: A(o.s + 100 * t, 0, 100), l: o.l, a: o.a };
748
- }, Bt = function(e) {
743
+ }, So = function(e) {
744
+ return typeof e == "string" ? me(e.trim(), ge.string) : typeof e == "object" && e !== null ? me(e, ge.object) : [null, void 0];
745
+ }, Bt = function(e, t) {
746
+ var o = pt(e);
747
+ return { h: o.h, s: T(o.s + 100 * t, 0, 100), l: o.l, a: o.a };
748
+ }, Vt = function(e) {
749
749
  return (299 * e.r + 587 * e.g + 114 * e.b) / 1e3 / 255;
750
- }, me = function(e, t) {
751
- var o = dt(e);
752
- return { h: o.h, s: o.s, l: A(o.l + 100 * t, 0, 100), a: o.a };
753
- }, ve = function() {
750
+ }, ve = function(e, t) {
751
+ var o = pt(e);
752
+ return { h: o.h, s: o.s, l: T(o.l + 100 * t, 0, 100), a: o.a };
753
+ }, be = function() {
754
754
  function e(t) {
755
- this.parsed = $o(t)[0], this.rgba = this.parsed || { r: 0, g: 0, b: 0, a: 1 };
755
+ this.parsed = So(t)[0], this.rgba = this.parsed || { r: 0, g: 0, b: 0, a: 1 };
756
756
  }
757
757
  return e.prototype.isValid = function() {
758
758
  return this.parsed !== null;
759
759
  }, e.prototype.brightness = function() {
760
- return S(Bt(this.rgba), 2);
760
+ return S(Vt(this.rgba), 2);
761
761
  }, e.prototype.isDark = function() {
762
- return Bt(this.rgba) < 0.5;
762
+ return Vt(this.rgba) < 0.5;
763
763
  }, e.prototype.isLight = function() {
764
- return Bt(this.rgba) >= 0.5;
764
+ return Vt(this.rgba) >= 0.5;
765
765
  }, e.prototype.toHex = function() {
766
- return t = Dt(this.rgba), o = t.r, r = t.g, s = t.b, a = (i = t.a) < 1 ? bt(S(255 * i)) : "", "#" + bt(o) + bt(r) + bt(s) + a;
766
+ return t = Rt(this.rgba), o = t.r, r = t.g, s = t.b, a = (i = t.a) < 1 ? yt(S(255 * i)) : "", "#" + yt(o) + yt(r) + yt(s) + a;
767
767
  var t, o, r, s, i, a;
768
768
  }, e.prototype.toRgb = function() {
769
- return Dt(this.rgba);
769
+ return Rt(this.rgba);
770
770
  }, e.prototype.toRgbString = function() {
771
- return t = Dt(this.rgba), o = t.r, r = t.g, s = t.b, (i = t.a) < 1 ? "rgba(" + o + ", " + r + ", " + s + ", " + i + ")" : "rgb(" + o + ", " + r + ", " + s + ")";
771
+ return t = Rt(this.rgba), o = t.r, r = t.g, s = t.b, (i = t.a) < 1 ? "rgba(" + o + ", " + r + ", " + s + ", " + i + ")" : "rgb(" + o + ", " + r + ", " + s + ")";
772
772
  var t, o, r, s, i;
773
773
  }, e.prototype.toHsl = function() {
774
- return ue(dt(this.rgba));
774
+ return he(pt(this.rgba));
775
775
  }, e.prototype.toHslString = function() {
776
- return t = ue(dt(this.rgba)), o = t.h, r = t.s, s = t.l, (i = t.a) < 1 ? "hsla(" + o + ", " + r + "%, " + s + "%, " + i + ")" : "hsl(" + o + ", " + r + "%, " + s + "%)";
776
+ return t = he(pt(this.rgba)), o = t.h, r = t.s, s = t.l, (i = t.a) < 1 ? "hsla(" + o + ", " + r + "%, " + s + "%, " + i + ")" : "hsl(" + o + ", " + r + "%, " + s + "%)";
777
777
  var t, o, r, s, i;
778
778
  }, e.prototype.toHsv = function() {
779
- return t = ze(this.rgba), { h: S(t.h), s: S(t.s), v: S(t.v), a: S(t.a, 3) };
779
+ return t = Me(this.rgba), { h: S(t.h), s: S(t.s), v: S(t.v), a: S(t.a, 3) };
780
780
  var t;
781
781
  }, e.prototype.invert = function() {
782
- return T({ r: 255 - (t = this.rgba).r, g: 255 - t.g, b: 255 - t.b, a: t.a });
782
+ return _({ r: 255 - (t = this.rgba).r, g: 255 - t.g, b: 255 - t.b, a: t.a });
783
783
  var t;
784
784
  }, e.prototype.saturate = function(t) {
785
- return t === void 0 && (t = 0.1), T(Rt(this.rgba, t));
785
+ return t === void 0 && (t = 0.1), _(Bt(this.rgba, t));
786
786
  }, e.prototype.desaturate = function(t) {
787
- return t === void 0 && (t = 0.1), T(Rt(this.rgba, -t));
787
+ return t === void 0 && (t = 0.1), _(Bt(this.rgba, -t));
788
788
  }, e.prototype.grayscale = function() {
789
- return T(Rt(this.rgba, -1));
789
+ return _(Bt(this.rgba, -1));
790
790
  }, e.prototype.lighten = function(t) {
791
- return t === void 0 && (t = 0.1), T(me(this.rgba, t));
791
+ return t === void 0 && (t = 0.1), _(ve(this.rgba, t));
792
792
  }, e.prototype.darken = function(t) {
793
- return t === void 0 && (t = 0.1), T(me(this.rgba, -t));
793
+ return t === void 0 && (t = 0.1), _(ve(this.rgba, -t));
794
794
  }, e.prototype.rotate = function(t) {
795
795
  return t === void 0 && (t = 15), this.hue(this.hue() + t);
796
796
  }, e.prototype.alpha = function(t) {
797
- return typeof t == "number" ? T({ r: (o = this.rgba).r, g: o.g, b: o.b, a: t }) : S(this.rgba.a, 3);
797
+ return typeof t == "number" ? _({ r: (o = this.rgba).r, g: o.g, b: o.b, a: t }) : S(this.rgba.a, 3);
798
798
  var o;
799
799
  }, e.prototype.hue = function(t) {
800
- var o = dt(this.rgba);
801
- return typeof t == "number" ? T({ h: t, s: o.s, l: o.l, a: o.a }) : S(o.h);
800
+ var o = pt(this.rgba);
801
+ return typeof t == "number" ? _({ h: t, s: o.s, l: o.l, a: o.a }) : S(o.h);
802
802
  }, e.prototype.isEqual = function(t) {
803
- return this.toHex() === T(t).toHex();
803
+ return this.toHex() === _(t).toHex();
804
804
  }, e;
805
- }(), T = function(e) {
806
- return e instanceof ve ? e : new ve(e);
805
+ }(), _ = function(e) {
806
+ return e instanceof be ? e : new be(e);
807
807
  };
808
- const So = typeof process < "u" && (process.env.NODE_ENV === "development" || process.env.NODE_ENV === "test");
809
- function Vt() {
810
- if (So) return !0;
808
+ const Co = typeof process < "u" && (process.env.NODE_ENV === "development" || process.env.NODE_ENV === "test");
809
+ function Ut() {
810
+ if (Co) return !0;
811
811
  try {
812
812
  return typeof localStorage < "u" && localStorage.getItem("pc-mode") === "development";
813
813
  } catch {
814
814
  return !1;
815
815
  }
816
816
  }
817
- function Co(e) {
817
+ function ko(e) {
818
818
  return {
819
819
  debug: (t, ...o) => {
820
- Vt() && console.debug(`[${e}]`, t, ...o);
820
+ Ut() && console.debug(`[${e}]`, t, ...o);
821
821
  },
822
822
  info: (t, ...o) => {
823
- Vt() && console.info(`[${e}]`, t, ...o);
823
+ Ut() && console.info(`[${e}]`, t, ...o);
824
824
  },
825
825
  warn: (t, ...o) => {
826
- Vt() && console.warn(`[${e}]`, t, ...o);
826
+ Ut() && console.warn(`[${e}]`, t, ...o);
827
827
  },
828
828
  error: (t, ...o) => {
829
829
  console.error(`[${e}]`, t, ...o);
830
830
  }
831
831
  };
832
832
  }
833
- const g = Co("Pollcatch");
834
- var Le = /* @__PURE__ */ ((e) => (e[e.AA_NORMAL = 4.5] = "AA_NORMAL", e[e.AA_LARGE = 3] = "AA_LARGE", e[e.AAA_NORMAL = 7] = "AAA_NORMAL", e[e.AAA_LARGE = 4.5] = "AAA_LARGE", e))(Le || {});
835
- const ko = {
833
+ const g = ko("Pollcatch");
834
+ var Ne = /* @__PURE__ */ ((e) => (e[e.AA_NORMAL = 4.5] = "AA_NORMAL", e[e.AA_LARGE = 3] = "AA_LARGE", e[e.AAA_NORMAL = 7] = "AAA_NORMAL", e[e.AAA_LARGE = 4.5] = "AAA_LARGE", e))(Ne || {});
835
+ const Eo = {
836
836
  black: "#000000",
837
837
  white: "#ffffff",
838
838
  red: "#ff0000",
@@ -849,20 +849,20 @@ const ko = {
849
849
  teal: "#008080",
850
850
  navy: "#000080"
851
851
  };
852
- function Eo(e) {
852
+ function Ao(e) {
853
853
  const t = e.toLowerCase().trim();
854
- return ko[t] || null;
854
+ return Eo[t] || null;
855
855
  }
856
- function Ut(e, t) {
857
- const o = be(e), r = be(t), s = Math.max(o, r), i = Math.min(o, r);
856
+ function jt(e, t) {
857
+ const o = ye(e), r = ye(t), s = Math.max(o, r), i = Math.min(o, r);
858
858
  return (s + 0.05) / (i + 0.05);
859
859
  }
860
- function be(e) {
861
- const t = Po(e), o = t.r / 255, r = t.g / 255, s = t.b / 255, i = o <= 0.03928 ? o / 12.92 : Math.pow((o + 0.055) / 1.055, 2.4), a = r <= 0.03928 ? r / 12.92 : Math.pow((r + 0.055) / 1.055, 2.4), l = s <= 0.03928 ? s / 12.92 : Math.pow((s + 0.055) / 1.055, 2.4);
860
+ function ye(e) {
861
+ const t = To(e), o = t.r / 255, r = t.g / 255, s = t.b / 255, i = o <= 0.03928 ? o / 12.92 : Math.pow((o + 0.055) / 1.055, 2.4), a = r <= 0.03928 ? r / 12.92 : Math.pow((r + 0.055) / 1.055, 2.4), l = s <= 0.03928 ? s / 12.92 : Math.pow((s + 0.055) / 1.055, 2.4);
862
862
  return 0.2126 * i + 0.7152 * a + 0.0722 * l;
863
863
  }
864
- function Ao(e, t = {}) {
865
- if (!T(e).isValid())
864
+ function Po(e, t = {}) {
865
+ if (!_(e).isValid())
866
866
  return g.warn(`Invalid color provided: ${e}`), "black";
867
867
  const {
868
868
  minContrast: r = 4.5,
@@ -875,15 +875,15 @@ function Ao(e, t = {}) {
875
875
  } = t, l = s.map((p) => p === "black" ? "#000000" : p === "white" ? "#ffffff" : p === "light" ? i.light || "#f8f9fa" : p === "dark" ? i.dark || "#343a40" : p);
876
876
  let n = a, d = 0;
877
877
  for (const p of l) {
878
- const h = Ut(e, p);
878
+ const h = jt(e, p);
879
879
  h >= r && h > d && (d = h, n = p);
880
880
  }
881
881
  if (d === 0) {
882
- const p = Ut(e, a);
882
+ const p = jt(e, a);
883
883
  n = a, d = p;
884
884
  for (const h of l) {
885
885
  if (h === a) continue;
886
- const b = Ut(e, h);
886
+ const b = jt(e, h);
887
887
  b > d && (d = b, n = h);
888
888
  }
889
889
  g.warn(
@@ -892,14 +892,14 @@ function Ao(e, t = {}) {
892
892
  }
893
893
  return n;
894
894
  }
895
- function Po(e) {
896
- const o = Eo(e) || e, r = T(o);
895
+ function To(e) {
896
+ const o = Ao(e) || e, r = _(o);
897
897
  if (!r.isValid())
898
898
  return g.warn(`Invalid color provided: ${e}`), { r: 0, g: 0, b: 0 };
899
899
  const { r: s, g: i, b: a } = r.toRgb();
900
900
  return { r: s, g: i, b: a };
901
901
  }
902
- function O(e, t) {
902
+ function I(e, t) {
903
903
  const r = t ? {
904
904
  left: "start",
905
905
  right: "end",
@@ -911,7 +911,7 @@ function O(e, t) {
911
911
  }[t] : void 0;
912
912
  return e === "left" || e === "right" ? r || "center" : e === "top" || e === "bottom" ? r || "start" : r || "center";
913
913
  }
914
- function jt(e, t = "1rem", o = 1) {
914
+ function qt(e, t = "1rem", o = 1) {
915
915
  if (!e) return t;
916
916
  const r = {
917
917
  xs: 0.7,
@@ -930,7 +930,7 @@ function jt(e, t = "1rem", o = 1) {
930
930
  const l = parseFloat(i);
931
931
  return isNaN(l) ? t : `${l}rem`;
932
932
  }
933
- function To(e, t = "4px") {
933
+ function _o(e, t = "4px") {
934
934
  if (!e) return t;
935
935
  const o = {
936
936
  xs: "2px",
@@ -961,7 +961,7 @@ function ot(e) {
961
961
  }
962
962
  return t;
963
963
  }
964
- function _o(e, t, o) {
964
+ function Oo(e, t, o) {
965
965
  return ot({
966
966
  role: "button",
967
967
  ariaLabel: e,
@@ -969,7 +969,7 @@ function _o(e, t, o) {
969
969
  ariaDisabled: o
970
970
  });
971
971
  }
972
- function Oo(e, t, o, r = !1) {
972
+ function Io(e, t, o, r = !1) {
973
973
  return ot({
974
974
  role: r ? "radio" : "checkbox",
975
975
  ariaLabel: e,
@@ -977,38 +977,38 @@ function Oo(e, t, o, r = !1) {
977
977
  ariaDisabled: o
978
978
  });
979
979
  }
980
- function qt(e, t, o) {
980
+ function Ht(e, t, o) {
981
981
  typeof o == "boolean" ? e.setAttribute(t, o ? "true" : "false") : e.setAttribute(t, o);
982
982
  }
983
- function Io(e) {
983
+ function zo(e) {
984
984
  if (typeof e != "string")
985
985
  return !1;
986
986
  const t = e.replace(/[<>"']/g, "").trim();
987
987
  return /^(#[0-9a-fA-F]{3,8}|rgb\([^)]+\)|rgba\([^)]+\)|hsl\([^)]+\)|hsla\([^)]+\)|[a-zA-Z]+)$/.test(t);
988
988
  }
989
989
  function tt(e) {
990
- return Io(e) ? e.replace(/[<>"']/g, "").trim() : (g.warn("Invalid color value:", e), "#000000");
990
+ return zo(e) ? e.replace(/[<>"']/g, "").trim() : (g.warn("Invalid color value:", e), "#000000");
991
991
  }
992
- function zo(e) {
992
+ function Mo(e) {
993
993
  if (typeof e != "string")
994
994
  return g.warn("Non-string value passed to sanitizeCSS:", typeof e), "";
995
995
  let t = e;
996
996
  return t = t.replace(/@import[^;]+;/gi, "").replace(/expression\s*\([^)]*\)/gi, "").replace(/javascript:\s*[^"'\s;]*/gi, "").replace(/url\s*\(\s*["']?data:(?!image\/[^;]+;base64,)[^"')]*["']?\s*\)/gi, "").replace(/-moz-binding\s*:[^;]+;/gi, "").replace(/behavior\s*:[^;]+;/gi, ""), t;
997
997
  }
998
- function Mo(e) {
998
+ function Lo(e) {
999
999
  return typeof e != "string" || !e.trim() ? "" : e.replace(
1000
1000
  /([^{}:;]+):\s*([^;{}!]+)(\s*!important)?\s*(;|})/gi,
1001
1001
  (t, o, r, s, i) => s ? t : `${o}: ${r.trim()} !important${i}`
1002
1002
  );
1003
1003
  }
1004
- const Lo = "https://jpxwfjorwcsrqraorpbj.supabase.co/functions/v1/data", No = "pc_session_id", Do = 24 * 60 * 60 * 1e3;
1005
- function ye() {
1004
+ const No = "https://jpxwfjorwcsrqraorpbj.supabase.co/functions/v1/data", Do = "pc_session_id", Ro = 24 * 60 * 60 * 1e3;
1005
+ function xe() {
1006
1006
  return typeof crypto < "u" && typeof crypto.randomUUID == "function" ? crypto.randomUUID() : (g.warn("crypto.randomUUID not available, using fallback UUID generator"), "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g, function(e) {
1007
1007
  const t = Math.random() * 16 | 0;
1008
1008
  return (e === "x" ? t : t & 3 | 8).toString(16);
1009
1009
  }));
1010
1010
  }
1011
- function Xt() {
1011
+ function Jt() {
1012
1012
  const e = "test-local-storage";
1013
1013
  try {
1014
1014
  return localStorage.setItem(e, e), localStorage.removeItem(e), !0;
@@ -1016,7 +1016,7 @@ function Xt() {
1016
1016
  return g.warn("localStorage not available, session ID will not persist"), !1;
1017
1017
  }
1018
1018
  }
1019
- function Ne(e) {
1019
+ function De(e) {
1020
1020
  try {
1021
1021
  const t = localStorage.getItem(e);
1022
1022
  return t ? JSON.parse(t) : void 0;
@@ -1025,34 +1025,34 @@ function Ne(e) {
1025
1025
  return;
1026
1026
  }
1027
1027
  }
1028
- function De(e, t) {
1028
+ function Re(e, t) {
1029
1029
  try {
1030
1030
  return localStorage.setItem(e, JSON.stringify(t)), !0;
1031
1031
  } catch (o) {
1032
1032
  return g.warn(`Failed to set item in localStorage: ${e}`, o), !1;
1033
1033
  }
1034
1034
  }
1035
- async function xe() {
1036
- const e = No, t = Do;
1037
- if (Xt()) {
1038
- const o = Ne(e);
1035
+ async function we() {
1036
+ const e = Do, t = Ro;
1037
+ if (Jt()) {
1038
+ const o = De(e);
1039
1039
  if (o && o.id && o.timestamp && Date.now() - o.timestamp < t)
1040
1040
  return g.debug("Using existing session ID from localStorage"), o.id;
1041
1041
  g.debug(
1042
1042
  o ? "Session ID expired" : "No session ID found",
1043
1043
  "generating new one"
1044
1044
  );
1045
- const r = ye();
1046
- return De(e, {
1045
+ const r = xe();
1046
+ return Re(e, {
1047
1047
  id: r,
1048
1048
  timestamp: Date.now()
1049
1049
  }) ? g.debug("Generated and stored new session ID") : g.warn("Generated session ID but failed to store it"), r;
1050
1050
  } else {
1051
- const o = ye();
1051
+ const o = xe();
1052
1052
  return g.debug("Generated non-persistent session ID"), o;
1053
1053
  }
1054
1054
  }
1055
- function kt(e) {
1055
+ function At(e) {
1056
1056
  if (!e || typeof e != "object")
1057
1057
  return 0;
1058
1058
  let t = 0, o = 0, r = 0;
@@ -1065,7 +1065,7 @@ function kt(e) {
1065
1065
  const s = t / r * 100, i = o / r * 100;
1066
1066
  return Math.round(s - i);
1067
1067
  }
1068
- function Ro(e) {
1068
+ function Bo(e) {
1069
1069
  if (!e || typeof e != "object")
1070
1070
  return { promoters: 0, passives: 0, detractors: 0 };
1071
1071
  let t = 0, o = 0, r = 0;
@@ -1075,14 +1075,14 @@ function Ro(e) {
1075
1075
  }
1076
1076
  return { promoters: t, passives: o, detractors: r };
1077
1077
  }
1078
- function Bo(e, t) {
1078
+ function Vo(e, t) {
1079
1079
  const o = {};
1080
1080
  for (const r of t)
1081
1081
  o[r] = e[r] || 0;
1082
1082
  return o;
1083
1083
  }
1084
- function Vo(e, t) {
1085
- const o = t ? Bo(e, t) : e;
1084
+ function Uo(e, t) {
1085
+ const o = t ? Vo(e, t) : e;
1086
1086
  let r = 0, s = 0;
1087
1087
  for (const [a, l] of Object.entries(o)) {
1088
1088
  s += l;
@@ -1101,26 +1101,26 @@ function U() {
1101
1101
  updated: (/* @__PURE__ */ new Date()).toISOString()
1102
1102
  };
1103
1103
  }
1104
- function Uo(e) {
1105
- if (!Xt())
1104
+ function jo(e) {
1105
+ if (!Jt())
1106
1106
  return U();
1107
1107
  try {
1108
- const t = Ne(e);
1108
+ const t = De(e);
1109
1109
  return t ? { ...U(), ...t } : U();
1110
1110
  } catch (t) {
1111
1111
  return g.warn("Failed to load localStats from localStorage", t), U();
1112
1112
  }
1113
1113
  }
1114
- function jo(e, t) {
1115
- if (!Xt())
1114
+ function qo(e, t) {
1115
+ if (!Jt())
1116
1116
  return !1;
1117
1117
  try {
1118
- return De(e, t) ? (g.debug("Saved localStats to localStorage", t), !0) : !1;
1118
+ return Re(e, t) ? (g.debug("Saved localStats to localStorage", t), !0) : !1;
1119
1119
  } catch (o) {
1120
1120
  return g.warn("Failed to save localStats to localStorage", o), !1;
1121
1121
  }
1122
1122
  }
1123
- function qo(e, t) {
1123
+ function Ho(e, t) {
1124
1124
  const o = {
1125
1125
  count: Math.max(0, e.count - t.count),
1126
1126
  sum: (e.sum || 0) - (t.sum || 0),
@@ -1133,9 +1133,9 @@ function qo(e, t) {
1133
1133
  if (o.count > 0 && o.sum !== void 0 ? o.avg = Math.round(o.sum / o.count * 100) / 100 : o.avg = 0, t.breakdown && o.breakdown)
1134
1134
  for (const [r, s] of Object.entries(t.breakdown))
1135
1135
  o.breakdown[r] && (o.breakdown[r] = Math.max(0, o.breakdown[r] - s), o.breakdown[r] === 0 && delete o.breakdown[r]);
1136
- return o.nps = kt((o == null ? void 0 : o.breakdown) || {}), o;
1136
+ return o.nps = At((o == null ? void 0 : o.breakdown) || {}), o;
1137
1137
  }
1138
- function Ho(e, t) {
1138
+ function Fo(e, t) {
1139
1139
  if (!e.count && !t.count)
1140
1140
  return U();
1141
1141
  if (!e.count)
@@ -1154,12 +1154,12 @@ function Ho(e, t) {
1154
1154
  for (const [r, s] of Object.entries(t.breakdown))
1155
1155
  o.breakdown[r] = (o.breakdown[r] || 0) + s;
1156
1156
  }
1157
- return o.nps = kt((o == null ? void 0 : o.breakdown) || {}), o;
1157
+ return o.nps = At((o == null ? void 0 : o.breakdown) || {}), o;
1158
1158
  }
1159
- function Re(e) {
1159
+ function Be(e) {
1160
1160
  return !e || typeof e != "string" ? !1 : /^[\p{Emoji}]$/u.test(e) ? !0 : new RegExp("^\\p{Emoji}(\\p{Emoji_Modifier}|\\u200D\\p{Emoji})*$", "u").test(e);
1161
1161
  }
1162
- function Tt(e) {
1162
+ function Ot(e) {
1163
1163
  if (!e || typeof e != "string")
1164
1164
  return !1;
1165
1165
  const t = e.trim();
@@ -1173,7 +1173,7 @@ function Tt(e) {
1173
1173
  return !1;
1174
1174
  }
1175
1175
  }
1176
- function Be(e) {
1176
+ function Ve(e) {
1177
1177
  if (!e || typeof e != "string")
1178
1178
  return [];
1179
1179
  const t = e.trim();
@@ -1188,44 +1188,57 @@ function Be(e) {
1188
1188
  }
1189
1189
  return t.split(",").map((o) => o.trim()).filter((o) => o !== "");
1190
1190
  }
1191
- function Fo(e, t) {
1191
+ function Yo(e, t) {
1192
1192
  const o = /{([^{}]+)}/g;
1193
1193
  return e.replace(o, (r, s) => {
1194
1194
  const i = s.trim(), a = t[i];
1195
1195
  return a !== void 0 ? String(a) : r;
1196
1196
  });
1197
1197
  }
1198
- function Yo(e, t) {
1198
+ function Ko(e, t) {
1199
1199
  let o = 2166136261;
1200
1200
  const r = e + ":" + t;
1201
1201
  for (let s = 0; s < r.length; s++)
1202
1202
  o ^= r.charCodeAt(s), o += (o << 1) + (o << 4) + (o << 7) + (o << 8) + (o << 24);
1203
1203
  return (o >>> 0).toString(16).padStart(8, "0");
1204
1204
  }
1205
- function Ko(e, t = 50) {
1205
+ function Wo(e, t = 50) {
1206
1206
  return e.length <= t ? e : e.substring(0, t).trim() + "...";
1207
1207
  }
1208
- const Wo = /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i, we = 5;
1209
- function Ve(e) {
1210
- return e || Lo;
1208
+ function xt(e) {
1209
+ if (!e) return;
1210
+ const t = e.trim().toLowerCase().replace(/[^a-z0-9-]/g, "-").replace(/-{2,}/g, "-").replace(/^-|-$/g, "");
1211
+ return t.length > 0 ? t : void 0;
1211
1212
  }
1212
- function Ue(e, t) {
1213
- const o = Ve(t);
1214
- return e.type === "registered" ? `${o}/widgets/${encodeURIComponent(e.widgetId)}` : `${o}/public-widgets/${encodeURIComponent(e.name)}`;
1213
+ const Go = /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i, $e = 5;
1214
+ function Ue(e) {
1215
+ return e || No;
1215
1216
  }
1216
- async function $e(e, t) {
1217
- const o = Ue(e, t);
1218
- g.debug("API GET", { url: o });
1219
- const r = await fetch(o);
1220
- if (!r.ok)
1221
- throw new Error(`API request failed with status: ${r.status}`);
1222
- const s = await r.json();
1223
- if (!s.success)
1224
- throw new Error("Backend returned unsuccessful response");
1217
+ function je(e, t, o) {
1218
+ const r = Ue(t);
1219
+ let s;
1220
+ if (e.type === "registered" ? s = `${r}/widgets/${encodeURIComponent(e.widgetId)}` : s = `${r}/public-widgets/${encodeURIComponent(e.name)}`, o) {
1221
+ const i = new URLSearchParams();
1222
+ for (const [l, n] of Object.entries(o))
1223
+ n && i.set(l, n);
1224
+ const a = i.toString();
1225
+ a && (s += `?${a}`);
1226
+ }
1225
1227
  return s;
1226
1228
  }
1227
- async function Go(e, t, o) {
1228
- const r = Ue(e, o);
1229
+ async function Se(e, t, o) {
1230
+ const r = je(e, t, o);
1231
+ g.debug("API GET", { url: r });
1232
+ const s = await fetch(r);
1233
+ if (!s.ok)
1234
+ throw new Error(`API request failed with status: ${s.status}`);
1235
+ const i = await s.json();
1236
+ if (!i.success)
1237
+ throw new Error("Backend returned unsuccessful response");
1238
+ return i;
1239
+ }
1240
+ async function Zo(e, t, o) {
1241
+ const r = je(e, o);
1229
1242
  if (g.debug("API POST", { url: r }), typeof navigator < "u" && navigator.sendBeacon) {
1230
1243
  if (navigator.sendBeacon(r, t)) {
1231
1244
  g.debug("Successfully sent stats via sendBeacon");
@@ -1245,7 +1258,7 @@ async function Go(e, t, o) {
1245
1258
  throw new Error(`API request failed with status: ${s.status}`);
1246
1259
  g.debug("Successfully sent stats via fetch");
1247
1260
  }
1248
- class Zo {
1261
+ class Xo {
1249
1262
  // Set when a fatal error occurs (e.g. type mismatch for registered widget)
1250
1263
  constructor(t) {
1251
1264
  this.stats = U(), this.localStats = U(), this.isLoading = !0, this.isLoadingConfig = !1, this.isSubmitting = !1, this.hasInteracted = !1, this.hasError = !1, (this.host = t).addController(this);
@@ -1259,13 +1272,13 @@ class Zo {
1259
1272
  */
1260
1273
  getWidgetIdentifier() {
1261
1274
  const t = this.host;
1262
- return t.widgetId ? Wo.test(t.widgetId) ? { type: "registered", widgetId: t.widgetId } : (g.error(`Invalid widget-id format: ${t.widgetId}`), null) : t.name ? t.name.length < we ? (g.error(
1263
- `Widget name must be at least ${we} characters long. Got: "${t.name}"`
1275
+ return t.widgetId ? Go.test(t.widgetId) ? { type: "registered", widgetId: t.widgetId } : (g.error(`Invalid widget-id format: ${t.widgetId}`), null) : t.name ? t.name.length < $e ? (g.error(
1276
+ `Widget name must be at least ${$e} characters long. Got: "${t.name}"`
1264
1277
  ), null) : { type: "public", name: t.name } : (g.error("Widget requires either widget-id or name attribute"), null);
1265
1278
  }
1266
1279
  async getLocalStatsKey() {
1267
- const t = this.host, o = await xe(), r = t.widgetId || t.name || "unnamed";
1268
- return `pc-local-stats-${o}-${r}`;
1280
+ const t = this.host, o = await we(), r = t.widgetId || t.name || "unnamed", s = xt(t.metadata), i = s ? `-${s}` : "";
1281
+ return `pc-local-stats-${o}-${r}${i}`;
1269
1282
  }
1270
1283
  /**
1271
1284
  * while 'hostConnected' is not async, we need to use this wrapper function
@@ -1288,7 +1301,7 @@ class Zo {
1288
1301
  for (const [l, n] of Object.entries(o)) {
1289
1302
  if (n == null) continue;
1290
1303
  if (l === "options" && typeof n == "string") {
1291
- const p = Be(n);
1304
+ const p = Ve(n);
1292
1305
  r.options = p.map((h) => ({
1293
1306
  value: h,
1294
1307
  label: h,
@@ -1317,54 +1330,54 @@ class Zo {
1317
1330
  let n, d;
1318
1331
  if (o.type === "registered") {
1319
1332
  this.isLoadingConfig = !0, this.host.requestUpdate();
1320
- const C = await $e(o), x = (s = (r = C.data) == null ? void 0 : r.config) == null ? void 0 : s.type;
1321
- if (x && x !== t.type) {
1333
+ const C = xt(t.metadata), A = await Se(o, void 0, C ? { meta: C } : void 0), P = (s = (r = A.data) == null ? void 0 : r.config) == null ? void 0 : s.type;
1334
+ if (P && P !== t.type) {
1322
1335
  g.error(
1323
- `Widget type mismatch: type="${t.type}" but server returned "${x}" for widget-id="${o.widgetId}"`
1336
+ `Widget type mismatch: type="${t.type}" but server returned "${P}" for widget-id="${o.widgetId}"`
1324
1337
  ), this.hasError = !0;
1325
1338
  return;
1326
1339
  }
1327
- const P = ((a = (i = C.data) == null ? void 0 : i.config) == null ? void 0 : a.attributes) || null;
1328
- n = ((l = C.data) == null ? void 0 : l.stats) || {}, this.applyWidgetAttributes(P);
1340
+ const at = ((a = (i = A.data) == null ? void 0 : i.config) == null ? void 0 : a.attributes) || null;
1341
+ n = ((l = A.data) == null ? void 0 : l.stats) || {}, this.applyWidgetAttributes(at);
1329
1342
  } else {
1330
1343
  let C;
1331
1344
  if (t.dataFunc && typeof window < "u") {
1332
- const P = t.dataFunc.replace(/^window\./, "").split(".");
1333
- let z = window;
1334
- for (const It of P)
1335
- if (z = z == null ? void 0 : z[It], z === void 0) break;
1336
- C = z;
1345
+ const A = t.dataFunc.replace(/^window\./, "").split(".");
1346
+ let P = window;
1347
+ for (const at of A)
1348
+ if (P = P == null ? void 0 : P[at], P === void 0) break;
1349
+ C = P;
1337
1350
  }
1338
1351
  if (C && typeof C == "function") {
1339
1352
  d = this.getValidOptionKeys(t), g.debug(`Using data function for: ${t.widgetId || t.name}`, {
1340
1353
  dataFuncName: t.dataFunc,
1341
1354
  options: d
1342
1355
  });
1343
- const x = await C(t.widgetId, t.name, d);
1344
- if (x && typeof x == "object" && "success" in x && "data" in x) {
1345
- if (!x.success)
1346
- throw g.error("Custom data function returned unsuccessful response", x), new Error("Custom data function returned unsuccessful response");
1347
- n = x.data || {};
1356
+ const w = await C(t.widgetId, t.name, d);
1357
+ if (w && typeof w == "object" && "success" in w && "data" in w) {
1358
+ if (!w.success)
1359
+ throw g.error("Custom data function returned unsuccessful response", w), new Error("Custom data function returned unsuccessful response");
1360
+ n = w.data || {};
1348
1361
  } else
1349
- n = x || {};
1362
+ n = w || {};
1350
1363
  } else
1351
- n = (await $e(o, t.dataEndpoint)).data || {};
1364
+ n = (await Se(o, t.dataEndpoint)).data || {};
1352
1365
  }
1353
1366
  d ?? (d = this.getValidOptionKeys(t));
1354
- const p = Vo(n.breakdown ?? {}, d), h = p.count, b = p.sum, w = h > 0 ? Math.round(b / h * 10) / 10 : 0, E = h > 0 ? Math.round(b / h * 100) : 0;
1367
+ const p = Uo(n.breakdown ?? {}, d), h = p.count, b = p.sum, x = h > 0 ? Math.round(b / h * 10) / 10 : 0, E = h > 0 ? Math.round(b / h * 100) : 0;
1355
1368
  this.stats = {
1356
1369
  count: h,
1357
1370
  sum: b,
1358
- avg: w,
1371
+ avg: x,
1359
1372
  pct: E,
1360
- nps: t.type === $.nps ? kt(p.breakdown) : 0,
1373
+ nps: t.type === $.nps ? At(p.breakdown) : 0,
1361
1374
  breakdown: p.breakdown,
1362
1375
  updated: n.updatedAt || n.updated_at || (/* @__PURE__ */ new Date()).toISOString()
1363
1376
  };
1364
1377
  } catch (n) {
1365
1378
  throw g.error("Error loading stats:", n, this.localStats), n;
1366
1379
  } finally {
1367
- this.isLoading = !1, this.isLoadingConfig = !1, this.host.requestUpdate();
1380
+ this.isLoading = !1, this.isLoadingConfig = !1, this.host.requestUpdate(), await this.host.updateComplete, this.dispatchInitEvent();
1368
1381
  }
1369
1382
  }
1370
1383
  /**
@@ -1393,7 +1406,7 @@ class Zo {
1393
1406
  async loadLocalStats() {
1394
1407
  const t = await this.getLocalStatsKey();
1395
1408
  try {
1396
- const o = Uo(t);
1409
+ const o = jo(t);
1397
1410
  g.debug("Loaded localStats from localStorage", o), this.localStats = o;
1398
1411
  } catch (o) {
1399
1412
  g.warn("Failed to generate localStorage key for localStats", o), this.localStats = U();
@@ -1406,7 +1419,7 @@ class Zo {
1406
1419
  async persistLocalStats() {
1407
1420
  try {
1408
1421
  const t = await this.getLocalStatsKey();
1409
- jo(t, this.localStats) || g.warn("Failed to save localStats to localStorage");
1422
+ qo(t, this.localStats) || g.warn("Failed to save localStats to localStorage");
1410
1423
  } catch (t) {
1411
1424
  g.warn("Failed to save localStats to localStorage", t);
1412
1425
  }
@@ -1420,7 +1433,7 @@ class Zo {
1420
1433
  * @param textValues
1421
1434
  */
1422
1435
  updateStats(t, o) {
1423
- if (this.hasInteracted = !0, this.stats && (this.stats = qo(this.stats, this.localStats)), this.localStats = {
1436
+ if (this.hasInteracted = !0, this.stats && (this.stats = Ho(this.stats, this.localStats)), this.localStats = {
1424
1437
  count: t > 0 || o.length > 0 ? 1 : 0,
1425
1438
  sum: t,
1426
1439
  // e.g. number of stars, nps value
@@ -1434,7 +1447,7 @@ class Zo {
1434
1447
  }, o && o.length > 0)
1435
1448
  for (const r of o)
1436
1449
  r && (this.localStats.breakdown[r] = 1);
1437
- this.stats = Ho(this.stats, this.localStats), g.debug("Stats updated - remote: ", this.stats), g.debug("Stats updated - local: ", this.localStats), this.persistLocalStats(), this.host.requestUpdate();
1450
+ this.stats = Fo(this.stats, this.localStats), g.debug("Stats updated - remote: ", this.stats), g.debug("Stats updated - local: ", this.localStats), this.persistLocalStats(), this.host.requestUpdate();
1438
1451
  }
1439
1452
  async markStatsAsSubmitted() {
1440
1453
  this.localStats.submitted = (/* @__PURE__ */ new Date()).toISOString(), await this.persistLocalStats(), this.host.requestUpdate();
@@ -1442,7 +1455,7 @@ class Zo {
1442
1455
  async submitStats() {
1443
1456
  if (!this.hasLocalStats() && !this.hasInteracted)
1444
1457
  throw g.warn("No local stats to submit"), new Error("No local stats to submit");
1445
- const t = this.host, o = Math.floor(Date.now() / 1e3).toString(), r = await xe(), s = this.localStats.sum, i = Object.keys(this.localStats.breakdown || {});
1458
+ const t = this.host, o = Math.floor(Date.now() / 1e3).toString(), r = await we(), s = this.localStats.sum, i = Object.keys(this.localStats.breakdown || {});
1446
1459
  this.isSubmitting = !0, this.host.requestUpdate();
1447
1460
  const a = {
1448
1461
  sessionId: r,
@@ -1452,9 +1465,9 @@ class Zo {
1452
1465
  url: window.location.href,
1453
1466
  numericValue: s,
1454
1467
  textValues: i,
1455
- metadata: t.metadata,
1468
+ metadata: xt(t.metadata),
1456
1469
  timestamp: o
1457
- }, l = Yo(JSON.stringify(a), o);
1470
+ }, l = Ko(JSON.stringify(a), o);
1458
1471
  try {
1459
1472
  await this.sendStats({ ...a, hash: l }), await this.markStatsAsSubmitted(), this.dispatchSubmitEvent(a);
1460
1473
  } catch (n) {
@@ -1471,12 +1484,12 @@ class Zo {
1471
1484
  g.debug("Skip sending stats as data function is in use.");
1472
1485
  return;
1473
1486
  }
1474
- const s = r.type === "registered" ? void 0 : o.dataEndpoint, i = Ve(s);
1475
- if (!Tt(i))
1487
+ const s = r.type === "registered" ? void 0 : o.dataEndpoint, i = Ue(s);
1488
+ if (!Ot(i))
1476
1489
  throw g.error("Invalid data endpoint", { dataEndpoint: i }), new Error(`Invalid data endpoint: ${i}`);
1477
1490
  const a = JSON.stringify(t);
1478
1491
  try {
1479
- await Go(r, a, s);
1492
+ await Zo(r, a, s);
1480
1493
  } catch (l) {
1481
1494
  throw g.error("Failed to send analytics:", l), l;
1482
1495
  }
@@ -1493,9 +1506,9 @@ class Zo {
1493
1506
  sum: (o == null ? void 0 : o.sum) || 0,
1494
1507
  avg: s,
1495
1508
  pct: (o == null ? void 0 : o.pct) || 0,
1496
- nps: r.type === $.nps ? kt((o == null ? void 0 : o.breakdown) || {}) : 0
1509
+ nps: r.type === $.nps ? At((o == null ? void 0 : o.breakdown) || {}) : 0
1497
1510
  };
1498
- return g.debug("Stats data: ", this.stats), Fo(t, i);
1511
+ return g.debug("Stats data: ", this.stats), Yo(t, i);
1499
1512
  }
1500
1513
  /**
1501
1514
  * Checks if a value is selected in the local stats
@@ -1547,7 +1560,7 @@ class Zo {
1547
1560
  widgetName: t.name,
1548
1561
  numericValue: o,
1549
1562
  textValues: r,
1550
- metadata: t.metadata,
1563
+ metadata: xt(t.metadata),
1551
1564
  url: typeof window < "u" ? window.location.href : "",
1552
1565
  timestamp: Math.floor(Date.now() / 1e3).toString()
1553
1566
  }, i = new CustomEvent("change", {
@@ -1569,6 +1582,23 @@ class Zo {
1569
1582
  });
1570
1583
  o.dispatchEvent(r), g.debug("Dispatched submit event", t);
1571
1584
  }
1585
+ /**
1586
+ * Dispatches an 'init' CustomEvent on the host element
1587
+ * This event fires once after data has loaded and the widget has rendered
1588
+ */
1589
+ dispatchInitEvent() {
1590
+ const t = this.host, o = new CustomEvent("init", {
1591
+ detail: {
1592
+ widgetId: t.widgetId,
1593
+ widgetName: t.name,
1594
+ widgetType: t.type,
1595
+ stats: this.stats
1596
+ },
1597
+ bubbles: !0,
1598
+ composed: !0
1599
+ });
1600
+ t.dispatchEvent(o), g.debug("Dispatched init event");
1601
+ }
1572
1602
  hasLocalStats() {
1573
1603
  var t;
1574
1604
  return ((t = this.localStats) == null ? void 0 : t.count) > 0;
@@ -1582,7 +1612,7 @@ class Zo {
1582
1612
  return ((t = this.localStats) == null ? void 0 : t.submitted) !== void 0 && this.hasLocalStats();
1583
1613
  }
1584
1614
  }
1585
- class Xo {
1615
+ class Jo {
1586
1616
  constructor(t, o) {
1587
1617
  this.isEditing = !0, this.isChartVisible = !1, this.isStatsVisible = !1, this.isThankYouVisible = !1, this.isReactionPopoverVisible = !1, this.initialized = !1, this.handleClickOutside = (r) => {
1588
1618
  r.target !== this.host && (this.toggleThankYouVisibility(!1), this.toggleReactionPopoverVisibility(!1));
@@ -1670,8 +1700,8 @@ class Xo {
1670
1700
  return !(this.host.readonly || !this.isEditing);
1671
1701
  }
1672
1702
  }
1673
- var Jt = /* @__PURE__ */ ((e) => (e.DECORATIVE = "decorative", e.FUNCTIONAL = "functional", e.STATUS = "status", e))(Jt || {});
1674
- function je(e, t = {}) {
1703
+ var Qt = /* @__PURE__ */ ((e) => (e.DECORATIVE = "decorative", e.FUNCTIONAL = "functional", e.STATUS = "status", e))(Qt || {});
1704
+ function qe(e, t = {}) {
1675
1705
  const { type: o = "functional", alt: r, ariaLabel: s, isSelected: i } = t;
1676
1706
  if (!e)
1677
1707
  return { alt: "", ariaHidden: !0 };
@@ -1680,20 +1710,20 @@ function je(e, t = {}) {
1680
1710
  o === "functional" && !r && !s && console.warn(
1681
1711
  "No alt text or aria-label provided for functional icon. This may cause accessibility issues."
1682
1712
  );
1683
- const a = i ? " (selected)" : "", l = Tt(e) && !r ? "" : r || e, n = s || (l ? `${l}${a}` : a);
1713
+ const a = i ? " (selected)" : "", l = Ot(e) && !r ? "" : r || e, n = s || (l ? `${l}${a}` : a);
1684
1714
  return {
1685
1715
  alt: l,
1686
1716
  ariaLabel: n,
1687
1717
  ariaHidden: !1
1688
1718
  };
1689
1719
  }
1690
- function Jo(e, t = "polite") {
1720
+ function Qo(e, t = "polite") {
1691
1721
  let o = document.getElementById("screen-reader-announcer");
1692
1722
  o ? o.setAttribute("aria-live", t) : (o = document.createElement("div"), o.id = "screen-reader-announcer", o.setAttribute("aria-live", t), o.setAttribute("role", "status"), o.setAttribute("aria-atomic", "true"), o.style.position = "absolute", o.style.width = "1px", o.style.height = "1px", o.style.margin = "-1px", o.style.padding = "0", o.style.overflow = "hidden", o.style.clip = "rect(0, 0, 0, 0)", o.style.whiteSpace = "nowrap", o.style.border = "0", document.body.appendChild(o)), o.textContent = "", setTimeout(() => {
1693
1723
  o.textContent = e;
1694
1724
  }, 50);
1695
1725
  }
1696
- function Qo(e, t) {
1726
+ function tr(e, t) {
1697
1727
  return `${e}: ${t}`;
1698
1728
  }
1699
1729
  /**
@@ -1701,8 +1731,8 @@ function Qo(e, t) {
1701
1731
  * Copyright 2017 Google LLC
1702
1732
  * SPDX-License-Identifier: BSD-3-Clause
1703
1733
  */
1704
- const qe = { ATTRIBUTE: 1 }, He = (e) => (...t) => ({ _$litDirective$: e, values: t });
1705
- let Fe = class {
1734
+ const He = { ATTRIBUTE: 1 }, Fe = (e) => (...t) => ({ _$litDirective$: e, values: t });
1735
+ let Ye = class {
1706
1736
  constructor(t) {
1707
1737
  }
1708
1738
  get _$AU() {
@@ -1723,10 +1753,10 @@ let Fe = class {
1723
1753
  * Copyright 2018 Google LLC
1724
1754
  * SPDX-License-Identifier: BSD-3-Clause
1725
1755
  */
1726
- const y = He(class extends Fe {
1756
+ const y = Fe(class extends Ye {
1727
1757
  constructor(e) {
1728
1758
  var t;
1729
- if (super(e), e.type !== qe.ATTRIBUTE || e.name !== "class" || ((t = e.strings) == null ? void 0 : t.length) > 2) throw Error("`classMap()` can only be used in the `class` attribute and must be the only part in the attribute.");
1759
+ if (super(e), e.type !== He.ATTRIBUTE || e.name !== "class" || ((t = e.strings) == null ? void 0 : t.length) > 2) throw Error("`classMap()` can only be used in the `class` attribute and must be the only part in the attribute.");
1730
1760
  }
1731
1761
  render(e) {
1732
1762
  return " " + Object.keys(e).filter((t) => e[t]).join(" ") + " ";
@@ -1747,18 +1777,18 @@ const y = He(class extends Fe {
1747
1777
  return q;
1748
1778
  }
1749
1779
  });
1750
- var tr = Object.defineProperty, v = (e, t, o, r) => {
1780
+ var er = Object.defineProperty, v = (e, t, o, r) => {
1751
1781
  for (var s = void 0, i = e.length - 1, a; i >= 0; i--)
1752
1782
  (a = e[i]) && (s = a(t, o, s) || s);
1753
- return s && tr(t, o, s), s;
1783
+ return s && er(t, o, s), s;
1754
1784
  };
1755
- const yt = {
1785
+ const wt = {
1756
1786
  mobile: "480px",
1757
1787
  tablet: "768px",
1758
1788
  desktop: "1024px"
1759
- }, Qt = class Qt extends N {
1789
+ }, te = class te extends N {
1760
1790
  constructor() {
1761
- super(...arguments), this.dataController = new Zo(this), this.displayController = new Xo(this, this.dataController), this.hasEditButton = !0, this.showStats = "never", this.showChart = !1, this.initialized = !1, this.ariaLabel = null, this.minContrast = Le.AA_NORMAL, this.options = [], this.questionPosition = "top", this.statsText = "{count} votes", this.buttonText = "Submit", this.buttonRadius = "sm", this.multiple = !1, this.inline = !1, this.readonly = !1, this.handleEditToggleKeyDown = (t) => {
1791
+ super(...arguments), this.dataController = new Xo(this), this.displayController = new Jo(this, this.dataController), this.hasEditButton = !0, this.showStats = "never", this.showChart = !1, this.initialized = !1, this.ariaLabel = null, this.minContrast = Ne.AA_NORMAL, this.options = [], this.questionPosition = "top", this.statsText = "{count} votes", this.buttonText = "Submit", this.buttonRadius = "sm", this.multiple = !1, this.inline = !1, this.readonly = !1, this.handleEditToggleKeyDown = (t) => {
1762
1792
  (t.key === "Enter" || t.key === " ") && (t.preventDefault(), this.handleEnterEditMode());
1763
1793
  };
1764
1794
  }
@@ -1793,7 +1823,7 @@ const yt = {
1793
1823
  const i = tt(this.primaryColor);
1794
1824
  o += `--pc-primary-color: ${i} !important;
1795
1825
  `;
1796
- const a = Ao(i, {
1826
+ const a = Po(i, {
1797
1827
  minContrast: this.minContrast,
1798
1828
  colorOptions: ["black", "white", "light", "dark"]
1799
1829
  });
@@ -1824,33 +1854,33 @@ const yt = {
1824
1854
  const s = this.starHoverColor || (r ? `color-mix(in srgb, ${tt(r)} 80%, white)` : null);
1825
1855
  if (s && (o += `--pc-star-hover-color: ${s} !important;
1826
1856
  `), this.starSize) {
1827
- const i = jt(this.starSize, "1.5em", 1.5);
1857
+ const i = qt(this.starSize, "1.5em", 1.5);
1828
1858
  o += `--pc-stars-star-size: ${i} !important;
1829
1859
  `;
1830
1860
  }
1831
1861
  if (this.reactionSize) {
1832
- const i = jt(this.reactionSize, "1em", 1);
1862
+ const i = qt(this.reactionSize, "1em", 1);
1833
1863
  o += `--pc-reaction-size: ${i} !important;
1834
1864
  `;
1835
1865
  }
1836
1866
  if (this.size) {
1837
- const i = jt(this.size);
1867
+ const i = qt(this.size);
1838
1868
  o += `font-size: ${i} !important;
1839
1869
  `;
1840
1870
  }
1841
1871
  if (this.buttonRadius) {
1842
- const i = To(this.buttonRadius);
1872
+ const i = _o(this.buttonRadius);
1843
1873
  o += `--pc-button-radius: ${i} !important;
1844
1874
  `;
1845
1875
  }
1846
1876
  o += `}
1847
- `, this.css && (o += Mo(zo(this.css))), t.textContent = o;
1877
+ `, this.css && (o += Lo(Mo(this.css))), t.textContent = o;
1848
1878
  }
1849
1879
  /**
1850
1880
  * Update ARIA attributes for accessibility
1851
1881
  */
1852
1882
  updateAriaAttributes() {
1853
- this.ariaLabel && qt(this, "aria-label", this.ariaLabel), this.ariaDescribedby && qt(this, "aria-describedby", this.ariaDescribedby), qt(this, "aria-busy", this.dataController.isLoading ? "true" : "false");
1883
+ this.ariaLabel && Ht(this, "aria-label", this.ariaLabel), this.ariaDescribedby && Ht(this, "aria-describedby", this.ariaDescribedby), Ht(this, "aria-busy", this.dataController.isLoading ? "true" : "false");
1854
1884
  }
1855
1885
  /**
1856
1886
  * Update host CSS classes based on state
@@ -1863,11 +1893,11 @@ const yt = {
1863
1893
  */
1864
1894
  getBreakpointClasses() {
1865
1895
  return {
1866
- "pc-mobile": window.matchMedia(`(max-width: ${yt.mobile})`).matches,
1896
+ "pc-mobile": window.matchMedia(`(max-width: ${wt.mobile})`).matches,
1867
1897
  "pc-tablet": window.matchMedia(
1868
- `(min-width: ${yt.mobile}) and (max-width: ${yt.tablet})`
1898
+ `(min-width: ${wt.mobile}) and (max-width: ${wt.tablet})`
1869
1899
  ).matches,
1870
- "pc-desktop": window.matchMedia(`(min-width: ${yt.desktop})`).matches
1900
+ "pc-desktop": window.matchMedia(`(min-width: ${wt.desktop})`).matches
1871
1901
  };
1872
1902
  }
1873
1903
  /**
@@ -1875,7 +1905,7 @@ const yt = {
1875
1905
  */
1876
1906
  announceSelectionChange(t, o, r) {
1877
1907
  const s = `Poll for "${t}"`, i = r ? `${o.label} selected` : `${o.label} unselected`;
1878
- Jo(Qo(s, i));
1908
+ Qo(tr(s, i));
1879
1909
  }
1880
1910
  /** Common render methods */
1881
1911
  renderLabel() {
@@ -1906,7 +1936,7 @@ const yt = {
1906
1936
  tabindex="0"
1907
1937
  aria-label="Edit vote"
1908
1938
  @keydown="${this.handleEditToggleKeyDown}"
1909
- >${Ct}</span
1939
+ >${Et}</span
1910
1940
  >
1911
1941
  ` : u;
1912
1942
  }
@@ -1925,7 +1955,7 @@ const yt = {
1925
1955
  tabindex="0"
1926
1956
  aria-label="${this.displayController.isChartVisible ? "Hide chart" : "Show chart"}"
1927
1957
  @keydown="${() => this.displayController.toggleChartVisibility()}"
1928
- >${this.displayController.isChartVisible ? Zt : Gt}</span
1958
+ >${this.displayController.isChartVisible ? Xt : Zt}</span
1929
1959
  >
1930
1960
  ` : u;
1931
1961
  }
@@ -1934,7 +1964,7 @@ const yt = {
1934
1964
  return u;
1935
1965
  const o = {
1936
1966
  "pc-status": !0,
1937
- [`pc-flex-content-${O(this.statsPosition, this.statsAlign)}`]: !0
1967
+ [`pc-flex-content-${I(this.statsPosition, this.statsAlign)}`]: !0
1938
1968
  };
1939
1969
  return c`<div class="${y(o)}" data-testid="pc-status">
1940
1970
  ${this.renderStatsText()} ${this.renderChartToggle()} ${this.renderEditToggleIcon()}
@@ -1952,7 +1982,7 @@ const yt = {
1952
1982
  renderThankYouMessage() {
1953
1983
  if (!this.displayController.shouldDisplayThankYouMsg())
1954
1984
  return u;
1955
- const t = Ko(this.thankYouMsg || "");
1985
+ const t = Wo(this.thankYouMsg || "");
1956
1986
  return c`
1957
1987
  <div class="pc-thank-you-overlay" data-testid="poll-thank-you-overlay">
1958
1988
  <div class="pc-thank-you" data-testid="thank-you">
@@ -1964,7 +1994,7 @@ const yt = {
1964
1994
  @click="${() => this.displayController.toggleThankYouVisibility(!1)}"
1965
1995
  role="button"
1966
1996
  aria-label="Close"
1967
- >${Pt}</span
1997
+ >${_t}</span
1968
1998
  >
1969
1999
  </div>
1970
2000
  </div>
@@ -1972,7 +2002,7 @@ const yt = {
1972
2002
  `;
1973
2003
  }
1974
2004
  };
1975
- Qt.styles = [
2005
+ te.styles = [
1976
2006
  R`
1977
2007
  :host {
1978
2008
  /* Default values for CSS variables - can be overridden by external :root or parent definitions */
@@ -2053,7 +2083,7 @@ Qt.styles = [
2053
2083
  }
2054
2084
  `
2055
2085
  ];
2056
- let m = Qt;
2086
+ let m = te;
2057
2087
  v([
2058
2088
  f({ type: String, attribute: "show-stats" })
2059
2089
  ], m.prototype, "showStats");
@@ -2159,7 +2189,7 @@ v([
2159
2189
  v([
2160
2190
  f({ type: Boolean, reflect: !0 })
2161
2191
  ], m.prototype, "readonly");
2162
- const er = R`
2192
+ const or = R`
2163
2193
  /* CSS variables inherit from parent - defaults are specified at usage sites */
2164
2194
 
2165
2195
  .pc-body {
@@ -2610,7 +2640,7 @@ const er = R`
2610
2640
  animation: none;
2611
2641
  }
2612
2642
  }
2613
- `, _t = R`
2643
+ `, It = R`
2614
2644
  /* Default values for CSS variables - can be overridden by external :root or parent definitions */
2615
2645
  :host {
2616
2646
  --default-primary-color: #2196f3;
@@ -3329,7 +3359,7 @@ const er = R`
3329
3359
  opacity: 1;
3330
3360
  }
3331
3361
  }
3332
- `, or = R`
3362
+ `, rr = R`
3333
3363
  :host {
3334
3364
  --popover-bg: light-dark(#ffffff, #1a1a1a);
3335
3365
  --popover-border: light-dark(#e0e0e0, #333333);
@@ -3451,12 +3481,12 @@ const er = R`
3451
3481
  max-width: 100%;
3452
3482
  }
3453
3483
  `;
3454
- var rr = Object.defineProperty, sr = Object.getOwnPropertyDescriptor, B = (e, t, o, r) => {
3455
- for (var s = r > 1 ? void 0 : r ? sr(t, o) : t, i = e.length - 1, a; i >= 0; i--)
3484
+ var sr = Object.defineProperty, ir = Object.getOwnPropertyDescriptor, B = (e, t, o, r) => {
3485
+ for (var s = r > 1 ? void 0 : r ? ir(t, o) : t, i = e.length - 1, a; i >= 0; i--)
3456
3486
  (a = e[i]) && (s = (r ? a(t, o, s) : a(s)) || s);
3457
- return r && s && rr(t, o, s), s;
3487
+ return r && s && sr(t, o, s), s;
3458
3488
  };
3459
- let _ = class extends N {
3489
+ let O = class extends N {
3460
3490
  constructor() {
3461
3491
  super(...arguments), this.open = !1, this.position = "auto", this.isClosing = !1, this.computedPosition = "bottom", this.popoverStyles = {}, this.arrowStyles = {}, this.updatePosition = () => {
3462
3492
  var h;
@@ -3464,8 +3494,8 @@ let _ = class extends N {
3464
3494
  const e = this.anchor.getBoundingClientRect(), t = window.innerWidth, o = window.innerHeight, r = 12, s = (h = this.popoverElement) == null ? void 0 : h.getBoundingClientRect(), i = (s == null ? void 0 : s.width) || 280, a = (s == null ? void 0 : s.height) || 200;
3465
3495
  let l = this.position;
3466
3496
  if (l === "auto") {
3467
- const b = o - e.bottom, w = e.top;
3468
- l = b >= a + r || b >= w ? "bottom" : "top";
3497
+ const b = o - e.bottom, x = e.top;
3498
+ l = b >= a + r || b >= x ? "bottom" : "top";
3469
3499
  }
3470
3500
  this.computedPosition = l;
3471
3501
  let n, d;
@@ -3545,35 +3575,35 @@ let _ = class extends N {
3545
3575
  `;
3546
3576
  }
3547
3577
  };
3548
- _.styles = [or];
3578
+ O.styles = [rr];
3549
3579
  B([
3550
3580
  f({ type: Boolean, reflect: !0 })
3551
- ], _.prototype, "open", 2);
3581
+ ], O.prototype, "open", 2);
3552
3582
  B([
3553
3583
  f({ type: String })
3554
- ], _.prototype, "position", 2);
3584
+ ], O.prototype, "position", 2);
3555
3585
  B([
3556
3586
  f({ attribute: !1 })
3557
- ], _.prototype, "anchor", 2);
3587
+ ], O.prototype, "anchor", 2);
3558
3588
  B([
3559
3589
  k()
3560
- ], _.prototype, "isClosing", 2);
3590
+ ], O.prototype, "isClosing", 2);
3561
3591
  B([
3562
3592
  k()
3563
- ], _.prototype, "computedPosition", 2);
3593
+ ], O.prototype, "computedPosition", 2);
3564
3594
  B([
3565
3595
  k()
3566
- ], _.prototype, "popoverStyles", 2);
3596
+ ], O.prototype, "popoverStyles", 2);
3567
3597
  B([
3568
3598
  k()
3569
- ], _.prototype, "arrowStyles", 2);
3599
+ ], O.prototype, "arrowStyles", 2);
3570
3600
  B([
3571
- ft(".pc-popover")
3572
- ], _.prototype, "popoverElement", 2);
3573
- _ = B([
3601
+ gt(".pc-popover")
3602
+ ], O.prototype, "popoverElement", 2);
3603
+ O = B([
3574
3604
  F("pc-popover")
3575
- ], _);
3576
- const ir = R`
3605
+ ], O);
3606
+ const ar = R`
3577
3607
  :host {
3578
3608
  --sheet-bg: light-dark(#ffffff, #1a1a1a);
3579
3609
  --sheet-border: light-dark(#e0e0e0, #333333);
@@ -3686,10 +3716,10 @@ const ir = R`
3686
3716
  max-width: 100%;
3687
3717
  }
3688
3718
  `;
3689
- var ar = Object.defineProperty, nr = Object.getOwnPropertyDescriptor, Q = (e, t, o, r) => {
3690
- for (var s = r > 1 ? void 0 : r ? nr(t, o) : t, i = e.length - 1, a; i >= 0; i--)
3719
+ var nr = Object.defineProperty, lr = Object.getOwnPropertyDescriptor, Q = (e, t, o, r) => {
3720
+ for (var s = r > 1 ? void 0 : r ? lr(t, o) : t, i = e.length - 1, a; i >= 0; i--)
3691
3721
  (a = e[i]) && (s = (r ? a(t, o, s) : a(s)) || s);
3692
- return r && s && ar(t, o, s), s;
3722
+ return r && s && nr(t, o, s), s;
3693
3723
  };
3694
3724
  let D = class extends N {
3695
3725
  constructor() {
@@ -3785,7 +3815,7 @@ let D = class extends N {
3785
3815
  `;
3786
3816
  }
3787
3817
  };
3788
- D.styles = [ir];
3818
+ D.styles = [ar];
3789
3819
  Q([
3790
3820
  f({ type: Boolean, reflect: !0 })
3791
3821
  ], D.prototype, "open", 2);
@@ -3802,17 +3832,17 @@ Q([
3802
3832
  k()
3803
3833
  ], D.prototype, "dragOffset", 2);
3804
3834
  Q([
3805
- ft(".pc-bottom-sheet")
3835
+ gt(".pc-bottom-sheet")
3806
3836
  ], D.prototype, "sheetElement", 2);
3807
3837
  D = Q([
3808
3838
  F("pc-bottom-sheet")
3809
3839
  ], D);
3810
- var lr = Object.defineProperty, cr = Object.getOwnPropertyDescriptor, gt = (e, t, o, r) => {
3811
- for (var s = r > 1 ? void 0 : r ? cr(t, o) : t, i = e.length - 1, a; i >= 0; i--)
3840
+ var cr = Object.defineProperty, dr = Object.getOwnPropertyDescriptor, mt = (e, t, o, r) => {
3841
+ for (var s = r > 1 ? void 0 : r ? dr(t, o) : t, i = e.length - 1, a; i >= 0; i--)
3812
3842
  (a = e[i]) && (s = (r ? a(t, o, s) : a(s)) || s);
3813
- return r && s && lr(t, o, s), s;
3843
+ return r && s && cr(t, o, s), s;
3814
3844
  };
3815
- const dr = 768;
3845
+ const pr = 768;
3816
3846
  let Z = class extends N {
3817
3847
  constructor() {
3818
3848
  super(...arguments), this.open = !1, this.position = "auto", this.isMobile = !1, this.handleMediaChange = (e) => {
@@ -3829,7 +3859,7 @@ let Z = class extends N {
3829
3859
  super.disconnectedCallback(), (e = this.mediaQuery) == null || e.removeEventListener("change", this.handleMediaChange);
3830
3860
  }
3831
3861
  setupMediaQuery() {
3832
- this.mediaQuery = window.matchMedia(`(max-width: ${dr - 1}px)`), this.isMobile = this.mediaQuery.matches, this.mediaQuery.addEventListener("change", this.handleMediaChange);
3862
+ this.mediaQuery = window.matchMedia(`(max-width: ${pr - 1}px)`), this.isMobile = this.mediaQuery.matches, this.mediaQuery.addEventListener("change", this.handleMediaChange);
3833
3863
  }
3834
3864
  render() {
3835
3865
  return this.isMobile ? c`
@@ -3853,27 +3883,27 @@ Z.styles = R`
3853
3883
  display: contents;
3854
3884
  }
3855
3885
  `;
3856
- gt([
3886
+ mt([
3857
3887
  f({ type: Boolean, reflect: !0 })
3858
3888
  ], Z.prototype, "open", 2);
3859
- gt([
3889
+ mt([
3860
3890
  f({ type: String })
3861
3891
  ], Z.prototype, "position", 2);
3862
- gt([
3892
+ mt([
3863
3893
  f({ attribute: !1 })
3864
3894
  ], Z.prototype, "anchor", 2);
3865
- gt([
3895
+ mt([
3866
3896
  k()
3867
3897
  ], Z.prototype, "isMobile", 2);
3868
- Z = gt([
3898
+ Z = mt([
3869
3899
  F("pc-responsive-modal")
3870
3900
  ], Z);
3871
- var pr = Object.defineProperty, ur = Object.getOwnPropertyDescriptor, Y = (e, t, o, r) => {
3872
- for (var s = r > 1 ? void 0 : r ? ur(t, o) : t, i = e.length - 1, a; i >= 0; i--)
3901
+ var ur = Object.defineProperty, hr = Object.getOwnPropertyDescriptor, Y = (e, t, o, r) => {
3902
+ for (var s = r > 1 ? void 0 : r ? hr(t, o) : t, i = e.length - 1, a; i >= 0; i--)
3873
3903
  (a = e[i]) && (s = (r ? a(t, o, s) : a(s)) || s);
3874
- return r && s && pr(t, o, s), s;
3904
+ return r && s && ur(t, o, s), s;
3875
3905
  };
3876
- let I = class extends m {
3906
+ let z = class extends m {
3877
3907
  constructor() {
3878
3908
  super(), this.min = 0, this.max = 10, this.type = $.nps, this.minLabel = "Not at all", this.maxLabel = "Extremely", this.minMaxPosition = "top", this.hoverValue = -1, this.popoverOpen = !1, this.handleNumberLeave = () => {
3879
3909
  this.hoverValue = -1;
@@ -3893,7 +3923,7 @@ let I = class extends m {
3893
3923
  const i = this.dataController.isValueSelected(String(s)), a = {
3894
3924
  "nps-button": !0,
3895
3925
  selected: i
3896
- }, l = _o(`Rate ${s}`, i, !1);
3926
+ }, l = Oo(`Rate ${s}`, i, !1);
3897
3927
  return c`
3898
3928
  <button
3899
3929
  data-testid="nps-button-${s}"
@@ -3937,10 +3967,10 @@ let I = class extends m {
3937
3967
  * NPS score displayed prominently in the middle
3938
3968
  */
3939
3969
  renderChart() {
3940
- const e = this.dataController.stats, t = (e == null ? void 0 : e.nps) ?? 0, o = 100, r = 100, s = 80, i = (P) => ({
3941
- x: o + s * Math.cos(P),
3942
- y: r - s * Math.sin(P)
3943
- }), a = i(Math.PI), l = i(Math.PI / 2), n = i(Math.PI / 4), d = i(0), p = (P, z, It = 0) => `M ${P.x} ${P.y} A ${s} ${s} 0 ${It} 1 ${z.x} ${z.y}`, h = p(a, l), b = p(l, n), w = p(n, d), C = ((P) => Math.PI - (P + 100) / 200 * Math.PI)(t), x = i(C);
3970
+ const e = this.dataController.stats, t = (e == null ? void 0 : e.nps) ?? 0, o = 100, r = 100, s = 80, i = (A) => ({
3971
+ x: o + s * Math.cos(A),
3972
+ y: r - s * Math.sin(A)
3973
+ }), a = i(Math.PI), l = i(Math.PI / 2), n = i(Math.PI / 4), d = i(0), p = (A, P, at = 0) => `M ${A.x} ${A.y} A ${s} ${s} 0 ${at} 1 ${P.x} ${P.y}`, h = p(a, l), b = p(l, n), x = p(n, d), C = ((A) => Math.PI - (A + 100) / 200 * Math.PI)(t), w = i(C);
3944
3974
  return c`
3945
3975
  <div class="nps-semicircle-gauge" data-testid="nps-semicircle-gauge">
3946
3976
  <svg viewBox="0 0 200 115">
@@ -3953,10 +3983,10 @@ let I = class extends m {
3953
3983
  <!-- Colored segments -->
3954
3984
  <path class="gauge-arc gauge-arc-detractor" d="${h}" />
3955
3985
  <path class="gauge-arc gauge-arc-passive" d="${b}" />
3956
- <path class="gauge-arc gauge-arc-promoter" d="${w}" />
3986
+ <path class="gauge-arc gauge-arc-promoter" d="${x}" />
3957
3987
 
3958
3988
  <!-- Needle indicator -->
3959
- <circle class="gauge-needle" cx="${x.x}" cy="${x.y}" r="5" />
3989
+ <circle class="gauge-needle" cx="${w.x}" cy="${w.y}" r="5" />
3960
3990
 
3961
3991
  <!-- Score display in center -->
3962
3992
  <text class="gauge-score" x="${o}" y="${r - 15}">${t}</text>
@@ -4016,7 +4046,7 @@ let I = class extends m {
4016
4046
  * Uses SVG with 3 colored segments for detractors/passives/promoters
4017
4047
  */
4018
4048
  renderInlineGauge() {
4019
- const e = this.dataController.stats, t = (e == null ? void 0 : e.breakdown) || {}, o = 8, r = 2 * Math.PI * o, s = Ro(t), i = s.detractors + s.passives + s.promoters;
4049
+ const e = this.dataController.stats, t = (e == null ? void 0 : e.breakdown) || {}, o = 8, r = 2 * Math.PI * o, s = Bo(t), i = s.detractors + s.passives + s.promoters;
4020
4050
  if (i === 0)
4021
4051
  return c`
4022
4052
  <div class="inline-nps-gauge">
@@ -4025,9 +4055,9 @@ let I = class extends m {
4025
4055
  </svg>
4026
4056
  </div>
4027
4057
  `;
4028
- const a = s.detractors / i * 100, l = s.passives / i * 100, n = s.promoters / i * 100, d = a / 100 * r, p = l / 100 * r, h = n / 100 * r, b = 0, w = -d, E = -(d + p), C = this.getUserScore();
4029
- let x = "gauge-bg";
4030
- return C !== null && (C <= 6 ? x = "gauge-detractor" : C <= 8 ? x = "gauge-passive" : x = "gauge-promoter"), c`
4058
+ const a = s.detractors / i * 100, l = s.passives / i * 100, n = s.promoters / i * 100, d = a / 100 * r, p = l / 100 * r, h = n / 100 * r, b = 0, x = -d, E = -(d + p), C = this.getUserScore();
4059
+ let w = "gauge-bg";
4060
+ return C !== null && (C <= 6 ? w = "gauge-detractor" : C <= 8 ? w = "gauge-passive" : w = "gauge-promoter"), c`
4031
4061
  <div class="inline-nps-gauge">
4032
4062
  <svg viewBox="0 0 20 20">
4033
4063
  <!-- Background circle -->
@@ -4048,7 +4078,7 @@ let I = class extends m {
4048
4078
  cy="10"
4049
4079
  r="${o}"
4050
4080
  stroke-dasharray="${p} ${r}"
4051
- stroke-dashoffset="${w}"
4081
+ stroke-dashoffset="${x}"
4052
4082
  />
4053
4083
  <!-- Promoter segment (green) -->
4054
4084
  <circle
@@ -4060,7 +4090,7 @@ let I = class extends m {
4060
4090
  stroke-dashoffset="${E}"
4061
4091
  />
4062
4092
  <!-- Center dot showing user's score category -->
4063
- <circle class="gauge-dot ${x}" cx="10" cy="10" r="2" />
4093
+ <circle class="gauge-dot ${w}" cx="10" cy="10" r="2" />
4064
4094
  </svg>
4065
4095
  </div>
4066
4096
  `;
@@ -4071,7 +4101,7 @@ let I = class extends m {
4071
4101
  * Shows add icon when no selection, edit icon when user has submitted
4072
4102
  */
4073
4103
  renderInlineTrigger() {
4074
- const t = this.displayController.shouldShowStats() && this.statsText ? this.dataController.formatStatsText(this.statsText) : "", r = this.dataController.hasLocalStats() ? Ct : Oe;
4104
+ const t = this.displayController.shouldShowStats() && this.statsText ? this.dataController.formatStatsText(this.statsText) : "", r = this.dataController.hasLocalStats() ? Et : Ie;
4075
4105
  return c`
4076
4106
  <button
4077
4107
  class="pc-inline-trigger"
@@ -4137,7 +4167,7 @@ let I = class extends m {
4137
4167
  @keydown="${(e) => {
4138
4168
  (e.key === "Enter" || e.key === " ") && (e.preventDefault(), this.displayController.toggleChartVisibility());
4139
4169
  }}"
4140
- >${this.displayController.isChartVisible ? Zt : Gt}</span
4170
+ >${this.displayController.isChartVisible ? Xt : Zt}</span
4141
4171
  >
4142
4172
  `;
4143
4173
  }
@@ -4156,7 +4186,7 @@ let I = class extends m {
4156
4186
  aria-label="Close"
4157
4187
  data-testid="popover-close-button"
4158
4188
  >
4159
- ${Pt}
4189
+ ${_t}
4160
4190
  </button>
4161
4191
  ${this.question ? c`<div class="pc-popover-question">${this.question}</div>` : u}
4162
4192
  ${this.renderPopoverNpsButtons()}
@@ -4206,11 +4236,11 @@ let I = class extends m {
4206
4236
  renderStandardMode() {
4207
4237
  const e = {
4208
4238
  [`pc-flex-pos-${this.questionPosition}`]: !0,
4209
- [`pc-flex-align-${O(this.questionPosition, this.questionAlign)}`]: !0
4239
+ [`pc-flex-align-${I(this.questionPosition, this.questionAlign)}`]: !0
4210
4240
  }, t = {
4211
4241
  nps: !0,
4212
4242
  [`pc-flex-pos-${this.statsPosition}`]: !0,
4213
- [`pc-flex-align-${O(this.statsPosition, this.statsAlign)}`]: !0
4243
+ [`pc-flex-align-${I(this.statsPosition, this.statsAlign)}`]: !0
4214
4244
  };
4215
4245
  return c`
4216
4246
  <div class="pc-container ${y(e)}" data-testid="nps-container">
@@ -4229,32 +4259,32 @@ let I = class extends m {
4229
4259
  return this.inline ? this.renderInlineMode() : this.readonly ? this.renderReadonlyMode() : this.renderStandardMode();
4230
4260
  }
4231
4261
  };
4232
- I.styles = [...m.styles, _t, er];
4262
+ z.styles = [...m.styles, It, or];
4233
4263
  Y([
4234
4264
  f({ type: String, attribute: "min-label" })
4235
- ], I.prototype, "minLabel", 2);
4265
+ ], z.prototype, "minLabel", 2);
4236
4266
  Y([
4237
4267
  f({ type: String, attribute: "max-label" })
4238
- ], I.prototype, "maxLabel", 2);
4268
+ ], z.prototype, "maxLabel", 2);
4239
4269
  Y([
4240
4270
  f({ type: String, attribute: "thank-you-msg" })
4241
- ], I.prototype, "thankYouMsg", 2);
4271
+ ], z.prototype, "thankYouMsg", 2);
4242
4272
  Y([
4243
4273
  f({ type: String, attribute: "min-max-position" })
4244
- ], I.prototype, "minMaxPosition", 2);
4274
+ ], z.prototype, "minMaxPosition", 2);
4245
4275
  Y([
4246
4276
  k()
4247
- ], I.prototype, "hoverValue", 2);
4277
+ ], z.prototype, "hoverValue", 2);
4248
4278
  Y([
4249
4279
  k()
4250
- ], I.prototype, "popoverOpen", 2);
4280
+ ], z.prototype, "popoverOpen", 2);
4251
4281
  Y([
4252
- ft(".pc-inline-trigger")
4253
- ], I.prototype, "triggerElement", 2);
4254
- I = Y([
4282
+ gt(".pc-inline-trigger")
4283
+ ], z.prototype, "triggerElement", 2);
4284
+ z = Y([
4255
4285
  F("pc-nps")
4256
- ], I);
4257
- const hr = R`
4286
+ ], z);
4287
+ const fr = R`
4258
4288
  /* CSS variables inherit from parent - defaults are specified at usage sites */
4259
4289
 
4260
4290
  .pc-container {
@@ -4639,10 +4669,10 @@ const hr = R`
4639
4669
  opacity: 0.8;
4640
4670
  }
4641
4671
  `;
4642
- var fr = Object.defineProperty, gr = Object.getOwnPropertyDescriptor, mt = (e, t, o, r) => {
4643
- for (var s = r > 1 ? void 0 : r ? gr(t, o) : t, i = e.length - 1, a; i >= 0; i--)
4672
+ var gr = Object.defineProperty, mr = Object.getOwnPropertyDescriptor, vt = (e, t, o, r) => {
4673
+ for (var s = r > 1 ? void 0 : r ? mr(t, o) : t, i = e.length - 1, a; i >= 0; i--)
4644
4674
  (a = e[i]) && (s = (r ? a(t, o, s) : a(s)) || s);
4645
- return r && s && fr(t, o, s), s;
4675
+ return r && s && gr(t, o, s), s;
4646
4676
  };
4647
4677
  let X = class extends m {
4648
4678
  constructor() {
@@ -4651,7 +4681,7 @@ let X = class extends m {
4651
4681
  renderStatus() {
4652
4682
  const t = {
4653
4683
  "pc-status": !0,
4654
- [`pc-flex-content-${O("bottom", this.statsAlign)}`]: !0
4684
+ [`pc-flex-content-${I("bottom", this.statsAlign)}`]: !0
4655
4685
  };
4656
4686
  return c`<div class="${y(t)}" data-testid="pc-status">
4657
4687
  <span>${this.renderStatsText()} ${this.renderEditToggleIcon("stats-edit-button")}</span>
@@ -4702,16 +4732,16 @@ let X = class extends m {
4702
4732
  */
4703
4733
  renderOptionIcon(e) {
4704
4734
  if (!(e != null && e.icon)) return "";
4705
- const t = Jt.DECORATIVE, o = (e == null ? void 0 : e.label) || "", r = e ? this.dataController.isValueSelected(e.value) : !1, s = je(e == null ? void 0 : e.icon, {
4735
+ const t = Qt.DECORATIVE, o = (e == null ? void 0 : e.label) || "", r = e ? this.dataController.isValueSelected(e.value) : !1, s = qe(e == null ? void 0 : e.icon, {
4706
4736
  type: t,
4707
4737
  alt: o,
4708
4738
  isSelected: r
4709
4739
  });
4710
- return Re(e == null ? void 0 : e.icon) ? c`<span
4740
+ return Be(e == null ? void 0 : e.icon) ? c`<span
4711
4741
  class="poll-option-icon"
4712
4742
  aria-hidden="${s.ariaHidden ? "true" : "false"}"
4713
4743
  >${e == null ? void 0 : e.icon}</span
4714
- >` : Tt(e == null ? void 0 : e.icon) ? c`<img
4744
+ >` : Ot(e == null ? void 0 : e.icon) ? c`<img
4715
4745
  src="${e == null ? void 0 : e.icon}"
4716
4746
  alt="${s.alt}"
4717
4747
  class="poll-option-icon-img"
@@ -4739,7 +4769,7 @@ let X = class extends m {
4739
4769
  selected: o,
4740
4770
  "poll-option--compact": this.compact,
4741
4771
  "poll-option--disabled": r
4742
- }, i = t + 1, a = `poll-${this.type}-${i}`, l = Oo(
4772
+ }, i = t + 1, a = `poll-${this.type}-${i}`, l = Io(
4743
4773
  e.label,
4744
4774
  o,
4745
4775
  r,
@@ -4796,12 +4826,12 @@ let X = class extends m {
4796
4826
  renderBarChart() {
4797
4827
  var n, d;
4798
4828
  const e = ((n = this.dataController.stats) == null ? void 0 : n.breakdown) || {}, t = ((d = this.dataController.localStats) == null ? void 0 : d.breakdown) || {}, o = Object.values(e).reduce((p, h) => p + h, 0), r = this.options.map((p, h) => {
4799
- const b = e[p.value] || 0, w = o > 0 ? Math.round(b / o * 100) : 0, E = (t[p.value] || 0) > 0;
4829
+ const b = e[p.value] || 0, x = o > 0 ? Math.round(b / o * 100) : 0, E = (t[p.value] || 0) > 0;
4800
4830
  return {
4801
4831
  option: p,
4802
4832
  index: h,
4803
4833
  voteCount: b,
4804
- percentage: w,
4834
+ percentage: x,
4805
4835
  isSelected: E
4806
4836
  };
4807
4837
  }), s = this.multiple ? L.GROUP : L.RADIOGROUP, i = this.question || this.name || "Options", a = ot({
@@ -4897,7 +4927,7 @@ let X = class extends m {
4897
4927
  * Shows add icon when no selection, edit icon when user has submitted
4898
4928
  */
4899
4929
  renderInlineTrigger() {
4900
- const t = this.displayController.shouldShowStats() && this.statsText ? this.dataController.formatStatsText(this.statsText) : "", r = this.dataController.hasLocalStats() ? Ct : Oe;
4930
+ const t = this.displayController.shouldShowStats() && this.statsText ? this.dataController.formatStatsText(this.statsText) : "", r = this.dataController.hasLocalStats() ? Et : Ie;
4901
4931
  return c`
4902
4932
  <button
4903
4933
  class="pc-inline-trigger"
@@ -4956,7 +4986,7 @@ let X = class extends m {
4956
4986
  aria-label="Close"
4957
4987
  data-testid="popover-close-button"
4958
4988
  >
4959
- ${Pt}
4989
+ ${_t}
4960
4990
  </button>
4961
4991
  ${this.question ? c`<div class="pc-popover-question">${this.question}</div>` : u}
4962
4992
  ${e ? this.renderBarChart() : this.renderPollOptions()}
@@ -4973,7 +5003,7 @@ let X = class extends m {
4973
5003
  @keydown=${(s) => {
4974
5004
  (s.key === "Enter" || s.key === " ") && (s.preventDefault(), this.handlePopoverEditClick());
4975
5005
  }}
4976
- >${Ct}</span
5006
+ >${Et}</span
4977
5007
  >` : u}
4978
5008
  </div>` : u}
4979
5009
  </div>
@@ -5030,10 +5060,10 @@ let X = class extends m {
5030
5060
  * Render standard mode - original behavior
5031
5061
  */
5032
5062
  renderStandardMode() {
5033
- const e = O(this.questionPosition, this.questionAlign), t = {
5063
+ const e = I(this.questionPosition, this.questionAlign), t = {
5034
5064
  [`pc-flex-pos-${this.questionPosition}`]: !0,
5035
5065
  [`pc-flex-align-${e}`]: !0
5036
- }, o = O(this.statsPosition, this.statsAlign), r = {
5066
+ }, o = I(this.statsPosition, this.statsAlign), r = {
5037
5067
  "pc-body": !0,
5038
5068
  [`pc-flex-pos-${this.statsPosition}`]: !0,
5039
5069
  [`pc-flex-align-${o}`]: !0
@@ -5059,23 +5089,23 @@ let X = class extends m {
5059
5089
  return this.inline ? this.renderInlineMode() : this.readonly ? this.renderReadonlyMode() : this.renderStandardMode();
5060
5090
  }
5061
5091
  };
5062
- X.styles = [...m.styles, _t, hr];
5063
- mt([
5092
+ X.styles = [...m.styles, It, fr];
5093
+ vt([
5064
5094
  f({ type: Boolean })
5065
5095
  ], X.prototype, "multiple", 2);
5066
- mt([
5096
+ vt([
5067
5097
  f({ type: Boolean })
5068
5098
  ], X.prototype, "compact", 2);
5069
- mt([
5099
+ vt([
5070
5100
  k()
5071
5101
  ], X.prototype, "popoverOpen", 2);
5072
- mt([
5073
- ft(".pc-inline-trigger")
5102
+ vt([
5103
+ gt(".pc-inline-trigger")
5074
5104
  ], X.prototype, "triggerElement", 2);
5075
- X = mt([
5105
+ X = vt([
5076
5106
  F("pc-poll")
5077
5107
  ], X);
5078
- const mr = R`
5108
+ const vr = R`
5079
5109
  /* CSS variables inherit from parent - defaults are specified at usage sites */
5080
5110
 
5081
5111
  .pc-section {
@@ -5262,10 +5292,10 @@ const mr = R`
5262
5292
  * Copyright 2018 Google LLC
5263
5293
  * SPDX-License-Identifier: BSD-3-Clause
5264
5294
  */
5265
- const Ye = "important", vr = " !" + Ye, br = He(class extends Fe {
5295
+ const Ke = "important", br = " !" + Ke, yr = Fe(class extends Ye {
5266
5296
  constructor(e) {
5267
5297
  var t;
5268
- if (super(e), e.type !== qe.ATTRIBUTE || e.name !== "style" || ((t = e.strings) == null ? void 0 : t.length) > 2) throw Error("The `styleMap` directive must be used in the `style` attribute and must be the only part in the attribute.");
5298
+ if (super(e), e.type !== He.ATTRIBUTE || e.name !== "style" || ((t = e.strings) == null ? void 0 : t.length) > 2) throw Error("The `styleMap` directive must be used in the `style` attribute and must be the only part in the attribute.");
5269
5299
  }
5270
5300
  render(e) {
5271
5301
  return Object.keys(e).reduce((t, o) => {
@@ -5281,14 +5311,14 @@ const Ye = "important", vr = " !" + Ye, br = He(class extends Fe {
5281
5311
  const s = t[r];
5282
5312
  if (s != null) {
5283
5313
  this.ft.add(r);
5284
- const i = typeof s == "string" && s.endsWith(vr);
5285
- r.includes("-") || i ? o.setProperty(r, i ? s.slice(0, -11) : s, i ? Ye : "") : o[r] = s;
5314
+ const i = typeof s == "string" && s.endsWith(br);
5315
+ r.includes("-") || i ? o.setProperty(r, i ? s.slice(0, -11) : s, i ? Ke : "") : o[r] = s;
5286
5316
  }
5287
5317
  }
5288
5318
  return q;
5289
5319
  }
5290
5320
  });
5291
- function wt(e, t = {}) {
5321
+ function St(e, t = {}) {
5292
5322
  if (!e || e.length === 0)
5293
5323
  return c`<div class="pc-bar-chart pc-bar-chart--empty">No data available</div>`;
5294
5324
  const o = Math.max(...e.map((i) => i.value)), s = { ...{
@@ -5317,7 +5347,7 @@ function wt(e, t = {}) {
5317
5347
  </div>
5318
5348
  `;
5319
5349
  }
5320
- const Se = {
5350
+ const Ce = {
5321
5351
  // Faces
5322
5352
  smile: "😊",
5323
5353
  laugh: "😄",
@@ -5460,17 +5490,17 @@ const Se = {
5460
5490
  hiking: "🥾",
5461
5491
  yoga: "🧘"
5462
5492
  };
5463
- function Et(e) {
5493
+ function Pt(e) {
5464
5494
  let t = "❓", o = !1;
5465
- return e ? e in Se ? t = Se[e] : Re(e) ? t = e : Tt(e) ? (o = !0, t = e) : /^\w+@\w+$/.test(e) ? t = e : e.endsWith(".svg") && !e.includes("/") ? (t = `https://cdn.jsdelivr.net/npm/@mdi/svg@7.4.47/svg/${e}`, o = !0) : t = e : t = "❓", {
5495
+ return e ? e in Ce ? t = Ce[e] : Be(e) ? t = e : Ot(e) ? (o = !0, t = e) : /^\w+@\w+$/.test(e) ? t = e : e.endsWith(".svg") && !e.includes("/") ? (t = `https://cdn.jsdelivr.net/npm/@mdi/svg@7.4.47/svg/${e}`, o = !0) : t = e : t = "❓", {
5466
5496
  icon: t,
5467
5497
  isRemoteImage: o
5468
5498
  };
5469
5499
  }
5470
- var yr = Object.defineProperty, xr = Object.getOwnPropertyDescriptor, it = (e, t, o, r) => {
5471
- for (var s = r > 1 ? void 0 : r ? xr(t, o) : t, i = e.length - 1, a; i >= 0; i--)
5500
+ var xr = Object.defineProperty, wr = Object.getOwnPropertyDescriptor, it = (e, t, o, r) => {
5501
+ for (var s = r > 1 ? void 0 : r ? wr(t, o) : t, i = e.length - 1, a; i >= 0; i--)
5472
5502
  (a = e[i]) && (s = (r ? a(t, o, s) : a(s)) || s);
5473
- return r && s && yr(t, o, s), s;
5503
+ return r && s && xr(t, o, s), s;
5474
5504
  };
5475
5505
  let H = class extends m {
5476
5506
  constructor() {
@@ -5495,14 +5525,14 @@ let H = class extends m {
5495
5525
  * Renders the star icon using resolveIcon for emoji, URL, or MDI support
5496
5526
  */
5497
5527
  renderStarIcon() {
5498
- const { icon: e, isRemoteImage: t } = Et(this.icon);
5528
+ const { icon: e, isRemoteImage: t } = Pt(this.icon);
5499
5529
  return t ? c`<img class="star-icon-img" src="${e}" alt="star" />` : e;
5500
5530
  }
5501
5531
  /**
5502
5532
  * Gets the resolved icon string (for use in chart labels)
5503
5533
  */
5504
5534
  getResolvedIconString() {
5505
- const { icon: e, isRemoteImage: t } = Et(this.icon);
5535
+ const { icon: e, isRemoteImage: t } = Pt(this.icon);
5506
5536
  return t ? "★" : e;
5507
5537
  }
5508
5538
  /**
@@ -5513,7 +5543,7 @@ let H = class extends m {
5513
5543
  renderStars(e = !1) {
5514
5544
  var n;
5515
5545
  const t = this.getUserVotePosition(), o = this.dataController.stats, r = (o == null ? void 0 : o.avg) ?? 0, s = ((n = this.dataController.localStats) == null ? void 0 : n.avg) ?? 0, i = this.readonly ? r : s, a = this.displayController.allowEdit(), l = Array.from({ length: this.numStars }, (d, p) => p + 1).map((d) => {
5516
- const p = e ? t || 0 : Math.floor(i), h = d <= p || d <= (this.hoverValue || 0), b = !e && !h && d === Math.ceil(i) && i % 1 !== 0, w = {
5546
+ const p = e ? t || 0 : Math.floor(i), h = d <= p || d <= (this.hoverValue || 0), b = !e && !h && d === Math.ceil(i) && i % 1 !== 0, x = {
5517
5547
  star: !0,
5518
5548
  selected: h,
5519
5549
  partial: b,
@@ -5523,8 +5553,8 @@ let H = class extends m {
5523
5553
  <div class="pc-section" data-testid="pc-section">
5524
5554
  <span
5525
5555
  data-testid="${e ? "popover" : "stars-view"}-star-${d}"
5526
- class=${y(w)}
5527
- style=${br(E)}
5556
+ class=${y(x)}
5557
+ style=${yr(E)}
5528
5558
  role="${a ? "button" : "presentation"}"
5529
5559
  tabindex="${a ? "0" : ""}"
5530
5560
  aria-label="${a ? `Rate ${d} star${d > 1 ? "s" : ""}` : ""}"
@@ -5552,7 +5582,7 @@ let H = class extends m {
5552
5582
  label: n,
5553
5583
  value: d,
5554
5584
  icon: r
5555
- })), a = getComputedStyle(this).getPropertyValue("--pc-accent-color").trim() || "#ffc107", l = wt(s, {
5585
+ })), a = getComputedStyle(this).getPropertyValue("--pc-accent-color").trim() || "#ffc107", l = St(s, {
5556
5586
  barColor: a,
5557
5587
  labelFormatter: (n) => `${n.label} ${n.icon}`,
5558
5588
  valueFormatter: (n) => `${o > 0 ? Math.round(n.value / o * 100) : 0}%`
@@ -5652,7 +5682,7 @@ let H = class extends m {
5652
5682
  aria-label="Close"
5653
5683
  data-testid="popover-close-button"
5654
5684
  >
5655
- ${Pt}
5685
+ ${_t}
5656
5686
  </button>
5657
5687
  ${this.question ? c`<div class="pc-popover-question">${this.question}</div>` : u}
5658
5688
  ${this.renderStars(!0)}
@@ -5675,7 +5705,7 @@ let H = class extends m {
5675
5705
  label: n,
5676
5706
  value: d,
5677
5707
  icon: r
5678
- })), a = getComputedStyle(this).getPropertyValue("--pc-accent-color").trim() || "#ffc107", l = wt(s, {
5708
+ })), a = getComputedStyle(this).getPropertyValue("--pc-accent-color").trim() || "#ffc107", l = St(s, {
5679
5709
  barColor: a,
5680
5710
  labelFormatter: (n) => `${n.label} ${n.icon}`,
5681
5711
  valueFormatter: (n) => `${o > 0 ? Math.round(n.value / o * 100) : 0}%`
@@ -5701,7 +5731,7 @@ let H = class extends m {
5701
5731
  @keydown="${(e) => {
5702
5732
  (e.key === "Enter" || e.key === " ") && (e.preventDefault(), this.displayController.toggleChartVisibility());
5703
5733
  }}"
5704
- >${this.displayController.isChartVisible ? Zt : Gt}</span
5734
+ >${this.displayController.isChartVisible ? Xt : Zt}</span
5705
5735
  >
5706
5736
  `;
5707
5737
  }
@@ -5744,7 +5774,7 @@ let H = class extends m {
5744
5774
  label: n,
5745
5775
  value: d,
5746
5776
  icon: r
5747
- })), a = getComputedStyle(this).getPropertyValue("--pc-accent-color").trim() || "#ffc107", l = wt(s, {
5777
+ })), a = getComputedStyle(this).getPropertyValue("--pc-accent-color").trim() || "#ffc107", l = St(s, {
5748
5778
  barColor: a,
5749
5779
  labelFormatter: (n) => `${n.label} ${n.icon}`,
5750
5780
  valueFormatter: (n) => `${o > 0 ? Math.round(n.value / o * 100) : 0}%`
@@ -5759,10 +5789,10 @@ let H = class extends m {
5759
5789
  * Render standard mode - original behavior
5760
5790
  */
5761
5791
  renderStandardMode() {
5762
- const e = O(this.questionPosition, this.questionAlign), t = {
5792
+ const e = I(this.questionPosition, this.questionAlign), t = {
5763
5793
  [`pc-flex-pos-${this.questionPosition}`]: !0,
5764
5794
  [`pc-flex-align-${e}`]: !0
5765
- }, o = O(this.statsPosition, this.statsAlign), r = {
5795
+ }, o = I(this.statsPosition, this.statsAlign), r = {
5766
5796
  "pc-body": !0,
5767
5797
  [`pc-flex-pos-${this.statsPosition}`]: !0,
5768
5798
  [`pc-flex-align-${o}`]: !0
@@ -5782,7 +5812,7 @@ let H = class extends m {
5782
5812
  return this.inline ? this.renderInlineMode() : this.readonly ? this.renderReadonlyMode() : this.renderStandardMode();
5783
5813
  }
5784
5814
  };
5785
- H.styles = [...m.styles, _t, mr];
5815
+ H.styles = [...m.styles, It, vr];
5786
5816
  it([
5787
5817
  f({ type: String })
5788
5818
  ], H.prototype, "icon", 2);
@@ -5796,12 +5826,12 @@ it([
5796
5826
  k()
5797
5827
  ], H.prototype, "popoverOpen", 2);
5798
5828
  it([
5799
- ft(".pc-inline-trigger")
5829
+ gt(".pc-inline-trigger")
5800
5830
  ], H.prototype, "triggerElement", 2);
5801
5831
  H = it([
5802
5832
  F("pc-stars")
5803
5833
  ], H);
5804
- const wr = R`
5834
+ const $r = R`
5805
5835
  /* Adjust stats text for reactions */
5806
5836
  .pc-stats-text {
5807
5837
  font-size: var(--pc-font-size-small, var(--default-font-size-small));
@@ -6064,11 +6094,11 @@ const wr = R`
6064
6094
  animation: none;
6065
6095
  }
6066
6096
  }
6067
- `, $r = "data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20height='24px'%20viewBox='0%20-960%20960%20960'%20width='24px'%20fill='%23434343'%3e%3cpath%20d='M480-480Zm0%20400q-83%200-156-31.5T197-197q-54-54-85.5-127T80-480q0-83%2031.5-156T197-763q54-54%20127-85.5T480-880q43%200%2083%208.5t77%2024.5v90q-35-20-75.5-31.5T480-800q-133%200-226.5%2093.5T160-480q0%20133%2093.5%20226.5T480-160q133%200%20226.5-93.5T800-480q0-32-6.5-62T776-600h86q9%2029%2013.5%2058.5T880-480q0%2083-31.5%20156T763-197q-54%2054-127%2085.5T480-80Zm320-600v-80h-80v-80h80v-80h80v80h80v80h-80v80h-80ZM620-520q25%200%2042.5-17.5T680-580q0-25-17.5-42.5T620-640q-25%200-42.5%2017.5T560-580q0%2025%2017.5%2042.5T620-520Zm-280%200q25%200%2042.5-17.5T400-580q0-25-17.5-42.5T340-640q-25%200-42.5%2017.5T280-580q0%2025%2017.5%2042.5T340-520Zm140%20260q68%200%20123.5-38.5T684-400H276q25%2063%2080.5%20101.5T480-260Z'/%3e%3c/svg%3e";
6068
- var Sr = Object.defineProperty, Cr = Object.getOwnPropertyDescriptor, Ot = (e, t, o, r) => {
6069
- for (var s = r > 1 ? void 0 : r ? Cr(t, o) : t, i = e.length - 1, a; i >= 0; i--)
6097
+ `, Sr = "data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20height='24px'%20viewBox='0%20-960%20960%20960'%20width='24px'%20fill='%23434343'%3e%3cpath%20d='M480-480Zm0%20400q-83%200-156-31.5T197-197q-54-54-85.5-127T80-480q0-83%2031.5-156T197-763q54-54%20127-85.5T480-880q43%200%2083%208.5t77%2024.5v90q-35-20-75.5-31.5T480-800q-133%200-226.5%2093.5T160-480q0%20133%2093.5%20226.5T480-160q133%200%20226.5-93.5T800-480q0-32-6.5-62T776-600h86q9%2029%2013.5%2058.5T880-480q0%2083-31.5%20156T763-197q-54%2054-127%2085.5T480-80Zm320-600v-80h-80v-80h80v-80h80v80h80v80h-80v80h-80ZM620-520q25%200%2042.5-17.5T680-580q0-25-17.5-42.5T620-640q-25%200-42.5%2017.5T560-580q0%2025%2017.5%2042.5T620-520Zm-280%200q25%200%2042.5-17.5T400-580q0-25-17.5-42.5T340-640q-25%200-42.5%2017.5T280-580q0%2025%2017.5%2042.5T340-520Zm140%20260q68%200%20123.5-38.5T684-400H276q25%2063%2080.5%20101.5T480-260Z'/%3e%3c/svg%3e";
6098
+ var Cr = Object.defineProperty, kr = Object.getOwnPropertyDescriptor, zt = (e, t, o, r) => {
6099
+ for (var s = r > 1 ? void 0 : r ? kr(t, o) : t, i = e.length - 1, a; i >= 0; i--)
6070
6100
  (a = e[i]) && (s = (r ? a(t, o, s) : a(s)) || s);
6071
- return r && s && Sr(t, o, s), s;
6101
+ return r && s && Cr(t, o, s), s;
6072
6102
  };
6073
6103
  let st = class extends m {
6074
6104
  constructor() {
@@ -6094,7 +6124,7 @@ let st = class extends m {
6094
6124
  * Renders the icon for a reaction
6095
6125
  */
6096
6126
  renderReactionIcon(e, t) {
6097
- const { icon: o, isRemoteImage: r } = Et(e), s = Jt.FUNCTIONAL, i = t.tooltip || `${t.value} reaction`, a = je(o, {
6127
+ const { icon: o, isRemoteImage: r } = Pt(e), s = Qt.FUNCTIONAL, i = t.tooltip || `${t.value} reaction`, a = qe(o, {
6098
6128
  type: s,
6099
6129
  alt: i,
6100
6130
  ariaLabel: i,
@@ -6148,7 +6178,7 @@ let st = class extends m {
6148
6178
  aria-expanded="${this.displayController.shouldShowReactionPopover()}"
6149
6179
  aria-haspopup="true"
6150
6180
  >
6151
- <img src="${$r}" alt="" class="trigger-icon" />
6181
+ <img src="${Sr}" alt="" class="trigger-icon" />
6152
6182
  </button>
6153
6183
  `;
6154
6184
  }
@@ -6246,7 +6276,7 @@ let st = class extends m {
6246
6276
  icon: (p == null ? void 0 : p.icon) || n
6247
6277
  // Use the icon or fall back to reaction value
6248
6278
  };
6249
- }), r = getComputedStyle(this), s = r.getPropertyValue("--pc-primary-color").trim(), a = r.getPropertyValue("--pc-accent-color").trim() || s || "#ffc107", l = wt(o, {
6279
+ }), r = getComputedStyle(this), s = r.getPropertyValue("--pc-primary-color").trim(), a = r.getPropertyValue("--pc-accent-color").trim() || s || "#ffc107", l = St(o, {
6250
6280
  barColor: a,
6251
6281
  labelFormatter: (n) => `${n.label}`,
6252
6282
  valueFormatter: (n) => `${e.totalCount > 0 ? Math.round(n.value / e.totalCount * 100) : 0}%`
@@ -6287,10 +6317,10 @@ let st = class extends m {
6287
6317
  * (Reactions are inherently inline, so inline mode = standard mode)
6288
6318
  */
6289
6319
  renderStandardMode() {
6290
- const e = O(this.questionPosition, this.questionAlign), t = {
6320
+ const e = I(this.questionPosition, this.questionAlign), t = {
6291
6321
  [`pc-flex-pos-${this.questionPosition}`]: !0,
6292
6322
  [`pc-flex-align-${e}`]: !0
6293
- }, o = O(this.statsPosition, this.statsAlign), r = {
6323
+ }, o = I(this.statsPosition, this.statsAlign), r = {
6294
6324
  "pc-body": !0,
6295
6325
  [`pc-flex-pos-${this.statsPosition}`]: !0,
6296
6326
  [`pc-flex-align-${o}`]: !0
@@ -6310,31 +6340,31 @@ let st = class extends m {
6310
6340
  return this.readonly ? this.renderReadonlyMode() : this.renderStandardMode();
6311
6341
  }
6312
6342
  };
6313
- st.styles = [...m.styles, _t, wr];
6314
- Ot([
6343
+ st.styles = [...m.styles, It, $r];
6344
+ zt([
6315
6345
  f({ type: Boolean, attribute: "show-counts" })
6316
6346
  ], st.prototype, "showCounts", 2);
6317
- Ot([
6347
+ zt([
6318
6348
  f({ type: Boolean, reflect: !0 })
6319
6349
  ], st.prototype, "compact", 2);
6320
- Ot([
6350
+ zt([
6321
6351
  f({ type: String, attribute: "popup-position" })
6322
6352
  ], st.prototype, "popupPosition", 2);
6323
- st = Ot([
6353
+ st = zt([
6324
6354
  F("pc-reaction")
6325
6355
  ], st);
6326
- function nt(e, t, o = void 0) {
6356
+ function lt(e, t, o = void 0) {
6327
6357
  const r = e.getAttribute(t);
6328
6358
  return r === null ? o : r == null ? void 0 : r.trim();
6329
6359
  }
6330
- function kr(e, t = void 0) {
6360
+ function Er(e, t = void 0) {
6331
6361
  const o = e.textContent;
6332
6362
  return o === "" || o === null ? t : o == null ? void 0 : o.trim();
6333
6363
  }
6334
- var Er = Object.defineProperty, Ar = Object.getOwnPropertyDescriptor, vt = (e, t, o, r) => {
6335
- for (var s = r > 1 ? void 0 : r ? Ar(t, o) : t, i = e.length - 1, a; i >= 0; i--)
6364
+ var Ar = Object.defineProperty, Pr = Object.getOwnPropertyDescriptor, bt = (e, t, o, r) => {
6365
+ for (var s = r > 1 ? void 0 : r ? Pr(t, o) : t, i = e.length - 1, a; i >= 0; i--)
6336
6366
  (a = e[i]) && (s = (r ? a(t, o, s) : a(s)) || s);
6337
- return r && s && Er(t, o, s), s;
6367
+ return r && s && Ar(t, o, s), s;
6338
6368
  };
6339
6369
  let J = class extends N {
6340
6370
  constructor() {
@@ -6395,16 +6425,16 @@ let J = class extends N {
6395
6425
  const e = this.querySelector("pc-poll, pc-reaction");
6396
6426
  if (!e) return;
6397
6427
  const t = this.querySelectorAll("poll-catch-option");
6398
- let r = Be(this.options).map((s) => ({
6428
+ let r = Ve(this.options).map((s) => ({
6399
6429
  value: s,
6400
6430
  label: s,
6401
6431
  icon: e.tagName === "PC-REACTION" ? s : void 0
6402
6432
  // REACTION widget uses options for the icon
6403
6433
  }));
6404
6434
  t && t.length > 0 && (r = Array.from(t).map((s) => {
6405
- const i = nt(s, "value", "") || "", a = nt(s, "label", kr(s, i)) || "", l = nt(s, "icon", void 0), n = nt(s, "tooltip", void 0), d = nt(s, "disabled", void 0), p = { value: i, label: a };
6435
+ const i = lt(s, "value", "") || "", a = lt(s, "label", Er(s, i)) || "", l = lt(s, "icon", void 0), n = lt(s, "tooltip", void 0), d = lt(s, "disabled", void 0), p = { value: i, label: a };
6406
6436
  if (l !== void 0) {
6407
- const h = Et(l);
6437
+ const h = Pt(l);
6408
6438
  p.icon = h.icon;
6409
6439
  }
6410
6440
  return n !== void 0 && (p.tooltip = n), d !== void 0 && (p.disabled = !0), p;
@@ -6430,19 +6460,19 @@ let J = class extends N {
6430
6460
  }
6431
6461
  }
6432
6462
  };
6433
- vt([
6463
+ bt([
6434
6464
  f({ type: String })
6435
6465
  ], J.prototype, "type", 2);
6436
- vt([
6466
+ bt([
6437
6467
  f({ type: String })
6438
6468
  ], J.prototype, "options", 2);
6439
- vt([
6469
+ bt([
6440
6470
  f({ type: String, attribute: "widget-id" })
6441
6471
  ], J.prototype, "widgetId", 2);
6442
- vt([
6472
+ bt([
6443
6473
  k()
6444
6474
  ], J.prototype, "parsedOptions", 2);
6445
- J = vt([
6475
+ J = bt([
6446
6476
  F("poll-catch")
6447
6477
  ], J);
6448
6478
  export {