mirror of
https://github.com/cypherstack/stack_wallet.git
synced 2025-03-26 00:58:50 +00:00
remove qr dialog and xpub nav icon
This commit is contained in:
parent
2fa00ff7a5
commit
1792af4ac8
2 changed files with 0 additions and 152 deletions
lib/widgets
|
@ -1,134 +0,0 @@
|
|||
import 'package:flutter/material.dart';
|
||||
import 'package:qr_flutter/qr_flutter.dart';
|
||||
import 'package:stackwallet/utilities/text_styles.dart';
|
||||
import 'package:stackwallet/utilities/theme/stack_colors.dart';
|
||||
import 'package:stackwallet/utilities/util.dart';
|
||||
|
||||
class QrDialogBase extends StatelessWidget {
|
||||
const QrDialogBase({
|
||||
Key? key,
|
||||
this.child,
|
||||
this.padding = const EdgeInsets.all(24),
|
||||
}) : super(key: key);
|
||||
|
||||
final EdgeInsets padding;
|
||||
final Widget? child;
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Padding(
|
||||
padding: const EdgeInsets.all(16),
|
||||
child: Column(
|
||||
mainAxisAlignment:
|
||||
!Util.isDesktop ? MainAxisAlignment.end : MainAxisAlignment.center,
|
||||
children: [
|
||||
Flexible(
|
||||
child: SingleChildScrollView(
|
||||
child: Material(
|
||||
borderRadius: BorderRadius.circular(
|
||||
20,
|
||||
),
|
||||
child: Container(
|
||||
decoration: BoxDecoration(
|
||||
color: Theme.of(context).extension<StackColors>()!.popupBG,
|
||||
borderRadius: BorderRadius.circular(
|
||||
20,
|
||||
),
|
||||
),
|
||||
child: Padding(
|
||||
padding: padding,
|
||||
child: child,
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
class QrDialog extends StatelessWidget {
|
||||
const QrDialog({
|
||||
Key? key,
|
||||
this.leftButton,
|
||||
this.rightButton,
|
||||
this.icon,
|
||||
required this.title,
|
||||
this.message,
|
||||
this.qr,
|
||||
}) : super(key: key);
|
||||
|
||||
final Widget? leftButton;
|
||||
final Widget? rightButton;
|
||||
|
||||
final Widget? icon;
|
||||
|
||||
final String title;
|
||||
final String? message;
|
||||
|
||||
final String? qr;
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return QrDialogBase(
|
||||
child: Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
Row(
|
||||
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||
children: [
|
||||
Flexible(
|
||||
child: Text(
|
||||
title,
|
||||
style: STextStyles.pageTitleH2(context),
|
||||
),
|
||||
),
|
||||
icon != null ? icon! : Container(),
|
||||
],
|
||||
),
|
||||
if (message != null)
|
||||
const SizedBox(
|
||||
height: 8,
|
||||
),
|
||||
if (message != null)
|
||||
Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
Text(
|
||||
message!,
|
||||
style: STextStyles.smallMed14(context),
|
||||
),
|
||||
],
|
||||
),
|
||||
if (qr != null)
|
||||
QrImage(
|
||||
data: qr!,
|
||||
size: 300,
|
||||
foregroundColor:
|
||||
Theme.of(context).extension<StackColors>()!.accentColorDark,
|
||||
),
|
||||
if (leftButton != null || rightButton != null)
|
||||
const SizedBox(
|
||||
height: 20,
|
||||
),
|
||||
if (leftButton != null || rightButton != null)
|
||||
Row(
|
||||
children: [
|
||||
leftButton == null
|
||||
? const Spacer()
|
||||
: Expanded(child: leftButton!),
|
||||
const SizedBox(
|
||||
width: 8,
|
||||
),
|
||||
rightButton == null
|
||||
? const Spacer()
|
||||
: Expanded(child: rightButton!),
|
||||
],
|
||||
)
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
|
@ -1,18 +0,0 @@
|
|||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter_svg/flutter_svg.dart';
|
||||
import 'package:stackwallet/utilities/assets.dart';
|
||||
import 'package:stackwallet/utilities/theme/stack_colors.dart';
|
||||
|
||||
class XPubNavIcon extends StatelessWidget {
|
||||
const XPubNavIcon({Key? key}) : super(key: key);
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return SvgPicture.asset(
|
||||
Assets.svg.eye,
|
||||
height: 20,
|
||||
width: 20,
|
||||
color: Theme.of(context).extension<StackColors>()!.bottomNavIconIcon,
|
||||
);
|
||||
}
|
||||
}
|
Loading…
Reference in a new issue