mirror of
https://github.com/jakejarvis/jarv.is.git
synced 2026-04-17 09:28:43 -04:00
update heading anchor links to always show on mobile
This commit is contained in:
@@ -22,7 +22,7 @@
|
||||
padding: 0 0.25em;
|
||||
color: var(--medium-light) !important;
|
||||
font-weight: 300;
|
||||
opacity: 0; /* overridden on hover */
|
||||
opacity: 0; /* overridden on hover below (except on small screens) */
|
||||
}
|
||||
.anchor::before {
|
||||
content: "\0023"; /* pound sign `#`, done here to keep content DOM cleaner */
|
||||
@@ -30,7 +30,7 @@
|
||||
.anchor:hover {
|
||||
color: var(--link) !important;
|
||||
}
|
||||
/* make anchor `#` link show up on hover over the corresponding heading */
|
||||
/* make anchor link show up on hover over its corresponding heading */
|
||||
.heading:hover .anchor {
|
||||
opacity: 1;
|
||||
}
|
||||
@@ -39,4 +39,9 @@
|
||||
.heading {
|
||||
scroll-margin-top: 6.5rem;
|
||||
}
|
||||
|
||||
/* don't require hover to show anchor link on small (likely touch) screens */
|
||||
.anchor {
|
||||
opacity: 1;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user