@paragrav/rhf-utils 0.0.147 → 0.59.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.
Files changed (213) hide show
  1. package/README.md +273 -118
  2. package/dist/dts/Register.d.ts +16 -0
  3. package/dist/dts/_exports/config.d.ts +2 -0
  4. package/dist/dts/_exports/errors.d.ts +3 -0
  5. package/dist/dts/_exports/form.d.ts +7 -0
  6. package/dist/dts/_exports/index.d.ts +13 -0
  7. package/dist/dts/_exports/relay.d.ts +8 -0
  8. package/dist/dts/_exports/submit.d.ts +4 -0
  9. package/dist/dts/_exports/trpc.d.ts +2 -0
  10. package/dist/dts/_exports/types.d.ts +7 -0
  11. package/dist/dts/_exports/zod.d.ts +6 -0
  12. package/dist/dts/client/config/RhfUtilsClientConfigType.d.ts +63 -0
  13. package/dist/dts/client/config/context/RhfUtilsClientConfigContext.d.ts +3 -0
  14. package/dist/dts/client/config/context/RhfUtilsClientConfigProvider.d.ts +7 -0
  15. package/dist/dts/client/config/context/useRhfUtilsClientConfig.d.ts +1 -0
  16. package/dist/{types → dts}/devtool/LazyDevTool.d.ts +3 -4
  17. package/dist/dts/devtool/LazyDevToolViaProviders.d.ts +1 -0
  18. package/dist/{types → dts}/errors/flat/FlatFieldErrorsList.d.ts +2 -2
  19. package/dist/{types → dts}/errors/flat/context/FlatFieldErrorsContextProvider.d.ts +3 -3
  20. package/dist/{types → dts}/errors/flat/context/useFlatFieldErrorsContext.d.ts +1 -2
  21. package/dist/dts/errors/flat/context/useFlatFieldErrorsContextHasOnlyOrphans.d.ts +6 -0
  22. package/dist/{types → dts}/errors/flat/context/useFlatFieldErrorsContextOutput.d.ts +1 -2
  23. package/dist/dts/errors/flat/filterFlatFieldErrors.d.ts +7 -0
  24. package/dist/{types → dts}/errors/flat/flattenFieldErrors.d.ts +1 -2
  25. package/dist/{types → dts}/errors/flat/getFlatFieldErrors.d.ts +2 -1
  26. package/dist/dts/errors/getRefdFromFlatFieldErrors.d.ts +1 -0
  27. package/dist/{types → dts}/errors/isFieldErrorRefd.d.ts +1 -2
  28. package/dist/dts/errors/isFlatFieldErrorEntryRefd.d.ts +5 -0
  29. package/dist/{types → dts}/errors/message/FormErrorMessage.d.ts +2 -2
  30. package/dist/{types → dts}/errors/message/RhfUtilsFieldErrorMessage.d.ts +2 -2
  31. package/dist/{types → dts}/errors/nonfield/RhfUtilsNonFieldErrorMarker.d.ts +2 -2
  32. package/dist/dts/errors/nonfield/RhfUtilsNonFieldErrorMarkerHtmlAttribute.d.ts +4 -0
  33. package/dist/{types → dts}/errors/nonfield/isNonFieldError.d.ts +1 -2
  34. package/dist/dts/errors/nonfield/isNonFieldErrorMarkerInDOM.d.ts +5 -0
  35. package/dist/dts/errors/orphan/getIsOrphanFormErrorWithParentElement.d.ts +5 -0
  36. package/dist/dts/errors/orphan/getOrphansFromFlatFieldErrors.d.ts +2 -0
  37. package/dist/dts/errors/orphan/isOrphanFormError.d.ts +2 -0
  38. package/dist/dts/errors/output/consoleErrors.d.ts +5 -0
  39. package/dist/dts/errors/root/RootErrorsListFromFlatFieldErrorsContext.d.ts +1 -0
  40. package/dist/dts/errors/root/getRootsFromFlatFieldErrors.d.ts +1 -0
  41. package/dist/{types → dts}/errors/root/isFlatFieldErrorEntryPathRoot.d.ts +1 -2
  42. package/dist/{types → dts}/errors/root/isFormErrorPathRoot.d.ts +1 -2
  43. package/dist/{types → dts}/errors/trpc/makeOnSubmitTrpcClientErrorHandler.d.ts +2 -3
  44. package/dist/dts/errors/trpc/trpcClientErrorMessageSchema.d.ts +19 -0
  45. package/dist/dts/errors/trpc/trpcClientErrorToFormSubmitFieldErrorsSchemaTransformer.d.ts +23 -0
  46. package/dist/dts/form/RHF_UseFormReturnWithoutProxiesType.d.ts +15 -0
  47. package/dist/dts/form/RhfUtilsFormComponentPropsType.d.ts +17 -0
  48. package/dist/dts/form/RhfUtilsFormStateWithUtilsType.d.ts +7 -0
  49. package/dist/dts/form/UseRhfUtilsFormChildrenPropsType.d.ts +25 -0
  50. package/dist/dts/form/_Controller.d.ts +4 -0
  51. package/dist/dts/form/context/utils/RhfUtilsContextPropsType.d.ts +11 -0
  52. package/dist/dts/form/context/utils/RhfUtilsContextProvider.d.ts +9 -0
  53. package/dist/dts/form/context/utils/useRhfUtilsContext.d.ts +5 -0
  54. package/dist/dts/form/context/utils/useRhfUtilsContextRequestSubmit.d.ts +4 -0
  55. package/dist/dts/form/defaults/UseRhfUtilsFormGlobalDefaults.d.ts +24 -0
  56. package/dist/dts/form/defaults/UseRhfUtilsFormInstanceDefaults.d.ts +18 -0
  57. package/dist/dts/form/defaults/UseRhfUtilsFormResolvedDefaultsType.d.ts +12 -0
  58. package/dist/dts/form/defaults/form/UseRhfUtilsFormInstanceFormProps.d.ts +6 -0
  59. package/dist/dts/form/defaults/form/getRhfUtilsFormResolvedFormProps.d.ts +2 -0
  60. package/dist/dts/form/defaults/form/useRhfUtilsFormResolvedFormProps.d.ts +293 -0
  61. package/dist/{types/form/RhfUtilsFormOptions.d.ts → dts/form/options/RhfUtilsFormOptionsType.d.ts} +6 -7
  62. package/dist/dts/form/options/getRhfUtilsFormResolvedOptions.d.ts +2 -0
  63. package/dist/dts/form/options/useRhfUtilsFormResolvedOptions.d.ts +8 -0
  64. package/dist/dts/form/providers/RhfUtilsFormProviders.d.ts +6 -0
  65. package/dist/dts/form/providers/RhfUtilsFormProvidersPropsType.d.ts +15 -0
  66. package/dist/dts/form/rhf/UseFormPropsType.d.ts +4 -0
  67. package/dist/dts/form/rhf/getRhfUtilsFormResolvedRhfProps.d.ts +4 -0
  68. package/dist/dts/form/rhf/useRhfFormWithResolvedProps.d.ts +5 -0
  69. package/dist/dts/form/state/relay/FormStateRelayContextProvider.d.ts +4 -0
  70. package/dist/dts/form/state/relay/FormStateRelayedAggregatedType.d.ts +10 -0
  71. package/dist/dts/form/state/relay/FormStateRelayedItemType.d.ts +11 -0
  72. package/dist/dts/form/state/relay/FormStateRelayedOptionsType.d.ts +20 -0
  73. package/dist/dts/form/state/relay/FormStateRelayedType.d.ts +3 -0
  74. package/dist/dts/form/state/relay/pull/hooks.d.ts +31 -0
  75. package/dist/dts/form/state/relay/push/FormStateRelayPusher.d.ts +4 -0
  76. package/dist/dts/form/state/relay/push/useFormStateRelayPusher.d.ts +3 -0
  77. package/dist/dts/form/state/relay/useFormStateRelayContext.d.ts +20 -0
  78. package/dist/dts/form/state/relay/utils.d.ts +4 -0
  79. package/dist/dts/form/utils/getSubmitterButtonData.d.ts +6 -0
  80. package/dist/{types → dts}/form/utils/useFormRequestSubmit.d.ts +1 -2
  81. package/dist/dts/form/utils/useHandleCancelWithCheckIfCanBe.d.ts +4 -0
  82. package/dist/dts/form/utils/useHandleCancelWithCheckIfCanBeViaProviders.d.ts +2 -0
  83. package/dist/{types → dts}/form/utils/useShouldFormBlockNavigation.d.ts +1 -2
  84. package/dist/dts/form/with-handlers-and-children/RhfUtilsForm.d.ts +3 -0
  85. package/dist/dts/form/with-handlers-and-children/RhfUtilsFormProps.d.ts +46 -0
  86. package/dist/dts/form/with-handlers-and-children/_ChildrenViaProviders.d.ts +3 -0
  87. package/dist/dts/form/with-handlers-and-children/_FormWithSubmitHandler.d.ts +4 -0
  88. package/dist/dts/form/with-handlers-and-children/_useHandleSubmit.d.ts +11 -0
  89. package/dist/dts/form/with-providers/RhfUtilsFormWithProviders.d.ts +8 -0
  90. package/dist/dts/form/with-providers/RhfUtilsFormWithProvidersProps.d.ts +4 -0
  91. package/dist/dts/resolvers/ObjectSchema.d.ts +7 -0
  92. package/dist/dts/resolvers/zod/RhfUtilsUseZodFormChildrenFCType.d.ts +7 -0
  93. package/dist/dts/resolvers/zod/RhfUtilsUseZodFormChildrenPropsType.d.ts +4 -0
  94. package/dist/dts/resolvers/zod/ZodTypeSafeFieldValuesType.d.ts +5 -0
  95. package/dist/dts/resolvers/zod/consts.d.ts +4 -0
  96. package/dist/dts/resolvers/zod/form/RhfUtilsZodForm.d.ts +7 -0
  97. package/dist/dts/resolvers/zod/getZodResolver.d.ts +4 -0
  98. package/dist/dts/resolvers/zod/providers/RhfUtilsZodFormProviders.d.ts +8 -0
  99. package/dist/dts/resolvers/zod/with-providers/RhfUtilsZodFormWithProviders.d.ts +10 -0
  100. package/dist/dts/submit/UseRhfUtilsFormOnSubmitContextType.d.ts +23 -0
  101. package/dist/dts/submit/error/FormSubmitError.d.ts +6 -0
  102. package/dist/{types → dts}/submit/error/FormSubmitFieldErrors.d.ts +1 -1
  103. package/dist/dts/submit/error/setCtxErrorsByFormSubmitFieldErrors.d.ts +8 -0
  104. package/dist/dts/submit/last-error/LastSubmitErrorContextProvider.d.ts +4 -0
  105. package/dist/dts/submit/last-error/LastSubmitErrorContextType.d.ts +8 -0
  106. package/dist/dts/submit/last-error/useLastSubmitError.d.ts +4 -0
  107. package/dist/dts/submit/last-error/useLastSubmitErrorContext.d.ts +3 -0
  108. package/dist/dts/submit/last-error/useLastSubmitErrorContextWith.d.ts +2 -0
  109. package/dist/{types → dts}/submit/useFormOnSubmitSuccessfulAndReset.d.ts +1 -2
  110. package/dist/dts/submit/useFormOnSubmitted.d.ts +4 -0
  111. package/dist/{types → dts}/submit/useResetFormOnSubmitted.d.ts +1 -2
  112. package/dist/dts/submit/useRhfUtilsFormOnSubmitContext.d.ts +3 -0
  113. package/dist/dts/submit/useSubmitFormOnChange.d.ts +15 -0
  114. package/dist/dts/submit/useSubmitFormOnEvent.d.ts +9 -0
  115. package/dist/dts/submit/useSubmitFormOnWatch.d.ts +14 -0
  116. package/dist/dts/utils/PassthroughChildren.d.ts +7 -0
  117. package/dist/{types → dts}/utils/createContext.d.ts +1 -2
  118. package/dist/dts/utils/fixedForwardRef.d.ts +5 -0
  119. package/dist/dts/utils/isEmptyObject.d.ts +1 -0
  120. package/dist/dts/utils/types.d.ts +3 -0
  121. package/dist/{types → dts}/utils/useImperativeForwardedRef.d.ts +1 -2
  122. package/dist/dts/utils/useIsFirstRender.d.ts +7 -0
  123. package/dist/dts/utils/useRefIfValueWasTrue.d.ts +2 -0
  124. package/dist/dts/utils/useToggle.d.ts +2 -0
  125. package/dist/dts/vite-env.d.ts +1 -0
  126. package/dist/esm/getFlatFieldErrors.mjs +55 -0
  127. package/dist/esm/index.mjs +503 -383
  128. package/dist/esm/relay.mjs +222 -0
  129. package/dist/esm/trpc.mjs +8 -9
  130. package/package.json +95 -23
  131. package/LICENSE.md +0 -21
  132. package/dist/esm/createContext.mjs +0 -16
  133. package/dist/esm/group.mjs +0 -74
  134. package/dist/esm/useFlatFieldErrorsContext.mjs +0 -10
  135. package/dist/esm/utils.mjs +0 -20
  136. package/dist/types/_exports/group.d.ts +0 -9
  137. package/dist/types/_exports/index.d.ts +0 -15
  138. package/dist/types/_exports/trpc.d.ts +0 -2
  139. package/dist/types/_exports/utils.d.ts +0 -1
  140. package/dist/types/client/config/RhfUtilsClientConfig.d.ts +0 -70
  141. package/dist/types/client/config/useRhfUtilsClientConfigContext.d.ts +0 -4
  142. package/dist/types/client/context.d.ts +0 -2
  143. package/dist/types/client/index.d.ts +0 -25
  144. package/dist/types/client/utils.d.ts +0 -12
  145. package/dist/types/client/zod/RhfUtilsUseFormChildrenZodFC.d.ts +0 -12
  146. package/dist/types/client/zod/RhfUtilsUseFormChildrenZodProps.d.ts +0 -4
  147. package/dist/types/client/zod/ZodTypeFieldValues.d.ts +0 -3
  148. package/dist/types/client/zod/consts.d.ts +0 -4
  149. package/dist/types/client/zod/context/RhfUtilsClientForZodContextProvider.d.ts +0 -7
  150. package/dist/types/client/zod/context/RhfUtilsZodForm.d.ts +0 -8
  151. package/dist/types/client/zod/context/useRhfUtilsClientForZodContext.d.ts +0 -5
  152. package/dist/types/client/zod/context/useRhfUtilsZodForm.d.ts +0 -7
  153. package/dist/types/client/zod/createRhfUtilsClientForZod.d.ts +0 -3
  154. package/dist/types/errors/flat/context/useFlatFieldErrorsContextHasOnlyOrphans.d.ts +0 -7
  155. package/dist/types/errors/flat/filterFlatFieldErrors.d.ts +0 -8
  156. package/dist/types/errors/getRefdFromFlatFieldErrors.d.ts +0 -2
  157. package/dist/types/errors/isFlatFieldErrorEntryRefd.d.ts +0 -6
  158. package/dist/types/errors/nonfield/RhfUtilsNonFieldErrorMarkerHtmlAttribute.d.ts +0 -5
  159. package/dist/types/errors/nonfield/isNonFieldErrorMarkerInDOM.d.ts +0 -6
  160. package/dist/types/errors/orphan/getIsOrphanFormErrorWithParentElement.d.ts +0 -6
  161. package/dist/types/errors/orphan/getOrphansFromFlatFieldErrors.d.ts +0 -3
  162. package/dist/types/errors/orphan/isOrphanFormError.d.ts +0 -3
  163. package/dist/types/errors/output/consoleErrors.d.ts +0 -6
  164. package/dist/types/errors/root/RootErrorsListFromFlatFieldErrorsContext.d.ts +0 -2
  165. package/dist/types/errors/root/getRootsFromFlatFieldErrors.d.ts +0 -2
  166. package/dist/types/errors/trpc/trpcClientErrorMessageSchema.d.ts +0 -23
  167. package/dist/types/errors/trpc/trpcClientErrorToFormSubmitFieldErrorsSchemaTransformer.d.ts +0 -27
  168. package/dist/types/form/Form.d.ts +0 -10
  169. package/dist/types/form/FormWithProviders.d.ts +0 -12
  170. package/dist/types/form/RhfUtilsFormProviders.d.ts +0 -11
  171. package/dist/types/form/UseRhfUtilsFormChildrenProps.d.ts +0 -19
  172. package/dist/types/form/UseRhfUtilsFormOnSubmitContext.d.ts +0 -28
  173. package/dist/types/form/UseRhfUtilsFormProps.d.ts +0 -22
  174. package/dist/types/form/UseRhfUtilsFormReturn.d.ts +0 -19
  175. package/dist/types/form/_Controller.d.ts +0 -5
  176. package/dist/types/form/context/group/FormGroupContextProvider.d.ts +0 -4
  177. package/dist/types/form/context/group/index.d.ts +0 -14
  178. package/dist/types/form/context/group/useFormGroupChildIsMountedTracker.d.ts +0 -5
  179. package/dist/types/form/context/group/useFormGroupChildIsSubmittingTracker.d.ts +0 -5
  180. package/dist/types/form/context/group/useFormGroupChildTracker.d.ts +0 -6
  181. package/dist/types/form/context/group/useFormGroupIsAnyBusy.d.ts +0 -2
  182. package/dist/types/form/context/group/useFormGroupIsChildBusy.d.ts +0 -2
  183. package/dist/types/form/context/group/useFormGroupIsParentBusy.d.ts +0 -2
  184. package/dist/types/form/context/group/useFormGroupParentTracker.d.ts +0 -7
  185. package/dist/types/form/context/group/useFormOrParentIsBusy.d.ts +0 -2
  186. package/dist/types/form/context/utils/RhfUtilsContextProvider.d.ts +0 -8
  187. package/dist/types/form/context/utils/useRhfUtilsContext.d.ts +0 -13
  188. package/dist/types/form/context/utils/useRhfUtilsContextRequestSubmit.d.ts +0 -5
  189. package/dist/types/form/useFormIsBusy.d.ts +0 -2
  190. package/dist/types/form/useRhfUtilsForm.d.ts +0 -15
  191. package/dist/types/form/utils/getSubmitterButtonData.d.ts +0 -7
  192. package/dist/types/register.d.ts +0 -7
  193. package/dist/types/submit/error/FormSubmitError.d.ts +0 -6
  194. package/dist/types/submit/error/setCtxErrorsByFormSubmitFieldErrors.d.ts +0 -9
  195. package/dist/types/submit/useFormOnSubmitted.d.ts +0 -5
  196. package/dist/types/submit/useSubmitFormOnChange.d.ts +0 -8
  197. package/dist/types/utils/PassthroughChildren.d.ts +0 -7
  198. package/dist/types/utils/fixedForwardRef.d.ts +0 -6
  199. package/dist/types/utils/isEmptyObject.d.ts +0 -2
  200. package/dist/types/utils/types.d.ts +0 -1
  201. package/dist/types/utils/useRefIfValueWasTrue.d.ts +0 -2
  202. package/dist/types/utils/useThrowAsyncError.d.ts +0 -5
  203. package/dist/types/utils/useToggle.d.ts +0 -3
  204. /package/dist/{types → dts}/errors/flat/context/FlatFieldErrorsOutputConfig.d.ts +0 -0
  205. /package/dist/{types → dts}/errors/flat/types.d.ts +0 -0
  206. /package/dist/{types → dts}/errors/nonfield/RhfUtilsNonFieldErrorMarker.spec.d.ts +0 -0
  207. /package/dist/{types → dts}/errors/nonfield/RhfUtilsNonFieldErrorMarker.utils.d.ts +0 -0
  208. /package/dist/{types → dts}/errors/output/types.d.ts +0 -0
  209. /package/dist/{types → dts}/errors/root/consts.d.ts +0 -0
  210. /package/dist/{types/form/SafeFieldValues.d.ts → dts/form/rhf/SafeFieldValuesType.d.ts} +0 -0
  211. /package/dist/{types → dts}/main.d.ts +0 -0
  212. /package/dist/{types → dts}/utils/timeoutAsync.d.ts +0 -0
  213. /package/dist/{types → dts}/utils/useDebouncedOnChangeValue.d.ts +0 -0
