Skip to content

TT-5727 prevent messages from integration from showing if closed#354

Merged
sarahentzel merged 3 commits into
developfrom
TT-5727
Jun 11, 2026
Merged

TT-5727 prevent messages from integration from showing if closed#354
sarahentzel merged 3 commits into
developfrom
TT-5727

Conversation

@sarahentzel

Copy link
Copy Markdown
Collaborator

No description provided.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR aims to prevent Paratext integration UI side-effects (notably snackbar/toast messages) from appearing after the Integration dialog has been closed, by ensuring the integration panel is unmounted when the dialog is not open and by guarding message emission against unmounted state.

Changes:

  • Conditionally mount/unmount the IntegrationTab inside BigDialog so it is only rendered while the dialog is open.
  • Add useMounted checks in IntegrationPanel to avoid emitting messages after the component has unmounted, and reset Paratext-related Redux state on unmount.
  • Minor formatting adjustment to a logError call for readability/consistency.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated no comments.

File Description
src/renderer/src/control/ProjButtons.tsx Only render IntegrationTab while the Integration dialog is open (prevents late UI messages after close).
src/renderer/src/components/Team/ProjectCard.tsx Same conditional mounting of IntegrationTab for the Team Project card integration dialog.
src/renderer/src/components/MediaRecord.tsx Formatting-only change to logError call.
src/renderer/src/components/Integration.tsx Add useMounted gating for message display and reset Paratext slice state on unmount to prevent stale/status messages after close.

@sarahentzel sarahentzel requested a review from gtryus June 11, 2026 15:32
@sarahentzel sarahentzel merged commit e19415b into develop Jun 11, 2026
2 checks passed
@sarahentzel sarahentzel deleted the TT-5727 branch June 11, 2026 19:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants