(fid, entry)
| 1091 | |
| 1092 | /* ── UI helpers ─────────────────────────────────────────── */ |
| 1093 | function appendLog(fid, entry) { |
| 1094 | const refs = panelRefs[fid]; |
| 1095 | if (!refs || !entry) return; |
| 1096 | |
| 1097 | const { logBox } = refs; |
| 1098 | |
| 1099 | const line = document.createElement('div'); |
| 1100 | line.className = 'log-line'; |
| 1101 | line.innerHTML = ` |
| 1102 | <span class="log-time">${escHtml(entry.t || nowTime())}</span> |
| 1103 | <span class="log-msg ${escHtml(entry.type || '')}">${entry.msg || ''}</span> |
| 1104 | `; |
| 1105 | |
| 1106 | logBox.appendChild(line); |
| 1107 | logBox.scrollTop = logBox.scrollHeight; |
| 1108 | } |
| 1109 | |
| 1110 | function renderKV(fid, kvMap) { |
| 1111 | const refs = panelRefs[fid]; |
no test coverage detected