Skip to content

Documentation / @ripl/charts / TreemapChartOptions

Interface: TreemapChartOptions<TData>

Defined in: charts/src/charts/treemap.ts:59

Options for configuring a TreemapChart.

Extends

Type Parameters

Type ParameterDefault type
TDataunknown

Properties

PropertyTypeDescriptionInherited fromDefined in
animation?boolean | Partial<ChartAnimationOptions>Animation configuration, or a boolean toggling all transitions. See ChartAnimationOptions.BaseChartOptions.animationcharts/src/core/chart.ts:89
autoRender?booleanWhether the chart renders automatically on construction and after every Chart.update. Defaults to true.BaseChartOptions.autoRendercharts/src/core/chart.ts:83
borderRadius?numberCorner radius in pixels applied to each cell. Defaults to 4.-charts/src/charts/treemap.ts:73
color?keyof TData | ((item) => string)Optional accessor for a per-item colour override (otherwise a palette colour is generated).-charts/src/charts/treemap.ts:69
dataTData[]The dataset to render, one cell per item.-charts/src/charts/treemap.ts:61
format?ValueFormatInputFormat applied to cell values shown as text (e.g. tooltips).-charts/src/charts/treemap.ts:75
gap?numberGap in pixels between adjacent cells. Defaults to 3.-charts/src/charts/treemap.ts:71
keykeyof TData | ((item) => string)Accessor for each item's unique key, used to match cells across data updates.-charts/src/charts/treemap.ts:63
labelkeyof TData | ((item) => string)Accessor for each item's display label (shown inside sufficiently large cells).-charts/src/charts/treemap.ts:67
padding?Partial<ChartPadding>Space reserved around the chart, per edge, in pixels.BaseChartOptions.paddingcharts/src/core/chart.ts:85
title?string | Partial<ChartTitleOptions>Chart title as plain text, or a ChartTitleOptions object for full control.BaseChartOptions.titlecharts/src/core/chart.ts:87
valueNumericAccessor<TData>Accessor for each item's numeric value, which determines its cell area.-charts/src/charts/treemap.ts:65