hide mixin
Sets display to none.
@mixin hideExample
.modal-closed { @include hide;}Compiled CSS
.modal-closed { display: none;}Display, visibility, overflow and text truncation utilities.
Classes:
All classes above support responsive variants with the @breakpoint suffix:
Generated from the doc blocks in the core source when the site is built, so it always matches the current release of @wovenui/core. Every example is compiled against core during the build; open Compiled CSSunder an example to see its output. Guide: Display. The A to Z index lists every public mixin and function.
hide hidden block inline inline-block show grid inline-grid flex inline-flex table table-row table-cell visible invisible collapse contents overflow-hidden overflow-visible overflow-scroll overflow-auto overflow-x-hidden overflow-y-hidden overflow-x-scroll overflow-y-scroll overflow-x-auto overflow-y-auto truncate overflow-label truncate-lines
hide mixinSets display to none.
@mixin hideExample
.modal-closed { @include hide;}.modal-closed { display: none;}hidden mixinSets display to none, exactly like hide.
@mixin hiddenExample
.modal-closed { @include hidden;}.modal-closed { display: none;}block mixinSets display to block.
@mixin blockExample
.thumbnail { @include block;}.thumbnail { display: block;}inline mixinSets display to inline.
@mixin inlineExample
.tag-label { @include inline;}.tag-label { display: inline;}inline-block mixinSets display to inline-block.
@mixin inline-blockExample
.badge { @include inline-block;}.badge { display: inline-block;}show mixinSets display to revert, restoring the element's natural display (block for a div, table for a table) after .hide or a responsive hide.
@mixin showExample
.toolbar-label { @include show;}.toolbar-label { display: revert;}grid mixinSets display to grid, establishing a grid container.
@mixin gridExample
.gallery { @include grid;}.gallery { display: grid;}inline-grid mixinSets display to inline-grid, establishing an inline grid container.
@mixin inline-gridExample
.icon-set { @include inline-grid;}.icon-set { display: inline-grid;}flex mixinSets display to flex, establishing a flex container.
@mixin flexExample
.toolbar { @include flex;}.toolbar { display: flex;}inline-flex mixinSets display to inline-flex, establishing an inline flex container.
@mixin inline-flexExample
.chip { @include inline-flex;}.chip { display: inline-flex;}table mixinSets display to table.
@mixin tableExample
.data-grid { @include table;}.data-grid { display: table;}table-row mixinSets display to table-row.
@mixin table-rowExample
.data-grid-row { @include table-row;}.data-grid-row { display: table-row;}table-cell mixinSets display to table-cell.
@mixin table-cellExample
.data-grid-cell { @include table-cell;}.data-grid-cell { display: table-cell;}visible mixinSets visibility to visible.
@mixin visibleExample
.row-actions { @include visible;}.row-actions { visibility: visible;}invisible mixinSets visibility to hidden, keeping the element in the layout.
@mixin invisibleExample
.row-actions { @include invisible;}.row-actions { visibility: hidden;}collapse mixinSets visibility to collapse, which removes table rows and columns without changing table layout.
@mixin collapseExample
.table-row-hidden { @include collapse;}.table-row-hidden { visibility: collapse;}contents mixinSets display to contents, so the element box disappears and its children join the parent layout.
@mixin contentsExample
.field-group { @include contents;}.field-group { display: contents;}overflow-hidden mixinSets overflow to hidden on both axes.
@mixin overflow-hiddenExample
.panel { @include overflow-hidden;}.panel { overflow: hidden;}overflow-visible mixinSets overflow to visible on both axes.
@mixin overflow-visibleExample
.panel { @include overflow-visible;}.panel { overflow: visible;}overflow-scroll mixinSets overflow to scroll on both axes.
@mixin overflow-scrollExample
.panel { @include overflow-scroll;}.panel { overflow: scroll;}overflow-auto mixinSets overflow to auto on both axes.
@mixin overflow-autoExample
.panel { @include overflow-auto;}.panel { overflow: auto;}overflow-x-hidden mixinSets overflow-x to hidden (horizontal axis).
@mixin overflow-x-hiddenExample
.panel { @include overflow-x-hidden;}.panel { overflow-x: hidden;}overflow-y-hidden mixinSets overflow-y to hidden (vertical axis).
@mixin overflow-y-hiddenExample
.panel { @include overflow-y-hidden;}.panel { overflow-y: hidden;}overflow-x-scroll mixinSets overflow-x to scroll (horizontal axis).
@mixin overflow-x-scrollExample
.panel { @include overflow-x-scroll;}.panel { overflow-x: scroll;}overflow-y-scroll mixinSets overflow-y to scroll (vertical axis).
@mixin overflow-y-scrollExample
.panel { @include overflow-y-scroll;}.panel { overflow-y: scroll;}overflow-x-auto mixinSets overflow-x to auto (horizontal axis).
@mixin overflow-x-autoExample
.panel { @include overflow-x-auto;}.panel { overflow-x: auto;}overflow-y-auto mixinSets overflow-y to auto (vertical axis).
@mixin overflow-y-autoExample
.panel { @include overflow-y-auto;}.panel { overflow-y: auto;}truncate mixinTruncates text to one line with an ellipsis, or to a number of lines like truncate-lines() (truncate(2) matches the .truncate-2 class).
@mixin truncate($lines: 1)| Parameter | Type | Default | Description |
|---|---|---|---|
$lines | Number|String | 1 | Number of visible lines: 1, or a whole number above 1, calc() or var() for a multi-line clamp |
Example 1
.file-name { @include truncate;}.file-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap;}Example 2
.card-summary { @include truncate(2); // the same as truncate-lines(2)}.card-summary { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; text-overflow: ellipsis;}overflow-label mixinTruncates a flex or grid child to one line; min-width 0 lets it shrink below its content width.
@mixin overflow-labelExample
.nav-item-label { @include overflow-label;}.nav-item-label { white-space: nowrap; word-break: break-all; text-overflow: ellipsis; overflow: hidden; min-width: 0;}truncate-lines mixinClamps text to a number of lines with an ellipsis using -webkit-line-clamp.
@mixin truncate-lines($lines: 2)| Parameter | Type | Default | Description |
|---|---|---|---|
$lines | Number|String | 2 | Number of visible lines: a whole number of 1 or more, calc() or var(); anything else raises an error |
Example
.card-summary { @include truncate-lines(3);}.card-summary { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; text-overflow: ellipsis;}