- 添加 truncate 类防止文件名过长溢出 - 设置不同屏幕宽度下的最大宽度(w-40 sm:w-64)以适应响应式布局
@@ -168,7 +168,7 @@ const AvatarSelector: React.FC<AvatarSelectorProps> = ({
{currentFile ? '更换头像' : placeholder}
</Button>
{currentFile && (
- <p className="text-xs text-muted-foreground">
+ <p className="text-xs text-muted-foreground truncate w-40 sm:w-64 ">
当前: {currentFile.name}
</p>
)}