import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
import { Tooltip as ReactTooltip } from "react-tooltip";
import { v4 as uuidv4 } from "uuid";
import styles from "./style.module.scss";
import clsx from "clsx";
const Tooltip = ({ children, content, toolTipPosition = "top", isDisabled = false, className, clickable = false, }) => {
    if (isDisabled)
        return _jsx("span", { children: children });
    const toolTipId = uuidv4();
    const combinedClasses = clsx({
        [styles.toolTipStyling]: true,
        ...(className && { [className]: true }),
    });
    return (_jsxs(_Fragment, { children: [_jsx("span", { "data-tooltip-id": toolTipId, "data-tooltip-place": toolTipPosition, children: children }), _jsx(ReactTooltip, { className: combinedClasses, id: toolTipId, noArrow: false, closeOnScroll: true, clickable: clickable, children: content })] }));
};
export default Tooltip;
