unjs / undocs

Minimal Documentation theme and CLI for shared usage across UnJS projects.
https://undocs.pages.dev/
MIT License
169 stars 13 forks source link

feat: Replaced dropdown with toc component #125

Closed itpropro closed 4 weeks ago

itpropro commented 5 months ago

Replaced dropdown with toc component to remove graphical glitches, improve usability and render sub headings.

cloudflare-workers-and-pages[bot] commented 5 months ago

Deploying undocs with  Cloudflare Pages  Cloudflare Pages

Latest commit: 7debcc0
Status: ✅  Deploy successful!
Preview URL: https://b7a11622.undocs.pages.dev
Branch Preview URL: https://feature-toc.undocs.pages.dev

View logs

itpropro commented 3 months ago

Hey @cpreston321 @pi0 anything that's blocking this from being merged? I think it's a very low hanging fruit for improving the UI in the docs ecosystem :)

pi0 commented 4 weeks ago

Sorry for late response @itpropro.

Actually it is part of new design that (similar to vue, vite docs) we have a compact and minimal TOC dropdown instead of sidebar.

One other reason was that we usually don't have a lot of headings (in current unjs project docs) and it was wasting sidebar.

How do you think? Maybe we can use a responsive method to only show it on larger screens?

pi0 commented 4 weeks ago

b3e97699f07c30ecf74d1c20e49f2b10c268d625 add sidebar TOC it in large screens