Open david2tdw opened 2 years ago
<!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>page layout</title>
<style>
html,
body {
height: 100%;
margin: 0;
padding: 0;
}
div {
margin: 0;
padding: 0;
}
#root {
display: flex;
flex-direction: column;
height: 100%;
}
.outer-wrapper {
flex: 1;
background-color: aqua;
padding: 0 20px;
}
.wrap {
display: flex;
flex-direction: column;
background-color: yellow;
height: 100%;
}
.top {
background-color: tomato;
}
.bottom {
background-color: rebeccapurple;
flex: 1;
}
.inner {
background-color: green;
}
</style>
</head>
<body>
<div id="root">
<div class="outer-wrapper">
<div class="wrap">
<div class="top">
this is top part<br />
this is top part<br />
this is top part<br />
this is top part<br />
</div>
<div class="bottom">
this is bottom part.
<div class="inner">this is bottom inner</div>
</div>
</div>
</div>
</div>
</body>
</html>
<!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>page layout</title>
<style>
html,
body {
height: 100%;
margin: 0;
padding: 0;
}
div {
margin: 0;
padding: 0;
}
#root {
display: flex;
flex-direction: column;
height: 100%;
}
.outer-wrapper {
flex: 1;
background-color: aqua;
padding: 0 20px;
}
.wrap {
display: flex;
flex-direction: column;
background-color: yellow;
height: 100%;
}
.top {
background-color: tomato;
}
.bottom {
background-color: rebeccapurple;
flex: 1;
}
.inner {
background-color: green;
height: 700px;
}
</style>
</head>
<body>
<div id="root">
<div class="outer-wrapper">
<div class="wrap">
<div class="top">
this is top part<br />
this is top part<br />
this is top part<br />
this is top part<br />
</div>
<div class="bottom">
this is bottom part.
<div class="inner">this is bottom inner</div>
</div>
</div>
</div>
</div>
</body>
</html>