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AAG,EAAE,OAhBsC;AAiB3C,QAAA,IAAI,EAAE;AAjBqC,OAAtC,CAAP;AAmBD;;AA1KM,GAlKF;;AA+UP,EAAA,MAAM,GAAA;AACJ,WAAO,KAAK,SAAL,CAAe,gBAAf,CAAP;AACD;;AAjVM,CAJM,CAAf","sourcesContent":["// Components\nimport VTimePickerTitle from './VTimePickerTitle'\nimport VTimePickerClock from './VTimePickerClock'\n\n// Mixins\nimport Picker from '../../mixins/picker'\nimport PickerButton from '../../mixins/picker-button'\n\n// Utils\nimport { createRange } from '../../util/helpers'\nimport pad from '../VDatePicker/util/pad'\nimport mixins from '../../util/mixins'\n\n// Types\nimport { VNode } from 'vue'\nimport { PropValidator } from 'vue/types/options'\n\nconst rangeHours24 = createRange(24)\nconst rangeHours12am = createRange(12)\nconst rangeHours12pm = rangeHours12am.map(v => v + 12)\nconst range60 = createRange(60)\nenum SelectingTimes {\n Hour = 1,\n Minute = 2,\n Second = 3\n}\nconst selectingNames = { 1: 'hour', 2: 'minute', 3: 'second' }\nexport { SelectingTimes }\n\ntype Period = 'am' | 'pm'\ntype AllowFunction = (val: number) => boolean\n\nexport default mixins(\n Picker,\n PickerButton\n/* @vue/component */\n).extend({\n name: 'v-time-picker',\n\n props: {\n allowedHours: {\n type: [Function, Array],\n } as PropValidator<AllowFunction | number[]>,\n allowedMinutes: {\n type: [Function, Array],\n } as PropValidator<AllowFunction | number[]>,\n allowedSeconds: {\n type: [Function, Array],\n } as PropValidator<AllowFunction | number[]>,\n disabled: Boolean,\n format: {\n type: String,\n default: 'ampm',\n validator (val) {\n return ['ampm', '24hr'].includes(val)\n },\n } as PropValidator<'ampm' | '24hr'>,\n min: String,\n max: String,\n readonly: Boolean,\n scrollable: Boolean,\n useSeconds: Boolean,\n value: null as any as PropValidator<any>,\n ampmInTitle: Boolean,\n },\n\n data () {\n return {\n inputHour: null as number | null,\n inputMinute: null as number | null,\n inputSecond: null as number | null,\n lazyInputHour: null as number | null,\n lazyInputMinute: null as number | null,\n lazyInputSecond: null as number | null,\n period: 'am' as Period,\n selecting: SelectingTimes.Hour,\n }\n },\n\n computed: {\n selectingHour: {\n get (): boolean {\n return this.selecting === SelectingTimes.Hour\n },\n set (v: boolean) {\n this.selecting = SelectingTimes.Hour\n },\n },\n selectingMinute: {\n get (): boolean {\n return this.selecting === SelectingTimes.Minute\n },\n set (v: boolean) {\n this.selecting = SelectingTimes.Minute\n },\n },\n selectingSecond: {\n get (): boolean {\n return this.selecting === SelectingTimes.Second\n },\n set (v: boolean) {\n this.selecting = SelectingTimes.Second\n },\n },\n isAllowedHourCb (): AllowFunction {\n let cb: AllowFunction\n\n if (this.allowedHours instanceof Array) {\n cb = (val: number) => (this.allowedHours as number[]).includes(val)\n } else {\n cb = this.allowedHours\n }\n\n if (!this.min && !this.max) return cb\n\n const minHour = this.min ? Number(this.min.split(':')[0]) : 0\n const maxHour = this.max ? Number(this.max.split(':')[0]) : 23\n\n return (val: number) => {\n return val >= minHour * 1 &&\n val <= maxHour * 1 &&\n (!cb || cb(val))\n }\n },\n isAllowedMinuteCb (): AllowFunction {\n let cb: AllowFunction\n\n const isHourAllowed = !this.isAllowedHourCb || this.inputHour === null || this.isAllowedHourCb(this.inputHour)\n if (this.allowedMinutes instanceof Array) {\n cb = (val: number) => (this.allowedMinutes as number[]).includes(val)\n } else {\n cb = this.allowedMinutes\n }\n\n if (!this.min && !this.max) {\n return isHourAllowed ? cb : () => false\n }\n\n const [minHour, minMinute] = this.min ? this.min.split(':').map(Number) : [0, 0]\n const [maxHour, maxMinute] = this.max ? this.max.split(':').map(Number) : [23, 59]\n const minTime = minHour * 60 + minMinute * 1\n const maxTime = maxHour * 60 + maxMinute * 1\n\n return (val: number) => {\n const time = 60 * this.inputHour! + val\n return time >= minTime &&\n time <= maxTime &&\n isHourAllowed &&\n (!cb || cb(val))\n }\n },\n isAllowedSecondCb (): AllowFunction {\n let cb: AllowFunction\n\n const isHourAllowed = !this.isAllowedHourCb || this.inputHour === null || this.isAllowedHourCb(this.inputHour)\n const isMinuteAllowed = isHourAllowed &&\n (!this.isAllowedMinuteCb ||\n this.inputMinute === null ||\n this.isAllowedMinuteCb(this.inputMinute)\n )\n\n if (this.allowedSeconds instanceof Array) {\n cb = (val: number) => (this.allowedSeconds as number[]).includes(val)\n } else {\n cb = this.allowedSeconds\n }\n\n if (!this.min && !this.max) {\n return isMinuteAllowed ? cb : () => false\n }\n\n const [minHour, minMinute, minSecond] = this.min ? this.min.split(':').map(Number) : [0, 0, 0]\n const [maxHour, maxMinute, maxSecond] = this.max ? this.max.split(':').map(Number) : [23, 59, 59]\n const minTime = minHour * 3600 + minMinute * 60 + (minSecond || 0) * 1\n const maxTime = maxHour * 3600 + maxMinute * 60 + (maxSecond || 0) * 1\n\n return (val: number) => {\n const time = 3600 * this.inputHour! + 60 * this.inputMinute! + val\n return time >= minTime &&\n time <= maxTime &&\n isMinuteAllowed &&\n (!cb || cb(val))\n }\n },\n isAmPm (): boolean {\n return this.format === 'ampm'\n },\n },\n\n watch: {\n value: 'setInputData',\n },\n\n mounted () {\n this.setInputData(this.value)\n this.$on('update:period', this.setPeriod)\n },\n\n methods: {\n genValue () {\n if (this.inputHour != null && this.inputMinute != null && (!this.useSeconds || this.inputSecond != null)) {\n return `${pad(this.inputHour)}:${pad(this.inputMinute)}` + (this.useSeconds ? `:${pad(this.inputSecond!)}` : '')\n }\n\n return null\n },\n emitValue () {\n const value = this.genValue()\n if (value !== null) this.$emit('input', value)\n },\n setPeriod (period: Period) {\n this.period = period\n if (this.inputHour != null) {\n const newHour = this.inputHour! + (period === 'am' ? -12 : 12)\n this.inputHour = this.firstAllowed('hour', newHour)\n this.emitValue()\n }\n },\n setInputData (value: string | null | Date) {\n if (value == null || value === '') {\n this.inputHour = null\n this.inputMinute = null\n this.inputSecond = null\n } else if (value instanceof Date) {\n this.inputHour = value.getHours()\n this.inputMinute = value.getMinutes()\n this.inputSecond = value.getSeconds()\n } else {\n const [, hour, minute, , second, period] = value.trim().toLowerCase().match(/^(\\d+):(\\d+)(:(\\d+))?([ap]m)?$/) || new Array(6)\n\n this.inputHour = period ? this.convert12to24(parseInt(hour, 10), period as Period) : parseInt(hour, 10)\n this.inputMinute = parseInt(minute, 10)\n this.inputSecond = parseInt(second || 0, 10)\n }\n\n this.period = (this.inputHour == null || this.inputHour < 12) ? 'am' : 'pm'\n },\n convert24to12 (hour: number) {\n return hour ? ((hour - 1) % 12 + 1) : 12\n },\n convert12to24 (hour: number, period: Period) {\n return hour % 12 + (period === 'pm' ? 12 : 0)\n },\n onInput (value: number) {\n if (this.selecting === SelectingTimes.Hour) {\n this.inputHour = this.isAmPm ? this.convert12to24(value, this.period) : value\n } else if (this.selecting === SelectingTimes.Minute) {\n this.inputMinute = value\n } else {\n this.inputSecond = value\n }\n this.emitValue()\n },\n onChange (value: number) {\n this.$emit(`click:${selectingNames[this.selecting]}`, value)\n\n const emitChange = this.selecting === (this.useSeconds ? SelectingTimes.Second : SelectingTimes.Minute)\n\n if (this.selecting === SelectingTimes.Hour) {\n this.selecting = SelectingTimes.Minute\n } else if (this.useSeconds && this.selecting === SelectingTimes.Minute) {\n this.selecting = SelectingTimes.Second\n }\n\n if (this.inputHour === this.lazyInputHour &&\n this.inputMinute === this.lazyInputMinute &&\n (!this.useSeconds || this.inputSecond === this.lazyInputSecond)\n ) return\n\n const time = this.genValue()\n if (time === null) return\n\n this.lazyInputHour = this.inputHour\n this.lazyInputMinute = this.inputMinute\n this.useSeconds && (this.lazyInputSecond = this.inputSecond)\n\n emitChange && this.$emit('change', time)\n },\n firstAllowed (type: 'hour' | 'minute' | 'second', value: number) {\n const allowedFn = type === 'hour' ? this.isAllowedHourCb : (type === 'minute' ? this.isAllowedMinuteCb : this.isAllowedSecondCb)\n if (!allowedFn) return value\n\n // TODO: clean up\n const range = type === 'minute'\n ? range60\n : (type === 'second'\n ? range60\n : (this.isAmPm\n ? (value < 12\n ? rangeHours12am\n : rangeHours12pm)\n : rangeHours24))\n const first = range.find(v => allowedFn((v + value) % range.length + range[0]))\n return ((first || 0) + value) % range.length + range[0]\n },\n genClock () {\n return this.$createElement(VTimePickerClock, {\n props: {\n allowedValues:\n this.selecting === SelectingTimes.Hour\n ? this.isAllowedHourCb\n : (this.selecting === SelectingTimes.Minute\n ? this.isAllowedMinuteCb\n : this.isAllowedSecondCb),\n color: this.color,\n dark: this.dark,\n disabled: this.disabled,\n double: this.selecting === SelectingTimes.Hour && !this.isAmPm,\n format: this.selecting === SelectingTimes.Hour\n ? (this.isAmPm ? this.convert24to12 : (val: number) => val)\n : (val: number) => pad(val, 2),\n light: this.light,\n max: this.selecting === SelectingTimes.Hour ? (this.isAmPm && this.period === 'am' ? 11 : 23) : 59,\n min: this.selecting === SelectingTimes.Hour && this.isAmPm && this.period === 'pm' ? 12 : 0,\n readonly: this.readonly,\n scrollable: this.scrollable,\n size: Number(this.width) - ((!this.fullWidth && this.landscape) ? 80 : 20),\n step: this.selecting === SelectingTimes.Hour ? 1 : 5,\n value: this.selecting === SelectingTimes.Hour\n ? this.inputHour\n : (this.selecting === SelectingTimes.Minute\n ? this.inputMinute\n : this.inputSecond),\n },\n on: {\n input: this.onInput,\n change: this.onChange,\n },\n ref: 'clock',\n })\n },\n genClockAmPm () {\n return this.$createElement('div', this.setTextColor(this.color || 'primary', {\n staticClass: 'v-time-picker-clock__ampm',\n }), [\n this.genPickerButton('period', 'am', 'AM', this.disabled || this.readonly),\n this.genPickerButton('period', 'pm', 'PM', this.disabled || this.readonly),\n ])\n },\n genPickerBody () {\n return this.$createElement('div', {\n staticClass: 'v-time-picker-clock__container',\n key: this.selecting,\n }, [\n !this.ampmInTitle && this.isAmPm && this.genClockAmPm(),\n this.genClock(),\n ])\n },\n genPickerTitle () {\n return this.$createElement(VTimePickerTitle, {\n props: {\n ampm: this.ampmInTitle && this.isAmPm,\n disabled: this.disabled,\n hour: this.inputHour,\n minute: this.inputMinute,\n second: this.inputSecond,\n period: this.period,\n readonly: this.readonly,\n useSeconds: this.useSeconds,\n selecting: this.selecting,\n },\n on: {\n 'update:selecting': (value: 1 | 2 | 3) => (this.selecting = value),\n 'update:period': this.setPeriod,\n },\n ref: 'title',\n slot: 'title',\n })\n },\n },\n\n render (): VNode {\n return this.genPicker('v-picker--time')\n },\n})\n"],"sourceRoot":"","file":"VTimePicker.js"} |