Repository navigation
Expand file tree
/
Copy pathapp.wxss
More file actions
99 lines (89 loc) · 1.85 KB
/
Copy pathapp.wxss
File metadata and controls
99 lines (89 loc) · 1.85 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
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
@import "/styles/variables.wxss";
page {
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'PingFang SC', 'Microsoft YaHei', sans-serif;
font-size: var(--font-size-base);
color: var(--color-text);
background-color: var(--color-bg);
box-sizing: border-box;
line-height: 1.6;
/* 横向滑动只允许出现在 scroll-x 组件(如分类标签栏)内,页面文档本身禁止横滑 */
overflow-x: hidden;
}
view, text, image, scroll-view, button, input, textarea {
box-sizing: border-box;
}
/* 安全区适配 */
.safe-bottom {
padding-bottom: constant(safe-area-inset-bottom);
padding-bottom: env(safe-area-inset-bottom);
}
/* 通用页面容器 */
.page {
min-height: 100vh;
background-color: var(--color-bg);
}
/* 通用卡片 */
.card {
background: var(--color-surface);
border-radius: 24rpx;
box-shadow: 0 4rpx 24rpx rgba(0, 0, 0, 0.04);
}
/* 按压反馈 */
.hover-press {
opacity: 0.85;
}
/* Flex 工具 */
.flex {
display: flex;
}
.flex-center {
display: flex;
align-items: center;
justify-content: center;
}
.flex-between {
display: flex;
justify-content: space-between;
align-items: center;
}
.flex-column {
display: flex;
flex-direction: column;
}
/* 文本省略 */
.ellipsis {
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.ellipsis-2 {
display: -webkit-box;
-webkit-box-orient: vertical;
-webkit-line-clamp: 2;
overflow: hidden;
}
.ellipsis-3 {
display: -webkit-box;
-webkit-box-orient: vertical;
-webkit-line-clamp: 3;
overflow: hidden;
}
/* 按钮重置 */
button {
margin: 0;
padding: 0;
border: none;
background: transparent;
font-size: inherit;
line-height: inherit;
}
button::after {
border: none;
}
/* 隐藏滚动条 */
::-webkit-scrollbar {
display: none;
width: 0 !important;
height: 0 !important;
color: transparent;
}