Skip to main content
100%

Collapsible Tree Example

✓ Published0🌍 Public
CCoola85
Last edited Jul 4, 2018
Created on Jul 4, 2018

This example shows a collapsible tree diagram where nodes are displayed as SVG images and connected by curved links, with node labels and link strokes colored by data attributes. The visualization presents hierarchical data from a static JavaScript array, using D3 v3’s `d3.layout.tree` to compute the layout and `d3.svg.diagonal` to draw the links. Node icons are loaded from external SVG files (`rect.svg`, `rect2.svg`) via `xlink:href`, and link colors reflect each target’s `level` property. The code defines nodes with `image` elements and text labels, while the tree structure and styles are set in the HTML and CSS.

AI-generated description

This is an example of using SVG as tree map nodes

mit Licensed

Similar vizzes