Skip to content

Commit

Permalink
remove zoom out toggle when editor is not iframed (#65452)
Browse files Browse the repository at this point in the history
  • Loading branch information
draganescu authored Sep 18, 2024
1 parent dac8767 commit 594a948
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
1 change: 1 addition & 0 deletions packages/editor/src/components/editor-interface/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -139,6 +139,7 @@ export default function EditorInterface( {
customSaveButton={ customSaveButton }
forceDisableBlockTools={ forceDisableBlockTools }
title={ title }
isEditorIframed={ ! disableIframe }
/>
)
}
Expand Down
3 changes: 2 additions & 1 deletion packages/editor/src/components/header/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ function Header( {
forceDisableBlockTools,
setEntitiesSavedStatesCallback,
title,
isEditorIframed,
} ) {
const isWideViewport = useViewportMatch( 'large' );
const isLargeViewport = useViewportMatch( 'medium' );
Expand Down Expand Up @@ -143,7 +144,7 @@ function Header( {
/>
<PostViewLink />

{ isWideViewport && <ZoomOutToggle /> }
{ isEditorIframed && isWideViewport && <ZoomOutToggle /> }

{ ( isWideViewport || ! showIconLabels ) && (
<PinnedItems.Slot scope="core" />
Expand Down

0 comments on commit 594a948

Please sign in to comment.