CoreFiles by mySites.guru
customizer.js38 lines, 950 bytes, from wordpress-4.4.21.zip
Raw History Compare with 4.4.20
md5
c2076270975f96875b8472e3242fbacd
sha1
16683f21cd76cb99a4b67e8bc0fc74821d857983
sha256
41fedf472637b10f48dbffba0564fec6bf5e237a65424545dd528a39569f6b20
/**
 * Twenty Fourteen Customizer enhancements for a better user experience.
 *
 * Contains handlers to make Customizer preview reload changes asynchronously.
 */
( function( $ ) {
	// Site title and description.
	wp.customize( 'blogname', function( value ) {
		value.bind( function( to ) {
			$( '.site-title a' ).text( to );
		} );
	} );
	wp.customize( 'blogdescription', function( value ) {
		value.bind( function( to ) {
			$( '.site-description' ).text( to );
		} );
	} );
	// Header text color.
	wp.customize( 'header_textcolor', function( value ) {
		value.bind( function( to ) {
			if ( 'blank' === to ) {
				$( '.site-title, .site-description' ).css( {
					'clip': 'rect(1px, 1px, 1px, 1px)',
					'position': 'absolute'
				} );
			} else {
				$( '.site-title,  .site-description' ).css( {
					'clip': 'auto',
					'position': 'static'
				} );

				$( '.site-title a' ).css( {
					'color': to
				} );
			}
		} );
	} );
} )( jQuery );

The same content is in 263 releases, WordPress 4.1-beta1 to 4.6.30. See them all, or every version of this file.