WordPress.org

Make WordPress Core

Changeset 31434


Ignore:
Timestamp:
02/12/2015 05:20:40 AM (6 years ago)
Author:
dd32
Message:

Move the (recently added) .notice admin notices below the first H2, same as the .updated and .error notices.

Props sippis.
Merges [31023] to the 4.1 branch.
Fixes #30885.

Location:
branches/4.1
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/4.1

  • branches/4.1/src/wp-admin/js/common.js

    r30918 r31434  
    172172
    173173$(document).ready( function() {
    174     var checks, first, last, checked, sliced, mobileEvent, transitionTimeout, focusedRowActions,
     174    var checks, first, last, checked, sliced, mobileEvent, transitionTimeout, focusedRowActions, $firstHeading,
    175175        lastClicked = false,
    176176        pageInput = $('input.current-page'),
     
    369369    }
    370370
    371     // Move .updated and .error alert boxes. Don't move boxes designed to be inline.
    372     $('div.wrap h2:first').nextAll('div.updated, div.error').addClass('below-h2');
    373     $('div.updated, div.error').not('.below-h2, .inline').insertAfter( $('div.wrap h2:first') );
     371    // Move .notice, .updated and .error alert boxes. Don't move boxes designed to be inline.
     372    $firstHeading = $( 'div.wrap h2:first' );
     373    $firstHeading.nextAll( 'div.updated, div.error, div.notice' ).addClass( 'below-h2' );
     374    $( 'div.updated, div.error, div.notice' ).not( '.below-h2, .inline' ).insertAfter( $firstHeading );
    374375
    375376    // Init screen meta
Note: See TracChangeset for help on using the changeset viewer.