Changeset 52285
- Timestamp:
- 11/30/2021 05:16:13 PM (3 years ago)
- Location:
- trunk/src
- Files:
-
- 22 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/js/_enqueues/admin/common.js
r51977 r52285 1728 1728 $document.on( 'wp-window-resized.wp-responsive', this.trigger.bind( this ) ); 1729 1729 1730 // This needs to run later as UI Sortable may be initialized later on $(document).ready().1730 // This needs to run later as UI Sortable may be initialized when the document is ready. 1731 1731 $window.on( 'load.wp-responsive', this.maybeDisableSortables ); 1732 1732 $document.on( 'postbox-toggled', this.maybeDisableSortables ); -
trunk/src/wp-admin/admin-header.php
r52030 r52285 98 98 ?> 99 99 <script type="text/javascript"> 100 addLoadEvent = function(func){if(typeof jQuery!=='undefined')jQuery( document).ready(func);else if(typeof wpOnload!=='function'){wpOnload=func;}else{var oldonload=wpOnload;wpOnload=function(){oldonload();func();}}};100 addLoadEvent = function(func){if(typeof jQuery!=='undefined')jQuery(function(){func();});else if(typeof wpOnload!=='function'){wpOnload=func;}else{var oldonload=wpOnload;wpOnload=function(){oldonload();func();}}}; 101 101 var ajaxurl = '<?php echo esc_js( admin_url( 'admin-ajax.php', 'relative' ) ); ?>', 102 102 pagenow = '<?php echo esc_js( $current_screen->id ); ?>', -
trunk/src/wp-admin/export.php
r51475 r52285 28 28 ?> 29 29 <script type="text/javascript"> 30 jQuery( document).ready(function($){30 jQuery( function($) { 31 31 var form = $('#export-filters'), 32 32 filters = form.find('.export-filters'); … … 40 40 } 41 41 }); 42 } );42 } ); 43 43 </script> 44 44 <?php -
trunk/src/wp-admin/includes/class-custom-image-header.php
r50707 r52285 394 394 } 395 395 396 $( document).ready(function() {396 $( function() { 397 397 var text_color = $('#text-color'); 398 398 header_text_fields = $('.displaying-header-text'); … … 409 409 toggle_text(); 410 410 <?php endif; ?> 411 } );411 } ); 412 412 })(jQuery); 413 413 </script> … … 431 431 } 432 432 433 jQuery( document).ready(function() {433 jQuery( function() { 434 434 var xinit = <?php echo absint( get_theme_support( 'custom-header', 'width' ) ); ?>; 435 435 var yinit = <?php echo absint( get_theme_support( 'custom-header', 'height' ) ); ?>; … … 486 486 } 487 487 }); 488 } );488 } ); 489 489 </script> 490 490 <?php -
trunk/src/wp-admin/includes/class-wp-internal-pointers.php
r47122 r52285 141 141 $(window).bind( 'load.wp-pointers', setup ); 142 142 else 143 $(document).ready( setup ); 143 $( function() { 144 setup(); 145 } ); 144 146 145 147 })( jQuery ); -
trunk/src/wp-admin/includes/deprecated.php
r52035 r52285 1508 1508 ?> 1509 1509 <script type="text/javascript"> 1510 jQuery( document).ready(function() {1510 jQuery( function() { 1511 1511 jQuery('.permalink-structure input:radio').change(function() { 1512 1512 if ( 'custom' == this.value ) … … 1517 1517 jQuery( '#custom_selection' ).prop( 'checked', true ); 1518 1518 }); 1519 } );1519 } ); 1520 1520 </script> 1521 1521 <?php -
trunk/src/wp-admin/includes/media.php
r52254 r52285 534 534 ?> 535 535 <script type="text/javascript"> 536 addLoadEvent = function(func){if(typeof jQuery!=='undefined')jQuery( document).ready(func);else if(typeof wpOnload!=='function'){wpOnload=func;}else{var oldonload=wpOnload;wpOnload=function(){oldonload();func();}}};536 addLoadEvent = function(func){if(typeof jQuery!=='undefined')jQuery(function(){func();});else if(typeof wpOnload!=='function'){wpOnload=func;}else{var oldonload=wpOnload;wpOnload=function(){oldonload();func();}}}; 537 537 var ajaxurl = '<?php echo esc_js( admin_url( 'admin-ajax.php', 'relative' ) ); ?>', pagenow = 'media-upload-popup', adminpage = 'media-upload-popup', 538 538 isRtl = <?php echo (int) is_rtl(); ?>; … … 2502 2502 }; 2503 2503 2504 jQuery( document).ready(function($) {2504 jQuery( function($) { 2505 2505 $('.media-types input').click( function() { 2506 2506 $('table.describe').toggleClass('not-image', $('#not-image').prop('checked') ); 2507 2507 }); 2508 } );2508 } ); 2509 2509 </script> 2510 2510 -
trunk/src/wp-admin/includes/meta-boxes.php
r52204 r52285 866 866 if ( ! in_array( 'commentsdiv', $hidden, true ) ) { 867 867 ?> 868 <script type="text/javascript">jQuery( document).ready(function(){commentsBox.get(<?php echo $total; ?>, 10);});</script>868 <script type="text/javascript">jQuery(function(){commentsBox.get(<?php echo $total; ?>, 10);});</script> 869 869 <?php 870 870 } -
trunk/src/wp-admin/includes/ms.php
r52086 r52285 1011 1011 ?> 1012 1012 <script type="text/javascript"> 1013 jQuery( document).ready(function($) {1013 jQuery( function($) { 1014 1014 var languageSelect = $( '#WPLANG' ); 1015 1015 $( 'form' ).on( 'submit', function() { … … 1020 1020 } 1021 1021 }); 1022 } );1022 } ); 1023 1023 </script> 1024 1024 <?php -
trunk/src/wp-admin/includes/options.php
r50001 r52285 35 35 ?> 36 36 <script type="text/javascript"> 37 jQuery( document).ready(function($){37 jQuery( function($) { 38 38 var $siteName = $( '#wp-admin-bar-site-name' ).children( 'a' ).first(), 39 39 homeURL = ( <?php echo wp_json_encode( get_home_url() ); ?> || '' ).replace( /^(https?:\/\/)?(www\.)?/, '' ); … … 97 97 } 98 98 }); 99 } );99 } ); 100 100 </script> 101 101 <?php … … 110 110 ?> 111 111 <script type="text/javascript"> 112 jQuery( document).ready(function($){112 jQuery( function($) { 113 113 var section = $('#front-static-pages'), 114 114 staticPage = section.find('input:radio[value="page"]'), … … 119 119 check_disabled(); 120 120 section.find( 'input:radio' ).on( 'change', check_disabled ); 121 } );121 } ); 122 122 </script> 123 123 <?php -
trunk/src/wp-admin/includes/template.php
r52204 r52285 2032 2032 ?> 2033 2033 <script type="text/javascript"> 2034 addLoadEvent = function(func){if(typeof jQuery!=='undefined')jQuery( document).ready(func);else if(typeof wpOnload!=='function'){wpOnload=func;}else{var oldonload=wpOnload;wpOnload=function(){oldonload();func();}}};2034 addLoadEvent = function(func){if(typeof jQuery!=='undefined')jQuery(function(){func();});else if(typeof wpOnload!=='function'){wpOnload=func;}else{var oldonload=wpOnload;wpOnload=function(){oldonload();func();}}}; 2035 2035 function tb_close(){var win=window.dialogArguments||opener||parent||top;win.tb_remove();} 2036 2036 var ajaxurl = '<?php echo esc_js( admin_url( 'admin-ajax.php', 'relative' ) ); ?>', -
trunk/src/wp-admin/includes/user.php
r52204 r52285 537 537 ?> 538 538 <script> 539 jQuery( document).ready(function($) {539 jQuery( function($) { 540 540 var submit = $('#submit').prop('disabled', true); 541 541 $('input[name="delete_option"]').one('change', function() { … … 545 545 $('#delete_option1').prop('checked', true).trigger('change'); 546 546 }); 547 } );547 } ); 548 548 </script> 549 549 <?php -
trunk/src/wp-content/themes/twentyeleven/inc/theme-options.js
r18229 r52285 8 8 }; 9 9 10 $( document).ready(function() {10 $( function() { 11 11 $('#default-color').wrapInner('<a href="#" />'); 12 12 … … 49 49 currentDefault.text( newDefault ); 50 50 }); 51 } );51 } ); 52 52 })(jQuery); -
trunk/src/wp-content/themes/twentyeleven/js/showcase.js
r50001 r52285 1 1 (function($) { 2 $( document).ready(function() {2 $( function() { 3 3 $('.feature-slider a').on( 'click', function(e) { 4 4 $('.featured-posts section.featured-post').css({ … … 14 14 e.preventDefault(); 15 15 }); 16 } );16 } ); 17 17 })(jQuery); -
trunk/src/wp-content/themes/twentyfifteen/js/functions.js
r50001 r52285 112 112 } 113 113 114 $( document ).ready(function() {114 $( function() { 115 115 $body = $( document.body ); 116 116 $window = $( window ); -
trunk/src/wp-content/themes/twentyfourteen/js/featured-content-admin.js
r26707 r52285 5 5 /* global ajaxurl:true */ 6 6 7 jQuery( document ).ready( function( $) {7 jQuery( function($) { 8 8 $( '#customize-control-featured-content-tag-name input' ).suggest( ajaxurl + '?action=ajax-tag-search&tax=post_tag', { delay: 500, minchars: 2 } ); 9 } );9 } ); -
trunk/src/wp-content/themes/twentyseventeen/assets/js/global.js
r51257 r52285 179 179 180 180 // Fire on document ready. 181 $( document ).ready(function() {181 $( function() { 182 182 183 183 // If navigation menu is present on page, setNavProps and adjustScrollClass. … … 219 219 document.documentElement.className += ' background-fixed'; 220 220 } 221 } );221 } ); 222 222 223 223 // If navigation menu is present on page, adjust it on scroll and screen resize. -
trunk/src/wp-content/themes/twentysixteen/js/functions.js
r50001 r52285 192 192 } 193 193 194 $( document ).ready(function() {194 $( function() { 195 195 body = $( document.body ); 196 196 -
trunk/src/wp-content/themes/twentytwenty/assets/js/customize-preview.js
r51322 r52285 187 187 } 188 188 // Generate styles on load. Handles page-changes on the preview pane. 189 $( document ).ready(function() {189 $( function() { 190 190 twentyTwentyGenerateColorA11yPreviewStyles( 'content' ); 191 191 twentyTwentyGenerateColorA11yPreviewStyles( 'header-footer' ); -
trunk/src/wp-content/themes/twentytwenty/assets/js/customize.js
r46585 r52285 2 2 3 3 ( function( $, api ) { 4 $( document ).ready(function() {4 $( function() { 5 5 // Make it possible to reset the color based on a radio input's value. 6 6 // `active` can be either `custom` or `default`. -
trunk/src/wp-includes/class-wp-embed.php
r51177 r52285 89 89 ?> 90 90 <script type="text/javascript"> 91 jQuery( document).ready(function($){91 jQuery( function($) { 92 92 $.get("<?php echo esc_url( admin_url( 'admin-ajax.php', 'relative' ) ) . '?action=oembed-cache&post=' . $post->ID; ?>"); 93 } );93 } ); 94 94 </script> 95 95 <?php -
trunk/src/wp-includes/script-loader.php
r52262 r52285 1817 1817 ); 1818 1818 1819 wp_add_inline_script( 'jquery-ui-datepicker', "jQuery( document).ready(function(jQuery){jQuery.datepicker.setDefaults({$datepicker_defaults});});" );1819 wp_add_inline_script( 'jquery-ui-datepicker', "jQuery(function(jQuery){jQuery.datepicker.setDefaults({$datepicker_defaults});});" ); 1820 1820 } 1821 1821
Note: See TracChangeset
for help on using the changeset viewer.