Skip to content

armgit / Pulse

Public Imported from GitHub
0

Real-time monitoring dashboard for Proxmox VE, PBS, Docker, Kubernetes, TrueNAS and vSphere. Self-hosted, with alerts for failed backups, full disks, unhealthy containers and offline nodes.

484 B
Raw Blame
export type TableSortDirection = 'asc' | 'desc';

/**
 * Canonical visual sort marker for table headers.
 *
 * Inactive headers remain discoverable through their button semantics instead
 * of repeating a dormant icon in every column. Only the active column needs a
 * direction marker.
 */
export function getTableSortIndicator(
  active: boolean,
  direction: TableSortDirection,
): '▲' | '▼' | null {
  if (!active) return null;
  return direction === 'asc' ? '▲' : '▼';
}