Closed Bug 1068698 Opened 10 years ago Closed 10 years ago

Email list should be listbox with list items.

Categories

(Firefox OS Graveyard :: Gaia::E-Mail, defect)

ARM
Gonk (Firefox OS)
defect
Not set
normal

Tracking

(b2g-v2.2 fixed, b2g-master fixed)

RESOLVED FIXED
2.2 S5 (6feb)
Tracking Status
b2g-v2.2 --- fixed
b2g-master --- fixed

People

(Reporter: MarcoZ, Assigned: aurelien.levy)

References

Details

(Keywords: access, Whiteboard: [b2ga11y p=1])

Attachments

(1 file)

Fix the semantics so the e-mail list is a real listbox with list items. Either listbox + options or ul with li elements, since these are read-only unless editing. But for the multi-select part, it's probably easier to go with listbox and option roles.
Hi, I don't think we can use listbox because listbox need an aria-selected option and in our case there isn't one. I propose to use role list and listitem. What do you think ?
Flags: needinfo?(mzehe)
No, role="listbox" is equivalent to a select with the size attribute greater 1. That also allows for no item to be selected. We have other examples where we use role listbox and option. If needed, Yura can elaborate.
Flags: needinfo?(mzehe) → needinfo?(yzenevich)
I concur, we should use listbox and option in this case.
Flags: needinfo?(yzenevich)
ok so without any aria-selected by default then when focus get on one of the option add it ? I also propose to had a aria-labelledby referring to the h1
Flags: needinfo?(yzenevich)
(In reply to aurelien levy from comment #4)
> ok so without any aria-selected by default then when focus get on one of the
> option add it ? I also propose to had a aria-labelledby referring to the h1

So there are 2 modes of operation for the message list: when it's in read mode, activation will result in navigation to a different card, so selected state will not matter. In edit mode where the messages can be selected we do indeed need to track aria-selected programmatically.

In Email app in general there s preference established by the team to avoid using ids which means we can't really use labeled by or described by. This means we need to duplicate the h1 content as an aria-label. I realise this is extra work but that's the state of things ATM.
Flags: needinfo?(yzenevich)
not quite sure about the fix in the js file, the objective is to label the list with the content of the h1
Attachment #8533268 - Flags: review?(jrburke)
Attachment #8533268 - Flags: a11y-review?(yzenevich)
Comment on attachment 8533268 [details]
Bug 1068698 - Email list should be listbox with list items

I believe this is a bit tricky as it should also work in edit mode, when you can multi-select 1 or more emails. The last time I tried, the just an option is not enough as there's going to be an internal checkbox that would need to be hidden from the screen reader in favor of multi selectable listbox.
Attachment #8533268 - Flags: a11y-review?(yzenevich)
Comment on attachment 8533268 [details]
Bug 1068698 - Email list should be listbox with list items

Just one formatting change suggested, details in a message in the pull request. flip review back to me when done and it should be easy to land. I assume the aria choices are correct, still learning those, just validating the mechanics of the code change.
Attachment #8533268 - Flags: review?(jrburke)
Hi Aurelien,

Let me know if you are still interested in getting this but finished up (that would be really awesome). If so I can give you more detailed description of things that we would ideally want to be addressed as part of this but besides fixing the roles and labels.
Flags: needinfo?(aurelien.levy)
Hi sorry, 
I'm quite buzy at work at the moment I've done the fix asked by James still need to do the rebase thing but I still get stuck with this everytime
Flags: needinfo?(aurelien.levy)
I think it's ok now
Comment on attachment 8533268 [details]
Bug 1068698 - Email list should be listbox with list items

This looks good for the default case. I will follow up with the improvements to the workflow when more messages need to be/are loaded.
Attachment #8533268 - Flags: review?(jrburke)
Assigning for tracking
Assignee: nobody → aurelien.levy
Status: NEW → ASSIGNED
Comment on attachment 8533268 [details]
Bug 1068698 - Email list should be listbox with list items

Looks simple enough. If you need me to do the merge just let me know.
Attachment #8533268 - Flags: review?(jrburke) → review+
Select mode will be addressed in bug 1068703.
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Comment on attachment 8533268 [details]
Bug 1068698 - Email list should be listbox with list items

[Approval Request Comment] This pull request fixes the accessibility of the message list in the email app.
[Bug caused by] (feature/regressing bug #): improvement not a bug
[User impact] if declined: If declined the user will not be able to select and navigate to email from the list of emails.
[Testing completed]: On device
[Risk to taking this patch] (and alternatives if risky): Low, only adding accessibility specific attributes
[String changes made]: none
Attachment #8533268 - Flags: approval-gaia-v2.2?
Attachment #8533268 - Flags: approval-gaia-v2.2? → approval-gaia-v2.2+
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: