Make footer stick to the bottom of the page
- Use JavaScript to determine height of `.page_footer` to apply padding to `body` avoiding any content overlap - Absolute position `.page_footer` to bottom of the page
This commit is contained in:
@@ -2,6 +2,12 @@
|
||||
BASE ELEMENTS
|
||||
========================================================================== */
|
||||
|
||||
html {
|
||||
/* sticky footer fix */
|
||||
position: relative;
|
||||
min-height: 100%;
|
||||
}
|
||||
|
||||
body {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
|
||||
@@ -5,6 +5,13 @@
|
||||
.page__footer {
|
||||
@include full();
|
||||
@include clearfix;
|
||||
/* sticky footer fix start */
|
||||
position: absolute;
|
||||
bottom: 0;
|
||||
width: 100%;
|
||||
clear: both;
|
||||
height: auto;
|
||||
/* sticky footer fix end */
|
||||
margin-top: 3em;
|
||||
color: mix(#fff, $gray, 25%);
|
||||
animation: intro 0.3s both;
|
||||
|
||||
Reference in New Issue
Block a user