This commit is contained in:
Panayiotis Lipiridis 2021-01-15 18:35:36 +02:00
parent 1e7dfa692b
commit 85e8e93d60

View File

@ -2,50 +2,50 @@ import { FontFamily } from "./element/types";
export const APP_NAME = "Excalidraw"; export const APP_NAME = "Excalidraw";
export const DRAGGING_THRESHOLD = 10; // 10px export const DRAGGING_THRESHOLD = 10;
export const LINE_CONFIRM_THRESHOLD = 10; // 10px export const LINE_CONFIRM_THRESHOLD = 10;
export const ELEMENT_SHIFT_TRANSLATE_AMOUNT = 5; export const ELEMENT_SHIFT_TRANSLATE_AMOUNT = 5;
export const ELEMENT_TRANSLATE_AMOUNT = 1; export const ELEMENT_TRANSLATE_AMOUNT = 1;
export const TEXT_TO_CENTER_SNAP_THRESHOLD = 30; export const TEXT_TO_CENTER_SNAP_THRESHOLD = 30;
export const SHIFT_LOCKING_ANGLE = Math.PI / 12; export const SHIFT_LOCKING_ANGLE = Math.PI / 12;
export const CURSOR_TYPE = { export const CURSOR_TYPE = {
TEXT: "text", AUTO: "",
CROSSHAIR: "crosshair", CROSSHAIR: "crosshair",
GRABBING: "grabbing", GRABBING: "grabbing",
POINTER: "pointer",
MOVE: "move", MOVE: "move",
AUTO: "", POINTER: "pointer",
TEXT: "text",
}; };
export const POINTER_BUTTON = { export const POINTER_BUTTON = {
MAIN: 0, MAIN: 0,
WHEEL: 1,
SECONDARY: 2, SECONDARY: 2,
TOUCH: -1, TOUCH: -1,
WHEEL: 1,
}; };
export enum EVENT { export enum EVENT {
BEFORE_UNLOAD = "beforeunload",
BLUR = "blur",
COPY = "copy", COPY = "copy",
PASTE = "paste",
CUT = "cut", CUT = "cut",
DRAG_OVER = "dragover",
DROP = "drop",
GESTURE_CHANGE = "gesturechange",
GESTURE_END = "gestureend",
GESTURE_START = "gesturestart",
HASHCHANGE = "hashchange",
KEYDOWN = "keydown", KEYDOWN = "keydown",
KEYUP = "keyup", KEYUP = "keyup",
MOUSE_MOVE = "mousemove", MOUSE_MOVE = "mousemove",
RESIZE = "resize", PASTE = "paste",
UNLOAD = "unload",
BLUR = "blur",
DRAG_OVER = "dragover",
DROP = "drop",
GESTURE_END = "gestureend",
BEFORE_UNLOAD = "beforeunload",
GESTURE_START = "gesturestart",
GESTURE_CHANGE = "gesturechange",
POINTER_MOVE = "pointermove", POINTER_MOVE = "pointermove",
POINTER_UP = "pointerup", POINTER_UP = "pointerup",
RESIZE = "resize",
STATE_CHANGE = "statechange", STATE_CHANGE = "statechange",
WHEEL = "wheel",
TOUCH_START = "touchstart",
TOUCH_END = "touchend", TOUCH_END = "touchend",
HASHCHANGE = "hashchange", TOUCH_START = "touchstart",
UNLOAD = "unload",
WHEEL = "wheel",
} }
export const ENV = { export const ENV = {