Skip to content

Commit

Permalink
fix(ui): fixed topology display
Browse files Browse the repository at this point in the history
  • Loading branch information
powerfooI committed Jan 9, 2025
1 parent d7f0dd2 commit ac7324f
Showing 1 changed file with 12 additions and 3 deletions.
15 changes: 12 additions & 3 deletions ui/src/pages/Cluster/Detail/Overview/BasicInfo.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -47,10 +47,16 @@ const nodeSelectorColumns: ColumnsType<ExtendedAffinity> = [
{
title: 'Values',
dataIndex: 'values',
render(value: string[] | undefined) {
return value?.join(', ') || '-';
},
},
{
title: 'Weight',
dataIndex: 'weight',
render(value: number | undefined) {
return value || '-';
},
},
];

Expand Down Expand Up @@ -78,6 +84,9 @@ const tolerationColumns: ColumnsType<ExtendedToleration> = [
{
title: 'Value',
dataIndex: 'value',
render(value: string | undefined) {
return value || '-';
},
},
{
title: 'Effect',
Expand Down Expand Up @@ -308,7 +317,7 @@ export default function BasicInfo({
</Title>
{topologyRendering.nodeSelectors.length > 0 && (
<>
<Text style={{ marginBottom: 8, display: 'block' }}>
<Text style={{ marginBottom: 8, marginTop: 8, display: 'block' }}>
Node Selector
</Text>
<Table
Expand All @@ -323,7 +332,7 @@ export default function BasicInfo({
)}
{topologyRendering.affinities.length > 0 && (
<>
<Text style={{ marginBottom: 8, display: 'block' }}>
<Text style={{ marginBottom: 8, marginTop: 8, display: 'block' }}>
Pod Affinity
</Text>
<Table
Expand All @@ -338,7 +347,7 @@ export default function BasicInfo({
)}
{topologyRendering.tolerations.length > 0 && (
<>
<Text style={{ marginBottom: 8, display: 'block' }}>
<Text style={{ marginBottom: 8, marginTop: 8, display: 'block' }}>
Tolerations
</Text>
<Table
Expand Down

0 comments on commit ac7324f

Please sign in to comment.