align-content প্রোপার্টির space-around মান ফ্লেক্স লাইনগুলোর চারপাশে সমান স্পেস যোগ করে। এটি flex-wrap: wrap থাকলে কাজ করে।
উদাহরণ
নিচের কোডটি চালিয়ে space-around মান ব্যবহার দেখুন:
<!DOCTYPE html> <html>
<head>
<style>
.mycontainer {
display: flex;
height: 200px;
background-color: red;
align-content: space-around;
flex-wrap: wrap;
}
.mycontainer > div {
background-color: yellow;
text-align: center;
line-height: 60px;
font-size: 30px;
width: 100px;
margin: 5px;
}
</style>
</head>
<body>
<h1>Queue</h1>
<div class="mycontainer">
<div>Q1</div>
<div>Q2</div>
<div>Q3</div>
<div>Q4</div>
<div>Q5</div>
<div>Q6</div>
<div>Q7</div>
<div>Q8</div>
</div>
</body>
</html>
ব্যাখ্যা: flex-wrap: wrap থাকায় আইটেমগুলো একাধিক লাইনে ভেঙে যায়। align-content: space-around প্রতিটি লাইনের উপরে এবং নিচে সমান স্পেস যোগ করে, প্রথম এবং শেষ লাইনের কন্টেইনারের বর্ডারের সাথে 스페েস نصف হয়।