-
Notifications
You must be signed in to change notification settings - Fork 0
/
grid.css
86 lines (71 loc) · 1.11 KB
/
grid.css
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
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
/*
* very rarely an app needs a complete grid system but few of the specific cells,
* and their device specific overides.
* any element with class `col` is an inline block element
* and following rule will provide desired width to such elements
*/
.col-1-1 {
width: 100%;
}
/* 2 col grid */
.col-1-2 {
width: 50%;
}
/* 3 col grid */
.col-1-3 {
width: 33.33%;
}
.col-2-3 {
width: 66.66%;
}
/* 4 col grid */
.col-1-4 {
width: 25%;
}
.col-3-4 {
width: 75%;
}
/* 5 col grid */
.col-1-5 {
width: 20%;
}
.col-2-5 {
width: 40%;
}
.col-3-5 {
width: 60%;
}
.col-4-5 {
width: 80%;
}
/* small device */
@media screen and (--sm-device) {
.col-sm-1-2,
.col-sm-1-3,
.col-sm-2-3,
.col-sm-1-4,
.col-sm-3-4 {
width: 100%;
}
}
/* medium device */
@media screen and (--md-device) {
.col-md-1-3,
.col-md-2-3,
.col-md-1-4,
.col-md-3-4 {
width: 100%;
}
}
/*!
* placeholder for large device specific layout rules
* @media screen and (--lg-device) {
* ...
* }
*/
/*!
* placeholder for extra large device specific layout rules
* @media screen and (--xl-device) {
* ...
* }
*/