- 좌측 패널 · 아래 단추 넷 · 종단도 · 구조물 배치 폼을 페이지에 한 번만 만듦(design_shared) — 두 보기가 같은 노드 - 보기는 가운데 위 칸만: 종단 보기 = 3D(design_view_profile) · 횡단 보기 = 횡단 카드(design_view_cross · 처음 보일 때 그림) - 옛 B05_Profile_UI_Page · B06_Section_UI_Page 삭제 · 한 벌이 받은 조작은 지금 보기로, 관 목록 · 횡단 재계산 알림은 두 보기 모두로 - 진행 단계 종단설계 · 횡단설계 두 칸이 보기를 따라 켜짐 · 누르면 주소만 바꿈 · 제목도 따라감(setTitle · setActiveStep) - [저장] · [확정] 한 벌 — 두 보기 몫을 모아 saveDesign 한 번 · 종단 보기 [확정] 켬(횡단 보기를 숨긴 채 세워 횡단 자료를 얻음) - [초기화] · 계획노선 편집은 같은 페이지라도 다시 세움(remountRoute) - 덧붙임: 방향키는 초점 있는 쪽만(조정창 ↔ 종단도 계획고) · 횡단 보기 계획고 편집에도 [3D 업데이트] 대기 표시 · 종단 보기 폼 관 옵션을 횡단 캐시에도 얹음 · 종단 보기에서 횡단 조정 칸 가림 - 나눔: Cross_View 756→658(_Cross_View_Frame) · Page_Structures_Panel 700→547(_Structures_Spec) · 옛 B05 Page 786 → design_view_profile 638(_Page_Latest · _Page_Stations) - 시험: test_design_view_parity 한 벌 기준(한 패널 · 보기 오가도 같은 노드) · page_single · profile_single · save_channels · save_recompute 등 옮긴 자리로 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01KmELpdXFDRZHhfbGuRhSmL
35 lines
1.8 KiB
TypeScript
35 lines
1.8 KiB
TypeScript
/* =============================================================================
|
|
* B05_Profile_UI_Profile_Panel.ts
|
|
* 종단 보기의 하단 종단도 — 한 페이지의 **종단도 한 벌**(`design_shared` · 오른쪽 판 배수유역도)에
|
|
* 종단 보기 알림을 건다(계획서 24-2c · 24-3b).
|
|
*
|
|
* 종단도는 두 보기가 같은 노드를 쓴다. 여기는 종단 보기가 부르던 이름 · 모양을 지킨다 —
|
|
* 페이지는 `drainage` 로 배수유역도를 바로 부른다.
|
|
* ========================================================================== */
|
|
|
|
import type { DesignSideBoard } from "../A00_Common/design/design_profile";
|
|
import {
|
|
bindDesignView,
|
|
sharedProfile,
|
|
type DesignPageShared,
|
|
} from "../A00_Common/design/design_shared";
|
|
import type { RouteProfilePanelCallbacks } from "./B05_Profile_UI_Profile_Panel_Types";
|
|
|
|
/** 콜백 타입은 `_Panel_Types` 에 있다 — 옛 임포트 경로가 그대로 동작하도록 다시 내보낸다. */
|
|
export type { RouteProfilePanelCallbacks } from "./B05_Profile_UI_Profile_Panel_Types";
|
|
|
|
export function createRouteProfilePanel(
|
|
shared: DesignPageShared,
|
|
/** 측점 선택 변경 — 같은 측점 재선택·빈 곳 클릭이면 null(해제)로 알린다. */
|
|
onSelectStation: (stationId: string | null) => void,
|
|
/** [초기선 복원] 클릭 시 함께 실행(비정규 측점 등 다른 조작값도 초기화하려고 Page가 넘긴다). */
|
|
onResetAll?: () => void,
|
|
callbacks?: RouteProfilePanelCallbacks,
|
|
) {
|
|
bindDesignView(shared, "profile", { profile: { onSelectStation, onResetAll, callbacks } });
|
|
const profile = sharedProfile(shared);
|
|
/** 배수유역도 패널 — 경로 확정 흐름에서 유역선 편집 저장 여부를 묻는 데 쓴다. */
|
|
const drainage = profile.side as DesignSideBoard;
|
|
return Object.assign(profile, { drainage });
|
|
}
|