import React from 'react'; import { useTooltipState, TooltipAnchor, FloatingTooltip } from './FloatingTooltip'; import type { Placement } from '@floating-ui/react-dom-interactions'; import cn from 'classnames'; interface Props { title?: React.ReactNode; children: React.ReactNode; disabled?: boolean; open?: boolean; placement?: Placement; className?: string; delay?: number; style?: any; offset?: number; anchorClassName?: string; } function Tooltip(props: Props) { const { title, disabled = false, open = false, placement, className = '', anchorClassName = '', containerClassName = '', delay = 500, style = {}, offset = 5, } = props; const arrowRef = React.useRef(null); const state = useTooltipState({ disabled: disabled, placement, delay, initialOpen: open, offset, arrowRef, }); return (