nanostudio-org / nanogallery2

a modern photo / video gallery and lightbox [JS library]
https://nanogallery2.nanostudio.org
755 stars 111 forks source link

Deep-linking in to a gallery from a page that hosts the gallery #397

Open AntSmith60 opened 1 year ago

AntSmith60 commented 1 year ago

I can't deep-link into a gallery from the page on which the gallery appears, deep linking from anywhere else works fine. This means I cannot provide in-page links to open a given image when discussing that image.

Eg. on this page: https://antsmith.net/photography/sprung

You can see beneath the gallery I discuss one image and provide the deep link, which updates the URL but does not open the gallery lightbox (the bold "I'm Late" link, with a link icon next to it).

===========

I can happily add a window.location.hash changed handler into my JS, but I can't see what I can call in the nanogallery2.js to cause the gallery lightbox to open for the deep linked image.

Can anyone provide any advice on this???