Sankey
Flows between columns of thin bone bars, carried by ribbons that run as gradients from the source's grey to the target's.
$149 once · every Pro piece
Nodes fade in column by column, then the ribbons grow from source to target on the shared reveal curve. Point at a node or a ribbon, or walk them with the arrow keys, and every path through it heats end to end while unrelated ribbons drop to a tenth and unrelated nodes step back; % pills appear on the ribbons it touches and the readout rolls to its value and share. Options: flat ribbons, pills always on the wide ribbons, a node lit at rest, column captions, loading and empty states. The layout is relaxed in the component itself, and new data morphs into place on springs.
Install
npx shadcn@latest add @obsyde/sankeyNeeds your licence key · Get Pro
Usage
Import it from where the CLI puts it, or copy the files below by hand.
import { Sankey } from '@/components/obsyde/ember/sankey/Sankey';
export function Example() {
return (
<Sankey />
);
}
Files
What you get with Pro: plain React, TypeScript and CSS, with no dependencies.
ember/sankey/Sankey.tsxcomponentember/sankey/sankey.cssstylesember/sankey/SankeyDemo.tsxdemoember/viz-kit/viz-kit.csssharedember/viz-kit/size.tssharedember/viz-kit/scale.tssharedember/viz-kit/patterns.tsxsharedember/viz-kit/motion.tssharedember/shared/spring.tssharedember/shared/accent.tssharedember/viz-kit/demo.tsxsharedember/viz-kit/demo.csssharedember/shared/RollingNumber.tsxsharedember/shared/rolling-number.csssharedember/shared/ember.csssharedember/viz-kit/touch.tsshared
API
| Prop | Type | Default |
|---|---|---|
accentAccent | 'ember' | 'volt' | 'arc' | 'ember' |
focusFocus | 'none' | 'alpha' | 'beta' | 'gamma' | 'delta' | 'stage-i' | 'stage-ii' | 'stage-iii' | 'out-a' | 'out-b' | 'out-c' | 'out-d' | 'none' |
ribbonsRibbons | 'gradient' | 'solid' | 'gradient' |
pillsPills | 'hover' | 'always' | 'none' | 'hover' |
captionsColumn captions | boolean | true |
heightHeight | number | 320 |
statusStatus | 'ready' | 'loading' | 'empty' | 'ready' |
seedSeed | number | 5 |