baselinewidely| Class | CSS |
|---|---|
| ttf:l | transition-timing-function: linear; |
| ttf:ei | transition-timing-function: ease-in; |
| ttf:eo | transition-timing-function: ease-out; |
| ttf:io | transition-timing-function: ease-in-out; |
Variants
Prefix any class with a variant to apply it only under that condition. Variants stack, as in @md:h:ttf:eo.
Breakpoints
Apply a class from a viewport width up. Each breakpoint covers its width & every width above it.
| @xs:ttf:eo | From 32rem up. |
| @sm:ttf:eo | From 40rem up. |
| @md:ttf:eo | From 48rem up. |
| @lg:ttf:eo | From 64rem up. |
| @xl:ttf:eo | From 80rem up. |
| @xxl:ttf:eo | 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:ttf:eo | Container from 32rem up. |
| @c:sm:ttf:eo | Container from 40rem up. |
| @c:md:ttf:eo | Container from 48rem up. |
| @c:lg:ttf:eo | Container from 64rem up. |
| @c:xl:ttf:eo | Container from 80rem up. |
| @c:xxl:ttf:eo | 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:ttf:eo | On a touch screen. |
| @prm:ttf:eo | With reduced motion on. |
| @st:ttf:eo | On the first frame. |
States
Apply a class only while the element is in a state, such as hovered, focused or checked.
| h:ttf:eo | On :hover. |
| f:ttf:eo | On :focus. |
| fv:ttf:eo | On :focus-visible. |
| a:ttf:eo | On :active. |
| d:ttf:eo | On :disabled. |
| fc:ttf:eo | On :first-child. |
| c:ttf:eo | On :checked. |
| e:ttf:eo | On :empty. |
| fw:ttf:eo | On :focus-within. |
| i:ttf:eo | On :invalid. |
| in:ttf:eo | On :indeterminate. |
| lc:ttf:eo | On :last-child. |
| nc:ttf:eo | On :nth-child. |
| r:ttf:eo | On :required. |
| ro:ttf:eo | On :read-only. |
| v:ttf:eo | On :valid. |
Pseudo Elements
Style a part of the element rather than the element itself, such as its placeholder or the selected text.
| a::ttf:eo | On ::after. |
| b::ttf:eo | On ::before. |
| p::ttf:eo | On ::placeholder. |
| s::ttf:eo | On ::selection. |
Working with easings
Name a curve once in theme.easings, written as any CSS timing function. Each name becomes a ttf: & an atf: class.
import { defineConfig } from "yummacss";
export default defineConfig({ theme: { easings: { "out-quart": "cubic-bezier(0.25, 1, 0.5, 1)", }, },});