@jasonshimmy/custom-elements-runtime 2.2.7 → 2.2.9

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.
@@ -1,47 +1,47 @@
1
- import { g as U, t as J, i as P, s as Re, a as H, b as F, d as D, f as q, T as gt, h as Ze, S as bt, j as at, k as Xe, l as Ce, m as Qe, n as Et } from "./namespace-helpers-Vwt2Fzds.js";
1
+ import { g as U, t as J, i as M, s as Re, a as H, b as F, d as D, f as q, T as gt, h as Ze, S as bt, j as at, k as Xe, l as Ce, m as Qe, n as Et } from "./namespace-helpers-Vwt2Fzds.js";
2
2
  import { c as En, r as Sn, u as vn, w as _n } from "./namespace-helpers-Vwt2Fzds.js";
3
3
  import { d as W, a as Q } from "./logger-BpibrmKL.js";
4
- import { j as St, g as vt, a as je, b as pe, m as ke, s as _t, c as et } from "./transitions-CZ21fzhh.js";
4
+ import { j as St, g as vt, a as $e, b as pe, m as ke, s as _t, c as et } from "./transitions-CZ21fzhh.js";
5
5
  import { d as kn } from "./transitions-CZ21fzhh.js";
6
6
  function Ct(e, n, t) {
7
7
  if (t)
8
8
  for (const [s, r] of Object.entries(t)) {
9
- let i, o = {};
10
- if (Array.isArray(r) ? (i = r[0], o = r[1] || {}) : i = r, n.set(s, {
11
- callback: i,
12
- options: o,
9
+ let o, i = {};
10
+ if (Array.isArray(r) ? (o = r[0], i = r[1] || {}) : o = r, n.set(s, {
11
+ callback: o,
12
+ options: i,
13
13
  oldValue: U(e, s)
14
- }), o.immediate)
14
+ }), i.immediate)
15
15
  try {
16
16
  const c = U(e, s);
17
- i(c, void 0, e);
17
+ o(c, void 0, e);
18
18
  } catch (c) {
19
19
  W(`Error in immediate watcher for "${s}":`, c);
20
20
  }
21
21
  }
22
22
  }
23
23
  function kt(e, n, t, s) {
24
- const r = (o, c) => {
25
- if (o === c) return !0;
26
- if (typeof o != typeof c || typeof o != "object" || o === null || c === null) return !1;
27
- if (Array.isArray(o) && Array.isArray(c))
28
- return o.length !== c.length ? !1 : o.every((g, w) => r(g, c[w]));
29
- const f = o, u = c, S = Object.keys(f || {}), E = Object.keys(u || {});
30
- return S.length !== E.length ? !1 : S.every((g) => r(f[g], u[g]));
31
- }, i = n.get(t);
32
- if (i && !r(s, i.oldValue))
24
+ const r = (i, c) => {
25
+ if (i === c) return !0;
26
+ if (typeof i != typeof c || typeof i != "object" || i === null || c === null) return !1;
27
+ if (Array.isArray(i) && Array.isArray(c))
28
+ return i.length !== c.length ? !1 : i.every((m, C) => r(m, c[C]));
29
+ const f = i, u = c, S = Object.keys(f || {}), b = Object.keys(u || {});
30
+ return S.length !== b.length ? !1 : S.every((m) => r(f[m], u[m]));
31
+ }, o = n.get(t);
32
+ if (o && !r(s, o.oldValue))
33
33
  try {
34
- i.callback(s, i.oldValue, e), i.oldValue = s;
35
- } catch (o) {
36
- W(`Error in watcher for "${t}":`, o);
34
+ o.callback(s, o.oldValue, e), o.oldValue = s;
35
+ } catch (i) {
36
+ W(`Error in watcher for "${t}":`, i);
37
37
  }
38
- for (const [o, c] of n.entries())
39
- if (c.options.deep && t.startsWith(o + "."))
38
+ for (const [i, c] of n.entries())
39
+ if (c.options.deep && t.startsWith(i + "."))
40
40
  try {
41
- const f = U(e, o);
41
+ const f = U(e, i);
42
42
  r(f, c.oldValue) || (c.callback(f, c.oldValue, e), c.oldValue = f);
43
43
  } catch (f) {
44
- W(`Error in deep watcher for "${o}":`, f);
44
+ W(`Error in deep watcher for "${i}":`, f);
45
45
  }
46
46
  }
