mkdocs-glightbox icon indicating copy to clipboard operation
mkdocs-glightbox copied to clipboard

[Feature Request] Support transparency

Open couleurm opened this issue 1 year ago • 6 comments
trafficstars

Hey, would it feasible to support transparency in in images (e.g on PNGs and SVGs)? Thank you!

couleurm avatar Dec 22 '23 16:12 couleurm

Hi @couleurm. Do you mean keeping the PNG or SVG files background transparent instead of a white background?

The effect with the transparency background in the slide looks as follows: Transparent

Currently, this plugin will add a white background automatically that looks as follows: White

blueswen avatar Dec 28 '23 16:12 blueswen

Hi yes, how can glightbox be configured like in your first picture?

couleurm avatar Jan 01 '24 13:01 couleurm

that drop shadow makes it really explicit where the picture ends, can that also be configured? image

couleurm avatar Jan 04 '24 17:01 couleurm

Hi @couleurm,

The latest version v0.3.7 can change the slide image background and disable the slide image's shadow by plugin options. In your case, you can set the config as follows:

plugins:
   - glightbox:
       background: none
       shadow: false

blueswen avatar Jan 24 '24 15:01 blueswen

what type of value can be put in background? it'd be cool to have rgba

couleurm avatar Jan 24 '24 20:01 couleurm

You can check details on document. Any valid CSS value for background is fine.

blueswen avatar Jan 25 '24 00:01 blueswen