dynamic-mui 2.1.0 → 2.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (72) hide show
  1. package/README.md +218 -37
  2. package/dist/AxisSharedComponents-BbsKw1BT.js +3 -0
  3. package/dist/AxisSharedComponents-xLtpOLH_.mjs +605 -0
  4. package/dist/ChartsAxis-CANvBdY9.mjs +47 -0
  5. package/dist/ChartsAxis-EZ7m_KrU.js +1 -0
  6. package/dist/ChartsGrid-BCRTvNTr.js +3 -0
  7. package/dist/ChartsGrid-C_HT7qpL.mjs +381 -0
  8. package/dist/ChartsWrapper-CM7EDyAK.js +5 -0
  9. package/dist/ChartsWrapper-CO5_Z6BD.mjs +1878 -0
  10. package/dist/ChartsXAxis-CPmuCRhq.mjs +487 -0
  11. package/dist/ChartsXAxis-DFFY1sPg.js +3 -0
  12. package/dist/ChartsYAxis-DLUMr9vG.mjs +392 -0
  13. package/dist/ChartsYAxis-fpevi1sP.js +1 -0
  14. package/dist/clampAngle-BvZjnf53.mjs +11 -0
  15. package/dist/clampAngle-DpAsDoeT.js +1 -0
  16. package/dist/components/FormGenerator.d.ts +33 -1
  17. package/dist/components/controls/AsyncAutocomplete/asyncautocomplete.d.ts +9 -0
  18. package/dist/components/controls/CheckBox/checkbox.d.ts +1 -1
  19. package/dist/components/controls/ChipSelect/chipselect.d.ts +1 -1
  20. package/dist/components/controls/EditableTable/editabletable.d.ts +2 -0
  21. package/dist/components/controls/IntlPhone/intlphone.d.ts +2 -0
  22. package/dist/components/controls/LocationField/locationfield.d.ts +1 -1
  23. package/dist/components/controls/MultiTextbox/multitextbox.d.ts +1 -1
  24. package/dist/components/controls/NpsScale/npsscale.d.ts +3 -0
  25. package/dist/components/controls/NumberField/numberfield.d.ts +1 -1
  26. package/dist/components/controls/PasswordField/passwordfield.d.ts +1 -1
  27. package/dist/components/controls/Radio/radio.d.ts +1 -1
  28. package/dist/components/controls/RichTextEditor/richtexteditor.d.ts +3 -0
  29. package/dist/components/controls/Select/select.d.ts +1 -1
  30. package/dist/components/controls/Switch/switch.d.ts +1 -1
  31. package/dist/components/controls/TextField/textfield.d.ts +1 -1
  32. package/dist/components/controls/index.d.ts +10 -0
  33. package/dist/createSelector-B-9FwV16.mjs +430 -0
  34. package/dist/createSelector-f0oqn8Lr.js +7 -0
  35. package/dist/dynamic-mui.cjs.js +1 -469
  36. package/dist/dynamic-mui.es.js +20 -102548
  37. package/dist/index--8Zky9Oh.js +299 -0
  38. package/dist/index-6WTs1Xy_.js +1 -0
  39. package/dist/index-B1R1akM2.js +1 -0
  40. package/dist/index-B_KNUTjy.js +1 -0
  41. package/dist/index-BhaKvHkU.mjs +62051 -0
  42. package/dist/index-Bif92ima.js +1 -0
  43. package/dist/index-BnZOu8CL.js +1 -0
  44. package/dist/index-CDxpgRlR.mjs +7 -0
  45. package/dist/index-CThMfvtJ.mjs +2555 -0
  46. package/dist/index-CodJBIn6.mjs +1665 -0
  47. package/dist/index-CslPwsrf.mjs +4 -0
  48. package/dist/index-CuV0MQzZ.mjs +1173 -0
  49. package/dist/index-DSkYYZuW.mjs +4 -0
  50. package/dist/index-DU78_FiA.js +1 -0
  51. package/dist/index-D_mYhgJ0.js +10 -0
  52. package/dist/index-Dlimbnxj.mjs +2965 -0
  53. package/dist/index-in5z9hUb.js +133 -0
  54. package/dist/index-qUW7FnZ-.mjs +20540 -0
  55. package/dist/index.d.ts +3 -1
  56. package/dist/isDeepEqual-BHfPvf9U.mjs +393 -0
  57. package/dist/isDeepEqual-CqxZGVRk.js +1 -0
  58. package/dist/playground/DemoGallery.d.ts +6 -0
  59. package/dist/playground/Sidebar.d.ts +9 -1
  60. package/dist/playground/demoForms.d.ts +3 -0
  61. package/dist/playground/demoRecipes.d.ts +15 -0
  62. package/dist/playground/demoVariants.d.ts +11 -0
  63. package/dist/schema.d.ts +404 -0
  64. package/dist/theme/theme.d.ts +5 -0
  65. package/dist/types.d.ts +16 -0
  66. package/dist/useAxis-DSbfEtO7.js +3 -0
  67. package/dist/useAxis-SiNBMMWq.mjs +3010 -0
  68. package/dist/useChartContainerProps-Bl3hO-r1.mjs +5418 -0
  69. package/dist/useChartContainerProps-C_C_PZoi.js +12 -0
  70. package/dist/useItemHighlightedGetter-9CIwqsGj.js +1 -0
  71. package/dist/useItemHighlightedGetter-CTISrNdV.mjs +88 -0
  72. package/package.json +1 -1
