From faa03676169e8406ee21a7a63b97b5c9d32f6b41 Mon Sep 17 00:00:00 2001 From: atavism Date: Wed, 6 Mar 2024 11:24:06 -0800 Subject: [PATCH 1/5] hide back button on home screen --- lib/vpn/vpn_tab.dart | 2 ++ pubspec.lock | 48 +++++++++++++++++++++++++++++++++----------- 2 files changed, 38 insertions(+), 12 deletions(-) diff --git a/lib/vpn/vpn_tab.dart b/lib/vpn/vpn_tab.dart index 6f0362638..daa0c0ce3 100644 --- a/lib/vpn/vpn_tab.dart +++ b/lib/vpn/vpn_tab.dart @@ -20,6 +20,8 @@ class VPNTab extends StatelessWidget { height: 16, fit: BoxFit.contain, ), + // make sure to disable the back arrow button on the home screen + automaticallyImplyLeading: false, padVertical: true, body: Column( mainAxisAlignment: MainAxisAlignment.spaceBetween, diff --git a/pubspec.lock b/pubspec.lock index 4b158776c..ec5d23429 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -900,6 +900,30 @@ packages: url: "https://pub.dev" source: hosted version: "4.8.1" + leak_tracker: + dependency: transitive + description: + name: leak_tracker + sha256: "78eb209deea09858f5269f5a5b02be4049535f568c07b275096836f01ea323fa" + url: "https://pub.dev" + source: hosted + version: "10.0.0" + leak_tracker_flutter_testing: + dependency: transitive + description: + name: leak_tracker_flutter_testing + sha256: b46c5e37c19120a8a01918cfaf293547f47269f7cb4b0058f21531c2465d6ef0 + url: "https://pub.dev" + source: hosted + version: "2.0.1" + leak_tracker_testing: + dependency: transitive + description: + name: leak_tracker_testing + sha256: a597f72a664dbd293f3bfc51f9ba69816f84dcd403cdac7066cb3f6003f3ab47 + url: "https://pub.dev" + source: hosted + version: "2.0.1" lints: dependency: transitive description: @@ -960,10 +984,10 @@ packages: dependency: transitive description: name: material_color_utilities - sha256: "9528f2f296073ff54cb9fee677df673ace1218163c3bc7628093e7eed5203d41" + sha256: "0e0a020085b65b6083975e499759762399b4475f766c21668c4ecca34ea74e5a" url: "https://pub.dev" source: hosted - version: "0.5.0" + version: "0.8.0" menu_base: dependency: transitive description: @@ -976,10 +1000,10 @@ packages: dependency: transitive description: name: meta - sha256: "7687075e408b093f36e6bbf6c91878cc0d4cd10f409506f7bc996f68220b9136" + sha256: d584fa6707a52763a52446f02cc621b077888fb63b93bbcb1143a7be5a0c0c04 url: "https://pub.dev" source: hosted - version: "1.12.0" + version: "1.11.0" mime: dependency: "direct main" description: @@ -1573,26 +1597,26 @@ packages: dependency: "direct dev" description: name: test - sha256: "7ee446762c2c50b3bd4ea96fe13ffac69919352bd3b4b17bac3f3465edc58073" + sha256: a1f7595805820fcc05e5c52e3a231aedd0b72972cb333e8c738a8b1239448b6f url: "https://pub.dev" source: hosted - version: "1.25.2" + version: "1.24.9" test_api: dependency: transitive description: name: test_api - sha256: "9955ae474176f7ac8ee4e989dadfb411a58c30415bcfb648fa04b2b8a03afa7f" + sha256: "5c2f730018264d276c20e4f1503fd1308dfbbae39ec8ee63c5236311ac06954b" url: "https://pub.dev" source: hosted - version: "0.7.0" + version: "0.6.1" test_core: dependency: transitive description: name: test_core - sha256: "2bc4b4ecddd75309300d8096f781c0e3280ca1ef85beda558d33fcbedc2eead4" + sha256: a757b14fc47507060a162cc2530d9a4a2f92f5100a952c7443b5cad5ef5b106a url: "https://pub.dev" source: hosted - version: "0.6.0" + version: "0.5.9" timezone: dependency: transitive description: @@ -1789,10 +1813,10 @@ packages: dependency: transitive description: name: vm_service - sha256: a13d5503b4facefc515c8c587ce3cf69577a7b064a9f1220e005449cf1f64aad + sha256: b3d56ff4341b8f182b96aceb2fa20e3dcb336b9f867bc0eafc0de10f1048e957 url: "https://pub.dev" source: hosted - version: "12.0.0" + version: "13.0.0" wakelock: dependency: "direct main" description: From ed50ce286867d517f256acc5f4dbd304f88788a7 Mon Sep 17 00:00:00 2001 From: atavism Date: Wed, 6 Mar 2024 11:44:01 -0800 Subject: [PATCH 2/5] server location widget updates --- lib/vpn/vpn_server_location.dart | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/lib/vpn/vpn_server_location.dart b/lib/vpn/vpn_server_location.dart index 60ec4a5c7..34f15c737 100644 --- a/lib/vpn/vpn_server_location.dart +++ b/lib/vpn/vpn_server_location.dart @@ -12,14 +12,19 @@ class ServerLocationWidget extends StatelessWidget { ), child: Row( crossAxisAlignment: CrossAxisAlignment.center, + mainAxisAlignment: MainAxisAlignment.center, children: [ CText( 'Server Location'.i18n, + textAlign: TextAlign.center, style: tsSubtitle3.copiedWith( color: unselectedTabIconColor, ), ), Container( + padding: const EdgeInsets.only( + left: 8, + ), transform: Matrix4.translationValues(0.0, 2.0, 0.0), child: Icon( Icons.info_outline_rounded, @@ -34,6 +39,7 @@ class ServerLocationWidget extends StatelessWidget { (BuildContext context, ServerInfo serverInfo, Widget? child) { if (vpnStatus == 'connected' || vpnStatus == 'disconnecting') { return Row( + crossAxisAlignment: CrossAxisAlignment.center, children: [ ClipRRect( borderRadius: const BorderRadius.all(Radius.circular(4)), @@ -47,12 +53,14 @@ class ServerLocationWidget extends StatelessWidget { CText( serverInfo.city, style: tsSubtitle4, + textAlign: TextAlign.center, ) ], ); } else { return CText( 'n/a'.i18n.toUpperCase(), + textAlign: TextAlign.center, style: tsSubtitle4, ); } From 0b243e96686952279f37e449067e33e207888224 Mon Sep 17 00:00:00 2001 From: atavism Date: Wed, 6 Mar 2024 11:50:27 -0800 Subject: [PATCH 3/5] Add explicit back arrow icon in base screen --- lib/common/ui/base_screen.dart | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/lib/common/ui/base_screen.dart b/lib/common/ui/base_screen.dart index 84162bf57..55e431722 100644 --- a/lib/common/ui/base_screen.dart +++ b/lib/common/ui/base_screen.dart @@ -76,6 +76,10 @@ class BaseScreen extends StatelessWidget { ), AppBar( automaticallyImplyLeading: automaticallyImplyLeading, + leading: automaticallyImplyLeading ? IconButton( + icon: Icon(Icons.arrow_back, color: Colors.black), + onPressed: () => Navigator.of(context).pop(), + ) : null, title: title is String ? CText( title, @@ -93,9 +97,7 @@ class BaseScreen extends StatelessWidget { titleSpacing: 0, actions: actions, ), - ], - ), ), ), From b2a3f0d168988ede5c6cf0c3f0d49f72c8ba26f1 Mon Sep 17 00:00:00 2001 From: atavism Date: Wed, 6 Mar 2024 12:07:13 -0800 Subject: [PATCH 4/5] increase content padding on account text input fields --- lib/account/device_linking/authorize_device_via_email.dart | 4 ++++ lib/account/report_issue.dart | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/lib/account/device_linking/authorize_device_via_email.dart b/lib/account/device_linking/authorize_device_via_email.dart index b65d494e5..d202b1b46 100644 --- a/lib/account/device_linking/authorize_device_via_email.dart +++ b/lib/account/device_linking/authorize_device_via_email.dart @@ -31,6 +31,10 @@ class AuthorizeDeviceViaEmail extends StatelessWidget { controller: emailController, autovalidateMode: AutovalidateMode.disabled, //TODO: this throws an error when we set it to AutovalidateMode.onUserInteraction + contentPadding: const EdgeInsetsDirectional.only( + top: 8.0, + bottom: 8.0, + ), label: 'Email'.i18n, helperText: 'auth_email_helper_text'.i18n, keyboardType: TextInputType.emailAddress, diff --git a/lib/account/report_issue.dart b/lib/account/report_issue.dart index cf465ffa8..6b2f5f8b6 100644 --- a/lib/account/report_issue.dart +++ b/lib/account/report_issue.dart @@ -88,6 +88,10 @@ class _ReportIssueState extends State { initialValue: emailAddress, controller: emailController, autovalidateMode: AutovalidateMode.disabled, + contentPadding: const EdgeInsetsDirectional.only( + top: 8.0, + bottom: 8.0, + ), label: 'email'.i18n, onChanged: (value) { setState(() {}); From d756eaa38534d44f0533f2839ca2c291924b24ad Mon Sep 17 00:00:00 2001 From: atavism Date: Wed, 6 Mar 2024 12:08:03 -0800 Subject: [PATCH 5/5] update padding on report issue screen to avoid overflow --- lib/account/report_issue.dart | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/account/report_issue.dart b/lib/account/report_issue.dart index 6b2f5f8b6..da6f8c43e 100644 --- a/lib/account/report_issue.dart +++ b/lib/account/report_issue.dart @@ -69,8 +69,8 @@ class _ReportIssueState extends State { resizeToAvoidBottomInset: false, body: Padding( padding: const EdgeInsetsDirectional.only( - start: 25, - end: 23, + start: 20, + end: 20, ), child: Column( mainAxisSize: MainAxisSize.max,