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/components/VCalendar/mixins/calendar-with-intervals.js.map
2019-08-11 20:48:02 +02:00

1 line
No EOL
8.5 KiB
Text

{"version":3,"sources":["../../../../src/components/VCalendar/mixins/calendar-with-intervals.ts"],"names":[],"mappings":"AACA;AACA,OAAO,YAAP,MAAyB,iBAAzB,C,CAEA;;AACA,OAAO,KAAP,MAAkB,eAAlB;AACA,SAIE,SAJF,EAKE,aALF,EAME,aANF,EAOE,aAPF,EAQE,kBARF,EASE,2BATF,QAUO,mBAVP;AAYA;;AACA,eAAe,YAAY,CAAC,MAAb,CAAoB;AACjC,EAAA,IAAI,EAAE,yBAD2B;AAGjC,EAAA,KAAK,EAAE,KAAK,CAAC,SAHoB;AAKjC,EAAA,QAAQ,EAAE;AACR,IAAA,mBAAmB,GAAA;AACjB,aAAO,QAAQ,CAAC,KAAK,aAAN,CAAf;AACD,KAHO;;AAIR,IAAA,qBAAqB,GAAA;AACnB,aAAO,QAAQ,CAAC,KAAK,eAAN,CAAf;AACD,KANO;;AAOR,IAAA,mBAAmB,GAAA;AACjB,aAAO,QAAQ,CAAC,KAAK,aAAN,CAAf;AACD,KATO;;AAUR,IAAA,oBAAoB,GAAA;AAClB,aAAO,UAAU,CAAC,KAAK,cAAN,CAAjB;AACD,KAZO;;AAaR,IAAA,WAAW,GAAA;AACT,aAAO,KAAK,mBAAL,GAA2B,KAAK,qBAAvC;AACD,KAfO;;AAgBR,IAAA,UAAU,GAAA;AACR,aAAO,KAAK,mBAAL,GAA2B,KAAK,oBAAvC;AACD,KAlBO;;AAmBR,IAAA,IAAI,GAAA;AACF,aAAO,aAAa,CAClB,KAAK,WADa,EAElB,KAAK,SAFa,EAGlB,KAAK,KAAL,CAAW,KAHO,EAIlB,KAAK,YAJa,EAKlB,KAAK,OALa,CAApB;AAOD,KA3BO;;AA4BR,IAAA,SAAS,GAAA;AACP,YAAM,IAAI,G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Aa;AACvB,YAAM,CAAC,GAAG,KAAK,OAAL,CAAa,IAAb,CAAV;AACA,YAAM,IAAI,GAAG,KAAK,KAAL,CAAW,UAAxB;;AAEA,UAAI,CAAC,KAAK,KAAN,IAAe,CAAC,IAApB,EAA0B;AACxB,eAAO,KAAP;AACD;;AAED,MAAA,IAAI,CAAC,SAAL,GAAiB,CAAjB;AAEA,aAAO,IAAP;AACD,KAxCM;;AAyCP,IAAA,eAAe,CAAE,OAAF,EAAiB;AAC9B,aAAO,OAAO,GAAG,KAAK,qBAAf,GAAuC,KAAK,oBAAnD;AACD,KA3CM;;AA4CP,IAAA,OAAO,CAAE,IAAF,EAAe,KAAK,GAAG,IAAvB,EAA2B;AAChC,YAAM,OAAO,GAAG,SAAS,CAAC,IAAD,CAAzB;;AAEA,UAAI,OAAO,KAAK,KAAhB,EAAuB;AACrB,eAAO,KAAP;AACD;;AAED,YAAM,GAAG,GAAW,KAAK,WAAzB;AACA,YAAM,GAAG,GAAW,KAAK,mBAAL,GAA2B,KAAK,qBAApD;AACA,YAAM,KAAK,GAAW,CAAC,OAAO,GAAG,GAAX,IAAkB,GAAxC;AACA,UAAI,CAAC,GAAW,KAAK,GAAG,KAAK,UAA7B;;AAEA,UAAI,KAAJ,EAAW;AACT,YAAI,CAAC,GAAG,CAAR,EAAW;AACT,UAAA,CAAC,GAAG,CAAJ;AACD;;AACD,YAAI,CAAC,GAAG,KAAK,UAAb,EAAyB;AACvB,UAAA,CAAC,GAAG,KAAK,UAAT;AACD;AACF;;AAED,aAAO,CAAP;AACD;;AAlEM;AA1DwB,CAApB,CAAf","sourcesContent":["\n// Mixins\nimport CalendarBase from './calendar-base'\n\n// Util\nimport props from '../util/props'\nimport {\n VTimestamp,\n VTime,\n VTimestampFormatter,\n parseTime,\n copyTimestamp,\n updateMinutes,\n createDayList,\n createIntervalList,\n createNativeLocaleFormatter,\n} from '../util/timestamp'\n\n/* @vue/component */\nexport default CalendarBase.extend({\n name: 'calendar-with-intervals',\n\n props: props.intervals,\n\n computed: {\n parsedFirstInterval (): number {\n return parseInt(this.firstInterval)\n },\n parsedIntervalMinutes (): number {\n return parseInt(this.intervalMinutes)\n },\n parsedIntervalCount (): number {\n return parseInt(this.intervalCount)\n },\n parsedIntervalHeight (): number {\n return parseFloat(this.intervalHeight)\n },\n firstMinute (): number {\n return this.parsedFirstInterval * this.parsedIntervalMinutes\n },\n bodyHeight (): number {\n return this.parsedIntervalCount * this.parsedIntervalHeight\n },\n days (): VTimestamp[] {\n return createDayList(\n this.parsedStart,\n this.parsedEnd,\n this.times.today,\n this.weekdaySkips,\n this.maxDays\n )\n },\n intervals (): VTimestamp[][] {\n const days: VTimestamp[] = this.days\n const first: number = this.parsedFirstInterval\n const minutes: number = this.parsedIntervalMinutes\n const count: number = this.parsedIntervalCount\n const now: VTimestamp = this.times.now\n\n return days.map(d => createIntervalList(d, first, minutes, count, now))\n },\n intervalFormatter (): VTimestampFormatter {\n if (this.intervalFormat) {\n return this.intervalFormat as VTimestampFormatter\n }\n\n const longOptions = { timeZone: 'UTC', hour12: true, hour: '2-digit', minute: '2-digit' }\n const shortOptions = { timeZone: 'UTC', hour12: true, hour: 'numeric', minute: '2-digit' }\n const shortHourOptions = { timeZone: 'UTC', hour12: true, hour: 'numeric' }\n\n return createNativeLocaleFormatter(\n this.currentLocale,\n (tms, short) => short ? (tms.minute === 0 ? shortHourOptions : shortOptions) : longOptions\n )\n },\n },\n\n methods: {\n showIntervalLabelDefault (interval: VTimestamp): boolean {\n const first: VTimestamp = this.intervals[0][0]\n const isFirst: boolean = first.hour === interval.hour && first.minute === interval.minute\n return !isFirst && interval.minute === 0\n },\n intervalStyleDefault (_interval: VTimestamp): object | undefined {\n return undefined\n },\n getTimestampAtEvent (e: MouseEvent | TouchEvent, day: VTimestamp): VTimestamp {\n const timestamp: VTimestamp = copyTimestamp(day)\n const bounds = (e.currentTarget as HTMLElement).getBoundingClientRect()\n const baseMinutes: number = this.firstMinute\n const touchEvent: TouchEvent = e as TouchEvent\n const mouseEvent: MouseEvent = e as MouseEvent\n const touches: TouchList = touchEvent.changedTouches || touchEvent.touches\n const clientY: number = touches && touches[0] ? touches[0].clientY : mouseEvent.clientY\n const addIntervals: number = (clientY - bounds.top) / this.parsedIntervalHeight\n const addMinutes: number = Math.floor(addIntervals * this.parsedIntervalMinutes)\n const minutes: number = baseMinutes + addMinutes\n\n return updateMinutes(timestamp, minutes, this.times.now)\n },\n getSlotScope (timestamp: VTimestamp): any {\n const scope = copyTimestamp(timestamp) as any\n scope.timeToY = this.timeToY\n scope.minutesToPixels = this.minutesToPixels\n return scope\n },\n scrollToTime (time: VTime): boolean {\n const y = this.timeToY(time)\n const pane = this.$refs.scrollArea as HTMLElement\n\n if (y === false || !pane) {\n return false\n }\n\n pane.scrollTop = y\n\n return true\n },\n minutesToPixels (minutes: number): number {\n return minutes / this.parsedIntervalMinutes * this.parsedIntervalHeight\n },\n timeToY (time: VTime, clamp = true): number | false {\n const minutes = parseTime(time)\n\n if (minutes === false) {\n return false\n }\n\n const min: number = this.firstMinute\n const gap: number = this.parsedIntervalCount * this.parsedIntervalMinutes\n const delta: number = (minutes - min) / gap\n let y: number = delta * this.bodyHeight\n\n if (clamp) {\n if (y < 0) {\n y = 0\n }\n if (y > this.bodyHeight) {\n y = this.bodyHeight\n }\n }\n\n return y\n },\n },\n})\n"],"sourceRoot":"","file":"calendar-with-intervals.js"}