Login screens: a11y

This commit is contained in:
Benoit Marty 2019-11-19 18:44:11 +01:00
parent 8ae9544b48
commit a8f24e5c39
13 changed files with 33 additions and 11 deletions

View File

@ -4,12 +4,13 @@
android:layout_width="match_parent"
android:layout_height="match_parent">
<!-- Note: Gif will be loaded by the code -->
<!-- Note: Animation will be started in the code -->
<ImageView
android:id="@+id/animatedLogoImageView"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:background="@drawable/riot_animated_logo"
android:importantForAccessibility="no"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"

View File

@ -23,7 +23,8 @@
<ImageView
android:id="@+id/logoImageView"
style="@style/LoginTopIcon"
android:layout_gravity="center_horizontal" />
android:layout_gravity="center_horizontal"
android:importantForAccessibility="no" />
<Space
android:layout_width="wrap_content"

View File

@ -12,6 +12,7 @@
android:id="@+id/logoImageView"
style="@style/LoginTopIcon"
android:layout_gravity="center_horizontal"
android:importantForAccessibility="no"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />
@ -26,15 +27,16 @@
android:text="@string/auth_recaptcha_message"
app:layout_constraintTop_toBottomOf="@+id/logoImageView" />
<!-- contentDescription does not work on WebView? -->
<WebView
android:id="@+id/loginCaptchaWevView"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_marginTop="8dp"
android:contentDescription="@string/login_a11y_captcha_container"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintTop_toBottomOf="@+id/loginCaptchaNotice" />
<ProgressBar
android:id="@+id/loginCaptchaProgress"
android:layout_width="60dp"

View File

@ -23,7 +23,8 @@
<ImageView
android:id="@+id/logoImageView"
style="@style/LoginTopIcon"
android:layout_gravity="center_horizontal" />
android:layout_gravity="center_horizontal"
android:importantForAccessibility="no" />
<TextView
android:id="@+id/loginGenericTextInputFormTitle"

View File

@ -22,7 +22,8 @@
<ImageView
android:id="@+id/logoImageView"
style="@style/LoginTopIcon"
android:layout_gravity="center_horizontal" />
android:layout_gravity="center_horizontal"
android:importantForAccessibility="no" />
<TextView
android:id="@+id/resetPasswordTitle"

View File

@ -22,7 +22,8 @@
<ImageView
android:id="@+id/logoImageView"
style="@style/LoginTopIcon"
android:layout_gravity="center_horizontal" />
android:layout_gravity="center_horizontal"
android:importantForAccessibility="no" />
<TextView
android:layout_width="wrap_content"

View File

@ -16,6 +16,7 @@
<ImageView
android:id="@+id/loginServerLogo"
style="@style/LoginTopIcon"
android:importantForAccessibility="no"
android:transitionName="loginLogoTransition"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
@ -49,6 +50,7 @@
android:layout_height="wrap_content"
android:layout_marginTop="24dp"
android:background="@drawable/bg_login_server_selector"
android:contentDescription="@string/login_a11y_choose_matrix_org"
android:minHeight="80dp"
android:paddingStart="@dimen/layout_horizontal_margin"
android:paddingEnd="@dimen/layout_horizontal_margin"
@ -60,6 +62,7 @@
android:id="@+id/loginServerChoiceMatrixOrgIcon"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:importantForAccessibility="no"
android:src="@drawable/ic_logo_matrix_org"
app:layout_constraintBottom_toTopOf="@+id/loginServerChoiceMatrixOrgText"
app:layout_constraintStart_toStartOf="parent"
@ -87,6 +90,7 @@
android:layout_height="wrap_content"
android:layout_marginTop="@dimen/layout_vertical_margin"
android:background="@drawable/bg_login_server_selector"
android:contentDescription="@string/login_a11y_choose_modular"
android:minHeight="80dp"
android:paddingStart="@dimen/layout_horizontal_margin"
android:paddingEnd="0dp"
@ -98,6 +102,7 @@
android:id="@+id/loginServerChoiceModularIcon"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:importantForAccessibility="no"
android:src="@drawable/ic_logo_modular"
app:layout_constraintBottom_toTopOf="@+id/loginServerChoiceModularText"
app:layout_constraintStart_toStartOf="parent"
@ -137,6 +142,7 @@
android:layout_height="wrap_content"
android:layout_marginTop="@dimen/layout_vertical_margin"
android:background="@drawable/bg_login_server_selector"
android:contentDescription="@string/login_a11y_choose_other"
android:minHeight="80dp"
android:paddingStart="@dimen/layout_horizontal_margin"
android:paddingEnd="@dimen/layout_horizontal_margin"

View File

@ -24,12 +24,14 @@
android:id="@+id/logoImageView"
style="@style/LoginTopIcon"
android:layout_gravity="center_horizontal"
android:layout_marginBottom="130dp" />
android:layout_marginBottom="130dp"
android:importantForAccessibility="no" />
<ImageView
android:id="@+id/loginServerUrlFormIcon"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:importantForAccessibility="no"
android:src="@drawable/ic_logo_modular" />
<TextView

View File

@ -26,6 +26,7 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="172dp"
android:importantForAccessibility="no"
android:visibility="gone"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/loginSignupSigninLogo"

View File

@ -38,6 +38,7 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="2dp"
android:importantForAccessibility="no"
android:src="@drawable/ic_login_splash_message_circle"
android:tint="?vctr_notice_secondary"
app:layout_constraintStart_toStartOf="parent"
@ -62,6 +63,7 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="2dp"
android:importantForAccessibility="no"
android:src="@drawable/ic_login_splash_lock"
android:tint="?vctr_notice_secondary"
app:layout_constraintStart_toStartOf="parent"
@ -85,6 +87,7 @@
android:id="@+id/loginSplashPicto3"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:importantForAccessibility="no"
android:src="@drawable/ic_login_splash_sliders"
android:tint="?vctr_notice_secondary"
app:layout_constraintStart_toStartOf="parent"

View File

@ -9,6 +9,7 @@
<ImageView
android:id="@+id/logoImageView"
style="@style/LoginTopIcon"
android:importantForAccessibility="no"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />

View File

@ -10,8 +10,6 @@
android:id="@+id/adapter_item_policy_checkbox"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="16dp"
android:layout_marginLeft="16dp"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />
@ -37,8 +35,7 @@
android:id="@+id/adapter_item_policy_arrow"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginEnd="16dp"
android:layout_marginRight="16dp"
android:importantForAccessibility="no"
android:rotationY="@integer/rtl_mirror_flip"
android:src="@drawable/ic_material_chevron_right_black"
app:layout_constraintBottom_toBottomOf="parent"

View File

@ -96,4 +96,9 @@
<string name="login_signup_submit">Next</string>
<string name="login_signup_error_user_in_use">That username is taken</string>
<string name="login_a11y_choose_matrix_org">Select matrix.org</string>
<string name="login_a11y_choose_modular">Select modular</string>
<string name="login_a11y_choose_other">Select a custom homeserver</string>
<string name="login_a11y_captcha_container">Please perform the captcha challenge</string>
</resources>