CSS Overflow: What It Is & How It Works?

Overflow

This property is used to define what happens if content overflows an element’s box. It means it will define whether to clip content or to add scrollbars when an element’s content is too big to fit in a specified area. This property only works for block elements with a specified height. We can set this property to visible (default), scroll, hidden, auto.

Ex:-

p { overflow: hidden; }

Diagnosis: overflow:hidden; (submenu truncated by theme CSS) - UberMenu  Troubleshooter Diagnosis

Overflow-x

This property is used to define whether to clip content, render a scroll bar, or display overflow content of a block-level element when it overflows at the left and right edges. We can set this property to visible (default), hidden, scroll, auto.

Ex: –

p { overflow-x: hidden; }

Overflow-y

This property is used to define whether to clip content, render a scroll bar, or display overflow content of a block-level element when it overflows at the top and bottom edges. We can set this property to visible (default), hidden, scroll, auto.

Ex: –

p { overflow-y: hidden; }

overflow-x hidden doesn´t let my content that is inside go out - Stack  Overflow
Tagged : / / / / /

Leave a Reply