Docs: Miscellaneous DocBlock corrections for plugin and theme installation and updates.
See #49572. git-svn-id: https://develop.svn.wordpress.org/trunk@48105 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
5e2ef3d937
commit
e27ad0f007
@ -276,7 +276,6 @@ class WP_Automatic_Updater {
|
||||
*
|
||||
* @param string $type The type of update being checked: 'core', 'theme', 'plugin', 'translation'.
|
||||
* @param object $item The update offer.
|
||||
*
|
||||
* @return null|WP_Error
|
||||
*/
|
||||
public function update( $type, $item ) {
|
||||
@ -1037,10 +1036,9 @@ class WP_Automatic_Updater {
|
||||
* @type string $body The email message body.
|
||||
* @type string $headers Any email headers, defaults to no headers.
|
||||
* }
|
||||
* @param string $type The type of email being sent. Can be one of
|
||||
* 'success', 'fail', 'mixed'.
|
||||
* @param array $successful_updates The updates that succeeded.
|
||||
* @param array $failed_updates The updates that failed.
|
||||
* @param string $type The type of email being sent. Can be one of 'success', 'fail', 'mixed'.
|
||||
* @param array $successful_updates A list of updates that succeeded.
|
||||
* @param array $failed_updates A list of updates that failed.
|
||||
*/
|
||||
$email = apply_filters( 'auto_plugin_theme_update_email', $email, $type, $successful_updates, $failed_updates );
|
||||
|
||||
|
@ -639,6 +639,7 @@ class WP_MS_Themes_List_Table extends WP_List_Table {
|
||||
*/
|
||||
public function column_description( $theme ) {
|
||||
global $status, $totals;
|
||||
|
||||
if ( $theme->errors() ) {
|
||||
$pre = 'broken' === $status ? __( 'Broken Theme:' ) . ' ' : '';
|
||||
echo '<p><strong class="error-message">' . $pre . $theme->errors()->get_error_message() . '</strong></p>';
|
||||
@ -680,20 +681,21 @@ class WP_MS_Themes_List_Table extends WP_List_Table {
|
||||
__( 'Visit Theme Site' )
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filters the array of row meta for each theme in the Multisite themes
|
||||
* list table.
|
||||
*
|
||||
* @since 3.1.0
|
||||
*
|
||||
* @param string[] $theme_meta An array of the theme's metadata,
|
||||
* including the version, author, and
|
||||
* theme URI.
|
||||
* @param string[] $theme_meta An array of the theme's metadata, including
|
||||
* the version, author, and theme URI.
|
||||
* @param string $stylesheet Directory name of the theme.
|
||||
* @param WP_Theme $theme WP_Theme object.
|
||||
* @param string $status Status of the theme.
|
||||
*/
|
||||
$theme_meta = apply_filters( 'theme_row_meta', $theme_meta, $stylesheet, $theme, $status );
|
||||
|
||||
echo implode( ' | ', $theme_meta );
|
||||
|
||||
echo '</div>';
|
||||
@ -768,8 +770,8 @@ class WP_MS_Themes_List_Table extends WP_List_Table {
|
||||
*
|
||||
* @since 5.5.0
|
||||
*
|
||||
* @param string $html The HTML for theme’s auto-update setting including toggle auto-update action link
|
||||
* and time to next update.
|
||||
* @param string $html The HTML for theme's auto-update setting, including
|
||||
* toggle auto-update action link and time to next update.
|
||||
* @param string $stylesheet Directory name of the theme.
|
||||
* @param WP_Theme $theme WP_Theme object.
|
||||
*/
|
||||
|
@ -117,21 +117,21 @@ class WP_Plugin_Install_List_Table extends WP_List_Table {
|
||||
$nonmenu_tabs = array( 'plugin-information' ); // Valid actions to perform which do not have a Menu item.
|
||||
|
||||
/**
|
||||
* Filters the tabs shown on the Plugin Install screen.
|
||||
* Filters the tabs shown on the Add Plugins screen.
|
||||
*
|
||||
* @since 2.7.0
|
||||
*
|
||||
* @param string[] $tabs The tabs shown on the Plugin Install screen. Defaults include 'featured', 'popular',
|
||||
* 'recommended', 'favorites', and 'upload'.
|
||||
* @param string[] $tabs The tabs shown on the Add Plugins screen. Defaults include
|
||||
* 'featured', 'popular', 'recommended', 'favorites', and 'upload'.
|
||||
*/
|
||||
$tabs = apply_filters( 'install_plugins_tabs', $tabs );
|
||||
|
||||
/**
|
||||
* Filters tabs not associated with a menu item on the Plugin Install screen.
|
||||
* Filters tabs not associated with a menu item on the Add Plugins screen.
|
||||
*
|
||||
* @since 2.7.0
|
||||
*
|
||||
* @param string[] $nonmenu_tabs The tabs that don't have a menu item on the Plugin Install screen.
|
||||
* @param string[] $nonmenu_tabs The tabs that don't have a menu item on the Add Plugins screen.
|
||||
*/
|
||||
$nonmenu_tabs = apply_filters( 'install_plugins_nonmenu_tabs', $nonmenu_tabs );
|
||||
|
||||
@ -207,14 +207,14 @@ class WP_Plugin_Install_List_Table extends WP_List_Table {
|
||||
}
|
||||
|
||||
/**
|
||||
* Filters API request arguments for each Plugin Install screen tab.
|
||||
* Filters API request arguments for each Add Plugins screen tab.
|
||||
*
|
||||
* The dynamic portion of the hook name, `$tab`, refers to the plugin install tabs.
|
||||
* Default tabs include 'featured', 'popular', 'recommended', 'favorites', and 'upload'.
|
||||
*
|
||||
* @since 3.7.0
|
||||
*
|
||||
* @param array|bool $args Plugin Install API arguments.
|
||||
* @param array|false $args Plugin install API arguments.
|
||||
*/
|
||||
$args = apply_filters( "install_plugins_table_api_args_{$tab}", $args );
|
||||
|
||||
|
@ -1006,9 +1006,8 @@ class WP_Plugins_List_Table extends WP_List_Table {
|
||||
*
|
||||
* @since 2.8.0
|
||||
*
|
||||
* @param string[] $plugin_meta An array of the plugin's metadata,
|
||||
* including the version, author,
|
||||
* author URI, and plugin URI.
|
||||
* @param string[] $plugin_meta An array of the plugin's metadata, including
|
||||
* the version, author, author URI, and plugin URI.
|
||||
* @param string $plugin_file Path to the plugin file relative to the plugins directory.
|
||||
* @param array $plugin_data An array of plugin data.
|
||||
* @param string $status Status of the plugin. Defaults are 'All', 'Active',
|
||||
@ -1016,6 +1015,7 @@ class WP_Plugins_List_Table extends WP_List_Table {
|
||||
* 'Drop-ins', 'Search', 'Paused'.
|
||||
*/
|
||||
$plugin_meta = apply_filters( 'plugin_row_meta', $plugin_meta, $plugin_file, $plugin_data, $status );
|
||||
|
||||
echo implode( ' | ', $plugin_meta );
|
||||
|
||||
echo '</div>';
|
||||
@ -1089,8 +1089,8 @@ class WP_Plugins_List_Table extends WP_List_Table {
|
||||
*
|
||||
* @since 5.5.0
|
||||
*
|
||||
* @param string $html The HTML of the plugin's auto-update column content,
|
||||
* including toggle auto-update action links and time to next update.
|
||||
* @param string $html The HTML of the plugin's auto-update column content, including
|
||||
* toggle auto-update action links and time to next update.
|
||||
* @param string $plugin_file Path to the plugin file relative to the plugins directory.
|
||||
* @param array $plugin_data An array of plugin data.
|
||||
*/
|
||||
|
@ -137,7 +137,7 @@ class WP_Theme_Install_List_Table extends WP_Themes_List_Table {
|
||||
*
|
||||
* @since 3.7.0
|
||||
*
|
||||
* @param array $args An array of themes API arguments.
|
||||
* @param array|false $args Theme install API arguments.
|
||||
*/
|
||||
$args = apply_filters( "install_themes_table_api_args_{$tab}", $args );
|
||||
|
||||
|
@ -677,7 +677,7 @@ function activate_plugin( $plugin, $redirect = '', $network_wide = false, $silen
|
||||
*
|
||||
* @param string $plugin Path to the plugin file relative to the plugins directory.
|
||||
* @param bool $network_wide Whether to enable the plugin for all sites in the network
|
||||
* or just the current site. Multisite only. Default is false.
|
||||
* or just the current site. Multisite only. Default false.
|
||||
*/
|
||||
do_action( 'activate_plugin', $plugin, $network_wide );
|
||||
|
||||
@ -692,7 +692,7 @@ function activate_plugin( $plugin, $redirect = '', $network_wide = false, $silen
|
||||
* @since 2.0.0
|
||||
*
|
||||
* @param bool $network_wide Whether to enable the plugin for all sites in the network
|
||||
* or just the current site. Multisite only. Default is false.
|
||||
* or just the current site. Multisite only. Default false.
|
||||
*/
|
||||
do_action( "activate_{$plugin}", $network_wide );
|
||||
}
|
||||
@ -719,7 +719,7 @@ function activate_plugin( $plugin, $redirect = '', $network_wide = false, $silen
|
||||
*
|
||||
* @param string $plugin Path to the plugin file relative to the plugins directory.
|
||||
* @param bool $network_wide Whether to enable the plugin for all sites in the network
|
||||
* or just the current site. Multisite only. Default is false.
|
||||
* or just the current site. Multisite only. Default false.
|
||||
*/
|
||||
do_action( 'activated_plugin', $plugin, $network_wide );
|
||||
}
|
||||
|
@ -552,7 +552,7 @@ if ( ! is_multisite() && $broken_themes ) {
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Returns the template for displaying the auto-update setting for a theme.
|
||||
* Returns the JavaScript template used to display the auto-update setting for a theme.
|
||||
*
|
||||
* @since 5.5.0
|
||||
*
|
||||
@ -585,7 +585,7 @@ function wp_theme_auto_update_setting_template() {
|
||||
';
|
||||
|
||||
/**
|
||||
* Filters the JavaScript template used in Backbone to display the auto-update setting for a theme (in the overlay).
|
||||
* Filters the JavaScript template used to display the auto-update setting for a theme (in the overlay).
|
||||
*
|
||||
* See {@see wp_prepare_themes_for_js()} for the properties of the `data` object.
|
||||
*
|
||||
|
Loading…
Reference in New Issue
Block a user