Skip to content

Latest commit

 

History

History
147 lines (140 loc) · 6 KB

File metadata and controls

147 lines (140 loc) · 6 KB
title Overflow
description Atomic overflow classes allow you to change an element's overflow properties quickly.
<script lang="ts"> import ClassTable from '$components/ClassTable.svelte'; import Example from '$components/Example.svelte'; import type { ClassTableRow } from '$components/ClassTable.svelte'; const classes: ClassTableRow[] = [ { class: '.overflow-auto', output: 'overflow: auto;', define: 'If content fits inside the content box, it looks the same as visible, but still establishes a new block-formatting context. Desktop browsers like Firefox provide scrollbars if content overflows.' }, { class: '.overflow-x-auto', output: 'overflow-x: auto;', define: 'If content fits inside the content box, it looks the same as visible in the x dimension, but still establishes a new block-formatting context. Desktop browsers like Firefox provide scrollbars if content overflows.' }, { class: '.overflow-y-auto', output: 'overflow-y: auto;', define: 'If content fits inside the content box, it looks the same as visible in the y dimension, but still establishes a new block-formatting context. Desktop browsers like Firefox provide scrollbars if content overflows.' }, { class: '.overflow-hidden', output: 'overflow: hidden;', define: 'Content is clipped if necessary to fit the content box. No scrollbars are provided.' }, { class: '.overflow-x-hidden', output: 'overflow-x: hidden;', define: 'Content is clipped if necessary to fit the content box. No scrollbars are provided in the x dimension.' }, { class: '.overflow-y-hidden', output: 'overflow-y: hidden;', define: 'Content is clipped if necessary to fit the content box. No scrollbars are provided in the y dimension.' }, { class: '.overflow-scroll', output: 'overflow: scroll;', define: 'Content is clipped if necessary to fit the content box. Browsers display scrollbars whether or not any content is actually clipped. (This prevents scrollbars from appearing or disappearing when the content changes.) Printers may still print overflowing content.' }, { class: '.overflow-x-scroll', output: 'overflow-x: scroll;', define: 'Content is clipped if necessary to fit the content box. Browsers display scrollbars whether or not any content is actually clipped in the x dimension.' }, { class: '.overflow-y-scroll', output: 'overflow-y: scroll;', define: 'Content is clipped if necessary to fit the content box. Browsers display scrollbars whether or not any content is actually clipped in the y dimension.' }, { class: '.overflow-visible', output: 'overflow: visible;', define: 'Content is not clipped and may be rendered outside the content box. This is the default value.' } ]; </script>

Classes

<ClassTable {classes} />

Examples

<div class="overflow-auto"></div>
<div class="overflow-x-auto"></div>
<div class="overflow-y-auto"></div>
<div class="overflow-hidden"></div>
<div class="overflow-x-hidden"></div>
<div class="overflow-y-hidden"></div>
<div class="overflow-scroll"></div>
<div class="overflow-x-scroll"></div>
<div class="overflow-y-scroll"></div>
<div class="overflow-visible"></div>
.overflow-auto
.overflow-x-auto
.overflow-y-auto
.overflow-hidden
.overflow-x-hidden
.overflow-y-hidden
.overflow-scroll
.overflow-x-scroll
.overflow-y-scroll
.overflow-visible