UNPKG

@mui/x-charts

Version:

The community edition of MUI X Charts components.

20 lines (19 loc) 586 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.useBrush = useBrush; var _useChartBrush = require("../internals/plugins/featurePlugins/useChartBrush"); var _useStore = require("../internals/store/useStore"); /** * Get the current brush state. * * - `start` is the starting point of the brush selection. * - `current` is the current point of the brush selection. * * @returns `{ start, current }` - The brush state. */ function useBrush() { const store = (0, _useStore.useStore)(); return store.use(_useChartBrush.selectorBrushState); }