Skip to content

fix(material/tabs): update tab nav bar focused index on direct focus #22584

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

Merged
merged 1 commit into from
Jun 22, 2021

Conversation

crisbeto
Copy link
Member

The tab nav bar allows navigation both through tabbing and keyboard events. This introduces a problem when the user tabs into it and then starts using the arrow keys, because the ListKeyManager state isn't up-to-date.

These changes add some logic to update the index when the tabs receives focus.

Fixes #22576.

The tab nav bar allows navigation both through tabbing and keyboard events. This introduces a problem when the user tabs into it and then starts using the arrow keys, because the `ListKeyManager` state isn't up-to-date.

These changes add some logic to update the index when the tabs receives focus.

Fixes angular#22576.
@crisbeto crisbeto added P3 An issue that is relevant to core functions, but does not impede progress. Important, but not urgent Accessibility This issue is related to accessibility (a11y) target: patch This PR is targeted for the next patch release labels Apr 28, 2021
@crisbeto crisbeto requested a review from andrewseguin April 28, 2021 16:09
@google-cla google-cla bot added the cla: yes PR author has agreed to Google's Contributor License Agreement label Apr 28, 2021
@andrewseguin andrewseguin added the action: merge The PR is ready for merge by the caretaker label May 4, 2021
Copy link
Contributor

@Splaktar Splaktar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@mmalerba mmalerba merged commit 40a3e16 into angular:master Jun 22, 2021
mmalerba pushed a commit that referenced this pull request Jun 22, 2021
…22584)

The tab nav bar allows navigation both through tabbing and keyboard events. This introduces a problem when the user tabs into it and then starts using the arrow keys, because the `ListKeyManager` state isn't up-to-date.

These changes add some logic to update the index when the tabs receives focus.

Fixes #22576.

(cherry picked from commit 40a3e16)
mmalerba pushed a commit that referenced this pull request Jun 22, 2021
…22584)

The tab nav bar allows navigation both through tabbing and keyboard events. This introduces a problem when the user tabs into it and then starts using the arrow keys, because the `ListKeyManager` state isn't up-to-date.

These changes add some logic to update the index when the tabs receives focus.

Fixes #22576.

(cherry picked from commit 40a3e16)
@angular-automatic-lock-bot
Copy link

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Jul 23, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Accessibility This issue is related to accessibility (a11y) action: merge The PR is ready for merge by the caretaker cla: yes PR author has agreed to Google's Contributor License Agreement P3 An issue that is relevant to core functions, but does not impede progress. Important, but not urgent target: patch This PR is targeted for the next patch release
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Tabs: Wrong navigate direction when navigate by switching between tab and arrow key
4 participants