WordPress.org

Make WordPress Core

Changeset 39010


Ignore:
Timestamp:
10/30/2016 04:22:18 AM (5 years ago)
Author:
westonruter
Message:

Customize: Reveal controls pane when clicking on edit shortcuts in mobile preview.

Re-use paneVisible state to also manage whether the mobile preview-only class is applied to the overlay.

Props seancjones.
See #36678, #36678, #27403.
Fixes #38080.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/js/customize-controls.js

    r38991 r39010  
    52735273
    52745274        api.state( 'paneVisible' ).bind( function( paneVisible ) {
     5275            overlay.toggleClass( 'preview-only', ! paneVisible );
    52755276            overlay.toggleClass( 'expanded', paneVisible );
    52765277            overlay.toggleClass( 'collapsed', ! paneVisible );
     
    53325333
    53335334        $( '.customize-controls-preview-toggle' ).on( 'click', function() {
    5334             overlay.toggleClass( 'preview-only' );
     5335            api.state( 'paneVisible' ).set( ! api.state( 'paneVisible' ).get() );
    53355336        });
    53365337
Note: See TracChangeset for help on using the changeset viewer.