[refactor] mutaton query 및 hook 추가 수정#221
Conversation
|
Caution Review failedThe pull request is closed. ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (18)
Walkthrough이 PR은 React Query 훅 계층을 재구성하고 import 경로를 정규화하는 광범위한 리팩토링입니다. 중앙화된 Possibly related PRs
🚥 Pre-merge checks | ✅ 2 | ❌ 2❌ Failed checks (2 inconclusive)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
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. Comment |
There was a problem hiding this comment.
Pull request overview
Thin query/mutation wrapper hooks are removed or relocated so call sites directly use *Queries / *Mutations option builders, and manager mutations are split by responsibility (club/application/member) to better match the page structure.
Changes:
- Replaced multiple “thin hooks” with direct
useQuery/useSuspenseQuery/useInfiniteQuerycalls usingauthQueries,clubQueries,scheduleQueries,notificationQueries,councilQueries. - Moved cache invalidation/update logic into
*Mutationsoption builders that accept aQueryClient, and introduced page-local mutation hooks for Manager/Chat/Notification usage. - Deleted obsolete wrapper hooks (auth/club/chat/notification + some page hooks) and updated imports across affected pages/components.
Reviewed changes
Copilot reviewed 42 out of 42 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| src/pages/User/Profile/index.tsx | Replaces useMyInfo with direct useSuspenseQuery(authQueries.myInfo()). |
| src/pages/User/Profile/hooks/useMyInfo.ts | Deletes thin hook wrapper around myInfo + update flow. |
| src/pages/User/MyPage/index.tsx | Uses authQueries.myInfo() directly via useSuspenseQuery. |
| src/pages/User/MyPage/components/UserInfoCard.tsx | Uses authQueries.myInfo() directly in multiple subcomponents. |
| src/pages/Schedule/index.tsx | Inlines monthly schedule query; adjusts bottom-sheet overlay classes. |
| src/pages/Schedule/hooks/useGetSchedules.ts | Deletes thin query wrapper for schedule list. |
| src/pages/Schedule/components/ScheduleDetail.tsx | Inlines monthly schedule query for detail view. |
| src/pages/Notifications/index.tsx | Uses useInfiniteQuery(notificationQueries.inboxInfinite()) and new mutation hook import. |
| src/pages/Manager/hooks/useManagedMemberMutations.ts | New page-local hooks wrapping managed member mutations. |
| src/pages/Manager/hooks/useManagedClubMutations.ts | New page-local hooks wrapping managed club mutations. |
| src/pages/Manager/hooks/useManagedApplicationMutations.ts | New page-local hooks wrapping managed application mutations. |
| src/pages/Manager/ManagedRecruitmentWrite/index.tsx | Updates imports to new Manager hooks location. |
| src/pages/Manager/ManagedRecruitmentForm/index.tsx | Updates imports to new Manager hooks location. |
| src/pages/Manager/ManagedMemberList/index.tsx | Updates imports to new Manager member mutation hooks. |
| src/pages/Manager/ManagedClubProfile/index.tsx | Updates imports to new Manager club mutation hooks. |
| src/pages/Manager/ManagedApplicationList/index.tsx | Updates imports to new Manager application mutation hooks. |
| src/pages/Manager/ManagedApplicationDetail/index.tsx | Updates imports to new Manager application mutation hooks. |
| src/pages/Manager/ManagedAccount/index.tsx | Updates imports to new Manager club mutation hooks. |
| src/pages/Home/hooks/useGetHomeClubs.ts | Removes recruiting-clubs thin hook wrapper export. |
| src/pages/Home/components/HomeClubSection.tsx | Inlines recruiting clubs infinite query using clubQueries.infiniteList. |
| src/pages/Council/CouncilDetail/components/CouncilNotice.tsx | Inlines council notices infinite query using councilQueries. |
| src/pages/Club/ClubSearch/index.tsx | Inlines clubs infinite query using clubQueries.infiniteList. |
| src/pages/Club/ClubList/index.tsx | Inlines clubs infinite query using clubQueries.infiniteList. |
| src/pages/Club/ClubList/hooks/useGetClubs.ts | Deletes thin infinite-query wrapper for clubs list/search. |
| src/pages/Club/ClubDetail/hooks/useCouncilNotices.ts | Deletes thin infinite-query wrapper for council notices. |
| src/pages/Club/Application/hooks/useApplyToClub.ts | Switches to useMutation(clubMutations.apply(queryClient, clubId)). |
| src/pages/Chat/hooks/useChatMutations.ts | New page-local chat mutation hooks. |
| src/pages/Chat/hooks/useChat.ts | Switches imports to page-local chat mutation hooks; removes unused param on send mutation. |
| src/pages/Auth/SignUp/FinishStep.tsx | Replaces useMyInfo with direct useSuspenseQuery(authQueries.myInfo()). |
| src/components/notification/hooks/useInboxNotificationQueries.ts | Deletes query + mutation re-export wrappers (unread count / list / mark-as-read). |
| src/components/notification/hooks/useInboxNotificationMutations.ts | New mutation hook wrapping notificationMutations with QueryClient. |
| src/components/notification/InboxNotificationLayer.tsx | Updates import to new notification mutation hook. |
| src/components/layout/Header/components/NotificationBell.tsx | Inlines unread-count query with auth-gated useQuery(notificationQueries.inboxUnreadCount()). |
| src/apis/notification/mutations.ts | Moves cache updates into mutation options; requires QueryClient param. |
| src/apis/notification/hooks.ts | Deletes old mutation hook implementation (logic moved into mutations + component hook). |
| src/apis/club/mutations.ts | Adds QueryClient param and invalidation on apply success. |
| src/apis/club/managedMutations.ts | Adds QueryClient param; centralizes invalidate/setQueryData behavior in options. |
| src/apis/club/managedHooks.ts | Deletes old managed hooks (now page-local hooks wrap the new mutation options). |
| src/apis/club/hooks.ts | Deletes old club hooks wrapper (apply). |
| src/apis/chat/mutations.ts | Adds QueryClient param and invalidations in chat mutation options. |
| src/apis/chat/hooks.ts | Deletes old chat hooks wrapper (now page-local hooks wrap mutation options). |
| src/apis/auth/hooks.ts | Deletes old auth hook wrapper (update my info). |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
✅ Actions performedReview triggered.
|
There was a problem hiding this comment.
Actionable comments posted: 6
🧹 Nitpick comments (8)
src/pages/Auth/SignUp/FinishStep.tsx (1)
15-18:handleStart내부의 null 체크가 불필요합니다.Line 11-13에서 이미
!myInfo일 때null을 반환하므로,handleStart함수가 호출되는 시점에는myInfo가 항상 존재합니다.♻️ 제안된 수정
const handleStart = () => { - if (!myInfo) { - return; - } - setUser(myInfo); navigate('/guide'); };🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@src/pages/Auth/SignUp/FinishStep.tsx` around lines 15 - 18, The internal null check inside handleStart is redundant because the component already returns null when myInfo is falsy, so remove the if (!myInfo) return; guard from handleStart and assume myInfo is defined there (or add a non-null assertion when accessing myInfo). Update handleStart to directly use myInfo and any dependent calls without the extra early return to eliminate dead code.src/pages/User/MyPage/components/UserInfoCard.tsx (1)
17-17: 동일한 쿼리가 3곳에서 호출됩니다.
ManagerDetailInfoCard,ManagerStats,UserInfoCard에서 각각authQueries.myInfo()를 호출합니다. React Query가 중복 호출을 자동으로 처리하므로 기능적으로는 문제없지만,myInfo를UserInfoCard에서 한 번 조회 후 props로 전달하면 코드 가독성이 향상될 수 있습니다.Also applies to: 54-54, 76-76
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@src/pages/User/MyPage/components/UserInfoCard.tsx` at line 17, Fetch authQueries.myInfo() once in the parent (e.g., the MyPage container) using useSuspenseQuery and pass the resulting myInfo down as a prop to UserInfoCard, ManagerDetailInfoCard, and ManagerStats instead of calling useSuspenseQuery(authQueries.myInfo()) inside each component; remove the duplicate useSuspenseQuery calls from the three child components, update their props/interfaces to accept the myInfo object (and adjust any usages accordingly), and keep the single source of truth in the parent to improve readability and avoid redundant queries.src/apis/club/mutations.ts (1)
2-4: 상대 경로 import를@/*alias로 통일하고 정렬 순서를 맞춰주세요.변경 구간에 상대 경로(
./queries,./entity,.)가 섞여 있어 현재 import 컨벤션과 충돌합니다.변경 제안
-import { clubQueryKeys } from './queries'; -import type { ClubApplyRequest } from './entity'; -import { applyClub } from '.'; +import { applyClub } from '@/apis/club'; +import type { ClubApplyRequest } from '@/apis/club/entity'; +import { clubQueryKeys } from '@/apis/club/queries';As per coding guidelines
**/*.{ts,tsx}: "Use@/*alias for import paths instead of relative paths" and "Sort imports according to eslint import/order ... with alphabetical ordering within groups".🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@src/apis/club/mutations.ts` around lines 2 - 4, Replace the relative imports in this file with the project alias and reorder them: import clubQueryKeys, ClubApplyRequest, and applyClub using the "@/..." path alias instead of './queries', './entity', and '.' respectively, and then sort the import statements according to eslint import/order (grouping and alphabetical order within groups) so symbols like clubQueryKeys, ClubApplyRequest, and applyClub appear in the proper alphabetical order.src/apis/club/managedMutations.ts (1)
48-186: 캐시 후처리는src/apis밖으로 빼는 편이 좋겠습니다.Line 48 이후처럼
QueryClient를 받아invalidateQueries/setQueryData까지 수행하면 API 레이어가 React Query에 결합됩니다. 이 파일은 mutation factory까지만 두고, 캐시 갱신은src/pages/Manager/hooks/*에서 조합하는 쪽이 현재 계층 규칙에 더 맞습니다.As per coding guidelines,
src/apis/**: API 레이어 컨벤션을 확인해주세요: - 비즈니스 로직이나 React 훅 의존성이 섞이지 않았는지🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@src/apis/club/managedMutations.ts` around lines 48 - 186, The API layer (functions like updateInfo, updateFee, upsertRecruitment, updateQuestions, patchSettings, approveApplication, rejectApplication, transferPresident, changeVicePresident, changeMemberPosition, removeMember, addPreMember, deletePreMember in managedMutations.ts) is directly manipulating React Query via a QueryClient and onSuccess cache ops; remove this coupling by eliminating the QueryClient parameter and any queryClient.invalidateQueries()/setQueryData() calls from these mutation factories (they should only provide mutationKey, mutationFn via mutationOptions). Move all cache-invalidating/onSuccess side-effects into the UI layer hooks (e.g., src/pages/Manager/hooks/*) where you call these mutations; there, use the QueryClient to run invalidateQueries/setQueryData using the existing keys (managedClubQueryKeys, clubQueryKeys, managedClubMutationKeys) after successful mutation. Ensure mutationOptions usage remains but without onSuccess that references QueryClient.src/pages/Schedule/components/ScheduleDetail.tsx (2)
16-19: 부모 컴포넌트와 동일한 쿼리 호출
Schedule/index.tsx와 동일한scheduleQueries.monthly({ year, month })쿼리를 호출합니다. React Query가 자동으로 중복 요청을 제거하므로 문제는 없지만, props로 데이터를 전달받는 방식도 고려해볼 수 있습니다.🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@src/pages/Schedule/components/ScheduleDetail.tsx` around lines 16 - 19, ScheduleDetail currently calls useQuery with scheduleQueries.monthly({ year, month }) duplicating the parent Schedule/index.tsx request; instead accept the already-fetched data via props (e.g., add a prop like monthlyData) and stop calling useQuery inside ScheduleDetail, or add a conditional to only call useQuery when props.monthlyData is undefined; update the ScheduleDetail component signature to accept the prop and use props.monthlyData where the local data variable is used, and remove or guard the useQuery call referencing scheduleQueries.monthly and useQuery.
8-13: 타입명 PascalCase 권장TypeScript 컨벤션상 타입/인터페이스는 PascalCase를 사용합니다.
-type scheduleDetailProps = { +type ScheduleDetailProps = { year: number; month: number; day: number; onItemClick?: () => void; }; -function ScheduleDetail({ year, month, day, onItemClick }: scheduleDetailProps) { +function ScheduleDetail({ year, month, day, onItemClick }: ScheduleDetailProps) {🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@src/pages/Schedule/components/ScheduleDetail.tsx` around lines 8 - 13, The type alias scheduleDetailProps uses camelCase but should follow TypeScript convention and be renamed to PascalCase; rename scheduleDetailProps to ScheduleDetailProps and update all references/usages (props declarations, component generic types, prop destructuring, imports/exports) such that the type name is consistently replaced; ensure any exported types and React component prop annotations (e.g., function/component signatures that previously referenced scheduleDetailProps) are updated accordingly to avoid type errors.src/pages/Schedule/index.tsx (1)
31-34:enabled조건 검토 필요
Boolean(year && month)는year나month가0일 때false가 됩니다. 현재 로직상 URL 파라미터에서 기본값을 설정하므로 문제없지만, 방어적으로undefined체크가 더 명확할 수 있습니다.- enabled: Boolean(year && month), + enabled: year !== undefined && month !== undefined,🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@src/pages/Schedule/index.tsx` around lines 31 - 34, The current enabled expression in useQuery (used with scheduleQueries.monthly) uses Boolean(year && month) which will incorrectly disable the query when year or month === 0; change the guard to explicitly check for defined values (e.g., year !== undefined && month !== undefined or typeof year !== 'undefined' && typeof month !== 'undefined') so the query runs for valid zero values while still preventing execution when params are missing.src/apis/notification/mutations.ts (1)
2-4: 변경된 import는@/alias로 맞춰주세요.이 변경분만 상대 경로가 남아 있으면 같은 도메인 파일에서도 규칙이 다시 섞입니다.
@/apis/notification/...형태로 통일하는 편이 좋습니다.As per coding guidelines, `**/*.{ts,tsx}`: Use path alias `@/*` for imports instead of relative paths.예시 수정
-import { decrementInboxUnreadCount, setInboxNotificationReadState } from './cache'; -import { notificationQueryKeys } from './queries'; -import type { InboxNotificationListResponse, InboxNotificationUnreadCountResponse } from './entity'; +import { decrementInboxUnreadCount, setInboxNotificationReadState } from '@/apis/notification/cache'; +import type { InboxNotificationListResponse, InboxNotificationUnreadCountResponse } from '@/apis/notification/entity'; +import { notificationQueryKeys } from '@/apis/notification/queries';🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@src/apis/notification/mutations.ts` around lines 2 - 4, Update the imports at the top of mutations.ts to use the project path alias instead of relative paths: replace the relative import for decrementInboxUnreadCount and setInboxNotificationReadState with "@/apis/notification/cache", replace notificationQueryKeys with "@/apis/notification/queries", and replace the entity types InboxNotificationListResponse and InboxNotificationUnreadCountResponse with "@/apis/notification/entity" so all notification-related imports use the "@/..." alias consistently.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@src/apis/chat/mutations.ts`:
- Around line 2-3: Update the two imports to use the project path alias instead
of relative paths: replace the module paths that import chatQueryKeys and
SendChatMessageRequest so they use the alias pattern starting with "@/..."
(e.g., import { chatQueryKeys } from '@/apis/chat/queries' and import type {
SendChatMessageRequest } from '@/apis/chat/entity') ensuring the symbol names
(chatQueryKeys, SendChatMessageRequest) remain unchanged and imports still
resolve correctly.
In `@src/apis/club/managedMutations.ts`:
- Around line 2-3: Replace the relative imports in managedMutations.ts with the
project path alias: change the import statements that reference
'./managedQueries' and './queries' to use the '@/...' alias so that
managedClubQueryKeys and clubQueryKeys are imported via
'@/apis/club/managedQueries' and '@/apis/club/queries' (or the correct alias
paths used in the project); ensure the imported identifiers managedClubQueryKeys
and clubQueryKeys remain unchanged.
In `@src/apis/notification/mutations.ts`:
- Around line 7-10: The MarkInboxNotificationAsReadVariables interface exposes
isRead which causes cache desyncs because callers pass the mutation-time value;
remove isRead from MarkInboxNotificationAsReadVariables and update the mutation
handlers (the mark-as-read mutation and any update logic around the
notificationId) to compute whether to decrement unread count by checking the
current cache or the mutation response state for the notification's previous
isRead value instead of trusting the passed isRead; update any callers to stop
supplying isRead and ensure the optimistic/update routines use the cache lookup
(by notificationId) or server response to decide whether to decrement the unread
counter (also apply the same change pattern to the similar code block referenced
at lines 22-35).
In `@src/pages/Chat/hooks/useChat.ts`:
- Line 4: Replace the relative import of useCreateChatRoomMutation,
useSendChatMessageMutation, and useToggleChatMuteMutation (currently imported
from './useChatMutations') with the project alias import using the `@/` prefix
(i.e., import those symbols from the same module path but using the @ alias
instead of a relative './' path) so the import follows the repository's alias
convention.
In `@src/pages/Club/ClubSearch/index.tsx`:
- Around line 32-35: The UI shows "0 clubs / no results" before the first search
response because the component only checks data; update the useInfiniteQuery
call to also destructure the initial-loading flag (isLoading or isFetching) and
in the render path branch off when that flag is true so you render a loading
skeleton/spinner instead of the empty-results UI; specifically adjust the
component using useInfiniteQuery (and the variables data, fetchNextPage,
hasNextPage, isFetchingNextPage) returned from clubQueries.infiniteList({ limit:
10, query: debouncedQuery || undefined, isRecruiting: false }) to check
isLoading (or isFetching when appropriate) and only show the "총 0개의 동아리 / 검색 결과
없음" UI when loading is false and data shows no items.
In `@src/pages/Schedule/index.tsx`:
- Around line 137-142: The Tailwind classes "z-31" and "z-32" are invalid;
update the overlay and sheet className usages (the element with className using
isSheetExpanded and the <section> element for the sheet) to use valid z-index
values—either replace "z-31" and "z-32" with Tailwind arbitrary value syntax
("z-[31]" and "z-[32]") or add those values to your Tailwind theme's zIndex
scale in the `@theme` block; ensure the overlay click handler (setIsSheetExpanded)
and transition classes remain unchanged.
---
Nitpick comments:
In `@src/apis/club/managedMutations.ts`:
- Around line 48-186: The API layer (functions like updateInfo, updateFee,
upsertRecruitment, updateQuestions, patchSettings, approveApplication,
rejectApplication, transferPresident, changeVicePresident, changeMemberPosition,
removeMember, addPreMember, deletePreMember in managedMutations.ts) is directly
manipulating React Query via a QueryClient and onSuccess cache ops; remove this
coupling by eliminating the QueryClient parameter and any
queryClient.invalidateQueries()/setQueryData() calls from these mutation
factories (they should only provide mutationKey, mutationFn via
mutationOptions). Move all cache-invalidating/onSuccess side-effects into the UI
layer hooks (e.g., src/pages/Manager/hooks/*) where you call these mutations;
there, use the QueryClient to run invalidateQueries/setQueryData using the
existing keys (managedClubQueryKeys, clubQueryKeys, managedClubMutationKeys)
after successful mutation. Ensure mutationOptions usage remains but without
onSuccess that references QueryClient.
In `@src/apis/club/mutations.ts`:
- Around line 2-4: Replace the relative imports in this file with the project
alias and reorder them: import clubQueryKeys, ClubApplyRequest, and applyClub
using the "@/..." path alias instead of './queries', './entity', and '.'
respectively, and then sort the import statements according to eslint
import/order (grouping and alphabetical order within groups) so symbols like
clubQueryKeys, ClubApplyRequest, and applyClub appear in the proper alphabetical
order.
In `@src/apis/notification/mutations.ts`:
- Around line 2-4: Update the imports at the top of mutations.ts to use the
project path alias instead of relative paths: replace the relative import for
decrementInboxUnreadCount and setInboxNotificationReadState with
"@/apis/notification/cache", replace notificationQueryKeys with
"@/apis/notification/queries", and replace the entity types
InboxNotificationListResponse and InboxNotificationUnreadCountResponse with
"@/apis/notification/entity" so all notification-related imports use the "@/..."
alias consistently.
In `@src/pages/Auth/SignUp/FinishStep.tsx`:
- Around line 15-18: The internal null check inside handleStart is redundant
because the component already returns null when myInfo is falsy, so remove the
if (!myInfo) return; guard from handleStart and assume myInfo is defined there
(or add a non-null assertion when accessing myInfo). Update handleStart to
directly use myInfo and any dependent calls without the extra early return to
eliminate dead code.
In `@src/pages/Schedule/components/ScheduleDetail.tsx`:
- Around line 16-19: ScheduleDetail currently calls useQuery with
scheduleQueries.monthly({ year, month }) duplicating the parent
Schedule/index.tsx request; instead accept the already-fetched data via props
(e.g., add a prop like monthlyData) and stop calling useQuery inside
ScheduleDetail, or add a conditional to only call useQuery when
props.monthlyData is undefined; update the ScheduleDetail component signature to
accept the prop and use props.monthlyData where the local data variable is used,
and remove or guard the useQuery call referencing scheduleQueries.monthly and
useQuery.
- Around line 8-13: The type alias scheduleDetailProps uses camelCase but should
follow TypeScript convention and be renamed to PascalCase; rename
scheduleDetailProps to ScheduleDetailProps and update all references/usages
(props declarations, component generic types, prop destructuring,
imports/exports) such that the type name is consistently replaced; ensure any
exported types and React component prop annotations (e.g., function/component
signatures that previously referenced scheduleDetailProps) are updated
accordingly to avoid type errors.
In `@src/pages/Schedule/index.tsx`:
- Around line 31-34: The current enabled expression in useQuery (used with
scheduleQueries.monthly) uses Boolean(year && month) which will incorrectly
disable the query when year or month === 0; change the guard to explicitly check
for defined values (e.g., year !== undefined && month !== undefined or typeof
year !== 'undefined' && typeof month !== 'undefined') so the query runs for
valid zero values while still preventing execution when params are missing.
In `@src/pages/User/MyPage/components/UserInfoCard.tsx`:
- Line 17: Fetch authQueries.myInfo() once in the parent (e.g., the MyPage
container) using useSuspenseQuery and pass the resulting myInfo down as a prop
to UserInfoCard, ManagerDetailInfoCard, and ManagerStats instead of calling
useSuspenseQuery(authQueries.myInfo()) inside each component; remove the
duplicate useSuspenseQuery calls from the three child components, update their
props/interfaces to accept the myInfo object (and adjust any usages
accordingly), and keep the single source of truth in the parent to improve
readability and avoid redundant queries.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
Run ID: df948a85-f502-437b-ad35-173831943b5b
📒 Files selected for processing (42)
src/apis/auth/hooks.tssrc/apis/chat/hooks.tssrc/apis/chat/mutations.tssrc/apis/club/hooks.tssrc/apis/club/managedHooks.tssrc/apis/club/managedMutations.tssrc/apis/club/mutations.tssrc/apis/notification/hooks.tssrc/apis/notification/mutations.tssrc/components/layout/Header/components/NotificationBell.tsxsrc/components/notification/InboxNotificationLayer.tsxsrc/components/notification/hooks/useInboxNotificationMutations.tssrc/components/notification/hooks/useInboxNotificationQueries.tssrc/pages/Auth/SignUp/FinishStep.tsxsrc/pages/Chat/hooks/useChat.tssrc/pages/Chat/hooks/useChatMutations.tssrc/pages/Club/Application/hooks/useApplyToClub.tssrc/pages/Club/ClubDetail/hooks/useCouncilNotices.tssrc/pages/Club/ClubList/hooks/useGetClubs.tssrc/pages/Club/ClubList/index.tsxsrc/pages/Club/ClubSearch/index.tsxsrc/pages/Council/CouncilDetail/components/CouncilNotice.tsxsrc/pages/Home/components/HomeClubSection.tsxsrc/pages/Home/hooks/useGetHomeClubs.tssrc/pages/Manager/ManagedAccount/index.tsxsrc/pages/Manager/ManagedApplicationDetail/index.tsxsrc/pages/Manager/ManagedApplicationList/index.tsxsrc/pages/Manager/ManagedClubProfile/index.tsxsrc/pages/Manager/ManagedMemberList/index.tsxsrc/pages/Manager/ManagedRecruitmentForm/index.tsxsrc/pages/Manager/ManagedRecruitmentWrite/index.tsxsrc/pages/Manager/hooks/useManagedApplicationMutations.tssrc/pages/Manager/hooks/useManagedClubMutations.tssrc/pages/Manager/hooks/useManagedMemberMutations.tssrc/pages/Notifications/index.tsxsrc/pages/Schedule/components/ScheduleDetail.tsxsrc/pages/Schedule/hooks/useGetSchedules.tssrc/pages/Schedule/index.tsxsrc/pages/User/MyPage/components/UserInfoCard.tsxsrc/pages/User/MyPage/index.tsxsrc/pages/User/Profile/hooks/useMyInfo.tssrc/pages/User/Profile/index.tsx
💤 Files with no reviewable changes (10)
- src/pages/Schedule/hooks/useGetSchedules.ts
- src/apis/club/hooks.ts
- src/pages/Club/ClubDetail/hooks/useCouncilNotices.ts
- src/apis/auth/hooks.ts
- src/apis/notification/hooks.ts
- src/pages/User/Profile/hooks/useMyInfo.ts
- src/pages/Club/ClubList/hooks/useGetClubs.ts
- src/components/notification/hooks/useInboxNotificationQueries.ts
- src/apis/chat/hooks.ts
- src/apis/club/managedHooks.ts
* 205 feat 이미지 전처리 기능 구현 (#206) * feat: 전처리 로직 및 WebWorker 구현 * feat: 전처리 적용 및 preview 동시성 제어 로직 추가 * refactor: 리뷰 반영 * [hotfix] 하단바 너비 수정 (#208) * hotfix: 하단바 너비 수정 * chore: 불필요한 값 제거 * refactor: 고정 gap 제거 * Reapply "[feat] 광고 배너 추가 (#200)" This reverts commit c51ec85. * [feat] 하단바 리디자인 (#213) * chore: asset 추가 * feat: 하단바 리디자인 반영 및 레이아웃 수정 * [refactor] 광고 카드 레이아웃 밀림 수정 (#215) * refactor: 광고 개수 측정 시기 변경 및 기본값 제거 * feat: 스켈레톤 UI 추가 * feat: 인앱 알림 페이지 및 토스트 구현 (#217) * feat: 알림 API 및 스트림 기반 추가 * feat: 인앱 알림 레이어 추가 * feat: 알림 페이지 및 헤더 진입 구현 * fix: 알림 스트림 401 재시도 조건 정리 * fix: 알림 목록 이동 차단 제거 * refactor: 알림 공용 훅 위치 정리 * fix: 알림 재연결 캐시 동기화 추가 * fix: 알림 목록 토스트 큐 누적 방지 * fix: 알림 읽음 카운트 감소 조건 보강 * [refactor] 도메인별 TanStack Query 훅 정리 (#219) * chore: pwa용 이미지 제거 * refactor: auth 도메인 쿼리와 뮤테이션 정리 * refactor: council과 schedule 조회 훅 정리 * refactor: chat과 notification 캐시 처리 정리 * refactor: club 조회와 지원 플로우 정리 * refactor: manager 도메인 캐시 처리 정리 * refactor: studyTime 도메인 쿼리와 뮤테이션 정리 * refactor: 광고와 업로드 도메인 훅 정리 * [refactor] mutaton query 및 hook 추가 수정 (#221) * refactor: auth와 user myInfo 훅 정리 * refactor: club과 schedule 조회 훅 정리 * refactor: chat과 notification 훅 구조 정리 * refactor: club 지원 뮤테이션 훅 정리 * refactor: manager 뮤테이션 훅 구조 정리 * refactor: mutation 훅 cache 정리 * refactor: 컨벤션 통일 * refactor: isRead 조건 정리 * fix: 채팅 스크롤 문제 수정 * refactor: 불필요한 코드 제거 * [fix] 모바일 환경 입력창과 키보드 간의 간격이 큰 문제 수정 (#223) * chore: 가공용 safeArea 변수 선언 * refactor: 고정 패딩 값 수정 및 safeArea 적용 변경 * feat: 키보드 활성화 감지 및 safeArea 적용 여부 기능 추가 * refactor: 매직넘버 상수화 및 가로모드 처리 * [fix] 키보드 활성화 시 화면 흔들림 문제 수정 (#225) * refactor: 채팅 viewport 훅 네이밍 정리 * refactor: viewport 높이 잠금 훅 적용 시점 조정 * [fix] 키보드 활성화 시 채팅 화면 전체가 흔들리는 문제 수정 (#227) * refactor: 채팅 viewport 훅 네이밍 정리 * refactor: viewport 높이 잠금 훅 적용 시점 조정 * fix: 채팅 화면 스크롤 잠금으로 키보드 흔들림 완화 * fix: 입력 포커스 중 viewport offset 고정 (#229) * fix: 문서 루트 스크롤 잠금으로 빈 공간 잔류 방지 (#232) * [fix] 키보드 활성화 시 채팅 화면 상단 고정이 깨지고 빈 공간이 남는 문제 수정 (#234) * fix: 채팅 화면 상단 고정 깨짐과 빈 공간 잔류 수정 * refactor: 라우트 조건 수정 * fix: 문서 스크롤 위치 감지 보강 * refactor: 입력 요소 판별 유틸과 스크롤 주석 정리 * [fix] 키보드 활성화 시 채팅 화면에서 문서 스크롤이 발생하는 문제 수정 (#236) * fix: 채팅 문서 스크롤 제스처 차단 * fix: 입력 요소 터치 동작 예외 처리 * [fix] 키보드 활성화 시 채팅방이 마지막 메시지 위치를 유지하지 못하는 문제 수정 (#238) * fix: 키보드 활성화 시 채팅 하단 정렬 유지 * refactor: 채팅 리사이즈 관찰 안정화 * fix: mypage 연계 약관 페이지 뒤로가기 수정 (#240) * refactor: alias import 경로 정리 * fix: query 설정과 suspense 분기 정리 * refactor: 관리자 화면 스타일 유틸 정리 * fix: 이미지 전처리 예외 처리 보강 * fix: 헤더와 회비 화면 동작 정리 * fix: 공통 유틸 안정성 개선 * fix: 이미지 전처리 실패 처리를 보정 * fix: 모집 공고 저장 후 설정 반영 순서 조정 * fix: 부원 직책 변경 실패 처리를 보강 * fix: 약관 링크 접근성을 개선 * fix: 공통 쿼리와 유틸 안정성을 보완 * [feat] 동적 버전 정보 표시 구현 (#211) * feat: 동적 버전 정보 표시 구현 * refactor: 버전 정보 미 존재시 v 표시 제거 * [feat] 메인화면 동아리 카드 디자인 수정 반영 (#242) * feat: 메인화면 동아리 카드 디자인 수정 * chore: 하단바 아이콘 수정 * refactor: 코드래빗 리뷰 반영 * refactor: and 연산자로 변경 * apiClient 코드 중복 제거 및 네이티브 브릿지 인증 동기화 중앙화 (#244) * refactor: apiClient 코드 중복 제거 및 네이티브 브릿지 인증 동기화 중앙화 * refactor: body 직렬화 가드를 plain object/array로 한정 * fix: body 읽기 중 AbortError가 ParseError로 오분류되는 문제 수정 * [refactor] 에러 처리 유틸 및 utils 구조 정리 (#246) * refactor: 에러 처리 유틸 및 공통 토스트 흐름 정리 * refactor: utils 폴더 구조를 역할별로 정리 * refactor: 코드래빗 리뷰 반영 * refactor: 코드래빗 리뷰 반영 * Update src/pages/Home/components/HomeClubSection.tsx * fix: 인증 세션 복구 흐름 정리 * fix: 홈 동아리 카드 레이아웃 정리 * [feat] 총동아리 페이지 리디자인 및 하단 오버레이 정리 (#249) * refactor: 하단 오버레이 처리 공통화 * feat: 총동아리 페이지와 헤더 리디자인 반영 * fix: 채팅 하단 여백과 외부 링크 속성 수정 * refactor: 총동아리 헤더 설정 정리 * fix: 총동아리 상세 접근성과 스타일 보완 * [feat] 마이페이지 관리자 카드 분리 및 채팅 미확인 배지 반영 (#251) * feat: 하단 채팅 배지 표시 및 조회 조건 보완 * refactor: 관리자 정보 카드 컴포넌트 분리 * feat: 채팅 페이지 리디자인 (#252) * feat: 채팅 페이지 리디자인 * fix:tailwind 문법 수정 * fix: 코드 수정 * fix: 폰트 색상 및 위치 수정 * fix: 채팅방 사람수 정렬 * fix: 오타 수정 * chore: conflict 해결 중 누락된 부분 수정 * [refactor] 광고 렌더링 조건 수정 (#254) * refactor: 광고 렌더링 조건 수정 * docs: 문서명 변경 --------- Co-authored-by: 박성주 <145267904+ParkSungju01@users.noreply.github.com>
* [배포] 이미지 전처리, 광고 기능, 하단바 리디자인, 인앱 알림 페이지 및 토스트 프로덕션 배포 (#230) * 205 feat 이미지 전처리 기능 구현 (#206) * feat: 전처리 로직 및 WebWorker 구현 * feat: 전처리 적용 및 preview 동시성 제어 로직 추가 * refactor: 리뷰 반영 * [hotfix] 하단바 너비 수정 (#208) * hotfix: 하단바 너비 수정 * chore: 불필요한 값 제거 * refactor: 고정 gap 제거 * Reapply "[feat] 광고 배너 추가 (#200)" This reverts commit c51ec85. * [feat] 하단바 리디자인 (#213) * chore: asset 추가 * feat: 하단바 리디자인 반영 및 레이아웃 수정 * [refactor] 광고 카드 레이아웃 밀림 수정 (#215) * refactor: 광고 개수 측정 시기 변경 및 기본값 제거 * feat: 스켈레톤 UI 추가 * feat: 인앱 알림 페이지 및 토스트 구현 (#217) * feat: 알림 API 및 스트림 기반 추가 * feat: 인앱 알림 레이어 추가 * feat: 알림 페이지 및 헤더 진입 구현 * fix: 알림 스트림 401 재시도 조건 정리 * fix: 알림 목록 이동 차단 제거 * refactor: 알림 공용 훅 위치 정리 * fix: 알림 재연결 캐시 동기화 추가 * fix: 알림 목록 토스트 큐 누적 방지 * fix: 알림 읽음 카운트 감소 조건 보강 * [refactor] 도메인별 TanStack Query 훅 정리 (#219) * chore: pwa용 이미지 제거 * refactor: auth 도메인 쿼리와 뮤테이션 정리 * refactor: council과 schedule 조회 훅 정리 * refactor: chat과 notification 캐시 처리 정리 * refactor: club 조회와 지원 플로우 정리 * refactor: manager 도메인 캐시 처리 정리 * refactor: studyTime 도메인 쿼리와 뮤테이션 정리 * refactor: 광고와 업로드 도메인 훅 정리 * [refactor] mutaton query 및 hook 추가 수정 (#221) * refactor: auth와 user myInfo 훅 정리 * refactor: club과 schedule 조회 훅 정리 * refactor: chat과 notification 훅 구조 정리 * refactor: club 지원 뮤테이션 훅 정리 * refactor: manager 뮤테이션 훅 구조 정리 * refactor: mutation 훅 cache 정리 * refactor: 컨벤션 통일 * refactor: isRead 조건 정리 * fix: 채팅 스크롤 문제 수정 * refactor: 불필요한 코드 제거 * [fix] 모바일 환경 입력창과 키보드 간의 간격이 큰 문제 수정 (#223) * chore: 가공용 safeArea 변수 선언 * refactor: 고정 패딩 값 수정 및 safeArea 적용 변경 * feat: 키보드 활성화 감지 및 safeArea 적용 여부 기능 추가 * refactor: 매직넘버 상수화 및 가로모드 처리 * [fix] 키보드 활성화 시 화면 흔들림 문제 수정 (#225) * refactor: 채팅 viewport 훅 네이밍 정리 * refactor: viewport 높이 잠금 훅 적용 시점 조정 * [fix] 키보드 활성화 시 채팅 화면 전체가 흔들리는 문제 수정 (#227) * refactor: 채팅 viewport 훅 네이밍 정리 * refactor: viewport 높이 잠금 훅 적용 시점 조정 * fix: 채팅 화면 스크롤 잠금으로 키보드 흔들림 완화 * fix: 입력 포커스 중 viewport offset 고정 (#229) * fix: 문서 루트 스크롤 잠금으로 빈 공간 잔류 방지 (#232) * [fix] 키보드 활성화 시 채팅 화면 상단 고정이 깨지고 빈 공간이 남는 문제 수정 (#234) * fix: 채팅 화면 상단 고정 깨짐과 빈 공간 잔류 수정 * refactor: 라우트 조건 수정 * fix: 문서 스크롤 위치 감지 보강 * refactor: 입력 요소 판별 유틸과 스크롤 주석 정리 * [fix] 키보드 활성화 시 채팅 화면에서 문서 스크롤이 발생하는 문제 수정 (#236) * fix: 채팅 문서 스크롤 제스처 차단 * fix: 입력 요소 터치 동작 예외 처리 * [fix] 키보드 활성화 시 채팅방이 마지막 메시지 위치를 유지하지 못하는 문제 수정 (#238) * fix: 키보드 활성화 시 채팅 하단 정렬 유지 * refactor: 채팅 리사이즈 관찰 안정화 * fix: mypage 연계 약관 페이지 뒤로가기 수정 (#240) * refactor: alias import 경로 정리 * fix: query 설정과 suspense 분기 정리 * refactor: 관리자 화면 스타일 유틸 정리 * fix: 이미지 전처리 예외 처리 보강 * fix: 헤더와 회비 화면 동작 정리 * fix: 공통 유틸 안정성 개선 * fix: 이미지 전처리 실패 처리를 보정 * fix: 모집 공고 저장 후 설정 반영 순서 조정 * fix: 부원 직책 변경 실패 처리를 보강 * fix: 약관 링크 접근성을 개선 * fix: 공통 쿼리와 유틸 안정성을 보완 * [feat] 동적 버전 정보 표시 구현 (#211) * feat: 동적 버전 정보 표시 구현 * refactor: 버전 정보 미 존재시 v 표시 제거 * [feat] 메인화면 동아리 카드 디자인 수정 반영 (#242) * feat: 메인화면 동아리 카드 디자인 수정 * chore: 하단바 아이콘 수정 * refactor: 코드래빗 리뷰 반영 * refactor: and 연산자로 변경 * apiClient 코드 중복 제거 및 네이티브 브릿지 인증 동기화 중앙화 (#244) * refactor: apiClient 코드 중복 제거 및 네이티브 브릿지 인증 동기화 중앙화 * refactor: body 직렬화 가드를 plain object/array로 한정 * fix: body 읽기 중 AbortError가 ParseError로 오분류되는 문제 수정 * [refactor] 에러 처리 유틸 및 utils 구조 정리 (#246) * refactor: 에러 처리 유틸 및 공통 토스트 흐름 정리 * refactor: utils 폴더 구조를 역할별로 정리 * refactor: 코드래빗 리뷰 반영 * refactor: 코드래빗 리뷰 반영 * Update src/pages/Home/components/HomeClubSection.tsx * fix: 인증 세션 복구 흐름 정리 * fix: 홈 동아리 카드 레이아웃 정리 * [feat] 총동아리 페이지 리디자인 및 하단 오버레이 정리 (#249) * refactor: 하단 오버레이 처리 공통화 * feat: 총동아리 페이지와 헤더 리디자인 반영 * fix: 채팅 하단 여백과 외부 링크 속성 수정 * refactor: 총동아리 헤더 설정 정리 * fix: 총동아리 상세 접근성과 스타일 보완 * [feat] 마이페이지 관리자 카드 분리 및 채팅 미확인 배지 반영 (#251) * feat: 하단 채팅 배지 표시 및 조회 조건 보완 * refactor: 관리자 정보 카드 컴포넌트 분리 * feat: 채팅 페이지 리디자인 (#252) * feat: 채팅 페이지 리디자인 * fix:tailwind 문법 수정 * fix: 코드 수정 * fix: 폰트 색상 및 위치 수정 * fix: 채팅방 사람수 정렬 * fix: 오타 수정 * chore: conflict 해결 중 누락된 부분 수정 * [refactor] 광고 렌더링 조건 수정 (#254) * refactor: 광고 렌더링 조건 수정 * docs: 문서명 변경 --------- Co-authored-by: 박성주 <145267904+ParkSungju01@users.noreply.github.com> * refactor: 가이드 페이지 이미지 변경 및 구조 개선 (#260) * hotfix: 가이드 이미지 경로 변경 --------- Co-authored-by: 박성주 <145267904+ParkSungju01@users.noreply.github.com>
✨ 요약
auth/user의myInfothin hook을 제거하고 사용처에서 직접authQueries.myInfo()를 사용하도록 정리했습니다.club/council/home/schedule의 thin query wrapper를 제거하고 사용처 인라인 호출로 정리했습니다.chat/notification의 mutation hook을 사용처 근처로 이동하고 알림 카운트 조회를 사용처에 인라인했습니다.managermutation hook을클럽,지원서,멤버책임 단위로 분리했습니다.club apply의 불필요한 한 단계 mutation hook을 제거했습니다.pnpm lint,pnpm build로 최종 검증했습니다.😎 해결한 이슈
close #220
Summary by CodeRabbit
릴리스 노트
버그 수정
리팩토링