import { jsx } from "react/jsx-runtime";
import { MenuRenderer } from "../MenuRenderer/MenuRenderer.mjs";
import { ButtonIcon } from "../ButtonIcon/ButtonIcon.mjs";
import { Box } from "../Box/Box.mjs";
import { triggerOffset } from "./OverflowMenu.css.mjs";
import { IconOverflow } from "../Accordion/AccordionItem.mjs";
const OverflowMenu = ({
  label,
  children,
  id,
  ...menuProps
}) => /* @__PURE__ */ jsx(
  MenuRenderer,
  {
    trigger: (triggerProps) => /* @__PURE__ */ jsx(
      Box,
      {
        display: "flex",
        justifyContent: "flexEnd",
        className: triggerOffset,
        children: /* @__PURE__ */ jsx(
          ButtonIcon,
          {
            id,
            icon: /* @__PURE__ */ jsx(IconOverflow, {}),
            variant: "transparent",
            label,
            ...triggerProps
          }
        )
      }
    ),
    align: "right",
    offsetSpace: "small",
    ...menuProps,
    children
  }
);
export {
  OverflowMenu
};
