10 lines
826 B
JavaScript
10 lines
826 B
JavaScript
export function renderHalPanel(document, manifest = {}, graph = []) {
|
|
const section = document.createElement("section"); section.className = "panel hal-panel";
|
|
const title = document.createElement("h2"); title.className = "panel-title"; title.textContent = "HAL diagnostics"; section.append(title);
|
|
const summary = document.createElement("p"); summary.className = "status-line"; summary.textContent = `${manifest.components ?? 0} components | ${graph.length} graph records`; section.append(summary);
|
|
const list = document.createElement("ul"); list.className = "hal-list";
|
|
for (const row of (manifest.blocked ?? []).slice(0, 8)) { const item = document.createElement("li"); item.textContent = `${row.code ?? "blocked"}: ${row.path ?? "HAL resource"}`; list.append(item); }
|
|
section.append(list);
|
|
return section;
|
|
}
|