Skip to content

Auto-expand/collapse nav items + some other improvements #992

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

Merged
merged 5 commits into from
Jun 26, 2025

Conversation

benface
Copy link
Contributor

@benface benface commented Jun 26, 2025

This PR squashes a few TODOs that existed in the code, notably these:

TODOs about the navigation system:

  • Auto-expand the current item's ancestors on load and when the route changes
  • Remember which groups/items are expanded at every level, so that closing and re-expanding an ancestor doesn't affect its children's state
  • Remember if groups/items were manually expanded (with the caret) or auto-expanded (either by clicking on its title or by navigating to it or one of its children), then auto-close those that were auto-expanded when the user navigates to a different group/item

It also updates dependencies (notably Prettier, hence the large number of files changed – sorry), tweaks the Callout styles (thanks @0xa3k5), replaces ✅ emojis with GDS (phosphor) check icons (thanks @hayderkg), and colocates our custom MDX (rehype and remark) plugins in the website package, as they were already tightly coupled to it (I converted them to TS while I was at it).

@benface benface marked this pull request as ready for review June 26, 2025 15:07
@benface benface requested a review from a team as a code owner June 26, 2025 15:07
@benface benface changed the title Auto-expand/collapse nav items Auto-expand/collapse nav items + some other improvements Jun 26, 2025
Copy link
Member

@0xa3k5 0xa3k5 left a comment

Choose a reason for hiding this comment

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

❤️

@benface benface merged commit 391a7d0 into main Jun 26, 2025
4 checks passed
@benface benface deleted the benface/nav-improvements branch June 26, 2025 15:40
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