feat(ui,worker): surface task numbers in row/detail UI and worker log

Slice 4/5 of task-numbers: TaskRowViewModel.Number renders as a dimmed
"#123" before the row title; DetailsIslandViewModel.TaskIdBadge now
shows "#123" instead of the unusable "#T<guid-prefix>" handle; and the
curated WorkerLog business events in TaskRunner, TaskMergeService, and
TaskResetService prefix their quoted title with "#<Number>".
This commit is contained in:
mika kuns
2026-08-11 13:51:20 +02:00
parent a1aeb21481
commit 38af549a80
11 changed files with 361 additions and 38 deletions
@@ -22,6 +22,24 @@ public class TaskRowViewModelTests
Assert.Equal(expected, vm.StatusChipClass);
}
[Fact]
public void Number_SetFromEntity_SurvivesUpdateFromEntity()
{
var entity = new TaskEntity
{
Id = "t", ListId = "l1", Title = "Task", Number = 123, CreatedAt = DateTime.UtcNow,
};
var vm = TaskRowViewModel.FromEntity(entity);
Assert.Equal(123, vm.Number);
// Simulates the TaskUpdated refresh path: the entity is re-fetched and the same
// row is updated in place rather than replaced.
entity.Title = "Task (edited)";
vm.UpdateFromEntity(entity);
Assert.Equal(123, vm.Number);
}
[Fact]
public void IsDropTarget_Follows_Either_DropHint_And_Raises_PropertyChanged()
{