8.L: collapse release/track name for single-track media (Session, Mix)

BatchTrackDetail gains ShowTrackName parameter (default true); BatchUpload removes the
Track Name input on the single-track path; BatchEdit suppresses it there too. Both sync
_tracks[0].TrackName = _albumName on submit/save so names can never diverge. Cut path
unchanged.
This commit is contained in:
daniel-c-harvey
2026-06-13 19:46:05 -04:00
parent add43c5a7d
commit 1b37a637e5
3 changed files with 34 additions and 12 deletions
@@ -59,10 +59,7 @@
<InputFile OnChange="HandleSingleWavSelected" accept=".wav,audio/wav,audio/x-wav" disabled="@_uploading" />
@if (_tracks.Count > 0)
{
<MudTextField @bind-Value="_tracks[0].TrackName"
Label="Track Name"
Variant="Variant.Outlined"
Disabled="_uploading" />
@* Track name is derived from the Release Name for Session/Mix — no separate input. *@
<MudText Typo="Typo.caption">Selected: @(_tracks[0].WavFile?.Name ?? "—")</MudText>
}
</MudStack>
@@ -247,6 +244,13 @@
return;
}
// For single-track media (Session/Mix) the track name is derived from the Release Name —
// no separate Track Name input is shown. Sync here so the stored name always matches.
if (MediumRules.CardinalityOf(_medium).IsSingleTrack && _tracks.Count > 0)
{
_tracks[0].TrackName = _albumName;
}
_imagePath = null; // Clear any stale uploaded path from a prior partial attempt.
_uploading = true;
_uploadedCount = 0;