Repository navigation
Conversation
Badge had four subtle variants and five outline variants. Add `subtle-neutral`, which reads the neutral roles like the other subtle variants read their intent roles. Refs tailor-inc/platform-planning#2210 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Contributor
Code Metrics Report
Details | | main (cc749d5) | #640 (fb39c88) | +/- |
|---------------------|----------------|----------------|------|
| Coverage | 89.3% | 89.3% | 0.0% |
| Files | 228 | 228 | 0 |
| Lines | 7241 | 7241 | 0 |
| Covered | 6471 | 6471 | 0 |
+ | Test Execution Time | 2m54s | 2m38s | -16s |Code coverage of files in pull request scope (100.0% → 100.0%)
Reported by octocov |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
Badgehas four subtle variants and five outline variants. There is nosubtle-neutral. The styling guide says tags usesubtle-*, but a tag with no status had no subtle variant.Closes tailor-inc/platform-planning#2210. Part of tailor-inc/platform-planning#2208.
What
subtle-neutral:bg-neutral-surface,text-neutral-textandhover:bg-neutral-surface-hover. The other subtle variants use the same three roles for their intent.subtle-neutralis added to the test that checks every semantic utility a variant uses is bridged.How it looks
Existing variants do not change. No snapshot changed.
Measured with
getComputedStylein the example app:neutralbackgroundsubtle-neutralbackgroundneutral/subtle-neutral)#f5f5f5#f5f5f5#171717/#0a0a0a#262626#262626#fafafa/#fafafargb(216, 217, 244)rgb(246, 242, 255)#171717/rgb(16, 18, 43)rgb(45, 48, 72)rgb(36, 39, 58)rgb(248, 249, 252)/ sameIn the default palette,
subtle-neutralhas the same background asneutral, because--mutedand--secondaryhave the same value. The hover colour is different (--accentinstead ofsecondary/80). Inbloom, and increamlight mode,--mutedis closer to the page background, sosubtle-neutralis quieter thanneutral. Increamdark mode the two values are almost the same.Text contrast on the subtle background is 14:1 or more, and 11:1 or more on hover, in default and bloom. The contrast test does not cover the neutral intent, the same as before.
Screenshots from the showcase page (
/showcase/primitives). The new variant is the last item in the Subtle row.Checks
fmt:check,lint,type-check,test(core: 2660 tests),docs:checkandbuildpass..astw\:bg-neutral-surface{background-color:var(--neutral-surface)}and the hover rule.🤖 Generated with Claude Code