Repository navigation
feat(website): flat sidebar rows, and a band for the open page - #427
Open
IanoNjuguna wants to merge 1 commit into
Open
IanoNjuguna wants to merge 1 commit into
IanoNjuguna wants to merge 1 commit into
Conversation
…page Replaces 248 lines of !important overrides with 88 token-driven ones. The active row is a surface band plus a 2px brand rule with ink text instead of a colour change, rows are square and flush, and hover tints at 5% ink so a row responds before it is clicked. Two knobs carry the open decisions: --sidebar-row-weight (400, set 500 for the reference weight) and --sidebar-row-radius (0, set 4px for the old chip). Also fixes a latent bug this exposed: Infima's .menu__caret::before arrow only stayed hidden because the old block neutered it with background: transparent !important. It is now hidden explicitly, so each category draws one chevron.
This branch has not been deployed
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.
Description
One file.
website/src/css/custom.cssloses 209 lines of!importantoverrides and gains 60 token-driven ones.The open page is now marked the way docs.logos.co marks it, which is the same Docusaurus version and the same Infima markup: a surface band plus a thin rule, with the label staying ink. Until now it was a colour change, blue text and a 3px blue rule on a transparent fill, which reads as a link rather than a location.
Measured after the change, light theme:
The two judgement calls are variables rather than decisions baked into the CSS:
Fixes #426.
Type of Change
Testing
Checklist
Verification
Built and served, then measured in the browser at 1280 in both themes, with the hover and active states driven rather than eyeballed. Three-way comparison of before, weight 500 and weight 400:
Light and dark both carry: band distinguishable from the page, blue rule visible, ink label at a single weight, one chevron per category, unchanged 4px rhythm between rows.
Notes
DocSidebarItem/Category, and Infima's.menu__caret::before. The pseudo-arrow had only been hidden because the old CSS setbackground: transparent !importanton it. It is nowdisplay: noneexplicitly, and the swizzled SVG carries the hover and rotation easing.border-colornow transitions withbackgroundat 180mscubic-bezier(.2,.7,.2,1), so the rule moves with the fill instead of snapping. Hover tints at 5% ink, which the previous design had as a no-op.sidebar_labelfrontmatter per page and belongs in its own change; the issue says so.