Update UserRow.tsx

This commit is contained in:
Charles Morgan 2020-11-29 19:35:16 -05:00
parent 947fdf72ed
commit 76d671aa8a
1 changed files with 15 additions and 15 deletions

View File

@ -49,21 +49,21 @@ export default ({ subuser }: Props) => {
<p css={tw`text-2xs text-neutral-500 uppercase`}>Permissions</p> <p css={tw`text-2xs text-neutral-500 uppercase`}>Permissions</p>
</div> </div>
{subuser.uuid !== uuid && {subuser.uuid !== uuid &&
<Can action={'user.update'}> <>
<button <Can action={'user.update'}>
type={'button'} <button
aria-label={'Edit subuser'} type={'button'}
css={tw`block text-sm p-1 md:p-2 text-neutral-500 hover:text-neutral-100 transition-colors duration-150 mx-4`} aria-label={'Edit subuser'}
onClick={() => setVisible(true)} css={tw`block text-sm p-1 md:p-2 text-neutral-500 hover:text-neutral-100 transition-colors duration-150 mx-4`}
> onClick={() => setVisible(true)}
<FontAwesomeIcon icon={faPencilAlt}/> >
</button> <FontAwesomeIcon icon={faPencilAlt} />
</Can> </button>
} </Can>
{subuser.uuid !== uuid && <Can action={'user.delete'}>
<Can action={'user.delete'}> <RemoveSubuserButton subuser={subuser} />
<RemoveSubuserButton subuser={subuser}/> </Can>
</Can> </>
} }
</GreyRowBox> </GreyRowBox>
); );