Ink Flow
A native WebGL hero background where fountain-pen pigment slowly disperses through warm, textured watercolor paper.
Installation#
pnpm dlx shadcn@latest add @davinciui/ink-flowUsage#
API Reference#
| Prop | Type | Default |
|---|---|---|
speedRate at which the ink evolves. Set to 0 to freeze the current frame. | number | 0.22 |
scaleSpatial scale of the ink structures. Lower values produce broader forms. | number | 1 |
saturationPigment saturation. Set to 0 for a neutral rendering. | number | 1 |
contrastSeparation between the paper and pigment tones. | number | 1 |
paperColorWarm paper base color. | string | "#F6EFD3" |
softInkColorColor used for broad, diffused ink washes. | string | "#9DA5B6" |
deepInkColorColor used for concentrated pigment regions. | string | "#3C2FAA" |
accentColorRare accent color used for thin ink veins. | string | "#F5AED9" |
maxDprMaximum device pixel ratio used by the canvas backing buffer. | number | 2 |
classNameAdditional classes applied to the full-size background layer. | string | — |
Accessibility#
The component is purely decorative: the wrapper is aria-hidden and pointer-events-none, with no focus targets. Screen readers skip the ink field, so supply any needed text in surrounding content.
Motion#
Ink animates continuously through a WebGL fragment shader driven by requestAnimationFrame; the speed prop sets evolution rate, and speed 0 freezes the frame. It detects prefers-reduced-motion, stops the loop, and draws a static frame.
Known constraints#
- Requires WebGL; the component shows a fallback surface when the context cannot be created.
- The simulation is decorative and is skipped or simplified when reduced motion is requested.
- Keep the host sized by layout, because the canvas follows its container rather than driving height.
About Ink Flow#
Bring a high-end, gallery-grade editorial aesthetic to your interfaces.
Ink Flow recreates the slow, organic movement of fountain-pen ink dispersing through textured watercolor paper. Large pigment fields gently stretch, bleed, and fold into one another to create a constantly evolving generative backdrop.
Built with native WebGL, the effect remains GPU accelerated without relying on heavy rendering frameworks.
Controls#
- Flow Speed controls how quickly the ink evolves.
- Ink Scale controls the size and density of the fluid forms.
- Ink Saturation controls the strength of the pigment.
- Contrast controls separation between paper and ink tones.
Best For#
Editorial sites, portfolios, premium agency pages, luxury product experiences, and immersive typographic hero sections.
View source
Keep in mind
Need a custom component?
I build bespoke UI components & websites tailored to your brand.

