diff --git a/packages/block-editor/src/components/inserter/block-patterns-tab/patterns-filter.js b/packages/block-editor/src/components/inserter/block-patterns-tab/patterns-filter.js index 766082bd7690d..8193088e0ae06 100644 --- a/packages/block-editor/src/components/inserter/block-patterns-tab/patterns-filter.js +++ b/packages/block-editor/src/components/inserter/block-patterns-tab/patterns-filter.js @@ -101,6 +101,11 @@ export function PatternsFilter( { } } + // Run only when the directory is disabled. + const menuOptions = PATTERN_SOURCE_MENU_OPTIONS.filter( + ( { value } ) => value !== 'directory' + ); + return ( <> { handleSetSourceFilterChange( value ); scrollContainerRef.current?.scrollTo(