You are here

public function RadioactivityReferenceValue::settingsSummary in Radioactivity 4.0.x

Returns a short summary for the current formatter settings.

If an empty result is returned, a UI can still be provided to display a settings form in case the formatter has configurable settings.

Return value

string[] A short summary of the formatter settings.

Overrides FormatterBase::settingsSummary

File

src/Plugin/Field/FieldFormatter/RadioactivityReferenceValue.php, line 49

Class

RadioactivityReferenceValue
Plugin implementation of the 'radioactivity_reference_value' formatter.

Namespace

Drupal\radioactivity\Plugin\Field\FieldFormatter

Code

public function settingsSummary() {
  $summary = [];
  $summary[] = t('Decimals: @number', [
    '@number' => $this
      ->getSetting('decimals'),
  ]);
  return $summary;
}