Skip to content

Commit 8012f7e

Browse files
Stick footer to bottom (#369)
* Stick to bottom * Use variable
1 parent 981d4cd commit 8012f7e

2 files changed

Lines changed: 4 additions & 1 deletion

File tree

assets/theme-css/styles.css

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -165,6 +165,8 @@ a > code {
165165
}
166166
#footer {
167167
background-color: var(--colorPrimaryDark);
168+
position: sticky;
169+
top: calc(100vh - var(--spht-footer-height));
168170
}
169171

170172
.footer-logo-column {

assets/theme-css/vars.css

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
:root {
33
--fontFamily: "{{ .Site.Params.font.name }}", "Noto Sans Symbols 2";
44

5-
/* First we name the colors of our theme's palette. */
65
--colorPrimaryDark: rgb(1, 50, 67);
76
--colorPrimary: rgb(77, 119, 207);
87
--colorPrimaryLight: rgb(77, 171, 207);
@@ -13,4 +12,6 @@
1312

1413
--colorBrightBlue: rgb(30, 135, 240);
1514
--colorYellow: rgb(255, 197, 83);
15+
16+
--spht-footer-height: 6em;
1617
}

0 commit comments

Comments
 (0)