Pop-Up Buttons in Mac Catalyst v3
Published 10 June 2021
Starting with macOS Monterey, Catalyst apps will now be able to use pop-up buttons.
![](/Images/Blog/2021/pop-up-button-example.gif)
Simply set a menu to the target button and enable both showsMenuAsPrimaryAction and changesSelectionAsPrimaryAction:
let button = UIButton(type: .system)
button.menu = UIMenu()
button.showsMenuAsPrimaryAction = true
button.changesSelectionAsPrimaryAction = true