From 329ca4d1b0b2f8323a175075daaca7d64d4d888b Mon Sep 17 00:00:00 2001 From: Jay Panchal Date: Tue, 12 Nov 2024 17:41:48 +0530 Subject: [PATCH 1/2] Set common appbar in connectId screens Set common app bar in connectId screens --- app/AndroidManifest.xml | 1 + app/res/drawable/bottom_shadow.xml | 11 + .../drawable/ic_connect_action_overflow.xml | 13 + app/res/drawable/ic_connect_arrow_back.xml | 13 + app/res/layout/connectid_common_title_bar.xml | 72 ++++ app/res/layout/fragment_recovery_code.xml | 18 +- .../fragment_secondary_phone_number.xml | 342 +++++++++--------- app/res/layout/fragment_signup.xml | 16 +- .../layout/screen_connect_password_verify.xml | 16 +- .../layout/screen_connect_phone_verify.xml | 16 +- .../layout/screen_connect_primary_phone.xml | 16 +- app/res/layout/screen_connect_verify.xml | 17 +- app/res/values/themes.xml | 38 ++ .../activities/connect/ConnectIdActivity.java | 6 - .../fragments/BreadcrumbBarFragment.java | 10 +- .../ConnectIDSecondaryPhoneNumber.java | 11 +- .../connectId/ConnectIDSignupFragment.java | 11 +- .../ConnectIdBiometricConfigFragment.java | 15 +- ...ConnectIdPasswordVerificationFragment.java | 11 +- .../connectId/ConnectIdPhoneFragment.java | 11 +- .../ConnectIdPhoneVerificationFragmnet.java | 11 +- .../connectId/ConnectIdPinFragment.java | 22 +- .../commcare/utils/ConnectIdAppBarUtils.java | 84 +++++ .../commcare/views/connect/CustomOtpView.java | 159 ++++++++ 24 files changed, 747 insertions(+), 193 deletions(-) create mode 100644 app/res/drawable/bottom_shadow.xml create mode 100644 app/res/drawable/ic_connect_action_overflow.xml create mode 100644 app/res/drawable/ic_connect_arrow_back.xml create mode 100644 app/res/layout/connectid_common_title_bar.xml create mode 100644 app/src/org/commcare/utils/ConnectIdAppBarUtils.java create mode 100644 app/src/org/commcare/views/connect/CustomOtpView.java diff --git a/app/AndroidManifest.xml b/app/AndroidManifest.xml index da9698ed6b..8e2b3444dc 100644 --- a/app/AndroidManifest.xml +++ b/app/AndroidManifest.xml @@ -171,6 +171,7 @@ + + + + + + + \ No newline at end of file diff --git a/app/res/drawable/ic_connect_action_overflow.xml b/app/res/drawable/ic_connect_action_overflow.xml new file mode 100644 index 0000000000..07e41af307 --- /dev/null +++ b/app/res/drawable/ic_connect_action_overflow.xml @@ -0,0 +1,13 @@ + + + + + + \ No newline at end of file diff --git a/app/res/drawable/ic_connect_arrow_back.xml b/app/res/drawable/ic_connect_arrow_back.xml new file mode 100644 index 0000000000..98a528a4af --- /dev/null +++ b/app/res/drawable/ic_connect_arrow_back.xml @@ -0,0 +1,13 @@ + + + + + + \ No newline at end of file diff --git a/app/res/layout/connectid_common_title_bar.xml b/app/res/layout/connectid_common_title_bar.xml new file mode 100644 index 0000000000..d63b6908ef --- /dev/null +++ b/app/res/layout/connectid_common_title_bar.xml @@ -0,0 +1,72 @@ + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/app/res/layout/fragment_recovery_code.xml b/app/res/layout/fragment_recovery_code.xml index 60ecec7874..162dc98c5a 100644 --- a/app/res/layout/fragment_recovery_code.xml +++ b/app/res/layout/fragment_recovery_code.xml @@ -8,12 +8,28 @@ android:background="@color/white" android:orientation="vertical"> + + + + + - + android:layout_height="match_parent" + android:orientation="vertical"> - - - - - - - - - - - - + + + + + + + + android:background="@color/white" + android:orientation="vertical"> - - + + + + + - + + android:layout_below="@id/secondary_phone_sub_title" + android:layout_marginHorizontal="16dp" + android:layout_marginTop="16dp" + android:orientation="horizontal"> + + + + + + - - - - - - + android:orientation="vertical"> + + + + + + + + + + + - - - - + - - - + + + + - - + + \ No newline at end of file diff --git a/app/res/layout/fragment_signup.xml b/app/res/layout/fragment_signup.xml index 7a6be6f251..47aab9e627 100644 --- a/app/res/layout/fragment_signup.xml +++ b/app/res/layout/fragment_signup.xml @@ -12,13 +12,27 @@ android:id="@+id/firstLayout" android:layout_width="match_parent" android:layout_height="match_parent" - android:layout_marginTop="60dp" android:orientation="vertical"> + + + + + diff --git a/app/res/layout/screen_connect_password_verify.xml b/app/res/layout/screen_connect_password_verify.xml index a3c8ba8db1..be5fd060a8 100644 --- a/app/res/layout/screen_connect_password_verify.xml +++ b/app/res/layout/screen_connect_password_verify.xml @@ -7,12 +7,26 @@ android:background="@color/white" android:orientation="vertical"> + + + + + diff --git a/app/res/layout/screen_connect_phone_verify.xml b/app/res/layout/screen_connect_phone_verify.xml index 7264d83731..be368cfaf6 100644 --- a/app/res/layout/screen_connect_phone_verify.xml +++ b/app/res/layout/screen_connect_phone_verify.xml @@ -9,12 +9,26 @@ android:background="@color/white" android:orientation="vertical"> + + + + + diff --git a/app/res/layout/screen_connect_primary_phone.xml b/app/res/layout/screen_connect_primary_phone.xml index c6c8fa9f5c..da42e1f4b4 100644 --- a/app/res/layout/screen_connect_primary_phone.xml +++ b/app/res/layout/screen_connect_primary_phone.xml @@ -8,12 +8,26 @@ android:background="@color/white" android:orientation="vertical"> + + + + + diff --git a/app/res/layout/screen_connect_verify.xml b/app/res/layout/screen_connect_verify.xml index 5f5a010b0b..408fced1d5 100644 --- a/app/res/layout/screen_connect_verify.xml +++ b/app/res/layout/screen_connect_verify.xml @@ -10,15 +10,28 @@ + + + + + @style/ThemeOverlay.MaterialComponents.MaterialCalendar + +