Skip to content

Commit

Permalink
focus on textfield if password flow is in confirm state
Browse files Browse the repository at this point in the history
  • Loading branch information
svojsu committed Aug 9, 2024
1 parent 0e44c5a commit fd85f20
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 fd85f20

Please sign in to comment.