Customizer panels: use a single back button for all panels.

This also ensures the back button is visible on iOS devices.

props celloexpressions.
fixes #29135.


git-svn-id: https://develop.svn.wordpress.org/trunk@29610 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Helen Hou-Sandi
2014-08-25 23:04:43 +00:00
parent f1fe507032
commit bcba1996fe
4 changed files with 6 additions and 6 deletions

View File

@@ -47,14 +47,14 @@
});
// Go back to the top-level Customizer accordion.
$( '.accordion-container' ).on( 'click keydown', '.control-panel-back', function( e ) {
$( '#customize-header-actions' ).on( 'click keydown', '.control-panel-back', function( e ) {
if ( e.type === 'keydown' && 13 !== e.which ) { // "return" key
return;
}
e.preventDefault(); // Keep this AFTER the key filter above
panelSwitch( $( this ) );
panelSwitch( $( '.current-panel' ) );
});
});
@@ -108,7 +108,7 @@
container = section.closest( '.accordion-container' ),
siblings = container.find( '.open' ),
topPanel = overlay.find( '#customize-theme-controls > ul > .accordion-section > .accordion-section-title' ).add( '#customize-info > .accordion-section-title' ),
backBtn = section.find( '.control-panel-back' ),
backBtn = overlay.find( '.control-panel-back' ),
panelTitle = section.find( '.accordion-section-title' ).first(),
content = section.find( '.control-panel-content' );