feat(css): parameterize component sizing with scale tokens#8
Open
Reebz wants to merge 1 commit into
Open
Conversation
Retuning component density meant overriding hundreds of literal clamp() values. Add a :root scale-token ramp with a --scale multiplier and --max-content-width, reusing the orphaned ramp already sitting unused in viewport-base.css, and route the component sizes through it. Defaults reproduce today's sizing exactly, so --scale: 1 is a no-op. Co-Authored-By: Leslie Barbara Knope (Claude Opus 4.8 (1M context)) <noreply@anthropic.com>
|
@Reebz is attempting to deploy a commit to the bluedusk's projects Team on Vercel. A member of the Team first needs to authorize it. |
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.
What
Retuning component density meant overriding hundreds of literal
clamp()values across the component selectors.:rootscale-token ramp incomponents.cssadds a--scalemultiplier and a--max-content-width, reusing and extending the ramp already defined but never consumed inviewport-base.css.--scale: 1is a pixel-identical no-op, and an author retunes density by setting--scaleand--max-content-widthonce on.deckor:root.SKILL.mdgains a short note to prefer component classes over per-element inline font sizes, so the knob is not fought by inline styles.This is a parameterization refactor, not a restyle. Visual defaults are unchanged.
Test
--scale: 1, every component renders at its current size.--scaleenlarges titles, body, and stat numbers proportionally, and--max-content-widthnarrows or widens the constrained components.Dependencies
Touches
components.cssandviewport-base.css, so it is cleanest to merge after the responsive-presentation PR.Co-Authored-By: Leslie Barbara Knope (Claude Opus 4.8 (1M context)) noreply@anthropic.com