Inset Utilities

The inset utilities provide a set of classes to adjust the inset, inset-inline, inset-block, inset-inline-start, inset-inline-end, inset-block-start, inset-block-end, top, right, bottom and left properties of elements.

Inset

Class NamePropertyValue
.inset-0inset0
.inset-autoinsetauto
.inset-fullinset100%
.inset-quarterinset25%
.inset-halfinset50%
.inset-three-quartersinset75%
.inset-thirdinsetcalc(100%/ 3)
.inset-two-thirdsinsetcalc(100%/ 1.5)

Inset X

Class NamePropertyValue
.inset-x-0inset-x0
.inset-x-autoinset-xauto
.inset-x-fullinset-x100%
.inset-x-quarterinset-x25%
.inset-x-halfinset-x50%
.inset-x-three-quartersinset-x75%
.inset-x-thirdinset-xcalc(100%/ 3)
.inset-x-two-thirdsinset-xcalc(100%/ 1.5)

Inset Y

Class NamePropertyValue
.inset-y-0inset-y0
.inset-y-autoinset-yauto
.inset-y-fullinset-y100%
.inset-y-quarterinset-y25%
.inset-y-halfinset-y50%
.inset-y-three-quartersinset-y75%
.inset-y-thirdinset-ycalc(100%/ 3)
.inset-y-two-thirdsinset-ycalc(100%/ 1.5)

Inset Inline

Class NamePropertyValue
.inset-inline-0inset-inline0
.inset-inline-autoinset-inlineauto
.inset-inline-fullinset-inline100%
.inset-inline-quarterinset-inline25%
.inset-inline-halfinset-inline50%
.inset-inline-three-quartersinset-inline75%
.inset-inline-thirdinset-inlinecalc(100%/ 3)
.inset-inline-two-thirdsinset-inlinecalc(100%/ 1.5)

Inset Block

Class NamePropertyValue
.inset-block-0inset-block0
.inset-block-autoinset-blockauto
.inset-block-fullinset-block100%
.inset-block-quarterinset-block25%
.inset-block-halfinset-block50%
.inset-block-three-quartersinset-block75%
.inset-block-thirdinset-blockcalc(100%/ 3)
.inset-block-two-thirdsinset-blockcalc(100%/ 1.5)

Inset Inline Start

Class NamePropertyValue
.inset-inline-start-0inset-inline-start0
.inset-inline-start-autoinset-inline-startauto
.inset-inline-start-fullinset-inline-start100%
.inset-inline-start-quarterinset-inline-start25%
.inset-inline-start-halfinset-inline-start50%
.inset-inline-start-three-quartersinset-inline-start75%
.inset-inline-start-thirdinset-inline-startcalc(100%/ 3)
.inset-inline-start-two-thirdsinset-inline-startcalc(100%/ 1.5)

Inset Inline End

Class NamePropertyValue
.inset-inline-end-0inset-inline-end0
.inset-inline-end-autoinset-inline-endauto
.inset-inline-end-fullinset-inline-end100%
.inset-inline-end-quarterinset-inline-end25%
.inset-inline-end-halfinset-inline-end50%
.inset-inline-end-three-quartersinset-inline-end75%
.inset-inline-end-thirdinset-inline-endcalc(100%/ 3)
.inset-inline-end-two-thirdsinset-inline-endcalc(100%/ 1.5)

Inset Block Start

Class NamePropertyValue
.inset-block-start-0inset-block-start0
.inset-block-start-autoinset-block-startauto
.inset-block-start-fullinset-block-start100%
.inset-block-start-quarterinset-block-start25%
.inset-block-start-halfinset-block-start50%
.inset-block-start-three-quartersinset-block-start75%
.inset-block-start-thirdinset-block-startcalc(100%/ 3)
.inset-block-start-two-thirdsinset-block-startcalc(100%/ 1.5)

Inset Block End

