vue-material/dist/components/mdInputContainer/index.js
2017-06-20 10:46:21 +02:00

6 lines
No EOL
26 KiB
JavaScript

/*!
* Vue Material v0.7.2
* Made with love by Marcos Moura
* Released under the MIT License.
*/
!(function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.VueMaterial=e():t.VueMaterial=e()})(this,(function(){return (function(t){function e(r){if(n[r])return n[r].exports;var i=n[r]={i:r,l:!1,exports:{}};return t[r].call(i.exports,i,i.exports,e),i.l=!0,i.exports}var n={};return e.m=t,e.c=n,e.i=function(t){return t},e.d=function(t,n,r){e.o(t,n)||Object.defineProperty(t,n,{configurable:!1,enumerable:!0,get:r})},e.n=function(t){var n=t&&t.__esModule?function(){return t.default}:function(){return t};return e.d(n,"a",n),n},e.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},e.p="/",e(e.s=459)})({0:function(t,e){t.exports=function(t,e,n,r,i){var o,u=t=t||{},a=typeof t.default;"object"!==a&&"function"!==a||(o=t,u=t.default);var s="function"==typeof u?u.options:u;e&&(s.render=e.render,s.staticRenderFns=e.staticRenderFns),r&&(s._scopeId=r);var l;if(i?(l=function(t){t=t||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext,t||"undefined"==typeof __VUE_SSR_CONTEXT__||(t=__VUE_SSR_CONTEXT__),n&&n.call(this,t),t&&t._registeredComponents&&t._registeredComponents.add(i)},s._ssrRegister=l):n&&(l=n),l){var c=s.functional,d=c?s.render:s.beforeCreate;c?s.render=function(t,e){return l.call(e),d(t,e)}:s.beforeCreate=d?[].concat(d,l):[l]}return{esModule:o,exports:u,options:s}}},1:function(t,e,n){"use strict";function r(t){if(!t)return null;var e=t.mdTheme;return e||"md-theme"!==t.$options._componentTag||(e=t.mdName),e||r(t.$parent)}Object.defineProperty(e,"__esModule",{value:!0}),e.default={props:{mdTheme:String},computed:{mdEffectiveTheme:function(){return r(this)||this.$material.currentTheme},themeClass:function(){return this.$material.prefix+this.mdEffectiveTheme}},watch:{mdTheme:function(t){this.$material.useTheme(t)}},beforeMount:function(){var t=this.mdTheme;this.$material.useTheme(t||"default")}},t.exports=e.default},10:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=function t(e,n){return!(!e||!e.$el)&&(0!==e._uid&&(e.$el.classList.contains(n)?e:t(e.$parent,n)))};e.default=r,t.exports=e.default},11:function(t,e,n){var r=n(9),i=n(17);t.exports=n(3)?function(t,e,n){return r.f(t,e,i(1,n))}:function(t,e,n){return t[e]=n,t}},115:function(t,e,n){var r,i,o;!(function(n,u){i=[e,t],r=u,void 0!==(o="function"==typeof r?r.apply(e,i):r)&&(t.exports=o)})(0,(function(t,e){"use strict";function n(t){function e(e){var n=t.style.width;t.style.width="0px",t.offsetWidth,t.style.width=n,t.style.overflowY=e}function n(t){for(var e=[];t&&t.parentNode&&t.parentNode instanceof Element;)t.parentNode.scrollTop&&e.push({node:t.parentNode,scrollTop:t.parentNode.scrollTop}),t=t.parentNode;return e}function r(){var e=t.style.height,r=n(t),i=document.documentElement&&document.documentElement.scrollTop;t.style.height="auto";var o=t.scrollHeight+a;if(0===t.scrollHeight)return void(t.style.height=e);t.style.height=o+"px",s=t.clientWidth,r.forEach((function(t){t.node.scrollTop=t.scrollTop})),i&&(document.documentElement.scrollTop=i)}function i(){r();var n=Math.round(parseFloat(t.style.height)),i=window.getComputedStyle(t,null),o="content-box"===i.boxSizing?Math.round(parseFloat(i.height)):t.offsetHeight;if(o!==n?"hidden"===i.overflowY&&(e("scroll"),r(),o="content-box"===i.boxSizing?Math.round(parseFloat(window.getComputedStyle(t,null).height)):t.offsetHeight):"hidden"!==i.overflowY&&(e("hidden"),r(),o="content-box"===i.boxSizing?Math.round(parseFloat(window.getComputedStyle(t,null).height)):t.offsetHeight),l!==o){l=o;var a=u("autosize:resized");try{t.dispatchEvent(a)}catch(t){}}}if(t&&t.nodeName&&"TEXTAREA"===t.nodeName&&!o.has(t)){var a=null,s=t.clientWidth,l=null,c=function(){t.clientWidth!==s&&i()},d=function(e){window.removeEventListener("resize",c,!1),t.removeEventListener("input",i,!1),t.removeEventListener("keyup",i,!1),t.removeEventListener("autosize:destroy",d,!1),t.removeEventListener("autosize:update",i,!1),Object.keys(e).forEach((function(n){t.style[n]=e[n]})),o.delete(t)}.bind(t,{height:t.style.height,resize:t.style.resize,overflowY:t.style.overflowY,overflowX:t.style.overflowX,wordWrap:t.style.wordWrap});t.addEventListener("autosize:destroy",d,!1),"onpropertychange"in t&&"oninput"in t&&t.addEventListener("keyup",i,!1),window.addEventListener("resize",c,!1),t.addEventListener("input",i,!1),t.addEventListener("autosize:update",i,!1),t.style.overflowX="hidden",t.style.wordWrap="break-word",o.set(t,{destroy:d,update:i}),(function(){var e=window.getComputedStyle(t,null);"vertical"===e.resize?t.style.resize="none":"both"===e.resize&&(t.style.resize="horizontal"),a="content-box"===e.boxSizing?-(parseFloat(e.paddingTop)+parseFloat(e.paddingBottom)):parseFloat(e.borderTopWidth)+parseFloat(e.borderBottomWidth),isNaN(a)&&(a=0),i()})()}}function r(t){var e=o.get(t);e&&e.destroy()}function i(t){var e=o.get(t);e&&e.update()}var o="function"==typeof Map?new Map:(function(){var t=[],e=[];return{has:function(e){return t.indexOf(e)>-1},get:function(n){return e[t.indexOf(n)]},set:function(n,r){-1===t.indexOf(n)&&(t.push(n),e.push(r))},delete:function(n){var r=t.indexOf(n);r>-1&&(t.splice(r,1),e.splice(r,1))}}})(),u=function(t){return new Event(t,{bubbles:!0})};try{new Event("test")}catch(t){u=function(t){var e=document.createEvent("Event");return e.initEvent(t,!0,!1),e}}var a=null;"undefined"==typeof window||"function"!=typeof window.getComputedStyle?(a=function(t){return t},a.destroy=function(t){return t},a.update=function(t){return t}):(a=function(t,e){return t&&Array.prototype.forEach.call(t.length?t:[t],(function(t){return n(t)})),t},a.destroy=function(t){return t&&Array.prototype.forEach.call(t.length?t:[t],r),t},a.update=function(t){return t&&Array.prototype.forEach.call(t.length?t:[t],i),t}),e.exports=a}))},124:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={props:{debounce:{type:Number,default:1e3},disabled:Boolean,fetch:{type:Function},filterList:Function,list:{type:Array,default:function(){return[]}},minChars:{type:Number,default:1},name:String,prepareResponseData:Function,printAttribute:{type:String,default:"name"},queryParam:{type:String,default:"q"},required:Boolean},methods:{onFocus:function(){this.parentContainer&&(this.parentContainer.isFocused=!0)},onBlur:function(){this.parentContainer.isFocused=!1,this.setParentValue()},verifyProps:function(){return this.parentContainer?this.listIsEmpty&&this.filterList?this.throwErrorDestroy("You should use a `filterList` function prop with the `list` prop"):!this.fetch&&this.listIsEmpty?this.throwErrorDestroy("You should use a `fetch` function prop"):void 0:this.throwErrorDestroy("You should wrap the md-input in a md-input-container")},throwErrorDestroy:function(t){throw this.$destroy(),new Error(t)}}},t.exports=e.default},13:function(t,e,n){var r=n(6);t.exports=function(t){if(!r(t))throw TypeError(t+" is not an object!");return t}},14:function(t,e){t.exports=function(t){if(void 0==t)throw TypeError("Can't call method on "+t);return t}},15:function(t,e){var n=Math.ceil,r=Math.floor;t.exports=function(t){return isNaN(t=+t)?0:(t>0?r:n)(t)}},156:function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var i=n(207),o=r(i),u=n(51),a=r(u),s=n(124),l=r(s),c=n(58),d=r(c),f=n(10),p=r(f);e.default={mixins:[d.default,l.default],data:function(){return{items:[],loading:!1,query:"",selected:null,timeout:0,parentContainer:null,searchButton:null}},computed:{listIsEmpty:function(){return 0===this.list.length}},watch:{list:function(t){this.items=(0,a.default)([],t)},query:function(t){this.$refs.input.value=t,this.setParentUpdateValue(t)},value:function(t){this.query=t,this.setParentUpdateValue(t)}},methods:{debounceUpdate:function(){var t=this;this.onInput(),this.timeout&&window.clearTimeout(this.timeout),this.timeout=window.setTimeout((function(){if(!t.listIsEmpty)return void t.renderFilteredList();t.update()}),this.debounce)},hit:function(t){this.query=t[this.printAttribute],this.$refs.input.value=t[this.printAttribute],this.selected=t,this.onInput(),this.$emit("selected",this.selected,this.$refs.input.value)},makeFetchRequest:function(t){var e=this;return this.fetch(t).then((function(t){var n=t||t.data||t.body;n=e.prepareResponseData?e.prepareResponseData(n):n,e.items=e.limit?n.slice(0,e.limit):n,e.loading=!1,e.toggleMenu()}))},onFocus:function(){this.parentContainer&&(this.parentContainer.isFocused=!0),this.$refs.input.focus()},onInput:function(){this.updateValues(),this.$emit("change",this.$refs.input.value),this.$emit("input",this.$refs.input.value)},renderFilteredList:function(){this.filterList&&(this.items=this.filterList((0,a.default)([],this.list),this.query)),this.toggleMenu()},reset:function(){this.items=[],this.query="",this.loading=!1},setParentValue:function(t){this.parentContainer.setValue(t||this.$refs.input.value)},setParentDisabled:function(){this.parentContainer.isDisabled=this.disabled},setParentRequired:function(){this.parentContainer.isRequired=this.required},setParentPlaceholder:function(){this.parentContainer.hasPlaceholder=!!this.placeholder},setParentUpdateValue:function(t){this.setParentValue(t),this.updateValues(t)},setSearchButton:function(){this.searchButton=this.parentContainer.$el.querySelector("[md-autocomplete-search]"),this.searchButton&&this.searchButton.addEventListener("click",this.makeFetchRequest)},update:function(){if(!this.query&&!this.list.length)return this.reset();if(!(this.minChars&&this.query.length<this.minChars)){this.loading=!0;var t=(0,o.default)({},this.queryParam,this.query);return this.makeFetchRequest(t)}},toggleMenu:function(){this.items.length&&this.$refs.menu.toggle()},updateValues:function(t){var e=t||this.$refs.input.value||this.value;this.setParentValue(e),this.parentContainer.inputLength=e?e.length:0}},beforeDestroy:function(){this.searchButton&&this.searchButton.removeEventListener("click",this.makeFetchRequest)},mounted:function(){var t=this;this.$nextTick((function(){t.parentContainer=(0,p.default)(t.$parent,"md-input-container"),t.listIsEmpty||(t.items=(0,a.default)([],t.list)),t.query=t.value,t.verifyProps(),t.setSearchButton(),t.setParentDisabled(),t.setParentRequired(),t.setParentPlaceholder(),t.handleMaxLength(),t.updateValues()}))}},t.exports=e.default},157:function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var i=n(58),o=r(i),u=n(10),a=r(u);e.default={name:"md-input",props:{type:{type:String,default:"text"}},mixins:[o.default],mounted:function(){var t=this;this.$nextTick((function(){if(t.parentContainer=(0,a.default)(t.$parent,"md-input-container"),!t.parentContainer)throw t.$destroy(),new Error("You should wrap the md-input in a md-input-container");t.parentContainer.inputInstance=t,t.setParentDisabled(),t.setParentRequired(),t.setParentPlaceholder(),t.handleMaxLength(),t.updateValues()}))}},t.exports=e.default},158:function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var i=n(1),o=r(i),u=n(66),a=r(u);e.default={name:"md-input-container",props:{mdInline:Boolean,mdHasPassword:Boolean,mdClearable:Boolean},mixins:[o.default],data:function(){return{value:"",input:!1,inputInstance:null,showPassword:!1,enableCounter:!1,hasSelect:!1,hasPlaceholder:!1,hasFile:!1,isDisabled:!1,isRequired:!1,isFocused:!1,counterLength:0,inputLength:0}},computed:{hasValue:function(){return(0,a.default)(this.value)?this.value.length>0:Boolean(this.value)},classes:function(){return{"md-input-inline":this.mdInline,"md-has-password":this.mdHasPassword,"md-clearable":this.mdClearable,"md-has-select":this.hasSelect,"md-has-file":this.hasFile,"md-has-value":this.hasValue,"md-input-placeholder":this.hasPlaceholder,"md-input-disabled":this.isDisabled,"md-input-required":this.isRequired,"md-input-focused":this.isFocused}}},methods:{isInput:function(){return this.input&&"input"===this.input.tagName.toLowerCase()},togglePasswordType:function(){this.isInput()&&("password"===this.input.type?(this.input.type="text",this.showPassword=!0):(this.input.type="password",this.showPassword=!1),this.input.focus())},clearInput:function(){this.inputInstance.$el.value="",this.inputInstance.$emit("input",""),this.setValue("")},setValue:function(t){this.value=t}},mounted:function(){if(this.input=this.$el.querySelectorAll("input, textarea, select, .md-file")[0],!this.input)throw this.$destroy(),new Error("Missing input/select/textarea inside md-input-container")}},t.exports=e.default},159:function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var i=n(115),o=r(i),u=n(58),a=r(u),s=n(10),l=r(s);e.default={name:"md-textarea",mixins:[a.default],watch:{value:function(){var t=this;this.$nextTick((function(){return o.default.update(t.$el)}))}},mounted:function(){var t=this;this.$nextTick((function(){if(t.parentContainer=(0,l.default)(t.$parent,"md-input-container"),!t.parentContainer)throw t.$destroy(),new Error("You should wrap the md-textarea in a md-input-container");t.parentContainer.inputInstance=t,t.setParentDisabled(),t.setParentRequired(),t.setParentPlaceholder(),t.handleMaxLength(),t.updateValues(),t.$el.getAttribute("rows")||t.$el.setAttribute("rows","1"),(0,o.default)(t.$el),setTimeout((function(){return o.default.update(t.$el)}),200)}))},beforeDestroy:function(){o.default.destroy(this.$el)}},t.exports=e.default},16:function(t,e,n){var r=n(2),i=n(4),o=n(28),u=n(11),a=function(t,e,n){var s,l,c,d=t&a.F,f=t&a.G,p=t&a.S,h=t&a.P,m=t&a.B,v=t&a.W,y=f?i:i[e]||(i[e]={}),b=y.prototype,g=f?r:p?r[e]:(r[e]||{}).prototype;f&&(n=e);for(s in n)(l=!d&&g&&void 0!==g[s])&&s in y||(c=l?g[s]:n[s],y[s]=f&&"function"!=typeof g[s]?n[s]:m&&l?o(c,r):v&&g[s]==c?(function(t){var e=function(e,n,r){if(this instanceof t){switch(arguments.length){case 0:return new t;case 1:return new t(e);case 2:return new t(e,n)}return new t(e,n,r)}return t.apply(this,arguments)};return e.prototype=t.prototype,e})(c):h&&"function"==typeof c?o(Function.call,c):c,h&&((y.virtual||(y.virtual={}))[s]=c,t&a.R&&b&&!b[s]&&u(b,s,c)))};a.F=1,a.G=2,a.S=4,a.P=8,a.B=16,a.W=32,a.U=64,a.R=128,t.exports=a},17:function(t,e){t.exports=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}}},18:function(t,e,n){var r=n(31),i=n(21);t.exports=Object.keys||function(t){return r(t,i)}},19:function(t,e,n){var r=n(22)("keys"),i=n(20);t.exports=function(t){return r[t]||(r[t]=i(t))}},2:function(t,e){var n=t.exports="undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=n)},20:function(t,e){var n=0,r=Math.random();t.exports=function(t){return"Symbol(".concat(void 0===t?"":t,")_",(++n+r).toString(36))}},204:function(t,e,n){t.exports={default:n(212),__esModule:!0}},207:function(t,e,n){"use strict";e.__esModule=!0;var r=n(204),i=(function(t){return t&&t.__esModule?t:{default:t}})(r);e.default=function(t,e,n){return e in t?(0,i.default)(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}},21:function(t,e){t.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},212:function(t,e,n){n(223);var r=n(4).Object;t.exports=function(t,e,n){return r.defineProperty(t,e,n)}},22:function(t,e,n){var r=n(2),i=r["__core-js_shared__"]||(r["__core-js_shared__"]={});t.exports=function(t){return i[t]||(i[t]={})}},223:function(t,e,n){var r=n(16);r(r.S+r.F*!n(3),"Object",{defineProperty:n(9).f})},23:function(t,e,n){var r=n(14);t.exports=function(t){return Object(r(t))}},237:function(t,e){},24:function(t,e){var n={}.toString;t.exports=function(t){return n.call(t).slice(8,-1)}},25:function(t,e,n){var r=n(6),i=n(2).document,o=r(i)&&r(i.createElement);t.exports=function(t){return o?i.createElement(t):{}}},26:function(t,e,n){var r=n(24);t.exports=Object("z").propertyIsEnumerable(0)?Object:function(t){return"String"==r(t)?t.split(""):Object(t)}},27:function(t,e,n){var r=n(6);t.exports=function(t,e){if(!r(t))return t;var n,i;if(e&&"function"==typeof(n=t.toString)&&!r(i=n.call(t)))return i;if("function"==typeof(n=t.valueOf)&&!r(i=n.call(t)))return i;if(!e&&"function"==typeof(n=t.toString)&&!r(i=n.call(t)))return i;throw TypeError("Can't convert object to primitive value")}},276:function(t,e){t.exports=".THEME_NAME.md-input-container.md-input-invalid:after{background-color:WARN-COLOR}.THEME_NAME.md-input-container.md-input-invalid label,.THEME_NAME.md-input-container.md-input-invalid input,.THEME_NAME.md-input-container.md-input-invalid textarea,.THEME_NAME.md-input-container.md-input-invalid .md-error,.THEME_NAME.md-input-container.md-input-invalid .md-count,.THEME_NAME.md-input-container.md-input-invalid .md-icon:not(.md-icon-delete){color:WARN-COLOR}.THEME_NAME.md-input-container.md-input-focused.md-input-inline label{color:rgba(0,0,0,0.54)}.THEME_NAME.md-input-container.md-input-focused.md-input-required label:after{color:WARN-COLOR}.THEME_NAME.md-input-container.md-input-focused:after{height:2px;background-color:PRIMARY-COLOR}.THEME_NAME.md-input-container.md-input-focused input,.THEME_NAME.md-input-container.md-input-focused textarea{color:PRIMARY-COLOR;text-shadow:0 0 0 BACKGROUND-CONTRAST;-webkit-text-fill-color:transparent}.THEME_NAME.md-input-container.md-input-focused label,.THEME_NAME.md-input-container.md-input-focused .md-icon:not(.md-icon-delete){color:PRIMARY-COLOR}.THEME_NAME.md-input-container.md-input-disabled label,.THEME_NAME.md-input-container.md-input-disabled input,.THEME_NAME.md-input-container.md-input-disabled textarea,.THEME_NAME.md-input-container.md-input-disabled .md-error,.THEME_NAME.md-input-container.md-input-disabled .md-count,.THEME_NAME.md-input-container.md-input-disabled .md-icon:not(.md-icon-delete),.THEME_NAME.md-input-container.md-input-disabled ::-webkit-input-placeholder{color:BACKGROUND-CONTRAST-0.38}.THEME_NAME.md-input-container .md-icon:not(.md-icon-delete):after{background:BACKGROUND-COLOR}\n"},28:function(t,e,n){var r=n(33);t.exports=function(t,e,n){if(r(t),void 0===e)return t;switch(n){case 1:return function(n){return t.call(e,n)};case 2:return function(n,r){return t.call(e,n,r)};case 3:return function(n,r,i){return t.call(e,n,r,i)}}return function(){return t.apply(e,arguments)}}},29:function(t,e,n){var r=n(15),i=Math.min;t.exports=function(t){return t>0?i(r(t),9007199254740991):0}},3:function(t,e,n){t.exports=!n(5)((function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a}))},30:function(t,e,n){t.exports=!n(3)&&!n(5)((function(){return 7!=Object.defineProperty(n(25)("div"),"a",{get:function(){return 7}}).a}))},31:function(t,e,n){var r=n(8),i=n(7),o=n(34)(!1),u=n(19)("IE_PROTO");t.exports=function(t,e){var n,a=i(t),s=0,l=[];for(n in a)n!=u&&r(a,n)&&l.push(n);for(;e.length>s;)r(a,n=e[s++])&&(~o(l,n)||l.push(n));return l}},325:function(t,e,n){var r=n(0)(n(156),n(391),null,null,null);t.exports=r.exports},326:function(t,e,n){var r=n(0)(n(157),n(389),null,null,null);t.exports=r.exports},327:function(t,e,n){function r(t){n(237)}var i=n(0)(n(158),n(392),r,null,null);t.exports=i.exports},328:function(t,e,n){var r=n(0)(n(159),n(424),null,null,null);t.exports=r.exports},33:function(t,e){t.exports=function(t){if("function"!=typeof t)throw TypeError(t+" is not a function!");return t}},34:function(t,e,n){var r=n(7),i=n(29),o=n(35);t.exports=function(t){return function(e,n,u){var a,s=r(e),l=i(s.length),c=o(u,l);if(t&&n!=n){for(;l>c;)if((a=s[c++])!=a)return!0}else for(;l>c;c++)if((t||c in s)&&s[c]===n)return t||c||0;return!t&&-1}}},35:function(t,e,n){var r=n(15),i=Math.max,o=Math.min;t.exports=function(t,e){return t=r(t),t<0?i(t+e,0):o(t,e)}},389:function(t,e){t.exports={render:function(){var t=this,e=t.$createElement;return(t._self._c||e)("input",{staticClass:"md-input",attrs:{name:t.name,type:t.type,disabled:t.disabled,required:t.required,placeholder:t.placeholder,maxlength:t.maxlength,readonly:t.readonly},domProps:{value:t.value},on:{focus:t.onFocus,blur:t.onBlur,input:t.onInput,keydown:[function(e){if(!("button"in e)&&t._k(e.keyCode,"up",38))return null;t.onInput(e)},function(e){if(!("button"in e)&&t._k(e.keyCode,"down",40))return null;t.onInput(e)}]}})},staticRenderFns:[]}},391:function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-autocomplete",on:{focus:t.onFocus,blur:t.onBlur}},[n("md-menu",{ref:"menu",staticClass:"md-autocomplete-menu",attrs:{"md-offset-x":8,"md-offset-y":"45"}},[n("span",{attrs:{"md-menu-trigger":""}}),t._v(" "),n("input",{directives:[{name:"model",rawName:"v-model",value:t.query,expression:"query"}],ref:"input",staticClass:"md-input",attrs:{type:"text",disabled:t.disabled,required:t.required,placeholder:t.placeholder,maxlength:t.maxlength,name:t.name},domProps:{value:t.query},on:{focus:t.onFocus,blur:t.onBlur,input:[function(e){e.target.composing||(t.query=e.target.value)},t.debounceUpdate]}}),t._v(" "),n("md-menu-content",t._l(t.items,(function(e){return t.items.length?n("md-menu-item",{key:e,on:{keyup:function(n){if(!("button"in n)&&t._k(n.keyCode,"enter",13))return null;t.hit(e)}},nativeOn:{click:function(n){t.hit(e)}}},[t._v("\n "+t._s(e[t.printAttribute])+"\n ")]):t._e()})))],1)],1)},staticRenderFns:[]}},392:function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-input-container",class:[t.themeClass,t.classes]},[t._t("default"),t._v(" "),t.enableCounter?n("span",{staticClass:"md-count"},[t._v(t._s(t.inputLength)+" / "+t._s(t.counterLength))]):t._e(),t._v(" "),t.mdHasPassword?n("md-button",{staticClass:"md-icon-button md-toggle-password",nativeOn:{click:function(e){t.togglePasswordType(e)}}},[n("md-icon",[t._v(t._s(t.showPassword?"visibility_off":"visibility"))])],1):t._e(),t._v(" "),t.mdClearable&&t.hasValue?n("md-button",{staticClass:"md-icon-button md-clear-input",nativeOn:{click:function(e){t.clearInput(e)}}},[n("md-icon",[t._v("clear")])],1):t._e()],2)},staticRenderFns:[]}},4:function(t,e){var n=t.exports={version:"2.4.0"};"number"==typeof __e&&(__e=n)},40:function(t,e){e.f={}.propertyIsEnumerable},424:function(t,e){t.exports={render:function(){var t=this,e=t.$createElement;return(t._self._c||e)("textarea",{staticClass:"md-input",attrs:{disabled:t.disabled,required:t.required,placeholder:t.placeholder,maxlength:t.maxlength,readonly:t.readonly},domProps:{value:t.value},on:{focus:t.onFocus,blur:t.onBlur,input:t.onInput}})},staticRenderFns:[]}},45:function(t,e){e.f=Object.getOwnPropertySymbols},459:function(t,e,n){t.exports=n(93)},5:function(t,e){t.exports=function(t){try{return!!t()}catch(t){return!0}}},51:function(t,e,n){t.exports={default:n(59),__esModule:!0}},58:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={props:{value:[String,Number],debounce:{type:Number,default:300},disabled:Boolean,required:Boolean,maxlength:[Number,String],name:String,placeholder:String,readonly:Boolean},data:function(){return{timeout:0}},watch:{value:function(){this.updateValues()},disabled:function(){this.setParentDisabled()},required:function(){this.setParentRequired()},placeholder:function(){this.setParentPlaceholder()},maxlength:function(){this.handleMaxLength()}},methods:{handleMaxLength:function(){this.parentContainer.enableCounter=this.maxlength>0,this.parentContainer.counterLength=this.maxlength},lazyEventEmitter:function(){var t=this;this.timeout&&window.clearTimeout(this.timeout),this.timeout=window.setTimeout((function(){t.$emit("change",t.$el.value),t.$emit("input",t.$el.value)}),this.debounce)},setParentValue:function(t){this.parentContainer.setValue(t||this.$el.value)},setParentDisabled:function(){this.parentContainer.isDisabled=this.disabled},setParentRequired:function(){this.parentContainer.isRequired=this.required},setParentPlaceholder:function(){this.parentContainer.hasPlaceholder=!!this.placeholder},updateValues:function(){var t=this;this.$nextTick((function(){var e=t.$el.value||t.value;t.setParentValue(e),t.parentContainer.inputLength=e?e.length:0}))},onFocus:function(){this.parentContainer&&(this.parentContainer.isFocused=!0)},onBlur:function(){this.parentContainer.isFocused=!1,this.setParentValue()},onInput:function(){this.updateValues(),this.lazyEventEmitter()}}},t.exports=e.default},59:function(t,e,n){n(64),t.exports=n(4).Object.assign},6:function(t,e){t.exports=function(t){return"object"==typeof t?null!==t:"function"==typeof t}},61:function(t,e,n){"use strict";var r=n(18),i=n(45),o=n(40),u=n(23),a=n(26),s=Object.assign;t.exports=!s||n(5)((function(){var t={},e={},n=Symbol(),r="abcdefghijklmnopqrst";return t[n]=7,r.split("").forEach((function(t){e[t]=t})),7!=s({},t)[n]||Object.keys(s({},e)).join("")!=r}))?function(t,e){for(var n=u(t),s=arguments.length,l=1,c=i.f,d=o.f;s>l;)for(var f,p=a(arguments[l++]),h=c?r(p).concat(c(p)):r(p),m=h.length,v=0;m>v;)d.call(p,f=h[v++])&&(n[f]=p[f]);return n}:s},64:function(t,e,n){var r=n(16);r(r.S+r.F,"Object",{assign:n(61)})},66:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=function(t){return t&&t.constructor===Array};e.default=r,t.exports=e.default},7:function(t,e,n){var r=n(26),i=n(14);t.exports=function(t){return r(i(t))}},8:function(t,e){var n={}.hasOwnProperty;t.exports=function(t,e){return n.call(t,e)}},9:function(t,e,n){var r=n(13),i=n(30),o=n(27),u=Object.defineProperty;e.f=n(3)?Object.defineProperty:function(t,e,n){if(r(t),e=o(e,!0),r(n),i)try{return u(t,e,n)}catch(t){}if("get"in n||"set"in n)throw TypeError("Accessors not supported!");return"value"in n&&(t[e]=n.value),t}},93:function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function i(t){t.component("md-input-container",u.default),t.component("md-input",s.default),t.component("md-autocomplete",c.default),t.component("md-textarea",f.default),t.material.styles.push(h.default)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=i;var o=n(327),u=r(o),a=n(326),s=r(a),l=n(325),c=r(l),d=n(328),f=r(d),p=n(276),h=r(p);t.exports=e.default}})}));