OptionalidUnique identifier for the chart. Used as the MAIDR id.
OptionaltitleChart title displayed in text descriptions.
OptionalsubtitleChart subtitle.
OptionalcaptionChart caption.
OptionalformatOptional formatting configuration applied to axes that do not specify
their own format. Per-axis format on AxisConfig takes precedence.
OptionalautoWhen true (the default), the binder writes the generated MAIDR schema
to the SVG as a maidr-data attribute so vanilla-JS users don't need
to call svg.setAttribute(...) themselves. The returned result is
unchanged either way.
Set to false if you are driving MAIDR yourself — e.g. passing the
returned schema to <Maidr data={...}> or persisting it elsewhere.
The React adapter (useD3Adapter, MaidrD3) forces this
to false internally so it can stay in control of the schema.
CSS selector for the wedge elements (e.g., 'path.slice', 'path.arc').
OptionalxAccessor for the slice label.
OptionalyAccessor for the slice magnitude. Defaults to the value d3.pie() itself
computed for the slice, which is what the drawn angle is proportional to;
supply this only for a pie drawn without the layout.
OptionalaxesAxis labels. A pie has no fill axis: the share of the whole is derived from the values themselves, so there is nothing for a third axis to name.
Optionalx?: D3AxisInputWhat the slice labels mean, e.g. 'Fruit'.
Optionaly?: D3AxisInputWhat the slice values measure, e.g. 'Units'.
Configuration for binding a D3 pie or doughnut chart.
The canonical D3 pie is
d3.pie()+d3.arc()drawn as one<path>per slice, soselectorshould match those paths. Both accessors are read against YOUR datum, not the arc the layout wraps it in — the binder unwraps the arc first.Example