mirror of
https://github.com/RedWizardsLab/EchoHub.git
synced 2026-09-04 08:36:11 +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:
@@ -15,9 +15,10 @@ public static class HubConstants
|
||||
public const int AsciiArtHeightHalfBlock = 80;
|
||||
|
||||
// Link embed constants
|
||||
public const int EmbedThumbnailWidth = 24;
|
||||
public const int EmbedThumbnailHeight = 12;
|
||||
public const int EmbedMaxDescriptionLength = 200;
|
||||
public const int EmbedIconWidth = 12;
|
||||
public const int EmbedIconHeight = 6;
|
||||
public const int EmbedMaxDescriptionLength = 500;
|
||||
public const int EmbedMaxHtmlBytes = 64 * 1024; // 64 KB
|
||||
public const int EmbedFetchTimeoutSeconds = 3;
|
||||
public const int EmbedMaxUrlsPerMessage = 3;
|
||||
}
|
||||
|
||||
@@ -12,7 +12,7 @@ public record MessageDto(
|
||||
string? AttachmentUrl,
|
||||
string? AttachmentFileName,
|
||||
DateTimeOffset SentAt,
|
||||
EmbedDto? Embed = null);
|
||||
List<EmbedDto>? Embeds = null);
|
||||
|
||||
public record ChannelDto(
|
||||
Guid Id,
|
||||
|
||||
Reference in New Issue
Block a user