GLightbox¶
The GLightbox extension, included with Zensical, enables image zoom through lightbox galleries — full-screen overlays with navigation controls. Enable it via:
The following additional configuration options are supported:
auto¶
When true, images are wrapped automatically, unless they have the off-glb CSS class or additional classes specified with the skip_classes option. When false, only images with the on-glb CSS class are wrapped. The default value is true.
auto_themed¶
When set to true, images for light and dark modes are grouped into separate galleries. Supports image URLs with #only-light/#only-dark or #gh-light-mode-only/#gh-dark-mode-only appended to their URLs (see light and dark mode images). The default value is false.
width¶
Width of the lightbox overlay (default: auto). Accepts CSS units (px, %, vw, vh) or auto.
height¶
Height of the lightbox overlay (default: auto). Accepts CSS units (px, %, vw, vh) or auto.
skip_classes¶
List of image CSS classes to exclude from automatic wrapping. The default value is [].
auto_caption¶
When set to true, the image alt attribute is used as a caption when no explicit data-title attribute is present. To set captions manually, add data-title to your images (e.g. { data-title="My Caption" }), which takes precedence over the alt attribute when auto_caption is true. The default value is false.
caption_position¶
Default caption position for images (default: bottom). Valid values: bottom, top, left, or right.
Adding attributes to images¶
- Attribute Lists — Enables adding data attributes to images for customizing lightbox behavior:
data-src— Alternative image source for the lightboxdata-title— Custom caption textdata-description— Additional description textdata-caption-position— Override global caption positiondata-gallery— Manual gallery grouping