Background

Background Size

Style syntax for setting the size of the background image.

🚧This page is still under construction and some content may not be complete.

Overview [sr-only]

ClassDeclarations
background-size:width / background:width / bg:widthbackground-size: width
background-size:width|heightbackground-size: width height
background-size:size,background-size: sizerem,
bg:autobackground-size: auto
bg:coverbackground-size: cover
bg:containbackground-size: contain

Conditionally apply

Apply styles in different states using selectors, media queries, etc.

<div class="background-size:10%|20:hover background-size:10%|20@sm background-size:10%|20@dark background-size:10%|20@print"></div>
PREVIOUS
Background Repeat

Style syntax for setting how background images are repeated.

NEXT
Border

Style syntax for setting an element’s border.

MIT License © Aoyue Design LLC.