@@ -9,6 +9,7 @@ import MenuIcon from "@mui/icons-material/Menu";
99import {
1010 Box ,
1111 Button ,
12+ Chip ,
1213 IconButton ,
1314 MenuItem ,
1415 MenuList ,
@@ -27,6 +28,7 @@ import { handleLogin, handleLogout } from "../../utils/keycloak";
2728import NotificationsMenu from "../NotificationsMenu" ;
2829import SupportMenu from "../SupportMenu/SupportMenu" ;
2930import { StyledContainer , StyledHeader } from "./NavBar.styles" ;
31+ import { AccountType } from "@/types/accounts" ;
3032
3133const NAMESPACE_TRANSLATIONS_NAVBAR = "NavBar" ;
3234
@@ -105,6 +107,8 @@ export default function NavBar({ loggedIn }: NavBarProps) {
105107 store . getUser ( ) ,
106108 store . setUser ,
107109 ] ) ;
110+ const storedOrganisation = useStore ( state => state . config . organisation ) ;
111+ const storedCustodian = useStore ( state => state . config . custodian ) ;
108112
109113 const theme = useTheme ( ) ;
110114 const [ isDrawerOpen , setIsDrawerOpen ] = useState ( false ) ;
@@ -214,6 +218,24 @@ export default function NavBar({ loggedIn }: NavBarProps) {
214218 sx = { { mr : 4 } }
215219 />
216220 </ Link >
221+ { loggedIn && (
222+ < Chip
223+ label = {
224+ storedOrganisation
225+ ? AccountType . ORGANISATION
226+ : storedCustodian
227+ ? AccountType . CUSTODIAN
228+ : AccountType . USER
229+ }
230+ sx = { {
231+ textTransform : "uppercase" ,
232+ backgroundColor : theme . palette [ `neutral-500` ] . main ,
233+ color : theme . palette . white ,
234+ } }
235+ size = "medium"
236+ />
237+ ) }
238+
217239 { renderButtons ( left_buttons ) }
218240 </ Box >
219241 < Box sx = { { display : "flex" , alignItems : "center" , gap : 2 } } >
0 commit comments