-
Notifications
You must be signed in to change notification settings - Fork 0
/
demo responsive.html
58 lines (52 loc) · 1.21 KB
/
demo responsive.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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Document</title>
<style>
body {
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
}
.pc,
.tablet,
.mobile {
font-size: 68px;
display: none;
}
/* BREAK POINT */
/* PC */
@media (min-width: 1024px) {
.pc {
display: block;
}
}
/* Tablet */
@media (min-width: 740px) and (max-width: 1023px) {
.tablet {
display: block;
}
}
/* Mobile */
@media (max-width: 740px) {
.mobile {
display: block;
}
}
/*
PC: >= 1024px
Tablet: >=740px & < 1024px
Mobile: < 740px
*/
</style>
</head>
<body>
<h2 class="pc">PC</h2>
<h2 class="tablet">Tablet</h2>
<h2 class="mobile">Mobile</h2>
</body>
</html>