81 Pro components and page blocks

Get Pro

Horizon Gradient

New

Preview

Customize

Color
top
Curve1.00
Reach1.00
Softness1.10
Speed1.0
Grain0.100

Installation

npx shadcn@latest add https://uibrik.com/r/horizon-gradient.json
Adds the files to components/uibrik/horizon-gradient. With the @uibrik namespace set up: npx shadcn@latest add @uibrik/horizon-gradient.

Usage

import { HorizonGradient } from "@/components/uibrik/horizon-gradient/horizon-gradient";​<HorizonGradient  color="#2b35d6"  direction="top"  curve={1}  reach={1}  softness={1.1}  speed={1}  grain={0.1}>  …</HorizonGradient>

Props

HorizonGradient
color
Type string
"#2b35d6"
Colour of the sky between the dark and the light; drawn in shades of it.
colors
Type string[]
["#000000","#2a0b4f","#7b2fd1","#f06aa8","#ffd2b8","#fffaf5"]
Hex colours, 2 to 6, from the dark edge to the light one. Overrides color.
direction
Type "top" | "right" | "bottom" | "left"
"top"
Edge the dark comes from; the light gathers at the opposite one.
curve
Type number
1
How strongly the bands arch; 0 is nearly level.
reach
Type number
1
How far down the dark reaches; 1 is the designed height.
softness
Type number
1.1
How gradual the bands are; higher spreads them over more of the frame.
speed
Type number
1
Animation speed; 1 is the designed pace.
grain
Type number
0.1
Film grain strength.
children
Type ReactNode
–
Content shown on top of the background.
className
Type string
–
Classes for the box; it fills whatever size you give it.