style: make sidebars sticky
Description
Make sidebars "sticky" to the browser top, making it accessible when scrolled partially or entirely down the page
Validation
When scrolling down the page, sidebars should remain visible:
On mobile, layout should be unaffected:
Related Issues
Addresses #7122
Check List
- [x] I have read the Contributing Guidelines and made commit messages that follow the guideline.
- [x] I have run
npm run formatto ensure the code follows the style guide. - [x] I have run
npm run testto check if all tests are passing. - [x] I have run
npx turbo buildto check if the website builds without errors. - [ ] I've covered new added functionality with unit tests if necessary.
The latest updates on your projects. Learn more about Vercel for Git ↗︎
| Name | Status | Preview | Updated (UTC) |
|---|---|---|---|
| nodejs-org | ✅ Ready (Inspect) | Visit Preview | Oct 29, 2024 11:17pm |
I'm not sure that I like how the left sidebar is also sticky. It means we need to scroll down to the bottom of every page to see the Modules/Diagnostics/Test Runner pages. Would be interested to hear others thoughts
I don't think this is a good change, sorry. The current layout is more suited for our needs. Thanks for the contribution tho!
the original issue was just to put the ToC in sticky so that it's always handy in the desktop. Which I don't think is too bad, but I don't think the lef nav should be stiky.
That's fair. Updated to only make the Metabar sticky, but not the other bars
Lighthouse Results
| URL | Performance | Accessibility | Best Practices | SEO | Report |
|---|---|---|---|---|---|
| /en | 🟢 99 | 🟢 100 | 🟢 100 | 🟢 91 | 🔗 |
| /en/about | 🟢 100 | 🟢 100 | 🟢 100 | 🟢 91 | 🔗 |
| /en/about/previous-releases | 🟢 99 | 🟢 100 | 🟢 100 | 🟢 92 | 🔗 |
| /en/download | 🟢 100 | 🟢 100 | 🟢 96 | 🟢 91 | 🔗 |
| /en/blog | 🟢 100 | 🟢 100 | 🟢 100 | 🟢 92 | 🔗 |
Unit Test Coverage Report
| Lines | Statements | Branches | Functions |
|---|---|---|---|
| 90.32% (588/651) | 75.43% (175/232) | 94.35% (117/124) |
Unit Test Report
| Tests | Skipped | Failures | Errors | Time |
|---|---|---|---|---|
| 131 | 0 :zzz: | 0 :x: | 0 :fire: | 5.638s :stopwatch: |
Thanks for the contribution ✨ -- appreciate your time!