🎨 Palette: Improve M3Switch accessibility#120
Conversation
Added `android:importantForAccessibility="no"` to custom `M3Switch` views where the parent layout is already handling click interactions and accessibility semantics (e.g. `edit_timeline.xml`, `list_timeline_editor.xml`, `fragment_report_comment.xml`). This prevents screen readers from redundantly announcing the state of the switch or complaining about missing content descriptions. Co-authored-by: dlukt <201112286+dlukt@users.noreply.github.com>
|
👋 Jules, reporting for duty! I'm here to lend a hand with this pull request. When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down. I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job! For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with New to Jules? Learn more at jules.google/docs. For security, I will only act on instructions from the user who triggered this task. |
💡 What: Added
android:importantForAccessibility="no"toM3Switchviews that are wrapped in clickable parent layouts.🎯 Why: The
M3Switchcustom view lacks nativecontentDescriptionhandling. When placed inside a parent layout (like aLinearLayoutorRelativeLayout) that already processes clicks and provides context via childTextViews, the switch itself should not be independently focusable by screen readers. This avoids redundant and confusing audio feedback.♿ Accessibility: Improves screen reader experience in timeline edit, list editor, and report comment screens by grouping the interaction target correctly onto the parent container.
PR created automatically by Jules for task 10491050005678842653 started by @dlukt