... | ... |
@@ -1,7 +1,7 @@ |
1 | 1 |
/** |
2 | 2 |
* Sticky footer |
3 | 3 |
*/ |
4 |
-@mixin set-sticky-footer($height, $padding: 30px) { |
|
4 |
+@mixin set-sticky-footer($height, $padding: 30px, $cssId: footer) { |
|
5 | 5 |
html { |
6 | 6 |
height: 100%; |
7 | 7 |
} |
... | ... |
@@ -14,14 +14,16 @@ |
14 | 14 |
#wrapper { |
15 | 15 |
padding-bottom: $height + $padding; |
16 | 16 |
} |
17 |
- #footer { |
|
17 |
+ ##{$cssId} { |
|
18 | 18 |
position: absolute; |
19 | 19 |
bottom: 0; |
20 | 20 |
left: 0; |
21 | 21 |
right: 0; |
22 |
+ height: $height; |
|
23 |
+ overflow: hidden; |
|
22 | 24 |
|
23 | 25 |
.inside { |
24 |
- height: $height; |
|
26 |
+ height: 100%; |
|
25 | 27 |
} |
26 | 28 |
} |
27 | 29 |
} |
28 | 30 |
\ No newline at end of file |
1 | 1 |
new file mode 100644 |
... | ... |
@@ -0,0 +1,27 @@ |
1 |
+/** |
|
2 |
+ * Sticky footer |
|
3 |
+ */ |
|
4 |
+@mixin set-sticky-footer($height, $padding: 30px) { |
|
5 |
+ html { |
|
6 |
+ height: 100%; |
|
7 |
+ } |
|
8 |
+ body { |
|
9 |
+ position: relative; |
|
10 |
+ margin: 0; |
|
11 |
+ padding: 0; |
|
12 |
+ min-height: 100%; |
|
13 |
+ } |
|
14 |
+ #wrapper { |
|
15 |
+ padding-bottom: $height + $padding; |
|
16 |
+ } |
|
17 |
+ #footer { |
|
18 |
+ position: absolute; |
|
19 |
+ bottom: 0; |
|
20 |
+ left: 0; |
|
21 |
+ right: 0; |
|
22 |
+ |
|
23 |
+ .inside { |
|
24 |
+ height: $height; |
|
25 |
+ } |
|
26 |
+ } |
|
27 |
+} |
|
0 | 28 |
\ No newline at end of file |