import { type Server } from "node:http"; interface PreviewState { server: Server; port: number; draftSessionId: string; lastActivity: number; publishHandler: () => Promise<{ ok: boolean; slug?: string; url?: string; error?: string; }>; idleInterval: NodeJS.Timeout; /** * Categories pulled from the registry once at preview-server * startup. Drives the