mirror of
https://github.com/cypherstack/stack_wallet.git
synced 2024-12-23 03:49:22 +00:00
refactor
This commit is contained in:
parent
1582b0313a
commit
0175a8b894
7 changed files with 16 additions and 12 deletions
|
@ -200,8 +200,10 @@ class AppNameText extends StatelessWidget {
|
|||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Text(
|
||||
"{$WhiteLabel.appName}",
|
||||
// TODO [prio=high]: `'appName' can't be accessed using static access.`",
|
||||
WhiteLabel.appName,
|
||||
// TODO [prio=high]: appName is now static due to `'appName' can't be
|
||||
// accessed using static access.`", check that that doesn't cause issues
|
||||
// elsewhere.
|
||||
textAlign: TextAlign.center,
|
||||
style: !isDesktop
|
||||
? STextStyles.pageTitleH1(context)
|
||||
|
|
|
@ -89,7 +89,7 @@ class SupportView extends StatelessWidget {
|
|||
AboutItem(
|
||||
linkUrl: "https://discord.com/invite/mRPZuXx3At",
|
||||
label: "Discord",
|
||||
buttonText: "{$WhiteLabel.appName}",
|
||||
buttonText: WhiteLabel.appName,
|
||||
iconAsset: Assets.socials.discord,
|
||||
isDesktop: isDesktop,
|
||||
),
|
||||
|
|
|
@ -20,9 +20,9 @@ import 'package:stackwallet/providers/desktop/current_desktop_menu_item.dart';
|
|||
import 'package:stackwallet/themes/stack_colors.dart';
|
||||
import 'package:stackwallet/utilities/assets.dart';
|
||||
import 'package:stackwallet/utilities/text_styles.dart';
|
||||
import 'package:stackwallet/whiteLabel.dart';
|
||||
import 'package:stackwallet/widgets/desktop/desktop_tor_status_button.dart';
|
||||
import 'package:stackwallet/widgets/desktop/living_stack_icon.dart';
|
||||
import 'package:stackwallet/whiteLabel.dart';
|
||||
|
||||
enum DesktopMenuItemId {
|
||||
myStack,
|
||||
|
@ -139,7 +139,7 @@ class _DesktopMenuState extends ConsumerState<DesktopMenu> {
|
|||
child: SizedBox(
|
||||
height: 28,
|
||||
child: Text(
|
||||
"{$WhiteLabel.appName}",
|
||||
WhiteLabel.appName,
|
||||
style: STextStyles.desktopH2(context).copyWith(
|
||||
fontSize: 18,
|
||||
height: 23.4 / 18,
|
||||
|
|
|
@ -201,7 +201,7 @@ class _DesktopLoginViewState extends ConsumerState<DesktopLoginView> {
|
|||
height: 42,
|
||||
),
|
||||
Text(
|
||||
"{$WhiteLabel.appName}",
|
||||
WhiteLabel.appName,
|
||||
style: STextStyles.desktopH1(context),
|
||||
),
|
||||
const SizedBox(
|
||||
|
|
|
@ -21,12 +21,12 @@ import 'package:package_info_plus/package_info_plus.dart';
|
|||
import 'package:stackwallet/themes/stack_colors.dart';
|
||||
import 'package:stackwallet/utilities/logger.dart';
|
||||
import 'package:stackwallet/utilities/text_styles.dart';
|
||||
import 'package:stackwallet/whiteLabel.dart';
|
||||
import 'package:stackwallet/widgets/custom_buttons/blue_text_button.dart';
|
||||
import 'package:stackwallet/widgets/desktop/desktop_app_bar.dart';
|
||||
import 'package:stackwallet/widgets/desktop/desktop_scaffold.dart';
|
||||
import 'package:stackwallet/widgets/rounded_white_container.dart';
|
||||
import 'package:url_launcher/url_launcher.dart';
|
||||
import 'package:stackwallet/whiteLabel.dart';
|
||||
|
||||
const kGithubAPI = "https://api.github.com";
|
||||
const kGithubSearch = "/search/commits";
|
||||
|
@ -166,7 +166,7 @@ class DesktopAboutView extends ConsumerWidget {
|
|||
mainAxisAlignment: MainAxisAlignment.start,
|
||||
children: [
|
||||
Text(
|
||||
"{$WhiteLabel.appName}",
|
||||
oWhiteLabel.appName,
|
||||
style: STextStyles.desktopH3(context),
|
||||
textAlign: TextAlign.start,
|
||||
),
|
||||
|
|
|
@ -18,7 +18,7 @@ abstract class FeaturedPaynyms {
|
|||
"PM8TJdQcNk27JpxGRtNR7Hnh8VkJk4Nf17BthLx89fM3iX3UL2YshyaiTAvKgTCVvpgsAgY1DbojkAaUd3Rcn48NEn4uUBuqkaSddgKL8TPAAEQXNuE6";
|
||||
|
||||
static Map<String, String> get featured => {
|
||||
"{$WhiteLabel.appName}": stackWallet,
|
||||
WhiteLabel.appName: stackWallet,
|
||||
// "Samourai Wallet Dev Fund": samouraiWalletDevFund,
|
||||
};
|
||||
}
|
||||
|
|
|
@ -1,7 +1,9 @@
|
|||
abstract class WhiteLabel {
|
||||
String get appName => appNamePrefix + appNameSuffix;
|
||||
static String get appName => prefix + separator + suffix;
|
||||
|
||||
String get appNamePrefix => "Stack";
|
||||
static String get prefix => "Stack";
|
||||
|
||||
String get appNameSuffix => "Wallet";
|
||||
static String get separator => " ";
|
||||
|
||||
static String get suffix => "Wallet";
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue