add simple scroll-to-top button. Fixes #24

lektura
max.mehl 2017-08-29 21:36:02 +02:00
parent b49090c1b8
commit f439b45794
2 changed files with 26 additions and 0 deletions

View File

@ -11,3 +11,9 @@
<p>{{ .Site.Params.legal.license }}</p> <p>{{ .Site.Params.legal.license }}</p>
</div> </div>
</section> </section>
<a class="page-scroll hiddenlink" href="#page-top" title="Scroll to top">
<div id="scroll-to-top">
<i class="fa fa-chevron-up" aria-hidden="true"></i>
</div>
</a>

View File

@ -218,3 +218,23 @@ a:not(.btn):not(.hiddenlink):hover::before, a:not(.btn):not(.hiddenlink):focus::
transform: translateY(-10px); transform: translateY(-10px);
} }
} }
/* Scroll to top arrow */
#scroll-to-top {
position: fixed;
bottom: 20px;
right: 20px;
background: rgba(0, 0, 0, 0.7);
width: 50px;
height: 50px;
text-decoration: none;
border-radius: 50%;
}
#scroll-to-top i {
color: #fff;
margin: 0;
position: relative;
left: 16px;
top: 13px;
font-size: 19px;
}