Interactive previews iPhone
Menu Action Button
Acts like a button and opens the menu on a secondary gesture
Platform Compatibility
iOS 15.0+ iPadOS 15.0+ macOS 12+ tvOS 17.0+ visionOS 1.0+
Tags
SwiftUI Code
Menu {
Button("Button 1", action: action)
Button("Button 2", systemImage: "button.vertical.left.press", action: action)
Button(action: action) {
Text("Button 3")
Text("Description 3")
}
} label: {
Text("Button 0")
} primaryAction: {
print("Button 0 tapped")
}Found an issue or have a suggestion?
Created: May 30, 2025Updated: December 27, 2025
More Menu Components
View allExplore Other Components
Browse allAccessoryCircularGaugeStyle
A gauge style that displays an open ring with a marker that appears at a point along the ring to indicate the gauge’s current value
Button Styles
A type that applies standard interaction behavior and a custom appearance to all buttons within a view hierarchy
Current Value Gauge
Creates a gauge showing a value within a range and that describes the gauge’s purpose and current value
Stepped Slider
Creates a slider to select a value from a given range, subject to a step increment