mirror of
https://github.com/darksaid98/new-phone-who-dis.git
synced 2026-12-04 14:38:45 +00:00
1 parent
404d526863
commit
e1e6e8440d
35 files changed
+1089
-65
No files matched your search
@@ -21,12 +21,17 @@ const useStyles = makeStyles<Theme, { color: string; backgroundColor: string }>(
|
||||
height: theme.spacing(8),
|
||||
fontSize: theme.typography.h4.fontSize,
|
||||
},
|
||||
icon: {
|
||||
fontSize: theme.typography.h4.fontSize,
|
||||
width: theme.spacing(8),
|
||||
height: theme.spacing(8),
|
||||
},
|
||||
tooltip: {
|
||||
fontSize: 12,
|
||||
},
|
||||
}));
|
||||
|
||||
export const AppIcon = ({ id, nameLocale, name, icon, backgroundColor, color, notification }) => {
|
||||
export const AppIcon = ({ id, nameLocale, name, Icon, backgroundColor, color, notification }) => {
|
||||
const { t } = useTranslation();
|
||||
const classes = useStyles({
|
||||
backgroundColor: backgroundColor || green[50],
|
||||
@@ -48,7 +53,11 @@ export const AppIcon = ({ id, nameLocale, name, icon, backgroundColor, color, no
|
||||
badgeContent={notification?.badge}
|
||||
invisible={!notification || notification.badge < 2}
|
||||
>
|
||||
<Avatar className={classes.avatar}>{icon || name[0].toUpperCase()}</Avatar>
|
||||
{Icon ? (
|
||||
<Icon className={classes.icon} fontSize="large" />
|
||||
) : (
|
||||
<Avatar className={classes.avatar}>{name[0].toUpperCase()}</Avatar>
|
||||
)}
|
||||
</Badge>
|
||||
</Button>
|
||||
</Tooltip>
|
||||
|
||||
Reference in new issue
Block a user