Menu / Picker dropdown: selected item announced as hard-coded English "selected", not as a selection state
Maintainers usually reply within 4 days
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 72/100
- Issue type
- Bug
- Clarity
- Clearly specified
- Activity status
- Active
- Domain
- accessibility, mobile
Research direction
Start in Commands/Menu.swift at RenderDropdownMenuItem, where the check icon's contentDescription is hard-coded to "selected" and the isSelected branch builds two DropdownMenuItem calls. Read how modifier.semantics is applied there, then remove the English description and attach a selected semantics state to both items. Done when the check icon has no hard-coded text and TalkBack announces the selection state in the app's language on a French-locale emulator, or the generated Kotlin shows the semantics on both items.
Written by the indexing model from the issue text.
Description
Environment
- skip-ui 1.63.0 (the code below is unchanged in 1.66.4), Fuse app, native mode, Material3, TalkBack on an Android 15 emulator, app in French
What happens
In the dropdown of a menu-style Picker (or a Menu with a selection), the selected item is announced as "selected. 3 hours": the word "selected" is read as text, in English whatever the app or system language, and it is not the selection state (TalkBack does not say "Selected" the way it does for a selected element).
Why
Commands/Menu.swift, RenderDropdownMenuItem:
selectedIcon = { Icon(imageVector: Icons.Outlined.Check, contentDescription: "selected") }
A hard-coded English content description on the check icon, and no selected semantics on the item.
Suggested fix
- selectedIcon = { Icon(imageVector: Icons.Outlined.Check, contentDescription: "selected") }
+ selectedIcon = { Icon(imageVector: Icons.Outlined.Check, contentDescription: nil) }
...
+ let modifierEtat = modifier.semantics { selected = isSelected }
(pass modifierEtat to both DropdownMenuItem calls of the isSelected branch)
TalkBack then announces the state in the user's language ("Sélectionné" in French), as VoiceOver does with its checkmark.
- Dominant language
- Swift
- Stars
- 334
- Forks
- 95
- Avg merge
- 2d 10h
- Merged PRs (30d)
- 8
Getting set up
- No Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from skiptools/skip-ui
-
Difficulty 2/5 1-3 hours Newbie friendliness 80/100
Maintainers usually reply within 4 days
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
Maintainers usually reply within 4 days
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
Maintainers usually reply within 4 days
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
Maintainers usually reply within 4 days
-
Difficulty 1/5 1-3 hours Newbie friendliness 90/100
Maintainers usually reply within 4 days
All issues in skiptools/skip-ui
Similar issues
-
AndroidAssetManager(env:peer:) in AssetURLProtocol.swift doesn't compile for Android on the Swift nightlyPossibly taken A pull request linked to this issue is open or already merged. Open
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
good first issue help wanted
Difficulty 2/5 1-3 hours Newbie friendliness 85/100
erkamyaman/unslop-anything#579 ·
Maintainers usually reply within 1 day
-
good first issue help wanted
Difficulty 2/5 1-3 hours Newbie friendliness 86/100
erkamyaman/rust-anything#1311 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 1 day
-
bug priority:low status:queued
Difficulty 2/5 1-3 hours Newbie friendliness 83/100
Maintainers usually reply within 1 day