/*! * Angular Material Design * https://github.com/angular/material * @license MIT * v0.11.3-master-3fe7d76 */ !function(e,t,n){"use strict";function i(e,t){function n(t,n,i){e(n)}function i(e,n,i){var r=this;r.isErrorGetter=i.mdIsError&&t(i.mdIsError),r.delegateClick=function(){r.input.focus()},r.element=n,r.setFocused=function(e){n.toggleClass("md-input-focused",!!e)},r.setHasValue=function(e){n.toggleClass("md-input-has-value",!!e)},r.setHasMessages=function(e){n.toggleClass("md-input-has-messages",!!e)},r.setHasPlaceholder=function(e){n.toggleClass("md-input-has-placeholder",!!e)},r.setInvalid=function(e){n.toggleClass("md-input-invalid",!!e)},e.$watch(function(){return r.label&&r.input},function(e){e&&!r.label.attr("for")&&r.label.attr("for",r.input.attr("id"))})}return i.$inject=["$scope","$element","$attrs"],{restrict:"E",link:n,controller:i}}function r(){return{restrict:"E",require:"^?mdInputContainer",link:function(e,t,n,i){i&&!n.mdNoFloat&&(i.label=t,e.$on("$destroy",function(){i.label=null}))}}}function a(e,n,i){function r(r,a,s,o){function l(e){return d.setHasValue(!m.$isEmpty(e)),e}function u(){d.setHasValue(a.val().length>0||(a[0].validity||{}).badInput)}function c(){function i(e){return h(),e}function s(){if(c.style.height=c.offsetHeight+"px",a.addClass("md-no-flex"),isNaN(f)){u.style.height="auto",u.scrollTop=0;var e=o();e&&(u.style.height=e+"px")}else{u.setAttribute("rows",1),g||(u.style.minHeight="0",g=a.prop("clientHeight"),u.style.minHeight=null);var t=Math.max(f,Math.round(u.scrollHeight/g));u.setAttribute("rows",t)}a.removeClass("md-no-flex"),c.style.height="auto"}function o(){var e=u.scrollHeight-u.offsetHeight;return u.offsetHeight+(e>0?e:0)}function l(e){u.scrollTop=0;var t=u.scrollHeight-u.offsetHeight,n=u.offsetHeight+t;u.style.height=n+"px"}if(!t.isDefined(a.attr("md-no-autogrow"))){var u=a[0],c=d.element[0],f=NaN,g=null;u.hasAttribute("rows")&&(f=parseInt(u.getAttribute("rows")));var h=e.debounce(s,1);if(m?(m.$formatters.push(i),m.$viewChangeListeners.push(i)):h(),a.on("keydown input",h),isNaN(f)&&(a.attr("rows","1"),a.on("scroll",l)),t.element(n).on("resize",h),r.$on("$destroy",function(){t.element(n).off("resize",h)}),t.isDefined(a.attr("md-detect-hidden"))){var p=function(){var e=!1;return function(){var t=0===u.offsetHeight;t===!1&&e===!0&&s(),e=t}}();r.$watch(function(){return e.nextTick(p,!1),!0})}}}var d=o[0],f=!!o[1],m=o[1]||e.fakeNgModel(),g=t.isDefined(s.readonly);if(d){if(d.input)throw new Error(" can only have *one* ,