@dxos/react-ui-form 0.7.5-staging.e6154f3 → 0.8.1-main.ae460ac
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/lib/browser/index.mjs +5 -4
- package/dist/lib/browser/index.mjs.map +3 -3
- package/dist/lib/browser/meta.json +1 -1
- package/dist/lib/node/index.cjs +24 -23
- package/dist/lib/node/index.cjs.map +2 -2
- package/dist/lib/node/meta.json +1 -1
- package/dist/lib/node-esm/index.mjs +5 -4
- package/dist/lib/node-esm/index.mjs.map +3 -3
- package/dist/lib/node-esm/meta.json +1 -1
- package/dist/types/src/components/deprecated/Form.d.ts +1 -1
- package/dist/types/src/components/deprecated/Form.d.ts.map +1 -1
- package/dist/types/src/hooks/useForm.d.ts +2 -1
- package/dist/types/src/hooks/useForm.d.ts.map +1 -1
- package/package.json +24 -26
- package/src/components/deprecated/Form.tsx +2 -2
- package/src/hooks/useForm.ts +2 -1
|
@@ -112,9 +112,10 @@ import { getValue as getValue2 } from "@dxos/echo-schema";
|
|
|
112
112
|
import { createJsonPath as createJsonPath2 } from "@dxos/effect";
|
|
113
113
|
|
|
114
114
|
// packages/ui/react-ui-form/src/hooks/useForm.ts
|
|
115
|
+
import { SchemaAST as AST } from "effect";
|
|
115
116
|
import { useCallback, useEffect, useMemo, useState } from "react";
|
|
116
117
|
import { getValue, setValue } from "@dxos/echo-schema";
|
|
117
|
-
import {
|
|
118
|
+
import { createJsonPath, fromEffectValidationPath } from "@dxos/effect";
|
|
118
119
|
import { invariant } from "@dxos/invariant";
|
|
119
120
|
import { log } from "@dxos/log";
|
|
120
121
|
import { validateSchema } from "@dxos/schema";
|
|
@@ -122,7 +123,7 @@ var __dxlog_file = "/home/runner/work/dxos/dxos/packages/ui/react-ui-form/src/ho
|
|
|
122
123
|
var useForm = ({ schema, initialValues, onValuesChanged, onValidate, onValid, onSave }) => {
|
|
123
124
|
invariant(AST.isTypeLiteral(schema.ast), void 0, {
|
|
124
125
|
F: __dxlog_file,
|
|
125
|
-
L:
|
|
126
|
+
L: 93,
|
|
126
127
|
S: void 0,
|
|
127
128
|
A: [
|
|
128
129
|
"AST.isTypeLiteral(schema.ast)",
|
|
@@ -218,7 +219,7 @@ var useForm = ({ schema, initialValues, onValuesChanged, onValidate, onValid, on
|
|
|
218
219
|
} catch (err) {
|
|
219
220
|
log.catch(err, void 0, {
|
|
220
221
|
F: __dxlog_file,
|
|
221
|
-
L:
|
|
222
|
+
L: 203,
|
|
222
223
|
S: void 0,
|
|
223
224
|
C: (f, a) => f(...a)
|
|
224
225
|
});
|
|
@@ -289,7 +290,7 @@ var useForm = ({ schema, initialValues, onValuesChanged, onValidate, onValid, on
|
|
|
289
290
|
var createKeySet = (obj, value) => {
|
|
290
291
|
invariant(obj, void 0, {
|
|
291
292
|
F: __dxlog_file,
|
|
292
|
-
L:
|
|
293
|
+
L: 265,
|
|
293
294
|
S: void 0,
|
|
294
295
|
A: [
|
|
295
296
|
"obj",
|