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

Separate active and selected states for .btn #1297

Merged
merged 10 commits into from
Apr 6, 2021
Merged

Separate active and selected states for .btn #1297

merged 10 commits into from
Apr 6, 2021

Conversation

simurai
Copy link
Contributor

@simurai simurai commented Apr 2, 2021

This came up in Slack.

Currently the :active state for .btns use the same colors as the aria-selected=true state. The selected state should be easily visible when in a button group:

image

But that might be too big of a difference when clicking/pressing on the button. So this PR separates the :active and aria-selected=true state so they can have different colors. Here how the :active state looks in all themes:

button

TODO:

@vdepizzol I think you like the btn btn-octicon combo. Should we document that and make it an "approved" option how .btn-octicon can be used.

@changeset-bot
Copy link

changeset-bot bot commented Apr 2, 2021

🦋 Changeset detected

Latest commit: 6e9a4bb

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@primer/css Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@vercel
Copy link

vercel bot commented Apr 2, 2021

This pull request is being automatically deployed with Vercel (learn more).
To see the status of your deployment, click below or on the icon next to each commit.

🔍 Inspect: https://vercel.com/primer/primer-css/Heko46bd1grbd4GdfFqaFzobDvwv
✅ Preview: https://primer-css-git-btn-active-primer.vercel.app

@vercel vercel bot temporarily deployed to Preview April 2, 2021 11:10 Inactive
@vercel vercel bot temporarily deployed to Preview April 2, 2021 17:36 Inactive
@vercel vercel bot temporarily deployed to Preview April 2, 2021 18:29 Inactive
@vdepizzol
Copy link
Contributor

@vdepizzol I think you like the btn btn-octicon combo. Should we document that and make it an "approved" option how .btn-octicon can be used.

@simurai let's chat about my explorations with button styles and ActionBar!

@vercel vercel bot temporarily deployed to Preview April 6, 2021 07:23 Inactive
@vercel vercel bot temporarily deployed to Preview April 6, 2021 07:31 Inactive
@simurai simurai marked this pull request as ready for review April 6, 2021 09:21
@vercel vercel bot temporarily deployed to Preview April 6, 2021 12:39 Inactive
@vercel vercel bot temporarily deployed to Preview April 6, 2021 15:21 Inactive
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants