Open cangec opened 6 years ago
@cangec This is possible in case of social media dialog post where only close button lies outside a bounding box. Since this gallery takes entire screen area and many things are outside image area which are important to interact with, I am not sure whether we can add this feature at this moment.
this.elementRef.nativeElement.querySelector('#ngx-gallery').addEventListener('click', e => { if(!(e.target.closest('img')) && !(e.target.closest('.control')) && !(e.target.closest('.thumbnail'))){ this.closeGallery(); } });
This worked for me. I gave the gallery an id of 'ngx-gallery' to select it easier.
Hi ! Any news about this functionality ?
Hey. Is It possible to close the gallery on backdrop click when the gallery is full screen?