-
Notifications
You must be signed in to change notification settings - Fork 245
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
users: add user favorite support #1864
Conversation
…to favorite-users
@@ -244,8 +245,17 @@ export default function UserDetails(props) { | |||
icon: <EditIcon />, | |||
handleOnClick: () => setShowEdit(true), | |||
}, | |||
<QuerySetFavoriteButton |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could optionally also do something like:
secondaryActions={[
<QuerySetFavoriteButton
key='secondary-action-favorite'
userID={props.userID}
/>,
].concat(
isAdmin
? [
{
label: 'Delete',
icon: <Delete />,
handleOnClick: () => setShowUserDeleteDialog(true),
},
{
label: 'Edit',
icon: <EditIcon />,
handleOnClick: () => setShowEdit(true),
},
]
: [],
)}
but looking at both pieces of code I like yours more. Yours is explicit that one chunk of buttons are shown if you're an admin and a completely separate chunk (that may or may not overlap the first chunk) is shown if not an admin.
This pull request has been automatically marked as stale because it has not had recent activity. Thank you for your contributions. |
make check
to catch common errors. Fixed any that came up.Description:
End Users may now set favorites on other users for a custom experience. This feature is replicated from Escalation Policies and similar functionalities that involve setting user favorites from the UI.
Which issue(s) this PR fixes:
Fixes #1086
Screenshots: