From f9a39de3ac8ac7f05584047e7d6a3c6fe279ed78 Mon Sep 17 00:00:00 2001 From: Mary Anthony Date: Mon, 16 Sep 2019 09:49:28 -0700 Subject: [PATCH] Fixing jump to internal anchors Signed-off-by: Mary Anthony --- assets/css/main.scss | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/assets/css/main.scss b/assets/css/main.scss index 24ca8435..f3e23660 100644 --- a/assets/css/main.scss +++ b/assets/css/main.scss @@ -30,6 +30,9 @@ } +/** +* https://www.bryanbraun.com/anchorjs +*/ .anchorjs-link { display: inline-block; height: 32px; @@ -42,6 +45,19 @@ display: block; } +/** +* Create an invisible pseudo-element and make it the height of the +* sticky navbar so the jump takes you to a location above the link +*/ +:target:before { + content: ""; + display: block; + margin-top: -80px; + height: 80px; + width: 1px; +} + +// END: www.bryanbraun.com/anchorjs body > div.uk-lightbox.uk-overflow-hidden.uk-lightbox-panel.uk-open > div.uk-lightbox-toolbar.uk-lightbox-caption.uk-position-bottom.uk-text-center.uk-transition-slide-bottom.uk-transition-opaque .lb-data .lb-details {