support `#only-dark` and `#only-light` feature of mkdocs material
This is a very cool plugin!
There is only one problem I am facing, when a page uses the #only-light or #only-dark feature of Mkdocs, the gallery has blank images (for the images which are hidden based on the theme).
For example, if you include the following markdown on a page:


If you are currently in light-mode, the gallery will contain 2 images, with the dark-mode one showing as blank.
I am afraid that I can't implement this. Since only-light and only-dark feature is implemented by CSS selector, and glightbox doesn't support dynamically add or remove images from slide.
If this lightbox effect affects your dynamic image based on the theme, you can add the class off-glb to images to disable them with the lightbox effect but keep others with it. The demo and details are both on documents.
I have also found this problem and I'm surprised that I found a solution for that, right in the document https://blueswen.github.io/mkdocs-glightbox/gallery/gallery/
So instead of


...


Add the data-gallery attribute
{data-gallery="light"}
{data-gallery="dark"}
...
{data-gallery="light"}
{data-gallery="dark"}
or any name to separate them into different galleries (in here I use light and dark.
So when you are in light mode, only the images with the attribute data-gallery="light" are displayed in the lightbox and vice versa.
This works perfectly!