{"version":3,"sources":["webpack:///./node_modules/core-js/modules/es.object.is.js","webpack:///../../../src/components/VCounter/VCounter.ts","webpack:///../../../src/components/VCounter/index.ts","webpack:///../../../src/mixins/intersectable/index.ts","webpack:///../../../src/components/VTextField/VTextField.ts"],"names":["$","is","target","stat","mixins","Themeable","extend","name","functional","props","value","type","Number","String","default","max","render","h","ctx","parseInt","content","isGreater","staticClass","class","functionalThemeClasses","VCounter","intersectable","options","Vue","data","isIntersecting","mounted","Intersect","inserted","this","$el","onObserve","$vnode","destroyed","unbind","methods","entries","observer","i","length","onVisible","callback","consoleWarn","baseMixins","VInput","Intersectable","Loadable","dirtyTypes","directives","resize","ripple","inheritAttrs","appendOuterIcon","autofocus","Boolean","clearable","clearIcon","counter","counterValue","Function","filled","flat","fullWidth","label","outlined","placeholder","prefix","prependInnerIcon","persistentPlaceholder","reverse","rounded","shaped","singleLine","solo","soloInverted","suffix","badInput","labelWidth","prefixWidth","prependWidth","initialValue","isBooted","isClearing","computed","classes","call","isSingle","isSolo","isEnclosed","computedColor","Validatable","isFocused","color","computedCounterValue","internalValue","toString","hasCounter","hasDetails","get","lazyValue","set","val","$emit","isDirty","_a","isLabelActive","includes","hasLabel","labelPosition","offset","labelValue","$vuetify","rtl","left","right","showLabel","watch","$nextTick","setLabelWidth","setPrefixWidth","created","$attrs","hasOwnProperty","breaking","$watch","tryAutofocus","requestAnimationFrame","onResize","focus","onFocus","blur","e","window","$refs","input","clearableCallback","genAppendSlot","slot","$slots","push","genIcon","genSlot","genPrependInnerSlot","genIconSlot","append","appendIcon","genInputSlot","prepend","children","unshift","genClearIcon","$createElement","genCounter","attrs$","maxlength","dark","light","$scopedSlots","_b","_c","genControl","genDefaultSlot","genFieldset","genTextFieldSlot","genProgress","attrs","genLegend","genLabel","absolute","validationState","disabled","isDisabled","focused","for","computedId","VLabel","width","span","domProps","innerHTML","style","undefined","convertToUnit","genInput","listeners","Object","assign","listeners$","change","inputAttrs","title","id","readonly","isReadonly","on","onBlur","onInput","keydown","onKeyDown","ref","modifiers","quiet","genMessages","showDetails","messagesNode","counterNode","genAffix","onClick","root","attachedRoot","activeElement","validity","keyCode","keyCodes","enter","onMouseDown","preventDefault","stopPropagation","onMouseUp","hasMouseDown","Math","min","scrollWidth","offsetWidth","setPrependWidth","document","updateValue","hasColor"],"mappings":"qGAAA,IAAIA,EAAI,EAAQ,QACZC,EAAK,EAAQ,QAIjBD,EAAE,CAAEE,OAAQ,SAAUC,MAAM,GAAQ,CAClCF,GAAIA,K,mQCKSG,iBAAOC,QAAWC,OAAO,CACtCC,KAAM,YAENC,YAAY,EAEZC,MAAO,CACLC,MAAO,CACLC,KAAM,CAACC,OAAQC,QACfC,QAAS,IAEXC,IAAK,CAACH,OAAQC,SAGhBG,OAAM,SAAEC,EAAGC,GACT,IAAQT,EAAUS,EAAVT,MACFM,EAAMI,SAASV,EAAMM,IAAK,IAC1BL,EAAQS,SAASV,EAAMC,MAAO,IAC9BU,EAAUL,EAAM,GAAH,OAAML,EAAK,cAAMK,GAAQF,OAAOJ,EAAMC,OACnDW,EAAYN,GAAQL,EAAQK,EAElC,OAAOE,EAAE,MAAO,CACdK,YAAa,YACbC,MAAO,gBACL,cAAeF,GACZG,eAAuBN,KAE3BE,MClCQK,I,gDCMD,SAAUC,EAAeC,GACrC,OAAOC,OAAItB,OAAO,CAChBC,KAAM,gBAENsB,KAAM,iBAAO,CACXC,gBAAgB,IAGlBC,QAAO,WACLC,OAAUC,SAASC,KAAKC,IAAoB,CAC1C5B,KAAM,YACNG,MAAOwB,KAAKE,WACXF,KAAKG,SAGVC,UAAS,WACPN,OAAUO,OAAOL,KAAKC,IAAoB,CACxC5B,KAAM,YACNG,MAAOwB,KAAKE,WACXF,KAAKG,SAGVG,QAAS,CACPJ,UAAS,SAAEK,EAAsCC,EAAgCZ,GAG/E,GAFAI,KAAKJ,eAAiBA,EAEjBA,EAEL,IAAK,IAAIa,EAAI,EAAGC,EAASjB,EAAQkB,UAAUD,OAAQD,EAAIC,EA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BAElCxG,KAAKkD,aAAelD,KAAKwG,MAAM,iBAAiB0F,cAElDlG,aAAY,WACV,IACGhG,KAAKwB,WACc,qBAAb4K,WACNpM,KAAKwG,MAAMC,MAAO,OAAO,EAE5B,IAAM0E,EAAOC,eAAapL,KAAKC,KAC/B,SAAKkL,GAAQA,EAAKE,gBAAkBrL,KAAKwG,MAAMC,SAE/CzG,KAAKwG,MAAMC,MAAMN,SAEV,IAETkG,YAAW,SAAE7H,GAEXxE,KAAKsM,SAAW9H,EAEZA,EACFxE,KAAKmD,aAAenD,KAAKsE,UAChBtE,KAAKmD,eAAiBnD,KAAKsE,WACpCtE,KAAKyE,MAAM,SAAUzE,KAAKsE,YAG9B4B,SAAQ,WACNlG,KAAKyF,gBACLzF,KAAK0F,iBACL1F,KAAKmM,uB","file":"static/js/chunk-f74817b4.2946457f.js","sourcesContent":["var $ = require('../internals/export');\nvar is = require('../internals/same-value');\n\n// `Object.is` method\n// https://tc39.es/ecma262/#sec-object.is\n$({ target: 'Object', stat: true }, {\n is: is\n});\n","// Styles\nimport './VCounter.sass'\n\n// Mixins\nimport Themeable, { functionalThemeClasses } from '../../mixins/themeable'\n\n// Types\nimport { VNode } from 'vue'\nimport mixins from '../../util/mixins'\n\n/* @vue/component */\nexport default mixins(Themeable).extend({\n name: 'v-counter',\n\n functional: true,\n\n props: {\n value: {\n type: [Number, String],\n default: '',\n },\n max: [Number, String],\n },\n\n render (h, ctx): VNode {\n const { props } = ctx\n const max = parseInt(props.max, 10)\n const value = parseInt(props.value, 10)\n const content = max ? `${value} / ${max}` : String(props.value)\n const isGreater = max && (value > max)\n\n return h('div', {\n staticClass: 'v-counter',\n class: {\n 'error--text': isGreater,\n ...functionalThemeClasses(ctx),\n },\n }, content)\n },\n})\n","import VCounter from './VCounter'\n\nexport { VCounter }\nexport default VCounter\n","// Directives\nimport Intersect from '../../directives/intersect'\n\n// Utilities\nimport { consoleWarn } from '../../util/console'\n\n// Types\nimport Vue from 'vue'\n\nexport default function intersectable (options: { onVisible: string[] }) {\n return Vue.extend({\n name: 'intersectable',\n\n data: () => ({\n isIntersecting: false,\n }),\n\n mounted () {\n Intersect.inserted(this.$el as HTMLElement, {\n name: 'intersect',\n value: this.onObserve,\n }, this.$vnode)\n },\n\n destroyed () {\n Intersect.unbind(this.$el as HTMLElement, {\n name: 'intersect',\n value: this.onObserve,\n }, this.$vnode)\n },\n\n methods: {\n onObserve (entries: IntersectionObserverEntry[], observer: IntersectionObserver, isIntersecting: boolean) {\n this.isIntersecting = isIntersecting\n\n if (!isIntersecting) return\n\n for (let i = 0, length = options.onVisible.length; i < length; i++) {\n const callback = (this as any)[options.onVisible[i]]\n\n if (typeof callback === 'function') {\n callback()\n continue\n }\n\n consoleWarn(options.onVisible[i] + ' method is not available on the instance but referenced in intersectable mixin options')\n }\n },\n },\n })\n}\n","// Styles\nimport './VTextField.sass'\n\n// Extensions\nimport VInput from '../VInput'\n\n// Components\nimport VCounter from '../VCounter'\nimport VLabel from '../VLabel'\n\n// Mixins\nimport Intersectable from '../../mixins/intersectable'\nimport Loadable from '../../mixins/loadable'\nimport Validatable from '../../mixins/validatable'\n\n// Directives\nimport resize from '../../directives/resize'\nimport ripple from '../../directives/ripple'\n\n// Utilities\nimport { attachedRoot } from '../../util/dom'\nimport { convertToUnit, keyCodes } from '../../util/helpers'\nimport { breaking, consoleWarn } from '../../util/console'\n\n// Types\nimport mixins from '../../util/mixins'\nimport { VNode, PropType } from 'vue/types'\n\nconst baseMixins = mixins(\n VInput,\n Intersectable({\n onVisible: [\n 'onResize',\n 'tryAutofocus',\n ],\n }),\n Loadable,\n)\ninterface options extends InstanceType {\n $refs: {\n label: HTMLElement\n input: HTMLInputElement\n 'prepend-inner': HTMLElement\n prefix: HTMLElement\n suffix: HTMLElement\n }\n}\n\nconst dirtyTypes = ['color', 'file', 'time', 'date', 'datetime-local', 'week', 'month']\n\n/* @vue/component */\nexport default baseMixins.extend().extend({\n name: 'v-text-field',\n\n directives: {\n resize,\n ripple,\n },\n\n inheritAttrs: false,\n\n props: {\n appendOuterIcon: String,\n autofocus: Boolean,\n clearable: Boolean,\n clearIcon: {\n type: String,\n default: '$clear',\n },\n counter: [Boolean, Number, String],\n counterValue: Function as PropType<(value: any) => number>,\n filled: Boolean,\n flat: Boolean,\n fullWidth: Boolean,\n label: String,\n outlined: Boolean,\n placeholder: String,\n prefix: String,\n prependInnerIcon: String,\n persistentPlaceholder: Boolean,\n reverse: Boolean,\n rounded: Boolean,\n shaped: Boolean,\n singleLine: Boolean,\n solo: Boolean,\n soloInverted: Boolean,\n suffix: String,\n type: {\n type: String,\n default: 'text',\n },\n },\n\n data: () => ({\n badInput: false,\n labelWidth: 0,\n prefixWidth: 0,\n prependWidth: 0,\n initialValue: null,\n isBooted: false,\n isClearing: false,\n }),\n\n computed: {\n classes (): object {\n return {\n ...VInput.options.computed.classes.call(this),\n 'v-text-field': true,\n 'v-text-field--full-width': this.fullWidth,\n 'v-text-field--prefix': this.prefix,\n 'v-text-field--single-line': this.isSingle,\n 'v-text-field--solo': this.isSolo,\n 'v-text-field--solo-inverted': this.soloInverted,\n 'v-text-field--solo-flat': this.flat,\n 'v-text-field--filled': this.filled,\n 'v-text-field--is-booted': this.isBooted,\n 'v-text-field--enclosed': this.isEnclosed,\n 'v-text-field--reverse': this.reverse,\n 'v-text-field--outlined': this.outlined,\n 'v-text-field--placeholder': this.placeholder,\n 'v-text-field--rounded': this.rounded,\n 'v-text-field--shaped': this.shaped,\n }\n },\n computedColor (): string | undefined {\n const computedColor = Validatable.options.computed.computedColor.call(this)\n\n if (!this.soloInverted || !this.isFocused) return computedColor\n\n return this.color || 'primary'\n },\n computedCounterValue (): number {\n if (typeof this.counterValue === 'function') {\n return this.counterValue(this.internalValue)\n }\n return [...(this.internalValue || '').toString()].length\n },\n hasCounter (): boolean {\n return this.counter !== false && this.counter != null\n },\n hasDetails (): boolean {\n return VInput.options.computed.hasDetails.call(this) || this.hasCounter\n },\n internalValue: {\n get (): any {\n return this.lazyValue\n },\n set (val: any) {\n this.lazyValue = val\n this.$emit('input', this.lazyValue)\n },\n },\n isDirty (): boolean {\n return this.lazyValue?.toString().length > 0 || this.badInput\n },\n isEnclosed (): boolean {\n return (\n this.filled ||\n this.isSolo ||\n this.outlined\n )\n },\n isLabelActive (): boolean {\n return this.isDirty || dirtyTypes.includes(this.type)\n },\n isSingle (): boolean {\n return (\n this.isSolo ||\n this.singleLine ||\n this.fullWidth ||\n // https://material.io/components/text-fields/#filled-text-field\n (this.filled && !this.hasLabel)\n )\n },\n isSolo (): boolean {\n return this.solo || this.soloInverted\n },\n labelPosition (): Record<'left' | 'right', string | number | undefined> {\n let offset = (this.prefix && !this.labelValue) ? this.prefixWidth : 0\n\n if (this.labelValue && this.prependWidth) offset -= this.prependWidth\n\n return (this.$vuetify.rtl === this.reverse) ? {\n left: offset,\n right: 'auto',\n } : {\n left: 'auto',\n right: offset,\n }\n },\n showLabel (): boolean {\n return this.hasLabel && !(this.isSingle && this.labelValue)\n },\n labelValue (): boolean {\n return this.isFocused || this.isLabelActive || this.persistentPlaceholder\n },\n },\n\n watch: {\n // labelValue: 'setLabelWidth', // moved to mounted, see #11533\n outlined: 'setLabelWidth',\n label () {\n this.$nextTick(this.setLabelWidth)\n },\n prefix () {\n this.$nextTick(this.setPrefixWidth)\n },\n isFocused: 'updateValue',\n value (val) {\n this.lazyValue = val\n },\n },\n\n created () {\n /* istanbul ignore next */\n if (this.$attrs.hasOwnProperty('box')) {\n breaking('box', 'filled', this)\n }\n\n /* istanbul ignore next */\n if (this.$attrs.hasOwnProperty('browser-autocomplete')) {\n breaking('browser-autocomplete', 'autocomplete', this)\n }\n\n /* istanbul ignore if */\n if (this.shaped && !(this.filled || this.outlined || this.isSolo)) {\n consoleWarn('shaped should be used with either filled or outlined', this)\n }\n },\n\n mounted () {\n // #11533\n this.$watch(() => this.labelValue, this.setLabelWidth)\n this.autofocus && this.tryAutofocus()\n requestAnimationFrame(() => {\n this.isBooted = true\n requestAnimationFrame(() => {\n if (!this.isIntersecting) {\n this.onResize()\n }\n })\n })\n },\n\n methods: {\n /** @public */\n focus () {\n this.onFocus()\n },\n /** @public */\n blur (e?: Event) {\n // https://github.com/vuetifyjs/vuetify/issues/5913\n // Safari tab order gets broken if called synchronous\n window.requestAnimationFrame(() => {\n this.$refs.input && this.$refs.input.blur()\n })\n },\n clearableCallback () {\n this.$refs.input && this.$refs.input.focus()\n this.$nextTick(() => this.internalValue = null)\n },\n genAppendSlot () {\n const slot = []\n\n if (this.$slots['append-outer']) {\n slot.push(this.$slots['append-outer'] as VNode[])\n } else if (this.appendOuterIcon) {\n slot.push(this.genIcon('appendOuter'))\n }\n\n return this.genSlot('append', 'outer', slot)\n },\n genPrependInnerSlot () {\n const slot = []\n\n if (this.$slots['prepend-inner']) {\n slot.push(this.$slots['prepend-inner'] as VNode[])\n } else if (this.prependInnerIcon) {\n slot.push(this.genIcon('prependInner'))\n }\n\n return this.genSlot('prepend', 'inner', slot)\n },\n genIconSlot () {\n const slot = []\n\n if (this.$slots.append) {\n slot.push(this.$slots.append as VNode[])\n } else if (this.appendIcon) {\n slot.push(this.genIcon('append'))\n }\n\n return this.genSlot('append', 'inner', slot)\n },\n genInputSlot () {\n const input = VInput.options.methods.genInputSlot.call(this)\n\n const prepend = this.genPrependInnerSlot()\n\n if (prepend) {\n input.children = input.children || []\n input.children.unshift(prepend)\n }\n\n return input\n },\n genClearIcon () {\n if (!this.clearable) return null\n\n // if the text field has no content then don't display the clear icon.\n // We add an empty div because other controls depend on a ref to append inner\n if (!this.isDirty) {\n return this.genSlot('append', 'inner', [\n this.$createElement('div'),\n ])\n }\n\n return this.genSlot('append', 'inner', [\n this.genIcon('clear', this.clearableCallback),\n ])\n },\n genCounter () {\n if (!this.hasCounter) return null\n\n const max = this.counter === true ? this.attrs$.maxlength : this.counter\n\n const props = {\n dark: this.dark,\n light: this.light,\n max,\n value: this.computedCounterValue,\n }\n\n return this.$scopedSlots.counter?.({ props }) ?? this.$createElement(VCounter, { props })\n },\n genControl () {\n return VInput.options.methods.genControl.call(this)\n },\n genDefaultSlot () {\n return [\n this.genFieldset(),\n this.genTextFieldSlot(),\n this.genClearIcon(),\n this.genIconSlot(),\n this.genProgress(),\n ]\n },\n genFieldset () {\n if (!this.outlined) return null\n\n return this.$createElement('fieldset', {\n attrs: {\n 'aria-hidden': true,\n },\n }, [this.genLegend()])\n },\n genLabel () {\n if (!this.showLabel) return null\n\n const data = {\n props: {\n absolute: true,\n color: this.validationState,\n dark: this.dark,\n disabled: this.isDisabled,\n focused: !this.isSingle && (this.isFocused || !!this.validationState),\n for: this.computedId,\n left: this.labelPosition.left,\n light: this.light,\n right: this.labelPosition.right,\n value: this.labelValue,\n },\n }\n\n return this.$createElement(VLabel, data, this.$slots.label || this.label)\n },\n genLegend () {\n const width = !this.singleLine && (this.labelValue || this.isDirty) ? this.labelWidth : 0\n const span = this.$createElement('span', {\n domProps: { innerHTML: '​' },\n staticClass: 'notranslate',\n })\n\n return this.$createElement('legend', {\n style: {\n width: !this.isSingle ? convertToUnit(width) : undefined,\n },\n }, [span])\n },\n genInput () {\n const listeners = Object.assign({}, this.listeners$)\n delete listeners.change // Change should not be bound externally\n const { title, ...inputAttrs } = this.attrs$\n\n return this.$createElement('input', {\n style: {},\n domProps: {\n value: (this.type === 'number' && Object.is(this.lazyValue, -0)) ? '-0' : this.lazyValue,\n },\n attrs: {\n ...inputAttrs,\n autofocus: this.autofocus,\n disabled: this.isDisabled,\n id: this.computedId,\n placeholder: this.persistentPlaceholder || this.isFocused || !this.hasLabel ? this.placeholder : undefined,\n readonly: this.isReadonly,\n type: this.type,\n },\n on: Object.assign(listeners, {\n blur: this.onBlur,\n input: this.onInput,\n focus: this.onFocus,\n keydown: this.onKeyDown,\n }),\n ref: 'input',\n directives: [{\n name: 'resize',\n modifiers: { quiet: true },\n value: this.onResize,\n }],\n })\n },\n genMessages () {\n if (!this.showDetails) return null\n\n const messagesNode = VInput.options.methods.genMessages.call(this)\n const counterNode = this.genCounter()\n\n return this.$createElement('div', {\n staticClass: 'v-text-field__details',\n }, [\n messagesNode,\n counterNode,\n ])\n },\n genTextFieldSlot () {\n return this.$createElement('div', {\n staticClass: 'v-text-field__slot',\n }, [\n this.genLabel(),\n this.prefix ? this.genAffix('prefix') : null,\n this.genInput(),\n this.suffix ? this.genAffix('suffix') : null,\n ])\n },\n genAffix (type: 'prefix' | 'suffix') {\n return this.$createElement('div', {\n class: `v-text-field__${type}`,\n ref: type,\n }, this[type])\n },\n onBlur (e?: Event) {\n this.isFocused = false\n e && this.$nextTick(() => this.$emit('blur', e))\n },\n onClick () {\n if (this.isFocused || this.isDisabled || !this.$refs.input) return\n\n this.$refs.input.focus()\n },\n onFocus (e?: Event) {\n if (!this.$refs.input) return\n\n const root = attachedRoot(this.$el)\n if (!root) return\n\n if (root.activeElement !== this.$refs.input) {\n return this.$refs.input.focus()\n }\n\n if (!this.isFocused) {\n this.isFocused = true\n e && this.$emit('focus', e)\n }\n },\n onInput (e: Event) {\n const target = e.target as HTMLInputElement\n this.internalValue = target.value\n this.badInput = target.validity && target.validity.badInput\n },\n onKeyDown (e: KeyboardEvent) {\n if (\n e.keyCode === keyCodes.enter &&\n this.lazyValue !== this.initialValue\n ) {\n this.initialValue = this.lazyValue\n this.$emit('change', this.initialValue)\n }\n\n this.$emit('keydown', e)\n },\n onMouseDown (e: Event) {\n // Prevent input from being blurred\n if (e.target !== this.$refs.input) {\n e.preventDefault()\n e.stopPropagation()\n }\n\n VInput.options.methods.onMouseDown.call(this, e)\n },\n onMouseUp (e: Event) {\n if (this.hasMouseDown) this.focus()\n\n VInput.options.methods.onMouseUp.call(this, e)\n },\n setLabelWidth () {\n if (!this.outlined) return\n\n this.labelWidth = this.$refs.label\n ? Math.min(this.$refs.label.scrollWidth * 0.75 + 6, (this.$el as HTMLElement).offsetWidth - 24)\n : 0\n },\n setPrefixWidth () {\n if (!this.$refs.prefix) return\n\n this.prefixWidth = this.$refs.prefix.offsetWidth\n },\n setPrependWidth () {\n if (!this.outlined || !this.$refs['prepend-inner']) return\n\n this.prependWidth = this.$refs['prepend-inner'].offsetWidth\n },\n tryAutofocus () {\n if (\n !this.autofocus ||\n typeof document === 'undefined' ||\n !this.$refs.input) return false\n\n const root = attachedRoot(this.$el)\n if (!root || root.activeElement === this.$refs.input) return false\n\n this.$refs.input.focus()\n\n return true\n },\n updateValue (val: boolean) {\n // Sets validationState from validatable\n this.hasColor = val\n\n if (val) {\n this.initialValue = this.lazyValue\n } else if (this.initialValue !== this.lazyValue) {\n this.$emit('change', this.lazyValue)\n }\n },\n onResize () {\n this.setLabelWidth()\n this.setPrefixWidth()\n this.setPrependWidth()\n },\n },\n})\n"],"sourceRoot":""}