[PR #6222] [PM-29014] Update BitwardenPasswordField semantics to support accessibility for visible passwords #19164

Open
opened 2026-04-15 03:40:54 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/bitwarden/android/pull/6222
Author: @SaintPatrck
Created: 12/3/2025
Status: 🔄 Open

Base: mainHead: PM-29014/talkback-support-for-passwords


📝 Commits (2)

  • ae5e4ca Update BitwardenPasswordField semantics to support accessibility for visible passwords
  • da57763 Fix logic for password field content description

📊 Changes

1 file changed (+16 additions, -0 deletions)

View changed files

📝 ui/src/main/kotlin/com/bitwarden/ui/platform/components/field/BitwardenPasswordField.kt (+16 -0)

📄 Description

🎟️ Tracking

PM-29014
Relates to #6212

📔 Objective

Improve accessibility support in BitwardenPasswordField by ensuring Talkback can read the password aloud when the user chooses to make it visible, while explicitly marking the content as sensitive data.

Behavioral changes:

  • When the "show password" toggle is active, Talkback will now read the actual password text instead of silence or obfuscated characters. This behavior occurs regardless of the system-wide "Speak Passwords" setting due to the custom visual transformation usage.
  • The field is semantically marked as containing sensitive data.

Specific changes:

  • Apply a semantics modifier to the internal TextField in BitwardenPasswordField.
  • Set contentDescription to the actual text value only when showPassword is true; otherwise, it defaults to an empty string.
  • Set the isSensitiveData semantic property to true.

📸 Screenshots


Reminders before review

  • Contributor guidelines followed
  • All formatters and local linters executed and passed
  • Written new unit and / or integration tests where applicable
  • Protected functional changes with optionality (feature flags)
  • Used internationalization (i18n) for all UI strings
  • CI builds passed
  • Communicated to DevOps any deployment requirements
  • Updated any necessary documentation (Confluence, contributing docs) or informed the documentation team

🦮 Reviewer guidelines

  • 👍 (:+1:) or similar for great changes
  • 📝 (:memo:) or ℹ️ (:information_source:) for notes or general info
  • (:question:) for questions
  • 🤔 (:thinking:) or 💭 (:thought_balloon:) for more open inquiry that's not quite a confirmed issue and could potentially benefit from discussion
  • 🎨 (:art:) for suggestions / improvements
  • (:x:) or ⚠️ (:warning:) for more significant problems or concerns needing attention
  • 🌱 (:seedling:) or ♻️ (:recycle:) for future improvements or indications of technical debt
  • ⛏ (:pick:) for minor or nitpick changes

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/bitwarden/android/pull/6222 **Author:** [@SaintPatrck](https://github.com/SaintPatrck) **Created:** 12/3/2025 **Status:** 🔄 Open **Base:** `main` ← **Head:** `PM-29014/talkback-support-for-passwords` --- ### 📝 Commits (2) - [`ae5e4ca`](https://github.com/bitwarden/android/commit/ae5e4cace3b05bb91f7115b119abe2b72c2aa861) Update BitwardenPasswordField semantics to support accessibility for visible passwords - [`da57763`](https://github.com/bitwarden/android/commit/da57763635dda7474b40925c597df75f272e1348) Fix logic for password field content description ### 📊 Changes **1 file changed** (+16 additions, -0 deletions) <details> <summary>View changed files</summary> 📝 `ui/src/main/kotlin/com/bitwarden/ui/platform/components/field/BitwardenPasswordField.kt` (+16 -0) </details> ### 📄 Description ## 🎟️ Tracking PM-29014 Relates to #6212 ## 📔 Objective Improve accessibility support in `BitwardenPasswordField` by ensuring Talkback can read the password aloud when the user chooses to make it visible, while explicitly marking the content as sensitive data. Behavioral changes: * When the "show password" toggle is active, Talkback will now read the actual password text instead of silence or obfuscated characters. This behavior occurs regardless of the system-wide "Speak Passwords" setting due to the custom visual transformation usage. * The field is semantically marked as containing sensitive data. Specific changes: * Apply a `semantics` modifier to the internal `TextField` in `BitwardenPasswordField`. * Set `contentDescription` to the actual text value only when `showPassword` is true; otherwise, it defaults to an empty string. * Set the `isSensitiveData` semantic property to `true`. ## 📸 Screenshots <img width="365" src="https://github.com/user-attachments/assets/3246a5db-b1a6-4821-ae5f-47b857ff3427" /> <img width="365" src="https://github.com/user-attachments/assets/b0b19cfe-f271-49b8-a6a6-0fb50c0de340" /> --- <img width="365" src="https://github.com/user-attachments/assets/bcc29eb2-d5f2-44f3-a88b-5aa34565866a" /> <img width="365" src="https://github.com/user-attachments/assets/7313e83f-e1a9-42fe-9955-0a6188cb4e39" /> ## ⏰ Reminders before review - Contributor guidelines followed - All formatters and local linters executed and passed - Written new unit and / or integration tests where applicable - Protected functional changes with optionality (feature flags) - Used internationalization (i18n) for all UI strings - CI builds passed - Communicated to DevOps any deployment requirements - Updated any necessary documentation (Confluence, contributing docs) or informed the documentation team ## 🦮 Reviewer guidelines <!-- Suggested interactions but feel free to use (or not) as you desire! --> - 👍 (`:+1:`) or similar for great changes - 📝 (`:memo:`) or ℹ️ (`:information_source:`) for notes or general info - ❓ (`:question:`) for questions - 🤔 (`:thinking:`) or 💭 (`:thought_balloon:`) for more open inquiry that's not quite a confirmed issue and could potentially benefit from discussion - 🎨 (`:art:`) for suggestions / improvements - ❌ (`:x:`) or ⚠️ (`:warning:`) for more significant problems or concerns needing attention - 🌱 (`:seedling:`) or ♻️ (`:recycle:`) for future improvements or indications of technical debt - ⛏ (`:pick:`) for minor or nitpick changes --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2026-04-15 03:40:54 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/android#19164