Skip to main content
Urbicon UI
source

Sankey

Playground

Source ASource BPotSink XSink Y
Sankey diagram: 5 nodes, 4 links — Source A → Pot: 60; Source B → Pot: 40; Pot → Sink X: 70; Pot → Sink Y: 30
SourceTargetValue
Source APot60
Source BPot40
PotSink X70
PotSink Y30
Loading...
Loading syntax highlighting...

01 Examples

5-Stage Heating Cost Flow

Complete service-charge example: sources (gas, heat pump, maintenance, chimney sweep) → heating cost pot → heating/hot water → residential units.
Gas billHeat pump electricityMaintenanceChimney sweepHeating cost potHeatingHot waterUnit 4Unit 4A
Sankey diagram: 9 nodes, 10 links — Gas bill → Heating cost pot: 2.206,09 €; Heat pump electricity → Heating cost pot: 1.127,31 €; Maintenance → Heating cost pot: 361,02 €; Chimney sweep → Heating cost pot: 128,00 €; Heating cost pot → Heating: 3.105,03 €; Heating cost pot → Hot water: 717,39 €; Heating → Unit 4: 1.855,47 €; Heating → Unit 4A: 1.249,56 €; Hot water → Unit 4: 394,77 €; Hot water → Unit 4A: 322,62 €
SourceTargetValue
Gas billHeating cost pot2.206,09 €
Heat pump electricityHeating cost pot1.127,31 €
MaintenanceHeating cost pot361,02 €
Chimney sweepHeating cost pot128,00 €
Heating cost potHeating3.105,03 €
Heating cost potHot water717,39 €
HeatingUnit 41.855,47 €
HeatingUnit 4A1.249,56 €
Hot waterUnit 4394,77 €
Hot waterUnit 4A322,62 €
Loading...
Loading syntax highlighting...

Salary Breakdown

Gross salary → income tax / social contributions / net pay. Social contributions branch further into health, pension, unemployment, and care insurance.
Gross salaryIncome taxSocial contributionsHealth insurancePension insuranceUnemployment ins.Long-term careNet pay
Sankey diagram: 8 nodes, 7 links — Gross salary → Income tax: 850 €; Gross salary → Social contributions: 1.080 €; Social contributions → Health insurance: 360 €; Social contributions → Pension insurance: 480 €; Social contributions → Unemployment ins.: 90 €; Social contributions → Long-term care: 150 €; Gross salary → Net pay: 2.570 €
SourceTargetValue
Gross salaryIncome tax850 €
Gross salarySocial contributions1.080 €
Social contributionsHealth insurance360 €
Social contributionsPension insurance480 €
Social contributionsUnemployment ins.90 €
Social contributionsLong-term care150 €
Gross salaryNet pay2.570 €
Loading...
Loading syntax highlighting...

Node Alignments

Four layer alignments. The early sink (B) lands in different positions depending on alignment — justify pushes it all the way right, left keeps it at its source layer.

justify

SourceMidAB (early sink)
Sankey diagram: 4 nodes, 3 links — Source → Mid: 60; Mid → A: 60; Source → B (early sink): 30
SourceTargetValue
SourceMid60
MidA60
SourceB (early sink)30

left

SourceMidAB (early sink)
Sankey diagram: 4 nodes, 3 links — Source → Mid: 60; Mid → A: 60; Source → B (early sink): 30
SourceTargetValue
SourceMid60
MidA60
SourceB (early sink)30

right

SourceMidAB (early sink)
Sankey diagram: 4 nodes, 3 links — Source → Mid: 60; Mid → A: 60; Source → B (early sink): 30
SourceTargetValue
SourceMid60
MidA60
SourceB (early sink)30

center

SourceMidAB (early sink)
Sankey diagram: 4 nodes, 3 links — Source → Mid: 60; Mid → A: 60; Source → B (early sink): 30
SourceTargetValue
SourceMid60
MidA60
SourceB (early sink)30
Loading...
Loading syntax highlighting...

Compact Embedding

A small height embedded in a card — the layout adapts automatically.

Cashflow Overview

Q1 2026

SourceTarget
Sankey diagram: 2 nodes, 1 links — Source → Target: 100 %
SourceTargetValue
SourceTarget100 %
Loading...
Loading syntax highlighting...

02 Customization

Custom Tooltip

Custom tooltip content with a conditionally formatted detail field.
Gas billHeat pump electricityMaintenanceChimney sweepHeating cost potHeatingHot waterUnit 4Unit 4A
Sankey diagram: 9 nodes, 10 links — Gas bill → Heating cost pot: 2.206,09 €; Heat pump electricity → Heating cost pot: 1.127,31 €; Maintenance → Heating cost pot: 361,02 €; Chimney sweep → Heating cost pot: 128,00 €; Heating cost pot → Heating: 3.105,03 €; Heating cost pot → Hot water: 717,39 €; Heating → Unit 4: 1.855,47 €; Heating → Unit 4A: 1.249,56 €; Hot water → Unit 4: 394,77 €; Hot water → Unit 4A: 322,62 €
SourceTargetValue
Gas billHeating cost pot2.206,09 €
Heat pump electricityHeating cost pot1.127,31 €
MaintenanceHeating cost pot361,02 €
Chimney sweepHeating cost pot128,00 €
Heating cost potHeating3.105,03 €
Heating cost potHot water717,39 €
HeatingUnit 41.855,47 €
HeatingUnit 4A1.249,56 €
Hot waterUnit 4394,77 €
Hot waterUnit 4A322,62 €
Loading...
Loading syntax highlighting...

03 Accessibility

SVG with role="img"

The SVG has role="img" with an aria-label that lists every connection ("Source → Target: value"). A screen reader announces the diagram in a single block.

Table Fallback

An sr-only table (source / target / value) is rendered in addition — screen readers that prefer tables can query the data row by row.

Keyboard Navigation

Tab focuses every node and link in sequence. On a focused element, Enter/Space triggers the click handler (onNodeClick / onLinkClick).

Hover + Focus Highlight

Hovering or focusing a node dims all unconnected paths and nodes and highlights its direct connections.

04 API Reference

27 props
27 props 2 required

No matching properties

No matching properties

05 Installation

Import

Loading...
Loading syntax highlighting...