Skip to content

Commit

Permalink
NCL-8671 Return missing Tooltip to Group Build status icon
Browse files Browse the repository at this point in the history
  • Loading branch information
patrikk0123 committed Apr 22, 2024
1 parent 91ba717 commit 01ace04
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/components/BuildStatusIcon/BuildStatusIcon.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,11 @@ export const BuildStatusIcon = ({ build, long }: IBuildStatusIcon) => {

return (
<span className={styles['build-status-icon']}>
{isBuild(build) ? <BuildLogLink build={build}>{buildImage}</BuildLogLink> : buildImage}
{isBuild(build) ? (
<BuildLogLink build={build}>{buildImage}</BuildLogLink>
) : (
<TooltipWrapper tooltip={build.status && buildStatusData[build.status].tooltip}>{buildImage}</TooltipWrapper>
)}
{isCorrupted && (
<Tooltip
removeFindDomNode
Expand Down Expand Up @@ -101,7 +105,7 @@ const BuildLogLink = ({ build, children }: PropsWithChildren<IBuildLogLinkProps>
const buildLogLink = useMemo(() => getAdequateBuildLogLink(build), [build]);

return (
<TooltipWrapper tooltip={<span>{buildStatusData[build.status!].tooltip}. Click to open the log</span>}>
<TooltipWrapper tooltip={build.status && `${buildStatusData[build.status].tooltip}. Click to open the log`}>
<Link to={buildLogLink} className={styles['build-log-link']}>
{children}
</Link>
Expand Down

0 comments on commit 01ace04

Please sign in to comment.