import type { App } from "../core/app.js";
import type { Record as RecordModel } from "../core/record_model.js";
export declare class RecordUpsert {
    ctx: unknown;
    app: App;
    record: RecordModel;
    accessLevel: number;
    disablePasswordValidations: boolean;
    password: string;
    passwordConfirm: string;
    oldPassword: string;
    constructor(app: App, record: RecordModel);
    SetContext(ctx: unknown): void;
    SetApp(app: App): void;
    SetRecord(record: RecordModel): void;
    ResetAccess(): void;
    GrantManagerAccess(): void;
    GrantSuperuserAccess(): void;
    HasManageAccess(): boolean;
    Load(data: Record<string, unknown>): void;
    LoadAsync(data: Record<string, unknown>): Promise<void>;
    private prepareLoad;
    private restoreHiddenFieldValue;
    private validateFormFieldsAsync;
    private checkOldPasswordAsync;
    DrySubmit(callback: ((txApp: App, drySavedRecord: RecordModel) => Error | null | Promise<Error | null>) | null): Promise<Error | null>;
    Submit(): Promise<Error | null>;
    syncPasswordFields(): void;
}