Class NamePropertyValue
.inset-block-end-0inset-block-end0
.inset-block-end-autoinset-block-endauto
.inset-block-end-fullinset-block-end100%
.inset-block-end-quarterinset-block-end25%
.inset-block-end-halfinset-block-end50%
.inset-block-end-three-quartersinset-block-end75%
.inset-block-end-thirdinset-block-endcalc(100%/ 3)
.inset-block-end-two-thirdsinset-block-endcalc(100%/ 1.5)

Top

Class NamePropertyValue
.top-0top0
.top-autotopauto
.top-fulltop100%
.top-quartertop25%
.top-halftop50%
.top-three-quarterstop75%
.top-thirdtopcalc(100%/ 3)
.top-two-thirdstopcalc(100%/ 1.5)
Class NamePropertyValue
.right-0right0
.right-autorightauto
.right-fullright100%
.right-quarterright25%
.right-halfright50%
.right-three-quartersright75%
.right-thirdrightcalc(100%/ 3)
.right-two-thirdsrightcalc(100%/ 1.5)

Bottom

Class NamePropertyValue
.bottom-0bottom0
.bottom-autobottomauto
.bottom-fullbottom100%
.bottom-quarterbottom25%
.bottom-halfbottom50%
.bottom-three-quartersbottom75%
.bottom-thirdbottomcalc(100%/ 3)
.bottom-two-thirdsbottomcalc(100%/ 1.5)

Left

Class NamePropertyValue
.left-0left0
.left-autoleftauto
.left-fullleft100%
.left-quarterleft25%
.left-halfleft50%
.left-three-quartersleft75%
.left-thirdleftcalc(100%/ 3)
.left-two-thirdsleftcalc(100%/ 1.5)

Customization

To customize the alignment utilities, you can use the following variables.

VariableDescriptionDefault Value
$selector-baseBase selector for utility classes."."
$selector-prefixThe selector prefix for all utility classes.""
$selector-suffixThe selctor suffix for all utility classes.""
$selector-separatorThe selector separator for all utility classes.""
$use-importantAppends !important to generated utility declarations.true
$generate-base-utilitiesGenerates the base utility classes.true
$screen-awareEnables screen-aware utility variants.false
$theme-awareEnables theme-aware utility variants.false
$scheme-awareEnables scheme-aware utility variants.false
$state-awareEnables state-aware utility variants.false
$container-awareEnables container-aware utility variants.false
$screen-aware-selector-prefixPrefix to the screen-aware portion of utility selectors.""
$screen-aware-selector-suffixSuffix to the screen-aware portion of utility selectors.""
$screen-aware-selector-separatorSeparator inserted for screen-aware utility selectors."\\:"
$theme-aware-selector-prefixPrefix to the theme-aware portion of utility selectors.""
$theme-aware-selector-suffixSuffix to the theme-aware portion of utility selectors."-theme"
$theme-aware-selector-separatorSeparator inserted for theme-aware utility selectors."\\:"
$scheme-aware-selector-prefixPrefix to the scheme-aware portion of utility selectors.""
$scheme-aware-selector-suffixSuffix to the scheme-aware portion of utility selectors."-mode"
$scheme-aware-selector-separatorSeparator inserted for scheme-aware utility selectors."\\:"
$state-aware-selector-prefixPrefix to the state-aware portion of utility selectors.""
$state-aware-selector-suffixSuffix to the state-aware portion of utility selectors.""
$state-aware-selector-separatorSeparator inserted for state-aware utility selectors."\\:"
$container-aware-selector-prefixPrefix to the container-aware portion of utility selectors."cq\\:"
$container-aware-selector-suffixSuffix to the container-aware portion of utility selectors.""
$container-aware-selector-separatorSeparator inserted for container-aware utility selectors."\\:"
$utility-propertiesMap of utility properties.()
$utility-valuesMap of utility values.()
$utility-mapMap of utility property/value pairs.()

Responsive Variants

Generating responsive utility classes can be done by setting $screen-aware, $theme-aware, $scheme-aware, $state-aware, or $container-aware to true.

By default, screen-aware responsive utility classes are generated for inset.

✏️ Note

For more information on responsive variants, refer to the Responsive utility classes documentation.