import React, { ReactNode } from 'react'; import * as Ariakit from '@ariakit/react'; import { ButtonProps } from '../Button/Button'; import { ClassValue } from 'clsx'; import { Variants } from './styles.css'; type FormComponent = React.FC & { Input: typeof Input; Error: typeof Error; Submit: typeof Submit; Field: typeof Field; Select: typeof Select; NamedSection: typeof NamedSection; Label: typeof Label; useFormStore: typeof Ariakit.useFormStore; }; interface LabelProps { label: string; name: Ariakit.FormInputProps['name']; tag?: ReactNode; optional?: boolean; } export declare const Label: React.FC; type HasLabel = { name: Ariakit.FormInputProps['name']; label?: string; optional?: boolean; tag?: ReactNode; icon?: ReactNode; }; export declare const NamedSection: ({ children, label, name, tag, icon, optional, }: React.PropsWithChildren) => React.JSX.Element; export declare const useForm: () => Ariakit.FormStore; type Props = Ariakit.FormProps; export declare const Form: FormComponent; export declare const Error: ({ ...props }: Ariakit.FormErrorProps) => React.JSX.Element; export declare const Submit: ({ ...props }: ButtonProps) => React.JSX.Element; export type InputProps = Omit & Variants & HasLabel & { cssClass?: ClassValue | ClassValue[]; }; export declare const Input: React.ForwardRefExoticComponent & { truncate?: boolean | undefined; size?: "small" | "xSmall" | undefined; collapsed?: boolean | undefined; outline?: boolean | undefined; rounded?: boolean | "first" | "last" | "middle" | undefined; } & HasLabel & { cssClass?: ClassValue | ClassValue[]; }, "ref"> & React.RefAttributes>; type FormFieldProps = Ariakit.FormFieldProps & React.PropsWithChildren & Variants & HasLabel & { cssClass?: ClassValue | ClassValue[]; }; export declare const Field: ({ children, label, cssClass, size, collapsed, truncate, outline, ...props }: FormFieldProps) => React.JSX.Element; type FormSelectProps = Ariakit.FormInputProps & React.PropsWithChildren; export declare const Select: ({ children, label, tag, optional, ...props }: FormSelectProps) => React.JSX.Element; export declare const useFormStore: typeof Ariakit.useFormStore; export declare type FormState> = Ariakit.FormStore; export {};