Skip to content

Commit 64faefe

Browse files
committed
feat: 添加头像组件
1 parent 2c7280a commit 64faefe

File tree

1 file changed

+19
-0
lines changed

1 file changed

+19
-0
lines changed

src/components/SoybeanAvatar.tsx

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
import clsx from 'clsx';
2+
3+
import soybeanAvatar from '@/assets/imgs/soybean.jpg';
4+
5+
const SoybeanAvatar = ({ className, ...props }: React.ComponentProps<'div'>) => {
6+
return (
7+
<div
8+
{...props}
9+
className={clsx('size-72px overflow-hidden rd-1/2', className)}
10+
>
11+
<img
12+
className="size-full"
13+
src={soybeanAvatar}
14+
/>
15+
</div>
16+
);
17+
};
18+
19+
export default SoybeanAvatar;

0 commit comments

Comments
 (0)