{"version":3,"sources":["webpack:///../../../src/mixins/validatable/index.ts","webpack:///../../../src/components/VLabel/VLabel.ts","webpack:///../../../src/components/VLabel/index.ts","webpack:///../../../src/components/VMessages/VMessages.ts","webpack:///../../../src/components/VMessages/index.ts","webpack:///../../../src/components/VInput/VInput.ts","webpack:///../../../src/components/VInput/index.ts"],"names":["baseMixins","mixins","Colorable","RegistrableInject","Themeable","extend","name","props","disabled","type","Boolean","default","error","errorCount","Number","String","errorMessages","Array","messages","readonly","rules","success","successMessages","validateOnBlur","value","required","data","errorBucket","hasColor","hasFocused","hasInput","isFocused","isResetting","lazyValue","this","valid","computed","computedColor","isDisabled","color","isDark","appIsDark","hasError","internalErrorMessages","length","hasSuccess","internalSuccessMessages","externalError","hasMessages","validationTarget","hasState","shouldValidate","genInternalMessages","internalMessages","internalValue","get","set","val","$emit","_a","form","isInteractive","isReadonly","validations","slice","validationState","watch","handler","newVal","oldVal","deepEqual","validate","deep","$nextTick","_this","setTimeout","beforeMount","created","register","beforeDestroy","unregister","methods","isArray","reset","resetValidation","force","arguments","undefined","index","rule","push","consoleError","concat","_typeof","functional","absolute","focused","for","left","right","render","h","ctx","children","listeners","newData","mergeData","staticClass","class","_objectSpread","functionalThemeClasses","attrs","on","style","convertToUnit","position","ref","options","setTextColor","VLabel","genChildren","$createElement","tag","map","genMessage","message","key","getSlot","themeClasses","VMessages","BindsAttrs","Validatable","inheritAttrs","appendIcon","backgroundColor","dense","height","hideDetails","hideSpinButtons","hint","id","label","loading","persistentHint","prependIcon","hasMouseDown","classes","showDetails","isLabelActive","isDirty","computedId","_uid","hasDetails","messagesToDisplay","hasHint","hasLabel","$slots","$_modelEvent","validation","validationResult","filter","beforeCreate","$options","model","event","genContent","genPrependSlot","genControl","genAppendSlot","title","attrs$","genInputSlot","genMessages","genDefaultSlot","genLabel","genIcon","cb","_this2","extraData","icon","eventName","kebabCase","hasListener","listeners$","localeKey","prepend","prependInner","append","appendOuter","clear","$vuetify","lang","t","dark","light","tabindex","click","e","preventDefault","stopPropagation","mouseup","VIcon","setBackgroundColor","onClick","mousedown","onMouseDown","onMouseUp","_this3","role","scopedSlots","genSlot","location","slot","VInput"],"mappings":"mQAcMA,EAAaC,eACjBC,OACAC,eAA+B,QAC/BC,QAIaJ,SAAWK,OAAO,CAC/BC,KAAM,cAENC,MAAO,CACLC,SAAU,CACRC,KAAMC,QACNC,QAAS,MAEXC,MAAOF,QACPG,WAAY,CACVJ,KAAM,CAACK,OAAQC,QACfJ,QAAS,GAEXK,cAAe,CACbP,KAAM,CAACM,OAAQE,OACfN,QAAS,WAAF,MAAQ,KAEjBO,SAAU,CACRT,KAAM,CAACM,OAAQE,OACfN,QAAS,WAAF,MAAQ,KAEjBQ,SAAU,CACRV,KAAMC,QACNC,QAAS,MAEXS,MAAO,CACLX,KAAMQ,MACNN,QAAS,WAAF,MAAQ,KAEjBU,QAASX,QACTY,gBAAiB,CACfb,KAAM,CAACM,OAAQE,OACfN,QAAS,WAAF,MAAQ,KAEjBY,eAAgBb,QAChBc,MAAO,CAAEC,UAAU,IAGrBC,KAAI,WACF,MAAO,CACLC,YAAa,GACbC,UAAU,EACVC,YAAY,EACZC,UAAU,EACVC,WAAW,EACXC,aAAa,EACbC,UAAWC,KAAKV,MAChBW,OAAO,IAIXC,SAAU,CACRC,cAAa,WACX,IAAIH,KAAKI,WACT,OAAIJ,KAAKK,MAAcL,KAAKK,MAMxBL,KAAKM,SAAWN,KAAKO,UAAkB,QAC/B,WAEdC,SAAQ,WACN,OACER,KAAKS,sBAAsBC,OAAS,GACpCV,KAAKP,YAAYiB,OAAS,GAC1BV,KAAKtB,OAKTiC,WAAU,WACR,OACEX,KAAKY,wBAAwBF,OAAS,GACtCV,KAAKb,SAGT0B,cAAa,WACX,OAAOb,KAAKS,sBAAsBC,OAAS,GAAKV,KAAKtB,OAEvDoC,YAAW,WACT,OAAOd,KAAKe,iBAAiBL,OAAS,GAExCM,SAAQ,WACN,OAAIhB,KAAKI,aAGPJ,KAAKW,YACJ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H,OAAO+B,OACdyB,EAAK1H,KAAKxD,KAAK0H,OAAO+B,QACbzJ,KAAKmG,YACd+E,EAAK1H,KAAKxD,KAAK6I,QAAQ,WAGlB7I,KAAKgL,QAAQ,SAAU,QAASE,IAEzCT,QAAO,SAAEN,GACPnK,KAAKwB,MAAM,QAAS2I,IAEtBQ,YAAW,SAAER,GACXnK,KAAK+G,cAAe,EACpB/G,KAAKwB,MAAM,YAAa2I,IAE1BS,UAAS,SAAET,GACTnK,KAAK+G,cAAe,EACpB/G,KAAKwB,MAAM,UAAW2I,KAI1BjG,OAAM,SAAEC,GACN,OAAOA,EAAE,MAAOnE,KAAKoF,aAAapF,KAAK+B,gBAAiB,CACtD0C,YAAa,UACbC,MAAO1E,KAAKgH,UACVhH,KAAKmI,iBCvUEgD,U","file":"js/chunk-f604550e.79cc4d2e.js","sourcesContent":["// Mixins\nimport Colorable from '../colorable'\nimport Themeable from '../themeable'\nimport { inject as RegistrableInject } from '../registrable'\n\n// Utilities\nimport { deepEqual } from '../../util/helpers'\nimport { consoleError } from '../../util/console'\nimport mixins from '../../util/mixins'\n\n// Types\nimport { PropValidator } from 'vue/types/options'\nimport { InputMessage, InputValidationRules } from 'vuetify/types'\n\nconst baseMixins = mixins(\n Colorable,\n RegistrableInject<'form', any>('form'),\n Themeable,\n)\n\n/* @vue/component */\nexport default baseMixins.extend({\n name: 'validatable',\n\n props: {\n disabled: {\n type: Boolean,\n default: null,\n },\n error: Boolean,\n errorCount: {\n type: [Number, String],\n default: 1,\n },\n errorMessages: {\n type: [String, Array],\n default: () => [],\n } as PropValidator,\n messages: {\n type: [String, Array],\n default: () => [],\n } as PropValidator,\n readonly: {\n type: Boolean,\n default: null,\n },\n rules: {\n type: Array,\n default: () => [],\n } as PropValidator,\n success: Boolean,\n successMessages: {\n type: [String, Array],\n default: () => [],\n } as PropValidator,\n validateOnBlur: Boolean,\n value: { required: false },\n },\n\n data () {\n return {\n errorBucket: [] as string[],\n hasColor: false,\n hasFocused: false,\n hasInput: false,\n isFocused: false,\n isResetting: false,\n lazyValue: this.value,\n valid: false,\n }\n },\n\n computed: {\n computedColor (): string | undefined {\n if (this.isDisabled) return undefined\n if (this.color) return this.color\n // It's assumed that if the input is on a\n // dark background, the user will want to\n // have a white color. If the entire app\n // is setup to be dark, then they will\n // like want to use their primary color\n if (this.isDark && !this.appIsDark) return 'white'\n else return 'primary'\n },\n hasError (): boolean {\n return (\n this.internalErrorMessages.length > 0 ||\n this.errorBucket.length > 0 ||\n this.error\n )\n },\n // TODO: Add logic that allows the user to enable based\n // upon a good validation\n hasSuccess (): boolean {\n return (\n this.internalSuccessMessages.length > 0 ||\n this.success\n )\n },\n externalError (): boolean {\n return this.internalErrorMessages.length > 0 || this.error\n },\n hasMessages (): boolean {\n return this.validationTarget.length > 0\n },\n hasState (): boolean {\n if (this.isDisabled) return false\n\n return (\n this.hasSuccess ||\n (this.shouldValidate && this.hasError)\n )\n },\n internalErrorMessages (): InputValidationRules {\n return this.genInternalMessages(this.errorMessages)\n },\n internalMessages (): InputValidationRules {\n return this.genInternalMessages(this.messages)\n },\n internalSuccessMessages (): InputValidationRules {\n return this.genInternalMessages(this.successMessages)\n },\n internalValue: {\n get (): unknown {\n return this.lazyValue\n },\n set (val: any) {\n this.lazyValue = val\n\n this.$emit('input', val)\n },\n },\n isDisabled (): boolean {\n return this.disabled ?? (\n !!this.form &&\n this.form.disabled\n )\n },\n isInteractive (): boolean {\n return !this.isDisabled && !this.isReadonly\n },\n isReadonly (): boolean {\n return this.readonly ?? (\n !!this.form &&\n this.form.readonly\n )\n },\n shouldValidate (): boolean {\n if (this.externalError) return true\n if (this.isResetting) return false\n\n return this.validateOnBlur\n ? this.hasFocused && !this.isFocused\n : (this.hasInput || this.hasFocused)\n },\n validations (): InputValidationRules {\n return this.validationTarget.slice(0, Number(this.errorCount))\n },\n validationState (): string | undefined {\n if (this.isDisabled) return undefined\n if (this.hasError && this.shouldValidate) return 'error'\n if (this.hasSuccess) return 'success'\n if (this.hasColor) return this.computedColor\n return undefined\n },\n validationTarget (): InputValidationRules {\n if (this.internalErrorMessages.length > 0) {\n return this.internalErrorMessages\n } else if (this.successMessages && this.successMessages.length > 0) {\n return this.internalSuccessMessages\n } else if (this.messages && this.messages.length > 0) {\n return this.internalMessages\n } else if (this.shouldValidate) {\n return this.errorBucket\n } else return []\n },\n },\n\n watch: {\n rules: {\n handler (newVal, oldVal) {\n if (deepEqual(newVal, oldVal)) return\n this.validate()\n },\n deep: true,\n },\n internalValue () {\n // If it's the first time we're setting input,\n // mark it with hasInput\n this.hasInput = true\n this.validateOnBlur || this.$nextTick(this.validate)\n },\n isFocused (val) {\n // Should not check validation\n // if disabled\n if (\n !val &&\n !this.isDisabled\n ) {\n this.hasFocused = true\n this.validateOnBlur && this.$nextTick(this.validate)\n }\n },\n isResetting () {\n setTimeout(() => {\n this.hasInput = false\n this.hasFocused = false\n this.isResetting = false\n this.validate()\n }, 0)\n },\n hasError (val) {\n if (this.shouldValidate) {\n this.$emit('update:error', val)\n }\n },\n value (val) {\n this.lazyValue = val\n },\n },\n\n beforeMount () {\n this.validate()\n },\n\n created () {\n this.form && this.form.register(this)\n },\n\n beforeDestroy () {\n this.form && this.form.unregister(this)\n },\n\n methods: {\n genInternalMessages (messages: InputMessage | null): InputValidationRules {\n if (!messages) return []\n else if (Array.isArray(messages)) return messages\n else return [messages]\n },\n /** @public */\n reset () {\n this.isResetting = true\n this.internalValue = Array.isArray(this.internalValue)\n ? []\n : null\n },\n /** @public */\n resetValidation () {\n this.isResetting = true\n },\n /** @public */\n validate (force = false, value?: any): boolean {\n const errorBucket = []\n value = value || this.internalValue\n\n if (force) this.hasInput = this.hasFocused = true\n\n for (let index = 0; index < this.rules.length; index++) {\n const rule = this.rules[index]\n const valid = typeof rule === 'function' ? rule(value) : rule\n\n if (valid === false || typeof valid === 'string') {\n errorBucket.push(valid || '')\n } else if (typeof valid !== 'boolean') {\n consoleError(`Rules should return a string or boolean, received '${typeof valid}' instead`, this)\n }\n }\n\n this.errorBucket = errorBucket\n this.valid = errorBucket.length === 0\n\n return this.valid\n },\n },\n})\n","// Styles\nimport './VLabel.sass'\n\n// Mixins\nimport Colorable from '../../mixins/colorable'\nimport Themeable, { functionalThemeClasses } from '../../mixins/themeable'\n\n// Types\nimport { VNode } from 'vue'\nimport mixins from '../../util/mixins'\n\n// Helpers\nimport { convertToUnit } from '../../util/helpers'\nimport mergeData from '../../util/mergeData'\n\n/* @vue/component */\nexport default mixins(Themeable).extend({\n name: 'v-label',\n\n functional: true,\n\n props: {\n absolute: Boolean,\n color: {\n type: String,\n default: 'primary',\n },\n disabled: Boolean,\n focused: Boolean,\n for: String,\n left: {\n type: [Number, String],\n default: 0,\n },\n right: {\n type: [Number, String],\n default: 'auto',\n },\n value: Boolean,\n },\n\n render (h, ctx): VNode {\n const { children, listeners, props, data } = ctx\n const newData = mergeData({\n staticClass: 'v-label',\n class: {\n 'v-label--active': props.value,\n 'v-label--is-disabled': props.disabled,\n ...functionalThemeClasses(ctx),\n },\n attrs: {\n for: props.for,\n 'aria-hidden': !props.for,\n },\n on: listeners,\n style: {\n left: convertToUnit(props.left),\n right: convertToUnit(props.right),\n position: props.absolute ? 'absolute' : 'relative',\n },\n ref: 'label',\n }, data)\n\n return h('label', Colorable.options.methods.setTextColor(props.focused && props.color, newData), children)\n },\n})\n","import VLabel from './VLabel'\n\nexport { VLabel }\nexport default VLabel\n","// Styles\nimport './VMessages.sass'\n\n// Mixins\nimport Colorable from '../../mixins/colorable'\nimport Themeable from '../../mixins/themeable'\n\n// Types\nimport { VNode } from 'vue'\nimport { PropValidator } from 'vue/types/options'\nimport mixins from '../../util/mixins'\n\n// Utilities\nimport { getSlot } from '../../util/helpers'\n\n/* @vue/component */\nexport default mixins(Colorable, Themeable).extend({\n name: 'v-messages',\n\n props: {\n value: {\n type: Array,\n default: () => ([]),\n } as PropValidator,\n },\n\n methods: {\n genChildren () {\n return this.$createElement('transition-group', {\n staticClass: 'v-messages__wrapper',\n attrs: {\n name: 'message-transition',\n tag: 'div',\n },\n }, this.value.map(this.genMessage))\n },\n genMessage (message: string, key: number) {\n return this.$createElement('div', {\n staticClass: 'v-messages__message',\n key,\n }, getSlot(this, 'default', { message, key }) || [message])\n },\n },\n\n render (h): VNode {\n return h('div', this.setTextColor(this.color, {\n staticClass: 'v-messages',\n class: this.themeClasses,\n }), [this.genChildren()])\n },\n})\n","import VMessages from './VMessages'\n\nexport { VMessages }\nexport default VMessages\n","// Styles\nimport './VInput.sass'\n\n// Components\nimport VIcon from '../VIcon'\nimport VLabel from '../VLabel'\nimport VMessages from '../VMessages'\n\n// Mixins\nimport BindsAttrs from '../../mixins/binds-attrs'\nimport Validatable from '../../mixins/validatable'\n\n// Utilities\nimport {\n convertToUnit,\n getSlot,\n kebabCase,\n} from '../../util/helpers'\nimport mergeData from '../../util/mergeData'\n\n// Types\nimport { VNode, VNodeData, PropType } from 'vue'\nimport mixins from '../../util/mixins'\nimport { InputValidationRule } from 'vuetify/types'\n\nconst baseMixins = mixins(\n BindsAttrs,\n Validatable,\n)\n\ninterface options extends InstanceType {\n /* eslint-disable-next-line camelcase */\n $_modelEvent: string\n}\n\n/* @vue/component */\nexport default baseMixins.extend().extend({\n name: 'v-input',\n\n inheritAttrs: false,\n\n props: {\n appendIcon: String,\n backgroundColor: {\n type: String,\n default: '',\n },\n dense: Boolean,\n height: [Number, String],\n hideDetails: [Boolean, String] as PropType,\n hideSpinButtons: Boolean,\n hint: String,\n id: String,\n label: String,\n loading: Boolean,\n persistentHint: Boolean,\n prependIcon: String,\n value: null as any as PropType,\n },\n\n data () {\n return {\n lazyValue: this.value,\n hasMouseDown: false,\n }\n },\n\n computed: {\n classes (): object {\n return {\n 'v-input--has-state': this.hasState,\n 'v-input--hide-details': !this.showDetails,\n 'v-input--is-label-active': this.isLabelActive,\n 'v-input--is-dirty': this.isDirty,\n 'v-input--is-disabled': this.isDisabled,\n 'v-input--is-focused': this.isFocused,\n // .loading === '' so we can't just cast to boolean\n 'v-input--is-loading': this.loading !== false && this.loading != null,\n 'v-input--is-readonly': this.isReadonly,\n 'v-input--dense': this.dense,\n 'v-input--hide-spin-buttons': this.hideSpinButtons,\n ...this.themeClasses,\n }\n },\n computedId (): string {\n return this.id || `input-${this._uid}`\n },\n hasDetails (): boolean {\n return this.messagesToDisplay.length > 0\n },\n hasHint (): boolean {\n return !this.hasMessages &&\n !!this.hint &&\n (this.persistentHint || this.isFocused)\n },\n hasLabel (): boolean {\n return !!(this.$slots.label || this.label)\n },\n // Proxy for `lazyValue`\n // This allows an input\n // to function without\n // a provided model\n internalValue: {\n get (): any {\n return this.lazyValue\n },\n set (val: any) {\n this.lazyValue = val\n this.$emit(this.$_modelEvent, val)\n },\n },\n isDirty (): boolean {\n return !!this.lazyValue\n },\n isLabelActive (): boolean {\n return this.isDirty\n },\n messagesToDisplay (): string[] {\n if (this.hasHint) return [this.hint]\n\n if (!this.hasMessages) return []\n\n return this.validations.map((validation: string | InputValidationRule) => {\n if (typeof validation === 'string') return validation\n\n const validationResult = validation(this.internalValue)\n\n return typeof validationResult === 'string' ? validationResult : ''\n }).filter(message => message !== '')\n },\n showDetails (): boolean {\n return this.hideDetails === false || (this.hideDetails === 'auto' && this.hasDetails)\n },\n },\n\n watch: {\n value (val) {\n this.lazyValue = val\n },\n },\n\n beforeCreate () {\n // v-radio-group needs to emit a different event\n // https://github.com/vuetifyjs/vuetify/issues/4752\n this.$_modelEvent = (this.$options.model && this.$options.model.event) || 'input'\n },\n\n methods: {\n genContent () {\n return [\n this.genPrependSlot(),\n this.genControl(),\n this.genAppendSlot(),\n ]\n },\n genControl () {\n return this.$createElement('div', {\n staticClass: 'v-input__control',\n attrs: { title: this.attrs$.title },\n }, [\n this.genInputSlot(),\n this.genMessages(),\n ])\n },\n genDefaultSlot () {\n return [\n this.genLabel(),\n getSlot(this),\n ]\n },\n genIcon (\n type: string,\n cb?: (e: Event) => void,\n extraData: VNodeData = {}\n ) {\n const icon = (this as any)[`${type}Icon`]\n const eventName = `click:${kebabCase(type)}`\n const hasListener = !!(this.listeners$[eventName] || cb)\n\n const localeKey = {\n prepend: 'prependAction',\n prependInner: 'prependAction',\n append: 'appendAction',\n appendOuter: 'appendAction',\n clear: 'clear',\n }[type]\n const label = hasListener && localeKey\n ? this.$vuetify.lang.t(`$vuetify.input.${localeKey}`, this.label ?? '')\n : undefined\n\n const data = mergeData({\n attrs: {\n 'aria-label': label,\n color: this.validationState,\n dark: this.dark,\n disabled: this.isDisabled,\n light: this.light,\n tabindex: type === 'clear' ? -1 : undefined,\n },\n on: !hasListener\n ? undefined\n : {\n click: (e: Event) => {\n e.preventDefault()\n e.stopPropagation()\n\n this.$emit(eventName, e)\n cb && cb(e)\n },\n // Container has g event that will\n // trigger menu open if enclosed\n mouseup: (e: Event) => {\n e.preventDefault()\n e.stopPropagation()\n },\n },\n }, extraData)\n\n return this.$createElement('div', {\n staticClass: `v-input__icon`,\n class: type ? `v-input__icon--${kebabCase(type)}` : undefined,\n }, [\n this.$createElement(\n VIcon,\n data,\n icon\n ),\n ])\n },\n genInputSlot () {\n return this.$createElement('div', this.setBackgroundColor(this.backgroundColor, {\n staticClass: 'v-input__slot',\n style: { height: convertToUnit(this.height) },\n on: {\n click: this.onClick,\n mousedown: this.onMouseDown,\n mouseup: this.onMouseUp,\n },\n ref: 'input-slot',\n }), [this.genDefaultSlot()])\n },\n genLabel () {\n if (!this.hasLabel) return null\n\n return this.$createElement(VLabel, {\n props: {\n color: this.validationState,\n dark: this.dark,\n disabled: this.isDisabled,\n focused: this.hasState,\n for: this.computedId,\n light: this.light,\n },\n }, getSlot(this, 'label') || this.label)\n },\n genMessages () {\n if (!this.showDetails) return null\n\n return this.$createElement(VMessages, {\n props: {\n color: this.hasHint ? '' : this.validationState,\n dark: this.dark,\n light: this.light,\n value: this.messagesToDisplay,\n },\n attrs: {\n role: this.hasMessages ? 'alert' : null,\n },\n scopedSlots: {\n default: props => getSlot(this, 'message', props),\n },\n })\n },\n genSlot (\n type: string,\n location: string,\n slot: (VNode | VNode[])[]\n ) {\n if (!slot.length) return null\n\n const ref = `${type}-${location}`\n\n return this.$createElement('div', {\n staticClass: `v-input__${ref}`,\n ref,\n }, slot)\n },\n genPrependSlot () {\n const slot = []\n\n if (this.$slots.prepend) {\n slot.push(this.$slots.prepend)\n } else if (this.prependIcon) {\n slot.push(this.genIcon('prepend'))\n }\n\n return this.genSlot('prepend', 'outer', slot)\n },\n genAppendSlot () {\n const slot = []\n\n // Append icon for text field was really\n // an appended inner icon, v-text-field\n // will overwrite this method in order to obtain\n // backwards compat\n if (this.$slots.append) {\n slot.push(this.$slots.append)\n } else if (this.appendIcon) {\n slot.push(this.genIcon('append'))\n }\n\n return this.genSlot('append', 'outer', slot)\n },\n onClick (e: Event) {\n this.$emit('click', e)\n },\n onMouseDown (e: Event) {\n this.hasMouseDown = true\n this.$emit('mousedown', e)\n },\n onMouseUp (e: Event) {\n this.hasMouseDown = false\n this.$emit('mouseup', e)\n },\n },\n\n render (h): VNode {\n return h('div', this.setTextColor(this.validationState, {\n staticClass: 'v-input',\n class: this.classes,\n }), this.genContent())\n },\n})\n","import VInput from './VInput'\n\nexport { VInput }\nexport default VInput\n"],"sourceRoot":""}