@formisch/qwik 0.9.3 → 0.9.5

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.
@@ -40,10 +40,10 @@ function batch(fn) {
40
40
  */
41
41
  function initializeFieldStore(internalFieldStore, schema, initialInput, path, nullish = false) {
42
42
  if (framework === "qwik" && schema.type === "lazy" || schema.type === "object_with_rest" || schema.type === "record" || schema.type === "tuple_with_rest" || schema.type === "promise") throw new Error(`"${schema.type}" schema is not supported`);
43
- else if (schema.type === "lazy") initializeFieldStore(internalFieldStore, schema.getter(void 0), initialInput, path);
43
+ else if (schema.type === "lazy") initializeFieldStore(internalFieldStore, schema.getter(void 0), initialInput, path, nullish);
44
44
  else if (schema.type === "exact_optional" || schema.type === "nullable" || schema.type === "nullish" || schema.type === "optional" || schema.type === "undefinedable") initializeFieldStore(internalFieldStore, schema.wrapped, initialInput === void 0 ? v.getDefault(schema) : initialInput, path, true);
45
45
  else if (schema.type === "non_nullable" || schema.type === "non_nullish" || schema.type === "non_optional") initializeFieldStore(internalFieldStore, schema.wrapped, initialInput, path);
46
- else if (schema.type === "intersect" || schema.type === "union" || schema.type === "variant") for (const schemaOption of schema.options) initializeFieldStore(internalFieldStore, schemaOption, initialInput, path);
46
+ else if (schema.type === "intersect" || schema.type === "union" || schema.type === "variant") for (const schemaOption of schema.options) initializeFieldStore(internalFieldStore, schemaOption, initialInput, path, nullish);
47
47
  else {
48
48
  internalFieldStore.schema = schema;
49
49
  internalFieldStore.name = JSON.stringify(path);
@@ -977,7 +977,7 @@ const Form = component$(({ of, onSubmit$,...other }) => {
977
977
  ref: (element) => {
978
978
  of[INTERNAL].element = element;
979
979
  },
980
- onSubmit$: handleSubmit(of, onSubmit$),
980
+ onSubmit$: (event) => handleSubmit(of, onSubmit$)(event),
981
981
  children: /* @__PURE__ */ jsx(Slot, {})
982
982
  });
983
983
  });
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@formisch/qwik",
3
3
  "description": "The modular and type-safe form library for Qwik",
4
- "version": "0.9.3",
4
+ "version": "0.9.5",
5
5
  "license": "MIT",
6
6
  "author": "Fabian Hiller",
7
7
  "homepage": "https://formisch.dev",
@@ -47,9 +47,9 @@
47
47
  "valibot": "^1.2.0",
48
48
  "vite": "7.0.4",
49
49
  "vite-tsconfig-paths": "^5.1.4",
50
- "@formisch/core": "0.6.2",
51
- "@formisch/methods": "0.7.0",
52
- "@formisch/eslint-config": "0.1.0"
50
+ "@formisch/eslint-config": "0.1.0",
51
+ "@formisch/core": "0.6.3",
52
+ "@formisch/methods": "0.7.0"
53
53
  },
54
54
  "peerDependencies": {
55
55
  "@qwik.dev/core": ">=2",