Charts · Gutenberg
Sankey Diagram block for WordPress
Flow diagram showing proportional transfers between stages. Great for budget allocation, user journeys, traffic sources, and energy/material flows.
Get Blockenberg
Free Gutenberg block in Blockenberg. The inspector controls and front-end behavior on this page come from this block’s source, not a shared stub.
What it actually does
Flow diagram showing proportional transfers between stages. Great for budget allocation, user journeys, traffic sources, and energy/material flows.
Inspector panels on this block: Chart Settings, Nodes, Flows (Links). Those titles come from index.js, not from a shared template.
Behavior controls: “From (source)” options: — Select —; “To (target)” options: — Select —.
Sankey Diagram has no render.php and no frontend.js. The saved Gutenberg HTML is what visitors see, plus Blockenberg layout/typography CSS.
Where to find it
Gutenberg inserter → Charts → search “Sankey Diagram” (block name `blockenberg/sankey-diagram` in block.json). Style it in the sidebar after insert.
How to use Sankey Diagram block for WordPress
- Install Blockenberg. Install from WordPress.org and activate the plugin.
- Insert the block. Edit a page, click +, search for “Sankey Diagram”, insert it. Category: Charts.
- Configure inspector controls that exist on this block. Open Chart Settings. Set “Chart Settings — Title”, “Show Title”, “Show Values”, “Canvas Width”.
- Publish. Save the page. Output is the saved block HTML; typography/colors follow Blockenberg shared panels.
Inspector controls from this block’s code
| Control | What the code does |
|---|---|
| Chart Settings — Title | Text field in the inspector. block.json default: Traffic Sources. Saved as `title`. |
| Show Title | On/off toggle in the inspector. On by default. Saved as `showTitle`. |
| Show Values | On/off toggle in the inspector. On by default. Saved as `showValues`. |
| Canvas Width | Numeric range control in the inspector. Range 300–1200. block.json default: 800. Saved as `svgWidth`. |
| Canvas Height | Numeric range control in the inspector. Range 200–900. block.json default: 440. Saved as `svgHeight`. |
| Node Width | Numeric range control in the inspector. Range 8–60. block.json default: 24. Saved as `nodeWidth`. |
| Node Padding | Numeric range control in the inspector. Range 4–60. block.json default: 20. Saved as `nodePad`. |
| Flow Opacity % | Numeric range control in the inspector. Range 5–95. block.json default: 40. Saved as `flowOpacity`. |
| Label Font Size | Numeric range control in the inspector. Range 8–22. block.json default: 13. Saved as `labelFontSize`. |
| Label Font Weight | Numeric range control in the inspector. Range 100–900. block.json default: 600. Saved as `labelFontWeight`. |
| Label Line Height | Numeric range control in the inspector. Range 1–3. block.json default: 1.4. Saved as `labelLineHeight`. |
| Value Font Size | Numeric range control in the inspector. Range 8–18. block.json default: 11. Saved as `valueFontSize`. |
| Value Font Weight | Numeric range control in the inspector. Range 100–900. block.json default: 400. Saved as `valueFontWeight`. |
| Value Line Height | Numeric range control in the inspector. Range 1–3. block.json default: 1.4. Saved as `valueLineHeight`. |
| Colors — Background | Color control in the inspector. block.json default: #ffffff. Saved as `bgColor`. |
| Title Color | Color control in the inspector. block.json default: #111827. Saved as `titleColor`. |
| Text Color | Color control in the inspector. block.json default: #374151. Saved as `textColor`. |
| ID (unique) | Text field in the inspector. |
| Label | Text field in the inspector. |
| From (source) | Select control; the chosen value is saved on the block. Options: — Select —. |
| To (target) | Select control; the chosen value is saved on the block. Options: — Select —. |
| Flow Value | Numeric range control in the inspector. Range 1–100000. |
When this is the right block
- Flow diagram showing proportional transfers between stages. Great for budget allocation, user journeys, traffic sources, and energy/material flows — that is the job of Sankey Diagram, not a generic content block.
- Use it when you need the editor control labeled “Chart Settings — Title”, which exists on this block’s inspector.
- It matches pages about sankey, flow, diagram.
- Inserter grouping: reports, dashboards, and data-heavy pages.
Notes from the implementation
Static block: markup is saved in post content; no PHP render callback in this folder.
FAQ
How do I add the Sankey Diagram block in WordPress?
Install Blockenberg from WordPress.org, edit a page in the block editor, click +, and search for “Sankey Diagram”. It sits under Charts. After insert, open Chart Settings and set “Chart Settings — Title”, “Show Title”, “Show Values”, “Canvas Width”.
What makes Sankey Diagram different from other Blockenberg blocks?
Flow diagram showing proportional transfers between stages. Great for budget allocation, user journeys, traffic sources, and energy/material flows. Inspector labels on this block include “Chart Settings — Title”, “Show Title”, “Show Values”, “Canvas Width”.
Is the Sankey Diagram Gutenberg block free?
Yes. Sankey Diagram ships inside Blockenberg. Get the plugin from WordPress.org — no paid add-on is required for this block.
Can I style Sankey Diagram to match my theme?
Yes. Blockenberg’s shared typography and color panels apply here, plus any block-specific style controls listed on this page (panels: Chart Settings, Nodes, Flows (Links)).
Related charts blocks
Chord Diagram
Circular diagram showing bidirectional relationships and flow volumes between groups. Great for migration patterns, trade flows, cross-referrals, and collaboration networks.
Waterfall Chart
Financial waterfall (bridge) chart showing cumulative effect of sequential positive and negative values. Perfect for P&L analysis, budget breakdowns, and cash flow visualization.
Creative Stats Waterfall
Staggered waterfall layout of large statistics with animated counters and accent colors.
Mind Map
Visual mind map diagram with a central topic, branches, and sub-items. Great for brainstorming, planning, and knowledge visualization.
Venn Diagram
SVG-based Venn diagram with two or three overlapping circles. Each circle and overlap region has customisable labels, colour, and list items. Perfect for comparing sets, audiences, or concepts.
Area Chart
Smooth filled area chart with multiple datasets, gradient fills, and animation using Chart.js (CDN). Great for showing trends over time.
Get Blockenberg
Install Blockenberg from WordPress.org, then insert Sankey Diagram from the Gutenberg inserter.