Integration Picker
The integrations page of a command menu: search with highlighted matches, Connected, Popular and All, and the service you are on shown beside your app on two tiles. Connecting moves through signing in, connected and failed with Retry. Use it in a card, your own panel, or the ⌘K-style IntegrationPickerDialog.
The decision inside it
Permissions before the sign-in jump
The details list what the app will be able to do, with changes marked apart from reads, right above a button that says where it sends you. A service that is already connected never offers Connect again: it says which account it uses.
When to use it
Use Integration Picker to let someone find and connect one service: search, Connected / Popular / All, and a connect step that lists what the app will be able to do before the sign-in. Use IntegrationPickerDialog for a ⌘K-style dialog, and App Directory for a full browsing page. Pass each service's logo yourself.
Installation
How you get it
Paste this into Claude Code, Cursor, Codex or any coding agent. It installs the file and uses it as it is, instead of writing a new one.
Use Layro's Integration Picker for this.
Install it: npx shadcn@latest add @layro/integration-picker
(the @layro registry is set up in components.json, with LAYRO_KEY in .env.local)
Import it from @/components/ui/integration-picker.
Do not rewrite or restyle it. Pass my data through its props
and keep its built-in states.For the full brief with every prop and the mistakes assistants usually make, use Copy prompt above. Pro components install through the @layro registry with your CLI token: see the Namespaced tab.
Usage
import { IntegrationPicker, type IntegrationService } from "@/components/ui/integration-picker";
const services: IntegrationService[] = [
{
id: "tracker", name: "Tracker", category: "Project management", domain: "tracker.example",
permissions: ["Read issues and comments", { label: "Create issues", access: "write" }],
popular: true,
},
{ id: "chat", name: "Chat", category: "Messaging", permissions: [{ label: "Post messages", access: "write" }] },
];
export function ConnectIntegration({ connected, connect, disconnect }: {
connected: Record<string, string>;
connect: (id: string) => Promise<string>;
disconnect: (id: string) => Promise<void>;
}) {
return (
<IntegrationPicker
app={{ name: "Layro" }}
services={services}
connected={connected}
onConnect={connect}
onDisconnect={disconnect}
/>
);
}API reference
“Copy prompt” above puts a full brief on your clipboard — install command, dependencies, props, and the mistakes an assistant usually makes with this component.
Props
Read from the component’s own TypeScript interface when the site is built, so this table cannot drift from the file you install.
| Prop | Type | Notes |
|---|---|---|
servicerequired | Pick<IntegrationService, "name" | "icon" | "logoUrl" | "color"> & { logo?: React.ReactNode } | — |
size | number | Pixels. Default 36. |
Dependencies
npm packages
@radix-ui/react-dialogclsxcmdkframer-motionlucide-reacttailwind-mergeLayro foundations, installed alongside it
layro-themebuttonStates
All of them are drawn by the component. None is left for you to design.
- Browsing
- Searching
- Connecting
- Connected
- Connect failed
- Disconnecting
- In a dialog
Accessibility
- Keyboard reachable throughout, in visual order
- Focus trapped in overlays, Escape closes them
- Focus returns to whatever opened it
- Live regions announce what changed, not that something did
- Honours prefers-reduced-motion
Responsive behavior
- Sizes to its container, not the viewport
- Usable from 320px up
- Pointer-based interaction, so trackpad and touch both work
- No hover-only affordances
Used in screensAll screens
Lifetime access
Every component, and everything we ship next.
- All 232 components, source included
- Every template, and everything released after you buy
- shadcn CLI or download — React 18/19, Tailwind v4
- One payment. No subscription.