declare class AjaxForm { #private; constructor(form: HTMLFormElement); setSubmitCallback(clb: (axForm: AjaxForm, formData: FormData) => void): void; /** * @deprecated submitCallback property is deprecated and will be removed in the next major release. Use setSubmitCallback() method instead. */ set submitCallback(clb: (axForm: AjaxForm, formData: FormData) => void); /** * Inserts a span element containing the error message after the input field, or at the beginning of the form to show form-level errors (field_id is the id of the form). */ showErrors(errors: { field_id: string; message: string; }[]): Promise; getForm(): HTMLFormElement; reset: () => void; resetFileInputs: () => void; } type AjaxFormCallable = ((formOrSelector: HTMLFormElement | string) => AjaxForm | null) & { /** @deprecated Use ajaxForm(form) instead: ajaxForm.get(form) */ get: (formOrSelector: HTMLFormElement | string) => AjaxForm | null; }; declare const ajaxForm: AjaxFormCallable; export { ajaxForm as default };