diff --git a/core/modules/shortcut/lib/Drupal/shortcut/Access/LinkDeleteAccessCheck.php b/core/modules/shortcut/lib/Drupal/shortcut/Access/LinkDeleteAccessCheck.php new file mode 100644 index 0000000..30153df --- /dev/null +++ b/core/modules/shortcut/lib/Drupal/shortcut/Access/LinkDeleteAccessCheck.php @@ -0,0 +1,37 @@ +attributes->get('menu_link'); + $set_name = str_replace('shortcut-', '', $menu_link['menu_name']); + if ($shortcut_set = shortcut_set_load($set_name)) { + return shortcut_set_edit_access($shortcut_set) ? static::ALLOW : static::DENY; + } + } + +} diff --git a/core/modules/toolbar/templates/toolbar.html.twig b/core/modules/toolbar/templates/toolbar.html.twig new file mode 100644 index 0000000..25430d0 --- /dev/null +++ b/core/modules/toolbar/templates/toolbar.html.twig @@ -0,0 +1,43 @@ +{# +/** + * @file + * Default theme implementation for the administrative toolbar. + * + * Available variables: + * - attributes: HTML attributes for the wrapper. + * - toolbar_attributes: HTML attributes to apply to the toolbar. + * - toolbar_heading: The heading or label for the toolbar. + * - tabs: List of tabs for the toolbar. + * - attributes: HTML Attributes for the tab container. + * - link: Link or button for the menu tab. + * - trays: Toolbar tray list, each associated with a tab. Each tray in trays + * contains: + * - attributes: HTML attributes to apply to the tray. + * - label: The tray's label. + * - links: The tray menu links. + * + * @see template_preprocess_toolbar() + * + * @ingroup themeable + */ +#} + + +

{{ toolbar_heading }}

+ {% for tab in tabs %} + {{ tab.link }} + {% endfor %} + + {% for tray in trays %} + {% spaceless %} + +
+ {% if tray.label %} +

{{ tray.label }}

+ {% endif %} + {{ tray.links }} +
+ + {% endspaceless %} + {% endfor %} +