{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "source-indicator",
  "title": "Source indicator",
  "description": "A floating pill that reports active field source state over a viewer: nothing selected, a located field path, or a field with no source.",
  "dependencies": [
    "lucide-react@^0.460.0"
  ],
  "registryDependencies": [
    "@retab/utils"
  ],
  "files": [
    {
      "path": "registry/new-york-v4/ui/source-indicator.tsx",
      "content": "\"use client\";\n\nimport * as React from \"react\";\nimport { Search } from \"lucide-react\";\n\nimport { cn } from \"@/lib/utils\";\n\n/**\n * Compact source status row: search icon plus an idle hint, or search icon plus\n * the active source path.\n */\nexport function SourceIndicator({\n  path,\n  emptyHint = \"Hover a field to see its source\",\n  className,\n}: {\n  /** The active field path, or null when nothing is selected. */\n  path: string | null;\n  /** Whether the active field has a resolvable source. */\n  found?: boolean;\n  /** Leading label shown before the path. */\n  label?: string;\n  /** Text shown when no field is active. */\n  emptyHint?: string;\n  className?: string;\n}) {\n  return (\n    <div\n      data-slot=\"source-indicator\"\n      className={cn(\n        \"pointer-events-none flex min-h-8 min-w-0 items-center px-3 py-1.5\",\n        className,\n      )}\n    >\n      <div className=\"flex h-5 max-w-full min-w-0 items-center gap-2 overflow-hidden rounded-[3px] text-xs\">\n        <Search className=\"text-muted-foreground size-3.5 shrink-0\" />\n        {path == null ? (\n          <span className=\"text-muted-foreground truncate\">{emptyHint}</span>\n        ) : (\n          <span className=\"text-foreground truncate font-mono\">{path}</span>\n        )}\n      </div>\n    </div>\n  );\n}\n",
      "type": "registry:ui",
      "target": "@ui/source-indicator.tsx"
    }
  ],
  "type": "registry:ui"
}