Make WordPress Core

Ticket #50686: 50686.1.patch

File 50686.1.patch, 1.5 KB (added by sabernhardt, 4 years ago)

using more exclusive CSS selector .form-invalid input:not(.button):not(#custom-menu-item-name) and adding required attribute

  • src/wp-admin/css/forms.css

     
    238238        color: #72777c;
    239239}
    240240
    241 .form-invalid input,
    242 .form-invalid input:focus,
     241.form-invalid input:not(.button):not(#custom-menu-item-name),
     242.form-invalid input:not(.button):not(#custom-menu-item-name):focus,
    243243.form-invalid select,
    244244.form-invalid select:focus {
    245245        border-color: #dc3232 !important;
  • src/wp-admin/nav-menus.php

     
    961961                                        <div id="nav-menu-header">
    962962                                                <div class="major-publishing-actions wp-clearfix">
    963963                                                        <label class="menu-name-label" for="menu-name"><?php _e( 'Menu Name' ); ?></label>
    964                                                         <input name="menu-name" id="menu-name" type="text" class="menu-name regular-text menu-item-textbox" <?php echo $menu_name_val . $menu_name_aria_desc; ?> />
     964                                                        <input name="menu-name" id="menu-name" type="text" class="menu-name regular-text menu-item-textbox" <?php echo $menu_name_val . $menu_name_aria_desc; ?> required="required" />
    965965                                                        <div class="publishing-action">
    966966                                                                <?php submit_button( empty( $nav_menu_selected_id ) ? __( 'Create Menu' ) : __( 'Save Menu' ), 'primary large menu-save', 'save_menu', false, array( 'id' => 'save_menu_header' ) ); ?>
    967967                                                        </div><!-- END .publishing-action -->