grid.css
1.23 KB
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
/*
* 布局
*/
/* 手机全屏占比 */
html, body, .g-window {
position: relative;
display: block;
width: 100%;
height: 100%;
overflow: hidden;
font-size: 1rem;
color: $color_base_font;
}
/* 外面嵌套g-window 为了覆盖weui默认样式 */
.g-window {
/*顶部布局*/
.g-header {
/* 移动端用fixed定位会有bug */
position: absolute;
top: 0;
left: 0;
width: 100%;
z-index: 5;
&.vux-tab {
height: 2.6rem;
a {
line-height: $height_nav;
}
}
.router-link {
height: $height_nav;
line-height: $height_nav;
color: $color_nav_font;
}
.router-link-active {
color: $color_nav_active_background;
border-bottom:2px solid $color_nav_active_background;
}
}
/* 水平垂直居中布局 */
.g-center {
position: absolute;
top: 50%;
left: 50%;
width: 80%;
height: auto;
transform: translate(-50%, -50%);
}
/* 继承布局 */
.g-inherit {
position: inherit;
display: inherit;
padding: 0;
margin: 0;
width: 100%;
height: 100%;
overflow: hidden;
}
/* flex布局-中央布局 */
.g-flex-c {
display: flex;
flex-flow: row wrap;
justify-content: center;
}
}