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

Add outline to toolbar buttons #6313

Merged
merged 10 commits into from
Oct 2, 2024
Merged

Add outline to toolbar buttons #6313

merged 10 commits into from
Oct 2, 2024

Conversation

JeffersonBledsoe
Copy link
Member

@JeffersonBledsoe JeffersonBledsoe commented Sep 24, 2024

Fixes #6311

Current progress

Screenshot 2024-09-24 at 16 56 59 Screenshot 2024-09-24 at 16 59 54

@JeffersonBledsoe JeffersonBledsoe changed the title Add outline to toolbar buttons WIP: Add outline to toolbar buttons Sep 24, 2024
@JeffersonBledsoe JeffersonBledsoe marked this pull request as draft September 24, 2024 14:46
Copy link

netlify bot commented Sep 24, 2024

Deploy Preview for plone-components canceled.

Name Link
🔨 Latest commit 8acc150
🔍 Latest deploy log https://app.netlify.com/sites/plone-components/deploys/66fab09d9e7a6a00082bf851

@JeffersonBledsoe JeffersonBledsoe changed the title WIP: Add outline to toolbar buttons Add outline to toolbar buttons Sep 25, 2024
@JeffersonBledsoe JeffersonBledsoe marked this pull request as ready for review September 25, 2024 08:03
@JeffersonBledsoe
Copy link
Member Author

@ichim-david Checks all green now. Not sure if this needs design input from anybody else but it's ready for merging from my perspective

@JeffersonBledsoe JeffersonBledsoe requested a review from a team September 26, 2024 08:39
@Wagner3UB Wagner3UB self-requested a review September 27, 2024 13:37
@pnicolli
Copy link
Contributor

A behavior that I have recently seen in good component libraries is to only add the outline when navigating with the keyboard, while avoiding it when clicking things, because that's redundant. I haven't looked into how to do that, but I think it would be a nice improvement here.

@ichim-david
Copy link
Member

A behavior that I have recently seen in good component libraries is to only add the outline when navigating with the keyboard, while avoiding it when clicking things, because that's redundant. I haven't looked into how to do that, but I think it would be a nice improvement here.

@JeffersonBledsoe this is why we had focus-visible selector instead of simply focus to ensure the outline shows up when using the keyboard navigation. I would set it back as well to avoid outlines when mouse clicking

@JeffersonBledsoe
Copy link
Member Author

Agreed on using focus-visible! I can't remember the reasoning why I removed it initially, but I've added it back. From a quick glance, every browser we support for the editor also has support for focus-visible so no need to provide any fallback for older browsers

Copy link
Member

@sneridagh sneridagh left a comment

Choose a reason for hiding this comment

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

LGTM if someone promises me no outline will show when clicking 😂

@sneridagh sneridagh merged commit 913a084 into main Oct 2, 2024
70 checks passed
@sneridagh sneridagh deleted the sidebar-button-focus-outline branch October 2, 2024 20:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Toolbar buttons don't provide a focus outline [SC 2.4.7]
6 participants