@@ -0,0 +1,63 @@
1
+ import { FlatFieldErrorsOutputConfig } from '../../errors/flat/context/FlatFieldErrorsOutputConfig';
2
+ import { UseRhfUtilsFormGlobalDefaults } from '../../form/defaults/UseRhfUtilsFormGlobalDefaults';
3
+ import { RhfUtilsFormComponentProps } from '../../form/RhfUtilsFormComponentPropsType';
4
+ import { FormSubmitFieldErrors } from '../../submit/error/FormSubmitFieldErrors';
5
+ import { UseRhfUtilsFormOnSubmitContext } from '../../submit/UseRhfUtilsFormOnSubmitContextType';
6
+ import { MaybePromise } from '../../utils/types';
7
+ /**
8
+ * Client configuration object.
9
+ *
10
+ * Options under `defaults` can be overridden at form level.
11
+ */
12
+ export type RhfUtilsClientConfig = {
13
+ /**
14
+ * Default options for all forms. (Are overridden by form-specific options.)
15
+ */
16
+ defaults?: UseRhfUtilsFormGlobalDefaults;
17
+ /**
18
+ * Supply your own `<form>` component. (By default, a native {@link HTMLFormElement} is used.)
19
+ *
20
+ * @description
21
+ *
22
+ * Can be used to inject your own hooks, components, etc.
23
+ *
24
+ * (NOTE: context params are not schema-typed as not possible at this level.)
25
+ */
26
+ FormComponent?: React.FC<React.PropsWithChildren<RhfUtilsFormComponentProps>>;
27
+ /**
28
+ * A hook that returns a callback that determines whether form can be cancelled at event-time.
29
+ *
30
+ * @description
31
+ *
32
+ * Cancellation of forms often doesn't involve navigation, making it more challenging to centrally handle.
33
+ * Your hook's returned callback should internally prompt user and return response as `boolean`
34
+ * indicating whether cancellation should be blocked. See `README.md` for example.
35
+ *
36
+ * @returns Callback that, given {@link RhfUtilsFormContext} at event-time, returns `boolean` value indicating whether form can be cancelled.
37
+ *
38
+ * Callback should return:
39
+ * `true`: if form can be cancelled (e.g., form not dirty or user confirmed via prompt); {@link UseRhfUtilsFormProps.onCancel} is called.
40
+ * `false`: form cannot be cancelled (e.g., user denied); {@link UseRhfUtilsFormProps.onCancel} is not called.
41
+ */
42
+ useCanFormBeCancelled?: () => (props: UseRhfUtilsFormOnSubmitContext) => MaybePromise<boolean>;
43
+ /**
44
+ * Global submit error handler when/if submit handler throws an error other than {@link FormSubmitError}.
45
+ *
46
+ * Example use case:
47
+ * - transform API errors to {@link FormSubmitFieldErrors}.
48
+ *
49
+ * @returns
50
+ * - if {@link FormSubmitFieldErrors}: merge into context errors.
51
+ * - if `undefined`: do nothing.
52
+ */
53
+ onSubmitErrorUnknown?: (error: unknown) => FormSubmitFieldErrors | undefined;
54
+ /**
55
+ * Configuration regarding RHF form state errors (`useFormContext().formState.errors`).
56
+ */
57
+ fieldErrors?: {
58
+ /**
59
+ * Configure how/if errors should be outputted for debugging/reporting (i.e., console and/or throwing).
60
+ */
61
+ output?: FlatFieldErrorsOutputConfig;
62
+ };
63
+ };
@@ -0,0 +1,3 @@
1
+ import { default as React } from 'react';
2
+ import { RhfUtilsClientConfig } from '../RhfUtilsClientConfigType';
3
+ export declare const RhfUtilsClientConfigContext_Internal: React.Context<RhfUtilsClientConfig | undefined>;
@@ -0,0 +1,7 @@
1
+ import { default as React } from 'react';
2
+ import { RhfUtilsClientConfig } from '../RhfUtilsClientConfigType';
3
+ type Props = React.PropsWithChildren<{
4
+ config?: RhfUtilsClientConfig;
5
+ }>;
6
+ export declare const RhfUtilsClientConfigProvider: React.FC<Props>;
7
+ export {};
@@ -0,0 +1 @@
1
+ export declare const useRhfUtilsClientConfig: () => import('../RhfUtilsClientConfigType').RhfUtilsClientConfig;
@@ -1,11 +1,10 @@
1
1
  import { DevtoolUIProps } from '@hookform/devtools/dist/devToolUI';
