(window.webpackJsonp=window.webpackJsonp||[]).push([[25,9,15],{"1Sn+":function(He,We,V){},"1XHU":function(He,We,V){"use strict";var ae=V("2qtc"),k=V("kLXV"),b=V("q1tI"),O=V.n(b),C=V("9kvl"),E=V("3wET"),M=V.n(E),w=V("bUJZ"),A=V.n(w),_=V("Ct/S"),g=V.n(_),x=function(v){var y=v.visible,p=v.occupationValue,s=v.onCancel,e=s===void 0?function(){}:s,a=function(){return O.a.createElement("div",{className:g.a.flexColumn},O.a.createElement("img",{className:g.a.img,src:A.a}),O.a.createElement("span",{className:g.a.content},"\u672A\u804C\u4E1A\u8BA4\u8BC1"))},n=function(){return O.a.createElement("div",{className:g.a.flexColumn},O.a.createElement("img",{className:g.a.img,src:M.a}),O.a.createElement("span",{className:g.a.content},"\u672A\u5B9E\u540D\u8BA4\u8BC1"))},c=function(){return p===3?O.a.createElement(O.a.Fragment,null,n(),a()):p===2?a():n()};return O.a.createElement(k.a,{centered:!0,keyboard:!1,closable:!1,destroyOnClose:!0,visible:y,title:"\u56E0\u4E3A\u4EE5\u4E0B\u539F\u56E0\uFF0C\u60A8\u6682\u65F6\u4E0D\u80FD\u8FDB\u884C\u64CD\u4F5C",okText:"\u7ACB\u5373\u8BA4\u8BC1",cancelText:"\u53D6\u6D88",width:"600px",onOk:function(){e(),C.d.push("/account/certification")},onCancel:function(){e()}},O.a.createElement("div",{className:g.a.tilte},"\u8BF7\u5728\u5B8C\u6210\u6761\u4EF6\u540E\u91CD\u8BD5"),O.a.createElement("div",{className:g.a.flexRow},c()))};We.a=Object(C.a)(function(S){var v=S.paperlibrary,y=S.loading,p=S.globalSetting;return{paperlibrary:v,globalSetting:p,loading:y.effects}})(x)},"2tKv":function(He,We,V){He.exports=V.p+"static/Code.584c4f34.png"},"3wET":function(He,We){He.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACQAAAAkCAYAAADhAJiYAAAAAXNSR0IArs4c6QAACE5JREFUWAmtWH1snVUZ/533tuvYVreyjGy3Y6srTBo2srI4XbtKgFQxIrKYzeAfk8AfCzHbCkPMjPjBP0aCsjr1D01USCQ6oosyiLF8xMGqc2BHauUj1I2Ntghs7dqytuu99/j7nfOee9/73js+jKd53+d5n3Oe5/zO8zznOafX4EO2ta/bhqlJfM4adFJ1hQWyxiIrM5QNG2CY7EnKei5agMf7V5pR9X3QRv0P1pr77WaO3AGLDoKokZYlY2hBtFqLDHLse9ZE2De41hyoNiYte19AzX22nfPdT8NtnJr6UgkIAl/dTLKXwHupeM9gqzmcBpH8rm6JI7ZYm3nhBfyAQHYlFcr4NL6yTn4kEamPxkxkutevx+5Hjcmnh+u7KqB1fXbR+Az2U195UmyWnjH8E1ULvGgsKDlRghTg8MnhPQvrsPVYqxnziqV3BSCBGZuUe21LMUGUKGx6F42K14rZJ6oWeFG19+w3eGnhPLSlQUVOM34pTGfHsR95tCBPozlOFCh5q++YOj7uqyfUxhqDbAYQjxzB8JFuoJ739qRrZ22L5tKcSQx+KbFk1VN2b8Fa5ky8QvojhEVDAh9C1DAH2NYIdFwMNM3TCIsT5wwOnbH45SlgIufDG8arv+RnsQb0SPe/rzdd0lYrAmr+s23PWzznxdXfyRzK1gEPrgU+cbHBa5MWr07KmsHq+RaXLTAYGAe29wFDMyVb6RC62YmxJjKbBj/td5+rJ1LJzeL+ihWUbHkuzpe5GYM9lwsM8MSbwLcGDMZmqc1cWlhrsOsyi20rgTubDb45YDGl0MZNPio1yS1yec2NdsldDq18jEUvzzqjjVj2UMF9i/JRDpFeMc/ihqUWT71p8fU+i3fO0eisRZ4hOjNl8f1/MWxvG3wha/GxedKVntct0SB3tM1hCIAwix0+YZWEVKRhPYF3SRjLxa+tN6hlGX56hHky7RNXyevHAe/OWPxpyCoUuKpem0F9frGBaqGBd5QYOAI1Kw7aBjuFDuWbckQt0DQfYr5srhuGkXdJ5cG4JZP+P+pjWzIn9gR5Vx746ajrLc3Fc7BDWCJM4EZu0xoXkmJ4OLqMl9HYY6Svj3vgrQ00SI9Z5Y+ewJOua/BjBrjj5IEybzjbmkN2YyoMxBJR0OmF5UreSDAmygmoLHqY5/kb3FlfWgWsJygdAu4giOnVlG39KHCcO63/HfXRd/HkgQZbgcquKaAz85GbvrMTBduEApFqUYGKTz2mIH8D4zMGs+Q/swK4Zhkno+w8vbCEpeCLBPmNq4HFDOuP+4G/vBHblN3UIz1LmajnzShD5e8yHO4BcE4HxAnKX/STE0TUPsyJjjUBG5YC937ccE2hz+DEWYs9PNN/N0hjBc0mo2waIz4ey7xxcznq+pGtYf5wc/oW95eqZcjiosRiOYvebWssNrMOLb7IYHSaRXEUGGMBHJ0G/j5icZS16QTDZQjcY/AzsHw54MKoFrAFvBRla2xeFz3fUgugMED1dDUT9YFrgdalBi++Rf6IxaFTrENTCiHcExblLIYP0lpWvFuvZLjPA799+QLzcd8oZCMEUu+HlCCE70DXLAEeuN5g1SLgJ89b/PwYcPoce90yw6hy/RCSWh6fX+Ex87UNwKkJ4DfMLdcI1EVPwH0bUciGWRdW6ztZR+IBjlzCg/NHvBk1EvZ9h4BH+lmV6bQwXkUyp4RNeMQpckwdD6fbrgJ2f5IX7bME1cMebfVqLcJwZHK8kMfb0m098qJ6pDiHS7j3U8Dliw26/0Yw9EyBVVw6GjOHbtjUaFGrpbp646n4OoZ8+zrgbl5+jzPPup4AnmeIHSDaZrr4UhLzZrZwMioU8GSpcGkSDeJS4wlX8zTvbAaO0NCv/0Exz6zk+C0twE8/b3B7qyE4r6t+VgB8dYNBF8G8+jaw6zHgRR4nwa5bcGoBNh/11GQKOJjPubXRueU+l/0tTMT5LP8PHy1gbJKAKSuGnEw/i+QwQ3F3h/4VsfjZEYMMd9fOjcAdGw3+yR131x+BV1ggK1rZdCYXZfC4s738u/Zp5tG1aYV6LvNXtwDLmcg3/4ITaytzkEC5pjAxqdfw5P/hTbwLXcLb1iGL+XUG2wmoj7Xqrj8Ag6fD8PIrb3Lf89r7zNC3zXX0Clse+1gxCSis30+5gMnc1GDwylvAmQkaUxgJItyZg68Ghgx2/p4Xtpt5B7qGt0CiPnqSYA4wd04HmzEoT/w7rI6U69onIasDz6X7zAEeC71lhx0nj5iw2rITU8AMjwuf6J6K97nk6ctDwM79zBN65a/HPX+ctcrbFE3yRED7ShRRLrRXGIRFGF3L7rHtVHou6QHxlzKpx3gBm2AVDttcVI1QijIn4KuZ9WqaJ//QmDdOGKVJXM2iRJStOFfGbBr+nr/CFgFpQOOd+b08M3cVk0S9CYvvB6iyvwRK9uNzxFMncCHqHnow0xV/+pCFj7aN0W7DrRfqhLs5qlZc8AZJ26pXcn1iC/twSq5weuqvvxrH77j+mELUoznD/KJlHpKgqcsumjlve2mqJeWg0nIrtKSpVqHhxcU3wZTGvFRXa9pO7C3/77WqaYE6P23380rRGaaQzcqQVOZQce73YLhLe+rmmq1pMFJxuyytq4Ht15nP8ljpdpX7QiFRyU+EIIQiUJUJ8aKOp51MIereRNvVwAhHVQ8lAWZv588xBf0cY6v8HJMcSXCxQVG14F1ReqWXpeWe4Yf+x59jnMXEa9k2u5mgdrASdHBqV1BTu7hiExGEfPss6b6Rh/9PP1glMDl2xZdtA8vMjRaFTl7tLqVQN86sOukJnmx8jD3FstpTCxw8+ciH+0nvv4gFlb/v9tJbAAAAAElFTkSuQmCC"},"55Ip":function(He,We,V){"use strict";V.d(We,"a",function(){return a});var ae=V("Ty5D"),k=V("dI71"),b=V("q1tI"),O=V.n(b),C=V("YS25"),E=V("17x9"),M=V.n(E),w=V("wx14"),A=V("zLVn"),_=V("9R94"),g=function(i){Object(k.a)(t,i);function t(){for(var h,f=arguments.length,T=new Array(f),R=0;R=F.length?W.slice(F.length):W}).join(`
`)}var s=[],e=[""],a=new v.a.Renderer,n=/^ *(#{1,6}) *([^\n]+?) *(?:#+ *)?(?:\n+|$)/;function c(){s.length=0,e=[""]}var l={overflow:"hidden",WebkitBoxOrient:"vertical",display:"-webkit-box",WebkitLineClamp:2};function u(B,D,P,F){if(D>=B.length||B[D].level<=P)return D;var W=B[D];F.push("- "+W.text+""),D++;var I=[];return D=u(B,D,W.level,I),I.length>0&&(F.push("
"),I.forEach(function(U){F.push(U)}),F.push("
")),F.push(" "),D=u(B,D,P,F),D}function m(){return u(s,0,0,e),e.push("
"),e.join("")}var d={heading:function(D){var P=n.exec(D);if(P)return{type:"heading",raw:P[0],depth:P[1].length,text:P[2]}},fences:function(D){var P=this.rules.block.fences.exec(D);if(P){var F=P[0],W=p(F,P[3]||""),I=P[2]?P[2].trim():P[2];if(["latex","katex","math"].indexOf(I)>=0){var U=t(),j=W;W=U,r[U]={type:"block",expression:j}}return{type:"code",raw:F,lang:I,text:W}}}},o=/(?:\${2})([^\n`]+?)(?:\${2})/gi,i=0,t=function(){return"__special_katext_id_".concat(i++,"__")},r={};function h(){return r}function f(){i=0,r={}}function T(B){return B=B.replace(o,function(D,P){var F=t();return r[F]={type:"inline",expression:P},F}),B}var R=a.listitem;a.listitem=function(B){return R(T(B))};var L=a.paragraph;a.paragraph=function(B){return L(T(B))};var N=a.tablecell;a.tablecell=function(B,D){return N(T(B),D)},a.code=function(B,D,P){var F=(D||"").match(/\S*/)[0];return F?["latex","katex","math"].indexOf(F)>=0?"".concat(B,"
"):'
').concat(P?B:Object(y.escape)(B,!0),`
`):''+(P?B:Object(y.escape)(B,!0))+"
"},a.heading=function(B,D,P){var F=this.options.headerPrefix+P.toLowerCase().replace(/[^\w\\u4e00-\\u9fa5]]+/g,"-");return s.push({anchor:F,level:D,text:B}),"'+B+""},v.a.setOptions({silent:!0,gfm:!0,pedantic:!1}),v.a.use({tokenizer:d,renderer:a});var H=v.a,K=V("SJMd"),X=V("ulZh"),z=V.n(X),J=V("m3rI"),te=V("Oy/b"),ee=V("p5ED"),ve=V("ErOA"),re=V("STEk");/* **********************************
cropro version 1.2.0
@license SEE LICENSE IN LICENSE
copyright Alan Mendelevich
see README and LICENSE for details
********************************** *//*! *****************************************************************************
Copyright (c) Microsoft Corporation.
Permission to use, copy, modify, and/or distribute this software for any
purpose with or without fee is hereby granted.
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
PERFORMANCE OF THIS SOFTWARE.
***************************************************************************** */var de=function(B,D){return(de=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(P,F){P.__proto__=F}||function(P,F){for(var W in F)Object.prototype.hasOwnProperty.call(F,W)&&(P[W]=F[W])})(B,D)};function ie(B,D){if(typeof D!="function"&&D!==null)throw new TypeError("Class extends value "+String(D)+" is not a constructor or null");function P(){this.constructor=B}de(B,D),B.prototype=D===null?Object.create(D):(P.prototype=D.prototype,new P)}function le(B,D,P,F){return new(P||(P=Promise))(function(W,I){function U($){try{G(F.next($))}catch(Y){I(Y)}}function j($){try{G(F.throw($))}catch(Y){I(Y)}}function G($){var Y;$.done?W($.value):(Y=$.value,Y instanceof P?Y:new P(function(q){q(Y)})).then(U,j)}G((F=F.apply(B,D||[])).next())})}function Q(B,D){var P,F,W,I,U={label:0,sent:function(){if(1&W[0])throw W[1];return W[1]},trys:[],ops:[]};return I={next:j(0),throw:j(1),return:j(2)},typeof Symbol=="function"&&(I[Symbol.iterator]=function(){return this}),I;function j(G){return function($){return function(Y){if(P)throw new TypeError("Generator is already executing.");for(;U;)try{if(P=1,F&&(W=2&Y[0]?F.return:Y[0]?F.throw||((W=F.return)&&W.call(F),0):F.next)&&!(W=W.call(F,Y[1])).done)return W;switch(F=0,W&&(Y=[2&Y[0],W.value]),Y[0]){case 0:case 1:W=Y;break;case 4:return U.label++,{value:Y[1],done:!1};case 5:U.label++,F=Y[1],Y=[0];continue;case 7:Y=U.ops.pop(),U.trys.pop();continue;default:if(!(W=U.trys,(W=W.length>0&&W[W.length-1])||Y[0]!==6&&Y[0]!==2)){U=0;continue}if(Y[0]===3&&(!W||Y[1]>W[0]&&Y[1]0&&P>0){var F=new ye(D,P),W=F.ratio>=1?20:F.getHorizontalLength(20),I=F.ratio<1?20:F.getVerticalLength(20),U=document.createElementNS("http://www.w3.org/2000/svg","svg");U.setAttribute("xmlns","http://www.w3.org/2000/svg"),U.setAttribute("viewBox","0 0 24 24"),document.body.appendChild(U);var j=ne.createDefs();U.appendChild(j);var G=ne.createElement("clipPath",[["id","text-bg-clip"]]);j.appendChild(G);var $=ne.createPath(ne.getHollowRectanglePath((24-W)/2,(24-I)/2,W,I,(24-W)/2+2,(24-I)/2+2,W-4,I-4));U.appendChild($);var Y=ne.createText([["x","0"],["y","0"],["font-size","7px"],["font-family","monospace"]]);Y.appendChild(ne.createTSpan(D+":"+P)),U.appendChild(Y);var q=Y.getBBox();ne.setAttributes(Y,[["x",((24-q.width)/2).toString()],["y",((24-q.height)/2-q.y).toString()]]);var Se=ne.createPath(ne.getHollowRectanglePath(0,0,24,24,(24-Math.ceil(q.width))/2,(24-Math.ceil(q.height))/2,Math.ceil(q.width),Math.ceil(q.height)));return G.appendChild(Se),ne.setAttributes($,[["clip-path","url(#text-bg-clip)"]]),document.body.removeChild(U),U.outerHTML}return''},B}(),ue=function(B){function D(P,F,W){var I=B.call(this,P,F)||this;return I.isDropdownOpen=!1,I.onClick=I.dropdownButtonClicked,I.dropdownButtons=W,I}return ie(D,B),D.prototype.setupDropdown=function(){var P=this;this.dropdownBlock=document.createElement("div"),this.dropdownBlock.className=this.dropdownClassName+" "+this.dropdownColorsClassName,this.dropdownBlock.style.display="none",this.dropdownButtons.forEach(function(F){F.className=P.className,F.colorsClassName=P.colorsClassName,P.dropdownBlock.appendChild(F.getUI())}),this.uiContainer.appendChild(this.dropdownBlock)},D.prototype.positionDropdown=function(){this.dropdownBlock.style.left=this.uiContainer.clientLeft+"px",this.dropdownBlock.style.top=this.uiContainer.clientTop+this.uiContainer.clientHeight+"px"},D.prototype.dropdownButtonClicked=function(){this.dropdownBlock===void 0&&this.setupDropdown(),this.isDropdownOpen=!this.isDropdownOpen,this.toggleDropdown()},D.prototype.toggleDropdown=function(){this.positionDropdown(),this.dropdownBlock.style.display=this.isDropdownOpen?"inline-block":"none"},D.prototype.showDropdown=function(){this.isDropdownOpen=!0,this.toggleDropdown()},D.prototype.hideDropdown=function(){this.isDropdownOpen=!1,this.toggleDropdown()},D}(he),Oe=function(){function B(D,P){this.GRIP_SIZE=10,this.color=D,this.fillColor=P,this.visual=ne.createGroup(),this.visual.appendChild(ne.createCircle(1.5*this.GRIP_SIZE,[["fill","transparent"]])),this.visual.appendChild(ne.createCircle(this.GRIP_SIZE,[["fill",this.fillColor],["fill-opacity","0.9"],["stroke",this.color],["stroke-width","2"],["stroke-opacity","0.7"]]))}return B.prototype.ownsTarget=function(D){return D===this.visual||D===this.visual.childNodes[0]||D===this.visual.childNodes[1]},B.prototype.setCenter=function(D,P){this.visual.childNodes.forEach(function(F){return ne.setAttributes(F,[["cx",D.toString()],["cy",P.toString()]])})},B}(),Re=function(){function B(D,P,F,W){this.isMoving=!1,this._isGridVisible=!0,this.numberOfGridLines=2,this.horizontalGridLines=[],this.verticalGridLines=[],this._zoomFactor=1,this.cropRectChanged=!1,this.canvasWidth=D,this.canvasHeight=P,this.margin=F,this.container=W,this.attachEvents=this.attachEvents.bind(this),this.onPointerDown=this.onPointerDown.bind(this),this.onPointerMove=this.onPointerMove.bind(this),this.onPointerUp=this.onPointerUp.bind(this),this.resize=this.resize.bind(this),this.adjustCropRect=this.adjustCropRect.bind(this),this.scaleCanvas=this.scaleCanvas.bind(this),this.getRescaledRect=this.getRescaledRect.bind(this)}return Object.defineProperty(B.prototype,"aspectRatio",{get:function(){return this._aspectRatio},set:function(D){this._aspectRatio=D,this.adjustCropRect(),this.setCropRectangle(this.cropRect)},enumerable:!1,configurable:!0}),Object.defineProperty(B.prototype,"isGridVisible",{get:function(){return this._isGridVisible},set:function(D){this._isGridVisible=D,this.gridContainer&&ne.setAttributes(this.gridContainer,[["display",this._isGridVisible?"":"none"]])},enumerable:!1,configurable:!0}),Object.defineProperty(B.prototype,"zoomFactor",{get:function(){return this._zoomFactor},set:function(D){this._zoomFactor=D,this.setCropRectangle(this.cropRect)},enumerable:!1,configurable:!0}),B.prototype.open=function(){var D=this;this.cropShadeElement=ne.createPath("M0,0Z",[["fill",this.cropShadeColor],["fill-opacity","0.8"]]),this.container.appendChild(this.cropShadeElement),this.gridContainer=ne.createGroup([["display",this.isGridVisible?"":"none"]]),this.container.appendChild(this.gridContainer);for(var P=0;Pthis.canvasHeight/this.canvasWidth?this.margin:this.margin+this.canvasHeight/2-P.height/2),ne.setAttributes(this.cropRectElement,[["x",P.x.toString()],["y",P.y.toString()],["width",P.width.toString()],["height",P.height.toString()]]);var F=P.height/(this.numberOfGridLines+1);this.horizontalGridLines.forEach(function(I,U){var j=P.y+F*(U+1);ne.setAttributes(I,[["x1",""+P.x],["y1",""+j],["x2",""+(P.x+P.width)],["y2",""+j]])});var W=P.width/(this.numberOfGridLines+1);this.verticalGridLines.forEach(function(I,U){var j=P.x+W*(U+1);ne.setAttributes(I,[["x1",""+j],["y1",""+P.y],["x2",""+j],["y2",""+(P.y+P.height)]])}),ne.setAttributes(this.cropShadeElement,[["d",ne.getHollowRectanglePath(0,0,this.canvasWidth+2*this.margin,this.canvasHeight+2*this.margin,P.x,P.y,P.width,P.height)]]),this.topLeftGrip.setCenter(P.x,P.y),this.topRightGrip.setCenter(P.x+P.width,P.y),this.bottomLeftGrip.setCenter(P.x,P.y+P.height),this.bottomRightGrip.setCenter(P.x+P.width,P.y+P.height),this.cropRectChanged&&this.onCropChange&&(this.cropRectChanged=!1,this.onCropChange(this.cropRect)),this.cropRectChanged=!1},B.prototype.attachEvents=function(){this.container.style.touchAction="none",this.container.addEventListener("pointerdown",this.onPointerDown),this.container.addEventListener("pointermove",this.onPointerMove),this.container.addEventListener("pointerup",this.onPointerUp)},B.prototype.clientToLocalCoordinates=function(D,P){var F=this.container.getBoundingClientRect();return{x:D-F.left+this.margin,y:P-F.top+this.margin}},B.prototype.onPointerDown=function(D){this.container.setPointerCapture(D.pointerId),this.previousPoint=this.clientToLocalCoordinates(D.clientX,D.clientY),this.cropRectElement===D.target?this.isMoving=!0:this.topLeftGrip.ownsTarget(D.target)?this.activeGrip=this.topLeftGrip:this.bottomLeftGrip.ownsTarget(D.target)?this.activeGrip=this.bottomLeftGrip:this.topRightGrip.ownsTarget(D.target)?this.activeGrip=this.topRightGrip:this.bottomRightGrip.ownsTarget(D.target)&&(this.activeGrip=this.bottomRightGrip)},B.prototype.onPointerMove=function(D){if(this.isMoving)this.move(this.clientToLocalCoordinates(D.clientX,D.clientY));else if(this.activeGrip){var P=this.clientToLocalCoordinates(D.clientX,D.clientY);this.resize(P)}D.preventDefault()},B.prototype.onPointerUp=function(D){this.activeGrip=void 0,this.isMoving=!1,this.container.releasePointerCapture(D.pointerId)},B.prototype.move=function(D){var P=D.x-this.previousPoint.x,F=D.y-this.previousPoint.y;this.zoomFactor!==1&&(P=-P/this.zoomFactor,F=-F/this.zoomFactor),this.cropRect.x=Math.min(Math.max(this.margin,this.cropRect.x+P),this.canvasWidth-this.cropRect.width+this.margin),this.cropRect.y=Math.min(Math.max(this.margin,this.cropRect.y+F),this.canvasHeight-this.cropRect.height+this.margin),this.onCropChange?(this.cropRectChanged=!0,this.onCropChange(this.cropRect)):this.setCropRectangle(this.cropRect),this.previousPoint=D},B.prototype.resize=function(D){var P=Object.assign({},this.cropRect),F=D.x-this.previousPoint.x,W=D.y-this.previousPoint.y;switch(this.activeGrip){case this.bottomLeftGrip:case this.topLeftGrip:P.x+Fthis.canvasWidth*this.zoomFactor&&(F=this.canvasWidth*this.zoomFactor-P.width),P.width+=F}switch(this.activeGrip){case this.topLeftGrip:case this.topRightGrip:this.aspectRatio?(P.y=this.cropRect.y-(this.activeGrip===this.topLeftGrip?-1:1)*this.aspectRatio.getVerticalLength(F),P.height=this.aspectRatio.getVerticalLength(P.width)):(P.y+=W,P.height=this.cropRect.y+this.cropRect.height-P.y);break;case this.bottomLeftGrip:case this.bottomRightGrip:this.aspectRatio?P.height=this.aspectRatio.getVerticalLength(P.width):P.height+=W}P.width<10&&(P.x=this.cropRect.x,P.width=10),P.height<10&&(P.y=this.cropRect.y,P.height=10),this.previousPoint=D,P.x>=this.margin&&P.y>=this.margin&&P.x-this.margin+P.width<=this.canvasWidth&&P.y-this.margin+P.height<=this.canvasHeight&&(this.cropRect=P,this.onCropChange?(this.cropRectChanged=!0,this.onCropChange(this.cropRect)):this.setCropRectangle(this.cropRect))},B.prototype.adjustCropRect=function(){if(this.aspectRatio&&Math.round(this.cropRect.height)!==Math.round(this.aspectRatio.getVerticalLength(this.cropRect.width))){var D=this.cropRect.x+this.cropRect.width/2,P=this.cropRect.y+this.cropRect.height/2,F=this.aspectRatio.getHorizontalLength(this.cropRect.height),W=this.aspectRatio.getVerticalLength(this.cropRect.width);F/this.canvasWidththis.canvasWidth&&(this.cropRect.height/=this.cropRect.width/this.canvasWidth,this.cropRect.width=this.canvasWidth),this.cropRect.height>this.canvasHeight&&(this.cropRect.width/=this.cropRect.height/this.canvasHeight,this.cropRect.height=this.canvasHeight),this.cropRect.x=D-this.cropRect.width/2,this.cropRect.y=P-this.cropRect.height/2,this.cropRect.x+this.cropRect.width>this.margin+this.canvasWidth&&(this.cropRect.x=this.margin+this.canvasWidth-this.cropRect.width),this.cropRect.y+this.cropRect.height>this.margin+this.canvasHeight&&(this.cropRect.y=this.margin+this.canvasHeight-this.cropRect.height),this.cropRect.x=Math.max(this.cropRect.x,this.margin),this.cropRect.y=Math.max(this.cropRect.y,this.margin)}},B.prototype.getRescaledRect=function(D,P,F,W,I,U){var j=F/D,G=W/P;return{x:(I.x-U)*j+U,y:(I.y-U)*G+U,width:I.width*j,height:I.height*G}},B.prototype.scaleCanvas=function(D,P){var F=this.getRescaledRect(this.canvasWidth,this.canvasHeight,D,P,this.cropRect,this.margin);this.canvasWidth=D,this.canvasHeight=P,this.onCropChange&&this.onCropChange(F),this.setCropRectangle(F)},B}(),fe=function(){function B(D){this._angle=0,this.isDragging=!1,this.width=401,this.height=24,this.title=D,this.uiContainer=document.createElement("div"),this.getUI=this.getUI.bind(this),this.onPointerDown=this.onPointerDown.bind(this),this.onPointerMove=this.onPointerMove.bind(this),this.onPointerUp=this.onPointerUp.bind(this),this.setAngleLabel=this.setAngleLabel.bind(this),this.positionScaleShape=this.positionScaleShape.bind(this)}return Object.defineProperty(B.prototype,"angle",{get:function(){return this._angle},set:function(D){this._angle=D,this.setAngleLabel(),this.positionScaleShape()},enumerable:!1,configurable:!0}),B.prototype.getUI=function(){return this.controlContainer=document.createElement("div"),this.controlContainer.title=this.title,this.controlContainer.className=this.className+" "+this.colorsClassName,this.controlContainer.appendChild(this.getVisual()),this.controlContainer.addEventListener("pointerdown",this.onPointerDown),this.controlContainer.addEventListener("pointermove",this.onPointerMove),this.controlContainer.addEventListener("pointerup",this.onPointerUp),this.uiContainer.appendChild(this.controlContainer),this.uiContainer.style.display="inline-block",this.uiContainer.style.touchAction="none",this.setAngleLabel(),this.positionScaleShape(),this.uiContainer},B.prototype.onPointerDown=function(D){this.controlContainer.setPointerCapture(D.pointerId),this.isDragging=!0,this.previousPoint={x:D.clientX,y:D.clientY}},B.prototype.onPointerMove=function(D){this.isDragging&&(this.onAngleChange&&this.onAngleChange((D.clientX-this.previousPoint.x)/5),this.previousPoint.x=D.clientX)},B.prototype.onPointerUp=function(D){this.isDragging&&this.onAngleChange&&this.onAngleChange((D.clientX-this.previousPoint.x)/5),this.isDragging=!1,this.controlContainer.releasePointerCapture(D.pointerId)},B.prototype.setAngleLabel=function(){if(this.angleLabelText){this.angleLabelText.innerHTML=""+Math.round(this._angle);var D=this.angleLabelText.getBBox();ne.setAttributes(this.angleLabelElement,[["x",((this.width-D.width)/2).toString()],["y",(this.height/2).toString()]])}},B.prototype.positionScaleShape=function(){if(this.scaleShape){var D=this.scaleShape.transform.baseVal.getItem(0);D.setTranslate(this._angle%5*5-25,0),this.scaleShape.transform.baseVal.replaceItem(D,0)}},B.prototype.getVisual=function(){var D=document.createElementNS("http://www.w3.org/2000/svg","svg");D.setAttribute("xmlns","http://www.w3.org/2000/svg"),D.setAttribute("width",this.width+"px"),D.setAttribute("height",this.height+"px"),D.setAttribute("viewBox","0 0 "+this.width+" "+this.height),D.style.flexShrink="0",document.body.appendChild(D);for(var P="M0,"+(this.height-1)+" v"+-this.height/3+"h1v"+this.height/3,F=1;F<=this.width/5+10;F++){var W=F%5==0?this.height/3:this.height/6;P+="h4v"+-W+"h1v"+W}P+="v1H0Z",this.scaleShape=ne.createPath(P);var I=ne.createTransform();this.scaleShape.transform.baseVal.appendItem(I),D.appendChild(this.scaleShape),this.angleLabelElement=ne.createText([["x","0"],["y","0"],["font-size","10px"],["font-family","monospace"]]),this.angleLabelText=ne.createTSpan(""),this.angleLabelElement.appendChild(this.angleLabelText);var U=ne.createTSpan("");return U.innerHTML="°",this.angleLabelElement.appendChild(U),D.appendChild(this.angleLabelElement),document.body.removeChild(D),D},B}(),_e=function(){function B(){this.naturalSize=!1,this.imageType="image/png"}return B.prototype.rasterize=function(D,P,F,W,I,U,j){var G=this;return new Promise(function($){var Y=document.createElement("canvas");Y.width=D.width.baseVal.value-2*W,Y.height=D.height.baseVal.value-2*W;var q=1,Se=1;G.naturalSize===!0?(q=P.naturalWidth/(D.width.baseVal.value-2*W)/U,Se=P.naturalHeight/(D.height.baseVal.value-2*W)/j,Y.width=P.naturalWidth/U,Y.height=P.naturalHeight/j):G.width!==void 0&&G.height!==void 0&&(q=G.width/F.width,Se=G.height/F.height,Y.width*=q,Y.height*=Se);var we=Y.getContext("2d");we.translate(Y.width/2,Y.height/2),we.rotate(I*Math.PI/180),we.scale(U,j),we.translate(-Y.width/2,-Y.height/2),we.drawImage(P,0,0,Y.width,Y.height);var xe=document.createElement("canvas");xe.width=F.width*q,xe.height=F.height*Se,xe.getContext("2d").putImageData(we.getImageData((F.x-W)*q,(F.y-W)*Se,F.width*q,F.height*Se),0,0),$(xe.toDataURL(G.imageType,G.imageQuality))})},B}(),je=function(){function B(D){this._zoomToCropEnabled=!0,this.zoomFactor=1,this.flippedHorizontally=!1,this.flippedVertically=!1,this._isGridVisible=!0,this._gridLines=2,this._rotationAngle=0,this.scaleFactor=1,this.renderEventListeners=[],this.closeEventListeners=[],this._isOpen=!1,this.CANVAS_MARGIN=20,this.renderAtNaturalSize=!1,this.renderImageType="image/png",this.displayMode="inline",this.popupMargin=30,this.toolbarHeight=40,this.aspectRatios=[{horizontal:0,vertical:0},{horizontal:4,vertical:3},{horizontal:3,vertical:2},{horizontal:16,vertical:9},{horizontal:1,vertical:1},{horizontal:3,vertical:4},{horizontal:2,vertical:3},{horizontal:9,vertical:16}],this._instanceNo=B.instanceCounter++,this.styles=new Te(this.instanceNo),this.target=D,this.targetRoot=document.body,this.open=this.open.bind(this),this.setTopLeft=this.setTopLeft.bind(this),this.overrideOverflow=this.overrideOverflow.bind(this),this.restoreOverflow=this.restoreOverflow.bind(this),this.close=this.close.bind(this),this.closeUI=this.closeUI.bind(this),this.addCloseEventListener=this.addCloseEventListener.bind(this),this.removeCloseEventListener=this.removeCloseEventListener.bind(this),this.addRenderEventListener=this.addRenderEventListener.bind(this),this.removeRenderEventListener=this.removeRenderEventListener.bind(this),this.clientToLocalCoordinates=this.clientToLocalCoordinates.bind(this),this.onWindowResize=this.onWindowResize.bind(this),this.setWindowHeight=this.setWindowHeight.bind(this),this.rotateBy=this.rotateBy.bind(this),this.applyRotation=this.applyRotation.bind(this),this.cropRectChanged=this.cropRectChanged.bind(this),this.zoomToCrop=this.zoomToCrop.bind(this),this.unzoomFromCrop=this.unzoomFromCrop.bind(this),this.rotateLeftButtonClicked=this.rotateLeftButtonClicked.bind(this),this.rotateRightButtonClicked=this.rotateRightButtonClicked.bind(this),this.flipHorizontallyButtonClicked=this.flipHorizontallyButtonClicked.bind(this),this.flipVerticallyButtonClicked=this.flipVerticallyButtonClicked.bind(this),this.applyFlip=this.applyFlip.bind(this),this.startRenderAndClose=this.startRenderAndClose.bind(this),this.render=this.render.bind(this),this.onPopupResize=this.onPopupResize.bind(this),this.applyAspectRatio=this.applyAspectRatio.bind(this)}return Object.defineProperty(B.prototype,"instanceNo",{get:function(){return this._instanceNo},enumerable:!1,configurable:!0}),Object.defineProperty(B.prototype,"zoomToCropEnabled",{get:function(){return this._zoomToCropEnabled},set:function(D){this._zoomToCropEnabled=D,D?this.zoomToCrop():this.unzoomFromCrop()},enumerable:!1,configurable:!0}),Object.defineProperty(B.prototype,"isGridVisible",{get:function(){return this._isGridVisible},set:function(D){this._isGridVisible=D,this.cropLayer&&(this.cropLayer.isGridVisible=this._isGridVisible)},enumerable:!1,configurable:!0}),Object.defineProperty(B.prototype,"gridLines",{get:function(){return this._gridLines},set:function(D){this._gridLines=D,this.cropLayer&&(this.cropLayer.numberOfGridLines=this._gridLines)},enumerable:!1,configurable:!0}),Object.defineProperty(B.prototype,"rotationAngle",{get:function(){return this._rotationAngle},set:function(D){this._rotationAngle=D,this.straightener&&(this.straightener.angle=this._rotationAngle)},enumerable:!1,configurable:!0}),Object.defineProperty(B.prototype,"paddedImageWidth",{get:function(){return this.imageWidth+2*this.CANVAS_MARGIN},enumerable:!1,configurable:!0}),Object.defineProperty(B.prototype,"paddedImageHeight",{get:function(){return this.imageHeight+2*this.CANVAS_MARGIN},enumerable:!1,configurable:!0}),Object.defineProperty(B.prototype,"isOpen",{get:function(){return this._isOpen},enumerable:!1,configurable:!0}),Object.defineProperty(B.prototype,"aspectRatio",{get:function(){var D;return(D=this._aspectRatio)!==null&&D!==void 0?D:this.aspectRatios[0]},set:function(D){this._aspectRatio=D},enumerable:!1,configurable:!0}),B.prototype.open=function(){this.imageWidth=Math.round(this.target.clientWidth),this.imageHeight=Math.round(this.target.clientHeight),this.setupResizeObserver(),this.initCropCanvas(),this.setEditingTarget(),this.setTopLeft(),this.initCropLayer(),this.attachEvents(),this.applyAspectRatio(),this.displayMode==="popup"&&this.onPopupResize(),this._isOpen=!0},B.prototype.show=function(){this.showUI(),this.open()},B.prototype.close=function(D){D===void 0&&(D=!1),this.isOpen&&(this.coverDiv&&this.closeUI(),this.targetObserver&&this.targetObserver.unobserve(this.target),this.displayMode==="popup"&&window.removeEventListener("resize",this.setWindowHeight),D||this.closeEventListeners.forEach(function(P){return P()}),this._isOpen=!1)},B.prototype.addRenderEventListener=function(D){this.renderEventListeners.push(D)},B.prototype.removeRenderEventListener=function(D){this.renderEventListeners.indexOf(D)>-1&&this.renderEventListeners.splice(this.renderEventListeners.indexOf(D),1)},B.prototype.addCloseEventListener=function(D){this.closeEventListeners.push(D)},B.prototype.removeCloseEventListener=function(D){this.closeEventListeners.indexOf(D)>-1&&this.closeEventListeners.splice(this.closeEventListeners.indexOf(D),1)},B.prototype.setupResizeObserver=function(){var D=this;this.displayMode==="inline"?window.ResizeObserver&&(this.targetObserver=new ResizeObserver(function(){D.resize(D.target.clientWidth,D.target.clientHeight)}),this.targetObserver.observe(this.target)):this.displayMode==="popup"&&(window.ResizeObserver&&(this.targetObserver=new ResizeObserver(this.onPopupResize),this.targetObserver.observe(this.contentDiv)),window.addEventListener("resize",this.setWindowHeight))},B.prototype.onPopupResize=function(){if(this.contentDiv.clientWidth>0&&this.contentDiv.clientHeight>0){var D=1*this.target.clientWidth/this.target.clientHeight,P=this.contentDiv.clientWidth/D>this.contentDiv.clientHeight?(this.contentDiv.clientHeight-2*this.CANVAS_MARGIN)*D:this.contentDiv.clientWidth-2*this.CANVAS_MARGIN,F=P+2*this.CANVAS_MARGIND+this.CANVAS_MARGIN?this.target.offsetTop-(D+this.CANVAS_MARGIN):0;this.coverDiv.style.top=P+"px",this.coverDiv.style.left=(this.target.offsetLeft>this.CANVAS_MARGIN?this.target.offsetLeft-this.CANVAS_MARGIN:0)+"px",this.coverDiv.style.width=this.target.offsetWidth+this.CANVAS_MARGIN+"px",this.coverDiv.style.zIndex=this.styles.settings.zIndex!==void 0?this.styles.settings.zIndex:"5";break;case"popup":this.coverDiv.style.position="absolute",this.coverDiv.style.top="0px",this.coverDiv.style.left="0px",this.coverDiv.style.width="100vw",this.coverDiv.style.height=window.innerHeight+"px",this.coverDiv.style.backgroundColor="rgba(0, 0, 0, 0.75)",this.coverDiv.style.zIndex=this.styles.settings.zIndex!==void 0?this.styles.settings.zIndex:"1000",this.coverDiv.style.display="flex"}this.targetRoot.appendChild(this.coverDiv),this.uiDiv=document.createElement("div"),this.uiDiv.style.display="flex",this.uiDiv.style.flexDirection="column",this.uiDiv.style.flexGrow="2",this.uiDiv.style.margin=this.displayMode==="popup"?this.popupMargin+"px":"0px",this.uiDiv.style.border="0px",this.coverDiv.appendChild(this.uiDiv),this.addToolbars(),this.uiDiv.appendChild(this.topToolbar.getUI()),this.contentDiv=document.createElement("div"),this.contentDiv.style.display="flex",this.contentDiv.style.alignItems="center",this.contentDiv.style.flexDirection="row",this.contentDiv.style.flexGrow="2",this.contentDiv.style.flexShrink="1",this.contentDiv.style.overflow="hidden",this.contentDiv.style.backgroundColor=this.styles.settings.canvasBackgroundColor,this.displayMode==="popup"&&(this.contentDiv.style.maxHeight="calc(100vh - "+(2*this.popupMargin+2*this.toolbarHeight)+"px)",this.contentDiv.style.maxWidth="calc(100vw - "+2*this.popupMargin+"px)"),this.uiDiv.appendChild(this.contentDiv),this.editorCanvas=document.createElement("div"),this.editorCanvas.style.flexGrow="2",this.editorCanvas.style.flexShrink="1",this.editorCanvas.style.position="relative",this.editorCanvas.style.overflow="hidden",this.editorCanvas.style.display="flex",this.displayMode==="popup"&&(this.editorCanvas.style.alignItems="center",this.editorCanvas.style.justifyContent="center"),this.editorCanvas.style.pointerEvents="none",this.contentDiv.appendChild(this.editorCanvas),this.uiDiv.appendChild(this.bottomToolbar.getUI()),this.straightener.angle=this.rotationAngle},B.prototype.addToolbars=function(){this.addTopToolbar(),this.addBottomToolbar()},B.prototype.addTopToolbar=function(){var D=this;this.topToolbar=new Ae,this.topToolbar.display=this.styles.settings.hideTopToolbar?"none":"",this.topToolbar.className=this.toolbarStyleClass.name,this.topToolbar.colorsClassName=this.styles.settings.toolbarStyleColorsClassName?this.styles.settings.toolbarStyleColorsClassName:this.toolbarStyleColorsClass.name,this.topToolbar.fadeInClassName=this.styles.fadeInAnimationClassName,this.topToolbar.blockClassName=this.toolbarBlockStyleClass.name,this.topToolbar.buttonClassName=this.toolbarButtonStyleClass.name,this.topToolbar.buttonColorsClassName=this.styles.settings.toolbarButtonStyleColorsClassName?this.styles.settings.toolbarButtonStyleColorsClassName:this.toolbarButtonStyleColorsClass.name,this.topToolbar.buttonActiveColorsClassName=this.styles.settings.toolbarActiveButtonStyleColorsClassName?this.styles.settings.toolbarActiveButtonStyleColorsClassName:this.toolbarActiveButtonStyleColorsClass.name;var P=new se;P.minWidth=3*this.toolbarHeight+"px",this.topToolbar.addButtonBlock(P);var F=[];this.aspectRatios.forEach(function(Se){var we=new he(me.getIcon(Se.horizontal,Se.vertical),Se.horizontal===0&&Se.vertical===0?"FREE":Se.horizontal+":"+Se.vertical);we.onClick=function(){return D.ratioButtonClicked(Se)},F.push(we)}),this.aspectRatioButton=new ue(me.getIcon(0,0),"Aspect ratio",F),this.aspectRatioButton.dropdownClassName=this.toolbarDropdownStyleClass.name,this.aspectRatioButton.dropdownColorsClassName=this.styles.settings.toolbarDropdownStyleColorsClassName?this.styles.settings.toolbarDropdownStyleColorsClassName:this.toolbarDropdownStyleColorsClass.name,P.addButton(this.aspectRatioButton),this.aspectRatios.length<2&&this.aspectRatioButton.hide();var W=new he('',"Toggle grid");W.isActive=this.isGridVisible,W.onClick=function(){D.isGridVisible=!D.isGridVisible,W.isActive=D.isGridVisible},P.addButton(W);var I=new he('',"Zoom to selection");if(I.isActive=this.zoomToCropEnabled,I.onClick=function(){D.zoomToCropEnabled=!D.zoomToCropEnabled,I.isActive=D.zoomToCropEnabled},P.addButton(I),!Z.isLicensed){var U=new ge;this.topToolbar.addElementBlock(U);var j=document.createElement("div");j.className=this.topToolbar.buttonClassName+" "+this.topToolbar.buttonColorsClassName;var G=document.createElement("a");G.style.color="currentColor",G.href="https://markerjs.com/products/cropro",G.target="_blank",G.innerHTML='',j.appendChild(G),U.addElement(j)}var $=new se;$.minWidth=3*this.toolbarHeight+"px",$.contentAlign="end",this.topToolbar.addButtonBlock($);var Y=new he('',"OK");Y.onClick=this.startRenderAndClose,$.addButton(Y),this.styles.settings.toolbarOkButtonStyleColorsClassName&&(Y.colorsClassName=this.styles.settings.toolbarOkButtonStyleColorsClassName);var q=new he('',"Close");q.onClick=this.close,$.addButton(q),this.styles.settings.toolbarCloseButtonStyleColorsClassName&&(q.colorsClassName=this.styles.settings.toolbarCloseButtonStyleColorsClassName)},B.prototype.addBottomToolbar=function(){var D=this;this.bottomToolbar=new Ae,this.bottomToolbar.display=this.styles.settings.hideBottomToolbar?"none":"",this.bottomToolbar.className=this.toolbarStyleClass.name,this.bottomToolbar.colorsClassName=this.styles.settings.toolbarStyleColorsClassName?this.styles.settings.toolbarStyleColorsClassName:this.toolbarStyleColorsClass.name,this.bottomToolbar.fadeInClassName=this.styles.fadeInAnimationClassName,this.bottomToolbar.blockClassName=this.toolbarBlockStyleClass.name,this.bottomToolbar.buttonClassName=this.toolbarButtonStyleClass.name,this.bottomToolbar.buttonColorsClassName=this.styles.settings.toolbarButtonStyleColorsClassName?this.styles.settings.toolbarButtonStyleColorsClassName:this.toolbarButtonStyleColorsClass.name,this.bottomToolbar.buttonActiveColorsClassName=this.styles.settings.toolbarActiveButtonStyleColorsClassName?this.styles.settings.toolbarActiveButtonStyleColorsClassName:this.toolbarActiveButtonStyleColorsClass.name;var P=new se;P.minWidth=2*this.toolbarHeight+"px",this.bottomToolbar.addButtonBlock(P);var F=new he('',"Rotate left");F.onClick=this.rotateLeftButtonClicked,P.addButton(F);var W=new he('',"Rotate right");W.onClick=this.rotateRightButtonClicked,P.addButton(W);var I=new ge;I.className=this.toolbarStraightenerBlockStyleClass.name,this.bottomToolbar.addElementBlock(I),this.straightener=new fe("Straighten"),this.straightener.className=this.toolbarStraightenerStyleClass.name,this.straightener.colorsClassName=this.styles.settings.toolbarStraightenerColorsClassName?this.styles.settings.toolbarStraightenerColorsClassName:this.toolbarStraightenerStyleColorsClass.name,this.straightener.onAngleChange=function($){D.rotateBy($),D.straightener.angle=D.rotationAngle},I.addElement(this.straightener.getUI());var U=new se;U.minWidth=2*this.toolbarHeight+"px",U.contentAlign="end",this.bottomToolbar.addButtonBlock(U);var j=new he('',"Flip horizontal");j.onClick=this.flipHorizontallyButtonClicked,U.addButton(j);var G=new he('',"Flip vertical");G.onClick=this.flipVerticallyButtonClicked,U.addButton(G)},B.prototype.ratioButtonClicked=function(D){this.aspectRatio=D,this.applyAspectRatio(),this.aspectRatioButton.hideDropdown()},B.prototype.applyAspectRatio=function(){this.setCropLayerAspectRatio(),this.aspectRatioButton.icon=me.getIcon(this.aspectRatio.horizontal,this.aspectRatio.vertical)},B.prototype.setCropLayerAspectRatio=function(){this.cropLayer&&(this.aspectRatio&&this.aspectRatio.horizontal!==0&&this.aspectRatio.vertical!==0?this.cropLayer.aspectRatio=new ye(this.aspectRatio.horizontal,this.aspectRatio.vertical):this.cropLayer.aspectRatio=void 0)},B.prototype.closeUI=function(){this.displayMode==="popup"&&this.restoreOverflow(),this.targetRoot.removeChild(this.coverDiv)},B.prototype.getState=function(){return{width:this.imageWidth,height:this.imageHeight,rotationAngle:this.rotationAngle,flippedHorizontally:this.flippedHorizontally,flippedVertically:this.flippedVertically,cropRect:Object.assign({},this.cropRect)}},B.prototype.restoreState=function(D){if(D){var P=this.cropLayer.getRescaledRect(D.width,D.height,this.imageWidth,this.imageHeight,D.cropRect,this.CANVAS_MARGIN);this.cropLayer.setCropRectangle(P),this.cropRectChanged(P),this.flippedHorizontally=D.flippedHorizontally,this.flippedVertically=D.flippedVertically,this.applyFlip(),this.rotationAngle=D.rotationAngle,this.applyRotation()}},B.prototype.clientToLocalCoordinates=function(D,P){var F=this.cropImage.getBoundingClientRect();return{x:D-F.left,y:P-F.top}},B.prototype.onWindowResize=function(){this.positionUI()},B.prototype.positionUI=function(){switch(this.setTopLeft(),this.displayMode){case"inline":var D=this.target.offsetTop>this.toolbarHeight?this.target.offsetTop-this.toolbarHeight:0;this.coverDiv.style.top=D+"px",this.coverDiv.style.left=this.target.offsetLeft.toString()+"px";break;case"popup":this.coverDiv.style.top="0px",this.coverDiv.style.left="0px",this.coverDiv.style.width="100vw",this.coverDiv.style.height=this.windowHeight+"px",this.contentDiv.style.maxHeight="calc(100vh - "+(2*this.popupMargin+2*this.toolbarHeight)+"px)"}this.positionCropImage()},B.prototype.rotateLeftButtonClicked=function(){var D=this.rotationAngle-90;this.rotationAngle%90!=0&&(D+=this.rotationAngle>=0?90-this.rotationAngle%90:-this.rotationAngle%90),this.rotateTo(D)},B.prototype.rotateRightButtonClicked=function(){var D=this.rotationAngle+90;this.rotationAngle%90!=0&&(D-=this.rotationAngle>=0?this.rotationAngle%90:90+this.rotationAngle%90),this.rotateTo(D)},B.prototype.rotateTo=function(D){D=(D=D>180?D-360:D)<=-180?D+360:D,this.rotationAngle=D,this.applyRotation()},B.prototype.rotateBy=function(D){this.rotateTo((this.rotationAngle+D)%360)},B.prototype.applyRotation=function(){var D=this.zoomToCropEnabled;this.zoomToCropEnabled=!1,this.editingTargetRotationScaleContainer.style.transformOrigin=this.imageWidth/2+"px "+this.imageHeight/2+"px",this.editingTargetRotationScaleContainer.style.transform="scale(1)";var P=this.editingTargetRotationContainer.transform.baseVal.getItem(0);P.setRotate(this.rotationAngle,this.imageWidth/2,this.imageHeight/2),this.editingTargetRotationContainer.transform.baseVal.replaceItem(P,0);var F=this.editingTarget.getBoundingClientRect();this.scaleFactor=Math.min(this.imageWidth/F.width,this.imageHeight/F.height),this.editingTargetRotationScaleContainer.style.transform="scale("+this.scaleFactor+")",this.zoomToCropEnabled=D},B.prototype.flipHorizontallyButtonClicked=function(){this.flippedHorizontally=!this.flippedHorizontally,this.applyFlip()},B.prototype.flipVerticallyButtonClicked=function(){this.flippedVertically=!this.flippedVertically,this.applyFlip()},B.prototype.applyFlip=function(){this.editingTarget.style.transform="scale("+(this.flippedHorizontally?-1:1)+","+(this.flippedVertically?-1:1)+")"},B.prototype.startRenderAndClose=function(){return le(this,void 0,void 0,function(){var D,P;return Q(this,function(F){switch(F.label){case 0:return[4,this.render()];case 1:return D=F.sent(),P=this.getState(),this.renderEventListeners.forEach(function(W){return W(D,P)}),this.close(!0),[2]}})})},B.prototype.render=function(){return le(this,void 0,void 0,function(){var D;return Q(this,function(P){switch(P.label){case 0:return(D=new _e).naturalSize=this.renderAtNaturalSize,D.imageType=this.renderImageType,D.imageQuality=this.renderImageQuality,D.width=this.renderWidth,D.height=this.renderHeight,this.unzoomFromCrop(),ne.setAttributes(this.cropLayerContainer,[["display","none"]]),[4,D.rasterize(this.cropImage,this.target,{x:this.cropRect.x,y:this.cropRect.y,width:this.cropRect.width,height:this.cropRect.height},this.CANVAS_MARGIN,this.rotationAngle,this.scaleFactor*(this.flippedHorizontally?-1:1),this.scaleFactor*(this.flippedVertically?-1:1))];case 1:return P.sent(),[4,D.rasterize(this.cropImage,this.target,{x:this.cropRect.x,y:this.cropRect.y,width:this.cropRect.width,height:this.cropRect.height},this.CANVAS_MARGIN,this.rotationAngle,this.scaleFactor*(this.flippedHorizontally?-1:1),this.scaleFactor*(this.flippedVertically?-1:1))];case 2:return[2,P.sent()]}})})},B.prototype.addStyles=function(){this.toolbarStyleClass=this.styles.addClass(new Ce("toolbar",`
width: `+(this.displayMode==="inline"?"100%":"calc(100vw - "+2*this.popupMargin+"px)")+`;
flex-shrink: 0;
display: flex;
flex-direction: row;
justify-content: space-between;
height: `+this.toolbarHeight+`px;
box-sizing: content-box;
overflow: hidden;
line-height: 0px;
`)),this.toolbarStyleColorsClass=this.styles.addClass(new Ce("toolbar_colors",`
background-color: `+this.styles.settings.toolbarBackgroundColor+`;
`)),this.toolbarBlockStyleClass=this.styles.addClass(new Ce("toolbar-block",`
display: flex;
align-items: center;
box-sizing: content-box;
`));var D=this.toolbarHeight/4;this.toolbarButtonStyleClass=this.styles.addClass(new Ce("toolbar_button",`
display: inline-block;
width: `+(this.toolbarHeight-2*D)+`px;
height: `+(this.toolbarHeight-2*D)+`px;
padding: `+D+`px;
cursor: default;
user-select: none;
box-sizing: content-box;
`)),this.toolbarButtonStyleColorsClass=this.styles.addClass(new Ce("toolbar_button_colors",`
color: `+this.styles.settings.toolbarColor+`;
fill: currentColor;
`)),this.toolbarActiveButtonStyleColorsClass=this.styles.addClass(new Ce("toolbar_active_button",`
color: `+this.styles.settings.toolbarColor+`;
fill: currentColor;
background-color: `+this.styles.settings.toolbarBackgroundActiveColor+`
`)),this.styles.addRule(new Ee("."+this.toolbarButtonStyleClass.name+" svg",`
height: `+this.toolbarHeight/2+`px;
`)),this.styles.addRule(new Ee("."+this.toolbarButtonStyleColorsClass.name+":hover",`
background-color: `+this.styles.settings.toolbarBackgroundHoverColor+`
`)),this.toolbarDropdownStyleClass=this.styles.addClass(new Ce("toolbar_dropdown",`
position: absolute;
max-width: `+4*this.toolbarHeight+`px;
z-index: 20;
white-space: normal;
box-sizing: content-box;
box-shadow: 3px 3px rgba(33, 33, 33, 0.1);
margin: `+(this.displayMode==="inline"?"0":this.popupMargin)+`px;
line-height: 0px;
`)),this.toolbarDropdownStyleColorsClass=this.styles.addClass(new Ce("toolbar_dropdown_colors",`
background-color: `+this.styles.settings.toolbarBackgroundColor+`;
`)),this.toolbarStraightenerBlockStyleClass=this.styles.addClass(new Ce("toolbar_straightener_block",`
display: flex;
overflow: hidden;
justify-content: center;
-webkit-mask-image: linear-gradient(90deg, rgba(0,0,0,0) 0%, rgba(0,0,0,1) 30%, rgba(0,0,0,1) 70%, rgba(0,0,0,0) 100%);
`)),this.toolbarStraightenerStyleClass=this.styles.addClass(new Ce("toolbar_straightener",`
display: flex;
overflow: hidden;
justify-content: center;
height: `+(this.toolbarHeight-2*D)+`px;
padding: `+D+`px;
cursor: default;
user-select: none;
box-sizing: content-box;
`)),this.toolbarStraightenerStyleColorsClass=this.styles.addClass(new Ce("toolbar_straightener_colors",`
color: `+this.styles.settings.toolbarColor+`;
fill: currentColor;
`))},B.instanceCounter=0,B}(),Ie=V("8hTe"),De=V.n(Ie),ce=/]*>/g;function Me(B){var D=document.createElement("div");return D.innerHTML=B,D.childNodes.length===0?"":D.childNodes[0].nodeValue}var Be=We.a=function(B){var D=B.value,P=D===void 0?"":D,F=B.edit,W=F===void 0?!1:F,I=B.className,U=B.showTextOnly,j=B.showLines,G=B.replaces,$=B.zoomImg,Y=B.hasMask,q=B.style,Se=q===void 0?{}:q,we=B.stylesPrev,xe=we===void 0?{}:we,Ke=String(P),Fe=Object(_.useRef)(),ke=Object(_.useRef)(),ze=Object(_.useState)(""),pe=Object(M.a)(ze,2),Le=pe[0],be=pe[1],Ue=Object(_.useState)("office"),Je=Object(M.a)(Ue,2),Ge=Je[0],et=Je[1],rt=function(){var Xe=new je(ke.current);Xe.displayMode="popup",Xe.addRenderEventListener(function(){var nt=Object(E.a)(A.a.mark(function Ye(Pe){var Ne;return A.a.wrap(function(Ze){for(;;)switch(Ze.prev=Ze.next){case 0:return Fe.current.style.display="none",Ze.next=3,Object(ve.a)("/api/attachments.json",{method:"post",body:{file_type:"base64",original_filename:"educoder.png",file:Pe}});case 3:Ne=Ze.sent,Ne!=null&&Ne.id&&G(ke.current.getAttribute("src").replace(J.a.API_SERVER,""),"/api/attachments/".concat(Ne==null?void 0:Ne.id,"?type=").concat(Ne.content_type));case 5:case"end":return Ze.stop()}},Ye)}));return function(Ye){return nt.apply(this,arguments)}}()),Xe.show()},it=function(){var Xe=new re.a(ke.current);Xe.settings.displayMode="popup",Xe.addEventListener("render",function(){var nt=Object(E.a)(A.a.mark(function Ye(Pe){var Ne;return A.a.wrap(function(Ze){for(;;)switch(Ze.prev=Ze.next){case 0:if(Fe.current.style.display="none",!ke.current){Ze.next=6;break}return Ze.next=4,Object(ve.a)("/api/attachments.json",{method:"post",body:{file_type:"base64",original_filename:"educoder.png",file:Pe.dataUrl}});case 4:Ne=Ze.sent,Ne!=null&&Ne.id&&G(ke.current.getAttribute("src").replace(J.a.API_SERVER,""),"/api/attachments/".concat(Ne==null?void 0:Ne.id,"?type=").concat(Ne.content_type));case 6:case"end":return Ze.stop()}},Ye)}));return function(Ye){return nt.apply(this,arguments)}}()),Xe.show(),window.markerArea=Xe},ot=Object(_.useMemo)(function(){Fe.current&&(Fe.current.style.zIndex=-1);try{var qe=/\(\s+\/api\/attachments\/|\(\/api\/attachments\/|\(\/attachments\/download\//g,Xe=/\"\/api\/attachments\/|\"\/attachments\/download\//g,nt=/\(\s+\/files\/uploads\/|\"\/files\/uploads\//g;Ke=Ke.replace(qe,"("+J.a.API_SERVER+"/api/attachments/").replace(Xe,'"'+J.a.API_SERVER+"/api/attachments/").replace(nt,'"'+J.a.API_SERVER+"/files/uploads/").replaceAll("http://video.educoder","https://video.educoder").replaceAll("http://www.educoder.net/api","https://data.educoder.net/api").replaceAll("https://www.educoder.net/api","https://data.educoder.net/api").replace(/\r\n/g,`
`)}catch($e){}var Ye=H(Ke),Pe=h();if(Ke.match(/\[TOC\]/)&&(Ye=Ye.replace("[TOC]
",m()),c()),Ye=Ye.replace(/(__special_katext_id_\d+__)/g,function($e,Ze){var ut=Pe[Ze],dt=ut.type,tt=ut.expression;return Object(te.renderToString)(Me(tt)||"",{displayMode:dt==="block",throwOnError:!1,output:"html"})}),Ye=Ye.replace(/▁/g,"\u2581\u2581\u2581"),f(),U){var Ne=document.createElement("div");return Ne.innerHTML=Ye,Ne.innerText}return setTimeout(function(){return st()},500),Ye},[Ke]),at=Object(_.useRef)();l.WebkitLineClamp=j,j&&(Se=Object(C.a)(Object(C.a)({},Se),l));function lt(qe){var Xe=qe.target;if(Xe.tagName.toUpperCase()==="IMG"){if($){var nt=Xe.getAttribute("src");be(nt),et("image")}}else if(Xe.tagName.toUpperCase()==="A"){var Ye=Xe.getAttribute("href");if(Ye.indexOf("office")>-1)qe.preventDefault(),be(Ye),et("office");else if(Ye.indexOf("application/pdf")>-1)qe.preventDefault(),be(Ye),et("pdf");else if(Ye.indexOf("text/html")>-1)qe.preventDefault(),be(Ye),et("html");else if(Ye.startsWith("#")){qe.preventDefault();var Pe=document.getElementById(Ye.replace("#",""));Pe&&Pe.scrollIntoView(!0)}}}var st=function(){var Xe,nt=(Xe=at.current)===null||Xe===void 0?void 0:Xe.querySelectorAll("video");nt==null||nt.forEach(function(Ye){if(Ye.oncontextmenu=function(){return!1},Ye.src.indexOf(".m3u8")>-1&&!Ye.canPlayType("application/vnd.apple.mpegurl")){if(z.a.isSupported()){var Pe=new z.a;Pe.loadSource(Ye.src),Pe.attachMedia(Ye)}}})};Object(_.useEffect)(function(){if(at.current&&ot&&(ot.match(ce)&&window.PR.prettyPrint()),at.current)return at.current.addEventListener("click",lt),function(){at.current.removeEventListener("click",lt),f(),c()}},[ot,at.current,lt]);var Qe=function(Xe){if(!W)return;Xe.target.nodeName==="IMG"?(Fe.current.style.zIndex=1,Fe.current.style.display="flex",Fe.current.style.width=Xe.target.clientWidth+"px",Fe.current.style.height=Xe.target.clientHeight+"px",Fe.current.style.top=Xe.target.offsetTop+"px",Fe.current.style.left=Xe.target.offsetLeft+"px",ke.current.src=Xe.target.getAttribute("src")):Fe.current.style.display="none"};return g.a.createElement("div",{style:{position:"relative"}},g.a.createElement("div",{ref:at,style:Object(C.a)({},Se),className:"".concat(I||""," markdown-body ").concat(De.a.mdBody),onMouseOver:Qe,dangerouslySetInnerHTML:{__html:ot}}),g.a.createElement("div",{ref:Fe,className:De.a.button},g.a.createElement(k.a,null,g.a.createElement(O.a,{onClick:function(){return rt()}},"\u88C1\u526A"),g.a.createElement(O.a,{onClick:function(){return it()}},"\u7F16\u8F91"))),g.a.createElement("img",{ref:ke,src:"",alt:"sample",crossOrigin:"anonymous",style:{maxWidth:"90%",opacity:0,position:"absolute",zIndex:-1}}),g.a.createElement(ee.a,{close:!0,data:Le,type:Le!=null&&Le.length?Ge:"",style:Object(C.a)({},xe),onClose:function(){return be("")}}))}},BJfS:function(He,We){var V=function(ae){return ae.replace(/[A-Z]/g,function(k){return"-"+k.toLowerCase()}).toLowerCase()};He.exports=V},CAjq:function(He,We,V){He.exports=V.p+"static/qqCode.a1502573.png"},"Cs+z":function(He,We,V){He.exports=V.p+"static/jqr.b801d45b.png"},"Ct/S":function(He,We,V){He.exports={tilte:"tilte___1Tz7i",flexRow:"flexRow___3w9_D",flexColumn:"flexColumn___2HzC_",footerWrap:"footerWrap___12F5M",img:"img___3ED9Z",content:"content___rqPDY",modalContent:"modalContent___2h4ne"}},DlQD:function(He,We,V){(function(ae,k){He.exports=k()})(this,function(){"use strict";function ae(P,F){for(var W=0;WP.length)&&(F=P.length);for(var W=0,I=new Array(F);W=P.length?{done:!0}:{done:!1,value:P[I++]}}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}return W=P[Symbol.iterator](),W.next.bind(W)}function E(P,F){return F={exports:{}},P(F,F.exports),F.exports}var M=E(function(P){function F(){return{baseUrl:null,breaks:!1,gfm:!0,headerIds:!0,headerPrefix:"",highlight:null,langPrefix:"language-",mangle:!0,pedantic:!1,renderer:null,sanitize:!1,sanitizer:null,silent:!1,smartLists:!1,smartypants:!1,tokenizer:null,walkTokens:null,xhtml:!1}}function W(I){P.exports.defaults=I}P.exports={defaults:F(),getDefaults:F,changeDefaults:W}}),w=M.defaults,A=M.getDefaults,_=M.changeDefaults,g=/[&<>"']/,x=/[&<>"']/g,S=/[<>"']|&(?!#?\w+;)/,v=/[<>"']|&(?!#?\w+;)/g,y={"&":"&","<":"<",">":">",'"':""","'":"'"},p=function(F){return y[F]};function s(P,F){if(F){if(g.test(P))return P.replace(x,p)}else if(S.test(P))return P.replace(v,p);return P}var e=/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig;function a(P){return P.replace(e,function(F,W){return W=W.toLowerCase(),W==="colon"?":":W.charAt(0)==="#"?W.charAt(1)==="x"?String.fromCharCode(parseInt(W.substring(2),16)):String.fromCharCode(+W.substring(1)):""})}var n=/(^|[^\[])\^/g;function c(P,F){P=P.source||P,F=F||"";var W={replace:function(U,j){return j=j.source||j,j=j.replace(n,"$1"),P=P.replace(U,j),W},getRegex:function(){return new RegExp(P,F)}};return W}var l=/[^\w:]/g,u=/^$|^[a-z][a-z0-9+.-]*:|^[?#]/i;function m(P,F,W){if(P){var I;try{I=decodeURIComponent(a(W)).replace(l,"").toLowerCase()}catch(U){return null}if(I.indexOf("javascript:")===0||I.indexOf("vbscript:")===0||I.indexOf("data:")===0)return null}F&&!u.test(W)&&(W=r(F,W));try{W=encodeURI(W).replace(/%25/g,"%")}catch(U){return null}return W}var d={},o=/^[^:]+:\/*[^/]*$/,i=/^([^:]+:)[\s\S]*$/,t=/^([^:]+:\/*[^/]*)[\s\S]*$/;function r(P,F){d[" "+P]||(o.test(P)?d[" "+P]=P+"/":d[" "+P]=R(P,"/",!0)),P=d[" "+P];var W=P.indexOf(":")===-1;return F.substring(0,2)==="//"?W?F:P.replace(i,"$1")+F:F.charAt(0)==="/"?W?F:P.replace(t,"$1")+F:P+F}var h={exec:function(){}};function f(P){for(var F=1,W,I;F=0&&$[q]==="\\";)Y=!Y;return Y?"|":" |"}),I=W.split(/ \|/),U=0;if(I.length>F)I.splice(F);else for(;I.length=I.length?U.slice(I.length):U}).join(`
`)}var re=function(){function P(W){this.options=W||K}var F=P.prototype;return F.space=function(I){var U=this.rules.block.newline.exec(I);if(U)return U[0].length>1?{type:"space",raw:U[0]}:{raw:`
`}},F.code=function(I,U){var j=this.rules.block.code.exec(I);if(j){var G=U[U.length-1];if(G&&G.type==="paragraph")return{raw:j[0],text:j[0].trimRight()};var $=j[0].replace(/^ {4}/gm,"");return{type:"code",raw:j[0],codeBlockStyle:"indented",text:this.options.pedantic?$:X($,`
`)}}},F.fences=function(I){var U=this.rules.block.fences.exec(I);if(U){var j=U[0],G=ve(j,U[3]||"");return{type:"code",raw:j,lang:U[2]?U[2].trim():U[2],text:G}}},F.heading=function(I){var U=this.rules.block.heading.exec(I);if(U)return{type:"heading",raw:U[0],depth:U[1].length,text:U[2]}},F.nptable=function(I){var U=this.rules.block.nptable.exec(I);if(U){var j={type:"table",header:z(U[1].replace(/^ *| *\| *$/g,"")),align:U[2].replace(/^ *|\| *$/g,"").split(/ *\| */),cells:U[3]?U[3].replace(/\n$/,"").split(`
`):[],raw:U[0]};if(j.header.length===j.align.length){var G=j.align.length,$;for($=0;$ ?/gm,"");return{type:"blockquote",raw:U[0],text:j}}},F.list=function(I){var U=this.rules.block.list.exec(I);if(U){for(var j=U[0],G=U[2],$=G.length>1,Y=G[G.length-1]===")",q={type:"list",raw:j,ordered:$,start:$?+G.slice(0,-1):"",loose:!1,items:[]},Se=U[0].match(this.rules.block.item),we=!1,xe,Ke,Fe,ke,ze,pe,Le,be=Se.length,Ue=0;Ue1||this.options.smartLists&&Fe!==G)&&(ke=Se.slice(Ue+1).join(`
`),q.raw=q.raw.substring(0,q.raw.length-ke.length),Ue=be-1)),ze=we||/\n\n(?!\s*$)/.test(xe),Ue!==be-1&&(we=xe.charAt(xe.length-1)===`
`,ze||(ze=we)),ze&&(q.loose=!0),pe=/^\[[ xX]\] /.test(xe),Le=void 0,pe&&(Le=xe[1]!==" ",xe=xe.replace(/^\[[ xX]\] +/,"")),q.items.push({type:"list_item",raw:j,task:pe,checked:Le,loose:ze,text:xe});return q}},F.html=function(I){var U=this.rules.block.html.exec(I);if(U)return{type:this.options.sanitize?"paragraph":"html",raw:U[0],pre:!this.options.sanitizer&&(U[1]==="pre"||U[1]==="script"||U[1]==="style"),text:this.options.sanitize?this.options.sanitizer?this.options.sanitizer(U[0]):J(U[0]):U[0]}},F.def=function(I){var U=this.rules.block.def.exec(I);if(U){U[3]&&(U[3]=U[3].substring(1,U[3].length-1));var j=U[1].toLowerCase().replace(/\s+/g," ");return{tag:j,raw:U[0],href:U[2],title:U[3]}}},F.table=function(I){var U=this.rules.block.table.exec(I);if(U){var j={type:"table",header:z(U[1].replace(/^ *| *\| *$/g,"")),align:U[2].replace(/^ *|\| *$/g,"").split(/ *\| */),cells:U[3]?U[3].replace(/\n$/,"").split(`
`):[]};if(j.header.length===j.align.length){j.raw=U[0];var G=j.align.length,$;for($=0;$/i.test(G[0])&&(U=!1),!j&&/^<(pre|code|kbd|script)(\s|>)/i.test(G[0])?j=!0:j&&/^<\/(pre|code|kbd|script)(\s|>)/i.test(G[0])&&(j=!1),{type:this.options.sanitize?"text":"html",raw:G[0],inLink:U,inRawBlock:j,text:this.options.sanitize?this.options.sanitizer?this.options.sanitizer(G[0]):J(G[0]):G[0]}},F.link=function(I){var U=this.rules.inline.link.exec(I);if(U){var j=te(U[2],"()");if(j>-1){var G=U[0].indexOf("!")===0?5:4,$=G+U[1].length+j;U[2]=U[2].substring(0,j),U[0]=U[0].substring(0,$).trim(),U[3]=""}var Y=U[2],q="";if(this.options.pedantic){var Se=/^([^'"]*[^\s])\s+(['"])(.*)\2/.exec(Y);Se?(Y=Se[1],q=Se[3]):q=""}else q=U[3]?U[3].slice(1,-1):"";Y=Y.trim().replace(/^<([\s\S]*)>$/,"$1");var we=ee(U,{href:Y&&Y.replace(this.rules.inline._escapes,"$1"),title:q&&q.replace(this.rules.inline._escapes,"$1")},U[0]);return we}},F.reflink=function(I,U){var j;if((j=this.rules.inline.reflink.exec(I))||(j=this.rules.inline.nolink.exec(I))){var G=(j[2]||j[1]).replace(/\s+/g," ");if(G=U[G.toLowerCase()],!G||!G.href){var $=j[0].charAt(0);return{type:"text",raw:$,text:$}}var Y=ee(j,G,j[0]);return Y}},F.strong=function(I,U,j){j===void 0&&(j="");var G=this.rules.inline.strong.start.exec(I);if(G&&(!G[1]||G[1]&&(j===""||this.rules.inline.punctuation.exec(j)))){U=U.slice(-1*I.length);var $=G[0]==="**"?this.rules.inline.strong.endAst:this.rules.inline.strong.endUnd;$.lastIndex=0;for(var Y;(G=$.exec(U))!=null;)if(Y=this.rules.inline.strong.middle.exec(U.slice(0,G.index+3)),Y)return{type:"strong",raw:I.slice(0,Y[0].length),text:I.slice(2,Y[0].length-2)}}},F.em=function(I,U,j){j===void 0&&(j="");var G=this.rules.inline.em.start.exec(I);if(G&&(!G[1]||G[1]&&(j===""||this.rules.inline.punctuation.exec(j)))){U=U.slice(-1*I.length);var $=G[0]==="*"?this.rules.inline.em.endAst:this.rules.inline.em.endUnd;$.lastIndex=0;for(var Y;(G=$.exec(U))!=null;)if(Y=this.rules.inline.em.middle.exec(U.slice(0,G.index+2)),Y)return{type:"em",raw:I.slice(0,Y[0].length),text:I.slice(1,Y[0].length-1)}}},F.codespan=function(I){var U=this.rules.inline.code.exec(I);if(U){var j=U[2].replace(/\n/g," "),G=/[^ ]/.test(j),$=j.startsWith(" ")&&j.endsWith(" ");return G&&$&&(j=j.substring(1,j.length-1)),j=J(j,!0),{type:"codespan",raw:U[0],text:j}}},F.br=function(I){var U=this.rules.inline.br.exec(I);if(U)return{type:"br",raw:U[0]}},F.del=function(I){var U=this.rules.inline.del.exec(I);if(U)return{type:"del",raw:U[0],text:U[1]}},F.autolink=function(I,U){var j=this.rules.inline.autolink.exec(I);if(j){var G,$;return j[2]==="@"?(G=J(this.options.mangle?U(j[1]):j[1]),$="mailto:"+G):(G=J(j[1]),$=G),{type:"link",raw:j[0],text:G,href:$,tokens:[{type:"text",raw:G,text:G}]}}},F.url=function(I,U){var j;if(j=this.rules.inline.url.exec(I)){var G,$;if(j[2]==="@")G=J(this.options.mangle?U(j[0]):j[0]),$="mailto:"+G;else{var Y;do Y=j[0],j[0]=this.rules.inline._backpedal.exec(j[0])[0];while(Y!==j[0]);G=J(j[0]),j[1]==="www."?$="http://"+G:$=G}return{type:"link",raw:j[0],text:G,href:$,tokens:[{type:"text",raw:G,text:G}]}}},F.inlineText=function(I,U,j){var G=this.rules.inline.text.exec(I);if(G){var $;return U?$=this.options.sanitize?this.options.sanitizer?this.options.sanitizer(G[0]):J(G[0]):G[0]:$=J(this.options.smartypants?j(G[0]):G[0]),{type:"text",raw:G[0],text:$}}},P}(),de=H.noopTest,ie=H.edit,le=H.merge,Q={newline:/^\n+/,code:/^( {4}[^\n]+\n*)+/,fences:/^ {0,3}(`{3,}(?=[^`\n]*\n)|~{3,})([^\n]*)\n(?:|([\s\S]*?)\n)(?: {0,3}\1[~`]* *(?:\n+|$)|$)/,hr:/^ {0,3}((?:- *){3,}|(?:_ *){3,}|(?:\* *){3,})(?:\n+|$)/,heading:/^ {0,3}(#{1,6}) +([^\n]*?)(?: +#+)? *(?:\n+|$)/,blockquote:/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/,list:/^( {0,3})(bull) [\s\S]+?(?:hr|def|\n{2,}(?! )(?!\1bull )\n*|\s*$)/,html:"^ {0,3}(?:<(script|pre|style)[\\s>][\\s\\S]*?(?:\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?\\?>\\n*|\\n*|\\n*|?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:\\n{2,}|$)|<(?!script|pre|style)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:\\n{2,}|$)|(?!script|pre|style)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:\\n{2,}|$))",def:/^ {0,3}\[(label)\]: *\n? *([^\s>]+)>?(?:(?: +\n? *| *\n *)(title))? *(?:\n+|$)/,nptable:de,table:de,lheading:/^([^\n]+)\n {0,3}(=+|-+) *(?:\n+|$)/,_paragraph:/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html)[^\n]+)*)/,text:/^[^\n]+/};Q._label=/(?!\s*\])(?:\\[\[\]]|[^\[\]])+/,Q._title=/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/,Q.def=ie(Q.def).replace("label",Q._label).replace("title",Q._title).getRegex(),Q.bullet=/(?:[*+-]|\d{1,9}[.)])/,Q.item=/^( *)(bull) ?[^\n]*(?:\n(?!\1bull ?)[^\n]*)*/,Q.item=ie(Q.item,"gm").replace(/bull/g,Q.bullet).getRegex(),Q.list=ie(Q.list).replace(/bull/g,Q.bullet).replace("hr","\\n+(?=\\1?(?:(?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$))").replace("def","\\n+(?="+Q.def.source+")").getRegex(),Q._tag="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|section|source|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",Q._comment=//,Q.html=ie(Q.html,"i").replace("comment",Q._comment).replace("tag",Q._tag).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),Q.paragraph=ie(Q._paragraph).replace("hr",Q.hr).replace("heading"," {0,3}#{1,6} ").replace("|lheading","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|!--)").replace("tag",Q._tag).getRegex(),Q.blockquote=ie(Q.blockquote).replace("paragraph",Q.paragraph).getRegex(),Q.normal=le({},Q),Q.gfm=le({},Q.normal,{nptable:"^ *([^|\\n ].*\\|.*)\\n *([-:]+ *\\|[-| :]*)(?:\\n((?:(?!\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)",table:"^ *\\|(.+)\\n *\\|?( *[-:]+[-| :]*)(?:\\n *((?:(?!\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)"}),Q.gfm.nptable=ie(Q.gfm.nptable).replace("hr",Q.hr).replace("heading"," {0,3}#{1,6} ").replace("blockquote"," {0,3}>").replace("code"," {4}[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|!--)").replace("tag",Q._tag).getRegex(),Q.gfm.table=ie(Q.gfm.table).replace("hr",Q.hr).replace("heading"," {0,3}#{1,6} ").replace("blockquote"," {0,3}>").replace("code"," {4}[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|!--)").replace("tag",Q._tag).getRegex(),Q.pedantic=le({},Q.normal,{html:ie(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?\\1> *(?:\\n{2,}|\\s*$)|\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment",Q._comment).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^ *(#{1,6}) *([^\n]+?) *(?:#+ *)?(?:\n+|$)/,fences:de,paragraph:ie(Q.normal._paragraph).replace("hr",Q.hr).replace("heading",` *#{1,6} *[^
]`).replace("lheading",Q.lheading).replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").getRegex()});var Z={escape:/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,autolink:/^<(scheme:[^\s\x00-\x1f<>]*|email)>/,url:de,tag:"^comment|^[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^|^",link:/^!?\[(label)\]\(\s*(href)(?:\s+(title))?\s*\)/,reflink:/^!?\[(label)\]\[(?!\s*\])((?:\\[\[\]]?|[^\[\]\\])+)\]/,nolink:/^!?\[(?!\s*\])((?:\[[^\[\]]*\]|\\[\[\]]|[^\[\]])*)\](?:\[\])?/,reflinkSearch:"reflink|nolink(?!\\()",strong:{start:/^(?:(\*\*(?=[*punctuation]))|\*\*)(?![\s])|__/,middle:/^\*\*(?:(?:(?!overlapSkip)(?:[^*]|\\\*)|overlapSkip)|\*(?:(?!overlapSkip)(?:[^*]|\\\*)|overlapSkip)*?\*)+?\*\*$|^__(?![\s])((?:(?:(?!overlapSkip)(?:[^_]|\\_)|overlapSkip)|_(?:(?!overlapSkip)(?:[^_]|\\_)|overlapSkip)*?_)+?)__$/,endAst:/[^punctuation\s]\*\*(?!\*)|[punctuation]\*\*(?!\*)(?:(?=[punctuation\s]|$))/,endUnd:/[^\s]__(?!_)(?:(?=[punctuation\s])|$)/},em:{start:/^(?:(\*(?=[punctuation]))|\*)(?![*\s])|_/,middle:/^\*(?:(?:(?!overlapSkip)(?:[^*]|\\\*)|overlapSkip)|\*(?:(?!overlapSkip)(?:[^*]|\\\*)|overlapSkip)*?\*)+?\*$|^_(?![_\s])(?:(?:(?!overlapSkip)(?:[^_]|\\_)|overlapSkip)|_(?:(?!overlapSkip)(?:[^_]|\\_)|overlapSkip)*?_)+?_$/,endAst:/[^punctuation\s]\*(?!\*)|[punctuation]\*(?!\*)(?:(?=[punctuation\s]|$))/,endUnd:/[^\s]_(?!_)(?:(?=[punctuation\s])|$)/},code:/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,br:/^( {2,}|\\)\n(?!\s*$)/,del:de,text:/^(`+|[^`])(?:[\s\S]*?(?:(?=[\\?@\\[\\]`^{|}~",Z.punctuation=ie(Z.punctuation).replace(/punctuation/g,Z._punctuation).getRegex(),Z._blockSkip="\\[[^\\]]*?\\]\\([^\\)]*?\\)|`[^`]*?`|<[^>]*?>",Z._overlapSkip="__[^_]*?__|\\*\\*\\[^\\*\\]*?\\*\\*",Z.em.start=ie(Z.em.start).replace(/punctuation/g,Z._punctuation).getRegex(),Z.em.middle=ie(Z.em.middle).replace(/punctuation/g,Z._punctuation).replace(/overlapSkip/g,Z._overlapSkip).getRegex(),Z.em.endAst=ie(Z.em.endAst,"g").replace(/punctuation/g,Z._punctuation).getRegex(),Z.em.endUnd=ie(Z.em.endUnd,"g").replace(/punctuation/g,Z._punctuation).getRegex(),Z.strong.start=ie(Z.strong.start).replace(/punctuation/g,Z._punctuation).getRegex(),Z.strong.middle=ie(Z.strong.middle).replace(/punctuation/g,Z._punctuation).replace(/blockSkip/g,Z._blockSkip).getRegex(),Z.strong.endAst=ie(Z.strong.endAst,"g").replace(/punctuation/g,Z._punctuation).getRegex(),Z.strong.endUnd=ie(Z.strong.endUnd,"g").replace(/punctuation/g,Z._punctuation).getRegex(),Z.blockSkip=ie(Z._blockSkip,"g").getRegex(),Z.overlapSkip=ie(Z._overlapSkip,"g").getRegex(),Z._escapes=/\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/g,Z._scheme=/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/,Z._email=/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/,Z.autolink=ie(Z.autolink).replace("scheme",Z._scheme).replace("email",Z._email).getRegex(),Z._attribute=/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/,Z.tag=ie(Z.tag).replace("comment",Q._comment).replace("attribute",Z._attribute).getRegex(),Z._label=/(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/,Z._href=/<(?:\\[<>]?|[^\s<>\\])*>|[^\s\x00-\x1f]*/,Z._title=/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/,Z.link=ie(Z.link).replace("label",Z._label).replace("href",Z._href).replace("title",Z._title).getRegex(),Z.reflink=ie(Z.reflink).replace("label",Z._label).getRegex(),Z.reflinkSearch=ie(Z.reflinkSearch,"g").replace("reflink",Z.reflink).replace("nolink",Z.nolink).getRegex(),Z.normal=le({},Z),Z.pedantic=le({},Z.normal,{strong:{start:/^__|\*\*/,middle:/^__(?=\S)([\s\S]*?\S)__(?!_)|^\*\*(?=\S)([\s\S]*?\S)\*\*(?!\*)/,endAst:/\*\*(?!\*)/g,endUnd:/__(?!_)/g},em:{start:/^_|\*/,middle:/^()\*(?=\S)([\s\S]*?\S)\*(?!\*)|^_(?=\S)([\s\S]*?\S)_(?!_)/,endAst:/\*(?!\*)/g,endUnd:/_(?!_)/g},link:ie(/^!?\[(label)\]\((.*?)\)/).replace("label",Z._label).getRegex(),reflink:ie(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",Z._label).getRegex()}),Z.gfm=le({},Z.normal,{escape:ie(Z.escape).replace("])","~|])").getRegex(),_extended_email:/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/,url:/^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/,_backpedal:/(?:[^?!.,:;*_~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_~)]+(?!$))+/,del:/^~+(?=\S)([\s\S]*?\S)~+/,text:/^(`+|[^`])(?:[\s\S]*?(?:(?=[\\.5&&(I="x"+I.toString(16)),F+=""+I+";";return F}var se=function(){function P(W){this.tokens=[],this.tokens.links=Object.create(null),this.options=W||Te,this.options.tokenizer=this.options.tokenizer||new re,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options;var I={block:Ee.normal,inline:Ce.normal};this.options.pedantic?(I.block=Ee.pedantic,I.inline=Ce.pedantic):this.options.gfm&&(I.block=Ee.gfm,this.options.breaks?I.inline=Ce.breaks:I.inline=Ce.gfm),this.tokenizer.rules=I}P.lex=function(I,U){var j=new P(U);return j.lex(I)};var F=P.prototype;return F.lex=function(I){return I=I.replace(/\r\n|\r/g,`
`).replace(/\t/g," "),this.blockTokens(I,this.tokens,!0),this.inline(this.tokens),this.tokens},F.blockTokens=function(I,U,j){U===void 0&&(U=[]),j===void 0&&(j=!0),I=I.replace(/^ +$/gm,"");for(var G,$,Y,q;I;){if(G=this.tokenizer.space(I)){I=I.substring(G.raw.length),G.type&&U.push(G);continue}if(G=this.tokenizer.code(I,U)){I=I.substring(G.raw.length),G.type?U.push(G):(q=U[U.length-1],q.raw+=`
`+G.raw,q.text+=`
`+G.text);continue}if(G=this.tokenizer.fences(I)){I=I.substring(G.raw.length),U.push(G);continue}if(G=this.tokenizer.heading(I)){I=I.substring(G.raw.length),U.push(G);continue}if(G=this.tokenizer.nptable(I)){I=I.substring(G.raw.length),U.push(G);continue}if(G=this.tokenizer.hr(I)){I=I.substring(G.raw.length),U.push(G);continue}if(G=this.tokenizer.blockquote(I)){I=I.substring(G.raw.length),G.tokens=this.blockTokens(G.text,[],j),U.push(G);continue}if(G=this.tokenizer.list(I)){for(I=I.substring(G.raw.length),Y=G.items.length,$=0;$0)for(;(Se=this.tokenizer.rules.inline.reflinkSearch.exec(q))!=null;)we.includes(Se[0].slice(Se[0].lastIndexOf("[")+1,-1))&&(q=q.slice(0,Se.index)+"["+"a".repeat(Se[0].length-2)+"]"+q.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;(Se=this.tokenizer.rules.inline.blockSkip.exec(q))!=null;)q=q.slice(0,Se.index)+"["+"a".repeat(Se[0].length-2)+"]"+q.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);for(;I;){if(Y=this.tokenizer.escape(I)){I=I.substring(Y.raw.length),U.push(Y);continue}if(Y=this.tokenizer.tag(I,j,G)){I=I.substring(Y.raw.length),j=Y.inLink,G=Y.inRawBlock,U.push(Y);continue}if(Y=this.tokenizer.link(I)){I=I.substring(Y.raw.length),Y.type==="link"&&(Y.tokens=this.inlineTokens(Y.text,[],!0,G)),U.push(Y);continue}if(Y=this.tokenizer.reflink(I,this.tokens.links)){I=I.substring(Y.raw.length),Y.type==="link"&&(Y.tokens=this.inlineTokens(Y.text,[],!0,G)),U.push(Y);continue}if(Y=this.tokenizer.strong(I,q,$)){I=I.substring(Y.raw.length),Y.tokens=this.inlineTokens(Y.text,[],j,G),U.push(Y);continue}if(Y=this.tokenizer.em(I,q,$)){I=I.substring(Y.raw.length),Y.tokens=this.inlineTokens(Y.text,[],j,G),U.push(Y);continue}if(Y=this.tokenizer.codespan(I)){I=I.substring(Y.raw.length),U.push(Y);continue}if(Y=this.tokenizer.br(I)){I=I.substring(Y.raw.length),U.push(Y);continue}if(Y=this.tokenizer.del(I)){I=I.substring(Y.raw.length),Y.tokens=this.inlineTokens(Y.text,[],j,G),U.push(Y);continue}if(Y=this.tokenizer.autolink(I,oe)){I=I.substring(Y.raw.length),U.push(Y);continue}if(!j&&(Y=this.tokenizer.url(I,oe))){I=I.substring(Y.raw.length),U.push(Y);continue}if(Y=this.tokenizer.inlineText(I,G,Ae)){I=I.substring(Y.raw.length),$=Y.raw.slice(-1),U.push(Y);continue}if(I){var xe="Infinite loop on byte: "+I.charCodeAt(0);if(this.options.silent){console.error(xe);break}else throw new Error(xe)}}return U},k(P,null,[{key:"rules",get:function(){return{block:Ee,inline:Ce}}}]),P}(),he=M.defaults,ge=H.cleanUrl,ye=H.escape,me=function(){function P(W){this.options=W||he}var F=P.prototype;return F.code=function(I,U,j){var G=(U||"").match(/\S*/)[0];if(this.options.highlight){var $=this.options.highlight(I,G);$!=null&&$!==I&&(j=!0,I=$)}return G?''+(j?I:ye(I,!0))+`
`:""+(j?I:ye(I,!0))+`
`},F.blockquote=function(I){return`
`+I+`
`},F.html=function(I){return I},F.heading=function(I,U,j,G){return this.options.headerIds?"
`:""+I+"
`},F.hr=function(){return this.options.xhtml?`
`:`
`},F.list=function(I,U,j){var G=U?"ol":"ul",$=U&&j!==1?' start="'+j+'"':"";return"<"+G+$+`>
`+I+""+G+`>
`},F.listitem=function(I){return""+I+`
`},F.checkbox=function(I){return" "},F.paragraph=function(I){return""+I+`
`},F.table=function(I,U){return U&&(U=""+U+""),`
`},F.tablerow=function(I){return`
`+I+`
`},F.tablecell=function(I,U){var j=U.header?"th":"td",G=U.align?"<"+j+' align="'+U.align+'">':"<"+j+">";return G+I+""+j+`>
`},F.strong=function(I){return""+I+""},F.em=function(I){return""+I+""},F.codespan=function(I){return""+I+""},F.br=function(){return this.options.xhtml?"
":"
"},F.del=function(I){return""+I+""},F.link=function(I,U,j){if(I=ge(this.options.sanitize,this.options.baseUrl,I),I===null)return j;var G='"+j+"",G},F.image=function(I,U,j){if(I=ge(this.options.sanitize,this.options.baseUrl,I),I===null)return j;var G='
":">",G},F.text=function(I){return I},P}(),ue=function(){function P(){}var F=P.prototype;return F.strong=function(I){return I},F.em=function(I){return I},F.codespan=function(I){return I},F.del=function(I){return I},F.html=function(I){return I},F.text=function(I){return I},F.link=function(I,U,j){return""+j},F.image=function(I,U,j){return""+j},F.br=function(){return""},P}(),Oe=function(){function P(){this.seen={}}var F=P.prototype;return F.slug=function(I){var U=I.toLowerCase().trim().replace(/<[!\/a-z].*?>/ig,"").replace(/[\u2000-\u206F\u2E00-\u2E7F\\'!"#$%&()*+,./:;<=>?@[\]^`{|}~]/g,"").replace(/\s/g,"-");if(this.seen.hasOwnProperty(U)){var j=U;do this.seen[j]++,U=j+"-"+this.seen[j];while(this.seen.hasOwnProperty(U))}return this.seen[U]=0,U},P}(),Re=M.defaults,fe=H.unescape,_e=function(){function P(W){this.options=W||Re,this.options.renderer=this.options.renderer||new me,this.renderer=this.options.renderer,this.renderer.options=this.options,this.textRenderer=new ue,this.slugger=new Oe}P.parse=function(I,U){var j=new P(U);return j.parse(I)};var F=P.prototype;return F.parse=function(I,U){U===void 0&&(U=!0);var j="",G,$,Y,q,Se,we,xe,Ke,Fe,ke,ze,pe,Le,be,Ue,Je,Ge,et,rt=I.length;for(G=0;G
"+De(Y.message+"",!0)+"
";throw Y}}B.options=B.setOptions=function(P){return je(B.defaults,P),Me(B.defaults),B},B.getDefaults=ce,B.defaults=Be,B.use=function(P){var F=je({},P);if(P.renderer&&function(){var I=B.defaults.renderer||new me,U=function($){var Y=I[$];I[$]=function(){for(var q=arguments.length,Se=new Array(q),we=0;we0)},we=function(){var Ke=function(){return/macintosh|mac os x/i.test(navigator.userAgent)}();if(console.log(Ke),Ke){Me(!0);return}var Fe="//shang.qq.com/wpa/qunwpa?idkey=2f2043d88c1bd61d182b98bf1e061c6185e23055bec832c07d8148fe11c5a6cd";Object(a.S)(Fe)};return E.a.createElement("div",{className:p.a.sideBar},E.a.createElement("div",{id:"wechat_QR_code_ids"},!ge.onlyShowBackTop&&(ge==null?void 0:ge.onlyShowBackTopIcons)&&W&&E.a.createElement(E.a.Fragment,null,E.a.createElement(x.a,{placement:"left",getPopupContainer:function(){return document.getElementById("wechat_QR_code_ids")},title:E.a.createElement("div",{style:{display:"flex",justifyContent:"center",flexWrap:"wrap",width:130,padding:"5px 0"}},E.a.createElement("img",{src:V("kywy"),width:"100px",height:"100px"}),E.a.createElement("div",{className:"tc font12",style:{width:"auto"}},E.a.createElement("div",null,"\u5FAE\u4FE1\u626B\u4E00\u626B"),E.a.createElement("div",null,"\u54A8\u8BE2\u6848\u4F8B\u66F4\u65B0\u3001\u6DFB\u52A0")))},E.a.createElement("div",{className:p.a.wrap,style:{display:"flex",justifyContent:"center",paddingTop:10}},E.a.createElement("i",{className:"iconfont icon-erweima1 c-light-primary font22"}))),E.a.createElement("div",{onClick:function(){I(!1),localStorage.setItem("hidesidebar","1")},style:{textAlign:"center",fontSize:"14px",color:"#0152d9",margin:"10px 0px",cursor:"pointer"}},"\u6536\u8D77")),!ge.onlyShowBackTop&&(ge==null?void 0:ge.onlyShowBackTopIcons)&&!W&&E.a.createElement("div",{onClick:function(){I(!0),localStorage.setItem("hidesidebar","2")},style:{textAlign:"center",fontSize:"16px",color:"#0152d9",background:"#fff",margin:"10px 0px",cursor:"pointer",position:"absolute",left:"80px",top:"-150px",boxShadow:"0px 0px 8px 0px #f1f1f1",width:"30px",writingMode:"vertical-lr",height:"100px",paddingLeft:"3px"}},"\u8054\u7CFB\u6211\u4EEC")),E.a.createElement(_.a,{centered:!0,destroyOnClose:!0,open:ce,title:"\u5934\u6B4C\u6559\u5E08\u4EA4\u6D41\u793E\u533A",width:"500px",footer:null,onCancel:function(){return Me(!1)}},E.a.createElement("div",{style:{display:"flex",flexDirection:"column",alignItems:"center"}},E.a.createElement("p",null,"\u626B\u7801\u6216\u641C\u7D22\u52A0\u5165\u5934\u6B4C\u6559\u5E08\u4EA4\u6D41QQ\u7FA4\uFF1A612934990 "),E.a.createElement("img",{src:e.a,width:200,height:200}))))},c=Object(v.a)(function(oe){var se=oe.loading,he=oe.globalSetting,ge=oe.user,ye=oe.shixunHomeworks;return{globalSetting:he,user:ge,loading:se.models.index,shixunHomeworks:ye}})(n),l=V("+L6B"),u=V("2/Rp"),m=V("9og8"),d=V("WmNS"),o=V.n(d),i=function(se){var he=se.user,ge=se.dispatch,ye=se.classroomList;return E.a.createElement(_.a,{title:"\u6E29\u99A8\u63D0\u793A",zIndex:9999,footer:null,visible:ye.actionTabs.key==="\u5BFC\u51FA\u63D0\u9192",onCancel:function(){ge({type:"classroomList/setActionTabs",payload:{}})}},E.a.createElement("div",null,E.a.createElement("span",null,"\u60A8\u5728\u5F53\u524D\u680F\u76EE\u4E2D\u6709\u5DF2\u5BFC\u51FA\u7684\u8868\u683C\u672A\u4E0B\u8F7D\uFF0C\u8BF7\u5148\u4E0B\u8F7D\u5DF2\u6709\u8868\u683C\uFF0C\u7136\u540E\u518D\u5BFC\u51FA\u65B0\u7684\u8868\u683C\u3002"),E.a.createElement("br",null),E.a.createElement("div",{style:{textAlign:"end"}},E.a.createElement(u.a,{type:"primary",onClick:Object(m.a)(o.a.mark(function me(){return o.a.wrap(function(Oe){for(;;)switch(Oe.prev=Oe.next){case 0:ge({type:"classroomList/setActionTabs",payload:{}});case 1:case"end":return Oe.stop()}},me)}))},"\u77E5\u9053\u4E86"))))},t=Object(v.a)(function(oe){var se=oe.user,he=oe.classroomList;return{user:se,classroomList:he}})(i),r=V("14J3"),h=V("BMrR"),f=V("sRBo"),T=V("kaz8"),R=V("wd/R"),L=V.n(R),N=V("2tKv"),H=V.n(N),K=V("O9QN"),X=V.n(K),z=function(se){var he,ge,ye=se.user,me=Object(C.useState)(!1),ue=Object(b.a)(me,2),Oe=ue[0],Re=ue[1],fe=Object(C.useState)(""),_e=Object(b.a)(fe,2),je=_e[0],Ie=_e[1];Object(C.useEffect)(function(){var ce,Me,Be=localStorage.getItem("extension-modal");if(!(ye!=null&&(ce=ye.userInfo)!==null&&ce!==void 0&&ce.login)||!Be)return;var B=L()(),D="".concat(ye==null||((Me=ye.userInfo)===null||Me===void 0)?void 0:Me.login,"-extend-date"),P=localStorage.getItem(D);if(P)if(B<=L()(P))Re(!1);else{Re(!0),localStorage.removeItem(D),localStorage.removeItem("extension-modal");var F=L()(localStorage.getItem("extension-date")).format("YYYY\u5E74MM\u6708DD\u65E5");Ie(F)}else{Re(!0),localStorage.removeItem("extension-modal");var W=L()(localStorage.getItem("extension-date")).format("YYYY\u5E74MM\u6708DD\u65E5");Ie(W)}return function(){Re(!1)}},[ye==null||((he=ye.userInfo)===null||he===void 0)?void 0:he.login]);var De=function(Me){var Be,B="".concat(ye==null||((Be=ye.userInfo)===null||Be===void 0)?void 0:Be.login,"-extend-date"),D=L()().endOf("day").format("YYYY-MM-DD HH:mm:ss");Me.target.checked?localStorage.setItem(B,D):localStorage.removeItem(B)};return E.a.createElement(_.a,{title:"\u6E29\u99A8\u63D0\u793A",visible:Oe,zIndex:9999,centered:!0,width:594,onCancel:function(){Re(!1)},footer:E.a.createElement(h.a,{align:"middle",justify:"space-between"},E.a.createElement(T.a,{onChange:De},"\u4ECA\u65E5\u4E0D\u518D\u63D0\u9192"),E.a.createElement(u.a,{onClick:function(){Re(!1)},style:{borderRadius:4},type:"primary"}," ","\u5173\u95ED"))},E.a.createElement("div",{className:"font14",style:{paddingLeft:16}},E.a.createElement("div",null,"\u8001\u5E08\u60A8\u597D\uFF01"),E.a.createElement("div",{style:{textIndent:28}},"\u611F\u8C22\u60A8\u5BF9\u5E73\u53F0\u7684\u8BA4\u53EF\u4E0E\u652F\u6301\uFF01\u6839\u636E\u5E73\u53F0",E.a.createElement("a",{href:"https://www.educoder.net/help/agreement",target:"_blank"},"\u670D\u52A1\u534F\u8BAE"),"\uFF0C\u8D35\u5355\u4F4D\u514D\u8D39\u8BD5\u7528\u671F\u5DF2\u7ED3\u675F\uFF0C\u5C06\u9650\u5236\u5BF9\u76F8\u5173\u529F\u80FD\u548C\u8D44\u6E90\u7684\u4F7F\u7528\u3002"),E.a.createElement("div",{style:{textIndent:28}},"\u8BF7\u60A8\u6DFB\u52A0\u4EE5\u4E0B\u5FAE\u4FE1\u5BA2\u670D\uFF0C\u534F\u52A9\u60A8\u5B8C\u6210\u540E\u7EED\u4F7F\u7528\u53CA\u7533\u8BF7\u6D41\u7A0B\uFF0C\u611F\u8C22\u652F\u6301\u4E0E\u7406\u89E3\u3002"),E.a.createElement("img",{style:{margin:"8px auto",display:"block"},width:160,src:((ge=ye.userInfo)===null||ge===void 0?void 0:ge.school_province)==="\u5B89\u5FBD"?X.a:H.a,alt:"\u4E8C\u7EF4\u7801"}),E.a.createElement("div",{style:{textAlign:"right"}},"\u8FD0\u8425\u4E2D\u5FC3"),E.a.createElement("div",{style:{textAlign:"right"}},je)))},J=Object(v.a)(function(oe){var se=oe.user;return{user:se}})(z),te=V("fV52"),ee=V("3I+P"),ve=V("xnZT"),re=V.n(ve),de=V("9Bee"),ie=V("ErOA"),le=V("LvDl"),Q=V.n(le),Z=function(se){var he,ge,ye=se.dispatch,me=se.user,ue=se.globalSetting,Oe=Object(C.useState)({}),Re=Object(b.a)(Oe,2),fe=Re[0],_e=Re[1],je=Object(C.useState)([]),Ie=Object(b.a)(je,2),De=Ie[0],ce=Ie[1],Me=Object(C.useState)(0),Be=Object(b.a)(Me,2),B=Be[0],D=Be[1],P=Object(C.useState)(!1),F=Object(b.a)(P,2),W=F[0],I=F[1],U=Object(C.useRef)(null),j=Object(S.h)(),G=function(pe,Le){var be=null;return pe===0&&(be=L()().add(100,"month").unix()),pe===1&&(be=L()().add(Le,"hour").unix()),pe===2&&(be=L()().add(Le,"days").unix()),pe===3&&(be=L()().add(Le*7,"days").unix()),pe===4&&(be=L()().add(Le,"month").unix()),pe===5&&(be=L()().add(Le*3,"month").unix()),be},$=function(pe){var Le,be,Ue,Je="".concat(me==null||((Le=me.userInfo)===null||Le===void 0)?void 0:Le.login,"-deadline-operate"),Ge=localStorage.getItem(Je)?JSON.parse(localStorage.getItem(Je)):[];Ge=(be=Ge)===null||be===void 0?void 0:be.filter(function(it){return it.id!==(pe==null?void 0:pe.id)});var et=G(pe==null?void 0:pe.show_type,pe==null?void 0:pe.show_count),rt={id:pe==null?void 0:pe.id,deadline:et,type:pe==null?void 0:pe.show_type};(Ue=Ge)===null||Ue===void 0||Ue.push(rt),localStorage.setItem(Je,JSON.stringify(Ge))},Y=function(){xe(fe==null?void 0:fe.id,"close");var pe=De[B+1];pe?($(pe),_e(pe),D(B+1),xe(pe==null?void 0:pe.id,"popup")):I(!1)},q=[{name:"\u9996\u9875",key:0,path:"/"},{name:"\u5B9E\u8DF5\u8BFE\u7A0B",key:1,path:"/paths"},{name:"\u5B9E\u8DF5\u9879\u76EE",key:2,path:"/shixuns"},{name:"\u6559\u5B66\u8BFE\u5802",key:3,path:"/classrooms"},{name:"\u5728\u7EBF\u7ADE\u8D5B",key:4,path:"/competitions"},{name:"\u6559\u5B66\u6848\u4F8B",key:5,path:"/moop_cases"},{name:"\u4EA4\u6D41\u95EE\u7B54",key:6,path:"/forums/categories"},{name:"\u4E2A\u4EBA\u4E2D\u5FC3",key:7,path:"/users"}];Object(C.useEffect)(function(){var ze,pe,Le;console.log(ue==null?void 0:ue.operateModelPath,me==null||((ze=me.userInfo)===null||ze===void 0)?void 0:ze.login,11444),!!(ue!=null&&ue.operateModelPath)&&!!(ue!=null&&(pe=ue.setting)!==null&&pe!==void 0&&pe.main_site)&&me!==null&&me!==void 0&&(Le=me.userInfo)!==null&&Le!==void 0&&Le.login&&Ke()},[ue==null?void 0:ue.operateModelPath,me==null||((he=me.userInfo)===null||he===void 0)?void 0:he.login,ue==null||((ge=ue.setting)===null||ge===void 0)?void 0:ge.main_site]),Object(C.useEffect)(function(){return function(){ye({type:"globalSetting/setOperateModelPath",payload:""})}},[]),Object(C.useEffect)(function(){var ze,pe,Le,be;if(j!=null&&(ze=j.pathname)!==null&&ze!==void 0&&ze.includes("/users")&&(j==null||((pe=j.pathname)===null||pe===void 0||((Le=pe.split("/"))===null||Le===void 0))?void 0:Le.length)===4){ye({type:"globalSetting/setOperateModelPath",payload:"/users"});return}if(j!=null&&(be=j.pathname)!==null&&be!==void 0&&be.includes("/forums/categories")){ye({type:"globalSetting/setOperateModelPath",payload:"/forums/categories"});return}for(var Ue=0;UeparseInt(ce)&&Ie(!0)},[]),E.a.createElement(k.b,{locale:M.default},document.domain!=="kepukehuan.educoder.net"&&E.a.createElement(w.a,Oe),E.a.createElement("section",{className:Ee.a.layoutMainClass},ye),E.a.createElement(c,null),E.a.createElement(t,null),E.a.createElement(J,null),!Object(a.r)()&&E.a.createElement(ne,null))},Ae=We.default=Object(v.a)(function(oe){var se=oe.loading,he=oe.globalSetting,ge=oe.user;return{loading:se,user:ge,globalSetting:he}})(Ce)},Jky8:function(He,We,V){"use strict";var ae=V("sRBo"),k=V("kaz8"),b=V("5NDa"),O=V("5rEg"),C=V("miYZ"),E=V("tsqr"),M=V("9og8"),w=V("2qtc"),A=V("kLXV"),_=V("tJVT"),g=V("WmNS"),x=V.n(g),S=V("q1tI"),v=V.n(S),y=V("9kvl"),p=V("6CvP"),s=V("1XHU"),e=V("1vsH"),a;(function(c){c[c.Professor=1]="Professor",c[c.AssistantProfessor=2]="AssistantProfessor",c[c.Student=3]="Student"})(a||(a={}));var n=function(l){var u=l.visible,m=l.user,d=l.onCancel,o=d===void 0?function(){}:d,i=Object(S.useState)(),t=Object(_.a)(i,2),r=t[0],h=t[1],f=Object(S.useState)([]),T=Object(_.a)(f,2),R=T[0],L=T[1],N=Object(S.useState)(!1),H=Object(_.a)(N,2),K=H[0],X=H[1],z=Object(S.useState)(!1),J=Object(_.a)(z,2),te=J[0],ee=J[1],ve=Object(S.useState)(),re=Object(_.a)(ve,2),de=re[0],ie=re[1];Object(S.useEffect)(function(){var ne;if(m!=null&&(ne=m.userInfo)!==null&&ne!==void 0&&ne.identity){var Te;L([(m==null||((Te=m.userInfo)===null||Te===void 0)?void 0:Te.identity)==="student"?3:1])}},[m]);var le=function(Te,Ee){if(R.includes(a.Professor)){A.a.confirm({centered:!0,okText:"\u786E\u5B9A",cancelText:"\u53D6\u6D88",title:"\u63D0\u793A",content:v.a.createElement("div",{className:"tc"},Ee||"\u7533\u8BF7\u5DF2\u63D0\u4EA4\uFF0C\u8BF7\u7B49\u5F85\u5BA1\u6838"),onOk:function(){y.d.push("/classrooms/".concat(Te,"/students"))}});return}y.d.push("/classrooms/".concat(Te,"/students"))},Q=function(){var ne=Object(M.a)(x.a.mark(function Te(){var Ee;return x.a.wrap(function(Ae){for(;;)switch(Ae.prev=Ae.next){case 0:if(r){Ae.next=3;break}return E.b.info("\u9080\u8BF7\u7801\u4E0D\u80FD\u4E3A\u7A7A"),Ae.abrupt("return");case 3:return X(!0),Ae.next=6,Object(p.c)({invite_code:r,professor:R.includes(a.Professor)?1:null,assistant_professor:R.includes(a.AssistantProfessor)?1:null,student:R.includes(a.Student)?1:null});case 6:if(Ee=Ae.sent,X(!1),!((Ee==null?void 0:Ee.status)===-2)){Ae.next=22;break}if(Z(),!(Ee.message==="\u8BE5\u8BFE\u5802\u8981\u6C42\u6210\u5458\u5B8C\u6210\u5B9E\u540D\u8BA4\u8BC1")){Ae.next=14;break}return ee(!0),ie(1),Ae.abrupt("return");case 14:if(!(Ee.message==="\u8BE5\u8BFE\u5802\u8981\u6C42\u6210\u5458\u5B8C\u6210\u804C\u4E1A\u8BA4\u8BC1")){Ae.next=18;break}return ee(!0),ie(2),Ae.abrupt("return");case 18:if(!(Ee.message==="\u8BE5\u8BFE\u5802\u8981\u6C42\u6210\u5458\u5B8C\u6210\u5B9E\u540D\u548C\u804C\u4E1A\u8BA4\u8BC1")){Ae.next=22;break}return ee(!0),ie(3),Ae.abrupt("return");case 22:if(!((Ee==null?void 0:Ee.status)===0)){Ae.next=27;break}return Object(e.db)(["\u6559\u5B66\u8BFE\u5802","\u9996\u9875","\u52A0\u5165\u8BFE\u5802"]),Z(),(Ee==null?void 0:Ee.course_id)&&le(Ee.course_id,Ee.message),Ae.abrupt("return");case 27:case"end":return Ae.stop()}},Te)}));return function(){return ne.apply(this,arguments)}}(),Z=function(){var ne=Object(M.a)(x.a.mark(function Te(){return x.a.wrap(function(Ce){for(;;)switch(Ce.prev=Ce.next){case 0:o();case 1:case"end":return Ce.stop()}},Te)}));return function(){return ne.apply(this,arguments)}}();return v.a.createElement(v.a.Fragment,null,v.a.createElement(A.a,{centered:!0,keyboard:!1,closable:!1,title:"\u52A0\u5165\u8BFE\u5802",visible:u,confirmLoading:K,onOk:Q,onCancel:Z},v.a.createElement("div",{className:"tc"},v.a.createElement("div",null,v.a.createElement("span",null,"\u8BFE\u5802\u9080\u8BF7\u7801\uFF1A"),v.a.createElement(O.a,{placeholder:"\u8BF7\u8F93\u51655\u4F4D\u8BFE\u5802\u9080\u8BF7\u7801\u62166\u4F4D\u5206\u73ED\u9080\u8BF7\u7801",style:{width:270},value:r,onChange:function(Te){if(Te.target.value.length>=7){E.b.info("\u8BF7\u8F93\u51655\u4F4D\u8BFE\u5802\u9080\u8BF7\u7801\u62166\u4F4D\u5206\u73ED\u9080\u8BF7\u7801\uFF01");return}h(Te.target.value)}})),v.a.createElement("div",{className:"mt10 font14"},v.a.createElement("span",null,"\u8EAB\u4EFD\uFF1A"),v.a.createElement(k.a.Group,{value:R,onChange:function(Te){return L(Te)}},v.a.createElement(k.a,{value:a.Professor,disabled:R.includes(2)||R.includes(3)},"\u6559\u5E08"),v.a.createElement(k.a,{value:a.AssistantProfessor,disabled:R.includes(1)},"\u52A9\u6559"),v.a.createElement(k.a,{value:a.Student,disabled:R.includes(1)},"\u5B66\u751F/\u53C2\u8D5B\u8005"))))),v.a.createElement(s.a,{visible:te,onCancel:function(){return ee(!1)},occupationValue:de}))};We.a=Object(y.a)(function(c){var l=c.user;return{user:l}})(n)},NLgs:function(He,We,V){"use strict";V.d(We,"e",function(){return s}),V.d(We,"f",function(){return e}),V.d(We,"d",function(){return n}),V.d(We,"c",function(){return c}),V.d(We,"a",function(){return l}),V.d(We,"b",function(){return u});var ae=V("miYZ"),k=V("tsqr"),b=V("9og8"),O=V("2qtc"),C=V("kLXV"),E=V("WmNS"),M=V.n(E),w=V("q1tI"),A=V.n(w),_=V("9kvl"),g=V("xKgJ"),x=V("1vsH"),S=V("RCxd"),v=V("yTi+"),y=V.n(v),p=V("m3rI"),s=function(d){var o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;return!!(e(d)&&a(o))},e=function(d){return Object(g.p)()?!0:(d({type:"user/showPopLogin",payload:{showPopLogin:!0,showClosable:!0}}),!1)},a=function(){var d,o=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1,i=Object(_.c)()._store.getState(),t=i.user;return(d=t.userInfo)!==null&&d!==void 0&&d.profile_completed?!0:(C.a.confirm({title:"\u63D0\u793A",width:530,centered:!0,content:o?"\u6309\u7167\u6709\u5173\u653F\u7B56\u89C4\u5B9A\uFF0C\u7279\u6B8A\u5B9E\u9A8C\u9700\u8981\u5148\u7ED1\u5B9A\u624B\u673A\u53F7\u624D\u80FD\u4F7F\u7528\uFF0C\u8BF7\u5148\u7ED1\u5B9A\u624B\u673A\u53F7\u7801":"\u60A8\u9700\u8981\u53BB\u5B8C\u5584\u60A8\u7684\u4E2A\u4EBA\u8D44\u6599\uFF0C\u624D\u80FD\u4F7F\u7528\u6B64\u529F\u80FD",okText:"\u7ACB\u5373\u5B8C\u5584",cancelText:"\u7A0D\u540E\u5B8C\u5584",onOk:function(){_.d.push("/account/profile/edit")}}),!1)},n=function(){var d,o=Object(_.c)()._store.getState(),i=o.user;return(d=i.userInfo)!==null&&d!==void 0&&d.professional_certification?!0:(C.a.confirm({title:"\u63D0\u793A",centered:!0,content:A.a.createElement("div",{className:"tc"},"\u60A8\u9700\u8981\u53BB\u5B8C\u6210\u60A8\u7684\u804C\u4E1A\u8BA4\u8BC1\uFF0C\u624D\u80FD\u4F7F\u7528\u6B64\u529F\u80FD"),okText:"\u7ACB\u5373\u5B8C\u5584",cancelText:"\u7A0D\u540E\u5B8C\u5584",onOk:function(){Object(x.S)("/account/certification")}}),!1)},c=function(){var d;if(Object(g.a)())return!0;var o=Object(_.c)()._store.getState(),i=o.user,t=o.globalSetting;return C.a.warning({centered:!0,width:530,title:"\u63D0\u793A",content:A.a.createElement("div",{className:"tc",style:{marginLeft:-38}},A.a.createElement("p",null,"\u626B\u7801\u6DFB\u52A0\uFF0C\u7533\u8BF7\u64CD\u4F5C\u6743\u9650"),A.a.createElement("img",{src:p.a.IMG_SERVER+(t==null||((d=t.setting)===null||d===void 0)?void 0:d.authority_qrcode_url),width:200})),okText:"\u6211\u77E5\u9053\u4E86",maskClosable:!0}),!1},l=function(d,o){var i;if(d)return!0;var t=Object(_.c)()._store.getState(),r=t.user,h=t.globalSetting;return C.a.confirm({centered:!0,zIndex:1e4,width:530,title:"\u63D0\u793A",content:A.a.createElement("div",null,A.a.createElement("p",null,o||"\u8BE5\u5B9E\u8DF5\u8D44\u6E90\u9700\u6388\u6743\u540E\u624D\u53EF\u4F7F\u7528\u3002 \u60A8\u53EF\u4EE5\u5728QQ\u670D\u52A1\u7FA4\u5411\u7BA1\u7406\u5458\u7533\u8BF7\uFF0C\u83B7\u5F97\u7EE7\u7EED\u64CD\u4F5C\u7684\u6743\u9650\u3002"),A.a.createElement("div",{style:{marginLeft:"110px"}},A.a.createElement("img",{src:p.a.IMG_SERVER+(h==null||((i=h.setting)===null||i===void 0)?void 0:i.authority_qrcode_url),width:200}),A.a.createElement("div",{style:{marginLeft:"35px"}},"\u7FA4\u53F7\uFF1A","714336072"))),okText:"\u7ACB\u5373\u8054\u7CFB",cancelText:"\u53D6\u6D88",onOk:function(){Object(x.S)("https://qm.qq.com/cgi-bin/qm/qr?k=tIyDPXUtE0yEk-MOJxhH55lTUJS-nYAM&jump_from=webapi")}}),!1},u=function(d){var o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"",i=Object(_.c)()._store.getState(),t=i.shixunsDetail.detail;return(t==null?void 0:t.public)===2||(t==null?void 0:t.public)===1||(t==null?void 0:t.shixun_status)===3?(C.a.info({centered:!0,icon:A.a.createElement(S.a,{style:{color:"#faad14"}}),width:460,title:"\u63D0\u793A",content:A.a.createElement("div",{className:"tc",style:{marginLeft:-38}},A.a.createElement("div",{style:{display:"flex",flexDirection:"column",alignItems:"flex-start",paddingLeft:38,margin:"12px 0"}},A.a.createElement("span",null,"\u8BE5\u5B9E\u8DF5\u9879\u76EE\u7684\u72B6\u6001\u4E3A",(t==null?void 0:t.public)===2?"\u5DF2\u516C\u5F00":(t==null?void 0:t.public)===1?"\u5F85\u5BA1\u6838":"\u5DF2\u5173\u95ED","\uFF0C",o,"\u3002"),A.a.createElement("p",null,"\u5982\u6709\u9700\u8981\uFF0C\u8BF7\u8054\u7CFB\u5E73\u53F0\u7BA1\u7406\u5458\u8FDB\u884C\u6280\u672F\u652F\u6301\u3002")),A.a.createElement("img",{style:{border:"4px solid #0152d9",borderRadius:"4px"},src:y.a,alt:"\u4E8C\u7EF4\u7801",width:160})),okText:"\u6211\u77E5\u9053\u4E86"}),!0):(t==null?void 0:t.shixun_status)===2?(C.a.confirm({centered:!0,icon:A.a.createElement(S.a,null),title:"\u63D0\u793A",content:A.a.createElement("div",null,A.a.createElement("span",null,"\u8BE5\u5B9E\u8DF5\u9879\u76EE\u5DF2\u53D1\u5E03\uFF0C",o,"\u3002"),A.a.createElement("br",null),A.a.createElement("span",null,"\u5982\u6709\u9700\u8981\uFF0C\u60A8\u53EF\u4EE5\u64A4\u9500\u53D1\u5E03\u540E\uFF0C\u518D\u8FDB\u884C\u64CD\u4F5C\u3002")),okText:"\u64A4\u9500\u53D1\u5E03",cancelText:"\u53D6\u6D88",onOk:function(){C.a.confirm({width:440,centered:!0,icon:A.a.createElement(S.a,{style:{color:"#faad14"}}),title:"\u63D0\u793A",content:"\u64A4\u9500\u53D1\u5E03\u540E\uFF0C\u5B66\u5458\u5C06\u65E0\u6CD5\u8FDB\u884C\u7EC3\u4E60\u3002\u662F\u5426\u786E\u8BA4\u64A4\u9500\u53D1\u5E03\uFF1F",okText:"\u786E\u5B9A\u64A4\u9500\u53D1\u5E03",cancelText:"\u53D6\u6D88",onOk:function(){var h=Object(b.a)(M.a.mark(function T(){var R;return M.a.wrap(function(N){for(;;)switch(N.prev=N.next){case 0:return N.next=2,d({type:"shixunsDetail/cancelRelease",payload:{id:t==null?void 0:t.identifier}});case 2:R=N.sent,R.status!==401&&(k.b.success("\u64A4\u9500\u53D1\u5E03\u6210\u529F\u3002\u5B9E\u8BAD\u56DE\u5230\u672A\u53D1\u5E03\u7684\u72B6\u6001\u3002"),d({type:"shixunsDetail/getShixunsDetail",payload:{id:t==null?void 0:t.identifier}}),d({type:"practiceSetting/getCommonData",payload:{id:t==null?void 0:t.identifier}}));case 4:case"end":return N.stop()}},T)}));function f(){return h.apply(this,arguments)}return f}()})}}),!0):!1}},O9QN:function(He,We,V){He.exports=V.p+"static/AnhuiContact.80900438.jpg"},SJMd:function(He,We){/**
* @license
* Copyright (C) 2006 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/var V,ae,k,b=!1,O,C;window.PR_SHOULD_USE_CONTINUATION=!0;var E,M;(function(){var w=window,A=["break,continue,do,else,for,if,return,while"],_=[A,"auto,case,char,const,default,double,enum,extern,float,goto,inline,int,long,register,restrict,short,signed,sizeof,static,struct,switch,typedef,union,unsigned,void,volatile"],g=[_,"catch,class,delete,false,import,new,operator,private,protected,public,this,throw,true,try,typeof"],x=[g,"alignas,alignof,align_union,asm,axiom,bool,concept,concept_map,const_cast,constexpr,decltype,delegate,dynamic_cast,explicit,export,friend,generic,late_check,mutable,namespace,noexcept,noreturn,nullptr,property,reinterpret_cast,static_assert,static_cast,template,typeid,typename,using,virtual,where"],S=[g,"abstract,assert,boolean,byte,extends,finally,final,implements,import,instanceof,interface,null,native,package,strictfp,super,synchronized,throws,transient"],v=[g,"abstract,add,alias,as,ascending,async,await,base,bool,by,byte,checked,decimal,delegate,descending,dynamic,event,finally,fixed,foreach,from,get,global,group,implicit,in,interface,internal,into,is,join,let,lock,null,object,out,override,orderby,params,partial,readonly,ref,remove,sbyte,sealed,select,set,stackalloc,string,select,uint,ulong,unchecked,unsafe,ushort,value,var,virtual,where,yield"],y="all,and,by,catch,class,else,extends,false,finally,for,if,in,is,isnt,loop,new,no,not,null,of,off,on,or,return,super,then,throw,true,try,unless,until,when,while,yes",p=[g,"abstract,async,await,constructor,debugger,enum,eval,export,function,get,implements,instanceof,interface,let,null,set,undefined,var,with,yield,Infinity,NaN"],s="caller,delete,die,do,dump,elsif,eval,exit,foreach,for,goto,if,import,last,local,my,next,no,our,print,package,redo,require,sub,undef,unless,until,use,wantarray,while,BEGIN,END",e=[A,"and,as,assert,class,def,del,elif,except,exec,finally,from,global,import,in,is,lambda,nonlocal,not,or,pass,print,raise,try,with,yield,False,True,None"],a=[A,"alias,and,begin,case,class,def,defined,elsif,end,ensure,false,in,module,next,nil,not,or,redo,rescue,retry,self,super,then,true,undef,unless,until,when,yield,BEGIN,END"],n=[A,"case,done,elif,esac,eval,fi,function,in,local,set,then,until"],c=[x,v,S,p,s,e,a,n],l=/^(DIR|FILE|array|vector|(de|priority_)?queue|(forward_)?list|stack|(const_)?(reverse_)?iterator|(unordered_)?(multi)?(set|map)|bitset|u?(int|float)\d*)\b/,u="str",m="kwd",d="com",o="typ",i="lit",t="pun",r="pln",h="tag",f="dec",T="src",R="atn",L="atv",N="nocode",H="(?:^^\\.?|[+-]|[!=]=?=?|\\#|%=?|&&?=?|\\(|\\*=?|[+\\-]=|->|\\/=?|::?|<=?|>>?>?=?|,|;|\\?|@|\\[|~|{|\\^\\^?=?|\\|\\|?=?|break|case|continue|delete|do|else|finally|instanceof|return|throw|try|typeof)\\s*";function K(oe){for(var se=0,he=!1,ge=!1,ye=0,me=oe.length;ye122||(I<65||W>90||Me.push([Math.max(65,W)|32,Math.min(I,90)|32]),I<97||W>122||Me.push([Math.max(97,W)&~32,Math.min(I,122)&~32]))}}Me.sort(function($,Y){return $[0]-Y[0]||Y[1]-$[1]});for(var U=[],j=[],D=0;DG[0]&&(G[1]+1>G[0]&&B.push("-"),B.push(fe(G[1])))}return B.push("]"),B.join("")}function je(De){for(var ce=De.source.match(new RegExp("(?:\\[(?:[^\\x5C\\x5D]|\\\\[\\s\\S])*\\]|\\\\u[A-Fa-f0-9]{4}|\\\\x[A-Fa-f0-9]{2}|\\\\[0-9]+|\\\\[^ux0-9]|\\(\\?[:!=]|[\\(\\)\\^]|[^\\x5B\\x5C\\(\\)\\^]+)","g")),Me=ce.length,Be=[],B=0,D=0;B=2&&W==="["?ce[B]=_e(P):W!=="\\"&&(ce[B]=P.replace(/[a-zA-Z]/g,function(j){var G=j.charCodeAt(0);return"["+String.fromCharCode(G&~32,G|32)+"]"}))}return ce.join("")}for(var Ie=[],ye=0,me=oe.length;ye=0;)he[Ie.charAt(De)]=je;var ce=je[1],Me=""+ce;Re.hasOwnProperty(Me)||(Oe.push(ce),Re[Me]=null)}Oe.push(/[\0-\uffff]/),ge=K(Oe)})();var ye=se.length,me=function(ue){for(var Oe=ue.sourceCode,Re=ue.basePos,fe=ue.sourceNode,_e=[Re,r],je=0,Ie=Oe.match(ge)||[],De={},ce=0,Me=Ie.length;ce=5&&B.substring(0,5)==="lang-",P&&!(D&&typeof D[1]=="string")&&(P=!1,B=T),P||(De[Be]=B)}var I=je;if(je+=Be.length,!P)_e.push(Re+I,B);else{var U=D[1],j=Be.indexOf(U),G=j+U.length;D[2]&&(G=Be.length-D[2].length,j=G-U.length);var $=B.substring(5);z(fe,Re+I,Be.substring(0,j),me,_e),z(fe,Re+I+j,U,Z($,U),_e),z(fe,Re+I+G,Be.substring(G),me,_e)}}ue.decorations=_e};return me}function ve(oe){var se=[],he=[];oe.tripleQuotedStrings?se.push([u,/^(?:\'\'\'(?:[^\'\\]|\\[\s\S]|\'{1,2}(?=[^\']))*(?:\'\'\'|$)|\"\"\"(?:[^\"\\]|\\[\s\S]|\"{1,2}(?=[^\"]))*(?:\"\"\"|$)|\'(?:[^\\\']|\\[\s\S])*(?:\'|$)|\"(?:[^\\\"]|\\[\s\S])*(?:\"|$))/,null,`'"`]):oe.multiLineStrings?se.push([u,/^(?:\'(?:[^\\\']|\\[\s\S])*(?:\'|$)|\"(?:[^\\\"]|\\[\s\S])*(?:\"|$)|\`(?:[^\\\`]|\\[\s\S])*(?:\`|$))/,null,"'\"`"]):se.push([u,/^(?:\'(?:[^\\\'\r\n]|\\.)*(?:\'|$)|\"(?:[^\\\"\r\n]|\\.)*(?:\"|$))/,null,`"'`]),oe.verbatimStrings&&he.push([u,/^@\"(?:[^\"]|\"\")*(?:\"|$)/,null]);var ge=oe.hashComments;ge&&(oe.cStyleComments?(ge>1?se.push([d,/^#(?:##(?:[^#]|#(?!##))*(?:###|$)|.*)/,null,"#"]):se.push([d,/^#(?:(?:define|e(?:l|nd)if|else|error|ifn?def|include|line|pragma|undef|warning)\b|[^\r\n]*)/,null,"#"]),he.push([u,/^<(?:(?:(?:\.\.\/)*|\/?)(?:[\w-]+(?:\/[\w-]+)+)?[\w-]+\.h(?:h|pp|\+\+)?|[a-z]\w*)>/,null])):se.push([d,/^#[^\r\n]*/,null,"#"])),oe.cStyleComments&&(he.push([d,/^\/\/[^\r\n]*/,null]),he.push([d,/^\/\*[\s\S]*?(?:\*\/|$)/,null]));var ye=oe.regexLiterals;if(ye){var me=ye>1?"":`
\r`,ue=me?".":"[\\S\\s]",Oe="/(?=[^/*"+me+"])(?:[^/\\x5B\\x5C"+me+"]|\\x5C"+ue+"|\\x5B(?:[^\\x5C\\x5D"+me+"]|\\x5C"+ue+")*(?:\\x5D|$))+/";he.push(["lang-regex",RegExp("^"+H+"("+Oe+")")])}var Re=oe.types;Re&&he.push([o,Re]);var fe=(""+oe.keywords).replace(/^ | $/g,"");fe.length&&he.push([m,new RegExp("^(?:"+fe.replace(/[\s,]+/g,"|")+")\\b"),null]),se.push([r,/^\s+/,null,` \r
\xA0`]);var _e="^.[^\\s\\w.$@'\"`/\\\\]*";return oe.regexLiterals&&(_e+="(?!s*/)"),he.push([i,/^@[a-z_$][a-z_$@0-9]*/i,null],[o,/^(?:[@_]?[A-Z]+[a-z][A-Za-z_$@0-9]*|\w+_t\b)/,null],[r,/^[a-z_$][a-z_$@0-9]*/i,null],[i,new RegExp("^(?:0x[a-f0-9]+|(?:\\d(?:_\\d+)*\\d*(?:\\.\\d*)?|\\.\\d\\+)(?:e[+\\-]?\\d+)?)[a-z]*","i"),null,"0123456789"],[r,/^\\[\s\S]?/,null],[t,new RegExp(_e),null]),ee(se,he)}var re=ve({keywords:c,hashComments:!0,cStyleComments:!0,multiLineStrings:!0,regexLiterals:!0});function de(oe,se,he){for(var ge=/(?:^|\s)nocode(?:\s|$)/,ye=/\r\n?|\n/,me=oe.ownerDocument,ue=me.createElement("li");oe.firstChild;)ue.appendChild(oe.firstChild);var Oe=[ue];function Re(ce){var Me=ce.nodeType;if(Me==1&&!ge.test(ce.className))if(ce.nodeName==="br")fe(ce),ce.parentNode&&ce.parentNode.removeChild(ce);else for(var Be=ce.firstChild;Be;Be=Be.nextSibling)Re(Be);else if((Me==3||Me==4)&&he){var B=ce.nodeValue,D=B.match(ye);if(D){var P=B.substring(0,D.index);ce.nodeValue=P;var F=B.substring(D.index+D[0].length);if(F){var W=ce.parentNode;W.insertBefore(me.createTextNode(F),ce.nextSibling)}fe(ce),P||ce.parentNode.removeChild(ce)}}}function fe(ce){for(;!ce.nextSibling;)if(ce=ce.parentNode,!ce)return;function Me(D,P){var F=P?D.cloneNode(!1):D,W=D.parentNode;if(W){var I=Me(W,1),U=D.nextSibling;I.appendChild(F);for(var j=U;j;j=U)U=j.nextSibling,I.appendChild(j)}return F}for(var Be=Me(ce.nextSibling,0),B;(B=Be.parentNode)&&B.nodeType===1;)Be=B;Oe.push(Be)}for(var _e=0;_e=W&&(Re+=2),me>=I&&(je+=2)}}finally{B&&(B.style.display=D)}}var le={};function Q(oe,se){for(var he=se.length;--he>=0;){var ge=se[he];le.hasOwnProperty(ge)?w.console&&console.warn("cannot override language handler %s",ge):le[ge]=oe}}function Z(oe,se){return oe&&le.hasOwnProperty(oe)||(oe=/^\s*]*(?:>|$)/],[d,/^<\!--[\s\S]*?(?:-\->|$)/],["lang-",/^<\?([\s\S]+?)(?:\?>|$)/],["lang-",/^<%([\s\S]+?)(?:%>|$)/],[t,/^(?:<[%?]|[%?]>)/],["lang-",/^]*>([\s\S]+?)<\/xmp\b[^>]*>/i],["lang-js",/^