Unique identifier for the chart (used for DOM IDs).
OptionaltitleChart title displayed in text descriptions.
OptionalsubtitleChart subtitle.
OptionalcaptionChart caption.
OptionaldataRecharts data array. Each item is one data point with named fields.
Required in simple/composed mode. In subplot mode it acts as the
default data for panels that do not provide their own data, and may
be omitted when every panel does.
OptionalchartChart type for simple mode (single chart type with one or more series).
Mutually exclusive with layers.
Key in data objects for x-axis values.
OptionalyKeys in data objects for y-axis values (simple mode).
Each key creates a separate data series.
Mutually exclusive with layers.
OptionallayersLayer configurations for composed charts (composed mode).
Each layer defines a chart type and data key.
Mutually exclusive with chartType/yKeys.
OptionalsubplotsPanel configurations for multi-panel (faceted) figures (subplot mode).
Mutually exclusive with the top-level chartType and layers.
A 2D array describes the panel grid directly in row-major visual
reading order (subplots[0][0] is the top-left panel). A flat array
is chunked into rows of columns panels (one single row when
columns is omitted). Rows may be ragged but never empty.
When rendering through <MaidrRecharts>, pass one Recharts chart per
panel as children in the same row-major order — each child is wrapped
in a generated .maidr-panel-<row>-<col> div used for per-panel
highlight scoping. See RechartsSubplotConfig.panelSelector for
the custom-DOM escape hatch.
OptionalcolumnsNumber of panels per row when subplots is a flat array.
Ignored when subplots is already a 2D grid.
OptionalxX-axis label.
OptionalyY-axis label.
OptionalorientationBar/box chart orientation. Defaults to vertical.
OptionalfillDisplay names for each series in stacked/dodged/normalized bar charts.
Maps 1:1 with yKeys — the i-th fillKey names the i-th yKey.
When omitted, the yKey strings are used as fill labels.
OptionalbinHistogram bin range configuration.
Required when chartType is 'histogram'.
OptionalselectorCustom CSS selector override for SVG highlighting.
By default the adapter generates selectors from Recharts' built-in class names. For multi-series charts, CSS selectors cannot reliably distinguish between series, so highlighting is disabled.
To enable highlighting for multi-series charts, add a custom
className to each Recharts component and pass the selector here:
Configuration for the Recharts-to-MAIDR adapter.
Supports three configuration modes:
chartTypeandyKeysfor a single chart type with one or more data series.layersfor mixed chart types (e.g., bar + line).subplotsfor multi-panel (faceted) figures made of a grid of Recharts charts.Example: Simple bar chart
Example: Stacked bar chart
Example: Histogram
Example: Composed chart (bar + line)
Example: Multi-panel (faceted) figure — 1x2 grid of bar charts