UIMenu in Mac Catalyst

When I'm using this code to display a toolbar item in Mac Catalyst to show the new UIMenu context menu behavior, the toolbar item is disabled because there's no primary action. Is this a bug or does this need special care on Mac Catalyst to work?

Code Block extension SceneDelegate {
    func toolbar(_ toolbar: NSToolbar, itemForItemIdentifier itemIdentifier: NSToolbarItem.Identifier, willBeInsertedIntoToolbar flag: Bool) -> NSToolbarItem? {
        if (itemIdentifier == addLinkButtonIdentifier) {
            let barButtonItem = UIBarButtonItem(title: "Test", image: nil, primaryAction: nil, menu: addLinkContextMenu)
            barButtonItem.accessibilityLabel = "Add Link"
            
            let button = NSToolbarItem(itemIdentifier: itemIdentifier, barButtonItem: barButtonItem)
            
            return button
        }
        
        return nil
    }
}


Same problem. I would expect the same look as in the Maps app when you click on the + button. How did Apple implement that?
I was able to get the menu by using NSMenuToolbarItem for my menu item and attaching a menu to it.
UIMenu in Mac Catalyst
 
 
Q