diff --git a/packages/editor/src/components/inserter-sidebar/index.js b/packages/editor/src/components/inserter-sidebar/index.js index e2e84c2f8185c4..5a1f473e8c4ca4 100644 --- a/packages/editor/src/components/inserter-sidebar/index.js +++ b/packages/editor/src/components/inserter-sidebar/index.js @@ -5,10 +5,7 @@ import { useDispatch, useSelect } from '@wordpress/data'; import { Button, VisuallyHidden } from '@wordpress/components'; import { __experimentalLibrary as Library } from '@wordpress/block-editor'; import { close } from '@wordpress/icons'; -import { - useViewportMatch, - __experimentalUseDialog as useDialog, -} from '@wordpress/compose'; +import { useViewportMatch } from '@wordpress/compose'; import { __ } from '@wordpress/i18n'; import { useEffect, useRef } from '@wordpress/element'; import { store as preferencesStore } from '@wordpress/preferences'; @@ -35,10 +32,6 @@ export default function InserterSidebar( { const isMobileViewport = useViewportMatch( 'medium', '<' ); const TagName = ! isMobileViewport ? VisuallyHidden : 'div'; - const [ inserterDialogRef, inserterDialogProps ] = useDialog( { - onClose: () => setIsInserterOpened( false ), - focusOnMount: null, - } ); const libraryRef = useRef(); useEffect( () => { @@ -46,11 +39,7 @@ export default function InserterSidebar( { }, [] ); return ( -
+