import { jsxs, jsx } from "react/jsx-runtime";
import * as React from "react";
import { Badge } from "../badge/badge.js";
import { c as cn } from "../../cn-FAaWYZ6x.js";
const Status = React.forwardRef(
  ({ className, variant = "secondary", label, pulse = false, ...props }, ref) => {
    const indicatorColors = {
      default: "bg-accent",
      secondary: "bg-gray-400",
      success: "bg-green-500",
      warning: "bg-amber-500",
      destructive: "bg-red-500",
      info: "bg-blue-500"
    };
    const indicatorColor = indicatorColors[variant];
    return /* @__PURE__ */ jsxs(
      Badge,
      {
        ref,
        variant,
        className: cn(
          "inline-flex items-center gap-1.5 border bg-transparent",
          className
        ),
        ...props,
        children: [
          /* @__PURE__ */ jsxs("span", { className: "relative flex h-2 w-2", children: [
            pulse && /* @__PURE__ */ jsx(
              "span",
              {
                className: cn(
                  "absolute inline-flex h-full w-full animate-ping rounded-full opacity-75",
                  indicatorColor
                )
              }
            ),
            /* @__PURE__ */ jsx(
              "span",
              {
                className: cn(
                  "relative inline-flex h-2 w-2 rounded-full",
                  indicatorColor
                )
              }
            )
          ] }),
          /* @__PURE__ */ jsx("span", { children: label })
        ]
      }
    );
  }
);
Status.displayName = "Status";
export {
  Status
};
