@decidables/decidables-elements 0.3.5 → 0.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +24 -0
- package/lib/decidablesElements.esm.js +541 -997
- package/lib/decidablesElements.esm.js.map +1 -1
- package/lib/decidablesElements.esm.min.js +61 -63
- package/lib/decidablesElements.esm.min.js.map +1 -1
- package/lib/decidablesElements.umd.js +541 -996
- package/lib/decidablesElements.umd.js.map +1 -1
- package/lib/decidablesElements.umd.min.js +61 -63
- package/lib/decidablesElements.umd.min.js.map +1 -1
- package/package.json +4 -4
- package/src/decidables-element.js +54 -1
- package/src/index.js +7 -0
- package/src/mixin-resizeable.js +51 -0
- package/src/spinner.js +15 -0
|
@@ -9,21 +9,21 @@
|
|
|
9
9
|
* Copyright 2019 Google LLC
|
|
10
10
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
11
11
|
*/
|
|
12
|
-
const t$
|
|
13
|
-
e$
|
|
14
|
-
s$
|
|
15
|
-
|
|
16
|
-
let
|
|
17
|
-
constructor(t, e,
|
|
18
|
-
if (this._$cssResult$ = !0,
|
|
12
|
+
const t$1 = globalThis,
|
|
13
|
+
e$2 = t$1.ShadowRoot && (void 0 === t$1.ShadyCSS || t$1.ShadyCSS.nativeShadow) && "adoptedStyleSheets" in Document.prototype && "replace" in CSSStyleSheet.prototype,
|
|
14
|
+
s$2 = Symbol(),
|
|
15
|
+
o$3 = new WeakMap();
|
|
16
|
+
let n$2 = class n {
|
|
17
|
+
constructor(t, e, o) {
|
|
18
|
+
if (this._$cssResult$ = !0, o !== s$2) throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");
|
|
19
19
|
this.cssText = t, this.t = e;
|
|
20
20
|
}
|
|
21
21
|
get styleSheet() {
|
|
22
22
|
let t = this.o;
|
|
23
23
|
const s = this.t;
|
|
24
|
-
if (e$
|
|
24
|
+
if (e$2 && void 0 === t) {
|
|
25
25
|
const e = void 0 !== s && 1 === s.length;
|
|
26
|
-
e && (t =
|
|
26
|
+
e && (t = o$3.get(s)), void 0 === t && ((this.o = t = new CSSStyleSheet()).replaceSync(this.cssText), e && o$3.set(s, t));
|
|
27
27
|
}
|
|
28
28
|
return t;
|
|
29
29
|
}
|
|
@@ -31,18 +31,26 @@
|
|
|
31
31
|
return this.cssText;
|
|
32
32
|
}
|
|
33
33
|
};
|
|
34
|
-
const r$
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
});
|
|
34
|
+
const r$3 = t => new n$2("string" == typeof t ? t : t + "", void 0, s$2),
|
|
35
|
+
i$2 = (t, ...e) => {
|
|
36
|
+
const o = 1 === t.length ? t[0] : e.reduce((e, s, o) => e + (t => {
|
|
37
|
+
if (!0 === t._$cssResult$) return t.cssText;
|
|
38
|
+
if ("number" == typeof t) return t;
|
|
39
|
+
throw Error("Value passed to 'css' function must be a 'css' function result: " + t + ". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.");
|
|
40
|
+
})(s) + t[o + 1], t[0]);
|
|
41
|
+
return new n$2(o, t, s$2);
|
|
41
42
|
},
|
|
42
|
-
|
|
43
|
+
S$1 = (s, o) => {
|
|
44
|
+
if (e$2) s.adoptedStyleSheets = o.map(t => t instanceof CSSStyleSheet ? t : t.styleSheet);else for (const e of o) {
|
|
45
|
+
const o = document.createElement("style"),
|
|
46
|
+
n = t$1.litNonce;
|
|
47
|
+
void 0 !== n && o.setAttribute("nonce", n), o.textContent = e.cssText, s.appendChild(o);
|
|
48
|
+
}
|
|
49
|
+
},
|
|
50
|
+
c$2 = e$2 ? t => t : t => t instanceof CSSStyleSheet ? (t => {
|
|
43
51
|
let e = "";
|
|
44
52
|
for (const s of t.cssRules) e += s.cssText;
|
|
45
|
-
return r$
|
|
53
|
+
return r$3(e);
|
|
46
54
|
})(t) : t;
|
|
47
55
|
|
|
48
56
|
/**
|
|
@@ -50,16 +58,24 @@
|
|
|
50
58
|
* Copyright 2017 Google LLC
|
|
51
59
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
52
60
|
*/
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
+
const {
|
|
62
|
+
is: i$1,
|
|
63
|
+
defineProperty: e$1,
|
|
64
|
+
getOwnPropertyDescriptor: r$2,
|
|
65
|
+
getOwnPropertyNames: h$1,
|
|
66
|
+
getOwnPropertySymbols: o$2,
|
|
67
|
+
getPrototypeOf: n$1
|
|
68
|
+
} = Object,
|
|
69
|
+
a$1 = globalThis,
|
|
70
|
+
c$1 = a$1.trustedTypes,
|
|
71
|
+
l$1 = c$1 ? c$1.emptyScript : "",
|
|
72
|
+
p$1 = a$1.reactiveElementPolyfillSupport,
|
|
73
|
+
d$1 = (t, s) => t,
|
|
74
|
+
u$1 = {
|
|
75
|
+
toAttribute(t, s) {
|
|
76
|
+
switch (s) {
|
|
61
77
|
case Boolean:
|
|
62
|
-
t = t ?
|
|
78
|
+
t = t ? l$1 : null;
|
|
63
79
|
break;
|
|
64
80
|
case Object:
|
|
65
81
|
case Array:
|
|
@@ -67,752 +83,177 @@
|
|
|
67
83
|
}
|
|
68
84
|
return t;
|
|
69
85
|
},
|
|
70
|
-
fromAttribute(t,
|
|
71
|
-
let
|
|
72
|
-
switch (
|
|
86
|
+
fromAttribute(t, s) {
|
|
87
|
+
let i = t;
|
|
88
|
+
switch (s) {
|
|
73
89
|
case Boolean:
|
|
74
|
-
|
|
90
|
+
i = null !== t;
|
|
75
91
|
break;
|
|
76
92
|
case Number:
|
|
77
|
-
|
|
93
|
+
i = null === t ? null : Number(t);
|
|
78
94
|
break;
|
|
79
95
|
case Object:
|
|
80
96
|
case Array:
|
|
81
97
|
try {
|
|
82
|
-
|
|
98
|
+
i = JSON.parse(t);
|
|
83
99
|
} catch (t) {
|
|
84
|
-
|
|
100
|
+
i = null;
|
|
85
101
|
}
|
|
86
102
|
}
|
|
87
|
-
return
|
|
103
|
+
return i;
|
|
88
104
|
}
|
|
89
105
|
},
|
|
90
|
-
|
|
91
|
-
|
|
106
|
+
f$1 = (t, s) => !i$1(t, s),
|
|
107
|
+
y$1 = {
|
|
92
108
|
attribute: !0,
|
|
93
109
|
type: String,
|
|
94
|
-
converter:
|
|
110
|
+
converter: u$1,
|
|
95
111
|
reflect: !1,
|
|
96
|
-
hasChanged:
|
|
112
|
+
hasChanged: f$1
|
|
97
113
|
};
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
super(), this._$Ei = new Map(), this.isUpdatePending = !1, this.hasUpdated = !1, this._$El = null, this.u();
|
|
101
|
-
}
|
|
114
|
+
Symbol.metadata ??= Symbol("metadata"), a$1.litPropertyMetadata ??= new WeakMap();
|
|
115
|
+
let b$1 = class b extends HTMLElement {
|
|
102
116
|
static addInitializer(t) {
|
|
103
|
-
|
|
104
|
-
this.finalize(), (null !== (i = this.h) && void 0 !== i ? i : this.h = []).push(t);
|
|
117
|
+
this._$Ei(), (this.l ??= []).push(t);
|
|
105
118
|
}
|
|
106
119
|
static get observedAttributes() {
|
|
107
|
-
this.finalize();
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
static createProperty(t, i = l$5) {
|
|
115
|
-
if (i.state && (i.attribute = !1), this.finalize(), this.elementProperties.set(t, i), !i.noAccessor && !this.prototype.hasOwnProperty(t)) {
|
|
116
|
-
const s = "symbol" == typeof t ? Symbol() : "__" + t,
|
|
117
|
-
e = this.getPropertyDescriptor(t, s, i);
|
|
118
|
-
void 0 !== e && Object.defineProperty(this.prototype, t, e);
|
|
120
|
+
return this.finalize(), this._$Eh && [...this._$Eh.keys()];
|
|
121
|
+
}
|
|
122
|
+
static createProperty(t, s = y$1) {
|
|
123
|
+
if (s.state && (s.attribute = !1), this._$Ei(), this.elementProperties.set(t, s), !s.noAccessor) {
|
|
124
|
+
const i = Symbol(),
|
|
125
|
+
r = this.getPropertyDescriptor(t, i, s);
|
|
126
|
+
void 0 !== r && e$1(this.prototype, t, r);
|
|
119
127
|
}
|
|
120
128
|
}
|
|
121
|
-
static getPropertyDescriptor(t,
|
|
129
|
+
static getPropertyDescriptor(t, s, i) {
|
|
130
|
+
const {
|
|
131
|
+
get: e,
|
|
132
|
+
set: h
|
|
133
|
+
} = r$2(this.prototype, t) ?? {
|
|
134
|
+
get() {
|
|
135
|
+
return this[s];
|
|
136
|
+
},
|
|
137
|
+
set(t) {
|
|
138
|
+
this[s] = t;
|
|
139
|
+
}
|
|
140
|
+
};
|
|
122
141
|
return {
|
|
123
142
|
get() {
|
|
124
|
-
return this
|
|
143
|
+
return e?.call(this);
|
|
125
144
|
},
|
|
126
|
-
set(
|
|
127
|
-
const r = this
|
|
128
|
-
this
|
|
145
|
+
set(s) {
|
|
146
|
+
const r = e?.call(this);
|
|
147
|
+
h.call(this, s), this.requestUpdate(t, r, i);
|
|
129
148
|
},
|
|
130
149
|
configurable: !0,
|
|
131
150
|
enumerable: !0
|
|
132
151
|
};
|
|
133
152
|
}
|
|
134
153
|
static getPropertyOptions(t) {
|
|
135
|
-
return this.elementProperties.get(t)
|
|
154
|
+
return this.elementProperties.get(t) ?? y$1;
|
|
155
|
+
}
|
|
156
|
+
static _$Ei() {
|
|
157
|
+
if (this.hasOwnProperty(d$1("elementProperties"))) return;
|
|
158
|
+
const t = n$1(this);
|
|
159
|
+
t.finalize(), void 0 !== t.l && (this.l = [...t.l]), this.elementProperties = new Map(t.elementProperties);
|
|
136
160
|
}
|
|
137
161
|
static finalize() {
|
|
138
|
-
if (this.hasOwnProperty("finalized")) return
|
|
139
|
-
this.finalized = !0
|
|
140
|
-
const t = Object.getPrototypeOf(this);
|
|
141
|
-
if (t.finalize(), void 0 !== t.h && (this.h = [...t.h]), this.elementProperties = new Map(t.elementProperties), this._$Ev = new Map(), this.hasOwnProperty("properties")) {
|
|
162
|
+
if (this.hasOwnProperty(d$1("finalized"))) return;
|
|
163
|
+
if (this.finalized = !0, this._$Ei(), this.hasOwnProperty(d$1("properties"))) {
|
|
142
164
|
const t = this.properties,
|
|
143
|
-
|
|
144
|
-
for (const
|
|
145
|
-
}
|
|
146
|
-
return this.elementStyles = this.finalizeStyles(this.styles), !0;
|
|
147
|
-
}
|
|
148
|
-
static finalizeStyles(i) {
|
|
149
|
-
const s = [];
|
|
150
|
-
if (Array.isArray(i)) {
|
|
151
|
-
const e = new Set(i.flat(1 / 0).reverse());
|
|
152
|
-
for (const i of e) s.unshift(c$2(i));
|
|
153
|
-
} else void 0 !== i && s.push(c$2(i));
|
|
154
|
-
return s;
|
|
155
|
-
}
|
|
156
|
-
static _$Ep(t, i) {
|
|
157
|
-
const s = i.attribute;
|
|
158
|
-
return !1 === s ? void 0 : "string" == typeof s ? s : "string" == typeof t ? t.toLowerCase() : void 0;
|
|
159
|
-
}
|
|
160
|
-
u() {
|
|
161
|
-
var t;
|
|
162
|
-
this._$E_ = new Promise(t => this.enableUpdating = t), this._$AL = new Map(), this._$Eg(), this.requestUpdate(), null === (t = this.constructor.h) || void 0 === t || t.forEach(t => t(this));
|
|
163
|
-
}
|
|
164
|
-
addController(t) {
|
|
165
|
-
var i, s;
|
|
166
|
-
(null !== (i = this._$ES) && void 0 !== i ? i : this._$ES = []).push(t), void 0 !== this.renderRoot && this.isConnected && (null === (s = t.hostConnected) || void 0 === s || s.call(t));
|
|
167
|
-
}
|
|
168
|
-
removeController(t) {
|
|
169
|
-
var i;
|
|
170
|
-
null === (i = this._$ES) || void 0 === i || i.splice(this._$ES.indexOf(t) >>> 0, 1);
|
|
171
|
-
}
|
|
172
|
-
_$Eg() {
|
|
173
|
-
this.constructor.elementProperties.forEach((t, i) => {
|
|
174
|
-
this.hasOwnProperty(i) && (this._$Ei.set(i, this[i]), delete this[i]);
|
|
175
|
-
});
|
|
176
|
-
}
|
|
177
|
-
createRenderRoot() {
|
|
178
|
-
var t;
|
|
179
|
-
const s = null !== (t = this.shadowRoot) && void 0 !== t ? t : this.attachShadow(this.constructor.shadowRootOptions);
|
|
180
|
-
return S$3(s, this.constructor.elementStyles), s;
|
|
181
|
-
}
|
|
182
|
-
connectedCallback() {
|
|
183
|
-
var t;
|
|
184
|
-
void 0 === this.renderRoot && (this.renderRoot = this.createRenderRoot()), this.enableUpdating(!0), null === (t = this._$ES) || void 0 === t || t.forEach(t => {
|
|
185
|
-
var i;
|
|
186
|
-
return null === (i = t.hostConnected) || void 0 === i ? void 0 : i.call(t);
|
|
187
|
-
});
|
|
188
|
-
}
|
|
189
|
-
enableUpdating(t) {}
|
|
190
|
-
disconnectedCallback() {
|
|
191
|
-
var t;
|
|
192
|
-
null === (t = this._$ES) || void 0 === t || t.forEach(t => {
|
|
193
|
-
var i;
|
|
194
|
-
return null === (i = t.hostDisconnected) || void 0 === i ? void 0 : i.call(t);
|
|
195
|
-
});
|
|
196
|
-
}
|
|
197
|
-
attributeChangedCallback(t, i, s) {
|
|
198
|
-
this._$AK(t, s);
|
|
199
|
-
}
|
|
200
|
-
_$EO(t, i, s = l$5) {
|
|
201
|
-
var e;
|
|
202
|
-
const r = this.constructor._$Ep(t, s);
|
|
203
|
-
if (void 0 !== r && !0 === s.reflect) {
|
|
204
|
-
const h = (void 0 !== (null === (e = s.converter) || void 0 === e ? void 0 : e.toAttribute) ? s.converter : n$5).toAttribute(i, s.type);
|
|
205
|
-
this._$El = t, null == h ? this.removeAttribute(r) : this.setAttribute(r, h), this._$El = null;
|
|
206
|
-
}
|
|
207
|
-
}
|
|
208
|
-
_$AK(t, i) {
|
|
209
|
-
var s;
|
|
210
|
-
const e = this.constructor,
|
|
211
|
-
r = e._$Ev.get(t);
|
|
212
|
-
if (void 0 !== r && this._$El !== r) {
|
|
213
|
-
const t = e.getPropertyOptions(r),
|
|
214
|
-
h = "function" == typeof t.converter ? {
|
|
215
|
-
fromAttribute: t.converter
|
|
216
|
-
} : void 0 !== (null === (s = t.converter) || void 0 === s ? void 0 : s.fromAttribute) ? t.converter : n$5;
|
|
217
|
-
this._$El = r, this[r] = h.fromAttribute(i, t.type), this._$El = null;
|
|
218
|
-
}
|
|
219
|
-
}
|
|
220
|
-
requestUpdate(t, i, s) {
|
|
221
|
-
let e = !0;
|
|
222
|
-
void 0 !== t && (((s = s || this.constructor.getPropertyOptions(t)).hasChanged || a$3)(this[t], i) ? (this._$AL.has(t) || this._$AL.set(t, i), !0 === s.reflect && this._$El !== t && (void 0 === this._$EC && (this._$EC = new Map()), this._$EC.set(t, s))) : e = !1), !this.isUpdatePending && e && (this._$E_ = this._$Ej());
|
|
223
|
-
}
|
|
224
|
-
async _$Ej() {
|
|
225
|
-
this.isUpdatePending = !0;
|
|
226
|
-
try {
|
|
227
|
-
await this._$E_;
|
|
228
|
-
} catch (t) {
|
|
229
|
-
Promise.reject(t);
|
|
230
|
-
}
|
|
231
|
-
const t = this.scheduleUpdate();
|
|
232
|
-
return null != t && (await t), !this.isUpdatePending;
|
|
233
|
-
}
|
|
234
|
-
scheduleUpdate() {
|
|
235
|
-
return this.performUpdate();
|
|
236
|
-
}
|
|
237
|
-
performUpdate() {
|
|
238
|
-
var t;
|
|
239
|
-
if (!this.isUpdatePending) return;
|
|
240
|
-
this.hasUpdated, this._$Ei && (this._$Ei.forEach((t, i) => this[i] = t), this._$Ei = void 0);
|
|
241
|
-
let i = !1;
|
|
242
|
-
const s = this._$AL;
|
|
243
|
-
try {
|
|
244
|
-
i = this.shouldUpdate(s), i ? (this.willUpdate(s), null === (t = this._$ES) || void 0 === t || t.forEach(t => {
|
|
245
|
-
var i;
|
|
246
|
-
return null === (i = t.hostUpdate) || void 0 === i ? void 0 : i.call(t);
|
|
247
|
-
}), this.update(s)) : this._$Ek();
|
|
248
|
-
} catch (t) {
|
|
249
|
-
throw i = !1, this._$Ek(), t;
|
|
250
|
-
}
|
|
251
|
-
i && this._$AE(s);
|
|
252
|
-
}
|
|
253
|
-
willUpdate(t) {}
|
|
254
|
-
_$AE(t) {
|
|
255
|
-
var i;
|
|
256
|
-
null === (i = this._$ES) || void 0 === i || i.forEach(t => {
|
|
257
|
-
var i;
|
|
258
|
-
return null === (i = t.hostUpdated) || void 0 === i ? void 0 : i.call(t);
|
|
259
|
-
}), this.hasUpdated || (this.hasUpdated = !0, this.firstUpdated(t)), this.updated(t);
|
|
260
|
-
}
|
|
261
|
-
_$Ek() {
|
|
262
|
-
this._$AL = new Map(), this.isUpdatePending = !1;
|
|
263
|
-
}
|
|
264
|
-
get updateComplete() {
|
|
265
|
-
return this.getUpdateComplete();
|
|
266
|
-
}
|
|
267
|
-
getUpdateComplete() {
|
|
268
|
-
return this._$E_;
|
|
269
|
-
}
|
|
270
|
-
shouldUpdate(t) {
|
|
271
|
-
return !0;
|
|
272
|
-
}
|
|
273
|
-
update(t) {
|
|
274
|
-
void 0 !== this._$EC && (this._$EC.forEach((t, i) => this._$EO(i, this[i], t)), this._$EC = void 0), this._$Ek();
|
|
275
|
-
}
|
|
276
|
-
updated(t) {}
|
|
277
|
-
firstUpdated(t) {}
|
|
278
|
-
};
|
|
279
|
-
d$2.finalized = !0, d$2.elementProperties = new Map(), d$2.elementStyles = [], d$2.shadowRootOptions = {
|
|
280
|
-
mode: "open"
|
|
281
|
-
}, null == o$5 || o$5({
|
|
282
|
-
ReactiveElement: d$2
|
|
283
|
-
}), (null !== (s$5 = e$4.reactiveElementVersions) && void 0 !== s$5 ? s$5 : e$4.reactiveElementVersions = []).push("1.6.1");
|
|
284
|
-
|
|
285
|
-
/**
|
|
286
|
-
* @license
|
|
287
|
-
* Copyright 2017 Google LLC
|
|
288
|
-
* SPDX-License-Identifier: BSD-3-Clause
|
|
289
|
-
*/
|
|
290
|
-
var t$2;
|
|
291
|
-
const i$2 = window,
|
|
292
|
-
s$4 = i$2.trustedTypes,
|
|
293
|
-
e$3 = s$4 ? s$4.createPolicy("lit-html", {
|
|
294
|
-
createHTML: t => t
|
|
295
|
-
}) : void 0,
|
|
296
|
-
o$4 = "$lit$",
|
|
297
|
-
n$4 = `lit$${(Math.random() + "").slice(9)}$`,
|
|
298
|
-
l$4 = "?" + n$4,
|
|
299
|
-
h$2 = `<${l$4}>`,
|
|
300
|
-
r$3 = document,
|
|
301
|
-
u$1 = () => r$3.createComment(""),
|
|
302
|
-
d$1 = t => null === t || "object" != typeof t && "function" != typeof t,
|
|
303
|
-
c$1 = Array.isArray,
|
|
304
|
-
v$1 = t => c$1(t) || "function" == typeof (null == t ? void 0 : t[Symbol.iterator]),
|
|
305
|
-
a$2 = "[ \t\n\f\r]",
|
|
306
|
-
f$1 = /<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,
|
|
307
|
-
_$1 = /-->/g,
|
|
308
|
-
m$1 = />/g,
|
|
309
|
-
p$1 = RegExp(`>|${a$2}(?:([^\\s"'>=/]+)(${a$2}*=${a$2}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`, "g"),
|
|
310
|
-
g$1 = /'/g,
|
|
311
|
-
$$1 = /"/g,
|
|
312
|
-
y$1 = /^(?:script|style|textarea|title)$/i,
|
|
313
|
-
T$1 = Symbol.for("lit-noChange"),
|
|
314
|
-
A$1 = Symbol.for("lit-nothing"),
|
|
315
|
-
E$1 = new WeakMap(),
|
|
316
|
-
C$1 = r$3.createTreeWalker(r$3, 129, null, !1);
|
|
317
|
-
function P$1(t, i) {
|
|
318
|
-
if (!Array.isArray(t) || !t.hasOwnProperty("raw")) throw Error("invalid template strings array");
|
|
319
|
-
return void 0 !== e$3 ? e$3.createHTML(i) : i;
|
|
320
|
-
}
|
|
321
|
-
const V$1 = (t, i) => {
|
|
322
|
-
const s = t.length - 1,
|
|
323
|
-
e = [];
|
|
324
|
-
let l,
|
|
325
|
-
r = 2 === i ? "<svg>" : "",
|
|
326
|
-
u = f$1;
|
|
327
|
-
for (let i = 0; i < s; i++) {
|
|
328
|
-
const s = t[i];
|
|
329
|
-
let d,
|
|
330
|
-
c,
|
|
331
|
-
v = -1,
|
|
332
|
-
a = 0;
|
|
333
|
-
for (; a < s.length && (u.lastIndex = a, c = u.exec(s), null !== c);) a = u.lastIndex, u === f$1 ? "!--" === c[1] ? u = _$1 : void 0 !== c[1] ? u = m$1 : void 0 !== c[2] ? (y$1.test(c[2]) && (l = RegExp("</" + c[2], "g")), u = p$1) : void 0 !== c[3] && (u = p$1) : u === p$1 ? ">" === c[0] ? (u = null != l ? l : f$1, v = -1) : void 0 === c[1] ? v = -2 : (v = u.lastIndex - c[2].length, d = c[1], u = void 0 === c[3] ? p$1 : '"' === c[3] ? $$1 : g$1) : u === $$1 || u === g$1 ? u = p$1 : u === _$1 || u === m$1 ? u = f$1 : (u = p$1, l = void 0);
|
|
334
|
-
const w = u === p$1 && t[i + 1].startsWith("/>") ? " " : "";
|
|
335
|
-
r += u === f$1 ? s + h$2 : v >= 0 ? (e.push(d), s.slice(0, v) + o$4 + s.slice(v) + n$4 + w) : s + n$4 + (-2 === v ? (e.push(void 0), i) : w);
|
|
336
|
-
}
|
|
337
|
-
return [P$1(t, r + (t[s] || "<?>") + (2 === i ? "</svg>" : "")), e];
|
|
338
|
-
};
|
|
339
|
-
let N$1 = class N {
|
|
340
|
-
constructor({
|
|
341
|
-
strings: t,
|
|
342
|
-
_$litType$: i
|
|
343
|
-
}, e) {
|
|
344
|
-
let h;
|
|
345
|
-
this.parts = [];
|
|
346
|
-
let r = 0,
|
|
347
|
-
d = 0;
|
|
348
|
-
const c = t.length - 1,
|
|
349
|
-
v = this.parts,
|
|
350
|
-
[a, f] = V$1(t, i);
|
|
351
|
-
if (this.el = N.createElement(a, e), C$1.currentNode = this.el.content, 2 === i) {
|
|
352
|
-
const t = this.el.content,
|
|
353
|
-
i = t.firstChild;
|
|
354
|
-
i.remove(), t.append(...i.childNodes);
|
|
165
|
+
s = [...h$1(t), ...o$2(t)];
|
|
166
|
+
for (const i of s) this.createProperty(i, t[i]);
|
|
355
167
|
}
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
for (const i of h.getAttributeNames()) if (i.endsWith(o$4) || i.startsWith(n$4)) {
|
|
361
|
-
const s = f[d++];
|
|
362
|
-
if (t.push(i), void 0 !== s) {
|
|
363
|
-
const t = h.getAttribute(s.toLowerCase() + o$4).split(n$4),
|
|
364
|
-
i = /([.?@])?(.*)/.exec(s);
|
|
365
|
-
v.push({
|
|
366
|
-
type: 1,
|
|
367
|
-
index: r,
|
|
368
|
-
name: i[2],
|
|
369
|
-
strings: t,
|
|
370
|
-
ctor: "." === i[1] ? H$1 : "?" === i[1] ? L$1 : "@" === i[1] ? z$1 : k$1
|
|
371
|
-
});
|
|
372
|
-
} else v.push({
|
|
373
|
-
type: 6,
|
|
374
|
-
index: r
|
|
375
|
-
});
|
|
376
|
-
}
|
|
377
|
-
for (const i of t) h.removeAttribute(i);
|
|
378
|
-
}
|
|
379
|
-
if (y$1.test(h.tagName)) {
|
|
380
|
-
const t = h.textContent.split(n$4),
|
|
381
|
-
i = t.length - 1;
|
|
382
|
-
if (i > 0) {
|
|
383
|
-
h.textContent = s$4 ? s$4.emptyScript : "";
|
|
384
|
-
for (let s = 0; s < i; s++) h.append(t[s], u$1()), C$1.nextNode(), v.push({
|
|
385
|
-
type: 2,
|
|
386
|
-
index: ++r
|
|
387
|
-
});
|
|
388
|
-
h.append(t[i], u$1());
|
|
389
|
-
}
|
|
390
|
-
}
|
|
391
|
-
} else if (8 === h.nodeType) if (h.data === l$4) v.push({
|
|
392
|
-
type: 2,
|
|
393
|
-
index: r
|
|
394
|
-
});else {
|
|
395
|
-
let t = -1;
|
|
396
|
-
for (; -1 !== (t = h.data.indexOf(n$4, t + 1));) v.push({
|
|
397
|
-
type: 7,
|
|
398
|
-
index: r
|
|
399
|
-
}), t += n$4.length - 1;
|
|
400
|
-
}
|
|
401
|
-
r++;
|
|
402
|
-
}
|
|
403
|
-
}
|
|
404
|
-
static createElement(t, i) {
|
|
405
|
-
const s = r$3.createElement("template");
|
|
406
|
-
return s.innerHTML = t, s;
|
|
407
|
-
}
|
|
408
|
-
};
|
|
409
|
-
function S$2(t, i, s = t, e) {
|
|
410
|
-
var o, n, l, h;
|
|
411
|
-
if (i === T$1) return i;
|
|
412
|
-
let r = void 0 !== e ? null === (o = s._$Co) || void 0 === o ? void 0 : o[e] : s._$Cl;
|
|
413
|
-
const u = d$1(i) ? void 0 : i._$litDirective$;
|
|
414
|
-
return (null == r ? void 0 : r.constructor) !== u && (null === (n = null == r ? void 0 : r._$AO) || void 0 === n || n.call(r, !1), void 0 === u ? r = void 0 : (r = new u(t), r._$AT(t, s, e)), void 0 !== e ? (null !== (l = (h = s)._$Co) && void 0 !== l ? l : h._$Co = [])[e] = r : s._$Cl = r), void 0 !== r && (i = S$2(t, r._$AS(t, i.values), r, e)), i;
|
|
415
|
-
}
|
|
416
|
-
let M$1 = class M {
|
|
417
|
-
constructor(t, i) {
|
|
418
|
-
this._$AV = [], this._$AN = void 0, this._$AD = t, this._$AM = i;
|
|
419
|
-
}
|
|
420
|
-
get parentNode() {
|
|
421
|
-
return this._$AM.parentNode;
|
|
422
|
-
}
|
|
423
|
-
get _$AU() {
|
|
424
|
-
return this._$AM._$AU;
|
|
425
|
-
}
|
|
426
|
-
u(t) {
|
|
427
|
-
var i;
|
|
428
|
-
const {
|
|
429
|
-
el: {
|
|
430
|
-
content: s
|
|
431
|
-
},
|
|
432
|
-
parts: e
|
|
433
|
-
} = this._$AD,
|
|
434
|
-
o = (null !== (i = null == t ? void 0 : t.creationScope) && void 0 !== i ? i : r$3).importNode(s, !0);
|
|
435
|
-
C$1.currentNode = o;
|
|
436
|
-
let n = C$1.nextNode(),
|
|
437
|
-
l = 0,
|
|
438
|
-
h = 0,
|
|
439
|
-
u = e[0];
|
|
440
|
-
for (; void 0 !== u;) {
|
|
441
|
-
if (l === u.index) {
|
|
442
|
-
let i;
|
|
443
|
-
2 === u.type ? i = new R$1(n, n.nextSibling, this, t) : 1 === u.type ? i = new u.ctor(n, u.name, u.strings, this, t) : 6 === u.type && (i = new Z(n, this, t)), this._$AV.push(i), u = e[++h];
|
|
444
|
-
}
|
|
445
|
-
l !== (null == u ? void 0 : u.index) && (n = C$1.nextNode(), l++);
|
|
446
|
-
}
|
|
447
|
-
return C$1.currentNode = r$3, o;
|
|
448
|
-
}
|
|
449
|
-
v(t) {
|
|
450
|
-
let i = 0;
|
|
451
|
-
for (const s of this._$AV) void 0 !== s && (void 0 !== s.strings ? (s._$AI(t, s, i), i += s.strings.length - 2) : s._$AI(t[i])), i++;
|
|
452
|
-
}
|
|
453
|
-
};
|
|
454
|
-
let R$1 = class R {
|
|
455
|
-
constructor(t, i, s, e) {
|
|
456
|
-
var o;
|
|
457
|
-
this.type = 2, this._$AH = A$1, this._$AN = void 0, this._$AA = t, this._$AB = i, this._$AM = s, this.options = e, this._$Cp = null === (o = null == e ? void 0 : e.isConnected) || void 0 === o || o;
|
|
458
|
-
}
|
|
459
|
-
get _$AU() {
|
|
460
|
-
var t, i;
|
|
461
|
-
return null !== (i = null === (t = this._$AM) || void 0 === t ? void 0 : t._$AU) && void 0 !== i ? i : this._$Cp;
|
|
462
|
-
}
|
|
463
|
-
get parentNode() {
|
|
464
|
-
let t = this._$AA.parentNode;
|
|
465
|
-
const i = this._$AM;
|
|
466
|
-
return void 0 !== i && 11 === (null == t ? void 0 : t.nodeType) && (t = i.parentNode), t;
|
|
467
|
-
}
|
|
468
|
-
get startNode() {
|
|
469
|
-
return this._$AA;
|
|
470
|
-
}
|
|
471
|
-
get endNode() {
|
|
472
|
-
return this._$AB;
|
|
473
|
-
}
|
|
474
|
-
_$AI(t, i = this) {
|
|
475
|
-
t = S$2(this, t, i), d$1(t) ? t === A$1 || null == t || "" === t ? (this._$AH !== A$1 && this._$AR(), this._$AH = A$1) : t !== this._$AH && t !== T$1 && this._(t) : void 0 !== t._$litType$ ? this.g(t) : void 0 !== t.nodeType ? this.$(t) : v$1(t) ? this.T(t) : this._(t);
|
|
476
|
-
}
|
|
477
|
-
k(t) {
|
|
478
|
-
return this._$AA.parentNode.insertBefore(t, this._$AB);
|
|
479
|
-
}
|
|
480
|
-
$(t) {
|
|
481
|
-
this._$AH !== t && (this._$AR(), this._$AH = this.k(t));
|
|
482
|
-
}
|
|
483
|
-
_(t) {
|
|
484
|
-
this._$AH !== A$1 && d$1(this._$AH) ? this._$AA.nextSibling.data = t : this.$(r$3.createTextNode(t)), this._$AH = t;
|
|
485
|
-
}
|
|
486
|
-
g(t) {
|
|
487
|
-
var i;
|
|
488
|
-
const {
|
|
489
|
-
values: s,
|
|
490
|
-
_$litType$: e
|
|
491
|
-
} = t,
|
|
492
|
-
o = "number" == typeof e ? this._$AC(t) : (void 0 === e.el && (e.el = N$1.createElement(P$1(e.h, e.h[0]), this.options)), e);
|
|
493
|
-
if ((null === (i = this._$AH) || void 0 === i ? void 0 : i._$AD) === o) this._$AH.v(s);else {
|
|
494
|
-
const t = new M$1(o, this),
|
|
495
|
-
i = t.u(this.options);
|
|
496
|
-
t.v(s), this.$(i), this._$AH = t;
|
|
168
|
+
const t = this[Symbol.metadata];
|
|
169
|
+
if (null !== t) {
|
|
170
|
+
const s = litPropertyMetadata.get(t);
|
|
171
|
+
if (void 0 !== s) for (const [t, i] of s) this.elementProperties.set(t, i);
|
|
497
172
|
}
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
}
|
|
503
|
-
T(t) {
|
|
504
|
-
c$1(this._$AH) || (this._$AH = [], this._$AR());
|
|
505
|
-
const i = this._$AH;
|
|
506
|
-
let s,
|
|
507
|
-
e = 0;
|
|
508
|
-
for (const o of t) e === i.length ? i.push(s = new R(this.k(u$1()), this.k(u$1()), this, this.options)) : s = i[e], s._$AI(o), e++;
|
|
509
|
-
e < i.length && (this._$AR(s && s._$AB.nextSibling, e), i.length = e);
|
|
510
|
-
}
|
|
511
|
-
_$AR(t = this._$AA.nextSibling, i) {
|
|
512
|
-
var s;
|
|
513
|
-
for (null === (s = this._$AP) || void 0 === s || s.call(this, !1, !0, i); t && t !== this._$AB;) {
|
|
514
|
-
const i = t.nextSibling;
|
|
515
|
-
t.remove(), t = i;
|
|
173
|
+
this._$Eh = new Map();
|
|
174
|
+
for (const [t, s] of this.elementProperties) {
|
|
175
|
+
const i = this._$Eu(t, s);
|
|
176
|
+
void 0 !== i && this._$Eh.set(i, t);
|
|
516
177
|
}
|
|
178
|
+
this.elementStyles = this.finalizeStyles(this.styles);
|
|
517
179
|
}
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
this.type = 1, this._$AH = A$1, this._$AN = void 0, this.element = t, this.name = i, this._$AM = e, this.options = o, s.length > 2 || "" !== s[0] || "" !== s[1] ? (this._$AH = Array(s.length - 1).fill(new String()), this.strings = s) : this._$AH = A$1;
|
|
526
|
-
}
|
|
527
|
-
get tagName() {
|
|
528
|
-
return this.element.tagName;
|
|
529
|
-
}
|
|
530
|
-
get _$AU() {
|
|
531
|
-
return this._$AM._$AU;
|
|
532
|
-
}
|
|
533
|
-
_$AI(t, i = this, s, e) {
|
|
534
|
-
const o = this.strings;
|
|
535
|
-
let n = !1;
|
|
536
|
-
if (void 0 === o) t = S$2(this, t, i, 0), n = !d$1(t) || t !== this._$AH && t !== T$1, n && (this._$AH = t);else {
|
|
537
|
-
const e = t;
|
|
538
|
-
let l, h;
|
|
539
|
-
for (t = o[0], l = 0; l < o.length - 1; l++) h = S$2(this, e[s + l], i, l), h === T$1 && (h = this._$AH[l]), n || (n = !d$1(h) || h !== this._$AH[l]), h === A$1 ? t = A$1 : t !== A$1 && (t += (null != h ? h : "") + o[l + 1]), this._$AH[l] = h;
|
|
540
|
-
}
|
|
541
|
-
n && !e && this.j(t);
|
|
180
|
+
static finalizeStyles(s) {
|
|
181
|
+
const i = [];
|
|
182
|
+
if (Array.isArray(s)) {
|
|
183
|
+
const e = new Set(s.flat(1 / 0).reverse());
|
|
184
|
+
for (const s of e) i.unshift(c$2(s));
|
|
185
|
+
} else void 0 !== s && i.push(c$2(s));
|
|
186
|
+
return i;
|
|
542
187
|
}
|
|
543
|
-
|
|
544
|
-
|
|
188
|
+
static _$Eu(t, s) {
|
|
189
|
+
const i = s.attribute;
|
|
190
|
+
return !1 === i ? void 0 : "string" == typeof i ? i : "string" == typeof t ? t.toLowerCase() : void 0;
|
|
545
191
|
}
|
|
546
|
-
};
|
|
547
|
-
let H$1 = class H extends k$1 {
|
|
548
192
|
constructor() {
|
|
549
|
-
super(
|
|
550
|
-
}
|
|
551
|
-
j(t) {
|
|
552
|
-
this.element[this.name] = t === A$1 ? void 0 : t;
|
|
193
|
+
super(), this._$Ep = void 0, this.isUpdatePending = !1, this.hasUpdated = !1, this._$Em = null, this._$Ev();
|
|
553
194
|
}
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
let L$1 = class L extends k$1 {
|
|
557
|
-
constructor() {
|
|
558
|
-
super(...arguments), this.type = 4;
|
|
559
|
-
}
|
|
560
|
-
j(t) {
|
|
561
|
-
t && t !== A$1 ? this.element.setAttribute(this.name, I$1) : this.element.removeAttribute(this.name);
|
|
562
|
-
}
|
|
563
|
-
};
|
|
564
|
-
let z$1 = class z extends k$1 {
|
|
565
|
-
constructor(t, i, s, e, o) {
|
|
566
|
-
super(t, i, s, e, o), this.type = 5;
|
|
567
|
-
}
|
|
568
|
-
_$AI(t, i = this) {
|
|
569
|
-
var s;
|
|
570
|
-
if ((t = null !== (s = S$2(this, t, i, 0)) && void 0 !== s ? s : A$1) === T$1) return;
|
|
571
|
-
const e = this._$AH,
|
|
572
|
-
o = t === A$1 && e !== A$1 || t.capture !== e.capture || t.once !== e.once || t.passive !== e.passive,
|
|
573
|
-
n = t !== A$1 && (e === A$1 || o);
|
|
574
|
-
o && this.element.removeEventListener(this.name, this, e), n && this.element.addEventListener(this.name, this, t), this._$AH = t;
|
|
575
|
-
}
|
|
576
|
-
handleEvent(t) {
|
|
577
|
-
var i, s;
|
|
578
|
-
"function" == typeof this._$AH ? this._$AH.call(null !== (s = null === (i = this.options) || void 0 === i ? void 0 : i.host) && void 0 !== s ? s : this.element, t) : this._$AH.handleEvent(t);
|
|
579
|
-
}
|
|
580
|
-
};
|
|
581
|
-
class Z {
|
|
582
|
-
constructor(t, i, s) {
|
|
583
|
-
this.element = t, this.type = 6, this._$AN = void 0, this._$AM = i, this.options = s;
|
|
584
|
-
}
|
|
585
|
-
get _$AU() {
|
|
586
|
-
return this._$AM._$AU;
|
|
587
|
-
}
|
|
588
|
-
_$AI(t) {
|
|
589
|
-
S$2(this, t);
|
|
590
|
-
}
|
|
591
|
-
}
|
|
592
|
-
const B$1 = i$2.litHtmlPolyfillSupport;
|
|
593
|
-
null == B$1 || B$1(N$1, R$1), (null !== (t$2 = i$2.litHtmlVersions) && void 0 !== t$2 ? t$2 : i$2.litHtmlVersions = []).push("2.8.0");
|
|
594
|
-
|
|
595
|
-
/**
|
|
596
|
-
* @license
|
|
597
|
-
* Copyright 2019 Google LLC
|
|
598
|
-
* SPDX-License-Identifier: BSD-3-Clause
|
|
599
|
-
*/
|
|
600
|
-
const t$1 = window.ShadowRoot && (void 0 === window.ShadyCSS || window.ShadyCSS.nativeShadow) && "adoptedStyleSheets" in Document.prototype && "replace" in CSSStyleSheet.prototype,
|
|
601
|
-
e$2 = Symbol(),
|
|
602
|
-
n$3 = new Map();
|
|
603
|
-
let s$3 = class s {
|
|
604
|
-
constructor(t, n) {
|
|
605
|
-
if (this._$cssResult$ = !0, n !== e$2) throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");
|
|
606
|
-
this.cssText = t;
|
|
607
|
-
}
|
|
608
|
-
get styleSheet() {
|
|
609
|
-
let e = n$3.get(this.cssText);
|
|
610
|
-
return t$1 && void 0 === e && (n$3.set(this.cssText, e = new CSSStyleSheet()), e.replaceSync(this.cssText)), e;
|
|
611
|
-
}
|
|
612
|
-
toString() {
|
|
613
|
-
return this.cssText;
|
|
614
|
-
}
|
|
615
|
-
};
|
|
616
|
-
const o$3 = t => new s$3("string" == typeof t ? t : t + "", e$2),
|
|
617
|
-
r$2 = (t, ...n) => {
|
|
618
|
-
const o = 1 === t.length ? t[0] : n.reduce((e, n, s) => e + (t => {
|
|
619
|
-
if (!0 === t._$cssResult$) return t.cssText;
|
|
620
|
-
if ("number" == typeof t) return t;
|
|
621
|
-
throw Error("Value passed to 'css' function must be a 'css' function result: " + t + ". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.");
|
|
622
|
-
})(n) + t[s + 1], t[0]);
|
|
623
|
-
return new s$3(o, e$2);
|
|
624
|
-
},
|
|
625
|
-
i$1 = (e, n) => {
|
|
626
|
-
t$1 ? e.adoptedStyleSheets = n.map(t => t instanceof CSSStyleSheet ? t : t.styleSheet) : n.forEach(t => {
|
|
627
|
-
const n = document.createElement("style"),
|
|
628
|
-
s = window.litNonce;
|
|
629
|
-
void 0 !== s && n.setAttribute("nonce", s), n.textContent = t.cssText, e.appendChild(n);
|
|
630
|
-
});
|
|
631
|
-
},
|
|
632
|
-
S$1 = t$1 ? t => t : t => t instanceof CSSStyleSheet ? (t => {
|
|
633
|
-
let e = "";
|
|
634
|
-
for (const n of t.cssRules) e += n.cssText;
|
|
635
|
-
return o$3(e);
|
|
636
|
-
})(t) : t;
|
|
637
|
-
|
|
638
|
-
/**
|
|
639
|
-
* @license
|
|
640
|
-
* Copyright 2017 Google LLC
|
|
641
|
-
* SPDX-License-Identifier: BSD-3-Clause
|
|
642
|
-
*/
|
|
643
|
-
var s$2;
|
|
644
|
-
const e$1 = window.trustedTypes,
|
|
645
|
-
r$1 = e$1 ? e$1.emptyScript : "",
|
|
646
|
-
h$1 = window.reactiveElementPolyfillSupport,
|
|
647
|
-
o$2 = {
|
|
648
|
-
toAttribute(t, i) {
|
|
649
|
-
switch (i) {
|
|
650
|
-
case Boolean:
|
|
651
|
-
t = t ? r$1 : null;
|
|
652
|
-
break;
|
|
653
|
-
case Object:
|
|
654
|
-
case Array:
|
|
655
|
-
t = null == t ? t : JSON.stringify(t);
|
|
656
|
-
}
|
|
657
|
-
return t;
|
|
658
|
-
},
|
|
659
|
-
fromAttribute(t, i) {
|
|
660
|
-
let s = t;
|
|
661
|
-
switch (i) {
|
|
662
|
-
case Boolean:
|
|
663
|
-
s = null !== t;
|
|
664
|
-
break;
|
|
665
|
-
case Number:
|
|
666
|
-
s = null === t ? null : Number(t);
|
|
667
|
-
break;
|
|
668
|
-
case Object:
|
|
669
|
-
case Array:
|
|
670
|
-
try {
|
|
671
|
-
s = JSON.parse(t);
|
|
672
|
-
} catch (t) {
|
|
673
|
-
s = null;
|
|
674
|
-
}
|
|
675
|
-
}
|
|
676
|
-
return s;
|
|
677
|
-
}
|
|
678
|
-
},
|
|
679
|
-
n$2 = (t, i) => i !== t && (i == i || t == t),
|
|
680
|
-
l$3 = {
|
|
681
|
-
attribute: !0,
|
|
682
|
-
type: String,
|
|
683
|
-
converter: o$2,
|
|
684
|
-
reflect: !1,
|
|
685
|
-
hasChanged: n$2
|
|
686
|
-
};
|
|
687
|
-
let a$1 = class a extends HTMLElement {
|
|
688
|
-
constructor() {
|
|
689
|
-
super(), this._$Et = new Map(), this.isUpdatePending = !1, this.hasUpdated = !1, this._$Ei = null, this.o();
|
|
690
|
-
}
|
|
691
|
-
static addInitializer(t) {
|
|
692
|
-
var i;
|
|
693
|
-
null !== (i = this.l) && void 0 !== i || (this.l = []), this.l.push(t);
|
|
694
|
-
}
|
|
695
|
-
static get observedAttributes() {
|
|
696
|
-
this.finalize();
|
|
697
|
-
const t = [];
|
|
698
|
-
return this.elementProperties.forEach((i, s) => {
|
|
699
|
-
const e = this._$Eh(s, i);
|
|
700
|
-
void 0 !== e && (this._$Eu.set(e, s), t.push(e));
|
|
701
|
-
}), t;
|
|
702
|
-
}
|
|
703
|
-
static createProperty(t, i = l$3) {
|
|
704
|
-
if (i.state && (i.attribute = !1), this.finalize(), this.elementProperties.set(t, i), !i.noAccessor && !this.prototype.hasOwnProperty(t)) {
|
|
705
|
-
const s = "symbol" == typeof t ? Symbol() : "__" + t,
|
|
706
|
-
e = this.getPropertyDescriptor(t, s, i);
|
|
707
|
-
void 0 !== e && Object.defineProperty(this.prototype, t, e);
|
|
708
|
-
}
|
|
709
|
-
}
|
|
710
|
-
static getPropertyDescriptor(t, i, s) {
|
|
711
|
-
return {
|
|
712
|
-
get() {
|
|
713
|
-
return this[i];
|
|
714
|
-
},
|
|
715
|
-
set(e) {
|
|
716
|
-
const r = this[t];
|
|
717
|
-
this[i] = e, this.requestUpdate(t, r, s);
|
|
718
|
-
},
|
|
719
|
-
configurable: !0,
|
|
720
|
-
enumerable: !0
|
|
721
|
-
};
|
|
722
|
-
}
|
|
723
|
-
static getPropertyOptions(t) {
|
|
724
|
-
return this.elementProperties.get(t) || l$3;
|
|
725
|
-
}
|
|
726
|
-
static finalize() {
|
|
727
|
-
if (this.hasOwnProperty("finalized")) return !1;
|
|
728
|
-
this.finalized = !0;
|
|
729
|
-
const t = Object.getPrototypeOf(this);
|
|
730
|
-
if (t.finalize(), this.elementProperties = new Map(t.elementProperties), this._$Eu = new Map(), this.hasOwnProperty("properties")) {
|
|
731
|
-
const t = this.properties,
|
|
732
|
-
i = [...Object.getOwnPropertyNames(t), ...Object.getOwnPropertySymbols(t)];
|
|
733
|
-
for (const s of i) this.createProperty(s, t[s]);
|
|
734
|
-
}
|
|
735
|
-
return this.elementStyles = this.finalizeStyles(this.styles), !0;
|
|
736
|
-
}
|
|
737
|
-
static finalizeStyles(i) {
|
|
738
|
-
const s = [];
|
|
739
|
-
if (Array.isArray(i)) {
|
|
740
|
-
const e = new Set(i.flat(1 / 0).reverse());
|
|
741
|
-
for (const i of e) s.unshift(S$1(i));
|
|
742
|
-
} else void 0 !== i && s.push(S$1(i));
|
|
743
|
-
return s;
|
|
744
|
-
}
|
|
745
|
-
static _$Eh(t, i) {
|
|
746
|
-
const s = i.attribute;
|
|
747
|
-
return !1 === s ? void 0 : "string" == typeof s ? s : "string" == typeof t ? t.toLowerCase() : void 0;
|
|
748
|
-
}
|
|
749
|
-
o() {
|
|
750
|
-
var t;
|
|
751
|
-
this._$Ep = new Promise(t => this.enableUpdating = t), this._$AL = new Map(), this._$Em(), this.requestUpdate(), null === (t = this.constructor.l) || void 0 === t || t.forEach(t => t(this));
|
|
195
|
+
_$Ev() {
|
|
196
|
+
this._$Eg = new Promise(t => this.enableUpdating = t), this._$AL = new Map(), this._$ES(), this.requestUpdate(), this.constructor.l?.forEach(t => t(this));
|
|
752
197
|
}
|
|
753
198
|
addController(t) {
|
|
754
|
-
|
|
755
|
-
(null !== (i = this._$Eg) && void 0 !== i ? i : this._$Eg = []).push(t), void 0 !== this.renderRoot && this.isConnected && (null === (s = t.hostConnected) || void 0 === s || s.call(t));
|
|
199
|
+
(this._$E_ ??= new Set()).add(t), void 0 !== this.renderRoot && this.isConnected && t.hostConnected?.();
|
|
756
200
|
}
|
|
757
201
|
removeController(t) {
|
|
758
|
-
|
|
759
|
-
null === (i = this._$Eg) || void 0 === i || i.splice(this._$Eg.indexOf(t) >>> 0, 1);
|
|
202
|
+
this._$E_?.delete(t);
|
|
760
203
|
}
|
|
761
|
-
_$
|
|
762
|
-
|
|
763
|
-
|
|
764
|
-
|
|
204
|
+
_$ES() {
|
|
205
|
+
const t = new Map(),
|
|
206
|
+
s = this.constructor.elementProperties;
|
|
207
|
+
for (const i of s.keys()) this.hasOwnProperty(i) && (t.set(i, this[i]), delete this[i]);
|
|
208
|
+
t.size > 0 && (this._$Ep = t);
|
|
765
209
|
}
|
|
766
210
|
createRenderRoot() {
|
|
767
|
-
|
|
768
|
-
|
|
769
|
-
return i$1(s, this.constructor.elementStyles), s;
|
|
211
|
+
const t = this.shadowRoot ?? this.attachShadow(this.constructor.shadowRootOptions);
|
|
212
|
+
return S$1(t, this.constructor.elementStyles), t;
|
|
770
213
|
}
|
|
771
214
|
connectedCallback() {
|
|
772
|
-
|
|
773
|
-
void 0 === this.renderRoot && (this.renderRoot = this.createRenderRoot()), this.enableUpdating(!0), null === (t = this._$Eg) || void 0 === t || t.forEach(t => {
|
|
774
|
-
var i;
|
|
775
|
-
return null === (i = t.hostConnected) || void 0 === i ? void 0 : i.call(t);
|
|
776
|
-
});
|
|
215
|
+
this.renderRoot ??= this.createRenderRoot(), this.enableUpdating(!0), this._$E_?.forEach(t => t.hostConnected?.());
|
|
777
216
|
}
|
|
778
217
|
enableUpdating(t) {}
|
|
779
218
|
disconnectedCallback() {
|
|
780
|
-
|
|
781
|
-
null === (t = this._$Eg) || void 0 === t || t.forEach(t => {
|
|
782
|
-
var i;
|
|
783
|
-
return null === (i = t.hostDisconnected) || void 0 === i ? void 0 : i.call(t);
|
|
784
|
-
});
|
|
219
|
+
this._$E_?.forEach(t => t.hostDisconnected?.());
|
|
785
220
|
}
|
|
786
|
-
attributeChangedCallback(t,
|
|
787
|
-
this._$AK(t,
|
|
221
|
+
attributeChangedCallback(t, s, i) {
|
|
222
|
+
this._$AK(t, i);
|
|
788
223
|
}
|
|
789
|
-
_$
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
if (void 0 !==
|
|
793
|
-
const
|
|
794
|
-
this._$
|
|
224
|
+
_$EO(t, s) {
|
|
225
|
+
const i = this.constructor.elementProperties.get(t),
|
|
226
|
+
e = this.constructor._$Eu(t, i);
|
|
227
|
+
if (void 0 !== e && !0 === i.reflect) {
|
|
228
|
+
const r = (void 0 !== i.converter?.toAttribute ? i.converter : u$1).toAttribute(s, i.type);
|
|
229
|
+
this._$Em = t, null == r ? this.removeAttribute(e) : this.setAttribute(e, r), this._$Em = null;
|
|
230
|
+
}
|
|
231
|
+
}
|
|
232
|
+
_$AK(t, s) {
|
|
233
|
+
const i = this.constructor,
|
|
234
|
+
e = i._$Eh.get(t);
|
|
235
|
+
if (void 0 !== e && this._$Em !== e) {
|
|
236
|
+
const t = i.getPropertyOptions(e),
|
|
237
|
+
r = "function" == typeof t.converter ? {
|
|
238
|
+
fromAttribute: t.converter
|
|
239
|
+
} : void 0 !== t.converter?.fromAttribute ? t.converter : u$1;
|
|
240
|
+
this._$Em = e, this[e] = r.fromAttribute(s, t.type), this._$Em = null;
|
|
795
241
|
}
|
|
796
242
|
}
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
if (void 0 !== n && this._$Ei !== n) {
|
|
802
|
-
const t = h.getPropertyOptions(n),
|
|
803
|
-
l = t.converter,
|
|
804
|
-
a = null !== (r = null !== (e = null === (s = l) || void 0 === s ? void 0 : s.fromAttribute) && void 0 !== e ? e : "function" == typeof l ? l : null) && void 0 !== r ? r : o$2.fromAttribute;
|
|
805
|
-
this._$Ei = n, this[n] = a(i, t.type), this._$Ei = null;
|
|
243
|
+
requestUpdate(t, s, i, e = !1, r) {
|
|
244
|
+
if (void 0 !== t) {
|
|
245
|
+
if (i ??= this.constructor.getPropertyOptions(t), !(i.hasChanged ?? f$1)(e ? r : this[t], s)) return;
|
|
246
|
+
this.C(t, s, i);
|
|
806
247
|
}
|
|
248
|
+
!1 === this.isUpdatePending && (this._$Eg = this._$EP());
|
|
807
249
|
}
|
|
808
|
-
|
|
809
|
-
|
|
810
|
-
void 0 !== t && (((s = s || this.constructor.getPropertyOptions(t)).hasChanged || n$2)(this[t], i) ? (this._$AL.has(t) || this._$AL.set(t, i), !0 === s.reflect && this._$Ei !== t && (void 0 === this._$EC && (this._$EC = new Map()), this._$EC.set(t, s))) : e = !1), !this.isUpdatePending && e && (this._$Ep = this._$E_());
|
|
250
|
+
C(t, s, i) {
|
|
251
|
+
this._$AL.has(t) || this._$AL.set(t, s), !0 === i.reflect && this._$Em !== t && (this._$Ej ??= new Set()).add(t);
|
|
811
252
|
}
|
|
812
|
-
async _$
|
|
253
|
+
async _$EP() {
|
|
813
254
|
this.isUpdatePending = !0;
|
|
814
255
|
try {
|
|
815
|
-
await this._$
|
|
256
|
+
await this._$Eg;
|
|
816
257
|
} catch (t) {
|
|
817
258
|
Promise.reject(t);
|
|
818
259
|
}
|
|
@@ -823,192 +264,184 @@
|
|
|
823
264
|
return this.performUpdate();
|
|
824
265
|
}
|
|
825
266
|
performUpdate() {
|
|
826
|
-
var t;
|
|
827
267
|
if (!this.isUpdatePending) return;
|
|
828
|
-
|
|
829
|
-
|
|
268
|
+
if (!this.hasUpdated) {
|
|
269
|
+
if (this.renderRoot ??= this.createRenderRoot(), this._$Ep) {
|
|
270
|
+
for (const [t, s] of this._$Ep) this[t] = s;
|
|
271
|
+
this._$Ep = void 0;
|
|
272
|
+
}
|
|
273
|
+
const t = this.constructor.elementProperties;
|
|
274
|
+
if (t.size > 0) for (const [s, i] of t) !0 !== i.wrapped || this._$AL.has(s) || void 0 === this[s] || this.C(s, this[s], i);
|
|
275
|
+
}
|
|
276
|
+
let t = !1;
|
|
830
277
|
const s = this._$AL;
|
|
831
278
|
try {
|
|
832
|
-
|
|
833
|
-
|
|
834
|
-
|
|
835
|
-
}), this.update(s)) : this._$EU();
|
|
836
|
-
} catch (t) {
|
|
837
|
-
throw i = !1, this._$EU(), t;
|
|
279
|
+
t = this.shouldUpdate(s), t ? (this.willUpdate(s), this._$E_?.forEach(t => t.hostUpdate?.()), this.update(s)) : this._$ET();
|
|
280
|
+
} catch (s) {
|
|
281
|
+
throw t = !1, this._$ET(), s;
|
|
838
282
|
}
|
|
839
|
-
|
|
283
|
+
t && this._$AE(s);
|
|
840
284
|
}
|
|
841
285
|
willUpdate(t) {}
|
|
842
286
|
_$AE(t) {
|
|
843
|
-
|
|
844
|
-
null === (i = this._$Eg) || void 0 === i || i.forEach(t => {
|
|
845
|
-
var i;
|
|
846
|
-
return null === (i = t.hostUpdated) || void 0 === i ? void 0 : i.call(t);
|
|
847
|
-
}), this.hasUpdated || (this.hasUpdated = !0, this.firstUpdated(t)), this.updated(t);
|
|
287
|
+
this._$E_?.forEach(t => t.hostUpdated?.()), this.hasUpdated || (this.hasUpdated = !0, this.firstUpdated(t)), this.updated(t);
|
|
848
288
|
}
|
|
849
|
-
_$
|
|
289
|
+
_$ET() {
|
|
850
290
|
this._$AL = new Map(), this.isUpdatePending = !1;
|
|
851
291
|
}
|
|
852
292
|
get updateComplete() {
|
|
853
293
|
return this.getUpdateComplete();
|
|
854
294
|
}
|
|
855
295
|
getUpdateComplete() {
|
|
856
|
-
return this._$
|
|
296
|
+
return this._$Eg;
|
|
857
297
|
}
|
|
858
298
|
shouldUpdate(t) {
|
|
859
299
|
return !0;
|
|
860
300
|
}
|
|
861
301
|
update(t) {
|
|
862
|
-
|
|
302
|
+
this._$Ej &&= this._$Ej.forEach(t => this._$EO(t, this[t])), this._$ET();
|
|
863
303
|
}
|
|
864
304
|
updated(t) {}
|
|
865
305
|
firstUpdated(t) {}
|
|
866
306
|
};
|
|
867
|
-
|
|
307
|
+
b$1.elementStyles = [], b$1.shadowRootOptions = {
|
|
868
308
|
mode: "open"
|
|
869
|
-
},
|
|
870
|
-
ReactiveElement:
|
|
871
|
-
}), (
|
|
309
|
+
}, b$1[d$1("elementProperties")] = new Map(), b$1[d$1("finalized")] = new Map(), p$1?.({
|
|
310
|
+
ReactiveElement: b$1
|
|
311
|
+
}), (a$1.reactiveElementVersions ??= []).push("2.0.2");
|
|
872
312
|
|
|
873
313
|
/**
|
|
874
314
|
* @license
|
|
875
315
|
* Copyright 2017 Google LLC
|
|
876
316
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
877
317
|
*/
|
|
878
|
-
|
|
879
|
-
|
|
880
|
-
s$1 = i.
|
|
881
|
-
e = s$1 ? s$1.createPolicy("lit-html", {
|
|
318
|
+
const t = globalThis,
|
|
319
|
+
i = t.trustedTypes,
|
|
320
|
+
s$1 = i ? i.createPolicy("lit-html", {
|
|
882
321
|
createHTML: t => t
|
|
883
322
|
}) : void 0,
|
|
884
|
-
|
|
885
|
-
|
|
886
|
-
|
|
887
|
-
|
|
888
|
-
r = document,
|
|
889
|
-
|
|
890
|
-
|
|
891
|
-
|
|
892
|
-
|
|
893
|
-
|
|
323
|
+
e = "$lit$",
|
|
324
|
+
h = `lit$${(Math.random() + "").slice(9)}$`,
|
|
325
|
+
o$1 = "?" + h,
|
|
326
|
+
n = `<${o$1}>`,
|
|
327
|
+
r$1 = document,
|
|
328
|
+
l = () => r$1.createComment(""),
|
|
329
|
+
c = t => null === t || "object" != typeof t && "function" != typeof t,
|
|
330
|
+
a = Array.isArray,
|
|
331
|
+
u = t => a(t) || "function" == typeof t?.[Symbol.iterator],
|
|
332
|
+
d = "[ \t\n\f\r]",
|
|
894
333
|
f = /<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,
|
|
895
|
-
|
|
896
|
-
|
|
897
|
-
|
|
898
|
-
|
|
899
|
-
|
|
900
|
-
|
|
901
|
-
|
|
334
|
+
v = /-->/g,
|
|
335
|
+
_ = />/g,
|
|
336
|
+
m = RegExp(`>|${d}(?:([^\\s"'>=/]+)(${d}*=${d}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`, "g"),
|
|
337
|
+
p = /'/g,
|
|
338
|
+
g = /"/g,
|
|
339
|
+
$ = /^(?:script|style|textarea|title)$/i,
|
|
340
|
+
y = t => (i, ...s) => ({
|
|
902
341
|
_$litType$: t,
|
|
903
342
|
strings: i,
|
|
904
343
|
values: s
|
|
905
344
|
}),
|
|
906
|
-
x =
|
|
907
|
-
b =
|
|
908
|
-
|
|
909
|
-
|
|
910
|
-
|
|
911
|
-
|
|
912
|
-
|
|
913
|
-
|
|
914
|
-
|
|
915
|
-
|
|
916
|
-
|
|
917
|
-
|
|
918
|
-
|
|
919
|
-
|
|
920
|
-
|
|
921
|
-
|
|
922
|
-
|
|
923
|
-
|
|
924
|
-
|
|
925
|
-
|
|
926
|
-
d
|
|
927
|
-
|
|
928
|
-
|
|
929
|
-
|
|
930
|
-
|
|
931
|
-
}
|
|
345
|
+
x = y(1),
|
|
346
|
+
b = y(2),
|
|
347
|
+
w = Symbol.for("lit-noChange"),
|
|
348
|
+
T = Symbol.for("lit-nothing"),
|
|
349
|
+
A = new WeakMap(),
|
|
350
|
+
E = r$1.createTreeWalker(r$1, 129);
|
|
351
|
+
function C(t, i) {
|
|
352
|
+
if (!Array.isArray(t) || !t.hasOwnProperty("raw")) throw Error("invalid template strings array");
|
|
353
|
+
return void 0 !== s$1 ? s$1.createHTML(i) : i;
|
|
354
|
+
}
|
|
355
|
+
const P = (t, i) => {
|
|
356
|
+
const s = t.length - 1,
|
|
357
|
+
o = [];
|
|
358
|
+
let r,
|
|
359
|
+
l = 2 === i ? "<svg>" : "",
|
|
360
|
+
c = f;
|
|
361
|
+
for (let i = 0; i < s; i++) {
|
|
362
|
+
const s = t[i];
|
|
363
|
+
let a,
|
|
364
|
+
u,
|
|
365
|
+
d = -1,
|
|
366
|
+
y = 0;
|
|
367
|
+
for (; y < s.length && (c.lastIndex = y, u = c.exec(s), null !== u);) y = c.lastIndex, c === f ? "!--" === u[1] ? c = v : void 0 !== u[1] ? c = _ : void 0 !== u[2] ? ($.test(u[2]) && (r = RegExp("</" + u[2], "g")), c = m) : void 0 !== u[3] && (c = m) : c === m ? ">" === u[0] ? (c = r ?? f, d = -1) : void 0 === u[1] ? d = -2 : (d = c.lastIndex - u[2].length, a = u[1], c = void 0 === u[3] ? m : '"' === u[3] ? g : p) : c === g || c === p ? c = m : c === v || c === _ ? c = f : (c = m, r = void 0);
|
|
368
|
+
const x = c === m && t[i + 1].startsWith("/>") ? " " : "";
|
|
369
|
+
l += c === f ? s + n : d >= 0 ? (o.push(a), s.slice(0, d) + e + s.slice(d) + h + x) : s + h + (-2 === d ? i : x);
|
|
370
|
+
}
|
|
371
|
+
return [C(t, l + (t[s] || "<?>") + (2 === i ? "</svg>" : "")), o];
|
|
372
|
+
};
|
|
932
373
|
class V {
|
|
933
374
|
constructor({
|
|
934
375
|
strings: t,
|
|
935
|
-
_$litType$:
|
|
936
|
-
},
|
|
937
|
-
let
|
|
376
|
+
_$litType$: s
|
|
377
|
+
}, n) {
|
|
378
|
+
let r;
|
|
938
379
|
this.parts = [];
|
|
939
|
-
let
|
|
940
|
-
|
|
941
|
-
const
|
|
942
|
-
|
|
943
|
-
[
|
|
944
|
-
if (this.el = V.createElement(
|
|
945
|
-
const t = this.el.content
|
|
946
|
-
|
|
947
|
-
i.remove(), t.append(...i.childNodes);
|
|
380
|
+
let c = 0,
|
|
381
|
+
a = 0;
|
|
382
|
+
const u = t.length - 1,
|
|
383
|
+
d = this.parts,
|
|
384
|
+
[f, v] = P(t, s);
|
|
385
|
+
if (this.el = V.createElement(f, n), E.currentNode = this.el.content, 2 === s) {
|
|
386
|
+
const t = this.el.content.firstChild;
|
|
387
|
+
t.replaceWith(...t.childNodes);
|
|
948
388
|
}
|
|
949
|
-
for (; null !== (
|
|
950
|
-
if (1 ===
|
|
951
|
-
if (
|
|
952
|
-
const
|
|
953
|
-
|
|
954
|
-
|
|
955
|
-
|
|
956
|
-
|
|
957
|
-
|
|
958
|
-
|
|
959
|
-
|
|
960
|
-
|
|
961
|
-
|
|
962
|
-
|
|
963
|
-
|
|
964
|
-
|
|
965
|
-
|
|
966
|
-
|
|
967
|
-
|
|
968
|
-
|
|
969
|
-
|
|
970
|
-
|
|
971
|
-
|
|
972
|
-
if (y.test(h.tagName)) {
|
|
973
|
-
const t = h.textContent.split(n$1),
|
|
974
|
-
i = t.length - 1;
|
|
975
|
-
if (i > 0) {
|
|
976
|
-
h.textContent = s$1 ? s$1.emptyScript : "";
|
|
977
|
-
for (let s = 0; s < i; s++) h.append(t[s], d()), C.nextNode(), v.push({
|
|
389
|
+
for (; null !== (r = E.nextNode()) && d.length < u;) {
|
|
390
|
+
if (1 === r.nodeType) {
|
|
391
|
+
if (r.hasAttributes()) for (const t of r.getAttributeNames()) if (t.endsWith(e)) {
|
|
392
|
+
const i = v[a++],
|
|
393
|
+
s = r.getAttribute(t).split(h),
|
|
394
|
+
e = /([.?@])?(.*)/.exec(i);
|
|
395
|
+
d.push({
|
|
396
|
+
type: 1,
|
|
397
|
+
index: c,
|
|
398
|
+
name: e[2],
|
|
399
|
+
strings: s,
|
|
400
|
+
ctor: "." === e[1] ? k : "?" === e[1] ? H : "@" === e[1] ? I : R
|
|
401
|
+
}), r.removeAttribute(t);
|
|
402
|
+
} else t.startsWith(h) && (d.push({
|
|
403
|
+
type: 6,
|
|
404
|
+
index: c
|
|
405
|
+
}), r.removeAttribute(t));
|
|
406
|
+
if ($.test(r.tagName)) {
|
|
407
|
+
const t = r.textContent.split(h),
|
|
408
|
+
s = t.length - 1;
|
|
409
|
+
if (s > 0) {
|
|
410
|
+
r.textContent = i ? i.emptyScript : "";
|
|
411
|
+
for (let i = 0; i < s; i++) r.append(t[i], l()), E.nextNode(), d.push({
|
|
978
412
|
type: 2,
|
|
979
|
-
index: ++
|
|
413
|
+
index: ++c
|
|
980
414
|
});
|
|
981
|
-
|
|
415
|
+
r.append(t[s], l());
|
|
982
416
|
}
|
|
983
417
|
}
|
|
984
|
-
} else if (8 ===
|
|
418
|
+
} else if (8 === r.nodeType) if (r.data === o$1) d.push({
|
|
985
419
|
type: 2,
|
|
986
|
-
index:
|
|
420
|
+
index: c
|
|
987
421
|
});else {
|
|
988
422
|
let t = -1;
|
|
989
|
-
for (; -1 !== (t =
|
|
423
|
+
for (; -1 !== (t = r.data.indexOf(h, t + 1));) d.push({
|
|
990
424
|
type: 7,
|
|
991
|
-
index:
|
|
992
|
-
}), t +=
|
|
425
|
+
index: c
|
|
426
|
+
}), t += h.length - 1;
|
|
993
427
|
}
|
|
994
|
-
|
|
428
|
+
c++;
|
|
995
429
|
}
|
|
996
430
|
}
|
|
997
431
|
static createElement(t, i) {
|
|
998
|
-
const s = r.createElement("template");
|
|
432
|
+
const s = r$1.createElement("template");
|
|
999
433
|
return s.innerHTML = t, s;
|
|
1000
434
|
}
|
|
1001
435
|
}
|
|
1002
436
|
function N(t, i, s = t, e) {
|
|
1003
|
-
|
|
1004
|
-
|
|
1005
|
-
|
|
1006
|
-
|
|
1007
|
-
return (null == r ? void 0 : r.constructor) !== d && (null === (n = null == r ? void 0 : r._$AO) || void 0 === n || n.call(r, !1), void 0 === d ? r = void 0 : (r = new d(t), r._$AT(t, s, e)), void 0 !== e ? (null !== (l = (h = s)._$Co) && void 0 !== l ? l : h._$Co = [])[e] = r : s._$Cl = r), void 0 !== r && (i = N(t, r._$AS(t, i.values), r, e)), i;
|
|
437
|
+
if (i === w) return i;
|
|
438
|
+
let h = void 0 !== e ? s._$Co?.[e] : s._$Cl;
|
|
439
|
+
const o = c(i) ? void 0 : i._$litDirective$;
|
|
440
|
+
return h?.constructor !== o && (h?._$AO?.(!1), void 0 === o ? h = void 0 : (h = new o(t), h._$AT(t, s, e)), void 0 !== e ? (s._$Co ??= [])[e] = h : s._$Cl = h), void 0 !== h && (i = N(t, h._$AS(t, i.values), h, e)), i;
|
|
1008
441
|
}
|
|
1009
442
|
class S {
|
|
1010
443
|
constructor(t, i) {
|
|
1011
|
-
this.
|
|
444
|
+
this._$AV = [], this._$AN = void 0, this._$AD = t, this._$AM = i;
|
|
1012
445
|
}
|
|
1013
446
|
get parentNode() {
|
|
1014
447
|
return this._$AM.parentNode;
|
|
@@ -1016,47 +449,44 @@
|
|
|
1016
449
|
get _$AU() {
|
|
1017
450
|
return this._$AM._$AU;
|
|
1018
451
|
}
|
|
1019
|
-
|
|
1020
|
-
var i;
|
|
452
|
+
u(t) {
|
|
1021
453
|
const {
|
|
1022
454
|
el: {
|
|
1023
|
-
content:
|
|
455
|
+
content: i
|
|
1024
456
|
},
|
|
1025
|
-
parts:
|
|
457
|
+
parts: s
|
|
1026
458
|
} = this._$AD,
|
|
1027
|
-
|
|
1028
|
-
|
|
1029
|
-
let
|
|
1030
|
-
|
|
1031
|
-
|
|
1032
|
-
|
|
1033
|
-
for (; void 0 !==
|
|
1034
|
-
if (
|
|
459
|
+
e = (t?.creationScope ?? r$1).importNode(i, !0);
|
|
460
|
+
E.currentNode = e;
|
|
461
|
+
let h = E.nextNode(),
|
|
462
|
+
o = 0,
|
|
463
|
+
n = 0,
|
|
464
|
+
l = s[0];
|
|
465
|
+
for (; void 0 !== l;) {
|
|
466
|
+
if (o === l.index) {
|
|
1035
467
|
let i;
|
|
1036
|
-
2 ===
|
|
468
|
+
2 === l.type ? i = new M(h, h.nextSibling, this, t) : 1 === l.type ? i = new l.ctor(h, l.name, l.strings, this, t) : 6 === l.type && (i = new L(h, this, t)), this._$AV.push(i), l = s[++n];
|
|
1037
469
|
}
|
|
1038
|
-
|
|
470
|
+
o !== l?.index && (h = E.nextNode(), o++);
|
|
1039
471
|
}
|
|
1040
|
-
return
|
|
472
|
+
return E.currentNode = r$1, e;
|
|
1041
473
|
}
|
|
1042
474
|
p(t) {
|
|
1043
475
|
let i = 0;
|
|
1044
|
-
for (const s of this.
|
|
476
|
+
for (const s of this._$AV) void 0 !== s && (void 0 !== s.strings ? (s._$AI(t, s, i), i += s.strings.length - 2) : s._$AI(t[i])), i++;
|
|
1045
477
|
}
|
|
1046
478
|
}
|
|
1047
479
|
class M {
|
|
1048
|
-
constructor(t, i, s, e) {
|
|
1049
|
-
var o;
|
|
1050
|
-
this.type = 2, this._$AH = A, this._$AN = void 0, this._$AA = t, this._$AB = i, this._$AM = s, this.options = e, this._$Cm = null === (o = null == e ? void 0 : e.isConnected) || void 0 === o || o;
|
|
1051
|
-
}
|
|
1052
480
|
get _$AU() {
|
|
1053
|
-
|
|
1054
|
-
|
|
481
|
+
return this._$AM?._$AU ?? this._$Cv;
|
|
482
|
+
}
|
|
483
|
+
constructor(t, i, s, e) {
|
|
484
|
+
this.type = 2, this._$AH = T, this._$AN = void 0, this._$AA = t, this._$AB = i, this._$AM = s, this.options = e, this._$Cv = e?.isConnected ?? !0;
|
|
1055
485
|
}
|
|
1056
486
|
get parentNode() {
|
|
1057
487
|
let t = this._$AA.parentNode;
|
|
1058
488
|
const i = this._$AM;
|
|
1059
|
-
return void 0 !== i && 11 ===
|
|
489
|
+
return void 0 !== i && 11 === t?.nodeType && (t = i.parentNode), t;
|
|
1060
490
|
}
|
|
1061
491
|
get startNode() {
|
|
1062
492
|
return this._$AA;
|
|
@@ -1065,113 +495,107 @@
|
|
|
1065
495
|
return this._$AB;
|
|
1066
496
|
}
|
|
1067
497
|
_$AI(t, i = this) {
|
|
1068
|
-
t = N(this, t, i),
|
|
498
|
+
t = N(this, t, i), c(t) ? t === T || null == t || "" === t ? (this._$AH !== T && this._$AR(), this._$AH = T) : t !== this._$AH && t !== w && this._(t) : void 0 !== t._$litType$ ? this.g(t) : void 0 !== t.nodeType ? this.$(t) : u(t) ? this.T(t) : this._(t);
|
|
1069
499
|
}
|
|
1070
|
-
|
|
500
|
+
k(t) {
|
|
1071
501
|
return this._$AA.parentNode.insertBefore(t, this._$AB);
|
|
1072
502
|
}
|
|
1073
|
-
|
|
1074
|
-
this._$AH !== t && (this._$AR(), this._$AH = this.
|
|
503
|
+
$(t) {
|
|
504
|
+
this._$AH !== t && (this._$AR(), this._$AH = this.k(t));
|
|
1075
505
|
}
|
|
1076
|
-
|
|
1077
|
-
this._$AH !==
|
|
506
|
+
_(t) {
|
|
507
|
+
this._$AH !== T && c(this._$AH) ? this._$AA.nextSibling.data = t : this.$(r$1.createTextNode(t)), this._$AH = t;
|
|
1078
508
|
}
|
|
1079
|
-
|
|
1080
|
-
var i;
|
|
509
|
+
g(t) {
|
|
1081
510
|
const {
|
|
1082
|
-
values:
|
|
1083
|
-
_$litType$:
|
|
511
|
+
values: i,
|
|
512
|
+
_$litType$: s
|
|
1084
513
|
} = t,
|
|
1085
|
-
|
|
1086
|
-
if (
|
|
1087
|
-
const t = new S(
|
|
1088
|
-
|
|
1089
|
-
t.p(
|
|
514
|
+
e = "number" == typeof s ? this._$AC(t) : (void 0 === s.el && (s.el = V.createElement(C(s.h, s.h[0]), this.options)), s);
|
|
515
|
+
if (this._$AH?._$AD === e) this._$AH.p(i);else {
|
|
516
|
+
const t = new S(e, this),
|
|
517
|
+
s = t.u(this.options);
|
|
518
|
+
t.p(i), this.$(s), this._$AH = t;
|
|
1090
519
|
}
|
|
1091
520
|
}
|
|
1092
521
|
_$AC(t) {
|
|
1093
|
-
let i =
|
|
1094
|
-
return void 0 === i &&
|
|
522
|
+
let i = A.get(t.strings);
|
|
523
|
+
return void 0 === i && A.set(t.strings, i = new V(t)), i;
|
|
1095
524
|
}
|
|
1096
|
-
|
|
1097
|
-
|
|
525
|
+
T(t) {
|
|
526
|
+
a(this._$AH) || (this._$AH = [], this._$AR());
|
|
1098
527
|
const i = this._$AH;
|
|
1099
528
|
let s,
|
|
1100
529
|
e = 0;
|
|
1101
|
-
for (const
|
|
530
|
+
for (const h of t) e === i.length ? i.push(s = new M(this.k(l()), this.k(l()), this, this.options)) : s = i[e], s._$AI(h), e++;
|
|
1102
531
|
e < i.length && (this._$AR(s && s._$AB.nextSibling, e), i.length = e);
|
|
1103
532
|
}
|
|
1104
533
|
_$AR(t = this._$AA.nextSibling, i) {
|
|
1105
|
-
|
|
1106
|
-
for (null === (s = this._$AP) || void 0 === s || s.call(this, !1, !0, i); t && t !== this._$AB;) {
|
|
534
|
+
for (this._$AP?.(!1, !0, i); t && t !== this._$AB;) {
|
|
1107
535
|
const i = t.nextSibling;
|
|
1108
536
|
t.remove(), t = i;
|
|
1109
537
|
}
|
|
1110
538
|
}
|
|
1111
539
|
setConnected(t) {
|
|
1112
|
-
|
|
1113
|
-
void 0 === this._$AM && (this._$Cm = t, null === (i = this._$AP) || void 0 === i || i.call(this, t));
|
|
540
|
+
void 0 === this._$AM && (this._$Cv = t, this._$AP?.(t));
|
|
1114
541
|
}
|
|
1115
542
|
}
|
|
1116
543
|
class R {
|
|
1117
|
-
constructor(t, i, s, e, o) {
|
|
1118
|
-
this.type = 1, this._$AH = A, this._$AN = void 0, this.element = t, this.name = i, this._$AM = e, this.options = o, s.length > 2 || "" !== s[0] || "" !== s[1] ? (this._$AH = Array(s.length - 1).fill(new String()), this.strings = s) : this._$AH = A;
|
|
1119
|
-
}
|
|
1120
544
|
get tagName() {
|
|
1121
545
|
return this.element.tagName;
|
|
1122
546
|
}
|
|
1123
547
|
get _$AU() {
|
|
1124
548
|
return this._$AM._$AU;
|
|
1125
549
|
}
|
|
550
|
+
constructor(t, i, s, e, h) {
|
|
551
|
+
this.type = 1, this._$AH = T, this._$AN = void 0, this.element = t, this.name = i, this._$AM = e, this.options = h, s.length > 2 || "" !== s[0] || "" !== s[1] ? (this._$AH = Array(s.length - 1).fill(new String()), this.strings = s) : this._$AH = T;
|
|
552
|
+
}
|
|
1126
553
|
_$AI(t, i = this, s, e) {
|
|
1127
|
-
const
|
|
1128
|
-
let
|
|
1129
|
-
if (void 0 ===
|
|
554
|
+
const h = this.strings;
|
|
555
|
+
let o = !1;
|
|
556
|
+
if (void 0 === h) t = N(this, t, i, 0), o = !c(t) || t !== this._$AH && t !== w, o && (this._$AH = t);else {
|
|
1130
557
|
const e = t;
|
|
1131
|
-
let
|
|
1132
|
-
for (t =
|
|
558
|
+
let n, r;
|
|
559
|
+
for (t = h[0], n = 0; n < h.length - 1; n++) r = N(this, e[s + n], i, n), r === w && (r = this._$AH[n]), o ||= !c(r) || r !== this._$AH[n], r === T ? t = T : t !== T && (t += (r ?? "") + h[n + 1]), this._$AH[n] = r;
|
|
1133
560
|
}
|
|
1134
|
-
|
|
561
|
+
o && !e && this.O(t);
|
|
1135
562
|
}
|
|
1136
|
-
|
|
1137
|
-
t ===
|
|
563
|
+
O(t) {
|
|
564
|
+
t === T ? this.element.removeAttribute(this.name) : this.element.setAttribute(this.name, t ?? "");
|
|
1138
565
|
}
|
|
1139
566
|
}
|
|
1140
567
|
class k extends R {
|
|
1141
568
|
constructor() {
|
|
1142
569
|
super(...arguments), this.type = 3;
|
|
1143
570
|
}
|
|
1144
|
-
|
|
1145
|
-
this.element[this.name] = t ===
|
|
571
|
+
O(t) {
|
|
572
|
+
this.element[this.name] = t === T ? void 0 : t;
|
|
1146
573
|
}
|
|
1147
574
|
}
|
|
1148
|
-
|
|
1149
|
-
class I extends R {
|
|
575
|
+
class H extends R {
|
|
1150
576
|
constructor() {
|
|
1151
577
|
super(...arguments), this.type = 4;
|
|
1152
578
|
}
|
|
1153
|
-
|
|
1154
|
-
|
|
579
|
+
O(t) {
|
|
580
|
+
this.element.toggleAttribute(this.name, !!t && t !== T);
|
|
1155
581
|
}
|
|
1156
582
|
}
|
|
1157
|
-
class
|
|
1158
|
-
constructor(t, i, s, e,
|
|
1159
|
-
super(t, i, s, e,
|
|
583
|
+
class I extends R {
|
|
584
|
+
constructor(t, i, s, e, h) {
|
|
585
|
+
super(t, i, s, e, h), this.type = 5;
|
|
1160
586
|
}
|
|
1161
587
|
_$AI(t, i = this) {
|
|
1162
|
-
|
|
1163
|
-
|
|
1164
|
-
|
|
1165
|
-
|
|
1166
|
-
|
|
1167
|
-
o && this.element.removeEventListener(this.name, this, e), n && this.element.addEventListener(this.name, this, t), this._$AH = t;
|
|
588
|
+
if ((t = N(this, t, i, 0) ?? T) === w) return;
|
|
589
|
+
const s = this._$AH,
|
|
590
|
+
e = t === T && s !== T || t.capture !== s.capture || t.once !== s.once || t.passive !== s.passive,
|
|
591
|
+
h = t !== T && (s === T || e);
|
|
592
|
+
e && this.element.removeEventListener(this.name, this, s), h && this.element.addEventListener(this.name, this, t), this._$AH = t;
|
|
1168
593
|
}
|
|
1169
594
|
handleEvent(t) {
|
|
1170
|
-
|
|
1171
|
-
"function" == typeof this._$AH ? this._$AH.call(null !== (s = null === (i = this.options) || void 0 === i ? void 0 : i.host) && void 0 !== s ? s : this.element, t) : this._$AH.handleEvent(t);
|
|
595
|
+
"function" == typeof this._$AH ? this._$AH.call(this.options?.host ?? this.element, t) : this._$AH.handleEvent(t);
|
|
1172
596
|
}
|
|
1173
597
|
}
|
|
1174
|
-
class
|
|
598
|
+
class L {
|
|
1175
599
|
constructor(t, i, s) {
|
|
1176
600
|
this.element = t, this.type = 6, this._$AN = void 0, this._$AM = i, this.options = s;
|
|
1177
601
|
}
|
|
@@ -1182,17 +606,16 @@
|
|
|
1182
606
|
N(this, t);
|
|
1183
607
|
}
|
|
1184
608
|
}
|
|
1185
|
-
const
|
|
1186
|
-
|
|
1187
|
-
const
|
|
1188
|
-
|
|
1189
|
-
|
|
1190
|
-
|
|
1191
|
-
|
|
1192
|
-
|
|
1193
|
-
n._$litPart$ = l = new M(i.insertBefore(d(), t), t, void 0, null != s ? s : {});
|
|
609
|
+
const Z = t.litHtmlPolyfillSupport;
|
|
610
|
+
Z?.(V, M), (t.litHtmlVersions ??= []).push("3.1.0");
|
|
611
|
+
const j = (t, i, s) => {
|
|
612
|
+
const e = s?.renderBefore ?? i;
|
|
613
|
+
let h = e._$litPart$;
|
|
614
|
+
if (void 0 === h) {
|
|
615
|
+
const t = s?.renderBefore ?? null;
|
|
616
|
+
e._$litPart$ = h = new M(i.insertBefore(l(), t), t, void 0, s ?? {});
|
|
1194
617
|
}
|
|
1195
|
-
return
|
|
618
|
+
return h._$AI(t), h;
|
|
1196
619
|
};
|
|
1197
620
|
|
|
1198
621
|
/**
|
|
@@ -1200,42 +623,38 @@
|
|
|
1200
623
|
* Copyright 2017 Google LLC
|
|
1201
624
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
1202
625
|
*/
|
|
1203
|
-
|
|
1204
|
-
class s extends a$1 {
|
|
626
|
+
class s extends b$1 {
|
|
1205
627
|
constructor() {
|
|
1206
628
|
super(...arguments), this.renderOptions = {
|
|
1207
629
|
host: this
|
|
1208
630
|
}, this._$Do = void 0;
|
|
1209
631
|
}
|
|
1210
632
|
createRenderRoot() {
|
|
1211
|
-
|
|
1212
|
-
|
|
1213
|
-
return null !== (t = (e = this.renderOptions).renderBefore) && void 0 !== t || (e.renderBefore = i.firstChild), i;
|
|
633
|
+
const t = super.createRenderRoot();
|
|
634
|
+
return this.renderOptions.renderBefore ??= t.firstChild, t;
|
|
1214
635
|
}
|
|
1215
636
|
update(t) {
|
|
1216
637
|
const i = this.render();
|
|
1217
|
-
this.hasUpdated || (this.renderOptions.isConnected = this.isConnected), super.update(t), this._$Do =
|
|
638
|
+
this.hasUpdated || (this.renderOptions.isConnected = this.isConnected), super.update(t), this._$Do = j(i, this.renderRoot, this.renderOptions);
|
|
1218
639
|
}
|
|
1219
640
|
connectedCallback() {
|
|
1220
|
-
|
|
1221
|
-
super.connectedCallback(), null === (t = this._$Do) || void 0 === t || t.setConnected(!0);
|
|
641
|
+
super.connectedCallback(), this._$Do?.setConnected(!0);
|
|
1222
642
|
}
|
|
1223
643
|
disconnectedCallback() {
|
|
1224
|
-
|
|
1225
|
-
super.disconnectedCallback(), null === (t = this._$Do) || void 0 === t || t.setConnected(!1);
|
|
644
|
+
super.disconnectedCallback(), this._$Do?.setConnected(!1);
|
|
1226
645
|
}
|
|
1227
646
|
render() {
|
|
1228
|
-
return
|
|
647
|
+
return w;
|
|
1229
648
|
}
|
|
1230
649
|
}
|
|
1231
|
-
s.
|
|
650
|
+
s._$litElement$ = !0, s[("finalized")] = !0, globalThis.litElementHydrateSupport?.({
|
|
1232
651
|
LitElement: s
|
|
1233
652
|
});
|
|
1234
|
-
const
|
|
1235
|
-
|
|
653
|
+
const r = globalThis.litElementPolyfillSupport;
|
|
654
|
+
r?.({
|
|
1236
655
|
LitElement: s
|
|
1237
656
|
});
|
|
1238
|
-
(
|
|
657
|
+
(globalThis.litElementVersions ??= []).push("4.0.2");
|
|
1239
658
|
|
|
1240
659
|
var noop = {
|
|
1241
660
|
value: () => {}
|
|
@@ -2152,15 +1571,15 @@
|
|
|
2152
1571
|
var darker = 0.7;
|
|
2153
1572
|
var brighter = 1 / darker;
|
|
2154
1573
|
var reI = "\\s*([+-]?\\d+)\\s*",
|
|
2155
|
-
reN = "\\s*([+-]?\\d
|
|
2156
|
-
reP = "\\s*([+-]?\\d
|
|
1574
|
+
reN = "\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",
|
|
1575
|
+
reP = "\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",
|
|
2157
1576
|
reHex = /^#([0-9a-f]{3,8})$/,
|
|
2158
|
-
reRgbInteger = new RegExp(
|
|
2159
|
-
reRgbPercent = new RegExp(
|
|
2160
|
-
reRgbaInteger = new RegExp(
|
|
2161
|
-
reRgbaPercent = new RegExp(
|
|
2162
|
-
reHslPercent = new RegExp(
|
|
2163
|
-
reHslaPercent = new RegExp(
|
|
1577
|
+
reRgbInteger = new RegExp(`^rgb\\(${reI},${reI},${reI}\\)$`),
|
|
1578
|
+
reRgbPercent = new RegExp(`^rgb\\(${reP},${reP},${reP}\\)$`),
|
|
1579
|
+
reRgbaInteger = new RegExp(`^rgba\\(${reI},${reI},${reI},${reN}\\)$`),
|
|
1580
|
+
reRgbaPercent = new RegExp(`^rgba\\(${reP},${reP},${reP},${reN}\\)$`),
|
|
1581
|
+
reHslPercent = new RegExp(`^hsl\\(${reN},${reP},${reP}\\)$`),
|
|
1582
|
+
reHslaPercent = new RegExp(`^hsla\\(${reN},${reP},${reP},${reN}\\)$`);
|
|
2164
1583
|
var named = {
|
|
2165
1584
|
aliceblue: 0xf0f8ff,
|
|
2166
1585
|
antiquewhite: 0xfaebd7,
|
|
@@ -2312,15 +1731,16 @@
|
|
|
2312
1731
|
yellowgreen: 0x9acd32
|
|
2313
1732
|
};
|
|
2314
1733
|
define(Color, color, {
|
|
2315
|
-
copy
|
|
1734
|
+
copy(channels) {
|
|
2316
1735
|
return Object.assign(new this.constructor(), this, channels);
|
|
2317
1736
|
},
|
|
2318
|
-
displayable
|
|
1737
|
+
displayable() {
|
|
2319
1738
|
return this.rgb().displayable();
|
|
2320
1739
|
},
|
|
2321
1740
|
hex: color_formatHex,
|
|
2322
1741
|
// Deprecated! Use color.formatHex.
|
|
2323
1742
|
formatHex: color_formatHex,
|
|
1743
|
+
formatHex8: color_formatHex8,
|
|
2324
1744
|
formatHsl: color_formatHsl,
|
|
2325
1745
|
formatRgb: color_formatRgb,
|
|
2326
1746
|
toString: color_formatRgb
|
|
@@ -2328,6 +1748,9 @@
|
|
|
2328
1748
|
function color_formatHex() {
|
|
2329
1749
|
return this.rgb().formatHex();
|
|
2330
1750
|
}
|
|
1751
|
+
function color_formatHex8() {
|
|
1752
|
+
return this.rgb().formatHex8();
|
|
1753
|
+
}
|
|
2331
1754
|
function color_formatHsl() {
|
|
2332
1755
|
return hslConvert(this).formatHsl();
|
|
2333
1756
|
}
|
|
@@ -2374,36 +1797,48 @@
|
|
|
2374
1797
|
this.opacity = +opacity;
|
|
2375
1798
|
}
|
|
2376
1799
|
define(Rgb, rgb, extend(Color, {
|
|
2377
|
-
brighter
|
|
1800
|
+
brighter(k) {
|
|
2378
1801
|
k = k == null ? brighter : Math.pow(brighter, k);
|
|
2379
1802
|
return new Rgb(this.r * k, this.g * k, this.b * k, this.opacity);
|
|
2380
1803
|
},
|
|
2381
|
-
darker
|
|
1804
|
+
darker(k) {
|
|
2382
1805
|
k = k == null ? darker : Math.pow(darker, k);
|
|
2383
1806
|
return new Rgb(this.r * k, this.g * k, this.b * k, this.opacity);
|
|
2384
1807
|
},
|
|
2385
|
-
rgb
|
|
1808
|
+
rgb() {
|
|
2386
1809
|
return this;
|
|
2387
1810
|
},
|
|
2388
|
-
|
|
1811
|
+
clamp() {
|
|
1812
|
+
return new Rgb(clampi(this.r), clampi(this.g), clampi(this.b), clampa(this.opacity));
|
|
1813
|
+
},
|
|
1814
|
+
displayable() {
|
|
2389
1815
|
return -0.5 <= this.r && this.r < 255.5 && -0.5 <= this.g && this.g < 255.5 && -0.5 <= this.b && this.b < 255.5 && 0 <= this.opacity && this.opacity <= 1;
|
|
2390
1816
|
},
|
|
2391
1817
|
hex: rgb_formatHex,
|
|
2392
1818
|
// Deprecated! Use color.formatHex.
|
|
2393
1819
|
formatHex: rgb_formatHex,
|
|
1820
|
+
formatHex8: rgb_formatHex8,
|
|
2394
1821
|
formatRgb: rgb_formatRgb,
|
|
2395
1822
|
toString: rgb_formatRgb
|
|
2396
1823
|
}));
|
|
2397
1824
|
function rgb_formatHex() {
|
|
2398
|
-
return
|
|
1825
|
+
return `#${hex(this.r)}${hex(this.g)}${hex(this.b)}`;
|
|
1826
|
+
}
|
|
1827
|
+
function rgb_formatHex8() {
|
|
1828
|
+
return `#${hex(this.r)}${hex(this.g)}${hex(this.b)}${hex((isNaN(this.opacity) ? 1 : this.opacity) * 255)}`;
|
|
2399
1829
|
}
|
|
2400
1830
|
function rgb_formatRgb() {
|
|
2401
|
-
|
|
2402
|
-
a
|
|
2403
|
-
|
|
1831
|
+
const a = clampa(this.opacity);
|
|
1832
|
+
return `${a === 1 ? "rgb(" : "rgba("}${clampi(this.r)}, ${clampi(this.g)}, ${clampi(this.b)}${a === 1 ? ")" : `, ${a})`}`;
|
|
1833
|
+
}
|
|
1834
|
+
function clampa(opacity) {
|
|
1835
|
+
return isNaN(opacity) ? 1 : Math.max(0, Math.min(1, opacity));
|
|
1836
|
+
}
|
|
1837
|
+
function clampi(value) {
|
|
1838
|
+
return Math.max(0, Math.min(255, Math.round(value) || 0));
|
|
2404
1839
|
}
|
|
2405
1840
|
function hex(value) {
|
|
2406
|
-
value =
|
|
1841
|
+
value = clampi(value);
|
|
2407
1842
|
return (value < 16 ? "0" : "") + value.toString(16);
|
|
2408
1843
|
}
|
|
2409
1844
|
function hsla(h, s, l, a) {
|
|
@@ -2443,15 +1878,15 @@
|
|
|
2443
1878
|
this.opacity = +opacity;
|
|
2444
1879
|
}
|
|
2445
1880
|
define(Hsl, hsl, extend(Color, {
|
|
2446
|
-
brighter
|
|
1881
|
+
brighter(k) {
|
|
2447
1882
|
k = k == null ? brighter : Math.pow(brighter, k);
|
|
2448
1883
|
return new Hsl(this.h, this.s, this.l * k, this.opacity);
|
|
2449
1884
|
},
|
|
2450
|
-
darker
|
|
1885
|
+
darker(k) {
|
|
2451
1886
|
k = k == null ? darker : Math.pow(darker, k);
|
|
2452
1887
|
return new Hsl(this.h, this.s, this.l * k, this.opacity);
|
|
2453
1888
|
},
|
|
2454
|
-
rgb
|
|
1889
|
+
rgb() {
|
|
2455
1890
|
var h = this.h % 360 + (this.h < 0) * 360,
|
|
2456
1891
|
s = isNaN(h) || isNaN(this.s) ? 0 : this.s,
|
|
2457
1892
|
l = this.l,
|
|
@@ -2459,15 +1894,24 @@
|
|
|
2459
1894
|
m1 = 2 * l - m2;
|
|
2460
1895
|
return new Rgb(hsl2rgb(h >= 240 ? h - 240 : h + 120, m1, m2), hsl2rgb(h, m1, m2), hsl2rgb(h < 120 ? h + 240 : h - 120, m1, m2), this.opacity);
|
|
2461
1896
|
},
|
|
2462
|
-
|
|
1897
|
+
clamp() {
|
|
1898
|
+
return new Hsl(clamph(this.h), clampt(this.s), clampt(this.l), clampa(this.opacity));
|
|
1899
|
+
},
|
|
1900
|
+
displayable() {
|
|
2463
1901
|
return (0 <= this.s && this.s <= 1 || isNaN(this.s)) && 0 <= this.l && this.l <= 1 && 0 <= this.opacity && this.opacity <= 1;
|
|
2464
1902
|
},
|
|
2465
|
-
formatHsl
|
|
2466
|
-
|
|
2467
|
-
a
|
|
2468
|
-
return (a === 1 ? "hsl(" : "hsla(") + (this.h || 0) + ", " + (this.s || 0) * 100 + "%, " + (this.l || 0) * 100 + "%" + (a === 1 ? ")" : ", " + a + ")");
|
|
1903
|
+
formatHsl() {
|
|
1904
|
+
const a = clampa(this.opacity);
|
|
1905
|
+
return `${a === 1 ? "hsl(" : "hsla("}${clamph(this.h)}, ${clampt(this.s) * 100}%, ${clampt(this.l) * 100}%${a === 1 ? ")" : `, ${a})`}`;
|
|
2469
1906
|
}
|
|
2470
1907
|
}));
|
|
1908
|
+
function clamph(value) {
|
|
1909
|
+
value = (value || 0) % 360;
|
|
1910
|
+
return value < 0 ? value + 360 : value;
|
|
1911
|
+
}
|
|
1912
|
+
function clampt(value) {
|
|
1913
|
+
return Math.max(0, Math.min(1, value || 0));
|
|
1914
|
+
}
|
|
2471
1915
|
|
|
2472
1916
|
/* From FvD 13.37, CSS Color Module Level 3 */
|
|
2473
1917
|
function hsl2rgb(h, m1, m2) {
|
|
@@ -3781,7 +3225,6 @@
|
|
|
3781
3225
|
};
|
|
3782
3226
|
/* eslint-enable key-spacing, object-curly-newline */
|
|
3783
3227
|
}
|
|
3784
|
-
|
|
3785
3228
|
static cssBoxShadow(elevation, rotate = false, inverse = false) {
|
|
3786
3229
|
const umbraO = this.shadows.opacityUmbra + this.shadows.opacityBoost;
|
|
3787
3230
|
const penumbraO = this.shadows.opacityPenumbra + this.shadows.opacityBoost;
|
|
@@ -3797,6 +3240,48 @@
|
|
|
3797
3240
|
const ambientS = rotate ? `${-ambientM.y}px ${ambientM.y / 2}px ${ambientM.b}px ${ambientM.s}px` : `${ambientM.y / 2}px ${ambientM.y}px ${ambientM.b}px ${ambientM.s}px`;
|
|
3798
3241
|
return `${umbraS} ${umbraC}, ${penumbraS} ${penumbraC}, ${ambientS} ${ambientC}`;
|
|
3799
3242
|
}
|
|
3243
|
+
static get svgDefs() {
|
|
3244
|
+
const shadows = DecidablesElement.shadows; /* eslint-disable-line prefer-destructuring */
|
|
3245
|
+
|
|
3246
|
+
const filters = shadows.elevations.map(z => {
|
|
3247
|
+
return `
|
|
3248
|
+
<filter id=${`shadow-${z}`} filterUnits="userSpaceOnUse" x="-100%" y="-100%" width="200%" height="200%">
|
|
3249
|
+
<feComponentTransfer in="SourceAlpha" result="solid">
|
|
3250
|
+
<feFuncA type="table" tableValues="0 1 1"/>
|
|
3251
|
+
</feComponentTransfer>
|
|
3252
|
+
<feOffset in="solid" result="offU" dx=${shadows.mapUmbra[z].y / 2} dy=${shadows.mapUmbra[z].y} />
|
|
3253
|
+
<feOffset in="solid" result="offP" dx=${shadows.mapPenumbra[z].y / 2} dy=${shadows.mapPenumbra[z].y} />
|
|
3254
|
+
<feOffset in="solid" result="offA" dx=${shadows.mapAmbient[z].y / 2} dy=${shadows.mapAmbient[z].y} />
|
|
3255
|
+
${shadows.mapUmbra[z].s === 0 ? '' : `<feMorphology in="offU" result="spreadU" operator=${shadows.mapUmbra[z].s > 0 ? 'dilate' : 'erode'} radius=${Math.abs(shadows.mapUmbra[z].s)} />`}
|
|
3256
|
+
${shadows.mapPenumbra[z].s === 0 ? '' : `<feMorphology in="offP" result="spreadP" operator=${shadows.mapPenumbra[z].s > 0 ? 'dilate' : 'erode'} radius=${Math.abs(shadows.mapPenumbra[z].s)} />`}
|
|
3257
|
+
${shadows.mapAmbient[z].s === 0 ? '' : `<feMorphology in="offA" result="spreadA" operator=${shadows.mapAmbient[z].s > 0 ? 'dilate' : 'erode'} radius=${Math.abs(shadows.mapAmbient[z].s)} />`}
|
|
3258
|
+
<feGaussianBlur in=${shadows.mapUmbra[z].s === 0 ? 'offU' : 'spreadU'} result="blurU" stdDeviation=${shadows.mapUmbra[z].b / 2} />
|
|
3259
|
+
<feGaussianBlur in=${shadows.mapPenumbra[z].s === 0 ? 'offP' : 'spreadP'} result="blurP" stdDeviation=${shadows.mapPenumbra[z].b / 2} />
|
|
3260
|
+
<feGaussianBlur in=${shadows.mapAmbient[z].s === 0 ? 'offA' : 'spreadA'} result="blurA" stdDeviation=${shadows.mapAmbient[z].b / 2} />
|
|
3261
|
+
<feFlood in="SourceGraphic" result="opU" flood-color=${shadows.baselineColor} flood-opacity=${shadows.opacityUmbra + shadows.opacityBoost} />
|
|
3262
|
+
<feFlood in="SourceGraphic" result="opP" flood-color=${shadows.baselineColor} flood-opacity=${shadows.opacityPenumbra + shadows.opacityBoost} />
|
|
3263
|
+
<feFlood in="SourceGraphic" result="opA" flood-color=${shadows.baselineColor} flood-opacity=${shadows.opacityAmbient + shadows.opacityBoost} />
|
|
3264
|
+
<feComposite in="opU" in2="blurU" result="shU" operator="in" />
|
|
3265
|
+
<feComposite in="opP" in2="blurP" result="shP" operator="in" />
|
|
3266
|
+
<feComposite in="opA" in2="blurA" result="shA" operator="in" />
|
|
3267
|
+
<feMorphology in="solid" result="smaller" operator="erode" radius="1" />
|
|
3268
|
+
<feComposite in="shU" in2="smaller" result="finalU" operator="out" />
|
|
3269
|
+
<feComposite in="shP" in2="smaller" result="finalP" operator="out" />
|
|
3270
|
+
<feComposite in="shA" in2="smaller" result="finalA" operator="out" />
|
|
3271
|
+
<feMerge>
|
|
3272
|
+
<feMergeNode in="finalU" />
|
|
3273
|
+
<feMergeNode in="finalP" />
|
|
3274
|
+
<feMergeNode in="finalA" />
|
|
3275
|
+
<feMergeNode in="SourceGraphic" />
|
|
3276
|
+
</feMerge>
|
|
3277
|
+
</filter>`;
|
|
3278
|
+
});
|
|
3279
|
+
return `
|
|
3280
|
+
<defs>
|
|
3281
|
+
${filters}
|
|
3282
|
+
</defs>
|
|
3283
|
+
`;
|
|
3284
|
+
}
|
|
3800
3285
|
static get svgFilters() {
|
|
3801
3286
|
const shadows = DecidablesElement.shadows; /* eslint-disable-line prefer-destructuring */
|
|
3802
3287
|
|
|
@@ -3804,7 +3289,7 @@
|
|
|
3804
3289
|
return b`
|
|
3805
3290
|
<filter id=${`shadow-${z}`} x="-250%" y="-250%" width="600%" height="600%">
|
|
3806
3291
|
<feComponentTransfer in="SourceAlpha" result="solid">
|
|
3807
|
-
<feFuncA
|
|
3292
|
+
<feFuncA type="table" tableValues="0 1 1"/>
|
|
3808
3293
|
</feComponentTransfer>
|
|
3809
3294
|
<feOffset in="solid" result="offU" dx=${shadows.mapUmbra[z].y / 2} dy=${shadows.mapUmbra[z].y} />
|
|
3810
3295
|
<feOffset in="solid" result="offP" dx=${shadows.mapPenumbra[z].y / 2} dy=${shadows.mapPenumbra[z].y} />
|
|
@@ -3842,24 +3327,24 @@
|
|
|
3842
3327
|
`;
|
|
3843
3328
|
}
|
|
3844
3329
|
static get styles() {
|
|
3845
|
-
return
|
|
3330
|
+
return i$2`
|
|
3846
3331
|
:host {
|
|
3847
|
-
---shadow-0: var(--shadow-0, ${
|
|
3848
|
-
---shadow-2: var(--shadow-2, ${
|
|
3849
|
-
---shadow-4: var(--shadow-4, ${
|
|
3850
|
-
---shadow-8: var(--shadow-8, ${
|
|
3851
|
-
|
|
3852
|
-
---color-background: var(--color-background, ${
|
|
3853
|
-
---color-border: var(--color-border, ${
|
|
3854
|
-
---color-text: var(--color-text, ${
|
|
3855
|
-
---color-text-inverse: var(--color-text-inverse, ${
|
|
3856
|
-
---color-link: var(--color-link, ${
|
|
3857
|
-
---color-element-background: var(--color-element-background, ${
|
|
3858
|
-
---color-element-disabled: var(--color-element-disabled, ${
|
|
3859
|
-
---color-element-enabled: var(--color-element-enabled, ${
|
|
3860
|
-
---color-element-selected: var(--color-element-selected, ${
|
|
3861
|
-
---color-element-border: var(--color-element-border, ${
|
|
3862
|
-
---color-element-emphasis: var(--color-element-emphasis, ${
|
|
3332
|
+
---shadow-0: var(--shadow-0, ${r$3(this.cssBoxShadow(0))});
|
|
3333
|
+
---shadow-2: var(--shadow-2, ${r$3(this.cssBoxShadow(2))});
|
|
3334
|
+
---shadow-4: var(--shadow-4, ${r$3(this.cssBoxShadow(4))});
|
|
3335
|
+
---shadow-8: var(--shadow-8, ${r$3(this.cssBoxShadow(8))});
|
|
3336
|
+
|
|
3337
|
+
---color-background: var(--color-background, ${r$3(this.greys.white)});
|
|
3338
|
+
---color-border: var(--color-border, ${r$3(this.greys.light75)});
|
|
3339
|
+
---color-text: var(--color-text, ${r$3(this.greys.dark75)});
|
|
3340
|
+
---color-text-inverse: var(--color-text-inverse, ${r$3(this.greys.white)});
|
|
3341
|
+
---color-link: var(--color-link, ${r$3(this.greys.dark25)});
|
|
3342
|
+
---color-element-background: var(--color-element-background, ${r$3(this.greys.light75)});
|
|
3343
|
+
---color-element-disabled: var(--color-element-disabled, ${r$3(this.greys.light50)});
|
|
3344
|
+
---color-element-enabled: var(--color-element-enabled, ${r$3(this.greys.dark25)});
|
|
3345
|
+
---color-element-selected: var(--color-element-selected, ${r$3(this.greys.grey)});
|
|
3346
|
+
---color-element-border: var(--color-element-border, ${r$3(this.greys.dark50)});
|
|
3347
|
+
---color-element-emphasis: var(--color-element-emphasis, ${r$3(this.greys.dark75)});
|
|
3863
3348
|
|
|
3864
3349
|
---font-family-base: var(--font-family-base, "Source Sans", sans-serif);
|
|
3865
3350
|
---font-family-math: var(--font-family-math, "Source Serif", serif);
|
|
@@ -3920,7 +3405,7 @@
|
|
|
3920
3405
|
this.disabled = false;
|
|
3921
3406
|
}
|
|
3922
3407
|
static get styles() {
|
|
3923
|
-
return [super.styles,
|
|
3408
|
+
return [super.styles, i$2`
|
|
3924
3409
|
:host {
|
|
3925
3410
|
margin: 0.25rem;
|
|
3926
3411
|
}
|
|
@@ -3990,7 +3475,7 @@
|
|
|
3990
3475
|
* Copyright 2018 Google LLC
|
|
3991
3476
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
3992
3477
|
*/
|
|
3993
|
-
const
|
|
3478
|
+
const o = o => o ?? T;
|
|
3994
3479
|
|
|
3995
3480
|
class DecidablesSlider extends DecidablesElement {
|
|
3996
3481
|
static get properties() {
|
|
@@ -4045,11 +3530,11 @@
|
|
|
4045
3530
|
this.value = event.target.value;
|
|
4046
3531
|
}
|
|
4047
3532
|
static get styles() {
|
|
4048
|
-
return [super.styles,
|
|
3533
|
+
return [super.styles, i$2`
|
|
4049
3534
|
:host {
|
|
4050
|
-
---shadow-2-rotate: var(--shadow-2-rotate, ${
|
|
4051
|
-
---shadow-4-rotate: var(--shadow-4-rotate, ${
|
|
4052
|
-
---shadow-8-rotate: var(--shadow-8-rotate, ${
|
|
3535
|
+
---shadow-2-rotate: var(--shadow-2-rotate, ${r$3(this.cssBoxShadow(2, true, false))});
|
|
3536
|
+
---shadow-4-rotate: var(--shadow-4-rotate, ${r$3(this.cssBoxShadow(4, true, false))});
|
|
3537
|
+
---shadow-8-rotate: var(--shadow-8-rotate, ${r$3(this.cssBoxShadow(8, true, false))});
|
|
4053
3538
|
|
|
4054
3539
|
display: flex;
|
|
4055
3540
|
|
|
@@ -4303,9 +3788,9 @@
|
|
|
4303
3788
|
<slot></slot>
|
|
4304
3789
|
</label>
|
|
4305
3790
|
<div class="range">
|
|
4306
|
-
<input type="range" id="slider" min=${
|
|
3791
|
+
<input type="range" id="slider" min=${o(this.min)} max=${o(this.max)} step=${o(this.step)} .value=${this.value} @change=${this.changed.bind(this)} @input=${this.inputted.bind(this)}>
|
|
4307
3792
|
</div>
|
|
4308
|
-
<decidables-spinner min=${
|
|
3793
|
+
<decidables-spinner min=${o(this.min)} max=${o(this.max)} step=${o(this.step)} .value=${this.value} @input=${this.inputted.bind(this)}></decidables-spinner>
|
|
4309
3794
|
`;
|
|
4310
3795
|
}
|
|
4311
3796
|
}
|
|
@@ -4355,12 +3840,15 @@
|
|
|
4355
3840
|
this.value = event.target.value;
|
|
4356
3841
|
}
|
|
4357
3842
|
static get styles() {
|
|
4358
|
-
return [super.styles,
|
|
3843
|
+
return [super.styles, i$2`
|
|
4359
3844
|
:host {
|
|
4360
3845
|
---decidables-spinner-font-size: var(--decidables-spinner-font-size, 1.125rem);
|
|
4361
3846
|
---decidables-spinner-input-width: var(--decidables-spinner-input-width, 4rem);
|
|
4362
3847
|
---decidables-spinner-prefix: var(--decidables-spinner-prefix, "");
|
|
4363
3848
|
|
|
3849
|
+
---decidables-spinner-postfix: var(--decidables-spinner-postfix, "");
|
|
3850
|
+
---decidables-spinner-postfix-padding: var(--decidables-spinner-postfix-padding, 0);
|
|
3851
|
+
|
|
4364
3852
|
display: block;
|
|
4365
3853
|
}
|
|
4366
3854
|
|
|
@@ -4388,8 +3876,20 @@
|
|
|
4388
3876
|
content: var(---decidables-spinner-prefix);
|
|
4389
3877
|
}
|
|
4390
3878
|
|
|
3879
|
+
label::after {
|
|
3880
|
+
position: absolute;
|
|
3881
|
+
right: 0.25rem;
|
|
3882
|
+
bottom: 1px;
|
|
3883
|
+
|
|
3884
|
+
font-size: var(---decidables-spinner-font-size);
|
|
3885
|
+
line-height: normal;
|
|
3886
|
+
|
|
3887
|
+
content: var(---decidables-spinner-postfix);
|
|
3888
|
+
}
|
|
3889
|
+
|
|
4391
3890
|
input[type=number] {
|
|
4392
3891
|
width: var(---decidables-spinner-input-width);
|
|
3892
|
+
padding-right: var(---decidables-spinner-postfix-padding);
|
|
4393
3893
|
|
|
4394
3894
|
font-family: var(---font-family-base);
|
|
4395
3895
|
font-size: var(---decidables-spinner-font-size);
|
|
@@ -4440,7 +3940,7 @@
|
|
|
4440
3940
|
return x`
|
|
4441
3941
|
<label>
|
|
4442
3942
|
<slot></slot>
|
|
4443
|
-
<input ?disabled=${this.disabled} type="number" min=${
|
|
3943
|
+
<input ?disabled=${this.disabled} type="number" min=${o(this.min)} max=${o(this.max)} step=${o(this.step)} .value=${this.value} @input=${this.inputted.bind(this)}>
|
|
4444
3944
|
</label>
|
|
4445
3945
|
`;
|
|
4446
3946
|
}
|
|
@@ -4479,7 +3979,7 @@
|
|
|
4479
3979
|
}));
|
|
4480
3980
|
}
|
|
4481
3981
|
static get styles() {
|
|
4482
|
-
return [super.styles,
|
|
3982
|
+
return [super.styles, i$2`
|
|
4483
3983
|
:host {
|
|
4484
3984
|
display: flex;
|
|
4485
3985
|
|
|
@@ -4631,7 +4131,7 @@
|
|
|
4631
4131
|
this.disabled = false;
|
|
4632
4132
|
}
|
|
4633
4133
|
static get styles() {
|
|
4634
|
-
return [super.styles,
|
|
4134
|
+
return [super.styles, i$2`
|
|
4635
4135
|
fieldset {
|
|
4636
4136
|
display: flex;
|
|
4637
4137
|
|
|
@@ -4706,7 +4206,7 @@
|
|
|
4706
4206
|
}));
|
|
4707
4207
|
}
|
|
4708
4208
|
static get styles() {
|
|
4709
|
-
return [super.styles,
|
|
4209
|
+
return [super.styles, i$2`
|
|
4710
4210
|
:host {
|
|
4711
4211
|
display: flex;
|
|
4712
4212
|
}
|
|
@@ -4842,10 +4342,55 @@
|
|
|
4842
4342
|
}
|
|
4843
4343
|
};
|
|
4844
4344
|
|
|
4345
|
+
function DecidablesMixinResizeable(superClass) {
|
|
4346
|
+
return class extends superClass {
|
|
4347
|
+
static get properties() {
|
|
4348
|
+
return {
|
|
4349
|
+
width: {
|
|
4350
|
+
attribute: false,
|
|
4351
|
+
type: Number,
|
|
4352
|
+
reflect: false
|
|
4353
|
+
},
|
|
4354
|
+
height: {
|
|
4355
|
+
attribute: false,
|
|
4356
|
+
type: Number,
|
|
4357
|
+
reflect: false
|
|
4358
|
+
},
|
|
4359
|
+
rem: {
|
|
4360
|
+
attribute: false,
|
|
4361
|
+
type: Number,
|
|
4362
|
+
reflect: false
|
|
4363
|
+
}
|
|
4364
|
+
};
|
|
4365
|
+
}
|
|
4366
|
+
constructor() {
|
|
4367
|
+
super();
|
|
4368
|
+
this.width = NaN;
|
|
4369
|
+
this.height = NaN;
|
|
4370
|
+
this.rem = NaN;
|
|
4371
|
+
}
|
|
4372
|
+
getDimensions() {
|
|
4373
|
+
this.width = parseFloat(this.getComputedStyleValue('width'), 10);
|
|
4374
|
+
this.height = parseFloat(this.getComputedStyleValue('height'), 10);
|
|
4375
|
+
this.rem = parseFloat(getComputedStyle(document.documentElement).getPropertyValue('font-size'), 10);
|
|
4376
|
+
}
|
|
4377
|
+
connectedCallback() {
|
|
4378
|
+
super.connectedCallback();
|
|
4379
|
+
this.resizeObserver = new ResizeObserver(this.getDimensions.bind(this));
|
|
4380
|
+
this.resizeObserver.observe(this);
|
|
4381
|
+
}
|
|
4382
|
+
disconnectedCallback() {
|
|
4383
|
+
this.resizeObserver.unobserve(this);
|
|
4384
|
+
super.disconnectedCallback();
|
|
4385
|
+
}
|
|
4386
|
+
};
|
|
4387
|
+
}
|
|
4388
|
+
|
|
4845
4389
|
exports.DecidablesButton = DecidablesButton;
|
|
4846
4390
|
exports.DecidablesConverterArray = DecidablesConverterArray;
|
|
4847
4391
|
exports.DecidablesConverterSet = DecidablesConverterSet;
|
|
4848
4392
|
exports.DecidablesElement = DecidablesElement;
|
|
4393
|
+
exports.DecidablesMixinResizeable = DecidablesMixinResizeable;
|
|
4849
4394
|
exports.DecidablesSlider = DecidablesSlider;
|
|
4850
4395
|
exports.DecidablesSpinner = DecidablesSpinner;
|
|
4851
4396
|
exports.DecidablesSwitch = DecidablesSwitch;
|