Make WordPress Core


Ignore:
Timestamp:
12/14/2021 01:55:28 AM (3 years ago)
Author:
noisysocks
Message:

Update @wordpress packages

Update packages to include these bug fixes from Gutenberg:

  • Image block: Set image display to grid when no alignment sent to properly align caption on resize
  • Update and align template descriptions
  • Site Editor - prevent loading state from showing the admin menu.
  • Add client side routing for Site Editor
  • Navigation: Add clearance for appender in submenus.
  • Fix CSS Custom Properties for presets in the site editor
  • Add/navigation blocks post processing after migration from menu items
  • Allow selector ordering to ensure theme.json root selector margin takes precedence
  • Do not remove theme presets if defaults are hidden
  • Format library: fix unsetting highlight color
  • FSE: Fix template resolution to give precedence to child theme PHP templates over parent theme block templates with equal specificity
  • ColorPalette: Improving accessibility and visibility
  • Update: Make the color popover on the gradient picker appear as expected
  • Site Editor: Display a notice if export fails
  • Fix docs and function naming for gallery block registration in PHP
  • Switch to addEventListener for load event in the navigation block view script
  • Fix mistake in _remove_theme_attribute_in_block_template_content
  • Better synchronisation between Gutenberg and Core code
  • Move the block page templates hook into compat/5.9 folder
  • Moves to the template loader hooks and functions into lib/compat folder
  • Refactor the gutenberg_is_fse_theme function to use wp_is_block_theme
  • Site Editor: Update support doc URL in Welcome Guide
  • Global Styles: Add Welcome Guide toggle
  • Hide remove control point when removing would break gradient control
  • Don't request the deprecated navigation areas endpoint outside of the Gutenberg plugin
  • Image: Fix resizer controls being hidden in Safari when switching between alignments
  • Remove Navigation Menus from WP Admin sidebar
  • Site Editor: Hide the block appender in the Template Part editor
  • Site Editor: Use server definition for the Template Areas
  • Synchronize wp_is_block_theme and block-templates block support with Core
  • E2E: Retry login again after a bad nonce request to prevent intermittent test failures
  • Fix theme requirement validation with WP 5.8
  • Fix WP 5.9 check for conditionally running code
  • Fix post comment form input width
  • Border Style Control: Update styling for consistency with border width control
  • Fix form-submit styles by adding button classes to the submit-button in post-comments block
  • Site Editor: Fix edit template part link in header dropdown
  • Move duotone palette to the bottom of global styles gradients
  • Fix how appearanceTools works
  • Move WP 5.9 wp-admin menus compatibility code to lib/compat folder
  • Revert "Site Editor: Set the <title> on the list page to be same as the CPT name"
  • Site Editor: Document Actions: add SR text to heading 1
  • Do not register global styles CPT in WordPress 5.9
  • Global Styles: Move the 'Edit colors' button to a standard menu item
  • Fix styles for previews and patterns
  • Site Editor: Fix failing E2E test
  • Templates: Search for old template names in the parent theme too
  • Remove 4 instances of 'gutenberg' text domain from WordPress core
  • Fix content loss when ungrouping template parts or reusable blocks
  • Simplify the RESET_BLOCK action to fix template part focus mode content loss
  • [Global Styles]: Make Blocks section more distinguishable
  • Only use block markup for comment form button when using a block theme
  • Navigation: Fix vertical alignment of page list in modal.
  • Fix: ToggleGroupControl active state
  • Remove gutenberg_ prefix from @wordpress/block-library

