Skip to content

Commit

Permalink
Do not render edit area if canvasMode is edit
Browse files Browse the repository at this point in the history
  • Loading branch information
oandregal committed Oct 22, 2024
1 parent 44650fd commit 34ed8bf
Showing 1 changed file with 12 additions and 10 deletions.
22 changes: 12 additions & 10 deletions packages/edit-site/src/components/layout/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -183,16 +183,18 @@ export default function Layout( { route } ) {
</div>
) }

{ ! isMobileViewport && areas.edit && (
<div
className="edit-site-layout__area"
style={ {
maxWidth: widths?.edit,
} }
>
{ areas.edit }
</div>
) }
{ ! isMobileViewport &&
areas.edit &&
canvasMode !== 'edit' && (
<div
className="edit-site-layout__area"
style={ {
maxWidth: widths?.edit,
} }
>
{ areas.edit }
</div>
) }

{ ! isMobileViewport && areas.preview && (
<div className="edit-site-layout__canvas-container">
Expand Down

0 comments on commit 34ed8bf

Please sign in to comment.