sphinx-wagtail-theme icon indicating copy to clipboard operation
sphinx-wagtail-theme copied to clipboard

Lightbox feature for images in docs

Open thibaudcolas opened this issue 2 years ago • 0 comments

We often have screenshots in our documentation, and other illustrative images, for example as part of the tutorial. It would be nice if we allowed viewing those images in a lightbox-style interface, so the images are easier to look at.

For example, on our Getting Started page of the tutorial, we have this screenshot: https://docs.wagtail.org/en/stable/_images/tutorial_2.png

The screenshot is 1280px in width, but will only be displayed at 680px when the viewport width is 1280px. This makes it hard to read the text (which our images often have a lot of) – so a lightbox that displays the image anywhere closer to 1280px would be ideal.


The implementation should be done in a way that we don’t have to create the content any differently – just find images in the docs as they are rendered now, and initialise the extra functionality on top.

thibaudcolas avatar Nov 01 '22 14:11 thibaudcolas