From cebed851b5b4f26ccbd0250ccb298f86c8bda2bc Mon Sep 17 00:00:00 2001 From: umsangdon Date: Fri, 16 Oct 2026 11:59:27 +0900 Subject: [PATCH] =?UTF-8?q?=EF=BB=BFfeat(=EC=A2=85=EB=8B=A8=EB=B3=B4?= =?UTF-8?q?=EA=B8=B0):=20345-5=20=ED=8F=89=EB=A9=B4=20=3D=20=EA=B0=80?= =?UTF-8?q?=EC=9A=B4=EB=8D=B0=20=EC=A0=84=EC=B2=B4=20=EC=98=81=EC=97=AD=20?= =?UTF-8?q?=C2=B7=20=EC=95=84=EB=9E=98=20=EC=A2=85=EB=8B=A8=20=ED=8C=90=20?= =?UTF-8?q?=3D=20=EB=8B=A4=EC=8B=9C=20=EB=9C=AC=20=ED=8C=90=20=E2=80=94=20?= =?UTF-8?q?=EC=A2=85=EB=8B=A8=20=EB=B3=B4=EA=B8=B0=20=ED=8C=90=20=ED=9D=90?= =?UTF-8?q?=EB=A6=84=20=EA=B7=9C=EC=B9=99=EC=9D=84=20=ED=9A=A1=EB=8B=A8=20?= =?UTF-8?q?=EB=B3=B4=EA=B8=B0=EB=A7=8C=EC=9C=BC=EB=A1=9C=20=EB=90=98?= =?UTF-8?q?=EB=8F=8C=EB=A6=BC(345-3=20=EC=95=9E=20=EA=BC=B4)=20=C2=B7=20?= =?UTF-8?q?=EB=81=8C=EC=96=B4=20=EB=86=92=EC=9D=B4=20=C2=B7=20=EC=A0=91?= =?UTF-8?q?=EA=B8=B0=20=C2=B7=20=EC=83=88=20=EC=B0=BD=20=EB=96=BC=EA=B8=B0?= =?UTF-8?q?=20=EA=B7=B8=EB=8C=80=EB=A1=9C=20=C2=B7=20=EA=B0=80=EB=A0=A4?= =?UTF-8?q?=EC=A7=84=20=EC=95=84=EB=9E=98=EC=AA=BD=EC=9D=80=20=ED=8C=AC?= =?UTF-8?q?=EC=9C=BC=EB=A1=9C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 시험: test_345_5_plan_full_overlay 3(전체 영역 · 뜬 판 · 띠 없음 · 종단 그래프 있음) · test_345_3 판 시험 고쳐 씀 · 관련 162 통과 Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_01Se7ytqbohmBQnfYpwYFnYf --- A00_Common/design/design_page.css | 6 +- B05_Profile/B05_Profile_UI_Style.css | 4 +- resources/tester/test_345_3_route_body.py | 9 ++- .../tester/test_345_5_plan_full_overlay.py | 70 +++++++++++++++++++ 4 files changed, 81 insertions(+), 8 deletions(-) create mode 100644 resources/tester/test_345_5_plan_full_overlay.py diff --git a/A00_Common/design/design_page.css b/A00_Common/design/design_page.css index 53f92167a..d4b2ff545 100644 --- a/A00_Common/design/design_page.css +++ b/A00_Common/design/design_page.css @@ -10,8 +10,8 @@ display: none; } -/* 가운데 = 위 칸(보기마다 다름) + 아래 종단도 한 벌. 종단도는 두 보기 모두 위 칸 아래 흐름에 - 선다(345-3 — 종단 보기 위 칸 = 평면 노선 편집 · 3D 는 모달) · 높이 끌기는 그대로. */ +/* 가운데 = 위 칸(보기마다 다름) + 아래 종단도 한 벌. 종단 보기에서 종단도는 평면(노선 편집) 위에 + 떠 있는 판(absolute · 평면은 전체 영역 · 345-5)이고, 횡단 보기에서는 카드 칸 아래 흐름에 선다. */ .design-page__main { position: relative; display: flex; @@ -35,7 +35,7 @@ min-height: 0; } -.design-page__main > .design-page__profile > .b05-route-profile { +.design-page__main[data-view="cross"] > .design-page__profile > .b05-route-profile { position: relative; flex: none; } diff --git a/B05_Profile/B05_Profile_UI_Style.css b/B05_Profile/B05_Profile_UI_Style.css index e0cff11c1..86d49ae50 100644 --- a/B05_Profile/B05_Profile_UI_Style.css +++ b/B05_Profile/B05_Profile_UI_Style.css @@ -36,8 +36,8 @@ } /* 하단 종단 패널: 그래프 + 12행 도면 테이블을 담기 위해 화면 높이의 60%를 차지한다. - 페이지 안에서는 위 칸(평면 · 횡단 카드) 아래 **흐름**에 선다(`design_page.css` · 345-3) — - 여기 absolute 는 페이지 밖 쓰임 꼴. 접기 핸들로 내리면 위 칸이 전체 영역을 갖는다. */ + 평면(노선 편집)을 밀어내지 않고 그 위를 덮는 오버레이로 띄운다(345-5) — 판을 여닫아도 평면 + 크기가 안 바뀜 · 가려진 아래쪽은 팬으로 봄. 횡단 보기에서는 카드 칸 아래 흐름(`design_page.css`). */ .b05-route-profile { position: absolute; z-index: 3; diff --git a/resources/tester/test_345_3_route_body.py b/resources/tester/test_345_3_route_body.py index 5162006fa..50efc25ba 100644 --- a/resources/tester/test_345_3_route_body.py +++ b/resources/tester/test_345_3_route_body.py @@ -78,11 +78,14 @@ def test_편집기는_본문_페이지_수명(): assert len(view.splitlines()) <= 700 -def test_종단도_판은_두_보기_모두_흐름(): +def test_종단도_판은_횡단_보기만_흐름(): + """345-5 — 종단 보기는 다시 뜬 판(평면 위 오버레이) · 횡단 보기만 흐름.""" css = _read("A00_Common/design/design_page.css") - rule = _block(css, ".design-page__main > .design-page__profile > .b05-route-profile") + rule = _block( + css, '.design-page__main[data-view="cross"] > .design-page__profile > .b05-route-profile' + ) assert "position: relative;" in rule and "flex: none;" in rule - assert '[data-view="cross"] > .design-page__profile > .b05-route-profile' not in css + assert "\n.design-page__main > .design-page__profile > .b05-route-profile" not in css def test_계획노선_칸_편집_단추_지움(): diff --git a/resources/tester/test_345_5_plan_full_overlay.py b/resources/tester/test_345_5_plan_full_overlay.py new file mode 100644 index 000000000..83966b029 --- /dev/null +++ b/resources/tester/test_345_5_plan_full_overlay.py @@ -0,0 +1,70 @@ +"""345-5 사용자 의견(요구 233) — 종단 보기 평면 = 가운데 전체 영역 · 아래 종단 판 = 뜬 판 · +노선 편집 안 「원지반선 · 계획 종단선」 띠 없음 · 아래 종단 판 종단 그래프는 그대로. + +꼴은 글로 봄(화면 확인은 브레인). +./venv/Scripts/python.exe -m pytest resources/tester/test_345_5_plan_full_overlay.py -q +""" + +from __future__ import annotations + +import re +from pathlib import Path + +ROOT = Path(__file__).resolve().parents[2] + + +def _read(rel: str) -> str: + return (ROOT / rel).read_text(encoding="utf-8") + + +def _block(css: str, selector: str) -> str: + found = re.search(rf"^{re.escape(selector)} \{{([^}}]*)\}}", css, re.M) + assert found, selector + return found.group(1) + + +def test_평면은_가운데_전체_영역(): + page = _read("A00_Common/design/design_page.css") + main = _block(page, ".design-page__main") + assert "position: relative;" in main and "height: 100%;" in main + assert "flex: 1 1 auto;" in _block(page, ".design-page__center") + # 종단 보기에서 판을 흐름에 세우는 규칙 없음 — 가운데가 위아래 끝까지 + flow = re.findall(r"^(\.design-page__main[^{\n]*\.b05-route-profile) \{", page, re.M) + assert flow == [ + '.design-page__main[data-view="cross"] > .design-page__profile > .b05-route-profile' + ] + route = _read("B05_Profile/B05_Profile_UI_Style_RouteEdit.css") + assert "flex: 1 1 auto;" in _block(route, ".b05-routeedit") + assert "flex: 1 1 auto;" in _block(route, ".b05-routeedit__canvas-wrap") + # 캔버스 크기 = 칸 크기(ResizeObserver) · 평면은 가운데 칸에 붙음 + editor = _read("B05_Profile/B05_Profile_UI_RouteEdit.ts") + assert "new ResizeObserver(() => resize())" in editor + assert ( + 'sizeWatch.observe(overlay.querySelector(".b05-routeedit__canvas-wrap")!)' + in editor + ) + view = _read("A00_Common/design/design_view_profile.ts") + assert "center.append(mainContent);" in view + assert "mountRouteEditor(mainContent, host, activeProjectId, rebuildAfterReplan," in view + + +def test_종단_판은_평면_위_뜬_판(): + style = _read("B05_Profile/B05_Profile_UI_Style.css") + panel = _block(style, ".b05-route-profile") + for line in ("position: absolute;", "z-index: 3;", "bottom: 0;", "left: 0;", "right: 0;"): + assert line in panel + # 끌어 높이 · 접기 · 새 창 떼기 그대로 + assert "height: var(--b05-profile-height, 60dvh);" in panel + assert ".b05-route-profile.is-collapsed > .ui-resizer" in style + page = _read("A00_Common/design/design_page.css") + assert "position: relative;" in _block(page, ".b05-route-profile.is-popout") + + +def test_띠_없음_종단_그래프_있음(): + chrome = _read("B05_Profile/B05_Profile_UI_RouteEdit_Chrome.ts") + assert "data-strip" not in chrome + assert not (ROOT / "B05_Profile/B05_Profile_UI_RouteEdit_ProfileStrip.ts").exists() + # 아래 종단 판(종단 그래프 · 표 · 유토곡선)은 그대로 세움 + view = _read("A00_Common/design/design_view_profile.ts") + assert "const profilePanel = createRouteProfilePanel(" in view + assert (ROOT / "B05_Profile/B05_Profile_UI_Profile_Panel.ts").exists()