6

Designing an e-commerce website that is accessible, what would be the proper WAI ARIA role-attribute for the "shopping cart" section of the page?

I understand the current available document landmark roles are:

  • article
  • banner
  • complementary
  • contentinfo
  • main
  • navigation
  • search

However, I do not know which of the one I should use for this particular content.

2

I was also looking for an answer to this, but the grid role didn’t feel right because in my case the basket widget contains controls other than the product list itself, for example: the title, the checkout button, the minimize button.

So I googled some more and found this ALA article: “Accessibility: The Missing Ingredient”. It recommends the dialog role and it feels a bit more appropriate to me.

3

Those are not the only ARIA roles available for assignment to UI elements.

Most carts are tabular data structures which means the grid role would be appropriate. The cart could be contained inside a div with a main role.

Here are two relevant pages from WAI.

The roles model

The grid role

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.