Giter VIP home page Giter VIP logo

fewds-css-overflow's Introduction

Overflow

In CSS, there's an overflow property that allows the overflow of content to be controlled. Overflow can be set to visible, hidden, scroll, or auto. When the overflow is set to visible, you will be able to see content overflow outside of the fixed-size container, whereas when you set overflow to hidden the content will get truncated or chopped at the edge of the parent container.

You can can also set overflow to scroll which will insert scroll bars into the element. Setting the overflow to auto will detect if the content is larger than the parent element, and will only create scroll bars if necessary.

<iframe width="100%" height="300" src="//jsfiddle.net/flatiron_school/sFfw5/embedded/html,css,result/" allowpaymentrequest allowfullscreen="allowfullscreen" frameborder="0"></iframe>

The first element in the example is set with overflow to hidden, and the text is getting chopped off inside of the element. On the next one the overflow is set to scroll, so you can see a small scroll bar that will allow the content inside of the element to be scrolled. Lastly, wthere's an element with an overflow set to visible. You can see the overflowing content popping outside of the element.

Note: It's important that you always have a fixed height set on that element in order to use the overflow property.

fewds-css-overflow's People

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.