@saas-ui/forms 2.0.0-next.8 → 2.0.0-rc.22

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,37 +1,18 @@
1
- import * as _chakra_ui_checkbox_dist_checkbox from '@chakra-ui/checkbox/dist/checkbox';
2
- import * as _chakra_ui_switch_dist_switch from '@chakra-ui/switch/dist/switch';
3
- import * as _chakra_ui_textarea_dist_textarea from '@chakra-ui/textarea/dist/textarea';
1
+ import * as React$1 from 'react';
2
+ import React$1__default from 'react';
4
3
  import * as react_hook_form from 'react-hook-form';
5
- import { FieldValues, FieldPath, RegisterOptions, UseFormReturn, UseFormProps, WatchObserver, SubmitHandler, SubmitErrorHandler, UseFieldArrayReturn } from 'react-hook-form';
6
- import * as react from 'react';
7
- import react__default from 'react';
8
- import * as _chakra_ui_system_dist_system_types from '@chakra-ui/system/dist/system.types';
9
- import { ButtonProps, InputProps, RadioGroupProps, MenuProps, SelectProps as SelectProps$1, UsePinInputProps, SystemProps, FormControlProps, HTMLChakraProps, NumberInputProps as NumberInputProps$1, StackDirection, MenuItemOptionProps, ResponsiveValue, TextareaProps, SwitchProps, CheckboxProps, RadioProps } from '@chakra-ui/react';
4
+ import { FieldValues, FieldPath, UseFormProps, SubmitHandler, RegisterOptions, UseFormReturn, UseFieldArrayReturn, WatchObserver, SubmitErrorHandler } from 'react-hook-form';
10
5
  import { MaybeRenderProp } from '@chakra-ui/react-utils';
6
+ import { UseStepperProps, UseStepperReturn } from '@saas-ui/core';
7
+ import { HTMLChakraProps, TextareaProps, SwitchProps, CheckboxProps, FormControlProps, ResponsiveValue, InputProps, RadioGroupProps, MenuProps, SelectProps as SelectProps$1, UsePinInputProps, SystemProps, NumberInputProps as NumberInputProps$1, StackDirection, MenuItemOptionProps, ButtonProps, RadioProps } from '@chakra-ui/react';
8
+ import { FocusableElement } from '@chakra-ui/utils';
9
+ import * as _chakra_ui_system_dist_system_types from '@chakra-ui/system/dist/system.types';
11
10
  import * as zod from 'zod';
12
11
  import { z } from 'zod';
13
- import * as _saas_ui_forms from '@saas-ui/forms';
14
- import { FieldProps as FieldProps$1, FormProps as FormProps$1, CreateFormProps } from '@saas-ui/forms';
12
+ import { FieldProps as FieldProps$1, WithFields, FormProps as FormProps$1, CreateFormProps } from '@saas-ui/forms';
15
13
  import { zodResolver } from '@hookform/resolvers/zod';
16
14
  export { zodResolver } from '@hookform/resolvers/zod';
17
15
 
18
- interface SubmitButtonProps extends ButtonProps {
19
- /**
20
- * Disable the submit button if the form is untouched.
21
- *
22
- * Change the default behavior by updating
23
- * `SubmitButton.defaultProps.disableIfUntouched`
24
- */
25
- disableIfUntouched?: boolean;
26
- /**
27
- * Disable the submit button if the form is invalid.
28
- *
29
- * Change the default behavior by updating
30
- * `SubmitButton.defaultProps.disableIfInvalid`
31
- */
32
- disableIfInvalid?: boolean;
33
- }
34
-
35
16
  interface NumberInputOptions {
36
17
  /**
37
18
  * Hide the stepper.
@@ -40,19 +21,19 @@ interface NumberInputOptions {
40
21
  /**
41
22
  * Render a custom increment icon.
42
23
  */
43
- incrementIcon?: react.ReactNode;
24
+ incrementIcon?: React$1.ReactNode;
44
25
  /**
45
26
  * Render a custom decrement icon.
46
27
  */
47
- decrementIcon?: react.ReactNode;
28
+ decrementIcon?: React$1.ReactNode;
48
29
  }
49
30
  interface NumberInputProps extends NumberInputProps$1, NumberInputOptions {
50
31
  }
51
32
 
52
33
  interface PasswordOptions {
53
- viewIcon?: react__default.ReactNode;
54
- viewOffIcon?: react__default.ReactNode;
55
- leftAddon?: react__default.ReactNode;
34
+ viewIcon?: React$1__default.ReactNode;
35
+ viewOffIcon?: React$1__default.ReactNode;
36
+ leftAddon?: React$1__default.ReactNode;
56
37
  }
57
38
  interface PasswordInputProps extends InputProps, PasswordOptions {
58
39
  }
@@ -108,7 +89,7 @@ interface SelectOptions {
108
89
  * @param value The value of the select field.
109
90
  * @returns The rendered value.
110
91
  */
111
- renderValue?: (value: string | string[]) => react__default.ReactNode;
92
+ renderValue?: (value: string | string[]) => React$1__default.ReactNode;
112
93
  }
113
94
 
