Menu

1.12Conditional Styling

Concise uses a set of classes for conditional styling based on browser viewport, screen resolution, if the document is currently being printed and lastly, if the document is being viewed on a high-definition screen (Retina/HiDPI).

Displaying Content

These classes determine if content will be shown given a certain browser viewport. If the user is not within that browser viewport, the content will be hidden.

ClassExtra Large
≥ 1280px
Large
≥ 1100px
Medium
≥ 960px
Small
≥ 768px
Extra Small
≤ 480px
.show--xsmHiddenHiddenHiddenHiddenVisible
.show--smHiddenHiddenHiddenVisibleHidden
.show--mdHiddenHiddenVisibleHiddenHidden
.show--lgHiddenVisibleHiddenHiddenHidden
.show--xlgVisibleHiddenHiddenHiddenHidden

Hiding Content

These classes determine if content will be hidden given a certain browser viewport. If the user is not within that browser viewport, the content will be shown.

ClassExtra Large
≥ 1280px
Large
≥ 1100px
Medium
≥ 960px
Small
≥ 768px
Extra Small
≤ 480px
.hide--xsmVisibleVisibleVisibleVisibleHidden
.hide--smVisibleVisibleVisibleHiddenVisible
.hide--mdVisibleVisibleHiddenVisibleVisible
.hide--lgVisibleHiddenVisibleVisibleVisible
.hide--xlgHiddenVisibleVisibleVisibleVisible

Print Content

Content also can be displayed or hidden based on whether the document is currently being printed or not.

ClassBrowserPrint
.show--printHiddenVisible
.hide--printVisibleHidden

High-Definition Content

Lastly, content can be displayed or hidden based on whether the document is currently being viewed on a high-definition screen (Retina/HiDPI).

ClassRegular ResolutionHigh-Definition
.show--hdHiddenVisible
.hide--hdVisibleHidden