Cofi icon indicating copy to clipboard operation
Cofi copied to clipboard

Accessibility Issues on Setting Screen

Open zhou-zhoukang opened this issue 6 months ago • 0 comments

Describe the bug Hi Developers! Thank you for your dedication to this excellent open-source app. However, I noticed that there are some accessibility issues in some settings page.

Taking the example of the interface shown in the figure below, the red boxes indicate the order in which components are focused sequentially by screen readers when visually impaired users navigate through the UI. When they focus on the Switch, they will only hear its current on/off state but cannot understand what specific feature this Switch is enabling/disabling. This requires them to perform additional left/right swipes to obtain contextual information about the Switch. This may creates unnecessary cognitive load.

Screenshots Image

Expected behavior A more accessible approach in this situation might be to set the onCheckedChange of the Switch to null, and instead move the click event of the Switch to the List Item, as shown in the code example below.

ListItem(  
    modifier = Modifier.clickable{},  
    trailingContent = {  
        Switch(  
            checked = true,  
            onCheckedChange = null,  
            enabled = true,  
        )  
    }  
)

Additional context Additionally, adding an onClickLabel to clickable controls is also a very good practice. This can be done as shown in the code example below. Taking a button as an example, before adding the label, the screen reader would announce "Double tap to activate" when focusing on the button. After adding the label, it would announce "Double tap to enter", making the button's purpose much clearer and more intuitive.

modifiler = Modifier.semantics {  
   onClick(label = "enter") { }
},

I completely understand if this is a lower priority because it is just a minor accessibility issue. Thank you for your hard work!

zhou-zhoukang avatar Jun 11 '25 04:06 zhou-zhoukang