@fuf-stack/uniform 1.5.7 → 1.6.1

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 (156) hide show
  1. package/dist/Checkboxes/index.cjs +12 -6
  2. package/dist/Checkboxes/index.cjs.map +1 -1
  3. package/dist/Checkboxes/index.js +11 -5
  4. package/dist/FieldArray/index.cjs +12 -6
  5. package/dist/FieldArray/index.cjs.map +1 -1
  6. package/dist/FieldArray/index.js +11 -5
  7. package/dist/Form/index.cjs +12 -6
  8. package/dist/Form/index.cjs.map +1 -1
  9. package/dist/Form/index.js +11 -5
  10. package/dist/Input/index.cjs +12 -6
  11. package/dist/Input/index.cjs.map +1 -1
  12. package/dist/Input/index.js +11 -5
  13. package/dist/RadioBoxes/index.cjs +12 -6
  14. package/dist/RadioBoxes/index.cjs.map +1 -1
  15. package/dist/RadioBoxes/index.js +11 -5
  16. package/dist/RadioTabs/index.cjs +12 -6
  17. package/dist/RadioTabs/index.cjs.map +1 -1
  18. package/dist/RadioTabs/index.js +11 -5
  19. package/dist/Radios/index.cjs +12 -6
  20. package/dist/Radios/index.cjs.map +1 -1
  21. package/dist/Radios/index.js +11 -5
  22. package/dist/Select/index.cjs +12 -6
  23. package/dist/Select/index.cjs.map +1 -1
  24. package/dist/Select/index.js +11 -5
  25. package/dist/SubmitButton/index.cjs +12 -6
  26. package/dist/SubmitButton/index.cjs.map +1 -1
  27. package/dist/SubmitButton/index.js +11 -5
  28. package/dist/Switch/index.cjs +12 -6
  29. package/dist/Switch/index.cjs.map +1 -1
  30. package/dist/Switch/index.js +11 -5
  31. package/dist/TextArea/index.cjs +12 -6
  32. package/dist/TextArea/index.cjs.map +1 -1
  33. package/dist/TextArea/index.js +11 -5
  34. package/dist/{chunk-KORRVEJL.cjs → chunk-345LYO4H.cjs} +3 -3
  35. package/dist/{chunk-KORRVEJL.cjs.map → chunk-345LYO4H.cjs.map} +1 -1
  36. package/dist/chunk-35V726MB.js +1 -0
  37. package/dist/chunk-35V726MB.js.map +1 -0
  38. package/dist/{chunk-RBQP2VHW.js → chunk-6C6YW5TM.js} +2 -2
  39. package/dist/{chunk-MLAU2DYU.cjs → chunk-A5Z75X7M.cjs} +3 -3
  40. package/dist/{chunk-MLAU2DYU.cjs.map → chunk-A5Z75X7M.cjs.map} +1 -1
  41. package/dist/chunk-AACO4OEK.cjs +100 -0
  42. package/dist/chunk-AACO4OEK.cjs.map +1 -0
  43. package/dist/chunk-AHJJIANM.js +7 -0
  44. package/dist/chunk-AHJJIANM.js.map +1 -0
  45. package/dist/{chunk-DFDZFIQN.js → chunk-BXGILW5C.js} +4 -4
  46. package/dist/chunk-CHNYQVWO.js +59 -0
  47. package/dist/chunk-CHNYQVWO.js.map +1 -0
  48. package/dist/chunk-CK362NWK.js +34 -0
  49. package/dist/chunk-CK362NWK.js.map +1 -0
  50. package/dist/chunk-D3NAUOYG.js +122 -0
  51. package/dist/chunk-D3NAUOYG.js.map +1 -0
  52. package/dist/{chunk-EALQ3KNW.cjs → chunk-E4DCVJS5.cjs} +3 -3
  53. package/dist/{chunk-EALQ3KNW.cjs.map → chunk-E4DCVJS5.cjs.map} +1 -1
  54. package/dist/{chunk-GE2QRIOE.cjs → chunk-F6JQYB53.cjs} +4 -4
  55. package/dist/{chunk-GE2QRIOE.cjs.map → chunk-F6JQYB53.cjs.map} +1 -1
  56. package/dist/{chunk-2ZM4P4G3.js → chunk-GUPJNFEX.js} +10 -6
  57. package/dist/{chunk-2ZM4P4G3.js.map → chunk-GUPJNFEX.js.map} +1 -1
  58. package/dist/{chunk-TCJK6IYV.js → chunk-H24QXVUI.js} +2 -2
  59. package/dist/{chunk-7FTSMHFL.js → chunk-HQGTCSHK.js} +2 -2
  60. package/dist/{chunk-CSTA3NED.cjs → chunk-IYULWK4H.cjs} +7 -5
  61. package/dist/chunk-IYULWK4H.cjs.map +1 -0
  62. package/dist/{chunk-LEEWUHKX.js → chunk-JKWNYLNS.js} +4 -4
  63. package/dist/chunk-JMFDNTVC.cjs +34 -0
  64. package/dist/chunk-JMFDNTVC.cjs.map +1 -0
  65. package/dist/chunk-LTKRK3OS.cjs +1 -0
  66. package/dist/chunk-LTKRK3OS.cjs.map +1 -0
  67. package/dist/{chunk-QIIMEQS3.js → chunk-MXUKW3PZ.js} +2 -2
  68. package/dist/{chunk-3UIFEC4R.cjs → chunk-NZBO4N3S.cjs} +3 -260
  69. package/dist/chunk-NZBO4N3S.cjs.map +1 -0
  70. package/dist/{chunk-UO52HWMC.cjs → chunk-NZIAIYPS.cjs} +4 -4
  71. package/dist/{chunk-UO52HWMC.cjs.map → chunk-NZIAIYPS.cjs.map} +1 -1
  72. package/dist/{chunk-P7Z25LOZ.cjs → chunk-OJHD2XHD.cjs} +3 -3
  73. package/dist/{chunk-P7Z25LOZ.cjs.map → chunk-OJHD2XHD.cjs.map} +1 -1
  74. package/dist/chunk-PCTYJUY7.cjs +7 -0
  75. package/dist/chunk-PCTYJUY7.cjs.map +1 -0
  76. package/dist/{chunk-47MZU3WD.js → chunk-PO5UQAU6.js} +2 -259
  77. package/dist/chunk-PO5UQAU6.js.map +1 -0
  78. package/dist/{chunk-UB44OT6Q.js → chunk-QRCV7JVB.js} +2 -2
  79. package/dist/{chunk-A5MP4JAG.cjs → chunk-RMCPVDAC.cjs} +3 -3
  80. package/dist/{chunk-A5MP4JAG.cjs.map → chunk-RMCPVDAC.cjs.map} +1 -1
  81. package/dist/{chunk-B5OTVY3W.js → chunk-SJZ7UUEE.js} +5 -3
  82. package/dist/{chunk-B5OTVY3W.js.map → chunk-SJZ7UUEE.js.map} +1 -1
  83. package/dist/chunk-TEIXBRF5.cjs +59 -0
  84. package/dist/chunk-TEIXBRF5.cjs.map +1 -0
  85. package/dist/chunk-TGJJZEHB.cjs +122 -0
  86. package/dist/chunk-TGJJZEHB.cjs.map +1 -0
  87. package/dist/{chunk-33X26MSK.js → chunk-TKFODQWI.js} +2 -2
  88. package/dist/{chunk-X5WF3MEZ.cjs → chunk-VPUMTPD3.cjs} +3 -3
  89. package/dist/{chunk-X5WF3MEZ.cjs.map → chunk-VPUMTPD3.cjs.map} +1 -1
  90. package/dist/{chunk-JABO2635.cjs → chunk-WFO4XPA3.cjs} +4 -4
  91. package/dist/{chunk-JABO2635.cjs.map → chunk-WFO4XPA3.cjs.map} +1 -1
  92. package/dist/{chunk-4XTUP7W7.cjs → chunk-XJBGXFVX.cjs} +10 -6
  93. package/dist/chunk-XJBGXFVX.cjs.map +1 -0
  94. package/dist/chunk-Z7FVILDT.js +100 -0
  95. package/dist/chunk-Z7FVILDT.js.map +1 -0
  96. package/dist/{chunk-LKBR2JGT.js → chunk-Z7NI5347.js} +2 -2
  97. package/dist/hooks/index.cjs +20 -7
  98. package/dist/hooks/index.cjs.map +1 -1
  99. package/dist/hooks/index.d.cts +10 -240
  100. package/dist/hooks/index.d.ts +10 -240
  101. package/dist/hooks/index.js +25 -12
  102. package/dist/hooks/useClientValidation/index.cjs +12 -0
  103. package/dist/hooks/useClientValidation/index.cjs.map +1 -0
  104. package/dist/hooks/useClientValidation/index.d.cts +78 -0
  105. package/dist/hooks/useClientValidation/index.d.ts +78 -0
  106. package/dist/hooks/useClientValidation/index.js +12 -0
  107. package/dist/hooks/useClientValidation/index.js.map +1 -0
  108. package/dist/hooks/useController/index.cjs +9 -0
  109. package/dist/hooks/useController/index.cjs.map +1 -0
  110. package/dist/hooks/useController/index.d.cts +28 -0
  111. package/dist/hooks/useController/index.d.ts +28 -0
  112. package/dist/hooks/useController/index.js +9 -0
  113. package/dist/hooks/useController/index.js.map +1 -0
  114. package/dist/hooks/useFormContext/index.cjs +11 -0
  115. package/dist/hooks/useFormContext/index.cjs.map +1 -0
  116. package/dist/hooks/useFormContext/index.d.cts +50 -0
  117. package/dist/hooks/useFormContext/index.d.ts +50 -0
  118. package/dist/hooks/useFormContext/index.js +11 -0
  119. package/dist/hooks/useFormContext/index.js.map +1 -0
  120. package/dist/hooks/useInput/index.cjs +8 -0
  121. package/dist/hooks/useInput/index.cjs.map +1 -0
  122. package/dist/hooks/useInput/index.d.cts +1 -0
  123. package/dist/hooks/useInput/index.d.ts +1 -0
  124. package/dist/hooks/useInput/index.js +8 -0
  125. package/dist/hooks/useInput/index.js.map +1 -0
  126. package/dist/hooks/useUniformField/index.cjs +14 -0
  127. package/dist/hooks/useUniformField/index.cjs.map +1 -0
  128. package/dist/hooks/useUniformField/index.d.cts +83 -0
  129. package/dist/hooks/useUniformField/index.d.ts +83 -0
  130. package/dist/hooks/useUniformField/index.js +14 -0
  131. package/dist/hooks/useUniformField/index.js.map +1 -0
  132. package/dist/hooks/useUniformFieldArray/index.cjs +15 -0
  133. package/dist/hooks/useUniformFieldArray/index.cjs.map +1 -0
  134. package/dist/hooks/useUniformFieldArray/index.d.cts +70 -0
  135. package/dist/hooks/useUniformFieldArray/index.d.ts +70 -0
  136. package/dist/hooks/useUniformFieldArray/index.js +15 -0
  137. package/dist/hooks/useUniformFieldArray/index.js.map +1 -0
  138. package/dist/index.cjs +30 -17
  139. package/dist/index.cjs.map +1 -1
  140. package/dist/index.d.cts +6 -1
  141. package/dist/index.d.ts +6 -1
  142. package/dist/index.js +39 -26
  143. package/package.json +33 -3
  144. package/dist/chunk-3UIFEC4R.cjs.map +0 -1
  145. package/dist/chunk-47MZU3WD.js.map +0 -1
  146. package/dist/chunk-4XTUP7W7.cjs.map +0 -1
  147. package/dist/chunk-CSTA3NED.cjs.map +0 -1
  148. /package/dist/{chunk-RBQP2VHW.js.map → chunk-6C6YW5TM.js.map} +0 -0
  149. /package/dist/{chunk-DFDZFIQN.js.map → chunk-BXGILW5C.js.map} +0 -0
  150. /package/dist/{chunk-TCJK6IYV.js.map → chunk-H24QXVUI.js.map} +0 -0
  151. /package/dist/{chunk-7FTSMHFL.js.map → chunk-HQGTCSHK.js.map} +0 -0
  152. /package/dist/{chunk-LEEWUHKX.js.map → chunk-JKWNYLNS.js.map} +0 -0
  153. /package/dist/{chunk-QIIMEQS3.js.map → chunk-MXUKW3PZ.js.map} +0 -0
  154. /package/dist/{chunk-UB44OT6Q.js.map → chunk-QRCV7JVB.js.map} +0 -0
  155. /package/dist/{chunk-33X26MSK.js.map → chunk-TKFODQWI.js.map} +0 -0
  156. /package/dist/{chunk-LKBR2JGT.js.map → chunk-Z7NI5347.js.map} +0 -0
