WordPress.org

Make WordPress Core


Ignore:
Timestamp:
03/12/2021 01:33:21 PM (9 months ago)
Author:
gziolo
Message:

Editor: Make block type aware of variations

Currently block variations are only defined on the client. In some cases, creating block variations on the server can be very useful, especially when needed data is not exposed in the REST APIs.

Related to https://github.com/WordPress/gutenberg/pull/29095.

Props: gwwar, timothyblynjacobs.
Fixes: #52688.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/taxonomy.php

    r50505 r50527  
    577577 *     @type string $most_used                  Title for the Most Used tab. Default 'Most Used'.
    578578 *     @type string $back_to_items              Label displayed after a term has been updated.
     579 *     @type string $item_link                  Used in the block editor. Title for a navigation link block variation.
     580 *                                              Default 'Tag Link'/'Category Link'.
     581 *     @type string $item_link_description      Used in the block editor. Description for a navigation link block
     582 *                                              variation. Default 'A link to a tag.'/'A link to a category'.
    579583 * }
    580584 */
     
    614618        'most_used'                  => array( _x( 'Most Used', 'tags' ), _x( 'Most Used', 'categories' ) ),
    615619        'back_to_items'              => array( __( '← Go to Tags' ), __( '← Go to Categories' ) ),
     620        'item_link'                  => array(
     621            _x( 'Tag Link', 'navigation link block title' ),
     622            _x( 'Category Link', 'navigation link block description' ),
     623        ),
     624        'item_link_description'      => array(
     625            _x( 'A link to a tag.', 'navigation link block description' ),
     626            _x( 'A link to a category.', 'navigation link block description' ),
     627        ),
    616628    );
    617629    $nohier_vs_hier_defaults['menu_name'] = $nohier_vs_hier_defaults['name'];
Note: See TracChangeset for help on using the changeset viewer.