0
votes

On the hub site top navigation, I cannot find a way to add a menu item without a link.

On all of the other SharePoint online menu editors, you can leave the URL blank and it will make the new item a label without a hyperlink. However, in the hub sites top navigation, if you leave the URL blank, the "OK" button is disabled. If you add "#" in the URL, it links to the site home page. This is a problem because users automatically click on a menu item when they want to see the children, resulting in a page reload.

More details here: https://techcommunity.microsoft.com/t5/SharePoint/Hub-site-navigation-top-level-requires-URL/m-p/226427#M20428

Has anyone been able to successfully add a menu to their hub site with top level navigation items not linking to anywhere?

1

1 Answers

0
votes

Yes, that is not supported OOTB. A valid URL seems like a must.

To get around this issue, you can make use of SPFx extensions based on links in term store.

After that, you can delete all the links in your hub site and then deploy this extension to sites associated to your hub. This will provide you will a consistent top navigation across site collections.

GitHub Link - Tenant Global NavBar Application Customizer

Use PS script from - Apply SPFx extensions to SharePoint Hub Sites using PnP PowerShell

When you deploy this extension, if the term has no link it acts like a label. If the term has child links, it will open a dropdown showing those child links which can then be clicked.

Seems like an overkill but there seems to be no other option.

You can always guide and train your end users or content owners to hover the links and the dropdown for child links besides it before clicking, but it will require a mentality change on their part !