WordPress.org

Make WordPress Core

Changeset 46600


Ignore:
Timestamp:
10/27/2019 02:05:18 PM (2 years ago)
Author:
SergeyBiryukov
Message:

Docs: Improve DocBlock formatting in WP_Block_Styles_Registry per the documentation standards.

See #48303.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/class-wp-block-styles-registry.php

    r46594 r46600  
    3636     *
    3737     * @param string $block_name       Block type name including namespace.
    38      * @param array  $style_properties Array containing the properties of the style name, label, style (name of the stylesheet to be enqueued), inline_style (string containing the CSS to be added).
    39      *
     38     * @param array  $style_properties Array containing the properties of the style name, label,
     39     *                                 style (name of the stylesheet to be enqueued),
     40     *                                 inline_style (string containing the CSS to be added).
    4041     * @return boolean True if the block style was registered with success and false otherwise.
    4142     */
     
    6970     * @param string $block_name       Block type name including namespace.
    7071     * @param string $block_style_name Block style name.
    71      *
    7272     * @return boolean True if the block style was unregistered with success and false otherwise.
    7373     */
    7474    public function unregister( $block_name, $block_style_name ) {
    7575        if ( ! $this->is_registered( $block_name, $block_style_name ) ) {
    76             /* translators: 1: block name, 2: block style name */
    77             $message = sprintf( __( 'Block "%1$s" does not contain a style named "%2$s.".' ), $block_name, $block_style_name );
     76            /* translators: 1: Block name, 2: Block style name. */
     77            $message = sprintf( __( 'Block "%1$s" does not contain a style named "%2$s".' ), $block_name, $block_style_name );
    7878            _doing_it_wrong( __METHOD__, $message, '5.3.0' );
    7979            return false;
     
    9292     * @param string $block_name       Block type name including namespace.
    9393     * @param string $block_style_name Block style name.
    94      *
    9594     * @return array Registered block style properties.
    9695     */
     
    108107     * @since 5.3.0
    109108     *
    110      * @return array Array of arrays containing the registered block styles properties grouped per block, and per style.
     109     * @return array Array of arrays containing the registered block styles properties grouped per block,
     110     *               and per style.
    111111     */
    112112    public function get_all_registered() {
     
    120120     *
    121121     * @param string $block_name Block type name including namespace.
    122      *
    123122     * @return array Array whose keys are block style names and whose value are block style properties.
    124123     */
     
    137136     * @param string $block_name       Block type name including namespace.
    138137     * @param string $block_style_name Block style name.
    139      *
    140138     * @return bool True if the block style is registered, false otherwise.
    141139     */
Note: See TracChangeset for help on using the changeset viewer.