114
95
  interface SelectProps extends Omit<MenuProps, 'children'>, SelectOptions {
@@ -134,8 +115,8 @@ interface NativeSelectProps extends SelectProps$1, NativeSelectOptions {
134
115
 
135
116
  interface InputFieldProps extends InputProps {
136
117
  type?: string;
137
- leftAddon?: react.ReactNode;
138
- rightAddon?: react.ReactNode;
118
+ leftAddon?: React$1.ReactNode;
119
+ rightAddon?: React$1.ReactNode;
139
120
  }
140
121
  interface NumberInputFieldProps extends NumberInputProps {
141
122
  type: 'number';
@@ -146,22 +127,39 @@ interface PinFieldProps extends Omit<UsePinInputProps, 'type'> {
146
127
  spacing?: SystemProps['margin'];
147
128
  }
148
129
  declare const defaultFieldTypes: {
149
- text: react.FC<InputFieldProps & BaseFieldProps<react_hook_form.FieldValues, string>>;
150
- email: react.FC<InputFieldProps & BaseFieldProps<react_hook_form.FieldValues, string>>;
151
- url: react.FC<InputFieldProps & BaseFieldProps<react_hook_form.FieldValues, string>>;
152
- phone: react.FC<InputFieldProps & BaseFieldProps<react_hook_form.FieldValues, string>>;
153
- number: react.FC<NumberInputFieldProps & BaseFieldProps<react_hook_form.FieldValues, string>>;
154
- password: react.FC<PasswordInputProps & BaseFieldProps<react_hook_form.FieldValues, string>>;
155
- textarea: react.FC<TextareaProps & BaseFieldProps<react_hook_form.FieldValues, string>>;
156
- switch: react.FC<SwitchProps & BaseFieldProps<react_hook_form.FieldValues, string>>;
157
- select: react.FC<SelectProps & BaseFieldProps<react_hook_form.FieldValues, string>>;
158
- checkbox: react.FC<CheckboxProps & BaseFieldProps<react_hook_form.FieldValues, string>>;
159
- radio: react.FC<RadioInputProps & BaseFieldProps<react_hook_form.FieldValues, string>>;
160
- pin: react.FC<PinFieldProps & BaseFieldProps<react_hook_form.FieldValues, string>>;
161
- 'native-select': react.FC<NativeSelectProps & BaseFieldProps<react_hook_form.FieldValues, string>>;
130
+ text: React$1.FC<InputFieldProps & BaseFieldProps<react_hook_form.FieldValues, string>>;
131
+ email: React$1.FC<InputFieldProps & BaseFieldProps<react_hook_form.FieldValues, string>>;
132
+ url: React$1.FC<InputFieldProps & BaseFieldProps<react_hook_form.FieldValues, string>>;
133
+ phone: React$1.FC<InputFieldProps & BaseFieldProps<react_hook_form.FieldValues, string>>;
134
+ number: React$1.FC<NumberInputFieldProps & BaseFieldProps<react_hook_form.FieldValues, string>>;
135
+ password: React$1.FC<PasswordInputProps & BaseFieldProps<react_hook_form.FieldValues, string>>;
136
+ textarea: React$1.FC<TextareaProps & BaseFieldProps<react_hook_form.FieldValues, string>>;
137
+ switch: React$1.FC<SwitchProps & BaseFieldProps<react_hook_form.FieldValues, string>>;
138
+ select: React$1.FC<SelectProps & BaseFieldProps<react_hook_form.FieldValues, string>>;
139
+ checkbox: React$1.FC<CheckboxProps & BaseFieldProps<react_hook_form.FieldValues, string>>;
140
+ radio: React$1.FC<RadioInputProps & BaseFieldProps<react_hook_form.FieldValues, string>>;
141
+ pin: React$1.FC<PinFieldProps & BaseFieldProps<react_hook_form.FieldValues, string>>;
142
+ 'native-select': React$1.FC<NativeSelectProps & BaseFieldProps<react_hook_form.FieldValues, string>>;
162
143
  };
163
144
  type DefaultFields = typeof defaultFieldTypes;
164
145
 
146
+ interface SubmitButtonProps extends ButtonProps {
147
+ /**
148
+ * Disable the submit button if the form is untouched.
149
+ *
150
+ * Change the default behavior by updating
151
+ * `SubmitButton.defaultProps.disableIfUntouched`
152
+ */
153
+ disableIfUntouched?: boolean;
154
+ /**
155
+ * Disable the submit button if the form is invalid.
156
+ *
157
+ * Change the default behavior by updating
158
+ * `SubmitButton.defaultProps.disableIfInvalid`
159
+ */
160
+ disableIfInvalid?: boolean;
161
+ }
162
+
165
163
  type FieldOption = {
166
164
  label?: string;
167
165
  value: string;
@@ -223,7 +221,7 @@ type FieldResolver = {
223
221
  };
224
222
 
225
223
  interface DisplayIfProps<TFieldValues extends FieldValues = FieldValues, TName extends FieldPath<TFieldValues> = FieldPath<TFieldValues>> {
226
- children: react.ReactElement;
224
+ children: React$1.ReactElement;
227
225
  name: TName;
228
226
  defaultValue?: unknown;
229
227
  isDisabled?: boolean;
@@ -279,25 +277,25 @@ interface ArrayField {
279
277
  * @see Docs https://saas-ui.dev/docs/components/forms/array-field
280
278
  */
281
279
  declare const ArrayField: ((props: ArrayFieldProps & {
282
- ref?: react.ForwardedRef<UseArrayFieldReturn>;
283
- }) => react.ReactElement) & {
280
+ ref?: React$1.ForwardedRef<UseArrayFieldReturn>;
281
+ }) => React$1.ReactElement) & {
284
282
  displayName: string;
285
283
  };
286
284
 
287
285
  interface ObjectFieldProps<TFieldValues extends FieldValues = FieldValues, TName extends FieldPath<TFieldValues> = FieldPath<TFieldValues>> extends BaseFieldProps {
288
286
  name: TName;
289
- children: react.ReactNode;
287
+ children: React$1.ReactNode;
290
288
  columns?: ResponsiveValue<number>;
291
289
  spacing?: ResponsiveValue<string | number>;
292
290
  }
293
291
 
294
292
  interface FormRenderContext<TFieldValues extends FieldValues = FieldValues, TContext extends object = object, TFieldTypes = FieldProps<TFieldValues>> extends UseFormReturn<TFieldValues, TContext> {
295
- Field: react.FC<TFieldTypes>;
296
- DisplayIf: react.FC<DisplayIfProps<TFieldValues>>;
297
- ArrayField: react.FC<ArrayFieldProps<TFieldValues>>;
298
- ObjectField: react.FC<ObjectFieldProps<TFieldValues>>;
293
+ Field: React$1.FC<TFieldTypes & React$1.RefAttributes<FocusableElement>>;
294
+ DisplayIf: React$1.FC<DisplayIfProps<TFieldValues>>;
295
+ ArrayField: React$1.FC<ArrayFieldProps<TFieldValues> & React$1.RefAttributes<UseArrayFieldReturn>>;
296
+ ObjectField: React$1.FC<ObjectFieldProps<TFieldValues>>;
299
297
  }
300
- interface FormOptions<TFieldValues extends FieldValues = FieldValues, TContext extends object = object, TSchema = any, TFieldTypes = FieldProps<TFieldValues>> {
298
+ interface FormOptions<TSchema = unknown, TFieldValues extends FieldValues = FieldValues, TContext extends object = object, TFieldTypes = FieldProps<TFieldValues>> {
301
299
  /**
302
300
  * The form schema.
303
301
  */
@@ -317,7 +315,7 @@ interface FormOptions<TFieldValues extends FieldValues = FieldValues, TContext e
317
315
  /**
318
316
  * The Hook Form state ref.
319
317
  */
320
- formRef?: react.RefObject<UseFormReturn<TFieldValues, TContext>>;
318
+ formRef?: React$1.RefObject<UseFormReturn<TFieldValues, TContext>>;
321
319
  /**
322
320
  * The form children, can be a render prop or a ReactNode.
323
321
  */
@@ -331,7 +329,62 @@ interface FormOptions<TFieldValues extends FieldValues = FieldValues, TContext e
331
329
  */
332
330
  fields?: DefaultFieldOverrides;
333
331
  }
334
- interface FormProps<TFieldValues extends FieldValues = FieldValues, TContext extends object = object, TSchema = any, TFieldTypes = FieldProps<TFieldValues>> extends UseFormProps<TFieldValues, TContext>, Omit<HTMLChakraProps<'form'>, 'children' | 'onChange' | 'onSubmit' | 'onError'>, FormOptions<TFieldValues, TContext, TSchema, TFieldTypes> {
332
+ interface FormProps<TSchema = unknown, TFieldValues extends FieldValues = FieldValues, TContext extends object = object, TFieldTypes = FieldProps<TFieldValues>> extends UseFormProps<TFieldValues, TContext>, Omit<HTMLChakraProps<'form'>, 'children' | 'onChange' | 'onSubmit' | 'onError'>, FormOptions<TSchema, TFieldValues, TContext, TFieldTypes> {
333
+ }
334
+
335
+ type StepsOptions<TSchema, TName extends string = string> = {
336
+ /**
337
+ * The step name
338
+ */
339
+ name: TName;
340
+ /**
341
+ * Schema
342
+ */
343
+ schema?: TSchema;
344
+ }[];
345
+ interface FormStepOptions<TName extends string = string> {
346
+ /**
347
+ * The step name
348
+ */
349
+ name: TName;
350
+ /**
351
+ * Schema
352
+ */
353
+ schema?: any;
354
+ /**
355
+ * Hook Form Resolver
356
+ */
357
+ resolver?: any;
358
+ }
359
+ interface FormStepProps<TName extends string = string> extends FormStepOptions<TName>, Omit<HTMLChakraProps<'div'>, 'onSubmit'> {
360
+ onSubmit?: FormStepSubmitHandler;
361
+ }
362
+ type FormStepSubmitHandler<TFieldValues extends FieldValues = FieldValues> = (data: TFieldValues, stepper: UseStepperReturn) => Promise<void>;
363
+
364
+ type StepName<T extends {
365
+ [k: number]: {
366
+ readonly name: string;
367
+ };
368
+ }> = T[number]['name'];
369
+ interface StepFormRenderContext<TSteps extends StepsOptions<any> = StepsOptions<any>, TFieldValues extends FieldValues = FieldValues, TContext extends object = object, TFieldTypes = FieldProps<TFieldValues>> extends UseStepFormReturn<TFieldValues> {
370
+ Field: React$1.FC<TFieldTypes & React$1.RefAttributes<FocusableElement>>;
371
+ FormStep: React$1.FC<FormStepProps<StepName<TSteps>>>;
372
+ DisplayIf: React$1.FC<DisplayIfProps<TFieldValues>>;
373
+ ArrayField: React$1.FC<ArrayFieldProps<TFieldValues> & React$1.RefAttributes<UseArrayFieldReturn>>;
374
+ ObjectField: React$1.FC<ObjectFieldProps<TFieldValues>>;
375
+ }
376
+ interface UseStepFormProps<TSteps extends StepsOptions<any> = StepsOptions<any>, TFieldValues extends FieldValues = FieldValues, TContext extends object = object, TFieldTypes = FieldProps<TFieldValues>> extends Omit<UseStepperProps, 'onChange'>, Omit<FormProps<any, TFieldValues, TContext, TFieldTypes>, 'children'> {
377
+ steps?: TSteps;
378
+ children: MaybeRenderProp<StepFormRenderContext<TSteps, TFieldValues, TContext, TFieldTypes>>;
379
+ }
380
+ interface UseStepFormReturn<TFieldValues extends FieldValues = FieldValues> extends UseStepperReturn {
381
+ getFormProps(): {
382
+ onSubmit: SubmitHandler<TFieldValues>;
383
+ schema?: any;
384
+ resolver?: any;
385
+ };
386
+ updateStep(step: any): void;
387
+ steps: Record<string, any>;
335
388
  }
336
389
 
337
390
  type Options = {
@@ -347,8 +400,8 @@ type Options = {
347
400
  declare const getFieldsFromSchema: (schema: zod.ZodTypeAny) => FieldProps$1[];
348
401
  declare const getNestedSchema: (schema: zod.ZodTypeAny, path: string) => any;
349
402
  declare const zodFieldResolver: <T extends zod.ZodTypeAny>(schema: T) => {
350
- getFields(): FieldProps$1<_saas_ui_forms.FieldValues>[];
351
- getNestedFields(name: string): FieldProps$1<_saas_ui_forms.FieldValues>[];
403
+ getFields(): FieldProps$1[];
404
+ getNestedFields(name: string): FieldProps$1[];
352
405
  };
353
406
  interface ZodMeta {
354
407
  label: string;
@@ -362,246 +415,137 @@ interface CreateZodFormProps<FieldDefs> extends CreateFormProps<FieldDefs> {
362
415
  schemaOptions?: ResolverArgs[1];
363
416
  resolverOptions?: ResolverArgs[2];
364
417
  }
365
- declare const createZodForm: <FieldDefs>(options?: CreateZodFormProps<FieldDefs> | undefined) => <TSchema extends z.AnyZodObject = z.AnyZodObject, TContext extends object = object>(props: Omit<FormProps$1<z.TypeOf<TSchema>, TContext, TSchema, _saas_ui_forms.FieldProps<z.TypeOf<TSchema>>>, "children" | "fields"> & {
366
- children?: react.ReactNode | ((props: _saas_ui_forms.FormRenderContext<z.TypeOf<TSchema>, TContext, ((FieldDefs extends never ? {
367
- text: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
368
- email: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
369
- url: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
370
- phone: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
371
- number: react.FC<_saas_ui_forms.NumberInputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
372
- password: react.FC<_saas_ui_forms.PasswordInputProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
373
- textarea: react.FC<_chakra_ui_textarea_dist_textarea.TextareaProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
374
- switch: react.FC<_chakra_ui_switch_dist_switch.SwitchProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
375
- select: react.FC<_saas_ui_forms.SelectProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
376
- checkbox: react.FC<_chakra_ui_checkbox_dist_checkbox.CheckboxProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
377
- radio: react.FC<_saas_ui_forms.RadioInputProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
378
- pin: react.FC<_saas_ui_forms.PinFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
379
- 'native-select': react.FC<_saas_ui_forms.NativeSelectProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
380
- } : Omit<{
381
- text: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
382
- email: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
383
- url: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
384
- phone: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
385
- number: react.FC<_saas_ui_forms.NumberInputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
386
- password: react.FC<_saas_ui_forms.PasswordInputProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
387
- textarea: react.FC<_chakra_ui_textarea_dist_textarea.TextareaProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
388
- switch: react.FC<_chakra_ui_switch_dist_switch.SwitchProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
389
- select: react.FC<_saas_ui_forms.SelectProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
390
- checkbox: react.FC<_chakra_ui_checkbox_dist_checkbox.CheckboxProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
391
- radio: react.FC<_saas_ui_forms.RadioInputProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
392
- pin: react.FC<_saas_ui_forms.PinFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
393
- 'native-select': react.FC<_saas_ui_forms.NativeSelectProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
394
- }, keyof FieldDefs> & FieldDefs) extends infer T ? { [K in keyof T]: (FieldDefs extends never ? {
395
- text: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
396
- email: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
397
- url: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
398
- phone: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
399
- number: react.FC<_saas_ui_forms.NumberInputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
400
- password: react.FC<_saas_ui_forms.PasswordInputProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
401
- textarea: react.FC<_chakra_ui_textarea_dist_textarea.TextareaProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
402
- switch: react.FC<_chakra_ui_switch_dist_switch.SwitchProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
403
- select: react.FC<_saas_ui_forms.SelectProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
404
- checkbox: react.FC<_chakra_ui_checkbox_dist_checkbox.CheckboxProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
405
- radio: react.FC<_saas_ui_forms.RadioInputProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
406
- pin: react.FC<_saas_ui_forms.PinFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
407
- 'native-select': react.FC<_saas_ui_forms.NativeSelectProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
408
- } : Omit<{
409
- text: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
410
- email: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
411
- url: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
412
- phone: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
413
- number: react.FC<_saas_ui_forms.NumberInputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
414
- password: react.FC<_saas_ui_forms.PasswordInputProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
415
- textarea: react.FC<_chakra_ui_textarea_dist_textarea.TextareaProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
416
- switch: react.FC<_chakra_ui_switch_dist_switch.SwitchProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
417
- select: react.FC<_saas_ui_forms.SelectProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
418
- checkbox: react.FC<_chakra_ui_checkbox_dist_checkbox.CheckboxProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
419
- radio: react.FC<_saas_ui_forms.RadioInputProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
420
- pin: react.FC<_saas_ui_forms.PinFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
421
- 'native-select': react.FC<_saas_ui_forms.NativeSelectProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
422
- }, keyof FieldDefs> & FieldDefs)[K] extends react.FC<infer Props> ? {
423
- type?: K | undefined;
424
- } & Omit<Props, keyof _saas_ui_forms.BaseFieldProps<TFieldValues, TName>> & _saas_ui_forms.BaseFieldProps<z.TypeOf<TSchema>, react_hook_form.Path<z.TypeOf<TSchema>>> : never; } : never)[keyof (FieldDefs extends never ? {
425
- text: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
426
- email: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
427
- url: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
428
- phone: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
429
- number: react.FC<_saas_ui_forms.NumberInputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
430
- password: react.FC<_saas_ui_forms.PasswordInputProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
431
- textarea: react.FC<_chakra_ui_textarea_dist_textarea.TextareaProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
432
- switch: react.FC<_chakra_ui_switch_dist_switch.SwitchProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
433
- select: react.FC<_saas_ui_forms.SelectProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
434
- checkbox: react.FC<_chakra_ui_checkbox_dist_checkbox.CheckboxProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
435
- radio: react.FC<_saas_ui_forms.RadioInputProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
436
- pin: react.FC<_saas_ui_forms.PinFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
437
- 'native-select': react.FC<_saas_ui_forms.NativeSelectProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
438
- } : Omit<{
439
- text: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
440
- email: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
441
- url: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
442
- phone: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
443
- number: react.FC<_saas_ui_forms.NumberInputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
444
- password: react.FC<_saas_ui_forms.PasswordInputProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
445
- textarea: react.FC<_chakra_ui_textarea_dist_textarea.TextareaProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
446
- switch: react.FC<_chakra_ui_switch_dist_switch.SwitchProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
447
- select: react.FC<_saas_ui_forms.SelectProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
448
- checkbox: react.FC<_chakra_ui_checkbox_dist_checkbox.CheckboxProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
449
- radio: react.FC<_saas_ui_forms.RadioInputProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
450
- pin: react.FC<_saas_ui_forms.PinFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
451
- 'native-select': react.FC<_saas_ui_forms.NativeSelectProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
452
- }, keyof FieldDefs> & FieldDefs)]>) => react.ReactNode);
453
- fields?: ({ [K_1 in react_hook_form.Path<z.TypeOf<TSchema>> | (react_hook_form.Path<z.TypeOf<TSchema>> extends infer T_1 ? T_1 extends react_hook_form.Path<z.TypeOf<TSchema>> ? T_1 extends string ? (string extends T_1 ? (T_1 & string)[] : T_1 extends infer T_2 ? T_2 extends T_1 ? T_2 extends "" ? [] : T_2 extends `${infer T_3}.${infer U}` ? [T_3, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_3}.${infer U}` ? [T_3, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_3}.${infer U}` ? [T_3, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_3}.${infer U}` ? [T_3, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_3}.${infer U}` ? [T_3, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_3}.${infer U}` ? [T_3, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_3}.${infer U}` ? [T_3, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_3}.${infer U}` ? [T_3, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_3}.${infer U}` ? [T_3, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_3}.${infer U}` ? [T_3, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_3}.${infer U}` ? [T_3, ...any] : [U]] : [U]] : [U]] : [U]] : [U]] : [U]] : [U]] : [U]] : [U]] : [U]] : [T_2] : never : never) extends infer T_4 ? T_4 extends (string extends T_1 ? (T_1 & string)[] : T_1 extends infer T_2 ? T_2 extends T_1 ? T_2 extends "" ? [] : T_2 extends `${infer T_3}.${infer U}` ? [T_3, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_3}.${infer U}` ? [T_3, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_3}.${infer U}` ? [T_3, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_3}.${infer U}` ? [T_3, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_3}.${infer U}` ? [T_3, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_3}.${infer U}` ? [T_3, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_3}.${infer U}` ? [T_3, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_3}.${infer U}` ? [T_3, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_3}.${infer U}` ? [T_3, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_3}.${infer U}` ? [T_3, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_3}.${infer U}` ? [T_3, ...any] : [U]] : [U]] : [U]] : [U]] : [U]] : [U]] : [U]] : [U]] : [U]] : [U]] : [T_2] : never : never) ? T_4 extends [infer U_1, ...infer R] ? U_1 extends string ? `${U_1 extends `${number}` ? "$" : U_1}${R[0] extends string ? "." : ""}${R extends string[] ? R extends infer T_5 ? T_5 extends R ? T_5 extends [infer U_1, ...infer R] ? U_1 extends string ? `${U_1 extends `${number}` ? "$" : U_1}${R[0] extends string ? "." : ""}${R extends string[] ? R extends infer T_6 ? T_6 extends R ? T_6 extends [infer U_1, ...infer R] ? U_1 extends string ? `${U_1 extends `${number}` ? "$" : U_1}${R[0] extends string ? "." : ""}${R extends string[] ? R extends infer T_7 ? T_7 extends R ? T_7 extends [infer U_1, ...infer R] ? U_1 extends string ? `${U_1 extends `${number}` ? "$" : U_1}${R[0] extends string ? "." : ""}${R extends string[] ? R extends infer T_8 ? T_8 extends R ? T_8 extends [infer U_1, ...infer R] ? U_1 extends string ? `${U_1 extends `${number}` ? "$" : U_1}${R[0] extends string ? "." : ""}${R extends string[] ? R extends infer T_9 ? T_9 extends R ? T_9 extends [infer U_1, ...infer R] ? U_1 extends string ? `${U_1 extends `${number}` ? "$" : U_1}${R[0] extends string ? "." : ""}${R extends string[] ? R extends infer T_10 ? T_10 extends R ? T_10 extends [infer U_1, ...infer R] ? U_1 extends string ? `${U_1 extends `${number}` ? "$" : U_1}${R[0] extends string ? "." : ""}${R extends string[] ? R extends infer T_11 ? T_11 extends R ? T_11 extends [infer U_1, ...infer R] ? U_1 extends string ? `${U_1 extends `${number}` ? "$" : U_1}${R[0] extends string ? "." : ""}${R extends string[] ? R extends infer T_12 ? T_12 extends R ? T_12 extends [infer U_1, ...infer R] ? U_1 extends string ? `${U_1 extends `${number}` ? "$" : U_1}${R[0] extends string ? "." : ""}${R extends string[] ? R extends infer T_13 ? T_13 extends R ? T_13 extends [infer U_1, ...infer R] ? U_1 extends string ? `${U_1 extends `${number}` ? "$" : U_1}${R[0] extends string ? "." : ""}${R extends string[] ? R extends infer T_14 ? T_14 extends R ? T_14 extends [infer U_1, ...infer R] ? U_1 extends string ? `${U_1 extends `${number}` ? "$" : U_1}${R[0] extends string ? "." : ""}${R extends string[] ? any : ""}` : "" : "" : never : never : ""}` : "" : "" : never : never : ""}` : "" : "" : never : never : ""}` : "" : "" : never : never : ""}` : "" : "" : never : never : ""}` : "" : "" : never : never : ""}` : "" : "" : never : never : ""}` : "" : "" : never : never : ""}` : "" : "" : never : never : ""}` : "" : "" : never : never : ""}` : "" : "" : never : never : never : never : never)]?: Omit<((FieldDefs extends never ? {
454
- text: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
455
- email: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
456
- url: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
457
- phone: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
458
- number: react.FC<_saas_ui_forms.NumberInputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
459
- password: react.FC<_saas_ui_forms.PasswordInputProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
460
- textarea: react.FC<_chakra_ui_textarea_dist_textarea.TextareaProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
461
- switch: react.FC<_chakra_ui_switch_dist_switch.SwitchProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
462
- select: react.FC<_saas_ui_forms.SelectProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
463
- checkbox: react.FC<_chakra_ui_checkbox_dist_checkbox.CheckboxProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
464
- radio: react.FC<_saas_ui_forms.RadioInputProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
465
- pin: react.FC<_saas_ui_forms.PinFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
466
- 'native-select': react.FC<_saas_ui_forms.NativeSelectProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
467
- } : Omit<{
468
- text: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
469
- email: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
470
- url: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
471
- phone: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
472
- number: react.FC<_saas_ui_forms.NumberInputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
473
- password: react.FC<_saas_ui_forms.PasswordInputProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
474
- textarea: react.FC<_chakra_ui_textarea_dist_textarea.TextareaProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
475
- switch: react.FC<_chakra_ui_switch_dist_switch.SwitchProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
476
- select: react.FC<_saas_ui_forms.SelectProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
477
- checkbox: react.FC<_chakra_ui_checkbox_dist_checkbox.CheckboxProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
478
- radio: react.FC<_saas_ui_forms.RadioInputProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
479
- pin: react.FC<_saas_ui_forms.PinFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
480
- 'native-select': react.FC<_saas_ui_forms.NativeSelectProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
481
- }, keyof FieldDefs> & FieldDefs) extends infer T_15 ? { [K_2 in keyof T_15]: (FieldDefs extends never ? {
482
- text: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
483
- email: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
484
- url: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
485
- phone: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
486
- number: react.FC<_saas_ui_forms.NumberInputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
487
- password: react.FC<_saas_ui_forms.PasswordInputProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
488
- textarea: react.FC<_chakra_ui_textarea_dist_textarea.TextareaProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
489
- switch: react.FC<_chakra_ui_switch_dist_switch.SwitchProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
490
- select: react.FC<_saas_ui_forms.SelectProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
491
- checkbox: react.FC<_chakra_ui_checkbox_dist_checkbox.CheckboxProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
492
- radio: react.FC<_saas_ui_forms.RadioInputProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
493
- pin: react.FC<_saas_ui_forms.PinFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
494
- 'native-select': react.FC<_saas_ui_forms.NativeSelectProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
495
- } : Omit<{
496
- text: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
497
- email: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
498
- url: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
499
- phone: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
500
- number: react.FC<_saas_ui_forms.NumberInputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
501
- password: react.FC<_saas_ui_forms.PasswordInputProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
502
- textarea: react.FC<_chakra_ui_textarea_dist_textarea.TextareaProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
503
- switch: react.FC<_chakra_ui_switch_dist_switch.SwitchProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
504
- select: react.FC<_saas_ui_forms.SelectProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
505
- checkbox: react.FC<_chakra_ui_checkbox_dist_checkbox.CheckboxProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
506
- radio: react.FC<_saas_ui_forms.RadioInputProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
507
- pin: react.FC<_saas_ui_forms.PinFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
508
- 'native-select': react.FC<_saas_ui_forms.NativeSelectProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
509
- }, keyof FieldDefs> & FieldDefs)[K_2] extends react.FC<infer Props> ? {
510
- type?: K_2 | undefined;
511
- } & Omit<Props, keyof _saas_ui_forms.BaseFieldProps<TFieldValues, TName>> & _saas_ui_forms.BaseFieldProps<z.TypeOf<TSchema>, react_hook_form.Path<z.TypeOf<TSchema>>> : never; } : never)[keyof (FieldDefs extends never ? {
512
- text: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
513
- email: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
514
- url: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
515
- phone: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
516
- number: react.FC<_saas_ui_forms.NumberInputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
517
- password: react.FC<_saas_ui_forms.PasswordInputProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
518
- textarea: react.FC<_chakra_ui_textarea_dist_textarea.TextareaProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
519
- switch: react.FC<_chakra_ui_switch_dist_switch.SwitchProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
520
- select: react.FC<_saas_ui_forms.SelectProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
521
- checkbox: react.FC<_chakra_ui_checkbox_dist_checkbox.CheckboxProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
522
- radio: react.FC<_saas_ui_forms.RadioInputProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
523
- pin: react.FC<_saas_ui_forms.PinFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
524
- 'native-select': react.FC<_saas_ui_forms.NativeSelectProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
525
- } : Omit<{
526
- text: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
527
- email: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
528
- url: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
529
- phone: react.FC<_saas_ui_forms.InputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
530
- number: react.FC<_saas_ui_forms.NumberInputFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
531
- password: react.FC<_saas_ui_forms.PasswordInputProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
532
- textarea: react.FC<_chakra_ui_textarea_dist_textarea.TextareaProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
533
- switch: react.FC<_chakra_ui_switch_dist_switch.SwitchProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
534
- select: react.FC<_saas_ui_forms.SelectProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
535
- checkbox: react.FC<_chakra_ui_checkbox_dist_checkbox.CheckboxProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
536
- radio: react.FC<_saas_ui_forms.RadioInputProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
537
- pin: react.FC<_saas_ui_forms.PinFieldProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
538
- 'native-select': react.FC<_saas_ui_forms.NativeSelectProps & _saas_ui_forms.BaseFieldProps<_saas_ui_forms.FieldValues, string>>;
539
- }, keyof FieldDefs> & FieldDefs)], "name"> | undefined; } & {
540
- submit?: _saas_ui_forms.SubmitButtonProps | undefined;
541
- }) | undefined;
542
- } & {
543
- ref?: react.ForwardedRef<HTMLFormElement> | undefined;
544
- }) => React.ReactElement;
418
+ type ZodFormType<FieldDefs, ExtraProps = object, ExtraOverrides = object, Type extends 'zod' = 'zod'> = (<TSchema extends z.AnyZodObject = z.AnyZodObject, TFieldValues extends z.infer<TSchema> = z.infer<TSchema>, TContext extends object = object>(props: WithFields<FormProps$1<TSchema, TFieldValues, TContext>, FieldDefs, ExtraOverrides> & {
419
+ ref?: React.ForwardedRef<HTMLFormElement>;
420
+ } & ExtraProps) => React.ReactElement) & {
421
+ displayName?: string;
422
+ id?: string;
423
+ };
424
+ declare const createZodForm: <FieldDefs>(options?: CreateZodFormProps<FieldDefs> | undefined) => ZodFormType<FieldDefs, object, object, "zod">;
545
425
 
