diff --git a/bin/build-plugin-zip.sh b/bin/build-plugin-zip.sh
index d68c58f0c9edb7..4aea6ac016c1e8 100755
--- a/bin/build-plugin-zip.sh
+++ b/bin/build-plugin-zip.sh
@@ -115,8 +115,7 @@ build_files=$(ls build/*/*.{js,css,asset.php} build/block-library/blocks/*.php b
status "Creating archive... 🎁"
zip -r gutenberg.zip \
gutenberg.php \
- lib/*.php \
- lib/demo-block-templates/*.html \
+ lib \
packages/block-serialization-default-parser/*.php \
post-content.php \
$vendor_scripts \
diff --git a/changelog.txt b/changelog.txt
index 9552802795a92a..a7f8ab103087ce 100644
--- a/changelog.txt
+++ b/changelog.txt
@@ -1,5 +1,120 @@
== Changelog ==
+= 7.7.0-rc.1 =
+
+### Features
+
+- Add the initial version of the Patterns UI as a sidebar plugin (This is not the final interface and work is in progress to integrate with the main block inserter). [20354](https://github.com/WordPress/gutenberg/pull/20354), [20715](https://github.com/WordPress/gutenberg/pull/20715).
+ - Add an initial set of patterns [20724](https://github.com/WordPress/gutenberg/pull/20724).
+
+### Enhancements
+
+- Update the Block and editor UI. [19344](https://github.com/WordPress/gutenberg/pull/19344)
+ - New icons. [20464](https://github.com/WordPress/gutenberg/pull/20464)
+ - Avoid empty menu groups. [20495](https://github.com/WordPress/gutenberg/pull/20495)
+ - Block Placeholders. [20441](https://github.com/WordPress/gutenberg/pull/20441), [20676](https://github.com/WordPress/gutenberg/pull/20676).
+ - Various tweaks [20679](https://github.com/WordPress/gutenberg/pull/20679), [20578](https://github.com/WordPress/gutenberg/pull/20578).
+- Improve the Back to WP Admin button in Fullscreen Mode. [20603](https://github.com/WordPress/gutenberg/pull/20603)
+- Make the editor Fullscreen by default. [20611](https://github.com/WordPress/gutenberg/pull/20611)
+- Remove template locking from the columns block [20465](https://github.com/WordPress/gutenberg/pull/20465)
+- Make the inserter full height. [20526](https://github.com/WordPress/gutenberg/pull/20526)
+
+### Bug Fixes
+
+- A11y:
+ - Deselect first/last gallery images on blur. [14930](https://github.com/WordPress/gutenberg/pull/14930)
+ - Revert top toolbar tab order [20571](https://github.com/WordPress/gutenberg/pull/20571)
+- Add an overlay to the html block preview to fix block selection in Firefox. [20425](https://github.com/WordPress/gutenberg/pull/20425)
+- Add missing accessibility attributes in the SVG icons. [20538](https://github.com/WordPress/gutenberg/pull/20538)
+- Fix invalid syntax error on Safari 12. [20507](https://github.com/WordPress/gutenberg/pull/20507)
+- Use a consistent width for the link suggetions. [20448](https://github.com/WordPress/gutenberg/pull/20448)
+- Use full labels for directional block movers. [20664](https://github.com/WordPress/gutenberg/pull/20664)
+- Columns block: Force 50% column width at mid-range viewport. [20597](https://github.com/WordPress/gutenberg/pull/20597)
+- Media & Text block: Fix frontend styles when "Crop image to fill" is selected [20539](https://github.com/WordPress/gutenberg/pull/20539)
+- Latest Post block:
+ - Fix the excerpt length. [20313](https://github.com/WordPress/gutenberg/pull/20313)
+ - Don't trim manual exerptts [20432](https://github.com/WordPress/gutenberg/pull/20432)
+- Fix sidebar scroll issue on small viewports. [20491](https://github.com/WordPress/gutenberg/pull/20491)
+- Social Link block:
+ - Escape generated class name. [20479](https://github.com/WordPress/gutenberg/pull/20479)
+ - Fix label attribute type as string. [20468](https://github.com/WordPress/gutenberg/pull/20468)
+ - i18n: Use placeholder for the default label [20475](https://github.com/WordPress/gutenberg/pull/20475)
+- Simulated Queries (Device previews):
+ - Check for match in stylesheet host and protocol to prevent Chrome breakage. [20673](https://github.com/WordPress/gutenberg/pull/20673)
+ - Fix IE11 editor breakage. [20226](https://github.com/WordPress/gutenberg/pull/20226)
+ - Fix incorrectly displayed preview option for private post types. [20604](https://github.com/WordPress/gutenberg/pull/20604)
+ - Focus preview button after opening preview. [20570](https://github.com/WordPress/gutenberg/pull/20570)
+- Fix isURL regex to take account file urls. [20435](https://github.com/WordPress/gutenberg/pull/20435)
+- Fix error when deleting empty paragraphs in IE11. [20594](https://github.com/WordPress/gutenberg/pull/20594)
+- Fix hidden inserter toggle behind the popover. [20663](https://github.com/WordPress/gutenberg/pull/20663)
+- Fix block registration shared defaults reuse across blocks. [20565](https://github.com/WordPress/gutenberg/pull/20565)
+- Shim meta attributes for early block registrations. [20544](https://github.com/WordPress/gutenberg/pull/20544)
+- Fix bouncing Custom color formatter. [20612](https://github.com/WordPress/gutenberg/pull/20612)
+- Fix Gallery block styles in Edge causing editor breakage. [20690](https://github.com/WordPress/gutenberg/pull/20690)
+
+### New APIs:
+
+- @wordpress/env: Add support for ZIP URL sources. [20426](https://github.com/WordPress/gutenberg/pull/20426)
+
+### Experiments
+
+- Lighter Block DOM: allow block types to render their own wrapper [19701](https://github.com/WordPress/gutenberg/pull/19701)
+ - Lighter InnerBlocks. [19910](https://github.com/WordPress/gutenberg/pull/19910)
+ - Automatically add block class. [20658](https://github.com/WordPress/gutenberg/pull/20658)
+- BlockPreview: Add __experimentalOnReady prop. [17242](https://github.com/WordPress/gutenberg/pull/17242)
+- Edit Site:
+ - Update template navigation to use new link control. [20366](https://github.com/WordPress/gutenberg/pull/20366)
+ - Update the edit site save modal UI. [20608](https://github.com/WordPress/gutenberg/pull/20608)
+- Fix the block toolbar in the Widgets and Site Edit screens. [20458](https://github.com/WordPress/gutenberg/pull/20458)
+- Fix widgets screen inserter [20680](https://github.com/WordPress/gutenberg/pull/20680)
+
+### Documentation
+
+- Add tutorial for creating a custom block editor instance. [20410](https://github.com/WordPress/gutenberg/pull/20410)
+- Create a new "Gutenberg as a Platform" page. [20666](https://github.com/WordPress/gutenberg/pull/20666)
+- Typos and tweaks: [20382](https://github.com/WordPress/gutenberg/pull/20382), [20386](https://github.com/WordPress/gutenberg/pull/20386), [20517](https://github.com/WordPress/gutenberg/pull/20517), [20662](https://github.com/WordPress/gutenberg/pull/20662), [20454](https://github.com/WordPress/gutenberg/pull/20454), [20659](https://github.com/WordPress/gutenberg/pull/20659).
+
+### Code Quality
+
+- Refactoring to existing blocks to use a lighter DOM:
+ - List block. [20498](https://github.com/WordPress/gutenberg/pull/20498)
+ - Image block. [20576](https://github.com/WordPress/gutenberg/pull/20576)
+ - Heading. [20493](https://github.com/WordPress/gutenberg/pull/20493)
+- Consistent block focus behaviour on mount. [20577](https://github.com/WordPress/gutenberg/pull/20577)
+- Cleanup CSS variables. [20529](https://github.com/WordPress/gutenberg/pull/20529)
+- Use the EditorSkeleton component in the widgets and Edit Site pages. [20440](https://github.com/WordPress/gutenberg/pull/20440), [20431](https://github.com/WordPress/gutenberg/pull/20431).
+- Refactor SlotFill components. [19242](https://github.com/WordPress/gutenberg/pull/19242)
+- Remove useless style override for floats. [20501](https://github.com/WordPress/gutenberg/pull/20501)
+- Block popover: remove data-type. [20531](https://github.com/WordPress/gutenberg/pull/20531)
+- Resizable editor improvements. [20259](https://github.com/WordPress/gutenberg/pull/20259)
+
+### Various
+
+- @wordpress/env:
+ - Save the database as a volume. [20648](https://github.com/WordPress/gutenberg/pull/20648)
+ - Fix accidental quotes in Site Title. [20520](https://github.com/WordPress/gutenberg/pull/20520)
+ - Set owner of wp-content to www-data. [20406](https://github.com/WordPress/gutenberg/pull/20406)
+- @wordpress/create-block:
+ - Fix system requirements checks. [20461](https://github.com/WordPress/gutenberg/pull/20461) [20456](https://github.com/WordPress/gutenberg/pull/20456)
+- Fix React warning triggered by the BlockToolbar component. [20546](https://github.com/WordPress/gutenberg/pull/20546)
+- Skip the Type Writer effect component in IE 11. [20485](https://github.com/WordPress/gutenberg/pull/20485)
+- Update browserslist to fix out-of-date caniuse-lite messages [20709](https://github.com/WordPress/gutenberg/pull/20709)
+- Add storybook stories:
+ - TextControl [20467](https://github.com/WordPress/gutenberg/pull/20467)
+ - TextAreaControl [20472](https://github.com/WordPress/gutenberg/pull/20472)
+ - SelectControl [20482](https://github.com/WordPress/gutenberg/pull/20482)
+ - Tooltip [20322](https://github.com/WordPress/gutenberg/pull/20322)
+- E2E Tests:
+ - Add test for the Image block. [20622](https://github.com/WordPress/gutenberg/pull/20622)
+ - More stable embed test. [20668](https://github.com/WordPress/gutenberg/pull/20668)
+ - Fix intermittent RichText e2e test failure. [20457](https://github.com/WordPress/gutenberg/pull/20457)
+- Travis: Avoid skipping Puppeteer download. [20547](https://github.com/WordPress/gutenberg/pull/20547)
+- Plugin: Bump minimum WordPress version to 5.3 [20628](https://github.com/WordPress/gutenberg/pull/20628)
+- @wordrpess/priority-queue: Fix for environments that don't have `window` defined. [20486](https://github.com/WordPress/gutenberg/pull/20486)
+- Update jest configuration to only ignore tests from /wordpress/ as a subdirectory [20420](https://github.com/WordPress/gutenberg/pull/20420)
+
+
+
= 7.6.0 =
## Features
diff --git a/docs/designers-developers/developers/slotfills/README.md b/docs/designers-developers/developers/slotfills/README.md
index 1fde71f171f99b..9df1769c19ba09 100644
--- a/docs/designers-developers/developers/slotfills/README.md
+++ b/docs/designers-developers/developers/slotfills/README.md
@@ -17,18 +17,16 @@ In order to access the SlotFills, we need to do four things:
Here is an example using the `PluginPostStatusInfo` slotFill:
+
```js
const { registerPlugin } = wp.plugins;
const { PluginPostStatusInfo } = wp.editPost;
-
-const PluginPostStatusInfoTest = () => {
- return(
-
-
+
+);
registerPlugin( 'post-status-info-test', { render: PluginPostStatusInfoTest } );
```
@@ -62,7 +60,6 @@ const PluginPostStatusInfo = ( { children, className } ) => (
PluginPostStatusInfo.Slot = Slot;
export default PluginPostStatusInfo;
-
```
This new Slot is then exposed in the editor. The example below is from core and represents the Status & visibility panel.
@@ -73,31 +70,34 @@ Any items that have been added via the SlotFill ( see the example above ), will
See [core code](https://github.com/WordPress/gutenberg/tree/master/packages/edit-post/src/components/sidebar/post-status/index.js#L26).
```js
-function PostStatus( { isOpened, onTogglePanel } ) {
- return (
-
-
- { ( fills ) => (
-
-
-
-
-
-
-
- { fills }
-
-
- ) }
-
-
- );
-}
+const PostStatus = ( { isOpened, onTogglePanel } ) => (
+
+
+ { ( fills ) => (
+
+
+
+
+
+
+
+ { fills }
+
+
+ ) }
+
+
+);
```
## Currently available SlotFills and examples
-There are currently seven available SlotFills in the `edit-post` package. Please refer to the individual items below for usage and example details:
+There are currently eight available SlotFills in the `edit-post` package. Please refer to the individual items below for usage and example details:
* [PluginBlockSettingsMenuItem](/docs/designers-developers/developers/slotfills/plugin-block-settings-menu-item.md)
* [PluginDocumentSettingPanel](/docs/designers-developers/developers/slotfills/plugin-document-setting-panel.md)
@@ -107,7 +107,3 @@ There are currently seven available SlotFills in the `edit-post` package. Please
* [PluginPrePublishPanel](/docs/designers-developers/developers/slotfills/plugin-pre-publish-panel.md)
* [PluginSidebar](/docs/designers-developers/developers/slotfills/plugin-sidebar.md)
* [PluginSidebarMoreMenuItem](/docs/designers-developers/developers/slotfills/plugin-sidebar-more-menu-item.md)
-
-
-
-
diff --git a/docs/designers-developers/developers/slotfills/plugin-block-settings-menu-item.md b/docs/designers-developers/developers/slotfills/plugin-block-settings-menu-item.md
index ce81b96f3e1824..666384c53af35d 100644
--- a/docs/designers-developers/developers/slotfills/plugin-block-settings-menu-item.md
+++ b/docs/designers-developers/developers/slotfills/plugin-block-settings-menu-item.md
@@ -1,9 +1,8 @@
# PluginBlockSettingsMenuItem
-This slot allows for adding a new item into the More Options area.
+This slot allows for adding a new item into the More Options area.
This will either appear in the controls for each block or at the Top Toolbar depending on the users setting.
-
## Example
```js
@@ -12,13 +11,18 @@ const { PluginBlockSettingsMenuItem } = wp.editPost;
const PluginBlockSettingsMenuGroupTest = () => (
{ alert( 'clicked' )} } />
-)
-
-registerPlugin( 'block-settings-menu-group-test', { render: PluginBlockSettingsMenuGroupTest } );
+ allowedBlocks={ [ 'core/paragraph' ] }
+ icon="smiley"
+ label="Menu item text"
+ onClick={ () => {
+ alert( 'clicked' );
+ } }
+ />
+);
+
+registerPlugin( 'block-settings-menu-group-test', {
+ render: PluginBlockSettingsMenuGroupTest,
+} );
```
## Location
diff --git a/docs/designers-developers/developers/slotfills/plugin-document-setting-panel.md b/docs/designers-developers/developers/slotfills/plugin-document-setting-panel.md
index 75f0a3638f1b4c..25a5ab915cb54b 100644
--- a/docs/designers-developers/developers/slotfills/plugin-document-setting-panel.md
+++ b/docs/designers-developers/developers/slotfills/plugin-document-setting-panel.md
@@ -3,15 +3,17 @@
This SlotFill allows registering a UI to edit Document settings.
## Available Props
+
* __name__ `string`: A string identifying the panel.
* __className__ `string`: An optional class name added to the sidebar body.
* __title__ `string`: Title displayed at the top of the sidebar.
* __icon__ `(string|Element)`: The [Dashicon](https://developer.wordpress.org/resource/dashicons/) icon slug string, or an SVG WP element.
## Example
+
```js
-const { registerPlugin } = wp.plugins;
-const { PluginDocumentSettingPanel } = wp.editPost;
+import { registerPlugin } from '@wordpress/plugins';
+import { PluginDocumentSettingPanel } from '@wordpress/edit-post';
const PluginDocumentSettingPanelDemo = () => (
(
Custom Panel Contents
);
-registerPlugin( 'plugin-document-setting-panel-demo', { render: PluginDocumentSettingPanelDemo, icon: 'palmtree' } );
-```
\ No newline at end of file
+
+registerPlugin( 'plugin-document-setting-panel-demo', {
+ render: PluginDocumentSettingPanelDemo,
+ icon: 'palmtree',
+} );
+```
diff --git a/docs/designers-developers/developers/slotfills/plugin-post-publish-panel.md b/docs/designers-developers/developers/slotfills/plugin-post-publish-panel.md
index 50c38098c19496..bbf146b4a8e050 100644
--- a/docs/designers-developers/developers/slotfills/plugin-post-publish-panel.md
+++ b/docs/designers-developers/developers/slotfills/plugin-post-publish-panel.md
@@ -5,19 +5,18 @@ This slot allows for injecting items into the bottom of the post-publish panel t
## Example
```js
-const { registerPlugin } = wp.plugins;
-const { PluginPostPublishPanel } = wp.editPost;
-
-const PluginPostPublishPanelTest = () => {
- return (
-
-
+
+);
registerPlugin( 'post-status-info-test', { render: PluginPostStatusInfoTest } );
```
diff --git a/docs/designers-developers/developers/slotfills/plugin-pre-publish-panel.md b/docs/designers-developers/developers/slotfills/plugin-pre-publish-panel.md
index 622a945dd08d87..abaa1cc4d6ae8d 100644
--- a/docs/designers-developers/developers/slotfills/plugin-pre-publish-panel.md
+++ b/docs/designers-developers/developers/slotfills/plugin-pre-publish-panel.md
@@ -1,23 +1,22 @@
# PluginPrePublishPanel
-This slot allows for injecting items into the bottom of the pre-publish panel that appears to confirm publishing after the user clicks "Publish'.
+This slot allows for injecting items into the bottom of the pre-publish panel that appears to confirm publishing after the user clicks "Publish".
## Example
```js
-const { registerPlugin } = wp.plugins;
-const { PluginPrePublishPanel }= wp.editPost;
-
-const PluginPrePublishPanelTest = () => {
- return (
-
-
+
+);
+
+registerPlugin( 'pre-publish-panel-test', {
+ render: PluginPrePublishPanelTest,
+} );
```
## Location
diff --git a/docs/designers-developers/developers/slotfills/plugin-sidebar-more-menu-item.md b/docs/designers-developers/developers/slotfills/plugin-sidebar-more-menu-item.md
index 40d1e0e22bab54..687a898c53047a 100644
--- a/docs/designers-developers/developers/slotfills/plugin-sidebar-more-menu-item.md
+++ b/docs/designers-developers/developers/slotfills/plugin-sidebar-more-menu-item.md
@@ -7,33 +7,24 @@ This is done by setting the `target` on `` to match t
```js
import { registerPlugin } from '@wordpress/plugins';
-import {
- PluginSidebar,
- PluginSidebarMoreMenuItem
-} from '@wordpress/edit-post';
+import { PluginSidebar, PluginSidebarMoreMenuItem } from '@wordpress/edit-post';
import { image } from '@wordpress/icons';
-
-const { Fragment } = wp.element;
-const myIcon =
+import { Fragment } from '@wordpress/element';
const PluginSidebarMoreMenuItemTest = () => (
-
+
Expanded Sidebar - More item
-
+
Content of the sidebar
-)
+);
-registerPlugin( 'plugin-sidebar-expanded-test', { render: PluginSidebarMoreMenuItemTest } );
+registerPlugin( 'plugin-sidebar-expanded-test', {
+ render: PluginSidebarMoreMenuItemTest,
+} );
```
## Location
diff --git a/docs/designers-developers/developers/slotfills/plugin-sidebar.md b/docs/designers-developers/developers/slotfills/plugin-sidebar.md
index 8af1641f6ea1fd..b5467f04c4bebd 100644
--- a/docs/designers-developers/developers/slotfills/plugin-sidebar.md
+++ b/docs/designers-developers/developers/slotfills/plugin-sidebar.md
@@ -10,17 +10,12 @@ import { registerPlugin } from '@wordpress/plugins';
import { PluginSidebar } from '@wordpress/edit-post';
import { image } from '@wordpress/icons';
-const PluginSidebarTest = () => {
- return (
-
-
Plugin Sidebar
-
- );
-};
+const PluginSidebarTest = () => (
+
+
Plugin Sidebar
+
+);
+
registerPlugin( 'plugin-sidebar-test', { render: PluginSidebarTest } );
```
diff --git a/docs/designers-developers/developers/tutorials/readme.md b/docs/designers-developers/developers/tutorials/readme.md
index 1a533bb595e16c..791048722f3bc9 100644
--- a/docs/designers-developers/developers/tutorials/readme.md
+++ b/docs/designers-developers/developers/tutorials/readme.md
@@ -12,4 +12,4 @@
* Learn how to add customized buttons to the toolbar with the [Format API tutorial](/docs/designers-developers/developers/tutorials/format-api/).
-* Build your own [custom block editor instance](/docs/designers-developers/developers/tutorials/custom-block-editor/) - this will walk you through building a standalone instance of the block editor within WP Admin.
\ No newline at end of file
+* Build your own [custom block editor instance](/docs/designers-developers/developers/platform/custom-block-editor/) - this will walk you through building a standalone instance of the block editor within WP Admin.
\ No newline at end of file
diff --git a/gutenberg.php b/gutenberg.php
index bdd7d4ebce6c2d..c151804694118a 100644
--- a/gutenberg.php
+++ b/gutenberg.php
@@ -3,7 +3,7 @@
* Plugin Name: Gutenberg
* Plugin URI: https://github.com/WordPress/gutenberg
* Description: Printing since 1440. This is the development plugin for the new block editor in core.
- * Version: 7.6.0
+ * Version: 7.7.0-rc.1
* Author: Gutenberg Team
* Text Domain: gutenberg
*
diff --git a/lib/client-assets.php b/lib/client-assets.php
index 10f36ce3a1d8d1..be7eeb19a83bb0 100644
--- a/lib/client-assets.php
+++ b/lib/client-assets.php
@@ -650,10 +650,10 @@ function gutenberg_load_block_pattern( $name ) {
*/
function gutenberg_extend_settings_block_patterns( $settings ) {
$block_patterns = [
- gutenberg_load_block_pattern( 'teams' ),
- gutenberg_load_block_pattern( 'testimonial' ),
- gutenberg_load_block_pattern( 'columns4-footer' ),
- gutenberg_load_block_pattern( 'natural-columns' ),
+ gutenberg_load_block_pattern( 'text-two-columns' ),
+ gutenberg_load_block_pattern( 'two-buttons' ),
+ gutenberg_load_block_pattern( 'cover-abc' ),
+ gutenberg_load_block_pattern( 'two-images' ),
];
$settings['__experimentalBlockPatterns'] = $block_patterns;
return $settings;
diff --git a/lib/patterns/columns4-footer.json b/lib/patterns/columns4-footer.json
deleted file mode 100644
index f968a91b106131..00000000000000
--- a/lib/patterns/columns4-footer.json
+++ /dev/null
@@ -1,5 +0,0 @@
-{
- "__file": "wp_block",
- "title": "4 columns footer",
- "content": "\n
“These guys are amazing! A very professional team that delivers excellent results every time we come for help. I highly recommend this company for your projects!”
\n\n\n\n
ANNA JANISON director at CYKO
\n"
-}
\ No newline at end of file
diff --git a/lib/patterns/text-two-columns.json b/lib/patterns/text-two-columns.json
new file mode 100644
index 00000000000000..1f6f33a865d51b
--- /dev/null
+++ b/lib/patterns/text-two-columns.json
@@ -0,0 +1,5 @@
+{
+ "__file": "wp_block",
+ "title": "Two Columns of Text",
+ "content": "\n
\n
\n
CHAPTER 1. Loomings
\n\n\n\n
Call me Ishmael. Some years ago—never mind how long precisely—having little or no money in my purse, and nothing particular to interest me on shore, I thought I would sail about a little and see the watery part of the world. It is a way I have of driving off the spleen and regulating the circulation.
\n
\n\n\n\n
\n
Whenever I find myself growing grim about the mouth; whenever it is a damp, drizzly November in my soul; whenever I find myself involuntarily pausing before coffin warehouses, and bringing up the rear of every funeral I meet; and especially whenever my hypos get such an upper hand of me, that it requires a strong moral principle to prevent me from deliberately stepping into the street, and methodically knocking people’s hats off—then, I account it high time tozz get to sea as soon as I can.