import { Field } from './Field'; import { TableCreateButton } from './TableCreateButton'; import { EditButton } from './EditButton'; import { SxProps } from '@mui/material'; import { RaRecord } from 'ra-core'; import { ReactElement, ReactNode } from 'react'; import { UseFieldArrayReturn } from 'react-hook-form'; declare const TableFormIterator: import('@emotion/styled').StyledComponent & import('@mui/system').MUIStyledCommonProps, {}, {}>; interface TableFormIteratorProps extends Partial { addButton?: ReactElement; children?: ReactNode; className?: string; disableAdd?: boolean; disableRemove?: boolean; enableClearAll?: boolean; /** * Adding the template prop will allow to set a default value for the new row. * * @example * * * * * * * * * * * */ template?: object; record?: RaRecord; label?: string | boolean; resource?: string; source?: string; sx?: SxProps; empty: ReactNode | string; inset?: boolean; } type ITableForm = typeof TableFormIterator & { /** * TableFormiterator allows to insert an addButton which will render the default btn and open a dialog with the form fields passed as children. * * @example * * * * * * * } * label="Property catalog"> * * * * * * * */ CreateButton: typeof TableCreateButton; /** * TableFormiterator allows a child EditButton which will render an edit button in the ActionsMenu of each row. * The EditButton will open a dialog with the form fields passed as children. * * @example * * * * * * * * * * * * * * * * * */ EditButton: typeof EditButton; /** * TableFormiterator allows a child Field which will render a read-only field in the Table with a custom record context. * The record context will overwritthe by getValues() of useFormContext() hook. * * @example * * * * * * * * * * * * * * * * * {...} * * * * */ Field: typeof Field; }; declare const DefaultTableForm: ITableForm; export { DefaultTableForm as TableFormIterator }; export type { TableFormIteratorProps }; //# sourceMappingURL=TableFormIterator.d.ts.map