perf: improve avatar display timing for non-avatar user
This commit is contained in:
parent
b778f8c982
commit
04dc1e98dd
@ -76,7 +76,7 @@ export const UserConfig: React.FC<UserConfigProps> = React.memo((props) => {
|
||||
<Avatar size={props.isCollapsed ? 'sm' : 'default'}>
|
||||
{userInfo?.avatar && <AvatarImage src={userInfo.avatar} />}
|
||||
|
||||
<AvatarFallback>
|
||||
<AvatarFallback delayMs={userInfo?.avatar ? undefined : 0}>
|
||||
{nickname.substring(0, 2).toUpperCase()}
|
||||
</AvatarFallback>
|
||||
</Avatar>
|
||||
|
@ -6,7 +6,6 @@ import { Loading } from '@/components/Loading';
|
||||
import { NotFoundTip } from '@/components/NotFoundTip';
|
||||
import { Button } from '@/components/ui/button';
|
||||
import { ScrollArea, ScrollBar } from '@/components/ui/scroll-area';
|
||||
import { Separator } from '@/components/ui/separator';
|
||||
import { WebsiteCodeBtn } from '@/components/website/WebsiteCodeBtn';
|
||||
import { WebsiteLighthouseBtn } from '@/components/website/WebsiteLighthouseBtn';
|
||||
import { WebsiteMetricsTable } from '@/components/website/WebsiteMetricsTable';
|
||||
|
Loading…
Reference in New Issue
Block a user