Browse documentation
Reference / Transitions & animation
Animation duration
Set the length of one animation cycle. The duration utility can override the built-in timing of a preset.
Working example
Reveal the imprint
Mono Press · Second edition
Apply the override under the same variants as the shorthand. Here both declarations begin when the disclosure opens and the user allows motion.
<details class="group rounded border p-4">
<summary class="cursor-pointer font-semibold">Reveal the imprint</summary>
<p class="mt-3 origin-left motion-safe:group-open:animate-fade-in motion-safe:group-open:animate-duration-1000">Mono Press · Second edition</p>
</details>Class reference
| Class | CSS declarations |
|---|---|
animate-duration-150 | animation-duration: 150ms; |
animate-duration-500 | animation-duration: 500ms; |
animate-duration-1000 | animation-duration: 1000ms; |
animate-duration-[1.8s] | animation-duration: 1.8s; |
animate-duration-[auto] | animation-duration: auto; |
View full generated CSS
.animate-duration-1000 {
animation-duration: 1000ms;
}
.animate-duration-150 {
animation-duration: 150ms;
}
.animate-duration-500 {
animation-duration: 500ms;
}
.animate-duration-\[1\.8s\] {
animation-duration: 1.8s;
}
.animate-duration-\[auto\] {
animation-duration: auto;
}