Installation
This component requires CSS keyframes to be added to your global styles. The installation command will handle this automatically.
Usage
Examples
Basic Example
Simple aurora text with default gradient colors.Custom Colors
Define your own color palette for the aurora gradient.Custom Speed
Control the animation speed with thespeed prop.
Large Heading
Use in hero sections with large typography.Centered Display
Center the text and add spacing.Props
The text content to display with the aurora effect.
Array of color values for the gradient. The gradient will cycle through these colors and loop back to the first.
The speed multiplier for the animation. Higher values make the animation faster. The base duration is 10 seconds.
Additional CSS classes to apply to the outer container.
CSS Animation
The component uses a complex CSS keyframe animation that combines background position changes with rotation and scaling:How It Works
The aurora effect is created through:- Diagonal gradient: A 135-degree linear gradient cycling through the provided colors
- Large background size: 200% to allow for smooth transitions
- Background clipping: The gradient is clipped to text using
bg-clip-text - Combined animations: Background position shifts combined with subtle rotation and scale transforms
- Accessibility: Screen reader text ensures the content is accessible
Customization
Monochrome Aurora
Use shades of a single color for a more subtle effect.Vibrant Neon Effect
Use bright, saturated colors for a neon look.Pause on Hover
Freeze the animation when hovering.Warm Color Palette
Create a warm, sunset-like effect.Cool Color Palette
Create a cool, ice-like effect.Use Cases
- Hero headings: Make landing page headlines stand out
- Brand names: Emphasize company or product names
- Call-to-action text: Draw attention to important CTAs
- Feature titles: Highlight key features or benefits
- Event announcements: Make announcements more eye-catching
The aurora effect includes subtle rotation and scaling transforms that create a more dynamic, organic animation compared to simple gradient shifts.