Making WordPress.org

Opened 7 years ago

Closed 4 years ago

#3116 closed enhancement (fixed)

Support new "heading" parameter for sessions and speakers shortcodes

Reported by: mrwweb's profile mrwweb Owned by: kau-boy's profile kau-boy
Milestone: Priority: normal
Component: WordCamp Site & Plugins Keywords: needs-patch good-first-bug accessibility
Cc:

Description

Many of the parameters for sessions and speaker shortcodes such as date or group, respectively, encourage outputting subsets of sessions or speakers. If these subsets appear on the same page, it's likely that each group is preceded by a Heading 2.

Since the default shortcode output uses Heading 2s for each title/name, this leads to an overly-flat and arguably inaccurate heading outline that decreases the site's accessibility for screen reader users. For sited users, the visually hierarchy of this is also subpar and makes it harder to scan the [usually extremely long] page.

Therefore, a new "heading" parameter (e.g. [sessions date="YYYY-MM-DD" heading="3"]) should be introduced to allow site users to output more accessible and usable markup.

Change History (10)

#1 @coreymckrill
6 years ago

  • Keywords needs-patch good-first-bug added
  • Type changed from defect to enhancement

This ticket was mentioned in Slack in #meta-wordcamp by coreymckrill. View the logs.


6 years ago

#3 @coreymckrill
6 years ago

  • Owner set to kau-boy
  • Status changed from new to assigned

#4 @iandunn
6 years ago

I think this is an important a11y issue to bring up, but I'm wondering if a shortcode param is the best option to solve it? I don't have any better ideas at the moment, but it seems like there might be a more elegant solution if we brainstorm a bit.

#5 @coreymckrill
6 years ago

We did discuss this in a recent ticket scrub (see also the link to the Slack mention above).

#6 @mrwweb
6 years ago

The solution proposed in the chat seems workable. I theoretically like a more elegant solution, but I think anything other than the shortcode parameter will likely involve unsupported edgecases. I can very quickly come up with realistic use cases for h2, h3, and h4 at a minimum. The idea of whitelisting elements mentioned in the chat makese sense. I can't think of a situation where a non-heading would be appropriate unless triggered by some other shortcode attribute that, for instance, shows speaker links in an unordered list (at which point the heading attribute is probably just ignored).

#7 @iandunn
6 years ago

  • Keywords accessibility added

This ticket was mentioned in Slack in #meta-wordcamp by ryelle. View the logs.


4 years ago

This ticket was mentioned in Slack in #meta-wordcamp by iandunn. View the logs.


4 years ago

#10 @iandunn
4 years ago

  • Keywords changed from needs-patch, good-first-bug, accessibility to needs-patch good-first-bug accessibility
  • Resolution set to fixed
  • Status changed from assigned to closed

The new blocks use an h3, so it doesn't seem like this is still an issue with them. If it is, though, we can reopen this (or create a new ticket in the GitHub repo).

https://github.com/WordPress/wordcamp.org/pull/104

Note: See TracTickets for help on using tickets.