Skip to content

Commit

Permalink
Merge pull request #1184 from novasamatech/fix/focus-password-textfie…
Browse files Browse the repository at this point in the history
…ld-on-confirm

Focus on the textfield if the password flow is in the confirmation state
  • Loading branch information
svojsu authored Aug 9, 2024
2 parents 0e44c5a + fd85f20 commit c1d7d8b
Showing 1 changed file with 6 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ final class CloudBackupCreateViewController: UIViewController, ViewHolder {
super.viewDidAppear(animated)

presenter.activateOnAppear()
preparePasswordView()
}

private func setupHandlers() {
Expand Down Expand Up @@ -105,6 +106,11 @@ final class CloudBackupCreateViewController: UIViewController, ViewHolder {
rootView.passwordView.textField.attributedPlaceholder = passwordPlaceholder
}

func preparePasswordView() {
guard flow == .confirmPassword else { return }
rootView.passwordView.textField.becomeFirstResponder()
}

@objc func actionContinue() {
presenter.activateContinue()
}
Expand Down

0 comments on commit c1d7d8b

Please sign in to comment.