Improve admin field names and generation-safe dialog lifecycle

This commit is contained in:
Joseph Doherty
2026-11-13 21:15:58 -05:00
parent 06b1743051
commit 169149f1eb
82 changed files with 15839 additions and 73 deletions
@@ -10,19 +10,21 @@
@implements IAsyncDisposable
<PageErrorBoundary>
<div class="d-flex justify-content-between align-items-center mb-3">
<div class="d-flex flex-wrap gap-2 justify-content-between align-items-center mb-3">
<h4 class="mb-0">Script log</h4>
<div class="d-flex align-items-center gap-2">
<select class="form-select form-select-sm" style="width:auto" @bind="_levelFilter" @bind:after="RecomputeVisible">
<div class="d-flex flex-wrap align-items-end gap-2" style="max-width:100%;min-width:0">
<div><label class="form-label small mb-1" for="@(_filterScope + "-level")">Log level</label>
<select id="@(_filterScope + "-level")" class="form-select form-select-sm" style="width:auto" @bind="_levelFilter" @bind:after="RecomputeVisible">
<option value="">All levels</option>
<option value="Trace">Trace+</option>
<option value="Debug">Debug+</option>
<option value="Information">Information+</option>
<option value="Warning">Warning+</option>
<option value="Error">Error+</option>
</select>
<input type="text" class="form-control form-control-sm" style="width:200px"
placeholder="Filter script ID…" @bind="_scriptFilter" @bind:event="oninput" @bind:after="RecomputeVisible" />
</select></div>
<div style="max-width:100%;min-width:0"><label class="form-label small mb-1" for="@(_filterScope + "-script")">Script ID</label>
<input id="@(_filterScope + "-script")" type="text" class="form-control form-control-sm" style="width:200px;max-width:100%"
placeholder="Filter script ID…" @bind="_scriptFilter" @bind:event="oninput" @bind:after="RecomputeVisible" /></div>
<span class="conn-pill" data-state="@(_connected ? "connected" : "disconnected")">
<span class="dot"></span><span>@(_connected ? "live" : "disconnected")</span>
</span>
@@ -81,6 +83,7 @@ else
</PageErrorBoundary>
@code {
private readonly string _filterScope = "script-log-" + Guid.NewGuid().ToString("N");
private const int Capacity = 500;
// Newest-first ring, filled from the bridge thread and drained once per coalescing window (R04 P7).
@@ -18,9 +18,10 @@
<div class="panel-head d-flex justify-content-between align-items-center flex-wrap gap-2">
<span>Unified namespace</span>
<div class="d-flex align-items-center gap-2 flex-wrap">
<input type="text" class="form-control form-control-sm" style="max-width:240px"
<div><label class="form-label small mb-1" for="@_filterId">Filter loaded UNS names</label>
<input id="@_filterId" type="text" class="form-control form-control-sm" style="max-width:240px"
placeholder="Filter by name (substring)…"
@bind="_filter" @bind:event="oninput" />
@bind="_filter" @bind:event="oninput" /></div>
<div class="btn-group btn-group-sm" role="group">
<button type="button" class="btn btn-outline-secondary btn-sm" @onclick="ExpandAll">Expand all</button>
<button type="button" class="btn btn-outline-secondary btn-sm" @onclick="CollapseAll">Collapse all</button>
@@ -108,6 +109,7 @@
</PageErrorBoundary>
@code {
private readonly string _filterId = "uns-filter-" + Guid.NewGuid().ToString("N");
private IReadOnlyList<UnsNode> _roots = Array.Empty<UnsNode>();
private string? _filter;
private bool _loading = true;