---
id: "packages/active-charts/all-exports/chart-defaults"
title: "ChartDefaults"
description: "ChartDefaults, ChartDefaultsProps, ChartDefaultsValue: generated from the source of active-charts."
url: "/packages/active-charts/all-exports/chart-defaults"
locale: "en"
revision: "g0mvjxwj5c-88bdbe1c:chart-defaults"
---

# ChartDefaults

Exported by `@workspace/active-charts`. Generated from the package source; part of [the index of every export](/packages/active-charts/all-exports).

## `ChartDefaults`

| Prop | Type | Required | Description |
| --- | --- | --- | --- |
| `children` | `ReactNode` | yes |  |
| `accessibility` | `AccessibilityOptions` | no |  |
| `animation` | `FeatureOption<AnimationOptions>` | no |  |
| `contextMenu` | `FeatureOption<Omit<ChartContextMenuOptions<unknown, keyof ChartContextMenuFeatures>, "items">>` | no | Cross-chart context-menu defaults: `enabled`, `features`, `pngScale` and `trigger`. No `items`: a provider does not know the element type of the charts below it, so the host's items are per chart. |
| `diagnostics` | `ChartDiagnosticSink` | no | Where every chart below delivers its diagnostics (input a chart cannot draw, options without effect, a failed menu export). Replaced whole by a nearer provider. Without one, warnings and errors go to the console and debug notices are dropped. |
| `exportFonts` | `ChartExportFonts` | no | The host's export fonts for every chart below: the PNG, SVG and PDF exports of the handle and of the context menu use them. An explicit `fonts` on an export call wins; `fonts: 'inherit'` skips this set for one call. A nested provider replaces the set as a whole. Live rendering never reads it. |
| `locale` | `ValuePresentation` | no |  |
| `t` | `ChartTranslateFn` | no |  |
| `tooltip` | `FeatureOption<TooltipOptions>` | no |  |

## Types

**ChartDefaultsProps**

```ts
interface ChartDefaultsProps extends ChartDefaultsValue {
  children: ReactNode;
}
```

**ChartDefaultsValue**

```ts
interface ChartDefaultsValue {
  locale?: ChartPresentation;
  t?: ChartTranslateFn;
  accessibility?: AccessibilityOptions;
  tooltip?: FeatureOption<TooltipOptions>;
  contextMenu?: FeatureOption<Omit<ChartContextMenuOptions, 'items'>>;
  animation?: FeatureOption<AnimationOptions>;
  exportFonts?: ChartExportFonts;
  diagnostics?: ChartDiagnosticSink;
}
```

App-wide default values for every chart rendered below this provider.

Any prop set on an individual chart takes precedence — this context only
fills in values the consumer left unset. All fields are optional, with two
ownership rules: `locale` is the presentation and `t` the translator of every
chart below, and a chart with neither the prop nor the `ChartDefaults` value
throws a configuration error (there is no `'en'` fallback, active-format D14,
and no English copy, ADR-028).

It carries no visual configuration: the palette, surfaces and text come
from the host's CSS tokens, never from this provider.
