From d9966143c19b2e26a8f2a109a5c3ce52fc4661d6 Mon Sep 17 00:00:00 2001 From: Mononaut Date: Wed, 15 Nov 2023 08:49:22 +0000 Subject: [PATCH] Minimum acceleration preview bar height --- .../accelerate-fee-graph.component.scss | 1 + .../accelerate-fee-graph.component.ts | 16 +++++++++------- 2 files changed, 10 insertions(+), 7 deletions(-) diff --git a/frontend/src/app/components/accelerate-preview/accelerate-fee-graph.component.scss b/frontend/src/app/components/accelerate-preview/accelerate-fee-graph.component.scss index 6137b53ee..795d11df6 100644 --- a/frontend/src/app/components/accelerate-preview/accelerate-fee-graph.component.scss +++ b/frontend/src/app/components/accelerate-preview/accelerate-fee-graph.component.scss @@ -18,6 +18,7 @@ bottom: 0; left: 0; right: 0; + min-height: 30px; display: flex; flex-direction: column; justify-content: center; diff --git a/frontend/src/app/components/accelerate-preview/accelerate-fee-graph.component.ts b/frontend/src/app/components/accelerate-preview/accelerate-fee-graph.component.ts index 4d746a0d9..b5aebd35f 100644 --- a/frontend/src/app/components/accelerate-preview/accelerate-fee-graph.component.ts +++ b/frontend/src/app/components/accelerate-preview/accelerate-fee-graph.component.ts @@ -58,13 +58,15 @@ export class AccelerateFeeGraphComponent implements OnInit, OnChanges { fee: option.fee, } }); - bars.push({ - rate: this.estimate.targetFeeRate, - style: this.getStyle(this.estimate.targetFeeRate, maxRate, baseHeight), - class: 'target', - label: 'next block', - fee: this.estimate.nextBlockFee - this.estimate.txSummary.effectiveFee - }); + if (this.estimate.nextBlockFee > this.estimate.txSummary.effectiveFee) { + bars.push({ + rate: this.estimate.targetFeeRate, + style: this.getStyle(this.estimate.targetFeeRate, maxRate, baseHeight), + class: 'target', + label: 'next block', + fee: this.estimate.nextBlockFee - this.estimate.txSummary.effectiveFee + }); + } bars.push({ rate: baseRate, style: this.getStyle(baseRate, maxRate, 0),