@florid-kit/components 0.9.6 → 0.9.8
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.
- package/components/toast.d.ts +1 -0
- package/index.js +57 -48
- package/index.mjs +193 -177
- package/package.json +1 -1
package/index.mjs
CHANGED
|
@@ -45,10 +45,10 @@ const ye = (o) => new he(typeof o == "string" ? o : o + "", void 0, Tt), f = (o,
|
|
|
45
45
|
* Copyright 2017 Google LLC
|
|
46
46
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
47
47
|
*/
|
|
48
|
-
const { is: xe, defineProperty: we, getOwnPropertyDescriptor: $e, getOwnPropertyNames: Ce, getOwnPropertySymbols: _e, getPrototypeOf: ke } = Object, W = globalThis, te = W.trustedTypes,
|
|
48
|
+
const { is: xe, defineProperty: we, getOwnPropertyDescriptor: $e, getOwnPropertyNames: Ce, getOwnPropertySymbols: _e, getPrototypeOf: ke } = Object, W = globalThis, te = W.trustedTypes, Se = te ? te.emptyScript : "", Lt = W.reactiveElementPolyfillSupport, lt = (o, t) => o, Ct = { toAttribute(o, t) {
|
|
49
49
|
switch (t) {
|
|
50
50
|
case Boolean:
|
|
51
|
-
o = o ?
|
|
51
|
+
o = o ? Se : null;
|
|
52
52
|
break;
|
|
53
53
|
case Object:
|
|
54
54
|
case Array:
|
|
@@ -95,8 +95,8 @@ let it = class extends HTMLElement {
|
|
|
95
95
|
this[e] = s;
|
|
96
96
|
} };
|
|
97
97
|
return { get: i, set(s) {
|
|
98
|
-
const
|
|
99
|
-
n == null || n.call(this, s), this.requestUpdate(t,
|
|
98
|
+
const c = i == null ? void 0 : i.call(this);
|
|
99
|
+
n == null || n.call(this, s), this.requestUpdate(t, c, r);
|
|
100
100
|
}, configurable: !0, enumerable: !0 };
|
|
101
101
|
}
|
|
102
102
|
static getPropertyOptions(t) {
|
|
@@ -192,8 +192,8 @@ let it = class extends HTMLElement {
|
|
|
192
192
|
var n, s;
|
|
193
193
|
const r = this.constructor, i = r._$Eh.get(t);
|
|
194
194
|
if (i !== void 0 && this._$Em !== i) {
|
|
195
|
-
const
|
|
196
|
-
this._$Em = i, this[i] =
|
|
195
|
+
const c = r.getPropertyOptions(i), h = typeof c.converter == "function" ? { fromAttribute: c.converter } : ((n = c.converter) == null ? void 0 : n.fromAttribute) !== void 0 ? c.converter : Ct;
|
|
196
|
+
this._$Em = i, this[i] = h.fromAttribute(e, c.type) ?? ((s = this._$Ej) == null ? void 0 : s.get(i)) ?? null, this._$Em = null;
|
|
197
197
|
}
|
|
198
198
|
}
|
|
199
199
|
requestUpdate(t, e, r) {
|
|
@@ -231,8 +231,8 @@ let it = class extends HTMLElement {
|
|
|
231
231
|
}
|
|
232
232
|
const i = this.constructor.elementProperties;
|
|
233
233
|
if (i.size > 0) for (const [n, s] of i) {
|
|
234
|
-
const { wrapped:
|
|
235
|
-
|
|
234
|
+
const { wrapped: c } = s, h = this[n];
|
|
235
|
+
c !== !0 || this._$AL.has(n) || h === void 0 || this.C(n, void 0, s, h);
|
|
236
236
|
}
|
|
237
237
|
}
|
|
238
238
|
let t = !1;
|
|
@@ -282,7 +282,7 @@ it.elementStyles = [], it.shadowRootOptions = { mode: "open" }, it[lt("elementPr
|
|
|
282
282
|
* Copyright 2017 Google LLC
|
|
283
283
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
284
284
|
*/
|
|
285
|
-
const ct = globalThis, _t = ct.trustedTypes, oe = _t ? _t.createPolicy("lit-html", { createHTML: (o) => o }) : void 0, de = "$lit$", K = `lit$${Math.random().toFixed(9).slice(2)}$`, pe = "?" + K,
|
|
285
|
+
const ct = globalThis, _t = ct.trustedTypes, oe = _t ? _t.createPolicy("lit-html", { createHTML: (o) => o }) : void 0, de = "$lit$", K = `lit$${Math.random().toFixed(9).slice(2)}$`, pe = "?" + K, Ee = `<${pe}>`, tt = document, dt = () => tt.createComment(""), pt = (o) => o === null || typeof o != "object" && typeof o != "function", Rt = Array.isArray, Ae = (o) => Rt(o) || typeof (o == null ? void 0 : o[Symbol.iterator]) == "function", It = `[
|
|
286
286
|
\f\r]`, at = /<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g, ie = /-->/g, re = />/g, J = RegExp(`>|${It}(?:([^\\s"'>=/]+)(${It}*=${It}*(?:[^
|
|
287
287
|
\f\r"'\`<>=]|("|')|))|$)`, "g"), ne = /'/g, se = /"/g, ue = /^(?:script|style|textarea|title)$/i, Le = (o) => (t, ...e) => ({ _$litType$: o, strings: t, values: e }), l = Le(1), G = Symbol.for("lit-noChange"), d = Symbol.for("lit-nothing"), ae = /* @__PURE__ */ new WeakMap(), Q = tt.createTreeWalker(tt, 129);
|
|
288
288
|
function ve(o, t) {
|
|
@@ -292,12 +292,12 @@ function ve(o, t) {
|
|
|
292
292
|
const Ie = (o, t) => {
|
|
293
293
|
const e = o.length - 1, r = [];
|
|
294
294
|
let i, n = t === 2 ? "<svg>" : t === 3 ? "<math>" : "", s = at;
|
|
295
|
-
for (let
|
|
296
|
-
const
|
|
295
|
+
for (let c = 0; c < e; c++) {
|
|
296
|
+
const h = o[c];
|
|
297
297
|
let b, x, p = -1, k = 0;
|
|
298
|
-
for (; k <
|
|
299
|
-
const
|
|
300
|
-
n += s === at ?
|
|
298
|
+
for (; k < h.length && (s.lastIndex = k, x = s.exec(h), x !== null); ) k = s.lastIndex, s === at ? x[1] === "!--" ? s = ie : x[1] !== void 0 ? s = re : x[2] !== void 0 ? (ue.test(x[2]) && (i = RegExp("</" + x[2], "g")), s = J) : x[3] !== void 0 && (s = J) : s === J ? x[0] === ">" ? (s = i ?? at, p = -1) : x[1] === void 0 ? p = -2 : (p = s.lastIndex - x[2].length, b = x[1], s = x[3] === void 0 ? J : x[3] === '"' ? se : ne) : s === se || s === ne ? s = J : s === ie || s === re ? s = at : (s = J, i = void 0);
|
|
299
|
+
const B = s === J && o[c + 1].startsWith("/>") ? " " : "";
|
|
300
|
+
n += s === at ? h + Ee : p >= 0 ? (r.push(b), h.slice(0, p) + de + h.slice(p) + K + B) : h + K + (p === -2 ? c : B);
|
|
301
301
|
}
|
|
302
302
|
return [ve(o, n + (o[e] || "<?>") + (t === 2 ? "</svg>" : t === 3 ? "</math>" : "")), r];
|
|
303
303
|
};
|
|
@@ -306,29 +306,29 @@ class ut {
|
|
|
306
306
|
let i;
|
|
307
307
|
this.parts = [];
|
|
308
308
|
let n = 0, s = 0;
|
|
309
|
-
const
|
|
309
|
+
const c = t.length - 1, h = this.parts, [b, x] = Ie(t, e);
|
|
310
310
|
if (this.el = ut.createElement(b, r), Q.currentNode = this.el.content, e === 2 || e === 3) {
|
|
311
311
|
const p = this.el.content.firstChild;
|
|
312
312
|
p.replaceWith(...p.childNodes);
|
|
313
313
|
}
|
|
314
|
-
for (; (i = Q.nextNode()) !== null &&
|
|
314
|
+
for (; (i = Q.nextNode()) !== null && h.length < c; ) {
|
|
315
315
|
if (i.nodeType === 1) {
|
|
316
316
|
if (i.hasAttributes()) for (const p of i.getAttributeNames()) if (p.endsWith(de)) {
|
|
317
|
-
const k = x[s++],
|
|
318
|
-
|
|
319
|
-
} else p.startsWith(K) && (
|
|
317
|
+
const k = x[s++], B = i.getAttribute(p).split(K), wt = /([.?@])?(.*)/.exec(k);
|
|
318
|
+
h.push({ type: 1, index: n, name: wt[2], strings: B, ctor: wt[1] === "." ? Oe : wt[1] === "?" ? ze : wt[1] === "@" ? Be : St }), i.removeAttribute(p);
|
|
319
|
+
} else p.startsWith(K) && (h.push({ type: 6, index: n }), i.removeAttribute(p));
|
|
320
320
|
if (ue.test(i.tagName)) {
|
|
321
321
|
const p = i.textContent.split(K), k = p.length - 1;
|
|
322
322
|
if (k > 0) {
|
|
323
323
|
i.textContent = _t ? _t.emptyScript : "";
|
|
324
|
-
for (let
|
|
324
|
+
for (let B = 0; B < k; B++) i.append(p[B], dt()), Q.nextNode(), h.push({ type: 2, index: ++n });
|
|
325
325
|
i.append(p[k], dt());
|
|
326
326
|
}
|
|
327
327
|
}
|
|
328
|
-
} else if (i.nodeType === 8) if (i.data === pe)
|
|
328
|
+
} else if (i.nodeType === 8) if (i.data === pe) h.push({ type: 2, index: n });
|
|
329
329
|
else {
|
|
330
330
|
let p = -1;
|
|
331
|
-
for (; (p = i.data.indexOf(K, p + 1)) !== -1; )
|
|
331
|
+
for (; (p = i.data.indexOf(K, p + 1)) !== -1; ) h.push({ type: 7, index: n }), p += K.length - 1;
|
|
332
332
|
}
|
|
333
333
|
n++;
|
|
334
334
|
}
|
|
@@ -339,11 +339,11 @@ class ut {
|
|
|
339
339
|
}
|
|
340
340
|
}
|
|
341
341
|
function rt(o, t, e = o, r) {
|
|
342
|
-
var s,
|
|
342
|
+
var s, c;
|
|
343
343
|
if (t === G) return t;
|
|
344
344
|
let i = r !== void 0 ? (s = e._$Co) == null ? void 0 : s[r] : e._$Cl;
|
|
345
345
|
const n = pt(t) ? void 0 : t._$litDirective$;
|
|
346
|
-
return (i == null ? void 0 : i.constructor) !== n && ((
|
|
346
|
+
return (i == null ? void 0 : i.constructor) !== n && ((c = i == null ? void 0 : i._$AO) == null || c.call(i, !1), n === void 0 ? i = void 0 : (i = new n(o), i._$AT(o, e, r)), r !== void 0 ? (e._$Co ?? (e._$Co = []))[r] = i : e._$Cl = i), i !== void 0 && (t = rt(o, i._$AS(o, t.values), i, r)), t;
|
|
347
347
|
}
|
|
348
348
|
class Pe {
|
|
349
349
|
constructor(t, e) {
|
|
@@ -358,13 +358,13 @@ class Pe {
|
|
|
358
358
|
u(t) {
|
|
359
359
|
const { el: { content: e }, parts: r } = this._$AD, i = ((t == null ? void 0 : t.creationScope) ?? tt).importNode(e, !0);
|
|
360
360
|
Q.currentNode = i;
|
|
361
|
-
let n = Q.nextNode(), s = 0,
|
|
362
|
-
for (;
|
|
363
|
-
if (s ===
|
|
361
|
+
let n = Q.nextNode(), s = 0, c = 0, h = r[0];
|
|
362
|
+
for (; h !== void 0; ) {
|
|
363
|
+
if (s === h.index) {
|
|
364
364
|
let b;
|
|
365
|
-
|
|
365
|
+
h.type === 2 ? b = new mt(n, n.nextSibling, this, t) : h.type === 1 ? b = new h.ctor(n, h.name, h.strings, this, t) : h.type === 6 && (b = new De(n, this, t)), this._$AV.push(b), h = r[++c];
|
|
366
366
|
}
|
|
367
|
-
s !== (
|
|
367
|
+
s !== (h == null ? void 0 : h.index) && (n = Q.nextNode(), s++);
|
|
368
368
|
}
|
|
369
369
|
return Q.currentNode = tt, i;
|
|
370
370
|
}
|
|
@@ -409,8 +409,8 @@ class mt {
|
|
|
409
409
|
const { values: e, _$litType$: r } = t, i = typeof r == "number" ? this._$AC(t) : (r.el === void 0 && (r.el = ut.createElement(ve(r.h, r.h[0]), this.options)), r);
|
|
410
410
|
if (((n = this._$AH) == null ? void 0 : n._$AD) === i) this._$AH.p(e);
|
|
411
411
|
else {
|
|
412
|
-
const s = new Pe(i, this),
|
|
413
|
-
s.p(e), this.T(
|
|
412
|
+
const s = new Pe(i, this), c = s.u(this.options);
|
|
413
|
+
s.p(e), this.T(c), this._$AH = s;
|
|
414
414
|
}
|
|
415
415
|
}
|
|
416
416
|
_$AC(t) {
|
|
@@ -436,7 +436,7 @@ class mt {
|
|
|
436
436
|
this._$AM === void 0 && (this._$Cv = t, (e = this._$AP) == null || e.call(this, t));
|
|
437
437
|
}
|
|
438
438
|
}
|
|
439
|
-
class
|
|
439
|
+
class St {
|
|
440
440
|
get tagName() {
|
|
441
441
|
return this.element.tagName;
|
|
442
442
|
}
|
|
@@ -451,9 +451,9 @@ class Et {
|
|
|
451
451
|
let s = !1;
|
|
452
452
|
if (n === void 0) t = rt(this, t, e, 0), s = !pt(t) || t !== this._$AH && t !== G, s && (this._$AH = t);
|
|
453
453
|
else {
|
|
454
|
-
const
|
|
455
|
-
let
|
|
456
|
-
for (t = n[0],
|
|
454
|
+
const c = t;
|
|
455
|
+
let h, b;
|
|
456
|
+
for (t = n[0], h = 0; h < n.length - 1; h++) b = rt(this, c[r + h], e, h), b === G && (b = this._$AH[h]), s || (s = !pt(b) || b !== this._$AH[h]), b === d ? t = d : t !== d && (t += (b ?? "") + n[h + 1]), this._$AH[h] = b;
|
|
457
457
|
}
|
|
458
458
|
s && !i && this.j(t);
|
|
459
459
|
}
|
|
@@ -461,7 +461,7 @@ class Et {
|
|
|
461
461
|
t === d ? this.element.removeAttribute(this.name) : this.element.setAttribute(this.name, t ?? "");
|
|
462
462
|
}
|
|
463
463
|
}
|
|
464
|
-
class Oe extends
|
|
464
|
+
class Oe extends St {
|
|
465
465
|
constructor() {
|
|
466
466
|
super(...arguments), this.type = 3;
|
|
467
467
|
}
|
|
@@ -469,7 +469,7 @@ class Oe extends Et {
|
|
|
469
469
|
this.element[this.name] = t === d ? void 0 : t;
|
|
470
470
|
}
|
|
471
471
|
}
|
|
472
|
-
class ze extends
|
|
472
|
+
class ze extends St {
|
|
473
473
|
constructor() {
|
|
474
474
|
super(...arguments), this.type = 4;
|
|
475
475
|
}
|
|
@@ -477,7 +477,7 @@ class ze extends Et {
|
|
|
477
477
|
this.element.toggleAttribute(this.name, !!t && t !== d);
|
|
478
478
|
}
|
|
479
479
|
}
|
|
480
|
-
class Be extends
|
|
480
|
+
class Be extends St {
|
|
481
481
|
constructor(t, e, r, i, n) {
|
|
482
482
|
super(t, e, r, i, n), this.type = 5;
|
|
483
483
|
}
|
|
@@ -569,18 +569,18 @@ const Me = { attribute: !0, type: String, converter: Ct, reflect: !1, hasChanged
|
|
|
569
569
|
let n = globalThis.litPropertyMetadata.get(i);
|
|
570
570
|
if (n === void 0 && globalThis.litPropertyMetadata.set(i, n = /* @__PURE__ */ new Map()), r === "setter" && ((o = Object.create(o)).wrapped = !0), n.set(e.name, o), r === "accessor") {
|
|
571
571
|
const { name: s } = e;
|
|
572
|
-
return { set(
|
|
573
|
-
const
|
|
574
|
-
t.set.call(this,
|
|
575
|
-
}, init(
|
|
576
|
-
return
|
|
572
|
+
return { set(c) {
|
|
573
|
+
const h = t.get.call(this);
|
|
574
|
+
t.set.call(this, c), this.requestUpdate(s, h, o);
|
|
575
|
+
}, init(c) {
|
|
576
|
+
return c !== void 0 && this.C(s, void 0, o, c), c;
|
|
577
577
|
} };
|
|
578
578
|
}
|
|
579
579
|
if (r === "setter") {
|
|
580
580
|
const { name: s } = e;
|
|
581
|
-
return function(
|
|
582
|
-
const
|
|
583
|
-
t.call(this,
|
|
581
|
+
return function(c) {
|
|
582
|
+
const h = this[s];
|
|
583
|
+
t.call(this, c), this.requestUpdate(s, h, o);
|
|
584
584
|
};
|
|
585
585
|
}
|
|
586
586
|
throw Error("Unsupported decorator location: " + r);
|
|
@@ -613,8 +613,8 @@ const je = (o, t, e) => (e.configurable = !0, e.enumerable = !0, Reflect.decorat
|
|
|
613
613
|
function fe(o, t) {
|
|
614
614
|
return (e, r, i) => {
|
|
615
615
|
const n = (s) => {
|
|
616
|
-
var
|
|
617
|
-
return ((
|
|
616
|
+
var c;
|
|
617
|
+
return ((c = s.renderRoot) == null ? void 0 : c.querySelector(o)) ?? null;
|
|
618
618
|
};
|
|
619
619
|
return je(e, r, { get() {
|
|
620
620
|
return n(this);
|
|
@@ -635,11 +635,11 @@ f`
|
|
|
635
635
|
* Copyright 2023 Google LLC
|
|
636
636
|
* SPDX-License-Identifier: Apache-2.0
|
|
637
637
|
*/
|
|
638
|
-
const
|
|
639
|
-
function
|
|
638
|
+
const Nt = Symbol("internals"), zt = Symbol("privateInternals");
|
|
639
|
+
function Ft(o) {
|
|
640
640
|
var t;
|
|
641
641
|
class e extends o {
|
|
642
|
-
get [(t =
|
|
642
|
+
get [(t = Nt, t)]() {
|
|
643
643
|
return this[zt] || (this[zt] = this.attachInternals()), this[zt];
|
|
644
644
|
}
|
|
645
645
|
}
|
|
@@ -654,9 +654,9 @@ function Re(o) {
|
|
|
654
654
|
o.addInitializer((t) => {
|
|
655
655
|
const e = t;
|
|
656
656
|
e.addEventListener("click", async (r) => {
|
|
657
|
-
const { type: i, [
|
|
658
|
-
if (!(!s || i === "button") && (await new Promise((
|
|
659
|
-
setTimeout(
|
|
657
|
+
const { type: i, [Nt]: n } = e, { form: s } = n;
|
|
658
|
+
if (!(!s || i === "button") && (await new Promise((c) => {
|
|
659
|
+
setTimeout(c);
|
|
660
660
|
}), !r.defaultPrevented)) {
|
|
661
661
|
if (i === "reset") {
|
|
662
662
|
s.reset();
|
|
@@ -664,8 +664,8 @@ function Re(o) {
|
|
|
664
664
|
}
|
|
665
665
|
s.addEventListener(
|
|
666
666
|
"submit",
|
|
667
|
-
(
|
|
668
|
-
Object.defineProperty(
|
|
667
|
+
(c) => {
|
|
668
|
+
Object.defineProperty(c, "submitter", {
|
|
669
669
|
configurable: !0,
|
|
670
670
|
enumerable: !0,
|
|
671
671
|
get: () => e
|
|
@@ -677,10 +677,10 @@ function Re(o) {
|
|
|
677
677
|
});
|
|
678
678
|
});
|
|
679
679
|
}
|
|
680
|
-
const
|
|
680
|
+
const Ne = `<svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
681
681
|
<path d="M8 3.6275C7.06799 0.971489 3.25399 -0.0226278 1.67414 2.30983C0.0877404 4.65197 1.67414 6.99412 2.62598 8.33249C3.0147 8.87905 8 14 8 14C8 14 12.9853 8.87905 13.374 8.33249C14.3259 6.99412 15.9123 4.65197 14.3259 2.30983C12.746 -0.0226277 8.97167 0.971489 8 3.6275Z" stroke="#3F2B2E" stroke-linecap="round"/>
|
|
682
682
|
</svg>
|
|
683
|
-
`,
|
|
683
|
+
`, Fe = `<svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
684
684
|
<path d="M16 8L4 0V16L16 8Z" fill="#3F2B2E"/>
|
|
685
685
|
</svg>
|
|
686
686
|
`, Ue = `<svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
@@ -772,9 +772,9 @@ const Fe = `<svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="h
|
|
|
772
772
|
</svg>
|
|
773
773
|
`, bo = `<svg xmlns="http://www.w3.org/2000/svg" width="10" height="8" viewBox="0 0 10 8" fill="none">
|
|
774
774
|
<path d="M1 4.5415L3 6.5415L9 0.541504" stroke="#FBF9F6" stroke-linecap="round" stroke-linejoin="round"/>
|
|
775
|
-
</svg>`,
|
|
776
|
-
wishlist:
|
|
777
|
-
playerv:
|
|
775
|
+
</svg>`, F = {
|
|
776
|
+
wishlist: Ne,
|
|
777
|
+
playerv: Fe,
|
|
778
778
|
chevronRight: Ue,
|
|
779
779
|
chevronLeft: Ve,
|
|
780
780
|
icoPlus: Qe,
|
|
@@ -855,13 +855,13 @@ Bt.directiveName = "unsafeHTML", Bt.resultType = 1;
|
|
|
855
855
|
class Dt extends Bt {
|
|
856
856
|
}
|
|
857
857
|
Dt.directiveName = "unsafeSVG", Dt.resultType = 2;
|
|
858
|
-
const
|
|
858
|
+
const C = Vt(Dt);
|
|
859
859
|
var mo = Object.defineProperty, xo = Object.getOwnPropertyDescriptor, w = (o, t, e, r) => {
|
|
860
860
|
for (var i = r > 1 ? void 0 : r ? xo(t, e) : t, n = o.length - 1, s; n >= 0; n--)
|
|
861
861
|
(s = o[n]) && (i = (r ? s(t, e, i) : s(i)) || i);
|
|
862
862
|
return r && i && mo(t, e, i), i;
|
|
863
863
|
};
|
|
864
|
-
const wo =
|
|
864
|
+
const wo = Ft(v);
|
|
865
865
|
let g = class extends wo {
|
|
866
866
|
constructor() {
|
|
867
867
|
super(...arguments), this.type = "submit", this.value = "", this.variant = "primary", this.text = "", this.textsecond = "", this.fullwidth = !1, this.disabled = !1, this.startIconModel = "", this.endIconModel = "", this.startIcon = !1, this.endIcon = !1, this.panelTarget = "", this.href = "", this.target = "", this.underlined = !1, this.withbadge = !1;
|
|
@@ -873,7 +873,7 @@ let g = class extends wo {
|
|
|
873
873
|
this.setAttribute("name", o);
|
|
874
874
|
}
|
|
875
875
|
get form() {
|
|
876
|
-
return this[
|
|
876
|
+
return this[Nt].form;
|
|
877
877
|
}
|
|
878
878
|
handleClick(o) {
|
|
879
879
|
if (!(o instanceof KeyboardEvent && !["Enter", " "].includes(o.key)) && this.panelTarget) {
|
|
@@ -887,11 +887,11 @@ let g = class extends wo {
|
|
|
887
887
|
renderIcon(o) {
|
|
888
888
|
const t = o === "start" ? this.startIconModel : this.endIconModel;
|
|
889
889
|
if (!t) return d;
|
|
890
|
-
const e =
|
|
890
|
+
const e = F[t].replace(
|
|
891
891
|
"<svg",
|
|
892
892
|
'<svg aria-hidden="true" focusable="false" part="svg"'
|
|
893
893
|
);
|
|
894
|
-
return l`<span class="${o === "start" ? "icon-start" : "icon-end"}">${
|
|
894
|
+
return l`<span class="${o === "start" ? "icon-start" : "icon-end"}">${C(e)}</span>`;
|
|
895
895
|
}
|
|
896
896
|
renderButton() {
|
|
897
897
|
const o = this.text || this.textsecond;
|
|
@@ -1181,7 +1181,7 @@ w([
|
|
|
1181
1181
|
g = w([
|
|
1182
1182
|
m("o-button")
|
|
1183
1183
|
], g);
|
|
1184
|
-
var $o = Object.defineProperty, Co = Object.getOwnPropertyDescriptor,
|
|
1184
|
+
var $o = Object.defineProperty, Co = Object.getOwnPropertyDescriptor, Et = (o, t, e, r) => {
|
|
1185
1185
|
for (var i = r > 1 ? void 0 : r ? Co(t, e) : t, n = o.length - 1, s; n >= 0; n--)
|
|
1186
1186
|
(s = o[n]) && (i = (r ? s(t, e, i) : s(i)) || i);
|
|
1187
1187
|
return r && i && $o(t, e, i), i;
|
|
@@ -1206,14 +1206,14 @@ let nt = class extends v {
|
|
|
1206
1206
|
(o.key === "Enter" || o.key === " ") && (o.preventDefault(), this.toggleStatus());
|
|
1207
1207
|
}
|
|
1208
1208
|
render() {
|
|
1209
|
-
const o =
|
|
1209
|
+
const o = F.wishlist.replace(
|
|
1210
1210
|
"<svg",
|
|
1211
1211
|
'<svg aria-hidden="true" focusable="false" part="svg"'
|
|
1212
1212
|
);
|
|
1213
1213
|
return l`
|
|
1214
1214
|
<button type="button" aria-describedby="${this.ariaDescribedBy}" class="wishlist-button">
|
|
1215
1215
|
<span class="sr-only">${this.label}</span>
|
|
1216
|
-
${
|
|
1216
|
+
${C(o)}
|
|
1217
1217
|
</button>
|
|
1218
1218
|
`;
|
|
1219
1219
|
}
|
|
@@ -1293,16 +1293,16 @@ nt.styles = f`
|
|
|
1293
1293
|
white-space: nowrap !important;
|
|
1294
1294
|
}
|
|
1295
1295
|
`;
|
|
1296
|
-
|
|
1296
|
+
Et([
|
|
1297
1297
|
a({ type: String, reflect: !0 })
|
|
1298
1298
|
], nt.prototype, "status", 2);
|
|
1299
|
-
|
|
1299
|
+
Et([
|
|
1300
1300
|
a({ type: String, reflect: !0 })
|
|
1301
1301
|
], nt.prototype, "ariaDescribedBy", 2);
|
|
1302
|
-
|
|
1302
|
+
Et([
|
|
1303
1303
|
a({ type: String, reflect: !0 })
|
|
1304
1304
|
], nt.prototype, "label", 2);
|
|
1305
|
-
nt =
|
|
1305
|
+
nt = Et([
|
|
1306
1306
|
m("o-wishlist-button")
|
|
1307
1307
|
], nt);
|
|
1308
1308
|
/**
|
|
@@ -1310,13 +1310,13 @@ nt = St([
|
|
|
1310
1310
|
* Copyright 2018 Google LLC
|
|
1311
1311
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
1312
1312
|
*/
|
|
1313
|
-
const
|
|
1313
|
+
const S = (o) => o ?? d;
|
|
1314
1314
|
var _o = Object.defineProperty, ko = Object.getOwnPropertyDescriptor, T = (o, t, e, r) => {
|
|
1315
1315
|
for (var i = r > 1 ? void 0 : r ? ko(t, e) : t, n = o.length - 1, s; n >= 0; n--)
|
|
1316
1316
|
(s = o[n]) && (i = (r ? s(t, e, i) : s(i)) || i);
|
|
1317
1317
|
return r && i && _o(t, e, i), i;
|
|
1318
1318
|
};
|
|
1319
|
-
let
|
|
1319
|
+
let E = class extends v {
|
|
1320
1320
|
constructor() {
|
|
1321
1321
|
super(...arguments), this.bgstyle = "background-light", this.size = "medium", this.status = "empty", this.type = "button", this.strokewidth = "1", this.icon = "wishlist", this.disabled = !1, this.showSrLabel = !1, this.srLabel = "";
|
|
1322
1322
|
}
|
|
@@ -1324,27 +1324,27 @@ let S = class extends v {
|
|
|
1324
1324
|
super.updated(o), this.style.setProperty("--icon-stroke-width", this.strokewidth);
|
|
1325
1325
|
}
|
|
1326
1326
|
render() {
|
|
1327
|
-
const o =
|
|
1327
|
+
const o = F[this.icon] ?? "", t = `icon-${this.icon}`, e = o.replace("<svg", '<svg aria-hidden="true" focusable="false" part="svg"').replace(/<path\b/g, '<path part="icon-path"').replace(/<g\b/g, '<g part="icon-group"').replace(/<circle\b/g, '<circle part="icon-circle"'), r = this.showSrLabel ? l`<span class="sr-only">${this.srLabel}</span>` : null, i = this.showSrLabel ? null : "icon";
|
|
1328
1328
|
return l`
|
|
1329
1329
|
${this.type === "span" ? l`
|
|
1330
1330
|
<span class="icon icon-button ${this.size} ${this.bgstyle} ${this.status} ${t}" ?disabled="${this.disabled}">
|
|
1331
|
-
${
|
|
1331
|
+
${C(e)}
|
|
1332
1332
|
</span>
|
|
1333
1333
|
` : l`
|
|
1334
1334
|
<button
|
|
1335
1335
|
type="button"
|
|
1336
|
-
aria-label=${
|
|
1336
|
+
aria-label=${S(i)}
|
|
1337
1337
|
class="icon-button ${this.size} ${this.bgstyle} ${this.status} ${t}"
|
|
1338
1338
|
?disabled="${this.disabled}"
|
|
1339
1339
|
>
|
|
1340
|
-
${
|
|
1340
|
+
${C(e)}
|
|
1341
1341
|
${r}
|
|
1342
1342
|
</button>
|
|
1343
1343
|
`}
|
|
1344
1344
|
`;
|
|
1345
1345
|
}
|
|
1346
1346
|
};
|
|
1347
|
-
|
|
1347
|
+
E.styles = f`
|
|
1348
1348
|
:host {
|
|
1349
1349
|
display: inline-flex;
|
|
1350
1350
|
justify-content: center;
|
|
@@ -1558,38 +1558,38 @@ S.styles = f`
|
|
|
1558
1558
|
`;
|
|
1559
1559
|
T([
|
|
1560
1560
|
a({ type: String, reflect: !0 })
|
|
1561
|
-
],
|
|
1561
|
+
], E.prototype, "bgstyle", 2);
|
|
1562
1562
|
T([
|
|
1563
1563
|
a({ type: String, reflect: !0 })
|
|
1564
|
-
],
|
|
1564
|
+
], E.prototype, "size", 2);
|
|
1565
1565
|
T([
|
|
1566
1566
|
a({ type: String, reflect: !0 })
|
|
1567
|
-
],
|
|
1567
|
+
], E.prototype, "status", 2);
|
|
1568
1568
|
T([
|
|
1569
1569
|
a({ type: String, reflect: !0 })
|
|
1570
|
-
],
|
|
1570
|
+
], E.prototype, "type", 2);
|
|
1571
1571
|
T([
|
|
1572
1572
|
a({ type: String })
|
|
1573
|
-
],
|
|
1573
|
+
], E.prototype, "strokewidth", 2);
|
|
1574
1574
|
T([
|
|
1575
1575
|
a({ type: String })
|
|
1576
|
-
],
|
|
1576
|
+
], E.prototype, "icon", 2);
|
|
1577
1577
|
T([
|
|
1578
1578
|
a({ type: Boolean, reflect: !0 })
|
|
1579
|
-
],
|
|
1579
|
+
], E.prototype, "disabled", 2);
|
|
1580
1580
|
T([
|
|
1581
1581
|
a({ type: Boolean })
|
|
1582
|
-
],
|
|
1582
|
+
], E.prototype, "showSrLabel", 2);
|
|
1583
1583
|
T([
|
|
1584
1584
|
a({ type: String })
|
|
1585
|
-
],
|
|
1586
|
-
|
|
1585
|
+
], E.prototype, "srLabel", 2);
|
|
1586
|
+
E = T([
|
|
1587
1587
|
m("o-icon-button")
|
|
1588
|
-
],
|
|
1589
|
-
var
|
|
1590
|
-
for (var i = r > 1 ? void 0 : r ?
|
|
1588
|
+
], E);
|
|
1589
|
+
var So = Object.defineProperty, Eo = Object.getOwnPropertyDescriptor, ot = (o, t, e, r) => {
|
|
1590
|
+
for (var i = r > 1 ? void 0 : r ? Eo(t, e) : t, n = o.length - 1, s; n >= 0; n--)
|
|
1591
1591
|
(s = o[n]) && (i = (r ? s(t, e, i) : s(i)) || i);
|
|
1592
|
-
return r && i &&
|
|
1592
|
+
return r && i && So(t, e, i), i;
|
|
1593
1593
|
};
|
|
1594
1594
|
let U = class extends v {
|
|
1595
1595
|
constructor() {
|
|
@@ -1603,7 +1603,7 @@ let U = class extends v {
|
|
|
1603
1603
|
return l`
|
|
1604
1604
|
<a
|
|
1605
1605
|
href="${o}"
|
|
1606
|
-
target="${
|
|
1606
|
+
target="${S(this.target || void 0)}"
|
|
1607
1607
|
@click="${this._handleClick}"
|
|
1608
1608
|
>
|
|
1609
1609
|
${this.endIcon && this.reverseEndIcon ? l`
|
|
@@ -1762,7 +1762,7 @@ let st = class extends v {
|
|
|
1762
1762
|
<div class="rating">
|
|
1763
1763
|
<div class="stars">
|
|
1764
1764
|
${o.map(
|
|
1765
|
-
(t) => l`<span class="star">${
|
|
1765
|
+
(t) => l`<span class="star">${C(F[t] ?? "")}</span>`
|
|
1766
1766
|
)}
|
|
1767
1767
|
</div>
|
|
1768
1768
|
${this.reviewCount != null && this.href != null ? l`<o-link template="review" href="${this.href}">${this.reviewCount}</o-link>` : null}
|
|
@@ -2044,12 +2044,12 @@ let u = class extends v {
|
|
|
2044
2044
|
document.body.style.overflow = "", document.body.removeAttribute("data-side-panel"), this.removeEventListener("keydown", this.handleKeyDown), super.disconnectedCallback(), this.removeEventListener("open-detail", this._onOpenDetail);
|
|
2045
2045
|
}
|
|
2046
2046
|
trapFocus(o) {
|
|
2047
|
-
var i, n, s,
|
|
2047
|
+
var i, n, s, c, h, b, x, p, k, B;
|
|
2048
2048
|
this.innerFocusedElement = document.activeElement || null, this.innerFocusedElement = ((n = (i = this.innerFocusedElement) == null ? void 0 : i.shadowRoot) == null ? void 0 : n.activeElement) || this.innerFocusedElement;
|
|
2049
2049
|
const t = this.getFocusableElements();
|
|
2050
2050
|
if (t.length === 0) return;
|
|
2051
2051
|
const e = t[0], r = t[t.length - 1];
|
|
2052
|
-
o.shiftKey && this.innerFocusedElement === e ? (o.preventDefault(), r.shadowRoot ? (
|
|
2052
|
+
o.shiftKey && this.innerFocusedElement === e ? (o.preventDefault(), r.shadowRoot ? (h = (c = (s = r.shadowRoot) == null ? void 0 : s.querySelector(u.focusablesSelector)) == null ? void 0 : c.focus) == null || h.call(c) : (b = r.focus) == null || b.call(r)) : !o.shiftKey && this.innerFocusedElement === r && (o.preventDefault(), e.shadowRoot ? (k = (p = (x = e.shadowRoot) == null ? void 0 : x.querySelector(u.focusablesSelector)) == null ? void 0 : p.focus) == null || k.call(p) : (B = e.focus) == null || B.call(e));
|
|
2053
2053
|
}
|
|
2054
2054
|
getFocusableElements() {
|
|
2055
2055
|
const o = this.renderRoot.querySelector(".panel");
|
|
@@ -2061,12 +2061,12 @@ let u = class extends v {
|
|
|
2061
2061
|
var s;
|
|
2062
2062
|
const n = [i.matches(u.focusablesSelector) ? i : []];
|
|
2063
2063
|
if (!["o-icon-button", "o-button"].includes(i.tagName.toLowerCase())) {
|
|
2064
|
-
const
|
|
2064
|
+
const c = Array.from(
|
|
2065
2065
|
i instanceof HTMLSlotElement ? i.assignedElements({ flatten: !0 }) : []
|
|
2066
|
-
).filter(t).flatMap(e),
|
|
2066
|
+
).filter(t).flatMap(e), h = Array.from(
|
|
2067
2067
|
((s = i.shadowRoot) == null ? void 0 : s.querySelectorAll("*")) || []
|
|
2068
2068
|
).filter(t).flatMap(e);
|
|
2069
|
-
n.push(...
|
|
2069
|
+
n.push(...c, ...h);
|
|
2070
2070
|
}
|
|
2071
2071
|
return n.flat();
|
|
2072
2072
|
}
|
|
@@ -2459,8 +2459,8 @@ y([
|
|
|
2459
2459
|
u = y([
|
|
2460
2460
|
m("o-side-panel")
|
|
2461
2461
|
], u);
|
|
2462
|
-
var Ro = Object.defineProperty,
|
|
2463
|
-
for (var i = r > 1 ? void 0 : r ?
|
|
2462
|
+
var Ro = Object.defineProperty, No = Object.getOwnPropertyDescriptor, X = (o, t, e, r) => {
|
|
2463
|
+
for (var i = r > 1 ? void 0 : r ? No(t, e) : t, n = o.length - 1, s; n >= 0; n--)
|
|
2464
2464
|
(s = o[n]) && (i = (r ? s(t, e, i) : s(i)) || i);
|
|
2465
2465
|
return r && i && Ro(t, e, i), i;
|
|
2466
2466
|
};
|
|
@@ -2685,10 +2685,10 @@ X([
|
|
|
2685
2685
|
M = X([
|
|
2686
2686
|
m("thumbnail-navigation")
|
|
2687
2687
|
], M);
|
|
2688
|
-
var
|
|
2688
|
+
var Fo = Object.defineProperty, Uo = Object.getOwnPropertyDescriptor, qt = (o, t, e, r) => {
|
|
2689
2689
|
for (var i = r > 1 ? void 0 : r ? Uo(t, e) : t, n = o.length - 1, s; n >= 0; n--)
|
|
2690
2690
|
(s = o[n]) && (i = (r ? s(t, e, i) : s(i)) || i);
|
|
2691
|
-
return r && i &&
|
|
2691
|
+
return r && i && Fo(t, e, i), i;
|
|
2692
2692
|
};
|
|
2693
2693
|
let vt = class extends v {
|
|
2694
2694
|
constructor() {
|
|
@@ -2892,7 +2892,7 @@ var qo = Object.defineProperty, Ko = Object.getOwnPropertyDescriptor, V = (o, t,
|
|
|
2892
2892
|
(s = o[n]) && (i = (r ? s(t, e, i) : s(i)) || i);
|
|
2893
2893
|
return r && i && qo(t, e, i), i;
|
|
2894
2894
|
};
|
|
2895
|
-
let
|
|
2895
|
+
let D = class extends v {
|
|
2896
2896
|
constructor() {
|
|
2897
2897
|
super(...arguments), this.options = [], this.value = "", this.name = "", this.disabled = !1, this.width = "100%", this.open = !1, this.activeIndex = -1, this.menuWidth = "", this._handleOutsideClick = (o) => {
|
|
2898
2898
|
this.contains(o.target) || (this.open = !1, this.activeIndex = -1);
|
|
@@ -2958,7 +2958,7 @@ let B = class extends v {
|
|
|
2958
2958
|
this.options.length > 0 && (this.options.some((e) => e.value === this.value) || (this.value = this.options[0].value));
|
|
2959
2959
|
}
|
|
2960
2960
|
render() {
|
|
2961
|
-
const o =
|
|
2961
|
+
const o = F.checkstroke.replace(
|
|
2962
2962
|
"<svg",
|
|
2963
2963
|
'<svg aria-hidden="true" focusable="false" part="svg"'
|
|
2964
2964
|
), t = this.options.find((e) => e.value === this.value);
|
|
@@ -3003,10 +3003,10 @@ let B = class extends v {
|
|
|
3003
3003
|
${e.url ? l`
|
|
3004
3004
|
<a href="${e.url}">
|
|
3005
3005
|
<span>${e.label}</span>
|
|
3006
|
-
${e.value === this.value ? l`<span class="check">${
|
|
3006
|
+
${e.value === this.value ? l`<span class="check">${C(o)}</span>` : null}
|
|
3007
3007
|
</a>` : l`
|
|
3008
3008
|
<span>${e.label}</span>
|
|
3009
|
-
${e.value === this.value ? l`<span class="check">${
|
|
3009
|
+
${e.value === this.value ? l`<span class="check">${C(o)}</span>` : null}`}
|
|
3010
3010
|
</li>`
|
|
3011
3011
|
)}
|
|
3012
3012
|
</ul>` : null}
|
|
@@ -3015,7 +3015,7 @@ let B = class extends v {
|
|
|
3015
3015
|
`;
|
|
3016
3016
|
}
|
|
3017
3017
|
};
|
|
3018
|
-
|
|
3018
|
+
D.styles = f`
|
|
3019
3019
|
:host {
|
|
3020
3020
|
display: inline-block;
|
|
3021
3021
|
position: relative;
|
|
@@ -3157,31 +3157,31 @@ B.styles = f`
|
|
|
3157
3157
|
`;
|
|
3158
3158
|
V([
|
|
3159
3159
|
a({ type: Array, reflect: !0 })
|
|
3160
|
-
],
|
|
3160
|
+
], D.prototype, "options", 2);
|
|
3161
3161
|
V([
|
|
3162
3162
|
a({ type: String, reflect: !0 })
|
|
3163
|
-
],
|
|
3163
|
+
], D.prototype, "value", 2);
|
|
3164
3164
|
V([
|
|
3165
3165
|
a({ type: String, reflect: !0 })
|
|
3166
|
-
],
|
|
3166
|
+
], D.prototype, "name", 2);
|
|
3167
3167
|
V([
|
|
3168
3168
|
a({ type: Boolean, reflect: !0 })
|
|
3169
|
-
],
|
|
3169
|
+
], D.prototype, "disabled", 2);
|
|
3170
3170
|
V([
|
|
3171
3171
|
a({ type: String, reflect: !0 })
|
|
3172
|
-
],
|
|
3172
|
+
], D.prototype, "width", 2);
|
|
3173
3173
|
V([
|
|
3174
3174
|
et()
|
|
3175
|
-
],
|
|
3175
|
+
], D.prototype, "open", 2);
|
|
3176
3176
|
V([
|
|
3177
3177
|
et()
|
|
3178
|
-
],
|
|
3178
|
+
], D.prototype, "activeIndex", 2);
|
|
3179
3179
|
V([
|
|
3180
3180
|
et()
|
|
3181
|
-
],
|
|
3182
|
-
|
|
3181
|
+
], D.prototype, "menuWidth", 2);
|
|
3182
|
+
D = V([
|
|
3183
3183
|
m("o-dropdown")
|
|
3184
|
-
],
|
|
3184
|
+
], D);
|
|
3185
3185
|
var Wo = Object.getOwnPropertyDescriptor, Go = (o, t, e, r) => {
|
|
3186
3186
|
for (var i = r > 1 ? void 0 : r ? Wo(t, e) : t, n = o.length - 1, s; n >= 0; n--)
|
|
3187
3187
|
(s = o[n]) && (i = s(i) || i);
|
|
@@ -3318,7 +3318,7 @@ let A = class extends v {
|
|
|
3318
3318
|
this.options.length > 0 && (this.options.some((t) => t.value === this.value) || (this.value = this.options[0].value));
|
|
3319
3319
|
}
|
|
3320
3320
|
render() {
|
|
3321
|
-
const o =
|
|
3321
|
+
const o = F.checkstroke.replace(
|
|
3322
3322
|
"<svg",
|
|
3323
3323
|
'<svg aria-hidden="true" focusable="false" part="svg"'
|
|
3324
3324
|
), t = this.options.find((e) => e.value === this.value);
|
|
@@ -3336,7 +3336,7 @@ let A = class extends v {
|
|
|
3336
3336
|
?disabled=${this.disabled}
|
|
3337
3337
|
class="btn-dropdown"
|
|
3338
3338
|
>
|
|
3339
|
-
<img alt="${
|
|
3339
|
+
<img alt="${S(t == null ? void 0 : t.label)}" src="${S(t == null ? void 0 : t.imgurl)}" />
|
|
3340
3340
|
<span id="dropdown-label" class="label">
|
|
3341
3341
|
${t ? t.label : "Select an option"}
|
|
3342
3342
|
</span>
|
|
@@ -3371,13 +3371,13 @@ let A = class extends v {
|
|
|
3371
3371
|
class="${r === this.activeIndex ? "active" : ""} ${e.disabled ? "disabled" : ""}"
|
|
3372
3372
|
@click=${() => this.selectOption(e)}
|
|
3373
3373
|
>
|
|
3374
|
-
<a href="${
|
|
3375
|
-
<img alt="${
|
|
3374
|
+
<a href="${S(e.url)}">
|
|
3375
|
+
<img alt="${S(e.label)}" src="${S(e.imgurl)}" />
|
|
3376
3376
|
<span class="label">${e.label}</span>
|
|
3377
3377
|
<div class="right">
|
|
3378
|
-
<span class="additional-text">${
|
|
3378
|
+
<span class="additional-text">${S(e.additionaltext)}</span>
|
|
3379
3379
|
${e.value === this.value && !e.additionaltext ? l`
|
|
3380
|
-
<span class="check">${
|
|
3380
|
+
<span class="check">${C(o)}</span>` : null}
|
|
3381
3381
|
</div>
|
|
3382
3382
|
</a>
|
|
3383
3383
|
</li>
|
|
@@ -3640,13 +3640,13 @@ let bt = class extends v {
|
|
|
3640
3640
|
width: `${this.imageSize}px`,
|
|
3641
3641
|
height: `${this.imageSize}px`
|
|
3642
3642
|
}, e = l`
|
|
3643
|
-
${this.option.imgurl ? l`<img src="${this.option.imgurl}" alt="${
|
|
3643
|
+
${this.option.imgurl ? l`<img src="${this.option.imgurl}" alt="${S(this.option.title)}" aria-hidden="true" style=${Yo(t)} />` : ""}
|
|
3644
3644
|
<div class="m-reassurance-content">
|
|
3645
|
-
<h3 class="a-reassurance-text">${
|
|
3646
|
-
<p class="a-reassurance-description">${
|
|
3645
|
+
<h3 class="a-reassurance-text">${S(this.option.title)}</h3>
|
|
3646
|
+
<p class="a-reassurance-description">${S(this.option.description)}</p>
|
|
3647
3647
|
</div>
|
|
3648
3648
|
`;
|
|
3649
|
-
return o ? l`<a href="${
|
|
3649
|
+
return o ? l`<a href="${S(this.option.url)}" class="reassurance-item clickable">${e}</a>` : l`<div class="reassurance-item">${e}</div>`;
|
|
3650
3650
|
}
|
|
3651
3651
|
};
|
|
3652
3652
|
bt.styles = f`
|
|
@@ -3745,7 +3745,7 @@ var oi = Object.defineProperty, ii = Object.getOwnPropertyDescriptor, Z = (o, t,
|
|
|
3745
3745
|
(s = o[n]) && (i = (r ? s(t, e, i) : s(i)) || i);
|
|
3746
3746
|
return r && i && oi(t, e, i), i;
|
|
3747
3747
|
};
|
|
3748
|
-
const ri =
|
|
3748
|
+
const ri = Ft(v);
|
|
3749
3749
|
let L = class extends ri {
|
|
3750
3750
|
constructor() {
|
|
3751
3751
|
super(...arguments), this.link = "", this.name = "", this.value = "", this.text = "", this.size = "standard", this.selected = !1, this.fullwidth = !1, this.inactive = !1;
|
|
@@ -3929,7 +3929,7 @@ var ai = Object.defineProperty, li = Object.getOwnPropertyDescriptor, R = (o, t,
|
|
|
3929
3929
|
(s = o[n]) && (i = (r ? s(t, e, i) : s(i)) || i);
|
|
3930
3930
|
return r && i && ai(t, e, i), i;
|
|
3931
3931
|
};
|
|
3932
|
-
const ci =
|
|
3932
|
+
const ci = Ft(v);
|
|
3933
3933
|
let I = class extends ci {
|
|
3934
3934
|
constructor() {
|
|
3935
3935
|
super(...arguments), this.name = "", this.value = "", this.type = "", this.text = "", this.selected = !1, this.disabled = !1, this.fullwidth = !1, this.crossIconName = "cross", this.strikethroughImgName = "strikeDiagonal";
|
|
@@ -3942,18 +3942,18 @@ let I = class extends ci {
|
|
|
3942
3942
|
this.dispatchEvent(e), e.defaultPrevented && o.preventDefault(), this.selected = t.selected;
|
|
3943
3943
|
}
|
|
3944
3944
|
crossIcon() {
|
|
3945
|
-
const o =
|
|
3945
|
+
const o = F[this.crossIconName].replace(
|
|
3946
3946
|
"<svg",
|
|
3947
3947
|
'<svg aria-hidden="true" focusable="false" part="svg"'
|
|
3948
3948
|
).replace(/stroke=[#"'a-z1-9]*/gi, "");
|
|
3949
|
-
return l`<span class="cross-icon">${
|
|
3949
|
+
return l`<span class="cross-icon">${C(o)}</span>`;
|
|
3950
3950
|
}
|
|
3951
3951
|
strikeThroughImg() {
|
|
3952
3952
|
const o = go[this.strikethroughImgName].replace(
|
|
3953
3953
|
"<svg",
|
|
3954
3954
|
'<svg aria-hidden="true" focusable="false" part="strikethrough"'
|
|
3955
3955
|
).replace(/stroke=[#"'a-z1-9]*/gi, "");
|
|
3956
|
-
return
|
|
3956
|
+
return C(o);
|
|
3957
3957
|
}
|
|
3958
3958
|
render() {
|
|
3959
3959
|
const o = this.text;
|
|
@@ -4365,14 +4365,14 @@ Xt([
|
|
|
4365
4365
|
yt = Xt([
|
|
4366
4366
|
m("o-badge")
|
|
4367
4367
|
], yt);
|
|
4368
|
-
var ui = Object.defineProperty, vi = Object.getOwnPropertyDescriptor,
|
|
4368
|
+
var ui = Object.defineProperty, vi = Object.getOwnPropertyDescriptor, z = (o, t, e, r) => {
|
|
4369
4369
|
for (var i = r > 1 ? void 0 : r ? vi(t, e) : t, n = o.length - 1, s; n >= 0; n--)
|
|
4370
4370
|
(s = o[n]) && (i = (r ? s(t, e, i) : s(i)) || i);
|
|
4371
4371
|
return r && i && ui(t, e, i), i;
|
|
4372
4372
|
};
|
|
4373
|
-
let
|
|
4373
|
+
let $ = class extends v {
|
|
4374
4374
|
constructor() {
|
|
4375
|
-
super(...arguments), this.icon = "info", this.text = "Sample text", this.verticalanchor = "top", this.horizontalanchor = "right", this.verticaloffset = 24, this.horizontaloffset = 24, this.animationduration = 500, this.animationaxis = "horizontal", this.animated = !0, this.lifeduration = 5e3;
|
|
4375
|
+
super(...arguments), this.icon = "info", this.text = "Sample text", this.verticalanchor = "top", this.horizontalanchor = "right", this.verticaloffset = 24, this.horizontaloffset = 24, this.animationduration = 500, this.animationaxis = "horizontal", this.animated = !0, this.lifeduration = 5e3, this.multiline = !1;
|
|
4376
4376
|
}
|
|
4377
4377
|
attributeChangedCallback(o, t, e) {
|
|
4378
4378
|
super.attributeChangedCallback(o, t, e), o == "verticaloffset" && this.style.setProperty("--vertical-offset", e + "px"), o == "horizontaloffset" && this.style.setProperty("--horizontal-offset", e + "px"), o == "animationduration" && this.style.setProperty("--animation-duration", e + "ms");
|
|
@@ -4402,9 +4402,13 @@ let C = class extends v {
|
|
|
4402
4402
|
}, 600);
|
|
4403
4403
|
}
|
|
4404
4404
|
firstUpdated() {
|
|
4405
|
-
var
|
|
4405
|
+
var r, i;
|
|
4406
4406
|
var o = this;
|
|
4407
|
-
const t = (
|
|
4407
|
+
const t = (r = this.renderRoot) == null ? void 0 : r.querySelector("o-icon-button"), e = (i = this.renderRoot) == null ? void 0 : i.querySelector(".o-toast-text");
|
|
4408
|
+
if (e != null) {
|
|
4409
|
+
const n = window.getComputedStyle(e), s = parseInt(n.getPropertyValue("line-height").replace("px", "")), c = parseInt(n.getPropertyValue("height").replace("px", ""));
|
|
4410
|
+
!isNaN(s) && !isNaN(c) && c > s && (this.multiline = !0);
|
|
4411
|
+
}
|
|
4408
4412
|
t != null && t.addEventListener("click", function() {
|
|
4409
4413
|
o.remove();
|
|
4410
4414
|
});
|
|
@@ -4414,7 +4418,7 @@ let C = class extends v {
|
|
|
4414
4418
|
return l`
|
|
4415
4419
|
<div class="o-toast">
|
|
4416
4420
|
<div class="o-toast-icon">
|
|
4417
|
-
${
|
|
4421
|
+
${C(t)}
|
|
4418
4422
|
</div>
|
|
4419
4423
|
<div class="o-toast-text">
|
|
4420
4424
|
${this.text}
|
|
@@ -4430,7 +4434,7 @@ let C = class extends v {
|
|
|
4430
4434
|
`;
|
|
4431
4435
|
}
|
|
4432
4436
|
};
|
|
4433
|
-
|
|
4437
|
+
$.styles = f`
|
|
4434
4438
|
:host {
|
|
4435
4439
|
--vertical-offset: 24px;
|
|
4436
4440
|
--horizontal-offset: 24px;
|
|
@@ -4477,6 +4481,15 @@ C.styles = f`
|
|
|
4477
4481
|
bottom: -100%;
|
|
4478
4482
|
}
|
|
4479
4483
|
|
|
4484
|
+
:host([multiline]) .o-toast-close {
|
|
4485
|
+
align-self: flex-start;
|
|
4486
|
+
}
|
|
4487
|
+
|
|
4488
|
+
:host([multiline]) .o-toast-icon {
|
|
4489
|
+
align-self: flex-start;
|
|
4490
|
+
line-height: 2.8rem;
|
|
4491
|
+
}
|
|
4492
|
+
|
|
4480
4493
|
.o-toast {
|
|
4481
4494
|
background: #fffefe;
|
|
4482
4495
|
padding: var(--spacing-l);
|
|
@@ -4491,7 +4504,7 @@ C.styles = f`
|
|
|
4491
4504
|
color: var(--color-content-body);
|
|
4492
4505
|
padding: 0 12px;
|
|
4493
4506
|
width: max-content;
|
|
4494
|
-
|
|
4507
|
+
line-height: 20px;
|
|
4495
4508
|
max-width: 65vw;
|
|
4496
4509
|
}
|
|
4497
4510
|
|
|
@@ -4499,39 +4512,42 @@ C.styles = f`
|
|
|
4499
4512
|
height: 16px;
|
|
4500
4513
|
}
|
|
4501
4514
|
`;
|
|
4502
|
-
|
|
4515
|
+
z([
|
|
4503
4516
|
a({ type: String, reflect: !0 })
|
|
4504
|
-
],
|
|
4505
|
-
|
|
4517
|
+
], $.prototype, "icon", 2);
|
|
4518
|
+
z([
|
|
4506
4519
|
a({ type: String, reflect: !0 })
|
|
4507
|
-
],
|
|
4508
|
-
|
|
4520
|
+
], $.prototype, "text", 2);
|
|
4521
|
+
z([
|
|
4509
4522
|
a({ type: String, reflect: !0 })
|
|
4510
|
-
],
|
|
4511
|
-
|
|
4523
|
+
], $.prototype, "verticalanchor", 2);
|
|
4524
|
+
z([
|
|
4512
4525
|
a({ type: String, reflect: !0 })
|
|
4513
|
-
],
|
|
4514
|
-
|
|
4526
|
+
], $.prototype, "horizontalanchor", 2);
|
|
4527
|
+
z([
|
|
4515
4528
|
a({ type: Number, reflect: !0 })
|
|
4516
|
-
],
|
|
4517
|
-
|
|
4529
|
+
], $.prototype, "verticaloffset", 2);
|
|
4530
|
+
z([
|
|
4518
4531
|
a({ type: Number, reflect: !0 })
|
|
4519
|
-
],
|
|
4520
|
-
|
|
4532
|
+
], $.prototype, "horizontaloffset", 2);
|
|
4533
|
+
z([
|
|
4521
4534
|
a({ type: Number, reflect: !0 })
|
|
4522
|
-
],
|
|
4523
|
-
|
|
4535
|
+
], $.prototype, "animationduration", 2);
|
|
4536
|
+
z([
|
|
4524
4537
|
a({ type: String, reflect: !0 })
|
|
4525
|
-
],
|
|
4526
|
-
|
|
4538
|
+
], $.prototype, "animationaxis", 2);
|
|
4539
|
+
z([
|
|
4527
4540
|
a({ type: Boolean, reflect: !0 })
|
|
4528
|
-
],
|
|
4529
|
-
|
|
4541
|
+
], $.prototype, "animated", 2);
|
|
4542
|
+
z([
|
|
4530
4543
|
a({ type: Number, reflect: !0 })
|
|
4531
|
-
],
|
|
4532
|
-
|
|
4544
|
+
], $.prototype, "lifeduration", 2);
|
|
4545
|
+
z([
|
|
4546
|
+
a({ type: Boolean, reflect: !0 })
|
|
4547
|
+
], $.prototype, "multiline", 2);
|
|
4548
|
+
$ = z([
|
|
4533
4549
|
m("o-toast")
|
|
4534
|
-
],
|
|
4550
|
+
], $);
|
|
4535
4551
|
var fi = Object.defineProperty, bi = Object.getOwnPropertyDescriptor, H = (o, t, e, r) => {
|
|
4536
4552
|
for (var i = r > 1 ? void 0 : r ? bi(t, e) : t, n = o.length - 1, s; n >= 0; n--)
|
|
4537
4553
|
(s = o[n]) && (i = (r ? s(t, e, i) : s(i)) || i);
|
|
@@ -4554,7 +4570,7 @@ let gi = 0, _ = class extends v {
|
|
|
4554
4570
|
this.disabled || (o.key === " " || o.key === "Enter") && (o.preventDefault(), this.toggle());
|
|
4555
4571
|
}
|
|
4556
4572
|
render() {
|
|
4557
|
-
const o =
|
|
4573
|
+
const o = C(F.checkbox.replace("<svg", '<svg aria-hidden="true" focusable="false" part="svg"')), t = C(F.icoMinus.replace("<svg", '<svg class="indeterminate" aria-hidden="true" focusable="false" part="svg"'));
|
|
4558
4574
|
return l`
|
|
4559
4575
|
<input
|
|
4560
4576
|
type="checkbox"
|
|
@@ -4707,7 +4723,7 @@ H([
|
|
|
4707
4723
|
_ = H([
|
|
4708
4724
|
m("o-checkbox")
|
|
4709
4725
|
], _);
|
|
4710
|
-
var yi = Object.defineProperty, mi = Object.getOwnPropertyDescriptor,
|
|
4726
|
+
var yi = Object.defineProperty, mi = Object.getOwnPropertyDescriptor, N = (o, t, e, r) => {
|
|
4711
4727
|
for (var i = r > 1 ? void 0 : r ? mi(t, e) : t, n = o.length - 1, s; n >= 0; n--)
|
|
4712
4728
|
(s = o[n]) && (i = (r ? s(t, e, i) : s(i)) || i);
|
|
4713
4729
|
return r && i && yi(t, e, i), i;
|
|
@@ -4829,33 +4845,33 @@ O.styles = f`
|
|
|
4829
4845
|
height: 0;
|
|
4830
4846
|
}
|
|
4831
4847
|
`;
|
|
4832
|
-
|
|
4848
|
+
N([
|
|
4833
4849
|
a({ type: Boolean, reflect: !0 })
|
|
4834
4850
|
], O.prototype, "checked", 2);
|
|
4835
|
-
|
|
4851
|
+
N([
|
|
4836
4852
|
a({ type: Boolean, reflect: !0 })
|
|
4837
4853
|
], O.prototype, "disabled", 2);
|
|
4838
|
-
|
|
4854
|
+
N([
|
|
4839
4855
|
a({ type: String, reflect: !0 })
|
|
4840
4856
|
], O.prototype, "size", 2);
|
|
4841
|
-
|
|
4857
|
+
N([
|
|
4842
4858
|
a({ type: Boolean })
|
|
4843
4859
|
], O.prototype, "showLabel", 2);
|
|
4844
|
-
|
|
4860
|
+
N([
|
|
4845
4861
|
a({ type: String })
|
|
4846
4862
|
], O.prototype, "label", 2);
|
|
4847
|
-
|
|
4863
|
+
N([
|
|
4848
4864
|
a({ type: String })
|
|
4849
4865
|
], O.prototype, "name", 2);
|
|
4850
|
-
|
|
4866
|
+
N([
|
|
4851
4867
|
a({ type: String })
|
|
4852
4868
|
], O.prototype, "value", 2);
|
|
4853
|
-
|
|
4869
|
+
N([
|
|
4854
4870
|
a({ type: String, reflect: !0 })
|
|
4855
4871
|
], O.prototype, "inputId", 2);
|
|
4856
|
-
|
|
4872
|
+
N([
|
|
4857
4873
|
fe("input")
|
|
4858
4874
|
], O.prototype, "inputEl", 2);
|
|
4859
|
-
O =
|
|
4875
|
+
O = N([
|
|
4860
4876
|
m("o-radio")
|
|
4861
4877
|
], O);
|