feat(M01): 테스트 컨테이너 고르기 부품 공용화 — 구분 → 상세구분 → 후보 거름 · B·C 에도 재료 바꿔 보기

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_016WRFJmmhPi4exAzHgPZHMT
This commit is contained in:
2026-09-20 22:14:22 +09:00
co-authored by Claude Sonnet 5
parent 35588d9aa5
commit 03e6b6511e
8 changed files with 216 additions and 84 deletions
+14 -1
View File
@@ -23,6 +23,8 @@ import {
type FlowColumn,
type FlowKind,
} from "./M01_MasterData_UI_Test_C_Model";
import { hasPickable, pickPanel, swappedRow, type Swaps } from "./M01_MasterData_UI_Test_Pick";
import { tt } from "./M01_MasterData_UI_Test_Text";
import "./M01_MasterData_UI_Test_C_Style.css";
const TEXT = {
@@ -69,6 +71,8 @@ function mount(host: HTMLElement, one: LogicOne): void {
for (const spec of row. ?? []) {
if (spec.?.length) values[spec.] = String(spec.[0]);
}
const swaps: Swaps = new Map();
const picker = pickPanel(one, swaps, () => run());
const open = new Set<string>();
const subs = new Map<string, LogicRow>();
let answer: CalcAnswer | null = null;
@@ -178,7 +182,8 @@ function mount(host: HTMLElement, one: LogicOne): void {
inputs[spec.] =
option !== undefined ? option : Number.isNaN(Number(raw)) ? raw : Number(raw);
}
void runCalc({ key: row.키, inputs })
const swapped = swappedRow(row, swaps);
void runCalc({ key: row.키, inputs, ...(swapped ? { row: swapped, file: one.file } : {}) })
.then((got) => {
answer = got;
redraw();
@@ -208,6 +213,14 @@ function mount(host: HTMLElement, one: LogicOne): void {
? [el("p", { className: "m01c__bad", text: one.reasons.join(" · ") })]
: []),
stopped,
...(hasPickable(row)
? [
el("details", {
attrs: { open: "" },
children: [el("summary", { text: tt("Mat_Title") }), picker],
}),
]
: []),
el("div", {
className: "m01c__flow",
children: [inputColumn(row, values, later), rest],