You are here

public function FontAwesome::getLibrary in Social Media Links Block and Field 8.2

Get the library.

This method is used if the iconset should be used via the Library API.

Return value

array The library.

Overrides IconsetBase::getLibrary

File

src/Plugin/SocialMediaLinks/Iconset/FontAwesome.php, line 86

Class

FontAwesome
Provides 'elegantthemes' iconset.

Namespace

Drupal\social_media_links\Plugin\SocialMediaLinks\Iconset

Code

public function getLibrary() {
  if (\Drupal::service('module_handler')
    ->moduleExists('fontawesome')) {
    return parent::getLibrary();
  }
  else {
    return [
      'social_media_links/fontawesome.component',
    ];
  }
}