nextdealit/
├─ docs/
│ └─ [ai-guidelines.md](<http://ai-guidelines.md/>)
├─ src/
│ ├─ app/
│ │ ├─ (auth)/ # 인증/가입 플로우 그룹
│ │ │ ├─ login/
│ │ │ ├─ signup/
│ │ │ ├─ find-id/
│ │ │ ├─ find-password/
│ │ │ ├─ region-setup/
│ │ │ ├─ find-location/
│ │ │ ├─ phone-auth/
│ │ │ ├─ terms/
│ │ │ ├─ profile-setup/
│ │ │ └─ category-selection/
│ │ ├─ (main)/ # 앱 사용 후 메인 탭/마이페이지 그룹
│ │ │ ├─ layout.tsx
│ │ │ ├─ home/
│ │ │ ├─ search/
│ │ │ │ └─ detail/
│ │ │ ├─ notifications/
│ │ │ │ └─ settings/
│ │ │ ├─ wishlist/
│ │ │ └─ mypage/
│ │ │ ├─ account-management/
│ │ │ ├─ my-bids/
│ │ │ ├─ purchase-history/
│ │ │ ├─ sales-history/
│ │ │ ├─ sales-management/
│ │ │ └─ review/write/
│ │ ├─ products/ # 상품 일반거래 도메인
│ │ │ ├─ register/
│ │ │ └─ [productId]/
│ │ │ ├─ payment/
│ │ │ ├─ receipt/
│ │ │ ├─ regular-purchase/
│ │ │ └─ report/
│ │ ├─ auctions/ # 경매 도메인
│ │ │ ├─ register/
│ │ │ └─ [auctionId]/
│ │ │ ├─ bidding-status/
│ │ │ ├─ bid-complete/
│ │ │ ├─ outbid/
│ │ │ └─ winning-complete/
│ │ ├─ chats/
│ │ │ └─ [roomId]/
│ │ ├─ page.tsx
│ │ ├─ layout.tsx
│ │ ├─ not-found.tsx
│ │ └─ globals.css
│ ├─ components/
│ │ ├─ common/ # 공통 UI
│ │ │ ├─ bottom-navigation/TabButton.tsx
│ │ │ ├─ modal/ConfirmModal.tsx
│ │ │ └─ ExploreIcon.tsx
│ │ └─ product/ # 상품 특화 UI
│ │ ├─ ProductCard.tsx
│ │ └─ ProductListItem.tsx
│ └─ types/
│ └─ index.ts
├─ package.json
├─ next.config.mjs
├─ postcss.config.mjs
├─ tsconfig.json
├─ split.ts
├─ restructure.ts
└─ fix-paths.ts
“파일 역할 + 내부 코드 쓰임” 문서화를 위한 설명 템플릿 (세부)
A. 앱 엔트리/레이아웃
src/app/layout.tsx
- 역할: 전역 HTML 스켈레톤, 글로벌 CSS 적용, metadata 설정.
- 핵심: 앱 전체 공통 래퍼(
<html lang="ko">, <body>).
src/app/page.tsx
- 역할: 현재 프로젝트의 “실질 라우팅 컨트롤러” (상태 기반 화면 전환 허브).
- 핵심 메서드 예시:
showToast(message): 토스트 상태 표시/해제.
navigateTo(screen): 화면 전환 상태 변경.
navigateToProduct(id): 상품 선택 + 상세 이동.
- 주의:
currentScreen === ... 분기 렌더링이 길게 이어짐.
src/app/not-found.tsx
B. 인증/메인 도메인 화면
src/app/(auth)/*
- 역할: 로그인/회원가입/인증/약관/프로필/관심 카테고리 단계.
- 예시 메서드:
CategorySelectionScreen의 카테고리 토글(toggleCategory)로 다중 선택 관리.