All checks were successful
Deploy to Production / deploy (push) Successful in 1m28s
- /oauth/register: drop resource_required check, accept generic registrations (Claude Desktop omits resource in DCR body per spec). serverId stored as NULL; /authorize still enforces org-ownership + access-token aud claim still pinned to resource. Fixes Claude Desktop DCR failure (ofid_d7e39530c109fa7f). - /oauth/authorize: skip strict server.id check when client.serverId is NULL (generic client); org check remains the security boundary. - schema: oauth_clients.server_id no longer NOT NULL. - migration 0002: ALTER COLUMN server_id DROP NOT NULL (already applied on prod). - install-snippets: add Claude Code (CLI), VS Code, Codex, raw URL tabs. Claude Desktop now shows form-field values (Name / Remote MCP Server URL / OAuth Client ID / Secret) matching the new Custom Connector UI instead of the obsolete JSON config. - types: InstallTarget enum extended. - hero-video: clicking the audio toggle restarts the video from frame 0 so unmute aligns with the spoken opening. - marketing: drop em-dashes from rendered copy.
53 lines
1.7 KiB
TypeScript
53 lines
1.7 KiB
TypeScript
'use client';
|
|
|
|
import { useState } from 'react';
|
|
import { buildSnippet, type SnippetInput } from '@/lib/install-snippets';
|
|
import { CodeBlock } from './code-block';
|
|
import { cn } from '@/lib/cn';
|
|
import type { InstallTarget } from '@bmm/types';
|
|
|
|
const TABS: { id: InstallTarget; label: string }[] = [
|
|
{ id: 'claude-desktop', label: 'Claude Desktop' },
|
|
{ id: 'claude-code', label: 'Claude Code' },
|
|
{ id: 'cursor', label: 'Cursor' },
|
|
{ id: 'vscode', label: 'VS Code' },
|
|
{ id: 'chatgpt', label: 'ChatGPT' },
|
|
{ id: 'codex', label: 'Codex' },
|
|
{ id: 'raw-url', label: 'Other' },
|
|
];
|
|
|
|
export function InstallSnippets({ input }: { input: SnippetInput }) {
|
|
const [tab, setTab] = useState<InstallTarget>('claude-desktop');
|
|
const snippet = buildSnippet(tab, input);
|
|
return (
|
|
<div>
|
|
<div className="flex flex-wrap gap-1 border-b border-[--color-border]">
|
|
{TABS.map((t) => (
|
|
<button
|
|
key={t.id}
|
|
type="button"
|
|
onClick={() => setTab(t.id)}
|
|
className={cn(
|
|
'relative px-3 py-2 text-[12.5px] transition-colors duration-200 ease-out',
|
|
tab === t.id
|
|
? 'text-[--color-fg]'
|
|
: 'text-[--color-fg-muted] hover:text-[--color-fg]',
|
|
)}
|
|
>
|
|
{t.label}
|
|
{tab === t.id && (
|
|
<span className="absolute inset-x-0 -bottom-px h-px bg-[--color-fg]" />
|
|
)}
|
|
</button>
|
|
))}
|
|
</div>
|
|
<div className="pt-4">
|
|
<CodeBlock label={snippet.label} code={snippet.code} />
|
|
{snippet.note && (
|
|
<p className="mt-2 text-[12px] leading-relaxed text-[--color-fg-muted]">{snippet.note}</p>
|
|
)}
|
|
</div>
|
|
</div>
|
|
);
|
|
}
|