From e5fd2c8cc03535bfd02fe7cd28eba51530ec7985 Mon Sep 17 00:00:00 2001 From: alansley Date: Wed, 7 Aug 2024 09:22:14 +1000 Subject: [PATCH] AccessibilityId refactor WIP --- .../conversation/start/home/StartConversation.kt | 2 +- .../securesms/conversation/start/newmessage/NewMessage.kt | 2 +- .../java/org/thoughtcrime/securesms/home/SeedReminder.kt | 2 +- .../securesms/onboarding/loadaccount/LoadAccount.kt | 2 +- content-descriptions/src/main/res/values/strings.xml | 8 ++++---- 5 files changed, 8 insertions(+), 8 deletions(-) diff --git a/app/src/main/java/org/thoughtcrime/securesms/conversation/start/home/StartConversation.kt b/app/src/main/java/org/thoughtcrime/securesms/conversation/start/home/StartConversation.kt index 90c48e1ab5..61f92261b9 100644 --- a/app/src/main/java/org/thoughtcrime/securesms/conversation/start/home/StartConversation.kt +++ b/app/src/main/java/org/thoughtcrime/securesms/conversation/start/home/StartConversation.kt @@ -72,7 +72,7 @@ internal fun StartConversationScreen( ItemButton( textId = R.string.sessionInviteAFriend, icon = R.drawable.ic_invite_friend, - Modifier.contentDescription(R.string.AccessibilityId_invite_friend_button), + Modifier.contentDescription(R.string.AccessibilityId_sessionInviteAFriend), onClick = delegate::onInviteFriend ) Column( diff --git a/app/src/main/java/org/thoughtcrime/securesms/conversation/start/newmessage/NewMessage.kt b/app/src/main/java/org/thoughtcrime/securesms/conversation/start/newmessage/NewMessage.kt index d298c4e8e8..7f5d30fe33 100644 --- a/app/src/main/java/org/thoughtcrime/securesms/conversation/start/newmessage/NewMessage.kt +++ b/app/src/main/java/org/thoughtcrime/securesms/conversation/start/newmessage/NewMessage.kt @@ -143,7 +143,7 @@ private fun EnterAccountId( BorderlessButtonWithIcon( text = stringResource(R.string.messageNewDescriptionMobile), modifier = Modifier - .contentDescription(R.string.AccessibilityId_help_desk_link) + .contentDescription(R.string.AccessibilityId_messageNewDescriptionMobile) .padding(horizontal = LocalDimensions.current.mediumSpacing) .fillMaxWidth(), style = LocalType.current.small, diff --git a/app/src/main/java/org/thoughtcrime/securesms/home/SeedReminder.kt b/app/src/main/java/org/thoughtcrime/securesms/home/SeedReminder.kt index 02448722cf..617f98a9cd 100644 --- a/app/src/main/java/org/thoughtcrime/securesms/home/SeedReminder.kt +++ b/app/src/main/java/org/thoughtcrime/securesms/home/SeedReminder.kt @@ -65,7 +65,7 @@ internal fun SeedReminder(startRecoveryPasswordActivity: () -> Unit) { text = stringResource(R.string.theContinue), modifier = Modifier .align(Alignment.CenterVertically) - .contentDescription(R.string.AccessibilityId_reveal_recovery_phrase_button), + .contentDescription(R.string.AccessibilityId_recoveryPasswordBanner), onClick = startRecoveryPasswordActivity ) } diff --git a/app/src/main/java/org/thoughtcrime/securesms/onboarding/loadaccount/LoadAccount.kt b/app/src/main/java/org/thoughtcrime/securesms/onboarding/loadaccount/LoadAccount.kt index b822931dcc..18d2c8db37 100644 --- a/app/src/main/java/org/thoughtcrime/securesms/onboarding/loadaccount/LoadAccount.kt +++ b/app/src/main/java/org/thoughtcrime/securesms/onboarding/loadaccount/LoadAccount.kt @@ -100,7 +100,7 @@ private fun RecoveryPassword(state: State, onChange: (String) -> Unit = {}, onCo SessionOutlinedTextField( text = state.recoveryPhrase, modifier = Modifier.fillMaxWidth(), - contentDescription = stringResource(R.string.AccessibilityId_recoveryPhrase), + contentDescription = stringResource(R.string.AccessibilityId_recoveryPasswordRestore), placeholder = stringResource(R.string.recoveryPasswordEnter), onChange = onChange, onContinue = onContinue, diff --git a/content-descriptions/src/main/res/values/strings.xml b/content-descriptions/src/main/res/values/strings.xml index 19230ff92e..aa96295571 100644 --- a/content-descriptions/src/main/res/values/strings.xml +++ b/content-descriptions/src/main/res/values/strings.xml @@ -23,10 +23,10 @@ Open URL Terms of service button Privacy policy button - Recovery phrase input - Reveal recovery phrase button - Help desk link - Invite friend button + Recovery phrase input + Reveal recovery phrase button + Help desk link + Invite friend button Create session ID Link a device