Menu
Curtain Text
CCUURRTTAAIINN
Customize
Text
Props
| Property | Type | Default | Description |
|---|---|---|---|
text | string | "CURTAIN" | The text to display. |
direction | "up" | "down" | "left" | "right" | "up" | Direction chars slide OUT on hover. Reveal enters from opposite. |
resetOnLeave | boolean | true | If false, the animation stays in its hovered state once triggered. |
staggerMs | number | 60 | Delay (ms) added per character for the stagger effect. |
durationMs | number | 400 | Duration (ms) of each character's slide transition. |
easing | string | "cubic-bezier(.77,0,.18,1)" | CSS easing / timing function string for the transition. |
baseColor | string | "#ffffff" | CSS color value for the resting base layer. |
activeColor | string | "#a889c7" | CSS color value for the incoming reveal layer. |
fontClass | string | "font-black" | Tailwind font-weight class applied to both layers. (TW variants only) |
fontWeight | string | "900" | CSS font-weight applied to both layers. (CSS variants only) |
fontSize | string | "clamp(1.5rem, 6vw, 5rem)" | CSS font-size value applied to both layers. |
letterSpacing | string | "0.1em" | CSS letter-spacing value. (CSS variants only) |
tracking | string | "tracking-widest" | Tailwind letter-spacing class. (TW variants only) |
textClassName | string | "" | Extra classes for the base layer. Supports Tailwind gradients/animations. (TW variants only) |
activeClassName | string | "" | Extra classes for the reveal layer. Falls back to textClassName if empty. (TW variants only) |
className | string | "" | Extra classes forwarded to the wrapper element. |
textTypestring
Default
"CURTAIN"The text to display.
directionType"up" | "down" | "left" | "right"
Default
"up"Direction chars slide OUT on hover. Reveal enters from opposite.
resetOnLeaveTypeboolean
Default
trueIf false, the animation stays in its hovered state once triggered.
staggerMsTypenumber
Default
60Delay (ms) added per character for the stagger effect.
durationMsTypenumber
Default
400Duration (ms) of each character's slide transition.
easingTypestring
Default
"cubic-bezier(.77,0,.18,1)"CSS easing / timing function string for the transition.
baseColorTypestring
Default
"#ffffff"CSS color value for the resting base layer.
activeColorTypestring
Default
"#a889c7"CSS color value for the incoming reveal layer.
fontClassTypestring
Default
"font-black"Tailwind font-weight class applied to both layers. (TW variants only)
fontWeightTypestring
Default
"900"CSS font-weight applied to both layers. (CSS variants only)
fontSizeTypestring
Default
"clamp(1.5rem, 6vw, 5rem)"CSS font-size value applied to both layers.
letterSpacingTypestring
Default
"0.1em"CSS letter-spacing value. (CSS variants only)
trackingTypestring
Default
"tracking-widest"Tailwind letter-spacing class. (TW variants only)
textClassNameTypestring
Default
""Extra classes for the base layer. Supports Tailwind gradients/animations. (TW variants only)
activeClassNameTypestring
Default
""Extra classes for the reveal layer. Falls back to textClassName if empty. (TW variants only)
classNameTypestring
Default
""Extra classes forwarded to the wrapper element.
Crafted withbyMohammad Tasin
