Added new tron networks
This commit is contained in:
@@ -2,6 +2,7 @@ import 'package:json_annotation/json_annotation.dart';
|
||||
|
||||
part 'confirmation.g.dart';
|
||||
|
||||
|
||||
@JsonSerializable()
|
||||
class ConfirmationResponse {
|
||||
@JsonKey(name: 'ttl_seconds', defaultValue: 0)
|
||||
|
||||
@@ -90,6 +90,10 @@ ChainNetwork chainNetworkFromValue(String? value) {
|
||||
return ChainNetwork.arbitrumOne;
|
||||
case 'other_evm':
|
||||
return ChainNetwork.otherEvm;
|
||||
case 'tron_mainnet':
|
||||
return ChainNetwork.tronMainnet;
|
||||
case 'tron_nile':
|
||||
return ChainNetwork.tronNile;
|
||||
case 'unspecified':
|
||||
return ChainNetwork.unspecified;
|
||||
default:
|
||||
@@ -105,6 +109,10 @@ String chainNetworkToValue(ChainNetwork chain) {
|
||||
return 'arbitrum_one';
|
||||
case ChainNetwork.otherEvm:
|
||||
return 'other_evm';
|
||||
case ChainNetwork.tronMainnet:
|
||||
return 'tron_mainnet';
|
||||
case ChainNetwork.tronNile:
|
||||
return 'tron_nile';
|
||||
case ChainNetwork.unspecified:
|
||||
return 'unspecified';
|
||||
}
|
||||
|
||||
@@ -49,5 +49,15 @@
|
||||
"chainNetworkOtherEvm": "Other EVM chain",
|
||||
"@chainNetworkOtherEvm": {
|
||||
"description": "Label for any other EVM-compatible network"
|
||||
},
|
||||
|
||||
"chainNetworkTronMainnet": "Tron Mainnet",
|
||||
"@chainNetworkTronMainnet": {
|
||||
"description": "Label for the Tron mainnet network"
|
||||
},
|
||||
|
||||
"chainNetworkTronNile": "Tron Nile (testnet)",
|
||||
"@chainNetworkTronNile": {
|
||||
"description": "Label for the Tron Nile testnet network"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -49,5 +49,15 @@
|
||||
"chainNetworkOtherEvm": "Другая EVM сеть",
|
||||
"@chainNetworkOtherEvm": {
|
||||
"description": "Label for any other EVM-compatible network"
|
||||
},
|
||||
|
||||
"chainNetworkTronMainnet": "Tron Mainnet",
|
||||
"@chainNetworkTronMainnet": {
|
||||
"description": "Label for the Tron mainnet network"
|
||||
},
|
||||
|
||||
"chainNetworkTronNile": "Tron Nile (testnet)",
|
||||
"@chainNetworkTronNile": {
|
||||
"description": "Label for the Tron Nile testnet network"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1 +1,8 @@
|
||||
enum ChainNetwork { unspecified, ethereumMainnet, arbitrumOne, otherEvm }
|
||||
enum ChainNetwork {
|
||||
unspecified,
|
||||
ethereumMainnet,
|
||||
arbitrumOne,
|
||||
otherEvm,
|
||||
tronMainnet,
|
||||
tronNile
|
||||
}
|
||||
|
||||
@@ -15,6 +15,10 @@ extension ChainNetworkL10n on ChainNetwork {
|
||||
return l10n.chainNetworkArbitrumOne;
|
||||
case ChainNetwork.otherEvm:
|
||||
return l10n.chainNetworkOtherEvm;
|
||||
case ChainNetwork.tronMainnet:
|
||||
return l10n.chainNetworkTronMainnet;
|
||||
case ChainNetwork.tronNile:
|
||||
return l10n.chainNetworkTronNile;
|
||||
case ChainNetwork.unspecified:
|
||||
return l10n.chainNetworkUnspecified;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user