Ingen beskrivning

22.7ec1dda8.chunk.js.map 3.6KB

1
  1. {"version":3,"file":"static/js/22.7ec1dda8.chunk.js","mappings":"kMAOMA,EAAyB,SAACC,EAAIC,EAAiBC,EAAgBC,EAAeC,GAClF,IAAMC,EAAML,EAAGM,cAAcC,YACvBC,GAAMC,EAAAA,EAAAA,GAAMT,GAcZU,EAAY,SAACC,GACjB,OAAOH,GAAOG,EAAOC,OAASD,EAAOC,MACvC,EA8BA,OAAOC,EAAAA,EAAAA,eAAc,CACnBb,GAAAA,EACAc,YAAa,eACbC,gBAAiB,GACjBC,UAAW,GACXC,SA/Be,SAACN,GAChB,OAfe,SAACA,GAChB,IACQO,EAAWP,EAAXO,OACR,OAAIV,EACKU,GAAUb,EAAIc,WAHL,GAKXD,GALW,EAMpB,CAQSE,CAAST,IAAWV,GAC7B,EA8BEoB,QAASnB,EACToB,OA9Ba,SAACX,GAEd,IACMY,EADQb,EAAUC,GACEN,EAAIc,WAC9BhB,EAAcoB,EAChB,EA0BEC,MAzBY,SAACb,GAEb,IAAMc,EAAQf,EAAUC,GAClBe,EAAQrB,EAAIc,WACZI,EAAYE,EAAQC,EACpBC,EAjBa,SAAChB,GACpB,OAAOH,GAAOG,EAAOiB,UAAYjB,EAAOiB,SAC1C,CAemBC,CAAalB,GAExBmB,EAAiBH,GAAY,IAAMA,EAAW,IAAOF,EADjDC,EAAQ,GAGZK,GADUD,EAAiB,EAAIP,EAAYA,GACfG,EAC9BM,EAAU,EACd,GAAID,EAAkB,EAAG,CACvB,IAAME,EAAMF,EAAkBG,KAAKC,IAAIR,GACvCK,EAAUE,KAAKE,IAAIH,EAAK,IAC1B,CACA7B,EAAa0B,EAAgBP,GAAa,EAAI,KAAOc,EAAAA,EAAAA,GAAM,EAAGd,EAAW,OAASS,EACpF,GAWF,C","sources":["../node_modules/@ionic/core/components/swipe-back.js"],"sourcesContent":["/*!\n * (C) Ionic http://ionicframework.com - MIT License\n */\nimport { h as clamp } from './helpers.js';\nimport { i as isRTL } from './dir.js';\nimport { createGesture } from './index2.js';\n\nconst createSwipeBackGesture = (el, canStartHandler, onStartHandler, onMoveHandler, onEndHandler) => {\n const win = el.ownerDocument.defaultView;\n const rtl = isRTL(el);\n /**\n * Determine if a gesture is near the edge\n * of the screen. If true, then the swipe\n * to go back gesture should proceed.\n */\n const isAtEdge = (detail) => {\n const threshold = 50;\n const { startX } = detail;\n if (rtl) {\n return startX >= win.innerWidth - threshold;\n }\n return startX <= threshold;\n };\n const getDeltaX = (detail) => {\n return rtl ? -detail.deltaX : detail.deltaX;\n };\n const getVelocityX = (detail) => {\n return rtl ? -detail.velocityX : detail.velocityX;\n };\n const canStart = (detail) => {\n return isAtEdge(detail) && canStartHandler();\n };\n const onMove = (detail) => {\n // set the transition animation's progress\n const delta = getDeltaX(detail);\n const stepValue = delta / win.innerWidth;\n onMoveHandler(stepValue);\n };\n const onEnd = (detail) => {\n // the swipe back gesture has ended\n const delta = getDeltaX(detail);\n const width = win.innerWidth;\n const stepValue = delta / width;\n const velocity = getVelocityX(detail);\n const z = width / 2.0;\n const shouldComplete = velocity >= 0 && (velocity > 0.2 || delta > z);\n const missing = shouldComplete ? 1 - stepValue : stepValue;\n const missingDistance = missing * width;\n let realDur = 0;\n if (missingDistance > 5) {\n const dur = missingDistance / Math.abs(velocity);\n realDur = Math.min(dur, 540);\n }\n onEndHandler(shouldComplete, stepValue <= 0 ? 0.01 : clamp(0, stepValue, 0.9999), realDur);\n };\n return createGesture({\n el,\n gestureName: 'goback-swipe',\n gesturePriority: 40,\n threshold: 10,\n canStart,\n onStart: onStartHandler,\n onMove,\n onEnd,\n });\n};\n\nexport { createSwipeBackGesture };\n"],"names":["createSwipeBackGesture","el","canStartHandler","onStartHandler","onMoveHandler","onEndHandler","win","ownerDocument","defaultView","rtl","isRTL","getDeltaX","detail","deltaX","createGesture","gestureName","gesturePriority","threshold","canStart","startX","innerWidth","isAtEdge","onStart","onMove","stepValue","onEnd","delta","width","velocity","velocityX","getVelocityX","shouldComplete","missingDistance","realDur","dur","Math","abs","min","clamp"],"sourceRoot":""}