[wp-trac] [WordPress Trac] #57503: Why does mejs audio player have tabindex="0" on the container div?

WordPress Trac noreply at wordpress.org
Wed Jan 18 19:54:59 UTC 2023


#57503: Why does mejs audio player have tabindex="0" on the container div?
---------------------------+-----------------------------
 Reporter:  squarecandy    |      Owner:  (none)
     Type:  defect (bug)   |     Status:  new
 Priority:  normal         |  Milestone:  Awaiting Review
Component:  Media          |    Version:  6.1.1
 Severity:  minor          |   Keywords:
  Focuses:  accessibility  |
---------------------------+-----------------------------
 Hi All -

 Just wondering why the shortcode/mejs audio player has the whole container
 as focusable when it's only the buttons inside it that are tied to
 events/actions you can take.

 {{{
 <div id="mep_7" class="mejs-container wp-audio-shortcode mejs-audio"
 tabindex="0" role="application" aria-label="Audio Player">
 <div class="mejs-inner">
 // ... etc
 </div></div>
 }}}

 Is this a best practice to make the whole player focusable in addition to
 the individual buttons?

 If yes, what's the purpose and do we need to ensure that a visible outline
 is applied when it's focused?

 If no, can this be removed from player HTML output?

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/57503>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list