@tachui/data 0.8.12 → 0.8.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +16 -16
- package/dist/List.js +349 -346
- package/package.json +5 -5
package/dist/List.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
var m = (n, e, t) =>
|
|
4
|
-
import { withModifiers as
|
|
1
|
+
var Oe = Object.defineProperty;
|
|
2
|
+
var Pe = (n, e, t) => e in n ? Oe(n, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : n[e] = t;
|
|
3
|
+
var m = (n, e, t) => Pe(n, typeof e != "symbol" ? e + "" : e, t);
|
|
4
|
+
import { withModifiers as pe, ComponentWithCSSClasses as ke, processElementOverride as Le, h as w, text as De, clonePropsPreservingReactivity as me, resetLifecycleState as ge, createSignal as N, isSignal as S, createEffect as R } from "@tachui/core";
|
|
5
5
|
import "@tachui/modifiers";
|
|
6
6
|
const y = {
|
|
7
7
|
Clean: 0,
|
|
@@ -9,35 +9,35 @@ const y = {
|
|
|
9
9
|
Dirty: 2,
|
|
10
10
|
Disposed: 3
|
|
11
11
|
};
|
|
12
|
-
var
|
|
13
|
-
let
|
|
14
|
-
const
|
|
15
|
-
let
|
|
16
|
-
const
|
|
17
|
-
|
|
12
|
+
var ze = Object.defineProperty, _e = (n, e, t) => e in n ? ze(n, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : n[e] = t, O = (n, e, t) => _e(n, typeof e != "symbol" ? e + "" : e, t);
|
|
13
|
+
let He = 0;
|
|
14
|
+
const Ve = Math.random().toString(36).substr(2, 6);
|
|
15
|
+
let ye = null, ve = null;
|
|
16
|
+
const je = /* @__PURE__ */ new Set();
|
|
17
|
+
je.add(Ve);
|
|
18
18
|
const Q = {
|
|
19
19
|
get currentComputation() {
|
|
20
|
-
return
|
|
20
|
+
return ye;
|
|
21
21
|
},
|
|
22
22
|
set currentComputation(n) {
|
|
23
|
-
|
|
23
|
+
ye = n;
|
|
24
24
|
},
|
|
25
25
|
get currentOwner() {
|
|
26
|
-
return
|
|
26
|
+
return ve;
|
|
27
27
|
},
|
|
28
28
|
set currentOwner(n) {
|
|
29
|
-
|
|
29
|
+
ve = n;
|
|
30
30
|
}
|
|
31
31
|
};
|
|
32
|
-
function
|
|
32
|
+
function Ce() {
|
|
33
33
|
return Q.currentComputation;
|
|
34
34
|
}
|
|
35
|
-
function
|
|
35
|
+
function Ee() {
|
|
36
36
|
return Q.currentOwner;
|
|
37
37
|
}
|
|
38
|
-
|
|
38
|
+
class Ae {
|
|
39
39
|
constructor(e, t = null) {
|
|
40
|
-
O(this, "id"), O(this, "owner"), O(this, "fn"), O(this, "sources", /* @__PURE__ */ new Set()), O(this, "observers", /* @__PURE__ */ new Set()), O(this, "state", y.Dirty), O(this, "value"), this.id = ++
|
|
40
|
+
O(this, "id"), O(this, "owner"), O(this, "fn"), O(this, "sources", /* @__PURE__ */ new Set()), O(this, "observers", /* @__PURE__ */ new Set()), O(this, "state", y.Dirty), O(this, "value"), this.id = ++He, this.fn = e, this.owner = t, t && !t.disposed && t.sources.add(this);
|
|
41
41
|
}
|
|
42
42
|
execute() {
|
|
43
43
|
if (this.state === y.Disposed)
|
|
@@ -66,17 +66,17 @@ let Ee = class {
|
|
|
66
66
|
this.observers.clear(), this.owner && !this.owner.disposed && this.owner.sources.delete(this);
|
|
67
67
|
}
|
|
68
68
|
}
|
|
69
|
-
}
|
|
70
|
-
var
|
|
71
|
-
let
|
|
69
|
+
}
|
|
70
|
+
var Fe = Object.defineProperty, Be = (n, e, t) => e in n ? Fe(n, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : n[e] = t, re = (n, e, t) => Be(n, typeof e != "symbol" ? e + "" : e, t);
|
|
71
|
+
let We = 0, Ue = class {
|
|
72
72
|
constructor(e) {
|
|
73
|
-
re(this, "id"), re(this, "observers", /* @__PURE__ */ new Set()), re(this, "_value"), this.id = ++
|
|
73
|
+
re(this, "id"), re(this, "observers", /* @__PURE__ */ new Set()), re(this, "_value"), this.id = ++We, this._value = e;
|
|
74
74
|
}
|
|
75
75
|
/**
|
|
76
76
|
* Get the current value and track dependency
|
|
77
77
|
*/
|
|
78
78
|
getValue() {
|
|
79
|
-
const e =
|
|
79
|
+
const e = Ce();
|
|
80
80
|
return e && e.state !== y.Disposed && (this.observers.add(e), e.sources.add(this)), this._value;
|
|
81
81
|
}
|
|
82
82
|
/**
|
|
@@ -97,7 +97,7 @@ let Be = 0, We = class {
|
|
|
97
97
|
*/
|
|
98
98
|
notify() {
|
|
99
99
|
for (const e of this.observers)
|
|
100
|
-
e.state !== y.Disposed && (e.state = y.Dirty,
|
|
100
|
+
e.state !== y.Disposed && (e.state = y.Dirty, qe(e));
|
|
101
101
|
}
|
|
102
102
|
/**
|
|
103
103
|
* Remove an observer (cleanup)
|
|
@@ -119,10 +119,10 @@ let Be = 0, We = class {
|
|
|
119
119
|
};
|
|
120
120
|
const X = /* @__PURE__ */ new Set();
|
|
121
121
|
let J = !1;
|
|
122
|
-
function
|
|
123
|
-
X.add(n), !J && queueMicrotask(
|
|
122
|
+
function qe(n) {
|
|
123
|
+
X.add(n), !J && queueMicrotask(Qe);
|
|
124
124
|
}
|
|
125
|
-
function
|
|
125
|
+
function Qe() {
|
|
126
126
|
if (!J) {
|
|
127
127
|
J = !0;
|
|
128
128
|
try {
|
|
@@ -137,8 +137,8 @@ function qe() {
|
|
|
137
137
|
}
|
|
138
138
|
}
|
|
139
139
|
}
|
|
140
|
-
function
|
|
141
|
-
const e = new
|
|
140
|
+
function ce(n) {
|
|
141
|
+
const e = new Ue(n), t = e.getValue.bind(e);
|
|
142
142
|
t.peek = e.peek.bind(e);
|
|
143
143
|
const s = e.set.bind(e);
|
|
144
144
|
return Object.defineProperty(t, Symbol.for("tachui.signal"), {
|
|
@@ -149,14 +149,14 @@ function le(n) {
|
|
|
149
149
|
function F(n) {
|
|
150
150
|
return typeof n == "function" && Symbol.for("tachui.signal") in n;
|
|
151
151
|
}
|
|
152
|
-
const
|
|
153
|
-
var
|
|
154
|
-
let
|
|
152
|
+
const Ge = (n, e) => n === e;
|
|
153
|
+
var Ke = Object.defineProperty, Ye = (n, e, t) => e in n ? Ke(n, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : n[e] = t, A = (n, e, t) => Ye(n, typeof e != "symbol" ? e + "" : e, t), G = /* @__PURE__ */ ((n) => (n[n.Immediate = 0] = "Immediate", n[n.High = 1] = "High", n[n.Normal = 2] = "Normal", n[n.Low = 3] = "Low", n[n.Idle = 4] = "Idle", n))(G || {});
|
|
154
|
+
let Ze = class extends Error {
|
|
155
155
|
constructor(e, t, s) {
|
|
156
156
|
super(e), this.cause = t, this.node = s, this.name = "ReactiveError";
|
|
157
157
|
}
|
|
158
158
|
};
|
|
159
|
-
const
|
|
159
|
+
const Xe = class _ {
|
|
160
160
|
constructor() {
|
|
161
161
|
A(this, "updateQueues", /* @__PURE__ */ new Map()), A(this, "isFlushPending", !1), A(this, "isDestroyed", !1), A(this, "errorHandlers", /* @__PURE__ */ new Set()), A(this, "maxRetries", 3), A(this, "totalUpdateCycles", 0), A(this, "totalUpdateTime", 0), A(this, "errorCount", 0), A(this, "nodeRegistry", /* @__PURE__ */ new WeakSet());
|
|
162
162
|
for (const e of Object.values(G))
|
|
@@ -196,7 +196,7 @@ const Ze = class _ {
|
|
|
196
196
|
await this.updateNodeWithRetry(i);
|
|
197
197
|
} catch (o) {
|
|
198
198
|
this.handleReactiveError(
|
|
199
|
-
new
|
|
199
|
+
new Ze(`Failed to update ${i.type} node ${i.id}`, o, i)
|
|
200
200
|
);
|
|
201
201
|
}
|
|
202
202
|
if (this.hasHigherPriorityWork(t))
|
|
@@ -360,17 +360,17 @@ const Ze = class _ {
|
|
|
360
360
|
};
|
|
361
361
|
}
|
|
362
362
|
};
|
|
363
|
-
A(
|
|
364
|
-
var
|
|
365
|
-
let
|
|
366
|
-
constructor(e, t = {}, s =
|
|
367
|
-
super(e, s), L(this, "type", "computed"), L(this, "priority"), L(this, "_hasValue", !1), L(this, "_error", null), L(this, "equalsFn"), L(this, "options"), this.priority = t.priority ?? G.Normal, this.equalsFn = t.equals ??
|
|
363
|
+
A(Xe, "instance", null);
|
|
364
|
+
var Je = Object.defineProperty, et = (n, e, t) => e in n ? Je(n, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : n[e] = t, L = (n, e, t) => et(n, typeof e != "symbol" ? e + "" : e, t);
|
|
365
|
+
let tt = class extends Ae {
|
|
366
|
+
constructor(e, t = {}, s = Ee()) {
|
|
367
|
+
super(e, s), L(this, "type", "computed"), L(this, "priority"), L(this, "_hasValue", !1), L(this, "_error", null), L(this, "equalsFn"), L(this, "options"), this.priority = t.priority ?? G.Normal, this.equalsFn = t.equals ?? Ge, this.options = t;
|
|
368
368
|
}
|
|
369
369
|
/**
|
|
370
370
|
* Get the computed value, tracking dependency and lazily computing
|
|
371
371
|
*/
|
|
372
372
|
getValue() {
|
|
373
|
-
const e =
|
|
373
|
+
const e = Ce();
|
|
374
374
|
return e && e.state !== y.Disposed && (this.observers.add(e), e.sources.add(this)), (this.state === y.Dirty || !this._hasValue) && (this.execute(), this._hasValue = !0), this.value;
|
|
375
375
|
}
|
|
376
376
|
/**
|
|
@@ -447,8 +447,8 @@ let et = class extends Ee {
|
|
|
447
447
|
return `Computed(${this.options.debugName || this.id}): ${this._hasValue ? this.value : "no value"}`;
|
|
448
448
|
}
|
|
449
449
|
};
|
|
450
|
-
function
|
|
451
|
-
const t = new
|
|
450
|
+
function st(n, e) {
|
|
451
|
+
const t = new tt(n, e), s = t.getValue.bind(t);
|
|
452
452
|
return s.peek = t.peek.bind(t), Object.defineProperty(s, Symbol.for("tachui.computed"), {
|
|
453
453
|
value: t,
|
|
454
454
|
enumerable: !1
|
|
@@ -457,19 +457,19 @@ function tt(n, e) {
|
|
|
457
457
|
function B(n) {
|
|
458
458
|
return typeof n == "function" && Symbol.for("tachui.computed") in n;
|
|
459
459
|
}
|
|
460
|
-
const [
|
|
461
|
-
|
|
462
|
-
const n =
|
|
463
|
-
return n === "system" ?
|
|
460
|
+
const [rt, Ss] = ce("light");
|
|
461
|
+
st(() => {
|
|
462
|
+
const n = rt();
|
|
463
|
+
return n === "system" ? it() : n;
|
|
464
464
|
});
|
|
465
|
-
function
|
|
465
|
+
function it() {
|
|
466
466
|
return typeof window < "u" && window.matchMedia && window.matchMedia("(prefers-color-scheme: dark)").matches ? "dark" : "light";
|
|
467
467
|
}
|
|
468
468
|
typeof globalThis.__DEV__ > "u" && (globalThis.__DEV__ = process.env.NODE_ENV !== "production");
|
|
469
|
-
var
|
|
470
|
-
let
|
|
469
|
+
var nt = Object.defineProperty, ot = (n, e, t) => e in n ? nt(n, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : n[e] = t, be = (n, e, t) => ot(n, typeof e != "symbol" ? e + "" : e, t);
|
|
470
|
+
let at = class {
|
|
471
471
|
constructor() {
|
|
472
|
-
|
|
472
|
+
be(this, "pending", /* @__PURE__ */ new Set()), be(this, "isFlushScheduled", !1);
|
|
473
473
|
}
|
|
474
474
|
schedule(e) {
|
|
475
475
|
this.pending.add(e), this.isFlushScheduled || (this.isFlushScheduled = !0, queueMicrotask(() => this.flush()));
|
|
@@ -490,7 +490,7 @@ let ot = class {
|
|
|
490
490
|
this.pending.size > 0 && (this.isFlushScheduled = !0, queueMicrotask(() => this.flush()));
|
|
491
491
|
}
|
|
492
492
|
};
|
|
493
|
-
new
|
|
493
|
+
new at();
|
|
494
494
|
let ie = null;
|
|
495
495
|
const b = class b {
|
|
496
496
|
constructor() {
|
|
@@ -780,25 +780,25 @@ m(b, "instanceCount", 0), m(b, "FORBIDDEN_NAMES", /* @__PURE__ */ new Set([
|
|
|
780
780
|
"toString",
|
|
781
781
|
"valueOf"
|
|
782
782
|
])), m(b, "NAME_PATTERN", /^[a-zA-Z_$][a-zA-Z0-9_$]*$/);
|
|
783
|
-
let
|
|
784
|
-
function
|
|
785
|
-
return ie || (ie = new
|
|
783
|
+
let he = b;
|
|
784
|
+
function lt() {
|
|
785
|
+
return ie || (ie = new he()), ie;
|
|
786
786
|
}
|
|
787
|
-
const
|
|
787
|
+
const x = lt();
|
|
788
788
|
function T(n, e = {}) {
|
|
789
|
-
const t =
|
|
789
|
+
const t = Ee();
|
|
790
790
|
let s;
|
|
791
791
|
const r = () => {
|
|
792
792
|
const o = n(s);
|
|
793
793
|
return s = o, o;
|
|
794
|
-
}, i = new
|
|
794
|
+
}, i = new Ae(r, t);
|
|
795
795
|
return e.name && Object.defineProperty(i, "name", {
|
|
796
796
|
value: e.name,
|
|
797
797
|
enumerable: !1
|
|
798
798
|
}), i.execute(), i;
|
|
799
799
|
}
|
|
800
|
-
var
|
|
801
|
-
const
|
|
800
|
+
var ct = Object.defineProperty, ht = (n, e, t) => e in n ? ct(n, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : n[e] = t, dt = (n, e, t) => ht(n, e + "", t);
|
|
801
|
+
const ut = /* @__PURE__ */ new Set([
|
|
802
802
|
"onFocus",
|
|
803
803
|
"onBlur",
|
|
804
804
|
"onKeyDown",
|
|
@@ -818,11 +818,11 @@ const dt = /* @__PURE__ */ new Set([
|
|
|
818
818
|
"onSwipeLeft",
|
|
819
819
|
"onSwipeRight"
|
|
820
820
|
]);
|
|
821
|
-
function
|
|
822
|
-
return
|
|
821
|
+
function Me() {
|
|
822
|
+
return x;
|
|
823
823
|
}
|
|
824
824
|
function d(n, ...e) {
|
|
825
|
-
const t =
|
|
825
|
+
const t = Me().get(n);
|
|
826
826
|
if (t)
|
|
827
827
|
try {
|
|
828
828
|
return t.apply(null, e);
|
|
@@ -833,9 +833,9 @@ function d(n, ...e) {
|
|
|
833
833
|
`Modifier '${n}' not found in registry. Import @tachui/modifiers or @tachui/modifiers/effects to register modifiers.`
|
|
834
834
|
);
|
|
835
835
|
}
|
|
836
|
-
|
|
836
|
+
class pt {
|
|
837
837
|
constructor(e) {
|
|
838
|
-
this.component = e,
|
|
838
|
+
this.component = e, dt(this, "modifiers", []);
|
|
839
839
|
}
|
|
840
840
|
frame(e, t) {
|
|
841
841
|
let s;
|
|
@@ -1120,8 +1120,8 @@ This method is for internal framework use only.`
|
|
|
1120
1120
|
const e = this.component, t = Array.isArray(
|
|
1121
1121
|
e.modifiers
|
|
1122
1122
|
) ? [...e.modifiers] : [], s = this.modifiers.filter(
|
|
1123
|
-
(
|
|
1124
|
-
(h) => h ===
|
|
1123
|
+
(l) => !e.modifiers.some(
|
|
1124
|
+
(h) => h === l
|
|
1125
1125
|
// Reference equality check
|
|
1126
1126
|
)
|
|
1127
1127
|
), r = [...t, ...s], i = e._originalComponent || e;
|
|
@@ -1129,17 +1129,17 @@ This method is for internal framework use only.`
|
|
|
1129
1129
|
if (typeof i?.clone == "function")
|
|
1130
1130
|
o = i.clone();
|
|
1131
1131
|
else {
|
|
1132
|
-
const
|
|
1133
|
-
o = Object.create(
|
|
1132
|
+
const l = i && Object.getPrototypeOf(i) || Object.prototype;
|
|
1133
|
+
o = Object.create(l), Object.assign(o, i), o.props = { ...i.props }, o.cleanup = Array.isArray(i.cleanup) ? [...i.cleanup] : [], o.mounted = i.mounted ?? !1, o.id = i.id, o.type = i.type, o.render = typeof i.render == "function" ? i.render.bind(i) : () => [];
|
|
1134
1134
|
}
|
|
1135
|
-
const
|
|
1135
|
+
const a = te(
|
|
1136
1136
|
o,
|
|
1137
1137
|
r
|
|
1138
1138
|
);
|
|
1139
1139
|
return process.env.NODE_ENV === "test" && this.applyModifiersToPropsForTesting(
|
|
1140
|
-
|
|
1140
|
+
a,
|
|
1141
1141
|
r
|
|
1142
|
-
),
|
|
1142
|
+
), a;
|
|
1143
1143
|
} else {
|
|
1144
1144
|
const e = te(
|
|
1145
1145
|
this.component,
|
|
@@ -1160,11 +1160,11 @@ This method is for internal framework use only.`
|
|
|
1160
1160
|
if (i === "role")
|
|
1161
1161
|
e.props.role = o;
|
|
1162
1162
|
else {
|
|
1163
|
-
const
|
|
1164
|
-
e.props[
|
|
1163
|
+
const a = i.startsWith("aria-") ? i : `aria-${i}`;
|
|
1164
|
+
e.props[a] = typeof o == "boolean" ? o : String(o);
|
|
1165
1165
|
}
|
|
1166
1166
|
});
|
|
1167
|
-
} else if (
|
|
1167
|
+
} else if (ut.has(s.type)) {
|
|
1168
1168
|
const r = s.properties || {};
|
|
1169
1169
|
Object.entries(r).forEach(([i, o]) => {
|
|
1170
1170
|
typeof o == "function" && (e.props[i] = o);
|
|
@@ -1298,74 +1298,74 @@ This method is for internal framework use only.`
|
|
|
1298
1298
|
// Shadow and clipping modifiers moved to @tachui/modifiers
|
|
1299
1299
|
// Available via Proxy when @tachui/modifiers is imported:
|
|
1300
1300
|
// - shadow(), textShadow(), shadows(), shadowPreset(), clipped()
|
|
1301
|
-
}
|
|
1302
|
-
function
|
|
1303
|
-
const e = new
|
|
1301
|
+
}
|
|
1302
|
+
function ft(n) {
|
|
1303
|
+
const e = new pt(n);
|
|
1304
1304
|
return new Proxy(e, {
|
|
1305
1305
|
get(t, s, r) {
|
|
1306
1306
|
if (s in t) {
|
|
1307
1307
|
const i = t[s];
|
|
1308
1308
|
return typeof i == "function" ? function(...o) {
|
|
1309
|
-
const
|
|
1310
|
-
return
|
|
1309
|
+
const a = i.apply(r, o);
|
|
1310
|
+
return a === t ? r : a;
|
|
1311
1311
|
} : i;
|
|
1312
1312
|
}
|
|
1313
1313
|
if (typeof s == "string") {
|
|
1314
|
-
const i =
|
|
1314
|
+
const i = Me();
|
|
1315
1315
|
if (s === "responsive")
|
|
1316
1316
|
return function(...o) {
|
|
1317
|
-
const
|
|
1318
|
-
if (
|
|
1319
|
-
const
|
|
1320
|
-
this.addModifierInternal(
|
|
1317
|
+
const a = o[0];
|
|
1318
|
+
if (a) {
|
|
1319
|
+
const l = d(s, a);
|
|
1320
|
+
this.addModifierInternal(l);
|
|
1321
1321
|
}
|
|
1322
1322
|
return r;
|
|
1323
1323
|
};
|
|
1324
1324
|
if (s === "base" || s === "sm" || s === "md" || s === "lg" || s === "xl" || s === "2xl")
|
|
1325
1325
|
return new Proxy({}, {
|
|
1326
|
-
get(o,
|
|
1327
|
-
if (typeof
|
|
1328
|
-
return (...
|
|
1329
|
-
const h = { [
|
|
1326
|
+
get(o, a) {
|
|
1327
|
+
if (typeof a == "string")
|
|
1328
|
+
return (...l) => {
|
|
1329
|
+
const h = { [a]: { [s]: l[0] } }, c = d("responsive", h);
|
|
1330
1330
|
return t.addModifierInternal(c), r;
|
|
1331
1331
|
};
|
|
1332
1332
|
}
|
|
1333
1333
|
});
|
|
1334
1334
|
if (i.has(s))
|
|
1335
1335
|
return function(...o) {
|
|
1336
|
-
const
|
|
1337
|
-
return this.addModifierInternal(
|
|
1336
|
+
const a = d(s, ...o);
|
|
1337
|
+
return this.addModifierInternal(a), r;
|
|
1338
1338
|
};
|
|
1339
1339
|
}
|
|
1340
1340
|
}
|
|
1341
1341
|
});
|
|
1342
1342
|
}
|
|
1343
|
-
class
|
|
1343
|
+
class mt {
|
|
1344
1344
|
register(e, t) {
|
|
1345
|
-
|
|
1345
|
+
x.register(e, t);
|
|
1346
1346
|
}
|
|
1347
1347
|
get(e) {
|
|
1348
|
-
return
|
|
1348
|
+
return x.get(e);
|
|
1349
1349
|
}
|
|
1350
1350
|
has(e) {
|
|
1351
|
-
return
|
|
1351
|
+
return x.has(e);
|
|
1352
1352
|
}
|
|
1353
1353
|
list() {
|
|
1354
|
-
return
|
|
1354
|
+
return x.list();
|
|
1355
1355
|
}
|
|
1356
1356
|
clear() {
|
|
1357
|
-
|
|
1357
|
+
x.clear();
|
|
1358
1358
|
}
|
|
1359
1359
|
validateRegistry() {
|
|
1360
|
-
return
|
|
1360
|
+
return x.validateRegistry();
|
|
1361
1361
|
}
|
|
1362
1362
|
}
|
|
1363
|
-
const V = new
|
|
1363
|
+
const V = new mt();
|
|
1364
1364
|
process.env.NODE_ENV === "development" && console.log("📤 Created RegistryAdapter for globalModifierRegistry", {
|
|
1365
|
-
registryId:
|
|
1366
|
-
currentSize:
|
|
1365
|
+
registryId: x.instanceId,
|
|
1366
|
+
currentSize: x.list().length
|
|
1367
1367
|
});
|
|
1368
|
-
function
|
|
1368
|
+
function Ie(n, e, t = {}, s = {}) {
|
|
1369
1369
|
if (!e.length) return n;
|
|
1370
1370
|
const r = {
|
|
1371
1371
|
componentId: t.componentId || "unknown",
|
|
@@ -1381,51 +1381,51 @@ function Me(n, e, t = {}, s = {}) {
|
|
|
1381
1381
|
};
|
|
1382
1382
|
switch (s.batch ? "batch" : "sequential") {
|
|
1383
1383
|
case "batch":
|
|
1384
|
-
return
|
|
1384
|
+
return yt(n, e, r, s);
|
|
1385
1385
|
default:
|
|
1386
|
-
return
|
|
1386
|
+
return gt(n, e, r, s);
|
|
1387
1387
|
}
|
|
1388
1388
|
}
|
|
1389
|
-
function
|
|
1389
|
+
function gt(n, e, t, s) {
|
|
1390
1390
|
const r = [...e].sort(
|
|
1391
|
-
(
|
|
1391
|
+
(l, h) => l.priority - h.priority
|
|
1392
1392
|
);
|
|
1393
1393
|
let i = n;
|
|
1394
|
-
const o = [],
|
|
1395
|
-
for (const
|
|
1394
|
+
const o = [], a = [];
|
|
1395
|
+
for (const l of r)
|
|
1396
1396
|
try {
|
|
1397
|
-
const h =
|
|
1397
|
+
const h = l.apply(i, t);
|
|
1398
1398
|
h && typeof h == "object" && "type" in h && (i = h), s.immediate && !s.suppressEffects && (o.forEach((c) => c()), o.length = 0);
|
|
1399
1399
|
} catch (h) {
|
|
1400
|
-
console.error(`Failed to apply modifier ${
|
|
1400
|
+
console.error(`Failed to apply modifier ${l.type}:`, h);
|
|
1401
1401
|
}
|
|
1402
|
-
if (
|
|
1403
|
-
const
|
|
1402
|
+
if (a.length > 0) {
|
|
1403
|
+
const l = i.dispose;
|
|
1404
1404
|
i.dispose = () => {
|
|
1405
|
-
|
|
1405
|
+
a.forEach((h) => h()), l && l();
|
|
1406
1406
|
};
|
|
1407
1407
|
}
|
|
1408
1408
|
return i;
|
|
1409
1409
|
}
|
|
1410
|
-
function
|
|
1411
|
-
const r =
|
|
1410
|
+
function yt(n, e, t, s) {
|
|
1411
|
+
const r = vt(e);
|
|
1412
1412
|
let i = n;
|
|
1413
|
-
const o = [],
|
|
1414
|
-
for (const [
|
|
1413
|
+
const o = [], a = [];
|
|
1414
|
+
for (const [l, h] of r)
|
|
1415
1415
|
try {
|
|
1416
|
-
i =
|
|
1416
|
+
i = bt(i, h, t);
|
|
1417
1417
|
} catch (c) {
|
|
1418
|
-
(typeof process > "u" || process.env.NODE_ENV !== "test") && console.error(`Failed to apply modifier group ${
|
|
1418
|
+
(typeof process > "u" || process.env.NODE_ENV !== "test") && console.error(`Failed to apply modifier group ${l}:`, c);
|
|
1419
1419
|
}
|
|
1420
|
-
if (s.suppressEffects || o.forEach((
|
|
1421
|
-
const
|
|
1420
|
+
if (s.suppressEffects || o.forEach((l) => l()), a.length > 0) {
|
|
1421
|
+
const l = i.dispose;
|
|
1422
1422
|
i.dispose = () => {
|
|
1423
|
-
|
|
1423
|
+
a.forEach((h) => h()), l && l();
|
|
1424
1424
|
};
|
|
1425
1425
|
}
|
|
1426
1426
|
return i;
|
|
1427
1427
|
}
|
|
1428
|
-
function
|
|
1428
|
+
function vt(n) {
|
|
1429
1429
|
const e = /* @__PURE__ */ new Map();
|
|
1430
1430
|
for (const t of n) {
|
|
1431
1431
|
const s = e.get(t.type) || [];
|
|
@@ -1433,7 +1433,7 @@ function yt(n) {
|
|
|
1433
1433
|
}
|
|
1434
1434
|
return e;
|
|
1435
1435
|
}
|
|
1436
|
-
function
|
|
1436
|
+
function bt(n, e, t) {
|
|
1437
1437
|
const s = [...e].sort(
|
|
1438
1438
|
(i, o) => i.priority - o.priority
|
|
1439
1439
|
);
|
|
@@ -1447,7 +1447,7 @@ function vt(n, e, t) {
|
|
|
1447
1447
|
}
|
|
1448
1448
|
return r;
|
|
1449
1449
|
}
|
|
1450
|
-
function
|
|
1450
|
+
function St(n) {
|
|
1451
1451
|
return n && typeof n.concat == "function" && typeof n.toSegment == "function" && typeof n.isConcatenatable == "function";
|
|
1452
1452
|
}
|
|
1453
1453
|
function te(n, e = []) {
|
|
@@ -1465,7 +1465,7 @@ function te(n, e = []) {
|
|
|
1465
1465
|
// Store reference to original component for modifier context
|
|
1466
1466
|
_originalComponent: n
|
|
1467
1467
|
};
|
|
1468
|
-
t.modifierBuilder =
|
|
1468
|
+
t.modifierBuilder = ft(
|
|
1469
1469
|
t
|
|
1470
1470
|
), t.modifier = t.modifierBuilder, Object.prototype.hasOwnProperty.call(n, "modifier") || Object.defineProperty(n, "modifier", {
|
|
1471
1471
|
configurable: !0,
|
|
@@ -1479,8 +1479,8 @@ function te(n, e = []) {
|
|
|
1479
1479
|
const r = n.render ? n.render.bind(n) : () => [];
|
|
1480
1480
|
return t.render = () => {
|
|
1481
1481
|
const i = r();
|
|
1482
|
-
return (Array.isArray(i) ? i : [i]).map((o,
|
|
1483
|
-
},
|
|
1482
|
+
return (Array.isArray(i) ? i : [i]).map((o, a) => (o && typeof o == "object" && (a === 0 ? (o.modifiers = [...t.modifiers], o.componentId = n.id, o._originalComponent = t._originalComponent) : (o.modifiers && delete o.modifiers, o.componentId && o.componentId === n.id && delete o.componentId)), o));
|
|
1483
|
+
}, St(n) && (t.concat = function(i) {
|
|
1484
1484
|
const o = {
|
|
1485
1485
|
id: t.id,
|
|
1486
1486
|
component: t,
|
|
@@ -1489,7 +1489,7 @@ function te(n, e = []) {
|
|
|
1489
1489
|
const h = t.render();
|
|
1490
1490
|
return Array.isArray(h) ? h[0] : h;
|
|
1491
1491
|
}
|
|
1492
|
-
},
|
|
1492
|
+
}, a = i.toSegment(), l = {
|
|
1493
1493
|
totalSegments: i instanceof Y ? i.segments.length + 1 : 2,
|
|
1494
1494
|
accessibilityRole: "text",
|
|
1495
1495
|
// Simplified for now
|
|
@@ -1498,8 +1498,8 @@ function te(n, e = []) {
|
|
|
1498
1498
|
};
|
|
1499
1499
|
return i instanceof Y ? new Y(
|
|
1500
1500
|
[o, ...i.segments],
|
|
1501
|
-
|
|
1502
|
-
) : new Y([o,
|
|
1501
|
+
l
|
|
1502
|
+
) : new Y([o, a], l);
|
|
1503
1503
|
}, t.toSegment = function() {
|
|
1504
1504
|
return {
|
|
1505
1505
|
id: t.id,
|
|
@@ -1538,17 +1538,17 @@ const K = /* @__PURE__ */ new Map([
|
|
|
1538
1538
|
["a", { role: "link", applyARIA: !1 }]
|
|
1539
1539
|
// Usually implicit
|
|
1540
1540
|
]);
|
|
1541
|
-
let
|
|
1541
|
+
let wt = {
|
|
1542
1542
|
autoApplySemanticRoles: !0,
|
|
1543
1543
|
warnOnOverrides: process.env.NODE_ENV !== "production",
|
|
1544
1544
|
warnOnSemanticIssues: process.env.NODE_ENV !== "production",
|
|
1545
1545
|
validateTags: !0,
|
|
1546
1546
|
allowInvalidTags: !0
|
|
1547
1547
|
};
|
|
1548
|
-
function
|
|
1549
|
-
return { ...
|
|
1548
|
+
function Ct() {
|
|
1549
|
+
return { ...wt };
|
|
1550
1550
|
}
|
|
1551
|
-
var
|
|
1551
|
+
var Et = Object.defineProperty, At = (n, e, t) => e in n ? Et(n, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : n[e] = t, Mt = (n, e, t) => At(n, e + "", t);
|
|
1552
1552
|
const xe = class W {
|
|
1553
1553
|
static getInstance() {
|
|
1554
1554
|
return W.instance || (W.instance = new W()), W.instance;
|
|
@@ -1557,7 +1557,7 @@ const xe = class W {
|
|
|
1557
1557
|
* Apply semantic ARIA attributes to an element based on its tag
|
|
1558
1558
|
*/
|
|
1559
1559
|
applySemanticAttributes(e, t, s) {
|
|
1560
|
-
const r =
|
|
1560
|
+
const r = Ct();
|
|
1561
1561
|
if (!r.autoApplySemanticRoles) return;
|
|
1562
1562
|
const i = K.get(t);
|
|
1563
1563
|
if (!(!i || !i.applyARIA)) {
|
|
@@ -1614,11 +1614,11 @@ const xe = class W {
|
|
|
1614
1614
|
}
|
|
1615
1615
|
}
|
|
1616
1616
|
};
|
|
1617
|
-
|
|
1618
|
-
let
|
|
1619
|
-
const xt =
|
|
1620
|
-
var
|
|
1621
|
-
const
|
|
1617
|
+
Mt(xe, "instance");
|
|
1618
|
+
let It = xe;
|
|
1619
|
+
const xt = It.getInstance();
|
|
1620
|
+
var Tt = Object.defineProperty, $t = (n, e, t) => e in n ? Tt(n, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : n[e] = t, ne = (n, e, t) => $t(n, typeof e != "symbol" ? e + "" : e, t);
|
|
1621
|
+
const Nt = /* @__PURE__ */ new Set([
|
|
1622
1622
|
"click",
|
|
1623
1623
|
"dblclick",
|
|
1624
1624
|
"mousedown",
|
|
@@ -1637,14 +1637,14 @@ const $t = /* @__PURE__ */ new Set([
|
|
|
1637
1637
|
"keydown",
|
|
1638
1638
|
"keyup",
|
|
1639
1639
|
"keypress"
|
|
1640
|
-
]),
|
|
1640
|
+
]), Se = /* @__PURE__ */ new Set([
|
|
1641
1641
|
"scroll",
|
|
1642
1642
|
"wheel",
|
|
1643
1643
|
"touchstart",
|
|
1644
1644
|
"touchmove",
|
|
1645
1645
|
"touchend"
|
|
1646
1646
|
]);
|
|
1647
|
-
class
|
|
1647
|
+
class Rt {
|
|
1648
1648
|
constructor() {
|
|
1649
1649
|
ne(this, "containerListeners", /* @__PURE__ */ new WeakMap()), ne(this, "elementHandlers", /* @__PURE__ */ new WeakMap()), ne(this, "handlerCounts", /* @__PURE__ */ new WeakMap());
|
|
1650
1650
|
}
|
|
@@ -1656,8 +1656,8 @@ class Nt {
|
|
|
1656
1656
|
i && i.has(s) && this.unregister(e, t, s), i || (i = /* @__PURE__ */ new Map(), this.elementHandlers.set(t, i)), i.set(s, { handler: r, element: t });
|
|
1657
1657
|
let o = this.handlerCounts.get(e);
|
|
1658
1658
|
o || (o = /* @__PURE__ */ new Map(), this.handlerCounts.set(e, o));
|
|
1659
|
-
const
|
|
1660
|
-
return o.set(s,
|
|
1659
|
+
const a = o.get(s) || 0;
|
|
1660
|
+
return o.set(s, a + 1), this.ensureRootListener(e, s), () => {
|
|
1661
1661
|
this.unregister(e, t, s);
|
|
1662
1662
|
};
|
|
1663
1663
|
}
|
|
@@ -1682,7 +1682,7 @@ class Nt {
|
|
|
1682
1682
|
return;
|
|
1683
1683
|
const r = (o) => {
|
|
1684
1684
|
this.handleDelegatedEvent(e, t, o);
|
|
1685
|
-
}, i =
|
|
1685
|
+
}, i = Se.has(t) ? { passive: !0 } : { passive: !1 };
|
|
1686
1686
|
e.addEventListener(t, r, i), s.set(t, r);
|
|
1687
1687
|
}
|
|
1688
1688
|
/**
|
|
@@ -1704,12 +1704,12 @@ class Nt {
|
|
|
1704
1704
|
for (; i && i !== e; ) {
|
|
1705
1705
|
const o = this.elementHandlers.get(i);
|
|
1706
1706
|
if (o) {
|
|
1707
|
-
const
|
|
1708
|
-
if (
|
|
1707
|
+
const a = o.get(t);
|
|
1708
|
+
if (a) {
|
|
1709
1709
|
try {
|
|
1710
|
-
|
|
1711
|
-
} catch (
|
|
1712
|
-
console.error(`Delegated event handler error for ${t}:`,
|
|
1710
|
+
a.handler(s);
|
|
1711
|
+
} catch (l) {
|
|
1712
|
+
console.error(`Delegated event handler error for ${t}:`, l);
|
|
1713
1713
|
}
|
|
1714
1714
|
return;
|
|
1715
1715
|
}
|
|
@@ -1721,13 +1721,13 @@ class Nt {
|
|
|
1721
1721
|
* Check if event type should use delegation
|
|
1722
1722
|
*/
|
|
1723
1723
|
shouldDelegate(e) {
|
|
1724
|
-
return
|
|
1724
|
+
return Nt.has(e);
|
|
1725
1725
|
}
|
|
1726
1726
|
/**
|
|
1727
1727
|
* Check if event type should use passive listeners
|
|
1728
1728
|
*/
|
|
1729
1729
|
shouldBePassive(e) {
|
|
1730
|
-
return
|
|
1730
|
+
return Se.has(e);
|
|
1731
1731
|
}
|
|
1732
1732
|
/**
|
|
1733
1733
|
* Get metrics for debugging
|
|
@@ -1756,9 +1756,10 @@ class Nt {
|
|
|
1756
1756
|
}), this.containerListeners.delete(e)), this.handlerCounts.delete(e);
|
|
1757
1757
|
}
|
|
1758
1758
|
}
|
|
1759
|
-
const oe = new
|
|
1760
|
-
var
|
|
1761
|
-
|
|
1759
|
+
const oe = new Rt();
|
|
1760
|
+
var Ot = Object.defineProperty, Pt = (n, e, t) => e in n ? Ot(n, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : n[e] = t, j = (n, e, t) => Pt(n, typeof e != "symbol" ? e + "" : e, t);
|
|
1761
|
+
const ae = "__tachuiManagedComponentId";
|
|
1762
|
+
class Te {
|
|
1762
1763
|
constructor() {
|
|
1763
1764
|
j(this, "nodeMap", /* @__PURE__ */ new WeakMap()), j(this, "cleanupMap", /* @__PURE__ */ new WeakMap()), j(this, "renderedNodes", /* @__PURE__ */ new Set()), j(this, "elementToContainer", /* @__PURE__ */ new WeakMap()), j(this, "metrics", {
|
|
1764
1765
|
created: 0,
|
|
@@ -1842,22 +1843,24 @@ class Ie {
|
|
|
1842
1843
|
}
|
|
1843
1844
|
updateProps(e, t, s) {
|
|
1844
1845
|
const r = t.props || {}, i = t.__appliedProps || {};
|
|
1845
|
-
|
|
1846
|
-
if (!(
|
|
1847
|
-
if (
|
|
1846
|
+
Object.keys(i).forEach((a) => {
|
|
1847
|
+
if (!(a in r)) {
|
|
1848
|
+
if (a === "key" || a === "children" || a.startsWith("on"))
|
|
1848
1849
|
return;
|
|
1849
|
-
this.setElementProp(e,
|
|
1850
|
+
this.setElementProp(e, a, void 0);
|
|
1850
1851
|
}
|
|
1851
|
-
}), Object.entries(r).forEach(([
|
|
1852
|
-
|
|
1853
|
-
})
|
|
1854
|
-
|
|
1855
|
-
|
|
1852
|
+
}), Object.entries(r).forEach(([a, l]) => {
|
|
1853
|
+
a === "key" || a === "children" || i && i[a] === l || this.applyProp(e, a, l, s);
|
|
1854
|
+
});
|
|
1855
|
+
const o = t.componentId;
|
|
1856
|
+
if (o ? (e.getAttribute("data-component-id") !== String(o) && (e.setAttribute("data-component-id", String(o)), this.recordAttributeWrite()), e[ae] = !0) : e.hasAttribute("data-component-id") && e[ae] === !0 && (e.removeAttribute("data-component-id"), this.recordAttributeRemoval(), e[ae] = !1), t.__appliedProps = { ...r }, "componentMetadata" in t && t.componentMetadata) {
|
|
1857
|
+
const a = t.componentMetadata;
|
|
1858
|
+
if (a.overriddenTo && a.originalType && t.tag)
|
|
1856
1859
|
try {
|
|
1857
1860
|
xt.processElementNode(
|
|
1858
1861
|
e,
|
|
1859
1862
|
t.tag,
|
|
1860
|
-
|
|
1863
|
+
a,
|
|
1861
1864
|
r?.aria || void 0
|
|
1862
1865
|
);
|
|
1863
1866
|
} catch (l) {
|
|
@@ -1881,14 +1884,14 @@ class Ie {
|
|
|
1881
1884
|
}), t.__renderedChildren = r;
|
|
1882
1885
|
return;
|
|
1883
1886
|
}
|
|
1884
|
-
const
|
|
1887
|
+
const a = /* @__PURE__ */ new Map(), l = [];
|
|
1885
1888
|
s.forEach((c) => {
|
|
1886
|
-
c.key != null ?
|
|
1889
|
+
c.key != null ? a.set(c.key, c) : l.push(c);
|
|
1887
1890
|
});
|
|
1888
1891
|
const h = Array.from({ length: r.length });
|
|
1889
1892
|
if (r.forEach((c, u) => {
|
|
1890
1893
|
let f;
|
|
1891
|
-
c.key != null ? (f =
|
|
1894
|
+
c.key != null ? (f = a.get(c.key), f && a.delete(c.key)) : l.length > 0 && (f = l.shift()), f && this.adoptNode(f, c);
|
|
1892
1895
|
const p = this.renderSingle(c, i);
|
|
1893
1896
|
h[u] = p;
|
|
1894
1897
|
}), o && t.tag) {
|
|
@@ -1902,9 +1905,9 @@ class Ie {
|
|
|
1902
1905
|
dom: f
|
|
1903
1906
|
});
|
|
1904
1907
|
}
|
|
1905
|
-
if (
|
|
1908
|
+
if (a.forEach((c) => {
|
|
1906
1909
|
this.removeNode(c);
|
|
1907
|
-
}),
|
|
1910
|
+
}), l.forEach((c) => {
|
|
1908
1911
|
this.removeNode(c);
|
|
1909
1912
|
}), typeof e.insertBefore == "function" && typeof e.appendChild == "function") {
|
|
1910
1913
|
let c = null;
|
|
@@ -2093,24 +2096,24 @@ class Ie {
|
|
|
2093
2096
|
}), Object.entries(t).forEach(([r, i]) => {
|
|
2094
2097
|
if (F(i) || B(i)) {
|
|
2095
2098
|
const o = T(() => {
|
|
2096
|
-
const
|
|
2097
|
-
if (
|
|
2098
|
-
e.style.removeProperty(
|
|
2099
|
+
const a = i(), l = r.replace(/[A-Z]/g, (h) => `-${h.toLowerCase()}`);
|
|
2100
|
+
if (a == null)
|
|
2101
|
+
e.style.removeProperty(l), this.recordAttributeRemoval();
|
|
2099
2102
|
else {
|
|
2100
|
-
const h = String(
|
|
2101
|
-
e.style.getPropertyValue(
|
|
2103
|
+
const h = String(a);
|
|
2104
|
+
e.style.getPropertyValue(l) !== h && (e.style.setProperty(l, h), this.recordAttributeWrite());
|
|
2102
2105
|
}
|
|
2103
2106
|
});
|
|
2104
2107
|
this.addCleanup(e, () => {
|
|
2105
2108
|
o.dispose();
|
|
2106
2109
|
});
|
|
2107
2110
|
} else {
|
|
2108
|
-
const o = r.replace(/[A-Z]/g, (
|
|
2111
|
+
const o = r.replace(/[A-Z]/g, (a) => `-${a.toLowerCase()}`);
|
|
2109
2112
|
if (i == null)
|
|
2110
2113
|
e.style.getPropertyValue(o) && (e.style.removeProperty(o), this.recordAttributeRemoval());
|
|
2111
2114
|
else {
|
|
2112
|
-
const
|
|
2113
|
-
e.style.getPropertyValue(o) !==
|
|
2115
|
+
const a = String(i);
|
|
2116
|
+
e.style.getPropertyValue(o) !== a && (e.style.setProperty(o, a), this.recordAttributeWrite());
|
|
2114
2117
|
}
|
|
2115
2118
|
}
|
|
2116
2119
|
}), e.__appliedStyles = { ...t };
|
|
@@ -2133,15 +2136,15 @@ class Ie {
|
|
|
2133
2136
|
this.addCleanup(e, h);
|
|
2134
2137
|
return;
|
|
2135
2138
|
}
|
|
2136
|
-
const
|
|
2139
|
+
const a = (h) => {
|
|
2137
2140
|
try {
|
|
2138
2141
|
s(h);
|
|
2139
2142
|
} catch (c) {
|
|
2140
2143
|
console.error(`Event handler error for ${t}:`, c);
|
|
2141
2144
|
}
|
|
2142
|
-
},
|
|
2143
|
-
e.addEventListener(i,
|
|
2144
|
-
e.removeEventListener(i,
|
|
2145
|
+
}, l = oe.shouldBePassive(i) ? { passive: !0 } : void 0;
|
|
2146
|
+
e.addEventListener(i, a, l), this.addCleanup(e, () => {
|
|
2147
|
+
e.removeEventListener(i, a, l);
|
|
2145
2148
|
});
|
|
2146
2149
|
}
|
|
2147
2150
|
/**
|
|
@@ -2214,7 +2217,7 @@ class Ie {
|
|
|
2214
2217
|
t.length > 0 && this.recordModifierApplications(t.length);
|
|
2215
2218
|
const r = s.componentInstance || s.componentMetadata && s.componentMetadata.componentInstance || s._originalComponent || // Use original component if available
|
|
2216
2219
|
s;
|
|
2217
|
-
|
|
2220
|
+
Ie(
|
|
2218
2221
|
s,
|
|
2219
2222
|
t,
|
|
2220
2223
|
{
|
|
@@ -2303,8 +2306,8 @@ class Ie {
|
|
|
2303
2306
|
this.metrics.modifierApplications += e;
|
|
2304
2307
|
}
|
|
2305
2308
|
}
|
|
2306
|
-
new
|
|
2307
|
-
function
|
|
2309
|
+
new Te();
|
|
2310
|
+
function kt(n, e, ...t) {
|
|
2308
2311
|
const s = t.flat().filter((i) => i != null).map((i) => typeof i == "string" || typeof i == "number" ? { type: "text", text: String(i) } : i), r = {
|
|
2309
2312
|
type: "element",
|
|
2310
2313
|
tag: n,
|
|
@@ -2314,7 +2317,7 @@ function Pt(n, e, ...t) {
|
|
|
2314
2317
|
};
|
|
2315
2318
|
return e && "componentMetadata" in e && (r.componentMetadata = e.componentMetadata), r;
|
|
2316
2319
|
}
|
|
2317
|
-
var
|
|
2320
|
+
var Lt = Object.defineProperty, Dt = (n, e, t) => e in n ? Lt(n, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : n[e] = t, P = (n, e, t) => Dt(n, typeof e != "symbol" ? e + "" : e, t);
|
|
2318
2321
|
let Y = class ee {
|
|
2319
2322
|
// Required by ModifiableComponent interface
|
|
2320
2323
|
constructor(e, t, s = !0) {
|
|
@@ -2326,7 +2329,7 @@ let Y = class ee {
|
|
|
2326
2329
|
render() {
|
|
2327
2330
|
const e = this.determineContainerClass(), t = this.buildAccessibilityLabel(), s = this.buildAccessibilityAttributes(), r = this.modifiers && this.modifiers.some((o) => o.type === "asHTML");
|
|
2328
2331
|
let i;
|
|
2329
|
-
return r ? i = this.renderSegmentsWithAsHTML() : i = this.segments.map((o) => o.render()).flat(), [
|
|
2332
|
+
return r ? i = this.renderSegmentsWithAsHTML() : i = this.segments.map((o) => o.render()).flat(), [kt("span", {
|
|
2330
2333
|
class: `tachui-concatenated ${e}`,
|
|
2331
2334
|
...s,
|
|
2332
2335
|
"aria-label": t || void 0,
|
|
@@ -2598,7 +2601,7 @@ let Y = class ee {
|
|
|
2598
2601
|
componentInstance: s.component
|
|
2599
2602
|
// Pass the original component
|
|
2600
2603
|
};
|
|
2601
|
-
return
|
|
2604
|
+
return Ie(e, t, r, { batch: !0 });
|
|
2602
2605
|
}
|
|
2603
2606
|
/**
|
|
2604
2607
|
* Generate comprehensive accessibility tree for this concatenated component
|
|
@@ -2622,14 +2625,14 @@ let Y = class ee {
|
|
|
2622
2625
|
};
|
|
2623
2626
|
}
|
|
2624
2627
|
};
|
|
2625
|
-
const
|
|
2628
|
+
const zt = {
|
|
2626
2629
|
proxyModifiers: !0
|
|
2627
2630
|
};
|
|
2628
|
-
let
|
|
2629
|
-
function
|
|
2630
|
-
return
|
|
2631
|
+
let _t = { ...zt };
|
|
2632
|
+
function $e() {
|
|
2633
|
+
return _t.proxyModifiers === !0;
|
|
2631
2634
|
}
|
|
2632
|
-
let
|
|
2635
|
+
let we = /* @__PURE__ */ new WeakMap(), Ht = /* @__PURE__ */ new WeakMap(), Vt = /* @__PURE__ */ new WeakMap(), jt = /* @__PURE__ */ new WeakMap();
|
|
2633
2636
|
function $(n) {
|
|
2634
2637
|
if (Object.prototype.hasOwnProperty.call(n, "modifiers") && Object.prototype.hasOwnProperty.call(n, "modifierBuilder"))
|
|
2635
2638
|
return n;
|
|
@@ -2653,147 +2656,147 @@ function $(n) {
|
|
|
2653
2656
|
}
|
|
2654
2657
|
return n._modifiableComponent;
|
|
2655
2658
|
}
|
|
2656
|
-
function
|
|
2657
|
-
if (
|
|
2659
|
+
function de(n) {
|
|
2660
|
+
if (!$e())
|
|
2658
2661
|
return n;
|
|
2659
|
-
const e =
|
|
2662
|
+
const e = we.get(n);
|
|
2660
2663
|
if (e)
|
|
2661
2664
|
return e;
|
|
2662
2665
|
const t = /* @__PURE__ */ new Map();
|
|
2663
|
-
|
|
2666
|
+
Ht.set(n, t);
|
|
2664
2667
|
const s = /* @__PURE__ */ new Map();
|
|
2665
|
-
|
|
2668
|
+
Vt.set(n, s);
|
|
2666
2669
|
const r = /* @__PURE__ */ new Map();
|
|
2667
|
-
|
|
2670
|
+
jt.set(n, r);
|
|
2668
2671
|
const i = {
|
|
2669
|
-
get(
|
|
2670
|
-
if (
|
|
2671
|
-
return Reflect.get(
|
|
2672
|
-
if (
|
|
2673
|
-
if (r.has(
|
|
2674
|
-
return r.get(
|
|
2675
|
-
const c = $(
|
|
2672
|
+
get(a, l, h) {
|
|
2673
|
+
if (l === Symbol.toStringTag)
|
|
2674
|
+
return Reflect.get(a, l, h);
|
|
2675
|
+
if (l === "render") {
|
|
2676
|
+
if (r.has(l))
|
|
2677
|
+
return r.get(l);
|
|
2678
|
+
const c = $(a);
|
|
2676
2679
|
if (typeof c.render == "function") {
|
|
2677
2680
|
const u = c.render.bind(c);
|
|
2678
|
-
return r.set(
|
|
2681
|
+
return r.set(l, u), u;
|
|
2679
2682
|
}
|
|
2680
|
-
return Reflect.get(
|
|
2683
|
+
return Reflect.get(a, l, h);
|
|
2681
2684
|
}
|
|
2682
|
-
if (
|
|
2683
|
-
const c = $(
|
|
2685
|
+
if (l === "build") {
|
|
2686
|
+
const c = $(a), u = c.modifierBuilder || c.modifier;
|
|
2684
2687
|
if (u && typeof u.build == "function") {
|
|
2685
2688
|
const f = u.build.bind(u);
|
|
2686
2689
|
return (...p) => {
|
|
2687
2690
|
const v = f(...p);
|
|
2688
|
-
return v && typeof v == "object" && !Array.isArray(v) ?
|
|
2691
|
+
return v && typeof v == "object" && !Array.isArray(v) ? de(
|
|
2689
2692
|
v
|
|
2690
2693
|
) : v;
|
|
2691
2694
|
};
|
|
2692
2695
|
}
|
|
2693
2696
|
return;
|
|
2694
2697
|
}
|
|
2695
|
-
if (
|
|
2696
|
-
if (
|
|
2698
|
+
if (l === "modifiers" || l === "modifier" || l === "modifierBuilder") {
|
|
2699
|
+
if (l === "modifier") {
|
|
2697
2700
|
const u = Object.getOwnPropertyDescriptor(
|
|
2698
|
-
|
|
2701
|
+
a,
|
|
2699
2702
|
"modifier"
|
|
2700
2703
|
);
|
|
2701
2704
|
if (u && "value" in u)
|
|
2702
2705
|
return u.value;
|
|
2703
2706
|
}
|
|
2704
|
-
const c = $(
|
|
2705
|
-
return
|
|
2707
|
+
const c = $(a);
|
|
2708
|
+
return l === "modifiers" ? c.modifiers : c.modifierBuilder;
|
|
2706
2709
|
}
|
|
2707
|
-
if (typeof
|
|
2710
|
+
if (typeof l == "string") {
|
|
2708
2711
|
let c;
|
|
2709
|
-
if (t.has(
|
|
2710
|
-
const p = s.get(
|
|
2711
|
-
p !== void 0 && p !== c && (t.delete(
|
|
2712
|
+
if (t.has(l) && (c = V.get(l), c)) {
|
|
2713
|
+
const p = s.get(l);
|
|
2714
|
+
p !== void 0 && p !== c && (t.delete(l), s.delete(l));
|
|
2712
2715
|
}
|
|
2713
|
-
if (Reflect.has(
|
|
2714
|
-
const p = Reflect.get(l, a
|
|
2716
|
+
if (Reflect.has(a, l)) {
|
|
2717
|
+
const p = Reflect.get(a, l, a);
|
|
2715
2718
|
if (typeof p != "function")
|
|
2716
2719
|
return p;
|
|
2717
2720
|
}
|
|
2718
|
-
const u = $(
|
|
2721
|
+
const u = $(a), f = u.modifierBuilder || u.modifier;
|
|
2719
2722
|
if (f) {
|
|
2720
|
-
const p = f[
|
|
2723
|
+
const p = f[l];
|
|
2721
2724
|
if (typeof p == "function") {
|
|
2722
|
-
if (!t.has(
|
|
2725
|
+
if (!t.has(l)) {
|
|
2723
2726
|
const v = (...k) => {
|
|
2724
|
-
const C = $(
|
|
2725
|
-
if (typeof
|
|
2727
|
+
const C = $(a), E = C.modifierBuilder || C.modifier, fe = E?.[l];
|
|
2728
|
+
if (typeof fe != "function")
|
|
2726
2729
|
throw new Error(
|
|
2727
|
-
`Modifier '${String(
|
|
2730
|
+
`Modifier '${String(l)}' is not callable`
|
|
2728
2731
|
);
|
|
2729
|
-
const se =
|
|
2732
|
+
const se = fe.apply(E, k);
|
|
2730
2733
|
return se && se !== E ? se : o;
|
|
2731
2734
|
};
|
|
2732
|
-
t.set(
|
|
2733
|
-
|
|
2734
|
-
c ?? V.get(
|
|
2735
|
+
t.set(l, v), s.set(
|
|
2736
|
+
l,
|
|
2737
|
+
c ?? V.get(l)
|
|
2735
2738
|
);
|
|
2736
2739
|
}
|
|
2737
|
-
return t.get(
|
|
2740
|
+
return t.get(l);
|
|
2738
2741
|
}
|
|
2739
2742
|
if (p !== void 0)
|
|
2740
2743
|
return p;
|
|
2741
2744
|
}
|
|
2742
|
-
if (V.has(
|
|
2743
|
-
if (!t.has(
|
|
2745
|
+
if (V.has(l)) {
|
|
2746
|
+
if (!t.has(l)) {
|
|
2744
2747
|
const p = (...v) => {
|
|
2745
|
-
const k = $(
|
|
2748
|
+
const k = $(a), C = k.modifierBuilder || k.modifier, E = C?.[l];
|
|
2746
2749
|
if (typeof E != "function")
|
|
2747
|
-
throw new Error(`Modifier '${String(
|
|
2750
|
+
throw new Error(`Modifier '${String(l)}' is not callable`);
|
|
2748
2751
|
return E.apply(C, v), o;
|
|
2749
2752
|
};
|
|
2750
|
-
t.set(
|
|
2751
|
-
|
|
2752
|
-
c ?? V.get(
|
|
2753
|
+
t.set(l, p), s.set(
|
|
2754
|
+
l,
|
|
2755
|
+
c ?? V.get(l)
|
|
2753
2756
|
);
|
|
2754
2757
|
}
|
|
2755
|
-
return t.get(
|
|
2758
|
+
return t.get(l);
|
|
2756
2759
|
}
|
|
2757
2760
|
}
|
|
2758
|
-
if (Reflect.has(
|
|
2759
|
-
const c = Reflect.get(l, a
|
|
2760
|
-
return typeof c == "function" ?
|
|
2761
|
-
const f = c.apply(
|
|
2762
|
-
return f && typeof f == "object" ?
|
|
2763
|
-
} : (r.has(
|
|
2761
|
+
if (Reflect.has(a, l)) {
|
|
2762
|
+
const c = Reflect.get(a, l, a);
|
|
2763
|
+
return typeof c == "function" ? l === "clone" ? (...u) => {
|
|
2764
|
+
const f = c.apply(a, u);
|
|
2765
|
+
return f && typeof f == "object" ? de(f) : f;
|
|
2766
|
+
} : (r.has(l) || r.set(l, c.bind(a)), r.get(l)) : c;
|
|
2764
2767
|
}
|
|
2765
2768
|
},
|
|
2766
|
-
has(
|
|
2767
|
-
if (
|
|
2769
|
+
has(a, l) {
|
|
2770
|
+
if (l === "modifiers" || l === "modifier" || l === "modifierBuilder")
|
|
2768
2771
|
return !0;
|
|
2769
|
-
if (typeof
|
|
2770
|
-
const h =
|
|
2771
|
-
if (c && typeof c[
|
|
2772
|
+
if (typeof l == "string") {
|
|
2773
|
+
const h = a._modifiableComponent || $(a), c = h?.modifierBuilder || h?.modifier;
|
|
2774
|
+
if (c && typeof c[l] == "function")
|
|
2772
2775
|
return !0;
|
|
2773
2776
|
}
|
|
2774
|
-
return Reflect.has(
|
|
2777
|
+
return Reflect.has(a, l) || V.has(l);
|
|
2775
2778
|
},
|
|
2776
|
-
set(
|
|
2777
|
-
if (
|
|
2778
|
-
return Object.defineProperty(
|
|
2779
|
+
set(a, l, h, c) {
|
|
2780
|
+
if (l === "modifier")
|
|
2781
|
+
return Object.defineProperty(a, "modifier", {
|
|
2779
2782
|
configurable: !0,
|
|
2780
2783
|
enumerable: !1,
|
|
2781
2784
|
writable: !0,
|
|
2782
2785
|
value: h
|
|
2783
2786
|
}), t.clear(), !0;
|
|
2784
|
-
if (
|
|
2785
|
-
const u = $(
|
|
2787
|
+
if (l === "modifiers" && Array.isArray(h)) {
|
|
2788
|
+
const u = $(a);
|
|
2786
2789
|
return u.modifiers = [...h], !0;
|
|
2787
2790
|
}
|
|
2788
|
-
return Reflect.set(
|
|
2791
|
+
return Reflect.set(a, l, h, c);
|
|
2789
2792
|
}
|
|
2790
2793
|
}, o = new Proxy(n, i);
|
|
2791
|
-
return
|
|
2794
|
+
return we.set(n, o), o;
|
|
2792
2795
|
}
|
|
2793
|
-
var
|
|
2794
|
-
class
|
|
2796
|
+
var Ft = Object.defineProperty, Bt = (n, e, t) => e in n ? Ft(n, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : n[e] = t, I = (n, e, t) => Bt(n, typeof e != "symbol" ? e + "" : e, t);
|
|
2797
|
+
class Wt {
|
|
2795
2798
|
constructor(e, t) {
|
|
2796
|
-
|
|
2799
|
+
I(this, "id"), I(this, "parent"), I(this, "providers", /* @__PURE__ */ new Map()), I(this, "consumers", /* @__PURE__ */ new Set()), I(this, "cleanup", /* @__PURE__ */ new Set()), I(this, "stateStore", /* @__PURE__ */ new Map()), I(this, "bindingStore", /* @__PURE__ */ new Map()), I(this, "createdAt", Date.now()), I(this, "updateCount", 0), this.id = e, this.parent = t;
|
|
2797
2800
|
}
|
|
2798
2801
|
/**
|
|
2799
2802
|
* Store state value for a property
|
|
@@ -2877,11 +2880,11 @@ class Bt {
|
|
|
2877
2880
|
};
|
|
2878
2881
|
}
|
|
2879
2882
|
}
|
|
2880
|
-
function
|
|
2881
|
-
return new
|
|
2883
|
+
function Ut(n, e) {
|
|
2884
|
+
return new Wt(n, e);
|
|
2882
2885
|
}
|
|
2883
|
-
var
|
|
2884
|
-
const
|
|
2886
|
+
var qt = Object.defineProperty, Qt = (n, e, t) => e in n ? qt(n, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : n[e] = t, H = (n, e, t) => Qt(n, typeof e != "symbol" ? e + "" : e, t);
|
|
2887
|
+
const Gt = class U {
|
|
2885
2888
|
constructor() {
|
|
2886
2889
|
H(this, "components", /* @__PURE__ */ new Map()), H(this, "contexts", /* @__PURE__ */ new Map()), H(this, "cleanupQueue", /* @__PURE__ */ new Set()), H(this, "updateQueue", /* @__PURE__ */ new Set()), H(this, "isUpdating", !1);
|
|
2887
2890
|
}
|
|
@@ -2978,9 +2981,9 @@ const Qt = class U {
|
|
|
2978
2981
|
}), this.cleanupQueue.clear(), this.updateQueue.clear();
|
|
2979
2982
|
}
|
|
2980
2983
|
};
|
|
2981
|
-
H(
|
|
2982
|
-
var
|
|
2983
|
-
const
|
|
2984
|
+
H(Gt, "instance");
|
|
2985
|
+
var Kt = Object.defineProperty, Yt = (n, e, t) => e in n ? Kt(n, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : n[e] = t, M = (n, e, t) => Yt(n, typeof e != "symbol" ? e + "" : e, t);
|
|
2986
|
+
const Ne = class q {
|
|
2984
2987
|
constructor() {
|
|
2985
2988
|
M(this, "contexts", /* @__PURE__ */ new Map()), M(this, "providerStack", /* @__PURE__ */ new Map()), M(this, "currentComponent", null);
|
|
2986
2989
|
}
|
|
@@ -3004,15 +3007,15 @@ const $e = class q {
|
|
|
3004
3007
|
*/
|
|
3005
3008
|
registerProvider(e, t, s) {
|
|
3006
3009
|
this.providerStack.has(e) || this.providerStack.set(e, []);
|
|
3007
|
-
const r = this.providerStack.get(e), [i, o] =
|
|
3010
|
+
const r = this.providerStack.get(e), [i, o] = ce(t), a = {
|
|
3008
3011
|
value: t,
|
|
3009
3012
|
signal: [i, o],
|
|
3010
3013
|
subscribers: /* @__PURE__ */ new Set(),
|
|
3011
3014
|
providers: /* @__PURE__ */ new Set([s])
|
|
3012
3015
|
};
|
|
3013
|
-
return r.push(
|
|
3014
|
-
const
|
|
3015
|
-
|
|
3016
|
+
return r.push(a), s.providers.set(e, a), () => {
|
|
3017
|
+
const l = r.indexOf(a);
|
|
3018
|
+
l !== -1 && r.splice(l, 1), s.providers.delete(e), a.subscribers.clear(), a.providers.clear();
|
|
3016
3019
|
};
|
|
3017
3020
|
}
|
|
3018
3021
|
/**
|
|
@@ -3022,7 +3025,7 @@ const $e = class q {
|
|
|
3022
3025
|
const s = this.providerStack.get(e), r = s && s.length > 0 ? s[s.length - 1] : null;
|
|
3023
3026
|
if (r)
|
|
3024
3027
|
return this.currentComponent && (r.subscribers.add(this.currentComponent.id), this.currentComponent.consumers.add(e)), [r.signal[0], !0];
|
|
3025
|
-
const [i] =
|
|
3028
|
+
const [i] = ce(t);
|
|
3026
3029
|
return [i, !1];
|
|
3027
3030
|
}
|
|
3028
3031
|
/**
|
|
@@ -3048,10 +3051,10 @@ const $e = class q {
|
|
|
3048
3051
|
this.contexts.clear(), this.providerStack.clear(), this.currentComponent = null;
|
|
3049
3052
|
}
|
|
3050
3053
|
};
|
|
3051
|
-
M(
|
|
3052
|
-
let
|
|
3054
|
+
M(Ne, "instance");
|
|
3055
|
+
let Zt = Ne, Xt = class {
|
|
3053
3056
|
constructor() {
|
|
3054
|
-
M(this, "registry",
|
|
3057
|
+
M(this, "registry", Zt.getInstance());
|
|
3055
3058
|
}
|
|
3056
3059
|
/**
|
|
3057
3060
|
* Create a context provider component
|
|
@@ -3063,12 +3066,12 @@ let Yt = $e, Zt = class {
|
|
|
3063
3066
|
const r = this.registry.registerProvider(
|
|
3064
3067
|
e.symbol,
|
|
3065
3068
|
t,
|
|
3066
|
-
|
|
3069
|
+
Ut(`provider_${e.symbol.toString()}`)
|
|
3067
3070
|
), i = s.flatMap((o) => {
|
|
3068
|
-
let
|
|
3069
|
-
"build" in o && typeof o.build == "function" && (
|
|
3070
|
-
const
|
|
3071
|
-
return Array.isArray(
|
|
3071
|
+
let a = o;
|
|
3072
|
+
"build" in o && typeof o.build == "function" && (a = o.build());
|
|
3073
|
+
const l = a.render();
|
|
3074
|
+
return Array.isArray(l) ? l : [l];
|
|
3072
3075
|
});
|
|
3073
3076
|
return [
|
|
3074
3077
|
{
|
|
@@ -3110,7 +3113,7 @@ let Yt = $e, Zt = class {
|
|
|
3110
3113
|
this.registry.clear();
|
|
3111
3114
|
}
|
|
3112
3115
|
};
|
|
3113
|
-
class
|
|
3116
|
+
class Jt {
|
|
3114
3117
|
constructor() {
|
|
3115
3118
|
M(this, "services", /* @__PURE__ */ new Map()), M(this, "factories", /* @__PURE__ */ new Map()), M(this, "singletons", /* @__PURE__ */ new Map()), M(this, "scoped", /* @__PURE__ */ new Map()), M(this, "dependencies", /* @__PURE__ */ new Map());
|
|
3116
3119
|
}
|
|
@@ -3172,11 +3175,11 @@ class Xt {
|
|
|
3172
3175
|
return [...this.services.keys(), ...this.factories.keys()];
|
|
3173
3176
|
}
|
|
3174
3177
|
}
|
|
3178
|
+
new Jt();
|
|
3175
3179
|
new Xt();
|
|
3176
|
-
new
|
|
3177
|
-
|
|
3178
|
-
|
|
3179
|
-
const ts = {
|
|
3180
|
+
new Te();
|
|
3181
|
+
var es = Object.defineProperty, ts = (n, e, t) => e in n ? es(n, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : n[e] = t, le = (n, e, t) => ts(n, typeof e != "symbol" ? e + "" : e, t);
|
|
3182
|
+
const ss = {
|
|
3180
3183
|
sanitizeClassNames: !0,
|
|
3181
3184
|
sanitizationRules: {
|
|
3182
3185
|
allowNumbers: !0,
|
|
@@ -3188,9 +3191,9 @@ const ts = {
|
|
|
3188
3191
|
warnDuplicateClasses: process.env.NODE_ENV === "development",
|
|
3189
3192
|
warnInvalidClasses: process.env.NODE_ENV === "development"
|
|
3190
3193
|
};
|
|
3191
|
-
let
|
|
3194
|
+
let rs = class {
|
|
3192
3195
|
constructor(e = {}) {
|
|
3193
|
-
|
|
3196
|
+
le(this, "config"), le(this, "classCache"), le(this, "processingCache"), this.config = { ...ss, ...e };
|
|
3194
3197
|
const t = (() => {
|
|
3195
3198
|
try {
|
|
3196
3199
|
return typeof Map < "u" && typeof Map == "function";
|
|
@@ -3364,16 +3367,16 @@ let ss = class {
|
|
|
3364
3367
|
this.cacheSet(this.classCache, e, t);
|
|
3365
3368
|
}
|
|
3366
3369
|
};
|
|
3367
|
-
new
|
|
3368
|
-
function
|
|
3370
|
+
new rs();
|
|
3371
|
+
function is(n, e, t = {}, ...s) {
|
|
3369
3372
|
const r = new n(e, ...s);
|
|
3370
|
-
return
|
|
3373
|
+
return $e() && t.prewarmProxy !== !1 && de(r), r;
|
|
3371
3374
|
}
|
|
3372
|
-
var
|
|
3373
|
-
let
|
|
3375
|
+
var ns = Object.defineProperty, os = (n, e, t) => e in n ? ns(n, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : n[e] = t, D = (n, e, t) => os(n, typeof e != "symbol" ? e + "" : e, t);
|
|
3376
|
+
let as = class ue extends ke {
|
|
3374
3377
|
constructor(e) {
|
|
3375
3378
|
super(), this.props = e, D(this, "type", "component"), D(this, "id"), D(this, "mounted", !1), D(this, "cleanup", []), D(this, "effectiveTag"), D(this, "validationResult"), this.id = `text-${Date.now()}-${Math.random().toString(36).substr(2, 9)}`;
|
|
3376
|
-
const t = this.resolveDefaultTag(), s =
|
|
3379
|
+
const t = this.resolveDefaultTag(), s = Le(
|
|
3377
3380
|
"Text",
|
|
3378
3381
|
t,
|
|
3379
3382
|
this.props.element
|
|
@@ -3403,7 +3406,7 @@ let os = class de extends Pe {
|
|
|
3403
3406
|
// Add reference to the Text component instance
|
|
3404
3407
|
}
|
|
3405
3408
|
},
|
|
3406
|
-
|
|
3409
|
+
De(this.props.content || "")
|
|
3407
3410
|
)];
|
|
3408
3411
|
}
|
|
3409
3412
|
// Concatenation support - simplified for now
|
|
@@ -3432,31 +3435,31 @@ let os = class de extends Pe {
|
|
|
3432
3435
|
return e.deep ? this.deepClone() : this.shallowClone();
|
|
3433
3436
|
}
|
|
3434
3437
|
shallowClone() {
|
|
3435
|
-
const e =
|
|
3436
|
-
return
|
|
3438
|
+
const e = me(this.props), t = new ue(e);
|
|
3439
|
+
return ge(t), t;
|
|
3437
3440
|
}
|
|
3438
3441
|
deepClone() {
|
|
3439
|
-
const e =
|
|
3442
|
+
const e = me(this.props, {
|
|
3440
3443
|
deep: !0
|
|
3441
|
-
}), t = new
|
|
3442
|
-
return
|
|
3444
|
+
}), t = new ue(e);
|
|
3445
|
+
return ge(t), t;
|
|
3443
3446
|
}
|
|
3444
3447
|
};
|
|
3445
|
-
function
|
|
3448
|
+
function Re(n, e) {
|
|
3446
3449
|
const t = {
|
|
3447
3450
|
content: n,
|
|
3448
3451
|
...e
|
|
3449
|
-
}, s =
|
|
3450
|
-
return
|
|
3452
|
+
}, s = is(as, t);
|
|
3453
|
+
return pe(s);
|
|
3451
3454
|
}
|
|
3452
3455
|
function z(n) {
|
|
3453
|
-
return (e, t) =>
|
|
3456
|
+
return (e, t) => Re(e, {
|
|
3454
3457
|
...t,
|
|
3455
3458
|
accessibilityRole: "heading",
|
|
3456
3459
|
accessibilityLevel: n
|
|
3457
3460
|
});
|
|
3458
3461
|
}
|
|
3459
|
-
Object.assign(
|
|
3462
|
+
Object.assign(Re, {
|
|
3460
3463
|
H1: z(1),
|
|
3461
3464
|
H2: z(2),
|
|
3462
3465
|
H3: z(3),
|
|
@@ -3464,8 +3467,8 @@ Object.assign(Ne, {
|
|
|
3464
3467
|
H5: z(5),
|
|
3465
3468
|
H6: z(6)
|
|
3466
3469
|
});
|
|
3467
|
-
var
|
|
3468
|
-
class
|
|
3470
|
+
var ls = Object.defineProperty, cs = (n, e, t) => e in n ? ls(n, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : n[e] = t, g = (n, e, t) => cs(n, typeof e != "symbol" ? e + "" : e, t);
|
|
3471
|
+
class hs {
|
|
3469
3472
|
constructor(e) {
|
|
3470
3473
|
this.props = e, g(this, "type", "component"), g(this, "id"), g(this, "mounted", !1), g(this, "cleanup", []), g(this, "scrollElement", null), g(this, "contentOffsetSignal"), g(this, "setContentOffset"), g(this, "contentSizeSignal"), g(this, "setContentSize"), g(this, "setIsScrolling"), g(this, "pullToRefreshStateSignal"), g(this, "setPullToRefreshState"), g(this, "scrollEventThrottle"), g(this, "lastScrollTime", 0), g(this, "scrollVelocity", { x: 0, y: 0 }), g(this, "lastScrollOffset", { x: 0, y: 0 }), g(this, "pullStartY", 0), g(this, "isPulling", !1), g(this, "handleScroll", (h) => {
|
|
3471
3474
|
if (!this.scrollElement) return;
|
|
@@ -3530,8 +3533,8 @@ class cs {
|
|
|
3530
3533
|
this.contentSizeSignal = r, this.setContentSize = i;
|
|
3531
3534
|
const [, o] = N(!1);
|
|
3532
3535
|
this.setIsScrolling = o;
|
|
3533
|
-
const [
|
|
3534
|
-
if (this.pullToRefreshStateSignal =
|
|
3536
|
+
const [a, l] = N("idle");
|
|
3537
|
+
if (this.pullToRefreshStateSignal = a, this.setPullToRefreshState = l, e.contentOffset && S(e.contentOffset)) {
|
|
3535
3538
|
this.setContentOffset(e.contentOffset());
|
|
3536
3539
|
const h = R(() => {
|
|
3537
3540
|
e.contentOffset && S(e.contentOffset) && this.setContentOffset(e.contentOffset());
|
|
@@ -3752,13 +3755,13 @@ class cs {
|
|
|
3752
3755
|
}
|
|
3753
3756
|
},
|
|
3754
3757
|
...s.flatMap((u) => u.render())
|
|
3755
|
-
), o = this.createPullToRefreshIndicator(),
|
|
3758
|
+
), o = this.createPullToRefreshIndicator(), a = [];
|
|
3756
3759
|
if (o) {
|
|
3757
3760
|
const u = o.render(), f = Array.isArray(u) ? u : [u];
|
|
3758
|
-
|
|
3761
|
+
a.push(...f.filter((p) => p));
|
|
3759
3762
|
}
|
|
3760
|
-
|
|
3761
|
-
const { direction:
|
|
3763
|
+
a.push(i);
|
|
3764
|
+
const { direction: l = "vertical" } = this.props, h = this.getOverflowStyles(l), c = w(
|
|
3762
3765
|
"div",
|
|
3763
3766
|
{
|
|
3764
3767
|
id: this.id,
|
|
@@ -3770,7 +3773,7 @@ class cs {
|
|
|
3770
3773
|
...h
|
|
3771
3774
|
}
|
|
3772
3775
|
},
|
|
3773
|
-
...
|
|
3776
|
+
...a
|
|
3774
3777
|
);
|
|
3775
3778
|
if (c.element) {
|
|
3776
3779
|
const u = c.element;
|
|
@@ -3800,11 +3803,11 @@ class cs {
|
|
|
3800
3803
|
return [c];
|
|
3801
3804
|
}
|
|
3802
3805
|
}
|
|
3803
|
-
function
|
|
3804
|
-
const e = new
|
|
3805
|
-
return
|
|
3806
|
+
function ds(n = {}) {
|
|
3807
|
+
const e = new hs(n);
|
|
3808
|
+
return pe(e);
|
|
3806
3809
|
}
|
|
3807
|
-
const
|
|
3810
|
+
const us = `
|
|
3808
3811
|
@keyframes spin {
|
|
3809
3812
|
from { transform: rotate(0deg); }
|
|
3810
3813
|
to { transform: rotate(360deg); }
|
|
@@ -3812,10 +3815,10 @@ const ds = `
|
|
|
3812
3815
|
`;
|
|
3813
3816
|
if (typeof document < "u") {
|
|
3814
3817
|
const n = document.createElement("style");
|
|
3815
|
-
n.textContent =
|
|
3818
|
+
n.textContent = us, document.head.appendChild(n);
|
|
3816
3819
|
}
|
|
3817
3820
|
process.env.NODE_ENV;
|
|
3818
|
-
class
|
|
3821
|
+
class ps {
|
|
3819
3822
|
constructor(e) {
|
|
3820
3823
|
m(this, "type", "component");
|
|
3821
3824
|
m(this, "id");
|
|
@@ -3851,8 +3854,8 @@ class us {
|
|
|
3851
3854
|
this.resolveSections()
|
|
3852
3855
|
);
|
|
3853
3856
|
this.sectionsSignal = r, this.setSections = i;
|
|
3854
|
-
const o = /* @__PURE__ */ new Set(), [
|
|
3855
|
-
this.selectedItemsSignal =
|
|
3857
|
+
const o = /* @__PURE__ */ new Set(), [a, l] = N(o);
|
|
3858
|
+
this.selectedItemsSignal = a, this.setSelectedItems = l;
|
|
3856
3859
|
const [h, c] = N(
|
|
3857
3860
|
this.resolveIsLoading()
|
|
3858
3861
|
);
|
|
@@ -3967,14 +3970,14 @@ class us {
|
|
|
3967
3970
|
handleItemSelection(e, t) {
|
|
3968
3971
|
const { selectionMode: s, getItemId: r, onSelectionChange: i } = this.props;
|
|
3969
3972
|
if (s === "none") return;
|
|
3970
|
-
const o = r ? r(e, t) : t,
|
|
3971
|
-
s === "single" ? (
|
|
3973
|
+
const o = r ? r(e, t) : t, a = new Set(this.selectedItemsSignal());
|
|
3974
|
+
s === "single" ? (a.clear(), a.add(o)) : s === "multiple" && (a.has(o) ? a.delete(o) : a.add(o)), this.setSelectedItems(a), i && i(a);
|
|
3972
3975
|
}
|
|
3973
3976
|
/**
|
|
3974
3977
|
* Create list item component
|
|
3975
3978
|
*/
|
|
3976
3979
|
createListItem(e, t, s) {
|
|
3977
|
-
const { renderItem: r, style: i, onItemTap: o, onItemLongPress:
|
|
3980
|
+
const { renderItem: r, style: i, onItemTap: o, onItemLongPress: a } = this.props, l = r(e, t);
|
|
3978
3981
|
return {
|
|
3979
3982
|
type: "component",
|
|
3980
3983
|
id: `${this.id}-item-${t}`,
|
|
@@ -3995,15 +3998,15 @@ class us {
|
|
|
3995
3998
|
cursor: o ? "pointer" : "default"
|
|
3996
3999
|
}
|
|
3997
4000
|
},
|
|
3998
|
-
...this.normalizeItemRenderOutput(
|
|
4001
|
+
...this.normalizeItemRenderOutput(l)
|
|
3999
4002
|
);
|
|
4000
4003
|
if (h.element) {
|
|
4001
4004
|
const c = h.element;
|
|
4002
|
-
if (o && c.addEventListener("click", () => o(e, t)),
|
|
4005
|
+
if (o && c.addEventListener("click", () => o(e, t)), a) {
|
|
4003
4006
|
let u;
|
|
4004
4007
|
const f = () => {
|
|
4005
4008
|
u = setTimeout(
|
|
4006
|
-
() =>
|
|
4009
|
+
() => a(e, t),
|
|
4007
4010
|
500
|
|
4008
4011
|
);
|
|
4009
4012
|
}, p = () => {
|
|
@@ -4175,8 +4178,8 @@ class us {
|
|
|
4175
4178
|
});
|
|
4176
4179
|
}
|
|
4177
4180
|
for (let i = this.visibleStartIndex; i <= this.visibleEndIndex && i < e.length; i++) {
|
|
4178
|
-
const o = e[i],
|
|
4179
|
-
r.push(this.createListItem(o, i,
|
|
4181
|
+
const o = e[i], a = this.props.getItemId ? this.props.getItemId(o, i) : i, l = t.has(a);
|
|
4182
|
+
r.push(this.createListItem(o, i, l)), s && i < e.length - 1 && r.push(s);
|
|
4180
4183
|
}
|
|
4181
4184
|
if (this.visibleEndIndex < e.length - 1) {
|
|
4182
4185
|
const i = this.totalHeight - (this.virtualItems[this.visibleEndIndex + 1]?.offset || 0);
|
|
@@ -4200,17 +4203,17 @@ class us {
|
|
|
4200
4203
|
*/
|
|
4201
4204
|
renderRegularContent() {
|
|
4202
4205
|
const e = this.dataSignal(), t = this.sectionsSignal(), s = this.selectedItemsSignal(), r = this.createSeparator(), i = [];
|
|
4203
|
-
return t.length > 0 ? t.forEach((o,
|
|
4204
|
-
const
|
|
4205
|
-
|
|
4206
|
-
const f =
|
|
4206
|
+
return t.length > 0 ? t.forEach((o, a) => {
|
|
4207
|
+
const l = this.createSectionHeader(o, a);
|
|
4208
|
+
l && i.push(l), o.items.forEach((c, u) => {
|
|
4209
|
+
const f = a * 1e3 + u, p = this.props.getItemId ? this.props.getItemId(c, f) : f, v = s.has(p);
|
|
4207
4210
|
i.push(this.createListItem(c, f, v)), r && u < o.items.length - 1 && i.push(r);
|
|
4208
4211
|
});
|
|
4209
|
-
const h = this.createSectionFooter(o,
|
|
4212
|
+
const h = this.createSectionFooter(o, a);
|
|
4210
4213
|
h && i.push(h);
|
|
4211
|
-
}) : e.forEach((o,
|
|
4212
|
-
const
|
|
4213
|
-
i.push(this.createListItem(o,
|
|
4214
|
+
}) : e.forEach((o, a) => {
|
|
4215
|
+
const l = this.props.getItemId ? this.props.getItemId(o, a) : a, h = s.has(l);
|
|
4216
|
+
i.push(this.createListItem(o, a, h)), r && a < e.length - 1 && i.push(r);
|
|
4214
4217
|
}), i;
|
|
4215
4218
|
}
|
|
4216
4219
|
/**
|
|
@@ -4236,14 +4239,14 @@ class us {
|
|
|
4236
4239
|
children: s,
|
|
4237
4240
|
onScroll: this.handleListScroll
|
|
4238
4241
|
};
|
|
4239
|
-
return new
|
|
4242
|
+
return new ds(r).render();
|
|
4240
4243
|
}
|
|
4241
4244
|
}
|
|
4242
4245
|
function Z(n) {
|
|
4243
|
-
const e = new
|
|
4244
|
-
return
|
|
4246
|
+
const e = new ps(n);
|
|
4247
|
+
return pe(e);
|
|
4245
4248
|
}
|
|
4246
|
-
const
|
|
4249
|
+
const As = {
|
|
4247
4250
|
/**
|
|
4248
4251
|
* Create a simple list from array
|
|
4249
4252
|
*/
|
|
@@ -4289,7 +4292,7 @@ const Ms = {
|
|
|
4289
4292
|
}
|
|
4290
4293
|
};
|
|
4291
4294
|
export {
|
|
4292
|
-
|
|
4295
|
+
ps as E,
|
|
4293
4296
|
Z as L,
|
|
4294
|
-
|
|
4297
|
+
As as a
|
|
4295
4298
|
};
|