Skip to content

Commit f30f29c

Browse files
Docs: Correct alignment in WP_Block_Bindings_Registry::register() DocBlock.
Follow-up to [57373], [57375], [57641]. Props nareshbheda, mukesh27. Fixes #61412. git-svn-id: https://develop.svn.wordpress.org/trunk@58395 602fd350-edb4-49c9-b593-d223f7449a82
1 parent c2bf2eb commit f30f29c

File tree

2 files changed

+29
-29
lines changed

2 files changed

+29
-29
lines changed

src/wp-includes/block-bindings.php

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -75,19 +75,19 @@
7575
* @param array $source_properties {
7676
* The array of arguments that are used to register a source.
7777
*
78-
* @type string $label The label of the source.
79-
* @type callable $get_value_callback A callback executed when the source is processed during block rendering.
80-
* The callback should have the following signature:
81-
*
82-
* `function ($source_args, $block_instance,$attribute_name): mixed`
83-
* - @param array $source_args Array containing source arguments
84-
* used to look up the override value,
85-
* i.e. {"key": "foo"}.
86-
* - @param WP_Block $block_instance The block instance.
87-
* - @param string $attribute_name The name of an attribute .
88-
* The callback has a mixed return type; it may return a string to override
89-
* the block's original value, null, false to remove an attribute, etc.
90-
* @type string[] $uses_context (optional) Array of values to add to block `uses_context` needed by the source.
78+
* @type string $label The label of the source.
79+
* @type callable $get_value_callback A callback executed when the source is processed during block rendering.
80+
* The callback should have the following signature:
81+
*
82+
* `function( $source_args, $block_instance, $attribute_name ): mixed`
83+
* - @param array $source_args Array containing source arguments
84+
* used to look up the override value,
85+
* i.e. {"key": "foo"}.
86+
* - @param WP_Block $block_instance The block instance.
87+
* - @param string $attribute_name The name of an attribute.
88+
* The callback has a mixed return type; it may return a string to override
89+
* the block's original value, null, false to remove an attribute, etc.
90+
* @type string[] $uses_context Optional. Array of values to add to block `uses_context` needed by the source.
9191
* }
9292
* @return WP_Block_Bindings_Source|false Source when the registration was successful, or `false` on failure.
9393
*/

src/wp-includes/class-wp-block-bindings-registry.php

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -72,25 +72,25 @@ final class WP_Block_Bindings_Registry {
7272
*
7373
* @since 6.5.0
7474
*
75-
* @param string $source_name The name of the source. It must be a string containing a namespace prefix, i.e.
76-
* `my-plugin/my-custom-source`. It must only contain lowercase alphanumeric
77-
* characters, the forward slash `/` and dashes.
78-
* @param array $source_properties {
75+
* @param string $source_name The name of the source. It must be a string containing a namespace prefix, i.e.
76+
* `my-plugin/my-custom-source`. It must only contain lowercase alphanumeric
77+
* characters, the forward slash `/` and dashes.
78+
* @param array $source_properties {
7979
* The array of arguments that are used to register a source.
8080
*
81-
* @type string $label The label of the source.
82-
* @type callable $get_value_callback A callback executed when the source is processed during block rendering.
83-
* The callback should have the following signature:
81+
* @type string $label The label of the source.
82+
* @type callable $get_value_callback A callback executed when the source is processed during block rendering.
83+
* The callback should have the following signature:
8484
*
85-
* `function ($source_args, $block_instance,$attribute_name): mixed`
86-
* - @param array $source_args Array containing source arguments
87-
* used to look up the override value,
88-
* i.e. {"key": "foo"}.
89-
* - @param WP_Block $block_instance The block instance.
90-
* - @param string $attribute_name The name of the target attribute.
91-
* The callback has a mixed return type; it may return a string to override
92-
* the block's original value, null, false to remove an attribute, etc.
93-
* @type string[] $uses_context (optional) Array of values to add to block `uses_context` needed by the source.
85+
* `function( $source_args, $block_instance, $attribute_name ): mixed`
86+
* - @param array $source_args Array containing source arguments
87+
* used to look up the override value,
88+
* i.e. {"key": "foo"}.
89+
* - @param WP_Block $block_instance The block instance.
90+
* - @param string $attribute_name The name of the target attribute.
91+
* The callback has a mixed return type; it may return a string to override
92+
* the block's original value, null, false to remove an attribute, etc.
93+
* @type string[] $uses_context Optional. Array of values to add to block `uses_context` needed by the source.
9494
* }
9595
* @return WP_Block_Bindings_Source|false Source when the registration was successful, or `false` on failure.
9696
*/

0 commit comments

Comments
 (0)