1
0
mirror of https://github.com/thangisme/notes.git synced 2024-11-17 23:35:55 -05:00

Anchor heading css

This commit is contained in:
Patrick Marsceill 2019-08-13 16:23:38 -04:00
parent 8d60dda67e
commit 15f1faae8a
No known key found for this signature in database
GPG Key ID: 286B93882D828F40
2 changed files with 30 additions and 12 deletions

View File

@ -1,12 +0,0 @@
a.anchor_heading {
visibility: hidden;
}
h1:hover > a.anchor_heading,
h2:hover > a.anchor_heading,
h3:hover > a.anchor_heading,
h4:hover > a.anchor_heading,
h5:hover > a.anchor_heading,
h6:hover > a.anchor_heading {
visibility: visible;
}

View File

@ -111,4 +111,34 @@
margin-left: 1em;
font-weight: 500;
}
.anchor-heading {
fill: $link-color;
visibility: hidden;
@include mq(md) {
position: absolute;
left: -$sp-5;
width: $sp-5;
height: 100%;
}
}
h1:hover > .anchor-heading,
h2:hover > .anchor-heading,
h3:hover > .anchor-heading,
h4:hover > .anchor-heading,
h5:hover > .anchor-heading,
h6:hover > .anchor-heading {
visibility: visible;
}
h1,
h2,
h3,
h4,
h5,
h6 {
position: relative;
}
}