struct DisclosureGroup: View {
var body: some View {
VStack {
Text(/*@START_MENU_TOKEN@*/"Hello, World!"/*@END_MENU_TOKEN@*/)
DisclosureGroup("Group") {
DisclosureGroup("Group") {
DisclosureGroup("Group") {
RoundedRectangle(cornerRadius: 25.0)
.frame(height: 200)
}
.padding()
.background(Color.pink.opacity(0.7))
}
.padding()
.background(Color.pink.opacity(0.7))
}
.padding()
.background(Color.pink.opacity(0.7))
ScrollView {
ForEach(0 ..< 50) { item in
DisclosureGroup(
content: {
RoundedRectangle(cornerRadius: 25.0)
.frame(height: 200)
},
label: {
Image(systemName: "moon.fill")
Text("Moon Cycle")
})
.padding()
}
}
}
}
}
DisclosureGroup