Skip to:
Content

BuddyPress.org

Changeset 11951


Ignore:
Timestamp:
04/05/2018 12:16:07 AM (4 years ago)
Author:
mercime
Message:

BP Nouveau: Improve HTML Markup of Messages bulk actions.

-Remove nesting of input controls within the label tags for a cleaner markup.
-Move the list element containing the checkbox and bulk actions closer to the
message list especially for mobile view.
-Reveal the label tag for the checkbox so that sighted users may see what the checkbox is for.
Style and JS support for this change have already been committed in r11916 and
r11920.

Fixes #7714.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-templates/bp-nouveau/buddypress/common/js-templates/messages/index.php

    r11913 r11951  
    7373
    7474<script type="text/html" id="tmpl-bp-messages-filters">
    75     <li class="user-messages-bulk-actions"></li>
    7675    <li class="user-messages-search" role="search" data-bp-search="{{data.box}}">
    7776        <div class="bp-search messages-search">
     
    8887        </div>
    8988    </li>
     89    <li class="user-messages-bulk-actions"></li>
    9090</script>
    9191
    9292<script type="text/html" id="tmpl-bp-bulk-actions">
    93     <label for="user_messages_select_all">
    94         <input type="checkbox" id="user_messages_select_all" value="1"/>
    95         <span class="bp-screen-reader-text"><?php esc_html_e( 'Select All Messages', 'buddypress' ); ?></span>
    96     </label>
    97 <div class="bulk-actions-wrap bp-hide">
     93    <input type="checkbox" id="user_messages_select_all" value="1"/>
     94    <label for="user_messages_select_all"><?php esc_html_e( 'All Messages', 'buddypress' ); ?></label>
     95    <div class="bulk-actions-wrap bp-hide">
    9896        <div class="bulk-actions select-wrap">
    9997            <label for="user-messages-bulk-actions" class="bp-screen-reader-text">
     
    107105            <span class="select-arrow" aria-hidden="true"></span>
    108106        </div>
    109         <button class="messages-button bulk-apply" type="submit">
     107        <button class="messages-button bulk-apply bp-tooltip" type="submit" data-bp-tooltip="<?php echo esc_attr( 'Apply', 'buddypress' ); ?>">
    110108            <span class="dashicons dashicons-yes" aria-hidden="true"></span>
    111109            <span class="bp-screen-reader-text"><?php esc_html_e( 'Apply', 'buddypress' ); ?></span>
     
    116114<script type="text/html" id="tmpl-bp-messages-thread">
    117115    <div class="thread-cb">
    118         <label for="bp-message-thread-{{data.id}}">
    119             <input class="message-check" type="checkbox" name="message_ids[]" id="bp-message-thread-{{data.id}}" value="{{data.id}}">
    120             <span class="bp-screen-reader-text"><?php esc_html_e( 'Select this message', 'buddypress' ); ?></span>
    121         </label>
     116        <input class="message-check" type="checkbox" name="message_ids[]" id="bp-message-thread-{{data.id}}" value="{{data.id}}">
     117        <label for="bp-message-thread-{{data.id}}" class="bp-screen-reader-text"><?php esc_html_e( 'Select this message', 'buddypress' ); ?></label>
    122118    </div>
    123119    <div class="thread-from">
Note: See TracChangeset for help on using the changeset viewer.