Animate UI

Flip Button

An animated flip button component with a variety of styles.

Made by imskyleen
Edit on GitHub

Installation

Usage

<FlipButton>
  <FlipButtonFront>Front</FlipButtonFront>
  <FlipButtonBack>Back</FlipButtonBack>
</FlipButton>

API Reference

FlipButton

Animate UI API Reference - Flip Button Primitive
PropTypeDefault
variant?
"default" | "accent" | "destructive" | "outline" | "secondary" | "ghost" | "link"
default
size?
"default" | "sm" | "lg" | "icon"
default
from?
'top' | 'right' | 'bottom' | 'left'
top
tapScale?
number
0.95
...props?
HTMLMotionProps<"button">
-

FlipButtonFront

Animate UI API Reference - Flip Button Front Primitive
PropTypeDefault
variant?
"default" | "accent" | "destructive" | "outline" | "secondary" | "ghost" | "link"
default
size?
"default" | "sm" | "lg" | "icon"
default
transition?
Transition
{ type: 'spring', stiffness: 280, damping: 20 }
...props?
HTMLMotionProps<"span">
-

FlipButtonBack

Animate UI API Reference - Flip Button Back Primitive
PropTypeDefault
variant?
"default" | "accent" | "destructive" | "outline" | "secondary" | "ghost" | "link"
default
size?
"default" | "sm" | "lg" | "icon"
default
transition?
Transition
{ type: 'spring', stiffness: 280, damping: 20 }
...props?
HTMLMotionProps<"span">
-

Credits

Built by Skyleen. The source code is available on GitHub.