mirror of
https://github.com/cypherstack/stack_wallet.git
synced 2024-11-16 17:27:39 +00:00
monkey view page
This commit is contained in:
parent
8ac085fe24
commit
a286ba7b8f
1 changed files with 119 additions and 45 deletions
|
@ -7,11 +7,13 @@ import 'package:stackwallet/pages/monkey/sub_widgets/fetch_monkey_dialog.dart';
|
|||
import 'package:stackwallet/services/coins/manager.dart';
|
||||
import 'package:stackwallet/themes/coin_icon_provider.dart';
|
||||
import 'package:stackwallet/themes/stack_colors.dart';
|
||||
import 'package:stackwallet/utilities/assets.dart';
|
||||
import 'package:stackwallet/utilities/enums/coin_enum.dart';
|
||||
import 'package:stackwallet/utilities/text_styles.dart';
|
||||
import 'package:stackwallet/widgets/background.dart';
|
||||
import 'package:stackwallet/widgets/custom_buttons/app_bar_icon_button.dart';
|
||||
import 'package:stackwallet/widgets/desktop/primary_button.dart';
|
||||
import 'package:stackwallet/widgets/desktop/secondary_button.dart';
|
||||
|
||||
class MonkeyView extends ConsumerStatefulWidget {
|
||||
const MonkeyView({
|
||||
|
@ -50,6 +52,7 @@ class _MonkeyViewState extends ConsumerState<MonkeyView> {
|
|||
@override
|
||||
Widget build(BuildContext context) {
|
||||
final Coin coin = ref.watch(managerProvider.select((value) => value.coin));
|
||||
bool isMonkey = false;
|
||||
|
||||
return Background(
|
||||
child: Stack(
|
||||
|
@ -65,21 +68,90 @@ class _MonkeyViewState extends ConsumerState<MonkeyView> {
|
|||
"MonKey",
|
||||
style: STextStyles.navBarTitle(context),
|
||||
),
|
||||
actions: [
|
||||
AspectRatio(
|
||||
aspectRatio: 1,
|
||||
child: AppBarIconButton(
|
||||
icon: SvgPicture.asset(Assets.svg.circleQuestion),
|
||||
onPressed: () {
|
||||
showDialog<dynamic>(
|
||||
context: context,
|
||||
useSafeArea: false,
|
||||
barrierDismissible: true,
|
||||
builder: (context) {
|
||||
return Dialog(
|
||||
child: Material(
|
||||
borderRadius: BorderRadius.circular(
|
||||
20,
|
||||
),
|
||||
body: Column(
|
||||
// mainAxisAlignment: MainAxisAlignment.center,
|
||||
// crossAxisAlignment: CrossAxisAlignment.center,
|
||||
child: Container(
|
||||
height: 200,
|
||||
decoration: BoxDecoration(
|
||||
color: Theme.of(context)
|
||||
.extension<StackColors>()!
|
||||
.popupBG,
|
||||
borderRadius: BorderRadius.circular(
|
||||
20,
|
||||
),
|
||||
),
|
||||
child: Column(
|
||||
children: [
|
||||
const Spacer(),
|
||||
Center(
|
||||
child: Text(
|
||||
"Help",
|
||||
style: STextStyles.pageTitleH2(
|
||||
context),
|
||||
),
|
||||
)
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
);
|
||||
});
|
||||
}),
|
||||
)
|
||||
],
|
||||
),
|
||||
body: isMonkey
|
||||
? Column(
|
||||
children: [
|
||||
Spacer(),
|
||||
Padding(
|
||||
padding: const EdgeInsets.all(16.0),
|
||||
child: Column(
|
||||
children: [
|
||||
SecondaryButton(
|
||||
label: "Download as SVG",
|
||||
onPressed: () {},
|
||||
),
|
||||
const SizedBox(height: 12),
|
||||
SecondaryButton(
|
||||
label: "Download as PNG",
|
||||
onPressed: () {},
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
],
|
||||
)
|
||||
: Column(
|
||||
children: [
|
||||
const Spacer(
|
||||
flex: 4,
|
||||
),
|
||||
Center(
|
||||
child: Column(
|
||||
children: [
|
||||
SvgPicture.file(
|
||||
Opacity(
|
||||
opacity: 0.2,
|
||||
child: SvgPicture.file(
|
||||
File(
|
||||
ref.watch(coinIconProvider(coin)),
|
||||
),
|
||||
width: 164,
|
||||
height: 164,
|
||||
width: 200,
|
||||
height: 200,
|
||||
),
|
||||
),
|
||||
const SizedBox(
|
||||
height: 40,
|
||||
|
@ -96,7 +168,9 @@ class _MonkeyViewState extends ConsumerState<MonkeyView> {
|
|||
],
|
||||
),
|
||||
),
|
||||
const Spacer(),
|
||||
const Spacer(
|
||||
flex: 6,
|
||||
),
|
||||
Padding(
|
||||
padding: const EdgeInsets.all(16.0),
|
||||
child: PrimaryButton(
|
||||
|
|
Loading…
Reference in a new issue