SweetUI

Search items

Jump to an item

recipe

collapsible

Native DisclosureGroup, distinct from accordion.

collapsibledisclosureexpandtoggleguidance
collapsible, light

On iPad

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

collapsible on iPad, light

Install

Usage

@State private var isShowingDetails = false

DisclosureGroup("Fee breakdown", isExpanded: $isShowingDetails) {
    LabeledContent("Transfer fee", value: "KWD 1.000")
    LabeledContent("Exchange margin", value: "KWD 0.450")
}
.registryItem("collapsible")

Why native is enough

DisclosureGroup: 1 region. accordion: several stacked. No extra treatment.

Accessibility contract

  • Disclosure announces expanded/collapsed.
  • Keep label meaningful: collapsed, VoiceOver reads only it.

Details

Kindrecipe
Version0.1.1
PlatformsiOS 26.0+
Dependenciesnone
Sourcenone (native guidance)