mirror of
https://github.com/Such-Software/hash-wallet.git
synced 2026-10-17 05:41:29 +02:00
feat: introduce feeFormattedValue and feeFormatted to remove string parsing in view model (#2366)
Co-authored-by: Omar Hatem <omarh.ismail1@gmail.com>
This commit is contained in:
@@ -36,8 +36,13 @@ class PendingEVMChainTransaction with PendingTransaction {
|
||||
|
||||
@override
|
||||
String get feeFormatted {
|
||||
return "$feeFormattedValue $feeCurrency";
|
||||
}
|
||||
|
||||
@override
|
||||
String get feeFormattedValue {
|
||||
final _fee = (fee / BigInt.from(pow(10, 18))).toString();
|
||||
return "${_fee.substring(0, min(10, _fee.length))} $feeCurrency";
|
||||
return _fee.substring(0, min(10, _fee.length));
|
||||
}
|
||||
|
||||
@override
|
||||
|
||||
Reference in New Issue
Block a user