Ticket #42365: 42365.4.diff
File 42365.4.diff, 3.6 KB (added by , 8 years ago) |
---|
-
src/wp-admin/css/customize-controls.css
2030 2030 display: none; 2031 2031 } 2032 2032 2033 .themes-section-installed_themes .theme .notice-success {2033 .themes-section-installed_themes .theme .notice-success:not(.updated-message) { 2034 2034 display: none; /* Hide "installed" notice on installed themes tab. */ 2035 2035 } 2036 2036 -
src/wp-admin/js/customize-controls.js
3347 3347 api.control.each( function( control ) { 3348 3348 if ( 'theme' === control.params.type && control.params.theme.id === response.slug ) { 3349 3349 control.params.theme.hasUpdate = false; 3350 control.rerenderAsInstalled( true ); 3350 control.params.theme.version = response.newVersion; 3351 setTimeout( function() { control.rerenderAsInstalled( true ); }, 2000 ); 3351 3352 } 3352 3353 }); 3353 3354 } ); -
src/wp-admin/js/updates.js
937 937 } else if ( 'customize' === pagenow ) { 938 938 939 939 // Update the theme details UI. 940 $notice = $( ' #update-theme' ).closest( '.notice' ).removeClass( 'notice-large' );940 $notice = $( '[data-slug="' + args.slug + '"].notice' ).removeClass( 'notice-large' ); 941 941 942 942 $notice.find( 'h3' ).remove(); 943 943 … … 988 988 $notice, newText; 989 989 990 990 if ( 'customize' === pagenow ) { 991 $theme = wp.customize.control( 'installed_theme_' + response.slug ).container; 992 } 991 $theme = $( '.updating-message' ).siblings( '.theme-name' ); 993 992 994 if ( 'themes-network' === pagenow ) { 993 if ( $theme.length ) { 994 995 // Update the version number in the row. 996 newText = $theme.html().replace( response.oldVersion, response.newVersion ); 997 $theme.html( newText ); 998 } 999 1000 $notice = $( '.theme-info .notice' ).add( wp.customize.control( 'installed_theme_' + response.slug ).container.find( '.theme' ).find( '.update-message' ) ); 1001 } else if ( 'themes-network' === pagenow ) { 995 1002 $notice = $theme.find( '.update-message' ); 996 1003 997 1004 // Update the version number in the row. … … 1016 1023 $document.trigger( 'wp-theme-update-success', response ); 1017 1024 1018 1025 // Show updated message after modal re-rendered. 1019 if ( isModalOpen ) {1026 if ( isModalOpen && 'customize' !== pagenow ) { 1020 1027 $( '.theme-info .theme-author' ).after( wp.updates.adminNotice( updatedMessage ) ); 1021 1028 } 1022 1029 }; … … 1046 1053 } 1047 1054 1048 1055 if ( 'customize' === pagenow ) { 1049 $theme = wp.customize.control( 'installed_theme_' + response.slug ).container ;1056 $theme = wp.customize.control( 'installed_theme_' + response.slug ).container.find( '.theme' ); 1050 1057 } 1051 1058 1052 1059 if ( 'themes-network' === pagenow ) { -
src/wp-includes/customize/class-wp-customize-themes-section.php
69 69 * @since 4.9.0 70 70 */ 71 71 protected function render_template() { 72 wp_localize_script( 'updates', '_wpUpdatesItemCounts', array( 73 'totals' => wp_get_update_data(), 74 ) ); 72 75 ?> 73 76 <li id="accordion-section-{{ data.id }}" class="theme-section"> 74 77 <button type="button" class="customize-themes-section-title themes-section-{{ data.id }}">{{ data.title }}</button>