From a0a089a3d0571f929dd7063659536210fc288065 Mon Sep 17 00:00:00 2001 From: umsangdon Date: Mon, 12 Oct 2026 22:36:01 +0900 Subject: [PATCH] =?UTF-8?q?fix(b06):=20=EC=95=88=20=EA=B3=A8=EB=9D=BC?= =?UTF-8?q?=EC=A7=84=20=EC=B9=B4=EB=93=9C=20=EB=B3=B4=EB=9D=BC=20=EC=82=AC?= =?UTF-8?q?=EB=A9=B4=EC=84=A0=20=EC=B2=AB=20=EB=88=84=EB=A6=84=20=3D=20?= =?UTF-8?q?=EA=B7=B8=20=EC=84=A0=20=E2=80=94=20=EB=82=A8=EC=9D=80=20?= =?UTF-8?q?=EB=B6=80=EC=9E=AC=20=EA=B3=A0=EB=A6=84(=EB=8F=84=EC=88=98?= =?UTF-8?q?=EB=A1=9C=20=EB=9D=A0)=EC=9D=84=20=EB=A8=BC=EC=A0=80=20?= =?UTF-8?q?=ED=92=80=EC=96=B4=20=EC=B9=B4=EB=93=9C=20=EA=B3=A0=EB=A6=84?= =?UTF-8?q?=EC=9D=B4=20=EB=90=98=EC=82=B4=EB=A6=AC=EC=A7=80=20=EC=95=8A?= =?UTF-8?q?=EC=9D=8C=20(295-4)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_014utrjfoW831Vc5wJUd13kL --- B06_Section/B06_Section_UI_Cross_View.ts | 6 +++++- resources/tester/test_137_design_pick.py | 2 +- .../tester/test_295_pick_order_detail.py | 21 +++++++++++++++++++ 3 files changed, 27 insertions(+), 2 deletions(-) diff --git a/B06_Section/B06_Section_UI_Cross_View.ts b/B06_Section/B06_Section_UI_Cross_View.ts index 7fa0738f2..2fb647b19 100644 --- a/B06_Section/B06_Section_UI_Cross_View.ts +++ b/B06_Section/B06_Section_UI_Cross_View.ts @@ -321,7 +321,11 @@ export function createCrossSectionCard( setChipActive(null); onAreaSelect?.(section.station_id, null); } - if (!isSelected) onSelect(section.station_id); + if (!isSelected) { + // 첫 누름 = 이 선 — 남은 부재 고름(도수로 띠 등)이 카드 고름에 되살아나 선을 풀지 않게(295-4) + if (activeRevet === null) revetOffset?.select(section.chainage_m, null); + onSelect(section.station_id); + } } setLineActive(next); }; diff --git a/resources/tester/test_137_design_pick.py b/resources/tester/test_137_design_pick.py index af7412b9a..fb46749b6 100644 --- a/resources/tester/test_137_design_pick.py +++ b/resources/tester/test_137_design_pick.py @@ -97,7 +97,7 @@ def test_카드_배선_하나만() -> None: """137-3 — 선을 고르면 벽 · 본체 · 면적을 풀고 카드도 고름 · 다른 고름은 선을 풂.""" view = _src("B06_Section/B06_Section_UI_Cross_View.ts") assert "const pickLine = (index: number): void => {" in view - assert "if (!isSelected) onSelect(section.station_id);" in view + assert "if (activeRevet === null) revetOffset?.select(section.chainage_m, null);" in view assert view.count("dropLine();") >= 4 # 본체 · 벽 · 카드 풂 · 면적 assert "setLineActive(pickedLineAt(section.station_id));" in view # 다시 그려도 되살림 assert "zoomBar.prepend(linePick.label);" in view # 치수 = [+ − ⤢] 왼쪽 diff --git a/resources/tester/test_295_pick_order_detail.py b/resources/tester/test_295_pick_order_detail.py index f69390536..4bc652b36 100644 --- a/resources/tester/test_295_pick_order_detail.py +++ b/resources/tester/test_295_pick_order_detail.py @@ -116,3 +116,24 @@ def test_배선(): assert "detailHomeView(layerPoints(layer), [cx, cy], plot, homeScale, 16)" in detail for name in ("B06_Section_UI_Cross_View.ts", "B06_Section_UI_Cross_Detail_Select.ts"): assert len(_read(name).splitlines()) <= 700 + + +def test_보라_선_첫_누름은_그_선_295_4(): + """안 골라진 카드의 성토 사면선 첫 누름 — 남은 부재키(도수로 띠)를 먼저 풀어 카드 고름이 되살리지 않음.""" + proc = subprocess.run( # noqa: S603 — 고정 실행 파일 + ["node", os.path.join(HERE, "helper_294_7_ford_slab_pick.cjs")], + capture_output=True, + text=True, + encoding="utf-8", + timeout=60, + ) + assert proc.returncode == 0, proc.stderr + first = json.loads(proc.stdout)["firstLine"] + assert first["oldKey"] == "chute" # 옛 길 = 카드 고름이 도수로 띠 부재키를 지킴 → 선 풀림 + assert first["newKey"] is None + view = " ".join(_read("B06_Section_UI_Cross_View.ts").split()) + assert "if (!isSelected) { // 첫 누름 = 이 선" in view + assert ( + "if (activeRevet === null) revetOffset?.select(section.chainage_m, null); onSelect(section.station_id);" + in view + )