Class MessageViewModel
One item of the open room's timeline.
Inheritance
MessageViewModel
Assembly: Uniform.Chat.Avalonia.dll
public sealed class MessageViewModel : ViewModelBase, INotifyPropertyChanged, INotifyPropertyChanging
Properties
|
Edit this page
View Source
Declaration
[ObservableProperty]
[NotifyPropertyChangedFor("HasDay")]
[ExcludeFromCodeCoverage]
public string? Day { get; set; }
Property Value
|
Edit this page
View Source
Event ID; null for messages still in the outbox.
Declaration
public string? EventId { get; init; }
Property Value
|
Edit this page
View Source
File name to save an attachment as.
Declaration
public string? FileName { get; init; }
Property Value
|
Edit this page
View Source
Get whether Day is shown.
Declaration
public bool HasDay { get; }
Property Value
|
Edit this page
View Source
Whether there are reactions.
Declaration
public bool HasReactions { get; }
Property Value
|
Edit this page
View Source
Declaration
public bool HasSenderAvatar { get; }
Property Value
|
Edit this page
View Source
Declaration
[ObservableProperty]
[ExcludeFromCodeCoverage]
public string? Html { get; set; }
Property Value
|
Edit this page
View Source
mxc:// URI of an image to show a thumbnail of.
Declaration
public string? ImageUri { get; init; }
Property Value
|
Edit this page
View Source
Whether it is an image, file, audio or video that can be saved.
Declaration
public bool IsAttachment { get; }
Property Value
|
Edit this page
View Source
Declaration
[ObservableProperty]
[ExcludeFromCodeCoverage]
public bool IsEdited { get; set; }
Property Value
|
Edit this page
View Source
Whether it mentions the signed-in user.
Declaration
public bool IsHighlight { get; init; }
Property Value
|
Edit this page
View Source
Whether it is a membership or state change, shown smaller.
Declaration
public bool IsInfo { get; }
Property Value
|
Edit this page
View Source
Whether the signed-in user sent it.
Declaration
public bool IsOwn { get; init; }
Property Value
|
Edit this page
View Source
Whether the message is still in the outbox.
Declaration
public bool IsPending { get; }
Property Value
|
Edit this page
View Source
Declaration
public required MessageKind Kind { get; init; }
Property Value
|
Edit this page
View Source
Outbox row of a message not sent yet.
Declaration
public long? OutboxId { get; init; }
Property Value
|
Edit this page
View Source
Declaration
[ObservableProperty]
[NotifyPropertyChangedFor("HasReactions")]
[ExcludeFromCodeCoverage]
public string Reactions { get; set; }
Property Value
|
Edit this page
View Source
The message this one answers, as Bob: snippet; null when it is not a reply.
Declaration
public string? ReplyQuote { get; init; }
Property Value
|
Edit this page
View Source
Declaration
[ObservableProperty]
[NotifyPropertyChangedFor("IsPending")]
[ExcludeFromCodeCoverage]
public string SendState { get; set; }
Property Value
|
Edit this page
View Source
Declaration
[ObservableProperty]
[NotifyPropertyChangedFor("HasSenderAvatar")]
[ExcludeFromCodeCoverage]
public Bitmap? SenderAvatar { get; set; }
Property Value
|
Edit this page
View Source
mxc:// URI of the sender's picture in the room, or null.
Declaration
public string? SenderAvatarUri { get; init; }
Property Value
|
Edit this page
View Source
Declaration
public required string SenderId { get; init; }
Property Value
|
Edit this page
View Source
First letter of the sender's name, shown as their avatar.
Declaration
public string SenderInitial { get; }
Property Value
|
Edit this page
View Source
Sender's display name in the room.
Declaration
public required string SenderName { get; init; }
Property Value
|
Edit this page
View Source
Declaration
[ObservableProperty]
[ExcludeFromCodeCoverage]
public bool ShowHeader { get; set; }
Property Value
|
Edit this page
View Source
Text
Declaration
[ObservableProperty]
[ExcludeFromCodeCoverage]
public string Text { get; set; }
Property Value
|
Edit this page
View Source
Declaration
[ObservableProperty]
[ExcludeFromCodeCoverage]
public Bitmap? Thumbnail { get; set; }
Property Value
|
Edit this page
View Source
TimeText
Time as shown, e.g. 14:05.
Declaration
public string TimeText { get; }
Property Value
|
Edit this page
View Source
Declaration
public required DateTimeOffset Timestamp { get; init; }
Property Value
Implements