Theme Customizer: Remove !important declarations from hide-if-customize and hide-if-no-customize classes. Use a default no-customize-support class on the body so we can use an element's original display property when visible. fixes #20565, see #19910.

git-svn-id: http://core.svn.wordpress.org/trunk@20759 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
koopersmith 2012-05-09 21:47:15 +00:00
parent 08e4e98c16
commit e7f756c669
2 changed files with 8 additions and 11 deletions

View File

@ -90,6 +90,8 @@ $admin_body_class .= ' locale-' . sanitize_html_class( strtolower( str_replace(
if ( wp_is_mobile() ) if ( wp_is_mobile() )
$admin_body_class .= ' mobile'; $admin_body_class .= ' mobile';
$admin_body_class .= ' no-customize-support';
?> ?>
</head> </head>
<body class="wp-admin no-js <?php echo apply_filters( 'admin_body_class', '' ) . " $admin_body_class"; ?>"> <body class="wp-admin no-js <?php echo apply_filters( 'admin_body_class', '' ) . " $admin_body_class"; ?>">
@ -100,7 +102,7 @@ if ( wp_is_mobile() )
// This prevents a flash of unstyled content. // This prevents a flash of unstyled content.
if ( wp_script_is( 'customize-loader', 'queue' ) ) : ?> if ( wp_script_is( 'customize-loader', 'queue' ) ) : ?>
if ( window.postMessage ) if ( window.postMessage )
document.body.className += ' customize-support'; document.body.className += document.body.className.replace('no-customize-support','customize-support');
<?php endif; ?> <?php endif; ?>
</script> </script>

View File

@ -4411,7 +4411,7 @@ h3.available-themes {
width: 300px; width: 300px;
} }
.available-theme a.screenshot { .available-theme .screenshot {
width: 300px; width: 300px;
height: 225px; height: 225px;
display: block; display: block;
@ -4556,12 +4556,12 @@ h3.available-themes {
/* Allow for three-up on 1024px wide screens, e.g. tablets */ /* Allow for three-up on 1024px wide screens, e.g. tablets */
@media only screen and (max-width: 1200px) { @media only screen and (max-width: 1200px) {
.available-theme, .available-theme,
.available-theme a.screenshot, .available-theme .screenshot,
#current-theme img { #current-theme img {
width: 240px; width: 240px;
} }
.available-theme a.screenshot { .available-theme .screenshot {
height: 180px; height: 180px;
} }
@ -5428,14 +5428,9 @@ body.full-overlay-active {
24.0 - Customize Loader 24.0 - Customize Loader
------------------------------------------------------------------------------*/ ------------------------------------------------------------------------------*/
.hide-if-no-customize, .no-customize-support .hide-if-no-customize,
.customize-support .hide-if-customize { .customize-support .hide-if-customize {
display: none !important; display: none;
}
.hide-if-customize,
.customize-support .hide-if-no-customize {
display: block !important;
} }
#customize-container { #customize-container {