AI Integration Quick Reference
AI Integration Quick Reference
Available from UI Kit v6.1.1. This component requires
cometchat_chat_uikit v6.1.1 or later, which depends on cometchat_sdk v5.0.7.CometChatSavedMessages lists the logged-in user’s saved (bookmarked) messages across every conversation — unlike Pinned Messages, it is not scoped to one chat. Rows are ordered newest-saved-first. Each row shows the conversation’s avatar and name, a preview of the message, and the date it was saved; a thread reply is titled by its author (“You” for your own) instead of the conversation name.
Saves are private to the logged-in user and sync across their own devices.
Where It Fits
Saved messages are user-level, so the entry point belongs in app chrome — a profile or user menu on the conversations screen, a settings row, or a navigation tab — not inside a single chat. The kit does not add one for you.Quick Start
- Dart
onItemTap usually has to open the conversation first and then jump — see the Pin & Save Messages guide.
Actions and Events
Callback Methods
onItemTap
Fires when a row is tapped. With popOnItemTap left at true, the screen asks its route to pop first, so the conversation you open is not stacked on top of the list.
Unsave
Long-pressing a row opens an Unsave message? confirmation, then unsaves the message and shows a “Message unsaved” toast. SethideUnsaveOption: true to turn the long-press off.
Real-Time Updates (Automatic)
The list is fetched once on open, 100 at a time until exhausted, with a Retry action if the fetch fails and an empty state (“No saved messages yet”) when there are none.
Functionality
Responsive presentation
popOnItemTap and useCloseButton let one component serve both layouts: a pushed mobile route that pops on jump, and a desktop panel that stays put and closes with a ✕.
- Dart
Style
- Dart
On v6.1.1,
unsaveIconColor is declared but has no visible effect — upgrade to v6.2.0 to use it. The class also declares itemContextTextStyle, which no release up to v6.2.0 applies.Next Steps
Pin & Save Messages Guide
Wire the pinned and saved screens into your app
Pinned Messages
A conversation’s pinned list
Message List
The Save / Unsave options and jump-to-message
Save A Message (SDK)
The SDK APIs underneath