Customizer: Hide empty space in footer on small screens since it is only populated on larger screens.

Props obenland.
Fixes #33138.

Built from https://develop.svn.wordpress.org/trunk@33454


git-svn-id: http://core.svn.wordpress.org/trunk@33421 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Weston Ruter 2015-07-28 03:43:24 +00:00
parent 3e36b24b24
commit a48604e32c
3 changed files with 13 additions and 4 deletions

View File

@ -595,12 +595,21 @@
} else {
container.scrollTop( 0 );
expand = function () {
var matchMedia, offset;
matchMedia = window.matchMedia || window.msMatchMedia;
offset = 90; // 45px for customize header actions + 45px for footer actions.
// No footer on small screens.
if ( matchMedia && matchMedia( '(max-width: 640px)' ).matches ) {
offset = 45;
}
section.container.addClass( 'open' );
overlay.addClass( 'section-open' );
position = content.offset().top;
scroll = container.scrollTop();
content.css( 'margin-top', ( 45 - position - scroll ) );
content.css( 'height', ( window.innerHeight - 90 ) );
content.css( 'height', ( window.innerHeight - offset ) );
sectionTitle.attr( 'tabindex', '-1' );
backBtn.attr( 'tabindex', '0' );
backBtn.focus();

File diff suppressed because one or more lines are too long

View File

@ -4,7 +4,7 @@
*
* @global string $wp_version
*/
$wp_version = '4.3-beta4-33453';
$wp_version = '4.3-beta4-33454';
/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.