some clean up of assets.dart

This commit is contained in:
julian 2023-05-09 10:23:39 -06:00
parent 7da9f3b6e1
commit 789029a11f

View file

@ -4,8 +4,6 @@ import 'package:stackwallet/services/exchange/majestic_bank/majestic_bank_exchan
import 'package:stackwallet/services/exchange/simpleswap/simpleswap_exchange.dart';
import 'package:stackwallet/services/exchange/trocador/trocador_exchange.dart';
import 'package:stackwallet/utilities/enums/coin_enum.dart';
import 'package:stackwallet/utilities/theme/color_theme.dart';
import 'package:stackwallet/utilities/theme/stack_colors.dart';
abstract class Assets {
static const svg = _SVG();
@ -60,18 +58,11 @@ class _BUY {
const _BUY();
String simplexLogo(BuildContext context) {
switch (Theme.of(context).extension<StackColors>()!.themeType) {
case ThemeType.dark:
case ThemeType.oledBlack:
case ThemeType.darkChans:
switch (MediaQuery.of(context).platformBrightness) {
case Brightness.dark:
return "assets/svg/buy/Simplex-Nuvei-Logo-light.svg";
case ThemeType.fruitSorbet:
case ThemeType.forest:
case ThemeType.oceanBreeze:
case ThemeType.light:
case ThemeType.chan:
case ThemeType.orange:
case Brightness.light:
return "assets/svg/buy/Simplex-Nuvei-Logo.svg";
}
}
@ -93,55 +84,6 @@ class _SVG {
final coinControl = const _COIN_CONTROL();
String? background(BuildContext context) {
switch (Theme.of(context).extension<StackColors>()!.themeType) {
case ThemeType.light:
case ThemeType.chan:
case ThemeType.dark:
case ThemeType.orange:
case ThemeType.oledBlack:
case ThemeType.darkChans:
return null;
case ThemeType.oceanBreeze:
case ThemeType.fruitSorbet:
case ThemeType.forest:
return "${_path(context)}/bg.svg";
}
}
String bellNew(BuildContext context) => "${_path(context)}/bell-new.svg";
String stackIcon(BuildContext context) => "${_path(context)}/stack-icon1.svg";
String exchange(BuildContext context) => "${_path(context)}/exchange-2.svg";
String buy(BuildContext context) => "${_path(context)}/buy-coins-icon.svg";
String receive(BuildContext context) =>
"${_path(context)}/tx-icon-receive.svg";
String receivePending(BuildContext context) =>
"${_path(context)}/tx-icon-receive-pending.svg";
String receiveCancelled(BuildContext context) =>
"${_path(context)}/tx-icon-receive-failed.svg";
String send(BuildContext context) => "${_path(context)}/tx-icon-send.svg";
String sendPending(BuildContext context) =>
"${_path(context)}/tx-icon-send-pending.svg";
String sendCancelled(BuildContext context) =>
"${_path(context)}/tx-icon-send-failed.svg";
String txExchange(BuildContext context) =>
"${_path(context)}/tx-exchange-icon.svg";
String txExchangePending(BuildContext context) =>
"${_path(context)}/tx-exchange-icon-pending.svg";
String txExchangeFailed(BuildContext context) =>
"${_path(context)}/tx-exchange-icon-failed.svg";
String personaIncognito(BuildContext context) =>
"${_path(context)}/persona-incognito-1.svg";
String personaEasy(BuildContext context) =>
"${_path(context)}/persona-easy-1.svg";
String stack(BuildContext context) => "${_path(context)}/stack.svg";
String get themeFruit => "assets/svg/fruit-sorbet-theme.svg";
String get themeForest => "assets/svg/forest-theme.svg";
String get themeOledBlack => "assets/svg/oled-black-theme.svg";