public function StringTextareaWidget::settingsSummary in Zircon Profile 8.0
Same name and namespace in other branches
- 8 core/lib/Drupal/Core/Field/Plugin/Field/FieldWidget/StringTextareaWidget.php \Drupal\Core\Field\Plugin\Field\FieldWidget\StringTextareaWidget::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
1 call to StringTextareaWidget::settingsSummary()
- TextareaWithSummaryWidget::settingsSummary in core/
modules/ text/ src/ Plugin/ Field/ FieldWidget/ TextareaWithSummaryWidget.php - Returns a short summary for the current widget settings.
1 method overrides StringTextareaWidget::settingsSummary()
- TextareaWithSummaryWidget::settingsSummary in core/
modules/ text/ src/ Plugin/ Field/ FieldWidget/ TextareaWithSummaryWidget.php - Returns a short summary for the current widget settings.
File
- core/
lib/ Drupal/ Core/ Field/ Plugin/ Field/ FieldWidget/ StringTextareaWidget.php, line 60 - Contains \Drupal\Core\Field\Plugin\Field\FieldWidget\StringTextareaWidget.
Class
- StringTextareaWidget
- Plugin implementation of the 'string_textarea' widget.
Namespace
Drupal\Core\Field\Plugin\Field\FieldWidgetCode
public function settingsSummary() {
$summary = array();
$summary[] = t('Number of rows: @rows', array(
'@rows' => $this
->getSetting('rows'),
));
$placeholder = $this
->getSetting('placeholder');
if (!empty($placeholder)) {
$summary[] = t('Placeholder: @placeholder', array(
'@placeholder' => $placeholder,
));
}
return $summary;
}