<!DOCTYPE html>
<html lang="en-US">
<head>
<style>
#parent{
display: flex;
flex-wrap: wrap;
width: 350px;
min-height: 350px;
border: 1px solid #8c8c8c;
}
#parent > div{
border:1px solid #267326;
color:#fff;
width: 70px;
height:70px;
}
</style>
</head>
<body>
<h1>CSS align-content Property</h1>
<div id="parent">
<div>Div 1</div>
<div>Div 2</div>
<div>Div 3</div>
<div>Div 4</div>
<div>Div 5</div>
<div>Div 6</div>
<div>Div 7</div>
</div>
<button onclick="myFunction()">Click Me</button>
<script>
var x = document.getElementById("parent");
function myFunction(){
x.style.alignContent = "space-evenly";
}
</script>
<p><strong>Note</strong>: Click on the button to change the 'align-content' from stretch (default) to space-evenly.</p> </body>
</html>