@ikonai/sdk-react-ui 0.0.9 → 0.0.11

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,2 +1,3 @@
1
1
  import { IkonUiComponentResolver } from '../ikon-ui-registry';
2
2
  export declare function createBaseDivResolver(): IkonUiComponentResolver;
3
+ export declare function createBaseResolvers(): IkonUiComponentResolver[];
@@ -1,5 +1,6 @@
1
- import { IkonUiComponentResolver, IkonUiModuleLoader, IkonUiRegistry } from '../ikon-ui-registry';
1
+ import { IkonUiModuleLoader, IkonUiRegistry } from '../ikon-ui-registry';
2
+ import { createBaseResolvers } from './base-div';
2
3
  export declare const IKON_UI_BASE_MODULE = "base";
3
- export declare function createBaseResolvers(): IkonUiComponentResolver[];
4
4
  export declare const loadBaseModule: IkonUiModuleLoader;
5
5
  export declare function registerBaseModule(registry: IkonUiRegistry): void;
6
+ export { createBaseResolvers };
package/index.js CHANGED
@@ -1,8 +1,8 @@
1
- import { createLogger as B } from "@ikonai/sdk";
2
- import { IkonUICore as Te, UiStreamStore as Re } from "@ikonai/sdk-ui";
3
- import { UiStreamStore as Mt } from "@ikonai/sdk-ui";
4
- import we, { useSyncExternalStore as Ce, Fragment as Ne, useMemo as Oe, memo as ke, useCallback as re, useEffect as ne } from "react";
5
- var x = { exports: {} }, j = {};
1
+ import { IkonUICore as Ne, UiStreamStore as we } from "@ikonai/sdk-ui";
2
+ import { UiStreamStore as Lt } from "@ikonai/sdk-ui";
3
+ import Oe, { useSyncExternalStore as Ae, Fragment as _e, useMemo as Me, memo as B, useEffect as G, useCallback as ae } from "react";
4
+ import { createLogger as K } from "@ikonai/sdk";
5
+ var z = { exports: {} }, j = {};
6
6
  /**
7
7
  * @license React
8
8
  * react-jsx-runtime.production.js
@@ -12,17 +12,17 @@ var x = { exports: {} }, j = {};
12
12
  * This source code is licensed under the MIT license found in the
13
13
  * LICENSE file in the root directory of this source tree.
14
14
  */
