mirror of
https://github.com/RedWizardsLab/EchoHub.git
synced 2026-09-05 15:46:01 +02:00
feat: Add notification sound functionality and embed support
- Introduced NotificationConfig to manage notification settings, including sound file. - Added Notification.mp3 asset for notifications. - Implemented NotificationSoundService to handle playing notification sounds. - Enhanced ChatRenderer and MainWindow to support emoji rendering. - Updated MessageDto to allow multiple embeds per message. - Modified LinkEmbedService to fetch multiple embeds from message content. - Added data migration for legacy embed JSON format to new array format. - Adjusted embed handling in ChatService and IrcMessageFormatter to accommodate multiple embeds. - Updated HubConstants for new embed dimensions and limits.
This commit is contained in:
@@ -24,9 +24,12 @@ public static partial class IrcMessageFormatter
|
||||
foreach (var chunk in SplitMessage(message.Content, MaxIrcLineContentBytes))
|
||||
lines.Add($"{prefix} PRIVMSG {ircChannel} :{chunk}");
|
||||
|
||||
// Append embed preview if present
|
||||
if (message.Embed is not null)
|
||||
lines.AddRange(FormatEmbed(prefix, ircChannel, message.Embed));
|
||||
// Append embed previews if present
|
||||
if (message.Embeds is { Count: > 0 })
|
||||
{
|
||||
foreach (var embed in message.Embeds)
|
||||
lines.AddRange(FormatEmbed(prefix, ircChannel, embed));
|
||||
}
|
||||
break;
|
||||
|
||||
case MessageType.Image:
|
||||
|
||||
Reference in New Issue
Block a user