UNPKG

@rocket.chat/fuselage-hooks

Version:

React hooks for Fuselage, Rocket.Chat's design system and UI toolkit

13 lines 461 B
import type { Ref } from 'react'; /** * Hook to automatically request focus for an DOM element. * * @param isFocused - if true, the focus will be requested * @param options - options of the focus request * @returns the ref which holds the element * @public */ export declare const useAutoFocus: <T extends { focus: (options?: FocusOptions) => void; }>(isFocused?: boolean, options?: FocusOptions) => Ref<T>; //# sourceMappingURL=useAutoFocus.d.ts.map