component

TuxTreemap

Squarified hierarchical-size visualization. Landscape's headline viz — replaces diskover's D3 v3 treemap. Self-contained SVG (no external viz library), implements the Bruls-Huijsen-van Wijk squarified algorithm so cells stay near-square at every level, which is what makes large hierarchies readable. Click a cell to drill in; breadcrumb to zoom out.

canonical

Filesystem · 2-deep

Hover a cell for path + size + child count. Click any aggregate with children to drill in. Maroon ramp colors by size (log-scaled, because file-size distributions are heavy-tailed).

movementlabraw-corridor-feeds7.8 GBprocessed2.0 GBexportsgrantsnsf-12343.9 GBtxdot-781.7 GBfhwa-2024906 MBpublications20251.3 GB20241.0 GB2023839 MBfield-photossite-07site-09code
<TuxTreemap :data="data" :max-depth="2" color-by="size" />

depth coloring

Color by depth instead of size

Pass color-by="depth" when the visual story is about hierarchy levels rather than absolute size. Useful for showing nested folder structure where every level matters equally.

movementlabraw-corridor-feeds7.8 GBprocessed2.0 GBexportsgrantsnsf-12343.9 GBtxdot-781.7 GBfhwa-2024906 MBpublications20251.3 GB20241.0 GB2023839 MBfield-photossite-07site-09code

single-level

Flat treemap (max-depth=1)

Pass :max-depth="1" for a flat one-level treemap — useful for top-level overviews where you don't want the eye distracted by sub-hierarchies.

movementlab10 GBgrants6.8 GBpublications3.4 GBfield-photos811 MBcode

props

Props + data shape

  • data — recursive { name, size?, children? }. Required.
  • maxDepth — render depth before showing aggregate cells. Defaults to 2.
  • colorBy"size" | "depth". Defaults to "size".
  • unit"bytes" | "count" | "percent". Sets the size formatter.
  • width + height — SVG viewBox dimensions (component renders responsive).

algorithm

Why squarified

Naive treemaps (slice-and-dice) produce strip-shaped cells that get unreadable as the dataset grows. The squarified algorithm (Bruls et al., 1999) chooses each row's contents to minimize the worst aspect ratio — the result is cells that stay near-square, which keeps labels readable and area perception accurate. This is the algorithm D3, ECharts, and Tableau all use. We implement it directly in ~80 lines of Vue so we don't take a viz-library dependency just for this one chart.