diff --git a/frontend/src/app/components/transaction/transaction.component.html b/frontend/src/app/components/transaction/transaction.component.html
index 006870864..f062662dc 100644
--- a/frontend/src/app/components/transaction/transaction.component.html
+++ b/frontend/src/app/components/transaction/transaction.component.html
@@ -292,9 +292,9 @@
Virtual size |
|
- (tx.weight / 4)">
+
Adjusted vsize |
- |
+ |
Weight |
@@ -314,9 +314,9 @@
Locktime |
|
- (tx.weight / 4)">
+
Sigops |
- |
+ |
Transaction hex |
diff --git a/frontend/src/app/components/transaction/transaction.component.ts b/frontend/src/app/components/transaction/transaction.component.ts
index 4743e5cd6..5260cd668 100644
--- a/frontend/src/app/components/transaction/transaction.component.ts
+++ b/frontend/src/app/components/transaction/transaction.component.ts
@@ -62,6 +62,8 @@ export class TransactionComponent implements OnInit, AfterViewInit, OnDestroy {
rbfReplaces: string[];
rbfInfo: RbfTree;
cpfpInfo: CpfpInfo | null;
+ sigops: number | null;
+ adjustedVsize: number | null;
showCpfpDetails = false;
fetchCpfp$ = new Subject();
fetchRbfHistory$ = new Subject();
@@ -343,6 +345,10 @@ export class TransactionComponent implements OnInit, AfterViewInit, OnDestroy {
if (tx.fee === undefined) {
this.tx.fee = 0;
}
+ if (this.tx.sigops != null) {
+ this.sigops = this.tx.sigops;
+ this.adjustedVsize = Math.max(this.tx.weight / 4, this.sigops * 5);
+ }
this.tx.feePerVsize = tx.fee / (tx.weight / 4);
this.isLoadingTx = false;
this.error = undefined;
@@ -543,6 +549,10 @@ export class TransactionComponent implements OnInit, AfterViewInit, OnDestroy {
}
this.cpfpInfo = cpfpInfo;
+ if (this.cpfpInfo.adjustedVsize && this.cpfpInfo.sigops != null) {
+ this.sigops = this.cpfpInfo.sigops;
+ this.adjustedVsize = this.cpfpInfo.adjustedVsize;
+ }
this.hasEffectiveFeeRate = hasRelatives || (this.tx.effectiveFeePerVsize && (Math.abs(this.tx.effectiveFeePerVsize - this.tx.feePerVsize) > 0.01));
}
@@ -569,6 +579,8 @@ export class TransactionComponent implements OnInit, AfterViewInit, OnDestroy {
this.replaced = false;
this.transactionTime = -1;
this.cpfpInfo = null;
+ this.adjustedVsize = null;
+ this.sigops = null;
this.hasEffectiveFeeRate = false;
this.rbfInfo = null;
this.rbfReplaces = [];
diff --git a/frontend/src/app/interfaces/electrs.interface.ts b/frontend/src/app/interfaces/electrs.interface.ts
index 2d604a9de..58a02ad79 100644
--- a/frontend/src/app/interfaces/electrs.interface.ts
+++ b/frontend/src/app/interfaces/electrs.interface.ts
@@ -26,6 +26,7 @@ export interface Transaction {
_outspends?: Outspend[];
_channels?: TransactionChannels;
price?: Price;
+ sigops?: number;
}
export interface TransactionChannels {