Skip to content

Commit

Permalink
Merge pull request #39040 from margelo/perunt/linking-rerender
Browse files Browse the repository at this point in the history
Blinking on chat switching
  • Loading branch information
NikkiWines authored Mar 28, 2024
2 parents 2b96626 + 8ec3050 commit a3f777e
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/pages/home/report/ReportActionsView.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,12 @@ function ReportActionsView({
setCurrentReportActionID('');
}, [route]);

// Change the list ID only for comment linking to get the positioning right
const listID = useMemo(() => {
if (!reportActionID) {
// Keep the old list ID since we're not in the Comment Linking flow
return listOldID;
}
isFirstLinkedActionRender.current = true;
const newID = generateNewRandomInt(listOldID, 1, Number.MAX_SAFE_INTEGER);
listOldID = newID;
Expand Down

0 comments on commit a3f777e

Please sign in to comment.