mirror of
https://github.com/home-assistant/frontend.git
synced 2025-07-24 09:46:36 +00:00
Fix solar order in compare stack for usage graph (#24360)
* Fix solar order in compare stack for usage graph * remove accidental commit
This commit is contained in:
parent
680d81001c
commit
783132ae46
@ -291,20 +291,19 @@ export class HuiEnergyUsageGraphCard
|
||||
true
|
||||
)
|
||||
);
|
||||
} else {
|
||||
// add empty dataset so compare bars are first
|
||||
// `stack: usage` so it doesn't take up space yet
|
||||
const firstId = statIds.from_grid?.[0] ?? "placeholder";
|
||||
datasets.push({
|
||||
id: "compare-" + firstId,
|
||||
type: "bar",
|
||||
stack: "usage",
|
||||
data: [],
|
||||
// @ts-expect-error
|
||||
order: 0,
|
||||
});
|
||||
}
|
||||
|
||||
// add empty dataset so compare bars are first
|
||||
// `stack: usage` so it doesn't take up space yet
|
||||
datasets.push({
|
||||
id: "compare-placeholder",
|
||||
type: "bar",
|
||||
stack: energyData.statsCompare ? "compare" : "usage",
|
||||
data: [],
|
||||
// @ts-expect-error
|
||||
order: 0,
|
||||
});
|
||||
|
||||
datasets.push(
|
||||
...this._processDataSet(
|
||||
energyData.stats,
|
||||
|
Loading…
x
Reference in New Issue
Block a user