Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

在页面内跳转时,跳转到的内容被 Header 遮挡 #771

Open
BeiyanYunyi opened this issue Mar 25, 2023 · 0 comments
Open

在页面内跳转时,跳转到的内容被 Header 遮挡 #771

BeiyanYunyi opened this issue Mar 25, 2023 · 0 comments
Assignees

Comments

@BeiyanYunyi
Copy link
Member

算是一个稍微有点影响体验的细节,查看注释再跳回去的时候会触发。解决方案(CSS)如下:

:target {
  scroll-margin-top: 50px; /* 当前 MtF.wiki 的 Header 高度 */
}

因为懒得录 GIF 所以可能表述不太清楚,可以参考 MDN 的相关条目

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Todo
Development

No branches or pull requests

3 participants