UNPKG

vue-instagram-cropper

Version:

Simple Image Cropper that works like Instagram for Vue

12 lines (9 loc) 901 B
export const PCT_PER_ZOOM = 1 / 100000; // The amount of zooming everytime it happens, in percentage of image width. export const MIN_MS_PER_CLICK = 500; // If touch duration is shorter than the value, then it is considered as a click. export const CLICK_MOVE_THRESHOLD = 100; // If touch move distance is greater than this value, then it will by no mean be considered as a click. export const MIN_WIDTH = 10; // The minimal width the user can zoom to. export const DEFAULT_PLACEHOLDER_TAKEUP = 2 / 3; // Placeholder text by default takes up this amount of times of canvas width. export const PINCH_ACCELERATION = 2; // The amount of times by which the pinching is more sensitive than the scolling export const ZOOM_SPEED = 3; // Specifies how fast the zoom is reacting to scroll gestures. Default to level 3. export const MAXIMUM_ASPECT_RATIO = 1.91 / 1; export const MINIMUM_ASPECT_RATIO = 4 / 5;