/** ApplicationsTab — read-only Authentik application directory. */ import { Alert, AlertDescription } from "@/components/ui/alert"; import { Skeleton } from "@/components/ui/skeleton"; import { Table, TableBody, TableCell, TableHead, TableHeader, TableRow, } from "@/components/ui/table"; import { useAuthentikApplications } from "../../hooks/useAuthentik"; import type { ServiceInstance } from "../../types"; export function ApplicationsTab({ instance }: { instance: ServiceInstance }) { const { data, isLoading } = useAuthentikApplications(instance.id); const applications = data?.items ?? []; return (
Application metadata only; providers, outposts, policies, and effective access evaluation are not shown. {data?.error ? ( {data.error} ) : null}
Application Slug Launch URL {isLoading && applications.length === 0 ? ( ) : null} {!isLoading && applications.length === 0 ? ( No applications found. ) : null} {applications.map((application) => ( {application.name} {application.slug || "—"} {application.launch_url || "—"} ))}
{data && data.total > applications.length ? (

Showing the first {applications.length} of {data.total} applications.

) : null}
); }