function useHotkeys(child, hotkeys) {
    if (!child || isEmpty(hotkeys)) return child;

    const memoHotkeys = useMemo(() => hotkeys, []),
        {handleKeyDown, handleKeyUp} = useHotkeysBp(memoHotkeys);

    return cloneElement(child, {onKeyDown: handleKeyDown, onKeyUp: handleKeyUp});
}
/**
 * Hook to add Key handling support to a component.
 *
 * The implementation of this hook is based on BlueprintJS.
 * See their docs {@link https://blueprintjs.com/docs/#core/components/hotkeys} for more info.
 *
 * @param {element} [child] - element to be given hotkey support.  Must specify Component
 *      that takes react key events as props (e.g. boxes, panel, div, etc).
 * @param {(Array|element)} [hotkeys] - An array of hotkeys, or configs for hotkeys,
 *      as prescribed by blueprint. A Hotkeys element may also be provided.
 */
Hook to add Key handling support to a component.
The implementation of this hook is based on BlueprintJS.

@param {element} [child] - element to be given hotkey support.  Must specify Component
that takes react key events as props .
@param {(Array|element)} [hotkeys] - An array of hotkeys, or configs for hotkeys,
as prescribed by blueprint. A Hotkeys element may also be provided.
Hook to add Key handling support to a component . The implementation of this hook is based on BlueprintJS . @param { element } [ child ] - element to be given hotkey support . Must specify Component that takes react key events as props . @param { ( Array|element ) } [ hotkeys ] - An array of hotkeys or configs for hotkeys as prescribed by blueprint . A Hotkeys element may also be provided .
function useHotkeys(child, hotkeys) {
    if (!child || isEmpty(hotkeys)) return child;
    const memoHotkeys = useMemo(() => hotkeys, []),
        {handleKeyDown, handleKeyUp} = useHotkeysBp(memoHotkeys);
    return cloneElement(child, {onKeyDown: handleKeyDown, onKeyUp: handleKeyUp});
}
function useHotkeys ( child , hotkeys ) { if ( ! child || isEmpty ( hotkeys ) ) return child ; const memoHotkeys = useMemo ( ( ) => hotkeys , [ ] ) , { handleKeyDown , handleKeyUp } = useHotkeysBp ( memoHotkeys ) ; return cloneElement ( child , { onKeyDown : handleKeyDown , onKeyUp : handleKeyUp } ) ; }
Hook to add Key handling support to a component.
Hook to add Key handling support to a component .