Skip to content

Commit 48fb8ed

Browse files
snigdhasscttcper
authored andcommitted
fix(activity): Update activity message for linked issues (#82064)
Use the `new` field added in #73069 to update the message shown for the CREATE_ISSUE activity. This should add the distinction of whether an external issue was linked or created. Fixes #77410 --------- Co-authored-by: Scott Cooper <[email protected]>
1 parent d11793b commit 48fb8ed

File tree

3 files changed

+14
-1
lines changed

3 files changed

+14
-1
lines changed

Diff for: static/app/types/group.tsx

+1
Original file line numberDiff line numberDiff line change
@@ -642,6 +642,7 @@ export interface GroupActivityCreateIssue extends GroupActivityBase {
642642
location: string;
643643
provider: string;
644644
title: string;
645+
new?: boolean;
645646
};
646647
type: GroupActivityType.CREATE_ISSUE;
647648
}

Diff for: static/app/views/issueDetails/groupActivityItem.tsx

+7
Original file line numberDiff line numberDiff line change
@@ -474,6 +474,13 @@ function GroupActivityItem({
474474
}
475475
case GroupActivityType.CREATE_ISSUE: {
476476
const {data} = activity;
477+
if (data.new === true) {
478+
return tct('[author] linked this issue to [issue] on [provider]', {
479+
author,
480+
issue: <ExternalLink href={data.location}>{data.title}</ExternalLink>,
481+
provider: data.provider,
482+
});
483+
}
477484
return tct('[author] created an issue on [provider] titled [title]', {
478485
author,
479486
provider: data.provider,

Diff for: static/app/views/issueDetails/streamline/sidebar/groupActivityItem.tsx

+6-1
Original file line numberDiff line numberDiff line change
@@ -493,8 +493,13 @@ export default function getGroupActivityItem(
493493
}
494494
case GroupActivityType.CREATE_ISSUE: {
495495
const {data} = activity;
496+
let title = t('Created Issue');
497+
if (data.new === true) {
498+
title = t('Linked Issue');
499+
}
500+
496501
return {
497-
title: t('Created Issue'),
502+
title: title,
498503
message: tct('by [author] on [provider] titled [title]', {
499504
author,
500505
provider: data.provider,

0 commit comments

Comments
 (0)