-
Notifications
You must be signed in to change notification settings - Fork 1
fix/140 3차 QA수정사항수정 #142
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
fix/140 3차 QA수정사항수정 #142
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -8,6 +8,7 @@ import { useQuery } from '@tanstack/react-query'; | |||||||||||||||||||||
| import { privateInstance } from '@/apis/privateInstance'; | ||||||||||||||||||||||
| import ReviewTitle from './ReviewTitle'; | ||||||||||||||||||||||
| import useUserStore from '@/stores/authStore'; | ||||||||||||||||||||||
| import cn from '@/lib/cn'; | ||||||||||||||||||||||
|
|
||||||||||||||||||||||
| import ReviewCardSkeleton from './Skeletons/ReviewCardSkeleton'; | ||||||||||||||||||||||
|
|
||||||||||||||||||||||
|
|
@@ -58,11 +59,7 @@ function ReviewSection({ | |||||||||||||||||||||
| key={review.id} | ||||||||||||||||||||||
| userName={review.user.nickname} | ||||||||||||||||||||||
| avatarSrc={review.user.profileImageUrl} | ||||||||||||||||||||||
| date={new Date(review.createdAt).toLocaleDateString('ko-KR', { | ||||||||||||||||||||||
| year: 'numeric', | ||||||||||||||||||||||
| month: '2-digit', | ||||||||||||||||||||||
| day: '2-digit', | ||||||||||||||||||||||
| })} | ||||||||||||||||||||||
| date={review.createdAt.slice(0, 10).replace(/-/g, '.')} | ||||||||||||||||||||||
| reviewText={review.content} | ||||||||||||||||||||||
| /> | ||||||||||||||||||||||
| )); | ||||||||||||||||||||||
|
|
@@ -71,7 +68,7 @@ function ReviewSection({ | |||||||||||||||||||||
| if (isLoading) { | ||||||||||||||||||||||
| return ( | ||||||||||||||||||||||
| <div className='mt-10 flex flex-col space-y-8'> | ||||||||||||||||||||||
| <div className='relative min-h-350 flex-col'> | ||||||||||||||||||||||
| <div className='relative min-h-300 flex-col'> | ||||||||||||||||||||||
| <ReviewTitle reviewCount={reviewCount} rating={rating} /> | ||||||||||||||||||||||
| {[...Array(3)].map((_, index) => ( | ||||||||||||||||||||||
| <ReviewCardSkeleton key={index} /> | ||||||||||||||||||||||
|
|
@@ -84,7 +81,7 @@ function ReviewSection({ | |||||||||||||||||||||
| if (!reviewData || reviewData.reviews.length === 0) { | ||||||||||||||||||||||
| return ( | ||||||||||||||||||||||
| <div className='mt-10 flex flex-col space-y-8'> | ||||||||||||||||||||||
| <div className='relative min-h-350'> | ||||||||||||||||||||||
| <div className='relative min-h-300'> | ||||||||||||||||||||||
| <ReviewTitle reviewCount={reviewCount} rating={rating} /> | ||||||||||||||||||||||
|
|
||||||||||||||||||||||
| <div className='pointer-events-none absolute inset-0 z-10 flex h-full items-center justify-center select-none'> | ||||||||||||||||||||||
|
|
@@ -107,8 +104,10 @@ function ReviewSection({ | |||||||||||||||||||||
| <div className='mt-10 flex flex-col space-y-8'> | ||||||||||||||||||||||
| <ReviewTitle reviewCount={reviewCount} rating={rating} /> | ||||||||||||||||||||||
|
|
||||||||||||||||||||||
| <div className='pointer-events-none relative min-h-350 select-none'> | ||||||||||||||||||||||
| <div className={user ? '' : 'blur-sm'}>{ReviewComponent()}</div> | ||||||||||||||||||||||
| <div className='pointer-events-none relative min-h-300 select-none'> | ||||||||||||||||||||||
| <div className={cn(user ? '' : 'blur-sm', 'mt-10')}> | ||||||||||||||||||||||
| {ReviewComponent()} | ||||||||||||||||||||||
| </div> | ||||||||||||||||||||||
|
Comment on lines
+107
to
+110
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. pointer-events-none 무조건 적용으로 상호작용 차단
- <div className='pointer-events-none relative min-h-300 select-none'>
+ <div
+ className={cn(!user && 'pointer-events-none select-none', 'relative min-h-300')}
+ >📝 Committable suggestion
Suggested change
🤖 Prompt for AI Agents |
||||||||||||||||||||||
|
|
||||||||||||||||||||||
| {!user && ( | ||||||||||||||||||||||
| <div className='pointer-events-none absolute inset-0 z-10 flex h-full items-center justify-center select-none'> | ||||||||||||||||||||||
|
|
||||||||||||||||||||||
| Original file line number | Diff line number | Diff line change | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -141,10 +141,29 @@ export const useEditActivityForm = () => { | |||||||||
| } | ||||||||||
|
|
||||||||||
| const newSchedules = dates.filter((d) => !d.id); | ||||||||||
|
|
||||||||||
| const scheduleIdsToRemove = originalSchedules | ||||||||||
| .filter((orig) => !dates.some((d) => d.id === orig.id)) | ||||||||||
| .map((d) => d.id) | ||||||||||
| .filter((id): id is number => id !== undefined); | ||||||||||
| .map((d) => d.id!) | ||||||||||
| .filter(Boolean); | ||||||||||
|
Comment on lines
+147
to
+148
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🛠️ Refactor suggestion 타입 안전성 개선 제안
다음과 같이 수정하세요: - .map((d) => d.id!)
- .filter(Boolean);
+ .map((d) => d.id)
+ .filter((id): id is number => id !== undefined);📝 Committable suggestion
Suggested change
🤖 Prompt for AI Agents |
||||||||||
|
|
||||||||||
| originalSchedules.forEach((orig) => { | ||||||||||
| const matched = dates.find((d) => d.id === orig.id); | ||||||||||
| if ( | ||||||||||
| matched && | ||||||||||
| (matched.date !== orig.date || | ||||||||||
| matched.startTime !== orig.startTime || | ||||||||||
| matched.endTime !== orig.endTime) | ||||||||||
| ) { | ||||||||||
| newSchedules.push({ | ||||||||||
| date: matched.date, | ||||||||||
| startTime: matched.startTime, | ||||||||||
| endTime: matched.endTime, | ||||||||||
| }); | ||||||||||
|
|
||||||||||
| scheduleIdsToRemove.push(orig.id!); | ||||||||||
| } | ||||||||||
| }); | ||||||||||
|
|
||||||||||
| const parsedPrice = parseInt(price, 10); | ||||||||||
| if (isNaN(parsedPrice) || parsedPrice <= 0) { | ||||||||||
|
|
||||||||||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -39,6 +39,7 @@ export function InfoSection({ | |
| placeholder='제목' | ||
| className='w-full' | ||
| value={title} | ||
| maxLength={20} | ||
| onChange={(e) => onTitleChange(e.target.value)} | ||
|
Comment on lines
+42
to
43
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 💡 Verification agent ❓ Verification inconclusive글자 수 제한 UX 보완 제안
글자 수 제한 UX 보완 필요 InfoSection.tsx (src/app/(with-header)/myactivity/components/InfoSection.tsx) 42–43행에서 maxLength={20}
onChange={(e) => onTitleChange(e.target.value)}현재 입력이 20자를 넘으면 조용히 막히기만 하므로, 아래를 검토해 주세요:
🤖 Prompt for AI Agents |
||
| /> | ||
| </div> | ||
|
|
||
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -45,7 +45,7 @@ export default function Button({ | |||||||||||||||||||||||||||||||
| )} | ||||||||||||||||||||||||||||||||
| {...props} | ||||||||||||||||||||||||||||||||
| > | ||||||||||||||||||||||||||||||||
| {isLoading ? <span className='animate-pulse'>로딩중...</span> : children} | ||||||||||||||||||||||||||||||||
| {isLoading ? <span className='animate-pulse'>...</span> : children} | ||||||||||||||||||||||||||||||||
| </button> | ||||||||||||||||||||||||||||||||
|
Comment on lines
+48
to
49
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🧹 Nitpick (assertive) 로딩 텍스트 접근성 개선 필요
- {isLoading ? <span className='animate-pulse'>...</span> : children}
+ {isLoading ? (
+ <span
+ className='animate-pulse'
+ aria-label='로딩 중'
+ role='status'
+ >
+ ...
+ <span className='sr-only'>로딩 중</span>
+ </span>
+ ) : (
+ children
+ )}📝 Committable suggestion
Suggested change
🤖 Prompt for AI Agents |
||||||||||||||||||||||||||||||||
| ); | ||||||||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||||||||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -31,7 +31,7 @@ export default function BookingButton({ | |
| {onBooking ? ( | ||
| <div className='flex items-center justify-center gap-2'> | ||
| <span className='h-10 w-10 animate-spin rounded-full border-2 border-white border-t-transparent' /> | ||
| <p>...</p> | ||
| <p>요청전송중...</p> | ||
| </div> | ||
|
Comment on lines
31
to
35
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🧹 Nitpick (assertive) 로딩 문구 일관성 유지 검토
🤖 Prompt for AI Agents |
||
| ) : ( | ||
| children | ||
|
|
||
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.
🧹 Nitpick (assertive)
날짜 포맷팅 방식 견고성 부족
slice(0, 10).replace(/-/g, '.')는 ISO-8601 형식이 아닐 경우 깨질 수 있습니다.dayjs,date-fns등의 라이브러리 사용을 권장합니다.🤖 Prompt for AI Agents