syncfusion/blazor-ui-components-skills / skills/syncfusion-blazor-accumulation-chart
syncfusion-blazor-accumulation-chart
VerifiedImplement Syncfusion Blazor Accumulation Chart (SfAccumulationChart) for proportional data visualization. Use this when creating pie charts, doughnut charts, funnel charts, or pyramid charts. This skill covers data labels, legends, tooltips, slice grouping, and part-to-whole visualizations in Blazor applications.
| File | Kind | Size |
|---|---|---|
| SKILL.md | skill md | 19.1 KB |
| references/accessibility-printing.md | markdown | 14.1 KB |
| references/animation-events.md | markdown | 14.5 KB |
| references/api-reference.md | markdown | 6.3 KB |
| references/center-label.md | markdown | 17.4 KB |
| references/chart-types.md | markdown | 23.7 KB |
| references/customization-styling.md | markdown | 13.2 KB |
| references/data-label.md | markdown | 25.6 KB |
| references/getting-started.md | markdown | 15.1 KB |
| references/legend.md | markdown | 21.7 KB |
| references/multiple-doughnut.md | markdown | 18.7 KB |
| references/tooltip.md | markdown | 16.5 KB |
references/api-reference.md
View on GitHub---
title: Accumulation Chart API Reference
summary: Reference for enums, public methods, and critical usage notes for `SfAccumulationChart` and related types.
---
# Accumulation Chart API Reference
This document provides a concise reference for the public API surface of the Syncfusion Blazor `SfAccumulationChart` and commonly used related types. It covers enum values, public methods, important usage notes, and quick code examples.
## Common Enums
- `AccumulationType`
- `Pie`
- `Funnel`
- `Pyramid`
- `AccumulationLabelPosition` (aka `AccumulationDataLabelSettings.Position`)
- `Inside`
- `Outside`
- `GroupMode`
- `Value` (group by value threshold)
- `Point` (group by point count)
- `LegendPosition`
- `Top`
- `Bottom`
- `Left`
- `Right`
- `ExportType`
- `PNG`
- `JPEG`
- `SVG`
- `PDF`
Notes: When specifying enum values in markup, use fully-qualified names if necessary (for example `Syncfusion.Blazor.Charts.AccumulationType.Pie`) in contexts where the namespace is ambiguous.
## Key Component Properties (summary)
- `AccumulationChartSeries.Type` (AccumulationType) — Pie, Funnel, Pyramid.
- `AccumulationChartSeries.InnerRadius` (string) — Inner radius for doughnut charts (e.g. "40%").
- `AccumulationChartSeries.Radius` (string) — Overall slice radius (e.g. "80%").
- `AccumulationChartSeries.GroupTo` (int or double) — Value or point count threshold used with `GroupMode`.
- `AccumulationChartSeries.GroupMode` (GroupMode) — `Value` or `Point`.
- `AccumulationDataLabelSettings.Visible` (bool) — Show/hide data labels.
- `AccumulationChartLegendSettings.Visible` (bool) — Show/hide legend.
- `AccumulationChartTooltipSettings.Enable` (bool) — Enable/disable tooltips.
## Theme Enum
The `SfAccumulationChart` component supports the `Theme` property which uses the `Syncfusion.Blazor.Theme` enum.
**IMPORTANT:** The enum name is `Theme`, NOT `AccumulationChartTheme`. Use it as `Theme="Syncfusion.Blazor.Theme.Material"` or `Theme="Theme.Material"` (with proper using directive).
```csharp
public enum Theme
{
Material,
Fabric,
Bootstrap,
Bootstrap4,
HighContrastLight,
MaterialDark,
FabricDark,
BootstrapDark,
Bootstrap4Dark,
HighContrast,
Tailwind,
TailwindDark,
Bootstrap5,
Bootstrap5Dark,
Fluent,
FluentDark,
Material3,
Material3Dark
}
```
**Usage Example:**
```razor
<SfAccumulationChart Title="Sales Distribution" Theme="Syncfusion.Blazor.Theme.Bootstrap5">
<!-- chart content -->
</SfAccumulationChart>
```
## Public Methods
The `SfAccumulationChart` component exposes a small set of useful public methods. Typical usage calls these from code-behind or event handlers.
- `Task ExportAsync(ExportType type, string fileName, PdfPageOrientation? orientation = null, bool allowDownload = true)`
- Exports the chart to the requested format. For `PDF`, `orientation` may be specified.
- Example: `await chart.ExportAsync(ExportType.PNG, "chart.png");`
- `Task PrintAsync()`
- Invokes the browser print dialog for the chart display area.
- Example: `await chart.PrintAsync();`
- `void Refresh(bool shouldAnimate = true)`
- Refreshes/redraws the chart. Pass `false` to skip animation.
- Example: `chart.Refresh(false);`
- `Task SetAnnotationValueAsync(double annotationIndex, string content)`
- Updates the content of an annotation at runtime.
- Example: `await chart.SetAnnotationValueAsync(0, "Updated content");`
Notes: The component instance (for calling instance methods) is usually obtained by assigning `@ref` to the `SfAccumulationChart` in Razor markup.
## Critical Usage Notes and Gotchas
- Center labels apply only to Doughnut charts: `AccumulationChartCenterLabel` content is meaningful when `InnerRadius` is set (doughnut). Using center-label markup for non-doughnut series will have no effect.
- `GroupTo` semantics depend on `GroupMode`: when `GroupMode` is `Value`, `GroupTo` is treated as the numeric threshold to group smaller values into "Others"; when `Point`, it defines the point count to group.
- Data label `Position` must be set using the enum (e.g. `Syncfusion.Blazor.Charts.AccumulationLabelPosition.Outside`) if the context doesn't include the `Syncfusion.Blazor.Charts` namespace.
- Legend visibility toggling (`ToggleVisibility`) and click behavior are controlled by legend settings; ensure `ToggleVisibility` is enabled when you expect legend-item clicks to hide/show points.
- Exporting large charts or complex templates may increase memory usage in the browser; prefer vector formats (SVG/PDF) when high fidelity is required.
## Common Patterns and Examples
Basic pie chart
```razor
<SfAccumulationChart @ref="chart" Title="Sales">
<AccumulationChartSeriesCollection>
<AccumulationChartSeries DataSource="@SalesData" XName="Product" YName="Sales">
<AccumulationDataLabelSettings Visible="true"/>
</AccumulationChartSeries>
</AccumulationChartSeriesCollection>
<AccumulationChartLegendSettings Visible="true"/>
</SfAccumulationChart>
@code {
SfAccumulationChart chart;
List<object> SalesData = new List<object> { /* ... */ };
}
```
Doughnut with center label and export
```razor
<AccumulationChartSeries Type="Syncfusion.Blazor.Charts.AccumulationType.Pie" InnerRadius="40%" DataSource="@Data" XName="Category" YName="Value">
<AccumulationDataLabelSettings Visible="true" Position="Syncfusion.Blazor.Charts.AccumulationLabelPosition.Outside" />
<AccumulationChartCenterLabel Text="Total<br/>$1.2M" />
</AccumulationChartSeries>
@code {
SfAccumulationChart chartRef;
async Task ExportPng() {
await chartRef.ExportAsync(ExportType.PNG, "doughnut.png");
}
}
```
Grouping small slices
```razor
<AccumulationChartSeries GroupTo="5" GroupMode="Syncfusion.Blazor.Charts.GroupMode.Value" />
```
Zoom/interaction note: Accumulation charts are non-cartesian; pinch/zoom interactions available for Cartesian charts are not applicable to accumulation charts. Use selection, explosion, and tooltip settings for interactivity instead.
## Troubleshooting
- If labels overlap badly, enable smart labels (`AccumulationDataLabelSettings` with smart positioning) or move labels outside using `Position=Outside`.
- If center label does not appear, verify `Type=Pie` and `InnerRadius` is a non-empty percentage.
- If a fully-qualified enum compiles error, add `@using Syncfusion.Blazor.Charts` to your Razor file or use the full type name.
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| reverse-engineer-anythingmorluto/reaReverse engineer native, managed, Electron/JavaScript, packaged, firmware, and browser targets with REA, and build agent environments (AgentEnv bundles) of web applications from a live instance or a capture, and of Linux desktop apps with a task from a request. Use shipped-artifact or requested runtime evidence to explain features, compare versions, decompile code, or guide a reconstruction. Skip REA for ordinary source-repository architecture analysis. | Stars: 469k | Updated | Claude CodeCodex | Verified | Install |
| diagnosing-superpowersobra/superpowersUse when a superpowers session went wrong and your human partner wants to know why — repeated work, ignored plans, stumbles, poor results, a skill that didn't fire, "it took too long", "why is it so expensive", "what is it doing" — or wants to build a bug report for the superpowers maintainers, for the current session or a past one identified by id or path, on any harness. | Stars: 321k | Updated | Claude CodeCodex | Verified | Install |
| dispatching-parallel-agentsobra/superpowersUse when facing 2+ independent tasks that can be worked on without shared state or sequential dependencies | Stars: 321k | Updated | Claude CodeCodex | Verified | Install |
| executing-plansobra/superpowersUse when executing an implementation plan in the current session as the implementer yourself — your human partner chose inline execution, or no subagent tool is available | Stars: 321k | Updated | Claude CodeCodex | Verified | Install |