UNPKG

@phemium-costaisa/fingerprint-auth

Version:

Automatic plugin to work with FaceID and TouchID authentication

46 lines (45 loc) 1.77 kB
import { BiometricsAvailable } from "./fingerprint.service"; export declare class FingerprintMockService { /** * Use this method in Login page to check if user * should be redirected to the Biometric Activator */ checkIfNeedsBiometric(user: string): Promise<boolean>; /** * Use in Login page to show the Biometric Activator page * @param user User * @param password Password * @param callbackUrl URL to return after success or fail */ showBiometricActivator(user: string, password: string, callbackUrl: string): void; /** * Use in Login page to open Biometric prompt * @param user string */ showBiometricPrompt(user: string): Promise<{ user: string; password: any; }>; /** * Checks and returns which biometrics methods are available * for the current device * @returns Promise<Biometric[]> */ retrieveDeviceBiometrics(): Promise<BiometricsAvailable>; /** * Shows the FaceID dialog to the user * @param user Client user * @returns Promise<void> */ activateFaceID(user: string, password: string): Promise<void>; /** * Shows the TouchID dialog to the user * @param user Client user * @param password Client password */ activateTouchID(user: string, password: string): void; isBiometricActive(user: string, biometricType: keyof BiometricsAvailable): Promise<any>; clearBiometricData(user: string, biometricType: keyof BiometricsAvailable): Promise<void>; disableBiometricData(user: string, biometricType: keyof BiometricsAvailable): Promise<void>; showFingerprintId(user: string, biometricType: keyof BiometricsAvailable): import("rxjs").Observable<boolean>; }