hooyantsing's Blog

P116_16_布局小米移动端页面结构

字数统计: 129阅读时长: 1 min
2020/04/16

P116 16 布局小米移动端页面结构

实战案例

效果

aca8e419366a8e1c1c3c7c899301087e.png

代码

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
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <style>
        * {
            padding: 0;
            margin: 0;
        }

        body {
            height: 100vh;
            display: flex;
            flex-direction: column;
            justify-content: space-between;
        }

        header {
            height: 60px;
            background: blueviolet;
        }

        main {
            flex-grow: 1;
            background: #ccc;
        }

        footer {
            height: 60px;
            background: #383881;
        }
    </style>
</head>
<body>
<header></header>
<main></main>
<footer></footer>
</body>
</html>
CATALOG