@@ -44,7 +44,7 @@ import authgearCapacitor, {
4444 BiometricOptions ,
4545 BiometricAccessConstraintIOS ,
4646 BiometricLAPolicy ,
47- BiometricAccessConstraintAndroid ,
47+ BiometricAuthenticatorAndroid ,
4848 WebKitWebViewUIImplementation ,
4949 DeviceBrowserUIImplementation ,
5050} from "@authgear/capacitor" ;
@@ -76,15 +76,22 @@ const REDIRECT_URI_CAPACITOR = "com.authgear.exampleapp.capacitor://host/path";
7676const biometricOptions : BiometricOptions = {
7777 ios : {
7878 localizedReason : "Use biometric to authenticate" ,
79+ localizedCancelTitle : "Customized Cancel" ,
7980 constraint : BiometricAccessConstraintIOS . BiometryCurrentSet ,
8081 policy : BiometricLAPolicy . deviceOwnerAuthenticationWithBiometrics ,
8182 } ,
8283 android : {
8384 title : "Biometric Authentication" ,
8485 subtitle : "Biometric authentication" ,
8586 description : "Use biometric to authenticate" ,
86- negativeButtonText : "Cancel" ,
87- constraint : [ BiometricAccessConstraintAndroid . BiometricStrong ] ,
87+ negativeButtonText : "Customized Cancel" ,
88+ allowedAuthenticatorsOnEnable : [
89+ BiometricAuthenticatorAndroid . BiometricStrong ,
90+ ] ,
91+ allowedAuthenticatorsOnAuthenticate : [
92+ BiometricAuthenticatorAndroid . BiometricStrong ,
93+ BiometricAuthenticatorAndroid . DeviceCredential ,
94+ ] ,
8895 invalidatedByBiometricEnrollment : true ,
8996 } ,
9097} ;
0 commit comments