From b79ed000eae0e8c72e8cd78f7e6b83a71be52757 Mon Sep 17 00:00:00 2001 From: nymkappa Date: Tue, 7 Jul 2026 12:36:30 +0200 Subject: [PATCH] [echart] fix regression from v6 --- .../acceleration-fees-graph.component.ts | 1 + .../src/app/components/address-graph/address-graph.component.ts | 2 ++ .../block-fee-rates-graph/block-fee-rates-graph.component.ts | 1 + .../components/block-fees-graph/block-fees-graph.component.ts | 1 + .../block-fees-subsidy-graph.component.ts | 1 + .../block-rewards-graph/block-rewards-graph.component.ts | 1 + .../block-sizes-weights-graph.component.ts | 2 +- .../app/components/hashrate-chart/hashrate-chart.component.ts | 1 + .../hashrates-chart-pools/hashrate-chart-pools.component.ts | 1 + frontend/src/app/components/pool/pool.component.ts | 1 + .../treasuries/treasuries-graph/treasuries-graph.component.ts | 1 + .../statistics-chart/lightning-statistics-chart.component.ts | 2 +- 12 files changed, 13 insertions(+), 2 deletions(-) diff --git a/frontend/src/app/components/acceleration/acceleration-fees-graph/acceleration-fees-graph.component.ts b/frontend/src/app/components/acceleration/acceleration-fees-graph/acceleration-fees-graph.component.ts index d27d7db1b..915c79c93 100644 --- a/frontend/src/app/components/acceleration/acceleration-fees-graph/acceleration-fees-graph.component.ts +++ b/frontend/src/app/components/acceleration/acceleration-fees-graph/acceleration-fees-graph.component.ts @@ -220,6 +220,7 @@ export class AccelerationFeesGraphComponent implements OnInit, OnChanges, OnDest }, }, legend: { + top: 'top', data: [ { name: this.totalBidBoostLabel, diff --git a/frontend/src/app/components/address-graph/address-graph.component.ts b/frontend/src/app/components/address-graph/address-graph.component.ts index 2d4d77f13..542a185ef 100644 --- a/frontend/src/app/components/address-graph/address-graph.component.ts +++ b/frontend/src/app/components/address-graph/address-graph.component.ts @@ -211,6 +211,7 @@ export class AddressGraphComponent implements OnChanges, OnDestroy { }, graphic: graphicElements.length > 0 ? graphicElements : undefined, legend: (this.showLegend && !this.stateService.isAnyTestnet()) ? { + top: 'top', data: [ { name: $localize`:@@7e69426bd97a606d8ae6026762858e6e7c86a1fd:Balance`, @@ -451,6 +452,7 @@ export class AddressGraphComponent implements OnChanges, OnDestroy { }, graphic: graphicElements.length > 0 ? graphicElements : undefined, legend: { + top: 'top', selected: this.selected, }, dataZoom: this.allowZoom ? [{ diff --git a/frontend/src/app/components/block-fee-rates-graph/block-fee-rates-graph.component.ts b/frontend/src/app/components/block-fee-rates-graph/block-fee-rates-graph.component.ts index 86c7e4619..5293c7ba3 100644 --- a/frontend/src/app/components/block-fee-rates-graph/block-fee-rates-graph.component.ts +++ b/frontend/src/app/components/block-fee-rates-graph/block-fee-rates-graph.component.ts @@ -281,6 +281,7 @@ export class BlockFeeRatesGraphComponent implements OnInit { }, }, legend: (this.widget || data.series.length === 0) ? undefined : { + top: 'top', padding: [10, 75], data: data.legends, selected: JSON.parse(this.storageService.getValue('fee_rates_legend') || 'null') ?? { diff --git a/frontend/src/app/components/block-fees-graph/block-fees-graph.component.ts b/frontend/src/app/components/block-fees-graph/block-fees-graph.component.ts index 82caae836..4c3d7f3a0 100644 --- a/frontend/src/app/components/block-fees-graph/block-fees-graph.component.ts +++ b/frontend/src/app/components/block-fees-graph/block-fees-graph.component.ts @@ -187,6 +187,7 @@ export class BlockFeesGraphComponent implements OnInit { } }, legend: data.blockFees.length === 0 ? undefined : { + top: 'top', data: [ { name: feesBtcLabel, diff --git a/frontend/src/app/components/block-fees-subsidy-graph/block-fees-subsidy-graph.component.ts b/frontend/src/app/components/block-fees-subsidy-graph/block-fees-subsidy-graph.component.ts index 9ac3fb01f..212f1c41d 100644 --- a/frontend/src/app/components/block-fees-subsidy-graph/block-fees-subsidy-graph.component.ts +++ b/frontend/src/app/components/block-fees-subsidy-graph/block-fees-subsidy-graph.component.ts @@ -240,6 +240,7 @@ export class BlockFeesSubsidyGraphComponent implements OnInit { } ], legend: this.data.blockFees.length === 0 ? undefined : { + top: 'top', data: [ { name: this.subsidyLabel, diff --git a/frontend/src/app/components/block-rewards-graph/block-rewards-graph.component.ts b/frontend/src/app/components/block-rewards-graph/block-rewards-graph.component.ts index 137cabe74..8dabd236c 100644 --- a/frontend/src/app/components/block-rewards-graph/block-rewards-graph.component.ts +++ b/frontend/src/app/components/block-rewards-graph/block-rewards-graph.component.ts @@ -183,6 +183,7 @@ export class BlockRewardsGraphComponent implements OnInit { } }, legend: data.blockRewards.length === 0 ? undefined : { + top: 'top', data: [ { name: 'Rewards BTC', diff --git a/frontend/src/app/components/block-sizes-weights-graph/block-sizes-weights-graph.component.ts b/frontend/src/app/components/block-sizes-weights-graph/block-sizes-weights-graph.component.ts index 1223be9c8..f1ec24e9a 100644 --- a/frontend/src/app/components/block-sizes-weights-graph/block-sizes-weights-graph.component.ts +++ b/frontend/src/app/components/block-sizes-weights-graph/block-sizes-weights-graph.component.ts @@ -182,7 +182,7 @@ export class BlockSizesWeightsGraphComponent implements OnInit { } }, legend: data.sizes.length === 0 ? undefined : { - padding: 10, + top: 'top', data: [ { name: $localize`:@@7faaaa08f56427999f3be41df1093ce4089bbd75:Size`, diff --git a/frontend/src/app/components/hashrate-chart/hashrate-chart.component.ts b/frontend/src/app/components/hashrate-chart/hashrate-chart.component.ts index 5c429fd6c..2ecba6e56 100644 --- a/frontend/src/app/components/hashrate-chart/hashrate-chart.component.ts +++ b/frontend/src/app/components/hashrate-chart/hashrate-chart.component.ts @@ -287,6 +287,7 @@ export class HashrateChartComponent implements OnInit { } }, legend: (this.widget || data.hashrates.length === 0) ? undefined : { + top: 'top', data: [ { name: $localize`:@@79a9dc5b1caca3cbeb1733a19515edacc5fc7920:Hashrate`, diff --git a/frontend/src/app/components/hashrates-chart-pools/hashrate-chart-pools.component.ts b/frontend/src/app/components/hashrates-chart-pools/hashrate-chart-pools.component.ts index cc45cbc7f..a51bcf548 100644 --- a/frontend/src/app/components/hashrates-chart-pools/hashrate-chart-pools.component.ts +++ b/frontend/src/app/components/hashrates-chart-pools/hashrate-chart-pools.component.ts @@ -250,6 +250,7 @@ export class HashrateChartPoolsComponent implements OnInit { } }, legend: (this.isMobile() || data.series.length === 0) ? undefined : { + top: 'top', data: data.legends }, yAxis: data.series.length === 0 ? undefined : { diff --git a/frontend/src/app/components/pool/pool.component.ts b/frontend/src/app/components/pool/pool.component.ts index 427035693..61821b540 100644 --- a/frontend/src/app/components/pool/pool.component.ts +++ b/frontend/src/app/components/pool/pool.component.ts @@ -240,6 +240,7 @@ export class PoolComponent implements OnInit, OnDestroy { } }, legend: { + top: 'top', data: [ { name: $localize`:@@79a9dc5b1caca3cbeb1733a19515edacc5fc7920:Hashrate`, diff --git a/frontend/src/app/components/treasuries/treasuries-graph/treasuries-graph.component.ts b/frontend/src/app/components/treasuries/treasuries-graph/treasuries-graph.component.ts index d1c15ec2b..8991c251a 100644 --- a/frontend/src/app/components/treasuries/treasuries-graph/treasuries-graph.component.ts +++ b/frontend/src/app/components/treasuries/treasuries-graph/treasuries-graph.component.ts @@ -402,6 +402,7 @@ export class TreasuriesGraphComponent implements OnInit, OnChanges, OnDestroy { this.chartOptions = { legend: { + top: 'top', selected: this.selectedWallets, } }; diff --git a/frontend/src/app/lightning/statistics-chart/lightning-statistics-chart.component.ts b/frontend/src/app/lightning/statistics-chart/lightning-statistics-chart.component.ts index d335e8b30..2eaf67183 100644 --- a/frontend/src/app/lightning/statistics-chart/lightning-statistics-chart.component.ts +++ b/frontend/src/app/lightning/statistics-chart/lightning-statistics-chart.component.ts @@ -200,7 +200,7 @@ export class LightningStatisticsChartComponent implements OnInit, OnChanges { } }, legend: this.widget || data.channel_count.length === 0 ? undefined : { - padding: 10, + top: 'top', data: [ { name: $localize`:@@807cf11e6ac1cde912496f764c176bdfdd6b7e19:Channels`,