Skip to content

Commit

Permalink
🚀 feat: add status description for pods (cyclops-ui#414)
Browse files Browse the repository at this point in the history
* feat: add status description for pods

Signed-off-by: Ruihua Wen <[email protected]>

* feat: add a tooltip with the status description in the image column

Signed-off-by: Ruihua Wen <[email protected]>

---------

Signed-off-by: Ruihua Wen <[email protected]>
  • Loading branch information
SpiffyEight77 authored Jul 17, 2024
1 parent 21facd6 commit ac4cc9f
Showing 1 changed file with 21 additions and 6 deletions.
27 changes: 21 additions & 6 deletions cyclops-ui/src/components/k8s-resources/common/PodTable.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import {
Tabs,
Modal,
Alert,
Tooltip,
} from "antd";
import axios from "axios";
import { formatPodAge } from "../../../utils/pods";
Expand Down Expand Up @@ -181,13 +182,27 @@ const PodTable = ({ pods, namespace }: Props) => {
}

return (
<Tag
color={color}
key={container.image}
style={{ fontSize: "100%" }}
<Tooltip
key={container.name}
title={
<div>
<div key={container.name}>
<strong>{container.name}:</strong>{" "}
{container.status.status}
<br />
<small>{container.status.message}</small>
</div>
</div>
}
>
{container.image}
</Tag>
<Tag
color={color}
key={container.image}
style={{ fontSize: "100%" }}
>
{container.image}
</Tag>
</Tooltip>
);
})}
</>
Expand Down

0 comments on commit ac4cc9f

Please sign in to comment.