---
title: "CompactMenuControlGroupStyle | Explore SwiftUI"
description: "A control group style that presents its content as a compact menu when the user presses the control, or as a submenu when nested within a larger menu"
canonical_url: "https://exploreswiftui.com/library/controlgroup/compactmenucontrolgroupstyle"
meta:
  author: "Explore SwiftUI"
  "og:description": "A control group style that presents its content as a compact menu when the user presses the control, or as a submenu when nested within a larger menu"
  "og:image": "https://exploreswiftui.com/_og/d/c_Component%2Ctitle_CompactMenuControlGroupStyle%2Cdescription_~QSBjb250cm9sIGdyb3VwIHN0eWxlIHRoYXQgcHJlc2VudHMgaXRzIGNvbnRlbnQgYXMgYSBjb21wYWN0IG1lbnUgd2hlbiB0aGUgdXNlciBwcmVzc2VzIHRoZSBjb250cm9sLCBvciBhcyBhIHN1Ym1lbnUgd2hlbiBuZXN0ZWQgd2l0aGluIGEgbGFyZ2VyIG1lbnU%2Ccategory_ControlGroup%2Cimage_~L2FwaS9pbWFnZXMvNTQvdmFyaWFudHMvNDAwP3Y9MTc5MDA3MzQ3ODg0MiZyPTImdz0xMjgwJnE9ODUmZj1qcGVn%2CimageMode_crop%2CimagePosition_center%2CimageFrame_~cG9zaXRpb246IGFic29sdXRlOyByaWdodDogMDsgd2lkdGg6IDY0MHB4OyBoZWlnaHQ6IDQ4MHB4OyBkaXNwbGF5OiBmbGV4OyBvdmVyZmxvdzogaGlkZGVuOyBiYWNrZ3JvdW5kOiAjRkZGRkZGOyBib3gtc2hhZG93OiAwIC0xMHB4IDUwcHggcmdiYSgzNyw5OSwyMzUsMC4xOCk7IGJvcmRlci1sZWZ0OiAxcHggc29saWQgcmdiYSgwLDAsMCwwLjA2KTsgdG9wOiA3NXB4OyBib3JkZXItdG9wOiAxcHggc29saWQgcmdiYSgwLDAsMCwwLjA2KTsgYm9yZGVyLWJvdHRvbTogMXB4IHNvbGlkIHJnYmEoMCwwLDAsMC4wNik7IGJvcmRlci10b3AtbGVmdC1yYWRpdXM6IDMycHg7IGJvcmRlci1ib3R0b20tbGVmdC1yYWRpdXM6IDMycHg7%2Cprops_eyJwbGF0Zm9ybXMiOlsiaU9TIiwiaVBhZE9TIiwibWFjT1MiLCJ2aXNpb25PUyJdfQ%2Cp_Ii9saWJyYXJ5L2NvbnRyb2xncm91cC9jb21wYWN0bWVudWNvbnRyb2xncm91cHN0eWxlIg%2Cs_Pm3jMwmDv5qwqTIp.png"
  "og:image:height": "630"
  "og:image:type": image/png
  "og:image:width": "1200"
  "og:title": "CompactMenuControlGroupStyle | Explore SwiftUI"
  "twitter:description": "A control group style that presents its content as a compact menu when the user presses the control, or as a submenu when nested within a larger menu"
  "twitter:image": "https://exploreswiftui.com/_og/d/c_Component%2Ctitle_CompactMenuControlGroupStyle%2Cdescription_~QSBjb250cm9sIGdyb3VwIHN0eWxlIHRoYXQgcHJlc2VudHMgaXRzIGNvbnRlbnQgYXMgYSBjb21wYWN0IG1lbnUgd2hlbiB0aGUgdXNlciBwcmVzc2VzIHRoZSBjb250cm9sLCBvciBhcyBhIHN1Ym1lbnUgd2hlbiBuZXN0ZWQgd2l0aGluIGEgbGFyZ2VyIG1lbnU%2Ccategory_ControlGroup%2Cimage_~L2FwaS9pbWFnZXMvNTQvdmFyaWFudHMvNDAwP3Y9MTc5MDA3MzQ3ODg0MiZyPTImdz0xMjgwJnE9ODUmZj1qcGVn%2CimageMode_crop%2CimagePosition_center%2CimageFrame_~cG9zaXRpb246IGFic29sdXRlOyByaWdodDogMDsgd2lkdGg6IDY0MHB4OyBoZWlnaHQ6IDQ4MHB4OyBkaXNwbGF5OiBmbGV4OyBvdmVyZmxvdzogaGlkZGVuOyBiYWNrZ3JvdW5kOiAjRkZGRkZGOyBib3gtc2hhZG93OiAwIC0xMHB4IDUwcHggcmdiYSgzNyw5OSwyMzUsMC4xOCk7IGJvcmRlci1sZWZ0OiAxcHggc29saWQgcmdiYSgwLDAsMCwwLjA2KTsgdG9wOiA3NXB4OyBib3JkZXItdG9wOiAxcHggc29saWQgcmdiYSgwLDAsMCwwLjA2KTsgYm9yZGVyLWJvdHRvbTogMXB4IHNvbGlkIHJnYmEoMCwwLDAsMC4wNik7IGJvcmRlci10b3AtbGVmdC1yYWRpdXM6IDMycHg7IGJvcmRlci1ib3R0b20tbGVmdC1yYWRpdXM6IDMycHg7%2Cprops_eyJwbGF0Zm9ybXMiOlsiaU9TIiwiaVBhZE9TIiwibWFjT1MiLCJ2aXNpb25PUyJdfQ%2Cp_Ii9saWJyYXJ5L2NvbnRyb2xncm91cC9jb21wYWN0bWVudWNvbnRyb2xncm91cHN0eWxlIg%2Cs_Pm3jMwmDv5qwqTIp.png"
  "twitter:title": "CompactMenuControlGroupStyle | Explore SwiftUI"
