chore(header): remove all dummy-targets and update smooth scroll

This commit is contained in:
Dillon
2020-02-16 16:42:14 +08:00
parent 4aac6b98a5
commit 69688661f4
11 changed files with 55 additions and 81 deletions

View File

@@ -32,7 +32,7 @@
}
@media only screen and (max-width: 960px) {
header.desktop {
#header-desktop {
.header-wrapper {
margin: 0 1rem;
}
@@ -52,11 +52,11 @@
}
@media only screen and (max-width: 560px) {
header.desktop {
#header-desktop {
display: none;
}
header.mobile {
#header-mobile {
display: block;
}

View File

@@ -54,13 +54,6 @@
@import "../_partial/_single/toc";
.content {
.post-dummy-target:target {
display: inline-block;
position: relative;
top: -5.6rem;
visibility: hidden;
}
h1,
h2,
h3,
@@ -75,17 +68,6 @@
}
}
h2::before,
h3::before,
h4::before,
h5::before,
h6::before {
display: block;
content: "";
height: 1.2 * $header-height;
margin: -1.2 * $header-height 0 0;
}
h2 > a:first-child::before {
content: "#";
margin-right: .3125rem;

View File

@@ -10,7 +10,7 @@ header {
}
}
header.desktop {
#header-desktop {
display: block;
z-index: 100;
@@ -45,7 +45,7 @@ header.desktop {
}
}
header.mobile {
#header-mobile {
display: none;
z-index: 100;
transition: all 0.3s ease 0s;