47
47
  function De(e, n) {
@@ -50,11 +50,11 @@ function De(e, n) {
50
50
  function At(e, n, t) {
51
51
  if (n)
52
52
  for (const s in n) {
53
- const r = n[s], i = J(s), o = e.getAttribute(i);
53
+ const r = n[s], o = J(s), i = e.getAttribute(o);
54
54
  if (r.type === Function && typeof e[s] == "function")
55
55
  t[s] = e[s];
56
- else if (o !== null)
57
- t[s] = De(o, r.type);
56
+ else if (i !== null)
57
+ t[s] = De(i, r.type);
58
58
  else if (typeof e[s] < "u")
59
59
  try {
60
60
  const c = e[s];
@@ -80,27 +80,27 @@ function wt(e, n, t) {
80
80
  ...Object.keys(s || {})
81
81
  ])
82
82
  );
83
- for (const i of r) {
84
- if (typeof i != "string" || i.startsWith("_")) continue;
85
- const o = Object.getOwnPropertyDescriptor(t, i);
83
+ for (const o of r) {
84
+ if (typeof o != "string" || o.startsWith("_")) continue;
85
+ const i = Object.getOwnPropertyDescriptor(t, o);
86
86
  if (!(!Object.prototype.hasOwnProperty.call(
87
87
  s,
88
- i
89
- ) && o && (o.get || o.set || !o.configurable)))
88
+ o
89
+ ) && i && (i.get || i.set || !i.configurable)))
90
90
  try {
91
- Object.defineProperty(t, i, {
91
+ Object.defineProperty(t, o, {
92
92
  enumerable: !0,
93
93
  configurable: !0,
94
94
  get() {
95
95
  try {
96
- const f = J(i), u = e.getAttribute(f);
96
+ const f = J(o), u = e.getAttribute(f);
97
97
  if (u !== null)
98
98
  return u;
99
- const S = e[i];
100
- let E;
101
- return P(S) || S && typeof S == "object" && "value" in S && !(S instanceof Node) ? E = S.value : E = S, E;
99
+ const S = e[o];
100
+ let b;
101
+ return M(S) || S && typeof S == "object" && "value" in S && !(S instanceof Node) ? b = S.value : b = S, b;
102
102
  } catch {
103
- return e[i];
103
+ return e[o];
104
104
  }
105
105
  }
106
106
  });
@@ -116,8 +116,8 @@ function wt(e, n, t) {
116
116
  function Tt(e, n, t, s) {
117
117
  e.onConnected && !t && (e.onConnected(n), s(!0));
118
118
  }
119
- function Lt(e, n, t, s, r, i, o, c) {
120
- e.onDisconnected && e.onDisconnected(n), t.forEach((f) => f()), s(), r(), i(!1), o(null), c(!1);
119
+ function Lt(e, n, t, s, r, o, i, c) {
120
+ e.onDisconnected && e.onDisconnected(n), t.forEach((f) => f()), s(), r(), o(!1), i(null), c(!1);
121
121
  }
122
122
  function Nt(e, n, t, s, r) {
123
123
  e.onAttributeChanged && e.onAttributeChanged(n, t, s, r);
@@ -158,8 +158,8 @@ class Ot {
158
158
  }
159
159
  const r = this.createEvaluator(n);
160
160
  if (this.cache.size >= this.maxCacheSize) {
161
- const i = this.cache.keys().next().value;
162
- i && this.cache.delete(i);
161
+ const o = this.cache.keys().next().value;
162
+ o && this.cache.delete(o);
163
163
  }
164
164
  if (this.cache.set(n, r), !r.isSecure) {
165
165
  Q("Blocked dangerous expression:", n);
@@ -197,26 +197,26 @@ class Ot {
197
197
  static createObjectEvaluator(n) {
198
198
  const t = n.trim().slice(1, -1), s = this.parseObjectProperties(t);
199
199
  return (r) => {
200
- const i = {};
201
- for (const { key: o, value: c } of s)
200
+ const o = {};
201
+ for (const { key: i, value: c } of s)
202
202
  try {
203
203
  if (c.startsWith("ctx.")) {
204
204
  const f = c.slice(4);
205
- i[o] = U(r, f);
205
+ o[i] = U(r, f);
206
206
  } else
207
- i[o] = this.evaluateSimpleValue(c, r);
207
+ o[i] = this.evaluateSimpleValue(c, r);
208
208
  } catch {
209
- i[o] = void 0;
209
+ o[i] = void 0;
210
210
  }
211
- return i;
211
+ return o;
212
212
  };
213
213
  }
214
214
  static parseObjectProperties(n) {
215
215
  const t = [], s = n.split(",");
216
216
  for (const r of s) {
217
- const i = r.indexOf(":");
218
- if (i === -1) continue;
219
- const o = r.slice(0, i).trim(), c = r.slice(i + 1).trim(), f = o.replace(/^['"]|['"]$/g, "");
217
+ const o = r.indexOf(":");
218
+ if (o === -1) continue;
219
+ const i = r.slice(0, o).trim(), c = r.slice(o + 1).trim(), f = i.replace(/^['"]|['"]$/g, "");
220
220
  t.push({ key: f, value: c });
221
221
  }
222
222
  return t;
@@ -228,53 +228,53 @@ class Ot {
228
228
  const r = [];
229
229
  s = s.replace(
230
230
  /("[^"\\]*(?:\\.[^"\\]*)*"|'[^'\\]*(?:\\.[^'\\]*)*')/g,
231
- (E) => `<<#${r.push(E) - 1}#>>`
231
+ (b) => `<<#${r.push(b) - 1}#>>`
232
232
  );
233
- const i = s.match(/ctx\.[\w.]+/g) || [];
234
- for (const E of i) {
235
- const g = E.slice(4), w = U(t, g);
236
- if (w === void 0) return;
237
- const p = r.push(JSON.stringify(w)) - 1;
233
+ const o = s.match(/ctx\.[\w.]+/g) || [];
234
+ for (const b of o) {
235
+ const m = b.slice(4), C = U(t, m);
236
+ if (C === void 0) return;
237
+ const w = r.push(JSON.stringify(C)) - 1;
238
238
  s = s.replace(
239
- new RegExp(E.replace(/[.*+?^${}()|[\]\\]/g, "\\$&"), "g"),
240
- `<<#${p}#>>`
239
+ new RegExp(b.replace(/[.*+?^${}()|[\]\\]/g, "\\$&"), "g"),
240
+ `<<#${w}#>>`
241
241
  );
242
242
  }
243
- const o = /\b[a-zA-Z_][a-zA-Z0-9_]*(?:\.[a-zA-Z_][a-zA-Z0-9_]*)+\b/g, c = s.match(o) || [];
244
- for (const E of c) {
245
- if (E.startsWith("ctx.")) continue;
246
- const g = U(t, E);
247
- if (g === void 0) return;
248
- const w = r.push(JSON.stringify(g)) - 1;
243
+ const i = /\b[a-zA-Z_][a-zA-Z0-9_]*(?:\.[a-zA-Z_][a-zA-Z0-9_]*)+\b/g, c = s.match(i) || [];
244
+ for (const b of c) {
245
+ if (b.startsWith("ctx.")) continue;
246
+ const m = U(t, b);
247
+ if (m === void 0) return;
248
+ const C = r.push(JSON.stringify(m)) - 1;
249
249
  s = s.replace(
250
- new RegExp(E.replace(/[.*+?^${}()|[\]\\]/g, "\\$&"), "g"),
251
- `<<#${w}#>>`
250
+ new RegExp(b.replace(/[.*+?^${}()|[\]\\]/g, "\\$&"), "g"),
251
+ `<<#${C}#>>`
252
252
  );
253
253
  }
254
254
  const f = /\b([a-zA-Z_][a-zA-Z0-9_]*)\b/g;
255
255
  let u;
256
256
  const S = /* @__PURE__ */ new Set();
257
257
  for (; (u = f.exec(s)) !== null; ) {
258
- const E = u[1];
259
- if (["true", "false", "null", "undefined"].includes(E) || /^[0-9]+$/.test(E) || E === "ctx" || S.has(E)) continue;
260
- S.add(E);
261
- const g = U(t, E);
262
- if (g === void 0) return;
263
- const w = JSON.stringify(g), p = r.push(w) - 1;
264
- E.includes(".") ? s = s.replace(
265
- new RegExp(E.replace(/[.*+?^${}()|[\]\\]/g, "\\$&"), "g"),
266
- `<<#${p}#>>`
258
+ const b = u[1];
259
+ if (["true", "false", "null", "undefined"].includes(b) || /^[0-9]+$/.test(b) || b === "ctx" || S.has(b)) continue;
260
+ S.add(b);
261
+ const m = U(t, b);
262
+ if (m === void 0) return;
263
+ const C = JSON.stringify(m), w = r.push(C) - 1;
264
+ b.includes(".") ? s = s.replace(
265
+ new RegExp(b.replace(/[.*+?^${}()|[\]\\]/g, "\\$&"), "g"),
266
+ `<<#${w}#>>`
267
267
  ) : s = s.replace(
268
268
  new RegExp(
269
- "\\b" + E.replace(/[.*+?^${}()|[\]\\]/g, "\\$&") + "\\b",
269
+ "\\b" + b.replace(/[.*+?^${}()|[\]\\]/g, "\\$&") + "\\b",
270
270
  "g"
271
271
  ),
272
- `<<#${p}#>>`
272
+ `<<#${w}#>>`
273
273
  );
274
274
  }
275
275
  s = s.replace(
276
276
  /<<#(\d+)#>>/g,
277
- (E, g) => r[Number(g)]
277
+ (b, m) => r[Number(m)]
278
278
  );
279
279
  try {
280
280
  return this.evaluateBasicExpression(s);
@@ -297,44 +297,44 @@ class Ot {
297
297
  function r() {
298
298
  return t[s];
299
299
  }
300
- function i(y) {
300
+ function o(d) {
301
301
  const k = t[s++];
302
- if (y && !k)
303
- throw new Error(`Unexpected token EOF, expected ${y}`);
304
- if (y && k && k.type !== y && k.value !== y)
302
+ if (d && !k)
303
+ throw new Error(`Unexpected token EOF, expected ${d}`);
304
+ if (d && k && k.type !== d && k.value !== d)
305
305
  throw new Error(
306
- `Unexpected token ${k.type}/${k.value}, expected ${y}`
306
+ `Unexpected token ${k.type}/${k.value}, expected ${d}`
307
307
  );
308
308
  return k;
309
309
  }
310
- function o() {
311
- return p();
310
+ function i() {
311
+ return w();
312
312
  }
313
- function c(y) {
314
- if (typeof y == "number") return y;
315
- if (y == null) return NaN;
316
- if (typeof y == "boolean") return y ? 1 : 0;
317
- const k = Number(y);
313
+ function c(d) {
314
+ if (typeof d == "number") return d;
315
+ if (d == null) return NaN;
316
+ if (typeof d == "boolean") return d ? 1 : 0;
317
+ const k = Number(d);
318
318
  return Number.isNaN(k) ? NaN : k;
319
319
  }
320
- function f(y, k) {
321
- return typeof y == "string" || typeof k == "string" ? String(y) + String(k) : c(y) + c(k);
320
+ function f(d, k) {
321
+ return typeof d == "string" || typeof k == "string" ? String(d) + String(k) : c(d) + c(k);
322
322
  }
323
- function u(y, k) {
324
- return c(y) - c(k);
323
+ function u(d, k) {
324
+ return c(d) - c(k);
325
325
  }
326
- function S(y, k) {
327
- return c(y) * c(k);
326
+ function S(d, k) {
327
+ return c(d) * c(k);
328
328
  }
329
- function E(y, k) {
330
- return c(y) / c(k);
329
+ function b(d, k) {
330
+ return c(d) / c(k);
331
331
  }
332
- function g(y, k) {
333
- return c(y) % c(k);
332
+ function m(d, k) {
333
+ return c(d) % c(k);
334
334
  }
335
- function w(y, k, l) {
335
+ function C(d, k, l) {
336
336
  if (typeof k == "number" && typeof l == "number")
337
- switch (y) {
337
+ switch (d) {
338
338
  case ">":
339
339
  return k > l;
340
340
  case "<":
@@ -346,178 +346,178 @@ class Ot {
346
346
  default:
347
347
  return !1;
348
348
  }
349
- const m = String(k), A = String(l);
350
- switch (y) {
349
+ const g = String(k), A = String(l);
350
+ switch (d) {
351
351
  case ">":
352
- return m > A;
352
+ return g > A;
353
353
  case "<":
354
- return m < A;
354
+ return g < A;
355
355
  case ">=":
356
- return m >= A;
356
+ return g >= A;
357
357
  case "<=":
358
- return m <= A;
358
+ return g <= A;
359
359
  default:
360
360
  return !1;
361
361
  }
362
362
  }
363
- function p() {
364
- const y = v(), k = r();
363
+ function w() {
364
+ const d = L(), k = r();
365
365
  if (k && k.value === "?") {
366
- i("?");
367
- const l = o();
368
- i(":");
369
- const m = o();
370
- return y ? l : m;
366
+ o("?");
367
+ const l = i();
368
+ o(":");
369
+ const g = i();
370
+ return d ? l : g;
371
371
  }
372
- return y;
372
+ return d;
373
373
  }
374
- function v() {
375
- let y = a();
374
+ function L() {
375
+ let d = a();
376
376
  for (; ; ) {
377
377
  const k = r();
378
378
  if (!k || k.value !== "||") break;
379
- i("OP");
379
+ o("OP");
380
380
  const l = a();
381
- y = y || l;
381
+ d = d || l;
382
382
  }
383
- return y;
383
+ return d;
384
384
  }
385
385
  function a() {
386
- let y = C();
386
+ let d = v();
387
387
  for (; ; ) {
388
388
  const k = r();
389
389
  if (!k || k.value !== "&&") break;
390
- i("OP");
391
- const l = C();
392
- y = y && l;
390
+ o("OP");
391
+ const l = v();
392
+ d = d && l;
393
393
  }
394
- return y;
394
+ return d;
395
395
  }
396
- function C() {
397
- let y = b();
396
+ function v() {
397
+ let d = h();
398
398
  for (; ; ) {
399
399
  const k = r();
400
400
  if (!k || !["==", "!=", "===", "!=="].includes(k.value)) break;
401
- const l = i("OP").value, m = b();
401
+ const l = o("OP").value, g = h();
402
402
  switch (l) {
403
403
  case "==":
404
- y = y == m;
404
+ d = d == g;
405
405
  break;
406
406
  case "!=":
407
- y = y != m;
407
+ d = d != g;
408
408
  break;
409
409
  case "===":
410
- y = y === m;
410
+ d = d === g;
411
411
  break;
412
412
  case "!==":
413
- y = y !== m;
413
+ d = d !== g;
414
414
  break;
415
415
  }
416
416
  }
417
- return y;
417
+ return d;
418
418
  }
419
- function b() {
420
- let y = h();
419
+ function h() {
420
+ let d = y();
421
421
  for (; ; ) {
422
422
  const k = r();
423
423
  if (!k || ![">", "<", ">=", "<="].includes(k.value)) break;
424
- const l = i("OP").value, m = h();
424
+ const l = o("OP").value, g = y();
425
425
  switch (l) {
426
426
  case ">":
427
- y = w(">", y, m);
427
+ d = C(">", d, g);
428
428
  break;
429
429
  case "<":
430
- y = w("<", y, m);
430
+ d = C("<", d, g);
431
431
  break;
432
432
  case ">=":
433
- y = w(">=", y, m);
433
+ d = C(">=", d, g);
434
434
  break;
435
435
  case "<=":
436
- y = w("<=", y, m);
436
+ d = C("<=", d, g);
437
437
  break;
438
438
  }
439
439
  }
440
- return y;
440
+ return d;
441
441
  }
442
- function h() {
443
- let y = d();
442
+ function y() {
443
+ let d = p();
444
444
  for (; ; ) {
445
445
  const k = r();
446
446
  if (!k || k.value !== "+" && k.value !== "-") break;
447
- const l = i("OP").value, m = d();
448
- y = l === "+" ? f(y, m) : u(y, m);
447
+ const l = o("OP").value, g = p();
448
+ d = l === "+" ? f(d, g) : u(d, g);
449
449
  }
450
- return y;
450
+ return d;
451
451
  }
452
- function d() {
453
- let y = _();
452
+ function p() {
453
+ let d = _();
454
454
  for (; ; ) {
455
455
  const k = r();
456
456
  if (!k || k.value !== "*" && k.value !== "/" && k.value !== "%")
457
457
  break;
458
- const l = i("OP").value, m = _();
458
+ const l = o("OP").value, g = _();
459
459
  switch (l) {
460
460
  case "*":
461
- y = S(y, m);
461
+ d = S(d, g);
462
462
  break;
463
463
  case "/":
464
- y = E(y, m);
464
+ d = b(d, g);
465
465
  break;
466
466
  case "%":
467
- y = g(y, m);
467
+ d = m(d, g);
468
468
  break;
469
469
  }
470
470
  }
471
- return y;
471
+ return d;
472
472
  }
473
473
  function _() {
474
- const y = r();
475
- if (y && y.value === "!")
476
- return i("OP"), !_();
477
- if (y && y.value === "-") {
478
- i("OP");
474
+ const d = r();
475
+ if (d && d.value === "!")
476
+ return o("OP"), !_();
477
+ if (d && d.value === "-") {
478
+ o("OP");
479
479
  const k = _();
480
480
  return u(0, k);
481
481
  }
482
- return T();
483
- }
484
- function T() {
485
- const y = r();
486
- if (y) {
487
- if (y.type === "NUMBER")
488
- return i("NUMBER"), Number(y.value);
489
- if (y.type === "STRING")
490
- return i("STRING"), y.value.slice(1, -1);
491
- if (y.type === "IDENT")
492
- return i("IDENT"), y.value === "true" ? !0 : y.value === "false" ? !1 : y.value === "null" ? null : void 0;
493
- if (y.value === "[") {
494
- i("PUNC");
482
+ return E();
483
+ }
484
+ function E() {
485
+ const d = r();
486
+ if (d) {
487
+ if (d.type === "NUMBER")
488
+ return o("NUMBER"), Number(d.value);
489
+ if (d.type === "STRING")
490
+ return o("STRING"), d.value.slice(1, -1);
491
+ if (d.type === "IDENT")
492
+ return o("IDENT"), d.value === "true" ? !0 : d.value === "false" ? !1 : d.value === "null" ? null : void 0;
493
+ if (d.value === "[") {
494
+ o("PUNC");
495
495
  const k = [];
496
496
  for (; ; ) {
497
497
  const l = r();
498
498
  if (!l || l.value === "]") break;
499
- k.push(o());
500
- const m = r();
501
- m && m.value === "," && i("PUNC");
499
+ k.push(i());
500
+ const g = r();
501
+ g && g.value === "," && o("PUNC");
502
502
  }
503
- return i("PUNC"), k;
503
+ return o("PUNC"), k;
504
504
  }
505
- if (y.value === "(") {
506
- i("PUNC");
507
- const k = o();
508
- return i("PUNC"), k;
505
+ if (d.value === "(") {
506
+ o("PUNC");
507
+ const k = i();
508
+ return o("PUNC"), k;
509
509
  }
510
510
  throw new Error("Unexpected token in expression");
511
511
  }
512
512
  }
513
- return o();
513
+ return i();
514
514
  }
515
515
  static tokenize(n) {
516
516
  const t = [], s = /\s*(=>|===|!==|==|!=|>=|<=|\|\||&&|[()?:,[\]]|\+|-|\*|\/|%|>|<|!|\d+\.?\d*|"(?:[^"\\]|\\.)*"|'(?:[^'\\]|\\.)*'|[a-zA-Z_][a-zA-Z0-9_]*|\S)\s*/g;
517
517
  let r;
518
518
  for (; (r = s.exec(n)) !== null; ) {
519
- const i = r[1];
520
- i && (/^\d/.test(i) ? t.push({ type: "NUMBER", value: i }) : /^"/.test(i) || /^'/.test(i) ? t.push({ type: "STRING", value: i }) : /^[a-zA-Z_]/.test(i) ? t.push({ type: "IDENT", value: i }) : /^[()?:,[\]]$/.test(i) ? t.push({ type: "PUNC", value: i }) : t.push({ type: "OP", value: i }));
519
+ const o = r[1];
520
+ o && (/^\d/.test(o) ? t.push({ type: "NUMBER", value: o }) : /^"/.test(o) || /^'/.test(o) ? t.push({ type: "STRING", value: o }) : /^[a-zA-Z_]/.test(o) ? t.push({ type: "IDENT", value: o }) : /^[()?:,[\]]$/.test(o) ? t.push({ type: "PUNC", value: o }) : t.push({ type: "OP", value: o }));
521
521
  }
522
522
  return t;
523
523
  }
@@ -545,7 +545,7 @@ class te {
545
545
  */
546
546
  static addListener(n, t, s, r) {
547
547
  n.addEventListener(t, s, r);
548
- const o = {
548
+ const i = {
549
549
  event: t,
550
550
  handler: s,
551
551
  wrapper: s,
@@ -555,19 +555,19 @@ class te {
555
555
  };
556
556
  this.cleanupFunctions.has(n) || this.cleanupFunctions.set(n, []);
557
557
  const c = this.cleanupFunctions.get(n);
558
- c.push(o), c.__metaList = c;
558
+ c.push(i), c.__metaList = c;
559
559
  }
560
560
  /**
561
561
  * Remove a specific event listener
562
562
  */
563
563
  static removeListener(n, t, s, r) {
564
564
  n.removeEventListener(t, s, r);
565
- const i = this.cleanupFunctions.get(n);
566
- if (i)
567
- for (let o = 0; o < i.length; o++) {
568
- const c = i[o];
565
+ const o = this.cleanupFunctions.get(n);
566
+ if (o)
567
+ for (let i = 0; i < o.length; i++) {
568
+ const c = o[i];
569
569
  if (c.event === t && c.handler === s) {
570
- i.splice(o, 1), i.length === 0 && this.cleanupFunctions.delete(n);
570
+ o.splice(i, 1), o.length === 0 && this.cleanupFunctions.delete(n);
571
571
  return;
572
572
  }
573
573
  }
@@ -622,15 +622,15 @@ function He(e, n) {
622
622
  }
623
623
  function tt(e, n, t, s, r) {
624
624
  if (e) {
625
- const i = n.value;
626
- if (r && typeof i == "object" && i !== null) {
627
- const o = { ...i };
628
- o[r] = t, n.value = o;
625
+ const o = n.value;
626
+ if (r && typeof o == "object" && o !== null) {
627
+ const i = { ...o };
628
+ i[r] = t, n.value = i;
629
629
  } else
630
630
  n.value = t;
631
631
  } else {
632
- const i = s._state || s;
633
- Re(i, n, t);
632
+ const o = s._state || s;
633
+ Re(o, n, t);
634
634
  }
635
635
  }
636
636
  function xe(e, n, t, s) {
@@ -639,17 +639,17 @@ function xe(e, n, t, s) {
639
639
  e._triggerWatchers(r, s);
640
640
  }
641
641
  }
642
- function Mt(e, n, t) {
643
- const s = `update:${J(n)}`, r = `update:${n}`, i = new CustomEvent(s, {
642
+ function Pt(e, n, t) {
643
+ const s = `update:${J(n)}`, r = `update:${n}`, o = new CustomEvent(s, {
644
644
  detail: t,
645
645
  bubbles: !0,
646
646
  cancelable: !0
647
- }), o = new CustomEvent(r, {
647
+ }), i = new CustomEvent(r, {
648
648
  detail: t,
649
649
  bubbles: !0,
650
650
  cancelable: !0
651
651
  });
652
- e.dispatchEvent(i), e.dispatchEvent(o);
652
+ e.dispatchEvent(o), e.dispatchEvent(i);
653
653
  }
654
654
  function nt(e, n, t, s) {
655
655
  const r = t;
@@ -662,19 +662,19 @@ function nt(e, n, t, s) {
662
662
  else
663
663
  e[n] = r;
664
664
  }), r == null || typeof r == "string" || typeof r == "number" || typeof r == "boolean") {
665
- const i = F(r);
666
- i !== null ? H(() => {
665
+ const o = F(r);
666
+ o !== null ? H(() => {
667
667
  typeof e.setAttribute == "function" && D(
668
668
  e,
669
669
  J(n),
670
- String(i)
670
+ String(o)
671
671
  );
672
672
  }) : H(() => {
673
673
  typeof e.removeAttribute == "function" && q(e, J(n));
674
674
  });
675
675
  }
676
676
  }
677
- function $t(e, n, t, s) {
677
+ function jt(e, n, t, s) {
678
678
  if (e) {
679
679
  const r = n.value;
680
680
  return s && typeof r == "object" && r !== null ? r[s] : r;
@@ -699,15 +699,15 @@ function de(e, n) {
699
699
  t.length > 0 && e.classList.remove(...t);
700
700
  }
701
701
  let We = !1;
702
- async function Pt(e, n, t = 10) {
702
+ async function Mt(e, n, t = 10) {
703
703
  if (!We) {
704
704
  if (!e.isConnected) {
705
705
  Q("⚠️ Element not connected to DOM, skipping style wait");
706
706
  return;
707
707
  }
708
708
  for (let s = 0; s < t; s++) {
709
- const r = window.getComputedStyle(e), i = r.transform && r.transform !== "", o = r.opacity && r.opacity !== "";
710
- if (i || o) {
709
+ const r = window.getComputedStyle(e), o = r.transform && r.transform !== "", i = r.opacity && r.opacity !== "";
710
+ if (o || i) {
711
711
  We = !0;
712
712
  return;
713
713
  }
@@ -718,129 +718,129 @@ async function Pt(e, n, t = 10) {
718
718
  We = !0, Q("⚠️ Styles did not load in time for transition, continuing anyway");
719
719
  }
720
720
  }
721
- function jt(e) {
722
- const n = window.getComputedStyle(e), t = n.transitionDuration || "0s", s = n.transitionDelay || "0s", r = (i) => {
723
- const o = parseFloat(i);
724
- return i.includes("ms") ? o : o * 1e3;
721
+ function $t(e) {
722
+ const n = window.getComputedStyle(e), t = n.transitionDuration || "0s", s = n.transitionDelay || "0s", r = (o) => {
723
+ const i = parseFloat(o);
724
+ return o.includes("ms") ? i : i * 1e3;
725
725
  };
726
726
  return r(t) + r(s);
727
727
  }
728
728
  function lt(e, n) {
729
729
  return new Promise((t) => {
730
- const s = n ?? jt(e);
730
+ const s = n ?? $t(e);
731
731
  if (s <= 0) {
732
732
  t();
733
733
  return;
734
734
  }
735
735
  let r = !1;
736
- const i = () => {
737
- r || (r = !0, e.removeEventListener("transitionend", o), e.removeEventListener("transitioncancel", o), t());
738
- }, o = () => i();
739
- e.addEventListener("transitionend", o), e.addEventListener("transitioncancel", o), setTimeout(i, s + 50);
736
+ const o = () => {
737
+ r || (r = !0, e.removeEventListener("transitionend", i), e.removeEventListener("transitioncancel", i), t());
738
+ }, i = () => o();
739
+ e.addEventListener("transitionend", i), e.addEventListener("transitioncancel", i), setTimeout(o, s + 50);
740
740
  });
741
741
  }
742
742
  async function Ae(e, n) {
743
- const { classes: t, hooks: s, css: r, duration: i } = n;
743
+ const { classes: t, hooks: s, css: r, duration: o } = n;
744
744
  if (s?.onBeforeEnter)
745
745
  try {
746
746
  s.onBeforeEnter(e);
747
- } catch (p) {
748
- W("Transition onBeforeEnter error:", p);
747
+ } catch (w) {
748
+ W("Transition onBeforeEnter error:", w);
749
749
  }
750
750
  if (!r)
751
- return s?.onEnter ? new Promise((p) => {
752
- const v = s.onEnter;
753
- typeof v == "function" ? v(e, () => {
751
+ return s?.onEnter ? new Promise((w) => {
752
+ const L = s.onEnter;
753
+ typeof L == "function" ? L(e, () => {
754
754
  if (s?.onAfterEnter)
755
755
  try {
756
756
  s.onAfterEnter(e);
757
757
  } catch (a) {
758
758
  W("Transition onAfterEnter error:", a);
759
759
  }
760
- p();
761
- }) : p();
760
+ w();
761
+ }) : w();
762
762
  }) : void 0;
763
- const o = he(t?.enterFrom), c = he(t?.enterActive), f = he(t?.enterTo);
764
- ye(e, o), e.offsetHeight, ye(e, c), e.offsetHeight;
763
+ const i = he(t?.enterFrom), c = he(t?.enterActive), f = he(t?.enterTo);
764
+ ye(e, i), e.offsetHeight, ye(e, c), e.offsetHeight;
765
765
  let u;
766
766
  if (s?.onEnter) {
767
- const p = new Promise((v) => {
768
- u = v;
767
+ const w = new Promise((L) => {
768
+ u = L;
769
769
  });
770
770
  try {
771
- const v = s.onEnter;
772
- typeof v == "function" && v(e, () => {
771
+ const L = s.onEnter;
772
+ typeof L == "function" && L(e, () => {
773
773
  u && u();
774
774
  });
775
- } catch (v) {
776
- W("Transition onEnter error:", v);
775
+ } catch (L) {
776
+ W("Transition onEnter error:", L);
777
777
  }
778
- u && await p;
778
+ u && await w;
779
779
  }
780
780
  await new Promise(
781
- (p) => requestAnimationFrame(() => p(void 0))
781
+ (w) => requestAnimationFrame(() => w(void 0))
782
782
  ), e.offsetHeight;
783
- const S = window.getComputedStyle(e), E = S.transform, g = S.opacity;
784
- de(e, o), E && E !== "none" && (e.style.transform = E), g && g !== "" && (e.style.opacity = g), e.offsetHeight, await new Promise(
785
- (p) => requestAnimationFrame(() => p(void 0))
783
+ const S = window.getComputedStyle(e), b = S.transform, m = S.opacity;
784
+ de(e, i), b && b !== "none" && (e.style.transform = b), m && m !== "" && (e.style.opacity = m), e.offsetHeight, await new Promise(
785
+ (w) => requestAnimationFrame(() => w(void 0))
786
786
  ), e.style.transform = "", e.style.opacity = "", ye(e, f), e.offsetHeight, await new Promise(
787
- (p) => requestAnimationFrame(() => p(void 0))
787
+ (w) => requestAnimationFrame(() => w(void 0))
788
788
  );
789
- let w;
790
- if (typeof i == "number" ? w = i : i && typeof i == "object" && "enter" in i && (w = i.enter), await lt(e, w), de(e, c), s?.onAfterEnter)
789
+ let C;
790
+ if (typeof o == "number" ? C = o : o && typeof o == "object" && "enter" in o && (C = o.enter), await lt(e, C), de(e, c), s?.onAfterEnter)
791
791
  try {
792
792
  s.onAfterEnter(e);
793
- } catch (p) {
794
- W("Transition onAfterEnter error:", p);
793
+ } catch (w) {
794
+ W("Transition onAfterEnter error:", w);
795
795
  }
796
796
  }
797
797
  async function ze(e, n) {
798
- const { classes: t, hooks: s, css: r, duration: i } = n;
798
+ const { classes: t, hooks: s, css: r, duration: o } = n;
799
799
  if (s?.onBeforeLeave)
800
800
  try {
801
801
  s.onBeforeLeave(e);
802
- } catch (E) {
803
- W("Transition onBeforeLeave error:", E);
802
+ } catch (b) {
803
+ W("Transition onBeforeLeave error:", b);
804
804
  }
805
805
  if (!r)
806
- return s?.onLeave ? new Promise((E) => {
807
- const g = s.onLeave;
808
- typeof g == "function" ? g(e, () => {
806
+ return s?.onLeave ? new Promise((b) => {
807
+ const m = s.onLeave;
808
+ typeof m == "function" ? m(e, () => {
809
809
  if (s?.onAfterLeave)
810
810
  try {
811
811
  s.onAfterLeave(e);
812
- } catch (w) {
813
- W("Transition onAfterLeave error:", w);
812
+ } catch (C) {
813
+ W("Transition onAfterLeave error:", C);
814
814
  }
815
- E();
816
- }) : E();
815
+ b();
816
+ }) : b();
817
817
  }) : void 0;
818
- const o = he(t?.leaveFrom), c = he(t?.leaveActive), f = he(t?.leaveTo);
819
- ye(e, o), e.offsetHeight, ye(e, c);
818
+ const i = he(t?.leaveFrom), c = he(t?.leaveActive), f = he(t?.leaveTo);
819
+ ye(e, i), e.offsetHeight, ye(e, c);
820
820
  let u;
821
821
  if (s?.onLeave) {
822
- const E = new Promise((g) => {
823
- u = g;
822
+ const b = new Promise((m) => {
823
+ u = m;
824
824
  });
825
825
  try {
826
- const g = s.onLeave;
827
- typeof g == "function" && g(e, () => {
826
+ const m = s.onLeave;
827
+ typeof m == "function" && m(e, () => {
828
828
  u && u();
829
829
  });
830
- } catch (g) {
831
- W("Transition onLeave error:", g);
830
+ } catch (m) {
831
+ W("Transition onLeave error:", m);
832
832
  }
833
- u && await E;
833
+ u && await b;
834
834
  }
835
835
  await new Promise(
836
- (E) => requestAnimationFrame(() => E(void 0))
837
- ), await Pt(e, [...o, ...c]), de(e, o), ye(e, f);
836
+ (b) => requestAnimationFrame(() => b(void 0))
837
+ ), await Mt(e, [...i, ...c]), de(e, i), ye(e, f);
838
838
  let S;
839
- if (typeof i == "number" ? S = i : i && typeof i == "object" && "leave" in i && (S = i.leave), await lt(e, S), de(e, c), de(e, f), de(e, o), s?.onAfterLeave)
839
+ if (typeof o == "number" ? S = o : o && typeof o == "object" && "leave" in o && (S = o.leave), await lt(e, S), de(e, c), de(e, f), de(e, i), s?.onAfterLeave)
840
840
  try {
841
841
  s.onAfterLeave(e);
842
- } catch (E) {
843
- W("Transition onAfterLeave error:", E);
842
+ } catch (b) {
843
+ W("Transition onAfterLeave error:", b);
844
844
  }
845
845
  }
846
846
  const ft = /* @__PURE__ */ new WeakMap(), ut = /* @__PURE__ */ new WeakMap();
@@ -901,7 +901,7 @@ function me(e) {
901
901
  }
902
902
  function Fe(e) {
903
903
  try {
904
- if (P(e)) return e.value;
904
+ if (M(e)) return e.value;
905
905
  } catch {
906
906
  }
907
907
  try {
@@ -920,7 +920,7 @@ function X(e) {
920
920
  return e instanceof HTMLInputElement || e instanceof HTMLSelectElement || e instanceof HTMLTextAreaElement || e instanceof HTMLButtonElement;
921
921
  }
922
922
  function ge(e) {
923
- return e === "" ? !0 : typeof e == "string" ? e === "false" ? !1 : e === "true" ? !0 : e !== "" : e && typeof e == "object" ? P(e) || "value" in e ? !!e.value : !1 : !!e;
923
+ return e === "" ? !0 : typeof e == "string" ? e === "false" ? !1 : e === "true" ? !0 : e !== "" : e && typeof e == "object" ? M(e) || "value" in e ? !!e.value : !1 : !!e;
924
924
  }
925
925
  function ue(e, n) {
926
926
  if (!n || !(e instanceof Element)) return;
@@ -936,218 +936,218 @@ function we(e, n, t) {
936
936
  const s = e.props?.reactiveRef ?? (e.props?.props && e.props.props.reactiveRef), r = e.props?.ref ?? (e.props?.props && e.props.props.ref);
937
937
  if (s)
938
938
  try {
939
- if (P(s) || typeof s == "object" && "value" in s)
939
+ if (M(s) || typeof s == "object" && "value" in s)
940
940
  s.value = n;
941
941
  else if (typeof s == "function")
942
942
  s(n);
943
943
  else if (typeof s == "string" && t)
944
944
  try {
945
- const i = String(s);
946
- t[i] = n;
945
+ const o = String(s);
946
+ t[o] = n;
947
947
  } catch {
948
948
  }
949
949
  } catch {
950
950
  }
951
951
  else if (r && t)
952
952
  try {
953
- const i = String(r);
954
- t[i] = n;
953
+ const o = String(r);
954
+ t[o] = n;
955
955
  } catch {
956
956
  }
957
957
  }
958
- function It(e, n, t, s, r, i, o, c) {
959
- if (!i) return;
960
- const f = n.includes("lazy"), u = n.includes("trim"), S = n.includes("number"), E = () => {
961
- if (P(e)) {
962
- const d = e.value;
963
- return c && o && (o instanceof HTMLInputElement || o instanceof HTMLTextAreaElement || o instanceof HTMLSelectElement) && typeof d == "object" && d !== null ? d[c] : d;
964
- }
965
- const h = i?._state || i;
966
- return U(h, e);
967
- }, g = E();
968
- let w = "text";
969
- o instanceof HTMLInputElement ? w = s?.type || o.type || "text" : o instanceof HTMLSelectElement ? w = "select" : o instanceof HTMLTextAreaElement && (w = "textarea");
970
- const p = o instanceof HTMLInputElement || o instanceof HTMLTextAreaElement || o instanceof HTMLSelectElement, a = p ? w === "checkbox" || w === "radio" ? "checked" : "value" : c ?? "modelValue";
971
- if (w === "checkbox")
972
- if (Array.isArray(g))
973
- t[a] = g.includes(
974
- String(o?.getAttribute("value") ?? s?.value ?? "")
958
+ function It(e, n, t, s, r, o, i, c) {
959
+ if (!o) return;
960
+ const f = n.includes("lazy"), u = n.includes("trim"), S = n.includes("number"), b = () => {
961
+ if (M(e)) {
962
+ const p = e.value;
963
+ return c && i && (i instanceof HTMLInputElement || i instanceof HTMLTextAreaElement || i instanceof HTMLSelectElement) && typeof p == "object" && p !== null ? p[c] : p;
964
+ }
965
+ const y = o?._state || o;
966
+ return U(y, e);
967
+ }, m = b();
968
+ let C = "text";
969
+ i instanceof HTMLInputElement ? C = s?.type || i.type || "text" : i instanceof HTMLSelectElement ? C = "select" : i instanceof HTMLTextAreaElement && (C = "textarea");
970
+ const w = i instanceof HTMLInputElement || i instanceof HTMLTextAreaElement || i instanceof HTMLSelectElement, a = w ? C === "checkbox" || C === "radio" ? "checked" : "value" : c ?? "modelValue";
971
+ if (C === "checkbox")
972
+ if (Array.isArray(m))
973
+ t[a] = m.includes(
974
+ String(i?.getAttribute("value") ?? s?.value ?? "")
975
975
  );
976
976
  else {
977
- const h = o?.getAttribute("true-value") ?? !0;
978
- t[a] = g === h;
979
- }
980
- else if (w === "radio")
981
- t[a] = g === (s?.value ?? "");
982
- else if (w === "select")
983
- if (o && o.hasAttribute("multiple") && o instanceof HTMLSelectElement) {
984
- const h = Array.isArray(g) ? g.map(String) : [];
977
+ const y = i?.getAttribute("true-value") ?? !0;
978
+ t[a] = m === y;
979
+ }
980
+ else if (C === "radio")
981
+ t[a] = m === (s?.value ?? "");
982
+ else if (C === "select")
983
+ if (i && i.hasAttribute("multiple") && i instanceof HTMLSelectElement) {
984
+ const y = Array.isArray(m) ? m.map(String) : [];
985
985
  setTimeout(() => {
986
- Array.from(o.options).forEach((d) => {
987
- d.selected = h.includes(d.value);
986
+ Array.from(i.options).forEach((p) => {
987
+ p.selected = y.includes(p.value);
988
988
  });
989
- }, 0), t[a] = Array.isArray(g) ? g : [];
989
+ }, 0), t[a] = Array.isArray(m) ? m : [];
990
990
  } else
991
- t[a] = g;
991
+ t[a] = m;
992
992
  else {
993
- !p && P(e) ? t[a] = e : t[a] = g;
993
+ !w && M(e) ? t[a] = e : t[a] = m;
994
994
  try {
995
- const h = J(a);
996
- s && (s[h] = g);
995
+ const y = J(a);
996
+ s && (s[y] = m);
997
997
  } catch {
998
998
  }
999
999
  }
1000
- const C = f || w === "checkbox" || w === "radio" || w === "select" ? "change" : "input", b = (h) => {
1001
- if (h.isComposing || r._isComposing)
1000
+ const v = f || C === "checkbox" || C === "radio" || C === "select" ? "change" : "input", h = (y) => {
1001
+ if (y.isComposing || r._isComposing)
1002
1002
  return;
1003
- const d = globalThis.process, _ = !!d && d.env?.NODE_ENV === "test" || typeof window < "u" && globalThis.__vitest__;
1004
- if (h.isTrusted === !1 && !_)
1003
+ const p = globalThis.process, _ = !!p && p.env?.NODE_ENV === "test" || typeof window < "u" && globalThis.__vitest__;
1004
+ if (y.isTrusted === !1 && !_)
1005
1005
  return;
1006
- const T = h.target;
1007
- if (!T || T._modelUpdating)
1006
+ const E = y.target;
1007
+ if (!E || E._modelUpdating)
1008
1008
  return;
1009
- let L = T.value;
1010
- if (w === "checkbox") {
1011
- const l = E();
1009
+ let T = E.value;
1010
+ if (C === "checkbox") {
1011
+ const l = b();
1012
1012
  if (Array.isArray(l)) {
1013
- const m = T.getAttribute("value") ?? "", A = Array.from(l);
1014
- if (T.checked)
1015
- A.includes(m) || A.push(m);
1013
+ const g = E.getAttribute("value") ?? "", A = Array.from(l);
1014
+ if (E.checked)
1015
+ A.includes(g) || A.push(g);
1016
1016
  else {
1017
- const N = A.indexOf(m);
1017
+ const N = A.indexOf(g);
1018
1018
  N > -1 && A.splice(N, 1);
1019
1019
  }
1020
- L = A;
1020
+ T = A;
1021
1021
  } else {
1022
- const m = T.getAttribute("true-value") ?? !0, A = T.getAttribute("false-value") ?? !1;
1023
- L = T.checked ? m : A;
1022
+ const g = E.getAttribute("true-value") ?? !0, A = E.getAttribute("false-value") ?? !1;
1023
+ T = E.checked ? g : A;
1024
1024
  }
1025
- } else if (w === "radio")
1026
- L = T.getAttribute("value") ?? T.value;
1027
- else if (w === "select" && T.multiple)
1028
- L = Array.from(T.selectedOptions).map(
1025
+ } else if (C === "radio")
1026
+ T = E.getAttribute("value") ?? E.value;
1027
+ else if (C === "select" && E.multiple)
1028
+ T = Array.from(E.selectedOptions).map(
1029
1029
  (l) => l.value
1030
1030
  );
1031
- else if (u && typeof L == "string" && (L = L.trim()), S) {
1032
- const l = Number(L);
1033
- isNaN(l) || (L = l);
1031
+ else if (u && typeof T == "string" && (T = T.trim()), S) {
1032
+ const l = Number(T);
1033
+ isNaN(l) || (T = l);
1034
1034
  }
1035
- const y = E();
1036
- if (He(L, y)) {
1037
- T._modelUpdating = !0;
1035
+ const d = b();
1036
+ if (He(T, d)) {
1037
+ E._modelUpdating = !0;
1038
1038
  try {
1039
- tt(P(e), e, L, i, c), xe(i, P(e), e, L), T && Mt(T, a, L);
1039
+ tt(M(e), e, T, o, c), xe(o, M(e), e, T), E && Pt(E, a, T);
1040
1040
  } finally {
1041
1041
  setTimeout(
1042
- () => T._modelUpdating = !1,
1042
+ () => E._modelUpdating = !1,
1043
1043
  0
1044
1044
  );
1045
1045
  }
1046
1046
  }
1047
1047
  };
1048
- if (p) {
1049
- if (r[C]) {
1050
- const h = r[C];
1051
- o && te.removeListener(o, C, h);
1048
+ if (w) {
1049
+ if (r[v]) {
1050
+ const y = r[v];
1051
+ i && te.removeListener(i, v, y);
1052
1052
  }
1053
- r[C] = b;
1053
+ r[v] = h;
1054
1054
  } else {
1055
- const h = `update:${J(a)}`, d = `update:${a}`;
1056
- if (r[h]) {
1057
- const _ = r[h];
1058
- o && te.removeListener(o, h, _);
1059
- }
1060
- if (r[d]) {
1061
- const _ = r[d];
1062
- o && te.removeListener(o, d, _);
1063
- }
1064
- if (r[h] = (_) => {
1065
- const T = _.detail;
1066
- let L = T !== void 0 ? T : void 0;
1067
- if (L === void 0) {
1055
+ const y = `update:${J(a)}`, p = `update:${a}`;
1056
+ if (r[y]) {
1057
+ const _ = r[y];
1058
+ i && te.removeListener(i, y, _);
1059
+ }
1060
+ if (r[p]) {
1061
+ const _ = r[p];
1062
+ i && te.removeListener(i, p, _);
1063
+ }
1064
+ if (r[y] = (_) => {
1065
+ const E = _.detail;
1066
+ let T = E !== void 0 ? E : void 0;
1067
+ if (T === void 0) {
1068
1068
  const l = _.target;
1069
1069
  if (l && typeof l == "object" && "value" in l)
1070
1070
  try {
1071
- L = l.value;
1071
+ T = l.value;
1072
1072
  } catch {
1073
- L = void 0;
1073
+ T = void 0;
1074
1074
  }
1075
1075
  }
1076
- const y = $t(
1077
- P(e),
1076
+ const d = jt(
1077
+ M(e),
1078
1078
  e,
1079
- i,
1079
+ o,
1080
1080
  c
1081
1081
  );
1082
- if (He(L, y)) {
1083
- tt(P(e), e, L, i, c), xe(i, P(e), e, L);
1082
+ if (He(T, d)) {
1083
+ tt(M(e), e, T, o, c), xe(o, M(e), e, T);
1084
1084
  const l = _.target;
1085
1085
  l && nt(
1086
1086
  l,
1087
1087
  a,
1088
- P(e) ? e : L,
1089
- P(e)
1088
+ M(e) ? e : T,
1089
+ M(e)
1090
1090
  );
1091
1091
  }
1092
- }, P(e) && typeof e.value == "object" && e.value !== null) {
1092
+ }, M(e) && typeof e.value == "object" && e.value !== null) {
1093
1093
  let _ = [];
1094
1094
  try {
1095
1095
  _ = Reflect.ownKeys(e.value);
1096
1096
  } catch {
1097
1097
  _ = Object.keys(e.value);
1098
1098
  }
1099
- const T = _.filter(
1100
- (L) => typeof L == "string" && !String(L).startsWith("_") && L !== "constructor"
1099
+ const E = _.filter(
1100
+ (T) => typeof T == "string" && !String(T).startsWith("_") && T !== "constructor"
1101
1101
  );
1102
- for (const L of T) {
1103
- const y = String(L), k = `update:${J(y)}`, l = `update:${y}`;
1104
- r[k] || (r[k] = (m) => {
1105
- const A = m.detail !== void 0 ? m.detail : m.target?.value, N = P(e) ? e.value[y] : U(
1106
- i?._state || i,
1102
+ for (const T of E) {
1103
+ const d = String(T), k = `update:${J(d)}`, l = `update:${d}`;
1104
+ r[k] || (r[k] = (g) => {
1105
+ const A = g.detail !== void 0 ? g.detail : g.target?.value, N = M(e) ? e.value[d] : U(
1106
+ o?._state || o,
1107
1107
  e
1108
1108
  );
1109
1109
  if (!He(A, N)) return;
1110
- if (P(e)) {
1110
+ if (M(e)) {
1111
1111
  const R = {
1112
1112
  ...e.value
1113
1113
  };
1114
- R[y] = A, e.value = R;
1114
+ R[d] = A, e.value = R;
1115
1115
  } else
1116
1116
  Re(
1117
- i?._state || i,
1117
+ o?._state || o,
1118
1118
  e,
1119
1119
  A
1120
1120
  );
1121
- xe(i, P(e), e, A);
1122
- const $ = m.currentTarget || o || m.target;
1123
- $ && nt(
1124
- $,
1121
+ xe(o, M(e), e, A);
1122
+ const j = g.currentTarget || i || g.target;
1123
+ j && nt(
1124
+ j,
1125
1125
  a,
1126
- P(e) ? e : A,
1127
- P(e)
1126
+ M(e) ? e : A,
1127
+ M(e)
1128
1128
  );
1129
1129
  }, r[l] = r[k]);
1130
1130
  }
1131
1131
  }
1132
- r[d] = r[h];
1132
+ r[p] = r[y];
1133
1133
  }
1134
- (w === "text" || w === "textarea") && (r.compositionstart = () => r._isComposing = !0, r.compositionend = (h) => {
1134
+ (C === "text" || C === "textarea") && (r.compositionstart = () => r._isComposing = !0, r.compositionend = (y) => {
1135
1135
  r._isComposing = !1;
1136
- const d = h.target;
1137
- d && setTimeout(() => {
1138
- const _ = d.value, T = i?._state || i, L = U(T, e);
1139
- let y = _;
1140
- if (u && (y = y.trim()), S) {
1141
- const l = Number(y);
1142
- isNaN(l) || (y = l);
1143
- }
1144
- if (He(y, L)) {
1145
- d._modelUpdating = !0;
1136
+ const p = y.target;
1137
+ p && setTimeout(() => {
1138
+ const _ = p.value, E = o?._state || o, T = U(E, e);
1139
+ let d = _;
1140
+ if (u && (d = d.trim()), S) {
1141
+ const l = Number(d);
1142
+ isNaN(l) || (d = l);
1143
+ }
1144
+ if (He(d, T)) {
1145
+ p._modelUpdating = !0;
1146
1146
  try {
1147
- Re(T, e, y), xe(i, P(e), e, y);
1147
+ Re(E, e, d), xe(o, M(e), e, d);
1148
1148
  } finally {
1149
1149
  setTimeout(
1150
- () => d._modelUpdating = !1,
1150
+ () => p._modelUpdating = !1,
1151
1151
  0
1152
1152
  );
1153
1153
  }
@@ -1161,50 +1161,50 @@ function pt(e) {
1161
1161
  }
1162
1162
  function Rt(e, n, t, s, r) {
1163
1163
  if (typeof e == "object" && e !== null)
1164
- for (const [i, o] of Object.entries(e))
1165
- if (i.startsWith("data-") || i.startsWith("aria-") || i === "class")
1166
- t[i] = o;
1167
- else if (i === "disabled" && r && X(r)) {
1168
- const c = o && typeof o == "object" && "value" in o;
1164
+ for (const [o, i] of Object.entries(e))
1165
+ if (o.startsWith("data-") || o.startsWith("aria-") || o === "class")
1166
+ t[o] = i;
1167
+ else if (o === "disabled" && r && X(r)) {
1168
+ const c = i && typeof i == "object" && "value" in i;
1169
1169
  (() => {
1170
1170
  try {
1171
- return P(o);
1171
+ return M(i);
1172
1172
  } catch {
1173
1173
  return !1;
1174
1174
  }
1175
- })() || c ? n[i] = o : t[i] = o;
1175
+ })() || c ? n[o] = i : t[o] = i;
1176
1176
  } else
1177
- n[i] = o;
1177
+ n[o] = i;
1178
1178
  else if (typeof e == "string") {
1179
1179
  if (!s) return;
1180
1180
  try {
1181
- const i = Me(e, s);
1182
- if (typeof i == "object" && i !== null) {
1183
- for (const [o, c] of Object.entries(i))
1184
- if (o.startsWith("data-") || o.startsWith("aria-") || o === "class")
1185
- t[o] = c;
1186
- else if (o === "disabled" && r && X(r)) {
1181
+ const o = Pe(e, s);
1182
+ if (typeof o == "object" && o !== null) {
1183
+ for (const [i, c] of Object.entries(o))
1184
+ if (i.startsWith("data-") || i.startsWith("aria-") || i === "class")
1185
+ t[i] = c;
1186
+ else if (i === "disabled" && r && X(r)) {
1187
1187
  const f = c && typeof c == "object" && "value" in c;
1188
1188
  (() => {
1189
1189
  try {
1190
- return P(c);
1190
+ return M(c);
1191
1191
  } catch {
1192
1192
  return !1;
1193
1193
  }
1194
- })() || f ? n[o] = c : t[o] = c;
1194
+ })() || f ? n[i] = c : t[i] = c;
1195
1195
  } else
1196
- n[o] = c;
1196
+ n[i] = c;
1197
1197
  return;
1198
1198
  } else {
1199
- t[e] = i;
1199
+ t[e] = o;
1200
1200
  return;
1201
1201
  }
1202
1202
  } catch {
1203
- const i = U(
1203
+ const o = U(
1204
1204
  s,
1205
1205
  e
1206
1206
  );
1207
- t[e] = i;
1207
+ t[e] = o;
1208
1208
  }
1209
1209
  }
1210
1210
  }
@@ -1212,40 +1212,40 @@ function Bt(e, n, t) {
1212
1212
  let s;
1213
1213
  if (typeof e == "string") {
1214
1214
  if (!t) return;
1215
- s = Me(e, t);
1215
+ s = Pe(e, t);
1216
1216
  } else
1217
1217
  s = e;
1218
1218
  const r = String(n.style || "");
1219
- let i = r;
1219
+ let o = r;
1220
1220
  if (s) {
1221
1221
  if (r) {
1222
- const o = String(r).split(";").map((f) => f.trim()).filter(Boolean), c = o.findIndex(
1222
+ const i = String(r).split(";").map((f) => f.trim()).filter(Boolean), c = i.findIndex(
1223
1223
  (f) => f.startsWith("display:")
1224
1224
  );
1225
- c >= 0 && o[c] === "display: none" && (o.splice(c, 1), i = o.length > 0 ? o.join("; ") + ";" : "");
1225
+ c >= 0 && i[c] === "display: none" && (i.splice(c, 1), o = i.length > 0 ? i.join("; ") + ";" : "");
1226
1226
  }
1227
1227
  } else if (r) {
1228
- const o = String(r).split(";").filter(Boolean), c = o.findIndex(
1228
+ const i = String(r).split(";").filter(Boolean), c = i.findIndex(
1229
1229
  (f) => f.trim().startsWith("display:")
1230
1230
  );
1231
- c >= 0 ? o[c] = "display: none" : o.push("display: none"), i = o.join("; ");
1231
+ c >= 0 ? i[c] = "display: none" : i.push("display: none"), o = i.join("; ");
1232
1232
  } else
1233
- i = "display: none";
1234
- i !== r && (i ? n.style = i : n.style = void 0);
1233
+ o = "display: none";
1234
+ o !== r && (o ? n.style = o : n.style = void 0);
1235
1235
  }
1236
- function Me(e, n) {
1236
+ function Pe(e, n) {
1237
1237
  return Ot.evaluate(e, n);
1238
1238
  }
1239
1239
  function Dt(e, n, t, s) {
1240
1240
  let r;
1241
1241
  if (typeof e == "string") {
1242
1242
  if (!t) return;
1243
- r = Me(e, t);
1243
+ r = Pe(e, t);
1244
1244
  } else
1245
1245
  r = e;
1246
1246
  try {
1247
1247
  if (r && typeof r == "object") {
1248
- if (P(r))
1248
+ if (M(r))
1249
1249
  r = r.value;
1250
1250
  else if ("value" in r && typeof r.value < "u") {
1251
1251
  const u = r.value;
@@ -1254,15 +1254,15 @@ function Dt(e, n, t, s) {
1254
1254
  }
1255
1255
  } catch {
1256
1256
  }
1257
- let i = [];
1257
+ let o = [];
1258
1258
  if (typeof r == "string")
1259
- i = [r];
1259
+ o = [r];
1260
1260
  else if (Array.isArray(r))
1261
- i = r.filter(Boolean);
1261
+ o = r.filter(Boolean);
1262
1262
  else if (typeof r == "object" && r !== null)
1263
1263
  for (const [u, S] of Object.entries(r))
1264
- S && i.push(u);
1265
- const o = i.join(" "), c = s && s.class || n.class || "", f = c ? `${c} ${o}`.trim() : o.trim();
1264
+ S && o.push(u);
1265
+ const i = o.join(" "), c = s && s.class || n.class || "", f = c ? `${c} ${i}`.trim() : i.trim();
1266
1266
  f ? n.class = f : n.class = void 0;
1267
1267
  }
1268
1268
  function Ve(e) {
@@ -1282,19 +1282,19 @@ function Wt(e, n, t) {
1282
1282
  let s;
1283
1283
  if (typeof e == "string") {
1284
1284
  if (!t) return;
1285
- s = Me(e, t);
1285
+ s = Pe(e, t);
1286
1286
  } else
1287
1287
  s = e;
1288
1288
  let r = "";
1289
1289
  if (typeof s == "string")
1290
1290
  r = s;
1291
1291
  else if (s && typeof s == "object") {
1292
- const o = [];
1292
+ const i = [];
1293
1293
  for (const [c, f] of Object.entries(s))
1294
1294
  if (f != null && f !== "") {
1295
1295
  const u = c.replace(
1296
1296
  /[A-Z]/g,
1297
- (g) => `-${g.toLowerCase()}`
1297
+ (m) => `-${m.toLowerCase()}`
1298
1298
  ), S = [
1299
1299
  "width",
1300
1300
  "height",
@@ -1321,49 +1321,49 @@ function Wt(e, n, t) {
1321
1321
  "min-height",
1322
1322
  "max-height"
1323
1323
  ];
1324
- let E = String(f);
1325
- typeof f == "number" && S.includes(u) && (E = `${f}px`), o.push(`${u}: ${E}`);
1324
+ let b = String(f);
1325
+ typeof f == "number" && S.includes(u) && (b = `${f}px`), i.push(`${u}: ${b}`);
1326
1326
  }
1327
- r = o.join("; ") + (o.length > 0 ? ";" : "");
1327
+ r = i.join("; ") + (i.length > 0 ? ";" : "");
1328
1328
  }
1329
- const i = String(n.style || "");
1330
- n.style = i + (i && !i.endsWith(";") ? "; " : "") + r;
1329
+ const o = String(n.style || "");
1330
+ n.style = o + (o && !o.endsWith(";") ? "; " : "") + r;
1331
1331
  }
1332
1332
  function zt(e, n, t) {
1333
1333
  let s = e;
1334
- typeof e == "string" && t && (s = Me(e, t)), P(s) ? n.reactiveRef = s : n.ref = s;
1334
+ typeof e == "string" && t && (s = Pe(e, t)), M(s) ? n.reactiveRef = s : n.ref = s;
1335
1335
  }
1336
1336
  function dt(e, n, t, s) {
1337
- const r = {}, i = { ...s || {} }, o = {};
1337
+ const r = {}, o = { ...s || {} }, i = {};
1338
1338
  for (const [c, f] of Object.entries(e)) {
1339
- const { value: u, modifiers: S, arg: E } = f;
1339
+ const { value: u, modifiers: S, arg: b } = f;
1340
1340
  if (c === "model" || c.startsWith("model:")) {
1341
- const g = c.split(":"), w = g.length > 1 ? g[1] : E;
1341
+ const m = c.split(":"), C = m.length > 1 ? m[1] : b;
1342
1342
  It(
1343
1343
  u,
1344
1344
  // Pass the original value (could be string or reactive state object)
1345
1345
  S,
1346
1346
  r,
1347
- i,
1348
1347
  o,
1348
+ i,
1349
1349
  n,
1350
1350
  t,
1351
- w
1351
+ C
1352
1352
  );
1353
1353
  continue;
1354
1354
  }
1355
1355
  switch (c) {
1356
1356
  case "bind":
1357
- Rt(u, r, i, n, t);
1357
+ Rt(u, r, o, n, t);
1358
1358
  break;
1359
1359
  case "show":
1360
- Bt(u, i, n);
1360
+ Bt(u, o, n);
1361
1361
  break;
1362
1362
  case "class":
1363
- Dt(u, i, n, s);
1363
+ Dt(u, o, n, s);
1364
1364
  break;
1365
1365
  case "style":
1366
- Wt(u, i, n);
1366
+ Wt(u, o, n);
1367
1367
  break;
1368
1368
  case "ref":
1369
1369
  zt(u, r, n);
@@ -1375,15 +1375,15 @@ function dt(e, n, t, s) {
1375
1375
  const f = r.disabled, u = f && typeof f == "object" && "value" in f;
1376
1376
  let S = !1;
1377
1377
  try {
1378
- S = P(f);
1378
+ S = M(f);
1379
1379
  } catch {
1380
1380
  S = !1;
1381
1381
  }
1382
1382
  if (!u && !S)
1383
1383
  try {
1384
- i.disabled = f, delete r.disabled;
1385
- const E = globalThis;
1386
- E.__VDOM_DISABLED_PROMOTIONS || (E.__VDOM_DISABLED_PROMOTIONS = []), E.__VDOM_DISABLED_PROMOTIONS.push({
1384
+ o.disabled = f, delete r.disabled;
1385
+ const b = globalThis;
1386
+ b.__VDOM_DISABLED_PROMOTIONS || (b.__VDOM_DISABLED_PROMOTIONS = []), b.__VDOM_DISABLED_PROMOTIONS.push({
1387
1387
  phase: "bind-directive:postfix-move",
1388
1388
  location: "attrs",
1389
1389
  key: "disabled",
@@ -1396,34 +1396,34 @@ function dt(e, n, t, s) {
1396
1396
  }
1397
1397
  } catch {
1398
1398
  }
1399
- return { props: r, attrs: i, listeners: o };
1399
+ return { props: r, attrs: o, listeners: i };
1400
1400
  }
1401
1401
  function qe(e, n) {
1402
1402
  if (Array.isArray(e)) {
1403
- const i = /* @__PURE__ */ new Set();
1404
- return e.map((o) => {
1405
- if (!o || typeof o != "object") return o;
1406
- let c = o.props?.key ?? o.key;
1403
+ const o = /* @__PURE__ */ new Set();
1404
+ return e.map((i) => {
1405
+ if (!i || typeof i != "object") return i;
1406
+ let c = i.props?.key ?? i.key;
1407
1407
  if (!c) {
1408
- const E = o.tag || "node", w = [
1408
+ const b = i.tag || "node", C = [
1409
1409
  // attrs (kebab-case)
1410
- o.props?.attrs?.id,
1411
- o.props?.attrs?.name,
1412
- o.props?.attrs?.["data-key"],
1410
+ i.props?.attrs?.id,
1411
+ i.props?.attrs?.name,
1412
+ i.props?.attrs?.["data-key"],
1413
1413
  // promoted JS props (camelCase or original)
1414
- o.props?.props?.id,
1415
- o.props?.props?.name,
1416
- o.props?.props?.dataKey,
1417
- o.props?.props?.["data-key"]
1418
- ].find((p) => p != null) ?? "";
1419
- c = w ? `${n}:${E}:${w}` : `${n}:${E}`;
1414
+ i.props?.props?.id,
1415
+ i.props?.props?.name,
1416
+ i.props?.props?.dataKey,
1417
+ i.props?.props?.["data-key"]
1418
+ ].find((w) => w != null) ?? "";
1419
+ c = C ? `${n}:${b}:${C}` : `${n}:${b}`;
1420
1420
  }
1421
1421
  let f = c, u = 1;
1422
- for (; i.has(f); )
1422
+ for (; o.has(f); )
1423
1423
  f = `${c}#${u++}`;
1424
- i.add(f);
1425
- let S = o.children;
1426
- return Array.isArray(S) && (S = qe(S, f)), { ...o, key: f, children: S };
1424
+ o.add(f);
1425
+ let S = i.children;
1426
+ return Array.isArray(S) && (S = qe(S, f)), { ...i, key: f, children: S };
1427
1427
  });
1428
1428
  }
1429
1429
  const t = e, s = t.props?.key ?? t.key ?? n;
@@ -1431,113 +1431,120 @@ function qe(e, n) {
1431
1431
  return Array.isArray(r) && (r = qe(r, s)), { ...t, key: s, children: r };
1432
1432
  }
1433
1433
  function rt(e, n, t, s) {
1434
- const r = t.directives ?? {}, i = dt(
1434
+ const r = t.directives ?? {}, o = t.attrs ? { ...t.attrs } : {}, i = dt(
1435
1435
  r,
1436
1436
  s,
1437
1437
  e,
1438
- t.attrs
1439
- ), o = {
1438
+ o
1439
+ ), c = {
1440
1440
  ...n.props || {},
1441
1441
  ...t.props || {},
1442
1442
  ...i.props || {}
1443
- }, c = {
1443
+ }, f = {
1444
1444
  ...n.attrs || {},
1445
- ...t.attrs || {},
1445
+ ...o || {},
1446
1446
  ...i.attrs || {}
1447
- }, f = n.props ?? {}, u = o, S = !!(t?.isCustomElement ?? n?.isCustomElement ?? !1);
1448
- let E = !1;
1449
- for (const p in { ...f, ...u }) {
1450
- const v = f[p], a = u[p];
1451
- let C = v, b = a;
1447
+ }, u = n.props ?? {}, S = c, b = !!(t?.isCustomElement ?? n?.isCustomElement ?? !1);
1448
+ let m = !1;
1449
+ for (const a in { ...u, ...S }) {
1450
+ const v = u[a], h = S[a];
1451
+ let y = v, p = h;
1452
1452
  if (H(() => {
1453
- (P(v) || me(v)) && (C = v.value);
1453
+ (M(v) || me(v)) && (y = v.value);
1454
1454
  }), H(() => {
1455
- (P(a) || me(a)) && (b = a.value);
1456
- }), !(v === a && C === b))
1457
- if (E = !0, p === "value" && (e instanceof HTMLInputElement || e instanceof HTMLTextAreaElement || e instanceof HTMLSelectElement)) {
1458
- const h = Fe(a), d = h == null ? "" : String(h);
1459
- e.value !== d && (e.value = d);
1460
- } else if (p === "checked" && e instanceof HTMLInputElement) {
1461
- const h = Fe(a);
1462
- e.checked = !!h;
1463
- } else if (p.startsWith("on") && typeof a == "function") {
1464
- const h = pt(p);
1465
- typeof v == "function" && te.removeListener(e, h, v), typeof a == "function" && te.addListener(e, h, a);
1455
+ (M(h) || me(h)) && (p = h.value);
1456
+ }), !(v === h && y === p))
1457
+ if (m = !0, a === "value" && (e instanceof HTMLInputElement || e instanceof HTMLTextAreaElement || e instanceof HTMLSelectElement)) {
1458
+ const _ = Fe(h), E = _ == null ? "" : String(_);
1459
+ e.value !== E && (e.value = E);
1460
+ } else if (a === "checked" && e instanceof HTMLInputElement) {
1461
+ const _ = Fe(h);
1462
+ e.checked = !!_;
1463
+ } else if (a.startsWith("on") && typeof h == "function") {
1464
+ const _ = pt(a);
1465
+ typeof v == "function" && te.removeListener(e, _, v), typeof h == "function" && te.addListener(e, _, h);
1466
1466
  try {
1467
- if (h && h.startsWith("update:")) {
1468
- const d = h.split(":", 2)[1], _ = u[d];
1469
- let T = [];
1467
+ if (_ && _.startsWith("update:")) {
1468
+ const E = _.split(":", 2)[1], T = S[E];
1469
+ let d = [];
1470
1470
  try {
1471
- if (P(_)) {
1472
- const y = _.value;
1473
- T = y && typeof y == "object" ? Object.keys(y) : [];
1474
- } else _ && typeof _ == "object" && (T = Object.keys(_));
1471
+ if (M(T)) {
1472
+ const l = T.value;
1473
+ d = l && typeof l == "object" ? Object.keys(l) : [];
1474
+ } else T && typeof T == "object" && (d = Object.keys(T));
1475
1475
  } catch {
1476
- T = [];
1476
+ d = [];
1477
1477
  }
1478
- const L = T.filter(
1479
- (y) => typeof y == "string" && !y.startsWith("_") && y !== "constructor"
1478
+ const k = d.filter(
1479
+ (l) => typeof l == "string" && !l.startsWith("_") && l !== "constructor"
1480
1480
  );
1481
- for (const y of L) {
1482
- const k = `update:${y}`, l = (m) => {
1483
- const A = m.detail !== void 0 ? m.detail : m.target instanceof HTMLInputElement || m.target instanceof HTMLTextAreaElement || m.target instanceof HTMLSelectElement ? m.target.value : void 0, O = { ...P(_) ? _.value || {} : u[d] || {}, [y]: A };
1481
+ for (const l of k) {
1482
+ const g = `update:${l}`, A = (N) => {
1483
+ const O = N.detail !== void 0 ? N.detail : N.target instanceof HTMLInputElement || N.target instanceof HTMLTextAreaElement || N.target instanceof HTMLSelectElement ? N.target.value : void 0, R = { ...M(T) ? T.value || {} : S[E] || {}, [l]: O };
1484
1484
  try {
1485
- typeof a == "function" && a({
1486
- detail: O
1485
+ typeof h == "function" && h({
1486
+ detail: R
1487
1487
  });
1488
1488
  } catch {
1489
1489
  }
1490
1490
  };
1491
1491
  H(() => {
1492
- te.addListener(e, k, l);
1492
+ te.addListener(e, g, A);
1493
1493
  });
1494
1494
  }
1495
1495
  }
1496
1496
  } catch {
1497
1497
  }
1498
- } else if (a == null)
1499
- q(e, p);
1498
+ } else if (h == null)
1499
+ q(e, a);
1500
1500
  else {
1501
- const h = t?.isCustomElement ?? n?.isCustomElement ?? !1;
1502
- if (h || p in e)
1501
+ const _ = t?.isCustomElement ?? n?.isCustomElement ?? !1;
1502
+ if (_ || a in e)
1503
1503
  try {
1504
- e[p] = a, p === "disabled" && a === !1 && !h && X(e) && q(e, "disabled");
1504
+ e[a] = h, a === "disabled" && h === !1 && !_ && X(e) && q(e, "disabled");
1505
1505
  } catch {
1506
1506
  }
1507
1507
  else
1508
- a === !1 && q(e, p);
1508
+ h === !1 && q(e, a);
1509
1509
  }
1510
1510
  }
1511
- for (const [p, v] of Object.entries(
1511
+ for (const [a, v] of Object.entries(
1512
1512
  i.listeners || {}
1513
1513
  )) {
1514
- te.addListener(e, p, v);
1514
+ te.addListener(e, a, v);
1515
1515
  try {
1516
- const a = e && e.parentElement;
1517
- a && a !== e && te.addListener(
1516
+ const h = e && e.parentElement;
1517
+ h && h !== e && te.addListener(
1518
+ h,
1518
1519
  a,
1519
- p,
1520
1520
  v
1521
1521
  );
1522
1522
  } catch {
1523
1523
  }
1524
1524
  }
1525
- const g = { ...n.attrs ?? {} }, w = c;
1525
+ const C = { ...n.attrs ?? {} }, w = f, L = i && i.attrs || {};
1526
+ if (Object.prototype.hasOwnProperty.call(L, "class") && typeof e.getAttribute == "function") {
1527
+ const a = e.getAttribute("class");
1528
+ a !== null && (C.class = a);
1529
+ }
1530
+ if (Object.prototype.hasOwnProperty.call(L, "style") && typeof e.getAttribute == "function") {
1531
+ const a = e.getAttribute("style");
1532
+ a !== null && (C.style = a);
1533
+ }
1526
1534
  try {
1527
- const p = i && i.attrs || {};
1528
- if (Object.prototype.hasOwnProperty.call(p, "class") && p.class === void 0 && typeof e.getAttribute == "function") {
1529
- const v = e.getAttribute("class");
1530
- v !== null && (g.class = v);
1535
+ if (Object.prototype.hasOwnProperty.call(L, "class") && L.class === void 0 && typeof e.getAttribute == "function") {
1536
+ const a = e.getAttribute("class");
1537
+ a !== null && (C.class = a);
1531
1538
  }
1532
- if (Object.prototype.hasOwnProperty.call(p, "style") && p.style === void 0 && typeof e.getAttribute == "function") {
1533
- const v = e.getAttribute("style");
1534
- v !== null && (g.style = v);
1539
+ if (Object.prototype.hasOwnProperty.call(L, "style") && L.style === void 0 && typeof e.getAttribute == "function") {
1540
+ const a = e.getAttribute("style");
1541
+ a !== null && (C.style = a);
1535
1542
  }
1536
1543
  try {
1537
1544
  if (typeof e.getAttribute == "function") {
1538
- const v = e.getAttribute("class");
1545
+ const a = e.getAttribute("class");
1539
1546
  try {
1540
- e instanceof HTMLInputElement && e.type === "text" && v !== null && v !== g.class && (g.class = v);
1547
+ e instanceof HTMLInputElement && e.type === "text" && a !== null && a !== C.class && (C.class = a);
1541
1548
  } catch {
1542
1549
  }
1543
1550
  }
@@ -1545,127 +1552,127 @@ function rt(e, n, t, s) {
1545
1552
  }
1546
1553
  } catch {
1547
1554
  }
1548
- for (const p in { ...g, ...w }) {
1549
- const v = g[p], a = w[p];
1550
- let C = v, b = a;
1551
- if (P(v) && (C = v.value), P(a) && (b = a.value), C !== b)
1552
- if (E = !0, b == null || b === !1)
1555
+ for (const a in { ...C, ...w }) {
1556
+ const v = C[a], h = w[a];
1557
+ let y = v, p = h;
1558
+ if (M(v) && (y = v.value), M(h) && (p = h.value), y !== p)
1559
+ if (m = !0, p == null || p === !1)
1553
1560
  H(() => {
1554
- q(e, p);
1555
- }), se(n, p, void 0), p === "value" && (e instanceof HTMLInputElement || e instanceof HTMLTextAreaElement ? H(() => {
1561
+ q(e, a);
1562
+ }), se(n, a, void 0), a === "value" && (e instanceof HTMLInputElement || e instanceof HTMLTextAreaElement ? H(() => {
1556
1563
  e.value = "";
1557
1564
  }) : e instanceof HTMLSelectElement ? H(() => {
1558
1565
  e.value = "";
1559
1566
  }) : e instanceof HTMLProgressElement && H(() => {
1560
1567
  e.value = 0;
1561
- })), p === "checked" && e instanceof HTMLInputElement && H(() => {
1568
+ })), a === "checked" && e instanceof HTMLInputElement && H(() => {
1562
1569
  e.checked = !1;
1563
- }), p === "disabled" && X(e) && H(() => {
1570
+ }), a === "disabled" && X(e) && H(() => {
1564
1571
  (e instanceof HTMLInputElement || e instanceof HTMLSelectElement || e instanceof HTMLTextAreaElement || e instanceof HTMLButtonElement) && (e.disabled = !1);
1565
1572
  });
1566
1573
  else {
1567
- if (p === "value") {
1574
+ if (a === "value") {
1568
1575
  if (e instanceof HTMLInputElement || e instanceof HTMLTextAreaElement) {
1569
1576
  H(() => {
1570
- e.value = b ?? "";
1577
+ e.value = p ?? "";
1571
1578
  });
1572
1579
  continue;
1573
1580
  } else if (e instanceof HTMLSelectElement) {
1574
1581
  H(() => {
1575
- e.value = b ?? "";
1582
+ e.value = p ?? "";
1576
1583
  });
1577
1584
  continue;
1578
1585
  } else if (e instanceof HTMLProgressElement) {
1579
1586
  H(() => {
1580
- e.value = Number(b);
1587
+ e.value = Number(p);
1581
1588
  });
1582
1589
  continue;
1583
1590
  }
1584
1591
  }
1585
- if (p === "checked" && e instanceof HTMLInputElement) {
1592
+ if (a === "checked" && e instanceof HTMLInputElement) {
1586
1593
  H(() => {
1587
- e.checked = !!b;
1594
+ e.checked = !!p;
1588
1595
  });
1589
1596
  continue;
1590
1597
  }
1591
- if (p === "style") {
1592
- const d = F(b);
1593
- d !== null && D(e, p, String(d)), se(n, p, b);
1598
+ if (a === "style") {
1599
+ const E = F(p);
1600
+ E !== null && D(e, a, String(E)), se(n, a, p);
1594
1601
  continue;
1595
1602
  }
1596
- if (p === "class") {
1597
- const d = F(b);
1598
- d !== null && D(e, p, String(d)), se(n, p, b);
1603
+ if (a === "class") {
1604
+ const E = F(p);
1605
+ E !== null && D(e, a, String(E)), se(n, a, p);
1599
1606
  continue;
1600
1607
  }
1601
- if (p === "disabled" && X(e)) {
1608
+ if (a === "disabled" && X(e)) {
1602
1609
  H(() => {
1603
- const d = ge(b);
1604
- (e instanceof HTMLInputElement || e instanceof HTMLSelectElement || e instanceof HTMLTextAreaElement || e instanceof HTMLButtonElement) && (e.disabled = d);
1605
- }), ge(b) ? H(() => {
1606
- D(e, p, "");
1610
+ const E = ge(p);
1611
+ (e instanceof HTMLInputElement || e instanceof HTMLSelectElement || e instanceof HTMLTextAreaElement || e instanceof HTMLButtonElement) && (e.disabled = E);
1612
+ }), ge(p) ? H(() => {
1613
+ D(e, a, "");
1607
1614
  }) : H(() => {
1608
- q(e, p);
1615
+ q(e, a);
1609
1616
  });
1610
1617
  continue;
1611
1618
  }
1612
- const h = e.namespaceURI === "http://www.w3.org/2000/svg";
1613
- if (S && !h && p.includes("-"))
1614
- if (at(p)) {
1615
- const d = F(a ?? b);
1616
- if (d !== null) {
1619
+ const _ = e.namespaceURI === "http://www.w3.org/2000/svg";
1620
+ if (b && !_ && a.includes("-"))
1621
+ if (at(a)) {
1622
+ const E = F(h ?? p);
1623
+ if (E !== null) {
1617
1624
  try {
1618
- D(e, p, String(d));
1625
+ D(e, a, String(E));
1619
1626
  } catch {
1620
1627
  }
1621
- se(n, p, b);
1628
+ se(n, a, p);
1622
1629
  }
1623
1630
  } else {
1624
- const d = Ze(p);
1631
+ const E = Ze(a);
1625
1632
  try {
1626
- const _ = e;
1627
- _[d] = P(a) ? a : b, se(n, p, b);
1633
+ const T = e;
1634
+ T[E] = M(h) ? h : p, se(n, a, p);
1628
1635
  } catch {
1629
- const _ = F(a ?? b);
1630
- _ !== null && D(e, p, String(_));
1636
+ const T = F(h ?? p);
1637
+ T !== null && D(e, a, String(T));
1631
1638
  }
1632
1639
  }
1633
- else if (!h && p in e)
1640
+ else if (!_ && a in e)
1634
1641
  try {
1635
- const d = e;
1636
- d[p] = P(a) ? a : b, se(n, p, b);
1642
+ const E = e;
1643
+ E[a] = M(h) ? h : p, se(n, a, p);
1637
1644
  } catch {
1638
- const d = F(b);
1639
- d !== null && (D(e, p, String(d)), se(n, p, b));
1645
+ const E = F(p);
1646
+ E !== null && (D(e, a, String(E)), se(n, a, p));
1640
1647
  }
1641
1648
  else {
1642
- const d = F(b);
1643
- d !== null && (D(e, p, String(d)), se(n, p, b));
1649
+ const E = F(p);
1650
+ E !== null && (D(e, a, String(E)), se(n, a, p));
1644
1651
  }
1645
1652
  }
1646
1653
  }
1647
1654
  try {
1648
1655
  if (X(e)) {
1649
- const p = o.disabled;
1656
+ const a = c.disabled;
1650
1657
  let v;
1651
1658
  try {
1652
- const C = Object.prototype.hasOwnProperty.call(
1659
+ const y = Object.prototype.hasOwnProperty.call(
1653
1660
  i.props || {},
1654
1661
  "disabled"
1655
- ), b = p && typeof p == "object" && "value" in p;
1656
- let h = !1;
1662
+ ), p = a && typeof a == "object" && "value" in a;
1663
+ let _ = !1;
1657
1664
  H(() => {
1658
- h = !!P(p);
1665
+ _ = !!M(a);
1659
1666
  });
1660
- const d = Ve(p);
1661
- h || b || C || d ? v = p : v = c.disabled;
1667
+ const E = Ve(a);
1668
+ _ || p || y || E ? v = a : v = f.disabled;
1662
1669
  } catch {
1663
- v = c.disabled;
1670
+ v = f.disabled;
1664
1671
  }
1665
- const a = ge(v);
1672
+ const h = ge(v);
1666
1673
  H(() => {
1667
- (e instanceof HTMLInputElement || e instanceof HTMLSelectElement || e instanceof HTMLTextAreaElement || e instanceof HTMLButtonElement) && (e.disabled = a);
1668
- }), a ? H(() => {
1674
+ (e instanceof HTMLInputElement || e instanceof HTMLSelectElement || e instanceof HTMLTextAreaElement || e instanceof HTMLButtonElement) && (e.disabled = h);
1675
+ }), h ? H(() => {
1669
1676
  D(e, "disabled", "");
1670
1677
  }) : H(() => {
1671
1678
  q(e, "disabled");
@@ -1673,12 +1680,12 @@ function rt(e, n, t, s) {
1673
1680
  }
1674
1681
  } catch {
1675
1682
  }
1676
- if (S && E) {
1677
- const p = e;
1683
+ if (b && m) {
1684
+ const a = e;
1678
1685
  H(() => {
1679
- p._applyProps?.(p._cfg);
1686
+ a._applyProps?.(a._cfg);
1680
1687
  }), H(() => {
1681
- typeof p.requestRender == "function" ? p.requestRender() : typeof p._render == "function" && p._render?.(p._cfg);
1688
+ typeof a.requestRender == "function" ? a.requestRender() : typeof a._render == "function" && a._render?.(a._cfg);
1682
1689
  });
1683
1690
  }
1684
1691
  }
@@ -1696,79 +1703,79 @@ function Z(e, n, t, s = null) {
1696
1703
  return document.createRange().createContextualFragment(a);
1697
1704
  }
1698
1705
  if (e.tag === "#anchor") {
1699
- const a = e, C = Array.isArray(a.children) ? a.children : [], b = document.createTextNode(""), h = document.createTextNode("");
1700
- a.key != null && (G(b, `${a.key}:start`), G(h, `${a.key}:end`)), a._startNode = b, a._endNode = h;
1701
- const d = document.createDocumentFragment();
1702
- d.appendChild(b);
1703
- for (const _ of C) {
1704
- const T = Z(
1706
+ const a = e, v = Array.isArray(a.children) ? a.children : [], h = document.createTextNode(""), y = document.createTextNode("");
1707
+ a.key != null && (G(h, `${a.key}:start`), G(y, `${a.key}:end`)), a._startNode = h, a._endNode = y;
1708
+ const p = document.createDocumentFragment();
1709
+ p.appendChild(h);
1710
+ for (const _ of v) {
1711
+ const E = Z(
1705
1712
  _,
1706
1713
  n,
1707
1714
  t,
1708
1715
  // propagate parent namespace (was previously a boolean)
1709
1716
  s
1710
1717
  );
1711
- if (a.key != null && T instanceof Element && !T.hasAttribute("data-anchor-key")) {
1712
- const L = _;
1713
- L && typeof L == "object" && L.key != null || G(T, String(a.key));
1718
+ if (a.key != null && E instanceof Element && !E.hasAttribute("data-anchor-key")) {
1719
+ const T = _;
1720
+ T && typeof T == "object" && T.key != null || G(E, String(a.key));
1714
1721
  }
1715
- d.appendChild(T);
1722
+ p.appendChild(E);
1716
1723
  }
1717
- return d.appendChild(h), d;
1724
+ return p.appendChild(y), p;
1718
1725
  }
1719
- const r = e && typeof e == "object" && e.props && e.props.attrs ? e.props.attrs : void 0, o = (r && typeof r.xmlns == "string" ? String(r.xmlns) : void 0) ?? s ?? gt[e.tag] ?? null, c = o ? document.createElementNS(o, e.tag) : document.createElement(e.tag);
1726
+ const r = e && typeof e == "object" && e.props && e.props.attrs ? e.props.attrs : void 0, i = (r && typeof r.xmlns == "string" ? String(r.xmlns) : void 0) ?? s ?? gt[e.tag] ?? null, c = i ? document.createElementNS(i, e.tag) : document.createElement(e.tag);
1720
1727
  e.key != null && G(c, e.key), e.props && e.props?._transitionGroup && xt(
1721
1728
  c,
1722
1729
  e.props?._transitionGroup
1723
1730
  );
1724
- const { props: f = {}, attrs: u = {}, directives: S = {} } = e.props ?? {}, E = dt(
1731
+ const { props: f = {}, attrs: u = {}, directives: S = {} } = e.props ?? {}, b = dt(
1725
1732
  S,
1726
1733
  n,
1727
1734
  c instanceof HTMLElement ? c : void 0,
1728
1735
  u
1729
- ), g = {
1736
+ ), m = {
1730
1737
  ...f,
1731
- ...E.props
1732
- }, w = {
1738
+ ...b.props
1739
+ }, C = {
1733
1740
  ...u,
1734
- ...E.attrs
1741
+ ...b.attrs
1735
1742
  };
1736
1743
  try {
1737
- const a = (w && w.class) ?? (g && g.class) ?? (e.props && e.props.attrs && e.props.attrs.class) ?? (e.props && e.props.props && e.props.props.class), C = F(a);
1738
- if (C !== null) {
1739
- const b = String(C).trim();
1740
- b && D(c, "class", b);
1744
+ const a = (C && C.class) ?? (m && m.class) ?? (e.props && e.props.attrs && e.props.attrs.class) ?? (e.props && e.props.props && e.props.props.class), v = F(a);
1745
+ if (v !== null) {
1746
+ const h = String(v).trim();
1747
+ h && D(c, "class", h);
1741
1748
  }
1742
1749
  } catch {
1743
1750
  }
1744
1751
  try {
1745
- if (g.disabled !== void 0 && c && X(c)) {
1746
- const a = g.disabled, C = a && typeof a == "object" && "value" in a;
1747
- let b = !1;
1752
+ if (m.disabled !== void 0 && c && X(c)) {
1753
+ const a = m.disabled, v = a && typeof a == "object" && "value" in a;
1754
+ let h = !1;
1748
1755
  try {
1749
- b = P(a);
1756
+ h = M(a);
1750
1757
  } catch {
1751
- b = !1;
1758
+ h = !1;
1752
1759
  }
1753
- !C && !b && H(() => {
1754
- w.disabled = a, delete g.disabled;
1760
+ !v && !h && H(() => {
1761
+ C.disabled = a, delete m.disabled;
1755
1762
  });
1756
1763
  }
1757
1764
  } catch {
1758
1765
  }
1759
- const p = c.namespaceURI === "http://www.w3.org/2000/svg";
1760
- for (const a in w) {
1761
- const C = w[a];
1766
+ const w = c.namespaceURI === "http://www.w3.org/2000/svg";
1767
+ for (const a in C) {
1768
+ const v = C[a];
1762
1769
  if (typeof a != "string" || /\[object Object\]/.test(a))
1763
1770
  continue;
1764
- const b = Fe(C);
1765
- if (typeof b == "boolean")
1766
- b ? D(c, a, "") : H(() => {
1771
+ const h = Fe(v);
1772
+ if (typeof h == "boolean")
1773
+ h ? D(c, a, "") : H(() => {
1767
1774
  q(c, a);
1768
1775
  });
1769
- else if (b != null) {
1776
+ else if (h != null) {
1770
1777
  if (a === "disabled" && X(c)) {
1771
- const h = g.disabled, d = Ve(h) ? h : b, _ = ge(d);
1778
+ const y = m.disabled, p = Ve(y) ? y : h, _ = ge(p);
1772
1779
  H(() => {
1773
1780
  c.disabled = _;
1774
1781
  }), _ ? H(() => {
@@ -1778,86 +1785,86 @@ function Z(e, n, t, s = null) {
1778
1785
  });
1779
1786
  continue;
1780
1787
  }
1781
- if (!p && a === "value" && (c instanceof HTMLInputElement || c instanceof HTMLTextAreaElement || c instanceof HTMLSelectElement || c instanceof HTMLProgressElement))
1788
+ if (!w && a === "value" && (c instanceof HTMLInputElement || c instanceof HTMLTextAreaElement || c instanceof HTMLSelectElement || c instanceof HTMLProgressElement))
1782
1789
  try {
1783
- c instanceof HTMLProgressElement ? c.value = Number(b) : c.value = String(b ?? "");
1790
+ c instanceof HTMLProgressElement ? c.value = Number(h) : c.value = String(h ?? "");
1784
1791
  } catch {
1785
- const h = F(b);
1786
- h !== null && D(c, a, String(h));
1792
+ const y = F(h);
1793
+ y !== null && D(c, a, String(y));
1787
1794
  }
1788
- else if (!p && a === "checked" && c instanceof HTMLInputElement)
1795
+ else if (!w && a === "checked" && c instanceof HTMLInputElement)
1789
1796
  try {
1790
- c.checked = !!b;
1797
+ c.checked = !!h;
1791
1798
  } catch {
1792
- const h = F(b);
1793
- h !== null && D(c, a, String(h));
1799
+ const y = F(h);
1800
+ y !== null && D(c, a, String(y));
1794
1801
  }
1795
- else if (!p && a in c)
1802
+ else if (!w && a in c)
1796
1803
  try {
1797
- c[a] = b, a === "disabled" && b === !1 && X(c) && q(c, "disabled"), se(e.props, a, b);
1804
+ c[a] = h, a === "disabled" && h === !1 && X(c) && q(c, "disabled"), se(e.props, a, h);
1798
1805
  } catch {
1799
- const h = F(b);
1800
- h !== null && D(c, a, String(h));
1806
+ const y = F(h);
1807
+ y !== null && D(c, a, String(y));
1801
1808
  }
1802
- else if ((e.props?.isCustomElement ?? !1) && !p && a.includes("-")) {
1803
- const d = Ze(a);
1809
+ else if ((e.props?.isCustomElement ?? !1) && !w && a.includes("-")) {
1810
+ const p = Ze(a);
1804
1811
  try {
1805
- c[d] = b;
1812
+ c[p] = h;
1806
1813
  } catch {
1807
- const _ = F(b);
1814
+ const _ = F(h);
1808
1815
  _ !== null && D(c, a, String(_));
1809
1816
  }
1810
1817
  } else {
1811
- const d = F(b);
1812
- d !== null && D(c, a, String(d));
1818
+ const p = F(h);
1819
+ p !== null && D(c, a, String(p));
1813
1820
  }
1814
1821
  }
1815
1822
  }
1816
- for (const a in g) {
1817
- const C = g[a];
1823
+ for (const a in m) {
1824
+ const v = m[a];
1818
1825
  if (!(typeof a != "string" || /\[object Object\]/.test(a)))
1819
1826
  if (a === "value" && (c instanceof HTMLInputElement || c instanceof HTMLTextAreaElement || c instanceof HTMLSelectElement)) {
1820
- const b = typeof C == "object" && C !== null && me(C) ? C.value : C;
1827
+ const h = typeof v == "object" && v !== null && me(v) ? v.value : v;
1821
1828
  H(() => {
1822
- c.value = String(b ?? "");
1829
+ c.value = String(h ?? "");
1823
1830
  });
1824
- } else if (a.startsWith("on") && typeof C == "function") {
1825
- const b = pt(a), h = b.includes(":") ? (() => {
1826
- const d = b.split(":"), _ = d[1];
1831
+ } else if (a.startsWith("on") && typeof v == "function") {
1832
+ const h = pt(a), y = h.includes(":") ? (() => {
1833
+ const p = h.split(":"), _ = p[1];
1827
1834
  if (_.includes("-")) {
1828
- const T = _.split("-").map(
1829
- (L, y) => y === 0 ? L : L.charAt(0).toUpperCase() + L.slice(1)
1835
+ const E = _.split("-").map(
1836
+ (T, d) => d === 0 ? T : T.charAt(0).toUpperCase() + T.slice(1)
1830
1837
  ).join("");
1831
- return `${d[0]}:${T}`;
1838
+ return `${p[0]}:${E}`;
1832
1839
  } else {
1833
- const T = _.replace(/([a-z0-9])([A-Z])/g, "$1-$2").toLowerCase();
1834
- return `${d[0]}:${T}`;
1840
+ const E = _.replace(/([a-z0-9])([A-Z])/g, "$1-$2").toLowerCase();
1841
+ return `${p[0]}:${E}`;
1835
1842
  }
1836
- })() : b;
1837
- E.listeners && (E.listeners[b] || E.listeners[h]) || te.addListener(c, b, C);
1843
+ })() : h;
1844
+ b.listeners && (b.listeners[h] || b.listeners[y]) || te.addListener(c, h, v);
1838
1845
  } else {
1839
- if (a.startsWith("on") && C === void 0)
1846
+ if (a.startsWith("on") && v === void 0)
1840
1847
  continue;
1841
- if (C == null || C === !1)
1848
+ if (v == null || v === !1)
1842
1849
  q(c, a);
1843
1850
  else {
1844
- const b = e.props?.isCustomElement ?? !1, h = typeof C == "object" && C !== null && P(C) ? C : me(C) && typeof C.value < "u" ? C.value : C;
1851
+ const h = e.props?.isCustomElement ?? !1, y = typeof v == "object" && v !== null && M(v) ? v : me(v) && typeof v.value < "u" ? v.value : v;
1845
1852
  if (a === "class" || a === "style") {
1846
1853
  try {
1847
- const d = F(h);
1848
- d !== null && D(c, a, String(d));
1854
+ const p = F(y);
1855
+ p !== null && D(c, a, String(p));
1849
1856
  } catch {
1850
1857
  }
1851
1858
  continue;
1852
1859
  }
1853
- if (b || a in c)
1860
+ if (h || a in c)
1854
1861
  try {
1855
- const d = typeof C == "object" && C !== null && P(C) ? C : me(C) ? C.value : C;
1862
+ const p = typeof v == "object" && v !== null && M(v) ? v : me(v) ? v.value : v;
1856
1863
  if (a === "disabled" && X(c)) {
1857
- const _ = g.disabled !== void 0 ? g.disabled : d, T = ge(_);
1864
+ const _ = m.disabled !== void 0 ? m.disabled : p, E = ge(_);
1858
1865
  H(() => {
1859
- c.disabled = T;
1860
- }), T ? H(() => {
1866
+ c.disabled = E;
1867
+ }), E ? H(() => {
1861
1868
  D(c, a, "");
1862
1869
  }) : H(() => {
1863
1870
  q(c, a);
@@ -1866,30 +1873,30 @@ function Z(e, n, t, s = null) {
1866
1873
  }
1867
1874
  try {
1868
1875
  if (typeof c[a] == "boolean") {
1869
- let T = d;
1870
- typeof d == "string" ? d === "false" ? T = !1 : d === "true" ? T = !0 : T = !!d && d !== "" : T = !!d, c[a] = T;
1876
+ let E = p;
1877
+ typeof p == "string" ? p === "false" ? E = !1 : p === "true" ? E = !0 : E = !!p && p !== "" : E = !!p, c[a] = E;
1871
1878
  } else
1872
- c[a] = d;
1879
+ c[a] = p;
1873
1880
  } catch {
1874
- c[a] = d;
1881
+ c[a] = p;
1875
1882
  }
1876
1883
  } catch {
1877
1884
  }
1878
1885
  }
1879
1886
  }
1880
1887
  }
1881
- for (const [a, C] of Object.entries(
1882
- E.listeners || {}
1888
+ for (const [a, v] of Object.entries(
1889
+ b.listeners || {}
1883
1890
  ))
1884
- te.addListener(c, a, C);
1885
- const v = {
1891
+ te.addListener(c, a, v);
1892
+ const L = {
1886
1893
  ...e,
1887
1894
  props: {
1888
1895
  ...e.props,
1889
- ...E.props
1896
+ ...b.props
1890
1897
  }
1891
1898
  };
1892
- we(v, c, t);
1899
+ we(L, c, t);
1893
1900
  try {
1894
1901
  const a = c;
1895
1902
  if (typeof a._applyProps == "function")
@@ -1901,31 +1908,31 @@ function Z(e, n, t, s = null) {
1901
1908
  } catch {
1902
1909
  }
1903
1910
  if (Array.isArray(e.children)) {
1904
- const a = e.tag === "foreignObject" && o === bt ? null : c.namespaceURI ?? null;
1905
- for (const C of e.children)
1906
- c.appendChild(Z(C, n, t, a));
1911
+ const a = e.tag === "foreignObject" && i === bt ? null : c.namespaceURI ?? null;
1912
+ for (const v of e.children)
1913
+ c.appendChild(Z(v, n, t, a));
1907
1914
  } else typeof e.children == "string" && (c.textContent = e.children);
1908
1915
  try {
1909
- if (c instanceof HTMLSelectElement && w && Object.prototype.hasOwnProperty.call(w, "value"))
1916
+ if (c instanceof HTMLSelectElement && C && Object.prototype.hasOwnProperty.call(C, "value"))
1910
1917
  try {
1911
- c.value = String(w.value ?? "");
1918
+ c.value = String(C.value ?? "");
1912
1919
  } catch {
1913
1920
  }
1914
1921
  } catch {
1915
1922
  }
1916
1923
  try {
1917
1924
  if (X(c)) {
1918
- const a = g.disabled, C = w.disabled, b = a && typeof a == "object" && "value" in a;
1919
- let h = !1;
1925
+ const a = m.disabled, v = C.disabled, h = a && typeof a == "object" && "value" in a;
1926
+ let y = !1;
1920
1927
  try {
1921
- h = !!P(a);
1928
+ y = !!M(a);
1922
1929
  } catch {
1923
- h = !1;
1930
+ y = !1;
1924
1931
  }
1925
- const _ = h || b || Ve(a) ? a : C, T = ge(_);
1932
+ const _ = y || h || Ve(a) ? a : v, E = ge(_);
1926
1933
  H(() => {
1927
- c.disabled = T;
1928
- }), T ? H(() => {
1934
+ c.disabled = E;
1935
+ }), E ? H(() => {
1929
1936
  D(c, "disabled", "");
1930
1937
  }) : H(() => {
1931
1938
  q(c, "disabled");
@@ -1941,77 +1948,77 @@ function Kt(e, n, t, s, r) {
1941
1948
  return;
1942
1949
  }
1943
1950
  if (!Array.isArray(t)) return;
1944
- const i = e.childNodes, o = [];
1945
- for (let v = 0; v < i.length; v++)
1946
- o.push(i[v]);
1951
+ const o = e.childNodes, i = [];
1952
+ for (let L = 0; L < o.length; L++)
1953
+ i.push(o[L]);
1947
1954
  const c = Array.isArray(n) ? n : [], f = Ht(e);
1948
1955
  if (f) {
1949
- const v = (h) => {
1950
- if (typeof h == "string")
1951
- return h.startsWith("each-") ? h.substring(5) : h;
1952
- if (typeof h == "number") return String(h);
1953
- }, a = [], C = [];
1954
- for (const h of t)
1955
- if (h && h.tag === "#anchor") {
1956
- const d = Array.isArray(h.children) ? h.children : [];
1957
- for (const _ of d) {
1958
- const T = v(
1959
- _.key ?? h.key ?? "unknown"
1956
+ const L = (y) => {
1957
+ if (typeof y == "string")
1958
+ return y.startsWith("each-") ? y.substring(5) : y;
1959
+ if (typeof y == "number") return String(y);
1960
+ }, a = [], v = [];
1961
+ for (const y of t)
1962
+ if (y && y.tag === "#anchor") {
1963
+ const p = Array.isArray(y.children) ? y.children : [];
1964
+ for (const _ of p) {
1965
+ const E = L(
1966
+ _.key ?? y.key ?? "unknown"
1960
1967
  );
1961
- a.push({ ..._, key: T });
1968
+ a.push({ ..._, key: E });
1962
1969
  }
1963
- } else h && a.push({ ...h, key: v(h.key) });
1964
- for (const h of c)
1965
- if (h && h.tag === "#anchor") {
1966
- const d = Array.isArray(h.children) ? h.children : [];
1967
- for (const _ of d) {
1968
- const T = v(
1969
- _.key ?? h.key ?? "unknown"
1970
+ } else y && a.push({ ...y, key: L(y.key) });
1971
+ for (const y of c)
1972
+ if (y && y.tag === "#anchor") {
1973
+ const p = Array.isArray(y.children) ? y.children : [];
1974
+ for (const _ of p) {
1975
+ const E = L(
1976
+ _.key ?? y.key ?? "unknown"
1970
1977
  );
1971
- C.push({ ..._, key: T });
1978
+ v.push({ ..._, key: E });
1972
1979
  }
1973
- } else h && C.push({
1974
- ...h,
1975
- key: v(h.key)
1980
+ } else y && v.push({
1981
+ ...y,
1982
+ key: L(y.key)
1976
1983
  });
1977
- if (a.some((h) => h && h.key != null) || C.some((h) => h && h.key != null)) {
1978
- const h = /* @__PURE__ */ new Map(), d = /* @__PURE__ */ new Map();
1979
- for (const l of C)
1984
+ if (a.some((y) => y && y.key != null) || v.some((y) => y && y.key != null)) {
1985
+ const y = /* @__PURE__ */ new Map(), p = /* @__PURE__ */ new Map();
1986
+ for (const l of v)
1980
1987
  if (l && l.key != null) {
1981
- const m = String(l.key);
1982
- h.set(m, l);
1988
+ const g = String(l.key);
1989
+ y.set(g, l);
1983
1990
  }
1984
- for (let l = 0; l < o.length; l++) {
1985
- const m = o[l];
1986
- let A = Ie(m);
1987
- if (A = v(A), A != null && m instanceof Element && m.nodeType === Node.ELEMENT_NODE) {
1991
+ for (let l = 0; l < i.length; l++) {
1992
+ const g = i[l];
1993
+ let A = Ie(g);
1994
+ if (A = L(A), A != null && g instanceof Element && g.nodeType === Node.ELEMENT_NODE) {
1988
1995
  let N = typeof A == "string" && A.includes(":") ? A.substring(0, A.lastIndexOf(":")) : A;
1989
- N = String(N), d.set(N, m);
1996
+ N = String(N), p.set(N, g);
1990
1997
  }
1991
1998
  }
1992
- const _ = /* @__PURE__ */ new Set(), T = /* @__PURE__ */ new Map(), L = o.length > 0;
1993
- if (f.moveClass && L)
1994
- for (let l = 0; l < o.length; l++) {
1995
- const m = o[l];
1996
- if (m instanceof HTMLElement && m.parentElement) {
1997
- const A = m.getBoundingClientRect();
1998
- T.set(m, A);
1999
+ const _ = /* @__PURE__ */ new Set(), E = /* @__PURE__ */ new Map(), T = i.length > 0;
2000
+ if (f.moveClass && T)
2001
+ for (let l = 0; l < i.length; l++) {
2002
+ const g = i[l];
2003
+ if (g instanceof HTMLElement && g.parentElement) {
2004
+ const A = g.getBoundingClientRect();
2005
+ E.set(g, A);
1999
2006
  }
2000
2007
  }
2001
- const y = [];
2008
+ const d = [];
2002
2009
  for (const l of a) {
2003
- let m = l.key;
2004
- if (m == null) continue;
2005
- m = String(m);
2006
- const A = h.get(m);
2007
- let N = d.get(m);
2010
+ let g = l.key;
2011
+ if (g == null) continue;
2012
+ g = String(g);
2013
+ const A = y.get(g);
2014
+ let N = p.get(g);
2008
2015
  if (N && A) {
2009
2016
  const O = Te(N, A, l, s);
2010
2017
  _.add(N);
2011
- const $ = String(m);
2012
- G(O, $), y.push({
2018
+ const j = String(g);
2019
+ G(O, j), d.push({
2013
2020
  node: O,
2014
- key: m,
2021
+ key: g,
2015
2022
  newVNode: l,
2016
2023
  oldVNode: A,
2017
2024
  isNew: !1
@@ -2022,67 +2029,67 @@ function Kt(e, n, t, s, r) {
2022
2029
  s,
2023
2030
  void 0,
2024
2031
  e instanceof Element ? e.namespaceURI ?? null : null
2025
- ), G(N, String(m)), e.appendChild(N);
2026
- const O = L || f.appear === !0;
2027
- N instanceof HTMLElement && O && Ae(N, f).catch(($) => {
2028
- W("Enter transition error:", $);
2029
- }), y.push({ node: N, key: m, newVNode: l, isNew: !0 });
2032
+ ), G(N, String(g)), e.appendChild(N);
2033
+ const O = T || f.appear === !0;
2034
+ N instanceof HTMLElement && O && Ae(N, f).catch((j) => {
2035
+ W("Enter transition error:", j);
2036
+ }), d.push({ node: N, key: g, newVNode: l, isNew: !0 });
2030
2037
  }
2031
2038
  }
2032
2039
  const k = [];
2033
- for (let l = 0; l < o.length; l++) {
2034
- const m = o[l], A = Ie(m);
2035
- if (!_.has(m) && A != null && m instanceof HTMLElement) {
2036
- const O = ze(m, f).then(() => {
2037
- e.contains(m) && e.removeChild(m);
2038
- }).catch(($) => {
2039
- W("Leave transition error:", $), e.contains(m) && e.removeChild(m);
2040
+ for (let l = 0; l < i.length; l++) {
2041
+ const g = i[l], A = Ie(g);
2042
+ if (!_.has(g) && A != null && g instanceof HTMLElement) {
2043
+ const O = ze(g, f).then(() => {
2044
+ e.contains(g) && e.removeChild(g);
2045
+ }).catch((j) => {
2046
+ W("Leave transition error:", j), e.contains(g) && e.removeChild(g);
2040
2047
  });
2041
2048
  k.push(O);
2042
2049
  }
2043
2050
  }
2044
2051
  if (k.length === 0) {
2045
2052
  let l = e.firstChild;
2046
- for (const { node: m } of y)
2047
- m !== l && e.insertBefore(m, l), l = m.nextSibling;
2048
- if (f.moveClass && T.size > 0) {
2049
- const m = [];
2050
- for (const { node: A, isNew: N } of y)
2053
+ for (const { node: g } of d)
2054
+ g !== l && e.insertBefore(g, l), l = g.nextSibling;
2055
+ if (f.moveClass && E.size > 0) {
2056
+ const g = [];
2057
+ for (const { node: A, isNew: N } of d)
2051
2058
  if (!N && A instanceof HTMLElement) {
2052
- const O = T.get(A);
2059
+ const O = E.get(A);
2053
2060
  if (O) {
2054
- const $ = A.getBoundingClientRect(), R = O.left - $.left, M = O.top - $.top;
2055
- if (R !== 0 || M !== 0) {
2061
+ const j = A.getBoundingClientRect(), R = O.left - j.left, P = O.top - j.top;
2062
+ if (R !== 0 || P !== 0) {
2056
2063
  const K = f.moveClass.split(/\s+/).filter((I) => I);
2057
- m.push({ node: A, deltaX: R, deltaY: M, moveClasses: K });
2064
+ g.push({ node: A, deltaX: R, deltaY: P, moveClasses: K });
2058
2065
  }
2059
2066
  }
2060
2067
  }
2061
- if (m.length > 0) {
2062
- for (const { node: A, deltaX: N, deltaY: O } of m)
2068
+ if (g.length > 0) {
2069
+ for (const { node: A, deltaX: N, deltaY: O } of g)
2063
2070
  A.style.transform = `translate(${N}px, ${O}px)`, A.style.transitionProperty = "none";
2064
2071
  e.offsetHeight, requestAnimationFrame(() => {
2065
2072
  requestAnimationFrame(() => {
2066
- for (const { node: A, moveClasses: N } of m)
2073
+ for (const { node: A, moveClasses: N } of g)
2067
2074
  for (const O of N)
2068
2075
  A.classList.add(O);
2069
2076
  requestAnimationFrame(() => {
2070
- const A = f.moveClass || "", N = A.match(/duration-(\d+)/), O = N ? `${N[1]}ms` : "300ms", $ = A.match(
2077
+ const A = f.moveClass || "", N = A.match(/duration-(\d+)/), O = N ? `${N[1]}ms` : "300ms", j = A.match(
2071
2078
  /ease-(out|in|in-out|linear)/
2072
- ), R = $ ? `ease-${$[1]}` : "ease-out";
2073
- for (const { node: M } of m)
2074
- M.style.transition = `transform ${O} ${R}`;
2079
+ ), R = j ? `ease-${j[1]}` : "ease-out";
2080
+ for (const { node: P } of g)
2081
+ P.style.transition = `transform ${O} ${R}`;
2075
2082
  requestAnimationFrame(() => {
2076
- for (const { node: M, moveClasses: K } of m) {
2077
- M.style.removeProperty("transform");
2083
+ for (const { node: P, moveClasses: K } of g) {
2084
+ P.style.removeProperty("transform");
2078
2085
  const I = () => {
2079
2086
  for (const ie of K)
2080
- M.classList.remove(ie);
2081
- M.style.removeProperty("transition"), M.removeEventListener("transitionend", I), M.removeEventListener("transitioncancel", I);
2087
+ P.classList.remove(ie);
2088
+ P.style.removeProperty("transition"), P.removeEventListener("transitionend", I), P.removeEventListener("transitioncancel", I);
2082
2089
  };
2083
- M.addEventListener("transitionend", I, {
2090
+ P.addEventListener("transitionend", I, {
2084
2091
  once: !0
2085
- }), M.addEventListener("transitioncancel", I, {
2092
+ }), P.addEventListener("transitioncancel", I, {
2086
2093
  once: !0
2087
2094
  });
2088
2095
  }
@@ -2097,151 +2104,151 @@ function Kt(e, n, t, s, r) {
2097
2104
  }
2098
2105
  }
2099
2106
  const u = /* @__PURE__ */ new Map();
2100
- for (const v of c)
2101
- v && v.key != null && u.set(v.key, v);
2107
+ for (const L of c)
2108
+ L && L.key != null && u.set(L.key, L);
2102
2109
  const S = /* @__PURE__ */ new Map();
2103
- for (let v = 0; v < o.length; v++) {
2104
- const a = o[v], C = Ie(a);
2105
- C != null && S.set(C, a);
2106
- }
2107
- const E = /* @__PURE__ */ new Set();
2108
- let g = e.firstChild;
2109
- function w(v, a) {
2110
- let C = v;
2111
- for (; C && (E.add(C), C !== a); )
2112
- C = C.nextSibling;
2113
- }
2114
- function p(v, a, C, b, h, d = !0) {
2110
+ for (let L = 0; L < i.length; L++) {
2111
+ const a = i[L], v = Ie(a);
2112
+ v != null && S.set(v, a);
2113
+ }
2114
+ const b = /* @__PURE__ */ new Set();
2115
+ let m = e.firstChild;
2116
+ function C(L, a) {
2117
+ let v = L;
2118
+ for (; v && (b.add(v), v !== a); )
2119
+ v = v.nextSibling;
2120
+ }
2121
+ function w(L, a, v, h, y, p = !0) {
2115
2122
  const _ = [];
2116
- let T = v.nextSibling;
2117
- for (; T && T !== a; )
2118
- _.push(T), T = T.nextSibling;
2119
- const L = Array.isArray(C) ? C : [];
2120
- if (b.some((k) => k && k.key != null) || L.some((k) => k && k.key != null)) {
2123
+ let E = L.nextSibling;
2124
+ for (; E && E !== a; )
2125
+ _.push(E), E = E.nextSibling;
2126
+ const T = Array.isArray(v) ? v : [];
2127
+ if (h.some((k) => k && k.key != null) || T.some((k) => k && k.key != null)) {
2121
2128
  const k = /* @__PURE__ */ new Map(), l = /* @__PURE__ */ new Map();
2122
- for (const O of L)
2129
+ for (const O of T)
2123
2130
  O && O.key != null && k.set(O.key, O);
2124
2131
  for (const O of _) {
2125
- const $ = Ie(O);
2126
- $ != null && l.set($, O);
2132
+ const j = Ie(O);
2133
+ j != null && l.set(j, O);
2127
2134
  }
2128
- const m = h && h.state === "visible" && L.length === 0 && b.length > 0, A = /* @__PURE__ */ new Set();
2129
- let N = v.nextSibling;
2130
- for (const O of b) {
2131
- let $;
2135
+ const g = y && y.state === "visible" && T.length === 0 && h.length > 0, A = /* @__PURE__ */ new Set();
2136
+ let N = L.nextSibling;
2137
+ for (const O of h) {
2138
+ let j;
2132
2139
  if (O.key != null && l.has(O.key)) {
2133
2140
  const R = k.get(O.key);
2134
- $ = Te(
2141
+ j = Te(
2135
2142
  l.get(O.key),
2136
2143
  R,
2137
2144
  O,
2138
2145
  s
2139
- ), A.add($), h && $ instanceof HTMLElement && m && h.appear && Ae($, h).catch((M) => {
2140
- W("Transition enter error (appear):", M);
2141
- }), $ !== N && e.contains($) && e.insertBefore($, N);
2146
+ ), A.add(j), y && j instanceof HTMLElement && g && y.appear && Ae(j, y).catch((P) => {
2147
+ W("Transition enter error (appear):", P);
2148
+ }), j !== N && e.contains(j) && e.insertBefore(j, N);
2142
2149
  } else
2143
- $ = Z(
2150
+ j = Z(
2144
2151
  O,
2145
2152
  s,
2146
2153
  void 0,
2147
2154
  e instanceof Element ? e.namespaceURI ?? null : null
2148
- ), e.insertBefore($, N), A.add($), h && $ instanceof HTMLElement && d && Ae($, h).catch((R) => {
2155
+ ), e.insertBefore(j, N), A.add(j), y && j instanceof HTMLElement && p && Ae(j, y).catch((R) => {
2149
2156
  W("Transition enter error:", R);
2150
2157
  });
2151
- N = $.nextSibling;
2158
+ N = j.nextSibling;
2152
2159
  }
2153
2160
  for (const O of _)
2154
- !A.has(O) && e.contains(O) && (h && O instanceof HTMLElement && d ? ze(O, h).then(() => {
2161
+ !A.has(O) && e.contains(O) && (y && O instanceof HTMLElement && p ? ze(O, y).then(() => {
2155
2162
  e.contains(O) && e.removeChild(O);
2156
- }).catch(($) => {
2157
- W("Transition leave error:", $), e.contains(O) && e.removeChild(O);
2163
+ }).catch((j) => {
2164
+ W("Transition leave error:", j), e.contains(O) && e.removeChild(O);
2158
2165
  }) : e.removeChild(O));
2159
2166
  } else {
2160
2167
  const k = Math.min(
2161
- L.length,
2162
- b.length
2168
+ T.length,
2169
+ h.length
2163
2170
  );
2164
2171
  for (let l = 0; l < k; l++) {
2165
- const m = L[l], A = b[l], N = Te(_[l], m, A, s);
2172
+ const g = T[l], A = h[l], N = Te(_[l], g, A, s);
2166
2173
  N !== _[l] && (e.insertBefore(N, _[l]), e.removeChild(_[l]));
2167
2174
  }
2168
- for (let l = k; l < b.length; l++) {
2169
- const m = Z(
2170
- b[l],
2175
+ for (let l = k; l < h.length; l++) {
2176
+ const g = Z(
2177
+ h[l],
2171
2178
  s,
2172
2179
  void 0,
2173
2180
  e instanceof Element ? e.namespaceURI ?? null : null
2174
2181
  );
2175
- e.insertBefore(m, a), h && m instanceof HTMLElement && d && Ae(m, h).catch((A) => {
2182
+ e.insertBefore(g, a), y && g instanceof HTMLElement && p && Ae(g, y).catch((A) => {
2176
2183
  W("Transition enter error:", A);
2177
2184
  });
2178
2185
  }
2179
2186
  for (let l = k; l < _.length; l++) {
2180
- const m = _[l];
2181
- h && m instanceof HTMLElement && d ? ze(m, h).then(() => {
2182
- e.contains(m) && e.removeChild(m);
2187
+ const g = _[l];
2188
+ y && g instanceof HTMLElement && p ? ze(g, y).then(() => {
2189
+ e.contains(g) && e.removeChild(g);
2183
2190
  }).catch((A) => {
2184
- W("Transition leave error:", A), e.contains(m) && e.removeChild(m);
2185
- }) : e.removeChild(m);
2191
+ W("Transition leave error:", A), e.contains(g) && e.removeChild(g);
2192
+ }) : e.removeChild(g);
2186
2193
  }
2187
2194
  }
2188
2195
  }
2189
- for (const v of t) {
2196
+ for (const L of t) {
2190
2197
  let a;
2191
- if (v.tag === "#anchor") {
2192
- const C = v.key, b = `${C}:start`, h = `${C}:end`;
2193
- let d = S.get(b), _ = S.get(h);
2194
- const T = Array.isArray(v.children) ? v.children : [];
2195
- if (d || (d = document.createTextNode(""), G(d, b)), _ || (_ = document.createTextNode(""), G(_, h)), v._startNode = d, v._endNode = _, !e.contains(d) || !e.contains(_)) {
2196
- e.insertBefore(d, g);
2197
- const L = v._transition, k = !(L && L.state === "visible" && T.length > 0) || L.appear;
2198
- for (const l of T) {
2199
- const m = Z(
2198
+ if (L.tag === "#anchor") {
2199
+ const v = L.key, h = `${v}:start`, y = `${v}:end`;
2200
+ let p = S.get(h), _ = S.get(y);
2201
+ const E = Array.isArray(L.children) ? L.children : [];
2202
+ if (p || (p = document.createTextNode(""), G(p, h)), _ || (_ = document.createTextNode(""), G(_, y)), L._startNode = p, L._endNode = _, !e.contains(p) || !e.contains(_)) {
2203
+ e.insertBefore(p, m);
2204
+ const T = L._transition, k = !(T && T.state === "visible" && E.length > 0) || T.appear;
2205
+ for (const l of E) {
2206
+ const g = Z(
2200
2207
  l,
2201
2208
  s,
2202
2209
  r,
2203
2210
  e instanceof Element ? e.namespaceURI ?? null : null
2204
2211
  );
2205
- e.insertBefore(m, g), L && m instanceof HTMLElement && k && Ae(m, L).catch((A) => {
2212
+ e.insertBefore(g, m), T && g instanceof HTMLElement && k && Ae(g, T).catch((A) => {
2206
2213
  W("Transition enter error:", A);
2207
2214
  });
2208
2215
  }
2209
- e.insertBefore(_, g);
2216
+ e.insertBefore(_, m);
2210
2217
  } else {
2211
- const L = v._transition, k = u.get(C)._transition, l = k && k.state !== L?.state, m = L && L.state === "visible" && T.length > 0 && !l, A = l || !m || L?.appear === !0;
2212
- p(
2213
- d,
2218
+ const T = L._transition, k = u.get(v)._transition, l = k && k.state !== T?.state, g = T && T.state === "visible" && E.length > 0 && !l, A = l || !g || T?.appear === !0;
2219
+ w(
2220
+ p,
2214
2221
  _,
2215
- u.get(C)?.children,
2222
+ u.get(v)?.children,
2223
+ E,
2216
2224
  T,
2217
- L,
2218
2225
  A
2219
2226
  );
2220
2227
  }
2221
- w(d, _), g = _.nextSibling;
2228
+ C(p, _), m = _.nextSibling;
2222
2229
  continue;
2223
2230
  }
2224
- if (v.key != null && S.has(v.key)) {
2225
- const C = u.get(v.key);
2231
+ if (L.key != null && S.has(L.key)) {
2232
+ const v = u.get(L.key);
2226
2233
  a = Te(
2227
- S.get(v.key),
2228
- C,
2234
+ S.get(L.key),
2229
2235
  v,
2236
+ L,
2230
2237
  s,
2231
2238
  r
2232
- ), E.add(a), a !== g && e.contains(a) && (g && !e.contains(g) && (g = null), e.insertBefore(a, g));
2239
+ ), b.add(a), a !== m && e.contains(a) && (m && !e.contains(m) && (m = null), e.insertBefore(a, m));
2233
2240
  } else
2234
2241
  a = Z(
2235
- v,
2242
+ L,
2236
2243
  s,
2237
2244
  r,
2238
2245
  e instanceof Element ? e.namespaceURI ?? null : null
2239
- ), g && !e.contains(g) && (g = null), e.insertBefore(a, g), E.add(a);
2240
- g = a.nextSibling;
2246
+ ), m && !e.contains(m) && (m = null), e.insertBefore(a, m), b.add(a);
2247
+ m = a.nextSibling;
2241
2248
  }
2242
- for (let v = 0; v < o.length; v++) {
2243
- const a = o[v];
2244
- !E.has(a) && e.contains(a) && (ue(a, r), e.removeChild(a));
2249
+ for (let L = 0; L < i.length; L++) {
2250
+ const a = i[L];
2251
+ !b.has(a) && e.contains(a) && (ue(a, r), e.removeChild(a));
2245
2252
  }
2246
2253
  }
2247
2254
  function Te(e, n, t, s, r) {
@@ -2250,47 +2257,47 @@ function Te(e, n, t, s, r) {
2250
2257
  if (e.nodeType === Node.TEXT_NODE)
2251
2258
  return e.textContent !== t && (e.textContent = t), e;
2252
2259
  {
2253
- const o = document.createTextNode(t);
2254
- return e.parentNode?.replaceChild(o, e), o;
2260
+ const i = document.createTextNode(t);
2261
+ return e.parentNode?.replaceChild(i, e), i;
2255
2262
  }
2256
2263
  }
2257
2264
  if (t && typeof t != "string" && t.tag === "#anchor") {
2258
- const o = t, c = Array.isArray(o.children) ? o.children : [], f = o._startNode ?? document.createTextNode(""), u = o._endNode ?? document.createTextNode("");
2259
- o.key != null && (G(f, `${o.key}:start`), G(u, `${o.key}:end`)), o._startNode = f, o._endNode = u;
2265
+ const i = t, c = Array.isArray(i.children) ? i.children : [], f = i._startNode ?? document.createTextNode(""), u = i._endNode ?? document.createTextNode("");
2266
+ i.key != null && (G(f, `${i.key}:start`), G(u, `${i.key}:end`)), i._startNode = f, i._endNode = u;
2260
2267
  const S = document.createDocumentFragment();
2261
2268
  S.appendChild(f);
2262
- for (const E of c) {
2263
- const g = Z(
2264
- E,
2269
+ for (const b of c) {
2270
+ const m = Z(
2271
+ b,
2265
2272
  s,
2266
2273
  r,
2267
2274
  e.parentNode instanceof Element ? e.parentNode.namespaceURI ?? null : null
2268
2275
  );
2269
- S.appendChild(g);
2276
+ S.appendChild(m);
2270
2277
  }
2271
2278
  return S.appendChild(u), e.parentNode?.replaceChild(S, e), f;
2272
2279
  }
2273
2280
  if (!t) {
2274
2281
  ue(e, r);
2275
- const o = document.createComment("removed");
2276
- return e.parentNode?.replaceChild(o, e), o;
2282
+ const i = document.createComment("removed");
2283
+ return e.parentNode?.replaceChild(i, e), i;
2277
2284
  }
2278
2285
  if (!n || typeof n == "string") {
2279
2286
  ue(e, r);
2280
- const o = Z(
2287
+ const i = Z(
2281
2288
  t,
2282
2289
  s,
2283
2290
  r,
2284
2291
  e.parentNode instanceof Element ? e.parentNode.namespaceURI ?? null : null
2285
2292
  );
2286
- return we(t, o, r), e.parentNode?.replaceChild(o, e), o;
2293
+ return we(t, i, r), e.parentNode?.replaceChild(i, e), i;
2287
2294
  }
2288
2295
  if (t.tag === "#anchor") {
2289
- const o = Array.isArray(t.children) ? t.children : [], c = t._startNode ?? document.createTextNode(""), f = t._endNode ?? document.createTextNode("");
2296
+ const i = Array.isArray(t.children) ? t.children : [], c = t._startNode ?? document.createTextNode(""), f = t._endNode ?? document.createTextNode("");
2290
2297
  t.key != null && (G(c, `${t.key}:start`), G(f, `${t.key}:end`)), t._startNode = c, t._endNode = f;
2291
2298
  const u = document.createDocumentFragment();
2292
2299
  u.appendChild(c);
2293
- for (const S of o)
2300
+ for (const S of i)
2294
2301
  u.appendChild(
2295
2302
  Z(
2296
2303
  S,
@@ -2302,8 +2309,8 @@ function Te(e, n, t, s, r) {
2302
2309
  return u.appendChild(f), e.parentNode?.replaceChild(u, e), c;
2303
2310
  }
2304
2311
  if (typeof n != "string" && typeof t != "string" && n.tag === t.tag && n.key === t.key) {
2305
- const o = e;
2306
- return rt(o, n.props || {}, t.props || {}, s), Kt(o, n.children, t.children, s, r), we(t, o, r), o;
2312
+ const i = e;
2313
+ return rt(i, n.props || {}, t.props || {}, s), Kt(i, n.children, t.children, s, r), we(t, i, r), i;
2307
2314
  }
2308
2315
  if (typeof n != "string" && typeof t != "string" && n.tag === t.tag && (n.tag && String(n.tag).includes("-") || t.props && t.props.isCustomElement || n.props && n.props.isCustomElement))
2309
2316
  try {
@@ -2312,13 +2319,13 @@ function Te(e, n, t, s, r) {
2312
2319
  } catch {
2313
2320
  }
2314
2321
  ue(e, r);
2315
- const i = Z(
2322
+ const o = Z(
2316
2323
  t,
2317
2324
  s,
2318
2325
  r,
2319
2326
  e.parentNode instanceof Element ? e.parentNode.namespaceURI ?? null : null
2320
2327
  );
2321
- return we(t, i, r), e.parentNode?.replaceChild(i, e), i;
2328
+ return we(t, o, r), e.parentNode?.replaceChild(o, e), o;
2322
2329
  }
2323
2330
  function Ut(e, n, t, s) {
2324
2331
  let r;
@@ -2330,14 +2337,14 @@ function Ut(e, n, t, s) {
2330
2337
  },
2331
2338
  children: [r]
2332
2339
  }), r = qe(r, String(r.key ?? "root"));
2333
- const i = e._prevVNode ?? null, o = e._prevDom ?? e.firstChild ?? null;
2340
+ const o = e._prevVNode ?? null, i = e._prevDom ?? e.firstChild ?? null;
2334
2341
  let c;
2335
- i && o ? typeof i != "string" && typeof r != "string" && i.tag === r.tag && i.key === r.key ? c = Te(o, i, r, t, s) : (c = Z(
2342
+ o && i ? typeof o != "string" && typeof r != "string" && o.tag === r.tag && o.key === r.key ? c = Te(i, o, r, t, s) : (c = Z(
2336
2343
  r,
2337
2344
  t,
2338
2345
  s,
2339
2346
  e.host instanceof Element ? e.host.namespaceURI ?? null : null
2340
- ), e.replaceChild(c, o)) : (c = Z(
2347
+ ), e.replaceChild(c, i)) : (c = Z(
2341
2348
  r,
2342
2349
  t,
2343
2350
  s,
@@ -2358,16 +2365,16 @@ function Vt(e, n) {
2358
2365
  const t = Ne.get(e);
2359
2366
  t && t.delete(n);
2360
2367
  }
2361
- function qt(e, n, t, s, r, i, o, c) {
2368
+ function qt(e, n, t, s, r, o, i, c) {
2362
2369
  if (e) {
2363
2370
  Le.push(t);
2364
2371
  try {
2365
2372
  const f = n.render(t);
2366
2373
  if (f instanceof Promise) {
2367
- i(!0), f.then((u) => {
2368
- i(!1), o(null), it(e, u, t, s, r), c(e.innerHTML);
2374
+ o(!0), f.then((u) => {
2375
+ o(!1), i(null), it(e, u, t, s, r), c(e.innerHTML);
2369
2376
  }).catch((u) => {
2370
- i(!1), o(u);
2377
+ o(!1), i(u);
2371
2378
  });
2372
2379
  return;
2373
2380
  }
@@ -2385,8 +2392,8 @@ function it(e, n, t, s, r) {
2385
2392
  s
2386
2393
  ), r(e.innerHTML));
2387
2394
  }
2388
- function Gt(e, n, t, s, r, i, o) {
2389
- if (i !== null && clearTimeout(i), Date.now() - n < 16) {
2395
+ function Gt(e, n, t, s, r, o, i) {
2396
+ if (o !== null && clearTimeout(o), Date.now() - n < 16) {
2390
2397
  if (r(t + 1), t === 15)
2391
2398
  Q(
2392
2399
  `⚠️ Component is re-rendering rapidly. This might indicate:
@@ -2402,76 +2409,76 @@ function Gt(e, n, t, s, r, i, o) {
2402
2409
  • This might be caused by state updates during render
2403
2410
  • Ensure all state modifications are done in event handlers or effects
2404
2411
  Stopping runaway component render to prevent browser freeze`
2405
- ), o(null);
2412
+ ), i(null);
2406
2413
  return;
2407
2414
  }
2408
2415
  } else
2409
2416
  r(0);
2410
2417
  const u = setTimeout(
2411
2418
  () => {
2412
- s(Date.now()), e(), o(null);
2419
+ s(Date.now()), e(), i(null);
2413
2420
  },
2414
2421
  t > 10 ? 100 : 0
2415
2422
  );
2416
- o(u);
2423
+ i(u);
2417
2424
  }
2418
2425
  function Zt(e, n, t, s, r) {
2419
2426
  if (!e) return;
2420
- let i = t || "";
2427
+ let o = t || "";
2421
2428
  try {
2422
- const b = Ne.get(e);
2423
- if (b && b.size > 0)
2424
- for (const h of b)
2429
+ const h = Ne.get(e);
2430
+ if (h && h.size > 0)
2431
+ for (const y of h)
2425
2432
  try {
2426
- const d = h.lastHtmlStringForJitCSS;
2427
- d && typeof d == "string" && d.trim() && (i += `
2428
- ` + d);
2433
+ const p = y.lastHtmlStringForJitCSS;
2434
+ p && typeof p == "string" && p.trim() && (o += `
2435
+ ` + p);
2429
2436
  } catch {
2430
2437
  }
2431
2438
  else {
2432
- const h = Array.from(
2439
+ const y = Array.from(
2433
2440
  e.querySelectorAll("*")
2434
2441
  );
2435
- for (const d of h)
2442
+ for (const p of y)
2436
2443
  try {
2437
- const _ = d.lastHtmlStringForJitCSS;
2438
- _ && typeof _ == "string" && _.trim() && (i += `
2444
+ const _ = p.lastHtmlStringForJitCSS;
2445
+ _ && typeof _ == "string" && _.trim() && (o += `
2439
2446
  ` + _);
2440
2447
  } catch {
2441
2448
  }
2442
2449
  }
2443
2450
  } catch {
2444
2451
  }
2445
- if (st.get(e) === i)
2452
+ if (st.get(e) === o)
2446
2453
  return;
2447
- st.set(e, i);
2448
- const c = St(i), f = vt();
2454
+ st.set(e, o);
2455
+ const c = St(o), f = vt();
2449
2456
  if ((!c || c.trim() === "") && !n._computedStyle && !f) {
2450
2457
  if (r(null), "adoptedStyleSheets" in e && typeof CSSStyleSheet < "u") {
2451
- const h = [je(), pe()];
2452
- e.adoptedStyleSheets = h;
2458
+ const y = [$e(), pe()];
2459
+ e.adoptedStyleSheets = y;
2453
2460
  } else {
2454
- const h = ke(et), d = pe();
2461
+ const y = ke(et), p = pe();
2455
2462
  let _ = "";
2456
2463
  try {
2457
- d && "cssRules" in d && (_ = Array.from(d.cssRules).map((y) => y.cssText).join(`
2464
+ p && "cssRules" in p && (_ = Array.from(p.cssRules).map((d) => d.cssText).join(`
2458
2465
  `));
2459
2466
  } catch {
2460
2467
  _ = "";
2461
2468
  }
2462
- const T = ke(`${h}
2469
+ const E = ke(`${y}
2463
2470
  ${_}`);
2464
- let L = e.querySelector(
2471
+ let T = e.querySelector(
2465
2472
  "style[data-cer-runtime]"
2466
2473
  );
2467
- L || (L = document.createElement("style"), D(L, "data-cer-runtime", "true"), e.appendChild(L));
2474
+ T || (T = document.createElement("style"), D(T, "data-cer-runtime", "true"), e.appendChild(T));
2468
2475
  try {
2469
- L.textContent = T;
2476
+ T.textContent = E;
2470
2477
  } catch {
2471
2478
  }
2472
2479
  try {
2473
- const y = [je(), pe()];
2474
- e.adoptedStyleSheets = y;
2480
+ const d = [$e(), pe()];
2481
+ e.adoptedStyleSheets = d;
2475
2482
  } catch {
2476
2483
  }
2477
2484
  }
@@ -2483,56 +2490,56 @@ ${_}`);
2483
2490
  ${c}
2484
2491
  `);
2485
2492
  S = ke(S);
2486
- let E = s;
2493
+ let b = s;
2487
2494
  if ("adoptedStyleSheets" in e && typeof CSSStyleSheet < "u") {
2488
- E || (E = new CSSStyleSheet());
2495
+ b || (b = new CSSStyleSheet());
2489
2496
  try {
2490
- E.replaceSync(S);
2497
+ b.replaceSync(S);
2491
2498
  } catch {
2492
- E = null;
2499
+ b = null;
2493
2500
  }
2494
- if (E) {
2495
- const b = [je(), pe()];
2496
- f && b.push(f), b.push(E), e.adoptedStyleSheets = b, r(E);
2501
+ if (b) {
2502
+ const h = [$e(), pe()];
2503
+ f && h.push(f), h.push(b), e.adoptedStyleSheets = h, r(b);
2497
2504
  return;
2498
2505
  }
2499
2506
  }
2500
- const w = ke(et), p = pe();
2501
- let v = "";
2507
+ const C = ke(et), w = pe();
2508
+ let L = "";
2502
2509
  try {
2503
- p && "cssRules" in p && (v = Array.from(p.cssRules).map((b) => b.cssText).join(`
2510
+ w && "cssRules" in w && (L = Array.from(w.cssRules).map((h) => h.cssText).join(`
2504
2511
  `));
2505
2512
  } catch {
2506
- v = "";
2513
+ L = "";
2507
2514
  }
2508
- const a = ke(`${w}
2509
- ${v}
2515
+ const a = ke(`${C}
2516
+ ${L}
2510
2517
  ${S}`);
2511
- let C = e.querySelector(
2518
+ let v = e.querySelector(
2512
2519
  "style[data-cer-runtime]"
2513
2520
  );
2514
- C || (C = document.createElement("style"), D(C, "data-cer-runtime", "true"), e.appendChild(C));
2521
+ v || (v = document.createElement("style"), D(v, "data-cer-runtime", "true"), e.appendChild(v));
2515
2522
  try {
2516
- C.textContent = a;
2523
+ v.textContent = a;
2517
2524
  } catch {
2518
2525
  }
2519
2526
  try {
2520
- const b = [
2521
- je(),
2527
+ const h = [
2528
+ $e(),
2522
2529
  pe()
2523
2530
  ];
2524
- if (f && b.push(f), typeof CSSStyleSheet < "u")
2531
+ if (f && h.push(f), typeof CSSStyleSheet < "u")
2525
2532
  try {
2526
- const h = new CSSStyleSheet();
2533
+ const y = new CSSStyleSheet();
2527
2534
  try {
2528
- h.replaceSync(S), b.push(h);
2535
+ y.replaceSync(S), h.push(y);
2529
2536
  } catch {
2530
- b.push({ cssRules: [], replaceSync: () => {
2537
+ h.push({ cssRules: [], replaceSync: () => {
2531
2538
  } });
2532
2539
  }
2533
2540
  } catch {
2534
2541
  }
2535
- e.adoptedStyleSheets = b;
2542
+ e.adoptedStyleSheets = h;
2536
2543
  } catch {
2537
2544
  }
2538
2545
  r(null);
@@ -2602,31 +2609,31 @@ function dn(e) {
2602
2609
  const t = B;
2603
2610
  try {
2604
2611
  const r = Object.keys(e || {});
2605
- for (const i of r) {
2606
- if (typeof i != "string" || i.startsWith("_")) continue;
2607
- const o = Object.getOwnPropertyDescriptor(t, i);
2608
- if (!(o && !o.configurable))
2612
+ for (const o of r) {
2613
+ if (typeof o != "string" || o.startsWith("_")) continue;
2614
+ const i = Object.getOwnPropertyDescriptor(t, o);
2615
+ if (!(i && !i.configurable))
2609
2616
  try {
2610
- let f = Object.prototype.hasOwnProperty.call(t, i) ? t[i] : void 0;
2611
- Object.defineProperty(t, i, {
2617
+ let f = Object.prototype.hasOwnProperty.call(t, o) ? t[o] : void 0;
2618
+ Object.defineProperty(t, o, {
2612
2619
  configurable: !0,
2613
2620
  enumerable: !0,
2614
2621
  get() {
2615
2622
  try {
2616
2623
  const u = t && t._host;
2617
2624
  if (u) {
2618
- const S = J(i), E = u.getAttribute(S);
2619
- if (E !== null) {
2620
- const g = typeof e[i];
2621
- return g === "boolean" ? E === "" || E === "true" : g === "number" ? Number(E) : E;
2625
+ const S = J(o), b = u.getAttribute(S);
2626
+ if (b !== null) {
2627
+ const m = typeof e[o];
2628
+ return m === "boolean" ? b === "" || b === "true" : m === "number" ? Number(b) : b;
2622
2629
  }
2623
- if (typeof u[i] < "u") {
2624
- const g = u[i];
2625
- if (P(g) || g && typeof g == "object" && "value" in g && !(g instanceof Node))
2626
- return g.value;
2627
- const w = typeof e[i];
2628
- if (!(w === "string" && g && typeof g == "object"))
2629
- return w === "boolean" && typeof g == "string" ? g === "" || g === "true" : g;
2630
+ if (typeof u[o] < "u") {
2631
+ const m = u[o];
2632
+ if (M(m) || m && typeof m == "object" && "value" in m && !(m instanceof Node))
2633
+ return m.value;
2634
+ const C = typeof e[o];
2635
+ if (!(C === "string" && m && typeof m == "object"))
2636
+ return C === "boolean" && typeof m == "string" ? m === "" || m === "true" : m;
2630
2637
  }
2631
2638
  }
2632
2639
  } catch {
@@ -2643,31 +2650,31 @@ function dn(e) {
2643
2650
  } catch {
2644
2651
  }
2645
2652
  return new Proxy({}, {
2646
- get(r, i) {
2647
- if (typeof i != "string") return;
2648
- const o = e[i];
2653
+ get(r, o) {
2654
+ if (typeof o != "string") return;
2655
+ const i = e[o];
2649
2656
  try {
2650
2657
  const f = t && t._host;
2651
2658
  if (f) {
2652
2659
  if (f instanceof HTMLElement || typeof f.getAttribute == "function" && typeof f.hasAttribute == "function") {
2653
- const S = i.replace(/([A-Z])/g, "-$1").toLowerCase(), E = f.getAttribute(S);
2654
- if (E !== null)
2655
- return typeof o == "boolean" ? E === "" || E === "true" : typeof o == "number" ? Number(E) : E;
2660
+ const S = o.replace(/([A-Z])/g, "-$1").toLowerCase(), b = f.getAttribute(S);
2661
+ if (b !== null)
2662
+ return typeof i == "boolean" ? b === "" || b === "true" : typeof i == "number" ? Number(b) : b;
2656
2663
  }
2657
- const u = f[i];
2664
+ const u = f[o];
2658
2665
  if (typeof u < "u" && u !== "") {
2659
2666
  const S = u && typeof u == "object" && "value" in u && !(u instanceof Node);
2660
- if (!(typeof o == "string" && u && typeof u == "object" && !S && !P(u)))
2661
- return typeof o == "boolean" && o === !1 && u === "" ? o : P(u) || S ? u.value : typeof o == "boolean" && typeof u == "string" ? u === "true" || u !== "" && u !== "false" : typeof o == "number" && typeof u == "string" && !Number.isNaN(Number(u)) ? Number(u) : u;
2667
+ if (!(typeof i == "string" && u && typeof u == "object" && !S && !M(u)))
2668
+ return typeof i == "boolean" && i === !1 && u === "" ? i : M(u) || S ? u.value : typeof i == "boolean" && typeof u == "string" ? u === "true" || u !== "" && u !== "false" : typeof i == "number" && typeof u == "string" && !Number.isNaN(Number(u)) ? Number(u) : u;
2662
2669
  }
2663
2670
  }
2664
2671
  } catch {
2665
2672
  }
2666
- const c = t[i];
2667
- return typeof o == "boolean" && c === "" ? o === !1 ? o : !0 : P(c) || c && typeof c == "object" && "value" in c && !(c instanceof Node) ? c.value : c != null && c !== "" ? typeof o == "boolean" && typeof c == "string" ? c === "true" : typeof o == "number" && typeof c == "string" && !Number.isNaN(Number(c)) ? Number(c) : c : o;
2673
+ const c = t[o];
2674
+ return typeof i == "boolean" && c === "" ? i === !1 ? i : !0 : M(c) || c && typeof c == "object" && "value" in c && !(c instanceof Node) ? c.value : c != null && c !== "" ? typeof i == "boolean" && typeof c == "string" ? c === "true" : typeof i == "number" && typeof c == "string" && !Number.isNaN(Number(c)) ? Number(c) : c : i;
2668
2675
  },
2669
- has(r, i) {
2670
- return typeof i == "string" && (i in t || i in e);
2676
+ has(r, o) {
2677
+ return typeof o == "string" && (o in t || o in e);
2671
2678
  },
2672
2679
  ownKeys() {
2673
2680
  return Array.from(
@@ -2751,8 +2758,8 @@ function Yt(e, n) {
2751
2758
  _templateError = null;
2752
2759
  constructor() {
2753
2760
  super(), this.attachShadow({ mode: "open" }), this._cfg = be.get(e) || n, this._componentId = `${e}-${Math.random().toString(36).substr(2, 9)}`;
2754
- const t = this._initContext(n), s = (i, o, c) => {
2755
- Object.defineProperty(i, o, {
2761
+ const t = this._initContext(n), s = (o, i, c) => {
2762
+ Object.defineProperty(o, i, {
2756
2763
  value: c,
2757
2764
  writable: !1,
2758
2765
  enumerable: !1,
@@ -2770,47 +2777,47 @@ function Yt(e, n) {
2770
2777
  ), s(t, "_componentId", this._componentId), s(
2771
2778
  t,
2772
2779
  "_triggerWatchers",
2773
- (i, o) => this._triggerWatchers(i, o)
2780
+ (o, i) => this._triggerWatchers(o, i)
2774
2781
  ), this.context = t, H(() => {
2775
2782
  s(t, "_host", this);
2776
2783
  }), s(
2777
2784
  this.context,
2778
2785
  "emit",
2779
- (i, o, c) => {
2786
+ (o, i, c) => {
2780
2787
  const f = {
2781
- detail: o,
2788
+ detail: i,
2782
2789
  bubbles: !0,
2783
2790
  composed: !0,
2784
2791
  ...c || {}
2785
- }, u = new CustomEvent(i, f);
2792
+ }, u = new CustomEvent(o, f);
2786
2793
  this.dispatchEvent(u);
2787
- const S = i.indexOf(":");
2794
+ const S = o.indexOf(":");
2788
2795
  if (S > 0) {
2789
- const E = i.substring(0, S), g = i.substring(S + 1), w = g.includes("-") ? `${E}:${g.split("-").map(
2790
- (p, v) => v === 0 ? p : p.charAt(0).toUpperCase() + p.slice(1)
2791
- ).join("")}` : `${E}:${g.replace(/([a-z0-9])([A-Z])/g, "$1-$2").toLowerCase()}`;
2792
- w !== i && H(() => {
2793
- this.dispatchEvent(new CustomEvent(w, f));
2796
+ const b = o.substring(0, S), m = o.substring(S + 1), C = m.includes("-") ? `${b}:${m.split("-").map(
2797
+ (w, L) => L === 0 ? w : w.charAt(0).toUpperCase() + w.slice(1)
2798
+ ).join("")}` : `${b}:${m.replace(/([a-z0-9])([A-Z])/g, "$1-$2").toLowerCase()}`;
2799
+ C !== o && H(() => {
2800
+ this.dispatchEvent(new CustomEvent(C, f));
2794
2801
  });
2795
2802
  }
2796
2803
  return !u.defaultPrevented;
2797
2804
  }
2798
2805
  );
2799
2806
  const r = be.get(e) || n;
2800
- for (const i in r) {
2801
- const o = r[i];
2802
- typeof o == "function" && (this.context[i] = (...c) => o(...c, this.context));
2807
+ for (const o in r) {
2808
+ const i = r[o];
2809
+ typeof i == "function" && (this.context[o] = (...c) => i(...c, this.context));
2803
2810
  }
2804
2811
  if (r.props)
2805
- for (const i in r.props) {
2806
- let o = this[i];
2807
- Object.defineProperty(this, i, {
2812
+ for (const o in r.props) {
2813
+ let i = this[o];
2814
+ Object.defineProperty(this, o, {
2808
2815
  get() {
2809
- return o;
2816
+ return i;
2810
2817
  },
2811
2818
  set(c) {
2812
- const f = o;
2813
- o = c, this.context[i] = c, this._initializing || (this._applyProps(r), f !== c && this._requestRender());
2819
+ const f = i;
2820
+ i = c, this.context[o] = c, this._initializing || (this._applyProps(r), f !== c && this._requestRender());
2814
2821
  },
2815
2822
  enumerable: !0,
2816
2823
  configurable: !0
@@ -2926,7 +2933,7 @@ function Yt(e, n) {
2926
2933
  } catch (r) {
2927
2934
  this._hasError = !0;
2928
2935
  try {
2929
- const i = this.tagName?.toLowerCase?.() || "<unknown>", o = this._componentId || "<unknown-id>", c = {};
2936
+ const o = this.tagName?.toLowerCase?.() || "<unknown>", i = this._componentId || "<unknown-id>", c = {};
2930
2937
  if (t && t.props)
2931
2938
  for (const f of Object.keys(t.props))
2932
2939
  try {
@@ -2935,7 +2942,7 @@ function Yt(e, n) {
2935
2942
  } catch {
2936
2943
  c[f] = "[unreadable]";
2937
2944
  }
2938
- W(`Error rendering component <${i}> (id=${o}):`, r), W("Component props snapshot:", c), Q(
2945
+ W(`Error rendering component <${o}> (id=${i}):`, r), W("Component props snapshot:", c), Q(
2939
2946
  "Common causes: accessing properties of null/undefined inside template interpolations; expensive or throwing expressions inside templates that evaluate eagerly. Fixes: use optional chaining (obj?.prop), guard with ternary, or use the runtime lazy overload: when(cond, () => html`...`)."
2940
2947
  );
2941
2948
  } catch {
@@ -2946,9 +2953,9 @@ function Yt(e, n) {
2946
2953
  // --- State, props, computed ---
2947
2954
  _initContext(t) {
2948
2955
  try {
2949
- let s = function(i, o = "") {
2950
- if (Array.isArray(i))
2951
- return new Proxy(i, {
2956
+ let s = function(o, i = "") {
2957
+ if (Array.isArray(o))
2958
+ return new Proxy(o, {
2952
2959
  get(c, f, u) {
2953
2960
  const S = Reflect.get(c, f, u);
2954
2961
  return typeof S == "function" && typeof f == "string" && [
@@ -2959,43 +2966,43 @@ function Yt(e, n) {
2959
2966
  "splice",
2960
2967
  "sort",
2961
2968
  "reverse"
2962
- ].includes(f) ? function(...g) {
2963
- const w = S.apply(c, g);
2969
+ ].includes(f) ? function(...m) {
2970
+ const C = S.apply(c, m);
2964
2971
  if (!r._initializing) {
2965
- const p = o || "root";
2966
- r._triggerWatchers(p, c), Ce(
2972
+ const w = i || "root";
2973
+ r._triggerWatchers(w, c), Ce(
2967
2974
  () => r._render(t),
2968
2975
  r._componentId
2969
2976
  );
2970
2977
  }
2971
- return w;
2978
+ return C;
2972
2979
  } : S;
2973
2980
  },
2974
2981
  set(c, f, u) {
2975
2982
  if (c[String(f)] = u, !r._initializing) {
2976
- const S = o ? `${o}.${String(f)}` : String(f);
2983
+ const S = i ? `${i}.${String(f)}` : String(f);
2977
2984
  r._triggerWatchers(S, u), Ce(() => r._render(t), r._componentId);
2978
2985
  }
2979
2986
  return !0;
2980
2987
  },
2981
2988
  deleteProperty(c, f) {
2982
2989
  if (delete c[String(f)], !r._initializing) {
2983
- const u = o ? `${o}.${String(f)}` : String(f);
2990
+ const u = i ? `${i}.${String(f)}` : String(f);
2984
2991
  r._triggerWatchers(u, void 0), Ce(() => r._render(t), r._componentId);
2985
2992
  }
2986
2993
  return !0;
2987
2994
  }
2988
2995
  });
2989
- if (i && typeof i == "object") {
2990
- if (P(i))
2991
- return i;
2992
- for (const c in i) {
2993
- const f = o ? `${o}.${c}` : c;
2994
- i[c] = s(i[c], f);
2996
+ if (o && typeof o == "object") {
2997
+ if (M(o))
2998
+ return o;
2999
+ for (const c in o) {
3000
+ const f = i ? `${i}.${c}` : c;
3001
+ o[c] = s(o[c], f);
2995
3002
  }
2996
- return new Proxy(i, {
3003
+ return new Proxy(o, {
2997
3004
  set(c, f, u) {
2998
- const S = o ? `${o}.${String(f)}` : String(f);
3005
+ const S = i ? `${i}.${String(f)}` : String(f);
2999
3006
  return c[String(f)] = s(u, S), r._initializing || (r._triggerWatchers(
3000
3007
  S,
3001
3008
  c[String(f)]
@@ -3006,16 +3013,16 @@ function Yt(e, n) {
3006
3013
  }
3007
3014
  });
3008
3015
  }
3009
- return i;
3016
+ return o;
3010
3017
  };
3011
3018
  const r = this;
3012
3019
  return s({
3013
3020
  // For functional components, state is managed by state() function calls
3014
3021
  // Include prop defaults in initial reactive context so prop updates trigger reactivity
3015
3022
  ...t.props ? Object.fromEntries(
3016
- Object.entries(t.props).map(([i, o]) => [
3017
- i,
3018
- o.default
3023
+ Object.entries(t.props).map(([o, i]) => [
3024
+ o,
3025
+ i.default
3019
3026
  ])
3020
3027
  ) : {}
3021
3028
  });
@@ -3055,47 +3062,47 @@ function yn(e, n) {
3055
3062
  // Props are accessed via useProps() hook
3056
3063
  props: {},
3057
3064
  // Add lifecycle hooks from the stored functions
3058
- onConnected: (i) => {
3065
+ onConnected: (o) => {
3059
3066
  if (s.onConnected)
3060
3067
  try {
3061
- s.onConnected(i);
3068
+ s.onConnected(o);
3062
3069
  } catch {
3063
3070
  }
3064
3071
  },
3065
- onDisconnected: (i) => {
3072
+ onDisconnected: (o) => {
3066
3073
  if (s.onDisconnected)
3067
3074
  try {
3068
- s.onDisconnected(i);
3075
+ s.onDisconnected(o);
3069
3076
  } catch {
3070
3077
  }
3071
3078
  },
3072
- onAttributeChanged: (i, o, c, f) => {
3079
+ onAttributeChanged: (o, i, c, f) => {
3073
3080
  if (s.onAttributeChanged)
3074
3081
  try {
3075
- s.onAttributeChanged(i, o, c, f);
3082
+ s.onAttributeChanged(o, i, c, f);
3076
3083
  } catch {
3077
3084
  }
3078
3085
  },
3079
- onError: (i, o) => {
3080
- if (s.onError && i)
3086
+ onError: (o, i) => {
3087
+ if (s.onError && o)
3081
3088
  try {
3082
- s.onError(i, o);
3089
+ s.onError(o, i);
3083
3090
  } catch {
3084
3091
  }
3085
3092
  },
3086
- render: (i) => {
3087
- const o = i, c = o._componentId || `${t}-${Math.random().toString(36).substr(2, 9)}`;
3093
+ render: (o) => {
3094
+ const i = o, c = i._componentId || `${t}-${Math.random().toString(36).substr(2, 9)}`;
3088
3095
  Xe.setCurrentComponent(c, () => {
3089
- i.requestRender && i.requestRender();
3096
+ o.requestRender && o.requestRender();
3090
3097
  });
3091
3098
  try {
3092
- ot(i);
3099
+ ot(o);
3093
3100
  let f;
3094
3101
  try {
3095
3102
  f = n();
3096
3103
  } catch (u) {
3097
3104
  try {
3098
- const S = o._hookCallbacks;
3105
+ const S = i._hookCallbacks;
3099
3106
  if (S && typeof S.onError == "function")
3100
3107
  try {
3101
3108
  S.onError(u);
@@ -3105,14 +3112,14 @@ function yn(e, n) {
3105
3112
  }
3106
3113
  throw u;
3107
3114
  }
3108
- if (o._hookCallbacks) {
3109
- const u = o._hookCallbacks;
3110
- if (u.onConnected && (s.onConnected = u.onConnected), u.onDisconnected && (s.onDisconnected = u.onDisconnected), u.onAttributeChanged && (s.onAttributeChanged = u.onAttributeChanged), u.onError && (s.onError = u.onError), u.style && (o._styleCallback = u.style), u.props) {
3115
+ if (i._hookCallbacks) {
3116
+ const u = i._hookCallbacks;
3117
+ if (u.onConnected && (s.onConnected = u.onConnected), u.onDisconnected && (s.onDisconnected = u.onDisconnected), u.onAttributeChanged && (s.onAttributeChanged = u.onAttributeChanged), u.onError && (s.onError = u.onError), u.style && (i._styleCallback = u.style), u.props) {
3111
3118
  const S = u.props;
3112
3119
  r.props = Object.fromEntries(
3113
- Object.entries(S).map(([E, g]) => [
3114
- E,
3115
- { type: typeof g == "boolean" ? Boolean : typeof g == "number" ? Number : typeof g == "string" ? String : Function, default: g }
3120
+ Object.entries(S).map(([b, m]) => [
3121
+ b,
3122
+ { type: typeof m == "boolean" ? Boolean : typeof m == "number" ? Number : typeof m == "string" ? String : Function, default: m }
3116
3123
  ])
3117
3124
  ), be.set(t, r);
3118
3125
  }
@@ -3125,7 +3132,7 @@ function yn(e, n) {
3125
3132
  };
3126
3133
  if (be.set(t, r), typeof window < "u") {
3127
3134
  try {
3128
- const i = {
3135
+ const o = {
3129
3136
  _hookCallbacks: {},
3130
3137
  requestRender: () => {
3131
3138
  },
@@ -3135,31 +3142,31 @@ function yn(e, n) {
3135
3142
  // instances will have a proper emit implementation.
3136
3143
  emit: () => !0
3137
3144
  };
3138
- ot(i);
3145
+ ot(o);
3139
3146
  try {
3140
3147
  n();
3141
- } catch (o) {
3148
+ } catch (i) {
3142
3149
  try {
3143
- const c = i?._hookCallbacks;
3150
+ const c = o?._hookCallbacks;
3144
3151
  if (c && typeof c.onError == "function")
3145
3152
  try {
3146
- c.onError(o);
3153
+ c.onError(i);
3147
3154
  } catch {
3148
3155
  }
3149
3156
  W(
3150
3157
  `Error during component discovery render <${t}>:`,
3151
- o
3158
+ i
3152
3159
  ), Q(
3153
3160
  "Error occurred during initial component discovery render. Consider guarding expensive expressions or using lazy factories for directives like when()."
3154
3161
  );
3155
3162
  } catch {
3156
3163
  }
3157
- throw Ke(), o;
3164
+ throw Ke(), i;
3158
3165
  }
3159
- if (Ke(), i._hookCallbacks?.props) {
3160
- const o = i._hookCallbacks.props;
3166
+ if (Ke(), o._hookCallbacks?.props) {
3167
+ const i = o._hookCallbacks.props;
3161
3168
  r.props = Object.fromEntries(
3162
- Object.entries(o).map(([c, f]) => [
3169
+ Object.entries(i).map(([c, f]) => [
3163
3170
  c,
3164
3171
  { type: typeof f == "boolean" ? Boolean : typeof f == "number" ? Number : typeof f == "string" ? String : Function, default: f }
3165
3172
  ])
@@ -3225,21 +3232,21 @@ function en(e, n) {
3225
3232
  return e.key != null ? e : { ...e, key: n };
3226
3233
  }
3227
3234
  function tn(e, n = [], t = {}) {
3228
- const s = {}, r = {}, i = {}, o = [], c = /([:@#]?)([a-zA-Z0-9-:.]+)(?:\s*=\s*("([^"\\]*(\\.[^"\\]*)*)"|'([^'\\]*(\\.[^'\\]*)*)'|([^\s>]+)))?/g;
3235
+ const s = {}, r = {}, o = {}, i = [], c = /([:@#]?)([a-zA-Z0-9-:.]+)(?:\s*=\s*("([^"\\]*(\\.[^"\\]*)*)"|'([^'\\]*(\\.[^'\\]*)*)'|([^\s>]+)))?/g;
3229
3236
  let f;
3230
3237
  for (; f = c.exec(e); ) {
3231
3238
  const u = f[1], S = f[2];
3232
- let E = "";
3239
+ let b = "";
3233
3240
  for (let a = 3; a < f.length; a++)
3234
3241
  if (f[a] !== void 0) {
3235
- E = f[a];
3242
+ b = f[a];
3236
3243
  break;
3237
3244
  }
3238
- E.length >= 2 && (E[0] === '"' && E[E.length - 1] === '"' || E[0] === "'" && E[E.length - 1] === "'") && (E = E.slice(1, -1));
3239
- const g = !/=/.test(f[0]), w = E.match(/^{{(\d+)}}$/);
3240
- let p = g ? !0 : w ? n[Number(w[1])] ?? null : E;
3241
- w || (p === "true" ? p = !0 : p === "false" ? p = !1 : p === "null" ? p = null : isNaN(Number(p)) || (p = Number(p)));
3242
- const v = [
3245
+ b.length >= 2 && (b[0] === '"' && b[b.length - 1] === '"' || b[0] === "'" && b[b.length - 1] === "'") && (b = b.slice(1, -1));
3246
+ const m = !/=/.test(f[0]), C = b.match(/^{{(\d+)}}$/);
3247
+ let w = m ? !0 : C ? n[Number(C[1])] ?? null : b;
3248
+ C || (w === "true" ? w = !0 : w === "false" ? w = !1 : w === "null" ? w = null : isNaN(Number(w)) || (w = Number(w)));
3249
+ const L = [
3243
3250
  "model",
3244
3251
  "bind",
3245
3252
  "show",
@@ -3249,66 +3256,66 @@ function tn(e, n = [], t = {}) {
3249
3256
  "when"
3250
3257
  ];
3251
3258
  if (u === ":") {
3252
- const [a, C] = S.split(":"), [b, ...h] = a.split(".");
3253
- if (v.includes(b)) {
3254
- const d = [...h], _ = b === "model" && C ? `model:${C}` : b;
3255
- i[_] = {
3256
- value: p,
3257
- modifiers: d,
3258
- arg: C
3259
+ const [a, v] = S.split(":"), [h, ...y] = a.split(".");
3260
+ if (L.includes(h)) {
3261
+ const p = [...y], _ = h === "model" && v ? `model:${v}` : h;
3262
+ o[_] = {
3263
+ value: w,
3264
+ modifiers: p,
3265
+ arg: v
3259
3266
  };
3260
3267
  } else if (S === "disabled") {
3261
- let d = p;
3262
- d && P(d) && (d = d.value);
3263
- const _ = typeof d;
3264
- if (d === "" || _ === "boolean" || _ === "string" && (d === "true" || d === "false") || d == null || _ === "number")
3265
- s[S] = d;
3268
+ let p = w;
3269
+ p && M(p) && (p = p.value);
3270
+ const _ = typeof p;
3271
+ if (p === "" || _ === "boolean" || _ === "string" && (p === "true" || p === "false") || p == null || _ === "number")
3272
+ s[S] = p;
3266
3273
  else {
3267
- let y = p;
3268
- y && P(y) && (y = y.value), r[S] = y;
3274
+ let d = w;
3275
+ d && M(d) && (d = d.value), r[S] = d;
3269
3276
  }
3270
- o.push(S);
3277
+ i.push(S);
3271
3278
  } else {
3272
- let d = p;
3273
- d && P(d) && (d = d.value), r[S] = d, o.push(S);
3279
+ let p = w;
3280
+ p && M(p) && (p = p.value), r[S] = p, i.push(S);
3274
3281
  }
3275
3282
  } else if (u === "@") {
3276
- const [a, ...C] = S.split("."), b = C;
3277
- Qt(p, a);
3278
- const h = typeof p == "function" ? p : typeof t[p] == "function" ? t[p] : void 0;
3279
- if (h) {
3280
- const d = (T) => {
3281
- if (b.includes("prevent") && T.preventDefault(), b.includes("stop") && T.stopPropagation(), !(b.includes("self") && T.target !== T.currentTarget))
3282
- return b.includes("once") && T.currentTarget?.removeEventListener(
3283
+ const [a, ...v] = S.split("."), h = v;
3284
+ Qt(w, a);
3285
+ const y = typeof w == "function" ? w : typeof t[w] == "function" ? t[w] : void 0;
3286
+ if (y) {
3287
+ const p = (E) => {
3288
+ if (h.includes("prevent") && E.preventDefault(), h.includes("stop") && E.stopPropagation(), !(h.includes("self") && E.target !== E.currentTarget))
3289
+ return h.includes("once") && E.currentTarget?.removeEventListener(
3283
3290
  a,
3284
- d
3285
- ), h(T);
3291
+ p
3292
+ ), y(E);
3286
3293
  }, _ = "on" + a.charAt(0).toUpperCase() + a.slice(1);
3287
- s[_] = d;
3294
+ s[_] = p;
3288
3295
  }
3289
- } else S === "ref" ? s.ref = p : r[S] = p;
3296
+ } else S === "ref" ? s.ref = w : r[S] = w;
3290
3297
  }
3291
- return { props: s, attrs: r, directives: i, bound: o };
3298
+ return { props: s, attrs: r, directives: o, bound: i };
3292
3299
  }
3293
3300
  function Ge(e) {
3294
3301
  if (!fe(e) || Oe(e))
3295
3302
  return e;
3296
3303
  const n = e.props?.directives;
3297
3304
  if (n && n.when) {
3298
- const t = n.when.value, s = P(t) ? t.value : t, r = { ...n };
3305
+ const t = n.when.value, s = M(t) ? t.value : t, r = { ...n };
3299
3306
  delete r.when;
3300
- const i = { ...e.props };
3301
- Object.keys(r).length > 0 ? i.directives = r : delete i.directives;
3302
- const o = {
3307
+ const o = { ...e.props };
3308
+ Object.keys(r).length > 0 ? o.directives = r : delete o.directives;
3309
+ const i = {
3303
3310
  ...e,
3304
- props: i
3311
+ props: o
3305
3312
  };
3306
- return Array.isArray(o.children) && (o.children = o.children.map(
3313
+ return Array.isArray(i.children) && (i.children = i.children.map(
3307
3314
  (f) => typeof f == "object" && f !== null ? Ge(f) : f
3308
3315
  )), {
3309
3316
  tag: "#anchor",
3310
3317
  key: e.key != null ? `when-${e.key}` : `when-${e.tag}`,
3311
- children: s ? [o] : []
3318
+ children: s ? [i] : []
3312
3319
  };
3313
3320
  }
3314
3321
  if (Array.isArray(e.children)) {
@@ -3323,62 +3330,62 @@ function Ge(e) {
3323
3330
  return e;
3324
3331
  }
3325
3332
  function nn(e, n, t) {
3326
- const s = Le.length > 0 ? Le[Le.length - 1] : void 0, r = t ?? s, i = !t && n.length === 0, o = i ? e.join("<!--TEMPLATE_DELIM-->") : null;
3327
- if (i && o) {
3328
- const l = Ue.get(o);
3333
+ const s = Le.length > 0 ? Le[Le.length - 1] : void 0, r = t ?? s, o = !t && n.length === 0, i = o ? e.join("<!--TEMPLATE_DELIM-->") : null;
3334
+ if (o && i) {
3335
+ const l = Ue.get(i);
3329
3336
  if (l) return l;
3330
3337
  }
3331
- function c(l, m) {
3332
- return oe("#text", {}, l, m);
3338
+ function c(l, g) {
3339
+ return oe("#text", {}, l, g);
3333
3340
  }
3334
- function f(l, m, A = !1) {
3341
+ function f(l, g, A = !1) {
3335
3342
  let N = typeof l == "string" ? Et(l) : l;
3336
- return !A && typeof N == "string" && /[\r\n]/.test(N) && (N = N.replace(/\s+/g, " ")), oe("#text", {}, N, m);
3343
+ return !A && typeof N == "string" && /[\r\n]/.test(N) && (N = N.replace(/\s+/g, " ")), oe("#text", {}, N, g);
3337
3344
  }
3338
3345
  let u = "";
3339
3346
  for (let l = 0; l < e.length; l++)
3340
3347
  u += e[l], l < n.length && (u += `{{${l}}}`);
3341
- const S = /<!--[\s\S]*?-->|<\/?([a-zA-Z0-9-]+)((?:\s+[^\s=>/]+(?:\s*=\s*(?:"(?:\\.|[^"])*"|'(?:\\.|[^'])*'|[^\s>]+))?)*)\s*\/?>|{{(\d+)}}|([^<]+)/g, E = [];
3342
- let g, w = [], p = null, v = {}, a, C = 0;
3343
- const b = [], h = /* @__PURE__ */ new Set([
3348
+ const S = /<!--[\s\S]*?-->|<\/?([a-zA-Z0-9-]+)((?:\s+[^\s=>/]+(?:\s*=\s*(?:"(?:\\.|[^"])*"|'(?:\\.|[^'])*'|[^\s>]+))?)*)\s*\/?>|{{(\d+)}}|([^<]+)/g, b = [];
3349
+ let m, C = [], w = null, L = {}, a, v = 0;
3350
+ const h = [], y = /* @__PURE__ */ new Set([
3344
3351
  "pre",
3345
3352
  "code",
3346
3353
  "textarea",
3347
3354
  "script",
3348
3355
  "style"
3349
3356
  ]);
3350
- function d() {
3351
- if (p && h.has(p.toLowerCase()))
3357
+ function p() {
3358
+ if (w && y.has(w.toLowerCase()))
3352
3359
  return !0;
3353
- for (const l of E)
3354
- if (h.has(l.tag.toLowerCase()))
3360
+ for (const l of b)
3361
+ if (y.has(l.tag.toLowerCase()))
3355
3362
  return !0;
3356
3363
  return !1;
3357
3364
  }
3358
3365
  function _(l) {
3359
3366
  if (!l || typeof l != "object" || Oe(l)) return;
3360
- const m = l, A = v;
3361
- if (m.props || m.attrs) {
3362
- const N = m;
3367
+ const g = l, A = L;
3368
+ if (g.props || g.attrs) {
3369
+ const N = g;
3363
3370
  N.props && (A.props || (A.props = {}), Object.assign(A.props, N.props)), N.attrs && (A.attrs || (A.attrs = {}), Object.keys(N.attrs).forEach((O) => {
3364
3371
  if (O === "style" && A.attrs.style) {
3365
- const $ = String(A.attrs.style).replace(/;?\s*$/, ""), R = String(N.attrs.style).replace(/^;?\s*/, "");
3366
- A.attrs.style = $ + "; " + R;
3372
+ const j = String(A.attrs.style).replace(/;?\s*$/, ""), R = String(N.attrs.style).replace(/^;?\s*/, "");
3373
+ A.attrs.style = j + "; " + R;
3367
3374
  } else if (O === "class" && A.attrs.class) {
3368
- const $ = String(A.attrs.class).trim().split(/\s+/).filter(Boolean), R = String(N.attrs.class).trim().split(/\s+/).filter(Boolean), M = [
3369
- .../* @__PURE__ */ new Set([...$, ...R])
3375
+ const j = String(A.attrs.class).trim().split(/\s+/).filter(Boolean), R = String(N.attrs.class).trim().split(/\s+/).filter(Boolean), P = [
3376
+ .../* @__PURE__ */ new Set([...j, ...R])
3370
3377
  ];
3371
- A.attrs.class = M.join(" ");
3378
+ A.attrs.class = P.join(" ");
3372
3379
  } else
3373
3380
  A.attrs[O] = N.attrs[O];
3374
3381
  }));
3375
3382
  } else
3376
- A.props || (A.props = {}), Object.assign(A.props, m);
3383
+ A.props || (A.props = {}), Object.assign(A.props, g);
3377
3384
  }
3378
- function T(l, m) {
3379
- const A = p ? w : b;
3385
+ function E(l, g) {
3386
+ const A = w ? C : h;
3380
3387
  if (Oe(l)) {
3381
- const N = l.key ?? m, O = l.children;
3388
+ const N = l.key ?? g, O = l.children;
3382
3389
  A.push({
3383
3390
  ...l,
3384
3391
  key: N,
@@ -3394,29 +3401,29 @@ function nn(e, n, t) {
3394
3401
  if (l.length === 0) return;
3395
3402
  for (let N = 0; N < l.length; N++) {
3396
3403
  const O = l[N];
3397
- Oe(O) || fe(O) || Array.isArray(O) ? T(O, `${m}-${N}`) : O !== null && typeof O == "object" ? Qe(O) ? A.push(
3404
+ Oe(O) || fe(O) || Array.isArray(O) ? E(O, `${g}-${N}`) : O !== null && typeof O == "object" ? Qe(O) ? A.push(
3398
3405
  oe(
3399
3406
  "#raw",
3400
3407
  {},
3401
3408
  O.__rawHTML,
3402
- `${m}-${N}`
3409
+ `${g}-${N}`
3403
3410
  )
3404
- ) : _(O) : A.push(c(String(O), `${m}-${N}`));
3411
+ ) : _(O) : A.push(c(String(O), `${g}-${N}`));
3405
3412
  }
3406
3413
  return;
3407
3414
  }
3408
3415
  if (l !== null && typeof l == "object") {
3409
3416
  if (Qe(l)) {
3410
3417
  const N = l.__rawHTML ?? "";
3411
- A.push(oe("#raw", {}, N, m));
3418
+ A.push(oe("#raw", {}, N, g));
3412
3419
  return;
3413
3420
  }
3414
3421
  _(l);
3415
3422
  return;
3416
3423
  }
3417
- A.push(c(String(l), m));
3424
+ A.push(c(String(l), g));
3418
3425
  }
3419
- const L = /* @__PURE__ */ new Set([
3426
+ const T = /* @__PURE__ */ new Set([
3420
3427
  "area",
3421
3428
  "base",
3422
3429
  "br",
@@ -3432,23 +3439,23 @@ function nn(e, n, t) {
3432
3439
  "track",
3433
3440
  "wbr"
3434
3441
  ]);
3435
- for (; g = S.exec(u); )
3436
- if (!(g[0].startsWith("<!--") && g[0].endsWith("-->"))) {
3437
- if (g[1]) {
3438
- const l = g[1], m = g[0][1] === "/", A = g[0][g[0].length - 2] === "/" || L.has(l), {
3442
+ for (; m = S.exec(u); )
3443
+ if (!(m[0].startsWith("<!--") && m[0].endsWith("-->"))) {
3444
+ if (m[1]) {
3445
+ const l = m[1], g = m[0][1] === "/", A = m[0][m[0].length - 2] === "/" || T.has(l), {
3439
3446
  props: N,
3440
3447
  attrs: O,
3441
- directives: $,
3448
+ directives: j,
3442
3449
  bound: R
3443
3450
  } = tn(
3444
- g[2] || "",
3451
+ m[2] || "",
3445
3452
  n,
3446
3453
  r ?? {}
3447
- ), M = { props: {}, attrs: {} };
3448
- for (const K in N) M.props[K] = N[K];
3449
- for (const K in O) M.attrs[K] = O[K];
3450
- M.attrs && Object.prototype.hasOwnProperty.call(M.attrs, "key") && !(M.props && Object.prototype.hasOwnProperty.call(M.props, "key")) && H(() => {
3451
- M.props.key = M.attrs.key;
3454
+ ), P = { props: {}, attrs: {} };
3455
+ for (const K in N) P.props[K] = N[K];
3456
+ for (const K in O) P.attrs[K] = O[K];
3457
+ P.attrs && Object.prototype.hasOwnProperty.call(P.attrs, "key") && !(P.props && Object.prototype.hasOwnProperty.call(P.props, "key")) && H(() => {
3458
+ P.props.key = P.attrs.key;
3452
3459
  });
3453
3460
  try {
3454
3461
  const K = {
@@ -3476,84 +3483,84 @@ function nn(e, n, t) {
3476
3483
  img: ["src", "alt", "width", "height"],
3477
3484
  button: ["type", "name", "value", "autofocus", "form"]
3478
3485
  }, I = l.toLowerCase(), ie = K[I] ?? [];
3479
- if (M.attrs) {
3486
+ if (P.attrs) {
3480
3487
  for (const x of ie)
3481
- if (R && R.includes(x) && x in M.attrs && !(M.props && x in M.props)) {
3482
- let j = M.attrs[x];
3483
- if (j && P(j))
3484
- j = j.value, M.props[x] = j, delete M.attrs[x];
3485
- else if (j && typeof j == "object" && "value" in j && !(j instanceof Node))
3488
+ if (R && R.includes(x) && x in P.attrs && !(P.props && x in P.props)) {
3489
+ let $ = P.attrs[x];
3490
+ if ($ && M($))
3491
+ $ = $.value, P.props[x] = $, delete P.attrs[x];
3492
+ else if ($ && typeof $ == "object" && "value" in $ && !($ instanceof Node))
3486
3493
  try {
3487
- const z = j.value;
3488
- M.props[x] = (I === "select" || I === "option") && x === "value" ? String(z) : z, delete M.attrs[x];
3494
+ const z = $.value;
3495
+ P.props[x] = (I === "select" || I === "option") && x === "value" ? String(z) : z, delete P.attrs[x];
3489
3496
  } catch {
3490
3497
  }
3491
3498
  else {
3492
- const z = typeof j;
3499
+ const z = typeof $;
3493
3500
  if (x === "disabled")
3494
- (j === "" || z === "boolean" || z === "string" && (j === "true" || j === "false") || j == null || z === "number") && (M.props[x] = j, delete M.attrs[x]);
3495
- else if (j === "" || z === "string" || z === "number" || z === "boolean" || j == null) {
3496
- const ee = (I === "select" || I === "option") && x === "value" ? String(j) : j;
3497
- M.props[x] = ee, delete M.attrs[x];
3501
+ ($ === "" || z === "boolean" || z === "string" && ($ === "true" || $ === "false") || $ == null || z === "number") && (P.props[x] = $, delete P.attrs[x]);
3502
+ else if ($ === "" || z === "string" || z === "number" || z === "boolean" || $ == null) {
3503
+ const ee = (I === "select" || I === "option") && x === "value" ? String($) : $;
3504
+ P.props[x] = ee, delete P.attrs[x];
3498
3505
  }
3499
3506
  }
3500
3507
  }
3501
3508
  }
3502
3509
  if (l.includes("-") || !!r?.__customElements?.has?.(l)) {
3503
- if (M.isCustomElement = !0, R && M.attrs) {
3510
+ if (P.isCustomElement = !0, R && P.attrs) {
3504
3511
  const x = /* @__PURE__ */ new Set(["id", "name", "data-key", "key"]);
3505
- for (const j of R)
3506
- if (j in M.attrs && !(M.props && j in M.props)) {
3507
- const z = j.includes("-") ? Ze(j) : j, ee = M.attrs[j];
3508
- if (M.props[z] = ee, x.has(j) || at(j))
3512
+ for (const $ of R)
3513
+ if ($ in P.attrs && !(P.props && $ in P.props)) {
3514
+ const z = $.includes("-") ? Ze($) : $, ee = P.attrs[$];
3515
+ if (P.props[z] = ee, x.has($) || at($))
3509
3516
  try {
3510
- const Pe = F(M.attrs[j]);
3511
- Pe === null ? delete M.attrs[j] : M.attrs[j] = Pe;
3517
+ const Me = F(P.attrs[$]);
3518
+ Me === null ? delete P.attrs[$] : P.attrs[$] = Me;
3512
3519
  } catch {
3513
- delete M.attrs[j];
3520
+ delete P.attrs[$];
3514
3521
  }
3515
3522
  else
3516
- delete M.attrs[j];
3523
+ delete P.attrs[$];
3517
3524
  }
3518
3525
  }
3519
3526
  try {
3520
- if (M.attrs && !(M.props && "modelValue" in M.props)) {
3521
- const x = M.attrs["model-value"] ?? M.attrs.modelValue;
3522
- typeof x < "u" && (M.props.modelValue = x);
3527
+ if (P.attrs && !(P.props && "modelValue" in P.props)) {
3528
+ const x = P.attrs["model-value"] ?? P.attrs.modelValue;
3529
+ typeof x < "u" && (P.props.modelValue = x);
3523
3530
  }
3524
3531
  } catch {
3525
3532
  }
3526
3533
  }
3527
3534
  } catch {
3528
3535
  }
3529
- if ($ && Object.keys($).some(
3536
+ if (j && Object.keys(j).some(
3530
3537
  (K) => K === "model" || K.startsWith("model:")
3531
3538
  ))
3532
3539
  try {
3533
3540
  const K = Symbol.for("cer.registry"), I = globalThis[K], ie = !!(I && typeof I.has == "function" && I.has(l)), Y = r, x = !!(Y && (Y.__customElements instanceof Set && Y.__customElements.has(l) || Array.isArray(Y.__isCustomElements) && Y.__isCustomElements.includes(l)));
3534
3541
  if (!!(l.includes("-") || x || ie))
3535
- for (const ee of Object.keys($)) {
3542
+ for (const ee of Object.keys(j)) {
3536
3543
  if (ee !== "model" && !ee.startsWith("model:")) continue;
3537
- const $e = $[ee], Pe = $e.arg ?? (ee.includes(":") ? ee.split(":", 2)[1] : void 0), V = $e.value, Be = Pe ?? "modelValue", Je = U, ht = Re, Se = r?._state || r;
3544
+ const je = j[ee], Me = je.arg ?? (ee.includes(":") ? ee.split(":", 2)[1] : void 0), V = je.value, Be = Me ?? "modelValue", Je = U, ht = Re, Se = r?._state || r;
3538
3545
  let re;
3539
3546
  typeof V == "string" && Se ? re = Je(
3540
3547
  Se,
3541
3548
  V
3542
- ) : re = V, M.props[Be] = re;
3549
+ ) : re = V, P.props[Be] = re;
3543
3550
  try {
3544
3551
  const ce = J(Be);
3545
- M.attrs || (M.attrs = {}), re != null && (typeof re == "string" || typeof re == "number" || typeof re == "boolean") && (M.attrs[ce] = re);
3552
+ P.attrs || (P.attrs = {}), re != null && (typeof re == "string" || typeof re == "number" || typeof re == "boolean") && (P.attrs[ce] = re);
3546
3553
  } catch {
3547
3554
  }
3548
- M.isCustomElement = !0;
3555
+ P.isCustomElement = !0;
3549
3556
  const Ye = `update:${J(Be)}`.replace(
3550
3557
  /-([a-z])/g,
3551
3558
  (ce, ne) => ne.toUpperCase()
3552
3559
  ), yt = "on" + Ye.charAt(0).toUpperCase() + Ye.slice(1);
3553
- M.props[yt] = function(ce) {
3560
+ P.props[yt] = function(ce) {
3554
3561
  const ne = ce.detail !== void 0 ? ce.detail : ce.target ? ce.target.value : void 0;
3555
3562
  if (Se)
3556
- if (V && P(V)) {
3563
+ if (V && M(V)) {
3557
3564
  const ae = V.value;
3558
3565
  if (Array.isArray(ne) && Array.isArray(ae) ? JSON.stringify([...ne].sort()) !== JSON.stringify([...ae].sort()) : ne !== ae) {
3559
3566
  V.value = ne;
@@ -3587,72 +3594,72 @@ function nn(e, n, t) {
3587
3594
  }
3588
3595
  }
3589
3596
  }
3590
- }, delete $[ee];
3597
+ }, delete j[ee];
3591
3598
  }
3592
3599
  } catch {
3593
3600
  }
3594
- if (Object.keys($).length > 0 && (M.directives = { ...$ }), m) {
3595
- const K = w.some(
3601
+ if (Object.keys(j).length > 0 && (P.directives = { ...j }), g) {
3602
+ const K = C.some(
3596
3603
  (x) => typeof x == "object" && x.tag !== "#text"
3597
3604
  );
3598
- let I = w;
3599
- if (K && w.length > 0) {
3605
+ let I = C;
3606
+ if (K && C.length > 0) {
3600
3607
  let x = 0;
3601
- for (; x < w.length; ) {
3602
- const z = w[x];
3608
+ for (; x < C.length; ) {
3609
+ const z = C[x];
3603
3610
  if (!fe(z) || z.tag !== "#text" || typeof z.children != "string" || z.children.trim() !== "")
3604
3611
  break;
3605
3612
  x++;
3606
3613
  }
3607
- let j = w.length - 1;
3608
- for (; j >= 0; ) {
3609
- const z = w[j];
3614
+ let $ = C.length - 1;
3615
+ for (; $ >= 0; ) {
3616
+ const z = C[$];
3610
3617
  if (!fe(z) || z.tag !== "#text" || typeof z.children != "string" || z.children.trim() !== "")
3611
3618
  break;
3612
- j--;
3619
+ $--;
3613
3620
  }
3614
- x === 0 && j === w.length - 1 ? I = w : x > j ? I = [] : I = w.slice(x, j + 1);
3621
+ x === 0 && $ === C.length - 1 ? I = C : x > $ ? I = [] : I = C.slice(x, $ + 1);
3615
3622
  }
3616
3623
  const ie = oe(
3617
- p,
3618
- v,
3624
+ w,
3625
+ L,
3619
3626
  I.length === 1 && fe(I[0]) && I[0].tag === "#text" ? typeof I[0].children == "string" ? I[0].children : "" : I.length ? I : void 0,
3620
3627
  a
3621
- ), Y = E.pop();
3622
- Y ? (p = Y.tag, v = Y.props, a = Y.key, w = Y.children, w.push(ie)) : (b.push(ie), p = null, v = {}, a = void 0, w = []);
3623
- } else A ? p ? w.push(oe(l, M, void 0, void 0)) : b.push(oe(l, M, void 0, void 0)) : (p && E.push({
3624
- tag: p,
3625
- props: v,
3626
- children: w,
3628
+ ), Y = b.pop();
3629
+ Y ? (w = Y.tag, L = Y.props, a = Y.key, C = Y.children, C.push(ie)) : (h.push(ie), w = null, L = {}, a = void 0, C = []);
3630
+ } else A ? w ? C.push(oe(l, P, void 0, void 0)) : h.push(oe(l, P, void 0, void 0)) : (w && b.push({
3631
+ tag: w,
3632
+ props: L,
3633
+ children: C,
3627
3634
  key: a
3628
- }), p = l, v = M, w = []);
3629
- } else if (typeof g[3] < "u") {
3630
- const l = Number(g[3]), m = n[l], A = `interp-${l}`;
3631
- T(m, A);
3632
- } else if (g[4]) {
3633
- const l = g[4], m = p ? w : b, A = l.split(/({{\d+}})/);
3635
+ }), w = l, L = P, C = []);
3636
+ } else if (typeof m[3] < "u") {
3637
+ const l = Number(m[3]), g = n[l], A = `interp-${l}`;
3638
+ E(g, A);
3639
+ } else if (m[4]) {
3640
+ const l = m[4], g = w ? C : h, A = l.split(/({{\d+}})/);
3634
3641
  for (const N of A) {
3635
3642
  if (!N) continue;
3636
3643
  const O = N.match(/^{{(\d+)}}$/);
3637
3644
  if (O) {
3638
- const $ = Number(O[1]), R = n[$], M = `interp-${$}`;
3639
- T(R, M);
3645
+ const j = Number(O[1]), R = n[j], P = `interp-${j}`;
3646
+ E(R, P);
3640
3647
  } else {
3641
- const $ = `text-${C++}`, R = d();
3642
- m.push(f(N, $, R));
3648
+ const j = `text-${v++}`, R = p();
3649
+ g.push(f(N, j, R));
3643
3650
  }
3644
3651
  }
3645
3652
  }
3646
3653
  }
3647
- const k = b.filter((l) => fe(l) && l.tag === "#text" ? typeof l.children == "string" && l.children.trim() !== "" : !0).map(
3654
+ const k = h.filter((l) => fe(l) && l.tag === "#text" ? typeof l.children == "string" && l.children.trim() !== "" : !0).map(
3648
3655
  (l) => Ge(l)
3649
3656
  );
3650
3657
  if (k.length === 1) {
3651
3658
  const l = k[0];
3652
- return i && o && Ue.set(o, l), l;
3659
+ return o && i && Ue.set(i, l), l;
3653
3660
  } else if (k.length > 1) {
3654
3661
  const l = k;
3655
- return i && o && Ue.set(o, l), l;
3662
+ return o && i && Ue.set(i, l), l;
3656
3663
  }
3657
3664
  return oe("div", {}, "", "fallback-root");
3658
3665
  }