mirror of
https://github.com/cypherstack/stack_wallet.git
synced 2025-01-10 20:54:33 +00:00
a couple small Coin enum fixes and added missing coin colors
This commit is contained in:
parent
c8cc7eed94
commit
4d594e3251
4 changed files with 27 additions and 13 deletions
|
@ -45,7 +45,7 @@ class _ManageNodesViewState extends ConsumerState<ManageNodesView> {
|
||||||
|
|
||||||
List<Coin> coins = showTestNet
|
List<Coin> coins = showTestNet
|
||||||
? _coins
|
? _coins
|
||||||
: _coins.sublist(0, Coin.values.length - kTestNetCoinCount);
|
: _coins.sublist(0, _coins.length - kTestNetCoinCount);
|
||||||
|
|
||||||
return Scaffold(
|
return Scaffold(
|
||||||
backgroundColor: CFColors.almostWhite,
|
backgroundColor: CFColors.almostWhite,
|
||||||
|
|
|
@ -6,12 +6,13 @@ class _CoinThemeColor {
|
||||||
const _CoinThemeColor();
|
const _CoinThemeColor();
|
||||||
|
|
||||||
Color get bitcoin => const Color(0xFFFCC17B);
|
Color get bitcoin => const Color(0xFFFCC17B);
|
||||||
Color get bitcoincash => const Color(0xFFFCC17B);
|
Color get bitcoincash => const Color(0xFF7BCFB8);
|
||||||
Color get firo => const Color(0xFFFF897A);
|
Color get firo => const Color(0xFFFF897A);
|
||||||
Color get dogecoin => const Color(0xFFFFE079);
|
Color get dogecoin => const Color(0xFFFFE079);
|
||||||
Color get epicCash => const Color(0xFFC5C7CB);
|
Color get epicCash => const Color(0xFFC5C7CB);
|
||||||
Color get monero => const Color(0xFFFF9E6B);
|
Color get monero => const Color(0xFFFF9E6B);
|
||||||
Color get namecoin => const Color(0xFFFCC17B);
|
Color get namecoin => const Color(0xFF91B1E1);
|
||||||
|
Color get wownero => const Color(0xFFED80C1);
|
||||||
|
|
||||||
Color forCoin(Coin coin) {
|
Color forCoin(Coin coin) {
|
||||||
switch (coin) {
|
switch (coin) {
|
||||||
|
@ -33,6 +34,8 @@ class _CoinThemeColor {
|
||||||
return monero;
|
return monero;
|
||||||
case Coin.namecoin:
|
case Coin.namecoin:
|
||||||
return namecoin;
|
return namecoin;
|
||||||
|
// case Coin.wownero:
|
||||||
|
// return wownero;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,12 +1,12 @@
|
||||||
import 'package:stackwallet/services/coins/bitcoin/bitcoin_wallet.dart' as btc;
|
import 'package:stackwallet/services/coins/bitcoin/bitcoin_wallet.dart' as btc;
|
||||||
|
import 'package:stackwallet/services/coins/bitcoincash/bitcoincash_wallet.dart'
|
||||||
|
as bch;
|
||||||
import 'package:stackwallet/services/coins/dogecoin/dogecoin_wallet.dart'
|
import 'package:stackwallet/services/coins/dogecoin/dogecoin_wallet.dart'
|
||||||
as doge;
|
as doge;
|
||||||
import 'package:stackwallet/services/coins/epiccash/epiccash_wallet.dart'
|
import 'package:stackwallet/services/coins/epiccash/epiccash_wallet.dart'
|
||||||
as epic;
|
as epic;
|
||||||
import 'package:stackwallet/services/coins/firo/firo_wallet.dart' as firo;
|
import 'package:stackwallet/services/coins/firo/firo_wallet.dart' as firo;
|
||||||
import 'package:stackwallet/services/coins/monero/monero_wallet.dart' as xmr;
|
import 'package:stackwallet/services/coins/monero/monero_wallet.dart' as xmr;
|
||||||
import 'package:stackwallet/services/coins/bitcoincash/bitcoincash_wallet.dart'
|
|
||||||
as bch;
|
|
||||||
import 'package:stackwallet/services/coins/namecoin/namecoin_wallet.dart'
|
import 'package:stackwallet/services/coins/namecoin/namecoin_wallet.dart'
|
||||||
as nmc;
|
as nmc;
|
||||||
|
|
||||||
|
@ -30,7 +30,7 @@ enum Coin {
|
||||||
}
|
}
|
||||||
|
|
||||||
// remove firotestnet for now
|
// remove firotestnet for now
|
||||||
const int kTestNetCoinCount = 2;
|
const int kTestNetCoinCount = 3;
|
||||||
|
|
||||||
extension CoinExt on Coin {
|
extension CoinExt on Coin {
|
||||||
String get prettyName {
|
String get prettyName {
|
||||||
|
@ -52,7 +52,7 @@ extension CoinExt on Coin {
|
||||||
case Coin.bitcoinTestNet:
|
case Coin.bitcoinTestNet:
|
||||||
return "tBitcoin";
|
return "tBitcoin";
|
||||||
case Coin.bitcoincashTestnet:
|
case Coin.bitcoincashTestnet:
|
||||||
return "tBitcoincash";
|
return "tBitcoin Cash";
|
||||||
case Coin.firoTestNet:
|
case Coin.firoTestNet:
|
||||||
return "tFiro";
|
return "tFiro";
|
||||||
case Coin.dogecoinTestNet:
|
case Coin.dogecoinTestNet:
|
||||||
|
@ -193,7 +193,7 @@ Coin coinFromPrettyName(String name) {
|
||||||
return Coin.bitcoinTestNet;
|
return Coin.bitcoinTestNet;
|
||||||
|
|
||||||
case "Bitcoincash Testnet":
|
case "Bitcoincash Testnet":
|
||||||
case "tBitcoincash":
|
case "tBitcoin Cash":
|
||||||
case "Bitcoin Cash Testnet":
|
case "Bitcoin Cash Testnet":
|
||||||
return Coin.bitcoincashTestnet;
|
return Coin.bitcoincashTestnet;
|
||||||
case "Firo Testnet":
|
case "Firo Testnet":
|
||||||
|
|
21
pubspec.lock
21
pubspec.lock
|
@ -74,9 +74,11 @@ packages:
|
||||||
bech32:
|
bech32:
|
||||||
dependency: "direct main"
|
dependency: "direct main"
|
||||||
description:
|
description:
|
||||||
name: bech32
|
path: "."
|
||||||
url: "https://pub.dartlang.org"
|
ref: "22279d4bb24ed541b431acd269a1bc50af0f36a0"
|
||||||
source: hosted
|
resolved-ref: "22279d4bb24ed541b431acd269a1bc50af0f36a0"
|
||||||
|
url: "https://github.com/cypherstack/bech32.git"
|
||||||
|
source: git
|
||||||
version: "0.2.1"
|
version: "0.2.1"
|
||||||
bip32:
|
bip32:
|
||||||
dependency: "direct main"
|
dependency: "direct main"
|
||||||
|
@ -94,12 +96,21 @@ packages:
|
||||||
url: "https://github.com/cypherstack/stack-bip39.git"
|
url: "https://github.com/cypherstack/stack-bip39.git"
|
||||||
source: git
|
source: git
|
||||||
version: "1.0.6"
|
version: "1.0.6"
|
||||||
|
bitbox:
|
||||||
|
dependency: "direct main"
|
||||||
|
description:
|
||||||
|
path: "."
|
||||||
|
ref: ea65073efbaf395a5557e8cd7bd72f195cd7eb11
|
||||||
|
resolved-ref: ea65073efbaf395a5557e8cd7bd72f195cd7eb11
|
||||||
|
url: "https://github.com/Quppy/bitbox-flutter.git"
|
||||||
|
source: git
|
||||||
|
version: "1.0.1"
|
||||||
bitcoindart:
|
bitcoindart:
|
||||||
dependency: "direct main"
|
dependency: "direct main"
|
||||||
description:
|
description:
|
||||||
path: "."
|
path: "."
|
||||||
ref: a35968c2d2d900e77baa9f8b28c89b722c074039
|
ref: "65eb920719c8f7895c5402a07497647e7fc4b346"
|
||||||
resolved-ref: a35968c2d2d900e77baa9f8b28c89b722c074039
|
resolved-ref: "65eb920719c8f7895c5402a07497647e7fc4b346"
|
||||||
url: "https://github.com/cypherstack/bitcoindart.git"
|
url: "https://github.com/cypherstack/bitcoindart.git"
|
||||||
source: git
|
source: git
|
||||||
version: "3.0.1"
|
version: "3.0.1"
|
||||||
|
|
Loading…
Reference in a new issue