diff --git a/SodaLive/Resources/Assets.xcassets/ic_can.imageset/ic_can.png b/SodaLive/Resources/Assets.xcassets/ic_can.imageset/ic_can.png index ebd2064..7142a77 100644 Binary files a/SodaLive/Resources/Assets.xcassets/ic_can.imageset/ic_can.png and b/SodaLive/Resources/Assets.xcassets/ic_can.imageset/ic_can.png differ diff --git a/SodaLive/Resources/Assets.xcassets/ic_no_item.imageset/ic_no_item.png b/SodaLive/Resources/Assets.xcassets/ic_no_item.imageset/ic_no_item.png index 498f40c..9b86d83 100644 Binary files a/SodaLive/Resources/Assets.xcassets/ic_no_item.imageset/ic_no_item.png and b/SodaLive/Resources/Assets.xcassets/ic_no_item.imageset/ic_no_item.png differ diff --git a/SodaLive/Sources/Dialog/LiveRoomPasswordDialog.swift b/SodaLive/Sources/Dialog/LiveRoomPasswordDialog.swift index 4348db4..41f40a8 100644 --- a/SodaLive/Sources/Dialog/LiveRoomPasswordDialog.swift +++ b/SodaLive/Sources/Dialog/LiveRoomPasswordDialog.swift @@ -70,6 +70,8 @@ struct LiveRoomPasswordDialog: View { .foregroundColor(Color(hex: "ffffff")) Image("ic_can") + .resizable() + .frame(width: 20, height: 20) Text("으로 입장") .font(.custom(Font.bold.rawValue, size: 15.3)) diff --git a/SodaLive/Sources/Live/Room/Chat/LiveRoomDonationChatItemView.swift b/SodaLive/Sources/Live/Room/Chat/LiveRoomDonationChatItemView.swift index d2922bc..cd89b53 100644 --- a/SodaLive/Sources/Live/Room/Chat/LiveRoomDonationChatItemView.swift +++ b/SodaLive/Sources/Live/Room/Chat/LiveRoomDonationChatItemView.swift @@ -23,6 +23,8 @@ struct LiveRoomDonationChatItemView: View { .cornerRadius(23.3) Image("ic_can") + .resizable() + .frame(width: 20, height: 20) } VStack(alignment: .leading, spacing: 6.7) { diff --git a/SodaLive/Sources/Live/Room/LiveRoomTopCreatorView.swift b/SodaLive/Sources/Live/Room/LiveRoomTopCreatorView.swift index 1fe9d20..fe724f5 100644 --- a/SodaLive/Sources/Live/Room/LiveRoomTopCreatorView.swift +++ b/SodaLive/Sources/Live/Room/LiveRoomTopCreatorView.swift @@ -11,6 +11,7 @@ import Kingfisher struct LiveRoomTopCreatorView: View { + let creatorId: Int var nickname: String var profileImageUrl: String var isFollowing: Bool @@ -34,8 +35,10 @@ struct LiveRoomTopCreatorView: View { Spacer() - Image(isFollowing ? "btn_following" : "btn_follow") - .onTapGesture { onClickFollow(isFollowing) } + if creatorId != UserDefaults.int(forKey: .userId) { + Image(isFollowing ? "btn_following" : "btn_follow") + .onTapGesture { onClickFollow(isFollowing) } + } } } } diff --git a/SodaLive/Sources/Live/Room/LiveRoomView.swift b/SodaLive/Sources/Live/Room/LiveRoomView.swift index 9b88d20..7baec7e 100644 --- a/SodaLive/Sources/Live/Room/LiveRoomView.swift +++ b/SodaLive/Sources/Live/Room/LiveRoomView.swift @@ -115,6 +115,7 @@ struct LiveRoomView: View { .padding(.horizontal, 13.3) LiveRoomTopCreatorView( + creatorId: liveRoomInfo.creatorId, nickname: liveRoomInfo.creatorNickname, profileImageUrl: liveRoomInfo.creatorProfileUrl, isFollowing: liveRoomInfo.isFollowing, @@ -125,9 +126,9 @@ struct LiveRoomView: View { }, onClickFollow: { if $0 { - viewModel.unRegisterNotification() + viewModel.creatorUnFollow() } else { - viewModel.registerNotification() + viewModel.creatorFollow() } } ) @@ -503,8 +504,8 @@ struct LiveRoomView: View { onClickRequestSpeaker: { viewModel.requestSpeaker() }, - registerNotification: { viewModel.registerNotification() }, - unRegisterNotification: { viewModel.unRegisterNotification() }, + registerNotification: { viewModel.creatorFollow() }, + unRegisterNotification: { viewModel.creatorUnFollow() }, onClickProfile: { if $0 != UserDefaults.int(forKey: .userId) { viewModel.getUserProfile(userId: $0) @@ -526,8 +527,8 @@ struct LiveRoomView: View { viewModel.setManager(userId: $0) }, onClickReleaseManager: { viewModel.changeListener(peerId: $0, isFromManager: true) }, - onClickFollow: { viewModel.registerNotification(creatorId: $0, isGetUserProfile: true) }, - onClickUnFollow: { viewModel.unRegisterNotification(creatorId: $0, isGetUserProfile: true) }, + onClickFollow: { viewModel.creatorFollow(creatorId: $0, isGetUserProfile: true) }, + onClickUnFollow: { viewModel.creatorUnFollow(creatorId: $0, isGetUserProfile: true) }, onClickInviteSpeaker: { inviteSpeaker(peerId: $0) }, onClickChangeListener: { viewModel.changeListener(peerId: $0) @@ -722,7 +723,7 @@ struct LiveRoomView: View { Spacer() HStack(spacing: 4.7) { - Image("ic_donation_status") + Image("ic_can") .resizable() .frame(width: 16, height: 16) diff --git a/SodaLive/Sources/Live/Room/LiveRoomViewModel.swift b/SodaLive/Sources/Live/Room/LiveRoomViewModel.swift index 0a8d1d0..0b982eb 100644 --- a/SodaLive/Sources/Live/Room/LiveRoomViewModel.swift +++ b/SodaLive/Sources/Live/Room/LiveRoomViewModel.swift @@ -751,7 +751,7 @@ final class LiveRoomViewModel: NSObject, ObservableObject { .store(in: &subscription) } - func registerNotification(creatorId: Int? = nil, isGetUserProfile: Bool = false) { + func creatorFollow(creatorId: Int? = nil, isGetUserProfile: Bool = false) { var userId = 0 if let creatorId = creatorId { @@ -803,7 +803,7 @@ final class LiveRoomViewModel: NSObject, ObservableObject { } } - func unRegisterNotification(creatorId: Int? = nil, isGetUserProfile: Bool = false) { + func creatorUnFollow(creatorId: Int? = nil, isGetUserProfile: Bool = false) { var userId = 0 if let creatorId = creatorId { diff --git a/SodaLive/Sources/MyPage/CanCardView.swift b/SodaLive/Sources/MyPage/CanCardView.swift index 9e1b0b6..36026f5 100644 --- a/SodaLive/Sources/MyPage/CanCardView.swift +++ b/SodaLive/Sources/MyPage/CanCardView.swift @@ -20,6 +20,8 @@ struct CanCardView: View { .foregroundColor(Color(hex: "eeeeee")) Image("ic_can") + .resizable() + .frame(width: 20, height: 20) Image("ic_forward") .resizable()