Skip to content

Commit

Permalink
remove extra wrapper
Browse files Browse the repository at this point in the history
  • Loading branch information
MaggieCabrera committed Jan 10, 2023
1 parent cade5cc commit 66a33c3
Showing 1 changed file with 43 additions and 45 deletions.
88 changes: 43 additions & 45 deletions packages/block-editor/src/components/off-canvas-editor/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -208,52 +208,50 @@ function __ExperimentalOffCanvasEditor(
listViewRef={ elementRef }
blockDropTarget={ blockDropTarget }
/>
<div className="offcanvas-editor-list-view-tree-wrapper">
<TreeGrid
id={ id }
className="block-editor-list-view-tree"
aria-label={ __( 'Block navigation structure' ) }
ref={ treeGridRef }
onCollapseRow={ collapseRow }
onExpandRow={ expandRow }
onFocusRow={ focusRow }
applicationAriaLabel={ __( 'Block navigation structure' ) }
>
<ListViewContext.Provider value={ contextValue }>
<ListViewBranch
blocks={ clientIdsTree }
selectBlock={ selectEditorBlock }
showBlockMovers={ showBlockMovers }
fixedListWindow={ fixedListWindow }
selectedClientIds={ selectedClientIds }
isExpanded={ isExpanded }
shouldShowInnerBlocks={ shouldShowInnerBlocks }
selectBlockInCanvas={ selectBlockInCanvas }
/>
<TreeGridRow
level={ 1 }
setSize={ 1 }
positionInSet={ 1 }
isExpanded={ true }
>
<TreeGridCell>
{ ( treeGridCellProps ) => (
<Appender { ...treeGridCellProps } />
) }
</TreeGridCell>
{ ! clientIdsTree.length && (
<TreeGridCell withoutGridItem>
<div className="offcanvas-editor-list-view-is-empty">
{ __(
'Your menu is currently empty. Add your first menu item to get started.'
) }
</div>
</TreeGridCell>
<TreeGrid
id={ id }
className="block-editor-list-view-tree"
aria-label={ __( 'Block navigation structure' ) }
ref={ treeGridRef }
onCollapseRow={ collapseRow }
onExpandRow={ expandRow }
onFocusRow={ focusRow }
applicationAriaLabel={ __( 'Block navigation structure' ) }
>
<ListViewContext.Provider value={ contextValue }>
<ListViewBranch
blocks={ clientIdsTree }
selectBlock={ selectEditorBlock }
showBlockMovers={ showBlockMovers }
fixedListWindow={ fixedListWindow }
selectedClientIds={ selectedClientIds }
isExpanded={ isExpanded }
shouldShowInnerBlocks={ shouldShowInnerBlocks }
selectBlockInCanvas={ selectBlockInCanvas }
/>
<TreeGridRow
level={ 1 }
setSize={ 1 }
positionInSet={ 1 }
isExpanded={ true }
>
<TreeGridCell>
{ ( treeGridCellProps ) => (
<Appender { ...treeGridCellProps } />
) }
</TreeGridRow>
</ListViewContext.Provider>
</TreeGrid>
</div>
</TreeGridCell>
{ ! clientIdsTree.length && (
<TreeGridCell withoutGridItem>
<div className="offcanvas-editor-list-view-is-empty">
{ __(
'Your menu is currently empty. Add your first menu item to get started.'
) }
</div>
</TreeGridCell>
) }
</TreeGridRow>
</ListViewContext.Provider>
</TreeGrid>
</AsyncModeProvider>
);
}
Expand Down

0 comments on commit 66a33c3

Please sign in to comment.