Back

Webkata - CSS 

Created 2 years ago
545 Views
0 Comments
SandhiyaNpJ1zW
@SandhiyaNpJ1zW
SandhiyaNpJ1zW
@SandhiyaNpJ1zWProfile is locked. Login

Display a flex container as Flexible by using display property and change the flex items size to 50px

<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Static Template</title>
     <style>
            .flex-container {
             display: flex;
                background-color: dodgerblue;
            }
            .flex-container >div {
                margin: 10px;
                padding: 20px;
              width: 50px;
              height: 50px;
              font-size:50px;
                text-align: center;
                background-color: #f1f1f1;
            }
        </style>

  </head>
  <body>
  <div class="flex-container">
            <div>1</div>
            <div>2</div>
            <div>3</div>
  </div>
  </body>
</html>
Comments
Please login to comment.