Skip to content

fix(docs): activate On this page scrollspy#27

Merged
vincentkoc merged 1 commit into
openclaw:mainfrom
vyctorbrzezowski:brzezowski/docs-toc-scrollspy
Jun 6, 2026
Merged

fix(docs): activate On this page scrollspy#27
vincentkoc merged 1 commit into
openclaw:mainfrom
vyctorbrzezowski:brzezowski/docs-toc-scrollspy

Conversation

@vyctorbrzezowski
Copy link
Copy Markdown
Contributor

Summary

  • add a scrollspy for the docs On this page links
  • keep exactly one TOC link active based on the current h2/h3 section
  • reinitialize the scrollspy after PJAX navigation swaps the main document content
  • keep the active TOC item in view when long TOC rails scroll internally

Screenshot

TOC scrollspy validation

Testing

  • git diff --check
  • npm run docs:build:preview
  • node --check scripts/docs-site/assets.mjs
  • node --check scripts/docs-site/smoke.mjs
  • node --check scripts/docs-site/visual-smoke.mjs
  • node --check dist/docs-site/assets/docs-site.js
  • manual browser verification on a long docs page

@vyctorbrzezowski vyctorbrzezowski force-pushed the brzezowski/docs-toc-scrollspy branch from 1ba0662 to d1ff6f0 Compare June 1, 2026 05:06
@vyctorbrzezowski vyctorbrzezowski marked this pull request as ready for review June 1, 2026 05:08
@vyctorbrzezowski vyctorbrzezowski requested a review from a team as a code owner June 1, 2026 05:08
@vincentkoc vincentkoc force-pushed the brzezowski/docs-toc-scrollspy branch from d1ff6f0 to 3f12520 Compare June 6, 2026 03:16
@vincentkoc vincentkoc merged commit 327fc44 into openclaw:main Jun 6, 2026
6 checks passed
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