提交 | 用户 | 时间
|
759b1c
|
1 |
/* ===== PC DESIGN ===== */ |
H |
2 |
$W: 1000; |
|
3 |
$H: 1920; |
|
4 |
$picW: 438; |
|
5 |
$picH: 560; |
|
6 |
$formW: 320; |
|
7 |
$tabW: $formW / 2; |
|
8 |
$rowH: 56; |
|
9 |
$buttonH: 50; |
|
10 |
|
|
11 |
// container |
|
12 |
$containerBgColor: #e6ebf2; |
|
13 |
$containerBgImage: '../assets/images/bg.png'; |
|
14 |
// container-logo |
|
15 |
$logoWidth: 500px; |
|
16 |
$logoHeight: 64px; |
|
17 |
//$logoImage: '../assets/logo/login-logo.png'; |
|
18 |
// container-content |
|
19 |
$contentWidth: round($W / $H * 100) * 1vw; |
|
20 |
$contentHeight: round($picH / $W * 100) / 100 * $contentWidth; |
|
21 |
$contentBgColor: #ffffff; |
|
22 |
// container-content-pic |
|
23 |
$picWidth: round($picW / $H * 100) * 1vw; |
|
24 |
$picHeight: inherit; |
|
25 |
$picImage: '../assets/images/pic.png'; |
|
26 |
// container-content-field |
|
27 |
$fieldWidth: $contentWidth - $picWidth; |
|
28 |
$fieldHeight: inherit; |
|
29 |
// container-content-field-form |
|
30 |
$formWidth: $formW * 1px; |
|
31 |
$tabWidth: $tabW * 1px; |
|
32 |
$rowHeight: $rowH * 1px; |
|
33 |
$buttonHeight: $buttonH * 1px; |
|
34 |
|
|
35 |
// - - - - - 页面基础设置 |
|
36 |
.container { |
|
37 |
.login-code { |
|
38 |
width: 33%; |
|
39 |
height: 38px; |
|
40 |
float: right; |
|
41 |
img { |
|
42 |
cursor: pointer; |
|
43 |
width:100%;max-width:100px; height:auto; |
|
44 |
vertical-align: middle; |
|
45 |
} |
|
46 |
} |
|
47 |
// 元素 |
|
48 |
width: inherit; |
|
49 |
height: inherit; |
|
50 |
min-width: 1080px; |
|
51 |
min-height: 620px; |
|
52 |
background-color: $containerBgColor; |
|
53 |
background-image: url($containerBgImage); |
|
54 |
background-size: cover; |
|
55 |
// 定位 |
|
56 |
position: relative; |
|
57 |
display: flex; |
|
58 |
justify-content: center; |
|
59 |
align-items: center; |
|
60 |
// 文字 |
|
61 |
font-size: 14px; |
|
62 |
font-family: Microsoft YaHei; |
|
63 |
font-weight: 400; |
|
64 |
.logo { |
|
65 |
// 元素 |
|
66 |
width: $logoWidth; |
|
67 |
height: $logoHeight; |
|
68 |
//background-image: url($logoImage); |
|
69 |
background-size: contain; |
|
70 |
// 定位 |
|
71 |
position: absolute; |
|
72 |
top: 50px; |
|
73 |
left: 50%; |
|
74 |
margin-left: -$logoWidth/2; |
|
75 |
} |
|
76 |
.content { |
|
77 |
// 元素 |
|
78 |
width: $contentWidth; |
|
79 |
height: $contentHeight; |
|
80 |
background-color: #ffffff; |
|
81 |
box-shadow: 0px 16px 40px rgba(0, 0, 0, 0.07); |
|
82 |
border-radius: 20px; |
|
83 |
// 定位 |
|
84 |
position: relative; |
|
85 |
.pic { |
|
86 |
// 元素 |
|
87 |
width: $picWidth; |
|
88 |
height: $picHeight; |
|
89 |
background-image: url($picImage); |
|
90 |
background-repeat: no-repeat; |
|
91 |
background-size: cover; |
|
92 |
border-radius: 20px 0 0 20px; |
|
93 |
// 定位 |
|
94 |
position: absolute; |
|
95 |
top: 0; |
|
96 |
left: 0; |
|
97 |
} |
|
98 |
.field { |
|
99 |
width: $fieldWidth; |
|
100 |
height: $fieldHeight; |
|
101 |
// 定位 |
|
102 |
position: absolute; |
|
103 |
top: 0; |
|
104 |
left: $picWidth; |
|
105 |
display:flex; |
|
106 |
justify-content: center; |
|
107 |
align-items: center; |
|
108 |
.pc-title{ width: 100%; clear: both;} |
|
109 |
.mobile-title, |
|
110 |
.mobile-switch { |
|
111 |
display: none; |
|
112 |
} |
|
113 |
.form { |
|
114 |
box-sizing: border-box; |
|
115 |
width: $formWidth; |
|
116 |
// - - - tab |
|
117 |
:deep(.el-tabs__content) { |
|
118 |
padding: 20px 0 0; |
|
119 |
} |
|
120 |
:deep(.el-tabs__item) { |
|
121 |
// 元素 |
|
122 |
width: $tabWidth; |
|
123 |
height: $rowHeight; |
|
124 |
padding: 0; |
|
125 |
// 文字 |
|
126 |
line-height: $rowHeight; |
|
127 |
color: #666666; |
|
128 |
} |
|
129 |
:deep(.el-tabs__item.is-active) { |
|
130 |
font-weight: bold; |
|
131 |
color: #2F53EB; |
|
132 |
} |
|
133 |
:deep(.el-tabs__active-bar) { |
|
134 |
height: 3px; |
|
135 |
border-radius: 2px; |
|
136 |
} |
|
137 |
// - - - input |
|
138 |
:deep(.el-input__inner) { |
|
139 |
// 元素 |
|
140 |
width: 100%; |
|
141 |
height: $rowHeight; |
|
142 |
background: #f5f5f5; |
|
143 |
border: 0; |
|
144 |
border-radius: 28px; |
|
145 |
// 文字 |
|
146 |
text-align: center; |
|
147 |
line-height: 19px; |
|
148 |
color: #262626; |
|
149 |
} |
|
150 |
.code:deep(.el-input__inner) { |
|
151 |
padding: 0 24px; |
|
152 |
// 文字 |
|
153 |
text-align: left; |
|
154 |
} |
|
155 |
:deep(.el-input__inner::-webkit-input-placeholder) { /* WebKit browsers */ |
|
156 |
font-weight: 400; |
|
157 |
color: #8C8C8C; |
|
158 |
} |
|
159 |
:deep(.el-input__inner:-moz-placeholder) { /* Mozilla Firefox 4 to 18 */ |
|
160 |
font-weight: 400; |
|
161 |
color: #8C8C8C; |
|
162 |
} |
|
163 |
:deep(.el-input__inner::-moz-placeholder) { /* Mozilla Firefox 19+ */ |
|
164 |
font-weight: 400; |
|
165 |
color: #8C8C8C; |
|
166 |
opacity:1; |
|
167 |
} |
|
168 |
:deep(.el-input__inner:-ms-input-placeholder) { /* Internet Explorer 10+ */ |
|
169 |
font-weight: 400; |
|
170 |
color: #8C8C8C !important; |
|
171 |
} |
|
172 |
:deep(.el-form-item) { |
|
173 |
position: relative; |
|
174 |
.button-code { |
|
175 |
// 元素 |
|
176 |
height: $rowHeight; |
|
177 |
box-sizing: border-box; |
|
178 |
// 定位 |
|
179 |
position: absolute; |
|
180 |
top: 0; |
|
181 |
right: 20px; |
|
182 |
z-index: 1; |
|
183 |
// 文字 |
|
184 |
line-height: 20px; |
|
185 |
font-size: 14px; |
|
186 |
font-family: PingFang SC; |
|
187 |
font-weight: 400; |
|
188 |
color: #2F53EB; |
|
189 |
span { |
|
190 |
padding-left: 15px; |
|
191 |
border-left: 2px solid #D9D9D9; |
|
192 |
} |
|
193 |
} |
|
194 |
} |
|
195 |
:deep(.el-form-item__error) { |
|
196 |
padding-left: 24px; |
|
197 |
} |
|
198 |
.button { |
|
199 |
width: 100%; |
|
200 |
height: $buttonHeight; |
|
201 |
background: rgba(24, 144, 255, 0.2); |
|
202 |
border: 0; |
|
203 |
border-radius: 24px; |
|
204 |
margin-bottom: 20px; |
|
205 |
// 文字 |
|
206 |
line-height: 26px; |
|
207 |
font-size: 20px; |
|
208 |
color: #FFFFFF; |
|
209 |
} |
|
210 |
.button-active { |
|
211 |
background: #2F53EB; |
|
212 |
box-shadow: 0px 2px 8px rgba(0, 80, 184, 0.2); |
|
213 |
} |
|
214 |
} |
|
215 |
} |
|
216 |
} |
|
217 |
.footer { |
|
218 |
// 元素 |
|
219 |
height: 16px; |
|
220 |
line-height: 16px; |
|
221 |
font-size: 12px; |
|
222 |
color: #8c8c8c; |
|
223 |
// 定位 |
|
224 |
position: absolute; |
|
225 |
bottom: 30px; |
|
226 |
a, |
|
227 |
a:hover, |
|
228 |
a:active { |
|
229 |
color: inherit; |
|
230 |
text-decoration: none; |
|
231 |
} |
|
232 |
} |
|
233 |
} |
|
234 |
|
|
235 |
// - - - - - PC 最小尺寸设置 |
|
236 |
@media screen and (min-width: 599px) and (max-width: 1366px) { |
|
237 |
.container { |
|
238 |
.content { |
|
239 |
width: 710px; |
|
240 |
height: 397px; |
|
241 |
.pic { |
|
242 |
width: 314px; |
|
243 |
} |
|
244 |
.field { |
|
245 |
width: calc(710px - 314px); |
|
246 |
left: 314px; |
|
247 |
.form { |
|
248 |
width: 320px; |
|
249 |
:deep(.el-input__inner) { |
|
250 |
width: 320px; |
|
251 |
height: 56px; |
|
252 |
} |
|
253 |
.button { |
|
254 |
height: 50px; |
|
255 |
} |
|
256 |
} |
|
257 |
} |
|
258 |
} |
|
259 |
} |
|
260 |
} |
|
261 |
|
|
262 |
|
|
263 |
/* ===== MOBILE DESIGN ===== */ |
|
264 |
$mobileW: 375; |
|
265 |
$mobileH: 812; |
|
266 |
$mobileContentW: 327; |
|
267 |
$mobileContentH: 376; |
|
268 |
$mobileFormW: 280; |
|
269 |
$mobileRowH: 48; |
|
270 |
$mobileButtonH: 48; |
|
271 |
|
|
272 |
// container |
|
273 |
$mobileContainerBgImage: '../assets/images/bg-mobile.png'; |
|
274 |
// container-content |
|
275 |
$mobileContentWidth: round($mobileContentW / $mobileW * 100) * 1vw; |
|
276 |
$mobileContentHeight: round($mobileContentH / $mobileW * 100) / 100 * $mobileContentWidth; |
|
277 |
// container-content-field-form |
|
278 |
$mobileFormWidth: round($mobileFormW / $mobileW *100) * 1vw; |
|
279 |
$mobileRowHeight: $mobileRowH * 1px; |
|
280 |
$mobileButtonHeight: $mobileButtonH * 1px; |
|
281 |
$iconBgImage: '../assets/images/icon.png'; |
|
282 |
|
|
283 |
// - - - - - 移动端设置 |
|
284 |
@media screen and (max-width: 599px) { |
|
285 |
.container { |
|
286 |
// 元素 |
|
287 |
background-image: url($mobileContainerBgImage); |
|
288 |
min-width: 280px; |
|
289 |
min-height: 568px; |
|
290 |
// 文字 |
|
291 |
font-size: 17px; |
|
292 |
font-family: PingFang SC; |
|
293 |
font-weight: bold; |
|
294 |
.logo { |
|
295 |
display: none; |
|
296 |
} |
|
297 |
|
|
298 |
.content { |
|
299 |
// 元素 |
|
300 |
width: $mobileContentWidth; |
|
301 |
height: $mobileContentHeight; |
|
302 |
min-width: 250px; |
|
303 |
min-height: 340px; |
|
304 |
// 定位 |
|
305 |
display: flex; |
|
306 |
justify-content: center; |
|
307 |
align-items: center; |
|
308 |
.pic { |
|
309 |
display: none; |
|
310 |
} |
|
311 |
.field { |
|
312 |
// 元素 |
|
313 |
width: inherit; |
|
314 |
min-height: inherit; |
|
315 |
// 定位 |
|
316 |
left: 0; |
|
317 |
display: flex; |
|
318 |
flex-direction: column; |
|
319 |
.mobile-title { |
|
320 |
// 元素 |
|
321 |
margin: 0 0 20px; |
|
322 |
display: block; |
|
323 |
} |
|
324 |
.form { |
|
325 |
width: $mobileFormWidth; |
|
326 |
// - - - tab |
|
327 |
:deep(.el-tabs__header) { |
|
328 |
display: none; |
|
329 |
} |
|
330 |
:deep(.el-tabs__content) { |
|
331 |
padding: 0; |
|
332 |
} |
|
333 |
// - - - input |
|
334 |
:deep(.el-input__inner) { |
|
335 |
height: $mobileRowHeight; |
|
336 |
line-height: 24px; |
|
337 |
// 文字 |
|
338 |
text-align: center; |
|
339 |
color: #262626; |
|
340 |
} |
|
341 |
:deep(.el-form-item) { |
|
342 |
.button-code { |
|
343 |
// 元素 |
|
344 |
height: $mobileRowHeight; |
|
345 |
} |
|
346 |
} |
|
347 |
.button { |
|
348 |
height: $mobileButtonHeight; |
|
349 |
line-height: 24px; |
|
350 |
color: #FFFFFF; |
|
351 |
} |
|
352 |
} |
|
353 |
.mobile-switch { |
|
354 |
display: block; |
|
355 |
line-height: 20px; |
|
356 |
font-size: 14px; |
|
357 |
font-weight: 400; |
|
358 |
color: #595959; |
|
359 |
margin: 0; |
|
360 |
.icon { |
|
361 |
width: 14px; |
|
362 |
height: 14px; |
|
363 |
display: inline-block; |
|
364 |
background-image: url($iconBgImage); |
|
365 |
background-size: cover; |
|
366 |
} |
|
367 |
} |
|
368 |
.mobile-switch:hover { |
|
369 |
cursor: pointer; |
|
370 |
} |
|
371 |
} |
|
372 |
} |
|
373 |
.footer { |
|
374 |
// 元素 |
|
375 |
font-size: 12px; |
|
376 |
font-family: PingFang SC; |
|
377 |
font-weight: 400; |
|
378 |
line-height: 17px; |
|
379 |
color: #333333; |
|
380 |
opacity: 0.6; |
|
381 |
// 定位 |
|
382 |
position: absolute; |
|
383 |
bottom: 20px; |
|
384 |
} |
|
385 |
} |
|
386 |
|
|
387 |
} |