Implement AppLockScreen as per the designs. (#1925)

Fix a bug in the unlock flow
This commit is contained in:
Doug
2023-10-20 17:35:57 +01:00
committed by GitHub
parent d292fe890d
commit ceee6b1853
21 changed files with 378 additions and 85 deletions
@@ -67,8 +67,14 @@ class AppLockFlowCoordinator: CoordinatorProtocol {
}
private func applicationWillEnterForeground() {
guard appLockService.isEnabled, appLockService.computeNeedsUnlock(willEnterForegroundAt: .now) else { return }
showUnlockScreen()
guard appLockService.isEnabled else { return }
if appLockService.computeNeedsUnlock(willEnterForegroundAt: .now) {
showUnlockScreen()
} else {
// Reveal the app again if within the grace period.
actionsSubject.send(.unlockApp)
}
}
/// Displays the unlock flow with the app's placeholder view to hide obscure the view hierarchy in the app switcher.