Skip to content

feat: 커뮤니티 사용자 차단 분리#549

Open
manNomi wants to merge 3 commits into
mainfrom
fix/community-local-user-block
Open

feat: 커뮤니티 사용자 차단 분리#549
manNomi wants to merge 3 commits into
mainfrom
fix/community-local-user-block

Conversation

@manNomi
Copy link
Copy Markdown
Contributor

@manNomi manNomi commented Jun 3, 2026

관련 이슈

  • 없음

작업 내용

  • 커뮤니티 신고 흐름에서 사용자 차단을 분리했습니다.
  • 게시글 상세 더보기 메뉴에 별도 차단하기 액션을 추가했습니다.
  • 댓글 더보기 메뉴에서 본인이 아닌 댓글 작성자를 차단하기 할 수 있도록 추가했습니다.
  • 차단한 사용자의 게시글/댓글을 커뮤니티 화면에서 숨기도록 했습니다.
  • 차단된 작성자의 게시글 상세에 접근하면 기존 목록으로 이동하도록 기존 상세 가드와 연결했습니다.

특이 사항

  • 백엔드 댓글 차단 API가 별도로 추가되기 전까지도 프론트에서는 사용자 차단 상태를 기준으로 해당 사용자의 댓글을 숨깁니다.
  • 현재 구현은 기존 사용자 차단 API(/users/block/{blockedId})를 호출합니다.
  • 검증 시 Node 버전 경고가 발생했습니다. 프로젝트 요구 버전은 22.x, 현재 로컬은 23.10.0입니다.

리뷰 요구사항 (선택)

  • 신고만 했을 때 사용자가 자동 차단되지 않는지 확인 부탁드립니다.
  • 게시글/댓글에서 각각 차단하기 후 해당 작성자의 콘텐츠가 즉시 보이지 않는지 확인 부탁드립니다.
  • 댓글 차단 백엔드 API가 별도로 생길 경우 현재 훅의 API 호출부를 교체할 수 있을지 확인 부탁드립니다.

검증

  • pnpm --filter @solid-connect/web run lint:check
  • pnpm --filter @solid-connect/web run typecheck:ci

@manNomi manNomi requested review from enunsnv and wibaek as code owners June 3, 2026 07:33
@vercel
Copy link
Copy Markdown

vercel Bot commented Jun 3, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
solid-connect-university-web Error Error Jun 3, 2026 7:50am
solid-connection-web Ready Ready Preview, Comment Jun 3, 2026 7:50am
1 Skipped Deployment
Project Deployment Actions Updated (UTC)
solid-connect-web-admin Skipped Skipped Jun 3, 2026 7:50am

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Jun 3, 2026

Warning

Review limit reached

@manNomi, we couldn't start this review because you've reached your PR review rate limit.

More reviews will be available in 22 minutes and 3 seconds. Learn how PR review limits work.

Your organization has run out of usage credits. Purchase more in the billing tab.

⌛ How to resolve this issue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans include higher PR review limits than trial, open-source, and free plans. In all cases, reviews become available again over time. During sustained high-volume PR review activity, CodeRabbit may temporarily slow when the next review becomes available.

Please see our Fair Usage Limits Policy for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

Run ID: b2ab2518-c8a3-4458-8798-901fabc5277d

📥 Commits

Reviewing files that changed from the base of the PR and between 74e9152 and a59b099.

📒 Files selected for processing (9)
  • apps/web/src/app/community/[boardCode]/CommunityPageContent.tsx
  • apps/web/src/app/community/[boardCode]/[postId]/CommentSection.tsx
  • apps/web/src/app/community/[boardCode]/[postId]/KebabMenu.tsx
  • apps/web/src/app/community/[boardCode]/[postId]/PostPageContent.tsx
  • apps/web/src/app/community/_hooks/useBlockCommunityUser.ts
  • apps/web/src/components/ui/ReportPanel/_hooks/useSelectReportHandler.ts
  • apps/web/src/components/ui/ReportPanel/index.tsx
  • apps/web/src/lib/zustand/useReportedPostsStore.ts
  • apps/web/src/types/community.ts
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/community-local-user-block

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 990e2364b0

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +43 to 45
const authorId = post.postFindSiteUserResponse?.id;

if (typeof authorId === "number" && blockedUserIdSet.has(authorId)) {
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Require author IDs before relying on block filters

When the /boards/{boardCode} list payload does not include postFindSiteUserResponse (the repository’s current board-list shape in apps/web/src/apis/community/api.ts only defines id/title/content/counts/category/thumbnail for this endpoint), authorId is undefined and every blocked author’s post passes this filter. In that scenario, after blocking someone from a post detail the app routes back to the list but still renders that author’s posts, so the new local block feature only works on detail/comment data that has author IDs.

Useful? React with 👍 / 👎.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

반영했습니다. 목록 응답에 작성자 ID가 없을 때도 차단을 누른 현재 게시글은 다시 노출되지 않도록 blockedPostIds를 저장하고, 목록/상세 가드에서 함께 필터링하도록 보완했습니다.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant