import { DOMRef } from '@react-types/shared';
import { FormHTMLAttributes, ReactElement } from 'react';
import { FormBaseProps } from '../../../shared/index';
import { BaseProps, ContainerStyleProps, Styles } from '../../../tasty/index';
import { FieldTypes } from './types';
import { CubeFormData, CubeFormInstance } from './use-form';
export declare const FormContext: import("react").Context<{}>;
export declare function useFormProps(props: any): any;
export interface CubeFormProps<T extends FieldTypes = FieldTypes> extends FormBaseProps, BaseProps, ContainerStyleProps, Pick<FormHTMLAttributes<HTMLFormElement>, 'action' | 'autoComplete' | 'encType' | 'method' | 'target'> {
    /** Form name */
    name?: string;
    /** Default field values */
    defaultValues?: Partial<T>;
    /** Trigger when any value of the Field is changed */
    onValuesChange?: CubeFormInstance<T>['onValuesChange'];
    /** Trigger on form submit and success */
    onSubmit?: CubeFormInstance<T>['onSubmit'];
    /** Trigger on form submit and failed */
    onSubmitFailed?: (any?: any) => void | Promise<any>;
    /** Set form instance created by useForm */
    form?: CubeFormInstance<T, CubeFormData<T>>;
    /** The size of the side area with labels. Only for `labelPosition="side"` */
    labelWidth?: Styles['width'];
    orientation?: 'vertical' | 'horizontal';
}
/**
 * Forms allow users to enter data that can be submitted while providing alignment and styling for form fields.
 */
declare const _Form: <T extends FieldTypes>(props: CubeFormProps<T> & {
    ref?: DOMRef<HTMLFormElement>;
}) => ReactElement;
export { _Form as Form };
