diff --git a/site/content/docs/0.0/utilities/display.md b/site/content/docs/0.0/utilities/display.md index abfd4b0127..b5b6920c2e 100644 --- a/site/content/docs/0.0/utilities/display.md +++ b/site/content/docs/0.0/utilities/display.md @@ -1,11 +1,116 @@ --- layout: docs title: Display property -description: Quickly and responsively toggle the display value of components and more with our display utilities. Includes support for some of the more common values, as well as some extras for controlling display when printing. +description: Quickly toggle the display value of components and more with our display utilities. Includes support for some of the more common values, as well as some extras for controlling display when printing. group: utilities aliases: - "/docs/utilities/display/" toc: true --- -{{< callout-soon "page" >}} +## How it works + +Change the value of the [`display` property](https://developer.mozilla.org/en-US/docs/Web/CSS/display) with our display utility classes. We purposely support only a subset of all possible values for `display`. Classes can be combined for various effects as you need. + +## Notation + + + +The classes are named using the format: + +- `.d-{value}` + + +Where *value* is one of: + +- `none` +- `inline` +- `inline-block` +- `block` +- `grid` +- `inline-grid` +- `table` +- `table-cell` +- `table-row` +- `flex` +- `inline-flex` + +The display values can be altered by changing the `display` values defined in `$utilities` and recompiling the SCSS. + + + + + +## Hiding elements + +Use display classes for showing and hiding elements. + +To hide elements simply use the `.d-none` class. + + + +{{< bs-table >}} +| Screen size | Class | +| --- | --- | +| Hidden on all | `.d-none` | +| Visible on all | `.d-block` | + + +{{< /bs-table >}} + + + +## Display in print + +Change the `display` value of elements when printing with our print display utility classes. Includes support for the same `display` values as our `.d-*` utilities. + +- `.d-print-none` +- `.d-print-inline` +- `.d-print-inline-block` +- `.d-print-block` +- `.d-print-grid` +- `.d-print-inline-grid` +- `.d-print-table` +- `.d-print-table-row` +- `.d-print-table-cell` +- `.d-print-flex` +- `.d-print-inline-flex` + +The print and display classes can be combined. + +{{< example >}} +