120 in printWidth since rocky got md

This commit is contained in:
Christopher committed 2021-03-02 20:56:15 +01:00
1 parent f552c1212c
commit d27aeb3b0e
90 files changed
+398 -1146

No files matched your search

+21 -35
View File
@@ -5,38 +5,28 @@ import { green } from '@material-ui/core/colors';
import { Badge, Button, Tooltip, Zoom } from '@material-ui/core';
import { useTranslation } from 'react-i18next';
const useStyles = makeStyles<Theme, { color: string; backgroundColor: string }>(
(theme) => ({
root: {
padding: 0,
marginTop: theme.spacing(3),
const useStyles = makeStyles<Theme, { color: string; backgroundColor: string }>((theme) => ({
root: {
padding: 0,
marginTop: theme.spacing(3),
},
avatar: {
'&:hover': {
backgroundColor: ({ backgroundColor }) => darken(backgroundColor, 0.1),
},
avatar: {
'&:hover': {
backgroundColor: ({ backgroundColor }) => darken(backgroundColor, 0.1),
},
backgroundColor: ({ backgroundColor }) => backgroundColor,
color: ({ color }) => color,
boxShadow: theme.shadows[2],
width: theme.spacing(8),
height: theme.spacing(8),
fontSize: theme.typography.h4.fontSize,
},
tooltip: {
fontSize: 12,
},
}),
);
backgroundColor: ({ backgroundColor }) => backgroundColor,
color: ({ color }) => color,
boxShadow: theme.shadows[2],
width: theme.spacing(8),
height: theme.spacing(8),
fontSize: theme.typography.h4.fontSize,
},
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],
@@ -53,11 +43,7 @@ export const AppIcon = ({
TransitionComponent={Zoom}
>
<Button className={classes.root}>
<Badge
color="error"
badgeContent={notification?.badge}
invisible={!notification || notification.badge < 2}
>
<Badge color="error" badgeContent={notification?.badge} invisible={!notification || notification.badge < 2}>
<Avatar className={classes.avatar}>{icon || name[0].toUpperCase()}</Avatar>
</Badge>
</Button>