View as Markdown

API reference: @salmonui/charts/tree-map

TreeMapIteminterface

import type { TreeMapItem } from '@salmonui/charts/tree-map';
interface TreeMapItem {
    readonly path: TreeMapPath;
    readonly label: string;
    readonly value: number;
    readonly depth: number;
    readonly leaf: boolean;
    readonly datum: unknown;
    readonly color: string;
}
TreeMapItem members (7)
NameSignatureDescription
pathreadonly path: TreeMapPath;
labelreadonly label: string;
valuereadonly value: number;
depthreadonly depth: number;

Depth below the root (1 = top level).

leafreadonly leaf: boolean;
datumreadonly datum: unknown;

The record for leaves and hierarchical groups; null for groups built by levels.

colorreadonly color: string;