Extend

Command

Component

About

A command menu (cmdk) with search input, grouped items and empty state — ideal for file-type filters and quick pickers.

Built with React and Tailwind. Copy the prompt and paste it into Claude Code, Cursor or Lovable: your agent adds Command to your project and fits it to your theme.

Code

How Command is used: the demo's code. The component's own source comes with a free account.

Usage.tsx

"use client";

import {
  Command,
  CommandEmpty,
  CommandGroup,
  CommandInput,
  CommandItem,
  CommandList,
} from "@/components/ui/command";

export default function Default() {
  return (
    <div className="flex min-h-screen w-full items-center justify-center bg-background p-8">
      <Command className="w-[24rem] rounded-lg border border-border">
        <CommandInput placeholder="Search file types…" />
        <CommandList>
          <CommandEmpty>No file types found.</CommandEmpty>
          <CommandGroup heading="Documents">
            <CommandItem>PDF document</CommandItem>
            <CommandItem>Word document</CommandItem>
            <CommandItem>Spreadsheet</CommandItem>
          </CommandGroup>
          <CommandGroup heading="Images">
            <CommandItem>PNG image</CommandItem>
            <CommandItem>JPEG image</CommandItem>
          </CommandGroup>
        </CommandList>
      </Command>
    </div>
  );
}

Dependencies

More by Extend

View all
  • Bounding Box Citations

    Bounding Box Citations

    51
  • Layout Blocks

    Layout Blocks

    13
  • Color Picker

    Color Picker

    5
  • Autocomplete

    Autocomplete

  • Tooltip

    Tooltip

  • Popover

    Popover

  • Separator

    Separator

  • Input

    Input