General Flashcards
css: box-sizing: border-box
Makes the size inclusive of border and padding
css: margin: 0 auto;
helps to centre horizontally, a width must be set for it to work
css: .breadcrumb li+li::before {
content: “>”;
}
Separator in breadcrumbs
css: display: flex;
Or. display: inline-flex
Designate an item as a flex container
css {
justify-content: flex-start;
flex-end;
centre;
space-around;
space-between
Five commonly used options to distribute within a flex-container.
css {
align-items: flex-start;
flex-end;
center
baseline;
stretch;
5 commonly used align-items properties to flex vertically -cross axis- within a flex-container
css {
flex-basis: npx
}
To specify a width of an item before it stretches or shrinks.
css {
flex-wrap: wrap;
wrap-reverse;
no-wrap;
Use on containers to apply to child items
css {
align-content: flex-start;
flex-end;
center;
space-between;
space-around;
stretch;
For aligning multiple rows vertically in a flex container. essentially shares values with align items.
css: {
flex-flow:
Shorthand for flex direction and flex-wrap (in this order).
css {
flex: (flex-grow flex-shrink flex-basis)
Flex is shorthand for the 3 values
css {
display: grid;
}
Setup a grid!
css: cursor: pointer;
Change the arrow to a point hand
css: ELEMENT:hover {
pseudo class to do something when the cursor is over it
css {
gap: rowpx colpx;
}
Set row and column spacing