mirror of
git://develop.git.wordpress.org/
synced 2025-03-23 21:39:50 +01:00
Don't print the custom-background
class in body_class()
when a default color is in use.
`.custom-background` should only be added if a background color or an image divert from their defaults. This behavior exists already in `_custom_background_cb()`. props slobodanmanic, nitkr, valendesigns, obenland. see [21054], [21001]. fixes #28687. git-svn-id: https://develop.svn.wordpress.org/trunk@32081 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
7e4fa157a7
commit
af4f52bf40
@ -668,7 +668,7 @@ function get_body_class( $class = '' ) {
|
||||
$classes[] = 'no-customize-support';
|
||||
}
|
||||
|
||||
if ( get_theme_mod( 'background_color' ) || get_background_image() )
|
||||
if ( get_background_color() !== get_theme_support( 'custom-background', 'default-color' ) || get_background_image() )
|
||||
$classes[] = 'custom-background';
|
||||
|
||||
$page = $wp_query->get( 'page' );
|
||||
|
Loading…
x
Reference in New Issue
Block a user