From d38e866c349de9e5facc547396178ed993b2d8fe Mon Sep 17 00:00:00 2001 From: priethor <27339341+priethor@users.noreply.github.com> Date: Mon, 10 Jul 2023 21:59:04 +0200 Subject: [PATCH] Revert "Post editor: Require confirmation before removing Footnotes (#52277)" This reverts commit e6426ea60b99ae76f703baeb22c8add5cc7afbf4. --- .../block-removal-warning-modal/index.js | 3 --- packages/edit-post/src/components/layout/index.js | 15 +-------------- packages/edit-site/src/components/editor/index.js | 3 --- 3 files changed, 1 insertion(+), 20 deletions(-) diff --git a/packages/block-editor/src/components/block-removal-warning-modal/index.js b/packages/block-editor/src/components/block-removal-warning-modal/index.js index af521b7233435a..08f3deccb5ae08 100644 --- a/packages/block-editor/src/components/block-removal-warning-modal/index.js +++ b/packages/block-editor/src/components/block-removal-warning-modal/index.js @@ -50,9 +50,6 @@ export function BlockRemovalWarningModal( { rules } ) { { blockNamesForPrompt.length === 1 ? (

{ rules[ blockNamesForPrompt[ 0 ] ] }

diff --git a/packages/edit-post/src/components/layout/index.js b/packages/edit-post/src/components/layout/index.js index 0c18521b1215f2..15bc017900daa2 100644 --- a/packages/edit-post/src/components/layout/index.js +++ b/packages/edit-post/src/components/layout/index.js @@ -16,10 +16,7 @@ import { store as editorStore, } from '@wordpress/editor'; import { useSelect, useDispatch } from '@wordpress/data'; -import { - BlockBreadcrumb, - privateApis as blockEditorPrivateApis, -} from '@wordpress/block-editor'; +import { BlockBreadcrumb } from '@wordpress/block-editor'; import { Button, ScrollLock, Popover } from '@wordpress/components'; import { useViewportMatch } from '@wordpress/compose'; import { PluginArea } from '@wordpress/plugins'; @@ -52,9 +49,6 @@ import WelcomeGuide from '../welcome-guide'; import ActionsPanel from './actions-panel'; import StartPageOptions from '../start-page-options'; import { store as editPostStore } from '../../store'; -import { unlock } from '../../lock-unlock'; - -const { BlockRemovalWarningModal } = unlock( blockEditorPrivateApis ); const interfaceLabels = { /* translators: accessibility text for the editor top bar landmark region. */ @@ -69,12 +63,6 @@ const interfaceLabels = { footer: __( 'Editor footer' ), }; -const blockRemovalRules = { - 'core/footnotes': __( - 'The Footnotes block displays all footnotes found in the content. Note that any footnotes in the content will persist after removing this block.' - ), -}; - function Layout( { styles } ) { const isMobileViewport = useViewportMatch( 'medium', '<' ); const isHugeViewport = useViewportMatch( 'huge', '>=' ); @@ -214,7 +202,6 @@ function Layout( { styles } ) { -