SweetUI

Search items

Jump to an item

component

button-group

ControlGroup: buttons side by side, one variant; keeps roles, labels.

buttoncontrol-groupactionstyle
button-group, light

On iPad

The same installed source at a regular width. It adapts its layout without a separate design.

button-group on iPad, light

Install

With the sweetui tool (brew install mangobyte-dev/tap/sweetui):

sweetui install button-group --destination Sources/YourFeature/Components

Installs in order: button 0.5.2, button-group 0.3.2. Point --destination at a folder inside the consuming target's sources.

Usage

// Content layer only. In toolbars, tab bars, or floating chrome the system supplies Liquid Glass; use .buttonStyle(.glass) or .buttonStyle(.glassProminent) there instead of .registry styles.

ControlGroup {
    Button("Undo", systemImage: "arrow.uturn.backward") {}
    Button("Redo", systemImage: "arrow.uturn.forward") {}
}
.controlGroupStyle(.registryButtons)

Accessibility contract

  • Native Button controls; one container.
  • Keeps button label, role.
  • Inherits direction, size, state, Dynamic Type.
  • Icon-only buttons MUST have labels.

Details

Kindcomponent
Version0.3.2
PlatformsiOS 26.0+
Dependenciesbutton
SourceRegistry/sources/components/RegistryButtonGroupStyle.swift
Xcode previewButton Group