UNPKG

@elastic/charts

Version:

Elastic-Charts data visualization library

14 lines 438 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.useLegendAction = useLegendAction; const react_1 = require("react"); function useLegendAction() { const ref = (0, react_1.useRef)(null); const onClose = () => { if (ref.current) { requestAnimationFrame(() => ref?.current?.focus?.()); } }; return [ref, onClose]; } //# sourceMappingURL=use_legend_action.js.map