Make WordPress Core


Ignore:
Timestamp:
10/10/2023 11:27:50 AM (9 months ago)
Author:
karmatosed
Message:

Update editor related npm packages for beta 3 second part.

The npm packages needed a second part to the update for beta 3 in preparation for 6.4.

Props talldan, ellatrix, santosguillamot, ramonopoly, andrewserong, artemiosans, isabel_brison, mikachan.

See #59411.

File:
1 edited

Legend:

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

    r56710 r56816  
    697697    $close_button_directives         = '';
    698698    if ( $should_load_view_script ) {
     699        $nav_element_context             = wp_json_encode(
     700            array(
     701                'core' => array(
     702                    'navigation' => array(
     703                        'overlayOpenedBy' => array(),
     704                        'type'            => 'overlay',
     705                        'roleAttribute'   => '',
     706                        'ariaLabel'       => __( 'Menu' ),
     707                    ),
     708                ),
     709            ),
     710            JSON_HEX_TAG | JSON_HEX_APOS | JSON_HEX_AMP
     711        );
    699712        $nav_element_directives          = '
    700713            data-wp-interactive
    701             data-wp-context=\'{ "core": { "navigation": { "overlayOpenedBy": {}, "type": "overlay", "roleAttribute": "" } } }\'
     714            data-wp-context=\'' . $nav_element_context . '\'
    702715        ';
    703716        $open_button_directives          = '
     
    715728        $responsive_dialog_directives    = '
    716729            data-wp-bind--aria-modal="selectors.core.navigation.ariaModal"
     730            data-wp-bind--aria-label="selectors.core.navigation.ariaLabel"
    717731            data-wp-bind--role="selectors.core.navigation.roleAttribute"
    718732            data-wp-effect="effects.core.navigation.focusFirstElement"
     
    724738
    725739    $responsive_container_markup = sprintf(
    726         '<button aria-haspopup="true" %3$s class="%6$s" %11$s>%9$s</button>
    727             <div class="%5$s" style="%7$s" id="%1$s" %12$s>
     740        '<button aria-haspopup="true" %3$s class="%6$s" %10$s>%8$s</button>
     741            <div class="%5$s" style="%7$s" id="%1$s" %11$s>
    728742                <div class="wp-block-navigation__responsive-close" tabindex="-1">
    729                     <div class="wp-block-navigation__responsive-dialog" aria-label="%8$s" %13$s>
    730                             <button %4$s class="wp-block-navigation__responsive-container-close" %14$s>%10$s</button>
     743                    <div class="wp-block-navigation__responsive-dialog" %12$s>
     744                            <button %4$s class="wp-block-navigation__responsive-container-close" %13$s>%9$s</button>
    731745                        <div class="wp-block-navigation__responsive-container-content" id="%1$s-content">
    732746                            %2$s
     
    742756        esc_attr( implode( ' ', $open_button_classes ) ),
    743757        esc_attr( safecss_filter_attr( $colors['overlay_inline_styles'] ) ),
    744         __( 'Menu' ),
    745758        $toggle_button_content,
    746759        $toggle_close_button_content,
Note: See TracChangeset for help on using the changeset viewer.