-
Notifications
You must be signed in to change notification settings - Fork 43
/
Copy path_grid.scss
69 lines (62 loc) · 2 KB
/
_grid.scss
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
//====================================================
// Grid Componets
//====================================================
.column {
display: flex;
flex-direction: column;
flex: 1 1 auto;
height: auto;
flex-wrap: nowrap;
@include small {
min-width: 100%;
}
}
.row {
display: flex;
flex: 1 1 auto;
height: auto;
flex-direction: row;
flex-wrap: wrap;
}
.row > .column {
@include small {
width: 100% !important;
}
}
//====================================================
// Gutters
//====================================================
// Add .gutters to .row/.column elements
.gutters { padding: $padding; }
// All direct descendants of .gutters get margin
.gutters > .column,
.gutters > .row {
margin: $margin;
@include small {
width: 100% !important;
min-width: 0;
}
}
// offset padding/margin to maintain width
.gutters > {
.w5 { width: calc(5% - #{$padding + $margin}); }
.w10 { width: calc(10% - #{$padding + $margin}); }
.w15 { width: calc(15% - #{$padding + $margin}); }
.w20 { width: calc(20% - #{$padding + $margin}); }
.w25 { width: calc(25% - #{$padding + $margin}); }
.w30 { width: calc(30% - #{$padding + $margin}); }
.w35 { width: calc(35% - #{$padding + $margin}); }
.w40 { width: calc(40% - #{$padding + $margin}); }
.w45 { width: calc(45% - #{$padding + $margin}); }
.w50 { width: calc(50% - #{$padding + $margin}); }
.w55 { width: calc(55% - #{$padding + $margin}); }
.w60 { width: calc(60% - #{$padding + $margin}); }
.w65 { width: calc(65% - #{$padding + $margin}); }
.w70 { width: calc(70% - #{$padding + $margin}); }
.w75 { width: calc(75% - #{$padding + $margin}); }
.w80 { width: calc(80% - #{$padding + $margin}); }
.w85 { width: calc(85% - #{$padding + $margin}); }
.w90 { width: calc(90% - #{$padding + $margin}); }
.w95 { width: calc(95% - #{$padding + $margin}); }
.w100 { width: calc(100% - #{$padding + $margin}); }
}