|
|
@ -90,7 +90,8 @@ const AnvilSummary: FC<AnvilSummaryProps> = (props) => { |
|
|
|
anvil && ( |
|
|
|
anvil && ( |
|
|
|
<Grid |
|
|
|
<Grid |
|
|
|
alignItems="center" |
|
|
|
alignItems="center" |
|
|
|
columns={4} |
|
|
|
columns={20} |
|
|
|
|
|
|
|
columnSpacing="0.5em" |
|
|
|
container |
|
|
|
container |
|
|
|
sx={{ |
|
|
|
sx={{ |
|
|
|
[`& > .${gridClasses.item}:nth-child(-n + 4)`]: { |
|
|
|
[`& > .${gridClasses.item}:nth-child(-n + 4)`]: { |
|
|
@ -107,38 +108,34 @@ const AnvilSummary: FC<AnvilSummaryProps> = (props) => { |
|
|
|
let servers: ReactNode; |
|
|
|
let servers: ReactNode; |
|
|
|
|
|
|
|
|
|
|
|
if (['offline', 'online'].includes(state)) { |
|
|
|
if (['offline', 'online'].includes(state)) { |
|
|
|
servers = ( |
|
|
|
servers = <MonoText variant="caption">{serverCount}</MonoText>; |
|
|
|
<BodyText variant="caption" whiteSpace="nowrap"> |
|
|
|
|
|
|
|
Servers{' '} |
|
|
|
|
|
|
|
<InlineMonoText sx={{ paddingRight: 0 }}> |
|
|
|
|
|
|
|
{serverCount} |
|
|
|
|
|
|
|
</InlineMonoText> |
|
|
|
|
|
|
|
</BodyText> |
|
|
|
|
|
|
|
); |
|
|
|
|
|
|
|
} else { |
|
|
|
} else { |
|
|
|
stateValue = `${stateProgress}%`; |
|
|
|
stateValue = `${stateProgress}%`; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
return [ |
|
|
|
return [ |
|
|
|
<Grid item key={`${uuid}-state-label`} xs={1}> |
|
|
|
<Grid item key={`${uuid}-state-label`} xs={7}> |
|
|
|
<BodyText variant="caption" whiteSpace="nowrap"> |
|
|
|
<BodyText variant="caption" whiteSpace="nowrap"> |
|
|
|
{name} |
|
|
|
{name} |
|
|
|
</BodyText> |
|
|
|
</BodyText> |
|
|
|
</Grid>, |
|
|
|
</Grid>, |
|
|
|
<Grid item key={`${uuid}-state`} xs={1}> |
|
|
|
<Grid item key={`${uuid}-state`} xs={5}> |
|
|
|
<MonoText inheritColour color={stateColour}> |
|
|
|
<MonoText inheritColour color={stateColour}> |
|
|
|
{stateValue} |
|
|
|
{stateValue} |
|
|
|
</MonoText> |
|
|
|
</MonoText> |
|
|
|
</Grid>, |
|
|
|
</Grid>, |
|
|
|
<Grid item key={`${uuid}-divider`} xs={1}> |
|
|
|
<Grid item key={`${uuid}-divider`} xs> |
|
|
|
<Divider sx={{ marginBottom: '-.2em' }} /> |
|
|
|
<Divider sx={{ marginBottom: '-.4em' }} /> |
|
|
|
|
|
|
|
</Grid>, |
|
|
|
|
|
|
|
<Grid item key={`${uuid}-server-label`} width="2.2em"> |
|
|
|
|
|
|
|
{servers && <BodyText variant="caption">Servers</BodyText>} |
|
|
|
</Grid>, |
|
|
|
</Grid>, |
|
|
|
<Grid |
|
|
|
<Grid |
|
|
|
display="flex" |
|
|
|
display="flex" |
|
|
|
item |
|
|
|
item |
|
|
|
justifyContent="flex-end" |
|
|
|
justifyContent="flex-end" |
|
|
|
key={`${uuid}-server-count`} |
|
|
|
key={`${uuid}-server-count`} |
|
|
|
xs={1} |
|
|
|
width="2em" |
|
|
|
> |
|
|
|
> |
|
|
|
{servers} |
|
|
|
{servers} |
|
|
|
</Grid>, |
|
|
|
</Grid>, |
|
|
@ -167,13 +164,13 @@ const AnvilSummary: FC<AnvilSummaryProps> = (props) => { |
|
|
|
alignItems="center" |
|
|
|
alignItems="center" |
|
|
|
columns={2} |
|
|
|
columns={2} |
|
|
|
container |
|
|
|
container |
|
|
|
minWidth="calc(0% + 3.2em)" |
|
|
|
|
|
|
|
sx={{ |
|
|
|
sx={{ |
|
|
|
|
|
|
|
width: '3.7em', |
|
|
|
|
|
|
|
|
|
|
|
[`& > .${gridClasses.item}:nth-child(-n + 2)`]: { |
|
|
|
[`& > .${gridClasses.item}:nth-child(-n + 2)`]: { |
|
|
|
marginBottom: '-.6em', |
|
|
|
marginBottom: '-.6em', |
|
|
|
}, |
|
|
|
}, |
|
|
|
}} |
|
|
|
}} |
|
|
|
width="calc(0% + 3.2em)" |
|
|
|
|
|
|
|
> |
|
|
|
> |
|
|
|
<Grid item xs={1}> |
|
|
|
<Grid item xs={1}> |
|
|
|
<BodyText variant="caption">Cores</BodyText> |
|
|
|
<BodyText variant="caption">Cores</BodyText> |
|
|
|