Image Lightbox
The Thesis theme comes with a built-in lightbox feature that enhances the viewing experience of images on your site. When enabled, users can click on images to view them in a fullscreen modal.
Default Behavior
By default, the lightbox feature is enabled for all images on your site. When a user clicks on an image, it opens in a fullscreen modal that allows for:
- Zooming in and out of images
- Viewing images in a distraction-free environment
- Closing the lightbox by clicking on image, using the escape key or scrolling the page
Disabling Lightbox Globally
Code Injection is required to add custom JS.
If you prefer not to use the built-in lightbox feature, you can disable it by adding the following code snippet to your siteβs Code Injection settings:
<script>
window.pvs?.disableLightbox?.();
</script>
Enabling Lightbox for Specific Posts
In cases where youβve disabled the lightbox globally but want to enable it for specific posts, you can use the internal tag system in Ghost:
- Log in to Ghost admin
- Go to Posts, and open the post
- Open the Post settings sidebar
- Add the
#lightbox
tag to Tags - Click Publish
The lightbox will now be enabled on posts with the #lightbox
internal tag, even if itβs disabled globally.
Remember that internal tags starting with #
are not visible to readers and are used only for theme features and integrations.
Disabling Lightbox for Specific Posts
If you prefer to disable the lightbox only for certain posts, you can use another internal tag:
- Log in to Ghost admin
- Go to Posts, and open the post
- Open the Post settings sidebar
- Add the
#disable-lightbox
tag to Tags - Click Publish
The lightbox will now be disabled only on posts with the #disable-lightbox
internal tag.
Remember that internal tags starting with #
are not visible to readers and are used only for theme features and integrations.