-
Notifications
You must be signed in to change notification settings - Fork 0
관리자 문의답변 추가에 대한 마이페이지 알림 추가 수정( #issue 353 ) #356
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Changes from 6 commits
Commits
Show all changes
8 commits
Select commit
Hold shift + click to select a range
63126d0
refactor: 링크 URL을 상수로 변경하여 코드 일관성 향상, 활동기록 내 문의글 list item이 head 넘치는 …
YouD0313 ebba77f
fix: linkUrl 함수의 반환값 수정 및 필터 조건 개선
YouD0313 0af16c5
refactor: linkUrl 함수에서 replier 매개변수 제거 및 불필요한 console.log 삭제
YouD0313 4067f66
refactor: linkUrl 함수에서 주석 제거하여 코드 가독성 향상
YouD0313 cae7c46
Merge remote-tracking branch 'origin' into feat/#353
YouD0313 cf96e56
feat: MyInquiriesWrapper 추가 및 스크롤 기능 구현, Inquiry 컴포넌트 수정
YouD0313 8af79cb
fix: Inquiries 및 Inquiry 컴포넌트에서 상태 관리 최적화
YouD0313 af47d71
refactor: Inquiries 컴포넌트에서 불필요한 상태 제거 및 스타일 수정
YouD0313 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🛠️ Refactor suggestion
스크롤 로직 개선 필요
useLayoutEffect 구현에서 몇 가지 개선 사항이 있습니다:
headHeight제거로 무한 재렌더링 방지다음과 같이 수정하시기 바랍니다:
useLayoutEffect(() => { if (!id || !headRef?.current) return; const height = headRef.current.offsetHeight; setHeadHeight(height); - const idx = userActivityData?.findIndex((item) => item.id == id); - const targetRef = typeof idx === 'number' ? inquiriesRef.current[idx] : ''; + const idx = userActivityData?.findIndex((item) => item.id === id); + const targetRef = idx !== undefined && idx >= 0 ? inquiriesRef.current[idx] : null; if (inquiriesRef?.current && targetRef) { targetRef.scrollIntoView({ behavior: 'smooth', block: 'start' }); } - }, [userActivityData, id, headHeight]); + }, [userActivityData, id]);📝 Committable suggestion
🤖 Prompt for AI Agents