mirror of
https://github.com/apache/superset.git
synced 2026-04-23 18:14:56 +00:00
fix: Total calculation in stacked Timeseries charts (#24477)
This commit is contained in:
committed by
GitHub
parent
51a34d7d58
commit
c5b4ecdca5
@@ -29,7 +29,7 @@ import {
|
||||
import { EchartsMixedTimeseriesChartTransformedProps } from './types';
|
||||
import Echart from '../components/Echart';
|
||||
import { EventHandlers } from '../types';
|
||||
import { currentSeries, formatSeriesName } from '../utils/series';
|
||||
import { formatSeriesName } from '../utils/series';
|
||||
|
||||
export default function EchartsMixedTimeseries({
|
||||
height,
|
||||
@@ -123,12 +123,6 @@ export default function EchartsMixedTimeseries({
|
||||
const { seriesName, seriesIndex } = props;
|
||||
handleChange(seriesName, seriesIndex);
|
||||
},
|
||||
mouseout: () => {
|
||||
currentSeries.name = '';
|
||||
},
|
||||
mouseover: params => {
|
||||
currentSeries.name = params.seriesName;
|
||||
},
|
||||
contextmenu: async eventParams => {
|
||||
if (onContextMenu) {
|
||||
eventParams.event.stop();
|
||||
|
||||
@@ -51,7 +51,6 @@ import {
|
||||
import { parseYAxisBound } from '../utils/controls';
|
||||
import {
|
||||
getOverMaxHiddenFormatter,
|
||||
currentSeries,
|
||||
dedupSeries,
|
||||
extractSeries,
|
||||
getAxisType,
|
||||
@@ -481,11 +480,7 @@ export default function transformProps(
|
||||
seriesName: key,
|
||||
formatter: primarySeries.has(key) ? formatter : formatterSecondary,
|
||||
});
|
||||
if (currentSeries.name === key) {
|
||||
rows.push(`<span style="font-weight: 700">${content}</span>`);
|
||||
} else {
|
||||
rows.push(`<span style="opacity: 0.7">${content}</span>`);
|
||||
}
|
||||
rows.push(`<span style="opacity: 0.7">${content}</span>`);
|
||||
});
|
||||
return rows.join('<br />');
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user