Prefer usernames in shell and admin flows
This commit is contained in:
@@ -167,7 +167,7 @@ export default function AppShell({
|
||||
</Box>
|
||||
);
|
||||
|
||||
const nameForAvatar = user?.displayName || user?.userName || user?.email;
|
||||
const nameForAvatar = user?.userName || user?.displayName || user?.email;
|
||||
const initials = initialsFrom(nameForAvatar);
|
||||
|
||||
const [userMenuAnchor, setUserMenuAnchor] = useState<null | HTMLElement>(null);
|
||||
@@ -232,7 +232,7 @@ export default function AppShell({
|
||||
<Avatar src={user.avatarImageDataUrl || undefined} sx={{ width: 30, height: 30, fontWeight: 900 }}>{initials}</Avatar>
|
||||
</IconButton>
|
||||
<Box sx={{ display: { xs: "none", sm: "block" } }}>
|
||||
<Typography sx={{ fontWeight: 600, lineHeight: 1.2 }}>{user.displayName || user.userName || user.email || t("user")}</Typography>
|
||||
<Typography sx={{ fontWeight: 600, lineHeight: 1.2 }}>{user.userName || user.displayName || user.email || t("user")}</Typography>
|
||||
<Typography variant="caption" sx={{ color: "text.secondary" }}>
|
||||
{user.roleLabel || ""}
|
||||
</Typography>
|
||||
|
||||
Reference in New Issue
Block a user