Add comprehensive CSS styles for the MCP Marketplace interface, including card hover effects, responsive grid layout, modal backdrop blur, category badges, rating stars, install buttons, and loading animations. Also include custom scrollbar styling for the model selector to enhance user experience and visual consistency.
23 lines
616 B
TypeScript
23 lines
616 B
TypeScript
import { NextRequest, NextResponse } from "next/server";
|
|
import { searchRemoteModels } from "@/lib/ollama";
|
|
|
|
export async function GET(request: NextRequest) {
|
|
try {
|
|
const { searchParams } = new URL(request.url);
|
|
const query = searchParams.get("q") || undefined;
|
|
|
|
const remoteModels = await searchRemoteModels(query);
|
|
|
|
return NextResponse.json({
|
|
success: true,
|
|
models: remoteModels,
|
|
});
|
|
} catch (error) {
|
|
console.error("Error searching remote models:", error);
|
|
return NextResponse.json(
|
|
{ error: "Failed to search remote models" },
|
|
{ status: 500 }
|
|
);
|
|
}
|
|
}
|