desktop wallet transactions ui fix

This commit is contained in:
julian 2023-04-20 18:34:16 -06:00
parent 58bc67f9ea
commit e7eec36986
2 changed files with 38 additions and 15 deletions

View file

@ -852,6 +852,8 @@ class _DesktopTransactionCardRowState
prefix = "-";
} else if (_transaction.type == TransactionType.incoming) {
prefix = "+";
} else {
prefix = "";
}
} else {
prefix = "";

View file

@ -7,6 +7,7 @@ import 'package:flutter_svg/svg.dart';
import 'package:stackwallet/pages/add_wallet_views/add_token_view/edit_wallet_tokens_view.dart';
import 'package:stackwallet/pages/token_view/my_tokens_view.dart';
import 'package:stackwallet/pages/wallet_view/sub_widgets/transactions_list.dart';
import 'package:stackwallet/pages/wallet_view/transaction_views/all_transactions_view.dart';
import 'package:stackwallet/pages_desktop_specific/my_stack_view/wallet_view/sub_widgets/desktop_wallet_features.dart';
import 'package:stackwallet/pages_desktop_specific/my_stack_view/wallet_view/sub_widgets/desktop_wallet_summary.dart';
import 'package:stackwallet/pages_desktop_specific/my_stack_view/wallet_view/sub_widgets/my_wallet.dart';
@ -285,7 +286,12 @@ class _DesktopWalletViewState extends ConsumerState<DesktopWalletView> {
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
Text(
"Tokens",
ref.watch(walletsChangeNotifierProvider.select(
(value) => value
.getManager(widget.walletId)
.hasTokenSupport))
? "Tokens"
: "Recent transactions",
style: STextStyles.desktopTextExtraSmall(context)
.copyWith(
color: Theme.of(context)
@ -294,8 +300,17 @@ class _DesktopWalletViewState extends ConsumerState<DesktopWalletView> {
),
),
CustomTextButton(
text: "Edit",
onTap: () async {
text: ref.watch(walletsChangeNotifierProvider.select(
(value) => value
.getManager(widget.walletId)
.hasTokenSupport))
? "Edit"
: "See all",
onTap: ref.watch(walletsChangeNotifierProvider.select(
(value) => value
.getManager(widget.walletId)
.hasTokenSupport))
? () async {
final result = await showDialog<int?>(
context: context,
builder: (context) => EditWalletTokensView(
@ -308,6 +323,12 @@ class _DesktopWalletViewState extends ConsumerState<DesktopWalletView> {
// wallet tokens were edited so update ui
setState(() {});
}
}
: () {
Navigator.of(context).pushNamed(
AllTransactionsView.routeName,
arguments: widget.walletId,
);
},
),
],