Quiet resting cells in tables canvas

This commit is contained in:
2026-03-21 15:10:06 +01:00
parent ae582367d6
commit 9cfb9ac364
3 changed files with 41 additions and 18 deletions

View File

@@ -29,6 +29,7 @@
if (TryGetCell(rollBand.Label, displayColumn.GroupKey, displayColumn.ColumnKey, out var resolvedCell) && resolvedCell is not null)
{
var cell = resolvedCell;
var isSelectedCell = IsSelectedCell(cell);
@if (MatchesModeFilter(cell))
{
@@ -41,24 +42,34 @@
}
else
{
<button
type="button"
class="critical-cell-action-button is-curation"
title="Open the curation preview for this cell."
@onclick:stopPropagation="true"
@onclick="() => OnOpenCuration.InvokeAsync(cell.ResultId)">
Needs Curation
</button>
<span class="critical-cell-status-chip needs-curation">Needs Curation</span>
}
<button
type="button"
class="critical-cell-action-button is-edit"
title="Open the full editor for this cell."
@onclick:stopPropagation="true"
@onclick="() => OnOpenEditor.InvokeAsync(cell.ResultId)">
Edit
</button>
@if (isSelectedCell)
{
<div class="critical-cell-selected-actions">
@if (!cell.IsCurated)
{
<button
type="button"
class="critical-cell-action-button is-curation"
title="Open the curation preview for this cell."
@onclick:stopPropagation="true"
@onclick="() => OnOpenCuration.InvokeAsync(cell.ResultId)">
Curate
</button>
}
<button
type="button"
class="critical-cell-action-button is-edit"
title="Open the full editor for this cell."
@onclick:stopPropagation="true"
@onclick="() => OnOpenEditor.InvokeAsync(cell.ResultId)">
Edit
</button>
</div>
}
</div>
<CompactCriticalCell
@@ -317,5 +328,8 @@
private Task SelectCell(CriticalTableCellDetail cell) =>
OnSelectCell.InvokeAsync(new TablesCellSelection(cell.ResultId, cell.RollBand, cell.ColumnKey, cell.GroupKey));
private bool IsSelectedCell(CriticalTableCellDetail cell) =>
SelectedCell is not null && cell.ResultId == SelectedCell.ResultId;
private static string BuildColumnSpanStyle(int span) => $"grid-column: span {span};";
}

View File

@@ -1619,6 +1619,13 @@ pre,
flex-wrap: wrap;
}
.critical-cell-selected-actions {
display: inline-flex;
align-items: center;
gap: 0.35rem;
margin-left: auto;
}
.critical-cell-action-button {
border: 1px solid rgba(127, 96, 55, 0.18);
border-radius: 999px;
@@ -1636,7 +1643,7 @@ pre,
}
.critical-cell-action-button.is-edit {
margin-left: auto;
margin-left: 0;
}
.critical-cell-action-button:hover {