pollcatch 2.1.13 → 2.1.14

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 +266 -258
package/pc.js CHANGED
@@ -4,7 +4,7 @@
4
4
  * SPDX-License-Identifier: BSD-3-Clause
5
5
  */
6
6
  const it = globalThis, At = it.ShadowRoot && (it.ShadyCSS === void 0 || it.ShadyCSS.nativeShadow) && "adoptedStyleSheets" in Document.prototype && "replace" in CSSStyleSheet.prototype, _t = Symbol(), Lt = /* @__PURE__ */ new WeakMap();
7
- let ae = class {
7
+ let ne = class {
8
8
  constructor(t, o, r) {
9
9
  if (this._$cssResult$ = !0, r !== _t) throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");
10
10
  this.cssText = t, this.t = o;
@@ -22,14 +22,14 @@ let ae = class {
22
22
  return this.cssText;
23
23
  }
24
24
  };
25
- const ke = (e) => new ae(typeof e == "string" ? e : e + "", void 0, _t), F = (e, ...t) => {
25
+ const Ae = (e) => new ne(typeof e == "string" ? e : e + "", void 0, _t), F = (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 ae(o, e, _t);
32
- }, Ae = (e, t) => {
31
+ return new ne(o, e, _t);
32
+ }, _e = (e, t) => {
33
33
  if (At) e.adoptedStyleSheets = t.map((o) => o instanceof CSSStyleSheet ? o : o.styleSheet);
34
34
  else for (const o of t) {
35
35
  const r = document.createElement("style"), s = it.litNonce;
@@ -38,17 +38,17 @@ const ke = (e) => new ae(typeof e == "string" ? e : e + "", void 0, _t), F = (e,
38
38
  }, Rt = At ? (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 Ae(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: _e, defineProperty: Ee, getOwnPropertyDescriptor: Pe, getOwnPropertyNames: Oe, getOwnPropertySymbols: Te, getPrototypeOf: ze } = Object, T = globalThis, Ut = T.trustedTypes, Ie = Ut ? Ut.emptyScript : "", mt = T.reactiveElementPolyfillSupport, K = (e, t) => e, at = { toAttribute(e, t) {
48
+ const { is: Ee, defineProperty: Pe, getOwnPropertyDescriptor: Oe, getOwnPropertyNames: Te, getOwnPropertySymbols: ze, getPrototypeOf: Ie } = Object, T = globalThis, Ut = T.trustedTypes, Ne = Ut ? Ut.emptyScript : "", mt = T.reactiveElementPolyfillSupport, K = (e, t) => e, at = { toAttribute(e, t) {
49
49
  switch (t) {
50
50
  case Boolean:
51
- e = e ? Ie : null;
51
+ e = e ? Ne : null;
52
52
  break;
53
53
  case Object:
54
54
  case Array:
@@ -73,7 +73,7 @@ const { is: _e, defineProperty: Ee, getOwnPropertyDescriptor: Pe, getOwnProperty
73
73
  }
74
74
  }
75
75
  return o;
76
- } }, Et = (e, t) => !_e(e, t), jt = { attribute: !0, type: String, converter: at, reflect: !1, hasChanged: Et };
76
+ } }, Et = (e, t) => !Ee(e, t), jt = { attribute: !0, type: String, converter: at, reflect: !1, hasChanged: Et };
77
77
  Symbol.metadata ?? (Symbol.metadata = Symbol("metadata")), T.litPropertyMetadata ?? (T.litPropertyMetadata = /* @__PURE__ */ new WeakMap());
78
78
  let U = class extends HTMLElement {
79
79
  static addInitializer(t) {
@@ -85,11 +85,11 @@ let U = class extends HTMLElement {
85
85
  static createProperty(t, o = jt) {
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 && Ee(this.prototype, t, s);
88
+ s !== void 0 && Pe(this.prototype, t, s);
89
89
  }
90
90
  }
91
91
  static getPropertyDescriptor(t, o, r) {
92
- const { get: s, set: i } = Pe(this.prototype, t) ?? { get() {
92
+ const { get: s, set: i } = Oe(this.prototype, t) ?? { get() {
93
93
  return this[o];
94
94
  }, set(a) {
95
95
  this[o] = a;
@@ -106,13 +106,13 @@ let U = class extends HTMLElement {
106
106
  }
107
107
  static _$Ei() {
108
108
  if (this.hasOwnProperty(K("elementProperties"))) return;
109
- const t = ze(this);
109
+ const t = Ie(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
113
  if (this.hasOwnProperty(K("finalized"))) return;
114
114
  if (this.finalized = !0, this._$Ei(), this.hasOwnProperty(K("properties"))) {
115
- const o = this.properties, r = [...Oe(o), ...Te(o)];
115
+ const o = this.properties, r = [...Te(o), ...ze(o)];
116
116
  for (const s of r) this.createProperty(s, o[s]);
117
117
  }
118
118
  const t = this[Symbol.metadata];
@@ -161,7 +161,7 @@ let U = class extends HTMLElement {
161
161
  }
162
162
  createRenderRoot() {
163
163
  const t = this.shadowRoot ?? this.attachShadow(this.constructor.shadowRootOptions);
164
- return Ae(t, this.constructor.elementStyles), t;
164
+ return _e(t, this.constructor.elementStyles), t;
165
165
  }
166
166
  connectedCallback() {
167
167
  var t;
@@ -279,53 +279,53 @@ U.elementStyles = [], U.shadowRootOptions = { mode: "open" }, U[K("elementProper
279
279
  * Copyright 2017 Google LLC
280
280
  * SPDX-License-Identifier: BSD-3-Clause
281
281
  */
282
- const W = globalThis, nt = W.trustedTypes, Bt = nt ? nt.createPolicy("lit-html", { createHTML: (e) => e }) : void 0, ne = "$lit$", P = `lit$${Math.random().toFixed(9).slice(2)}$`, le = "?" + P, Ne = `<${le}>`, L = document, X = () => L.createComment(""), Q = (e) => e === null || typeof e != "object" && typeof e != "function", Pt = Array.isArray, Me = (e) => Pt(e) || typeof (e == null ? void 0 : e[Symbol.iterator]) == "function", bt = `[
282
+ const W = globalThis, nt = W.trustedTypes, Bt = nt ? nt.createPolicy("lit-html", { createHTML: (e) => e }) : void 0, le = "$lit$", P = `lit$${Math.random().toFixed(9).slice(2)}$`, ce = "?" + P, Me = `<${ce}>`, L = document, X = () => L.createComment(""), Q = (e) => e === null || typeof e != "object" && typeof e != "function", Pt = Array.isArray, Le = (e) => Pt(e) || typeof (e == null ? void 0 : e[Symbol.iterator]) == "function", bt = `[
283
283
  \f\r]`, Z = /<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g, Dt = /-->/g, Vt = />/g, N = RegExp(`>|${bt}(?:([^\\s"'>=/]+)(${bt}*=${bt}*(?:[^
284
- \f\r"'\`<>=]|("|')|))|$)`, "g"), qt = /'/g, Ht = /"/g, ce = /^(?:script|style|textarea|title)$/i, Le = (e) => (t, ...o) => ({ _$litType$: e, strings: t, values: o }), d = Le(1), z = Symbol.for("lit-noChange"), h = Symbol.for("lit-nothing"), Ft = /* @__PURE__ */ new WeakMap(), M = L.createTreeWalker(L, 129);
285
- function de(e, t) {
284
+ \f\r"'\`<>=]|("|')|))|$)`, "g"), qt = /'/g, Ht = /"/g, de = /^(?:script|style|textarea|title)$/i, Re = (e) => (t, ...o) => ({ _$litType$: e, strings: t, values: o }), d = Re(1), z = Symbol.for("lit-noChange"), h = Symbol.for("lit-nothing"), Ft = /* @__PURE__ */ new WeakMap(), M = L.createTreeWalker(L, 129);
285
+ function pe(e, t) {
286
286
  if (!Pt(e) || !e.hasOwnProperty("raw")) throw Error("invalid template strings array");
287
287
  return Bt !== void 0 ? Bt.createHTML(t) : t;
288
288
  }
289
- const Re = (e, t) => {
289
+ const Ue = (e, t) => {
290
290
  const o = e.length - 1, r = [];
291
291
  let s, i = t === 2 ? "<svg>" : t === 3 ? "<math>" : "", a = Z;
292
292
  for (let n = 0; n < o; n++) {
293
293
  const l = e[n];
294
- let u, c, p = -1, w = 0;
295
- for (; w < l.length && (a.lastIndex = w, c = a.exec(l), c !== null); ) w = a.lastIndex, a === Z ? c[1] === "!--" ? a = Dt : c[1] !== void 0 ? a = Vt : c[2] !== void 0 ? (ce.test(c[2]) && (s = RegExp("</" + c[2], "g")), a = N) : c[3] !== void 0 && (a = N) : a === N ? c[0] === ">" ? (a = s ?? Z, p = -1) : c[1] === void 0 ? p = -2 : (p = a.lastIndex - c[2].length, u = c[1], a = c[3] === void 0 ? N : c[3] === '"' ? Ht : qt) : a === Ht || a === qt ? a = N : a === Dt || a === Vt ? a = Z : (a = N, s = void 0);
294
+ let p, c, u = -1, w = 0;
295
+ for (; w < l.length && (a.lastIndex = w, c = a.exec(l), c !== null); ) w = a.lastIndex, a === Z ? c[1] === "!--" ? a = Dt : c[1] !== void 0 ? a = Vt : c[2] !== void 0 ? (de.test(c[2]) && (s = RegExp("</" + c[2], "g")), a = N) : c[3] !== void 0 && (a = N) : a === N ? c[0] === ">" ? (a = s ?? Z, u = -1) : c[1] === void 0 ? u = -2 : (u = a.lastIndex - c[2].length, p = c[1], a = c[3] === void 0 ? N : c[3] === '"' ? Ht : qt) : a === Ht || a === qt ? a = N : a === Dt || a === Vt ? a = Z : (a = N, s = void 0);
296
296
  const v = a === N && e[n + 1].startsWith("/>") ? " " : "";
297
- i += a === Z ? l + Ne : p >= 0 ? (r.push(u), l.slice(0, p) + ne + l.slice(p) + P + v) : l + P + (p === -2 ? n : v);
297
+ i += a === Z ? l + Me : u >= 0 ? (r.push(p), l.slice(0, u) + le + l.slice(u) + P + v) : l + P + (u === -2 ? n : v);
298
298
  }
299
- return [de(e, i + (e[o] || "<?>") + (t === 2 ? "</svg>" : t === 3 ? "</math>" : "")), r];
299
+ return [pe(e, i + (e[o] || "<?>") + (t === 2 ? "</svg>" : t === 3 ? "</math>" : "")), r];
300
300
  };
301
- let kt = class pe {
301
+ let kt = class ue {
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 n = t.length - 1, l = this.parts, [u, c] = Re(t, o);
307
- if (this.el = pe.createElement(u, r), M.currentNode = this.el.content, o === 2 || o === 3) {
308
- const p = this.el.content.firstChild;
309
- p.replaceWith(...p.childNodes);
306
+ const n = t.length - 1, l = this.parts, [p, c] = Ue(t, o);
307
+ if (this.el = ue.createElement(p, r), M.currentNode = this.el.content, o === 2 || o === 3) {
308
+ const u = this.el.content.firstChild;
309
+ u.replaceWith(...u.childNodes);
310
310
  }
311
311
  for (; (s = M.nextNode()) !== null && l.length < n; ) {
312
312
  if (s.nodeType === 1) {
313
- if (s.hasAttributes()) for (const p of s.getAttributeNames()) if (p.endsWith(ne)) {
314
- const w = c[a++], v = s.getAttribute(p).split(P), E = /([.?@])?(.*)/.exec(w);
315
- l.push({ type: 1, index: i, name: E[2], strings: v, ctor: E[1] === "." ? je : E[1] === "?" ? Be : E[1] === "@" ? De : ct }), s.removeAttribute(p);
316
- } else p.startsWith(P) && (l.push({ type: 6, index: i }), s.removeAttribute(p));
317
- if (ce.test(s.tagName)) {
318
- const p = s.textContent.split(P), w = p.length - 1;
313
+ if (s.hasAttributes()) for (const u of s.getAttributeNames()) if (u.endsWith(le)) {
314
+ const w = c[a++], v = s.getAttribute(u).split(P), E = /([.?@])?(.*)/.exec(w);
315
+ l.push({ type: 1, index: i, name: E[2], strings: v, ctor: E[1] === "." ? Be : E[1] === "?" ? De : E[1] === "@" ? Ve : ct }), s.removeAttribute(u);
316
+ } else u.startsWith(P) && (l.push({ type: 6, index: i }), s.removeAttribute(u));
317
+ if (de.test(s.tagName)) {
318
+ const u = s.textContent.split(P), w = u.length - 1;
319
319
  if (w > 0) {
320
320
  s.textContent = nt ? nt.emptyScript : "";
321
- for (let v = 0; v < w; v++) s.append(p[v], X()), M.nextNode(), l.push({ type: 2, index: ++i });
322
- s.append(p[w], X());
321
+ for (let v = 0; v < w; v++) s.append(u[v], X()), M.nextNode(), l.push({ type: 2, index: ++i });
322
+ s.append(u[w], X());
323
323
  }
324
324
  }
325
- } else if (s.nodeType === 8) if (s.data === le) l.push({ type: 2, index: i });
325
+ } else if (s.nodeType === 8) if (s.data === ce) l.push({ type: 2, index: i });
326
326
  else {
327
- let p = -1;
328
- for (; (p = s.data.indexOf(P, p + 1)) !== -1; ) l.push({ type: 7, index: i }), p += P.length - 1;
327
+ let u = -1;
328
+ for (; (u = s.data.indexOf(P, u + 1)) !== -1; ) l.push({ type: 7, index: i }), u += P.length - 1;
329
329
  }
330
330
  i++;
331
331
  }
@@ -342,7 +342,7 @@ function D(e, t, o = e, r) {
342
342
  const i = Q(t) ? void 0 : t._$litDirective$;
343
343
  return (s == null ? void 0 : s.constructor) !== i && ((n = s == null ? void 0 : s._$AO) == null || n.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 = D(e, s._$AS(e, t.values), s, r)), t;
344
344
  }
345
- let Ue = class {
345
+ let je = class {
346
346
  constructor(t, o) {
347
347
  this._$AV = [], this._$AN = void 0, this._$AD = t, this._$AM = o;
348
348
  }
@@ -358,8 +358,8 @@ let Ue = class {
358
358
  let i = M.nextNode(), a = 0, n = 0, l = r[0];
359
359
  for (; l !== void 0; ) {
360
360
  if (a === l.index) {
361
- let u;
362
- l.type === 2 ? u = new et(i, i.nextSibling, this, t) : l.type === 1 ? u = new l.ctor(i, l.name, l.strings, this, t) : l.type === 6 && (u = new Ve(i, this, t)), this._$AV.push(u), l = r[++n];
361
+ let p;
362
+ l.type === 2 ? p = new et(i, i.nextSibling, this, t) : l.type === 1 ? p = new l.ctor(i, l.name, l.strings, this, t) : l.type === 6 && (p = new qe(i, this, t)), this._$AV.push(p), l = r[++n];
363
363
  }
364
364
  a !== (l == null ? void 0 : l.index) && (i = M.nextNode(), a++);
365
365
  }
@@ -390,7 +390,7 @@ class et {
390
390
  return this._$AB;
391
391
  }
392
392
  _$AI(t, o = this) {
393
- t = D(this, t, o), Q(t) ? t === h || t == null || t === "" ? (this._$AH !== h && this._$AR(), this._$AH = h) : t !== this._$AH && t !== z && this._(t) : t._$litType$ !== void 0 ? this.$(t) : t.nodeType !== void 0 ? this.T(t) : Me(t) ? this.k(t) : this._(t);
393
+ t = D(this, t, o), Q(t) ? t === h || t == null || t === "" ? (this._$AH !== h && this._$AR(), this._$AH = h) : t !== this._$AH && t !== z && this._(t) : t._$litType$ !== void 0 ? this.$(t) : t.nodeType !== void 0 ? this.T(t) : Le(t) ? this.k(t) : this._(t);
394
394
  }
395
395
  O(t) {
396
396
  return this._$AA.parentNode.insertBefore(t, this._$AB);
@@ -403,10 +403,10 @@ class et {
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 = kt.createElement(de(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 = kt.createElement(pe(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 Ue(s, this), n = a.u(this.options);
409
+ const a = new je(s, this), n = a.u(this.options);
410
410
  a.p(o), this.T(n), this._$AH = a;
411
411
  }
412
412
  }
@@ -449,8 +449,8 @@ class ct {
449
449
  if (i === void 0) t = D(this, t, o, 0), a = !Q(t) || t !== this._$AH && t !== z, a && (this._$AH = t);
450
450
  else {
451
451
  const n = t;
452
- let l, u;
453
- for (t = i[0], l = 0; l < i.length - 1; l++) u = D(this, n[r + l], o, l), u === z && (u = this._$AH[l]), a || (a = !Q(u) || u !== this._$AH[l]), u === h ? t = h : t !== h && (t += (u ?? "") + i[l + 1]), this._$AH[l] = u;
452
+ let l, p;
453
+ for (t = i[0], l = 0; l < i.length - 1; l++) p = D(this, n[r + l], o, l), p === z && (p = this._$AH[l]), a || (a = !Q(p) || p !== this._$AH[l]), p === h ? t = h : t !== h && (t += (p ?? "") + i[l + 1]), this._$AH[l] = p;
454
454
  }
455
455
  a && !s && this.j(t);
456
456
  }
@@ -458,7 +458,7 @@ class ct {
458
458
  t === h ? this.element.removeAttribute(this.name) : this.element.setAttribute(this.name, t ?? "");
459
459
  }
460
460
  }
461
- let je = class extends ct {
461
+ let Be = class extends ct {
462
462
  constructor() {
463
463
  super(...arguments), this.type = 3;
464
464
  }
@@ -466,7 +466,7 @@ let je = class extends ct {
466
466
  this.element[this.name] = t === h ? void 0 : t;
467
467
  }
468
468
  };
469
- class Be extends ct {
469
+ class De extends ct {
470
470
  constructor() {
471
471
  super(...arguments), this.type = 4;
472
472
  }
@@ -474,7 +474,7 @@ class Be extends ct {
474
474
  this.element.toggleAttribute(this.name, !!t && t !== h);
475
475
  }
476
476
  }
477
- class De extends ct {
477
+ class Ve extends ct {
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 De extends ct {
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 Ve {
491
+ class qe {
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
  }
@@ -501,7 +501,7 @@ class Ve {
501
501
  }
502
502
  const gt = W.litHtmlPolyfillSupport;
503
503
  gt == null || gt(kt, et), (W.litHtmlVersions ?? (W.litHtmlVersions = [])).push("3.2.1");
504
- const qe = (e, t, o) => {
504
+ const He = (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) {
@@ -526,7 +526,7 @@ let j = class extends U {
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 = qe(o, this.renderRoot, this.renderOptions);
529
+ this.hasUpdated || (this.renderOptions.isConnected = this.isConnected), super.update(t), this._$Do = He(o, this.renderRoot, this.renderOptions);
530
530
  }
531
531
  connectedCallback() {
532
532
  var t;
@@ -540,8 +540,8 @@ let j = class extends U {
540
540
  return z;
541
541
  }
542
542
  };
543
- var ie;
544
- j._$litElement$ = !0, j.finalized = !0, (ie = globalThis.litElementHydrateSupport) == null || ie.call(globalThis, { LitElement: j });
543
+ var ae;
544
+ j._$litElement$ = !0, j.finalized = !0, (ae = globalThis.litElementHydrateSupport) == null || ae.call(globalThis, { LitElement: j });
545
545
  const vt = globalThis.litElementPolyfillSupport;
546
546
  vt == null || vt({ LitElement: j });
547
547
  (globalThis.litElementVersions ?? (globalThis.litElementVersions = [])).push("4.1.1");
@@ -560,7 +560,7 @@ const ot = (e) => (t, o) => {
560
560
  * Copyright 2017 Google LLC
561
561
  * SPDX-License-Identifier: BSD-3-Clause
562
562
  */
563
- const He = { attribute: !0, type: String, converter: at, reflect: !1, hasChanged: Et }, Fe = (e = He, t, o) => {
563
+ const Fe = { attribute: !0, type: String, converter: at, reflect: !1, hasChanged: Et }, Ye = (e = Fe, 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 He = { attribute: !0, type: String, converter: at, 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" ? Fe(e, t, o) : ((r, s, i) => {
585
+ return (t, o) => typeof o == "object" ? Ye(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);
@@ -596,50 +596,50 @@ function Ot(e) {
596
596
  return f({ ...e, state: !0, attribute: !1 });
597
597
  }
598
598
  var $ = /* @__PURE__ */ ((e) => (e.reaction = "reaction", e.stars = "stars", e.poll = "poll", e.text = "text", e.nps = "nps", e))($ || {});
599
- const Ye = "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='M640-160v-280h160v280H640Zm-240%200v-640h160v640H400Zm-240%200v-440h160v440H160Z'/%3e%3c/svg%3e", Ze = "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='M160-160v-440h160v440H160Zm240%200v-400l160%20160v240H400Zm160-354L400-674v-126h160v286Zm240%20240L640-434v-6h160v166Zm-9%20219L55-791l57-57%20736%20736-57%2057Z'/%3e%3c/svg%3e", Ge = "data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20height='24px'%20viewBox='0%20-960%20960%20960'%20width='24px'%20fill='currentColor'%3e%3cpath%20d='M200-200h57l391-391-57-57-391%20391v57Zm-80%2080v-170l528-527q12-11%2026.5-17t30.5-6q16%200%2031%206t26%2018l55%2056q12%2011%2017.5%2026t5.5%2030q0%2016-5.5%2030.5T817-647L290-120H120Zm640-584-56-56%2056%2056Zm-141%2085-28-29%2057%2057-29-28Z'/%3e%3c/svg%3e", Ke = "data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='16'%20height='16'%20fill='%23666666'%20class='bi%20bi-x'%20viewBox='0%200%2016%2016'%3e%3cpath%20d='M4.646%204.646a.5.5%200%200%201%20.708%200L8%207.293l2.646-2.647a.5.5%200%200%201%20.708.708L8.707%208l2.647%202.646a.5.5%200%200%201-.708.708L8%208.707l-2.646%202.647a.5.5%200%200%201-.708-.708L7.293%208%204.646%205.354a.5.5%200%200%201%200-.708'/%3e%3c/svg%3e";
600
- var We = { grad: 0.9, turn: 360, rad: 360 / (2 * Math.PI) }, A = function(e) {
599
+ const Ze = "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='M640-160v-280h160v280H640Zm-240%200v-640h160v640H400Zm-240%200v-440h160v440H160Z'/%3e%3c/svg%3e", Ge = "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='M160-160v-440h160v440H160Zm240%200v-400l160%20160v240H400Zm160-354L400-674v-126h160v286Zm240%20240L640-434v-6h160v166Zm-9%20219L55-791l57-57%20736%20736-57%2057Z'/%3e%3c/svg%3e", Ke = "data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20height='24px'%20viewBox='0%20-960%20960%20960'%20width='24px'%20fill='currentColor'%3e%3cpath%20d='M200-200h57l391-391-57-57-391%20391v57Zm-80%2080v-170l528-527q12-11%2026.5-17t30.5-6q16%200%2031%206t26%2018l55%2056q12%2011%2017.5%2026t5.5%2030q0%2016-5.5%2030.5T817-647L290-120H120Zm640-584-56-56%2056%2056Zm-141%2085-28-29%2057%2057-29-28Z'/%3e%3c/svg%3e", We = "data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='16'%20height='16'%20fill='%23666666'%20class='bi%20bi-x'%20viewBox='0%200%2016%2016'%3e%3cpath%20d='M4.646%204.646a.5.5%200%200%201%20.708%200L8%207.293l2.646-2.647a.5.5%200%200%201%20.708.708L8.707%208l2.647%202.646a.5.5%200%200%201-.708.708L8%208.707l-2.646%202.647a.5.5%200%200%201-.708-.708L7.293%208%204.646%205.354a.5.5%200%200%201%200-.708'/%3e%3c/svg%3e";
600
+ var Je = { grad: 0.9, turn: 360, rad: 360 / (2 * Math.PI) }, A = function(e) {
601
601
  return typeof e == "string" ? e.length > 0 : typeof e == "number";
602
602
  }, x = function(e, t, o) {
603
603
  return t === void 0 && (t = 0), o === void 0 && (o = Math.pow(10, t)), Math.round(o * e) / o + 0;
604
604
  }, S = function(e, t, o) {
605
605
  return t === void 0 && (t = 0), o === void 0 && (o = 1), e > o ? o : e > t ? e : t;
606
- }, ue = function(e) {
606
+ }, he = function(e) {
607
607
  return (e = isFinite(e) ? e % 360 : 0) > 0 ? e : e + 360;
608
608
  }, Yt = function(e) {
609
609
  return { r: S(e.r, 0, 255), g: S(e.g, 0, 255), b: S(e.b, 0, 255), a: S(e.a) };
610
610
  }, yt = function(e) {
611
611
  return { r: x(e.r), g: x(e.g), b: x(e.b), a: x(e.a, 3) };
612
- }, Je = /^#([0-9a-f]{3,8})$/i, rt = function(e) {
612
+ }, Xe = /^#([0-9a-f]{3,8})$/i, rt = function(e) {
613
613
  var t = e.toString(16);
614
614
  return t.length < 2 ? "0" + t : t;
615
- }, he = function(e) {
615
+ }, fe = function(e) {
616
616
  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), n = a ? i === t ? (o - r) / a : i === o ? 2 + (r - t) / a : 4 + (t - o) / a : 0;
617
617
  return { h: 60 * (n < 0 ? n + 6 : n), s: i ? a / i * 100 : 0, v: i / 255 * 100, a: s };
618
- }, fe = function(e) {
618
+ }, me = function(e) {
619
619
  var t = e.h, o = e.s, r = e.v, s = e.a;
620
620
  t = t / 360 * 6, o /= 100, r /= 100;
621
- var i = Math.floor(t), a = r * (1 - o), n = r * (1 - (t - i) * o), l = r * (1 - (1 - t + i) * o), u = i % 6;
622
- return { r: 255 * [r, n, a, a, l, r][u], g: 255 * [l, r, r, n, a, a][u], b: 255 * [a, a, l, r, r, n][u], a: s };
621
+ var i = Math.floor(t), a = r * (1 - o), n = r * (1 - (t - i) * o), l = r * (1 - (1 - t + i) * o), p = i % 6;
622
+ return { r: 255 * [r, n, a, a, l, r][p], g: 255 * [l, r, r, n, a, a][p], b: 255 * [a, a, l, r, r, n][p], a: s };
623
623
  }, Zt = function(e) {
624
- return { h: ue(e.h), s: S(e.s, 0, 100), l: S(e.l, 0, 100), a: S(e.a) };
624
+ return { h: he(e.h), s: S(e.s, 0, 100), l: S(e.l, 0, 100), a: S(e.a) };
625
625
  }, Gt = function(e) {
626
626
  return { h: x(e.h), s: x(e.s), l: x(e.l), a: x(e.a, 3) };
627
627
  }, Kt = function(e) {
628
- return fe((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 }));
628
+ 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 }));
629
629
  var t, o, r;
630
630
  }, J = function(e) {
631
- return { h: (t = he(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 };
631
+ return { h: (t = fe(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 };
632
632
  var t, o, r, s;
633
- }, Xe = /^hsla?\(\s*([+-]?\d*\.?\d+)(deg|rad|grad|turn)?\s*,\s*([+-]?\d*\.?\d+)%\s*,\s*([+-]?\d*\.?\d+)%\s*(?:,\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i, Qe = /^hsla?\(\s*([+-]?\d*\.?\d+)(deg|rad|grad|turn)?\s+([+-]?\d*\.?\d+)%\s+([+-]?\d*\.?\d+)%\s*(?:\/\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i, to = /^rgba?\(\s*([+-]?\d*\.?\d+)(%)?\s*,\s*([+-]?\d*\.?\d+)(%)?\s*,\s*([+-]?\d*\.?\d+)(%)?\s*(?:,\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i, eo = /^rgba?\(\s*([+-]?\d*\.?\d+)(%)?\s+([+-]?\d*\.?\d+)(%)?\s+([+-]?\d*\.?\d+)(%)?\s*(?:\/\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i, Wt = { string: [[function(e) {
634
- var t = Je.exec(e);
633
+ }, Qe = /^hsla?\(\s*([+-]?\d*\.?\d+)(deg|rad|grad|turn)?\s*,\s*([+-]?\d*\.?\d+)%\s*,\s*([+-]?\d*\.?\d+)%\s*(?:,\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i, to = /^hsla?\(\s*([+-]?\d*\.?\d+)(deg|rad|grad|turn)?\s+([+-]?\d*\.?\d+)%\s+([+-]?\d*\.?\d+)%\s*(?:\/\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i, eo = /^rgba?\(\s*([+-]?\d*\.?\d+)(%)?\s*,\s*([+-]?\d*\.?\d+)(%)?\s*,\s*([+-]?\d*\.?\d+)(%)?\s*(?:,\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i, oo = /^rgba?\(\s*([+-]?\d*\.?\d+)(%)?\s+([+-]?\d*\.?\d+)(%)?\s+([+-]?\d*\.?\d+)(%)?\s*(?:\/\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i, Wt = { string: [[function(e) {
634
+ var t = Xe.exec(e);
635
635
  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 ? x(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 ? x(parseInt(e.substr(6, 2), 16) / 255, 2) : 1 } : null : null;
636
636
  }, "hex"], [function(e) {
637
- var t = to.exec(e) || eo.exec(e);
637
+ var t = eo.exec(e) || oo.exec(e);
638
638
  return t ? t[2] !== t[4] || t[4] !== t[6] ? null : Yt({ 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;
639
639
  }, "rgb"], [function(e) {
640
- var t = Xe.exec(e) || Qe.exec(e);
640
+ var t = Qe.exec(e) || to.exec(e);
641
641
  if (!t) return null;
642
- var o, r, s = Zt({ h: (o = t[1], r = t[2], r === void 0 && (r = "deg"), Number(o) * (We[r] || 1)), s: Number(t[3]), l: Number(t[4]), a: t[5] === void 0 ? 1 : Number(t[5]) / (t[6] ? 100 : 1) });
642
+ var o, r, s = Zt({ h: (o = t[1], r = t[2], r === void 0 && (r = "deg"), Number(o) * (Je[r] || 1)), s: Number(t[3]), l: Number(t[4]), a: t[5] === void 0 ? 1 : Number(t[5]) / (t[6] ? 100 : 1) });
643
643
  return Kt(s);
644
644
  }, "hsl"]], object: [[function(e) {
645
645
  var t = e.r, o = e.g, r = e.b, s = e.a, i = s === void 0 ? 1 : s;
@@ -653,16 +653,16 @@ var We = { grad: 0.9, turn: 360, rad: 360 / (2 * Math.PI) }, A = function(e) {
653
653
  var t = e.h, o = e.s, r = e.v, s = e.a, i = s === void 0 ? 1 : s;
654
654
  if (!A(t) || !A(o) || !A(r)) return null;
655
655
  var a = function(n) {
656
- return { h: ue(n.h), s: S(n.s, 0, 100), v: S(n.v, 0, 100), a: S(n.a) };
656
+ return { h: he(n.h), s: S(n.s, 0, 100), v: S(n.v, 0, 100), a: S(n.a) };
657
657
  }({ h: Number(t), s: Number(o), v: Number(r), a: Number(i) });
658
- return fe(a);
658
+ return me(a);
659
659
  }, "hsv"]] }, Jt = function(e, t) {
660
660
  for (var o = 0; o < t.length; o++) {
661
661
  var r = t[o][0](e);
662
662
  if (r) return [r, t[o][1]];
663
663
  }
664
664
  return [null, void 0];
665
- }, oo = function(e) {
665
+ }, ro = function(e) {
666
666
  return typeof e == "string" ? Jt(e.trim(), Wt.string) : typeof e == "object" && e !== null ? Jt(e, Wt.object) : [null, void 0];
667
667
  }, wt = function(e, t) {
668
668
  var o = J(e);
@@ -674,7 +674,7 @@ var We = { grad: 0.9, turn: 360, rad: 360 / (2 * Math.PI) }, A = function(e) {
674
674
  return { h: o.h, s: o.s, l: S(o.l + 100 * t, 0, 100), a: o.a };
675
675
  }, Qt = function() {
676
676
  function e(t) {
677
- this.parsed = oo(t)[0], this.rgba = this.parsed || { r: 0, g: 0, b: 0, a: 1 };
677
+ this.parsed = ro(t)[0], this.rgba = this.parsed || { r: 0, g: 0, b: 0, a: 1 };
678
678
  }
679
679
  return e.prototype.isValid = function() {
680
680
  return this.parsed !== null;
@@ -698,7 +698,7 @@ var We = { grad: 0.9, turn: 360, rad: 360 / (2 * Math.PI) }, A = function(e) {
698
698
  return t = Gt(J(this.rgba)), o = t.h, r = t.s, s = t.l, (i = t.a) < 1 ? "hsla(" + o + ", " + r + "%, " + s + "%, " + i + ")" : "hsl(" + o + ", " + r + "%, " + s + "%)";
699
699
  var t, o, r, s, i;
700
700
  }, e.prototype.toHsv = function() {
701
- return t = he(this.rgba), { h: x(t.h), s: x(t.s), v: x(t.v), a: x(t.a, 3) };
701
+ return t = fe(this.rgba), { h: x(t.h), s: x(t.s), v: x(t.v), a: x(t.a, 3) };
702
702
  var t;
703
703
  }, e.prototype.invert = function() {
704
704
  return C({ r: 255 - (t = this.rgba).r, g: 255 - t.g, b: 255 - t.b, a: t.a });
@@ -728,7 +728,7 @@ var We = { grad: 0.9, turn: 360, rad: 360 / (2 * Math.PI) }, A = function(e) {
728
728
  return e instanceof Qt ? e : new Qt(e);
729
729
  };
730
730
  const xt = process.env.NODE_ENV === "development" || process.env.NODE_ENV === "test";
731
- function ro(e) {
731
+ function so(e) {
732
732
  return {
733
733
  debug: (t, ...o) => {
734
734
  xt && console.debug(`[${e}]`, t, ...o);
@@ -744,9 +744,9 @@ function ro(e) {
744
744
  }
745
745
  };
746
746
  }
747
- const m = ro("Pollcatch");
748
- var me = /* @__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))(me || {});
749
- const so = {
747
+ const b = so("Pollcatch");
748
+ var be = /* @__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))(be || {});
749
+ const io = {
750
750
  black: "#000000",
751
751
  white: "#ffffff",
752
752
  red: "#ff0000",
@@ -763,21 +763,21 @@ const so = {
763
763
  teal: "#008080",
764
764
  navy: "#000080"
765
765
  };
766
- function io(e) {
766
+ function ao(e) {
767
767
  const t = e.toLowerCase().trim();
768
- return so[t] || null;
768
+ return io[t] || null;
769
769
  }
770
770
  function St(e, t) {
771
771
  const o = te(e), r = te(t), s = Math.max(o, r), i = Math.min(o, r);
772
772
  return (s + 0.05) / (i + 0.05);
773
773
  }
774
774
  function te(e) {
775
- const t = no(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), n = s <= 0.03928 ? s / 12.92 : Math.pow((s + 0.055) / 1.055, 2.4);
775
+ const t = lo(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), n = s <= 0.03928 ? s / 12.92 : Math.pow((s + 0.055) / 1.055, 2.4);
776
776
  return 0.2126 * i + 0.7152 * a + 0.0722 * n;
777
777
  }
778
- function ao(e, t = {}) {
778
+ function no(e, t = {}) {
779
779
  if (!C(e).isValid())
780
- return m.warn(`Invalid color provided: ${e}`), "black";
780
+ return b.warn(`Invalid color provided: ${e}`), "black";
781
781
  const {
782
782
  minContrast: r = 4.5,
783
783
  colorOptions: s = ["black", "white", "light", "dark"],
@@ -787,29 +787,29 @@ function ao(e, t = {}) {
787
787
  },
788
788
  fallback: a = "white"
789
789
  } = t, n = s.map((c) => c === "black" ? "#000000" : c === "white" ? "#ffffff" : c === "light" ? i.light || "#f8f9fa" : c === "dark" ? i.dark || "#343a40" : c);
790
- let l = a, u = 0;
790
+ let l = a, p = 0;
791
791
  for (const c of n) {
792
- const p = St(e, c);
793
- p >= r && p > u && (u = p, l = c);
792
+ const u = St(e, c);
793
+ u >= r && u > p && (p = u, l = c);
794
794
  }
795
- if (u === 0) {
795
+ if (p === 0) {
796
796
  const c = St(e, a);
797
- l = a, u = c;
798
- for (const p of n) {
799
- if (p === a) continue;
800
- const w = St(e, p);
801
- w > u && (u = w, l = p);
797
+ l = a, p = c;
798
+ for (const u of n) {
799
+ if (u === a) continue;
800
+ const w = St(e, u);
801
+ w > p && (p = w, l = u);
802
802
  }
803
- m.warn(
804
- `No color option met the minimum contrast ratio of ${r}:1 against ${e}. Using ${l} with contrast ratio ${u.toFixed(2)}:1 instead.`
803
+ b.warn(
804
+ `No color option met the minimum contrast ratio of ${r}:1 against ${e}. Using ${l} with contrast ratio ${p.toFixed(2)}:1 instead.`
805
805
  );
806
806
  }
807
807
  return l;
808
808
  }
809
- function no(e) {
810
- const o = io(e) || e, r = C(o);
809
+ function lo(e) {
810
+ const o = ao(e) || e, r = C(o);
811
811
  if (!r.isValid())
812
- return m.warn(`Invalid color provided: ${e}`), { r: 0, g: 0, b: 0 };
812
+ return b.warn(`Invalid color provided: ${e}`), { r: 0, g: 0, b: 0 };
813
813
  const { r: s, g: i, b: a } = r.toRgb();
814
814
  return { r: s, g: i, b: a };
815
815
  }
@@ -825,24 +825,24 @@ function k(e, t) {
825
825
  }[t] : void 0;
826
826
  return e === "left" || e === "right" ? r || "center" : e === "top" || e === "bottom" ? r || "start" : r || "center";
827
827
  }
828
- function lo(e, t = "1rem") {
828
+ function ee(e, t = "1rem", o = 1) {
829
829
  if (!e) return t;
830
- const o = {
831
- xs: "0.75rem",
832
- sm: "0.875rem",
833
- md: "1rem",
834
- lg: "1.25rem",
835
- xl: "1.5rem"
836
- }, r = e.toLowerCase().trim();
837
- if (o[r])
838
- return o[r];
839
- const s = e.trim().replace(/\s+/g, " ");
830
+ const r = {
831
+ xs: 0.75,
832
+ sm: 0.875,
833
+ md: 1,
834
+ lg: 1.25,
835
+ xl: 1.5
836
+ }, s = e.toLowerCase().trim();
837
+ if (r[s] !== void 0)
838
+ return `${r[s] * o}rem`;
839
+ const i = e.trim().replace(/\s+/g, " ");
840
840
  if (/\d+(\.\d+)?\s*(px|em|rem|%|vh|vw|pt|pc|in|cm|mm|ex|ch|vmin|vmax)$/i.test(
841
- s
841
+ i
842
842
  ))
843
- return s.replace(/\s+/g, "");
844
- const a = parseFloat(s);
845
- return isNaN(a) ? t : `${a}rem`;
843
+ return i.replace(/\s+/g, "");
844
+ const n = parseFloat(i);
845
+ return isNaN(n) ? t : `${n}rem`;
846
846
  }
847
847
  function co(e, t = "4px") {
848
848
  if (!e) return t;
@@ -901,11 +901,11 @@ function ho(e) {
901
901
  return /^(#[0-9a-fA-F]{3,8}|rgb\([^)]+\)|rgba\([^)]+\)|hsl\([^)]+\)|hsla\([^)]+\)|[a-zA-Z]+)$/.test(t);
902
902
  }
903
903
  function R(e) {
904
- return ho(e) ? e.replace(/[<>"']/g, "").trim() : (m.warn("Invalid color value:", e), "#000000");
904
+ return ho(e) ? e.replace(/[<>"']/g, "").trim() : (b.warn("Invalid color value:", e), "#000000");
905
905
  }
906
906
  function fo(e) {
907
907
  if (typeof e != "string")
908
- return m.warn("Non-string value passed to sanitizeCSS:", typeof e), "";
908
+ return b.warn("Non-string value passed to sanitizeCSS:", typeof e), "";
909
909
  let t = e;
910
910
  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;
911
911
  }
@@ -915,9 +915,9 @@ function mo(e) {
915
915
  (t, o, r, s, i) => s ? t : `${o}: ${r.trim()} !important${i}`
916
916
  );
917
917
  }
918
- const ee = "https://jpxwfjorwcsrqraorpbj.supabase.co/functions/v1/data", bo = "pc_session_id", go = 24 * 60 * 60 * 1e3;
919
- function oe() {
920
- return typeof crypto < "u" && typeof crypto.randomUUID == "function" ? crypto.randomUUID() : (m.warn("crypto.randomUUID not available, using fallback UUID generator"), "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g, function(e) {
918
+ const oe = "https://jpxwfjorwcsrqraorpbj.supabase.co/functions/v1/data", bo = "pc_session_id", go = 24 * 60 * 60 * 1e3;
919
+ function re() {
920
+ return typeof crypto < "u" && typeof crypto.randomUUID == "function" ? crypto.randomUUID() : (b.warn("crypto.randomUUID not available, using fallback UUID generator"), "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g, function(e) {
921
921
  const t = Math.random() * 16 | 0;
922
922
  return (e === "x" ? t : t & 3 | 8).toString(16);
923
923
  }));
@@ -927,56 +927,56 @@ function Tt() {
927
927
  try {
928
928
  return localStorage.setItem(e, e), localStorage.removeItem(e), !0;
929
929
  } catch {
930
- return m.warn("localStorage not available, session ID will not persist"), !1;
930
+ return b.warn("localStorage not available, session ID will not persist"), !1;
931
931
  }
932
932
  }
933
- function be(e) {
933
+ function ge(e) {
934
934
  try {
935
935
  const t = localStorage.getItem(e);
936
936
  return t ? JSON.parse(t) : void 0;
937
937
  } catch (t) {
938
- m.warn(`Failed to get item from localStorage: ${e}`, t);
938
+ b.warn(`Failed to get item from localStorage: ${e}`, t);
939
939
  return;
940
940
  }
941
941
  }
942
- function ge(e, t) {
942
+ function ve(e, t) {
943
943
  try {
944
944
  return localStorage.setItem(e, JSON.stringify(t)), !0;
945
945
  } catch (o) {
946
- return m.warn(`Failed to set item in localStorage: ${e}`, o), !1;
946
+ return b.warn(`Failed to set item in localStorage: ${e}`, o), !1;
947
947
  }
948
948
  }
949
949
  async function vo() {
950
950
  if (typeof window < "u") {
951
951
  if (window.pcProject !== void 0)
952
- return m.debug("Found project key in global variable"), window.pcProject;
952
+ return b.debug("Found project key in global variable"), window.pcProject;
953
953
  const e = document.querySelectorAll("script[pc-project]");
954
954
  if (e.length > 0) {
955
955
  const t = e[e.length - 1], o = t == null ? void 0 : t.getAttribute("pc-project");
956
956
  if (o)
957
- return m.debug("Found project key in script tag attribute"), o;
957
+ return b.debug("Found project key in script tag attribute"), o;
958
958
  }
959
959
  }
960
- m.warn("No project key found in global variable or script tags");
960
+ b.warn("No project key found in global variable or script tags");
961
961
  }
962
- async function re() {
962
+ async function se() {
963
963
  const e = bo, t = go;
964
964
  if (Tt()) {
965
- const o = be(e);
965
+ const o = ge(e);
966
966
  if (o && o.id && o.timestamp && Date.now() - o.timestamp < t)
967
- return m.debug("Using existing session ID from localStorage"), o.id;
968
- m.debug(
967
+ return b.debug("Using existing session ID from localStorage"), o.id;
968
+ b.debug(
969
969
  o ? "Session ID expired" : "No session ID found",
970
970
  "generating new one"
971
971
  );
972
- const r = oe();
973
- return ge(e, {
972
+ const r = re();
973
+ return ve(e, {
974
974
  id: r,
975
975
  timestamp: Date.now()
976
- }) ? m.debug("Generated and stored new session ID") : m.warn("Generated session ID but failed to store it"), r;
976
+ }) ? b.debug("Generated and stored new session ID") : b.warn("Generated session ID but failed to store it"), r;
977
977
  } else {
978
- const o = oe();
979
- return m.debug("Generated non-persistent session ID"), o;
978
+ const o = re();
979
+ return b.debug("Generated non-persistent session ID"), o;
980
980
  }
981
981
  }
982
982
  function lt(e) {
@@ -1006,19 +1006,19 @@ function yo(e) {
1006
1006
  if (!Tt())
1007
1007
  return O();
1008
1008
  try {
1009
- const t = be(e);
1009
+ const t = ge(e);
1010
1010
  return t ? { ...O(), ...t } : O();
1011
1011
  } catch (t) {
1012
- return m.warn("Failed to load localStats from localStorage", t), O();
1012
+ return b.warn("Failed to load localStats from localStorage", t), O();
1013
1013
  }
1014
1014
  }
1015
1015
  function wo(e, t) {
1016
1016
  if (!Tt())
1017
1017
  return !1;
1018
1018
  try {
1019
- return ge(e, t) ? (m.debug("Saved localStats to localStorage", t), !0) : !1;
1019
+ return ve(e, t) ? (b.debug("Saved localStats to localStorage", t), !0) : !1;
1020
1020
  } catch (o) {
1021
- return m.warn("Failed to save localStats to localStorage", o), !1;
1021
+ return b.warn("Failed to save localStats to localStorage", o), !1;
1022
1022
  }
1023
1023
  }
1024
1024
  function $o(e, t) {
@@ -1057,7 +1057,7 @@ function xo(e, t) {
1057
1057
  }
1058
1058
  return o.nps = lt((o == null ? void 0 : o.breakdown) || {}), o;
1059
1059
  }
1060
- function ve(e) {
1060
+ function ye(e) {
1061
1061
  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);
1062
1062
  }
1063
1063
  function dt(e) {
@@ -1118,7 +1118,7 @@ class _o {
1118
1118
  return this.host.project || await vo() || "public";
1119
1119
  }
1120
1120
  async getLocalStatsKey() {
1121
- const t = this.host, o = await re(), r = await this.getProjectId(), s = t.name || "unnamed";
1121
+ const t = this.host, o = await se(), r = await this.getProjectId(), s = t.name || "unnamed";
1122
1122
  return `pc-local-stats-${o}-${r}-${s}`;
1123
1123
  }
1124
1124
  /**
@@ -1146,42 +1146,42 @@ class _o {
1146
1146
  }
1147
1147
  let a, n;
1148
1148
  if (i && typeof i == "function") {
1149
- const p = this.getOptionsForDataFunc(t);
1150
- if (m.debug(`Using data function for: ${r}`, {
1149
+ const u = this.getOptionsForDataFunc(t);
1150
+ if (b.debug(`Using data function for: ${r}`, {
1151
1151
  dataFuncName: t.dataFunc,
1152
1152
  projectKey: o,
1153
- options: p
1154
- }), a = await i(o, r, p), a && typeof a == "object" && "success" in a && "data" in a) {
1153
+ options: u
1154
+ }), a = await i(o, r, u), a && typeof a == "object" && "success" in a && "data" in a) {
1155
1155
  if (!a.success)
1156
- throw m.error("Custom data function returned unsuccessful response", a), new Error("Custom data function returned unsuccessful response");
1156
+ throw b.error("Custom data function returned unsuccessful response", a), new Error("Custom data function returned unsuccessful response");
1157
1157
  n = a.data || {};
1158
1158
  } else
1159
1159
  n = a || {};
1160
1160
  } else {
1161
- const p = t.dataEndpoint || ee;
1161
+ const u = t.dataEndpoint || oe;
1162
1162
  if (!r)
1163
1163
  throw new Error("Name parameter is required");
1164
- const w = `${p}/${encodeURIComponent(o)}/${encodeURIComponent(r)}`;
1165
- m.debug(`Fetching stats for: ${r}`, { endpoint: p, projectKey: o });
1164
+ const w = `${u}/${encodeURIComponent(o)}/${encodeURIComponent(r)}`;
1165
+ b.debug(`Fetching stats for: ${r}`, { endpoint: u, projectKey: o });
1166
1166
  const v = await fetch(w);
1167
1167
  if (!v.ok)
1168
1168
  throw new Error(`API request failed with status: ${v.status}`);
1169
1169
  if (a = await v.json(), !a.success)
1170
- throw m.error("Backend returned unsuccessful response", a), new Error("Backend returned unsuccessful response");
1170
+ throw b.error("Backend returned unsuccessful response", a), new Error("Backend returned unsuccessful response");
1171
1171
  n = a.data || {};
1172
1172
  }
1173
- const l = n.count > 0 ? Math.round(n.sum / n.count) : 0, u = Math.round(n.sum / n.count * 100), c = {
1173
+ const l = n.count > 0 ? Math.round(n.sum / n.count) : 0, p = Math.round(n.sum / n.count * 100), c = {
1174
1174
  count: n.count ?? 0,
1175
1175
  sum: n.sum,
1176
1176
  avg: l,
1177
- pct: u,
1177
+ pct: p,
1178
1178
  nps: s === $.nps ? lt((n == null ? void 0 : n.breakdown) || {}) : 0,
1179
1179
  breakdown: n.breakdown ?? {},
1180
1180
  updated: n.updated_at || (/* @__PURE__ */ new Date()).toISOString()
1181
1181
  };
1182
1182
  this.stats = c;
1183
1183
  } catch (o) {
1184
- throw m.error("Error loading stats:", o, this.localStats), o;
1184
+ throw b.error("Error loading stats:", o, this.localStats), o;
1185
1185
  } finally {
1186
1186
  this.isLoading = !1, this.host.requestUpdate();
1187
1187
  }
@@ -1213,9 +1213,9 @@ class _o {
1213
1213
  const t = await this.getLocalStatsKey();
1214
1214
  try {
1215
1215
  const o = yo(t);
1216
- m.debug("Loaded localStats from localStorage", o), this.localStats = o;
1216
+ b.debug("Loaded localStats from localStorage", o), this.localStats = o;
1217
1217
  } catch (o) {
1218
- m.warn("Failed to generate localStorage key for localStats", o), this.localStats = O();
1218
+ b.warn("Failed to generate localStorage key for localStats", o), this.localStats = O();
1219
1219
  }
1220
1220
  this.host.requestUpdate();
1221
1221
  }
@@ -1225,9 +1225,9 @@ class _o {
1225
1225
  async persistLocalStats() {
1226
1226
  try {
1227
1227
  const t = await this.getLocalStatsKey();
1228
- wo(t, this.localStats) || m.warn("Failed to save localStats to localStorage");
1228
+ wo(t, this.localStats) || b.warn("Failed to save localStats to localStorage");
1229
1229
  } catch (t) {
1230
- m.warn("Failed to save localStats to localStorage", t);
1230
+ b.warn("Failed to save localStats to localStorage", t);
1231
1231
  }
1232
1232
  }
1233
1233
  /**
@@ -1255,15 +1255,15 @@ class _o {
1255
1255
  }, o && o.length > 0)
1256
1256
  for (const s of o)
1257
1257
  s && (this.localStats.breakdown[s] = 1);
1258
- this.stats = xo(this.stats, this.localStats), m.debug("Stats updated - remote: ", this.stats), m.debug("Stats updated - local: ", this.stats), this.persistLocalStats(), this.host.requestUpdate();
1258
+ this.stats = xo(this.stats, this.localStats), b.debug("Stats updated - remote: ", this.stats), b.debug("Stats updated - local: ", this.stats), this.persistLocalStats(), this.host.requestUpdate();
1259
1259
  }
1260
1260
  async markStatsAsSubmitted() {
1261
1261
  this.localStats.submitted = (/* @__PURE__ */ new Date()).toISOString(), await this.persistLocalStats(), this.host.requestUpdate();
1262
1262
  }
1263
1263
  async submitStats() {
1264
1264
  if (!this.hasLocalStats() && !this.hasInteracted)
1265
- throw m.warn("No local stats to submit"), new Error("No local stats to submit");
1266
- const t = this.host, o = Math.floor(Date.now() / 1e3).toString(), r = await re(), s = await this.getProjectId(), i = t.name || "", a = this.localStats.sum, n = Object.keys(this.localStats.breakdown || {});
1265
+ throw b.warn("No local stats to submit"), new Error("No local stats to submit");
1266
+ const t = this.host, o = Math.floor(Date.now() / 1e3).toString(), r = await se(), s = await this.getProjectId(), i = t.name || "", a = this.localStats.sum, n = Object.keys(this.localStats.breakdown || {});
1267
1267
  this.isSubmitting = !0, this.host.requestUpdate();
1268
1268
  const l = {
1269
1269
  sessionId: r,
@@ -1275,31 +1275,31 @@ class _o {
1275
1275
  textValues: n,
1276
1276
  metadata: t.metadata,
1277
1277
  timestamp: o
1278
- }, u = ko(JSON.stringify(l), o);
1278
+ }, p = ko(JSON.stringify(l), o);
1279
1279
  try {
1280
- await this.sendStats({ ...l, hash: u }), await this.markStatsAsSubmitted(), this.dispatchSubmitEvent(l);
1280
+ await this.sendStats({ ...l, hash: p }), await this.markStatsAsSubmitted(), this.dispatchSubmitEvent(l);
1281
1281
  } catch (c) {
1282
- m.warn("Failed to send stats event", c);
1282
+ b.warn("Failed to send stats event", c);
1283
1283
  } finally {
1284
1284
  this.isSubmitting = !1, this.host.requestUpdate();
1285
1285
  }
1286
1286
  return l;
1287
1287
  }
1288
1288
  async sendStats(t) {
1289
- const o = JSON.stringify(t), r = this.host, s = r.dataEndpoint || ee;
1289
+ const o = JSON.stringify(t), r = this.host, s = r.dataEndpoint || oe;
1290
1290
  if (r.dataFunc) {
1291
- m.debug("Skip sending stats as data function is in use.");
1291
+ b.debug("Skip sending stats as data function is in use.");
1292
1292
  return;
1293
1293
  }
1294
1294
  if (!dt(s))
1295
- throw m.error("Invalid data endpoint", { dataEndpoint: s }), new Error(`Invalid data endpoint: ${s}`);
1295
+ throw b.error("Invalid data endpoint", { dataEndpoint: s }), new Error(`Invalid data endpoint: ${s}`);
1296
1296
  try {
1297
- if (m.debug("Sending stats", { endpoint: s, event: t }), typeof navigator < "u" && navigator.sendBeacon)
1297
+ if (b.debug("Sending stats", { endpoint: s, event: t }), typeof navigator < "u" && navigator.sendBeacon)
1298
1298
  if (navigator.sendBeacon(s, o)) {
1299
- m.debug("Successfully sent stats via sendBeacon");
1299
+ b.debug("Successfully sent stats via sendBeacon");
1300
1300
  return;
1301
1301
  } else
1302
- m.debug("sendBeacon failed, falling back to fetch");
1302
+ b.debug("sendBeacon failed, falling back to fetch");
1303
1303
  const i = await fetch(s, {
1304
1304
  body: o,
1305
1305
  method: "POST",
@@ -1310,9 +1310,9 @@ class _o {
1310
1310
  });
1311
1311
  if (!i.ok)
1312
1312
  throw new Error(`API request failed with status: ${i.status}`);
1313
- m.debug("Successfully sent stats via fetch");
1313
+ b.debug("Successfully sent stats via fetch");
1314
1314
  } catch (i) {
1315
- throw m.error("Failed to send analytics:", i), i;
1315
+ throw b.error("Failed to send analytics:", i), i;
1316
1316
  }
1317
1317
  }
1318
1318
  /**
@@ -1329,7 +1329,7 @@ class _o {
1329
1329
  pct: (o == null ? void 0 : o.pct) || 0,
1330
1330
  nps: r.type === $.nps ? lt((o == null ? void 0 : o.breakdown) || {}) : 0
1331
1331
  };
1332
- return m.debug("Stats data: ", this.stats), Co(t, s);
1332
+ return b.debug("Stats data: ", this.stats), Co(t, s);
1333
1333
  }
1334
1334
  /**
1335
1335
  * Checks if a value is selected in the local stats
@@ -1357,7 +1357,7 @@ class _o {
1357
1357
  let a = 1;
1358
1358
  if ((i.type === $.stars || i.type === $.nps) && (a = parseInt(t)), s)
1359
1359
  if (o) {
1360
- const l = r.filter((u) => u !== t);
1360
+ const l = r.filter((p) => p !== t);
1361
1361
  this.updateStats(l.length > 0 ? 1 : 0, l);
1362
1362
  } else
1363
1363
  this.updateStats(0, []);
@@ -1389,7 +1389,7 @@ class _o {
1389
1389
  bubbles: !0,
1390
1390
  composed: !0
1391
1391
  });
1392
- t.dispatchEvent(i), m.debug("Dispatched change event", s);
1392
+ t.dispatchEvent(i), b.debug("Dispatched change event", s);
1393
1393
  }
1394
1394
  /**
1395
1395
  * Dispatches a 'submit' CustomEvent on the host element
@@ -1401,7 +1401,7 @@ class _o {
1401
1401
  bubbles: !0,
1402
1402
  composed: !0
1403
1403
  });
1404
- o.dispatchEvent(r), m.debug("Dispatched submit event", t);
1404
+ o.dispatchEvent(r), b.debug("Dispatched submit event", t);
1405
1405
  }
1406
1406
  hasLocalStats() {
1407
1407
  var t;
@@ -1501,7 +1501,7 @@ class Eo {
1501
1501
  }
1502
1502
  }
1503
1503
  var zt = /* @__PURE__ */ ((e) => (e.DECORATIVE = "decorative", e.FUNCTIONAL = "functional", e.STATUS = "status", e))(zt || {});
1504
- function ye(e, t = {}) {
1504
+ function we(e, t = {}) {
1505
1505
  const { type: o = "functional", alt: r, ariaLabel: s, isSelected: i } = t;
1506
1506
  if (!e)
1507
1507
  return { alt: "", ariaHidden: !0 };
@@ -1531,8 +1531,8 @@ function Oo(e, t) {
1531
1531
  * Copyright 2017 Google LLC
1532
1532
  * SPDX-License-Identifier: BSD-3-Clause
1533
1533
  */
1534
- const we = { ATTRIBUTE: 1 }, $e = (e) => (...t) => ({ _$litDirective$: e, values: t });
1535
- let xe = class {
1534
+ const $e = { ATTRIBUTE: 1 }, xe = (e) => (...t) => ({ _$litDirective$: e, values: t });
1535
+ let Se = class {
1536
1536
  constructor(t) {
1537
1537
  }
1538
1538
  get _$AU() {
@@ -1553,10 +1553,10 @@ let xe = class {
1553
1553
  * Copyright 2018 Google LLC
1554
1554
  * SPDX-License-Identifier: BSD-3-Clause
1555
1555
  */
1556
- const y = $e(class extends xe {
1556
+ const y = xe(class extends Se {
1557
1557
  constructor(e) {
1558
1558
  var t;
1559
- if (super(e), e.type !== we.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.");
1559
+ if (super(e), e.type !== $e.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.");
1560
1560
  }
1561
1561
  render(e) {
1562
1562
  return " " + Object.keys(e).filter((t) => e[t]).join(" ") + " ";
@@ -1588,7 +1588,7 @@ const st = {
1588
1588
  desktop: "1024px"
1589
1589
  }, Mt = class Mt extends j {
1590
1590
  constructor() {
1591
- super(...arguments), this.dataController = new _o(this), this.displayController = new Eo(this, this.dataController), this.hasEditButton = !0, this.showStats = "never", this.showChart = !1, this.initialized = !1, this.lockAnswer = !1, this.ariaLabel = null, this.minContrast = me.AA_NORMAL, this.options = [], this.project = "public", this.questionPosition = "top", this.statsText = "{count} votes", this.buttonText = "Submit", this.buttonRadius = "sm", this.multiple = !1, this.readOnly = !1, this.handleEditToggleKeyDown = (t) => {
1591
+ super(...arguments), this.dataController = new _o(this), this.displayController = new Eo(this, this.dataController), this.hasEditButton = !0, this.showStats = "never", this.showChart = !1, this.initialized = !1, this.lockAnswer = !1, this.ariaLabel = null, this.minContrast = be.AA_NORMAL, this.options = [], this.project = "public", this.questionPosition = "top", this.statsText = "{count} votes", this.buttonText = "Submit", this.buttonRadius = "sm", this.multiple = !1, this.readOnly = !1, this.handleEditToggleKeyDown = (t) => {
1592
1592
  (t.key === "Enter" || t.key === " ") && (t.preventDefault(), this.handleEnterEditMode());
1593
1593
  };
1594
1594
  }
@@ -1623,7 +1623,7 @@ const st = {
1623
1623
  const i = R(this.primaryColor);
1624
1624
  o += `--pc-primary-color: ${i} !important;
1625
1625
  `;
1626
- const a = ao(i, {
1626
+ const a = no(i, {
1627
1627
  minContrast: this.minContrast,
1628
1628
  colorOptions: ["black", "white", "light", "dark"]
1629
1629
  });
@@ -1653,8 +1653,13 @@ const st = {
1653
1653
  }
1654
1654
  const s = this.starHoverColor || (r ? `color-mix(in srgb, ${R(r)} 80%, white)` : null);
1655
1655
  if (s && (o += `--pc-star-hover-color: ${s} !important;
1656
- `), this.size) {
1657
- const i = lo(this.size);
1656
+ `), this.starSize) {
1657
+ const i = ee(this.starSize, "1rem", 1.5);
1658
+ o += `--pc-stars-star-size: ${i} !important;
1659
+ `;
1660
+ }
1661
+ if (this.size) {
1662
+ const i = ee(this.size);
1658
1663
  o += `font-size: ${i} !important;
1659
1664
  `;
1660
1665
  }
@@ -1719,7 +1724,7 @@ const st = {
1719
1724
  renderEditToggleIcon(t = "edit-toggle-button") {
1720
1725
  return this.displayController.shouldShowEditButton() ? d`
1721
1726
  <img
1722
- src="${Ge}"
1727
+ src="${Ke}"
1723
1728
  alt="Edit vote"
1724
1729
  class="edit-toggle-icon"
1725
1730
  data-testid="${t}"
@@ -1738,7 +1743,7 @@ const st = {
1738
1743
  renderChartToggle() {
1739
1744
  return this.displayController.shouldShowChartToggle() ? d`
1740
1745
  <img
1741
- src="${this.displayController.isChartVisible ? Ze : Ye}"
1746
+ src="${this.displayController.isChartVisible ? Ge : Ze}"
1742
1747
  alt="${this.displayController.isChartVisible ? "Hide chart" : "Show chart"}"
1743
1748
  class="chart-toggle-icon"
1744
1749
  data-testid="chart-toggle-button"
@@ -1779,7 +1784,7 @@ const st = {
1779
1784
  <div class="pc-thank-you-msg" data-testid="thank-you-msg">
1780
1785
  ${t}
1781
1786
  <img
1782
- src="${Ke}"
1787
+ src="${We}"
1783
1788
  alt="Close"
1784
1789
  class="thank-you-close-icon"
1785
1790
  data-testid="close-thank-you-button"
@@ -1882,106 +1887,109 @@ Mt.styles = [
1882
1887
  }
1883
1888
  `
1884
1889
  ];
1885
- let b = Mt;
1890
+ let m = Mt;
1886
1891
  g([
1887
1892
  f({ type: String, attribute: "show-stats" })
1888
- ], b.prototype, "showStats");
1893
+ ], m.prototype, "showStats");
1889
1894
  g([
1890
1895
  f({ type: Boolean, attribute: "show-chart" })
1891
- ], b.prototype, "showChart");
1896
+ ], m.prototype, "showChart");
1892
1897
  g([
1893
1898
  f({ type: Boolean, attribute: "initialized" })
1894
- ], b.prototype, "initialized");
1899
+ ], m.prototype, "initialized");
1895
1900
  g([
1896
1901
  f({ type: Boolean, attribute: "lock-answer" })
1897
- ], b.prototype, "lockAnswer");
1902
+ ], m.prototype, "lockAnswer");
1898
1903
  g([
1899
1904
  f({ type: String, attribute: "primary-color" })
1900
- ], b.prototype, "primaryColor");
1905
+ ], m.prototype, "primaryColor");
1901
1906
  g([
1902
1907
  f({ type: String, attribute: "mute-color" })
1903
- ], b.prototype, "muteColor");
1908
+ ], m.prototype, "muteColor");
1904
1909
  g([
1905
1910
  f({ type: String, attribute: "text-color" })
1906
- ], b.prototype, "textColor");
1911
+ ], m.prototype, "textColor");
1907
1912
  g([
1908
1913
  f({ type: String, attribute: "background-color" })
1909
- ], b.prototype, "backgroundColor");
1914
+ ], m.prototype, "backgroundColor");
1910
1915
  g([
1911
1916
  f({ type: String, attribute: "accent-color" })
1912
- ], b.prototype, "accentColor");
1917
+ ], m.prototype, "accentColor");
1913
1918
  g([
1914
1919
  f({ type: String, attribute: "star-color" })
1915
- ], b.prototype, "starColor");
1920
+ ], m.prototype, "starColor");
1916
1921
  g([
1917
1922
  f({ type: String, attribute: "star-hover-color" })
1918
- ], b.prototype, "starHoverColor");
1923
+ ], m.prototype, "starHoverColor");
1924
+ g([
1925
+ f({ type: String, attribute: "star-size" })
1926
+ ], m.prototype, "starSize");
1919
1927
  g([
1920
1928
  f({ type: String })
1921
- ], b.prototype, "size");
1929
+ ], m.prototype, "size");
1922
1930
  g([
1923
1931
  f({ type: String, attribute: "aria-label" })
1924
- ], b.prototype, "ariaLabel");
1932
+ ], m.prototype, "ariaLabel");
1925
1933
  g([
1926
1934
  f({ type: String, attribute: "aria-describedby" })
1927
- ], b.prototype, "ariaDescribedby");
1935
+ ], m.prototype, "ariaDescribedby");
1928
1936
  g([
1929
1937
  f({ type: Number, attribute: "min-contrast" })
1930
- ], b.prototype, "minContrast");
1938
+ ], m.prototype, "minContrast");
1931
1939
  g([
1932
1940
  f({ type: String })
1933
- ], b.prototype, "css");
1941
+ ], m.prototype, "css");
1934
1942
  g([
1935
1943
  f({ type: Array })
1936
- ], b.prototype, "options");
1944
+ ], m.prototype, "options");
1937
1945
  g([
1938
1946
  f({ type: String })
1939
- ], b.prototype, "project");
1947
+ ], m.prototype, "project");
1940
1948
  g([
1941
1949
  f({ type: String, attribute: "name" })
1942
- ], b.prototype, "name");
1950
+ ], m.prototype, "name");
1943
1951
  g([
1944
1952
  f({ type: String })
1945
- ], b.prototype, "metadata");
1953
+ ], m.prototype, "metadata");
1946
1954
  g([
1947
1955
  f({ type: String, attribute: "data-func" })
1948
- ], b.prototype, "dataFunc");
1956
+ ], m.prototype, "dataFunc");
1949
1957
  g([
1950
1958
  f({ type: String, attribute: "data-endpoint" })
1951
- ], b.prototype, "dataEndpoint");
1959
+ ], m.prototype, "dataEndpoint");
1952
1960
  g([
1953
1961
  f({ type: String })
1954
- ], b.prototype, "question");
1962
+ ], m.prototype, "question");
1955
1963
  g([
1956
1964
  f({ type: String, attribute: "question-position" })
1957
- ], b.prototype, "questionPosition");
1965
+ ], m.prototype, "questionPosition");
1958
1966
  g([
1959
1967
  f({ type: String, attribute: "question-align" })
1960
- ], b.prototype, "questionAlign");
1968
+ ], m.prototype, "questionAlign");
1961
1969
  g([
1962
1970
  f({ type: String, attribute: "stats-text" })
1963
- ], b.prototype, "statsText");
1971
+ ], m.prototype, "statsText");
1964
1972
  g([
1965
1973
  f({ type: String, attribute: "stats-position" })
1966
- ], b.prototype, "statsPosition");
1974
+ ], m.prototype, "statsPosition");
1967
1975
  g([
1968
1976
  f({ type: String, attribute: "stats-align" })
1969
- ], b.prototype, "statsAlign");
1977
+ ], m.prototype, "statsAlign");
1970
1978
  g([
1971
1979
  f({ type: String, attribute: "button-text" })
1972
- ], b.prototype, "buttonText");
1980
+ ], m.prototype, "buttonText");
1973
1981
  g([
1974
1982
  f({ type: String, attribute: "button-radius" })
1975
- ], b.prototype, "buttonRadius");
1983
+ ], m.prototype, "buttonRadius");
1976
1984
  g([
1977
1985
  f({ type: String, attribute: "thank-you-msg" })
1978
- ], b.prototype, "thankYouMsg");
1986
+ ], m.prototype, "thankYouMsg");
1979
1987
  g([
1980
1988
  f({ type: Boolean, attribute: "multiple" })
1981
- ], b.prototype, "multiple");
1989
+ ], m.prototype, "multiple");
1982
1990
  g([
1983
1991
  f({ type: Boolean, attribute: "read-only" })
1984
- ], b.prototype, "readOnly");
1992
+ ], m.prototype, "readOnly");
1985
1993
  const zo = F`
1986
1994
  /* CSS variables inherit from parent - defaults are specified at usage sites */
1987
1995
 
@@ -2623,10 +2631,10 @@ function It(e, t = {}) {
2623
2631
  const n = `
2624
2632
  width: ${o > 0 ? i.value / o * s.maxWidth : 0}%;
2625
2633
  background-color: ${s.barColor};
2626
- `, l = s.labelFormatter(i), u = i.label ? d`<span class="pc-bar-label-text">${l}</span>` : h, c = !i.label && i.icon ? d`<span class="pc-bar-label-icon">${i.icon}</span>` : h;
2634
+ `, l = s.labelFormatter(i), p = i.label ? d`<span class="pc-bar-label-text">${l}</span>` : h, c = !i.label && i.icon ? d`<span class="pc-bar-label-icon">${i.icon}</span>` : h;
2627
2635
  return d`
2628
2636
  <div class="pc-bar-row">
2629
- <div class="pc-bar-label">${u} ${c}</div>
2637
+ <div class="pc-bar-label">${p} ${c}</div>
2630
2638
  <div class="pc-bar-container">
2631
2639
  <div class="pc-bar" style="${n}"></div>
2632
2640
  <div class="pc-bar-value">${s.valueFormatter(i)}</div>
@@ -2642,7 +2650,7 @@ var Io = Object.defineProperty, No = Object.getOwnPropertyDescriptor, Y = (e, t,
2642
2650
  (a = e[i]) && (s = (r ? a(t, o, s) : a(s)) || s);
2643
2651
  return r && s && Io(t, o, s), s;
2644
2652
  };
2645
- let I = class extends b {
2653
+ let I = class extends m {
2646
2654
  constructor() {
2647
2655
  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.handleNumberLeave = () => {
2648
2656
  this.hoverValue = -1;
@@ -2770,7 +2778,7 @@ let I = class extends b {
2770
2778
  `;
2771
2779
  }
2772
2780
  };
2773
- I.styles = [...b.styles, pt, zo];
2781
+ I.styles = [...m.styles, pt, zo];
2774
2782
  Y([
2775
2783
  f({ type: String, attribute: "min-label" })
2776
2784
  ], I.prototype, "minLabel", 2);
@@ -3051,7 +3059,7 @@ var Lo = Object.defineProperty, Ro = Object.getOwnPropertyDescriptor, Nt = (e, t
3051
3059
  (a = e[i]) && (s = (r ? a(t, o, s) : a(s)) || s);
3052
3060
  return r && s && Lo(t, o, s), s;
3053
3061
  };
3054
- let tt = class extends b {
3062
+ let tt = class extends m {
3055
3063
  constructor() {
3056
3064
  super(), this.type = $.poll, this.multiple = !1, this.compact = !1, this.hasEditButton = !0, this.statsText = "{count} votes", this.questionPosition = "top", this.statsPosition = "bottom", this.showStats = "after-vote";
3057
3065
  }
@@ -3109,12 +3117,12 @@ let tt = class extends b {
3109
3117
  */
3110
3118
  renderOptionIcon(e) {
3111
3119
  if (!(e != null && e.icon)) return "";
3112
- const t = zt.DECORATIVE, o = (e == null ? void 0 : e.label) || "", r = e ? this.dataController.isValueSelected(e.value) : !1, s = ye(e == null ? void 0 : e.icon, {
3120
+ const t = zt.DECORATIVE, o = (e == null ? void 0 : e.label) || "", r = e ? this.dataController.isValueSelected(e.value) : !1, s = we(e == null ? void 0 : e.icon, {
3113
3121
  type: t,
3114
3122
  alt: o,
3115
3123
  isSelected: r
3116
3124
  });
3117
- return ve(e == null ? void 0 : e.icon) ? d`<span
3125
+ return ye(e == null ? void 0 : e.icon) ? d`<span
3118
3126
  class="poll-option-icon"
3119
3127
  aria-hidden="${s.ariaHidden ? "true" : "false"}"
3120
3128
  >${e == null ? void 0 : e.icon}</span
@@ -3198,12 +3206,12 @@ let tt = class extends b {
3198
3206
  * Render chart that replaces poll options when showing
3199
3207
  */
3200
3208
  renderBarChart() {
3201
- var l, u;
3202
- const e = ((l = this.dataController.stats) == null ? void 0 : l.breakdown) || {}, t = ((u = this.dataController.localStats) == null ? void 0 : u.breakdown) || {}, o = Object.values(e).reduce((c, p) => c + p, 0), r = this.options.map((c, p) => {
3209
+ var l, p;
3210
+ const e = ((l = this.dataController.stats) == null ? void 0 : l.breakdown) || {}, t = ((p = this.dataController.localStats) == null ? void 0 : p.breakdown) || {}, o = Object.values(e).reduce((c, u) => c + u, 0), r = this.options.map((c, u) => {
3203
3211
  const w = e[c.value] || 0, v = o > 0 ? Math.round(w / o * 100) : 0, E = (t[c.value] || 0) > 0;
3204
3212
  return {
3205
3213
  option: c,
3206
- index: p,
3214
+ index: u,
3207
3215
  voteCount: w,
3208
3216
  percentage: v,
3209
3217
  isSelected: E
@@ -3222,7 +3230,7 @@ let tt = class extends b {
3222
3230
  ...=${a}
3223
3231
  >
3224
3232
  ${r.map((c) => {
3225
- const p = {
3233
+ const u = {
3226
3234
  "poll-option": !0,
3227
3235
  "poll-option--compact": this.compact,
3228
3236
  "poll-option--chart-view": !0,
@@ -3230,7 +3238,7 @@ let tt = class extends b {
3230
3238
  };
3231
3239
  return d`
3232
3240
  <div
3233
- class="${y(p)}"
3241
+ class="${y(u)}"
3234
3242
  data-testid="poll-chart-item-${c.index}"
3235
3243
  role="listitem"
3236
3244
  aria-label="${c.option.label}: ${c.percentage}% (${c.voteCount} votes)"
@@ -3314,7 +3322,7 @@ let tt = class extends b {
3314
3322
  `;
3315
3323
  }
3316
3324
  };
3317
- tt.styles = [...b.styles, pt, Mo];
3325
+ tt.styles = [...m.styles, pt, Mo];
3318
3326
  Nt([
3319
3327
  f({ type: Boolean })
3320
3328
  ], tt.prototype, "multiple", 2);
@@ -3406,10 +3414,10 @@ const Uo = F`
3406
3414
  * Copyright 2018 Google LLC
3407
3415
  * SPDX-License-Identifier: BSD-3-Clause
3408
3416
  */
3409
- const Se = "important", jo = " !" + Se, Bo = $e(class extends xe {
3417
+ const Ce = "important", jo = " !" + Ce, Bo = xe(class extends Se {
3410
3418
  constructor(e) {
3411
3419
  var t;
3412
- if (super(e), e.type !== we.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.");
3420
+ if (super(e), e.type !== $e.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.");
3413
3421
  }
3414
3422
  render(e) {
3415
3423
  return Object.keys(e).reduce((t, o) => {
@@ -3426,7 +3434,7 @@ const Se = "important", jo = " !" + Se, Bo = $e(class extends xe {
3426
3434
  if (s != null) {
3427
3435
  this.ft.add(r);
3428
3436
  const i = typeof s == "string" && s.endsWith(jo);
3429
- r.includes("-") || i ? o.setProperty(r, i ? s.slice(0, -11) : s, i ? Se : "") : o[r] = s;
3437
+ r.includes("-") || i ? o.setProperty(r, i ? s.slice(0, -11) : s, i ? Ce : "") : o[r] = s;
3430
3438
  }
3431
3439
  }
3432
3440
  return z;
@@ -3437,7 +3445,7 @@ var Do = Object.defineProperty, Vo = Object.getOwnPropertyDescriptor, ut = (e, t
3437
3445
  (a = e[i]) && (s = (r ? a(t, o, s) : a(s)) || s);
3438
3446
  return r && s && Do(t, o, s), s;
3439
3447
  };
3440
- let V = class extends b {
3448
+ let V = class extends m {
3441
3449
  constructor() {
3442
3450
  super(), this.type = $.stars, this.numStars = 5, this.hoverValue = -1, this.handleStarKeyDown = (e) => {
3443
3451
  if (e.key === "Enter" || e.key === " ") {
@@ -3463,18 +3471,18 @@ let V = class extends b {
3463
3471
  var i, a;
3464
3472
  if (this.displayController.shouldShowChart()) return h;
3465
3473
  const e = ((i = this.dataController.stats) == null ? void 0 : i.avg) || 0, t = ((a = this.dataController.localStats) == null ? void 0 : a.avg) || 0, o = this.readOnly ? e : t, r = this.displayController.allowEdit(), s = Array.from({ length: this.numStars }, (n, l) => l + 1).map((n) => {
3466
- const l = n <= Math.floor(o) || n <= (this.hoverValue || 0), u = !l && n === Math.ceil(o) && o % 1 !== 0, c = {
3474
+ const l = n <= Math.floor(o) || n <= (this.hoverValue || 0), p = !l && n === Math.ceil(o) && o % 1 !== 0, c = {
3467
3475
  star: !0,
3468
3476
  selected: l,
3469
- partial: u,
3477
+ partial: p,
3470
3478
  "view-mode": !r
3471
- }, p = u ? { "--partial-fill": `${o % 1 * 100}%` } : {};
3479
+ }, u = p ? { "--partial-fill": `${o % 1 * 100}%` } : {};
3472
3480
  return d`
3473
3481
  <div class="pc-section" data-testid="pc-section">
3474
3482
  <span
3475
3483
  data-testid="stars-view-star-${n}"
3476
3484
  class=${y(c)}
3477
- style=${Bo(p)}
3485
+ style=${Bo(u)}
3478
3486
  role="${r ? "button" : "presentation"}"
3479
3487
  tabindex="${r ? "0" : ""}"
3480
3488
  aria-label="${r ? `Rate ${n} star${n > 1 ? "s" : ""}` : ""}"
@@ -3534,7 +3542,7 @@ let V = class extends b {
3534
3542
  `;
3535
3543
  }
3536
3544
  };
3537
- V.styles = [...b.styles, pt, Uo];
3545
+ V.styles = [...m.styles, pt, Uo];
3538
3546
  ut([
3539
3547
  f({ type: String })
3540
3548
  ], V.prototype, "icon", 2);
@@ -3741,7 +3749,7 @@ const qo = F`
3741
3749
  .reaction.expand .reaction-list {
3742
3750
  order: 1;
3743
3751
  }
3744
- `, se = {
3752
+ `, ie = {
3745
3753
  // Faces
3746
3754
  smile: "😊",
3747
3755
  laugh: "😄",
@@ -3884,9 +3892,9 @@ const qo = F`
3884
3892
  hiking: "🥾",
3885
3893
  yoga: "🧘"
3886
3894
  };
3887
- function Ce(e) {
3895
+ function ke(e) {
3888
3896
  let t = "❓", o = !1;
3889
- return e ? e in se ? t = se[e] : ve(e) ? t = e : dt(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 = "❓", {
3897
+ return e ? e in ie ? t = ie[e] : ye(e) ? t = e : dt(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 = "❓", {
3890
3898
  icon: t,
3891
3899
  isRemoteImage: o
3892
3900
  };
@@ -3897,7 +3905,7 @@ var Fo = Object.defineProperty, Yo = Object.getOwnPropertyDescriptor, ht = (e, t
3897
3905
  (a = e[i]) && (s = (r ? a(t, o, s) : a(s)) || s);
3898
3906
  return r && s && Fo(t, o, s), s;
3899
3907
  };
3900
- let q = class extends b {
3908
+ let q = class extends m {
3901
3909
  constructor() {
3902
3910
  super(), this.type = $.reaction, this.showCounts = !1, this.compact = !1, this.popupPosition = "auto", this.hasEditButton = !1, this.statsText = "{count} votes", this.buttonRadius = "990px", this.muteColor = "#cccccc", this.questionPosition = "top", this.statsPosition = "right", this.popupPosition = "auto";
3903
3911
  }
@@ -3921,7 +3929,7 @@ let q = class extends b {
3921
3929
  * Renders the icon for a reaction
3922
3930
  */
3923
3931
  renderReactionIcon(e, t) {
3924
- const { icon: o, isRemoteImage: r } = Ce(e), s = zt.FUNCTIONAL, i = t.tooltip || `${t.value} reaction`, a = ye(o, {
3932
+ const { icon: o, isRemoteImage: r } = ke(e), s = zt.FUNCTIONAL, i = t.tooltip || `${t.value} reaction`, a = we(o, {
3925
3933
  type: s,
3926
3934
  alt: i,
3927
3935
  ariaLabel: i,
@@ -4064,13 +4072,13 @@ let q = class extends b {
4064
4072
  renderChart() {
4065
4073
  if (!this.displayController.shouldShowChart()) return h;
4066
4074
  const e = this.dataController.getBreakdownInfo(), o = Object.entries(e.breakdownCount).filter(
4067
- ([l, u]) => this.options.some((c) => c.value === l)
4068
- ).map(([l, u]) => {
4069
- const c = this.options.find((p) => p.value === l);
4075
+ ([l, p]) => this.options.some((c) => c.value === l)
4076
+ ).map(([l, p]) => {
4077
+ const c = this.options.find((u) => u.value === l);
4070
4078
  return {
4071
4079
  label: l,
4072
4080
  // Use the reaction value as label
4073
- value: u,
4081
+ value: p,
4074
4082
  icon: (c == null ? void 0 : c.icon) || l
4075
4083
  // Use the icon or fall back to reaction value
4076
4084
  };
@@ -4106,7 +4114,7 @@ let q = class extends b {
4106
4114
  `;
4107
4115
  }
4108
4116
  };
4109
- q.styles = [...b.styles, pt, qo];
4117
+ q.styles = [...m.styles, pt, qo];
4110
4118
  ht([
4111
4119
  f({ type: Boolean, attribute: "show-counts" })
4112
4120
  ], q.prototype, "showCounts", 2);
@@ -4200,12 +4208,12 @@ let H = class extends j {
4200
4208
  // REACTION widget uses options for the icon
4201
4209
  }));
4202
4210
  t && t.length > 0 && (r = Array.from(t).map((s) => {
4203
- const i = G(s, "value", "") || "", a = G(s, "label", Zo(s, i)) || "", n = G(s, "icon", void 0), l = G(s, "tooltip", void 0), u = G(s, "disabled", void 0), c = { value: i, label: a };
4211
+ const i = G(s, "value", "") || "", a = G(s, "label", Zo(s, i)) || "", n = G(s, "icon", void 0), l = G(s, "tooltip", void 0), p = G(s, "disabled", void 0), c = { value: i, label: a };
4204
4212
  if (n !== void 0) {
4205
- const p = Ce(n);
4206
- c.icon = p.icon;
4213
+ const u = ke(n);
4214
+ c.icon = u.icon;
4207
4215
  }
4208
- return l !== void 0 && (c.tooltip = l), u !== void 0 && (c.disabled = !0), c;
4216
+ return l !== void 0 && (c.tooltip = l), p !== void 0 && (c.disabled = !0), c;
4209
4217
  })), this.parsedOptions = r;
4210
4218
  }
4211
4219
  /**