CSS Flashcards
What CSS property controls the font used for the text inside an element?
font-family
What is a pseudo-class?
keyword added to a selector that specifies a special state of the selected element
What are CSS pseudo-classes useful for?
apply a style to an element
What CSS properties make up the box model?
Content, padding, boarder, margin
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 are the names of the individual pieces of a CSS rule?
property : value;
In CSS, how do you select elements by their class attribute?
.className
In CSS, how do you select elements by their type?
the corresponding tag name
In CSS, how do you select an element by its id attribute?
idName
What is the default flex-direction of a flex container?
row
What is the default flex-wrap of a flex container?
wrap
Why do two div elements “vertically stack” on one another by default?
Because they are block elements (they start start on a new line)
What is the default flex-direction of an element with display: flex?
row
What is the default value for the position property of HTML elements?
static (normal flow)