uibrik

Fluted Glass

Preview

Customize

Colors
Ribs28px
Magnify3.0
Curve0.60
Shading0.80
Frost0.15
Dispersion0.30
Angle0°
Band angle-50°
Band width1.00
Flow1.00
Speed1.0
Grain0.050
Seed0
Bend1.00
Shine1.00
Reach160px
Follow0.70

Usage

import { FlutedGlass } from "@/components/uibrik/fluted-glass/fluted-glass";

<FlutedGlass />

Installation

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

Props

FlutedGlass
colors
Type string[]
["#03060c","#0b3f86","#1a7fd4","#cfe3f4","#f7c2a6"]
From the dark to the core of the band, blended in OKLCH; 2 to 6 colours.
ribs
Type number
28
Width of each rib.
magnify
Type number
3
How much of the scene each rib squeezes into its width; 1 is flat glass.
curve
Type number
0.6
Extra squeeze toward the rib edges.
shading
Type number
0.8
Dark-to-light shading across each rib, and the seams between them.
frost
Type number
0.15
Blur through the glass.
dispersion
Type number
0.3
Colour split toward the rib edges.
angle
Type number
0
Rib direction; 0 is vertical.
bandAngle
Type number
-50
Direction of the band of light.
bandWidth
Type number
1
Thickness of the band of light.
flow
Type number
1
How much the band sways.
speed
Type number
1
Animation speed; 1 is the designed pace.
grain
Type number
0.05
Film grain strength.
seed
Type number
0
Shifts the composition, so two backgrounds with the same settings still differ.
animate
Type boolean
true
Move on its own. Off draws one still frame.
interactive
Type boolean
true
React to the pointer.
bend
Type number
1
How far the band of light bends toward the pointer.
shine
Type number
1
How strongly the glass catches the light near the pointer.
reach
Type number
160
How far the pointer's effects reach.
follow
Type number
0.7
How lazily the light follows the pointer, 0 (locked) to 1 (drifts after it).
children
Type ReactNode
–
Content shown on top of the background.
className
Type string
–
Classes for the box; it fills whatever size you give it.