Skip to content

Commit

Permalink
Problems: show item value in tooltip, fix #1145
Browse files Browse the repository at this point in the history
  • Loading branch information
alexanderzobnin committed Feb 4, 2021
1 parent 52b8317 commit fdaadaf
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/panel-triggers/components/Problems/ProblemDetails.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -216,11 +216,13 @@ interface ProblemItemProps {
function ProblemItem(props: ProblemItemProps) {
const { item, showName } = props;
const itemName = utils.expandItemName(item.name, item.key_);
const tooltipContent = () => <>{itemName}<br/>{item.lastvalue}</>;

return (
<div className="problem-item">
<FAIcon icon="thermometer-three-quarters" />
{showName && <span className="problem-item-name">{item.name}: </span>}
<Tooltip placement="top-start" content={itemName}>
<Tooltip placement="top-start" content={tooltipContent}>
<span className="problem-item-value">{item.lastvalue}</span>
</Tooltip>
</div>
Expand Down

0 comments on commit fdaadaf

Please sign in to comment.