1 line
38 KiB
JSON
1 line
38 KiB
JSON
{"ast":null,"code":"/*!\n * (C) Ionic http://ionicframework.com - MIT License\n */\nimport { G as GESTURE_CONTROLLER } from './gesture-controller-17e82006.js';\nexport { G as GESTURE_CONTROLLER } from './gesture-controller-17e82006.js';\n\nconst addEventListener = (el, eventName, callback, opts) => {\n // use event listener options when supported\n // otherwise it's just a boolean for the \"capture\" arg\n const listenerOpts = supportsPassive(el) ? {\n capture: !!opts.capture,\n passive: !!opts.passive\n } : !!opts.capture;\n let add;\n let remove;\n\n if (el['__zone_symbol__addEventListener']) {\n add = '__zone_symbol__addEventListener';\n remove = '__zone_symbol__removeEventListener';\n } else {\n add = 'addEventListener';\n remove = 'removeEventListener';\n }\n\n el[add](eventName, callback, listenerOpts);\n return () => {\n el[remove](eventName, callback, listenerOpts);\n };\n};\n\nconst supportsPassive = node => {\n if (_sPassive === undefined) {\n try {\n const opts = Object.defineProperty({}, 'passive', {\n get: () => {\n _sPassive = true;\n }\n });\n node.addEventListener('optsTest', () => {\n return;\n }, opts);\n } catch (e) {\n _sPassive = false;\n }\n }\n\n return !!_sPassive;\n};\n\nlet _sPassive;\n\nconst MOUSE_WAIT = 2000;\n\nconst createPointerEvents = (el, pointerDown, pointerMove, pointerUp, options) => {\n let rmTouchStart;\n let rmTouchMove;\n let rmTouchEnd;\n let rmTouchCancel;\n let rmMouseStart;\n let rmMouseMove;\n let rmMouseUp;\n let lastTouchEvent = 0;\n\n const handleTouchStart = ev => {\n lastTouchEvent = Date.now() + MOUSE_WAIT;\n\n if (!pointerDown(ev)) {\n return;\n }\n\n if (!rmTouchMove && pointerMove) {\n rmTouchMove = addEventListener(el, 'touchmove', pointerMove, options);\n }\n /**\n * Events are dispatched on the element that is tapped and bubble up to\n * the reference element in the gesture. In the event that the element this\n * event was first dispatched on is removed from the DOM, the event will no\n * longer bubble up to our reference element. This leaves the gesture in an\n * unusable state. To account for this, the touchend and touchcancel listeners\n * should be added to the event target so that they still fire even if the target\n * is removed from the DOM.\n */\n\n\n if (!rmTouchEnd) {\n rmTouchEnd = addEventListener(ev.target, 'touchend', handleTouchEnd, options);\n }\n\n if (!rmTouchCancel) {\n rmTouchCancel = addEventListener(ev.target, 'touchcancel', handleTouchEnd, options);\n }\n };\n\n const handleMouseDown = ev => {\n if (lastTouchEvent > Date.now()) {\n return;\n }\n\n if (!pointerDown(ev)) {\n return;\n }\n\n if (!rmMouseMove && pointerMove) {\n rmMouseMove = addEventListener(getDocument(el), 'mousemove', pointerMove, options);\n }\n\n if (!rmMouseUp) {\n rmMouseUp = addEventListener(getDocument(el), 'mouseup', handleMouseUp, options);\n }\n };\n\n const handleTouchEnd = ev => {\n stopTouch();\n\n if (pointerUp) {\n pointerUp(ev);\n }\n };\n\n const handleMouseUp = ev => {\n stopMouse();\n\n if (pointerUp) {\n pointerUp(ev);\n }\n };\n\n const stopTouch = () => {\n if (rmTouchMove) {\n rmTouchMove();\n }\n\n if (rmTouchEnd) {\n rmTouchEnd();\n }\n\n if (rmTouchCancel) {\n rmTouchCancel();\n }\n\n rmTouchMove = rmTouchEnd = rmTouchCancel = undefined;\n };\n\n const stopMouse = () => {\n if (rmMouseMove) {\n rmMouseMove();\n }\n\n if (rmMouseUp) {\n rmMouseUp();\n }\n\n rmMouseMove = rmMouseUp = undefined;\n };\n\n const stop = () => {\n stopTouch();\n stopMouse();\n };\n\n const enable = (isEnabled = true) => {\n if (!isEnabled) {\n if (rmTouchStart) {\n rmTouchStart();\n }\n\n if (rmMouseStart) {\n rmMouseStart();\n }\n\n rmTouchStart = rmMouseStart = undefined;\n stop();\n } else {\n if (!rmTouchStart) {\n rmTouchStart = addEventListener(el, 'touchstart', handleTouchStart, options);\n }\n\n if (!rmMouseStart) {\n rmMouseStart = addEventListener(el, 'mousedown', handleMouseDown, options);\n }\n }\n };\n\n const destroy = () => {\n enable(false);\n pointerUp = pointerMove = pointerDown = undefined;\n };\n\n return {\n enable,\n stop,\n destroy\n };\n};\n\nconst getDocument = node => {\n return node instanceof Document ? node : node.ownerDocument;\n};\n\nconst createPanRecognizer = (direction, thresh, maxAngle) => {\n const radians = maxAngle * (Math.PI / 180);\n const isDirX = direction === 'x';\n const maxCosine = Math.cos(radians);\n const threshold = thresh * thresh;\n let startX = 0;\n let startY = 0;\n let dirty = false;\n let isPan = 0;\n return {\n start(x, y) {\n startX = x;\n startY = y;\n isPan = 0;\n dirty = true;\n },\n\n detect(x, y) {\n if (!dirty) {\n return false;\n }\n\n const deltaX = x - startX;\n const deltaY = y - startY;\n const distance = deltaX * deltaX + deltaY * deltaY;\n\n if (distance < threshold) {\n return false;\n }\n\n const hypotenuse = Math.sqrt(distance);\n const cosine = (isDirX ? deltaX : deltaY) / hypotenuse;\n\n if (cosine > maxCosine) {\n isPan = 1;\n } else if (cosine < -maxCosine) {\n isPan = -1;\n } else {\n isPan = 0;\n }\n\n dirty = false;\n return true;\n },\n\n isGesture() {\n return isPan !== 0;\n },\n\n getDirection() {\n return isPan;\n }\n\n };\n};\n\nconst createGesture = config => {\n let hasCapturedPan = false;\n let hasStartedPan = false;\n let hasFiredStart = true;\n let isMoveQueued = false;\n const finalConfig = Object.assign({\n disableScroll: false,\n direction: 'x',\n gesturePriority: 0,\n passive: true,\n maxAngle: 40,\n threshold: 10\n }, config);\n const canStart = finalConfig.canStart;\n const onWillStart = finalConfig.onWillStart;\n const onStart = finalConfig.onStart;\n const onEnd = finalConfig.onEnd;\n const notCaptured = finalConfig.notCaptured;\n const onMove = finalConfig.onMove;\n const threshold = finalConfig.threshold;\n const passive = finalConfig.passive;\n const blurOnStart = finalConfig.blurOnStart;\n const detail = {\n type: 'pan',\n startX: 0,\n startY: 0,\n startTime: 0,\n currentX: 0,\n currentY: 0,\n velocityX: 0,\n velocityY: 0,\n deltaX: 0,\n deltaY: 0,\n currentTime: 0,\n event: undefined,\n data: undefined\n };\n const pan = createPanRecognizer(finalConfig.direction, finalConfig.threshold, finalConfig.maxAngle);\n const gesture = GESTURE_CONTROLLER.createGesture({\n name: config.gestureName,\n priority: config.gesturePriority,\n disableScroll: config.disableScroll\n });\n\n const pointerDown = ev => {\n const timeStamp = now(ev);\n\n if (hasStartedPan || !hasFiredStart) {\n return false;\n }\n\n updateDetail(ev, detail);\n detail.startX = detail.currentX;\n detail.startY = detail.currentY;\n detail.startTime = detail.currentTime = timeStamp;\n detail.velocityX = detail.velocityY = detail.deltaX = detail.deltaY = 0;\n detail.event = ev; // Check if gesture can start\n\n if (canStart && canStart(detail) === false) {\n return false;\n } // Release fallback\n\n\n gesture.release(); // Start gesture\n\n if (!gesture.start()) {\n return false;\n }\n\n hasStartedPan = true;\n\n if (threshold === 0) {\n return tryToCapturePan();\n }\n\n pan.start(detail.startX, detail.startY);\n return true;\n };\n\n const pointerMove = ev => {\n // fast path, if gesture is currently captured\n // do minimum job to get user-land even dispatched\n if (hasCapturedPan) {\n if (!isMoveQueued && hasFiredStart) {\n isMoveQueued = true;\n calcGestureData(detail, ev);\n requestAnimationFrame(fireOnMove);\n }\n\n return;\n } // gesture is currently being detected\n\n\n calcGestureData(detail, ev);\n\n if (pan.detect(detail.currentX, detail.currentY)) {\n if (!pan.isGesture() || !tryToCapturePan()) {\n abortGesture();\n }\n }\n };\n\n const fireOnMove = () => {\n // Since fireOnMove is called inside a RAF, onEnd() might be called,\n // we must double check hasCapturedPan\n if (!hasCapturedPan) {\n return;\n }\n\n isMoveQueued = false;\n\n if (onMove) {\n onMove(detail);\n }\n };\n\n const tryToCapturePan = () => {\n if (gesture && !gesture.capture()) {\n return false;\n }\n\n hasCapturedPan = true;\n hasFiredStart = false; // reset start position since the real user-land event starts here\n // If the pan detector threshold is big, not resetting the start position\n // will cause a jump in the animation equal to the detector threshold.\n // the array of positions used to calculate the gesture velocity does not\n // need to be cleaned, more points in the positions array always results in a\n // more accurate value of the velocity.\n\n detail.startX = detail.currentX;\n detail.startY = detail.currentY;\n detail.startTime = detail.currentTime;\n\n if (onWillStart) {\n onWillStart(detail).then(fireOnStart);\n } else {\n fireOnStart();\n }\n\n return true;\n };\n\n const blurActiveElement = () => {\n if (typeof document !== 'undefined') {\n const activeElement = document.activeElement;\n\n if (activeElement === null || activeElement === void 0 ? void 0 : activeElement.blur) {\n activeElement.blur();\n }\n }\n };\n\n const fireOnStart = () => {\n if (blurOnStart) {\n blurActiveElement();\n }\n\n if (onStart) {\n onStart(detail);\n }\n\n hasFiredStart = true;\n };\n\n const reset = () => {\n hasCapturedPan = false;\n hasStartedPan = false;\n isMoveQueued = false;\n hasFiredStart = true;\n gesture.release();\n }; // END *************************\n\n\n const pointerUp = ev => {\n const tmpHasCaptured = hasCapturedPan;\n const tmpHasFiredStart = hasFiredStart;\n reset();\n\n if (!tmpHasFiredStart) {\n return;\n }\n\n calcGestureData(detail, ev); // Try to capture press\n\n if (tmpHasCaptured) {\n if (onEnd) {\n onEnd(detail);\n }\n\n return;\n } // Not captured any event\n\n\n if (notCaptured) {\n notCaptured(detail);\n }\n };\n\n const pointerEvents = createPointerEvents(finalConfig.el, pointerDown, pointerMove, pointerUp, {\n capture: false,\n passive\n });\n\n const abortGesture = () => {\n reset();\n pointerEvents.stop();\n\n if (notCaptured) {\n notCaptured(detail);\n }\n };\n\n return {\n enable(enable = true) {\n if (!enable) {\n if (hasCapturedPan) {\n pointerUp(undefined);\n }\n\n reset();\n }\n\n pointerEvents.enable(enable);\n },\n\n destroy() {\n gesture.destroy();\n pointerEvents.destroy();\n }\n\n };\n};\n\nconst calcGestureData = (detail, ev) => {\n if (!ev) {\n return;\n }\n\n const prevX = detail.currentX;\n const prevY = detail.currentY;\n const prevT = detail.currentTime;\n updateDetail(ev, detail);\n const currentX = detail.currentX;\n const currentY = detail.currentY;\n const timestamp = detail.currentTime = now(ev);\n const timeDelta = timestamp - prevT;\n\n if (timeDelta > 0 && timeDelta < 100) {\n const velocityX = (currentX - prevX) / timeDelta;\n const velocityY = (currentY - prevY) / timeDelta;\n detail.velocityX = velocityX * 0.7 + detail.velocityX * 0.3;\n detail.velocityY = velocityY * 0.7 + detail.velocityY * 0.3;\n }\n\n detail.deltaX = currentX - detail.startX;\n detail.deltaY = currentY - detail.startY;\n detail.event = ev;\n};\n\nconst updateDetail = (ev, detail) => {\n // get X coordinates for either a mouse click\n // or a touch depending on the given event\n let x = 0;\n let y = 0;\n\n if (ev) {\n const changedTouches = ev.changedTouches;\n\n if (changedTouches && changedTouches.length > 0) {\n const touch = changedTouches[0];\n x = touch.clientX;\n y = touch.clientY;\n } else if (ev.pageX !== undefined) {\n x = ev.pageX;\n y = ev.pageY;\n }\n }\n\n detail.currentX = x;\n detail.currentY = y;\n};\n\nconst now = ev => {\n return ev.timeStamp || Date.now();\n};\n\nexport { createGesture };","map":{"version":3,"names":["G","GESTURE_CONTROLLER","addEventListener","el","eventName","callback","opts","listenerOpts","supportsPassive","capture","passive","add","remove","node","_sPassive","undefined","Object","defineProperty","get","e","MOUSE_WAIT","createPointerEvents","pointerDown","pointerMove","pointerUp","options","rmTouchStart","rmTouchMove","rmTouchEnd","rmTouchCancel","rmMouseStart","rmMouseMove","rmMouseUp","lastTouchEvent","handleTouchStart","ev","Date","now","target","handleTouchEnd","handleMouseDown","getDocument","handleMouseUp","stopTouch","stopMouse","stop","enable","isEnabled","destroy","Document","ownerDocument","createPanRecognizer","direction","thresh","maxAngle","radians","Math","PI","isDirX","maxCosine","cos","threshold","startX","startY","dirty","isPan","start","x","y","detect","deltaX","deltaY","distance","hypotenuse","sqrt","cosine","isGesture","getDirection","createGesture","config","hasCapturedPan","hasStartedPan","hasFiredStart","isMoveQueued","finalConfig","assign","disableScroll","gesturePriority","canStart","onWillStart","onStart","onEnd","notCaptured","onMove","blurOnStart","detail","type","startTime","currentX","currentY","velocityX","velocityY","currentTime","event","data","pan","gesture","name","gestureName","priority","timeStamp","updateDetail","release","tryToCapturePan","calcGestureData","requestAnimationFrame","fireOnMove","abortGesture","then","fireOnStart","blurActiveElement","document","activeElement","blur","reset","tmpHasCaptured","tmpHasFiredStart","pointerEvents","prevX","prevY","prevT","timestamp","timeDelta","changedTouches","length","touch","clientX","clientY","pageX","pageY"],"sources":["D:/MobileDev/WRB/WrenchBoard2023a/node_modules/@ionic/core/dist/esm/index-3f1a7d95.js"],"sourcesContent":["/*!\n * (C) Ionic http://ionicframework.com - MIT License\n */\nimport { G as GESTURE_CONTROLLER } from './gesture-controller-17e82006.js';\nexport { G as GESTURE_CONTROLLER } from './gesture-controller-17e82006.js';\n\nconst addEventListener = (el, eventName, callback, opts) => {\n // use event listener options when supported\n // otherwise it's just a boolean for the \"capture\" arg\n const listenerOpts = supportsPassive(el)\n ? {\n capture: !!opts.capture,\n passive: !!opts.passive,\n }\n : !!opts.capture;\n let add;\n let remove;\n if (el['__zone_symbol__addEventListener']) {\n add = '__zone_symbol__addEventListener';\n remove = '__zone_symbol__removeEventListener';\n }\n else {\n add = 'addEventListener';\n remove = 'removeEventListener';\n }\n el[add](eventName, callback, listenerOpts);\n return () => {\n el[remove](eventName, callback, listenerOpts);\n };\n};\nconst supportsPassive = (node) => {\n if (_sPassive === undefined) {\n try {\n const opts = Object.defineProperty({}, 'passive', {\n get: () => {\n _sPassive = true;\n },\n });\n node.addEventListener('optsTest', () => {\n return;\n }, opts);\n }\n catch (e) {\n _sPassive = false;\n }\n }\n return !!_sPassive;\n};\nlet _sPassive;\n\nconst MOUSE_WAIT = 2000;\nconst createPointerEvents = (el, pointerDown, pointerMove, pointerUp, options) => {\n let rmTouchStart;\n let rmTouchMove;\n let rmTouchEnd;\n let rmTouchCancel;\n let rmMouseStart;\n let rmMouseMove;\n let rmMouseUp;\n let lastTouchEvent = 0;\n const handleTouchStart = (ev) => {\n lastTouchEvent = Date.now() + MOUSE_WAIT;\n if (!pointerDown(ev)) {\n return;\n }\n if (!rmTouchMove && pointerMove) {\n rmTouchMove = addEventListener(el, 'touchmove', pointerMove, options);\n }\n /**\n * Events are dispatched on the element that is tapped and bubble up to\n * the reference element in the gesture. In the event that the element this\n * event was first dispatched on is removed from the DOM, the event will no\n * longer bubble up to our reference element. This leaves the gesture in an\n * unusable state. To account for this, the touchend and touchcancel listeners\n * should be added to the event target so that they still fire even if the target\n * is removed from the DOM.\n */\n if (!rmTouchEnd) {\n rmTouchEnd = addEventListener(ev.target, 'touchend', handleTouchEnd, options);\n }\n if (!rmTouchCancel) {\n rmTouchCancel = addEventListener(ev.target, 'touchcancel', handleTouchEnd, options);\n }\n };\n const handleMouseDown = (ev) => {\n if (lastTouchEvent > Date.now()) {\n return;\n }\n if (!pointerDown(ev)) {\n return;\n }\n if (!rmMouseMove && pointerMove) {\n rmMouseMove = addEventListener(getDocument(el), 'mousemove', pointerMove, options);\n }\n if (!rmMouseUp) {\n rmMouseUp = addEventListener(getDocument(el), 'mouseup', handleMouseUp, options);\n }\n };\n const handleTouchEnd = (ev) => {\n stopTouch();\n if (pointerUp) {\n pointerUp(ev);\n }\n };\n const handleMouseUp = (ev) => {\n stopMouse();\n if (pointerUp) {\n pointerUp(ev);\n }\n };\n const stopTouch = () => {\n if (rmTouchMove) {\n rmTouchMove();\n }\n if (rmTouchEnd) {\n rmTouchEnd();\n }\n if (rmTouchCancel) {\n rmTouchCancel();\n }\n rmTouchMove = rmTouchEnd = rmTouchCancel = undefined;\n };\n const stopMouse = () => {\n if (rmMouseMove) {\n rmMouseMove();\n }\n if (rmMouseUp) {\n rmMouseUp();\n }\n rmMouseMove = rmMouseUp = undefined;\n };\n const stop = () => {\n stopTouch();\n stopMouse();\n };\n const enable = (isEnabled = true) => {\n if (!isEnabled) {\n if (rmTouchStart) {\n rmTouchStart();\n }\n if (rmMouseStart) {\n rmMouseStart();\n }\n rmTouchStart = rmMouseStart = undefined;\n stop();\n }\n else {\n if (!rmTouchStart) {\n rmTouchStart = addEventListener(el, 'touchstart', handleTouchStart, options);\n }\n if (!rmMouseStart) {\n rmMouseStart = addEventListener(el, 'mousedown', handleMouseDown, options);\n }\n }\n };\n const destroy = () => {\n enable(false);\n pointerUp = pointerMove = pointerDown = undefined;\n };\n return {\n enable,\n stop,\n destroy,\n };\n};\nconst getDocument = (node) => {\n return node instanceof Document ? node : node.ownerDocument;\n};\n\nconst createPanRecognizer = (direction, thresh, maxAngle) => {\n const radians = maxAngle * (Math.PI / 180);\n const isDirX = direction === 'x';\n const maxCosine = Math.cos(radians);\n const threshold = thresh * thresh;\n let startX = 0;\n let startY = 0;\n let dirty = false;\n let isPan = 0;\n return {\n start(x, y) {\n startX = x;\n startY = y;\n isPan = 0;\n dirty = true;\n },\n detect(x, y) {\n if (!dirty) {\n return false;\n }\n const deltaX = x - startX;\n const deltaY = y - startY;\n const distance = deltaX * deltaX + deltaY * deltaY;\n if (distance < threshold) {\n return false;\n }\n const hypotenuse = Math.sqrt(distance);\n const cosine = (isDirX ? deltaX : deltaY) / hypotenuse;\n if (cosine > maxCosine) {\n isPan = 1;\n }\n else if (cosine < -maxCosine) {\n isPan = -1;\n }\n else {\n isPan = 0;\n }\n dirty = false;\n return true;\n },\n isGesture() {\n return isPan !== 0;\n },\n getDirection() {\n return isPan;\n },\n };\n};\n\nconst createGesture = (config) => {\n let hasCapturedPan = false;\n let hasStartedPan = false;\n let hasFiredStart = true;\n let isMoveQueued = false;\n const finalConfig = Object.assign({ disableScroll: false, direction: 'x', gesturePriority: 0, passive: true, maxAngle: 40, threshold: 10 }, config);\n const canStart = finalConfig.canStart;\n const onWillStart = finalConfig.onWillStart;\n const onStart = finalConfig.onStart;\n const onEnd = finalConfig.onEnd;\n const notCaptured = finalConfig.notCaptured;\n const onMove = finalConfig.onMove;\n const threshold = finalConfig.threshold;\n const passive = finalConfig.passive;\n const blurOnStart = finalConfig.blurOnStart;\n const detail = {\n type: 'pan',\n startX: 0,\n startY: 0,\n startTime: 0,\n currentX: 0,\n currentY: 0,\n velocityX: 0,\n velocityY: 0,\n deltaX: 0,\n deltaY: 0,\n currentTime: 0,\n event: undefined,\n data: undefined,\n };\n const pan = createPanRecognizer(finalConfig.direction, finalConfig.threshold, finalConfig.maxAngle);\n const gesture = GESTURE_CONTROLLER.createGesture({\n name: config.gestureName,\n priority: config.gesturePriority,\n disableScroll: config.disableScroll,\n });\n const pointerDown = (ev) => {\n const timeStamp = now(ev);\n if (hasStartedPan || !hasFiredStart) {\n return false;\n }\n updateDetail(ev, detail);\n detail.startX = detail.currentX;\n detail.startY = detail.currentY;\n detail.startTime = detail.currentTime = timeStamp;\n detail.velocityX = detail.velocityY = detail.deltaX = detail.deltaY = 0;\n detail.event = ev;\n // Check if gesture can start\n if (canStart && canStart(detail) === false) {\n return false;\n }\n // Release fallback\n gesture.release();\n // Start gesture\n if (!gesture.start()) {\n return false;\n }\n hasStartedPan = true;\n if (threshold === 0) {\n return tryToCapturePan();\n }\n pan.start(detail.startX, detail.startY);\n return true;\n };\n const pointerMove = (ev) => {\n // fast path, if gesture is currently captured\n // do minimum job to get user-land even dispatched\n if (hasCapturedPan) {\n if (!isMoveQueued && hasFiredStart) {\n isMoveQueued = true;\n calcGestureData(detail, ev);\n requestAnimationFrame(fireOnMove);\n }\n return;\n }\n // gesture is currently being detected\n calcGestureData(detail, ev);\n if (pan.detect(detail.currentX, detail.currentY)) {\n if (!pan.isGesture() || !tryToCapturePan()) {\n abortGesture();\n }\n }\n };\n const fireOnMove = () => {\n // Since fireOnMove is called inside a RAF, onEnd() might be called,\n // we must double check hasCapturedPan\n if (!hasCapturedPan) {\n return;\n }\n isMoveQueued = false;\n if (onMove) {\n onMove(detail);\n }\n };\n const tryToCapturePan = () => {\n if (gesture && !gesture.capture()) {\n return false;\n }\n hasCapturedPan = true;\n hasFiredStart = false;\n // reset start position since the real user-land event starts here\n // If the pan detector threshold is big, not resetting the start position\n // will cause a jump in the animation equal to the detector threshold.\n // the array of positions used to calculate the gesture velocity does not\n // need to be cleaned, more points in the positions array always results in a\n // more accurate value of the velocity.\n detail.startX = detail.currentX;\n detail.startY = detail.currentY;\n detail.startTime = detail.currentTime;\n if (onWillStart) {\n onWillStart(detail).then(fireOnStart);\n }\n else {\n fireOnStart();\n }\n return true;\n };\n const blurActiveElement = () => {\n if (typeof document !== 'undefined') {\n const activeElement = document.activeElement;\n if (activeElement === null || activeElement === void 0 ? void 0 : activeElement.blur) {\n activeElement.blur();\n }\n }\n };\n const fireOnStart = () => {\n if (blurOnStart) {\n blurActiveElement();\n }\n if (onStart) {\n onStart(detail);\n }\n hasFiredStart = true;\n };\n const reset = () => {\n hasCapturedPan = false;\n hasStartedPan = false;\n isMoveQueued = false;\n hasFiredStart = true;\n gesture.release();\n };\n // END *************************\n const pointerUp = (ev) => {\n const tmpHasCaptured = hasCapturedPan;\n const tmpHasFiredStart = hasFiredStart;\n reset();\n if (!tmpHasFiredStart) {\n return;\n }\n calcGestureData(detail, ev);\n // Try to capture press\n if (tmpHasCaptured) {\n if (onEnd) {\n onEnd(detail);\n }\n return;\n }\n // Not captured any event\n if (notCaptured) {\n notCaptured(detail);\n }\n };\n const pointerEvents = createPointerEvents(finalConfig.el, pointerDown, pointerMove, pointerUp, {\n capture: false,\n passive,\n });\n const abortGesture = () => {\n reset();\n pointerEvents.stop();\n if (notCaptured) {\n notCaptured(detail);\n }\n };\n return {\n enable(enable = true) {\n if (!enable) {\n if (hasCapturedPan) {\n pointerUp(undefined);\n }\n reset();\n }\n pointerEvents.enable(enable);\n },\n destroy() {\n gesture.destroy();\n pointerEvents.destroy();\n },\n };\n};\nconst calcGestureData = (detail, ev) => {\n if (!ev) {\n return;\n }\n const prevX = detail.currentX;\n const prevY = detail.currentY;\n const prevT = detail.currentTime;\n updateDetail(ev, detail);\n const currentX = detail.currentX;\n const currentY = detail.currentY;\n const timestamp = (detail.currentTime = now(ev));\n const timeDelta = timestamp - prevT;\n if (timeDelta > 0 && timeDelta < 100) {\n const velocityX = (currentX - prevX) / timeDelta;\n const velocityY = (currentY - prevY) / timeDelta;\n detail.velocityX = velocityX * 0.7 + detail.velocityX * 0.3;\n detail.velocityY = velocityY * 0.7 + detail.velocityY * 0.3;\n }\n detail.deltaX = currentX - detail.startX;\n detail.deltaY = currentY - detail.startY;\n detail.event = ev;\n};\nconst updateDetail = (ev, detail) => {\n // get X coordinates for either a mouse click\n // or a touch depending on the given event\n let x = 0;\n let y = 0;\n if (ev) {\n const changedTouches = ev.changedTouches;\n if (changedTouches && changedTouches.length > 0) {\n const touch = changedTouches[0];\n x = touch.clientX;\n y = touch.clientY;\n }\n else if (ev.pageX !== undefined) {\n x = ev.pageX;\n y = ev.pageY;\n }\n }\n detail.currentX = x;\n detail.currentY = y;\n};\nconst now = (ev) => {\n return ev.timeStamp || Date.now();\n};\n\nexport { createGesture };\n"],"mappings":"AAAA;AACA;AACA;AACA,SAASA,CAAC,IAAIC,kBAAd,QAAwC,kCAAxC;AACA,SAASD,CAAC,IAAIC,kBAAd,QAAwC,kCAAxC;;AAEA,MAAMC,gBAAgB,GAAG,CAACC,EAAD,EAAKC,SAAL,EAAgBC,QAAhB,EAA0BC,IAA1B,KAAmC;EAC1D;EACA;EACA,MAAMC,YAAY,GAAGC,eAAe,CAACL,EAAD,CAAf,GACjB;IACAM,OAAO,EAAE,CAAC,CAACH,IAAI,CAACG,OADhB;IAEAC,OAAO,EAAE,CAAC,CAACJ,IAAI,CAACI;EAFhB,CADiB,GAKjB,CAAC,CAACJ,IAAI,CAACG,OALX;EAMA,IAAIE,GAAJ;EACA,IAAIC,MAAJ;;EACA,IAAIT,EAAE,CAAC,iCAAD,CAAN,EAA2C;IACzCQ,GAAG,GAAG,iCAAN;IACAC,MAAM,GAAG,oCAAT;EACD,CAHD,MAIK;IACHD,GAAG,GAAG,kBAAN;IACAC,MAAM,GAAG,qBAAT;EACD;;EACDT,EAAE,CAACQ,GAAD,CAAF,CAAQP,SAAR,EAAmBC,QAAnB,EAA6BE,YAA7B;EACA,OAAO,MAAM;IACXJ,EAAE,CAACS,MAAD,CAAF,CAAWR,SAAX,EAAsBC,QAAtB,EAAgCE,YAAhC;EACD,CAFD;AAGD,CAvBD;;AAwBA,MAAMC,eAAe,GAAIK,IAAD,IAAU;EAChC,IAAIC,SAAS,KAAKC,SAAlB,EAA6B;IAC3B,IAAI;MACF,MAAMT,IAAI,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