Skip to content

Commit

Permalink
Fix Nav Sidebar Site Editor error (#40722)
Browse files Browse the repository at this point in the history
  • Loading branch information
getdave authored May 3, 2022
1 parent 739b871 commit 8b5c5d6
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions packages/edit-site/src/components/block-editor/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import classnames from 'classnames';
* WordPress dependencies
*/
import { useSelect, useDispatch } from '@wordpress/data';
import { useCallback, useRef } from '@wordpress/element';
import { useCallback, useRef, Fragment } from '@wordpress/element';
import { useEntityBlockEditor, store as coreStore } from '@wordpress/core-data';
import {
BlockList,
Expand Down Expand Up @@ -127,7 +127,7 @@ export default function BlockEditor( { setIsInserterOpen } ) {
// Conditionally include NavMenu sidebar in Plugin only.
// Optimise for dead code elimination.
// See https://github.com/WordPress/gutenberg/blob/trunk/docs/how-to-guides/feature-flags.md#dead-code-elimination.
let MaybeNavMenuSidebarToggle = 'Fragment';
let MaybeNavMenuSidebarToggle = Fragment;

if ( process.env.IS_GUTENBERG_PLUGIN ) {
MaybeNavMenuSidebarToggle = NavMenuSidebarToggle;
Expand Down
4 changes: 2 additions & 2 deletions packages/edit-site/src/components/sidebar/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
import { createSlotFill, PanelBody } from '@wordpress/components';
import { __ } from '@wordpress/i18n';
import { cog } from '@wordpress/icons';
import { useEffect } from '@wordpress/element';
import { useEffect, Fragment } from '@wordpress/element';
import { useSelect, useDispatch } from '@wordpress/data';
import { store as interfaceStore } from '@wordpress/interface';
import { store as blockEditorStore } from '@wordpress/block-editor';
Expand Down Expand Up @@ -62,7 +62,7 @@ export function SidebarComplementaryAreaFills() {
// Conditionally include NavMenu sidebar in Plugin only.
// Optimise for dead code elimination.
// See https://github.com/WordPress/gutenberg/blob/trunk/docs/how-to-guides/feature-flags.md#dead-code-elimination.
let MaybeNavigationMenuSidebar = 'Fragment';
let MaybeNavigationMenuSidebar = Fragment;

if ( process.env.IS_GUTENBERG_PLUGIN ) {
MaybeNavigationMenuSidebar = NavigationMenuSidebar;
Expand Down

0 comments on commit 8b5c5d6

Please sign in to comment.