UNPKG

monday-ui-react-core

Version:

Official monday.com UI resources for application development in React.js

23 lines (22 loc) 804 B
import { MutableRefObject } from "react"; import { NavDirections } from "../../hooks/useFullKeyboardListeners"; export type GridElementRef = MutableRefObject<HTMLElement> & { current?: HTMLElement & { disabled?: boolean; }; }; export type DirectionMap = Map<GridElementRef, GridElementRef>; export type DirectionMaps = Record<NavDirections, DirectionMap>; export type Position = VerticalPosition & HorizontalPosition; type VerticalPosition = { topElement?: GridElementRef; bottomElement?: GridElementRef; }; type HorizontalPosition = { leftElement?: GridElementRef; rightElement?: GridElementRef; }; export interface GridKeyboardNavigationContextType { onOutboundNavigation?: (ref: GridElementRef, direction: NavDirections) => void; } export {};