-
Notifications
You must be signed in to change notification settings - Fork 14
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Password manager: Fix tabbing between text fields #3724
base: main
Are you sure you want to change the base?
Password manager: Fix tabbing between text fields #3724
Conversation
Fix tabbing between text fields in the password manager by manually recalculating key view loop in PasswordManagementViewController. This isn't done automatically as MainWindow disables autorecalculatesKeyViewLoop. Fix tabbing in password manager by recalculating key view loop when replacing child view
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice work @noisysocks, this change works perfectly and is a great UX improvement, thank you!
I did notice that the call to recalculateKeyViewLoop()
triggers every time an item is selected, not just when adding a new item but from a performance perspective it doesn’t appear to have an impact so should be safe to leave as is 🙂
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If you feel inspired to also tackle tabbing between text fields when editing, I think the same fix should work if applied within this code block (around line 150 of this file) when isEditing == true
, but totally up to you!
editingCancellable = itemModel?.isEditingPublisher.sink(receiveValue: { [weak self] isEditing in
guard let self = self else { return }
self.isEditing = isEditing
self.divider.isHidden = isEditing
self.updateEmptyState(state: self.listModel?.emptyState)
self.searchField.isEditable = !isEditing
})
Yeah cool. I think conceptually it makes sense to recalculate the key view loop whenever a new item is selected since the new child view might (one day) have a different set of fields that can be tabbed between.
I’ll play with this! |
Hey @amddg44. What do you think of the alternative approach I just pushed up? Instead of having Doing it this way means the bug is fixed in more cases (including the one you spotted) and also lets me remove the call to Pretty rusty with macOS/iOS development so please let me know if I’m off piste here! |
Hey @noisysocks, I like this alternate approach! However hooking in on Some options from here could be to simply add in a throttling mechanism within the |
Oh and one minor note - can you please include any changes to |
Task/Issue URL: #3723
Description:
Fix tabbing between text fields in the password manager by manually recalculating key view loop in
PasswordManagementViewController
. This isn't done automatically asMainWindow
disablesautorecalculatesKeyViewLoop
.Optional E2E tests:
Check this to run the Personal Information Removal end to end tests. If updating CCF, or any PIR related code, tick this.
Steps to test this PR:
Definition of Done:
Internal references:
Pull Request Review Checklist
Software Engineering Expectations
Technical Design Template
Pull Request Documentation