Make WordPress Core


Ignore:
Timestamp:
09/28/2016 07:53:07 PM (9 years ago)
Author:
afercia
Message:

Administration: Improve the usage of the button CSS classes.

Introduces some consistency in the usage of the button CSS classes, fixes the
focus style for accessibility and responsiveness of the buttons.

  • Adds the button class to all primary buttons make them responsive
  • Removes all secondary-button classes and replaces it with button when needed. button-secondary shouldn't be used and exists just for backward compatibility reasons
  • Replaces classes inside submit_button() with a shorthand for some buttons, and use an empty string for the default button class. Passing button is unnecessary
  • Adjusts get_submit_button() to remove empty items

Props iseulde, dimchik, chris_d2d, mhowell, afercia.
Fixes #27314, #37138, #37448.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/network/themes.php

    r38657 r38672  
    159159
    160160                        if ( 1 == $themes_to_delete ) {
    161                             submit_button( __( 'Yes, delete this theme' ), 'button', 'submit', false );
     161                            submit_button( __( 'Yes, delete this theme' ), '', 'submit', false );
    162162                        } else {
    163                             submit_button( __( 'Yes, delete these themes' ), 'button', 'submit', false );
     163                            submit_button( __( 'Yes, delete these themes' ), '', 'submit', false );
    164164                        }
    165165                    ?>
     
    169169                ?>
    170170                <form method="post" action="<?php echo $referer ? esc_url( $referer ) : ''; ?>" style="display:inline;">
    171                     <?php submit_button( __( 'No, return me to the theme list' ), 'button', 'submit', false ); ?>
     171                    <?php submit_button( __( 'No, return me to the theme list' ), '', 'submit', false ); ?>
    172172                </form>
    173173            </div>
Note: See TracChangeset for help on using the changeset viewer.