stars.vue
8.73 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
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
<template>
<div class="bck">
<div class="box">
<div class="box_L">
<div class="L_top">
<div class="pic">
<img src="@/assets/rank/tx.png" />
</div>
<div class="font_box">
<div class="font_name">熊初墨</div>
<div class="font_sch">柯桥实验小学元培学院</div>
</div>
</div>
<div class="L_mid">
<div class="mid_item">
<div>
<span class="strong_font">23</span>
<span>分</span>
</div>
<div class="grey_font">已完成题数</div>
</div>
<div class="mid_item">
<div>
<span class="strong_font">50</span>
<span>%</span>
</div>
<div class="grey_font">正确率</div>
</div>
</div>
<div class="yellowFont">*积分可用于兑换各种福利</div>
</div>
<div class="box_R">
<div class="box_R_item">
<div class="title">
<div>排行榜</div>
<span>RANKS</span>
</div>
<div class="imgBox">
<img src="@/assets/rank/jb.png" />
</div>
</div>
<div class="box_R_item">
<div class="title">
<div>刷题记录</div>
<span>RECORD</span>
</div>
<div class="imgBox">
<img src="@/assets/rank/qz.png" />
</div>
</div>
</div>
</div>
<div class="card">
<div class="picBox">
<img src="@/assets/rank/wxsn.png" />
</div>
<div class="flexBox" v-for="(v, i) in libraryList" :key="i">
<div class="tipPic">
<img :src="v.imgUrl" />
</div>
<div class="context">
<div class="context_title">{{ v.name }}</div>
<div class="context_grey">{{ v.text }}</div>
</div>
<div class="btnBox">
<div class="btn" @click="toAns(i + 1)">开始答题</div>
</div>
</div>
</div>
</div>
</template>
<script>
export default {
data() {
return {
libraryList: [
{
name: "青铜级",
text: "夯实基础,稳步前进",
imgUrl: require("@/assets/rank/qt.png"),
},
{
name: "黄金级",
text: "夯实基础,稳步前进",
imgUrl: require("@/assets/rank/hj.png"),
},
{
name: "白金级",
text: "夯实基础,稳步前进",
imgUrl: require("@/assets/rank/bj.png"),
},
],
};
},
methods: {
toAns(val) {
this.$router.push({
name: "ans_question",
});
},
},
};
</script>
<style lang="scss" scoped>
.bck {
position: absolute;
width: 100vw;
height: 30vh;
background-image: url("../../assets/rank/wx_back.png");
-moz-background-size: 100% 100%;
background-size: 100% 100%;
.box {
display: flex;
justify-content: space-between;
margin: 5vw 3vw 8vw;
.box_L {
width: 45vw;
height: 360px;
background-color: #fff;
border-radius: 30px;
padding: 3vw 2vw;
box-sizing: border-box;
display: flex;
flex-wrap: wrap;
align-content: space-between;
border: 1px solid #ff6868;
.L_top {
width: 100%;
display: flex;
justify-content: space-between;
.pic {
display: flex;
align-items: center;
img {
width: 13vw;
height: 13vw;
}
}
.font_box {
width: 25vw;
display: flex;
align-content: space-between;
flex-wrap: wrap;
.font_name {
font-size: 30px;
color: #333333;
}
.font_sch {
font-size: 27px;
color: #999;
white-space: nowrap; //文本强制不换行;
text-overflow: ellipsis; //文本溢出显示省略号;
overflow: hidden; //溢出的部分隐藏;
}
}
}
.L_mid {
width: 100%;
display: flex;
justify-content: space-between;
.mid_item {
width: 100%;
text-align: center;
font-size: 25px;
.grey_font {
color: #999;
font-size: 25px;
margin-top: 5px;
}
.strong_font {
font-size: 50px;
font-weight: bold;
}
}
}
.yellowFont {
width: 100%;
font-size: 24px;
color: #ff7a1c;
text-align: center;
}
}
.box_R {
width: 45vw;
height: 360px;
display: flex;
flex-wrap: wrap;
align-content: space-between;
.box_R_item {
width: 100%;
height: 165px;
border-radius: 30px;
display: flex;
justify-content: space-between;
padding: 20px 30px;
box-sizing: border-box;
background-color: #fff;
.title {
font-size: 30px;
color: #000000;
span {
color: #999999;
font-size: 22px;
}
}
.imgBox {
display: flex;
align-items: center;
img {
width: 110px;
height: 110px;
}
}
}
}
}
.card {
width: 100%;
min-height: 800px;
background-color: #fff;
border-radius: 30px;
padding: 5vw 3vw;
box-sizing: border-box;
.picBox {
width: 100%;
margin-bottom: 30px;
img {
width: 100%;
height: 100%;
}
}
.flexBox {
display: flex;
justify-content: space-between;
padding: 5vw 3vw;
box-sizing: border-box;
border-bottom: 1px solid #f1f1f1;
.tipPic {
img {
width: 16vw;
height: 16vw;
}
}
.context {
display: flex;
align-content: space-between;
flex-wrap: wrap;
padding: 5px 0;
box-sizing: border-box;
margin-left: 3vw;
.context_title {
width: 100%;
font-size: 36px;
color: #333333;
}
.context_grey {
font-size: 30px;
color: #999999;
}
}
.btnBox {
display: flex;
justify-content: flex-end;
align-items: center;
.btn {
width: 180px;
height: 70px;
background-color: #fff2f2;
color: #ff6868;
padding: 10px 30px;
box-sizing: border-box;
font-size: 28px;
border-radius: 30px;
text-align: center;
}
}
}
}
}
</style>