refactor(gateway): extract node pairing reconciliation

This commit is contained in:
Peter Steinberger
2026-04-01 17:57:59 +09:00
parent 4590ac31cc
commit db0cea5689
17 changed files with 789 additions and 255 deletions

View File

@@ -19,7 +19,7 @@ export function renderPendingPairingRequestsTable(params: {
IP: r.remoteIp ?? "",
Requested:
typeof r.ts === "number" ? formatTimeAgo(Math.max(0, now - r.ts)) : theme.muted("unknown"),
Repair: r.isRepair ? theme.warn("yes") : "",
Repair: r.repairReason ? theme.warn(r.repairReason) : r.isRepair ? theme.warn("yes") : "",
}));
return {
heading: theme.heading("Pending"),
@@ -30,7 +30,7 @@ export function renderPendingPairingRequestsTable(params: {
{ key: "Node", header: "Node", minWidth: 14, flex: true },
{ key: "IP", header: "IP", minWidth: 10 },
{ key: "Requested", header: "Requested", minWidth: 12 },
{ key: "Repair", header: "Repair", minWidth: 6 },
{ key: "Repair", header: "Repair", minWidth: 12 },
],
rows,
}).trimEnd(),