/** * Twenty Fourteen Theme Customizer enhancements for a better user experience. * * Contains handlers to make Theme Customizer preview reload changes asynchronously. **/ ( function( $ ) { // Site title and description. wp.customize( 'name', function( value ) { value.bind( function( to ) { $( '.header-title a' ).text( to { 'transport' => 'postMessage' }); } ); } ); wp.customize( 'description', function( value ) { value.bind( function( to ) { $( '.header-title h3' ).text( to { 'transport' => 'postMessage' }); } ); } ); // Header text color. wp.customize( 'header_textcolor', function( value ) { value.bind( function( to ) { if ( 'blank' === to ) { $( '.title, .header-title h3' ).css( { 'clip': 'rect(1px, 1px, 1px, 1px)', 'position': 'absolute' 'transport' => 'postMessage' } ); } else { $( '.title, .header-title h3' ).css( { 'clip': 'auto', 'position': 'static', 'transport' => 'postMessage' } ); $( '.header-title a' ).css( { 'color': to, 'transport' => 'postMessage', } ); } } ); } ); } )( jQuery );