@namespace Lumeo

<Badge Variant="Badge.BadgeVariant.Secondary" Class="@($"flex items-center gap-1 pl-2 pr-1 {Class}".Trim())" @attributes="AdditionalAttributes">
    @Label: @Value
    <button type="button" class="ml-1 rounded-full hover:bg-muted p-0.5 focus-visible:outline-none focus-visible:ring-[1.5px] focus-visible:ring-ring focus-visible:ring-offset-1" aria-label="@($"Remove {Label} filter")" @onclick="OnDismiss">
        <Blazicon Svg="Lucide.X" class="h-3 w-3" />
    </button>
</Badge>

@code {
    [Parameter] public string Label { get; set; } = "";
    [Parameter] public string Value { get; set; } = "";
    [Parameter] public EventCallback OnDismiss { get; set; }
    [Parameter] public string? Class { get; set; }
    [Parameter(CaptureUnmatchedValues = true)] public Dictionary<string, object>? AdditionalAttributes { get; set; }
}
