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. Built from https://develop.svn.wordpress.org/trunk@56816 git-svn-id: http://core.svn.wordpress.org/trunk@56328 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
330f070340
commit
6468f40e61
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
@ -200,6 +200,7 @@ function block_core_image_render_lightbox( $block_content, $block ) {
|
|||
$w->set_attribute( 'data-wp-init', 'effects.core.image.setCurrentSrc' );
|
||||
$w->set_attribute( 'data-wp-on--load', 'actions.core.image.handleLoad' );
|
||||
$w->set_attribute( 'data-wp-effect', 'effects.core.image.setButtonStyles' );
|
||||
$w->set_attribute( 'data-wp-effect--setStylesOnResize', 'effects.core.image.setStylesOnResize' );
|
||||
$body_content = $w->get_updated_html();
|
||||
|
||||
// Wrap the image in the body content with a button.
|
||||
|
|
|
@ -1 +1 @@
|
|||
<?php return array('dependencies' => array(), 'version' => '3417a4e11cf880e590b5');
|
||||
<?php return array('dependencies' => array(), 'version' => '3925a54ac2df8ffae562');
|
||||
|
|
|
@ -95,7 +95,7 @@ function handleScroll(context) {
|
|||
context.core.image.lastFocusedElement = window.document.activeElement;
|
||||
context.core.image.scrollDelta = 0;
|
||||
context.core.image.lightboxEnabled = true;
|
||||
setStyles(context, event);
|
||||
setStyles(context, event.target.previousElementSibling);
|
||||
context.core.image.scrollTopReset = window.pageYOffset || document.documentElement.scrollTop;
|
||||
|
||||
// In most cases, this value will be 0, but this is included
|
||||
|
@ -309,6 +309,15 @@ function handleScroll(context) {
|
|||
context.core.image.imageButtonWidth = offsetWidth;
|
||||
context.core.image.imageButtonHeight = offsetHeight;
|
||||
}
|
||||
},
|
||||
setStylesOnResize: ({
|
||||
state,
|
||||
context,
|
||||
ref
|
||||
}) => {
|
||||
if (context.core.image.lightboxEnabled && (state.core.image.windowWidth || state.core.image.windowHeight)) {
|
||||
setStyles(context, ref);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -331,7 +340,7 @@ function handleScroll(context) {
|
|||
* @param {Object} context - An Interactivity API context
|
||||
* @param {Object} event - A triggering event
|
||||
*/
|
||||
function setStyles(context, event) {
|
||||
function setStyles(context, ref) {
|
||||
// The reference img element lies adjacent
|
||||
// to the event target button in the DOM.
|
||||
let {
|
||||
|
@ -339,11 +348,11 @@ function setStyles(context, event) {
|
|||
naturalHeight,
|
||||
offsetWidth: originalWidth,
|
||||
offsetHeight: originalHeight
|
||||
} = event.target.previousElementSibling;
|
||||
} = ref;
|
||||
let {
|
||||
x: screenPosX,
|
||||
y: screenPosY
|
||||
} = event.target.previousElementSibling.getBoundingClientRect();
|
||||
} = ref.getBoundingClientRect();
|
||||
|
||||
// Natural ratio of the image clicked to open the lightbox.
|
||||
const naturalRatio = naturalWidth / naturalHeight;
|
||||
|
|
|
@ -1 +1 @@
|
|||
<?php return array('dependencies' => array(), 'version' => '6e38467974481d14d2da');
|
||||
<?php return array('dependencies' => array(), 'version' => '658cda6fbef6b9d36ffd');
|
||||
|
|
File diff suppressed because one or more lines are too long
|
@ -152,10 +152,9 @@ function render_block_core_latest_posts( $attributes ) {
|
|||
if ( $excerpt_length <= $block_core_latest_posts_excerpt_length ) {
|
||||
$trimmed_excerpt = substr( $trimmed_excerpt, 0, -11 );
|
||||
$trimmed_excerpt .= sprintf(
|
||||
/* translators: 1: A URL to a post, 2: The static string "Read more", 3: The post title only visible to screen readers. */
|
||||
__( '… <a href="%1$s" rel="noopener noreferrer">%2$s<span class="screen-reader-text">: %3$s</span></a>' ),
|
||||
/* translators: 1: A URL to a post, 2: Hidden accessibility text: Post title */
|
||||
__( '… <a href="%1$s" rel="noopener noreferrer">Read more<span class="screen-reader-text">: %2$s</span></a>' ),
|
||||
esc_url( $post_link ),
|
||||
__( 'Read more' ),
|
||||
esc_html( $title )
|
||||
);
|
||||
}
|
||||
|
|
|
@ -696,9 +696,22 @@ function render_block_core_navigation( $attributes, $content, $block ) {
|
|||
$responsive_dialog_directives = '';
|
||||
$close_button_directives = '';
|
||||
if ( $should_load_view_script ) {
|
||||
$nav_element_context = wp_json_encode(
|
||||
array(
|
||||
'core' => array(
|
||||
'navigation' => array(
|
||||
'overlayOpenedBy' => array(),
|
||||
'type' => 'overlay',
|
||||
'roleAttribute' => '',
|
||||
'ariaLabel' => __( 'Menu' ),
|
||||
),
|
||||
),
|
||||
),
|
||||
JSON_HEX_TAG | JSON_HEX_APOS | JSON_HEX_AMP
|
||||
);
|
||||
$nav_element_directives = '
|
||||
data-wp-interactive
|
||||
data-wp-context=\'{ "core": { "navigation": { "overlayOpenedBy": {}, "type": "overlay", "roleAttribute": "" } } }\'
|
||||
data-wp-context=\'' . $nav_element_context . '\'
|
||||
';
|
||||
$open_button_directives = '
|
||||
data-wp-on--click="actions.core.navigation.openMenuOnClick"
|
||||
|
@ -714,6 +727,7 @@ function render_block_core_navigation( $attributes, $content, $block ) {
|
|||
';
|
||||
$responsive_dialog_directives = '
|
||||
data-wp-bind--aria-modal="selectors.core.navigation.ariaModal"
|
||||
data-wp-bind--aria-label="selectors.core.navigation.ariaLabel"
|
||||
data-wp-bind--role="selectors.core.navigation.roleAttribute"
|
||||
data-wp-effect="effects.core.navigation.focusFirstElement"
|
||||
';
|
||||
|
@ -723,11 +737,11 @@ function render_block_core_navigation( $attributes, $content, $block ) {
|
|||
}
|
||||
|
||||
$responsive_container_markup = sprintf(
|
||||
'<button aria-haspopup="true" %3$s class="%6$s" %11$s>%9$s</button>
|
||||
<div class="%5$s" style="%7$s" id="%1$s" %12$s>
|
||||
'<button aria-haspopup="true" %3$s class="%6$s" %10$s>%8$s</button>
|
||||
<div class="%5$s" style="%7$s" id="%1$s" %11$s>
|
||||
<div class="wp-block-navigation__responsive-close" tabindex="-1">
|
||||
<div class="wp-block-navigation__responsive-dialog" aria-label="%8$s" %13$s>
|
||||
<button %4$s class="wp-block-navigation__responsive-container-close" %14$s>%10$s</button>
|
||||
<div class="wp-block-navigation__responsive-dialog" %12$s>
|
||||
<button %4$s class="wp-block-navigation__responsive-container-close" %13$s>%9$s</button>
|
||||
<div class="wp-block-navigation__responsive-container-content" id="%1$s-content">
|
||||
%2$s
|
||||
</div>
|
||||
|
@ -741,7 +755,6 @@ function render_block_core_navigation( $attributes, $content, $block ) {
|
|||
esc_attr( implode( ' ', $responsive_container_classes ) ),
|
||||
esc_attr( implode( ' ', $open_button_classes ) ),
|
||||
esc_attr( safecss_filter_attr( $colors['overlay_inline_styles'] ) ),
|
||||
__( 'Menu' ),
|
||||
$toggle_button_content,
|
||||
$toggle_close_button_content,
|
||||
$open_button_directives,
|
||||
|
|
|
@ -1 +1 @@
|
|||
<?php return array('dependencies' => array(), 'version' => 'efa7b39e8a2ac7d3f83a');
|
||||
<?php return array('dependencies' => array(), 'version' => '90985864bc4f9b55787d');
|
||||
|
|
|
@ -87,6 +87,13 @@ const closeMenu = (store, menuClosedOn) => {
|
|||
} = store;
|
||||
return context.core.navigation.type === 'overlay' && selectors.core.navigation.isMenuOpen(store) ? 'true' : null;
|
||||
},
|
||||
ariaLabel: store => {
|
||||
const {
|
||||
context,
|
||||
selectors
|
||||
} = store;
|
||||
return context.core.navigation.type === 'overlay' && selectors.core.navigation.isMenuOpen(store) ? context.core.navigation.ariaLabel : null;
|
||||
},
|
||||
isMenuOpen: ({
|
||||
context
|
||||
}) =>
|
||||
|
|
|
@ -1 +1 @@
|
|||
<?php return array('dependencies' => array(), 'version' => 'dde7635cad8b0819b900');
|
||||
<?php return array('dependencies' => array(), 'version' => 'a5ffa1bdbe6aee7a5c54');
|
||||
|
|
|
@ -1 +1 @@
|
|||
"use strict";(self.__WordPressPrivateInteractivityAPI__=self.__WordPressPrivateInteractivityAPI__||[]).push([[3],{932:function(e,n,o){var t=o(754);const i=["a[href]",'input:not([disabled]):not([type="hidden"]):not([aria-hidden])',"select:not([disabled]):not([aria-hidden])","textarea:not([disabled]):not([aria-hidden])","button:not([disabled]):not([aria-hidden])","[contenteditable]",'[tabindex]:not([tabindex^="-"])'],a=(e,n)=>{const{context:o,ref:t,selectors:i}=e;i.core.navigation.menuOpenedBy(e)[n]=!0,o.core.navigation.previousFocus=t,"overlay"===o.core.navigation.type&&document.documentElement.classList.add("has-modal-open")},c=(e,n)=>{const{context:o,selectors:t}=e;t.core.navigation.menuOpenedBy(e)[n]=!1,t.core.navigation.isMenuOpen(e)||(o.core.navigation.modal?.contains(window.document.activeElement)&&o.core.navigation.previousFocus.focus(),o.core.navigation.modal=null,o.core.navigation.previousFocus=null,"overlay"===o.core.navigation.type&&document.documentElement.classList.remove("has-modal-open"))};(0,t.h)({effects:{core:{navigation:{initMenu:e=>{const{context:n,selectors:o,ref:t}=e;if(o.core.navigation.isMenuOpen(e)){const e=t.querySelectorAll(i);n.core.navigation.modal=t,n.core.navigation.firstFocusableElement=e[0],n.core.navigation.lastFocusableElement=e[e.length-1]}},focusFirstElement:e=>{const{selectors:n,ref:o}=e;n.core.navigation.isMenuOpen(e)&&o.querySelector(".wp-block-navigation-item > *:first-child").focus()}}}},selectors:{core:{navigation:{roleAttribute:e=>{const{context:n,selectors:o}=e;return"overlay"===n.core.navigation.type&&o.core.navigation.isMenuOpen(e)?"dialog":null},ariaModal:e=>{const{context:n,selectors:o}=e;return"overlay"===n.core.navigation.type&&o.core.navigation.isMenuOpen(e)?"true":null},isMenuOpen:({context:e})=>Object.values(e.core.navigation["overlay"===e.core.navigation.type?"overlayOpenedBy":"submenuOpenedBy"]).filter(Boolean).length>0,menuOpenedBy:({context:e})=>e.core.navigation["overlay"===e.core.navigation.type?"overlayOpenedBy":"submenuOpenedBy"]}}},actions:{core:{navigation:{openMenuOnHover(e){const{navigation:n}=e.context.core;"submenu"===n.type&&0===Object.values(n.overlayOpenedBy||{}).filter(Boolean).length&&a(e,"hover")},closeMenuOnHover(e){c(e,"hover")},openMenuOnClick(e){a(e,"click")},closeMenuOnClick(e){c(e,"click"),c(e,"focus")},openMenuOnFocus(e){a(e,"focus")},toggleMenuOnClick:e=>{const{selectors:n}=e,o=n.core.navigation.menuOpenedBy(e);o.click||o.focus?(c(e,"click"),c(e,"focus")):a(e,"click")},handleMenuKeydown:e=>{const{context:n,selectors:o,event:t}=e;if(o.core.navigation.menuOpenedBy(e).click){if("Escape"===t?.key)return c(e,"click"),void c(e,"focus");"overlay"===n.core.navigation.type&&"Tab"===t.key&&(t.shiftKey&&window.document.activeElement===n.core.navigation.firstFocusableElement?(t.preventDefault(),n.core.navigation.lastFocusableElement.focus()):t.shiftKey||window.document.activeElement!==n.core.navigation.lastFocusableElement||(t.preventDefault(),n.core.navigation.firstFocusableElement.focus()))}},handleMenuFocusout:e=>{const{context:n,event:o}=e;n.core.navigation.modal?.contains(o.relatedTarget)||o.target===window.document.activeElement||(c(e,"click"),c(e,"focus"))}}}}})}},function(e){var n;n=932,e(e.s=n)}]);
|
||||
"use strict";(self.__WordPressPrivateInteractivityAPI__=self.__WordPressPrivateInteractivityAPI__||[]).push([[3],{932:function(e,n,o){var t=o(754);const a=["a[href]",'input:not([disabled]):not([type="hidden"]):not([aria-hidden])',"select:not([disabled]):not([aria-hidden])","textarea:not([disabled]):not([aria-hidden])","button:not([disabled]):not([aria-hidden])","[contenteditable]",'[tabindex]:not([tabindex^="-"])'],i=(e,n)=>{const{context:o,ref:t,selectors:a}=e;a.core.navigation.menuOpenedBy(e)[n]=!0,o.core.navigation.previousFocus=t,"overlay"===o.core.navigation.type&&document.documentElement.classList.add("has-modal-open")},c=(e,n)=>{const{context:o,selectors:t}=e;t.core.navigation.menuOpenedBy(e)[n]=!1,t.core.navigation.isMenuOpen(e)||(o.core.navigation.modal?.contains(window.document.activeElement)&&o.core.navigation.previousFocus.focus(),o.core.navigation.modal=null,o.core.navigation.previousFocus=null,"overlay"===o.core.navigation.type&&document.documentElement.classList.remove("has-modal-open"))};(0,t.h)({effects:{core:{navigation:{initMenu:e=>{const{context:n,selectors:o,ref:t}=e;if(o.core.navigation.isMenuOpen(e)){const e=t.querySelectorAll(a);n.core.navigation.modal=t,n.core.navigation.firstFocusableElement=e[0],n.core.navigation.lastFocusableElement=e[e.length-1]}},focusFirstElement:e=>{const{selectors:n,ref:o}=e;n.core.navigation.isMenuOpen(e)&&o.querySelector(".wp-block-navigation-item > *:first-child").focus()}}}},selectors:{core:{navigation:{roleAttribute:e=>{const{context:n,selectors:o}=e;return"overlay"===n.core.navigation.type&&o.core.navigation.isMenuOpen(e)?"dialog":null},ariaModal:e=>{const{context:n,selectors:o}=e;return"overlay"===n.core.navigation.type&&o.core.navigation.isMenuOpen(e)?"true":null},ariaLabel:e=>{const{context:n,selectors:o}=e;return"overlay"===n.core.navigation.type&&o.core.navigation.isMenuOpen(e)?n.core.navigation.ariaLabel:null},isMenuOpen:({context:e})=>Object.values(e.core.navigation["overlay"===e.core.navigation.type?"overlayOpenedBy":"submenuOpenedBy"]).filter(Boolean).length>0,menuOpenedBy:({context:e})=>e.core.navigation["overlay"===e.core.navigation.type?"overlayOpenedBy":"submenuOpenedBy"]}}},actions:{core:{navigation:{openMenuOnHover(e){const{navigation:n}=e.context.core;"submenu"===n.type&&0===Object.values(n.overlayOpenedBy||{}).filter(Boolean).length&&i(e,"hover")},closeMenuOnHover(e){c(e,"hover")},openMenuOnClick(e){i(e,"click")},closeMenuOnClick(e){c(e,"click"),c(e,"focus")},openMenuOnFocus(e){i(e,"focus")},toggleMenuOnClick:e=>{const{selectors:n}=e,o=n.core.navigation.menuOpenedBy(e);o.click||o.focus?(c(e,"click"),c(e,"focus")):i(e,"click")},handleMenuKeydown:e=>{const{context:n,selectors:o,event:t}=e;if(o.core.navigation.menuOpenedBy(e).click){if("Escape"===t?.key)return c(e,"click"),void c(e,"focus");"overlay"===n.core.navigation.type&&"Tab"===t.key&&(t.shiftKey&&window.document.activeElement===n.core.navigation.firstFocusableElement?(t.preventDefault(),n.core.navigation.lastFocusableElement.focus()):t.shiftKey||window.document.activeElement!==n.core.navigation.lastFocusableElement||(t.preventDefault(),n.core.navigation.firstFocusableElement.focus()))}},handleMenuFocusout:e=>{const{context:n,event:o}=e;n.core.navigation.modal?.contains(o.relatedTarget)||o.target===window.document.activeElement||(c(e,"click"),c(e,"focus"))}}}}})}},function(e){var n;n=932,e(e.s=n)}]);
|
|
@ -34,7 +34,8 @@ function render_block_core_query( $attributes, $content, $block ) {
|
|||
'loadedText' => __( 'Page Loaded.' ),
|
||||
),
|
||||
),
|
||||
)
|
||||
),
|
||||
JSON_HEX_TAG | JSON_HEX_APOS | JSON_HEX_AMP
|
||||
)
|
||||
);
|
||||
$content = $p->get_updated_html();
|
||||
|
|
|
@ -1018,6 +1018,7 @@
|
|||
|
||||
.block-editor-block-switcher__preview__popover{
|
||||
display:none;
|
||||
overflow:hidden;
|
||||
}
|
||||
.block-editor-block-switcher__preview__popover.components-popover{
|
||||
margin-top:11px;
|
||||
|
@ -1033,6 +1034,7 @@
|
|||
border-radius:2px;
|
||||
box-shadow:none;
|
||||
outline:none;
|
||||
overflow:auto;
|
||||
width:300px;
|
||||
}
|
||||
.block-editor-block-switcher__preview__popover .block-editor-block-switcher__preview{
|
||||
|
@ -1041,6 +1043,9 @@
|
|||
overflow:hidden;
|
||||
padding:0 16px;
|
||||
}
|
||||
.block-editor-block-switcher__preview__popover .block-editor-block-switcher__preview.is-pattern-list-preview{
|
||||
overflow:unset;
|
||||
}
|
||||
|
||||
.block-editor-block-switcher__preview-title{
|
||||
color:#757575;
|
||||
|
|
File diff suppressed because one or more lines are too long
|
@ -1018,6 +1018,7 @@
|
|||
|
||||
.block-editor-block-switcher__preview__popover{
|
||||
display:none;
|
||||
overflow:hidden;
|
||||
}
|
||||
.block-editor-block-switcher__preview__popover.components-popover{
|
||||
margin-top:11px;
|
||||
|
@ -1033,6 +1034,7 @@
|
|||
border-radius:2px;
|
||||
box-shadow:none;
|
||||
outline:none;
|
||||
overflow:auto;
|
||||
width:300px;
|
||||
}
|
||||
.block-editor-block-switcher__preview__popover .block-editor-block-switcher__preview{
|
||||
|
@ -1041,6 +1043,9 @@
|
|||
overflow:hidden;
|
||||
padding:0 16px;
|
||||
}
|
||||
.block-editor-block-switcher__preview__popover .block-editor-block-switcher__preview.is-pattern-list-preview{
|
||||
overflow:unset;
|
||||
}
|
||||
|
||||
.block-editor-block-switcher__preview-title{
|
||||
color:#757575;
|
||||
|
|
File diff suppressed because one or more lines are too long
|
@ -3082,6 +3082,11 @@ body.is-fullscreen-mode .edit-site .components-editor-notices__snackbar{
|
|||
flex-shrink:0;
|
||||
}
|
||||
|
||||
@media (min-width:782px){
|
||||
.edit-site-sidebar-navigation-screen__content .edit-site-global-styles-style-variations-container{
|
||||
max-width:292px;
|
||||
}
|
||||
}
|
||||
.edit-site-sidebar-navigation-screen__content .edit-site-global-styles-style-variations-container .edit-site-global-styles-variations_item-preview{
|
||||
border:1px solid #1e1e1e;
|
||||
}
|
||||
|
|
File diff suppressed because one or more lines are too long
|
@ -3082,6 +3082,11 @@ body.is-fullscreen-mode .edit-site .components-editor-notices__snackbar{
|
|||
flex-shrink:0;
|
||||
}
|
||||
|
||||
@media (min-width:782px){
|
||||
.edit-site-sidebar-navigation-screen__content .edit-site-global-styles-style-variations-container{
|
||||
max-width:292px;
|
||||
}
|
||||
}
|
||||
.edit-site-sidebar-navigation-screen__content .edit-site-global-styles-style-variations-container .edit-site-global-styles-variations_item-preview{
|
||||
border:1px solid #1e1e1e;
|
||||
}
|
||||
|
|
File diff suppressed because one or more lines are too long
|
@ -58490,10 +58490,8 @@ function PreviewPatternsPopover({
|
|||
className: "block-editor-block-switcher__preview__popover",
|
||||
position: "bottom right"
|
||||
}, (0,external_wp_element_namespaceObject.createElement)("div", {
|
||||
className: "block-editor-block-switcher__preview"
|
||||
}, (0,external_wp_element_namespaceObject.createElement)("div", {
|
||||
className: "block-editor-block-switcher__preview-title"
|
||||
}, (0,external_wp_i18n_namespaceObject.__)('Preview')), (0,external_wp_element_namespaceObject.createElement)(BlockPatternsList, {
|
||||
className: "block-editor-block-switcher__preview is-pattern-list-preview"
|
||||
}, (0,external_wp_element_namespaceObject.createElement)(BlockPatternsList, {
|
||||
patterns: patterns,
|
||||
onSelect: onSelect
|
||||
})))));
|
||||
|
|
File diff suppressed because one or more lines are too long
|
@ -25959,8 +25959,8 @@ function LatestPostsEdit({
|
|||
}
|
||||
});
|
||||
const needsReadMore = excerptLength < excerpt.trim().split(' ').length && post.excerpt.raw === '';
|
||||
const postExcerpt = needsReadMore ? (0,external_wp_element_namespaceObject.createElement)(external_wp_element_namespaceObject.Fragment, null, excerpt.trim().split(' ', excerptLength).join(' '), (0,external_wp_element_namespaceObject.createInterpolateElement)((0,external_wp_i18n_namespaceObject.sprintf)( /* translators: 1: The static string "Read more", 2: The post title only visible to screen readers. */
|
||||
(0,external_wp_i18n_namespaceObject.__)('… <a>%1$s<span>: %2$s</span></a>'), (0,external_wp_i18n_namespaceObject.__)('Read more'), titleTrimmed || (0,external_wp_i18n_namespaceObject.__)('(no title)')), {
|
||||
const postExcerpt = needsReadMore ? (0,external_wp_element_namespaceObject.createElement)(external_wp_element_namespaceObject.Fragment, null, excerpt.trim().split(' ', excerptLength).join(' '), (0,external_wp_element_namespaceObject.createInterpolateElement)((0,external_wp_i18n_namespaceObject.sprintf)( /* translators: 1: Hidden accessibility text: Post title */
|
||||
(0,external_wp_i18n_namespaceObject.__)('… <a>Read more<span>: %1$s</span></a>'), titleTrimmed || (0,external_wp_i18n_namespaceObject.__)('(no title)')), {
|
||||
a:
|
||||
// eslint-disable-next-line jsx-a11y/anchor-has-content
|
||||
(0,external_wp_element_namespaceObject.createElement)("a", {
|
||||
|
@ -33013,7 +33013,6 @@ function Navigation({
|
|||
}), (0,external_wp_element_namespaceObject.createElement)(ResponsiveWrapper, {
|
||||
id: clientId,
|
||||
onToggle: setResponsiveMenuVisibility,
|
||||
label: (0,external_wp_i18n_namespaceObject.__)('Menu'),
|
||||
hasIcon: hasIcon,
|
||||
icon: icon,
|
||||
isOpen: isResponsiveMenuOpen,
|
||||
|
|
File diff suppressed because one or more lines are too long
|
@ -14815,6 +14815,31 @@ function headRemover(node) {
|
|||
node.parentNode.removeChild(node);
|
||||
}
|
||||
|
||||
;// CONCATENATED MODULE: ./node_modules/@wordpress/blocks/build-module/api/raw-handling/ms-list-ignore.js
|
||||
/**
|
||||
* Looks for comments, and removes them.
|
||||
*
|
||||
* @param {Node} node The node to be processed.
|
||||
* @return {void}
|
||||
*/
|
||||
function msListIgnore(node) {
|
||||
if (node.nodeType !== node.ELEMENT_NODE) {
|
||||
return;
|
||||
}
|
||||
const style = node.getAttribute('style');
|
||||
if (!style || !style.includes('mso-list')) {
|
||||
return;
|
||||
}
|
||||
const rules = style.split(';').reduce((acc, rule) => {
|
||||
const [key, value] = rule.split(':');
|
||||
acc[key.trim().toLowerCase()] = value.trim().toLowerCase();
|
||||
return acc;
|
||||
}, {});
|
||||
if (rules['mso-list'] === 'ignore') {
|
||||
node.remove();
|
||||
}
|
||||
}
|
||||
|
||||
;// CONCATENATED MODULE: ./node_modules/@wordpress/blocks/build-module/api/raw-handling/ms-list-converter.js
|
||||
/**
|
||||
* Browser dependencies
|
||||
|
@ -14822,6 +14847,12 @@ function headRemover(node) {
|
|||
const {
|
||||
parseInt: ms_list_converter_parseInt
|
||||
} = window;
|
||||
|
||||
/**
|
||||
* Internal dependencies
|
||||
*/
|
||||
|
||||
|
||||
function ms_list_converter_isList(node) {
|
||||
return node.nodeName === 'OL' || node.nodeName === 'UL';
|
||||
}
|
||||
|
@ -14830,19 +14861,9 @@ function msListConverter(node, doc) {
|
|||
return;
|
||||
}
|
||||
const style = node.getAttribute('style');
|
||||
if (!style) {
|
||||
if (!style || !style.includes('mso-list')) {
|
||||
return;
|
||||
}
|
||||
|
||||
// Quick check.
|
||||
if (style.indexOf('mso-list') === -1) {
|
||||
return;
|
||||
}
|
||||
const matches = /mso-list\s*:[^;]+level([0-9]+)/i.exec(style);
|
||||
if (!matches) {
|
||||
return;
|
||||
}
|
||||
let level = ms_list_converter_parseInt(matches[1], 10) - 1 || 0;
|
||||
const prevNode = node.previousElementSibling;
|
||||
|
||||
// Add new list if no previous.
|
||||
|
@ -14861,13 +14882,10 @@ function msListConverter(node, doc) {
|
|||
const listItem = doc.createElement('li');
|
||||
let receivingNode = listNode;
|
||||
|
||||
// Remove the first span with list info.
|
||||
node.removeChild(node.firstChild);
|
||||
|
||||
// Add content.
|
||||
while (node.firstChild) {
|
||||
listItem.appendChild(node.firstChild);
|
||||
}
|
||||
listItem.innerHTML = deepFilterHTML(node.innerHTML, [msListIgnore]);
|
||||
const matches = /mso-list\s*:[^;]+level([0-9]+)/i.exec(style);
|
||||
let level = matches ? ms_list_converter_parseInt(matches[1], 10) - 1 || 0 : 0;
|
||||
|
||||
// Change pointer depending on indentation level.
|
||||
while (level--) {
|
||||
|
@ -15202,6 +15220,7 @@ function slackParagraphCorrector(node) {
|
|||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/**
|
||||
|
@ -15220,7 +15239,7 @@ const {
|
|||
* @return {string} HTML only containing phrasing content.
|
||||
*/
|
||||
function filterInlineHTML(HTML, preserveWhiteSpace) {
|
||||
HTML = deepFilterHTML(HTML, [headRemover, googleDocsUIdRemover, phrasingContentReducer, commentRemover]);
|
||||
HTML = deepFilterHTML(HTML, [headRemover, googleDocsUIdRemover, msListIgnore, phrasingContentReducer, commentRemover]);
|
||||
HTML = (0,external_wp_dom_namespaceObject.removeInvalidHTML)(HTML, (0,external_wp_dom_namespaceObject.getPhrasingContentSchema)('paste'), {
|
||||
inline: true
|
||||
});
|
||||
|
|
File diff suppressed because one or more lines are too long
|
@ -16,7 +16,7 @@
|
|||
*
|
||||
* @global string $wp_version
|
||||
*/
|
||||
$wp_version = '6.4-beta2-56815';
|
||||
$wp_version = '6.4-beta2-56816';
|
||||
|
||||
/**
|
||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||
|
|
Loading…
Reference in New Issue