2
2
  import { default as React } from 'react';
3
3
  type LazyDevToolProps = {
4
- enabled?: boolean;
5
- props?: Omit<DevtoolUIProps, 'control'>;
4
+ config?: boolean | Pick<DevtoolUIProps, 'placement' | 'styles'>;
6
5
  };
7
6
  /**
8
7
  * Lazy-loaded RHF DevTool.
9
8
  */
10
- declare const LazyDevTool: React.FC<LazyDevToolProps>;
11
- export default LazyDevTool;
9
+ export declare const LazyDevTool: React.FC<LazyDevToolProps>;
10
+ export {};
@@ -0,0 +1 @@
1
+ export declare const LazyDevToolViaProviders: React.FC;
@@ -1,6 +1,6 @@
1
1
  import { FlatFieldErrors } from './types';
2
2
  export type Props = {
3
3
  errors: FlatFieldErrors | null | undefined;
4
+ className?: string;
4
5
  };
5
- declare const FlatFieldErrorsList: React.FC<Props>;
6
- export default FlatFieldErrorsList;
6
+ export declare const FlatFieldErrorsList: React.FC<Props>;
@@ -1,10 +1,10 @@
1
1
  import { default as React } from 'react';
2
2
  type Props = React.PropsWithChildren<{
3
- formRef: React.RefObject<HTMLFormElement>;
3
+ formRef: React.RefObject<HTMLFormElement | null>;
4
4
  }>;
