Make WordPress Core


Ignore:
Timestamp:
11/08/2021 02:26:27 PM (4 years ago)
Author:
youknowriad
Message:

Block Editor: Update the WordPress Packages based on Gutenberg 11.9 RC1.

This brings the JS packages up to date and is the first step that will allow us
to include the other block editor updates for WordPress 5.9:
FSE infrastrucutre, site editor and global styles.

Props noisysocks.
See #54337.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/blocks/query-pagination.php

    r50929 r52042  
    77
    88/**
     9 * Renders the `core/query-pagination` block on the server.
     10 *
     11 * @param array  $attributes Block attributes.
     12 * @param string $content    Block default content.
     13 *
     14 * @return string Returns the wrapper for the Query pagination.
     15 */
     16function render_block_core_query_pagination( $attributes, $content ) {
     17    if ( empty( trim( $content ) ) ) {
     18        return '';
     19    }
     20
     21    return sprintf(
     22        '<div %1$s>%2$s</div>',
     23        get_block_wrapper_attributes(),
     24        $content
     25    );
     26}
     27
     28/**
    929 * Registers the `core/query-pagination` block on the server.
    1030 */
    1131function register_block_core_query_pagination() {
    1232    register_block_type_from_metadata(
    13         __DIR__ . '/query-pagination'
     33        __DIR__ . '/query-pagination',
     34        array(
     35            'render_callback' => 'render_block_core_query_pagination',
     36        )
    1437    );
    1538}
Note: See TracChangeset for help on using the changeset viewer.