Add Alert component

This commit is contained in:
hishamco 2020-09-17 15:09:20 +03:00
parent 38f2fa5733
commit 3613ce62eb
2 changed files with 32 additions and 0 deletions

View File

@ -0,0 +1,22 @@
@namespace Oqtane.Modules.Controls
@inherits ModuleControlBase
@if (!string.IsNullOrEmpty(Message))
{
<div class="alert alert-@(Type.ToString().ToLower()) alert-dismissible fade show" role="alert">
@Message
</div>
}
@code {
[Parameter]
public string Message { get; set; }
[Parameter]
public AlertType Type { get; set; }
protected override void OnInitialized()
{
base.OnInitialized();
}
}

View File

@ -0,0 +1,10 @@
namespace Oqtane.Modules.Controls
{
public enum AlertType
{
Information,
Danger,
Success,
Warning
}
}