@@ -0,0 +1,50 @@
1
+ import * as _fuf_stack_veto from '@fuf-stack/veto';
2
+ import { VetoInstance, VetoFormattedError } from '@fuf-stack/veto';
3
+ import * as React from 'react';
4
+ import { D as DebugModeSettings } from '../../FormContext-LRho0tno.js';
5
+ import * as react_hook_form from 'react-hook-form';
6
+ import { FieldValues, Path, FieldError } from 'react-hook-form';
7
+
8
+ /** Schema check whether a field is required or optional */
9
+ declare const checkFieldIsRequired: (validation: VetoInstance, path: string[]) => boolean;
10
+ /**
11
+ * Custom hook that extends react-hook-form's useFormContext to add validation and state management.
12
+ */
13
+ declare const useFormContext: <TFieldValues extends FieldValues = FieldValues, TContext = any, TTransformedValues = TFieldValues>() => {
14
+ formState: react_hook_form.FormState<TFieldValues>;
15
+ getFieldState: (name: Path<TFieldValues>, testId?: string) => {
16
+ error: FieldError[] | undefined;
17
+ invalid: boolean;
18
+ required: boolean;
19
+ testId: string;
20
+ isDirty: boolean;
21
+ isTouched: boolean;
22
+ isValidating: boolean;
23
+ };
24
+ getValues: react_hook_form.UseFormGetValues<TFieldValues>;
25
+ subscribe: react_hook_form.UseFromSubscribe<TFieldValues>;
26
+ watch: react_hook_form.UseFormWatch<TFieldValues>;
27
+ debugMode: "debug" | "debug-testids" | "off" | "disabled";
28
+ debugModeSettings?: DebugModeSettings;
29
+ preventSubmit: (prevent: boolean) => void;
30
+ setDebugMode: (debugMode: "debug" | "debug-testids" | "off" | "disabled") => void;
31
+ triggerSubmit: (e?: React.BaseSyntheticEvent) => Promise<void> | void;
32
+ validation: {
33
+ instance?: VetoInstance;
34
+ errors?: VetoFormattedError;
35
+ setClientValidationSchema: (key: string, schema: _fuf_stack_veto.VetoTypeAny | null) => void;
36
+ };
37
+ setError: react_hook_form.UseFormSetError<TFieldValues>;
38
+ clearErrors: react_hook_form.UseFormClearErrors<TFieldValues>;
39
+ setValue: react_hook_form.UseFormSetValue<TFieldValues>;
40
+ trigger: react_hook_form.UseFormTrigger<TFieldValues>;
41
+ resetField: react_hook_form.UseFormResetField<TFieldValues>;
42
+ reset: react_hook_form.UseFormReset<TFieldValues>;
43
+ handleSubmit: react_hook_form.UseFormHandleSubmit<TFieldValues, TTransformedValues>;
44
+ unregister: react_hook_form.UseFormUnregister<TFieldValues>;
45
+ control: react_hook_form.Control<TFieldValues, TContext, TTransformedValues>;
46
+ register: react_hook_form.UseFormRegister<TFieldValues>;
47
+ setFocus: react_hook_form.UseFormSetFocus<TFieldValues>;
48
+ };
49
+
50
+ export { checkFieldIsRequired, useFormContext };
@@ -0,0 +1,11 @@
1
+ import {
2
+ checkFieldIsRequired,
3
+ useFormContext
4
+ } from "../../chunk-PO5UQAU6.js";
5
+ import "../../chunk-76KOVUDN.js";
6
+ import "../../chunk-K2V4ULA2.js";
7
+ export {
8
+ checkFieldIsRequired,
9
+ useFormContext
10
+ };
11
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
@@ -0,0 +1,8 @@
1
+ "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
+
3
+ var _chunkPCTYJUY7cjs = require('../../chunk-PCTYJUY7.cjs');
4
+ require('../../chunk-555JRYCS.cjs');
5
+
6
+
7
+ exports.useInput = _chunkPCTYJUY7cjs.useInput;
8
+ //# sourceMappingURL=index.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["/home/runner/work/pixels/pixels/packages/uniform/dist/hooks/useInput/index.cjs"],"names":[],"mappings":"AAAA;AACE;AACF,4DAAiC;AACjC,oCAAiC;AACjC;AACE;AACF,8CAAC","file":"/home/runner/work/pixels/pixels/packages/uniform/dist/hooks/useInput/index.cjs"}
@@ -0,0 +1 @@
1
+ export { useInput } from '@heroui/input';
@@ -0,0 +1 @@
1
+ export { useInput } from '@heroui/input';
@@ -0,0 +1,8 @@
1
+ import {
2
+ useInput
3
+ } from "../../chunk-AHJJIANM.js";
4
+ import "../../chunk-K2V4ULA2.js";
5
+ export {
6
+ useInput
7
+ };
8
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
@@ -0,0 +1,14 @@
1
+ "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
+
3
+ var _chunkTGJJZEHBcjs = require('../../chunk-TGJJZEHB.cjs');
4
+ require('../../chunk-NHEZXA4H.cjs');
5
+ require('../../chunk-JMFDNTVC.cjs');
6
+ require('../../chunk-PCTYJUY7.cjs');
7
+ require('../../chunk-OE5BOGGX.cjs');
8
+ require('../../chunk-NZBO4N3S.cjs');
9
+ require('../../chunk-Z353BLWI.cjs');
10
+ require('../../chunk-555JRYCS.cjs');
11
+
12
+
13
+ exports.useUniformField = _chunkTGJJZEHBcjs.useUniformField;
14
+ //# sourceMappingURL=index.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["/home/runner/work/pixels/pixels/packages/uniform/dist/hooks/useUniformField/index.cjs"],"names":[],"mappings":"AAAA;AACE;AACF,4DAAiC;AACjC,oCAAiC;AACjC,oCAAiC;AACjC,oCAAiC;AACjC,oCAAiC;AACjC,oCAAiC;AACjC,oCAAiC;AACjC,oCAAiC;AACjC;AACE;AACF,4DAAC","file":"/home/runner/work/pixels/pixels/packages/uniform/dist/hooks/useUniformField/index.cjs"}
@@ -0,0 +1,83 @@
1
+ import { ReactNode } from 'react';
2
+ import { FieldValues, Path, FieldError } from 'react-hook-form';
3
+ import { useController } from '../useController/index.cjs';
4
+ import { useFormContext } from '../useFormContext/index.cjs';
5
+ import { useInput } from '@heroui/input';
6
+ import '@fuf-stack/veto';
7
+ import '../../FormContext-LRho0tno.cjs';
8
+
9
+ interface UseUniformFieldParams<TFieldValues extends FieldValues = FieldValues> {
10
+ /** Form field name */
11
+ name: Path<TFieldValues> & string;
12
+ /** Disable the field */
13
+ disabled?: boolean;
14
+ /** Optional explicit test id used to build stable test ids */
15
+ testId?: string;
16
+ /** Optional label content; pass false to suppress label entirely */
17
+ label?: ReactNode | false;
18
+ }
19
+ interface UseUniformFieldReturn<TFieldValues extends FieldValues = FieldValues> {
20
+ /** react-hook-form control instance for advanced integrations */
21
+ control: ReturnType<typeof useFormContext<TFieldValues>>['control'];
22
+ /** Debug mode from Uniform provider */
23
+ debugMode: ReturnType<typeof useFormContext<TFieldValues>>['debugMode'];
24
+ /** Current value used to initialize uncontrolled components */
25
+ defaultValue: unknown;
26
+ /** Whether the field is currently disabled (from RHF) */
27
+ disabled: boolean | undefined;
28
+ /** Validation error(s) for the field */
29
+ error: FieldError[] | undefined;
30
+ /** Pre-built errorMessage node to plug into components */
31
+ errorMessage: ReactNode | null;
32
+ /** RHF controller field with nullish conversions applied */
33
+ field: ReturnType<typeof useController<TFieldValues>>['field'];
34
+ /** Helper to spread standardized error message props to underlying components */
35
+ getErrorMessageProps: ReturnType<typeof useInput>['getErrorMessageProps'];
36
+ /** Helper to spread standardized helper wrapper props (for spacing/animation) */
37
+ getHelperWrapperProps: ReturnType<typeof useInput>['getHelperWrapperProps'];
38
+ /** Helper to spread standardized label props to underlying components */
39
+ getLabelProps: ReturnType<typeof useInput>['getLabelProps'];
40
+ /** Access current form values (converted to validation-friendly format) */
41
+ getValues: ReturnType<typeof useFormContext<TFieldValues>>['getValues'];
42
+ /** Whether the field should show invalid state (debounced for smooth animations). True when field is invalid AND (dirty OR touched OR submitted) */
43
+ invalid: boolean;
44
+ /** Computed label node including optional test id copy button */
45
+ label: ReactNode | null;
46
+ /** onBlur handler from controller */
47
+ onBlur: ReturnType<typeof useController<TFieldValues>>['field']['onBlur'];
48
+ /** onChange handler from controller (with nullish handling) */
49
+ onChange: ReturnType<typeof useController<TFieldValues>>['field']['onChange'];
50
+ /** Ref to forward to underlying control */
51
+ ref: ReturnType<typeof useController<TFieldValues>>['field']['ref'];
52
+ /** Whether the field is required according to validation schema */
53
+ required: boolean;
54
+ /** Reset a specific field in the form */
55
+ resetField: ReturnType<typeof useFormContext<TFieldValues>>['resetField'];
56
+ /** Generated HTML data-testid for the field */
57
+ testId: string;
58
+ }
59
+ /**
60
+ * Combines frequently used form field logic into a single hook.
61
+ *
62
+ * Provides:
63
+ * - Enhanced form context (validation-aware state, `testId`, value transforms)
64
+ * - Controller field with nullish conversion handling
65
+ * - Debounced `invalid` state with smart timing:
66
+ * • `true` (field becomes invalid): applies immediately so errors show right away
67
+ * • `false` (field becomes valid): delayed 200ms to allow smooth exit animations
68
+ * • Respects `prefers-reduced-motion` by skipping delays when user prefers reduced motion
69
+ * - Smart `invalid` visibility (via `showInvalid`):
70
+ * • Shows errors when field is dirty OR touched OR form has been submitted
71
+ * • Prevents showing errors on pristine/untouched fields for better UX
72
+ * • Works well for all field types (text inputs, checkboxes, radios, arrays)
73
+ * - Prebuilt `errorMessage` React node using `FieldValidationError`
74
+ * - Computed `label` node which appends a `FieldCopyTestIdButton` in
75
+ * `debug-testids` mode
76
+ * - `defaultValue` for uncontrolled defaults and all usual field handlers
77
+ * - Access to form utilities: `control`, `getValues`, `resetField`
78
+ * - Presentation helpers: `getLabelProps`, `getErrorMessageProps`,
79
+ * `getHelperWrapperProps` for consistent wiring to underlying UI components
80
+ */
81
+ declare function useUniformField<TFieldValues extends FieldValues = FieldValues>(params: UseUniformFieldParams<TFieldValues>): UseUniformFieldReturn<TFieldValues>;
82
+
83
+ export { type UseUniformFieldParams, type UseUniformFieldReturn, useUniformField };
@@ -0,0 +1,83 @@
1
+ import { ReactNode } from 'react';
2
+ import { FieldValues, Path, FieldError } from 'react-hook-form';
3
+ import { useController } from '../useController/index.js';
4
+ import { useFormContext } from '../useFormContext/index.js';
5
+ import { useInput } from '@heroui/input';
6
+ import '@fuf-stack/veto';
7
+ import '../../FormContext-LRho0tno.js';
8
+
9
+ interface UseUniformFieldParams<TFieldValues extends FieldValues = FieldValues> {
10
+ /** Form field name */
11
+ name: Path<TFieldValues> & string;
12
+ /** Disable the field */
13
+ disabled?: boolean;
14
+ /** Optional explicit test id used to build stable test ids */
15
+ testId?: string;
16
+ /** Optional label content; pass false to suppress label entirely */
17
+ label?: ReactNode | false;
18
+ }
19
+ interface UseUniformFieldReturn<TFieldValues extends FieldValues = FieldValues> {
20
+ /** react-hook-form control instance for advanced integrations */
21
+ control: ReturnType<typeof useFormContext<TFieldValues>>['control'];
22
+ /** Debug mode from Uniform provider */
23
+ debugMode: ReturnType<typeof useFormContext<TFieldValues>>['debugMode'];
24
+ /** Current value used to initialize uncontrolled components */
25
+ defaultValue: unknown;
26
+ /** Whether the field is currently disabled (from RHF) */
27
+ disabled: boolean | undefined;
28
+ /** Validation error(s) for the field */
29
+ error: FieldError[] | undefined;
30
+ /** Pre-built errorMessage node to plug into components */
31
+ errorMessage: ReactNode | null;
32
+ /** RHF controller field with nullish conversions applied */
33
+ field: ReturnType<typeof useController<TFieldValues>>['field'];
34
+ /** Helper to spread standardized error message props to underlying components */
35
+ getErrorMessageProps: ReturnType<typeof useInput>['getErrorMessageProps'];
36
+ /** Helper to spread standardized helper wrapper props (for spacing/animation) */
37
+ getHelperWrapperProps: ReturnType<typeof useInput>['getHelperWrapperProps'];
38
+ /** Helper to spread standardized label props to underlying components */
39
+ getLabelProps: ReturnType<typeof useInput>['getLabelProps'];
40
+ /** Access current form values (converted to validation-friendly format) */
41
+ getValues: ReturnType<typeof useFormContext<TFieldValues>>['getValues'];
42
+ /** Whether the field should show invalid state (debounced for smooth animations). True when field is invalid AND (dirty OR touched OR submitted) */
43
+ invalid: boolean;
44
+ /** Computed label node including optional test id copy button */
45
+ label: ReactNode | null;
46
+ /** onBlur handler from controller */
47
+ onBlur: ReturnType<typeof useController<TFieldValues>>['field']['onBlur'];
48
+ /** onChange handler from controller (with nullish handling) */
49
+ onChange: ReturnType<typeof useController<TFieldValues>>['field']['onChange'];
50
+ /** Ref to forward to underlying control */
51
+ ref: ReturnType<typeof useController<TFieldValues>>['field']['ref'];
52
+ /** Whether the field is required according to validation schema */
53
+ required: boolean;
54
+ /** Reset a specific field in the form */
55
+ resetField: ReturnType<typeof useFormContext<TFieldValues>>['resetField'];
56
+ /** Generated HTML data-testid for the field */
57
+ testId: string;
58
+ }
59
+ /**
60
+ * Combines frequently used form field logic into a single hook.
61
+ *
62
+ * Provides:
63
+ * - Enhanced form context (validation-aware state, `testId`, value transforms)
64
+ * - Controller field with nullish conversion handling
65
+ * - Debounced `invalid` state with smart timing:
66
+ * • `true` (field becomes invalid): applies immediately so errors show right away
67
+ * • `false` (field becomes valid): delayed 200ms to allow smooth exit animations
68
+ * • Respects `prefers-reduced-motion` by skipping delays when user prefers reduced motion
69
+ * - Smart `invalid` visibility (via `showInvalid`):
70
+ * • Shows errors when field is dirty OR touched OR form has been submitted
71
+ * • Prevents showing errors on pristine/untouched fields for better UX
72
+ * • Works well for all field types (text inputs, checkboxes, radios, arrays)
73
+ * - Prebuilt `errorMessage` React node using `FieldValidationError`
74
+ * - Computed `label` node which appends a `FieldCopyTestIdButton` in
75
+ * `debug-testids` mode
76
+ * - `defaultValue` for uncontrolled defaults and all usual field handlers
77
+ * - Access to form utilities: `control`, `getValues`, `resetField`
78
+ * - Presentation helpers: `getLabelProps`, `getErrorMessageProps`,
79
+ * `getHelperWrapperProps` for consistent wiring to underlying UI components
80
+ */
81
+ declare function useUniformField<TFieldValues extends FieldValues = FieldValues>(params: UseUniformFieldParams<TFieldValues>): UseUniformFieldReturn<TFieldValues>;
82
+
83
+ export { type UseUniformFieldParams, type UseUniformFieldReturn, useUniformField };
@@ -0,0 +1,14 @@
1
+ import {
2
+ useUniformField
3
+ } from "../../chunk-D3NAUOYG.js";
4
+ import "../../chunk-ELYGQTXB.js";
5
+ import "../../chunk-CK362NWK.js";
6
+ import "../../chunk-AHJJIANM.js";
7
+ import "../../chunk-NTDKZW4E.js";
8
+ import "../../chunk-PO5UQAU6.js";
9
+ import "../../chunk-76KOVUDN.js";
10
+ import "../../chunk-K2V4ULA2.js";
11
+ export {
12
+ useUniformField
13
+ };
14
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
@@ -0,0 +1,15 @@
1
+ "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
+
3
+ var _chunkAACO4OEKcjs = require('../../chunk-AACO4OEK.cjs');
4
+ require('../../chunk-TGJJZEHB.cjs');
5
+ require('../../chunk-NHEZXA4H.cjs');
6
+ require('../../chunk-JMFDNTVC.cjs');
7
+ require('../../chunk-PCTYJUY7.cjs');
8
+ require('../../chunk-OE5BOGGX.cjs');
9
+ require('../../chunk-NZBO4N3S.cjs');
10
+ require('../../chunk-Z353BLWI.cjs');
11
+ require('../../chunk-555JRYCS.cjs');
12
+
13
+
14
+ exports.useUniformFieldArray = _chunkAACO4OEKcjs.useUniformFieldArray;
15
+ //# sourceMappingURL=index.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["/home/runner/work/pixels/pixels/packages/uniform/dist/hooks/useUniformFieldArray/index.cjs"],"names":[],"mappings":"AAAA;AACE;AACF,4DAAiC;AACjC,oCAAiC;AACjC,oCAAiC;AACjC,oCAAiC;AACjC,oCAAiC;AACjC,oCAAiC;AACjC,oCAAiC;AACjC,oCAAiC;AACjC,oCAAiC;AACjC;AACE;AACF,sEAAC","file":"/home/runner/work/pixels/pixels/packages/uniform/dist/hooks/useUniformFieldArray/index.cjs"}
@@ -0,0 +1,70 @@
1
+ import { useController } from '../useController/index.cjs';
2
+ import * as _heroui_input from '@heroui/input';
3
+ import * as react_hook_form from 'react-hook-form';
4
+ import { FieldValues, ArrayPath } from 'react-hook-form';
5
+ import { ReactNode } from 'react';
6
+ import { useFormContext } from '../useFormContext/index.cjs';
7
+ import '@fuf-stack/veto';
8
+ import '../../FormContext-LRho0tno.cjs';
9
+
10
+ interface UseUniformFieldArrayProps<TFieldValues extends FieldValues = FieldValues> {
11
+ /** Field name for the array */
12
+ name: ArrayPath<TFieldValues>;
13
+ /** Whether this is a flat array (array of primitives) */
14
+ flat?: boolean;
15
+ /** Initial value for new array elements */
16
+ elementInitialValue?: unknown;
17
+ /** Whether the last element cannot be removed (always maintain at least one element) */
18
+ lastElementNotRemovable?: boolean;
19
+ /** Disable the field */
20
+ disabled?: boolean;
21
+ /** Optional explicit test id used to build stable test ids */
22
+ testId?: string;
23
+ /** Optional label content; pass false to suppress label entirely */
24
+ label?: ReactNode | false;
25
+ }
26
+ /**
27
+ * Enhanced useFieldArray hook with initialization and animation logic.
28
+ * Based on React Hook Form's useFieldArray with additional features:
29
+ * - Automatic initialization when lastElementNotRemovable is set
30
+ * - Animation control (disabled during initialization)
31
+ * - Support for flat arrays (arrays of primitives)
32
+ *
33
+ * Note: Automatic validation triggering on length change is disabled to prevent
34
+ * triggering form-wide validation. Array validation still runs on form submission.
35
+ *
36
+ * @see https://react-hook-form.com/docs/usefieldarray
37
+ */
38
+ declare const useUniformFieldArray: <TFieldValues extends FieldValues = FieldValues>({ name, flat, elementInitialValue: _elementInitialValue, lastElementNotRemovable, disabled, testId: explicitTestId, label, }: UseUniformFieldArrayProps<TFieldValues>) => {
39
+ control: react_hook_form.Control<TFieldValues, any, TFieldValues>;
40
+ debugMode: ReturnType<typeof useFormContext<TFieldValues_1>>["debugMode"];
41
+ defaultValue: unknown;
42
+ disabled: boolean | undefined;
43
+ error: react_hook_form.FieldError[] | undefined;
44
+ errorMessage: ReactNode | null;
45
+ field: Omit<react_hook_form.ControllerRenderProps<TFieldValues>, "value" | "onChange"> & {
46
+ onChange: (... /** Initial value for new array elements */event: any[]) => void;
47
+ value: string;
48
+ };
49
+ getErrorMessageProps: ReturnType<typeof _heroui_input.useInput>["getErrorMessageProps"];
50
+ getHelperWrapperProps: ReturnType<typeof _heroui_input.useInput>["getHelperWrapperProps"];
51
+ getLabelProps: ReturnType<typeof _heroui_input.useInput>["getLabelProps"];
52
+ getValues: react_hook_form.UseFormGetValues<TFieldValues>;
53
+ invalid: boolean;
54
+ label: ReactNode | null;
55
+ onBlur: ReturnType<typeof useController>["field"]["onBlur"];
56
+ onChange: ReturnType<typeof useController>["field"]["onChange"];
57
+ ref: ReturnType<typeof useController>["field"]["ref"];
58
+ required: boolean;
59
+ resetField: react_hook_form.UseFormResetField<TFieldValues>;
60
+ testId: string;
61
+ fields: react_hook_form.FieldArrayWithId<TFieldValues, ArrayPath<TFieldValues>, "id">[];
62
+ append: react_hook_form.UseFieldArrayAppend<TFieldValues, ArrayPath<TFieldValues>>;
63
+ remove: react_hook_form.UseFieldArrayRemove;
64
+ insert: react_hook_form.UseFieldArrayInsert<TFieldValues, ArrayPath<TFieldValues>>;
65
+ move: react_hook_form.UseFieldArrayMove;
66
+ disableAnimation: boolean;
67
+ elementInitialValue: {};
68
+ };
69
+
70
+ export { type UseUniformFieldArrayProps, useUniformFieldArray };
@@ -0,0 +1,70 @@
1
+ import { useController } from '../useController/index.js';
2
+ import * as _heroui_input from '@heroui/input';
3
+ import * as react_hook_form from 'react-hook-form';
4
+ import { FieldValues, ArrayPath } from 'react-hook-form';
5
+ import { ReactNode } from 'react';
6
+ import { useFormContext } from '../useFormContext/index.js';
7
+ import '@fuf-stack/veto';
8
+ import '../../FormContext-LRho0tno.js';
9
+
10
+ interface UseUniformFieldArrayProps<TFieldValues extends FieldValues = FieldValues> {
11
+ /** Field name for the array */
12
+ name: ArrayPath<TFieldValues>;
13
+ /** Whether this is a flat array (array of primitives) */
14
+ flat?: boolean;
15
+ /** Initial value for new array elements */
16
+ elementInitialValue?: unknown;
17
+ /** Whether the last element cannot be removed (always maintain at least one element) */
18
+ lastElementNotRemovable?: boolean;
19
+ /** Disable the field */
20
+ disabled?: boolean;
21
+ /** Optional explicit test id used to build stable test ids */
22
+ testId?: string;
23
+ /** Optional label content; pass false to suppress label entirely */
24
+ label?: ReactNode | false;
25
+ }
26
+ /**
27
+ * Enhanced useFieldArray hook with initialization and animation logic.
28
+ * Based on React Hook Form's useFieldArray with additional features:
29
+ * - Automatic initialization when lastElementNotRemovable is set
30
+ * - Animation control (disabled during initialization)
31
+ * - Support for flat arrays (arrays of primitives)
32
+ *
33
+ * Note: Automatic validation triggering on length change is disabled to prevent
34
+ * triggering form-wide validation. Array validation still runs on form submission.
35
+ *
36
+ * @see https://react-hook-form.com/docs/usefieldarray
37
+ */
38
+ declare const useUniformFieldArray: <TFieldValues extends FieldValues = FieldValues>({ name, flat, elementInitialValue: _elementInitialValue, lastElementNotRemovable, disabled, testId: explicitTestId, label, }: UseUniformFieldArrayProps<TFieldValues>) => {
39
+ control: react_hook_form.Control<TFieldValues, any, TFieldValues>;
40
+ debugMode: ReturnType<typeof useFormContext<TFieldValues_1>>["debugMode"];
41
+ defaultValue: unknown;
42
+ disabled: boolean | undefined;
43
+ error: react_hook_form.FieldError[] | undefined;
44
+ errorMessage: ReactNode | null;
45
+ field: Omit<react_hook_form.ControllerRenderProps<TFieldValues>, "value" | "onChange"> & {
46
+ onChange: (... /** Initial value for new array elements */event: any[]) => void;
47
+ value: string;
48
+ };
49
+ getErrorMessageProps: ReturnType<typeof _heroui_input.useInput>["getErrorMessageProps"];
50
+ getHelperWrapperProps: ReturnType<typeof _heroui_input.useInput>["getHelperWrapperProps"];
51
+ getLabelProps: ReturnType<typeof _heroui_input.useInput>["getLabelProps"];
52
+ getValues: react_hook_form.UseFormGetValues<TFieldValues>;
53
+ invalid: boolean;
54
+ label: ReactNode | null;
55
+ onBlur: ReturnType<typeof useController>["field"]["onBlur"];
56
+ onChange: ReturnType<typeof useController>["field"]["onChange"];
57
+ ref: ReturnType<typeof useController>["field"]["ref"];
58
+ required: boolean;
59
+ resetField: react_hook_form.UseFormResetField<TFieldValues>;
60
+ testId: string;
61
+ fields: react_hook_form.FieldArrayWithId<TFieldValues, ArrayPath<TFieldValues>, "id">[];
62
+ append: react_hook_form.UseFieldArrayAppend<TFieldValues, ArrayPath<TFieldValues>>;
63
+ remove: react_hook_form.UseFieldArrayRemove;
64
+ insert: react_hook_form.UseFieldArrayInsert<TFieldValues, ArrayPath<TFieldValues>>;
65
+ move: react_hook_form.UseFieldArrayMove;
66
+ disableAnimation: boolean;
67
+ elementInitialValue: {};
68
+ };
69
+
70
+ export { type UseUniformFieldArrayProps, useUniformFieldArray };
@@ -0,0 +1,15 @@
1
+ import {
2
+ useUniformFieldArray
3
+ } from "../../chunk-Z7FVILDT.js";
4
+ import "../../chunk-D3NAUOYG.js";
5
+ import "../../chunk-ELYGQTXB.js";
6
+ import "../../chunk-CK362NWK.js";
7
+ import "../../chunk-AHJJIANM.js";
8
+ import "../../chunk-NTDKZW4E.js";
9
+ import "../../chunk-PO5UQAU6.js";
10
+ import "../../chunk-76KOVUDN.js";
11
+ import "../../chunk-K2V4ULA2.js";
12
+ export {
13
+ useUniformFieldArray
14
+ };
15
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
package/dist/index.cjs CHANGED
@@ -1,67 +1,79 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
2
 
