@@ -15,30 +15,26 @@ import type { V0ServerJson } from "@/generated/types.gen";
1515
1616interface ServerCardProps {
1717 server : V0ServerJson ;
18- /**
19- * The MCP server URL
20- */
21- url ?: string ;
18+ serverUrl ?: string ;
2219}
2320
2421/**
2522 * Server card component that displays MCP server information
26- * from the catalog, following the Figma design specifications.
23+ * from the catalog
2724 */
28- export function ServerCard ( { server, url } : ServerCardProps ) {
25+ export function ServerCard ( { server, serverUrl } : ServerCardProps ) {
2926 const { name, description, repository, remotes } = server ;
30- const serverName = name ;
3127 const author = repository ?. id ;
3228 const isVirtualMcp = remotes && remotes . length > 0 ;
3329
3430 const handleCopyUrl = async ( ) => {
35- if ( ! url ) {
31+ if ( ! serverUrl ) {
3632 toast . error ( "URL not available" ) ;
3733 return ;
3834 }
3935
4036 try {
41- await navigator . clipboard . writeText ( url ) ;
37+ await navigator . clipboard . writeText ( serverUrl ) ;
4238 toast . success ( "URL copied to clipboard" ) ;
4339 } catch {
4440 toast . error ( "Failed to copy URL" ) ;
@@ -49,10 +45,10 @@ export function ServerCard({ server, url }: ServerCardProps) {
4945 < Card className = "flex h-full w-full flex-col shadow-none rounded-md" >
5046 < CardHeader className = "gap-2 pb-4" >
5147 < CardTitle className = "text-xl font-semibold leading-7 tracking-tight" >
52- { serverName }
48+ { name }
5349 </ CardTitle >
5450 < CardDescription className = "flex items-center gap-1.5 text-xs leading-5" >
55- < span > { author } </ span >
51+ { author && < span > { author } </ span > }
5652 { isVirtualMcp && (
5753 < Badge variant = "secondary" className = "text-xs" >
5854 Virtual MCP
0 commit comments