Files
Enciphered.Blazor.UIComponents/Enciphered.Blazor.UIComponents/Card/CardDescription.razor
T
2026-04-13 15:39:41 +05:00

23 lines
729 B
Plaintext

@namespace Enciphered.Blazor.UIComponents
<p data-slot="card-description" class="@ComputedClass" @attributes="AdditionalAttributes">
@ChildContent
</p>
@code {
/// <summary>Description text or markup rendered below the title.</summary>
[Parameter] public RenderFragment? ChildContent { get; set; }
/// <summary>Additional CSS classes.</summary>
[Parameter] public string? Class { get; set; }
[Parameter(CaptureUnmatchedValues = true)]
public Dictionary<string, object>? AdditionalAttributes { get; set; }
private const string BaseClass =
"text-sm text-muted-foreground";
private string ComputedClass =>
string.IsNullOrEmpty(Class) ? BaseClass : $"{BaseClass} {Class}";
}