text: /*!
   * Angular Material Design
   * https://github.com/angular/material
   * @license MIT
   * v1.1.0-rc.5-master-2ddeb91
   */
  goog.provide("ngmaterial.components.colors"),goog.require("ngmaterial.core"),function(){"use strict";function e(e,r,o){function t(e,r){try{r&&e.css(l(r))}catch(n){o.error(n.message)}}function a(e){var r=u(e);return s(r)}function s(o,n){n=n||!1;var t=e.PALETTES[o.palette][o.hue];return t=n?t.contrast:t.value,r.supplant("rgba({0}, {1}, {2}, {3})",[t[0],t[1],t[2],t[3]||o.opacity])}function l(e){var r={},o=e.hasOwnProperty("color");return angular.forEach(e,function(e,n){var t=u(e),a=n.indexOf("background")>-1;r[n]=s(t),a&&!o&&(r.color=s(t,!0))}),r}function i(r){return angular.isDefined(e.THEMES[r.split("-")[0]])}function u(r){var o=r.split("-"),n=angular.isDefined(e.THEMES[o[0]]),t=n?o.splice(0,1)[0]:e.defaultTheme();return{theme:t,palette:c(o,t),hue:m(o,t),opacity:o[2]||1}}function c(o,t){var a=o.length>1&&n.indexOf(o[1])!==-1,s=o[0].replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase();if(a&&(s=o[0]+"-"+o.splice(1,1)),n.indexOf(s)===-1){var l=e.THEMES[t].colors[s];if(!l)throw new Error(r.supplant("mdColors: couldn't find '{palette}' in the palettes.",{palette:s}));s=l.name}return s}function m(o,n){var t=e.THEMES[n].colors;if("hue"===o[1]){var a=parseInt(o.splice(2,1)[0],10);if(a<1||a>3)throw new Error(r.supplant("mdColors: 'hue-{hueNumber}' is not a valid hue, can be only 'hue-1', 'hue-2' and 'hue-3'",{hueNumber:a}));if(o[1]="hue-"+a,!(o[0]in t))throw new Error(r.supplant("mdColors: 'hue-x' can only be used with [{availableThemes}], but was used with '{usedTheme}'",{availableThemes:Object.keys(t).join(", "),usedTheme:o[0]}));return t[o[0]].hues[o[1]]}return o[1]||t[o[0]in t?o[0]:"primary"].hues["default"]}return n=n||Object.keys(e.PALETTES),{applyThemeColors:t,getThemeColor:a,hasTheme:i}}function r(e,r,n,t){return{restrict:"A",require:["^?mdTheme"],compile:function(a,s){function l(){var e=s.mdColors,n=e.indexOf("::")>-1,t=!!n||o.test(s.mdColors);s.mdColors=e.replace("::","");var a=angular.isDefined(s.mdColorsWatch);return!n&&!t&&(!a||r.parseAttributeBoolean(s.mdColorsWatch))}var i=l();return function(r,o,a,s){var l=s[0],u={},c=function(o){"string"!=typeof o&&(o=""),a.mdColors||(a.mdColors="{}");var n=t(a.mdColors)(r);return l&&Object.keys(n).forEach(function(r){var t=n[r];e.hasTheme(t)||(n[r]=(o||l.$mdTheme)+"-"+t)}),m(n),n},m=function(e){if(!angular.equals(e,u)){var r=Object.keys(u);u.background&&!r.color&&r.push("color"),r.forEach(function(e){o.css(e,"")})}u=e},h=angular.noop;l&&(h=l.registerChanges(function(r){e.applyThemeColors(o,c(r))})),r.$on("$destroy",function(){h()});try{i?r.$watch(c,angular.bind(this,e.applyThemeColors,o),!0):e.applyThemeColors(o,c())}catch(d){n.error(d.message)}}}}}var o=/^{((\s|,)*?["'a-zA-Z-]+?\s*?:\s*?('|")[a-zA-Z0-9-.]*('|"))+\s*}$/,n=void 0;angular.module("material.components.colors",["material.core"]).directive("mdColors",r).service("$mdColors",e),e.$inject=["$mdTheming","$mdUtil","$log"],r.$inject=["$mdColors","$mdUtil","$log","$parse"]}(),ngmaterial.components.colors=angular.module("material.components.colors");