public function ImageResizeEffect::getSummary in Image effect kit 8
Returns a render array summarizing the configuration of the image effect.
Return value
array A render array.
Overrides ImageEffectBase::getSummary
File
- src/
Plugin/ ImageEffect/ ImageResizeEffect.php, line 59 - Contains \Drupal\iek\Plugin\ImageEffect\ImageResizeEffect.
Class
- ImageResizeEffect
- IEK - Resize.
Namespace
Drupal\iek\Plugin\ImageEffectCode
public function getSummary() {
$data = $this->configuration;
if ($data['blank_margin'] == 1) {
$data['blank_margin'] = $this
->t('Yes');
}
else {
$data['blank_margin'] = $this
->t('No');
}
$positions = $this
->getAlignPositions();
$data['position'] = $positions[$data['position']];
$summary = [
'#theme' => 'iek_image_resize_summary',
'#data' => $data,
];
$summary += parent::getSummary();
return $summary;
}