Add fields, id as tooltip, and display none if value not set #12

This commit is contained in:
Lena 2021-03-08 17:39:23 +01:00 committed by Sascha
parent cef44db8c7
commit e55761b2f8
2 changed files with 14 additions and 4 deletions

View File

@ -1,10 +1,14 @@
query CurrentIdentity {
repository {
userIdentity {
id
humanId
email
displayName
email
name
avatarUrl
isProtected
login
}
}
}

View File

@ -71,9 +71,15 @@ const CurrentIdentity = () => {
<Paper>
<ClickAwayListener onClickAway={handleClose}>
<MenuList autoFocusItem={open} id="menu-list-grow">
<MenuItem>Display Name: {user.displayName}</MenuItem>
<MenuItem>Human Id: {user.humanId}</MenuItem>
<MenuItem>Email: {user.email}</MenuItem>
<MenuItem>Name: {user.name ? user.name : 'none'}</MenuItem>
<MenuItem title={user.id}>
Id: {user.humanId ? user.humanId : 'none'}
</MenuItem>
<MenuItem>Email: {user.email ? user.email : 'none'}</MenuItem>
<MenuItem>Login: {user.login ? user.login : 'none'}</MenuItem>
<MenuItem>
Protected: {user.isProtected ? user.login : 'not set'}
</MenuItem>
</MenuList>
</ClickAwayListener>
</Paper>