diff --git a/app/src/main/assets/testnet_tokens.json b/app/src/main/assets/testnet_tokens.json
index 3badefc007..30fa60f3c4 100644
--- a/app/src/main/assets/testnet_tokens.json
+++ b/app/src/main/assets/testnet_tokens.json
@@ -748,6 +748,16 @@
"networkId": "core/test"
}
]
+ },
+ {
+ "id": "casper-network",
+ "name": "Casper",
+ "symbol": "CSPR",
+ "networks": [
+ {
+ "networkId": "casper-network/test"
+ }
+ ]
}
]
}
diff --git a/core/ui/src/main/java/com/tangem/core/ui/extensions/BlockchainIcons.kt b/core/ui/src/main/java/com/tangem/core/ui/extensions/BlockchainIcons.kt
index 9c460e02a1..1270dd2741 100644
--- a/core/ui/src/main/java/com/tangem/core/ui/extensions/BlockchainIcons.kt
+++ b/core/ui/src/main/java/com/tangem/core/ui/extensions/BlockchainIcons.kt
@@ -79,6 +79,7 @@ fun getActiveIconRes(blockchainId: String): Int {
"energy-web-chain", "energy-web-chain/test" -> R.drawable.img_energy_web_22
"energy-web-x", "energy-web-x/test" -> R.drawable.img_energy_web_22
"core", "core/test" -> R.drawable.img_core_22
+ "casper-network", "casper-network/test" -> R.drawable.img_casper_22
else -> R.drawable.ic_alert_24
}
}
@@ -159,6 +160,7 @@ fun getActiveIconResByNetworkId(networkId: String): Int {
"energy-web-chain", "energy-web-chain/test" -> R.drawable.img_energy_web_22
"energy-web-x", "energy-web-x/test" -> R.drawable.img_energy_web_22
"core", "core/test" -> R.drawable.img_core_22
+ "casper-network", "casper-network/test" -> R.drawable.img_casper_22
else -> R.drawable.ic_alert_24
}
}
@@ -236,6 +238,7 @@ fun getActiveIconResByCoinId(coinId: String): Int {
"energy-web-chain", "energy-web-chain/test" -> R.drawable.img_energy_web_22
"energy-web-x", "energy-web-x/test" -> R.drawable.img_energy_web_22
"core", "core/test" -> R.drawable.img_core_22
+ "casper-network" -> R.drawable.img_casper_22
else -> R.drawable.ic_alert_24
}
}
@@ -316,6 +319,7 @@ fun getGreyedOutIconRes(blockchainId: String): Int {
"energy-web-chain", "energy-web-chain/test" -> R.drawable.ic_energy_web_22
"energy-web-x", "energy-web-x/test" -> R.drawable.ic_energy_web_22
"core", "core/test" -> R.drawable.ic_core_22
+ "casper-network", "casper-network/test" -> R.drawable.ic_casper_22
else -> R.drawable.ic_alert_24
}
}
@@ -396,6 +400,7 @@ fun getGreyedOutIconResByNetworkId(networkId: String): Int {
"energy-web-chain", "energy-web-chain/test" -> R.drawable.ic_energy_web_22
"energy-web-x", "energy-web-x/test" -> R.drawable.ic_energy_web_22
"core", "core/test" -> R.drawable.ic_core_22
+ "casper-network", "casper-network/test" -> R.drawable.ic_casper_22
else -> R.drawable.ic_alert_24
}
}
\ No newline at end of file
diff --git a/core/ui/src/main/res/drawable/ic_casper_22.xml b/core/ui/src/main/res/drawable/ic_casper_22.xml
new file mode 100644
index 0000000000..e2abfc22ea
--- /dev/null
+++ b/core/ui/src/main/res/drawable/ic_casper_22.xml
@@ -0,0 +1,9 @@
+
+
+
diff --git a/core/ui/src/main/res/drawable/img_casper_22.xml b/core/ui/src/main/res/drawable/img_casper_22.xml
new file mode 100644
index 0000000000..ade71437f7
--- /dev/null
+++ b/core/ui/src/main/res/drawable/img_casper_22.xml
@@ -0,0 +1,19 @@
+
+
+
+
+
+
+
+
diff --git a/libs/blockchain-sdk/src/main/java/com/tangem/blockchainsdk/utils/Blockchain.kt b/libs/blockchain-sdk/src/main/java/com/tangem/blockchainsdk/utils/Blockchain.kt
index c8e9fca637..3132bfa610 100644
--- a/libs/blockchain-sdk/src/main/java/com/tangem/blockchainsdk/utils/Blockchain.kt
+++ b/libs/blockchain-sdk/src/main/java/com/tangem/blockchainsdk/utils/Blockchain.kt
@@ -136,6 +136,8 @@ fun Blockchain.Companion.fromNetworkId(networkId: String): Blockchain? {
"add_later_test" -> Blockchain.CasperTestnet
"core" -> Blockchain.Core
"core/test" -> Blockchain.CoreTestnet
+ "casper-network" -> Blockchain.Casper
+ "casper-network/test" -> Blockchain.CasperTestnet
else -> null
}
}
@@ -269,8 +271,8 @@ fun Blockchain.toNetworkId(): String {
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"
+ Blockchain.Casper -> "casper-network"
+ Blockchain.CasperTestnet -> "casper-network/test"
Blockchain.Core -> "core"
Blockchain.CoreTestnet -> "core/test"
}
@@ -360,8 +362,7 @@ fun Blockchain.toCoinId(): String {
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"
+ Blockchain.Casper, Blockchain.CasperTestnet -> "casper-network"
Blockchain.Core, Blockchain.CoreTestnet -> "coredaoorg"
}
}
@@ -386,6 +387,7 @@ fun Blockchain.amountToCreateAccount(token: Token? = null): BigDecimal? {
Blockchain.Near, Blockchain.NearTestnet -> 0.00182.toBigDecimal()
Blockchain.Aptos, Blockchain.AptosTestnet,
Blockchain.Filecoin,
+ Blockchain.Casper, Blockchain.CasperTestnet,
-> BigDecimal.ZERO
else -> null
}