From ffe19266922cdc3f1e8e1df1332e83b55e8c41da Mon Sep 17 00:00:00 2001 From: Oliver Zimmerman <oezimmerman@gmail.com> Date: Mon, 13 Jul 2020 14:14:38 +0100 Subject: [PATCH] Added explanation for location usage in onboarding flow (EXPOSUREAPP-1620) (#849) * Added explanation for location usage in onboarding Added card that explains why location is necessary in the tracing section of the onboarding flow. * removed unused import Co-authored-by: Philipp Woessner <64482866+pwoessner@users.noreply.github.com> --- .../src/main/res/drawable/ic_location.xml | 18 +++++++++++ .../layout/fragment_onboarding_tracing.xml | 3 ++ .../main/res/layout/include_onboarding.xml | 31 +++++++++++++++++-- .../src/main/res/values-de/strings.xml | 6 ++++ .../src/main/res/values-en/strings.xml | 6 ++++ .../src/main/res/values-tr/strings.xml | 6 ++++ .../src/main/res/values/strings.xml | 6 ++++ 7 files changed, 74 insertions(+), 2 deletions(-) create mode 100644 Corona-Warn-App/src/main/res/drawable/ic_location.xml diff --git a/Corona-Warn-App/src/main/res/drawable/ic_location.xml b/Corona-Warn-App/src/main/res/drawable/ic_location.xml new file mode 100644 index 000000000..0b05c1c73 --- /dev/null +++ b/Corona-Warn-App/src/main/res/drawable/ic_location.xml @@ -0,0 +1,18 @@ +<vector xmlns:android="http://schemas.android.com/apk/res/android" + android:width="40dp" + android:height="40dp" + android:viewportWidth="40" + android:viewportHeight="40"> + <path + android:pathData="M20,0L20,0A20,20 0,0 1,40 20L40,20A20,20 0,0 1,20 40L20,40A20,20 0,0 1,0 20L0,20A20,20 0,0 1,20 0z" + android:strokeWidth="1" + android:fillColor="#2296F3" + android:fillType="evenOdd" + android:strokeColor="#00000000"/> + <path + android:pathData="M20,10C16.134,10 13,13.134 13,17C13,22 20,30 20,30C20,30 27,22 27,17C27,13.134 23.866,10 20,10ZM20,19.5C18.619,19.5 17.5,18.381 17.5,17C17.5,15.619 18.619,14.5 20,14.5C21.381,14.5 22.5,15.619 22.5,17C22.5,18.381 21.381,19.5 20,19.5Z" + android:strokeWidth="1" + android:fillColor="#FFFFFF" + android:fillType="nonZero" + android:strokeColor="#00000000"/> +</vector> diff --git a/Corona-Warn-App/src/main/res/layout/fragment_onboarding_tracing.xml b/Corona-Warn-App/src/main/res/layout/fragment_onboarding_tracing.xml index c927d4d09..5ca28ca9c 100644 --- a/Corona-Warn-App/src/main/res/layout/fragment_onboarding_tracing.xml +++ b/Corona-Warn-App/src/main/res/layout/fragment_onboarding_tracing.xml @@ -50,6 +50,9 @@ app:headlineCard="@{@string/onboarding_tracing_headline_consent}" app:illustration="@{@drawable/ic_illustration_tracing_on}" app:illustrationDescription="@{@string/onboarding_tracing_illustration_description}" + app:locationBodyCard="@{@string/onboarding_tracing_location_body}" + app:locationHeadlineCard="@{@string/onboarding_tracing_location_headline}" + app:locationIconCard="@{@drawable/ic_location}" app:layout_constraintBottom_toTopOf="@+id/onboarding_button_next" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintStart_toStartOf="parent" diff --git a/Corona-Warn-App/src/main/res/layout/include_onboarding.xml b/Corona-Warn-App/src/main/res/layout/include_onboarding.xml index c9fa1240c..c3fc8e542 100644 --- a/Corona-Warn-App/src/main/res/layout/include_onboarding.xml +++ b/Corona-Warn-App/src/main/res/layout/include_onboarding.xml @@ -41,6 +41,18 @@ name="bodyEmphasized" type="String" /> + <variable + name="locationIconCard" + type="android.graphics.drawable.Drawable" /> + + <variable + name="locationHeadlineCard" + type="String" /> + + <variable + name="locationBodyCard" + type="String" /> + </data> <ScrollView @@ -119,18 +131,33 @@ tools:text="@string/onboarding_body_emphasized" /> <include - android:id="@+id/onboarding_card" + android:id="@+id/onboarding_location_card" layout="@layout/include_tracing_status_card" android:layout_width="@dimen/match_constraint" android:layout_height="wrap_content" android:layout_marginTop="@dimen/spacing_large" + android:visibility="@{FormatterHelper.formatVisibilityText(locationHeadlineCard)}" + app:body="@{locationBodyCard}" + app:headline="@{locationHeadlineCard}" + app:icon="@{locationIconCard}" + android:focusable="true" + app:layout_constraintEnd_toStartOf="@+id/guideline_card_end" + app:layout_constraintStart_toStartOf="@+id/guideline_card_start" + app:layout_constraintTop_toBottomOf="@+id/onboarding_body_emphasized" /> + + <include + android:id="@+id/onboarding_card" + layout="@layout/include_tracing_status_card" + android:layout_width="@dimen/match_constraint" + android:layout_height="wrap_content" + android:layout_marginTop="@dimen/spacing_medium" android:visibility="@{FormatterHelper.formatVisibilityText(headlineCard)}" app:body="@{bodyCard}" app:headline="@{headlineCard}" android:focusable="true" app:layout_constraintEnd_toStartOf="@+id/guideline_card_end" app:layout_constraintStart_toStartOf="@+id/guideline_card_start" - app:layout_constraintTop_toBottomOf="@+id/onboarding_body_emphasized" /> + app:layout_constraintTop_toBottomOf="@+id/onboarding_location_card" /> <androidx.constraintlayout.widget.Guideline android:id="@+id/guideline_start" diff --git a/Corona-Warn-App/src/main/res/values-de/strings.xml b/Corona-Warn-App/src/main/res/values-de/strings.xml index 566b5d90b..72887768f 100644 --- a/Corona-Warn-App/src/main/res/values-de/strings.xml +++ b/Corona-Warn-App/src/main/res/values-de/strings.xml @@ -380,6 +380,12 @@ <string name="onboarding_tracing_dialog_button_negative">"Zurück"</string> <!-- XACT: onboarding(tracing) - illustraction description, header image --> <string name="onboarding_tracing_illustration_description">"Drei Personen haben die Risiko-Ermittlung auf ihren Smartphones aktiviert, ihre Begegnung wird daher aufgezeichnet."</string> + <!-- XHED: onboarding(tracing) - location explanation for bluetooth headline --> + <string name="onboarding_tracing_location_headline">"Standort Verwendung erlauben"</string> + <!-- XTXT: onboarding(tracing) - location explanation for bluetooth body text --> + <string name="onboarding_tracing_location_body">"Auf Ihren Standort wird nicht zugegriffen. Die Standort Erlaubnis wird benötigt, da Google Android diese für die Verwendung von Bluetooth voraussetzt."</string> + <!-- XBUT: onboarding(tracing) - button enable tracing --> + <string name="onboarding_tracing_location_button">"Geräte-Einstellungen öffnen"</string> <!-- XACT: Onboarding (test) page title --> <string name="onboarding_test_accessibility_title">"Einführung Seite 4 von 5: Falls Sie positiv getestet wurden"</string> <!-- XHED: onboarding(test) - about positive tests --> diff --git a/Corona-Warn-App/src/main/res/values-en/strings.xml b/Corona-Warn-App/src/main/res/values-en/strings.xml index 2e8c65a93..3864d7893 100644 --- a/Corona-Warn-App/src/main/res/values-en/strings.xml +++ b/Corona-Warn-App/src/main/res/values-en/strings.xml @@ -378,6 +378,12 @@ <string name="onboarding_tracing_dialog_button_negative">"Back"</string> <!-- XACT: onboarding(tracing) - illustraction description, header image --> <string name="onboarding_tracing_illustration_description">"Three people have activated exposure logging on their devices, which will log their encounters with each other."</string> + <!-- XHED: onboarding(tracing) - location explanation for bluetooth headline --> + <string name="onboarding_tracing_location_headline">"Allow location use"</string> + <!-- XTXT: onboarding(tracing) - location explanation for bluetooth body text --> + <string name="onboarding_tracing_location_body">"Your location is not being accessed. The location permission is required because Google Android requires this for the use of Bluetooth."</string> + <!-- XBUT: onboarding(tracing) - button enable tracing --> + <string name="onboarding_tracing_location_button">"Open device settings"</string> <!-- XACT: Onboarding (test) page title --> <string name="onboarding_test_accessibility_title">"Onboarding page 4 of 5: If you are diagnosed with COVID-19..."</string> <!-- XHED: onboarding(test) - about positive tests --> diff --git a/Corona-Warn-App/src/main/res/values-tr/strings.xml b/Corona-Warn-App/src/main/res/values-tr/strings.xml index 2934e6ffe..34934ab8f 100644 --- a/Corona-Warn-App/src/main/res/values-tr/strings.xml +++ b/Corona-Warn-App/src/main/res/values-tr/strings.xml @@ -378,6 +378,12 @@ <string name="onboarding_tracing_illustration_description">"Üç kişi cihazlarında maruz kalma günlüğünü etkinleştirdi ve birbirleri ile karşılaşmaları günlüğe kaydedilecektir."</string> <!-- XACT: Onboarding (test) page title --> <string name="onboarding_test_accessibility_title">"Etkinleştirme sayfası 4/5: Size COVID-19 tanısı konduysa..."</string> + <!-- XHED: onboarding(tracing) - location explanation for bluetooth headline --> + <string name="onboarding_tracing_location_headline">"Konum kullanımına izin ver"</string> + <!-- XTXT: onboarding(tracing) - location explanation for bluetooth body text --> + <string name="onboarding_tracing_location_body">"Konumunuza erişilmiyor. Konum izni gereklidir, çünkü Google Android Bluetooth kullanımı için bunu gerektirir."</string> + <!-- XBUT: onboarding(tracing) - button enable tracing --> + <string name="onboarding_tracing_location_button">"Cihaz ayarlarını aç"</string> <!-- XHED: onboarding(test) - about positive tests --> <string name="onboarding_test_headline">"COVID-19 tanısı aldıysanız..."</string> <!-- XHED: onboarding(test) - two/three line headline under an illustration --> diff --git a/Corona-Warn-App/src/main/res/values/strings.xml b/Corona-Warn-App/src/main/res/values/strings.xml index 3565365b2..1652f460e 100644 --- a/Corona-Warn-App/src/main/res/values/strings.xml +++ b/Corona-Warn-App/src/main/res/values/strings.xml @@ -380,6 +380,12 @@ <string name="onboarding_tracing_dialog_button_negative">"Back"</string> <!-- XACT: onboarding(tracing) - illustraction description, header image --> <string name="onboarding_tracing_illustration_description">"Three people have activated exposure logging on their devices, which will log their encounters with each other."</string> + <!-- XHED: onboarding(tracing) - location explanation for bluetooth headline --> + <string name="onboarding_tracing_location_headline">"Allow location use"</string> + <!-- XTXT: onboarding(tracing) - location explanation for bluetooth body text --> + <string name="onboarding_tracing_location_body">"Your location is not being accessed. The location permission is required because Google Android requires this for the use of Bluetooth."</string> + <!-- XBUT: onboarding(tracing) - button enable tracing --> + <string name="onboarding_tracing_location_button">"Open device settings"</string> <!-- XACT: Onboarding (test) page title --> <string name="onboarding_test_accessibility_title">"Onboarding page 4 of 5: If you are diagnosed with COVID-19..."</string> <!-- XHED: onboarding(test) - about positive tests --> -- GitLab