5
5
  /**
6
6
  * Provides a flattened version of the form errors.
7
7
  * Allows flattening and filtering to happen once per errors change.
8
8
  */
9
- declare const FlatFieldErrorsContextProvider: React.FC<Props>;
10
- export default FlatFieldErrorsContextProvider;
9
+ export declare const FlatFieldErrorsContextProvider: React.FC<Props>;
10
+ export {};
@@ -8,5 +8,4 @@ export type FlatFieldErrorsContext = {
8
8
  hasOrphans: boolean;
9
9
  };
10
10
  declare const _FormErrorsFlatContextProvider: import('react').Provider<FlatFieldErrorsContext | undefined>, useFlatFieldErrorsContext: () => FlatFieldErrorsContext;
11
- export default useFlatFieldErrorsContext;
12
- export { _FormErrorsFlatContextProvider };
11
+ export { _FormErrorsFlatContextProvider, useFlatFieldErrorsContext };
@@ -0,0 +1,6 @@
1
+ /**
2
+ * Returns `true` if all errors are orphans.
3
+ *
4
+ * You may want to treat this case specifically.
5
+ */
6
+ export declare const useFlatFieldErrorsContextHasOnlyOrphans: () => boolean;
@@ -2,5 +2,4 @@ import { FlatFieldErrorsOutputConfig } from './FlatFieldErrorsOutputConfig';
2
2
  /**
3
3
  * Outputs (e.g., console, throw) errors based on config.
4
4
  */
