{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "latency-badge",
  "type": "registry:ui",
  "title": "Latency badge",
  "description": "A monospace millisecond badge that turns green under 100ms, amber under 400ms and red above. Useful for API monitors, model responses and status dashboards.",
  "dependencies": [],
  "registryDependencies": [
    "utils"
  ],
  "files": [
    {
      "path": "registry/ui/latency-badge.tsx",
      "type": "registry:ui",
      "target": "components/ui/latency-badge.tsx",
      "content": "\"use client\"\nimport * as React from \"react\"\nimport { cn } from \"@/lib/utils\"\n\nfunction LatencyBadge({\n  ms,\n  className,\n}: {\n  ms: number\n  className?: string\n}) {\n  const tone = ms < 100 ? \"text-success\" : ms < 400 ? \"text-warning\" : \"text-danger\"\n  return (\n    <span\n      data-slot=\"latency-badge\"\n      className={cn(\n        \"inline-flex h-5 items-center rounded-md border border-border bg-sunken px-1.5 font-mono text-[11px] tabular-nums\",\n        tone,\n        className\n      )}\n    >\n      {ms}ms\n    </span>\n  )\n}\nexport { LatencyBadge }\n"
    }
  ]
}
