feat: add Content Attribute.
This commit is contained in:
@@ -16,7 +16,9 @@
|
||||
<u:Notification Content="Hello, Ursa!" />
|
||||
</u:NotificationCard>
|
||||
<u:NotificationCard NotificationType="Error" Classes="Light">
|
||||
<u:Notification Title="Welcome" Content="Hello, Ursa!" />
|
||||
<u:Notification Title="Welcome">
|
||||
Hello, Ursa!
|
||||
</u:Notification>
|
||||
</u:NotificationCard>
|
||||
</ReversibleStackPanel>
|
||||
</ThemeVariantScope>
|
||||
|
||||
@@ -10,7 +10,9 @@
|
||||
Hello, Ursa!
|
||||
</u:ToastCard>
|
||||
<u:ToastCard NotificationType="Success" Classes="Light">
|
||||
<u:Toast Content="Hello, Ursa!" />
|
||||
<u:Toast>
|
||||
Hello, Ursa!
|
||||
</u:Toast>
|
||||
</u:ToastCard>
|
||||
</ReversibleStackPanel>
|
||||
</ThemeVariantScope>
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
using System.ComponentModel;
|
||||
using System.Runtime.CompilerServices;
|
||||
using Avalonia.Controls.Notifications;
|
||||
using Avalonia.Metadata;
|
||||
|
||||
namespace Ursa.Controls;
|
||||
|
||||
@@ -66,6 +67,7 @@ public class Notification : INotification, INotifyPropertyChanged
|
||||
}
|
||||
|
||||
/// <inheritdoc/>
|
||||
[Content]
|
||||
public string? Content
|
||||
{
|
||||
get => _content;
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
using System.ComponentModel;
|
||||
using System.Runtime.CompilerServices;
|
||||
using Avalonia.Controls.Notifications;
|
||||
using Avalonia.Metadata;
|
||||
|
||||
namespace Ursa.Controls;
|
||||
|
||||
@@ -49,6 +50,7 @@ public class Toast : IToast, INotifyPropertyChanged
|
||||
}
|
||||
|
||||
/// <inheritdoc/>
|
||||
[Content]
|
||||
public string? Content
|
||||
{
|
||||
get => _content;
|
||||
|
||||
Reference in New Issue
Block a user