feat: add support for custom emojis and membership badges in chat display

This commit is contained in:
Yusuf İpek
2025-10-09 01:05:13 +03:00
parent 5a33b01a11
commit fce6ca5708
5 changed files with 188 additions and 35 deletions
+8
View File
@@ -2,6 +2,7 @@ export type Badge = {
type: 'moderator' | 'member' | 'verified' | 'custom';
label?: string;
icon?: string;
imageUrl?: string; // For custom membership badges
};
export type SuperChatInfo = {
@@ -10,12 +11,19 @@ export type SuperChatInfo = {
color: string;
};
export type MessageRun = {
text?: string;
emojiUrl?: string;
emojiAlt?: string;
};
export type ChatMessage = {
id: string;
author: string;
authorPhoto?: string;
authorChannelId?: string;
text: string;
runs?: MessageRun[]; // structured runs for emojis
publishedAt: string;
badges?: Badge[];
isModerator?: boolean;