feat: add voice message duration display to VoiceMessageView#427
Draft
feat: add voice message duration display to VoiceMessageView#427
Conversation
Co-authored-by: vatsaltanna-simformsolutions <63704011+vatsaltanna-simformsolutions@users.noreply.github.com>
Co-authored-by: vatsaltanna-simformsolutions <63704011+vatsaltanna-simformsolutions@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Fix issue in voice message duration display
feat: add voice message duration display to VoiceMessageView
Jan 22, 2026
Copilot started reviewing on behalf of
vatsaltanna-simformsolutions
January 23, 2026 20:06
View session
There was a problem hiding this comment.
Pull request overview
This PR adds visible duration display for voice messages in the main chat bubble, leveraging the existing voiceMessageDuration field and the toHHMMSS() extension, and exposes configuration to style that duration text along with documentation updates.
Changes:
- Update
VoiceMessageViewto rendervoiceMessageDurationnext to the waveform when present, formatted viatoHHMMSS(). - Extend
VoiceMessageConfigurationwith an optionaldurationTextStyleto customize the duration label appearance. - Document voice message duration usage and styling in
doc/documentation.md, including examples for message creation and configuration.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
lib/src/widgets/voice_message_view.dart |
Renders the voice message duration text conditionally after the waveform, using VoiceMessageConfiguration.durationTextStyle with a sensible default. |
lib/src/models/config_models/voice_message_configuration.dart |
Adds the new durationTextStyle field to the configuration model and documents its purpose. |
doc/documentation.md |
Adds a new “Voice Message Duration” section and updates the voice message configuration example to show how to style the duration label. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Voice messages support
voiceMessageDurationparameter in the Message model but the duration wasn't rendered in the VoiceMessageView widget. Duration was only visible in reply message previews.Changes:
voiceMessageDurationafter the waveform using the existingtoHHMMSS()extensiondurationTextStyleparameter for styling customization (defaults to 12px white text)doc/documentation.mdUsage:
Customize appearance via configuration:
Checklist
fix:,feat:,docs:etc).docsand added dartdoc comments with///.examplesordocs.Breaking Change?
Original prompt
💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.