@NigelGee thanks for the response. No, no NavigationStack
in the (Grand)parent view (ItemsFilteredView
). Unfortunately the Button approach makes no difference.
As I've continued to troubleshoot, I am observing the following behavior.
The tap (or button press) is successful (verified through a print statement immediately prior to setting isImageViewerPresented
). As I scroll through the LazyHStack
and tap on photos it seems the view I expect (ImageViewer
) is put on a stack somewhere.
Meaning... after I tap on a few photos in the view within the LazyHStack
, the ImageViewer
view does not display as expected. HOWEVER, if I then change the filtered view in the grandparent (ItemsFilteredView
), the images start appearing via ImageViewer
-- sequentially, one after another for each photo that was tapped, as if they were queued views.
This behavior does not happen if I use the HStack
instead of LazyHStack
.
I imagine that is confusing to follow.
Troubleshooting this queued (but hidden!) stack of views is outside of my current skill level.
edit:
I realized, in fact, I do have a NavigationStack
at the topmost view. I removed the NavigationStack
in ItemView
as it was serving no purpose. Still no difference, though, in the behavior I describe above. Still not working with LazyHStack