mirror of
https://github.com/Such-Software/hash-wallet.git
synced 2026-12-01 12:04:21 +01:00
refactor: Improve bridge view model (#3184)
* refactor: Improve bridge view model * Move bridge related vms into single folder * handle missing class when building for monero.com * handle missing classes in monero.com build * Minor enhancements * Update lib/view_model/bridge/bridge_view_model.dart [skip ci] * Update lib/view_model/bridge/bridge_view_model.dart --------- Co-authored-by: Omar Hatem <omarh.ismail1@gmail.com>
This commit is contained in:
co-authored by
Omar Hatem
parent
928113ea25
commit
40c4118b66
+12
-2
@@ -1570,7 +1570,7 @@ abstract class EVM {
|
||||
bool isUSDT0Token(WalletBase wallet, CryptoCurrency token);
|
||||
List<ChainInfo> getUSDT0DestinationChains(WalletBase wallet);
|
||||
|
||||
Future<USDT0Quote> quoteUSDT0Transfer({
|
||||
Future<BridgeQuote> quoteUSDT0Transfer({
|
||||
required WalletBase wallet,
|
||||
required int sourceChainId,
|
||||
required int destinationChainId,
|
||||
@@ -1585,7 +1585,7 @@ abstract class EVM {
|
||||
required int destinationChainId,
|
||||
required BigInt amount,
|
||||
required String recipientAddress,
|
||||
required USDT0Quote quote,
|
||||
required BridgeQuote quote,
|
||||
required TransactionPriority priority,
|
||||
bool useBlinkProtection = true,
|
||||
});
|
||||
@@ -1631,6 +1631,16 @@ class EvmWalletConnectFeeQuote {
|
||||
final int maxPriorityFeePerGasWei;
|
||||
final int? latestBaseFeeWei;
|
||||
}
|
||||
|
||||
class BridgeQuote {
|
||||
const BridgeQuote({
|
||||
required this.nativeFee,
|
||||
required this.lzTokenFee,
|
||||
});
|
||||
|
||||
final BigInt nativeFee;
|
||||
final BigInt lzTokenFee;
|
||||
}
|
||||
""";
|
||||
|
||||
const evmEmptyDefinition = 'EVM? evm;\n';
|
||||
|
||||
Reference in New Issue
Block a user