@conform-to/react 1.14.1 → 1.15.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/README.md +1 -1
- package/dist/future/hooks.d.ts +2 -2
- package/dist/future/index.d.ts +3 -3
- package/dist/future/index.js +4 -0
- package/dist/future/index.mjs +1 -1
- package/dist/future/state.d.ts +2 -2
- package/dist/future/types.d.ts +1 -5
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
╚══════╝ ╚═════╝ ╚═╝ ╚══╝ ╚═╝ ╚═════╝ ╚═╝ ╚═╝ ╚═╝ ╚═╝
|
|
8
8
|
```
|
|
9
9
|
|
|
10
|
-
Version 1.
|
|
10
|
+
Version 1.15.0 / License MIT / Copyright (c) 2025 Edmund Hung
|
|
11
11
|
|
|
12
12
|
Progressively enhance HTML forms with React. Build resilient, type-safe forms with no hassle using web standards.
|
|
13
13
|
|
package/dist/future/hooks.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { type FormValue, type Serialize, type SubmissionResult, createGlobalFormsObserver } from '@conform-to/dom/future';
|
|
1
|
+
import { type FieldName, type FormValue, type Serialize, type SubmissionResult, createGlobalFormsObserver } from '@conform-to/dom/future';
|
|
2
2
|
import { useEffect } from 'react';
|
|
3
|
-
import type { FormContext, IntentDispatcher, FormMetadata, Fieldset, GlobalFormOptions, FormOptions,
|
|
3
|
+
import type { FormContext, IntentDispatcher, FormMetadata, Fieldset, GlobalFormOptions, FormOptions, FieldMetadata, Control, Selector, UseFormDataOptions, ValidateHandler, ErrorHandler, SubmitHandler, FormState, FormRef, BaseErrorShape, DefaultErrorShape, BaseSchemaType, InferInput, InferOutput } from './types';
|
|
4
4
|
import { StandardSchemaV1 } from './standard-schema';
|
|
5
5
|
export declare const INITIAL_KEY = "INITIAL_KEY";
|
|
6
6
|
export declare const GlobalFormOptionsContext: import("react").Context<GlobalFormOptions & {
|
package/dist/future/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
export type { FormError, FormValue, Submission, SubmissionResult, } from '@conform-to/dom/future';
|
|
2
|
-
export { parseSubmission, report, isDirty } from '@conform-to/dom/future';
|
|
3
|
-
export type { Control, DefaultValue, BaseMetadata, CustomMetadata, CustomMetadataDefinition, BaseErrorShape, CustomTypes, FormContext, FormMetadata, FormOptions, FormRef, FieldMetadata,
|
|
1
|
+
export type { FieldName, FormError, FormValue, Submission, SubmissionResult, } from '@conform-to/dom/future';
|
|
2
|
+
export { getFieldValue, parseSubmission, report, isDirty, } from '@conform-to/dom/future';
|
|
3
|
+
export type { Control, DefaultValue, BaseMetadata, CustomMetadata, CustomMetadataDefinition, BaseErrorShape, CustomTypes, FormContext, FormMetadata, FormOptions, FormRef, FieldMetadata, Fieldset, IntentDispatcher, } from './types';
|
|
4
4
|
export { FormProvider, FormOptionsProvider, useControl, useField, useForm, useFormData, useFormMetadata, useIntent, } from './hooks';
|
|
5
5
|
export { memoize } from './memoize';
|
|
6
6
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/future/index.js
CHANGED
|
@@ -8,6 +8,10 @@ var memoize = require('./memoize.js');
|
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
|
|
11
|
+
Object.defineProperty(exports, 'getFieldValue', {
|
|
12
|
+
enumerable: true,
|
|
13
|
+
get: function () { return future.getFieldValue; }
|
|
14
|
+
});
|
|
11
15
|
Object.defineProperty(exports, 'isDirty', {
|
|
12
16
|
enumerable: true,
|
|
13
17
|
get: function () { return future.isDirty; }
|
package/dist/future/index.mjs
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export { isDirty, parseSubmission, report } from '@conform-to/dom/future';
|
|
1
|
+
export { getFieldValue, isDirty, parseSubmission, report } from '@conform-to/dom/future';
|
|
2
2
|
export { FormOptionsProvider, FormProvider, useControl, useField, useForm, useFormData, useFormMetadata, useIntent } from './hooks.mjs';
|
|
3
3
|
export { memoize } from './memoize.mjs';
|
package/dist/future/state.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { type ValidationAttributes, type Serialize } from '@conform-to/dom/future';
|
|
2
|
-
import type { FieldMetadata,
|
|
1
|
+
import { type FieldName, type ValidationAttributes, type Serialize } from '@conform-to/dom/future';
|
|
2
|
+
import type { FieldMetadata, Fieldset, FormContext, FormMetadata, FormState, FormAction, UnknownIntent, ActionHandler, CustomMetadataDefinition } from './types';
|
|
3
3
|
export declare function initializeState<ErrorShape>(options?: {
|
|
4
4
|
defaultValue?: Record<string, unknown> | null | undefined;
|
|
5
5
|
resetKey?: string | undefined;
|
package/dist/future/types.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { FormError, FormValue, Serialize, SubmissionResult, ValidationAttributes } from '@conform-to/dom/future';
|
|
1
|
+
import type { FieldName, FormError, FormValue, Serialize, SubmissionResult, ValidationAttributes } from '@conform-to/dom/future';
|
|
2
2
|
import type { StandardSchemaV1 } from './standard-schema';
|
|
3
3
|
export type Prettify<T> = {
|
|
4
4
|
[K in keyof T]: T[K];
|
|
@@ -182,10 +182,6 @@ export interface FormContext<ErrorShape extends BaseErrorShape = DefaultErrorSha
|
|
|
182
182
|
/** Blur event handler for form-wide blur events */
|
|
183
183
|
handleBlur: (event: React.FocusEvent) => void;
|
|
184
184
|
}
|
|
185
|
-
/** The name of an input field with type information for TypeScript inference. */
|
|
186
|
-
export type FieldName<FieldShape> = string & {
|
|
187
|
-
'~shape'?: FieldShape;
|
|
188
|
-
};
|
|
189
185
|
export type UnknownIntent = {
|
|
190
186
|
type: string;
|
|
191
187
|
payload?: unknown;
|
package/package.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"description": "Conform view adapter for react",
|
|
4
4
|
"homepage": "https://conform.guide",
|
|
5
5
|
"license": "MIT",
|
|
6
|
-
"version": "1.
|
|
6
|
+
"version": "1.15.0",
|
|
7
7
|
"main": "./dist/index.js",
|
|
8
8
|
"module": "./dist/index.mjs",
|
|
9
9
|
"types": "./dist/index.d.ts",
|
|
@@ -41,7 +41,7 @@
|
|
|
41
41
|
"url": "https://github.com/edmundhung/conform/issues"
|
|
42
42
|
},
|
|
43
43
|
"dependencies": {
|
|
44
|
-
"@conform-to/dom": "1.
|
|
44
|
+
"@conform-to/dom": "1.15.0"
|
|
45
45
|
},
|
|
46
46
|
"devDependencies": {
|
|
47
47
|
"@babel/core": "^7.17.8",
|