feat: ✨ File message type and trailing parameter (for custom file i… #360
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.
✨ New Feature: Add File Message Type Support with Open File Capability and Enhanced Input Field Customization
Video Recording
file-message-demo.mp4
Description
This pull request significantly enhances ChatView by introducing a new file message type and improving the customizability of the chat input field. Users can now send and receive files, with the added functionality to open these files directly from the chat interface. Additionally, the existing
trailingparameter of the text field is highlighted as a powerful way to add custom icons, such as a file picker, to the chat composer.FEATURES
File Message Type and File Opening on Tap
This feature introduces the capability to handle and display messages that represent files. A new
FileMessageViewwidget is integrated to render these messages. Furthermore, users can now open these files directly from the chat UI by tapping on the message, facilitated by theopen_filexpackage. The reply message view also supports a distinct display for file messages.Screenshots
Code
Enhanced Input Field Customization via
trailingparameterThis feature leverages the existing
trailingparameter withinSendMessageConfigurationto provide greater flexibility for adding custom widgets to the chat input field. Developers can now easily integrate elements like a file attachment icon, stickers button, or any other custom functionality directly into the message composer's right side.Screenshots
Code
Checklist
fix:,feat:,docs:etc).docsand added dartdoc comments with///.examplesordocs.Breaking Change?
Related Issues