-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsimulator.html
118 lines (107 loc) · 2.44 KB
/
simulator.html
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
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>drag</title>
<style type="text/css">
body {
display: flex;
flex-flow: row nowrap;
align-items: center;
justify-content: center;
margin: 0;
padding: 0;
height: 100vh;
width: 100vw;
overflow: hidden;
font-family: PingFangSC-Regular;
}
.simulator {
width: 375px;
height: 812px;
border-radius: 38px;
border: 8px solid #000;
outline: 6px solid #32353ecc;
box-shadow: 6px 8px 16px #000, 18px 32px 70px rgba(0, 0, 0, 0.2);
background-color: #f5f5f5;
overflow: hidden;
position: relative;
box-sizing: content-box;
transform: scale(0.8);
}
.status-bar {
display: flex;
flex-flow: row nowrap;
align-items: center;
justify-content: center;
position: absolute;
top: 0;
height: 88px;
left: 0;
right: 0;
z-index: 9;
}
.status-bar::after {
content: '';
position: absolute;
top: 0;
left: 0;
bottom: 0;
right: 0;
z-index: 10;
background-position: top center;
background-repeat: no-repeat;
background-image: url("./assets/simulator/white.png");
background-size: contain;
}
.transparent {
background-color: 'transparent';
}
.transparent::after {
background-image: url("./assets/simulator/transparent.png");
}
.wrapper {
position: absolute;
top: 88px;
left: 0;
right: 0;
bottom: 0;
z-index: 8;
padding-bottom: 26px;
box-sizing: border-box;
overflow: hidden;
display: flex;
flex-flow: column nowrap;
align-items: stretch;
justify-content: flex-start;
transition: all 0.35s ease-in-out;
}
.safe-area-bar {
display: flex;
flex-flow: row nowrap;
align-items: center;
justify-content: center;
position: absolute;
bottom: 8px;
height: 5px;
left: 0;
right: 0;
z-index: 10;
}
.safe-area-bar::after {
content: '';
width: 120px;
background-color: #000;
height: 5px;
border-radius: 2.5px;
}
</style>
</head>
<body>
<div class="simulator">
<div class="status-bar"></div>
<div class="wrapper">内容</div>
<div class="safe-area-bar"></div>
</div>
</body>
</html>