var QRCode;!function(){function aR(aR){this.mode=eV.MODE_8BIT_BYTE,this.data=aR,this.parsedData=[];for(var gg=0,cN=this.data.length;cN>gg;gg++){var fV=[],aG=this.data.charCodeAt(gg);aG>65536?(fV[0]=240|(1835008&aG)>>>18,fV[1]=128|(258048&aG)>>>12,fV[2]=128|(4032&aG)>>>6,fV[3]=128|63&aG):aG>2048?(fV[0]=224|(61440&aG)>>>12,fV[1]=128|(4032&aG)>>>6,fV[2]=128|63&aG):aG>128?(fV[0]=192|(1984&aG)>>>6,fV[1]=128|63&aG):fV[0]=aG,this.parsedData.push(fV)}this.parsedData=Array.prototype.concat.apply([],this.parsedData),this.parsedData.length!=this.data.length&&(this.parsedData.unshift(191),this.parsedData.unshift(187),this.parsedData.unshift(239))}function gg(aR,gg){this.typeNumber=aR,this.errorCorrectLevel=gg,this.modules=null,this.moduleCount=0,this.dataCache=null,this.dataList=[]}function cN(aR,gg){if(void 0==aR.length)throw new Error(aR.length+"/"+gg);for(var cN=0;cN<aR.length&&0==aR[cN];)cN++;this.num=new Array(aR.length-cN+gg);for(var fV=0;fV<aR.length-cN;fV++)this.num[fV]=aR[fV+cN]}function fV(aR,gg){this.totalCount=aR,this.dataCount=gg}function aG(){this.buffer=[],this.length=0}function dC(){return"undefined"!=typeof CanvasRenderingContext2D}function de(){var aR=!1,gg=navigator.userAgent;if(/android/i.test(gg)){aR=!0;var cN=gg.toString().match(/android ([0-9]\.[0-9])/i);cN&&cN[1]&&(aR=parseFloat(cN[1]))}return aR}function eL(aR,gg){for(var cN=1,fV=fH(aR),aG=0,dC=hb.length;dC>=aG;aG++){var de=0;switch(gg){case bK.L:de=hb[aG][0];break;case bK.M:de=hb[aG][1];break;case bK.Q:de=hb[aG][2];break;case bK.H:de=hb[aG][3]}if(de>=fV)break;cN++}if(cN>hb.length)throw new Error("Too long data");return cN}function fH(aR){var gg=encodeURI(aR).toString().replace(/\%[0-9a-fA-F]{2}/g,"a");return gg.length+(gg.length!=aR?3:0)}aR.prototype={getLength:function(aR){return this.parsedData.length},write:function(aR){for(var gg=0,cN=this.parsedData.length;cN>gg;gg++)aR.put(this.parsedData[gg],8)}},gg.prototype={addData:function(gg){var cN=new aR(gg);this.dataList.push(cN),this.dataCache=null},isDark:function(aR,gg){if(0>aR||this.moduleCount<=aR||0>gg||this.moduleCount<=gg)throw new Error(aR+","+gg);return this.modules[aR][gg]},getModuleCount:function(){return this.moduleCount},make:function(){this.makeImpl(!1,this.getBestMaskPattern())},makeImpl:function(aR,cN){this.moduleCount=4*this.typeNumber+17,this.modules=new Array(this.moduleCount);for(var fV=0;fV<this.moduleCount;fV++){this.modules[fV]=new Array(this.moduleCount);for(var aG=0;aG<this.moduleCount;aG++)this.modules[fV][aG]=null}this.setupPositionProbePattern(0,0),this.setupPositionProbePattern(this.moduleCount-7,0),this.setupPositionProbePattern(0,this.moduleCount-7),this.setupPositionAdjustPattern(),this.setupTimingPattern(),this.setupTypeInfo(aR,cN),this.typeNumber>=7&&this.setupTypeNumber(aR),null==this.dataCache&&(this.dataCache=gg.createData(this.typeNumber,this.errorCorrectLevel,this.dataList)),this.mapData(this.dataCache,cN)},setupPositionProbePattern:function(aR,gg){for(var cN=-1;7>=cN;cN++)if(!(-1>=aR+cN||this.moduleCount<=aR+cN))for(var fV=-1;7>=fV;fV++)-1>=gg+fV||this.moduleCount<=gg+fV||(cN>=0&&6>=cN&&(0==fV||6==fV)||fV>=0&&6>=fV&&(0==cN||6==cN)||cN>=2&&4>=cN&&fV>=2&&4>=fV?this.modules[aR+cN][gg+fV]=!0:this.modules[aR+cN][gg+fV]=!1)},getBestMaskPattern:function(){for(var aR=0,gg=0,cN=0;8>cN;cN++){this.makeImpl(!0,cN);var fV=aP.getLostPoint(this);(0==cN||aR>fV)&&(aR=fV,gg=cN)}return gg},createMovieClip:function(aR,gg,cN){var fV=aR.createEmptyMovieClip(gg,cN),aG=1;this.make();for(var dC=0;dC<this.modules.length;dC++)for(var de=dC*aG,eL=0;eL<this.modules[dC].length;eL++){var fH=eL*aG,eV=this.modules[dC][eL];eV&&(fV.beginFill(0,100),fV.moveTo(fH,de),fV.lineTo(fH+aG,de),fV.lineTo(fH+aG,de+aG),fV.lineTo(fH,de+aG),fV.endFill())}return fV},setupTimingPattern:function(){for(var aR=8;aR<this.moduleCount-8;aR++)null==this.modules[aR][6]&&(this.modules[aR][6]=aR%2==0);for(var gg=8;gg<this.moduleCount-8;gg++)null==this.modules[6][gg]&&(this.modules[6][gg]=gg%2==0)},setupPositionAdjustPattern:function(){for(var aR=aP.getPatternPosition(this.typeNumber),gg=0;gg<aR.length;gg++)for(var cN=0;cN<aR.length;cN++){var fV=aR[gg],aG=aR[cN];if(null==this.modules[fV][aG])for(var dC=-2;2>=dC;dC++)for(var de=-2;2>=de;de++)-2==dC||2==dC||-2==de||2==de||0==dC&&0==de?this.modules[fV+dC][aG+de]=!0:this.modules[fV+dC][aG+de]=!1}},setupTypeNumber:function(aR){for(var gg=aP.getBCHTypeNumber(this.typeNumber),cN=0;18>cN;cN++){var fV=!aR&&1==(gg>>cN&1);this.modules[Math.floor(cN/3)][cN%3+this.moduleCount-8-3]=fV}for(var cN=0;18>cN;cN++){var fV=!aR&&1==(gg>>cN&1);this.modules[cN%3+this.moduleCount-8-3][Math.floor(cN/3)]=fV}},setupTypeInfo:function(aR,gg){for(var cN=this.errorCorrectLevel<<3|gg,fV=aP.getBCHTypeInfo(cN),aG=0;15>aG;aG++){var dC=!aR&&1==(fV>>aG&1);6>aG?this.modules[aG][8]=dC:8>aG?this.modules[aG+1][8]=dC:this.modules[this.moduleCount-15+aG][8]=dC}for(var aG=0;15>aG;aG++){var dC=!aR&&1==(fV>>aG&1);8>aG?this.modules[8][this.moduleCount-aG-1]=dC:9>aG?this.modules[8][15-aG-1+1]=dC:this.modules[8][15-aG-1]=dC}this.modules[this.moduleCount-8][8]=!aR},mapData:function(aR,gg){for(var cN=-1,fV=this.moduleCount-1,aG=7,dC=0,de=this.moduleCount-1;de>0;de-=2)for(6==de&&de--;;){for(var eL=0;2>eL;eL++)if(null==this.modules[fV][de-eL]){var fH=!1;dC<aR.length&&(fH=1==(aR[dC]>>>aG&1));var eV=aP.getMask(gg,fV,de-eL);eV&&(fH=!fH),this.modules[fV][de-eL]=fH,aG--,-1==aG&&(dC++,aG=7)}if(fV+=cN,0>fV||this.moduleCount<=fV){fV-=cN,cN=-cN;break}}}},gg.PAD0=236,gg.PAD1=17,gg.createData=function(aR,cN,dC){for(var de=fV.getRSBlocks(aR,cN),eL=new aG,fH=0;fH<dC.length;fH++){var eV=dC[fH];eL.put(eV.mode,4),eL.put(eV.getLength(),aP.getLengthInBits(eV.mode,aR)),eV.write(eL)}for(var bK=0,fH=0;fH<de.length;fH++)bK+=de[fH].dataCount;if(eL.getLengthInBits()>8*bK)throw new Error("code length overflow. ("+eL.getLengthInBits()+">"+8*bK+")");for(eL.getLengthInBits()+4<=8*bK&&eL.put(0,4);eL.getLengthInBits()%8!=0;)eL.putBit(!1);for(;;){if(eL.getLengthInBits()>=8*bK)break;if(eL.put(gg.PAD0,8),eL.getLengthInBits()>=8*bK)break;eL.put(gg.PAD1,8)}return gg.createBytes(eL,de)},gg.createBytes=function(aR,gg){for(var fV=0,aG=0,dC=0,de=new Array(gg.length),eL=new Array(gg.length),fH=0;fH<gg.length;fH++){var eV=gg[fH].dataCount,bK=gg[fH].totalCount-eV;aG=Math.max(aG,eV),dC=Math.max(dC,bK),de[fH]=new Array(eV);for(var bV=0;bV<de[fH].length;bV++)de[fH][bV]=255&aR.buffer[bV+fV];fV+=eV;var fR=aP.getErrorCorrectPolynomial(bK),da=new cN(de[fH],fR.getLength()-1),hb=da.mod(fR);eL[fH]=new Array(fR.getLength()-1);for(var bV=0;bV<eL[fH].length;bV++){var bg=bV+hb.getLength()-eL[fH].length;eL[fH][bV]=bg>=0?hb.get(bg):0}}for(var ah=0,bV=0;bV<gg.length;bV++)ah+=gg[bV].totalCount;for(var cB=new Array(ah),aJ=0,bV=0;aG>bV;bV++)for(var fH=0;fH<gg.length;fH++)bV<de[fH].length&&(cB[aJ++]=de[fH][bV]);for(var bV=0;dC>bV;bV++)for(var fH=0;fH<gg.length;fH++)bV<eL[fH].length&&(cB[aJ++]=eL[fH][bV]);return cB};for(var eV={MODE_NUMBER:1,MODE_ALPHA_NUM:2,MODE_8BIT_BYTE:4,MODE_KANJI:8},bK={L:1,M:0,Q:3,H:2},bV={PATTERN000:0,PATTERN001:1,PATTERN010:2,PATTERN011:3,PATTERN100:4,PATTERN101:5,PATTERN110:6,PATTERN111:7},aP={PATTERN_POSITION_TABLE:[[],[6,18],[6,22],[6,26],[6,30],[6,34],[6,22,38],[6,24,42],[6,26,46],[6,28,50],[6,30,54],[6,32,58],[6,34,62],[6,26,46,66],[6,26,48,70],[6,26,50,74],[6,30,54,78],[6,30,56,82],[6,30,58,86],[6,34,62,90],[6,28,50,72,94],[6,26,50,74,98],[6,30,54,78,102],[6,28,54,80,106],[6,32,58,84,110],[6,30,58,86,114],[6,34,62,90,118],[6,26,50,74,98,122],[6,30,54,78,102,126],[6,26,52,78,104,130],[6,30,56,82,108,134],[6,34,60,86,112,138],[6,30,58,86,114,142],[6,34,62,90,118,146],[6,30,54,78,102,126,150],[6,24,50,76,102,128,154],[6,28,54,80,106,132,158],[6,32,58,84,110,136,162],[6,26,54,82,110,138,166],[6,30,58,86,114,142,170]],G15:1335,G18:7973,G15_MASK:21522,getBCHTypeInfo:function(aR){for(var gg=aR<<10;aP.getBCHDigit(gg)-aP.getBCHDigit(aP.G15)>=0;)gg^=aP.G15<<aP.getBCHDigit(gg)-aP.getBCHDigit(aP.G15);return(aR<<10|gg)^aP.G15_MASK},getBCHTypeNumber:function(aR){for(var gg=aR<<12;aP.getBCHDigit(gg)-aP.getBCHDigit(aP.G18)>=0;)gg^=aP.G18<<aP.getBCHDigit(gg)-aP.getBCHDigit(aP.G18);return aR<<12|gg},getBCHDigit:function(aR){for(var gg=0;0!=aR;)gg++,aR>>>=1;return gg},getPatternPosition:function(aR){return aP.PATTERN_POSITION_TABLE[aR-1]},getMask:function(aR,gg,cN){switch(aR){case bV.PATTERN000:return(gg+cN)%2==0;case bV.PATTERN001:return gg%2==0;case bV.PATTERN010:return cN%3==0;case bV.PATTERN011:return(gg+cN)%3==0;case bV.PATTERN100:return(Math.floor(gg/2)+Math.floor(cN/3))%2==0;case bV.PATTERN101:return gg*cN%2+gg*cN%3==0;case bV.PATTERN110:return(gg*cN%2+gg*cN%3)%2==0;case bV.PATTERN111:return(gg*cN%3+(gg+cN)%2)%2==0;default:throw new Error("bad maskPattern:"+aR)}},getErrorCorrectPolynomial:function(aR){for(var gg=new cN([1],0),fV=0;aR>fV;fV++)gg=gg.multiply(new cN([1,fR.gexp(fV)],0));return gg},getLengthInBits:function(aR,gg){if(gg>=1&&10>gg)switch(aR){case eV.MODE_NUMBER:return 10;case eV.MODE_ALPHA_NUM:return 9;case eV.MODE_8BIT_BYTE:return 8;case eV.MODE_KANJI:return 8;default:throw new Error("mode:"+aR)}else if(27>gg)switch(aR){case eV.MODE_NUMBER:return 12;case eV.MODE_ALPHA_NUM:return 11;case eV.MODE_8BIT_BYTE:return 16;case eV.MODE_KANJI:return 10;default:throw new Error("mode:"+aR)}else{if(!(41>gg))throw new Error("type:"+gg);switch(aR){case eV.MODE_NUMBER:return 14;case eV.MODE_ALPHA_NUM:return 13;case eV.MODE_8BIT_BYTE:return 16;case eV.MODE_KANJI:return 12;default:throw new Error("mode:"+aR)}}},getLostPoint:function(aR){for(var gg=aR.getModuleCount(),cN=0,fV=0;gg>fV;fV++)for(var aG=0;gg>aG;aG++){for(var dC=0,de=aR.isDark(fV,aG),eL=-1;1>=eL;eL++)if(!(0>fV+eL||fV+eL>=gg))for(var fH=-1;1>=fH;fH++)0>aG+fH||aG+fH>=gg||(0!=eL||0!=fH)&&de==aR.isDark(fV+eL,aG+fH)&&dC++;dC>5&&(cN+=3+dC-5)}for(var fV=0;gg-1>fV;fV++)for(var aG=0;gg-1>aG;aG++){var eV=0;aR.isDark(fV,aG)&&eV++,aR.isDark(fV+1,aG)&&eV++,aR.isDark(fV,aG+1)&&eV++,aR.isDark(fV+1,aG+1)&&eV++,(0==eV||4==eV)&&(cN+=3)}for(var fV=0;gg>fV;fV++)for(var aG=0;gg-6>aG;aG++)aR.isDark(fV,aG)&&!aR.isDark(fV,aG+1)&&aR.isDark(fV,aG+2)&&aR.isDark(fV,aG+3)&&aR.isDark(fV,aG+4)&&!aR.isDark(fV,aG+5)&&aR.isDark(fV,aG+6)&&(cN+=40);for(var aG=0;gg>aG;aG++)for(var fV=0;gg-6>fV;fV++)aR.isDark(fV,aG)&&!aR.isDark(fV+1,aG)&&aR.isDark(fV+2,aG)&&aR.isDark(fV+3,aG)&&aR.isDark(fV+4,aG)&&!aR.isDark(fV+5,aG)&&aR.isDark(fV+6,aG)&&(cN+=40);for(var bK=0,aG=0;gg>aG;aG++)for(var fV=0;gg>fV;fV++)aR.isDark(fV,aG)&&bK++;var bV=Math.abs(100*bK/gg/gg-50)/5;return cN+=10*bV}},fR={glog:function(aR){if(1>aR)throw new Error("glog("+aR+")");return fR.LOG_TABLE[aR]},gexp:function(aR){for(;0>aR;)aR+=255;for(;aR>=256;)aR-=255;return fR.EXP_TABLE[aR]},EXP_TABLE:new Array(256),LOG_TABLE:new Array(256)},da=0;8>da;da++)fR.EXP_TABLE[da]=1<<da;for(var da=8;256>da;da++)fR.EXP_TABLE[da]=fR.EXP_TABLE[da-4]^fR.EXP_TABLE[da-5]^fR.EXP_TABLE[da-6]^fR.EXP_TABLE[da-8];for(var da=0;255>da;da++)fR.LOG_TABLE[fR.EXP_TABLE[da]]=da;cN.prototype={get:function(aR){return this.num[aR]},getLength:function(){return this.num.length},multiply:function(aR){for(var gg=new Array(this.getLength()+aR.getLength()-1),fV=0;fV<this.getLength();fV++)for(var aG=0;aG<aR.getLength();aG++)gg[fV+aG]^=fR.gexp(fR.glog(this.get(fV))+fR.glog(aR.get(aG)));return new cN(gg,0)},mod:function(aR){if(this.getLength()-aR.getLength()<0)return this;for(var gg=fR.glog(this.get(0))-fR.glog(aR.get(0)),fV=new Array(this.getLength()),aG=0;aG<this.getLength();aG++)fV[aG]=this.get(aG);for(var aG=0;aG<aR.getLength();aG++)fV[aG]^=fR.gexp(fR.glog(aR.get(aG))+gg);return new cN(fV,0).mod(aR)}},fV.RS_BLOCK_TABLE=[[1,26,19],[1,26,16],[1,26,13],[1,26,9],[1,44,34],[1,44,28],[1,44,22],[1,44,16],[1,70,55],[1,70,44],[2,35,17],[2,35,13],[1,100,80],[2,50,32],[2,50,24],[4,25,9],[1,134,108],[2,67,43],[2,33,15,2,34,16],[2,33,11,2,34,12],[2,86,68],[4,43,27],[4,43,19],[4,43,15],[2,98,78],[4,49,31],[2,32,14,4,33,15],[4,39,13,1,40,14],[2,121,97],[2,60,38,2,61,39],[4,40,18,2,41,19],[4,40,14,2,41,15],[2,146,116],[3,58,36,2,59,37],[4,36,16,4,37,17],[4,36,12,4,37,13],[2,86,68,2,87,69],[4,69,43,1,70,44],[6,43,19,2,44,20],[6,43,15,2,44,16],[4,101,81],[1,80,50,4,81,51],[4,50,22,4,51,23],[3,36,12,8,37,13],[2,116,92,2,117,93],[6,58,36,2,59,37],[4,46,20,6,47,21],[7,42,14,4,43,15],[4,133,107],[8,59,37,1,60,38],[8,44,20,4,45,21],[12,33,11,4,34,12],[3,145,115,1,146,116],[4,64,40,5,65,41],[11,36,16,5,37,17],[11,36,12,5,37,13],[5,109,87,1,110,88],[5,65,41,5,66,42],[5,54,24,7,55,25],[11,36,12],[5,122,98,1,123,99],[7,73,45,3,74,46],[15,43,19,2,44,20],[3,45,15,13,46,16],[1,135,107,5,136,108],[10,74,46,1,75,47],[1,50,22,15,51,23],[2,42,14,17,43,15],[5,150,120,1,151,121],[9,69,43,4,70,44],[17,50,22,1,51,23],[2,42,14,19,43,15],[3,141,113,4,142,114],[3,70,44,11,71,45],[17,47,21,4,48,22],[9,39,13,16,40,14],[3,135,107,5,136,108],[3,67,41,13,68,42],[15,54,24,5,55,25],[15,43,15,10,44,16],[4,144,116,4,145,117],[17,68,42],[17,50,22,6,51,23],[19,46,16,6,47,17],[2,139,111,7,140,112],[17,74,46],[7,54,24,16,55,25],[34,37,13],[4,151,121,5,152,122],[4,75,47,14,76,48],[11,54,24,14,55,25],[16,45,15,14,46,16],[6,147,117,4,148,118],[6,73,45,14,74,46],[11,54,24,16,55,25],[30,46,16,2,47,17],[8,132,106,4,133,107],[8,75,47,13,76,48],[7,54,24,22,55,25],[22,45,15,13,46,16],[10,142,114,2,143,115],[19,74,46,4,75,47],[28,50,22,6,51,23],[33,46,16,4,47,17],[8,152,122,4,153,123],[22,73,45,3,74,46],[8,53,23,26,54,24],[12,45,15,28,46,16],[3,147,117,10,148,118],[3,73,45,23,74,46],[4,54,24,31,55,25],[11,45,15,31,46,16],[7,146,116,7,147,117],[21,73,45,7,74,46],[1,53,23,37,54,24],[19,45,15,26,46,16],[5,145,115,10,146,116],[19,75,47,10,76,48],[15,54,24,25,55,25],[23,45,15,25,46,16],[13,145,115,3,146,116],[2,74,46,29,75,47],[42,54,24,1,55,25],[23,45,15,28,46,16],[17,145,115],[10,74,46,23,75,47],[10,54,24,35,55,25],[19,45,15,35,46,16],[17,145,115,1,146,116],[14,74,46,21,75,47],[29,54,24,19,55,25],[11,45,15,46,46,16],[13,145,115,6,146,116],[14,74,46,23,75,47],[44,54,24,7,55,25],[59,46,16,1,47,17],[12,151,121,7,152,122],[12,75,47,26,76,48],[39,54,24,14,55,25],[22,45,15,41,46,16],[6,151,121,14,152,122],[6,75,47,34,76,48],[46,54,24,10,55,25],[2,45,15,64,46,16],[17,152,122,4,153,123],[29,74,46,14,75,47],[49,54,24,10,55,25],[24,45,15,46,46,16],[4,152,122,18,153,123],[13,74,46,32,75,47],[48,54,24,14,55,25],[42,45,15,32,46,16],[20,147,117,4,148,118],[40,75,47,7,76,48],[43,54,24,22,55,25],[10,45,15,67,46,16],[19,148,118,6,149,119],[18,75,47,31,76,48],[34,54,24,34,55,25],[20,45,15,61,46,16]],fV.getRSBlocks=function(aR,gg){var cN=fV.getRsBlockTable(aR,gg);if(void 0==cN)throw new Error("bad rs block @ typeNumber:"+aR+"/errorCorrectLevel:"+gg);for(var aG=cN.length/3,dC=[],de=0;aG>de;de++)for(var eL=cN[3*de+0],fH=cN[3*de+1],eV=cN[3*de+2],bK=0;eL>bK;bK++)dC.push(new fV(fH,eV));return dC},fV.getRsBlockTable=function(aR,gg){switch(gg){case bK.L:return fV.RS_BLOCK_TABLE[4*(aR-1)+0];case bK.M:return fV.RS_BLOCK_TABLE[4*(aR-1)+1];case bK.Q:return fV.RS_BLOCK_TABLE[4*(aR-1)+2];case bK.H:return fV.RS_BLOCK_TABLE[4*(aR-1)+3];default:return}},aG.prototype={get:function(aR){var gg=Math.floor(aR/8);return 1==(this.buffer[gg]>>>7-aR%8&1)},put:function(aR,gg){for(var cN=0;gg>cN;cN++)this.putBit(1==(aR>>>gg-cN-1&1))},getLengthInBits:function(){return this.length},putBit:function(aR){var gg=Math.floor(this.length/8);this.buffer.length<=gg&&this.buffer.push(0),aR&&(this.buffer[gg]|=128>>>this.length%8),this.length++}};var hb=[[17,14,11,7],[32,26,20,14],[53,42,32,24],[78,62,46,34],[106,84,60,44],[134,106,74,58],[154,122,86,64],[192,152,108,84],[230,180,130,98],[271,213,151,119],[321,251,177,137],[367,287,203,155],[425,331,241,177],[458,362,258,194],[520,412,292,220],[586,450,322,250],[644,504,364,280],[718,560,394,310],[792,624,442,338],[858,666,482,382],[929,711,509,403],[1003,779,565,439],[1091,857,611,461],[1171,911,661,511],[1273,997,715,535],[1367,1059,751,593],[1465,1125,805,625],[1528,1190,868,658],[1628,1264,908,698],[1732,1370,982,742],[1840,1452,1030,790],[1952,1538,1112,842],[2068,1628,1168,898],[2188,1722,1228,958],[2303,1809,1283,983],[2431,1911,1351,1051],[2563,1989,1423,1093],[2699,2099,1499,1139],[2809,2213,1579,1219],[2953,2331,1663,1273]],bg=function(){var aR=function(aR,gg){this._el=aR,this._htOption=gg};return aR.prototype.draw=function(aR){function gg(aR,gg){var cN=document.createElementNS("http://www.w3.org/2000/svg",aR);for(var fV in gg)gg.hasOwnProperty(fV)&&cN.setAttribute(fV,gg[fV]);return cN}var cN=this._htOption,fV=this._el,aG=aR.getModuleCount();Math.floor(cN.width/aG),Math.floor(cN.height/aG);this.clear();var dC=gg("svg",{viewBox:"0 0 "+String(aG)+" "+String(aG),width:"100%",height:"100%",fill:cN.colorLight});dC.setAttributeNS("http://www.w3.org/2000/xmlns/","xmlns:xlink","http://www.w3.org/1999/xlink"),fV.appendChild(dC),dC.appendChild(gg("rect",{fill:cN.colorLight,width:"100%",height:"100%"})),dC.appendChild(gg("rect",{fill:cN.colorDark,width:"1",height:"1",id:"template"}));for(var de=0;aG>de;de++)for(var eL=0;aG>eL;eL++)if(aR.isDark(de,eL)){var fH=gg("use",{x:String(eL),y:String(de)});fH.setAttributeNS("http://www.w3.org/1999/xlink","href","#template"),dC.appendChild(fH)}},aR.prototype.clear=function(){for(;this._el.hasChildNodes();)this._el.removeChild(this._el.lastChild)},aR}(),ah="svg"===document.documentElement.tagName.toLowerCase(),cB=ah?bg:dC()?function(){function aR(){this._elImage.src=this._elCanvas.toDataURL("image/png"),this._elImage.style.display="block",this._elCanvas.style.display="none"}function gg(aR,gg){var cN=this;if(cN._fFail=gg,cN._fSuccess=aR,null===cN._bSupportDataURI){var fV=document.createElement("img"),aG=function(){cN._bSupportDataURI=!1,cN._fFail&&cN._fFail.call(cN)},dC=function(){cN._bSupportDataURI=!0,cN._fSuccess&&cN._fSuccess.call(cN)};return fV.onabort=aG,fV.onerror=aG,fV.onload=dC,void(fV.src="data:image/gif;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAHElEQVQI12P4//8/w38GIAXDIBKE0DHxgljNBAAO9TXL0Y4OHwAAAABJRU5ErkJggg==")}cN._bSupportDataURI===!0&&cN._fSuccess?cN._fSuccess.call(cN):cN._bSupportDataURI===!1&&cN._fFail&&cN._fFail.call(cN)}if(this._android&&this._android<=2.1){var cN=1/window.devicePixelRatio,fV=CanvasRenderingContext2D.prototype.drawImage;CanvasRenderingContext2D.prototype.drawImage=function(aR,gg,aG,dC,de,eL,fH,eV,bK){if("nodeName"in aR&&/img/i.test(aR.nodeName))for(var bV=arguments.length-1;bV>=1;bV--)arguments[bV]=arguments[bV]*cN;else"undefined"==typeof eV&&(arguments[1]*=cN,arguments[2]*=cN,arguments[3]*=cN,arguments[4]*=cN);fV.apply(this,arguments)}}var aG=function(aR,gg){this._bIsPainted=!1,this._android=de(),this._htOption=gg,this._elCanvas=document.createElement("canvas"),this._elCanvas.width=gg.width,this._elCanvas.height=gg.height,aR.appendChild(this._elCanvas),this._el=aR,this._oContext=this._elCanvas.getContext("2d"),this._bIsPainted=!1,this._elImage=document.createElement("img"),this._elImage.alt="Scan me!",this._elImage.style.display="none",this._el.appendChild(this._elImage),this._bSupportDataURI=null};return aG.prototype.draw=function(aR){var gg=this._elImage,cN=this._oContext,fV=this._htOption,aG=aR.getModuleCount(),dC=fV.width/aG,de=fV.height/aG,eL=Math.round(dC),fH=Math.round(de);gg.style.display="none",this.clear();for(var eV=0;aG>eV;eV++)for(var bK=0;aG>bK;bK++){var bV=aR.isDark(eV,bK),aP=bK*dC,fR=eV*de;cN.strokeStyle=bV?fV.colorDark:fV.colorLight,cN.lineWidth=1,cN.fillStyle=bV?fV.colorDark:fV.colorLight,cN.fillRect(aP,fR,dC,de),cN.strokeRect(Math.floor(aP)+.5,Math.floor(fR)+.5,eL,fH),cN.strokeRect(Math.ceil(aP)-.5,Math.ceil(fR)-.5,eL,fH)}this._bIsPainted=!0},aG.prototype.makeImage=function(){this._bIsPainted&&gg.call(this,aR)},aG.prototype.isPainted=function(){return this._bIsPainted},aG.prototype.clear=function(){this._oContext.clearRect(0,0,this._elCanvas.width,this._elCanvas.height),this._bIsPainted=!1},aG.prototype.round=function(aR){return aR?Math.floor(1e3*aR)/1e3:aR},aG}():function(){var aR=function(aR,gg){this._el=aR,this._htOption=gg};return aR.prototype.draw=function(aR){for(var gg=this._htOption,cN=this._el,fV=aR.getModuleCount(),aG=Math.floor(gg.width/fV),dC=Math.floor(gg.height/fV),de=['<table style="border:0;border-collapse:collapse;">'],eL=0;fV>eL;eL++){de.push("<tr>");for(var fH=0;fV>fH;fH++)de.push('<td style="border:0;border-collapse:collapse;padding:0;margin:0;width:'+aG+"px;height:"+dC+"px;background-color:"+(aR.isDark(eL,fH)?gg.colorDark:gg.colorLight)+';"></td>');de.push("</tr>")}de.push("</table>"),cN.innerHTML=de.join("");var eV=cN.childNodes[0],bK=(gg.width-eV.offsetWidth)/2,bV=(gg.height-eV.offsetHeight)/2;bK>0&&bV>0&&(eV.style.margin=bV+"px "+bK+"px")},aR.prototype.clear=function(){this._el.innerHTML=""},aR}();QRCode=function(aR,gg){if(this._htOption={width:256,height:256,typeNumber:4,colorDark:"#000000",colorLight:"#ffffff",correctLevel:bK.H},"string"==typeof gg&&(gg={text:gg}),gg)for(var cN in gg)this._htOption[cN]=gg[cN];"string"==typeof aR&&(aR=document.getElementById(aR)),this._htOption.useSVG&&(cB=bg),this._android=de(),this._el=aR,this._oQRCode=null,this._oDrawing=new cB(this._el,this._htOption),this._htOption.text&&this.makeCode(this._htOption.text)},QRCode.prototype.makeCode=function(aR){this._oQRCode=new gg(eL(aR,this._htOption.correctLevel),this._htOption.correctLevel),this._oQRCode.addData(aR),this._oQRCode.make(),this._el.title=aR,this._oDrawing.draw(this._oQRCode),this.makeImage()},QRCode.prototype.makeImage=function(){"function"==typeof this._oDrawing.makeImage&&(!this._android||this._android>=3)&&this._oDrawing.makeImage()},QRCode.prototype.clear=function(){this._oDrawing.clear()},QRCode.CorrectLevel=bK}(),function(aR,gg,cN){function fV(aR,gg){var cN=da({},aRaR,gg||{},hb(aR));cN.imageSelector&&(cN.image=fH(cN.imageSelector).map(function(aR){return aR.src}).join("||")),bK(aR,"share-component social-share"),aG(aR,cN),dC(aR,cN),aR.initialized=!0}function aG(aR,gg){var cN=de(gg),fV="prepend"==gg.mode;ah(fV?cN.reverse():cN,function(cN){var aG=eL(cN,gg),dC=gg.initialized?aP(aR,"icon-"+cN):fR('<a class="social-share-icon icon-'+cN+'"></a>');return dC.length?(dC[0].href=aG,"wechat"===cN?dC[0].tabindex=-1:dC[0].target="_blank",void(gg.initialized||(fV?aR.insertBefore(dC[0],aR.firstChild):aR.appendChild(dC[0])))):!0})}function dC(aR,gg){var cN=aP(aR,"icon-wechat","a");if(0===cN.length)return!1;var fV=fR('<div class="wechat-qrcode"><h4>'+gg.wechatQrcodeTitle+'</h4><div class="qrcode"></div><div class="help">'+gg.wechatQrcodeHelper+"</div></div>"),aG=aP(fV[0],"qrcode","div");cN[0].appendChild(fV[0]),new QRCode(aG[0],{text:gg.url,width:gg.wechatQrcodeSize,height:gg.wechatQrcodeSize})}function de(aR){aR.mobileSites.length||(aR.mobileSites=aR.sites);var gg=(aj?aR.mobileSites:aR.sites).slice(0),cN=aR.disabled;return"string"==typeof gg&&(gg=gg.split(/\s*,\s*/)),"string"==typeof cN&&(cN=cN.split(/\s*,\s*/)),aK&&cN.push("wechat"),cN.length&&ah(cN,function(aR){gg.splice(bg(aR,gg),1)}),gg}function eL(aR,gg){return gg.summary=gg.description,ggaR[aR].replace(/\{\{(\w)(\w*)\}\}/g,function(fV,aG,dC){var de=aR+aG+dC.toLowerCase();return dC=(aG+dC).toLowerCase(),encodeURIComponent((gg[de]===cN?gg[dC]:gg[de])||"")})}function fH(cN){return(gg.querySelectorAll||aR.jQuery||aR.Zepto||eV).call(gg,cN)}function eV(aR){var cN=[];return ah(aR.split(/\s*,\s*/),function(fV){var aG=fV.match(/([#.])(\w+)/);if(null===aG)throw Error("Supports only simple single #ID or .CLASS selector.");if(aG[1]){var dC=gg.getElementById(aG[2]);dC&&cN.push(dC)}cN=cN.concat(aP(aR))}),cN}function bK(aR,gg){if(gg&&"string"==typeof gg){var cN=(aR.className+" "+gg).split(/\s+/),fV=" ";ah(cN,function(aR){fV.indexOf(" "+aR+" ")<0&&(fV+=aR+" ")}),aR.className=fV.slice(1,-1)}}function bV(aR){return(gg.getElementsByName(aR)[0]||0).content}function aP(aR,gg,cN){if(aR.getElementsByClassName)return aR.getElementsByClassName(gg);var fV=[],aG=aR.getElementsByTagName(cN||"*");return gg=" "+gg+" ",ah(aG,function(aR){(" "+(aR.className||"")+" ").indexOf(gg)>=0&&fV.push(aR)}),fV}function fR(aR){var cN=gg.createElement("div");return cN.innerHTML=aR,cN.childNodes}function da(){var aR=arguments;if(cQ)return cQ.apply(null,aR);var gg={};return ah(aR,function(aR){ah(aR,function(aR,cN){gg[cN]=aR})}),aR[0]=gg}function hb(aR){if(aR.dataset)return aR.dataset;var gg={};return aR.hasAttributes()?(ah(aR.attributes,function(aR){var cN=aR.name;return 0!==cN.indexOf("data-")?!0:(cN=cN.replace(/^data-/i,"").replace(/-(\w)/g,function(aR,gg){return gg.toUpperCase()}),void(gg[cN]=aR.value))}),gg):{}}function bg(aR,gg,cN){var fV;if(gg){if(aJ)return aJ.call(gg,aR,cN);for(fV=gg.length,cN=cN?0>cN?Math.max(0,fV+cN):cN:0;fV>cN;cN++)if(cN in gg&&gg[cN]===aR)return cN}return-1}function ah(aR,gg){var fV=aR.length;if(fV===cN){for(var aG in aR)if(aR.hasOwnProperty(aG)&&gg.call(aR[aG],aR[aG],aG)===!1)break}else for(var dC=0;fV>dC&&gg.call(aR[dC],aR[dC],dC)!==!1;dC++);}function cB(cN){var fV="addEventListener",aG=gg[fV]?"":"on";~gg.readyState.indexOf("m")?cN():"load DOMContentLoaded readystatechange".replace(/\w+/g,function(dC,de){(de?gg:aR)[aG?"attachEvent":fV](aG+dC,function(){cN&&(6>de||~gg.readyState.indexOf("m"))&&(cN(),cN=0)},!1)})}var aJ=Array.prototype.indexOf,cQ=Object.assign,aK=/MicroMessenger/i.test(navigator.userAgent),aj=gg.documentElement.clientWidth<=768,eP=(gg.images[0]||0).src||"",aL=bV("site")||bV("Site")||gg.title,cP=bV("title")||bV("Title")||gg.title,bE=bV("description")||bV("Description")||"",aRaR={url:location.href,origin:location.origin,source:aL,title:cP,description:bE,image:eP,imageSelector:cN,weiboKey:"",wechatQrcodeTitle:"微信扫一扫：分享",wechatQrcodeHelper:"<p>微信里点“发现”，扫一下</p><p>二维码便可将本文分享至朋友圈。</p>",wechatQrcodeSize:100,sites:["weibo","qq","wechat","tencent","douban","qzone","linkedin","diandian","facebook","twitter","google"],mobileSites:[],disabled:[],initialized:!1},ggaR={qzone:"http://sns.qzone.qq.com/cgi-bin/qzshare/cgi_qzshare_onekey?url={{URL}}&title={{TITLE}}&desc={{DESCRIPTION}}&summary={{SUMMARY}}&site={{SOURCE}}",qq:"http://connect.qq.com/widget/shareqq/index.html?url={{URL}}&title={{TITLE}}&source={{SOURCE}}&desc={{DESCRIPTION}}&pics={{IMAGE}}",tencent:"http://share.v.t.qq.com/index.php?c=share&a=index&title={{TITLE}}&url={{URL}}&pic={{IMAGE}}",weibo:"http://service.weibo.com/share/share.php?url={{URL}}&title={{TITLE}}&pic={{IMAGE}}&appkey={{WEIBOKEY}}",wechat:"javascript:",douban:"http://shuo.douban.com/!service/share?href={{URL}}&name={{TITLE}}&text={{DESCRIPTION}}&image={{IMAGE}}&starid=0&aid=0&style=11",diandian:"http://www.diandian.com/share?lo={{URL}}&ti={{TITLE}}&type=link",linkedin:"http://www.linkedin.com/shareArticle?mini=true&ro=true&title={{TITLE}}&url={{URL}}&summary={{SUMMARY}}&source={{SOURCE}}&armin=armin",facebook:"https://www.facebook.com/sharer/sharer.php?u={{URL}}",twitter:"https://twitter.com/intent/tweet?text={{TITLE}}&url={{URL}}&via={{ORIGIN}}",google:"https://plus.google.com/share?url={{URL}}"};aR.socialShare=function(aR,gg){aR="string"==typeof aR?fH(aR):aR,aR.length===cN&&(aR=[aR]),ah(aR,function(aR){aR.initialized||fV(aR,gg)})},cB(function(){socialShare(".social-share, .share-component")})}(window,document);