3
- var _chunkEALQ3KNWcjs = require('./chunk-EALQ3KNW.cjs');
3
+ var _chunkE4DCVJS5cjs = require('./chunk-E4DCVJS5.cjs');
4
4
 
5
5
 
6
- var _chunkMLAU2DYUcjs = require('./chunk-MLAU2DYU.cjs');
6
+ var _chunkA5Z75X7Mcjs = require('./chunk-A5Z75X7M.cjs');
7
7
 
8
8
 
9
- var _chunkP7Z25LOZcjs = require('./chunk-P7Z25LOZ.cjs');
9
+ var _chunkOJHD2XHDcjs = require('./chunk-OJHD2XHD.cjs');
10
10
 
11
11
 
12
- var _chunk4XTUP7W7cjs = require('./chunk-4XTUP7W7.cjs');
12
+ var _chunkXJBGXFVXcjs = require('./chunk-XJBGXFVX.cjs');
13
13
 
14
14
 
15
- var _chunkUO52HWMCcjs = require('./chunk-UO52HWMC.cjs');
15
+ var _chunkNZIAIYPScjs = require('./chunk-NZIAIYPS.cjs');
16
16
 
17
17
 
18
- var _chunkA5MP4JAGcjs = require('./chunk-A5MP4JAG.cjs');
18
+ var _chunkRMCPVDACcjs = require('./chunk-RMCPVDAC.cjs');
19
19
 
