W2: CSS Layout Display and Overflow Flashcards
Specifies if/how an element is displayed?
display property
The default display value for most elements is ___ or ____.
block or inline.
A _____-level element always starts on a new line and takes up the full width available.
Block-level element
An ______-level element does not start on a new line and only takes up as much width as necessary.
Inline-level element
It is commonly used with JavaScript to hide and show elements without deleting and recreating them.
display: none;
What element uses display: none; as default?
<script> element. </script>
Controls what happens to content that is too big to fit into an area?
Overflow property
By default, the overflow value is ____ meaning that it is not clipped and it renders outside the element’s box.
visible or overflow: visible;
With the ____ value, the overflow is clipped, and the rest of the content is hidden.
hidden or overflow: hidden;
The overflow is clipped and a scrollbar is added to scroll inside the box horizontally and vertically.
scroll or overflow: scroll;
This overflow value is similar to scroll, but it adds scrollbars only when necessary.
auto or overflow: auto;