Changeset 36797
- Timestamp:
- 03/01/2016 10:17:20 PM (9 years ago)
- Location:
- trunk/src/wp-content/themes
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-content/themes/twentyeleven/inc/theme-options.php
r32314 r36797 511 511 $wp_customize->get_setting( 'header_textcolor' )->transport = 'postMessage'; 512 512 513 if ( isset( $wp_customize->selective_refresh ) ) { 514 $wp_customize->selective_refresh->add_partial( 'blogname', array( 515 'selector' => '#site-title a', 516 'container_inclusive' => false, 517 'render_callback' => 'twentyeleven_customize_partial_blogname', 518 ) ); 519 $wp_customize->selective_refresh->add_partial( 'blogdescription', array( 520 'selector' => '#site-description', 521 'container_inclusive' => false, 522 'render_callback' => 'twentyeleven_customize_partial_blogdescription', 523 ) ); 524 } 525 513 526 $options = twentyeleven_get_theme_options(); 514 527 $defaults = twentyeleven_get_default_theme_options(); … … 576 589 577 590 /** 591 * Render the site title for the selective refresh partial. 592 * 593 * @since Twenty Eleven 2.4 594 * @see twentyeleven_customize_register() 595 * 596 * @return void 597 */ 598 function twentyeleven_customize_partial_blogname() { 599 bloginfo( 'name' ); 600 } 601 602 /** 603 * Render the site tagline for the selective refresh partial. 604 * 605 * @since Twenty Eleven 2.4 606 * @see twentyeleven_customize_register() 607 * 608 * @return void 609 */ 610 function twentyeleven_customize_partial_blogdescription() { 611 bloginfo( 'description' ); 612 } 613 614 /** 578 615 * Bind JS handlers to make Customizer preview reload changes asynchronously. 579 616 * -
trunk/src/wp-content/themes/twentyfifteen/inc/customizer.php
r34791 r36797 20 20 $wp_customize->get_setting( 'blogname' )->transport = 'postMessage'; 21 21 $wp_customize->get_setting( 'blogdescription' )->transport = 'postMessage'; 22 23 if ( isset( $wp_customize->selective_refresh ) ) { 24 $wp_customize->selective_refresh->add_partial( 'blogname', array( 25 'selector' => '.site-title a', 26 'container_inclusive' => false, 27 'render_callback' => 'twentyfifteen_customize_partial_blogname', 28 ) ); 29 $wp_customize->selective_refresh->add_partial( 'blogdescription', array( 30 'selector' => '.site-description', 31 'container_inclusive' => false, 32 'render_callback' => 'twentyfifteen_customize_partial_blogdescription', 33 ) ); 34 } 22 35 23 36 // Add color scheme setting and control. … … 69 82 } 70 83 add_action( 'customize_register', 'twentyfifteen_customize_register', 11 ); 84 85 /** 86 * Render the site title for the selective refresh partial. 87 * 88 * @since Twenty Fifteen 1.5 89 * @see twentyfifteen_customize_register() 90 * 91 * @return void 92 */ 93 function twentyfifteen_customize_partial_blogname() { 94 bloginfo( 'name' ); 95 } 96 97 /** 98 * Render the site tagline for the selective refresh partial. 99 * 100 * @since Twenty Fifteen 1.5 101 * @see twentyfifteen_customize_register() 102 * 103 * @return void 104 */ 105 function twentyfifteen_customize_partial_blogdescription() { 106 bloginfo( 'description' ); 107 } 71 108 72 109 /** -
trunk/src/wp-content/themes/twentyfourteen/inc/customizer.php
r32116 r36797 20 20 $wp_customize->get_setting( 'blogdescription' )->transport = 'postMessage'; 21 21 $wp_customize->get_setting( 'header_textcolor' )->transport = 'postMessage'; 22 23 if ( isset( $wp_customize->selective_refresh ) ) { 24 $wp_customize->selective_refresh->add_partial( 'blogname', array( 25 'selector' => '.site-title a', 26 'container_inclusive' => false, 27 'render_callback' => 'twentyfourteen_customize_partial_blogname', 28 ) ); 29 $wp_customize->selective_refresh->add_partial( 'blogdescription', array( 30 'selector' => '.site-description', 31 'container_inclusive' => false, 32 'render_callback' => 'twentyfourteen_customize_partial_blogdescription', 33 ) ); 34 } 22 35 23 36 // Rename the label to "Site Title Color" because this only affects the site title in this theme. … … 64 77 } 65 78 add_action( 'customize_register', 'twentyfourteen_customize_register' ); 79 80 /** 81 * Render the site title for the selective refresh partial. 82 * 83 * @since Twenty Fourteen 1.7 84 * @see twentyfourteen_customize_register() 85 * 86 * @return void 87 */ 88 function twentyfourteen_customize_partial_blogname() { 89 bloginfo( 'name' ); 90 } 91 92 /** 93 * Render the site tagline for the selective refresh partial. 94 * 95 * @since Twenty Fourteen 1.7 96 * @see twentyfourteen_customize_register() 97 * 98 * @return void 99 */ 100 function twentyfourteen_customize_partial_blogdescription() { 101 bloginfo( 'description' ); 102 } 66 103 67 104 /** -
trunk/src/wp-content/themes/twentythirteen/functions.php
r35885 r36797 536 536 $wp_customize->get_setting( 'blogdescription' )->transport = 'postMessage'; 537 537 $wp_customize->get_setting( 'header_textcolor' )->transport = 'postMessage'; 538 539 if ( isset( $wp_customize->selective_refresh ) ) { 540 $wp_customize->selective_refresh->add_partial( 'blogname', array( 541 'selector' => '.site-title', 542 'container_inclusive' => false, 543 'render_callback' => 'twentythirteen_customize_partial_blogname', 544 ) ); 545 $wp_customize->selective_refresh->add_partial( 'blogdescription', array( 546 'selector' => '.site-description', 547 'container_inclusive' => false, 548 'render_callback' => 'twentythirteen_customize_partial_blogdescription', 549 ) ); 550 } 538 551 } 539 552 add_action( 'customize_register', 'twentythirteen_customize_register' ); 553 554 /** 555 * Render the site title for the selective refresh partial. 556 * 557 * @since Twenty Thirteen 1.9 558 * @see twentythirteen_customize_register() 559 * 560 * @return void 561 */ 562 function twentythirteen_customize_partial_blogname() { 563 bloginfo( 'name' ); 564 } 565 566 /** 567 * Render the site tagline for the selective refresh partial. 568 * 569 * @since Twenty Thirteen 1.9 570 * @see twentythirteen_customize_register() 571 * 572 * @return void 573 */ 574 function twentythirteen_customize_partial_blogdescription() { 575 bloginfo( 'description' ); 576 } 540 577 541 578 /** -
trunk/src/wp-content/themes/twentytwelve/functions.php
r36709 r36797 481 481 $wp_customize->get_setting( 'blogdescription' )->transport = 'postMessage'; 482 482 $wp_customize->get_setting( 'header_textcolor' )->transport = 'postMessage'; 483 484 if ( isset( $wp_customize->selective_refresh ) ) { 485 $wp_customize->selective_refresh->add_partial( 'blogname', array( 486 'selector' => '.site-title > a', 487 'container_inclusive' => false, 488 'render_callback' => 'twentytwelve_customize_partial_blogname', 489 ) ); 490 $wp_customize->selective_refresh->add_partial( 'blogdescription', array( 491 'selector' => '.site-description', 492 'container_inclusive' => false, 493 'render_callback' => 'twentytwelve_customize_partial_blogdescription', 494 ) ); 495 } 483 496 } 484 497 add_action( 'customize_register', 'twentytwelve_customize_register' ); 498 499 /** 500 * Render the site title for the selective refresh partial. 501 * 502 * @since Twenty Twelve 2.0 503 * @see twentytwelve_customize_register() 504 * 505 * @return void 506 */ 507 function twentytwelve_customize_partial_blogname() { 508 bloginfo( 'name' ); 509 } 510 511 /** 512 * Render the site tagline for the selective refresh partial. 513 * 514 * @since Twenty Twelve 2.0 515 * @see twentytwelve_customize_register() 516 * 517 * @return void 518 */ 519 function twentytwelve_customize_partial_blogdescription() { 520 bloginfo( 'description' ); 521 } 485 522 486 523 /**
Note: See TracChangeset
for help on using the changeset viewer.