From 8e5abf74f6beeba0d24345e5226c11ea59b7ecef Mon Sep 17 00:00:00 2001 From: Daniel Cousens <413395+dcousens@users.noreply.github.com> Date: Wed, 21 Aug 2024 16:39:45 +1000 Subject: [PATCH] fix examples/custom-admin-ui-pages --- .../admin/components/CustomNavigation.tsx | 32 +++++++++++++++---- examples/custom-admin-ui-pages/package.json | 1 + pnpm-lock.yaml | 3 ++ 3 files changed, 30 insertions(+), 6 deletions(-) diff --git a/examples/custom-admin-ui-pages/admin/components/CustomNavigation.tsx b/examples/custom-admin-ui-pages/admin/components/CustomNavigation.tsx index 2d4580d7119..42ce6904baf 100644 --- a/examples/custom-admin-ui-pages/admin/components/CustomNavigation.tsx +++ b/examples/custom-admin-ui-pages/admin/components/CustomNavigation.tsx @@ -1,13 +1,33 @@ import React from 'react' -import { NavItem, ListNavItems, NavigationContainer } from '@keystone-6/core/admin-ui/components' + +import { Divider } from '@keystar/ui/layout' +import { + getHrefFromList, + DeveloperResourcesMenu, + NavContainer, + NavFooter, + NavList, + NavItem, +} from '@keystone-6/core/admin-ui/components' import type { NavigationProps } from '@keystone-6/core/admin-ui/components' export function CustomNavigation ({ lists }: NavigationProps) { return ( - - Dashboard - - Custom Page - + + + Dashboard + Custom Page + + {lists.map((list) => ( + + {list.label} + + ))} + + + + + + ) } diff --git a/examples/custom-admin-ui-pages/package.json b/examples/custom-admin-ui-pages/package.json index b65caa80b7c..2143a930be8 100644 --- a/examples/custom-admin-ui-pages/package.json +++ b/examples/custom-admin-ui-pages/package.json @@ -10,6 +10,7 @@ "postinstall": "keystone postinstall" }, "dependencies": { + "@keystar/ui": "^0.7.6", "@keystone-6/core": "^6.2.0", "@keystone-ui/core": "^5.0.2", "@prisma/client": "5.17.0", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 2af55450497..58c396af782 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -722,6 +722,9 @@ importers: examples/custom-admin-ui-pages: dependencies: + '@keystar/ui': + specifier: ^0.7.6 + version: 0.7.9(next@14.2.5(@babel/core@7.25.2)(babel-plugin-macros@3.1.0)(react-dom@18.3.1(react@18.3.1))(react@18.3.1))(react-dom@18.3.1(react@18.3.1))(react@18.3.1) '@keystone-6/core': specifier: ^6.2.0 version: link:../../packages/core