Skip to content

regression: Jump to message not working for audio played from quoted messages - #41601

Merged
dionisio-bot[bot] merged 2 commits into
release-8.7.0from
regression/quoted-audio-jump-to-message
Jul 28, 2026
Merged

regression: Jump to message not working for audio played from quoted messages#41601
dionisio-bot[bot] merged 2 commits into
release-8.7.0from
regression/quoted-audio-jump-to-message

Conversation

@KevLehman

@KevLehman KevLehman commented Jul 28, 2026

Copy link
Copy Markdown
Member

Proposed changes (including videos or screenshots)

When audio is played from a quoted or forwarded message, the Jump to message action in the Now Playing sidebar card did nothing.

Quote attachments are split out of the message's attachment list and rendered by a separate <Attachments> call in RoomMessageContent/ThreadMessageContent that did not pass the source context (rid/mid), and QuoteAttachment dropped it for its inner attachments as well. The track registered by AudioAttachment therefore had no room/message reference and openConversation in NowPlayingSection bailed out early.

Now source is passed to the quotes render in both message variants and threaded through AttachmentsItemQuoteAttachment → inner Attachments, so the card jumps to the message containing the quote. The track name is taken from the quote's author_name, so the card attributes the audio to the quoted author rather than the quoting user.

Verified end-to-end with Playwright against a local server: playing from a quote, switching rooms, and clicking Jump to message navigates to /channel/<room>?msg=<quoting message id>; non-quoted audio unchanged.

Issue(s)

https://rocketchat.atlassian.net/browse/CORE-2486

Steps to test or reproduce

  1. Send an audio file in a channel
  2. Quote that message (or forward it to another channel)
  3. Play the audio from the quoted/forwarded message
  4. Switch to another channel
  5. Hover the Now Playing card in the sidebar and click Jump to message
  6. You are taken back to the message containing the quote

Further comments

Summary by CodeRabbit

  • Enhancements
    • Improved quoted audio attachment handling in room and thread messages.
    • Preserved attachment source information when displaying quoted content.
    • Enhanced nested attachments with relevant message and author details for more consistent behavior.

@dionisio-bot

dionisio-bot Bot commented Jul 28, 2026

Copy link
Copy Markdown
Contributor

Looks like this PR is ready to merge! 🎉
If you have any trouble, please check the PR guidelines

@coderabbitai

coderabbitai Bot commented Jul 28, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: b3540357-7b09-4a2a-92af-60a547d7ee0f

📥 Commits

Reviewing files that changed from the base of the PR and between 008fee8 and 2b99385.

📒 Files selected for processing (4)
  • apps/meteor/client/components/message/content/attachments/AttachmentsItem.tsx
  • apps/meteor/client/components/message/content/attachments/QuoteAttachment.tsx
  • apps/meteor/client/components/message/variants/room/RoomMessageContent.tsx
  • apps/meteor/client/components/message/variants/thread/ThreadMessageContent.tsx
📜 Recent review details
⏰ Context from checks skipped due to timeout. (3)
  • GitHub Check: 📊 Report Coverage
  • GitHub Check: cubic · AI code reviewer
  • GitHub Check: Hacktron Security Check
🧰 Additional context used
📓 Path-based instructions (1)
**/*.{ts,tsx,js}

📄 CodeRabbit inference engine (.cursor/rules/playwright.mdc)

**/*.{ts,tsx,js}: Write concise, technical TypeScript/JavaScript with accurate typing in Playwright tests
Avoid code comments in the implementation

Files:

  • apps/meteor/client/components/message/content/attachments/AttachmentsItem.tsx
  • apps/meteor/client/components/message/variants/thread/ThreadMessageContent.tsx
  • apps/meteor/client/components/message/variants/room/RoomMessageContent.tsx
  • apps/meteor/client/components/message/content/attachments/QuoteAttachment.tsx
🧠 Learnings (2)
📚 Learning: 2026-03-27T14:52:56.865Z
Learnt from: dougfabris
Repo: RocketChat/Rocket.Chat PR: 39892
File: apps/meteor/client/views/room/contextualBar/Threads/Thread.tsx:150-155
Timestamp: 2026-03-27T14:52:56.865Z
Learning: In Rocket.Chat, there are two different `ModalBackdrop` components with different prop APIs. During review, confirm the import source: (1) `rocket.chat/fuselage` `ModalBackdrop` uses `ModalBackdropProps` based on `BoxProps` (so it supports `onClick` and other Box/DOM props) and does not have an `onDismiss` prop; (2) `rocket.chat/ui-client` `ModalBackdrop` uses a narrower props interface like `{ children?: ReactNode; onDismiss?: () => void }` and handles Escape keypress and outside mouse-up, and it does not forward arbitrary DOM props such as `onClick`. Flag mismatched props (e.g., `onDismiss` passed to the fuselage component or `onClick` passed to the ui-client component) and ensure the usage matches the correct component being imported.

Applied to files:

  • apps/meteor/client/components/message/content/attachments/AttachmentsItem.tsx
  • apps/meteor/client/components/message/variants/thread/ThreadMessageContent.tsx
  • apps/meteor/client/components/message/variants/room/RoomMessageContent.tsx
  • apps/meteor/client/components/message/content/attachments/QuoteAttachment.tsx
