Signup/Sign In
Ask Question
Not satisfied by the Answer? Still looking for a better solution?

How to solve level 15 lesson 8

Use the flex-shrink property with default value for the class flex-item.
by

1 Answer

sam5epi0l
Here is a possible solution:

<!doctype html>
<html>
<head>
<title>CSS Flex Shrink</title>
<style>
.flex-container{
display: flex;
background-color: #4535AA;
}
.flex-item{
margin: 3px;
padding: 20px;
background-color: white;
width: 150px;
flex-shrink:1;

}
.shrink{
flex-shrink:5;
}

</style>
</head>
<body>
<div class="flex-container">
<div class="flex-item shrink">Item 1</div>
<div class="flex-item">Item 2</div>
<div class="flex-item">Item 3</div>
</div>
</body>
</html>

Login / Signup to Answer the Question.