feat(creator-profile): 후원 랭킹 섹션, 팬 Talk 섹션 UI 변경
This commit is contained in:
		@@ -31,9 +31,9 @@ struct UserProfileFanTalkCheersItemView: View {
 | 
			
		||||
                HStack(alignment: .top, spacing: 6.7) {
 | 
			
		||||
                    KFImage(URL(string: cheersItem.profileUrl))
 | 
			
		||||
                        .cancelOnDisappear(true)
 | 
			
		||||
                        .downsampling(size: CGSize(width: 33.3, height: 33.3))
 | 
			
		||||
                        .downsampling(size: CGSize(width: 42, height: 42))
 | 
			
		||||
                        .resizable()
 | 
			
		||||
                        .frame(width: 33.3, height: 33.3)
 | 
			
		||||
                        .frame(width: 42, height: 42)
 | 
			
		||||
                        .clipShape(Circle())
 | 
			
		||||
                        .onTapGesture {
 | 
			
		||||
                            if UserDefaults.int(forKey: .userId) != cheersItem.memberId {
 | 
			
		||||
@@ -43,20 +43,20 @@ struct UserProfileFanTalkCheersItemView: View {
 | 
			
		||||
                    
 | 
			
		||||
                    VStack(alignment: .leading, spacing: 0) {
 | 
			
		||||
                        Text("\(cheersItem.nickname)")
 | 
			
		||||
                            .font(.custom(Font.medium.rawValue, size: 12))
 | 
			
		||||
                            .foregroundColor(Color.gray90)
 | 
			
		||||
                            .font(.custom(Font.preBold.rawValue, size: 16))
 | 
			
		||||
                            .foregroundColor(Color.white)
 | 
			
		||||
                        
 | 
			
		||||
                        Text("\(cheersItem.date)")
 | 
			
		||||
                            .font(.custom(Font.medium.rawValue, size: 10.7))
 | 
			
		||||
                            .foregroundColor(Color.gray55)
 | 
			
		||||
                            .padding(.top, 8.3)
 | 
			
		||||
                            .font(.custom(Font.preMedium.rawValue, size: 14))
 | 
			
		||||
                            .foregroundColor(Color(hex: "78909C"))
 | 
			
		||||
                            .padding(.top, 4)
 | 
			
		||||
                        
 | 
			
		||||
                        if isModeModify {
 | 
			
		||||
                            HStack(spacing: 10) {
 | 
			
		||||
                                TextField("", text: $cheers)
 | 
			
		||||
                                    .autocapitalization(.none)
 | 
			
		||||
                                    .disableAutocorrection(true)
 | 
			
		||||
                                    .font(.custom(Font.medium.rawValue, size: 13.3))
 | 
			
		||||
                                    .font(.custom(Font.preMedium.rawValue, size: 14))
 | 
			
		||||
                                    .foregroundColor(Color.grayee)
 | 
			
		||||
                                    .padding(13.3)
 | 
			
		||||
                                    .background(Color.gray23)
 | 
			
		||||
@@ -70,7 +70,7 @@ struct UserProfileFanTalkCheersItemView: View {
 | 
			
		||||
                                    )
 | 
			
		||||
                                
 | 
			
		||||
                                Text("수정")
 | 
			
		||||
                                    .font(.custom(Font.bold.rawValue, size: 13.3))
 | 
			
		||||
                                    .font(.custom(Font.preBold.rawValue, size: 14))
 | 
			
		||||
                                    .foregroundColor(Color.white)
 | 
			
		||||
                                    .padding(13.3)
 | 
			
		||||
                                    .background(Color.button)
 | 
			
		||||
@@ -81,7 +81,7 @@ struct UserProfileFanTalkCheersItemView: View {
 | 
			
		||||
                                    }
 | 
			
		||||
                                
 | 
			
		||||
                                Text("취소")
 | 
			
		||||
                                    .font(.custom(Font.bold.rawValue, size: 13.3))
 | 
			
		||||
                                    .font(.custom(Font.preBold.rawValue, size: 14))
 | 
			
		||||
                                    .foregroundColor(Color.button)
 | 
			
		||||
                                    .padding(13.3)
 | 
			
		||||
                                    .background(Color.gray22)
 | 
			
		||||
@@ -93,11 +93,11 @@ struct UserProfileFanTalkCheersItemView: View {
 | 
			
		||||
                            .padding(.top, 13.3)
 | 
			
		||||
                        } else {
 | 
			
		||||
                            Text("\(cheersItem.content)")
 | 
			
		||||
                                .font(.custom(Font.medium.rawValue, size: 13.3))
 | 
			
		||||
                                .foregroundColor(Color.grayee)
 | 
			
		||||
                                .font(.custom(Font.preMedium.rawValue, size: 16))
 | 
			
		||||
                                .foregroundColor(Color(hex: "B0BEC5"))
 | 
			
		||||
                                .fixedSize(horizontal: false, vertical: true)
 | 
			
		||||
                                .lineSpacing(8)
 | 
			
		||||
                                .padding(.top, 13.3)
 | 
			
		||||
                                .padding(.top, 12)
 | 
			
		||||
                        }
 | 
			
		||||
                        
 | 
			
		||||
                        if isShowInputReply {
 | 
			
		||||
@@ -105,7 +105,7 @@ struct UserProfileFanTalkCheersItemView: View {
 | 
			
		||||
                                TextField("응원댓글에 답글을 남겨보세요!", text: $replyContent)
 | 
			
		||||
                                    .autocapitalization(.none)
 | 
			
		||||
                                    .disableAutocorrection(true)
 | 
			
		||||
                                    .font(.custom(Font.medium.rawValue, size: 13.3))
 | 
			
		||||
                                    .font(.custom(Font.preMedium.rawValue, size: 14))
 | 
			
		||||
                                    .foregroundColor(Color.grayee)
 | 
			
		||||
                                    .padding(13.3)
 | 
			
		||||
                                    .background(Color.gray23)
 | 
			
		||||
@@ -119,7 +119,7 @@ struct UserProfileFanTalkCheersItemView: View {
 | 
			
		||||
                                    )
 | 
			
		||||
                                
 | 
			
		||||
                                Text("등록")
 | 
			
		||||
                                    .font(.custom(Font.bold.rawValue, size: 13.3))
 | 
			
		||||
                                    .font(.custom(Font.preBold.rawValue, size: 14))
 | 
			
		||||
                                    .foregroundColor(Color.white)
 | 
			
		||||
                                    .padding(13.3)
 | 
			
		||||
                                    .background(Color.button)
 | 
			
		||||
@@ -137,7 +137,7 @@ struct UserProfileFanTalkCheersItemView: View {
 | 
			
		||||
                            if cheersItem.replyList.count <= 0 {
 | 
			
		||||
                                if userId == UserDefaults.int(forKey: .userId) {
 | 
			
		||||
                                    Text("답글쓰기")
 | 
			
		||||
                                        .font(.custom(Font.medium.rawValue, size: 12))
 | 
			
		||||
                                        .font(.custom(Font.preMedium.rawValue, size: 12))
 | 
			
		||||
                                        .foregroundColor(Color.button)
 | 
			
		||||
                                        .padding(.top, 18.3)
 | 
			
		||||
                                        .onTapGesture {
 | 
			
		||||
@@ -148,7 +148,7 @@ struct UserProfileFanTalkCheersItemView: View {
 | 
			
		||||
                                let reply = cheersItem.replyList[0]
 | 
			
		||||
                                VStack(alignment: .leading, spacing: 8.3) {
 | 
			
		||||
                                    Text(reply.content)
 | 
			
		||||
                                        .font(.custom(Font.medium.rawValue, size: 12))
 | 
			
		||||
                                        .font(.custom(Font.preMedium.rawValue, size: 12))
 | 
			
		||||
                                        .foregroundColor(Color.white)
 | 
			
		||||
                                        .frame(minWidth: 100)
 | 
			
		||||
                                        .padding(.horizontal, 6.7)
 | 
			
		||||
@@ -160,12 +160,12 @@ struct UserProfileFanTalkCheersItemView: View {
 | 
			
		||||
                                    
 | 
			
		||||
                                    HStack(spacing: 6.7) {
 | 
			
		||||
                                        Text(reply.date)
 | 
			
		||||
                                            .font(.custom(Font.medium.rawValue, size: 10.7))
 | 
			
		||||
                                            .font(.custom(Font.preMedium.rawValue, size: 10.7))
 | 
			
		||||
                                            .foregroundColor(Color.gray52)
 | 
			
		||||
                                        
 | 
			
		||||
                                        if userId == UserDefaults.int(forKey: .userId) {
 | 
			
		||||
                                            Text("답글 수정")
 | 
			
		||||
                                                .font(.custom(Font.medium.rawValue, size: 10.7))
 | 
			
		||||
                                                .font(.custom(Font.preMedium.rawValue, size: 12))
 | 
			
		||||
                                                .foregroundColor(Color.button)
 | 
			
		||||
                                                .onTapGesture {
 | 
			
		||||
                                                    self.replyContent = reply.content
 | 
			
		||||
@@ -197,7 +197,7 @@ struct UserProfileFanTalkCheersItemView: View {
 | 
			
		||||
                VStack(spacing: 10) {
 | 
			
		||||
                    if cheersItem.memberId != UserDefaults.int(forKey: .userId) {
 | 
			
		||||
                        Text("신고하기")
 | 
			
		||||
                            .font(.custom(Font.medium.rawValue, size: 14))
 | 
			
		||||
                            .font(.custom(Font.preMedium.rawValue, size: 14))
 | 
			
		||||
                            .foregroundColor(Color.gray77)
 | 
			
		||||
                            .onTapGesture {
 | 
			
		||||
                                reportPopup(cheersItem.cheersId)
 | 
			
		||||
@@ -207,7 +207,7 @@ struct UserProfileFanTalkCheersItemView: View {
 | 
			
		||||
                    
 | 
			
		||||
                    if cheersItem.memberId == UserDefaults.int(forKey: .userId) {
 | 
			
		||||
                        Text("수정")
 | 
			
		||||
                            .font(.custom(Font.medium.rawValue, size: 14))
 | 
			
		||||
                            .font(.custom(Font.preMedium.rawValue, size: 14))
 | 
			
		||||
                            .foregroundColor(Color.gray77)
 | 
			
		||||
                            .onTapGesture {
 | 
			
		||||
                                isModeModify = true
 | 
			
		||||
@@ -220,7 +220,7 @@ struct UserProfileFanTalkCheersItemView: View {
 | 
			
		||||
                        cheersItem.memberId == UserDefaults.int(forKey: .userId)
 | 
			
		||||
                    {
 | 
			
		||||
                        Text("삭제")
 | 
			
		||||
                            .font(.custom(Font.medium.rawValue, size: 14))
 | 
			
		||||
                            .font(.custom(Font.preMedium.rawValue, size: 14))
 | 
			
		||||
                            .foregroundColor(Color.gray77)
 | 
			
		||||
                            .onTapGesture {
 | 
			
		||||
                                onClickDelete(cheersItem.cheersId)
 | 
			
		||||
 
 | 
			
		||||
@@ -26,42 +26,36 @@ struct UserProfileFanTalkView: View {
 | 
			
		||||
        VStack(alignment: .leading, spacing: 0) {
 | 
			
		||||
            HStack(spacing: 0) {
 | 
			
		||||
                Text("팬 Talk")
 | 
			
		||||
                    .font(.custom(Font.bold.rawValue, size: 16.7))
 | 
			
		||||
                    .foregroundColor(Color.grayee)
 | 
			
		||||
                    .font(.custom(Font.preBold.rawValue, size: 26))
 | 
			
		||||
                    .foregroundColor(Color.white)
 | 
			
		||||
                
 | 
			
		||||
                Spacer()
 | 
			
		||||
                
 | 
			
		||||
                Text("전체보기")
 | 
			
		||||
                    .font(.custom(Font.light.rawValue, size: 11.3))
 | 
			
		||||
                    .foregroundColor(Color.graybb)
 | 
			
		||||
                    .font(.custom(Font.preLight.rawValue, size: 14))
 | 
			
		||||
                    .foregroundColor(Color(hex: "78909C"))
 | 
			
		||||
                    .onTapGesture {
 | 
			
		||||
                        AppState.shared.setAppStep(step: .userProfileFanTalkAll(userId: userId))
 | 
			
		||||
                    }
 | 
			
		||||
            }
 | 
			
		||||
            .padding(.horizontal, 13.3)
 | 
			
		||||
            .padding(.horizontal, 24)
 | 
			
		||||
            
 | 
			
		||||
            VStack(alignment: .leading, spacing: 0) {
 | 
			
		||||
            VStack(alignment: .leading, spacing: 20) {
 | 
			
		||||
                HStack(spacing: 6.7) {
 | 
			
		||||
                    Text("응원")
 | 
			
		||||
                        .font(.custom(Font.medium.rawValue, size: 14.7))
 | 
			
		||||
                        .font(.custom(Font.preMedium.rawValue, size: 16))
 | 
			
		||||
                        .foregroundColor(Color.grayee)
 | 
			
		||||
                    
 | 
			
		||||
                    Text("\(cheers.totalCount)")
 | 
			
		||||
                        .font(.custom(Font.medium.rawValue, size: 12))
 | 
			
		||||
                        .font(.custom(Font.preMedium.rawValue, size: 14))
 | 
			
		||||
                        .foregroundColor(Color.gray77)
 | 
			
		||||
                }
 | 
			
		||||
                .padding(.top, 20)
 | 
			
		||||
                
 | 
			
		||||
                Rectangle()
 | 
			
		||||
                    .frame(height: 1)
 | 
			
		||||
                    .foregroundColor(Color.gray90.opacity(0.5))
 | 
			
		||||
                    .padding(.top, 13.3)
 | 
			
		||||
                
 | 
			
		||||
                HStack(spacing: 0) {
 | 
			
		||||
                    TextField("응원댓글을 입력하세요", text: $cheersContent)
 | 
			
		||||
                        .autocapitalization(.none)
 | 
			
		||||
                        .disableAutocorrection(true)
 | 
			
		||||
                        .font(.custom(Font.medium.rawValue, size: 13.3))
 | 
			
		||||
                        .font(.custom(Font.preMedium.rawValue, size: 14))
 | 
			
		||||
                        .foregroundColor(Color.grayee)
 | 
			
		||||
                        .accentColor(Color.button)
 | 
			
		||||
                        .keyboardType(.default)
 | 
			
		||||
@@ -86,12 +80,6 @@ struct UserProfileFanTalkView: View {
 | 
			
		||||
                        .strokeBorder(lineWidth: 1)
 | 
			
		||||
                        .foregroundColor(Color.button)
 | 
			
		||||
                )
 | 
			
		||||
                .padding(.top, 13.3)
 | 
			
		||||
                
 | 
			
		||||
                Rectangle()
 | 
			
		||||
                    .frame(height: 1)
 | 
			
		||||
                    .foregroundColor(Color.gray90.opacity(0.5))
 | 
			
		||||
                    .padding(.top, 13.3)
 | 
			
		||||
                
 | 
			
		||||
                VStack(spacing: 20) {
 | 
			
		||||
                    if viewModel.cheersTotalCount > 0 {
 | 
			
		||||
@@ -122,18 +110,19 @@ struct UserProfileFanTalkView: View {
 | 
			
		||||
                        }
 | 
			
		||||
                    } else {
 | 
			
		||||
                        Text("응원이 없습니다.\n\n처음으로 응원을 해보세요!")
 | 
			
		||||
                            .font(.custom(Font.light.rawValue, size: 13.3))
 | 
			
		||||
                            .font(.custom(Font.preLight.rawValue, size: 13.3))
 | 
			
		||||
                            .foregroundColor(Color.graybb)
 | 
			
		||||
                            .multilineTextAlignment(.center)
 | 
			
		||||
                            .fixedSize(horizontal: false, vertical: true)
 | 
			
		||||
                            .padding(.vertical, 60)
 | 
			
		||||
                            .frame(width: screenSize().width - 26.7)
 | 
			
		||||
                            .frame(maxWidth: .infinity)
 | 
			
		||||
                            .padding(.horizontal, 24)
 | 
			
		||||
                    }
 | 
			
		||||
                }
 | 
			
		||||
                .padding(.top, 20)
 | 
			
		||||
            }
 | 
			
		||||
            .frame(width: screenSize().width - 26.7)
 | 
			
		||||
            .padding(.horizontal, 13.3)
 | 
			
		||||
            .frame(maxWidth: .infinity)
 | 
			
		||||
            .padding(.horizontal, 24)
 | 
			
		||||
            .padding(.top, 20)
 | 
			
		||||
        }
 | 
			
		||||
        .onTapGesture { hideKeyboard() }
 | 
			
		||||
        .onAppear {
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user