Add filters to the dashboard catch list and filter by clicking top 10 rows
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
8eeb7894a3
commit
9f07d41cb0
11 files changed
+771
-83
No files matched your search
@@ -28,21 +28,25 @@ else
|
||||
var key = KeyFormatter?.Invoke(entry.Key) ?? entry.Key;
|
||||
var label = LabelFormatter is null ? entry.Label : LabelFormatter(entry.Key, entry.Label);
|
||||
var share = (entry.Count * 100.0 / Entries[0].Count).ToString("0.#", CultureInfo.InvariantCulture);
|
||||
<tr data-expand="@($"{KeyLabel}:{entry.Key}")" tabindex="0" aria-expanded="false">
|
||||
<td class="clip" title="@(label is null ? key : $"{label} · {key}")">
|
||||
@if (ShowFlags)
|
||||
{
|
||||
<span class="flag">@Formatting.Flag(entry.Key)</span>
|
||||
}
|
||||
@if (label is not null)
|
||||
{
|
||||
<span class="top-label">@label</span>
|
||||
<span class="top-key mono">@key</span>
|
||||
}
|
||||
else
|
||||
{
|
||||
<span class="mono">@key</span>
|
||||
}
|
||||
var active = IsActive(entry);
|
||||
var title = label is null ? key : $"{label} · {key}";
|
||||
<tr data-href="@Href(entry)" class="@(active ? "active" : null)">
|
||||
<td class="clip" title="@title">
|
||||
<a href="@Href(entry)" aria-current="@(active ? "true" : null)" title="@(active ? $"Filter {title} entfernen" : $"Fänge filtern: {title}")">
|
||||
@if (ShowFlags)
|
||||
{
|
||||
<span class="flag">@Formatting.Flag(entry.Key)</span>
|
||||
}
|
||||
@if (label is not null)
|
||||
{
|
||||
<span class="top-label">@label</span>
|
||||
<span class="top-key mono">@key</span>
|
||||
}
|
||||
else
|
||||
{
|
||||
<span class="mono">@key</span>
|
||||
}
|
||||
</a>
|
||||
</td>
|
||||
<td><span class="share-bar" style="--share: @(share)%"></span></td>
|
||||
<td class="num">@Formatting.Number(entry.Count)</td>
|
||||
@@ -63,4 +67,8 @@ else
|
||||
[Parameter] public Func<string?, string?>? KeyFormatter { get; set; }
|
||||
|
||||
[Parameter] public Func<string?, string?, string?>? LabelFormatter { get; set; }
|
||||
|
||||
[Parameter, EditorRequired] public required Func<TopEntry, string> Href { get; set; }
|
||||
|
||||
[Parameter, EditorRequired] public required Func<TopEntry, bool> IsActive { get; set; }
|
||||
}
|
||||
Reference in new issue
Block a user