You are here

public function DateRecurModularOscarWidget::settingsSummary in Recurring Date Field Modular Widgets 8

Same name and namespace in other branches
  1. 3.x src/Plugin/Field/FieldWidget/DateRecurModularOscarWidget.php \Drupal\date_recur_modular\Plugin\Field\FieldWidget\DateRecurModularOscarWidget::settingsSummary()
  2. 2.x src/Plugin/Field/FieldWidget/DateRecurModularOscarWidget.php \Drupal\date_recur_modular\Plugin\Field\FieldWidget\DateRecurModularOscarWidget::settingsSummary()

Returns a short summary for the current widget settings.

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

Return value

array A short summary of the widget settings.

Overrides WidgetBase::settingsSummary

File

src/Plugin/Field/FieldWidget/DateRecurModularOscarWidget.php, line 90

Class

DateRecurModularOscarWidget
Date recur opening hours widget.

Namespace

Drupal\date_recur_modular\Plugin\Field\FieldWidget

Code

public function settingsSummary() : array {
  $summary = parent::settingsSummary();
  $summary[] = $this
    ->isAllDayToggleEnabled() ? $this
    ->t('All day toggle: enabled') : $this
    ->t('All day toggle: disabled');
  return $summary;
}