From 54b312b737f1bd4766794559955f75419937816b Mon Sep 17 00:00:00 2001 From: umsangdon Date: Mon, 26 Oct 2026 05:19:27 +0900 Subject: [PATCH] =?UTF-8?q?fix(E03):=20=ED=99=95=EB=A5=A0=20=ED=83=AD=20?= =?UTF-8?q?=EC=B9=B8=20=EB=B0=B0=EC=B9=98=20=C2=B7=20=EA=B7=B8=EB=9E=98?= =?UTF-8?q?=ED=94=84=20=ED=91=9C=EC=A7=80=20=EA=B8=80=20=EA=B2=B9=EC=B9=A8?= =?UTF-8?q?=20=E2=80=94=20=EC=8B=A4=ED=96=89=20=EC=B9=B8=203=20=EC=97=B4?= =?UTF-8?q?=20=EA=B2=A9=EC=9E=90=20=C2=B7=20=EB=8B=A8=EC=B6=94=20=EC=A4=84?= =?UTF-8?q?=20=EB=94=B0=EB=A1=9C=20=C2=B7=20=EC=9E=85=EB=A0=A5=20=ED=91=9C?= =?UTF-8?q?=20=EC=A2=81=ED=9E=98=20=C2=B7=20=ED=91=9C=EC=A7=80=20=EA=B8=80?= =?UTF-8?q?=20=EC=A4=84=20=EB=82=98=EB=88=94=20=C2=B7=20=EC=84=B8=EB=A1=9C?= =?UTF-8?q?=EC=B6=95=20=EC=9D=B4=EB=A6=84=20=EC=9C=84=EB=A1=9C=20(537-1)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Claude Opus 5.5 --- E03_StabSection/E03_StabSection_UI_Prob.css | 30 ++++++++++++++++--- E03_StabSection/E03_StabSection_UI_Prob.ts | 9 +++--- .../E03_StabSection_UI_ProbChart.ts | 19 +++++++----- ui_template/ui_template_locale_e03.ts | 2 +- 4 files changed, 44 insertions(+), 16 deletions(-) diff --git a/E03_StabSection/E03_StabSection_UI_Prob.css b/E03_StabSection/E03_StabSection_UI_Prob.css index 4ea757351..0a9f45842 100644 --- a/E03_StabSection/E03_StabSection_UI_Prob.css +++ b/E03_StabSection/E03_StabSection_UI_Prob.css @@ -1,15 +1,37 @@ /* E03 확률 · 민감도 탭(537-1) — 입력 표 · 히스토그램 · 민감도 선 · 토네이도 막대 */ +.e03-prob-vars { + font-size: 12px; +} + .e03-prob-vars input[type="number"] { - width: 5.5em; + width: 4.2em; } .e03-prob-vars select { - width: auto; + width: 6.2em; } .e03-prob-run { - flex-wrap: wrap; - align-items: flex-end; + display: grid; + grid-template-columns: repeat(3, minmax(0, 1fr)); + gap: 6px 8px; + margin-top: 8px; +} + +.e03-prob-run .ui-field { + min-width: 0; +} + +.e03-prob-run select, +.e03-prob-run input { + width: 100%; +} + +.e03-prob-actions { + display: flex; + justify-content: flex-end; + gap: 8px; + margin: 8px 0; } .e03-prob-src summary { diff --git a/E03_StabSection/E03_StabSection_UI_Prob.ts b/E03_StabSection/E03_StabSection_UI_Prob.ts index 3cd5b777e..d51ce5f5a 100644 --- a/E03_StabSection/E03_StabSection_UI_Prob.ts +++ b/E03_StabSection/E03_StabSection_UI_Prob.ts @@ -176,7 +176,7 @@ export function createProbPanel(projectId: string, base: string, repaint: () => }); return input; }; - const unit = row.kind === "cov" ? t("E03_Pb_Cov") : row.prop === "water" ? "σ m" : "σ"; + const unit = row.kind === "cov" ? "" : row.prop === "water" ? "σ m" : "σ"; const label = row.prop === "water" || row.prop === "ru" ? t(`E03_Pb_Prop_${row.prop}` as LocaleKey) @@ -199,7 +199,7 @@ export function createProbPanel(projectId: string, base: string, repaint: () => function runFields(setup: ProbSetup, slot: string, editable: boolean): HTMLElement { const r = cache!.run; - const wrap = el("div", { className: "e03-panel__row e03-prob-run" }); + const wrap = el("div", { className: "e03-prob-run" }); const set = (k: K, v: (typeof r)[K]): void => { r[k] = v; save(); @@ -281,8 +281,9 @@ export function createProbPanel(projectId: string, base: string, repaint: () => }, }); reset.disabled = !!busy; - wrap.append(reset, go); - return wrap; + const actions = el("div", { className: "e03-prob-actions" }); + actions.append(reset, go); + return el("div", { children: [wrap, actions] }); } function summary(rec: ProbRecord): HTMLElement { diff --git a/E03_StabSection/E03_StabSection_UI_ProbChart.ts b/E03_StabSection/E03_StabSection_UI_ProbChart.ts index 57ba2ce39..08bf0de62 100644 --- a/E03_StabSection/E03_StabSection_UI_ProbChart.ts +++ b/E03_StabSection/E03_StabSection_UI_ProbChart.ts @@ -12,7 +12,7 @@ import { svgEl } from "./E03_StabSection_UI_Section"; const W = 380; const H = 200; -const PAD = { l: 44, r: 12, t: 12, b: 28 }; +const PAD = { l: 44, r: 12, t: 22, b: 28 }; const fmt = (v: number | null | undefined, d = 2): string => v === null || v === undefined || !Number.isFinite(v) ? "-" : v.toFixed(d); @@ -49,12 +49,13 @@ function frame( for (const v of xt) axis.append(svgEl("text", { x: sx(v), y: H - pad.b + 14, "text-anchor": "middle" }, String(v))); axis.append(svgEl("text", { x: W - pad.r, y: H - 2, "text-anchor": "end" }, xLabel)); - axis.append(svgEl("text", { x: 2, y: pad.t - 2 }, yLabel)); + axis.append(svgEl("text", { x: 2, y: 10 }, yLabel)); svg.append(axis); return { svg, sx, sy }; } -function mark(f: Frame, x: number, cls: string, label: string): void { +/** 세로 표지선 · 글 — row = 글 줄(가까운 표지끼리 안 겹치게 아래로) */ +function mark(f: Frame, x: number, cls: string, label: string, row = 0): void { f.svg.append( svgEl("line", { x1: f.sx(x), @@ -63,7 +64,11 @@ function mark(f: Frame, x: number, cls: string, label: string): void { y2: H - PAD.b, class: `e03-prob-mark ${cls}`, }), - svgEl("text", { x: f.sx(x) + 3, y: PAD.t + 10, class: `e03-prob-mark__text ${cls}` }, label), + svgEl( + "text", + { x: f.sx(x) + 3, y: PAD.t + 10 + 12 * row, class: `e03-prob-mark__text ${cls}` }, + label, + ), ); } @@ -102,8 +107,8 @@ export function histogramChart( f.svg.append(bar); }); mark(f, 1, "e03-prob-mark--one", "F = 1"); - if (required) mark(f, required, "e03-prob-mark--req", `${t("E03_Required")} ${fmt(required)}`); - if (fsDet) mark(f, fsDet, "e03-prob-mark--det", t("E03_Pb_Det")); + if (required) mark(f, required, "e03-prob-mark--req", `${t("E03_Required")} ${fmt(required)}`, 1); + if (fsDet) mark(f, fsDet, "e03-prob-mark--det", t("E03_Pb_Det"), 2); return box("prob-hist", f.svg); } @@ -118,7 +123,7 @@ export function cdfChart(res: ProbResult, required: number | null): HTMLElement svgEl("polyline", { points: pointsText(pts), class: "e03-prob-line e03-prob-line--0" }), ); mark(f, 1, "e03-prob-mark--one", `Pf ${fmt((res.stats.pf ?? 0) * 100, 1)} %`); - if (required) mark(f, required, "e03-prob-mark--req", `${t("E03_Required")} ${fmt(required)}`); + if (required) mark(f, required, "e03-prob-mark--req", `${t("E03_Required")} ${fmt(required)}`, 1); return box("prob-cdf", f.svg); } diff --git a/ui_template/ui_template_locale_e03.ts b/ui_template/ui_template_locale_e03.ts index 457cf797f..139bdafdd 100644 --- a/ui_template/ui_template_locale_e03.ts +++ b/ui_template/ui_template_locale_e03.ts @@ -227,7 +227,7 @@ export const ui_locales_e03 = { E03_Pb_Dist: ["분포", "Distribution"], E03_Pb_Dist_normal: ["정규", "Normal"], E03_Pb_Dist_lognormal: ["대수정규", "Lognormal"], - E03_Pb_Spread: ["변동", "Spread"], + E03_Pb_Spread: ["변동계수 · σ", "COV · σ"], E03_Pb_Cov: ["변동계수", "COV"], E03_Pb_Trunc: ["절단 ±σ 배", "Truncate ±kσ"], E03_Pb_Prop_c: ["c kPa", "c kPa"],