DropDown menu

I want to make a Dropdown-Menü like in pages(I mean the brush button).I use SwiftUI but at first my menu looks not like this and it don‘t work.If I press any button the menu closes.I want that the menu looks like the menu in pages/keynote and also works without that you have to open the menu every time u press a button.My current code looks like this:


import UniformTypeIdentifiers



struct ContentView: View {

    var body: some View {

        NavigationView {

            Text("")

            .toolbar {

                ToolbarItem(placement: ToolbarItemPlacement.navigationBarTrailing) {

                    Menu {

                        Button("button"){

                            print("Pressed")

                        }

                    } label: {

                        Label(

                            title: { Text("Settings") },

                            icon: { Image(systemName: "gearshape.fill") }

                        )

                    }

                }

            }

        }.navigationViewStyle(StackNavigationViewStyle())

    }

}

Tanks in advance(if u say it so in English) Edit: I work on a iPad(Because of that I have this style at the NavigationView)

DropDown menu
 
 
Q