Skip to content

Extras

Chart

Bit.BlazorUI.ExtrasGraphPlot

BitChart renders native SVG computed in C# - no canvas or JavaScript engine - so it works in prerendering and static SSR. A Chart.js-like API (BitChartType + BitChartData + BitChartOptions, or one BitChartConfig) draws line, bar, area, pie, doughnut, polar area, radar, scatter, bubble, mixed and sparkline charts, styled by the bit theme and public --bit-Chart-* CSS variables, with keyboard and screen-reader support and SVG/PNG/CSV export.

Interaction

Hover and intersection modes, loading and empty states, and charts linked to each other.

Hover anywhere

With the default Interaction.Intersect = false, hovering anywhere over a category activates that index, so marker-less lines (PointRadius = 0) stay hoverable. Interaction.Crosshair and Interaction.CrosshairLabel toggle the crosshair and its axis chip.
Interactive chart. Use the left and right arrow keys to move through a series, the up and down arrow keys to move between series, Home and End for the first and last value, Enter to select, and Escape to leave.
Line chart with 2 data series.
SeriesJanFebMarAprMayJunJul
Requests120190160250220300280
Errors129201418118

Require an intersection

Interaction.Intersect = true makes only the element directly under the pointer react, so a dataset without visible markers has nothing to hover.
Interactive chart. Use the left and right arrow keys to move through a series, the up and down arrow keys to move between series, Home and End for the first and last value, Enter to select, and Escape to leave.
Line chart with 2 data series.
SeriesJanFebMarAprMayJunJul
Requests120190160250220300280
Errors129201418118

Interaction modes

Interaction.Mode picks which elements join the hovered one: Nearest just that one, Index every series at the same label, Dataset the whole series. Plugins.Tooltip.Mode overrides it for the tooltip.
Interactive chart. Use the left and right arrow keys to move through a series, the up and down arrow keys to move between series, Home and End for the first and last value, Enter to select, and Escape to leave.
Bar chart with 3 data series.
SeriesJanFebMarAprMayJunJul
Product A12191422182520
Product B811179141219
Product C5791281014

Loading and empty states

Loading veils the plot with a spinner and LoadingLabel (or your LoadingTemplate), marks the chart aria-busy and holds back the empty state. With nothing to draw, the chart shows EmptyText or your EmptyTemplate instead of bare axes.
Interactive chart. Use the left and right arrow keys to move through a series, the up and down arrow keys to move between series, Home and End for the first and last value, Enter to select, and Escape to leave.
Bar chart with 3 data series.
SeriesJanFebMarAprMayJunJul
Product A12191422182520
Product B811179141219
Product C5791281014

Linked charts

OnElementHover reports the active items whenever they change, and null when none are active - enough to link charts, as here, or drive a shared readout or table highlight.
Hover either chart
Interactive chart. Use the left and right arrow keys to move through a series, the up and down arrow keys to move between series, Home and End for the first and last value, Enter to select, and Escape to leave.
Bar chart with 3 data series.
SeriesJanFebMarAprMayJunJul
Product A12191422182520
Product B811179141219
Product C5791281014
Interactive chart. Use the left and right arrow keys to move through a series, the up and down arrow keys to move between series, Home and End for the first and last value, Enter to select, and Escape to leave.
Line chart with 2 data series.
SeriesJanFebMarAprMayJunJul
202565598081565572
202628484060869278

Feedback

Found a mistake, a gap, or something that could be clearer? Every page and every component is one click from its source.