- Docs
- Components
- 3D & Shaders
- Frame Border
A crisp, glowing border that frames any content
| Name | Type | Default | Description |
|---|---|---|---|
colors | [string, string] | ["#5227FF", "#FF9FFC"] | Two colours blended in OKLCH along the frame. The gradient slowly travels around it. |
backgroundColor | string | "transparent" | Fill behind the frame. Transparent reads the page colour. On light colours the frame switches to a fine inked line with a tinted glow. |
radius | number | 16 | Corner radius of the line in px. The root is rounded to match. |
lineWidth | number | 1 | Width of the border line in px. It stays crisp at any size. 0 hides it. |
inset | number | 0 | Distance in px between the edge of the element and the line. |
glow | number | 0.5 | Strength of the soft inner glow. |
glowWidth | number | 110 | How far the glow reaches inward, in px. It always fades to zero. |
noise | number | 0.6 | How much the flowing noise moves through the glow and along the line, from 0 to 1. |
noiseScale | number | 3 | Density of the noise. Higher values give more, smaller patches. |
flowSpeed | number | 1 | Speed of the light travelling around the frame. Hovering speeds it up gently. |
pulseSpeed | number | 1 | Speed of the twin pulses a click sends from the nearest edge. They meet on the opposite side. |
idlePulses | number | 3 | Soft swells of light that drift along the frame after the intro. 0 turns them off. |
idleSpeed | number | 1 | Speed of the idle swells. |
idleStrength | number | 1 | Brightness of the idle swells. |
intensity | number | 1 | Overall brightness of the line and glow. |
opacity | number | 1 | Opacity of the light layer. |
grain | number | 0 | Film grain over the light, from 0 to 1. |
interactive | boolean | true | Enables click pulses and the hover speed-up. Clicks stack. |
intro | boolean | true | Draws the border in from the top, then fades the glow in. |
paused | boolean | false | Stops all motion. Reduced-motion users get a still frame. |
dpr | number | 2 | Maximum device pixel ratio for the canvas. |
width | string | number | "100%" | Width of the root element. |
height | string | number | "100%" | Height of the root element. |
children | ReactNode | undefined | Content shown inside the frame, above the light. |
ref | { pulse, replay } | undefined | pulse(x?, y?) sends twin pulses from a point in px. replay() draws the border in again. |
className | string | undefined | Classes for the root element. |
style | CSSProperties | undefined | Inline styles for the root element. |
colors[string, string]Two colours blended in OKLCH along the frame. The gradient slowly travels around it.
["#5227FF", "#FF9FFC"]backgroundColorstringFill behind the frame. Transparent reads the page colour. On light colours the frame switches to a fine inked line with a tinted glow.
"transparent"radiusnumberCorner radius of the line in px. The root is rounded to match.
16lineWidthnumberWidth of the border line in px. It stays crisp at any size. 0 hides it.
1insetnumberDistance in px between the edge of the element and the line.
0glownumberStrength of the soft inner glow.
0.5glowWidthnumberHow far the glow reaches inward, in px. It always fades to zero.
110noisenumberHow much the flowing noise moves through the glow and along the line, from 0 to 1.
0.6noiseScalenumberDensity of the noise. Higher values give more, smaller patches.
3flowSpeednumberSpeed of the light travelling around the frame. Hovering speeds it up gently.
1pulseSpeednumberSpeed of the twin pulses a click sends from the nearest edge. They meet on the opposite side.
1idlePulsesnumberSoft swells of light that drift along the frame after the intro. 0 turns them off.
3idleSpeednumberSpeed of the idle swells.
1idleStrengthnumberBrightness of the idle swells.
1intensitynumberOverall brightness of the line and glow.
1opacitynumberOpacity of the light layer.
1grainnumberFilm grain over the light, from 0 to 1.
0interactivebooleanEnables click pulses and the hover speed-up. Clicks stack.
trueintrobooleanDraws the border in from the top, then fades the glow in.
truepausedbooleanStops all motion. Reduced-motion users get a still frame.
falsedprnumberMaximum device pixel ratio for the canvas.
2widthstring | numberWidth of the root element.
"100%"heightstring | numberHeight of the root element.
"100%"childrenReactNodeContent shown inside the frame, above the light.
undefinedref{ pulse, replay }pulse(x?, y?) sends twin pulses from a point in px. replay() draws the border in again.
undefinedclassNamestringClasses for the root element.
undefinedstyleCSSPropertiesInline styles for the root element.
undefined