@model string

@{
    var badgeClass = Model?.ToLowerInvariant() switch
    {
        "active" or "success" => "badge bg-success",
        "inactive" or "disabled" => "badge bg-secondary",
        "pending" or "processing" => "badge bg-warning",
        "error" or "failed" => "badge bg-danger",
        _ => "badge bg-info"
    };
}

<span class="@badgeClass">@Model</span>
