Merge remote-tracking branch 'origin/dev' into main_laptop_1
This commit is contained in:
@@ -546,6 +546,8 @@ export function appendCrossDesignOverlay(
|
||||
minSlope?: { points: Array<{ offset: number; elevation: number }> };
|
||||
maxSlope?: { points: Array<{ offset: number; elevation: number }> };
|
||||
},
|
||||
// 노폭 라벨 고정 자리(B06 카드 — X 축 라벨 바로 위 가운데). 없으면 노면 위.
|
||||
labelAt?: { layer: SVGElement; x: number; y: number },
|
||||
): void {
|
||||
const line = design.design_line;
|
||||
if (!line || line.length < 2) return;
|
||||
@@ -754,8 +756,11 @@ export function appendCrossDesignOverlay(
|
||||
const shoulderLeft = roadEdges ? roadEdges.left.offset_m - edges.left.offset_m : null;
|
||||
const shoulderRight = roadEdges ? edges.right.offset_m - roadEdges.right.offset_m : null;
|
||||
const label = document.createElementNS(SVG_NS, "text");
|
||||
label.setAttribute("x", String((x(edges.left.offset_m) + x(edges.right.offset_m)) / 2));
|
||||
label.setAttribute("y", String(toDisplayY(edges.left.elevation_m) - 6));
|
||||
label.setAttribute(
|
||||
"x",
|
||||
String(labelAt?.x ?? (x(edges.left.offset_m) + x(edges.right.offset_m)) / 2),
|
||||
);
|
||||
label.setAttribute("y", String(labelAt?.y ?? toDisplayY(edges.left.elevation_m) - 6));
|
||||
label.setAttribute("class", "b06-chart__carriageway-label");
|
||||
const widthText =
|
||||
widened > 0.001 && typeof standardWidth === "number"
|
||||
@@ -770,7 +775,7 @@ export function appendCrossDesignOverlay(
|
||||
: `좌 ${shoulderLeft.toFixed(2)} / 우 ${shoulderRight.toFixed(2)}m`
|
||||
}`
|
||||
: widthText;
|
||||
svg.append(label);
|
||||
(labelAt?.layer ?? svg).append(label);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -468,7 +468,11 @@ export function createCrossSectionCard(
|
||||
// (2026-09-06 사용자 확정: 구조물 자체 면적을 빼는 것이 아니다). 그림과 면적이
|
||||
// 같은 트림 값을 쓰므로 "그림은 이런데 수량은 저렇다"가 생기지 않는다.
|
||||
applyStructureAreas(section, designTrim);
|
||||
appendCrossDesignOverlay(plotLayer, section.design, x, toDisplayY, drawSamples, designTrim);
|
||||
appendCrossDesignOverlay(plotLayer, section.design, x, toDisplayY, drawSamples, designTrim, {
|
||||
layer: svg,
|
||||
x: (CROSS_PAD.left + widthPx - CROSS_PAD.right) / 2,
|
||||
y: heightPx - CROSS_PAD.bottom - 4,
|
||||
});
|
||||
// 사토장(유용토운반작업장) — 교본 6장 3절이 횡단도 표시를 요구한다. 값은 설계 결과에서
|
||||
// 그대로 오고 여기서 다시 세지 않는다. 선 종류는 터파기 파선과 갈라 둔다.
|
||||
appendSpoilFillOverlay(plotLayer, section.design, x, toDisplayY);
|
||||
|
||||
Reference in New Issue
Block a user