import { execAsync } from "ags/process" import { createPoll } from "ags/time" export default function Workspaces() { // Poll the active workspace ID from Hyprland const activeWs = createPoll(1, 250, (prev) => execAsync("hyprctl activeworkspace -j") .then((out) => JSON.parse(out).id as number) .catch(() => prev), ) return ( {Array.from({ length: 9 }, (_, i) => i + 1).map((i) => ( ))} ) }