@mantou/gem 2.0.0 → 2.1.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.
Files changed (87) hide show
  1. package/dist/gem.es.js +1172 -1188
  2. package/dist/gem.umd.js +25 -25
  3. package/elements/base/gesture.d.ts +1 -2
  4. package/elements/base/gesture.d.ts.map +1 -1
  5. package/elements/base/gesture.js +21 -28
  6. package/elements/base/gesture.js.map +1 -1
  7. package/elements/base/link.d.ts +1 -2
  8. package/elements/base/link.d.ts.map +1 -1
  9. package/elements/base/link.js +17 -10
  10. package/elements/base/link.js.map +1 -1
  11. package/elements/base/modal-factory.d.ts +6 -4
  12. package/elements/base/modal-factory.d.ts.map +1 -1
  13. package/elements/base/modal-factory.js +3 -3
  14. package/elements/base/modal-factory.js.map +1 -1
  15. package/elements/base/route.d.ts +8 -2
  16. package/elements/base/route.d.ts.map +1 -1
  17. package/elements/base/route.js +4 -4
  18. package/elements/base/route.js.map +1 -1
  19. package/elements/base/title.d.ts +0 -1
  20. package/elements/base/title.d.ts.map +1 -1
  21. package/elements/base/title.js +15 -5
  22. package/elements/base/title.js.map +1 -1
  23. package/elements/base/unsafe.d.ts +1 -1
  24. package/elements/base/unsafe.d.ts.map +1 -1
  25. package/elements/base/unsafe.js +10 -4
  26. package/elements/base/unsafe.js.map +1 -1
  27. package/elements/base/use.d.ts +0 -1
  28. package/elements/base/use.d.ts.map +1 -1
  29. package/elements/base/use.js +11 -2
  30. package/elements/base/use.js.map +1 -1
  31. package/helper/i18n.d.ts.map +1 -1
  32. package/helper/i18n.js +11 -11
  33. package/helper/i18n.js.map +1 -1
  34. package/helper/theme.d.ts +8 -7
  35. package/helper/theme.d.ts.map +1 -1
  36. package/helper/theme.js +21 -21
  37. package/helper/theme.js.map +1 -1
  38. package/lib/decorators.d.ts +1 -1
  39. package/lib/decorators.d.ts.map +1 -1
  40. package/lib/decorators.js +3 -3
  41. package/lib/decorators.js.map +1 -1
  42. package/lib/element.d.ts +5 -4
  43. package/lib/element.d.ts.map +1 -1
  44. package/lib/element.js +14 -16
  45. package/lib/element.js.map +1 -1
  46. package/lib/history.d.ts +20 -8
  47. package/lib/history.d.ts.map +1 -1
  48. package/lib/history.js +12 -12
  49. package/lib/history.js.map +1 -1
  50. package/lib/store.d.ts +5 -10
  51. package/lib/store.d.ts.map +1 -1
  52. package/lib/store.js +7 -22
  53. package/lib/store.js.map +1 -1
  54. package/lib/utils.d.ts +1 -0
  55. package/lib/utils.d.ts.map +1 -1
  56. package/lib/utils.js +20 -14
  57. package/lib/utils.js.map +1 -1
  58. package/lib/version.d.ts +1 -1
  59. package/lib/version.d.ts.map +1 -1
  60. package/lib/version.js +1 -2
  61. package/lib/version.js.map +1 -1
  62. package/package.json +3 -4
  63. package/src/elements/base/gesture.ts +23 -25
  64. package/src/elements/base/link.ts +9 -9
  65. package/src/elements/base/modal-factory.ts +3 -3
  66. package/src/elements/base/route.ts +4 -4
  67. package/src/elements/base/title.ts +5 -4
  68. package/src/elements/base/unsafe.ts +6 -3
  69. package/src/elements/base/use.ts +4 -3
  70. package/src/helper/i18n.ts +11 -8
  71. package/src/helper/theme.ts +27 -26
  72. package/src/lib/decorators.ts +4 -4
  73. package/src/lib/element.ts +17 -19
  74. package/src/lib/history.ts +12 -12
  75. package/src/lib/store.ts +11 -31
  76. package/src/lib/utils.ts +22 -14
  77. package/src/lib/version.ts +1 -2
  78. package/src/test/gem-element/advance.test.ts +2 -2
  79. package/src/test/gem-element/basic.test.ts +3 -3
  80. package/src/test/gem-element/decorators.test.ts +4 -4
  81. package/src/test/store.test.ts +7 -7
  82. package/src/test/utils.test.ts +1 -1
  83. package/LICENSE +0 -21
  84. package/helper/react-shim.d.ts +0 -15
  85. package/helper/react-shim.d.ts.map +0 -1
  86. package/helper/react-shim.js +0 -56
  87. package/helper/react-shim.js.map +0 -1
package/dist/gem.es.js CHANGED
@@ -1,20 +1,20 @@
1
- var ka = Object.defineProperty;
2
- var mi = (e) => {
1
+ var Ia = Object.defineProperty;
2
+ var Si = (e) => {
3
3
  throw TypeError(e);
4
4
  };
5
- var xa = (e, t, n) => t in e ? ka(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
6
- var T = (e, t, n) => xa(e, typeof t != "symbol" ? t + "" : t, n), Rn = (e, t, n) => t.has(e) || mi("Cannot " + n);
7
- var p = (e, t, n) => (Rn(e, t, "read from private field"), n ? n.call(e) : t.get(e)), b = (e, t, n) => t.has(e) ? mi("Cannot add the same private member more than once") : t instanceof WeakSet ? t.add(e) : t.set(e, n), x = (e, t, n, s) => (Rn(e, t, "write to private field"), s ? s.call(e, n) : t.set(e, n), n), Hn = (e, t, n) => (Rn(e, t, "access private method"), n);
8
- const Ta = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
5
+ var Ra = (e, t, n) => t in e ? Ia(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
6
+ var O = (e, t, n) => Ra(e, typeof t != "symbol" ? t + "" : t, n), Hn = (e, t, n) => t.has(e) || Si("Cannot " + n);
7
+ var p = (e, t, n) => (Hn(e, t, "read from private field"), n ? n.call(e) : t.get(e)), b = (e, t, n) => t.has(e) ? Si("Cannot add the same private member more than once") : t instanceof WeakSet ? t.add(e) : t.set(e, n), x = (e, t, n, s) => (Hn(e, t, "write to private field"), s ? s.call(e, n) : t.set(e, n), n), Wn = (e, t, n) => (Hn(e, t, "access private method"), n);
8
+ const Ha = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
9
9
  __proto__: null,
10
10
  get adoptedStyle() {
11
- return Rs;
11
+ return Hs;
12
12
  },
13
13
  get aria() {
14
14
  return Ln;
15
15
  },
16
16
  get async() {
17
- return dc;
17
+ return Ec;
18
18
  },
19
19
  get attribute() {
20
20
  return V;
@@ -26,55 +26,55 @@ const Ta = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
26
26
  return Mn;
27
27
  },
28
28
  get customElement() {
29
- return pc;
29
+ return bc;
30
30
  },
31
31
  get effect() {
32
- return $t;
32
+ return St;
33
33
  },
34
34
  get emitter() {
35
- return ye;
35
+ return Se;
36
36
  },
37
37
  get fallback() {
38
- return cc;
38
+ return wc;
39
39
  },
40
40
  get globalemitter() {
41
- return uc;
41
+ return $c;
42
42
  },
43
43
  get light() {
44
- return Mr;
44
+ return Rr;
45
45
  },
46
46
  get memo() {
47
- return Pr;
47
+ return Lr;
48
48
  },
49
49
  get mounted() {
50
50
  return qe;
51
51
  },
52
52
  get numattribute() {
53
- return oc;
53
+ return mc;
54
54
  },
55
55
  get part() {
56
- return Tr;
56
+ return Ar;
57
57
  },
58
58
  get property() {
59
59
  return U;
60
60
  },
61
61
  get shadow() {
62
- return Ht;
62
+ return zt;
63
63
  },
64
64
  get slot() {
65
- return hc;
65
+ return Sc;
66
66
  },
67
67
  get state() {
68
68
  return On;
69
69
  },
70
70
  get template() {
71
- return kr;
71
+ return ae;
72
72
  },
73
73
  get unmounted() {
74
- return ac;
74
+ return vc;
75
75
  },
76
76
  get willMount() {
77
- return Is;
77
+ return Rs;
78
78
  }
79
79
  }, Symbol.toStringTag, { value: "Module" }));
80
80
  /**
@@ -90,10 +90,10 @@ const Ta = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
90
90
  * subject to an additional IP rights grant found at
91
91
  * http://polymer.github.io/PATENTS.txt
92
92
  */
