@startinblox/boilerplate 3.0.5 → 3.1.0

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/README.md CHANGED
@@ -201,13 +201,19 @@ This project utilizes [`@lit/localize`](https://www.npmjs.com/package/@lit/local
201
201
  To change the locale at runtime within an application:
202
202
 
203
203
  ```javascript
204
+ // With Orbit:
204
205
  window.setLocale.map((setLocale) => setLocale("your-lang-code"));
206
+ // Without Orbit:
207
+ window.setLocale("your-lang-code");
205
208
  ```
206
209
 
207
210
  To retrieve the current locale:
208
211
 
209
212
  ```javascript
213
+ // With Orbit:
210
214
  window.getLocale.map((locale) => console.log(locale));
215
+ // Without Orbit:
216
+ console.log(window.getLocale("your-lang-code"));
211
217
  ```
212
218
 
213
219
  ### Testing
package/biome.json CHANGED
@@ -1,5 +1,6 @@
1
1
  {
2
- "$schema": "https://biomejs.dev/schemas/1.9.3/schema.json",
2
+ "root": false,
3
+ "$schema": "https://biomejs.dev/schemas/2.0.0/schema.json",
3
4
  "vcs": {
4
5
  "enabled": true,
5
6
  "clientKind": "git",
@@ -7,15 +8,13 @@
7
8
  },
8
9
  "files": {
9
10
  "ignoreUnknown": false,
10
- "ignore": []
11
+ "includes": ["**"]
11
12
  },
12
13
  "formatter": {
13
14
  "enabled": true,
14
15
  "indentStyle": "space"
15
16
  },
16
- "organizeImports": {
17
- "enabled": true
18
- },
17
+ "assist": { "actions": { "source": { "organizeImports": "on" } } },
19
18
  "linter": {
20
19
  "enabled": true,
21
20
  "rules": {
@@ -25,6 +24,18 @@
25
24
  },
26
25
  "suspicious": {
27
26
  "noExplicitAny": "off"
27
+ },
28
+ "style": {
29
+ "noParameterAssign": "error",
30
+ "useAsConstAssertion": "error",
31
+ "useDefaultParameterLast": "error",
32
+ "useEnumInitializers": "error",
33
+ "useSelfClosingElements": "error",
34
+ "useSingleVarDeclarator": "error",
35
+ "noUnusedTemplateLiteral": "error",
36
+ "useNumberNamespace": "error",
37
+ "noInferrableTypes": "error",
38
+ "noUselessElse": "error"
28
39
  }
29
40
  }
30
41
  },
package/dist/index.js CHANGED
@@ -3,18 +3,18 @@
3
3
  * Copyright 2019 Google LLC
4
4
  * SPDX-License-Identifier: BSD-3-Clause
5
5
  */
6
- const N = globalThis, Y = N.ShadowRoot && (N.ShadyCSS === void 0 || N.ShadyCSS.nativeShadow) && "adoptedStyleSheets" in Document.prototype && "replace" in CSSStyleSheet.prototype, tt = Symbol(), lt = /* @__PURE__ */ new WeakMap();
6
+ const N = globalThis, et = N.ShadowRoot && (N.ShadyCSS === void 0 || N.ShadyCSS.nativeShadow) && "adoptedStyleSheets" in Document.prototype && "replace" in CSSStyleSheet.prototype, st = Symbol(), ut = /* @__PURE__ */ new WeakMap();
7
7
  let Ct = class {
8
8
  constructor(t, e, r) {
9
- if (this._$cssResult$ = !0, r !== tt) throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");
9
+ if (this._$cssResult$ = !0, r !== st) throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");
10
10
  this.cssText = t, this.t = e;
11
11
  }
12
12
  get styleSheet() {
13
13
  let t = this.o;
14
14
  const e = this.t;
15
- if (Y && t === void 0) {
15
+ if (et && t === void 0) {
16
16
  const r = e !== void 0 && e.length === 1;
17
- r && (t = lt.get(e)), t === void 0 && ((this.o = t = new CSSStyleSheet()).replaceSync(this.cssText), r && lt.set(e, t));
17
+ r && (t = ut.get(e)), t === void 0 && ((this.o = t = new CSSStyleSheet()).replaceSync(this.cssText), r && ut.set(e, t));
18
18
  }
19
19
  return t;
20
20
  }
@@ -22,33 +22,33 @@ let Ct = class {
22
22
  return this.cssText;
23
23
  }
24
24
  };
25
- const et = (s) => new Ct(typeof s == "string" ? s : s + "", void 0, tt), st = (s, ...t) => {
25
+ const it = (s) => new Ct(typeof s == "string" ? s : s + "", void 0, st), rt = (s, ...t) => {
26
26
  const e = s.length === 1 ? s[0] : t.reduce((r, i, o) => r + ((n) => {
27
27
  if (n._$cssResult$ === !0) return n.cssText;
28
28
  if (typeof n == "number") return n;
29
29
  throw Error("Value passed to 'css' function must be a 'css' function result: " + n + ". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.");
30
30
  })(i) + s[o + 1], s[0]);
31
- return new Ct(e, s, tt);
32
- }, zt = (s, t) => {
33
- if (Y) s.adoptedStyleSheets = t.map((e) => e instanceof CSSStyleSheet ? e : e.styleSheet);
31
+ return new Ct(e, s, st);
32
+ }, Vt = (s, t) => {
33
+ if (et) s.adoptedStyleSheets = t.map((e) => e instanceof CSSStyleSheet ? e : e.styleSheet);
34
34
  else for (const e of t) {
35
35
  const r = document.createElement("style"), i = N.litNonce;
36
36
  i !== void 0 && r.setAttribute("nonce", i), r.textContent = e.cssText, s.appendChild(r);
37
37
  }
38
- }, ct = Y ? (s) => s : (s) => s instanceof CSSStyleSheet ? ((t) => {
38
+ }, dt = et ? (s) => s : (s) => s instanceof CSSStyleSheet ? ((t) => {
39
39
  let e = "";
40
40
  for (const r of t.cssRules) e += r.cssText;
41
- return et(e);
41
+ return it(e);
42
42
  })(s) : s;
43
43
  /**
44
44
  * @license
45
45
  * Copyright 2017 Google LLC
46
46
  * SPDX-License-Identifier: BSD-3-Clause
47
47
  */
48
- const { is: Vt, defineProperty: Bt, getOwnPropertyDescriptor: Wt, getOwnPropertyNames: Ft, getOwnPropertySymbols: Kt, getPrototypeOf: Xt } = Object, B = globalThis, ut = B.trustedTypes, Jt = ut ? ut.emptyScript : "", Zt = B.reactiveElementPolyfillSupport, O = (s, t) => s, D = { toAttribute(s, t) {
48
+ const { is: Bt, defineProperty: Wt, getOwnPropertyDescriptor: Ft, getOwnPropertyNames: Kt, getOwnPropertySymbols: Xt, getPrototypeOf: Jt } = Object, B = globalThis, pt = B.trustedTypes, Zt = pt ? pt.emptyScript : "", Gt = B.reactiveElementPolyfillSupport, O = (s, t) => s, D = { toAttribute(s, t) {
49
49
  switch (t) {
50
50
  case Boolean:
51
- s = s ? Jt : null;
51
+ s = s ? Zt : null;
52
52
  break;
53
53
  case Object:
54
54
  case Array:
@@ -73,7 +73,7 @@ const { is: Vt, defineProperty: Bt, getOwnPropertyDescriptor: Wt, getOwnProperty
73
73
  }
74
74
  }
75
75
  return e;
76
- } }, W = (s, t) => !Vt(s, t), dt = { attribute: !0, type: String, converter: D, reflect: !1, useDefault: !1, hasChanged: W };
76
+ } }, W = (s, t) => !Bt(s, t), ft = { attribute: !0, type: String, converter: D, reflect: !1, useDefault: !1, hasChanged: W };
77
77
  Symbol.metadata ??= Symbol("metadata"), B.litPropertyMetadata ??= /* @__PURE__ */ new WeakMap();
78
78
  let E = class extends HTMLElement {
79
79
  static addInitializer(t) {
@@ -82,14 +82,14 @@ let E = class extends HTMLElement {
82
82
  static get observedAttributes() {
83
83
  return this.finalize(), this._$Eh && [...this._$Eh.keys()];
84
84
  }
85
- static createProperty(t, e = dt) {
85
+ static createProperty(t, e = ft) {
86
86
  if (e.state && (e.attribute = !1), this._$Ei(), this.prototype.hasOwnProperty(t) && ((e = Object.create(e)).wrapped = !0), this.elementProperties.set(t, e), !e.noAccessor) {
87
87
  const r = Symbol(), i = this.getPropertyDescriptor(t, r, e);
88
- i !== void 0 && Bt(this.prototype, t, i);
88
+ i !== void 0 && Wt(this.prototype, t, i);
89
89
  }
90
90
  }
91
91
  static getPropertyDescriptor(t, e, r) {
92
- const { get: i, set: o } = Wt(this.prototype, t) ?? { get() {
92
+ const { get: i, set: o } = Ft(this.prototype, t) ?? { get() {
93
93
  return this[e];
94
94
  }, set(n) {
95
95
  this[e] = n;
@@ -100,17 +100,17 @@ let E = class extends HTMLElement {
100
100
  }, configurable: !0, enumerable: !0 };
101
101
  }
102
102
  static getPropertyOptions(t) {
103
- return this.elementProperties.get(t) ?? dt;
103
+ return this.elementProperties.get(t) ?? ft;
104
104
  }
105
105
  static _$Ei() {
106
106
  if (this.hasOwnProperty(O("elementProperties"))) return;
107
- const t = Xt(this);
107
+ const t = Jt(this);
108
108
  t.finalize(), t.l !== void 0 && (this.l = [...t.l]), this.elementProperties = new Map(t.elementProperties);
109
109
  }
110
110
  static finalize() {
111
111
  if (this.hasOwnProperty(O("finalized"))) return;
112
112
  if (this.finalized = !0, this._$Ei(), this.hasOwnProperty(O("properties"))) {
113
- const e = this.properties, r = [...Ft(e), ...Kt(e)];
113
+ const e = this.properties, r = [...Kt(e), ...Xt(e)];
114
114
  for (const i of r) this.createProperty(i, e[i]);
115
115
  }
116
116
  const t = this[Symbol.metadata];
@@ -129,8 +129,8 @@ let E = class extends HTMLElement {
129
129
  const e = [];
130
130
  if (Array.isArray(t)) {
131
131
  const r = new Set(t.flat(1 / 0).reverse());
132
- for (const i of r) e.unshift(ct(i));
133
- } else t !== void 0 && e.push(ct(t));
132
+ for (const i of r) e.unshift(dt(i));
133
+ } else t !== void 0 && e.push(dt(t));
134
134
  return e;
135
135
  }
136
136
  static _$Eu(t, e) {
@@ -156,7 +156,7 @@ let E = class extends HTMLElement {
156
156
  }
157
157
  createRenderRoot() {
158
158
  const t = this.shadowRoot ?? this.attachShadow(this.constructor.shadowRootOptions);
159
- return zt(t, this.constructor.elementStyles), t;
159
+ return Vt(t, this.constructor.elementStyles), t;
160
160
  }
161
161
  connectedCallback() {
162
162
  this.renderRoot ??= this.createRenderRoot(), this.enableUpdating(!0), this._$EO?.forEach((t) => t.hostConnected?.());
@@ -254,53 +254,53 @@ let E = class extends HTMLElement {
254
254
  firstUpdated(t) {
255
255
  }
256
256
  };
257
- E.elementStyles = [], E.shadowRootOptions = { mode: "open" }, E[O("elementProperties")] = /* @__PURE__ */ new Map(), E[O("finalized")] = /* @__PURE__ */ new Map(), Zt?.({ ReactiveElement: E }), (B.reactiveElementVersions ??= []).push("2.1.0");
257
+ E.elementStyles = [], E.shadowRootOptions = { mode: "open" }, E[O("elementProperties")] = /* @__PURE__ */ new Map(), E[O("finalized")] = /* @__PURE__ */ new Map(), Gt?.({ ReactiveElement: E }), (B.reactiveElementVersions ??= []).push("2.1.0");
258
258
  /**
259
259
  * @license
260
260
  * Copyright 2017 Google LLC
261
261
  * SPDX-License-Identifier: BSD-3-Clause
262
262
  */
263
- const it = globalThis, q = it.trustedTypes, pt = q ? q.createPolicy("lit-html", { createHTML: (s) => s }) : void 0, Pt = "$lit$", y = `lit$${Math.random().toFixed(9).slice(2)}$`, Rt = "?" + y, Gt = `<${Rt}>`, w = document, x = () => w.createComment(""), j = (s) => s === null || typeof s != "object" && typeof s != "function", rt = Array.isArray, Qt = (s) => rt(s) || typeof s?.[Symbol.iterator] == "function", K = `[
264
- \f\r]`, R = /<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g, ft = /-->/g, _t = />/g, b = RegExp(`>|${K}(?:([^\\s"'>=/]+)(${K}*=${K}*(?:[^
265
- \f\r"'\`<>=]|("|')|))|$)`, "g"), $t = /'/g, gt = /"/g, Ot = /^(?:script|style|textarea|title)$/i, Yt = (s) => (t, ...e) => ({ _$litType$: s, strings: t, values: e }), T = Yt(1), C = Symbol.for("lit-noChange"), c = Symbol.for("lit-nothing"), yt = /* @__PURE__ */ new WeakMap(), A = w.createTreeWalker(w, 129);
266
- function xt(s, t) {
267
- if (!rt(s) || !s.hasOwnProperty("raw")) throw Error("invalid template strings array");
268
- return pt !== void 0 ? pt.createHTML(t) : t;
263
+ const ot = globalThis, q = ot.trustedTypes, _t = q ? q.createPolicy("lit-html", { createHTML: (s) => s }) : void 0, Pt = "$lit$", y = `lit$${Math.random().toFixed(9).slice(2)}$`, Rt = "?" + y, Qt = `<${Rt}>`, A = document, j = () => A.createComment(""), x = (s) => s === null || typeof s != "object" && typeof s != "function", nt = Array.isArray, Yt = (s) => nt(s) || typeof s?.[Symbol.iterator] == "function", K = `[
264
+ \f\r]`, R = /<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g, $t = /-->/g, gt = />/g, b = RegExp(`>|${K}(?:([^\\s"'>=/]+)(${K}*=${K}*(?:[^
265
+ \f\r"'\`<>=]|("|')|))|$)`, "g"), yt = /'/g, vt = /"/g, Ot = /^(?:script|style|textarea|title)$/i, te = (s) => (t, ...e) => ({ _$litType$: s, strings: t, values: e }), T = te(1), C = Symbol.for("lit-noChange"), c = Symbol.for("lit-nothing"), bt = /* @__PURE__ */ new WeakMap(), w = A.createTreeWalker(A, 129);
266
+ function jt(s, t) {
267
+ if (!nt(s) || !s.hasOwnProperty("raw")) throw Error("invalid template strings array");
268
+ return _t !== void 0 ? _t.createHTML(t) : t;
269
269
  }
270
- const te = (s, t) => {
270
+ const ee = (s, t) => {
271
271
  const e = s.length - 1, r = [];
272
272
  let i, o = t === 2 ? "<svg>" : t === 3 ? "<math>" : "", n = R;
273
273
  for (let h = 0; h < e; h++) {
274
274
  const a = s[h];
275
275
  let u, d, l = -1, f = 0;
276
- for (; f < a.length && (n.lastIndex = f, d = n.exec(a), d !== null); ) f = n.lastIndex, n === R ? d[1] === "!--" ? n = ft : d[1] !== void 0 ? n = _t : d[2] !== void 0 ? (Ot.test(d[2]) && (i = RegExp("</" + d[2], "g")), n = b) : d[3] !== void 0 && (n = b) : n === b ? d[0] === ">" ? (n = i ?? R, l = -1) : d[1] === void 0 ? l = -2 : (l = n.lastIndex - d[2].length, u = d[1], n = d[3] === void 0 ? b : d[3] === '"' ? gt : $t) : n === gt || n === $t ? n = b : n === ft || n === _t ? n = R : (n = b, i = void 0);
276
+ for (; f < a.length && (n.lastIndex = f, d = n.exec(a), d !== null); ) f = n.lastIndex, n === R ? d[1] === "!--" ? n = $t : d[1] !== void 0 ? n = gt : d[2] !== void 0 ? (Ot.test(d[2]) && (i = RegExp("</" + d[2], "g")), n = b) : d[3] !== void 0 && (n = b) : n === b ? d[0] === ">" ? (n = i ?? R, l = -1) : d[1] === void 0 ? l = -2 : (l = n.lastIndex - d[2].length, u = d[1], n = d[3] === void 0 ? b : d[3] === '"' ? vt : yt) : n === vt || n === yt ? n = b : n === $t || n === gt ? n = R : (n = b, i = void 0);
277
277
  const g = n === b && s[h + 1].startsWith("/>") ? " " : "";
278
- o += n === R ? a + Gt : l >= 0 ? (r.push(u), a.slice(0, l) + Pt + a.slice(l) + y + g) : a + y + (l === -2 ? h : g);
278
+ o += n === R ? a + Qt : l >= 0 ? (r.push(u), a.slice(0, l) + Pt + a.slice(l) + y + g) : a + y + (l === -2 ? h : g);
279
279
  }
280
- return [xt(s, o + (s[e] || "<?>") + (t === 2 ? "</svg>" : t === 3 ? "</math>" : "")), r];
280
+ return [jt(s, o + (s[e] || "<?>") + (t === 2 ? "</svg>" : t === 3 ? "</math>" : "")), r];
281
281
  };
282
282
  class L {
283
283
  constructor({ strings: t, _$litType$: e }, r) {
284
284
  let i;
285
285
  this.parts = [];
286
286
  let o = 0, n = 0;
287
- const h = t.length - 1, a = this.parts, [u, d] = te(t, e);
288
- if (this.el = L.createElement(u, r), A.currentNode = this.el.content, e === 2 || e === 3) {
287
+ const h = t.length - 1, a = this.parts, [u, d] = ee(t, e);
288
+ if (this.el = L.createElement(u, r), w.currentNode = this.el.content, e === 2 || e === 3) {
289
289
  const l = this.el.content.firstChild;
290
290
  l.replaceWith(...l.childNodes);
291
291
  }
292
- for (; (i = A.nextNode()) !== null && a.length < h; ) {
292
+ for (; (i = w.nextNode()) !== null && a.length < h; ) {
293
293
  if (i.nodeType === 1) {
294
294
  if (i.hasAttributes()) for (const l of i.getAttributeNames()) if (l.endsWith(Pt)) {
295
295
  const f = d[n++], g = i.getAttribute(l).split(y), M = /([.?@])?(.*)/.exec(f);
296
- a.push({ type: 1, index: o, name: M[2], strings: g, ctor: M[1] === "." ? se : M[1] === "?" ? ie : M[1] === "@" ? re : F }), i.removeAttribute(l);
296
+ a.push({ type: 1, index: o, name: M[2], strings: g, ctor: M[1] === "." ? ie : M[1] === "?" ? re : M[1] === "@" ? oe : F }), i.removeAttribute(l);
297
297
  } else l.startsWith(y) && (a.push({ type: 6, index: o }), i.removeAttribute(l));
298
298
  if (Ot.test(i.tagName)) {
299
299
  const l = i.textContent.split(y), f = l.length - 1;
300
300
  if (f > 0) {
301
301
  i.textContent = q ? q.emptyScript : "";
302
- for (let g = 0; g < f; g++) i.append(l[g], x()), A.nextNode(), a.push({ type: 2, index: ++o });
303
- i.append(l[f], x());
302
+ for (let g = 0; g < f; g++) i.append(l[g], j()), w.nextNode(), a.push({ type: 2, index: ++o });
303
+ i.append(l[f], j());
304
304
  }
305
305
  }
306
306
  } else if (i.nodeType === 8) if (i.data === Rt) a.push({ type: 2, index: o });
@@ -312,17 +312,17 @@ class L {
312
312
  }
313
313
  }
314
314
  static createElement(t, e) {
315
- const r = w.createElement("template");
315
+ const r = A.createElement("template");
316
316
  return r.innerHTML = t, r;
317
317
  }
318
318
  }
319
319
  function P(s, t, e = s, r) {
320
320
  if (t === C) return t;
321
321
  let i = r !== void 0 ? e._$Co?.[r] : e._$Cl;
322
- const o = j(t) ? void 0 : t._$litDirective$;
322
+ const o = x(t) ? void 0 : t._$litDirective$;
323
323
  return i?.constructor !== o && (i?._$AO?.(!1), o === void 0 ? i = void 0 : (i = new o(s), i._$AT(s, e, r)), r !== void 0 ? (e._$Co ??= [])[r] = i : e._$Cl = i), i !== void 0 && (t = P(s, i._$AS(s, t.values), i, r)), t;
324
324
  }
325
- class ee {
325
+ class se {
326
326
  constructor(t, e) {
327
327
  this._$AV = [], this._$AN = void 0, this._$AD = t, this._$AM = e;
328
328
  }
@@ -333,17 +333,17 @@ class ee {
333
333
  return this._$AM._$AU;
334
334
  }
335
335
  u(t) {
336
- const { el: { content: e }, parts: r } = this._$AD, i = (t?.creationScope ?? w).importNode(e, !0);
337
- A.currentNode = i;
338
- let o = A.nextNode(), n = 0, h = 0, a = r[0];
336
+ const { el: { content: e }, parts: r } = this._$AD, i = (t?.creationScope ?? A).importNode(e, !0);
337
+ w.currentNode = i;
338
+ let o = w.nextNode(), n = 0, h = 0, a = r[0];
339
339
  for (; a !== void 0; ) {
340
340
  if (n === a.index) {
341
341
  let u;
342
- a.type === 2 ? u = new U(o, o.nextSibling, this, t) : a.type === 1 ? u = new a.ctor(o, a.name, a.strings, this, t) : a.type === 6 && (u = new oe(o, this, t)), this._$AV.push(u), a = r[++h];
342
+ a.type === 2 ? u = new U(o, o.nextSibling, this, t) : a.type === 1 ? u = new a.ctor(o, a.name, a.strings, this, t) : a.type === 6 && (u = new ne(o, this, t)), this._$AV.push(u), a = r[++h];
343
343
  }
344
- n !== a?.index && (o = A.nextNode(), n++);
344
+ n !== a?.index && (o = w.nextNode(), n++);
345
345
  }
346
- return A.currentNode = w, i;
346
+ return w.currentNode = A, i;
347
347
  }
348
348
  p(t) {
349
349
  let e = 0;
@@ -369,7 +369,7 @@ class U {
369
369
  return this._$AB;
370
370
  }
371
371
  _$AI(t, e = this) {
372
- t = P(this, t, e), j(t) ? t === c || t == null || t === "" ? (this._$AH !== c && this._$AR(), this._$AH = c) : t !== this._$AH && t !== C && this._(t) : t._$litType$ !== void 0 ? this.$(t) : t.nodeType !== void 0 ? this.T(t) : Qt(t) ? this.k(t) : this._(t);
372
+ t = P(this, t, e), x(t) ? t === c || t == null || t === "" ? (this._$AH !== c && this._$AR(), this._$AH = c) : t !== this._$AH && t !== C && this._(t) : t._$litType$ !== void 0 ? this.$(t) : t.nodeType !== void 0 ? this.T(t) : Yt(t) ? this.k(t) : this._(t);
373
373
  }
374
374
  O(t) {
375
375
  return this._$AA.parentNode.insertBefore(t, this._$AB);
@@ -378,25 +378,25 @@ class U {
378
378
  this._$AH !== t && (this._$AR(), this._$AH = this.O(t));
379
379
  }
380
380
  _(t) {
381
- this._$AH !== c && j(this._$AH) ? this._$AA.nextSibling.data = t : this.T(w.createTextNode(t)), this._$AH = t;
381
+ this._$AH !== c && x(this._$AH) ? this._$AA.nextSibling.data = t : this.T(A.createTextNode(t)), this._$AH = t;
382
382
  }
383
383
  $(t) {
384
- const { values: e, _$litType$: r } = t, i = typeof r == "number" ? this._$AC(t) : (r.el === void 0 && (r.el = L.createElement(xt(r.h, r.h[0]), this.options)), r);
384
+ const { values: e, _$litType$: r } = t, i = typeof r == "number" ? this._$AC(t) : (r.el === void 0 && (r.el = L.createElement(jt(r.h, r.h[0]), this.options)), r);
385
385
  if (this._$AH?._$AD === i) this._$AH.p(e);
386
386
  else {
387
- const o = new ee(i, this), n = o.u(this.options);
387
+ const o = new se(i, this), n = o.u(this.options);
388
388
  o.p(e), this.T(n), this._$AH = o;
389
389
  }
390
390
  }
391
391
  _$AC(t) {
392
- let e = yt.get(t.strings);
393
- return e === void 0 && yt.set(t.strings, e = new L(t)), e;
392
+ let e = bt.get(t.strings);
393
+ return e === void 0 && bt.set(t.strings, e = new L(t)), e;
394
394
  }
395
395
  k(t) {
396
- rt(this._$AH) || (this._$AH = [], this._$AR());
396
+ nt(this._$AH) || (this._$AH = [], this._$AR());
397
397
  const e = this._$AH;
398
398
  let r, i = 0;
399
- for (const o of t) i === e.length ? e.push(r = new U(this.O(x()), this.O(x()), this, this.options)) : r = e[i], r._$AI(o), i++;
399
+ for (const o of t) i === e.length ? e.push(r = new U(this.O(j()), this.O(j()), this, this.options)) : r = e[i], r._$AI(o), i++;
400
400
  i < e.length && (this._$AR(r && r._$AB.nextSibling, i), e.length = i);
401
401
  }
402
402
  _$AR(t = this._$AA.nextSibling, e) {
@@ -422,11 +422,11 @@ class F {
422
422
  _$AI(t, e = this, r, i) {
423
423
  const o = this.strings;
424
424
  let n = !1;
425
- if (o === void 0) t = P(this, t, e, 0), n = !j(t) || t !== this._$AH && t !== C, n && (this._$AH = t);
425
+ if (o === void 0) t = P(this, t, e, 0), n = !x(t) || t !== this._$AH && t !== C, n && (this._$AH = t);
426
426
  else {
427
427
  const h = t;
428
428
  let a, u;
429
- for (t = o[0], a = 0; a < o.length - 1; a++) u = P(this, h[r + a], e, a), u === C && (u = this._$AH[a]), n ||= !j(u) || u !== this._$AH[a], u === c ? t = c : t !== c && (t += (u ?? "") + o[a + 1]), this._$AH[a] = u;
429
+ for (t = o[0], a = 0; a < o.length - 1; a++) u = P(this, h[r + a], e, a), u === C && (u = this._$AH[a]), n ||= !x(u) || u !== this._$AH[a], u === c ? t = c : t !== c && (t += (u ?? "") + o[a + 1]), this._$AH[a] = u;
430
430
  }
431
431
  n && !i && this.j(t);
432
432
  }
@@ -434,7 +434,7 @@ class F {
434
434
  t === c ? this.element.removeAttribute(this.name) : this.element.setAttribute(this.name, t ?? "");
435
435
  }
436
436
  }
437
- class se extends F {
437
+ class ie extends F {
438
438
  constructor() {
439
439
  super(...arguments), this.type = 3;
440
440
  }
@@ -442,7 +442,7 @@ class se extends F {
442
442
  this.element[this.name] = t === c ? void 0 : t;
443
443
  }
444
444
  }
445
- class ie extends F {
445
+ class re extends F {
446
446
  constructor() {
447
447
  super(...arguments), this.type = 4;
448
448
  }
@@ -450,7 +450,7 @@ class ie extends F {
450
450
  this.element.toggleAttribute(this.name, !!t && t !== c);
451
451
  }
452
452
  }
453
- class re extends F {
453
+ class oe extends F {
454
454
  constructor(t, e, r, i, o) {
455
455
  super(t, e, r, i, o), this.type = 5;
456
456
  }
@@ -463,7 +463,7 @@ class re extends F {
463
463
  typeof this._$AH == "function" ? this._$AH.call(this.options?.host ?? this.element, t) : this._$AH.handleEvent(t);
464
464
  }
465
465
  }
466
- class oe {
466
+ class ne {
467
467
  constructor(t, e, r) {
468
468
  this.element = t, this.type = 6, this._$AN = void 0, this._$AM = e, this.options = r;
469
469
  }
@@ -474,14 +474,14 @@ class oe {
474
474
  P(this, t);
475
475
  }
476
476
  }
477
- const ne = it.litHtmlPolyfillSupport;
478
- ne?.(L, U), (it.litHtmlVersions ??= []).push("3.3.0");
479
- const ae = (s, t, e) => {
477
+ const ae = ot.litHtmlPolyfillSupport;
478
+ ae?.(L, U), (ot.litHtmlVersions ??= []).push("3.3.0");
479
+ const he = (s, t, e) => {
480
480
  const r = e?.renderBefore ?? t;
481
481
  let i = r._$litPart$;
482
482
  if (i === void 0) {
483
483
  const o = e?.renderBefore ?? null;
484
- r._$litPart$ = i = new U(t.insertBefore(x(), o), o, void 0, e ?? {});
484
+ r._$litPart$ = i = new U(t.insertBefore(j(), o), o, void 0, e ?? {});
485
485
  }
486
486
  return i._$AI(s), i;
487
487
  };
@@ -490,7 +490,7 @@ const ae = (s, t, e) => {
490
490
  * Copyright 2017 Google LLC
491
491
  * SPDX-License-Identifier: BSD-3-Clause
492
492
  */
493
- const ot = globalThis;
493
+ const at = globalThis;
494
494
  let S = class extends E {
495
495
  constructor() {
496
496
  super(...arguments), this.renderOptions = { host: this }, this._$Do = void 0;
@@ -501,7 +501,7 @@ let S = class extends E {
501
501
  }
502
502
  update(t) {
503
503
  const e = this.render();
504
- this.hasUpdated || (this.renderOptions.isConnected = this.isConnected), super.update(t), this._$Do = ae(e, this.renderRoot, this.renderOptions);
504
+ this.hasUpdated || (this.renderOptions.isConnected = this.isConnected), super.update(t), this._$Do = he(e, this.renderRoot, this.renderOptions);
505
505
  }
506
506
  connectedCallback() {
507
507
  super.connectedCallback(), this._$Do?.setConnected(!0);
@@ -513,16 +513,16 @@ let S = class extends E {
513
513
  return C;
514
514
  }
515
515
  };
516
- S._$litElement$ = !0, S.finalized = !0, ot.litElementHydrateSupport?.({ LitElement: S });
517
- const he = ot.litElementPolyfillSupport;
518
- he?.({ LitElement: S });
519
- (ot.litElementVersions ??= []).push("4.2.0");
516
+ S._$litElement$ = !0, S.finalized = !0, at.litElementHydrateSupport?.({ LitElement: S });
517
+ const le = at.litElementPolyfillSupport;
518
+ le?.({ LitElement: S });
519
+ (at.litElementVersions ??= []).push("4.2.0");
520
520
  /**
521
521
  * @license
522
522
  * Copyright 2017 Google LLC
523
523
  * SPDX-License-Identifier: BSD-3-Clause
524
524
  */
525
- const nt = (s) => (t, e) => {
525
+ const ht = (s) => (t, e) => {
526
526
  e !== void 0 ? e.addInitializer(() => {
527
527
  customElements.define(s, t);
528
528
  }) : customElements.define(s, t);
@@ -532,7 +532,7 @@ const nt = (s) => (t, e) => {
532
532
  * Copyright 2017 Google LLC
533
533
  * SPDX-License-Identifier: BSD-3-Clause
534
534
  */
535
- const le = { attribute: !0, type: String, converter: D, reflect: !1, hasChanged: W }, ce = (s = le, t, e) => {
535
+ const ce = { attribute: !0, type: String, converter: D, reflect: !1, hasChanged: W }, ue = (s = ce, t, e) => {
536
536
  const { kind: r, metadata: i } = e;
537
537
  let o = globalThis.litPropertyMetadata.get(i);
538
538
  if (o === void 0 && globalThis.litPropertyMetadata.set(i, o = /* @__PURE__ */ new Map()), r === "setter" && ((s = Object.create(s)).wrapped = !0), o.set(e.name, s), r === "accessor") {
@@ -554,7 +554,7 @@ const le = { attribute: !0, type: String, converter: D, reflect: !1, hasChanged:
554
554
  throw Error("Unsupported decorator location: " + r);
555
555
  };
556
556
  function p(s) {
557
- return (t, e) => typeof e == "object" ? ce(s, t, e) : ((r, i, o) => {
557
+ return (t, e) => typeof e == "object" ? ue(s, t, e) : ((r, i, o) => {
558
558
  const n = i.hasOwnProperty(o);
559
559
  return i.constructor.createProperty(o, r), n ? Object.getOwnPropertyDescriptor(i, o) : void 0;
560
560
  })(s, t, e);
@@ -564,7 +564,7 @@ function p(s) {
564
564
  * Copyright 2017 Google LLC
565
565
  * SPDX-License-Identifier: BSD-3-Clause
566
566
  */
567
- function jt(s) {
567
+ function xt(s) {
568
568
  return p({ ...s, state: !0, attribute: !1 });
569
569
  }
570
570
  /**
@@ -572,8 +572,8 @@ function jt(s) {
572
572
  * Copyright 2017 Google LLC
573
573
  * SPDX-License-Identifier: BSD-3-Clause
574
574
  */
575
- const ue = Symbol();
576
- class de {
575
+ const de = Symbol();
576
+ class pe {
577
577
  get taskComplete() {
578
578
  return this.t || (this.i === 1 ? this.t = new Promise((t, e) => {
579
579
  this.o = t, this.h = e;
@@ -582,7 +582,7 @@ class de {
582
582
  constructor(t, e, r) {
583
583
  this.p = 0, this.i = 0, (this._ = t).addController(this);
584
584
  const i = typeof e == "object" ? e : { task: e, args: r };
585
- this.v = i.task, this.j = i.args, this.m = i.argsEqual ?? pe, this.k = i.onComplete, this.A = i.onError, this.autoRun = i.autoRun ?? !0, "initialValue" in i && (this.u = i.initialValue, this.i = 2, this.O = this.T?.());
585
+ this.v = i.task, this.j = i.args, this.m = i.argsEqual ?? fe, this.k = i.onComplete, this.A = i.onError, this.autoRun = i.autoRun ?? !0, "initialValue" in i && (this.u = i.initialValue, this.i = 2, this.O = this.T?.());
586
586
  }
587
587
  hostUpdate() {
588
588
  this.autoRun === !0 && this.S();
@@ -612,7 +612,7 @@ class de {
612
612
  o = !0, r = n;
613
613
  }
614
614
  if (this.p === i) {
615
- if (e === ue) this.i = 0;
615
+ if (e === de) this.i = 0;
616
616
  else {
617
617
  if (o === !1) {
618
618
  try {
@@ -659,31 +659,31 @@ class de {
659
659
  }
660
660
  }
661
661
  }
662
- const pe = (s, t) => s === t || s.length === t.length && s.every((e, r) => !W(e, t[r]));
662
+ const fe = (s, t) => s === t || s.length === t.length && s.every((e, r) => !W(e, t[r]));
663
663
  !window.orbit && !"/".includes("cypress") && await new Promise((s) => {
664
664
  document.addEventListener("orbit-ready", () => {
665
665
  s(!0);
666
666
  });
667
667
  });
668
- var fe = Object.defineProperty, _e = (s, t, e, r) => {
668
+ var _e = Object.defineProperty, $e = (s, t, e, r) => {
669
669
  for (var i = void 0, o = s.length - 1, n; o >= 0; o--)
670
670
  (n = s[o]) && (i = n(t, e, i) || i);
671
- return i && fe(t, e, i), i;
671
+ return i && _e(t, e, i), i;
672
672
  };
673
- class at extends S {
673
+ class lt extends S {
674
674
  constructor() {
675
675
  super(...arguments), this.objects = [], this.hasType = (t, e = this.objects) => new Set(e.flatMap((i) => i["@type"])).has(t);
676
676
  }
677
677
  }
678
- _e([
678
+ $e([
679
679
  p({ attribute: !1 })
680
- ], at.prototype, "objects");
681
- var $e = Object.defineProperty, v = (s, t, e, r) => {
680
+ ], lt.prototype, "objects");
681
+ var ge = Object.defineProperty, v = (s, t, e, r) => {
682
682
  for (var i = void 0, o = s.length - 1, n; o >= 0; o--)
683
683
  (n = s[o]) && (i = n(t, e, i) || i);
684
- return i && $e(t, e, i), i;
684
+ return i && ge(t, e, i), i;
685
685
  };
686
- class $ extends at {
686
+ class $ extends lt {
687
687
  constructor({
688
688
  defaultRoute: t = !1,
689
689
  setupSubscriptions: e = !0,
@@ -700,7 +700,7 @@ class $ extends at {
700
700
  document.readyState !== "complete" ? document.addEventListener("DOMContentLoaded", i) : i();
701
701
  }
702
702
  async _attach(t, e, r) {
703
- return !this.orbit && window.orbit && (this.orbit = window.orbit, e) ? (ve({
703
+ return !this.orbit && window.orbit && (this.orbit = window.orbit, e) ? (be({
704
704
  component: this,
705
705
  defaultRoute: t,
706
706
  ignoreRouter: r
@@ -755,9 +755,9 @@ class $ extends at {
755
755
  try {
756
756
  if (t) {
757
757
  let i = t;
758
- if (typeof t == "string" && (i = await window.sibStore.getData(t, bt)), typeof t != "string" && t.isFullResource && (t.isFullResource?.() || (i = await window.sibStore.getData(
758
+ if (typeof t == "string" && (i = await window.sibStore.getData(t, wt)), typeof t != "string" && t.isFullResource && (t.isFullResource?.() || (i = await window.sibStore.getData(
759
759
  t["@id"],
760
- bt
760
+ wt
761
761
  ))), typeof t != "string" && !t.isFullResource && (i.properties = Object.keys(i), i.get = (o) => i[o]), !i) return { _originalResource: i };
762
762
  if (typeof i == "object" && i !== null) {
763
763
  if (i["ldp:contains"]) {
@@ -798,12 +798,12 @@ v([
798
798
  p({ attribute: !1 })
799
799
  ], $.prototype, "cherryPickedProperties");
800
800
  v([
801
- jt()
801
+ xt()
802
802
  ], $.prototype, "orbit");
803
803
  v([
804
- jt()
804
+ xt()
805
805
  ], $.prototype, "currentRoute");
806
- const ge = (s, { keywords: t = [], attributes: e = ["dataSrc"] } = {}) => {
806
+ const ye = (s, { keywords: t = [], attributes: e = ["dataSrc"] } = {}) => {
807
807
  const r = () => {
808
808
  t && e && (s.caching === void 0 && (s.caching = 0), s.hasCachedDatas === void 0 && (s.hasCachedDatas = !1), s.cacheListener = (i) => {
809
809
  const o = i.detail.id || i.detail.resource["@id"];
@@ -816,15 +816,15 @@ const ge = (s, { keywords: t = [], attributes: e = ["dataSrc"] } = {}) => {
816
816
  };
817
817
  document.readyState !== "complete" ? document.addEventListener("DOMContentLoaded", r) : r();
818
818
  };
819
- function ye() {
819
+ function ve() {
820
820
  return Math.random().toString(16).slice(2);
821
821
  }
822
- const ve = ({
822
+ const be = ({
823
823
  component: s,
824
824
  defaultRoute: t = !1,
825
825
  ignoreRouter: e = !1
826
826
  }) => {
827
- if (s.uniq || (s.uniq = ye(), t && !s.route && !e && (s.route = t)), s._subscriptions = /* @__PURE__ */ new Set(), !e) {
827
+ if (s.uniq || (s.uniq = ve(), t && !s.route && !e && (s.route = t)), s._subscriptions = /* @__PURE__ */ new Set(), !e) {
828
828
  s.route || (s.route = s.uniq, window.orbit && (s.route = window.orbit.getRoute(s.uniq))), s.noRouter = !0;
829
829
  let r = document.querySelector("solid-router");
830
830
  for (; r; )
@@ -849,7 +849,7 @@ const ve = ({
849
849
  document.removeEventListener(r[0], r[1]);
850
850
  }, s._subscribe();
851
851
  };
852
- class be extends S {
852
+ class me extends S {
853
853
  constructor() {
854
854
  super(...arguments), this.object = {
855
855
  "@id": ""
@@ -859,14 +859,14 @@ class be extends S {
859
859
  };
860
860
  }
861
861
  }
862
- const vt = (s, t) => {
862
+ const mt = (s, t) => {
863
863
  let e = s;
864
864
  for (let r = 0; r < t.length && (e && t[r] in e); r++)
865
865
  e = e[t[r]];
866
866
  return e;
867
- }, me = (s, t, e = "asc") => s.sort((r, i) => {
867
+ }, we = (s, t, e = "asc") => s.sort((r, i) => {
868
868
  let o = r, n = i;
869
- Array.isArray(t) ? (o = vt(r, t), n = vt(i, t)) : (o = r[t], n = i[t]);
869
+ Array.isArray(t) ? (o = mt(r, t), n = mt(i, t)) : (o = r[t], n = i[t]);
870
870
  let h = 0;
871
871
  if (typeof o == "number" && typeof n == "number")
872
872
  h = o - n;
@@ -886,31 +886,31 @@ const vt = (s, t) => {
886
886
  }
887
887
  })
888
888
  );
889
- }, bt = {};
890
- var we = Object.getOwnPropertyDescriptor, Ee = (s, t, e, r) => {
891
- for (var i = r > 1 ? void 0 : r ? we(t, e) : t, o = s.length - 1, n; o >= 0; o--)
889
+ }, wt = {};
890
+ var Ee = Object.getOwnPropertyDescriptor, Se = (s, t, e, r) => {
891
+ for (var i = r > 1 ? void 0 : r ? Ee(t, e) : t, o = s.length - 1, n; o >= 0; o--)
892
892
  (n = s[o]) && (i = n(i) || i);
893
893
  return i;
894
894
  };
895
- let Z = class extends $ {
895
+ let Q = class extends $ {
896
896
  constructor() {
897
897
  super(...arguments), this.cherryPickedProperties = [
898
898
  { key: "name", value: "name" }
899
- ], this._getResource = new de(this, {
899
+ ], this._getResource = new pe(this, {
900
900
  task: async ([s]) => {
901
901
  if (!(!s || !this.orbit || !this.noRouter && this.route && this.currentRoute && !this.route.startsWith(this.currentRoute))) {
902
902
  if (!this.hasCachedDatas || this.oldDataSrc !== s) {
903
903
  if (!s) return;
904
904
  this.datas = await this._getProxyValue(s), this.hasCachedDatas = !0;
905
905
  }
906
- return this.oldDataSrc !== s && (this.oldDataSrc = s), me(this.datas, "name", "asc");
906
+ return this.oldDataSrc !== s && (this.oldDataSrc = s), we(this.datas, "name", "asc");
907
907
  }
908
908
  },
909
909
  args: () => [this.dataSrc, this.caching, this.currentRoute]
910
910
  });
911
911
  }
912
912
  async _afterAttach() {
913
- return ge(this, {
913
+ return ye(this, {
914
914
  keywords: ["some-keyword", "for-invalidating", "cache"]
915
915
  }), Promise.resolve();
916
916
  }
@@ -923,7 +923,7 @@ let Z = class extends $ {
923
923
  });
924
924
  }
925
925
  };
926
- Z.styles = st`
926
+ Q.styles = rt`
927
927
  div {
928
928
  background-color: red;
929
929
  position: absolute;
@@ -933,25 +933,25 @@ Z.styles = st`
933
933
  bottom: 0;
934
934
  }
935
935
  `;
936
- Z = Ee([
937
- nt("solid-boilerplate")
938
- ], Z);
936
+ Q = Se([
937
+ ht("solid-boilerplate")
938
+ ], Q);
939
939
  /**
940
940
  * @license
941
941
  * Copyright 2021 Google LLC
942
942
  * SPDX-License-Identifier: BSD-3-Clause
943
943
  */
944
- const G = "lit-localize-status";
944
+ const Y = "lit-localize-status";
945
945
  /**
946
946
  * @license
947
947
  * Copyright 2021 Google LLC
948
948
  * SPDX-License-Identifier: BSD-3-Clause
949
949
  */
950
- const Se = (s, ...t) => ({
950
+ const Ce = (s, ...t) => ({
951
951
  strTag: !0,
952
952
  strings: s,
953
953
  values: t
954
- }), Ce = Se, Pe = (s) => typeof s != "string" && "strTag" in s, Tt = (s, t, e) => {
954
+ }), Tt = Ce, Pe = (s) => typeof s != "string" && "strTag" in s, Lt = (s, t, e) => {
955
955
  let r = s[0];
956
956
  for (let i = 1; i < s.length; i++)
957
957
  r += t[e ? e[i - 1] : i - 1], r += s[i];
@@ -962,12 +962,12 @@ const Se = (s, ...t) => ({
962
962
  * Copyright 2021 Google LLC
963
963
  * SPDX-License-Identifier: BSD-3-Clause
964
964
  */
965
- const Lt = (s) => Pe(s) ? Tt(s.strings, s.values) : s;
966
- let ht = Lt, mt = !1;
965
+ const Ut = (s) => Pe(s) ? Lt(s.strings, s.values) : s;
966
+ let ct = Ut, At = !1;
967
967
  function Re(s) {
968
- if (mt)
968
+ if (At)
969
969
  throw new Error("lit-localize can only be configured once");
970
- ht = s, mt = !0;
970
+ ct = s, At = !0;
971
971
  }
972
972
  /**
973
973
  * @license
@@ -981,25 +981,25 @@ class Oe {
981
981
  }, this.host = t;
982
982
  }
983
983
  hostConnected() {
984
- window.addEventListener(G, this.__litLocalizeEventHandler);
984
+ window.addEventListener(Y, this.__litLocalizeEventHandler);
985
985
  }
986
986
  hostDisconnected() {
987
- window.removeEventListener(G, this.__litLocalizeEventHandler);
987
+ window.removeEventListener(Y, this.__litLocalizeEventHandler);
988
988
  }
989
989
  }
990
- const xe = (s) => s.addController(new Oe(s)), je = xe;
990
+ const je = (s) => s.addController(new Oe(s)), xe = je;
991
991
  /**
992
992
  * @license
993
993
  * Copyright 2021 Google LLC
994
994
  * SPDX-License-Identifier: BSD-3-Clause
995
995
  */
996
- const Ut = () => (s, t) => (s.addInitializer(je), s);
996
+ const Mt = () => (s, t) => (s.addInitializer(xe), s);
997
997
  /**
998
998
  * @license
999
999
  * Copyright 2020 Google LLC
1000
1000
  * SPDX-License-Identifier: BSD-3-Clause
1001
1001
  */
1002
- class Mt {
1002
+ class Ht {
1003
1003
  constructor() {
1004
1004
  this.settled = !1, this.promise = new Promise((t, e) => {
1005
1005
  this._resolve = t, this._reject = e;
@@ -1040,7 +1040,7 @@ function He(s, t) {
1040
1040
  * Copyright 2021 Google LLC
1041
1041
  * SPDX-License-Identifier: BSD-3-Clause
1042
1042
  */
1043
- const At = /* @__PURE__ */ new WeakMap(), wt = /* @__PURE__ */ new Map();
1043
+ const Et = /* @__PURE__ */ new WeakMap(), St = /* @__PURE__ */ new Map();
1044
1044
  function Ne(s, t, e) {
1045
1045
  if (s) {
1046
1046
  const r = e?.id ?? De(t), i = s[r];
@@ -1048,7 +1048,7 @@ function Ne(s, t, e) {
1048
1048
  if (typeof i == "string")
1049
1049
  return i;
1050
1050
  if ("strTag" in i)
1051
- return Tt(
1051
+ return Lt(
1052
1052
  i.strings,
1053
1053
  // Cast `template` because its type wasn't automatically narrowed (but
1054
1054
  // we know it must be the same type as `localized`).
@@ -1056,20 +1056,20 @@ function Ne(s, t, e) {
1056
1056
  i.values
1057
1057
  );
1058
1058
  {
1059
- let o = At.get(i);
1060
- return o === void 0 && (o = i.values, At.set(i, o)), {
1059
+ let o = Et.get(i);
1060
+ return o === void 0 && (o = i.values, Et.set(i, o)), {
1061
1061
  ...i,
1062
1062
  values: o.map((n) => t.values[n])
1063
1063
  };
1064
1064
  }
1065
1065
  }
1066
1066
  }
1067
- return Lt(t);
1067
+ return Ut(t);
1068
1068
  }
1069
1069
  function De(s) {
1070
1070
  const t = typeof s == "string" ? s : s.strings;
1071
- let e = wt.get(t);
1072
- return e === void 0 && (e = He(t, typeof s != "string" && !("strTag" in s)), wt.set(t, e)), e;
1071
+ let e = St.get(t);
1072
+ return e === void 0 && (e = He(t, typeof s != "string" && !("strTag" in s)), St.set(t, e)), e;
1073
1073
  }
1074
1074
  /**
1075
1075
  * @license
@@ -1077,27 +1077,27 @@ function De(s) {
1077
1077
  * SPDX-License-Identifier: BSD-3-Clause
1078
1078
  */
1079
1079
  function X(s) {
1080
- window.dispatchEvent(new CustomEvent(G, { detail: s }));
1080
+ window.dispatchEvent(new CustomEvent(Y, { detail: s }));
1081
1081
  }
1082
- let I = "", J, Ht, k, Q, Nt, m = new Mt();
1082
+ let I = "", J, Nt, k, tt, Dt, m = new Ht();
1083
1083
  m.resolve();
1084
1084
  let H = 0;
1085
- const qe = (s) => (Re((t, e) => Ne(Nt, t, e)), I = Ht = s.sourceLocale, k = new Set(s.targetLocales), k.add(s.sourceLocale), Q = s.loadLocale, { getLocale: Ie, setLocale: ke }), Ie = () => I, ke = (s) => {
1085
+ const qe = (s) => (Re((t, e) => Ne(Dt, t, e)), I = Nt = s.sourceLocale, k = new Set(s.targetLocales), k.add(s.sourceLocale), tt = s.loadLocale, { getLocale: Ie, setLocale: ke }), Ie = () => I, ke = (s) => {
1086
1086
  if (s === (J ?? I))
1087
1087
  return m.promise;
1088
- if (!k || !Q)
1088
+ if (!k || !tt)
1089
1089
  throw new Error("Internal error");
1090
1090
  if (!k.has(s))
1091
1091
  throw new Error("Invalid locale code");
1092
1092
  H++;
1093
1093
  const t = H;
1094
- return J = s, m.settled && (m = new Mt()), X({ status: "loading", loadingLocale: s }), (s === Ht ? (
1094
+ return J = s, m.settled && (m = new Ht()), X({ status: "loading", loadingLocale: s }), (s === Nt ? (
1095
1095
  // We could switch to the source locale synchronously, but we prefer to
1096
1096
  // queue it on a microtask so that switching locales is consistently
1097
1097
  // asynchronous.
1098
1098
  Promise.resolve({ templates: void 0 })
1099
- ) : Q(s)).then((r) => {
1100
- H === t && (I = s, J = void 0, Nt = r.templates, X({ status: "ready", readyLocale: s }), m.resolve());
1099
+ ) : tt(s)).then((r) => {
1100
+ H === t && (I = s, J = void 0, Dt = r.templates, X({ status: "ready", readyLocale: s }), m.resolve());
1101
1101
  }, (r) => {
1102
1102
  H === t && (X({
1103
1103
  status: "error",
@@ -1105,43 +1105,43 @@ const qe = (s) => (Re((t, e) => Ne(Nt, t, e)), I = Ht = s.sourceLocale, k = new
1105
1105
  errorMessage: r.toString()
1106
1106
  }), m.reject(r));
1107
1107
  }), m.promise;
1108
- }, Dt = ":host{background-color:pink;user-select:none}";
1109
- var ze = Object.defineProperty, Ve = Object.getOwnPropertyDescriptor, qt = (s, t, e, r) => {
1108
+ }, qt = ":host{background-color:pink;user-select:none}";
1109
+ var ze = Object.defineProperty, Ve = Object.getOwnPropertyDescriptor, It = (s, t, e, r) => {
1110
1110
  for (var i = r > 1 ? void 0 : r ? Ve(t, e) : t, o = s.length - 1, n; o >= 0; o--)
1111
1111
  (n = s[o]) && (i = (r ? n(t, e, i) : n(i)) || i);
1112
1112
  return r && i && ze(t, e, i), i;
1113
1113
  };
1114
- let z = class extends be {
1114
+ let z = class extends me {
1115
1115
  constructor() {
1116
1116
  super(...arguments), this.object = { "@id": "" };
1117
1117
  }
1118
1118
  render() {
1119
1119
  return this.isType("some:Type") ? c : T`<li>
1120
- ${ht(Ce`Sample object named: ${this.object.name}`)}
1120
+ ${ct(Tt`Sample object named: ${this.object.name}`)}
1121
1121
  </li>`;
1122
1122
  }
1123
1123
  };
1124
- z.styles = st`
1125
- ${et(Dt)}
1124
+ z.styles = rt`
1125
+ ${it(qt)}
1126
1126
  `;
1127
- qt([
1127
+ It([
1128
1128
  p({ attribute: !1, type: Object })
1129
1129
  ], z.prototype, "object", 2);
1130
- z = qt([
1131
- nt("sample-object"),
1132
- Ut()
1130
+ z = It([
1131
+ ht("sample-object"),
1132
+ Mt()
1133
1133
  ], z);
1134
- var Be = Object.defineProperty, We = Object.getOwnPropertyDescriptor, It = (s, t, e, r) => {
1134
+ var Be = Object.defineProperty, We = Object.getOwnPropertyDescriptor, kt = (s, t, e, r) => {
1135
1135
  for (var i = r > 1 ? void 0 : r ? We(t, e) : t, o = s.length - 1, n; o >= 0; o--)
1136
1136
  (n = s[o]) && (i = (r ? n(t, e, i) : n(i)) || i);
1137
1137
  return r && i && Be(t, e, i), i;
1138
1138
  };
1139
- let V = class extends at {
1139
+ let V = class extends lt {
1140
1140
  constructor() {
1141
1141
  super(...arguments), this.objects = [];
1142
1142
  }
1143
1143
  render() {
1144
- return this.hasType("some:Type") ? c : T`${ht("Here are all of our objects:")}<br />
1144
+ return this.hasType("some:Type") ? c : T`${ct("Here are all of our objects:")}<br />
1145
1145
  <ul>
1146
1146
  ${this.objects.map(
1147
1147
  (s) => T`<sample-object .object=${s}></sample-object>`
@@ -1149,27 +1149,33 @@ let V = class extends at {
1149
1149
  </ul>`;
1150
1150
  }
1151
1151
  };
1152
- V.styles = st`
1153
- ${et(Dt)}
1152
+ V.styles = rt`
1153
+ ${it(qt)}
1154
1154
  `;
1155
- It([
1155
+ kt([
1156
1156
  p({ attribute: !1, type: Object })
1157
1157
  ], V.prototype, "objects", 2);
1158
- V = It([
1159
- nt("sample-objects"),
1160
- Ut()
1158
+ V = kt([
1159
+ ht("sample-objects"),
1160
+ Mt()
1161
1161
  ], V);
1162
- const Fe = "en", kt = [
1162
+ const Fe = {
1163
+ s9cb0b52fd65ea225: Tt`Sample object named: ${0}`,
1164
+ se975788b1544119d: "Here are all of our objects:"
1165
+ }, Ke = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1166
+ __proto__: null,
1167
+ templates: Fe
1168
+ }, Symbol.toStringTag, { value: "Module" })), Xe = "en", zt = [
1163
1169
  "en"
1164
- ], Ke = /* @__PURE__ */ Object.assign({}), Xe = new Map(
1165
- kt.map((s) => [
1170
+ ], Je = /* @__PURE__ */ Object.assign({ "../../generated/locales/en.ts": Ke }), Ze = new Map(
1171
+ zt.map((s) => [
1166
1172
  s,
1167
- Ke[`../generated/locales/${s}.ts`]
1173
+ Je[`../../generated/locales/${s}.ts`]
1168
1174
  ])
1169
- ), { getLocale: Et, setLocale: St } = qe({
1170
- sourceLocale: Fe,
1171
- targetLocales: kt,
1172
- loadLocale: async (s) => Xe.get(s)
1175
+ ), { getLocale: Z, setLocale: G } = qe({
1176
+ sourceLocale: Xe,
1177
+ targetLocales: zt,
1178
+ loadLocale: async (s) => Ze.get(s)
1173
1179
  });
1174
- window.getLocale = window.getLocale ? window.getLocale.push(Et) : [Et];
1175
- window.setLocale = window.setLocale ? window.setLocale.push(St) : [St];
1180
+ window.getLocale = window.orbit ? window.getLocale ? window.getLocale.push(Z) : [Z] : Z;
1181
+ window.setLocale = window.orbit ? window.setLocale ? window.setLocale.push(G) : [G] : G;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@startinblox/boilerplate",
3
- "version": "3.0.5",
3
+ "version": "3.1.0",
4
4
  "description": "Startin'blox Boilerplate",
5
5
  "main": "dist/index.js",
6
6
  "type": "module",
@@ -1,12 +1,12 @@
1
1
  import { configureLocalization } from "@lit/localize";
2
2
  import { sourceLocale, targetLocales } from "@src/generated/locale-codes.js";
3
3
 
4
- const langs = import.meta.glob("../generated/locales/**/*.ts", { eager: true });
4
+ const langs = import.meta.glob("../../generated/locales/**/*.ts", { eager: true });
5
5
 
6
6
  const localizedTemplates: Map<string, any> = new Map(
7
7
  targetLocales.map((locale) => [
8
8
  locale,
9
- langs[`../generated/locales/${locale}.ts`],
9
+ langs[`../../generated/locales/${locale}.ts`],
10
10
  ]),
11
11
  );
12
12
 
package/src/index.ts CHANGED
@@ -3,5 +3,5 @@ import "@styles/index.scss";
3
3
  import.meta.glob("./components/**/*.ts", { eager: true });
4
4
  import.meta.glob("./components/**/*.js", { eager: true });
5
5
 
6
- window.getLocale = window.getLocale ? window.getLocale.push(getLocale) : [getLocale];
7
- window.setLocale = window.setLocale ? window.setLocale.push(setLocale) : [setLocale];
6
+ window.getLocale = window.orbit ? window.getLocale ? window.getLocale.push(getLocale) : [getLocale] : getLocale;
7
+ window.setLocale = window.orbit ? window.setLocale ? window.setLocale.push(setLocale) : [setLocale] : setLocale;