5
- declare const useFlatFieldErrorsContextOutput: (config?: FlatFieldErrorsOutputConfig) => void;
6
- export default useFlatFieldErrorsContextOutput;
5
+ export declare const useFlatFieldErrorsContextOutput: (config?: FlatFieldErrorsOutputConfig) => void;
@@ -0,0 +1,7 @@
1
+ import { FlatFieldErrorEntry, FlatFieldErrors } from './types';
2
+ /**
3
+ * Filter {@link FlatFieldErrors} by a predicate.
4
+ *
5
+ * (Encapsulates to and from Object entries.)
6
+ */
7
+ export declare const makeFlatFieldErrorsFilter: (predicate: (entry: FlatFieldErrorEntry, index: number) => boolean) => (errors: FlatFieldErrors) => FlatFieldErrors;
@@ -11,5 +11,4 @@ import { FieldErrors } from 'react-hook-form';
11
11
  * }
12
12
  * ```
13
13
  */
14
- declare const flattenFieldErrors: (errors: FieldErrors) => Record<string, unknown>;
15
- export default flattenFieldErrors;
14
+ export declare const flattenFieldErrors: (errors: FieldErrors) => Record<string, unknown>;
@@ -1,4 +1,4 @@
1
- import { FieldErrors } from 'react-hook-form';
1
+ import { FieldError, FieldErrors } from 'react-hook-form';
2
2
  import { FlatFieldErrors } from './types';
3
3
  /**
4
4
  * Get {@link FlatFieldErrors} from {@link FieldErrors}.
@@ -28,3 +28,4 @@ export declare const getFlatFieldErrors: (errors: FieldErrors) => FlatFieldError
28
28
  * iow: dot [?: non-capturing]("type" | "message")[\b word boundary][$ end of string]
29
29
  */
30
30
  export declare const regexMaybeFieldErrorLeafNodeSuffix: RegExp;
31
+ export declare const getFlatFieldErrorsSansRef: (errors: FieldErrors) => Record<string, Omit<FieldError, "ref">>;
@@ -0,0 +1 @@
1
+ export declare const getRefdFromFlatFieldErrors: (errors: import('./flat/types').FlatFieldErrors) => import('./flat/types').FlatFieldErrors;
@@ -2,5 +2,4 @@ import { FieldError } from 'react-hook-form';
2
2
  /**
3
3
  * Determine if {@link FieldError} is a `ref`'d field error.
4
4
  */
5
- declare const isFieldErrorRefd: (error: FieldError) => boolean;
6
- export default isFieldErrorRefd;
5
+ export declare const isFieldErrorRefd: (error: FieldError) => boolean;
@@ -0,0 +1,5 @@
1
+ import { FlatFieldErrorEntry } from './flat/types';
2
+ /**
3
+ * Determine if {@link FieldError} is a `ref`'d field error.
4
+ */
5
+ export declare const isFlatFieldErrorEntryRefd: ([, error,]: FlatFieldErrorEntry) => boolean;
@@ -3,5 +3,5 @@ type Props = {
3
3
  message: string;
4
4
  className?: string;
5
5
  };
6
- declare const FormErrorMessage: React.FC<Props>;
7
- export default FormErrorMessage;
6
+ export declare const FormErrorMessage: React.FC<Props>;
7
+ export {};
@@ -6,5 +6,5 @@ type Props = {
6
6
  message: string;
7
7
  }>;
8
8
  };
9
- declare const RhfUtilsFieldErrorMessage: React.FC<Props>;
10
- export default RhfUtilsFieldErrorMessage;
9
+ export declare const RhfUtilsFieldErrorMessage: React.FC<Props>;
10
+ export {};
@@ -9,5 +9,5 @@ type Props = {
9
9
  * Field array with minimum items.
10
10
  * (When there are no items, the error is not associated with a field and is displayed separately.)
11
11
  */
12
- declare const RhfUtilsNonFieldErrorMarker: React.FC<Props>;
13
- export default RhfUtilsNonFieldErrorMarker;
12
+ export declare const RhfUtilsNonFieldErrorMarker: React.FC<Props>;
13
+ export {};
@@ -0,0 +1,4 @@
1
+ /**
2
+ * HTML data attribute for {@link RhfUtilsNonFieldErrorMarker}.
3
+ */
4
+ export declare const RhfUtilsNonFieldErrorMarkerHtmlAttribute = "data-rhfutils-nonfield-error-marker-path";
@@ -14,5 +14,4 @@ import { FieldError } from 'react-hook-form';
14
14
  * - The schema is incorrect.
15
15
  * - The error is not displayed to user with `FormErrorNonFieldMarker`.
16
16
  */
17
- declare const isNonFieldError: (error: FieldError) => boolean;
18
- export default isNonFieldError;
17
+ export declare const isNonFieldError: (error: FieldError) => boolean;
@@ -0,0 +1,5 @@
1
+ /**
2
+ * Determine if a non-field error marker is in the DOM.
3
+ * Note: this will also look for nested markers to accommodate field arrays
4
+ */
5
+ export declare const isNonFieldErrorMarkerInDOM: (path: string, parentElement: Pick<HTMLElement, "querySelector">) => boolean;
@@ -0,0 +1,5 @@
1
+ import { FlatFieldErrorEntry } from '../flat/types';
2
+ /**
3
+ * Util wrapper for {@link isOrphanFormError} for usage with {@link FlatFieldErrorEntry}.
4
+ */
5
+ export declare const getIsFlatFieldErrorEntryOrphanByParentElement: (parentElement: Pick<HTMLElement, "querySelector">) => ([path, error]: FlatFieldErrorEntry) => boolean;
@@ -0,0 +1,2 @@
1
+ import { FlatFieldErrors } from '../flat/types';
2
+ export declare const getOrphansFromFlatFieldErrors: (errors: FlatFieldErrors, parentElement: Pick<HTMLElement, "querySelector">) => FlatFieldErrors;
@@ -0,0 +1,2 @@
1
+ import { FieldError } from 'react-hook-form';
2
+ export declare const isOrphanFormError: (path: string, error: FieldError, parentElement: Pick<HTMLElement, "querySelector">) => boolean;
@@ -0,0 +1,5 @@
1
+ import { SafeFieldValues } from '../../form/rhf/SafeFieldValuesType';
2
+ /**
3
+ * Output form values and errors to console.
4
+ */
5
+ export declare const consoleErrors: (message: string, values: SafeFieldValues, errors: Record<string, unknown>, type?: "debug" | "error") => void;
@@ -0,0 +1 @@
1
+ export declare const RootErrorsListFromFlatFieldErrorsContext: React.FC;
@@ -0,0 +1 @@
1
+ export declare const getRootsFromFlatFieldErrors: (errors: import('../flat/types').FlatFieldErrors) => import('../flat/types').FlatFieldErrors;
@@ -2,5 +2,4 @@ import { FlatFieldErrorEntry } from '../flat/types';
2
2
  /**
3
3
  * Util wrapper for {@link isFormErrorPathRoot} for usage with {@link FlatFieldErrorEntry}.
4
4
  */
5
- declare const isFlatFieldErrorEntryPathRoot: ([path]: FlatFieldErrorEntry) => boolean;
6
- export default isFlatFieldErrorEntryPathRoot;
5
+ export declare const isFlatFieldErrorEntryPathRoot: ([path]: FlatFieldErrorEntry) => boolean;
@@ -3,5 +3,4 @@
3
3
  *
4
4
  * @param path Flat path. (e.g., 'root.nested')
5
5
  */
6
- declare const isFormErrorPathRoot: (path: string) => boolean;
7
- export default isFormErrorPathRoot;
6
+ export declare const isFormErrorPathRoot: (path: string) => boolean;
@@ -1,4 +1,4 @@
1
- import { RhfUtilsClientConfig } from '../../client/config/RhfUtilsClientConfig';
1
+ import { RhfUtilsClientConfig } from '../../client/config/RhfUtilsClientConfigType';
2
2
  import { FormSubmitFieldErrors } from '../../submit/error/FormSubmitFieldErrors';
3
3
  /**
4
4
  * HOF that returns submit error handler for {@link RhfUtilsClientConfig.onSubmitErrorUnknown}.
@@ -6,5 +6,4 @@ import { FormSubmitFieldErrors } from '../../submit/error/FormSubmitFieldErrors'
6
6
  * @param onError Fallback for handling non-TRPC errors.
7
7
  * @returns FormSubmitError
8
8
  */
9
- declare const makeOnSubmitTrpcClientErrorHandler: (onNotTrpcClientError: NonNullable<RhfUtilsClientConfig["onSubmitErrorUnknown"]>) => (error: unknown) => FormSubmitFieldErrors | undefined;
10
- export default makeOnSubmitTrpcClientErrorHandler;
9
+ export declare const makeOnSubmitTrpcClientErrorHandler: (onNotTrpcClientError: NonNullable<RhfUtilsClientConfig["onSubmitErrorUnknown"]>) => (error: unknown) => FormSubmitFieldErrors | undefined;
@@ -0,0 +1,19 @@
1
+ import { z } from 'zod';
2
+ /**
3
+ * Schema for {@link TRPCClientError} message.
4
+ *
5
+ * (Sent from backend as JSON string.)
6
+ */
7
+ export declare const trpcClientErrorMessageSchema: z.ZodObject<{
8
+ code: z.ZodString;
9
+ message: z.ZodString;
10
+ path: z.ZodArray<z.ZodString, "many">;
11
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
12
+ code: z.ZodString;
13
+ message: z.ZodString;
14
+ path: z.ZodArray<z.ZodString, "many">;
15
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
16
+ code: z.ZodString;
17
+ message: z.ZodString;
18
+ path: z.ZodArray<z.ZodString, "many">;
19
+ }, z.ZodTypeAny, "passthrough">>;
@@ -0,0 +1,23 @@
1
+ import { TRPCClientErrorLike } from '@trpc/client';
2
+ import { AnyTRPCRouter } from '@trpc/server';
3
+ import { z } from 'zod';
4
+ import { FormSubmitFieldErrors } from '../../submit/error/FormSubmitFieldErrors';
5
+ /**
6
+ * Schema that transforms {@link TRPCClientError} to RHF {@link FormSubmitFieldErrors}.
7
+ */
8
+ export declare const trpcClientErrorToFormSubmitFieldErrorsSchemaTransformer: z.ZodEffects<z.ZodEffects<z.ZodPipeline<z.ZodEffects<z.ZodEffects<z.ZodType<TRPCClientErrorLike<AnyTRPCRouter>, z.ZodTypeDef, TRPCClientErrorLike<AnyTRPCRouter>>, string, TRPCClientErrorLike<AnyTRPCRouter>>, unknown, TRPCClientErrorLike<AnyTRPCRouter>>, z.ZodArray<z.ZodObject<{
9
+ code: z.ZodString;
10
+ message: z.ZodString;
11
+ path: z.ZodArray<z.ZodString, "many">;
12
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
13
+ code: z.ZodString;
14
+ message: z.ZodString;
15
+ path: z.ZodArray<z.ZodString, "many">;
16
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
17
+ code: z.ZodString;
18
+ message: z.ZodString;
19
+ path: z.ZodArray<z.ZodString, "many">;
20
+ }, z.ZodTypeAny, "passthrough">>, "many">>, (readonly [string, {
21
+ type: string;
22
+ message: string;
23
+ }])[], TRPCClientErrorLike<AnyTRPCRouter>>, FormSubmitFieldErrors, TRPCClientErrorLike<AnyTRPCRouter>>;
@@ -0,0 +1,15 @@
1
+ import { UseFormReturn } from 'react-hook-form';
2
+ import { SafeFieldValues } from './rhf/SafeFieldValuesType';
3
+ /**
4
+ * RHF's {@link UseFormReturn} without proxies -- i.e., `formState`.
5
+ *
6
+ * (Proxy values must be invoked or read individually before render.)
7
+ *
8
+ * @see https://react-hook-form.com/docs/useform/formstate
9
+ * @see https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Proxy
10
+ *
11
+ * @description
12
+ *
13
+ * Hiding them from consumer's callbacks, will force explicit usage before first render.
14
+ */
15
+ export type RHF_UseFormReturnWithoutProxies<TFieldValues extends SafeFieldValues = SafeFieldValues, TTransformedValues extends SafeFieldValues = TFieldValues> = Omit<UseFormReturn<TFieldValues, unknown, TTransformedValues>, 'formState'>;
@@ -0,0 +1,17 @@
1
+ import { UseFormReturn } from 'react-hook-form';
2
+ import { FormSubmitError } from '../submit/error/FormSubmitError';
3
+ import { _Controller } from './_Controller';
4
+ import { RhfUtilsContextProps } from './context/utils/RhfUtilsContextPropsType';
5
+ import { UseRhfUtilsFormInstanceFormProps } from './defaults/form/UseRhfUtilsFormInstanceFormProps';
6
+ import { SafeFieldValues } from './rhf/SafeFieldValuesType';
7
+ /**
8
+ * RhfUtilsClientConfig's FormComponent props.
9
+ */
10
+ export type RhfUtilsFormComponentProps<TFieldValues extends SafeFieldValues = SafeFieldValues, TTransformedValues extends SafeFieldValues = TFieldValues> = RhfUtilsContextProps & {
11
+ rhf: UseFormReturn<TFieldValues, unknown, TTransformedValues>;
12
+ formProps: UseRhfUtilsFormInstanceFormProps & {
13
+ onSubmit: NonNullable<React.PropsWithoutRef<React.JSX.IntrinsicElements['form']>['onSubmit']>;
14
+ };
15
+ Controller: typeof _Controller<TFieldValues>;
16
+ FormSubmitError: typeof FormSubmitError<TFieldValues>;
17
+ };
@@ -0,0 +1,7 @@
1
+ import { FormState } from 'react-hook-form';
2
+ import { RhfUtilsContextProps } from './context/utils/RhfUtilsContextPropsType';
3
+ import { SafeFieldValues } from './rhf/SafeFieldValuesType';
4
+ export type RhfUtilsFormStateWithUtilsType<TFieldValues extends SafeFieldValues = SafeFieldValues> = {
5
+ state: FormState<TFieldValues>;
6
+ utils: RhfUtilsContextProps;
7
+ };
@@ -0,0 +1,25 @@
1
+ import { UseFormReturn } from 'react-hook-form';
2
+ import { FormSubmitError } from '../submit/error/FormSubmitError';
3
+ import { MaybePromise } from '../utils/types';
4
+ import { _Controller } from './_Controller';
5
+ import { RhfUtilsContextProps } from './context/utils/RhfUtilsContextPropsType';
6
+ import { RhfUtilsFormOptions } from './options/RhfUtilsFormOptionsType';
7
+ import { SafeFieldValues } from './rhf/SafeFieldValuesType';
8
+ /**
9
+ * Component props for `Children`.
10
+ *
11
+ * (Consider keeping shape in line with `UseRhfUtilsFormOnSubmitProps` and `UseRhfUtilsFormReturn`.)
12
+ */
13
+ export type UseRhfUtilsFormChildrenProps<TFieldValues extends SafeFieldValues, TTransformedValues extends SafeFieldValues, TProps = undefined> = RhfUtilsContextProps & {
14
+ rhf: UseFormReturn<TFieldValues, unknown, TTransformedValues>;
15
+ options: RhfUtilsFormOptions;
16
+ Controller: typeof _Controller<TFieldValues>;
17
+ FormSubmitError: typeof FormSubmitError<TFieldValues>;
18
+ } & {
19
+ onCancel?: () => MaybePromise<void>;
20
+ } & // cancel
21
+ (TProps extends undefined ? {
22
+ props?: undefined;
23
+ } : {
24
+ props: TProps;
25
+ });
@@ -0,0 +1,4 @@
1
+ import { ControllerProps, FieldPath } from 'react-hook-form';
2
+ import { SafeFieldValues } from './rhf/SafeFieldValuesType';
3
+ export type _ControllerProps<TFieldValues extends SafeFieldValues, TName extends FieldPath<TFieldValues> = FieldPath<TFieldValues>> = Omit<ControllerProps<TFieldValues, TName>, 'control'>;
4
+ export declare const _Controller: <TFieldValues extends SafeFieldValues, TName extends FieldPath<TFieldValues> = FieldPath<TFieldValues>>(props: _ControllerProps<TFieldValues, TName>) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,11 @@
1
+ import { RefObject } from 'react';
2
+ import { RhfUtilsContextProviderProps } from './RhfUtilsContextProvider';
3
+ export type RhfUtilsContextProps = RhfUtilsContextProviderProps & {
4
+ /**
5
+ * Current form submit state.
6
+ *
7
+ * e.g., can be used to determine whether safe to redirect (navigate) without prompter.
8
+ * Unlike RHF's `isSubmitSuccessful`, is computed/set immediately after `onSubmit` succeeds/fails.
9
+ */
10
+ lastSubmitStateRef: RefObject<null | 'submitting' | 'success' | 'error'>;
11
+ };
@@ -0,0 +1,9 @@
1
+ import { default as React } from 'react';
2
+ import { RhfUtilsFormOptions } from '../../options/RhfUtilsFormOptionsType';
3
+ export type RhfUtilsContextProviderProps = {
4
+ formId: string;
5
+ formRef: React.RefObject<HTMLFormElement | null>;
6
+ /** Consumer-supplied options and values. */
7
+ options: RhfUtilsFormOptions;
8
+ };
9
+ export declare const RhfUtilsContextProvider: React.FC<React.PropsWithChildren<RhfUtilsContextProviderProps>>;
@@ -0,0 +1,5 @@
1
+ import { RhfUtilsContextProps } from './RhfUtilsContextPropsType';
2
+ declare const _RhfUtilsContextProvider: import('react').Provider<RhfUtilsContextProps | undefined>, useRhfUtilsContext: () => import('./RhfUtilsContextProvider').RhfUtilsContextProviderProps & {
3
+ lastSubmitStateRef: import('react').RefObject<null | "submitting" | "success" | "error">;
4
+ }, useRhfUtilsMaybeContext: () => RhfUtilsContextProps | undefined;
5
+ export { _RhfUtilsContextProvider, useRhfUtilsContext, useRhfUtilsMaybeContext, };
@@ -0,0 +1,4 @@
1
+ /**
2
+ * Get `requestSubmit` function from the form ref'd in current context.
3
+ */
4
+ export declare const useRhfUtilsContextRequestSubmit: () => (submitter?: HTMLElement | null) => void;
@@ -0,0 +1,24 @@
1
+ import { default as React } from 'react';
2
+ import { RhfUtilsFormOptions } from '../options/RhfUtilsFormOptionsType';
3
+ import { RhfUseFormGlobalProps } from '../rhf/UseFormPropsType';
4
+ /**
5
+ * Globally-relevant subset of defaults.
6
+ */
7
+ export type UseRhfUtilsFormGlobalDefaults = {
8
+ /**
9
+ * Default RHF `useForm` settings.
10
+ *
11
+ * (Exposes only non-local props.)
12
+ */
13
+ rhf?: RhfUseFormGlobalProps;
14
+ /**
15
+ * Global settings and defaults.
16
+ *
17
+ * (Extend this type via `Register` type to inject custom options/functionality via `Children` component.)
18
+ */
19
+ options?: RhfUtilsFormOptions;
20
+ /**
21
+ * Default props for form element.
22
+ */
23
+ form?: Pick<React.PropsWithoutRef<React.JSX.IntrinsicElements['form']>, 'className' | 'noValidate' | 'role'>;
24
+ };
@@ -0,0 +1,18 @@
1
+ import { RhfUtilsFormOptions } from '../options/RhfUtilsFormOptionsType';
2
+ import { SafeFieldValues } from '../rhf/SafeFieldValuesType';
3
+ import { RhfUseFormInstanceProps } from '../rhf/UseFormPropsType';
4
+ import { UseRhfUtilsFormInstanceFormProps } from './form/UseRhfUtilsFormInstanceFormProps';
5
+ /**
6
+ * Instance-specific subset of defaults.
7
+ */
8
+ export type UseRhfUtilsFormInstanceDefaults<TFieldValues extends SafeFieldValues, TTransformedValues extends SafeFieldValues> = {
9
+ rhf?: RhfUseFormInstanceProps<TFieldValues, TTransformedValues>;
10
+ options?: RhfUtilsFormOptions;
11
+ form?: UseRhfUtilsFormInstanceFormProps;
12
+ /**
13
+ * Class name for styling.
14
+ *
15
+ * (Surfaced for sake of styling libraries. Value is merged along with `form.className`.)
16
+ */
17
+ className?: string;
18
+ };
@@ -0,0 +1,12 @@
1
+ import { RhfUtilsFormOptions } from '../options/RhfUtilsFormOptionsType';
2
+ import { SafeFieldValues } from '../rhf/SafeFieldValuesType';
3
+ import { RhfUseFormInstanceProps } from '../rhf/UseFormPropsType';
4
+ import { UseRhfUtilsFormInstanceFormProps } from './form/UseRhfUtilsFormInstanceFormProps';
5
+ /**
6
+ * Global and instance defaults merged and resolved.
7
+ */
8
+ export type UseRhfUtilsFormResolvedDefaults<TFieldValues extends SafeFieldValues, TTransformedValues extends SafeFieldValues> = {
9
+ rhf: RhfUseFormInstanceProps<TFieldValues, TTransformedValues>;
10
+ options: RhfUtilsFormOptions;
11
+ form: UseRhfUtilsFormInstanceFormProps;
12
+ };
@@ -0,0 +1,6 @@
1
+ import { default as React } from 'react';
2
+ type DataAttributes = Record<`data-${string}`, string>;
3
+ type FormAttributes = React.PropsWithoutRef<React.JSX.IntrinsicElements['form']> & DataAttributes;
4
+ export type UseRhfUtilsFormInstanceFormProps = Omit<FormAttributes, 'id' | 'onSubmit'>;
5
+ export type RhfUtilsFormInstanceFormSurfacedProps = Pick<FormAttributes, 'className'>;
6
+ export {};
@@ -0,0 +1,2 @@
1
+ import { RhfUtilsFormInstanceFormSurfacedProps, UseRhfUtilsFormInstanceFormProps } from './UseRhfUtilsFormInstanceFormProps';
2
+ export declare const getRhfUtilsFormResolvedFormProps: (global: UseRhfUtilsFormInstanceFormProps | undefined, instance: UseRhfUtilsFormInstanceFormProps | undefined, surfaced?: RhfUtilsFormInstanceFormSurfacedProps) => UseRhfUtilsFormInstanceFormProps;