20
20
 
21
- var _chunkCSTA3NEDcjs = require('./chunk-CSTA3NED.cjs');
21
+ var _chunkIYULWK4Hcjs = require('./chunk-IYULWK4H.cjs');
22
22
 
23
23
 
24
- var _chunkJABO2635cjs = require('./chunk-JABO2635.cjs');
24
+ var _chunkWFO4XPA3cjs = require('./chunk-WFO4XPA3.cjs');
25
25
 
26
26
 
27
27
  var _chunkTTD3KL6Ecjs = require('./chunk-TTD3KL6E.cjs');
28
28
 
29
29
 
30
- var _chunkGE2QRIOEcjs = require('./chunk-GE2QRIOE.cjs');
30
+ var _chunkF6JQYB53cjs = require('./chunk-F6JQYB53.cjs');
31
31
 
32
32
 
33
- var _chunkX5WF3MEZcjs = require('./chunk-X5WF3MEZ.cjs');
33
+ var _chunkVPUMTPD3cjs = require('./chunk-VPUMTPD3.cjs');
34
34
 
35
35
 
36
- var _chunkKORRVEJLcjs = require('./chunk-KORRVEJL.cjs');
36
+ var _chunk345LYO4Hcjs = require('./chunk-345LYO4H.cjs');
37
+ require('./chunk-LTKRK3OS.cjs');
37
38
 
