/* Positional alignment */
justify-content: center; /* Pack items around the center */
justify-content: start; /* Pack items from the start */
justify-content: end; /* Pack items from the end */
justify-content: flex-start; /* Pack flex items from the start */
justify-content: flex-end; /* Pack flex items from the end */
justify-content: left; /* Pack items from the left */
justify-content: right; /* Pack items from the right */
/* Baseline alignment */
/* justify-content does not take baseline values */
/* Normal alignment */
justify-content: normal;
/* Distributed alignment */
justify-content: space-between; /* Distribute items evenly
The first item is flush with the start,
the last is flush with the end */
justify-content: space-around; /* Distribute items evenly
Items have a half-size space
on either end */
justify-content: space-evenly; /* Distribute items evenly
Items have equal space around them */
justify-content: stretch; /* Distribute items evenly
Stretch 'auto'-sized items to fit
the container */
/* Overflow alignment */
justify-content: safe center;
justify-content: unsafe center;
/* Global values */
justify-content: inherit;
justify-content: initial;
justify-content: unset;
display:
> flex <!-- Creates a flex-box container. Items in this container
become flex-box items. Useful for laying out elements in a single
row or column responsively. These items can have the following declerations
applied to them: -->
flex-direction: determines which direction is the main axis
> row <!-- Main axis is left to right -->
> row-reversed <!-- Main axis is right to left -->
> column <!-- Main axis is top to bottom -->
> column-reversed <!-- Main axis is bottom to bottom -->
flex-wrap: wraps content in flexcontainer if necessary
> nowrap (default)
> wrap
flex-flow: specifies both flex-direction and flex-wrap
> ex = flex-flow: row wrap
justify-content: determines how elements are positioned along main axis (again, main axis is set by flex direction)
> flex-start <!-- This is affected accordingly if main axis is reversed -->
> flex-end <!-- This is affected accordingly if main axis is reversed -->
> center
> etc.
align-items: determines how elements are positioned along the non main axis, the cross axis (again, main axis is set by flex direction)
> flex-start <!-- This is affected accordingly if main axis is reversed -->
> flex-end <!-- This is affected accordingly if main axis is reversed -->
> center
> etc.
> Note, align-items has a different meaning if display from above is NOT set to flex and is set to grid, ie (display: grid)
When items are wraped, you use flex-content to change how rows are positioned to each other
align-content:
> center
> space-between
> space-around
> etc.
Code Example |
---|
Html :: upload icon font awesome |
Html :: html power |
Html :: html accept png and jpg |
Html :: bootstrap height 100vh class |
Html :: how to change font size in html |
Html :: fontawesome |
Html :: html option disabled |
Html :: link javascript to html |
Html :: ver pdf en html |
Html :: html image googe drive |
Html :: how to change tab logo html |
Html :: target blank |
Html :: gradient on top of image css |
Html :: how to insert degree symbol in html |
Html :: html indice |
Html :: html select tag default value |
Html :: html align text right |
Html :: min number input html |
Html :: span limit text length |
Html :: favicon htmk |
Html :: link style page with html page in django |
Html :: get input value on button click javascript |
Html :: disable textarea html |
Html :: how to navigate to another page in html |
Html :: bold text in input field |
Html :: how to make circle button in bootstrap |
Html :: my dixon earbuds are not in sync |
Html :: ol list |
Html :: type phone number html |
Html :: html button with link |