import { type FormLayout } from './form-layout'; import type { ActionFieldDef } from './types'; import { buildZodSchema, resolveWidget } from './dynamic-form-schema'; export { buildZodSchema, resolveWidget }; export { DynamicLineItems } from './dynamic-line-items'; export { DynamicSelectField } from './dynamic-select-field'; export { DynamicMultiSelectField } from './dynamic-multi-select-field'; export { DynamicDateField } from './dynamic-date-field'; export { UploadField } from './upload-field'; export { IconPickerField } from './icon-picker-field'; export { ColorPickerField, DEFAULT_ROLE_COLOR, normalizeHex } from './color-picker-field'; export interface DynamicFormProps { fields: ActionFieldDef[]; initialValues?: Record; onSubmit: (values: Record) => void | Promise; onCancel?: () => void; submitLabel?: string; cancelLabel?: string; disabled?: boolean; /** * Declarative form layout served on the model metadata (kernel PR #230). * When present the visible fields are grouped by their `section` respecting * `sections` order: `mode:"sections"` stacks (optionally collapsible) * sections; `mode:"steps"` renders a Anterior/Siguiente wizard. Absent → the * legacy flat list (unchanged). */ formLayout?: FormLayout; /** * Para formularios dentro de un modal con alto acotado: el cuerpo de campos * hace scroll propio y la barra de botones (Guardar/Cancelar) queda fija * abajo, así nunca queda fuera de pantalla con muchos campos. El contenedor * debe ser flex-col con alto máximo (p.ej. `max-h-[90dvh]`). */ scrollableBody?: boolean; } export declare function DynamicForm({ fields, initialValues, onSubmit, onCancel, submitLabel, cancelLabel, disabled, formLayout, scrollableBody, }: DynamicFormProps): import("react").JSX.Element; /** * Radix Select puede emitir `onValueChange('')` sin interacción del usuario (su *