Challenge - 5 Problems
Display Mode Master
Get all challenges correct to earn this badge!
Test your skills under time pressure!
🧠 Conceptual
intermediate2:00remaining
What happens when you use
block display mode?In Tailwind CSS, what visual effect does applying
block display mode have on an element?Attempts:
2 left
💡 Hint
Think about how paragraphs behave in a text document.
✗ Incorrect
Block elements take up the full width and start on a new line, pushing content below them. This is why block display mode makes elements behave like paragraphs or divs.
📝 Syntax
intermediate2:00remaining
Which Tailwind class correctly sets an element to inline display?
You want an element to flow inline with text and other elements. Which Tailwind CSS class should you use?
Attempts:
2 left
💡 Hint
Inline elements do not start on a new line and only take as much width as needed.
✗ Incorrect
The inline class sets the display to inline, making the element flow with text and other inline elements.
❓ rendering
advanced2:00remaining
What is the visual difference between
inline and inline-block display modes?Consider two elements styled with Tailwind classes
inline and inline-block. What is the key visual difference you will see in the browser?Attempts:
2 left
💡 Hint
Try setting width on both types and see what happens.
✗ Incorrect
inline-block elements behave like inline elements but allow setting width and height. inline elements ignore width and height settings.
❓ selector
advanced2:00remaining
Which Tailwind class combination creates a flex container with items stacked vertically?
You want a container to use flexbox and stack child items vertically. Which Tailwind classes achieve this?
Attempts:
2 left
💡 Hint
Flex direction controls stacking direction.
✗ Incorrect
flex makes the container a flexbox. flex-col sets the direction to column, stacking items vertically.
❓ accessibility
expert3:00remaining
Why is choosing the right display mode important for keyboard navigation?
How can incorrect display modes affect users who navigate websites using only a keyboard?
Attempts:
2 left
💡 Hint
Think about how elements appear and behave visually and structurally.
✗ Incorrect
Some display modes can hide elements or change their flow, making it impossible for keyboard users to reach them with tab keys. Proper display ensures all interactive elements are accessible.