Gradient Text
ComponentsGradient Text
TypographyNew

Gradient Text

A flowing spectrum of color for a few words you want to make unforgettable.

React + CSS
COLOR OUTSIDE THE ORDINARY

Stay a little
different.

A brighter turn of phrase.
Live component. Go ahead, interact.
Accent
01

Installation

Run this in your shadcn-configured React project. The component and stylesheet are added together.

TERMINAL
npx shadcn@latest add http://localhost:5173/r/gradient-text.json

This command uses the current site address. For localhost, keep this preview running on the same computer. Files follow your configured components alias.

02

Usage

Import the component and make the details your own.

TypeScript
import { GradientText } from '@/components/anticraft/GradientText';

export function Example() {
  return <GradientText>Stay a little different.</GradientText>;
}
03

Props

PropTypeDefaultDescription
childrenReactNodeRequiredText or inline content receiving the gradient.
colorsstring[]Orange, cream, violet, orangeTwo to eight CSS colors. Defaults to #ef9b61, #f7e6cf, #b8a0e9, #ef9b61.
speednumber8The gradient animation duration in seconds, clamped between 1 and 180.
pausedbooleanfalsePauses the gradient animation.
classNamestring''Additional classes. Native span attributes and inline styles are supported.
04

Motion & accessibility

Considered by default.

The gradient stops moving when reduced motion is preferred.

Use semantic content and meaningful labels in your composition. Check contrast and keyboard behavior with your own styles and content.