import { AdminForthPlugin } from "adminforth"; import type { IAdminForth, IHttpServer, AdminForthResourceColumn, AdminForthResource } from "adminforth"; import type { PluginOptions } from './types.js'; export default class EmailPasswordReset extends AdminForthPlugin { options: PluginOptions; emailField: AdminForthResourceColumn; passwordField: AdminForthResourceColumn; authResourceId: string; adminforth: IAdminForth; constructor(options: PluginOptions); modifyResourceConfig(adminforth: IAdminForth, resourceConfig: AdminForthResource): Promise; validateConfigAfterDiscover(adminforth: IAdminForth, resourceConfig: AdminForthResource): void; getAllowedOrigins(): string[]; /** * Short non-reversible digest of the user's current password hash. It is put into the reset token * and re-checked on confirm, so as soon as the password is changed (by this link or any other way) * every previously issued link for this user stops working, without relying on any storage. */ passwordHashDigest(passwordHash: string | null | undefined): string; /** * Same constraints which reset form checks on the frontend. Repeated here because the endpoint can be * called directly (e.g. from Postman), bypassing the form. */ validatePassword(password: string): string | null; normalizeEmail(email: string): string; instanceUniqueRepresentation(pluginOptions: any): string; setupEndpoints(server: IHttpServer): void; }