You are here

public function OptionsBase::getItemFormats in Webform 6.x

Same name and namespace in other branches
  1. 8.5 src/Plugin/WebformElement/OptionsBase.php \Drupal\webform\Plugin\WebformElement\OptionsBase::getItemFormats()

Get an element's available single value formats.

Return value

array An associative array of single value formats containing name/label pairs.

Overrides WebformElementBase::getItemFormats

1 call to OptionsBase::getItemFormats()
WebformImageSelect::getItemFormats in modules/webform_image_select/src/Plugin/WebformElement/WebformImageSelect.php
Get an element's available single value formats.
1 method overrides OptionsBase::getItemFormats()
WebformImageSelect::getItemFormats in modules/webform_image_select/src/Plugin/WebformElement/WebformImageSelect.php
Get an element's available single value formats.

File

src/Plugin/WebformElement/OptionsBase.php, line 408

Class

OptionsBase
Provides a base 'options' element.

Namespace

Drupal\webform\Plugin\WebformElement

Code

public function getItemFormats() {
  return parent::getItemFormats() + [
    'description' => $this
      ->t('Option description'),
  ];
}