Skip to content

Commit

Permalink
🐛 Add tooltip for unlink jira ticket (#1643)
Browse files Browse the repository at this point in the history
  • Loading branch information
ibolton336 authored Dec 19, 2023
1 parent 413eea0 commit c458ed0
Show file tree
Hide file tree
Showing 3 changed files with 27 additions and 12 deletions.
5 changes: 3 additions & 2 deletions client/public/locales/en/translation.json
Original file line number Diff line number Diff line change
Expand Up @@ -214,7 +214,8 @@
"taskInProgressForTags": "A new analysis is in-progress. Tags may be updated upon completion.",
"toTagApplication": "Either no tags exist yet or you may not have permission to view any. If you have permission, try creating a new custom tag.",
"unsavedChanges": "Are you sure you want to close the assessment? Any unsaved changes will be lost.",
"noAnswers": "Are you sure you want to close the assessment? There are no answers to save."
"noAnswers": "Are you sure you want to close the assessment? There are no answers to save.",
"unlinkTicket": "Unlink from Jira"
},
"proposedActions": {
"refactor": "Refactor",
Expand Down Expand Up @@ -308,7 +309,7 @@
"date": "Date",
"decision": "Decision",
"dependencies": "Dependencies",
"dependentQuestion": "Dependent question",
"dependentQuestion": "Conditional question",
"description": "Description",
"details": "Details",
"displayName": "Display name",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import {
Grid,
GridItem,
Spinner,
Tooltip,
} from "@patternfly/react-core";
import { Application } from "@app/api/models";
import spacing from "@patternfly/react-styles/css/utilities/Spacing/spacing";
Expand Down Expand Up @@ -187,11 +188,17 @@ export const ApplicationDetailFields: React.FC<{
isLoading ? (
<Spinner role="status" size="sm" />
) : (
<Button
variant="link"
icon={<UnlinkIcon />}
onClick={() => deleteTicket(matchingTicket.id)}
/>
<Tooltip
content={t("message.unlinkTicket")}
position="top"
entryDelay={1000}
>
<Button
variant="link"
icon={<UnlinkIcon />}
onClick={() => deleteTicket(matchingTicket.id)}
/>
</Tooltip>
)
) : null}
</Text>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import {
Toolbar,
ToolbarContent,
ToolbarItem,
Tooltip,
} from "@patternfly/react-core";
import { Table, Tbody, Td, Th, Thead, Tr } from "@patternfly/react-table";
import alignment from "@patternfly/react-styles/css/utilities/Alignment/alignment";
Expand Down Expand Up @@ -165,11 +166,17 @@ export const WaveStatusTable: React.FC<IWaveStatusTableProps> = ({
</Td>
<Td className={alignment.textAlignRight}>
{ticket?.id && (
<Button
variant="link"
icon={<UnlinkIcon />}
onClick={() => deleteTicket(ticket.id)}
/>
<Tooltip
content={t("message.unlinkTicket")}
position="top"
entryDelay={1000}
>
<Button
variant="link"
icon={<UnlinkIcon />}
onClick={() => deleteTicket(ticket.id)}
/>
</Tooltip>
)}
<Button
type="button"
Expand Down

0 comments on commit c458ed0

Please sign in to comment.