Skip to content

Commit 0c0ea75

Browse files
authored
feat: add attributes field to ReceivedChatMessage (#1176)
1 parent 6368c04 commit 0c0ea75

File tree

1 file changed

+2
-0
lines changed
  • packages/core/src/components

1 file changed

+2
-0
lines changed

packages/core/src/components/chat.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ export type { ChatMessage };
1616
/** @public */
1717
export interface ReceivedChatMessage extends ChatMessage {
1818
from?: Participant;
19+
attributes?: Record<string, string>;
1920
}
2021

2122
export interface LegacyChatMessage extends ChatMessage {
@@ -169,6 +170,7 @@ export function setupChat(room: Room, options?: ChatOptions) {
169170
const receivedChatMsg: ReceivedChatMessage = {
170171
...chatMsg,
171172
from: room.localParticipant,
173+
attributes: options.attributes,
172174
};
173175

174176
messageSubject.next(receivedChatMsg);

0 commit comments

Comments
 (0)