1
- // Bootstrap Grid Changes
2
-
3
- /* Changes the default gutter size */
4
- $xgutter :2rem ;
5
- $ygutter :4rem ;
6
-
7
- // Sets gutters on all cols
8
- [class ^= ' col-' ] {
9
- padding-left :$xgutter ;
10
- padding-right :$xgutter ;
11
- margin-top :$ygutter ;
12
- margin-bottom :$ygutter ;
13
1
}
14
2
15
- @each $breakpoint in $breakpoints {
16
- $size : nth ($breakpoint , 1 );
17
- $width : nth ($breakpoint , 2 );
3
+ // Pulls information for each breakpoint
4
+ @each $size , $width in $breakpoints {
18
5
19
- // Upon collapse of cols at the appropriate breakpoint, adds a margin
6
+ // Upon collapse of cols at the appropriate breakpoint:
20
7
@include mq-max-width ($width ) {
8
+
9
+ // adds a margin to the top cols that come after cols
21
10
[class ^= ' col-#{$size } ' ] + [class ^= ' col-#{$size } ' ] {
22
- margin-top :0 ;
23
- margin-bottom :$ygutter ;
11
+ margin-top :($cspacer * 2 );
24
12
}
25
- .container {
26
- max-width :1200px ;
13
+
14
+ // adds padding to the child div of the col to even spacing
15
+ .container [class ^= " col-#{$size } " ] > div {
16
+ padding-left :$cspacer !important ;
17
+ padding-right :$cspacer !important ;
27
18
}
19
+
20
+ // removes padding for container within fluid container
28
21
.container-fluid .container {
29
22
padding :0 ;
23
+ }
30
24
31
- .row {
32
- margin-left :0 ;
33
- margin-right :0 ;
34
25
}
35
26
}
36
- // Adds the gutter to the left and right when collapsed
37
- [class ^= ' col-' ] {
38
- padding-left :$xgutter ;
39
- padding-right :$xgutter ;
40
- }
41
27
}
42
- }
43
-
28
+ }
0 commit comments