Push profile/tag taps inside the detail overlay
Created by: jedmund
Summary
- Wrap
IllustDetailOverlayin its ownNavigationStack(path:)and registerProfileDestination/PixivIllust.Tagdestinations on it.IllustDetailContent's user-row and tag-pill buttons were reading\.pushDestinationfrom an env that resolved tonil(the overlay is a sibling ofTabView, not a child of any tab'sNavigationStack), so both taps were silent no-ops. Setting the env on the overlay's own stack makes Back return to the same detail view — pager position, scroll offset, matched-geometry hero all preserved. - Gate the close button and bookmark on
pathIsRootso they hide once a destination is pushed; the pushed view's nav bar back button takes over. - Keep the status bar visible across the entire overlay (root + pushed destinations). Previously
.statusBarHidden()was unconditional, and gating it onpathIsRootintroduced a safe-area-top collapse/restore flash at push time. Only hide the status bar while the lightbox is up.
Host-feed PresentedDetail.onPushProfile / onPushTag callbacks are left in place (still wired at HomeView / ProfileView / SearchView / TagFeedView / RelatedIllustsSection). They're unreached by the new code path but harmless; removing them is a mechanical follow-up once we've verified no other consumer relies on them.
Known issues (not blockers for this checkpoint)
- The
unshifted()calibration inprepareSourceFrameThenDismiss/handlePageChangecompensated for the safe-area-top collapse when the status bar was hidden. With it staying visible, the delta is ~0 and the calibration is effectively a no-op. Safe to drop in a follow-up. - Nested-overlay interaction (related → open → tap user row) should work via the same mechanism — the nested overlay gets its own
NavigationStack— but hasn't been exercised end-to-end yet.
Test plan
-
Home → tap illust → tap user row. Profile slides in with Back chevron; overlay chrome (X, heart) hides. -
Back returns to the same detail with pager position and scroll offset preserved; X + heart restored. -
Edge-swipe back has the standard interactive pop animation and lands on the restored detail. -
Tag pill push → TagFeedViewwith the same Back behavior. -
Multi-page illust: page to image 2, tap user row, Back — carousel index preserved. -
Repeat from Search and Profile tabs to confirm per-overlay stack works regardless of host. -
Related section: open a nested overlay from within a detail, then tap its user row. Back returns to the nested detail; dismissing returns to the original detail. -
Status bar: visible on detail root, visible in pushed profile/tag, hidden only while the lightbox is up.