Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions packages/manager/src/MainContent_CMR.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,10 @@ const useStyles = makeStyles((theme: Theme) => ({
paddingTop: theme.spacing(2),
paddingLeft: 0,
paddingRight: 0
},
[theme.breakpoints.between('md', 'lg')]: {
paddingLeft: theme.spacing(2),
paddingRight: theme.spacing(2)
}
},
content: {
Expand Down
42 changes: 6 additions & 36 deletions packages/manager/src/components/EntityIcon/EntityIcon.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ import FirewallIcon from 'src/assets/icons/entityIcons/firewall.svg';
import FolderIcon from 'src/assets/icons/entityIcons/folder.svg';
import KubeIcon from 'src/assets/icons/entityIcons/kubernetes.svg';
import LinodeIcon from 'src/assets/icons/entityIcons/linode.svg';
import LoadingIcon from 'src/assets/icons/entityIcons/loading.svg';
import NodeBalancerIcon from 'src/assets/icons/entityIcons/nodebalancer.svg';
import ObjectIcon from 'src/assets/icons/entityIcons/object.svg';
import StackScriptIcon from 'src/assets/icons/entityIcons/stackscript.svg';
Expand All @@ -28,9 +27,6 @@ type ClassNames =
| 'icon'
| 'running'
| 'offline'
| 'maintenance'
| 'loading'
| 'loadingIcon'
| 'animated';

const styles = (theme: Theme) =>
Expand Down Expand Up @@ -58,14 +54,8 @@ const styles = (theme: Theme) =>
offline: {
color: theme.color.grey1
},
maintenance: {},
loading: {
position: 'absolute',
top: 0,
left: 0
},
loadingIcon: {
fill: theme.color.offBlack
error: {
color: theme.color.red
},
animated: {
animation: '$rotate 2s linear infinite'
Expand Down Expand Up @@ -122,7 +112,6 @@ const EntityIcon: React.FC<CombinedProps> = props => {
size,
className,
marginTop,
stopAnimation,
...rest
} = props;

Expand All @@ -143,7 +132,7 @@ const EntityIcon: React.FC<CombinedProps> = props => {
case 'disabled':
return 'offline';
case 'has_errors':
return 'offline';
return 'error';
default:
return 'offline';
}
Expand All @@ -164,8 +153,8 @@ const EntityIcon: React.FC<CombinedProps> = props => {
className={classNames(
{
[classes.root]: true,
[classes.default]: !loading,
[classes[`${finalStatus}`]]: !loading
[classes.default]: true,
[classes[`${finalStatus}`]]: true
},
className
)}
Expand All @@ -176,26 +165,7 @@ const EntityIcon: React.FC<CombinedProps> = props => {
aria-label={`${variant} is ${finalStatus}`}
{...rest}
>
<Icon
className={classNames({
[classes.icon]: true,
['loading']: loading
})}
width={iconSize}
height={iconSize}
/>
{loading && (
<div className={classes.loading}>
<LoadingIcon
className={classNames({
[classes.loadingIcon]: true,
[classes.animated]: !stopAnimation
})}
width={iconSize - 2}
height={iconSize - 2}
/>
</div>
)}
<Icon className={classes.icon} width={iconSize} height={iconSize} />
</div>
);
};
Expand Down