mirror of
https://github.com/cypherstack/stack_wallet.git
synced 2025-03-12 09:27:01 +00:00
hide or show theme features based on configuration
This commit is contained in:
parent
2b28e6b121
commit
df5988b48e
2 changed files with 20 additions and 14 deletions
|
@ -12,6 +12,7 @@ import 'dart:io';
|
|||
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
import '../../../app_config.dart';
|
||||
import '../../../route_generator.dart';
|
||||
import '../../../themes/stack_colors.dart';
|
||||
import '../../../utilities/assets.dart';
|
||||
|
@ -211,19 +212,23 @@ class GlobalSettingsView extends StatelessWidget {
|
|||
);
|
||||
},
|
||||
),
|
||||
const SizedBox(
|
||||
height: 8,
|
||||
),
|
||||
SettingsListButton(
|
||||
iconAssetName: Assets.svg.sun,
|
||||
iconSize: 18,
|
||||
title: "Appearance",
|
||||
onPressed: () {
|
||||
Navigator.of(context).pushNamed(
|
||||
AppearanceSettingsView.routeName,
|
||||
);
|
||||
},
|
||||
),
|
||||
if (AppConfig.hasFeature(
|
||||
AppFeature.themeSelection))
|
||||
const SizedBox(
|
||||
height: 8,
|
||||
),
|
||||
if (AppConfig.hasFeature(
|
||||
AppFeature.themeSelection))
|
||||
SettingsListButton(
|
||||
iconAssetName: Assets.svg.sun,
|
||||
iconSize: 18,
|
||||
title: "Appearance",
|
||||
onPressed: () {
|
||||
Navigator.of(context).pushNamed(
|
||||
AppearanceSettingsView.routeName,
|
||||
);
|
||||
},
|
||||
),
|
||||
if (Platform.isIOS)
|
||||
const SizedBox(
|
||||
height: 8,
|
||||
|
|
|
@ -12,6 +12,7 @@ import 'package:flutter/material.dart';
|
|||
import 'package:flutter_riverpod/flutter_riverpod.dart';
|
||||
import 'package:flutter_svg/svg.dart';
|
||||
|
||||
import '../../app_config.dart';
|
||||
import '../../themes/stack_colors.dart';
|
||||
import '../../utilities/assets.dart';
|
||||
import 'settings_menu_item.dart';
|
||||
|
@ -36,7 +37,7 @@ class _SettingsMenuState extends ConsumerState<SettingsMenu> {
|
|||
"Tor settings",
|
||||
"Nodes",
|
||||
"Syncing preferences",
|
||||
"Appearance",
|
||||
if (AppConfig.hasFeature(AppFeature.themeSelection)) "Appearance",
|
||||
"Advanced",
|
||||
];
|
||||
|
||||
|
|
Loading…
Reference in a new issue