Using Button in ToolbarItem is buggy. I use buttons in bottom toolbar.
ToolbarItem in the bottomBar cannot show Text and Icon at the same time, and change the tintColor separately.
If I tried it to put a Text and Image into ZStack or HStack, and it will lose the default pointer hover effect in iPad, which is hard to adjust to emulate the default pointer hover effect.
It cannot show Text and Icon at the same time.
Developers cannot change the tintColor of these buttons separately.
Code Block struct ContentView: View { var body: some View { NavigationView { Text("Hello, world!") .toolbar { ToolbarItemGroup(placement: .bottomBar) { Button(action: {}) { Label("Bookmark", systemImage: "bookmark") }.accentColor(.green) Spacer() Button(action: {}) { Label("Delete", systemImage: "trash") }.accentColor(.red) } } } } } struct ContentView_Previews: PreviewProvider { static var previews: some View { ContentView() } }
ToolbarItem in the bottomBar cannot show Text and Icon at the same time, and change the tintColor separately.
If I tried it to put a Text and Image into ZStack or HStack, and it will lose the default pointer hover effect in iPad, which is hard to adjust to emulate the default pointer hover effect.