38
39
 
40
+ var _chunkBZ5OMN4Ycjs = require('./chunk-BZ5OMN4Y.cjs');
41
+
42
+
43
+ var _chunk4WYC2RBEcjs = require('./chunk-4WYC2RBE.cjs');
39
44
 
40
45
 
46
+ var _chunkAACO4OEKcjs = require('./chunk-AACO4OEK.cjs');
41
47
 
42
48
 
49
+ var _chunkTGJJZEHBcjs = require('./chunk-TGJJZEHB.cjs');
50
+
51
+
52
+ var _chunkNHEZXA4Hcjs = require('./chunk-NHEZXA4H.cjs');
53
+
43
54
 
55
+ var _chunkJMFDNTVCcjs = require('./chunk-JMFDNTVC.cjs');
44
56
 
45
- var _chunk3UIFEC4Rcjs = require('./chunk-3UIFEC4R.cjs');
57
+
58
+ var _chunkPCTYJUY7cjs = require('./chunk-PCTYJUY7.cjs');
46
59
 
47
60
 
48
61
  var _chunkOE5BOGGXcjs = require('./chunk-OE5BOGGX.cjs');
49
62
 
50
63
 
51
- var _chunkNHEZXA4Hcjs = require('./chunk-NHEZXA4H.cjs');
52
64
 
