You are here

public static function Micon::loadActiveLabels in Micon 8

Same name and namespace in other branches
  1. 2.x src/Entity/Micon.php \Drupal\micon\Entity\Micon::loadActiveLabels()

Load all active Micon labels.

Return value

static[] An array of entity labels indexed by their IDs.

Overrides MiconInterface::loadActiveLabels

5 calls to Micon::loadActiveLabels()
MiconLinkWidget::settingsForm in micon_link/src/Plugin/Field/FieldWidget/MiconLinkWidget.php
Returns a form to configure settings for the widget.
MiconLinkWidget::settingsSummary in micon_link/src/Plugin/Field/FieldWidget/MiconLinkWidget.php
Returns a short summary for the current widget settings.
MiconMenuConfigForm::buildForm in micon_menu/src/Form/MiconMenuConfigForm.php
Form constructor.
StringMiconWidget::settingsForm in src/Plugin/Field/FieldWidget/StringMiconWidget.php
Returns a form to configure settings for the widget.
StringMiconWidget::settingsSummary in src/Plugin/Field/FieldWidget/StringMiconWidget.php
Returns a short summary for the current widget settings.

File

src/Entity/Micon.php, line 215

Class

Micon
Defines the Micon entity.

Namespace

Drupal\micon\Entity

Code

public static function loadActiveLabels() {
  $labels = [];
  foreach (Micon::loadActive() as $micon) {
    $labels[$micon
      ->id()] = $micon
      ->label();
  }
  return $labels;
}