From 7b2c87df9a24dd317ec0c8f5adcb8796942fdd7f Mon Sep 17 00:00:00 2001 From: "Drew Jaynes (DrewAPicture)" Date: Mon, 19 May 2014 03:22:21 +0000 Subject: [PATCH] Improve inline documentation of default arguments for `post_format_meta_box()`, `post_tags_meta_box()`, and `post_categories_meta_box()`. See #28298. git-svn-id: https://develop.svn.wordpress.org/trunk@28499 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/includes/meta-boxes.php | 42 ++++++++++++++++++++++++++-- 1 file changed, 39 insertions(+), 3 deletions(-) diff --git a/src/wp-admin/includes/meta-boxes.php b/src/wp-admin/includes/meta-boxes.php index ca574eb072..b9f7f63d10 100644 --- a/src/wp-admin/includes/meta-boxes.php +++ b/src/wp-admin/includes/meta-boxes.php @@ -342,7 +342,15 @@ function attachment_submit_meta_box( $post ) { * * @since 3.1.0 * - * @param object $post + * @param WP_Post $post Post object. + * @param array $box { + * Post formats meta box arguments. + * + * @type string $id Meta box ID. + * @type string $title Meta box title. + * @type callback $callback Meta box display callback. + * @type array $args Extra meta box arguments. + * } */ function post_format_meta_box( $post, $box ) { if ( current_theme_supports( 'post-formats' ) && post_type_supports( $post->post_type, 'post-formats' ) ) : @@ -370,7 +378,21 @@ function post_format_meta_box( $post, $box ) { * * @since 2.6.0 * - * @param object $post + * @todo Create taxonomy-agnostic wrapper for this. + * + * @param WP_Post $post Post object. + * @param array $box { + * Tags meta box arguments. + * + * @type string $id Meta box ID. + * @type string $title Meta box title. + * @type callback $callback Meta box display callback. + * @type array $args { + * Extra meta box arguments. + * + * @type string $taxonomy Taxonomy. Default 'post_tag'. + * } + * } */ function post_tags_meta_box( $post, $box ) { $defaults = array( 'taxonomy' => 'post_tag' ); @@ -414,7 +436,21 @@ function post_tags_meta_box( $post, $box ) { * * @since 2.6.0 * - * @param object $post + * @todo Create taxonomy-agnostic wrapper for this. + * + * @param WP_Post $post Post object. + * @param array $box { + * Categories meta box arguments. + * + * @type string $id Meta box ID. + * @type string $title Meta box title. + * @type callback $callback Meta box display callback. + * @type array $args { + * Extra meta box arguments. + * + * @type string $taxonomy Taxonomy. Default 'category'. + * } + * } */ function post_categories_meta_box( $post, $box ) { $defaults = array( 'taxonomy' => 'category' );