Returns a short info icon for the current behavior settings.
Usually the information is in the form of an icon or a badge or some similar graphical representation.
\Drupal\paragraphs\Entity\Paragraph $paragraph: The paragraph.
string[] The plugin settings.
Overrides ParagraphsBehaviorBase::settingsIcon
ParagraphInterface::getIcons()
public function settingsIcon(Paragraph $paragraph) {
$bold_setting = $paragraph
->getBehaviorSetting($this
->getPluginId(), 'bold_text');
if ($bold_setting) {
return [
'bold' => [
'#theme' => 'paragraphs_info_icon',
'#message' => $this
->t('Bold: Yes.'),
'#icon' => 'bold',
],
];
}
return [];
}