Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
117 changes: 87 additions & 30 deletions app/_components/guide-overview.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -34,37 +34,22 @@ export function GuideOverview({ children, className }: GuideOverviewProps) {
className
)}
>
{/* Outcomes section (full width) */}
{outcomes && (
<div className="mb-6">
<h2 className="mb-3 font-semibold text-card-foreground text-xl">
Outcomes
</h2>
<div className="text-muted-foreground">
{React.isValidElement(outcomes) &&
(outcomes.props as { children: React.ReactNode }).children}
</div>
</div>
)}

{/* Two column layout - You will Learn (2/3) and Prerequisites (1/3) */}
<div className="grid gap-6 md:grid-cols-3">
{/* You will Learn column - takes 2/3 of width */}
{youWillLearn && (
<div className="md:col-span-2">
<h3 className="mb-3 font-medium text-card-foreground text-lg">
You will Learn
</h3>
<div className="space-y-2 text-muted-foreground text-sm">
{React.isValidElement(youWillLearn) &&
(youWillLearn.props as { children: React.ReactNode }).children}
{/* When only Outcomes and Prerequisites exist, show them side by side */}
{outcomes && prerequisites && !youWillLearn && (
<div className="grid gap-6 md:grid-cols-2">
{/* Outcomes column */}
<div>
<h2 className="mb-3 font-semibold text-card-foreground text-xl">
Outcomes
</h2>
<div className="text-muted-foreground">
{React.isValidElement(outcomes) &&
(outcomes.props as { children: React.ReactNode }).children}
</div>
</div>
)}

{/* Prerequisites column - takes 1/3 of width */}
{prerequisites && (
<div className="md:col-span-1">
{/* Prerequisites column */}
<div>
<h3 className="mb-3 font-medium text-card-foreground text-lg">
Prerequisites
</h3>
Expand All @@ -73,8 +58,80 @@ export function GuideOverview({ children, className }: GuideOverviewProps) {
(prerequisites.props as { children: React.ReactNode }).children}
</div>
</div>
)}
</div>
</div>
)}

{/* When YouWillLearn exists, use the original layout */}
{youWillLearn && (
<>
{/* Outcomes section (full width) */}
{outcomes && (
<div className="mb-6">
<h2 className="mb-3 font-semibold text-card-foreground text-xl">
Outcomes
</h2>
<div className="text-muted-foreground">
{React.isValidElement(outcomes) &&
(outcomes.props as { children: React.ReactNode }).children}
</div>
</div>
)}

{/* Two column layout - You will Learn (2/3) and Prerequisites (1/3) */}
<div className="grid gap-6 md:grid-cols-3">
{/* You will Learn column - takes 2/3 of width */}
<div className="md:col-span-2">
<h3 className="mb-3 font-medium text-card-foreground text-lg">
You will Learn
</h3>
<div className="space-y-2 text-muted-foreground text-sm">
{React.isValidElement(youWillLearn) &&
(youWillLearn.props as { children: React.ReactNode })
.children}
</div>
</div>

{/* Prerequisites column - takes 1/3 of width */}
{prerequisites && (
<div className="md:col-span-1">
<h3 className="mb-3 font-medium text-card-foreground text-lg">
Prerequisites
</h3>
<div className="space-y-2 text-muted-foreground text-sm">
{React.isValidElement(prerequisites) &&
(prerequisites.props as { children: React.ReactNode })
.children}
</div>
</div>
)}
</div>
</>
)}

{/* Fallback for edge cases - only outcomes, only prerequisites, etc. */}
{outcomes && !prerequisites && !youWillLearn && (
<div>
<h2 className="mb-3 font-semibold text-card-foreground text-xl">
Outcomes
</h2>
<div className="text-muted-foreground">
{React.isValidElement(outcomes) &&
(outcomes.props as { children: React.ReactNode }).children}
</div>
</div>
)}

{!outcomes && prerequisites && !youWillLearn && (
<div>
<h3 className="mb-3 font-medium text-card-foreground text-lg">
Prerequisites
</h3>
<div className="space-y-2 text-muted-foreground text-sm">
{React.isValidElement(prerequisites) &&
(prerequisites.props as { children: React.ReactNode }).children}
</div>
</div>
)}
</div>
);
}
Expand Down
26 changes: 13 additions & 13 deletions app/en/home/mcp-clients/cursor/page.mdx
Original file line number Diff line number Diff line change
@@ -1,29 +1,31 @@
import { Steps, Callout } from "nextra/components";
import { SignupLink } from "@/app/_components/analytics";


# Use Arcade in Cursor

In this guide, you'll learn how to connect Cursor to an Arcade MCP Gateway.
<GuideOverview>
<GuideOverview.Outcomes>

Connect Cursor to an Arcade MCP Gateway.

<Steps>
</GuideOverview.Outcomes>

### Prerequisites
<GuideOverview.Prerequisites>

1. Create an <SignupLink linkLocation="docs:claude-desktop-client">Arcade account</SignupLink>
2. Get an [Arcade API key](/home/api-keys)
3. Create an [Arcade MCP Gateway](/home/mcp-gateways) and select the tools you want to use

</GuideOverview.Prerequisites>

</GuideOverview>

### Set up Cursor

3. Download and open [Cursor](https://cursor.com/download)
4. Open the command palette and select **Open MCP Settings...**
5. Choose **HTTP**
6. Paste the URL of your MCP Gateway
7. Give your MCP server a name, like `mcp-arcade`
8. Add the API key as the bearer token within the `Authorization` header, and the email address that you used to sign up for the Arcade account as the `Arcade-User-ID` header
1. Open the Command Palette (`Cmd + Shift + P` on macOS, `Ctrl + Shift + P` on Windows/Linux) and select **Open MCP Settings**
1. Click on the "New MCP Server" button

Cursor will update your `settings.json` file with the following
Cursor will open the MCP settings file, and you can add a new entry to the `mcpServers` object:

```json
{
Expand All @@ -44,5 +46,3 @@ Cursor will update your `settings.json` file with the following
1. Open the chat pane (typically command-l)
1. Make sure you are in **Agent** mode
1. Ask the agent to use a tool!

</Steps>