@harnessio/forms 0.1.6-beta.2 → 0.3.0-beta.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.
package/dist/index.js CHANGED
@@ -1,21 +1,21 @@
1
- var se = Object.defineProperty;
2
- var ae = (r, e, n) => e in r ? se(r, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : r[e] = n;
3
- var P = (r, e, n) => ae(r, typeof e != "symbol" ? e + "" : e, n);
4
- import { isEmpty as j, cloneDeep as x, set as g, get as b, forOwn as G, isArray as E, isObject as H, merge as C, isUndefined as q, pick as oe, unset as ue, isNull as Q, omitBy as X, isNil as ie, isString as ce, capitalize as fe } from "lodash-es";
5
- import le, { createContext as de, useContext as me, useMemo as Z, useRef as F, useEffect as O, useCallback as he, forwardRef as pe, Fragment as ye } from "react";
6
- import { useFormContext as ge, useForm as be, FormProvider as ve, appendErrors as _e, useController as Ee } from "react-hook-form";
1
+ var he = Object.defineProperty;
2
+ var pe = (r, e, n) => e in r ? he(r, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : r[e] = n;
3
+ var N = (r, e, n) => pe(r, typeof e != "symbol" ? e + "" : e, n);
4
+ import { isEmpty as C, cloneDeep as q, set as g, get as b, forOwn as te, isArray as S, isObject as ne, merge as V, isUndefined as F, pick as ye, unset as ge, isNull as se, omitBy as ae, isNil as be, isString as ve, capitalize as _e } from "lodash-es";
5
+ import Re, { createContext as Ee, useContext as Te, useMemo as D, useRef as M, useEffect as j, useCallback as Oe, forwardRef as Se, Fragment as je } from "react";
6
+ import { useFormContext as Ie, get as Ce, useForm as we, FormProvider as Ve, appendErrors as xe, useController as Pe } from "react-hook-form";
7
7
  export * from "react-hook-form";
8
- import * as m from "zod";
9
- import { toNestErrors as Re } from "@hookform/resolvers";
10
- class Te extends Error {
8
+ import * as d from "zod";
9
+ import { toNestErrors as qe } from "@hookform/resolvers";
10
+ class Fe extends Error {
11
11
  constructor(e) {
12
12
  super(`Input component '${e}' is already registered.`);
13
13
  }
14
14
  }
15
- class Y {
15
+ class oe {
16
16
  constructor(e) {
17
- P(this, "componentBank");
18
- P(this, "allowOverride");
17
+ N(this, "componentBank");
18
+ N(this, "allowOverride");
19
19
  this.allowOverride = (e == null ? void 0 : e.allowOverride) ?? !1, this.componentBank = /* @__PURE__ */ new Map();
20
20
  }
21
21
  /**
@@ -26,11 +26,11 @@ class Y {
26
26
  */
27
27
  registerComponent(e) {
28
28
  if (!this.allowOverride && this.getComponent(e.internalType))
29
- throw new Te(e.internalType);
29
+ throw new Fe(e.internalType);
30
30
  this.componentBank.set(e.internalType, e);
31
31
  }
32
32
  getComponent(e) {
33
- if (e && !j(e))
33
+ if (e && !C(e))
34
34
  return this.componentBank.get(e);
35
35
  }
36
36
  /**
@@ -47,7 +47,7 @@ class Y {
47
47
  * @returns new input factory
48
48
  */
49
49
  clone() {
50
- const e = new Y({
50
+ const e = new oe({
51
51
  allowOverride: this.allowOverride
52
52
  });
53
53
  return this.listRegisteredComponents().forEach((n) => {
@@ -55,16 +55,16 @@ class Y {
55
55
  }), e;
56
56
  }
57
57
  }
58
- var A = { exports: {} }, _ = {};
58
+ var Z = { exports: {} }, O = {};
59
59
  /*
60
60
  object-assign
61
61
  (c) Sindre Sorhus
62
62
  @license MIT
63
63
  */
64
- var k, B;
65
- function Oe() {
66
- if (B) return k;
67
- B = 1;
64
+ var B, X;
65
+ function Ae() {
66
+ if (X) return B;
67
+ X = 1;
68
68
  var r = Object.getOwnPropertySymbols, e = Object.prototype.hasOwnProperty, n = Object.prototype.propertyIsEnumerable;
69
69
  function t(s) {
70
70
  if (s == null)
@@ -78,34 +78,34 @@ function Oe() {
78
78
  var s = new String("abc");
79
79
  if (s[5] = "de", Object.getOwnPropertyNames(s)[0] === "5")
80
80
  return !1;
81
- for (var u = {}, o = 0; o < 10; o++)
82
- u["_" + String.fromCharCode(o)] = o;
83
- var i = Object.getOwnPropertyNames(u).map(function(f) {
84
- return u[f];
81
+ for (var i = {}, o = 0; o < 10; o++)
82
+ i["_" + String.fromCharCode(o)] = o;
83
+ var u = Object.getOwnPropertyNames(i).map(function(l) {
84
+ return i[l];
85
85
  });
86
- if (i.join("") !== "0123456789")
86
+ if (u.join("") !== "0123456789")
87
87
  return !1;
88
88
  var c = {};
89
- return "abcdefghijklmnopqrst".split("").forEach(function(f) {
90
- c[f] = f;
89
+ return "abcdefghijklmnopqrst".split("").forEach(function(l) {
90
+ c[l] = l;
91
91
  }), Object.keys(Object.assign({}, c)).join("") === "abcdefghijklmnopqrst";
92
92
  } catch {
93
93
  return !1;
94
94
  }
95
95
  }
96
- return k = a() ? Object.assign : function(s, u) {
97
- for (var o, i = t(s), c, f = 1; f < arguments.length; f++) {
98
- o = Object(arguments[f]);
99
- for (var l in o)
100
- e.call(o, l) && (i[l] = o[l]);
96
+ return B = a() ? Object.assign : function(s, i) {
97
+ for (var o, u = t(s), c, l = 1; l < arguments.length; l++) {
98
+ o = Object(arguments[l]);
99
+ for (var m in o)
100
+ e.call(o, m) && (u[m] = o[m]);
101
101
  if (r) {
102
102
  c = r(o);
103
- for (var d = 0; d < c.length; d++)
104
- n.call(o, c[d]) && (i[c[d]] = o[c[d]]);
103
+ for (var f = 0; f < c.length; f++)
104
+ n.call(o, c[f]) && (u[c[f]] = o[c[f]]);
105
105
  }
106
106
  }
107
- return i;
108
- }, k;
107
+ return u;
108
+ }, B;
109
109
  }
110
110
  /** @license React v17.0.2
111
111
  * react-jsx-runtime.production.min.js
@@ -115,97 +115,112 @@ function Oe() {
115
115
  * This source code is licensed under the MIT license found in the
116
116
  * LICENSE file in the root directory of this source tree.
117
117
  */
118
- var $;
119
- function Se() {
120
- if ($) return _;
121
- $ = 1, Oe();
122
- var r = le, e = 60103;
123
- if (_.Fragment = 60107, typeof Symbol == "function" && Symbol.for) {
118
+ var Y;
119
+ function ke() {
120
+ if (Y) return O;
121
+ Y = 1, Ae();
122
+ var r = Re, e = 60103;
123
+ if (O.Fragment = 60107, typeof Symbol == "function" && Symbol.for) {
124
124
  var n = Symbol.for;
125
- e = n("react.element"), _.Fragment = n("react.fragment");
125
+ e = n("react.element"), O.Fragment = n("react.fragment");
126
126
  }
127
127
  var t = r.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, a = Object.prototype.hasOwnProperty, s = { key: !0, ref: !0, __self: !0, __source: !0 };
128
- function u(o, i, c) {
129
- var f, l = {}, d = null, p = null;
130
- c !== void 0 && (d = "" + c), i.key !== void 0 && (d = "" + i.key), i.ref !== void 0 && (p = i.ref);
131
- for (f in i) a.call(i, f) && !s.hasOwnProperty(f) && (l[f] = i[f]);
132
- if (o && o.defaultProps) for (f in i = o.defaultProps, i) l[f] === void 0 && (l[f] = i[f]);
133
- return { $$typeof: e, type: o, key: d, ref: p, props: l, _owner: t.current };
128
+ function i(o, u, c) {
129
+ var l, m = {}, f = null, h = null;
130
+ c !== void 0 && (f = "" + c), u.key !== void 0 && (f = "" + u.key), u.ref !== void 0 && (h = u.ref);
131
+ for (l in u) a.call(u, l) && !s.hasOwnProperty(l) && (m[l] = u[l]);
132
+ if (o && o.defaultProps) for (l in u = o.defaultProps, u) m[l] === void 0 && (m[l] = u[l]);
133
+ return { $$typeof: e, type: o, key: f, ref: h, props: m, _owner: t.current };
134
134
  }
135
- return _.jsx = u, _.jsxs = u, _;
135
+ return O.jsx = i, O.jsxs = i, O;
136
136
  }
137
- var J;
138
- function je() {
139
- return J || (J = 1, A.exports = Se()), A.exports;
137
+ var K;
138
+ function Ne() {
139
+ return K || (K = 1, Z.exports = ke()), Z.exports;
140
140
  }
141
- var h = je();
142
- const K = de({});
143
- function Ie({ children: r, metadata: e }) {
144
- return /* @__PURE__ */ h.jsx(
145
- K.Provider,
141
+ var p = Ne();
142
+ const ue = Ee({});
143
+ function De({
144
+ children: r,
145
+ metadata: e,
146
+ readonly: n
147
+ }) {
148
+ return /* @__PURE__ */ p.jsx(
149
+ ue.Provider,
146
150
  {
147
151
  value: {
148
- metadata: e
152
+ metadata: e,
153
+ readonly: n
149
154
  },
150
155
  children: r
151
156
  }
152
157
  );
153
158
  }
154
- function Ce() {
155
- const r = me(K);
159
+ function Me() {
160
+ const r = Te(ue);
156
161
  return r || console.warn("useRootFormContext must be used within RootFormProvider"), r;
157
162
  }
158
- const L = ({
163
+ const z = ({
159
164
  children: r,
160
165
  withoutWrapper: e = !1
161
- }) => e || !r ? r : /* @__PURE__ */ h.jsx("div", { children: r });
162
- function Ve({
166
+ }) => e || !r ? r : /* @__PURE__ */ p.jsx("div", { children: r });
167
+ function Ze({
163
168
  path: r,
164
169
  factory: e,
165
170
  onUpdate: n,
166
171
  onChange: t,
167
- readonly: a,
168
- initialValues: s,
169
- input: u,
170
- withoutWrapper: o = !1
172
+ initialValues: a,
173
+ input: s,
174
+ withoutWrapper: i = !1
171
175
  }) {
172
- const { formState: i, watch: c } = ge(), {
173
- fixedValues: f = {}
176
+ var W;
177
+ const { formState: o, watch: u } = Ie(), {
178
+ fixedValues: c = {}
174
179
  /*getValuesWithDependencies*/
175
- } = {}, { metadata: l } = Ce(), d = e == null ? void 0 : e.getComponent(u.inputType), p = Z(
180
+ } = {}, { metadata: l, readonly: m } = Me(), f = e == null ? void 0 : e.getComponent(s.inputType), h = u(), _ = q(h);
181
+ c && Object.keys(c).forEach((w) => {
182
+ const A = c[w];
183
+ g(_, w, A);
184
+ });
185
+ const y = !s.isVisible || s.isVisible(_, l);
186
+ let E, T;
187
+ y && (E = m || s.readonly, T = typeof s.disabled == "function" ? s.disabled(_, l) : s.disabled);
188
+ const R = (W = s.warning) == null ? void 0 : W.schema, v = D(() => {
189
+ var H, Q;
190
+ if (!y || typeof R > "u") return;
191
+ const w = Ce(h, s.path), A = typeof R == "function" ? R(_) : R, { success: me, error: k } = A.safeParse(w), G = (Q = (H = k == null ? void 0 : k.errors) == null ? void 0 : H[0]) == null ? void 0 : Q.message;
192
+ return !me && G ? G : void 0;
193
+ }, [s.path, h, R, y]), U = D(
176
194
  () => ({
177
195
  path: r,
178
196
  key: r,
179
- initialValues: s,
197
+ initialValues: a,
180
198
  onUpdate: n,
181
199
  onChange: t,
182
200
  factory: e,
183
- readonly: a,
184
- input: u
201
+ readonly: E,
202
+ input: s,
203
+ disabled: T,
204
+ warning: v
185
205
  }),
186
- [e, s, u, t, n, r, a, i.errors]
187
- ), R = c(), v = x(R);
188
- f && Object.keys(f).forEach((y) => {
189
- const ne = f[y];
190
- g(v, y, ne);
191
- });
192
- const T = !u.isVisible || (u == null ? void 0 : u.isVisible(v, l)), I = Z(() => T ? /* @__PURE__ */ h.jsxs(h.Fragment, { children: [
193
- u.before ? u.before : null,
194
- d == null ? void 0 : d.renderComponent(p),
195
- u.after ? u.after : null
196
- ] }) : null, [p, u.after, u.before, d, T, i.errors]);
197
- return d ? /* @__PURE__ */ h.jsx(L, { withoutWrapper: o, children: I }) : /* @__PURE__ */ h.jsx(L, { withoutWrapper: o, children: /* @__PURE__ */ h.jsxs("p", { children: [
206
+ [e, a, s, t, n, r, E, o.errors, T]
207
+ ), de = D(() => y ? /* @__PURE__ */ p.jsxs(p.Fragment, { children: [
208
+ s.before ? s.before : null,
209
+ f == null ? void 0 : f.renderComponent(U),
210
+ s.after ? s.after : null
211
+ ] }) : null, [U, s.after, s.before, f, y, o.errors]);
212
+ return f ? /* @__PURE__ */ p.jsx(z, { withoutWrapper: i, children: de }) : /* @__PURE__ */ p.jsx(z, { withoutWrapper: i, children: /* @__PURE__ */ p.jsxs("p", { children: [
198
213
  "Input component not found (internal type: ",
199
- u.inputType,
214
+ s.inputType,
200
215
  ")"
201
216
  ] }) });
202
217
  }
203
- class He {
218
+ class ar {
204
219
  getType() {
205
220
  return this.internalType;
206
221
  }
207
222
  }
208
- function Qe(r) {
223
+ function or(r) {
209
224
  const {
210
225
  mode: e = "onSubmit",
211
226
  resolver: n,
@@ -213,27 +228,28 @@ function Qe(r) {
213
228
  shouldFocusError: a,
214
229
  // validateAfterFirstSubmit,
215
230
  onValuesChange: s,
216
- onValidationChange: u,
231
+ onValidationChange: i,
217
232
  onSubmit: o,
218
233
  // validate,
219
234
  // validateDebounceInterval,
220
235
  // validationConfig,
221
- metadata: i,
236
+ metadata: u,
222
237
  children: c,
223
238
  // fixedValues
224
- autoFocusPath: f
225
- } = r, l = be({
239
+ autoFocusPath: l,
240
+ readonly: m
241
+ } = r, f = we({
226
242
  mode: e ?? "onSubmit",
227
243
  reValidateMode: "onChange",
228
244
  defaultValues: t,
229
245
  shouldFocusError: a,
230
246
  resolver: n
231
- }), d = F(!1);
232
- O(() => {
233
- l.reset(t, {});
234
- }, [l.reset, t]), O(() => {
235
- const y = requestIdleCallback(() => {
236
- l.reset({}, {
247
+ }), h = M(!1);
248
+ j(() => {
249
+ f.reset(t, {});
250
+ }, [f.reset, t]), j(() => {
251
+ const v = requestIdleCallback(() => {
252
+ f.reset({}, {
237
253
  keepErrors: !0,
238
254
  keepDirty: !0,
239
255
  keepDirtyValues: !0,
@@ -246,220 +262,220 @@ function Qe(r) {
246
262
  keepSubmitCount: !0
247
263
  });
248
264
  });
249
- return () => cancelIdleCallback(y);
265
+ return () => cancelIdleCallback(v);
250
266
  }, []);
251
- const { getValues: p, handleSubmit: R } = l, v = p(), T = F(!0);
252
- O(() => {
267
+ const { getValues: _, handleSubmit: y } = f, E = _(), T = M(!0);
268
+ j(() => {
253
269
  if (T.current) {
254
270
  T.current = !1;
255
271
  return;
256
272
  }
257
- s == null || s({ ...v }), d.current === !0 && l.trigger();
258
- }, [JSON.stringify(v)]);
259
- const I = F(!0);
260
- return O(() => {
261
- if (I.current) {
262
- I.current = !1;
273
+ s == null || s({ ...E }), h.current === !0 && f.trigger();
274
+ }, [JSON.stringify(E)]);
275
+ const R = M(!0);
276
+ return j(() => {
277
+ if (R.current) {
278
+ R.current = !1;
263
279
  return;
264
280
  }
265
- u == null || u({ isValid: l.formState.isValid, isSubmitted: l.formState.isSubmitted });
266
- }, [l.formState.isValid, l.formState.isSubmitted]), O(() => {
267
- if (f)
281
+ i == null || i({ isValid: f.formState.isValid, isSubmitted: f.formState.isSubmitted });
282
+ }, [f.formState.isValid, f.formState.isSubmitted]), j(() => {
283
+ if (l)
268
284
  if ("requestIdleCallback" in window) {
269
- const y = requestIdleCallback(() => {
270
- l.setFocus(f);
285
+ const v = requestIdleCallback(() => {
286
+ f.setFocus(l);
271
287
  });
272
- return () => cancelIdleCallback(y);
288
+ return () => cancelIdleCallback(v);
273
289
  } else {
274
- const y = setTimeout(() => {
275
- l.setFocus(f);
290
+ const v = setTimeout(() => {
291
+ f.setFocus(l);
276
292
  }, 100);
277
- return () => clearTimeout(y);
293
+ return () => clearTimeout(v);
278
294
  }
279
- }, [l]), /* @__PURE__ */ h.jsx(Ie, { metadata: i, children: /* @__PURE__ */ h.jsx(ve, { ...l, children: typeof c == "function" ? c({
280
- ...l,
295
+ }, [f]), /* @__PURE__ */ p.jsx(De, { metadata: u, readonly: m, children: /* @__PURE__ */ p.jsx(Ve, { ...f, children: typeof c == "function" ? c({
296
+ ...f,
281
297
  submitForm: async () => {
282
- o && (d.current = !0, R((y) => {
283
- o(y);
298
+ o && (h.current = !0, y((v) => {
299
+ o(v);
284
300
  })());
285
301
  }
286
302
  }) : c }) });
287
303
  }
288
- const Xe = (r) => {
304
+ const ur = (r) => {
289
305
  const e = {}, n = (t) => {
290
306
  t.forEach((a) => {
291
- const { path: s, default: u, inputType: o, inputs: i } = a;
292
- (o === "group" || o === "accordion") && Array.isArray(i) ? n(i) : b(e, s) === void 0 && g(e, s, u);
307
+ const { path: s, default: i, inputType: o, inputs: u } = a;
308
+ (o === "group" || o === "accordion") && Array.isArray(u) ? n(u) : b(e, s) === void 0 && g(e, s, i);
293
309
  });
294
310
  };
295
311
  return Array.isArray(r.inputs) && n(r.inputs), e;
296
312
  };
297
- function Ye(r, e) {
313
+ function ir(r, e) {
298
314
  const n = r.inputs.map((t) => {
299
- const a = we(e, t.path);
315
+ const a = Be(e, t.path);
300
316
  return a || t;
301
317
  });
302
318
  return { ...r, inputs: n };
303
319
  }
304
- function we(r, e) {
320
+ function Be(r, e) {
305
321
  return r.inputs.find((n) => n.path === e);
306
322
  }
307
- const z = "__temp_", Ke = (r) => z + r.split(".").join("__");
308
- function xe(r) {
323
+ const ie = "__temp_", cr = (r) => ie + r.split(".").join("__");
324
+ function $e(r) {
309
325
  const e = { ...r };
310
- return G(e, (n, t) => {
311
- t.startsWith(z) && delete e[t];
326
+ return te(e, (n, t) => {
327
+ t.startsWith(ie) && delete e[t];
312
328
  }), e;
313
329
  }
314
- const qe = "Required field";
315
- function S(r) {
330
+ const Je = "Required field";
331
+ function I(r) {
316
332
  const e = typeof r == "string" ? JSON.parse(r) : r;
317
333
  if (typeof e == "string")
318
334
  return e;
319
- if (E(e))
320
- return S(e[0]);
335
+ if (S(e))
336
+ return I(e[0]);
321
337
  const n = e;
322
- return H(n) && (n != null && n.message) ? e == null ? void 0 : e.message : "Unknown error";
338
+ return ne(n) && (n != null && n.message) ? e == null ? void 0 : e.message : "Unknown error";
323
339
  }
324
- function Pe(r, e, n) {
340
+ function Le(r, e, n) {
325
341
  let t = {};
326
- if (w(t, r.inputs, e, n), n != null && n.prefix) {
342
+ if (P(t, r.inputs, e, n), n != null && n.prefix) {
327
343
  const s = n == null ? void 0 : n.prefix.replace(/.$/, "");
328
344
  t = g({}, s, t);
329
345
  }
330
- return m.object(V(t, e, n));
346
+ return d.object(x(t, e, n));
331
347
  }
332
- function V(r, e, n) {
348
+ function x(r, e, n) {
333
349
  const t = {};
334
350
  return Object.keys(r).forEach((a) => {
335
351
  const {
336
352
  _requiredOnly: s,
337
- _schemaObj: u,
353
+ _schemaObj: i,
338
354
  _input: o,
339
- _isList: i,
355
+ _isList: u,
340
356
  _isArrayItem: c,
341
- _schema: f
357
+ _schema: l
342
358
  /*...nestedSchemaObj*/
343
359
  } = r[a];
344
- if (i && u && o) {
345
- const l = m.array(m.object(V(u, e, n))).optional(), d = U(f, o, e, n, l);
346
- t[a] = d;
360
+ if (u && i && o) {
361
+ const m = d.array(d.object(x(i, e, n))).optional(), f = ee(l, o, e, n, m);
362
+ t[a] = f;
347
363
  } else if (c && o) {
348
- const l = u != null && u.___array ? V({ ___array: u.___array }, e, n) : { ___array: m.any() }, d = m.array(l.___array).optional(), p = U(f, o, e, n, d);
349
- t[a] = p;
350
- } else if (f && o) {
351
- const l = Fe(f, o, e, n);
352
- t[a] = l;
353
- } else s && o ? t[a] = D(o, n) : t[a] = m.object(V(r[a], e, n)).optional();
364
+ const m = i != null && i.___array ? x({ ___array: i.___array }, e, n) : { ___array: d.any() }, f = d.array(m.___array).optional(), h = ee(l, o, e, n, f);
365
+ t[a] = h;
366
+ } else if (l && o) {
367
+ const m = Ue(l, o, e, n);
368
+ t[a] = m;
369
+ } else s && o ? t[a] = J(o, n) : t[a] = d.object(x(r[a], e, n)).optional();
354
370
  }), t;
355
371
  }
356
- function Fe(r, e, n, t) {
357
- return m.any().optional().superRefine(async (a, s) => {
358
- var o, i;
359
- if (e.required && !(await D(e, t).safeParseAsync(a)).success)
372
+ function Ue(r, e, n, t) {
373
+ return d.any().optional().superRefine(async (a, s) => {
374
+ var o, u;
375
+ if (e.required && !(await J(e, t).safeParseAsync(a)).success)
360
376
  return s.addIssue({
361
- code: m.ZodIssueCode.custom,
362
- message: N(e, t)
363
- }), m.NEVER;
377
+ code: d.ZodIssueCode.custom,
378
+ message: $(e, t)
379
+ }), d.NEVER;
364
380
  if ((o = t == null ? void 0 : t.validationConfig) != null && o.globalValidation) {
365
- const c = (i = t == null ? void 0 : t.validationConfig) == null ? void 0 : i.globalValidation(a, e, t.metadata);
381
+ const c = (u = t == null ? void 0 : t.validationConfig) == null ? void 0 : u.globalValidation(a, e, t.metadata);
366
382
  if (c.error)
367
383
  return s.addIssue({
368
- code: m.ZodIssueCode.custom,
384
+ code: d.ZodIssueCode.custom,
369
385
  message: c.error
370
- }), m.NEVER;
386
+ }), d.NEVER;
371
387
  if (!c.continue)
372
388
  return !0;
373
389
  }
374
- const u = ee(r, n);
375
- if (u) {
376
- const c = await u.safeParseAsync(a);
390
+ const i = ce(r, n);
391
+ if (i) {
392
+ const c = await i.safeParseAsync(a);
377
393
  if (!c.success) {
378
- const f = S(c == null ? void 0 : c.error.message), l = f === "Required" ? N(e, t) : f;
394
+ const l = I(c == null ? void 0 : c.error.message), m = l === "Required" ? $(e, t) : l;
379
395
  s.addIssue({
380
- code: m.ZodIssueCode.custom,
381
- message: l
396
+ code: d.ZodIssueCode.custom,
397
+ message: m
382
398
  });
383
399
  }
384
400
  }
385
401
  });
386
402
  }
387
- function U(r, e, n, t, a) {
388
- return m.any().optional().superRefine(async (s, u) => {
389
- var f, l;
390
- const i = await D(e, t).safeParseAsync(s);
391
- if (e.required && !i.success) {
392
- const d = S(i.error.message);
393
- return u.addIssue({ code: m.ZodIssueCode.custom, message: d, fatal: !0 }), m.NEVER;
403
+ function ee(r, e, n, t, a) {
404
+ return d.any().optional().superRefine(async (s, i) => {
405
+ var l, m;
406
+ const u = await J(e, t).safeParseAsync(s);
407
+ if (e.required && !u.success) {
408
+ const f = I(u.error.message);
409
+ return i.addIssue({ code: d.ZodIssueCode.custom, message: f, fatal: !0 }), d.NEVER;
394
410
  }
395
- if (!e.required && !i.success)
396
- return m.NEVER;
397
- if ((f = t == null ? void 0 : t.validationConfig) != null && f.globalValidation) {
398
- const d = (l = t == null ? void 0 : t.validationConfig) == null ? void 0 : l.globalValidation(s, e, t.metadata);
399
- if (d.error)
400
- return u.addIssue({
401
- code: m.ZodIssueCode.custom,
402
- message: S(d.error)
403
- }), m.NEVER;
404
- if (!d.continue)
405
- return m.NEVER;
411
+ if (!e.required && !u.success)
412
+ return d.NEVER;
413
+ if ((l = t == null ? void 0 : t.validationConfig) != null && l.globalValidation) {
414
+ const f = (m = t == null ? void 0 : t.validationConfig) == null ? void 0 : m.globalValidation(s, e, t.metadata);
415
+ if (f.error)
416
+ return i.addIssue({
417
+ code: d.ZodIssueCode.custom,
418
+ message: I(f.error)
419
+ }), d.NEVER;
420
+ if (!f.continue)
421
+ return d.NEVER;
406
422
  }
407
- if (!E(s))
408
- return u.addIssue({
409
- code: m.ZodIssueCode.custom,
423
+ if (!S(s))
424
+ return i.addIssue({
425
+ code: d.ZodIssueCode.custom,
410
426
  message: "'Value is not array'"
411
- }), m.NEVER;
412
- const c = ee(r, n);
427
+ }), d.NEVER;
428
+ const c = ce(r, n);
413
429
  if (c) {
414
- const d = await c.safeParseAsync(s);
415
- if (!d.success)
416
- return u.addIssue({
417
- code: m.ZodIssueCode.custom,
418
- message: S(d.error.message)
419
- }), m.NEVER;
430
+ const f = await c.safeParseAsync(s);
431
+ if (!f.success)
432
+ return i.addIssue({
433
+ code: d.ZodIssueCode.custom,
434
+ message: I(f.error.message)
435
+ }), d.NEVER;
420
436
  }
421
- }).pipe(a ?? m.any());
437
+ }).pipe(a ?? d.any());
422
438
  }
423
- function w(r, e, n, t, a) {
439
+ function P(r, e, n, t, a) {
424
440
  e.forEach((s) => {
425
- var o, i, c, f, l;
426
- const u = n;
427
- if (!s.isVisible || (o = s.isVisible) != null && o.call(s, u, t == null ? void 0 : t.metadata)) {
428
- const d = b(r, s.path);
429
- if ((i = s.validation) != null && i.schema ? g(
441
+ var o, u, c, l, m;
442
+ const i = n;
443
+ if (!s.isVisible || (o = s.isVisible) != null && o.call(s, i, t == null ? void 0 : t.metadata)) {
444
+ const f = b(r, s.path);
445
+ if ((u = s.validation) != null && u.schema ? g(
430
446
  r,
431
447
  s.path,
432
- C(d, {
448
+ V(f, {
433
449
  _schema: (c = s.validation) == null ? void 0 : c.schema,
434
450
  _input: s
435
451
  })
436
- ) : s.required && g(r, s.path, C(d, { _requiredOnly: !0, _input: s })), s.inputs && w(r, s.inputs, n, t), s.inputType === "list") {
437
- const p = {};
438
- w(
439
- p,
440
- s.inputConfig.inputs.map((v) => ({
441
- ...v,
442
- path: v.relativePath
452
+ ) : s.required && g(r, s.path, V(f, { _requiredOnly: !0, _input: s })), s.inputs && P(r, s.inputs, n, t), s.inputType === "list") {
453
+ const h = {};
454
+ P(
455
+ h,
456
+ s.inputConfig.inputs.map((y) => ({
457
+ ...y,
458
+ path: y.relativePath
443
459
  })),
444
460
  n,
445
461
  t
446
462
  );
447
- const R = b(r, s.path);
448
- g(r, s.path, C(R, { _schemaObj: p, _isList: !0, _input: s }));
463
+ const _ = b(r, s.path);
464
+ g(r, s.path, V(_, { _schemaObj: h, _isList: !0, _input: s }));
449
465
  }
450
- if (!((f = s.validation) != null && f.schema) && s.inputType === "array") {
451
- const p = {};
452
- w(
453
- p,
466
+ if (!((l = s.validation) != null && l.schema) && s.inputType === "array") {
467
+ const h = {};
468
+ P(
469
+ h,
454
470
  [{ ...s.inputConfig.input, path: "___array" }],
455
471
  n,
456
472
  t
457
473
  ), g(
458
474
  r,
459
475
  s.path,
460
- C(d, {
461
- _schemaObj: p,
462
- _schema: (l = s.validation) == null ? void 0 : l.schema,
476
+ V(f, {
477
+ _schemaObj: h,
478
+ _schema: (m = s.validation) == null ? void 0 : m.schema,
463
479
  _isArrayItem: !0,
464
480
  _input: s
465
481
  })
@@ -468,50 +484,50 @@ function w(r, e, n, t, a) {
468
484
  }
469
485
  });
470
486
  }
471
- function N(r, e) {
487
+ function $(r, e) {
472
488
  var n, t, a;
473
- return ((t = (n = e == null ? void 0 : e.validationConfig) == null ? void 0 : n.requiredMessagePerInput) == null ? void 0 : t[r.inputType]) ?? ((a = e == null ? void 0 : e.validationConfig) == null ? void 0 : a.requiredMessage) ?? qe;
489
+ return ((t = (n = e == null ? void 0 : e.validationConfig) == null ? void 0 : n.requiredMessagePerInput) == null ? void 0 : t[r.inputType]) ?? ((a = e == null ? void 0 : e.validationConfig) == null ? void 0 : a.requiredMessage) ?? Je;
474
490
  }
475
- function D(r, e) {
476
- var t, a, s, u, o, i;
491
+ function J(r, e) {
492
+ var t, a, s, i, o, u;
477
493
  if ((a = (t = e == null ? void 0 : e.validationConfig) == null ? void 0 : t.requiredSchemaPerInput) != null && a[r.inputType])
478
- return (u = (s = e == null ? void 0 : e.validationConfig) == null ? void 0 : s.requiredSchemaPerInput) == null ? void 0 : u[r.inputType];
494
+ return (i = (s = e == null ? void 0 : e.validationConfig) == null ? void 0 : s.requiredSchemaPerInput) == null ? void 0 : i[r.inputType];
479
495
  if ((o = e == null ? void 0 : e.validationConfig) != null && o.requiredSchema)
480
- return (i = e == null ? void 0 : e.validationConfig) == null ? void 0 : i.requiredSchema;
481
- const n = N(r, e);
482
- return m.any().optional().superRefine((c, f) => {
483
- typeof c == "object" && j(c) && f.addIssue({
484
- code: m.ZodIssueCode.custom,
496
+ return (u = e == null ? void 0 : e.validationConfig) == null ? void 0 : u.requiredSchema;
497
+ const n = $(r, e);
498
+ return d.any().optional().superRefine((c, l) => {
499
+ typeof c == "object" && C(c) && l.addIssue({
500
+ code: d.ZodIssueCode.custom,
485
501
  message: n
486
- }), (q(c) || c === "") && f.addIssue({
487
- code: m.ZodIssueCode.custom,
502
+ }), (F(c) || c === "") && l.addIssue({
503
+ code: d.ZodIssueCode.custom,
488
504
  message: n
489
505
  });
490
506
  });
491
507
  }
492
- function ee(r, e) {
493
- if (r instanceof m.ZodType)
508
+ function ce(r, e) {
509
+ if (r instanceof d.ZodType)
494
510
  return r;
495
511
  if (typeof r == "function")
496
512
  return r(e);
497
513
  }
498
- const Ae = (r) => Array.isArray(r == null ? void 0 : r.errors), ke = (r, e) => {
514
+ const We = (r) => Array.isArray(r == null ? void 0 : r.errors), Ge = (r, e) => {
499
515
  const n = {};
500
516
  for (; r.length; ) {
501
- const t = r[0], { code: a, message: s, path: u } = t, o = u.join(".");
517
+ const t = r[0], { code: a, message: s, path: i } = t, o = i.join(".");
502
518
  if (!n[o])
503
519
  if ("unionErrors" in t) {
504
- const i = t.unionErrors[0].errors[0];
520
+ const u = t.unionErrors[0].errors[0];
505
521
  n[o] = {
506
- message: i.message,
507
- type: i.code
522
+ message: u.message,
523
+ type: u.code
508
524
  };
509
525
  } else
510
526
  n[o] = { message: s, type: a };
511
- "unionErrors" in t && t.unionErrors.forEach((i) => i.errors.forEach((c) => r.push(c)));
527
+ "unionErrors" in t && t.unionErrors.forEach((u) => u.errors.forEach((c) => r.push(c)));
512
528
  {
513
- const i = n[o].types, c = i && i[t.code];
514
- n[o] = _e(
529
+ const u = n[o].types, c = u && u[t.code];
530
+ n[o] = xe(
515
531
  o,
516
532
  e,
517
533
  n,
@@ -523,20 +539,20 @@ const Ae = (r) => Array.isArray(r == null ? void 0 : r.errors), ke = (r, e) => {
523
539
  }
524
540
  return n;
525
541
  };
526
- function ze(r, e) {
527
- return he(
542
+ function fr(r, e) {
543
+ return Oe(
528
544
  async (n, t, a) => {
529
545
  try {
530
- return await Pe(r, n, e).parseAsync(n), {
546
+ return await Le(r, n, e).parseAsync(n), {
531
547
  values: n,
532
548
  // TODO: check this - values does not contains all data
533
549
  errors: {}
534
550
  };
535
551
  } catch (s) {
536
- if (Ae(s))
552
+ if (We(s))
537
553
  return {
538
554
  values: {},
539
- errors: Re(ke(s.errors, !0), a)
555
+ errors: qe(Ge(s.errors, !0), a)
540
556
  };
541
557
  throw s;
542
558
  }
@@ -544,63 +560,63 @@ function ze(r, e) {
544
560
  [r]
545
561
  );
546
562
  }
547
- function Ne(r, e) {
548
- const n = x(r);
563
+ function He(r, e) {
564
+ const n = q(r);
549
565
  return e.forEach((t) => {
550
- t.inputTransform && (E(t.inputTransform) ? t.inputTransform : [t.inputTransform]).forEach((s) => {
551
- const u = b(n, t.path), o = s(u, n);
566
+ t.inputTransform && (S(t.inputTransform) ? t.inputTransform : [t.inputTransform]).forEach((s) => {
567
+ const i = b(n, t.path), o = s(i, n);
552
568
  o && g(n, o.path ?? t.path, o.value);
553
569
  });
554
570
  }), n;
555
571
  }
556
- function De(r, e) {
557
- const n = x(r);
572
+ function Qe(r, e) {
573
+ const n = q(r);
558
574
  return e.forEach((t) => {
559
- t.outputTransform && (E(t.outputTransform) ? t.outputTransform : [t.outputTransform]).forEach((s) => {
560
- const u = b(n, t.path), o = s(u, n);
575
+ t.outputTransform && (S(t.outputTransform) ? t.outputTransform : [t.outputTransform]).forEach((s) => {
576
+ const i = b(n, t.path), o = s(i, n);
561
577
  o && g(n, o.path ?? t.path, o.value);
562
578
  });
563
579
  }), n;
564
580
  }
565
- function M(r) {
566
- return r.reduce((n, t) => (t.inputType === "group" || t.inputType === "accordion") && t.inputs ? [...n, t, ...M(t.inputs)] : [...n, t], []);
581
+ function L(r) {
582
+ return r.reduce((n, t) => (t.inputType === "group" || t.inputType === "accordion") && t.inputs ? [...n, t, ...L(t.inputs)] : [...n, t], []);
567
583
  }
568
- function re(r) {
569
- const n = M(r.inputs).reduce((t, a) => {
584
+ function fe(r) {
585
+ const n = L(r.inputs).reduce((t, a) => {
570
586
  const s = a.inputType === "text" || a.inputType === "boolean" || a.inputType === "number" || a.inputType === "textarea" || a.inputType === "select";
571
587
  return (a.inputTransform || a.outputTransform) && t.push({
572
- ...oe(a, "path", "inputTransform", "outputTransform"),
588
+ ...ye(a, "path", "inputTransform", "outputTransform"),
573
589
  level: a.path.split(".").length,
574
590
  isPrimitive: s
575
591
  }), t;
576
592
  }, []);
577
593
  return n.sort((t, a) => t.level === a.level ? t.isPrimitive ? 1 : -1 : t.level > a.level ? -1 : 1), n;
578
594
  }
579
- function Me(r, e, n, t = {}) {
580
- const { preserve: a } = t, s = M(r.inputs), u = x(e);
595
+ function Xe(r, e, n, t = {}) {
596
+ const { preserve: a } = t, s = L(r.inputs), i = q(e);
581
597
  return s.forEach((o) => {
582
- a && a.includes(o.path) || o.isVisible && !o.isVisible(e, n) && ue(u, o.path);
583
- }), u;
598
+ a && a.includes(o.path) || o.isVisible && !o.isVisible(e, n) && ge(i, o.path);
599
+ }), i;
584
600
  }
585
- function er(r, e) {
586
- const n = re(e);
587
- return Ne(r, n);
601
+ function lr(r, e) {
602
+ const n = fe(e);
603
+ return He(r, n);
588
604
  }
589
- function rr(r, e, n, t = {}) {
590
- const a = re(e);
591
- let s = Me(e, r, n, t);
592
- return s = De(s, a), s = xe(s), s;
605
+ function dr(r, e, n, t = {}) {
606
+ const a = fe(e);
607
+ let s = Xe(e, r, n, t);
608
+ return s = Qe(s, a), s = $e(s), s;
593
609
  }
594
- function tr(r) {
610
+ function mr(r) {
595
611
  const e = {}, n = (t) => {
596
612
  t.forEach((a) => {
597
- const { default: s, path: u, inputType: o, inputs: i } = a;
598
- (o === "group" || o === "accordion") && Array.isArray(i) ? n(i) : s !== void 0 && g(e, u, s);
613
+ const { default: s, path: i, inputType: o, inputs: u } = a;
614
+ (o === "group" || o === "accordion") && Array.isArray(u) ? n(u) : s !== void 0 && g(e, i, s);
599
615
  });
600
616
  };
601
617
  return Array.isArray(r.inputs) && n(r.inputs), e;
602
618
  }
603
- function nr() {
619
+ function hr() {
604
620
  return function(r, e) {
605
621
  if (!(typeof r > "u"))
606
622
  return r ? {
@@ -608,7 +624,7 @@ function nr() {
608
624
  } : { value: r };
609
625
  };
610
626
  }
611
- function sr(r) {
627
+ function pr(r) {
612
628
  return function(e, n) {
613
629
  if (typeof e > "u") return;
614
630
  if (!e) return { value: e };
@@ -618,64 +634,64 @@ function sr(r) {
618
634
  return r != null && r.unsetIfEmpty && Object.getOwnPropertyNames(t.value).length === 0 ? { value: void 0 } : t;
619
635
  };
620
636
  }
621
- function ar() {
637
+ function yr() {
622
638
  return function(r, e) {
623
639
  if (!(typeof r > "u"))
624
- return E(r) && j(r) ? { value: void 0 } : { value: r };
640
+ return S(r) && C(r) ? { value: void 0 } : { value: r };
625
641
  };
626
642
  }
627
- function or(r) {
643
+ function gr(r) {
628
644
  return function(e, n) {
629
645
  const t = r ? b(n, r) : e;
630
646
  if (!(typeof t > "u")) {
631
- if (Q(t)) return { value: void 0, path: r };
632
- if (H(t)) {
633
- const a = X(t, ie);
634
- if (j(a))
647
+ if (se(t)) return { value: void 0, path: r };
648
+ if (ne(t)) {
649
+ const a = ae(t, be);
650
+ if (C(a))
635
651
  return { value: void 0, path: r };
636
652
  }
637
653
  return { value: t, path: r };
638
654
  }
639
655
  };
640
656
  }
641
- function ur() {
657
+ function br() {
642
658
  return function(r, e) {
643
659
  if (!(typeof r > "u"))
644
- return ce(r) && j(r) ? { value: void 0 } : { value: r };
660
+ return ve(r) && C(r) ? { value: void 0 } : { value: r };
645
661
  };
646
662
  }
647
- function ir(r) {
663
+ function vr(r) {
648
664
  return function(e, n) {
649
665
  const t = b(n, r);
650
666
  return typeof t == "string" ? { value: t } : { value: e };
651
667
  };
652
668
  }
653
- function cr(r) {
669
+ function _r(r) {
654
670
  return function(e, n) {
655
671
  if (typeof e > "u") return;
656
672
  if (!e) return { value: e };
657
673
  const t = b(n, r);
658
674
  if (typeof t == "object") {
659
- const a = Ze(t);
675
+ const a = Ye(t);
660
676
  if (Object.getOwnPropertyNames(a).length === 1)
661
677
  return { value: e, path: r };
662
678
  }
663
679
  return { value: e };
664
680
  };
665
681
  }
666
- function fr(r) {
682
+ function Rr(r) {
667
683
  return function(e, n) {
668
684
  if (typeof e > "u") return;
669
685
  const t = b(n, r);
670
686
  return typeof t == "string" ? { value: [t] } : { value: e };
671
687
  };
672
688
  }
673
- function lr(r, e) {
689
+ function Er(r, e) {
674
690
  return function(n, t) {
675
691
  if (typeof n > "u") return;
676
692
  if (!n) return { value: n };
677
693
  const a = b(t, r);
678
- if (E(a)) {
694
+ if (S(a)) {
679
695
  if (a.length === 1)
680
696
  return { value: a[0], path: r };
681
697
  if (a.length === 0 && e != null && e.unsetIfEmpty)
@@ -684,43 +700,42 @@ function lr(r, e) {
684
700
  return { value: n };
685
701
  };
686
702
  }
687
- function te(r) {
688
- return typeof r == "object" ? !Object.getOwnPropertyNames(r).some((e) => !te(r[e])) : q(r);
703
+ function le(r) {
704
+ return typeof r == "object" ? !Object.getOwnPropertyNames(r).some((e) => !le(r[e])) : F(r);
689
705
  }
690
- function Ze(r) {
691
- return X(r, (e) => typeof e == "object" ? te(e) : q(e));
706
+ function Ye(r) {
707
+ return ae(r, (e) => typeof e == "object" ? le(e) : F(e));
692
708
  }
693
- function W(r) {
709
+ function re(r) {
694
710
  const { items: e, ...n } = r;
695
- return /* @__PURE__ */ h.jsx(h.Fragment, { children: e.map((t) => /* @__PURE__ */ h.jsx(
696
- Ve,
711
+ return /* @__PURE__ */ p.jsx(p.Fragment, { children: e.map((t) => /* @__PURE__ */ p.jsx(
712
+ Ze,
697
713
  {
698
714
  input: t,
699
715
  path: t.path,
700
- readonly: !1,
701
716
  ...n
702
717
  },
703
718
  `${t.inputType}_${t.path}_${t.label}`
704
719
  )) });
705
720
  }
706
- const Be = pe((r, e) => {
721
+ const Ke = Se((r, e) => {
707
722
  const { inputs: n, className: t, factory: a, withoutWrapper: s } = r;
708
- return s ? /* @__PURE__ */ h.jsxs(ye, { children: [
723
+ return s ? /* @__PURE__ */ p.jsxs(je, { children: [
709
724
  n.hero,
710
- /* @__PURE__ */ h.jsx(W, { items: n.inputs, factory: a, withoutWrapper: s })
711
- ] }) : /* @__PURE__ */ h.jsxs("div", { className: t, ref: e, children: [
725
+ /* @__PURE__ */ p.jsx(re, { items: n.inputs, factory: a, withoutWrapper: s })
726
+ ] }) : /* @__PURE__ */ p.jsxs("div", { className: t, ref: e, children: [
712
727
  n.hero,
713
- /* @__PURE__ */ h.jsx(W, { items: n.inputs, factory: a, withoutWrapper: s })
728
+ /* @__PURE__ */ p.jsx(re, { items: n.inputs, factory: a, withoutWrapper: s })
714
729
  ] });
715
730
  });
716
- Be.displayName = "RenderForm";
717
- function dr(r) {
731
+ Ke.displayName = "RenderForm";
732
+ function Tr(r) {
718
733
  let e = !0;
719
- return G(r, (n) => {
720
- e = e && (n === "" || Q(n) || q(n));
734
+ return te(r, (n) => {
735
+ e = e && (n === "" || se(n) || F(n));
721
736
  }), e;
722
737
  }
723
- const mr = (r = "") => fe(r.split("_").join(" ")), $e = (r, e = 2) => {
738
+ const Or = (r = "") => _e(r.split("_").join(" ")), ze = (r, e = 2) => {
724
739
  let n = !1;
725
740
  const t = () => {
726
741
  requestAnimationFrame(() => {
@@ -731,54 +746,54 @@ const mr = (r = "") => fe(r.split("_").join(" ")), $e = (r, e = 2) => {
731
746
  n = !0;
732
747
  };
733
748
  };
734
- function hr(r) {
749
+ function Sr(r) {
735
750
  const {
736
751
  field: { onBlur: e, ...n },
737
752
  ...t
738
- } = Ee(r);
753
+ } = Pe(r);
739
754
  return {
740
755
  ...t,
741
756
  field: {
742
757
  ...n,
743
- onBlur: $e(e)
758
+ onBlur: ze(e)
744
759
  }
745
760
  };
746
761
  }
747
762
  export {
748
- He as InputComponent,
749
- Ve as InputComponentRenderer,
750
- Y as InputFactory,
751
- Te as InputOverrideError,
752
- Be as RenderForm,
753
- W as RenderInputs,
754
- Qe as RootForm,
755
- $e as afterFrames,
756
- sr as arrayToObjectOutputTransformer,
757
- tr as collectDefaultValues,
758
- er as convertDataToFormModel,
759
- rr as convertFormModelToData,
760
- mr as generateReadableLabel,
761
- Xe as getDefaultValuesFromFormDefinition,
762
- Ke as getTemporaryPath,
763
- re as getTransformers,
764
- Pe as getValidationSchema,
765
- Ne as inputTransformValues,
766
- dr as isChildrenEmpty,
767
- nr as objectToArrayInputTransformer,
768
- De as outputTransformValues,
769
- Ye as overrideFormDefinition,
770
- S as processValidationParseResponse,
771
- xe as removeTemporaryFieldsValue,
772
- fr as shorthandArrayInputTransformer,
773
- lr as shorthandArrayOutputTransformer,
774
- ir as shorthandObjectInputTransformer,
775
- cr as shorthandObjectOutputTransformer,
776
- ar as unsetEmptyArrayOutputTransformer,
777
- or as unsetEmptyObjectOutputTransformer,
778
- ur as unsetEmptyStringOutputTransformer,
779
- Me as unsetHiddenInputsValues,
780
- hr as useController,
781
- Ce as useRootFormContext,
782
- ze as useZodValidationResolver
763
+ ar as InputComponent,
764
+ Ze as InputComponentRenderer,
765
+ oe as InputFactory,
766
+ Fe as InputOverrideError,
767
+ Ke as RenderForm,
768
+ re as RenderInputs,
769
+ or as RootForm,
770
+ ze as afterFrames,
771
+ pr as arrayToObjectOutputTransformer,
772
+ mr as collectDefaultValues,
773
+ lr as convertDataToFormModel,
774
+ dr as convertFormModelToData,
775
+ Or as generateReadableLabel,
776
+ ur as getDefaultValuesFromFormDefinition,
777
+ cr as getTemporaryPath,
778
+ fe as getTransformers,
779
+ Le as getValidationSchema,
780
+ He as inputTransformValues,
781
+ Tr as isChildrenEmpty,
782
+ hr as objectToArrayInputTransformer,
783
+ Qe as outputTransformValues,
784
+ ir as overrideFormDefinition,
785
+ I as processValidationParseResponse,
786
+ $e as removeTemporaryFieldsValue,
787
+ Rr as shorthandArrayInputTransformer,
788
+ Er as shorthandArrayOutputTransformer,
789
+ vr as shorthandObjectInputTransformer,
790
+ _r as shorthandObjectOutputTransformer,
791
+ yr as unsetEmptyArrayOutputTransformer,
792
+ gr as unsetEmptyObjectOutputTransformer,
793
+ br as unsetEmptyStringOutputTransformer,
794
+ Xe as unsetHiddenInputsValues,
795
+ Sr as useController,
796
+ Me as useRootFormContext,
797
+ fr as useZodValidationResolver
783
798
  };
784
799
  //# sourceMappingURL=index.js.map