- Servers can say what they run on (or it is worked out from the Proxmox node); when the host is down the guests' offline alerts fold under it: held back, not counted, not notified, still recorded. - Recurring maintenance schedules made into ordinary windows a week ahead (maintenance_schedules). - Run a Semaphore template limited to a server from its page or an alert, and watch the run. - Agents report pending updates (apt, dnf, zypper, Windows Update); an Updates page lists them. - Migrations 0024 and 0025. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
39 lines
1.6 KiB
TypeScript
39 lines
1.6 KiB
TypeScript
// The keyboard shortcuts: "g" then a letter goes to a page (like GitHub's), "/" jumps to the search box, "?" lists them all.
|
|
// One list, so the handler, the help dialog and the command palette's hints can't drift apart.
|
|
|
|
export interface GoShortcut {
|
|
/** The letter after "g". */
|
|
key: string;
|
|
to: string;
|
|
label: string;
|
|
}
|
|
|
|
export const GO_SHORTCUTS: GoShortcut[] = [
|
|
{ key: "d", to: "/", label: "Dashboard" },
|
|
{ key: "a", to: "/alerts", label: "Alerts" },
|
|
{ key: "s", to: "/servers", label: "Servers" },
|
|
{ key: "m", to: "/maintenance", label: "Maintenance" },
|
|
{ key: "u", to: "/updates", label: "Updates" },
|
|
{ key: "i", to: "/integrations", label: "Integrations" },
|
|
{ key: "k", to: "/secrets", label: "Secrets" },
|
|
{ key: "p", to: "/map", label: "Map" },
|
|
{ key: "w", to: "/wall", label: "Wall display" },
|
|
];
|
|
|
|
export const OTHER_SHORTCUTS: { keys: string; label: string }[] = [
|
|
{ keys: "Ctrl K", label: "Search, and run actions (silence a server, switch theme…)" },
|
|
{ keys: "/", label: "Jump to the search box of the table on this page" },
|
|
{ keys: "j / k", label: "Move down or up the rows of the table on this page (Enter opens the row)" },
|
|
{ keys: "[", label: "Narrow the sidebar to icons, or widen it again" },
|
|
{ keys: "?", label: "Show this list" },
|
|
{ keys: "Esc", label: "Close a dialog, the search or this list" },
|
|
];
|
|
|
|
/** The "g x" hint for a page, if it has one — shown beside it in the command palette. */
|
|
export function shortcutHintFor(to: string): string | null {
|
|
const found = GO_SHORTCUTS.find((s) => s.to === to);
|
|
return found ? `g ${found.key}` : null;
|
|
}
|
|
|
|
export const SHOW_SHORTCUTS_EVENT = "show-shortcuts";
|