Props ocean90, oandregal, hellofromtonya, youknowriad.
See #54487.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/site-editor.php

    r52336 r52364  
    2424}
    2525
     26// Used in the HTML title tag.
     27$title       = __( 'Editor (beta)' );
    2628$parent_file = 'themes.php';
    2729
     
    5759
    5860if ( isset( $_GET['postType'] ) && ! isset( $_GET['postId'] ) ) {
    59 
    6061    $post_type = get_post_type_object( $_GET['postType'] );
    61 
    6262    if ( ! $post_type ) {
    6363        wp_die( __( 'Invalid post type.' ) );
    6464    }
     65}
    6566
    66     // Used in the HTML title tag.
    67     $title = $post_type->labels->name;
     67$active_global_styles_id = WP_Theme_JSON_Resolver::get_user_custom_post_type_id();
     68$active_theme            = wp_get_theme()->get_stylesheet();
     69$preload_paths           = array(
     70    array( '/wp/v2/media', 'OPTIONS' ),
     71    '/',
     72    '/wp/v2/types?context=edit',
     73    '/wp/v2/types/wp_template?context=edit',
     74    '/wp/v2/types/wp_template-part?context=edit',
     75    '/wp/v2/taxonomies?context=edit',
     76    '/wp/v2/pages?context=edit',
     77    '/wp/v2/categories?context=edit',
     78    '/wp/v2/posts?context=edit',
     79    '/wp/v2/tags?context=edit',
     80    '/wp/v2/templates?context=edit&per_page=-1',
     81    '/wp/v2/template-parts?context=edit&per_page=-1',
     82    '/wp/v2/settings',
     83    '/wp/v2/themes?context=edit&status=active',
     84    '/wp/v2/global-styles/' . $active_global_styles_id . '?context=edit',
     85    '/wp/v2/global-styles/' . $active_global_styles_id,
     86    '/wp/v2/global-styles/themes/' . $active_theme,
     87);
    6888
    69     $preload_paths = array(
    70         '/',
    71         '/wp/v2/types/' . $post_type->name . '?context=edit',
    72         '/wp/v2/types?context=edit',
    73         add_query_arg( 'context', 'edit', rest_get_route_for_post_type_items( $post_type->name ) ),
    74     );
     89block_editor_rest_api_preload( $preload_paths, $block_editor_context );
    7590
    76     block_editor_rest_api_preload( $preload_paths, $block_editor_context );
    77 
    78     wp_add_inline_script(
    79         'wp-edit-site',
    80         sprintf(
    81             'wp.domReady( function() {
    82                 wp.editSite.initializeList( "site-editor", "%s", %s );
    83             } );',
    84             $post_type->name,
    85             wp_json_encode( $editor_settings )
    86         )
    87     );
    88 
    89 } else {
    90 
    91     // Used in the HTML title tag.
    92     $title = __( 'Editor (beta)' );
    93 
    94     $active_global_styles_id = WP_Theme_JSON_Resolver::get_user_custom_post_type_id();
    95     $active_theme            = wp_get_theme()->get_stylesheet();
    96     $preload_paths           = array(
    97         array( rest_get_route_for_post_type_items( 'attachment' ), 'OPTIONS' ),
    98         '/',
    99         '/wp/v2/types?context=edit',
    100         '/wp/v2/taxonomies?context=edit',
    101         add_query_arg( 'context', 'edit', rest_get_route_for_post_type_items( 'page' ) ),
    102         add_query_arg( 'context', 'edit', rest_get_route_for_post_type_items( 'post' ) ),
    103         add_query_arg( 'context', 'edit', rest_get_route_for_taxonomy_items( 'category' ) ),
    104         add_query_arg( 'context', 'edit', rest_get_route_for_taxonomy_items( 'post_tag' ) ),
    105         add_query_arg( 'context', 'edit', rest_get_route_for_post_type_items( 'wp_template' ) ),
    106         add_query_arg( 'context', 'edit', rest_get_route_for_post_type_items( 'wp_template_part' ) ),
    107         '/wp/v2/settings',
    108         '/wp/v2/themes?context=edit&status=active',
    109         '/wp/v2/global-styles/' . $active_global_styles_id . '?context=edit',
    110         '/wp/v2/global-styles/' . $active_global_styles_id,
    111         '/wp/v2/themes/' . $active_theme . '/global-styles',
    112     );
    113 
    114     block_editor_rest_api_preload( $preload_paths, $block_editor_context );
    115 
    116     wp_add_inline_script(
    117         'wp-edit-site',
    118         sprintf(
    119             'wp.domReady( function() {
    120                 wp.editSite.initializeEditor( "site-editor", %s );
    121             } );',
    122             wp_json_encode( $editor_settings )
    123         )
    124     );
    125 
    126 }
     91wp_add_inline_script(
     92    'wp-edit-site',
     93    sprintf(
     94        'wp.domReady( function() {
     95            wp.editSite.initializeEditor( "site-editor", %s );
     96        } );',
     97        wp_json_encode( $editor_settings )
     98    )
     99);
    127100
    128101// Preload server-registered block schemas.
Note: See TracChangeset for help on using the changeset viewer.