[feat](trx-frontend-http): add Plugins tab showing registered frontends
Add GET /frontends API endpoint returning registered frontend names as JSON. Add Plugins tab to the web UI that fetches and displays the list. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
This commit is contained in:
@@ -615,6 +615,18 @@ document.querySelector(".tab-bar").addEventListener("click", (e) => {
|
||||
|
||||
connect();
|
||||
|
||||
// --- Plugins tab ---
|
||||
fetch("/frontends").then(r => r.json()).then(names => {
|
||||
const list = document.getElementById("plugins-list");
|
||||
if (!Array.isArray(names) || names.length === 0) {
|
||||
list.innerHTML = '<div class="plugin-item" style="color:var(--text-muted);">No frontends registered</div>';
|
||||
return;
|
||||
}
|
||||
list.innerHTML = names.map(n => `<div class="plugin-item">${n}</div>`).join("");
|
||||
}).catch(err => {
|
||||
console.error("Failed to fetch frontends", err);
|
||||
});
|
||||
|
||||
// --- Signal measurement ---
|
||||
const sigMeasureBtn = document.getElementById("sig-measure-btn");
|
||||
const sigClearBtn = document.getElementById("sig-clear-btn");
|
||||
|
||||
Reference in New Issue
Block a user