라이브 상세 - 참여자 리스트 삭제
This commit is contained in:
parent
30cceefbcf
commit
e8de5dd72b
|
@ -106,15 +106,6 @@ struct LiveDetailView: View {
|
|||
.padding(.top, 16.7)
|
||||
.frame(width: proxy.size.width - 26.7)
|
||||
|
||||
Rectangle()
|
||||
.frame(height: 1)
|
||||
.foregroundColor(Color(hex: "909090").opacity(0.5))
|
||||
.padding(.top, 8)
|
||||
.frame(width: proxy.size.width - 26.7)
|
||||
|
||||
ParticipantView(room: room)
|
||||
.frame(width: proxy.size.width - 26.7)
|
||||
|
||||
Rectangle()
|
||||
.frame(height: 1)
|
||||
.foregroundColor(Color(hex: "909090").opacity(0.5))
|
||||
|
@ -418,88 +409,6 @@ struct LiveDetailView: View {
|
|||
}
|
||||
}
|
||||
|
||||
@ViewBuilder
|
||||
private func ParticipantView(room: GetRoomDetailResponse) -> some View {
|
||||
if isExpandParticipantArea {
|
||||
HStack(spacing: 0) {
|
||||
Text(room.channelName.isNullOrBlank() ? "예약자" : "참가자")
|
||||
.font(.custom(Font.medium.rawValue, size: 12))
|
||||
.foregroundColor(Color(hex: "eeeeee"))
|
||||
|
||||
Spacer()
|
||||
|
||||
Text("\(room.numberOfParticipants)")
|
||||
.font(.custom(Font.medium.rawValue, size: 12))
|
||||
.foregroundColor(Color(hex: "9970ff"))
|
||||
|
||||
Text("/\(room.numberOfParticipantsTotal)")
|
||||
.font(.custom(Font.medium.rawValue, size: 12))
|
||||
.foregroundColor(Color(hex: "bbbbbb"))
|
||||
}
|
||||
.padding(.top, 16.7)
|
||||
|
||||
LazyVGrid(columns: columns) {
|
||||
ForEach(room.participatingUsers, id: \.self) { user in
|
||||
VStack(spacing: 6.7) {
|
||||
KFImage(URL(string: user.profileImageUrl))
|
||||
.resizable()
|
||||
.scaledToFill()
|
||||
.frame(width: 46.7, height: 46.7, alignment: .top)
|
||||
.clipShape(Circle())
|
||||
|
||||
Text(user.nickname)
|
||||
.font(.custom(Font.medium.rawValue, size: 12))
|
||||
.foregroundColor(Color(hex: "bbbbbb"))
|
||||
.lineLimit(1)
|
||||
}
|
||||
}
|
||||
}
|
||||
.padding(.top, 16.7)
|
||||
} else {
|
||||
let userCount = room.numberOfParticipants > 10 ? 10 : room.numberOfParticipants
|
||||
|
||||
HStack(spacing: -13.3) {
|
||||
ForEach(0..<userCount, id: \.self) { index in
|
||||
let user = room.participatingUsers[index]
|
||||
KFImage(URL(string: user.profileImageUrl))
|
||||
.resizable()
|
||||
.scaledToFill()
|
||||
.frame(width: 33.3, height: 33.3, alignment: .top)
|
||||
.clipShape(Circle())
|
||||
}
|
||||
|
||||
Spacer()
|
||||
|
||||
HStack(spacing: 0) {
|
||||
Text("\(room.numberOfParticipants)")
|
||||
.font(.custom(Font.medium.rawValue, size: 12))
|
||||
.foregroundColor(Color(hex: "9970ff"))
|
||||
|
||||
Text("/\(room.numberOfParticipantsTotal)")
|
||||
.font(.custom(Font.medium.rawValue, size: 12))
|
||||
.foregroundColor(Color(hex: "bbbbbb"))
|
||||
}
|
||||
}
|
||||
.padding(.top, 22)
|
||||
}
|
||||
|
||||
if room.numberOfParticipants > 0 {
|
||||
HStack(spacing: 6.7) {
|
||||
Image(isExpandParticipantArea ? "ic_live_detail_top" : "ic_live_detail_bottom")
|
||||
.resizable()
|
||||
.frame(width: 20, height: 20)
|
||||
|
||||
Text(isExpandParticipantArea ? "닫기" : "펼쳐보기")
|
||||
.font(.custom(Font.medium.rawValue, size: 12))
|
||||
.foregroundColor(Color(hex: "bbbbbb"))
|
||||
}
|
||||
.padding(.top, 13.3)
|
||||
.onTapGesture {
|
||||
isExpandParticipantArea.toggle()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private func hideView() {
|
||||
if let close = onClickClose {
|
||||
close()
|
||||
|
|
Loading…
Reference in New Issue