You are here

public function BlazyLibrary::librariesInfo in Blazy 7

Implements hook_libraries_info().

File

src/BlazyLibrary.php, line 160

Class

BlazyLibrary
Provides Blazy library definitions.

Namespace

Drupal\blazy

Code

public function librariesInfo() {
  if (!isset($this->librariesInfo)) {
    $libraries['blazy'] = [
      'name' => 'Blazy',
      'vendor url' => 'http://dinbror.dk/blazy/',
      'download url' => 'https://github.com/dinbror/blazy',
      'version arguments' => [
        'file' => 'blazy.min.js',
        'pattern' => '@v([0-9a-zA-Z\\.-]+)@',
        'lines' => 5,
      ],
      'files' => [
        'js' => [
          'blazy.min.js',
        ],
      ],
      'variants' => [
        'minified' => [
          'files' => [
            'js' => [
              'blazy.min.js',
            ],
          ],
        ],
        'source' => [
          'files' => [
            'js' => [
              'blazy.js',
            ],
          ],
        ],
      ],
    ];
    $this->librariesInfo = $libraries;
  }
  return $this->librariesInfo;
}