"use client"; import Link from "next/link"; import Image from "next/image"; import type { CliCatalogEntry } from "@/shared/schemas/cliCatalog"; import type { ToolBatchStatus } from "@/shared/types/cliBatchStatus"; import CliStatusBadge from "@/app/(dashboard)/dashboard/cli-code/components/CliStatusBadge"; import { cn } from "@/shared/utils/cn"; export interface CliToolCardProps { tool: CliCatalogEntry; batchStatus: ToolBatchStatus | null; detailHref: string; hasActiveProviders: boolean; } export default function CliToolCard({ tool, batchStatus, detailHref, hasActiveProviders, }: CliToolCardProps) { const installed = batchStatus?.detection.installed ?? false; const configStatus = batchStatus?.config.status ?? null; const version = batchStatus?.detection.version ?? "not found"; const endpoint = batchStatus?.config.endpoint ?? null; const showInstallChips = !installed && tool.configType !== "guide"; const title = (
{tool.description}