Merged btc and 4.1.0 branches.
BIN
assets/images/2.0x/transfer.png
Normal file
After Width: | Height: | Size: 1.1 KiB |
BIN
assets/images/2.0x/upload.png
Normal file
After Width: | Height: | Size: 760 B |
BIN
assets/images/3.0x/transfer.png
Normal file
After Width: | Height: | Size: 1.6 KiB |
BIN
assets/images/3.0x/upload.png
Normal file
After Width: | Height: | Size: 1.1 KiB |
Before Width: | Height: | Size: 408 B After Width: | Height: | Size: 629 B |
Before Width: | Height: | Size: 341 B After Width: | Height: | Size: 440 B |
|
@ -9,7 +9,7 @@ class PreferencesKey {
|
|||
static const shouldSaveRecipientAddressKey = 'save_recipient_address';
|
||||
static const allowBiometricalAuthenticationKey =
|
||||
'allow_biometrical_authentication';
|
||||
static const currentDarkTheme = 'dark_theme';
|
||||
static const currentTheme = 'current_theme';
|
||||
static const displayActionListModeKey = 'display_list_mode';
|
||||
static const currentPinLength = 'current_pin_length';
|
||||
static const currentLanguageCode = 'language_code';
|
||||
|
|
|
@ -44,6 +44,7 @@ class S implements WidgetsLocalizations {
|
|||
String get authentication => "Authentication";
|
||||
String get available_balance => "Available Balance";
|
||||
String get biometric_auth_reason => "Scan your fingerprint to authenticate";
|
||||
String get bright_theme => "Bright";
|
||||
String get buy => "Buy";
|
||||
String get cake_wallet => "Cake Wallet";
|
||||
String get cancel => "Cancel";
|
||||
|
@ -57,6 +58,7 @@ class S implements WidgetsLocalizations {
|
|||
String get choose_account => "Choose account";
|
||||
String get choose_wallet_currency => "Please choose wallet currency:";
|
||||
String get clear => "Clear";
|
||||
String get color_theme => "Color theme";
|
||||
String get confirm => "Confirm";
|
||||
String get confirm_delete_template => "This action will delete this template. Do you wish to continue?";
|
||||
String get confirm_delete_wallet => "This action will delete this wallet. Do you wish to continue?";
|
||||
|
@ -71,6 +73,7 @@ class S implements WidgetsLocalizations {
|
|||
String get create_new => "Create New Wallet";
|
||||
String get create_new_account => "Create new account";
|
||||
String get creating_new_wallet => "Creating new wallet";
|
||||
String get dark_theme => "Dark";
|
||||
String get delete => "Delete";
|
||||
String get digit_pin => "-digit PIN";
|
||||
String get edit => "Edit";
|
||||
|
@ -107,6 +110,7 @@ class S implements WidgetsLocalizations {
|
|||
String get id => "ID: ";
|
||||
String get incoming => "Incoming";
|
||||
String get incorrect_seed => "The text entered is not valid.";
|
||||
String get light_theme => "Light";
|
||||
String get loading_your_wallet => "Loading your wallet";
|
||||
String get login => "Login";
|
||||
String get new_node_testing => "New node testing";
|
||||
|
@ -394,6 +398,8 @@ class $de extends S {
|
|||
@override
|
||||
String get biometric_auth_reason => "Scannen Sie Ihren Fingerabdruck zur Authentifizierung";
|
||||
@override
|
||||
String get dark_theme => "Dunkel";
|
||||
@override
|
||||
String get transaction_sent => "Transaktion gesendet!";
|
||||
@override
|
||||
String get send_fee => "Gebühr";
|
||||
|
@ -646,6 +652,8 @@ class $de extends S {
|
|||
@override
|
||||
String get filters => "Filter";
|
||||
@override
|
||||
String get color_theme => "Farbthema";
|
||||
@override
|
||||
String get settings_current_node => "Aktueller Knoten";
|
||||
@override
|
||||
String get copy_id => "ID kopieren";
|
||||
|
@ -886,12 +894,16 @@ class $de extends S {
|
|||
@override
|
||||
String get trade_state_confirming => "Bestätigung";
|
||||
@override
|
||||
String get bright_theme => "Hell";
|
||||
@override
|
||||
String get send => "Senden";
|
||||
@override
|
||||
String get send_title => "Senden Sie";
|
||||
@override
|
||||
String get error_text_keys => "Walletschlüssel können nur 64 hexadezimale Zeichen enthalten";
|
||||
@override
|
||||
String get light_theme => "Licht";
|
||||
@override
|
||||
String get settings_save_recipient_address => "Empfängeradresse speichern";
|
||||
@override
|
||||
String get change_exchange_provider => "Wechseln Sie den Exchange-Anbieter";
|
||||
|
@ -1086,6 +1098,8 @@ class $hi extends S {
|
|||
@override
|
||||
String get biometric_auth_reason => "प्रमाणित करने के लिए अपने फ़िंगरप्रिंट को स्कैन करें";
|
||||
@override
|
||||
String get dark_theme => "अंधेरा";
|
||||
@override
|
||||
String get transaction_sent => "भेजा गया लेन-देन";
|
||||
@override
|
||||
String get send_fee => "शुल्क:";
|
||||
|
@ -1338,6 +1352,8 @@ class $hi extends S {
|
|||
@override
|
||||
String get filters => "फ़िल्टर";
|
||||
@override
|
||||
String get color_theme => "रंग विषय";
|
||||
@override
|
||||
String get settings_current_node => "वर्तमान नोड";
|
||||
@override
|
||||
String get copy_id => "प्रतिलिपि ID";
|
||||
|
@ -1578,12 +1594,16 @@ class $hi extends S {
|
|||
@override
|
||||
String get trade_state_confirming => "पुष्टि";
|
||||
@override
|
||||
String get bright_theme => "उज्ज्वल";
|
||||
@override
|
||||
String get send => "संदेश";
|
||||
@override
|
||||
String get send_title => "संदेश";
|
||||
@override
|
||||
String get error_text_keys => "वॉलेट कीज़ में हेक्स में केवल 64 वर्ण हो सकते हैं";
|
||||
@override
|
||||
String get light_theme => "रोशनी";
|
||||
@override
|
||||
String get settings_save_recipient_address => "प्राप्तकर्ता का पता सहेजें";
|
||||
@override
|
||||
String get change_exchange_provider => "एक्सचेंज प्रदाता बदलें";
|
||||
|
@ -1778,6 +1798,8 @@ class $ru extends S {
|
|||
@override
|
||||
String get biometric_auth_reason => "Отсканируйте свой отпечаток пальца для аутентификации";
|
||||
@override
|
||||
String get dark_theme => "Темная";
|
||||
@override
|
||||
String get transaction_sent => "Tранзакция отправлена!";
|
||||
@override
|
||||
String get send_fee => "Комиссия";
|
||||
|
@ -2030,6 +2052,8 @@ class $ru extends S {
|
|||
@override
|
||||
String get filters => "Фильтр";
|
||||
@override
|
||||
String get color_theme => "Цветовая тема";
|
||||
@override
|
||||
String get settings_current_node => "Текущая нода";
|
||||
@override
|
||||
String get copy_id => "Скопировать ID";
|
||||
|
@ -2270,12 +2294,16 @@ class $ru extends S {
|
|||
@override
|
||||
String get trade_state_confirming => "Подтверждение";
|
||||
@override
|
||||
String get bright_theme => "Яркая";
|
||||
@override
|
||||
String get send => "Отправить";
|
||||
@override
|
||||
String get send_title => "Отправить";
|
||||
@override
|
||||
String get error_text_keys => "Ключи кошелька могут содержать только 64 символа в hex";
|
||||
@override
|
||||
String get light_theme => "Светлая";
|
||||
@override
|
||||
String get settings_save_recipient_address => "Сохранять адрес получателя";
|
||||
@override
|
||||
String get change_exchange_provider => "Изменить провайдера обмена";
|
||||
|
@ -2470,6 +2498,8 @@ class $ko extends S {
|
|||
@override
|
||||
String get biometric_auth_reason => "지문을 스캔하여 인증";
|
||||
@override
|
||||
String get dark_theme => "어두운";
|
||||
@override
|
||||
String get transaction_sent => "거래가 전송되었습니다!";
|
||||
@override
|
||||
String get send_fee => "회비";
|
||||
|
@ -2722,6 +2752,8 @@ class $ko extends S {
|
|||
@override
|
||||
String get filters => "필터";
|
||||
@override
|
||||
String get color_theme => "색상 테마";
|
||||
@override
|
||||
String get settings_current_node => "현재 노드";
|
||||
@override
|
||||
String get copy_id => "부 ID";
|
||||
|
@ -2962,12 +2994,16 @@ class $ko extends S {
|
|||
@override
|
||||
String get trade_state_confirming => "확인 중";
|
||||
@override
|
||||
String get bright_theme => "선명한";
|
||||
@override
|
||||
String get send => "보내다";
|
||||
@override
|
||||
String get send_title => "보내다";
|
||||
@override
|
||||
String get error_text_keys => "지갑 키는 16 진수로 64 자만 포함 할 수 있습니다";
|
||||
@override
|
||||
String get light_theme => "빛";
|
||||
@override
|
||||
String get settings_save_recipient_address => "수신자 주소 저장";
|
||||
@override
|
||||
String get change_exchange_provider => "교환 공급자 변경";
|
||||
|
@ -3162,6 +3198,8 @@ class $pt extends S {
|
|||
@override
|
||||
String get biometric_auth_reason => "Digitalize sua impressão digital para autenticar";
|
||||
@override
|
||||
String get dark_theme => "Sombria";
|
||||
@override
|
||||
String get transaction_sent => "Transação enviada!";
|
||||
@override
|
||||
String get send_fee => "Taxa";
|
||||
|
@ -3414,6 +3452,8 @@ class $pt extends S {
|
|||
@override
|
||||
String get filters => "Filtro";
|
||||
@override
|
||||
String get color_theme => "Tema de cor";
|
||||
@override
|
||||
String get settings_current_node => "Nó atual";
|
||||
@override
|
||||
String get copy_id => "Copiar ID";
|
||||
|
@ -3654,12 +3694,16 @@ class $pt extends S {
|
|||
@override
|
||||
String get trade_state_confirming => "Confirmando";
|
||||
@override
|
||||
String get bright_theme => "Brilhante";
|
||||
@override
|
||||
String get send => "Enviar";
|
||||
@override
|
||||
String get send_title => "Enviar";
|
||||
@override
|
||||
String get error_text_keys => "As chaves da carteira podem conter apenas 64 caracteres em hexadecimal";
|
||||
@override
|
||||
String get light_theme => "Luz";
|
||||
@override
|
||||
String get settings_save_recipient_address => "Salvar endereço do destinatário";
|
||||
@override
|
||||
String get change_exchange_provider => "Alterar o provedor de troca";
|
||||
|
@ -3854,6 +3898,8 @@ class $uk extends S {
|
|||
@override
|
||||
String get biometric_auth_reason => "Відскануйте свій відбиток пальця для аутентифікації";
|
||||
@override
|
||||
String get dark_theme => "Темна";
|
||||
@override
|
||||
String get transaction_sent => "Tранзакцію відправлено!";
|
||||
@override
|
||||
String get send_fee => "Комісія";
|
||||
|
@ -4106,6 +4152,8 @@ class $uk extends S {
|
|||
@override
|
||||
String get filters => "Фільтр";
|
||||
@override
|
||||
String get color_theme => "Кольорова тема";
|
||||
@override
|
||||
String get settings_current_node => "Поточний вузол";
|
||||
@override
|
||||
String get copy_id => "Скопіювати ID";
|
||||
|
@ -4346,12 +4394,16 @@ class $uk extends S {
|
|||
@override
|
||||
String get trade_state_confirming => "Підтвердження";
|
||||
@override
|
||||
String get bright_theme => "Яскрава";
|
||||
@override
|
||||
String get send => "Відправити";
|
||||
@override
|
||||
String get send_title => "Відправити";
|
||||
@override
|
||||
String get error_text_keys => "Ключі гаманця можуть містити тільки 64 символів в hex";
|
||||
@override
|
||||
String get light_theme => "Світла";
|
||||
@override
|
||||
String get settings_save_recipient_address => "Зберігати адресу отримувача";
|
||||
@override
|
||||
String get change_exchange_provider => "Змінити провайдера обміну";
|
||||
|
@ -4546,6 +4598,8 @@ class $ja extends S {
|
|||
@override
|
||||
String get biometric_auth_reason => "प指紋をスキャンして認証する";
|
||||
@override
|
||||
String get dark_theme => "闇";
|
||||
@override
|
||||
String get transaction_sent => "トランザクションが送信されました!";
|
||||
@override
|
||||
String get send_fee => "費用";
|
||||
|
@ -4798,6 +4852,8 @@ class $ja extends S {
|
|||
@override
|
||||
String get filters => "フィルタ";
|
||||
@override
|
||||
String get color_theme => "カラーテーマ";
|
||||
@override
|
||||
String get settings_current_node => "現在のノード";
|
||||
@override
|
||||
String get copy_id => "IDをコピー";
|
||||
|
@ -5038,12 +5094,16 @@ class $ja extends S {
|
|||
@override
|
||||
String get trade_state_confirming => "確認中";
|
||||
@override
|
||||
String get bright_theme => "明るい";
|
||||
@override
|
||||
String get send => "送る";
|
||||
@override
|
||||
String get send_title => "を送信";
|
||||
@override
|
||||
String get error_text_keys => "ウォレットキーには、16進数で64文字しか含めることができません";
|
||||
@override
|
||||
String get light_theme => "光";
|
||||
@override
|
||||
String get settings_save_recipient_address => "受信者のアドレスを保存";
|
||||
@override
|
||||
String get change_exchange_provider => "Exchangeプロバイダーの変更";
|
||||
|
@ -5242,6 +5302,8 @@ class $pl extends S {
|
|||
@override
|
||||
String get biometric_auth_reason => "Zeskanuj swój odcisk palca, aby go uwierzytelnić";
|
||||
@override
|
||||
String get dark_theme => "Ciemny";
|
||||
@override
|
||||
String get transaction_sent => "Transakcja wysłana!";
|
||||
@override
|
||||
String get send_fee => "Opłata";
|
||||
|
@ -5494,6 +5556,8 @@ class $pl extends S {
|
|||
@override
|
||||
String get filters => "Filtr";
|
||||
@override
|
||||
String get color_theme => "Motyw kolorystyczny";
|
||||
@override
|
||||
String get settings_current_node => "Bieżący węzeł";
|
||||
@override
|
||||
String get copy_id => "ID kopii";
|
||||
|
@ -5734,12 +5798,16 @@ class $pl extends S {
|
|||
@override
|
||||
String get trade_state_confirming => "Potwierdzam";
|
||||
@override
|
||||
String get bright_theme => "Jasny";
|
||||
@override
|
||||
String get send => "Wysłać";
|
||||
@override
|
||||
String get send_title => "Wyślij";
|
||||
@override
|
||||
String get error_text_keys => "Klucze portfela mogą zawierać tylko 64 znaki w systemie szesnastkowym";
|
||||
@override
|
||||
String get light_theme => "Lekki";
|
||||
@override
|
||||
String get settings_save_recipient_address => "Zapisz adres odbiorcy";
|
||||
@override
|
||||
String get change_exchange_provider => "Zmień dostawcę programu Exchange";
|
||||
|
@ -5934,6 +6002,8 @@ class $es extends S {
|
|||
@override
|
||||
String get biometric_auth_reason => "Escanee su huella digital para autenticar";
|
||||
@override
|
||||
String get dark_theme => "Oscura";
|
||||
@override
|
||||
String get transaction_sent => "Transacción enviada!";
|
||||
@override
|
||||
String get send_fee => "Cuota";
|
||||
|
@ -6186,6 +6256,8 @@ class $es extends S {
|
|||
@override
|
||||
String get filters => "Filtrar";
|
||||
@override
|
||||
String get color_theme => "Tema de color";
|
||||
@override
|
||||
String get settings_current_node => "Nodo actual";
|
||||
@override
|
||||
String get copy_id => "Copiar ID";
|
||||
|
@ -6426,12 +6498,16 @@ class $es extends S {
|
|||
@override
|
||||
String get trade_state_confirming => "Confirmando";
|
||||
@override
|
||||
String get bright_theme => "Brillante";
|
||||
@override
|
||||
String get send => "Enviar";
|
||||
@override
|
||||
String get send_title => "Enviar";
|
||||
@override
|
||||
String get error_text_keys => "Las llaves de billetera solo pueden contener 64 caracteres en hexadecimal";
|
||||
@override
|
||||
String get light_theme => "Ligera";
|
||||
@override
|
||||
String get settings_save_recipient_address => "Guardar dirección del destinatario";
|
||||
@override
|
||||
String get change_exchange_provider => "Cambiar proveedor de intercambio";
|
||||
|
@ -6626,6 +6702,8 @@ class $nl extends S {
|
|||
@override
|
||||
String get biometric_auth_reason => "Scan uw vingerafdruk om te verifiëren";
|
||||
@override
|
||||
String get dark_theme => "Donker";
|
||||
@override
|
||||
String get transaction_sent => "Transactie verzonden!";
|
||||
@override
|
||||
String get send_fee => "Vergoeding";
|
||||
|
@ -6878,6 +6956,8 @@ class $nl extends S {
|
|||
@override
|
||||
String get filters => "Filter";
|
||||
@override
|
||||
String get color_theme => "Kleur thema";
|
||||
@override
|
||||
String get settings_current_node => "Huidige knooppunt";
|
||||
@override
|
||||
String get copy_id => "ID kopiëren";
|
||||
|
@ -7118,12 +7198,16 @@ class $nl extends S {
|
|||
@override
|
||||
String get trade_state_confirming => "Bevestiging";
|
||||
@override
|
||||
String get bright_theme => "Helder";
|
||||
@override
|
||||
String get send => "Sturen";
|
||||
@override
|
||||
String get send_title => "Stuur";
|
||||
@override
|
||||
String get error_text_keys => "Portefeuillesleutels kunnen maximaal 64 tekens bevatten in hexadecimale volgorde";
|
||||
@override
|
||||
String get light_theme => "Licht";
|
||||
@override
|
||||
String get settings_save_recipient_address => "Adres ontvanger opslaan";
|
||||
@override
|
||||
String get change_exchange_provider => "Wijzig Exchange Provider";
|
||||
|
@ -7318,6 +7402,8 @@ class $zh extends S {
|
|||
@override
|
||||
String get biometric_auth_reason => "掃描指紋以進行身份驗證";
|
||||
@override
|
||||
String get dark_theme => "黑暗";
|
||||
@override
|
||||
String get transaction_sent => "交易已发送";
|
||||
@override
|
||||
String get send_fee => "費用";
|
||||
|
@ -7570,6 +7656,8 @@ class $zh extends S {
|
|||
@override
|
||||
String get filters => "過濾";
|
||||
@override
|
||||
String get color_theme => "顏色主題";
|
||||
@override
|
||||
String get settings_current_node => "当前节点";
|
||||
@override
|
||||
String get copy_id => "复印ID";
|
||||
|
@ -7810,12 +7898,16 @@ class $zh extends S {
|
|||
@override
|
||||
String get trade_state_confirming => "确认中";
|
||||
@override
|
||||
String get bright_theme => "亮";
|
||||
@override
|
||||
String get send => "发送";
|
||||
@override
|
||||
String get send_title => "發送";
|
||||
@override
|
||||
String get error_text_keys => "钱包密钥只能包含16个字符的十六进制字符";
|
||||
@override
|
||||
String get light_theme => "光";
|
||||
@override
|
||||
String get settings_save_recipient_address => "保存收件人地址";
|
||||
@override
|
||||
String get change_exchange_provider => "更改交易所提供商";
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
import 'package:cake_wallet/themes/theme_base.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter/services.dart';
|
||||
import 'package:hive/hive.dart';
|
||||
|
@ -122,27 +123,25 @@ class App extends StatelessWidget {
|
|||
@override
|
||||
Widget build(BuildContext context) {
|
||||
final settingsStore = getIt.get<AppStore>().settingsStore;
|
||||
|
||||
if (settingsStore.theme == null) {
|
||||
settingsStore.isDarkTheme = false;
|
||||
}
|
||||
|
||||
final statusBarColor = Colors.transparent;
|
||||
final statusBarBrightness =
|
||||
settingsStore.isDarkTheme ? Brightness.light : Brightness.dark;
|
||||
final statusBarIconBrightness =
|
||||
settingsStore.isDarkTheme ? Brightness.light : Brightness.dark;
|
||||
final authenticationStore = getIt.get<AuthenticationStore>();
|
||||
final initialRoute = authenticationStore.state == AuthenticationState.denied
|
||||
? Routes.disclaimer
|
||||
: Routes.login;
|
||||
|
||||
return Observer(builder: (BuildContext context) {
|
||||
final currentTheme = settingsStore.currentTheme;
|
||||
final statusBarBrightness = currentTheme.type == ThemeType.dark
|
||||
? Brightness.light
|
||||
: Brightness.dark;
|
||||
final statusBarIconBrightness = currentTheme.type == ThemeType.dark
|
||||
? Brightness.light
|
||||
: Brightness.dark;
|
||||
SystemChrome.setSystemUIOverlayStyle(SystemUiOverlayStyle(
|
||||
statusBarColor: statusBarColor,
|
||||
statusBarBrightness: statusBarBrightness,
|
||||
statusBarIconBrightness: statusBarIconBrightness));
|
||||
|
||||
return Observer(builder: (BuildContext context) {
|
||||
return Root(
|
||||
authenticationStore: authenticationStore,
|
||||
navigatorKey: navigatorKey,
|
||||
|
|
|
@ -4,7 +4,7 @@ class Palette {
|
|||
static const Color green = Color.fromRGBO(39, 206, 80, 1.0);
|
||||
static const Color red = Color.fromRGBO(255, 51, 51, 1.0);
|
||||
static const Color darkRed = Color.fromRGBO(204, 38, 38, 1.0);
|
||||
static const Color blueAlice = Color.fromRGBO(231, 240, 253, 1.0);
|
||||
static const Color blueAlice = Color.fromRGBO(229, 247, 255, 1.0);
|
||||
static const Color lightBlue = Color.fromRGBO(172, 203, 238, 1.0);
|
||||
static const Color lavender = Color.fromRGBO(237, 245, 252, 1.0);
|
||||
static const Color oceanBlue = Color.fromRGBO(30, 52, 78, 1.0);
|
||||
|
@ -13,7 +13,6 @@ class Palette {
|
|||
static const Color blue = Color.fromRGBO(88, 143, 252, 1.0);
|
||||
static const Color darkLavender = Color.fromRGBO(229, 238, 250, 1.0);
|
||||
static const Color nightBlue = Color.fromRGBO(46, 57, 96, 1.0);
|
||||
|
||||
static const Color moderateOrangeYellow = Color.fromRGBO(245, 134, 82, 1.0);
|
||||
static const Color moderateOrange = Color.fromRGBO(235, 117, 63, 1.0);
|
||||
static const Color shineGreen = Color.fromRGBO(76, 189, 87, 1.0);
|
||||
|
@ -22,9 +21,8 @@ class Palette {
|
|||
static const Color royalBlue = Color.fromRGBO(43, 114, 221, 1.0);
|
||||
static const Color lightRed = Color.fromRGBO(227, 87, 87, 1.0);
|
||||
static const Color persianRed = Color.fromRGBO(206, 55, 55, 1.0);
|
||||
|
||||
// NEW DESIGN
|
||||
static const Color blueCraiola = Color.fromRGBO(69, 110, 255, 1.0);
|
||||
static const Color blueGreyCraiola = Color.fromRGBO(106, 177, 207, 1.0);
|
||||
static const Color darkBlueCraiola = Color.fromRGBO(53, 86, 136, 1.0);
|
||||
static const Color pinkFlamingo = Color.fromRGBO(240, 60, 243, 1.0);
|
||||
static const Color redHat = Color.fromRGBO(209, 68, 37, 1.0);
|
||||
|
@ -43,26 +41,17 @@ class Palette {
|
|||
static const Color alizarinRed = Color.fromRGBO(233, 45, 45, 1.0);
|
||||
static const Color moderateSlateBlue = Color.fromRGBO(129, 93, 251, 1.0);
|
||||
static const Color brightOrange = Color.fromRGBO(255, 102, 0, 1.0);
|
||||
|
||||
// FIXME: Rename.
|
||||
static const Color eee = Color.fromRGBO(236, 239, 245, 1.0);
|
||||
static const Color xxx = Color.fromRGBO(72, 89, 109, 1);
|
||||
static const Color dullGray = Color.fromRGBO(98, 98, 98, 1.0);
|
||||
static const Color protectiveBlue = Color.fromRGBO(33, 148, 255, 1.0);
|
||||
}
|
||||
|
||||
class PaletteDark {
|
||||
//static const Color distantBlue = Color.fromRGBO(70, 85, 133, 1.0); // mainBackgroundColor
|
||||
static const Color lightDistantBlue = Color.fromRGBO(81, 96, 147, 1.0); // borderCardColor
|
||||
static const Color gray = Color.fromRGBO(140, 153, 201, 1.0); // walletCardText
|
||||
//static const Color violetBlue = Color.fromRGBO(51, 63, 104, 1.0); // walletCardAddressField
|
||||
//static const Color moderateBlue = Color.fromRGBO(63, 77, 122, 1.0); // walletCardSubAddressField
|
||||
//static const Color darkNightBlue = Color.fromRGBO(33, 43, 73, 1.0); // historyPanel
|
||||
static const Color pigeonBlue = Color.fromRGBO(91, 112, 146, 1.0); // historyPanelText
|
||||
static const Color moderateNightBlue = Color.fromRGBO(39, 53, 96, 1.0); // historyPanelButton
|
||||
static const Color headerNightBlue = Color.fromRGBO(41, 52, 84, 1.0); // menuHeader
|
||||
//static const Color lightNightBlue = Color.fromRGBO(48, 59, 95, 1.0); // menuList
|
||||
static const Color moderatePurpleBlue = Color.fromRGBO(57, 74, 95, 1.0); // selectButtonText
|
||||
|
||||
// NEW DESIGN
|
||||
static const Color lightDistantBlue = Color.fromRGBO(81, 96, 147, 1.0);
|
||||
static const Color gray = Color.fromRGBO(140, 153, 201, 1.0);
|
||||
static const Color pigeonBlue = Color.fromRGBO(91, 112, 146, 1.0);
|
||||
static const Color moderateNightBlue = Color.fromRGBO(39, 53, 96, 1.0);
|
||||
static const Color headerNightBlue = Color.fromRGBO(41, 52, 84, 1.0);
|
||||
static const Color moderatePurpleBlue = Color.fromRGBO(57, 74, 95, 1.0);
|
||||
static const Color backgroundColor = Color.fromRGBO(25, 35, 60, 1.0);
|
||||
static const Color nightBlue = Color.fromRGBO(35, 47, 79, 1.0);
|
||||
static const Color wildNightBlue = Color.fromRGBO(39, 53, 96, 1.0);
|
||||
|
@ -94,8 +83,5 @@ class PaletteDark {
|
|||
static const Color deepVioletBlue = Color.fromRGBO(52, 66, 104, 1.0);
|
||||
static const Color lightPurpleBlue = Color.fromRGBO(120, 133, 170, 1.0);
|
||||
static const Color indicatorVioletBlue = Color.fromRGBO(59, 72, 119, 1.0);
|
||||
|
||||
// FIXME: Rename.
|
||||
static const Color eee = Color.fromRGBO(236, 239, 245, 1.0);
|
||||
static const Color xxx = Color.fromRGBO(72, 89, 109, 1);
|
||||
static const Color granite = Color.fromRGBO(48, 51, 60, 1.0);
|
||||
}
|
|
@ -1,3 +1,4 @@
|
|||
import 'package:cake_wallet/themes/theme_base.dart';
|
||||
import 'package:flutter/cupertino.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:cake_wallet/palette.dart';
|
||||
|
@ -9,13 +10,13 @@ enum AppBarStyle { regular, withShadow, transparent }
|
|||
|
||||
abstract class BasePage extends StatelessWidget {
|
||||
BasePage()
|
||||
: _scaffoldKey = GlobalKey<ScaffoldState>(),
|
||||
_closeButtonImage = Image.asset('assets/images/close_button.png'),
|
||||
_closeButtonImageDarkTheme =
|
||||
Image.asset('assets/images/close_button_dark_theme.png');
|
||||
: _scaffoldKey = GlobalKey<ScaffoldState>();
|
||||
final GlobalKey<ScaffoldState> _scaffoldKey;
|
||||
final Image _closeButtonImage;
|
||||
final Image _closeButtonImageDarkTheme;
|
||||
|
||||
final Image closeButtonImage =
|
||||
Image.asset('assets/images/close_button.png');
|
||||
final Image closeButtonImageDarkTheme =
|
||||
Image.asset('assets/images/close_button_dark_theme.png');
|
||||
|
||||
String get title => null;
|
||||
|
||||
|
@ -37,7 +38,7 @@ abstract class BasePage extends StatelessWidget {
|
|||
|
||||
Widget Function(BuildContext, Widget) get rootWrapper => null;
|
||||
|
||||
bool get isDarkTheme => getIt.get<SettingsStore>().isDarkTheme;
|
||||
ThemeBase get currentTheme => getIt.get<SettingsStore>().currentTheme;
|
||||
|
||||
void onOpenEndDrawer() => _scaffoldKey.currentState.openEndDrawer();
|
||||
|
||||
|
@ -51,8 +52,8 @@ abstract class BasePage extends StatelessWidget {
|
|||
final _backButton = Icon(Icons.arrow_back_ios,
|
||||
color: titleColor ?? Theme.of(context).primaryTextTheme.title.color,
|
||||
size: 16,);
|
||||
final _closeButton =
|
||||
isDarkTheme ? _closeButtonImageDarkTheme : _closeButtonImage;
|
||||
final _closeButton = currentTheme.type == ThemeType.dark
|
||||
? closeButtonImageDarkTheme : closeButtonImage;
|
||||
|
||||
return SizedBox(
|
||||
height: 37,
|
||||
|
@ -88,8 +89,8 @@ abstract class BasePage extends StatelessWidget {
|
|||
Widget floatingActionButton(BuildContext context) => null;
|
||||
|
||||
ObstructingPreferredSizeWidget appBar(BuildContext context) {
|
||||
final appBarColor =
|
||||
isDarkTheme ? backgroundDarkColor : backgroundLightColor;
|
||||
final appBarColor = currentTheme.type == ThemeType.dark
|
||||
? backgroundDarkColor : backgroundLightColor;
|
||||
|
||||
switch (appBarStyle) {
|
||||
case AppBarStyle.regular:
|
||||
|
@ -131,10 +132,12 @@ abstract class BasePage extends StatelessWidget {
|
|||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
final _backgroundColor = currentTheme.type == ThemeType.dark
|
||||
? backgroundDarkColor : backgroundLightColor;
|
||||
|
||||
final root = Scaffold(
|
||||
key: _scaffoldKey,
|
||||
backgroundColor:
|
||||
isDarkTheme ? backgroundDarkColor : backgroundLightColor,
|
||||
backgroundColor: _backgroundColor,
|
||||
resizeToAvoidBottomPadding: resizeToAvoidBottomPadding,
|
||||
extendBodyBehindAppBar: extendBodyBehindAppBar,
|
||||
endDrawer: endDrawer,
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
import 'package:cake_wallet/generated/i18n.dart';
|
||||
import 'package:cake_wallet/routes.dart';
|
||||
import 'package:cake_wallet/themes/theme_base.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter/cupertino.dart';
|
||||
import 'package:cake_wallet/view_model/dashboard/dashboard_view_model.dart';
|
||||
|
@ -20,7 +21,8 @@ class DashboardPage extends BasePage {
|
|||
});
|
||||
|
||||
@override
|
||||
Color get backgroundLightColor => Colors.transparent;
|
||||
Color get backgroundLightColor => currentTheme.type == ThemeType.bright
|
||||
? Colors.transparent : Colors.white;
|
||||
|
||||
@override
|
||||
Color get backgroundDarkColor => Colors.transparent;
|
||||
|
@ -50,7 +52,8 @@ class DashboardPage extends BasePage {
|
|||
@override
|
||||
Widget trailing(BuildContext context) {
|
||||
final menuButton =
|
||||
Image.asset('assets/images/menu.png', color: Colors.white);
|
||||
Image.asset('assets/images/menu.png',
|
||||
color: Theme.of(context).accentTextTheme.display3.backgroundColor);
|
||||
|
||||
return Container(
|
||||
alignment: Alignment.centerRight,
|
||||
|
@ -65,12 +68,6 @@ class DashboardPage extends BasePage {
|
|||
|
||||
final DashboardViewModel walletViewModel;
|
||||
final WalletAddressListViewModel addressListViewModel;
|
||||
final sendImage = Image.asset('assets/images/upload.png',
|
||||
height: 22.24, width: 24, color: Colors.white);
|
||||
final exchangeImage = Image.asset('assets/images/transfer.png',
|
||||
height: 24.27, width: 22.25, color: Colors.white);
|
||||
final receiveImage = Image.asset('assets/images/download.png',
|
||||
height: 22.24, width: 24, color: Colors.white);
|
||||
final controller = PageController(initialPage: 1);
|
||||
|
||||
var pages = <Widget>[];
|
||||
|
@ -78,6 +75,15 @@ class DashboardPage extends BasePage {
|
|||
|
||||
@override
|
||||
Widget body(BuildContext context) {
|
||||
final sendImage = Image.asset('assets/images/upload.png',
|
||||
height: 22.24, width: 24,
|
||||
color: Theme.of(context).accentTextTheme.display3.backgroundColor);
|
||||
final exchangeImage = Image.asset('assets/images/transfer.png',
|
||||
height: 24.27, width: 22.25,
|
||||
color: Theme.of(context).accentTextTheme.display3.backgroundColor);
|
||||
final receiveImage = Image.asset('assets/images/download.png',
|
||||
height: 22.24, width: 24,
|
||||
color: Theme.of(context).accentTextTheme.display3.backgroundColor);
|
||||
_setEffects();
|
||||
|
||||
return SafeArea(
|
||||
|
@ -100,7 +106,8 @@ class DashboardPage extends BasePage {
|
|||
dotWidth: 6.0,
|
||||
dotHeight: 6.0,
|
||||
dotColor: Theme.of(context).indicatorColor,
|
||||
activeDotColor: Colors.white),
|
||||
activeDotColor: Theme.of(context).accentTextTheme.display1
|
||||
.backgroundColor),
|
||||
)),
|
||||
Container(
|
||||
padding: EdgeInsets.only(left: 45, right: 45, bottom: 24),
|
||||
|
|
|
@ -39,7 +39,10 @@ class ActionButton extends StatelessWidget {
|
|||
SizedBox(height: 15),
|
||||
Text(
|
||||
title,
|
||||
style: TextStyle(fontSize: 14, color: Colors.white),
|
||||
style: TextStyle(
|
||||
fontSize: 14,
|
||||
color: Theme.of(context).accentTextTheme.display3
|
||||
.backgroundColor),
|
||||
)
|
||||
],
|
||||
),
|
||||
|
|
|
@ -44,12 +44,18 @@ class AddressPage extends StatelessWidget {
|
|||
style: TextStyle(
|
||||
fontSize: 14,
|
||||
fontWeight: FontWeight.w500,
|
||||
color: Colors.white),
|
||||
color: Theme.of(context)
|
||||
.accentTextTheme
|
||||
.display3
|
||||
.backgroundColor),
|
||||
)),
|
||||
Icon(
|
||||
Icons.arrow_forward_ios,
|
||||
size: 14,
|
||||
color: Colors.white,
|
||||
color: Theme.of(context)
|
||||
.accentTextTheme
|
||||
.display3
|
||||
.backgroundColor,
|
||||
)
|
||||
],
|
||||
),
|
||||
|
|
|
@ -34,7 +34,10 @@ class BalancePage extends StatelessWidget {
|
|||
style: TextStyle(
|
||||
fontSize: 40,
|
||||
fontWeight: FontWeight.bold,
|
||||
color: Theme.of(context).indicatorColor,
|
||||
color: Theme.of(context)
|
||||
.accentTextTheme
|
||||
.display2
|
||||
.backgroundColor,
|
||||
height: 1),
|
||||
);
|
||||
}),
|
||||
|
@ -44,7 +47,10 @@ class BalancePage extends StatelessWidget {
|
|||
style: TextStyle(
|
||||
fontSize: 12,
|
||||
fontWeight: FontWeight.w600,
|
||||
color: Theme.of(context).indicatorColor,
|
||||
color: Theme.of(context)
|
||||
.accentTextTheme
|
||||
.display2
|
||||
.backgroundColor,
|
||||
height: 1),
|
||||
);
|
||||
}),
|
||||
|
@ -53,12 +59,14 @@ class BalancePage extends StatelessWidget {
|
|||
return AutoSizeText(
|
||||
dashboardViewModel.balanceViewModel.cryptoBalance,
|
||||
style: TextStyle(
|
||||
fontSize: 54,
|
||||
fontSize: 40,
|
||||
fontWeight: FontWeight.bold,
|
||||
color: Colors.white,
|
||||
color: Theme.of(context)
|
||||
.accentTextTheme
|
||||
.display3
|
||||
.backgroundColor,
|
||||
height: 1),
|
||||
maxLines: 1,
|
||||
textAlign: TextAlign.center);
|
||||
);
|
||||
}),
|
||||
SizedBox(height: 10),
|
||||
Observer(builder: (_) {
|
||||
|
|
|
@ -27,14 +27,15 @@ class HeaderRow extends StatelessWidget {
|
|||
style: TextStyle(
|
||||
fontSize: 20,
|
||||
fontWeight: FontWeight.w500,
|
||||
color: Colors.white
|
||||
color: Theme.of(context).accentTextTheme.display3.backgroundColor
|
||||
),
|
||||
),
|
||||
GestureDetector(
|
||||
onTap: () {
|
||||
showPopUp<void>(
|
||||
context: context,
|
||||
builder: (context) => FilterWidget(dashboardViewModel: dashboardViewModel)
|
||||
builder: (context) =>
|
||||
FilterWidget(dashboardViewModel: dashboardViewModel)
|
||||
);
|
||||
},
|
||||
child: Container(
|
||||
|
|
|
@ -48,14 +48,16 @@ class TradeRow extends StatelessWidget {
|
|||
style: TextStyle(
|
||||
fontSize: 16,
|
||||
fontWeight: FontWeight.w500,
|
||||
color: Colors.white
|
||||
color: Theme.of(context).accentTextTheme.
|
||||
display3.backgroundColor
|
||||
)),
|
||||
formattedAmount != null
|
||||
? Text(formattedAmount + ' ' + amountCrypto,
|
||||
style: TextStyle(
|
||||
fontSize: 16,
|
||||
fontWeight: FontWeight.w500,
|
||||
color: Colors.white
|
||||
color: Theme.of(context).accentTextTheme.
|
||||
display3.backgroundColor
|
||||
))
|
||||
: Container()
|
||||
]),
|
||||
|
|
|
@ -60,12 +60,14 @@ class TransactionRow extends StatelessWidget {
|
|||
style: TextStyle(
|
||||
fontSize: 16,
|
||||
fontWeight: FontWeight.w500,
|
||||
color: Colors.white)),
|
||||
color: Theme.of(context).accentTextTheme.
|
||||
display3.backgroundColor)),
|
||||
Text(formattedAmount,
|
||||
style: TextStyle(
|
||||
fontSize: 16,
|
||||
fontWeight: FontWeight.w500,
|
||||
color: Colors.white))
|
||||
color: Theme.of(context).accentTextTheme.
|
||||
display3.backgroundColor))
|
||||
]),
|
||||
Row(
|
||||
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||
|
|
|
@ -95,9 +95,8 @@ class ExchangePage extends BasePage {
|
|||
return KeyboardActions(
|
||||
config: KeyboardActionsConfig(
|
||||
keyboardActionsPlatform: KeyboardActionsPlatform.IOS,
|
||||
keyboardBarColor: isDarkTheme
|
||||
? Color.fromRGBO(48, 51, 60, 1.0)
|
||||
: Color.fromRGBO(98, 98, 98, 1.0),
|
||||
keyboardBarColor: Theme.of(context).accentTextTheme.body2
|
||||
.backgroundColor,
|
||||
nextFocus: false,
|
||||
actions: [
|
||||
KeyboardActionsItem(
|
||||
|
|
|
@ -166,8 +166,8 @@ class ExchangeCardState extends State<ExchangeCard> {
|
|||
fontSize: 16,
|
||||
fontWeight: FontWeight.w600,
|
||||
color: Theme.of(context)
|
||||
.textTheme
|
||||
.subhead
|
||||
.accentTextTheme
|
||||
.display4
|
||||
.decorationColor),
|
||||
validator: _isAmountEditable
|
||||
? widget.currencyValueValidator
|
||||
|
@ -211,8 +211,8 @@ class ExchangeCardState extends State<ExchangeCard> {
|
|||
fontSize: 10,
|
||||
height: 1.2,
|
||||
color: Theme.of(context)
|
||||
.textTheme
|
||||
.subhead
|
||||
.accentTextTheme
|
||||
.display4
|
||||
.decorationColor),
|
||||
)
|
||||
: Offstage(),
|
||||
|
@ -224,8 +224,8 @@ class ExchangeCardState extends State<ExchangeCard> {
|
|||
fontSize: 10,
|
||||
height: 1.2,
|
||||
color: Theme.of(context)
|
||||
.textTheme
|
||||
.subhead
|
||||
.accentTextTheme
|
||||
.display4
|
||||
.decorationColor))
|
||||
: Offstage(),
|
||||
]),
|
||||
|
@ -239,7 +239,10 @@ class ExchangeCardState extends State<ExchangeCard> {
|
|||
fontSize: 14,
|
||||
fontWeight: FontWeight.w500,
|
||||
color:
|
||||
Theme.of(context).textTheme.subhead.decorationColor),
|
||||
Theme.of(context)
|
||||
.accentTextTheme
|
||||
.display4
|
||||
.decorationColor),
|
||||
))
|
||||
: Offstage(),
|
||||
_isAddressEditable
|
||||
|
@ -263,7 +266,10 @@ class ExchangeCardState extends State<ExchangeCard> {
|
|||
fontSize: 16,
|
||||
fontWeight: FontWeight.w600,
|
||||
color:
|
||||
Theme.of(context).textTheme.subhead.decorationColor),
|
||||
Theme.of(context)
|
||||
.accentTextTheme
|
||||
.display4
|
||||
.decorationColor),
|
||||
buttonColor: widget.addressButtonsColor,
|
||||
validator: widget.addressTextFieldValidator,
|
||||
),
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
import 'package:cake_wallet/di.dart';
|
||||
import 'package:cake_wallet/routes.dart';
|
||||
import 'package:cake_wallet/store/settings_store.dart';
|
||||
import 'package:cake_wallet/themes/theme_base.dart';
|
||||
import 'package:cake_wallet/utils/show_pop_up.dart';
|
||||
import 'package:mobx/mobx.dart';
|
||||
import 'package:flutter_mobx/flutter_mobx.dart';
|
||||
|
@ -22,17 +21,24 @@ class NewWalletPage extends BasePage {
|
|||
|
||||
final WalletNewVM _walletNewVM;
|
||||
|
||||
final walletNameImage = Image.asset('assets/images/wallet_name.png');
|
||||
final walletNameLightImage =
|
||||
Image.asset('assets/images/wallet_name_light.png');
|
||||
|
||||
@override
|
||||
String get title => S.current.new_wallet;
|
||||
|
||||
@override
|
||||
Widget body(BuildContext context) => WalletNameForm(_walletNewVM);
|
||||
Widget body(BuildContext context) => WalletNameForm(_walletNewVM,
|
||||
currentTheme.type == ThemeType.dark
|
||||
? walletNameImage : walletNameLightImage);
|
||||
}
|
||||
|
||||
class WalletNameForm extends StatefulWidget {
|
||||
WalletNameForm(this._walletNewVM);
|
||||
WalletNameForm(this._walletNewVM, this.walletImage);
|
||||
|
||||
final WalletNewVM _walletNewVM;
|
||||
final Image walletImage;
|
||||
|
||||
@override
|
||||
_WalletNameFormState createState() => _WalletNameFormState(_walletNewVM);
|
||||
|
@ -43,9 +49,6 @@ class _WalletNameFormState extends State<WalletNameForm> {
|
|||
|
||||
static const aspectRatioImage = 1.22;
|
||||
|
||||
final walletNameImage = Image.asset('assets/images/wallet_name.png');
|
||||
final walletNameLightImage =
|
||||
Image.asset('assets/images/wallet_name_light.png');
|
||||
final _formKey = GlobalKey<FormState>();
|
||||
final _languageSelectorKey = GlobalKey<SeedLanguageSelectorState>();
|
||||
ReactionDisposer _stateReaction;
|
||||
|
@ -78,10 +81,6 @@ class _WalletNameFormState extends State<WalletNameForm> {
|
|||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
final walletImage = getIt.get<SettingsStore>().isDarkTheme
|
||||
? walletNameImage
|
||||
: walletNameLightImage;
|
||||
|
||||
return Container(
|
||||
padding: EdgeInsets.only(top: 24),
|
||||
child: ScrollableWithBottomSection(
|
||||
|
@ -92,7 +91,7 @@ class _WalletNameFormState extends State<WalletNameForm> {
|
|||
padding: EdgeInsets.only(left: 12, right: 12),
|
||||
child: AspectRatio(
|
||||
aspectRatio: aspectRatioImage,
|
||||
child: FittedBox(child: walletImage, fit: BoxFit.fill)),
|
||||
child: FittedBox(child: widget.walletImage, fit: BoxFit.fill)),
|
||||
),
|
||||
Padding(
|
||||
padding: EdgeInsets.only(top: 24),
|
||||
|
|
|
@ -6,6 +6,8 @@ import 'package:cake_wallet/store/settings_store.dart';
|
|||
import 'package:cake_wallet/utils/show_bar.dart';
|
||||
import 'package:cake_wallet/view_model/wallet_new_vm.dart';
|
||||
import 'package:flushbar/flushbar.dart';
|
||||
import 'package:cake_wallet/entities/wallet_type.dart';
|
||||
import 'package:cake_wallet/themes/theme_base.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter/cupertino.dart';
|
||||
import 'package:cake_wallet/generated/i18n.dart';
|
||||
|
@ -15,28 +17,36 @@ import 'package:cake_wallet/src/widgets/scollable_with_bottom_section.dart';
|
|||
import 'package:cake_wallet/src/screens/new_wallet/widgets/select_button.dart';
|
||||
|
||||
class NewWalletTypePage extends BasePage {
|
||||
NewWalletTypePage(this.walletNewVM,
|
||||
{this.onTypeSelected, this.isNewWallet});
|
||||
NewWalletTypePage(this.walletNewVM, {this.onTypeSelected, this.isNewWallet});
|
||||
|
||||
final void Function(BuildContext, WalletType) onTypeSelected;
|
||||
final bool isNewWallet;
|
||||
final WalletNewVM walletNewVM;
|
||||
|
||||
final walletTypeImage = Image.asset('assets/images/wallet_type.png');
|
||||
final walletTypeLightImage =
|
||||
Image.asset('assets/images/wallet_type_light.png');
|
||||
|
||||
@override
|
||||
String get title =>
|
||||
isNewWallet ? S.current.new_wallet : S.current.wallet_list_restore_wallet;
|
||||
|
||||
@override
|
||||
Widget body(BuildContext context) =>
|
||||
WalletTypeForm(walletNewVM, isNewWallet, onTypeSelected: onTypeSelected);
|
||||
Widget body(BuildContext context) => WalletTypeForm(walletNewVM, isNewWallet,
|
||||
onTypeSelected: onTypeSelected,
|
||||
walletImage: currentTheme.type == ThemeType.dark
|
||||
? walletTypeImage
|
||||
: walletTypeLightImage);
|
||||
}
|
||||
|
||||
class WalletTypeForm extends StatefulWidget {
|
||||
WalletTypeForm(this.walletNewVM, this.isNewWallet, {this.onTypeSelected});
|
||||
WalletTypeForm(this.walletNewVM, this.isNewWallet,
|
||||
{this.onTypeSelected, this.walletImage});
|
||||
|
||||
final void Function(BuildContext, WalletType) onTypeSelected;
|
||||
final WalletNewVM walletNewVM;
|
||||
final bool isNewWallet;
|
||||
final Image walletImage;
|
||||
|
||||
@override
|
||||
WalletTypeFormState createState() => WalletTypeFormState();
|
||||
|
@ -65,10 +75,6 @@ class WalletTypeFormState extends State<WalletTypeForm> {
|
|||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
final walletImage = getIt.get<SettingsStore>().isDarkTheme
|
||||
? walletTypeImage
|
||||
: walletTypeLightImage;
|
||||
|
||||
return Container(
|
||||
padding: EdgeInsets.only(top: 24, bottom: 24),
|
||||
child: ScrollableWithBottomSection(
|
||||
|
@ -80,7 +86,8 @@ class WalletTypeFormState extends State<WalletTypeForm> {
|
|||
padding: EdgeInsets.only(left: 12, right: 12),
|
||||
child: AspectRatio(
|
||||
aspectRatio: aspectRatioImage,
|
||||
child: FittedBox(child: walletImage, fit: BoxFit.fill)),
|
||||
child:
|
||||
FittedBox(child: widget.walletImage, fit: BoxFit.fill)),
|
||||
),
|
||||
Padding(
|
||||
padding: EdgeInsets.only(top: 48),
|
||||
|
@ -107,10 +114,7 @@ class WalletTypeFormState extends State<WalletTypeForm> {
|
|||
bottomSection: PrimaryButton(
|
||||
onPressed: () => onTypeSelected(),
|
||||
text: S.of(context).seed_language_next,
|
||||
color: Theme.of(context)
|
||||
.accentTextTheme
|
||||
.subtitle
|
||||
.decorationColor,
|
||||
color: Theme.of(context).accentTextTheme.body2.color,
|
||||
textColor: Colors.white,
|
||||
isDisabled: selected == null,
|
||||
),
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
import 'package:cake_wallet/src/widgets/keyboard_done_button.dart';
|
||||
import 'package:cake_wallet/themes/theme_base.dart';
|
||||
import 'package:cake_wallet/utils/show_pop_up.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter/cupertino.dart';
|
||||
|
@ -27,16 +28,47 @@ class ReceivePage extends BasePage {
|
|||
String get title => S.current.receive;
|
||||
|
||||
@override
|
||||
Color get backgroundLightColor => Colors.transparent;
|
||||
Color get backgroundLightColor => currentTheme.type == ThemeType.bright
|
||||
? Colors.transparent : Colors.white;
|
||||
|
||||
@override
|
||||
Color get backgroundDarkColor => Colors.transparent;
|
||||
|
||||
@override
|
||||
Color get titleColor => Colors.white;
|
||||
|
||||
final FocusNode _cryptoAmountFocus;
|
||||
|
||||
@override
|
||||
Widget leading(BuildContext context) {
|
||||
final _backButton = Icon(Icons.arrow_back_ios,
|
||||
color: Theme.of(context).accentTextTheme.display3.backgroundColor,
|
||||
size: 16,);
|
||||
|
||||
return SizedBox(
|
||||
height: 37,
|
||||
width: 37,
|
||||
child: ButtonTheme(
|
||||
minWidth: double.minPositive,
|
||||
child: FlatButton(
|
||||
highlightColor: Colors.transparent,
|
||||
splashColor: Colors.transparent,
|
||||
padding: EdgeInsets.all(0),
|
||||
onPressed: () => onClose(context),
|
||||
child: _backButton),
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
@override
|
||||
Widget middle(BuildContext context) {
|
||||
return Text(
|
||||
title,
|
||||
style: TextStyle(
|
||||
fontSize: 18.0,
|
||||
fontWeight: FontWeight.bold,
|
||||
fontFamily: 'Lato',
|
||||
color: Theme.of(context).accentTextTheme.display3.backgroundColor),
|
||||
);
|
||||
}
|
||||
|
||||
@override
|
||||
Widget Function(BuildContext, Widget) get rootWrapper =>
|
||||
(BuildContext context, Widget scaffold) => Container(
|
||||
|
@ -51,7 +83,8 @@ class ReceivePage extends BasePage {
|
|||
@override
|
||||
Widget trailing(BuildContext context) {
|
||||
final shareImage =
|
||||
Image.asset('assets/images/share.png', color: Colors.white);
|
||||
Image.asset('assets/images/share.png',
|
||||
color: Theme.of(context).accentTextTheme.display3.backgroundColor);
|
||||
|
||||
return SizedBox(
|
||||
height: 20.0,
|
||||
|
@ -74,9 +107,8 @@ class ReceivePage extends BasePage {
|
|||
return KeyboardActions(
|
||||
config: KeyboardActionsConfig(
|
||||
keyboardActionsPlatform: KeyboardActionsPlatform.IOS,
|
||||
keyboardBarColor: isDarkTheme
|
||||
? Color.fromRGBO(48, 51, 60, 1.0)
|
||||
: Color.fromRGBO(98, 98, 98, 1.0),
|
||||
keyboardBarColor: Theme.of(context).accentTextTheme.body2
|
||||
.backgroundColor,
|
||||
nextFocus: false,
|
||||
actions: [
|
||||
KeyboardActionsItem(
|
||||
|
|
|
@ -47,8 +47,8 @@ class QRWidget extends StatelessWidget {
|
|||
child: QrImage(
|
||||
data: addressListViewModel.uri.toString(),
|
||||
backgroundColor: Colors.transparent,
|
||||
foregroundColor: Colors.white,
|
||||
//Theme.of(context).textTheme.headline.color,
|
||||
foregroundColor: Theme.of(context).accentTextTheme.
|
||||
display3.backgroundColor,
|
||||
))))),
|
||||
Spacer(flex: 3)
|
||||
]),
|
||||
|
@ -67,11 +67,12 @@ class QRWidget extends StatelessWidget {
|
|||
decimal: true),
|
||||
inputFormatters: [
|
||||
BlacklistingTextInputFormatter(
|
||||
RegExp('[\\-|\\ |\\,]'))
|
||||
RegExp('[\\-|\\ ]'))
|
||||
],
|
||||
textAlign: TextAlign.center,
|
||||
hintText: S.of(context).receive_amount,
|
||||
textColor: Colors.white,
|
||||
textColor: Theme.of(context).accentTextTheme.
|
||||
display3.backgroundColor,
|
||||
borderColor: Theme.of(context)
|
||||
.textTheme
|
||||
.headline
|
||||
|
@ -110,7 +111,8 @@ class QRWidget extends StatelessWidget {
|
|||
style: TextStyle(
|
||||
fontSize: 16,
|
||||
fontWeight: FontWeight.w500,
|
||||
color: Colors.white),
|
||||
color: Theme.of(context).accentTextTheme.
|
||||
display3.backgroundColor),
|
||||
),
|
||||
),
|
||||
Padding(
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
import 'package:cake_wallet/di.dart';
|
||||
import 'package:cake_wallet/routes.dart';
|
||||
import 'package:cake_wallet/store/settings_store.dart';
|
||||
import 'package:cake_wallet/themes/theme_base.dart';
|
||||
import 'package:flutter/cupertino.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:cake_wallet/generated/i18n.dart';
|
||||
|
@ -8,8 +7,8 @@ import 'package:cake_wallet/src/widgets/primary_button.dart';
|
|||
import 'package:cake_wallet/src/screens/base_page.dart';
|
||||
|
||||
class PreSeedPage extends BasePage {
|
||||
static final imageLight = Image.asset('assets/images/pre_seed_light.png');
|
||||
static final imageDark = Image.asset('assets/images/pre_seed_dark.png');
|
||||
final imageLight = Image.asset('assets/images/pre_seed_light.png');
|
||||
final imageDark = Image.asset('assets/images/pre_seed_dark.png');
|
||||
|
||||
@override
|
||||
Widget leading(BuildContext context) => null;
|
||||
|
@ -19,8 +18,7 @@ class PreSeedPage extends BasePage {
|
|||
|
||||
@override
|
||||
Widget body(BuildContext context) {
|
||||
final image =
|
||||
getIt.get<SettingsStore>().isDarkTheme ? imageDark : imageLight;
|
||||
final image = currentTheme.type == ThemeType.dark ? imageDark : imageLight;
|
||||
|
||||
return WillPopScope(
|
||||
onWillPop: () async => false,
|
||||
|
|
|
@ -1,7 +1,6 @@
|
|||
import 'package:cake_wallet/di.dart';
|
||||
import 'package:cake_wallet/palette.dart';
|
||||
import 'package:cake_wallet/themes/theme_base.dart';
|
||||
import 'package:cake_wallet/src/widgets/alert_with_two_actions.dart';
|
||||
import 'package:cake_wallet/store/settings_store.dart';
|
||||
import 'package:cake_wallet/utils/show_bar.dart';
|
||||
import 'package:cake_wallet/utils/show_pop_up.dart';
|
||||
import 'package:flutter/cupertino.dart';
|
||||
|
@ -17,8 +16,8 @@ import 'package:cake_wallet/view_model/wallet_seed_view_model.dart';
|
|||
class WalletSeedPage extends BasePage {
|
||||
WalletSeedPage(this.walletSeedViewModel, {@required this.isNewWalletCreated});
|
||||
|
||||
static final imageLight = Image.asset('assets/images/crypto_lock_light.png');
|
||||
static final imageDark = Image.asset('assets/images/crypto_lock.png');
|
||||
final imageLight = Image.asset('assets/images/crypto_lock_light.png');
|
||||
final imageDark = Image.asset('assets/images/crypto_lock.png');
|
||||
|
||||
@override
|
||||
String get title => S.current.seed_title;
|
||||
|
@ -83,8 +82,7 @@ class WalletSeedPage extends BasePage {
|
|||
|
||||
@override
|
||||
Widget body(BuildContext context) {
|
||||
final image =
|
||||
getIt.get<SettingsStore>().isDarkTheme ? imageDark : imageLight;
|
||||
final image = currentTheme.type == ThemeType.dark ? imageDark : imageLight;
|
||||
|
||||
return WillPopScope(onWillPop: () async => false, child: Container(
|
||||
padding: EdgeInsets.all(24),
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
import 'package:cake_wallet/di.dart';
|
||||
import 'package:cake_wallet/themes/theme_base.dart';
|
||||
import 'package:cake_wallet/src/widgets/seed_language_selector.dart';
|
||||
import 'package:cake_wallet/store/settings_store.dart';
|
||||
import 'package:flutter_mobx/flutter_mobx.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter/cupertino.dart';
|
||||
|
@ -15,17 +14,26 @@ class SeedLanguage extends BasePage {
|
|||
|
||||
final Function(BuildContext, String) onConfirm;
|
||||
|
||||
final walletNameImage = Image.asset('assets/images/wallet_name.png');
|
||||
final walletNameLightImage =
|
||||
Image.asset('assets/images/wallet_name_light.png');
|
||||
|
||||
@override
|
||||
String get title => S.current.wallet_list_restore_wallet;
|
||||
|
||||
@override
|
||||
Widget body(BuildContext context) => SeedLanguageForm(onConfirm: onConfirm);
|
||||
Widget body(BuildContext context) =>
|
||||
SeedLanguageForm(
|
||||
onConfirm: onConfirm,
|
||||
walletImage: currentTheme.type == ThemeType.dark
|
||||
? walletNameImage : walletNameLightImage);
|
||||
}
|
||||
|
||||
class SeedLanguageForm extends StatefulWidget {
|
||||
SeedLanguageForm({this.onConfirm});
|
||||
SeedLanguageForm({this.onConfirm, this.walletImage});
|
||||
|
||||
final Function(BuildContext, String) onConfirm;
|
||||
final Image walletImage;
|
||||
|
||||
@override
|
||||
SeedLanguageFormState createState() => SeedLanguageFormState();
|
||||
|
@ -33,18 +41,10 @@ class SeedLanguageForm extends StatefulWidget {
|
|||
|
||||
class SeedLanguageFormState extends State<SeedLanguageForm> {
|
||||
static const aspectRatioImage = 1.22;
|
||||
|
||||
final walletNameImage = Image.asset('assets/images/wallet_name.png');
|
||||
final walletNameLightImage =
|
||||
Image.asset('assets/images/wallet_name_light.png');
|
||||
final _languageSelectorKey = GlobalKey<SeedLanguageSelectorState>();
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
final walletImage = getIt.get<SettingsStore>().isDarkTheme
|
||||
? walletNameImage
|
||||
: walletNameLightImage;
|
||||
|
||||
return Container(
|
||||
padding: EdgeInsets.only(top: 24),
|
||||
child: ScrollableWithBottomSection(
|
||||
|
@ -55,7 +55,8 @@ class SeedLanguageFormState extends State<SeedLanguageForm> {
|
|||
padding: EdgeInsets.only(left: 12, right: 12),
|
||||
child: AspectRatio(
|
||||
aspectRatio: aspectRatioImage,
|
||||
child: FittedBox(child: walletImage, fit: BoxFit.fill)),
|
||||
child: FittedBox(child: widget.walletImage,
|
||||
fit: BoxFit.fill)),
|
||||
),
|
||||
Padding(
|
||||
padding: EdgeInsets.only(top: 40),
|
||||
|
|
|
@ -83,9 +83,8 @@ class SendPage extends BasePage {
|
|||
return KeyboardActions(
|
||||
config: KeyboardActionsConfig(
|
||||
keyboardActionsPlatform: KeyboardActionsPlatform.IOS,
|
||||
keyboardBarColor: isDarkTheme
|
||||
? Color.fromRGBO(48, 51, 60, 1.0)
|
||||
: Color.fromRGBO(98, 98, 98, 1.0),
|
||||
keyboardBarColor: Theme.of(context).accentTextTheme.body2
|
||||
.backgroundColor,
|
||||
nextFocus: false,
|
||||
actions: [
|
||||
KeyboardActionsItem(
|
||||
|
@ -498,14 +497,8 @@ class SendPage extends BasePage {
|
|||
}
|
||||
},
|
||||
text: S.of(context).send,
|
||||
color: Theme.of(context)
|
||||
.accentTextTheme
|
||||
.subtitle
|
||||
.decorationColor,
|
||||
textColor: Theme.of(context)
|
||||
.accentTextTheme
|
||||
.headline
|
||||
.decorationColor,
|
||||
color: Theme.of(context).accentTextTheme.body2.color,
|
||||
textColor: Colors.white,
|
||||
isLoading: sendViewModel.state is IsExecutingState ||
|
||||
sendViewModel.state is TransactionCommitting,
|
||||
isDisabled:
|
||||
|
|
|
@ -49,9 +49,8 @@ class SendTemplatePage extends BasePage {
|
|||
return KeyboardActions(
|
||||
config: KeyboardActionsConfig(
|
||||
keyboardActionsPlatform: KeyboardActionsPlatform.IOS,
|
||||
keyboardBarColor: isDarkTheme
|
||||
? Color.fromRGBO(48, 51, 60, 1.0)
|
||||
: Color.fromRGBO(98, 98, 98, 1.0),
|
||||
keyboardBarColor: Theme.of(context).accentTextTheme.body2
|
||||
.backgroundColor,
|
||||
nextFocus: false,
|
||||
actions: [
|
||||
KeyboardActionsItem(
|
||||
|
@ -247,9 +246,8 @@ class SendTemplatePage extends BasePage {
|
|||
}
|
||||
},
|
||||
text: S.of(context).save,
|
||||
color: Theme.of(context).accentTextTheme.subtitle.decorationColor,
|
||||
textColor:
|
||||
Theme.of(context).accentTextTheme.headline.decorationColor,
|
||||
color: Colors.green,
|
||||
textColor: Colors.white,
|
||||
),
|
||||
),
|
||||
));
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
import 'package:cake_wallet/src/screens/auth/auth_page.dart';
|
||||
import 'package:cake_wallet/src/screens/wallet_list/widgets/wallet_menu_alert.dart';
|
||||
import 'package:cake_wallet/src/widgets/alert_with_two_actions.dart';
|
||||
import 'package:cake_wallet/utils/show_bar.dart';
|
||||
import 'package:cake_wallet/utils/show_pop_up.dart';
|
||||
|
@ -15,7 +14,6 @@ import 'package:cake_wallet/view_model/wallet_list/wallet_list_view_model.dart';
|
|||
import 'package:cake_wallet/src/widgets/primary_button.dart';
|
||||
import 'package:cake_wallet/src/screens/base_page.dart';
|
||||
import 'package:cake_wallet/src/widgets/scollable_with_bottom_section.dart';
|
||||
import 'package:cake_wallet/src/screens/wallet_list/wallet_menu.dart';
|
||||
import 'package:flutter_slidable/flutter_slidable.dart';
|
||||
|
||||
class WalletListPage extends BasePage {
|
||||
|
@ -51,7 +49,7 @@ class WalletListBodyState extends State<WalletListBody> {
|
|||
final newWalletImage = Image.asset('assets/images/new_wallet.png',
|
||||
height: 12,
|
||||
width: 12,
|
||||
color: Theme.of(context).accentTextTheme.headline.decorationColor);
|
||||
color: Colors.white);
|
||||
final restoreWalletImage = Image.asset('assets/images/restore_wallet.png',
|
||||
height: 12,
|
||||
width: 12,
|
||||
|
@ -168,9 +166,8 @@ class WalletListBodyState extends State<WalletListBody> {
|
|||
onPressed: () => Navigator.of(context).pushNamed(Routes.newWalletType),
|
||||
image: newWalletImage,
|
||||
text: S.of(context).wallet_list_create_new_wallet,
|
||||
color: Theme.of(context).accentTextTheme.subtitle.decorationColor,
|
||||
textColor:
|
||||
Theme.of(context).accentTextTheme.headline.decorationColor,
|
||||
color: Theme.of(context).accentTextTheme.body2.color,
|
||||
textColor: Colors.white,
|
||||
),
|
||||
SizedBox(height: 10.0),
|
||||
PrimaryImageButton(
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
import 'package:cake_wallet/di.dart';
|
||||
import 'package:cake_wallet/store/settings_store.dart';
|
||||
import 'package:cake_wallet/themes/theme_base.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:cake_wallet/routes.dart';
|
||||
import 'package:cake_wallet/src/widgets/primary_button.dart';
|
||||
|
@ -23,9 +22,7 @@ class WelcomePage extends BasePage {
|
|||
|
||||
@override
|
||||
Widget body(BuildContext context) {
|
||||
final welcomeImage = getIt
|
||||
.get<SettingsStore>()
|
||||
.isDarkTheme
|
||||
final welcomeImage = currentTheme.type == ThemeType.dark
|
||||
? welcomeImageDark : welcomeImageLight;
|
||||
|
||||
final newWalletImage = Image.asset('assets/images/new_wallet.png',
|
||||
|
|
|
@ -31,7 +31,7 @@ class AlertWithOneAction extends BaseAlertDialog {
|
|||
width: 300,
|
||||
height: 52,
|
||||
padding: EdgeInsets.only(left: 12, right: 12),
|
||||
color: Theme.of(context).accentTextTheme.body2.color,
|
||||
color: Theme.of(context).accentTextTheme.body1.backgroundColor,
|
||||
child: ButtonTheme(
|
||||
minWidth: double.infinity,
|
||||
child: FlatButton(
|
||||
|
@ -44,7 +44,8 @@ class AlertWithOneAction extends BaseAlertDialog {
|
|||
style: TextStyle(
|
||||
fontSize: 15,
|
||||
fontWeight: FontWeight.w600,
|
||||
color: Colors.white,
|
||||
color: Theme.of(context).primaryTextTheme.body1
|
||||
.backgroundColor,
|
||||
decoration: TextDecoration.none,
|
||||
),
|
||||
)),
|
||||
|
|
|
@ -61,18 +61,24 @@ class BaseAlertDialog extends StatelessWidget {
|
|||
fontSize: 15,
|
||||
fontFamily: 'Lato',
|
||||
fontWeight: FontWeight.w600,
|
||||
color: Colors.white,
|
||||
color: Theme.of(context).primaryTextTheme.body2
|
||||
.backgroundColor,
|
||||
decoration: TextDecoration.none,
|
||||
),
|
||||
)),
|
||||
),
|
||||
)
|
||||
),
|
||||
Container(
|
||||
width: 1,
|
||||
height: 52,
|
||||
color: Theme.of(context).dividerColor,
|
||||
),
|
||||
Flexible(
|
||||
child: Container(
|
||||
height: 52,
|
||||
padding: EdgeInsets.only(left: 6, right: 6),
|
||||
color: Theme.of(context).accentTextTheme.body2.color,
|
||||
color: Theme.of(context).accentTextTheme.body1.backgroundColor,
|
||||
child: ButtonTheme(
|
||||
minWidth: double.infinity,
|
||||
child: FlatButton(
|
||||
|
@ -86,7 +92,8 @@ class BaseAlertDialog extends StatelessWidget {
|
|||
fontSize: 15,
|
||||
fontFamily: 'Lato',
|
||||
fontWeight: FontWeight.w600,
|
||||
color: Colors.white,
|
||||
color: Theme.of(context).primaryTextTheme.body1
|
||||
.backgroundColor,
|
||||
decoration: TextDecoration.none,
|
||||
),
|
||||
)),
|
||||
|
@ -133,6 +140,10 @@ class BaseAlertDialog extends StatelessWidget {
|
|||
],
|
||||
),
|
||||
),
|
||||
Container(
|
||||
height: 1,
|
||||
color: Theme.of(context).dividerColor,
|
||||
),
|
||||
actionButtons(context)
|
||||
],
|
||||
),
|
||||
|
|
|
@ -21,7 +21,10 @@ class TrailButton extends StatelessWidget {
|
|||
child: Text(
|
||||
caption,
|
||||
style: TextStyle(
|
||||
color: Theme.of(context).textTheme.subhead.decorationColor,
|
||||
color: Theme.of(context)
|
||||
.accentTextTheme
|
||||
.display4
|
||||
.decorationColor,
|
||||
fontWeight: FontWeight.w500,
|
||||
fontSize: 14),
|
||||
),
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
import 'package:cake_wallet/entities/preferences_key.dart';
|
||||
import 'package:cake_wallet/themes.dart';
|
||||
import 'package:cake_wallet/themes/theme_base.dart';
|
||||
import 'package:cake_wallet/themes/theme_list.dart';
|
||||
import 'package:flutter/foundation.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:hive/hive.dart';
|
||||
|
@ -28,7 +29,7 @@ abstract class SettingsStoreBase with Store {
|
|||
@required BalanceDisplayMode initialBalanceDisplayMode,
|
||||
@required bool initialSaveRecipientAddress,
|
||||
@required bool initialAllowBiometricalAuthentication,
|
||||
@required bool initialDarkTheme,
|
||||
@required ThemeBase initialTheme,
|
||||
@required int initialPinLength,
|
||||
@required String initialLanguageCode,
|
||||
// @required String initialCurrentLocale,
|
||||
|
@ -40,7 +41,7 @@ abstract class SettingsStoreBase with Store {
|
|||
balanceDisplayMode = initialBalanceDisplayMode;
|
||||
shouldSaveRecipientAddress = initialSaveRecipientAddress;
|
||||
allowBiometricalAuthentication = initialAllowBiometricalAuthentication;
|
||||
isDarkTheme = initialDarkTheme;
|
||||
currentTheme = initialTheme;
|
||||
pinCodeLength = initialPinLength;
|
||||
languageCode = initialLanguageCode;
|
||||
this.nodes = ObservableMap<WalletType, Node>.of(nodes);
|
||||
|
@ -64,9 +65,9 @@ abstract class SettingsStoreBase with Store {
|
|||
shouldSaveRecipientAddress));
|
||||
|
||||
reaction(
|
||||
(_) => isDarkTheme,
|
||||
(bool isDarkTheme) => sharedPreferences.setBool(
|
||||
PreferencesKey.currentDarkTheme, isDarkTheme));
|
||||
(_) => currentTheme,
|
||||
(ThemeBase theme) => sharedPreferences.setInt(
|
||||
PreferencesKey.currentTheme, theme.raw));
|
||||
|
||||
reaction(
|
||||
(_) => allowBiometricalAuthentication,
|
||||
|
@ -111,13 +112,13 @@ abstract class SettingsStoreBase with Store {
|
|||
bool allowBiometricalAuthentication;
|
||||
|
||||
@observable
|
||||
bool isDarkTheme;
|
||||
ThemeBase currentTheme;
|
||||
|
||||
@observable
|
||||
int pinCodeLength;
|
||||
|
||||
@computed
|
||||
ThemeData get theme => isDarkTheme ? Themes.darkTheme : Themes.lightTheme;
|
||||
ThemeData get theme => currentTheme.themeData;
|
||||
|
||||
@observable
|
||||
String languageCode;
|
||||
|
@ -151,8 +152,8 @@ abstract class SettingsStoreBase with Store {
|
|||
final allowBiometricalAuthentication = sharedPreferences
|
||||
.getBool(PreferencesKey.allowBiometricalAuthenticationKey) ??
|
||||
false;
|
||||
final savedDarkTheme =
|
||||
sharedPreferences.getBool(PreferencesKey.currentDarkTheme) ?? false;
|
||||
final savedTheme = ThemeList.deserialize(
|
||||
raw: sharedPreferences.getInt(PreferencesKey.currentTheme) ?? 0);
|
||||
final actionListDisplayMode = ObservableList<ActionListDisplayMode>();
|
||||
actionListDisplayMode.addAll(deserializeActionlistDisplayModes(
|
||||
sharedPreferences.getInt(PreferencesKey.displayActionListModeKey) ??
|
||||
|
@ -185,7 +186,7 @@ abstract class SettingsStoreBase with Store {
|
|||
initialBalanceDisplayMode: currentBalanceDisplayMode,
|
||||
initialSaveRecipientAddress: shouldSaveRecipientAddress,
|
||||
initialAllowBiometricalAuthentication: allowBiometricalAuthentication,
|
||||
initialDarkTheme: savedDarkTheme,
|
||||
initialTheme: savedTheme,
|
||||
actionlistDisplayMode: actionListDisplayMode,
|
||||
initialPinLength: pinLength,
|
||||
initialLanguageCode: savedLanguageCode);
|
||||
|
|
353
lib/themes.dart
|
@ -1,353 +0,0 @@
|
|||
import 'package:flutter/material.dart';
|
||||
import 'palette.dart';
|
||||
|
||||
class Themes {
|
||||
|
||||
static final ThemeData lightTheme = ThemeData(
|
||||
fontFamily: 'Lato',
|
||||
brightness: Brightness.light,
|
||||
backgroundColor: Colors.white,
|
||||
accentColor: Palette.blueCraiola, // first gradient color
|
||||
scaffoldBackgroundColor: Palette.pinkFlamingo, // second gradient color
|
||||
primaryColor: Palette.redHat, // third gradient color
|
||||
buttonColor: Colors.white.withOpacity(0.2), // action buttons on dashboard page
|
||||
indicatorColor: Colors.white.withOpacity(0.5), // page indicator
|
||||
hoverColor: Colors.white, // amount hint text (receive page)
|
||||
dividerColor: Palette.paleBlue,
|
||||
hintColor: Palette.gray,
|
||||
textTheme: TextTheme(
|
||||
title: TextStyle(
|
||||
color: Colors.white, // sync_indicator text
|
||||
backgroundColor: Colors.white.withOpacity(0.2), // synced sync_indicator
|
||||
decorationColor: Colors.white.withOpacity(0.15), // not synced sync_indicator
|
||||
),
|
||||
caption: TextStyle(
|
||||
color: Palette.shineOrange, // not synced light
|
||||
decorationColor: Colors.white, // filter icon
|
||||
),
|
||||
overline: TextStyle(
|
||||
color: Colors.white.withOpacity(0.2), // filter button
|
||||
backgroundColor: Colors.white.withOpacity(0.5), // date section row
|
||||
decorationColor: Colors.white.withOpacity(0.2) // icons (transaction and trade rows)
|
||||
),
|
||||
subhead: TextStyle(
|
||||
color: Colors.white.withOpacity(0.2), // address button border
|
||||
decorationColor: Colors.white.withOpacity(0.4), // copy button (qr widget)
|
||||
),
|
||||
headline: TextStyle(
|
||||
color: Colors.white, // qr code
|
||||
decorationColor: Colors.white.withOpacity(0.5), // bottom border of amount (receive page)
|
||||
),
|
||||
display1: TextStyle(
|
||||
color: PaletteDark.lightBlueGrey, // icons color (receive page)
|
||||
decorationColor: Palette.lavender, // icons background (receive page)
|
||||
),
|
||||
display2: TextStyle(
|
||||
color: Palette.darkBlueCraiola, // text color of tiles (receive page)
|
||||
decorationColor: Colors.white // background of tiles (receive page)
|
||||
),
|
||||
display3: TextStyle(
|
||||
color: Colors.white, // text color of current tile (receive page),
|
||||
//decorationColor: Palette.blueCraiola // background of current tile (receive page)
|
||||
decorationColor: Palette.moderateSlateBlue // background of current tile (receive page)
|
||||
),
|
||||
display4: TextStyle(
|
||||
color: Palette.violetBlue, // text color of tiles (account list)
|
||||
decorationColor: Colors.white // background of tiles (account list)
|
||||
),
|
||||
subtitle: TextStyle(
|
||||
color: Palette.moderateSlateBlue, // text color of current tile (account list)
|
||||
decorationColor: Colors.white // background of current tile (account list)
|
||||
),
|
||||
body1: TextStyle(
|
||||
color: Palette.moderatePurpleBlue, // scrollbar thumb
|
||||
decorationColor: Palette.periwinkleCraiola // scrollbar background
|
||||
),
|
||||
body2: TextStyle(
|
||||
color: Palette.moderateLavender, // menu header
|
||||
decorationColor: Colors.white, // menu background
|
||||
)
|
||||
),
|
||||
primaryTextTheme: TextTheme(
|
||||
title: TextStyle(
|
||||
color: Palette.darkBlueCraiola, // title color
|
||||
backgroundColor: Palette.wildPeriwinkle // textfield underline
|
||||
),
|
||||
caption: TextStyle(
|
||||
color: PaletteDark.pigeonBlue, // secondary text
|
||||
decorationColor: Palette.wildLavender // menu divider
|
||||
),
|
||||
overline: TextStyle(
|
||||
color: Palette.darkGray, // transaction/trade details titles
|
||||
decorationColor: Colors.white.withOpacity(0.5), // placeholder
|
||||
),
|
||||
subhead: TextStyle(
|
||||
color: Palette.blueCraiola, // first gradient color (send page)
|
||||
decorationColor: Palette.pinkFlamingo // second gradient color (send page)
|
||||
),
|
||||
headline: TextStyle(
|
||||
color: Colors.white.withOpacity(0.5), // text field border color (send page)
|
||||
decorationColor: Colors.white.withOpacity(0.5), // text field hint color (send page)
|
||||
),
|
||||
display1: TextStyle(
|
||||
color: Colors.white.withOpacity(0.2), // text field button color (send page)
|
||||
decorationColor: Colors.white // text field button icon color (send page)
|
||||
),
|
||||
display2: TextStyle(
|
||||
color: Colors.white.withOpacity(0.5), // estimated fee (send page)
|
||||
decorationColor: Palette.shadowWhite // template dotted border (send page)
|
||||
),
|
||||
display3: TextStyle(
|
||||
color: Palette.darkBlueCraiola, // template new text (send page)
|
||||
decorationColor: Palette.shadowWhite // template background color (send page)
|
||||
),
|
||||
display4: TextStyle(
|
||||
color: Palette.darkBlueCraiola, // template title (send page)
|
||||
decorationColor: Palette.niagara // receive amount text (exchange page)
|
||||
),
|
||||
subtitle: TextStyle(
|
||||
color: Palette.blueCraiola, // first gradient color top panel (exchange page)
|
||||
decorationColor: Palette.pinkFlamingo // second gradient color top panel (exchange page)
|
||||
),
|
||||
body1: TextStyle(
|
||||
color: Palette.blueCraiola.withOpacity(0.7), // first gradient color bottom panel (exchange page)
|
||||
decorationColor: Palette.pinkFlamingo.withOpacity(0.7) // second gradient color bottom panel (exchange page)
|
||||
),
|
||||
body2: TextStyle(
|
||||
color: Colors.white.withOpacity(0.5), // text field border on top panel (exchange page)
|
||||
decorationColor: Colors.white.withOpacity(0.5), // text field border on bottom panel (exchange page)
|
||||
)
|
||||
),
|
||||
focusColor: Colors.white.withOpacity(0.2), // text field button (exchange page)
|
||||
accentTextTheme: TextTheme(
|
||||
title: TextStyle(
|
||||
color: Colors.white, // picker background
|
||||
backgroundColor: Palette.periwinkleCraiola, // picker divider
|
||||
decorationColor: Colors.white // dialog background
|
||||
),
|
||||
caption: TextStyle(
|
||||
color: Palette.moderateLavender, // container (confirm exchange)
|
||||
backgroundColor: Palette.moderateLavender, // button background (confirm exchange)
|
||||
decorationColor: Palette.darkBlueCraiola, // text color (information page)
|
||||
),
|
||||
subtitle: TextStyle(
|
||||
color: Palette.darkBlueCraiola, // QR code (exchange trade page)
|
||||
backgroundColor: Palette.wildPeriwinkle, // divider (exchange trade page)
|
||||
//decorationColor: Palette.blueCraiola // crete new wallet button background (wallet list page)
|
||||
decorationColor: Palette.moderateSlateBlue // crete new wallet button background (wallet list page)
|
||||
),
|
||||
headline: TextStyle(
|
||||
color: Palette.moderateLavender, // first gradient color of wallet action buttons (wallet list page)
|
||||
backgroundColor: Palette.moderateLavender, // second gradient color of wallet action buttons (wallet list page)
|
||||
decorationColor: Colors.white // restore wallet button text color (wallet list page)
|
||||
),
|
||||
subhead: TextStyle(
|
||||
color: Palette.darkGray, // titles color (filter widget)
|
||||
backgroundColor: Palette.periwinkle, // divider color (filter widget)
|
||||
decorationColor: Colors.white // checkbox background (filter widget)
|
||||
),
|
||||
overline: TextStyle(
|
||||
color: Palette.wildPeriwinkle, // checkbox bounds (filter widget)
|
||||
decorationColor: Colors.white, // menu subname
|
||||
),
|
||||
display1: TextStyle(
|
||||
color: Palette.blueCraiola, // first gradient color (menu header)
|
||||
decorationColor: Palette.pinkFlamingo // second gradient color(menu header)
|
||||
),
|
||||
display2: TextStyle(
|
||||
color: Palette.shadowWhite, // action button color (address text field)
|
||||
decorationColor: Palette.darkGray // hint text (seed widget)
|
||||
),
|
||||
display3: TextStyle(
|
||||
color: Palette.darkGray, // hint text (new wallet page)
|
||||
decorationColor: Palette.periwinkleCraiola // underline (new wallet page)
|
||||
),
|
||||
display4: TextStyle(
|
||||
color: Palette.darkGray, // switch background (settings page)
|
||||
),
|
||||
body1: TextStyle(
|
||||
color: Palette.darkGray, // indicators (PIN code)
|
||||
decorationColor: Palette.darkGray // switch (PIN code)
|
||||
),
|
||||
body2: TextStyle(
|
||||
color: Palette.moderateSlateBlue, // primary buttons, alert right buttons
|
||||
decorationColor: Palette.brightOrange // alert left button
|
||||
),
|
||||
),
|
||||
cardColor: Palette.moderateSlateBlue // bottom button (action list)
|
||||
);
|
||||
|
||||
|
||||
static final ThemeData darkTheme = ThemeData(
|
||||
fontFamily: 'Lato',
|
||||
brightness: Brightness.dark,
|
||||
backgroundColor: PaletteDark.backgroundColor,
|
||||
accentColor: PaletteDark.backgroundColor, // first gradient color
|
||||
scaffoldBackgroundColor: PaletteDark.backgroundColor, // second gradient color
|
||||
primaryColor: PaletteDark.backgroundColor, // third gradient color
|
||||
buttonColor: PaletteDark.nightBlue, // action buttons on dashboard page
|
||||
indicatorColor: PaletteDark.cyanBlue, // page indicator
|
||||
hoverColor: PaletteDark.cyanBlue, // amount hint text (receive page)
|
||||
dividerColor: PaletteDark.dividerColor,
|
||||
hintColor: PaletteDark.pigeonBlue, // menu
|
||||
textTheme: TextTheme(
|
||||
title: TextStyle(
|
||||
color: PaletteDark.wildBlue, // sync_indicator text
|
||||
backgroundColor: PaletteDark.lightNightBlue, // synced sync_indicator
|
||||
decorationColor: PaletteDark.oceanBlue // not synced sync_indicator
|
||||
),
|
||||
caption: TextStyle(
|
||||
color: PaletteDark.orangeYellow, // not synced light
|
||||
decorationColor: PaletteDark.wildBlue, // filter icon
|
||||
),
|
||||
overline: TextStyle(
|
||||
color: PaletteDark.oceanBlue, // filter button
|
||||
backgroundColor: PaletteDark.darkCyanBlue, // date section row
|
||||
decorationColor: PaletteDark.wildNightBlue // icons (transaction and trade rows)
|
||||
),
|
||||
subhead: TextStyle(
|
||||
color: PaletteDark.nightBlue, // address button border
|
||||
decorationColor: PaletteDark.lightBlueGrey, // copy button (qr widget)
|
||||
),
|
||||
headline: TextStyle(
|
||||
color: PaletteDark.lightBlueGrey, // qr code
|
||||
decorationColor: PaletteDark.darkGrey, // bottom border of amount (receive page)
|
||||
),
|
||||
display1: TextStyle(
|
||||
color: Colors.white, // icons color (receive page)
|
||||
decorationColor: PaletteDark.distantNightBlue, // icons background (receive page)
|
||||
),
|
||||
display2: TextStyle(
|
||||
color: Colors.white, // text color of tiles (receive page)
|
||||
decorationColor: PaletteDark.nightBlue // background of tiles (receive page)
|
||||
),
|
||||
display3: TextStyle(
|
||||
color: Palette.blueCraiola, // text color of current tile (receive page)
|
||||
decorationColor: PaletteDark.lightOceanBlue // background of current tile (receive page)
|
||||
),
|
||||
display4: TextStyle(
|
||||
color: Colors.white, // text color of tiles (account list)
|
||||
decorationColor: PaletteDark.darkOceanBlue // background of tiles (account list)
|
||||
),
|
||||
subtitle: TextStyle(
|
||||
color: Palette.blueCraiola, // text color of current tile (account list)
|
||||
decorationColor: PaletteDark.darkNightBlue // background of current tile (account list)
|
||||
),
|
||||
body1: TextStyle(
|
||||
color: PaletteDark.wildBlueGrey, // scrollbar thumb
|
||||
decorationColor: PaletteDark.violetBlue // scrollbar background
|
||||
),
|
||||
body2: TextStyle(
|
||||
color: PaletteDark.deepPurpleBlue, // menu header
|
||||
decorationColor: PaletteDark.deepPurpleBlue, // menu background
|
||||
)
|
||||
),
|
||||
primaryTextTheme: TextTheme(
|
||||
title: TextStyle(
|
||||
color: Colors.white, // title color
|
||||
backgroundColor: PaletteDark.darkOceanBlue // textfield underline
|
||||
),
|
||||
caption: TextStyle(
|
||||
color: PaletteDark.darkCyanBlue, // secondary text
|
||||
decorationColor: PaletteDark.darkOceanBlue // menu divider
|
||||
),
|
||||
overline: TextStyle(
|
||||
color: PaletteDark.lightBlueGrey, // transaction/trade details titles
|
||||
decorationColor: Colors.grey, // placeholder
|
||||
),
|
||||
subhead: TextStyle(
|
||||
color: PaletteDark.darkNightBlue, // first gradient color (send page)
|
||||
decorationColor: PaletteDark.darkNightBlue // second gradient color (send page)
|
||||
),
|
||||
headline: TextStyle(
|
||||
color: PaletteDark.lightVioletBlue, // text field border color (send page)
|
||||
decorationColor: PaletteDark.darkCyanBlue, // text field hint color (send page)
|
||||
),
|
||||
display1: TextStyle(
|
||||
color: PaletteDark.buttonNightBlue, // text field button color (send page)
|
||||
decorationColor: PaletteDark.gray // text field button icon color (send page)
|
||||
),
|
||||
display2: TextStyle(
|
||||
color: Colors.white, // estimated fee (send page)
|
||||
decorationColor: PaletteDark.darkCyanBlue // template dotted border (send page)
|
||||
),
|
||||
display3: TextStyle(
|
||||
color: PaletteDark.darkCyanBlue, // template new text (send page)
|
||||
decorationColor: PaletteDark.darkVioletBlue // template background color (send page)
|
||||
),
|
||||
display4: TextStyle(
|
||||
color: PaletteDark.cyanBlue, // template title (send page)
|
||||
decorationColor: PaletteDark.darkCyanBlue // receive amount text (exchange page)
|
||||
),
|
||||
subtitle: TextStyle(
|
||||
color: PaletteDark.wildVioletBlue, // first gradient color top panel (exchange page)
|
||||
decorationColor: PaletteDark.wildVioletBlue // second gradient color top panel (exchange page)
|
||||
),
|
||||
body1: TextStyle(
|
||||
color: PaletteDark.darkNightBlue, // first gradient color bottom panel (exchange page)
|
||||
decorationColor: PaletteDark.darkNightBlue // second gradient color bottom panel (exchange page)
|
||||
),
|
||||
body2: TextStyle(
|
||||
color: PaletteDark.blueGrey, // text field border on top panel (exchange page)
|
||||
decorationColor: PaletteDark.moderateVioletBlue, // text field border on bottom panel (exchange page)
|
||||
)
|
||||
),
|
||||
focusColor: PaletteDark.moderateBlue, // text field button (exchange page)
|
||||
accentTextTheme: TextTheme(
|
||||
title: TextStyle(
|
||||
color: PaletteDark.nightBlue, // picker background
|
||||
backgroundColor: PaletteDark.dividerColor, // picker divider
|
||||
decorationColor: PaletteDark.darkNightBlue // dialog background
|
||||
),
|
||||
caption: TextStyle(
|
||||
color: PaletteDark.nightBlue, // container (confirm exchange)
|
||||
backgroundColor: PaletteDark.deepVioletBlue, // button background (confirm exchange)
|
||||
decorationColor: Palette.darkLavender, // text color (information page)
|
||||
),
|
||||
subtitle: TextStyle(
|
||||
//color: PaletteDark.lightBlueGrey, // QR code (exchange trade page)
|
||||
color: Colors.white, // QR code (exchange trade page)
|
||||
backgroundColor: PaletteDark.deepVioletBlue, // divider (exchange trade page)
|
||||
decorationColor: Colors.white // crete new wallet button background (wallet list page)
|
||||
),
|
||||
headline: TextStyle(
|
||||
color: PaletteDark.distantBlue, // first gradient color of wallet action buttons (wallet list page)
|
||||
backgroundColor: PaletteDark.distantNightBlue, // second gradient color of wallet action buttons (wallet list page)
|
||||
decorationColor: Palette.darkBlueCraiola // restore wallet button text color (wallet list page)
|
||||
),
|
||||
subhead: TextStyle(
|
||||
color: Colors.white, // titles color (filter widget)
|
||||
backgroundColor: PaletteDark.darkOceanBlue, // divider color (filter widget)
|
||||
decorationColor: PaletteDark.wildVioletBlue.withOpacity(0.3) // checkbox background (filter widget)
|
||||
),
|
||||
overline: TextStyle(
|
||||
color: PaletteDark.wildVioletBlue, // checkbox bounds (filter widget)
|
||||
decorationColor: PaletteDark.darkCyanBlue, // menu subname
|
||||
),
|
||||
display1: TextStyle(
|
||||
color: PaletteDark.deepPurpleBlue, // first gradient color (menu header)
|
||||
decorationColor: PaletteDark.deepPurpleBlue // second gradient color(menu header)
|
||||
),
|
||||
display2: TextStyle(
|
||||
color: PaletteDark.nightBlue, // action button color (address text field)
|
||||
decorationColor: PaletteDark.darkCyanBlue // hint text (seed widget)
|
||||
),
|
||||
display3: TextStyle(
|
||||
color: PaletteDark.cyanBlue, // hint text (new wallet page)
|
||||
decorationColor: PaletteDark.darkGrey // underline (new wallet page)
|
||||
),
|
||||
display4: TextStyle(
|
||||
color: PaletteDark.deepVioletBlue, // switch background (settings page)
|
||||
),
|
||||
body1: TextStyle(
|
||||
color: PaletteDark.indicatorVioletBlue, // indicators (PIN code)
|
||||
decorationColor: PaletteDark.lightPurpleBlue // switch (PIN code)
|
||||
),
|
||||
body2: TextStyle(
|
||||
color: Palette.blueCraiola, // primary buttons, alert right buttons
|
||||
decorationColor: Palette.alizarinRed // alert left button
|
||||
),
|
||||
),
|
||||
cardColor: PaletteDark.darkNightBlue // bottom button (action list)
|
||||
);
|
||||
}
|
197
lib/themes/bright_theme.dart
Normal file
|
@ -0,0 +1,197 @@
|
|||
import 'package:cake_wallet/themes/theme_base.dart';
|
||||
import 'package:cake_wallet/generated/i18n.dart';
|
||||
import 'package:cake_wallet/palette.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
class BrightTheme extends ThemeBase {
|
||||
BrightTheme({@required int raw}) : super(raw: raw);
|
||||
|
||||
@override
|
||||
String get title => S.current.bright_theme;
|
||||
|
||||
@override
|
||||
ThemeType get type => ThemeType.bright;
|
||||
|
||||
@override
|
||||
ThemeData get themeData => ThemeData(
|
||||
fontFamily: 'Lato',
|
||||
brightness: Brightness.light,
|
||||
backgroundColor: Colors.white,
|
||||
accentColor: Palette.blueCraiola, // first gradient color
|
||||
scaffoldBackgroundColor: Palette.pinkFlamingo, // second gradient color
|
||||
primaryColor: Palette.redHat, // third gradient color
|
||||
buttonColor: Colors.white.withOpacity(0.2), // action buttons on dashboard page
|
||||
indicatorColor: Colors.white.withOpacity(0.5), // page indicator
|
||||
hoverColor: Colors.white, // amount hint text (receive page)
|
||||
dividerColor: Palette.paleBlue,
|
||||
hintColor: Palette.gray,
|
||||
textTheme: TextTheme(
|
||||
title: TextStyle(
|
||||
color: Colors.white, // sync_indicator text
|
||||
backgroundColor: Colors.white.withOpacity(0.2), // synced sync_indicator
|
||||
decorationColor: Colors.white.withOpacity(0.15), // not synced sync_indicator
|
||||
),
|
||||
caption: TextStyle(
|
||||
color: Palette.shineOrange, // not synced light
|
||||
decorationColor: Colors.white, // filter icon
|
||||
),
|
||||
overline: TextStyle(
|
||||
color: Colors.white.withOpacity(0.2), // filter button
|
||||
backgroundColor: Colors.white.withOpacity(0.5), // date section row
|
||||
decorationColor: Colors.white.withOpacity(0.2) // icons (transaction and trade rows)
|
||||
),
|
||||
subhead: TextStyle(
|
||||
color: Colors.white.withOpacity(0.2), // address button border
|
||||
decorationColor: Colors.white.withOpacity(0.4), // copy button (qr widget)
|
||||
),
|
||||
headline: TextStyle(
|
||||
color: Colors.white, // qr code
|
||||
decorationColor: Colors.white.withOpacity(0.5), // bottom border of amount (receive page)
|
||||
),
|
||||
display1: TextStyle(
|
||||
color: PaletteDark.lightBlueGrey, // icons color (receive page)
|
||||
decorationColor: Palette.lavender, // icons background (receive page)
|
||||
),
|
||||
display2: TextStyle(
|
||||
color: Palette.darkBlueCraiola, // text color of tiles (receive page)
|
||||
decorationColor: Colors.white // background of tiles (receive page)
|
||||
),
|
||||
display3: TextStyle(
|
||||
color: Colors.white, // text color of current tile (receive page),
|
||||
//decorationColor: Palette.blueCraiola // background of current tile (receive page)
|
||||
decorationColor: Palette.moderateSlateBlue // background of current tile (receive page)
|
||||
),
|
||||
display4: TextStyle(
|
||||
color: Palette.violetBlue, // text color of tiles (account list)
|
||||
decorationColor: Colors.white // background of tiles (account list)
|
||||
),
|
||||
subtitle: TextStyle(
|
||||
color: Palette.moderateSlateBlue, // text color of current tile (account list)
|
||||
decorationColor: Colors.white // background of current tile (account list)
|
||||
),
|
||||
body1: TextStyle(
|
||||
color: Palette.moderatePurpleBlue, // scrollbar thumb
|
||||
decorationColor: Palette.periwinkleCraiola // scrollbar background
|
||||
),
|
||||
body2: TextStyle(
|
||||
color: Palette.moderateLavender, // menu header
|
||||
decorationColor: Colors.white, // menu background
|
||||
)
|
||||
),
|
||||
primaryTextTheme: TextTheme(
|
||||
title: TextStyle(
|
||||
color: Palette.darkBlueCraiola, // title color
|
||||
backgroundColor: Palette.wildPeriwinkle // textfield underline
|
||||
),
|
||||
caption: TextStyle(
|
||||
color: PaletteDark.pigeonBlue, // secondary text
|
||||
decorationColor: Palette.wildLavender // menu divider
|
||||
),
|
||||
overline: TextStyle(
|
||||
color: Palette.darkGray, // transaction/trade details titles
|
||||
decorationColor: Colors.white.withOpacity(0.5), // placeholder
|
||||
),
|
||||
subhead: TextStyle(
|
||||
color: Palette.blueCraiola, // first gradient color (send page)
|
||||
decorationColor: Palette.pinkFlamingo // second gradient color (send page)
|
||||
),
|
||||
headline: TextStyle(
|
||||
color: Colors.white.withOpacity(0.5), // text field border color (send page)
|
||||
decorationColor: Colors.white.withOpacity(0.5), // text field hint color (send page)
|
||||
),
|
||||
display1: TextStyle(
|
||||
color: Colors.white.withOpacity(0.2), // text field button color (send page)
|
||||
decorationColor: Colors.white // text field button icon color (send page)
|
||||
),
|
||||
display2: TextStyle(
|
||||
color: Colors.white.withOpacity(0.5), // estimated fee (send page)
|
||||
decorationColor: Palette.shadowWhite // template dotted border (send page)
|
||||
),
|
||||
display3: TextStyle(
|
||||
color: Palette.darkBlueCraiola, // template new text (send page)
|
||||
decorationColor: Palette.shadowWhite // template background color (send page)
|
||||
),
|
||||
display4: TextStyle(
|
||||
color: Palette.darkBlueCraiola, // template title (send page)
|
||||
decorationColor: Palette.niagara // receive amount text (exchange page)
|
||||
),
|
||||
subtitle: TextStyle(
|
||||
color: Palette.blueCraiola, // first gradient color top panel (exchange page)
|
||||
decorationColor: Palette.pinkFlamingo // second gradient color top panel (exchange page)
|
||||
),
|
||||
body1: TextStyle(
|
||||
color: Palette.blueCraiola.withOpacity(0.7), // first gradient color bottom panel (exchange page)
|
||||
decorationColor: Palette.pinkFlamingo.withOpacity(0.7), // second gradient color bottom panel (exchange page)
|
||||
backgroundColor: Palette.moderateSlateBlue // alert right button text
|
||||
),
|
||||
body2: TextStyle(
|
||||
color: Colors.white.withOpacity(0.5), // text field border on top panel (exchange page)
|
||||
decorationColor: Colors.white.withOpacity(0.5), // text field border on bottom panel (exchange page)
|
||||
backgroundColor: Palette.brightOrange // alert left button text
|
||||
)
|
||||
),
|
||||
focusColor: Colors.white.withOpacity(0.2), // text field button (exchange page)
|
||||
accentTextTheme: TextTheme(
|
||||
title: TextStyle(
|
||||
color: Colors.white, // picker background
|
||||
backgroundColor: Palette.periwinkleCraiola, // picker divider
|
||||
decorationColor: Colors.white // dialog background
|
||||
),
|
||||
caption: TextStyle(
|
||||
color: Palette.moderateLavender, // container (confirm exchange)
|
||||
backgroundColor: Palette.moderateLavender, // button background (confirm exchange)
|
||||
decorationColor: Palette.darkBlueCraiola, // text color (information page)
|
||||
),
|
||||
subtitle: TextStyle(
|
||||
color: Palette.darkBlueCraiola, // QR code (exchange trade page)
|
||||
backgroundColor: Palette.wildPeriwinkle, // divider (exchange trade page)
|
||||
//decorationColor: Palette.blueCraiola // crete new wallet button background (wallet list page)
|
||||
decorationColor: Palette.moderateSlateBlue // crete new wallet button background (wallet list page)
|
||||
),
|
||||
headline: TextStyle(
|
||||
color: Palette.moderateLavender, // first gradient color of wallet action buttons (wallet list page)
|
||||
backgroundColor: Palette.moderateLavender, // second gradient color of wallet action buttons (wallet list page)
|
||||
decorationColor: Colors.white // restore wallet button text color (wallet list page)
|
||||
),
|
||||
subhead: TextStyle(
|
||||
color: Palette.darkGray, // titles color (filter widget)
|
||||
backgroundColor: Palette.periwinkle, // divider color (filter widget)
|
||||
decorationColor: Colors.white // checkbox background (filter widget)
|
||||
),
|
||||
overline: TextStyle(
|
||||
color: Palette.wildPeriwinkle, // checkbox bounds (filter widget)
|
||||
decorationColor: Colors.white, // menu subname
|
||||
),
|
||||
display1: TextStyle(
|
||||
color: Palette.blueCraiola, // first gradient color (menu header)
|
||||
decorationColor: Palette.pinkFlamingo, // second gradient color(menu header)
|
||||
backgroundColor: Colors.white // active dot color
|
||||
),
|
||||
display2: TextStyle(
|
||||
color: Palette.shadowWhite, // action button color (address text field)
|
||||
decorationColor: Palette.darkGray, // hint text (seed widget)
|
||||
backgroundColor: Colors.white.withOpacity(0.5) // text on balance page
|
||||
),
|
||||
display3: TextStyle(
|
||||
color: Palette.darkGray, // hint text (new wallet page)
|
||||
decorationColor: Palette.periwinkleCraiola, // underline (new wallet page)
|
||||
backgroundColor: Colors.white // menu, icons, balance (dashboard page)
|
||||
),
|
||||
display4: TextStyle(
|
||||
color: Palette.darkGray, // switch background (settings page)
|
||||
decorationColor: Colors.white.withOpacity(0.4) // hint text (exchange page)
|
||||
),
|
||||
body1: TextStyle(
|
||||
color: Palette.darkGray, // indicators (PIN code)
|
||||
decorationColor: Palette.darkGray, // switch (PIN code)
|
||||
backgroundColor: Colors.white // alert right button
|
||||
),
|
||||
body2: TextStyle(
|
||||
color: Palette.moderateSlateBlue, // primary buttons
|
||||
decorationColor: Colors.white, // alert left button,
|
||||
backgroundColor: Palette.dullGray // keyboard bar color
|
||||
),
|
||||
),
|
||||
cardColor: Palette.moderateSlateBlue // bottom button (action list)
|
||||
);
|
||||
}
|
196
lib/themes/dark_theme.dart
Normal file
|
@ -0,0 +1,196 @@
|
|||
import 'package:cake_wallet/themes/theme_base.dart';
|
||||
import 'package:cake_wallet/generated/i18n.dart';
|
||||
import 'package:cake_wallet/palette.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
class DarkTheme extends ThemeBase {
|
||||
DarkTheme({@required int raw}) : super(raw: raw);
|
||||
|
||||
@override
|
||||
String get title => S.current.dark_theme;
|
||||
|
||||
@override
|
||||
ThemeType get type => ThemeType.dark;
|
||||
|
||||
@override
|
||||
ThemeData get themeData => ThemeData(
|
||||
fontFamily: 'Lato',
|
||||
brightness: Brightness.dark,
|
||||
backgroundColor: PaletteDark.backgroundColor,
|
||||
accentColor: PaletteDark.backgroundColor, // first gradient color
|
||||
scaffoldBackgroundColor: PaletteDark.backgroundColor, // second gradient color
|
||||
primaryColor: PaletteDark.backgroundColor, // third gradient color
|
||||
buttonColor: PaletteDark.nightBlue, // action buttons on dashboard page
|
||||
indicatorColor: PaletteDark.cyanBlue, // page indicator
|
||||
hoverColor: PaletteDark.cyanBlue, // amount hint text (receive page)
|
||||
dividerColor: PaletteDark.dividerColor,
|
||||
hintColor: PaletteDark.pigeonBlue, // menu
|
||||
textTheme: TextTheme(
|
||||
title: TextStyle(
|
||||
color: PaletteDark.wildBlue, // sync_indicator text
|
||||
backgroundColor: PaletteDark.lightNightBlue, // synced sync_indicator
|
||||
decorationColor: PaletteDark.oceanBlue // not synced sync_indicator
|
||||
),
|
||||
caption: TextStyle(
|
||||
color: PaletteDark.orangeYellow, // not synced light
|
||||
decorationColor: PaletteDark.wildBlue, // filter icon
|
||||
),
|
||||
overline: TextStyle(
|
||||
color: PaletteDark.oceanBlue, // filter button
|
||||
backgroundColor: PaletteDark.darkCyanBlue, // date section row
|
||||
decorationColor: PaletteDark.wildNightBlue // icons (transaction and trade rows)
|
||||
),
|
||||
subhead: TextStyle(
|
||||
color: PaletteDark.nightBlue, // address button border
|
||||
decorationColor: PaletteDark.lightBlueGrey, // copy button (qr widget)
|
||||
),
|
||||
headline: TextStyle(
|
||||
color: PaletteDark.lightBlueGrey, // qr code
|
||||
decorationColor: PaletteDark.darkGrey, // bottom border of amount (receive page)
|
||||
),
|
||||
display1: TextStyle(
|
||||
color: Colors.white, // icons color (receive page)
|
||||
decorationColor: PaletteDark.distantNightBlue, // icons background (receive page)
|
||||
),
|
||||
display2: TextStyle(
|
||||
color: Colors.white, // text color of tiles (receive page)
|
||||
decorationColor: PaletteDark.nightBlue // background of tiles (receive page)
|
||||
),
|
||||
display3: TextStyle(
|
||||
color: Palette.blueCraiola, // text color of current tile (receive page)
|
||||
decorationColor: PaletteDark.lightOceanBlue // background of current tile (receive page)
|
||||
),
|
||||
display4: TextStyle(
|
||||
color: Colors.white, // text color of tiles (account list)
|
||||
decorationColor: PaletteDark.darkOceanBlue // background of tiles (account list)
|
||||
),
|
||||
subtitle: TextStyle(
|
||||
color: Palette.blueCraiola, // text color of current tile (account list)
|
||||
decorationColor: PaletteDark.darkNightBlue // background of current tile (account list)
|
||||
),
|
||||
body1: TextStyle(
|
||||
color: PaletteDark.wildBlueGrey, // scrollbar thumb
|
||||
decorationColor: PaletteDark.violetBlue // scrollbar background
|
||||
),
|
||||
body2: TextStyle(
|
||||
color: PaletteDark.deepPurpleBlue, // menu header
|
||||
decorationColor: PaletteDark.deepPurpleBlue, // menu background
|
||||
)
|
||||
),
|
||||
primaryTextTheme: TextTheme(
|
||||
title: TextStyle(
|
||||
color: Colors.white, // title color
|
||||
backgroundColor: PaletteDark.darkOceanBlue // textfield underline
|
||||
),
|
||||
caption: TextStyle(
|
||||
color: PaletteDark.darkCyanBlue, // secondary text
|
||||
decorationColor: PaletteDark.darkOceanBlue // menu divider
|
||||
),
|
||||
overline: TextStyle(
|
||||
color: PaletteDark.lightBlueGrey, // transaction/trade details titles
|
||||
decorationColor: Colors.grey, // placeholder
|
||||
),
|
||||
subhead: TextStyle(
|
||||
color: PaletteDark.darkNightBlue, // first gradient color (send page)
|
||||
decorationColor: PaletteDark.darkNightBlue // second gradient color (send page)
|
||||
),
|
||||
headline: TextStyle(
|
||||
color: PaletteDark.lightVioletBlue, // text field border color (send page)
|
||||
decorationColor: PaletteDark.darkCyanBlue, // text field hint color (send page)
|
||||
),
|
||||
display1: TextStyle(
|
||||
color: PaletteDark.buttonNightBlue, // text field button color (send page)
|
||||
decorationColor: PaletteDark.gray // text field button icon color (send page)
|
||||
),
|
||||
display2: TextStyle(
|
||||
color: Colors.white, // estimated fee (send page)
|
||||
decorationColor: PaletteDark.darkCyanBlue // template dotted border (send page)
|
||||
),
|
||||
display3: TextStyle(
|
||||
color: PaletteDark.darkCyanBlue, // template new text (send page)
|
||||
decorationColor: PaletteDark.darkVioletBlue // template background color (send page)
|
||||
),
|
||||
display4: TextStyle(
|
||||
color: PaletteDark.cyanBlue, // template title (send page)
|
||||
decorationColor: PaletteDark.darkCyanBlue // receive amount text (exchange page)
|
||||
),
|
||||
subtitle: TextStyle(
|
||||
color: PaletteDark.wildVioletBlue, // first gradient color top panel (exchange page)
|
||||
decorationColor: PaletteDark.wildVioletBlue // second gradient color top panel (exchange page)
|
||||
),
|
||||
body1: TextStyle(
|
||||
color: PaletteDark.darkNightBlue, // first gradient color bottom panel (exchange page)
|
||||
decorationColor: PaletteDark.darkNightBlue, // second gradient color bottom panel (exchange page)
|
||||
backgroundColor: Palette.blueCraiola // alert right button text
|
||||
),
|
||||
body2: TextStyle(
|
||||
color: PaletteDark.blueGrey, // text field border on top panel (exchange page)
|
||||
decorationColor: PaletteDark.moderateVioletBlue, // text field border on bottom panel (exchange page)
|
||||
backgroundColor: Palette.alizarinRed // alert left button text
|
||||
)
|
||||
),
|
||||
focusColor: PaletteDark.moderateBlue, // text field button (exchange page)
|
||||
accentTextTheme: TextTheme(
|
||||
title: TextStyle(
|
||||
color: PaletteDark.nightBlue, // picker background
|
||||
backgroundColor: PaletteDark.dividerColor, // picker divider
|
||||
decorationColor: PaletteDark.darkNightBlue // dialog background
|
||||
),
|
||||
caption: TextStyle(
|
||||
color: PaletteDark.nightBlue, // container (confirm exchange)
|
||||
backgroundColor: PaletteDark.deepVioletBlue, // button background (confirm exchange)
|
||||
decorationColor: Palette.darkLavender, // text color (information page)
|
||||
),
|
||||
subtitle: TextStyle(
|
||||
//color: PaletteDark.lightBlueGrey, // QR code (exchange trade page)
|
||||
color: Colors.white, // QR code (exchange trade page)
|
||||
backgroundColor: PaletteDark.deepVioletBlue, // divider (exchange trade page)
|
||||
decorationColor: Colors.white // crete new wallet button background (wallet list page)
|
||||
),
|
||||
headline: TextStyle(
|
||||
color: PaletteDark.distantBlue, // first gradient color of wallet action buttons (wallet list page)
|
||||
backgroundColor: PaletteDark.distantNightBlue, // second gradient color of wallet action buttons (wallet list page)
|
||||
decorationColor: Palette.darkBlueCraiola // restore wallet button text color (wallet list page)
|
||||
),
|
||||
subhead: TextStyle(
|
||||
color: Colors.white, // titles color (filter widget)
|
||||
backgroundColor: PaletteDark.darkOceanBlue, // divider color (filter widget)
|
||||
decorationColor: PaletteDark.wildVioletBlue.withOpacity(0.3) // checkbox background (filter widget)
|
||||
),
|
||||
overline: TextStyle(
|
||||
color: PaletteDark.wildVioletBlue, // checkbox bounds (filter widget)
|
||||
decorationColor: PaletteDark.darkCyanBlue, // menu subname
|
||||
),
|
||||
display1: TextStyle(
|
||||
color: PaletteDark.deepPurpleBlue, // first gradient color (menu header)
|
||||
decorationColor: PaletteDark.deepPurpleBlue, // second gradient color(menu header)
|
||||
backgroundColor: Colors.white // active dot color
|
||||
),
|
||||
display2: TextStyle(
|
||||
color: PaletteDark.nightBlue, // action button color (address text field)
|
||||
decorationColor: PaletteDark.darkCyanBlue, // hint text (seed widget)
|
||||
backgroundColor: PaletteDark.cyanBlue // text on balance page
|
||||
),
|
||||
display3: TextStyle(
|
||||
color: PaletteDark.cyanBlue, // hint text (new wallet page)
|
||||
decorationColor: PaletteDark.darkGrey, // underline (new wallet page)
|
||||
backgroundColor: Colors.white // menu, icons, balance (dashboard page)
|
||||
),
|
||||
display4: TextStyle(
|
||||
color: PaletteDark.deepVioletBlue, // switch background (settings page)
|
||||
decorationColor: PaletteDark.lightBlueGrey // hint text (exchange page)
|
||||
),
|
||||
body1: TextStyle(
|
||||
color: PaletteDark.indicatorVioletBlue, // indicators (PIN code)
|
||||
decorationColor: PaletteDark.lightPurpleBlue, // switch (PIN code)
|
||||
backgroundColor: PaletteDark.darkNightBlue // alert right button
|
||||
),
|
||||
body2: TextStyle(
|
||||
color: Palette.blueCraiola, // primary buttons
|
||||
decorationColor: PaletteDark.darkNightBlue, // alert left button
|
||||
backgroundColor: PaletteDark.granite // keyboard bar color
|
||||
),
|
||||
),
|
||||
cardColor: PaletteDark.darkNightBlue // bottom button (action list)
|
||||
);
|
||||
}
|
196
lib/themes/light_theme.dart
Normal file
|
@ -0,0 +1,196 @@
|
|||
import 'package:cake_wallet/themes/theme_base.dart';
|
||||
import 'package:cake_wallet/generated/i18n.dart';
|
||||
import 'package:cake_wallet/palette.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
class LightTheme extends ThemeBase {
|
||||
LightTheme({@required int raw}) : super(raw: raw);
|
||||
|
||||
@override
|
||||
String get title => S.current.light_theme;
|
||||
|
||||
@override
|
||||
ThemeType get type => ThemeType.light;
|
||||
|
||||
@override
|
||||
ThemeData get themeData => ThemeData(
|
||||
fontFamily: 'Lato',
|
||||
brightness: Brightness.light,
|
||||
backgroundColor: Colors.white,
|
||||
accentColor: Colors.white, // first gradient color
|
||||
scaffoldBackgroundColor: Colors.white, // second gradient color
|
||||
primaryColor: Colors.white, // third gradient color
|
||||
buttonColor: Palette.blueAlice, // action buttons on dashboard page
|
||||
indicatorColor: PaletteDark.darkCyanBlue.withOpacity(0.67), // page indicator
|
||||
hoverColor: Palette.darkBlueCraiola, // amount hint text (receive page)
|
||||
dividerColor: Palette.paleBlue,
|
||||
hintColor: Palette.gray,
|
||||
textTheme: TextTheme(
|
||||
title: TextStyle(
|
||||
color: Palette.darkBlueCraiola, // sync_indicator text
|
||||
backgroundColor: Palette.blueAlice, // synced sync_indicator
|
||||
decorationColor: Palette.blueAlice.withOpacity(0.75), // not synced sync_indicator
|
||||
),
|
||||
caption: TextStyle(
|
||||
color: Palette.shineOrange, // not synced light
|
||||
decorationColor: PaletteDark.wildBlue, // filter icon
|
||||
),
|
||||
overline: TextStyle(
|
||||
color: Palette.blueAlice, // filter button
|
||||
backgroundColor: PaletteDark.darkCyanBlue, // date section row
|
||||
decorationColor: Palette.blueAlice // icons (transaction and trade rows)
|
||||
),
|
||||
subhead: TextStyle(
|
||||
color: Palette.blueAlice, // address button border
|
||||
decorationColor: PaletteDark.lightBlueGrey, // copy button (qr widget)
|
||||
),
|
||||
headline: TextStyle(
|
||||
color: Colors.white, // qr code
|
||||
decorationColor: Palette.darkBlueCraiola, // bottom border of amount (receive page)
|
||||
),
|
||||
display1: TextStyle(
|
||||
color: PaletteDark.lightBlueGrey, // icons color (receive page)
|
||||
decorationColor: Palette.moderateLavender, // icons background (receive page)
|
||||
),
|
||||
display2: TextStyle(
|
||||
color: Palette.darkBlueCraiola, // text color of tiles (receive page)
|
||||
decorationColor: Palette.blueAlice // background of tiles (receive page)
|
||||
),
|
||||
display3: TextStyle(
|
||||
color: Colors.white, // text color of current tile (receive page),
|
||||
//decorationColor: Palette.blueCraiola // background of current tile (receive page)
|
||||
decorationColor: Palette.blueCraiola // background of current tile (receive page)
|
||||
),
|
||||
display4: TextStyle(
|
||||
color: Palette.violetBlue, // text color of tiles (account list)
|
||||
decorationColor: Colors.white // background of tiles (account list)
|
||||
),
|
||||
subtitle: TextStyle(
|
||||
color: Palette.protectiveBlue, // text color of current tile (account list)
|
||||
decorationColor: Colors.white // background of current tile (account list)
|
||||
),
|
||||
body1: TextStyle(
|
||||
color: Palette.moderatePurpleBlue, // scrollbar thumb
|
||||
decorationColor: Palette.periwinkleCraiola // scrollbar background
|
||||
),
|
||||
body2: TextStyle(
|
||||
color: Palette.moderateLavender, // menu header
|
||||
decorationColor: Colors.white, // menu background
|
||||
)
|
||||
),
|
||||
primaryTextTheme: TextTheme(
|
||||
title: TextStyle(
|
||||
color: Palette.darkBlueCraiola, // title color
|
||||
backgroundColor: Palette.wildPeriwinkle // textfield underline
|
||||
),
|
||||
caption: TextStyle(
|
||||
color: PaletteDark.pigeonBlue, // secondary text
|
||||
decorationColor: Palette.wildLavender // menu divider
|
||||
),
|
||||
overline: TextStyle(
|
||||
color: Palette.darkGray, // transaction/trade details titles
|
||||
decorationColor: PaletteDark.darkCyanBlue, // placeholder
|
||||
),
|
||||
subhead: TextStyle(
|
||||
color: Palette.blueCraiola, // first gradient color (send page)
|
||||
decorationColor: Palette.blueGreyCraiola // second gradient color (send page)
|
||||
),
|
||||
headline: TextStyle(
|
||||
color: Colors.white.withOpacity(0.5), // text field border color (send page)
|
||||
decorationColor: Colors.white.withOpacity(0.5), // text field hint color (send page)
|
||||
),
|
||||
display1: TextStyle(
|
||||
color: Colors.white.withOpacity(0.2), // text field button color (send page)
|
||||
decorationColor: Colors.white // text field button icon color (send page)
|
||||
),
|
||||
display2: TextStyle(
|
||||
color: Colors.white.withOpacity(0.5), // estimated fee (send page)
|
||||
decorationColor: Palette.moderateLavender // template dotted border (send page)
|
||||
),
|
||||
display3: TextStyle(
|
||||
color: Palette.darkBlueCraiola, // template new text (send page)
|
||||
decorationColor: Palette.blueAlice // template background color (send page)
|
||||
),
|
||||
display4: TextStyle(
|
||||
color: Palette.darkBlueCraiola, // template title (send page)
|
||||
decorationColor: Palette.niagara // receive amount text (exchange page)
|
||||
),
|
||||
subtitle: TextStyle(
|
||||
color: Palette.blueCraiola, // first gradient color top panel (exchange page)
|
||||
decorationColor: Palette.blueGreyCraiola // second gradient color top panel (exchange page)
|
||||
),
|
||||
body1: TextStyle(
|
||||
color: Palette.blueCraiola.withOpacity(0.7), // first gradient color bottom panel (exchange page)
|
||||
decorationColor: Palette.blueGreyCraiola.withOpacity(0.7), // second gradient color bottom panel (exchange page)
|
||||
backgroundColor: Palette.protectiveBlue // alert right button text
|
||||
),
|
||||
body2: TextStyle(
|
||||
color: Colors.white.withOpacity(0.5), // text field border on top panel (exchange page)
|
||||
decorationColor: Colors.white.withOpacity(0.5), // text field border on bottom panel (exchange page)
|
||||
backgroundColor: Palette.brightOrange // alert left button text
|
||||
)
|
||||
),
|
||||
focusColor: Colors.white.withOpacity(0.2), // text field button (exchange page)
|
||||
accentTextTheme: TextTheme(
|
||||
title: TextStyle(
|
||||
color: Colors.white, // picker background
|
||||
backgroundColor: Palette.periwinkleCraiola, // picker divider
|
||||
decorationColor: Colors.white // dialog background
|
||||
),
|
||||
caption: TextStyle(
|
||||
color: Palette.blueAlice, // container (confirm exchange)
|
||||
backgroundColor: Palette.blueAlice, // button background (confirm exchange)
|
||||
decorationColor: Palette.darkBlueCraiola, // text color (information page)
|
||||
),
|
||||
subtitle: TextStyle(
|
||||
color: Palette.darkBlueCraiola, // QR code (exchange trade page)
|
||||
backgroundColor: Palette.wildPeriwinkle, // divider (exchange trade page)
|
||||
decorationColor: Palette.protectiveBlue // crete new wallet button background (wallet list page)
|
||||
),
|
||||
headline: TextStyle(
|
||||
color: Palette.moderateLavender, // first gradient color of wallet action buttons (wallet list page)
|
||||
backgroundColor: Palette.moderateLavender, // second gradient color of wallet action buttons (wallet list page)
|
||||
decorationColor: Colors.white // restore wallet button text color (wallet list page)
|
||||
),
|
||||
subhead: TextStyle(
|
||||
color: Palette.darkGray, // titles color (filter widget)
|
||||
backgroundColor: Palette.periwinkle, // divider color (filter widget)
|
||||
decorationColor: Colors.white // checkbox background (filter widget)
|
||||
),
|
||||
overline: TextStyle(
|
||||
color: Palette.wildPeriwinkle, // checkbox bounds (filter widget)
|
||||
decorationColor: Colors.white, // menu subname
|
||||
),
|
||||
display1: TextStyle(
|
||||
color: Palette.blueCraiola, // first gradient color (menu header)
|
||||
decorationColor: Palette.blueGreyCraiola, // second gradient color(menu header)
|
||||
backgroundColor: PaletteDark.darkNightBlue // active dot color
|
||||
),
|
||||
display2: TextStyle(
|
||||
color: Palette.shadowWhite, // action button color (address text field)
|
||||
decorationColor: Palette.darkGray, // hint text (seed widget)
|
||||
backgroundColor: Palette.darkBlueCraiola.withOpacity(0.67) // text on balance page
|
||||
),
|
||||
display3: TextStyle(
|
||||
color: Palette.darkGray, // hint text (new wallet page)
|
||||
decorationColor: Palette.periwinkleCraiola, // underline (new wallet page)
|
||||
backgroundColor: Palette.darkBlueCraiola // menu, icons, balance (dashboard page)
|
||||
),
|
||||
display4: TextStyle(
|
||||
color: Palette.darkGray, // switch background (settings page)
|
||||
decorationColor: Colors.white.withOpacity(0.4) // hint text (exchange page)
|
||||
),
|
||||
body1: TextStyle(
|
||||
color: Palette.darkGray, // indicators (PIN code)
|
||||
decorationColor: Palette.darkGray, // switch (PIN code)
|
||||
backgroundColor: Colors.white // alert right button
|
||||
),
|
||||
body2: TextStyle(
|
||||
color: Palette.protectiveBlue, // primary buttons
|
||||
decorationColor: Colors.white, // alert left button,
|
||||
backgroundColor: Palette.dullGray // keyboard bar color
|
||||
),
|
||||
),
|
||||
cardColor: Palette.protectiveBlue // bottom button (action list)
|
||||
);
|
||||
}
|
17
lib/themes/theme_base.dart
Normal file
|
@ -0,0 +1,17 @@
|
|||
import 'package:flutter/material.dart';
|
||||
|
||||
enum ThemeType {light, bright, dark}
|
||||
|
||||
abstract class ThemeBase {
|
||||
ThemeBase({@required this.raw});
|
||||
|
||||
final int raw;
|
||||
String get title;
|
||||
ThemeData get themeData;
|
||||
ThemeType get type;
|
||||
|
||||
@override
|
||||
String toString() {
|
||||
return title;
|
||||
}
|
||||
}
|
25
lib/themes/theme_list.dart
Normal file
|
@ -0,0 +1,25 @@
|
|||
import 'package:cake_wallet/themes/bright_theme.dart';
|
||||
import 'package:cake_wallet/themes/dark_theme.dart';
|
||||
import 'package:cake_wallet/themes/light_theme.dart';
|
||||
import 'package:cake_wallet/themes/theme_base.dart';
|
||||
|
||||
class ThemeList {
|
||||
static final all = [lightTheme, brightTheme, darkTheme];
|
||||
|
||||
static final lightTheme = LightTheme(raw: 0);
|
||||
static final brightTheme = BrightTheme(raw: 1);
|
||||
static final darkTheme = DarkTheme(raw: 2);
|
||||
|
||||
static ThemeBase deserialize({int raw}) {
|
||||
switch (raw) {
|
||||
case 0:
|
||||
return lightTheme;
|
||||
case 1:
|
||||
return brightTheme;
|
||||
case 2:
|
||||
return darkTheme;
|
||||
default:
|
||||
return null;
|
||||
}
|
||||
}
|
||||
}
|
|
@ -1,3 +1,5 @@
|
|||
import 'package:cake_wallet/themes/theme_base.dart';
|
||||
import 'package:cake_wallet/themes/theme_list.dart';
|
||||
import 'package:cake_wallet/src/screens/pin_code/pin_code_widget.dart';
|
||||
import 'package:flutter/cupertino.dart';
|
||||
import 'package:mobx/mobx.dart';
|
||||
|
@ -107,11 +109,12 @@ abstract class SettingsViewModelBase with Store {
|
|||
setAllowBiometricalAuthentication(value);
|
||||
}
|
||||
}),
|
||||
SwitcherListItem(
|
||||
title: S.current.settings_dark_mode,
|
||||
value: () => _settingsStore.isDarkTheme,
|
||||
onValueChange: (_, bool value) =>
|
||||
_settingsStore.isDarkTheme = value)
|
||||
PickerListItem(
|
||||
title: S.current.color_theme,
|
||||
items: ThemeList.all,
|
||||
selectedItem: () => theme,
|
||||
onItemSelected: (ThemeBase theme) =>
|
||||
_settingsStore.currentTheme = theme)
|
||||
],
|
||||
[
|
||||
LinkListItem(
|
||||
|
@ -187,6 +190,9 @@ abstract class SettingsViewModelBase with Store {
|
|||
bool get allowBiometricalAuthentication =>
|
||||
_settingsStore.allowBiometricalAuthentication;
|
||||
|
||||
@computed
|
||||
ThemeBase get theme => _settingsStore.currentTheme;
|
||||
|
||||
final Map<String, String> itemHeaders;
|
||||
List<List<SettingsListItem>> sections;
|
||||
final SettingsStore _settingsStore;
|
||||
|
|
|
@ -31,7 +31,7 @@ class MoneroURI extends PaymentURI {
|
|||
var base = 'monero:' + address;
|
||||
|
||||
if (amount?.isNotEmpty ?? false) {
|
||||
base += '?tx_amount=$amount';
|
||||
base += '?tx_amount=${amount.replaceAll(',', '.')}';
|
||||
}
|
||||
|
||||
return base;
|
||||
|
@ -47,7 +47,7 @@ class BitcoinURI extends PaymentURI {
|
|||
var base = 'bitcoin:' + address;
|
||||
|
||||
if (amount?.isNotEmpty ?? false) {
|
||||
base += '?amount=$amount';
|
||||
base += '?amount=${amount.replaceAll(',', '.')}';
|
||||
}
|
||||
|
||||
return base;
|
||||
|
|
|
@ -423,5 +423,10 @@
|
|||
|
||||
"provider_error" : "${provider} Error",
|
||||
|
||||
"use_ssl" : "Verwenden Sie SSL"
|
||||
"use_ssl" : "Verwenden Sie SSL",
|
||||
|
||||
"color_theme" : "Farbthema",
|
||||
"light_theme" : "Licht",
|
||||
"bright_theme" : "Hell",
|
||||
"dark_theme" : "Dunkel"
|
||||
}
|
|
@ -423,5 +423,10 @@
|
|||
|
||||
"provider_error" : "${provider} error",
|
||||
|
||||
"use_ssl" : "Use SSL"
|
||||
"use_ssl" : "Use SSL",
|
||||
|
||||
"color_theme" : "Color theme",
|
||||
"light_theme" : "Light",
|
||||
"bright_theme" : "Bright",
|
||||
"dark_theme" : "Dark"
|
||||
}
|
|
@ -423,5 +423,10 @@
|
|||
|
||||
"provider_error" : "${provider} error",
|
||||
|
||||
"use_ssl" : "Utilice SSL"
|
||||
"use_ssl" : "Utilice SSL",
|
||||
|
||||
"color_theme" : "Tema de color",
|
||||
"light_theme" : "Ligera",
|
||||
"bright_theme" : "Brillante",
|
||||
"dark_theme" : "Oscura"
|
||||
}
|
|
@ -423,5 +423,10 @@
|
|||
|
||||
"provider_error" : "${provider} त्रुटि",
|
||||
|
||||
"use_ssl" : "उपयोग SSL"
|
||||
"use_ssl" : "उपयोग SSL",
|
||||
|
||||
"color_theme" : "रंग विषय",
|
||||
"light_theme" : "रोशनी",
|
||||
"bright_theme" : "उज्ज्वल",
|
||||
"dark_theme" : "अंधेरा"
|
||||
}
|
|
@ -423,5 +423,10 @@
|
|||
|
||||
"provider_error" : "${provider} エラー",
|
||||
|
||||
"use_ssl" : "SSLを使用する"
|
||||
"use_ssl" : "SSLを使用する",
|
||||
|
||||
"color_theme" : "カラーテーマ",
|
||||
"light_theme" : "光",
|
||||
"bright_theme" : "明るい",
|
||||
"dark_theme" : "闇"
|
||||
}
|
|
@ -423,5 +423,10 @@
|
|||
|
||||
"provider_error" : "${provider} 오류",
|
||||
|
||||
"use_ssl" : "SSL 사용"
|
||||
"use_ssl" : "SSL 사용",
|
||||
|
||||
"color_theme" : "색상 테마",
|
||||
"light_theme" : "빛",
|
||||
"bright_theme" : "선명한",
|
||||
"dark_theme" : "어두운"
|
||||
}
|
|
@ -423,5 +423,10 @@
|
|||
|
||||
"provider_error" : "${provider} fout",
|
||||
|
||||
"use_ssl" : "Gebruik SSL"
|
||||
"use_ssl" : "Gebruik SSL",
|
||||
|
||||
"color_theme" : "Kleur thema",
|
||||
"light_theme" : "Licht",
|
||||
"bright_theme" : "Helder",
|
||||
"dark_theme" : "Donker"
|
||||
}
|
|
@ -423,5 +423,10 @@
|
|||
|
||||
"provider_error" : "${provider} pomyłka",
|
||||
|
||||
"use_ssl" : "Użyj SSL"
|
||||
"use_ssl" : "Użyj SSL",
|
||||
|
||||
"color_theme" : "Motyw kolorystyczny",
|
||||
"light_theme" : "Lekki",
|
||||
"bright_theme" : "Jasny",
|
||||
"dark_theme" : "Ciemny"
|
||||
}
|
|
@ -423,5 +423,10 @@
|
|||
|
||||
"provider_error" : "${provider} erro",
|
||||
|
||||
"use_ssl" : "Use SSL"
|
||||
"use_ssl" : "Use SSL",
|
||||
|
||||
"color_theme" : "Tema de cor",
|
||||
"light_theme" : "Luz",
|
||||
"bright_theme" : "Brilhante",
|
||||
"dark_theme" : "Sombria"
|
||||
}
|
||||
|
|
|
@ -423,5 +423,10 @@
|
|||
|
||||
"provider_error" : "${provider} ошибка",
|
||||
|
||||
"use_ssl" : "Использовать SSL"
|
||||
"use_ssl" : "Использовать SSL",
|
||||
|
||||
"color_theme" : "Цветовая тема",
|
||||
"light_theme" : "Светлая",
|
||||
"bright_theme" : "Яркая",
|
||||
"dark_theme" : "Темная"
|
||||
}
|
|
@ -423,5 +423,10 @@
|
|||
|
||||
"provider_error" : "${provider} помилка",
|
||||
|
||||
"use_ssl" : "Використати SSL"
|
||||
"use_ssl" : "Використати SSL",
|
||||
|
||||
"color_theme" : "Кольорова тема",
|
||||
"light_theme" : "Світла",
|
||||
"bright_theme" : "Яскрава",
|
||||
"dark_theme" : "Темна"
|
||||
}
|
|
@ -423,5 +423,10 @@
|
|||
|
||||
"provider_error" : "${provider} 錯誤",
|
||||
|
||||
"use_ssl" : "使用SSL"
|
||||
"use_ssl" : "使用SSL",
|
||||
|
||||
"color_theme" : "顏色主題",
|
||||
"light_theme" : "光",
|
||||
"bright_theme" : "亮",
|
||||
"dark_theme" : "黑暗"
|
||||
}
|