This repository has been archived on 2024-07-27. You can view files and clone it, but cannot push or open issues or pull requests.
keksAccountGUI/node_modulesOLD/vuetify/lib/services/goto/index.js.map
2019-08-11 20:48:02 +02:00

1 line
No EOL
4.6 KiB
Text

{"version":3,"sources":["../../../src/services/goto/index.ts"],"names":[],"mappings":"AAAA;AACA,SAAS,OAAT,QAAwB,YAAxB,C,CAEA;;AACA,OAAO,KAAK,cAAZ,MAAgC,mBAAhC;AACA,SACE,YADF,EAEE,SAFF,QAGO,QAHP;AAUA,eAAc,SAAU,IAAV,CACZ,OADY,EAEZ,SAAA,GAAyC,EAF7B,EAE+B;AAE3C,QAAM,QAAQ,GAAuB;AACnC,IAAA,SAAS,EAAG,QAAQ,CAAC,gBAAT,IAAoD,QAAQ,CAAC,IAA7D,IAAqE,QAAQ,CAAC,eADvD;AAEnC,IAAA,QAAQ,EAAE,GAFyB;AAGnC,IAAA,MAAM,EAAE,CAH2B;AAInC,IAAA,MAAM,EAAE,gBAJ2B;AAKnC,IAAA,SAAS,EAAE,IALwB;AAMnC,OAAG;AANgC,GAArC;AAQA,QAAM,SAAS,GAAG,YAAY,CAAC,QAAQ,CAAC,SAAV,CAA9B;AAEA;;AACA,MAAI,QAAQ,CAAC,SAAT,IAAsB,IAAI,CAAC,SAAL,CAAe,WAAzC,EAAsD;AACpD,UAAM,QAAQ,GAAG,SAAS,CAAC,SAAV,CAAoB,QAApB,CAA6B,qBAA7B,CAAjB;AACA,UAAM,SAAS,GAAG,SAAS,CAAC,SAAV,CAAoB,QAApB,CAA6B,8BAA7B,CAAlB;AACA,UAAM;AAAE,MAAA,GAAF;AAAO,MAAA;AAAP,QAAe,IAAI,CAAC,SAAL,CAAe,WAApC;AAEA,IAAA,QAAQ,CAAC,MAAT,IAAmB,GAAnB;AACA;;AACA,QAAI,CAAC,QAAD,IAAa,SAAjB,EAA4B,QAAQ,CAAC,MAAT,IAAmB,GAAnB;AAC7B;;AAED,QAAM,SAAS,GAAG,WAAW,CAAC,GAAZ,EAAl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M,MAAO,IAAP,SAAoB,OAApB,CAA2B;AAG/B,EAAA,WAAA,GAAA;AACE;AAEA,WAAO,IAAP;AACD;;AAP8B;AACjB,IAAA,CAAA,QAAA,GAAW,MAAX","sourcesContent":["// Extensions\nimport { Service } from '../service'\n\n// Utilities\nimport * as easingPatterns from './easing-patterns'\nimport {\n getContainer,\n getOffset,\n} from './util'\n\n// Types\nimport { VuetifyGoToOptions, VuetifyGoToTarget } from 'vuetify/types/services/goto'\n\nimport { VuetifyServiceContract } from 'vuetify/types/services'\n\nexport default function goTo (\n _target: VuetifyGoToTarget,\n _settings: Partial<VuetifyGoToOptions> = {}\n): Promise<number> {\n const settings: VuetifyGoToOptions = {\n container: (document.scrollingElement as HTMLElement | null) || document.body || document.documentElement,\n duration: 500,\n offset: 0,\n easing: 'easeInOutCubic',\n appOffset: true,\n ..._settings,\n }\n const container = getContainer(settings.container)\n\n /* istanbul ignore else */\n if (settings.appOffset && goTo.framework.application) {\n const isDrawer = container.classList.contains('v-navigation-drawer')\n const isClipped = container.classList.contains('v-navigation-drawer--clipped')\n const { bar, top } = goTo.framework.application as any\n\n settings.offset += bar\n /* istanbul ignore else */\n if (!isDrawer || isClipped) settings.offset += top\n }\n\n const startTime = performance.now()\n const targetLocation = getOffset(_target) - settings.offset!\n const startLocation = container.scrollTop\n if (targetLocation === startLocation) return Promise.resolve(targetLocation)\n\n const ease = typeof settings.easing === 'function'\n ? settings.easing\n : easingPatterns[settings.easing!]\n /* istanbul ignore else */\n if (!ease) throw new TypeError(`Easing function \"${settings.easing}\" not found.`)\n\n // Cannot be tested properly in jsdom\n // tslint:disable-next-line:promise-must-complete\n /* istanbul ignore next */\n return new Promise(resolve => requestAnimationFrame(function step (currentTime: number) {\n const timeElapsed = currentTime - startTime\n const progress = Math.abs(settings.duration ? Math.min(timeElapsed / settings.duration, 1) : 1)\n\n container.scrollTop = Math.floor(startLocation + (targetLocation - startLocation) * ease(progress))\n\n if (progress === 1 || container.clientHeight + container.scrollTop === container.scrollHeight) {\n return resolve(targetLocation)\n }\n\n requestAnimationFrame(step)\n }))\n}\n\ngoTo.framework = {} as Record<string, VuetifyServiceContract>\ngoTo.init = () => {}\n\nexport class Goto extends Service {\n public static property = 'goTo'\n\n constructor () {\n super()\n\n return goTo\n }\n}\n"],"sourceRoot":"","file":"index.js"}