I'm having problems with my page layout on flexbox and wonder if anyone can help! I've got the below code in a JSFiddle here https://jsfiddle.net/smvrn7to/1/
I'm trying to make the div with the ID 'notheader' stretch to the bottom of the screen, but I'm having no luck. As I understand it if I use align-content:stretch
on the "notheader" div should work, but I'm getting nothing.
I've tried changing the height to 100% as well, but again its made no difference.
body{
background-color: blueviolet;
margin: 0px;
padding: 0px;
display: flex;
align-content: stretch;
height: 100%;
}
html{
height: 100%;
}
nav{
background-color: aqua;
width: 80px;
height: 100%;
}
main{
background: yellow;
width: 100%
}
header{
height: 100px;
background-color: teal;
}
#controls{
background: tomato;
}
#notnav{
width: 100%;
background-color: chartreuse;
display: flex;
flex-direction: column;
height: 100%;
}
#notheader{
background: white;
}
<nav>
<p>Nav Bar</p>
</nav>
<div id="notnav">
<header>Header</header>
<div id="notheader">not header</div>
<!-- <div id="controls">controls</div> -->
</div>