Skip to content

Commit

Permalink
some bit more cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
coliu-akamai committed Oct 11, 2024
1 parent 6183ec0 commit dbe9387
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 15 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -16,15 +16,6 @@ export const StyledBox = styled(Box, { label: 'StyledBox' })(({ theme }) => ({
},
}));

export const StyledLabelBox = styled(Box, { label: 'StyledLabelBox' })(
({ theme }) => ({
alignItems: 'center',
display: 'flex',
fontFamily: theme.font.bold,
marginRight: theme.spacing(0.5),
})
);

export const StyledActionRowGrid = styled(Grid, {
label: 'StyledActionRowGrid',
})({
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@ import { KubeControlPlaneACLDrawer } from './KubeControlPaneACLDrawer';
import {
StyledActionRowGrid,
StyledBox,
StyledLabelBox,
StyledTagGrid,
} from './KubeSummaryPanel.styles';

Expand Down Expand Up @@ -82,13 +81,10 @@ export const KubeSummaryPanel = React.memo((props: Props) => {
const {
data: aclData,
error: isErrorKubernetesACL,
// isFetching: isFetchingKubernetesACL,
isLoading: isLoadingKubernetesACL,
// refetch: refetchKubernetesACL,
} = useKubernetesControlPlaneACLQuery(cluster.id);

const enabledACL = aclData?.acl.enabled ?? false;
// const revisionIDACL = acl_response ? acl_response.acl['revision-id'] : '';
const totalIPv4 = aclData?.acl.addresses?.ipv4?.length ?? 0;
const totalIPv6 = aclData?.acl.addresses?.ipv6?.length ?? 0;
const totalNumberIPs = totalIPv4 + totalIPv6;
Expand Down Expand Up @@ -192,9 +188,14 @@ export const KubeSummaryPanel = React.memo((props: Props) => {
xs={12}
>
<StyledBox>
<StyledLabelBox component="span">
<Typography
sx={{
fontFamily: theme.font.bold,
marginRight: theme.spacing(0.5),
}}
>
Control Plane ACL:
</StyledLabelBox>
</Typography>
{isLoadingKubernetesACL ? (
<Box sx={{ paddingLeft: 1 }}>
<CircleProgress noPadding size="sm" />
Expand Down

0 comments on commit dbe9387

Please sign in to comment.