Closed blopker closed 6 months ago
Hey, thanks for this theme, it looks great. I saw the issue where the ToC links scroll too far. There's a handy CSS rule now that fixes that: scroll-padding-top: <value>; (https://developer.mozilla.org/en-US/docs/Web/CSS/scroll-padding-top)
scroll-padding-top: <value>;
Basically you'd just need to add it to the html selector in global.css:
html
global.css
html { overflow-y: auto; color-scheme: light; + scroll-padding-top: 200px; }
Now anchor links will always stop at 200px below the top of the viewport. This doesn't affect any of the padding on the page.
Thank you!!
Hey, thanks for this theme, it looks great. I saw the issue where the ToC links scroll too far. There's a handy CSS rule now that fixes that:
scroll-padding-top: <value>;
(https://developer.mozilla.org/en-US/docs/Web/CSS/scroll-padding-top)Basically you'd just need to add it to the
html
selector inglobal.css
:Now anchor links will always stop at 200px below the top of the viewport. This doesn't affect any of the padding on the page.