You are here

protected function InsertImageWidgetUtility::getStyleClasses in Insert 8

@inheritdoc

Parameters

$styles:

Return value

array

Overrides InsertFileWidgetUtility::getStyleClasses

File

src/Utility/InsertImageWidgetUtility.php, line 179

Class

InsertImageWidgetUtility

Namespace

Drupal\insert\Utility

Code

protected function getStyleClasses($styles) {
  $styleClasses = [];
  foreach ($styles as $styleName => $style) {
    if ($style instanceof ImageStyle) {
      $styleClasses[] = 'image-' . $styleName;
    }
  }
  return $styleClasses;
}