65
+ var _chunkTEIXBRF5cjs = require('./chunk-TEIXBRF5.cjs');
53
66
 
54
67
 
55
68
 
69
+ var _chunkNZBO4N3Scjs = require('./chunk-NZBO4N3S.cjs');
56
70
 
57
71
 
58
- var _chunkZ353BLWIcjs = require('./chunk-Z353BLWI.cjs');
59
72
 
60
73
 
61
- var _chunkBZ5OMN4Ycjs = require('./chunk-BZ5OMN4Y.cjs');
62
74
 
63
75
 
64
- var _chunk4WYC2RBEcjs = require('./chunk-4WYC2RBE.cjs');
76
+ var _chunkZ353BLWIcjs = require('./chunk-Z353BLWI.cjs');
65
77
  require('./chunk-555JRYCS.cjs');
66
78
 
67
79
 
@@ -92,5 +104,6 @@ require('./chunk-555JRYCS.cjs');
92
104
 
93
105
 
94
106
 
95
- exports.Checkboxes = _chunkA5MP4JAGcjs.Checkboxes_default; exports.FieldArray = _chunkCSTA3NEDcjs.FieldArray_default; exports.FieldCopyTestIdButton = _chunkOE5BOGGXcjs.FieldCopyTestIdButton_default; exports.FieldValidationError = _chunkNHEZXA4Hcjs.FieldValidationError_default; exports.Form = _chunkJABO2635cjs.Form_default; exports.Grid = _chunkTTD3KL6Ecjs.Grid_default; exports.Input = _chunkGE2QRIOEcjs.Input_default; exports.RadioBoxes = _chunkX5WF3MEZcjs.RadioBoxes_default; exports.RadioTabs = _chunkKORRVEJLcjs.RadioTabs_default; exports.Radios = _chunkEALQ3KNWcjs.Radios_default; exports.Select = _chunkMLAU2DYUcjs.Select_default; exports.SubmitButton = _chunkP7Z25LOZcjs.SubmitButton_default; exports.Switch = _chunk4XTUP7W7cjs.Switch_default; exports.TextArea = _chunkUO52HWMCcjs.TextArea_default; exports.checkFieldIsRequired = _chunk3UIFEC4Rcjs.checkFieldIsRequired; exports.flatArrayKey = _chunkZ353BLWIcjs.flatArrayKey; exports.fromNullishString = _chunkZ353BLWIcjs.fromNullishString; exports.toFormFormat = _chunkZ353BLWIcjs.toFormFormat; exports.toNullishString = _chunkZ353BLWIcjs.toNullishString; exports.toValidationFormat = _chunkZ353BLWIcjs.toValidationFormat; exports.useClientValidation = _chunk3UIFEC4Rcjs.useClientValidation; exports.useController = _chunk3UIFEC4Rcjs.useController; exports.useFormContext = _chunk3UIFEC4Rcjs.useFormContext; exports.useInput = _chunk3UIFEC4Rcjs.useInput; exports.useInputValueDebounce = _chunkBZ5OMN4Ycjs.useInputValueDebounce; exports.useInputValueTransform = _chunk4WYC2RBEcjs.useInputValueTransform; exports.useUniformField = _chunk3UIFEC4Rcjs.useUniformField; exports.useUniformFieldArray = _chunk3UIFEC4Rcjs.useUniformFieldArray;
107
+
108
+ exports.Checkboxes = _chunkRMCPVDACcjs.Checkboxes_default; exports.FieldArray = _chunkIYULWK4Hcjs.FieldArray_default; exports.FieldCopyTestIdButton = _chunkOE5BOGGXcjs.FieldCopyTestIdButton_default; exports.FieldValidationError = _chunkNHEZXA4Hcjs.FieldValidationError_default; exports.Form = _chunkWFO4XPA3cjs.Form_default; exports.Grid = _chunkTTD3KL6Ecjs.Grid_default; exports.Input = _chunkF6JQYB53cjs.Input_default; exports.RadioBoxes = _chunkVPUMTPD3cjs.RadioBoxes_default; exports.RadioTabs = _chunk345LYO4Hcjs.RadioTabs_default; exports.Radios = _chunkE4DCVJS5cjs.Radios_default; exports.Select = _chunkA5Z75X7Mcjs.Select_default; exports.SubmitButton = _chunkOJHD2XHDcjs.SubmitButton_default; exports.Switch = _chunkXJBGXFVXcjs.Switch_default; exports.TextArea = _chunkNZIAIYPScjs.TextArea_default; exports.checkFieldIsRequired = _chunkNZBO4N3Scjs.checkFieldIsRequired; exports.clientValidationSchemaByName = _chunkTEIXBRF5cjs.clientValidationSchemaByName; exports.flatArrayKey = _chunkZ353BLWIcjs.flatArrayKey; exports.fromNullishString = _chunkZ353BLWIcjs.fromNullishString; exports.toFormFormat = _chunkZ353BLWIcjs.toFormFormat; exports.toNullishString = _chunkZ353BLWIcjs.toNullishString; exports.toValidationFormat = _chunkZ353BLWIcjs.toValidationFormat; exports.useClientValidation = _chunkTEIXBRF5cjs.useClientValidation; exports.useController = _chunkJMFDNTVCcjs.useController; exports.useFormContext = _chunkNZBO4N3Scjs.useFormContext; exports.useInput = _chunkPCTYJUY7cjs.useInput; exports.useInputValueDebounce = _chunkBZ5OMN4Ycjs.useInputValueDebounce; exports.useInputValueTransform = _chunk4WYC2RBEcjs.useInputValueTransform; exports.useUniformField = _chunkTGJJZEHBcjs.useUniformField; exports.useUniformFieldArray = _chunkAACO4OEKcjs.useUniformFieldArray;
96
109
  //# sourceMappingURL=index.cjs.map
