<!--
{
  "availability" : [
    "iOS: 15.0.0 -",
    "iPadOS: 15.0.0 -",
    "macCatalyst: 15.0.0 -",
    "macOS: 12.0.0 -",
    "tvOS: 17.0.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "SwiftUI",
  "identifier" : "/documentation/SwiftUI/ControlGroupStyle",
  "metadataVersion" : "0.1.0",
  "role" : "Protocol",
  "symbol" : {
    "kind" : "Protocol",
    "modules" : [
      "SwiftUI"
    ],
    "preciseIdentifier" : "s:7SwiftUI17ControlGroupStyleP"
  },
  "title" : "ControlGroupStyle"
}
-->

# ControlGroupStyle

Defines the implementation of all control groups within a view
hierarchy.

```
@MainActor @preconcurrency protocol ControlGroupStyle
```

## Overview

To configure the current `ControlGroupStyle` for a view hierarchy, use the
[`controlGroupStyle(_:)`](/documentation/SwiftUI/View/controlGroupStyle(_:)) modifier.

A type conforming to this protocol inherits `@preconcurrency @MainActor`
isolation from the protocol if the conformance is included in the type’s
base declaration:

```
struct MyCustomType: Transition {
    // `@preconcurrency @MainActor` isolation by default
}
```

Isolation to the main actor is the default, but it’s not required. Declare
the conformance in an extension to opt out of main actor isolation:

```
extension MyCustomType: Transition {
    // `nonisolated` by default
}
```

## Topics

### Getting built-in control group styles

[`automatic`](/documentation/SwiftUI/ControlGroupStyle/automatic)

The default control group style.

[`compactMenu`](/documentation/SwiftUI/ControlGroupStyle/compactMenu)

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.

[`menu`](/documentation/SwiftUI/ControlGroupStyle/menu)

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.

[`navigation`](/documentation/SwiftUI/ControlGroupStyle/navigation)

The navigation control group style.

[`palette`](/documentation/SwiftUI/ControlGroupStyle/palette)

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

### Creating custom control group styles

[`makeBody(configuration:)`](/documentation/SwiftUI/ControlGroupStyle/makeBody(configuration:))

Creates a view representing the body of a control group.

[`Configuration`](/documentation/SwiftUI/ControlGroupStyle/Configuration)

The properties of a `ControlGroup` instance being created.

[`Body`](/documentation/SwiftUI/ControlGroupStyle/Body)

A view representing the body of a control group.

### Supporting types

[`AutomaticControlGroupStyle`](/documentation/SwiftUI/AutomaticControlGroupStyle)

The default control group style.

[`CompactMenuControlGroupStyle`](/documentation/SwiftUI/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.

[`MenuControlGroupStyle`](/documentation/SwiftUI/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.

[`NavigationControlGroupStyle`](/documentation/SwiftUI/NavigationControlGroupStyle)

The navigation control group style.

[`PaletteControlGroupStyle`](/documentation/SwiftUI/PaletteControlGroupStyle)

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

## Relationships

### Conforming Types

[`AutomaticControlGroupStyle`](/documentation/SwiftUI/AutomaticControlGroupStyle)

[`PaletteControlGroupStyle`](/documentation/SwiftUI/PaletteControlGroupStyle)

[`CompactMenuControlGroupStyle`](/documentation/SwiftUI/CompactMenuControlGroupStyle)

[`NavigationControlGroupStyle`](/documentation/SwiftUI/NavigationControlGroupStyle)

[`MenuControlGroupStyle`](/documentation/SwiftUI/MenuControlGroupStyle)

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)