Skip to content
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

fix(checkbox): redirect focus to underlying input element #13959

Merged
merged 1 commit into from
Dec 7, 2018

Conversation

crisbeto
Copy link
Member

@crisbeto crisbeto commented Nov 3, 2018

Currently the mat-checkbox host element isn't focusable, which means that if consumers decided to use something like cdkFocusInitial on it, nothing would happen. These changes tweak the tabindex so the element is focusable and add a focus listener that'll redirect focus to the input.

Relates to #13953.

@crisbeto crisbeto added Accessibility This issue is related to accessibility (a11y) target: patch This PR is targeted for the next patch release labels Nov 3, 2018
@googlebot googlebot added the cla: yes PR author has agreed to Google's Contributor License Agreement label Nov 3, 2018
Copy link
Member

@josephperrott josephperrott left a comment

Choose a reason for hiding this comment

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

LGTM

@josephperrott josephperrott added pr: lgtm action: merge The PR is ready for merge by the caretaker labels Nov 5, 2018
Copy link
Member

@jelbourn jelbourn left a comment

Choose a reason for hiding this comment

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

LGTM

Currently the `mat-checkbox` host element isn't focusable, which means that if consumers decided to use something like `cdkFocusInitial` on it, nothing would happen. These changes tweak the `tabindex` so the element is focusable and add a `focus` listener that'll redirect focus to the `input`.

Relates to angular#13953.
@crisbeto crisbeto force-pushed the 13953/checkbox-focus-redirect branch from b2f4d57 to 24e163c Compare November 9, 2018 09:30
@mmalerba mmalerba merged commit e0eb3df into angular:master Dec 7, 2018
mmalerba pushed a commit that referenced this pull request Dec 10, 2018
Currently the `mat-checkbox` host element isn't focusable, which means that if consumers decided to use something like `cdkFocusInitial` on it, nothing would happen. These changes tweak the `tabindex` so the element is focusable and add a `focus` listener that'll redirect focus to the `input`.

Relates to #13953.
mmalerba added a commit that referenced this pull request Dec 11, 2018
mmalerba added a commit that referenced this pull request Dec 11, 2018
mmalerba added a commit that referenced this pull request Dec 11, 2018
…from ListKeyManager" (#14467)

* Revert "build: update sauce connect (#14422)"

This reverts commit bc563b7.

* Revert "build: changelog script not filtering duplicate entries (#14421)"

This reverts commit fe46290.

* Revert "build: update to angular 7.1.2 (#14418)"

This reverts commit e1487df.

* Revert "refactor(drag-drop): move logic out of directives (#14350)"

This reverts commit 19f9bca.

* Revert "fix(checkbox): redirect focus to underlying input element (#13959)"

This reverts commit e0eb3df.

* Revert "fix(radio): host element unable to receive focus events (#13956)"

This reverts commit 41eb27e.

* Revert "fix(a11y): activeItem out of date if active index is removed from ListKeyManager (#14407)"

This reverts commit 014dc79.
mmalerba added a commit that referenced this pull request Dec 11, 2018
mmalerba added a commit that referenced this pull request Dec 11, 2018
)

* Revert "Revert "fix(a11y): activeItem out of date if active index is removed from ListKeyManager" (#14467)"

This reverts commit 8f790f5.

* Revert "build: update sauce connect (#14422)"

This reverts commit bc563b7.

* Revert "build: changelog script not filtering duplicate entries (#14421)"

This reverts commit fe46290.

* Revert "build: update to angular 7.1.2 (#14418)"

This reverts commit e1487df.

* Revert "refactor(drag-drop): move logic out of directives (#14350)"

This reverts commit 19f9bca.

* Revert "fix(checkbox): redirect focus to underlying input element (#13959)"

This reverts commit e0eb3df.

* Revert "fix(radio): host element unable to receive focus events (#13956)"

This reverts commit 41eb27e.
mmalerba added a commit that referenced this pull request Dec 11, 2018
…14469)

* Revert "Revert "fix(radio): host element unable to receive focus events" (#14468)"

This reverts commit 4aa47c7.

* Revert "Revert "fix(a11y): activeItem out of date if active index is removed from ListKeyManager" (#14467)"

This reverts commit 8f790f5.

* Revert "build: update sauce connect (#14422)"

This reverts commit bc563b7.

* Revert "build: changelog script not filtering duplicate entries (#14421)"

This reverts commit fe46290.

* Revert "build: update to angular 7.1.2 (#14418)"

This reverts commit e1487df.

* Revert "refactor(drag-drop): move logic out of directives (#14350)"

This reverts commit 19f9bca.

* Revert "fix(checkbox): redirect focus to underlying input element (#13959)"

This reverts commit e0eb3df.
mmalerba added a commit that referenced this pull request Dec 11, 2018
…from ListKeyManager" (#14467)

* Revert "build: update sauce connect (#14422)"

This reverts commit bc563b7.

* Revert "build: changelog script not filtering duplicate entries (#14421)"

This reverts commit fe46290.

* Revert "build: update to angular 7.1.2 (#14418)"

This reverts commit e1487df.

* Revert "refactor(drag-drop): move logic out of directives (#14350)"

This reverts commit 19f9bca.

