import type { ElementType } from "react"; import type { ButtonOptions } from "../button/button.tsx"; import type { Props } from "../utils/types.ts"; import type { FormStore } from "./form-store.ts"; declare const TagName = "button"; type TagName = typeof TagName; /** * Returns props to create a `FormReset` component. * @see https://ariakit.com/components/form * @example * ```jsx * const store = useFormStore(); * const props = useFormSubmit({ store }); *
* Submit *
* ``` */ export declare const useFormSubmit: import("../utils/types.ts").Hook<"button", FormSubmitOptions<"button">>; /** * Renders a native submit button inside a form. The button will be * [`disabled`](https://ariakit.com/reference/form-submit#disabled) while the * form is submitting, but it will remain accessible to keyboard and screen * reader users thanks to the * [`accessibleWhenDisabled`](https://ariakit.com/reference/form-submit#accessiblewhendisabled) * prop that's enabled by default. * @see https://ariakit.com/components/form * @example * ```jsx {4} * const form = useFormStore(); * *
* Submit *
* ``` */ export declare const FormSubmit: (props: FormSubmitProps) => import("react").ReactElement>; export interface FormSubmitOptions extends ButtonOptions { /** * Object returned by the * [`useFormStore`](https://ariakit.com/reference/use-form-store) hook. If not * provided, the closest [`Form`](https://ariakit.com/reference/form) or * [`FormProvider`](https://ariakit.com/reference/form-provider) components' * context will be used. */ store?: FormStore; /** * @default true */ accessibleWhenDisabled?: ButtonOptions["accessibleWhenDisabled"]; } export type FormSubmitProps = Props>; export {};