---

> Index of every page on this site: [llms.txt](https://exploreswiftui.com/llms.txt)

**Interactive previews**[ iPhone](https://exploreswiftui.com/iphone?element=54)

# **CompactMenuControlGroupStyle**

A control group style that presents its content as a compact menu when the user presses the control, or as a submenu when nested within a larger menu

![CompactMenuControlGroupStyle - iOS on iPhone - Portrait - Liquid Glass - Light Mode - Preview](https://exploreswiftui.com/api/images/54/variants/400?v=1790073478842&r=2&w=800&q=80&f=webp)

### **Platform Compatibility**

iOS 16.4+ iPadOS 16.4+ macOS 13.3+ visionOS 1.0+

### **Tags**

### **SwiftUI Code**

[ Docs](https://developer.apple.com/documentation/swiftui/controlgroupstyle/compactmenu)

```
VStack {
    ControlGroup {
        Button("Increase", systemImage: "plus", action: action)
        Button("Decrease", systemImage: "minus", action: action)
    } label: {
        Text("Foo")
    }
    ControlGroup("Foo", systemImage: "magnifyingglass") {
        Button("Increase", systemImage: "plus", action: action)
        Button("Decrease", systemImage: "minus", action: action)
    }
    ControlGroup {
        Button("Increase", systemImage: "plus", action: action)
        Button("Decrease", systemImage: "minus", action: action)
    }
}
.controlGroupStyle(.compactMenu)
```

### **Found an issue or have a suggestion?**

Created: June 4, 2025Updated: December 27, 2025

![Connect Wizard](https://exploreswiftui.com/_ipx/f_webp&q_80&s_48x48/images/connect-wizard-icon.png)

**Connect Wizard**

**Unlock insights App Store Connect doesn’t show you.**

[** Get Started **](https://apps.apple.com/app/apple-store/id6747314580?pt=121213751&ct=Explore%20SwiftUI%20Banner&mt=8)

### **More ControlGroup Components **

[**View all **](https://exploreswiftui.com/library/controlgroup)

![PaletteControlGroupStyle - iOS on iPhone - Portrait - Liquid Glass - Light Mode - Preview](https://exploreswiftui.com/api/images/57/variants/49?v=1790073478842&r=2&w=412&q=75&f=webp)

### **PaletteControlGroupStyle**

A control group style that presents its content as a palette.

![NavigationControlGroupStyle - iOS on iPhone - Portrait - Liquid Glass - Light Mode - Preview](https://exploreswiftui.com/api/images/56/variants/404?v=1790073478842&r=2&w=412&q=75&f=webp)

### **NavigationControlGroupStyle**

The navigation control group style

![MenuControlGroupStyle - iOS on iPhone - Portrait - Liquid Glass - Light Mode - Preview](https://exploreswiftui.com/api/images/55/variants/99?v=1790073478842&r=2&w=412&q=75&f=webp)

### **MenuControlGroupStyle**

A control group style that presents its content as a menu when the user presses the control, or as a submenu when nested within a larger menu

![ControlGroup - iOS on iPhone - Portrait - Liquid Glass - Light Mode - Preview](https://exploreswiftui.com/api/images/53/variants/163?v=1790073478842&r=2&w=412&q=75&f=webp)

### **ControlGroup**

Creates a new ControlGroup with the specified children

### **Explore Other Components **

[**Browse all **](https://exploreswiftui.com/)

![Axis Behavior - iOS on iPhone Duo - Landscape - Closed - Liquid Glass - Light Mode - Preview](https://exploreswiftui.com/api/images/247/variants/1692?v=1790586402346&r=2&w=412&q=75&f=webp)

### **Axis Behavior**

The bar axis behavior of the toolbar item.

![Value Tab View - iOS on iPhone - Portrait - Liquid Glass - Light Mode - Preview](https://exploreswiftui.com/api/images/165/variants/616?v=1790073478842&r=2&w=412&q=75&f=webp)

### **Value Tab View**

Creates a tab view that uses a builder to create and specify selection values for its tabs.

![Increased Header Prominence - iOS on iPhone - Portrait - Flat Design - Light Mode - Preview](https://exploreswiftui.com/api/images/108/variants/331?v=1790073478842&r=2&w=412&q=75&f=webp)

### **Increased Header Prominence**

Sets the header prominence to increased for this view.

![HelpLink - macOS - Flat Design - Light Mode - Preview](https://exploreswiftui.com/api/images/77/variants/30?v=1790073478842&r=2&w=412&q=75&f=webp)

### **HelpLink**

A button with a standard appearance that opens app-specific help documentation

![TabBarOnlyTabViewStyle - iOS on iPhone - Portrait - Liquid Glass - Light Mode - Preview](https://exploreswiftui.com/api/images/159/variants/699?v=1790073478842&r=2&w=412&q=75&f=webp)

### **TabBarOnlyTabViewStyle**

A tab view style that displays a tab bar when possible.

![Manage Subscriptions Sheet - iOS on iPhone - Portrait - Liquid Glass - Light Mode - Preview](https://exploreswiftui.com/api/images/223/variants/241?v=1790073478842&r=2&w=412&q=75&f=webp)

### **Manage Subscriptions Sheet**

Opens the manage subscriptions sheet.

![Tab View Side Bar Bottom Bar - iPadOS - Landscape - Liquid Glass - Light Mode - Preview](https://exploreswiftui.com/api/images/169/variants/707?v=1790073478842&r=2&w=412&q=75&f=webp)

### **Tab View Side Bar Bottom Bar**

Adds a custom bottom bar to the sidebar of a tab view.

![Hide Tab Bar On Scroll Down - iOS on iPhone - Portrait - Liquid Glass - Light Mode - Preview](https://exploreswiftui.com/api/images/88/variants/383?v=1790073478842&r=2&w=412&q=75&f=webp)

### **Hide Tab Bar On Scroll Down**

Minimize the tab bar when downwards scrolling starts. Minimizing is supported for tab bars on only iPhone

```json
{"@context":"https://schema.org","@graph":[{"@id":"https://exploreswiftui.com/#website","@type":"WebSite","description":"A visual library for SwiftUI APIs, components, and modifiers","inLanguage":"en-US","name":"Explore SwiftUI","url":"https://exploreswiftui.com/","publisher":{"@id":"https://exploreswiftui.com/#identity"}},{"@id":"https://exploreswiftui.com/library/controlgroup/compactmenucontrolgroupstyle#webpage","@type":"WebPage","dateModified":"2025-12-27T13:37:55.421Z","datePublished":"2025-06-04T12:20:41.812Z","description":"A control group style that presents its content as a compact menu when the user presses the control, or as a submenu when nested within a larger menu","name":"CompactMenuControlGroupStyle","url":"https://exploreswiftui.com/library/controlgroup/compactmenucontrolgroupstyle","breadcrumb":{"@id":"https://exploreswiftui.com/library/controlgroup/compactmenucontrolgroupstyle#breadcrumb"},"isPartOf":{"@id":"https://exploreswiftui.com/#website"},"potentialAction":[{"@type":"ReadAction","target":["https://exploreswiftui.com/library/controlgroup/compactmenucontrolgroupstyle"]}],"primaryImageOfPage":{"@id":"https://exploreswiftui.com/#logo"}},{"@id":"https://exploreswiftui.com/#identity","@type":"Organization","description":"A visual library for SwiftUI APIs, components, and modifiers","name":"Explore SwiftUI","url":"https://exploreswiftui.com","logo":{"@id":"https://exploreswiftui.com/#logo"},"sameAs":["https://x.com/Typ0genius","https://mastodon.social/@Typ0genius"]},{"@id":"https://exploreswiftui.com/library/controlgroup/compactmenucontrolgroupstyle#article","dateModified":"2025-12-27T13:37:55.421Z","datePublished":"2025-06-04T12:20:41.812Z","description":"A control group style that presents its content as a compact menu when the user presses the control, or as a submenu when nested within a larger menu","headline":"CompactMenuControlGroupStyle","inLanguage":"en-US","name":"CompactMenuControlGroupStyle","thumbnailUrl":"https://exploreswiftui.com/api/images/54/variants/400?v=1790073478842&r=2","url":"https://exploreswiftui.com/library/controlgroup/compactmenucontrolgroupstyle","@type":["Article","TechArticle"],"about":{"@type":"Thing","name":"SwiftUI"},"author":{"@id":"https://exploreswiftui.com/#identity"},"image":{"@id":"https://exploreswiftui.com/#/schema/image/1"},"isPartOf":{"@type":"WebSite","name":"Explore SwiftUI","url":"https://exploreswiftui.com"},"mainEntityOfPage":{"@id":"https://exploreswiftui.com/library/controlgroup/compactmenucontrolgroupstyle#webpage"},"publisher":{"@id":"https://exploreswiftui.com/#identity"}},{"@id":"https://exploreswiftui.com/library/controlgroup/compactmenucontrolgroupstyle#/schema/software-source-code/1","@type":"SoftwareSourceCode","codeRepository":"https://developer.apple.com/documentation/swiftui/controlgroupstyle/compactmenu","codeSampleType":"full example","description":"A control group style that presents its content as a compact menu when the user presses the control, or as a submenu when nested within a larger menu","name":"CompactMenuControlGroupStyle SwiftUI Example","programmingLanguage":"Swift","runtimePlatform":"SwiftUI","text":"VStack {\n    ControlGroup {\n        Button(\"Increase\", systemImage: \"plus\", action: action)\n        Button(\"Decrease\", systemImage: \"minus\", action: action)\n    } label: {\n        Text(\"Foo\")\n    }\n    ControlGroup(\"Foo\", systemImage: \"magnifyingglass\") {\n        Button(\"Increase\", systemImage: \"plus\", action: action)\n        Button(\"Decrease\", systemImage: \"minus\", action: action)\n    }\n    ControlGroup {\n        Button(\"Increase\", systemImage: \"plus\", action: action)\n        Button(\"Decrease\", systemImage: \"minus\", action: action)\n    }\n}\n.controlGroupStyle(.compactMenu)","about":[{"@type":"Thing","name":"SwiftUI"},{"@type":"Thing","name":"ControlGroup"},{"@type":"Thing","name":"CompactMenuControlGroupStyle"}]},{"@id":"https://exploreswiftui.com/library/controlgroup/compactmenucontrolgroupstyle#breadcrumb","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","name":"Home","item":"https://exploreswiftui.com","position":1},{"@type":"ListItem","name":"ControlGroup","item":"https://exploreswiftui.com/library/controlgroup","position":2},{"@type":"ListItem","name":"CompactMenuControlGroupStyle","item":"https://exploreswiftui.com/library/controlgroup/compactmenucontrolgroupstyle","position":3}]},{"@id":"https://exploreswiftui.com/#logo","@type":"ImageObject","caption":"Explore SwiftUI","contentUrl":"https://exploreswiftui.com/apple-touch-icon.png","inLanguage":"en","url":"https://exploreswiftui.com/apple-touch-icon.png"},{"@id":"https://exploreswiftui.com/#/schema/image/1","@type":"ImageObject","contentUrl":"https://exploreswiftui.com/api/images/54/variants/400?v=1790073478842&r=2","inLanguage":"en","url":"https://exploreswiftui.com/api/images/54/variants/400?v=1790073478842&r=2"}]}
```