diff --git a/src/library-authoring/LibraryLayout.tsx b/src/library-authoring/LibraryLayout.tsx index c093af7ad..9acd0d431 100644 --- a/src/library-authoring/LibraryLayout.tsx +++ b/src/library-authoring/LibraryLayout.tsx @@ -1,17 +1,11 @@ -import { useCallback } from 'react'; import { - Route, - Routes, useParams, - useLocation, } from 'react-router-dom'; -import { ROUTES } from './routes'; import LibraryAuthoringPage from './LibraryAuthoringPage'; import { LibraryProvider } from './common/context/LibraryContext'; import { SidebarProvider } from './common/context/SidebarContext'; import { CreateCollectionModal } from './create-collection'; -import LibraryCollectionPage from './collections/LibraryCollectionPage'; import { ComponentPicker } from './component-picker'; import { ComponentEditorModal } from './components/ComponentEditorModal'; @@ -23,12 +17,8 @@ const LibraryLayout = () => { throw new Error('Error: route is missing libraryId.'); } - const location = useLocation(); - const context = useCallback((childPage) => ( + return ( { componentPicker={ComponentPicker} > - <> - {childPage} - - - + + + - ), [location.pathname]); - - return ( - - )} - /> - )} - /> - )} - /> - )} - /> - )} - /> - ); };