Skip to content

docs(focus indicators): Add documentation for focus indicators. #18724

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

Closed
wants to merge 3 commits into from

Conversation

zelliott
Copy link
Collaborator

@zelliott zelliott commented Mar 5, 2020

No description provided.

@googlebot googlebot added the cla: yes PR author has agreed to Google's Contributor License Agreement label Mar 5, 2020
// Including this mixin will theme the focus indicators.
// This mixin can be included multiple times throughout your app
// to change the focus indicator's color.
@include mat-strong-focus-indicators-theme($theme-or-color);
Copy link
Member

Choose a reason for hiding this comment

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

Maybe we should use an actual color here like the other examples in this doc?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Good idea, added an actual color.

@@ -251,3 +251,27 @@ function changeTheme(themeName) {
### Theming your own components
For more details about theming your own components,
see [theming-your-components.md](./theming-your-components.md).

### Showing strong focus indicators
Angular Material has built-in support for showing **strong focus indicators** on all components. Focus indicators are visual markers that show users which element is focused. Angular Material's strong focus indicators render as highly visible outlines around elements.
Copy link
Member

Choose a reason for hiding this comment

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

The sentence starting with "Focus indicators..." sounds like it's referring to focus indicators in general, not the strong ones. Maybe we should be more explicit?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

This is purposeful because by "focus indicators" I meant either Material's current focus styles or these new strong ones. Either way, they are visual markers that show users which element is focused. I was also back-and-forth on just removing this sentence if it is just going to cause more confusion.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I ended up just removing this sentence.

@@ -251,3 +251,27 @@ function changeTheme(themeName) {
### Theming your own components
For more details about theming your own components,
see [theming-your-components.md](./theming-your-components.md).

Copy link
Member

Choose a reason for hiding this comment

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

Should we mention the mat-focus-indicator class somewhere?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Added a sentence & example towards the end, let me know if you had something else in mind.

@jelbourn
Copy link
Member

Closing this since docs were added in #22374

(I hadn't realized at the time there was an existing PR)

@jelbourn jelbourn closed this Apr 13, 2021
@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 May 14, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
cla: yes PR author has agreed to Google's Contributor License Agreement
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants