From 4c9455a768b38dfa5dcd324c133563ddb17e8cb1 Mon Sep 17 00:00:00 2001 From: Gutenberg Repository Automation Date: Thu, 31 Aug 2023 09:12:23 +0000 Subject: [PATCH] Merge changes published in the Gutenberg plugin "release/16.6" branch --- .github/CODEOWNERS | 1 + .github/workflows/enforce-pr-labels.yml | 2 +- .github/workflows/publish-npm-packages.yml | 12 +- bin/plugin/commands/packages.js | 65 +- changelog.txt | 634 ++++-- .../getting-started-with-code-contribution.md | 2 +- docs/contributors/code/release.md | 146 +- docs/contributors/code/testing-overview.md | 17 +- docs/explanations/faq.md | 15 +- docs/getting-started/devenv/README.md | 2 +- .../nested-blocks-inner-blocks.md | 25 +- .../enqueueing-assets-in-the-editor.md | 118 + .../platform/custom-block-editor.md | 33 +- docs/manifest.json | 6 + .../block-api/block-metadata.md | 10 + .../block-api/block-variations.md | 178 +- docs/reference-guides/core-blocks.md | 4 +- .../reference-guides/data/data-core-blocks.md | 6 +- .../data/data-core-edit-site.md | 4 + docs/toc.json | 1 + gutenberg.php | 2 +- lib/compat/wordpress-6.3/rest-api.php | 29 + lib/compat/wordpress-6.4/block-patterns.php | 36 + .../class-wp-font-face-resolver.php | 14 +- .../fonts/font-face}/class-wp-font-face.php | 36 +- .../wordpress-6.4}/fonts/fonts.php | 42 +- lib/compat/wordpress-6.4/script-loader.php | 98 + lib/experimental/auto-inserting-blocks.php | 95 +- lib/experimental/editor-settings.php | 4 + .../class-gutenberg-fonts-api-bc-layer.php | 0 .../class-wp-fonts-provider-local.php | 0 .../bc-layer/class-wp-fonts-provider.php | 0 .../bc-layer/class-wp-fonts-resolver.php | 0 .../bc-layer/class-wp-fonts-utils.php | 0 .../bc-layer/class-wp-fonts.php | 0 .../bc-layer/class-wp-web-fonts.php | 0 .../class-wp-webfonts-provider-local.php | 0 .../bc-layer/class-wp-webfonts-provider.php | 0 .../bc-layer/class-wp-webfonts-utils.php | 0 .../bc-layer/class-wp-webfonts.php | 0 .../bc-layer/webfonts-deprecations.php | 4 +- .../class-wp-font-family-utils.php | 8 +- .../font-library}/class-wp-font-family.php | 24 +- .../font-library/class-wp-font-library.php} | 12 +- ...class-wp-rest-font-library-controller.php} | 38 +- .../font-library/font-library.php} | 14 +- lib/load.php | 72 +- package-lock.json | 1923 ++++++++--------- package.json | 17 +- packages/README.md | 2 +- packages/block-editor/CHANGELOG.md | 4 + packages/block-editor/README.md | 42 +- .../src/components/block-icon/test/index.js | 4 +- .../block-list/block-outline.native.js | 7 +- .../src/components/block-list/content.scss | 5 +- .../src/components/block-list/index.js | 7 +- .../block-list/use-block-props/index.js | 26 + .../use-block-props/use-nav-mode-exit.js | 2 +- .../src/components/block-lock/menu-item.js | 2 + .../src/components/block-lock/toolbar.js | 4 +- .../src/components/block-popover/inbetween.js | 7 +- .../src/components/block-popover/index.js | 5 +- .../src/components/block-styles/style.scss | 3 - .../button-block-appender/content.scss | 8 + .../components/color-style-selector/index.js | 2 +- .../src/components/iframe/index.js | 1 + .../inserter/reusable-blocks-tab.native.js | 9 +- .../inserter/search-results.native.js | 22 +- .../src/components/link-control/index.js | 6 +- .../src/components/link-control/test/index.js | 1 + .../list-view/block-select-button.js | 82 +- .../components/list-view/drop-indicator.js | 9 +- .../src/components/list-view/index.js | 32 +- .../list-view/use-list-view-images.js | 12 +- .../src/components/observe-typing/README.md | 4 +- .../src/components/preview-options/index.js | 2 + .../src/components/provider/index.js | 9 +- .../rich-text/use-remove-browser-shortcuts.js | 2 +- .../test/__snapshots__/index.js.snap | 133 -- .../src/components/url-popover/test/index.js | 75 - .../components/use-block-commands/index.js | 180 +- .../src/components/warning/index.js | 4 +- .../src/hooks/auto-inserting-blocks.js | 232 ++ packages/block-editor/src/hooks/index.js | 1 + packages/block-editor/src/store/selectors.js | 2 +- .../src/utils/pre-parse-patterns.js | 69 - packages/block-library/README.md | 19 + .../test/__snapshots__/edit.native.js.snap | 184 +- .../block-library/src/cover/edit/index.js | 4 +- packages/block-library/src/cover/shared.js | 45 +- .../src/cover/test/edit.native.js | 6 +- .../src/embed/embed-link-settings.native.js | 1 - .../src/embed/test/index.native.js | 18 +- .../test/__snapshots__/edit.native.js.snap | 380 ++-- packages/block-library/src/footnotes/init.js | 6 + packages/block-library/src/image/index.php | 5 + packages/block-library/src/list/edit.js | 1 + .../src/navigation/edit/inner-blocks.js | 1 + .../block-library/src/post-content/edit.js | 4 +- .../block-library/src/post-content/index.php | 6 - .../src/post-featured-image/index.php | 6 - .../src/post-navigation-link/index.php | 4 +- .../src/post-template/block.json | 3 +- .../block-library/src/post-template/index.php | 23 +- .../src/query-no-results/index.php | 6 +- .../src/query-pagination-next/block.json | 8 +- .../src/query-pagination-next/index.php | 23 +- .../src/query-pagination-numbers/block.json | 8 +- .../src/query-pagination-numbers/edit.js | 80 +- .../src/query-pagination-numbers/index.php | 31 +- .../src/query-pagination-previous/block.json | 8 +- .../src/query-pagination-previous/index.php | 21 +- packages/block-library/src/query/block.json | 11 +- .../query/edit/inspector-controls/index.js | 49 +- .../src/query/edit/query-content.js | 1 + packages/block-library/src/query/index.php | 95 +- packages/block-library/src/query/style.scss | 63 + packages/block-library/src/query/view.js | 82 + packages/block-library/src/quote/edit.js | 1 + packages/block-library/src/search/edit.js | 10 +- .../test/__snapshots__/edit.native.js.snap | 628 +++--- packages/block-library/src/search/utils.js | 1 - .../block-library/src/site-logo/style.scss | 1 + .../src/social-link/edit.native.js | 2 +- .../src/social-link/editor.native.scss | 4 - .../src/social-link/test/index.native.js | 132 -- .../src/social-links/editor.scss | 3 +- .../src/social-links/test/edit.native.js | 30 + .../src/template-part/edit/index.js | 57 +- packages/blocks/src/api/registration.js | 88 +- packages/blocks/src/api/test/registration.js | 118 +- packages/blocks/src/store/actions.js | 202 +- packages/blocks/src/store/index.js | 2 + packages/blocks/src/store/private-actions.js | 42 + .../blocks/src/store/private-selectors.js | 34 +- .../blocks/src/store/process-block-type.js | 159 ++ packages/blocks/src/store/reducer.js | 74 +- packages/blocks/src/store/selectors.js | 11 - packages/blocks/src/store/test/reducer.js | 15 +- packages/components/CHANGELOG.md | 20 +- packages/components/CONTRIBUTING.md | 4 +- packages/components/README.md | 11 +- packages/components/package.json | 2 +- .../stories/index.story.tsx | 12 +- .../alignment-matrix-control/test/index.tsx | 8 +- .../stories/index.story.tsx | 8 +- .../src/animate/stories/index.story.tsx | 24 +- .../src/base-control/stories/index.story.tsx | 16 +- .../stories/index.story.tsx | 16 +- .../border-control/stories/index.story.tsx | 24 +- .../src/button-group/stories/index.story.tsx | 12 +- .../src/button/stories/e2e/index.story.tsx | 6 +- .../src/button/stories/index.story.tsx | 22 +- .../src/card/stories/index.story.tsx | 12 +- .../checkbox-control/stories/index.story.tsx | 15 +- .../stories/index.story.tsx | 25 +- .../color-indicator/stories/index.story.tsx | 12 +- .../src/color-palette/stories/index.story.tsx | 35 +- .../src/color-palette/test/index.tsx | 24 +- .../src/color-palette/test/utils.ts | 15 - .../components/src/color-palette/utils.ts | 7 - .../color-picker/hsv-color-picker.native.js | 88 + .../src/color-picker/hue-picker.native.js | 194 ++ .../src/color-picker/index.native.js | 3 +- .../color-picker/saturation-picker.native.js | 163 ++ .../src/color-picker/stories/index.story.tsx | 8 +- .../src/color-picker/style.native.scss | 23 + .../combobox-control/stories/index.story.tsx | 8 +- .../src/confirm-dialog/stories/index.story.js | 2 +- .../stories/index.story.tsx | 8 +- .../src/date-time/stories/date-time.story.tsx | 20 +- .../src/date-time/stories/date.story.tsx | 19 +- .../src/date-time/stories/time.story.tsx | 10 +- .../dimension-control/stories/index.story.tsx | 8 +- .../src/disabled/stories/index.story.tsx | 10 +- .../src/divider/stories/index.story.tsx | 14 +- .../src/draggable/stories/index.story.tsx | 12 +- .../src/drop-zone/stories/index.story.tsx | 8 +- .../dropdown-menu-v2/stories/index.story.tsx | 39 +- .../src/dropdown-menu/stories/index.story.tsx | 8 +- .../src/dropdown/stories/index.story.tsx | 14 +- .../stories/duotone-picker.story.tsx | 11 +- .../stories/duotone-swatch.story.tsx | 8 +- .../src/elevation/stories/index.story.tsx | 16 +- .../src/external-link/stories/index.story.tsx | 12 +- .../src/flex/stories/index.story.tsx | 14 +- .../stories/index.story.tsx | 8 +- .../stories/e2e/index.story.tsx | 6 +- .../font-size-picker/stories/index.story.tsx | 22 +- .../form-file-upload/stories/index.story.tsx | 8 +- .../src/form-toggle/stories/index.story.tsx | 13 +- .../form-token-field/stories/index.story.tsx | 23 +- .../gradient-picker/stories/index.story.tsx | 8 +- .../src/grid/stories/index.story.tsx | 10 +- .../src/guide/stories/index.story.tsx | 6 +- .../src/h-stack/stories/e2e/index.story.tsx | 8 +- .../src/h-stack/stories/index.story.tsx | 10 +- .../src/heading/stories/index.story.tsx | 8 +- .../src/icon/stories/index.story.tsx | 12 +- .../src/input-control/stories/index.story.tsx | 10 +- .../src/item-group/item-group/component.tsx | 1 - .../src/item-group/item/component.tsx | 1 - .../src/item-group/stories/index.story.tsx | 25 +- .../stories/index.story.tsx | 8 +- .../src/menu-group/stories/index.story.tsx | 12 +- packages/components/src/menu-item/README.md | 2 +- packages/components/src/menu-item/index.tsx | 7 +- .../src/menu-item/stories/index.story.tsx | 80 + packages/components/src/menu-item/types.ts | 5 +- .../menu-items-choice/stories/index.story.tsx | 12 +- .../link-settings-navigation.native.js | 2 +- .../src/modal/stories/index.story.tsx | 15 +- .../stories/navigable-menu.story.tsx | 8 +- .../stories/tabbable-container.story.tsx | 8 +- packages/components/src/navigation/index.tsx | 1 - .../src/navigation/stories/index.story.tsx | 20 +- .../stories/utils/controlled-state.tsx | 4 +- .../src/navigation/stories/utils/default.tsx | 4 +- .../src/navigation/stories/utils/group.tsx | 4 +- .../stories/utils/hide-if-empty.tsx | 4 +- .../stories/utils/more-examples.tsx | 4 +- .../src/navigation/stories/utils/search.tsx | 4 +- .../navigator-provider/component.tsx | 1 - .../src/navigator/stories/index.story.tsx | 21 +- .../src/notice/stories/index.story.tsx | 14 +- .../number-control/stories/index.story.tsx | 8 +- .../src/palette-edit/stories/index.story.tsx | 8 +- .../components/src/palette-edit/styles.js | 1 - .../src/panel/stories/index.story.tsx | 22 +- .../src/placeholder/stories/index.story.tsx | 12 +- packages/components/src/popover/README.md | 4 +- packages/components/src/popover/index.tsx | 172 +- .../components/src/popover/limit-shift.ts | 205 -- .../src/popover/overlay-middlewares.tsx | 4 +- .../src/popover/stories/index.story.tsx | 18 +- .../components/src/popover/test/index.tsx | 16 +- packages/components/src/popover/types.ts | 6 + packages/components/src/popover/utils.ts | 61 +- .../src/progress-bar/stories/index.story.tsx | 12 +- .../components/src/progress-bar/styles.ts | 5 +- .../query-controls/stories/index.story.tsx | 13 +- .../src/radio-control/stories/index.story.tsx | 12 +- .../src/radio-group/stories/index.story.js | 1 + .../src/range-control/stories/index.story.tsx | 32 +- .../src/resizable-box/stories/index.story.tsx | 8 +- .../stories/index.story.tsx | 11 +- packages/components/src/sandbox/index.tsx | 5 +- .../src/sandbox/stories/index.story.tsx | 10 +- .../src/scroll-lock/stories/index.story.tsx | 8 +- .../src/scrollable/stories/index.story.tsx | 10 +- .../src/search-control/index.native.js | 66 +- .../search-control/stories/index.story.tsx | 8 +- .../select-control/stories/index.story.tsx | 8 +- packages/components/src/shortcut/index.tsx | 13 + .../src/shortcut/stories/index.story.tsx | 33 + packages/components/src/slot-fill/README.md | 10 +- .../bubbles-virtually/slot-fill-context.js | 3 + .../src/slot-fill/bubbles-virtually/slot.js | 22 +- packages/components/src/slot-fill/index.js | 7 +- .../src/slot-fill/stories/index.story.js | 4 +- .../slot-fill/test/__snapshots__/slot.js.snap | 16 +- .../src/snackbar/stories/index.story.tsx | 25 +- .../src/snackbar/stories/list.story.tsx | 8 +- .../src/spacer/stories/index.story.tsx | 10 +- packages/components/src/spinner/index.tsx | 1 - .../src/spinner/stories/index.story.tsx | 12 +- .../src/surface/stories/index.story.tsx | 10 +- .../src/tab-panel/stories/index.story.tsx | 20 +- .../components/src/tab-panel/test/index.tsx | 34 +- .../src/text-control/stories/index.story.tsx | 15 +- .../text-highlight/stories/index.story.tsx | 12 +- packages/components/src/text/test/index.tsx | 2 +- .../textarea-control/stories/index.story.tsx | 12 +- packages/components/src/theme/index.tsx | 1 - .../src/theme/stories/index.story.tsx | 14 +- .../src/tip/stories/index.story.tsx | 10 +- .../toggle-control/stories/index.story.tsx | 8 +- .../stories/index.story.tsx | 30 +- .../src/toolbar/stories/index.story.tsx | 18 +- .../src/tools-panel/stories/index.story.tsx | 31 +- .../tools-panel-header/component.tsx | 3 + .../src/tools-panel/tools-panel/component.tsx | 1 - .../src/tooltip/stories/index.story.js | 2 +- .../src/tree-grid/stories/index.story.tsx | 8 +- packages/components/src/tree-select/index.tsx | 1 - .../src/tree-select/stories/index.story.tsx | 8 +- .../src/truncate/stories/index.story.tsx | 14 +- .../components/src/ui/context/constants.js | 2 - .../components/src/ui/utils/get-high-dpi.ts | 20 - .../components/src/unit-control/index.tsx | 1 - .../src/unit-control/stories/index.story.tsx | 21 +- packages/components/src/utils/browsers.js | 36 - packages/components/src/utils/events.ts | 50 - packages/components/src/utils/hooks/use-cx.ts | 3 +- packages/components/src/utils/math.js | 11 - packages/components/src/utils/test/events.js | 63 - packages/components/src/utils/test/values.js | 101 - packages/components/src/utils/values.js | 81 - .../src/v-stack/stories/e2e/index.story.tsx | 8 +- .../src/v-stack/stories/index.story.tsx | 8 +- packages/components/src/view/component.tsx | 1 - .../src/view/stories/index.story.tsx | 10 +- .../visually-hidden/stories/index.story.tsx | 16 +- .../src/z-stack/stories/index.story.tsx | 10 +- .../src/hooks/use-fixed-window-list/index.js | 19 +- .../src/site-editor-navigation-commands.js | 145 +- .../lib/templates/block/view.js.mustache | 18 + .../components/sidebar-block-editor/index.js | 9 +- packages/customize-widgets/src/index.js | 2 +- .../customize-widgets/src/store/selectors.js | 2 +- .../src/admin/create-new-post.js | 22 +- .../src/admin/visit-site-editor.ts | 4 +- packages/e2e-test-utils/src/site-editor.js | 6 +- packages/e2e-tests/package.json | 4 +- .../directive-bind/render.php | 40 + .../interactive-blocks/directive-bind/view.js | 11 + .../directive-context/render.php | 13 + .../directive-context/view.js | 35 +- .../directive-key/block.json | 14 + .../directive-key/render.php | 18 + .../interactive-blocks/directive-key/view.js | 23 + .../directive-slots/block.json | 14 + .../directive-slots/render.php | 67 + .../directive-slots/view.js | 18 + .../router-regions/block.json | 14 + .../router-regions/render.php | 89 + .../interactive-blocks/router-regions/view.js | 43 + .../editor/various/shortcut-help.test.js | 47 - .../components/header/header-toolbar/index.js | 2 + .../edit-post/src/components/layout/index.js | 3 +- .../preferences-modal/test/index.js | 10 +- .../components/secondary-sidebar/style.scss | 3 +- .../sidebar/post-taxonomies/taxonomy-panel.js | 51 +- .../components/start-page-options/index.js | 92 +- .../src/components/visual-editor/index.js | 6 +- packages/edit-post/src/index.js | 2 +- .../plugins/copy-content-menu-item/index.js | 10 +- packages/edit-post/src/store/selectors.js | 2 +- .../edit-site/src/components/app/index.js | 3 +- .../block-editor/site-editor-canvas.js | 11 +- .../index.js | 4 +- .../style.scss | 6 +- .../edit-site/src/components/editor/index.js | 6 +- .../components/global-styles/screen-block.js | 14 + .../src/components/header-edit-mode/index.js | 71 +- .../more-menu/copy-content-menu-item.js | 41 +- .../keyboard-shortcuts/edit-mode.js | 32 +- .../src/components/page-patterns/grid-item.js | 6 +- .../src/components/page-patterns/style.scss | 6 +- .../page-panels/page-status.js | 55 +- .../sidebar-edit-mode/page-panels/style.scss | 9 + .../index.js | 41 +- .../more-menu.js | 3 +- .../convert-to-template-part.js | 2 + .../src/hooks/commands/use-common-commands.js | 22 - .../hooks/commands/use-edit-mode-commands.js | 75 +- packages/edit-site/src/index.js | 2 +- packages/edit-site/src/store/actions.js | 77 +- packages/edit-site/src/store/test/actions.js | 88 + packages/edit-site/src/store/test/reducer.js | 31 +- packages/edit-site/src/style.scss | 2 +- .../block-editor => utils}/constants.js | 0 .../keyboard-shortcut-help-modal/style.scss | 5 - .../src/components/layout/index.js | 2 - .../index.js | 5 +- .../index.js | 2 - packages/edit-widgets/src/index.js | 2 +- packages/edit-widgets/src/store/selectors.js | 2 +- .../hooks/use-is-dirty.js | 36 +- .../configs/recommended-with-formatting.js | 1 + packages/format-library/src/language/index.js | 1 - packages/format-library/src/link/index.js | 4 + packages/icons/CHANGELOG.md | 4 + packages/icons/src/library/align-justify.js | 2 +- packages/icons/src/library/custom-link.js | 2 +- packages/icons/src/library/map-marker.js | 2 +- packages/icons/src/library/post-content.js | 2 +- packages/icons/src/library/title.js | 2 +- packages/interactivity/CHANGELOG.md | 11 + .../interactivity/docs/2-api-reference.md | 28 +- packages/interactivity/src/directives.js | 152 +- packages/interactivity/src/hooks.js | 1 + packages/interactivity/src/hydration.js | 22 - packages/interactivity/src/index.js | 9 +- packages/interactivity/src/router.js | 127 ++ packages/interactivity/src/slots.js | 38 + packages/jest-console/package.json | 2 +- packages/jest-preset-default/package.json | 2 +- .../scripts/setup-globals.js | 3 + .../nux/src/components/dot-tip/test/index.js | 42 +- .../src/components/pattern-convert-button.js | 7 +- .../src/horizontal-rule/index.native.js | 14 +- .../src/horizontal-rule/styles.native.scss | 9 +- packages/react-native-aztec/package.json | 2 +- packages/react-native-aztec/src/AztecView.js | 6 +- packages/react-native-bridge/package.json | 2 +- packages/react-native-editor/CHANGELOG.md | 18 +- .../helpers/appium-local-start.js | 12 +- .../__device-tests__/pages/editor-page.js | 1 + packages/react-native-editor/ios/Podfile.lock | 8 +- packages/react-native-editor/package.json | 3 +- packages/report-flaky-tests/package.json | 2 +- .../rich-text/src/component/use-anchor.js | 4 +- .../rich-text/src/register-format-type.js | 18 +- packages/rich-text/src/types.ts | 6 +- packages/scripts/config/webpack.config.js | 5 + packages/scripts/package.json | 8 +- packages/url/src/test/fixtures/wpt-data.json | 2 +- packages/warning/README.md | 2 +- packages/warning/babel-plugin.js | 32 +- packages/warning/src/index.js | 6 +- packages/warning/src/test/index.js | 15 +- packages/warning/test/babel-plugin.js | 22 +- patches/react-native+0.71.11.patch | 12 + phpcs.xml.dist | 55 + phpunit.xml.dist | 3 +- phpunit/blocks/render-post-template-test.php | 86 + phpunit/bootstrap.php | 2 + .../class-wp-font-family-test.php | 340 --- .../class-wp-fonts-library-test.php | 52 - phpunit/multisite.xml | 3 +- .../fonts-api/base.php} | 2 +- .../fonts-api/bc-layer/base.php} | 2 +- .../bc-layer/bc-layer-tests-dataset.php | 0 .../isDeprecatedStructure.php} | 2 +- .../migrateDeprecatedStructure.php} | 2 +- .../bc-layer/wpRegisterWebfonts.php} | 2 +- .../bc-layer/wpWebfonts/getAllWebfonts.php} | 2 +- .../bc-layer/wpWebfonts/getFontSlug.php} | 2 +- .../wpWebfonts/getRegisteredWebfonts.php} | 2 +- .../bc-layer/wpWebfonts/registerWebfont.php} | 2 +- .../fonts-api/wp-fonts-tests-dataset.php | 0 .../fonts-api/wpDeregisterFontFamily.php} | 2 +- .../fonts-api/wpDeregisterFontVariation.php} | 2 +- .../fonts-api/wpEnqueueFontVariations.php} | 2 +- .../fonts-api/wpEnqueueFonts.php} | 2 +- .../fonts-api/wpFonts.php} | 2 +- .../fonts-api/wpFonts/add.php} | 2 +- .../fonts-api/wpFonts/addFontFamily.php} | 2 +- .../fonts-api/wpFonts/addVariation.php} | 2 +- .../fonts-api/wpFonts/dequeue.php} | 2 +- .../fonts-api/wpFonts/doItem.php} | 2 +- .../fonts-api/wpFonts/doItems.php} | 4 +- .../fonts-api/wpFonts/enqueue.php} | 2 +- .../fonts-api/wpFonts/getEnqueued.php} | 2 +- .../fonts-api/wpFonts/getProviders.php} | 4 +- .../fonts-api/wpFonts/getRegistered.php} | 2 +- .../fonts-api/wpFonts/query.php} | 2 +- .../fonts-api/wpFonts/registerProvider.php} | 4 +- .../fonts-api/wpFonts/remove.php} | 2 +- .../fonts-api/wpFonts/removeFontFamily.php} | 2 +- .../fonts-api/wpFonts/removeVariation.php} | 2 +- .../fonts-api/wpFontsProviderLocal.php} | 4 +- .../addMissingFontsToThemeJson.php} | 2 +- .../enqueueUserSelectedFonts.php} | 2 +- .../registerFontsFromThemeJson.php} | 2 +- .../convertFontFamilyIntoHandle.php} | 2 +- .../convertVariationIntoHandle.php} | 2 +- .../getFontFamilyFromVariation.php} | 2 +- .../fonts-api/wpFontsUtils/isDefined.php} | 2 +- .../fonts-api/wpPrintFonts.php} | 4 +- .../fonts-api/wpRegisterFontProvider.php} | 4 +- .../fonts-api/wpRegisterFonts.php} | 2 +- .../fonts/font-face/base.php} | 2 +- .../font-face}/wp-font-face-tests-dataset.php | 0 .../wpFontFace/generateAndPrint.php} | 12 +- .../getFontsFromThemeJson.php} | 12 +- .../fonts/font-face/wpPrintFontFaces.php} | 12 +- ...class-wp-rest-font-library-controller.php} | 74 +- .../font-library/wpFontFamily/__construct.php | 62 + .../fonts/font-library/wpFontFamily/base.php | 75 + .../font-library/wpFontFamily/getData.php | 94 + .../wpFontFamily/getDataAsJson.php | 67 + .../font-library/wpFontFamily/getFontPost.php | 42 + .../wpFontFamily/hasFontFaces.php | 78 + .../font-library/wpFontFamily/install.php | 248 +++ .../font-library/wpFontFamily/uninstall.php | 194 ++ .../getFilenameFromFontFace.php | 64 + .../wpFontFamilyUtils/hasFontMimeType.php | 61 + .../wpFontFamilyUtils/mergeFontsData.php} | 190 +- .../wpFontLibrary/getFontsDir.php | 18 + .../wpFontLibrary/setUploadDir.php | 30 + storybook/preview.js | 27 + storybook/stories/playground/index.story.js | 45 +- test/e2e/playwright.config.ts | 2 +- .../editor/plugins/wp-editor-meta-box.spec.js | 2 +- .../specs/editor/various/list-view.spec.js | 27 +- .../editor/various/shortcut-help.spec.js | 42 + .../interactivity/directive-bind.spec.ts | 167 +- .../specs/interactivity/directive-key.spec.ts | 34 + .../interactivity/directive-slots.spec.ts | 186 ++ .../interactivity/directives-context.spec.ts | 27 + .../fixtures/interactivity-utils.ts | 21 +- .../interactivity/router-regions.spec.ts | 100 + test/e2e/specs/site-editor/pages.spec.js | 2 +- test/e2e/specs/site-editor/style-book.spec.js | 2 +- .../core__query-pagination-numbers.json | 4 +- .../fixtures/blocks/core__query.json | 3 +- .../blocks/core__query__deprecated-3.json | 4 +- .../helpers/integration-test-editor.js | 36 +- .../specs/front-end-block-theme.spec.js | 8 +- test/performance/specs/post-editor.spec.js | 40 +- test/performance/specs/site-editor.spec.js | 6 +- .../ValidBlockLibraryFunctionNameSniff.php | 173 ++ .../Gutenberg/ruleset.xml | 1 + tools/webpack/shared.js | 2 + typings/gutenberg-env/index.d.ts | 2 + 507 files changed, 9695 insertions(+), 6085 deletions(-) create mode 100644 docs/how-to-guides/enqueueing-assets-in-the-editor.md create mode 100644 lib/compat/wordpress-6.4/block-patterns.php rename lib/{experimental/fonts => compat/wordpress-6.4/fonts/font-face}/class-wp-font-face-resolver.php (95%) rename lib/{experimental/fonts => compat/wordpress-6.4/fonts/font-face}/class-wp-font-face.php (96%) rename lib/{experimental => compat/wordpress-6.4}/fonts/fonts.php (51%) create mode 100644 lib/compat/wordpress-6.4/script-loader.php rename lib/experimental/fonts/{ => font-face}/bc-layer/class-gutenberg-fonts-api-bc-layer.php (100%) rename lib/experimental/fonts/{ => font-face}/bc-layer/class-wp-fonts-provider-local.php (100%) rename lib/experimental/fonts/{ => font-face}/bc-layer/class-wp-fonts-provider.php (100%) rename lib/experimental/fonts/{ => font-face}/bc-layer/class-wp-fonts-resolver.php (100%) rename lib/experimental/fonts/{ => font-face}/bc-layer/class-wp-fonts-utils.php (100%) rename lib/experimental/fonts/{ => font-face}/bc-layer/class-wp-fonts.php (100%) rename lib/experimental/fonts/{ => font-face}/bc-layer/class-wp-web-fonts.php (100%) rename lib/experimental/fonts/{ => font-face}/bc-layer/class-wp-webfonts-provider-local.php (100%) rename lib/experimental/fonts/{ => font-face}/bc-layer/class-wp-webfonts-provider.php (100%) rename lib/experimental/fonts/{ => font-face}/bc-layer/class-wp-webfonts-utils.php (100%) rename lib/experimental/fonts/{ => font-face}/bc-layer/class-wp-webfonts.php (100%) rename lib/experimental/fonts/{ => font-face}/bc-layer/webfonts-deprecations.php (98%) rename lib/experimental/{fonts-library => fonts/font-library}/class-wp-font-family-utils.php (90%) rename lib/experimental/{fonts-library => fonts/font-library}/class-wp-font-family.php (95%) rename lib/experimental/{fonts-library/class-wp-fonts-library.php => fonts/font-library/class-wp-font-library.php} (85%) rename lib/experimental/{fonts-library/class-wp-rest-fonts-library-controller.php => fonts/font-library/class-wp-rest-font-library-controller.php} (87%) rename lib/experimental/{fonts-library/fonts-library.php => fonts/font-library/font-library.php} (66%) delete mode 100644 packages/block-editor/src/components/url-popover/test/__snapshots__/index.js.snap delete mode 100644 packages/block-editor/src/components/url-popover/test/index.js create mode 100644 packages/block-editor/src/hooks/auto-inserting-blocks.js delete mode 100644 packages/block-editor/src/utils/pre-parse-patterns.js create mode 100644 packages/block-library/src/footnotes/init.js create mode 100644 packages/block-library/src/query/style.scss create mode 100644 packages/block-library/src/query/view.js delete mode 100644 packages/block-library/src/social-link/test/index.native.js create mode 100644 packages/blocks/src/store/private-actions.js create mode 100644 packages/blocks/src/store/process-block-type.js create mode 100644 packages/components/src/color-picker/hsv-color-picker.native.js create mode 100644 packages/components/src/color-picker/hue-picker.native.js create mode 100644 packages/components/src/color-picker/saturation-picker.native.js create mode 100644 packages/components/src/menu-item/stories/index.story.tsx delete mode 100644 packages/components/src/popover/limit-shift.ts create mode 100644 packages/components/src/shortcut/stories/index.story.tsx delete mode 100644 packages/components/src/ui/utils/get-high-dpi.ts delete mode 100644 packages/components/src/utils/browsers.js delete mode 100644 packages/components/src/utils/events.ts delete mode 100644 packages/components/src/utils/test/events.js delete mode 100644 packages/components/src/utils/test/values.js create mode 100644 packages/e2e-tests/plugins/interactive-blocks/directive-key/block.json create mode 100644 packages/e2e-tests/plugins/interactive-blocks/directive-key/render.php create mode 100644 packages/e2e-tests/plugins/interactive-blocks/directive-key/view.js create mode 100644 packages/e2e-tests/plugins/interactive-blocks/directive-slots/block.json create mode 100644 packages/e2e-tests/plugins/interactive-blocks/directive-slots/render.php create mode 100644 packages/e2e-tests/plugins/interactive-blocks/directive-slots/view.js create mode 100644 packages/e2e-tests/plugins/interactive-blocks/router-regions/block.json create mode 100644 packages/e2e-tests/plugins/interactive-blocks/router-regions/render.php create mode 100644 packages/e2e-tests/plugins/interactive-blocks/router-regions/view.js delete mode 100644 packages/e2e-tests/specs/editor/various/shortcut-help.test.js rename packages/edit-site/src/components/{canvas-spinner => canvas-loader}/index.js (90%) rename packages/edit-site/src/components/{canvas-spinner => canvas-loader}/style.scss (66%) rename packages/edit-site/src/{components/block-editor => utils}/constants.js (100%) delete mode 100644 packages/interactivity/src/hydration.js create mode 100644 packages/interactivity/src/router.js create mode 100644 packages/interactivity/src/slots.js create mode 100644 patches/react-native+0.71.11.patch delete mode 100644 phpunit/fonts-library/class-wp-font-family-test.php delete mode 100644 phpunit/fonts-library/class-wp-fonts-library-test.php rename phpunit/{fonts-api/wp-fonts-testcase.php => tests/fonts-api/base.php} (99%) rename phpunit/{fonts-api/bc-layer/fonts-bc-layer-testcase.php => tests/fonts-api/bc-layer/base.php} (94%) rename phpunit/{ => tests}/fonts-api/bc-layer/bc-layer-tests-dataset.php (100%) rename phpunit/{fonts-api/bc-layer/gutenbergFontsApiBcLayer/isDeprecatedStructure-test.php => tests/fonts-api/bc-layer/gutenbergFontsApiBcLayer/isDeprecatedStructure.php} (94%) rename phpunit/{fonts-api/bc-layer/gutenbergFontsApiBcLayer/migrateDeprecatedStructure-test.php => tests/fonts-api/bc-layer/gutenbergFontsApiBcLayer/migrateDeprecatedStructure.php} (95%) rename phpunit/{fonts-api/bc-layer/wpRegisterWebfonts-test.php => tests/fonts-api/bc-layer/wpRegisterWebfonts.php} (97%) rename phpunit/{fonts-api/bc-layer/wpWebfonts/getAllWebfonts-test.php => tests/fonts-api/bc-layer/wpWebfonts/getAllWebfonts.php} (93%) rename phpunit/{fonts-api/bc-layer/wpWebfonts/getFontSlug-test.php => tests/fonts-api/bc-layer/wpWebfonts/getFontSlug.php} (98%) rename phpunit/{fonts-api/bc-layer/wpWebfonts/getRegisteredWebfonts-test.php => tests/fonts-api/bc-layer/wpWebfonts/getRegisteredWebfonts.php} (93%) rename phpunit/{fonts-api/bc-layer/wpWebfonts/registerWebfont-test.php => tests/fonts-api/bc-layer/wpWebfonts/registerWebfont.php} (98%) rename phpunit/{ => tests}/fonts-api/wp-fonts-tests-dataset.php (100%) rename phpunit/{fonts-api/wpDeregisterFontFamily-test.php => tests/fonts-api/wpDeregisterFontFamily.php} (98%) rename phpunit/{fonts-api/wpDeregisterFontVariation-test.php => tests/fonts-api/wpDeregisterFontVariation.php} (99%) rename phpunit/{fonts-api/wpEnqueueFontVariations-test.php => tests/fonts-api/wpEnqueueFontVariations.php} (98%) rename phpunit/{fonts-api/wpEnqueueFonts-test.php => tests/fonts-api/wpEnqueueFonts.php} (98%) rename phpunit/{fonts-api/wpFonts-test.php => tests/fonts-api/wpFonts.php} (94%) rename phpunit/{fonts-api/wpFonts/add-test.php => tests/fonts-api/wpFonts/add.php} (95%) rename phpunit/{fonts-api/wpFonts/addFontFamily-test.php => tests/fonts-api/wpFonts/addFontFamily.php} (97%) rename phpunit/{fonts-api/wpFonts/addVariation-test.php => tests/fonts-api/wpFonts/addVariation.php} (99%) rename phpunit/{fonts-api/wpFonts/dequeue-test.php => tests/fonts-api/wpFonts/dequeue.php} (97%) rename phpunit/{fonts-api/wpFonts/doItem-test.php => tests/fonts-api/wpFonts/doItem.php} (99%) rename phpunit/{fonts-api/wpFonts/doItems-test.php => tests/fonts-api/wpFonts/doItems.php} (98%) rename phpunit/{fonts-api/wpFonts/enqueue-test.php => tests/fonts-api/wpFonts/enqueue.php} (97%) rename phpunit/{fonts-api/wpFonts/getEnqueued-test.php => tests/fonts-api/wpFonts/getEnqueued.php} (96%) rename phpunit/{fonts-api/wpFonts/getProviders-test.php => tests/fonts-api/wpFonts/getProviders.php} (93%) rename phpunit/{fonts-api/wpFonts/getRegistered-test.php => tests/fonts-api/wpFonts/getRegistered.php} (97%) rename phpunit/{fonts-api/wpFonts/query-test.php => tests/fonts-api/wpFonts/query.php} (98%) rename phpunit/{fonts-api/wpFonts/registerProvider-test.php => tests/fonts-api/wpFonts/registerProvider.php} (96%) rename phpunit/{fonts-api/wpFonts/remove-test.php => tests/fonts-api/wpFonts/remove.php} (97%) rename phpunit/{fonts-api/wpFonts/removeFontFamily-test.php => tests/fonts-api/wpFonts/removeFontFamily.php} (98%) rename phpunit/{fonts-api/wpFonts/removeVariation-test.php => tests/fonts-api/wpFonts/removeVariation.php} (99%) rename phpunit/{fonts-api/wpFontsProviderLocal-test.php => tests/fonts-api/wpFontsProviderLocal.php} (97%) rename phpunit/{fonts-api/wpFontsResolver/addMissingFontsToThemeJson-test.php => tests/fonts-api/wpFontsResolver/addMissingFontsToThemeJson.php} (99%) rename phpunit/{fonts-api/wpFontsResolver/enqueueUserSelectedFonts-test.php => tests/fonts-api/wpFontsResolver/enqueueUserSelectedFonts.php} (98%) rename phpunit/{fonts-api/wpFontsResolver/registerFontsFromThemeJson-test.php => tests/fonts-api/wpFontsResolver/registerFontsFromThemeJson.php} (99%) rename phpunit/{fonts-api/wpFontsUtils/convertFontFamilyIntoHandle-test.php => tests/fonts-api/wpFontsUtils/convertFontFamilyIntoHandle.php} (97%) rename phpunit/{fonts-api/wpFontsUtils/convertVariationIntoHandle-test.php => tests/fonts-api/wpFontsUtils/convertVariationIntoHandle.php} (98%) rename phpunit/{fonts-api/wpFontsUtils/getFontFamilyFromVariation-test.php => tests/fonts-api/wpFontsUtils/getFontFamilyFromVariation.php} (98%) rename phpunit/{fonts-api/wpFontsUtils/isDefined-test.php => tests/fonts-api/wpFontsUtils/isDefined.php} (96%) rename phpunit/{fonts-api/wpPrintFonts-test.php => tests/fonts-api/wpPrintFonts.php} (98%) rename phpunit/{fonts-api/wpRegisterFontProvider-test.php => tests/fonts-api/wpRegisterFontProvider.php} (95%) rename phpunit/{fonts-api/wpRegisterFonts-test.php => tests/fonts-api/wpRegisterFonts.php} (98%) rename phpunit/{fonts/wp-font-face-testcase.php => tests/fonts/font-face/base.php} (98%) rename phpunit/{fonts => tests/fonts/font-face}/wp-font-face-tests-dataset.php (100%) rename phpunit/{fonts/wpFontFace/generateAndPrint-test.php => tests/fonts/font-face/wpFontFace/generateAndPrint.php} (70%) rename phpunit/{fonts/wpFontFaceResolver/getFontsFromThemeJson-test.php => tests/fonts/font-face/wpFontFaceResolver/getFontsFromThemeJson.php} (87%) rename phpunit/{fonts/wpPrintFontFaces-test.php => tests/fonts/font-face/wpPrintFontFaces.php} (76%) rename phpunit/{fonts-library/class-wp-rest-fonts-library-controller-test.php => tests/fonts/font-library/class-wp-rest-font-library-controller.php} (85%) create mode 100644 phpunit/tests/fonts/font-library/wpFontFamily/__construct.php create mode 100644 phpunit/tests/fonts/font-library/wpFontFamily/base.php create mode 100644 phpunit/tests/fonts/font-library/wpFontFamily/getData.php create mode 100644 phpunit/tests/fonts/font-library/wpFontFamily/getDataAsJson.php create mode 100644 phpunit/tests/fonts/font-library/wpFontFamily/getFontPost.php create mode 100644 phpunit/tests/fonts/font-library/wpFontFamily/hasFontFaces.php create mode 100644 phpunit/tests/fonts/font-library/wpFontFamily/install.php create mode 100644 phpunit/tests/fonts/font-library/wpFontFamily/uninstall.php create mode 100644 phpunit/tests/fonts/font-library/wpFontFamilyUtils/getFilenameFromFontFace.php create mode 100644 phpunit/tests/fonts/font-library/wpFontFamilyUtils/hasFontMimeType.php rename phpunit/{fonts-library/class-wp-font-family-utils-test.php => tests/fonts/font-library/wpFontFamilyUtils/mergeFontsData.php} (59%) create mode 100644 phpunit/tests/fonts/font-library/wpFontLibrary/getFontsDir.php create mode 100644 phpunit/tests/fonts/font-library/wpFontLibrary/setUploadDir.php create mode 100644 test/e2e/specs/editor/various/shortcut-help.spec.js create mode 100644 test/e2e/specs/interactivity/directive-key.spec.ts create mode 100644 test/e2e/specs/interactivity/directive-slots.spec.ts create mode 100644 test/e2e/specs/interactivity/router-regions.spec.ts create mode 100644 test/php/gutenberg-coding-standards/Gutenberg/Sniffs/NamingConventions/ValidBlockLibraryFunctionNameSniff.php diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS index a324657fad6f7..22404fc7c96eb 100644 --- a/.github/CODEOWNERS +++ b/.github/CODEOWNERS @@ -1,5 +1,6 @@ # Documentation /docs @ajitbohra @ryanwelcher @juanmaguitar @fabiankaegy @ndiego +/packages/interactivity/docs @juanmaguitar # Schemas /schemas/json @ajlende diff --git a/.github/workflows/enforce-pr-labels.yml b/.github/workflows/enforce-pr-labels.yml index be2e46af5b55f..6dc9cb6b17add 100644 --- a/.github/workflows/enforce-pr-labels.yml +++ b/.github/workflows/enforce-pr-labels.yml @@ -1,7 +1,7 @@ name: Enforce labels on Pull Request on: pull_request_target: - types: [opened, labeled, unlabeled, synchronize] + types: [labeled, unlabeled, ready_for_review, review_requested] jobs: type-related-labels: runs-on: ubuntu-latest diff --git a/.github/workflows/publish-npm-packages.yml b/.github/workflows/publish-npm-packages.yml index 1832625466cae..dd1f188e0ae2f 100644 --- a/.github/workflows/publish-npm-packages.yml +++ b/.github/workflows/publish-npm-packages.yml @@ -32,7 +32,7 @@ jobs: - name: Checkout (for CLI) uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3 with: - path: main + path: cli ref: trunk - name: Checkout (for publishing) @@ -52,13 +52,13 @@ jobs: - name: Setup Node.js uses: actions/setup-node@64ed1c7eab4cce3362f8c340dee64e5eaeef8f7c # v3.6.0 with: - node-version-file: 'main/.nvmrc' + node-version-file: 'cli/.nvmrc' registry-url: 'https://registry.npmjs.org' - name: Publish development packages to npm ("next" dist-tag) if: ${{ github.event.inputs.release_type == 'development' }} run: | - cd main + cd cli npm ci ./bin/plugin/cli.js npm-next --ci --repository-path ../publish env: @@ -67,7 +67,7 @@ jobs: - name: Publish packages to npm with bug fixes ("latest" dist-tag) if: ${{ github.event.inputs.release_type == 'bugfix' }} run: | - cd main + cd cli npm ci ./bin/plugin/cli.js npm-bugfix --ci --repository-path ../publish env: @@ -76,8 +76,8 @@ jobs: - name: Publish packages to npm for WP major ("wp/${{ github.event.inputs.wp_version || 'X.Y' }}" dist-tag) if: ${{ github.event.inputs.release_type == 'wp' && github.event.inputs.wp_version }} run: | - cd main + cd publish npm ci - ./bin/plugin/cli.js npm-wp --wp-version=${{ github.event.inputs.wp_version }} --ci --repository-path ../publish + npx lerna publish patch --dist-tag wp-${{ github.event.inputs.wp_version }} --no-private --yes --no-verify-access env: NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} diff --git a/bin/plugin/commands/packages.js b/bin/plugin/commands/packages.js index c085201a23500..87ecc6eb89cfc 100644 --- a/bin/plugin/commands/packages.js +++ b/bin/plugin/commands/packages.js @@ -25,6 +25,7 @@ const { findPluginReleaseBranchName, } = require( './common' ); const { join } = require( 'path' ); +const pluginConfig = require( '../config' ); /** * Release type names. @@ -99,7 +100,7 @@ async function checkoutNpmReleaseBranch( { * `trunk` commits from within the past week. */ await SimpleGit( gitWorkingDirectoryPath ) - .fetch( npmReleaseBranch, [ '--depth=100' ] ) + .fetch( 'origin', npmReleaseBranch, [ '--depth=100' ] ) .checkout( npmReleaseBranch ); log( '>> The local npm release branch ' + @@ -411,13 +412,27 @@ async function publishPackagesToNpm( { ); } else if ( [ 'bugfix', 'wp' ].includes( releaseType ) ) { log( '>> Publishing modified packages to npm.' ); - await command( - `npx lerna publish ${ minimumVersionBump } --dist-tag ${ distTag } --no-private ${ yesFlag } ${ noVerifyAccessFlag }`, - { - cwd: gitWorkingDirectoryPath, - stdio: 'inherit', - } - ); + try { + await command( + `npx lerna publish ${ minimumVersionBump } --dist-tag ${ distTag } --no-private ${ yesFlag } ${ noVerifyAccessFlag }`, + { + cwd: gitWorkingDirectoryPath, + stdio: 'inherit', + } + ); + } catch { + log( + '>> Trying to finish failed publishing of modified npm packages.' + ); + await SimpleGit( gitWorkingDirectoryPath ).reset( 'hard' ); + await command( + `npx lerna publish from-package --dist-tag ${ distTag } ${ yesFlag } ${ noVerifyAccessFlag }`, + { + cwd: gitWorkingDirectoryPath, + stdio: 'inherit', + } + ); + } } else { log( '>> Bumping version of public packages changed since the last release.' @@ -431,13 +446,27 @@ async function publishPackagesToNpm( { ); log( '>> Publishing modified packages to npm.' ); - await command( - `npx lerna publish from-package ${ yesFlag } ${ noVerifyAccessFlag }`, - { - cwd: gitWorkingDirectoryPath, - stdio: 'inherit', - } - ); + try { + await command( + `npx lerna publish from-package ${ yesFlag } ${ noVerifyAccessFlag }`, + { + cwd: gitWorkingDirectoryPath, + stdio: 'inherit', + } + ); + } catch { + log( + '>> Trying to finish failed publishing of modified npm packages.' + ); + await SimpleGit( gitWorkingDirectoryPath ).reset( 'hard' ); + await command( + `npx lerna publish from-package ${ yesFlag } ${ noVerifyAccessFlag }`, + { + cwd: gitWorkingDirectoryPath, + stdio: 'inherit', + } + ); + } } const afterCommitHash = await SimpleGit( gitWorkingDirectoryPath ).revparse( @@ -530,7 +559,11 @@ async function runPackagesRelease( config, customMessages ) { config.abortMessage, async () => { log( '>> Cloning the Git repository' ); - await SimpleGit( gitPath ).clone( config.gitRepositoryURL ); + await SimpleGit().clone( + pluginConfig.gitRepositoryURL, + gitPath, + [ '--depth=1', '--no-single-branch' ] + ); log( ` >> successfully clone into: ${ gitPath }` ); } ); diff --git a/changelog.txt b/changelog.txt index fdf70081364e9..0f4f5bcf9bbcf 100644 --- a/changelog.txt +++ b/changelog.txt @@ -1,6 +1,277 @@ == Changelog == -= 16.5.0-rc.1 = += 16.6.0-rc.1 = + +## Changelog + +### Features + +#### Interactivity API +- Add Slot and Fill directives. ([53958](https://github.com/WordPress/gutenberg/pull/53958)) +- Query block: Client-side pagination. ([53812](https://github.com/WordPress/gutenberg/pull/53812)) +- Update `data-wp-bind` directive logic. ([54003](https://github.com/WordPress/gutenberg/pull/54003)) + + +### Enhancements + +- Bundle ObserveTyping within the BlockList component. ([53875](https://github.com/WordPress/gutenberg/pull/53875)) +- Default appender: Hide the dashed indicator until ancestor is selected. ([53761](https://github.com/WordPress/gutenberg/pull/53761)) +- Register the block editor keyboard shortcuts automatically when using BlockEditorProvider. ([53910](https://github.com/WordPress/gutenberg/pull/53910)) +- [Commands]: Add toggle list view command in site editor. ([53983](https://github.com/WordPress/gutenberg/pull/53983)) + +#### Components +- Bundle SlotFillProvider within BlockEditorProvider. ([53940](https://github.com/WordPress/gutenberg/pull/53940)) +- Make the Popover.Slot optional. ([53889](https://github.com/WordPress/gutenberg/pull/53889)) +- Popover: Update `@floating-ui` to latest version, remove custom fix for iframe positioning and scaling. ([46845](https://github.com/WordPress/gutenberg/pull/46845)) +- `AlignmentMatrixControl`: Replace `act()` with `userEvent`. ([53703](https://github.com/WordPress/gutenberg/pull/53703)) +- `ProgressBar`: Add transition to determinate indicator. ([53877](https://github.com/WordPress/gutenberg/pull/53877)) + +#### Block Library +- Blocks: Move bootstrapped block types to Redux state. ([53807](https://github.com/WordPress/gutenberg/pull/53807)) +- Capture toolbars in navigation block. ([53697](https://github.com/WordPress/gutenberg/pull/53697)) +- Content Block: Change placeholder and end-to-end test to refer to Content block. ([53902](https://github.com/WordPress/gutenberg/pull/53902)) +- Make mid size parameter settable for Query Pagination block. ([51216](https://github.com/WordPress/gutenberg/pull/51216)) + +#### Block Editor +- Capture toolbars in quote block. ([53699](https://github.com/WordPress/gutenberg/pull/53699)) +- Improve writing flow for lists by capturing list item toolbars. ([53306](https://github.com/WordPress/gutenberg/pull/53306)) +- RichTextValue: Typescript Adjustment. ([54002](https://github.com/WordPress/gutenberg/pull/54002)) + +#### Typography +- Font Face: Prepare for merge into Core. ([53858](https://github.com/WordPress/gutenberg/pull/53858)) +- Renames "Fonts Library" to "Font Library". ([53780](https://github.com/WordPress/gutenberg/pull/53780)) + +#### Post Editor +- Edit Post: Use hooks instead of HoCs in `TaxonomyPanel`. ([53773](https://github.com/WordPress/gutenberg/pull/53773)) + +#### List View +- Add keyboard shortcut for duplicating blocks. ([53559](https://github.com/WordPress/gutenberg/pull/53559)) + +#### Patterns +- Add a custom taxonomy for user created patterns. ([53163](https://github.com/WordPress/gutenberg/pull/53163)) + + +### New APIs + +#### Interactivity API +- Router with region-based client-side navigation. ([53733](https://github.com/WordPress/gutenberg/pull/53733)) + + +### Bug Fixes + +- Add missing aria roles for block locking toolbar and menu buttons. ([53734](https://github.com/WordPress/gutenberg/pull/53734)) +- Block Editor: Fix cleanup in the 'useNavModeExit' hook. ([53795](https://github.com/WordPress/gutenberg/pull/53795)) +- Command Palette: Fix crash on block-related commands. ([53923](https://github.com/WordPress/gutenberg/pull/53923)) +- Date: Add relative time translations for moment.js. ([53931](https://github.com/WordPress/gutenberg/pull/53931)) +- Date: Update translation domains for strings to be translatable. ([53995](https://github.com/WordPress/gutenberg/pull/53995)) +- Iframe: Set character encoding to utf-8. ([53519](https://github.com/WordPress/gutenberg/pull/53519)) +- Replace horizontal ellipsis icon with vertical ellipsis icon. ([52731](https://github.com/WordPress/gutenberg/pull/52731)) +- Toggle Distraction free mode mode based on compatibility. ([54030](https://github.com/WordPress/gutenberg/pull/54030)) +- Warning: Introduce `SCRIPT_DEBUG` to make the package compatible with webpack 5. ([50122](https://github.com/WordPress/gutenberg/pull/50122)) +- [Commands]: Fix `move to` command condition for registering. ([54049](https://github.com/WordPress/gutenberg/pull/54049)) +- [Commands]: Fix block editor commands availability. ([53994](https://github.com/WordPress/gutenberg/pull/53994)) +- [Format library]: Fix `language` popover position. ([53841](https://github.com/WordPress/gutenberg/pull/53841)) + +#### Block Library +- Add init.js module for the Footnotes block. ([53763](https://github.com/WordPress/gutenberg/pull/53763)) +- Adding center align css for social icon issue. ([43120](https://github.com/WordPress/gutenberg/pull/43120)) +- Cover block: Fix exception when adding video background. ([53961](https://github.com/WordPress/gutenberg/pull/53961)) +- List View: Allow replacing template part when a block isn't selected. ([53757](https://github.com/WordPress/gutenberg/pull/53757)) +- Post Navigation Link: Remove unnecessary space between arrows and label. ([53572](https://github.com/WordPress/gutenberg/pull/53572)) +- Search block: Fix width input field. ([53952](https://github.com/WordPress/gutenberg/pull/53952)) +- Simplify check for no posts in query-no-results block. ([53772](https://github.com/WordPress/gutenberg/pull/53772)) +- Site Logo: Remove line-height for the anchor element. ([53909](https://github.com/WordPress/gutenberg/pull/53909)) + +#### Components +- Always render the fallback Popover anchor within the Popover's parent element. ([53982](https://github.com/WordPress/gutenberg/pull/53982)) +- Fix the cleanup method for SandBox. ([53796](https://github.com/WordPress/gutenberg/pull/53796)) +- PaletteEdit: Fix component height. ([54000](https://github.com/WordPress/gutenberg/pull/54000)) + +#### Post Editor +- Edit Post: Fix tab border conflicts in the Document Overview panel. ([53711](https://github.com/WordPress/gutenberg/pull/53711)) +- EditPostPreferencesModal: Fix intermittently failing tests. ([53814](https://github.com/WordPress/gutenberg/pull/53814)) +- getInsertionPoint: Fix type check for the state value. ([53793](https://github.com/WordPress/gutenberg/pull/53793)) + +#### npm Packages +- Workflow: Run Learn directly from GitHub action when publishing to npm targeting WP core. ([53762](https://github.com/WordPress/gutenberg/pull/53762)) +- Workflows: Fix issues with the npm publishing workflow when using locally. ([53565](https://github.com/WordPress/gutenberg/pull/53565)) + +#### Themes +- Command Palette: Proper handling of page/post links in all themes. ([53718](https://github.com/WordPress/gutenberg/pull/53718)) +- Fix query loop bugs by correctly relying on the main query and removing problematic workaround. ([49904](https://github.com/WordPress/gutenberg/pull/49904)) + +#### Block Editor +- Fix: Indicator style when block moving mode. ([53972](https://github.com/WordPress/gutenberg/pull/53972)) + +#### Icons +- Fix invalid namespaces. ([53955](https://github.com/WordPress/gutenberg/pull/53955)) + +#### Patterns +- Disable the preview option button when editing. ([53913](https://github.com/WordPress/gutenberg/pull/53913)) + +#### Global Styles +- Gallery: Re-enable block spacing at block level while still hiding in global styles. ([53900](https://github.com/WordPress/gutenberg/pull/53900)) + +#### Layout +- BlockList: Ensure element styles (and svg) are always appended at the end of the document. ([53859](https://github.com/WordPress/gutenberg/pull/53859)) + +#### Interactivity API +- Add "supports.interactivity" to Image block. ([53850](https://github.com/WordPress/gutenberg/pull/53850)) + +#### Style Variations +- Block Styles: Fix misplaced preview popover on RTL site. ([53726](https://github.com/WordPress/gutenberg/pull/53726)) + +#### List View +- Recalculate window list when expanded state changes (fix logic for long nested lists). ([53716](https://github.com/WordPress/gutenberg/pull/53716)) + +#### Widgets Editor +- Block Widget: Fix content cutoff in the keyboard shortcut modal. ([53638](https://github.com/WordPress/gutenberg/pull/53638)) + +#### Rich Text +- Fix cleanup in `useRemoveBrowserShortcuts`. ([52225](https://github.com/WordPress/gutenberg/pull/52225)) + + +### Accessibility + +- Edit site: Add missing label to post status password protected input field. ([52885](https://github.com/WordPress/gutenberg/pull/52885)) +- [a11y] Fix: Aria-haspop, aria-expanded attributes on the link format button. ([53691](https://github.com/WordPress/gutenberg/pull/53691)) + +#### Site Editor +- Add missing aria roles to the 'Create template part' menu item. ([53754](https://github.com/WordPress/gutenberg/pull/53754)) +- Unify the delete button style in the dropdown menu with red. ([52597](https://github.com/WordPress/gutenberg/pull/52597)) + +#### Block Library +- Add missing aria roles to the 'Replace template part' menu item. ([53755](https://github.com/WordPress/gutenberg/pull/53755)) + +#### Patterns +- Add missing aria roles to the 'Create pattern' menu item. ([53739](https://github.com/WordPress/gutenberg/pull/53739)) + +#### List View +- [a11y] Fix: Aria-haspop and aria-expanded attributes on list view button. ([53693](https://github.com/WordPress/gutenberg/pull/53693)) + +#### Block Editor +- [a11y] Fix: Aria-haspop and aria-expanded attributes on the inserter button. ([53692](https://github.com/WordPress/gutenberg/pull/53692)) + + +### Performance + +- Revert "Switch performance tests to Playwright (#52022)". ([53741](https://github.com/WordPress/gutenberg/pull/53741)) +- StartPageOptions: Load and parse patterns only after establishing the need for them. ([53673](https://github.com/WordPress/gutenberg/pull/53673)) +- Switch performance tests to Playwright: Take 2. ([53768](https://github.com/WordPress/gutenberg/pull/53768)) + + +### Experiments + +#### Block API +- Auto-inserting blocks: Add block inspector panel. ([52969](https://github.com/WordPress/gutenberg/pull/52969)) + + +### Documentation + +- Add juanmaguitar as codeowner of /packages/interactivity/docs. ([53845](https://github.com/WordPress/gutenberg/pull/53845)) +- Add new How-to Guide for enqueueing assets in the Editor. ([53828](https://github.com/WordPress/gutenberg/pull/53828)) +- Adds example for useBlockProps hook. ([53646](https://github.com/WordPress/gutenberg/pull/53646)) +- Adds explanatory text to view.js template. ([53870](https://github.com/WordPress/gutenberg/pull/53870)) +- Clarification for `parent` and `ancestor` hierarchical relationships. ([53855](https://github.com/WordPress/gutenberg/pull/53855)) +- Docs: Extend the information about using `render` with `block.json`. ([53973](https://github.com/WordPress/gutenberg/pull/53973)) +- Docs: Remove duplicate sections from FAQ page. ([53830](https://github.com/WordPress/gutenberg/pull/53830)) +- Document the naming convention for `block-library` PHP functions. ([53777](https://github.com/WordPress/gutenberg/pull/53777)) +- Fix 'lerna' links in the release documentation. ([53770](https://github.com/WordPress/gutenberg/pull/53770)) +- Fix typo in code sample for Interactivity API. ([53916](https://github.com/WordPress/gutenberg/pull/53916)) +- MenuItem: Add Storybook stories. ([53613](https://github.com/WordPress/gutenberg/pull/53613)) +- Shortcut: Add Storybook stories. ([53627](https://github.com/WordPress/gutenberg/pull/53627)) +- Storybook: Add back subcomponents to props table. ([53751](https://github.com/WordPress/gutenberg/pull/53751)) +- Storybook: Fix default source visibility. ([53749](https://github.com/WordPress/gutenberg/pull/53749)) +- Storybook: Show main story before description. ([53753](https://github.com/WordPress/gutenberg/pull/53753)) +- Update local instructions on the dev env documentation. ([53924](https://github.com/WordPress/gutenberg/pull/53924)) +- Update the Block Variations API doc. ([53817](https://github.com/WordPress/gutenberg/pull/53817)) +- Update to node 16 and npm 8 in the getting started with code contribution doc. ([53912](https://github.com/WordPress/gutenberg/pull/53912)) +- docs: Fix report-flaky-test link. ([53848](https://github.com/WordPress/gutenberg/pull/53848)) + + +### Code Quality + +- Components: Update Popover per reviews. ([53907](https://github.com/WordPress/gutenberg/pull/53907)) +- Edit Site: Rename `CanvasSpinner` to `CanvasLoader`. ([53728](https://github.com/WordPress/gutenberg/pull/53728)) +- Enforce valid function names in the packages/block-library/src/*/*.php files. ([53438](https://github.com/WordPress/gutenberg/pull/53438)) +- Fonts Library: Update properties name from snake case to camel case to match the rest of the properties. ([53746](https://github.com/WordPress/gutenberg/pull/53746)) + +#### Post Editor +- Editor: Fix the 'useSelect' warning in the 'useIsDirty' hook. ([53759](https://github.com/WordPress/gutenberg/pull/53759)) +- Fix browser console error when changing device preview mode. ([53969](https://github.com/WordPress/gutenberg/pull/53969)) +- Refactor latest content selectors in 'CopyContentMenuItem' components. ([53676](https://github.com/WordPress/gutenberg/pull/53676)) + +#### Components +- Remove unnecessary utils. ([53679](https://github.com/WordPress/gutenberg/pull/53679)) +- SlotFill: Refactor ``. ([53272](https://github.com/WordPress/gutenberg/pull/53272)) +- Storybook: Update TypeScript types. ([53748](https://github.com/WordPress/gutenberg/pull/53748)) + +#### List View +- Fix warning error when the gallery block has the same image URLs. ([53809](https://github.com/WordPress/gutenberg/pull/53809)) + +#### Typography +- Font Face API: Use `gutenberg_get_global_settings` instead of private API. ([53805](https://github.com/WordPress/gutenberg/pull/53805)) + + +### Tools + +- Try: Change PR label enforcer automation not to work on draft PRs by default. ([53417](https://github.com/WordPress/gutenberg/pull/53417)) + +#### Testing +- Attempt to fix intermittent end-to-end test failure. ([53905](https://github.com/WordPress/gutenberg/pull/53905)) +- Fonts Library: Test improvements. ([53702](https://github.com/WordPress/gutenberg/pull/53702)) +- Make fonts test files use Core approach. ([53856](https://github.com/WordPress/gutenberg/pull/53856)) +- Migrate shortcut help end-to-end tests to Playwright. ([53832](https://github.com/WordPress/gutenberg/pull/53832)) +- Relocates Font Face and Fonts Library PHP files into Core's fonts directory. ([53747](https://github.com/WordPress/gutenberg/pull/53747)) +- `ColorPalette`: Refine test query. ([53704](https://github.com/WordPress/gutenberg/pull/53704)) +- end-to-end Playwright Utils: Automatically detect canvas type. ([53744](https://github.com/WordPress/gutenberg/pull/53744)) +- test: Automate mobile editor tests. ([53991](https://github.com/WordPress/gutenberg/pull/53991)) + +#### Build Tooling +- Update Jest to latest version, and use optimized JSDOM. ([53736](https://github.com/WordPress/gutenberg/pull/53736)) + +#### Plugin +- Backport themes `is_block_theme` collection param from core. ([53846](https://github.com/WordPress/gutenberg/pull/53846)) + + +## First time contributors + +The following PRs were merged by first time contributors: + +- @JEverhart383: Fix typo in code sample for Interactivity API. ([53916](https://github.com/WordPress/gutenberg/pull/53916)) +- @krokodok: Make mid size parameter settable for Query Pagination block. ([51216](https://github.com/WordPress/gutenberg/pull/51216)) +- @mklute101: Update local instructions on the dev env documentation. ([53924](https://github.com/WordPress/gutenberg/pull/53924)) + + +## Contributors + +The following contributors merged PRs in this release: + +@afercia @andrewserong @anton-vlasenko @bangank36 @brookewp @ciampo @colorful-tones @DAreRodz @dcalhoun @derekblank @ellatrix @felixarntz @geriux @glendaviesnz @gziolo @hellofromtonya @jasmussen @jblz @JEverhart383 @jordesign @jorgefilipecosta @jsnajdr @juanmaguitar @krokodok @luisherranz @Mamaduka @margolisj @matiasbenedetto @mburridge @mirka @mklute101 @mokagio @ndiego @ntsekouras @oandregal @ocean90 @ockham @priethor @ramonjd @richtabor @SiobhyB @Smit2808 @stokesman @t-hamano @torounit @tyxla @walbo @WunderBart @youknowriad + + += 16.5.1 = + + + +## Changelog + +### Bug Fixes + +#### Block Editor +- Pass entire link value on toggle of setting on Link Preview. ([53949](https://github.com/WordPress/gutenberg/pull/53949)) + + + + +## Contributors + +The following contributors merged PRs in this release: + +@getdave + + += 16.5.0 = @@ -13,166 +284,139 @@ ### Enhancements -#### Post Editor -- Command Palette: - - Add new block commands. ([52509](https://github.com/WordPress/gutenberg/pull/52509)) - - Add support for registering commands without icons. ([53647](https://github.com/WordPress/gutenberg/pull/53647)) - - Update the `Preview in a new tab` command to reuse the preview target tab when available. ([53242](https://github.com/WordPress/gutenberg/pull/53242)) - - Update command palette styling. ([53117](https://github.com/WordPress/gutenberg/pull/53117)) - - Improve command palette rendering on smaller viewports. ([53661](https://github.com/WordPress/gutenberg/pull/53661)) -- Replace `withPluginContext` in `PluginPostPublishPanel` ([53302](https://github.com/WordPress/gutenberg/pull/53302)) and `PluginPrePublishPanel` ([53304](https://github.com/WordPress/gutenberg/pull/53304)). -- Replace HoCs with hooks in: - - `PluginDocumentSettingPanel` ([53290](https://github.com/WordPress/gutenberg/pull/53290)) - - `PostPendingStatusCheck` ([53389](https://github.com/WordPress/gutenberg/pull/53389)) - - `PostPendingStatus` ([53387](https://github.com/WordPress/gutenberg/pull/53387)) -- Top-align Publish row in the post panel. ([53573](https://github.com/WordPress/gutenberg/pull/53573)) -- Dependencies: Bump `remove-accents` to 0.5.0. ([53420](https://github.com/WordPress/gutenberg/pull/53420)) +#### Commands +- Add block-related commands. ([52509](https://github.com/WordPress/gutenberg/pull/52509)) +- Add support for registering commands without icons. ([53647](https://github.com/WordPress/gutenberg/pull/53647)) +- Update the "Preview in a new tab" command to reuse the preview target tab when available. ([53242](https://github.com/WordPress/gutenberg/pull/53242)) +- Update command palette styling. ([53117](https://github.com/WordPress/gutenberg/pull/53117)) +- Improve command palette rendering on smaller viewports. ([53661](https://github.com/WordPress/gutenberg/pull/53661)) +- Tweak existing commands to establish consistency with command language. ([53496](https://github.com/WordPress/gutenberg/pull/53496)) +- End the command palette description with a period in the keyboard shortcut modal. ([53635](https://github.com/WordPress/gutenberg/pull/53635)) #### Components - Button: Remove default border from the destructive button. ([53607](https://github.com/WordPress/gutenberg/pull/53607)) - LineHeightControl: Allow for more granular control of decimal places. ([52902](https://github.com/WordPress/gutenberg/pull/52902)) - Snackbar: Design and motion improvements. ([53248](https://github.com/WordPress/gutenberg/pull/53248)) - Modal: - - Add `headerActions` prop to render buttons in the header. ([53328](https://github.com/WordPress/gutenberg/pull/53328)) - - Nuance outside interactions. ([52994](https://github.com/WordPress/gutenberg/pull/52994)) -- ProgressBar: - - Use gray 300 for track color. ([53349](https://github.com/WordPress/gutenberg/pull/53349)) - - Use the theme system accent for indicator color. ([53347](https://github.com/WordPress/gutenberg/pull/53347)) - - Use theme accent color variable. ([53632](https://github.com/WordPress/gutenberg/pull/53632)) -- Expose `Theme` via private APIs. ([53262](https://github.com/WordPress/gutenberg/pull/53262)) -- Move accent colors to theme context. ([53631](https://github.com/WordPress/gutenberg/pull/53631)) + - Add `headerActions` prop to enable buttons or other elements to be injected in the header. ([53328](https://github.com/WordPress/gutenberg/pull/53328)) + - Enhance overlay interactions, enabling outside interactions without dismissal. ([52994](https://github.com/WordPress/gutenberg/pull/52994)) +- ProgressBar: Update colors, including gray 300 for track color ([53349](https://github.com/WordPress/gutenberg/pull/53349)), theme system accent for indicator color ([53347](https://github.com/WordPress/gutenberg/pull/53347)), and the theme accent color variable. ([53632](https://github.com/WordPress/gutenberg/pull/53632)). #### Block Library -- Details block: Add accordion and toggle keywords. ([53501](https://github.com/WordPress/gutenberg/pull/53501)) - Column block: - - Add stretch alignment. ([53325](https://github.com/WordPress/gutenberg/pull/53325)) - - Exit on enter. ([53311](https://github.com/WordPress/gutenberg/pull/53311)) + - Add a `stretch` option to block's vertical alignment options. ([53325](https://github.com/WordPress/gutenberg/pull/53325)) + - Exit upon pressing enter in an empty paragraph at the end of the block. ([53311](https://github.com/WordPress/gutenberg/pull/53311)) - Classic block: Increase dimensions of modal and allow toggling fullscreen. ([53449](https://github.com/WordPress/gutenberg/pull/53449)) -- File block: Add spacing support. ([45107](https://github.com/WordPress/gutenberg/pull/45107)) -- Footnotes block: Add typography, dimensions, and border block supports. ([53044](https://github.com/WordPress/gutenberg/pull/53044)) +- Details block: + - Add `accordion` and `toggle` keywords to improve block's discoverability. ([53501](https://github.com/WordPress/gutenberg/pull/53501)) + - Add layout and block spacing options. ([53282](https://github.com/WordPress/gutenberg/pull/53282)) +- File block: Add block spacing options. ([45107](https://github.com/WordPress/gutenberg/pull/45107)) - Image block: Add aspect ratio support to lightbox. ([52765](https://github.com/WordPress/gutenberg/pull/52765)) +- Post Content block: Add color controls. ([51326](https://github.com/WordPress/gutenberg/pull/51326)) - Remove "post" from block titles. ([53492](https://github.com/WordPress/gutenberg/pull/53492)) #### Patterns -- Open detail view when duplicating pattern. ([53214](https://github.com/WordPress/gutenberg/pull/53214)) -- Prevent convert modal closing block options menu. ([53707](https://github.com/WordPress/gutenberg/pull/53707)) -- Skip migration logs in the Patterns screen. ([53626](https://github.com/WordPress/gutenberg/pull/53626)) +- Open detail view when duplicating a pattern. ([53214](https://github.com/WordPress/gutenberg/pull/53214)) +- Prevent the "create pattern" modal from closing the block options menu when it is closed. ([53707](https://github.com/WordPress/gutenberg/pull/53707)) +- Skip migration logs in the patterns screen. ([53626](https://github.com/WordPress/gutenberg/pull/53626)) +- Add missing full stop to string. ([53544](https://github.com/WordPress/gutenberg/pull/53544)) #### Global Styles -- Global styles revisions: Add a reset to default revision. ([52965](https://github.com/WordPress/gutenberg/pull/52965)) -- Global styles revisions: Reduce visibility check from 2 to 1 revision. ([53281](https://github.com/WordPress/gutenberg/pull/53281)) -- Post Content: Add color controls. ([51326](https://github.com/WordPress/gutenberg/pull/51326)) +- Add a reset to default global styles revision ([52965](https://github.com/WordPress/gutenberg/pull/52965)) and reduce visibility check from two to one revision ([53281](https://github.com/WordPress/gutenberg/pull/53281)). #### Media - Adjust size of image previews in list view. ([53649](https://github.com/WordPress/gutenberg/pull/53649)) -- List View: Add media previews to list view for gallery and image blocks. ([53381](https://github.com/WordPress/gutenberg/pull/53381)) +- Add media previews to list view for gallery and image blocks. ([53381](https://github.com/WordPress/gutenberg/pull/53381)) #### Site Editor -- Command Palette: Order template results in Site Editor. ([53286](https://github.com/WordPress/gutenberg/pull/53286)) -- Edit Site: Use progress bar for loading screen. ([53032](https://github.com/WordPress/gutenberg/pull/53032)) - -#### Data Layer -- Data: Warn if the 'useSelect' hook returns different values when called with the same state and parameters. ([53666](https://github.com/WordPress/gutenberg/pull/53666)) +- Expose `Theme` via private APIs ([53262](https://github.com/WordPress/gutenberg/pull/53262)), which was necessary to use the progress bar component for the site editor loading screen ([53032](https://github.com/WordPress/gutenberg/pull/53032)). #### Block Editor - Add `Opens in new Tab` control into Link Preview. ([53566](https://github.com/WordPress/gutenberg/pull/53566)) - -#### Interactivity API -- Update deepsignal version. ([53549](https://github.com/WordPress/gutenberg/pull/53549)) - -#### Code Editor -- Tweak, and add, more consistent commands. ([53496](https://github.com/WordPress/gutenberg/pull/53496)) - -#### Themes +- Dependencies: Bump `remove-accents` to 0.5.0. ([53420](https://github.com/WordPress/gutenberg/pull/53420)) +- Top-align Publish row in the post panel. ([53573](https://github.com/WordPress/gutenberg/pull/53573)) - Allow layout controls to be disabled per block from theme.json. ([53378](https://github.com/WordPress/gutenberg/pull/53378)) - -#### Plugins API -- Plugins: Introduce the 'usePluginContext' hook. ([53291](https://github.com/WordPress/gutenberg/pull/53291)) - -#### Layout -- Add layout and block spacing to details block. ([53282](https://github.com/WordPress/gutenberg/pull/53282)) - -#### Typography - Fluid typography: Add min and max viewport width configurable options. ([53081](https://github.com/WordPress/gutenberg/pull/53081)) ### New APIs #### Extensibility -- Make useBlockEditingMode() public. ([52094](https://github.com/WordPress/gutenberg/pull/52094)) +- Make `useBlockEditingMode()` public. ([52094](https://github.com/WordPress/gutenberg/pull/52094)) ### Bug Fixes -- Command palette: Fix metrics for resting and no results view. ([53497](https://github.com/WordPress/gutenberg/pull/53497)) -- Fix top toolbar in the post editor with custom fields in Safari. ([53688](https://github.com/WordPress/gutenberg/pull/53688)) -- Improve metrics on post publish view buttons. ([53245](https://github.com/WordPress/gutenberg/pull/53245)) -- Set top toolbar size dynamically. ([53526](https://github.com/WordPress/gutenberg/pull/53526)) -- Support container queries in editor CSS. ([49915](https://github.com/WordPress/gutenberg/pull/49915)) +#### Commands +- Style tweaks to fix metrics for resting and no results view in command palette. ([53497](https://github.com/WordPress/gutenberg/pull/53497)) +- Order template results in Site Editor, to fix some templates not displaying. ([53286](https://github.com/WordPress/gutenberg/pull/53286)) +- Don't allow access to Styles-related pages via the command palette in the hybrid theme. ([53123](https://github.com/WordPress/gutenberg/pull/53123)) #### Block Library -- Button block: Memoize link value passed to the LinkControl. ([53507](https://github.com/WordPress/gutenberg/pull/53507)) -- Cover block: Fix flickering when inserted in templates and also fix isDark calculation bugs. ([53253](https://github.com/WordPress/gutenberg/pull/53253)) -- Footnotes: - - Autosave is not slashing JSON. ([53664](https://github.com/WordPress/gutenberg/pull/53664)) +- Button block: Avoid losing user changes when the `ButtonEdit` component re-renders. ([53507](https://github.com/WordPress/gutenberg/pull/53507)) +- Cover block: Fix flickering when inserted in templates and also fix `isDark` calculation bugs. ([53253](https://github.com/WordPress/gutenberg/pull/53253)) +- Footnotes block: + - Ensure autosave works and escapes quotes as expected. ([53664](https://github.com/WordPress/gutenberg/pull/53664)) - Fix accidental override. ([53663](https://github.com/WordPress/gutenberg/pull/53663)) - Fix recursion into updating attributes when attributes is not an object. ([53257](https://github.com/WordPress/gutenberg/pull/53257)) + - Remove Footnotes when interactive formatting is disabled. ([53474](https://github.com/WordPress/gutenberg/pull/53474)) - Image block: - Fix image stretching with only height. ([53443](https://github.com/WordPress/gutenberg/pull/53443)) - Don't render `DimensionsTool` if it is not resizable. ([53181](https://github.com/WordPress/gutenberg/pull/53181)) - Fix stretched images constrained by max-width. ([53274](https://github.com/WordPress/gutenberg/pull/53274)) - Clear aspect ratio when wide aligned. ([53439](https://github.com/WordPress/gutenberg/pull/53439)) - - Dimensions Tool: Change the conditions underwhich we display the scale control. ([53334](https://github.com/WordPress/gutenberg/pull/53334)) - - Aspect Ratio: Reset height when selecting the original aspect ratio. ([53339](https://github.com/WordPress/gutenberg/pull/53339)) -- Latest Posts block: Make latest-posts ssr categories handling more defensive. ([53659](https://github.com/WordPress/gutenberg/pull/53659)) + - Change the conditions under which we display the scale control. ([53334](https://github.com/WordPress/gutenberg/pull/53334)) + - Reset height when selecting the original aspect ratio. ([53339](https://github.com/WordPress/gutenberg/pull/53339)) +- Latest Posts block: Make categories handling more defensive to prevent multisite error. ([53659](https://github.com/WordPress/gutenberg/pull/53659)) +- Media & Text block: Fix deprecation with `isStackOnMobile` default value changed. ([49538](https://github.com/WordPress/gutenberg/pull/49538)) - Inject theme stylesheet value as template part theme attribute. ([53423](https://github.com/WordPress/gutenberg/pull/53423)) -- Patterns: Add `delete_posts` to the wp_block (patterns) capabilities. ([53405](https://github.com/WordPress/gutenberg/pull/53405)) - Block serialization: Correctly compare default attribute values. ([53521](https://github.com/WordPress/gutenberg/pull/53521)) #### Block Editor -- Fix Synced Patterns' color in quick inserter. ([53327](https://github.com/WordPress/gutenberg/pull/53327)) -- Hide pattern previews on hover in inserter. ([53331](https://github.com/WordPress/gutenberg/pull/53331)) - LinkControl: Prevent overflow when the title is a URL. ([53356](https://github.com/WordPress/gutenberg/pull/53356)) -- Safari: Fix ArrowUp on empty paragraph. ([53341](https://github.com/WordPress/gutenberg/pull/53341)) -- Safari: Fix Shift+Click multi select. ([53440](https://github.com/WordPress/gutenberg/pull/53440)) -- Selection: Restore focus after dragging out of the block repeatedly. ([53429](https://github.com/WordPress/gutenberg/pull/53429)) -- Writing flow: Avoid merging paragraph into Columns. ([53508](https://github.com/WordPress/gutenberg/pull/53508)) -- Writing flow: Fix vertical arrow keys not moving. ([53454](https://github.com/WordPress/gutenberg/pull/53454)) +- Fix broken flows on Safari, including `ArrowUp` functionality in an empty paragraph ([53341](https://github.com/WordPress/gutenberg/pull/53341)) and multi-selection upon shift plus click ([53440](https://github.com/WordPress/gutenberg/pull/53440)). +- Restore focus after dragging out of the block repeatedly. ([53429](https://github.com/WordPress/gutenberg/pull/53429)) +- Avoid merging paragraph into a Columns block. ([53508](https://github.com/WordPress/gutenberg/pull/53508)) +- Prevent vertical arrow keys getting stuck in view. ([53454](https://github.com/WordPress/gutenberg/pull/53454)) +- Set top toolbar size dynamically. ([53526](https://github.com/WordPress/gutenberg/pull/53526)) +- Support container queries in editor CSS. ([49915](https://github.com/WordPress/gutenberg/pull/49915)) +- Copy tag name on internal paste. ([48254](https://github.com/WordPress/gutenberg/pull/48254)) #### Site Editor - Add missing i18n in `HomeTemplateDetails`. ([53543](https://github.com/WordPress/gutenberg/pull/53543)) -- Adds site editor mobile block settings and styles. ([53412](https://github.com/WordPress/gutenberg/pull/53412)) -- Edit Site: Fix site editor canvas edit mode button. ([53730](https://github.com/WordPress/gutenberg/pull/53730)) +- Add buttons for block settings and styles in smaller viewport. ([53412](https://github.com/WordPress/gutenberg/pull/53412)) +- Ensure canvas edit mode button occupies the entire frame canvas. ([53730](https://github.com/WordPress/gutenberg/pull/53730)) - Fix document actions label helper method. ([52974](https://github.com/WordPress/gutenberg/pull/52974)) - Fix document title alignment in command palette button. ([53224](https://github.com/WordPress/gutenberg/pull/53224)) #### Post Editor -- Fix crash by moving editor style logic into a hook with useMemo. ([53596](https://github.com/WordPress/gutenberg/pull/53596)) +- Address crash by moving editor style logic into a hook with `useMemo`. ([53596](https://github.com/WordPress/gutenberg/pull/53596)) - Fix support of sticky position in non-iframed post editor. ([53540](https://github.com/WordPress/gutenberg/pull/53540)) -- Fix the typo when setting the preview device type to 'Desktop'. ([53409](https://github.com/WordPress/gutenberg/pull/53409)) -- getInsertionPoint: Avoid returning a different object on every call. ([53722](https://github.com/WordPress/gutenberg/pull/53722)) +- Correct typo when setting the preview device type to 'Desktop'. ([53409](https://github.com/WordPress/gutenberg/pull/53409)) +- Avoid returning a different object on every call to `getInsertionPoint`. ([53722](https://github.com/WordPress/gutenberg/pull/53722)) +- Fix top toolbar in the post editor with custom fields in Safari. ([53688](https://github.com/WordPress/gutenberg/pull/53688)) +- Improve metrics on post publish view buttons. ([53245](https://github.com/WordPress/gutenberg/pull/53245)) #### Page Content Focus - Fix missing Replace button in content-locked Image blocks. ([53410](https://github.com/WordPress/gutenberg/pull/53410)) -- Site Editor: Fix BlockPreview in Template panel when editing a page. ([53550](https://github.com/WordPress/gutenberg/pull/53550)) -- Use template.blocks in BlockPreview if it exists. ([53611](https://github.com/WordPress/gutenberg/pull/53611)) +- Fix BlockPreview in Template panel when editing a page in the site editor. ([53550](https://github.com/WordPress/gutenberg/pull/53550)) +- Use `template.blocks` in BlockPreview if it exists. ([53611](https://github.com/WordPress/gutenberg/pull/53611)) #### Navigation Menus -- Fix: #52886 Make all the 'Loading' strings consistent. ([52901](https://github.com/WordPress/gutenberg/pull/52901)) -- Fix: Title is not copied correctly when duplicating navigation. ([53610](https://github.com/WordPress/gutenberg/pull/53610)) -- Revert Fix entity cache misses for single posts due to string as recordKey. ([53419](https://github.com/WordPress/gutenberg/pull/53419)) +- Make all the 'Loading' strings consistent. ([52901](https://github.com/WordPress/gutenberg/pull/52901)) +- Fix title not being copied correctly when duplicating navigation. ([53610](https://github.com/WordPress/gutenberg/pull/53610)) +- Remove "go to" for terms and posts. ([53408](https://github.com/WordPress/gutenberg/pull/53408)) #### Typography - Fallback to default max viewport if layout wide size is fluid. ([53551](https://github.com/WordPress/gutenberg/pull/53551)) - Fix typo and add tests for fonts install endpoint. ([53644](https://github.com/WordPress/gutenberg/pull/53644)) #### Patterns +- Fix Synced Patterns' color in quick inserter. ([53327](https://github.com/WordPress/gutenberg/pull/53327)) +- Hide pattern previews on hover in inserter. ([53331](https://github.com/WordPress/gutenberg/pull/53331)) +- Ensure it's possible to delete draft patterns. ([53405](https://github.com/WordPress/gutenberg/pull/53405)) - Fix pattern creation button in list view dropdown menu. ([53562](https://github.com/WordPress/gutenberg/pull/53562)) -- Fix: Sync status overlaps for some languages in Patterns post type page. ([53243](https://github.com/WordPress/gutenberg/pull/53243)) - -#### Rich Text -- Copy tag name on internal paste. ([48254](https://github.com/WordPress/gutenberg/pull/48254)) -- RichText: Remove 'Footnotes' when interactive formatting is disabled. ([53474](https://github.com/WordPress/gutenberg/pull/53474)) +- Prevent sync status overlapping for some languages in patterns. ([53243](https://github.com/WordPress/gutenberg/pull/53243)) #### Global Styles - Fix push-to-global-styles clearing of attributes, border fallbacks, link hover colors, and behaviors. ([51621](https://github.com/WordPress/gutenberg/pull/51621)) @@ -183,33 +427,18 @@ - Include namespace in layout classname for non-core blocks. ([53404](https://github.com/WordPress/gutenberg/pull/53404)) #### Interactivity API -- Add short-cirtuit to `useSignalEffect`. ([53358](https://github.com/WordPress/gutenberg/pull/53358)) +- Add short-circuit to `useSignalEffect`. ([53358](https://github.com/WordPress/gutenberg/pull/53358)) - Add support for underscores and leading dashes in the suffix part of the directive. ([53337](https://github.com/WordPress/gutenberg/pull/53337)) +- Update deepsignal version. ([53549](https://github.com/WordPress/gutenberg/pull/53549)) #### Components -- Button: add `:Disabled` selector to reset hover color for disabled buttons. ([53411](https://github.com/WordPress/gutenberg/pull/53411)) - -#### Template Editor -- Remove "go to" for terms and posts. ([53408](https://github.com/WordPress/gutenberg/pull/53408)) - -#### Custom Fields -- Insert path and query args to form before submitting. ([53324](https://github.com/WordPress/gutenberg/pull/53324)) - -#### Themes -- Don't allow access to Styles-related pages via the command palette in the hybrid theme. ([53123](https://github.com/WordPress/gutenberg/pull/53123)) - -#### Block Validation/Deprecation -- Media & Text Block: Fix deprecation with `isStackOnMobile` default value changed. ([49538](https://github.com/WordPress/gutenberg/pull/49538)) - -#### npm Packages -- Add some missing package dependencies. ([41486](https://github.com/WordPress/gutenberg/pull/41486)) +- Button: Add `:Disabled` selector to reset hover color for disabled buttons. ([53411](https://github.com/WordPress/gutenberg/pull/53411)) +- Preferences Modal: Insert path and query args to form before submitting. ([53324](https://github.com/WordPress/gutenberg/pull/53324)) ### Accessibility - Type labels GH Action: Fix accessibility issues in error message. ([53371](https://github.com/WordPress/gutenberg/pull/53371)) - -#### Block Library - Add accessible description of current Navigation block state. ([53469](https://github.com/WordPress/gutenberg/pull/53469)) - Implement accessible version of Navigation overlay preview toggle control. ([53462](https://github.com/WordPress/gutenberg/pull/53462)) - Search Block: Fix unintended wrapping of button text in "Button only" style. ([53373](https://github.com/WordPress/gutenberg/pull/53373)) @@ -219,156 +448,145 @@ - Compute presets from `theme.json`: Skip those without classes or variables. ([53574](https://github.com/WordPress/gutenberg/pull/53574)) - Switch performance tests to Playwright. ([52022](https://github.com/WordPress/gutenberg/pull/52022)) - -#### Block Editor - Fix memory leaks in `