midzer / tobii

An accessible, open-source lightbox with no dependencies
https://midzer.github.io/tobii/demo/
MIT License
196 stars 20 forks source link

Problem opening iframe youtube video #95

Closed BernardF956 closed 2 years ago

BernardF956 commented 2 years ago

Hi, I'm trying using tobii to set up kinda video gallery with clickable thumbnails opening an iframe youtube short video. I customzised your demo page and everything is ok : https://www.temperance.fr/index4.html When I just copy the same code into a stand alone page (without the demo's table) tobii doesn't seem to init and every click is only linking to a full youtube page : https://www.temperance.fr/video_gallery_test.html I spent a lot of time unsuccessfully trying to figure out what am I doing wrong. Any help will be appreciated. Regards

midzer commented 2 years ago

Hi @BernardF956 thanks for filing!

In your https://www.temperance.fr/video_gallery_test.html there is an error in console:

Uncaught TypeError: Cannot read properties of null (reading 'classList')

You probably have to fix this first, before tobii can do it's work.

BernardF956 commented 2 years ago

Thanks very much for your quick answer. I updated commenting the "manual" part. I had to purge the cache and things went great. Tobii is and awesome piece of software. Best regards

BernardF956 commented 2 years ago

Sorry I forgot to close the issue.