mirror of
https://github.com/cypherstack/stack_wallet.git
synced 2025-01-23 19:05:51 +00:00
fix: background
This commit is contained in:
parent
b16e96fc6d
commit
7131632044
1 changed files with 69 additions and 65 deletions
|
@ -6,6 +6,7 @@ import 'package:stackwallet/themes/stack_colors.dart';
|
|||
import 'package:stackwallet/themes/theme_service.dart';
|
||||
import 'package:stackwallet/utilities/text_styles.dart';
|
||||
import 'package:stackwallet/utilities/util.dart';
|
||||
import 'package:stackwallet/widgets/background.dart';
|
||||
import 'package:stackwallet/widgets/conditional_parent.dart';
|
||||
import 'package:stackwallet/widgets/custom_buttons/app_bar_icon_button.dart';
|
||||
import 'package:stackwallet/widgets/desktop/primary_button.dart';
|
||||
|
@ -37,78 +38,81 @@ class _ManageThemesViewState extends ConsumerState<ManageThemesView> {
|
|||
Widget build(BuildContext context) {
|
||||
return ConditionalParent(
|
||||
condition: !Util.isDesktop,
|
||||
builder: (child) => Scaffold(
|
||||
backgroundColor: Theme.of(context).extension<StackColors>()!.background,
|
||||
appBar: AppBar(
|
||||
leading: AppBarBackButton(
|
||||
onPressed: () {
|
||||
Navigator.of(context).pop();
|
||||
},
|
||||
builder: (child) => Background(
|
||||
child: Scaffold(
|
||||
backgroundColor:
|
||||
Theme.of(context).extension<StackColors>()!.background,
|
||||
appBar: AppBar(
|
||||
leading: AppBarBackButton(
|
||||
onPressed: () {
|
||||
Navigator.of(context).pop();
|
||||
},
|
||||
),
|
||||
title: Text(
|
||||
"Add more themes",
|
||||
style: STextStyles.navBarTitle(context),
|
||||
),
|
||||
),
|
||||
title: Text(
|
||||
"Add more themes",
|
||||
style: STextStyles.navBarTitle(context),
|
||||
),
|
||||
),
|
||||
body: _showThemes
|
||||
? Column(
|
||||
children: [
|
||||
Expanded(
|
||||
child: SingleChildScrollView(
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.symmetric(
|
||||
horizontal: 16,
|
||||
),
|
||||
child: IntrinsicHeight(
|
||||
child: child,
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
Padding(
|
||||
padding: const EdgeInsets.all(16),
|
||||
child: SecondaryButton(
|
||||
label: "Install theme file",
|
||||
onPressed: () {},
|
||||
),
|
||||
),
|
||||
],
|
||||
)
|
||||
: Padding(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 16),
|
||||
child: Column(
|
||||
body: _showThemes
|
||||
? Column(
|
||||
children: [
|
||||
RoundedWhiteContainer(
|
||||
child: Text(
|
||||
"You are using Incognito Mode. Please press the"
|
||||
" button below to load available themes from our server"
|
||||
" or upload a theme file manually from your device.",
|
||||
style: STextStyles.smallMed12(context),
|
||||
Expanded(
|
||||
child: SingleChildScrollView(
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.symmetric(
|
||||
horizontal: 16,
|
||||
),
|
||||
child: IntrinsicHeight(
|
||||
child: child,
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
const SizedBox(
|
||||
height: 12,
|
||||
Padding(
|
||||
padding: const EdgeInsets.all(16),
|
||||
child: SecondaryButton(
|
||||
label: "Install theme file",
|
||||
onPressed: () {},
|
||||
),
|
||||
),
|
||||
PrimaryButton(
|
||||
label: "Load themes",
|
||||
onPressed: () {
|
||||
setState(() {
|
||||
_showThemes = true;
|
||||
future = ref.watch(pThemeService).fetchThemes();
|
||||
});
|
||||
},
|
||||
),
|
||||
const SizedBox(
|
||||
height: 12,
|
||||
),
|
||||
SecondaryButton(
|
||||
label: "Install theme file",
|
||||
onPressed: () {},
|
||||
),
|
||||
const Spacer(),
|
||||
],
|
||||
)
|
||||
: Padding(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 16),
|
||||
child: Column(
|
||||
children: [
|
||||
RoundedWhiteContainer(
|
||||
child: Text(
|
||||
"You are using Incognito Mode. Please press the"
|
||||
" button below to load available themes from our server"
|
||||
" or upload a theme file manually from your device.",
|
||||
style: STextStyles.smallMed12(context),
|
||||
),
|
||||
),
|
||||
const SizedBox(
|
||||
height: 12,
|
||||
),
|
||||
PrimaryButton(
|
||||
label: "Load themes",
|
||||
onPressed: () {
|
||||
setState(() {
|
||||
_showThemes = true;
|
||||
future = ref.watch(pThemeService).fetchThemes();
|
||||
});
|
||||
},
|
||||
),
|
||||
const SizedBox(
|
||||
height: 12,
|
||||
),
|
||||
SecondaryButton(
|
||||
label: "Install theme file",
|
||||
onPressed: () {},
|
||||
),
|
||||
const Spacer(),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
child: Column(
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
|
|
Loading…
Reference in a new issue