mirror of
https://github.com/apache/superset.git
synced 2026-07-26 16:42:32 +00:00
When Query A (or B) on a Mixed Chart has multiple metrics plus at least one Group By dimension, the display-name builder in transformProps.ts always prepended metrics[0]'s label: the entryName.includes(metricPart) guard is false for every series belonging to metrics[1+], so those series were renamed to e.g. 'score_one, score_two, A' instead of 'score_two, A' — the 'first metric duplicated in legend/tooltip' symptom reported in #37921 (residual follow-up to #37055). Derive each series' metric from its label_map tuple ([metric, ...dimensions]) instead, matching what the per-series formatter lookup already does. Single-element tuples (no metric part) fall back to the first metric, preserving existing behavior for single-metric charts and showQueryIdentifiers naming. Applied to both the Query A and Query B paths. Includes the regression test originally landed red on this branch, verified red on master without the fix and green with it. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@superset-ui/plugin-chart-echarts
This plugin provides Echarts viz plugins for Superset:
- Timeseries Chart (combined line, area bar with support for predictive analytics)
- Pie Chart
Usage
Configure key, which can be any string, and register the plugin. This key will be used to
lookup this chart throughout the app.
import {
EchartsTimeseriesChartPlugin,
EchartsPieChartPlugin,
} from '@superset-ui/plugin-chart-echarts';
new EchartsTimeseriesChartPlugin().configure({ key: 'echarts-ts' }).register();
new EchartsPieChartPlugin().configure({ key: 'pie' }).register();
Then use it via SuperChart. See
storybook
for more details.
<SuperChart
chartType="echarts-ts"
width={600}
height={600}
formData={...}
queriesData={[{
data: {...},
}]}
/>