/*! * Angular Material Design * https://github.com/angular/material * @license MIT * v1.1.2-master-a9ba340 */ function mdInputContainerDirective(e,n){function t(n){var t=n[0].querySelector(r),i=n[0].querySelector(s);return t&&n.addClass("md-icon-left"),i&&n.addClass("md-icon-right"),function(n,t){e(t)}}function i(e,t,i,a){var r=this;r.isErrorGetter=i.mdIsError&&n(i.mdIsError),r.delegateClick=function(){r.input.focus()},r.element=t,r.setFocused=function(e){t.toggleClass("md-input-focused",!!e)},r.setHasValue=function(e){t.toggleClass("md-input-has-value",!!e)},r.setHasPlaceholder=function(e){t.toggleClass("md-input-has-placeholder",!!e)},r.setInvalid=function(e){e?a.addClass(t,"md-input-invalid"):a.removeClass(t,"md-input-invalid")},e.$watch(function(){return r.label&&r.input},function(e){e&&!r.label.attr("for")&&r.label.attr("for",r.input.attr("id"))})}i.$inject=["$scope","$element","$attrs","$animate"];var a=["INPUT","TEXTAREA","SELECT","MD-SELECT"],r=a.reduce(function(e,n){return e.concat(["md-icon ~ "+n,".md-icon ~ "+n])},[]).join(","),s=a.reduce(function(e,n){return e.concat([n+" ~ md-icon",n+" ~ .md-icon"])},[]).join(",");return{restrict:"E",compile:t,controller:i}}function labelDirective(){return{restrict:"E",require:"^?mdInputContainer",link:function(e,n,t,i){!i||t.mdNoFloat||n.hasClass("md-container-ignore")||(i.label=n,e.$on("$destroy",function(){i.label=null}))}}}function inputTextareaDirective(e,n,t,i,a){function r(r,s,o,u){function l(e){return g.setHasValue(!p.$isEmpty(e)),e}function d(){g.label&&o.$observe("required",function(e){g.label.toggleClass("md-required",e&&!$)})}function c(){g.setHasValue(s.val().length>0||(s[0].validity||{}).badInput)}function m(){function t(){s.attr("rows",1).css("height","auto").addClass("md-no-flex");var e=u();if(!M){var n=s[0].style.padding||"";M=s.css("padding",0).prop("offsetHeight"),s[0].style.padding=n}if(v&&M&&(e=Math.max(e,M*v)),h&&M){var t=M*h;t-1&&p.$formatters.splice(e,1)}}function c(){function e(e){e.preventDefault(),l=!0,c=e.clientY,m=parseFloat(s.css("height"))||s.prop("offsetHeight")}function n(e){l&&(e.preventDefault(),d(),f.addClass("md-input-resized"))}function t(e){l&&s.css("height",m+e.pointer.distanceY+"px")}function i(e){l&&(l=!1,f.removeClass("md-input-resized"))}if(!o.hasOwnProperty("mdNoResize")){var u=angular.element('
'),l=!1,c=null,m=0,f=g.element,p=a.register(u,"drag",{horizontal:!1});s.wrap('
').after(u),u.on("mousedown",e),f.on("$md.dragstart",n).on("$md.drag",t).on("$md.dragend",i),r.$on("$destroy",function(){u.off("mousedown",e).remove(),f.off("$md.dragstart",n).off("$md.drag",t).off("$md.dragend",i),p(),u=null,f=null,p=null})}}var m=!o.hasOwnProperty("mdNoAutogrow");if(c(),m){var v=o.hasOwnProperty("rows")?parseInt(o.rows):NaN,h=o.hasOwnProperty("maxRows")?parseInt(o.maxRows):NaN,$=r.$on("md-resize-textarea",t),M=null,C=s[0];if(i(function(){e.nextTick(t)},10,!1),s.on("input",t),f&&p.$formatters.push(l),v||s.attr("rows",1),angular.element(n).on("resize",t),r.$on("$destroy",d),o.hasOwnProperty("mdDetectHidden")){var w=function(){var e=!1;return function(){var n=0===C.offsetHeight;n===!1&&e===!0&&t(),e=n}}();r.$watch(function(){return e.nextTick(w,!1),!0})}}}var g=u[0],f=!!u[1],p=u[1]||e.fakeNgModel(),v=u[2],h=angular.isDefined(o.readonly),$=e.parseAttributeBoolean(o.mdNoAsterisk),M=s[0].tagName.toLowerCase();if(g){if("hidden"===o.type)return void s.attr("aria-hidden","true");if(g.input){if(g.input[0].contains(s[0]))return;throw new Error(" can only have *one* ,