(function(e){var c={transparent:16777216,aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};function a(f){function h(l,j){var k;if(void 0!==l){l=parseFloat(l)}if(void 0===j){j=255;k=255}else{if(1===j){if(void 0===l||1===l){return 1}j=100;k=1}else{k=j}}if(isNaN(l)||l<=0){return 0}if(j<l){return k}if(l<1||1===j){if(k===1){return l}else{return(l*k)|0}}return l*k/j}function g(k,p,n){k=h(k,360)/360;p=h(p,1);n=h(n,1);if(0===p){n=Math.round(n*255);return[n,n,n]}function j(m,r,l){if(l<0){++l}if(l>1){--l}if(6*l<1){return m+(r-m)*6*l}if(2*l<1){return r}if(3*l<2){return m+(r-m)*(4-6*l)}return m}var q=n<0.5?(n+n*p):(n+p-n*p);var o=n+n-q;return[Math.round(255*j(o,q,k+1/3)),Math.round(255*j(o,q,k)),Math.round(255*j(o,q,k-1/3))]}function i(j,p,r){j=h(j,360)/60;p=h(p,1);r=h(r,1);var o=j|0;var q=j-o;q=(j&1)?q:1-q;var k=Math.round(255*(r*(1-p)));var l=Math.round(255*(r*(1-p*q)));r=Math.round(255*r);switch(o){case 6:case 0:return[r,l,k];case 1:return[l,r,k];case 2:return[k,r,l];case 3:return[k,l,r];case 4:return[l,k,r];case 5:return[r,k,l]}}this.setColor=function(j){this.success=true;if(typeof j==="number"){this.a=((j>>24)&255)/255;this.r=(j>>16)&255;this.g=(j>>8)&255;this.b=(j)&255;return}while(typeof j==="object"){if(0 in j&&1 in j&&2 in j){this.a=h(j[3],1);this.r=h(j[0]);this.g=h(j[1]);this.b=h(j[2]);return}else{if("r" in j&&"g" in j&&"b" in j){this.a=h(j.a,1);this.r=h(j.r);this.g=h(j.g);this.b=h(j.b);return}else{if("h" in j&&"s" in j){var n;if("l" in j){n=g(j.h,j.s,j.l)}else{if("v" in j){n=i(j.h,j.s,j.v)}else{if("b" in j){n=i(j.h,j.s,j.b)}else{break}}}this.a=h(j.a,1);this.r=n[0];this.g=n[1];this.b=n[2];return}}}break}if(typeof j!=="string"){this.success=false;return}j=j.toLowerCase().replace(/[^a-z0-9,.()#%]/g,"");var m,l;if(j in c){l=c[j];this.a=(!((l>>24)&255))|0;this.r=((l>>16)&255);this.g=((l>>8)&255);this.b=((l)&255);return}if(m=/^([1-9]\d*)$/.exec(j)){l=parseInt(m[1],10);this.a=(((l>>24)&255)||255)/255;this.r=((l>>16)&255);this.g=((l>>8)&255);this.b=((l)&255);return}if(m=/^#?([0-9a-f]{2})([0-9a-f]{2})([0-9a-f]{2})$/.exec(j)){this.a=1;this.r=parseInt(m[1],16);this.g=parseInt(m[2],16);this.b=parseInt(m[3],16);return}if(m=/^#?([0-9a-f])([0-9a-f])([0-9a-f])$/.exec(j)){this.a=1;this.r=parseInt(m[1]+m[1],16);this.g=parseInt(m[2]+m[2],16);this.b=parseInt(m[3]+m[3],16);return}if(m=/^rgba?\((\d{1,3}),(\d{1,3}),(\d{1,3})(,([0-9.]+))?\)$/.exec(j)){this.a=h(m[5],1);this.r=h(m[1]);this.g=h(m[2]);this.b=h(m[3]);return}if(m=/^rgba?\(([0-9.]+\%),([0-9.]+\%),([0-9.]+\%)(,([0-9.]+)\%?)?\)$/.exec(j)){this.a=h(m[5],1);this.r=Math.round(h(m[1],100)*2.55);this.g=Math.round(h(m[2],100)*2.55);this.b=Math.round(h(m[3],100)*2.55);return}if(m=/^hs([bvl])a?\((\d{1,3}),(\d{1,3}),(\d{1,3})(,([0-9.]+))?\)$/.exec(j)){var k;if(m[1]==="l"){k=g}else{k=i}l=k(parseInt(m[2],10),parseInt(m[3],10),parseInt(m[4],10));this.a=h(m[6],1);this.r=l[0];this.g=l[1];this.b=l[2];return}if(m=/^(\d{1,3}),(\d{1,3}),(\d{1,3})(,([0-9.]+))?$/.exec(j)){this.a=h(m[5],1);this.r=h(m[1]);this.g=h(m[2]);this.b=h(m[3]);return}this.success=false};this.getColor=function(j){if(void 0!==j){switch(j.toLowerCase()){case"rgb":return this.getRGB();case"hsv":case"hsb":return this.getHSV();case"hsl":return this.getHSL();case"int":return this.getInt();case"array":return this.getArray();case"fraction":return this.getFraction();case"css":case"style":return this.getCSS();case"name":return this.getName()}}return this.getHex()};this.getRGB=function(){if(this.success){return{r:this.r,g:this.g,b:this.b,a:this.a}}return null};this.getCSS=function(){if(this.success){if(this.a==1){return"rgb("+this.r+", "+this.g+", "+this.b+")"}return"rgba("+this.r+", "+this.g+", "+this.b+", "+this.a+")"}return null};this.getArray=function(){if(this.success){return[this.r,this.g,this.b,this.a*100|0]}return null};this.getName=function(){if(this.success){var o=null;var l;var k=c;var m=this.getHSL();for(var j in k){var n=new a(k[j]).getHSL();var p=Math.sqrt(0.5*(m.h-n.h)*(m.h-n.h)+0.5*(m.s-n.s)*(m.s-n.s)+(m.l-n.l)*(m.l-n.l));if(null===o||p<o){o=p;l=j}}return l}return null};this.getFraction=function(){if(this.success){return{r:this.r/255,g:this.g/255,b:this.b/255,a:this.a}}return null};this.getHSL=function(){if(this.success){var o=this.r/255;var j=this.g/255;var n=this.b/255;var q=Math.min(o,j,n);var u=Math.max(o,j,n);var t=u-q;var k,p,m=(u+q)/2;if(0==t){k=0;p=0}else{if(u==o){k=(j-n)/t}else{if(u==j){k=2+(n-o)/t}else{if(u==n){k=4+(o-j)/t}}}if(k<0){k+=6}p=t/(m<0.5?u+q:2-u-q)}return{h:Math.round(k*60),s:Math.round(p*100),l:Math.round(m*100),a:this.a}}return null};this.getHSV=function(){if(this.success){var p=this.r/255;var j=this.g/255;var o=this.b/255;var t=Math.min(p,j,o);var w=Math.max(p,j,o);var u=w-t;var k,q,x=w;if(0==u){k=0;q=0}else{q=u/w;u*=6;var l=0.5+(w-p)/u;var n=0.5+(w-j)/u;var m=0.5+(w-o)/u;if(p==w){k=m-n}else{if(j==w){k=1/3+l-m}else{if(o==w){k=2/3+n-l}}}if(k<0){++k}if(k>1){--k}}return{h:Math.round(k*360),s:Math.round(q*100),v:Math.round(x*100),a:this.a}}return null};this.getHex=function(){if(this.success){var j="0123456789abcdef";var l=this.r>>4;var o=this.g>>4;var k=this.b>>4;var m=this.r&15;var p=this.g&15;var n=this.b&15;if(0===((l^m)|(o^p)|(k^n))){return"#"+j.charAt(l)+j.charAt(o)+j.charAt(k)}return"#"+j.charAt(l)+j.charAt(m)+j.charAt(o)+j.charAt(p)+j.charAt(k)+j.charAt(n)}return null};this.getInt=function(j){if(this.success){if(void 0!==j){return((this.a*100|0)<<24^this.r<<16^this.g<<8^this.b)}return(this.r<<16^this.g<<8^this.b)&16777215}return null};this.toString=function(){return this.getHex()};this.setColor(f)}e.each(["color","backgroundColor","borderColor","borderTopColor","borderBottomColor","borderLeftColor","borderRightColor","outlineColor"],function(g,f){e.fx.step[f]=function(l){if(l.xinit===void 0){if(typeof l.end==="string"&&-1!==l.end.indexOf(";")){var h,i=l.end.split(";");if(i.length>2){for(h in i){if(-1===i[h].indexOf("native")){i[h]=new a(i[h])}else{i[h]=b(l.elem,f)}}l.start=null;l.end=i}else{l.start=new a(i[0]);l.end=new a(i[1])}}else{l.start=b(l.elem,f);l.end=new a(l.end)}l.xinit=1}var p=l.start;var q=l.end;var o=l.pos;if(null===p){var j=o*(q.length-1),k=o<1?j|0:q.length-2;p=q[k];q=q[k+1];o=j-k}if(e.support.opacity){l.elem.style[f]="rgba("+((p.r+(q.r-p.r)*o)|0)+","+((p.g+(q.g-p.g)*o)|0)+","+((p.b+(q.b-p.b)*o)|0)+","+((p.a+(q.a-p.a)*o))+")"}else{l.elem.style[f]="rgb("+((p.r+(q.r-p.r)*o)|0)+","+((p.g+(q.g-p.g)*o)|0)+","+((p.b+(q.b-p.b)*o)|0)+")"}}});function b(h,g){var f="";do{f=e.curCSS(h,g);if(""!==f&&"transparent"!==f&&"rgba(0, 0, 0, 0)"!==f||e.nodeName(h,"body")){break}}while(h=h.parentNode);if(""===f){if(e.support.opacity){f="transparent"}else{if("backgroundColor"===g){f="white"}else{f="black"}}}return new a(f)}function d(){this.test=function(g){var f=new a(g);if(f.success){return f}return null};this.red=function(g){var f=new a(g);if(f.success){f.g=255;f.b=255;return f}return null};this.blue=function(g){var f=new a(g);if(f.success){f.r=255;f.g=255;return f}return null};this.green=function(g){var f=new a(g);if(f.success){f.r=255;f.b=255;return f}return null};this.sepia=function(k){var j=new a(k);if(j.success){var h=j.r,f=j.g,i=j.b;j.r=Math.round(h*0.393+f*0.769+i*0.189);j.g=Math.round(h*0.349+f*0.686+i*0.168);j.b=Math.round(h*0.272+f*0.534+i*0.131);return j}return null};this.random=function(){return new a([(255*Math.random())|0,(255*Math.random())|0,(255*Math.random())|0])};this.inverse=function(g){var f=new a(g);if(f.success){f.r^=255;f.g^=255;f.b^=255;return f}return null};this.opacity=function(i,j,f){var g=new a(i);var h=new a(j);if(g.success&h.success){if(f>1){f/=100}f=Math.max(f-1+h.a,0);g.r=Math.round((h.r-g.r)*f+g.r);g.g=Math.round((h.g-g.g)*f+g.g);g.b=Math.round((h.b-g.b)*f+g.b);return g}return null};this.greyfilter=function(i,f){var g,h=new a(i);if(h.success){switch(f){case 1:g=0.35+13*(h.r+h.g+h.b)/60;break;case 2:g=(13*(h.r+h.g+h.b)+5355)/60;break;default:g=h.r*0.3+h.g*0.59+h.b*0.11}h.r=h.g=h.b=Math.min(g|0,255);return h}return null};this.webround=function(g){var f=new a(g);if(f.success){if((f.r+=51-f.r%51)>255){f.r=255}if((f.g+=51-f.g%51)>255){f.g=255}if((f.b+=51-f.b%51)>255){f.b=255}return f}return null};this.distance=function(h,i){var f=new a(h);var g=new a(i);if(f.success&g.success){return Math.sqrt(3*(g.r-f.r)*(g.r-f.r)+4*(g.g-f.g)*(g.g-f.g)+2*(g.b-f.b)*(g.b-f.b))}return null};this.readable=function(g,i){var f=new a(i);var h=new a(g);if(f.success&h.success){return((h.r-f.r)*(h.r-f.r)+(h.g-f.g)*(h.g-f.g)+(h.b-f.b)*(h.b-f.b))>10404}return null};this.combine=function(h,i){var f=new a(h);var g=new a(i);if(f.success&g.success){f.r^=g.r;f.g^=g.g;f.b^=g.b;return f}return null};this.breed=function(f,g){var k=new a(f);var l=new a(g);var j=0;if(k.success&l.success){for(var h=0;h<6;++h){if(Math.random()<0.5){j|=15<<(h<<2)}}k.r=(k.r&((j>>16)&255))|(l.r&(((j>>16)&255)^255));k.g=(k.g&((j>>8)&255))|(l.g&(((j>>8)&255)^255));k.b=(k.b&((j>>0)&255))|(l.b&(((j>>0)&255)^255));return k}return null};this.additive=function(h,i){var f=new a(h);var g=new a(i);if(f.success&g.success){if((f.r+=g.r)>255){f.r=255}if((f.g+=g.g)>255){f.g=255}if((f.b+=g.b)>255){f.b=255}return f}return null};this.subtractive=function(h,i){var f=new a(h);var g=new a(i);if(f.success&g.success){if((f.r+=g.r-255)<0){f.r=0}if((f.g+=g.g-255)<0){f.g=0}if((f.b+=g.b-255)<0){f.b=0}return f}return null};this.subtract=function(h,i){var f=new a(h);var g=new a(i);if(f.success&g.success){if((f.r-=g.r)<0){f.r=0}if((f.g-=g.g)<0){f.g=0}if((f.b-=g.b)<0){f.b=0}return f}return null};this.multiply=function(h,i){var f=new a(h);var g=new a(i);if(f.success&g.success){f.r=(f.r/255*g.r)|0;f.g=(f.g/255*g.g)|0;f.b=(f.b/255*g.b)|0;return f}return null};this.average=function(h,i){var f=new a(h);var g=new a(i);if(f.success&g.success){f.r=(f.r+g.r)>>1;f.g=(f.g+g.g)>>1;f.b=(f.b+g.b)>>1;return f}return null};this.triad=function(g){var f=new a(g);if(f.success){return[f,new a([f.b,f.r,f.g]),new a([f.g,f.b,f.r])]}return null};this.tetrad=function(g){var f=new a(g);if(f.success){return[f,new a([f.b,f.r,f.b]),new a([f.b,f.g,f.r]),new a([f.r,f.b,f.r])]}return null};this.gradientlevel=function(f,g,h,j){if(h>j){return null}var i=new a(f);var k=new a(g);if(i.success&k.success){i.r=(i.r+((k.r-i.r)/j)*h)|0;i.g=(i.g+((k.g-i.g)/j)*h)|0;i.b=(i.b+((k.b-i.b)/j)*h)|0;return i}return null};this.gradientarray=function(h,g,f){if(g>f){return null}var l=(g*(h.length-1)/f)|0;var i=(g-f*l/(h.length-1))/f;var j=new a(h[l]);var k=new a(h[l+1]);if(j.success&k.success){j.r=(j.r+h.length*(k.r-j.r)*i)|0;j.g=(j.g+h.length*(k.g-j.g)*i)|0;j.b=(j.b+h.length*(k.b-j.b)*i)|0;return j}return null};this.nearestname=function(f){f=new a(f);if(f.success){return f.getName()}return null};this.darken=function(h,f,i){if(f===void 0){f=1}else{if(f<0){return this.lighten(h,-f,i)}}if(i===void 0){i=32}var g=new a(h);if(g.success){if((g.r-=i*f)<0){g.r=0}if((g.g-=i*f)<0){g.g=0}if((g.b-=i*f)<0){g.b=0}return g}return null};this.lighten=function(h,f,i){if(f===void 0){f=1}else{if(f<0){return this.darken(h,-f,i)}}if(i===void 0){i=32}var g=new a(h);if(g.success){if((g.r+=i*f)>255){g.r=255}if((g.g+=i*f)>255){g.g=255}if((g.b+=i*f)>255){g.b=255}return g}return null};this.analogous=function(f,l,j){if(l===void 0){l=8}if(j===void 0){j=30}var k=new a(f);if(k.success){var g=k.getHSV();var h=360/j,i=[k];for(g.h=((g.h-(h*l>>1))+720)%360;--l;){g.h+=h;g.h%=360;i.push(new a(g))}return i}return null};this.complementary=function(h){var g=new a(h);if(g.success){var f=g.getHSL();f.h=(f.h+180)%360;return new a(f)}return null};this.splitcomplement=function(i){var h=new a(i);if(h.success){var f=h.getHSV();var g=[h];f.h+=72;f.h%=360;g.push(new a(f));f.h+=144;f.h%=360;g.push(new a(f));return g}return null};this.monochromatic=function(i,g){if(g===void 0){g=6}var h=new a(i);if(h.success){var f=h.getHSV();var j=[h];while(--g){f.v+=20;f.v%=100;j.push(new a(f))}return j}return null}}e.xcolor=new d();e.fn.isReadable=function(){var i=this[0];var g="";var h="";do{if(""===g&&("transparent"===(g=e.curCSS(i,"color"))||"rgba(0, 0, 0, 0)"===g)){g=""}if(""===h&&("transparent"===(h=e.curCSS(i,"backgroundColor"))||"rgba(0, 0, 0, 0)"===h)){h=""}if(""!==g&&""!==h||e.nodeName(i,"body")){break}}while(i=i.parentNode);if(""===g){g="black"}if(""===h){h="white"}return e.xcolor.readable(h,g)}})(jQuery);
