- πΊπΈUnited States johnhanley
This issue is nearly 3 years old, but documentation for Colorbox gallery support still isn't included on the project page or in the README.md.
In the meantime, the process is super straightforward. Simply add the attribute "data-colorbox-gallery" to each anchor tag with whatever name for the gallery. E.g. data-colorbox-gallery="image-gallery"
Be sure the "data-colorbox-inline" attribute is unique and matches the id of the link. For instance, I appended the media file ID.
Colorbox will handle grouping all the images together in a gallery and add the appropriate pagination links.
To define the caption that appears in the lower left-hand corner, simply add a "title" attribute to the anchor tag.
Here's a complete example using replacement tokens in "Rewrite results":
<a data-colorbox-inline="#data-image-{{ value_2 }}" data-colorbox-gallery="image-gallery" title="{{ value_3 }}"><img alt="data-image-{{ value_2 }}" data-entity-type="file" date-entity-uuid="" id="data-image-{{ value_2 }}" src="{{ value_1 }}" /></a>
Be sure to exclude all the field values except for the image thumbnail.