CSS Flashcards
What are the names of the individual pieces of a CSS rule?
selector, property, value
In CSS, how do you select elements by their class attribute?
dot class (.)
In CSS, how do you select elements by their type?
simply element name
In CSS, how do you select an element by its id attribute?
pound sign (#)
Name three different types of values you can use to specify colors in CSS.
color name, rgb, hexadecimal
What CSS properties make up the box model?
margin, padding, border, content
Which CSS property pushes boxes away from each other?
margin
Which CSS property add space between a box’s content and its border?
padding
What is a pseudo-class?
pseudo-class is used to define a special state of an element.
Name at least two units of type size in CSS.
px, em, rem
What CSS property controls the font used for the text inside an element?
font-family
What is the default flex-direction of a flex container?
row
What is the default flex-wrap of a flex container?
nowrap
What is the default value for the position property of HTML elements?
static
How does setting position: relative on an element affect document flow?
none unless specified otherwise with offsets top, bottom, left, right