3 * Provides Photobox integration for Image and Media fields.
6 (function ($, Drupal) {
10 Drupal.blazy = Drupal.blazy || {};
12 Drupal.behaviors.blazyPhotobox = {
13 attach: function (context) {
14 $('[data-photobox-gallery]', context).once('blazy-photobox').each(function () {
15 $(this).photobox('a[data-photobox-trigger]', {thumb: '> [data-thumb]', thumbAttr: 'data-thumb'}, Drupal.blazy.photobox);
21 * Callback for custom captions.
23 Drupal.blazy.photobox = function () {
24 var $caption = $(this).next('.litebox-caption');
26 if ($caption.length) {
27 $('#pbCaption .title').html($caption.html());