baselinewidely| Class | CSS |
|---|---|
| sb:auto | scroll-behavior: auto; |
| sb:s | scroll-behavior: smooth; |
Variants
Prefix any class with a variant to apply it only under that condition. Variants stack, as in @md:h:sb:s.
Breakpoints
Apply a class from a viewport width up. Each breakpoint covers its width & every width above it.
| @xs:sb:s | From 32rem up. |
| @sm:sb:s | From 40rem up. |
| @md:sb:s | From 48rem up. |
| @lg:sb:s | From 64rem up. |
| @xl:sb:s | From 80rem up. |
| @xxl:sb:s | From 96rem up. |
Containers
Apply a class from a container's width up, not the viewport's. Mark the parent with ct:is first.
| @c:xs:sb:s | Container from 32rem up. |
| @c:sm:sb:s | Container from 40rem up. |
| @c:md:sb:s | Container from 48rem up. |
| @c:lg:sb:s | Container from 64rem up. |
| @c:xl:sb:s | Container from 80rem up. |
| @c:xxl:sb:s | Container from 96rem up. |
Media
Apply a class when the device or the page matches a condition, or on the first frame an element renders.
| @pc:sb:s | On a touch screen. |
| @prm:sb:s | With reduced motion on. |
| @st:sb:s | On the first frame. |
States
Apply a class only while the element is in a state, such as hovered, focused or checked.
| h:sb:s | On :hover. |
| f:sb:s | On :focus. |
| fv:sb:s | On :focus-visible. |
| a:sb:s | On :active. |
| d:sb:s | On :disabled. |
| fc:sb:s | On :first-child. |
| c:sb:s | On :checked. |
| e:sb:s | On :empty. |
| fw:sb:s | On :focus-within. |
| i:sb:s | On :invalid. |
| in:sb:s | On :indeterminate. |
| lc:sb:s | On :last-child. |
| nc:sb:s | On :nth-child. |
| r:sb:s | On :required. |
| ro:sb:s | On :read-only. |
| v:sb:s | On :valid. |
Pseudo Elements
Style a part of the element rather than the element itself, such as its placeholder or the selected text.
| a::sb:s | On ::after. |
| b::sb:s | On ::before. |
| p::sb:s | On ::placeholder. |
| s::sb:s | On ::selection. |