You are here

public function WebformImageSelect::getItemFormats in Webform 6.x

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

Get an element's available single value formats.

Return value

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

Overrides OptionsBase::getItemFormats

File

modules/webform_image_select/src/Plugin/WebformElement/WebformImageSelect.php, line 191

Class

WebformImageSelect
Provides a 'image_select' element.

Namespace

Drupal\webform_image_select\Plugin\WebformElement

Code

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