mirror of
https://github.com/excalidraw/excalidraw.git
synced 2025-05-03 10:00:07 -04:00
feat: split gridSize
from enabled state & support custom gridStep
(#8364)
This commit is contained in:
parent
4320a3cf41
commit
3cfcc7b489
31 changed files with 737 additions and 278 deletions
|
@ -1,10 +1,5 @@
|
|||
import { MIN_ZOOM } from "../constants";
|
||||
import type { AppState, NormalizedZoomValue } from "../types";
|
||||
|
||||
export const getNormalizedZoom = (zoom: number): NormalizedZoomValue => {
|
||||
return Math.max(MIN_ZOOM, Math.min(zoom, 30)) as NormalizedZoomValue;
|
||||
};
|
||||
|
||||
export const getStateForZoom = (
|
||||
{
|
||||
viewportX,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue