feat(creator-channel): 차단·신고 메뉴를 연결한다

This commit is contained in:
Yu Sung
2026-08-14 16:41:33 +09:00
parent 080f36e690
commit 4b209dcd72
4 changed files with 197 additions and 1 deletions

View File

@@ -19,6 +19,10 @@ struct CreatorChannelView: View {
@State private var isShowChannelDonationDialog = false
@State private var isShowAuthView = false
@State private var isShowAuthConfirmView = false
@State private var isShowReportMenu = false
@State private var isShowUserBlockConfirm = false
@State private var isShowUserReport = false
@State private var isShowProfileReport = false
@State private var isCreatorActionMenuPresented = false
@State private var pendingAction: (() -> Void)? = nil
@State private var payload = Payload()
@@ -183,6 +187,56 @@ struct CreatorChannelView: View {
)
}
if viewModel.response != nil && isShowReportMenu {
VStack(spacing: 0) {
ProfileReportMenuView(
isShowing: $isShowReportMenu,
isBlockedUser: false,
userBlockAction: { isShowUserBlockConfirm = true },
userUnBlockAction: {},
userReportAction: { isShowUserReport = true },
profileReportAction: { isShowProfileReport = true }
)
if proxy.safeAreaInsets.bottom > 0 {
Rectangle()
.foregroundColor(Color(hex: "222222"))
.frame(width: proxy.size.width, height: 15.3)
}
}
.ignoresSafeArea()
}
if let creator = viewModel.response?.creator, isShowUserBlockConfirm {
UserBlockConfirmDialogView(
isShowing: $isShowUserBlockConfirm,
nickname: creator.nickname,
confirmAction: {
viewModel.userBlock(userId: creator.creatorId) {
dismiss()
}
}
)
}
if isShowUserReport {
UserReportDialogView(
isShowing: $isShowUserReport,
confirmAction: { reason in
viewModel.report(type: .USER, userId: creatorId, reason: reason)
}
)
}
if isShowProfileReport {
ProfileReportDialogView(
isShowing: $isShowProfileReport,
confirmAction: {
viewModel.report(type: .PROFILE, userId: creatorId)
}
)
}
communityOverlay(proxy: proxy)
}
}
@@ -227,7 +281,9 @@ struct CreatorChannelView: View {
onTapUnnotify: {
viewModel.creatorFollow(follow: true, notify: false)
},
onTapMore: {}
onTapMore: {
isShowReportMenu = true
}
)
}