Files
ETB/ETB-FrontEnd/node_modules/@mui/x-charts/esm/hooks/useDrawingArea.js
Iliyan Angelov 306b20e24a Frontend start
2025-09-14 00:54:48 +03:00

16 lines
626 B
JavaScript

'use client';
import { useStore } from "../internals/store/useStore.js";
import { useSelector } from "../internals/store/useSelector.js";
import { selectorChartDrawingArea } from "../internals/plugins/corePlugins/useChartDimensions/useChartDimensions.selectors.js";
/**
* Get the drawing area dimensions and coordinates. The drawing area is the area where the chart is rendered.
*
* It includes the left, top, width, height, bottom, and right dimensions.
*
* @returns The drawing area dimensions.
*/
export function useDrawingArea() {
const store = useStore();
return useSelector(store, selectorChartDrawingArea);
}