function ListFloatItem::allowedValuesDescription
Same name in other branches
- 8.9.x core/modules/options/src/Plugin/Field/FieldType/ListFloatItem.php \Drupal\options\Plugin\Field\FieldType\ListFloatItem::allowedValuesDescription()
- 10 core/modules/options/src/Plugin/Field/FieldType/ListFloatItem.php \Drupal\options\Plugin\Field\FieldType\ListFloatItem::allowedValuesDescription()
- 11.x core/modules/options/src/Plugin/Field/FieldType/ListFloatItem.php \Drupal\options\Plugin\Field\FieldType\ListFloatItem::allowedValuesDescription()
Overrides ListItemBase::allowedValuesDescription
File
-
core/
modules/ options/ src/ Plugin/ Field/ FieldType/ ListFloatItem.php, line 54
Class
- ListFloatItem
- Plugin implementation of the 'list_float' field type.
Namespace
Drupal\options\Plugin\Field\FieldTypeCode
protected function allowedValuesDescription() {
$description = '<p>' . $this->t('The possible values this field can contain. Enter one value per line, in the format key|label.');
$description .= '<br/>' . $this->t('The key is the stored value, and must be numeric. The label will be used in displayed values and edit forms.');
$description .= '<br/>' . $this->t('The label is optional: if a line contains a single number, it will be used as key and label.');
$description .= '<br/>' . $this->t('Lists of labels are also accepted (one label per line), only if the field does not hold any values yet. Numeric keys will be automatically generated from the positions in the list.');
$description .= '</p>';
$description .= '<p>' . $this->t('Allowed HTML tags in labels: @tags', [
'@tags' => FieldFilteredMarkup::displayAllowedTags(),
]) . '</p>';
return $description;
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.