Merge remote-tracking branch 'origin/sub_laptop_2' into sub_laptop_1
충돌 셋(UI_Side · UI_Style · locale_m2)은 양쪽을 모두 살려 풂 — 옵션 보이기 · 항목 고르기 문구 · 층 화면 문구를 한 벌로, 도면 양식 줄은 시스템 층에서만.
This commit is contained in:
@@ -25,6 +25,7 @@ import {
|
||||
saveTemplate,
|
||||
StaleError,
|
||||
type Kind,
|
||||
type Layer,
|
||||
type StructureNumbers,
|
||||
type TemplateInfo,
|
||||
} from "./M02_MasterTemplete_Api_Fetch";
|
||||
@@ -60,6 +61,9 @@ const STUB_DRAWING = {
|
||||
};
|
||||
|
||||
export interface SideOptions {
|
||||
/** 이 화면의 층 — 도면 양식 목록은 시스템 층에만 있음 */
|
||||
layer: Layer;
|
||||
/** 이 층을 고칠 수 있나 */
|
||||
isAdmin: boolean;
|
||||
onOpen: (sel: Selection | null) => void;
|
||||
getOpen: () => Selection | null;
|
||||
@@ -88,7 +92,7 @@ const failed = (error: unknown): void =>
|
||||
showToast(L("M02_ActionFailed").replace("{value}", why(error)), "error");
|
||||
|
||||
export function buildSide(opt: SideOptions): SideHandle {
|
||||
const layer = "system" as const;
|
||||
const layer = opt.layer;
|
||||
let items: TemplateInfo[] = [];
|
||||
let columns: StructureColumn[] = [];
|
||||
let numbers: Record<string, StructureNumbers> = {};
|
||||
@@ -151,7 +155,9 @@ export function buildSide(opt: SideOptions): SideHandle {
|
||||
children: [
|
||||
summary,
|
||||
section(options.title, options.body),
|
||||
section(L("M02_KindDrawing"), bodies.get("drawing")!, ...actionRow("drawing")),
|
||||
...(layer === "system"
|
||||
? [section(L("M02_KindDrawing"), bodies.get("drawing")!, ...actionRow("drawing"))]
|
||||
: []),
|
||||
],
|
||||
});
|
||||
attachCollapsible(listHost);
|
||||
|
||||
Reference in New Issue
Block a user