You are here

function blazy_photoswipe_library in Blazy PhotoSwipe 7

Implements hook_library().

File

./blazy_photoswipe.module, line 11
Provides a simple Blazy PhotoSwipe integration.

Code

function blazy_photoswipe_library() {
  $info = system_get_info('module', 'blazy_photoswipe');
  $path = drupal_get_path('module', 'blazy_photoswipe');
  $libraries['load'] = [
    'title' => 'Blazy PhotoSwipe',
    'website' => 'https://drupal.org/project/blazy_photoswipe',
    'version' => empty($info['version']) ? '1.x' : $info['version'],
    'js' => [
      $path . '/js/blazy.photoswipe.min.js' => [
        'group' => JS_DEFAULT,
      ],
    ],
    'css' => [
      $path . '/css/blazy.photoswipe.theme.css' => [],
    ],
    'dependencies' => [
      [
        'blazy',
        'lightbox',
      ],
      [
        'blazy',
        'media',
      ],
    ],
  ];
  return $libraries;
}