docs(notes): close input canonical cleanup

This commit is contained in:
2026-05-13 02:50:30 +09:00
parent 7bd08dcf9d
commit c3e04adb23
2 changed files with 105 additions and 0 deletions
@@ -918,3 +918,17 @@ frontend/lib/api/numberingRule.ts ← previewNumberi
3. **edit 뷰 컴포넌트** 가 운영에서 보임 (수정 모달) 3. **edit 뷰 컴포넌트** 가 운영에서 보임 (수정 모달)
4. **BlockRenderer.tsx:54-57** 의 runtimeConfig 가 columnName 기반 defaultValue hijack — fix 적용됨 4. **BlockRenderer.tsx:54-57** 의 runtimeConfig 가 columnName 기반 defaultValue hijack — fix 적용됨
5. 임시 console.log 모두 제거됨 (saveTemplate payload 의 일반 진단 로그만 1줄 유지) 5. 임시 console.log 모두 제거됨 (saveTemplate payload 의 일반 진단 로그만 1줄 유지)
---
## Closing (2026-05-13)
입력 canonical 마이그레이션은 본 phase 시리즈로 종결됨.
- **단일 진실의 원천**: `frontend/lib/registry/components/input/InputComponent.tsx` (canonical input)
- **단일 ConfigPanel**: `frontend/components/v2/config-panels/InvFieldConfigPanel.tsx` (id: `"input"`)
- **삭제된 폴더 11개**: 옛 입력 6종 + slider-basic + radio-basic + toggle-switch + test-input + `category-manager.tsx` orphan
- **보존 explicit/domain 7종**: entity-search-input, autocomplete-search-input, selected-items-detail-input, domain/v2-location-swap-selector, v2-category-manager, category-manager/, mail-recipient-selector
- **병합 커밋**: `7bd08dcf9 refactor(components): consolidate canonical input cleanup`
상세 phase 별 작업과 검증 명령은 `notes/gbpark/2026-05-12-codex-handoff-input-canonical.md` §6 참고.
@@ -213,3 +213,94 @@ D.7 이후 진행.
- old file/media 본체 복구 금지 - old file/media 본체 복구 금지
- DB layout JSON 변환 SQL 작성 금지 - DB layout JSON 변환 SQL 작성 금지
- FieldConfig / DataPort 계약 축소 금지 - FieldConfig / DataPort 계약 축소 금지
---
## 6. 진행 완료 요약 (2026-05-13, Phase F.4)
### 6.1 완료된 Phase
| Phase | 내용 | 상태 |
|---|---|---|
| D.7 | canonical `input``mask` / `slider` / `color` 흡수 | ✅ 완료 |
| E | 옛 입력 6종 폴더 삭제 (text/number/date/select/checkbox/textarea) | ✅ 완료 |
| F.1 | `radio-basic` · `toggle-switch` 폴더 삭제 | ✅ 완료 |
| F.2 | `test-input` 폴더 삭제, 기타 input-adjacent 후보 분류/보존 | ✅ 완료 |
| F.3 | orphan `category-manager.tsx` 삭제, `v2-numbering-rule` stale schema 정리 | ✅ 완료 |
| F.4 | 최종 grep audit + 본 노트 업데이트 | ✅ 완료 |
병합 커밋: `7bd08dcf9 refactor(components): consolidate canonical input cleanup`
### 6.2 삭제된 컴포넌트 폴더/파일
- 옛 입력 6종 (Phase E): `text-input/`, `number-input/`, `date-input/`, `select-basic/`, `checkbox-basic/`, `textarea-basic/`
- 슬라이더 (Phase D.7): `slider-basic/`
- 라디오/토글 (Phase F.1): `radio-basic/`, `toggle-switch/`
- CLI demo 잔재 (Phase F.2): `test-input/`
- orphan 정의 파일 (Phase F.3): `lib/registry/components/category-manager.tsx` (standalone, never imported)
### 6.3 의도적 보존 (explicit / domain)
| 폴더 | 분류 | 보존 이유 |
|---|---|---|
| `entity-search-input/` | explicit 검색 모달 | canonical input 의 `entity` 는 code-name option source 전용. 명시적 검색 UI 가 필요한 케이스는 별도 계열로 유지. `useEntitySearch` hook 은 modal-repeater-table / autocomplete-search-input 에서도 공유. |
| `autocomplete-search-input/` | explicit autocomplete | demo 페이지 (`app/test-autocomplete-mapping/page.tsx`) 와 runtime 분기 (`DynamicComponentRenderer`) 가 살아있음. |
| `selected-items-detail-input/` | explicit 선택항목 상세 입력 | `screenGroup.ts``parentDataMapping`, `V2PropertiesPanel` 테이블 로딩, `V2SelectedItemsDetailInputConfigPanel` 등 다지점 의존. |
| `domain/v2-location-swap-selector/` | domain 컴포넌트 | 도메인 별 출발/도착 swap UI. 추후 domain phase 에서 재평가. |
| `v2-category-manager/` | domain 컴포넌트 | 카테고리 관리. 추후 domain phase 에서 재평가. |
| `category-manager/` (폴더) | explicit category manager | "공통코드관리" 통합 phase 에서 일괄 처리 예정. |
| `mail-recipient-selector/` | explicit 메일 수신자 선택 | 내부 인원 + 외부 이메일 선택 기능 유지. |
### 6.4 보존 인접 시스템 (Phase F 범위 밖, 별도 서브시스템)
- `frontend/lib/api/numberingRule.ts`, `components/numbering-rule/`, `app/(main)/admin/systemMng/numberingRuleList/`, `types/numbering-rule.ts`: 채번관리 admin UI + API 클라이언트. canvas 컴포넌트 (v2-numbering-rule) 와 무관.
- `frontend/lib/registry/components/input/numbering-picker.tsx`: canonical input 의 autonum 진입점. 채번 admin API 호출.
- `frontend/lib/registry/pop-components/`: POP 카드 셀 타입 시스템 (`number-input` 등의 셀 이름). canvas input 컴포넌트와 동일 문자열이지만 별개 도메인. 절대 건드리지 말 것.
### 6.5 검증 명령 + 기대 결과
```bash
# 1. 작업 디렉터리 검사
git diff --check
git diff --cached --check
# 2. 금지 패턴 검사 (0 matches 기대)
rg "v2-input|v2-select|V2InputRenderer|V2SelectRenderer" \
frontend/lib frontend/components frontend/app frontend/types frontend/styles
rg 'componentType: "v2-file-upload"|file: "v2-file-upload"|image: "v2-file-upload"|img: "v2-file-upload"' \
frontend/lib frontend/components frontend/app frontend/types
rg "EntityPicker|entity-picker|EntitySearchModal" \
frontend/lib/registry/components/input \
frontend/components/v2/config-panels/InvFieldConfigPanel.tsx
# 3. 삭제된 입력 컴포넌트 (history comment 만 남아야 함)
rg "slider-basic|radio-basic|toggle-switch|test-input" \
frontend/lib frontend/components frontend/app frontend/types frontend/styles
# → comment 만 12건 정도, 활성 코드 0건
rg "date-input|text-input|number-input|select-basic|checkbox-basic|textarea-basic" \
frontend/lib frontend/components frontend/app frontend/types frontend/styles
# → comment + POP cell-type 만, 활성 입력 컴포넌트 코드 0건
# 4. 보존 컴포넌트 (활성 wiring 존재)
rg "entity-search-input|autocomplete-search-input|selected-items-detail-input|v2-location-swap-selector|v2-category-manager|category-manager|mail-recipient-selector" \
frontend/lib frontend/components frontend/app frontend/types frontend/styles
# → 각 컴포넌트의 자체 폴더 + 활성 wiring 만 나와야 함
```
### 6.6 tsc 상태
- `frontend/package.json` 에서 직접 의존성으로 박혀있던 `lightningcss-linux-x64-gnu` 를 제거하여 Windows 에서 `npm install``tsc` 실행 가능.
- `./node_modules/.bin/tsc.cmd --noEmit --pretty false` → 2806개의 기존 전역 에러 (snake_case/camelCase, BlockRole). Phase D.7~F.3 은 새 에러를 만들지 않았으며, 삭제 모듈 관련 orphan import 도 0건.
- 전역 tsc 정리는 본 phase 의 책임이 아님.
### 6.7 다음 권장 작업
- 입력 canonical 정리는 **종결**. 추가 폴더 삭제는 새 plan/phase 가 필요.
- 다음 line of work 후보 (각각 별도 plan 필요):
- `entity-search-input` / `autocomplete-search-input` 의 explicit UX 재평가 (canonical input 의 entity option source 와 진짜 search modal 의 경계 재확정)
- `v2-category-manager` / `category-manager/` 의 "공통코드관리" 통합 phase
- domain 컴포넌트 phase (`domain/v2-location-swap-selector`, `domain/v2-rack-structure`, `domain/v2-bom-*` 등)
- 전역 snake_case ↔ camelCase 일관성 정리 (현재 tsc 에러 대부분의 원인)