Skip to content

Commit 1c6d7b3

Browse files
committed
Start working on tooltip
1 parent 4f42d4b commit 1c6d7b3

File tree

1 file changed

+5
-7
lines changed

1 file changed

+5
-7
lines changed

site/src/components/Resources/AgentMetadata.tsx

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -96,12 +96,6 @@ const MetadataItem: FC<{ item: WorkspaceAgentMetadata }> = ({ item }) => {
9696
classes={{ paper: styles.metadataPopover }}
9797
>
9898
<HelpTooltipTitle>{item.description.display_name}</HelpTooltipTitle>
99-
<HelpTooltipText>
100-
This item was collected{" "}
101-
{dayjs.duration(item.result.age, "s").humanize()} ago and will be
102-
updated in{" "}
103-
{dayjs.duration(Math.min(updatesInSeconds, 0), "s").humanize()}.
104-
</HelpTooltipText>
10599
{isStale ? (
106100
<HelpTooltipText>
107101
This item is now stale because the agent hasn{"'"}t reported a new
@@ -111,7 +105,11 @@ const MetadataItem: FC<{ item: WorkspaceAgentMetadata }> = ({ item }) => {
111105
<></>
112106
)}
113107
<HelpTooltipText>
114-
This item is collected by running the following command:
108+
This item was collected{" "}
109+
{dayjs.duration(item.result.age, "s").humanize()} ago and will be
110+
updated in{" "}
111+
{dayjs.duration(Math.min(updatesInSeconds, 0), "s").humanize()} by
112+
running the following command:
115113
</HelpTooltipText>
116114
<HelpTooltipText>
117115
<CodeExample code={item.description.script}></CodeExample>

0 commit comments

Comments
 (0)