mirror of
https://github.com/WordPress/WordPress.git
synced 2025-12-05 11:24:25 +01:00
Docs: Docblock adjustments in some 5.9 block related functions.
Adds missing `@since` mention to `wp_enqueue_block_style()` and `_wp_multiple_block_styles()`, and a few other minor changes. Follow-up to [52069]. See #53359. Built from https://develop.svn.wordpress.org/trunk@52354 git-svn-id: http://core.svn.wordpress.org/trunk@51946 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
f847144952
commit
adee0cbf6b
@ -1191,15 +1191,16 @@ function get_query_pagination_arrow( $block, $is_next ) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Enqueue a stylesheet for a specific block.
|
* Enqueues a stylesheet for a specific block.
|
||||||
*
|
*
|
||||||
* If the theme has opted-in to separate-styles loading,
|
* If the theme has opted-in to separate-styles loading,
|
||||||
* then the stylesheet will be enqueued on-render,
|
* then the stylesheet will be enqueued on-render,
|
||||||
* otherwise when the block inits.
|
* otherwise when the block inits.
|
||||||
*
|
*
|
||||||
|
* @since 5.9.0
|
||||||
|
*
|
||||||
* @param string $block_name The block-name, including namespace.
|
* @param string $block_name The block-name, including namespace.
|
||||||
* @param array $args An array of arguments [handle,src,deps,ver,media].
|
* @param array $args An array of arguments [handle,src,deps,ver,media].
|
||||||
*
|
|
||||||
* @return void
|
* @return void
|
||||||
*/
|
*/
|
||||||
function wp_enqueue_block_style( $block_name, $args ) {
|
function wp_enqueue_block_style( $block_name, $args ) {
|
||||||
@ -1220,8 +1221,7 @@ function wp_enqueue_block_style( $block_name, $args ) {
|
|||||||
* @param string $content When the callback is used for the render_block filter,
|
* @param string $content When the callback is used for the render_block filter,
|
||||||
* the content needs to be returned so the function parameter
|
* the content needs to be returned so the function parameter
|
||||||
* is to ensure the content exists.
|
* is to ensure the content exists.
|
||||||
*
|
* @return string Block content.
|
||||||
* @return string
|
|
||||||
*/
|
*/
|
||||||
$callback = static function( $content ) use ( $args ) {
|
$callback = static function( $content ) use ( $args ) {
|
||||||
// Register the stylesheet.
|
// Register the stylesheet.
|
||||||
@ -1275,9 +1275,10 @@ function wp_enqueue_block_style( $block_name, $args ) {
|
|||||||
/**
|
/**
|
||||||
* Allow multiple block styles.
|
* Allow multiple block styles.
|
||||||
*
|
*
|
||||||
* @param array $metadata Metadata for registering a block type.
|
* @since 5.9.0
|
||||||
*
|
*
|
||||||
* @return array
|
* @param array $metadata Metadata for registering a block type.
|
||||||
|
* @return array Metadata for registering a block type.
|
||||||
*/
|
*/
|
||||||
function _wp_multiple_block_styles( $metadata ) {
|
function _wp_multiple_block_styles( $metadata ) {
|
||||||
foreach ( array( 'style', 'editorStyle' ) as $key ) {
|
foreach ( array( 'style', 'editorStyle' ) as $key ) {
|
||||||
|
|||||||
@ -16,7 +16,7 @@
|
|||||||
*
|
*
|
||||||
* @global string $wp_version
|
* @global string $wp_version
|
||||||
*/
|
*/
|
||||||
$wp_version = '5.9-beta2-52353';
|
$wp_version = '5.9-beta2-52354';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user