diff options
Diffstat (limited to '')
-rw-r--r-- | LibMatrix/StateEventTypes/Spec/RoomAvatarEventData.cs | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/LibMatrix/StateEventTypes/Spec/RoomAvatarEventData.cs b/LibMatrix/StateEventTypes/Spec/RoomAvatarEventData.cs new file mode 100644 index 0000000..cbe41dd --- /dev/null +++ b/LibMatrix/StateEventTypes/Spec/RoomAvatarEventData.cs @@ -0,0 +1,28 @@ +using System.Text.Json.Serialization; +using LibMatrix.Extensions; +using LibMatrix.Interfaces; + +namespace LibMatrix.StateEventTypes.Spec; + +[MatrixEvent(EventName = "m.room.avatar")] +public class RoomAvatarEventData : IStateEventType { + [JsonPropertyName("url")] + public string? Url { get; set; } + + [JsonPropertyName("info")] + public RoomAvatarInfo? Info { get; set; } + + public class RoomAvatarInfo { + [JsonPropertyName("h")] + public int? Height { get; set; } + + [JsonPropertyName("w")] + public int? Width { get; set; } + + [JsonPropertyName("mimetype")] + public string? MimeType { get; set; } + + [JsonPropertyName("size")] + public int? Size { get; set; } + } +} |