Skip to content

Audio recording playback fails and renamed downloads use incorrect file format #1247

@rohitbansal2005

Description

@rohitbansal2005

Description:

When users record and send an audio message, audio behavior is inconsistent in Storybook/local integration:

  • Sent audio sometimes shows 0:00 / 0:00 and controls appear non-functional due to media URL access issues.
  • If the attachment filename is renamed (especially without extension or with a wrong extension), download may use an incorrect format/extension.
  • Console also shows related warnings errors (CORS/403 for file URLs, and DOM nesting warning in message rendering context).

Steps to reproduce:

  1. Connect EmbeddedChat to local Rocket.Chat (http://localhost:3000) and run UI via Storybook (http://localhost:6006).
  2. Record an audio message from chat input and send it.
  3. Try to play the sent audio from message area.
  4. Rename attachment name (e.g., hello or hello.txt) and download it.
  5. Open browser console and observe network runtime warnings.

Expected behavior:

  1. Sent audio should play normally (play button and seek slider functional).
  2. Downloaded file should keep a valid audio format extension based on actual media type.
  3. Renaming should not convert force audio into an incorrect extension.
  4. No DOM nesting warnings for normal message rendering.
Video.Project.4.mp4

Actual behavior:

  1. Audio media URL requests fail with 403 / CORS preflight errors in Storybook-to-Rocket.Chat setup.
  2. Audio appears as 0:00 / 0:00 and playback is not usable.
  3. Renamed downloads can end up with incorrect extension handling in some flows.
  4. Console warning appears: validateDOMNesting(...):
    cannot appear as a descendant of

    .

Video.Project.3.mp4

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions