From 04645d6c6babbe47a33b4561726db0cb9daed5b7 Mon Sep 17 00:00:00 2001 From: Hoang Btmrk Date: Thu, 29 Aug 2024 15:23:07 +0700 Subject: [PATCH] Update UI --- assets | 2 +- lib/screen/irl_screen/webview_irl_screen.dart | 4 +-- lib/screen/new_onboarding_page.dart | 8 +++-- lib/util/ui_helper.dart | 3 +- lib/view/cast_button.dart | 32 +++++++------------ lib/view/display_instruction_view.dart | 2 +- lib/view/stream_device_view.dart | 2 +- 7 files changed, 25 insertions(+), 28 deletions(-) diff --git a/assets b/assets index 5ecc5442b..de8d6dc7d 160000 --- a/assets +++ b/assets @@ -1 +1 @@ -Subproject commit 5ecc5442bdd3f430b8e79b1a7098f8b7ce5fd860 +Subproject commit de8d6dc7de10d40a31ff5ea6c20960fa7e6dbbcf diff --git a/lib/screen/irl_screen/webview_irl_screen.dart b/lib/screen/irl_screen/webview_irl_screen.dart index 99627d92c..b30006d06 100644 --- a/lib/screen/irl_screen/webview_irl_screen.dart +++ b/lib/screen/irl_screen/webview_irl_screen.dart @@ -331,7 +331,7 @@ class _IRLWebScreenState extends State { '_signMessage', JSResult.error( ''' - Wallet not found. Chain ${argument.chain}, + Wallet not found. Chain ${argument.chain}, address: ${argument.sourceAddress} ''', ), @@ -394,7 +394,7 @@ class _IRLWebScreenState extends State { '_sendTransaction', JSResult.error( ''' - Wallet not found. Chain ${argument.chain}, + Wallet not found. Chain ${argument.chain}, address: ${argument.sourceAddress} ''', ), diff --git a/lib/screen/new_onboarding_page.dart b/lib/screen/new_onboarding_page.dart index be2cba98e..de8dc2ffe 100644 --- a/lib/screen/new_onboarding_page.dart +++ b/lib/screen/new_onboarding_page.dart @@ -95,14 +95,18 @@ class _NewOnboardingPageState extends State { ), Text( title, - style: theme.textTheme.ppMori700White24, + style: theme.textTheme.ppMori700Black36.copyWith( + color: AppColor.white, + ), ), Container( height: 30, ), Text( desc, - style: theme.textTheme.ppMori400White14, + style: theme.textTheme.ppMori700White18.copyWith( + fontWeight: FontWeight.w400, + ), ), ], ), diff --git a/lib/util/ui_helper.dart b/lib/util/ui_helper.dart index c5e8d10bb..532fe37ce 100644 --- a/lib/util/ui_helper.dart +++ b/lib/util/ui_helper.dart @@ -107,6 +107,7 @@ class UIHelper { EdgeInsets? padding, EdgeInsets? paddingTitle, bool withCloseIcon = false, + double spacing = 40, }) async { log.info('[UIHelper] showDialog: $title'); currentDialogTitle = title; @@ -174,7 +175,7 @@ class UIHelper { ], ), ), - const SizedBox(height: 40), + SizedBox(height: spacing), content, ], ), diff --git a/lib/view/cast_button.dart b/lib/view/cast_button.dart index d70564e01..100f16274 100644 --- a/lib/view/cast_button.dart +++ b/lib/view/cast_button.dart @@ -173,30 +173,22 @@ class _FFCastButtonState extends State { final subscriptionDetail = upgradeState.activeSubscriptionDetails.firstOrNull; final price = subscriptionDetail?.price ?? r'$200/year'; - return Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - Text( - 'you_need_to_subscribe'.tr(), - style: Theme.of(context).textTheme.ppMori400White14, - ), - const SizedBox(height: 20), - MembershipCard( - type: MembershipCardType.premium, - price: price, - isProcessing: upgradeState.isProcessing, - isEnable: subscriptionDetail != null, - onTap: (_) { - _onPressSubscribe( - subscriptionDetails: subscriptionDetail!); - }, - buttonText: 'upgrade'.tr(), - ), - ], + return MembershipCard( + type: MembershipCardType.premium, + price: price, + isProcessing: upgradeState.isProcessing, + isEnable: subscriptionDetail != null, + onTap: (_) { + _onPressSubscribe(subscriptionDetails: subscriptionDetail!); + }, + buttonText: 'upgrade'.tr(), ); }), ), isDismissible: true, + withCloseIcon: true, + spacing: 20, + padding: const EdgeInsets.fromLTRB(14, 20, 14, 40), ); } diff --git a/lib/view/display_instruction_view.dart b/lib/view/display_instruction_view.dart index 2e739421f..e5e2d2920 100644 --- a/lib/view/display_instruction_view.dart +++ b/lib/view/display_instruction_view.dart @@ -271,7 +271,7 @@ class HowToDisplayOnBrowser extends StatelessWidget { ), ), const TextSpan( - text: " on your TV's web browser.", + text: " on TV's web browser.", ), ], ), diff --git a/lib/view/stream_device_view.dart b/lib/view/stream_device_view.dart index 525896183..569776b62 100644 --- a/lib/view/stream_device_view.dart +++ b/lib/view/stream_device_view.dart @@ -167,7 +167,7 @@ class _StreamDeviceViewState extends State { const SizedBox(height: 30), ], ] else ...[ - const SizedBox(height: 40), + const SizedBox(height: 20), _instructionDetailWidget(context), ], const SizedBox(height: 10),