feat: chat stickers
This commit is contained in:
@@ -168,6 +168,7 @@ export default function ChatThreadPage() {
|
||||
replyToId?: string,
|
||||
previewUrl?: string,
|
||||
attachments?: UploadedAttachment[],
|
||||
stickerKey?: string,
|
||||
) => {
|
||||
const clientMsgId = crypto.randomUUID();
|
||||
const optimistic: ChatMessage = {
|
||||
@@ -188,7 +189,13 @@ export default function ChatThreadPage() {
|
||||
setMessages((prev) => [...prev, optimistic]);
|
||||
|
||||
chat
|
||||
.send(id, body, { clientMsgId, replyToId, previewUrl, attachments })
|
||||
.send(id, body, {
|
||||
clientMsgId,
|
||||
replyToId,
|
||||
previewUrl,
|
||||
attachments,
|
||||
stickerKey,
|
||||
})
|
||||
.then((saved) => {
|
||||
setMessages((prev) => {
|
||||
// Drop the placeholder and any realtime echo of the same message.
|
||||
|
||||
Reference in New Issue
Block a user