Skip to content

fix(sidebar): align siblings' text, control indent directly#1329

Merged
LeoMcA merged 2 commits intomainfrom
1311-indent-control
Mar 12, 2026
Merged

fix(sidebar): align siblings' text, control indent directly#1329
LeoMcA merged 2 commits intomainfrom
1311-indent-control

Conversation

@LeoMcA
Copy link
Member

@LeoMcA LeoMcA commented Feb 25, 2026

Best effort attempt at fixing #1311 given the universal feedback on #1311 (comment) to go with the indent-all option.

This takes that approach - which ensures hierarchical consistency across each level (including the root) - and makes it better:

  • Adds a variable controlling the indent level, which automatically resizes the chevron to match
  • Saves some space around the chevron icon by cropping it slightly - ensuring the left edge of the chevron itself, not its containing box, is aligned with its parent's text
  • Indents lists with no <details> element in it slightly less: this ends up looking visually more consistent, and saves space

With all this, despite the increase in base padding to make everything align on the root level, we actually increase the space available for text compared to main.

Before After
1-main 1-1311-indent-control
2-main 2-1311-indent-control
3-main 3-1311-indent-control
4-main 4-1311-indent-control

@LeoMcA LeoMcA requested a review from a team as a code owner February 25, 2026 11:36
@LeoMcA LeoMcA requested review from globau and removed request for globau February 25, 2026 11:36
@github-actions
Copy link
Contributor

github-actions bot commented Feb 25, 2026

1d6afc9 was deployed to: https://fred-pr1329.review.mdn.allizom.net/

Co-authored-by: Claas Augner <495429+caugner@users.noreply.github.com>
@LeoMcA LeoMcA enabled auto-merge (squash) March 12, 2026 17:55
@LeoMcA LeoMcA merged commit 7b9c00d into main Mar 12, 2026
13 checks passed
@LeoMcA LeoMcA deleted the 1311-indent-control branch March 12, 2026 18:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants