feat(cms): extract all-releases grid as embeddable ALL-tab component (9.8.B)

CmsAllReleasesGrid self-loads the cross-medium release list so 8.A can host it as the ALL tab with no VM plumbing; TrackList's Albums mode renders it now. Preserves sort/delete/expand/edit and the 8.D Type chip.
This commit is contained in:
daniel-c-harvey
2026-06-13 21:26:43 -04:00
parent 2991d9ec5d
commit e78a61c3b1
4 changed files with 77 additions and 30 deletions
@@ -125,14 +125,15 @@ else
private List<AlbumRow> _rows = new();
// Tracks the Releases reference last projected into _rows. Guards against OnParametersSet
// resurrecting a row we removed locally on delete: VM.Albums is cached for the circuit and is
// not re-fetched after a delete, so a blind rebuild every render would bring the deleted album
// back. We only re-project when the parent hands us a genuinely new list.
// resurrecting a row we removed locally on delete: while the parent holds the same Releases
// instance (e.g. a mid-operation re-render under IsDeleting, before any refresh hands us a new
// list), a blind rebuild every render would bring the deleted row back. We only re-project when
// the parent hands us a genuinely new list.
private IReadOnlyList<ReleaseDto>? _projectedReleases;
// Re-project rows only when the parent supplies a genuinely new release list (reference change).
// Local edits to _rows (a removed row after delete) must survive re-renders triggered by the
// same cached VM.Albums instance.
// same Releases instance.
protected override void OnParametersSet()
{
if (!ReferenceEquals(_projectedReleases, Releases))
@@ -245,7 +246,7 @@ else
// Delete an orphaned release (0 live tracks) via the release endpoint. Mirrors the track-cascade
// delete path's row lifecycle: confirm, guard with IsDeleting, then remove the row and notify the
// parent so the cached VM.Albums stays in sync with what is shown.
// parent so its release list stays in sync with what is shown.
private async Task ConfirmAndDeleteEmptyReleaseAsync(AlbumRow row)
{
var confirmed = await DialogService.ShowMessageBox(