import { Star, Download, Terminal, ChevronRight, Info } from "lucide-react"; import { Badge } from "@site/src/components/ui/badge"; import { Button } from "@site/src/components/ui/button"; import type { MCPServer } from "@site/src/types/server"; import Link from "@docusaurus/Link"; import { useState } from "react"; import { motion, AnimatePresence } from "framer-motion"; import { getGooseInstallLink } from "@site/src/utils/install-links"; export function ServerCard({ server }: { server: MCPServer }) { const [isCommandVisible, setIsCommandVisible] = useState(false); return (
{server.name}

{server.description}

{server.is_builtin && (
Can be enabled in the goose settings page
)} {(!server.is_builtin && server.command !== undefined && server.url === undefined) && ( <> {isCommandVisible && ( {`goose session --with-extension "${server.command}"`} )} )} {(!server.is_builtin && server.command === undefined && server.url !== undefined) && ( <> {isCommandVisible && ( {`goose session --with-remote-extension "${server.url}"`} )} )}
{server.githubStars !== undefined && ( e.stopPropagation()} > {server.githubStars} on Github )}
{server.is_builtin ? (
Built-in
) : ( Install )}
); }