546
- declare const Form: <TSchema extends zod.AnyZodObject = zod.AnyZodObject, TContext extends object = object>(props: Omit<FormProps<zod.TypeOf<TSchema>, TContext, TSchema, FieldProps<zod.TypeOf<TSchema>>>, "children" | "fields"> & {
547
- children?: react.ReactNode | ((props: FormRenderContext<zod.TypeOf<TSchema>, TContext, ({
548
- type?: "number" | undefined;
549
- } & Omit<NumberInputFieldProps & BaseFieldProps<react_hook_form.FieldValues, string>, keyof BaseFieldProps<TFieldValues, TName>> & BaseFieldProps<zod.TypeOf<TSchema>, react_hook_form.Path<zod.TypeOf<TSchema>>>) | ({
550
- type?: "text" | undefined;
551
- } & Omit<InputFieldProps & BaseFieldProps<react_hook_form.FieldValues, string>, keyof BaseFieldProps<TFieldValues, TName>> & BaseFieldProps<zod.TypeOf<TSchema>, react_hook_form.Path<zod.TypeOf<TSchema>>>) | ({
552
- type?: "email" | undefined;
553
- } & Omit<InputFieldProps & BaseFieldProps<react_hook_form.FieldValues, string>, keyof BaseFieldProps<TFieldValues, TName>> & BaseFieldProps<zod.TypeOf<TSchema>, react_hook_form.Path<zod.TypeOf<TSchema>>>) | ({
554
- type?: "url" | undefined;
555
- } & Omit<InputFieldProps & BaseFieldProps<react_hook_form.FieldValues, string>, keyof BaseFieldProps<TFieldValues, TName>> & BaseFieldProps<zod.TypeOf<TSchema>, react_hook_form.Path<zod.TypeOf<TSchema>>>) | ({
556
- type?: "phone" | undefined;
557
- } & Omit<InputFieldProps & BaseFieldProps<react_hook_form.FieldValues, string>, keyof BaseFieldProps<TFieldValues, TName>> & BaseFieldProps<zod.TypeOf<TSchema>, react_hook_form.Path<zod.TypeOf<TSchema>>>) | ({
558
- type?: "password" | undefined;
559
- } & Omit<PasswordInputProps & BaseFieldProps<react_hook_form.FieldValues, string>, keyof BaseFieldProps<TFieldValues, TName>> & BaseFieldProps<zod.TypeOf<TSchema>, react_hook_form.Path<zod.TypeOf<TSchema>>>) | ({
560
- type?: "textarea" | undefined;
561
- } & Omit<_chakra_ui_textarea_dist_textarea.TextareaProps & BaseFieldProps<react_hook_form.FieldValues, string>, keyof BaseFieldProps<TFieldValues, TName>> & BaseFieldProps<zod.TypeOf<TSchema>, react_hook_form.Path<zod.TypeOf<TSchema>>>) | ({
562
- type?: "switch" | undefined;
563
- } & Omit<_chakra_ui_switch_dist_switch.SwitchProps & BaseFieldProps<react_hook_form.FieldValues, string>, keyof BaseFieldProps<TFieldValues, TName>> & BaseFieldProps<zod.TypeOf<TSchema>, react_hook_form.Path<zod.TypeOf<TSchema>>>) | ({
564
- type?: "select" | undefined;
565
- } & Omit<SelectProps & BaseFieldProps<react_hook_form.FieldValues, string>, keyof BaseFieldProps<TFieldValues, TName>> & BaseFieldProps<zod.TypeOf<TSchema>, react_hook_form.Path<zod.TypeOf<TSchema>>>) | ({
566
- type?: "checkbox" | undefined;
567
- } & Omit<_chakra_ui_checkbox_dist_checkbox.CheckboxProps & BaseFieldProps<react_hook_form.FieldValues, string>, keyof BaseFieldProps<TFieldValues, TName>> & BaseFieldProps<zod.TypeOf<TSchema>, react_hook_form.Path<zod.TypeOf<TSchema>>>) | ({
568
- type?: "radio" | undefined;
569
- } & Omit<RadioInputProps & BaseFieldProps<react_hook_form.FieldValues, string>, keyof BaseFieldProps<TFieldValues, TName>> & BaseFieldProps<zod.TypeOf<TSchema>, react_hook_form.Path<zod.TypeOf<TSchema>>>) | ({
570
- type?: "pin" | undefined;
571
- } & Omit<PinFieldProps & BaseFieldProps<react_hook_form.FieldValues, string>, keyof BaseFieldProps<TFieldValues, TName>> & BaseFieldProps<zod.TypeOf<TSchema>, react_hook_form.Path<zod.TypeOf<TSchema>>>) | ({
572
- type?: "native-select" | undefined;
573
- } & Omit<NativeSelectProps & BaseFieldProps<react_hook_form.FieldValues, string>, keyof BaseFieldProps<TFieldValues, TName>> & BaseFieldProps<zod.TypeOf<TSchema>, react_hook_form.Path<zod.TypeOf<TSchema>>>)>) => react.ReactNode);
574
- fields?: ({ [K in react_hook_form.Path<zod.TypeOf<TSchema>> | (react_hook_form.Path<zod.TypeOf<TSchema>> extends infer T ? T extends react_hook_form.Path<zod.TypeOf<TSchema>> ? T extends string ? (string extends T ? (T & string)[] : T extends infer T_1 ? T_1 extends T ? T_1 extends "" ? [] : T_1 extends `${infer T_2}.${infer U}` ? [T_2, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_2}.${infer U}` ? [T_2, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_2}.${infer U}` ? [T_2, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_2}.${infer U}` ? [T_2, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_2}.${infer U}` ? [T_2, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_2}.${infer U}` ? [T_2, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_2}.${infer U}` ? [T_2, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_2}.${infer U}` ? [T_2, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_2}.${infer U}` ? [T_2, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_2}.${infer U}` ? [T_2, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_2}.${infer U}` ? [T_2, ...any] : [U]] : [U]] : [U]] : [U]] : [U]] : [U]] : [U]] : [U]] : [U]] : [U]] : [T_1] : never : never) extends infer T_3 ? T_3 extends (string extends T ? (T & string)[] : T extends infer T_1 ? T_1 extends T ? T_1 extends "" ? [] : T_1 extends `${infer T_2}.${infer U}` ? [T_2, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_2}.${infer U}` ? [T_2, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_2}.${infer U}` ? [T_2, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_2}.${infer U}` ? [T_2, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_2}.${infer U}` ? [T_2, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_2}.${infer U}` ? [T_2, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_2}.${infer U}` ? [T_2, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_2}.${infer U}` ? [T_2, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_2}.${infer U}` ? [T_2, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_2}.${infer U}` ? [T_2, ...string extends U ? (U & string)[] : U extends "" ? [] : U extends `${infer T_2}.${infer U}` ? [T_2, ...any] : [U]] : [U]] : [U]] : [U]] : [U]] : [U]] : [U]] : [U]] : [U]] : [U]] : [T_1] : never : never) ? T_3 extends [infer U_1, ...infer R] ? U_1 extends string ? `${U_1 extends `${number}` ? "$" : U_1}${R[0] extends string ? "." : ""}${R extends string[] ? R extends infer T_4 ? T_4 extends R ? T_4 extends [infer U_1, ...infer R] ? U_1 extends string ? `${U_1 extends `${number}` ? "$" : U_1}${R[0] extends string ? "." : ""}${R extends string[] ? R extends infer T_5 ? T_5 extends R ? T_5 extends [infer U_1, ...infer R] ? U_1 extends string ? `${U_1 extends `${number}` ? "$" : U_1}${R[0] extends string ? "." : ""}${R extends string[] ? R extends infer T_6 ? T_6 extends R ? T_6 extends [infer U_1, ...infer R] ? U_1 extends string ? `${U_1 extends `${number}` ? "$" : U_1}${R[0] extends string ? "." : ""}${R extends string[] ? R extends infer T_7 ? T_7 extends R ? T_7 extends [infer U_1, ...infer R] ? U_1 extends string ? `${U_1 extends `${number}` ? "$" : U_1}${R[0] extends string ? "." : ""}${R extends string[] ? R extends infer T_8 ? T_8 extends R ? T_8 extends [infer U_1, ...infer R] ? U_1 extends string ? `${U_1 extends `${number}` ? "$" : U_1}${R[0] extends string ? "." : ""}${R extends string[] ? R extends infer T_9 ? T_9 extends R ? T_9 extends [infer U_1, ...infer R] ? U_1 extends string ? `${U_1 extends `${number}` ? "$" : U_1}${R[0] extends string ? "." : ""}${R extends string[] ? R extends infer T_10 ? T_10 extends R ? T_10 extends [infer U_1, ...infer R] ? U_1 extends string ? `${U_1 extends `${number}` ? "$" : U_1}${R[0] extends string ? "." : ""}${R extends string[] ? R extends infer T_11 ? T_11 extends R ? T_11 extends [infer U_1, ...infer R] ? U_1 extends string ? `${U_1 extends `${number}` ? "$" : U_1}${R[0] extends string ? "." : ""}${R extends string[] ? R extends infer T_12 ? T_12 extends R ? T_12 extends [infer U_1, ...infer R] ? U_1 extends string ? `${U_1 extends `${number}` ? "$" : U_1}${R[0] extends string ? "." : ""}${R extends string[] ? R extends infer T_13 ? T_13 extends R ? T_13 extends [infer U_1, ...infer R] ? U_1 extends string ? `${U_1 extends `${number}` ? "$" : U_1}${R[0] extends string ? "." : ""}${R extends string[] ? any : ""}` : "" : "" : never : never : ""}` : "" : "" : never : never : ""}` : "" : "" : never : never : ""}` : "" : "" : never : never : ""}` : "" : "" : never : never : ""}` : "" : "" : never : never : ""}` : "" : "" : never : never : ""}` : "" : "" : never : never : ""}` : "" : "" : never : never : ""}` : "" : "" : never : never : ""}` : "" : "" : never : never : never : never : never)]?: Omit<({
575
- type?: "number" | undefined;
576
- } & Omit<NumberInputFieldProps & BaseFieldProps<react_hook_form.FieldValues, string>, keyof BaseFieldProps<TFieldValues, TName>> & BaseFieldProps<zod.TypeOf<TSchema>, react_hook_form.Path<zod.TypeOf<TSchema>>>) | ({
577
- type?: "text" | undefined;
578
- } & Omit<InputFieldProps & BaseFieldProps<react_hook_form.FieldValues, string>, keyof BaseFieldProps<TFieldValues, TName>> & BaseFieldProps<zod.TypeOf<TSchema>, react_hook_form.Path<zod.TypeOf<TSchema>>>) | ({
579
- type?: "email" | undefined;
580
- } & Omit<InputFieldProps & BaseFieldProps<react_hook_form.FieldValues, string>, keyof BaseFieldProps<TFieldValues, TName>> & BaseFieldProps<zod.TypeOf<TSchema>, react_hook_form.Path<zod.TypeOf<TSchema>>>) | ({
581
- type?: "url" | undefined;
582
- } & Omit<InputFieldProps & BaseFieldProps<react_hook_form.FieldValues, string>, keyof BaseFieldProps<TFieldValues, TName>> & BaseFieldProps<zod.TypeOf<TSchema>, react_hook_form.Path<zod.TypeOf<TSchema>>>) | ({
583
- type?: "phone" | undefined;
584
- } & Omit<InputFieldProps & BaseFieldProps<react_hook_form.FieldValues, string>, keyof BaseFieldProps<TFieldValues, TName>> & BaseFieldProps<zod.TypeOf<TSchema>, react_hook_form.Path<zod.TypeOf<TSchema>>>) | ({
585
- type?: "password" | undefined;
586
- } & Omit<PasswordInputProps & BaseFieldProps<react_hook_form.FieldValues, string>, keyof BaseFieldProps<TFieldValues, TName>> & BaseFieldProps<zod.TypeOf<TSchema>, react_hook_form.Path<zod.TypeOf<TSchema>>>) | ({
587
- type?: "textarea" | undefined;
588
- } & Omit<_chakra_ui_textarea_dist_textarea.TextareaProps & BaseFieldProps<react_hook_form.FieldValues, string>, keyof BaseFieldProps<TFieldValues, TName>> & BaseFieldProps<zod.TypeOf<TSchema>, react_hook_form.Path<zod.TypeOf<TSchema>>>) | ({
589
- type?: "switch" | undefined;
590
- } & Omit<_chakra_ui_switch_dist_switch.SwitchProps & BaseFieldProps<react_hook_form.FieldValues, string>, keyof BaseFieldProps<TFieldValues, TName>> & BaseFieldProps<zod.TypeOf<TSchema>, react_hook_form.Path<zod.TypeOf<TSchema>>>) | ({
591
- type?: "select" | undefined;
592
- } & Omit<SelectProps & BaseFieldProps<react_hook_form.FieldValues, string>, keyof BaseFieldProps<TFieldValues, TName>> & BaseFieldProps<zod.TypeOf<TSchema>, react_hook_form.Path<zod.TypeOf<TSchema>>>) | ({
593
- type?: "checkbox" | undefined;
594
- } & Omit<_chakra_ui_checkbox_dist_checkbox.CheckboxProps & BaseFieldProps<react_hook_form.FieldValues, string>, keyof BaseFieldProps<TFieldValues, TName>> & BaseFieldProps<zod.TypeOf<TSchema>, react_hook_form.Path<zod.TypeOf<TSchema>>>) | ({
595
- type?: "radio" | undefined;
596
- } & Omit<RadioInputProps & BaseFieldProps<react_hook_form.FieldValues, string>, keyof BaseFieldProps<TFieldValues, TName>> & BaseFieldProps<zod.TypeOf<TSchema>, react_hook_form.Path<zod.TypeOf<TSchema>>>) | ({
597
- type?: "pin" | undefined;
598
- } & Omit<PinFieldProps & BaseFieldProps<react_hook_form.FieldValues, string>, keyof BaseFieldProps<TFieldValues, TName>> & BaseFieldProps<zod.TypeOf<TSchema>, react_hook_form.Path<zod.TypeOf<TSchema>>>) | ({
599
- type?: "native-select" | undefined;
600
- } & Omit<NativeSelectProps & BaseFieldProps<react_hook_form.FieldValues, string>, keyof BaseFieldProps<TFieldValues, TName>> & BaseFieldProps<zod.TypeOf<TSchema>, react_hook_form.Path<zod.TypeOf<TSchema>>>), "name"> | undefined; } & {
601
- submit?: SubmitButtonProps | undefined;
602
- }) | undefined;
603
- } & {
604
- ref?: react.ForwardedRef<HTMLFormElement> | undefined;
605
- }) => react.ReactElement<any, string | react.JSXElementConstructor<any>>;
426
+ declare const Form: ZodFormType<unknown, object, object, "zod">;
427
+ declare const StepForm: (<TSteps extends {
428
+ name: string;
429
+ schema?: zod.AnyZodObject | undefined;
430
+ }[] = {
431
+ name: string;
432
+ schema?: zod.AnyZodObject | undefined;
433
+ }[], TFieldValues extends TSteps extends [infer Step, ...infer Rest] ? Step extends {
434
+ schema: zod.AnyZodObject;
435
+ } ? zod.TypeOf<Step["schema"]> & (Rest extends {
436
+ name: string;
437
+ schema?: zod.AnyZodObject | undefined;
438
+ }[] ? Rest extends infer T ? T extends Rest ? T extends [infer Step, ...infer Rest] ? Step extends {
439
+ schema: zod.AnyZodObject;
440
+ } ? zod.TypeOf<Step["schema"]> & (Rest extends {
441
+ name: string;
442
+ schema?: zod.AnyZodObject | undefined;
443
+ }[] ? Rest extends infer T_1 ? T_1 extends Rest ? T_1 extends [infer Step, ...infer Rest] ? Step extends {
444
+ schema: zod.AnyZodObject;
445
+ } ? zod.TypeOf<Step["schema"]> & (Rest extends {
446
+ name: string;
447
+ schema?: zod.AnyZodObject | undefined;
448
+ }[] ? Rest extends infer T_2 ? T_2 extends Rest ? T_2 extends [infer Step, ...infer Rest] ? Step extends {
449
+ schema: zod.AnyZodObject;
450
+ } ? zod.TypeOf<Step["schema"]> & (Rest extends {
451
+ name: string;
452
+ schema?: zod.AnyZodObject | undefined;
453
+ }[] ? Rest extends infer T_3 ? T_3 extends Rest ? T_3 extends [infer Step, ...infer Rest] ? Step extends {
454
+ schema: zod.AnyZodObject;
455
+ } ? zod.TypeOf<Step["schema"]> & (Rest extends {
456
+ name: string;
457
+ schema?: zod.AnyZodObject | undefined;
458
+ }[] ? Rest extends infer T_4 ? T_4 extends Rest ? T_4 extends [infer Step, ...infer Rest] ? Step extends {
459
+ schema: zod.AnyZodObject;
460
+ } ? zod.TypeOf<Step["schema"]> & (Rest extends {
461
+ name: string;
462
+ schema?: zod.AnyZodObject | undefined;
463
+ }[] ? Rest extends infer T_5 ? T_5 extends Rest ? T_5 extends [infer Step, ...infer Rest] ? Step extends {
464
+ schema: zod.AnyZodObject;
465
+ } ? zod.TypeOf<Step["schema"]> & (Rest extends {
466
+ name: string;
467
+ schema?: zod.AnyZodObject | undefined;
468
+ }[] ? Rest extends infer T_6 ? T_6 extends Rest ? T_6 extends [infer Step, ...infer Rest] ? Step extends {
469
+ schema: zod.AnyZodObject;
470
+ } ? zod.TypeOf<Step["schema"]> & (Rest extends {
471
+ name: string;
472
+ schema?: zod.AnyZodObject | undefined;
473
+ }[] ? Rest extends infer T_7 ? T_7 extends Rest ? T_7 extends [infer Step, ...infer Rest] ? Step extends {
474
+ schema: zod.AnyZodObject;
475
+ } ? zod.TypeOf<Step["schema"]> & (Rest extends {
476
+ name: string;
477
+ schema?: zod.AnyZodObject | undefined;
478
+ }[] ? Rest extends infer T_8 ? T_8 extends Rest ? T_8 extends [infer Step, ...infer Rest] ? Step extends {
479
+ schema: zod.AnyZodObject;
480
+ } ? zod.TypeOf<Step["schema"]> & (Rest extends {
481
+ name: string;
482
+ schema?: zod.AnyZodObject | undefined;
483
+ }[] ? Rest extends infer T_9 ? T_9 extends Rest ? T_9 extends [infer Step, ...infer Rest] ? Step extends {
484
+ schema: zod.AnyZodObject;
485
+ } ? zod.TypeOf<Step["schema"]> & (Rest extends {
486
+ name: string;
487
+ schema?: zod.AnyZodObject | undefined;
488
+ }[] ? any : object) : object : object : never : never : object) : object : object : never : never : object) : object : object : never : never : object) : object : object : never : never : object) : object : object : never : never : object) : object : object : never : never : object) : object : object : never : never : object) : object : object : never : never : object) : object : object : never : never : object) : object : object : never : never : object) : object : object = TSteps extends [infer Step, ...infer Rest] ? Step extends {
489
+ schema: zod.AnyZodObject;
490
+ } ? zod.TypeOf<Step["schema"]> & (Rest extends {
491
+ name: string;
492
+ schema?: zod.AnyZodObject | undefined;
493
+ }[] ? Rest extends infer T_10 ? T_10 extends Rest ? T_10 extends [infer Step, ...infer Rest] ? Step extends {
494
+ schema: zod.AnyZodObject;
495
+ } ? zod.TypeOf<Step["schema"]> & (Rest extends {
496
+ name: string;
497
+ schema?: zod.AnyZodObject | undefined;
498
+ }[] ? Rest extends infer T_11 ? T_11 extends Rest ? T_11 extends [infer Step, ...infer Rest] ? Step extends {
499
+ schema: zod.AnyZodObject;
500
+ } ? zod.TypeOf<Step["schema"]> & (Rest extends {
501
+ name: string;
502
+ schema?: zod.AnyZodObject | undefined;
503
+ }[] ? Rest extends infer T_12 ? T_12 extends Rest ? T_12 extends [infer Step, ...infer Rest] ? Step extends {
504
+ schema: zod.AnyZodObject;
505
+ } ? zod.TypeOf<Step["schema"]> & (Rest extends {
506
+ name: string;
507
+ schema?: zod.AnyZodObject | undefined;
508
+ }[] ? Rest extends infer T_13 ? T_13 extends Rest ? T_13 extends [infer Step, ...infer Rest] ? Step extends {
509
+ schema: zod.AnyZodObject;
510
+ } ? zod.TypeOf<Step["schema"]> & (Rest extends {
511
+ name: string;
512
+ schema?: zod.AnyZodObject | undefined;
513
+ }[] ? Rest extends infer T_14 ? T_14 extends Rest ? T_14 extends [infer Step, ...infer Rest] ? Step extends {
514
+ schema: zod.AnyZodObject;
515
+ } ? zod.TypeOf<Step["schema"]> & (Rest extends {
516
+ name: string;
517
+ schema?: zod.AnyZodObject | undefined;
518
+ }[] ? Rest extends infer T_15 ? T_15 extends Rest ? T_15 extends [infer Step, ...infer Rest] ? Step extends {
519
+ schema: zod.AnyZodObject;
520
+ } ? zod.TypeOf<Step["schema"]> & (Rest extends {
521
+ name: string;
522
+ schema?: zod.AnyZodObject | undefined;
523
+ }[] ? Rest extends infer T_16 ? T_16 extends Rest ? T_16 extends [infer Step, ...infer Rest] ? Step extends {
524
+ schema: zod.AnyZodObject;
525
+ } ? zod.TypeOf<Step["schema"]> & (Rest extends {
526
+ name: string;
527
+ schema?: zod.AnyZodObject | undefined;
528
+ }[] ? Rest extends infer T_17 ? T_17 extends Rest ? T_17 extends [infer Step, ...infer Rest] ? Step extends {
529
+ schema: zod.AnyZodObject;
530
+ } ? zod.TypeOf<Step["schema"]> & (Rest extends {
531
+ name: string;
532
+ schema?: zod.AnyZodObject | undefined;
533
+ }[] ? Rest extends infer T_18 ? T_18 extends Rest ? T_18 extends [infer Step, ...infer Rest] ? Step extends {
534
+ schema: zod.AnyZodObject;
535
+ } ? zod.TypeOf<Step["schema"]> & (Rest extends {
536
+ name: string;
537
+ schema?: zod.AnyZodObject | undefined;
538
+ }[] ? Rest extends infer T_19 ? T_19 extends Rest ? T_19 extends [infer Step, ...infer Rest] ? Step extends {
539
+ schema: zod.AnyZodObject;
540
+ } ? zod.TypeOf<Step["schema"]> & (Rest extends {
541
+ name: string;
542
+ schema?: zod.AnyZodObject | undefined;
543
+ }[] ? any : object) : object : object : never : never : object) : object : object : never : never : object) : object : object : never : never : object) : object : object : never : never : object) : object : object : never : never : object) : object : object : never : never : object) : object : object : never : never : object) : object : object : never : never : object) : object : object : never : never : object) : object : object : never : never : object) : object : object, TContext extends object = object>(props: UseStepFormProps<TSteps, TFieldValues, TContext, FieldProps<TFieldValues>> & {
544
+ steps: TSteps;
545
+ ref?: React$1.ForwardedRef<HTMLFormElement> | undefined;
546
+ }) => React$1.ReactElement<any, string | React$1.JSXElementConstructor<any>>) & {
547
+ displayName?: string | undefined;
548
+ id?: string | undefined;
549
+ };
606
550
 
607
- export { Form, Options, ZodMeta, createZodForm, getFieldsFromSchema, getNestedSchema, zodFieldResolver, zodMeta, zodParseMeta };
551
+ export { Form, Options, StepForm, ZodFormType, ZodMeta, createZodForm, getFieldsFromSchema, getNestedSchema, zodFieldResolver, zodMeta, zodParseMeta };