📚 Learning: 2026-05-06T12:21:44.083Z
Learnt from: juliajforesti
Repo: RocketChat/Rocket.Chat PR: 40256
File: apps/meteor/client/components/CreateDiscussion/CreateDiscussion.tsx:121-149
Timestamp: 2026-05-06T12:21:44.083Z
Learning: Field wrappers in rocket.chat/fuselage-forms (Field, FieldLabel, FieldRow, FieldError, FieldHint) auto-create htmlFor/id associations, aria-describedby, and role="alert" for errors. Do not manually set htmlFor, id, aria-describedby, or role attributes when using these wrappers. This automatic wiring does not apply to plain rocket.chat/fuselage components, which require explicit ID wiring per the accessibility docs. In code reviews, prefer using fuselage-forms wrappers for form fields and verify there is no unnecessary manual ID/aria wiring in files that use these wrappers. If a component uses plain fuselage components, ensure proper id wiring as per docs.

Applied to files:

  • apps/meteor/client/components/message/content/attachments/AttachmentsItem.tsx
  • apps/meteor/client/components/message/variants/thread/ThreadMessageContent.tsx
  • apps/meteor/client/components/message/variants/room/RoomMessageContent.tsx
  • apps/meteor/client/components/message/content/attachments/QuoteAttachment.tsx
🔇 Additional comments (4)
apps/meteor/client/components/message/content/attachments/QuoteAttachment.tsx (1)

9-9: LGTM!

Also applies to: 38-41, 70-74

apps/meteor/client/components/message/content/attachments/AttachmentsItem.tsx (1)

22-22: LGTM!

apps/meteor/client/components/message/variants/room/RoomMessageContent.tsx (1)

60-65: LGTM!

apps/meteor/client/components/message/variants/thread/ThreadMessageContent.tsx (1)

54-59: LGTM!


Walkthrough

Quote attachment rendering now propagates audio attachment source metadata from room and thread messages through AttachmentsItem and QuoteAttachment to nested attachments.

Changes

Quote attachment source propagation

Layer / File(s) Summary
Source contract and nested forwarding
apps/meteor/client/components/message/content/attachments/QuoteAttachment.tsx, apps/meteor/client/components/message/content/attachments/AttachmentsItem.tsx
QuoteAttachment accepts an optional AudioAttachmentSource, derives nested source metadata, and AttachmentsItem forwards the source prop.
Message quote source construction
apps/meteor/client/components/message/variants/room/RoomMessageContent.tsx, apps/meteor/client/components/message/variants/thread/ThreadMessageContent.tsx
Room and thread quote attachment renders provide message identifiers and author metadata through the source prop.

Estimated code review effort: 1 (Trivial) | ~5 minutes

Possibly related PRs

Suggested labels: type: bug

Suggested reviewers: tassoevan, dougfabris, ggazzo

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately describes the regression fix for jump-to-message on audio from quoted messages.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

Warning

Review ran into problems

🔥 Problems

Errors were encountered while retrieving linked issues.

Errors (1)
  • CORE-2486: Request failed with status code 401

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@changeset-bot

changeset-bot Bot commented Jul 28, 2026

Copy link
Copy Markdown

⚠️ No Changeset found

Latest commit: 2b99385

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@codecov

codecov Bot commented Jul 28, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 68.75000% with 5 lines in your changes missing coverage. Please review.
⚠️ Please upload report for BASE (release-8.7.0@9ac66cc). Learn more about missing BASE report.

Additional details and impacted files

Impacted file tree graph

@@               Coverage Diff                @@
##             release-8.7.0   #41601   +/-   ##
================================================
  Coverage                 ?   68.40%           
================================================
  Files                    ?     4139           
  Lines                    ?   158310           
  Branches                 ?    28307           
================================================
  Hits                     ?   108287           
  Misses                   ?    44894           
  Partials                 ?     5129           
Flag Coverage Δ
e2e 58.86% <100.00%> (?)
e2e-api 45.38% <ø> (?)
unit 70.32% <60.00%> (?)

Flags with carried forward coverage won't be shown. Click here to find out more.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@KevLehman KevLehman added this to the 8.7.0 milestone Jul 28, 2026
@KevLehman
KevLehman marked this pull request as ready for review July 28, 2026 15:41
@KevLehman
KevLehman requested a review from a team as a code owner July 28, 2026 15:41

@cubic-dev-ai cubic-dev-ai Bot 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.

No issues found across 4 files

Re-trigger cubic

@cardoso cardoso added the stat: QA assured Means it has been tested and approved by a company insider label Jul 28, 2026
@dionisio-bot dionisio-bot Bot added the stat: ready to merge PR tested and approved waiting for merge label Jul 28, 2026
@dionisio-bot
dionisio-bot Bot merged commit 9bd5a7d into release-8.7.0 Jul 28, 2026
98 of 101 checks passed
@dionisio-bot
dionisio-bot Bot deleted the regression/quoted-audio-jump-to-message branch July 28, 2026 15:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

stat: QA assured Means it has been tested and approved by a company insider stat: ready to merge PR tested and approved waiting for merge type: bug

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants