laguagu/claude-code-nextjs-skills / skills/nextjs-chatbot
nextjs-chatbot
VerifiedProduction Next.js web-chat integration: tool approval, persisted conversations, tool result UI, grounded retrieval, follow-up suggestions and embedded widgets. Use when building or debugging a web chatbot that needs these features. Use nextjs-shadcn for scaffolding and ai-sdk for general SDK APIs; multi-platform bots use Chat SDK.
| File | Kind | Size |
|---|---|---|
| SKILL.md | skill md | 5.6 KB |
| hitl.md | markdown | 4.1 KB |
| persistence.md | markdown | 4.0 KB |
| popup-widget.md | markdown | 1.6 KB |
| search.md | markdown | 1.8 KB |
| suggestions.md | markdown | 1.4 KB |
| testing.md | markdown | 2.2 KB |
| tool-rendering.md | markdown | 1.7 KB |
| web-search.md | markdown | 1.6 KB |
popup-widget.md
View on GitHub# Popup and embedded chat
Choose a full page, inline panel, popup or iframe from the host application's
needs. A widget does not require a Lottie cue, decorative glow, hidden scrollbar
or permanently visible prompt chips.
Keep the composer reachable while history scrolls. A flex/grid chain with
bounded height and `min-height: 0` on the scrolling child prevents messages from
pushing the input out of the panel. Test narrow screens, virtual keyboards,
long tool results and safe-area insets.
Give the launcher an accessible name and clear open state. Opening/closing
must manage focus appropriately; provide keyboard dismissal and return focus
to the launcher when relevant. Announce useful state without reading every
streamed token.
## Embedding boundary
An iframe isolates styles, but adds a cross-origin integration contract.
Configure permitted embedding origins with CSP `frame-ancestors`; account for
other frame restrictions and the application's authentication/cookie policy.
Do not loosen the whole application's policy solely for a widget.
Validate `postMessage` origins and message shapes on both sides; use a specific
target origin. Never treat a parent-supplied user, tenant, consent or API key as
trusted without server validation.
A loader script should mount once, avoid conflicting host styles and expose a
deliberate open/close/unmount interface. Keep secrets server-side. Verify the
real host page, permitted and rejected origins, keyboard flow, mobile layout
and streaming through the deployed proxy.
Use `nextjs-shadcn` for visual decisions and
[persistence.md](persistence.md) for conversation lifetime.
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| brainstormingobra/superpowersYou MUST use this before any creative work - creating features, building components, adding functionality, modifying behavior, or planning anything new, in software or out of it (a talk, a business, a renovation). | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| brand-guidelinesanthropics/skillsApplies Anthropic's official brand colors and typography to any sort of artifact that may benefit from having Anthropic's look-and-feel. Use it when brand colors or style guidelines, visual formatting, or company design standards apply. | Stars: 198k | Updated | Claude CodeCodex | Verified | Install |
| frontend-designanthropics/skillsGuidance for distinctive, intentional visual design when building new UI or reshaping an existing one. Helps with aesthetic direction, typography, and making choices that don't read as templated defaults. | Stars: 198k | Updated | Claude CodeCodex | Verified | Install |
| mcp-builderanthropics/skillsGuide for creating high-quality MCP (Model Context Protocol) servers that enable LLMs to interact with external services through well-designed tools. Use when building MCP servers to integrate external APIs or services, whether in Python (FastMCP) or Node/TypeScript (MCP SDK). | Stars: 198k | Updated | Claude CodeCodex | Verified | Install |