feat(public-nav): slim appbar to ARCHIVE + inline CUTS/SESSIONS/MIXES, drop GENRES and Tracks (8.I)

Desktop flattens the ARCHIVE popover into inline appbar links above the medium
breakpoint; mobile keeps the indented sub-list under ARCHIVE. GENRES and /tracks
removed from nav only — routes (GenresView, TracksView) remain reachable by URL.
Retires the now-dead desktop hover-popover and its 8.J collapse-state machinery
(mobile drawer still dismisses on click).
This commit is contained in:
daniel-c-harvey
2026-06-13 21:26:44 -04:00
parent 2991d9ec5d
commit 743c2c3d02
3 changed files with 14 additions and 91 deletions
@@ -10,32 +10,17 @@
<ul class="dd-nav-links">
@foreach (var navPage in Pages.MenuPages)
{
@if (navPage.HasChildren)
{
@* Dual-role node: the parent anchor navigates to its own route on click,
while hover/focus reveals the child dropdown (pure CSS, no JS).
dd-nav-item-collapsed is added on child click to force-hide the
dropdown after SPA navigation (which keeps the DOM and may leave
:hover true). It is cleared on mouseleave so the next hover works. *@
<li class="dd-nav-item-parent @(_collapsedDropdowns.Contains(navPage.Route) ? "dd-nav-item-collapsed" : "")"
@onmouseleave="() => ResetDropdown(navPage.Route)"
@onfocusout="() => ResetDropdown(navPage.Route)">
<a href="@navPage.Route" class="dd-nav-link">@navPage.Name</a>
<ul class="dd-nav-dropdown">
@foreach (var child in navPage.Children)
{
<li>
<a href="@child.Route" class="dd-nav-link dd-nav-dropdown-link"
@onclick="() => CollapseDropdown(navPage.Route)">@child.Name</a>
</li>
}
</ul>
</li>
}
else
@* Above the medium breakpoint the medium modes ride inline beside their parent:
the parent link renders, then each child renders as its own sibling appbar link.
No popover — so the 8.J stuck-open dismissal applies only to the mobile drawer
below, where clicks close the menu. *@
<li>
<a href="@navPage.Route" class="dd-nav-link">@navPage.Name</a>
</li>
@foreach (var child in navPage.Children)
{
<li>
<a href="@navPage.Route" class="dd-nav-link">@navPage.Name</a>
<a href="@child.Route" class="dd-nav-link">@child.Name</a>
</li>
}
}
@@ -96,7 +81,6 @@
[Parameter] public required EventCallback<bool> IsDarkModeChanged { get; set; }
private bool _mobileMenuOpen;
private readonly HashSet<string> _collapsedDropdowns = [];
protected override async Task OnAfterRenderAsync(bool firstRender)
{
@@ -129,8 +113,4 @@
private void ToggleMobileMenu() => _mobileMenuOpen = !_mobileMenuOpen;
private void CloseMobileMenu() => _mobileMenuOpen = false;
private void CollapseDropdown(string route) => _collapsedDropdowns.Add(route);
private void ResetDropdown(string route) => _collapsedDropdowns.Remove(route);
}