93
- const lr = /* @__PURE__ */ new WeakMap(), Sn = (e) => (...t) => {
93
+ const _r = /* @__PURE__ */ new WeakMap(), Sn = (e) => (...t) => {
94
94
  const n = e(...t);
95
- return lr.set(n, !0), n;
96
- }, Ve = (e) => typeof e == "function" && lr.has(e);
95
+ return _r.set(n, !0), n;
96
+ }, Ve = (e) => typeof e == "function" && _r.has(e);
97
97
  /**
98
98
  * @license
99
99
  * Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
@@ -107,12 +107,12 @@ const lr = /* @__PURE__ */ new WeakMap(), Sn = (e) => (...t) => {
107
107
  * subject to an additional IP rights grant found at
108
108
  * http://polymer.github.io/PATENTS.txt
109
109
  */
110
- const vi = typeof window < "u" && window.customElements != null && window.customElements.polyfillWrapFlushCallback !== void 0, hr = (e, t, n = null, s = null) => {
110
+ const $i = typeof window < "u" && window.customElements != null && window.customElements.polyfillWrapFlushCallback !== void 0, gr = (e, t, n = null, s = null) => {
111
111
  for (; t !== n; ) {
112
112
  const i = t.nextSibling;
113
113
  e.insertBefore(t, s), t = i;
114
114
  }
115
- }, $s = (e, t, n = null) => {
115
+ }, Es = (e, t, n = null) => {
116
116
  for (; t !== n; ) {
117
117
  const s = t.nextSibling;
118
118
  e.removeChild(t), t = s;
@@ -131,7 +131,7 @@ const vi = typeof window < "u" && window.customElements != null && window.custom
131
131
  * subject to an additional IP rights grant found at
132
132
  * http://polymer.github.io/PATENTS.txt
133
133
  */
134
- const it = {}, wi = {};
134
+ const ot = {}, Ei = {};
135
135
  /**
136
136
  * @license
137
137
  * Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
@@ -145,67 +145,67 @@ const it = {}, wi = {};
145
145
  * subject to an additional IP rights grant found at
146
146
  * http://polymer.github.io/PATENTS.txt
147
147
  */
148
- const St = `{{lit-${String(Math.random()).slice(2)}}}`, ur = `<!--${St}-->`, yi = new RegExp(`${St}|${ur}`), we = "$lit$";
149
- class Oa {
148
+ const yt = `{{lit-${String(Math.random()).slice(2)}}}`, mr = `<!--${yt}-->`, bi = new RegExp(`${yt}|${mr}`), ye = "$lit$";
149
+ class Wa {
150
150
  constructor(t, n) {
151
151
  this.parts = [], this.element = n;
152
- const s = [], i = [], o = document.createTreeWalker(n.content, 133, null, !1);
153
- let c = 0, a = -1, f = 0;
154
- const { strings: h, values: { length: m } } = t;
155
- for (; f < m; ) {
156
- const r = o.nextNode();
157
- if (r === null) {
158
- o.currentNode = i.pop();
152
+ const s = [], i = [], r = document.createTreeWalker(n.content, 133, null, !1);
153
+ let c = 0, a = -1, d = 0;
154
+ const { strings: f, values: { length: g } } = t;
155
+ for (; d < g; ) {
156
+ const o = r.nextNode();
157
+ if (o === null) {
158
+ r.currentNode = i.pop();
159
159
  continue;
160
160
  }
161
- if (a++, r.nodeType === 1) {
162
- if (r.hasAttributes()) {
163
- const _ = r.attributes, { length: l } = _;
164
- let g = 0;
165
- for (let v = 0; v < l; v++)
166
- Si(_[v].name, we) && g++;
167
- for (; g-- > 0; ) {
168
- const v = h[f], y = Jn.exec(v)[2], $ = y.toLowerCase() + we, d = r.getAttribute($);
169
- r.removeAttribute($);
170
- const S = d.split(yi);
171
- this.parts.push({ type: "attribute", index: a, name: y, strings: S }), f += S.length - 1;
161
+ if (a++, o.nodeType === 1) {
162
+ if (o.hasAttributes()) {
163
+ const _ = o.attributes, { length: h } = _;
164
+ let m = 0;
165
+ for (let v = 0; v < h; v++)
166
+ Ci(_[v].name, ye) && m++;
167
+ for (; m-- > 0; ) {
168
+ const v = f[d], y = Jn.exec(v)[2], E = y.toLowerCase() + ye, u = o.getAttribute(E);
169
+ o.removeAttribute(E);
170
+ const S = u.split(bi);
171
+ this.parts.push({ type: "attribute", index: a, name: y, strings: S }), d += S.length - 1;
172
172
  }
173
173
  }
174
- r.tagName === "TEMPLATE" && (i.push(r), o.currentNode = r.content);
175
- } else if (r.nodeType === 3) {
176
- const _ = r.data;
177
- if (_.indexOf(St) >= 0) {
178
- const l = r.parentNode, g = _.split(yi), v = g.length - 1;
174
+ o.tagName === "TEMPLATE" && (i.push(o), r.currentNode = o.content);
175
+ } else if (o.nodeType === 3) {
176
+ const _ = o.data;
177
+ if (_.indexOf(yt) >= 0) {
178
+ const h = o.parentNode, m = _.split(bi), v = m.length - 1;
179
179
  for (let y = 0; y < v; y++) {
180
- let $, d = g[y];
181
- if (d === "")
182
- $ = ot();
180
+ let E, u = m[y];
181
+ if (u === "")
182
+ E = ct();
183
183
  else {
184
- const S = Jn.exec(d);
185
- S !== null && Si(S[2], we) && (d = d.slice(0, S.index) + S[1] + S[2].slice(0, -we.length) + S[3]), $ = document.createTextNode(d);
184
+ const S = Jn.exec(u);
185
+ S !== null && Ci(S[2], ye) && (u = u.slice(0, S.index) + S[1] + S[2].slice(0, -ye.length) + S[3]), E = document.createTextNode(u);
186
186
  }
187
- l.insertBefore($, r), this.parts.push({ type: "node", index: ++a });
187
+ h.insertBefore(E, o), this.parts.push({ type: "node", index: ++a });
188
188
  }
189
- g[v] === "" ? (l.insertBefore(ot(), r), s.push(r)) : r.data = g[v], f += v;
189
+ m[v] === "" ? (h.insertBefore(ct(), o), s.push(o)) : o.data = m[v], d += v;
190
190
  }
191
- } else if (r.nodeType === 8)
192
- if (r.data === St) {
193
- const _ = r.parentNode;
194
- (r.previousSibling === null || a === c) && (a++, _.insertBefore(ot(), r)), c = a, this.parts.push({ type: "node", index: a }), r.nextSibling === null ? r.data = "" : (s.push(r), a--), f++;
191
+ } else if (o.nodeType === 8)
192
+ if (o.data === yt) {
193
+ const _ = o.parentNode;
194
+ (o.previousSibling === null || a === c) && (a++, _.insertBefore(ct(), o)), c = a, this.parts.push({ type: "node", index: a }), o.nextSibling === null ? o.data = "" : (s.push(o), a--), d++;
195
195
  } else {
196
196
  let _ = -1;
197
- for (; (_ = r.data.indexOf(St, _ + 1)) !== -1; )
198
- this.parts.push({ type: "node", index: -1 }), f++;
197
+ for (; (_ = o.data.indexOf(yt, _ + 1)) !== -1; )
198
+ this.parts.push({ type: "node", index: -1 }), d++;
199
199
  }
200
200
  }
201
- for (const r of s)
202
- r.parentNode.removeChild(r);
201
+ for (const o of s)
202
+ o.parentNode.removeChild(o);
203
203
  }
204
204
  }
205
- const Si = (e, t) => {
205
+ const Ci = (e, t) => {
206
206
  const n = e.length - t.length;
207
207
  return n >= 0 && e.slice(n) === t;
208
- }, Ma = (e) => e.index !== -1, ot = () => document.createComment(""), Jn = (
208
+ }, za = (e) => e.index !== -1, ct = () => document.createComment(""), Jn = (
209
209
  // eslint-disable-next-line no-control-regex
210
210
  /([ \x09\x0a\x0c\x0d])([^\0-\x1F\x7F-\x9F "'>=/]+)([ \x09\x0a\x0c\x0d]*=[ \x09\x0a\x0c\x0d]*(?:[^ \x09\x0a\x0c\x0d"'`<>=]*|"[^"]*|'[^']*))$/
211
211
  );
@@ -222,7 +222,7 @@ const Si = (e, t) => {
222
222
  * subject to an additional IP rights grant found at
223
223
  * http://polymer.github.io/PATENTS.txt
224
224
  */
225
- class $i {
225
+ class Pi {
226
226
  constructor(t, n, s) {
227
227
  this.__parts = [], this.template = t, this.processor = n, this.options = s;
228
228
  }
@@ -234,23 +234,23 @@ class $i {
234
234
  s !== void 0 && s.commit();
235
235
  }
236
236
  _clone() {
237
- const t = vi ? this.template.element.content.cloneNode(!0) : document.importNode(this.template.element.content, !0), n = [], s = this.template.parts, i = document.createTreeWalker(t, 133, null, !1);
238
- let o = 0, c = 0, a, f = i.nextNode();
239
- for (; o < s.length; ) {
240
- if (a = s[o], !Ma(a)) {
241
- this.__parts.push(void 0), o++;
237
+ const t = $i ? this.template.element.content.cloneNode(!0) : document.importNode(this.template.element.content, !0), n = [], s = this.template.parts, i = document.createTreeWalker(t, 133, null, !1);
238
+ let r = 0, c = 0, a, d = i.nextNode();
239
+ for (; r < s.length; ) {
240
+ if (a = s[r], !za(a)) {
241
+ this.__parts.push(void 0), r++;
242
242
  continue;
243
243
  }
244
244
  for (; c < a.index; )
245
- c++, f.nodeName === "TEMPLATE" && (n.push(f), i.currentNode = f.content), (f = i.nextNode()) === null && (i.currentNode = n.pop(), f = i.nextNode());
245
+ c++, d.nodeName === "TEMPLATE" && (n.push(d), i.currentNode = d.content), (d = i.nextNode()) === null && (i.currentNode = n.pop(), d = i.nextNode());
246
246
  if (a.type === "node") {
247
- const h = this.processor.handleTextExpression(this.options);
248
- h.insertAfterNode(f.previousSibling), this.__parts.push(h);
247
+ const f = this.processor.handleTextExpression(this.options);
248
+ f.insertAfterNode(d.previousSibling), this.__parts.push(f);
249
249
  } else
250
- this.__parts.push(...this.processor.handleAttributeExpressions(f, a.name, a.strings, this.options));
251
- o++;
250
+ this.__parts.push(...this.processor.handleAttributeExpressions(d, a.name, a.strings, this.options));
251
+ r++;
252
252
  }
253
- return vi && (document.adoptNode(t), customElements.upgrade(t)), t;
253
+ return $i && (document.adoptNode(t), customElements.upgrade(t)), t;
254
254
  }
255
255
  }
256
256
  /**
@@ -266,7 +266,7 @@ class $i {
266
266
  * subject to an additional IP rights grant found at
267
267
  * http://polymer.github.io/PATENTS.txt
268
268
  */
269
- const Ei = window.trustedTypes && trustedTypes.createPolicy("lit-html", { createHTML: (e) => e }), La = ` ${St} `;
269
+ const ki = window.trustedTypes && trustedTypes.createPolicy("lit-html", { createHTML: (e) => e }), Ga = ` ${yt} `;
270
270
  class $n {
271
271
  constructor(t, n, s, i) {
272
272
  this.strings = t, this.values = n, this.type = s, this.processor = i;
@@ -278,26 +278,26 @@ class $n {
278
278
  const t = this.strings.length - 1;
279
279
  let n = "", s = !1;
280
280
  for (let i = 0; i < t; i++) {
281
- const o = this.strings[i], c = o.lastIndexOf("<!--");
282
- s = (c > -1 || s) && o.indexOf("-->", c + 1) === -1;
283
- const a = Jn.exec(o);
284
- a === null ? n += o + (s ? La : ur) : n += o.substr(0, a.index) + a[1] + a[2] + we + a[3] + St;
281
+ const r = this.strings[i], c = r.lastIndexOf("<!--");
282
+ s = (c > -1 || s) && r.indexOf("-->", c + 1) === -1;
283
+ const a = Jn.exec(r);
284
+ a === null ? n += r + (s ? Ga : mr) : n += r.substr(0, a.index) + a[1] + a[2] + ye + a[3] + yt;
285
285
  }
286
286
  return n += this.strings[t], n;
287
287
  }
288
288
  getTemplateElement() {
289
289
  const t = document.createElement("template");
290
290
  let n = this.getHTML();
291
- return Ei !== void 0 && (n = Ei.createHTML(n)), t.innerHTML = n, t;
291
+ return ki !== void 0 && (n = ki.createHTML(n)), t.innerHTML = n, t;
292
292
  }
293
293
  }
294
- class dr extends $n {
294
+ class vr extends $n {
295
295
  getHTML() {
296
296
  return `<svg>${super.getHTML()}</svg>`;
297
297
  }
298
298
  getTemplateElement() {
299
299
  const t = super.getTemplateElement(), n = t.content, s = n.firstChild;
300
- return n.removeChild(s), hr(n, s.firstChild), t;
300
+ return n.removeChild(s), gr(n, s.firstChild), t;
301
301
  }
302
302
  }
303
303
  /**
@@ -313,9 +313,9 @@ class dr extends $n {
313
313
  * subject to an additional IP rights grant found at
314
314
  * http://polymer.github.io/PATENTS.txt
315
315
  */
316
- const Es = (e) => e === null || !(typeof e == "object" || typeof e == "function"), Yn = (e) => Array.isArray(e) || // eslint-disable-next-line @typescript-eslint/no-explicit-any
316
+ const bs = (e) => e === null || !(typeof e == "object" || typeof e == "function"), Yn = (e) => Array.isArray(e) || // eslint-disable-next-line @typescript-eslint/no-explicit-any
317
317
  !!(e && e[Symbol.iterator]);
318
- class pr {
318
+ class wr {
319
319
  constructor(t, n, s) {
320
320
  this.dirty = !0, this.element = t, this.name = n, this.strings = s, this.parts = [];
321
321
  for (let i = 0; i < s.length - 1; i++)
@@ -325,28 +325,28 @@ class pr {
325
325
  * Creates a single part. Override this to create a differnt type of part.
326
326
  */
327
327
  _createPart() {
328
- return new bs(this);
328
+ return new Cs(this);
329
329
  }
330
330
  _getValue() {
331
331
  const t = this.strings, n = t.length - 1, s = this.parts;
332
332
  if (n === 1 && t[0] === "" && t[1] === "") {
333
- const o = s[0].value;
334
- if (typeof o == "symbol")
335
- return String(o);
336
- if (typeof o == "string" || !Yn(o))
337
- return o;
333
+ const r = s[0].value;
334
+ if (typeof r == "symbol")
335
+ return String(r);
336
+ if (typeof r == "string" || !Yn(r))
337
+ return r;
338
338
  }
339
339
  let i = "";
340
- for (let o = 0; o < n; o++) {
341
- i += t[o];
342
- const c = s[o];
340
+ for (let r = 0; r < n; r++) {
341
+ i += t[r];
342
+ const c = s[r];
343
343
  if (c !== void 0) {
344
344
  const a = c.value;
345
- if (Es(a) || !Yn(a))
345
+ if (bs(a) || !Yn(a))
346
346
  i += typeof a == "string" ? a : String(a);
347
347
  else
348
- for (const f of a)
349
- i += typeof f == "string" ? f : String(f);
348
+ for (const d of a)
349
+ i += typeof d == "string" ? d : String(d);
350
350
  }
351
351
  }
352
352
  return i += t[n], i;
@@ -355,19 +355,19 @@ class pr {
355
355
  this.dirty && (this.dirty = !1, this.element.setAttribute(this.name, this._getValue()));
356
356
  }
357
357
  }
358
- class bs {
358
+ class Cs {
359
359
  constructor(t) {
360
360
  this.value = void 0, this.committer = t;
361
361
  }
362
362
  setValue(t) {
363
- t !== it && (!Es(t) || t !== this.value) && (this.value = t, Ve(t) || (this.committer.dirty = !0));
363
+ t !== ot && (!bs(t) || t !== this.value) && (this.value = t, Ve(t) || (this.committer.dirty = !0));
364
364
  }
365
365
  commit() {
366
366
  for (; Ve(this.value); ) {
367
367
  const t = this.value;
368
- this.value = it, t(this);
368
+ this.value = ot, t(this);
369
369
  }
370
- this.value !== it && this.committer.commit();
370
+ this.value !== ot && this.committer.commit();
371
371
  }
372
372
  }
373
373
  class re {
@@ -380,7 +380,7 @@ class re {
380
380
  * This part must be empty, as its contents are not automatically moved.
381
381
  */
382
382
  appendInto(t) {
383
- this.startNode = t.appendChild(ot()), this.endNode = t.appendChild(ot());
383
+ this.startNode = t.appendChild(ct()), this.endNode = t.appendChild(ct());
384
384
  }
385
385
  /**
386
386
  * Inserts this part after the `ref` node (between `ref` and `ref`'s next
@@ -398,7 +398,7 @@ class re {
398
398
  * This part must be empty, as its contents are not automatically moved.
399
399
  */
400
400
  appendIntoPart(t) {
401
- t.__insert(this.startNode = ot()), t.__insert(this.endNode = ot());
401
+ t.__insert(this.startNode = ct()), t.__insert(this.endNode = ct());
402
402
  }
403
403
  /**
404
404
  * Inserts this part after the `ref` part.
@@ -406,7 +406,7 @@ class re {
406
406
  * This part must be empty, as its contents are not automatically moved.
407
407
  */
408
408
  insertAfterPart(t) {
409
- t.__insert(this.startNode = ot()), this.endNode = t.endNode, t.endNode = this.startNode;
409
+ t.__insert(this.startNode = ct()), this.endNode = t.endNode, t.endNode = this.startNode;
410
410
  }
411
411
  setValue(t) {
412
412
  this.__pendingValue = t;
@@ -416,10 +416,10 @@ class re {
416
416
  return;
417
417
  for (; Ve(this.__pendingValue); ) {
418
418
  const n = this.__pendingValue;
419
- this.__pendingValue = it, n(this);
419
+ this.__pendingValue = ot, n(this);
420
420
  }
421
421
  const t = this.__pendingValue;
422
- t !== it && (Es(t) ? t !== this.value && this.__commitText(t) : t instanceof $n ? this.__commitTemplateResult(t) : t instanceof Node ? this.__commitNode(t) : Yn(t) ? this.__commitIterable(t) : t === wi ? (this.value = wi, this.clear()) : this.__commitText(t));
422
+ t !== ot && (bs(t) ? t !== this.value && this.__commitText(t) : t instanceof $n ? this.__commitTemplateResult(t) : t instanceof Node ? this.__commitNode(t) : Yn(t) ? this.__commitIterable(t) : t === Ei ? (this.value = Ei, this.clear()) : this.__commitText(t));
423
423
  }
424
424
  __insert(t) {
425
425
  this.endNode.parentNode.insertBefore(t, this.endNode);
@@ -435,10 +435,10 @@ class re {
435
435
  }
436
436
  __commitTemplateResult(t) {
437
437
  const n = this.options.templateFactory(t);
438
- if (this.value instanceof $i && this.value.template === n)
438
+ if (this.value instanceof Pi && this.value.template === n)
439
439
  this.value.update(t.values);
440
440
  else {
441
- const s = new $i(n, t.processor, this.options), i = s._clone();
441
+ const s = new Pi(n, t.processor, this.options), i = s._clone();
442
442
  s.update(t.values), this.__commitNode(i), this.value = s;
443
443
  }
444
444
  }
@@ -446,15 +446,15 @@ class re {
446
446
  Array.isArray(this.value) || (this.value = [], this.clear());
447
447
  const n = this.value;
448
448
  let s = 0, i;
449
- for (const o of t)
450
- i = n[s], i === void 0 && (i = new re(this.options), n.push(i), s === 0 ? i.appendIntoPart(this) : i.insertAfterPart(n[s - 1])), i.setValue(o), i.commit(), s++;
449
+ for (const r of t)
450
+ i = n[s], i === void 0 && (i = new re(this.options), n.push(i), s === 0 ? i.appendIntoPart(this) : i.insertAfterPart(n[s - 1])), i.setValue(r), i.commit(), s++;
451
451
  s < n.length && (n.length = s, this.clear(i && i.endNode));
452
452
  }
453
453
  clear(t = this.startNode) {
454
- $s(this.startNode.parentNode, t.nextSibling, this.endNode);
454
+ Es(this.startNode.parentNode, t.nextSibling, this.endNode);
455
455
  }
456
456
  }
457
- class Na {
457
+ class Va {
458
458
  constructor(t, n, s) {
459
459
  if (this.value = void 0, this.__pendingValue = void 0, s.length !== 2 || s[0] !== "" || s[1] !== "")
460
460
  throw new Error("Boolean attributes can only contain a single expression");
@@ -466,20 +466,20 @@ class Na {
466
466
  commit() {
467
467
  for (; Ve(this.__pendingValue); ) {
468
468
  const n = this.__pendingValue;
469
- this.__pendingValue = it, n(this);
469
+ this.__pendingValue = ot, n(this);
470
470
  }
471
- if (this.__pendingValue === it)
471
+ if (this.__pendingValue === ot)
472
472
  return;
473
473
  const t = !!this.__pendingValue;
474
- this.value !== t && (t ? this.element.setAttribute(this.name, "") : this.element.removeAttribute(this.name), this.value = t), this.__pendingValue = it;
474
+ this.value !== t && (t ? this.element.setAttribute(this.name, "") : this.element.removeAttribute(this.name), this.value = t), this.__pendingValue = ot;
475
475
  }
476
476
  }
477
- class Aa extends pr {
477
+ class Da extends wr {
478
478
  constructor(t, n, s) {
479
479
  super(t, n, s), this.single = s.length === 2 && s[0] === "" && s[1] === "";
480
480
  }
481
481
  _createPart() {
482
- return new Ia(this);
482
+ return new Fa(this);
483
483
  }
484
484
  _getValue() {
485
485
  return this.single ? this.parts[0].value : super._getValue();
@@ -488,21 +488,21 @@ class Aa extends pr {
488
488
  this.dirty && (this.dirty = !1, this.element[this.name] = this._getValue());
489
489
  }
490
490
  }
491
- class Ia extends bs {
491
+ class Fa extends Cs {
492
492
  }
493
- let fr = !1;
493
+ let yr = !1;
494
494
  (() => {
495
495
  try {
496
496
  const e = {
497
497
  get capture() {
498
- return fr = !0, !1;
498
+ return yr = !0, !1;
499
499
  }
500
500
  };
501
501
  window.addEventListener("test", e, e), window.removeEventListener("test", e, e);
502
502
  } catch {
503
503
  }
504
504
  })();
505
- class Ra {
505
+ class qa {
506
506
  constructor(t, n, s) {
507
507
  this.value = void 0, this.__pendingValue = void 0, this.element = t, this.eventName = n, this.eventContext = s, this.__boundHandleEvent = (i) => this.handleEvent(i);
508
508
  }
@@ -511,19 +511,19 @@ class Ra {
511
511
  }
512
512
  commit() {
513
513
  for (; Ve(this.__pendingValue); ) {
514
- const o = this.__pendingValue;
515
- this.__pendingValue = it, o(this);
514
+ const r = this.__pendingValue;
515
+ this.__pendingValue = ot, r(this);
516
516
  }
517
- if (this.__pendingValue === it)
517
+ if (this.__pendingValue === ot)
518
518
  return;
519
519
  const t = this.__pendingValue, n = this.value, s = t == null || n != null && (t.capture !== n.capture || t.once !== n.once || t.passive !== n.passive), i = t != null && (n == null || s);
520
- s && this.element.removeEventListener(this.eventName, this.__boundHandleEvent, this.__options), i && (this.__options = Ha(t), this.element.addEventListener(this.eventName, this.__boundHandleEvent, this.__options)), this.value = t, this.__pendingValue = it;
520
+ s && this.element.removeEventListener(this.eventName, this.__boundHandleEvent, this.__options), i && (this.__options = Ua(t), this.element.addEventListener(this.eventName, this.__boundHandleEvent, this.__options)), this.value = t, this.__pendingValue = ot;
521
521
  }
522
522
  handleEvent(t) {
523
523
  typeof this.value == "function" ? this.value.call(this.eventContext || this.element, t) : this.value.handleEvent(t);
524
524
  }
525
525
  }
526
- const Ha = (e) => e && (fr ? { capture: e.capture, passive: e.passive, once: e.once } : e.capture);
526
+ const Ua = (e) => e && (yr ? { capture: e.capture, passive: e.passive, once: e.once } : e.capture);
527
527
  /**
528
528
  * @license
529
529
  * Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
@@ -537,7 +537,7 @@ const Ha = (e) => e && (fr ? { capture: e.capture, passive: e.passive, once: e.o
537
537
  * subject to an additional IP rights grant found at
538
538
  * http://polymer.github.io/PATENTS.txt
539
539
  */
540
- class Wa {
540
+ class Ba {
541
541
  /**
542
542
  * Create parts for an attribute-position binding, given the event, attribute
543
543
  * name, and string literals.
@@ -548,8 +548,8 @@ class Wa {
548
548
  * event for fully-controlled bindings with a single expression.
549
549
  */
550
550
  handleAttributeExpressions(t, n, s, i) {
551
- const o = n[0];
552
- return o === "." ? new Aa(t, n.slice(1), s).parts : o === "@" ? [new Ra(t, n.slice(1), i.eventContext)] : o === "?" ? [new Na(t, n.slice(1), s)] : new pr(t, n, s).parts;
551
+ const r = n[0];
552
+ return r === "." ? new Da(t, n.slice(1), s).parts : r === "@" ? [new qa(t, n.slice(1), i.eventContext)] : r === "?" ? [new Va(t, n.slice(1), s)] : new wr(t, n, s).parts;
553
553
  }
554
554
  /**
555
555
  * Create parts for a text-position binding.
@@ -559,7 +559,7 @@ class Wa {
559
559
  return new re(t);
560
560
  }
561
561
  }
562
- const _r = new Wa();
562
+ const Sr = new Ba();
563
563
  /**
564
564
  * @license
565
565
  * Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
@@ -573,19 +573,19 @@ const _r = new Wa();
573
573
  * subject to an additional IP rights grant found at
574
574
  * http://polymer.github.io/PATENTS.txt
575
575
  */
576
- function za(e) {
577
- let t = bi.get(e.type);
576
+ function Ka(e) {
577
+ let t = xi.get(e.type);
578
578
  t === void 0 && (t = {
579
579
  stringsArray: /* @__PURE__ */ new WeakMap(),
580
580
  keyString: /* @__PURE__ */ new Map()
581
- }, bi.set(e.type, t));
581
+ }, xi.set(e.type, t));
582
582
  let n = t.stringsArray.get(e.strings);
583
583
  if (n !== void 0)
584
584
  return n;
585
- const s = e.strings.join(St);
586
- return n = t.keyString.get(s), n === void 0 && (n = new Oa(e, e.getTemplateElement()), t.keyString.set(s, n)), t.stringsArray.set(e.strings, n), n;
585
+ const s = e.strings.join(yt);
586
+ return n = t.keyString.get(s), n === void 0 && (n = new Wa(e, e.getTemplateElement()), t.keyString.set(s, n)), t.stringsArray.set(e.strings, n), n;
587
587
  }
588
- const bi = /* @__PURE__ */ new Map();
588
+ const xi = /* @__PURE__ */ new Map();
589
589
  /**
590
590
  * @license
591
591
  * Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
@@ -599,9 +599,9 @@ const bi = /* @__PURE__ */ new Map();
599
599
  * subject to an additional IP rights grant found at
600
600
  * http://polymer.github.io/PATENTS.txt
601
601
  */
602
- const Ci = /* @__PURE__ */ new WeakMap(), Cs = (e, t, n) => {
603
- let s = Ci.get(t);
604
- s === void 0 && ($s(t, t.firstChild), Ci.set(t, s = new re(Object.assign({ templateFactory: za }, n))), s.appendInto(t)), s.setValue(e), s.commit();
602
+ const Ti = /* @__PURE__ */ new WeakMap(), Ps = (e, t, n) => {
603
+ let s = Ti.get(t);
604
+ s === void 0 && (Es(t, t.firstChild), Ti.set(t, s = new re(Object.assign({ templateFactory: Ka }, n))), s.appendInto(t)), s.setValue(e), s.commit();
605
605
  };
606
606
  /**
607
607
  * @license
@@ -617,23 +617,25 @@ const Ci = /* @__PURE__ */ new WeakMap(), Cs = (e, t, n) => {
617
617
  * http://polymer.github.io/PATENTS.txt
618
618
  */
619
619
  typeof window < "u" && (window.litHtmlVersions || (window.litHtmlVersions = [])).push("1.4.1");
620
- const at = (e, ...t) => new $n(e, t, "html", _r), Ga = (e, ...t) => new dr(e, t, "svg", _r);
621
- let _e = /* @__PURE__ */ new Set();
622
- function Ot(e) {
623
- typeof e == "function" && (_e.size || globalThis.queueMicrotask(() => {
624
- const t = _e;
625
- _e = /* @__PURE__ */ new Set(), t.forEach((n) => n());
626
- }), _e.delete(e), _e.add(e));
627
- }
628
- function gr(e = "", t = "") {
620
+ const ht = (e, ...t) => new $n(e, t, "html", Sr), ja = (e, ...t) => new vr(e, t, "svg", Sr), { assign: Ja, setPrototypeOf: Ya, fromEntries: Qa, entries: Xa, keys: Za } = Object, zn = /* @__PURE__ */ new Set();
621
+ function Mt(e) {
622
+ zn.has(e) || (queueMicrotask(() => {
623
+ zn.delete(e), e();
624
+ }), zn.add(e));
625
+ }
626
+ function En(e, t) {
627
+ const n = t;
628
+ return Ya(n, null), delete n.name, delete n.length, Ja(n, e), n;
629
+ }
630
+ function $r(e = "", t = "") {
629
631
  const { pathname: n, search: s, hash: i } = new URL(t, location.origin + e);
630
632
  return n + s + decodeURIComponent(i);
631
633
  }
632
- function mr(e, t, n, s) {
634
+ function Er(e, t, n, s) {
633
635
  return e.addEventListener(t, n, s), () => e.removeEventListener(t, n, s);
634
636
  }
635
637
  var vt, lt, wt, Ke, Qn;
636
- class Va extends EventTarget {
638
+ class tc extends EventTarget {
637
639
  constructor() {
638
640
  super(...arguments);
639
641
  b(this, Ke);
@@ -667,12 +669,12 @@ class Va extends EventTarget {
667
669
  // 如果是添加第一个,start 事件会在添加前触发,避免处理事件重复的逻辑
668
670
  add(n) {
669
671
  p(this, wt) || this.dispatchEvent(new CustomEvent("start"));
670
- const s = Hn(this, Ke, Qn).call(this, n) || { value: n };
672
+ const s = Wn(this, Ke, Qn).call(this, n) || { value: n };
671
673
  s.prev = p(this, wt), s.prev && (s.prev.next = s), s.next = void 0, x(this, wt, s), p(this, lt) || x(this, lt, s), p(this, vt).set(n, s);
672
674
  }
673
675
  // 删除这个元素后没有其他元素时立即出发 end 事件
674
676
  delete(n) {
675
- const s = Hn(this, Ke, Qn).call(this, n);
677
+ const s = Wn(this, Ke, Qn).call(this, n);
676
678
  return p(this, lt) || this.dispatchEvent(new CustomEvent("end")), s;
677
679
  }
678
680
  // 获取头部元素
@@ -687,17 +689,17 @@ vt = new WeakMap(), lt = new WeakMap(), wt = new WeakMap(), Ke = new WeakSet(),
687
689
  const s = p(this, vt).get(n);
688
690
  return s && (s.prev ? s.prev.next = s.next : x(this, lt, s.next), s.next ? s.next.prev = s.prev : x(this, wt, s.prev), p(this, vt).delete(n)), s;
689
691
  };
690
- class Da extends WeakMap {
692
+ class ec extends WeakMap {
691
693
  get(t) {
692
694
  let n = super.get(t);
693
695
  return n || (n = {}, this.set(t, n)), n;
694
696
  }
695
697
  }
696
- var Bt, _n;
698
+ var Kt, _n;
697
699
  class De extends URLSearchParams {
698
700
  constructor(n) {
699
701
  super(n);
700
- b(this, Bt, (n) => typeof n == "string" ? n : JSON.stringify(n));
702
+ b(this, Kt, (n) => typeof n == "string" ? n : JSON.stringify(n));
701
703
  b(this, _n, (n) => {
702
704
  if (!n) return null;
703
705
  try {
@@ -710,15 +712,15 @@ class De extends URLSearchParams {
710
712
  // support `{ key: ObjectValue }`
711
713
  concat(n) {
712
714
  let s;
713
- typeof n == "string" ? s = Object.fromEntries(new URLSearchParams(n).entries()) : s = n, Object.entries(s).forEach(([i, o]) => {
714
- this.append(i, p(this, Bt).call(this, o));
715
+ typeof n == "string" ? s = Qa(new URLSearchParams(n).entries()) : s = n, Xa(s).forEach(([i, r]) => {
716
+ this.append(i, p(this, Kt).call(this, r));
715
717
  });
716
718
  }
717
719
  setAny(n, s) {
718
720
  if (Array.isArray(s))
719
- this.delete(n), s.forEach((i) => this.append(n, p(this, Bt).call(this, i)));
721
+ this.delete(n), s.forEach((i) => this.append(n, p(this, Kt).call(this, i)));
720
722
  else {
721
- const i = p(this, Bt).call(this, s);
723
+ const i = p(this, Kt).call(this, s);
722
724
  i ? this.set(n, i) : this.delete(n);
723
725
  }
724
726
  }
@@ -736,242 +738,225 @@ class De extends URLSearchParams {
736
738
  return this.toString();
737
739
  }
738
740
  }
739
- Bt = new WeakMap(), _n = new WeakMap();
740
- function Ps(e, ...t) {
741
+ Kt = new WeakMap(), _n = new WeakMap();
742
+ function ks(e, ...t) {
741
743
  return e.reduce((n, s, i) => n + (t[i - 1] ?? "") + s);
742
744
  }
743
- const vr = Ps;
744
- function En(e = 5) {
745
+ const br = ks;
746
+ function bn(e = 5) {
745
747
  const t = Math.random().toString(36).slice(2, 2 + e);
746
- return t.length < e ? t + En(e - t.length) : t;
748
+ return t.length < e ? t + bn(e - t.length) : t;
747
749
  }
748
- const Wl = { class: Ps };
750
+ const Kh = { class: ks };
749
751
  function oe(e) {
750
752
  return e.replace(/[A-Z]/g, (t) => "-" + t.toLowerCase());
751
753
  }
752
- function zl(e) {
754
+ function jh(e) {
753
755
  return e.replace(/-(.)/g, (t, n) => n.toUpperCase());
754
756
  }
755
- function ks(e) {
756
- return Object.keys(e).forEach((t) => {
757
+ function xs(e) {
758
+ return Za(e).forEach((t) => {
757
759
  delete e[t];
758
760
  }), e;
759
761
  }
760
- class yt extends Error {
762
+ class Lt extends Error {
761
763
  constructor(t) {
762
764
  super(t), this.message = `gem: ${this.message}`;
763
765
  }
764
766
  }
765
- function Fa(e, t) {
767
+ function nc(e, t) {
766
768
  const n = e.length;
767
769
  if (t.length !== n) return !0;
768
770
  for (let s = 0; s < n; s++)
769
771
  if (e[s] !== t[s]) return !0;
770
772
  return !1;
771
773
  }
772
- function xs(e, t, n) {
774
+ function Ts(e, t, n) {
773
775
  let s = t;
774
776
  for (const i in e) {
775
- const o = n(i, e[i]);
776
- s += o ? o + t : "";
777
+ const r = n(i, e[i]);
778
+ s += r ? r + t : "";
777
779
  }
778
780
  return s;
779
781
  }
780
- function Gl(e) {
781
- return xs(
782
+ function Jh(e) {
783
+ return Ts(
782
784
  e,
783
785
  ";",
784
786
  (t, n) => n || n === 0 ? `${oe(t)}:${n}` : ""
785
787
  );
786
788
  }
787
- function qa(e) {
788
- return xs(e, " ", (t, n) => n ? t : "");
789
+ function sc(e) {
790
+ return Ts(e, " ", (t, n) => n ? t : "");
789
791
  }
790
- const Vl = qa;
791
- function Dl(e) {
792
- return xs(
792
+ const Yh = sc;
793
+ function Qh(e) {
794
+ return Ts(
793
795
  e,
794
796
  ",",
795
797
  (t, n) => n === !0 || t === n ? t : n ? `${t}:${n}` : ""
796
798
  );
797
799
  }
798
- const ne = /* @__PURE__ */ new WeakMap();
799
- function bn(e) {
800
- if (ne.has(e))
801
- throw new yt("argument error");
802
- return ne.set(e, /* @__PURE__ */ new Set()), e;
803
- }
804
- function It(e, t) {
805
- var n;
806
- Object.assign(e, t), (n = ne.get(e)) == null || n.forEach((s) => {
807
- Ot(s);
800
+ const un = /* @__PURE__ */ new WeakMap();
801
+ function Wt(e) {
802
+ const t = En(e, (n) => {
803
+ var s;
804
+ Object.assign(t, n), (s = un.get(t)) == null || s.forEach((i) => Mt(i));
808
805
  });
809
- }
810
- function Xe(e) {
811
- const t = bn(e);
812
- return [t, (n) => It(t, n)];
806
+ return un.set(t, /* @__PURE__ */ new Set()), t;
813
807
  }
814
808
  function ft(e, t) {
815
- const n = ne.get(e);
816
- return n == null || n.add(t), () => {
817
- n == null || n.delete(t);
818
- };
819
- }
820
- function Ua(e, t) {
821
- const n = ne.get(e);
822
- n == null || n.delete(t);
809
+ const n = un.get(e);
810
+ return n == null || n.add(t), () => n == null ? void 0 : n.delete(t);
823
811
  }
824
- const Ba = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
812
+ const ic = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
825
813
  __proto__: null,
826
- StoreListenerMap: ne,
814
+ StoreListenerMap: un,
827
815
  connect: ft,
828
- createStore: bn,
829
- disconnect: Ua,
830
- updateStore: It,
831
- useStore: Xe
832
- }, Symbol.toStringTag, { value: "Module" })), { assign: Wn, defineProperty: Ka, setPrototypeOf: ja } = Object;
833
- Ka(Symbol, "metadata", { value: Symbol.for("Symbol.metadata") });
834
- const Ts = (e) => typeof e == "function" && e(), Rt = Symbol.for("gem@sheetToken"), Cn = Symbol.for("gem@update"), wr = "gem-style-boundary", Os = "gem@render-error", Ja = Cn, zn = /* @__PURE__ */ new WeakMap(), yr = /* @__PURE__ */ new WeakMap(), Pi = (e) => [...e.querySelectorAll("[data-gem-reflect]")].map((t) => t.target);
835
- class Ya {
816
+ createStore: Wt
817
+ }, Symbol.toStringTag, { value: "Module" })), { assign: Oi, defineProperty: rc } = Object;
818
+ rc(Symbol, "metadata", { value: Symbol.for("Symbol.metadata") });
819
+ const Os = (e) => typeof e == "function" && e(), Ht = Symbol.for("gem@sheetToken"), Cn = Symbol.for("gem@update"), Cr = "gem-style-boundary", Ms = "gem@render-error", oc = Cn, Gn = /* @__PURE__ */ new WeakMap(), Pr = /* @__PURE__ */ new WeakMap(), Mi = (e) => [...e.querySelectorAll("[data-gem-reflect]")].map((t) => t.target);
820
+ class ac {
836
821
  constructor(t) {
837
- T(this, "refSelector");
838
- T(this, "ele");
839
- T(this, "ref");
840
- const n = `ref-${En()}`;
822
+ O(this, "refSelector");
823
+ O(this, "ele");
824
+ O(this, "ref");
825
+ const n = `ref-${bn()}`;
841
826
  this.refSelector = `[ref=${n}]`, this.ele = t.internals.shadowRoot || t, this.ref = n;
842
827
  }
843
828
  get element() {
844
- for (const t of [this.ele, ...Pi(this.ele)]) {
829
+ for (const t of [this.ele, ...Mi(this.ele)]) {
845
830
  const n = t.querySelector(this.refSelector);
846
831
  if (n) return n;
847
832
  }
848
833
  }
849
834
  get elements() {
850
- return [this.ele, ...Pi(this.ele)].map((t) => [...t.querySelectorAll(this.refSelector)]).flat();
835
+ return [this.ele, ...Mi(this.ele)].map((t) => [...t.querySelectorAll(this.refSelector)]).flat();
851
836
  }
852
837
  toString() {
853
838
  return this.ref;
854
839
  }
855
840
  }
856
- let Sr;
857
- var rt;
858
- class Qa extends CSSStyleSheet {
841
+ let kr;
842
+ var at;
843
+ class cc extends CSSStyleSheet {
859
844
  constructor() {
860
845
  super(...arguments);
861
- b(this, rt);
862
- T(this, "cssText", "");
846
+ b(this, at);
847
+ O(this, "cssText", "");
863
848
  }
864
849
  get element() {
865
- return p(this, rt) || (x(this, rt, document.createElement("style")), p(this, rt).textContent = this.cssText, p(this, rt).dataset.gemStyle = ""), p(this, rt);
850
+ return p(this, at) || (x(this, at, document.createElement("style")), p(this, at).textContent = this.cssText, p(this, at).dataset.gemStyle = ""), p(this, at);
866
851
  }
867
852
  replaceSync(n) {
868
- this.cssText = n, p(this, rt) && (p(this, rt).textContent = n), super.replaceSync(n);
853
+ this.cssText = n, p(this, at) && (p(this, at).textContent = n), super.replaceSync(n);
869
854
  }
870
855
  }
871
- rt = new WeakMap();
872
- var Mt, je, Kt, jt;
873
- class Xa {
856
+ at = new WeakMap();
857
+ var Nt, je, jt, Jt;
858
+ class hc {
874
859
  constructor(t = "") {
875
- b(this, Mt, "");
860
+ b(this, Nt, "");
876
861
  b(this, je, "");
877
862
  // 不需要 GC
878
- b(this, Kt, /* @__PURE__ */ new Map());
879
863
  b(this, jt, /* @__PURE__ */ new Map());
864
+ b(this, Jt, /* @__PURE__ */ new Map());
880
865
  x(this, je, t);
881
866
  }
882
867
  setContent(t) {
883
- x(this, Mt, t);
868
+ x(this, Nt, t);
884
869
  }
885
870
  getStyle(t) {
886
- var o;
887
- const n = t && !((o = t.internals) != null && o.shadowRoot), s = n ? t.constructor : this;
888
- if (!p(this, Kt).has(s)) {
889
- const c = new Qa({ media: p(this, je) });
890
- p(this, Kt).set(s, c);
871
+ var r;
872
+ const n = t && !((r = t.internals) != null && r.shadowRoot), s = n ? t.constructor : this;
873
+ if (!p(this, jt).has(s)) {
874
+ const c = new cc({ media: p(this, je) });
875
+ p(this, jt).set(s, c);
891
876
  }
892
- const i = p(this, Kt).get(s);
893
- if (!p(this, jt).has(i)) {
894
- let c = p(this, Mt), a = "";
895
- n && (a = `@scope (${t.tagName}) to (:state(${wr}) > *)`, c = `${a}{ ${c} }`), i.replaceSync(c), p(this, jt).set(i, a);
877
+ const i = p(this, jt).get(s);
878
+ if (!p(this, Jt).has(i)) {
879
+ let c = p(this, Nt), a = "";
880
+ n && (a = `@scope (${t.tagName}) to (:state(${Cr}) > *)`, c = `${a}{ ${c} }`), i.replaceSync(c), p(this, Jt).set(i, a);
896
881
  }
897
882
  return i;
898
883
  }
899
884
  // 一般用于主题更新,不支持 layer
900
885
  updateStyle() {
901
- p(this, jt).forEach((t, n) => {
902
- n.replaceSync(t ? `${t}{${p(this, Mt)}}` : p(this, Mt));
886
+ p(this, Jt).forEach((t, n) => {
887
+ n.replaceSync(t ? `${t}{${p(this, Nt)}}` : p(this, Nt));
903
888
  });
904
889
  }
905
890
  }
906
- Mt = new WeakMap(), je = new WeakMap(), Kt = new WeakMap(), jt = new WeakMap();
891
+ Nt = new WeakMap(), je = new WeakMap(), jt = new WeakMap(), Jt = new WeakMap();
907
892
  function Pn(e, t) {
908
- const n = t ? e : "", s = t || e, i = new Xa(n), o = { [Rt]: i };
893
+ const n = t ? e : "", s = t || e, i = new hc(n), r = { [Ht]: i };
909
894
  let c = "";
910
895
  return typeof s == "string" ? c = s : Object.keys(s).forEach((a) => {
911
- const f = a === "$";
912
- o[a] = f || a.includes("-") ? a : `${a}-${En()}`, c += `${f ? ":scope,:host" : `.${o[a]}`} {${s[a]}}`;
913
- }), i.setContent(c), o;
896
+ const d = a === "$";
897
+ r[a] = d || a.includes("-") ? a : `${a}-${bn()}`, c += `${d ? ":where(:scope:not([hidden])),:host(:where(:not([hidden])))" : `.${r[a]}`} {${s[a]}}`;
898
+ }), i.setContent(c), r;
914
899
  }
915
- const ki = (e, t, n) => {
900
+ const Li = (e, t, n) => {
916
901
  let s = !1;
917
902
  t.forEach((i) => {
918
- const o = e.get(i) || 0;
919
- s || (s = n === 1 && o === 0 || n === -1 && o === 1), e.set(i, o + n);
920
- }), s && Ot(yr.get(e));
921
- }, Za = (e, t) => {
903
+ const r = e.get(i) || 0;
904
+ s || (s = n === 1 && r === 0 || n === -1 && r === 1), e.set(i, r + n);
905
+ }), s && Mt(Pr.get(e));
906
+ }, lc = (e, t) => {
922
907
  const n = e.getRootNode();
923
- if (!zn.has(n)) {
908
+ if (!Gn.has(n)) {
924
909
  const i = /* @__PURE__ */ new Map();
925
- zn.set(n, i), yr.set(i, () => {
926
- const o = n.adoptedStyleSheets.filter((c) => !i.has(c));
927
- i.forEach((c, a) => c && o.push(a)), n.adoptedStyleSheets = o.reverse();
910
+ Gn.set(n, i), Pr.set(i, () => {
911
+ const r = n.adoptedStyleSheets.filter((c) => !i.has(c));
912
+ i.forEach((c, a) => c && r.push(a)), n.adoptedStyleSheets = r.reverse();
928
913
  });
929
914
  }
930
- const s = zn.get(n);
931
- return ki(s, t, 1), () => ki(s, t, -1);
915
+ const s = Gn.get(n);
916
+ return Li(s, t, 1), () => Li(s, t, -1);
932
917
  };
933
- let Ms;
934
- function xi(e) {
918
+ let Ls;
919
+ function Ni(e) {
935
920
  e == null || e.forEach((t) => {
936
- const { callback: n, getDep: s, values: i, preCallback: o } = t, c = s == null ? void 0 : s();
937
- (!s || !i || Fa(i, c)) && (Ts(o), t.preCallback = n(c, i), t.values = c, t.initialized = !0);
921
+ const { callback: n, getDep: s, values: i, preCallback: r } = t, c = s == null ? void 0 : s();
922
+ (!s || !i || nc(i, c)) && (Os(r), t.preCallback = n(c, i), t.values = c, t.initialized = !0);
938
923
  });
939
924
  }
940
- function Ti(e) {
941
- return e.filter((t) => (Ts(t.preCallback), t.initialized = !1, t.values = void 0, t.fixed));
925
+ function Ai(e) {
926
+ return e.filter((t) => (Os(t.preCallback), t.initialized = !1, t.values = void 0, t.fixed));
942
927
  }
943
- let Ls;
944
- const Ft = new Va(), Xn = (e = performance.now()) => {
928
+ let Ns;
929
+ const Ut = new tc(), Xn = (e = performance.now()) => {
945
930
  if (performance.now() > e + 16) return requestAnimationFrame(Xn);
946
- const t = Ft.get();
931
+ const t = Ut.get();
947
932
  t && (t(), Xn(e));
948
933
  };
949
- Ft.addEventListener("start", () => Ot(Xn));
950
- let Gn;
951
- var Jt, Yt, j, ht, Lt, ut, Qt, dt, Xt, Zt, Je, st, Gt, Zn, gn, mn, Ye, te, Nt, vn, wn, yn, Qe, ee;
952
- const qt = class qt extends HTMLElement {
934
+ Ut.addEventListener("start", () => Mt(Xn));
935
+ let Vn;
936
+ var Yt, Qt, J, ut, At, dt, Xt, pt, Zt, te, Je, rt, Ft, Zn, gn, mn, Ye, ee, It, vn, wn, yn, Qe, ne;
937
+ const Bt = class Bt extends HTMLElement {
953
938
  constructor() {
954
939
  super();
955
- b(this, st);
956
- b(this, Yt);
957
- b(this, j);
958
- b(this, ht, []);
959
- b(this, Lt, []);
960
- b(this, ut, []);
940
+ b(this, rt);
961
941
  b(this, Qt);
962
- b(this, dt);
963
- // not in constructor 的近似值
942
+ b(this, J);
943
+ b(this, ut, []);
944
+ b(this, At, []);
945
+ b(this, dt, []);
964
946
  b(this, Xt);
947
+ b(this, pt);
948
+ // not in constructor 的近似值
965
949
  b(this, Zt);
950
+ b(this, te);
966
951
  b(this, Je);
967
952
  /**
968
953
  * 每次更新完检查依赖,执行对应的副作用回调
969
954
  * */
970
955
  b(this, gn, () => {
971
- xi(p(this, ht));
956
+ Ni(p(this, ut));
972
957
  });
973
958
  b(this, mn, () => {
974
- xi(p(this, Lt));
959
+ Ni(p(this, At));
975
960
  });
976
961
  /**
977
962
  * - 条件渲染
@@ -981,37 +966,37 @@ const qt = class qt extends HTMLElement {
981
966
  * */
982
967
  b(this, Ye, (n) => {
983
968
  try {
984
- x(this, Zt, !0), p(this, mn).call(this);
985
- const s = p(this, Yt) === this, i = n ? n.render() : s ? void 0 : at`<slot></slot>`;
986
- if (x(this, Zt, !1), i === void 0) return;
987
- Cs(i, p(this, Yt));
969
+ x(this, te, !0), p(this, mn).call(this);
970
+ const s = p(this, Qt) === this, i = n ? n.render() : s ? void 0 : ht`<slot></slot>`;
971
+ if (x(this, te, !1), i === void 0) return;
972
+ Ps(i, p(this, Qt));
988
973
  } catch (s) {
989
- this.dispatchEvent(new CustomEvent(Os, { bubbles: !0, composed: !0, detail: s }));
974
+ this.dispatchEvent(new CustomEvent(Ms, { bubbles: !0, composed: !0, detail: s }));
990
975
  }
991
976
  });
992
- b(this, te, () => {
993
- const n = p(this, st, Zn);
994
- p(this, dt) && // 当有渲染函数,但是没一个符合条件时跳过
995
- (n || !p(this, ut).length) && (p(this, Ye).call(this, n), Ot(p(this, gn)));
977
+ b(this, ee, () => {
978
+ const n = p(this, rt, Zn);
979
+ p(this, pt) && // 当有渲染函数,但是没一个符合条件时跳过
980
+ (n || !p(this, dt).length) && (p(this, Ye).call(this, n), Mt(p(this, gn)));
996
981
  });
997
- b(this, Nt, () => {
998
- p(this, st, Gt).noBlocking ? Ft.add(p(this, te)) : p(this, te).call(this);
982
+ b(this, It, () => {
983
+ p(this, rt, Ft).noBlocking ? Ut.add(p(this, ee)) : p(this, ee).call(this);
999
984
  });
1000
985
  b(this, vn, () => {
1001
- const { adoptedStyleSheets: n = [] } = p(this, st, Gt), { shadowRoot: s, sheets: i } = p(this, j), o = n.map((c) => c[Rt].getStyle(this));
986
+ const { adoptedStyleSheets: n = [] } = p(this, rt, Ft), { shadowRoot: s, sheets: i } = p(this, J), r = n.map((c) => c[Ht].getStyle(this));
1002
987
  if (s)
1003
- s.adoptedStyleSheets = o.concat(i);
988
+ s.adoptedStyleSheets = r.concat(i);
1004
989
  else
1005
- return this.prepend(...i.map((c) => c.element)), Za(this, o);
990
+ return this.prepend(...i.map((c) => c.element)), lc(this, r);
1006
991
  });
1007
992
  /**
1008
993
  * 元素挂载后执行还未初始化的副作用
1009
994
  * */
1010
995
  b(this, wn, () => {
1011
996
  var n;
1012
- (n = p(this, ht)) == null || n.forEach((s) => {
1013
- const { callback: i, getDep: o, initialized: c } = s;
1014
- c || (s.values = o == null ? void 0 : o(), s.preCallback = i(s.values), s.initialized = !0);
997
+ (n = p(this, ut)) == null || n.forEach((s) => {
998
+ const { callback: i, getDep: r, initialized: c } = s;
999
+ c || (s.values = r == null ? void 0 : r(), s.preCallback = i(s.values), s.initialized = !0);
1015
1000
  });
1016
1001
  });
1017
1002
  b(this, yn, () => {
@@ -1019,17 +1004,17 @@ const qt = class qt extends HTMLElement {
1019
1004
  this.willMount && this.memo(this.willMount.bind(this), () => []), this.mounted && this.effect(this.mounted.bind(this), () => []), this.updated && this.effect((s, i) => i && this.updated.apply(this)), this.unmounted && this.effect(
1020
1005
  () => this.unmounted.bind(this),
1021
1006
  () => []
1022
- ), !p(this, ut).length && this.render && p(this, ut).push({ render: this.render.bind(this), condition: (n = this.shouldUpdate) == null ? void 0 : n.bind(this) });
1007
+ ), !p(this, dt).length && this.render && p(this, dt).push({ render: this.render.bind(this), condition: (n = this.shouldUpdate) == null ? void 0 : n.bind(this) });
1023
1008
  });
1024
1009
  b(this, Qe);
1025
- b(this, ee, async () => {
1026
- if (p(this, Qt)) {
1027
- x(this, Qt, !1);
1010
+ b(this, ne, async () => {
1011
+ if (p(this, Xt)) {
1012
+ x(this, Xt, !1);
1028
1013
  return;
1029
1014
  }
1030
1015
  p(this, yn).call(this);
1031
- const { observedStores: n, mode: s, penetrable: i } = p(this, st, Gt);
1032
- !s && p(this, ut).length && !i && p(this, j).states.add(wr), x(this, Xt, !0), x(this, Qe, n == null ? void 0 : n.map((o) => ft(o, p(this, Nt)))), p(this, Ye).call(this, p(this, st, Zn)), x(this, dt, !0), x(this, Je, p(this, vn).call(this)), await Promise.resolve(), p(this, wn).call(this);
1016
+ const { observedStores: n, mode: s, penetrable: i } = p(this, rt, Ft);
1017
+ !s && p(this, dt).length && !i && p(this, J).states.add(Cr), x(this, Zt, !0), x(this, Qe, n == null ? void 0 : n.map((r) => ft(r, p(this, It)))), p(this, Ye).call(this, p(this, rt, Zn)), x(this, pt, !0), x(this, Je, p(this, vn).call(this)), await Promise.resolve(), p(this, wn).call(this);
1033
1018
  });
1034
1019
  /**
1035
1020
  * @helper
@@ -1045,14 +1030,14 @@ const qt = class qt extends HTMLElement {
1045
1030
  * }
1046
1031
  * ```
1047
1032
  * */
1048
- T(this, "effect", (n, s) => {
1033
+ O(this, "effect", (n, s) => {
1049
1034
  const i = {
1050
1035
  callback: n,
1051
1036
  getDep: s,
1052
- initialized: p(this, dt),
1053
- fixed: !p(this, Xt)
1037
+ initialized: p(this, pt),
1038
+ fixed: !p(this, Zt)
1054
1039
  };
1055
- p(this, dt) && (i.values = s == null ? void 0 : s(), i.preCallback = n(i.values)), p(this, ht).push(i);
1040
+ p(this, pt) && (i.values = s == null ? void 0 : s(), i.preCallback = n(i.values)), p(this, ut).push(i);
1056
1041
  });
1057
1042
  /**
1058
1043
  * @helper
@@ -1071,38 +1056,38 @@ const qt = class qt extends HTMLElement {
1071
1056
  * }
1072
1057
  * ```
1073
1058
  * */
1074
- T(this, "memo", (n, s) => {
1075
- p(this, Lt).push({
1059
+ O(this, "memo", (n, s) => {
1060
+ p(this, At).push({
1076
1061
  callback: n,
1077
1062
  getDep: s,
1078
- fixed: !p(this, Xt)
1063
+ fixed: !p(this, Zt)
1079
1064
  });
1080
1065
  });
1081
1066
  /**
1082
1067
  * @helper
1083
1068
  * async
1084
1069
  */
1085
- T(this, "update", () => Ot(p(this, Nt)));
1086
- Gn = this;
1087
- const { mode: n, serializable: s, delegatesFocus: i, slotAssignment: o, aria: c } = p(this, st, Gt), { focusable: a, ...f } = c || {};
1088
- x(this, Yt, n ? this.attachShadow({ mode: n, serializable: s, delegatesFocus: i, slotAssignment: o }) : this), x(this, j, this.attachInternals()), p(this, j).stateList = [], p(this, j).sheets = [], Wn(p(this, j), f);
1089
- let h;
1090
- p(this, ht).push({
1070
+ O(this, "update", () => Mt(p(this, It)));
1071
+ Vn = this;
1072
+ const { mode: n, serializable: s, delegatesFocus: i, slotAssignment: r, aria: c } = p(this, rt, Ft), { focusable: a, ...d } = c || {};
1073
+ x(this, Qt, n ? this.attachShadow({ mode: n, serializable: s, delegatesFocus: i, slotAssignment: r }) : this), x(this, J, this.attachInternals()), p(this, J).stateList = [], p(this, J).sheets = [], Oi(p(this, J), d);
1074
+ let f;
1075
+ p(this, ut).push({
1091
1076
  fixed: !0,
1092
1077
  getDep: () => [this.disabled],
1093
- callback: ([m = !1]) => {
1094
- if (h === void 0 && (h = this.hasAttribute("tabindex")), p(this, j).ariaDisabled = String(m), a && !h && (this.tabIndex = -Number(m)), (a || i) && m)
1095
- return mr(this, "click", (r) => r.isTrusted && r.stopImmediatePropagation(), {
1078
+ callback: ([g = !1]) => {
1079
+ if (f === void 0 && (f = this.hasAttribute("tabindex")), p(this, J).ariaDisabled = String(g), a && !f && (this.tabIndex = -Number(g)), (a || i) && g)
1080
+ return Er(this, "click", (o) => o.isTrusted && o.stopImmediatePropagation(), {
1096
1081
  capture: !0
1097
1082
  });
1098
1083
  }
1099
1084
  });
1100
1085
  }
1101
- [Ja]() {
1102
- p(this, dt) && Ot(p(this, Nt));
1086
+ [oc]() {
1087
+ p(this, pt) && Mt(p(this, It));
1103
1088
  }
1104
1089
  get internals() {
1105
- return p(this, j);
1090
+ return p(this, J);
1106
1091
  }
1107
1092
  /**
1108
1093
  * @private
@@ -1110,14 +1095,14 @@ const qt = class qt extends HTMLElement {
1110
1095
  * use `mounted`
1111
1096
  */
1112
1097
  connectedCallback() {
1113
- return p(this, st, Gt).noBlocking ? Ft.add(p(this, ee)) : p(this, ee).call(this), p(qt, Jt);
1098
+ return p(this, rt, Ft).noBlocking ? Ut.add(p(this, ne)) : p(this, ne).call(this), p(Bt, Yt);
1114
1099
  }
1115
1100
  /**
1116
1101
  * @private
1117
1102
  * @final
1118
1103
  */
1119
1104
  adoptedCallback() {
1120
- return p(qt, Jt);
1105
+ return p(Bt, Yt);
1121
1106
  }
1122
1107
  /**
1123
1108
  * @private
@@ -1127,54 +1112,54 @@ const qt = class qt extends HTMLElement {
1127
1112
  disconnectedCallback() {
1128
1113
  var n;
1129
1114
  if (this.isConnected) {
1130
- x(this, Qt, !0);
1115
+ x(this, Xt, !0);
1131
1116
  return;
1132
1117
  }
1133
- return Ft.delete(p(this, ee)), Ft.delete(p(this, te)), x(this, dt, !1), (n = p(this, Qe)) == null || n.forEach((s) => s()), x(this, ht, Ti(p(this, ht))), x(this, Lt, Ti(p(this, Lt))), Ts(p(this, Je)), p(qt, Jt);
1118
+ return Ut.delete(p(this, ne)), Ut.delete(p(this, ee)), x(this, pt, !1), (n = p(this, Qe)) == null || n.forEach((s) => s()), x(this, ut, Ai(p(this, ut))), x(this, At, Ai(p(this, At))), Os(p(this, Je)), p(Bt, Yt);
1134
1119
  }
1135
1120
  };
1136
- Jt = new WeakMap(), Yt = new WeakMap(), j = new WeakMap(), ht = new WeakMap(), Lt = new WeakMap(), ut = new WeakMap(), Qt = new WeakMap(), dt = new WeakMap(), Xt = new WeakMap(), Zt = new WeakMap(), Je = new WeakMap(), st = new WeakSet(), Gt = function() {
1121
+ Yt = new WeakMap(), Qt = new WeakMap(), J = new WeakMap(), ut = new WeakMap(), At = new WeakMap(), dt = new WeakMap(), Xt = new WeakMap(), pt = new WeakMap(), Zt = new WeakMap(), te = new WeakMap(), Je = new WeakMap(), rt = new WeakSet(), Ft = function() {
1137
1122
  return this.constructor[Symbol.metadata];
1138
1123
  }, Zn = function() {
1139
- return p(this, ut).find((n) => !n.condition || n.condition());
1140
- }, gn = new WeakMap(), mn = new WeakMap(), Ye = new WeakMap(), te = new WeakMap(), Nt = new WeakMap(), vn = new WeakMap(), wn = new WeakMap(), yn = new WeakMap(), Qe = new WeakMap(), ee = new WeakMap(), // 禁止覆盖自定义元素原生生命周期方法
1124
+ return p(this, dt).findLast((n) => !n.condition || n.condition());
1125
+ }, gn = new WeakMap(), mn = new WeakMap(), Ye = new WeakMap(), ee = new WeakMap(), It = new WeakMap(), vn = new WeakMap(), wn = new WeakMap(), yn = new WeakMap(), Qe = new WeakMap(), ne = new WeakMap(), // 禁止覆盖自定义元素原生生命周期方法
1141
1126
  // https://github.com/microsoft/TypeScript/issues/21388#issuecomment-934345226
1142
- b(qt, Jt, Symbol()), Ms = (n) => {
1143
- const s = Gn, i = (o) => {
1144
- Wn(i, o), p(s, Zt) || Ot(p(s, Nt));
1145
- };
1146
- return ja(i, null), delete i.name, delete i.length, p(s, j).stateList.push(i), Wn(i, n), i;
1147
- }, Sr = () => new Ya(Gn), Ls = (n, s) => p(n, ut).push(s);
1148
- let B = qt;
1149
- const tc = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1127
+ b(Bt, Yt, Symbol()), Ls = (n) => {
1128
+ const s = Vn, i = En(n, (r) => {
1129
+ Oi(i, r), p(s, te) || Mt(p(s, It));
1130
+ });
1131
+ return p(s, J).stateList.push(i), i;
1132
+ }, kr = () => new ac(Vn), Ns = (n, s) => p(n, dt).push(s);
1133
+ let B = Bt;
1134
+ const uc = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1150
1135
  __proto__: null,
1151
1136
  GemElement: B,
1152
- RenderErrorEvent: Os,
1153
- SVGTemplateResult: dr,
1154
- SheetToken: Rt,
1137
+ SVGTemplateResult: vr,
1138
+ SheetToken: Ht,
1155
1139
  TemplateResult: $n,
1156
1140
  UpdateToken: Cn,
1141
+ _RenderErrorEvent: Ms,
1142
+ get _createTemplate() {
1143
+ return Ns;
1144
+ },
1157
1145
  createCSSSheet: Pn,
1158
1146
  get createRef() {
1159
- return Sr;
1147
+ return kr;
1160
1148
  },
1161
1149
  get createState() {
1162
- return Ms;
1163
- },
1164
- get createTemplate() {
1165
1150
  return Ls;
1166
1151
  },
1167
1152
  directive: Sn,
1168
- html: at,
1169
- render: Cs,
1170
- svg: Ga
1171
- }, Symbol.toStringTag, { value: "Module" })), ec = "0.0.0", nc = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1153
+ html: ht,
1154
+ render: Ps,
1155
+ svg: ja
1156
+ }, Symbol.toStringTag, { value: "Module" })), dc = "2.1.1", pc = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1172
1157
  __proto__: null,
1173
- version: ec
1174
- }, Symbol.toStringTag, { value: "Module" })), { deleteProperty: sc, getOwnPropertyDescriptor: $r, defineProperty: kn } = Reflect, { getPrototypeOf: Pt, assign: Er } = Object, Oi = new Da();
1175
- function Et(e, t, n) {
1158
+ version: dc
1159
+ }, Symbol.toStringTag, { value: "Module" })), { deleteProperty: fc, getOwnPropertyDescriptor: xr, defineProperty: kn } = Reflect, { getPrototypeOf: Ct, assign: Tr } = Object, Ii = new ec();
1160
+ function $t(e, t, n) {
1176
1161
  const s = e.metadata;
1177
- if (!$r(s, t)) {
1162
+ if (!xr(s, t)) {
1178
1163
  const i = new Set(s[t]);
1179
1164
  i.delete(n), kn(s, t, {
1180
1165
  value: [...i]
@@ -1183,54 +1168,54 @@ function Et(e, t, n) {
1183
1168
  s[t].push(n);
1184
1169
  }
1185
1170
  function xn(e, t) {
1186
- const { value: n } = $r(e, t);
1187
- sc(e, t), e[t] = n;
1171
+ const { value: n } = xr(e, t);
1172
+ fc(e, t), e[t] = n;
1188
1173
  }
1189
- const Fe = /* @__PURE__ */ new WeakMap(), { setAttribute: br, toggleAttribute: ic, removeAttribute: Cr } = Element.prototype;
1174
+ const Fe = /* @__PURE__ */ new WeakMap(), { setAttribute: Or, toggleAttribute: _c, removeAttribute: Mr } = Element.prototype;
1190
1175
  B.prototype.setAttribute = function(e, t) {
1191
1176
  var s;
1192
- const n = (s = Fe.get(Pt(this))) == null ? void 0 : s.get(e);
1193
- if (!n) return br.call(this, e, t);
1177
+ const n = (s = Fe.get(Ct(this))) == null ? void 0 : s.get(e);
1178
+ if (!n) return Or.call(this, e, t);
1194
1179
  this[n] = t;
1195
1180
  };
1196
1181
  B.prototype.removeAttribute = function(e) {
1197
1182
  var n;
1198
- const t = (n = Fe.get(Pt(this))) == null ? void 0 : n.get(e);
1199
- if (!t) return Cr.call(this, e);
1183
+ const t = (n = Fe.get(Ct(this))) == null ? void 0 : n.get(e);
1184
+ if (!t) return Mr.call(this, e);
1200
1185
  this[t] = null;
1201
1186
  };
1202
1187
  B.prototype.toggleAttribute = function(e, t) {
1203
1188
  var s;
1204
- const n = (s = Fe.get(Pt(this))) == null ? void 0 : s.get(e);
1205
- return n ? this[n] = t ?? !this.hasAttribute(e) : ic.call(this, e, t);
1189
+ const n = (s = Fe.get(Ct(this))) == null ? void 0 : s.get(e);
1190
+ return n ? this[n] = t ?? !this.hasAttribute(e) : _c.call(this, e, t);
1206
1191
  };
1207
- function rc() {
1192
+ function gc() {
1208
1193
  }
1209
- const Mi = Symbol("event handle");
1210
- function Ns(e, t, { attr: n, attrType: s, event: i, eventOptions: o } = {}) {
1194
+ const Ri = Symbol("event handle");
1195
+ function As(e, t, { attr: n, attrType: s, event: i, eventOptions: r } = {}) {
1211
1196
  kn(e, t, {
1212
1197
  configurable: !0,
1213
1198
  get() {
1214
- const c = Oi.get(this)[t];
1215
- return i && !c ? (this[t] = rc, this[t]) : c;
1199
+ const c = Ii.get(this)[t];
1200
+ return i && !c ? (this[t] = gc, this[t]) : c;
1216
1201
  },
1217
1202
  set(c) {
1218
- const a = this, f = Oi.get(a);
1219
- n && (c = s === Boolean && c === "" ? !0 : s(c || ""), c ? br.call(this, n, s === Boolean ? "" : c) : Cr.call(this, n)), c !== f[t] && (i ? (f[t] = c != null && c[Mi] ? c : (h, m) => {
1220
- const r = new CustomEvent(i, { ...m, ...o, detail: h });
1221
- a.dispatchEvent(r), c(h, m);
1222
- }, f[t][Mi] = !0) : (f[t] = c, this[Cn]()));
1203
+ const a = this, d = Ii.get(a);
1204
+ n && (c = s === Boolean && c === "" ? !0 : s(c || ""), c ? Or.call(this, n, s === Boolean ? "" : c) : Mr.call(this, n)), c !== d[t] && (i ? (d[t] = c != null && c[Ri] ? c : (f, g) => {
1205
+ const o = new CustomEvent(i, { ...g, ...r, detail: f });
1206
+ a.dispatchEvent(o), c(f, g);
1207
+ }, d[t][Ri] = !0) : (d[t] = c, this[Cn]()));
1223
1208
  }
1224
1209
  });
1225
1210
  }
1226
- function As(e, t) {
1211
+ function Is(e, t) {
1227
1212
  const n = e.name, s = oe(n);
1228
1213
  return e.addInitializer(function() {
1229
- const i = Pt(this);
1214
+ const i = Ct(this);
1230
1215
  if (!i.hasOwnProperty(n)) {
1231
- Et(e, "observedAttributes", s), Ns(i, n, { attr: s, attrType: t });
1232
- const o = Fe.get(i) || /* @__PURE__ */ new Map();
1233
- o.set(s, n), Fe.set(i, o);
1216
+ $t(e, "observedAttributes", s), As(i, n, { attr: s, attrType: t });
1217
+ const r = Fe.get(i) || /* @__PURE__ */ new Map();
1218
+ r.set(s, n), Fe.set(i, r);
1234
1219
  }
1235
1220
  xn(this, n);
1236
1221
  }), function(i) {
@@ -1238,44 +1223,44 @@ function As(e, t) {
1238
1223
  };
1239
1224
  }
1240
1225
  function V(e, t) {
1241
- return As(t, String);
1226
+ return Is(t, String);
1242
1227
  }
1243
1228
  function Tn(e, t) {
1244
- return As(t, Boolean);
1229
+ return Is(t, Boolean);
1245
1230
  }
1246
- function oc(e, t) {
1247
- return As(t, Number);
1231
+ function mc(e, t) {
1232
+ return Is(t, Number);
1248
1233
  }
1249
1234
  function U(e, t) {
1250
1235
  const n = t.name;
1251
1236
  return t.addInitializer(function() {
1252
- const s = Pt(this);
1253
- s.hasOwnProperty(n) || (Et(t, "observedProperties", n), Ns(s, n)), xn(this, n);
1237
+ const s = Ct(this);
1238
+ s.hasOwnProperty(n) || ($t(t, "observedProperties", n), As(s, n)), xn(this, n);
1254
1239
  }), function(s) {
1255
1240
  return this[n] ?? s;
1256
1241
  };
1257
1242
  }
1258
- function Pr(e) {
1243
+ function Lr(e) {
1259
1244
  return function(t, n) {
1260
- const { addInitializer: s, name: i, access: o, kind: c } = n;
1245
+ const { addInitializer: s, name: i, access: r, kind: c } = n;
1261
1246
  s(function() {
1262
1247
  const a = e && (() => e(this));
1263
1248
  if (c === "getter") {
1264
- if (n.private) throw new yt("not support");
1265
- this.memo(() => kn(this, i, { configurable: !0, value: o.get(this) }), a);
1249
+ if (n.private) throw new Lt("not support");
1250
+ this.memo(() => kn(this, i, { configurable: !0, value: r.get(this) }), a);
1266
1251
  } else
1267
- this.memo(o.get(this).bind(this), a);
1252
+ this.memo(r.get(this).bind(this), a);
1268
1253
  });
1269
1254
  };
1270
1255
  }
1271
- function $t(e) {
1256
+ function St(e) {
1272
1257
  return function(t, { addInitializer: n, access: s }) {
1273
1258
  n(function() {
1274
1259
  this.effect(s.get(this).bind(this), e && (() => e(this)));
1275
1260
  });
1276
1261
  };
1277
1262
  }
1278
- function ac() {
1263
+ function vc() {
1279
1264
  return function(e, { addInitializer: t, access: n }) {
1280
1265
  t(function() {
1281
1266
  this.effect(
@@ -1285,32 +1270,32 @@ function ac() {
1285
1270
  });
1286
1271
  };
1287
1272
  }
1288
- function Is() {
1289
- return Pr(() => []);
1273
+ function Rs() {
1274
+ return Lr(() => []);
1290
1275
  }
1291
1276
  function qe() {
1292
- return $t(() => []);
1277
+ return St(() => []);
1293
1278
  }
1294
- function kr(e) {
1279
+ function ae(e) {
1295
1280
  return function(t, { addInitializer: n, access: s }) {
1296
1281
  n(function() {
1297
- Ls(this, {
1282
+ Ns(this, {
1298
1283
  render: s.get(this).bind(this),
1299
1284
  condition: e && (() => e(this))
1300
1285
  });
1301
1286
  });
1302
1287
  };
1303
1288
  }
1304
- function cc() {
1289
+ function wc() {
1305
1290
  return function(e, { addInitializer: t, access: n }) {
1306
1291
  t(function() {
1307
- this.addEventListener(Os, ({ detail: s }) => {
1308
- Cs(n.get(this).apply(this, [s]), this.internals.shadowRoot || this);
1292
+ this.addEventListener(Ms, ({ detail: s }) => {
1293
+ Ps(n.get(this).apply(this, [s]), this.internals.shadowRoot || this);
1309
1294
  });
1310
1295
  });
1311
1296
  };
1312
1297
  }
1313
- function lc(e, t, n) {
1298
+ function yc(e, t, n) {
1314
1299
  kn(e, t, {
1315
1300
  configurable: !0,
1316
1301
  get() {
@@ -1318,87 +1303,87 @@ function lc(e, t, n) {
1318
1303
  return i == null ? void 0 : i.has(n);
1319
1304
  },
1320
1305
  set(s) {
1321
- const i = this, { states: o } = i.internals;
1322
- s ? o == null || o.add(n) : o == null || o.delete(n);
1306
+ const i = this, { states: r } = i.internals;
1307
+ s ? r == null || r.add(n) : r == null || r.delete(n);
1323
1308
  }
1324
1309
  });
1325
1310
  }
1326
1311
  function On(e, t) {
1327
1312
  t.addInitializer(function() {
1328
- const n = Pt(this), s = t.name;
1313
+ const n = Ct(this), s = t.name;
1329
1314
  if (!n.hasOwnProperty(s)) {
1330
1315
  const i = oe(s);
1331
- Et(t, "definedCSSStates", i), lc(n, s, i);
1316
+ $t(t, "definedCSSStates", i), yc(n, s, i);
1332
1317
  }
1333
1318
  xn(this, s);
1334
1319
  });
1335
1320
  }
1336
- function xr(e, t, n, s) {
1337
- const i = e.name, o = oe(i);
1321
+ function Nr(e, t, n, s) {
1322
+ const i = e.name, r = oe(i);
1338
1323
  if (e.static)
1339
- Et(e, n, o);
1324
+ $t(e, n, r);
1340
1325
  else {
1341
- const c = Pt(t);
1342
- c[i] || (c[i] = o, Et(e, n, o));
1326
+ const c = Ct(t);
1327
+ c[i] || (c[i] = r, $t(e, n, r));
1343
1328
  }
1344
- return s || o;
1329
+ return s || r;
1345
1330
  }
1346
- function hc(e, t) {
1331
+ function Sc(e, t) {
1347
1332
  return function(n) {
1348
- return xr(t, this, "definedSlots", n);
1333
+ return Nr(t, this, "definedSlots", n);
1349
1334
  };
1350
1335
  }
1351
- function Tr(e, t) {
1336
+ function Ar(e, t) {
1352
1337
  return function(n) {
1353
- return xr(t, this, "definedParts", n);
1338
+ return Nr(t, this, "definedParts", n);
1354
1339
  };
1355
1340
  }
1356
- function ye(e, t) {
1341
+ function Se(e, t) {
1357
1342
  t.addInitializer(function() {
1358
- Or(t, this, t.name);
1343
+ Ir(t, this, t.name);
1359
1344
  });
1360
1345
  }
1361
- function uc(e, t) {
1346
+ function $c(e, t) {
1362
1347
  t.addInitializer(function() {
1363
- Or(t, this, t.name, { bubbles: !0, composed: !0 });
1348
+ Ir(t, this, t.name, { bubbles: !0, composed: !0 });
1364
1349
  });
1365
1350
  }
1366
- function Or(e, t, n, s) {
1367
- const i = Pt(t);
1351
+ function Ir(e, t, n, s) {
1352
+ const i = Ct(t);
1368
1353
  if (!i.hasOwnProperty(n)) {
1369
- const o = oe(n);
1370
- Et(e, "definedEvents", o), Ns(i, n, { event: o, eventOptions: s });
1354
+ const r = oe(n);
1355
+ $t(e, "definedEvents", r), As(i, n, { event: r, eventOptions: s });
1371
1356
  }
1372
1357
  xn(t, n);
1373
1358
  }
1374
- function Rs(e) {
1359
+ function Hs(e) {
1375
1360
  return function(t, n) {
1376
- Et(n, "adoptedStyleSheets", e);
1361
+ $t(n, "adoptedStyleSheets", e);
1377
1362
  };
1378
1363
  }
1379
1364
  function Mn(e) {
1380
1365
  return function(t, n) {
1381
- Et(n, "observedStores", e);
1366
+ $t(n, "observedStores", e);
1382
1367
  };
1383
1368
  }
1384
- function Ht({
1369
+ function zt({
1385
1370
  mode: e = "open",
1386
1371
  serializable: t = !0,
1387
1372
  delegatesFocus: n,
1388
1373
  slotAssignment: s
1389
1374
  } = {}) {
1390
- return function(i, o) {
1391
- const c = o.metadata;
1392
- Er(c, { mode: e, serializable: t, delegatesFocus: n, slotAssignment: s });
1375
+ return function(i, r) {
1376
+ const c = r.metadata;
1377
+ Tr(c, { mode: e, serializable: t, delegatesFocus: n, slotAssignment: s });
1393
1378
  };
1394
1379
  }
1395
- function Mr({ penetrable: e }) {
1380
+ function Rr({ penetrable: e }) {
1396
1381
  return function(t, n) {
1397
1382
  const s = n.metadata;
1398
1383
  s.penetrable = e;
1399
1384
  };
1400
1385
  }
1401
- function dc() {
1386
+ function Ec() {
1402
1387
  return function(e, t) {
1403
1388
  const n = t.metadata;
1404
1389
  n.noBlocking = !0;
@@ -1410,147 +1395,147 @@ function Ln(e) {
1410
1395
  s.aria = { ...s.aria, ...e };
1411
1396
  };
1412
1397
  }
1413
- function pc(e) {
1398
+ function bc(e) {
1414
1399
  return function(t, { addInitializer: n }) {
1415
1400
  n(function() {
1416
1401
  customElements.define(e, t);
1417
1402
  });
1418
1403
  };
1419
1404
  }
1420
- window.__GEM_DEVTOOLS__HOOK__ && !window.__GEM_DEVTOOLS__HOOK__.GemElement && Er(window.__GEM_DEVTOOLS__HOOK__, {
1421
- ...tc,
1422
- ...Ta,
1423
- ...Ba,
1424
- ...nc
1405
+ window.__GEM_DEVTOOLS__HOOK__ && !window.__GEM_DEVTOOLS__HOOK__.GemElement && Tr(window.__GEM_DEVTOOLS__HOOK__, {
1406
+ ...uc,
1407
+ ...Ha,
1408
+ ...ic,
1409
+ ...pc
1425
1410
  });
1426
- const J = window.history, Lr = J.pushState.bind(J), Nr = J.replaceState.bind(J);
1427
- let fc = 0;
1428
- const Hs = () => `${performance.now()}-${++fc}`, [R, Ut] = Xe({
1411
+ const Y = window.history, Hr = Y.pushState.bind(Y), Wr = Y.replaceState.bind(Y);
1412
+ let Cc = 0;
1413
+ const Ws = () => `${performance.now()}-${++Cc}`, T = Wt({
1429
1414
  $hasCloseHandle: !1,
1430
1415
  $hasOpenHandle: !1,
1431
1416
  $hasShouldCloseHandle: !1,
1432
1417
  $key: ""
1433
1418
  }), q = /* @__PURE__ */ new Map();
1434
- function Ar(e) {
1419
+ function zr(e) {
1435
1420
  const { $key: t, $hasCloseHandle: n, $hasOpenHandle: s, $hasShouldCloseHandle: i } = e || {};
1436
- if (R.$key !== t) {
1437
- if (t) throw new yt("`$key` is not allowed");
1438
- if (n) throw new yt("`$hasCloseHandle` is not allowed");
1439
- if (s) throw new yt("`$hasOpenHandle` is not allowed");
1440
- if (i) throw new yt("`$hasShouldCloseHandle` is not allowed");
1421
+ if (T.$key !== t) {
1422
+ if (t) throw new Lt("`$key` is not allowed");
1423
+ if (n) throw new Lt("`$hasCloseHandle` is not allowed");
1424
+ if (s) throw new Lt("`$hasOpenHandle` is not allowed");
1425
+ if (i) throw new Lt("`$hasShouldCloseHandle` is not allowed");
1441
1426
  }
1442
1427
  }
1443
- function Ir(e) {
1444
- return Y.basePath ? Y.basePath + e : e;
1428
+ function Gr(e) {
1429
+ return Q.basePath ? Q.basePath + e : e;
1445
1430
  }
1446
1431
  function ts(e) {
1447
- return e === Y.basePath ? "/" : e.replace(new RegExp(`^${Y.basePath}/`), "/");
1432
+ return e === Q.basePath ? "/" : e.replace(new RegExp(`^${Q.basePath}/`), "/");
1448
1433
  }
1449
- function Ws() {
1450
- Y.dispatchEvent(new CustomEvent("beforechange"));
1434
+ function zs() {
1435
+ Q.dispatchEvent(new CustomEvent("beforechange"));
1451
1436
  }
1452
1437
  function dn(e) {
1453
- const t = q.get(R.$key) || { path: ts(location.pathname), query: new De() }, n = e.path ? gr(t.path, e.path) : ts(location.pathname), s = new De(e.query ?? (e.path ? "" : location.search)), i = String(s) !== String(t.query), o = i ? s : t.query, c = n !== t.path || i, a = e.title || (c ? "" : document.title), f = e.close || e.data || e.open || e.shouldClose, h = decodeURIComponent(e.hash ?? (!c && f ? location.hash : ""));
1454
- return { ...e, title: a, path: n, query: o, hash: h };
1438
+ const t = q.get(T.$key) || { path: ts(location.pathname), query: new De() }, n = e.path ? $r(t.path, e.path) : ts(location.pathname), s = new De(e.query ?? (e.path ? "" : location.search)), i = String(s) !== String(t.query), r = i ? s : t.query, c = n !== t.path || i, a = e.title || (c ? "" : document.title), d = e.close || e.data || e.open || e.shouldClose, f = decodeURIComponent(e.hash ?? (!c && d ? location.hash : ""));
1439
+ return { ...e, title: a, path: n, query: r, hash: f };
1455
1440
  }
1456
- function Li(e, t) {
1457
- Ar(e.data);
1458
- const n = dn(e), { title: s, path: i, query: o, hash: c, close: a, open: f, shouldClose: h, data: m } = n, r = {
1441
+ function Hi(e, t) {
1442
+ zr(e.data);
1443
+ const n = dn(e), { title: s, path: i, query: r, hash: c, close: a, open: d, shouldClose: f, data: g } = n, o = {
1459
1444
  $hasCloseHandle: !!a,
1460
- $hasOpenHandle: !!f,
1461
- $hasShouldCloseHandle: !!h,
1462
- $key: Hs(),
1445
+ $hasOpenHandle: !!d,
1446
+ $hasShouldCloseHandle: !!f,
1447
+ $key: Ws(),
1463
1448
  $title: s,
1464
- ...m
1449
+ ...g
1465
1450
  };
1466
- q.set(r.$key, n), Ws(), ks(R), Ut(r);
1467
- const _ = Ir(i) + new De(o) + c, l = decodeURIComponent(location.hash);
1468
- t(r, s, _), l !== c && window.dispatchEvent(new CustomEvent("hashchange"));
1451
+ q.set(o.$key, n), zs(), xs(T), T(o);
1452
+ const _ = Gr(i) + new De(r) + c, h = decodeURIComponent(location.hash);
1453
+ t(o, s, _), h !== c && window.dispatchEvent(new CustomEvent("hashchange"));
1469
1454
  }
1470
- function Ni(e, t, n, s) {
1471
- Ar(e);
1455
+ function Wi(e, t, n, s) {
1456
+ zr(e);
1472
1457
  const i = {
1473
- $key: Hs(),
1458
+ $key: Ws(),
1474
1459
  $title: t,
1475
1460
  ...e || {}
1476
- }, { pathname: o, search: c, hash: a } = new URL(n, location.origin + location.pathname), f = dn({ path: o, query: new De(c), hash: a, title: t, data: e });
1477
- q.set(i.$key, f), Ws(), ks(R), Ut(i);
1478
- const h = Ir(o) + f.query + a, m = location.hash;
1479
- s(i, t, h), m !== a && window.dispatchEvent(new CustomEvent("hashchange"));
1461
+ }, { pathname: r, search: c, hash: a } = new URL(n, location.origin + location.pathname), d = dn({ path: r, query: new De(c), hash: a, title: t, data: e });
1462
+ q.set(i.$key, d), zs(), xs(T), T(i);
1463
+ const f = Gr(r) + d.query + a, g = location.hash;
1464
+ s(i, t, f), g !== a && window.dispatchEvent(new CustomEvent("hashchange"));
1480
1465
  }
1481
- const [Rr, _c] = Xe({
1466
+ const es = Wt({
1482
1467
  basePath: ""
1483
1468
  });
1484
- class gc extends EventTarget {
1469
+ class Pc extends EventTarget {
1485
1470
  get store() {
1486
- return R;
1471
+ return T;
1487
1472
  }
1488
1473
  get currentKey() {
1489
- return R.$key;
1474
+ return T.$key;
1490
1475
  }
1491
1476
  get basePath() {
1492
- return Rr.basePath;
1477
+ return es.basePath;
1493
1478
  }
1494
1479
  set basePath(t) {
1495
- _c({ basePath: t }), Object.assign(q.get(R.$key), { path: ts(location.pathname) });
1480
+ es({ basePath: t }), Object.assign(q.get(T.$key), { path: ts(location.pathname) });
1496
1481
  }
1497
1482
  getParams() {
1498
- return q.get(R.$key);
1483
+ return q.get(T.$key);
1499
1484
  }
1500
1485
  updateParams(t) {
1501
- Object.assign(q.get(R.$key), t), Ut();
1486
+ Object.assign(q.get(T.$key), t), T();
1502
1487
  }
1503
1488
  push(t) {
1504
- Li(t, Lr);
1489
+ Hi(t, Hr);
1505
1490
  }
1506
1491
  replace(t) {
1507
- Li(t, Nr);
1492
+ Hi(t, Wr);
1508
1493
  }
1509
1494
  pushIgnoreCloseHandle(t) {
1510
1495
  var n, s;
1511
- R.$hasCloseHandle ? ((s = (n = q.get(R.$key)) == null ? void 0 : n.close) == null || s.call(n), this.replace(t)) : this.push(t);
1496
+ T.$hasCloseHandle ? ((s = (n = q.get(T.$key)) == null ? void 0 : n.close) == null || s.call(n), this.replace(t)) : this.push(t);
1512
1497
  }
1513
1498
  forward() {
1514
- J.forward();
1499
+ Y.forward();
1515
1500
  }
1516
1501
  back() {
1517
- J.back();
1502
+ Y.back();
1518
1503
  }
1519
1504
  }
1520
- const Y = new gc(), [rn, mc] = Xe({ defaultTitle: document.title, url: "", title: "" }), vc = { history: Y, titleStore: rn, basePathStore: Rr };
1505
+ const Q = new Pc(), $e = Wt({ defaultTitle: document.title, url: "", title: "" }), kc = { history: Q, titleStore: $e, basePathStore: es };
1521
1506
  if (!window._GEMHISTORY) {
1522
- if (window._GEMHISTORY = vc, J.pushState = function(t, n, s) {
1523
- Ni(t, n, s, Lr);
1524
- }, J.replaceState = function(t, n, s) {
1525
- Ni(t, n, s, Nr);
1507
+ if (window._GEMHISTORY = kc, Y.pushState = function(t, n, s) {
1508
+ Wi(t, n, s, Hr);
1509
+ }, Y.replaceState = function(t, n, s) {
1510
+ Wi(t, n, s, Wr);
1526
1511
  }, window.addEventListener("hashchange", ({ isTrusted: t }) => {
1527
- t && Y.replace({ hash: location.hash });
1528
- }), J.state)
1529
- if (J.state.$hasCloseHandle) {
1530
- Ut(J.state);
1512
+ t && Q.replace({ hash: location.hash });
1513
+ }), Y.state)
1514
+ if (Y.state.$hasCloseHandle) {
1515
+ T(Y.state);
1531
1516
  const t = dn({ title: document.title });
1532
- q.set(R.$key, t), Y.back();
1517
+ q.set(T.$key, t), Q.back();
1533
1518
  } else {
1534
1519
  const t = dn({ title: document.title, hash: location.hash });
1535
- Ut({
1536
- $key: Hs(),
1537
- ...J.state || {}
1538
- }), q.set(R.$key, t);
1520
+ T({
1521
+ $key: Ws(),
1522
+ ...Y.state || {}
1523
+ }), q.set(T.$key, t);
1539
1524
  }
1540
1525
  else {
1541
1526
  const { protocol: t, pathname: n, search: s, hash: i } = location;
1542
- t.startsWith("http") && Y.replace({ path: n, query: s, hash: i });
1543
- }
1544
- ft(rn, () => {
1545
- const t = q.get(R.$key);
1546
- t && (t.title = rn.title);
1547
- }), ft(R, () => {
1548
- const { title: t } = Y.getParams();
1549
- t !== rn.title && mc({ title: t });
1527
+ t.startsWith("http") && Q.replace({ path: n, query: s, hash: i });
1528
+ }
1529
+ ft($e, () => {
1530
+ const t = q.get(T.$key);
1531
+ t && (t.title = $e.title);
1532
+ }), ft(T, () => {
1533
+ const { title: t } = Q.getParams();
1534
+ t !== $e.title && $e({ title: t });
1550
1535
  });
1551
1536
  let e = !1;
1552
1537
  window.addEventListener("popstate", (t) => {
1553
- var o, c;
1538
+ var r, c;
1554
1539
  const n = t.state;
1555
1540
  if (!(n != null && n.$key))
1556
1541
  return;
@@ -1559,31 +1544,31 @@ if (!window._GEMHISTORY) {
1559
1544
  return;
1560
1545
  }
1561
1546
  if (!q.has(n.$key)) {
1562
- const { pathname: a, search: f, hash: h } = location;
1547
+ const { pathname: a, search: d, hash: f } = location;
1563
1548
  q.set(n.$key, {
1564
1549
  path: a,
1565
- query: new De(f),
1566
- hash: decodeURIComponent(h),
1550
+ query: new De(d),
1551
+ hash: decodeURIComponent(f),
1567
1552
  title: n.$title,
1568
1553
  // document.title 是导航前的
1569
1554
  data: n
1570
1555
  });
1571
1556
  }
1572
- const s = R;
1557
+ const s = T;
1573
1558
  if (parseFloat(n.$key) > parseFloat(s.$key) && n.$hasOpenHandle)
1574
- (c = (o = q.get(n.$key)) == null ? void 0 : o.open) == null || c.call(o);
1559
+ (c = (r = q.get(n.$key)) == null ? void 0 : r.open) == null || c.call(r);
1575
1560
  else if (s.$hasCloseHandle) {
1576
- const a = q.get(s.$key), f = a == null ? void 0 : a.close, h = a == null ? void 0 : a.shouldClose;
1577
- if (h && !h()) {
1578
- e = !0, Y.forward();
1561
+ const a = q.get(s.$key), d = a == null ? void 0 : a.close, f = a == null ? void 0 : a.shouldClose;
1562
+ if (f && !f()) {
1563
+ e = !0, Q.forward();
1579
1564
  return;
1580
1565
  } else
1581
- f ? f() : n.$hasCloseHandle && (e = !0, Y.back());
1566
+ d ? d() : n.$hasCloseHandle && (e = !0, Q.back());
1582
1567
  }
1583
- Ws(), ks(R), Ut(n);
1568
+ zs(), xs(T), T(n);
1584
1569
  });
1585
1570
  }
1586
- const { history: O, titleStore: At, basePathStore: wc } = window._GEMHISTORY;
1571
+ const { history: M, titleStore: Rt, basePathStore: xc } = window._GEMHISTORY;
1587
1572
  /**
1588
1573
  * @license
1589
1574
  * Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
@@ -1597,66 +1582,66 @@ const { history: O, titleStore: At, basePathStore: wc } = window._GEMHISTORY;
1597
1582
  * subject to an additional IP rights grant found at
1598
1583
  * http://polymer.github.io/PATENTS.txt
1599
1584
  */
1600
- const Ai = (e, t) => {
1601
- const n = e.startNode.parentNode, s = t === void 0 ? e.endNode : t.startNode, i = n.insertBefore(ot(), s);
1602
- n.insertBefore(ot(), s);
1603
- const o = new re(e.options);
1604
- return o.insertAfterNode(i), o;
1605
- }, kt = (e, t) => (e.setValue(t), e.commit(), e), Vn = (e, t, n) => {
1606
- const s = e.startNode.parentNode, i = n ? n.startNode : e.endNode, o = t.endNode.nextSibling;
1607
- o !== i && hr(s, t.startNode, o, i);
1608
- }, Dn = (e) => {
1609
- $s(e.startNode.parentNode, e.startNode, e.endNode.nextSibling);
1610
- }, Ii = (e, t, n) => {
1585
+ const zi = (e, t) => {
1586
+ const n = e.startNode.parentNode, s = t === void 0 ? e.endNode : t.startNode, i = n.insertBefore(ct(), s);
1587
+ n.insertBefore(ct(), s);
1588
+ const r = new re(e.options);
1589
+ return r.insertAfterNode(i), r;
1590
+ }, Pt = (e, t) => (e.setValue(t), e.commit(), e), Dn = (e, t, n) => {
1591
+ const s = e.startNode.parentNode, i = n ? n.startNode : e.endNode, r = t.endNode.nextSibling;
1592
+ r !== i && gr(s, t.startNode, r, i);
1593
+ }, Fn = (e) => {
1594
+ Es(e.startNode.parentNode, e.startNode, e.endNode.nextSibling);
1595
+ }, Gi = (e, t, n) => {
1611
1596
  const s = /* @__PURE__ */ new Map();
1612
1597
  for (let i = t; i <= n; i++)
1613
1598
  s.set(e[i], i);
1614
1599
  return s;
1615
- }, Ri = /* @__PURE__ */ new WeakMap(), Hi = /* @__PURE__ */ new WeakMap(), Fl = Sn((e, t, n) => {
1600
+ }, Vi = /* @__PURE__ */ new WeakMap(), Di = /* @__PURE__ */ new WeakMap(), Xh = Sn((e, t, n) => {
1616
1601
  let s;
1617
1602
  return n === void 0 ? n = t : t !== void 0 && (s = t), (i) => {
1618
1603
  if (!(i instanceof re))
1619
1604
  throw new Error("repeat can only be used in text bindings");
1620
- const o = Ri.get(i) || [], c = Hi.get(i) || [], a = [], f = [], h = [];
1621
- let m = 0;
1622
- for (const $ of e)
1623
- h[m] = s ? s($, m) : m, f[m] = n($, m), m++;
1624
- let r, _, l = 0, g = o.length - 1, v = 0, y = f.length - 1;
1625
- for (; l <= g && v <= y; )
1626
- if (o[l] === null)
1627
- l++;
1628
- else if (o[g] === null)
1629
- g--;
1630
- else if (c[l] === h[v])
1631
- a[v] = kt(o[l], f[v]), l++, v++;
1632
- else if (c[g] === h[y])
1633
- a[y] = kt(o[g], f[y]), g--, y--;
1634
- else if (c[l] === h[y])
1635
- a[y] = kt(o[l], f[y]), Vn(i, o[l], a[y + 1]), l++, y--;
1636
- else if (c[g] === h[v])
1637
- a[v] = kt(o[g], f[v]), Vn(i, o[g], o[l]), g--, v++;
1638
- else if (r === void 0 && (r = Ii(h, v, y), _ = Ii(c, l, g)), !r.has(c[l]))
1639
- Dn(o[l]), l++;
1640
- else if (!r.has(c[g]))
1641
- Dn(o[g]), g--;
1605
+ const r = Vi.get(i) || [], c = Di.get(i) || [], a = [], d = [], f = [];
1606
+ let g = 0;
1607
+ for (const E of e)
1608
+ f[g] = s ? s(E, g) : g, d[g] = n(E, g), g++;
1609
+ let o, _, h = 0, m = r.length - 1, v = 0, y = d.length - 1;
1610
+ for (; h <= m && v <= y; )
1611
+ if (r[h] === null)
1612
+ h++;
1613
+ else if (r[m] === null)
1614
+ m--;
1615
+ else if (c[h] === f[v])
1616
+ a[v] = Pt(r[h], d[v]), h++, v++;
1617
+ else if (c[m] === f[y])
1618
+ a[y] = Pt(r[m], d[y]), m--, y--;
1619
+ else if (c[h] === f[y])
1620
+ a[y] = Pt(r[h], d[y]), Dn(i, r[h], a[y + 1]), h++, y--;
1621
+ else if (c[m] === f[v])
1622
+ a[v] = Pt(r[m], d[v]), Dn(i, r[m], r[h]), m--, v++;
1623
+ else if (o === void 0 && (o = Gi(f, v, y), _ = Gi(c, h, m)), !o.has(c[h]))
1624
+ Fn(r[h]), h++;
1625
+ else if (!o.has(c[m]))
1626
+ Fn(r[m]), m--;
1642
1627
  else {
1643
- const $ = _.get(h[v]), d = $ !== void 0 ? o[$] : null;
1644
- if (d === null) {
1645
- const S = Ai(i, o[l]);
1646
- kt(S, f[v]), a[v] = S;
1628
+ const E = _.get(f[v]), u = E !== void 0 ? r[E] : null;
1629
+ if (u === null) {
1630
+ const S = zi(i, r[h]);
1631
+ Pt(S, d[v]), a[v] = S;
1647
1632
  } else
1648
- a[v] = kt(d, f[v]), Vn(i, d, o[l]), o[$] = null;
1633
+ a[v] = Pt(u, d[v]), Dn(i, u, r[h]), r[E] = null;
1649
1634
  v++;
1650
1635
  }
1651
1636
  for (; v <= y; ) {
1652
- const $ = Ai(i, a[y + 1]);
1653
- kt($, f[v]), a[v++] = $;
1637
+ const E = zi(i, a[y + 1]);
1638
+ Pt(E, d[v]), a[v++] = E;
1654
1639
  }
1655
- for (; l <= g; ) {
1656
- const $ = o[l++];
1657
- $ !== null && Dn($);
1640
+ for (; h <= m; ) {
1641
+ const E = r[h++];
1642
+ E !== null && Fn(E);
1658
1643
  }
1659
- Ri.set(i, a), Hi.set(i, h);
1644
+ Vi.set(i, a), Di.set(i, f);
1660
1645
  };
1661
1646
  });
1662
1647
  /**
@@ -1672,14 +1657,14 @@ const Ai = (e, t) => {
1672
1657
  * subject to an additional IP rights grant found at
1673
1658
  * http://polymer.github.io/PATENTS.txt
1674
1659
  */
1675
- const Fn = /* @__PURE__ */ new WeakMap(), ql = Sn((e, t) => (n) => {
1676
- const s = Fn.get(n);
1660
+ const qn = /* @__PURE__ */ new WeakMap(), Zh = Sn((e, t) => (n) => {
1661
+ const s = qn.get(n);
1677
1662
  if (Array.isArray(e)) {
1678
- if (Array.isArray(s) && s.length === e.length && e.every((i, o) => i === s[o]))
1663
+ if (Array.isArray(s) && s.length === e.length && e.every((i, r) => i === s[r]))
1679
1664
  return;
1680
- } else if (s === e && (e !== void 0 || Fn.has(n)))
1665
+ } else if (s === e && (e !== void 0 || qn.has(n)))
1681
1666
  return;
1682
- n.setValue(t()), Fn.set(n, Array.isArray(e) ? Array.from(e) : e);
1667
+ n.setValue(t()), qn.set(n, Array.isArray(e) ? Array.from(e) : e);
1683
1668
  });
1684
1669
  /**
1685
1670
  * @license
@@ -1694,222 +1679,222 @@ const Fn = /* @__PURE__ */ new WeakMap(), ql = Sn((e, t) => (n) => {
1694
1679
  * subject to an additional IP rights grant found at
1695
1680
  * http://polymer.github.io/PATENTS.txt
1696
1681
  */
1697
- const qn = /* @__PURE__ */ new WeakMap(), yc = Sn((e) => (t) => {
1698
- const n = qn.get(t);
1699
- if (e === void 0 && t instanceof bs) {
1700
- if (n !== void 0 || !qn.has(t)) {
1682
+ const Un = /* @__PURE__ */ new WeakMap(), Tc = Sn((e) => (t) => {
1683
+ const n = Un.get(t);
1684
+ if (e === void 0 && t instanceof Cs) {
1685
+ if (n !== void 0 || !Un.has(t)) {
1701
1686
  const s = t.committer.name;
1702
1687
  t.committer.element.removeAttribute(s);
1703
1688
  }
1704
1689
  } else e !== n && t.setValue(e);
1705
- qn.set(t, e);
1690
+ Un.set(t, e);
1706
1691
  });
1707
- var Sc = Object.create, zs = Object.defineProperty, $c = Object.getOwnPropertyDescriptor, Hr = (e, t) => (t = Symbol[e]) ? t : Symbol.for("Symbol." + e), ae = (e) => {
1692
+ var Oc = Object.create, Gs = Object.defineProperty, Mc = Object.getOwnPropertyDescriptor, Vr = (e, t) => (t = Symbol[e]) ? t : Symbol.for("Symbol." + e), ce = (e) => {
1708
1693
  throw TypeError(e);
1709
- }, Wr = (e, t, n) => t in e ? zs(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n, Wi = (e, t) => zs(e, "name", { value: t, configurable: !0 }), zr = (e) => [, , , Sc((e == null ? void 0 : e[Hr("metadata")]) ?? null)], Gr = ["class", "method", "getter", "setter", "accessor", "field", "value", "get", "set"], Se = (e) => e !== void 0 && typeof e != "function" ? ae("Function expected") : e, Ec = (e, t, n, s, i) => ({ kind: Gr[e], name: t, metadata: s, addInitializer: (o) => n._ ? ae("Already initialized") : i.push(Se(o || null)) }), bc = (e, t) => Wr(t, Hr("metadata"), e[3]), P = (e, t, n, s) => {
1710
- for (var i = 0, o = e[t >> 1], c = o && o.length; i < c; i++) t & 1 ? o[i].call(n) : s = o[i].call(n, s);
1694
+ }, Dr = (e, t, n) => t in e ? Gs(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n, Fi = (e, t) => Gs(e, "name", { value: t, configurable: !0 }), Fr = (e) => [, , , Oc((e == null ? void 0 : e[Vr("metadata")]) ?? null)], qr = ["class", "method", "getter", "setter", "accessor", "field", "value", "get", "set"], Ee = (e) => e !== void 0 && typeof e != "function" ? ce("Function expected") : e, Lc = (e, t, n, s, i) => ({ kind: qr[e], name: t, metadata: s, addInitializer: (r) => n._ ? ce("Already initialized") : i.push(Ee(r || null)) }), Nc = (e, t) => Dr(t, Vr("metadata"), e[3]), P = (e, t, n, s) => {
1695
+ for (var i = 0, r = e[t >> 1], c = r && r.length; i < c; i++) t & 1 ? r[i].call(n) : s = r[i].call(n, s);
1711
1696
  return s;
1712
- }, W = (e, t, n, s, i, o) => {
1713
- var c, a, f, h, m, r = t & 7, _ = !!(t & 8), l = !!(t & 16), g = r > 3 ? e.length + 1 : r ? _ ? 1 : 2 : 0, v = Gr[r + 5], y = r > 3 && (e[g - 1] = []), $ = e[g] || (e[g] = []), d = r && (!l && !_ && (i = i.prototype), r < 5 && (r > 3 || !l) && $c(r < 4 ? i : { get [n]() {
1714
- return I(this, o);
1715
- }, set [n](u) {
1716
- return pn(this, o, u);
1697
+ }, z = (e, t, n, s, i, r) => {
1698
+ var c, a, d, f, g, o = t & 7, _ = !!(t & 8), h = !!(t & 16), m = o > 3 ? e.length + 1 : o ? _ ? 1 : 2 : 0, v = qr[o + 5], y = o > 3 && (e[m - 1] = []), E = e[m] || (e[m] = []), u = o && (!h && !_ && (i = i.prototype), o < 5 && (o > 3 || !h) && Mc(o < 4 ? i : { get [n]() {
1699
+ return H(this, r);
1700
+ }, set [n](l) {
1701
+ return pn(this, r, l);
1717
1702
  } }, n));
1718
- r ? l && r < 4 && Wi(o, (r > 2 ? "set " : r > 1 ? "get " : "") + n) : Wi(i, n);
1703
+ o ? h && o < 4 && Fi(r, (o > 2 ? "set " : o > 1 ? "get " : "") + n) : Fi(i, n);
1719
1704
  for (var S = s.length - 1; S >= 0; S--)
1720
- h = Ec(r, n, f = {}, e[3], $), r && (h.static = _, h.private = l, m = h.access = { has: l ? (u) => Cc(i, u) : (u) => n in u }, r ^ 3 && (m.get = l ? (u) => (r ^ 1 ? I : Pc)(u, i, r ^ 4 ? o : d.get) : (u) => u[n]), r > 2 && (m.set = l ? (u, k) => pn(u, i, k, r ^ 4 ? o : d.set) : (u, k) => u[n] = k)), a = (0, s[S])(r ? r < 4 ? l ? o : d[v] : r > 4 ? void 0 : { get: d.get, set: d.set } : i, h), f._ = 1, r ^ 4 || a === void 0 ? Se(a) && (r > 4 ? y.unshift(a) : r ? l ? o = a : d[v] = a : i = a) : typeof a != "object" || a === null ? ae("Object expected") : (Se(c = a.get) && (d.get = c), Se(c = a.set) && (d.set = c), Se(c = a.init) && y.unshift(c));
1721
- return r || bc(e, i), d && zs(i, n, d), l ? r ^ 4 ? o : d : i;
1722
- }, z = (e, t, n) => Wr(e, typeof t != "symbol" ? t + "" : t, n), Gs = (e, t, n) => t.has(e) || ae("Cannot " + n), Cc = (e, t) => Object(t) !== t ? ae('Cannot use the "in" operator on this value') : e.has(t), I = (e, t, n) => (Gs(e, t, "read from private field"), n ? n.call(e) : t.get(e)), Z = (e, t, n) => t.has(e) ? ae("Cannot add the same private member more than once") : t instanceof WeakSet ? t.add(e) : t.set(e, n), pn = (e, t, n, s) => (Gs(e, t, "write to private field"), s ? s.call(e, n) : t.set(e, n), n), Pc = (e, t, n) => (Gs(e, t, "access private method"), n), Vr, Dr, Fr, qr, Ur, Br, Kr, jr, Jr, Yr, Qr, Xr, Zr, to, eo, es, no, w, xt, Vt, $e, on, ns, Ee, an, Vs, Ds, ss, Fs, qs, so, Us, io;
1723
- const ro = "_";
1724
- class kc extends RegExp {
1705
+ f = Lc(o, n, d = {}, e[3], E), o && (f.static = _, f.private = h, g = f.access = { has: h ? (l) => Ac(i, l) : (l) => n in l }, o ^ 3 && (g.get = h ? (l) => (o ^ 1 ? H : Ic)(l, i, o ^ 4 ? r : u.get) : (l) => l[n]), o > 2 && (g.set = h ? (l, k) => pn(l, i, k, o ^ 4 ? r : u.set) : (l, k) => l[n] = k)), a = (0, s[S])(o ? o < 4 ? h ? r : u[v] : o > 4 ? void 0 : { get: u.get, set: u.set } : i, f), d._ = 1, o ^ 4 || a === void 0 ? Ee(a) && (o > 4 ? y.unshift(a) : o ? h ? r = a : u[v] = a : i = a) : typeof a != "object" || a === null ? ce("Object expected") : (Ee(c = a.get) && (u.get = c), Ee(c = a.set) && (u.set = c), Ee(c = a.init) && y.unshift(c));
1706
+ return o || Nc(e, i), u && Gs(i, n, u), h ? o ^ 4 ? r : u : i;
1707
+ }, G = (e, t, n) => Dr(e, typeof t != "symbol" ? t + "" : t, n), Vs = (e, t, n) => t.has(e) || ce("Cannot " + n), Ac = (e, t) => Object(t) !== t ? ce('Cannot use the "in" operator on this value') : e.has(t), H = (e, t, n) => (Vs(e, t, "read from private field"), n ? n.call(e) : t.get(e)), et = (e, t, n) => t.has(e) ? ce("Cannot add the same private member more than once") : t instanceof WeakSet ? t.add(e) : t.set(e, n), pn = (e, t, n, s) => (Vs(e, t, "write to private field"), s ? s.call(e, n) : t.set(e, n), n), Ic = (e, t, n) => (Vs(e, t, "access private method"), n), Ur, Br, Kr, jr, Jr, Yr, Qr, Xr, Zr, to, eo, no, so, io, ro, ns, oo, w, kt, qt, be, sn, ss, Ce, rn, Ds, Fs, is, qs, Us, ao, Bs, co;
1708
+ const ho = "_";
1709
+ class Rc extends RegExp {
1725
1710
  constructor(t) {
1726
1711
  let n = 0;
1727
1712
  super(
1728
- `^${t.replace(/((:[^/$]+)|(\*))/g, (s, i) => i === "*" ? `(?<${ro}${n++}>.*)` : `(?<${i.slice(1)}>[^/]+)`)}$`
1713
+ `^${t.replace(/((:[^/$]+)|(\*))/g, (s, i) => i === "*" ? `(?<${ho}${n++}>.*)` : `(?<${i.slice(1)}>[^/]+)`)}$`
1729
1714
  );
1730
1715
  }
1731
1716
  }
1732
- function oo(e, t) {
1717
+ function lo(e, t) {
1733
1718
  if (window.URLPattern) {
1734
- const o = new window.URLPattern({ pathname: e }), c = o.exec({ pathname: t }) || o.exec({ pathname: `${t}/` });
1719
+ const r = new window.URLPattern({ pathname: e }), c = r.exec({ pathname: t }) || r.exec({ pathname: `${t}/` });
1735
1720
  return c ? c.pathname.groups : null;
1736
1721
  }
1737
- const n = new kc(e), s = t.match(n) || `${t}/`.match(n);
1722
+ const n = new Rc(e), s = t.match(n) || `${t}/`.match(n);
1738
1723
  if (!s) return null;
1739
1724
  const i = {};
1740
- return s.groups && Object.entries(s.groups).forEach(([o, c]) => {
1741
- i[o.startsWith(ro) ? o.slice(1) : o] = c;
1725
+ return s.groups && Object.entries(s.groups).forEach(([r, c]) => {
1726
+ i[r.startsWith(ho) ? r.slice(1) : r] = c;
1742
1727
  }), i;
1743
1728
  }
1744
- function Bs(e, t) {
1729
+ function Ks(e, t) {
1745
1730
  let n = 0, s = e.pattern.replaceAll("*", () => `:${n++}`);
1746
1731
  const i = t == null ? void 0 : t.params;
1747
- return i && Object.keys(i).forEach((o) => {
1748
- s = s.replace(new RegExp(`:${o}`, "g"), i[o]);
1732
+ return i && Object.keys(i).forEach((r) => {
1733
+ s = s.replace(new RegExp(`:${r}`, "g"), i[r]);
1749
1734
  }), s;
1750
1735
  }
1751
- function xc(e, t) {
1736
+ function Hc(e, t) {
1752
1737
  return {
1753
- path: Bs(e, t),
1738
+ path: Ks(e, t),
1754
1739
  ...t
1755
1740
  };
1756
1741
  }
1757
- const Un = at``, zi = /* @__PURE__ */ new Map();
1758
- no = [Mr({ penetrable: !0 })];
1759
- class N extends (es = B, eo = [Tn], to = [U], Zr = [U], Xr = [U], Qr = [ye], Yr = [ye], Jr = [ye], jr = [ye], Kr = [U], Br = [U], Ur = [U], qr = [$t((t) => [t.scrollContainer])], Fr = [$t((t) => [t.scrollContainer])], Dr = [$t((t) => {
1742
+ const Bn = ht``, qi = /* @__PURE__ */ new Map();
1743
+ oo = [Rr({ penetrable: !0 })];
1744
+ class R extends (ns = B, ro = [Tn], io = [U], so = [U], no = [U], eo = [Se], to = [Se], Zr = [Se], Xr = [Se], Qr = [U], Yr = [U], Jr = [U], jr = [St((t) => [t.scrollContainer])], Kr = [St((t) => [t.scrollContainer])], Br = [St((t) => {
1760
1745
  var n;
1761
- return I(n = t, ss).call(n);
1762
- })], Vr = [kr((t) => !t.inert)], es) {
1746
+ return H(n = t, is).call(n);
1747
+ })], Ur = [ae((t) => !t.inert)], ns) {
1763
1748
  constructor() {
1764
- super(...arguments), Z(this, xt), z(this, "transition", P(w, 8, this)), P(w, 11, this), z(this, "routes", P(w, 12, this)), P(w, 15, this), z(this, "locationStore", P(w, 16, this)), P(w, 19, this), z(this, "key", P(w, 20, this)), P(w, 23, this), z(this, "loading", P(w, 24, this)), P(w, 27, this), z(this, "beforeroutechange", P(w, 28, this)), P(w, 31, this), z(this, "routechange", P(w, 32, this)), P(w, 35, this), z(this, "error", P(w, 36, this)), P(w, 39, this), z(this, "scrollContainer", P(w, 40, this)), P(w, 43, this), z(this, "scrollIgnoreHash", P(w, 44, this)), P(w, 47, this), z(this, "trigger", P(w, 48, this, O)), P(w, 51, this), z(this, "currentRoute"), z(this, "currentParams", {}), Z(this, $e, Ms({ content: Un })), Z(this, on, () => {
1749
+ super(...arguments), et(this, kt), G(this, "transition", P(w, 8, this)), P(w, 11, this), G(this, "routes", P(w, 12, this)), P(w, 15, this), G(this, "locationStore", P(w, 16, this)), P(w, 19, this), G(this, "key", P(w, 20, this)), P(w, 23, this), G(this, "loading", P(w, 24, this)), P(w, 27, this), G(this, "beforeroutechange", P(w, 28, this)), P(w, 31, this), G(this, "routechange", P(w, 32, this)), P(w, 35, this), G(this, "error", P(w, 36, this)), P(w, 39, this), G(this, "scrollContainer", P(w, 40, this)), P(w, 43, this), G(this, "scrollIgnoreHash", P(w, 44, this)), P(w, 47, this), G(this, "trigger", P(w, 48, this, M)), P(w, 51, this), G(this, "currentRoute"), G(this, "currentParams", {}), et(this, be, Ls({ content: Bn })), et(this, sn, () => {
1765
1750
  if (!this.locationStore) return;
1766
- const { path: t, query: n, hash: s, data: i } = O.getParams();
1767
- It(this.locationStore, {
1751
+ const { path: t, query: n, hash: s, data: i } = M.getParams();
1752
+ this.locationStore({
1768
1753
  path: t,
1769
1754
  params: this.currentParams,
1770
1755
  query: n,
1771
1756
  hash: s,
1772
1757
  data: i
1773
1758
  });
1774
- }), Z(this, ns, () => {
1775
- if (!I(this, xt, Vt)) return;
1776
- const t = zi.get(O.currentKey);
1777
- t ? I(this, xt, Vt).scroll(0, t) : (this.scrollIgnoreHash || !O.getParams().hash) && I(this, xt, Vt).scroll(0, 0);
1778
- }), Z(this, Ee), Z(this, an, (t, n, s) => {
1779
- this.beforeroutechange(t), pn(this, Ee, void 0), this.currentRoute = t, this.currentParams = n;
1759
+ }), et(this, ss, () => {
1760
+ if (!H(this, kt, qt)) return;
1761
+ const t = qi.get(M.currentKey);
1762
+ t ? H(this, kt, qt).scroll(0, t) : (this.scrollIgnoreHash || !M.getParams().hash) && H(this, kt, qt).scroll(0, 0);
1763
+ }), et(this, Ce), et(this, rn, (t, n, s) => {
1764
+ this.beforeroutechange(t), pn(this, Ce, void 0), this.currentRoute = t, this.currentParams = n;
1780
1765
  const i = async () => {
1781
- I(this, $e).call(this, { content: s }), I(this, on).call(this), await Promise.resolve(), I(this, ns).call(this), this.routechange(this.currentRoute);
1766
+ H(this, be).call(this, { content: s }), H(this, sn).call(this), await Promise.resolve(), H(this, ss).call(this), this.routechange(this.currentRoute);
1782
1767
  };
1783
1768
  this.transition && "startViewTransition" in document ? document.startViewTransition(() => i()) : i();
1784
- }), Z(this, Vs, P(w, 52, this, () => {
1785
- if (I(this, xt, Vt))
1786
- return mr(
1787
- O,
1769
+ }), et(this, Ds, P(w, 52, this, () => {
1770
+ if (H(this, kt, qt))
1771
+ return Er(
1772
+ M,
1788
1773
  "beforechange",
1789
- () => zi.set(O.currentKey, I(this, xt, Vt).scrollTop)
1774
+ () => qi.set(M.currentKey, H(this, kt, qt).scrollTop)
1790
1775
  );
1791
- })), P(w, 55, this), Z(this, Ds, P(w, 56, this, () => ft(this.trigger.store, () => I(this, $e).call(this, {})))), P(w, 59, this), Z(this, ss, () => {
1776
+ })), P(w, 55, this), et(this, Fs, P(w, 56, this, () => this.trigger.store && ft(this.trigger.store, () => H(this, be).call(this)))), P(w, 59, this), et(this, is, () => {
1792
1777
  const { path: t, query: n, hash: s } = this.trigger.getParams();
1793
1778
  return [this.key, t, n, s];
1794
- }), Z(this, Fs, P(w, 60, this, ([t, n], s) => {
1779
+ }), et(this, qs, P(w, 60, this, ([t, n], s) => {
1795
1780
  if (s && t === s[0] && n === s[1]) {
1796
- I(this, on).call(this);
1781
+ H(this, sn).call(this);
1797
1782
  return;
1798
1783
  }
1799
1784
  this.update();
1800
- })), P(w, 63, this), Z(this, qs, P(w, 64, this, () => {
1801
- const { content: t } = I(this, $e);
1785
+ })), P(w, 63, this), et(this, Us, P(w, 64, this, () => {
1786
+ const { content: t } = H(this, be);
1802
1787
  if (t !== void 0)
1803
- return this.shadowRoot ? at`
1788
+ return this.shadowRoot ? ht`
1804
1789
  <style>
1805
1790
  :host(:where(:not([hidden]))),
1806
1791
  :not(:defined) {
1807
1792
  display: contents;
1808
1793
  }
1809
1794
  </style>
1810
- ${t === Un ? at`<slot></slot>` : t}
1811
- ` : t === Un ? void 0 : at`${t}`;
1812
- })), P(w, 67, this), z(this, "update", () => {
1813
- const { path: t, hash: n, query: s } = this.trigger.getParams(), { route: i, params: o = {} } = Ue.findRoute(this.routes, t), { redirect: c, content: a, getContent: f } = i || {};
1795
+ ${t === Bn ? ht`<slot></slot>` : t}
1796
+ ` : t === Bn ? void 0 : ht`${t}`;
1797
+ })), P(w, 67, this), G(this, "update", () => {
1798
+ const { path: t, hash: n, query: s } = this.trigger.getParams(), { route: i, params: r = {} } = Ue.findRoute(this.routes, t), { redirect: c, content: a, getContent: d } = i || {};
1814
1799
  if (c) {
1815
1800
  this.trigger.replace({
1816
- path: Bs({ pattern: c }, { params: o }),
1801
+ path: Ks({ pattern: c }, { params: r }),
1817
1802
  query: s,
1818
1803
  hash: n
1819
1804
  });
1820
1805
  return;
1821
1806
  }
1822
- this.trigger === O && (location.href !== At.url || i != null && i.title) && It(At, { url: location.href, title: i == null ? void 0 : i.title });
1823
- const h = a || (f == null ? void 0 : f(o, this.shadowRoot || this));
1824
- if (this.loading(i), h instanceof Promise) {
1825
- pn(this, Ee, h);
1826
- const m = () => I(this, Ee) === h;
1827
- h.then((r) => {
1828
- m() && I(this, an).call(this, i, o, r);
1829
- }).catch((r) => {
1830
- m() && this.error(r);
1807
+ this.trigger === M && (location.href !== Rt.url || i != null && i.title) && Rt({ url: location.href, title: i == null ? void 0 : i.title });
1808
+ const f = a || (d == null ? void 0 : d(r, this.shadowRoot || this));
1809
+ if (this.loading(i), f instanceof Promise) {
1810
+ pn(this, Ce, f);
1811
+ const g = () => H(this, Ce) === f;
1812
+ f.then((o) => {
1813
+ g() && H(this, rn).call(this, i, r, o);
1814
+ }).catch((o) => {
1815
+ g() && this.error(o);
1831
1816
  });
1832
1817
  return;
1833
1818
  }
1834
- I(this, an).call(this, i, o, h);
1819
+ H(this, rn).call(this, i, r, f);
1835
1820
  });
1836
1821
  }
1837
1822
  }
1838
- w = zr(es);
1839
- xt = /* @__PURE__ */ new WeakSet();
1840
- Vt = function() {
1823
+ w = Fr(ns);
1824
+ kt = /* @__PURE__ */ new WeakSet();
1825
+ qt = function() {
1841
1826
  return typeof this.scrollContainer == "function" ? this.scrollContainer() : this.scrollContainer;
1842
1827
  };
1843
- $e = /* @__PURE__ */ new WeakMap();
1844
- on = /* @__PURE__ */ new WeakMap();
1845
- ns = /* @__PURE__ */ new WeakMap();
1846
- Ee = /* @__PURE__ */ new WeakMap();
1847
- an = /* @__PURE__ */ new WeakMap();
1848
- Vs = /* @__PURE__ */ new WeakMap();
1849
- Ds = /* @__PURE__ */ new WeakMap();
1828
+ be = /* @__PURE__ */ new WeakMap();
1829
+ sn = /* @__PURE__ */ new WeakMap();
1850
1830
  ss = /* @__PURE__ */ new WeakMap();
1831
+ Ce = /* @__PURE__ */ new WeakMap();
1832
+ rn = /* @__PURE__ */ new WeakMap();
1833
+ Ds = /* @__PURE__ */ new WeakMap();
1851
1834
  Fs = /* @__PURE__ */ new WeakMap();
1835
+ is = /* @__PURE__ */ new WeakMap();
1852
1836
  qs = /* @__PURE__ */ new WeakMap();
1853
- W(w, 5, "transition", eo, N);
1854
- W(w, 5, "routes", to, N);
1855
- W(w, 5, "locationStore", Zr, N);
1856
- W(w, 5, "key", Xr, N);
1857
- W(w, 5, "loading", Qr, N);
1858
- W(w, 5, "beforeroutechange", Yr, N);
1859
- W(w, 5, "routechange", Jr, N);
1860
- W(w, 5, "error", jr, N);
1861
- W(w, 5, "scrollContainer", Kr, N);
1862
- W(w, 5, "scrollIgnoreHash", Br, N);
1863
- W(w, 5, "trigger", Ur, N);
1864
- W(w, 21, "#rememberScrollPosition", qr, Vs);
1865
- W(w, 21, "#connectTriggerStore", Fr, Ds);
1866
- W(w, 21, "#updateContent", Dr, Fs);
1867
- W(w, 21, "#content", Vr, qs);
1868
- N = W(w, 0, "GemLightRouteElement", no, N);
1869
- z(N, "createLocationStore", () => {
1870
- const { path: e, query: t, hash: n, data: s } = O.getParams();
1871
- return bn({ path: e, query: t, hash: n, data: s, params: {} });
1837
+ Us = /* @__PURE__ */ new WeakMap();
1838
+ z(w, 5, "transition", ro, R);
1839
+ z(w, 5, "routes", io, R);
1840
+ z(w, 5, "locationStore", so, R);
1841
+ z(w, 5, "key", no, R);
1842
+ z(w, 5, "loading", eo, R);
1843
+ z(w, 5, "beforeroutechange", to, R);
1844
+ z(w, 5, "routechange", Zr, R);
1845
+ z(w, 5, "error", Xr, R);
1846
+ z(w, 5, "scrollContainer", Qr, R);
1847
+ z(w, 5, "scrollIgnoreHash", Yr, R);
1848
+ z(w, 5, "trigger", Jr, R);
1849
+ z(w, 21, "#rememberScrollPosition", jr, Ds);
1850
+ z(w, 21, "#connectTriggerStore", Kr, Fs);
1851
+ z(w, 21, "#updateContent", Br, qs);
1852
+ z(w, 21, "#content", Ur, Us);
1853
+ R = z(w, 0, "GemLightRouteElement", oo, R);
1854
+ G(R, "createLocationStore", () => {
1855
+ const { path: e, query: t, hash: n, data: s } = M.getParams();
1856
+ return Wt({ path: e, query: t, hash: n, data: s, params: {} });
1872
1857
  });
1873
- z(N, "findRoute", (e = [], t) => {
1858
+ G(R, "findRoute", (e = [], t) => {
1874
1859
  let n = null, s;
1875
1860
  e instanceof Array ? s = e : s = Object.values(e);
1876
1861
  for (const i of s)
1877
1862
  if (i.pattern === "*")
1878
1863
  n = i;
1879
1864
  else {
1880
- const o = oo(i.pattern, t);
1881
- if (o)
1882
- return { route: i, params: o };
1865
+ const r = lo(i.pattern, t);
1866
+ if (r)
1867
+ return { route: i, params: r };
1883
1868
  }
1884
1869
  return { route: n };
1885
1870
  });
1886
- P(w, 1, N);
1887
- so = [Ht()];
1888
- class Ue extends (io = N) {
1889
- }
1890
- Us = zr(io);
1891
- Ue = W(Us, 0, "GemRouteElement", so, Ue);
1892
- P(Us, 1, Ue);
1893
- var Tc = Object.create, Ks = Object.defineProperty, Oc = Object.getOwnPropertyDescriptor, ao = (e, t) => (t = Symbol[e]) ? t : Symbol.for("Symbol." + e), ce = (e) => {
1871
+ P(w, 1, R);
1872
+ ao = [zt()];
1873
+ class Ue extends (co = R) {
1874
+ }
1875
+ Bs = Fr(co);
1876
+ Ue = z(Bs, 0, "GemRouteElement", ao, Ue);
1877
+ P(Bs, 1, Ue);
1878
+ var Wc = Object.create, js = Object.defineProperty, zc = Object.getOwnPropertyDescriptor, uo = (e, t) => (t = Symbol[e]) ? t : Symbol.for("Symbol." + e), he = (e) => {
1894
1879
  throw TypeError(e);
1895
- }, co = (e, t, n) => t in e ? Ks(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n, Gi = (e, t) => Ks(e, "name", { value: t, configurable: !0 }), lo = (e) => [, , , Tc((e == null ? void 0 : e[ao("metadata")]) ?? null)], ho = ["class", "method", "getter", "setter", "accessor", "field", "value", "get", "set"], be = (e) => e !== void 0 && typeof e != "function" ? ce("Function expected") : e, Mc = (e, t, n, s, i) => ({ kind: ho[e], name: t, metadata: s, addInitializer: (o) => n._ ? ce("Already initialized") : i.push(be(o || null)) }), Lc = (e, t) => co(t, ao("metadata"), e[3]), C = (e, t, n, s) => {
1896
- for (var i = 0, o = e[t >> 1], c = o && o.length; i < c; i++) t & 1 ? o[i].call(n) : s = o[i].call(n, s);
1880
+ }, po = (e, t, n) => t in e ? js(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n, Ui = (e, t) => js(e, "name", { value: t, configurable: !0 }), fo = (e) => [, , , Wc((e == null ? void 0 : e[uo("metadata")]) ?? null)], _o = ["class", "method", "getter", "setter", "accessor", "field", "value", "get", "set"], Pe = (e) => e !== void 0 && typeof e != "function" ? he("Function expected") : e, Gc = (e, t, n, s, i) => ({ kind: _o[e], name: t, metadata: s, addInitializer: (r) => n._ ? he("Already initialized") : i.push(Pe(r || null)) }), Vc = (e, t) => po(t, uo("metadata"), e[3]), C = (e, t, n, s) => {
1881
+ for (var i = 0, r = e[t >> 1], c = r && r.length; i < c; i++) t & 1 ? r[i].call(n) : s = r[i].call(n, s);
1897
1882
  return s;
1898
- }, A = (e, t, n, s, i, o) => {
1899
- var c, a, f, h, m, r = t & 7, _ = !!(t & 8), l = !!(t & 16), g = r > 3 ? e.length + 1 : r ? _ ? 1 : 2 : 0, v = ho[r + 5], y = r > 3 && (e[g - 1] = []), $ = e[g] || (e[g] = []), d = r && (!l && !_ && (i = i.prototype), r < 5 && (r > 3 || !l) && Oc(r < 4 ? i : { get [n]() {
1900
- return nt(this, o);
1901
- }, set [n](u) {
1902
- return Vi(this, o, u);
1883
+ }, A = (e, t, n, s, i, r) => {
1884
+ var c, a, d, f, g, o = t & 7, _ = !!(t & 8), h = !!(t & 16), m = o > 3 ? e.length + 1 : o ? _ ? 1 : 2 : 0, v = _o[o + 5], y = o > 3 && (e[m - 1] = []), E = e[m] || (e[m] = []), u = o && (!h && !_ && (i = i.prototype), o < 5 && (o > 3 || !h) && zc(o < 4 ? i : { get [n]() {
1885
+ return it(this, r);
1886
+ }, set [n](l) {
1887
+ return Bi(this, r, l);
1903
1888
  } }, n));
1904
- r ? l && r < 4 && Gi(o, (r > 2 ? "set " : r > 1 ? "get " : "") + n) : Gi(i, n);
1889
+ o ? h && o < 4 && Ui(r, (o > 2 ? "set " : o > 1 ? "get " : "") + n) : Ui(i, n);
1905
1890
  for (var S = s.length - 1; S >= 0; S--)
1906
- h = Mc(r, n, f = {}, e[3], $), r && (h.static = _, h.private = l, m = h.access = { has: l ? (u) => Nc(i, u) : (u) => n in u }, r ^ 3 && (m.get = l ? (u) => (r ^ 1 ? nt : Ac)(u, i, r ^ 4 ? o : d.get) : (u) => u[n]), r > 2 && (m.set = l ? (u, k) => Vi(u, i, k, r ^ 4 ? o : d.set) : (u, k) => u[n] = k)), a = (0, s[S])(r ? r < 4 ? l ? o : d[v] : r > 4 ? void 0 : { get: d.get, set: d.set } : i, h), f._ = 1, r ^ 4 || a === void 0 ? be(a) && (r > 4 ? y.unshift(a) : r ? l ? o = a : d[v] = a : i = a) : typeof a != "object" || a === null ? ce("Object expected") : (be(c = a.get) && (d.get = c), be(c = a.set) && (d.set = c), be(c = a.init) && y.unshift(c));
1907
- return r || Lc(e, i), d && Ks(i, n, d), l ? r ^ 4 ? o : d : i;
1908
- }, D = (e, t, n) => co(e, typeof t != "symbol" ? t + "" : t, n), js = (e, t, n) => t.has(e) || ce("Cannot " + n), Nc = (e, t) => Object(t) !== t ? ce('Cannot use the "in" operator on this value') : e.has(t), nt = (e, t, n) => (js(e, t, "read from private field"), n ? n.call(e) : t.get(e)), Dt = (e, t, n) => t.has(e) ? ce("Cannot add the same private member more than once") : t instanceof WeakSet ? t.add(e) : t.set(e, n), Vi = (e, t, n, s) => (js(e, t, "write to private field"), s ? s.call(e, n) : t.set(e, n), n), Ac = (e, t, n) => (js(e, t, "access private method"), n), uo, po, fo, _o, go, mo, vo, wo, yo, So, $o, Eo, bo, is, Co, E, gt, Ce, Po, Js, rs, os, Ys, as, ko, xo, To, cs, Oo, Q, Qs;
1909
- function Di(e) {
1891
+ f = Gc(o, n, d = {}, e[3], E), o && (f.static = _, f.private = h, g = f.access = { has: h ? (l) => Dc(i, l) : (l) => n in l }, o ^ 3 && (g.get = h ? (l) => (o ^ 1 ? it : Fc)(l, i, o ^ 4 ? r : u.get) : (l) => l[n]), o > 2 && (g.set = h ? (l, k) => Bi(l, i, k, o ^ 4 ? r : u.set) : (l, k) => l[n] = k)), a = (0, s[S])(o ? o < 4 ? h ? r : u[v] : o > 4 ? void 0 : { get: u.get, set: u.set } : i, f), d._ = 1, o ^ 4 || a === void 0 ? Pe(a) && (o > 4 ? y.unshift(a) : o ? h ? r = a : u[v] = a : i = a) : typeof a != "object" || a === null ? he("Object expected") : (Pe(c = a.get) && (u.get = c), Pe(c = a.set) && (u.set = c), Pe(c = a.init) && y.unshift(c));
1892
+ return o || Vc(e, i), u && js(i, n, u), h ? o ^ 4 ? r : u : i;
1893
+ }, D = (e, t, n) => po(e, typeof t != "symbol" ? t + "" : t, n), Js = (e, t, n) => t.has(e) || he("Cannot " + n), Dc = (e, t) => Object(t) !== t ? he('Cannot use the "in" operator on this value') : e.has(t), it = (e, t, n) => (Js(e, t, "read from private field"), n ? n.call(e) : t.get(e)), xt = (e, t, n) => t.has(e) ? he("Cannot add the same private member more than once") : t instanceof WeakSet ? t.add(e) : t.set(e, n), Bi = (e, t, n, s) => (Js(e, t, "write to private field"), s ? s.call(e, n) : t.set(e, n), n), Fc = (e, t, n) => (Js(e, t, "access private method"), n), go, mo, vo, wo, yo, So, $o, Eo, bo, Co, Po, ko, xo, To, rs, Oo, $, gt, ke, Mo, Ys, os, as, Qs, cs, Xs, Lo, No, Ao, hs, Io, X, Zs;
1894
+ function Ki(e) {
1910
1895
  return !e.startsWith("/");
1911
1896
  }
1912
- const Ic = Pn(vr`
1897
+ const qc = Pn(br`
1913
1898
  :host {
1914
1899
  /* link default style */
1915
1900
  cursor: pointer;
@@ -1924,14 +1909,14 @@ const Ic = Pn(vr`
1924
1909
  color: unset;
1925
1910
  }
1926
1911
  `);
1927
- Co = [Mn(wc), Rs(Ic), Ht(), Ln({ focusable: !0 })];
1928
- class H extends (is = B, bo = [V], Eo = [V], $o = [V], So = [V], yo = [V], wo = [V], vo = [Tn], mo = [U], go = [U], _o = [U], fo = [U], po = [Tr], uo = [qe()], is) {
1912
+ Oo = [Mn(xc), Hs(qc), zt(), Ln({ focusable: !0 })];
1913
+ class W extends (rs = B, To = [V], xo = [V], ko = [V], Po = [V], Co = [V], bo = [V], Eo = [Tn], $o = [U], So = [U], yo = [U], wo = [U], vo = [Ar], mo = [qe()], go = [ae()], rs) {
1929
1914
  constructor() {
1930
- super(...arguments), C(E, 5, this), Dt(this, gt), D(this, "href", C(E, 8, this)), C(E, 11, this), D(this, "target", C(E, 12, this)), C(E, 15, this), D(this, "path", C(E, 16, this)), C(E, 19, this), D(this, "query", C(E, 20, this)), C(E, 23, this), D(this, "hash", C(E, 24, this)), C(E, 27, this), D(this, "hint", C(E, 28, this)), C(E, 31, this), D(this, "preload", C(E, 32, this)), C(E, 35, this), D(this, "route", C(E, 36, this)), C(E, 39, this), D(this, "options", C(E, 40, this)), C(E, 43, this), D(this, "routeOptions", C(E, 44, this)), C(E, 47, this), D(this, "prepare", C(E, 48, this)), C(E, 51, this), D(this, "link", C(E, 52, this)), C(E, 55, this), Dt(this, Js, async () => {
1931
- var o;
1932
- const t = this.getLocationString();
1915
+ super(...arguments), C($, 5, this), xt(this, gt), D(this, "href", C($, 8, this)), C($, 11, this), D(this, "target", C($, 12, this)), C($, 15, this), D(this, "path", C($, 16, this)), C($, 19, this), D(this, "query", C($, 20, this)), C($, 23, this), D(this, "hash", C($, 24, this)), C($, 27, this), D(this, "hint", C($, 28, this)), C($, 31, this), D(this, "preload", C($, 32, this)), C($, 35, this), D(this, "route", C($, 36, this)), C($, 39, this), D(this, "options", C($, 40, this)), C($, 43, this), D(this, "routeOptions", C($, 44, this)), C($, 47, this), D(this, "prepare", C($, 48, this)), C($, 51, this), D(this, "link", C($, 52, this)), C($, 55, this), xt(this, Ys, async () => {
1916
+ var r;
1917
+ const t = this._getLocationString();
1933
1918
  if (!t) return;
1934
- if (Di(t))
1919
+ if (Ki(t))
1935
1920
  switch (this.target) {
1936
1921
  case "_self":
1937
1922
  window.location.href = t;
@@ -1946,178 +1931,177 @@ class H extends (is = B, bo = [V], Eo = [V], $o = [V], So = [V], yo = [V], wo =
1946
1931
  window.open(t);
1947
1932
  return;
1948
1933
  }
1949
- const { path: n, query: s, hash: i } = O.getParams();
1934
+ const { path: n, query: s, hash: i } = M.getParams();
1950
1935
  if (n + s + i !== t)
1951
- if (await ((o = this.prepare) == null ? void 0 : o.call(this)), this.route)
1952
- O.pushIgnoreCloseHandle(xc(this.route, nt(this, gt, Ce)));
1936
+ if (await ((r = this.prepare) == null ? void 0 : r.call(this)), this.route)
1937
+ M.pushIgnoreCloseHandle(Hc(this.route, it(this, gt, ke)));
1953
1938
  else if (this.href) {
1954
1939
  const c = new URL(t, location.origin);
1955
- O.pushIgnoreCloseHandle({
1940
+ M.pushIgnoreCloseHandle({
1956
1941
  path: c.pathname,
1957
1942
  query: c.search,
1958
1943
  hash: c.hash
1959
1944
  });
1960
1945
  } else
1961
- O.pushIgnoreCloseHandle({
1946
+ M.pushIgnoreCloseHandle({
1962
1947
  path: this.path,
1963
1948
  query: this.query,
1964
1949
  hash: this.hash
1965
1950
  });
1966
- }), Dt(this, rs, (t) => {
1967
- t.preventDefault();
1968
- }), Dt(this, os, () => {
1969
- const t = this.getLocationString();
1970
- return Di(t) ? t : new URL(O.basePath + t, location.origin).toString();
1971
- }), Dt(this, Ys, () => {
1951
+ }), xt(this, os, (t) => t.preventDefault()), xt(this, as, () => {
1952
+ const t = this._getLocationString();
1953
+ return Ki(t) ? t : new URL(M.basePath + t, location.origin).toString();
1954
+ }), xt(this, Qs, () => {
1972
1955
  var t, n, s;
1973
1956
  (t = this.route) == null || t.content, (s = (n = this.route) == null ? void 0 : n.getContent) == null || s.call(n, {}, this.shadowRoot);
1974
- });
1975
- }
1976
- render() {
1977
- return at`
1957
+ }), xt(this, Xs, C($, 56, this, () => ht`
1978
1958
  <a
1979
1959
  part=${this.link}
1980
- @click=${nt(this, rs)}
1981
- href=${yc(nt(this, gt, Po) === "off" ? void 0 : nt(this, os).call(this))}
1960
+ @click=${it(this, os)}
1961
+ href=${Tc(it(this, gt, Mo) === "off" ? void 0 : it(this, as).call(this))}
1982
1962
  tabindex="-1"
1983
1963
  >
1984
1964
  <slot></slot>
1985
1965
  </a>
1986
- `;
1966
+ `)), C($, 59, this);
1987
1967
  }
1988
1968
  /**
1989
1969
  * 如果该元素是外部链接返回 URL,否则返回路径(不包含 basePath)
1990
1970
  */
1991
- getLocationString() {
1971
+ _getLocationString() {
1992
1972
  var t, n;
1993
1973
  if (this.route) {
1994
- const s = ((t = nt(this, gt, Ce)) == null ? void 0 : t.query) || "", i = ((n = nt(this, gt, Ce)) == null ? void 0 : n.hash) || "";
1995
- return Bs(this.route, nt(this, gt, Ce)) + s + i;
1974
+ const s = ((t = it(this, gt, ke)) == null ? void 0 : t.query) || "", i = ((n = it(this, gt, ke)) == null ? void 0 : n.hash) || "";
1975
+ return Ks(this.route, it(this, gt, ke)) + s + i;
1996
1976
  } else {
1997
- const s = this.href || this.path + this.query + this.hash, { path: i, query: o } = O.getParams();
1998
- return s.startsWith("#") ? `${i}${o}${s}` : s.startsWith("?") ? `${i}${s}` : s.startsWith(".") ? gr(i, s) : s;
1977
+ const s = this.href || this.path + this.query + this.hash, { path: i, query: r } = M.getParams();
1978
+ return s.startsWith("#") ? `${i}${r}${s}` : s.startsWith("?") ? `${i}${s}` : s.startsWith(".") ? $r(i, s) : s;
1999
1979
  }
2000
1980
  }
2001
1981
  }
2002
- E = lo(is);
1982
+ $ = fo(rs);
2003
1983
  gt = /* @__PURE__ */ new WeakSet();
2004
- Ce = function() {
1984
+ ke = function() {
2005
1985
  return this.routeOptions || this.options;
2006
1986
  };
2007
- Po = function() {
1987
+ Mo = function() {
2008
1988
  return this.hint || "on";
2009
1989
  };
2010
- Js = /* @__PURE__ */ new WeakMap();
2011
- rs = /* @__PURE__ */ new WeakMap();
2012
- os = /* @__PURE__ */ new WeakMap();
2013
1990
  Ys = /* @__PURE__ */ new WeakMap();
2014
- as = function() {
2015
- this.addEventListener("click", nt(this, Js)), this.addEventListener("pointerenter", nt(this, Ys));
1991
+ os = /* @__PURE__ */ new WeakMap();
1992
+ as = /* @__PURE__ */ new WeakMap();
1993
+ Qs = /* @__PURE__ */ new WeakMap();
1994
+ cs = function() {
1995
+ this.addEventListener("click", it(this, Ys)), this.addEventListener("pointerenter", it(this, Qs));
2016
1996
  };
2017
- as = A(E, 17, "#init", uo, gt, as);
2018
- A(E, 5, "href", bo, H);
2019
- A(E, 5, "target", Eo, H);
2020
- A(E, 5, "path", $o, H);
2021
- A(E, 5, "query", So, H);
2022
- A(E, 5, "hash", yo, H);
2023
- A(E, 5, "hint", wo, H);
2024
- A(E, 5, "preload", vo, H);
2025
- A(E, 5, "route", mo, H);
2026
- A(E, 5, "options", go, H);
2027
- A(E, 5, "routeOptions", _o, H);
2028
- A(E, 5, "prepare", fo, H);
2029
- A(E, 5, "link", po, H);
2030
- H = A(E, 0, "GemLinkElement", Co, H);
2031
- C(E, 1, H);
2032
- Oo = [Mn(O.store)];
2033
- class se extends (cs = H, To = [V], xo = [On], ko = [$t()], cs) {
1997
+ Xs = /* @__PURE__ */ new WeakMap();
1998
+ cs = A($, 17, "#init", mo, gt, cs);
1999
+ A($, 5, "href", To, W);
2000
+ A($, 5, "target", xo, W);
2001
+ A($, 5, "path", ko, W);
2002
+ A($, 5, "query", Po, W);
2003
+ A($, 5, "hash", Co, W);
2004
+ A($, 5, "hint", bo, W);
2005
+ A($, 5, "preload", Eo, W);
2006
+ A($, 5, "route", $o, W);
2007
+ A($, 5, "options", So, W);
2008
+ A($, 5, "routeOptions", yo, W);
2009
+ A($, 5, "prepare", wo, W);
2010
+ A($, 5, "link", vo, W);
2011
+ A($, 21, "#content", go, Xs);
2012
+ W = A($, 0, "GemLinkElement", Oo, W);
2013
+ C($, 1, W);
2014
+ Io = [Mn(M.store)];
2015
+ class se extends (hs = W, Ao = [V], No = [On], Lo = [St()], hs) {
2034
2016
  constructor() {
2035
- super(...arguments), D(this, "pattern", C(Q, 8, this)), C(Q, 11, this), D(this, "active", C(Q, 12, this)), C(Q, 15, this), Dt(this, Qs, C(Q, 16, this, () => {
2036
- const { path: t, query: n, hash: s } = O.getParams(), i = this.pattern && oo(this.pattern, t);
2037
- this.active = !!i || t + n + s === this.getLocationString();
2038
- })), C(Q, 19, this);
2039
- }
2040
- }
2041
- Q = lo(cs);
2042
- Qs = /* @__PURE__ */ new WeakMap();
2043
- A(Q, 5, "pattern", To, se);
2044
- A(Q, 5, "active", xo, se);
2045
- A(Q, 21, "#updateState", ko, Qs);
2046
- se = A(Q, 0, "GemActiveLinkElement", Oo, se);
2047
- C(Q, 1, se);
2048
- customElements.define("gem-link", H);
2017
+ super(...arguments), D(this, "pattern", C(X, 8, this)), C(X, 11, this), D(this, "active", C(X, 12, this)), C(X, 15, this), xt(this, Zs, C(X, 16, this, () => {
2018
+ const { path: t, query: n, hash: s } = M.getParams(), i = this.pattern && lo(this.pattern, t);
2019
+ this.active = !!i || t + n + s === this._getLocationString();
2020
+ })), C(X, 19, this);
2021
+ }
2022
+ }
2023
+ X = fo(hs);
2024
+ Zs = /* @__PURE__ */ new WeakMap();
2025
+ A(X, 5, "pattern", Ao, se);
2026
+ A(X, 5, "active", No, se);
2027
+ A(X, 21, "#updateState", Lo, Zs);
2028
+ se = A(X, 0, "GemActiveLinkElement", Io, se);
2029
+ C(X, 1, se);
2030
+ customElements.define("gem-link", W);
2049
2031
  customElements.define("gem-active-link", se);
2050
2032
  customElements.define("gem-route", Ue);
2051
- customElements.define("gem-light-route", N);
2052
- var Rc = Object.create, Xs = Object.defineProperty, Hc = Object.getOwnPropertyDescriptor, Mo = (e, t) => (t = Symbol[e]) ? t : Symbol.for("Symbol." + e), le = (e) => {
2033
+ customElements.define("gem-light-route", R);
2034
+ var Uc = Object.create, ti = Object.defineProperty, Bc = Object.getOwnPropertyDescriptor, Ro = (e, t) => (t = Symbol[e]) ? t : Symbol.for("Symbol." + e), le = (e) => {
2053
2035
  throw TypeError(e);
2054
- }, Lo = (e, t, n) => t in e ? Xs(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n, Fi = (e, t) => Xs(e, "name", { value: t, configurable: !0 }), Wc = (e) => [, , , Rc((e == null ? void 0 : e[Mo("metadata")]) ?? null)], No = ["class", "method", "getter", "setter", "accessor", "field", "value", "get", "set"], Pe = (e) => e !== void 0 && typeof e != "function" ? le("Function expected") : e, zc = (e, t, n, s, i) => ({ kind: No[e], name: t, metadata: s, addInitializer: (o) => n._ ? le("Already initialized") : i.push(Pe(o || null)) }), Gc = (e, t) => Lo(t, Mo("metadata"), e[3]), tt = (e, t, n, s) => {
2055
- for (var i = 0, o = e[t >> 1], c = o && o.length; i < c; i++) t & 1 ? o[i].call(n) : s = o[i].call(n, s);
2036
+ }, Ho = (e, t, n) => t in e ? ti(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n, ji = (e, t) => ti(e, "name", { value: t, configurable: !0 }), Kc = (e) => [, , , Uc((e == null ? void 0 : e[Ro("metadata")]) ?? null)], Wo = ["class", "method", "getter", "setter", "accessor", "field", "value", "get", "set"], xe = (e) => e !== void 0 && typeof e != "function" ? le("Function expected") : e, jc = (e, t, n, s, i) => ({ kind: Wo[e], name: t, metadata: s, addInitializer: (r) => n._ ? le("Already initialized") : i.push(xe(r || null)) }), Jc = (e, t) => Ho(t, Ro("metadata"), e[3]), j = (e, t, n, s) => {
2037
+ for (var i = 0, r = e[t >> 1], c = r && r.length; i < c; i++) t & 1 ? r[i].call(n) : s = r[i].call(n, s);
2056
2038
  return s;
2057
- }, he = (e, t, n, s, i, o) => {
2058
- var c, a, f, h, m, r = t & 7, _ = !!(t & 8), l = !!(t & 16), g = r > 3 ? e.length + 1 : r ? _ ? 1 : 2 : 0, v = No[r + 5], y = r > 3 && (e[g - 1] = []), $ = e[g] || (e[g] = []), d = r && (!l && !_ && (i = i.prototype), r < 5 && (r > 3 || !l) && Hc(r < 4 ? i : { get [n]() {
2059
- return ls(this, o);
2060
- }, set [n](u) {
2061
- return qi(this, o, u);
2039
+ }, Gt = (e, t, n, s, i, r) => {
2040
+ var c, a, d, f, g, o = t & 7, _ = !!(t & 8), h = !!(t & 16), m = o > 3 ? e.length + 1 : o ? _ ? 1 : 2 : 0, v = Wo[o + 5], y = o > 3 && (e[m - 1] = []), E = e[m] || (e[m] = []), u = o && (!h && !_ && (i = i.prototype), o < 5 && (o > 3 || !h) && Bc(o < 4 ? i : { get [n]() {
2041
+ return ls(this, r);
2042
+ }, set [n](l) {
2043
+ return Ji(this, r, l);
2062
2044
  } }, n));
2063
- r ? l && r < 4 && Fi(o, (r > 2 ? "set " : r > 1 ? "get " : "") + n) : Fi(i, n);
2045
+ o ? h && o < 4 && ji(r, (o > 2 ? "set " : o > 1 ? "get " : "") + n) : ji(i, n);
2064
2046
  for (var S = s.length - 1; S >= 0; S--)
2065
- h = zc(r, n, f = {}, e[3], $), r && (h.static = _, h.private = l, m = h.access = { has: l ? (u) => Vc(i, u) : (u) => n in u }, r ^ 3 && (m.get = l ? (u) => (r ^ 1 ? ls : Dc)(u, i, r ^ 4 ? o : d.get) : (u) => u[n]), r > 2 && (m.set = l ? (u, k) => qi(u, i, k, r ^ 4 ? o : d.set) : (u, k) => u[n] = k)), a = (0, s[S])(r ? r < 4 ? l ? o : d[v] : r > 4 ? void 0 : { get: d.get, set: d.set } : i, h), f._ = 1, r ^ 4 || a === void 0 ? Pe(a) && (r > 4 ? y.unshift(a) : r ? l ? o = a : d[v] = a : i = a) : typeof a != "object" || a === null ? le("Object expected") : (Pe(c = a.get) && (d.get = c), Pe(c = a.set) && (d.set = c), Pe(c = a.init) && y.unshift(c));
2066
- return r || Gc(e, i), d && Xs(i, n, d), l ? r ^ 4 ? o : d : i;
2067
- }, ke = (e, t, n) => Lo(e, typeof t != "symbol" ? t + "" : t, n), Zs = (e, t, n) => t.has(e) || le("Cannot " + n), Vc = (e, t) => Object(t) !== t ? le('Cannot use the "in" operator on this value') : e.has(t), ls = (e, t, n) => (Zs(e, t, "read from private field"), n ? n.call(e) : t.get(e)), Bn = (e, t, n) => t.has(e) ? le("Cannot add the same private member more than once") : t instanceof WeakSet ? t.add(e) : t.set(e, n), qi = (e, t, n, s) => (Zs(e, t, "write to private field"), s ? s.call(e, n) : t.set(e, n), n), Dc = (e, t, n) => (Zs(e, t, "access private method"), n), Ao, Io, Ro, Ho, Wo, hs, zo, L, ti, us, ei;
2068
- let Ui = 0;
2069
- const Bi = (e) => {
2070
- clearTimeout(Ui), Ui = window.setTimeout(() => document.title = e);
2047
+ f = jc(o, n, d = {}, e[3], E), o && (f.static = _, f.private = h, g = f.access = { has: h ? (l) => Yc(i, l) : (l) => n in l }, o ^ 3 && (g.get = h ? (l) => (o ^ 1 ? ls : Qc)(l, i, o ^ 4 ? r : u.get) : (l) => l[n]), o > 2 && (g.set = h ? (l, k) => Ji(l, i, k, o ^ 4 ? r : u.set) : (l, k) => l[n] = k)), a = (0, s[S])(o ? o < 4 ? h ? r : u[v] : o > 4 ? void 0 : { get: u.get, set: u.set } : i, f), d._ = 1, o ^ 4 || a === void 0 ? xe(a) && (o > 4 ? y.unshift(a) : o ? h ? r = a : u[v] = a : i = a) : typeof a != "object" || a === null ? le("Object expected") : (xe(c = a.get) && (u.get = c), xe(c = a.set) && (u.set = c), xe(c = a.init) && y.unshift(c));
2048
+ return o || Jc(e, i), u && ti(i, n, u), h ? o ^ 4 ? r : u : i;
2049
+ }, on = (e, t, n) => Ho(e, typeof t != "symbol" ? t + "" : t, n), ei = (e, t, n) => t.has(e) || le("Cannot " + n), Yc = (e, t) => Object(t) !== t ? le('Cannot use the "in" operator on this value') : e.has(t), ls = (e, t, n) => (ei(e, t, "read from private field"), n ? n.call(e) : t.get(e)), Ze = (e, t, n) => t.has(e) ? le("Cannot add the same private member more than once") : t instanceof WeakSet ? t.add(e) : t.set(e, n), Ji = (e, t, n, s) => (ei(e, t, "write to private field"), s ? s.call(e, n) : t.set(e, n), n), Qc = (e, t, n) => (ei(e, t, "access private method"), n), zo, Go, Vo, Do, Fo, qo, us, Uo, L, ni, ds, si, ii;
2050
+ let Yi = 0;
2051
+ const Qi = (e) => {
2052
+ clearTimeout(Yi), Yi = window.setTimeout(() => document.title = e);
2071
2053
  };
2072
- function Fc(e, t = "", n = "") {
2073
- const s = At.title || e;
2074
- s && s !== At.defaultTitle ? (xe.title = s, Bi(t + xe.title + n)) : (xe.title = At.defaultTitle, Bi(xe.title));
2054
+ function Xc(e, t = "", n = "") {
2055
+ const s = Rt.title || e;
2056
+ s && s !== Rt.defaultTitle ? (Te.title = s, Qi(t + Te.title + n)) : (Te.title = Rt.defaultTitle, Qi(Te.title));
2075
2057
  }
2076
- zo = [Ht()];
2077
- let bt = class Go extends (hs = B, Wo = [V], Ho = [V], Ro = [Tn], Io = [$t((t) => [t.inert])], Ao = [qe()], hs) {
2058
+ Uo = [zt()];
2059
+ let Et = class Bo extends (us = B, qo = [V], Fo = [V], Do = [Tn], Vo = [St((t) => [t.inert])], Go = [qe()], zo = [ae()], us) {
2078
2060
  constructor() {
2079
- super(...arguments), ke(this, "prefix", tt(L, 8, this)), tt(L, 11, this), ke(this, "suffix", tt(L, 12, this)), tt(L, 15, this), ke(this, "inert", tt(L, 16, this)), tt(L, 19, this), Bn(this, ti, tt(L, 20, this, () => !this.inert && ft(At, this.update))), tt(L, 23, this), Bn(this, us, new MutationObserver(() => this.update())), Bn(this, ei, tt(L, 24, this, () => {
2080
- ls(this, us).observe(this, { characterData: !0, childList: !0, subtree: !0 });
2081
- })), tt(L, 27, this), ke(this, "render", () => {
2061
+ super(...arguments), on(this, "prefix", j(L, 8, this)), j(L, 11, this), on(this, "suffix", j(L, 12, this)), j(L, 15, this), on(this, "inert", j(L, 16, this)), j(L, 19, this), Ze(this, ni, j(L, 20, this, () => !this.inert && ft(Rt, this.update))), j(L, 23, this), Ze(this, ds, new MutationObserver(() => this.update())), Ze(this, si, j(L, 24, this, () => {
2062
+ ls(this, ds).observe(this, { characterData: !0, childList: !0, subtree: !0 });
2063
+ })), j(L, 27, this), Ze(this, ii, j(L, 28, this, () => {
2082
2064
  var t;
2083
- return Fc((t = this.textContent) == null ? void 0 : t.trim(), this.prefix, this.suffix), at`${Go.title}`;
2084
- });
2065
+ return Xc((t = this.textContent) == null ? void 0 : t.trim(), this.prefix, this.suffix), ht`${Bo.title}`;
2066
+ })), j(L, 31, this);
2085
2067
  }
2086
2068
  static setTitle(t) {
2087
- It(At, { title: t });
2069
+ Rt({ title: t });
2088
2070
  }
2089
2071
  };
2090
- L = Wc(hs);
2091
- ti = /* @__PURE__ */ new WeakMap();
2092
- us = /* @__PURE__ */ new WeakMap();
2093
- ei = /* @__PURE__ */ new WeakMap();
2094
- he(L, 5, "prefix", Wo, bt);
2095
- he(L, 5, "suffix", Ho, bt);
2096
- he(L, 5, "inert", Ro, bt);
2097
- he(L, 21, "#connectStore", Io, ti);
2098
- he(L, 21, "#obTextContent", Ao, ei);
2099
- bt = he(L, 0, "GemTitleElement", zo, bt);
2100
- ke(bt, "title", document.title);
2101
- tt(L, 1, bt);
2102
- let xe = bt;
2103
- customElements.define("gem-title", xe);
2104
- var qc = Object.create, ni = Object.defineProperty, Uc = Object.getOwnPropertyDescriptor, Vo = (e, t) => (t = Symbol[e]) ? t : Symbol.for("Symbol." + e), ue = (e) => {
2072
+ L = Kc(us);
2073
+ ni = /* @__PURE__ */ new WeakMap();
2074
+ ds = /* @__PURE__ */ new WeakMap();
2075
+ si = /* @__PURE__ */ new WeakMap();
2076
+ ii = /* @__PURE__ */ new WeakMap();
2077
+ Gt(L, 5, "prefix", qo, Et);
2078
+ Gt(L, 5, "suffix", Fo, Et);
2079
+ Gt(L, 5, "inert", Do, Et);
2080
+ Gt(L, 21, "#connectStore", Vo, ni);
2081
+ Gt(L, 21, "#obTextContent", Go, si);
2082
+ Gt(L, 21, "#content", zo, ii);
2083
+ Et = Gt(L, 0, "GemTitleElement", Uo, Et);
2084
+ on(Et, "title", document.title);
2085
+ j(L, 1, Et);
2086
+ let Te = Et;
2087
+ customElements.define("gem-title", Te);
2088
+ var Zc = Object.create, ri = Object.defineProperty, th = Object.getOwnPropertyDescriptor, Ko = (e, t) => (t = Symbol[e]) ? t : Symbol.for("Symbol." + e), ue = (e) => {
2105
2089
  throw TypeError(e);
2106
- }, Do = (e, t, n) => t in e ? ni(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n, Ki = (e, t) => ni(e, "name", { value: t, configurable: !0 }), Bc = (e) => [, , , qc((e == null ? void 0 : e[Vo("metadata")]) ?? null)], Fo = ["class", "method", "getter", "setter", "accessor", "field", "value", "get", "set"], Te = (e) => e !== void 0 && typeof e != "function" ? ue("Function expected") : e, Kc = (e, t, n, s, i) => ({ kind: Fo[e], name: t, metadata: s, addInitializer: (o) => n._ ? ue("Already initialized") : i.push(Te(o || null)) }), jc = (e, t) => Do(t, Vo("metadata"), e[3]), ct = (e, t, n, s) => {
2107
- for (var i = 0, o = e[t >> 1], c = o && o.length; i < c; i++) t & 1 ? o[i].call(n) : s = o[i].call(n, s);
2090
+ }, jo = (e, t, n) => t in e ? ri(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n, Xi = (e, t) => ri(e, "name", { value: t, configurable: !0 }), eh = (e) => [, , , Zc((e == null ? void 0 : e[Ko("metadata")]) ?? null)], Jo = ["class", "method", "getter", "setter", "accessor", "field", "value", "get", "set"], Oe = (e) => e !== void 0 && typeof e != "function" ? ue("Function expected") : e, nh = (e, t, n, s, i) => ({ kind: Jo[e], name: t, metadata: s, addInitializer: (r) => n._ ? ue("Already initialized") : i.push(Oe(r || null)) }), sh = (e, t) => jo(t, Ko("metadata"), e[3]), nt = (e, t, n, s) => {
2091
+ for (var i = 0, r = e[t >> 1], c = r && r.length; i < c; i++) t & 1 ? r[i].call(n) : s = r[i].call(n, s);
2108
2092
  return s;
2109
- }, Ze = (e, t, n, s, i, o) => {
2110
- var c, a, f, h, m, r = t & 7, _ = !!(t & 8), l = !!(t & 16), g = r > 3 ? e.length + 1 : r ? _ ? 1 : 2 : 0, v = Fo[r + 5], y = r > 3 && (e[g - 1] = []), $ = e[g] || (e[g] = []), d = r && (!l && !_ && (i = i.prototype), r < 5 && (r > 3 || !l) && Uc(r < 4 ? i : { get [n]() {
2111
- return ds(this, o);
2112
- }, set [n](u) {
2113
- return ji(this, o, u);
2093
+ }, de = (e, t, n, s, i, r) => {
2094
+ var c, a, d, f, g, o = t & 7, _ = !!(t & 8), h = !!(t & 16), m = o > 3 ? e.length + 1 : o ? _ ? 1 : 2 : 0, v = Jo[o + 5], y = o > 3 && (e[m - 1] = []), E = e[m] || (e[m] = []), u = o && (!h && !_ && (i = i.prototype), o < 5 && (o > 3 || !h) && th(o < 4 ? i : { get [n]() {
2095
+ return ps(this, r);
2096
+ }, set [n](l) {
2097
+ return tr(this, r, l);
2114
2098
  } }, n));
2115
- r ? l && r < 4 && Ki(o, (r > 2 ? "set " : r > 1 ? "get " : "") + n) : Ki(i, n);
2099
+ o ? h && o < 4 && Xi(r, (o > 2 ? "set " : o > 1 ? "get " : "") + n) : Xi(i, n);
2116
2100
  for (var S = s.length - 1; S >= 0; S--)
2117
- h = Kc(r, n, f = {}, e[3], $), r && (h.static = _, h.private = l, m = h.access = { has: l ? (u) => Jc(i, u) : (u) => n in u }, r ^ 3 && (m.get = l ? (u) => (r ^ 1 ? ds : Qc)(u, i, r ^ 4 ? o : d.get) : (u) => u[n]), r > 2 && (m.set = l ? (u, k) => ji(u, i, k, r ^ 4 ? o : d.set) : (u, k) => u[n] = k)), a = (0, s[S])(r ? r < 4 ? l ? o : d[v] : r > 4 ? void 0 : { get: d.get, set: d.set } : i, h), f._ = 1, r ^ 4 || a === void 0 ? Te(a) && (r > 4 ? y.unshift(a) : r ? l ? o = a : d[v] = a : i = a) : typeof a != "object" || a === null ? ue("Object expected") : (Te(c = a.get) && (d.get = c), Te(c = a.set) && (d.set = c), Te(c = a.init) && y.unshift(c));
2118
- return r || jc(e, i), d && ni(i, n, d), l ? r ^ 4 ? o : d : i;
2119
- }, en = (e, t, n) => Do(e, typeof t != "symbol" ? t + "" : t, n), si = (e, t, n) => t.has(e) || ue("Cannot " + n), Jc = (e, t) => Object(t) !== t ? ue('Cannot use the "in" operator on this value') : e.has(t), ds = (e, t, n) => (si(e, t, "read from private field"), n ? n.call(e) : t.get(e)), Yc = (e, t, n) => t.has(e) ? ue("Cannot add the same private member more than once") : t instanceof WeakSet ? t.add(e) : t.set(e, n), ji = (e, t, n, s) => (si(e, t, "write to private field"), s ? s.call(e, n) : t.set(e, n), n), Qc = (e, t, n) => (si(e, t, "access private method"), n), qo, Uo, Bo, Ko, ps, jo, G, fs;
2120
- const Xc = Pn(vr`
2101
+ f = nh(o, n, d = {}, e[3], E), o && (f.static = _, f.private = h, g = f.access = { has: h ? (l) => ih(i, l) : (l) => n in l }, o ^ 3 && (g.get = h ? (l) => (o ^ 1 ? ps : rh)(l, i, o ^ 4 ? r : u.get) : (l) => l[n]), o > 2 && (g.set = h ? (l, k) => tr(l, i, k, o ^ 4 ? r : u.set) : (l, k) => l[n] = k)), a = (0, s[S])(o ? o < 4 ? h ? r : u[v] : o > 4 ? void 0 : { get: u.get, set: u.set } : i, f), d._ = 1, o ^ 4 || a === void 0 ? Oe(a) && (o > 4 ? y.unshift(a) : o ? h ? r = a : u[v] = a : i = a) : typeof a != "object" || a === null ? ue("Object expected") : (Oe(c = a.get) && (u.get = c), Oe(c = a.set) && (u.set = c), Oe(c = a.init) && y.unshift(c));
2102
+ return o || sh(e, i), u && ri(i, n, u), h ? o ^ 4 ? r : u : i;
2103
+ }, tn = (e, t, n) => jo(e, typeof t != "symbol" ? t + "" : t, n), oi = (e, t, n) => t.has(e) || ue("Cannot " + n), ih = (e, t) => Object(t) !== t ? ue('Cannot use the "in" operator on this value') : e.has(t), ps = (e, t, n) => (oi(e, t, "read from private field"), n ? n.call(e) : t.get(e)), Zi = (e, t, n) => t.has(e) ? ue("Cannot add the same private member more than once") : t instanceof WeakSet ? t.add(e) : t.set(e, n), tr = (e, t, n, s) => (oi(e, t, "write to private field"), s ? s.call(e, n) : t.set(e, n), n), rh = (e, t, n) => (oi(e, t, "access private method"), n), Yo, Qo, Xo, Zo, ta, fs, ea, I, _s, ai;
2104
+ const oh = Pn(br`
2121
2105
  :host(:where(:not([hidden]))) {
2122
2106
  position: relative;
2123
2107
  display: inline-flex;
@@ -2127,57 +2111,54 @@ const Xc = Pn(vr`
2127
2111
  width: 100%;
2128
2112
  height: 100%;
2129
2113
  }
2130
- `), Ji = /* @__PURE__ */ new Map();
2131
- jo = [Ht(), Rs(Xc)];
2132
- class Ct extends (ps = B, Ko = [V], Bo = [U], Uo = [U], qo = [On], ps) {
2114
+ `), er = /* @__PURE__ */ new Map();
2115
+ ea = [zt(), Hs(oh)];
2116
+ class bt extends (fs = B, ta = [V], Zo = [U], Xo = [U], Qo = [On], Yo = [ae()], fs) {
2133
2117
  constructor() {
2134
- super(...arguments), en(this, "selector", ct(G, 8, this)), ct(G, 11, this), en(this, "root", ct(G, 12, this)), ct(G, 15, this), en(this, "element", ct(G, 16, this)), ct(G, 19, this), en(this, "active", ct(G, 20, this)), ct(G, 23, this), Yc(this, fs, () => {
2118
+ super(...arguments), tn(this, "selector", nt(I, 8, this)), nt(I, 11, this), tn(this, "root", nt(I, 12, this)), nt(I, 15, this), tn(this, "element", nt(I, 16, this)), nt(I, 19, this), tn(this, "active", nt(I, 20, this)), nt(I, 23, this), Zi(this, _s, () => {
2135
2119
  const t = this.element || (this.selector ? (this.root || document).querySelector(this.selector) : null);
2136
2120
  if (typeof t == "string") {
2137
- let n = Ji.get(t);
2138
- return n || (n = document.createElement("template"), n.innerHTML = t, Ji.set(t, n)), n.content.cloneNode(!0);
2121
+ let n = er.get(t);
2122
+ return n || (n = document.createElement("template"), n.innerHTML = t, er.set(t, n)), n.content.cloneNode(!0);
2139
2123
  } else return t instanceof HTMLTemplateElement ? t.content.cloneNode(!0) : t == null ? void 0 : t.cloneNode(!0);
2140
- });
2141
- }
2142
- render() {
2143
- return at`
2144
- ${ds(this, fs).call(this)}
2124
+ }), Zi(this, ai, nt(I, 24, this, () => ht`
2125
+ ${ps(this, _s).call(this)}
2145
2126
  <slot></slot>
2146
- `;
2147
- }
2148
- }
2149
- G = Bc(ps);
2150
- fs = /* @__PURE__ */ new WeakMap();
2151
- Ze(G, 5, "selector", Ko, Ct);
2152
- Ze(G, 5, "root", Bo, Ct);
2153
- Ze(G, 5, "element", Uo, Ct);
2154
- Ze(G, 5, "active", qo, Ct);
2155
- Ct = Ze(G, 0, "GemUseElement", jo, Ct);
2156
- ct(G, 1, Ct);
2157
- customElements.define("gem-use", Ct);
2158
- var Zc = Object.create, ii = Object.defineProperty, tl = Object.getOwnPropertyDescriptor, Jo = (e, t) => (t = Symbol[e]) ? t : Symbol.for("Symbol." + e), tn = (e) => {
2127
+ `)), nt(I, 27, this);
2128
+ }
2129
+ }
2130
+ I = eh(fs);
2131
+ _s = /* @__PURE__ */ new WeakMap();
2132
+ ai = /* @__PURE__ */ new WeakMap();
2133
+ de(I, 5, "selector", ta, bt);
2134
+ de(I, 5, "root", Zo, bt);
2135
+ de(I, 5, "element", Xo, bt);
2136
+ de(I, 5, "active", Qo, bt);
2137
+ de(I, 21, "#content", Yo, ai);
2138
+ bt = de(I, 0, "GemUseElement", ea, bt);
2139
+ nt(I, 1, bt);
2140
+ customElements.define("gem-use", bt);
2141
+ var ah = Object.create, ci = Object.defineProperty, ch = Object.getOwnPropertyDescriptor, na = (e, t) => (t = Symbol[e]) ? t : Symbol.for("Symbol." + e), pe = (e) => {
2159
2142
  throw TypeError(e);
2160
- }, Yo = (e, t, n) => t in e ? ii(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n, Yi = (e, t) => ii(e, "name", { value: t, configurable: !0 }), el = (e) => [, , , Zc((e == null ? void 0 : e[Jo("metadata")]) ?? null)], Qo = ["class", "method", "getter", "setter", "accessor", "field", "value", "get", "set"], Oe = (e) => e !== void 0 && typeof e != "function" ? tn("Function expected") : e, nl = (e, t, n, s, i) => ({ kind: Qo[e], name: t, metadata: s, addInitializer: (o) => n._ ? tn("Already initialized") : i.push(Oe(o || null)) }), sl = (e, t) => Yo(t, Jo("metadata"), e[3]), Me = (e, t, n, s) => {
2161
- for (var i = 0, o = e[t >> 1], c = o && o.length; i < c; i++) t & 1 ? o[i].call(n) : s = o[i].call(n, s);
2143
+ }, sa = (e, t, n) => t in e ? ci(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n, nr = (e, t) => ci(e, "name", { value: t, configurable: !0 }), hh = (e) => [, , , ah((e == null ? void 0 : e[na("metadata")]) ?? null)], ia = ["class", "method", "getter", "setter", "accessor", "field", "value", "get", "set"], Me = (e) => e !== void 0 && typeof e != "function" ? pe("Function expected") : e, lh = (e, t, n, s, i) => ({ kind: ia[e], name: t, metadata: s, addInitializer: (r) => n._ ? pe("Already initialized") : i.push(Me(r || null)) }), uh = (e, t) => sa(t, na("metadata"), e[3]), Tt = (e, t, n, s) => {
2144
+ for (var i = 0, r = e[t >> 1], c = r && r.length; i < c; i++) t & 1 ? r[i].call(n) : s = r[i].call(n, s);
2162
2145
  return s;
2163
- }, ri = (e, t, n, s, i, o) => {
2164
- var c, a, f, h, m, r = t & 7, _ = !!(t & 8), l = !!(t & 16), g = r > 3 ? e.length + 1 : r ? _ ? 1 : 2 : 0, v = Qo[r + 5], y = r > 3 && (e[g - 1] = []), $ = e[g] || (e[g] = []), d = r && (!l && !_ && (i = i.prototype), r < 5 && (r > 3 || !l) && tl(r < 4 ? i : { get [n]() {
2165
- return Xi(this, o);
2166
- }, set [n](u) {
2167
- return Zi(this, o, u);
2146
+ }, Nn = (e, t, n, s, i, r) => {
2147
+ var c, a, d, f, g, o = t & 7, _ = !!(t & 8), h = !!(t & 16), m = o > 3 ? e.length + 1 : o ? _ ? 1 : 2 : 0, v = ia[o + 5], y = o > 3 && (e[m - 1] = []), E = e[m] || (e[m] = []), u = o && (!h && !_ && (i = i.prototype), o < 5 && (o > 3 || !h) && ch(o < 4 ? i : { get [n]() {
2148
+ return ir(this, r);
2149
+ }, set [n](l) {
2150
+ return rr(this, r, l);
2168
2151
  } }, n));
2169
- r ? l && r < 4 && Yi(o, (r > 2 ? "set " : r > 1 ? "get " : "") + n) : Yi(i, n);
2152
+ o ? h && o < 4 && nr(r, (o > 2 ? "set " : o > 1 ? "get " : "") + n) : nr(i, n);
2170
2153
  for (var S = s.length - 1; S >= 0; S--)
2171
- h = nl(r, n, f = {}, e[3], $), r && (h.static = _, h.private = l, m = h.access = { has: l ? (u) => il(i, u) : (u) => n in u }, r ^ 3 && (m.get = l ? (u) => (r ^ 1 ? Xi : rl)(u, i, r ^ 4 ? o : d.get) : (u) => u[n]), r > 2 && (m.set = l ? (u, k) => Zi(u, i, k, r ^ 4 ? o : d.set) : (u, k) => u[n] = k)), a = (0, s[S])(r ? r < 4 ? l ? o : d[v] : r > 4 ? void 0 : { get: d.get, set: d.set } : i, h), f._ = 1, r ^ 4 || a === void 0 ? Oe(a) && (r > 4 ? y.unshift(a) : r ? l ? o = a : d[v] = a : i = a) : typeof a != "object" || a === null ? tn("Object expected") : (Oe(c = a.get) && (d.get = c), Oe(c = a.set) && (d.set = c), Oe(c = a.init) && y.unshift(c));
2172
- return r || sl(e, i), d && ii(i, n, d), l ? r ^ 4 ? o : d : i;
2173
- }, Qi = (e, t, n) => Yo(e, typeof t != "symbol" ? t + "" : t, n), oi = (e, t, n) => t.has(e) || tn("Cannot " + n), il = (e, t) => Object(t) !== t ? tn('Cannot use the "in" operator on this value') : e.has(t), Xi = (e, t, n) => (oi(e, t, "read from private field"), n ? n.call(e) : t.get(e)), Zi = (e, t, n, s) => (oi(e, t, "write to private field"), s ? s.call(e, n) : t.set(e, n), n), rl = (e, t, n) => (oi(e, t, "access private method"), n), Xo, Zo, _s, ta, pt;
2174
- ta = [Ht()];
2175
- class ie extends (_s = B, Zo = [V], Xo = [V], _s) {
2154
+ f = lh(o, n, d = {}, e[3], E), o && (f.static = _, f.private = h, g = f.access = { has: h ? (l) => dh(i, l) : (l) => n in l }, o ^ 3 && (g.get = h ? (l) => (o ^ 1 ? ir : fh)(l, i, o ^ 4 ? r : u.get) : (l) => l[n]), o > 2 && (g.set = h ? (l, k) => rr(l, i, k, o ^ 4 ? r : u.set) : (l, k) => l[n] = k)), a = (0, s[S])(o ? o < 4 ? h ? r : u[v] : o > 4 ? void 0 : { get: u.get, set: u.set } : i, f), d._ = 1, o ^ 4 || a === void 0 ? Me(a) && (o > 4 ? y.unshift(a) : o ? h ? r = a : u[v] = a : i = a) : typeof a != "object" || a === null ? pe("Object expected") : (Me(c = a.get) && (u.get = c), Me(c = a.set) && (u.set = c), Me(c = a.init) && y.unshift(c));
2155
+ return o || uh(e, i), u && ci(i, n, u), h ? o ^ 4 ? r : u : i;
2156
+ }, sr = (e, t, n) => sa(e, typeof t != "symbol" ? t + "" : t, n), hi = (e, t, n) => t.has(e) || pe("Cannot " + n), dh = (e, t) => Object(t) !== t ? pe('Cannot use the "in" operator on this value') : e.has(t), ir = (e, t, n) => (hi(e, t, "read from private field"), n ? n.call(e) : t.get(e)), ph = (e, t, n) => t.has(e) ? pe("Cannot add the same private member more than once") : t instanceof WeakSet ? t.add(e) : t.set(e, n), rr = (e, t, n, s) => (hi(e, t, "write to private field"), s ? s.call(e, n) : t.set(e, n), n), fh = (e, t, n) => (hi(e, t, "access private method"), n), ra, oa, aa, gs, ca, Z, li;
2157
+ ca = [zt()];
2158
+ class ie extends (gs = B, aa = [V], oa = [V], ra = [ae()], gs) {
2176
2159
  constructor() {
2177
- super(...arguments), Qi(this, "content", Me(pt, 8, this)), Me(pt, 11, this), Qi(this, "contentcss", Me(pt, 12, this)), Me(pt, 15, this);
2178
- }
2179
- render() {
2180
- this.shadowRoot.innerHTML = Ps`
2160
+ super(...arguments), sr(this, "content", Tt(Z, 8, this)), Tt(Z, 11, this), sr(this, "contentcss", Tt(Z, 12, this)), Tt(Z, 15, this), ph(this, li, Tt(Z, 16, this, () => {
2161
+ this.shadowRoot.innerHTML = ks`
2181
2162
  <style>
2182
2163
  :host(:where(:not([hidden]))) {
2183
2164
  display: contents;
@@ -2186,93 +2167,96 @@ class ie extends (_s = B, Zo = [V], Xo = [V], _s) {
2186
2167
  </style>
2187
2168
  ${this.content}
2188
2169
  `;
2170
+ })), Tt(Z, 19, this);
2189
2171
  }
2190
2172
  }
2191
- pt = el(_s);
2192
- ri(pt, 5, "content", Zo, ie);
2193
- ri(pt, 5, "contentcss", Xo, ie);
2194
- ie = ri(pt, 0, "GemUnsafeElement", ta, ie);
2195
- Me(pt, 1, ie);
2173
+ Z = hh(gs);
2174
+ li = /* @__PURE__ */ new WeakMap();
2175
+ Nn(Z, 5, "content", aa, ie);
2176
+ Nn(Z, 5, "contentcss", oa, ie);
2177
+ Nn(Z, 21, "#content", ra, li);
2178
+ ie = Nn(Z, 0, "GemUnsafeElement", ca, ie);
2179
+ Tt(Z, 1, ie);
2196
2180
  customElements.define("gem-unsafe", ie);
2197
- var ol = Object.create, ai = Object.defineProperty, al = Object.getOwnPropertyDescriptor, ea = (e, t) => (t = Symbol[e]) ? t : Symbol.for("Symbol." + e), de = (e) => {
2181
+ var _h = Object.create, ui = Object.defineProperty, gh = Object.getOwnPropertyDescriptor, ha = (e, t) => (t = Symbol[e]) ? t : Symbol.for("Symbol." + e), fe = (e) => {
2198
2182
  throw TypeError(e);
2199
- }, na = (e, t, n) => t in e ? ai(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n, tr = (e, t) => ai(e, "name", { value: t, configurable: !0 }), cl = (e) => [, , , ol((e == null ? void 0 : e[ea("metadata")]) ?? null)], sa = ["class", "method", "getter", "setter", "accessor", "field", "value", "get", "set"], Le = (e) => e !== void 0 && typeof e != "function" ? de("Function expected") : e, ll = (e, t, n, s, i) => ({ kind: sa[e], name: t, metadata: s, addInitializer: (o) => n._ ? de("Already initialized") : i.push(Le(o || null)) }), ia = (e, t) => na(t, ea("metadata"), e[3]), _t = (e, t, n, s) => {
2200
- for (var i = 0, o = e[t >> 1], c = o && o.length; i < c; i++) t & 1 ? o[i].call(n) : s = o[i].call(n, s);
2183
+ }, la = (e, t, n) => t in e ? ui(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n, or = (e, t) => ui(e, "name", { value: t, configurable: !0 }), mh = (e) => [, , , _h((e == null ? void 0 : e[ha("metadata")]) ?? null)], ua = ["class", "method", "getter", "setter", "accessor", "field", "value", "get", "set"], Le = (e) => e !== void 0 && typeof e != "function" ? fe("Function expected") : e, vh = (e, t, n, s, i) => ({ kind: ua[e], name: t, metadata: s, addInitializer: (r) => n._ ? fe("Already initialized") : i.push(Le(r || null)) }), da = (e, t) => la(t, ha("metadata"), e[3]), _t = (e, t, n, s) => {
2184
+ for (var i = 0, r = e[t >> 1], c = r && r.length; i < c; i++) t & 1 ? r[i].call(n) : s = r[i].call(n, s);
2201
2185
  return s;
2202
- }, Nn = (e, t, n, s, i, o) => {
2203
- var c, a, f, h, m, r = t & 7, _ = !!(t & 8), l = !!(t & 16), g = r > 3 ? e.length + 1 : r ? _ ? 1 : 2 : 0, v = sa[r + 5], y = r > 3 && (e[g - 1] = []), $ = e[g] || (e[g] = []), d = r && (!l && !_ && (i = i.prototype), r < 5 && (r > 3 || !l) && al(r < 4 ? i : { get [n]() {
2204
- return mt(this, o);
2205
- }, set [n](u) {
2206
- return gs(this, o, u);
2186
+ }, An = (e, t, n, s, i, r) => {
2187
+ var c, a, d, f, g, o = t & 7, _ = !!(t & 8), h = !!(t & 16), m = o > 3 ? e.length + 1 : o ? _ ? 1 : 2 : 0, v = ua[o + 5], y = o > 3 && (e[m - 1] = []), E = e[m] || (e[m] = []), u = o && (!h && !_ && (i = i.prototype), o < 5 && (o > 3 || !h) && gh(o < 4 ? i : { get [n]() {
2188
+ return mt(this, r);
2189
+ }, set [n](l) {
2190
+ return ms(this, r, l);
2207
2191
  } }, n));
2208
- r ? l && r < 4 && tr(o, (r > 2 ? "set " : r > 1 ? "get " : "") + n) : tr(i, n);
2192
+ o ? h && o < 4 && or(r, (o > 2 ? "set " : o > 1 ? "get " : "") + n) : or(i, n);
2209
2193
  for (var S = s.length - 1; S >= 0; S--)
2210
- h = ll(r, n, f = {}, e[3], $), r && (h.static = _, h.private = l, m = h.access = { has: l ? (u) => hl(i, u) : (u) => n in u }, r ^ 3 && (m.get = l ? (u) => (r ^ 1 ? mt : ul)(u, i, r ^ 4 ? o : d.get) : (u) => u[n]), r > 2 && (m.set = l ? (u, k) => gs(u, i, k, r ^ 4 ? o : d.set) : (u, k) => u[n] = k)), a = (0, s[S])(r ? r < 4 ? l ? o : d[v] : r > 4 ? void 0 : { get: d.get, set: d.set } : i, h), f._ = 1, r ^ 4 || a === void 0 ? Le(a) && (r > 4 ? y.unshift(a) : r ? l ? o = a : d[v] = a : i = a) : typeof a != "object" || a === null ? de("Object expected") : (Le(c = a.get) && (d.get = c), Le(c = a.set) && (d.set = c), Le(c = a.init) && y.unshift(c));
2211
- return r || ia(e, i), d && ai(i, n, d), l ? r ^ 4 ? o : d : i;
2212
- }, er = (e, t, n) => na(e, typeof t != "symbol" ? t + "" : t, n), ci = (e, t, n) => t.has(e) || de("Cannot " + n), hl = (e, t) => Object(t) !== t ? de('Cannot use the "in" operator on this value') : e.has(t), mt = (e, t, n) => (ci(e, t, "read from private field"), n ? n.call(e) : t.get(e)), Wt = (e, t, n) => t.has(e) ? de("Cannot add the same private member more than once") : t instanceof WeakSet ? t.add(e) : t.set(e, n), gs = (e, t, n, s) => (ci(e, t, "write to private field"), s ? s.call(e, n) : t.set(e, n), n), ul = (e, t, n) => (ci(e, t, "access private method"), n), ra, oa, aa, ca, ms, F, vs, la, li, cn, ws, Ne, hi;
2213
- const dl = "gem-reflect-start", ha = "gem-reflect-end", nr = (e) => new Comment(e), pl = (e) => {
2194
+ f = vh(o, n, d = {}, e[3], E), o && (f.static = _, f.private = h, g = f.access = { has: h ? (l) => wh(i, l) : (l) => n in l }, o ^ 3 && (g.get = h ? (l) => (o ^ 1 ? mt : yh)(l, i, o ^ 4 ? r : u.get) : (l) => l[n]), o > 2 && (g.set = h ? (l, k) => ms(l, i, k, o ^ 4 ? r : u.set) : (l, k) => l[n] = k)), a = (0, s[S])(o ? o < 4 ? h ? r : u[v] : o > 4 ? void 0 : { get: u.get, set: u.set } : i, f), d._ = 1, o ^ 4 || a === void 0 ? Le(a) && (o > 4 ? y.unshift(a) : o ? h ? r = a : u[v] = a : i = a) : typeof a != "object" || a === null ? fe("Object expected") : (Le(c = a.get) && (u.get = c), Le(c = a.set) && (u.set = c), Le(c = a.init) && y.unshift(c));
2195
+ return o || da(e, i), u && ui(i, n, u), h ? o ^ 4 ? r : u : i;
2196
+ }, ar = (e, t, n) => la(e, typeof t != "symbol" ? t + "" : t, n), di = (e, t, n) => t.has(e) || fe("Cannot " + n), wh = (e, t) => Object(t) !== t ? fe('Cannot use the "in" operator on this value') : e.has(t), mt = (e, t, n) => (di(e, t, "read from private field"), n ? n.call(e) : t.get(e)), Vt = (e, t, n) => t.has(e) ? fe("Cannot add the same private member more than once") : t instanceof WeakSet ? t.add(e) : t.set(e, n), ms = (e, t, n, s) => (di(e, t, "write to private field"), s ? s.call(e, n) : t.set(e, n), n), yh = (e, t, n) => (di(e, t, "access private method"), n), pa, fa, _a, ga, vs, F, ws, ma, pi, an, ys, Ne, fi;
2197
+ const Sh = "gem-reflect-start", va = "gem-reflect-end", cr = (e) => new Comment(e), $h = (e) => {
2214
2198
  const t = [];
2215
2199
  let n = e;
2216
- for (; n && (t.push(n), n.nodeValue !== ha); )
2200
+ for (; n && (t.push(n), n.nodeValue !== va); )
2217
2201
  n = n.nextSibling;
2218
2202
  return t;
2219
2203
  };
2220
- class An extends (ms = B, ca = [V], aa = [U], oa = [Is()], ra = [$t((t) => [t.target])], ms) {
2204
+ class In extends (vs = B, ga = [V], _a = [U], fa = [Rs()], pa = [St((t) => [t.target])], vs) {
2221
2205
  constructor() {
2222
- super(...arguments), Wt(this, vs), er(this, "method", _t(F, 8, this)), _t(F, 11, this), er(this, "target", _t(F, 12, this, document.head)), _t(F, 15, this), Wt(this, li, _t(F, 16, this, () => {
2206
+ super(...arguments), Vt(this, ws), ar(this, "method", _t(F, 8, this)), _t(F, 11, this), ar(this, "target", _t(F, 12, this, document.head)), _t(F, 15, this), Vt(this, pi, _t(F, 16, this, () => {
2223
2207
  this.hidden = !0, this.dataset.gemReflect = "";
2224
- })), _t(F, 19, this), Wt(this, cn, nr(dl)), Wt(this, ws, nr(ha)), Wt(this, Ne), Wt(this, hi, _t(F, 20, this, () => ((mt(this, Ne) || [mt(this, cn), ...this.childNodes, mt(this, ws)]).forEach((t, n, s) => {
2208
+ })), _t(F, 19, this), Vt(this, an, cr(Sh)), Vt(this, ys, cr(va)), Vt(this, Ne), Vt(this, fi, _t(F, 20, this, () => ((mt(this, Ne) || [mt(this, an), ...this.childNodes, mt(this, ys)]).forEach((t, n, s) => {
2225
2209
  const i = s[n - 1];
2226
- i ? i.after(t) : this.target[mt(this, vs, la)](t);
2210
+ i ? i.after(t) : this.target[mt(this, ws, ma)](t);
2227
2211
  }), () => {
2228
- gs(this, Ne, pl(mt(this, cn))), mt(this, Ne).forEach((t) => t.remove());
2212
+ ms(this, Ne, $h(mt(this, an))), mt(this, Ne).forEach((t) => t.remove());
2229
2213
  }))), _t(F, 23, this);
2230
2214
  }
2231
2215
  }
2232
- F = cl(ms);
2233
- vs = /* @__PURE__ */ new WeakSet();
2234
- la = function() {
2216
+ F = mh(vs);
2217
+ ws = /* @__PURE__ */ new WeakSet();
2218
+ ma = function() {
2235
2219
  return this.method || "append";
2236
2220
  };
2237
- li = /* @__PURE__ */ new WeakMap();
2238
- cn = /* @__PURE__ */ new WeakMap();
2239
- ws = /* @__PURE__ */ new WeakMap();
2221
+ pi = /* @__PURE__ */ new WeakMap();
2222
+ an = /* @__PURE__ */ new WeakMap();
2223
+ ys = /* @__PURE__ */ new WeakMap();
2240
2224
  Ne = /* @__PURE__ */ new WeakMap();
2241
- hi = /* @__PURE__ */ new WeakMap();
2242
- Nn(F, 5, "method", ca, An);
2243
- Nn(F, 5, "target", aa, An);
2244
- Nn(F, 21, "#init", oa, li);
2245
- Nn(F, 21, "#changeTarget", ra, hi);
2246
- ia(F, An);
2247
- customElements.define("gem-reflect", An);
2248
- var fl = Object.create, ui = Object.defineProperty, _l = Object.getOwnPropertyDescriptor, ua = (e, t) => (t = Symbol[e]) ? t : Symbol.for("Symbol." + e), pe = (e) => {
2225
+ fi = /* @__PURE__ */ new WeakMap();
2226
+ An(F, 5, "method", ga, In);
2227
+ An(F, 5, "target", _a, In);
2228
+ An(F, 21, "#init", fa, pi);
2229
+ An(F, 21, "#changeTarget", pa, fi);
2230
+ da(F, In);
2231
+ customElements.define("gem-reflect", In);
2232
+ var Eh = Object.create, _i = Object.defineProperty, bh = Object.getOwnPropertyDescriptor, wa = (e, t) => (t = Symbol[e]) ? t : Symbol.for("Symbol." + e), _e = (e) => {
2249
2233
  throw TypeError(e);
2250
- }, da = (e, t, n) => t in e ? ui(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n, sr = (e, t) => ui(e, "name", { value: t, configurable: !0 }), gl = (e) => [, , , fl((e == null ? void 0 : e[ua("metadata")]) ?? null)], pa = ["class", "method", "getter", "setter", "accessor", "field", "value", "get", "set"], Ae = (e) => e !== void 0 && typeof e != "function" ? pe("Function expected") : e, ml = (e, t, n, s, i) => ({ kind: pa[e], name: t, metadata: s, addInitializer: (o) => n._ ? pe("Already initialized") : i.push(Ae(o || null)) }), vl = (e, t) => da(t, ua("metadata"), e[3]), ge = (e, t, n, s) => {
2251
- for (var i = 0, o = e[t >> 1], c = o && o.length; i < c; i++) t & 1 ? o[i].call(n) : s = o[i].call(n, s);
2234
+ }, ya = (e, t, n) => t in e ? _i(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n, hr = (e, t) => _i(e, "name", { value: t, configurable: !0 }), Ch = (e) => [, , , Eh((e == null ? void 0 : e[wa("metadata")]) ?? null)], Sa = ["class", "method", "getter", "setter", "accessor", "field", "value", "get", "set"], Ae = (e) => e !== void 0 && typeof e != "function" ? _e("Function expected") : e, Ph = (e, t, n, s, i) => ({ kind: Sa[e], name: t, metadata: s, addInitializer: (r) => n._ ? _e("Already initialized") : i.push(Ae(r || null)) }), kh = (e, t) => ya(t, wa("metadata"), e[3]), me = (e, t, n, s) => {
2235
+ for (var i = 0, r = e[t >> 1], c = r && r.length; i < c; i++) t & 1 ? r[i].call(n) : s = r[i].call(n, s);
2252
2236
  return s;
2253
- }, Kn = (e, t, n, s, i, o) => {
2254
- var c, a, f, h, m, r = t & 7, _ = !!(t & 8), l = !!(t & 16), g = r > 3 ? e.length + 1 : r ? _ ? 1 : 2 : 0, v = pa[r + 5], y = r > 3 && (e[g - 1] = []), $ = e[g] || (e[g] = []), d = r && (!l && !_ && (i = i.prototype), r < 5 && (r > 3 || !l) && _l(r < 4 ? i : { get [n]() {
2255
- return ir(this, o);
2256
- }, set [n](u) {
2257
- return or(this, o, u);
2237
+ }, Kn = (e, t, n, s, i, r) => {
2238
+ var c, a, d, f, g, o = t & 7, _ = !!(t & 8), h = !!(t & 16), m = o > 3 ? e.length + 1 : o ? _ ? 1 : 2 : 0, v = Sa[o + 5], y = o > 3 && (e[m - 1] = []), E = e[m] || (e[m] = []), u = o && (!h && !_ && (i = i.prototype), o < 5 && (o > 3 || !h) && bh(o < 4 ? i : { get [n]() {
2239
+ return lr(this, r);
2240
+ }, set [n](l) {
2241
+ return dr(this, r, l);
2258
2242
  } }, n));
2259
- r ? l && r < 4 && sr(o, (r > 2 ? "set " : r > 1 ? "get " : "") + n) : sr(i, n);
2243
+ o ? h && o < 4 && hr(r, (o > 2 ? "set " : o > 1 ? "get " : "") + n) : hr(i, n);
2260
2244
  for (var S = s.length - 1; S >= 0; S--)
2261
- h = ml(r, n, f = {}, e[3], $), r && (h.static = _, h.private = l, m = h.access = { has: l ? (u) => wl(i, u) : (u) => n in u }, r ^ 3 && (m.get = l ? (u) => (r ^ 1 ? ir : yl)(u, i, r ^ 4 ? o : d.get) : (u) => u[n]), r > 2 && (m.set = l ? (u, k) => or(u, i, k, r ^ 4 ? o : d.set) : (u, k) => u[n] = k)), a = (0, s[S])(r ? r < 4 ? l ? o : d[v] : r > 4 ? void 0 : { get: d.get, set: d.set } : i, h), f._ = 1, r ^ 4 || a === void 0 ? Ae(a) && (r > 4 ? y.unshift(a) : r ? l ? o = a : d[v] = a : i = a) : typeof a != "object" || a === null ? pe("Object expected") : (Ae(c = a.get) && (d.get = c), Ae(c = a.set) && (d.set = c), Ae(c = a.init) && y.unshift(c));
2262
- return r || vl(e, i), d && ui(i, n, d), l ? r ^ 4 ? o : d : i;
2263
- }, nn = (e, t, n) => da(e, typeof t != "symbol" ? t + "" : t, n), di = (e, t, n) => t.has(e) || pe("Cannot " + n), wl = (e, t) => Object(t) !== t ? pe('Cannot use the "in" operator on this value') : e.has(t), ir = (e, t, n) => (di(e, t, "read from private field"), n ? n.call(e) : t.get(e)), rr = (e, t, n) => t.has(e) ? pe("Cannot add the same private member more than once") : t instanceof WeakSet ? t.add(e) : t.set(e, n), or = (e, t, n, s) => (di(e, t, "write to private field"), s ? s.call(e, n) : t.set(e, n), n), yl = (e, t, n) => (di(e, t, "access private method"), n);
2264
- const sn = Symbol("open mark");
2265
- function Ul(e) {
2266
- var t, n, s, i, o, c, a;
2267
- const f = Symbol();
2268
- i = [Ht(), Ln({ role: "alertdialog", ariaModal: "true" })];
2269
- let h = class fa extends (s = B, n = [qe()], t = [qe()], s) {
2245
+ f = Ph(o, n, d = {}, e[3], E), o && (f.static = _, f.private = h, g = f.access = { has: h ? (l) => xh(i, l) : (l) => n in l }, o ^ 3 && (g.get = h ? (l) => (o ^ 1 ? lr : Th)(l, i, o ^ 4 ? r : u.get) : (l) => l[n]), o > 2 && (g.set = h ? (l, k) => dr(l, i, k, o ^ 4 ? r : u.set) : (l, k) => l[n] = k)), a = (0, s[S])(o ? o < 4 ? h ? r : u[v] : o > 4 ? void 0 : { get: u.get, set: u.set } : i, f), d._ = 1, o ^ 4 || a === void 0 ? Ae(a) && (o > 4 ? y.unshift(a) : o ? h ? r = a : u[v] = a : i = a) : typeof a != "object" || a === null ? _e("Object expected") : (Ae(c = a.get) && (u.get = c), Ae(c = a.set) && (u.set = c), Ae(c = a.init) && y.unshift(c));
2246
+ return o || kh(e, i), u && _i(i, n, u), h ? o ^ 4 ? r : u : i;
2247
+ }, en = (e, t, n) => ya(e, typeof t != "symbol" ? t + "" : t, n), gi = (e, t, n) => t.has(e) || _e("Cannot " + n), xh = (e, t) => Object(t) !== t ? _e('Cannot use the "in" operator on this value') : e.has(t), lr = (e, t, n) => (gi(e, t, "read from private field"), n ? n.call(e) : t.get(e)), ur = (e, t, n) => t.has(e) ? _e("Cannot add the same private member more than once") : t instanceof WeakSet ? t.add(e) : t.set(e, n), dr = (e, t, n, s) => (gi(e, t, "write to private field"), s ? s.call(e, n) : t.set(e, n), n), Th = (e, t, n) => (gi(e, t, "access private method"), n);
2248
+ const nn = Symbol("open mark");
2249
+ function tl(e) {
2250
+ var t, n, s, i, r, c, a;
2251
+ const d = Symbol();
2252
+ i = [zt(), Ln({ role: "alertdialog", ariaModal: "true" })];
2253
+ let f = class $a extends (s = B, n = [qe()], t = [qe()], s) {
2270
2254
  constructor() {
2271
- super(...arguments), nn(this, "label", ""), rr(this, c, ge(o, 8, this, () => ft(O.store, this.update))), ge(o, 11, this), rr(this, a, ge(o, 12, this, () => ft(fa.store, this.update))), ge(o, 15, this);
2255
+ super(...arguments), en(this, "label", ""), ur(this, c, me(r, 8, this, () => ft(M.store, this.update))), me(r, 11, this), ur(this, a, me(r, 12, this, () => ft($a.store, this.update))), me(r, 15, this);
2272
2256
  }
2273
2257
  /**@final */
2274
2258
  static get isOpen() {
2275
- return this.store[sn];
2259
+ return this.store[nn];
2276
2260
  }
2277
2261
  /**
2278
2262
  * @final
@@ -2280,24 +2264,24 @@ function Ul(e) {
2280
2264
  * 浏览器 history 为异步 API,需要设置较长延迟;
2281
2265
  */
2282
2266
  static open(_) {
2283
- const l = new this();
2284
- this.instance = l, this.inertStore = [...document.body.children].filter((v) => !v.inert), this.inertStore.forEach((v) => v.inert = !0), document.body.append(l);
2285
- const g = () => It(this.store, { [sn]: !0, ..._ });
2267
+ const h = new this();
2268
+ this.instance = h, this.inertStore = [...document.body.children].filter((v) => !v.inert), this.inertStore.forEach((v) => v.inert = !0), document.body.append(h);
2269
+ const m = () => this.store({ [nn]: !0, ..._ });
2286
2270
  return setTimeout(() => {
2287
- g(), O.push({
2288
- title: l.label,
2289
- open: g,
2271
+ m(), M.push({
2272
+ title: h.label,
2273
+ open: m,
2290
2274
  close: this.closeHandle.bind(this),
2291
2275
  shouldClose: this.shouldClose.bind(this)
2292
2276
  });
2293
- }, 100), f;
2277
+ }, 100), d;
2294
2278
  }
2295
2279
  /**
2296
2280
  * @final
2297
2281
  * UI 中执行关闭
2298
2282
  */
2299
2283
  static close() {
2300
- return O.back(), f;
2284
+ return M.back(), d;
2301
2285
  }
2302
2286
  /**
2303
2287
  * @final
@@ -2305,7 +2289,7 @@ function Ul(e) {
2305
2289
  */
2306
2290
  static closeHandle() {
2307
2291
  var _;
2308
- return this.inertStore.forEach((l) => l.inert = !1), (_ = this.instance) == null || _.remove(), It(this.store, { [sn]: !1, ...e }), f;
2292
+ return this.inertStore.forEach((h) => h.inert = !1), (_ = this.instance) == null || _.remove(), this.store({ [nn]: !1, ...e }), d;
2309
2293
  }
2310
2294
  /**
2311
2295
  * 由于要操作浏览器历史记录,所以没有设计为 Promise;
@@ -2314,107 +2298,108 @@ function Ul(e) {
2314
2298
  return !0;
2315
2299
  }
2316
2300
  };
2317
- return o = gl(s), c = /* @__PURE__ */ new WeakMap(), a = /* @__PURE__ */ new WeakMap(), Kn(o, 21, "#connectHistory", n, c), Kn(o, 21, "#connectStore", t, a), h = Kn(o, 0, "ModalElement", i, h), nn(h, "inertStore", []), nn(h, "instance", null), nn(h, "store", bn({
2318
- [sn]: !1,
2301
+ return r = Ch(s), c = /* @__PURE__ */ new WeakMap(), a = /* @__PURE__ */ new WeakMap(), Kn(r, 21, "#connectHistory", n, c), Kn(r, 21, "#connectStore", t, a), f = Kn(r, 0, "ModalElement", i, f), en(f, "inertStore", []), en(f, "instance", null), en(f, "store", Wt({
2302
+ [nn]: !1,
2319
2303
  ...e
2320
- })), ge(o, 1, h), h;
2304
+ })), me(r, 1, f), f;
2321
2305
  }
2322
- var Sl = Object.create, pi = Object.defineProperty, $l = Object.getOwnPropertyDescriptor, _a = (e, t) => (t = Symbol[e]) ? t : Symbol.for("Symbol." + e), fe = (e) => {
2306
+ var Oh = Object.create, mi = Object.defineProperty, Mh = Object.getOwnPropertyDescriptor, Ea = (e, t) => (t = Symbol[e]) ? t : Symbol.for("Symbol." + e), ge = (e) => {
2323
2307
  throw TypeError(e);
2324
- }, ga = (e, t, n) => t in e ? pi(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n, ar = (e, t) => pi(e, "name", { value: t, configurable: !0 }), El = (e) => [, , , Sl((e == null ? void 0 : e[_a("metadata")]) ?? null)], ma = ["class", "method", "getter", "setter", "accessor", "field", "value", "get", "set"], Ie = (e) => e !== void 0 && typeof e != "function" ? fe("Function expected") : e, bl = (e, t, n, s, i) => ({ kind: ma[e], name: t, metadata: s, addInitializer: (o) => n._ ? fe("Already initialized") : i.push(Ie(o || null)) }), Cl = (e, t) => ga(t, _a("metadata"), e[3]), Tt = (e, t, n, s) => {
2325
- for (var i = 0, o = e[t >> 1], c = o && o.length; i < c; i++) t & 1 ? o[i].call(n) : s = o[i].call(n, s);
2308
+ }, ba = (e, t, n) => t in e ? mi(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n, pr = (e, t) => mi(e, "name", { value: t, configurable: !0 }), Lh = (e) => [, , , Oh((e == null ? void 0 : e[Ea("metadata")]) ?? null)], Ca = ["class", "method", "getter", "setter", "accessor", "field", "value", "get", "set"], Ie = (e) => e !== void 0 && typeof e != "function" ? ge("Function expected") : e, Nh = (e, t, n, s, i) => ({ kind: Ca[e], name: t, metadata: s, addInitializer: (r) => n._ ? ge("Already initialized") : i.push(Ie(r || null)) }), Ah = (e, t) => ba(t, Ea("metadata"), e[3]), Ot = (e, t, n, s) => {
2309
+ for (var i = 0, r = e[t >> 1], c = r && r.length; i < c; i++) t & 1 ? r[i].call(n) : s = r[i].call(n, s);
2326
2310
  return s;
2327
- }, In = (e, t, n, s, i, o) => {
2328
- var c, a, f, h, m, r = t & 7, _ = !!(t & 8), l = !!(t & 16), g = r > 3 ? e.length + 1 : r ? _ ? 1 : 2 : 0, v = ma[r + 5], y = r > 3 && (e[g - 1] = []), $ = e[g] || (e[g] = []), d = r && (!l && !_ && (i = i.prototype), r < 5 && (r > 3 || !l) && $l(r < 4 ? i : { get [n]() {
2329
- return et(this, o);
2330
- }, set [n](u) {
2331
- return Ge(this, o, u);
2311
+ }, Rn = (e, t, n, s, i, r) => {
2312
+ var c, a, d, f, g, o = t & 7, _ = !!(t & 8), h = !!(t & 16), m = o > 3 ? e.length + 1 : o ? _ ? 1 : 2 : 0, v = Ca[o + 5], y = o > 3 && (e[m - 1] = []), E = e[m] || (e[m] = []), u = o && (!h && !_ && (i = i.prototype), o < 5 && (o > 3 || !h) && Mh(o < 4 ? i : { get [n]() {
2313
+ return st(this, r);
2314
+ }, set [n](l) {
2315
+ return Ge(this, r, l);
2332
2316
  } }, n));
2333
- r ? l && r < 4 && ar(o, (r > 2 ? "set " : r > 1 ? "get " : "") + n) : ar(i, n);
2317
+ o ? h && o < 4 && pr(r, (o > 2 ? "set " : o > 1 ? "get " : "") + n) : pr(i, n);
2334
2318
  for (var S = s.length - 1; S >= 0; S--)
2335
- h = bl(r, n, f = {}, e[3], $), r && (h.static = _, h.private = l, m = h.access = { has: l ? (u) => Pl(i, u) : (u) => n in u }, r ^ 3 && (m.get = l ? (u) => (r ^ 1 ? et : kl)(u, i, r ^ 4 ? o : d.get) : (u) => u[n]), r > 2 && (m.set = l ? (u, k) => Ge(u, i, k, r ^ 4 ? o : d.set) : (u, k) => u[n] = k)), a = (0, s[S])(r ? r < 4 ? l ? o : d[v] : r > 4 ? void 0 : { get: d.get, set: d.set } : i, h), f._ = 1, r ^ 4 || a === void 0 ? Ie(a) && (r > 4 ? y.unshift(a) : r ? l ? o = a : d[v] = a : i = a) : typeof a != "object" || a === null ? fe("Object expected") : (Ie(c = a.get) && (d.get = c), Ie(c = a.set) && (d.set = c), Ie(c = a.init) && y.unshift(c));
2336
- return r || Cl(e, i), d && pi(i, n, d), l ? r ^ 4 ? o : d : i;
2337
- }, me = (e, t, n) => ga(e, typeof t != "symbol" ? t + "" : t, n), fi = (e, t, n) => t.has(e) || fe("Cannot " + n), Pl = (e, t) => Object(t) !== t ? fe('Cannot use the "in" operator on this value') : e.has(t), et = (e, t, n) => (fi(e, t, "read from private field"), n ? n.call(e) : t.get(e)), zt = (e, t, n) => t.has(e) ? fe("Cannot add the same private member more than once") : t instanceof WeakSet ? t.add(e) : t.set(e, n), Ge = (e, t, n, s) => (fi(e, t, "write to private field"), s ? s.call(e, n) : t.set(e, n), n), kl = (e, t, n) => (fi(e, t, "access private method"), n), va, wa, ya, ys, Sa, X, Re, He, We, Ss, ln, _i;
2319
+ f = Nh(o, n, d = {}, e[3], E), o && (f.static = _, f.private = h, g = f.access = { has: h ? (l) => Ih(i, l) : (l) => n in l }, o ^ 3 && (g.get = h ? (l) => (o ^ 1 ? st : Rh)(l, i, o ^ 4 ? r : u.get) : (l) => l[n]), o > 2 && (g.set = h ? (l, k) => Ge(l, i, k, o ^ 4 ? r : u.set) : (l, k) => l[n] = k)), a = (0, s[S])(o ? o < 4 ? h ? r : u[v] : o > 4 ? void 0 : { get: u.get, set: u.set } : i, f), d._ = 1, o ^ 4 || a === void 0 ? Ie(a) && (o > 4 ? y.unshift(a) : o ? h ? r = a : u[v] = a : i = a) : typeof a != "object" || a === null ? ge("Object expected") : (Ie(c = a.get) && (u.get = c), Ie(c = a.set) && (u.set = c), Ie(c = a.init) && y.unshift(c));
2320
+ return o || Ah(e, i), u && mi(i, n, u), h ? o ^ 4 ? r : u : i;
2321
+ }, ve = (e, t, n) => ba(e, typeof t != "symbol" ? t + "" : t, n), vi = (e, t, n) => t.has(e) || ge("Cannot " + n), Ih = (e, t) => Object(t) !== t ? ge('Cannot use the "in" operator on this value') : e.has(t), st = (e, t, n) => (vi(e, t, "read from private field"), n ? n.call(e) : t.get(e)), Dt = (e, t, n) => t.has(e) ? ge("Cannot add the same private member more than once") : t instanceof WeakSet ? t.add(e) : t.set(e, n), Ge = (e, t, n, s) => (vi(e, t, "write to private field"), s ? s.call(e, n) : t.set(e, n), n), Rh = (e, t, n) => (vi(e, t, "access private method"), n), Pa, ka, xa, Ss, Ta, tt, Re, He, We, $s, cn, wi;
2338
2322
  const jn = Symbol();
2339
- Sa = [Mn(O.store), Ln({ role: "dialog", ariaModal: "true" })];
2340
- class Be extends (ys = B, ya = [V], wa = [On], va = [Is()], ys) {
2323
+ Ta = [Mn(M.store), Ln({ role: "dialog", ariaModal: "true" })];
2324
+ class Be extends (Ss = B, xa = [V], ka = [On], Pa = [Rs()], Ss) {
2341
2325
  constructor() {
2342
- super(...arguments), me(this, "label", Tt(X, 8, this)), Tt(X, 11, this), me(this, "opened", Tt(X, 12, this)), Tt(X, 15, this), zt(this, Re), zt(this, He), zt(this, We, []), zt(this, Ss, () => {
2326
+ super(...arguments), ve(this, "label", Ot(tt, 8, this)), Ot(tt, 11, this), ve(this, "opened", Ot(tt, 12, this)), Ot(tt, 15, this), Dt(this, Re), Dt(this, He), Dt(this, We, []), Dt(this, $s, () => {
2343
2327
  var t;
2344
- this.inert = !0, et(this, We).forEach((n) => n.inert = !1), et(this, Re) ? et(this, Re).before(this) : et(this, He) && ((t = et(this, He)) == null || t.appendChild(this)), this.dispatchEvent(new CustomEvent("close")), this.opened = !1;
2345
- }), zt(this, ln, () => {
2346
- this.hidden = !1, this.inert = !1, Ge(this, Re, this.nextSibling), Ge(this, He, this.parentElement || this.getRootNode()), Ge(this, We, [...document.body.children].filter((t) => !t.inert)), et(this, We).forEach((t) => t.inert = !0), document.body.append(this), this.dispatchEvent(new CustomEvent("open")), this.opened = !0;
2347
- }), zt(this, _i, Tt(X, 16, this, () => this.inert = !0)), Tt(X, 19, this), me(this, "open", () => {
2328
+ this.inert = !0, st(this, We).forEach((n) => n.inert = !1), st(this, Re) ? st(this, Re).before(this) : st(this, He) && ((t = st(this, He)) == null || t.appendChild(this)), this.dispatchEvent(new CustomEvent("close")), this.opened = !1;
2329
+ }), Dt(this, cn, () => {
2330
+ this.hidden = !1, this.inert = !1, Ge(this, Re, this.nextSibling), Ge(this, He, this.parentElement || this.getRootNode()), Ge(this, We, [...document.body.children].filter((t) => !t.inert)), st(this, We).forEach((t) => t.inert = !0), document.body.append(this), this.dispatchEvent(new CustomEvent("open")), this.opened = !0;
2331
+ }), Dt(this, wi, Ot(tt, 16, this, () => this.inert = !0)), Ot(tt, 19, this), ve(this, "open", () => {
2348
2332
  if (!this.opened)
2349
- return et(this, ln).call(this), O.push({
2333
+ return st(this, cn).call(this), M.push({
2350
2334
  title: this.label,
2351
- open: et(this, ln),
2352
- close: et(this, Ss),
2335
+ open: st(this, cn),
2336
+ close: st(this, $s),
2353
2337
  shouldClose: this.shouldClose
2354
2338
  }), jn;
2355
- }), me(this, "close", () => (O.back(), jn)), me(this, "forceClose", () => (this.opened = !1, setTimeout(this.close, 100), jn));
2339
+ }), ve(this, "close", () => (M.back(), jn)), ve(this, "forceClose", () => (this.opened = !1, setTimeout(this.close, 100), jn));
2356
2340
  }
2357
2341
  shouldClose() {
2358
2342
  return !0;
2359
2343
  }
2360
2344
  }
2361
- X = El(ys);
2345
+ tt = Lh(Ss);
2362
2346
  Re = /* @__PURE__ */ new WeakMap();
2363
2347
  He = /* @__PURE__ */ new WeakMap();
2364
2348
  We = /* @__PURE__ */ new WeakMap();
2365
- Ss = /* @__PURE__ */ new WeakMap();
2366
- ln = /* @__PURE__ */ new WeakMap();
2367
- _i = /* @__PURE__ */ new WeakMap();
2368
- In(X, 5, "label", ya, Be);
2369
- In(X, 5, "opened", wa, Be);
2370
- In(X, 21, "#init", va, _i);
2371
- Be = In(X, 0, "GemDialogBaseElement", Sa, Be);
2372
- Tt(X, 1, Be);
2373
- class xl {
2349
+ $s = /* @__PURE__ */ new WeakMap();
2350
+ cn = /* @__PURE__ */ new WeakMap();
2351
+ wi = /* @__PURE__ */ new WeakMap();
2352
+ Rn(tt, 5, "label", xa, Be);
2353
+ Rn(tt, 5, "opened", ka, Be);
2354
+ Rn(tt, 21, "#init", Pa, wi);
2355
+ Be = Rn(tt, 0, "GemDialogBaseElement", Ta, Be);
2356
+ Ot(tt, 1, Be);
2357
+ class Hh {
2374
2358
  constructor(t) {
2375
- T(this, "_type");
2376
- T(this, "info", (...t) => {
2359
+ O(this, "_type");
2360
+ O(this, "info", (...t) => {
2377
2361
  console.log(`[${this._type}]:`, ...t);
2378
2362
  });
2379
- T(this, "warn", (...t) => {
2363
+ O(this, "warn", (...t) => {
2380
2364
  console.warn(`[${this._type}]:`, ...t);
2381
2365
  });
2382
- T(this, "error", (...t) => {
2366
+ O(this, "error", (...t) => {
2383
2367
  console.error(`[${this._type}]:`, ...t);
2384
2368
  });
2385
2369
  this._type = t;
2386
2370
  }
2387
2371
  }
2388
- const Tl = new xl("GEM"), Ol = /\$\d(?:<[^>]*>)?/, Ml = /\$(\d)(<([^>]*)>)?/g, Ll = 3;
2389
- function Nl(e, ...t) {
2390
- const n = e.split(Ol), s = [];
2372
+ const Wh = new Hh("GEM"), zh = /\$\d(?:<[^>]*>)?/, Gh = /\$(\d)(<([^>]*)>)?/g, Vh = 3;
2373
+ function Dh(e, ...t) {
2374
+ const n = e.split(zh), s = [];
2391
2375
  let i;
2392
- for (; i = Ml.exec(e); ) {
2393
- const o = i[Ll], c = Number(i[1]) - 1, a = t[c];
2394
- s.push(typeof a == "function" ? a(o) : a);
2376
+ for (; i = Gh.exec(e); ) {
2377
+ const r = i[Vh], c = Number(i[1]) - 1, a = t[c];
2378
+ s.push(typeof a == "function" ? a(r) : a);
2395
2379
  }
2396
- return at(n, ...s);
2380
+ return ht(n, ...s);
2397
2381
  }
2398
- const ve = /* @__PURE__ */ new Set();
2399
- var M, hn, $a, Ea, ze, un;
2400
- const gi = class gi {
2382
+ const we = /* @__PURE__ */ new Set();
2383
+ var N, hn, Oa, Ma, ze, ln, Xe;
2384
+ const yi = class yi {
2401
2385
  constructor(t) {
2402
- b(this, M);
2403
- T(this, "resources");
2404
- T(this, "fallbackLanguage");
2405
- T(this, "currentLanguage");
2406
- T(this, "cache");
2407
- T(this, "cachePrefix", "gem-i18n");
2408
- T(this, "urlParamsType");
2409
- T(this, "urlParamsName");
2410
- T(this, "onChange");
2386
+ b(this, N);
2387
+ O(this, "resources");
2388
+ O(this, "fallbackLanguage");
2389
+ O(this, "currentLanguage");
2390
+ O(this, "cache");
2391
+ O(this, "cachePrefix", "gem-i18n");
2392
+ O(this, "urlParamsType");
2393
+ O(this, "urlParamsName");
2394
+ O(this, "onChange");
2411
2395
  // 兼容 `<gem-route>`
2412
- T(this, "replace", ({ path: t }) => this.setLanguage(t));
2413
- T(this, "getParams", () => ({ path: this.currentLanguage }));
2396
+ O(this, "replace", ({ path: t }) => this.setLanguage(t));
2397
+ O(this, "getParams", () => ({ path: this.currentLanguage }));
2398
+ b(this, Xe, !0);
2414
2399
  if (!t.resources[t.fallbackLanguage])
2415
- throw new yt("i18n: fallbackLanguage invalid");
2400
+ throw new Lt("i18n: fallbackLanguage invalid");
2416
2401
  Object.assign(this, t);
2417
- let n = p(this, M, $a) || this.currentLanguage || p(this, M, Ea);
2402
+ let n = p(this, N, Oa) || this.currentLanguage || p(this, N, Ma);
2418
2403
  const s = document.querySelector(`[type*=${this.cachePrefix}]`);
2419
2404
  if (s)
2420
2405
  try {
@@ -2422,73 +2407,74 @@ const gi = class gi {
2422
2407
  n = i.currentLanguage, this.resources[i.currentLanguage] = i.currentLanguagePack;
2423
2408
  } catch {
2424
2409
  }
2425
- n ? (x(this, M, n, un), this.setLanguage(n)) : this.resetLanguage();
2410
+ n ? (x(this, N, n, ln), this.setLanguage(n)) : this.resetLanguage(), x(this, Xe, !1);
2426
2411
  }
2427
2412
  get(t, ...n) {
2428
- const s = this.resources[this.currentLanguage], i = this.resources[this.fallbackLanguage], o = s[t] || i[t], c = (o == null ? void 0 : o.message) || o || `[${t}]`;
2429
- return n.length ? Nl(c, ...n) : c;
2413
+ const s = this.resources[this.currentLanguage], i = this.resources[this.fallbackLanguage], r = s[t] || i[t], c = (r == null ? void 0 : r.message) || r || `[${t}]`;
2414
+ return n.length ? Dh(c, ...n) : c;
2430
2415
  }
2431
2416
  detectLanguage() {
2432
2417
  const t = Object.keys(this.resources), n = navigator.languages.map((s) => s.replace(/-(.*)/, (i) => i.toUpperCase()));
2433
2418
  for (const s of n) {
2434
- const i = t.find((o) => o === s || s.startsWith(`${o}-`));
2419
+ const i = t.find((r) => r === s || s.startsWith(`${r}-`));
2435
2420
  if (i) return i;
2436
2421
  }
2437
2422
  return this.fallbackLanguage;
2438
2423
  }
2439
2424
  async setLanguage(t) {
2440
- var o, c;
2441
- p(this, M, ze) && ve.forEach(async (a) => await a.setLanguage(t));
2425
+ var i, r;
2426
+ p(this, N, ze) && we.forEach(async (c) => await c.setLanguage(t));
2442
2427
  let n;
2443
2428
  const s = this.resources[t];
2444
2429
  if (!s)
2445
- return Tl.warn(`${this.cachePrefix}: not found \`${t}\``), this.resetLanguage();
2430
+ return Wh.warn(`${this.cachePrefix}: not found \`${t}\``), this.resetLanguage();
2446
2431
  if (typeof s == "string") {
2447
- const a = `${this.cachePrefix}:`, f = `${a}${s}`, h = localStorage.getItem(f), m = async () => {
2448
- const r = await (await fetch(s)).json();
2432
+ const c = `${this.cachePrefix}:`, a = `${c}${s}`, d = localStorage.getItem(a), f = async () => {
2433
+ const g = await (await fetch(s)).json();
2449
2434
  if (this.cache) {
2450
- for (let _ = 0; _ < localStorage.length; _++) {
2451
- const l = localStorage.key(_);
2452
- l.startsWith(a) && localStorage.removeItem(l);
2435
+ for (let o = 0; o < localStorage.length; o++) {
2436
+ const _ = localStorage.key(o);
2437
+ _.startsWith(c) && localStorage.removeItem(_);
2453
2438
  }
2454
- localStorage.setItem(f, JSON.stringify(r));
2439
+ localStorage.setItem(a, JSON.stringify(g));
2455
2440
  }
2456
- return r;
2441
+ return g;
2457
2442
  };
2458
- if (h)
2443
+ if (d)
2459
2444
  try {
2460
- n = JSON.parse(h);
2445
+ n = JSON.parse(d);
2461
2446
  } catch {
2462
- n = await m();
2447
+ n = await f();
2463
2448
  }
2464
2449
  else
2465
- n = await m();
2450
+ n = await f();
2466
2451
  } else
2467
2452
  n = s;
2468
- this.resources[t] = n;
2469
- const i = [document.documentElement];
2470
- for (; i.length; ) {
2471
- const a = i.pop();
2472
- (o = a[Cn]) == null || o.call(a), (c = a.shadowRoot) != null && c.firstElementChild && i.push(a.shadowRoot.firstElementChild), a.firstElementChild && i.push(a.firstElementChild), a.nextElementSibling && i.push(a.nextElementSibling);
2453
+ if (this.resources[t] = n, !p(this, Xe)) {
2454
+ const c = [document.documentElement];
2455
+ for (; c.length; ) {
2456
+ const a = c.pop();
2457
+ (i = a[Cn]) == null || i.call(a), c.push(...[...a.children, ...((r = a.shadowRoot) == null ? void 0 : r.children) || []].reverse());
2458
+ }
2473
2459
  }
2474
- return t !== this.currentLanguage && x(this, M, t, un), this.cache === !0 && this.setCache(), t;
2460
+ return t !== this.currentLanguage && x(this, N, t, ln), this.cache === !0 && this.setCache(), t;
2475
2461
  }
2476
2462
  resetLanguage() {
2477
- return p(this, M, ze) && ve.forEach((t) => t.resetLanguage()), x(this, M, this.fallbackLanguage, un), this.cache && localStorage.removeItem(p(this, M, hn)), this.setLanguage(this.detectLanguage());
2463
+ return p(this, N, ze) && we.forEach((t) => t.resetLanguage()), x(this, N, this.fallbackLanguage, ln), this.cache && localStorage.removeItem(p(this, N, hn)), this.setLanguage(this.detectLanguage());
2478
2464
  }
2479
2465
  // 一般用在 `onChange` 中
2480
2466
  setCache() {
2481
- p(this, M, ze) && ve.forEach((t) => t.setCache()), localStorage.setItem(p(this, M, hn), this.currentLanguage);
2467
+ p(this, N, ze) && we.forEach((t) => t.setCache()), localStorage.setItem(p(this, N, hn), this.currentLanguage);
2482
2468
  }
2483
2469
  createSubModule(t, n) {
2484
- const s = new gi({
2470
+ const s = new yi({
2485
2471
  resources: n,
2486
2472
  cachePrefix: `${this.cachePrefix}-${t}`,
2487
2473
  currentLanguage: this.currentLanguage,
2488
2474
  fallbackLanguage: this.fallbackLanguage,
2489
2475
  cache: this.cache
2490
2476
  });
2491
- return ve.add(s), s;
2477
+ return we.add(s), s;
2492
2478
  }
2493
2479
  /**
2494
2480
  * @example
@@ -2506,9 +2492,9 @@ const gi = class gi {
2506
2492
  };
2507
2493
  }
2508
2494
  };
2509
- M = new WeakSet(), hn = function() {
2495
+ N = new WeakSet(), hn = function() {
2510
2496
  return `${this.cachePrefix}:current`;
2511
- }, $a = function() {
2497
+ }, Oa = function() {
2512
2498
  const { hostname: t, pathname: n, search: s } = location, i = t.split(".");
2513
2499
  switch (this.urlParamsType) {
2514
2500
  case "ccTLD":
@@ -2518,19 +2504,19 @@ M = new WeakSet(), hn = function() {
2518
2504
  case "path":
2519
2505
  return n.split("/")[1];
2520
2506
  default:
2521
- const o = this.urlParamsName && new URLSearchParams(s).get(this.urlParamsName) || "";
2522
- return o in this.resources ? o : "";
2507
+ const r = this.urlParamsName && new URLSearchParams(s).get(this.urlParamsName) || "";
2508
+ return r in this.resources ? r : "";
2523
2509
  }
2524
- }, Ea = function() {
2525
- return this.cache && localStorage.getItem(p(this, M, hn)) || "";
2510
+ }, Ma = function() {
2511
+ return this.cache && localStorage.getItem(p(this, N, hn)) || "";
2526
2512
  }, ze = function() {
2527
- return !ve.has(this);
2528
- }, un = function(t) {
2513
+ return !we.has(this);
2514
+ }, ln = function(t) {
2529
2515
  var n;
2530
- p(this, M, ze) && (document.documentElement.lang = t), this.currentLanguage = t, (n = this.onChange) == null || n.call(this, t);
2531
- };
2532
- let cr = gi;
2533
- const K = (e) => window.matchMedia(e).matches, Bl = {
2516
+ p(this, N, ze) && (document.documentElement.lang = t), this.currentLanguage = t, (n = this.onChange) == null || n.call(this, t);
2517
+ }, Xe = new WeakMap();
2518
+ let fr = yi;
2519
+ const K = (e) => window.matchMedia(e).matches, el = {
2534
2520
  PRINT: "print",
2535
2521
  get isPrint() {
2536
2522
  return K(this.PRINT);
@@ -2590,229 +2576,227 @@ const K = (e) => window.matchMedia(e).matches, Bl = {
2590
2576
  get isWidthScreen() {
2591
2577
  return K(this.WIDTHSCREEN);
2592
2578
  }
2593
- }, Al = Object.getPrototypeOf(Object.getPrototypeOf(new Int8Array())).constructor;
2594
- function Il(e = {}) {
2579
+ }, Fh = Object.getPrototypeOf(Object.getPrototypeOf(new Int8Array())).constructor;
2580
+ function qh(e = {}) {
2595
2581
  const {
2596
2582
  origin: t = location.origin,
2597
2583
  base: n = "",
2598
2584
  appendHeaders: s = () => ({}),
2599
- transformInput: i = (r) => r,
2600
- transformOutput: o = (r) => r,
2585
+ transformInput: i = (o) => o,
2586
+ transformOutput: r = (o) => o,
2601
2587
  ...c
2602
- } = e, a = (r) => r instanceof FormData || r instanceof Blob || r instanceof Al || r instanceof URLSearchParams || r instanceof ReadableStream || r instanceof ArrayBuffer ? r : typeof r == "object" ? JSON.stringify(r) : r, f = (r, _) => {
2603
- if (new URL(r, location.origin).pathname !== r)
2604
- throw new yt("`path` format is incorrect");
2605
- const l = new URLSearchParams(_).toString();
2606
- return `${t}${n}${r}${l ? "?" : ""}${l}`;
2607
- }, h = (r) => {
2608
- if (!r) return {};
2609
- if (r instanceof Headers) return Object.fromEntries(r);
2610
- const _ = Array.isArray(r) ? r : Object.entries(r);
2611
- return Object.fromEntries(_.map(([l, g]) => [l.toLowerCase(), g]));
2612
- }, m = async (r, _ = {}) => {
2613
- const l = new Request(r, {
2588
+ } = e, a = (o) => o instanceof FormData || o instanceof Blob || o instanceof Fh || o instanceof URLSearchParams || o instanceof ReadableStream || o instanceof ArrayBuffer ? o : typeof o == "object" ? JSON.stringify(o) : o, d = (o, _) => {
2589
+ if (new URL(o, location.origin).pathname !== o)
2590
+ throw new Lt("`path` format is incorrect");
2591
+ const h = new URLSearchParams(_).toString();
2592
+ return `${t}${n}${o}${h ? "?" : ""}${h}`;
2593
+ }, f = (o) => {
2594
+ if (!o) return {};
2595
+ if (o instanceof Headers) return Object.fromEntries(o);
2596
+ const _ = Array.isArray(o) ? o : Object.entries(o);
2597
+ return Object.fromEntries(_.map(([h, m]) => [h.toLowerCase(), m]));
2598
+ }, g = async (o, _ = {}) => {
2599
+ const h = new Request(o, {
2614
2600
  ...c,
2615
2601
  ..._,
2616
2602
  headers: new Headers({
2617
2603
  "content-type": "application/json",
2618
- ...h(c.headers),
2619
- ...h(_.headers)
2604
+ ...f(c.headers),
2605
+ ...f(_.headers)
2620
2606
  })
2621
- }), g = await fetch(l);
2622
- if (g.status === 0) throw new Error("Request fail");
2623
- if (g.status >= 500) throw new Error(g.statusText);
2624
- const v = l.headers.get("content-type"), y = g.status >= 400;
2607
+ }), m = await fetch(h);
2608
+ if (m.status === 0) throw new Error("Request fail");
2609
+ if (m.status >= 500) throw new Error(m.statusText);
2610
+ const v = h.headers.get("content-type"), y = m.status >= 400;
2625
2611
  try {
2626
- let $;
2627
- if (v.includes("json") ? $ = await g.json() : v.includes("octet-stream") ? $ = await g.arrayBuffer() : $ = await g.text(), y) throw new Error(g.statusText, { cause: $ });
2628
- return o($, l);
2612
+ let E;
2613
+ if (v.includes("json") ? E = await m.json() : v.includes("octet-stream") ? E = await m.arrayBuffer() : E = await m.text(), y) throw new Error(m.statusText, { cause: E });
2614
+ return r(E, h);
2629
2615
  } catch {
2630
2616
  throw new Error("Parse error");
2631
2617
  }
2632
2618
  };
2633
2619
  return {
2634
- request: m,
2635
- get(r, _) {
2636
- const l = i(_);
2637
- return m(f(r, l), {
2620
+ request: g,
2621
+ get(o, _) {
2622
+ const h = i(_);
2623
+ return g(d(o, h), {
2638
2624
  method: "GET",
2639
- headers: s(l)
2625
+ headers: s(h)
2640
2626
  });
2641
2627
  },
2642
- del(r, _) {
2643
- const l = i(_);
2644
- return m(f(r, l), {
2628
+ del(o, _) {
2629
+ const h = i(_);
2630
+ return g(d(o, h), {
2645
2631
  method: "DELETE",
2646
- headers: s(l)
2632
+ headers: s(h)
2647
2633
  });
2648
2634
  },
2649
- put(r, _) {
2650
- const l = i(_);
2651
- return m(f(r), {
2635
+ put(o, _) {
2636
+ const h = i(_);
2637
+ return g(d(o), {
2652
2638
  method: "PUT",
2653
- headers: s(l),
2654
- body: a(l)
2639
+ headers: s(h),
2640
+ body: a(h)
2655
2641
  });
2656
2642
  },
2657
- post(r, _) {
2658
- const l = i(_);
2659
- return m(f(r), {
2643
+ post(o, _) {
2644
+ const h = i(_);
2645
+ return g(d(o), {
2660
2646
  method: "POST",
2661
- headers: s(l),
2662
- body: a(l)
2647
+ headers: s(h),
2648
+ body: a(h)
2663
2649
  });
2664
2650
  }
2665
2651
  };
2666
2652
  }
2667
- const { request: Kl, del: jl, get: Jl, post: Yl, put: Ql } = Il(), ba = /* @__PURE__ */ new WeakMap(), Ca = /* @__PURE__ */ new WeakMap();
2668
- function Xl(e) {
2669
- return ba.get(e);
2653
+ const { request: nl, del: sl, get: il, post: rl, put: ol } = qh(), La = /* @__PURE__ */ new WeakMap(), Na = /* @__PURE__ */ new WeakMap();
2654
+ function al(e) {
2655
+ return La.get(e);
2670
2656
  }
2671
- function Pa(e) {
2672
- return Ca.get(e);
2657
+ function Aa(e) {
2658
+ return Na.get(e);
2673
2659
  }
2674
2660
  function fn(e, t = {}) {
2675
- const n = En(), s = Pn({})[Rt], [i, o] = Xe(e), c = new Proxy(
2676
- { [Rt]: s },
2661
+ const n = bn(), s = Pn({})[Ht], i = Wt(e), r = new Proxy(
2662
+ En({ [Ht]: s }, (a) => i(a)),
2677
2663
  {
2678
- get(f, h) {
2679
- if (!f[h]) {
2680
- const [m, r, _] = h.match(/^(\w*Color)(\d+)$/) || [];
2681
- r && (f[h] = `oklch(from ${f[r]} calc(l - ${(Number(_) - 400) / 1e3}) c h)`);
2664
+ get(a, d) {
2665
+ if (!a[d]) {
2666
+ const [f, g, o] = d.match(/^(\w*Color)(\d+)$/) || [];
2667
+ g && (a[d] = `oklch(from ${a[g]} calc(l - ${(Number(o) - 400) / 1e3}) c h)`);
2682
2668
  }
2683
- return f[h];
2669
+ return a[d];
2684
2670
  }
2685
2671
  }
2686
2672
  );
2687
- Ca.set(c, t), ba.set(c, i);
2688
- const a = () => {
2689
- let f = "";
2690
- Object.keys(i).forEach((h) => {
2691
- t[h] || (t[h] = `--${oe(h)}-${n}`, c[h] = `var(${t[h]})`), f += `${t[h]}:${i[h]};`;
2692
- }), s.setContent(`:scope,:host{${f}}`);
2673
+ Na.set(r, t), La.set(r, i);
2674
+ const c = () => {
2675
+ let a = "";
2676
+ Object.keys(i).forEach((d) => {
2677
+ t[d] || (t[d] = `--${oe(d)}-${n}`, r[d] = `var(${t[d]})`), a += `${t[d]}:${i[d]};`;
2678
+ }), s.setContent(`:scope,:host{${a}}`);
2693
2679
  };
2694
- return a(), ft(i, () => {
2695
- a(), s.updateStyle();
2696
- }), [c, o];
2680
+ return c(), ft(i, () => {
2681
+ c(), s.updateStyle();
2682
+ }), r;
2697
2683
  }
2698
- function Rl(e) {
2684
+ function Uh(e) {
2699
2685
  return fn(e);
2700
2686
  }
2701
- function Zl(e) {
2702
- const t = Rl(e);
2703
- return document.adoptedStyleSheets.push(t[0][Rt].getStyle()), t;
2687
+ function cl(e) {
2688
+ const t = Uh(e);
2689
+ return document.adoptedStyleSheets.push(t[Ht].getStyle()), t;
2704
2690
  }
2705
- function th(e, t) {
2706
- return fn(t, Pa(e));
2691
+ function hl(e, t) {
2692
+ return fn(t, Aa(e));
2707
2693
  }
2708
- function eh(e) {
2709
- const [t] = fn(e), n = Pa(t);
2710
- return [t, (i) => (o, { addInitializer: c, access: a }) => {
2694
+ function ll(e) {
2695
+ const t = fn(e), n = Aa(t);
2696
+ return En(t, (i) => (r, { addInitializer: c, access: a }) => {
2711
2697
  c(function() {
2712
- const [f, h] = fn({ ...e }, n);
2713
- this.internals.sheets.push(f[Rt].getStyle(this)), this.memo(() => h(a.get(this).apply(this)), i && (() => i(this)));
2698
+ const d = fn({ ...e }, n);
2699
+ this.internals.sheets.push(d[Ht].getStyle(this)), this.memo(() => d(a.get(this).apply(this)), i && (() => i(this)));
2714
2700
  });
2715
- }];
2701
+ });
2716
2702
  }
2717
2703
  export {
2718
2704
  se as GemActiveLinkElement,
2719
2705
  Be as GemDialogBaseElement,
2720
2706
  B as GemElement,
2721
- yt as GemError,
2722
- N as GemLightRouteElement,
2723
- H as GemLinkElement,
2724
- An as GemReflectElement,
2707
+ Lt as GemError,
2708
+ R as GemLightRouteElement,
2709
+ W as GemLinkElement,
2710
+ In as GemReflectElement,
2725
2711
  Ue as GemRouteElement,
2726
- xe as GemTitleElement,
2712
+ Te as GemTitleElement,
2727
2713
  ie as GemUnsafeElement,
2728
- Ct as GemUseElement,
2729
- cr as I18n,
2730
- Va as LinkedList,
2731
- xl as Logger,
2732
- Da as PropProxyMap,
2714
+ bt as GemUseElement,
2715
+ fr as I18n,
2716
+ tc as LinkedList,
2717
+ Hh as Logger,
2718
+ ec as PropProxyMap,
2733
2719
  De as QueryString,
2734
- Os as RenderErrorEvent,
2735
- dr as SVGTemplateResult,
2736
- Rt as SheetToken,
2737
- ne as StoreListenerMap,
2720
+ vr as SVGTemplateResult,
2721
+ Ht as SheetToken,
2722
+ un as StoreListenerMap,
2738
2723
  $n as TemplateResult,
2739
2724
  Cn as UpdateToken,
2740
- gr as absoluteLocation,
2741
- mr as addListener,
2742
- Ot as addMicrotask,
2743
- Rs as adoptedStyle,
2725
+ Ms as _RenderErrorEvent,
2726
+ Ns as _createTemplate,
2727
+ $r as absoluteLocation,
2728
+ Er as addListener,
2729
+ Mt as addMicrotask,
2730
+ Hs as adoptedStyle,
2744
2731
  Ln as aria,
2745
- dc as async,
2732
+ Ec as async,
2746
2733
  V as attribute,
2747
- wc as basePathStore,
2734
+ xc as basePathStore,
2748
2735
  Tn as boolattribute,
2749
2736
  oe as camelToKebabCase,
2750
- qa as classMap,
2751
- ks as cleanObject,
2737
+ sc as classMap,
2738
+ xs as cleanObject,
2752
2739
  ft as connect,
2753
2740
  Mn as connectStore,
2754
2741
  Pn as createCSSSheet,
2755
- xc as createHistoryParams,
2756
- Ul as createModalClass,
2757
- Bs as createPath,
2758
- Sr as createRef,
2759
- Ms as createState,
2760
- bn as createStore,
2761
- Ls as createTemplate,
2762
- vr as css,
2763
- pc as customElement,
2764
- jl as del,
2742
+ ll as createDecoratorTheme,
2743
+ Hc as createHistoryParams,
2744
+ tl as createModalClass,
2745
+ hl as createOverrideTheme,
2746
+ Ks as createPath,
2747
+ kr as createRef,
2748
+ Uh as createScopedTheme,
2749
+ Ls as createState,
2750
+ Wt as createStore,
2751
+ cl as createTheme,
2752
+ En as createUpdater,
2753
+ br as css,
2754
+ bc as customElement,
2755
+ sl as del,
2765
2756
  Sn as directive,
2766
- Ua as disconnect,
2767
- $t as effect,
2768
- ye as emitter,
2769
- Dl as exportPartsMap,
2770
- cc as fallback,
2771
- Jl as get,
2772
- Pa as getThemeProps,
2773
- Xl as getThemeStore,
2774
- uc as globalemitter,
2775
- ql as guard,
2776
- O as history,
2777
- at as html,
2778
- yc as ifDefined,
2779
- Il as initRequest,
2780
- Fa as isArrayChange,
2781
- zl as kebabToCamelCase,
2782
- Mr as light,
2783
- Tl as logger,
2784
- oo as matchPath,
2785
- Bl as mediaQuery,
2786
- Pr as memo,
2757
+ St as effect,
2758
+ Se as emitter,
2759
+ Qh as exportPartsMap,
2760
+ wc as fallback,
2761
+ il as get,
2762
+ Aa as getThemeProps,
2763
+ al as getThemeStore,
2764
+ $c as globalemitter,
2765
+ Zh as guard,
2766
+ M as history,
2767
+ ht as html,
2768
+ Tc as ifDefined,
2769
+ qh as initRequest,
2770
+ nc as isArrayChange,
2771
+ jh as kebabToCamelCase,
2772
+ Rr as light,
2773
+ Wh as logger,
2774
+ lo as matchPath,
2775
+ el as mediaQuery,
2776
+ Lr as memo,
2787
2777
  qe as mounted,
2788
- oc as numattribute,
2789
- xs as objectMapToString,
2790
- Tr as part,
2791
- Vl as partMap,
2792
- Yl as post,
2778
+ mc as numattribute,
2779
+ Ts as objectMapToString,
2780
+ Ar as part,
2781
+ Yh as partMap,
2782
+ rl as post,
2793
2783
  U as property,
2794
- Ql as put,
2795
- En as randomStr,
2796
- Ps as raw,
2797
- Cs as render,
2798
- Fl as repeat,
2799
- Kl as request,
2800
- Ht as shadow,
2801
- hc as slot,
2802
- Nl as splice,
2784
+ ol as put,
2785
+ bn as randomStr,
2786
+ ks as raw,
2787
+ Ps as render,
2788
+ Xh as repeat,
2789
+ nl as request,
2790
+ zt as shadow,
2791
+ Sc as slot,
2792
+ Dh as splice,
2803
2793
  On as state,
2804
- Gl as styleMap,
2805
- Wl as styled,
2806
- Ga as svg,
2807
- kr as template,
2808
- At as titleStore,
2809
- ac as unmounted,
2810
- It as updateStore,
2811
- eh as useDecoratorTheme,
2812
- th as useOverrideTheme,
2813
- Rl as useScopedTheme,
2814
- Xe as useStore,
2815
- Zl as useTheme,
2816
- ec as version,
2817
- Is as willMount
2794
+ Jh as styleMap,
2795
+ Kh as styled,
2796
+ ja as svg,
2797
+ ae as template,
2798
+ Rt as titleStore,
2799
+ vc as unmounted,
2800
+ dc as version,
2801
+ Rs as willMount
2818
2802
  };