You are here

protected function TextFormat::getElementSelectorInputsOptions in YAML Form 8

Get an element's (sub)inputs selectors as options.

Parameters

array $element: An element.

Return value

array An array of element (sub)input selectors.

Overrides YamlFormElementBase::getElementSelectorInputsOptions

File

src/Plugin/YamlFormElement/TextFormat.php, line 155

Class

TextFormat
Provides a 'text_format' element.

Namespace

Drupal\yamlform\Plugin\YamlFormElement

Code

protected function getElementSelectorInputsOptions(array $element) {
  $title = $this
    ->getAdminLabel($element);
  return [
    'value' => $title . ' [' . t('Textarea') . ']',
    'format' => $title . ' [' . t('Select') . ']',
  ];
}