15
- var se;
16
- function Ae() {
17
- if (se) return j;
18
- se = 1;
15
+ var ce;
16
+ function je() {
17
+ if (ce) return j;
18
+ ce = 1;
19
19
  var n = Symbol.for("react.transitional.element"), e = Symbol.for("react.fragment");
20
20
  function t(r, s, i) {
21
21
  var a = null;
22
22
  if (i !== void 0 && (a = "" + i), s.key !== void 0 && (a = "" + s.key), "key" in s) {
23
23
  i = {};
24
- for (var l in s)
25
- l !== "key" && (i[l] = s[l]);
24
+ for (var c in s)
25
+ c !== "key" && (i[c] = s[c]);
26
26
  } else i = s;
27
27
  return s = i.ref, {
28
28
  $$typeof: n,
@@ -44,26 +44,26 @@ var I = {};
44
44
  * This source code is licensed under the MIT license found in the
45
45
  * LICENSE file in the root directory of this source tree.
46
46
  */
47
- var oe;
48
- function _e() {
49
- return oe || (oe = 1, process.env.NODE_ENV !== "production" && function() {
47
+ var le;
48
+ function Ie() {
49
+ return le || (le = 1, process.env.NODE_ENV !== "production" && function() {
50
50
  function n(o) {
51
51
  if (o == null) return null;
52
52
  if (typeof o == "function")
53
- return o.$$typeof === be ? null : o.displayName || o.name || null;
53
+ return o.$$typeof === Te ? null : o.displayName || o.name || null;
54
54
  if (typeof o == "string") return o;
55
55
  switch (o) {
56
56
  case b:
57
57
  return "Fragment";
58
- case h:
58
+ case p:
59
59
  return "Profiler";
60
60
  case f:
61
61
  return "StrictMode";
62
- case k:
62
+ case A:
63
63
  return "Suspense";
64
64
  case L:
65
65
  return "SuspenseList";
66
- case ge:
66
+ case Re:
67
67
  return "Activity";
68
68
  }
69
69
  if (typeof o == "object")
@@ -72,19 +72,19 @@ function _e() {
72
72
  ), o.$$typeof) {
73
73
  case _:
74
74
  return "Portal";
75
- case w:
75
+ case C:
76
76
  return (o.displayName || "Context") + ".Provider";
77
77
  case y:
78
78
  return (o._context.displayName || "Context") + ".Consumer";
79
- case R:
80
- var c = o.render;
81
- return o = o.displayName, o || (o = c.displayName || c.name || "", o = o !== "" ? "ForwardRef(" + o + ")" : "ForwardRef"), o;
82
- case Se:
83
- return c = o.displayName || null, c !== null ? c : n(o.type) || "Memo";
84
- case X:
85
- c = o._payload, o = o._init;
79
+ case T:
80
+ var u = o.render;
81
+ return o = o.displayName, o || (o = u.displayName || u.name || "", o = o !== "" ? "ForwardRef(" + o + ")" : "ForwardRef"), o;
82
+ case Ee:
83
+ return u = o.displayName || null, u !== null ? u : n(o.type) || "Memo";
84
+ case ee:
85
+ u = o._payload, o = o._init;
86
86
  try {
87
- return n(o(c));
87
+ return n(o(u));
88
88
  } catch {
89
89
  }
90
90
  }
@@ -96,15 +96,15 @@ function _e() {
96
96
  function t(o) {
97
97
  try {
98
98
  e(o);
99
- var c = !1;
99
+ var u = !1;
100
100
  } catch {
101
- c = !0;
101
+ u = !0;
102
102
  }
103
- if (c) {
104
- c = console;
105
- var m = c.error, S = typeof Symbol == "function" && Symbol.toStringTag && o[Symbol.toStringTag] || o.constructor.name || "Object";
106
- return m.call(
107
- c,
103
+ if (u) {
104
+ u = console;
105
+ var h = u.error, S = typeof Symbol == "function" && Symbol.toStringTag && o[Symbol.toStringTag] || o.constructor.name || "Object";
106
+ return h.call(
107
+ u,
108
108
  "The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",
109
109
  S
110
110
  ), e(o);
@@ -112,57 +112,57 @@ function _e() {
112
112
  }
113
113
  function r(o) {
114
114
  if (o === b) return "<>";
115
- if (typeof o == "object" && o !== null && o.$$typeof === X)
115
+ if (typeof o == "object" && o !== null && o.$$typeof === ee)
116
116
  return "<...>";
117
117
  try {
118
- var c = n(o);
119
- return c ? "<" + c + ">" : "<...>";
118
+ var u = n(o);
119
+ return u ? "<" + u + ">" : "<...>";
120
120
  } catch {
121
121
  return "<...>";
122
122
  }
123
123
  }
124
124
  function s() {
125
- var o = F.A;
125
+ var o = $.A;
126
126
  return o === null ? null : o.getOwner();
127
127
  }
128
128
  function i() {
129
129
  return Error("react-stack-top-frame");
130
130
  }
131
131
  function a(o) {
132
- if (H.call(o, "key")) {
133
- var c = Object.getOwnPropertyDescriptor(o, "key").get;
134
- if (c && c.isReactWarning) return !1;
132
+ if (te.call(o, "key")) {
133
+ var u = Object.getOwnPropertyDescriptor(o, "key").get;
134
+ if (u && u.isReactWarning) return !1;
135
135
  }
136
136
  return o.key !== void 0;
137
137
  }
138
- function l(o, c) {
139
- function m() {
140
- K || (K = !0, console.error(
138
+ function c(o, u) {
139
+ function h() {
140
+ re || (re = !0, console.error(
141
141
  "%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)",
142
- c
142
+ u
143
143
  ));
144
144
  }
145
- m.isReactWarning = !0, Object.defineProperty(o, "key", {
146
- get: m,
145
+ h.isReactWarning = !0, Object.defineProperty(o, "key", {
146
+ get: h,
147
147
  configurable: !0
148
148
  });
149
149
  }
150
- function u() {
150
+ function l() {
151
151
  var o = n(this.type);
152
- return Z[o] || (Z[o] = !0, console.error(
152
+ return ne[o] || (ne[o] = !0, console.error(
153
153
  "Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release."
154
154
  )), o = this.props.ref, o !== void 0 ? o : null;
155
155
  }
156
- function d(o, c, m, S, N, C, D, q) {
157
- return m = C.ref, o = {
156
+ function d(o, u, h, S, w, k, q, Y) {
157
+ return h = k.ref, o = {
158
158
  $$typeof: O,
159
159
  type: o,
160
- key: c,
161
- props: C,
162
- _owner: N
163
- }, (m !== void 0 ? m : null) !== null ? Object.defineProperty(o, "ref", {
160
+ key: u,
161
+ props: k,
162
+ _owner: w
163
+ }, (h !== void 0 ? h : null) !== null ? Object.defineProperty(o, "ref", {
164
164
  enumerable: !1,
165
- get: u
165
+ get: l
166
166
  }) : Object.defineProperty(o, "ref", { enumerable: !1, value: null }), o._store = {}, Object.defineProperty(o._store, "validated", {
167
167
  configurable: !1,
168
168
  enumerable: !1,
@@ -177,19 +177,19 @@ function _e() {
177
177
  configurable: !1,
178
178
  enumerable: !1,
179
179
  writable: !0,
180
- value: D
180
+ value: q
181
181
  }), Object.defineProperty(o, "_debugTask", {
182
182
  configurable: !1,
183
183
  enumerable: !1,
184
184
  writable: !0,
185
- value: q
185
+ value: Y
186
186
  }), Object.freeze && (Object.freeze(o.props), Object.freeze(o)), o;
187
187
  }
188
- function p(o, c, m, S, N, C, D, q) {
189
- var g = c.children;
188
+ function m(o, u, h, S, w, k, q, Y) {
189
+ var g = u.children;
190
190
  if (g !== void 0)
191
191
  if (S)
192
- if (ve(g)) {
192
+ if (Ce(g)) {
193
193
  for (S = 0; S < g.length; S++)
194
194
  E(g[S]);
195
195
  Object.freeze && Object.freeze(g);
@@ -198,12 +198,12 @@ function _e() {
198
198
  "React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead."
199
199
  );
200
200
  else E(g);
201
- if (H.call(c, "key")) {
201
+ if (te.call(u, "key")) {
202
202
  g = n(o);
203
- var M = Object.keys(c).filter(function(Ee) {
204
- return Ee !== "key";
203
+ var M = Object.keys(u).filter(function(ke) {
204
+ return ke !== "key";
205
205
  });
206
- S = 0 < M.length ? "{key: someKey, " + M.join(": ..., ") + ": ...}" : "{key: someKey}", te[g + S] || (M = 0 < M.length ? "{" + M.join(": ..., ") + ": ...}" : "{}", console.error(
206
+ S = 0 < M.length ? "{key: someKey, " + M.join(": ..., ") + ": ...}" : "{key: someKey}", ie[g + S] || (M = 0 < M.length ? "{" + M.join(": ..., ") + ": ...}" : "{}", console.error(
207
207
  `A props object containing a "key" prop is being spread into JSX:
208
208
  let props = %s;
209
209
  <%s {...props} />
@@ -214,83 +214,83 @@ React keys must be passed directly to JSX without using spread:
214
214
  g,
215
215
  M,
216
216
  g
217
- ), te[g + S] = !0);
217
+ ), ie[g + S] = !0);
218
218
  }
219
- if (g = null, m !== void 0 && (t(m), g = "" + m), a(c) && (t(c.key), g = "" + c.key), "key" in c) {
220
- m = {};
221
- for (var Y in c)
222
- Y !== "key" && (m[Y] = c[Y]);
223
- } else m = c;
224
- return g && l(
225
- m,
219
+ if (g = null, h !== void 0 && (t(h), g = "" + h), a(u) && (t(u.key), g = "" + u.key), "key" in u) {
220
+ h = {};
221
+ for (var W in u)
222
+ W !== "key" && (h[W] = u[W]);
223
+ } else h = u;
224
+ return g && c(
225
+ h,
226
226
  typeof o == "function" ? o.displayName || o.name || "Unknown" : o
227
227
  ), d(
228
228
  o,
229
229
  g,
230
- C,
231
- N,
230
+ k,
231
+ w,
232
232
  s(),
233
- m,
234
- D,
235
- q
233
+ h,
234
+ q,
235
+ Y
236
236
  );
237
237
  }
238
238
  function E(o) {
239
239
  typeof o == "object" && o !== null && o.$$typeof === O && o._store && (o._store.validated = 1);
240
240
  }
241
- var T = we, O = Symbol.for("react.transitional.element"), _ = Symbol.for("react.portal"), b = Symbol.for("react.fragment"), f = Symbol.for("react.strict_mode"), h = Symbol.for("react.profiler"), y = Symbol.for("react.consumer"), w = Symbol.for("react.context"), R = Symbol.for("react.forward_ref"), k = Symbol.for("react.suspense"), L = Symbol.for("react.suspense_list"), Se = Symbol.for("react.memo"), X = Symbol.for("react.lazy"), ge = Symbol.for("react.activity"), be = Symbol.for("react.client.reference"), F = T.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, H = Object.prototype.hasOwnProperty, ve = Array.isArray, $ = console.createTask ? console.createTask : function() {
241
+ var R = Oe, O = Symbol.for("react.transitional.element"), _ = Symbol.for("react.portal"), b = Symbol.for("react.fragment"), f = Symbol.for("react.strict_mode"), p = Symbol.for("react.profiler"), y = Symbol.for("react.consumer"), C = Symbol.for("react.context"), T = Symbol.for("react.forward_ref"), A = Symbol.for("react.suspense"), L = Symbol.for("react.suspense_list"), Ee = Symbol.for("react.memo"), ee = Symbol.for("react.lazy"), Re = Symbol.for("react.activity"), Te = Symbol.for("react.client.reference"), $ = R.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, te = Object.prototype.hasOwnProperty, Ce = Array.isArray, D = console.createTask ? console.createTask : function() {
242
242
  return null;
243
243
  };
244
- T = {
244
+ R = {
245
245
  "react-stack-bottom-frame": function(o) {
246
246
  return o();
247
247
  }
248
248
  };
249
- var K, Z = {}, Q = T["react-stack-bottom-frame"].bind(
250
- T,
249
+ var re, ne = {}, se = R["react-stack-bottom-frame"].bind(
250
+ R,
251
251
  i
252
- )(), ee = $(r(i)), te = {};
253
- I.Fragment = b, I.jsx = function(o, c, m, S, N) {
254
- var C = 1e4 > F.recentlyCreatedOwnerStacks++;
255
- return p(
252
+ )(), oe = D(r(i)), ie = {};
253
+ I.Fragment = b, I.jsx = function(o, u, h, S, w) {
254
+ var k = 1e4 > $.recentlyCreatedOwnerStacks++;
255
+ return m(
256
256
  o,
257
- c,
258
- m,
257
+ u,
258
+ h,
259
259
  !1,
260
260
  S,
261
- N,
262
- C ? Error("react-stack-top-frame") : Q,
263
- C ? $(r(o)) : ee
261
+ w,
262
+ k ? Error("react-stack-top-frame") : se,
263
+ k ? D(r(o)) : oe
264
264
  );
265
- }, I.jsxs = function(o, c, m, S, N) {
266
- var C = 1e4 > F.recentlyCreatedOwnerStacks++;
267
- return p(
265
+ }, I.jsxs = function(o, u, h, S, w) {
266
+ var k = 1e4 > $.recentlyCreatedOwnerStacks++;
267
+ return m(
268
268
  o,
269
- c,
270
- m,
269
+ u,
270
+ h,
271
271
  !0,
272
272
  S,
273
- N,
274
- C ? Error("react-stack-top-frame") : Q,
275
- C ? $(r(o)) : ee
273
+ w,
274
+ k ? Error("react-stack-top-frame") : se,
275
+ k ? D(r(o)) : oe
276
276
  );
277
277
  };
278
278
  }()), I;
279
279
  }
280
- var ie;
281
- function Me() {
282
- return ie || (ie = 1, process.env.NODE_ENV === "production" ? x.exports = Ae() : x.exports = _e()), x.exports;
280
+ var ue;
281
+ function Pe() {
282
+ return ue || (ue = 1, process.env.NODE_ENV === "production" ? z.exports = je() : z.exports = Ie()), z.exports;
283
283
  }
284
- var A = Me();
285
- function je(n) {
286
- return Ce(
284
+ var N = Pe();
285
+ function Ue(n) {
286
+ return Ae(
287
287
  (e) => n.subscribe(e),
288
288
  () => n.getSnapshot(),
289
289
  () => n.getSnapshot()
290
290
  );
291
291
  }
292
- const Ie = B("UIRenderer");
293
- function Pe(n) {
292
+ const xe = K("UIRenderer");
293
+ function Le(n) {
294
294
  if (n === void 0)
295
295
  return "{}";
296
296
  if (typeof n == "string")
@@ -301,26 +301,26 @@ function Pe(n) {
301
301
  return "{}";
302
302
  }
303
303
  }
304
- function me(n) {
305
- const e = Le(n), t = Ue(n);
304
+ function be(n) {
305
+ const e = Fe(n), t = ze(n);
306
306
  return e === n.children && t === n.styleIds ? n : {
307
307
  ...n,
308
308
  ...e !== n.children ? { children: e } : {},
309
309
  ...t !== n.styleIds ? { styleIds: t } : {}
310
310
  };
311
311
  }
312
- function Ue(n) {
312
+ function ze(n) {
313
313
  const e = n.styleIds;
314
314
  return Array.isArray(e) ? e : [];
315
315
  }
316
- function Le(n) {
316
+ function Fe(n) {
317
317
  const e = n.children;
318
318
  return Array.isArray(e) ? e : [];
319
319
  }
320
- function xe({ node: n, renderer: e, library: t, context: r, className: s }) {
321
- const i = me(n), a = i.children.map((u) => U(u, t, r)), l = e;
322
- return /* @__PURE__ */ A.jsx(
323
- l,
320
+ function Be({ node: n, renderer: e, library: t, context: r, className: s }) {
321
+ const i = be(n), a = i.children.map((l) => U(l, t, r)), c = e;
322
+ return /* @__PURE__ */ N.jsx(
323
+ c,
324
324
  {
325
325
  node: i,
326
326
  context: r,
@@ -331,47 +331,47 @@ function xe({ node: n, renderer: e, library: t, context: r, className: s }) {
331
331
  );
332
332
  }
333
333
  function U(n, e, t) {
334
- const r = me(n), s = r.children;
334
+ const r = be(n), s = r.children;
335
335
  if (r.type === "root")
336
- return /* @__PURE__ */ A.jsx(Ne, { children: s.map((u) => U(u, e, t)) }, r.id);
336
+ return /* @__PURE__ */ N.jsx(_e, { children: s.map((l) => U(l, e, t)) }, r.id);
337
337
  const i = e.resolve(r);
338
338
  if (!i)
339
- return Ie.warn(`No renderer for node type ${r.type}`), null;
340
- const a = r.styleIds, l = a.length > 0 ? a.join(" ") : void 0;
341
- return /* @__PURE__ */ A.jsx(
342
- xe,
339
+ return xe.warn(`No renderer for node type ${r.type}`), null;
340
+ const a = r.styleIds, c = a.length > 0 ? a.join(" ") : void 0;
341
+ return /* @__PURE__ */ N.jsx(
342
+ Be,
343
343
  {
344
344
  node: r,
345
345
  renderer: i,
346
346
  library: e,
347
347
  context: t,
348
- className: l
348
+ className: c
349
349
  },
350
350
  r.id
351
351
  );
352
352
  }
353
- function ze({ store: n, library: e, containerId: t, emptyFallback: r = null, onAction: s }) {
354
- const i = je(n), a = t ?? i.rootContainerId;
353
+ function $e({ store: n, library: e, containerId: t, emptyFallback: r = null, onAction: s }) {
354
+ const i = Ue(n), a = t ?? i.rootContainerId;
355
355
  if (!a) return r;
356
- const l = i.containers.get(a);
357
- if (!l) return r;
358
- const u = {
356
+ const c = i.containers.get(a);
357
+ if (!c) return r;
358
+ const l = {
359
359
  getPayload: (d) => i.payloads.get(d),
360
- renderChildren: (d) => Array.isArray(d) ? d.map((p) => U(p, e, u)) : [],
360
+ renderChildren: (d) => Array.isArray(d) ? d.map((m) => U(m, e, l)) : [],
361
361
  renderContainer: (d) => {
362
- const p = i.containers.get(d);
363
- return p ? U(p, e, u) : null;
362
+ const m = i.containers.get(d);
363
+ return m ? U(m, e, l) : null;
364
364
  },
365
- dispatchAction: (d, p) => {
365
+ dispatchAction: (d, m) => {
366
366
  if (!d)
367
367
  return;
368
- const E = Pe(p);
368
+ const E = Le(m);
369
369
  s?.(d, E);
370
370
  }
371
371
  };
372
- return U(l, e, u);
372
+ return U(c, e, l);
373
373
  }
374
- class Be {
374
+ class De {
375
375
  constructor(e, t) {
376
376
  if (this.fallback = t, e)
377
377
  for (const [r, s] of e)
@@ -388,29 +388,28 @@ class Be {
388
388
  return this.renderers.get(e.type) ?? this.fallback;
389
389
  }
390
390
  }
391
- function Et(n, e) {
391
+ function wt(n, e) {
392
392
  const t = Object.entries(n);
393
- return new Be(t, e);
393
+ return new De(t, e);
394
394
  }
395
- const J = "ikon-ui";
396
- function Fe(n, e) {
395
+ const H = "ikon-ui";
396
+ function qe(n, e) {
397
397
  return n === e;
398
398
  }
399
- function Tt({ stores: n, library: e, category: t = J, version: r, onAction: s }) {
400
- const i = Oe(() => {
399
+ function Ot({ stores: n, library: e, category: t = H, version: r, onAction: s }) {
400
+ const i = Me(() => {
401
401
  const a = [];
402
- for (const [l, u] of n) {
403
- if (!Fe(u.category, t))
402
+ for (const [c, l] of n) {
403
+ if (!qe(l.category, t))
404
404
  continue;
405
- const d = u.store.getSnapshot();
406
- !d.rootContainerId || !d.containers.has(d.rootContainerId) || a.push({ key: l, store: u.store });
405
+ const d = l.store.getSnapshot();
406
+ !d.rootContainerId || !d.containers.has(d.rootContainerId) || a.push({ key: c, store: l.store });
407
407
  }
408
408
  return a;
409
409
  }, [n, t, r]);
410
- return i.length === 0 ? null : /* @__PURE__ */ A.jsx(A.Fragment, { children: i.map(({ key: a, store: l }) => /* @__PURE__ */ A.jsx(ze, { store: l, library: e, onAction: s }, a)) });
410
+ return i.length === 0 ? null : /* @__PURE__ */ N.jsx(N.Fragment, { children: i.map(({ key: a, store: c }) => /* @__PURE__ */ N.jsx($e, { store: c, library: e, onAction: s }, a)) });
411
411
  }
412
- B("IkonUI");
413
- class Rt {
412
+ class At {
414
413
  core;
415
414
  ownsCore;
416
415
  stores = /* @__PURE__ */ new Map();
@@ -419,7 +418,7 @@ class Rt {
419
418
  unsubscribeClears;
420
419
  unsubscribeStoreChanges;
421
420
  constructor(e) {
422
- this.core = e?.core ?? new Te({ client: e?.client }), this.ownsCore = !e?.core, this.unsubscribeUpdates = this.core.subscribeToUiUpdates(this.handleUiUpdate), this.unsubscribeClears = this.core.subscribeToUiStreamCleared(this.handleUiStreamCleared), this.unsubscribeStoreChanges = this.core.uiStore.subscribe(this.syncStreamSnapshot), this.syncAllStreams();
421
+ this.core = e?.core ?? new Ne({ client: e?.client }), this.ownsCore = !e?.core, this.unsubscribeUpdates = this.core.subscribeToUiUpdates(this.handleUiUpdate), this.unsubscribeClears = this.core.subscribeToUiStreamCleared(this.handleUiStreamCleared), this.unsubscribeStoreChanges = this.core.uiStore.subscribe(this.syncStreamSnapshot), this.syncAllStreams();
423
422
  }
424
423
  dispose() {
425
424
  this.unsubscribeUpdates(), this.unsubscribeClears(), this.unsubscribeStoreChanges(), this.ownsCore && this.core.dispose(), this.listeners.clear(), this.stores.clear();
@@ -464,8 +463,8 @@ class Rt {
464
463
  root: r
465
464
  },
466
465
  payloads: t.payloads
467
- }, a = s.store.apply(i), l = this.updateCategory(e, t.category);
468
- (a || l) && this.notify(e);
466
+ }, a = s.store.apply(i), c = this.updateCategory(e, t.category);
467
+ (a || c) && this.notify(e);
469
468
  };
470
469
  syncAllStreams() {
471
470
  const e = this.core.uiStore.getSnapshots(), t = /* @__PURE__ */ new Set();
@@ -479,8 +478,8 @@ class Rt {
479
478
  if (t)
480
479
  return t;
481
480
  const r = {
482
- category: J,
483
- store: new Re()
481
+ category: H,
482
+ store: new we()
484
483
  };
485
484
  return this.stores.set(e, r), r;
486
485
  }
@@ -488,7 +487,7 @@ class Rt {
488
487
  const r = this.stores.get(e);
489
488
  if (!r)
490
489
  return !1;
491
- const s = t ?? this.core.uiStore.getSnapshot(e)?.category ?? J;
490
+ const s = t ?? this.core.uiStore.getSnapshot(e)?.category ?? H;
492
491
  return r.category === s ? !1 : (this.stores.set(e, { ...r, category: s }), !0);
493
492
  }
494
493
  notify(e) {
@@ -496,26 +495,118 @@ class Rt {
496
495
  t(e);
497
496
  }
498
497
  }
499
- function $e() {
500
- const n = ke(function({ node: t, context: r, className: s }) {
501
- const i = t.children?.length ? r.renderChildren(t.children) : void 0;
502
- return /* @__PURE__ */ A.jsx("div", { className: s, children: i });
498
+ function x(n) {
499
+ if (typeof n == "string") {
500
+ const e = n.trim();
501
+ return e.length > 0 ? e : void 0;
502
+ }
503
+ if (Array.isArray(n)) {
504
+ const e = n.filter((t) => typeof t == "string").map((t) => t.trim()).filter(Boolean);
505
+ return e.length > 0 ? e.join(" ") : void 0;
506
+ }
507
+ }
508
+ function Z(...n) {
509
+ const e = [];
510
+ for (const t of n)
511
+ t && t.trim() && e.push(t.trim());
512
+ return e.length > 0 ? e.join(" ") : void 0;
513
+ }
514
+ function Q(n) {
515
+ if (!n)
516
+ return {};
517
+ const e = {};
518
+ for (const [t, r] of Object.entries(n))
519
+ r != null && (typeof r == "string" || typeof r == "number" || typeof r == "boolean") && (e[t] = r);
520
+ return e;
521
+ }
522
+ function Ye() {
523
+ const n = B(function({ node: t }) {
524
+ const r = x(t.props?.targetElementId ?? t.props?.TargetElementId), s = x(t.props?.targetContainerId ?? t.props?.TargetContainerId), i = t.props?.focusOnly ?? t.props?.FocusOnly, a = typeof i == "boolean" ? i : void 0;
525
+ return G(() => {
526
+ if (typeof document > "u")
527
+ return;
528
+ const c = (r ? document.querySelector(`[data-ikon-element-id="${r}"]`) : null) ?? (r ? document.getElementById(r) : null);
529
+ if (!c)
530
+ return;
531
+ const l = (s ? document.querySelector(`[data-ikon-container-id="${s}"]`) : null) ?? c.closest("[data-ikon-container-id]") ?? c.closest('[data-ikon-container-type="scroll-view"]') ?? c;
532
+ if (l && l !== c && typeof l.scrollIntoView == "function")
533
+ try {
534
+ l.scrollIntoView({ behavior: "smooth", block: "nearest" });
535
+ } catch {
536
+ l.scrollIntoView();
537
+ }
538
+ if (typeof c.focus == "function")
539
+ try {
540
+ c.focus({ preventScroll: a !== !1 });
541
+ } catch {
542
+ c.focus();
543
+ }
544
+ }, [a, s, r]), null;
545
+ });
546
+ return ({ type: e }) => {
547
+ if (e === "common.focus-hint")
548
+ return n;
549
+ };
550
+ }
551
+ function We() {
552
+ const n = B(function({ node: t, context: r, className: s }) {
553
+ const i = Q(t.props), a = Z(x(t.props?.className), s), c = t.children?.length ? r.renderChildren(t.children) : void 0;
554
+ return /* @__PURE__ */ N.jsx("div", { ...i, "data-ikon-element-id": t.id, className: a, children: c });
503
555
  });
504
556
  return ({ type: e }) => {
505
557
  if (e === "common.div")
506
558
  return n;
507
559
  };
508
560
  }
509
- const De = "base";
510
- function qe() {
511
- return [$e()];
561
+ function Ve() {
562
+ const n = B(function({ node: t, context: r, className: s }) {
563
+ const i = Q(t.props), a = Z(x(t.props?.className), s), c = t.children?.length ? r.renderChildren(t.children) : void 0;
564
+ return /* @__PURE__ */ N.jsx(
565
+ "form",
566
+ {
567
+ ...i,
568
+ "data-ikon-element-id": t.id,
569
+ "data-ikon-container-id": t.id,
570
+ className: a,
571
+ onSubmit: (l) => l.preventDefault(),
572
+ children: c
573
+ }
574
+ );
575
+ });
576
+ return ({ type: e }) => {
577
+ if (e === "common.form")
578
+ return n;
579
+ };
580
+ }
581
+ function Je() {
582
+ const n = B(function({ node: t, context: r, className: s }) {
583
+ const i = Q(t.props), a = Z(x(t.props?.className), s), c = t.children?.length ? r.renderChildren(t.children) : void 0;
584
+ return /* @__PURE__ */ N.jsx(
585
+ "div",
586
+ {
587
+ ...i,
588
+ "data-ikon-element-id": t.id,
589
+ "data-ikon-container-id": t.id,
590
+ "data-ikon-container-type": "scroll-view",
591
+ className: a,
592
+ children: c
593
+ }
594
+ );
595
+ });
596
+ return ({ type: e }) => {
597
+ if (e === "common.scroll-view")
598
+ return n;
599
+ };
512
600
  }
513
- const Ye = async () => qe();
514
- function We(n) {
515
- n.registerModule(De, Ye);
601
+ function Ge() {
602
+ return [We(), Ve(), Je(), Ye()];
516
603
  }
517
- const ae = B("UIRegistry");
518
- class Ve {
604
+ const He = "base", Xe = async () => Ge();
605
+ function Ke(n) {
606
+ n.registerModule(He, Xe);
607
+ }
608
+ const de = K("UIRegistry");
609
+ class Ze {
519
610
  baseResolvers = [];
520
611
  moduleLoaders = /* @__PURE__ */ new Map();
521
612
  moduleResolvers = /* @__PURE__ */ new Map();
@@ -537,15 +628,15 @@ class Ve {
537
628
  for (const [r, s] of this.moduleLoaders.entries())
538
629
  if (!this.moduleResolvers.has(r))
539
630
  try {
540
- const i = await s(), a = Ge(i);
631
+ const i = await s(), a = et(i);
541
632
  this.moduleResolvers.set(r, a), e = !0;
542
633
  } catch (i) {
543
- ae.error(`[IkonUiRegistry] Failed to load module '${r}'.`, i);
634
+ de.error(`[IkonUiRegistry] Failed to load module '${r}'.`, i);
544
635
  }
545
636
  const t = [];
546
637
  for (const r of this.moduleLoaders.keys())
547
638
  this.moduleResolvers.has(r) && t.push(r);
548
- return Xe(t, this.activeModuleOrder) || (this.activeModuleOrder = t, e = !0), e;
639
+ return tt(t, this.activeModuleOrder) || (this.activeModuleOrder = t, e = !0), e;
549
640
  }
550
641
  resolve(e) {
551
642
  for (const t of this.baseResolvers) {
@@ -555,7 +646,7 @@ class Ve {
555
646
  for (const t of this.activeModuleOrder) {
556
647
  const r = this.moduleResolvers.get(t);
557
648
  if (!r) {
558
- ae.warn(`Missing resolvers for module ${t}`);
649
+ de.warn(`Missing resolvers for module ${t}`);
559
650
  continue;
560
651
  }
561
652
  for (const s of r) {
@@ -565,17 +656,17 @@ class Ve {
565
656
  }
566
657
  }
567
658
  }
568
- function wt() {
569
- const n = new Ve();
570
- return We(n), n.loadRegisteredModules(), n;
659
+ function _t() {
660
+ const n = new Ze();
661
+ return Ke(n), n.loadRegisteredModules(), n;
571
662
  }
572
- function Je(n) {
663
+ function Qe(n) {
573
664
  return Array.isArray(n) ? n : [n];
574
665
  }
575
- function Ge(n) {
576
- return n ? Je(n).flatMap((e) => e ? Array.isArray(e) ? e.filter(Boolean) : [e] : []) : [];
666
+ function et(n) {
667
+ return n ? Qe(n).flatMap((e) => e ? Array.isArray(e) ? e.filter(Boolean) : [e] : []) : [];
577
668
  }
578
- function Xe(n, e) {
669
+ function tt(n, e) {
579
670
  if (n.length !== e.length)
580
671
  return !1;
581
672
  for (let t = 0; t < n.length; t += 1)
@@ -583,7 +674,7 @@ function Xe(n, e) {
583
674
  return !1;
584
675
  return !0;
585
676
  }
586
- const W = B("MotionController"), ce = {
677
+ const V = K("MotionController"), fe = {
587
678
  ease: [0.25, 0.1, 0.25, 1],
588
679
  "ease-in": [0.42, 0, 1, 1],
589
680
  "ease-out": [0, 0, 0.58, 1],
@@ -616,86 +707,85 @@ const W = B("MotionController"), ce = {
616
707
  function v(n) {
617
708
  return n <= 0 ? 0 : n >= 1 ? 1 : n;
618
709
  }
619
- function le(n) {
710
+ function pe(n) {
620
711
  if (n == null) return;
621
712
  const e = `${n}`.trim();
622
713
  if (!e) return;
623
714
  const t = Number.parseFloat(e);
624
715
  return Number.isFinite(t) ? t : void 0;
625
716
  }
626
- function ue(n) {
627
- const e = globalThis.CSS;
628
- return e?.escape ? e.escape(n) : n.replace(/[^a-zA-Z0-9_-]/g, (t) => `\\${t}`);
717
+ function me(n) {
718
+ return typeof CSS < "u" && CSS.escape ? CSS.escape(n) : n.replace(/[^a-zA-Z0-9_-]/g, (e) => `\\${e}`);
629
719
  }
630
- function de(n, e, t, r) {
631
- const p = new Float32Array(11);
632
- function E(f, h, y) {
633
- return ((3 * h - 3 * y + 1) * f + (3 * y - 6 * h)) * f * f + 3 * h * f;
720
+ function he(n, e, t, r) {
721
+ const m = new Float32Array(11);
722
+ function E(f, p, y) {
723
+ return ((3 * p - 3 * y + 1) * f + (3 * y - 6 * p)) * f * f + 3 * p * f;
634
724
  }
635
- function T(f, h, y) {
636
- return 3 * (3 * h - 3 * y + 1) * f * f + 2 * (3 * y - 6 * h) * f + 3 * h;
725
+ function R(f, p, y) {
726
+ return 3 * (3 * p - 3 * y + 1) * f * f + 2 * (3 * y - 6 * p) * f + 3 * p;
637
727
  }
638
- function O(f, h) {
728
+ function O(f, p) {
639
729
  for (let y = 0; y < 4; y += 1) {
640
- const w = T(h, n, t);
641
- if (w === 0)
642
- return h;
643
- const R = E(h, n, t) - f;
644
- h -= R / w;
730
+ const C = R(p, n, t);
731
+ if (C === 0)
732
+ return p;
733
+ const T = E(p, n, t) - f;
734
+ p -= T / C;
645
735
  }
646
- return h;
736
+ return p;
647
737
  }
648
- function _(f, h, y) {
649
- let w = 0, R = 0, k = 0;
738
+ function _(f, p, y) {
739
+ let C = 0, T = 0, A = 0;
650
740
  do
651
- R = h + (y - h) / 2, w = E(R, n, t) - f, w > 0 ? y = R : h = R;
652
- while (Math.abs(w) > 1e-7 && ++k < 10);
653
- return R;
741
+ T = p + (y - p) / 2, C = E(T, n, t) - f, C > 0 ? y = T : p = T;
742
+ while (Math.abs(C) > 1e-7 && ++A < 10);
743
+ return T;
654
744
  }
655
745
  function b(f) {
656
- let h = 0, y = 1;
657
- const w = 10;
658
- for (; y !== w && p[y] <= f; y += 1)
659
- h += 0.1;
746
+ let p = 0, y = 1;
747
+ const C = 10;
748
+ for (; y !== C && m[y] <= f; y += 1)
749
+ p += 0.1;
660
750
  y -= 1;
661
- const R = (f - p[y]) / (p[y + 1] - p[y]), k = h + R * 0.1, L = T(k, n, t);
662
- return L >= 1e-3 ? O(f, k) : L === 0 ? k : _(f, h, h + 0.1);
751
+ const T = (f - m[y]) / (m[y + 1] - m[y]), A = p + T * 0.1, L = R(A, n, t);
752
+ return L >= 1e-3 ? O(f, A) : L === 0 ? A : _(f, p, p + 0.1);
663
753
  }
664
754
  for (let f = 0; f < 11; f += 1)
665
- p[f] = E(f * 0.1, n, t);
755
+ m[f] = E(f * 0.1, n, t);
666
756
  return (f) => f <= 0 ? 0 : f >= 1 ? 1 : E(b(f), e, r);
667
757
  }
668
- function He(n) {
758
+ function rt(n) {
669
759
  const e = /steps\(\s*([0-9]+)\s*(?:,\s*([a-z-]+)\s*)?\)/i.exec(n);
670
760
  if (!e)
671
761
  return (s) => v(s);
672
762
  const t = Math.max(1, parseInt(e[1], 10)), r = (e[2] ?? "end").toLowerCase();
673
763
  return r === "start" || r === "jump-start" ? (s) => v(Math.ceil(s * t) / t) : r === "none" || r === "jump-none" ? (s) => v(Math.round(s * t) / t) : r === "both" || r === "jump-both" ? (s) => v((Math.floor(s * t) + 0.5) / t) : (s) => v(Math.floor(s * t) / t);
674
764
  }
675
- function Ke(n) {
765
+ function nt(n) {
676
766
  if (!n)
677
767
  return (t) => v(t);
678
768
  const e = n.trim().toLowerCase();
679
769
  if (!e || e === "linear")
680
770
  return (t) => v(t);
681
- if (ce[e]) {
682
- const [t, r, s, i] = ce[e], a = de(t, r, s, i);
683
- return (l) => v(a(v(l)));
771
+ if (fe[e]) {
772
+ const [t, r, s, i] = fe[e], a = he(t, r, s, i);
773
+ return (c) => v(a(v(c)));
684
774
  }
685
775
  if (e.startsWith("cubic-bezier(") && e.endsWith(")")) {
686
776
  const r = e.slice(13, -1).split(",").map((s) => Number.parseFloat(s.trim()));
687
777
  if (r.length === 4 && r.every((s) => Number.isFinite(s))) {
688
- const [s, i, a, l] = r, u = de(s, i, a, l);
689
- return (d) => v(u(v(d)));
778
+ const [s, i, a, c] = r, l = he(s, i, a, c);
779
+ return (d) => v(l(v(d)));
690
780
  }
691
781
  }
692
782
  if (e.startsWith("steps(") && e.endsWith(")")) {
693
- const t = He(e);
783
+ const t = rt(e);
694
784
  return (r) => t(v(r));
695
785
  }
696
786
  return (t) => v(t);
697
787
  }
698
- function Ze(n) {
788
+ function st(n) {
699
789
  if (!n)
700
790
  return;
701
791
  const e = /(-?\d+(?:\.\d+)?)\s*\.\.\s*(-?\d+(?:\.\d+)?)\s*->\s*(-?\d+(?:\.\d+)?)\s*\.\.\s*(-?\d+(?:\.\d+)?)/.exec(n);
@@ -705,7 +795,7 @@ function Ze(n) {
705
795
  if (![t, r, s, i].some((a) => !Number.isFinite(a)))
706
796
  return { inStart: t, inEnd: r, outStart: s, outEnd: i };
707
797
  }
708
- class Qe {
798
+ class ot {
709
799
  bindingsByStyle = /* @__PURE__ */ new Map();
710
800
  observer;
711
801
  observeScheduled = !1;
@@ -729,7 +819,7 @@ class Qe {
729
819
  try {
730
820
  e();
731
821
  } catch (t) {
732
- W.warn("Failed to cleanup binding listener", t);
822
+ V.warn("Failed to cleanup binding listener", t);
733
823
  }
734
824
  this.globalCleanups.clear(), this.elementStates.clear(), this.styleToElements.clear(), this.bindingsByStyle.clear(), this.pendingScanStyles.clear(), this.scanScheduled = !1, this.observer && (this.observer.disconnect(), this.observer = void 0);
735
825
  }
@@ -739,7 +829,7 @@ class Qe {
739
829
  const r = (JSON.parse(e).motionBindings ?? []).map((s) => this.parseBinding(s)).filter((s) => s !== void 0);
740
830
  return r.length === 0 ? void 0 : { bindings: r };
741
831
  } catch (t) {
742
- W.warn("Failed to parse motion metadata", t);
832
+ V.warn("Failed to parse motion metadata", t);
743
833
  return;
744
834
  }
745
835
  }
@@ -747,16 +837,16 @@ class Qe {
747
837
  const t = e.source?.trim();
748
838
  if (!t)
749
839
  return;
750
- const r = le(e.min) ?? 0, s = le(e.max), i = s === void 0 ? r + 100 : s, a = (e.clamp ?? "clamp").trim().toLowerCase(), l = !!e.reverse, u = Ke(e.ease), d = Ze(e.map), p = e.targetId?.trim() || void 0;
840
+ const r = pe(e.min) ?? 0, s = pe(e.max), i = s === void 0 ? r + 100 : s, a = (e.clamp ?? "clamp").trim().toLowerCase(), c = !!e.reverse, l = nt(e.ease), d = st(e.map), m = e.targetId?.trim() || void 0;
751
841
  return Number.isNaN(r) || Number.isNaN(i) ? void 0 : {
752
842
  source: t.toLowerCase(),
753
843
  min: r,
754
844
  max: i,
755
845
  clamp: a === "freeze-start" || a === "freeze-end" || a === "unclamped" ? a : "clamp",
756
- reverse: l,
757
- ease: u,
846
+ reverse: c,
847
+ ease: l,
758
848
  map: d,
759
- targetId: p
849
+ targetId: m
760
850
  };
761
851
  }
762
852
  ensureObserver() {
@@ -805,7 +895,7 @@ class Qe {
805
895
  const t = this.bindingsByStyle.get(e);
806
896
  if (!t || typeof document > "u")
807
897
  return;
808
- const r = `.${ue(e)}`;
898
+ const r = `.${me(e)}`;
809
899
  document.querySelectorAll(r).forEach((i) => this.applyStyleToElement(i, e, t));
810
900
  }
811
901
  applyStyleToElement(e, t, r) {
@@ -840,12 +930,12 @@ class Qe {
840
930
  i();
841
931
  const a = new AbortController();
842
932
  s.addEventListener("scroll", i, { passive: !0, signal: a.signal }), this.registerCleanup(e, t, () => a.abort());
843
- const l = () => i();
844
- window.addEventListener("resize", l), this.registerCleanup(e, t, () => window.removeEventListener("resize", l));
933
+ const c = () => i();
934
+ window.addEventListener("resize", c), this.registerCleanup(e, t, () => window.removeEventListener("resize", c));
845
935
  }
846
936
  resolveScrollContainer(e, t) {
847
937
  if (t.targetId) {
848
- const r = `[data-ikon-motion-source="${ue(t.targetId)}"]`, s = typeof document < "u" ? document.querySelector(r) : null;
938
+ const r = `[data-ikon-motion-source="${me(t.targetId)}"]`, s = typeof document < "u" ? document.querySelector(r) : null;
849
939
  if (s)
850
940
  return s;
851
941
  }
@@ -855,10 +945,10 @@ class Qe {
855
945
  const s = t.max - t.min, i = s === 0 ? r > t.min ? 1 : 0 : (r - t.min) / s;
856
946
  let a = this.applyClamp(i, t.clamp);
857
947
  t.reverse && (a = 1 - a);
858
- const l = t.ease(a), u = Number.isFinite(l) ? l : 0, d = u * 100;
859
- if (e.style.setProperty("--tw-motion-bind-source-value", `${r}`), e.style.setProperty("--tw-motion-bind-progress-ratio", `${u}`), e.style.setProperty("--tw-motion-bind-progress", `${d}`), t.map) {
860
- const p = this.applyMap(d, t.map);
861
- p !== void 0 && e.style.setProperty("--tw-motion-bind-value", `${p}`);
948
+ const c = t.ease(a), l = Number.isFinite(c) ? c : 0, d = l * 100;
949
+ if (e.style.setProperty("--tw-motion-bind-source-value", `${r}`), e.style.setProperty("--tw-motion-bind-progress-ratio", `${l}`), e.style.setProperty("--tw-motion-bind-progress", `${d}`), t.map) {
950
+ const m = this.applyMap(d, t.map);
951
+ m !== void 0 && e.style.setProperty("--tw-motion-bind-value", `${m}`);
862
952
  } else
863
953
  e.style.removeProperty("--tw-motion-bind-value");
864
954
  }
@@ -905,14 +995,17 @@ class Qe {
905
995
  this.cleanupElementStyle(e, s);
906
996
  }
907
997
  cleanupElementStyle(e, t) {
908
- const r = this.elementStates.get(e), s = r?.get(t);
998
+ const r = this.elementStates.get(e);
999
+ if (!r)
1000
+ return;
1001
+ const s = r.get(t);
909
1002
  if (!s)
910
1003
  return;
911
1004
  for (const a of s) {
912
1005
  try {
913
1006
  a();
914
- } catch (l) {
915
- W.warn("Failed to cleanup listener", l);
1007
+ } catch (c) {
1008
+ V.warn("Failed to cleanup listener", c);
916
1009
  }
917
1010
  this.globalCleanups.delete(a);
918
1011
  }
@@ -956,16 +1049,16 @@ class Qe {
956
1049
  }
957
1050
  }
958
1051
  }
959
- const fe = new Qe(), V = "ikon-ds";
960
- function Ct(n) {
961
- const e = re(({ styleId: r, css: s, common: i }) => {
1052
+ const ye = new ot(), J = "ikon-ds";
1053
+ function Mt(n) {
1054
+ const e = ae(({ styleId: r, css: s, common: i }) => {
962
1055
  if (!r || typeof document > "u") return;
963
- let a = document.getElementById(V);
964
- a || (a = document.createElement("style"), a.id = V, document.head.appendChild(a)), s && (a.innerHTML += s), fe.registerStyle(r, i);
965
- }, []), t = re(() => {
966
- typeof document < "u" && document.getElementById(V)?.remove(), fe.reset();
1056
+ let a = document.getElementById(J);
1057
+ a || (a = document.createElement("style"), a.id = J, document.head.appendChild(a)), s && (a.innerHTML += s), ye.registerStyle(r, i);
1058
+ }, []), t = ae(() => {
1059
+ typeof document < "u" && document.getElementById(J)?.remove(), ye.reset();
967
1060
  }, []);
968
- return ne(() => {
1061
+ return G(() => {
969
1062
  if (!n) return;
970
1063
  for (const s of n.getUiStyles())
971
1064
  e(s);
@@ -973,50 +1066,50 @@ function Ct(n) {
973
1066
  return () => {
974
1067
  r?.(), t();
975
1068
  };
976
- }, [n, t, e]), ne(() => () => t(), [t]), { setStyle: e, reset: t };
1069
+ }, [n, t, e]), G(() => () => t(), [t]), { setStyle: e, reset: t };
977
1070
  }
978
- var et = typeof global == "object" && global && global.Object === Object && global, tt = typeof self == "object" && self && self.Object === Object && self, rt = et || tt || Function("return this")(), z = rt.Symbol, ye = Object.prototype, nt = ye.hasOwnProperty, st = ye.toString, P = z ? z.toStringTag : void 0;
979
- function ot(n) {
980
- var e = nt.call(n, P), t = n[P];
1071
+ var it = typeof global == "object" && global && global.Object === Object && global, at = typeof self == "object" && self && self.Object === Object && self, ct = it || at || Function("return this")(), F = ct.Symbol, ve = Object.prototype, lt = ve.hasOwnProperty, ut = ve.toString, P = F ? F.toStringTag : void 0;
1072
+ function dt(n) {
1073
+ var e = lt.call(n, P), t = n[P];
981
1074
  try {
982
1075
  n[P] = void 0;
983
1076
  var r = !0;
984
1077
  } catch {
985
1078
  }
986
- var s = st.call(n);
1079
+ var s = ut.call(n);
987
1080
  return r && (e ? n[P] = t : delete n[P]), s;
988
1081
  }
989
- var it = Object.prototype, at = it.toString;
990
- function ct(n) {
991
- return at.call(n);
1082
+ var ft = Object.prototype, pt = ft.toString;
1083
+ function mt(n) {
1084
+ return pt.call(n);
992
1085
  }
993
- var lt = "[object Null]", ut = "[object Undefined]", he = z ? z.toStringTag : void 0;
994
- function dt(n) {
995
- return n == null ? n === void 0 ? ut : lt : he && he in Object(n) ? ot(n) : ct(n);
1086
+ var ht = "[object Null]", yt = "[object Undefined]", Se = F ? F.toStringTag : void 0;
1087
+ function St(n) {
1088
+ return n == null ? n === void 0 ? yt : ht : Se && Se in Object(n) ? dt(n) : mt(n);
996
1089
  }
997
- function ft(n) {
1090
+ function gt(n) {
998
1091
  return n != null && typeof n == "object";
999
1092
  }
1000
- var ht = Array.isArray, pt = "[object String]";
1001
- function mt(n) {
1002
- return typeof n == "string" || !ht(n) && ft(n) && dt(n) == pt;
1093
+ var bt = Array.isArray, vt = "[object String]";
1094
+ function Et(n) {
1095
+ return typeof n == "string" || !bt(n) && gt(n) && St(n) == vt;
1003
1096
  }
1004
- const pe = "ikonUiModules";
1005
- function G(n) {
1097
+ const ge = "ikonUiModules";
1098
+ function X(n) {
1006
1099
  return typeof n == "object" && n !== null && !Array.isArray(n);
1007
1100
  }
1008
- function yt(n) {
1101
+ function Rt(n) {
1009
1102
  if (!Array.isArray(n))
1010
1103
  return;
1011
1104
  const e = /* @__PURE__ */ new Set();
1012
1105
  for (const t of n) {
1013
- if (!mt(t)) continue;
1106
+ if (!Et(t)) continue;
1014
1107
  const r = t.trim();
1015
1108
  r && (e.has(r) || e.add(r));
1016
1109
  }
1017
1110
  return Array.from(e);
1018
1111
  }
1019
- function Nt(n, e) {
1112
+ function jt(n, e) {
1020
1113
  if (n === e)
1021
1114
  return !0;
1022
1115
  if (!n || !e)
@@ -1028,21 +1121,21 @@ function Nt(n, e) {
1028
1121
  return !1;
1029
1122
  return !0;
1030
1123
  }
1031
- function St(n) {
1032
- if (!(!G(n) || !Object.prototype.hasOwnProperty.call(n, pe)))
1033
- return yt(n[pe]);
1124
+ function Tt(n) {
1125
+ if (!(!X(n) || !Object.prototype.hasOwnProperty.call(n, ge)))
1126
+ return Rt(n[ge]);
1034
1127
  }
1035
- function Ot(...n) {
1128
+ function It(...n) {
1036
1129
  for (const e of n) {
1037
- const t = St(e);
1130
+ const t = Tt(e);
1038
1131
  if (t !== void 0)
1039
1132
  return t;
1040
1133
  }
1041
1134
  }
1042
- function kt(n) {
1043
- if (!G(n))
1135
+ function Pt(n) {
1136
+ if (!X(n))
1044
1137
  return;
1045
- const e = n, t = Object.keys(e).find((u) => u.toLowerCase() === "modules");
1138
+ const e = n, t = Object.keys(e).find((l) => l.toLowerCase() === "modules");
1046
1139
  if (!t)
1047
1140
  return;
1048
1141
  const r = e[t];
@@ -1051,56 +1144,56 @@ function kt(n) {
1051
1144
  if (!Array.isArray(r))
1052
1145
  return;
1053
1146
  const s = [], i = /* @__PURE__ */ new Map(), a = /* @__PURE__ */ new Set();
1054
- for (const u of r) {
1055
- if (typeof u == "string") {
1056
- const b = u.trim();
1147
+ for (const l of r) {
1148
+ if (typeof l == "string") {
1149
+ const b = l.trim();
1057
1150
  if (!b || a.has(b))
1058
1151
  continue;
1059
1152
  s.push(b), a.add(b);
1060
1153
  continue;
1061
1154
  }
1062
- if (!G(u))
1155
+ if (!X(l))
1063
1156
  continue;
1064
- const d = u, p = Object.keys(d).find((b) => b.toLowerCase() === "name");
1065
- if (!p)
1157
+ const d = l, m = Object.keys(d).find((b) => b.toLowerCase() === "name");
1158
+ if (!m)
1066
1159
  continue;
1067
- const E = d[p];
1160
+ const E = d[m];
1068
1161
  if (typeof E != "string")
1069
1162
  continue;
1070
- const T = E.trim();
1071
- if (!T)
1163
+ const R = E.trim();
1164
+ if (!R)
1072
1165
  continue;
1073
1166
  const O = Object.keys(d).find((b) => b.toLowerCase() === "javascript"), _ = O ? d[O] : void 0;
1074
- typeof _ == "string" && i.set(T, _), a.has(T) || (s.push(T), a.add(T));
1167
+ typeof _ == "string" && i.set(R, _), a.has(R) || (s.push(R), a.add(R));
1075
1168
  }
1076
1169
  if (!s.length && i.size === 0)
1077
1170
  return { modules: [] };
1078
- const l = Array.from(i.entries()).map(([u, d]) => ({
1079
- name: u,
1171
+ const c = Array.from(i.entries()).map(([l, d]) => ({
1172
+ name: l,
1080
1173
  javascript: d
1081
1174
  }));
1082
- return l.length > 0 ? { modules: s, inlineModules: l } : { modules: s };
1175
+ return c.length > 0 ? { modules: s, inlineModules: c } : { modules: s };
1083
1176
  }
1084
1177
  export {
1085
- De as IKON_UI_BASE_MODULE,
1086
- J as IKON_UI_STREAM_CATEGORY,
1087
- Rt as IkonUi,
1088
- Ve as IkonUiRegistry,
1089
- Tt as IkonUiSurface,
1090
- Be as UiComponentRegistry,
1091
- ze as UiRenderer,
1092
- Mt as UiStreamStore,
1093
- Nt as areIkonUiModuleListsEqual,
1094
- qe as createBaseResolvers,
1095
- Et as createComponentLibrary,
1096
- wt as createIkonUiRegistry,
1097
- Fe as isIkonUiCategoryMatch,
1098
- Ye as loadBaseModule,
1099
- yt as normalizeIkonUiModuleList,
1100
- kt as parseIkonUiInitPayload,
1101
- St as readIkonUiModules,
1102
- Ot as readIkonUiModulesFromSources,
1103
- We as registerBaseModule,
1104
- Ct as useIkonStyles,
1105
- je as useUiStore
1178
+ He as IKON_UI_BASE_MODULE,
1179
+ H as IKON_UI_STREAM_CATEGORY,
1180
+ At as IkonUi,
1181
+ Ze as IkonUiRegistry,
1182
+ Ot as IkonUiSurface,
1183
+ De as UiComponentRegistry,
1184
+ $e as UiRenderer,
1185
+ Lt as UiStreamStore,
1186
+ jt as areIkonUiModuleListsEqual,
1187
+ Ge as createBaseResolvers,
1188
+ wt as createComponentLibrary,
1189
+ _t as createIkonUiRegistry,
1190
+ qe as isIkonUiCategoryMatch,
1191
+ Xe as loadBaseModule,
1192
+ Rt as normalizeIkonUiModuleList,
1193
+ Pt as parseIkonUiInitPayload,
1194
+ Tt as readIkonUiModules,
1195
+ It as readIkonUiModulesFromSources,
1196
+ Ke as registerBaseModule,
1197
+ Mt as useIkonStyles,
1198
+ Ue as useUiStore
1106
1199
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ikonai/sdk-react-ui",
3
- "version": "0.0.9",
3
+ "version": "0.0.11",
4
4
  "type": "module",
5
5
  "main": "./index.js",
6
6
  "types": "./index.d.ts",