fix(720-2): 단가산출 · 일위대가 층 줄 「+」 = 구조물 조합과 같은 자리(줄 오른쪽 끝 m02-tree__tools)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -143,6 +143,8 @@ export function buildLibrarySection(opt: LibraryOptions): LibraryHandle {
|
||||
add.classList.add("m02-tree__add");
|
||||
add.title = L("M02_TreeAddTop");
|
||||
add.setAttribute("aria-label", L("M02_TreeAddTop"));
|
||||
// 구조물 조합 줄과 같은 자리(줄 오른쪽 끝 · `m02-tree__tools`)
|
||||
const addTools = el("span", { className: "ui-toolbar m02-tree__tools", children: [add] });
|
||||
const leaves = new Map<string, HTMLElement>();
|
||||
const toggled = new Map<string, boolean>(); // 손으로 펴고 접은 폴더 — 다시 그려도 그대로
|
||||
const targets = new Map<string, Target>();
|
||||
@@ -470,7 +472,7 @@ export function buildLibrarySection(opt: LibraryOptions): LibraryHandle {
|
||||
const mine = ++seq;
|
||||
const at = opt.scope();
|
||||
add.hidden = !at.canWrite;
|
||||
barHost.replaceChildren(opt.bar(add));
|
||||
barHost.replaceChildren(opt.bar(addTools));
|
||||
if (!keep) treeHost.replaceChildren(createEmpty({ text: tc("Loading"), small: true }));
|
||||
const [got, tree] = await Promise.all([
|
||||
// 못 받으면 빈 나무(목록표에서 까닭) · 폴더를 못 받으면 문서는 모두 뿌리
|
||||
|
||||
@@ -64,7 +64,7 @@ def test_화면_층_단추_최상위_폴더_이름_바꾸기():
|
||||
# 720-2 — 층 줄 「+」 = 서고 칸 맨 위 메뉴 · 메뉴 줄 = 같은 addFolder([])
|
||||
assert page.count(" add,\n") == 3 # 구조물 조합 · 일위대가 · 단가산출
|
||||
assert "onClick: (event) => openTreeMenu(event, menuAt([]))" in lib
|
||||
assert "add.hidden = !at.canWrite;" in lib and "opt.bar(add)" in lib
|
||||
assert "add.hidden = !at.canWrite;" in lib and "opt.bar(addTools)" in lib
|
||||
assert lib.count('L("M02_TreeAddTopFolder"), () => void addFolder([])') == 1 # 폴더 줄
|
||||
assert '{ label: L("M02_TreeAddTopFolder"), run: () => void addFolder([])' in lib # 문서 줄
|
||||
tree = _text("M02_MasterTemplete_TreePanel.ts")
|
||||
|
||||
Reference in New Issue
Block a user