You are here

public function ListFormatter::settingsSummary in Text list formatter 8.2

Implements Drupal\field\Plugin\Type\Formatter\FormatterInterface::settingsForm().

File

lib/Drupal/textformatter/Plugin/field/formatter/ListFormatter.php, line 175
Definition of Drupal\textformatter\Plugin\field\formatter\List;

Class

ListFormatter
Plugin implementation of the 'text_default' formatter.

Namespace

Drupal\textformatter\Plugin\field\formatter

Code

public function settingsSummary() {
  $summary = array();
  $types = $this
    ->listTypes();
  $summary[] = $types[$this
    ->getSetting('type')];
  if ($this
    ->getSetting('class')) {
    $summary[] = t("CSS Class") . ': <em>' . check_plain($this
      ->getSetting('class')) . '</em>';
  }
  if ($this
    ->getSetting('comma_override')) {
    $summary[] = '<em>*' . t("Comma separator overridden") . '*</em>';
  }
  return implode('<br>', $summary);
}