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

Update utilities #1630

Merged
merged 7 commits into from
Oct 8, 2021
Merged

Update utilities #1630

merged 7 commits into from
Oct 8, 2021

Conversation

simurai
Copy link
Contributor

@simurai simurai commented Oct 1, 2021

This updates the utilities.

  • The muted roles are now used for borders, instead of backgrounds
  • The neutral backgrounds are removed
  • The .color-bg-neutral-emphasis-plus got renamed to .color-bg-emphasis and is the replacement for .color-bg-canvas-inverse in v1
Backgrounds Borders
Screen Shot 2021-10-05 at 16 07 30 Screen Shot 2021-10-05 at 16 07 47

@changeset-bot
Copy link

changeset-bot bot commented Oct 1, 2021

🦋 Changeset detected

Latest commit: a8a9cba

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 Major

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

@simurai simurai requested a review from auareyou October 1, 2021 06:37
@simurai simurai marked this pull request as ready for review October 1, 2021 06:37
@simurai simurai requested a review from a team as a code owner October 1, 2021 06:37
@simurai simurai requested a review from colebemis October 1, 2021 06:37
@auareyou
Copy link
Contributor

auareyou commented Oct 1, 2021

Thanks @simurai - The only thing I'd change is I would remove 'subtle' and 'muted' from the naming in color role backgrounds and borders. For example:

.color-bg-accent
.color-bg-accent-emphasis

.color-border-accent
.color-border-accent-emphasis

This one folks don't need to guess what muted or subtle is, they'll just know it's not emphasis

Copy link
Contributor

@colebemis colebemis left a comment

Choose a reason for hiding this comment

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

@simurai
Copy link
Contributor Author

simurai commented Oct 4, 2021

The only thing I'd change is I would remove 'subtle' and 'muted' from the naming in color role backgrounds and borders.
This one folks don't need to guess what muted or subtle is, they'll just know it's not emphasis

Yeah, I was debating about that too. It would make it less verbose and without the bg -> subtle, border -> muted oddity. My thinking was that when seeing .color-bg-accent I'm less sure what to expect. But with .color-bg-accent-subtle I can guess only by the name that it will be a subtle/faded color.

Another point is that when searching for color-bg-accent the results will be mixed with color-bg-accent-emphasis. Like currently when searching for color-bg-info the color-bg-info-inverse will also show up.

Screen Shot 2021-10-04 at 11 58 23

There might be a regex for only finding color-bg-accent and excluding color-bg-accent-emphasis? /cc @jonrohan

Anyone else with strong opinions about it? Maybe @ashygee?

Copy link
Member

@jonrohan jonrohan left a comment

Choose a reason for hiding this comment

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

There might be a regex for only finding color-bg-accent and excluding color-bg-accent-emphasis?

You can regex search like this color-bg-accent[^-] where the last character would be anything except -.

@simurai
Copy link
Contributor Author

simurai commented Oct 5, 2021

You can regex search like this color-bg-accent[^-] where the last character would be anything except -.

Nice. Saved for later. 👍

@simurai
Copy link
Contributor Author

simurai commented Oct 5, 2021

@auareyou Ok, the utility names are now updated without the -subtle and -muted for backgrounds and borders.

Here a preview. 👀

@simurai simurai enabled auto-merge (squash) October 8, 2021 06:45
@simurai simurai merged commit 5f7bb45 into main Oct 8, 2021
@simurai simurai deleted the update-utilities branch October 8, 2021 06:46
@primer-css primer-css mentioned this pull request Oct 8, 2021
@simurai simurai mentioned this pull request Oct 8, 2021
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.

4 participants