Files
Aislo/B05_Profile/logic/B05_Profile_UI_Profile_Alignment_Edit.ts
T
eomsangdonandClaude Opus 5.5 2da632dc45 refactor(B05·B06): 부름 0 옛 줄 · 늘 건너뛰는 시험 지움 (PLAN 472-8 ② ③ · 요구 409)
지움
- flushDesignStore(design_store · 부름 0) — 시험 344-4 의 flush 대조 한 줄도
- b_page_state 옛 세션 열쇠 옮김(legacy · migrate) · b_project_switch 옛 키 머리
  — 옛 열쇠는 세션 저장소(탭 닫으면 사라짐) · 지금 코드가 안 씀 · storage · DB 에 없음
  · 시험 290-1 · 401 · 384-1 의 옛 키 줄 뺌
- 시험만 부르던 TS — planFootprint(346-2 거울은 footprintRecord + slopePieces 로 그대로)
  · shiftSegment · shiftMovingPoints(쉬프트 단추는 09-02 지움 · min_cover_guard 쉬프트 시험 뺌)
  · dropStationsNear(test_b05_station_merge.mjs 지움) · createIrregularStationsSection(부름 0)
  · generalStations(234-1 은 기본 맞춤 값으로 같은 것 잼) · sameSummaryItem
- test_b05_b06_save_roundtrip + helper_b05_save_payload 둘 — 프로젝트 936be972 storage 없어 늘 skip
  · 같은 저장 왕복은 test_472_6_design_save(창구 원자성) · test_449_save_pipes(관 PUT)
    · test_238_1_save_keeps_structure_stations(구조물 측점)가 잼

남김
- migrateLegacyStations — 부르는 곳 있음(design_view_profile_sections) · storage 에 비정규 측점 남음
- common_util_excavation 셋 — 지금은 운영이 부름(design_calc_node)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-28 21:09:50 +09:00

29 lines
1.2 KiB
TypeScript

/* =============================================================================
* B05_Profile/logic/B05_Profile_UI_Profile_Alignment_Edit.ts
* 종단 계획선 편집 도구 — 곡선 R 입력. `B05_Profile_UI_Profile_Alignment.ts`
* 에서 나눔(700줄 · 511-B B-3) · 선형 짓기(`buildAlignment`)는 그 파일.
* ========================================================================== */
import {
chainageKey,
type AlignmentCurve,
type AlignmentEdits,
} from "./B05_Profile_UI_Profile_Alignment";
/**
* 곡선 행의 R 입력을 저장한다. R이 1차 값이므로 그대로 담고, 곡선길이는
* L = R × |대수차| 로 매 렌더마다 다시 계산된다(계획고를 편집해도 R은 유지된다).
* 빈 값이면 키를 지워 정책 기본 반경으로 돌아간다.
*/
export function setCurveRadius(
edits: AlignmentEdits,
curve: AlignmentCurve,
radiusM: number,
): AlignmentEdits {
const key = chainageKey(curve.chainage_m);
const curveRadii = { ...edits.curve_radii };
if (!Number.isFinite(radiusM) || radiusM <= 0) delete curveRadii[key];
else curveRadii[key] = Number(radiusM.toFixed(6));
return { ...edits, curve_radii: curveRadii };
}