Admin Toolbar Links Access Filter filters out custom links to existing pages

Created on 4 March 2021, almost 4 years ago
Updated 8 July 2024, 6 months ago

I've created custom toolbar links to existing admin pages and when I enable the Admin Toolbar Links Access Filter module, the links are hidden, even to administrators, even though the linked internal page and child menu items are fully accessible to the user.

Here is what my custom_module.links.menu.yml file looks like:

custom _module.navigation:
  title: 'Navigation'
  parent: system.admin
  url: internal:/admin/structure/menu/manage/main
  weight: -8
custom_module.add-link:
  title: 'Add link'
  parent:  custom_module.navigation
  url: internal:/admin/structure/menu/manage/main/add
  weight: 0
custom_module.siteinfo:
  title: 'Site Information'
  parent: system.admin
  url: internal:/admin/config/system/siteinfo
  weight: -5

The first two links are just to core pages for editing the main menu, including a child menu item that admins can access, and the last is a custom config page that provides its own permission, which the admin user also has access to. If this module is intended to filter out links the current user doesn't have access to, why are these ones being hidden

I suspect it is because I an using 'internal' in the URL and linking to an existing page defined by another module. If instead of duplicating this link this way, I go admin/structure/menu/manage/admin and move the original into the top level of the admin menu, this module does not filter it out, but that's not what I want to do. I basically just want to create a shortcut to an existing page, but have it as part of the main admin toolbar. Is there any way to change this so that links like this (whose targets the user does have permission to view) do not get filtered?

πŸ› Bug report
Status

Active

Version

3.0

Component

Code

Created by

πŸ‡ΊπŸ‡ΈUnited States chrisgross

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024