LocalActionManager::$defaults

Same name in other branches
  1. 8.9.x core/lib/Drupal/Core/Menu/LocalActionManager.php \Drupal\Core\Menu\LocalActionManager::defaults
  2. 10 core/lib/Drupal/Core/Menu/LocalActionManager.php \Drupal\Core\Menu\LocalActionManager::defaults
  3. 11.x core/lib/Drupal/Core/Menu/LocalActionManager.php \Drupal\Core\Menu\LocalActionManager::defaults

Provides some default values for all local action plugins.

Type: array

Overrides DefaultPluginManager::$defaults

File

core/lib/Drupal/Core/Menu/LocalActionManager.php, line 31

Class

LocalActionManager
Provides the default local action manager using YML as primary definition.

Namespace

Drupal\Core\Menu

Code

protected $defaults = [
    // The plugin id. Set by the plugin system based on the top-level YAML key.
'id' => NULL,
    // The static title for the local action.
'title' => '',
    // The weight of the local action.
'weight' => NULL,
    // (Required) the route name used to generate a link.
'route_name' => NULL,
    // Default route parameters for generating links.
'route_parameters' => [],
    // Associative array of link options.
'options' => [],
    // The route names where this local action appears.
'appears_on' => [],
    // Default class for local action implementations.
'class' => 'Drupal\\Core\\Menu\\LocalActionDefault',
];

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.