Update to Drupal 8.2.0. For more information, see https://www.drupal.org/project/drupal/releases/8.2.0
This commit is contained in:
parent
2f563ab520
commit
f1c8716f57
1732 changed files with 52334 additions and 11780 deletions
|
@ -126,11 +126,11 @@ class ContextualLinkManager extends DefaultPluginManager implements ContextualLi
|
|||
public function processDefinition(&$definition, $plugin_id) {
|
||||
parent::processDefinition($definition, $plugin_id);
|
||||
|
||||
// If there is no route name, this is a broken definition.
|
||||
// If there is no route name, this is a broken definition.
|
||||
if (empty($definition['route_name'])) {
|
||||
throw new PluginException(sprintf('Contextual link plugin (%s) definition must include "route_name".', $plugin_id));
|
||||
}
|
||||
// If there is no group name, this is a broken definition.
|
||||
// If there is no group name, this is a broken definition.
|
||||
if (empty($definition['group'])) {
|
||||
throw new PluginException(sprintf('Contextual link plugin (%s) definition must include "group".', $plugin_id));
|
||||
}
|
||||
|
|
|
@ -37,7 +37,7 @@ class DefaultMenuLinkTreeManipulators {
|
|||
*
|
||||
* @var \Drupal\Core\Entity\Query\QueryFactory
|
||||
*/
|
||||
protected $queryFactory;
|
||||
protected $queryFactory;
|
||||
|
||||
/**
|
||||
* Constructs a \Drupal\Core\Menu\DefaultMenuLinkTreeManipulators object.
|
||||
|
|
|
@ -24,7 +24,7 @@ class LocalActionDefault extends PluginBase implements LocalActionInterface, Con
|
|||
*
|
||||
* @var \Drupal\Core\Routing\RouteProviderInterface
|
||||
*/
|
||||
protected $routeProvider;
|
||||
protected $routeProvider;
|
||||
|
||||
/**
|
||||
* Constructs a LocalActionDefault object.
|
||||
|
|
|
@ -158,7 +158,7 @@ class LocalTaskManager extends DefaultPluginManager implements LocalTaskManagerI
|
|||
*/
|
||||
public function processDefinition(&$definition, $plugin_id) {
|
||||
parent::processDefinition($definition, $plugin_id);
|
||||
// If there is no route name, this is a broken definition.
|
||||
// If there is no route name, this is a broken definition.
|
||||
if (empty($definition['route_name'])) {
|
||||
throw new PluginException(sprintf('Plugin (%s) definition must include "route_name"', $plugin_id));
|
||||
}
|
||||
|
|
|
@ -13,7 +13,7 @@ interface MenuActiveTrailInterface {
|
|||
/**
|
||||
* Gets the active trail IDs of the specified menu tree.
|
||||
*
|
||||
* @param string|NULL $menu_name
|
||||
* @param string|null $menu_name
|
||||
* (optional) The menu name of the requested tree. If omitted, all menu
|
||||
* trees will be searched.
|
||||
*
|
||||
|
@ -25,11 +25,11 @@ interface MenuActiveTrailInterface {
|
|||
/**
|
||||
* Fetches a menu link which matches the route name, parameters and menu name.
|
||||
*
|
||||
* @param string|NULL $menu_name
|
||||
* @param string|null $menu_name
|
||||
* (optional) The menu within which to find the active link. If omitted, all
|
||||
* menus will be searched.
|
||||
*
|
||||
* @return \Drupal\Core\Menu\MenuLinkInterface|NULL
|
||||
* @return \Drupal\Core\Menu\MenuLinkInterface|null
|
||||
* The menu link for the given route name, parameters and menu, or NULL if
|
||||
* there is no matching menu link or the current user cannot access the
|
||||
* current page (i.e. we have a 403 response).
|
||||
|
|
|
@ -68,7 +68,7 @@ class MenuLinkTreeElement {
|
|||
* If the value is NULL the access was not determined yet, if an access result
|
||||
* object, it was determined already.
|
||||
*
|
||||
* @var \Drupal\Core\Access\AccessResultInterface|NULL
|
||||
* @var \Drupal\Core\Access\AccessResultInterface|null
|
||||
*/
|
||||
public $access;
|
||||
|
||||
|
|
|
@ -20,7 +20,7 @@ namespace Drupal\Core\Menu;
|
|||
* a tree transformation, because menu links themselves are responsible
|
||||
* for translation. Transformations are performed by "menu link tree
|
||||
* manipulators", which are functions or methods; see
|
||||
* \Drupal\menu_link\DefaultMenuTreeManipulators for examples.
|
||||
* \Drupal\Core\Menu\DefaultMenuLinkTreeManipulators for examples.
|
||||
* - Create a render array using MenuLinkTreeInterface::build().
|
||||
*/
|
||||
interface MenuLinkTreeInterface {
|
||||
|
|
|
@ -135,7 +135,7 @@ class MenuParentFormSelector implements MenuParentFormSelectorInterface {
|
|||
* An excluded menu link.
|
||||
* @param int $depth_limit
|
||||
* The maximum depth of menu links considered for the select options.
|
||||
* @param \Drupal\Core\Cache\CacheableMetadata|NULL &$cacheability
|
||||
* @param \Drupal\Core\Cache\CacheableMetadata|null &$cacheability
|
||||
* The object to add cacheability metadata to, if not NULL.
|
||||
*/
|
||||
protected function parentSelectOptionsTreeWalk(array $tree, $menu_name, $indent, array &$options, $exclude, $depth_limit, CacheableMetadata &$cacheability = NULL) {
|
||||
|
|
|
@ -18,7 +18,7 @@ interface MenuParentFormSelectorInterface {
|
|||
* @param array $menus
|
||||
* Optional array of menu names as keys and titles as values to limit
|
||||
* the select options. If NULL, all menus will be included.
|
||||
* @param \Drupal\Core\Cache\CacheableMetadata|NULL &$cacheability
|
||||
* @param \Drupal\Core\Cache\CacheableMetadata|null &$cacheability
|
||||
* Optional cacheability metadata object, which will be populated based on
|
||||
* the accessibility of the links and the cacheability of the links.
|
||||
*
|
||||
|
|
|
@ -41,7 +41,7 @@ interface MenuTreeStorageInterface {
|
|||
* @param string $id
|
||||
* The menu link plugin ID.
|
||||
*
|
||||
* @return array|FALSE
|
||||
* @return array|false
|
||||
* The plugin definition, or FALSE if no definition was found for the ID.
|
||||
*/
|
||||
public function load($id);
|
||||
|
|
|
@ -21,7 +21,7 @@ interface StaticMenuLinkOverridesInterface {
|
|||
* @param string $id
|
||||
* A menu link plugin ID.
|
||||
*
|
||||
* @return array|NULL
|
||||
* @return array|null
|
||||
* An override with following supported keys:
|
||||
* - parent
|
||||
* - weight
|
||||
|
|
|
@ -170,11 +170,11 @@
|
|||
* - Pass the menu tree to \Drupal\Core\Menu\MenuLinkTree::transform() to apply
|
||||
* menu link tree manipulators that transform the tree. You will almost always
|
||||
* want to apply access checking. The manipulators that you will typically
|
||||
* need can be found in \Drupal\Core\Menu\DefaultMenuTreeManipulators.
|
||||
* need can be found in \Drupal\Core\Menu\DefaultMenuLinkTreeManipulators.
|
||||
* - Potentially write a custom menu tree manipulator, see
|
||||
* \Drupal\Core\Menu\DefaultMenuTreeManipulators for examples. This is only
|
||||
* necessary if you want to do things like adding extra metadata to rendered
|
||||
* links to display icons next to them.
|
||||
* \Drupal\Core\Menu\DefaultMenuLinkTreeManipulators for examples. This is
|
||||
* only necessary if you want to do things like adding extra metadata to
|
||||
* rendered links to display icons next to them.
|
||||
* - Pass the menu tree to \Drupal\Core\Menu\MenuLinkTree::build(), this will
|
||||
* build a renderable array.
|
||||
*
|
||||
|
|
Reference in a new issue