fix(chart): pass series index to data-table keys (#1150)

This commit is contained in:
FredApps
2026-11-07 17:27:25 +01:00
parent 505cae34c8
commit 6b19e445f4
3 changed files with 32 additions and 2 deletions
+1 -1
View File
@@ -70,7 +70,7 @@ pub(super) fn draw(ctx: &mut Ctx, chart: &Chart, data: &ChartData, plot: Bx, lay
let y = top + (layout.headers as f32 + i as f32 + 0.5) * layout.row_height;
let name_x = if settings.show_keys { x0 + 25.0 } else { x0 + 4.0 };
if settings.show_keys {
let swatch = match plot_kind(chart, series) {
let swatch = match plot_kind(chart, series, i) {
ChartKind::Line | ChartKind::LineStacked => Swatch::Line,
ChartKind::LineMarkers => Swatch::LineMarker,
_ => Swatch::Box,