diff --git a/apps/meteor/client/components/InfoPanel/InfoPanelTitle.tsx b/apps/meteor/client/components/InfoPanel/InfoPanelTitle.tsx index 7ea4de6d9867..615f6762efd1 100644 --- a/apps/meteor/client/components/InfoPanel/InfoPanelTitle.tsx +++ b/apps/meteor/client/components/InfoPanel/InfoPanelTitle.tsx @@ -5,15 +5,15 @@ import React from 'react'; type InfoPanelTitleProps = { title: string; - icon: ReactNode; + icon?: ReactNode; }; const isValidIcon = (icon: ReactNode): icon is IconName => typeof icon === 'string'; const InfoPanelTitle: FC = ({ title, icon }) => ( - + {isValidIcon(icon) ? : icon} - + {title} diff --git a/apps/meteor/client/components/UserCard/UserCardRoles.tsx b/apps/meteor/client/components/UserCard/UserCardRoles.tsx index 9cd22ebdff35..f7a977d4a4dc 100644 --- a/apps/meteor/client/components/UserCard/UserCardRoles.tsx +++ b/apps/meteor/client/components/UserCard/UserCardRoles.tsx @@ -6,7 +6,7 @@ import UserCardInfo from './UserCardInfo'; const UserCardRoles = ({ children }: { children: ReactNode }): ReactElement => ( - + {children} diff --git a/apps/meteor/client/components/UserInfo/UserInfo.tsx b/apps/meteor/client/components/UserInfo/UserInfo.tsx index bdce27d028ad..8a42f1b87026 100644 --- a/apps/meteor/client/components/UserInfo/UserInfo.tsx +++ b/apps/meteor/client/components/UserInfo/UserInfo.tsx @@ -81,12 +81,19 @@ const UserInfo = ({ {userDisplayName && } {statusText && ( - + )} + {nickname && ( + + {t('Nickname')} + {nickname} + + )} + {roles.length !== 0 && ( {t('Roles')} @@ -94,6 +101,13 @@ const UserInfo = ({ )} + {username && username !== name && ( + + {t('Username')} + {username} + + )} + {Number.isInteger(utcOffset) && ( {t('Local_Time')} @@ -101,10 +115,12 @@ const UserInfo = ({ )} - {username && username !== name && ( + {bio && ( - {t('Username')} - {username} + {t('Bio')} + + + )} @@ -122,22 +138,6 @@ const UserInfo = ({ )} - {nickname && ( - - {t('Nickname')} - {nickname} - - )} - - {bio && ( - - {t('Bio')} - - - - - )} - {phone && ( {t('Phone')} diff --git a/apps/meteor/client/views/admin/users/AdminUserInfoActions.tsx b/apps/meteor/client/views/admin/users/AdminUserInfoActions.tsx index d003b47ba2af..dd0bf833f72b 100644 --- a/apps/meteor/client/views/admin/users/AdminUserInfoActions.tsx +++ b/apps/meteor/client/views/admin/users/AdminUserInfoActions.tsx @@ -83,8 +83,8 @@ const AdminUserInfoActions = ({ ...(changeAdminStatusAction && !isFederatedUser && { makeAdmin: changeAdminStatusAction }), ...(resetE2EKeyAction && !isFederatedUser && { resetE2EKey: resetE2EKeyAction }), ...(resetTOTPAction && !isFederatedUser && { resetTOTP: resetTOTPAction }), - ...(deleteUserAction && { delete: deleteUserAction }), ...(changeUserStatusAction && !isFederatedUser && { changeActiveStatus: changeUserStatusAction }), + ...(deleteUserAction && { delete: deleteUserAction }), }), [ t, @@ -116,7 +116,13 @@ const AdminUserInfoActions = ({ secondary flexShrink={0} key='menu' - renderItem={({ label: { label, icon }, ...props }): ReactElement =>