You are here

protected function LanguageConfigEntityFormBase::getAttributes in Flags 8

Gets array with attributes for each option element.

Return value

Attribute[]

1 call to LanguageConfigEntityFormBase::getAttributes()
LanguageConfigEntityFormBase::buildForm in flags_ui/src/Form/LanguageConfigEntityFormBase.php
Overrides Drupal\Core\Entity\EntityFormController::form().

File

flags_ui/src/Form/LanguageConfigEntityFormBase.php, line 212

Class

LanguageConfigEntityFormBase
Class ConfigEntityFormBase.

Namespace

Drupal\flags_ui\Form

Code

protected function getAttributes($items) {
  $mapper = \Drupal::service('flags.mapping.language');
  $attributes = $mapper
    ->getOptionAttributes($items);
  return $attributes;
}