function MediaThumbnailFormatter::settingsSummary
Same name in other branches
- 8.9.x core/modules/media/src/Plugin/Field/FieldFormatter/MediaThumbnailFormatter.php \Drupal\media\Plugin\Field\FieldFormatter\MediaThumbnailFormatter::settingsSummary()
- 10 core/modules/media/src/Plugin/Field/FieldFormatter/MediaThumbnailFormatter.php \Drupal\media\Plugin\Field\FieldFormatter\MediaThumbnailFormatter::settingsSummary()
- 11.x core/modules/media/src/Plugin/Field/FieldFormatter/MediaThumbnailFormatter.php \Drupal\media\Plugin\Field\FieldFormatter\MediaThumbnailFormatter::settingsSummary()
Overrides ImageFormatter::settingsSummary
File
-
core/
modules/ media/ src/ Plugin/ Field/ FieldFormatter/ MediaThumbnailFormatter.php, line 125
Class
- MediaThumbnailFormatter
- Plugin implementation of the 'media_thumbnail' formatter.
Namespace
Drupal\media\Plugin\Field\FieldFormatterCode
public function settingsSummary() {
$summary = parent::settingsSummary();
// The parent class adds summary text if the image_link setting is
// 'content'. Here we only have to add summary text if the setting
// is 'media'.
if ($this->getSetting('image_link') === 'media') {
$summary[] = $this->t('Linked to media item');
}
return $summary;
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.