Flex Container
.flex-container {
display: flex;
background-color: orange;
width:250px;
}
.flex-container > div {
background-color: yellow;
margin: 4px;
padding: 5px 10px;
font-size: 30px;
color:black;
}
div class="flex-container"
div 1 div
div 2 div
div 3 div
div
display: flex;
flex-direction: column;
flex-direction: row;
flex-direction: column-reverse;
flex-direction: row-reverse;
flex-wrap: wrap;
flex-wrap: nowrap;
flex-wrap: wrap-reverse;
flex-flow: row wrap;
justify-content: center;
justify-content: flex-start;
justify-content: flex-end;
justify-content: space-around;
justify-content: space-between;
align-items: center;
align-items: flex-start;
align-items: flex-end;
align-items: stretch;
align-items: baseline;
align-content: space-between;
align-content: space-around;
align-content: stretch;
align-content: center;
align-content: flex-start;
align-content: flex-end;
Div Total Center
.flex-container {
display: flex;
justify-content: center;
align-items: center;
height: 300px;
background-color: orange;
}
.flex-container > div {
background-color: #f1f1f1;
color: white;
width: 100px;
height: 100px;
}
FLEX CONTENT
flex-direction: row; example
flex-direction: row-reverse; example
flex-direction: column; example
flex-direction: column-reverse; example
flex-wrap: wrap; example
flex-wrap: nowrap; example
flex-wrap: wrap-reverse; example
flex-flow: row wrap; example
justify-content: center; example
justify-content: flex-start; example
justify-content: flex-end; example
justify-content: space-around; example
justify-content: space-between; example
align-items: center; example
align-items: flex-start; example
align-items: flex-end; example
align-items: stretch; example
align-items: baseline; example
align-content: space-between; example
align-content: space-around; example
align-content: stretch; example
align-content: center; example
flex-wrap: wrap; example
align-content: flex-start; example
Total Center display: flex;
justify-content: center;
align-items: center; example
hr{
border: 0;
height: 5px;
background-image:
-webkit-gradient(linear,
left top, right top,
from(yellow), to(red));
border-radius: 5px;
}
GRADIANT HORIZONTAL LINE