import { f as cn, lt as Root3, ot as Content2, st as Portal, ut as Trigger } from "./connect-MjNGHHUz-BfDIyhte.js";
import { forwardRef } from "react";
import { jsx, jsxs } from "react/jsx-runtime";
//#region node_modules/@powerhousedao/design-system/dist/ui/components/tooltip/tooltip.js
const TooltipContent = forwardRef(({ children, className, ...props }, ref) => {
	return /* @__PURE__ */ jsx(Content2, {
		ref,
		...props,
		className: cn("z-50 overflow-hidden rounded-md text-sm", "border border-gray-200 bg-white text-gray-900 dark:border-gray-900 dark:bg-slate-900 dark:text-gray-200", "px-3 py-1.5 shadow-md", "data-[state=open]:animate-fade-in data-[state=open]:animate-zoom-in", "data-[state=closed]:animate-fade-out data-[state=closed]:animate-zoom-out", "data-[side=bottom]:animate-slide-in-from-top", "data-[side=left]:animate-slide-in-from-right", "data-[side=right]:animate-slide-in-from-left", "data-[side=top]:animate-slide-in-from-bottom", className),
		children
	});
});
const Tooltip = ({ content, children, triggerAsChild = false, delayDuration = 0, ...props }) => {
	const { open, defaultOpen, onOpenChange, ...rest } = props;
	return /* @__PURE__ */ jsxs(Root3, {
		defaultOpen,
		delayDuration,
		onOpenChange,
		open,
		children: [/* @__PURE__ */ jsx(Trigger, {
			asChild: triggerAsChild,
			type: triggerAsChild ? void 0 : "button",
			children
		}), /* @__PURE__ */ jsx(Portal, { children: /* @__PURE__ */ jsx(TooltipContent, {
			sideOffset: 3,
			...rest,
			children: content
		}) })]
	});
};
//#endregion
export { Tooltip as t };

//# sourceMappingURL=tooltip-DCro2_Kh.js.map