Coral Compose
A copy-paste block that recreates the Coral prompt stage with Cohere's rail, brand mark, prompt surface, model menu, and tool toggles. The block is not a package component: copy the file, or install it with the shadcn CLI, then edit the layout like any other file in your project. It is assembled entirely from Agent UI compose primitives, and every control is keyboard accessible.
Source you own: install the block with the shadcn CLI or copy components/blocks/composes/cohere-compose.tsx. The preview below is the real file, and the code tab is the exact source.
How can I help you today?
Chat with Command, grounded in your enterprise data.
By signing up, you agree to the Terms of Use and Privacy Policy.
Cohere can make mistakes. Check important info.
The code tab contains the full block, ready to copy.
Installation
Add the block with the shadcn CLI. It writes components/blocks/composes/cohere-compose.tsx and installs its dependencies.
npx shadcn@latest add https://agent-ui-27t.pages.dev/r/cohere-compose.jsonPrefer to own the file manually? Install the dependencies, then copy the source from the Files section.
pnpm add @agent-ui/react lucide-reactTailwind CSS v4 users: add @source "../node_modules/@agent-ui/react/src" to the global stylesheet so the library utilities are generated.
Usage
Import the copied file and render it anywhere. The block accepts onSend, disabled, and className; wire onSend to any backend.
import { CohereCompose } from "@/components/blocks/composes/cohere-compose"; <CohereCompose onSend={(text) => console.log(text)} />Files
One file. The same source is served by the shadcn registry endpoint, so the CLI and the docs can never drift.
components/blocks/composes/cohere-compose.tsxtsx"use client"; import * as React from "react";import { ArrowRight, Plus } from "lucide-react";import { ComposeSendButton, ComposeTextarea, ModelChip, createCompose, type ComposeProps,} from "@agent-ui/react"; const Root = createCompose({ id: "cohere", maxWidth: "max-w-none", placeholder: "Message Command", models: [ { id: "command-r-plus", name: "Command R+", hint: "Best quality" }, { id: "command-r", name: "Command R", hint: "Fast" }, { id: "command-a", name: "Command A", hint: "Agentic" }, ],}); /** Cohere Coral: chalk canvas, editorial serif, sea-green + coral, soft 3D pebbles. */function CohereComposeLayout() { return ( <div className="relative flex min-h-[400px] w-full flex-col overflow-hidden bg-[#f2f1ee] px-6 pb-5 pt-4 text-[13px] text-[#212121]"> <div aria-hidden="true" className="pointer-events-none absolute -left-6 top-24 h-20 w-20 rotate-12 rounded-[38%] bg-[radial-gradient(circle_at_30%_30%,#8fd3c7,#39594d_70%)] opacity-70 blur-[1px]" /> <div aria-hidden="true" className="pointer-events-none absolute -right-4 top-16 h-16 w-16 -rotate-12 rounded-[40%] bg-[radial-gradient(circle_at_35%_30%,#ffb59d,#e4552f_75%)] opacity-80 blur-[1px]" /> <div aria-hidden="true" className="pointer-events-none absolute -right-2 bottom-24 h-14 w-14 rotate-45 rounded-[42%] bg-[radial-gradient(circle_at_35%_30%,#f9a8d4,#7c3aed_80%)] opacity-60 blur-[1px]" /> <div className="relative flex items-center gap-1.5"> <span className="flex items-end gap-0.5" aria-hidden="true"> <span className="h-2.5 w-2.5 rounded-full bg-[#39594d]" /> <span className="h-2 w-2 rounded-full bg-[#e4552f]" /> </span> <span className="-ml-0.5 text-[15px] font-semibold tracking-[-0.03em] text-[#39594d]"> cohere </span> <button type="button" className="ml-auto text-[10.5px] text-[#39594d]"> Sign Up </button> </div> <div className="relative my-auto mx-auto w-full max-w-[420px] rounded-md border border-[#d8d6cf] bg-white px-6 py-5 shadow-[0_2px_10px_rgba(57,89,77,0.06)]"> <h1 className="text-center font-serif text-[25px] tracking-[-0.01em]"> How can I help you today? </h1> <p className="mt-1 text-center text-[10.5px] text-[#6b6b64]"> Chat with Command, grounded in your enterprise data. </p> <div data-agent-id="compose-card" className="mt-4 flex flex-col rounded-md border border-[#c9c7bf] bg-white transition-shadow duration-200 focus-within:border-[#39594d]/60 focus-within:shadow-[0_4px_16px_rgba(57,89,77,0.12)]" > <ComposeTextarea aria-label="Message Command" placeholder="Message Command" rows={2} className="min-h-[42px] px-3 py-2 text-[13.5px] leading-6 placeholder:text-[#9b9b93]" /> <div className="flex items-center justify-between border-t border-[#e6e4dd] px-2 py-1.5"> <button type="button" aria-label="Attach" className="grid h-6 w-6 place-items-center rounded text-[#6b6b64] hover:bg-[#f2f1ee]" > <Plus className="h-3.5 w-3.5" aria-hidden="true" /> </button> <div className="flex items-center gap-1.5"> <ModelChip tone="light" className="[&>button]:h-6 [&>button]:px-1 [&>button]:text-[10.5px] [&>button]:text-[#6b6b64] [&>button]:hover:bg-[#f2f1ee]" /> <ComposeSendButton aria-label="Send message" className="h-6 rounded-sm bg-[#39594d] px-3 text-[10.5px] font-medium text-white hover:bg-[#2c463c] disabled:bg-[#c9d3cd] disabled:text-white disabled:opacity-100" icon={<ArrowRight className="h-3 w-3" aria-hidden="true" />} /> </div> </div> </div> <p className="mt-3 text-center text-[9px] leading-snug text-[#8a8a82]"> By signing up, you agree to the{" "} <a href="#" className="underline"> Terms of Use </a>{" "} and{" "} <a href="#" className="underline"> Privacy Policy </a> . </p> </div> <p className="relative text-center text-[9px] text-[#9b9b93]"> Cohere can make mistakes. Check important info. </p> </div> );} export function CohereCompose(props: ComposeProps) { return ( <Root {...props}> <CohereComposeLayout /> </Root> );} Built with
The block imports these Agent UI primitives. Each one is a package export with its own docs page, so you can change the layout without giving up the behaviour.
Accessibility
Coral also has a full product page.
Metadata, model list, and the same block in a dedicated route.
CohereCompose composes with MessageList, ChatShell, useChat, and the provider compose blocks. Browse the full reference or see all components in the gallery.
121 lines · copy-ready