mirror of
https://github.com/ChenQihan666/MyBlog-Next.git
synced 2026-08-14 11:01:42 +08:00
fix: add scroll offset for anchor targets (#506)
* fix: add scroll offset for anchor targets * fix: update scroll-margin-block to 1rem --------- Co-authored-by: satnaing <satnaingdev@gmail.com>
This commit is contained in:
@@ -57,3 +57,9 @@ html[data-theme="dark"] {
|
|||||||
.active-nav {
|
.active-nav {
|
||||||
@apply underline decoration-wavy decoration-2 underline-offset-4;
|
@apply underline decoration-wavy decoration-2 underline-offset-4;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Source: https://piccalil.li/blog/a-more-modern-css-reset/ */
|
||||||
|
/* Anything that has been anchored to should have extra scroll margin */
|
||||||
|
:target {
|
||||||
|
scroll-margin-block: 1rem;
|
||||||
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user