Making WordPress.org


Ignore:
Timestamp:
04/20/2017 03:44:38 PM (7 years ago)
Author:
ocean90
Message:

Plugin Directory: Provide more context for "Read more" and "Show less" buttons to improve accessibility.

Props SergeyBiryukov, joedolson.
Fixes #2292.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-plugins/client/components/plugin/sections/index.jsx

    r5024 r5394  
    99    <div>
    1010        <div id={ slug } className={ `section read-more plugin-${ slug }` }>
    11             <h2>{ title }</h2>
     11            <h2 id={ `${ slug }-header` }>{ title }</h2>
    1212            <div dangerouslySetInnerHTML={ { __html: content } } />
    1313        </div>
     
    1616            className="button-link section-toggle"
    1717            aria-controls={ slug }
     18            aria-describedby={ `${ slug }-header` }
    1819            aria-expanded="false"
    1920            data-show-less={ translate( 'Show less' ) }
Note: See TracChangeset for help on using the changeset viewer.