Press n or j to go to the next uncovered block, b, p or k for the previous block.
| 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 | 14x | // The round initial of the signed-in user (Design canvas: AsunnotTili,
// TiliKevyt), in the accent colour.
import Box from '@mui/material/Box'
import { initialOf } from './initial'
export function AccountAvatar({ name, size }: { name: string; size: number }) {
return (
<Box
component="span"
aria-hidden="true"
sx={{
width: size,
height: size,
flexShrink: 0,
borderRadius: '50%',
bgcolor: 'accent.main',
color: 'accent.contrastText',
display: 'flex',
alignItems: 'center',
justifyContent: 'center',
fontSize: Math.round(size * 0.4),
fontWeight: 900,
}}
>
{initialOf(name)}
</Box>
)
}
|