package/dist/index.d.ts CHANGED
@@ -1,6 +1,8 @@
1
- export { FormGenerator, FormData, ClearFormData } from './components/FormGenerator';
1
+ export { FormGenerator, FormData, ClearFormData, useForm } from './components/FormGenerator';
2
+ export type { FormApi, FormMessages, FormGeneratorProps } from './components/FormGenerator';
2
3
  export { default as DynamicComponent } from './components/DynamicComponent';
3
4
  export { default as Controls } from './components/controls';
4
5
  export { default as MuiConfig } from './config/mui';
5
6
  export * from './types';
6
7
  export * from './ai';
8
+ export * from './schema';
@@ -0,0 +1,393 @@
1
+ import { k as U, l as N, _ as C } from "./index-BhaKvHkU.mjs";
2
+ import * as K from "react";
3
+ import V from "react";
4
+ const q = parseInt(K.version, 10), $ = Object.is;
5
+ function ce(t, e) {
6
+ if (t === e)
7
+ return !0;
8
+ if (!(t instanceof Object) || !(e instanceof Object))
9
+ return !1;
10
+ let u = 0, i = 0;
11
+ for (const r in t)
12
+ if (u += 1, !$(t[r], e[r]) || !(r in e))
13
+ return !1;
14
+ for (const r in e)
15
+ i += 1;
16
+ return u === i;
17
+ }
18
+ var A = { exports: {} }, j = {};
19
+ var I;
20
+ function P() {
21
+ if (I) return j;
22
+ I = 1;
23
+ var t = V;
24
+ function e(c, a) {
25
+ return c === a && (c !== 0 || 1 / c === 1 / a) || c !== c && a !== a;
26
+ }
27
+ var u = typeof Object.is == "function" ? Object.is : e, i = t.useState, r = t.useEffect, n = t.useLayoutEffect, O = t.useDebugValue;
28
+ function h(c, a) {
29
+ var o = a(), s = i({ inst: { value: o, getSnapshot: a } }), f = s[0].inst, _ = s[1];
30
+ return n(
31
+ function() {
32
+ f.value = o, f.getSnapshot = a, E(f) && _({ inst: f });
33
+ },
34
+ [c, o, a]
35
+ ), r(
36
+ function() {
37
+ return E(f) && _({ inst: f }), c(function() {
38
+ E(f) && _({ inst: f });
39
+ });
40
+ },
41
+ [c]
42
+ ), O(o), o;
43
+ }
44
+ function E(c) {
45
+ var a = c.getSnapshot;
46
+ c = c.value;
47
+ try {
48
+ var o = a();
49
+ return !u(c, o);
50
+ } catch {
51
+ return !0;
52
+ }
53
+ }
54
+ function d(c, a) {
55
+ return a();
56
+ }
57
+ var l = typeof window > "u" || typeof window.document > "u" || typeof window.document.createElement > "u" ? d : h;
58
+ return j.useSyncExternalStore = t.useSyncExternalStore !== void 0 ? t.useSyncExternalStore : l, j;
59
+ }
60
+ var w = {};
61
+ var k;
62
+ function Y() {
63
+ return k || (k = 1, process.env.NODE_ENV !== "production" && (function() {
64
+ function t(o, s) {
65
+ return o === s && (o !== 0 || 1 / o === 1 / s) || o !== o && s !== s;
66
+ }
67
+ function e(o, s) {
68
+ l || r.startTransition === void 0 || (l = !0, console.error(
69
+ "You are using an outdated, pre-release alpha of React 18 that does not support useSyncExternalStore. The use-sync-external-store shim will not work correctly. Upgrade to a newer pre-release."
70
+ ));
71
+ var f = s();
72
+ if (!c) {
73
+ var _ = s();
74
+ n(f, _) || (console.error(
75
+ "The result of getSnapshot should be cached to avoid an infinite loop"
76
+ ), c = !0);
77
+ }
78
+ _ = O({
79
+ inst: { value: f, getSnapshot: s }
80
+ });
81
+ var p = _[0].inst, y = _[1];
82
+ return E(
83
+ function() {
84
+ p.value = f, p.getSnapshot = s, u(p) && y({ inst: p });
85
+ },
86
+ [o, f, s]
87
+ ), h(
88
+ function() {
89
+ return u(p) && y({ inst: p }), o(function() {
90
+ u(p) && y({ inst: p });
91
+ });
92
+ },
93
+ [o]
94
+ ), d(f), f;
95
+ }
96
+ function u(o) {
97
+ var s = o.getSnapshot;
98
+ o = o.value;
99
+ try {
100
+ var f = s();
101
+ return !n(o, f);
102
+ } catch {
103
+ return !0;
104
+ }
105
+ }
106
+ function i(o, s) {
107
+ return s();
108
+ }
109
+ typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ < "u" && typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart == "function" && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());
110
+ var r = V, n = typeof Object.is == "function" ? Object.is : t, O = r.useState, h = r.useEffect, E = r.useLayoutEffect, d = r.useDebugValue, l = !1, c = !1, a = typeof window > "u" || typeof window.document > "u" || typeof window.document.createElement > "u" ? i : e;
111
+ w.useSyncExternalStore = r.useSyncExternalStore !== void 0 ? r.useSyncExternalStore : a, typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ < "u" && typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop == "function" && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error());
112
+ })()), w;
113
+ }
114
+ var x;
115
+ function G() {
116
+ return x || (x = 1, process.env.NODE_ENV === "production" ? A.exports = P() : A.exports = Y()), A.exports;
117
+ }
118
+ var F = G(), T = { exports: {} }, D = {};
119
+ var B;
120
+ function J() {
121
+ if (B) return D;
122
+ B = 1;
123
+ var t = V, e = G();
124
+ function u(d, l) {
125
+ return d === l && (d !== 0 || 1 / d === 1 / l) || d !== d && l !== l;
126
+ }
127
+ var i = typeof Object.is == "function" ? Object.is : u, r = e.useSyncExternalStore, n = t.useRef, O = t.useEffect, h = t.useMemo, E = t.useDebugValue;
128
+ return D.useSyncExternalStoreWithSelector = function(d, l, c, a, o) {
129
+ var s = n(null);
130
+ if (s.current === null) {
131
+ var f = { hasValue: !1, value: null };
132
+ s.current = f;
133
+ } else f = s.current;
134
+ s = h(
135
+ function() {
136
+ function p(S) {
137
+ if (!y) {
138
+ if (y = !0, m = S, S = a(S), o !== void 0 && f.hasValue) {
139
+ var v = f.value;
140
+ if (o(v, S))
141
+ return L = v;
142
+ }
143
+ return L = S;
144
+ }
145
+ if (v = L, i(m, S)) return v;
146
+ var R = a(S);
147
+ return o !== void 0 && o(v, R) ? (m = S, v) : (m = S, L = R);
148
+ }
149
+ var y = !1, m, L, g = c === void 0 ? null : c;
150
+ return [
151
+ function() {
152
+ return p(l());
153
+ },
154
+ g === null ? void 0 : function() {
155
+ return p(g());
156
+ }
157
+ ];
158
+ },
159
+ [l, c, a, o]
160
+ );
161
+ var _ = r(d, s[0], s[1]);
162
+ return O(
163
+ function() {
164
+ f.hasValue = !0, f.value = _;
165
+ },
166
+ [_]
167
+ ), E(_), _;
168
+ }, D;
169
+ }
170
+ var b = {};
171
+ var z;
172
+ function Q() {
173
+ return z || (z = 1, process.env.NODE_ENV !== "production" && (function() {
174
+ function t(d, l) {
175
+ return d === l && (d !== 0 || 1 / d === 1 / l) || d !== d && l !== l;
176
+ }
177
+ typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ < "u" && typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart == "function" && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());
178
+ var e = V, u = G(), i = typeof Object.is == "function" ? Object.is : t, r = u.useSyncExternalStore, n = e.useRef, O = e.useEffect, h = e.useMemo, E = e.useDebugValue;
179
+ b.useSyncExternalStoreWithSelector = function(d, l, c, a, o) {
180
+ var s = n(null);
181
+ if (s.current === null) {
182
+ var f = { hasValue: !1, value: null };
183
+ s.current = f;
184
+ } else f = s.current;
185
+ s = h(
186
+ function() {
187
+ function p(S) {
188
+ if (!y) {
189
+ if (y = !0, m = S, S = a(S), o !== void 0 && f.hasValue) {
190
+ var v = f.value;
191
+ if (o(v, S))
192
+ return L = v;
193
+ }
194
+ return L = S;
195
+ }
196
+ if (v = L, i(m, S))
197
+ return v;
198
+ var R = a(S);
199
+ return o !== void 0 && o(v, R) ? (m = S, v) : (m = S, L = R);
200
+ }
201
+ var y = !1, m, L, g = c === void 0 ? null : c;
202
+ return [
203
+ function() {
204
+ return p(l());
205
+ },
206
+ g === null ? void 0 : function() {
207
+ return p(g());
208
+ }
209
+ ];
210
+ },
211
+ [l, c, a, o]
212
+ );
213
+ var _ = r(d, s[0], s[1]);
214
+ return O(
215
+ function() {
216
+ f.hasValue = !0, f.value = _;
217
+ },
218
+ [_]
219
+ ), E(_), _;
220
+ }, typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ < "u" && typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop == "function" && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error());
221
+ })()), b;
222
+ }
223
+ var H;
224
+ function X() {
225
+ return H || (H = 1, process.env.NODE_ENV === "production" ? T.exports = J() : T.exports = Q()), T.exports;
226
+ }
227
+ var Z = X();
228
+ const ee = q >= 19, te = ee ? ne : ue;
229
+ function re(t, e, u, i, r) {
230
+ return te(t, e, u, i, r);
231
+ }
232
+ function ne(t, e, u, i, r) {
233
+ const n = K.useCallback(() => e(t.getSnapshot(), u, i, r), [t, e, u, i, r]);
234
+ return F.useSyncExternalStore(t.subscribe, n, n);
235
+ }
236
+ function ue(t, e, u, i, r) {
237
+ return Z.useSyncExternalStoreWithSelector(t.subscribe, t.getSnapshot, t.getSnapshot, (n) => e(n, u, i, r));
238
+ }
239
+ const oe = () => {
240
+ };
241
+ function ae(t, e, u) {
242
+ const i = U(ie, {
243
+ store: t,
244
+ selector: e
245
+ }).current;
246
+ i.effect = u, N(i.onMount);
247
+ }
248
+ function ie(t) {
249
+ const {
250
+ store: e,
251
+ selector: u
252
+ } = t;
253
+ let i = u(e.state);
254
+ const r = {
255
+ effect: oe,
256
+ dispose: null,
257
+ // We want a single subscription done right away and cleared on unmount only,
258
+ // but React triggers `useOnMount` multiple times in dev, so we need to manage
259
+ // the subscription anyway.
260
+ subscribe: () => {
261
+ r.dispose ??= e.subscribe((n) => {
262
+ const O = u(n);
263
+ if (!Object.is(i, O)) {
264
+ const h = i;
265
+ i = O, r.effect(h, O);
266
+ }
267
+ });
268
+ },
269
+ onMount: () => (r.subscribe(), () => {
270
+ r.dispose?.(), r.dispose = null;
271
+ })
272
+ };
273
+ return r.subscribe(), r;
274
+ }
275
+ class W {
276
+ // HACK: `any` fixes adding listeners that accept partial state.
277
+ // Internal state to handle recursive `setState()` calls
278
+ static create(e) {
279
+ return new W(e);
280
+ }
281
+ constructor(e) {
282
+ this.state = e, this.listeners = /* @__PURE__ */ new Set(), this.updateTick = 0;
283
+ }
284
+ subscribe = (e) => (this.listeners.add(e), () => {
285
+ this.listeners.delete(e);
286
+ });
287
+ /**
288
+ * Returns the current state snapshot. Meant for usage with `useSyncExternalStore`.
289
+ * If you want to access the state, use the `state` property instead.
290
+ */
291
+ getSnapshot = () => this.state;
292
+ setState(e) {
293
+ this.state = e, this.updateTick += 1;
294
+ const u = this.updateTick, i = this.listeners.values();
295
+ let r;
296
+ for (; r = i.next(), !r.done; ) {
297
+ if (u !== this.updateTick)
298
+ return;
299
+ const n = r.value;
300
+ n(e);
301
+ }
302
+ }
303
+ update(e) {
304
+ for (const u in e)
305
+ if (!Object.is(this.state[u], e[u])) {
306
+ this.setState(C({}, this.state, e));
307
+ return;
308
+ }
309
+ }
310
+ set(e, u) {
311
+ Object.is(this.state[e], u) || this.setState(C({}, this.state, {
312
+ [e]: u
313
+ }));
314
+ }
315
+ use = (e, u, i, r) => re(this, e, u, i, r);
316
+ }
317
+ function M(t, e) {
318
+ if (t === e)
319
+ return !0;
320
+ if (t && e && typeof t == "object" && typeof e == "object") {
321
+ if (t.constructor !== e.constructor)
322
+ return !1;
323
+ if (Array.isArray(t)) {
324
+ const r = t.length;
325
+ if (r !== e.length)
326
+ return !1;
327
+ for (let n = 0; n < r; n += 1)
328
+ if (!M(t[n], e[n]))
329
+ return !1;
330
+ return !0;
331
+ }
332
+ if (t instanceof Map && e instanceof Map) {
333
+ if (t.size !== e.size)
334
+ return !1;
335
+ const r = Array.from(t.entries());
336
+ for (let n = 0; n < r.length; n += 1)
337
+ if (!e.has(r[n][0]))
338
+ return !1;
339
+ for (let n = 0; n < r.length; n += 1) {
340
+ const O = r[n];
341
+ if (!M(O[1], e.get(O[0])))
342
+ return !1;
343
+ }
344
+ return !0;
345
+ }
346
+ if (t instanceof Set && e instanceof Set) {
347
+ if (t.size !== e.size)
348
+ return !1;
349
+ const r = Array.from(t.entries());
350
+ for (let n = 0; n < r.length; n += 1)
351
+ if (!e.has(r[n][0]))
352
+ return !1;
353
+ return !0;
354
+ }
355
+ if (ArrayBuffer.isView(t) && ArrayBuffer.isView(e)) {
356
+ const r = t.length;
357
+ if (r !== e.length)
358
+ return !1;
359
+ for (let n = 0; n < r; n += 1)
360
+ if (t[n] !== e[n])
361
+ return !1;
362
+ return !0;
363
+ }
364
+ if (t.constructor === RegExp)
365
+ return t.source === e.source && t.flags === e.flags;
366
+ if (t.valueOf !== Object.prototype.valueOf)
367
+ return t.valueOf() === e.valueOf();
368
+ if (t.toString !== Object.prototype.toString)
369
+ return t.toString() === e.toString();
370
+ const u = Object.keys(t), i = u.length;
371
+ if (i !== Object.keys(e).length)
372
+ return !1;
373
+ for (let r = 0; r < i; r += 1)
374
+ if (!Object.prototype.hasOwnProperty.call(e, u[r]))
375
+ return !1;
376
+ for (let r = 0; r < i; r += 1) {
377
+ const n = u[r];
378
+ if (!M(t[n], e[n]))
379
+ return !1;
380
+ }
381
+ return !0;
382
+ }
383
+ return t !== t && e !== e;
384
+ }
385
+ export {
386
+ W as S,
387
+ re as a,
388
+ ce as f,
389
+ M as i,
390
+ q as r,
391
+ F as s,
392
+ ae as u
393
+ };
@@ -0,0 +1 @@
1
+ "use strict";const b=require("./index--8Zky9Oh.js"),j=require("react");function $(t){const e=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const n in t)if(n!=="default"){const o=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(e,n,o.get?o:{enumerable:!0,get:()=>t[n]})}}return e.default=t,Object.freeze(e)}const W=$(j),U=parseInt(W.version,10),P=Object.is;function Y(t,e){if(t===e)return!0;if(!(t instanceof Object)||!(e instanceof Object))return!1;let n=0,o=0;for(const r in t)if(n+=1,!P(t[r],e[r])||!(r in e))return!1;for(const r in e)o+=1;return n===o}var A={exports:{}},w={};var I;function F(){if(I)return w;I=1;var t=j;function e(f,a){return f===a&&(f!==0||1/f===1/a)||f!==f&&a!==a}var n=typeof Object.is=="function"?Object.is:e,o=t.useState,r=t.useEffect,u=t.useLayoutEffect,O=t.useDebugValue;function h(f,a){var i=a(),s=o({inst:{value:i,getSnapshot:a}}),c=s[0].inst,S=s[1];return u(function(){c.value=i,c.getSnapshot=a,E(c)&&S({inst:c})},[f,i,a]),r(function(){return E(c)&&S({inst:c}),f(function(){E(c)&&S({inst:c})})},[f]),O(i),i}function E(f){var a=f.getSnapshot;f=f.value;try{var i=a();return!n(f,i)}catch{return!0}}function d(f,a){return a()}var l=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?d:h;return w.useSyncExternalStore=t.useSyncExternalStore!==void 0?t.useSyncExternalStore:l,w}var D={};var k;function J(){return k||(k=1,process.env.NODE_ENV!=="production"&&(function(){function t(i,s){return i===s&&(i!==0||1/i===1/s)||i!==i&&s!==s}function e(i,s){l||r.startTransition===void 0||(l=!0,console.error("You are using an outdated, pre-release alpha of React 18 that does not support useSyncExternalStore. The use-sync-external-store shim will not work correctly. Upgrade to a newer pre-release."));var c=s();if(!f){var S=s();u(c,S)||(console.error("The result of getSnapshot should be cached to avoid an infinite loop"),f=!0)}S=O({inst:{value:c,getSnapshot:s}});var p=S[0].inst,y=S[1];return E(function(){p.value=c,p.getSnapshot=s,n(p)&&y({inst:p})},[i,c,s]),h(function(){return n(p)&&y({inst:p}),i(function(){n(p)&&y({inst:p})})},[i]),d(c),c}function n(i){var s=i.getSnapshot;i=i.value;try{var c=s();return!u(i,c)}catch{return!0}}function o(i,s){return s()}typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());var r=j,u=typeof Object.is=="function"?Object.is:t,O=r.useState,h=r.useEffect,E=r.useLayoutEffect,d=r.useDebugValue,l=!1,f=!1,a=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?o:e;D.useSyncExternalStore=r.useSyncExternalStore!==void 0?r.useSyncExternalStore:a,typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error())})()),D}var B;function G(){return B||(B=1,process.env.NODE_ENV==="production"?A.exports=F():A.exports=J()),A.exports}var N=G(),T={exports:{}},M={};var z;function Q(){if(z)return M;z=1;var t=j,e=G();function n(d,l){return d===l&&(d!==0||1/d===1/l)||d!==d&&l!==l}var o=typeof Object.is=="function"?Object.is:n,r=e.useSyncExternalStore,u=t.useRef,O=t.useEffect,h=t.useMemo,E=t.useDebugValue;return M.useSyncExternalStoreWithSelector=function(d,l,f,a,i){var s=u(null);if(s.current===null){var c={hasValue:!1,value:null};s.current=c}else c=s.current;s=h(function(){function p(_){if(!y){if(y=!0,m=_,_=a(_),i!==void 0&&c.hasValue){var v=c.value;if(i(v,_))return g=v}return g=_}if(v=g,o(m,_))return v;var R=a(_);return i!==void 0&&i(v,R)?(m=_,v):(m=_,g=R)}var y=!1,m,g,L=f===void 0?null:f;return[function(){return p(l())},L===null?void 0:function(){return p(L())}]},[l,f,a,i]);var S=r(d,s[0],s[1]);return O(function(){c.hasValue=!0,c.value=S},[S]),E(S),S},M}var C={};var H;function X(){return H||(H=1,process.env.NODE_ENV!=="production"&&(function(){function t(d,l){return d===l&&(d!==0||1/d===1/l)||d!==d&&l!==l}typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());var e=j,n=G(),o=typeof Object.is=="function"?Object.is:t,r=n.useSyncExternalStore,u=e.useRef,O=e.useEffect,h=e.useMemo,E=e.useDebugValue;C.useSyncExternalStoreWithSelector=function(d,l,f,a,i){var s=u(null);if(s.current===null){var c={hasValue:!1,value:null};s.current=c}else c=s.current;s=h(function(){function p(_){if(!y){if(y=!0,m=_,_=a(_),i!==void 0&&c.hasValue){var v=c.value;if(i(v,_))return g=v}return g=_}if(v=g,o(m,_))return v;var R=a(_);return i!==void 0&&i(v,R)?(m=_,v):(m=_,g=R)}var y=!1,m,g,L=f===void 0?null:f;return[function(){return p(l())},L===null?void 0:function(){return p(L())}]},[l,f,a,i]);var S=r(d,s[0],s[1]);return O(function(){c.hasValue=!0,c.value=S},[S]),E(S),S},typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error())})()),C}var K;function Z(){return K||(K=1,process.env.NODE_ENV==="production"?T.exports=Q():T.exports=X()),T.exports}var ee=Z();const te=U>=19,re=te?ne:ue;function q(t,e,n,o,r){return re(t,e,n,o,r)}function ne(t,e,n,o,r){const u=W.useCallback(()=>e(t.getSnapshot(),n,o,r),[t,e,n,o,r]);return N.useSyncExternalStore(t.subscribe,u,u)}function ue(t,e,n,o,r){return ee.useSyncExternalStoreWithSelector(t.subscribe,t.getSnapshot,t.getSnapshot,u=>e(u,n,o,r))}const oe=()=>{};function ie(t,e,n){const o=b.useLazyRef(se,{store:t,selector:e}).current;o.effect=n,b.useOnMount(o.onMount)}function se(t){const{store:e,selector:n}=t;let o=n(e.state);const r={effect:oe,dispose:null,subscribe:()=>{r.dispose??=e.subscribe(u=>{const O=n(u);if(!Object.is(o,O)){const h=o;o=O,r.effect(h,O)}})},onMount:()=>(r.subscribe(),()=>{r.dispose?.(),r.dispose=null})};return r.subscribe(),r}class x{static create(e){return new x(e)}constructor(e){this.state=e,this.listeners=new Set,this.updateTick=0}subscribe=e=>(this.listeners.add(e),()=>{this.listeners.delete(e)});getSnapshot=()=>this.state;setState(e){this.state=e,this.updateTick+=1;const n=this.updateTick,o=this.listeners.values();let r;for(;r=o.next(),!r.done;){if(n!==this.updateTick)return;const u=r.value;u(e)}}update(e){for(const n in e)if(!Object.is(this.state[n],e[n])){this.setState(b._extends({},this.state,e));return}}set(e,n){Object.is(this.state[e],n)||this.setState(b._extends({},this.state,{[e]:n}))}use=(e,n,o,r)=>q(this,e,n,o,r)}function V(t,e){if(t===e)return!0;if(t&&e&&typeof t=="object"&&typeof e=="object"){if(t.constructor!==e.constructor)return!1;if(Array.isArray(t)){const r=t.length;if(r!==e.length)return!1;for(let u=0;u<r;u+=1)if(!V(t[u],e[u]))return!1;return!0}if(t instanceof Map&&e instanceof Map){if(t.size!==e.size)return!1;const r=Array.from(t.entries());for(let u=0;u<r.length;u+=1)if(!e.has(r[u][0]))return!1;for(let u=0;u<r.length;u+=1){const O=r[u];if(!V(O[1],e.get(O[0])))return!1}return!0}if(t instanceof Set&&e instanceof Set){if(t.size!==e.size)return!1;const r=Array.from(t.entries());for(let u=0;u<r.length;u+=1)if(!e.has(r[u][0]))return!1;return!0}if(ArrayBuffer.isView(t)&&ArrayBuffer.isView(e)){const r=t.length;if(r!==e.length)return!1;for(let u=0;u<r;u+=1)if(t[u]!==e[u])return!1;return!0}if(t.constructor===RegExp)return t.source===e.source&&t.flags===e.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===e.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===e.toString();const n=Object.keys(t),o=n.length;if(o!==Object.keys(e).length)return!1;for(let r=0;r<o;r+=1)if(!Object.prototype.hasOwnProperty.call(e,n[r]))return!1;for(let r=0;r<o;r+=1){const u=n[r];if(!V(t[u],e[u]))return!1}return!0}return t!==t&&e!==e}exports.Store=x;exports.fastObjectShallowCompare=Y;exports.isDeepEqual=V;exports.reactMajor=U;exports.shimExports=N;exports.useStore=q;exports.useStoreEffect=ie;
@@ -0,0 +1,6 @@
1
+ import { FormField } from '../util/helper';
2
+ /** Full-width live gallery: patterns + every component in multiple config variants, with props, code, and add-to-builder. */
3
+ export declare const DemoGallery: ({ onAddField, onAddFields }: {
4
+ onAddField: (field: FormField) => void;
5
+ onAddFields: (fields: FormField[]) => void;
6
+ }) => import("react/jsx-runtime").JSX.Element;
@@ -1 +1,9 @@
1
- export declare const Sidebar: () => import("react/jsx-runtime").JSX.Element;
1
+ export declare const CATEGORIES: Record<string, string[]>;
2
+ export declare const CATEGORY_META: Record<string, {
3
+ color: string;
4
+ icon: string;
5
+ grad: [string, string];
6
+ }>;
7
+ export declare const Sidebar: ({ onAdd }: {
8
+ onAdd?: (type: string) => void;
9
+ }) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,3 @@
1
+ import { DemoRecipe } from './demoRecipes';
2
+ /** Forms with every input normalized to a consistent "label on top" style. */
3
+ export declare const DEMO_FORMS: DemoRecipe[];
@@ -0,0 +1,15 @@
1
+ import { FormField } from '../util/helper';
2
+ export interface DemoRecipe {
3
+ id: string;
4
+ title: string;
5
+ description: string;
6
+ icon: string;
7
+ data: FormField[];
8
+ }
9
+ /**
10
+ * Practical, multi-field examples that show the DYNAMIC engine at work —
11
+ * live formulas, conditional visibility, dependent selects (subforms),
12
+ * required-when, disabled-when, and cross-field validation. These are the
13
+ * real-world patterns single-component demos can't show.
14
+ */
15
+ export declare const DEMO_RECIPES: DemoRecipe[];
@@ -0,0 +1,11 @@
1
+ import { FormField } from '../util/helper';
2
+ export type DemoVariant = {
3
+ label: string;
4
+ field: FormField;
5
+ };
6
+ /**
7
+ * Curated config variants per component so the Demo gallery shows "what this
8
+ * component can do". Any component NOT listed here falls back to its single
9
+ * playground template (see DemoCard).
10
+ */
11
+ export declare const DEMO_VARIANTS: Record<string, DemoVariant[]>;