feat(routing): add ReleaseRoutes.DetailHref resolver; repoint release click sites and add /tracks/{id} redirect (P11 W2 §2)

This commit is contained in:
daniel-c-harvey
2026-06-16 10:56:28 -04:00
parent 74b9c02722
commit 55515981a9
8 changed files with 128 additions and 18 deletions
@@ -6,11 +6,23 @@
{
<div class="track-meta-row">
<div class="track-meta-identity">
<a href="@($"/track/{Track.EntryKey}")" style="text-decoration: none;">
@* Title links to the release's dedicated detail page via the shared resolver (§2): the
TrackDto already carries Release { Id, Medium }, so no round-trip is needed. When no
release is attached there is no medium to resolve, so the title renders unlinked. *@
@if (Track.Release is not null)
{
<a href="@ReleaseRoutes.DetailHref(Track.Release)" style="text-decoration: none;">
<MudText Typo="Typo.subtitle2" Class="track-meta-title text-truncate">
@Track.TrackName
</MudText>
</a>
}
else
{
<MudText Typo="Typo.subtitle2" Class="track-meta-title text-truncate">
@Track.TrackName
</MudText>
</a>
}
<MudText Typo="Typo.subtitle2" Class="track-meta-sep"> - </MudText>
<MudText Typo="Typo.caption" Class="track-meta-artist text-truncate">
@Track.Release?.Artist