feat(514-1 알약 우클릭 삭제): 측점선 없는 구조물(대피로 · 노출형 횡단수로 등)도 종단 알약 · 평면 마커 우클릭 「구조물 삭제」 — 513-3 주인 가르기를 알약 id 로(removeMarkOwner · 관 알약 = 관 지점 정본 · 그 밖 = 좌측 칸 [삭제]와 같은 길) · B05 종단 보기 · B06 횡단 보기 같은 길(onStructureMarkRemove) · 캐시에만 · [저장] 때 나감 · 우클릭 삭제 글 = 관 · 세월교 · BOX 도 「구조물 삭제」 하나 · 시험 test_514_1 · test_513_1 글 기대 고침 — 요구 328-1 · 328-2
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -3,7 +3,7 @@
|
||||
* 평면 우클릭 구조물 메뉴(513-1 · 요구 327-1).
|
||||
*
|
||||
* · 메뉴 = 종단 그래프 우클릭과 같은 항목 · 같은 동작(`structureMenuItemsAt` · 재료 = 지금 선 종단 그래프).
|
||||
* · 자리 = 누른 곳을 노선에 내린 누가거리 · 가까운 구조물 · 배관 측점이면 삭제.
|
||||
* · 자리 = 누른 곳을 노선에 내린 누가거리 · 가까운 구조물 · 배관 측점이면 삭제 · 측점선 없는 마커도(514-1).
|
||||
* · 노드 위 = 옛 동작 그대로(노드 삭제 · `bindNodeSplice`) · 노선에서 먼 곳 = 메뉴 없음.
|
||||
* ========================================================================== */
|
||||
|
||||
@@ -11,6 +11,7 @@ import { pickPx } from "../A00_Common/touch_bridge";
|
||||
import { createMapContextMenu } from "@ui/ui_template_context_menu";
|
||||
import { liveStructureMenu, structureMenuItemsAt } from "./B05_Profile_UI_Profile_Structures";
|
||||
import { routePointAtScreen } from "./B05_Profile_UI_RouteEdit_Input";
|
||||
import { planMarkAt } from "./B05_Profile_UI_RouteEdit_StructureMarks";
|
||||
import type { RouteEditPointerParams } from "./B05_Profile_UI_RouteEdit_Pointer";
|
||||
import { stationFrameAt } from "./logic/B05_Profile_UI_RouteEdit_Frame";
|
||||
|
||||
@@ -47,10 +48,13 @@ export function bindPlanStructureMenu(
|
||||
.filter((entry) => entry.distance <= pickPx(STATION_HIT_PX))
|
||||
.sort((left, right) => left.distance - right.distance)[0];
|
||||
const host = menu.element.parentElement?.getBoundingClientRect() ?? rect;
|
||||
const mark = near ? null : planMarkAt(canvas, line, toScreen, px, py)?.mark;
|
||||
menu.open(
|
||||
event.clientX - host.left,
|
||||
event.clientY - host.top,
|
||||
structureMenuItemsAt(options, hit.chainageM, near?.station ?? null),
|
||||
mark
|
||||
? [["구조물 삭제", () => options.onRemoveMark?.(mark.id)]]
|
||||
: structureMenuItemsAt(options, hit.chainageM, near?.station ?? null),
|
||||
);
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user