Ticket #31791: 31791.patch
| File 31791.patch, 4.9 KB (added by , 11 years ago) |
|---|
-
src/wp-admin/css/customize-controls.css
906 906 font-size: 32px; 907 907 } 908 908 909 .wp-customizer .theme-browser .theme.active .theme-name {910 padding-right: 15px;911 }912 913 909 .wp-customizer #themes-filter { 914 910 font-size: 16px; 915 911 font-weight: 300; … … 917 913 width: 100%; 918 914 } 919 915 916 917 .wp-customizer .theme-browser .theme.active:hover, 918 .wp-customizer .theme-browser .theme.active:focus { 919 cursor: default; 920 } 921 922 .wp-customizer .theme-browser .theme.active .more-details { 923 display: none; 924 } 925 926 .wp-customizer .theme-browser .theme.active .theme-name { 927 padding-right: 15px; 928 } 929 930 .wp-customizer .theme-browser.rendered .theme.active:hover .theme-screenshot img, 931 .wp-customizer .theme-browser.rendered .theme.active:focus .theme-screenshot img { 932 opacity: 1; 933 } 934 920 935 /* Panel-like behavior */ 921 936 #accordion-section-themes .accordion-section-title:after { 922 937 content: "\f148"; -
src/wp-admin/includes/theme.php
529 529 </div> 530 530 </div> 531 531 532 < div class="theme-actions">533 < # if ( ! data.active ) { #>532 <# if ( ! data.active ) { #> 533 <div class="theme-actions"> 534 534 <div class="inactive-theme"> 535 535 <a href="<?php echo add_query_arg( 'theme', '{{ data.id }}' ); ?>" target="_top" class="button button-primary"><?php _e( 'Live Preview' ); ?></a> 536 536 </div> 537 < # } #>538 < /div>537 </div> 538 <# } #> 539 539 </div> 540 540 </script> 541 541 <?php -
src/wp-admin/js/customize-controls.js
648 648 section.closeDetails(); 649 649 }); 650 650 651 section.container.on( 'click keydown', '.theme-actions .button', function( event ) {652 if ( api.utils.isKeydownButNotEnterEvent( event ) ) {653 return;654 }655 656 $( '.wp-full-overlay' ).addClass( 'customize-loading' );657 });658 659 651 section.container.on( 'input', '#themes-filter', function( event ) { 660 652 var count, 661 653 term = event.currentTarget.value.toLowerCase().trim().replace( '-', ' ' ), … … 1885 1877 return; 1886 1878 } 1887 1879 1888 api.section( control.section() ).showDetails( control.params.theme ); 1880 if ( $( this ).hasClass( 'active' ) ) { 1881 return; 1882 } 1883 1884 var previewUrl = $( this ).data( 'previewUrl' ); 1885 1886 $( '.wp-full-overlay' ).addClass( 'customize-loading' ); 1887 1888 window.parent.location = previewUrl; 1889 1889 }); 1890 1890 1891 control.container.on( 'click keydown', '.theme-actions . button', function( event ) {1891 control.container.on( 'click keydown', '.theme-actions .theme-details', function( event ) { 1892 1892 if ( api.utils.isKeydownButNotEnterEvent( event ) ) { 1893 1893 return; 1894 1894 } 1895 1895 1896 $( '.wp-full-overlay' ).addClass( 'customize-loading' ); 1896 event.preventDefault(); // Keep this AFTER the key filter above 1897 1898 api.section( control.section() ).showDetails( control.params.theme ); 1897 1899 }); 1898 1900 }, 1899 1901 -
src/wp-includes/class-wp-customize-control.php
1200 1200 * @since 4.2.0 1201 1201 */ 1202 1202 public function content_template() { 1203 ?> 1204 <div class="theme<# if ( data.theme.active ) { #> active<# } #>" tabindex="0" aria-describedby="{{ data.theme.id }}-action {{ data.theme.id }}-name"> 1203 $preview_url = site_url( add_query_arg( 'theme', '{{ data.theme.id }}' ) ); 1204 ?> 1205 <div class="theme<# if ( data.theme.active ) { #> active<# } #>" data-preview-url="<?php echo esc_attr( $preview_url ); ?>" aria-describedby="{{ data.theme.id }}-action {{ data.theme.id }}-name"> 1205 1206 <# if ( data.theme.screenshot[0] ) { #> 1206 1207 <div class="theme-screenshot"> 1207 1208 <img src="{{ data.theme.screenshot[0] }}" alt="" /> … … 1209 1210 <# } else { #> 1210 1211 <div class="theme-screenshot blank"></div> 1211 1212 <# } #> 1212 <span class="more-details" id="{{ data.theme.id }}-action"><?php _e( ' Theme Details' ); ?></span>1213 <span class="more-details" id="{{ data.theme.id }}-action"><?php _e( 'Live Preview' ); ?></span> 1213 1214 <div class="theme-author"><?php printf( __( 'By %s' ), '{{ data.theme.author }}' ); ?></div> 1214 1215 1215 1216 <# if ( data.theme.active ) { #> … … 1225 1226 1226 1227 <# if ( ! data.theme.active ) { #> 1227 1228 <div class="theme-actions"> 1228 < a class="button" href="<?php echo add_query_arg( 'theme', '{{ data.theme.id }}' ); ?>" target="_top"><?php _e( 'Live Preview' ); ?></a>1229 <button type="button" class="button theme-details"><?php _e( 'Theme Details' ); ?></button> 1229 1230 </div> 1230 1231 <# } #> 1231 1232 </div>
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)