Making WordPress.org


Ignore:
Timestamp:
01/18/2018 06:36:37 PM (6 years ago)
Author:
obenland
Message:

DevHub: Add a notification for screen readers after voting on a user contributed note

Props keesiemeijer.
Fixes #1819.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-developer/inc/user-content-voting.php

    r5432 r6400  
    6565        // Only need to enqueue voting-related resources if there are comments to vote on.
    6666        if ( self::user_can_vote() && is_singular() && '0' != get_comments_number() ) {
    67             wp_register_script( 'wporg-developer-user-notes-voting', get_template_directory_uri() . '/js/user-notes-voting.js', array(), '20160623', true );
     67            wp_register_script( 'wporg-developer-user-notes-voting', get_template_directory_uri() . '/js/user-notes-voting.js', array( 'wp-a11y' ), '20160623', true );
    6868            wp_localize_script( 'wporg-developer-user-notes-voting', 'ajaxurl', admin_url( 'admin-ajax.php' ) );
    6969            wp_enqueue_script( 'wporg-developer-user-notes-voting' );
     
    307307        }
    308308
    309         echo '<div class="user-note-voting" data-nonce="' . esc_attr( $nonce ) . '">';
     309        echo '<div id="user-note-voting" class="user-note-voting" data-nonce="' . esc_attr( $nonce ) . '">';
    310310
    311311        // Up vote link
Note: See TracChangeset for help on using the changeset viewer.