From 352108fd5e7676f05e320f404a0f71a1a983dd12 Mon Sep 17 00:00:00 2001 From: "Charl (Nitride)" <77973576+CharlVS@users.noreply.github.com> Date: Fri, 18 Jul 2025 14:51:09 +0200 Subject: [PATCH 1/7] feat(ui): auto-scroll addresses in tx pages --- .../transactions/transaction_details.dart | 21 ++++++++++++------- .../transactions/transaction_list_item.dart | 9 +++++++- 2 files changed, 21 insertions(+), 9 deletions(-) diff --git a/lib/views/wallet/coin_details/transactions/transaction_details.dart b/lib/views/wallet/coin_details/transactions/transaction_details.dart index 46914a74cd..f50a7a0317 100644 --- a/lib/views/wallet/coin_details/transactions/transaction_details.dart +++ b/lib/views/wallet/coin_details/transactions/transaction_details.dart @@ -13,6 +13,7 @@ import 'package:web_dex/model/coin.dart'; import 'package:web_dex/shared/utils/formatters.dart'; import 'package:web_dex/shared/utils/utils.dart'; import 'package:web_dex/shared/widgets/copied_text.dart'; +import 'package:web_dex/views/wallet/common/address_copy_button.dart'; class TransactionDetails extends StatelessWidget { const TransactionDetails({ @@ -144,14 +145,18 @@ class TransactionDetails extends StatelessWidget { const SizedBox(width: 8), ConstrainedBox( constraints: const BoxConstraints(maxWidth: 200), - child: CopiedText( - copiedValue: address, - isTruncated: true, - padding: const EdgeInsets.symmetric( - vertical: 8, - horizontal: 16, - ), - fontSize: 14, + child: Row( + children: [ + Expanded( + child: AutoScrollText( + text: address, + style: const TextStyle(fontSize: 14), + isSelectable: true, + ), + ), + const SizedBox(width: 8), + AddressCopyButton(address: address), + ], ), ), ], diff --git a/lib/views/wallet/coin_details/transactions/transaction_list_item.dart b/lib/views/wallet/coin_details/transactions/transaction_list_item.dart index de51a9a2ef..add35bd183 100644 --- a/lib/views/wallet/coin_details/transactions/transaction_list_item.dart +++ b/lib/views/wallet/coin_details/transactions/transaction_list_item.dart @@ -12,6 +12,7 @@ import 'package:web_dex/shared/utils/formatters.dart'; import 'package:web_dex/views/wallet/common/address_copy_button.dart'; import 'package:web_dex/views/wallet/common/address_icon.dart'; import 'package:web_dex/views/wallet/common/address_text.dart'; +import 'package:komodo_ui_kit/komodo_ui_kit.dart'; class TransactionListRow extends StatefulWidget { const TransactionListRow({ @@ -298,7 +299,13 @@ class _TransactionAddress extends StatelessWidget { const SizedBox(width: 8), AddressIcon(address: myAddress), const SizedBox(width: 8), - AddressText(address: myAddress), + Flexible( + child: AutoScrollText( + text: myAddress, + style: const TextStyle(fontSize: 14), + isSelectable: true, + ), + ), AddressCopyButton(address: myAddress), ], ); From 0245e9d73a169943780c9324c9a148a0eb53059d Mon Sep 17 00:00:00 2001 From: CharlVS <77973576+CharlVS@users.noreply.github.com> Date: Fri, 18 Jul 2025 17:42:42 +0200 Subject: [PATCH 2/7] feat: show full transaction address --- lib/shared/widgets/copied_text.dart | 25 +++-- lib/views/support/missing_coins_dialog.dart | 12 --- .../transactions/transaction_details.dart | 99 +++++++++---------- .../transactions/transaction_list.dart | 43 ++++---- .../transactions/transaction_list_item.dart | 70 +++++++------ 5 files changed, 115 insertions(+), 134 deletions(-) diff --git a/lib/shared/widgets/copied_text.dart b/lib/shared/widgets/copied_text.dart index 66501e7c7c..54469dbd3a 100644 --- a/lib/shared/widgets/copied_text.dart +++ b/lib/shared/widgets/copied_text.dart @@ -1,4 +1,5 @@ import 'package:flutter/material.dart'; +import 'package:komodo_ui_kit/komodo_ui_kit.dart'; import 'package:web_dex/shared/utils/utils.dart'; import 'package:web_dex/shared/widgets/truncate_middle_text.dart'; @@ -68,15 +69,15 @@ class CopiedText extends StatelessWidget { ), ), ) - : Text( - copiedValue, - maxLines: maxLines, - softWrap: softWrap, - style: TextStyle( - fontSize: fontSize, - fontWeight: fontWeight, - color: fontColor, - height: height, + : Flexible( + child: AutoScrollText( + text: copiedValue, + style: TextStyle( + fontSize: fontSize, + fontWeight: fontWeight, + color: fontColor, + height: height, + ), ), ), ), @@ -162,10 +163,8 @@ class CopiedTextV2 extends StatelessWidget { color: textColor ?? const Color(0xFFADAFC4)), ), ) - : Text( - copiedValue, - maxLines: maxLines, - softWrap: softWrap, + : AutoScrollText( + text: copiedValue, style: TextStyle( fontSize: fontSize, fontWeight: FontWeight.w700, diff --git a/lib/views/support/missing_coins_dialog.dart b/lib/views/support/missing_coins_dialog.dart index be5bac8c1e..b83bcf0398 100644 --- a/lib/views/support/missing_coins_dialog.dart +++ b/lib/views/support/missing_coins_dialog.dart @@ -1,19 +1,7 @@ import 'package:easy_localization/easy_localization.dart'; import 'package:flutter/material.dart'; -import 'package:flutter/gestures.dart'; -import 'package:flutter_bloc/flutter_bloc.dart'; import 'package:url_launcher/url_launcher.dart'; -import 'package:web_dex/app_config/app_config.dart'; -import 'package:web_dex/bloc/auth_bloc/auth_bloc.dart'; -import 'package:web_dex/bloc/coins_bloc/coins_bloc.dart'; -import 'package:web_dex/common/screen.dart'; import 'package:web_dex/generated/codegen_loader.g.dart'; -import 'package:web_dex/dispatchers/popup_dispatcher.dart'; -import 'package:web_dex/model/authorize_mode.dart'; -import 'package:web_dex/model/wallet.dart'; -import 'package:web_dex/views/wallets_manager/wallets_manager_events_factory.dart'; -import 'package:web_dex/views/wallets_manager/wallets_manager_wrapper.dart'; -import 'package:app_theme/app_theme.dart'; Future showMissingCoinsDialog(BuildContext context) { return showDialog( diff --git a/lib/views/wallet/coin_details/transactions/transaction_details.dart b/lib/views/wallet/coin_details/transactions/transaction_details.dart index f50a7a0317..120f703d58 100644 --- a/lib/views/wallet/coin_details/transactions/transaction_details.dart +++ b/lib/views/wallet/coin_details/transactions/transaction_details.dart @@ -113,9 +113,22 @@ class TransactionDetails extends StatelessWidget { title: LocaleKeys.transactionHash.tr(), value: transaction.txHash ?? '', isCopied: true, + isTruncated: true, ), - const SizedBox(height: 20), - _buildAddresses(isMobile, context), + SizedBox(height: 16), + _buildSimpleData( + context, + title: LocaleKeys.from.tr(), + value: transaction.from.first, + isCopied: true, + ), + _buildSimpleData( + context, + title: LocaleKeys.to.tr(), + value: transaction.to.first, + isCopied: true, + ), + SizedBox(height: 16), _buildControls(context, isMobile), ], ), @@ -132,26 +145,29 @@ class TransactionDetails extends StatelessWidget { required String title, required String address, }) { - return Padding( - padding: const EdgeInsets.only(bottom: 20), + return Container( + margin: const EdgeInsets.only(bottom: 10), child: Row( crossAxisAlignment: CrossAxisAlignment.center, children: [ - Text( - title, - style: - Theme.of(context).textTheme.bodyLarge?.copyWith(fontSize: 14), + // Title with fixed flex + Expanded( + flex: 2, + child: Text( + title, + style: + Theme.of(context).textTheme.bodyLarge?.copyWith(fontSize: 14), + ), ), - const SizedBox(width: 8), - ConstrainedBox( - constraints: const BoxConstraints(maxWidth: 200), + // Address and copy button + Expanded( + flex: 5, child: Row( children: [ Expanded( child: AutoScrollText( text: address, style: const TextStyle(fontSize: 14), - isSelectable: true, ), ), const SizedBox(width: 8), @@ -168,47 +184,21 @@ class TransactionDetails extends StatelessWidget { return Container( width: double.infinity, padding: const EdgeInsets.only(bottom: 10), - child: isMobile - ? Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - _buildAddress( - context, - title: LocaleKeys.from.tr(), - address: transaction.from.first, - ), - _buildAddress( - context, - title: LocaleKeys.to.tr(), - address: transaction.to.first, - ), - ], - ) - : Row( - children: [ - Expanded( - child: Container( - alignment: Alignment.centerLeft, - child: _buildAddress( - context, - title: LocaleKeys.from.tr(), - address: transaction.from.first, - ), - ), - ), - const SizedBox(width: 10), - Expanded( - child: Container( - alignment: Alignment.centerLeft, - child: _buildAddress( - context, - title: LocaleKeys.to.tr(), - address: transaction.to.first, - ), - ), - ), - ], - ), + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + _buildAddress( + context, + title: LocaleKeys.from.tr(), + address: transaction.from.first, + ), + _buildAddress( + context, + title: LocaleKeys.to.tr(), + address: transaction.to.first, + ), + ], + ), ); } @@ -357,6 +347,7 @@ class TransactionDetails extends StatelessWidget { required String value, bool hasBackground = false, bool isCopied = false, + bool isTruncated = false, }) { return Padding( padding: const EdgeInsets.only(bottom: 10.0), @@ -381,7 +372,7 @@ class TransactionDetails extends StatelessWidget { constraints: const BoxConstraints(maxHeight: 340), child: CopiedText( copiedValue: value, - isTruncated: true, + isTruncated: isTruncated, padding: const EdgeInsets.symmetric( vertical: 8, horizontal: 16, diff --git a/lib/views/wallet/coin_details/transactions/transaction_list.dart b/lib/views/wallet/coin_details/transactions/transaction_list.dart index f7e53820cc..b8a096e76b 100644 --- a/lib/views/wallet/coin_details/transactions/transaction_list.dart +++ b/lib/views/wallet/coin_details/transactions/transaction_list.dart @@ -51,35 +51,28 @@ class _List extends StatelessWidget { child: Column( children: [ if (transactions.isNotEmpty && !isMobile) const HistoryTitle(), - Card( - margin: const EdgeInsets.symmetric(vertical: 12), - shape: RoundedRectangleBorder( - borderRadius: BorderRadius.circular(16.0), - ), - color: theme.custom.dexPageTheme.frontPlate, - child: Padding( - padding: EdgeInsets.all(isMobile ? 16.0 : 24.0), - child: isMobile - ? HistoryListContent( + Padding( + padding: EdgeInsets.all(isMobile ? 16.0 : 0), + child: isMobile + ? HistoryListContent( + transactions: transactions, + coinAbbr: coinAbbr, + setTransaction: setTransaction, + isInProgress: isInProgress, + ) + : Card( + margin: const EdgeInsets.symmetric(vertical: 6), + shape: RoundedRectangleBorder( + borderRadius: BorderRadius.circular(16.0), + ), + color: Theme.of(context).colorScheme.onSurface, + child: HistoryListContent( transactions: transactions, coinAbbr: coinAbbr, setTransaction: setTransaction, isInProgress: isInProgress, - ) - : Card( - margin: const EdgeInsets.symmetric(vertical: 6), - shape: RoundedRectangleBorder( - borderRadius: BorderRadius.circular(16.0), - ), - color: Theme.of(context).colorScheme.onSurface, - child: HistoryListContent( - transactions: transactions, - coinAbbr: coinAbbr, - setTransaction: setTransaction, - isInProgress: isInProgress, - ), ), - ), + ), ), ], ), @@ -144,7 +137,7 @@ class HistoryTitle extends StatelessWidget { child: Align( alignment: Alignment.centerLeft, child: Text( - LocaleKeys.lastTransactions.tr(), + LocaleKeys.transactions.tr(), style: TextStyle( fontWeight: FontWeight.w600, fontSize: isMobile ? 16 : 24, diff --git a/lib/views/wallet/coin_details/transactions/transaction_list_item.dart b/lib/views/wallet/coin_details/transactions/transaction_list_item.dart index add35bd183..3d73494fae 100644 --- a/lib/views/wallet/coin_details/transactions/transaction_list_item.dart +++ b/lib/views/wallet/coin_details/transactions/transaction_list_item.dart @@ -100,14 +100,17 @@ class _TransactionListRowState extends State { : theme.custom.decreaseColor, ), const SizedBox(width: 4), - Text( - '${Coin.normalizeAbbr(widget.transaction.assetId.id)} $formatted', - style: TextStyle( - color: _isReceived - ? theme.custom.increaseColor - : theme.custom.decreaseColor, - fontSize: 14, - fontWeight: FontWeight.w500, + Flexible( + child: AutoScrollText( + text: + '$formatted ${Coin.normalizeAbbr(widget.transaction.assetId.id)} ', + style: TextStyle( + color: _isReceived + ? theme.custom.increaseColor + : theme.custom.decreaseColor, + fontSize: 14, + fontWeight: FontWeight.w500, + ), ), ), ], @@ -143,11 +146,13 @@ class _TransactionListRowState extends State { children: [ _buildMemo(), const SizedBox(width: 6), - Text( - formatTransactionDateTime(widget.transaction), - style: isMobile - ? TextStyle(color: Colors.grey[400]) - : const TextStyle(fontSize: 14, fontWeight: FontWeight.w500), + Expanded( + child: AutoScrollText( + text: formatTransactionDateTime(widget.transaction), + style: isMobile + ? TextStyle(color: Colors.grey[400]) + : const TextStyle(fontSize: 14, fontWeight: FontWeight.w500), + ), ), const SizedBox(width: 4), ], @@ -196,8 +201,9 @@ class _TransactionListRowState extends State { return Row( mainAxisSize: MainAxisSize.max, children: [ - Expanded( - flex: 4, + SizedBox(width: 8), + SizedBox( + width: 380, child: _TransactionAddress( transaction: widget.transaction, coinAbbr: widget.coinAbbr, @@ -236,12 +242,9 @@ class _TransactionListRowState extends State { const SizedBox(height: 6), ConstrainedBox( constraints: const BoxConstraints(maxHeight: 120), - child: SingleChildScrollView( - controller: ScrollController(), - child: Text( - memo, - style: const TextStyle(fontSize: 14), - ), + child: AutoScrollText( + text: memo, + style: const TextStyle(fontSize: 14), ), ), ], @@ -260,8 +263,8 @@ class _TransactionListRowState extends State { widget.transaction.amount.toString(), widget.coinAbbr, ); - return Text( - '$_sign \$${formatAmt((usdChanges ?? 0).abs())}', + return AutoScrollText( + text: '$_sign \$${formatAmt((usdChanges ?? 0).abs())}', style: TextStyle( color: _isReceived ? theme.custom.increaseColor @@ -295,15 +298,22 @@ class _TransactionAddress extends StatelessWidget { } return Row( + spacing: 8, + mainAxisAlignment: MainAxisAlignment.spaceBetween, children: [ - const SizedBox(width: 8), - AddressIcon(address: myAddress), - const SizedBox(width: 8), Flexible( - child: AutoScrollText( - text: myAddress, - style: const TextStyle(fontSize: 14), - isSelectable: true, + child: Row( + spacing: 8, + mainAxisSize: MainAxisSize.min, + children: [ + AddressIcon(address: myAddress), + Expanded( + child: AutoScrollText( + text: myAddress, + style: const TextStyle(fontSize: 14), + ), + ), + ], ), ), AddressCopyButton(address: myAddress), From 5ee02400e164ba4aaf5fa745cdadbbbeff73ec68 Mon Sep 17 00:00:00 2001 From: CharlVS <77973576+CharlVS@users.noreply.github.com> Date: Mon, 21 Jul 2025 13:50:47 +0200 Subject: [PATCH 3/7] feat: show full address for own addresses --- .../coin_details_info/coin_addresses.dart | 4 ++-- lib/views/wallet/common/address_text.dart | 17 ++++++++++++++--- .../common/expandable_coin_list_item.dart | 15 ++++++++------- 3 files changed, 24 insertions(+), 12 deletions(-) diff --git a/lib/views/wallet/coin_details/coin_details_info/coin_addresses.dart b/lib/views/wallet/coin_details/coin_details_info/coin_addresses.dart index cc182c869d..8d9f9fceda 100644 --- a/lib/views/wallet/coin_details/coin_details_info/coin_addresses.dart +++ b/lib/views/wallet/coin_details/coin_details_info/coin_addresses.dart @@ -235,7 +235,7 @@ class AddressCard extends StatelessWidget { children: [ AddressIcon(address: address.address), const SizedBox(width: 8), - AddressText(address: address.address), + Flexible(child: AddressText(address: address.address)), const SizedBox(width: 8), if (coin.hasFaucet) ConstrainedBox( @@ -249,7 +249,7 @@ class AddressCard extends StatelessWidget { ), ), SwapAddressTag(address: address), - const Spacer(), + const SizedBox(width: 8), AddressCopyButton( address: address.address, coinAbbr: coin.abbr, diff --git a/lib/views/wallet/common/address_text.dart b/lib/views/wallet/common/address_text.dart index d382db45dd..d09c554451 100644 --- a/lib/views/wallet/common/address_text.dart +++ b/lib/views/wallet/common/address_text.dart @@ -1,18 +1,29 @@ import 'package:flutter/material.dart'; +import 'package:komodo_ui_kit/komodo_ui_kit.dart'; import 'package:web_dex/shared/utils/formatters.dart'; class AddressText extends StatelessWidget { const AddressText({ required this.address, + this.isTruncated = false, }); final String address; + final bool isTruncated; @override Widget build(BuildContext context) { - return Text( - truncateMiddleSymbols(address, 5, 4), - style: const TextStyle(fontSize: 14), + final style = Theme.of(context).textTheme.bodyMedium; + if (isTruncated) { + return Text( + truncateMiddleSymbols(address, 5, 4), + style: style, + ); + } + + return AutoScrollText( + text: address, + style: style, ); } } diff --git a/lib/views/wallet/wallet_page/common/expandable_coin_list_item.dart b/lib/views/wallet/wallet_page/common/expandable_coin_list_item.dart index 9bf0dd6c09..fd0859e8e0 100644 --- a/lib/views/wallet/wallet_page/common/expandable_coin_list_item.dart +++ b/lib/views/wallet/wallet_page/common/expandable_coin_list_item.dart @@ -5,6 +5,7 @@ import 'package:flutter/material.dart'; import 'package:flutter_bloc/flutter_bloc.dart'; import 'package:komodo_defi_types/komodo_defi_types.dart'; import 'package:komodo_ui/komodo_ui.dart'; +import 'package:komodo_ui_kit/komodo_ui_kit.dart'; import 'package:web_dex/bloc/coins_bloc/coins_bloc.dart'; import 'package:web_dex/bloc/trading_status/trading_status_bloc.dart'; import 'package:web_dex/common/screen.dart'; @@ -279,9 +280,11 @@ class _AddressRow extends StatelessWidget { ), title: Row( children: [ - Text( - pubkey.addressShort, - style: theme.textTheme.bodyMedium, + Flexible( + child: AutoScrollText( + text: pubkey.address, + style: theme.textTheme.bodyMedium, + ), ), const SizedBox(width: 8), Material( @@ -296,12 +299,10 @@ class _AddressRow extends StatelessWidget { if (isSwapAddress && context.watch().state is TradingEnabled) ...[ const SizedBox(width: 8), - const Chip( + Chip( label: Text( - 'Swap', - // style: theme.textTheme.labelSmall, + LocaleKeys.tradingAddress.tr(), ), - // backgroundColor: theme.colorScheme.primaryContainer, ), ], ], From f8139fb017c2b761a7a6e28faf12419e2ccdcb39 Mon Sep 17 00:00:00 2001 From: CharlVS <77973576+CharlVS@users.noreply.github.com> Date: Mon, 21 Jul 2025 13:50:55 +0200 Subject: [PATCH 4/7] chore: roll SDK --- packages/komodo_ui_kit/pubspec.lock | 6 +++--- pubspec.lock | 24 ++++++++++++------------ 2 files changed, 15 insertions(+), 15 deletions(-) diff --git a/packages/komodo_ui_kit/pubspec.lock b/packages/komodo_ui_kit/pubspec.lock index dc077645ca..df9c0b9d61 100644 --- a/packages/komodo_ui_kit/pubspec.lock +++ b/packages/komodo_ui_kit/pubspec.lock @@ -95,7 +95,7 @@ packages: description: path: "packages/komodo_defi_rpc_methods" ref: dev - resolved-ref: abd3de0995652a34e721dcb47283f5d670b239e8 + resolved-ref: eac2b8fb588119ae34e0e101384548c7fa952f52 url: "https://github.com/KomodoPlatform/komodo-defi-sdk-flutter.git" source: git version: "0.2.0+0" @@ -104,7 +104,7 @@ packages: description: path: "packages/komodo_defi_types" ref: dev - resolved-ref: abd3de0995652a34e721dcb47283f5d670b239e8 + resolved-ref: eac2b8fb588119ae34e0e101384548c7fa952f52 url: "https://github.com/KomodoPlatform/komodo-defi-sdk-flutter.git" source: git version: "0.2.0+0" @@ -113,7 +113,7 @@ packages: description: path: "packages/komodo_ui" ref: dev - resolved-ref: abd3de0995652a34e721dcb47283f5d670b239e8 + resolved-ref: eac2b8fb588119ae34e0e101384548c7fa952f52 url: "https://github.com/KomodoPlatform/komodo-defi-sdk-flutter.git" source: git version: "0.2.0+0" diff --git a/pubspec.lock b/pubspec.lock index 8f28d1976c..8e1f2e6b62 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -656,7 +656,7 @@ packages: description: path: "packages/komodo_cex_market_data" ref: dev - resolved-ref: abd3de0995652a34e721dcb47283f5d670b239e8 + resolved-ref: eac2b8fb588119ae34e0e101384548c7fa952f52 url: "https://github.com/KomodoPlatform/komodo-defi-sdk-flutter.git" source: git version: "0.0.1" @@ -665,7 +665,7 @@ packages: description: path: "packages/komodo_coin_updates" ref: dev - resolved-ref: abd3de0995652a34e721dcb47283f5d670b239e8 + resolved-ref: eac2b8fb588119ae34e0e101384548c7fa952f52 url: "https://github.com/KomodoPlatform/komodo-defi-sdk-flutter.git" source: git version: "1.0.0" @@ -674,7 +674,7 @@ packages: description: path: "packages/komodo_coins" ref: dev - resolved-ref: abd3de0995652a34e721dcb47283f5d670b239e8 + resolved-ref: eac2b8fb588119ae34e0e101384548c7fa952f52 url: "https://github.com/KomodoPlatform/komodo-defi-sdk-flutter.git" source: git version: "0.2.0+0" @@ -683,7 +683,7 @@ packages: description: path: "packages/komodo_defi_framework" ref: dev - resolved-ref: abd3de0995652a34e721dcb47283f5d670b239e8 + resolved-ref: eac2b8fb588119ae34e0e101384548c7fa952f52 url: "https://github.com/KomodoPlatform/komodo-defi-sdk-flutter.git" source: git version: "0.2.0" @@ -692,7 +692,7 @@ packages: description: path: "packages/komodo_defi_local_auth" ref: dev - resolved-ref: abd3de0995652a34e721dcb47283f5d670b239e8 + resolved-ref: eac2b8fb588119ae34e0e101384548c7fa952f52 url: "https://github.com/KomodoPlatform/komodo-defi-sdk-flutter.git" source: git version: "0.2.0+0" @@ -701,7 +701,7 @@ packages: description: path: "packages/komodo_defi_rpc_methods" ref: dev - resolved-ref: abd3de0995652a34e721dcb47283f5d670b239e8 + resolved-ref: eac2b8fb588119ae34e0e101384548c7fa952f52 url: "https://github.com/KomodoPlatform/komodo-defi-sdk-flutter.git" source: git version: "0.2.0+0" @@ -710,7 +710,7 @@ packages: description: path: "packages/komodo_defi_sdk" ref: dev - resolved-ref: abd3de0995652a34e721dcb47283f5d670b239e8 + resolved-ref: eac2b8fb588119ae34e0e101384548c7fa952f52 url: "https://github.com/KomodoPlatform/komodo-defi-sdk-flutter.git" source: git version: "0.2.0+0" @@ -719,7 +719,7 @@ packages: description: path: "packages/komodo_defi_types" ref: dev - resolved-ref: abd3de0995652a34e721dcb47283f5d670b239e8 + resolved-ref: eac2b8fb588119ae34e0e101384548c7fa952f52 url: "https://github.com/KomodoPlatform/komodo-defi-sdk-flutter.git" source: git version: "0.2.0+0" @@ -735,7 +735,7 @@ packages: description: path: "packages/komodo_ui" ref: dev - resolved-ref: abd3de0995652a34e721dcb47283f5d670b239e8 + resolved-ref: eac2b8fb588119ae34e0e101384548c7fa952f52 url: "https://github.com/KomodoPlatform/komodo-defi-sdk-flutter.git" source: git version: "0.2.0+0" @@ -751,7 +751,7 @@ packages: description: path: "packages/komodo_wallet_build_transformer" ref: dev - resolved-ref: abd3de0995652a34e721dcb47283f5d670b239e8 + resolved-ref: eac2b8fb588119ae34e0e101384548c7fa952f52 url: "https://github.com/KomodoPlatform/komodo-defi-sdk-flutter.git" source: git version: "0.2.0+0" @@ -799,10 +799,10 @@ packages: dependency: transitive description: name: local_auth_android - sha256: "63ad7ca6396290626dc0cb34725a939e4cfe965d80d36112f08d49cf13a8136e" + sha256: "82b2bdeee2199a510d3b7716121e96a6609da86693bb0863edd8566355406b79" url: "https://pub.dev" source: hosted - version: "1.0.49" + version: "1.0.50" local_auth_darwin: dependency: transitive description: From 906882b6944c0d0582e729ea75c20543286eccbb Mon Sep 17 00:00:00 2001 From: CharlVS <77973576+CharlVS@users.noreply.github.com> Date: Mon, 21 Jul 2025 14:25:11 +0200 Subject: [PATCH 5/7] chore: roll SDK --- packages/komodo_ui_kit/pubspec.lock | 6 +++--- pubspec.lock | 20 ++++++++++---------- 2 files changed, 13 insertions(+), 13 deletions(-) diff --git a/packages/komodo_ui_kit/pubspec.lock b/packages/komodo_ui_kit/pubspec.lock index df9c0b9d61..eadaf9b3e1 100644 --- a/packages/komodo_ui_kit/pubspec.lock +++ b/packages/komodo_ui_kit/pubspec.lock @@ -95,7 +95,7 @@ packages: description: path: "packages/komodo_defi_rpc_methods" ref: dev - resolved-ref: eac2b8fb588119ae34e0e101384548c7fa952f52 + resolved-ref: "7eefbd875b181b19edb1ea20bc0962ebc2c3e9bc" url: "https://github.com/KomodoPlatform/komodo-defi-sdk-flutter.git" source: git version: "0.2.0+0" @@ -104,7 +104,7 @@ packages: description: path: "packages/komodo_defi_types" ref: dev - resolved-ref: eac2b8fb588119ae34e0e101384548c7fa952f52 + resolved-ref: "7eefbd875b181b19edb1ea20bc0962ebc2c3e9bc" url: "https://github.com/KomodoPlatform/komodo-defi-sdk-flutter.git" source: git version: "0.2.0+0" @@ -113,7 +113,7 @@ packages: description: path: "packages/komodo_ui" ref: dev - resolved-ref: eac2b8fb588119ae34e0e101384548c7fa952f52 + resolved-ref: "7eefbd875b181b19edb1ea20bc0962ebc2c3e9bc" url: "https://github.com/KomodoPlatform/komodo-defi-sdk-flutter.git" source: git version: "0.2.0+0" diff --git a/pubspec.lock b/pubspec.lock index 8e1f2e6b62..e4261c260b 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -656,7 +656,7 @@ packages: description: path: "packages/komodo_cex_market_data" ref: dev - resolved-ref: eac2b8fb588119ae34e0e101384548c7fa952f52 + resolved-ref: "7eefbd875b181b19edb1ea20bc0962ebc2c3e9bc" url: "https://github.com/KomodoPlatform/komodo-defi-sdk-flutter.git" source: git version: "0.0.1" @@ -665,7 +665,7 @@ packages: description: path: "packages/komodo_coin_updates" ref: dev - resolved-ref: eac2b8fb588119ae34e0e101384548c7fa952f52 + resolved-ref: "7eefbd875b181b19edb1ea20bc0962ebc2c3e9bc" url: "https://github.com/KomodoPlatform/komodo-defi-sdk-flutter.git" source: git version: "1.0.0" @@ -674,7 +674,7 @@ packages: description: path: "packages/komodo_coins" ref: dev - resolved-ref: eac2b8fb588119ae34e0e101384548c7fa952f52 + resolved-ref: "7eefbd875b181b19edb1ea20bc0962ebc2c3e9bc" url: "https://github.com/KomodoPlatform/komodo-defi-sdk-flutter.git" source: git version: "0.2.0+0" @@ -683,7 +683,7 @@ packages: description: path: "packages/komodo_defi_framework" ref: dev - resolved-ref: eac2b8fb588119ae34e0e101384548c7fa952f52 + resolved-ref: "7eefbd875b181b19edb1ea20bc0962ebc2c3e9bc" url: "https://github.com/KomodoPlatform/komodo-defi-sdk-flutter.git" source: git version: "0.2.0" @@ -692,7 +692,7 @@ packages: description: path: "packages/komodo_defi_local_auth" ref: dev - resolved-ref: eac2b8fb588119ae34e0e101384548c7fa952f52 + resolved-ref: "7eefbd875b181b19edb1ea20bc0962ebc2c3e9bc" url: "https://github.com/KomodoPlatform/komodo-defi-sdk-flutter.git" source: git version: "0.2.0+0" @@ -701,7 +701,7 @@ packages: description: path: "packages/komodo_defi_rpc_methods" ref: dev - resolved-ref: eac2b8fb588119ae34e0e101384548c7fa952f52 + resolved-ref: "7eefbd875b181b19edb1ea20bc0962ebc2c3e9bc" url: "https://github.com/KomodoPlatform/komodo-defi-sdk-flutter.git" source: git version: "0.2.0+0" @@ -710,7 +710,7 @@ packages: description: path: "packages/komodo_defi_sdk" ref: dev - resolved-ref: eac2b8fb588119ae34e0e101384548c7fa952f52 + resolved-ref: "7eefbd875b181b19edb1ea20bc0962ebc2c3e9bc" url: "https://github.com/KomodoPlatform/komodo-defi-sdk-flutter.git" source: git version: "0.2.0+0" @@ -719,7 +719,7 @@ packages: description: path: "packages/komodo_defi_types" ref: dev - resolved-ref: eac2b8fb588119ae34e0e101384548c7fa952f52 + resolved-ref: "7eefbd875b181b19edb1ea20bc0962ebc2c3e9bc" url: "https://github.com/KomodoPlatform/komodo-defi-sdk-flutter.git" source: git version: "0.2.0+0" @@ -735,7 +735,7 @@ packages: description: path: "packages/komodo_ui" ref: dev - resolved-ref: eac2b8fb588119ae34e0e101384548c7fa952f52 + resolved-ref: "7eefbd875b181b19edb1ea20bc0962ebc2c3e9bc" url: "https://github.com/KomodoPlatform/komodo-defi-sdk-flutter.git" source: git version: "0.2.0+0" @@ -751,7 +751,7 @@ packages: description: path: "packages/komodo_wallet_build_transformer" ref: dev - resolved-ref: eac2b8fb588119ae34e0e101384548c7fa952f52 + resolved-ref: "7eefbd875b181b19edb1ea20bc0962ebc2c3e9bc" url: "https://github.com/KomodoPlatform/komodo-defi-sdk-flutter.git" source: git version: "0.2.0+0" From 095efbd8592f501b679bd591d3f11a804a90f40f Mon Sep 17 00:00:00 2001 From: CharlVS <77973576+CharlVS@users.noreply.github.com> Date: Mon, 21 Jul 2025 14:54:07 +0200 Subject: [PATCH 6/7] fix(ui): Fix address text item responsiveness --- .../wallet/coin_details/coin_details_info/coin_addresses.dart | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/views/wallet/coin_details/coin_details_info/coin_addresses.dart b/lib/views/wallet/coin_details/coin_details_info/coin_addresses.dart index 8d9f9fceda..b798c0983e 100644 --- a/lib/views/wallet/coin_details/coin_details_info/coin_addresses.dart +++ b/lib/views/wallet/coin_details/coin_details_info/coin_addresses.dart @@ -269,7 +269,7 @@ class AddressCard extends StatelessWidget { width: double.infinity, child: Row( children: [ - AddressText(address: address.address), + Flexible(child: AddressText(address: address.address)), const SizedBox(width: 8), AddressCopyButton( address: address.address, From 693f5ddb13950b2bc5b148683e315015038323c8 Mon Sep 17 00:00:00 2001 From: CharlVS <77973576+CharlVS@users.noreply.github.com> Date: Tue, 22 Jul 2025 13:28:36 +0200 Subject: [PATCH 7/7] fix(ui): align transaction table columns --- lib/shared/utils/formatters.dart | 4 +- .../transactions/transaction_list_item.dart | 63 +++++++++---------- 2 files changed, 32 insertions(+), 35 deletions(-) diff --git a/lib/shared/utils/formatters.dart b/lib/shared/utils/formatters.dart index 1c8172ac10..0e09db632a 100644 --- a/lib/shared/utils/formatters.dart +++ b/lib/shared/utils/formatters.dart @@ -353,10 +353,10 @@ String truncateMiddleSymbols( String formatTransactionDateTime(Transaction tx) { if (tx.timestamp == DateTime.fromMillisecondsSinceEpoch(0) && tx.confirmations == 0) { - return 'unconfirmed'; + return 'Unconfirmed'; } else if (tx.timestamp == DateTime.fromMillisecondsSinceEpoch(0) && tx.confirmations > 0) { - return 'confirmed'; + return 'Now'; } else { return DateFormat('dd MMM yyyy HH:mm').format(tx.timestamp); } diff --git a/lib/views/wallet/coin_details/transactions/transaction_list_item.dart b/lib/views/wallet/coin_details/transactions/transaction_list_item.dart index 3d73494fae..70303b94b9 100644 --- a/lib/views/wallet/coin_details/transactions/transaction_list_item.dart +++ b/lib/views/wallet/coin_details/transactions/transaction_list_item.dart @@ -202,15 +202,22 @@ class _TransactionListRowState extends State { mainAxisSize: MainAxisSize.max, children: [ SizedBox(width: 8), - SizedBox( - width: 380, - child: _TransactionAddress( - transaction: widget.transaction, - coinAbbr: widget.coinAbbr, + Flexible( + flex: 6, + child: Container( + constraints: const BoxConstraints(maxWidth: 415), + alignment: Alignment.centerLeft, + child: _TransactionAddress( + transaction: widget.transaction, + coinAbbr: widget.coinAbbr, + ), ), ), - Expanded( - flex: 4, + SizedBox(width: 16), + Container( + margin: const EdgeInsets.symmetric(horizontal: 8), + alignment: Alignment.centerLeft, + width: 60, child: Text( _isReceived ? LocaleKeys.receive.tr() : LocaleKeys.send.tr(), style: const TextStyle( @@ -276,6 +283,13 @@ class _TransactionListRowState extends State { } } +extension _TransactionExtension on Transaction { + String get myAddress { + List addressList = isIncoming ? to : from; + return addressList.isNotEmpty ? addressList.first : LocaleKeys.unknown.tr(); + } +} + class _TransactionAddress extends StatelessWidget { const _TransactionAddress({ required this.transaction, @@ -287,36 +301,19 @@ class _TransactionAddress extends StatelessWidget { @override Widget build(BuildContext context) { - String myAddress; - List addressList = - transaction.isIncoming ? transaction.to : transaction.from; - - if (addressList.isNotEmpty) { - myAddress = addressList.first; - } else { - myAddress = LocaleKeys.unknown.tr(); - } - return Row( - spacing: 8, - mainAxisAlignment: MainAxisAlignment.spaceBetween, + mainAxisSize: MainAxisSize.min, children: [ - Flexible( - child: Row( - spacing: 8, - mainAxisSize: MainAxisSize.min, - children: [ - AddressIcon(address: myAddress), - Expanded( - child: AutoScrollText( - text: myAddress, - style: const TextStyle(fontSize: 14), - ), - ), - ], + AddressIcon(address: transaction.myAddress), + const SizedBox(width: 8), + Expanded( + child: AutoScrollText( + text: transaction.myAddress, + style: Theme.of(context).textTheme.bodySmall, ), ), - AddressCopyButton(address: myAddress), + const SizedBox(width: 4), + AddressCopyButton(address: transaction.myAddress), ], ); }