Add missing biometry type. (#2148)
This commit is contained in:
@@ -21,36 +21,28 @@ extension LABiometryType {
|
||||
/// The SF Symbol that represents the biometry type.
|
||||
var systemSymbol: SFSymbol {
|
||||
switch self {
|
||||
case .none:
|
||||
MXLog.error("Invalid presentation: Biometrics not supported.")
|
||||
return .viewfinder
|
||||
case .touchID:
|
||||
return .touchid
|
||||
case .faceID:
|
||||
return .faceid
|
||||
// Requires Xcode 15:
|
||||
// case .opticID:
|
||||
// .opticid
|
||||
@unknown default:
|
||||
return .viewfinder
|
||||
case .none: {
|
||||
MXLog.error("Invalid presentation: Biometrics not supported.")
|
||||
return .viewfinder
|
||||
}()
|
||||
case .touchID: .touchid
|
||||
case .faceID: .faceid
|
||||
case .opticID: SFSymbol(rawValue: "opticid")
|
||||
@unknown default: .viewfinder
|
||||
}
|
||||
}
|
||||
|
||||
/// The localized string for the biometry type.
|
||||
var localizedString: String {
|
||||
switch self {
|
||||
case .none:
|
||||
MXLog.error("Invalid presentation: Biometrics not supported.")
|
||||
return L10n.screenAppLockBiometricUnlock
|
||||
case .touchID:
|
||||
return L10n.commonTouchIdIos
|
||||
case .faceID:
|
||||
return L10n.commonFaceIdIos
|
||||
// Requires Xcode 15:
|
||||
// case .opticID:
|
||||
// L10n.commonOpticIdIos
|
||||
@unknown default:
|
||||
return L10n.screenAppLockBiometricUnlock
|
||||
case .none: {
|
||||
MXLog.error("Invalid presentation: Biometrics not supported.")
|
||||
return L10n.screenAppLockBiometricUnlock
|
||||
}()
|
||||
case .touchID: L10n.commonTouchIdIos
|
||||
case .faceID: L10n.commonFaceIdIos
|
||||
case .opticID: L10n.commonOpticIdIos
|
||||
@unknown default: L10n.screenAppLockBiometricUnlock
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user