@@ -1 +1 @@
1
- {"version":3,"sources":["/home/runner/work/pixels/pixels/packages/uniform/dist/index.cjs"],"names":[],"mappings":"AAAA;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACA;AACA;AACA;AACA;AACA;AACA;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACA;AACA;AACA;AACA;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B,gCAA6B;AAC7B;AACE;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACF,6pDAAC","file":"/home/runner/work/pixels/pixels/packages/uniform/dist/index.cjs"}
1
+ {"version":3,"sources":["/home/runner/work/pixels/pixels/packages/uniform/dist/index.cjs"],"names":[],"mappings":"AAAA;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B,gCAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACA;AACF,wDAA6B;AAC7B;AACE;AACA;AACF,wDAA6B;AAC7B;AACE;AACA;AACA;AACA;AACA;AACF,wDAA6B;AAC7B,gCAA6B;AAC7B;AACE;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACF,ovDAAC","file":"/home/runner/work/pixels/pixels/packages/uniform/dist/index.cjs"}
package/dist/index.d.cts CHANGED
@@ -3,10 +3,14 @@ export { F as FieldArray, a as FieldArrayChildrenRenderFn, b as FieldArrayFeatur
3
3
  export { F as Form, a as FormProps } from './Form-Cu0lWRDN.cjs';
4
4
  export { G as Grid, a as GridProps } from './Grid-DF3L9NF3.cjs';
5
5
  export { flatArrayKey, fromNullishString, toFormFormat, toNullishString, toValidationFormat } from './helpers/index.cjs';
6
- export { UseControllerProps, UseControllerReturn, UseUniformFieldArrayProps, UseUniformFieldParams, UseUniformFieldReturn, checkFieldIsRequired, useClientValidation, useController, useFormContext, useUniformField, useUniformFieldArray } from './hooks/index.cjs';
6
+ export { clientValidationSchemaByName, useClientValidation } from './hooks/useClientValidation/index.cjs';
7
+ export { UseControllerProps, UseControllerReturn, useController } from './hooks/useController/index.cjs';
8
+ export { UseUniformFieldArrayProps, useUniformFieldArray } from './hooks/useUniformFieldArray/index.cjs';
9
+ export { checkFieldIsRequired, useFormContext } from './hooks/useFormContext/index.cjs';
7
10
  export { useInput } from '@heroui/input';
8
11
  export { UseInputValueDebounceOptions, UseInputValueDebounceReturn, useInputValueDebounce } from './hooks/useInputValueDebounce/index.cjs';
9
12
  export { InputValueTransform, UseInputValueTransformOptions, UseInputValueTransformReturn, useInputValueTransform } from './hooks/useInputValueTransform/index.cjs';
13
+ export { UseUniformFieldParams, UseUniformFieldReturn, useUniformField } from './hooks/useUniformField/index.cjs';
10
14
  export { I as Input, a as InputProps } from './Input-D7HT_8jf.cjs';
11
15
  export { F as FieldCopyTestIdButton, a as FieldCopyTestIdButtonProps } from './FieldCopyTestIdButton-_TDlmw0L.cjs';
12
16
  export { F as FieldValidationError, a as FieldValidationErrorProps } from './FieldValidationError-DwtLkGMo.cjs';
@@ -24,6 +28,7 @@ import 'react';
24
28
  import '@fuf-stack/veto';
25
29
  import 'react-hook-form';
26
30
  import './FormContext-LRho0tno.cjs';
31
+ import '@fuf-stack/veto/dist/types.d-CNPgNK-V';
27
32
  import '@fuf-stack/pixels';
28
33
  import 'react-select';
29
34
  import '@heroui/switch';