UNPKG

@linzjs/step-ag-grid

Version:

[![semantic-release: angular](https://img.shields.io/badge/semantic--release-angular-e10079?logo=semantic-release)](https://github.com/semantic-release/semantic-release) > Reusable [ag-grid](https://www.ag-grid.com/) component for LINZ / Toitū te whenua.

22 lines (21 loc) 694 B
import { MenuState, MenuStateOptions } from '../types'; /** * A custom Hook which helps manage the states of `ControlledMenu`. */ export declare const useMenuState: (props?: MenuStateOptions) => [{ /** * Menu state which should be forwarded to `ControlledMenu`. */ state?: MenuState; /** * Stop transition animation. This function value should be forwarded to `ControlledMenu`. */ endTransition: () => void; }, /** * Open or close menu. * * - If no parameter is supplied, this function will toggle state between open and close phases. * - You can set a boolean parameter to explicitly switch into one of the two phases. */ (open?: boolean) => void];