* Revert "fix(checkbox): redirect focus to underlying input element (#13959)"

This reverts commit e0eb3df.

* Revert "fix(radio): host element unable to receive focus events (#13956)"

This reverts commit 41eb27e.

* Revert "fix(a11y): activeItem out of date if active index is removed from ListKeyManager (#14407)"

This reverts commit 014dc79.
mmalerba added a commit that referenced this pull request Dec 11, 2018
)

* Revert "Revert "fix(a11y): activeItem out of date if active index is removed from ListKeyManager" (#14467)"

This reverts commit 8f790f5.

* Revert "build: update sauce connect (#14422)"

This reverts commit bc563b7.

* Revert "build: changelog script not filtering duplicate entries (#14421)"

This reverts commit fe46290.

* Revert "build: update to angular 7.1.2 (#14418)"

This reverts commit e1487df.

* Revert "refactor(drag-drop): move logic out of directives (#14350)"

This reverts commit 19f9bca.

* Revert "fix(checkbox): redirect focus to underlying input element (#13959)"

This reverts commit e0eb3df.

* Revert "fix(radio): host element unable to receive focus events (#13956)"

This reverts commit 41eb27e.
mmalerba added a commit that referenced this pull request Dec 11, 2018
…14469)

* Revert "Revert "fix(radio): host element unable to receive focus events" (#14468)"

This reverts commit 4aa47c7.

* Revert "Revert "fix(a11y): activeItem out of date if active index is removed from ListKeyManager" (#14467)"

This reverts commit 8f790f5.

* Revert "build: update sauce connect (#14422)"

This reverts commit bc563b7.

* Revert "build: changelog script not filtering duplicate entries (#14421)"

This reverts commit fe46290.

* Revert "build: update to angular 7.1.2 (#14418)"

This reverts commit e1487df.

* Revert "refactor(drag-drop): move logic out of directives (#14350)"

This reverts commit 19f9bca.

* Revert "fix(checkbox): redirect focus to underlying input element (#13959)"

This reverts commit e0eb3df.
josephperrott pushed a commit to josephperrott/components that referenced this pull request Jan 14, 2019
)

Currently the `mat-checkbox` host element isn't focusable, which means that if consumers decided to use something like `cdkFocusInitial` on it, nothing would happen. These changes tweak the `tabindex` so the element is focusable and add a `focus` listener that'll redirect focus to the `input`.

Relates to angular#13953.
josephperrott pushed a commit to josephperrott/components that referenced this pull request Jan 14, 2019
…from ListKeyManager" (angular#14467)

* Revert "build: update sauce connect (angular#14422)"

This reverts commit bc563b7.

* Revert "build: changelog script not filtering duplicate entries (angular#14421)"

This reverts commit fe46290.

* Revert "build: update to angular 7.1.2 (angular#14418)"

This reverts commit e1487df.

* Revert "refactor(drag-drop): move logic out of directives (angular#14350)"

This reverts commit 19f9bca.

* Revert "fix(checkbox): redirect focus to underlying input element (angular#13959)"

This reverts commit e0eb3df.

* Revert "fix(radio): host element unable to receive focus events (angular#13956)"

This reverts commit 41eb27e.

* Revert "fix(a11y): activeItem out of date if active index is removed from ListKeyManager (angular#14407)"

This reverts commit 014dc79.
josephperrott pushed a commit to josephperrott/components that referenced this pull request Jan 14, 2019
…ular#14468)

* Revert "Revert "fix(a11y): activeItem out of date if active index is removed from ListKeyManager" (angular#14467)"

This reverts commit 8f790f5.

* Revert "build: update sauce connect (angular#14422)"

This reverts commit bc563b7.

* Revert "build: changelog script not filtering duplicate entries (angular#14421)"

This reverts commit fe46290.

* Revert "build: update to angular 7.1.2 (angular#14418)"

This reverts commit e1487df.

* Revert "refactor(drag-drop): move logic out of directives (angular#14350)"

This reverts commit 19f9bca.

* Revert "fix(checkbox): redirect focus to underlying input element (angular#13959)"

This reverts commit e0eb3df.

* Revert "fix(radio): host element unable to receive focus events (angular#13956)"

This reverts commit 41eb27e.
josephperrott pushed a commit to josephperrott/components that referenced this pull request Jan 14, 2019
…ngular#14469)

* Revert "Revert "fix(radio): host element unable to receive focus events" (angular#14468)"

This reverts commit 4aa47c7.

* Revert "Revert "fix(a11y): activeItem out of date if active index is removed from ListKeyManager" (angular#14467)"

This reverts commit 8f790f5.

* Revert "build: update sauce connect (angular#14422)"

This reverts commit bc563b7.

* Revert "build: changelog script not filtering duplicate entries (angular#14421)"

This reverts commit fe46290.

* Revert "build: update to angular 7.1.2 (angular#14418)"

This reverts commit e1487df.

* Revert "refactor(drag-drop): move logic out of directives (angular#14350)"

This reverts commit 19f9bca.

* Revert "fix(checkbox): redirect focus to underlying input element (angular#13959)"

This reverts commit e0eb3df.
@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 Sep 10, 2019
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 target: patch This PR is targeted for the next patch release
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants