// // DropDownFriends.swift // AllIn // // Created by Emre on 16/12/2023. // import SwiftUI struct DropDownFriends: View { @State private var selectedItems: Set = [] @State var expand = false let friends: [(Int, Int, String, String)] = [ (0, 541, "David", "defaultUserImage"), (1, 541, "David", "defaultUserImage"), (2, 541, "David", "defaultUserImage"), (3, 541, "David", "defaultUserImage"), (4, 541, "David", "defaultUserImage"), (5, 541, "David", "defaultUserImage") ] var body: some View { VStack(spacing: 0, content: { Button(action: { self.expand.toggle() }) { HStack(spacing: 3){ Text("41") .textStyle(weight: .bold, color: AllInColors.primaryTextColor, size: 15) Text("amis disponibles") .textStyle(weight: .regular, color: AllInColors.grey800Color, size: 15) Spacer() Image(expand ? "chevronUpIcon" : "chevronDownIcon").resizable().frame(width: 15, height: 7).scaledToFill() } .padding([.leading, .trailing], 15) .padding(.top, 5) .frame(height: 43) } if expand { Rectangle() .frame(height: 1) .foregroundColor(AllInColors.delimiterGrey) ScrollView(.vertical) { VStack(spacing: 0) { ForEach(0..