diff --git a/packages/block-library/src/navigation/editor.scss b/packages/block-library/src/navigation/editor.scss index 4a6a6fe6b43951..107fb6e6de5fd5 100644 --- a/packages/block-library/src/navigation/editor.scss +++ b/packages/block-library/src/navigation/editor.scss @@ -503,30 +503,6 @@ body.editor-styles-wrapper .wp-block-navigation__responsive-container.is-menu-op left: 0; } -// Without this, the block cannot be selected, nor does the right container get focus. -// @todo: this is disruptive. Ideally we can retire a few of the containers, -// so focus is applied naturally on the block container. -// It's important the right container has focus, otherwise you can't press -// "Delete" to remove the block. -.wp-block-navigation:not(.is-editing-disabled) { - .wp-block-navigation__responsive-container, - .wp-block-navigation__responsive-close { - @include break-small() { - pointer-events: none; - - .wp-block-navigation__responsive-container-close, - .block-editor-block-list__layout * { - pointer-events: all; - } - } - - // Page List items should remain inert. - .wp-block-pages-list__item__link { - pointer-events: none; - } - } -} - // The menu and close buttons need higher specificity in the editor. .components-button.wp-block-navigation__responsive-container-open.wp-block-navigation__responsive-container-open, .components-button.wp-block-navigation__responsive-container-close.wp-block-navigation__responsive-container-close { diff --git a/packages/customize-widgets/src/components/keyboard-shortcuts/index.js b/packages/customize-widgets/src/components/keyboard-shortcuts/index.js index a83b730ddbb701..b7cdc1d42de863 100644 --- a/packages/customize-widgets/src/components/keyboard-shortcuts/index.js +++ b/packages/customize-widgets/src/components/keyboard-shortcuts/index.js @@ -127,7 +127,7 @@ function KeyboardShortcutsRegister() { } ); registerShortcut( { - name: `core/customize-widgets/transform-heading-to-paragraph`, + name: 'core/customize-widgets/transform-heading-to-paragraph', category: 'block-library', description: __( 'Transform heading to paragraph.' ), keyCombination: { diff --git a/packages/e2e-test-utils/src/create-reusable-block.js b/packages/e2e-test-utils/src/create-reusable-block.js index 266e0525d34bd2..7193db49a83efb 100644 --- a/packages/e2e-test-utils/src/create-reusable-block.js +++ b/packages/e2e-test-utils/src/create-reusable-block.js @@ -24,7 +24,7 @@ export const createReusableBlock = async ( content, title ) => { await page.keyboard.type( content ); await clickBlockToolbarButton( 'Options' ); - await clickMenuItem( 'Create a Pattern' ); + await clickMenuItem( 'Create pattern' ); const nameInput = await page.waitForSelector( reusableBlockNameInputSelector ); diff --git a/packages/e2e-tests/specs/editor/various/block-editor-keyboard-shortcuts.test.js b/packages/e2e-tests/specs/editor/various/block-editor-keyboard-shortcuts.test.js index 97248c472e4ac4..24e8e3104aaaa2 100644 --- a/packages/e2e-tests/specs/editor/various/block-editor-keyboard-shortcuts.test.js +++ b/packages/e2e-tests/specs/editor/various/block-editor-keyboard-shortcuts.test.js @@ -90,7 +90,7 @@ describe( 'block editor keyboard shortcuts', () => { } ); it( 'should prevent deleting multiple selected blocks from inputs', async () => { await clickBlockToolbarButton( 'Options' ); - await clickMenuItem( 'Create a Pattern' ); + await clickMenuItem( 'Create pattern' ); const reusableBlockNameInputSelector = '.reusable-blocks-menu-items__convert-modal .components-text-control__input'; const nameInput = await page.waitForSelector( diff --git a/packages/e2e-tests/specs/editor/various/reusable-blocks.test.js b/packages/e2e-tests/specs/editor/various/reusable-blocks.test.js index 416782733dfaa2..6d9eaa562b48f5 100644 --- a/packages/e2e-tests/specs/editor/various/reusable-blocks.test.js +++ b/packages/e2e-tests/specs/editor/various/reusable-blocks.test.js @@ -197,7 +197,7 @@ describe( 'Reusable blocks', () => { // Convert block to a reusable block. await clickBlockToolbarButton( 'Options' ); - await clickMenuItem( 'Create a Pattern' ); + await clickMenuItem( 'Create pattern' ); // Set title. const nameInput = await page.waitForSelector( @@ -383,7 +383,7 @@ describe( 'Reusable blocks', () => { // Convert to reusable. await clickBlockToolbarButton( 'Options' ); - await clickMenuItem( 'Create a Pattern' ); + await clickMenuItem( 'Create pattern' ); const nameInput = await page.waitForSelector( reusableBlockNameInputSelector ); diff --git a/packages/edit-post/src/components/keyboard-shortcuts/index.js b/packages/edit-post/src/components/keyboard-shortcuts/index.js index 5344d9155c8a47..432bce0a3bff5c 100644 --- a/packages/edit-post/src/components/keyboard-shortcuts/index.js +++ b/packages/edit-post/src/components/keyboard-shortcuts/index.js @@ -184,7 +184,7 @@ function KeyboardShortcuts() { } ); registerShortcut( { - name: `core/edit-post/transform-heading-to-paragraph`, + name: 'core/edit-post/transform-heading-to-paragraph', category: 'block-library', description: __( 'Transform heading to paragraph.' ), keyCombination: { diff --git a/packages/edit-site/src/components/keyboard-shortcuts/register.js b/packages/edit-site/src/components/keyboard-shortcuts/register.js index 0574125ba476b6..9660b03e762ed6 100644 --- a/packages/edit-site/src/components/keyboard-shortcuts/register.js +++ b/packages/edit-site/src/components/keyboard-shortcuts/register.js @@ -129,7 +129,7 @@ function KeyboardShortcutsRegister() { } ); registerShortcut( { - name: `core/edit-site/transform-heading-to-paragraph`, + name: 'core/edit-site/transform-heading-to-paragraph', category: 'block-library', description: __( 'Transform heading to paragraph.' ), keyCombination: { diff --git a/packages/edit-site/src/components/template-part-converter/convert-to-template-part.js b/packages/edit-site/src/components/template-part-converter/convert-to-template-part.js index d7571a0dcd6285..8e49e9d92abb45 100644 --- a/packages/edit-site/src/components/template-part-converter/convert-to-template-part.js +++ b/packages/edit-site/src/components/template-part-converter/convert-to-template-part.js @@ -57,7 +57,7 @@ export default function ConvertToTemplatePart( { clientIds, blocks } ) { setIsModalOpen( true ); } } > - { __( 'Create Template part' ) } + { __( 'Create template part' ) } { isModalOpen && ( handleTextLevelShortcut( event, 0 ) ); @@ -79,7 +79,7 @@ function KeyboardShortcuts() { //the hook will execute the same way every time //eslint-disable-next-line react-hooks/rules-of-hooks useShortcut( - `core/edit-widgets//transform-paragraph-to-heading-${ level }`, + `core/edit-widgets/transform-paragraph-to-heading-${ level }`, ( event ) => handleTextLevelShortcut( event, level ) ); } ); @@ -180,7 +180,7 @@ function KeyboardShortcutsRegister() { } ); registerShortcut( { - name: `core/edit-widgets//transform-heading-to-paragraph`, + name: 'core/edit-widgets/transform-heading-to-paragraph', category: 'block-library', description: __( 'Transform heading to paragraph.' ), keyCombination: { @@ -191,7 +191,7 @@ function KeyboardShortcutsRegister() { [ 1, 2, 3, 4, 5, 6 ].forEach( ( level ) => { registerShortcut( { - name: `core/edit-widgets//transform-paragraph-to-heading-${ level }`, + name: `core/edit-widgets/transform-paragraph-to-heading-${ level }`, category: 'block-library', description: __( 'Transform paragraph to heading.' ), keyCombination: { diff --git a/packages/reusable-blocks/src/components/reusable-blocks-menu-items/reusable-block-convert-button.js b/packages/reusable-blocks/src/components/reusable-blocks-menu-items/reusable-block-convert-button.js index c8203fdd73c409..e02cd4f428b679 100644 --- a/packages/reusable-blocks/src/components/reusable-blocks-menu-items/reusable-block-convert-button.js +++ b/packages/reusable-blocks/src/components/reusable-blocks-menu-items/reusable-block-convert-button.js @@ -130,11 +130,11 @@ export default function ReusableBlockConvertButton( { icon={ symbol } onClick={ () => setIsModalOpen( true ) } > - { __( 'Create a Pattern' ) } + { __( 'Create pattern' ) } { isModalOpen && ( { setIsModalOpen( false ); setTitle( '' ); diff --git a/test/e2e/specs/site-editor/template-part.spec.js b/test/e2e/specs/site-editor/template-part.spec.js index 1eb5fdba0c70d6..b6c124f2fbd3c6 100644 --- a/test/e2e/specs/site-editor/template-part.spec.js +++ b/test/e2e/specs/site-editor/template-part.spec.js @@ -147,7 +147,7 @@ test.describe( 'Template Part', () => { await editor.selectBlocks( paragraphBlock1, paragraphBlock2 ); // Convert block to a template part. - await editor.clickBlockOptionsMenuItem( 'Create Template part' ); + await editor.clickBlockOptionsMenuItem( 'Create template part' ); await page.type( 'role=dialog >> role=textbox[name="Name"i]', 'Test' ); await page.keyboard.press( 'Enter' );