You are here

public function ImageZoomFormatter::optionsProfiles in Image Zoom 8.3

Gets an array of all options profiles.

Return value

array Array of options profiles.

2 calls to ImageZoomFormatter::optionsProfiles()
ImageZoomFormatter::settingsForm in src/Plugin/Field/FieldFormatter/ImageZoomFormatter.php
Returns a form to configure settings for the formatter.
ImageZoomFormatter::settingsSummary in src/Plugin/Field/FieldFormatter/ImageZoomFormatter.php
Returns a short summary for the current formatter settings.

File

src/Plugin/Field/FieldFormatter/ImageZoomFormatter.php, line 162

Class

ImageZoomFormatter
Image Zoom field formatter for Image fields.

Namespace

Drupal\imagezoom\Plugin\Field\FieldFormatter

Code

public function optionsProfiles() {
  $profiles = ImageZoomOptions::loadMultiple();
  $options = [];
  foreach ($profiles as $name => $profile) {
    $options[$name] = $profile
      ->label();
  }
  return $options;
}