From 2e9c5f0995696d09654ccd25f3dcdb0b42c367da Mon Sep 17 00:00:00 2001 From: Jerry Jones Date: Thu, 28 Mar 2024 09:29:26 -0500 Subject: [PATCH] Fix editor canvas overflow on search results with position: relative Previously this was fixed with overflow: hidden; which is more restrictive. position: relative also fixes the issue and is less restrictive of allowing other styling options and ui elements on the inserter such as a block pattern flyout. --- packages/block-editor/src/components/inserter/style.scss | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/packages/block-editor/src/components/inserter/style.scss b/packages/block-editor/src/components/inserter/style.scss index ba1107054c6e1..580e4ec0e21f2 100644 --- a/packages/block-editor/src/components/inserter/style.scss +++ b/packages/block-editor/src/components/inserter/style.scss @@ -22,7 +22,6 @@ $block-inserter-tabs-height: 44px; flex-direction: column; height: 100%; gap: $grid-unit-20; - overflow-y: hidden; &.show-as-tabs { gap: 0; @@ -142,6 +141,8 @@ $block-inserter-tabs-height: 44px; .block-editor-inserter__no-tab-container { overflow-y: auto; flex-grow: 1; + // Fixes the editor canvas scrolling on search results https://github.com/WordPress/gutenberg/issues/56811 + position: relative; } .block-editor-inserter__panel-header {