(Text, Borders, and Images) Flashcards
7 cards from real CSS practice questions. Tap to flip, then mark Knew It or Still Learning โ missed cards come back until you master them.
Read the first 7 (Text, Borders, and Images) flashcards as text
Which property aligns text horizontally within its container?
Answer: text-align
text-align controls horizontal alignment of inline content.
What does 'background-size: cover' do?
Answer: Scales the image to fill the container, cropping if needed
cover scales the image to completely fill the box, cropping overflow.
Which value of border-style draws two parallel lines?
Answer: double
double renders the border as two solid lines.
How do you add a shadow to text?
Answer: text-shadow
text-shadow applies a shadow effect to text.
Which property controls whether a border is shown only on the bottom?
Answer: border-bottom
border-bottom sets the border on the bottom edge only.
What does 'text-decoration: line-through' produce?
Answer: A strikethrough line over the text
line-through draws a line through the middle of the text.
Which property positions a background image within its element?
Answer: background-position
background-position sets where the image is placed in the box.