🎨 Polish: Improve accessibility touch targets#697
Conversation
Moved explicit `Modifier.size(24.dp)` from `IconButton` containers to their inner `Icon` children in `MainActivity.kt` and `ChatActivity.kt`. This prevents explicitly overriding the default 48x48dp minimum touch target required by Android accessibility guidelines while maintaining the correct visual icon size. Co-authored-by: yuga-hashimoto <74749461+yuga-hashimoto@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. |
Moved explicit `Modifier.size(24.dp)` from `IconButton` containers to their inner `Icon` children in `MainActivity.kt` and `ChatActivity.kt`. This prevents explicitly overriding the default 48x48dp minimum touch target required by Android accessibility guidelines while maintaining the correct visual icon size. Also replaced explicit `https://repo1.maven.org/maven2/` with `mavenCentral()` to prevent 403 Forbidden errors in CI. Co-authored-by: yuga-hashimoto <74749461+yuga-hashimoto@users.noreply.github.com>
💡 What
Moved the
Modifier.size()from theIconButtondirectly to theIconchild for the "Settings", "Refresh", and "Stop" buttons inMainActivityandChatActivity.🎯 Why
Android accessibility guidelines require interactive elements to have a minimum touch target size of 48x48dp. When
Modifier.size(24.dp)is applied directly to anIconButton, it forces the button's total interactive area to shrink to 24x24dp, making it difficult for users to tap. By moving the modifier to the innerIcon, the visual graphic remains 24x24dp, but Compose automatically pads the outerIconButtonto meet the 48x48dp minimum accessible touch bounds.📸 Before/After
IconButtontouch bounds were constrained to 24x24dp.IconButtontouch bounds expand to the standard 48x48dp accessible minimum, while the icon visually remains 24dp.♿ Accessibility
Improves tap target sizing for users with motor impairments, complying with WCAG and Android's minimum touch target guidelines.
PR created automatically by Jules for task 14226495084689334365 started by @yuga-hashimoto