🚀 refactor: toc component with responsive design

- Implement scroll-sync highlight tracking
- Add auto-scroll functionality for active items
- Remove animations during view transitions
This commit is contained in:
radishzzz 2025-03-31 16:05:46 +01:00
parent 4c8dff619e
commit 7c6172e0ae
5 changed files with 449 additions and 309 deletions

View file

@ -93,4 +93,10 @@ document.addEventListener('astro:after-swap', setupScrollbar)
--os-handle-bg-active: oklch(var(--un-preset-theme-colors-secondary) / 0.35);
--os-handle-min-size: 12%;
}
@media (min-width: 1536px) {
#toc-content .os-scrollbar {
--at-apply: 'hidden';
}
}
</style>