-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathgrid1.html
76 lines (69 loc) · 1.96 KB
/
grid1.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
<!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>Grid</title>
</head>
<style>
*{box-sizing: border-box;
margin: 0;}
header{grid-area: header;}
nav{grid-area: menu;}
aside{grid-area: right;}
footer{grid-area: footer;}
.container{
display: grid;
height: 200vh;
gap: 20px;
padding: 10px;
background-color: aquamarine;
grid-template-areas:
"header header header"
"menu main right"
"footer footer footer";
grid-template-columns: 1fr 3fr 2fr;
grid-template-rows: 20% 1fr 100px;
}
.container >*{
background-color: white;
opacity: 0.9;
text-align: center;
padding: 10px 0;
font-size: 4vw;
}
@media(max-width:600px) {
body{
display: grid;
width: 100vw;
height: 100vh;
grid-template-columns: 1fr 2fr;
grid-template-rows: 6vw 1fr 6vw 4vw ;
background-color: rebeccapurple;
grid-template-areas: 'header' 'header'
'menu' 'main'
'right' 'right'
'footer' 'footer';
}
}
</style>
<body>
<div class="container">
<header>Grid 1</header>
<nav>
<p>Navegação do grid</p>
<a href="grid1.html"> grid 1</a>
<a href="grid2.html"> grid 2</a>
<a href="grid3.html"> grid 3</a>
<a href="grid4.html"> grid 4</a>
<a href="grid5.html"> grid 5</a>
<a href="grid6.html"> grid 6</a>
<a href="index.html">Flex</a>
</nav>
<main>Assunto principal</main>
<aside>Texto de suporte</aside>
<footer>Rodapé</footer>
</div>
</body>
</html>