mirror of
https://github.com/grafana/grafana.git
synced 2024-11-25 02:10:45 -06:00
BarChart: Fix legend and tooltip colors off by 1 after data refresh (#39234)
This commit is contained in:
parent
2a4b08eab9
commit
fb091de2c7
@ -246,10 +246,16 @@ export function prepareGraphableFrames(
|
||||
};
|
||||
}
|
||||
|
||||
let seriesIndex = 0;
|
||||
|
||||
for (let frame of series) {
|
||||
const fields: Field[] = [];
|
||||
for (const field of frame.fields) {
|
||||
if (field.type === FieldType.number) {
|
||||
field.state = field.state ?? {};
|
||||
|
||||
field.state.seriesIndex = seriesIndex++;
|
||||
|
||||
let copy = {
|
||||
...field,
|
||||
config: {
|
||||
|
Loading…
Reference in New Issue
Block a user