Avatar
A round badge with someone's initials, in a few colours.
A round badge with someone's initials, in a few colours.
npm install @mui/material
First time with Material UI? Set it up once.
/**
* Demo from Material UI, https://mui.com/material-ui/ (docs demo LetterAvatars)
* MIT License, Copyright (c) 2014 Call-Em-All. Full text: https://github.com/mui/material-ui/blob/master/LICENSE
*/
'use client';
import Avatar from '@mui/material/Avatar';
import Stack from '@mui/material/Stack';
import { deepOrange, deepPurple } from '@mui/material/colors';
export default function LetterAvatars() {
return (
<Stack direction="row" spacing={2}>
<Avatar>H</Avatar>
<Avatar sx={{ bgcolor: deepOrange[500] }}>N</Avatar>
<Avatar sx={{ bgcolor: deepPurple[500] }}>OP</Avatar>
</Stack>
);
}