Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions packages/edit-site/src/components/editor/style.scss
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,12 @@
padding: $grid-unit-30;
display: flex;
justify-content: center;

.is-entity-save-view-open & {
position: absolute;
right: -9999999em;
height: 0;
}
}

// Adjust the position of the notices
Expand Down
30 changes: 14 additions & 16 deletions packages/edit-site/src/components/save-panel/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -142,22 +142,20 @@ export default function SavePanel() {
} ) }
ariaLabel={ __( 'Save panel' ) }
>
{ isSaveViewOpen ? (
<_EntitiesSavedStates onClose={ onClose } />
) : (
<div className="edit-site-editor__toggle-save-panel">
<Button
variant="secondary"
className="edit-site-editor__toggle-save-panel-button"
onClick={ () => setIsSaveViewOpened( true ) }
aria-expanded={ false }
disabled={ disabled }
__experimentalIsFocusable
>
{ __( 'Open save panel' ) }
</Button>
</div>
) }
<div className="edit-site-editor__toggle-save-panel">
<Button
variant="secondary"
className="edit-site-editor__toggle-save-panel-button"
onClick={ () => setIsSaveViewOpened( true ) }
aria-expanded={ false }
disabled={ disabled }
aria-haspopup={ 'dialog' }
__experimentalIsFocusable
>
{ __( 'Open save panel' ) }
</Button>
</div>
{ isSaveViewOpen && <_EntitiesSavedStates onClose={ onClose } /> }
</NavigableRegion>
);
}