diff --git a/packages/firecms_cloud/src/components/FireCMSCloudDrawer.tsx b/packages/firecms_cloud/src/components/FireCMSCloudDrawer.tsx index 0f0dee489..9ebb11d64 100644 --- a/packages/firecms_cloud/src/components/FireCMSCloudDrawer.tsx +++ b/packages/firecms_cloud/src/components/FireCMSCloudDrawer.tsx @@ -4,8 +4,8 @@ import { DrawerNavigationItem, IconForView, TopNavigationResult, - useAuthController, useApp, + useAuthController, useNavigationController } from "@firecms/core"; import { AddIcon, Button, Tooltip, Typography, } from "@firecms/ui"; @@ -44,10 +44,10 @@ export function FireCMSCloudDrawer() { }: TopNavigationResult = navigation.topLevelNavigation; const buildGroupHeader = useCallback((group?: string) => { - if (!drawerOpen) return
; + if (!drawerOpen) return
; const reservedGroup = group && RESERVED_GROUPS.includes(group); const canCreateCollections = collectionEditorController.configPermissions({ user }).createCollections && !reservedGroup; - return
+ return
@@ -79,11 +79,15 @@ export function FireCMSCloudDrawer() { <> -
+ +
{groups.map((group) => ( - +
{buildGroupHeader(group)} {Object.values(navigationEntries) .filter(e => e.group === group) @@ -95,7 +99,7 @@ export function FireCMSCloudDrawer() { drawerOpen={drawerOpen} url={view.url} name={view.name}/>)} - +
))}