@factorialco/f0-react 2.55.1 → 2.55.3

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.
@@ -12103,9 +12103,9 @@ function JI(t) {
12103
12103
  return n?.typeName === "ZodObject" || n?.typeName === "ZodEffects";
12104
12104
  }
12105
12105
  function Ey(t, e) {
12106
- const n = typeof t == "function", i = !1, [r, s] = K(
12106
+ const n = typeof t == "function", i = !!e, [r, s] = K(
12107
12107
  n ? void 0 : t
12108
- ), [o, a] = K(n && !i), l = X(t);
12108
+ ), [o, a] = K(n), l = X(t);
12109
12109
  l.current = t;
12110
12110
  const c = X(e);
12111
12111
  return c.current = e, fe(() => {
@@ -12113,11 +12113,7 @@ function Ey(t, e) {
12113
12113
  const d = new AbortController();
12114
12114
  a(!0);
12115
12115
  const f = l.current;
12116
- return c.current && !c.current.safeParse(d.signal).success ? (a(!1), () => {
12117
- d.abort();
12118
- }) : (f(
12119
- d.signal
12120
- ).then((h) => {
12116
+ return (c.current ? f({}) : f(d.signal)).then((h) => {
12121
12117
  d.signal.aborted || (s(h), a(!1));
12122
12118
  }).catch((h) => {
12123
12119
  d.signal.aborted || (console.warn(
@@ -12126,7 +12122,7 @@ function Ey(t, e) {
12126
12122
  ), s(void 0), a(!1));
12127
12123
  }), () => {
12128
12124
  d.abort();
12129
- });
12125
+ };
12130
12126
  }, [n, i]), n ? { resolved: r, isLoading: o } : { resolved: t, isLoading: !1 };
12131
12127
  }
12132
12128
  function YI(t) {
@@ -42666,7 +42662,8 @@ function Wx({
42666
42662
  isLoading: a
42667
42663
  }) {
42668
42664
  const l = t, { resolved: c, isLoading: d } = Ey(
42669
- l.asyncDefaultValues ?? l.defaultValues
42665
+ l.asyncDefaultValues ?? l.defaultValuesFn ?? l.defaultValues,
42666
+ l.defaultValuesParamsSchema
42670
42667
  ), f = se(
42671
42668
  (u) => l.onSubmit({ data: u }),
42672
42669
  [l]
@@ -42707,7 +42704,8 @@ function qx({
42707
42704
  isLoading: a
42708
42705
  }) {
42709
42706
  const l = t, { resolved: c, isLoading: d } = Ey(
42710
- l.asyncDefaultValues ?? l.defaultValues
42707
+ l.asyncDefaultValues ?? l.defaultValuesFn ?? l.defaultValues,
42708
+ l.defaultValuesParamsSchema
42711
42709
  ), f = X(
42712
42710
  c ? { ...c } : {}
42713
42711
  ), u = se(
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@factorialco/f0-react",
3
- "version": "2.55.1",
3
+ "version": "2.55.3",
4
4
  "private": false,
5
5
  "files": [
6
6
  "assets",