UNPKG

674 BSCSSView Raw
1// stylelint-disable declaration-no-important
2
3// Common values
4
5// Sass list not in variables since it's not intended for customization.
6// stylelint-disable-next-line scss/dollar-variable-default
7$positions: static, relative, absolute, fixed, sticky;
8
9@each $position in $positions {
10 .position-#{$position} { position: $position !important; }
11}
12
13// Shorthand
14
15.fixed-top {
16 position: fixed;
17 top: 0;
18 right: 0;
19 left: 0;
20 z-index: $zindex-fixed;
21}
22
23.fixed-bottom {
24 position: fixed;
25 right: 0;
26 bottom: 0;
27 left: 0;
28 z-index: $zindex-fixed;
29}
30
31.sticky-top {
32 @supports (position: sticky) {
33 position: sticky;
34 top: 0;
35 z-index: $zindex-sticky;
36 }
37}