UNPKG

@kubit-ui-web/react-components

Version:

Kubit React Components is a customizable, accessible library of React web components, designed to enhance your application's user experience

12 lines 369 B
import { useEffect, useState } from 'react'; export const useTooltipAsModalAriaLabel = (ref) => { const [ariaLabel, setArialabel] = useState(undefined); useEffect(() => { if (!ref.current) { return; } setArialabel(ref.current.innerText); }); return ariaLabel; }; //# sourceMappingURL=useTooltipAsModalAriaLabel.js.map