Expand description
Utilities for controlling the position of an element’s background image.
| Class | Properties |
|---|---|
| bg-bottom | background-position: bottom; |
| bg-center | background-position: center; |
| bg-left | background-position: left; |
| bg-left-bottom | background-position: left bottom; |
| bg-left-top | background-position: left top; |
| bg-right | background-position: right; |
| bg-right-bottom | background-position: right bottom; |
| bg-right-top | background-position: right top; |
| bg-top | background-position: top; |
§Arbitrary values
Any <position> property is allowed as arbitrary value.
For example, bg-[position:0px_0px,bottom_12cm_right_-6px].
§Tailwind compatibility
When using arbitrary values, you must specify the position hint
to disambiguate between this plugin and the background_size plugin.
That’s not the case in Tailwind: background-position is preferred over background-size.