mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-04-03 20:24:26 +00:00
Shiny Updates: Add ajax-y updates to the plugin list page, and ajax-y updates and installs to the plugin card page.
This also includes JS architecture that can be expanded to support theme, core and language pack updates. Props pento, ericlewis, lgladdy, adamsilverstein, DrewAPicture See #29820 git-svn-id: https://develop.svn.wordpress.org/trunk@31333 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -501,6 +501,18 @@ function wp_default_scripts( &$scripts ) {
|
||||
) );
|
||||
|
||||
$scripts->add( 'updates', "/wp-admin/js/updates$suffix.js", array( 'jquery' ) );
|
||||
did_action( 'init' ) && $scripts->localize( 'updates', '_wpUpdatesSettings', array(
|
||||
'ajax_nonce' => wp_create_nonce( 'updates' ),
|
||||
'l10n' => array(
|
||||
'updating' => __( 'Updating...' ),
|
||||
'updated' => __( 'Updated!' ),
|
||||
'updateFailed' => __( 'Update failed' ),
|
||||
'installNow' => __( 'Install Now' ),
|
||||
'installing' => __( 'Installing...' ),
|
||||
'installed' => __( 'Installed!' ),
|
||||
'installFailed' => __( 'Installation failed' ),
|
||||
)
|
||||
) );
|
||||
|
||||
$scripts->add( 'farbtastic', '/wp-admin/js/farbtastic.js', array('jquery'), '1.2' );
|
||||
|
||||
|
||||
Reference in New Issue
Block a user