fix(adminui): one save-error area per driver/device modal; refusal chips print the full message (#847)
This commit is contained in:
+1
-3
@@ -57,7 +57,7 @@
|
||||
</button>
|
||||
</div>
|
||||
}
|
||||
@if (_openError is not null) { <span class="chip chip-bad" title="@_openError">@TruncatedError()</span> }
|
||||
@if (_openError is not null) { <RefusalChip Message="@_openError" /> }
|
||||
</div>
|
||||
|
||||
@if (_token != Guid.Empty)
|
||||
@@ -154,8 +154,6 @@
|
||||
return _useIndex ? $"{_tagName}[{_elementIndex}]" : _tagName;
|
||||
}
|
||||
|
||||
private string TruncatedError() =>
|
||||
_openError is null ? "" : (_openError.Length > 60 ? _openError[..60] + "…" : _openError);
|
||||
|
||||
public ValueTask DisposeAsync()
|
||||
{
|
||||
|
||||
+1
-3
@@ -121,7 +121,7 @@
|
||||
</button>
|
||||
</div>
|
||||
}
|
||||
@if (_openError is not null) { <span class="chip chip-bad" title="@_openError">@TruncatedError()</span> }
|
||||
@if (_openError is not null) { <RefusalChip Message="@_openError" /> }
|
||||
</div>
|
||||
|
||||
@if (_token != Guid.Empty)
|
||||
@@ -228,8 +228,6 @@
|
||||
? FocasAddressBuilder.BuildAlarm(_alarmScope, _alarmLow, _alarmHigh)
|
||||
: FocasAddressBuilder.Build(_kind, _pmcLetter, _number, _bitIndex);
|
||||
|
||||
private string TruncatedError() =>
|
||||
_openError is null ? "" : (_openError.Length > 60 ? _openError[..60] + "…" : _openError);
|
||||
|
||||
public ValueTask DisposeAsync()
|
||||
{
|
||||
|
||||
+1
-3
@@ -42,7 +42,7 @@
|
||||
<span class="chip chip-ok">Browser open</span>
|
||||
<button type="button" class="btn btn-outline-secondary btn-sm" @onclick="CloseBrowseAsync">Close</button>
|
||||
}
|
||||
@if (_openError is not null) { <span class="chip chip-bad" title="@_openError">@TruncatedError()</span> }
|
||||
@if (_openError is not null) { <RefusalChip Message="@_openError" /> }
|
||||
</div>
|
||||
|
||||
@if (_token != Guid.Empty)
|
||||
@@ -215,8 +215,6 @@
|
||||
return $"{_tagName}.{_attributeName}";
|
||||
}
|
||||
|
||||
private string TruncatedError() =>
|
||||
_openError is null ? "" : (_openError.Length > 60 ? _openError[..60] + "…" : _openError);
|
||||
|
||||
public ValueTask DisposeAsync()
|
||||
{
|
||||
|
||||
+1
-3
@@ -40,7 +40,7 @@
|
||||
Close
|
||||
</button>
|
||||
}
|
||||
@if (_openError is not null) { <span class="chip chip-bad" title="@_openError">@TruncatedError()</span> }
|
||||
@if (_openError is not null) { <RefusalChip Message="@_openError" /> }
|
||||
</div>
|
||||
|
||||
@if (_token != Guid.Empty)
|
||||
@@ -113,8 +113,6 @@
|
||||
await CurrentAddressChanged.InvokeAsync(_built);
|
||||
}
|
||||
|
||||
private string TruncatedError() =>
|
||||
_openError is null ? "" : (_openError.Length > 60 ? _openError[..60] + "…" : _openError);
|
||||
|
||||
public ValueTask DisposeAsync()
|
||||
{
|
||||
|
||||
+1
-1
@@ -156,7 +156,7 @@ else
|
||||
<button type="button" class="btn btn-outline-secondary btn-sm" @onclick="CloseBrowseAsync">Close</button>
|
||||
}
|
||||
@* Same open-error chip the five sibling pickers use: abbreviated inline, full text on title. *@
|
||||
@if (_openError is not null) { <span class="chip chip-bad" title="@_openError">@DisplayText.Abbreviate(_openError, 60)</span> }
|
||||
@if (_openError is not null) { <RefusalChip Message="@_openError" /> }
|
||||
</div>
|
||||
|
||||
@if (_token != Guid.Empty)
|
||||
|
||||
+1
-3
@@ -46,7 +46,7 @@
|
||||
</button>
|
||||
</div>
|
||||
}
|
||||
@if (_openError is not null) { <span class="chip chip-bad" title="@_openError">@TruncatedError()</span> }
|
||||
@if (_openError is not null) { <RefusalChip Message="@_openError" /> }
|
||||
</div>
|
||||
|
||||
@if (_token != Guid.Empty)
|
||||
@@ -133,8 +133,6 @@
|
||||
await CurrentAddressChanged.InvokeAsync(_built);
|
||||
}
|
||||
|
||||
private string TruncatedError() =>
|
||||
_openError is null ? "" : (_openError.Length > 60 ? _openError[..60] + "…" : _openError);
|
||||
|
||||
public ValueTask DisposeAsync()
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user