@kanunilabs/datagrid-react-enterprise
@kanunilabs/datagrid-react-enterprise / GridChartPanelProps
Interface: GridChartPanelProps<TRow>
Type Parameters
TRow
TRow = GridRowData
Properties
columns
columns:
object[]
Columns offered in the pickers, in grid order.
enumerated marks a column that draws from a bounded set (it has a
lookup) — the only reliable signal, without counting a million rows, that
a column makes a sensible category. isKey marks the row key.
enumerated?
optionalenumerated?:boolean
id
id:
string
isKey?
optionalisKey?:boolean
label
label:
string
numeric
numeric:
boolean
temporal?
optionaltemporal?:boolean
A date column — offered calendar grouping, and bucketed by default.
controller
controller:
DataGridController<TRow> |null
crossFilter?
optionalcrossFilter?:boolean
Clicking a category filters the grid by it. Off by default — see §13.
height?
optionalheight?:number
Fixed canvas height in px. Omit to fill the panel.
Filling relies on recharts' ResizeObserver, which never fires for an
element that is display: none — so a chart inside a collapsed accordion
or an inactive tab stays blank until it is shown. A fixed height sidesteps
the observer and draws immediately.
initialSpec?
optionalinitialSpec?:Partial<ChartSpec<TRow>>
initialType?
optionalinitialType?:string
Chart type to open on — a registered renderer's id. Defaults to column.
Separate from initialSpec because the type is a RENDERING choice, not
part of the (serializable, worker-bound) chart definition; the panel's own
picker changes it afterwards either way. The cell menu's chart submenu
uses this to open straight into the type the user picked.
labels?
optionallabels?:Partial<GridChartPanelLabels>
locale?
optionallocale?:string
onSpecChange?
optionalonSpecChange?: (spec) =>void
Parameters
spec
ChartSpec<TRow>
Returns
void
Methods
onClose()
onClose():
void
Returns
void