mirror of
https://github.com/cypherstack/stack_wallet.git
synced 2024-11-16 17:27:39 +00:00
dark mode testing without partial nmc+bch
This commit is contained in:
parent
4c25c67d89
commit
43b673ec0d
20 changed files with 11814 additions and 11829 deletions
|
@ -113,12 +113,12 @@ class _AddEditNodeViewState extends ConsumerState<AddEditNodeView> {
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case Coin.bitcoin:
|
case Coin.bitcoin:
|
||||||
case Coin.bitcoincash:
|
// case Coin.bitcoincash:
|
||||||
case Coin.dogecoin:
|
case Coin.dogecoin:
|
||||||
case Coin.firo:
|
case Coin.firo:
|
||||||
case Coin.namecoin:
|
// case Coin.namecoin:
|
||||||
case Coin.bitcoinTestNet:
|
case Coin.bitcoinTestNet:
|
||||||
case Coin.bitcoincashTestnet:
|
// case Coin.bitcoincashTestnet:
|
||||||
case Coin.firoTestNet:
|
case Coin.firoTestNet:
|
||||||
case Coin.dogecoinTestNet:
|
case Coin.dogecoinTestNet:
|
||||||
final client = ElectrumX(
|
final client = ElectrumX(
|
||||||
|
@ -529,10 +529,10 @@ class _NodeFormState extends ConsumerState<NodeForm> {
|
||||||
case Coin.bitcoin:
|
case Coin.bitcoin:
|
||||||
case Coin.dogecoin:
|
case Coin.dogecoin:
|
||||||
case Coin.firo:
|
case Coin.firo:
|
||||||
case Coin.namecoin:
|
// case Coin.namecoin:
|
||||||
case Coin.bitcoincash:
|
// case Coin.bitcoincash:
|
||||||
case Coin.bitcoinTestNet:
|
case Coin.bitcoinTestNet:
|
||||||
case Coin.bitcoincashTestnet:
|
// case Coin.bitcoincashTestnet:
|
||||||
case Coin.firoTestNet:
|
case Coin.firoTestNet:
|
||||||
case Coin.dogecoinTestNet:
|
case Coin.dogecoinTestNet:
|
||||||
return false;
|
return false;
|
||||||
|
|
|
@ -102,9 +102,9 @@ class _NodeDetailsViewState extends ConsumerState<NodeDetailsView> {
|
||||||
case Coin.bitcoinTestNet:
|
case Coin.bitcoinTestNet:
|
||||||
case Coin.firoTestNet:
|
case Coin.firoTestNet:
|
||||||
case Coin.dogecoinTestNet:
|
case Coin.dogecoinTestNet:
|
||||||
case Coin.bitcoincash:
|
// case Coin.bitcoincash:
|
||||||
case Coin.namecoin:
|
// case Coin.namecoin:
|
||||||
case Coin.bitcoincashTestnet:
|
// case Coin.bitcoincashTestnet:
|
||||||
final client = ElectrumX(
|
final client = ElectrumX(
|
||||||
host: node!.host,
|
host: node!.host,
|
||||||
port: node.port,
|
port: node.port,
|
||||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -8,8 +8,6 @@ import 'package:stackwallet/services/coins/dogecoin/dogecoin_wallet.dart';
|
||||||
import 'package:stackwallet/services/coins/epiccash/epiccash_wallet.dart';
|
import 'package:stackwallet/services/coins/epiccash/epiccash_wallet.dart';
|
||||||
import 'package:stackwallet/services/coins/firo/firo_wallet.dart';
|
import 'package:stackwallet/services/coins/firo/firo_wallet.dart';
|
||||||
import 'package:stackwallet/services/coins/monero/monero_wallet.dart';
|
import 'package:stackwallet/services/coins/monero/monero_wallet.dart';
|
||||||
import 'package:stackwallet/services/coins/bitcoincash/bitcoincash_wallet.dart';
|
|
||||||
import 'package:stackwallet/services/coins/namecoin/namecoin_wallet.dart';
|
|
||||||
import 'package:stackwallet/services/transaction_notification_tracker.dart';
|
import 'package:stackwallet/services/transaction_notification_tracker.dart';
|
||||||
import 'package:stackwallet/utilities/enums/coin_enum.dart';
|
import 'package:stackwallet/utilities/enums/coin_enum.dart';
|
||||||
import 'package:stackwallet/utilities/prefs.dart';
|
import 'package:stackwallet/utilities/prefs.dart';
|
||||||
|
@ -99,25 +97,25 @@ abstract class CoinServiceAPI {
|
||||||
tracker: tracker,
|
tracker: tracker,
|
||||||
);
|
);
|
||||||
|
|
||||||
case Coin.bitcoincash:
|
// case Coin.bitcoincash:
|
||||||
return BitcoinCashWallet(
|
// return BitcoinCashWallet(
|
||||||
walletId: walletId,
|
// walletId: walletId,
|
||||||
walletName: walletName,
|
// walletName: walletName,
|
||||||
coin: coin,
|
// coin: coin,
|
||||||
client: client,
|
// client: client,
|
||||||
cachedClient: cachedClient,
|
// cachedClient: cachedClient,
|
||||||
tracker: tracker,
|
// tracker: tracker,
|
||||||
);
|
// );
|
||||||
|
//
|
||||||
case Coin.bitcoincashTestnet:
|
// case Coin.bitcoincashTestnet:
|
||||||
return BitcoinCashWallet(
|
// return BitcoinCashWallet(
|
||||||
walletId: walletId,
|
// walletId: walletId,
|
||||||
walletName: walletName,
|
// walletName: walletName,
|
||||||
coin: coin,
|
// coin: coin,
|
||||||
client: client,
|
// client: client,
|
||||||
cachedClient: cachedClient,
|
// cachedClient: cachedClient,
|
||||||
tracker: tracker,
|
// tracker: tracker,
|
||||||
);
|
// );
|
||||||
|
|
||||||
case Coin.dogecoin:
|
case Coin.dogecoin:
|
||||||
return DogecoinWallet(
|
return DogecoinWallet(
|
||||||
|
@ -145,15 +143,15 @@ abstract class CoinServiceAPI {
|
||||||
// tracker: tracker,
|
// tracker: tracker,
|
||||||
);
|
);
|
||||||
|
|
||||||
case Coin.namecoin:
|
// case Coin.namecoin:
|
||||||
return NamecoinWallet(
|
// return NamecoinWallet(
|
||||||
walletId: walletId,
|
// walletId: walletId,
|
||||||
walletName: walletName,
|
// walletName: walletName,
|
||||||
coin: coin,
|
// coin: coin,
|
||||||
tracker: tracker,
|
// tracker: tracker,
|
||||||
cachedClient: cachedClient,
|
// cachedClient: cachedClient,
|
||||||
client: client,
|
// client: client,
|
||||||
);
|
// );
|
||||||
|
|
||||||
case Coin.dogecoinTestNet:
|
case Coin.dogecoinTestNet:
|
||||||
return DogecoinWallet(
|
return DogecoinWallet(
|
||||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -5,8 +5,6 @@ import 'package:crypto/crypto.dart';
|
||||||
import 'package:flutter_libepiccash/epic_cash.dart';
|
import 'package:flutter_libepiccash/epic_cash.dart';
|
||||||
import 'package:stackwallet/services/coins/dogecoin/dogecoin_wallet.dart';
|
import 'package:stackwallet/services/coins/dogecoin/dogecoin_wallet.dart';
|
||||||
import 'package:stackwallet/services/coins/firo/firo_wallet.dart';
|
import 'package:stackwallet/services/coins/firo/firo_wallet.dart';
|
||||||
import 'package:stackwallet/services/coins/bitcoincash/bitcoincash_wallet.dart';
|
|
||||||
import 'package:stackwallet/services/coins/namecoin/namecoin_wallet.dart';
|
|
||||||
import 'package:stackwallet/utilities/enums/coin_enum.dart';
|
import 'package:stackwallet/utilities/enums/coin_enum.dart';
|
||||||
import 'package:stackwallet/utilities/logger.dart';
|
import 'package:stackwallet/utilities/logger.dart';
|
||||||
|
|
||||||
|
@ -42,8 +40,8 @@ class AddressUtils {
|
||||||
switch (coin) {
|
switch (coin) {
|
||||||
case Coin.bitcoin:
|
case Coin.bitcoin:
|
||||||
return Address.validateAddress(address, bitcoin);
|
return Address.validateAddress(address, bitcoin);
|
||||||
case Coin.bitcoincash:
|
// case Coin.bitcoincash:
|
||||||
return Address.validateAddress(address, bitcoincash);
|
// return Address.validateAddress(address, bitcoincash);
|
||||||
case Coin.dogecoin:
|
case Coin.dogecoin:
|
||||||
return Address.validateAddress(address, dogecoin);
|
return Address.validateAddress(address, dogecoin);
|
||||||
case Coin.epicCash:
|
case Coin.epicCash:
|
||||||
|
@ -53,12 +51,12 @@ class AddressUtils {
|
||||||
case Coin.monero:
|
case Coin.monero:
|
||||||
return RegExp("[a-zA-Z0-9]{95}").hasMatch(address) ||
|
return RegExp("[a-zA-Z0-9]{95}").hasMatch(address) ||
|
||||||
RegExp("[a-zA-Z0-9]{106}").hasMatch(address);
|
RegExp("[a-zA-Z0-9]{106}").hasMatch(address);
|
||||||
case Coin.namecoin:
|
// case Coin.namecoin:
|
||||||
return Address.validateAddress(address, namecoin);
|
// return Address.validateAddress(address, namecoin);
|
||||||
case Coin.bitcoinTestNet:
|
case Coin.bitcoinTestNet:
|
||||||
return Address.validateAddress(address, testnet);
|
return Address.validateAddress(address, testnet);
|
||||||
case Coin.bitcoincashTestnet:
|
// case Coin.bitcoincashTestnet:
|
||||||
return Address.validateAddress(address, bitcoincashtestnet);
|
// return Address.validateAddress(address, bitcoincashtestnet);
|
||||||
case Coin.firoTestNet:
|
case Coin.firoTestNet:
|
||||||
return Address.validateAddress(address, firoTestNetwork);
|
return Address.validateAddress(address, firoTestNetwork);
|
||||||
case Coin.dogecoinTestNet:
|
case Coin.dogecoinTestNet:
|
||||||
|
|
|
@ -138,8 +138,8 @@ class _SVG {
|
||||||
switch (coin) {
|
switch (coin) {
|
||||||
case Coin.bitcoin:
|
case Coin.bitcoin:
|
||||||
return bitcoin;
|
return bitcoin;
|
||||||
case Coin.bitcoincash:
|
// case Coin.bitcoincash:
|
||||||
return bitcoincash;
|
// return bitcoincash;
|
||||||
case Coin.dogecoin:
|
case Coin.dogecoin:
|
||||||
return dogecoin;
|
return dogecoin;
|
||||||
case Coin.epicCash:
|
case Coin.epicCash:
|
||||||
|
@ -148,12 +148,12 @@ class _SVG {
|
||||||
return firo;
|
return firo;
|
||||||
case Coin.monero:
|
case Coin.monero:
|
||||||
return monero;
|
return monero;
|
||||||
case Coin.namecoin:
|
// case Coin.namecoin:
|
||||||
return namecoin;
|
// return namecoin;
|
||||||
case Coin.bitcoinTestNet:
|
case Coin.bitcoinTestNet:
|
||||||
return bitcoinTestnet;
|
return bitcoinTestnet;
|
||||||
case Coin.bitcoincashTestnet:
|
// case Coin.bitcoincashTestnet:
|
||||||
return bitcoincashTestnet;
|
// return bitcoincashTestnet;
|
||||||
case Coin.firoTestNet:
|
case Coin.firoTestNet:
|
||||||
return firoTestnet;
|
return firoTestnet;
|
||||||
case Coin.dogecoinTestNet:
|
case Coin.dogecoinTestNet:
|
||||||
|
@ -181,9 +181,9 @@ class _PNG {
|
||||||
case Coin.bitcoin:
|
case Coin.bitcoin:
|
||||||
case Coin.bitcoinTestNet:
|
case Coin.bitcoinTestNet:
|
||||||
return bitcoin;
|
return bitcoin;
|
||||||
case Coin.bitcoincash:
|
// case Coin.bitcoincash:
|
||||||
case Coin.bitcoincashTestnet:
|
// case Coin.bitcoincashTestnet:
|
||||||
return bitcoincash;
|
// return bitcoincash;
|
||||||
case Coin.dogecoin:
|
case Coin.dogecoin:
|
||||||
case Coin.dogecoinTestNet:
|
case Coin.dogecoinTestNet:
|
||||||
return dogecoin;
|
return dogecoin;
|
||||||
|
@ -195,8 +195,8 @@ class _PNG {
|
||||||
return firo;
|
return firo;
|
||||||
case Coin.monero:
|
case Coin.monero:
|
||||||
return monero;
|
return monero;
|
||||||
case Coin.namecoin:
|
// case Coin.namecoin:
|
||||||
return namecoin;
|
// return namecoin;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -22,12 +22,12 @@ Uri getBlockExplorerTransactionUrlFor({
|
||||||
return Uri.parse("https://explorer.firo.org/tx/$txid");
|
return Uri.parse("https://explorer.firo.org/tx/$txid");
|
||||||
case Coin.firoTestNet:
|
case Coin.firoTestNet:
|
||||||
return Uri.parse("https://testexplorer.firo.org/tx/$txid");
|
return Uri.parse("https://testexplorer.firo.org/tx/$txid");
|
||||||
case Coin.bitcoincash:
|
// case Coin.bitcoincash:
|
||||||
return Uri.parse("https://blockchair.com/bitcoin-cash/transaction/$txid");
|
// return Uri.parse("https://blockchair.com/bitcoin-cash/transaction/$txid");
|
||||||
case Coin.bitcoincashTestnet:
|
// case Coin.bitcoincashTestnet:
|
||||||
return Uri.parse(
|
// return Uri.parse(
|
||||||
"https://blockexplorer.one/bitcoin-cash/testnet/tx/$txid");
|
// "https://blockexplorer.one/bitcoin-cash/testnet/tx/$txid");
|
||||||
case Coin.namecoin:
|
// case Coin.namecoin:
|
||||||
return Uri.parse("https://chainz.cryptoid.info/nmc/tx.dws?$txid.htm");
|
// return Uri.parse("https://chainz.cryptoid.info/nmc/tx.dws?$txid.htm");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -39,14 +39,15 @@ abstract class Constants {
|
||||||
final List<int> values = [];
|
final List<int> values = [];
|
||||||
switch (coin) {
|
switch (coin) {
|
||||||
case Coin.bitcoin:
|
case Coin.bitcoin:
|
||||||
case Coin.bitcoincash:
|
// case Coin.bitcoincash:
|
||||||
|
// case Coin.bitcoincashTestnet:
|
||||||
case Coin.dogecoin:
|
case Coin.dogecoin:
|
||||||
case Coin.firo:
|
case Coin.firo:
|
||||||
case Coin.bitcoinTestNet:
|
case Coin.bitcoinTestNet:
|
||||||
case Coin.dogecoinTestNet:
|
case Coin.dogecoinTestNet:
|
||||||
case Coin.firoTestNet:
|
case Coin.firoTestNet:
|
||||||
case Coin.epicCash:
|
case Coin.epicCash:
|
||||||
case Coin.namecoin:
|
// case Coin.namecoin:
|
||||||
values.addAll([24, 21, 18, 15, 12]);
|
values.addAll([24, 21, 18, 15, 12]);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
@ -64,9 +65,9 @@ abstract class Constants {
|
||||||
case Coin.bitcoinTestNet:
|
case Coin.bitcoinTestNet:
|
||||||
return 600;
|
return 600;
|
||||||
|
|
||||||
case Coin.bitcoincash:
|
// case Coin.bitcoincash:
|
||||||
case Coin.bitcoincashTestnet:
|
// case Coin.bitcoincashTestnet:
|
||||||
return 600;
|
// return 600;
|
||||||
|
|
||||||
case Coin.dogecoin:
|
case Coin.dogecoin:
|
||||||
case Coin.dogecoinTestNet:
|
case Coin.dogecoinTestNet:
|
||||||
|
@ -82,8 +83,8 @@ abstract class Constants {
|
||||||
case Coin.monero:
|
case Coin.monero:
|
||||||
return 120;
|
return 120;
|
||||||
|
|
||||||
case Coin.namecoin:
|
// case Coin.namecoin:
|
||||||
return 600;
|
// return 600;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -13,9 +13,10 @@ abstract class DefaultNodes {
|
||||||
firo,
|
firo,
|
||||||
monero,
|
monero,
|
||||||
epicCash,
|
epicCash,
|
||||||
bitcoincash,
|
// bitcoincash,
|
||||||
namecoin,
|
// namecoin,
|
||||||
bitcoinTestnet,
|
bitcoinTestnet,
|
||||||
|
// bitcoincashTestnet,
|
||||||
dogecoinTestnet,
|
dogecoinTestnet,
|
||||||
firoTestnet,
|
firoTestnet,
|
||||||
];
|
];
|
||||||
|
@ -32,17 +33,17 @@ abstract class DefaultNodes {
|
||||||
isDown: false,
|
isDown: false,
|
||||||
);
|
);
|
||||||
|
|
||||||
static NodeModel get bitcoincash => NodeModel(
|
// static NodeModel get bitcoincash => NodeModel(
|
||||||
host: "bitcoincash.stackwallet.com",
|
// host: "bitcoincash.stackwallet.com",
|
||||||
port: 50002,
|
// port: 50002,
|
||||||
name: defaultName,
|
// name: defaultName,
|
||||||
id: _nodeId(Coin.bitcoincash),
|
// id: _nodeId(Coin.bitcoincash),
|
||||||
useSSL: true,
|
// useSSL: true,
|
||||||
enabled: true,
|
// enabled: true,
|
||||||
coinName: Coin.bitcoincash.name,
|
// coinName: Coin.bitcoincash.name,
|
||||||
isFailover: true,
|
// isFailover: true,
|
||||||
isDown: false,
|
// isDown: false,
|
||||||
);
|
// );
|
||||||
|
|
||||||
static NodeModel get dogecoin => NodeModel(
|
static NodeModel get dogecoin => NodeModel(
|
||||||
host: "dogecoin.stackwallet.com",
|
host: "dogecoin.stackwallet.com",
|
||||||
|
@ -94,17 +95,17 @@ abstract class DefaultNodes {
|
||||||
isDown: false,
|
isDown: false,
|
||||||
);
|
);
|
||||||
|
|
||||||
static NodeModel get namecoin => NodeModel(
|
// static NodeModel get namecoin => NodeModel(
|
||||||
host: "namecoin.stackwallet.com",
|
// host: "namecoin.stackwallet.com",
|
||||||
port: 57002,
|
// port: 57002,
|
||||||
name: defaultName,
|
// name: defaultName,
|
||||||
id: _nodeId(Coin.namecoin),
|
// id: _nodeId(Coin.namecoin),
|
||||||
useSSL: true,
|
// useSSL: true,
|
||||||
enabled: true,
|
// enabled: true,
|
||||||
coinName: Coin.namecoin.name,
|
// coinName: Coin.namecoin.name,
|
||||||
isFailover: true,
|
// isFailover: true,
|
||||||
isDown: false,
|
// isDown: false,
|
||||||
);
|
// );
|
||||||
|
|
||||||
static NodeModel get bitcoinTestnet => NodeModel(
|
static NodeModel get bitcoinTestnet => NodeModel(
|
||||||
host: "electrumx-testnet.cypherstack.com",
|
host: "electrumx-testnet.cypherstack.com",
|
||||||
|
@ -142,25 +143,25 @@ abstract class DefaultNodes {
|
||||||
isDown: false,
|
isDown: false,
|
||||||
);
|
);
|
||||||
|
|
||||||
static NodeModel get bitcoincashTestnet => NodeModel(
|
// static NodeModel get bitcoincashTestnet => NodeModel(
|
||||||
host: "testnet.hsmiths.com",
|
// host: "testnet.hsmiths.com",
|
||||||
port: 53012,
|
// port: 53012,
|
||||||
name: defaultName,
|
// name: defaultName,
|
||||||
id: _nodeId(Coin.bitcoincash),
|
// id: _nodeId(Coin.bitcoincash),
|
||||||
useSSL: true,
|
// useSSL: true,
|
||||||
enabled: true,
|
// enabled: true,
|
||||||
coinName: Coin.bitcoincash.name,
|
// coinName: Coin.bitcoincash.name,
|
||||||
isFailover: true,
|
// isFailover: true,
|
||||||
isDown: false,
|
// isDown: false,
|
||||||
);
|
// );
|
||||||
|
|
||||||
static NodeModel getNodeFor(Coin coin) {
|
static NodeModel getNodeFor(Coin coin) {
|
||||||
switch (coin) {
|
switch (coin) {
|
||||||
case Coin.bitcoin:
|
case Coin.bitcoin:
|
||||||
return bitcoin;
|
return bitcoin;
|
||||||
|
//
|
||||||
case Coin.bitcoincash:
|
// case Coin.bitcoincash:
|
||||||
return bitcoincash;
|
// return bitcoincash;
|
||||||
|
|
||||||
case Coin.dogecoin:
|
case Coin.dogecoin:
|
||||||
return dogecoin;
|
return dogecoin;
|
||||||
|
@ -174,14 +175,14 @@ abstract class DefaultNodes {
|
||||||
case Coin.monero:
|
case Coin.monero:
|
||||||
return monero;
|
return monero;
|
||||||
|
|
||||||
case Coin.namecoin:
|
// case Coin.namecoin:
|
||||||
return namecoin;
|
// return namecoin;
|
||||||
|
|
||||||
case Coin.bitcoinTestNet:
|
case Coin.bitcoinTestNet:
|
||||||
return bitcoinTestnet;
|
return bitcoinTestnet;
|
||||||
|
|
||||||
case Coin.bitcoincashTestnet:
|
// case Coin.bitcoincashTestnet:
|
||||||
return bitcoincashTestnet;
|
// return bitcoincashTestnet;
|
||||||
|
|
||||||
case Coin.firoTestNet:
|
case Coin.firoTestNet:
|
||||||
return firoTestnet;
|
return firoTestnet;
|
||||||
|
|
|
@ -1,44 +1,40 @@
|
||||||
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/namecoin/namecoin_wallet.dart'
|
|
||||||
as nmc;
|
|
||||||
|
|
||||||
enum Coin {
|
enum Coin {
|
||||||
bitcoin,
|
bitcoin,
|
||||||
bitcoincash,
|
// bitcoincash,
|
||||||
dogecoin,
|
dogecoin,
|
||||||
epicCash,
|
epicCash,
|
||||||
firo,
|
firo,
|
||||||
monero,
|
monero,
|
||||||
namecoin,
|
// namecoin,
|
||||||
|
|
||||||
///
|
///
|
||||||
///
|
///
|
||||||
///
|
///
|
||||||
|
|
||||||
bitcoinTestNet,
|
bitcoinTestNet,
|
||||||
bitcoincashTestnet,
|
// bitcoincashTestnet,
|
||||||
dogecoinTestNet,
|
dogecoinTestNet,
|
||||||
firoTestNet,
|
firoTestNet,
|
||||||
}
|
}
|
||||||
|
|
||||||
// remove firotestnet for now
|
// remove firotestnet for now
|
||||||
const int kTestNetCoinCount = 3;
|
const int kTestNetCoinCount = 2;
|
||||||
|
|
||||||
extension CoinExt on Coin {
|
extension CoinExt on Coin {
|
||||||
String get prettyName {
|
String get prettyName {
|
||||||
switch (this) {
|
switch (this) {
|
||||||
case Coin.bitcoin:
|
case Coin.bitcoin:
|
||||||
return "Bitcoin";
|
return "Bitcoin";
|
||||||
case Coin.bitcoincash:
|
// case Coin.bitcoincash:
|
||||||
return "Bitcoin Cash";
|
// return "Bitcoin Cash";
|
||||||
case Coin.dogecoin:
|
case Coin.dogecoin:
|
||||||
return "Dogecoin";
|
return "Dogecoin";
|
||||||
case Coin.epicCash:
|
case Coin.epicCash:
|
||||||
|
@ -47,12 +43,12 @@ extension CoinExt on Coin {
|
||||||
return "Firo";
|
return "Firo";
|
||||||
case Coin.monero:
|
case Coin.monero:
|
||||||
return "Monero";
|
return "Monero";
|
||||||
case Coin.namecoin:
|
// case Coin.namecoin:
|
||||||
return "Namecoin";
|
// return "Namecoin";
|
||||||
case Coin.bitcoinTestNet:
|
case Coin.bitcoinTestNet:
|
||||||
return "tBitcoin";
|
return "tBitcoin";
|
||||||
case Coin.bitcoincashTestnet:
|
// case Coin.bitcoincashTestnet:
|
||||||
return "tBitcoin Cash";
|
// return "tBitcoin Cash";
|
||||||
case Coin.firoTestNet:
|
case Coin.firoTestNet:
|
||||||
return "tFiro";
|
return "tFiro";
|
||||||
case Coin.dogecoinTestNet:
|
case Coin.dogecoinTestNet:
|
||||||
|
@ -64,8 +60,8 @@ extension CoinExt on Coin {
|
||||||
switch (this) {
|
switch (this) {
|
||||||
case Coin.bitcoin:
|
case Coin.bitcoin:
|
||||||
return "BTC";
|
return "BTC";
|
||||||
case Coin.bitcoincash:
|
// case Coin.bitcoincash:
|
||||||
return "BCH";
|
// return "BCH";
|
||||||
case Coin.dogecoin:
|
case Coin.dogecoin:
|
||||||
return "DOGE";
|
return "DOGE";
|
||||||
case Coin.epicCash:
|
case Coin.epicCash:
|
||||||
|
@ -74,12 +70,12 @@ extension CoinExt on Coin {
|
||||||
return "FIRO";
|
return "FIRO";
|
||||||
case Coin.monero:
|
case Coin.monero:
|
||||||
return "XMR";
|
return "XMR";
|
||||||
case Coin.namecoin:
|
// case Coin.namecoin:
|
||||||
return "NMC";
|
// return "NMC";
|
||||||
case Coin.bitcoinTestNet:
|
case Coin.bitcoinTestNet:
|
||||||
return "tBTC";
|
return "tBTC";
|
||||||
case Coin.bitcoincashTestnet:
|
// case Coin.bitcoincashTestnet:
|
||||||
return "tBCH";
|
// return "tBCH";
|
||||||
case Coin.firoTestNet:
|
case Coin.firoTestNet:
|
||||||
return "tFIRO";
|
return "tFIRO";
|
||||||
case Coin.dogecoinTestNet:
|
case Coin.dogecoinTestNet:
|
||||||
|
@ -91,8 +87,8 @@ extension CoinExt on Coin {
|
||||||
switch (this) {
|
switch (this) {
|
||||||
case Coin.bitcoin:
|
case Coin.bitcoin:
|
||||||
return "bitcoin";
|
return "bitcoin";
|
||||||
case Coin.bitcoincash:
|
// case Coin.bitcoincash:
|
||||||
return "bitcoincash";
|
// return "bitcoincash";
|
||||||
case Coin.dogecoin:
|
case Coin.dogecoin:
|
||||||
return "dogecoin";
|
return "dogecoin";
|
||||||
case Coin.epicCash:
|
case Coin.epicCash:
|
||||||
|
@ -102,12 +98,12 @@ extension CoinExt on Coin {
|
||||||
return "firo";
|
return "firo";
|
||||||
case Coin.monero:
|
case Coin.monero:
|
||||||
return "monero";
|
return "monero";
|
||||||
case Coin.namecoin:
|
// case Coin.namecoin:
|
||||||
return "namecoin";
|
// return "namecoin";
|
||||||
case Coin.bitcoinTestNet:
|
case Coin.bitcoinTestNet:
|
||||||
return "bitcoin";
|
return "bitcoin";
|
||||||
case Coin.bitcoincashTestnet:
|
// case Coin.bitcoincashTestnet:
|
||||||
return "bitcoincash";
|
// return "bitcoincash";
|
||||||
case Coin.firoTestNet:
|
case Coin.firoTestNet:
|
||||||
return "firo";
|
return "firo";
|
||||||
case Coin.dogecoinTestNet:
|
case Coin.dogecoinTestNet:
|
||||||
|
@ -118,12 +114,12 @@ extension CoinExt on Coin {
|
||||||
bool get isElectrumXCoin {
|
bool get isElectrumXCoin {
|
||||||
switch (this) {
|
switch (this) {
|
||||||
case Coin.bitcoin:
|
case Coin.bitcoin:
|
||||||
case Coin.bitcoincash:
|
// case Coin.bitcoincash:
|
||||||
case Coin.dogecoin:
|
case Coin.dogecoin:
|
||||||
case Coin.firo:
|
case Coin.firo:
|
||||||
case Coin.namecoin:
|
// case Coin.namecoin:
|
||||||
case Coin.bitcoinTestNet:
|
case Coin.bitcoinTestNet:
|
||||||
case Coin.bitcoincashTestnet:
|
// case Coin.bitcoincashTestnet:
|
||||||
case Coin.firoTestNet:
|
case Coin.firoTestNet:
|
||||||
case Coin.dogecoinTestNet:
|
case Coin.dogecoinTestNet:
|
||||||
return true;
|
return true;
|
||||||
|
@ -140,9 +136,9 @@ extension CoinExt on Coin {
|
||||||
case Coin.bitcoinTestNet:
|
case Coin.bitcoinTestNet:
|
||||||
return btc.MINIMUM_CONFIRMATIONS;
|
return btc.MINIMUM_CONFIRMATIONS;
|
||||||
|
|
||||||
case Coin.bitcoincash:
|
// case Coin.bitcoincash:
|
||||||
case Coin.bitcoincashTestnet:
|
// case Coin.bitcoincashTestnet:
|
||||||
return bch.MINIMUM_CONFIRMATIONS;
|
// return bch.MINIMUM_CONFIRMATIONS;
|
||||||
|
|
||||||
case Coin.firo:
|
case Coin.firo:
|
||||||
case Coin.firoTestNet:
|
case Coin.firoTestNet:
|
||||||
|
@ -157,8 +153,8 @@ extension CoinExt on Coin {
|
||||||
|
|
||||||
case Coin.monero:
|
case Coin.monero:
|
||||||
return xmr.MINIMUM_CONFIRMATIONS;
|
return xmr.MINIMUM_CONFIRMATIONS;
|
||||||
case Coin.namecoin:
|
// case Coin.namecoin:
|
||||||
return nmc.MINIMUM_CONFIRMATIONS;
|
// return nmc.MINIMUM_CONFIRMATIONS;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -168,10 +164,10 @@ Coin coinFromPrettyName(String name) {
|
||||||
case "Bitcoin":
|
case "Bitcoin":
|
||||||
case "bitcoin":
|
case "bitcoin":
|
||||||
return Coin.bitcoin;
|
return Coin.bitcoin;
|
||||||
case "Bitcoincash":
|
// case "Bitcoincash":
|
||||||
case "bitcoincash":
|
// case "bitcoincash":
|
||||||
case "Bitcoin Cash":
|
// case "Bitcoin Cash":
|
||||||
return Coin.bitcoincash;
|
// return Coin.bitcoincash;
|
||||||
case "Dogecoin":
|
case "Dogecoin":
|
||||||
case "dogecoin":
|
case "dogecoin":
|
||||||
return Coin.dogecoin;
|
return Coin.dogecoin;
|
||||||
|
@ -184,18 +180,18 @@ Coin coinFromPrettyName(String name) {
|
||||||
case "Monero":
|
case "Monero":
|
||||||
case "monero":
|
case "monero":
|
||||||
return Coin.monero;
|
return Coin.monero;
|
||||||
case "Namecoin":
|
// case "Namecoin":
|
||||||
case "namecoin":
|
// case "namecoin":
|
||||||
return Coin.namecoin;
|
// return Coin.namecoin;
|
||||||
case "Bitcoin Testnet":
|
case "Bitcoin Testnet":
|
||||||
case "tBitcoin":
|
case "tBitcoin":
|
||||||
case "bitcoinTestNet":
|
case "bitcoinTestNet":
|
||||||
return Coin.bitcoinTestNet;
|
return Coin.bitcoinTestNet;
|
||||||
|
|
||||||
case "Bitcoincash Testnet":
|
// case "Bitcoincash Testnet":
|
||||||
case "tBitcoin Cash":
|
// case "tBitcoin Cash":
|
||||||
case "Bitcoin Cash Testnet":
|
// case "Bitcoin Cash Testnet":
|
||||||
return Coin.bitcoincashTestnet;
|
// return Coin.bitcoincashTestnet;
|
||||||
case "Firo Testnet":
|
case "Firo Testnet":
|
||||||
case "tFiro":
|
case "tFiro":
|
||||||
case "firoTestNet":
|
case "firoTestNet":
|
||||||
|
@ -214,8 +210,8 @@ Coin coinFromTickerCaseInsensitive(String ticker) {
|
||||||
switch (ticker.toLowerCase()) {
|
switch (ticker.toLowerCase()) {
|
||||||
case "btc":
|
case "btc":
|
||||||
return Coin.bitcoin;
|
return Coin.bitcoin;
|
||||||
case "bch":
|
// case "bch":
|
||||||
return Coin.bitcoincash;
|
// return Coin.bitcoincash;
|
||||||
case "doge":
|
case "doge":
|
||||||
return Coin.dogecoin;
|
return Coin.dogecoin;
|
||||||
case "epic":
|
case "epic":
|
||||||
|
@ -224,12 +220,12 @@ Coin coinFromTickerCaseInsensitive(String ticker) {
|
||||||
return Coin.firo;
|
return Coin.firo;
|
||||||
case "xmr":
|
case "xmr":
|
||||||
return Coin.monero;
|
return Coin.monero;
|
||||||
case "nmc":
|
// case "nmc":
|
||||||
return Coin.namecoin;
|
// return Coin.namecoin;
|
||||||
case "tbtc":
|
case "tbtc":
|
||||||
return Coin.bitcoinTestNet;
|
return Coin.bitcoinTestNet;
|
||||||
case "tbch":
|
// case "tbch":
|
||||||
return Coin.bitcoincashTestnet;
|
// return Coin.bitcoincashTestnet;
|
||||||
case "tfiro":
|
case "tfiro":
|
||||||
return Coin.firoTestNet;
|
return Coin.firoTestNet;
|
||||||
case "tdoge":
|
case "tdoge":
|
||||||
|
|
|
@ -190,9 +190,9 @@ class CoinThemeColor {
|
||||||
case Coin.bitcoin:
|
case Coin.bitcoin:
|
||||||
case Coin.bitcoinTestNet:
|
case Coin.bitcoinTestNet:
|
||||||
return bitcoin;
|
return bitcoin;
|
||||||
case Coin.bitcoincash:
|
// case Coin.bitcoincash:
|
||||||
case Coin.bitcoincashTestnet:
|
// case Coin.bitcoincashTestnet:
|
||||||
return bitcoincash;
|
// return bitcoincash;
|
||||||
case Coin.dogecoin:
|
case Coin.dogecoin:
|
||||||
case Coin.dogecoinTestNet:
|
case Coin.dogecoinTestNet:
|
||||||
return dogecoin;
|
return dogecoin;
|
||||||
|
@ -203,8 +203,8 @@ class CoinThemeColor {
|
||||||
return firo;
|
return firo;
|
||||||
case Coin.monero:
|
case Coin.monero:
|
||||||
return monero;
|
return monero;
|
||||||
case Coin.namecoin:
|
// case Coin.namecoin:
|
||||||
return namecoin;
|
// return namecoin;
|
||||||
// case Coin.wownero:
|
// case Coin.wownero:
|
||||||
// return wownero;
|
// return wownero;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1378,9 +1378,9 @@ class StackColors extends ThemeExtension<StackColors> {
|
||||||
case Coin.bitcoin:
|
case Coin.bitcoin:
|
||||||
case Coin.bitcoinTestNet:
|
case Coin.bitcoinTestNet:
|
||||||
return _coin.bitcoin;
|
return _coin.bitcoin;
|
||||||
case Coin.bitcoincash:
|
// case Coin.bitcoincash:
|
||||||
case Coin.bitcoincashTestnet:
|
// case Coin.bitcoincashTestnet:
|
||||||
return _coin.bitcoincash;
|
// return _coin.bitcoincash;
|
||||||
case Coin.dogecoin:
|
case Coin.dogecoin:
|
||||||
case Coin.dogecoinTestNet:
|
case Coin.dogecoinTestNet:
|
||||||
return _coin.dogecoin;
|
return _coin.dogecoin;
|
||||||
|
@ -1391,8 +1391,8 @@ class StackColors extends ThemeExtension<StackColors> {
|
||||||
return _coin.firo;
|
return _coin.firo;
|
||||||
case Coin.monero:
|
case Coin.monero:
|
||||||
return _coin.monero;
|
return _coin.monero;
|
||||||
case Coin.namecoin:
|
// case Coin.namecoin:
|
||||||
return _coin.namecoin;
|
// return _coin.namecoin;
|
||||||
// case Coin.wownero:
|
// case Coin.wownero:
|
||||||
// return wownero;
|
// return wownero;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,120 +1,120 @@
|
||||||
import 'package:flutter/material.dart';
|
// import 'package:flutter/material.dart';
|
||||||
import 'package:stackwallet/models/exchange/change_now/exchange_transaction_status.dart';
|
// import 'package:stackwallet/models/exchange/change_now/exchange_transaction_status.dart';
|
||||||
import 'package:stackwallet/utilities/enums/coin_enum.dart';
|
// import 'package:stackwallet/utilities/enums/coin_enum.dart';
|
||||||
import 'package:stackwallet/utilities/theme/color_theme.dart';
|
// import 'package:stackwallet/utilities/theme/color_theme.dart';
|
||||||
import 'package:stackwallet/utilities/theme/dark_colors.dart';
|
// import 'package:stackwallet/utilities/theme/dark_colors.dart';
|
||||||
import 'package:stackwallet/utilities/theme/light_colors.dart';
|
// import 'package:stackwallet/utilities/theme/light_colors.dart';
|
||||||
|
//
|
||||||
class StackTheme {
|
// class StackTheme {
|
||||||
StackTheme._();
|
// StackTheme._();
|
||||||
static final StackTheme _instance = StackTheme._();
|
// static final StackTheme _instance = StackTheme._();
|
||||||
static StackTheme get instance => _instance;
|
// static StackTheme get instance => _instance;
|
||||||
|
//
|
||||||
late StackColorTheme color;
|
// late StackColorTheme color;
|
||||||
late ThemeType theme;
|
// late ThemeType theme;
|
||||||
|
//
|
||||||
void setTheme(ThemeType theme) {
|
// void setTheme(ThemeType theme) {
|
||||||
this.theme = theme;
|
// this.theme = theme;
|
||||||
switch (theme) {
|
// switch (theme) {
|
||||||
case ThemeType.light:
|
// case ThemeType.light:
|
||||||
color = LightColors();
|
// color = LightColors();
|
||||||
break;
|
// break;
|
||||||
case ThemeType.dark:
|
// case ThemeType.dark:
|
||||||
color = DarkColors();
|
// color = DarkColors();
|
||||||
break;
|
// break;
|
||||||
}
|
// }
|
||||||
}
|
// }
|
||||||
|
//
|
||||||
BoxShadow get standardBoxShadow => BoxShadow(
|
// BoxShadow get standardBoxShadow => BoxShadow(
|
||||||
color: color.shadow,
|
// color: color.shadow,
|
||||||
spreadRadius: 3,
|
// spreadRadius: 3,
|
||||||
blurRadius: 4,
|
// blurRadius: 4,
|
||||||
);
|
// );
|
||||||
|
//
|
||||||
Color colorForCoin(Coin coin) {
|
// Color colorForCoin(Coin coin) {
|
||||||
switch (coin) {
|
// switch (coin) {
|
||||||
case Coin.bitcoin:
|
// case Coin.bitcoin:
|
||||||
case Coin.bitcoinTestNet:
|
// case Coin.bitcoinTestNet:
|
||||||
return _coin.bitcoin;
|
// return _coin.bitcoin;
|
||||||
case Coin.bitcoincash:
|
// case Coin.bitcoincash:
|
||||||
case Coin.bitcoincashTestnet:
|
// case Coin.bitcoincashTestnet:
|
||||||
return _coin.bitcoincash;
|
// return _coin.bitcoincash;
|
||||||
case Coin.dogecoin:
|
// case Coin.dogecoin:
|
||||||
case Coin.dogecoinTestNet:
|
// case Coin.dogecoinTestNet:
|
||||||
return _coin.dogecoin;
|
// return _coin.dogecoin;
|
||||||
case Coin.epicCash:
|
// case Coin.epicCash:
|
||||||
return _coin.epicCash;
|
// return _coin.epicCash;
|
||||||
case Coin.firo:
|
// case Coin.firo:
|
||||||
case Coin.firoTestNet:
|
// case Coin.firoTestNet:
|
||||||
return _coin.firo;
|
// return _coin.firo;
|
||||||
case Coin.monero:
|
// case Coin.monero:
|
||||||
return _coin.monero;
|
// return _coin.monero;
|
||||||
case Coin.namecoin:
|
// case Coin.namecoin:
|
||||||
return _coin.namecoin;
|
// return _coin.namecoin;
|
||||||
// case Coin.wownero:
|
// // case Coin.wownero:
|
||||||
// return wownero;
|
// // return wownero;
|
||||||
}
|
// }
|
||||||
}
|
// }
|
||||||
|
//
|
||||||
Color colorForStatus(ChangeNowTransactionStatus status) {
|
// Color colorForStatus(ChangeNowTransactionStatus status) {
|
||||||
switch (status) {
|
// switch (status) {
|
||||||
case ChangeNowTransactionStatus.New:
|
// case ChangeNowTransactionStatus.New:
|
||||||
case ChangeNowTransactionStatus.Waiting:
|
// case ChangeNowTransactionStatus.Waiting:
|
||||||
case ChangeNowTransactionStatus.Confirming:
|
// case ChangeNowTransactionStatus.Confirming:
|
||||||
case ChangeNowTransactionStatus.Exchanging:
|
// case ChangeNowTransactionStatus.Exchanging:
|
||||||
case ChangeNowTransactionStatus.Sending:
|
// case ChangeNowTransactionStatus.Sending:
|
||||||
case ChangeNowTransactionStatus.Verifying:
|
// case ChangeNowTransactionStatus.Verifying:
|
||||||
return const Color(0xFFD3A90F);
|
// return const Color(0xFFD3A90F);
|
||||||
case ChangeNowTransactionStatus.Finished:
|
// case ChangeNowTransactionStatus.Finished:
|
||||||
return color.accentColorGreen;
|
// return color.accentColorGreen;
|
||||||
case ChangeNowTransactionStatus.Failed:
|
// case ChangeNowTransactionStatus.Failed:
|
||||||
return color.accentColorRed;
|
// return color.accentColorRed;
|
||||||
case ChangeNowTransactionStatus.Refunded:
|
// case ChangeNowTransactionStatus.Refunded:
|
||||||
return color.textSubtitle2;
|
// return color.textSubtitle2;
|
||||||
}
|
// }
|
||||||
}
|
// }
|
||||||
|
//
|
||||||
ButtonStyle? getPrimaryEnabledButtonColor(BuildContext context) =>
|
// ButtonStyle? getPrimaryEnabledButtonColor(BuildContext context) =>
|
||||||
Theme.of(context).textButtonTheme.style?.copyWith(
|
// Theme.of(context).textButtonTheme.style?.copyWith(
|
||||||
backgroundColor: MaterialStateProperty.all<Color>(
|
// backgroundColor: MaterialStateProperty.all<Color>(
|
||||||
color.buttonBackPrimary,
|
// color.buttonBackPrimary,
|
||||||
),
|
// ),
|
||||||
);
|
// );
|
||||||
|
//
|
||||||
ButtonStyle? getPrimaryDisabledButtonColor(BuildContext context) =>
|
// ButtonStyle? getPrimaryDisabledButtonColor(BuildContext context) =>
|
||||||
Theme.of(context).textButtonTheme.style?.copyWith(
|
// Theme.of(context).textButtonTheme.style?.copyWith(
|
||||||
backgroundColor: MaterialStateProperty.all<Color>(
|
// backgroundColor: MaterialStateProperty.all<Color>(
|
||||||
color.buttonBackPrimaryDisabled,
|
// color.buttonBackPrimaryDisabled,
|
||||||
),
|
// ),
|
||||||
);
|
// );
|
||||||
|
//
|
||||||
ButtonStyle? getSecondaryEnabledButtonColor(BuildContext context) =>
|
// ButtonStyle? getSecondaryEnabledButtonColor(BuildContext context) =>
|
||||||
Theme.of(context).textButtonTheme.style?.copyWith(
|
// Theme.of(context).textButtonTheme.style?.copyWith(
|
||||||
backgroundColor: MaterialStateProperty.all<Color>(
|
// backgroundColor: MaterialStateProperty.all<Color>(
|
||||||
color.buttonBackSecondary,
|
// color.buttonBackSecondary,
|
||||||
),
|
// ),
|
||||||
);
|
// );
|
||||||
|
//
|
||||||
ButtonStyle? getSmallSecondaryEnabledButtonColor(BuildContext context) =>
|
// ButtonStyle? getSmallSecondaryEnabledButtonColor(BuildContext context) =>
|
||||||
Theme.of(context).textButtonTheme.style?.copyWith(
|
// Theme.of(context).textButtonTheme.style?.copyWith(
|
||||||
backgroundColor: MaterialStateProperty.all<Color>(
|
// backgroundColor: MaterialStateProperty.all<Color>(
|
||||||
color.textFieldDefaultBG,
|
// color.textFieldDefaultBG,
|
||||||
),
|
// ),
|
||||||
);
|
// );
|
||||||
|
//
|
||||||
ButtonStyle? getDesktopMenuButtonColor(BuildContext context) =>
|
// ButtonStyle? getDesktopMenuButtonColor(BuildContext context) =>
|
||||||
Theme.of(context).textButtonTheme.style?.copyWith(
|
// Theme.of(context).textButtonTheme.style?.copyWith(
|
||||||
backgroundColor: MaterialStateProperty.all<Color>(
|
// backgroundColor: MaterialStateProperty.all<Color>(
|
||||||
color.popupBG,
|
// color.popupBG,
|
||||||
),
|
// ),
|
||||||
);
|
// );
|
||||||
|
//
|
||||||
ButtonStyle? getDesktopMenuButtonColorSelected(BuildContext context) =>
|
// ButtonStyle? getDesktopMenuButtonColorSelected(BuildContext context) =>
|
||||||
Theme.of(context).textButtonTheme.style?.copyWith(
|
// Theme.of(context).textButtonTheme.style?.copyWith(
|
||||||
backgroundColor: MaterialStateProperty.all<Color>(
|
// backgroundColor: MaterialStateProperty.all<Color>(
|
||||||
color.textFieldDefaultBG,
|
// color.textFieldDefaultBG,
|
||||||
),
|
// ),
|
||||||
);
|
// );
|
||||||
|
//
|
||||||
static const _coin = CoinThemeColor();
|
// static const _coin = CoinThemeColor();
|
||||||
}
|
// }
|
||||||
|
|
|
@ -106,9 +106,9 @@ class NodeOptionsSheet extends ConsumerWidget {
|
||||||
case Coin.bitcoinTestNet:
|
case Coin.bitcoinTestNet:
|
||||||
case Coin.firoTestNet:
|
case Coin.firoTestNet:
|
||||||
case Coin.dogecoinTestNet:
|
case Coin.dogecoinTestNet:
|
||||||
case Coin.bitcoincash:
|
// case Coin.bitcoincash:
|
||||||
case Coin.namecoin:
|
// case Coin.namecoin:
|
||||||
case Coin.bitcoincashTestnet:
|
// case Coin.bitcoincashTestnet:
|
||||||
final client = ElectrumX(
|
final client = ElectrumX(
|
||||||
host: node.host,
|
host: node.host,
|
||||||
port: node.port,
|
port: node.port,
|
||||||
|
|
File diff suppressed because it is too large
Load diff
File diff suppressed because it is too large
Load diff
|
@ -1,11 +1,8 @@
|
||||||
import 'package:flutter/material.dart';
|
import 'package:flutter/material.dart';
|
||||||
import 'package:flutter_test/flutter_test.dart';
|
import 'package:flutter_test/flutter_test.dart';
|
||||||
import 'package:stackwallet/utilities/theme/color_theme.dart';
|
|
||||||
import 'package:stackwallet/utilities/theme/stack_theme.dart';
|
|
||||||
import 'package:stackwallet/widgets/custom_buttons/app_bar_icon_button.dart';
|
import 'package:stackwallet/widgets/custom_buttons/app_bar_icon_button.dart';
|
||||||
|
|
||||||
void main() {
|
void main() {
|
||||||
StackTheme.instance.setTheme(ThemeType.light);
|
|
||||||
testWidgets("AppBarIconButton test", (tester) async {
|
testWidgets("AppBarIconButton test", (tester) async {
|
||||||
int buttonPressedCount = 0;
|
int buttonPressedCount = 0;
|
||||||
final button = AppBarIconButton(
|
final button = AppBarIconButton(
|
||||||
|
|
|
@ -1,11 +1,8 @@
|
||||||
import 'package:flutter/material.dart';
|
import 'package:flutter/material.dart';
|
||||||
import 'package:flutter_test/flutter_test.dart';
|
import 'package:flutter_test/flutter_test.dart';
|
||||||
import 'package:stackwallet/utilities/theme/color_theme.dart';
|
|
||||||
import 'package:stackwallet/utilities/theme/stack_theme.dart';
|
|
||||||
import 'package:stackwallet/widgets/custom_buttons/draggable_switch_button.dart';
|
import 'package:stackwallet/widgets/custom_buttons/draggable_switch_button.dart';
|
||||||
|
|
||||||
void main() {
|
void main() {
|
||||||
StackTheme.instance.setTheme(ThemeType.light);
|
|
||||||
testWidgets("DraggableSwitchButton tapped", (tester) async {
|
testWidgets("DraggableSwitchButton tapped", (tester) async {
|
||||||
bool? isButtonOn = false;
|
bool? isButtonOn = false;
|
||||||
final button = DraggableSwitchButton(
|
final button = DraggableSwitchButton(
|
||||||
|
|
|
@ -1,13 +1,10 @@
|
||||||
import 'package:flutter/material.dart';
|
import 'package:flutter/material.dart';
|
||||||
import 'package:flutter_svg/svg.dart';
|
import 'package:flutter_svg/svg.dart';
|
||||||
import 'package:flutter_test/flutter_test.dart';
|
import 'package:flutter_test/flutter_test.dart';
|
||||||
import 'package:stackwallet/utilities/theme/color_theme.dart';
|
|
||||||
import 'package:stackwallet/utilities/theme/stack_theme.dart';
|
|
||||||
import 'package:stackwallet/widgets/custom_pin_put/custom_pin_put.dart';
|
import 'package:stackwallet/widgets/custom_pin_put/custom_pin_put.dart';
|
||||||
import 'package:stackwallet/widgets/custom_pin_put/pin_keyboard.dart';
|
import 'package:stackwallet/widgets/custom_pin_put/pin_keyboard.dart';
|
||||||
|
|
||||||
void main() {
|
void main() {
|
||||||
StackTheme.instance.setTheme(ThemeType.light);
|
|
||||||
group("CustomPinPut tests", () {
|
group("CustomPinPut tests", () {
|
||||||
testWidgets("CustomPinPut with 4 fields builds correctly", (tester) async {
|
testWidgets("CustomPinPut with 4 fields builds correctly", (tester) async {
|
||||||
const pinPut = CustomPinPut(fieldsCount: 4);
|
const pinPut = CustomPinPut(fieldsCount: 4);
|
||||||
|
|
Loading…
Reference in a new issue