Updated on 2026-08-14

This commit is contained in:
Tangem 2024-10-03 14:13:39 +03:00
commit e963790304
437 changed files with 4080 additions and 12228 deletions

View file

@ -128,6 +128,12 @@ fun Blockchain.Companion.fromNetworkId(networkId: String): Blockchain? {
"internet-computer" -> Blockchain.InternetComputer
"sui" -> Blockchain.Sui
"sui/test" -> Blockchain.SuiTestnet
"energy-web-chain" -> Blockchain.EnergyWebChain
"energy-web-chain/test" -> Blockchain.EnergyWebChainTestnet
"energy-web-x" -> Blockchain.EnergyWebX
"energy-web-x/test" -> Blockchain.EnergyWebXTestnet
"add_later" -> Blockchain.Casper
"add_later_test" -> Blockchain.CasperTestnet
else -> null
}
}
@ -257,6 +263,12 @@ fun Blockchain.toNetworkId(): String {
Blockchain.InternetComputer -> "internet-computer"
Blockchain.Sui -> "sui"
Blockchain.SuiTestnet -> "sui/test"
Blockchain.EnergyWebChain -> "energy-web-chain"
Blockchain.EnergyWebChainTestnet -> "energy-web-chain/test"
Blockchain.EnergyWebX -> "energy-web-x"
Blockchain.EnergyWebXTestnet -> "energy-web-x/test"
Blockchain.Casper -> "add_later"
Blockchain.CasperTestnet -> "add_later_test"
}
}
@ -342,6 +354,10 @@ fun Blockchain.toCoinId(): String {
Blockchain.Sei, Blockchain.SeiTestnet -> "sei-network"
Blockchain.InternetComputer -> "internet-computer"
Blockchain.Sui, Blockchain.SuiTestnet -> "sui"
Blockchain.EnergyWebChain, Blockchain.EnergyWebChainTestnet -> "energy-web-token"
Blockchain.EnergyWebX, Blockchain.EnergyWebXTestnet -> "energy-web-token"
Blockchain.Casper -> "add_later"
Blockchain.CasperTestnet -> "add_later_test"
}
}
@ -368,6 +384,7 @@ fun Blockchain.minimalAmount(): BigDecimal {
private const val NODL = "NODL"
private const val NODL_AMOUNT_TO_CREATE_ACCOUNT = 1.5
// no need to add testnets
private val excludedBlockchains = listOf(
Blockchain.Unknown,
Blockchain.Nexa,