From 7e5549add3e39993cada83c8610d3f0cf8cbce97 Mon Sep 17 00:00:00 2001 From: George Mamadashvili Date: Mon, 19 Oct 2026 14:04:21 +0100 Subject: [PATCH] General: Bump the pinned hash for Gutenberg to `7b95ee9`. This updates the pinned commit hash of the Gutenberg repository from `954fe7f9e04631c41aec4552acd627a7203a2aad` (version `24.1.0`) to `7b95ee96b54de2e35886971ccf7eb449c324c830` (version `24.2.0`). A full list of changes included in this commit can be found on GitHub: https://github.com/WordPress/gutenberg/compare/954fe7f9e04631c41aec4552acd627a7203a2aad...7b95ee96b54de2e35886971ccf7eb449c324c830. Gutenberg 24.2 no longer builds `wp-includes/js/dist/sync.js` or its minified counterpart, so both are added to `$_old_files` to be removed on upgrade. They were listed under 7.0.2 and restored in 7.1. See #66340. --- package.json | 2 +- src/wp-admin/includes/update-core.php | 3 + .../assets/icon-library-manifest.php | 9 + .../assets/script-loader-packages.php | 68 +- .../assets/script-modules-packages.php | 44 +- .../blocks/accordion-heading/block.json | 1 + src/wp-includes/blocks/archives/block.json | 3 + src/wp-includes/blocks/avatar.php | 8 +- src/wp-includes/blocks/avatar/block.json | 4 + src/wp-includes/blocks/blocks-json.php | 282 +- src/wp-includes/blocks/breadcrumbs.php | 2 +- src/wp-includes/blocks/button.php | 47 + src/wp-includes/blocks/button/block.json | 6 + src/wp-includes/blocks/buttons/block.json | 7 +- src/wp-includes/blocks/code/block.json | 4 + src/wp-includes/blocks/columns/block.json | 4 + .../blocks/comments-pagination/block.json | 11 + src/wp-includes/blocks/cover.php | 59 +- src/wp-includes/blocks/cover/block.json | 3 +- src/wp-includes/blocks/details/block.json | 3 + src/wp-includes/blocks/embed/block.json | 7 +- src/wp-includes/blocks/file/block.json | 5 + src/wp-includes/blocks/footnotes/block.json | 4 + src/wp-includes/blocks/gallery/block.json | 13 + src/wp-includes/blocks/heading/block.json | 5 + src/wp-includes/blocks/home-link/block.json | 12 + src/wp-includes/blocks/icon.php | 2 +- src/wp-includes/blocks/image.php | 7 +- .../blocks/latest-comments/block.json | 10 + .../blocks/latest-posts/block.json | 4 + src/wp-includes/blocks/list-item/block.json | 9 +- src/wp-includes/blocks/list/block.json | 13 +- src/wp-includes/blocks/loginout/block.json | 4 + src/wp-includes/blocks/math/block.json | 4 + src/wp-includes/blocks/media-text/block.json | 18 + src/wp-includes/blocks/page-list/block.json | 4 + src/wp-includes/blocks/paragraph/block.json | 1 + .../blocks/post-author-biography/block.json | 1 + .../blocks/post-comments-form/block.json | 5 + .../blocks/post-content/block.json | 3 +- .../blocks/post-excerpt/block.json | 4 + .../blocks/post-featured-image/block.json | 1 + src/wp-includes/blocks/post-terms/block.json | 4 + .../blocks/post-time-to-read/block.json | 4 + src/wp-includes/blocks/post-title/block.json | 4 + .../blocks/preformatted/block.json | 4 + src/wp-includes/blocks/pullquote/block.json | 3 +- .../blocks/query-no-results/block.json | 4 + .../blocks/query-pagination/block.json | 17 + src/wp-includes/blocks/query-total/block.json | 4 + src/wp-includes/blocks/quote/block.json | 2 + src/wp-includes/blocks/read-more/block.json | 5 + src/wp-includes/blocks/rss/block.json | 4 + src/wp-includes/blocks/search/block.json | 3 +- .../blocks/site-tagline/block.json | 4 + src/wp-includes/blocks/site-title/block.json | 4 + .../blocks/social-links/block.json | 1 + src/wp-includes/blocks/tab-list/block.json | 4 + src/wp-includes/blocks/tab-panels/block.json | 3 + src/wp-includes/blocks/tabs/block.json | 3 + src/wp-includes/blocks/template-part.php | 19 +- src/wp-includes/blocks/term-count/block.json | 5 + .../blocks/term-description/block.json | 4 + src/wp-includes/blocks/term-name/block.json | 7 +- .../blocks/term-template/block.json | 4 + src/wp-includes/blocks/verse/block.json | 4 + src/wp-includes/blocks/video/block.json | 8 +- src/wp-includes/build/constants.php | 2 +- .../build/routes/connectors-home/content.js | 661 +- .../connectors-home/content.min.asset.php | 2 +- .../routes/connectors-home/content.min.js | 2 +- .../build/routes/font-list/content.js | 13542 +++++++++++++--- .../routes/font-list/content.min.asset.php | 2 +- .../build/routes/font-list/content.min.js | 14 +- .../images/icon-library/arrow-down-left.svg | 2 +- .../images/icon-library/arrow-down-right.svg | 2 +- .../images/icon-library/arrow-down.svg | 2 +- .../images/icon-library/arrow-left.svg | 2 +- .../images/icon-library/arrow-right.svg | 2 +- .../images/icon-library/arrow-up-left.svg | 2 +- .../images/icon-library/arrow-up-right.svg | 2 +- .../images/icon-library/arrow-up.svg | 2 +- .../images/icon-library/at-symbol.svg | 2 +- src/wp-includes/images/icon-library/audio.svg | 2 +- src/wp-includes/images/icon-library/bell.svg | 4 +- .../images/icon-library/block-default.svg | 3 +- .../images/icon-library/block-meta.svg | 2 +- .../images/icon-library/block-table.svg | 2 +- src/wp-includes/images/icon-library/brush.svg | 2 +- .../images/icon-library/calendar.svg | 4 +- .../images/icon-library/capture-photo.svg | 4 +- .../images/icon-library/capture-video.svg | 4 +- src/wp-includes/images/icon-library/cart.svg | 6 +- .../images/icon-library/category.svg | 8 +- .../images/icon-library/caution.svg | 2 +- .../images/icon-library/chart-bar.svg | 2 +- src/wp-includes/images/icon-library/check.svg | 2 +- .../icon-library/chevron-down-small.svg | 2 +- .../images/icon-library/chevron-down.svg | 2 +- .../icon-library/chevron-left-small.svg | 2 +- .../images/icon-library/chevron-left.svg | 2 +- .../icon-library/chevron-right-small.svg | 2 +- .../images/icon-library/chevron-right.svg | 2 +- .../images/icon-library/chevron-up-down.svg | 2 +- .../images/icon-library/chevron-up-small.svg | 2 +- .../images/icon-library/chevron-up.svg | 2 +- .../images/icon-library/comment.svg | 2 +- src/wp-includes/images/icon-library/cover.svg | 2 +- .../images/icon-library/create.svg | 2 +- .../images/icon-library/dashboard.svg | 2 +- .../images/icon-library/desktop.svg | 2 +- .../images/icon-library/download.svg | 2 +- .../images/icon-library/drawer-left.svg | 2 +- .../images/icon-library/drawer-right.svg | 2 +- .../images/icon-library/envelope.svg | 2 +- src/wp-includes/images/icon-library/error.svg | 2 +- .../images/icon-library/external.svg | 2 +- src/wp-includes/images/icon-library/file.svg | 2 +- .../images/icon-library/gallery.svg | 4 +- src/wp-includes/images/icon-library/group.svg | 4 +- .../images/icon-library/heading.svg | 2 +- src/wp-includes/images/icon-library/help.svg | 4 +- src/wp-includes/images/icon-library/home.svg | 2 +- src/wp-includes/images/icon-library/image.svg | 2 +- src/wp-includes/images/icon-library/info.svg | 2 +- src/wp-includes/images/icon-library/key.svg | 2 +- .../images/icon-library/language.svg | 4 +- src/wp-includes/images/icon-library/link.svg | 2 +- .../images/icon-library/map-marker.svg | 2 +- src/wp-includes/images/icon-library/media.svg | 12 +- src/wp-includes/images/icon-library/menu.svg | 2 +- .../images/icon-library/mobile.svg | 2 +- .../images/icon-library/more-horizontal.svg | 6 +- .../images/icon-library/more-vertical.svg | 6 +- src/wp-includes/images/icon-library/next.svg | 2 +- src/wp-includes/images/icon-library/page.svg | 2 +- .../images/icon-library/paragraph.svg | 4 +- .../images/icon-library/payment.svg | 4 +- .../images/icon-library/pencil.svg | 4 +- .../images/icon-library/people.svg | 2 +- src/wp-includes/images/icon-library/pin.svg | 2 +- .../images/icon-library/plugins.svg | 2 +- .../images/icon-library/plus-circle.svg | 4 +- src/wp-includes/images/icon-library/plus.svg | 2 +- .../images/icon-library/previous.svg | 2 +- .../images/icon-library/published.svg | 4 +- src/wp-includes/images/icon-library/quote.svg | 2 +- .../images/icon-library/receipt.svg | 2 +- src/wp-includes/images/icon-library/rss.svg | 4 +- .../images/icon-library/scheduled.svg | 4 +- .../images/icon-library/search.svg | 2 +- .../images/icon-library/settings.svg | 2 +- .../images/icon-library/shadow.svg | 2 +- src/wp-includes/images/icon-library/share.svg | 2 +- .../images/icon-library/shield.svg | 2 +- .../images/icon-library/shuffle.svg | 2 +- src/wp-includes/images/icon-library/sites.svg | 6 +- .../images/icon-library/star-empty.svg | 2 +- .../images/icon-library/star-filled.svg | 2 +- .../images/icon-library/star-half.svg | 2 +- src/wp-includes/images/icon-library/store.svg | 2 +- .../images/icon-library/styles.svg | 2 +- .../images/icon-library/symbol-filled.svg | 4 +- .../images/icon-library/symbol.svg | 4 +- src/wp-includes/images/icon-library/table.svg | 2 +- .../images/icon-library/tablet.svg | 2 +- src/wp-includes/images/icon-library/tag.svg | 2 +- src/wp-includes/images/icon-library/tip.svg | 2 +- src/wp-includes/images/icon-library/tool.svg | 2 +- .../images/icon-library/update.svg | 2 +- .../images/icon-library/upload.svg | 2 +- src/wp-includes/images/icon-library/verse.svg | 6 +- 172 files changed, 12087 insertions(+), 3239 deletions(-) diff --git a/package.json b/package.json index eb165bda5b0f0..2881c5f3715c1 100644 --- a/package.json +++ b/package.json @@ -7,7 +7,7 @@ "url": "https://develop.svn.wordpress.org/trunk" }, "gutenberg": { - "sha": "954fe7f9e04631c41aec4552acd627a7203a2aad", + "sha": "7b95ee96b54de2e35886971ccf7eb449c324c830", "ghcrRepo": "WordPress/gutenberg/gutenberg-wp-develop-build" }, "engines": { diff --git a/src/wp-admin/includes/update-core.php b/src/wp-admin/includes/update-core.php index 7d625150110f1..4b91dca2b183a 100644 --- a/src/wp-admin/includes/update-core.php +++ b/src/wp-admin/includes/update-core.php @@ -1170,6 +1170,9 @@ * 'wp-includes/images/icon-library/update.svg', * 'wp-includes/images/icon-library/wordpress.svg', */ + // 7.2 + 'wp-includes/js/dist/sync.js', + 'wp-includes/js/dist/sync.min.js', ); /** diff --git a/src/wp-includes/assets/icon-library-manifest.php b/src/wp-includes/assets/icon-library-manifest.php index 6af5b7d421051..c4bbc83af2b5b 100644 --- a/src/wp-includes/assets/icon-library-manifest.php +++ b/src/wp-includes/assets/icon-library-manifest.php @@ -49,11 +49,13 @@ 'label' => _x( 'At Symbol (@)', 'icon label' ), 'filePath' => 'at-symbol.svg', 'collections' => array( 'core' ), + 'keywords' => array( _x( 'email', 'icon keyword' ) ), ), 'audio' => array( 'label' => _x( 'Audio', 'icon label' ), 'filePath' => 'audio.svg', 'collections' => array( 'core' ), + 'keywords' => array( _x( 'music', 'icon keyword' ), _x( 'note', 'icon keyword' ) ), ), 'bell' => array( 'label' => _x( 'Bell', 'icon label' ), @@ -109,6 +111,7 @@ 'label' => _x( 'Caution', 'icon label' ), 'filePath' => 'caution.svg', 'collections' => array( 'core' ), + 'keywords' => array( _x( 'alert', 'icon keyword' ), _x( 'exclamation', 'icon keyword' ), _x( 'warning', 'icon keyword' ) ), ), 'chart-bar' => array( 'label' => _x( 'Chart Bar', 'icon label' ), @@ -179,6 +182,7 @@ 'label' => _x( 'Create', 'icon label' ), 'filePath' => 'create.svg', 'collections' => array( 'core' ), + 'keywords' => array( _x( 'add', 'icon keyword' ), _x( 'new', 'icon keyword' ), _x( 'plus', 'icon keyword' ) ), ), 'dashboard' => array( 'label' => _x( 'Dashboard', 'icon label' ), @@ -209,11 +213,13 @@ 'label' => _x( 'Envelope', 'icon label' ), 'filePath' => 'envelope.svg', 'collections' => array( 'core' ), + 'keywords' => array( _x( 'email', 'icon keyword' ), _x( 'letter', 'icon keyword' ), _x( 'post', 'icon keyword' ) ), ), 'error' => array( 'label' => _x( 'Error', 'icon label' ), 'filePath' => 'error.svg', 'collections' => array( 'core' ), + 'keywords' => array( _x( 'alert', 'icon keyword' ), _x( 'caution', 'icon keyword' ), _x( 'exclamation', 'icon keyword' ), _x( 'warning', 'icon keyword' ) ), ), 'external' => array( 'label' => _x( 'External', 'icon label' ), @@ -224,6 +230,7 @@ 'label' => _x( 'File', 'icon label' ), 'filePath' => 'file.svg', 'collections' => array( 'core' ), + 'keywords' => array( _x( 'archive', 'icon keyword' ), _x( 'document', 'icon keyword' ), _x( 'folder', 'icon keyword' ) ), ), 'gallery' => array( 'label' => _x( 'Gallery', 'icon label' ), @@ -329,6 +336,7 @@ 'label' => _x( 'Pencil', 'icon label' ), 'filePath' => 'pencil.svg', 'collections' => array( 'core', 'core-admin' ), + 'keywords' => array( _x( 'edit', 'icon keyword' ) ), ), 'people' => array( 'label' => _x( 'People', 'icon label' ), @@ -429,6 +437,7 @@ 'label' => _x( 'Star Filled', 'icon label' ), 'filePath' => 'star-filled.svg', 'collections' => array( 'core' ), + 'keywords' => array( _x( 'favorite', 'icon keyword' ) ), ), 'star-half' => array( 'label' => _x( 'Star Half', 'icon label' ), diff --git a/src/wp-includes/assets/script-loader-packages.php b/src/wp-includes/assets/script-loader-packages.php index 130c022842931..d25684f47cc98 100644 --- a/src/wp-includes/assets/script-loader-packages.php +++ b/src/wp-includes/assets/script-loader-packages.php @@ -4,7 +4,7 @@ 'wp-dom-ready', 'wp-i18n' ), - 'version' => '31c6cec5a4ff7aff483d' + 'version' => '5faef02d497f248e93ee' ), 'annotations.js' => array( 'dependencies' => array( @@ -67,7 +67,7 @@ 'wp-url', 'wp-warning' ), - 'version' => '56da94f1b6ed56573e78' + 'version' => '6d6b3181a753252387e7' ), 'block-editor.js' => array( 'dependencies' => array( @@ -105,7 +105,7 @@ 'wp-url', 'wp-warning' ), - 'version' => '578ad9eb61ae8af0123d' + 'version' => '6e282539cf0a135ed4a5' ), 'block-library.js' => array( 'dependencies' => array( @@ -151,7 +151,7 @@ 'import' => 'dynamic' ) ), - 'version' => '0999d15ea60b2ca101bc' + 'version' => '9442f80186e1fd6c9d4b' ), 'block-serialization-default-parser.js' => array( 'dependencies' => array( @@ -184,7 +184,7 @@ 'wp-shortcode', 'wp-warning' ), - 'version' => 'c453468c6e4fc4dacf25' + 'version' => '3a5d55524352cd1635f7' ), 'commands.js' => array( 'dependencies' => array( @@ -201,7 +201,7 @@ 'wp-primitives', 'wp-private-apis' ), - 'version' => '4a4a518ce9c4838666fe' + 'version' => '0f782aaf1624cdb1148e' ), 'components.js' => array( 'dependencies' => array( @@ -226,11 +226,10 @@ 'wp-theme', 'wp-warning' ), - 'version' => 'fecbc7a454bacff1527c' + 'version' => 'b719ac135662ae191dd9' ), 'compose.js' => array( 'dependencies' => array( - 'react', 'react-jsx-runtime', 'wp-deprecated', 'wp-dom', @@ -241,7 +240,7 @@ 'wp-private-apis', 'wp-undo-manager' ), - 'version' => '18547cd8d2e6674f7b98' + 'version' => '502412777bc436c79a5e' ), 'core-commands.js' => array( 'dependencies' => array( @@ -258,7 +257,7 @@ 'wp-router', 'wp-url' ), - 'version' => '738a4beca871c27833f1' + 'version' => '8839a8b3ea5cc4eb698e' ), 'core-data.js' => array( 'dependencies' => array( @@ -271,6 +270,7 @@ 'wp-data', 'wp-deprecated', 'wp-element', + 'wp-hooks', 'wp-html-entities', 'wp-i18n', 'wp-notices', @@ -278,12 +278,11 @@ 'wp-private-apis', 'wp-rich-text', 'wp-style-engine', - 'wp-sync', 'wp-undo-manager', 'wp-url', 'wp-warning' ), - 'version' => 'a1d74a5d3b46ac893e05' + 'version' => '85a2af40c63fbc42dfd4' ), 'customize-widgets.js' => array( 'dependencies' => array( @@ -319,7 +318,7 @@ 'import' => 'static' ) ), - 'version' => 'dcab974f036fbee73086' + 'version' => 'b8cdb457de36ea41f05c' ), 'data.js' => array( 'dependencies' => array( @@ -347,7 +346,7 @@ 'moment', 'wp-deprecated' ), - 'version' => '8173fc0fc12b7bb7eaf0' + 'version' => 'af0f72250d99230696c5' ), 'deprecated.js' => array( 'dependencies' => array( @@ -410,7 +409,7 @@ 'import' => 'static' ) ), - 'version' => 'b4b1fb53ee012caa42fb' + 'version' => '2c15b75d60d41653fe34' ), 'edit-site.js' => array( 'dependencies' => array( @@ -459,7 +458,7 @@ 'import' => 'static' ) ), - 'version' => '1d1116c276ed95618737' + 'version' => '8690337206dfcb4ce13d' ), 'edit-widgets.js' => array( 'dependencies' => array( @@ -501,7 +500,7 @@ 'import' => 'static' ) ), - 'version' => 'b66dc643708560ba6922' + 'version' => '09222c649dc37fa9ac75' ), 'editor.js' => array( 'dependencies' => array( @@ -552,7 +551,7 @@ 'import' => 'static' ) ), - 'version' => '021570d5ceb676201638' + 'version' => 'a4fe21d0704817acc70d' ), 'element.js' => array( 'dependencies' => array( @@ -560,7 +559,7 @@ 'react-dom', 'wp-escape-html' ), - 'version' => '4822427ad9c627826631' + 'version' => '5a4b1aa0e42aad8ef7db' ), 'escape-html.js' => array( 'dependencies' => array( @@ -594,7 +593,7 @@ 'import' => 'dynamic' ) ), - 'version' => 'f9ce39fe8a3d8aaf2fd6' + 'version' => '8a12998b72d8407956ee' ), 'hooks.js' => array( 'dependencies' => array( @@ -627,7 +626,7 @@ 'wp-element', 'wp-keycodes' ), - 'version' => 'ba3985e44a8fdca9462f' + 'version' => '2871b9b36c2a9aef74c4' ), 'keycodes.js' => array( 'dependencies' => array( @@ -662,6 +661,7 @@ 'wp-date', 'wp-deprecated', 'wp-element', + 'wp-html-entities', 'wp-i18n', 'wp-keycodes', 'wp-notices', @@ -672,7 +672,7 @@ 'wp-url', 'wp-warning' ), - 'version' => '64a4692e40e4685caccd' + 'version' => '688e248d5d924b36f889' ), 'notices.js' => array( 'dependencies' => array( @@ -711,7 +711,7 @@ 'wp-url', 'wp-warning' ), - 'version' => 'bb86130c876014c4db11' + 'version' => '6738120a1e2a12899699' ), 'plugins.js' => array( 'dependencies' => array( @@ -723,7 +723,7 @@ 'wp-is-shallow-equal', 'wp-primitives' ), - 'version' => 'a03a674fba0130981f2d' + 'version' => '4c53884fe0283a7ee4c5' ), 'preferences.js' => array( 'dependencies' => array( @@ -739,7 +739,7 @@ 'wp-primitives', 'wp-private-apis' ), - 'version' => 'f0a611a312173e6b7648' + 'version' => '00228fed7f2d274a78ab' ), 'preferences-persistence.js' => array( 'dependencies' => array( @@ -764,7 +764,7 @@ 'dependencies' => array( ), - 'version' => 'df3615fd5cb379fb7ffe' + 'version' => 'c12220e72e4bcdfac6f3' ), 'react-i18n.js' => array( 'dependencies' => array( @@ -824,7 +824,7 @@ 'wp-i18n', 'wp-url' ), - 'version' => '83e806a0634df6b93530' + 'version' => '3ddc6eaa634c653fb483' ), 'shortcode.js' => array( 'dependencies' => array( @@ -836,15 +836,7 @@ 'dependencies' => array( ), - 'version' => '914befb08774033e6265' - ), - 'sync.js' => array( - 'dependencies' => array( - 'wp-api-fetch', - 'wp-hooks', - 'wp-private-apis' - ), - 'version' => '7179e38284ff7aba21e6' + 'version' => '7d2c0a2a9e5ae3f8e1c9' ), 'theme.js' => array( 'dependencies' => array( @@ -854,7 +846,7 @@ 'wp-element', 'wp-private-apis' ), - 'version' => '795a74a11c336f95159b' + 'version' => '21b0c3318f26c7b3d71e' ), 'token-list.js' => array( 'dependencies' => array( @@ -926,7 +918,7 @@ 'wp-notices', 'wp-primitives' ), - 'version' => 'f2802a2d8ac37b86bc43' + 'version' => '27c5c0b8c8fcd1753149' ), 'wordcount.js' => array( 'dependencies' => array( diff --git a/src/wp-includes/assets/script-modules-packages.php b/src/wp-includes/assets/script-modules-packages.php index b000cd3d852b6..1cfd4f0882c86 100644 --- a/src/wp-includes/assets/script-modules-packages.php +++ b/src/wp-includes/assets/script-modules-packages.php @@ -3,14 +3,14 @@ 'dependencies' => array( ), - 'version' => 'f62f48906198ea8abc60' + 'version' => '4df772cdd295831820e3' ), 'abilities/index.js' => array( 'dependencies' => array( 'wp-data', 'wp-i18n' ), - 'version' => 'e5fcd7e304ead0fc9779' + 'version' => '9448bb3053516a39086d' ), 'block-editor/utils/fit-text-frontend.js' => array( 'dependencies' => array( @@ -36,6 +36,22 @@ ), 'version' => '6d4bb8df9c7539843ad3' ), + 'block-library/cover/view.js' => array( + 'dependencies' => array( + + ), + 'module_dependencies' => array( + array( + 'id' => '@wordpress/a11y', + 'import' => 'static' + ), + array( + 'id' => '@wordpress/interactivity', + 'import' => 'static' + ) + ), + 'version' => '205c83d309206ac7b189' + ), 'block-library/file/view.js' => array( 'dependencies' => array( @@ -58,7 +74,7 @@ 'import' => 'static' ) ), - 'version' => '25ee935fd6c67371d0f3' + 'version' => '22bef14632c3f4b4622a' ), 'block-library/navigation/view.js' => array( 'dependencies' => array( @@ -82,7 +98,7 @@ 'import' => 'static' ) ), - 'version' => 'fde7e3309a48521aed56' + 'version' => 'dcead465d87ec21eea99' ), 'block-library/query/view.js' => array( 'dependencies' => array( @@ -162,7 +178,7 @@ 'import' => 'static' ) ), - 'version' => 'f6c3c0c637fe0ed2dbd2' + 'version' => 'a31ac98fff5501742501' ), 'connectors/index.js' => array( 'dependencies' => array( @@ -219,13 +235,13 @@ 'import' => 'static' ) ), - 'version' => '9e49b9edcfc16dc5203c' + 'version' => '4b2e3230d57e16afb0ad' ), 'interactivity/index.js' => array( 'dependencies' => array( ), - 'version' => 'b0929e0bd08daccaa778' + 'version' => '2c5ac406b0272485700e' ), 'interactivity-router/full-page.js' => array( 'dependencies' => array( @@ -253,13 +269,13 @@ 'import' => 'static' ) ), - 'version' => '711aa380e66c57009b7a' + 'version' => '3ee11de34faed693e7a5' ), 'latex-to-mathml/index.js' => array( 'dependencies' => array( ), - 'version' => '662cb0e7f68d2a21cd68' + 'version' => '4ec5f96f5cf884f76516' ), 'latex-to-mathml/loader.js' => array( 'dependencies' => array( @@ -287,7 +303,7 @@ 'wp-private-apis', 'wp-style-engine' ), - 'version' => 'e50dce77f58e6e3ffa9b' + 'version' => '7fa38becb312ea2acafb' ), 'route/index.js' => array( 'dependencies' => array( @@ -314,7 +330,7 @@ 'dependencies' => array( ), - 'version' => '4d3627c45251ceb4f9a2' + 'version' => 'fa777d9ac60940d2e501' ), 'vips/loader.js' => array( 'dependencies' => array( @@ -332,14 +348,14 @@ 'dependencies' => array( ), - 'version' => '7e33cd8c4128731126e8' + 'version' => '41206bd52b7ae59d873a' ), 'widget-primitives/index.js' => array( 'dependencies' => array( 'react-jsx-runtime', 'wp-element' ), - 'version' => '3047de39283129372300' + 'version' => '355066e7b5d458a5968d' ), 'workflow/index.js' => array( 'dependencies' => array( @@ -372,6 +388,6 @@ 'import' => 'dynamic' ) ), - 'version' => '02fa947b818b1e4c07fd' + 'version' => '870e8ddb51af5d567758' ) ); \ No newline at end of file diff --git a/src/wp-includes/blocks/accordion-heading/block.json b/src/wp-includes/blocks/accordion-heading/block.json index 8f51644120d41..1aa1756019374 100644 --- a/src/wp-includes/blocks/accordion-heading/block.json +++ b/src/wp-includes/blocks/accordion-heading/block.json @@ -45,6 +45,7 @@ "letterSpacing" ], "fontSize": true, + "lineHeight": true, "__experimentalFontFamily": true, "__experimentalFontWeight": true, "__experimentalFontStyle": true, diff --git a/src/wp-includes/blocks/archives/block.json b/src/wp-includes/blocks/archives/block.json index 7455b558c0d18..b0063dd06663b 100644 --- a/src/wp-includes/blocks/archives/block.json +++ b/src/wp-includes/blocks/archives/block.json @@ -42,6 +42,9 @@ "gradient": true } }, + "dimensions": { + "minHeight": true + }, "html": false, "spacing": { "margin": true, diff --git a/src/wp-includes/blocks/avatar.php b/src/wp-includes/blocks/avatar.php index 196d67a4d480c..c257175432685 100644 --- a/src/wp-includes/blocks/avatar.php +++ b/src/wp-includes/blocks/avatar.php @@ -19,6 +19,7 @@ function render_block_core_avatar( $attributes, $content, $block ) { $size = $attributes['size'] ?? 96; $wrapper_attributes = get_block_wrapper_attributes(); $border_attributes = get_block_core_avatar_border_attributes( $attributes ); + $shadow_styles = wp_style_engine_get_styles( array( 'shadow' => $attributes['style']['shadow'] ?? null ) ); // Class gets passed through `esc_attr` via `get_avatar`. $image_classes = ! empty( $border_attributes['class'] ) @@ -26,10 +27,11 @@ function render_block_core_avatar( $attributes, $content, $block ) { : 'wp-block-avatar__image'; // Unlike class, `get_avatar` doesn't filter the styles via `esc_attr`. - // The style engine does pass the border styles through + // The style engine does pass the border and shadow styles through // `safecss_filter_attr` however. - $image_styles = ! empty( $border_attributes['style'] ) - ? sprintf( ' style="%s"', esc_attr( $border_attributes['style'] ) ) + $image_css = ( $border_attributes['style'] ?? '' ) . ( $shadow_styles['css'] ?? '' ); + $image_styles = ! empty( $image_css ) + ? sprintf( ' style="%s"', esc_attr( $image_css ) ) : ''; if ( ! isset( $block->context['commentId'] ) ) { diff --git a/src/wp-includes/blocks/avatar/block.json b/src/wp-includes/blocks/avatar/block.json index 0cb92d81865c7..7d8b2ddee1f10 100644 --- a/src/wp-includes/blocks/avatar/block.json +++ b/src/wp-includes/blocks/avatar/block.json @@ -54,12 +54,16 @@ "filter": { "duotone": true }, + "shadow": { + "__experimentalSkipSerialization": true + }, "interactivity": { "clientNavigation": true } }, "selectors": { "border": ".wp-block-avatar img", + "shadow": ".wp-block-avatar img", "filter": { "duotone": ".wp-block-avatar img" } diff --git a/src/wp-includes/blocks/blocks-json.php b/src/wp-includes/blocks/blocks-json.php index 73e0bebb8fb78..e21c24ebf586c 100644 --- a/src/wp-includes/blocks/blocks-json.php +++ b/src/wp-includes/blocks/blocks-json.php @@ -152,6 +152,7 @@ 'letterSpacing' ), 'fontSize' => true, + 'lineHeight' => true, '__experimentalFontFamily' => true, '__experimentalFontWeight' => true, '__experimentalFontStyle' => true, @@ -414,6 +415,9 @@ 'gradient' => true ) ), + 'dimensions' => array( + 'minHeight' => true + ), 'html' => false, 'spacing' => array( 'margin' => true, @@ -591,12 +595,16 @@ 'filter' => array( 'duotone' => true ), + 'shadow' => array( + '__experimentalSkipSerialization' => true + ), 'interactivity' => array( 'clientNavigation' => true ) ), 'selectors' => array( 'border' => '.wp-block-avatar img', + 'shadow' => '.wp-block-avatar img', 'filter' => array( 'duotone' => '.wp-block-avatar img' ) @@ -808,6 +816,12 @@ 'splitting' => true, 'align' => false, 'alignWide' => false, + 'background' => array( + 'backgroundImage' => true, + 'backgroundSize' => true, + 'gradient' => true, + '__experimentalSkipSerialization' => true + ), 'color' => array( '__experimentalSkipSerialization' => true, 'gradients' => true, @@ -971,6 +985,10 @@ 'fontSize' => true ) ), + 'dimensions' => array( + 'minHeight' => true, + 'minWidth' => true + ), '__experimentalBorder' => array( 'color' => true, 'radius' => true, @@ -994,7 +1012,8 @@ 'clientNavigation' => true ), 'listView' => true, - 'contentRole' => true + 'contentRole' => true, + 'shadow' => true ), 'editorStyle' => 'wp-block-buttons-editor', 'style' => 'wp-block-buttons' @@ -1196,6 +1215,10 @@ 'gradient' => true ) ), + 'dimensions' => array( + 'minHeight' => true, + 'minWidth' => true + ), 'typography' => array( 'fontSize' => true, 'lineHeight' => true, @@ -1400,6 +1423,10 @@ 'gradient' => true ) ), + 'dimensions' => array( + 'minHeight' => true, + 'minWidth' => true + ), 'spacing' => array( 'blockGap' => array( '__experimentalDefault' => '2em', @@ -1995,6 +2022,11 @@ 'type' => 'flex' ) ), + 'spacing' => array( + 'padding' => true, + 'margin' => true, + 'blockGap' => true + ), 'typography' => array( 'fontSize' => true, 'lineHeight' => true, @@ -2008,6 +2040,12 @@ 'fontSize' => true ) ), + '__experimentalBorder' => array( + 'color' => true, + 'radius' => true, + 'style' => true, + 'width' => true + ), 'interactivity' => array( 'clientNavigation' => true ) @@ -2424,7 +2462,8 @@ 'allowJustification' => false ), 'interactivity' => array( - 'clientNavigation' => true + 'clientNavigation' => true, + 'interactive' => true ), 'filter' => array( 'duotone' => true @@ -2515,6 +2554,9 @@ 'padding' => false ) ), + 'dimensions' => array( + 'minWidth' => true + ), 'typography' => array( 'fontSize' => true, 'lineHeight' => true, @@ -2584,8 +2626,13 @@ 'supports' => array( 'anchor' => true, 'align' => true, + 'dimensions' => array( + 'minHeight' => true, + 'minWidth' => true + ), 'spacing' => array( - 'margin' => true + 'margin' => true, + 'padding' => true ), 'interactivity' => array( 'clientNavigation' => true @@ -2678,6 +2725,10 @@ 'margin' => true, 'padding' => true ), + 'dimensions' => array( + 'minHeight' => true, + 'minWidth' => true + ), 'color' => array( 'gradients' => true, 'link' => true, @@ -2699,6 +2750,7 @@ 'style' => true ) ), + 'shadow' => true, 'interactivity' => true ), 'editorStyle' => 'wp-block-file-editor', @@ -2764,6 +2816,10 @@ 'padding' => false ) ), + 'dimensions' => array( + 'minHeight' => true, + 'minWidth' => true + ), 'typography' => array( 'fontSize' => true, 'lineHeight' => true, @@ -3005,6 +3061,11 @@ 'background' => true, 'gradients' => true ), + 'shadow' => true, + 'dimensions' => array( + 'minHeight' => true, + 'minWidth' => true + ), 'layout' => array( 'allowSwitching' => false, 'allowInheriting' => false, @@ -3018,11 +3079,19 @@ 'type' => 'flex' ) ), + 'filter' => array( + 'duotone' => true + ), 'interactivity' => array( 'clientNavigation' => true ), 'listView' => true ), + 'selectors' => array( + 'filter' => array( + 'duotone' => '.wp-block-gallery :where(img)' + ) + ), 'editorStyle' => 'wp-block-gallery-editor', 'style' => 'wp-block-gallery' ), @@ -3208,6 +3277,10 @@ 'text' => true ) ), + 'dimensions' => array( + 'minHeight' => true, + 'minWidth' => true + ), 'shadow' => true, 'spacing' => array( 'margin' => true, @@ -3221,6 +3294,7 @@ 'fontSize' => true, 'lineHeight' => true, 'textAlign' => true, + 'textIndent' => true, '__experimentalFontFamily' => true, '__experimentalFontStyle' => true, '__experimentalFontWeight' => true, @@ -3299,6 +3373,10 @@ ) ), 'shadow' => true, + 'dimensions' => array( + 'minHeight' => true, + 'minWidth' => true + ), '__experimentalBorder' => array( 'color' => true, 'radius' => true, @@ -3311,6 +3389,14 @@ 'width' => false ) ), + 'spacing' => array( + 'margin' => true, + 'padding' => true, + '__experimentalDefaultControls' => array( + 'margin' => false, + 'padding' => false + ) + ), 'interactivity' => array( 'clientNavigation' => true ) @@ -3674,11 +3760,21 @@ 'link' => true ) ), + 'dimensions' => array( + 'minHeight' => true, + 'minWidth' => true + ), 'html' => false, 'spacing' => array( 'margin' => true, 'padding' => true ), + '__experimentalBorder' => array( + 'color' => true, + 'radius' => true, + 'style' => true, + 'width' => true + ), 'shadow' => true, 'typography' => array( 'fontSize' => true, @@ -3804,6 +3900,10 @@ 'link' => true ) ), + 'dimensions' => array( + 'minHeight' => true, + 'minWidth' => true + ), 'spacing' => array( 'margin' => true, 'padding' => true, @@ -3945,6 +4045,15 @@ 'fontSize' => true ) ), + 'background' => array( + 'backgroundImage' => true, + 'backgroundSize' => true, + 'gradient' => true, + '__experimentalDefaultControls' => array( + 'backgroundImage' => true, + 'gradient' => true + ) + ), 'color' => array( 'gradients' => true, 'link' => true, @@ -3961,6 +4070,7 @@ 'padding' => false ) ), + 'shadow' => true, '__unstablePasteTextInline' => true, '__experimentalOnMerge' => true, '__experimentalSlashInserter' => true, @@ -3970,7 +4080,8 @@ 'listView' => true ), 'selectors' => array( - 'border' => '.wp-block-list:not(.wp-block-list .wp-block-list)' + 'border' => '.wp-block-list:not(.wp-block-list .wp-block-list)', + 'shadow' => '.wp-block-list:not(.wp-block-list .wp-block-list)' ), 'editorStyle' => 'wp-block-list-editor', 'style' => 'wp-block-list' @@ -4005,6 +4116,11 @@ 'html' => false, 'className' => false, 'splitting' => true, + 'background' => array( + 'backgroundImage' => true, + 'backgroundSize' => true, + 'gradient' => true + ), '__experimentalBorder' => array( 'color' => true, 'radius' => true, @@ -4027,6 +4143,7 @@ 'padding' => false ) ), + 'shadow' => true, 'typography' => array( 'fontSize' => true, 'lineHeight' => true, @@ -4046,7 +4163,8 @@ ), 'selectors' => array( 'root' => '.wp-block-list > li', - 'border' => '.wp-block-list:not(.wp-block-list .wp-block-list) > li' + 'border' => '.wp-block-list:not(.wp-block-list .wp-block-list) > li', + 'shadow' => '.wp-block-list:not(.wp-block-list .wp-block-list) > li' ) ), 'loginout' => array( @@ -4093,6 +4211,10 @@ 'gradients' => true, 'link' => true ), + 'dimensions' => array( + 'minHeight' => true, + 'minWidth' => true + ), 'spacing' => array( 'margin' => true, 'padding' => true, @@ -4166,6 +4288,10 @@ 'text' => true ) ), + 'dimensions' => array( + 'minHeight' => true, + 'minWidth' => true + ), 'shadow' => true, 'spacing' => array( 'margin' => true, @@ -4310,6 +4436,11 @@ 'full' ), 'html' => false, + 'background' => array( + 'backgroundImage' => true, + 'backgroundSize' => true, + 'gradient' => true + ), '__experimentalBorder' => array( 'color' => true, 'radius' => true, @@ -4332,10 +4463,15 @@ 'text' => true ) ), + 'dimensions' => array( + 'minHeight' => true, + 'minWidth' => true + ), 'spacing' => array( 'margin' => true, 'padding' => true ), + 'shadow' => true, 'typography' => array( 'fontSize' => true, 'lineHeight' => true, @@ -4349,11 +4485,19 @@ 'fontSize' => true ) ), + 'filter' => array( + 'duotone' => true + ), 'interactivity' => array( 'clientNavigation' => true ), 'allowedBlocks' => true ), + 'selectors' => array( + 'filter' => array( + 'duotone' => '.wp-block-media-text > .wp-block-media-text__media img, .wp-block-media-text > .wp-block-media-text__media video' + ) + ), 'editorStyle' => 'wp-block-media-text-editor', 'style' => 'wp-block-media-text' ), @@ -4989,6 +5133,10 @@ ) ), 'shadow' => true, + 'dimensions' => array( + 'minHeight' => true, + 'minWidth' => true + ), 'contentRole' => true ), 'editorStyle' => 'wp-block-page-list-editor', @@ -5104,6 +5252,7 @@ 'style' => true, 'width' => true ), + 'shadow' => true, 'color' => array( 'gradients' => true, 'link' => true, @@ -5499,6 +5648,7 @@ 'lineHeight' => true, 'textAlign' => true, 'textColumns' => true, + 'textIndent' => true, '__experimentalFontFamily' => true, '__experimentalFontWeight' => true, '__experimentalFontStyle' => true, @@ -5698,6 +5848,10 @@ 'text' => true ) ), + 'dimensions' => array( + 'minHeight' => true, + 'minWidth' => true + ), 'spacing' => array( 'margin' => true, 'padding' => true @@ -5706,6 +5860,7 @@ 'fontSize' => true, 'lineHeight' => true, 'textAlign' => true, + '__experimentalFontFamily' => true, '__experimentalFontStyle' => true, '__experimentalFontWeight' => true, '__experimentalLetterSpacing' => true, @@ -5844,7 +5999,8 @@ ) ), 'dimensions' => array( - 'minHeight' => true + 'minHeight' => true, + 'minWidth' => true ), 'shadow' => true, 'spacing' => array( @@ -6031,6 +6187,10 @@ 'margin' => true, 'padding' => true ), + 'dimensions' => array( + 'minHeight' => true, + 'minWidth' => true + ), 'typography' => array( 'fontSize' => true, 'lineHeight' => true, @@ -6151,6 +6311,7 @@ '__experimentalBorder' => array( 'color' => true, 'radius' => true, + 'style' => true, 'width' => true, '__experimentalSkipSerialization' => true, '__experimentalDefaultControls' => array( @@ -6419,6 +6580,10 @@ 'link' => true ) ), + 'dimensions' => array( + 'minHeight' => true, + 'minWidth' => true + ), 'shadow' => true, 'spacing' => array( 'margin' => true, @@ -6496,6 +6661,10 @@ 'text' => true ) ), + 'dimensions' => array( + 'minHeight' => true, + 'minWidth' => true + ), 'html' => false, 'shadow' => true, 'spacing' => array( @@ -6600,6 +6769,10 @@ 'link' => true ) ), + 'dimensions' => array( + 'minHeight' => true, + 'minWidth' => true + ), 'shadow' => true, 'spacing' => array( 'margin' => true, @@ -6669,6 +6842,10 @@ 'text' => true ) ), + 'dimensions' => array( + 'minHeight' => true, + 'minWidth' => true + ), 'shadow' => true, 'spacing' => array( 'padding' => true, @@ -6754,7 +6931,8 @@ ) ), 'dimensions' => array( - 'minHeight' => true + 'minHeight' => true, + 'minWidth' => true ), 'shadow' => true, 'spacing' => array( @@ -6913,6 +7091,10 @@ 'heading' => true, 'button' => true ), + 'dimensions' => array( + 'minHeight' => true, + 'minWidth' => true + ), 'spacing' => array( 'padding' => true, 'margin' => true, @@ -6998,6 +7180,11 @@ 'link' => true ) ), + 'spacing' => array( + 'padding' => true, + 'margin' => true, + 'blockGap' => true + ), 'layout' => array( 'allowSwitching' => false, 'allowInheriting' => false, @@ -7018,6 +7205,18 @@ 'fontSize' => true ) ), + '__experimentalBorder' => array( + 'color' => true, + 'radius' => true, + 'style' => true, + 'width' => true, + '__experimentalDefaultControls' => array( + 'color' => false, + 'radius' => false, + 'style' => false, + 'width' => false + ) + ), 'interactivity' => array( 'clientNavigation' => true ) @@ -7316,6 +7515,10 @@ 'margin' => true, 'padding' => true ), + 'dimensions' => array( + 'minHeight' => true, + 'minWidth' => true + ), 'color' => array( 'gradients' => true, '__experimentalDefaultControls' => array( @@ -7418,6 +7621,7 @@ ), 'dimensions' => array( 'minHeight' => true, + 'minWidth' => true, '__experimentalDefaultControls' => array( 'minHeight' => false ) @@ -7441,6 +7645,7 @@ 'gradients' => true, 'heading' => true, 'link' => true, + 'button' => true, '__experimentalDefaultControls' => array( 'background' => true, 'text' => true @@ -7521,6 +7726,10 @@ 'textDecoration' => true ) ), + 'dimensions' => array( + 'minHeight' => true, + 'minWidth' => true + ), 'spacing' => array( 'margin' => array( 'top', @@ -7534,6 +7743,7 @@ '__experimentalBorder' => array( 'color' => true, 'radius' => true, + 'style' => true, 'width' => true, '__experimentalDefaultControls' => array( 'width' => true @@ -7621,6 +7831,10 @@ 'margin' => false ) ), + 'dimensions' => array( + 'minHeight' => true, + 'minWidth' => true + ), 'shadow' => true, 'background' => array( 'backgroundImage' => true, @@ -7734,7 +7948,8 @@ ) ), 'spacing' => array( - 'margin' => true + 'margin' => true, + 'padding' => true ), 'html' => false ), @@ -7976,6 +8191,10 @@ ) ), 'contentRole' => true, + 'dimensions' => array( + 'minHeight' => true, + 'minWidth' => true + ), 'spacing' => array( 'margin' => true, 'padding' => true, @@ -8074,6 +8293,10 @@ 'link' => true ) ), + 'dimensions' => array( + 'minHeight' => true, + 'minWidth' => true + ), 'spacing' => array( 'padding' => true, 'margin' => true, @@ -8274,6 +8497,7 @@ 'style' => true ) ), + 'shadow' => true, 'contentRole' => true, 'listView' => true ), @@ -8408,10 +8632,14 @@ 'padding' => true, 'blockGap' => true ) + ), + 'shadow' => array( + '__experimentalSkipSerialization' => true ) ), 'selectors' => array( 'border' => '.wp-block-tab-list button', + 'shadow' => '.wp-block-tab-list button', 'color' => array( 'background' => '.wp-block-tab-list button', 'text' => '.wp-block-tab-list button' @@ -8541,6 +8769,9 @@ 'spacing' => array( 'padding' => true ), + 'dimensions' => array( + 'minHeight' => true + ), 'typography' => array( 'fontSize' => true, 'lineHeight' => true, @@ -8854,6 +9085,9 @@ 'margin' => true, 'padding' => true ), + 'dimensions' => array( + 'minWidth' => true + ), 'shadow' => true, 'typography' => array( 'fontSize' => true, @@ -9042,8 +9276,13 @@ ), 'shadow' => true, 'spacing' => array( + 'margin' => true, 'padding' => true ), + 'dimensions' => array( + 'minHeight' => true, + 'minWidth' => true + ), 'typography' => array( 'fontSize' => true, 'lineHeight' => true, @@ -9109,6 +9348,10 @@ 'text' => true ) ), + 'dimensions' => array( + 'minHeight' => true, + 'minWidth' => true + ), 'spacing' => array( 'padding' => true, 'margin' => true @@ -9198,9 +9441,14 @@ 'link' => true ) ), + 'dimensions' => array( + 'minHeight' => true, + 'minWidth' => true + ), 'shadow' => true, 'spacing' => array( - 'padding' => true + 'padding' => true, + 'margin' => true ), 'typography' => array( 'fontSize' => true, @@ -9285,6 +9533,10 @@ 'fontSize' => true ) ), + 'dimensions' => array( + 'minHeight' => true, + 'minWidth' => true + ), 'spacing' => array( 'margin' => true, 'padding' => true, @@ -9456,6 +9708,7 @@ ), 'dimensions' => array( 'minHeight' => true, + 'minWidth' => true, '__experimentalDefaultControls' => array( 'minHeight' => false ) @@ -9465,12 +9718,15 @@ '__experimentalFontFamily' => true, 'lineHeight' => true, 'textAlign' => true, + 'textColumns' => true, + 'textIndent' => true, '__experimentalFontStyle' => true, '__experimentalFontWeight' => true, '__experimentalLetterSpacing' => true, '__experimentalTextTransform' => true, '__experimentalTextDecoration' => true, '__experimentalWritingMode' => true, + 'fitText' => true, '__experimentalDefaultControls' => array( 'fontSize' => true ) @@ -9594,6 +9850,9 @@ 'supports' => array( 'anchor' => true, 'align' => true, + 'filter' => array( + 'duotone' => true + ), 'spacing' => array( 'margin' => true, 'padding' => true, @@ -9610,7 +9869,10 @@ ) ), 'selectors' => array( - 'shadow' => '.wp-block-video video' + 'shadow' => '.wp-block-video video', + 'filter' => array( + 'duotone' => '.wp-block-video video' + ) ), 'editorStyle' => 'wp-block-video-editor', 'style' => 'wp-block-video' diff --git a/src/wp-includes/blocks/breadcrumbs.php b/src/wp-includes/blocks/breadcrumbs.php index 02c038dd057ea..b659afd8259b1 100644 --- a/src/wp-includes/blocks/breadcrumbs.php +++ b/src/wp-includes/blocks/breadcrumbs.php @@ -188,7 +188,7 @@ function render_block_core_breadcrumbs( $attributes, $content, $block ) { $wrapper_attributes = get_block_wrapper_attributes( array( 'style' => '--separator: "' . $separator . '";', - 'aria-label' => _x( 'Breadcrumbs', 'area label' ), + 'aria-label' => _x( 'Breadcrumbs', 'aria label' ), ) ); diff --git a/src/wp-includes/blocks/button.php b/src/wp-includes/blocks/button.php index 7b67ad158aed1..fd117e9436a57 100644 --- a/src/wp-includes/blocks/button.php +++ b/src/wp-includes/blocks/button.php @@ -60,6 +60,53 @@ function render_block_core_button( $attributes, $content ) { return ''; } + // Background skips serialization, so apply it to the link like color. + $background = $attributes['style']['background'] ?? null; + + if ( is_array( $background ) ) { + $background_styles = array( + 'backgroundImage' => $background['backgroundImage'] ?? null, + 'backgroundSize' => $background['backgroundSize'] ?? null, + 'backgroundPosition' => $background['backgroundPosition'] ?? null, + 'backgroundRepeat' => $background['backgroundRepeat'] ?? null, + 'backgroundAttachment' => $background['backgroundAttachment'] ?? null, + 'gradient' => $background['gradient'] ?? null, + ); + + // Mirror the background block support defaults. + if ( ! empty( $background_styles['backgroundImage'] ) ) { + $background_styles['backgroundSize'] = $background_styles['backgroundSize'] ?? 'cover'; + if ( 'contain' === $background_styles['backgroundSize'] && ! $background_styles['backgroundPosition'] ) { + $background_styles['backgroundPosition'] = '50% 50%'; + } + } + + $styles = wp_style_engine_get_styles( array( 'background' => $background_styles ) ); + + if ( ! empty( $styles['css'] ) ) { + $processor = new WP_HTML_Tag_Processor( $content ); + while ( $processor->next_tag() ) { + if ( $tag !== $processor->get_tag() ) { + continue; + } + + $existing_style = $processor->get_attribute( 'style' ); + if ( is_string( $existing_style ) && '' !== $existing_style ) { + $separator = str_ends_with( $existing_style, ';' ) ? '' : ';'; + $processor->set_attribute( 'style', $existing_style . $separator . $styles['css'] ); + } else { + $processor->set_attribute( 'style', $styles['css'] ); + } + + if ( ! empty( $background_styles['backgroundImage'] ) || ! empty( $background_styles['gradient'] ) ) { + $processor->add_class( 'has-background' ); + } + break; + } + $content = $processor->get_updated_html(); + } + } + $width = $attributes['style']['dimensions']['width'] ?? null; if ( is_string( $width ) && '' !== $width ) { diff --git a/src/wp-includes/blocks/button/block.json b/src/wp-includes/blocks/button/block.json index 2e23a64c8f559..29e3c1f22c50f 100644 --- a/src/wp-includes/blocks/button/block.json +++ b/src/wp-includes/blocks/button/block.json @@ -70,6 +70,12 @@ "splitting": true, "align": false, "alignWide": false, + "background": { + "backgroundImage": true, + "backgroundSize": true, + "gradient": true, + "__experimentalSkipSerialization": true + }, "color": { "__experimentalSkipSerialization": true, "gradients": true, diff --git a/src/wp-includes/blocks/buttons/block.json b/src/wp-includes/blocks/buttons/block.json index 4927a9644837b..03092ff3dc10a 100644 --- a/src/wp-includes/blocks/buttons/block.json +++ b/src/wp-includes/blocks/buttons/block.json @@ -50,6 +50,10 @@ "fontSize": true } }, + "dimensions": { + "minHeight": true, + "minWidth": true + }, "__experimentalBorder": { "color": true, "radius": true, @@ -73,7 +77,8 @@ "clientNavigation": true }, "listView": true, - "contentRole": true + "contentRole": true, + "shadow": true }, "editorStyle": "wp-block-buttons-editor", "style": "wp-block-buttons" diff --git a/src/wp-includes/blocks/code/block.json b/src/wp-includes/blocks/code/block.json index 028a64620cac3..4fad135a9706d 100644 --- a/src/wp-includes/blocks/code/block.json +++ b/src/wp-includes/blocks/code/block.json @@ -27,6 +27,10 @@ "gradient": true } }, + "dimensions": { + "minHeight": true, + "minWidth": true + }, "typography": { "fontSize": true, "lineHeight": true, diff --git a/src/wp-includes/blocks/columns/block.json b/src/wp-includes/blocks/columns/block.json index dcd1193ca093e..7f742a87931a1 100644 --- a/src/wp-includes/blocks/columns/block.json +++ b/src/wp-includes/blocks/columns/block.json @@ -43,6 +43,10 @@ "gradient": true } }, + "dimensions": { + "minHeight": true, + "minWidth": true + }, "spacing": { "blockGap": { "__experimentalDefault": "2em", diff --git a/src/wp-includes/blocks/comments-pagination/block.json b/src/wp-includes/blocks/comments-pagination/block.json index a2b7d9fe0b170..867a29736413d 100644 --- a/src/wp-includes/blocks/comments-pagination/block.json +++ b/src/wp-includes/blocks/comments-pagination/block.json @@ -50,6 +50,11 @@ "type": "flex" } }, + "spacing": { + "padding": true, + "margin": true, + "blockGap": true + }, "typography": { "fontSize": true, "lineHeight": true, @@ -63,6 +68,12 @@ "fontSize": true } }, + "__experimentalBorder": { + "color": true, + "radius": true, + "style": true, + "width": true + }, "interactivity": { "clientNavigation": true } diff --git a/src/wp-includes/blocks/cover.php b/src/wp-includes/blocks/cover.php index 8bd1c3f5cd38f..1241ece24c917 100644 --- a/src/wp-includes/blocks/cover.php +++ b/src/wp-includes/blocks/cover.php @@ -26,6 +26,10 @@ function render_block_core_cover( $attributes, $content ) { ) { $url = $attributes['url']; + // The view script decides whether the embed may autoplay, so it is only + // needed for embed backgrounds. + wp_enqueue_script_module( '@wordpress/block-library/cover/view' ); + // Use WordPress's native oEmbed processing (includes caching). $oembed_html = wp_oembed_get( $url ); @@ -50,7 +54,8 @@ function render_block_core_cover( $attributes, $content ) { } // Modify iframe src to add background video parameters based on provider. - $parsed_url = wp_parse_url( $iframe_src ); + $parsed_url = wp_parse_url( $iframe_src ); + $reduced_motion_src = null; if ( $parsed_url && isset( $parsed_url['host'] ) ) { // Parse existing query parameters. $query_params = array(); @@ -58,9 +63,12 @@ function render_block_core_cover( $attributes, $content ) { parse_str( $parsed_url['query'], $query_params ); } - // Add background video parameters based on provider. + // Add background video parameters based on provider. The + // autoplay parameters are kept separate so a source without + // them can also be built, which the view script swaps in for + // a visitor who has asked for reduced motion. + $autoplay_params = array(); if ( 'youtube' === $provider ) { - $query_params['autoplay'] = '1'; $query_params['mute'] = '1'; $query_params['loop'] = '1'; $query_params['controls'] = '0'; @@ -74,32 +82,53 @@ function render_block_core_cover( $attributes, $content ) { if ( $video_id ) { $query_params['playlist'] = $video_id; } + + $autoplay_params['autoplay'] = '1'; } elseif ( 'vimeo' === $provider ) { - $query_params['autoplay'] = '1'; $query_params['muted'] = '1'; $query_params['loop'] = '1'; - $query_params['background'] = '1'; $query_params['controls'] = '0'; $query_params['transparent'] = '0'; + + // Vimeo's background mode always autoplays, so it can only + // be used when autoplay is allowed. + $autoplay_params['autoplay'] = '1'; + $autoplay_params['background'] = '1'; } elseif ( 'videopress' === $provider || 'wordpress-tv' === $provider ) { - $query_params['autoplay'] = '1'; - $query_params['loop'] = '1'; - $query_params['muted'] = '1'; + $query_params['loop'] = '1'; + $query_params['muted'] = '1'; + + $autoplay_params['autoplay'] = '1'; } // Rebuild the URL with new parameters. - $iframe_src = $parsed_url['scheme'] . '://' . $parsed_url['host']; + $iframe_base = $parsed_url['scheme'] . '://' . $parsed_url['host']; if ( isset( $parsed_url['path'] ) ) { - $iframe_src .= $parsed_url['path']; - } - if ( ! empty( $query_params ) ) { - $iframe_src .= '?' . http_build_query( $query_params ); + $iframe_base .= $parsed_url['path']; } + + $reduced_motion_src = empty( $query_params ) + ? $iframe_base + : $iframe_base . '?' . http_build_query( $query_params ); + + $iframe_src = empty( $autoplay_params ) + ? $reduced_motion_src + : $iframe_base . '?' . http_build_query( array_merge( $query_params, $autoplay_params ) ); } - // Build the iframe HTML that will replace the figure. + // Build the iframe HTML that will replace the figure. The server + // renders the autoplaying source, and the view script swaps in the + // one without autoplay for a visitor who prefers reduced motion. $iframe_html = sprintf( - '
', + '
', + esc_attr( + wp_json_encode( + array( + 'src' => $iframe_src, + 'reducedMotionSrc' => $reduced_motion_src, + ) + ) + ), esc_url( $iframe_src ) ); diff --git a/src/wp-includes/blocks/cover/block.json b/src/wp-includes/blocks/cover/block.json index 1d95f80402e61..8f2f864555eb7 100644 --- a/src/wp-includes/blocks/cover/block.json +++ b/src/wp-includes/blocks/cover/block.json @@ -153,7 +153,8 @@ "allowJustification": false }, "interactivity": { - "clientNavigation": true + "clientNavigation": true, + "interactive": true }, "filter": { "duotone": true diff --git a/src/wp-includes/blocks/details/block.json b/src/wp-includes/blocks/details/block.json index f5a2a1a6c3edc..ef2ad1428c39c 100644 --- a/src/wp-includes/blocks/details/block.json +++ b/src/wp-includes/blocks/details/block.json @@ -67,6 +67,9 @@ "padding": false } }, + "dimensions": { + "minWidth": true + }, "typography": { "fontSize": true, "lineHeight": true, diff --git a/src/wp-includes/blocks/embed/block.json b/src/wp-includes/blocks/embed/block.json index d6f7c501d6507..41db597f29949 100644 --- a/src/wp-includes/blocks/embed/block.json +++ b/src/wp-includes/blocks/embed/block.json @@ -43,8 +43,13 @@ "supports": { "anchor": true, "align": true, + "dimensions": { + "minHeight": true, + "minWidth": true + }, "spacing": { - "margin": true + "margin": true, + "padding": true }, "interactivity": { "clientNavigation": true diff --git a/src/wp-includes/blocks/file/block.json b/src/wp-includes/blocks/file/block.json index 24eeba2b2c386..3d8da956428be 100644 --- a/src/wp-includes/blocks/file/block.json +++ b/src/wp-includes/blocks/file/block.json @@ -78,6 +78,10 @@ "margin": true, "padding": true }, + "dimensions": { + "minHeight": true, + "minWidth": true + }, "color": { "gradients": true, "link": true, @@ -99,6 +103,7 @@ "style": true } }, + "shadow": true, "interactivity": true }, "editorStyle": "wp-block-file-editor", diff --git a/src/wp-includes/blocks/footnotes/block.json b/src/wp-includes/blocks/footnotes/block.json index 393f7f702ab99..07fb9171aa243 100644 --- a/src/wp-includes/blocks/footnotes/block.json +++ b/src/wp-includes/blocks/footnotes/block.json @@ -53,6 +53,10 @@ "padding": false } }, + "dimensions": { + "minHeight": true, + "minWidth": true + }, "typography": { "fontSize": true, "lineHeight": true, diff --git a/src/wp-includes/blocks/gallery/block.json b/src/wp-includes/blocks/gallery/block.json index 44158bb0fd0ad..a18adb2573b8c 100644 --- a/src/wp-includes/blocks/gallery/block.json +++ b/src/wp-includes/blocks/gallery/block.json @@ -166,6 +166,11 @@ "background": true, "gradients": true }, + "shadow": true, + "dimensions": { + "minHeight": true, + "minWidth": true + }, "layout": { "allowSwitching": false, "allowInheriting": false, @@ -179,11 +184,19 @@ "type": "flex" } }, + "filter": { + "duotone": true + }, "interactivity": { "clientNavigation": true }, "listView": true }, + "selectors": { + "filter": { + "duotone": ".wp-block-gallery :where(img)" + } + }, "editorStyle": "wp-block-gallery-editor", "style": "wp-block-gallery" } diff --git a/src/wp-includes/blocks/heading/block.json b/src/wp-includes/blocks/heading/block.json index 4498f79781735..0f4a9476b19a9 100644 --- a/src/wp-includes/blocks/heading/block.json +++ b/src/wp-includes/blocks/heading/block.json @@ -53,6 +53,10 @@ "text": true } }, + "dimensions": { + "minHeight": true, + "minWidth": true + }, "shadow": true, "spacing": { "margin": true, @@ -66,6 +70,7 @@ "fontSize": true, "lineHeight": true, "textAlign": true, + "textIndent": true, "__experimentalFontFamily": true, "__experimentalFontStyle": true, "__experimentalFontWeight": true, diff --git a/src/wp-includes/blocks/home-link/block.json b/src/wp-includes/blocks/home-link/block.json index 036e967883164..733a3afdd8e0d 100644 --- a/src/wp-includes/blocks/home-link/block.json +++ b/src/wp-includes/blocks/home-link/block.json @@ -52,6 +52,10 @@ } }, "shadow": true, + "dimensions": { + "minHeight": true, + "minWidth": true + }, "__experimentalBorder": { "color": true, "radius": true, @@ -64,6 +68,14 @@ "width": false } }, + "spacing": { + "margin": true, + "padding": true, + "__experimentalDefaultControls": { + "margin": false, + "padding": false + } + }, "interactivity": { "clientNavigation": true } diff --git a/src/wp-includes/blocks/icon.php b/src/wp-includes/blocks/icon.php index 1b615c8a6dc96..e158333bc4da5 100644 --- a/src/wp-includes/blocks/icon.php +++ b/src/wp-includes/blocks/icon.php @@ -15,7 +15,7 @@ * @return string Returns the Icon. */ function render_block_core_icon( $attributes ) { - if ( empty( $attributes['icon'] ) ) { + if ( empty( $attributes['icon'] ) || ! is_string( $attributes['icon'] ) ) { return; } diff --git a/src/wp-includes/blocks/image.php b/src/wp-includes/blocks/image.php index aef905ef59a64..43f8e8c26c468 100644 --- a/src/wp-includes/blocks/image.php +++ b/src/wp-includes/blocks/image.php @@ -369,13 +369,12 @@ class="wp-lightbox-overlay zoom" data-wp-on--touchstart="actions.handleTouchStart" data-wp-on--touchmove="actions.handleTouchMove" data-wp-on--touchend="actions.handleTouchEnd" - data-wp-on--click="actions.hideLightbox" data-wp-on-window--resize="callbacks.setOverlayStyles" data-wp-on-window--scroll="actions.handleScroll" data-wp-bind--style="state.overlayStyles" tabindex="-1" > - @@ -383,7 +382,7 @@ class="wp-lightbox-overlay zoom" {$prev_button_icon} {$prev_button_text} -