feat(ui): 공용 호버 정보 양식 · B09 칸 풍선을 새 호버로(185-3)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01STqEqztUthVFBmEP18wBSz
This commit is contained in:
2026-10-10 12:59:16 +09:00
co-authored by Claude Opus 5.5
parent 9483c19ad3
commit 3b81fc61ff
4 changed files with 357 additions and 9 deletions
+10 -9
View File
@@ -20,6 +20,7 @@ import {
} from "@ui/ui_template_elements";
import { attachCollapsible } from "@ui/ui_template_collapsible";
import { createDataTable, type DataTable } from "@ui/ui_template_data_table";
import { attachHoverInfo } from "@ui/ui_template_hover_info";
import { ui_locales, currentLanguageIndex } from "@ui/ui_template_locale";
import { clearState, readState, writeState } from "../A00_Common/b_page_state";
import { workflowSteps } from "../A00_Common/b_page_scaffold";
@@ -227,16 +228,16 @@ export function renderB09Estimation(root: HTMLElement): void {
const box = cell.getBoundingClientRect();
openMenuAt(box.left, box.bottom, items);
});
// 157-3 칸 풍선 — 공용 표는 그대로 · 올린 칸에 title
// 157-3 칸 풍선 — 공용 표는 그대로 · 올린 칸에 공용 호버 정보(185-3)
if (spec.tip)
made.root.addEventListener("mouseover", (event) => {
const cell = (event.target as Element).closest<HTMLTableCellElement>("tr[data-i] td");
const row = cell?.parentElement;
const column = cell ? spec.columns[cell.cellIndex] : undefined;
if (!cell || !row || !column) return;
const tip = spec.tip?.(Number(row.dataset.i), column.key);
if (tip) cell.title = tip;
});
attachHoverInfo(
made.root,
(cell) => {
const column = spec.columns[(cell as HTMLTableCellElement).cellIndex];
return column && spec.tip?.(Number(cell.parentElement?.dataset.i), column.key);
},
"tr[data-i] td",
);
return made;
};
const hint = spec.hint ? note(spec.hint) : null;