feat: SSH card UX, agent version sync, persistent ssh_admin_ok (0.11.5)
Silent SSH probe on host card open; manual test feedback auto-hides. Persist ssh_admin_ok in DB (migration 019). After agent update read version from host and refresh UI.
This commit is contained in:
@@ -0,0 +1,16 @@
|
||||
import type { HostDetail } from "../api";
|
||||
|
||||
type HostPatchListener = (detail: HostDetail) => void;
|
||||
|
||||
const listeners = new Set<HostPatchListener>();
|
||||
|
||||
export function subscribeHostPatch(listener: HostPatchListener): () => void {
|
||||
listeners.add(listener);
|
||||
return () => listeners.delete(listener);
|
||||
}
|
||||
|
||||
export function emitHostPatch(detail: HostDetail): void {
|
||||
for (const listener of listeners) {
|
||||
listener(detail);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user