|
|
(self.webpackChunk=self.webpackChunk||[]).push([[508],{40001:function(ln,Ft,ie){"use strict";ie.d(Ft,{Z:function(){return Re}});var z=ie(54476),Ke=ie(59301),ve={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M912 190h-69.9c-9.8 0-19.1 4.5-25.1 12.2L404.7 724.5 207 474a32 32 0 00-25.1-12.2H112c-6.7 0-10.4 7.7-6.3 12.9l273.9 347c12.8 16.2 37.4 16.2 50.3 0l488.4-618.9c4.1-5.1.4-12.8-6.3-12.8z"}}]},name:"check",theme:"outlined"},Ae=ve,ye=ie(7657),be=function(fe,We){return Ke.createElement(ye.Z,(0,z.Z)({},fe,{ref:We,icon:Ae}))},Me=Ke.forwardRef(be),Re=Me},26227:function(ln,Ft,ie){"use strict";ie.d(Ft,{Z:function(){return Re}});var z=ie(54476),Ke=ie(59301),ve={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M360 184h-8c4.4 0 8-3.6 8-8v8h304v-8c0 4.4 3.6 8 8 8h-8v72h72v-80c0-35.3-28.7-64-64-64H352c-35.3 0-64 28.7-64 64v80h72v-72zm504 72H160c-17.7 0-32 14.3-32 32v32c0 4.4 3.6 8 8 8h60.4l24.7 523c1.6 34.1 29.8 61 63.9 61h454c34.2 0 62.3-26.8 63.9-61l24.7-523H888c4.4 0 8-3.6 8-8v-32c0-17.7-14.3-32-32-32zM731.3 840H292.7l-24.2-512h487l-24.2 512z"}}]},name:"delete",theme:"outlined"},Ae=ve,ye=ie(7657),be=function(fe,We){return Ke.createElement(ye.Z,(0,z.Z)({},fe,{ref:We,icon:Ae}))},Me=Ke.forwardRef(be),Re=Me},87169:function(ln,Ft,ie){"use strict";ie.d(Ft,{Z:function(){return Re}});var z=ie(54476),Ke=ie(59301),ve={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z"}},{tag:"path",attrs:{d:"M464 688a48 48 0 1096 0 48 48 0 10-96 0zm24-112h48c4.4 0 8-3.6 8-8V296c0-4.4-3.6-8-8-8h-48c-4.4 0-8 3.6-8 8v272c0 4.4 3.6 8 8 8z"}}]},name:"exclamation-circle",theme:"outlined"},Ae=ve,ye=ie(7657),be=function(fe,We){return Ke.createElement(ye.Z,(0,z.Z)({},fe,{ref:We,icon:Ae}))},Me=Ke.forwardRef(be),Re=Me},73331:function(ln,Ft,ie){"use strict";ie.d(Ft,{Z:function(){return Re}});var z=ie(54476),Ke=ie(59301),ve={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M942.2 486.2Q889.47 375.11 816.7 305l-50.88 50.88C807.31 395.53 843.45 447.4 874.7 512 791.5 684.2 673.4 766 512 766q-72.67 0-133.87-22.38L323 798.75Q408 838 512 838q288.3 0 430.2-300.3a60.29 60.29 0 000-51.5zm-63.57-320.64L836 122.88a8 8 0 00-11.32 0L715.31 232.2Q624.86 186 512 186q-288.3 0-430.2 300.3a60.3 60.3 0 000 51.5q56.69 119.4 136.5 191.41L112.48 835a8 8 0 000 11.31L155.17 889a8 8 0 0011.31 0l712.15-712.12a8 8 0 000-11.32zM149.3 512C232.6 339.8 350.7 258 512 258c54.54 0 104.13 9.36 149.12 28.39l-70.3 70.3a176 176 0 00-238.13 238.13l-83.42 83.42C223.1 637.49 183.3 582.28 149.3 512zm246.7 0a112.11 112.11 0 01146.2-106.69L401.31 546.2A112 112 0 01396 512z"}},{tag:"path",attrs:{d:"M508 624c-3.46 0-6.87-.16-10.25-.47l-52.82 52.82a176.09 176.09 0 00227.42-227.42l-52.82 52.82c.31 3.38.47 6.79.47 10.25a111.94 111.94 0 01-112 112z"}}]},name:"eye-invisible",theme:"outlined"},Ae=ve,ye=ie(7657),be=function(fe,We){return Ke.createElement(ye.Z,(0,z.Z)({},fe,{ref:We,icon:Ae}))},Me=Ke.forwardRef(be),Re=Me},15277:function(ln,Ft,ie){"use strict";ie.d(Ft,{Z:function(){return Re}});var z=ie(54476),Ke=ie(59301),ve={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M942.2 486.2C847.4 286.5 704.1 186 512 186c-192.2 0-335.4 100.5-430.2 300.3a60.3 60.3 0 000 51.5C176.6 737.5 319.9 838 512 838c192.2 0 335.4-100.5 430.2-300.3 7.7-16.2 7.7-35 0-51.5zM512 766c-161.3 0-279.4-81.8-362.7-254C232.6 339.8 350.7 258 512 258c161.3 0 279.4 81.8 362.7 254C791.5 684.2 673.4 766 512 766zm-4-430c-97.2 0-176 78.8-176 176s78.8 176 176 176 176-78.8 176-176-78.8-176-176-176zm0 288c-61.9 0-112-50.1-112-112s50.1-112 112-112 112 50.1 112 112-50.1 112-112 112z"}}]},name:"eye",theme:"outlined"},Ae=ve,ye=ie(7657),be=function(fe,We){return Ke.createElement(ye.Z,(0,z.Z)({},fe,{ref:We,icon:Ae}))},Me=Ke.forwardRef(be),Re=Me},33853:function(ln,Ft,ie){"use strict";ie.d(Ft,{Z:function(){return Re}});var z=ie(54476),Ke=ie(59301),ve={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M724 218.3V141c0-6.7-7.7-10.4-12.9-6.3L260.3 486.8a31.86 31.86 0 000 50.3l450.8 352.1c5.3 4.1 12.9.4 12.9-6.3v-77.3c0-4.9-2.3-9.6-6.1-12.6l-360-281 360-281.1c3.8-3 6.1-7.7 6.1-12.6z"}}]},name:"left",theme:"outlined"},Ae=ve,ye=ie(7657),be=function(fe,We){return Ke.createElement(ye.Z,(0,z.Z)({},fe,{ref:We,icon:Ae}))},Me=Ke.forwardRef(be),Re=Me},61485:function(ln,Ft,ie){"use strict";ie.d(Ft,{Z:function(){return Re}});var z=ie(54476),Ke=ie(59301),ve={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z"}},{tag:"path",attrs:{d:"M623.6 316.7C593.6 290.4 554 276 512 276s-81.6 14.5-111.6 40.7C369.2 344 352 380.7 352 420v7.6c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V420c0-44.1 43.1-80 96-80s96 35.9 96 80c0 31.1-22 59.6-56.1 72.7-21.2 8.1-39.2 22.3-52.1 40.9-13.1 19-19.9 41.8-19.9 64.9V620c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8v-22.7a48.3 48.3 0 0130.9-44.8c59-22.7 97.1-74.7 97.1-132.5.1-39.3-17.1-76-48.3-103.3zM472 732a40 40 0 1080 0 40 40 0 10-80 0z"}}]},name:"question-circle",theme:"outlined"},Ae=ve,ye=ie(7657),be=function(fe,We){return Ke.createElement(ye.Z,(0,z.Z)({},fe,{ref:We,icon:Ae}))},Me=Ke.forwardRef(be),Re=Me},47472:function(ln,Ft,ie){"use strict";ie.d(Ft,{Z:function(){return Re}});var z=ie(54476),Ke=ie(59301),ve={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M909.6 854.5L649.9 594.8C690.2 542.7 712 479 712 412c0-80.2-31.3-155.4-87.9-212.1-56.6-56.7-132-87.9-212.1-87.9s-155.5 31.3-212.1 87.9C143.2 256.5 112 331.8 112 412c0 80.1 31.3 155.5 87.9 212.1C256.5 680.8 331.8 712 412 712c67 0 130.6-21.8 182.7-62l259.7 259.6a8.2 8.2 0 0011.6 0l43.6-43.5a8.2 8.2 0 000-11.6zM570.4 570.4C528 612.7 471.8 636 412 636s-116-23.3-158.4-65.6C211.3 528 188 471.8 188 412s23.3-116.1 65.6-158.4C296 211.3 352.2 188 412 188s116.1 23.2 158.4 65.6S636 352.2 636 412s-23.3 116.1-65.6 158.4z"}}]},name:"search",theme:"outlined"},Ae=ve,ye=ie(7657),be=function(fe,We){return Ke.createElement(ye.Z,(0,z.Z)({},fe,{ref:We,icon:Ae}))},Me=Ke.forwardRef(be),Re=Me},87395:function(ln,Ft,ie){"use strict";ie.d(Ft,{Z:function(){return Re}});var z=ie(54476),Ke=ie(59301),ve={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M890.5 755.3L537.9 269.2c-12.8-17.6-39-17.6-51.7 0L133.5 755.3A8 8 0 00140 768h75c5.1 0 9.9-2.5 12.9-6.6L512 369.8l284.1 391.6c3 4.1 7.8 6.6 12.9 6.6h75c6.5 0 10.3-7.4 6.5-12.7z"}}]},name:"up",theme:"outlined"},Ae=ve,ye=ie(7657),be=function(fe,We){return Ke.createElement(ye.Z,(0,z.Z)({},fe,{ref:We,icon:Ae}))},Me=Ke.forwardRef(be),Re=Me},45559:function(){"use strict"},42313:function(){"use strict"},96408:function(ln,Ft){"use strict";Ft.Z={lists:"lists___xhHyq",item:"item___pWJAA",children:"children___sDG61",diamond:"diamond___FwgzD",button:"button___WPN6r",mathWrap:"mathWrap___FmnMJ",mathFillWrap:"mathFillWrap___PmY3H"}},93510:function(module,exports,__webpack_require__){var __WEBPACK_AMD_DEFINE_ARRAY__,__WEBPACK_AMD_DEFINE_RESULT__;(function(){if(typeof window.GGBApplet=="function"){console.warn("deployggb.js was loaded twice");return}var isRenderGGBElementEnabled=!1,scriptLoadStarted=!1,html5AppletsToProcess=null,ggbHTML5LoadedCodebaseIsWebSimple=!1,ggbHTML5LoadedCodebaseVersion=null,ggbHTML5LoadedScript=null,GGBApplet=function(){"use strict";for(var ln={},Ft="5.0",ie={},z=null,Ke=!1,ve=!1,Ae=null,ye=!1,be=null,Me=null,Re=0;Re<arguments.length;Re++){var Oe=arguments[Re];if(Oe!==null)switch(typeof Oe){case"number":Ft=Oe.toFixed(1);break;case"string":Oe.match(new RegExp("^[0-9]\\.[0-9]+$"))?Ft=Oe:Ae=Oe;break;case"object":typeof Oe.is3D!="undefined"?z=Oe:ie=Oe;break;case"boolean":Ke=Oe,ve=!0;break}}z===null&&(z={is3D:!1,AV:!1,SV:!1,CV:!1,EV2:!1,CP:!1,PC:!1,DA:!1,FI:!1,PV:!1,macro:!1},ie.material_id!==void 0&&!ve&&(Ke=!0)),Ae!==null&&ie.id===void 0&&(ie.id=Ae);var fe="",We="",Se=!1,yt=null,Xe=null,Le=null,Ge=!1,Ne=null,dt=null,It=null,Bt=null,mt=null;ie.height!==void 0&&(ie.height=Math.round(ie.height)),ie.width!==void 0&&(ie.width=Math.round(ie.width));var st=function(Ie){return parseFloat(Ie)>4?parseFloat(Ie):5};ln.setHTML5Codebase=function(Ie,Ue){Me=Ie,Je(Ie,Ue)},ln.setJavaCodebase=ln.setJavaCodebaseVersion=ln.isCompiledInstalled=ln.setPreCompiledScriptPath=ln.setPreCompiledResourcePath=function(){},ln.setHTML5CodebaseVersion=function(Ie,Ue){var et=parseFloat(Ie);if(et!==NaN&&et<5){console.log("The GeoGebra HTML5 codebase version "+et+" is deprecated. Using version latest instead.");return}be=Ie,ce(Ie,Ue)},ln.getHTML5CodebaseVersion=function(){return Xe},ln.getParameters=function(){return ie},ln.setFontsCSSURL=function(Ie){Bt=Ie},ln.setGiacJSURL=function(Ie){},ln.setJNLPFile=function(Ie){fe=Ie},ln.setJNLPBaseDir=function(Ie){},ln.inject=function(){function Ie(){return window.frameElement&&window.frameElement.getAttribute("data-singleton")}for(var Ue="auto",et=ie.id,cn,kt=!1,Yt=0;Yt<arguments.length;Yt++){var ze=arguments[Yt];typeof ze=="string"?(ze=ze.toLowerCase(),ze.match(/^(prefer)?(java|html5|compiled|auto|screenshot)$/)?Ue=ze:et=arguments[Yt]):typeof ze=="boolean"?kt=ze:ze instanceof HTMLElement&&(cn=ze)}zt();function zt(){if(!ye){setTimeout(zt,200);return}Ue=Pt(Ue);var ut=cn||document.getElementById(et);if(!ut){console.log("possibly bug on ajax loading? ");return}if(ln.removeExistingApplet(ut,!1),ie.width===void 0&&ut.clientWidth&&(ie.width=ut.clientWidth),ie.height===void 0&&ut.clientHeight&&(ie.height=ut.clientHeight),!(ie.width&&ie.height)&&Ue==="html5"&&(delete ie.width,delete ie.height),yt=Ue,Ue==="screenshot")lt(ut,ie);else{var ae=!1;ie.hasOwnProperty("playButton")&&ie.playButton||ie.hasOwnProperty("clickToLoad")&&ie.clickToLoad?ae=!0:ie.hasOwnProperty("playButtonAutoDecide")&&ie.playButtonAutoDecide&&(ae=(!it()||Ie())&&je()),ae?(yt="screenshot",At(ut,ie,kt,Ue)):at(ut,ie,kt)}}};function it(){try{return window.self!==window.top}catch(Ie){return!0}}function je(){return ie.hasOwnProperty("screenshotGenerator")&&ie.screenshotGenerator?!1:Math.max(screen.width,screen.height)<800}ln.getViews=function(){return z},ln.isJavaInstalled=function(){return!1};var Ot=function(Ie){var Ue=function(Yt){var ze=JSON.parse(Yt),zt=function(te){return te.type=="G"||te.type=="E"},ut=ze.elements?ze.elements.filter(zt)[0]:ze;if(!ut||!ut.url){et();return}ie.fileName=ut.url,nt(ut.settings||{}),z.is3D=!0;var ae="https://www.geogebra.org/images/";ln.setPreviewImage(Ne||ut.previewUrl,ae+"GeoGebra_loading.png",ae+"applet_play.png"),Ie()},et=function(){ie.onError&&ie.onError(),jt("Error: Fetching material (id "+ie.material_id+") failed.",ie)},cn=location.host.match(/(www|stage|beta|groot|alpha).geogebra.(org|net)/)?location.host:"www.geogebra.org",kt="/materials/"+ie.material_id+"?scope=basic";tt("https://"+cn+"/api/proxy.php?path="+encodeURIComponent(kt),Ue,et)};function nt(Ie){var Ue=["width","height","showToolBar","showMenuBar","showAlgebraInput","allowStyleBar","showResetIcon","enableLabelDrags","enableShiftDragZoom","enableRightClick","appName"];["enableLabelDrags","enableShiftDragZoom","enableRightClick"].forEach(function(et){Ie[et]=!!Ie[et]}),Ue.forEach(function(et){ie[et]===void 0&&Ie[et]!==void 0&&(ie[et]=Ie[et])}),ie.showToolBarHelp===void 0&&(ie.showToolBarHelp=ie.showToolBar)}function tt(Ie,Ue,et){var cn=new XMLHttpRequest;cn.open("GET",Ie),cn.onload=function(){Ue(cn.responseText)},cn.onerror=et,cn.send()}ln.isHTML5Installed=function(){return!0},ln.getLoadedAppletType=function(){return yt},ln.setPreviewImage=function(Ie,Ue,et){Ne=Ie,dt=Ue,It=et},ln.removeExistingApplet=function(Ie,Ue){var et;typeof Ie=="string"&&(Ie=document.getElementById(Ie)),yt=null;var cn=null;for(et=0;et<Ie.childNodes.length;et++){var kt=Ie.childNodes[et],Yt=kt.className;Yt==="applet_screenshot"?Ue?(kt.style.display="block",yt="screenshot"):kt.style.display="none":Yt!=="applet_scaler prerender"&&(Ie.removeChild(kt),cn=Yt&&Yt.indexOf("appletParameters")!=-1?kt.id:null,et--)}var ze=ie.id!==void 0?ie.id:cn,zt=window[ze];zt&&typeof zt.getBase64=="function"&&(zt.remove(),window[ze]=null)},ln.refreshHitPoints=function(){if(st(ggbHTML5LoadedCodebaseVersion)>=5)return!0;var Ie=ln.getAppletObject();return Ie&&typeof Ie.recalculateEnvironments=="function"?(Ie.recalculateEnvironments(),!0):!1},ln.startAnimation=function(){var Ie=ln.getAppletObject();return Ie&&typeof Ie.startAnimation=="function"?(Ie.startAnimation(),!0):!1},ln.stopAnimation=function(){var Ie=ln.getAppletObject();return Ie&&typeof Ie.stopAnimation=="function"?(Ie.stopAnimation(),!0):!1},ln.getAppletObject=function(){var Ie=ie.id!==void 0?ie.id:"ggbApplet";return window[Ie]},ln.resize=function(){};var ht=function(Ie,Ue,et){var cn=document.createElement("param");cn.setAttribute("name",Ue),cn.setAttribute("value",et),Ie.appendChild(cn)},$e=function(Ie){return Ie&&Ie!=="false"},at=function(Ie,Ue,et){st(Xe)<=4.2&&(et=!0);var cn=!isRenderGGBElementEnabled&&!scriptLoadStarted;(!isRenderGGBElementEnabled&&!scriptLoadStarted||ggbHTML5LoadedCodebaseVersion!==Xe||ggbHTML5LoadedCodebaseIsWebSimple&&!Ge)&&(cn=!0,isRenderGGBElementEnabled=!1,scriptLoadStarted=!1);var kt=document.createElement("div");kt.classList.add("appletParameters","notranslate");var Yt=Ue.width,ze=Ue.height;if(Ue.disableAutoScale=Ue.disableAutoScale===void 0?GGBAppletUtils.isFlexibleWorksheetEditor():Ue.disableAutoScale,Ue.width!==void 0)if(st(Xe)<=4.4)$e(Ue.showToolBar)&&(Ue.height-=7),$e(Ue.showAlgebraInput)&&(Ue.height-=37),Ue.width<605&&$e(Ue.showToolBar)&&(Ue.width=605,Yt=605);else{var zt=100;($e(Ue.showToolBar)||$e(Ue.showMenuBar))&&(Ue.hasOwnProperty("customToolBar")&&(Ue.customToolbar=Ue.customToolBar),zt=$e(Ue.showMenuBar)?245:155),Yt<zt&&(Ue.width=zt,Yt=zt)}kt.style.border="none",kt.style.display="inline-block";for(var ut in Ue)Ue.hasOwnProperty(ut)&&ut!=="appletOnLoad"&&kt.setAttribute("data-param-"+ut,Ue[ut]);Bt&&kt.setAttribute("data-param-fontscssurl",Bt),ln.resize=function(){GGBAppletUtils.responsiveResize(Ie,Ue)},window.addEventListener("resize",function(bt){ln.resize()});var ae=typeof Ue.appletOnLoad=="function"?Ue.appletOnLoad:function(){};if(!et&&Ue.width!==void 0){Ue.hasOwnProperty("showSplash")||kt.setAttribute("data-param-showSplash","false");var te=Ie.querySelector(".applet_scaler.prerender"),ee=te!==null;if(ee)var oe=te.querySelector(".ggb_preview");else{var oe=He(Yt,ze,Ue.borderColor,!1);te=document.createElement("div"),te.className="applet_scaler",te.style.position="relative",te.style.display="block",te.style.width=Yt+"px",te.style.height=ze+"px"}window.GGBT_spinner&&window.GGBT_spinner.attachSpinner(te,"66%"),st(Xe)>=5?(Ue.appletOnLoad=function(bt){var ct=Ie.querySelector(".ggb_preview");ct&&ct.parentNode.removeChild(ct),window.GGBT_spinner&&window.GGBT_spinner.removeSpinner(te),window.GGBT_wsf_view&&$(window).trigger("resize"),ae(bt)},ee||te.appendChild(oe)):kt.appendChild(oe),te.appendChild(kt),ee||Ie.appendChild(te),setTimeout(function(){ln.resize()},1)}else{var se=document.createElement("div");se.className="applet_scaler",se.style.position="relative",se.style.display="block",se.appendChild(kt),Ie.appendChild(se),Ue.appletOnLoad=function(bt){ln.resize(),ae(bt)}}function ne(bt,ct){ct&&typeof ct.appletOnLoad=="function"&&typeof renderGGBElement=="function"?renderGGBElement(bt,ct.appletOnLoad):renderGGBElement(bt),jt("GeoGebra HTML5 applet injected and rendered with previously loaded codebase.",ct)}function he(bt,ct){typeof renderGGBElement=="undefined"?(html5AppletsToProcess===null&&(html5AppletsToProcess=[]),html5AppletsToProcess.push({article:bt,params:ct}),window.renderGGBElementReady=function(){isRenderGGBElementEnabled=!0,html5AppletsToProcess!==null&&html5AppletsToProcess.length&&(html5AppletsToProcess.forEach(function(Kt){ne(Kt.article,Kt.params)}),html5AppletsToProcess=null)},st(Xe)<5&&(bt.className+=" geogebraweb")):ne(bt,ct)}if(cn){scriptLoadStarted=!0;for(var xe=0;xe<kt.childNodes.length;xe++){var ot=kt.childNodes[xe].tagName;ot==="TABLE"&&(kt.removeChild(kt.childNodes[xe]),xe--)}if(ggbHTML5LoadedScript!==null){var Ee=document.querySelector('script[src="'+ggbHTML5LoadedScript+'"]');Ee!=null&&Ee.parentNode.removeChild(Ee)}var Fe=document.createElement("script"),qe=function(){he(kt,Ue)};Fe.src=We+Le,ggbHTML5LoadedCodebaseIsWebSimple=Ge,ggbHTML5LoadedCodebaseVersion=Xe,ggbHTML5LoadedScript=Fe.src,jt("GeoGebra HTML5 codebase loaded: '"+We+"'.",Ue),!Me&&(!be||be=="5.0")?(Ge?webSimple.succeeded=webSimple.succeeded||webSimple():web3d.succeeded=web3d.succeeded||web3d(),qe()):We.requirejs?__webpack_require__.e(3861).then(function(){var bt=[__webpack_require__(40341)];qe.apply(null,bt)}.bind(this)).catch(__webpack_require__.oe):(Fe.onload=qe,Ie.appendChild(Fe))}else he(kt,Ue);Ue.height=ze,Ue.width=Yt},lt=function(Ie,Ue,et){var cn=He(Ue.width,Ue.height,Ue.borderColor,et),kt=document.createElement("div");kt.style.position="relative",kt.style.display="block",kt.style.width=Ue.width+"px",kt.style.height=Ue.height+"px",kt.className="applet_screenshot applet_scaler"+(et?" applet_screenshot_play":""),kt.appendChild(cn);var Yt=GGBAppletUtils.getScale(Ue,Ie,et);et?(Ie.appendChild(De()),window.GGBT_wsf_view||(Ie.style.position="relative")):window.GGBT_spinner&&window.GGBT_spinner.attachSpinner(kt,"66%"),Ie.appendChild(kt),Yt!==1&&!isNaN(Yt)&&(GGBAppletUtils.scaleElement(kt,Yt),kt.style.width=Ue.width+"px",kt.style.height=Ue.height+"px",kt.parentNode.style.width=Ue.width*Yt+"px",kt.parentNode.style.height=Ue.height*Yt+"px"),ln.resize=function(){me(Ie,cn,kt,et)},window.addEventListener("resize",function(ze){ln.resize()}),ln.resize()};function me(Ie,Ue,et,cn){if(Ie.contains(Ue)){if(typeof window.GGBT_wsf_view=="object"&&window.GGBT_wsf_view.isFullscreen()){if(Ie.id!=="fullscreencontent")return;window.GGBT_wsf_view.setCloseBtnPosition(Ie)}var kt=GGBAppletUtils.getScale(ie,Ie,cn);et.parentNode!==null&&(!isNaN(kt)&&kt!==1?(GGBAppletUtils.scaleElement(et,kt),et.parentNode.style.width=ie.width*kt+"px",et.parentNode.style.height=ie.height*kt+"px"):(GGBAppletUtils.scaleElement(et,1),et.parentNode.style.width=ie.width+"px",et.parentNode.style.height=ie.height+"px")),typeof window.GGBT_wsf_view=="object"&&window.GGBT_wsf_view.isFullscreen()&&GGBAppletUtils.positionCenter(Ie),typeof window.GGBT_ws_header_footer=="object"&&window.GGBT_ws_header_footer.setWsScrollerHeight()}}ln.onExitFullscreen=function(Ie,Ue){Ue.appendChild(Ie)};var At=function(Ie,Ue,et,cn){lt(Ie,Ue,!0);for(var kt=function(){var zt=[];for(ze=0;ze<Ie.childNodes.length;ze++)zt.push(Ie.childNodes[ze]);if(window.GGBT_wsf_view){var ut=window.GGBT_wsf_view.renderFullScreen(Ie,Ue.id),ae=document.getElementById("fullscreencontainer"),te=jQuery(Ie).find(".fullscreencontent");te.length>0?(ut.remove(),te.attr("id","fullscreencontent").show(),jQuery(ae).append(te),window.dispatchEvent(new Event("resize"))):at(ut,Ue,!1),window.GGBT_wsf_view.launchFullScreen(ae)}else yt=cn,at(Ie,Ue,!1);if(!window.GGBT_wsf_view)for(ze=0;ze<zt.length;ze++)Ie.removeChild(zt[ze])},Yt=Ie.getElementsByClassName("ggb_preview_play"),ze=0;ze<Yt.length;ze++)Yt[ze].addEventListener("click",kt,!1),Yt[ze].addEventListener("ontouchstart",kt,!1);typeof window.ggbAppletPlayerOnload=="function"&&window.ggbAppletPlayerOnload(Ie),je()&&window.GGBT_wsf_view&&$(".wsf-element-fullscreen-button").remove()},De=function(){var Ie=document.createElement("div");if(Ie.className="ggb_preview_play icon-applet-play",!window.GGBT_wsf_view){var Ue='.icon-applet-play { width: 100%; height: 100%;box-sizing: border-box;position: absolute;z-index: 1001;cursor: pointer;border-width: 0px; background-color: transparent;background-repeat: no-repeat;left: 0;top: 0;background-position: center center; background-image: url("https://www.geogebra.org/images/worksheet/icon-start-applet.png");}.icon-applet-play:hover {background-image: url("https://www.geogebra.org/images/worksheet/icon-start-applet-hover.png");}',et=document.createElement("style");et.styleSheet?et.styleSheet.cssText=Ue:et.appendChild(document.createTextNode(Ue)),document.getElementsByTagName("head")[0].appendChild(et)}return Ie},He=function(Ie,Ue,et,cn){var kt=document.createElement("div");kt.className="ggb_preview",kt.style.position="absolute",kt.style.zIndex="90",kt.style.width=Ie-2+"px",kt.style.height=Ue-2+"px",kt.style.top="0px",kt.style.left="0px",kt.style.overflow="hidden",kt.style.backgroundColor="white";var Yt="lightgrey";et!==void 0&&(et==="none"?Yt="transparent":Yt=et),kt.style.border="1px solid "+Yt;var ze=document.createElement("img");if(ze.style.position="relative",ze.style.zIndex="1000",ze.style.top="-1px",ze.style.left="-1px",Ne!==null&&ze.setAttribute("src",Ne),ze.style.opacity=.7,dt!==null){var zt,ut,ae;if(!cn){zt=document.createElement("img"),zt.style.position="absolute",zt.style.zIndex="1001",zt.style.opacity=1,ze.style.opacity=.3,ut=360,ut>Ie/4*3&&(ut=Ie/4*3),ae=ut/5.8,zt.setAttribute("src",dt),zt.setAttribute("width",ut),zt.setAttribute("height",ae);var te=(Ie-ut)/2,ee=(Ue-ae)/2;zt.style.left=te+"px",zt.style.top=ee+"px",kt.appendChild(zt)}}return kt.appendChild(ze),kt},Pt=function(Ie){return Ie=Ie.toLowerCase(),Ie==="html5"||Ie==="screenshot"?Ie:"html5"},ge=["web","webSimple","web3d","tablet","tablet3d","phone"],ce=function(Ie,Ue){if(Xe=Ie,Ue){Je(Xe,!0);return}var et=!Ke;if(et){var cn=st(Xe);!isNaN(cn)&&cn<4.4&&(et=!1)}var kt,Yt;window.location.protocol.substr(0,4)==="http"?kt=window.location.protocol:kt="http:";var ze=Xe.indexOf("//");ze>0?Yt=Xe:ze===0?Yt=kt+Xe:Yt="https://www.geogebra.org/apps/5.2.814.0/";for(var zt in ge)if(Xe.slice(ge[zt].length*-1)===ge[zt]||Xe.slice((ge[zt].length+1)*-1)===ge[zt]+"/"){Je(Yt,!1);return}!GGBAppletUtils.isFlexibleWorksheetEditor()&&et&&!z.is3D&&!z.AV&&!z.SV&&!z.CV&&!z.EV2&&!z.CP&&!z.PC&&!z.DA&&!z.FI&&!z.PV&&!$e(ie.showToolBar)&&!$e(ie.showMenuBar)&&!$e(ie.showAlgebraInput)&&!$e(ie.enableRightClick)&&(!ie.appName||ie.appName=="classic")?Yt+="webSimple/":Yt+="web3d/",Je(Yt,!1)},Je=function(Ie,Ue){if(Ie.requirejs){We=Ie;return}Ie.slice(-1)!=="/"&&(Ie+="/"),We=Ie,Ue===null&&(Ue=Ie.indexOf("http")===-1),Se=Ue,Le="web.nocache.js",Ge=!1;var et=We.split("/");et.length>1&&(!Ue&&et[et.length-2]==="webSimple"?(Le="webSimple.nocache.js",Ge=!0):ge.indexOf(et[et.length-2])>=0&&(Le=et[et.length-2]+".nocache.js")),et=Ie.split("/"),Xe=et[et.length-3],Xe.substr(0,4)==="test"?Xe=Xe.substr(4,1)+"."+Xe.substr(5,1):(Xe.substr(0,3)==="war"||Xe.substr(0,4)==="beta")&&(Xe="5.0");var cn=parseFloat(Xe);cn!==NaN&&cn<5&&Ie.indexOf("geogebra.org")>=0&&(console.log("The GeoGebra HTML5 codebase version "+cn+" is deprecated. Using version latest instead."),ce("5.0",Ue))},jt=function(Ie,Ue){window.console&&window.console.log&&(!Ue||typeof Ue.showLogging=="undefined"||Ue.showLogging&&Ue.showLogging!=="false")&&console.log(Ie)};ie.material_id!==void 0?Ot(wt):wt();function wt(){var Ie=Ft;be!==null?Ie=be:parseFloat(Ie)<5&&(Ie="5.0"),ce(Ie,!1),Me!==null&&Je(Me,Se),ye=!0}return ln},GGBAppletUtils=function(){"use strict";function ln(){return window.GGBT_wsf_edit!==void 0}function Ft(ye,be){be!=1?(ye.style.transformOrigin="0% 0% 0px",ye.style.webkitTransformOrigin="0% 0% 0px",ye.style.transform="scale("+be+","+be+")",ye.style.webkitTransform="scale("+be+","+be+")",ye.style.maxWidth="initial",ye.querySelector(".ggb_preview")!==null&&(ye.querySelector(".ggb_preview").style.maxWidth="initial"),ye.querySelectorAll(".ggb_preview img")[0]!==void 0&&(ye.querySelectorAll(".ggb_preview img")[0].style.maxWidth="initial"),ye.querySelectorAll(".ggb_preview img")[1]!==void 0&&(ye.querySelectorAll(".ggb_preview img")[1].style.maxWidth="initial")):(ye.style.transform="none",ye.style.webkitTransform="none")}function ie(ye,be,Me,Re,Oe,fe){var We=null;if(fe!=null&&fe!="")for(var Se=ye.parentNode;Se!=null;)if((" "+Se.className+" ").indexOf(" "+fe+" ")>-1){We=Se;break}else Se=Se.parentNode;var yt=0,Xe=0,Le=0,Ge=0,Ne=0,dt=0,It=0;if(We)yt=We.offsetWidth,Xe=Math.max(Re?We.offsetWidth:0,We.offsetHeight);else{if(window.innerWidth&&document.documentElement.clientWidth?(yt=Math.min(window.innerWidth,document.documentElement.clientWidth),Xe=Math.min(window.innerHeight,document.documentElement.clientHeight),Le=yt):(yt=window.innerWidth,Xe=window.innerHeight,Le=window.innerWidth),ye){var Bt=ye.getBoundingClientRect();Bt.left>0&&Bt.left<=yt&&(Oe===void 0||!Oe)&&(document.dir==="rtl"?(Ne=yt-Bt.width-Bt.left,dt=Le<=480?10:30):(dt=Bt.left,Ne=Le<=480?10:30),Ge=dt+Ne)}if(ye&&typeof window.GGBT_wsf_view=="object"&&window.GGBT_wsf_view.isFullscreen()){var mt=ye.getBoundingClientRect();window.GGBT_wsf_view.getCloseBtnPosition()==="closePositionRight"?(Ge=40,It=0):window.GGBT_wsf_view.getCloseBtnPosition()==="closePositionTop"&&(Ge=0,It=40)}}return ye&&((Me===void 0||!Me)&&be>0&&be+Ge<yt?yt=be:yt-=Ge,typeof window.GGBT_wsf_view=="object"&&window.GGBT_wsf_view.isFullscreen()&&(Me===void 0||!Me)&&(Xe-=It)),{width:yt,height:Xe}}function z(ye,be,Me,Re,Oe){if(ye.isScreenshoGenerator)return 1;var fe=Re!==void 0&&Re,We=ye.noScaleMargin!=null&&ye.noScaleMargin,Se=function(mt){return mt&&mt!=="false"},yt=Se(ye.autoHeight),Xe=ie(be,ye.width,Me,yt,fe&&window.GGBT_wsf_view||We,Oe),Le=parseInt(Xe.width),Ge=ye.width,Ne=ye.height;if(Ge===void 0){var dt=be.querySelector(".appletParameters");dt&&(Ge=dt.offsetWidth,Ne=dt.offsetHeight)}var It=Le/Ge,Bt=fe?1:Xe.height/Ne;return Me!==void 0&&!Me&&(It=Math.min(1,It),Bt=Math.min(1,Bt)),Math.min(It,Bt)}function Ke(ye,be,Me){var Re=1,Oe,fe=!1;if(ye.hasOwnProperty("allowUpscale")&&(fe=ye.allowUpscale),ye.hasOwnProperty("scale")&&(Re=parseFloat(ye.scale),(isNaN(Re)||Re===null||Re===0)&&(Re=1),Re>1&&(fe=!0)),be&&typeof window.GGBT_wsf_view=="object"&&window.GGBT_wsf_view.isFullscreen()&&(fe=!0),!(ye.hasOwnProperty("disableAutoScale")&&ye.disableAutoScale))Oe=z(ye,be,fe,Me,ye.scaleContainerClass);else return Re;return fe&&(!ye.hasOwnProperty("scale")||Re===1)?Oe:Math.min(Re,Oe)}function ve(ye){var be=Math.min(window.innerWidth,document.documentElement.clientWidth),Me=Math.min(window.innerHeight,document.documentElement.clientHeight),Re=ye.getBoundingClientRect(),Oe=(be-Re.width)/2,fe=(Me-Re.height)/2;fe<0&&(fe=0),ye.style.position="relative",window.GGBT_wsf_view.getCloseBtnPosition()==="closePositionRight"?(Oe<40?ye.style.left="40px":ye.style.left=Oe+"px",ye.style.top=fe+"px"):window.GGBT_wsf_view.getCloseBtnPosition()==="closePositionTop"&&(fe<40?ye.style.top="40px":ye.style.top=fe+"px",ye.style.left=Oe+"px")}function Ae(ye,be){var Me=ye.querySelector(".appletParameters");if(Me){if(typeof window.GGBT_wsf_view=="object"&&window.GGBT_wsf_view.isFullscreen()){if(be.id!==Me.getAttribute("data-param-id"))return;window.GGBT_wsf_view.setCloseBtnPosition(ye)}if(Me.parentElement&&/fullscreen/.test(Me.parentElement.className))return;var Re=Ke(be,ye);ln()&&Me.setAttribute("data-param-scale",Re);for(var Oe=null,fe=0;fe<ye.childNodes.length;fe++)if(ye.childNodes[fe].className!==void 0&&ye.childNodes[fe].className.match(/^applet_scaler/)){Oe=ye.childNodes[fe];break}if(Oe!==null&&Oe.querySelector(".noscale")!==null)return;var We=be.id!==void 0?be.id:"ggbApplet",Se=window[We];(Se==null||!Se.recalculateEnvironments)&&Oe!==null&&!Oe.className.match(/fullscreen/)&&(Oe.parentNode.style.transform="",!isNaN(Re)&&Re!==1?(Oe.parentNode.style.width=be.width*Re+"px",Oe.parentNode.style.height=be.height*Re+"px",Ft(Oe,Re)):(Ft(Oe,1),Oe.parentNode.style.width=be.width+"px",Oe.parentNode.style.height=be.height+"px")),typeof window.GGBT_wsf_view=="object"&&window.GGBT_wsf_view.isFullscreen()&&ve(ye),window.GGBT_wsf_view&&!window.GGBT_wsf_view.isFullscreen()&&window.GGBT_wsf_general.adjustContentToResize($(Me).parents(".content-added-content"))}}return{responsiveResize:Ae,isFlexibleWorksheetEditor:ln,positionCenter:ve,getScale:Ke,scaleElement:Ft}}();__WEBPACK_AMD_DEFINE_ARRAY__=[],__WEBPACK_AMD_DEFINE_RESULT__=function(){return GGBApplet}.apply(exports,__WEBPACK_AMD_DEFINE_ARRAY__),__WEBPACK_AMD_DEFINE_RESULT__!==void 0&&(module.exports=__WEBPACK_AMD_DEFINE_RESULT__),GGBAppletUtils.makeModule=function(name,permutation){function webModule(){var H="bootstrap",I="begin",J="gwt.codesvr."+name+"=",K="gwt.codesvr=",L=name,M="startup",N="DUMMY",O=0,P=1,Q="iframe",R="position:absolute; width:0; height:0; border:none; left: -1000px;",S=" top: -1000px;",T="Chrome",U="CSS1Compat",V="<!doctype html>",W="",X="<html><head></head><body></body></html>",Y="undefined",Z="readystatechange",$=10,_="script",ab="javascript",bb="Failed to load ",cb="moduleStartup",db="scriptTagAdded",eb="moduleRequested",fb="meta",gb="name",hb=name+"::",ib="::",jb="gwt:property",kb="content",lb="=",mb="gwt:onPropertyErrorFn",nb='Bad handler "',ob='" for "gwt:onPropertyErrorFn"',pb="gwt:onLoadErrorFn",qb='" for "gwt:onLoadErrorFn"',rb="#",sb="?",tb="/",ub="img",vb="clear.cache.gif",wb="baseUrl",xb=name+".nocache.js",yb="base",zb="//",Ab="selectingPermutation",Bb=name+".devmode.js",Cb=permutation,Db=":",Eb=".cache.js",Fb="loadExternalRefs",Gb="end",n=window,o=document;function p(){var ln=n.location.search;return ln.indexOf(J)!=-1||ln.indexOf(K)!=-1}function q(ln,Ft){}webModule.__sendStats=q,webModule.__moduleName=L,webModule.__errFn=null,webModule.__moduleBase=N,webModule.__softPermutationId=O,webModule.__computePropValue=null,webModule.__getPropMap=null,webModule.__installRunAsyncCode=function(){},webModule.__gwtStartLoadingFragment=function(){return null},webModule.__gwt_isKnownPropertyValue=function(){return!1},webModule.__gwt_getMetaProperty=function(){return null};var r=null,s=n.__gwt_activeModules=n.__gwt_activeModules||{};s[L]={moduleName:L},webModule.__moduleStartupDone=function(ln){var Ft=s[L].bindings;s[L].bindings=function(){for(var ie=Ft?Ft():{},z=ln[webModule.__softPermutationId],Ke=O;Ke<z.length;Ke++){var ve=z[Ke];ie[ve[O]]=ve[P]}return ie}};var t;function u(){return v(),t}function v(){if(!t){var ln=o.createElement(Q);if(ln.id=L,ln.style.cssText=R+S,ln.tabIndex=-1,o.body.appendChild(ln),t=ln.contentWindow.document,navigator.userAgent.indexOf(T)==-1){t.open();var Ft=document.compatMode==U?V:W;t.write(Ft+X),t.close()}}}function w(ln){function Ft(z){function Ke(){return typeof o.readyState==Y?typeof o.body!=Y&&o.body!=null:/loaded|complete/.test(o.readyState)}var ve=Ke();if(ve){z();return}function Ae(){if(!ve){if(!Ke())return;ve=!0,z(),o.removeEventListener&&o.removeEventListener(Z,Ae,!1),ye&&clearInterval(ye)}}o.addEventListener&&o.addEventListener(Z,Ae,!1);var ye=setInterval(function(){Ae()},$)}function ie(z){var Ke=u(),ve=Ke.body,Ae=Ke.createElement(_);Ae.language=ab,Ae.crossOrigin=W,Ae.src=z,webModule.__errFn&&(Ae.onerror=function(){webModule.__errFn(L,new Error(bb+z))}),ve.appendChild(Ae)}Ft(function(){ie(ln)})}webModule.__startLoadingFragment=function(ln){return C(ln)},webModule.__installRunAsyncCode=function(ln){var Ft=u(),ie=Ft.body,z=Ft.createElement(_);z.language=ab,z.text=ln,ie.appendChild(z),ie.removeChild(z)};function A(){for(var c={},d,e,f=o.getElementsByTagName(fb),g=O,h=f.length;g<h;++g){var i=f[g],j=i.getAttribute(gb),k;if(j){if(j=j.replace(hb,W),j.indexOf(ib)>=O)continue;if(j==jb){if(k=i.getAttribute(kb),k){var l,m=k.indexOf(lb);m>=O?(j=k.substring(O,m),l=k.substring(m+P)):(j=k,l=W),c[j]=l}}else if(j==mb){if(k=i.getAttribute(kb),k)try{d=eval(k)}catch(ln){alert(nb+k+ob)}}else if(j==pb&&(k=i.getAttribute(kb),k))try{e=eval(k)}catch(ln){alert(nb+k+qb)}}}__gwt_getMetaProperty=function(ln){var Ft=c[ln];return Ft==null?null:Ft},r=d,webModule.__errFn=e}function B(){function ln(ye){var be=ye.lastIndexOf(rb);be==-1&&(be=ye.length);var Me=ye.indexOf(sb);Me==-1&&(Me=ye.length);var Re=ye.lastIndexOf(tb,Math.min(Me,be));return Re>=O?ye.substring(O,Re+P):W}function Ft(ye){if(!ye.match(/^\w+:\/\//)){var be=o.createElement(ub);be.src=ye+vb,ye=ln(be.src)}return ye}function ie(){var ye=__gwt_getMetaProperty(wb);return ye!=null?ye:W}function z(){for(var ye=o.getElementsByTagName(_),be=O;be<ye.length;++be)if(ye[be].src.indexOf(xb)!=-1)return ln(ye[be].src);return W}function Ke(){var ye=o.getElementsByTagName(yb);return ye.length>O?ye[ye.length-P].href:W}function ve(){var ye=o.location;return ye.href==ye.protocol+zb+ye.host+ye.pathname+ye.search+ye.hash}var Ae=ie();return Ae==W&&(Ae=z()),Ae==W&&(Ae=Ke()),Ae==W&&ve()&&(Ae=ln(o.location.href)),Ae=Ft(Ae),Ae}function C(ln){return ln.match(/^\//)||ln.match(/^[a-zA-Z]+:\/\//)?ln:webModule.__moduleBase+ln}function D(){var ln=[],Ft=O,ie=[],z=[];function Ke(ye){var be=z[ye](),Me=ie[ye];if(be in Me)return be;var Re=[];for(var Oe in Me)Re[Me[Oe]]=Oe;throw r&&r(ye,Re,be),null}if(__gwt_isKnownPropertyValue=function(ye,be){return be in ie[ye]},webModule.__getPropMap=function(){var ye={};for(var be in ie)ie.hasOwnProperty(be)&&(ye[be]=Ke(be));return ye},webModule.__computePropValue=Ke,n.__gwt_activeModules[L].bindings=webModule.__getPropMap,p())return C(Bb);var ve;try{ve=Cb;var Ae=ve.indexOf(Db);Ae!=-1&&(Ft=parseInt(ve.substring(Ae+P),$),ve=ve.substring(O,Ae))}catch(ye){}return webModule.__softPermutationId=Ft,C(ve+Eb)}function F(){n.__gwt_stylesLoaded||(n.__gwt_stylesLoaded={})}A(),webModule.__moduleBase="/js/mathematicalGraphics/"+name+"/",s[L].moduleBase=webModule.__moduleBase;var G=D();return F(),w(G),!0}return webModule},typeof window.web3d!="function"&&(window.web3d=GGBAppletUtils.makeModule("web3d","A18F540516513B1292CA7CEF2F6AFC7E")),typeof window.webSimple!="function"&&(window.webSimple=GGBAppletUtils.makeModule("webSimple","96B09BF1B436BF53F0DF54116700F16A")),window.GGBApplet=GGBApplet})()},28735:function(ln,Ft,ie){"use strict";ie.d(Ft,{Ax:function(){return Ae},Ds:function(){return ye},KI:function(){return Me},SI:function(){return ve},f1:function(){return Ke}});var z=ie(74128);function Ke(Re){let Oe=!0;if(Re.length>0){for(let fe=0;fe<Re.length;fe++)if(Re[fe].compile_success==0||!Re[fe].compile_success){Oe=!1;break}}else Oe=!1;return Oe}function ve(Re,Oe=""){let fe=[];for(let We=0;We<Re.length;We++){let Se=Re[We],yt=Oe?`${Oe}/${Se.name}`:`${Se.name}`;fe.push({title:Se.name,type:Se.type,isLeaf:Se.type!=="tree",key:yt})}return fe}function Ae(Re,Oe,fe){for(let We=0;We<Re.length;We++){let Se=Re[We];if(Se.key===Oe){Se.children=fe;break}Se.children&&Ae(Se.children,Oe,fe)}return Re}function ye(Re,Oe,fe){let We;return function(){let Se=this,yt=arguments,Xe=function(){We=null,fe||Re.apply(Se,yt)},Le=fe&&!We;clearTimeout(We),We=setTimeout(Xe,Oe),Le&&Re.apply(Se,yt)}}const be=!0,Me=z.Z.API_SERVER},16750:function(ln,Ft,ie){"use strict";ie.d(Ft,{Z:function(){return We}});var z=ie(59301),Ke={imageDimensions:"imageDimensions___a7crR",img:"img___Kroat",fullWidth:"fullWidth___c492T"},ve=ie(92310),Ae=ie.n(ve),ye=ie(29787),be=ie(2859),Me=ie(38147),Re=ie(65862),Oe=(Se,yt,Xe)=>new Promise((Le,Ge)=>{var Ne=Bt=>{try{It(Xe.next(Bt))}catch(mt){Ge(mt)}},dt=Bt=>{try{It(Xe.throw(Bt))}catch(mt){Ge(mt)}},It=Bt=>Bt.done?Le(Bt.value):Promise.resolve(Bt.value).then(Ne,dt);It((Xe=Xe.apply(Se,yt)).next())}),We=({data:Se,className:yt,fullWidth:Xe,style:Le={},onClose:Ge,onOk:Ne,showFullTools:dt,noAssociationId:It})=>{const Bt=(0,z.useRef)(null),mt=(0,z.useRef)(null),st=(0,z.useRef)(null),it=(0,z.useRef)(null),[je,Ot]=(0,z.useState)(!1),[nt,tt]=(0,z.useState)("\u6B63\u5728\u52A0\u8F7D\u4E2D");(0,z.useEffect)(()=>(st.current||(st.current=document.createElement("style"),document.head.appendChild(st.current)),Se!=null&&Se.visible?(document.body.setAttribute("data-custom","y-hidden"),st.current.innerHTML=" html { overflow-y: hidden; }",Se!=null&&Se.src&&ht()):(document.body.removeAttribute("data-custom"),st.current&&(document.head.removeChild(st.current),st.current=null)),()=>{document.body.removeAttribute("data-custom"),st.current&&(document.head.removeChild(st.current),st.current=null)}),[Se==null?void 0:Se.visible]);const ht=()=>Oe(void 0,null,function*(){Ot(!0),tt("\u6B63\u5728\u52A0\u8F7D\u4E2D");const me=yield(0,Re.ZJ)(Se==null?void 0:Se.src);Bt.current.src="",Bt.current.src=me,Bt.current.onload=function(){lt()},Ot(!1),tt("")}),$e=me=>Oe(void 0,null,function*(){Ot(!0),tt("\u6B63\u5728\u4FDD\u5B58\u4E2D");const At=yield(0,Me.ZP)("/api/attachments.json",{method:"post",body:{file_type:"base64",original_filename:Se.title,file:me.dataUrl}});At!=null&&At.id&&!It?(yield(0,Me.ZP)(`/api/attachments/${Se.id}/add_subitem.json`,{method:"post",body:{subitem_id:At==null?void 0:At.id,settings:JSON.stringify(me.state)}})).status===0&&Ne():At!=null&&At.id&&Ne(At),Ot(!1),tt("")}),at=()=>{const me=document.querySelector('a[href="https://markerjs.com/"]');me&&me.parentNode&&(me.parentNode.style.display="none"),[{name:'[data-action="select"]',title:"\u9009\u62E9"},{name:'[data-action="delete"]',title:"\u5220\u9664\u5143\u7D20"},{name:'[data-action="undo"]',title:"\u64A4\u9500"},{name:'[data-type-name="FrameMarker"]',title:"\u77E9\u5F62"},{name:'[data-type-name="FreehandMarker"]',title:"\u753B\u7EBF"},{name:'[data-type-name="ArrowMarker"]',title:"\u7BAD\u5934"},{name:'[data-type-name="TextMarker"]',title:"\u6587\u672C"},{name:'[data-type-name="EllipseMarker"]',title:"\u692D\u5706"},{name:'[data-type-name="HighlightMarker"]',title:"\u65B9\u5757"},{name:'[data-type-name="CalloutMarker"]',title:"\u6CE8\u91CA"},{name:'[data-action="render"]',title:"\u4FDD\u5B58"},{name:'[data-action="close"]',title:"\u9000\u51FA"}].forEach(De=>{const He=document.querySelector(De.name);He&&He.setAttribute("title",De.title)})},lt=()=>{mt.current=new be.hP(Bt.current),mt.current.targetRoot=it.current,mt.current.addEventListener("render",$e),mt.current.addEventListener("beforeclose",Ge),dt&&(mt.current.availableMarkerTypes=mt.current.ALL_MARKER_TYPES,mt.current.uiStyleSettings.redoButtonVisible=!0,mt.current.uiStyleSettings.notesButtonVisible=!0,mt.current.uiStyleSettings.zoomButtonVisible=!0,mt.current.uiStyleSettings.zoomOutButtonVisible=!0,mt.current.uiStyleSettings.clearButtonVisible=!0),window.markerArea=mt.current.uiStyleSettings,mt.current.show(),Se!=null&&Se.snapshotData&&mt.current.restoreState(Se.snapshotData),setTimeout(()=>{window.scrollTo(0,0),at()},300)};return z.createElement(z.Fragment,null,(Se==null?void 0:Se.visible)&&z.createElement(ye.Z,{spinning:je,tip:nt,style:{position:"absolute",width:"100vw"}},z.createElement("div",{ref:it,className:Ae()(Ke.imageDimensions,yt,Xe?Ke.fullWidth:""),style:Le},z.createElement("img",{className:Ke.img,ref:Bt}))))}},99298:function(ln,Ft,ie){"use strict";var z=ie(59301),Ke=ie(77019),ve=ie(5269),Ae=ie(31691),ye=ie(7939),be=ie(95097),Me=ie(96408),Re=ie(48136),Oe=ie(59301);const fe=(0,z.forwardRef)(({callback:We,showSaveButton:Se,value:yt=""},Xe)=>{const Le=(0,z.useRef)(),Ge=[{name:"\u5206\u6570\u5F97\u5206",value:"\\frac{x}{y}",children:[{name:"\u5206\u6570 Fractions",data:[{value:"\\frac{a}{b}"},{value:"x\\tfrac{x}{a} "},{value:"\\mathrm{d}t"},{value:"\\partial t"},{value:"\\frac{\\partial y}{\\partial x}"},{value:"\\nabla\\psi"},{value:"\\frac{\\partial^2}{\\partial x_1\\partial x_2}y"},{value:"\\cfrac{1}{a + \\cfrac{7}{b + \\cfrac{2}{9}}} = c"}]},{name:"\u5BFC\u6570 Derivative",data:[{value:"\\dot{a} "},{value:"\\ddot{a}"},{value:"{f}^{\\prime}"},{value:"{f}^{\\prime\\prime}"},{value:"{f}^{(n)}"}]},{name:"\u6A21\u7B97\u672F Modular arithmetic",data:[{value:"a \\bmod b"},{value:"a \\equiv b \\pmod{m} "},{value:"\\gcd(m, n) "},{value:"\\operatorname{lcm}(m, n) "}]}]},{name:"\u6839\u5F0F\u89D2\u6807",value:"\\sqrt{x}",children:[{name:"\u6839\u5F0F Radicals",data:[{value:"\\sqrt{x}"},{value:"\\sqrt[y]{x}"}]},{name:"\u4E0A\u4E0B\u6807 Sub&Super",data:[{value:"x^{a}"},{value:"x_{a}"},{value:"x_{a}^{b} "},{value:"_{a}^{b} x"},{value:"x_{a}^{b} "}]},{name:"\u91CD\u97F3\u7B26\u53CA\u5176\u4ED6 Accents and Others",data:[{value:"\\hat{a} "},{value:"\\sqrt[y]{x}"},{value:"\\check{} "},{value:"\\grave{a} "},{value:"\\acute{a}"},{value:"\\tilde{a}"},{value:"\\breve{a}"},{value:"\\bar{a}"},{value:"\\vec{a}"},{value:"\\not{a}"},{value:"\\widetilde{abc}"},{value:"\\widehat{abc}"},{value:"\\overleftarrow{abc} "},{value:"\\overrightarrow{abc}"},{value:"\\overline{abc}"},{value:"\\underline{abc}"},{value:"\\overbrace{abc}"},{value:"\\underbrace{abc}"},{value:"\\overset{a}{abc}"},{value:"\\underset{a}{abc} \\stackrel\\frown{ab}"},{value:"\\overline{ab} "},{value:"\\overleftrightarrow{ab}"},{value:"\\overset{a}{\\leftarrow}"},{value:"\\overset{a}{\\rightarrow}"},{value:"\\xleftarrow[abc]{a}"},{value:"\\xrightarrow[abc]{a} "}]}]},{name:"\u6781\u9650\u5BF9\u6570",value:"\\lim_{x \\to 0}",children:[{name:"\u6781\u9650 Limits",data:[{value:"\\lim a"},{value:"\\lim_{x \\to 0}"},{value:"\\lim_{x \\to \\infty}"},{value:"\\max_b{a}"},{value:"\\min_a{b}"}]},{name:"\u5BF9\u6570\u6307\u6570 Logarithms and exponentials",data:[{value:"\\log_{a}{b}"},{value:"\\lg_{a}{b}"},{value:"\\ln_{a}{b}"},{value:"\\exp a"}]},{name:"\u754C\u9650 Bounds",data:[{value:"\\min x"},{value:"\\sup t"},{value:"\\inf s"},{value:"\\lim u"},{value:"\\limsup w"},{value:"\\dim p"},{value:"\\ker\\phi "}]}]},{name:"\u4E09\u89D2\u51FD\u6570",value:"\\sin a",children:[{name:"\u4E09\u89D2\u51FD\u6570 Trigonometric functions",data:[{value:"\\sin a"},{value:"\\cos a"},{value:"\\tan a"},{value:"\\cot a "},{value:"\\sec a "},{value:"\\csc a "}]},{name:"\u53CD\u4E09\u89D2\u51FD\u6570 Inverse trigonometric functions",data:[{value:"\\sin^{-1}"},{value:"\\cos^{-1}"},{value:"\\tan^{-1}"},{value:"\\cot^{-1}"},{value:"\\sec^{-1}"},{value:"\\csc^{-1}"},{value:"\\arcsin a"},{value:"\\arccos a"},{value:"\\arctan a"},{value:"\\operatorname{arccot} a"},{value:"\\operatorname{arcsec} a"},{value:"\\operatorname{arccsc} a"}]},{name:"\u53CC\u66F2\u51FD\u6570 Hyperblic functions",data:[{value:"\\sinh a"},{value:"\\cosh a"},{value:"\\tanh a"},{value:"\\coth a"},{value:"\\operatorname{sech} a"},{value:"\\operatorname{csch} a"}]},{name:"\u53CD\u53CC\u66F2\u51FD\u6570 Inverse hyperbolic functions",data:[{value:"\\sinh^{-1}"},{value:"a\\cosh^{-1} a"},{value:"\\tanh^{-1} a"},{value:"\\coth^{-1} a"},{value:"\\operatorname{sech}^{-1} a"},{value:"\\operatorname{csch}^{-1} a"}]}]},{name:"\u79EF\u5206\u8FD0\u7B97",value:"\\int_{a}^{b}",children:[{name:"\u79EF\u5206 Integral",data:[{value:"\\int"},{value:"\\int_{a}^{b}"},{value:"\\int\\limits_{a}^{b}"}]},{name:"\u53CC\u91CD\u79EF\u5206 Double integral",data:[{value:"\\iint"},{value:"\\iint_{a}^{b} "},{value:"\\iint\\limits_{a}^{b} "}]},{name:"\u4E09\u91CD\u79EF\u5206 Triple integral",data:[{value:"\\iiint"},{value:"\\iiint_{a}^{b}"},{value:"\\iiint\\limits_{a}^{b} "}]},{name:"\u66F2\u7EBF\u79EF\u5206 Closed line or path integral",data:[{value:"\\oint"},{value:"\\oint_{a}^{b} "}]}]},{name:"\u5927\u578B\u8FD0\u7B97",value:"\\sum_{a}^{b}",children:[{name:"\u6C42\u548C Summation",data:[{value:"\\sum"},{value:"\\sum_{a}^{b}"},{value:"{\\textstyle \\sum_{a}^{b}} "}]},{name:"\u4E58\u79EF\u4F59\u79EF Product and coproduct",data:[{value:"\\prod"},{value:"\\prod_{a}^{b}"},{value:"{\\textstyle \\prod_{a}^{b}}"},{value:"\\coprod"},{value:"\\coprod_{a}^{b}"},{value:"{\\textstyle \\coprod_{a}^{b}} "}]},{name:"\u5E76\u96C6\u4EA4\u96C6 Union and intersection",data:[{value:"\\bigcup"},{value:"\\bigcup_{a}^{b}"},{value:"{\\textstyle \\bigcup_{a}^{b}}"},{value:"\\bigcap"},{value:"\\bigcap_{a}^{b}"}]},{name:"\u6790\u53D6\u5408\u53D6 Disjunction and conjunction",data:[{value:"\\bigvee"},{value:"\\bigvee_{a}^{b}"},{value:"\\bigwedge"},{value:"\\bigwedge_{a}^{b}"}]}]},{name:"\u62EC\u53F7\u53D6\u6574",value:"\\left [ \\left ( \\right ) \\right ] ",children:[{name:"\u62EC\u53F7 Brackets",data:[{value:"\\left ( \\right )"},{value:"\\left [ \\right ]"},{value:"\\left \\langle \\right \\rangle "},{value:"\\left | \\right | "},{value:"\\left \\lfloor \\right \\rfloor "},{value:"\\left \\lceil \\right \\rceil "}]}]}],Ne=[{name:"\u4EE3\u6570",value:"\\sqrt{a^2+b^2}",children:[{data:[{value:"\\left(x-1\\right)\\left(x+3\\right) "},{value:"\\sqrt{a^2+b^2}"},{value:"\\left ( \\frac{a}{b}\\right )^{n}= \\frac{a^{n}}{b^{n}}"},{value:"\\frac{a}{b}\\pm \\frac{c}{d}= \\frac{ad \\pm bc}{bd} "},{value:"\\frac{x^{2}}{a^{2}}-\\frac{y^{2}}{b^{2}}=1 "},{value:"\\frac{1}{\\sqrt{a}}=\\frac{\\sqrt{a}}{a},a\\ge 0\\frac{1}{\\sqrt{a}}=\\frac{\\sqrt{a}}{a},a\\ge 0 "},{value:"\\sqrt[n]{a^{n}}=\\left ( \\sqrt[n]{a}\\right )^{n} "},{value:"x ={-b \\pm \\sqrt{b^2-4ac}\\over 2a} "},{value:"y-y_{1}=k \\left( x-x_{1}\\right) "},{value:`\\left\\{\\begin{matrix} \r
|
|
|
x=a + r\\text{cos}\\theta \\ \r
|
|
|
y=b + r\\text{sin}\\theta \r
|
|
|
\\end{matrix}\\right. `},{value:`\\begin{array}{l} \r
|
|
|
\\text{\u5BF9\u4E8E\u65B9\u7A0B\u5F62\u5982\uFF1A}x^{3}-1=0 \\ \r
|
|
|
\\text{\u8BBE}\\text{:}\\omega =\\frac{-1+\\sqrt{3}i}{2} \\ \r
|
|
|
x_{1}=1,x_{2}= \\omega =\\frac{-1+\\sqrt{3}i}{2} \\ \r
|
|
|
x_{3}= \\omega ^{2}=\\frac{-1-\\sqrt{3}i}{2} \r
|
|
|
\\end{array} `},{value:`\\begin{array}{l} \r
|
|
|
a\\mathop{{x}}\\nolimits^{{2}}+bx+c=0 \\ \r
|
|
|
\\Delta =\\mathop{{b}}\\nolimits^{{2}}-4ac \\ \r
|
|
|
\\left\\{\\begin{matrix} \r
|
|
|
\\Delta \\gt 0\\text{\u65B9\u7A0B\u6709\u4E24\u4E2A\u4E0D\u76F8\u7B49\u7684\u5B9E\u6839} \\ \r
|
|
|
\\Delta = 0\\text{\u65B9\u7A0B\u6709\u4E24\u4E2A\u76F8\u7B49\u7684\u5B9E\u6839} \\ \r
|
|
|
\\Delta \\lt 0\\text{\u65B9\u7A0B\u65E0\u5B9E\u6839} \r
|
|
|
\\end{matrix}\\right. \r
|
|
|
\\end{array} `},{value:`\\begin{array}{l} \r
|
|
|
a\\mathop{{x}}\\nolimits^{{2}}+bx+c=0 \\ \r
|
|
|
\\Delta =\\mathop{{b}}\\nolimits^{{2}}-4ac \\ \r
|
|
|
\\mathop{{x}}\\nolimits_{{1,2}}=\\frac{{-b \\pm \r
|
|
|
\\sqrt{{\\mathop{{b}}\\nolimits^{{2}}-4ac}}}}{{2a}} \\ \r
|
|
|
\\mathop{{x}}\\nolimits_{{1}}+\\mathop{{x}}\\nolimits_{{2}}=-\\frac{{b}}{{a}} \\ \r
|
|
|
\\mathop{{x}}\\nolimits_{{1}}\\mathop{{x}}\\nolimits_{{2}}=\\frac{{c}}{{a}} \r
|
|
|
\\end{array} `}]}]},{name:"\u51E0\u4F55",value:"\\Delta A B C ",children:[{data:[{value:"\\Delta A B C "},{value:"a \\parallel c,b \\parallel c \\Rightarrow a \\parallel b "},{value:"l \\perp \\beta ,l \\subset \\alpha \\Rightarrow \\alpha \\perp \\beta"},{value:`\\left.\\begin{matrix} \r
|
|
|
a \\perp \\alpha \\ \r
|
|
|
b \\perp \\alpha \r
|
|
|
\\end{matrix}\\right\\}\\Rightarrow a \\parallel b`},{value:"P \\in \\alpha ,P \\in \\beta , \\alpha \\cap \\beta =l \\Rightarrow P \\in l "},{value:`\\alpha \\perp \\beta , \\alpha \\cap \\beta =l,a \\subset \\alpha ,a \\perp l \r
|
|
|
\\Rightarrow a \\perp \\beta `},{value:`\\left.\\begin{matrix} \r
|
|
|
a \\subset \\beta ,b \\subset \\beta ,a \\cap b=P \\ \r
|
|
|
a \\parallel \\partial ,b \\parallel \\partial \r
|
|
|
\\end{matrix}\\right\\}\\Rightarrow \\beta \\parallel \\alpha `},{value:"\\alpha \\parallel \\beta , \\gamma \\cap \\alpha =a, \\gamma \\cap \\beta =b \\Rightarrow a \\parallel b "},{value:"A \\in l,B \\in l,A \\in \\alpha ,B \\in \\alpha \\Rightarrow l \\subset \\alpha "},{value:`\\left.\\begin{matrix} \r
|
|
|
m \\subset \\alpha ,n \\subset \\alpha ,m \\cap n=P \\ \r
|
|
|
a \\perp m,a \\perp n \r
|
|
|
\\end{matrix}\\right\\}\\Rightarrow a \\perp \\alpha `},{value:`\\begin{array}{c} \r
|
|
|
\\text{\u76F4\u89D2\u4E09\u89D2\u5F62\u4E2D,\u76F4\u89D2\u8FB9\u957Fa,b,\u659C\u8FB9\u8FB9\u957Fc} \\ \r
|
|
|
a^{2}+b^{2}=c^{2} \r
|
|
|
\\end{array}`}]}]},{name:"\u4E0D\u7B49\u5F0F",value:"a > b",children:[{data:[{value:"a > b,b > c \\Rightarrow a > c "},{value:"a > b,c > d \\Rightarrow a+c > b+d "},{value:"a > b > 0,c > d > 0 \\Rightarrow ac bd "},{value:`\\begin{array}{c} \r
|
|
|
a \\gt b,c \\gt 0 \\Rightarrow ac \\gt bc \\ \r
|
|
|
a \\gt b,c \\lt 0 \\Rightarrow ac \\lt bc \r
|
|
|
\\end{array}`},{value:"\\left | a-b \\right | \\geqslant \\left | a \\right | -\\left | b \\right | "},{value:"-\\left | a \\right |\\leq a\\leqslant \\left | a \\right | "},{value:"\\left | a \\right |\\leqslant b \\Rightarrow -b \\leqslant a \\leqslant \\left | b \\right | "},{value:"\\left | a+b \\right | \\leqslant \\left | a \\right | + \\left | b \\right | "},{value:`\\begin{array}{c} \r
|
|
|
a \\gt b \\gt 0,n \\in N^{\\ast},n \\gt 1 \\ \r
|
|
|
\\Rightarrow a^{n}\\gt b^{n}, \\sqrt[n]{a}\\gt \\sqrt[n]{b} \r
|
|
|
\\end{array}`},{value:`\\left( \\sum_{k=1}^n a_k b_k \\right)^{\\!\\!2}\\leq \r
|
|
|
\\left( \\sum_{k=1}^n a_k^2 \\right) \\left( \\sum_{k=1}^n b_k^2 \\right) `},{value:`\\begin{array}{c} \r
|
|
|
a,b \\in R^{+} \\ \r
|
|
|
\\Rightarrow \\frac{a+b}{{2}}\\ge \\sqrt{ab} \\ \r
|
|
|
\\left( \\text{\u5F53\u4E14\u4EC5\u5F53}a=b\\text{\u65F6\u53D6\u201C}=\\text{\u201D\u53F7}\\right) \r
|
|
|
\\end{array}`},{value:`\\begin{array}{c} \r
|
|
|
a,b \\in R \\ \r
|
|
|
\\Rightarrow a^{2}+b^{2}\\gt 2ab \\ \r
|
|
|
\\left( \\text{\u5F53\u4E14\u4EC5\u5F53}a=b\\text{\u65F6\u53D6\u201C}=\\text{\u201D\u53F7}\\right) \r
|
|
|
\\end{array}`},{value:`\\begin{array}{c} \r
|
|
|
H_{n}=\\frac{n}{\\sum \\limits_{i=1}^{n}\\frac{1}{x_{i}}}= \\frac{n}{\\frac{1}{x_{1}}+ \\frac{1}{x_{2}}+ \\cdots + \\frac{1}{x_{n}}} \\ G_{n}=\\sqrt[n]{\\prod \\limits_{i=1}^{n}x_{i}}= \\sqrt[n]{x_{1}x_{2}\\cdots x_{n}} \\ A_{n}=\\frac{1}{n}\\sum \\limits_{i=1}^{n}x_{i}=\\frac{x_{1}+ x_{2}+ \\cdots + x_{n}}{n} \\ Q_{n}=\\sqrt{\\sum \\limits_{i=1}^{n}x_{i}^{2}}= \\sqrt{\\frac{x_{1}^{2}+ x_{2}^{2}+ \\cdots + x_{n}^{2}}{n}} \\ H_{n}\\leq G_{n}\\leq A_{n}\\leq Q_{n} \r
|
|
|
\\end{array}`}]}]},{name:"\u79EF\u5206",value:"\\frac{\\mathrm{d}\\partial}{\\partial x}",children:[{data:[{value:"\\frac{\\mathrm{d}}{\\mathrm{d}x}x^n=nx^{n-1} "},{value:"\\frac{\\mathrm{d}}{\\mathrm{d}x}e^{ax}=a\\,e^{ax} "},{value:"\\frac{\\mathrm{d}}{\\mathrm{d}x}\\ln(x)=\\frac{1}{x} "},{value:"\\frac{\\mathrm{d}}{\\mathrm{d}x}\\sin x=\\cos x "},{value:"\\frac{\\mathrm{d}}{\\mathrm{d}x}\\cos x=-\\sin x "},{value:"\\int k\\mathrm{d}x = kx+C "},{value:"\\frac{\\mathrm{d}}{\\mathrm{d}x}\\tan x=\\sec^2 x "},{value:"\\frac{\\mathrm{d}}{\\mathrm{d}x}\\cot x=-\\csc^2 x "},{value:"\\int \\frac{1}{x}\\mathrm{d}x= \\ln \\left| x \\right| +C "},{value:"\\int \\frac{1}{\\sqrt{1-x^{2}}}\\mathrm{d}x= \\arcsin x +C "},{value:"\\int \\frac{1}{1+x^{2}}\\mathrm{d}x= \\arctan x +C "},{value:"\\int u \\frac{\\mathrm{d}v}{\\mathrm{d}x}\\,\\mathrm{d}x=uv-\\int \\frac{\\mathrm{d}u}{\\mathrm{d}x}v\\,\\mathrm{d}x "},{value:"f(x) = \\int_{-\\infty}^\\infty \\hat f(x)\\xi\\,e^{2 \\pi i \\xi x} \\,\\mathrm{d}\\xi "},{value:"\\int x^{\\mu}\\mathrm{d}x=\\frac{x^{\\mu +1}}{\\mu +1}+C, \\left({\\mu \\neq -1}\\right) "}]}]},{name:"\u4E09\u89D2",value:"e^{i \\theta}",children:[{name:"\u6C42\u548C Summation",data:[{value:"e^{i \\theta} "},{value:"\\left(\\frac{\\pi}{2}-\\theta \\right ) "},{value:"\\text{sin}^{2}\\frac{\\alpha}{2}=\\frac{1- \\text{cos}\\alpha}{2} "},{value:"\\text{cos}^{2}\\frac{\\alpha}{2}=\\frac{1+ \\text{cos}\\alpha}{2} "},{value:"\\text{tan}\\frac{\\alpha}{2}=\\frac{\\text{sin}\\alpha}{1+ \\text{cos}\\alpha} "},{value:"\\sin \\alpha + \\sin \\beta =2 \\sin \\frac{\\alpha + \\beta}{2}\\cos \\frac{\\alpha - \\beta}{2} "},{value:"\\sin \\alpha - \\sin \\beta =2 \\cos \\frac{\\alpha + \\beta}{2}\\sin \\frac{\\alpha - \\beta}{2} "},{value:"\\cos \\alpha + \\cos \\beta =2 \\cos \\frac{\\alpha + \\beta}{2}\\cos \\frac{\\alpha - \\beta}{2} "},{value:"\\cos \\alpha - \\cos \\beta =-2\\sin \\frac{\\alpha + \\beta}{2}\\sin \\frac{\\alpha - \\beta}{2} "},{value:"a^{2}=b^{2}+c^{2}-2bc\\cos A "},{value:"\\frac{\\sin A}{a}=\\frac{\\sin B}{b}=\\frac{\\sin C}{c}=\\frac{1}{2R} "},{value:"\\sin \\left ( \\frac{\\pi}{2}-\\alpha \\right ) = \\cos \\alpha "},{value:"\\sin \\left ( \\frac{\\pi}{2}+\\alpha \\right ) = \\cos \\alpha "}]}]},{name:"\u7EDF\u8BA1",value:"C_{r}^{n}",children:[{data:[{value:"C_{r}^{n} "},{value:"\\frac{n!}{r!(n-r)!} "},{value:"\\sum_{i=1}^{n}{X_i} "},{value:"\\sum_{i=1}^{n}{X_i^2} "},{value:"X_1, \\cdots,X_n "},{value:"\\frac{x-\\mu}{\\sigma} "},{value:"\\sum_{i=1}^{n}{(X_i - \\overline{X})^2} "},{value:`\\begin{array}{c} \r
|
|
|
\\text{\u82E5}P \\left( AB \\right) =P \\left( A \\right) P \\left( B \\right) \\\\ \r
|
|
|
\\text{\u5219}P \\left( A \\left| B\\right. \\right) =P \\left({B}\\right) \r
|
|
|
\\end{array}`},{value:"P(E) ={n \\choose k}p^k (1-p)^{n-k} "},{value:"P \\left( A \\right) = \\lim \\limits_{n \\to \\infty}f_{n}\\left ( A \\right ) "},{value:"P \\left( \\bigcup \\limits_{i=1}^{+ \\infty}A_{i}\\right) = \\prod \\limits_{i=1}^{+ \\infty}P{\\left( A_{i}\\right)} "},{value:`\\begin{array}{c} \r
|
|
|
P \\left( \\emptyset \\right) =0 \\\\ \r
|
|
|
P \\left( S \\right) =1 \r
|
|
|
\\end{array}`},{value:`\\begin{array}{c} \r
|
|
|
\\forall A \\in S \\\\ \r
|
|
|
P \\left( A \\right) \\ge 0 \r
|
|
|
\\end{array}`},{value:"P \\left( \\bigcup \\limits_{i=1}^{n}A_{i}\\right) = \\prod \\limits_{i=1}^{n}P \\left( A_{i}\\right) "},{value:`\\begin{array}{c} \r
|
|
|
S= \\binom{N}{n},A_{k}=\\binom{M}{k}\\cdot \\binom{N-M}{n-k} \\\\ \r
|
|
|
P\\left ( A_{k}\\right ) = \\frac{\\binom{M}{k}\\cdot \\binom{N-M}{n-k}}{\\binom{N}{n}} \r
|
|
|
\\end{array}`},{value:`\\begin{array}{c} \r
|
|
|
P_{n}=n! \\\\ \r
|
|
|
A_{n}^{k}=\\frac{n!}{\\left( n-k \\left) !\\right. \\right.} \r
|
|
|
\\end{array}`}]}]}],dt=mt=>{Le.current.setValue(Le.current.getValue()+" "+mt.value+" ")},It=[{key:"1",label:"\u5FEB\u6377\u6A21\u677F",children:Oe.createElement(Ke.Z,{className:Me.Z.lists,gutter:[10,10]},Ge.map((mt,st)=>Oe.createElement(ve.Z,{flex:"110px",className:Me.Z.item},Oe.createElement("div",null,Oe.createElement(be.Z,{value:`$$${mt.value}$$`}),mt.name),Oe.createElement("div",{className:Me.Z.children},mt.children.map((it,je)=>Oe.createElement("div",{key:je},Oe.createElement("h1",null,it.name),Oe.createElement(Ke.Z,{gutter:[10,10]},it.data.map((Ot,nt)=>Oe.createElement(ve.Z,{key:nt,onClick:()=>dt(Ot),className:Me.Z.diamond},Oe.createElement(be.Z,{value:"`$$"+Ot.value+"$$`"}))))))))))},{key:"2",label:"\u516C\u5F0F\u6A21\u677F",children:Oe.createElement(Ke.Z,{className:Me.Z.lists,gutter:[10,10]},Ne.map((mt,st)=>Oe.createElement(ve.Z,{flex:"110px",className:Me.Z.item},Oe.createElement("div",null,Oe.createElement(be.Z,{value:"`$$"+mt.value+"$$`"}),mt.name),Oe.createElement("div",{className:Me.Z.children},mt.children.map((it,je)=>Oe.createElement("div",{key:je},it.name&&Oe.createElement("h1",null,it.name),Oe.createElement(Ke.Z,{gutter:[10,10]},it.data.map((Ot,nt)=>Oe.createElement(ve.Z,{key:nt,onClick:()=>dt(Ot),className:Me.Z.diamond},Oe.createElement(be.Z,{value:"`$$"+Ot.value+"$$`"}))))))))))}],Bt=()=>{var mt=document.createElement("div");mt.innerHTML=Le.current.getValue();var st=mt.innerText;return We&&We(st),st};return(0,z.useImperativeHandle)(Xe,()=>({getData:Bt})),Oe.createElement("div",{className:Me.Z.mathWrap},Oe.createElement(Ae.default,{defaultActiveKey:"1",items:It}),Oe.createElement("math-field",{locale:"zh_cn",className:Me.Z.mathField,placeholder:"\u8BF7\u6253\u5F00\u952E\u76D8\uFF0C\u8F93\u5165\u516C\u5F0F",ref:Le,style:{width:800,marginTop:30,fontSize:18}},yt||""),Se&&Oe.createElement("div",{className:Me.Z.button},Oe.createElement(ye.ZP,{size:"large",onClick:Bt,style:{zIndex:8,marginTop:10},type:"primary"},"\u4FDD\u5B58\u5230\u7F16\u8F91\u5668")))});Ft.Z=fe},2524:function(ln,Ft,ie){"use strict";var z=ie(59301),Ke=ie(93314),ve=ie(7939),Ae=Object.defineProperty,ye=Object.defineProperties,be=Object.getOwnPropertyDescriptors,Me=Object.getOwnPropertySymbols,Re=Object.prototype.hasOwnProperty,Oe=Object.prototype.propertyIsEnumerable,fe=(Xe,Le,Ge)=>Le in Xe?Ae(Xe,Le,{enumerable:!0,configurable:!0,writable:!0,value:Ge}):Xe[Le]=Ge,We=(Xe,Le)=>{for(var Ge in Le||(Le={}))Re.call(Le,Ge)&&fe(Xe,Ge,Le[Ge]);if(Me)for(var Ge of Me(Le))Oe.call(Le,Ge)&&fe(Xe,Ge,Le[Ge]);return Xe},Se=(Xe,Le)=>ye(Xe,be(Le));const yt=({img:Xe,buttonProps:Le={},styles:Ge={},customText:Ne,ButtonText:dt,ButtonClick:It,Buttonclass:Bt,ButtonTwo:mt,imgStyles:st,loading:it=!1,className:je=""})=>z.createElement("section",{className:`tc animated fadeIn ${je}`,style:We({color:"#999",margin:"100px auto",visibility:it?"hidden":"visible"},Ge)},z.createElement("img",{src:Xe||Ke,style:Se(We({},st),{pointerEvents:"none",userSelect:"none"})}),z.createElement("p",{className:"mt20 font14"},Ne||"\u6682\u65F6\u8FD8\u6CA1\u6709\u76F8\u5173\u6570\u636E\u54E6!"),dt&&z.createElement(ve.ZP,We({className:Bt,onClick:It},Le),dt),mt&&mt);Ft.Z=yt},52918:function(ln,Ft,ie){"use strict";ie.d(Ft,{Z:function(){return Bt}});var z=ie(59301),Ke={wrp:"wrp___dq7YK",bgBlack:"bgBlack___ARIUV",monaco:"monaco___VnZC3",darkBlue:"darkBlue___UprA9",close:"close___LKoWu",embed:"embed___hvpEJ"},ve=ie(7939),Ae=ie(70557),ye=ie(50258),be=ie(25399),Me=ie(65862),Re=ie(87513),Oe=ie(2524),fe=ie(74128),We=ie(7310),Se=ie(59301),yt=Object.defineProperty,Xe=Object.getOwnPropertySymbols,Le=Object.prototype.hasOwnProperty,Ge=Object.prototype.propertyIsEnumerable,Ne=(mt,st,it)=>st in mt?yt(mt,st,{enumerable:!0,configurable:!0,writable:!0,value:it}):mt[st]=it,dt=(mt,st)=>{for(var it in st||(st={}))Le.call(st,it)&&Ne(mt,it,st[it]);if(Xe)for(var it of Xe(st))Ge.call(st,it)&&Ne(mt,it,st[it]);return mt},It=(mt,st,it)=>new Promise((je,Ot)=>{var nt=$e=>{try{ht(it.next($e))}catch(at){Ot(at)}},tt=$e=>{try{ht(it.throw($e))}catch(at){Ot(at)}},ht=$e=>$e.done?je($e.value):Promise.resolve($e.value).then(nt,tt);ht((it=it.apply(mt,st)).next())}),Bt=({editOffice:mt="view",data:st,issaver:it,onSaver:je,theme:Ot,type:nt,filename:tt,monacoEditor:ht,className:$e,style:at,close:lt,onClose:me,hasMask:At,disabledDownload:De,onImgDimensions:He,showNodata:Pt,recordInfo:ge})=>{const[ce,Je]=(0,z.useState)("https://view.officeapps.live.com/op/view.aspx?src=http://testgs.educoder.net//rails/active_storage/blobs/eyJfcmFpbHMiOnsibWVzc2FnZSI6IkJBaHBCZz09IiwiZXhwIjpudWxsLCJwdXIiOiJibG9iX2lkIn19--03541f6234b93d7ac3b2d84e7eb0e6594a952945/1.ppt"),[jt,wt]=(0,z.useState)(""),[Ie,Ue]=(0,z.useState)(),et=window.ENV==="build"?"/react/build":"",cn=location.host.startsWith("localhost")?fe.Z.PROXY_SERVER:fe.Z.API_SERVER,Yt=10*(1024*1024),ze=(0,z.useRef)();st!=null&&st.startsWith("/api")&&nt!=="txt"&&(st=fe.Z.API_SERVER+st);const zt=oe=>oe.substring(oe.lastIndexOf("/")+1).split(".").pop();tt&&ht&&(ht.filename=tt),(0,z.useEffect)(()=>{var oe,se;const ne=(se=(oe=document.cookie)==null?void 0:oe.replace(/\s/g,""))==null?void 0:se.split(";");ne==null||ne.map(he=>{let xe=he.split("=");xe[0]==="_educoder_session"&&wt(xe[1])})},[]),(0,z.useEffect)(()=>{nt==="office"&&(st.indexOf("bigfilescdn.")>-1||st.indexOf("bigfiles1")>-1?Ue({url:st,fileType:zt(st),model:st.indexOf("model=edit")?"edit":"view"}):ae())},[nt,st]);function ut(oe){return It(this,null,function*(){oe.data.type==="pdfdata"&&(je(oe.data.data),window.removeEventListener("message",ut,!1)),console.log("mess---:",oe.data)})}const ae=()=>It(void 0,null,function*(){console.log("data:",st);let oe=st;st.startsWith("http")||(oe=location.origin+oe);let se=new URL(oe).pathname.split("/").pop();const ne=yield(0,Re.gJ)({attachment_id:se});ne.url=cn+ne.url,Ue(ne)}),te=()=>{if(st.startsWith("http")||st.startsWith("blob:")){ee();return}(0,Me.Sv)(tt||"educoder",st,tt)},ee=()=>{ge&&(0,We.fc)({id:ge==null?void 0:ge.id,watch_type:1,course_id:ge==null?void 0:ge.course_id}),(0,Me.Nd)(tt||"educoder",decodeURIComponent(st))};return Se.createElement("div",{style:dt({},at||{}),className:`${At&&Ke.bgBlack} ${nt?Ke.wrp:"hide"}`},lt&&Se.createElement("div",{className:Ke.close,ref:ze},!!He&&Se.createElement(be.Z,{title:"\u70B9\u51FB\u5BF9\u56FE\u7247\u8FDB\u884C\u6279\u6CE8",getPopupContainer:()=>ze.current},Se.createElement("span",{onClick:()=>{me(),He()}},Se.createElement("i",{className:"icon-yulanpizhu"}))),!De&&Se.createElement(be.Z,{title:"\u70B9\u51FB\u4E0B\u8F7D\u6B64\u6587\u4EF6",getPopupContainer:()=>ze.current},Se.createElement("span",{onClick:ee},Se.createElement("i",{className:"icon-quxiaozhiding"}))),it&&Se.createElement(be.Z,{title:"\u4FDD\u5B58pdf\u5E76\u9000\u51FA",getPopupContainer:()=>ze.current},Se.createElement("span",{className:"",onClick:()=>{const oe=document.getElementById("pdfiframe");window.addEventListener("message",ut,!1),setTimeout(()=>{oe.contentWindow.postMessage("getData","*")},300)}},Se.createElement("i",{className:"icon-baocun"}))),Se.createElement(be.Z,{title:"\u5173\u95ED",getPopupContainer:()=>ze.current},Se.createElement("span",{className:"",onClick:()=>{me()}},Se.createElement("i",{className:"icon-guanbi1"})))),Se.createElement("div",{className:`${Ke[$e]} ${$e} ${Ke.monaco} ${nt==="txt"?"show":"hide"}`},nt==="txt"&&Se.createElement(Se.Fragment,null,Se.createElement(ye.ZP,dt({},ht)))),nt==="audio"&&Se.createElement("audio",{src:`${(st==null?void 0:st.indexOf("http://"))>-1||(st==null?void 0:st.indexOf("https://"))>-1?"":"data:audio/mp3;base64,"}${st}`,autoPlay:!0}),nt==="video"&&Se.createElement(Se.Fragment,null,(st==null?void 0:st.indexOf("http"))>-1?Se.createElement("video",{controls:!0,src:`${st}`,autoPlay:!0}):Se.createElement("video",{controls:!0,src:`data:video/mp4;base64,${st}`,autoPlay:!0})),nt==="office"&&Ie&&Se.createElement("iframe",{src:`${et}/office.html?key=${Ie.key}&url=${btoa(Ie.url)}&callbackUrl=${cn+(Ie.callbackUrl||"")}&fileType=${Ie.fileType}&title=${Ie.title||""}&model=${mt}&officeServer=${fe.Z.ONLYOFFICE}&disabledDownload=${!!De}`}),nt==="html"&&Se.createElement("iframe",{src:st+"&disposition=inline"}),nt==="pdf"&&Se.createElement("iframe",{id:"pdfiframe",src:`${et}/js/pdf/index.html?filename=${tt||"educoder.pdf"}&url=${encodeURIComponent(st)}&disabledDownload=${!!De}&model=${mt}`}),nt==="image"&&Se.createElement("img",{src:`${(st==null?void 0:st.indexOf("http://"))>-1||(st==null?void 0:st.indexOf("https://"))>-1?"":"data:image/png;base64,"}${st}`}),(nt==="other"||nt==="download")&&Se.createElement(Se.Fragment,null,Pt?Se.createElement(Oe.Z,{customText:"\u5F53\u524D\u6587\u4EF6\u4E0D\u652F\u6301\u9884\u89C8\uFF0C\u53EF\u70B9\u51FB\u4E0B\u8F7D\u67E5\u770B",ButtonTwo:Se.createElement(ve.ZP,{icon:Se.createElement("i",{className:"iconfont icon-xiazai4 font14"}),type:"primary",size:"middle",onClick:te,disabled:De},"\u4E0B\u8F7D")}):Se.createElement(ve.ZP,{type:"primary",size:"middle",onClick:te,disabled:De},Se.createElement(Ae.Z,null),"\u70B9\u51FB\u4E0B\u8F7D")),nt==="flowChart"&&Se.createElement("div",{className:"embed"},Se.createElement("iframe",{src:`/drawio/src/main/webapp/viewer.html?id=${st||""}&gapi=0&od=0&db=0&gh=0&gl=0`,width:"100%",height:"100%",frameBorder:"0"})))}},95097:function(ln,Ft,ie){"use strict";ie.d(Ft,{z:function(){return ht},Z:function(){return $e}});var z=ie(59301),Ke=ie(48850),ve=ie(49142),Ae=ie(64018),ye=ie(17030),be=ie(74128),Me=ie(65862),Re=ie(15342),Oe=ie(44104),fe=ie(7939),We=ie(1012),Se=ie(52918),yt=ie(59301),Le=({html:at})=>{const lt=(0,z.useRef)(null),me=(0,z.useRef)(null),At=`.markdown-body p {
|
|
|
margin: 0 0 16px 0 !important;
|
|
|
line-height: 28px;
|
|
|
white-space: pre-wrap;
|
|
|
}
|
|
|
|
|
|
ol,
|
|
|
ul,
|
|
|
li {
|
|
|
list-style-type: none
|
|
|
}
|
|
|
|
|
|
ol,
|
|
|
ul,
|
|
|
dl {
|
|
|
margin-bottom: 0px;
|
|
|
}
|
|
|
|
|
|
.markdown-body {
|
|
|
-ms-text-size-adjust: 100%;
|
|
|
-webkit-text-size-adjust: 100%;
|
|
|
color: #333;
|
|
|
overflow: hidden;
|
|
|
font-family: "Microsoft YaHei", Helvetica, "Meiryo UI", "Malgun Gothic", "Segoe UI", "Trebuchet MS", "Monaco", monospace, Tahoma, STXihei, "\u534E\u6587\u7EC6\u9ED1", STHeiti, "Helvetica Neue", "Droid Sans", "wenquanyi micro hei", FreeSans, Arimo, Arial, SimSun, "\u5B8B\u4F53", Heiti, "\u9ED1\u4F53", sans-serif;
|
|
|
word-break: break-word;
|
|
|
font-size: 16px;
|
|
|
line-height: 1.6;
|
|
|
white-space: normal;
|
|
|
word-wrap: break-word;
|
|
|
position: relative;
|
|
|
}
|
|
|
|
|
|
.markdown-body ul>li {
|
|
|
list-style-type: disc;
|
|
|
}
|
|
|
|
|
|
.markdown-body ol>li {
|
|
|
list-style-type: decimal;
|
|
|
}
|
|
|
|
|
|
.markdown-body a {
|
|
|
background: transparent;
|
|
|
}
|
|
|
|
|
|
.markdown-body a:active,
|
|
|
.markdown-body a:hover {
|
|
|
outline: 0;
|
|
|
}
|
|
|
|
|
|
.markdown-body strong {
|
|
|
font-weight: bold;
|
|
|
}
|
|
|
|
|
|
.markdown-body h1 {
|
|
|
font-size: 2em;
|
|
|
margin: 0.67em 0;
|
|
|
}
|
|
|
|
|
|
.markdown-body img {
|
|
|
border: 0;
|
|
|
}
|
|
|
|
|
|
.markdown-body hr {
|
|
|
-moz-box-sizing: content-box;
|
|
|
box-sizing: content-box;
|
|
|
height: 0;
|
|
|
}
|
|
|
|
|
|
.markdown-body pre {
|
|
|
overflow: auto;
|
|
|
}
|
|
|
|
|
|
.markdown-body code,
|
|
|
.markdown-body kbd,
|
|
|
.markdown-body pre {
|
|
|
font-family: "Meiryo UI", "YaHei Consolas Hybrid", Consolas, "Malgun Gothic", "Segoe UI", "Trebuchet MS", Helvetica, monospace, monospace;
|
|
|
font-size: 1em;
|
|
|
}
|
|
|
|
|
|
.markdown-body input {
|
|
|
color: inherit;
|
|
|
font: inherit;
|
|
|
margin: 0;
|
|
|
}
|
|
|
|
|
|
.markdown-body html input[disabled] {
|
|
|
cursor: default;
|
|
|
}
|
|
|
|
|
|
.markdown-body input {
|
|
|
line-height: normal;
|
|
|
}
|
|
|
|
|
|
.markdown-body input[type="checkbox"] {
|
|
|
-moz-box-sizing: border-box;
|
|
|
box-sizing: border-box;
|
|
|
padding: 0;
|
|
|
}
|
|
|
|
|
|
.markdown-body table {
|
|
|
border-collapse: collapse;
|
|
|
border-spacing: 0;
|
|
|
}
|
|
|
|
|
|
.markdown-body td,
|
|
|
.markdown-body th {
|
|
|
padding: 0;
|
|
|
}
|
|
|
|
|
|
.markdown-body * {
|
|
|
-moz-box-sizing: border-box;
|
|
|
box-sizing: border-box;
|
|
|
}
|
|
|
|
|
|
.markdown-body input {
|
|
|
font: 13px/1.4 Helvetica, arial, freesans, clean, sans-serif, "Segoe UI Emoji", "Segoe UI Symbol";
|
|
|
}
|
|
|
|
|
|
.markdown-body a {
|
|
|
color: #4183c4;
|
|
|
text-decoration: none;
|
|
|
}
|
|
|
|
|
|
.markdown-body a:hover,
|
|
|
.markdown-body a:active {
|
|
|
text-decoration: underline;
|
|
|
}
|
|
|
|
|
|
.markdown-body hr {
|
|
|
height: 0;
|
|
|
margin: 15px 0;
|
|
|
overflow: hidden;
|
|
|
background: transparent;
|
|
|
border: 0;
|
|
|
border-bottom: 1px solid #ddd;
|
|
|
}
|
|
|
|
|
|
.markdown-body hr:before {
|
|
|
display: table;
|
|
|
content: "";
|
|
|
}
|
|
|
|
|
|
.markdown-body hr:after {
|
|
|
display: table;
|
|
|
clear: both;
|
|
|
content: "";
|
|
|
}
|
|
|
|
|
|
.markdown-body h1,
|
|
|
.markdown-body h2,
|
|
|
.markdown-body h3,
|
|
|
.markdown-body h4,
|
|
|
.markdown-body h5,
|
|
|
.markdown-body h6 {
|
|
|
margin-top: 15px;
|
|
|
margin-bottom: 15px;
|
|
|
line-height: 1.1;
|
|
|
}
|
|
|
|
|
|
.markdown-body h1 {
|
|
|
font-size: 30px;
|
|
|
}
|
|
|
|
|
|
.markdown-body h2 {
|
|
|
font-size: 21px;
|
|
|
}
|
|
|
|
|
|
.markdown-body h3 {
|
|
|
font-size: 16px;
|
|
|
}
|
|
|
|
|
|
.markdown-body h4 {
|
|
|
font-size: 14px;
|
|
|
}
|
|
|
|
|
|
.markdown-body h5 {
|
|
|
font-size: 12px;
|
|
|
}
|
|
|
|
|
|
.markdown-body h6 {
|
|
|
font-size: 11px;
|
|
|
}
|
|
|
|
|
|
.markdown-body blockquote {
|
|
|
margin: 0;
|
|
|
}
|
|
|
|
|
|
.markdown-body ul,
|
|
|
.markdown-body ol {
|
|
|
padding: 0;
|
|
|
margin-top: 0;
|
|
|
margin-bottom: 0;
|
|
|
}
|
|
|
|
|
|
ul.linenums,
|
|
|
ol.linenums {
|
|
|
padding: 16px 0 0 56px !important;
|
|
|
}
|
|
|
|
|
|
.markdown-body ul,
|
|
|
.markdown-body ol {
|
|
|
padding-left: 2em;
|
|
|
}
|
|
|
|
|
|
|
|
|
.markdown-body ol ol,
|
|
|
.markdown-body ul ol {
|
|
|
list-style-type: lower-roman;
|
|
|
}
|
|
|
|
|
|
.markdown-body ul ul ol,
|
|
|
.markdown-body ul ol ol,
|
|
|
.markdown-body ol ul ol,
|
|
|
.markdown-body ol ol ol {
|
|
|
list-style-type: lower-alpha;
|
|
|
}
|
|
|
|
|
|
.markdown-body dd {
|
|
|
margin-left: 0;
|
|
|
}
|
|
|
|
|
|
.markdown-body code {
|
|
|
font-family: Consolas, "Liberation Mono", Menlo, Courier, monospace;
|
|
|
font-size: 12px;
|
|
|
}
|
|
|
|
|
|
.markdown-body pre {
|
|
|
margin-top: 0;
|
|
|
margin-bottom: 0;
|
|
|
font: 12px Consolas, "Liberation Mono", Menlo, Courier, monospace;
|
|
|
}
|
|
|
|
|
|
.markdown-body .octicon {
|
|
|
font: normal normal 16px octicons-anchor;
|
|
|
line-height: 1;
|
|
|
display: inline-block;
|
|
|
text-decoration: none;
|
|
|
-webkit-font-smoothing: antialiased;
|
|
|
-moz-osx-font-smoothing: grayscale;
|
|
|
-webkit-user-select: none;
|
|
|
-moz-user-select: none;
|
|
|
-ms-user-select: none;
|
|
|
user-select: none;
|
|
|
}
|
|
|
|
|
|
.markdown-body .octicon-link:before {
|
|
|
content: '\f05c';
|
|
|
}
|
|
|
|
|
|
.markdown-body>*:first-child {
|
|
|
margin-top: 0 !important;
|
|
|
}
|
|
|
|
|
|
.markdown-body>*:last-child {
|
|
|
margin-bottom: 0 !important;
|
|
|
}
|
|
|
|
|
|
.markdown-body .anchor {
|
|
|
position: absolute;
|
|
|
top: 0;
|
|
|
left: 0;
|
|
|
display: block;
|
|
|
padding-right: 6px;
|
|
|
padding-left: 30px;
|
|
|
margin-left: -30px;
|
|
|
}
|
|
|
|
|
|
.markdown-body .anchor:focus {
|
|
|
outline: none;
|
|
|
}
|
|
|
|
|
|
.markdown-body h1,
|
|
|
.markdown-body h2,
|
|
|
.markdown-body h3,
|
|
|
.markdown-body h4,
|
|
|
.markdown-body h5,
|
|
|
.markdown-body h6 {
|
|
|
position: relative;
|
|
|
margin-top: 1em;
|
|
|
margin-bottom: 16px;
|
|
|
font-weight: bold;
|
|
|
line-height: 1.4;
|
|
|
}
|
|
|
|
|
|
.markdown-body h1 .octicon-link,
|
|
|
.markdown-body h2 .octicon-link,
|
|
|
.markdown-body h3 .octicon-link,
|
|
|
.markdown-body h4 .octicon-link,
|
|
|
.markdown-body h5 .octicon-link,
|
|
|
.markdown-body h6 .octicon-link {
|
|
|
display: none;
|
|
|
color: #000;
|
|
|
vertical-align: middle;
|
|
|
}
|
|
|
|
|
|
.markdown-body h1:hover .anchor,
|
|
|
.markdown-body h2:hover .anchor,
|
|
|
.markdown-body h3:hover .anchor,
|
|
|
.markdown-body h4:hover .anchor,
|
|
|
.markdown-body h5:hover .anchor,
|
|
|
.markdown-body h6:hover .anchor {
|
|
|
padding-left: 8px;
|
|
|
margin-left: -30px;
|
|
|
text-decoration: none;
|
|
|
}
|
|
|
|
|
|
.markdown-body h1:hover .anchor .octicon-link,
|
|
|
.markdown-body h2:hover .anchor .octicon-link,
|
|
|
.markdown-body h3:hover .anchor .octicon-link,
|
|
|
.markdown-body h4:hover .anchor .octicon-link,
|
|
|
.markdown-body h5:hover .anchor .octicon-link,
|
|
|
.markdown-body h6:hover .anchor .octicon-link {
|
|
|
display: inline-block;
|
|
|
}
|
|
|
|
|
|
.markdown-body h1 {
|
|
|
padding-bottom: 0.3em;
|
|
|
font-size: 2.25em;
|
|
|
line-height: 1.2;
|
|
|
border-bottom: 1px solid #eee;
|
|
|
}
|
|
|
|
|
|
.markdown-body h1 .anchor {
|
|
|
line-height: 1;
|
|
|
}
|
|
|
|
|
|
.markdown-body h2 {
|
|
|
padding-bottom: 0.3em;
|
|
|
font-size: 1.75em;
|
|
|
line-height: 1.225;
|
|
|
border-bottom: 1px solid #eee;
|
|
|
}
|
|
|
|
|
|
.markdown-body h2 .anchor {
|
|
|
line-height: 1;
|
|
|
}
|
|
|
|
|
|
.markdown-body h3 {
|
|
|
font-size: 1.5em;
|
|
|
line-height: 1.43;
|
|
|
}
|
|
|
|
|
|
.markdown-body h3 .anchor {
|
|
|
line-height: 1.2;
|
|
|
}
|
|
|
|
|
|
.markdown-body h4 {
|
|
|
font-size: 1.25em;
|
|
|
}
|
|
|
|
|
|
.markdown-body h4 .anchor {
|
|
|
line-height: 1.2;
|
|
|
}
|
|
|
|
|
|
.markdown-body h5 {
|
|
|
font-size: 1em;
|
|
|
}
|
|
|
|
|
|
.markdown-body h5 .anchor {
|
|
|
line-height: 1.1;
|
|
|
}
|
|
|
|
|
|
.markdown-body h6 {
|
|
|
font-size: 1em;
|
|
|
color: #777;
|
|
|
}
|
|
|
|
|
|
.markdown-body h6 .anchor {
|
|
|
line-height: 1.1;
|
|
|
}
|
|
|
|
|
|
.markdown-body p,
|
|
|
.markdown-body blockquote,
|
|
|
.markdown-body ul,
|
|
|
.markdown-body ol,
|
|
|
.markdown-body dl,
|
|
|
.markdown-body table,
|
|
|
.markdown-body pre {
|
|
|
margin-top: 0;
|
|
|
margin-bottom: 16px;
|
|
|
}
|
|
|
|
|
|
.markdown-body ul ul,
|
|
|
.markdown-body ul ol,
|
|
|
.markdown-body ol ol,
|
|
|
.markdown-body ol ul {
|
|
|
margin-top: 0;
|
|
|
margin-bottom: 0;
|
|
|
}
|
|
|
|
|
|
.markdown-body li>p {
|
|
|
margin-top: 16px;
|
|
|
}
|
|
|
|
|
|
.markdown-body dl {
|
|
|
padding: 0;
|
|
|
}
|
|
|
|
|
|
.markdown-body dl dt {
|
|
|
padding: 0;
|
|
|
margin-top: 16px;
|
|
|
font-size: 1em;
|
|
|
font-style: italic;
|
|
|
font-weight: bold;
|
|
|
}
|
|
|
|
|
|
.markdown-body dl dd {
|
|
|
padding: 0 16px;
|
|
|
margin-bottom: 16px;
|
|
|
}
|
|
|
|
|
|
.markdown-body blockquote {
|
|
|
padding: 0 15px;
|
|
|
color: #777;
|
|
|
border-left: 4px solid #ddd;
|
|
|
}
|
|
|
|
|
|
.markdown-body blockquote> :first-child {
|
|
|
margin-top: 0;
|
|
|
}
|
|
|
|
|
|
.markdown-body blockquote> :last-child {
|
|
|
margin-bottom: 0;
|
|
|
}
|
|
|
|
|
|
.markdown-body table {
|
|
|
display: block;
|
|
|
width: 100%;
|
|
|
overflow: auto;
|
|
|
word-break: normal;
|
|
|
word-break: keep-all;
|
|
|
}
|
|
|
|
|
|
.markdown-body table th {
|
|
|
font-weight: bold;
|
|
|
text-align: revert;
|
|
|
}
|
|
|
|
|
|
.markdown-body table th,
|
|
|
.markdown-body table td {
|
|
|
padding: 6px 13px;
|
|
|
border: 1px solid #ddd;
|
|
|
}
|
|
|
|
|
|
.markdown-body table tr {
|
|
|
background-color: #fff;
|
|
|
border-top: 1px solid #ccc;
|
|
|
}
|
|
|
|
|
|
.markdown-body table tr:nth-child(2n) {
|
|
|
background-color: #f8f8f8;
|
|
|
}
|
|
|
|
|
|
.markdown-body img {
|
|
|
max-width: 100%;
|
|
|
-moz-box-sizing: border-box;
|
|
|
box-sizing: border-box;
|
|
|
}
|
|
|
|
|
|
.markdown-body code {
|
|
|
padding: 0;
|
|
|
padding-top: 0.2em;
|
|
|
padding-bottom: 0.2em;
|
|
|
margin: 0;
|
|
|
font-size: 85%;
|
|
|
background-color: rgba(0, 0, 0, 0.04);
|
|
|
border-radius: 3px;
|
|
|
}
|
|
|
|
|
|
.markdown-body code:has(.katex) {
|
|
|
background-color: transparent;
|
|
|
}
|
|
|
|
|
|
.markdown-body code:before,
|
|
|
.markdown-body code:after {
|
|
|
letter-spacing: -0.2em;
|
|
|
content: "\\00a0";
|
|
|
}
|
|
|
|
|
|
.markdown-body pre>code {
|
|
|
padding: 0;
|
|
|
margin: 0;
|
|
|
font-size: 100%;
|
|
|
word-break: normal;
|
|
|
white-space: pre;
|
|
|
background: transparent;
|
|
|
border: 0;
|
|
|
}
|
|
|
|
|
|
.markdown-body .highlight {
|
|
|
margin-bottom: 16px;
|
|
|
}
|
|
|
|
|
|
.markdown-body .highlight pre,
|
|
|
.markdown-body pre {
|
|
|
padding: 16px;
|
|
|
overflow: auto;
|
|
|
font-size: 85%;
|
|
|
line-height: 1.45;
|
|
|
background-color: #f7f7f7;
|
|
|
border-radius: 3px;
|
|
|
}
|
|
|
|
|
|
.markdown-body .highlight pre {
|
|
|
margin-bottom: 0;
|
|
|
word-break: normal;
|
|
|
}
|
|
|
|
|
|
.markdown-body pre {
|
|
|
word-wrap: normal;
|
|
|
}
|
|
|
|
|
|
.markdown-body pre code {
|
|
|
display: inline;
|
|
|
max-width: initial;
|
|
|
padding: 0;
|
|
|
margin: 0;
|
|
|
overflow: initial;
|
|
|
line-height: inherit;
|
|
|
word-wrap: normal;
|
|
|
background-color: transparent;
|
|
|
border: 0;
|
|
|
}
|
|
|
|
|
|
.markdown-body pre code:before,
|
|
|
.markdown-body pre code:after {
|
|
|
content: normal;
|
|
|
}
|
|
|
|
|
|
.markdown-body kbd {
|
|
|
display: inline-block;
|
|
|
padding: 3px 5px;
|
|
|
font-size: 11px;
|
|
|
line-height: 10px;
|
|
|
color: #555;
|
|
|
vertical-align: middle;
|
|
|
background-color: #fcfcfc;
|
|
|
border: solid 1px #ccc;
|
|
|
border-bottom-color: #bbb;
|
|
|
border-radius: 3px;
|
|
|
box-shadow: inset 0 -1px 0 #bbb;
|
|
|
}
|
|
|
|
|
|
.markdown-body .pl-c {
|
|
|
color: #969896;
|
|
|
}
|
|
|
|
|
|
.markdown-body .pl-c1,
|
|
|
.markdown-body .pl-mdh,
|
|
|
.markdown-body .pl-mm,
|
|
|
.markdown-body .pl-mp,
|
|
|
.markdown-body .pl-mr,
|
|
|
.markdown-body .pl-s1 .pl-v,
|
|
|
.markdown-body .pl-s3,
|
|
|
.markdown-body .pl-sc,
|
|
|
.markdown-body .pl-sv {
|
|
|
color: #0086b3;
|
|
|
}
|
|
|
|
|
|
.markdown-body .pl-e,
|
|
|
.markdown-body .pl-en {
|
|
|
color: #795da3;
|
|
|
}
|
|
|
|
|
|
.markdown-body .pl-s1 .pl-s2,
|
|
|
.markdown-body .pl-smi,
|
|
|
.markdown-body .pl-smp,
|
|
|
.markdown-body .pl-stj,
|
|
|
.markdown-body .pl-vo,
|
|
|
.markdown-body .pl-vpf {
|
|
|
color: #333;
|
|
|
}
|
|
|
|
|
|
.markdown-body .pl-ent {
|
|
|
color: #63a35c;
|
|
|
}
|
|
|
|
|
|
.markdown-body .pl-k,
|
|
|
.markdown-body .pl-s,
|
|
|
.markdown-body .pl-st {
|
|
|
color: #a71d5d;
|
|
|
}
|
|
|
|
|
|
.markdown-body .pl-pds,
|
|
|
.markdown-body .pl-s1,
|
|
|
.markdown-body .pl-s1 .pl-pse .pl-s2,
|
|
|
.markdown-body .pl-sr,
|
|
|
.markdown-body .pl-sr .pl-cce,
|
|
|
.markdown-body .pl-sr .pl-sra,
|
|
|
.markdown-body .pl-sr .pl-sre,
|
|
|
.markdown-body .pl-src {
|
|
|
color: #df5000;
|
|
|
}
|
|
|
|
|
|
.markdown-body .pl-mo,
|
|
|
.markdown-body .pl-v {
|
|
|
color: #1d3e81;
|
|
|
}
|
|
|
|
|
|
.markdown-body .pl-id {
|
|
|
color: #b52a1d;
|
|
|
}
|
|
|
|
|
|
.markdown-body .pl-ii {
|
|
|
background-color: #b52a1d;
|
|
|
color: #f8f8f8;
|
|
|
}
|
|
|
|
|
|
.markdown-body .pl-sr .pl-cce {
|
|
|
color: #63a35c;
|
|
|
font-weight: bold;
|
|
|
}
|
|
|
|
|
|
.markdown-body .pl-ml {
|
|
|
color: #693a17;
|
|
|
}
|
|
|
|
|
|
.markdown-body .pl-mh,
|
|
|
.markdown-body .pl-mh .pl-en,
|
|
|
.markdown-body .pl-ms {
|
|
|
color: #1d3e81;
|
|
|
font-weight: bold;
|
|
|
}
|
|
|
|
|
|
.markdown-body .pl-mq {
|
|
|
color: #008080;
|
|
|
}
|
|
|
|
|
|
.markdown-body .pl-mi {
|
|
|
color: #333;
|
|
|
font-style: italic;
|
|
|
}
|
|
|
|
|
|
.markdown-body .pl-mb {
|
|
|
color: #333;
|
|
|
font-weight: bold;
|
|
|
}
|
|
|
|
|
|
.markdown-body .pl-md,
|
|
|
.markdown-body .pl-mdhf {
|
|
|
background-color: #ffecec;
|
|
|
color: #bd2c00;
|
|
|
}
|
|
|
|
|
|
.markdown-body .pl-mdht,
|
|
|
.markdown-body .pl-mi1 {
|
|
|
background-color: #eaffea;
|
|
|
color: #55a532;
|
|
|
}
|
|
|
|
|
|
.markdown-body .pl-mdr {
|
|
|
color: #795da3;
|
|
|
font-weight: bold;
|
|
|
}
|
|
|
|
|
|
.markdown-body kbd {
|
|
|
display: inline-block;
|
|
|
padding: 3px 5px;
|
|
|
font: 11px Consolas, "Liberation Mono", Menlo, Courier, monospace;
|
|
|
line-height: 10px;
|
|
|
color: #555;
|
|
|
vertical-align: middle;
|
|
|
background-color: #fcfcfc;
|
|
|
border: solid 1px #ccc;
|
|
|
border-bottom-color: #bbb;
|
|
|
border-radius: 3px;
|
|
|
box-shadow: inset 0 -1px 0 #bbb;
|
|
|
}
|
|
|
|
|
|
.markdown-body .task-list-item {
|
|
|
list-style-type: none;
|
|
|
}
|
|
|
|
|
|
.markdown-body .task-list-item+.task-list-item {
|
|
|
margin-top: 3px;
|
|
|
}
|
|
|
|
|
|
.markdown-body .task-list-item input {
|
|
|
float: left;
|
|
|
margin: 0.3em 0 0.25em -1.6em;
|
|
|
vertical-align: middle;
|
|
|
}
|
|
|
|
|
|
.markdown-body :checked+.radio-label {
|
|
|
z-index: 1;
|
|
|
position: relative;
|
|
|
border-color: #4183c4;
|
|
|
}
|
|
|
|
|
|
|
|
|
/*! Pretty printing styles. Used with prettify.js. */
|
|
|
/* SPAN elements with the classes below are added by prettyprint. */
|
|
|
.pln {
|
|
|
color: #000
|
|
|
}
|
|
|
|
|
|
/* plain text */
|
|
|
|
|
|
@media screen {
|
|
|
.str {
|
|
|
color: #080
|
|
|
}
|
|
|
|
|
|
/* string content */
|
|
|
.kwd {
|
|
|
color: #008
|
|
|
}
|
|
|
|
|
|
/* a keyword */
|
|
|
.com {
|
|
|
color: #800
|
|
|
}
|
|
|
|
|
|
/* a comment */
|
|
|
.typ {
|
|
|
color: #606
|
|
|
}
|
|
|
|
|
|
/* a type name */
|
|
|
.lit {
|
|
|
color: #066
|
|
|
}
|
|
|
|
|
|
/* a literal value */
|
|
|
/* punctuation, lisp open bracket, lisp close bracket */
|
|
|
.pun,
|
|
|
.opn,
|
|
|
.clo {
|
|
|
color: #660
|
|
|
}
|
|
|
|
|
|
.tag {
|
|
|
color: #008
|
|
|
}
|
|
|
|
|
|
/* a markup tag name */
|
|
|
.atn {
|
|
|
color: #606
|
|
|
}
|
|
|
|
|
|
/* a markup attribute name */
|
|
|
.atv {
|
|
|
color: #080
|
|
|
}
|
|
|
|
|
|
/* a markup attribute value */
|
|
|
.dec,
|
|
|
.var {
|
|
|
color: #606
|
|
|
}
|
|
|
|
|
|
/* a declaration; a variable name */
|
|
|
.fun {
|
|
|
color: red
|
|
|
}
|
|
|
|
|
|
/* a function name */
|
|
|
}
|
|
|
|
|
|
/* Use higher contrast and text-weight for printable form. */
|
|
|
@media print,
|
|
|
projection {
|
|
|
.str {
|
|
|
color: #060
|
|
|
}
|
|
|
|
|
|
.kwd {
|
|
|
color: #006;
|
|
|
font-weight: bold
|
|
|
}
|
|
|
|
|
|
.com {
|
|
|
color: #600;
|
|
|
font-style: italic
|
|
|
}
|
|
|
|
|
|
.typ {
|
|
|
color: #404;
|
|
|
font-weight: bold
|
|
|
}
|
|
|
|
|
|
.lit {
|
|
|
color: #044
|
|
|
}
|
|
|
|
|
|
.pun,
|
|
|
.opn,
|
|
|
.clo {
|
|
|
color: #440
|
|
|
}
|
|
|
|
|
|
.tag {
|
|
|
color: #006;
|
|
|
font-weight: bold
|
|
|
}
|
|
|
|
|
|
.atn {
|
|
|
color: #404
|
|
|
}
|
|
|
|
|
|
.atv {
|
|
|
color: #060
|
|
|
}
|
|
|
}
|
|
|
|
|
|
/* Put a border around prettyprinted code snippets. */
|
|
|
pre.prettyprint {
|
|
|
padding: 2px;
|
|
|
/* border: 1px solid #888 */
|
|
|
}
|
|
|
|
|
|
/* Specify class=linenums on a pre to get line numbering */
|
|
|
ol.linenums {
|
|
|
margin-top: 0;
|
|
|
margin-bottom: 0
|
|
|
}
|
|
|
|
|
|
/* IE indents via margin-left */
|
|
|
li.L0,
|
|
|
li.L1,
|
|
|
li.L2,
|
|
|
li.L3,
|
|
|
li.L5,
|
|
|
li.L6,
|
|
|
li.L7,
|
|
|
li.L8 {
|
|
|
list-style-type: none
|
|
|
}
|
|
|
|
|
|
/* Alternate shading for lines */
|
|
|
li.L1,
|
|
|
li.L3,
|
|
|
li.L5,
|
|
|
li.L7,
|
|
|
li.L9 {
|
|
|
background: #eee
|
|
|
}
|
|
|
|
|
|
.markdown-body p,
|
|
|
.markdown-body blockquote,
|
|
|
.markdown-body ul,
|
|
|
.markdown-body ol,
|
|
|
.markdown-body dl,
|
|
|
.markdown-body table,
|
|
|
.markdown-body pre {
|
|
|
margin-top: 0;
|
|
|
margin-bottom: 16px;
|
|
|
}`;return(0,z.useEffect)(()=>{const De=lt.current.attachShadow({mode:"open"});me.current=document.createElement("div"),me.current.className="markdown-body",me.current.innerHTML=at,De.appendChild(me.current);const He=document.createElement("style");return He.textContent=At,De.appendChild(He),()=>{De.innerHTML=""}},[]),(0,z.useEffect)(()=>{me.current&&(me.current.innerHTML=at)},[at]),yt.createElement("div",{ref:lt})};function Ge(at){const lt=["onabort","onanimationend","onanimationiteration","onanimationstart","onauxclick","onblur","oncancel","oncanplay","oncanplaythrough","onchange","onclick","onclose","oncontextmenu","oncopy","oncut","ondblclick","ondrag","ondragend","ondragenter","ondragleave","ondragover","ondragstart","ondrop","ondurationchange","onemptied","onended","onerror","onfocus","onformdata","ongotpointercapture","oninput","oninvalid","onkeydown","onkeypress","onkeyup","onload","onloadeddata","onloadedmetadata","onloadstart","onlostpointercapture","onmousedown","onmousemove","onmouseout","onmouseover","onmouseup","onpaste","onpause","onplay","onplaying","onpointercancel","onpointerdown","onpointerenter","onpointerleave","onpointermove","onpointerout","onpointerover","onpointerup","onprogress","onratechange","onreset","onresize","onscroll","onsecuritypolicyviolation","onseeked","onseeking","onselect","onslotchange","onstalled","onsubmit","onsuspend","ontimeupdate","ontoggle","ontouchcancel","ontouchend","ontouchmove","ontouchstart","ontransitionend","onvolumechange","onwaiting","onwheel"],me=new RegExp(`\\b(${lt.join("|")})\\s*=\\s*(?:"[^"]*"|'[^']*'|[^\\s>]*)`,"gi");return at.replace(me,"").trim()}var Ne={mdBody:"mdBody___raKXb",button:"button___Ch5Pc",previewFlowChart:"previewFlowChart___vY1dq"},dt=Object.defineProperty,It=Object.getOwnPropertySymbols,Bt=Object.prototype.hasOwnProperty,mt=Object.prototype.propertyIsEnumerable,st=(at,lt,me)=>lt in at?dt(at,lt,{enumerable:!0,configurable:!0,writable:!0,value:me}):at[lt]=me,it=(at,lt)=>{for(var me in lt||(lt={}))Bt.call(lt,me)&&st(at,me,lt[me]);if(It)for(var me of It(lt))mt.call(lt,me)&&st(at,me,lt[me]);return at};const je="@\u2581\u2581@",Ot="@\u2581@",nt=/<pre[^>]*>/g;function tt(at){let lt=document.createElement("div");return lt.innerHTML=at,lt.childNodes.length===0?"":lt.childNodes[0].nodeValue}const ht=(at,lt)=>{at=at||"";const me=/(?:https?:\/\/[^\/]+)?\/api\/attachments\/([A-Za-z0-9+/=]+)(\?.*?)?\)|(?:https?:\/\/[^\/]+)?\/api\/attachments\/([A-Za-z0-9+/=]+)(\?.*?)?|(?:https?:\/\/[^\/]+)?\/attachments\/download\/([A-Za-z0-9+/=]+)(\?.*?)?\//g,At=/\"(?:https?:\/\/[^\/]+)?\/api\/attachments\/([A-Za-z0-9+/=]+)(\?.*?)?|\"(?:https?:\/\/[^\/]+)?\/attachments\/download\/([A-Za-z0-9+/=]+)(\?.*?)?\//g,De=/\(\s+(?:https?:\/\/[^\/]+)?\/files\/uploads\/([A-Za-z0-9+/=]+)(\?.*?)?|\"(?:https?:\/\/[^\/]+)?\/files\/uploads\/([A-Za-z0-9+/=]+)(\?.*?)?\//g,He=/(?:https?:\/\/[^\/]+)?\/attachments\/download\/([A-Za-z0-9+/=]+)(\?.*?)?\//g;return lt?at.replaceAll("https://www.educoder.net","").replaceAll("https://www-cdn.educoder.net","").replaceAll("//api/attachments","/api/attachments").replace(me,(Pt,ge,ce,Je,jt,wt,Ie)=>{const Ue=ge||Je||wt,et=ce||jt||Ie||"?";return be.Z.API_SERVER+"/api/attachments/"+Ue+et+"&t="+(0,Me.Jn)(Ue,Date.now())+(Pt.indexOf(")")>-1?")":"&")}).replaceAll('src="(','src="').replaceAll("src='(",'src="'):(at=at.replace(He,(Pt,ge,ce,Je,jt,wt,Ie)=>{const Ue=ge||Je||wt,et=ce||jt||Ie||"?";return be.Z.API_SERVER+"/attachments/download/"+Ue+et+"&t="+(0,Me.Jn)(Ue,Date.now())+(Pt.indexOf(")")>-1?")":"&")}).replace(me,(Pt,ge,ce,Je,jt,wt,Ie)=>{const Ue=ge||Je||wt,et=ce||jt||Ie||"?";return be.Z.API_SERVER+"/api/attachments/"+Ue+et+"&t="+(0,Me.Jn)(Ue,Date.now())+(Pt.indexOf(")")>-1?")":"&")}).replace(At,(Pt,ge,ce,Je,jt)=>{const wt=ge||Je,Ie=ce||jt||"";return'"'+be.Z.API_SERVER+"/api/attachments/"+wt+Ie+wt+Ie+"&t="+(0,Me.Jn)(wt,Date.now())}).replace(De,(Pt,ge,ce,Je,jt)=>{const wt=ge||Je,Ie=ce||jt||"";return"("+be.Z.API_SERVER+"/files/uploads/"+wt+Ie+wt+Ie+"&t="+(0,Me.Jn)(wt,Date.now())}).replaceAll('src="(','src="').replaceAll("src='(",'src="').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,`
|
|
|
`),at)};var $e=({value:at="",edit:lt=!1,className:me,showTextOnly:At,showLines:De,style:He={},stylesPrev:Pt={},highlightKeywords:ge,showProgramFill:ce,isProgramFill:Je,disabledFill:jt=!1,programFillValue:wt,openEditor:Ie=()=>{},onFillChange:Ue=kt=>{},onFillBlur:et=()=>{},onFillFocus:cn=()=>{}})=>{let kt=Ge(String(at||""));const Yt=(0,z.useRef)(),ze=(0,z.useRef)(),[zt,ut]=(0,z.useState)(""),[ae,te]=(0,z.useState)("office"),[ee,oe]=(0,z.useState)([]),se=(0,z.useRef)("a"+(0,We.Z)()),ne={},he=ft=>/<style[\s\S]*?>/i.test(ft||""),xe=(ft,Gt,Tt)=>{const en=document.createElement(ft===Ot?"input":"textarea");en.style.width="100%",en.style.height=ft===Ot?"40px":"151px",en.rows=5,en.spellcheck=!1,en.name="edu-program-fill",en.placeholder="\u8BF7\u8F93\u5165",en.dataset.id=Gt;const yn=Object.keys(ne).length;return ne[yn]=en,`<span class="edu-program-fill-wrap ${ft===Ot?"":"show"}" style="width:${ft===Ot?"600px":"100%"}" title=${Tt||""}><span>${en.outerHTML}<span class="edu-program-fill-score" style="margin:0 6px"></span></span></span>`};function ot(ft){return ft=ft.replace(/!\[.*?\]\(.*?\)/g,""),ft=ft.replace(/\[.*?\]\(.*?\)/g,""),ft=ft.replace(new RegExp("<iframe.*?<\\/iframe>","gs"),""),ft=ft.replace(/<embed.*?>/g,""),ft=ft.replace(/<img.*?>/g,""),ft=ft.replace(new RegExp("<video.*?>.*?<\\/video>","gs"),""),ft=ft.replace(new RegExp("<audio.*?>.*?<\\/audio>","gs"),""),ft=ft.replace(new RegExp("<style.*?>.*?<\\/style>","gs"),""),ft=ft.replace(new RegExp("<script.*?>.*?<\\/script>","gs"),""),ft}const Ee=ft=>!At&&he(kt)?ft:ft.replace(/<style.*?>([\s\S]+?)<\/style>/gim,function(Gt,Tt){let en=Tt.replace(/(\n|\r)/g,"").split("}"),yn=[];return en.map(Rn=>{Rn!=""&&yn.push(`.${se.current} ${Rn}`)}),`<style>${yn.join("}")}</style>`}),Fe=(0,z.useMemo)(()=>{try{const en=/\(\s+\/api\/attachments\/|\(\/api\/attachments\//g,yn=/\"\/api\/attachments\/|\"\/attachments\/download\//g,Rn=/\(\s+\/files\/uploads\/|\"\/files\/uploads\//g,On=/\(\/attachments\/download\//g;kt=kt.replace(On,"("+be.Z.API_SERVER+"/attachments/download/").replace(en,"("+be.Z.API_SERVER+"/api/attachments/").replace(yn,'"'+be.Z.API_SERVER+"/api/attachments/").replace(Rn,'"'+be.Z.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,`
|
|
|
`),Yt.current.style.display="none"}catch(en){}if(ce){let en=-1;return kt=kt.replaceAll("<","<").replaceAll(">",">").replace(/(@▁▁@|@▁@)/g,function(yn,Rn,On){var Pe;return++en,xe(yn,en,(Pe=wt==null?void 0:wt[en])==null?void 0:Pe.value.replaceAll("<","<").replaceAll(">",">"))}),`<pre style="background:#fff;padding:4px">${Ee(kt||"")}</pre>`}let ft=Ee(kt);ft=(0,ve.ZP)(ft);const Gt=(0,ve.ez)();kt.match(/\[TOC\]/)&&(ft=ft.replace("<p>[TOC]</p>",(0,ve.Qv)()),(0,ve.Iy)()),ft=ft.replace(/(__special_katext_id_\d+__)/g,(en,yn)=>{const{type:Rn,expression:On}=Gt[yn];return(0,Re.renderToString)(tt(On)||"",{displayMode:Rn==="block",throwOnError:!1,output:"html"})}),ft=ft.replace(/▁/g,"\u2581\u2581\u2581\u2581\u2581"),(0,ve.AL)();const Tt=document.createElement("div");if(Tt.innerHTML=ft,At)return Tt.innerText;if(ge){const en=ge.replace(/[.*+?^${}()|[\]\\]/g,"\\$&");return Kt(Tt,en),Tt.innerHTML}return setTimeout(()=>rn(),500),Tt.innerHTML},[kt,ge]);(0,z.useEffect)(()=>{Wt.current&&Wt.current.querySelectorAll(["input","textarea"]).forEach(Gt=>{Gt.oninput=qe,Gt.onblur=bt,Gt.onfocus=ct})},[ee]),(0,z.useEffect)(()=>{var ft,Gt,Tt,en,yn;if(wt!=null&&wt.length)try{const Rn=Wt.current.querySelectorAll(".edu-program-fill-score"),On=Wt.current.querySelectorAll('[name="edu-program-fill"]');for(const[Pe,rt]of On.entries())rt.value=((ft=wt==null?void 0:wt[Pe])==null?void 0:ft.value)||"",((Gt=wt==null?void 0:wt[Pe])==null?void 0:Gt.type)==="warning"?rt.className="program-fill-warning":((Tt=wt==null?void 0:wt[Pe])==null?void 0:Tt.type)==="success"?rt.className="program-fill-success":rt.className="";for(const[Pe,rt]of Rn.entries())rt.innerHTML=(en=wt==null?void 0:wt[Pe])!=null&&en.score?`${(yn=wt==null?void 0:wt[Pe])==null?void 0:yn.score}\u5206`:"";oe(wt)}catch(Rn){console.log(Rn,"error")}},[wt]);const qe=ft=>{ee[ft.target.dataset.id]=ee[ft.target.dataset.id]||{},ee[ft.target.dataset.id].value=ft.target.value,oe([...ee]),Ue(ee,ft.target.dataset.id)},bt=ft=>{ee[ft.target.dataset.id]=ee[ft.target.dataset.id]||{},ee[ft.target.dataset.id].value=ft.target.value,oe([...ee]),et(ee,ft.target.dataset.id)},ct=ft=>{ee[ft.target.dataset.id]=ee[ft.target.dataset.id]||{},ee[ft.target.dataset.id].value=ft.target.value,oe([...ee]),cn(ee,ft.target.dataset.id)};function Kt(ft,Gt){return ft.childNodes.forEach(Tt=>{var en;if(Tt.childNodes.length>0)Kt(Tt,Gt);else if(Tt.nodeName!=="IMG")if(Tt.innerHTML)Tt.innerHTML=(en=Tt.innerHTML)==null?void 0:en.replace(new RegExp(Gt,"gi"),'<span style="color:#0152d9;background-color:#1890ff33">$&</span>');else{const yn=document.createElement("span");yn.innerHTML=Tt.textContent.replace(new RegExp(Gt,"gi"),'<span style="color:#0152d9;background-color:#1890ff33">$&</span>'),Tt.replaceWith(yn)}})}const Wt=(0,z.useRef)();ve.jb.WebkitLineClamp=De,De&&(He=it(it({},He),ve.jb));function Nt(ft){let Gt=ft.target;if(Gt.tagName.toUpperCase()==="A"){let Tt=Gt.getAttribute("href");if(Tt.indexOf("office")>-1)ft.preventDefault(),ut(Tt),te("office");else if(Tt.indexOf("application/pdf")>-1)ft.preventDefault(),ut(Tt),te("pdf");else if(Tt.indexOf("text/html")>-1)ft.preventDefault(),ut(Tt),te("html");else if(Tt.startsWith("#")){ft.preventDefault();let en=document.getElementById(Tt.replace("#",""));en&&en.scrollIntoView(!0)}}}const rn=()=>{var ft;const Gt=(ft=Wt.current)==null?void 0:ft.querySelectorAll("video");Gt==null||Gt.forEach(Tt=>{if(Tt.oncontextmenu=()=>!1,Tt.src.indexOf(".m3u8")>-1&&!Tt.canPlayType("application/vnd.apple.mpegurl")){if(ye.ZP.isSupported()){var en=new ye.ZP;en.loadSource(Tt.src),en.attachMedia(Tt)}}})};(0,z.useEffect)(()=>{if(Wt.current&&Fe&&Fe.match(nt)&&window.PR.prettyPrint(),Wt.current)return Wt.current.addEventListener("click",Nt),()=>{var ft;(ft=Wt.current)==null||ft.removeEventListener("click",Nt),(0,ve.AL)(),(0,ve.Iy)()}},[Fe,Wt.current,Nt]);const qt=ft=>{ft.target.nodeName==="IMG"&&ft.target.className.indexOf("draw-flowchart")>-1?(Yt.current.style.zIndex=1,Yt.current.style.display="flex",Yt.current.style.width=ft.target.clientWidth+"px",Yt.current.style.height=ft.target.clientHeight+"px",Yt.current.style.top=ft.target.offsetTop+"px",Yt.current.style.left=ft.target.offsetLeft+"px",ft.target.id&&(ze.current=ft.target.id)):Yt.current.style.display="none"},on=()=>{Yt.current.style.display="none"};return(0,z.useEffect)(()=>{var ft;const Gt=Tt=>{Tt.preventDefault(),Tt.clipboardData.setData("text",window.getSelection().toString())};return(ft=Wt.current)==null||ft.addEventListener("copy",Gt),()=>{var Tt;(Tt=Wt.current)==null||Tt.removeEventListener("copy",Gt)}},[Wt.current]),z.createElement("div",{style:{position:"relative"},onMouseLeave:on},At&&z.createElement("div",{ref:Wt,className:`${Ne.mdBody} `},Fe),!At&&!he(Fe)&&z.createElement("div",{ref:Wt,style:it({},He),onMouseOver:qt,className:`${me||""} ${jt?"disabled-fill":""} markdown-body ${Ne.mdBody} ${se.current}`,dangerouslySetInnerHTML:{__html:Fe}}),!At&&he(Fe)&&z.createElement(Le,{html:Fe}),z.createElement("div",{ref:Yt,className:`${Ne.button} ${lt?"":Ne.previewFlowChart}`},z.createElement(Oe.Z,null,z.createElement(fe.ZP,{onClick:()=>{lt?Ie(ze.current):(ut(ze.current),te("flowChart"))}},lt?"\u7F16\u8F91":"\u9884\u89C8"))),z.createElement(Se.Z,{close:!0,data:zt,type:zt!=null&&zt.length?ae:"",style:it({},Pt),onClose:()=>ut("")}))}},30214:function(ln,Ft,ie){"use strict";ie.d(Ft,{Z:function(){return Ae}});var z=ie(59301),Ke=ie(77254),ve=ie(75786),Ae=()=>{const[ye,be]=(0,z.useState)(""),[Me,Re]=(0,z.useState)(0);let[Oe,fe]=(0,z.useState)(),[We,Se]=(0,z.useState)();const[yt,Xe]=(0,z.useState)(!1),Le=(0,z.useRef)("");(0,z.useEffect)(()=>Ke.Z.subscribe("preview-image",nt=>{be(nt),console.log(it.current)}),[]),(0,z.useEffect)(()=>(document.addEventListener("keydown",Ge),()=>{document.removeEventListener("keydown",Ge)}),[]),(0,z.useEffect)(()=>{Le.current=ye},[ye]);function Ge(Ot){console.log("e====",Ot),Ot.keyCode==27&&Le.current&&Ne()}function Ne(){document.body.style.overflow="auto",fe(void 0),Se(void 0),Re(0),be("")}function dt(){Re(Me+90)}function It(){Oe=it.current.width*1.1,We=it.current.height*1.1,Se(We),fe(Oe)}function Bt(){Oe=it.current.width/1.1,We=it.current.height/1.1,Se(We),fe(Oe)}const mt=(0,z.useRef)(),st=(0,z.useRef)(),it=(0,z.useRef)(),je=Ot=>{(Ot.nativeEvent.target===mt.current||Ot.nativeEvent.target===st.current)&&Ne()};return z.createElement(z.Fragment,null,ye?z.createElement("div",null,z.createElement("div",{className:"preview-wrp-group",ref:st},z.createElement(ve.Z,{className:"image-preview",src:ye,style:{display:"none"},preview:{visible:!0,src:ye,onVisibleChange:Ot=>{be("")}},alt:"\u9884\u89C8\u5927\u56FE"}))):null)}},85533:function(ln,Ft,ie){"use strict";ie.d(Ft,{h:function(){return mt}});var z=ie(59301),Ke=ie(82326),ve=ie(28284),Ae=ie(7939),ye=ie(89780),be=ie.n(ye),Me=ie(45559),Re=ie(42313),Oe=Object.defineProperty,fe=Object.defineProperties,We=Object.getOwnPropertyDescriptors,Se=Object.getOwnPropertySymbols,yt=Object.prototype.hasOwnProperty,Xe=Object.prototype.propertyIsEnumerable,Le=(st,it,je)=>it in st?Oe(st,it,{enumerable:!0,configurable:!0,writable:!0,value:je}):st[it]=je,Ge=(st,it)=>{for(var je in it||(it={}))yt.call(it,je)&&Le(st,je,it[je]);if(Se)for(var je of Se(it))Xe.call(it,je)&&Le(st,je,it[je]);return st},Ne=(st,it)=>fe(st,We(it));const dt=Ke.default.Option,It={labelCol:{span:4},wrapperCol:{span:20}},Bt={asp:["ASP","vbscript"],actionscript:["ActionScript(3.0)/Flash/Flex","clike"],bash:["Bash/Bat","shell"],css:["CSS","css"],c:["C","clike"],cpp:["C++","clike"],csharp:["C#","clike"],coffeescript:["CoffeeScript","coffeescript"],d:["D","d"],dart:["Dart","dart"],delphi:["Delphi/Pascal","pascal"],erlang:["Erlang","erlang"],go:["Golang","go"],groovy:["Groovy","groovy"],html:["HTML","text/html"],java:["Java","clike"],json:["JSON","text/json"],javascript:["Javascript","javascript"],lua:["Lua","lua"],less:["LESS","css"],markdown:["Markdown","gfm"],"objective-c":["Objective-C","clike"],php:["PHP","php"],perl:["Perl","perl"],python:["Python","python"],r:["R","r"],rst:["reStructedText","rst"],ruby:["Ruby","ruby"],sql:["SQL","sql"],sass:["SASS/SCSS","sass"],shell:["Shell","shell"],scala:["Scala","clike"],swift:["Swift","clike"],vb:["VB/VBScript","vb"],xml:["XML","text/xml"],yaml:["YAML","yaml"]};Ft.Z=({callback:st,onCancel:it})=>{const[je,Ot]=(0,z.useState)("python");function nt(ht){Ot(Bt[ht][1])}function tt(ht){st(ht)}return z.createElement(ve.default,Ne(Ge({},It),{className:"code-block-panel",initialValues:{language:"python",content:""},onFinish:tt,style:{width:500}}),z.createElement(ve.default.Item,{label:"\u4EE3\u7801\u8BED\u8A00",name:"language"},z.createElement(Ke.default,{getPopupContainer:ht=>ht.parentNode,onChange:nt},Object.keys(Bt).map(ht=>z.createElement(dt,{key:ht,value:ht},Bt[ht][0])))),z.createElement(ve.default.Item,{label:"\u4EE3\u7801\u5185\u5BB9",name:"content",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u4EE3\u7801\u5185\u5BB9"}]},z.createElement(mt,{mode:je})),z.createElement("div",{className:"flex-container flex-end"},z.createElement(Ae.ZP,{type:"primary",htmlType:"submit",style:{marginRight:10}},"\u786E\u5B9A"),z.createElement(Ae.ZP,{type:"ghost",onClick:it},"\u53D6\u6D88")))};function mt({value:st,onChange:it,mode:je,options:Ot={}}){const nt=(0,z.useRef)(),[tt,ht]=(0,z.useState)();return(0,z.useEffect)(()=>{if(tt){let $e=function(at){const lt=at.getValue();it&&it(lt)};return tt.on("change",$e),()=>{tt.off("change",$e)}}},[tt,it]),(0,z.useEffect)(()=>{tt&&tt.setOption("mode",je)},[tt,je]),(0,z.useEffect)(()=>{tt&&(st!==tt.getValue()||st==="")&&setTimeout(()=>{tt.setValue(st||"")},300)},[tt,st]),(0,z.useEffect)(()=>{if(nt.current&&!tt){const $e=be().fromTextArea(nt.current,Ge({mode:je,lineNumbers:!0,lineWrapping:!0,autoCloseBrackets:!0,tabSize:4,autofocus:!0,autoCloseTags:!0,matchBrackets:!0,styleActiveLine:!0},Ot));ht($e)}},[nt.current,tt]),z.createElement("div",{className:"my-codemirror-container"},z.createElement("textarea",{ref:nt}))}},25374:function(ln,Ft,ie){"use strict";ie.d(Ft,{Z:function(){return Vt}});var z=ie(59301),Ke=ie(65582),ve=ie(89780),Ae=ie.n(ve),ye=ie(76374),be=ie(45559),Me=ie(6313),Re=ie(25717),Oe=ie(99498),fe=ie(25419),We=ie(67549),Se=ie(95097),yt=({value:Ut="",className:En,showTextOnly:mn,showLines:xn,style:wn={}})=>{const Bn=(0,z.useMemo)(()=>"",[Ut]);return z.createElement(z.Fragment,null,z.createElement("div",{dangerouslySetInnerHTML:{__html:Bn}}))},Xe=Object.defineProperty,Le=Object.defineProperties,Ge=Object.getOwnPropertyDescriptors,Ne=Object.getOwnPropertySymbols,dt=Object.prototype.hasOwnProperty,It=Object.prototype.propertyIsEnumerable,Bt=(Ut,En,mn)=>En in Ut?Xe(Ut,En,{enumerable:!0,configurable:!0,writable:!0,value:mn}):Ut[En]=mn,mt=(Ut,En)=>{for(var mn in En||(En={}))dt.call(En,mn)&&Bt(Ut,mn,En[mn]);if(Ne)for(var mn of Ne(En))It.call(En,mn)&&Bt(Ut,mn,En[mn]);return Ut},st=(Ut,En)=>Le(Ut,Ge(En));let it=[{title:"\u7C97\u4F53",icon:"md-iconfont icon-bold",actionName:"bold"},{title:"\u659C\u4F53",icon:"md-iconfont icon-italic",actionName:"italic"},"|",{title:"\u65E0\u5E8F\u5217\u8868",icon:"md-iconfont icon-unorder-list",actionName:"list-ul"},{title:"\u6709\u5E8F\u5217\u8868",icon:"md-iconfont icon-order-list",actionName:"list-ol"},"|",{title:"\u884C\u5185\u4EE3\u7801",icon:"md-iconfont icon-code",actionName:"code"},{title:"\u4EE3\u7801\u5757\uFF08\u591A\u8BED\u8A00\u98CE\u683C\uFF09",icon:"md-iconfont icon-file-code",actionName:"code-block"},{title:"\u94FE\u63A5",icon:"md-iconfont icon-link",actionName:"link"},"|",{title:"\u884C\u5185\u516C\u5F0F",icon:"md-iconfont icon-sum",actionName:"inline-latex"},{title:"\u6570\u5B66\u516C\u5F0F",icon:"iconfont icon-shuxuetuxiang2",actionName:"maths-latex"},{title:"\u591A\u884C\u516C\u5F0F",icon:"md-iconfont icon-formula",actionName:"latex"},"|",{title:"\u6DFB\u52A0\u56FE\u7247",icon:"md-iconfont icon-picture",actionName:"upload-image"},{title:"\u63D2\u5165\u753B\u56FE",icon:"iconfont icon-sheji",actionName:"draw-image"},{title:"\u63D2\u5165\u6D41\u7A0B\u56FE",icon:"iconfont icon-liucheng",actionName:"add-flowchart"},{title:"\u8868\u683C",icon:"md-iconfont icon-table",actionName:"add-table"},"|",{title:"\u6362\u884C",icon:"md-iconfont icon-minus",actionName:"line-break"},{title:"\u6E05\u7A7A",icon:"md-iconfont icon-eraser",actionName:"eraser"}];function je({onActionCallback:Ut,title:En,icon:mn,actionName:xn,className:wn="",children:Bn}){function Zn(){Ut(xn)}return z.createElement("a",{title:En,className:wn,onClick:Zn},z.createElement("i",{className:`${mn}`}),Bn)}var Ot=({watch:Ut,showNullButton:En,showNullProgramButton:mn,onActionCallback:xn,fullScreen:wn,insertTemp:Bn,hidetoolBar:Zn,extraUse:Yn})=>{const Wn=[...it,{title:`${Ut?"\u5173\u95ED\u5B9E\u65F6\u9884\u89C8":"\u5F00\u542F\u5B9E\u65F6\u9884\u89C8"}`,icon:`${Ut?"md-iconfont icon-eye-slash":"md-iconfont icon-eye"}`,actionName:"trigger-watch"}];return z.createElement("ul",{className:"markdown-toolbar-container"},!Zn&&Wn.map((ir,gn)=>z.createElement("li",{key:gn},ir.actionName?z.createElement(je,st(mt({},ir),{onActionCallback:xn})):z.createElement("span",{className:"v-line"}))),En?z.createElement("li",null,z.createElement(je,{icon:"iconfont icon-tianjia5 insert-blank",className:"btn-null ml5",title:"\u589E\u52A0\u586B\u7A7A",actionName:"add-null-ch",onActionCallback:xn},z.createElement("span",{className:"fill-tip"},"\u70B9\u51FB\u65B0\u589E\u586B\u7A7A\u9879"))):null,mn?z.createElement(z.Fragment,null,z.createElement("li",null,z.createElement(je,{icon:"md-iconfont icon-edit insert-blank",className:"btn-null",title:"\u589E\u52A0\u586B\u7A7A",actionName:"add-signal",onActionCallback:xn},z.createElement("span",{className:"fill-tip"},"\u6DFB\u52A0\u5355\u884C\u586B\u7A7A\u9879"))),z.createElement("li",null,z.createElement(je,{icon:"md-iconfont icon-uniE900 insert-blank",className:"btn-null",title:"\u589E\u52A0\u586B\u7A7A",actionName:"add-multiple",onActionCallback:xn},z.createElement("span",{className:"fill-tip"},"\u6DFB\u52A0\u591A\u884C\u586B\u7A7A\u9879")))):null,Bn&&z.createElement("li",null,z.createElement(je,{icon:"md-iconfont icon-edit",className:"btn-null",title:"\u63D2\u5165\u6A21\u677F",actionName:`inster-template-${Bn}`,onActionCallback:xn},z.createElement("span",{className:"fill-tip"},"\u63D2\u5165\u6A21\u677F"))),Yn&&z.createElement("li",null,Yn),z.createElement("li",{className:"btn-full-screen"},z.createElement(je,{icon:`${wn?"md-iconfont icon-shrink":"md-iconfont icon-enlarge"}`,title:wn?"\u5173\u95ED\u5168\u5C4F":"\u5F00\u542F\u5168\u5C4F",actionName:"trigger-full-screen",onActionCallback:xn})))},nt=ie(57261),tt=ie(28284),ht=ie(37568),$e=ie(7939),at=Object.defineProperty,lt=Object.defineProperties,me=Object.getOwnPropertyDescriptors,At=Object.getOwnPropertySymbols,De=Object.prototype.hasOwnProperty,He=Object.prototype.propertyIsEnumerable,Pt=(Ut,En,mn)=>En in Ut?at(Ut,En,{enumerable:!0,configurable:!0,writable:!0,value:mn}):Ut[En]=mn,ge=(Ut,En)=>{for(var mn in En||(En={}))De.call(En,mn)&&Pt(Ut,mn,En[mn]);if(At)for(var mn of At(En))He.call(En,mn)&&Pt(Ut,mn,En[mn]);return Ut},ce=(Ut,En)=>lt(Ut,me(En));const Je={labelCol:{span:4},wrapperCol:{span:20}};var jt=({callback:Ut,onCancel:En})=>{function mn(xn){Ut(xn)}return z.createElement(tt.default,ce(ge({},Je),{initialValues:{link:"http://",title:""},className:"link-panel",onFinish:mn,style:{width:500}}),z.createElement(tt.default.Item,{label:"\u94FE\u63A5\u5730\u5740",name:"link",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u94FE\u63A5\u5730\u5740"}]},z.createElement(ht.default,null)),z.createElement(tt.default.Item,{label:"\u94FE\u63A5\u6807\u9898",name:"title",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u94FE\u63A5\u6807\u9898"}]},z.createElement(ht.default,null)),z.createElement("div",{className:"flex-container flex-end"},z.createElement($e.ZP,{type:"primary",htmlType:"submit",style:{marginRight:10}},"\u786E\u5B9A"),z.createElement($e.ZP,{type:"ghost",onClick:En},"\u53D6\u6D88")))},wt=ie(85533),Ie=ie(45053),Ue=ie(62957),et=ie(77019),cn=ie(16750),kt=ie(59301),Yt=({callback:Ut,onCancel:En})=>{const mn=document.createElement("canvas"),xn=mn.getContext("2d");mn.width=1e3,mn.height=800,xn.fillStyle="#ffffff",xn.fillRect(0,0,mn.width,mn.height);const wn=mn.toDataURL("image/png");return kt.createElement(Ue.default,{open:!0,width:"100vw",style:{height:"100vh",top:0},footer:null,title:null,closable:!1},kt.createElement(et.Z,{style:{height:"100vh"}},kt.createElement(cn.Z,{fullWidth:!0,noAssociationId:!0,showFullTools:!0,data:{src:wn,visible:!0,title:String(Date.now())},onOk:Bn=>{Ut({src:Bn.url})},onClose:En})))},ze=ie(36207),zt=ie(5269),ut=ie(6767),ae={myPaletteDiv:"myPaletteDiv___Xjz2I",flowChartWrp:"flowChartWrp____f45r",maxH60:"maxH60___Pd4Re",drawerWrap:"drawerWrap___MfDw8"},te=ie(59301),oe=(0,z.forwardRef)(({onCancel:Ut,editImgId:En,callback:mn},xn)=>{let wn=(0,z.useRef)(),Bn=(0,z.useRef)(),Zn=(0,z.useRef)(),Yn=(0,z.useRef)(!1);const Wn=(0,z.useRef)(!1);console.log("ref:",xn);const[ir,gn]=(0,z.useState)(0),[Dt,Qt]=(0,z.useState)("100vh");return(0,z.useEffect)(()=>{gn(1)},[]),(0,z.useImperativeHandle)(xn,()=>({setHeight:Qt})),te.createElement("div",{ref:Wn,className:"body-overflow-initial"},te.createElement(ze.Z,{width:"100vw",height:Dt,footer:null,closable:!0,placement:"bottom",open:!!ir,destroyOnClose:!0,maskClosable:!1,mask:!1,rootClassName:`zIndex-9999 ${ae.drawerWrap}`,onClose:()=>{window.saveDrawData(Un=>{mn({src:`/api/attachments/${Un}`,id:Un})})},title:te.createElement(et.Z,{align:"middle"},te.createElement(zt.Z,{flex:1},"\u63D2\u5165\u6D41\u7A0B\u56FE"),te.createElement(zt.Z,{onClick:()=>{Qt(Dt==="60px"?"100vh":"60px")}},te.createElement("span",{className:"current c-blue",style:{fontWeight:400}},"\u5C55\u5F00/\u6536\u8D77")),te.createElement(zt.Z,{onClick:()=>{window.saveDrawData(Un=>{if(Un===null){ut.ZP.warning({content:"\u5185\u5BB9\u4E3A\u7A7A\uFF0C\u8BF7\u5148\u7ED8\u5236\u6D41\u7A0B\u56FE",key:"saveFlowChart"});return}ut.ZP.success({content:"\u4FDD\u5B58\u6210\u529F",key:"saveFlowChart",style:{zIndex:999999999}}),mn({src:`/api/attachments/${Un}`,id:Un,disabledClose:!0})})}},te.createElement($e.ZP,{type:"primary",className:"ml20"},"\u4FDD\u5B58")))},te.createElement("iframe",{src:`/drawio/src/main/webapp/?id=${En||""}&gapi=0&od=0&db=0&gh=0&gl=0&local=0`,width:"100%",height:"100%",frameBorder:"0",ref:Bn})))}),se=ie(74128),ne=ie(47889),he=ie(4875);const xe=ne.ZP.Group,ot={margin:"0 8px"};var Ee=({callback:Ut,onCancel:En})=>{function mn(xn){Ut(xn)}return z.createElement(tt.default,{className:"add-table-panel",initialValues:{row:3,col:2,align:"default"},onFinish:mn},z.createElement("div",{className:"flex-container",style:{alignItems:"baseline"}},z.createElement("span",{style:ot},"\u5355\u5143\u683C\u6570\uFF1A"),z.createElement("span",{style:ot},"\u884C\u6570"),z.createElement(tt.default.Item,{name:"row",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u884C\u6570"}]},z.createElement(he.Z,null)),z.createElement("span",{style:ot},"\u5217\u6570"),z.createElement(tt.default.Item,{name:"col",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u5217\u6570"}]},z.createElement(he.Z,null))),z.createElement("div",{className:"flex-container",style:{marginTop:12,alignItems:"baseline"}},z.createElement("span",{style:ot},"\u5BF9\u9F50\u65B9\u5F0F\uFF1A"),z.createElement(tt.default.Item,{name:"align"},z.createElement(xe,null,z.createElement(ne.ZP,{value:"default"},z.createElement("i",{className:"fa fa-align-justify"})),z.createElement(ne.ZP,{value:"left"},z.createElement("i",{className:"fa fa-align-left"})),z.createElement(ne.ZP,{value:"center"},z.createElement("i",{className:"fa fa-align-center"})),z.createElement(ne.ZP,{value:"right"},z.createElement("i",{className:"fa fa-align-right"}))))),z.createElement("div",{className:"flex-container flex-end"},z.createElement($e.ZP,{type:"primary",htmlType:"submit",style:{marginRight:10}},"\u786E\u5B9A"),z.createElement($e.ZP,{type:"ghost",onClick:En},"\u53D6\u6D88")))},Fe=ie(58755),qe=ie(93510),bt=ie.n(qe),Kt=(0,z.forwardRef)(({use3d:Ut,width:En,height:mn,callback:xn,showSaveButton:wn},Bn)=>{const Zn=(0,z.useRef)(),Yn=(0,z.useRef)(),[Wn,ir]=(0,z.useState)(!1),gn=(0,z.useRef)({id:Zn,appName:"graphing",width:En||1e3,height:mn||600,showToolBar:!0,showMenuBar:!0,allowStyleBar:!0,showAlgebraInput:!0,enableLabelDrags:!1,enableShiftDragZoom:!0,showToolBarHelp:!1,errorDialogsActive:!0,showTutorialLink:!0,showLogging:!0,useBrowserForJS:!1});(0,z.useEffect)(()=>{Yn.current=new(bt())(gn.current,!0),window.onload=function(){Yn.current.inject("applet_container")}},[]);const Dt=()=>{var Qt=window.ggbApplet.getPNGBase64(1,!0,72);return xn&&xn(Qt),Qt};return(0,z.useEffect)(()=>{gn.current.appName=Wn?"3D":"graphing",Yn.current.inject("applet_container")},[Wn]),(0,z.useEffect)(()=>{ir(Ut)},[Ut]),(0,z.useImperativeHandle)(Bn,()=>({getImgData:Dt})),z.createElement(z.Fragment,null,z.createElement("div",{style:{width:"100%",height:"100%"},id:"applet_container",ref:Zn}),z.createElement(et.Z,{align:"middle"},z.createElement(zt.Z,{flex:1},z.createElement(Fe.Z,{size:"default",checkedChildren:"\u5173\u95ED3D\u56FE\u50CF",unCheckedChildren:"\u5F00\u542F3D\u56FE\u50CF",checked:Wn,onChange:Qt=>ir(Qt)})),z.createElement(zt.Z,null,z.createElement($e.ZP,{size:"large",onClick:Dt,style:{zIndex:8,marginTop:10},type:"primary"},"\u4FDD\u5B58\u5230\u7F16\u8F91\u5668"))))}),Wt=ie(99298);const Nt="link",rn="upload-image",qt="add-flowchart",on="draw-image",ft="add-flowchart",Gt="code-block",Tt="add-table",en="------------",yn={default:en,left:`:${en}`,center:`:${en}:`,right:`${en}:`};var Rn=ie(31103),On=ie(65862);function Pe(){}let rt=0;const St=1e4,_t="\u2581",bn="@\u2581\u2581@",In="@\u2581@",rr=`
|
|
|
**\u6A21\u677F\u6807\u9898**
|
|
|
\u6A21\u677F\u6B63\u6587\u5185\u5BB9\uFF0C\u53EF\u8F93\u5165\u6587\u672C\u5185\u5BB9\u548C\u7C98\u8D34\u56FE\u7247\u7B49\u64CD\u4F5C`,Xn=["pptm","pptx","ppt","pot","pps","ppa","potx","ppsx","ppam","pptm","potm","ppsm","doc","docx","dot","dotx","docm","dotm","xls","xlsx","csv","xlt","xla","xltx","xlsm","xltm","xlam","xlsb"];function Cn(Ut){return/^\d+$/.test(Ut)?`${Ut}px`:Ut}const xt=navigator.platform.toUpperCase().indexOf("MAC")>=0?"Cmd":"Ctrl",$t={[xt+"-B"]:"bold",[xt+"-I"]:"italic"},vt={[Nt]:"\u6DFB\u52A0\u94FE\u63A5",[Gt]:"\u6DFB\u52A0\u4EE3\u7801\u5757",[rn]:"\u6DFB\u52A0\u56FE\u7247",[on]:"\u6DFB\u52A0\u753B\u56FE",[qt]:"\u63D2\u5165\u6D41\u7A0B\u56FE",[Tt]:"\u6DFB\u52A0\u8868\u683C","maths-latex":"\u6570\u5B66\u56FE\u50CF","inline-latex":"LATEX\u516C\u5F0F"};var Vt=({defaultValue:Ut="",onChange:En,width:mn="100%",height:xn=400,miniToolbar:wn=!1,isFocus:Bn=!1,watch:Zn,insertTemp:Yn,mode:Wn="markdown",id:ir="markdown-editor-id",showResizeBar:gn=!1,noStorage:Dt=!1,showNullButton:Qt=!1,showNullProgramButton:Un=!1,hidetoolBar:fr=!1,fullScreen:ke=!1,onBlur:_e,onCMBeforeChange:Ce,onFullScreen:Be,className:we="",disablePaste:Te=!1,disabled:Qe=!1,disabledFill:nn=!1,placeholder:sn="",values:Xt="",extraUse:Ht,onAddBlank:Ct})=>{const[pt,un]=(0,z.useState)(null),[$n,Dn]=(0,z.useState)(Ut),[kn,pr]=(0,z.useState)(Zn),[gt,Ve]=(0,z.useState)(ke),[Et,Rt]=(0,z.useState)(""),[Zt,hn]=(0,z.useState)(0),[Hn,Sn]=(0,z.useState)(xn),[Tn,An]=(0,z.useState)(!1),[jn,Pn]=(0,z.useState)(0),[lr,Jn]=(0,z.useState)(0),Kn=(0,z.useRef)(),sr=(0,z.useRef)(),mr=(0,z.useRef)(),Qn=(0,z.useRef)(),cr=(0,z.useRef)(),Gn=(0,z.useRef)(),vr=(0,Ke.useDispatch)();(0,z.useEffect)(()=>{const an=window.scrollY||window.pageYOffset;Dn(Xt),pt==null||pt.setValue(Xt),window.scrollTo(0,an)},[Xt]),(0,z.useEffect)(()=>{Be==null||Be(gt)},[gt]),(0,z.useEffect)(()=>{if(Kn.current){let an=function(Nn,Ln){var yr;if(Te){Ln.preventDefault();return}const Mr=Ln.clipboardData;if(Mr){const Cr=Mr.types.toString(),Ar=Mr.items;if(Cr==="Files"||Mr.types.indexOf("Files")>-1){if(Ln.preventDefault(),Wn=="stex")return;try{let Tr=Ar[1];((yr=Ar[0])==null?void 0:yr.kind)==="file"&&(Tr=Ar[0]);const Lr=Tr.getAsFile(),Dr=Lr.name.split(".").pop();(0,Ie.I)(Lr,Nr=>{var Fr,Gr,Qr;Nr.id?((Fr=Lr==null?void 0:Lr.type)==null?void 0:Fr.indexOf("image"))>-1?dn.replaceSelection(`<img width="100%" src="/api/attachments/${Nr.id}?type=${Nr.content_type})" alt="" />`):((Gr=Lr==null?void 0:Lr.type)==null?void 0:Gr.indexOf("video"))>-1?dn.replaceSelection(`<video width="100%" controls src="/api/attachments/${Nr.id}"></video>`):((Qr=Lr==null?void 0:Lr.type)==null?void 0:Qr.indexOf("pdf"))>-1?dn.replaceSelection(`<a href="/api/attachments/${Nr.id}?type=${Lr.type}&disposition=inline" target="_blank">${Lr.name}</a>`):Xn.includes(Dr)?dn.replaceSelection(`<a href="/api/attachments/${Nr.id}?type=office&disposition=inline" target="_blank">${Lr.name}</a>`):dn.replaceSelection(`[${Lr.name}](/api/attachments/${Nr.id}?type=${Nr.content_type})`):(Nr==null?void 0:Nr.status)===401&&(document.location.href="/user/login")})}catch(Tr){ut.ZP.warning("\u8BF7\u4F7F\u7528chrome\u6D4F\u89C8\u5668\u7C98\u8D34")}return!0}else return!0}return!0};const dn=Ae().fromTextArea(Kn.current,{mode:Wn,lineNumbers:!wn,lineWrapping:!0,value:Ut,autoCloseTags:!0,autoCloseBrackets:!0});return dn.on("keyup",function(Nn,Ln){Ln.keyCode===8&&(Nn.getValue()==""?dn.setOption("placeholder",sn):dn.setOption("placeholder",null))}),dn.on("keydown",function(Nn,Ln){if(Ln.keyCode===8){var yr=Sr(Nn);yr&&Ln.preventDefault()}}),Bn&&dn.focus(),dn.on("paste",an),Qe&&dn.on("beforeChange",function(Nn,Ln){(Ln.origin==="paste"||Ln.origin==="+input")&&Ln.cancel()}),un(dn),()=>{dn.off("paste",an)}}},[]);const qn=(0,z.useCallback)(()=>{if(sr.current)try{}catch(an){console.log(an,"---- to set md editor body height")}},[Hn,sr,gt]);(0,z.useEffect)(()=>{function an(){let dn=new ye.Z(Nn=>{for(let Ln of Nn)(Ln.target.offsetHeight>0||Ln.target.offsetWidth>0)&&(qn(),pt.setSize("100%","100%"),pt.refresh())});return dn.observe(Kn.current.parentElement),dn}if(pt){const dn=an();return()=>{var Nn,Ln;(Nn=Kn.current)!=null&&Nn.parentElement&&dn.unobserve((Ln=Kn.current)==null?void 0:Ln.parentElement)}}},[pt,qn]),(0,z.useEffect)(()=>{if(pt){let an=[];for(const[dn,Nn]of Object.entries($t)){let Ln={[dn]:()=>{ar(Nn)}};an.push(Ln),pt.addKeyMap(Ln)}return()=>{for(let dn of an)pt.removeKeyMap(dn)}}},[pt]),(0,z.useEffect)(()=>{ke!==gt&&Ve(ke)},[ke]),(0,Rn.Z)(()=>{if(!Dt&&Zt>0){let an=new Date().getTime(),dn=window.sessionStorage.getItem(ir);an>=Zt+St&&(!dn||dn!==$n)&&(window.sessionStorage.setItem(ir,$n),An(!0))}},St),(0,z.useEffect)(()=>{pr(Zn)},[pt,Zn]),(0,z.useEffect)(()=>{pt&&Bn&&pt.focus()},[pt,Bn]),(0,z.useEffect)(()=>{if(kn&&pt){let an=function(Nn){let Ln=Nn.target;if(Qn.current){let yr=Ln.scrollTop/Ln.scrollHeight;Qn.current.scrollTop=Qn.current.scrollHeight*yr}};const dn=pt.getScrollerElement();return dn.addEventListener("scroll",an),()=>{dn.removeEventListener("scroll",an)}}},[pt,kn]),(0,z.useEffect)(()=>{if(pt&&Ce){let an=function(dn,Nn){Ce(dn,Nn)};return pt.on("beforeChange",an),()=>{pt.off("beforeChange",an)}}},[pt,Ce]),(0,z.useEffect)(()=>{if(pt&&_e){let an=function(){_e(pt.getValue())};return pt.on("blur",an),()=>{pt.off("blur",an)}}},[pt,_e]);function Sr(an,dn){var Nn=an.getDoc(),Ln=Nn.getCursor(),yr=Nn.getLine(Ln.line),Mr=yr.charAt(Ln.ch-1),Cr=yr.lastIndexOf("@\u2581@",Ln.ch),Ar=yr.lastIndexOf("@\u2581\u2581@",Ln.ch),Tr=Cr>Ar?Cr:Ar,Lr=Cr>Ar?3:4;if(bn.indexOf(Mr)===-1)return null;if(console.log("change1:",dn,an,yr,Ln,Tr,Cr,Ar,Mr),Tr>=0&&Ln.ch-Tr<5){var Dr=Tr+Lr;return Nn.replaceRange("",{line:Ln.line,ch:Tr},{line:Ln.line,ch:Dr}),{line:Ln.line,ch:Dr}}return null}(0,z.useEffect)(()=>{if(pt){let an=function(dn,Nn){const Ln=dn.getValue();Dn(Ln),hn(new Date().getTime()),dn.getScrollerElement().dispatchEvent(new CustomEvent("scroll")),En&&(Un?En(Ln,fn(Ln)):En(Ln))};return pt.on("change",an),()=>{pt.off("change",an)}}},[pt,En]),(0,z.useEffect)(()=>{if(pt)if(Ut==null)pt.setValue(""),Dn("");else{const an=window.scrollY||window.pageYOffset;Ut!==pt.getValue()&&(pt.setValue(Ut),Dn(Ut),pt.setCursor(Qe?1:pt.lineCount(),0),window.scrollTo(0,an))}},[pt,Ut]);const ar=(0,z.useCallback)(an=>{const dn=pt.getCursor(),Nn=pt.getSelection();let Ln=Nn.split(`
|
|
|
`);switch(an){case"bold":return pt.replaceSelection("**"+Nn+"**"),Nn===""&&pt.setCursor(dn.line,dn.ch+2),pt.focus();case"italic":return pt.replaceSelection("*"+Nn+"*"),Nn===""&&pt.setCursor(dn.line,dn.ch+1),pt.focus();case"code":return pt.replaceSelection("`"+Nn+"`"),Nn===""&&pt.setCursor(dn.line,dn.ch+1),pt.focus();case"inline-latex":return(0,On.Ye)(vr)?void 0:(Rt("inline-latex"),pt.focus());case"latex":return pt.replaceSelection("```latex\n"+Nn+"\n```"),pt.setCursor(dn.line+1,Nn.length+1),pt.focus();case"line-break":return pt.replaceSelection(`<br/>
|
|
|
`),pt.focus();case"list-ul":return Nn===""?pt.replaceSelection("- "+Nn):pt.replaceSelection(Ln.map(yr=>yr===""?"":`- ${yr}`).join(`
|
|
|
`)),pt.focus();case"list-ol":return Nn===""?pt.replaceSelection("1. "+Nn):pt.replaceSelection(Ln.map((yr,Mr)=>yr===""?"":`${Mr+1}. ${yr}`).join(`
|
|
|
`)),pt.focus();case"add-null-ch":Ct==null||Ct();return;case"add-signal":return Nn===""&&pt.setCursor(dn.line,dn.ch),pt.replaceSelection(In),pt.focus();case"add-multiple":return Nn===""&&pt.setCursor(dn.line,dn.ch),pt.replaceSelection(bn),pt.focus();case"inster-template-1":return Nn===""&&pt.setCursor(dn.line,dn.ch),pt.replaceSelection(rr),pt.focus();case"eraser":return pt.setValue(""),pt.focus();case"trigger-watch":return pr(!kn),pt.focus();case"trigger-full-screen":return Ve(!gt),pt.focus();case Nt:Rt(Nt);return;case Gt:Rt(Gt);return;case rn:Rt(rn);return;case on:Rt(on);return;case"maths-latex":if((0,On.Ye)(vr))return;Rt("maths-latex");return;case qt:cr.current="",sessionStorage.removeItem("file_id"),Rt(qt);return;case Tt:Rt(Tt);return;default:throw new Error}},[pt,kn,gt]),or=(0,z.useCallback)((an,dn)=>{var Nn,Ln,yr,Mr,Cr,Ar;an!=null&&an.disabledClose||Rt("");const{src:Tr,alt:Lr,id:Dr}=an||{};switch(Et){case Nt:const{title:ri,link:Wr}=an;return pt.replaceSelection(`[${ri}](${Wr})`),pt.focus();case Gt:const{language:jr,content:Ur}=an;return pt.replaceSelection(["```"+jr,Ur,"```"].join(`
|
|
|
`)),pt.focus();case"maths-latex":for(var Nr=atob(an),Fr=new Uint8Array(Nr.length),Gr=0;Gr<Nr.length;Gr++)Fr[Gr]=Nr.charCodeAt(Gr);var Qr=new Blob([Fr],{type:"image/png"});(0,Ie.I)(Qr,hi=>{hi.id?pt.replaceSelection(``):(hi==null?void 0:hi.status)===401&&(document.location.href="/user/login")});break;case"inline-latex":if((0,On.Ye)(vr))return;pt.replaceSelection("`$$"+an+"$$`");break;case ft:if(!Dr)return;pt.getValue().indexOf(Tr)===-1?pt.replaceSelection(`<center><img id="${Dr}" width="80%" src="${Tr}" class="draw-flowchart" alt="${Lr||""}" /></center>`):document.getElementById(Dr).src=se.Z.API_SERVER+Tr+"?t="+Date.now();break;case rn:case on:const kr=dn,Jr=(yr=(Ln=(Nn=kr==null?void 0:kr.name)==null?void 0:Nn.split("."))==null?void 0:Ln.pop)==null?void 0:yr.call(Ln);return((Mr=kr==null?void 0:kr.type)==null?void 0:Mr.indexOf("image"))>-1||!(kr!=null&&kr.type)?kr!=null&&kr.align||kr!=null&&kr.width?pt.replaceSelection(`<p style="text-align:${kr.align||"initial"}"><img width="${kr.width?kr.width+"%":"initial"}" src="${Tr}" alt="${Lr||""}" /></p>`):pt.replaceSelection(`<img width="100%" src="${Tr}" alt="${Lr||""}" />`):((Cr=kr==null?void 0:kr.type)==null?void 0:Cr.indexOf("video"))>-1?pt.replaceSelection(`<video width="100%" controls src="${Tr}"></video>`):((Ar=kr==null?void 0:kr.type)==null?void 0:Ar.indexOf("pdf"))>-1?pt.replaceSelection(`<a href="${Tr}?type=${kr.type}&disposition=inline" target="_blank">${kr.name}</a>`):Xn.includes(Jr)?pt.replaceSelection(`<a href="${Tr}?type=office&disposition=inline" target="_blank">${kr.name}</a>`):pt.replaceSelection(`[${kr.name}](${Tr})`),pt.focus();case Tt:const{row:Xr,col:li,align:Ci}=an;let fi=`
|
|
|
`;for(let hi=0;hi<Xr;hi++){let Ii=[],_r=[];for(let si=0;si<li;si++)hi===1&&_r.push(yn[Ci]),Ii.push(" ");hi===1&&(fi+=`| ${_r.join(" | ")} |
|
|
|
`),fi+=`| ${Ii.join(li===1?"":" | ")} |
|
|
|
`}return pt.replaceSelection(fi+`
|
|
|
`),pt.focus();default:throw new Error}},[pt,Et]),hr=(0,z.useMemo)(()=>{switch(Et){case Nt:return z.createElement(jt,{callback:or,onCancel:xr});case Gt:return z.createElement(wt.Z,{callback:or,onCancel:xr});case rn:return z.createElement(Ie.Z,{callback:or,onCancel:xr});case qt:return z.createElement(oe,{editImgId:cr.current,callback:or,onCancel:xr});case Tt:return z.createElement(Ee,{callback:or,onCancel:xr});case"maths-latex":return z.createElement(Kt,{showSaveButton:!0,callback:or});case"inline-latex":return z.createElement(Wt.Z,{showSaveButton:!0,callback:or});default:return null}},[Et]);function xr(){Rt("")}(0,z.useEffect)(()=>{if(mr.current){let an=function(Cr){yr=!0,Mr=Cr.pageY},dn=function(){yr=!1},Nn=function(Cr){if(yr){let Ar=Cr.pageY-Mr;Ar<0&&(Ar=0),Ar>300&&(Ar=300);let Tr=xn+Ar+"px";Sn(Tr)}},Ln=mr.current,yr=!1,Mr=0;return Ln.addEventListener("mousedown",an),document.addEventListener("mousemove",Nn),document.addEventListener("mouseup",dn),()=>{Ln.removeEventListener("mousedown",an),document.removeEventListener("mousemove",Nn),document.removeEventListener("mouseup",dn)}}},[pt,mr]),(0,z.useEffect)(()=>{Sn(xn)},[xn]);const br=Cn(mn),dr=Cn(Hn),er={width:br,height:dr},tn=(0,z.useMemo)(()=>{if(Zt){let an=new Date(Zt),dn=an.getHours(),Nn=an.getMinutes(),Ln=an.getSeconds();return dn=dn<10?"0"+dn:dn,Nn=Nn<10?"0"+Nn:Nn,Ln=Ln<10?"0"+Ln:Ln,`${dn}:${Nn}:${Ln}`}return 0},[Zt]),fn=an=>{const dn=[];if(Un){let Nn=-1;an=an.replace(/(@▁▁@|@▁@)/g,function(Ln,yr,Mr){dn.push({multiLine:Ln!==In})})}return dn};function pn(){window.sessionStorage.removeItem(ir),An(!1),hn(0)}function Jt(){An(!1),hn(0),pt.setValue(window.sessionStorage.getItem(ir))}(0,z.useEffect)(()=>{vt[Et]&&Et!==on&&Et!==qt&&setTimeout(()=>{const an=document.getElementsByClassName("markdown-popup-form")[0],dn=window.innerWidth/2-an.offsetWidth/2,Nn=window.innerHeight/2-an.offsetHeight/2;Pn(dn),Jn(Nn)},0)},[Et]);const zn=an=>{an.preventDefault();const dn=an.clientX-jn,Nn=an.clientY-lr;document.body.onmousemove=Ln=>{let yr=Ln.clientX-dn,Mr=Ln.clientY-Nn;const Cr=document.getElementsByClassName("markdown-popup-form")[0],Ar=window.innerWidth-Cr.offsetWidth,Tr=window.innerHeight-Cr.offsetHeight;yr=Math.max(0,Math.min(yr,Ar)),Mr=Math.max(0,Math.min(Mr,Tr)),_n(Ln.clientX,Ln.clientY,dn,Nn)&&(Pn(yr),Jn(Mr))},document.body.onmouseup=function(){document.body.onmousemove=null}},_n=(an,dn,Nn,Ln)=>{const yr=document.body.clientHeight,Mr=document.body.clientWidth;return an<20&&Nn>an||an>Mr-20&&Nn<an||dn<20&&Ln>dn||dn>yr-20&&Ln<dn?(document.body.onmousemove=null,document.body.onmouseup=null,!1):!0};return z.createElement(z.Fragment,null,z.createElement("div",{className:"markdown-editor-wrapper",ref:sr},z.createElement("div",{className:`markdown-editor-container ${we} ${kn?"on-preview":""} ${wn?"mini":""} ${gt?"full-screen":""}`,style:er},z.createElement(Ot,{insertTemp:Yn,watch:kn,fullScreen:gt,showNullButton:Qt,showNullProgramButton:Un,onActionCallback:ar,hidetoolBar:fr,extraUse:Ht}),z.createElement("div",{className:"markdown-editor-body"},z.createElement("div",{className:"codemirror-container"},z.createElement("textarea",{ref:Kn,placeholder:sn})),kn?z.createElement("div",{ref:Qn,className:"preview-container"},Wn==="stex"&&z.createElement(yt,{value:$n}),Wn!=="stex"&&z.createElement(Se.Z,{edit:!0,disabledFill:nn,showProgramFill:Un,value:$n,openEditor:an=>{var dn;cr.current=an,(dn=Gn.current)==null||dn.setHeight("100vh"),setTimeout(()=>{Rt("add-flowchart")},150)}})):null))),gn?z.createElement("a",{ref:mr,className:"editor-resize"}):null,Et===on&&z.createElement(Yt,{callback:or,onCancel:xr}),Et===qt&&z.createElement(oe,{ref:Gn,editImgId:cr.current,callback:or,onCancel:xr}),z.createElement(nt.Z,null,vt[Et]&&Et!==on&&Et!==qt?z.createElement(Ue.default,{maskClosable:!1,centered:!0,style:{position:"absolute",left:jn,top:lr},title:z.createElement("div",{style:{cursor:"move"},onMouseDown:zn},vt[Et]),open:!0,onCancel:xr,footer:null,destroyOnClose:!0,width:Et===qt?"1200px":null,height:Et===qt?"80vh":null,className:"markdown-popup-form"},hr):null))}},45053:function(ln,Ft,ie){"use strict";ie.d(Ft,{Z:function(){return it},I:function(){return Ot}});var z=ie(28284),Ke=ie(6767),ve=ie(37568),Ae=ie(44104),ye=ie(4875),be=ie(47889),Me=ie(7939),Re=ie(28735),Oe=ie(59301),fe=ie(59301),We=Object.defineProperty,Se=Object.defineProperties,yt=Object.getOwnPropertyDescriptors,Xe=Object.getOwnPropertySymbols,Le=Object.prototype.hasOwnProperty,Ge=Object.prototype.propertyIsEnumerable,Ne=(nt,tt,ht)=>tt in nt?We(nt,tt,{enumerable:!0,configurable:!0,writable:!0,value:ht}):nt[tt]=ht,dt=(nt,tt)=>{for(var ht in tt||(tt={}))Le.call(tt,ht)&&Ne(nt,ht,tt[ht]);if(Xe)for(var ht of Xe(tt))Ge.call(tt,ht)&&Ne(nt,ht,tt[ht]);return nt},It=(nt,tt)=>Se(nt,yt(tt));const{useForm:Bt}=z.default,mt={width:280,marginRight:10},st={labelCol:{span:5},wrapperCol:{span:19}};var it=({callback:nt,onCancel:tt})=>{const[ht]=Bt();let $e=(0,Oe.useRef)();function at(At){$e.current.width=ht.getFieldValue("width"),$e.current.align=ht.getFieldValue("align"),nt(At,$e.current)}function lt(At,De){if(At.status===-1){Ke.ZP.error(At.message);return}ht.setFieldsValue({src:`/api/attachments/${At.id}`,type:De.type})}function me(At){let De=At.target.files[0];$e.current=De,Ot(De,lt)}return fe.createElement(z.default,It(dt({form:ht},st),{className:"upload-image-panel",onFinish:at,style:{width:470,overflow:"hidden"}}),fe.createElement(z.default.Item,{label:"\u56FE\u7247\u5730\u5740",required:!0},fe.createElement("div",{className:"flex-container"},fe.createElement(z.default.Item,{noStyle:!0,name:"src",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u56FE\u7247\u5730\u5740"}]},fe.createElement(ve.default,{style:mt})),fe.createElement(je,{onFileChange:me}))),fe.createElement(z.default.Item,{label:"\u56FE\u7247\u63CF\u8FF0",name:"alt"},fe.createElement(ve.default,{style:{width:264}})),fe.createElement(z.default.Item,{label:"\u56FE\u7247\u5BBD\u5EA6",name:"width"},fe.createElement(Ae.Z,null,fe.createElement(z.default.Item,{name:"width",style:{margin:0}},fe.createElement(ye.Z,{style:{width:264}})),fe.createElement("span",{className:"ml8"},"%"))),fe.createElement(z.default.Item,{label:"\u5BF9\u9F50\u65B9\u5F0F",name:"align"},fe.createElement(be.ZP.Group,{name:"align",defaultValue:1,options:[{value:"left",label:"\u5DE6\u5BF9\u9F50"},{value:"center",label:"\u5C45\u4E2D\u5BF9\u9F50"},{value:"right",label:"\u53F3\u5BF9\u9F50"}]})),fe.createElement("aside",null,fe.createElement(z.default.Item,{style:{textAlign:"right",position:"relative",right:-98}},fe.createElement(Me.ZP,{type:"primary",htmlType:"submit",style:{marginRight:10}},"\u786E\u5B9A"),fe.createElement(Me.ZP,{type:"default",onClick:tt},"\u53D6\u6D88"))))};function je({onFileChange:nt}){return fe.createElement("label",{className:"upload-button",style:{cursor:"pointer"}},"\u672C\u5730\u4E0A\u4F20",fe.createElement("input",{type:"file",onChange:nt}))}function Ot(nt,tt){if(!nt)throw new String("\u6CA1\u6709\u6587\u4EF6");let ht=new FormData;ht.append("editormd-image-file",nt),ht.append("file_param_name","editormd-image-file"),ht.append("byxhr","true");var $e=new window.XMLHttpRequest;$e.withCredentials=!0,$e.addEventListener("load",function(at){tt(JSON.parse(at.target.responseText),nt)},!1),$e.addEventListener("error",function(at){console.error(at)},!1),$e.open("POST",`${Re.KI}/api/attachments.json`),$e.send(ht)}},57261:function(ln,Ft,ie){"use strict";ie.d(Ft,{Z:function(){return ve}});var z=ie(59301),Ke=ie(4676);class ve extends z.Component{constructor(ye){super(ye);const be=window.document;this.node=be.createElement("div"),be.body.appendChild(this.node)}render(){const{children:ye}=this.props;return(0,Ke.createPortal)(ye,this.node)}componentWillUnmount(){window.document.body.removeChild(this.node)}}},50258:function(ln,Ft,ie){"use strict";ie.d(Ft,{SV:function(){return Yt},ZP:function(){return kt}});var z=ie(59301),Ke=ie(76374);const ve={keywords:["print","auto","break","case","char","const","continue","default","do","double","else","enum","extern","float","for","goto","if","int","long","register","return","short","signed","sizeof","static","struct","switch","typedef","union","unsigned","void","volatile","while"]},Ae={quickKey:[{label:"main",content:["public static void main(String[] args) {"," $0","}"].join(`
|
|
|
`)},{label:"System.out.println",content:["System.out.println($0)"].join(`
|
|
|
`)},{label:"System.out.print",content:["System.out.print($0)"].join(`
|
|
|
`)}],keywords:["abstract","continue","for","new","switch","assert","default","goto","package","synchronized","boolean","do","if","private","this","break","double","implements","protected","throw","byte","else","import","public","throws","case","enum","instanceof","return","transient","catch","extends","int","short","try","char","final","interface","static","void","class","finally","long","strictfp","volatile","const","float","native","super","while","true","false"]},ye={keywords:["abstract","amp","array","auto","bool","break","case","catch","char","class","const","constexpr","const_cast","continue","cpu","decltype","default","delegate","delete","do","double","dynamic_cast","each","else","enum","event","explicit","export","extern","false","final","finally","float","friend","gcnew","generic","goto","in","initonly","inline","int","interface","interior_ptr","internal","literal","long","mutable","namespace","new","noexcept","nullptr","__nullptr","operator","override","partial","pascal","pin_ptr","private","property","protected","public","ref","register","reinterpret_cast","restrict","return","safe_cast","sealed","short","signed","sizeof","static","static_assert","static_cast","struct","switch","template","this","thread_local","throw","tile_static","true","try","typedef","typeid","typename","union","unsigned","using","virtual","void","volatile","wchar_t","where","while","_asm","_based","_cdecl","_declspec","_fastcall","_if_exists","_if_not_exists","_inline","_multiple_inheritance","_pascal","_single_inheritance","_stdcall","_virtual_inheritance","_w64","__abstract","__alignof","__asm","__assume","__based","__box","__builtin_alignof","__cdecl","__clrcall","__declspec","__delegate","__event","__except","__fastcall","__finally","__forceinline","__gc","__hook","__identifier","__if_exists","__if_not_exists","__inline","__int128","__int16","__int32","__int64","__int8","__interface","__leave","__m128","__m128d","__m128i","__m256","__m256d","__m256i","__m64","__multiple_inheritance","__newslot","__nogc","__noop","__nounwind","__novtordisp","__pascal","__pin","__pragma","__property","__ptr32","__ptr64","__raise","__restrict","__resume","__sealed","__single_inheritance","__stdcall","__super","__thiscall","__try","__try_cast","__typeof","__unaligned","__unhook","__uuidof","__value","__virtual_inheritance","__w64","__wchar_t"],operators:["=",">","<","!","~","?",":","==","<=",">=","!=","&&","||","++","--","+","-","*","/","&","|","^","%","<<",">>",">>>","+=","-=","*=","/=","&=","|=","^=","%=","<<=",">>=",">>>="],quickKey:[{label:"ifelse",content:["if (${1:condition}) {"," $0","} else {"," ","}"].join(`
|
|
|
`)},{label:"include",content:"include<$0>"},{label:"printf",content:"printf($0)"},{label:"system",content:'system("$0")'},{label:"main",content:["int main () {"," $0","}"].join(`
|
|
|
`)},{label:"if",content:["if () {"," $0","}"].join(`
|
|
|
`)},{label:"for",content:["for(int j=0 ; j<10; j++){"," $0","}"].join(`
|
|
|
`)},{label:"trycatch",content:["try{"," $0","}catch(ExceptionName e){","}"].join(`
|
|
|
`)},{label:"using namespace std",content:["using namespace std"].join(`
|
|
|
`)},{label:"include <iostream>",content:["#include <iostream>"].join(`
|
|
|
`)},{label:"include <vector>",content:["#include <vector>"].join(`
|
|
|
`)},{label:"include <cstdio>",content:["#include <cstdio>"].join(`
|
|
|
`)},{label:"include <cstring>",content:["#include <cstring>"].join(`
|
|
|
`)},{label:"include <sstream>",content:["#include <sstream>"].join(`
|
|
|
`)},{label:"include <fstream>",content:["#include <fstream>"].join(`
|
|
|
`)},{label:"include <map>",content:["#include <map>"].join(`
|
|
|
`)},{label:"include <string>",content:["#include <string>"].join(`
|
|
|
`)},{label:"include <cmath>",content:["#include <cmath>"].join(`
|
|
|
`)}]},be={keywords:["and","as","assert","break","class","continue","def","del","elif","else","except","exec","finally","for","from","global","if","import","in","is","lambda","None","not","or","pass","raise","return","self","try","while","with","yield","int","float","long","complex","hex","abs","all","any","apply","basestring","bin","bool","buffer","bytearray","callable","chr","classmethod","cmp","coerce","compile","complex","delattr","dict","dir","divmod","enumerate","eval","execfile","file","filter","format","frozenset","getattr","globals","hasattr","hash","help","id","input","intern","isinstance","issubclass","iter","len","locals","list","map","max","memoryview","min","next","object","oct","open","ord","pow","print","property","reversed","range","raw_input","reduce","reload","repr","reversed","round","set","setattr","slice","sorted","staticmethod","str","sum","super","tuple","type","unichr","unicode","vars","xrange","zip","True","False","__dict__","__methods__","__members__","__class__","__bases__","__name__","__mro__","__subclasses__","__init__","__import__"],quickKey:[{label:"print",content:["print($0)"].join(`
|
|
|
`)}]},Me={keywords:["asInstanceOf","catch","class","classOf","def","do","else","extends","finally","for","foreach","forSome","if","import","isInstanceOf","macro","match","new","object","package","return","throw","trait","try","type","until","val","var","while","with","yield","given","enum","then"],quickKey:[{label:"println",content:["println($0)"].join(`
|
|
|
`)}]};var Re=ie(53184),Oe=ie.n(Re),fe=(ze,zt,ut)=>new Promise((ae,te)=>{var ee=ne=>{try{se(ut.next(ne))}catch(he){te(he)}},oe=ne=>{try{se(ut.throw(ne))}catch(he){te(he)}},se=ne=>ne.done?ae(ne.value):Promise.resolve(ne.value).then(ee,oe);se((ut=ut.apply(ze,zt)).next())});const We={languages:["c","abap","apex","azcli","bat","cameligo","clojure","coffee","cpp","csharp","csp","css","dockerfile","fsharp","go","graphql","handlebars","html","ini","java","javascript","json","kotlin","less","lua","markdown","mips","msdax","mysql","objective-c","pascal","pascaligo","perl","pgsql","php","postiats","powerquery","powershell","pug","python","r","razor","redis","redshift","restructuredtext","ruby","rust","sb","scheme","scss","shell","solidity","sophia","sql","st","swift","tcl","twig","vb","xml","yaml'"],tables:{users:["name","id","email","phone","password"],roles:["id","name","order","created_at","updated_at","deleted_at"]}},Se=(ze,zt,ut,ae)=>{const te=zt.getValueInRange({startLineNumber:1,startColumn:1,endLineNumber:ut.lineNumber,endColumn:ut.column});return Array.from(new Set(te.match(/\b\w{2,}\b/g)||[])).map(oe=>({label:oe,kind:ze.languages.CompletionItemKind.Text,insertText:oe,range:ae}))},yt=(ze,zt,ut,ae)=>{ze.languages.registerCompletionItemProvider(zt,{provideCompletionItems(te,ee){const oe=te.getWordUntilPosition(ee),se={startLineNumber:ee.lineNumber,endLineNumber:ee.lineNumber,startColumn:oe.startColumn,endColumn:oe.endColumn},ne=te.getLineContent(ee.lineNumber).substring(oe.startColumn-2,oe.endColumn);return{suggestions:[...Se(ze,te,ee,se),...ut.map(xe=>({label:xe,kind:ze.languages.CompletionItemKind.Keyword,documentation:xe,insertText:xe,insertTextRules:ze.languages.CompletionItemInsertTextRule.InsertAsSnippet,range:se})),...ae.map(xe=>({label:xe.label,kind:ze.languages.CompletionItemKind.Snippet,documentation:xe.content,insertText:ne.startsWith("#")?xe.content.replace(/#/,""):xe.content,insertTextRules:ze.languages.CompletionItemInsertTextRule.InsertAsSnippet,range:se}))]}}})};var Xe=ze=>{We.languages.forEach(zt=>{ze.languages.registerDocumentFormattingEditProvider(zt,{provideDocumentFormattingEdits(ut){return fe(this,null,function*(){const ae=Oe()(ut.getValue(),{indent_size:2,indent_char:" ",max_preserve_newlines:2,preserve_newlines:!0,keep_array_indentation:!0,break_chained_methods:!1,indent_scripts:"normal",brace_style:"collapse",space_before_conditional:!0,unescape_strings:!1,jslint_happy:!1,end_with_newline:!0,wrap_line_length:0,indent_inner_html:!1,comma_first:!1,e4x:!1,indent_empty_lines:!1});return[{range:ut.getFullModelRange(),text:ae}]})}})}),yt(ze,"java",Ae.keywords,Ae.quickKey),yt(ze,"cpp",ye.keywords,ye.quickKey),yt(ze,"c",ve.keywords,[]),yt(ze,"python",be.keywords,be.quickKey),yt(ze,"scala",Me.keywords,Me.quickKey)};const Le="\u8BE5\u4EFB\u52A1\u5173\u5361\u8BBE\u7F6E\u4E86\u7981\u6B62\u590D\u5236\u7C98\u8D34\uFF0C\u8BF7\u624B\u52A8\u8F93\u5165\u4EE3\u7801\u3002";var Ge=Object.defineProperty,Ne=(ze,zt,ut)=>zt in ze?Ge(ze,zt,{enumerable:!0,configurable:!0,writable:!0,value:ut}):ze[zt]=ut,dt=(ze,zt,ut)=>Ne(ze,typeof zt!="symbol"?zt+"":zt,ut);const It=class zs{constructor(zt,ut,ae){this.placeholder=zt,this.editor=ut,this.monaco=ae,ut.onDidChangeModelContent(()=>this.onDidChangeModelContent()),this.onDidChangeModelContent()}onDidChangeModelContent(){this.editor.getValue()===""?this.editor.addContentWidget(this):this.editor.removeContentWidget(this)}getId(){return zs.ID}getDomNode(){return this.domNode||(this.domNode=document.createElement("div"),this.domNode.style.width="max-content",this.domNode.textContent=this.placeholder,this.domNode.style.fontStyle="initial",this.domNode.style.color="#D7D7D7",this.domNode.style.pointerEvents="none",this.editor.applyFontInfo(this.domNode)),this.domNode}getPosition(){return{position:{lineNumber:1,column:1},preference:[this.monaco.editor.ContentWidgetPositionPreference.EXACT]}}dispose(){this.editor.removeContentWidget(this)}};dt(It,"ID","editor.widget.placeholderHint");var mt=It,st=ie(96236),it=ie(6767),je=ie(25399),Ot=ie(89392),nt=ie(77254),tt=ie(56102),ht=Object.defineProperty,$e=Object.defineProperties,at=Object.getOwnPropertyDescriptors,lt=Object.getOwnPropertySymbols,me=Object.prototype.hasOwnProperty,At=Object.prototype.propertyIsEnumerable,De=(ze,zt,ut)=>zt in ze?ht(ze,zt,{enumerable:!0,configurable:!0,writable:!0,value:ut}):ze[zt]=ut,He=(ze,zt)=>{for(var ut in zt||(zt={}))me.call(zt,ut)&&De(ze,ut,zt[ut]);if(lt)for(var ut of lt(zt))At.call(zt,ut)&&De(ze,ut,zt[ut]);return ze},Pt=(ze,zt)=>$e(ze,at(zt)),ge=(ze,zt)=>{var ut={};for(var ae in ze)me.call(ze,ae)&&zt.indexOf(ae)<0&&(ut[ae]=ze[ae]);if(ze!=null&<)for(var ae of lt(ze))zt.indexOf(ae)<0&&At.call(ze,ae)&&(ut[ae]=ze[ae]);return ut},ce=(ze,zt,ut)=>new Promise((ae,te)=>{var ee=ne=>{try{se(ut.next(ne))}catch(he){te(he)}},oe=ne=>{try{se(ut.throw(ne))}catch(he){te(he)}},se=ne=>ne.done?ae(ne.value):Promise.resolve(ne.value).then(ee,oe);se((ut=ut.apply(ze,zt)).next())});function Je(ze){return/^\d+$/.test(ze)?`${ze}px`:ze}function jt(){}let wt=!1;const Ie={"Python3.6":"python","Python2.7":"python",Dynamips:"cpp",Java:"java",Web:"php",Html:"html",Hive:"sql",Hadoop:"java",SDL:"cpp",PHP:"php",Matlab:"python",Git:"python",Python:"python","C/C++":"cpp","C++":"cpp",C:"cpp",Ruby:"ruby",Shell:"shell",JavaScript:"javascript",Perl6:"perl",Kotlin:"kotlin",Elixir:"elixir",Android:"java",JavaWeb:"java",Go:"go",Spark:"sql",MachineLearning:"python",Verilog:"xml","Verilog/VNC":"xml",Docker:"dockerfile","C#":"csharp",SQLite3:"sql",Oracle:"sql",Vhdl:"vhdl",R:"r",Swift:"swift",SQLServer:"mysql",MySQL:"mysql",Mongo:"sql",PostgreSql:"pgsql",Hbase:"powershell",Sqoop:"sql",Nasm:"cpp",Kafka:"java",Flink:"java",Sml:"javascript",OpenGL:"cpp",Perl5:"perl",Orange:"python",Scala:"scale",solidity:"sol"};function Ue(ze=[]){let zt=ze;if(Array.isArray(ze)){for(let ut=0;ut<ze.length;ut++){let ae=Ie[ze[ut]];if(ae)return ae}return zt[0]}return Ie[zt]||zt}let et=null;const cn=()=>ce(void 0,null,function*(){try{yield navigator.clipboard.writeText(" "),console.log("\u5185\u5BB9\u5DF2\u81EA\u52A8\u590D\u5236\u5230\u526A\u8D34\u677F:")}catch(ze){console.error("\u81EA\u52A8\u590D\u5236\u5931\u8D25:",ze)}});var kt=ze=>{var zt=ze,{width:ut="100%",height:ae="100%",value:te,language:ee="javascript",style:oe={},options:se={},overrideServices:ne={},theme:he="vs-dark",onEditBlur:xe,isCopy:ot=!1,onSave:Ee,autoHeight:Fe=!1,forbidCopy:qe=!1,forbidCopyTips:bt,onChange:ct=jt,editorDidMount:Kt=jt,onFocus:Wt=jt,onBreakPoint:Nt=jt,breakPointValue:rn=[],filename:qt="educoder.txt",errorLine:on,errorContent:ft="",highlightLine:Gt,openBreakPoint:Tt=!1,placeholder:en="",showMiniMap:yn=!0}=zt,Rn=ge(zt,["width","height","value","language","style","options","overrideServices","theme","onEditBlur","isCopy","onSave","autoHeight","forbidCopy","forbidCopyTips","onChange","editorDidMount","onFocus","onBreakPoint","breakPointValue","filename","errorLine","errorContent","highlightLine","openBreakPoint","placeholder","showMiniMap"]);const On=(0,z.useRef)(),Pe=(0,z.useRef)({}),rt=(0,z.useRef)(),St=(0,z.useRef)(),_t=(0,z.useRef)([]),bn=(0,z.useRef)(!1),In=(0,z.useRef)(),rr=(0,z.useRef)(),Xn=(0,z.useRef)(!1),[Cn,Fn]=(0,z.useState)(!1);function xt(){let Dt;return On.current&&(Dt=new Ke.Z(Qt=>{for(let Un of Qt)(Un.target.offsetHeight>0||Un.target.offsetWidth>0)&&Pe.current.instance.layout()}),Dt.observe(On.current)),Dt}function $t(){it.ZP.warning({content:decodeURIComponent(bt||Le),key:"monaco-editor-tip"})}const vt=()=>{let Dt=Pe.current.instance;if(te!=null&&Dt&&Cn){const Qt=Dt.getModel();Qt&&te!==Qt.getValue()&&(wt=!0,Qt.setValue(te),Dt.layout(),wt=!1)}};(0,z.useEffect)(()=>{const Dt=nt.Z.subscribe("formatDocument",Qt=>{var Un;let fr=Pe.current.instance;(Un=fr==null?void 0:fr.getAction)==null||Un.call(fr,"editor.action.formatDocument").run()});return window.updateMonacoValue=Qt=>{ct(Qt)},Dt},[]),(0,z.useEffect)(()=>{var Dt;let Qt=Pe.current.instance;St.current&&clearTimeout(St.current),St.current=setTimeout(()=>{vt()},500),te&&(te!=null&&te.length)&&((Dt=Qt==null?void 0:Qt.updateOptions)==null||Dt.call(Qt,{lineNumbersMinChars:Math.max(Math.floor(Math.log10(te.split(/\r\n|\r|\n/g).length))+3,5)}))},[te,Cn,Pe.current]),(0,z.useEffect)(()=>{if(on&&Pe.current&&Pe.current.instance){let Qt=Pe.current.instance;Qt.changeViewZones(function(Un){var fr=document.createElement("div");fr.style.padding="10px 20px",fr.style.width="calc(100% - 20px)",fr.className="my-error-line-wrp",fr.innerHTML=ft,Un.addZone({afterLineNumber:on||11,heightInLines:3,domNode:fr})});var Dt={domNode:null,getId:function(){return"my.overlay.widget"},getDomNode:function(){return this.domNode||(this.domNode=document.createElement("div"),this.domNode.innerHTML="",this.domNode.style.width="100%",this.domNode.style.padding="20px 100px",this.domNode.style.right="0px",this.domNode.style.top="50px",this.domNode.style.position="relative",this.domNode.style.color="#333"),this.domNode},getPosition:function(){return null}};Qt.addOverlayWidget(Dt),Qt.revealPositionInCenter({lineNumber:20,column:1})}},[on,Pe.current,Cn]);const Vt=(Dt="",Qt)=>{if(!Dt||Dt.trim()==="")return!0;const fr=Pe.current.instance.getModel().getLineTokens(Qt);let ke=!1;for(let _e=0;_e<2;_e++)fr.getStandardTokenType(_e)===1&&(ke=!0);return ke};(0,z.useEffect)(()=>{var Dt;const Qt=(Dt=Pe.current)==null?void 0:Dt.instance;if(Qt&&Cn&&qe){const Un=Qt.onDidBlurEditorWidget(()=>{Xn.current=!1}),fr=Qt.onDidFocusEditorText(()=>{Xn.current=!0});return()=>{Un.dispose(),fr.dispose()}}},[Pe.current,Cn,qe]),(0,z.useEffect)(()=>{var Dt;if((Dt=Pe.current)!=null&&Dt.instance&&Cn&&Tt){let Qt=Pe.current.instance,Un=Qt.getModel();if(!Un)return;(()=>{var Ht;let Ct=[],pt=[];const un=Un.getAllDecorations();for(let Dn of un)Dn.options.className==="highlighted-line"&&(Ct.push((Ht=Dn==null?void 0:Dn.range)==null?void 0:Ht.startLineNumber),pt.push(Dn==null?void 0:Dn.id));if(Gt===Ct[0])return;Un.deltaDecorations(pt,[]);const $n=Un.getLineCount();Gt&&Gt<=$n&&(Qt.deltaDecorations([],[{range:new et.Range(Gt,1,Gt,Un.getLineMaxColumn(Gt)),options:{isWholeLine:!0,className:"highlighted-line"}}]),Qt.revealLineInCenter(Gt))})();const ke=(Ht=!1)=>{var Ct;let pt=[],un=[];const $n=Un.getAllDecorations();for(let Dn of $n)Dn.options.linesDecorationsClassName==="breakpoints-select"&&(pt.push((Ct=Dn==null?void 0:Dn.range)==null?void 0:Ct.startLineNumber),un.push(Dn==null?void 0:Dn.id));if(Ht)return{lines:pt,ids:un};Nt(pt)},_e=Ht=>ce(void 0,null,function*(){let Ct={range:new et.Range(Ht,1,Ht,1),options:{isWholeLine:!1,linesDecorationsClassName:"breakpoints-select"}};yield Un.deltaDecorations([],[Ct]),ke()}),Ce=Ht=>ce(void 0,null,function*(){let Ct=[];const pt=Qt.getLineDecorations(Ht);for(let un of pt)un.options.linesDecorationsClassName==="breakpoints-select"&&Ct.push(un.id);yield Un.deltaDecorations(Ct,[]),ke()}),Be=Ht=>{let Ct=Qt.getLineDecorations(Ht);for(let pt of Ct)if(pt.options.linesDecorationsClassName==="breakpoints-select")return!0;return!1};if(!(0,Ot.isEqual)(rn,ke(!0).lines)){Un.deltaDecorations(ke(!0).ids,[]);const Ht=rn.map(Ct=>({range:new et.Range(Ct,1,Ct,1),options:{isWholeLine:!1,linesDecorationsClassName:"breakpoints-select"}}));Un.deltaDecorations([],Ht)}const we=Qt.onDidChangeModelContent(Ht=>{let Ct=Qt.getPosition();if(Ct){let pt=Ct.lineNumber;clearTimeout(rr.current),rr.current=setTimeout(()=>{Vt(Un.getLineContent(pt),pt)?Ce(pt):Be(pt)?(Ce(pt),_e(pt)):ke()},100)}}),Te=Qt.onMouseDown(Ht=>{var Ct,pt,un;if(Ht.target.detail&&((un=(pt=(Ct=Ht.target)==null?void 0:Ct.element)==null?void 0:pt.className)!=null&&un.includes("line-numbers"))){let $n=Ht.target.position.lineNumber;if(Vt(Un.getLineContent($n),$n))return;Be($n)?Ce($n):_e($n)}}),Qe=Ht=>{let Ct={range:new et.Range(Ht,1,Ht,1),options:{isWholeLine:!1,linesDecorationsClassName:"breakpoints-fake"}};_t.current=Qt.deltaDecorations(_t.current,[Ct])},nn=()=>{_t.current=Qt.deltaDecorations(_t.current,[])},sn=Qt.onMouseMove(Ht=>{var Ct,pt,un;if(nn(),Ht.target.detail&&((un=(pt=(Ct=Ht.target)==null?void 0:Ct.element)==null?void 0:pt.className)!=null&&un.includes("line-numbers"))){let $n=Ht.target.position.lineNumber;if(Vt(Un.getLineContent($n),$n))return;Qe($n)}}),Xt=Qt.onMouseLeave(()=>{nn()});return()=>{we.dispose(),Te.dispose(),sn.dispose(),Xt.dispose()}}},[Pe.current,Cn,rn,Gt,Tt,ee]),(0,z.useEffect)(()=>{var Dt;(Dt=Pe.current)!=null&&Dt.instance&&Tt&&Pe.current.instance.setPosition({lineNumber:0,column:0})},[Gt]);function Ut(){let Dt=Pe.current.instance;if(Dt){const Qt=Dt.getSelection(),Un=Pe.current.pastePos||{},fr=new et.Range(Un.startLineNumber||Qt.endLineNumber,Un.startColumn||Qt.endColumn,Un.endLineNumber||Qt.endLineNumber,Un.endColumn||Qt.endColumn);setTimeout(()=>{Dt.executeEdits("",[{range:fr,text:""}])},300)}}function En(Dt){(window.navigator.platform.match("Mac")?Dt.metaKey:Dt.ctrlKey)&&Dt.keyCode==83&&(Dt.preventDefault(),Ee())}const mn=()=>{if(Fe&&Pe.current.instance){const Dt=Pe.current.instance.getContentHeight();ir(Dt<ae?ae:Dt)}else ir(ae)};function xn(Dt){var Qt=document.createEvent("MouseEvents");Qt.initMouseEvent("click",!0,!1,window,0,0,0,0,0,!1,!1,!1,!1,0,null),Dt.dispatchEvent(Qt)}const wn=Dt=>{if(!Xn.current)return;const{keyCode:Qt,ctrlKey:Un,metaKey:fr,target:ke,type:_e}=Dt;return(_e==="paste"||(Qt===67||Qt===86)&&(fr||Un))&&ke.nodeName==="TEXTAREA"&&($t(),Dt.preventDefault()),!1};function Bn(Dt,Qt){var Un=window.URL||window.webkitURL||window,fr=new Blob([Qt]),ke=document.createElementNS("http://www.w3.org/1999/xhtml","a");ke.href=Un.createObjectURL(fr),ke.download=Dt,xn(ke)}(0,z.useEffect)(()=>{mn()},[mn]),(0,z.useEffect)(()=>{On.current&&!Cn&&Promise.all([ie.e(8909),ie.e(2460)]).then(ie.bind(ie,71448)).then(Dt=>{try{et=Dt,Pe.current.instance=et.editor.create(On.current,{value:te,language:Ue(ee),theme:he,requireConfig:{"vs/nls":{availableLanguages:{"*":"zh-cn"}}},wordWrap:!0,autoIndent:!0,contextmenu:!0,formatOnType:!0,minimap:{enabled:yn||!1}},ne);const Qt=Pe.current.instance;let ke=[...st.BH._menuItems].find(we=>we[0]._debugName=="EditorContext")[1],_e=["editor.action.clipboardCopyWithSyntaxHighlightingAction","editor.action.quickCommand","editor.action.clipboardCopyAction","editor.action.clipboardPasteAction","editor.action.clipboardCutAction"],Ce=(we,Te)=>{var Qe,nn;let sn=we._first;do Te.includes((nn=(Qe=sn.element)==null?void 0:Qe.command)==null?void 0:nn.id)&&we._remove(sn);while(sn=sn.next)};if(Kt(Qt,et),setTimeout(()=>{mn(),Pe.current.instance.addAction({id:"d123123",label:"Download File",contextMenuGroupId:"9_cutcopypaste",run:()=>{Bn(qt||"educoder.txt",Qt.getValue())}})},500),Pe.current.subscription=Qt.onDidChangeModelContent(we=>{bn.current?clearTimeout(In.current):(mn(),ct(Qt.getValue(),we)),In.current=setTimeout(()=>{bn.current=!1},500)}),window.Monaco||Xe(et,Ue(ee)),qe&&(Ce(ke,_e),On.current.classList.add("noCopyPaste"),window.removeEventListener("keydown",wn),window.removeEventListener("paste",wn),window.addEventListener("keydown",wn),window.addEventListener("paste",wn)),window.Monaco=et,xe&&Qt.onDidBlurEditorWidget(()=>{xe(Qt.getValue())}),Wt&&Qt.onDidFocusEditorText(()=>{qe&&cn(),Wt(Qt.getValue())}),qe){cn();try{Qt.onDidPaste(we=>{const Te=Qt.getSelection(),Qe=Pe.current.pastePos||{},nn=new et.Range(Qe.startLineNumber||Te.endLineNumber,Qe.startColumn||Te.endColumn,Qe.endLineNumber||Te.endLineNumber,Qe.endColumn||Te.endColumn);Qt.executeEdits("",[{range:we.range,text:""}])})}catch(we){}}let Be=xt();return en&&typeof en=="string"&&new mt(en,Qt,et),Fn(!0),()=>{const we=Pe.current.instance;we.dispose();const Te=we.getModel();Te&&Te.dispose(),Pe.current.subscription&&Pe.current.subscription.dispose(),Be.unobserve(On.current)}}catch(Qt){}})},[]),(0,z.useEffect)(()=>{if(Pe.current.instance&&Cn)return document.addEventListener("keydown",En,!1),()=>{document.removeEventListener("keydown",En)}},[Ee,Cn]),(0,z.useEffect)(()=>{let Dt=Pe.current.instance;if(Dt&&Cn){let Qt=Ue(ee);et.editor.setModelLanguage(Dt.getModel(),Qt)}},[ee,Cn]),(0,z.useEffect)(()=>{Pe.current.instance&&Cn&&et.editor.setTheme(he)},[he,Cn]),(0,z.useEffect)(()=>{let Dt=Pe.current.instance;rt.current=se,Dt&&Cn&&(Dt.updateOptions(He({},se)),setTimeout(()=>{Dt.getModel().updateOptions(He({},se))},200))},[JSON.stringify(se),Cn]),(0,z.useEffect)(()=>{let Dt=Pe.current.instance;Dt&&Cn&&Dt.layout()},[ut,ae,Cn]);const[Zn,Yn]=(0,z.useState)(Je(ut)),[Wn,ir]=(0,z.useState)(Je(ae)),gn=Pt(He({},oe),{width:Zn,height:Wn,position:"relative"});return z.createElement("div",{className:"my-monaco-editor",ref:On,style:gn,onFocus:()=>{qe&&cn()}},ot&&z.createElement(tt.CopyToClipboard,{text:te,onCopy:()=>it.ZP.success("\u590D\u5236\u6210\u529F")},z.createElement(je.Z,{title:"\u590D\u5236\u4EE3\u7801"},z.createElement("div",{style:{position:"absolute",top:0,right:10,cursor:"pointer",zIndex:10,color:"#165DFF"}},z.createElement("i",{className:"iconfont icon-fuzhi8",style:{fontSize:14}})," \u590D\u5236\u4EE3\u7801"))))};function Yt({width:ze="100%",height:zt="100%",original:ut,modified:ae,language:te,options:ee={}}){const oe=(0,z.useRef)(),[se,ne]=(0,z.useState)(null);function he(Fe){let qe;return oe.current&&(qe=new Ke.Z(bt=>{for(let ct of bt)(ct.target.offsetHeight>0||ct.target.offsetWidth>0)&&Fe.layout()}),qe.observe(oe.current)),qe}(0,z.useEffect)(()=>(oe.current&&Promise.all([ie.e(8909),ie.e(9404)]).then(ie.bind(ie,2550)).then(Fe=>{et=Fe;const qe=et.editor.createDiffEditor(oe.current,Pt(He({enableSplitViewResizing:!1,scrollBeyondLastLine:!1,roundedSelection:!1,renderIndicators:!1,useShadows:!1,horizontal:"hidden",lineNumbers:"off",wordWrap:"off",ignoreTrimWhitespace:!1,"semanticHighlighting.enabled":!0,followsCaret:!0,ignoreCharChanges:!0,minimap:{enabled:!1},readOnly:!0},ee),{wordWrap:!0}));ne(qe);let bt=he(qe);return()=>{qe.dispose();const ct=qe.getModel();ct&&ct.dispose(),bt.unobserve(oe.current)}}),()=>{window.removeEventListener("keydown",checkPaste),window.removeEventListener("paste",checkPaste)}),[]),(0,z.useEffect)(()=>{se&&se.setModel({original:et.editor.createModel(ut,te),modified:et.editor.createModel(ae,te)})},[ut,ae,te,se]);const xe=Je(ze),ot=Je(zt),Ee={width:xe,height:ot};return z.createElement("div",{className:"my-diff-editor",ref:oe,style:Ee})}},31103:function(ln,Ft,ie){"use strict";ie.d(Ft,{Z:function(){return Ke}});var z=ie(59301);function Ke(ve,Ae){const ye=(0,z.useRef)();(0,z.useEffect)(()=>{ye.current=ve}),(0,z.useEffect)(()=>{function be(){ye.current()}if(Ae!==null){let Me=setInterval(be,Ae);return()=>clearInterval(Me)}},[Ae])}},7018:function(ln,Ft,ie){"use strict";ie.r(Ft),ie.d(Ft,{default:function(){return Fn}});var z=ie(59301),Ke=ie(65582),ve=ie(74128),Ae=ie(77019),ye=ie(5269),be=ie(7939),Me={wrap:"wrap___oiJRJ",head:"head___zCLJu",recommendItem:"recommendItem___Z46_0",buttonWrap:"buttonWrap___Gol4S",privateMessage:"privateMessage___UCiuy",flex1:"flex1___FVk7y",mWidth147:"mWidth147___f_pcl"},Re=ie(16209),Oe=Object.defineProperty,fe=Object.defineProperties,We=Object.getOwnPropertyDescriptors,Se=Object.getOwnPropertySymbols,yt=Object.prototype.hasOwnProperty,Xe=Object.prototype.propertyIsEnumerable,Le=(xt,$t,vt)=>$t in xt?Oe(xt,$t,{enumerable:!0,configurable:!0,writable:!0,value:vt}):xt[$t]=vt,Ge=(xt,$t)=>{for(var vt in $t||($t={}))yt.call($t,vt)&&Le(xt,vt,$t[vt]);if(Se)for(var vt of Se($t))Xe.call($t,vt)&&Le(xt,vt,$t[vt]);return xt},Ne=(xt,$t)=>fe(xt,We($t)),dt=(xt,$t)=>{var vt={};for(var Vt in xt)yt.call(xt,Vt)&&$t.indexOf(Vt)<0&&(vt[Vt]=xt[Vt]);if(xt!=null&&Se)for(var Vt of Se(xt))$t.indexOf(Vt)<0&&Xe.call(xt,Vt)&&(vt[Vt]=xt[Vt]);return vt},It=(xt,$t,vt)=>new Promise((Vt,Ut)=>{var En=wn=>{try{xn(vt.next(wn))}catch(Bn){Ut(Bn)}},mn=wn=>{try{xn(vt.throw(wn))}catch(Bn){Ut(Bn)}},xn=wn=>wn.done?Vt(wn.value):Promise.resolve(wn.value).then(En,mn);xn((vt=vt.apply(xt,$t)).next())});const Bt=xt=>{var $t=xt,{user:vt,forumsDetail:Vt,globalSetting:Ut,loading:En,dispatch:mn}=$t,xn=dt($t,["user","forumsDetail","globalSetting","loading","dispatch"]),wn,Bn,Zn,Yn;const{author_info:Wn,memo:ir,recommend_shixuns:gn}=Vt.forumsDetailData||{},Dt=()=>It(void 0,null,function*(){(Wn!=null&&Wn.watched?yield(0,Re.Sr)({user_id:Wn.login}):yield(0,Re.YP)({user_id:Wn.login}))&&mn({type:"forumsDetail/setForumsDetailData",payload:Ne(Ge({},Vt.forumsDetailData),{author_info:Ne(Ge({},Wn),{watched:!(Wn!=null&&Wn.watched)})})})});return z.createElement("section",{className:Me.wrap},z.createElement("aside",{className:"ml20"},z.createElement("div",{className:`bg-white pt40 pb40 pl20 pr20 ${Me.head}`},z.createElement("a",{href:`/users/${Wn==null?void 0:Wn.login}`,target:"_blank"},(Wn==null?void 0:Wn.image_url)&&z.createElement("img",{src:`${ve.Z.API_SERVER}/images/${Wn==null?void 0:Wn.image_url}`})),z.createElement("div",{className:"tc font20"},Wn==null?void 0:Wn.username),z.createElement("div",{className:"tc c-grey-999"},Wn==null?void 0:Wn.identity),((wn=vt.userInfo)==null?void 0:wn.user_id)!==(Wn==null?void 0:Wn.user_id)&&z.createElement(Ae.Z,{justify:"center",className:`mt30 ${Me.buttonWrap}`},z.createElement(ye.Z,null,z.createElement(be.ZP,{type:"primary",className:"mr10",onClick:Dt},Wn!=null&&Wn.watched?"\u53D6\u6D88\u5173\u6CE8":"\u5173\u6CE8")),z.createElement(ye.Z,null,z.createElement(be.ZP,{className:Me.privateMessage,href:`/messages/${(Bn=vt.userInfo)==null?void 0:Bn.login}/message_detail?target_ids=${Wn==null?void 0:Wn.user_id}`,target:"_blank"},"\u79C1\u4FE1")))),!!((Zn=ir==null?void 0:ir.tag)!=null&&Zn.length)&&z.createElement("div",{className:"bg-white mt10 pt40 pb40 pl20 pr20"},z.createElement("div",{className:"font16"},"\u8BDD\u9898\u6807\u7B7E"),z.createElement("div",{className:`mt10 ${Me.tag}`},(Yn=ir==null?void 0:ir.tag)==null?void 0:Yn.map((Qt,Un)=>z.createElement("span",{key:Un,className:"c-light-primary mr10"},Qt)))),z.createElement("div",{className:"pt10 pb10 pl10 pr10"},z.createElement("div",{className:"font16 mb20"},"\u63A8\u8350\u5B9E\u8BAD"),z.createElement("div",{className:Me.recommend},gn==null?void 0:gn.map(Qt=>z.createElement("div",{className:Me.recommendItem},z.createElement("a",{href:`/shixuns/${Qt.identifier}/challenges`,target:"_blank"},z.createElement("img",{alt:Qt.id,src:`${Qt.image_url}`})),z.createElement("div",{className:`${Me.flex1} ml10`},z.createElement("a",{href:`/shixuns/${Qt.identifier}/challenges`,target:"_blank",title:Qt.name,className:`${Me.mWidth147} multi-llipsis1e c-grey-666 mb10`},Qt.name),z.createElement("div",{className:"c-grey-999"},Qt.myshixuns_count," \u4EBA\u5B66\u4E60"))))))))};var mt=(0,Ke.connect)(({user:xt,forumsDetail:$t,loading:vt,globalSetting:Vt})=>({user:xt,forumsDetail:$t,globalSetting:Vt,loading:vt.models.forumsDetail}))(Bt),st=ie(66649),it=ie.n(st),je=ie(95097),Ot=ie(6767),nt=ie(62957),tt=ie(37568),ht=ie(93041),$e=ie(91882),at=ie(25399),lt=ie(75727),me=ie(25374),At=ie(26227),De={flex_box_center:"flex_box_center___nMc3G",flex_space_between:"flex_space_between___gTlaF",flex_box_vertical_center:"flex_box_vertical_center___GQv6O",flex_box_center_end:"flex_box_center_end___nrFEP",flex_box_column:"flex_box_column___Ls1oQ",reply:"reply___jb23w",replyList:"replyList___ryiUt",comment:"comment___QJ1eT",content:"content___X2UnY",commentItem:"commentItem___h_wnY"},He=Object.defineProperty,Pt=Object.defineProperties,ge=Object.getOwnPropertyDescriptors,ce=Object.getOwnPropertySymbols,Je=Object.prototype.hasOwnProperty,jt=Object.prototype.propertyIsEnumerable,wt=(xt,$t,vt)=>$t in xt?He(xt,$t,{enumerable:!0,configurable:!0,writable:!0,value:vt}):xt[$t]=vt,Ie=(xt,$t)=>{for(var vt in $t||($t={}))Je.call($t,vt)&&wt(xt,vt,$t[vt]);if(ce)for(var vt of ce($t))jt.call($t,vt)&&wt(xt,vt,$t[vt]);return xt},Ue=(xt,$t)=>Pt(xt,ge($t)),et=(xt,$t,vt)=>new Promise((Vt,Ut)=>{var En=wn=>{try{xn(vt.next(wn))}catch(Bn){Ut(Bn)}},mn=wn=>{try{xn(vt.throw(wn))}catch(Bn){Ut(Bn)}},xn=wn=>wn.done?Vt(wn.value):Promise.resolve(wn.value).then(En,mn);xn((vt=vt.apply(xt,$t)).next())});it().locale("ZH-cn");function cn({user:xt,vlist:$t=[],dispatch:vt,params:Vt,id:Ut,memo_replies:En,forumsDetail:mn}){return z.createElement("aside",{className:De.comment},$t.map(function(xn,wn){var Bn,Zn;return z.createElement(Ae.Z,{key:wn,className:De.commentItem},z.createElement(ye.Z,{span:24},z.createElement(Ae.Z,null,z.createElement(ye.Z,{flex:"1"},z.createElement("a",{href:`/users/${xn.user_login}`,target:"_blank",className:"c-light-black"},xn==null?void 0:xn.username),z.createElement("span",{className:"c-light-black ml10"},xn.time)),(xn.can_delete||xn.user_id===((Bn=xt.userInfo)==null?void 0:Bn.user_id)||xn.user_login===((Zn=xt.userInfo)==null?void 0:Zn.login))&&z.createElement(ye.Z,{className:"forums-comment-delete",style:{display:"none"}},z.createElement(at.Z,{title:"\u5220\u9664"},z.createElement(At.Z,{className:"current",onClick:()=>{nt.default.confirm({centered:!0,width:530,okText:"\u786E\u5B9A",cancelText:"\u53D6\u6D88",title:"\u63D0\u793A",content:z.createElement("div",{className:"font16 tc"},"\u786E\u5B9A\u8981\u5220\u9664\u8BE5\u6761\u56DE\u590D\u5417\uFF1F"),onOk:()=>et(this,null,function*(){const Yn=yield(0,Re.sW)({id:xn.id}),Wn=En.find(ir=>ir.id===Ut).children.filter(ir=>ir.id!==xn.id);En.find(ir=>ir.id===Ut).children=Wn,vt({type:"forumsDetail/setForumsDetailData",payload:Ue(Ie({},mn.forumsDetailData),{memo_replies:[...En]})})})})}}))))),z.createElement(ye.Z,null,z.createElement(je.Z,{value:xn.content})))}))}var kt=cn,Yt=ie(65862),ze=Object.defineProperty,zt=Object.defineProperties,ut=Object.getOwnPropertyDescriptors,ae=Object.getOwnPropertySymbols,te=Object.prototype.hasOwnProperty,ee=Object.prototype.propertyIsEnumerable,oe=(xt,$t,vt)=>$t in xt?ze(xt,$t,{enumerable:!0,configurable:!0,writable:!0,value:vt}):xt[$t]=vt,se=(xt,$t)=>{for(var vt in $t||($t={}))te.call($t,vt)&&oe(xt,vt,$t[vt]);if(ae)for(var vt of ae($t))ee.call($t,vt)&&oe(xt,vt,$t[vt]);return xt},ne=(xt,$t)=>zt(xt,ut($t)),he=(xt,$t)=>{var vt={};for(var Vt in xt)te.call(xt,Vt)&&$t.indexOf(Vt)<0&&(vt[Vt]=xt[Vt]);if(xt!=null&&ae)for(var Vt of ae(xt))$t.indexOf(Vt)<0&&ee.call(xt,Vt)&&(vt[Vt]=xt[Vt]);return vt},xe=(xt,$t,vt)=>new Promise((Vt,Ut)=>{var En=wn=>{try{xn(vt.next(wn))}catch(Bn){Ut(Bn)}},mn=wn=>{try{xn(vt.throw(wn))}catch(Bn){Ut(Bn)}},xn=wn=>wn.done?Vt(wn.value):Promise.resolve(wn.value).then(En,mn);xn((vt=vt.apply(xt,$t)).next())});it().locale("ZH-cn");const ot=(xt,$t)=>{var vt=xt,{user:Vt,forumsDetail:Ut,globalSetting:En,loading:mn,dispatch:xn,handleClick:wn}=vt,Bn=he(vt,["user","forumsDetail","globalSetting","loading","dispatch","handleClick"]);const{memo:Zn,memo_replies:Yn}=Ut.forumsDetailData||{},Wn=(0,Ke.useParams)(),[ir,gn]=(0,z.useState)(""),[Dt,Qt]=(0,z.useState)(""),[Un,fr]=(0,z.useState)(-1),[ke,_e]=(0,z.useState)(!1),[Ce,Be]=(0,z.useState)(1),[we,Te]=(0,z.useState)(!1);(0,z.useImperativeHandle)($t,()=>({onMdFouch:sn})),(0,z.useEffect)(()=>{_e((Zn==null?void 0:Zn.replies_count)>10)},[Zn==null?void 0:Zn.replies_count]);const Qe=()=>xe(void 0,null,function*(){var Xt;const Ht=Ce+1;Be(Ht);const Ct=yield(0,Re.z5)({id:Wn.memoId,page:Ht});Ct!=null&&Ct.memo_replies&&(xn({type:"forumsDetail/setForumsDetailData",payload:ne(se({},Ut.forumsDetailData),{memo_replies:[...Yn,...Ct.memo_replies]})}),_e(((Xt=Ct.memo_replies)==null?void 0:Xt.length)===10))}),nn=Xt=>{var Ht,Ct,pt,un;return ne(se({},Xt),{image_url:(Ht=Vt.userInfo)==null?void 0:Ht.image_url,children:[],user_id:(Ct=Vt.userInfo)==null?void 0:Ct.user_id,user_login:(pt=Vt.userInfo)==null?void 0:pt.login,username:(un=Vt.userInfo)==null?void 0:un.username,time:`${(0,Yt.li)((new Date().getTime()-new Date(Xt.created_at).getTime())/1e3)}\u524D`})},sn=()=>{Te(!0)};return z.createElement("section",{className:De.wrap},!!(Yn!=null&&Yn.length)&&z.createElement("aside",{className:De.content},z.createElement("div",{style:{padding:"10px 15px 5px 15px",justifyContent:"space-between",display:"flex"}},z.createElement("span",null,"\u5168\u90E8\u56DE\u590D\uFF08",Zn.replies_count,"\uFF09")),z.createElement("aside",{className:De.replyList},Yn==null?void 0:Yn.map(function(Xt,Ht){var Ct;return z.createElement(Ae.Z,{gutter:[12,12],key:Ht},z.createElement(ye.Z,{flex:"40px"},z.createElement("a",{href:`/users/${Xt.user_login}`,target:"_blank"},z.createElement("img",{alt:"\u7528\u6237\u5934\u50CF",width:"50",height:"50",src:`${ve.Z.IMG_SERVER}/images/${Xt==null?void 0:Xt.image_url}`}))),z.createElement(ye.Z,{flex:"1"},z.createElement(Ae.Z,{align:"middle"},z.createElement(ye.Z,{span:24},z.createElement("a",{href:`/users/${Xt.user_login}`,target:"_blank"},z.createElement("span",{className:"c-light-black"},Xt==null?void 0:Xt.username)),z.createElement("span",{className:"c-light-black ml10"},Xt.time)),z.createElement(ye.Z,{span:24},z.createElement("div",{onClick:wn},z.createElement(je.Z,{value:Xt.content}))),!!((Ct=Xt==null?void 0:Xt.children)!=null&&Ct.length)&&z.createElement(kt,{user:Vt,id:Xt==null?void 0:Xt.id,vlist:Xt==null?void 0:Xt.children,dispatch:xn,params:Wn,memo_replies:Yn,forumsDetail:Ut}),z.createElement(ye.Z,{span:24,className:"mt5 c-light-black"},Un===Ht?z.createElement("aside",null,z.createElement(me.Z,{onChange:pt=>{Qt(pt)},height:150,isFocus:!0,placeholder:"\u6211\u8981\u56DE\u590D..."}),z.createElement(Ae.Z,null,z.createElement(ye.Z,{span:24,className:"tr"},z.createElement(be.ZP,{type:"primary",size:"middle",onClick:()=>xe(this,null,function*(){if(Dt==="")Ot.ZP.error("\u8BF7\u8F93\u5165\u5185\u5BB9");else{const pt=yield(0,Re.ts)({parent_id:Xt.id,content:Dt});Qt(null),pt&&(fr(-1),Yn.find(un=>un.id===pt.parent_id).children.push(nn(pt)),xn({type:"forumsDetail/setForumsDetailData",payload:ne(se({},Ut.forumsDetailData),{memo:ne(se({},Zn),{replies_count:Zn.replies_count+1}),memo_replies:[...Yn]})}))}})},"\u53D1\u9001")))):z.createElement("div",{className:"tr"},z.createElement("span",{className:"iconfont icon-huifu1 mr15 ml30 current",onClick:()=>fr(Ht)}),z.createElement(at.Z,{title:Xt.user_praise?"\u53D6\u6D88\u70B9\u8D5E":"\u70B9\u8D5E"},z.createElement("span",{className:Xt.user_praise?"c-orange":"c-gery-888"},z.createElement("i",{className:"iconfont icon-dianzan mr3 current",onClick:()=>xe(this,null,function*(){const pt=yield(0,Re.vL)({id:Xt.id,container_type:"Memo",type:Xt.user_praise?0:1});(pt==null?void 0:pt.praise_count)>=0&&(Yn.find(un=>un.id===Xt.id).user_praise=!Xt.user_praise,Yn.find(un=>un.id===Xt.id).praise_count=pt==null?void 0:pt.praise_count,xn({type:"forumsDetail/setForumsDetailData",payload:ne(se({},Ut.forumsDetailData),{memo_replies:[...Yn]})}))})}),Xt.praise_count>0?Xt.praise_count:"")))))))}))),ke&&z.createElement("aside",{className:"bg-white pb20",style:{display:"flex",justifyContent:"center"}},z.createElement(Ae.Z,{justify:"space-between"},z.createElement(ye.Z,null),z.createElement(ye.Z,null,ke&&z.createElement("a",{className:"c-black",onClick:Qe},"\u67E5\u770B\u66F4\u591A\u8BC4\u8BBA")))),z.createElement("aside",{className:De.reply},z.createElement(me.Z,{onBlur:()=>Te(!1),isFocus:we,defaultValue:ir,id:"writeForumsReviewId",onChange:Xt=>{gn(Xt)},placeholder:"\u6211\u8981\u56DE\u590D...",height:240}),z.createElement(Ae.Z,null,z.createElement(ye.Z,{flex:"1"}),z.createElement(ye.Z,null,z.createElement(be.ZP,{type:"primary",size:"middle",onClick:()=>xe(void 0,null,function*(){if(ir==="")Ot.ZP.error("\u8BF7\u8F93\u5165\u5185\u5BB9");else{const Xt=yield(0,Re.ts)({parent_id:Zn.id,content:ir});gn(null),Xt&&xn({type:"forumsDetail/setForumsDetailData",payload:ne(se({},Ut.forumsDetailData),{memo:ne(se({},Zn),{replies_count:Zn.replies_count+1}),memo_replies:[nn(Xt),...Yn]})})}})},"\u53D1\u9001")))))};var Ee=(0,Ke.connect)(({user:xt,forumsDetail:$t,loading:vt,globalSetting:Vt})=>({user:xt,forumsDetail:$t,globalSetting:Vt,loading:vt.models.forumsDetail}),null,null,{forwardRef:!0})((0,z.forwardRef)(ot)),Fe={wrap:"wrap___Soi3l",header:"header___vk3EC",title:"title___WJAyR",menu:"menu___yMPKF",top:"top___ZqzEM",line:"line___EQKlG",flexCenter:"flexCenter___Rcnhr",like:"like___uNtmq",canLike:"canLike___Lu04z",attachmentName:"attachmentName___nwdzp"},qe=ie(87169),bt=ie(30214),ct=ie(77254),Kt=Object.defineProperty,Wt=Object.defineProperties,Nt=Object.getOwnPropertyDescriptors,rn=Object.getOwnPropertySymbols,qt=Object.prototype.hasOwnProperty,on=Object.prototype.propertyIsEnumerable,ft=(xt,$t,vt)=>$t in xt?Kt(xt,$t,{enumerable:!0,configurable:!0,writable:!0,value:vt}):xt[$t]=vt,Gt=(xt,$t)=>{for(var vt in $t||($t={}))qt.call($t,vt)&&ft(xt,vt,$t[vt]);if(rn)for(var vt of rn($t))on.call($t,vt)&&ft(xt,vt,$t[vt]);return xt},Tt=(xt,$t)=>Wt(xt,Nt($t)),en=(xt,$t)=>{var vt={};for(var Vt in xt)qt.call(xt,Vt)&&$t.indexOf(Vt)<0&&(vt[Vt]=xt[Vt]);if(xt!=null&&rn)for(var Vt of rn(xt))$t.indexOf(Vt)<0&&on.call(xt,Vt)&&(vt[Vt]=xt[Vt]);return vt},yn=(xt,$t,vt)=>new Promise((Vt,Ut)=>{var En=wn=>{try{xn(vt.next(wn))}catch(Bn){Ut(Bn)}},mn=wn=>{try{xn(vt.throw(wn))}catch(Bn){Ut(Bn)}},xn=wn=>wn.done?Vt(wn.value):Promise.resolve(wn.value).then(En,mn);xn((vt=vt.apply(xt,$t)).next())});const Rn={5:"\u6280\u672F\u5206\u4EAB",3:"\u64CD\u4F5C\u6307\u5357",16:"\u901A\u77E5\u516C\u544A"},On=xt=>{var $t=xt,{user:vt,forumsDetail:Vt,globalSetting:Ut,loading:En,dispatch:mn}=$t,xn=en($t,["user","forumsDetail","globalSetting","loading","dispatch"]),wn,Bn,Zn,Yn,Wn;const{author_info:ir,memo:gn,attachments_list:Dt}=Vt.forumsDetailData||{},Qt=(0,z.useRef)(),Un=(0,z.useRef)(),fr=()=>yn(void 0,null,function*(){const Qe={id:gn.id,sticky:gn.sticky?0:1},nn=yield(0,Re.B0)(Qe);(nn==null?void 0:nn.status)===0&&mn({type:"forumsDetail/setForumsDetailData",payload:Tt(Gt({},Vt.forumsDetailData),{memo:Tt(Gt({},gn),{sticky:!(gn!=null&&gn.sticky)})})})}),ke=()=>yn(void 0,null,function*(){const Qe=yield(0,Re.sW)({id:gn==null?void 0:gn.id});(Qe==null?void 0:Qe.status)===0&&(Ot.ZP.success("\u5220\u9664\u6210\u529F"),Ke.history.push("/forums")),(Qe==null?void 0:Qe.status)===-1&&Ke.history.push("/forums")}),_e=()=>yn(void 0,null,function*(){nt.default.confirm({centered:!0,width:530,okText:"\u786E\u5B9A",cancelText:"\u53D6\u6D88",title:"\u5956\u52B1\u8BBE\u7F6E",content:z.createElement("div",{className:"font14 tc"},z.createElement(tt.default,{defaultValue:Qt.current,onChange:Qe=>Qt.current=Qe.target.value})),onOk:()=>yn(void 0,null,function*(){const Qe=yield(0,Re.eh)({id:gn==null?void 0:gn.id,container_type:"Memo",score:Qt.current?Number(Qt.current):0,user_id:ir==null?void 0:ir.user_id});if(Qt.current=null,(Qe==null?void 0:Qe.code)>0){mn({type:"forumsDetail/setForumsDetailData",payload:Tt(Gt({},Vt.forumsDetailData),{memo:Tt(Gt({},gn),{reward:Qe==null?void 0:Qe.code})})}),Ot.ZP.success("\u5956\u52B1\u6210\u529F");return}Ot.ZP.success("\u5956\u52B1\u5931\u8D25\uFF0C\u8BF7\u8054\u7CFB\u7CFB\u7EDF\u7BA1\u7406\u5458\uFF01")})})}),Ce=()=>{Un.current.onMdFouch&&Un.current.onMdFouch()},Be=()=>yn(void 0,null,function*(){const Qe=yield(0,Re.vL)({id:gn.id,container_type:"Memo",type:1});(Qe==null?void 0:Qe.praise_count)>=0&&mn({type:"forumsDetail/setForumsDetailData",payload:Tt(Gt({},Vt.forumsDetailData),{memo:Tt(Gt({},gn),{user_praise:!(gn!=null&&gn.user_praise),memo_praise_count:Qe==null?void 0:Qe.praise_count})})})}),we=z.createElement(ht.default,{className:Fe.menu},((wn=vt.userInfo)==null?void 0:wn.admin)&&(gn==null?void 0:gn.sticky)&&z.createElement(ht.default.Item,null,z.createElement("a",{onClick:()=>fr()},"\u53D6\u6D88\u7F6E\u9876")),((Bn=vt.userInfo)==null?void 0:Bn.admin)&&!(gn!=null&&gn.sticky)&&z.createElement(ht.default.Item,null,z.createElement("a",{onClick:()=>fr()},"\u7F6E\xA0\xA0\u9876")),z.createElement(ht.default.Item,null,z.createElement(Ke.Link,{to:`/forums/${gn==null?void 0:gn.id}/edit`},"\u7F16\xA0\xA0\u8F91")),z.createElement(ht.default.Item,null,z.createElement("a",{onClick:()=>{nt.default.confirm({title:"\u63D0\u793A",icon:z.createElement(qe.Z,null),content:"\u5E16\u5B50\u5C06\u88AB\u5220\u9664\uFF0C\u65E0\u6CD5\u6062\u590D\u3002\u662F\u5426\u786E\u8BA4\u5220\u9664\uFF1F",okText:"\u786E\u8BA4",onOk:()=>{ke()},cancelText:"\u53D6\u6D88"})}},"\u5220\xA0\xA0\u9664"))),Te=Qe=>{let{nodeName:nn,src:sn}=Qe.target;nn==="IMG"&&(ct.Z.publish("preview-image",sn),console.log("src:",sn))};return(0,z.useEffect)(()=>{},[]),z.createElement("section",{className:Fe.wrap},z.createElement($e.Z,{separator:"/",className:"mb5"},z.createElement($e.Z.Item,null,z.createElement(Ke.Link,{to:`/forums/categories/${gn==null?void 0:gn.forum_id}`},Rn[gn==null?void 0:gn.forum_id])),z.createElement($e.Z.Item,null,"\u8BE6\u60C5")),z.createElement("header",{className:`bg-white pt40 pb40 pl30 pr30 ${Fe.header}`},z.createElement(Ae.Z,{align:"middle"},z.createElement(ye.Z,{flex:1,className:"font24 mb5"},z.createElement("span",{className:Fe.title},gn==null?void 0:gn.subject),(gn==null?void 0:gn.sticky)&&z.createElement("span",{className:Fe.top},"\u7F6E\u9876"),!!(gn!=null&&gn.reward)&&z.createElement(at.Z,{placement:"bottom",title:`\u83B7\u5F97\u5E73\u53F0\u5956\u52B1\u91D1\u5E01\uFF1A${gn==null?void 0:gn.reward}`},z.createElement("span",{className:"ml10 c-orange-ff7"},z.createElement("i",{className:"iconfont icon-gift font16 mr5"}),z.createElement("span",{className:"font14"},gn==null?void 0:gn.reward)))),z.createElement(ye.Z,null,(((Zn=vt.userInfo)==null?void 0:Zn.admin)||((Yn=vt.userInfo)==null?void 0:Yn.user_id)===(ir==null?void 0:ir.user_id))&&z.createElement(lt.Z,{dropdownRender:()=>we},z.createElement("i",{className:"fa fa-bars font-16 current c-grey-bcb"})))),z.createElement(Ae.Z,{align:"middle",className:"font14"},z.createElement(ye.Z,{flex:1,className:"c-grey-999"},z.createElement("span",null,it()(gn==null?void 0:gn.time).fromNow()," \u66F4\u65B0")),z.createElement(ye.Z,{className:"c-grey-999"},((Wn=vt.userInfo)==null?void 0:Wn.admin)&&z.createElement(at.Z,{placement:"bottom",title:"\u5E16\u5B50\u5956\u52B1"},z.createElement("span",{className:`current pr10 ${Fe.line}`,onClick:_e},z.createElement("i",{className:"iconfont icon-jiangli font18 mr5"}))),z.createElement("span",{className:`pr10 pl10 ${gn!=null&&gn.replies_count?Fe.line:""}`},z.createElement("i",{className:"iconfont icon-liulanyan font18 mr5"}),gn==null?void 0:gn.viewed_count),!!(gn!=null&&gn.replies_count)&&z.createElement(at.Z,{placement:"bottom",title:"\u5199\u8BC4\u8BBA"},z.createElement("span",{className:"current pl10",onClick:Ce},z.createElement("i",{className:"iconfont icon-huifu1 font18 mr5"}),gn==null?void 0:gn.replies_count))))),z.createElement("main",{className:"bg-white pt40 pb40 pl40 pr40"},z.createElement("div",{onClick:Te},z.createElement(je.Z,{value:gn==null?void 0:gn.content})),z.createElement("div",{className:"bg-white pl40 pr40 mt40"},z.createElement("div",{className:`mt10 mb20 ${Fe.flexCenter}`},z.createElement("div",{className:`${Fe.like} ${gn!=null&&gn.user_praise?"":Fe.canLike}`,onClick:Be},z.createElement("i",{className:"iconfont icon-dianzan font18"}),z.createElement("br",null),z.createElement("span",null,gn==null?void 0:gn.memo_praise_count)))),!!(Dt!=null&&Dt.length)&&z.createElement("div",{className:"mt40"},Dt==null?void 0:Dt.map(Qe=>z.createElement("div",{className:`c-grey-888 ${Fe.flexCenter}`},z.createElement("i",{className:"iconfont icon-fujian mr10 font14 c-green-29b"}),z.createElement("a",{href:Qe==null?void 0:Qe.url,title:Qe==null?void 0:Qe.title,className:`${Fe.attachmentName} mr10`},Qe==null?void 0:Qe.title),z.createElement("span",{className:"font12 c-grey-666 mt3"},Qe==null?void 0:Qe.filesize))))),z.createElement(Ee,{ref:Un,handleClick:Te}),z.createElement(bt.Z,null))};var Pe=(0,Ke.connect)(({user:xt,forumsDetail:$t,loading:vt,globalSetting:Vt})=>({user:xt,forumsDetail:$t,globalSetting:Vt,loading:vt.effects}))(On),rt={flex:"flex___fgmSn"},St=ie(29787),_t=Object.getOwnPropertySymbols,bn=Object.prototype.hasOwnProperty,In=Object.prototype.propertyIsEnumerable,rr=(xt,$t)=>{var vt={};for(var Vt in xt)bn.call(xt,Vt)&&$t.indexOf(Vt)<0&&(vt[Vt]=xt[Vt]);if(xt!=null&&_t)for(var Vt of _t(xt))$t.indexOf(Vt)<0&&In.call(xt,Vt)&&(vt[Vt]=xt[Vt]);return vt},Xn=(xt,$t,vt)=>new Promise((Vt,Ut)=>{var En=wn=>{try{xn(vt.next(wn))}catch(Bn){Ut(Bn)}},mn=wn=>{try{xn(vt.throw(wn))}catch(Bn){Ut(Bn)}},xn=wn=>wn.done?Vt(wn.value):Promise.resolve(wn.value).then(En,mn);xn((vt=vt.apply(xt,$t)).next())});const Cn=xt=>{var $t=xt,{forumsDetail:vt,globalSetting:Vt,loading:Ut,dispatch:En}=$t,mn=rr($t,["forumsDetail","globalSetting","loading","dispatch"]);const xn=(0,Ke.useParams)(),[wn,Bn]=(0,z.useState)(!1);(0,z.useEffect)(()=>{Zn()},[xn.memoId]);const Zn=()=>Xn(void 0,null,function*(){Bn(!0);let Yn=yield En({type:"forumsDetail/getForumsDetailData",payload:{id:xn.memoId}});Bn(!1)});return z.createElement(St.Z,{spinning:wn},z.createElement("section",{className:`edu-container mb20 mt30 ${rt.flex}`},z.createElement(Pe,null),z.createElement(mt,null)))};var Fn=(0,Ke.connect)(({forumsDetail:xt,loading:$t,globalSetting:vt})=>({forumsDetail:xt,globalSetting:vt,loading:$t.models.forumsDetail}))(Cn)},49142:function(ln,Ft,ie){"use strict";ie.d(Ft,{AL:function(){return mt},Iy:function(){return We},Qv:function(){return Xe},ez:function(){return Bt},jb:function(){return Se}});var z=ie(32834),Ke=ie.n(z),ve=ie(11690),Ae=ie.n(ve);let ye=1;function be(nt,tt){const ht=nt.match(/^(\s+)(?:```)/);if(ht===null)return tt;const $e=ht[1];return tt.split(`
|
|
|
`).map(at=>{const lt=at.match(/^\s+/);if(lt===null)return at;const[me]=lt;return me.length>=$e.length?at.slice($e.length):at}).join(`
|
|
|
`)}let Me=[],Re=["<ul>"];const Oe=new(Ke()).Renderer,fe=/^ *(#{1,6}) *([^\n]+?) *(?:#+ *)?(?:\n+|$)/;function We(){Me.length=0,Re=["<ul>"]}const Se={overflow:"hidden",WebkitBoxOrient:"vertical",display:"-webkit-box",WebkitLineClamp:2};function yt(nt,tt,ht,$e){if(tt>=nt.length||nt[tt].level<=ht)return tt;var at=nt[tt];$e.push("<li><a href='#"+ye+at.anchor+"'>"+at.text+"</a>"),tt++;var lt=[];return tt=yt(nt,tt,at.level,lt),lt.length>0&&($e.push("<ul>"),lt.forEach(function(me){$e.push(me)}),$e.push("</ul>")),$e.push("</li>"),tt=yt(nt,tt,ht,$e),tt}function Xe(){return yt(Me,0,0,Re),Re.push("</ul>"),Re.join("")}const Le={heading(nt){const tt=fe.exec(nt);if(ye+=1,tt)return{type:"heading",raw:tt[0],depth:tt[1].length,text:tt[2]}},fences(nt){const tt=this.rules.block.fences.exec(nt);if(tt){const ht=tt[0];let $e=be(ht,tt[3]||"");const at=tt[2]?tt[2].trim():tt[2];if(["latex","katex","math"].indexOf(at)>=0){const lt=dt(),me=$e;$e=lt,It[lt]={type:"block",expression:me}}return{type:"code",raw:ht,lang:at,text:$e}}}},Ge=/(?:\${2})([^\n`]+?)(?:\${2})/gi;let Ne=0;const dt=()=>`__special_katext_id_${Ne++}__`;let It={};function Bt(){return It}function mt(){Ne=0,It={}}function st(nt){return nt=nt.replace(Ge,(tt,ht)=>{const $e=dt();return It[$e]={type:"inline",expression:ht},$e}),nt}const it=Oe.listitem;Oe.listitem=function(nt){return it(st(nt))};const je=Oe.paragraph;Oe.paragraph=function(nt){return je(st(nt))};const Ot=Oe.tablecell;Oe.tablecell=function(nt,tt){return Ot(st(nt),tt)},Oe.code=function(nt,tt,ht){const $e=(tt||"").match(/\S*/)[0];return $e?["latex","katex","math"].indexOf($e)>=0?`<p class='editormd-tex'>${nt}</p>`:`<pre class="prettyprint linenums"><code class="language-${tt}">${ht?nt:(0,ve.escape)(nt,!0)}</code></pre>
|
|
|
`:'<pre class="prettyprint linenums"><code>'+(ht?nt:(0,ve.escape)(nt,!0))+"</code></pre>"},Oe.heading=function(nt,tt,ht){let $e=this.options.headerPrefix+ht.toLowerCase().replace(/[^\w\\u4e00-\\u9fa5]]+/g,"-");return Me.push({anchor:$e,level:tt,text:nt}),"<h"+tt+' id="'+ye+$e+'">'+nt+"</h"+tt+">"},Ke().setOptions({silent:!0,gfm:!0,pedantic:!1}),Ke().use({tokenizer:Le,renderer:Oe}),Ft.ZP=Ke()},86013:function(ln,Ft,ie){"use strict";var z=ie(59301),Ke=ie(19248);const ve=Ae=>{let ye;return typeof Ae=="object"&&(Ae!=null&&Ae.clearIcon)?ye=Ae:Ae&&(ye={clearIcon:z.createElement(Ke.Z,null)}),ye};Ft.Z=ve},91882:function(ln,Ft,ie){"use strict";ie.d(Ft,{Z:function(){return De}});var z=ie(59301),Ke=ie(92310),ve=ie.n(Ke),Ae=ie(11592),ye=ie(26112),be=ie(22703),Me=ie(48755),Re=ie(84105),Oe=ie(19563);const fe=He=>{let{children:Pt}=He;const{getPrefixCls:ge}=z.useContext(Me.E_),ce=ge("breadcrumb");return z.createElement("li",{className:`${ce}-separator`,"aria-hidden":"true"},Pt===""?Pt:Pt||"/")};fe.__ANT_BREADCRUMB_SEPARATOR=!0;var We=fe,Se=function(He,Pt){var ge={};for(var ce in He)Object.prototype.hasOwnProperty.call(He,ce)&&Pt.indexOf(ce)<0&&(ge[ce]=He[ce]);if(He!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Je=0,ce=Object.getOwnPropertySymbols(He);Je<ce.length;Je++)Pt.indexOf(ce[Je])<0&&Object.prototype.propertyIsEnumerable.call(He,ce[Je])&&(ge[ce[Je]]=He[ce[Je]]);return ge};function yt(He,Pt){if(He.title===void 0||He.title===null)return null;const ge=Object.keys(Pt).join("|");return typeof He.title=="object"?He.title:String(He.title).replace(new RegExp(`:(${ge})`,"g"),(ce,Je)=>Pt[Je]||ce)}function Xe(He,Pt,ge,ce){if(ge==null)return null;const{className:Je,onClick:jt}=Pt,wt=Se(Pt,["className","onClick"]),Ie=Object.assign(Object.assign({},(0,ye.Z)(wt,{data:!0,aria:!0})),{onClick:jt});return ce!==void 0?z.createElement("a",Object.assign({},Ie,{className:ve()(`${He}-link`,Je),href:ce}),ge):z.createElement("span",Object.assign({},Ie,{className:ve()(`${He}-link`,Je)}),ge)}function Le(He,Pt){return(ce,Je,jt,wt,Ie)=>{if(Pt)return Pt(ce,Je,jt,wt);const Ue=yt(ce,Je);return Xe(He,ce,Ue,Ie)}}var Ge=function(He,Pt){var ge={};for(var ce in He)Object.prototype.hasOwnProperty.call(He,ce)&&Pt.indexOf(ce)<0&&(ge[ce]=He[ce]);if(He!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Je=0,ce=Object.getOwnPropertySymbols(He);Je<ce.length;Je++)Pt.indexOf(ce[Je])<0&&Object.prototype.propertyIsEnumerable.call(He,ce[Je])&&(ge[ce[Je]]=He[ce[Je]]);return ge};const Ne=He=>{const{prefixCls:Pt,separator:ge="/",children:ce,menu:Je,overlay:jt,dropdownProps:wt,href:Ie}=He,et=(cn=>{if(Je||jt){const kt=Object.assign({},wt);if(Je){const Yt=Je||{},{items:ze}=Yt,zt=Ge(Yt,["items"]);kt.menu=Object.assign(Object.assign({},zt),{items:ze==null?void 0:ze.map((ut,ae)=>{var{key:te,title:ee,label:oe,path:se}=ut,ne=Ge(ut,["key","title","label","path"]);let he=oe!=null?oe:ee;return se&&(he=z.createElement("a",{href:`${Ie}${se}`},he)),Object.assign(Object.assign({},ne),{key:te!=null?te:ae,label:he})})})}else jt&&(kt.overlay=jt);return z.createElement(Oe.Z,Object.assign({placement:"bottom"},kt),z.createElement("span",{className:`${Pt}-overlay-link`},cn,z.createElement(Re.Z,null)))}return cn})(ce);return et!=null?z.createElement(z.Fragment,null,z.createElement("li",null,et),ge&&z.createElement(We,null,ge)):null},dt=He=>{const{prefixCls:Pt,children:ge,href:ce}=He,Je=Ge(He,["prefixCls","children","href"]),{getPrefixCls:jt}=z.useContext(Me.E_),wt=jt("breadcrumb",Pt);return z.createElement(Ne,Object.assign({},Je,{prefixCls:wt}),Xe(wt,Je,ge,ce))};dt.__ANT_BREADCRUMB_ITEM=!0;var It=dt,Bt=ie(36237),mt=ie(63356),st=ie(16931),it=ie(51636);const je=He=>{const{componentCls:Pt,iconCls:ge,calc:ce}=He;return{[Pt]:Object.assign(Object.assign({},(0,mt.Wf)(He)),{color:He.itemColor,fontSize:He.fontSize,[ge]:{fontSize:He.iconFontSize},ol:{display:"flex",flexWrap:"wrap",margin:0,padding:0,listStyle:"none"},a:Object.assign({color:He.linkColor,transition:`color ${He.motionDurationMid}`,padding:`0 ${(0,Bt.unit)(He.paddingXXS)}`,borderRadius:He.borderRadiusSM,height:He.fontHeight,display:"inline-block",marginInline:ce(He.marginXXS).mul(-1).equal(),"&:hover":{color:He.linkHoverColor,backgroundColor:He.colorBgTextHover}},(0,mt.Qy)(He)),"li:last-child":{color:He.lastItemColor},[`${Pt}-separator`]:{marginInline:He.separatorMargin,color:He.separatorColor},[`${Pt}-link`]:{[`
|
|
|
> ${ge} + span,
|
|
|
> ${ge} + a
|
|
|
`]:{marginInlineStart:He.marginXXS}},[`${Pt}-overlay-link`]:{borderRadius:He.borderRadiusSM,height:He.fontHeight,display:"inline-block",padding:`0 ${(0,Bt.unit)(He.paddingXXS)}`,marginInline:ce(He.marginXXS).mul(-1).equal(),[`> ${ge}`]:{marginInlineStart:He.marginXXS,fontSize:He.fontSizeIcon},"&:hover":{color:He.linkHoverColor,backgroundColor:He.colorBgTextHover,a:{color:He.linkHoverColor}},a:{"&:hover":{backgroundColor:"transparent"}}},[`&${He.componentCls}-rtl`]:{direction:"rtl"}})}},Ot=He=>({itemColor:He.colorTextDescription,lastItemColor:He.colorText,iconFontSize:He.fontSize,linkColor:He.colorTextDescription,linkHoverColor:He.colorText,separatorColor:He.colorTextDescription,separatorMargin:He.marginXS});var nt=(0,st.I$)("Breadcrumb",He=>{const Pt=(0,it.mergeToken)(He,{});return je(Pt)},Ot),tt=function(He,Pt){var ge={};for(var ce in He)Object.prototype.hasOwnProperty.call(He,ce)&&Pt.indexOf(ce)<0&&(ge[ce]=He[ce]);if(He!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Je=0,ce=Object.getOwnPropertySymbols(He);Je<ce.length;Je++)Pt.indexOf(ce[Je])<0&&Object.prototype.propertyIsEnumerable.call(He,ce[Je])&&(ge[ce[Je]]=He[ce[Je]]);return ge};function ht(He){const{breadcrumbName:Pt,children:ge}=He,ce=tt(He,["breadcrumbName","children"]),Je=Object.assign({title:Pt},ce);return ge&&(Je.menu={items:ge.map(jt=>{var{breadcrumbName:wt}=jt,Ie=tt(jt,["breadcrumbName"]);return Object.assign(Object.assign({},Ie),{title:wt})})}),Je}function $e(He,Pt){return(0,z.useMemo)(()=>He||(Pt?Pt.map(ht):null),[He,Pt])}var at=function(He,Pt){var ge={};for(var ce in He)Object.prototype.hasOwnProperty.call(He,ce)&&Pt.indexOf(ce)<0&&(ge[ce]=He[ce]);if(He!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Je=0,ce=Object.getOwnPropertySymbols(He);Je<ce.length;Je++)Pt.indexOf(ce[Je])<0&&Object.prototype.propertyIsEnumerable.call(He,ce[Je])&&(ge[ce[Je]]=He[ce[Je]]);return ge};const lt=(He,Pt)=>{if(Pt===void 0)return Pt;let ge=(Pt||"").replace(/^\//,"");return Object.keys(He).forEach(ce=>{ge=ge.replace(`:${ce}`,He[ce])}),ge},me=He=>{const{prefixCls:Pt,separator:ge="/",style:ce,className:Je,rootClassName:jt,routes:wt,items:Ie,children:Ue,itemRender:et,params:cn={}}=He,kt=at(He,["prefixCls","separator","style","className","rootClassName","routes","items","children","itemRender","params"]),{getPrefixCls:Yt,direction:ze,breadcrumb:zt}=z.useContext(Me.E_);let ut;const ae=Yt("breadcrumb",Pt),[te,ee,oe]=nt(ae),se=$e(Ie,wt),ne=Le(ae,et);if(se&&se.length>0){const ot=[],Ee=Ie||wt;ut=se.map((Fe,qe)=>{const{path:bt,key:ct,type:Kt,menu:Wt,overlay:Nt,onClick:rn,className:qt,separator:on,dropdownProps:ft}=Fe,Gt=lt(cn,bt);Gt!==void 0&&ot.push(Gt);const Tt=ct!=null?ct:qe;if(Kt==="separator")return z.createElement(We,{key:Tt},on);const en={},yn=qe===se.length-1;Wt?en.menu=Wt:Nt&&(en.overlay=Nt);let{href:Rn}=Fe;return ot.length&&Gt!==void 0&&(Rn=`#/${ot.join("/")}`),z.createElement(Ne,Object.assign({key:Tt},en,(0,ye.Z)(Fe,{data:!0,aria:!0}),{className:qt,dropdownProps:ft,href:Rn,separator:yn?"":ge,onClick:rn,prefixCls:ae}),ne(Fe,cn,Ee,ot,Rn))})}else if(Ue){const ot=(0,Ae.Z)(Ue).length;ut=(0,Ae.Z)(Ue).map((Ee,Fe)=>{if(!Ee)return Ee;const qe=Fe===ot-1;return(0,be.Tm)(Ee,{separator:qe?"":ge,key:Fe})})}const he=ve()(ae,zt==null?void 0:zt.className,{[`${ae}-rtl`]:ze==="rtl"},Je,jt,ee,oe),xe=Object.assign(Object.assign({},zt==null?void 0:zt.style),ce);return te(z.createElement("nav",Object.assign({className:he,style:xe},kt),z.createElement("ol",null,ut)))};me.Item=It,me.Separator=We;var At=me,De=At},38406:function(ln,Ft,ie){"use strict";var z=ie(59301),Ke=ie(48755),ve=ie(584);const Ae=ye=>{const{componentName:be}=ye,{getPrefixCls:Me}=(0,z.useContext)(Ke.E_),Re=Me("empty");switch(be){case"Table":case"List":return z.createElement(ve.Z,{image:ve.Z.PRESENTED_IMAGE_SIMPLE});case"Select":case"TreeSelect":case"Cascader":case"Transfer":case"Mentions":return z.createElement(ve.Z,{image:ve.Z.PRESENTED_IMAGE_SIMPLE,className:`${Re}-small`});case"Table.filter":return null;default:return z.createElement(ve.Z,null)}};Ft.Z=Ae},36207:function(ln,Ft,ie){"use strict";ie.d(Ft,{Z:function(){return ot}});var z=ie(59301),Ke=ie(92310),ve=ie.n(Ke),Ae=ie(33885),ye=ie(42978),be=ie(43403),Me=ie(34280),Re=z.createContext(null),Oe=z.createContext({}),fe=Re,We=ie(20068),Se=ie(54476),yt=ie(77900),Xe=ie(10228),Le=ie(26112),Ge=ie(75931),Ne=ie(8654),dt=["prefixCls","className","containerRef"],It=function(Fe){var qe=Fe.prefixCls,bt=Fe.className,ct=Fe.containerRef,Kt=(0,Ge.Z)(Fe,dt),Wt=z.useContext(Oe),Nt=Wt.panel,rn=(0,Ne.x1)(Nt,ct);return z.createElement("div",(0,Se.Z)({className:ve()("".concat(qe,"-content"),bt),role:"dialog",ref:rn},(0,Le.Z)(Fe,{aria:!0}),{"aria-modal":"true"},Kt))},Bt=It,mt=ie(48736);function st(Ee){return typeof Ee=="string"&&String(Number(Ee))===Ee?((0,mt.ZP)(!1,"Invalid value type of `width` or `height` which should be number type instead."),Number(Ee)):Ee}function it(Ee){warning(!("wrapperClassName"in Ee),"'wrapperClassName' is removed. Please use 'rootClassName' instead."),warning(canUseDom()||!Ee.open,"Drawer with 'open' in SSR is not work since no place to createPortal. Please move to 'useEffect' instead.")}var je={width:0,height:0,overflow:"hidden",outline:"none",position:"absolute"};function Ot(Ee,Fe){var qe,bt,ct,Kt=Ee.prefixCls,Wt=Ee.open,Nt=Ee.placement,rn=Ee.inline,qt=Ee.push,on=Ee.forceRender,ft=Ee.autoFocus,Gt=Ee.keyboard,Tt=Ee.classNames,en=Ee.rootClassName,yn=Ee.rootStyle,Rn=Ee.zIndex,On=Ee.className,Pe=Ee.id,rt=Ee.style,St=Ee.motion,_t=Ee.width,bn=Ee.height,In=Ee.children,rr=Ee.mask,Xn=Ee.maskClosable,Cn=Ee.maskMotion,Fn=Ee.maskClassName,xt=Ee.maskStyle,$t=Ee.afterOpenChange,vt=Ee.onClose,Vt=Ee.onMouseEnter,Ut=Ee.onMouseOver,En=Ee.onMouseLeave,mn=Ee.onClick,xn=Ee.onKeyDown,wn=Ee.onKeyUp,Bn=Ee.styles,Zn=Ee.drawerRender,Yn=z.useRef(),Wn=z.useRef(),ir=z.useRef();z.useImperativeHandle(Fe,function(){return Yn.current});var gn=function(Ct){var pt=Ct.keyCode,un=Ct.shiftKey;switch(pt){case Xe.Z.TAB:{if(pt===Xe.Z.TAB){if(!un&&document.activeElement===ir.current){var $n;($n=Wn.current)===null||$n===void 0||$n.focus({preventScroll:!0})}else if(un&&document.activeElement===Wn.current){var Dn;(Dn=ir.current)===null||Dn===void 0||Dn.focus({preventScroll:!0})}}break}case Xe.Z.ESC:{vt&&Gt&&(Ct.stopPropagation(),vt(Ct));break}}};z.useEffect(function(){if(Wt&&ft){var Ht;(Ht=Yn.current)===null||Ht===void 0||Ht.focus({preventScroll:!0})}},[Wt]);var Dt=z.useState(!1),Qt=(0,ye.Z)(Dt,2),Un=Qt[0],fr=Qt[1],ke=z.useContext(fe),_e;typeof qt=="boolean"?_e=qt?{}:{distance:0}:_e=qt||{};var Ce=(qe=(bt=(ct=_e)===null||ct===void 0?void 0:ct.distance)!==null&&bt!==void 0?bt:ke==null?void 0:ke.pushDistance)!==null&&qe!==void 0?qe:180,Be=z.useMemo(function(){return{pushDistance:Ce,push:function(){fr(!0)},pull:function(){fr(!1)}}},[Ce]);z.useEffect(function(){if(Wt){var Ht;ke==null||(Ht=ke.push)===null||Ht===void 0||Ht.call(ke)}else{var Ct;ke==null||(Ct=ke.pull)===null||Ct===void 0||Ct.call(ke)}},[Wt]),z.useEffect(function(){return function(){var Ht;ke==null||(Ht=ke.pull)===null||Ht===void 0||Ht.call(ke)}},[]);var we=rr&&z.createElement(yt.default,(0,Se.Z)({key:"mask"},Cn,{visible:Wt}),function(Ht,Ct){var pt=Ht.className,un=Ht.style;return z.createElement("div",{className:ve()("".concat(Kt,"-mask"),pt,Tt==null?void 0:Tt.mask,Fn),style:(0,Ae.Z)((0,Ae.Z)((0,Ae.Z)({},un),xt),Bn==null?void 0:Bn.mask),onClick:Xn&&Wt?vt:void 0,ref:Ct})}),Te=typeof St=="function"?St(Nt):St,Qe={};if(Un&&Ce)switch(Nt){case"top":Qe.transform="translateY(".concat(Ce,"px)");break;case"bottom":Qe.transform="translateY(".concat(-Ce,"px)");break;case"left":Qe.transform="translateX(".concat(Ce,"px)");break;default:Qe.transform="translateX(".concat(-Ce,"px)");break}Nt==="left"||Nt==="right"?Qe.width=st(_t):Qe.height=st(bn);var nn={onMouseEnter:Vt,onMouseOver:Ut,onMouseLeave:En,onClick:mn,onKeyDown:xn,onKeyUp:wn},sn=z.createElement(yt.default,(0,Se.Z)({key:"panel"},Te,{visible:Wt,forceRender:on,onVisibleChanged:function(Ct){$t==null||$t(Ct)},removeOnLeave:!1,leavedClassName:"".concat(Kt,"-content-wrapper-hidden")}),function(Ht,Ct){var pt=Ht.className,un=Ht.style,$n=z.createElement(Bt,(0,Se.Z)({id:Pe,containerRef:Ct,prefixCls:Kt,className:ve()(On,Tt==null?void 0:Tt.content),style:(0,Ae.Z)((0,Ae.Z)({},rt),Bn==null?void 0:Bn.content)},(0,Le.Z)(Ee,{aria:!0}),nn),In);return z.createElement("div",(0,Se.Z)({className:ve()("".concat(Kt,"-content-wrapper"),Tt==null?void 0:Tt.wrapper,pt),style:(0,Ae.Z)((0,Ae.Z)((0,Ae.Z)({},Qe),un),Bn==null?void 0:Bn.wrapper)},(0,Le.Z)(Ee,{data:!0})),Zn?Zn($n):$n)}),Xt=(0,Ae.Z)({},yn);return Rn&&(Xt.zIndex=Rn),z.createElement(fe.Provider,{value:Be},z.createElement("div",{className:ve()(Kt,"".concat(Kt,"-").concat(Nt),en,(0,We.Z)((0,We.Z)({},"".concat(Kt,"-open"),Wt),"".concat(Kt,"-inline"),rn)),style:Xt,tabIndex:-1,ref:Yn,onKeyDown:gn},we,z.createElement("div",{tabIndex:0,ref:Wn,style:je,"aria-hidden":"true","data-sentinel":"start"}),sn,z.createElement("div",{tabIndex:0,ref:ir,style:je,"aria-hidden":"true","data-sentinel":"end"})))}var nt=z.forwardRef(Ot),tt=nt,ht=function(Fe){var qe=Fe.open,bt=qe===void 0?!1:qe,ct=Fe.prefixCls,Kt=ct===void 0?"rc-drawer":ct,Wt=Fe.placement,Nt=Wt===void 0?"right":Wt,rn=Fe.autoFocus,qt=rn===void 0?!0:rn,on=Fe.keyboard,ft=on===void 0?!0:on,Gt=Fe.width,Tt=Gt===void 0?378:Gt,en=Fe.mask,yn=en===void 0?!0:en,Rn=Fe.maskClosable,On=Rn===void 0?!0:Rn,Pe=Fe.getContainer,rt=Fe.forceRender,St=Fe.afterOpenChange,_t=Fe.destroyOnClose,bn=Fe.onMouseEnter,In=Fe.onMouseOver,rr=Fe.onMouseLeave,Xn=Fe.onClick,Cn=Fe.onKeyDown,Fn=Fe.onKeyUp,xt=Fe.panelRef,$t=z.useState(!1),vt=(0,ye.Z)($t,2),Vt=vt[0],Ut=vt[1],En=z.useState(!1),mn=(0,ye.Z)(En,2),xn=mn[0],wn=mn[1];(0,Me.Z)(function(){wn(!0)},[]);var Bn=xn?bt:!1,Zn=z.useRef(),Yn=z.useRef();(0,Me.Z)(function(){Bn&&(Yn.current=document.activeElement)},[Bn]);var Wn=function(Un){var fr;if(Ut(Un),St==null||St(Un),!Un&&Yn.current&&!((fr=Zn.current)!==null&&fr!==void 0&&fr.contains(Yn.current))){var ke;(ke=Yn.current)===null||ke===void 0||ke.focus({preventScroll:!0})}},ir=z.useMemo(function(){return{panel:xt}},[xt]);if(!rt&&!Vt&&!Bn&&_t)return null;var gn={onMouseEnter:bn,onMouseOver:In,onMouseLeave:rr,onClick:Xn,onKeyDown:Cn,onKeyUp:Fn},Dt=(0,Ae.Z)((0,Ae.Z)({},Fe),{},{open:Bn,prefixCls:Kt,placement:Nt,autoFocus:qt,keyboard:ft,width:Tt,mask:yn,maskClosable:On,inline:Pe===!1,afterOpenChange:Wn,ref:Zn},gn);return z.createElement(Oe.Provider,{value:ir},z.createElement(be.Z,{open:Bn||rt||Vt,autoDestroy:!1,getContainer:Pe,autoLock:yn&&(Bn||Vt)},z.createElement(tt,Dt)))},$e=ht,at=$e,lt=ie(62487),me=ie(75030),At=ie(86641),De=ie(55743),He=ie(48755),Pt=ie(91190),ge=ie(78776),ce=ie(458),jt=Ee=>{var Fe,qe;const{prefixCls:bt,title:ct,footer:Kt,extra:Wt,loading:Nt,onClose:rn,headerStyle:qt,bodyStyle:on,footerStyle:ft,children:Gt,classNames:Tt,styles:en}=Ee,yn=(0,He.dj)("drawer"),Rn=z.useCallback(_t=>z.createElement("button",{type:"button",onClick:rn,"aria-label":"Close",className:`${bt}-close`},_t),[rn]),[On,Pe]=(0,ge.Z)((0,ge.w)(Ee),(0,ge.w)(yn),{closable:!0,closeIconRender:Rn}),rt=z.useMemo(()=>{var _t,bn;return!ct&&!On?null:z.createElement("div",{style:Object.assign(Object.assign(Object.assign({},(_t=yn.styles)===null||_t===void 0?void 0:_t.header),qt),en==null?void 0:en.header),className:ve()(`${bt}-header`,{[`${bt}-header-close-only`]:On&&!ct&&!Wt},(bn=yn.classNames)===null||bn===void 0?void 0:bn.header,Tt==null?void 0:Tt.header)},z.createElement("div",{className:`${bt}-header-title`},Pe,ct&&z.createElement("div",{className:`${bt}-title`},ct)),Wt&&z.createElement("div",{className:`${bt}-extra`},Wt))},[On,Pe,Wt,qt,bt,ct]),St=z.useMemo(()=>{var _t,bn;if(!Kt)return null;const In=`${bt}-footer`;return z.createElement("div",{className:ve()(In,(_t=yn.classNames)===null||_t===void 0?void 0:_t.footer,Tt==null?void 0:Tt.footer),style:Object.assign(Object.assign(Object.assign({},(bn=yn.styles)===null||bn===void 0?void 0:bn.footer),ft),en==null?void 0:en.footer)},Kt)},[Kt,ft,bt]);return z.createElement(z.Fragment,null,rt,z.createElement("div",{className:ve()(`${bt}-body`,Tt==null?void 0:Tt.body,(Fe=yn.classNames)===null||Fe===void 0?void 0:Fe.body),style:Object.assign(Object.assign(Object.assign({},(qe=yn.styles)===null||qe===void 0?void 0:qe.body),on),en==null?void 0:en.body)},Nt?z.createElement(ce.Z,{active:!0,title:!1,paragraph:{rows:5},className:`${bt}-body-skeleton`}):Gt),St)},wt=ie(36237),Ie=ie(63356),Ue=ie(16931),et=ie(51636);const cn=Ee=>{const Fe="100%";return{left:`translateX(-${Fe})`,right:`translateX(${Fe})`,top:`translateY(-${Fe})`,bottom:`translateY(${Fe})`}[Ee]},kt=(Ee,Fe)=>({"&-enter, &-appear":Object.assign(Object.assign({},Ee),{"&-active":Fe}),"&-leave":Object.assign(Object.assign({},Fe),{"&-active":Ee})}),Yt=(Ee,Fe)=>Object.assign({"&-enter, &-appear, &-leave":{"&-start":{transition:"none"},"&-active":{transition:`all ${Fe}`}}},kt({opacity:Ee},{opacity:1})),ze=(Ee,Fe)=>[Yt(.7,Fe),kt({transform:cn(Ee)},{transform:"none"})];var ut=Ee=>{const{componentCls:Fe,motionDurationSlow:qe}=Ee;return{[Fe]:{[`${Fe}-mask-motion`]:Yt(0,qe),[`${Fe}-panel-motion`]:["left","right","top","bottom"].reduce((bt,ct)=>Object.assign(Object.assign({},bt),{[`&-${ct}`]:ze(ct,qe)}),{})}}};const ae=Ee=>{const{borderRadiusSM:Fe,componentCls:qe,zIndexPopup:bt,colorBgMask:ct,colorBgElevated:Kt,motionDurationSlow:Wt,motionDurationMid:Nt,paddingXS:rn,padding:qt,paddingLG:on,fontSizeLG:ft,lineHeightLG:Gt,lineWidth:Tt,lineType:en,colorSplit:yn,marginXS:Rn,colorIcon:On,colorIconHover:Pe,colorBgTextHover:rt,colorBgTextActive:St,colorText:_t,fontWeightStrong:bn,footerPaddingBlock:In,footerPaddingInline:rr,calc:Xn}=Ee,Cn=`${qe}-content-wrapper`;return{[qe]:{position:"fixed",inset:0,zIndex:bt,pointerEvents:"none",color:_t,"&-pure":{position:"relative",background:Kt,display:"flex",flexDirection:"column",[`&${qe}-left`]:{boxShadow:Ee.boxShadowDrawerLeft},[`&${qe}-right`]:{boxShadow:Ee.boxShadowDrawerRight},[`&${qe}-top`]:{boxShadow:Ee.boxShadowDrawerUp},[`&${qe}-bottom`]:{boxShadow:Ee.boxShadowDrawerDown}},"&-inline":{position:"absolute"},[`${qe}-mask`]:{position:"absolute",inset:0,zIndex:bt,background:ct,pointerEvents:"auto"},[Cn]:{position:"absolute",zIndex:bt,maxWidth:"100vw",transition:`all ${Wt}`,"&-hidden":{display:"none"}},[`&-left > ${Cn}`]:{top:0,bottom:0,left:{_skip_check_:!0,value:0},boxShadow:Ee.boxShadowDrawerLeft},[`&-right > ${Cn}`]:{top:0,right:{_skip_check_:!0,value:0},bottom:0,boxShadow:Ee.boxShadowDrawerRight},[`&-top > ${Cn}`]:{top:0,insetInline:0,boxShadow:Ee.boxShadowDrawerUp},[`&-bottom > ${Cn}`]:{bottom:0,insetInline:0,boxShadow:Ee.boxShadowDrawerDown},[`${qe}-content`]:{display:"flex",flexDirection:"column",width:"100%",height:"100%",overflow:"auto",background:Kt,pointerEvents:"auto"},[`${qe}-header`]:{display:"flex",flex:0,alignItems:"center",padding:`${(0,wt.unit)(qt)} ${(0,wt.unit)(on)}`,fontSize:ft,lineHeight:Gt,borderBottom:`${(0,wt.unit)(Tt)} ${en} ${yn}`,"&-title":{display:"flex",flex:1,alignItems:"center",minWidth:0,minHeight:0}},[`${qe}-extra`]:{flex:"none"},[`${qe}-close`]:Object.assign({display:"inline-flex",width:Xn(ft).add(rn).equal(),height:Xn(ft).add(rn).equal(),borderRadius:Fe,justifyContent:"center",alignItems:"center",marginInlineEnd:Rn,color:On,fontWeight:bn,fontSize:ft,fontStyle:"normal",lineHeight:1,textAlign:"center",textTransform:"none",textDecoration:"none",background:"transparent",border:0,cursor:"pointer",transition:`all ${Nt}`,textRendering:"auto","&:hover":{color:Pe,backgroundColor:rt,textDecoration:"none"},"&:active":{backgroundColor:St}},(0,Ie.Qy)(Ee)),[`${qe}-title`]:{flex:1,margin:0,fontWeight:Ee.fontWeightStrong,fontSize:ft,lineHeight:Gt},[`${qe}-body`]:{flex:1,minWidth:0,minHeight:0,padding:on,overflow:"auto",[`${qe}-body-skeleton`]:{width:"100%",height:"100%",display:"flex",justifyContent:"center"}},[`${qe}-footer`]:{flexShrink:0,padding:`${(0,wt.unit)(In)} ${(0,wt.unit)(rr)}`,borderTop:`${(0,wt.unit)(Tt)} ${en} ${yn}`},"&-rtl":{direction:"rtl"}}}},te=Ee=>({zIndexPopup:Ee.zIndexPopupBase,footerPaddingBlock:Ee.paddingXS,footerPaddingInline:Ee.padding});var ee=(0,Ue.I$)("Drawer",Ee=>{const Fe=(0,et.mergeToken)(Ee,{});return[ae(Fe),ut(Fe)]},te),oe=function(Ee,Fe){var qe={};for(var bt in Ee)Object.prototype.hasOwnProperty.call(Ee,bt)&&Fe.indexOf(bt)<0&&(qe[bt]=Ee[bt]);if(Ee!=null&&typeof Object.getOwnPropertySymbols=="function")for(var ct=0,bt=Object.getOwnPropertySymbols(Ee);ct<bt.length;ct++)Fe.indexOf(bt[ct])<0&&Object.prototype.propertyIsEnumerable.call(Ee,bt[ct])&&(qe[bt[ct]]=Ee[bt[ct]]);return qe};const se=null,ne={distance:180},he=Ee=>{var Fe;const{rootClassName:qe,width:bt,height:ct,size:Kt="default",mask:Wt=!0,push:Nt=ne,open:rn,afterOpenChange:qt,onClose:on,prefixCls:ft,getContainer:Gt,style:Tt,className:en,visible:yn,afterVisibleChange:Rn,maskStyle:On,drawerStyle:Pe,contentWrapperStyle:rt}=Ee,St=oe(Ee,["rootClassName","width","height","size","mask","push","open","afterOpenChange","onClose","prefixCls","getContainer","style","className","visible","afterVisibleChange","maskStyle","drawerStyle","contentWrapperStyle"]),{getPopupContainer:_t,getPrefixCls:bn,direction:In,className:rr,style:Xn,classNames:Cn,styles:Fn}=(0,He.dj)("drawer"),xt=bn("drawer",ft),[$t,vt,Vt]=ee(xt),Ut=Gt===void 0&&_t?()=>_t(document.body):Gt,En=ve()({"no-mask":!Wt,[`${xt}-rtl`]:In==="rtl"},qe,vt,Vt),mn=z.useMemo(()=>bt!=null?bt:Kt==="large"?736:378,[bt,Kt]),xn=z.useMemo(()=>ct!=null?ct:Kt==="large"?736:378,[ct,Kt]),wn={motionName:(0,At.m)(xt,"mask-motion"),motionAppear:!0,motionEnter:!0,motionLeave:!0,motionDeadline:500},Bn=Dt=>({motionName:(0,At.m)(xt,`panel-motion-${Dt}`),motionAppear:!0,motionEnter:!0,motionLeave:!0,motionDeadline:500}),Zn=(0,Pt.H)(),[Yn,Wn]=(0,me.Cn)("Drawer",St.zIndex),{classNames:ir={},styles:gn={}}=St;return $t(z.createElement(lt.Z,{form:!0,space:!0},z.createElement(De.Z.Provider,{value:Wn},z.createElement(at,Object.assign({prefixCls:xt,onClose:on,maskMotion:wn,motion:Bn},St,{classNames:{mask:ve()(ir.mask,Cn.mask),content:ve()(ir.content,Cn.content),wrapper:ve()(ir.wrapper,Cn.wrapper)},styles:{mask:Object.assign(Object.assign(Object.assign({},gn.mask),On),Fn.mask),content:Object.assign(Object.assign(Object.assign({},gn.content),Pe),Fn.content),wrapper:Object.assign(Object.assign(Object.assign({},gn.wrapper),rt),Fn.wrapper)},open:rn!=null?rn:yn,mask:Wt,push:Nt,width:mn,height:xn,style:Object.assign(Object.assign({},Xn),Tt),className:ve()(rr,en),rootClassName:En,getContainer:Ut,afterOpenChange:qt!=null?qt:Rn,panelRef:Zn,zIndex:Yn}),z.createElement(jt,Object.assign({prefixCls:xt},St,{onClose:on}))))))},xe=Ee=>{const{prefixCls:Fe,style:qe,className:bt,placement:ct="right"}=Ee,Kt=oe(Ee,["prefixCls","style","className","placement"]),{getPrefixCls:Wt}=z.useContext(He.E_),Nt=Wt("drawer",Fe),[rn,qt,on]=ee(Nt),ft=ve()(Nt,`${Nt}-pure`,`${Nt}-${ct}`,qt,on,bt);return rn(z.createElement("div",{className:ft,style:qe},z.createElement(jt,Object.assign({prefixCls:Nt},Kt))))};he._InternalPanelDoNotUseOrYouWillBeFired=xe;var ot=he},19563:function(ln,Ft,ie){"use strict";ie.d(Ft,{Z:function(){return wt}});var z=ie(59301),Ke=ie(33853),ve=ie(38819),Ae=ie(92310),ye=ie.n(Ae),be=ie(96478),Me=ie(6089),Re=ie(18929),Oe=ie(2738),fe=ie(75030),Se=Ie=>typeof Ie!="object"&&typeof Ie!="function"||Ie===null,yt=ie(52838),Xe=ie(45915),Le=ie(22703),Ge=ie(32383),Ne=ie(55743),dt=ie(48755),It=ie(83397),Bt=ie(93041),mt=ie(78857),st=ie(57700),it=ie(36237),je=ie(63356),Ot=ie(46e3),nt=ie(93873),tt=ie(34925),ht=ie(37645),$e=ie(36305),at=ie(16931),lt=ie(51636),At=Ie=>{const{componentCls:Ue,menuCls:et,colorError:cn,colorTextLightSolid:kt}=Ie,Yt=`${et}-item`;return{[`${Ue}, ${Ue}-menu-submenu`]:{[`${et} ${Yt}`]:{[`&${Yt}-danger:not(${Yt}-disabled)`]:{color:cn,"&:hover":{color:kt,backgroundColor:cn}}}}}};const De=Ie=>{const{componentCls:Ue,menuCls:et,zIndexPopup:cn,dropdownArrowDistance:kt,sizePopupArrow:Yt,antCls:ze,iconCls:zt,motionDurationMid:ut,paddingBlock:ae,fontSize:te,dropdownEdgeChildPadding:ee,colorTextDisabled:oe,fontSizeIcon:se,controlPaddingHorizontal:ne,colorBgElevated:he}=Ie;return[{[Ue]:{position:"absolute",top:-9999,left:{_skip_check_:!0,value:-9999},zIndex:cn,display:"block","&::before":{position:"absolute",insetBlock:Ie.calc(Yt).div(2).sub(kt).equal(),zIndex:-9999,opacity:1e-4,content:'""'},"&-menu-vertical":{maxHeight:"100vh",overflowY:"auto"},[`&-trigger${ze}-btn`]:{[`& > ${zt}-down, & > ${ze}-btn-icon > ${zt}-down`]:{fontSize:se}},[`${Ue}-wrap`]:{position:"relative",[`${ze}-btn > ${zt}-down`]:{fontSize:se},[`${zt}-down::before`]:{transition:`transform ${ut}`}},[`${Ue}-wrap-open`]:{[`${zt}-down::before`]:{transform:"rotate(180deg)"}},"\n &-hidden,\n &-menu-hidden,\n &-menu-submenu-hidden\n ":{display:"none"},[`&${ze}-slide-down-enter${ze}-slide-down-enter-active${Ue}-placement-bottomLeft,
|
|
|
&${ze}-slide-down-appear${ze}-slide-down-appear-active${Ue}-placement-bottomLeft,
|
|
|
&${ze}-slide-down-enter${ze}-slide-down-enter-active${Ue}-placement-bottom,
|
|
|
&${ze}-slide-down-appear${ze}-slide-down-appear-active${Ue}-placement-bottom,
|
|
|
&${ze}-slide-down-enter${ze}-slide-down-enter-active${Ue}-placement-bottomRight,
|
|
|
&${ze}-slide-down-appear${ze}-slide-down-appear-active${Ue}-placement-bottomRight`]:{animationName:Ot.fJ},[`&${ze}-slide-up-enter${ze}-slide-up-enter-active${Ue}-placement-topLeft,
|
|
|
&${ze}-slide-up-appear${ze}-slide-up-appear-active${Ue}-placement-topLeft,
|
|
|
&${ze}-slide-up-enter${ze}-slide-up-enter-active${Ue}-placement-top,
|
|
|
&${ze}-slide-up-appear${ze}-slide-up-appear-active${Ue}-placement-top,
|
|
|
&${ze}-slide-up-enter${ze}-slide-up-enter-active${Ue}-placement-topRight,
|
|
|
&${ze}-slide-up-appear${ze}-slide-up-appear-active${Ue}-placement-topRight`]:{animationName:Ot.Qt},[`&${ze}-slide-down-leave${ze}-slide-down-leave-active${Ue}-placement-bottomLeft,
|
|
|
&${ze}-slide-down-leave${ze}-slide-down-leave-active${Ue}-placement-bottom,
|
|
|
&${ze}-slide-down-leave${ze}-slide-down-leave-active${Ue}-placement-bottomRight`]:{animationName:Ot.Uw},[`&${ze}-slide-up-leave${ze}-slide-up-leave-active${Ue}-placement-topLeft,
|
|
|
&${ze}-slide-up-leave${ze}-slide-up-leave-active${Ue}-placement-top,
|
|
|
&${ze}-slide-up-leave${ze}-slide-up-leave-active${Ue}-placement-topRight`]:{animationName:Ot.ly}}},(0,ht.ZP)(Ie,he,{arrowPlacement:{top:!0,bottom:!0}}),{[`${Ue} ${et}`]:{position:"relative",margin:0},[`${et}-submenu-popup`]:{position:"absolute",zIndex:cn,background:"transparent",boxShadow:"none",transformOrigin:"0 0","ul, li":{listStyle:"none",margin:0}},[`${Ue}, ${Ue}-menu-submenu`]:Object.assign(Object.assign({},(0,je.Wf)(Ie)),{[et]:Object.assign(Object.assign({padding:ee,listStyleType:"none",backgroundColor:he,backgroundClip:"padding-box",borderRadius:Ie.borderRadiusLG,outline:"none",boxShadow:Ie.boxShadowSecondary},(0,je.Qy)(Ie)),{"&:empty":{padding:0,boxShadow:"none"},[`${et}-item-group-title`]:{padding:`${(0,it.unit)(ae)} ${(0,it.unit)(ne)}`,color:Ie.colorTextDescription,transition:`all ${ut}`},[`${et}-item`]:{position:"relative",display:"flex",alignItems:"center"},[`${et}-item-icon`]:{minWidth:te,marginInlineEnd:Ie.marginXS,fontSize:Ie.fontSizeSM},[`${et}-title-content`]:{flex:"auto","&-with-extra":{display:"inline-flex",alignItems:"center",width:"100%"},"> a":{color:"inherit",transition:`all ${ut}`,"&:hover":{color:"inherit"},"&::after":{position:"absolute",inset:0,content:'""'}},[`${et}-item-extra`]:{paddingInlineStart:Ie.padding,marginInlineStart:"auto",fontSize:Ie.fontSizeSM,color:Ie.colorTextDescription}},[`${et}-item, ${et}-submenu-title`]:Object.assign(Object.assign({display:"flex",margin:0,padding:`${(0,it.unit)(ae)} ${(0,it.unit)(ne)}`,color:Ie.colorText,fontWeight:"normal",fontSize:te,lineHeight:Ie.lineHeight,cursor:"pointer",transition:`all ${ut}`,borderRadius:Ie.borderRadiusSM,"&:hover, &-active":{backgroundColor:Ie.controlItemBgHover}},(0,je.Qy)(Ie)),{"&-selected":{color:Ie.colorPrimary,backgroundColor:Ie.controlItemBgActive,"&:hover, &-active":{backgroundColor:Ie.controlItemBgActiveHover}},"&-disabled":{color:oe,cursor:"not-allowed","&:hover":{color:oe,backgroundColor:he,cursor:"not-allowed"},a:{pointerEvents:"none"}},"&-divider":{height:1,margin:`${(0,it.unit)(Ie.marginXXS)} 0`,overflow:"hidden",lineHeight:0,backgroundColor:Ie.colorSplit},[`${Ue}-menu-submenu-expand-icon`]:{position:"absolute",insetInlineEnd:Ie.paddingXS,[`${Ue}-menu-submenu-arrow-icon`]:{marginInlineEnd:"0 !important",color:Ie.colorTextDescription,fontSize:se,fontStyle:"normal"}}}),[`${et}-item-group-list`]:{margin:`0 ${(0,it.unit)(Ie.marginXS)}`,padding:0,listStyle:"none"},[`${et}-submenu-title`]:{paddingInlineEnd:Ie.calc(ne).add(Ie.fontSizeSM).equal()},[`${et}-submenu-vertical`]:{position:"relative"},[`${et}-submenu${et}-submenu-disabled ${Ue}-menu-submenu-title`]:{[`&, ${Ue}-menu-submenu-arrow-icon`]:{color:oe,backgroundColor:he,cursor:"not-allowed"}},[`${et}-submenu-selected ${Ue}-menu-submenu-title`]:{color:Ie.colorPrimary}})})},[(0,Ot.oN)(Ie,"slide-up"),(0,Ot.oN)(Ie,"slide-down"),(0,nt.Fm)(Ie,"move-up"),(0,nt.Fm)(Ie,"move-down"),(0,tt._y)(Ie,"zoom-big")]]},He=Ie=>Object.assign(Object.assign({zIndexPopup:Ie.zIndexPopupBase+50,paddingBlock:(Ie.controlHeight-Ie.fontSize*Ie.lineHeight)/2},(0,ht.wZ)({contentRadius:Ie.borderRadiusLG,limitVerticalRadius:!0})),(0,$e.w)(Ie));var Pt=(0,at.I$)("Dropdown",Ie=>{const{marginXXS:Ue,sizePopupArrow:et,paddingXXS:cn,componentCls:kt}=Ie,Yt=(0,lt.mergeToken)(Ie,{menuCls:`${kt}-menu`,dropdownArrowDistance:Ie.calc(et).div(2).add(Ue).equal(),dropdownEdgeChildPadding:cn});return[De(Yt),At(Yt)]},He,{resetStyle:!1});const ge=null,ce=Ie=>{var Ue;const{menu:et,arrow:cn,prefixCls:kt,children:Yt,trigger:ze,disabled:zt,dropdownRender:ut,getPopupContainer:ae,overlayClassName:te,rootClassName:ee,overlayStyle:oe,open:se,onOpenChange:ne,visible:he,onVisibleChange:xe,mouseEnterDelay:ot=.15,mouseLeaveDelay:Ee=.1,autoAdjustOverflow:Fe=!0,placement:qe="",overlay:bt,transitionName:ct}=Ie,{getPopupContainer:Kt,getPrefixCls:Wt,direction:Nt,dropdown:rn}=z.useContext(dt.E_),qt=(0,Ge.ln)("Dropdown"),on=z.useMemo(()=>{const Ut=Wt();return ct!==void 0?ct:qe.includes("top")?`${Ut}-slide-down`:`${Ut}-slide-up`},[Wt,qe,ct]),ft=z.useMemo(()=>qe?qe.includes("Center")?qe.slice(0,qe.indexOf("Center")):qe:Nt==="rtl"?"bottomRight":"bottomLeft",[qe,Nt]),Gt=Wt("dropdown",kt),Tt=(0,It.Z)(Gt),[en,yn,Rn]=Pt(Gt,Tt),[,On]=(0,st.ZP)(),Pe=z.Children.only(Se(Yt)?z.createElement("span",null,Yt):Yt),rt=(0,Le.Tm)(Pe,{className:ye()(`${Gt}-trigger`,{[`${Gt}-rtl`]:Nt==="rtl"},Pe.props.className),disabled:(Ue=Pe.props.disabled)!==null&&Ue!==void 0?Ue:zt}),St=zt?[]:ze,_t=!!(St!=null&&St.includes("contextMenu")),[bn,In]=(0,Re.Z)(!1,{value:se!=null?se:he}),rr=(0,Me.Z)(Ut=>{ne==null||ne(Ut,{source:"trigger"}),xe==null||xe(Ut),In(Ut)}),Xn=ye()(te,ee,yn,Rn,Tt,rn==null?void 0:rn.className,{[`${Gt}-rtl`]:Nt==="rtl"}),Cn=(0,yt.Z)({arrowPointAtCenter:typeof cn=="object"&&cn.pointAtCenter,autoAdjustOverflow:Fe,offset:On.marginXXS,arrowWidth:cn?On.sizePopupArrow:0,borderRadius:On.borderRadius}),Fn=z.useCallback(()=>{et!=null&&et.selectable&&(et!=null&&et.multiple)||(ne==null||ne(!1,{source:"menu"}),In(!1))},[et==null?void 0:et.selectable,et==null?void 0:et.multiple]),xt=()=>{let Ut;return et!=null&&et.items?Ut=z.createElement(Bt.default,Object.assign({},et)):typeof bt=="function"?Ut=bt():Ut=bt,ut&&(Ut=ut(Ut)),Ut=z.Children.only(typeof Ut=="string"?z.createElement("span",null,Ut):Ut),z.createElement(mt.J,{prefixCls:`${Gt}-menu`,rootClassName:ye()(Rn,Tt),expandIcon:z.createElement("span",{className:`${Gt}-menu-submenu-arrow`},Nt==="rtl"?z.createElement(Ke.Z,{className:`${Gt}-menu-submenu-arrow-icon`}):z.createElement(ve.Z,{className:`${Gt}-menu-submenu-arrow-icon`})),mode:"vertical",selectable:!1,onClick:Fn,validator:En=>{let{mode:mn}=En}},Ut)},[$t,vt]=(0,fe.Cn)("Dropdown",oe==null?void 0:oe.zIndex);let Vt=z.createElement(be.Z,Object.assign({alignPoint:_t},(0,Oe.Z)(Ie,["rootClassName"]),{mouseEnterDelay:ot,mouseLeaveDelay:Ee,visible:bn,builtinPlacements:Cn,arrow:!!cn,overlayClassName:Xn,prefixCls:Gt,getPopupContainer:ae||Kt,transitionName:on,trigger:St,overlay:xt,placement:ft,onVisibleChange:rr,overlayStyle:Object.assign(Object.assign(Object.assign({},rn==null?void 0:rn.style),oe),{zIndex:$t})}),rt);return $t&&(Vt=z.createElement(Ne.Z.Provider,{value:vt},Vt)),en(Vt)},Je=(0,Xe.Z)(ce,"align",void 0,"dropdown",Ie=>Ie),jt=Ie=>z.createElement(Je,Object.assign({},Ie),z.createElement("span",null));ce._InternalPanelDoNotUseOrYouWillBeFired=jt;var wt=ce},75727:function(ln,Ft,ie){"use strict";ie.d(Ft,{Z:function(){return Xe}});var z=ie(19563),Ke=ie(59301),ve=ie(18785),Ae=ie(92310),ye=ie.n(Ae),be=ie(7939),Me=ie(48755),Re=ie(44104),Oe=ie(70045),fe=function(Le,Ge){var Ne={};for(var dt in Le)Object.prototype.hasOwnProperty.call(Le,dt)&&Ge.indexOf(dt)<0&&(Ne[dt]=Le[dt]);if(Le!=null&&typeof Object.getOwnPropertySymbols=="function")for(var It=0,dt=Object.getOwnPropertySymbols(Le);It<dt.length;It++)Ge.indexOf(dt[It])<0&&Object.prototype.propertyIsEnumerable.call(Le,dt[It])&&(Ne[dt[It]]=Le[dt[It]]);return Ne};const We=Le=>{const{getPopupContainer:Ge,getPrefixCls:Ne,direction:dt}=Ke.useContext(Me.E_),{prefixCls:It,type:Bt="default",danger:mt,disabled:st,loading:it,onClick:je,htmlType:Ot,children:nt,className:tt,menu:ht,arrow:$e,autoFocus:at,overlay:lt,trigger:me,align:At,open:De,onOpenChange:He,placement:Pt,getPopupContainer:ge,href:ce,icon:Je=Ke.createElement(ve.Z,null),title:jt,buttonsRender:wt=ot=>ot,mouseEnterDelay:Ie,mouseLeaveDelay:Ue,overlayClassName:et,overlayStyle:cn,destroyPopupOnHide:kt,dropdownRender:Yt}=Le,ze=fe(Le,["prefixCls","type","danger","disabled","loading","onClick","htmlType","children","className","menu","arrow","autoFocus","overlay","trigger","align","open","onOpenChange","placement","getPopupContainer","href","icon","title","buttonsRender","mouseEnterDelay","mouseLeaveDelay","overlayClassName","overlayStyle","destroyPopupOnHide","dropdownRender"]),zt=Ne("dropdown",It),ut=`${zt}-button`,ae={menu:ht,arrow:$e,autoFocus:at,align:At,disabled:st,trigger:st?[]:me,onOpenChange:He,getPopupContainer:ge||Ge,mouseEnterDelay:Ie,mouseLeaveDelay:Ue,overlayClassName:et,overlayStyle:cn,destroyPopupOnHide:kt,dropdownRender:Yt},{compactSize:te,compactItemClassnames:ee}=(0,Oe.ri)(zt,dt),oe=ye()(ut,ee,tt);"overlay"in Le&&(ae.overlay=lt),"open"in Le&&(ae.open=De),"placement"in Le?ae.placement=Pt:ae.placement=dt==="rtl"?"bottomLeft":"bottomRight";const se=Ke.createElement(be.ZP,{type:Bt,danger:mt,disabled:st,loading:it,onClick:je,htmlType:Ot,href:ce,title:jt},nt),ne=Ke.createElement(be.ZP,{type:Bt,danger:mt,icon:Je}),[he,xe]=wt([se,ne]);return Ke.createElement(Re.Z.Compact,Object.assign({className:oe,size:te,block:!0},ze),he,Ke.createElement(z.Z,Object.assign({},ae),xe))};We.__ANT_BUTTON=!0;var Se=We;const yt=z.Z;yt.Button=Se;var Xe=yt},584:function(ln,Ft,ie){"use strict";ie.d(Ft,{Z:function(){return Bt}});var z=ie(59301),Ke=ie(92310),ve=ie.n(Ke),Ae=ie(9017),ye=ie(17835),be=ie(57700),Re=()=>{const[,mt]=(0,be.ZP)(),[st]=(0,Ae.Z)("Empty"),je=new ye.FastColor(mt.colorBgBase).toHsl().l<.5?{opacity:.65}:{};return z.createElement("svg",{style:je,width:"184",height:"152",viewBox:"0 0 184 152",xmlns:"http://www.w3.org/2000/svg"},z.createElement("title",null,(st==null?void 0:st.description)||"Empty"),z.createElement("g",{fill:"none",fillRule:"evenodd"},z.createElement("g",{transform:"translate(24 31.67)"},z.createElement("ellipse",{fillOpacity:".8",fill:"#F5F5F7",cx:"67.797",cy:"106.89",rx:"67.797",ry:"12.668"}),z.createElement("path",{d:"M122.034 69.674L98.109 40.229c-1.148-1.386-2.826-2.225-4.593-2.225h-51.44c-1.766 0-3.444.839-4.592 2.225L13.56 69.674v15.383h108.475V69.674z",fill:"#AEB8C2"}),z.createElement("path",{d:"M101.537 86.214L80.63 61.102c-1.001-1.207-2.507-1.867-4.048-1.867H31.724c-1.54 0-3.047.66-4.048 1.867L6.769 86.214v13.792h94.768V86.214z",fill:"url(#linearGradient-1)",transform:"translate(13.56)"}),z.createElement("path",{d:"M33.83 0h67.933a4 4 0 0 1 4 4v93.344a4 4 0 0 1-4 4H33.83a4 4 0 0 1-4-4V4a4 4 0 0 1 4-4z",fill:"#F5F5F7"}),z.createElement("path",{d:"M42.678 9.953h50.237a2 2 0 0 1 2 2V36.91a2 2 0 0 1-2 2H42.678a2 2 0 0 1-2-2V11.953a2 2 0 0 1 2-2zM42.94 49.767h49.713a2.262 2.262 0 1 1 0 4.524H42.94a2.262 2.262 0 0 1 0-4.524zM42.94 61.53h49.713a2.262 2.262 0 1 1 0 4.525H42.94a2.262 2.262 0 0 1 0-4.525zM121.813 105.032c-.775 3.071-3.497 5.36-6.735 5.36H20.515c-3.238 0-5.96-2.29-6.734-5.36a7.309 7.309 0 0 1-.222-1.79V69.675h26.318c2.907 0 5.25 2.448 5.25 5.42v.04c0 2.971 2.37 5.37 5.277 5.37h34.785c2.907 0 5.277-2.421 5.277-5.393V75.1c0-2.972 2.343-5.426 5.25-5.426h26.318v33.569c0 .617-.077 1.216-.221 1.789z",fill:"#DCE0E6"})),z.createElement("path",{d:"M149.121 33.292l-6.83 2.65a1 1 0 0 1-1.317-1.23l1.937-6.207c-2.589-2.944-4.109-6.534-4.109-10.408C138.802 8.102 148.92 0 161.402 0 173.881 0 184 8.102 184 18.097c0 9.995-10.118 18.097-22.599 18.097-4.528 0-8.744-1.066-12.28-2.902z",fill:"#DCE0E6"}),z.createElement("g",{transform:"translate(149.65 15.383)",fill:"#FFF"},z.createElement("ellipse",{cx:"20.654",cy:"3.167",rx:"2.849",ry:"2.815"}),z.createElement("path",{d:"M5.698 5.63H0L2.898.704zM9.259.704h4.985V5.63H9.259z"}))))},fe=()=>{const[,mt]=(0,be.ZP)(),[st]=(0,Ae.Z)("Empty"),{colorFill:it,colorFillTertiary:je,colorFillQuaternary:Ot,colorBgContainer:nt}=mt,{borderColor:tt,shadowColor:ht,contentColor:$e}=(0,z.useMemo)(()=>({borderColor:new ye.FastColor(it).onBackground(nt).toHexString(),shadowColor:new ye.FastColor(je).onBackground(nt).toHexString(),contentColor:new ye.FastColor(Ot).onBackground(nt).toHexString()}),[it,je,Ot,nt]);return z.createElement("svg",{width:"64",height:"41",viewBox:"0 0 64 41",xmlns:"http://www.w3.org/2000/svg"},z.createElement("title",null,(st==null?void 0:st.description)||"Empty"),z.createElement("g",{transform:"translate(0 1)",fill:"none",fillRule:"evenodd"},z.createElement("ellipse",{fill:ht,cx:"32",cy:"33",rx:"32",ry:"7"}),z.createElement("g",{fillRule:"nonzero",stroke:tt},z.createElement("path",{d:"M55 12.76L44.854 1.258C44.367.474 43.656 0 42.907 0H21.093c-.749 0-1.46.474-1.947 1.257L9 12.761V22h46v-9.24z"}),z.createElement("path",{d:"M41.613 15.931c0-1.605.994-2.93 2.227-2.931H55v18.137C55 33.26 53.68 35 52.05 35h-40.1C10.32 35 9 33.259 9 31.137V13h11.16c1.233 0 2.227 1.323 2.227 2.928v.022c0 1.605 1.005 2.901 2.237 2.901h14.752c1.232 0 2.237-1.308 2.237-2.913v-.007z",fill:$e}))))},We=ie(16931),Se=ie(51636);const yt=mt=>{const{componentCls:st,margin:it,marginXS:je,marginXL:Ot,fontSize:nt,lineHeight:tt}=mt;return{[st]:{marginInline:je,fontSize:nt,lineHeight:tt,textAlign:"center",[`${st}-image`]:{height:mt.emptyImgHeight,marginBottom:je,opacity:mt.opacityImage,img:{height:"100%"},svg:{maxWidth:"100%",height:"100%",margin:"auto"}},[`${st}-description`]:{color:mt.colorTextDescription},[`${st}-footer`]:{marginTop:it},"&-normal":{marginBlock:Ot,color:mt.colorTextDescription,[`${st}-description`]:{color:mt.colorTextDescription},[`${st}-image`]:{height:mt.emptyImgHeightMD}},"&-small":{marginBlock:je,color:mt.colorTextDescription,[`${st}-image`]:{height:mt.emptyImgHeightSM}}}}};var Xe=(0,We.I$)("Empty",mt=>{const{componentCls:st,controlHeightLG:it,calc:je}=mt,Ot=(0,Se.mergeToken)(mt,{emptyImgCls:`${st}-img`,emptyImgHeight:je(it).mul(2.5).equal(),emptyImgHeightMD:it,emptyImgHeightSM:je(it).mul(.875).equal()});return[yt(Ot)]}),Le=ie(48755),Ge=function(mt,st){var it={};for(var je in mt)Object.prototype.hasOwnProperty.call(mt,je)&&st.indexOf(je)<0&&(it[je]=mt[je]);if(mt!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Ot=0,je=Object.getOwnPropertySymbols(mt);Ot<je.length;Ot++)st.indexOf(je[Ot])<0&&Object.prototype.propertyIsEnumerable.call(mt,je[Ot])&&(it[je[Ot]]=mt[je[Ot]]);return it};const Ne=z.createElement(Re,null),dt=z.createElement(fe,null),It=mt=>{const{className:st,rootClassName:it,prefixCls:je,image:Ot=Ne,description:nt,children:tt,imageStyle:ht,style:$e,classNames:at,styles:lt}=mt,me=Ge(mt,["className","rootClassName","prefixCls","image","description","children","imageStyle","style","classNames","styles"]),{getPrefixCls:At,direction:De,className:He,style:Pt,classNames:ge,styles:ce}=(0,Le.dj)("empty"),Je=At("empty",je),[jt,wt,Ie]=Xe(Je),[Ue]=(0,Ae.Z)("Empty"),et=typeof nt!="undefined"?nt:Ue==null?void 0:Ue.description,cn=typeof et=="string"?et:"empty";let kt=null;return typeof Ot=="string"?kt=z.createElement("img",{alt:cn,src:Ot}):kt=Ot,jt(z.createElement("div",Object.assign({className:ve()(wt,Ie,Je,He,{[`${Je}-normal`]:Ot===dt,[`${Je}-rtl`]:De==="rtl"},st,it,ge.root,at==null?void 0:at.root),style:Object.assign(Object.assign(Object.assign(Object.assign({},ce.root),Pt),lt==null?void 0:lt.root),$e)},me),z.createElement("div",{className:ve()(`${Je}-image`,ge.image,at==null?void 0:at.image),style:Object.assign(Object.assign(Object.assign({},ht),ce.image),lt==null?void 0:lt.image)},kt),et&&z.createElement("div",{className:ve()(`${Je}-description`,ge.description,at==null?void 0:at.description),style:Object.assign(Object.assign({},ce.description),lt==null?void 0:lt.description)},et),tt&&z.createElement("div",{className:ve()(`${Je}-footer`,ge.footer,at==null?void 0:at.footer),style:Object.assign(Object.assign({},ce.footer),lt==null?void 0:lt.footer)},tt)))};It.PRESENTED_IMAGE_DEFAULT=Ne,It.PRESENTED_IMAGE_SIMPLE=dt;var Bt=It},28284:function(ln,Ft,ie){"use strict";ie.d(Ft,{default:function(){return _e}});var z=ie(56553),Ke=ie(94480),ve=ie(59301),Ae=ie(92310),ye=ie.n(Ae),be=ie(77900),Me=ie(86641),Re=ie(83397);function Oe(Ce){const[Be,we]=ve.useState(Ce);return ve.useEffect(()=>{const Te=setTimeout(()=>{we(Ce)},Ce.length?0:10);return()=>{clearTimeout(Te)}},[Ce]),Be}var fe=ie(36237),We=ie(63356),Se=ie(34925),yt=ie(34961),Xe=ie(51636),Le=ie(16931),Ne=Ce=>{const{componentCls:Be}=Ce,we=`${Be}-show-help`,Te=`${Be}-show-help-item`;return{[we]:{transition:`opacity ${Ce.motionDurationFast} ${Ce.motionEaseInOut}`,"&-appear, &-enter":{opacity:0,"&-active":{opacity:1}},"&-leave":{opacity:1,"&-active":{opacity:0}},[Te]:{overflow:"hidden",transition:`height ${Ce.motionDurationFast} ${Ce.motionEaseInOut},
|
|
|
opacity ${Ce.motionDurationFast} ${Ce.motionEaseInOut},
|
|
|
transform ${Ce.motionDurationFast} ${Ce.motionEaseInOut} !important`,[`&${Te}-appear, &${Te}-enter`]:{transform:"translateY(-5px)",opacity:0,"&-active":{transform:"translateY(0)",opacity:1}},[`&${Te}-leave-active`]:{transform:"translateY(-5px)"}}}}};const dt=Ce=>({legend:{display:"block",width:"100%",marginBottom:Ce.marginLG,padding:0,color:Ce.colorTextDescription,fontSize:Ce.fontSizeLG,lineHeight:"inherit",border:0,borderBottom:`${(0,fe.unit)(Ce.lineWidth)} ${Ce.lineType} ${Ce.colorBorder}`},'input[type="search"]':{boxSizing:"border-box"},'input[type="radio"], input[type="checkbox"]':{lineHeight:"normal"},'input[type="file"]':{display:"block"},'input[type="range"]':{display:"block",width:"100%"},"select[multiple], select[size]":{height:"auto"},"input[type='file']:focus,\n input[type='radio']:focus,\n input[type='checkbox']:focus":{outline:0,boxShadow:`0 0 0 ${(0,fe.unit)(Ce.controlOutlineWidth)} ${Ce.controlOutline}`},output:{display:"block",paddingTop:15,color:Ce.colorText,fontSize:Ce.fontSize,lineHeight:Ce.lineHeight}}),It=(Ce,Be)=>{const{formItemCls:we}=Ce;return{[we]:{[`${we}-label > label`]:{height:Be},[`${we}-control-input`]:{minHeight:Be}}}},Bt=Ce=>{const{componentCls:Be}=Ce;return{[Ce.componentCls]:Object.assign(Object.assign(Object.assign({},(0,We.Wf)(Ce)),dt(Ce)),{[`${Be}-text`]:{display:"inline-block",paddingInlineEnd:Ce.paddingSM},"&-small":Object.assign({},It(Ce,Ce.controlHeightSM)),"&-large":Object.assign({},It(Ce,Ce.controlHeightLG))})}},mt=Ce=>{const{formItemCls:Be,iconCls:we,rootPrefixCls:Te,antCls:Qe,labelRequiredMarkColor:nn,labelColor:sn,labelFontSize:Xt,labelHeight:Ht,labelColonMarginInlineStart:Ct,labelColonMarginInlineEnd:pt,itemMarginBottom:un}=Ce;return{[Be]:Object.assign(Object.assign({},(0,We.Wf)(Ce)),{marginBottom:un,verticalAlign:"top","&-with-help":{transition:"none"},[`&-hidden,
|
|
|
&-hidden${Qe}-row`]:{display:"none"},"&-has-warning":{[`${Be}-split`]:{color:Ce.colorError}},"&-has-error":{[`${Be}-split`]:{color:Ce.colorWarning}},[`${Be}-label`]:{flexGrow:0,overflow:"hidden",whiteSpace:"nowrap",textAlign:"end",verticalAlign:"middle","&-left":{textAlign:"start"},"&-wrap":{overflow:"unset",lineHeight:Ce.lineHeight,whiteSpace:"unset"},"> label":{position:"relative",display:"inline-flex",alignItems:"center",maxWidth:"100%",height:Ht,color:sn,fontSize:Xt,[`> ${we}`]:{fontSize:Ce.fontSize,verticalAlign:"top"},[`&${Be}-required`]:{"&::before":{display:"inline-block",marginInlineEnd:Ce.marginXXS,color:nn,fontSize:Ce.fontSize,fontFamily:"SimSun, sans-serif",lineHeight:1,content:'"*"'},[`&${Be}-required-mark-hidden, &${Be}-required-mark-optional`]:{"&::before":{display:"none"}}},[`${Be}-optional`]:{display:"inline-block",marginInlineStart:Ce.marginXXS,color:Ce.colorTextDescription,[`&${Be}-required-mark-hidden`]:{display:"none"}},[`${Be}-tooltip`]:{color:Ce.colorTextDescription,cursor:"help",writingMode:"horizontal-tb",marginInlineStart:Ce.marginXXS},"&::after":{content:'":"',position:"relative",marginBlock:0,marginInlineStart:Ct,marginInlineEnd:pt},[`&${Be}-no-colon::after`]:{content:'"\\a0"'}}},[`${Be}-control`]:{"--ant-display":"flex",flexDirection:"column",flexGrow:1,[`&:first-child:not([class^="'${Te}-col-'"]):not([class*="' ${Te}-col-'"])`]:{width:"100%"},"&-input":{position:"relative",display:"flex",alignItems:"center",minHeight:Ce.controlHeight,"&-content":{flex:"auto",maxWidth:"100%"}}},[Be]:{"&-additional":{display:"flex",flexDirection:"column"},"&-explain, &-extra":{clear:"both",color:Ce.colorTextDescription,fontSize:Ce.fontSize,lineHeight:Ce.lineHeight},"&-explain-connected":{width:"100%"},"&-extra":{minHeight:Ce.controlHeightSM,transition:`color ${Ce.motionDurationMid} ${Ce.motionEaseOut}`},"&-explain":{"&-error":{color:Ce.colorError},"&-warning":{color:Ce.colorWarning}}},[`&-with-help ${Be}-explain`]:{height:"auto",opacity:1},[`${Be}-feedback-icon`]:{fontSize:Ce.fontSize,textAlign:"center",visibility:"visible",animationName:Se.kr,animationDuration:Ce.motionDurationMid,animationTimingFunction:Ce.motionEaseOutBack,pointerEvents:"none","&-success":{color:Ce.colorSuccess},"&-error":{color:Ce.colorError},"&-warning":{color:Ce.colorWarning},"&-validating":{color:Ce.colorPrimary}}})}},st=(Ce,Be)=>{const{formItemCls:we}=Ce;return{[`${Be}-horizontal`]:{[`${we}-label`]:{flexGrow:0},[`${we}-control`]:{flex:"1 1 0",minWidth:0},[`${we}-label[class$='-24'], ${we}-label[class*='-24 ']`]:{[`& + ${we}-control`]:{minWidth:"unset"}}}}},it=Ce=>{const{componentCls:Be,formItemCls:we,inlineItemMarginBottom:Te}=Ce;return{[`${Be}-inline`]:{display:"flex",flexWrap:"wrap",[we]:{flex:"none",marginInlineEnd:Ce.margin,marginBottom:Te,"&-row":{flexWrap:"nowrap"},[`> ${we}-label,
|
|
|
> ${we}-control`]:{display:"inline-block",verticalAlign:"top"},[`> ${we}-label`]:{flex:"none"},[`${Be}-text`]:{display:"inline-block"},[`${we}-has-feedback`]:{display:"inline-block"}}}}},je=Ce=>({padding:Ce.verticalLabelPadding,margin:Ce.verticalLabelMargin,whiteSpace:"initial",textAlign:"start","> label":{margin:0,"&::after":{visibility:"hidden"}}}),Ot=Ce=>{const{componentCls:Be,formItemCls:we,rootPrefixCls:Te}=Ce;return{[`${we} ${we}-label`]:je(Ce),[`${Be}:not(${Be}-inline)`]:{[we]:{flexWrap:"wrap",[`${we}-label, ${we}-control`]:{[`&:not([class*=" ${Te}-col-xs"])`]:{flex:"0 0 100%",maxWidth:"100%"}}}}}},nt=Ce=>{const{componentCls:Be,formItemCls:we,antCls:Te}=Ce;return{[`${Be}-vertical`]:{[`${we}:not(${we}-horizontal)`]:{[`${we}-row`]:{flexDirection:"column"},[`${we}-label > label`]:{height:"auto"},[`${we}-control`]:{width:"100%"},[`${we}-label,
|
|
|
${Te}-col-24${we}-label,
|
|
|
${Te}-col-xl-24${we}-label`]:je(Ce)}},[`@media (max-width: ${(0,fe.unit)(Ce.screenXSMax)})`]:[Ot(Ce),{[Be]:{[`${we}:not(${we}-horizontal)`]:{[`${Te}-col-xs-24${we}-label`]:je(Ce)}}}],[`@media (max-width: ${(0,fe.unit)(Ce.screenSMMax)})`]:{[Be]:{[`${we}:not(${we}-horizontal)`]:{[`${Te}-col-sm-24${we}-label`]:je(Ce)}}},[`@media (max-width: ${(0,fe.unit)(Ce.screenMDMax)})`]:{[Be]:{[`${we}:not(${we}-horizontal)`]:{[`${Te}-col-md-24${we}-label`]:je(Ce)}}},[`@media (max-width: ${(0,fe.unit)(Ce.screenLGMax)})`]:{[Be]:{[`${we}:not(${we}-horizontal)`]:{[`${Te}-col-lg-24${we}-label`]:je(Ce)}}}}},tt=Ce=>{const{formItemCls:Be,antCls:we}=Ce;return{[`${Be}-vertical`]:{[`${Be}-row`]:{flexDirection:"column"},[`${Be}-label > label`]:{height:"auto"},[`${Be}-control`]:{width:"100%"}},[`${Be}-vertical ${Be}-label,
|
|
|
${we}-col-24${Be}-label,
|
|
|
${we}-col-xl-24${Be}-label`]:je(Ce),[`@media (max-width: ${(0,fe.unit)(Ce.screenXSMax)})`]:[Ot(Ce),{[Be]:{[`${we}-col-xs-24${Be}-label`]:je(Ce)}}],[`@media (max-width: ${(0,fe.unit)(Ce.screenSMMax)})`]:{[Be]:{[`${we}-col-sm-24${Be}-label`]:je(Ce)}},[`@media (max-width: ${(0,fe.unit)(Ce.screenMDMax)})`]:{[Be]:{[`${we}-col-md-24${Be}-label`]:je(Ce)}},[`@media (max-width: ${(0,fe.unit)(Ce.screenLGMax)})`]:{[Be]:{[`${we}-col-lg-24${Be}-label`]:je(Ce)}}}},ht=Ce=>({labelRequiredMarkColor:Ce.colorError,labelColor:Ce.colorTextHeading,labelFontSize:Ce.fontSize,labelHeight:Ce.controlHeight,labelColonMarginInlineStart:Ce.marginXXS/2,labelColonMarginInlineEnd:Ce.marginXS,itemMarginBottom:Ce.marginLG,verticalLabelPadding:`0 0 ${Ce.paddingXS}px`,verticalLabelMargin:0,inlineItemMarginBottom:0}),$e=(Ce,Be)=>(0,Xe.mergeToken)(Ce,{formItemCls:`${Ce.componentCls}-item`,rootPrefixCls:Be});var at=(0,Le.I$)("Form",(Ce,Be)=>{let{rootPrefixCls:we}=Be;const Te=$e(Ce,we);return[Bt(Te),mt(Te),Ne(Te),st(Te,Te.componentCls),st(Te,Te.formItemCls),it(Te),nt(Te),tt(Te),(0,yt.Z)(Te),Se.kr]},ht,{order:-1e3});const lt=[];function me(Ce,Be,we){let Te=arguments.length>3&&arguments[3]!==void 0?arguments[3]:0;return{key:typeof Ce=="string"?Ce:`${Be}-${Te}`,error:Ce,errorStatus:we}}var De=Ce=>{let{help:Be,helpStatus:we,errors:Te=lt,warnings:Qe=lt,className:nn,fieldId:sn,onVisibleChanged:Xt}=Ce;const{prefixCls:Ht}=ve.useContext(z.Rk),Ct=`${Ht}-item-explain`,pt=(0,Re.Z)(Ht),[un,$n,Dn]=at(Ht,pt),kn=ve.useMemo(()=>(0,Me.Z)(Ht),[Ht]),pr=Oe(Te),gt=Oe(Qe),Ve=ve.useMemo(()=>Be!=null?[me(Be,"help",we)]:[].concat((0,Ke.Z)(pr.map((Zt,hn)=>me(Zt,"error","error",hn))),(0,Ke.Z)(gt.map((Zt,hn)=>me(Zt,"warning","warning",hn)))),[Be,we,pr,gt]),Et=ve.useMemo(()=>{const Zt={};return Ve.forEach(hn=>{let{key:Hn}=hn;Zt[Hn]=(Zt[Hn]||0)+1}),Ve.map((hn,Hn)=>Object.assign(Object.assign({},hn),{key:Zt[hn.key]>1?`${hn.key}-fallback-${Hn}`:hn.key}))},[Ve]),Rt={};return sn&&(Rt.id=`${sn}_help`),un(ve.createElement(be.default,{motionDeadline:kn.motionDeadline,motionName:`${Ht}-show-help`,visible:!!Et.length,onVisibleChanged:Xt},Zt=>{const{className:hn,style:Hn}=Zt;return ve.createElement("div",Object.assign({},Rt,{className:ye()(Ct,hn,Dn,pt,nn,$n),style:Hn}),ve.createElement(be.CSSMotionList,Object.assign({keys:Et},(0,Me.Z)(Ht),{motionName:`${Ht}-show-help-item`,component:!1}),Sn=>{const{key:Tn,error:An,errorStatus:jn,className:Pn,style:lr}=Sn;return ve.createElement("div",{key:Tn,className:ye()(Pn,{[`${Ct}-${jn}`]:jn}),style:lr},An)}))}))},He=ie(22001),Pt=ie(48755),ge=ie(2171),ce=ie(31756),Je=ie(23069),jt=ie(76846),wt=ie(16722);const Ie=["parentNode"],Ue="form_item";function et(Ce){return Ce===void 0||Ce===!1?[]:Array.isArray(Ce)?Ce:[Ce]}function cn(Ce,Be){if(!Ce.length)return;const we=Ce.join("_");return Be?`${Be}_${we}`:Ie.includes(we)?`${Ue}_${we}`:we}function kt(Ce,Be,we,Te,Qe,nn){let sn=Te;return nn!==void 0?sn=nn:we.validating?sn="validating":Ce.length?sn="error":Be.length?sn="warning":(we.touched||Qe&&we.validated)&&(sn="success"),sn}var Yt=function(Ce,Be){var we={};for(var Te in Ce)Object.prototype.hasOwnProperty.call(Ce,Te)&&Be.indexOf(Te)<0&&(we[Te]=Ce[Te]);if(Ce!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Qe=0,Te=Object.getOwnPropertySymbols(Ce);Qe<Te.length;Qe++)Be.indexOf(Te[Qe])<0&&Object.prototype.propertyIsEnumerable.call(Ce,Te[Qe])&&(we[Te[Qe]]=Ce[Te[Qe]]);return we};function ze(Ce){return et(Ce).join("_")}function zt(Ce,Be){const we=Be.getFieldInstance(Ce),Te=(0,jt.bn)(we);if(Te)return Te;const Qe=cn(et(Ce),Be.__INTERNAL__.name);if(Qe)return document.getElementById(Qe)}function ut(Ce){const[Be]=(0,He.useForm)(),we=ve.useRef({}),Te=ve.useMemo(()=>Ce!=null?Ce:Object.assign(Object.assign({},Be),{__INTERNAL__:{itemRef:Qe=>nn=>{const sn=ze(Qe);nn?we.current[sn]=nn:delete we.current[sn]}},scrollToField:function(Qe){let nn=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};const{focus:sn}=nn,Xt=Yt(nn,["focus"]),Ht=zt(Qe,Te);Ht&&((0,wt.Z)(Ht,Object.assign({scrollMode:"if-needed",block:"nearest"},Xt)),sn&&Te.focusField(Qe))},focusField:Qe=>{var nn,sn;const Xt=Te.getFieldInstance(Qe);typeof(Xt==null?void 0:Xt.focus)=="function"?Xt.focus():(sn=(nn=zt(Qe,Te))===null||nn===void 0?void 0:nn.focus)===null||sn===void 0||sn.call(nn)},getFieldInstance:Qe=>{const nn=ze(Qe);return we.current[nn]}}),[Ce,Be]);return[Te]}var ae=ie(98350),te=function(Ce,Be){var we={};for(var Te in Ce)Object.prototype.hasOwnProperty.call(Ce,Te)&&Be.indexOf(Te)<0&&(we[Te]=Ce[Te]);if(Ce!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Qe=0,Te=Object.getOwnPropertySymbols(Ce);Qe<Te.length;Qe++)Be.indexOf(Te[Qe])<0&&Object.prototype.propertyIsEnumerable.call(Ce,Te[Qe])&&(we[Te[Qe]]=Ce[Te[Qe]]);return we};const ee=(Ce,Be)=>{const we=ve.useContext(ge.Z),{getPrefixCls:Te,direction:Qe,requiredMark:nn,colon:sn,scrollToFirstError:Xt,className:Ht,style:Ct}=(0,Pt.dj)("form"),{prefixCls:pt,className:un,rootClassName:$n,size:Dn,disabled:kn=we,form:pr,colon:gt,labelAlign:Ve,labelWrap:Et,labelCol:Rt,wrapperCol:Zt,hideRequiredMark:hn,layout:Hn="horizontal",scrollToFirstError:Sn,requiredMark:Tn,onFinishFailed:An,name:jn,style:Pn,feedbackIcons:lr,variant:Jn}=Ce,Kn=te(Ce,["prefixCls","className","rootClassName","size","disabled","form","colon","labelAlign","labelWrap","labelCol","wrapperCol","hideRequiredMark","layout","scrollToFirstError","requiredMark","onFinishFailed","name","style","feedbackIcons","variant"]),sr=(0,ce.Z)(Dn),mr=ve.useContext(ae.Z),Qn=ve.useMemo(()=>Tn!==void 0?Tn:hn?!1:nn!==void 0?nn:!0,[hn,Tn,nn]),cr=gt!=null?gt:sn,Gn=Te("form",pt),vr=(0,Re.Z)(Gn),[qn,Sr,ar]=at(Gn,vr),or=ye()(Gn,`${Gn}-${Hn}`,{[`${Gn}-hide-required-mark`]:Qn===!1,[`${Gn}-rtl`]:Qe==="rtl",[`${Gn}-${sr}`]:sr},ar,vr,Sr,Ht,un,$n),[hr]=ut(pr),{__INTERNAL__:xr}=hr;xr.name=jn;const br=ve.useMemo(()=>({name:jn,labelAlign:Ve,labelCol:Rt,labelWrap:Et,wrapperCol:Zt,vertical:Hn==="vertical",colon:cr,requiredMark:Qn,itemRef:xr.itemRef,form:hr,feedbackIcons:lr}),[jn,Ve,Rt,Zt,Hn,cr,Qn,hr,lr]),dr=ve.useRef(null);ve.useImperativeHandle(Be,()=>{var fn;return Object.assign(Object.assign({},hr),{nativeElement:(fn=dr.current)===null||fn===void 0?void 0:fn.nativeElement})});const er=(fn,pn)=>{if(fn){let Jt={block:"nearest"};typeof fn=="object"&&(Jt=Object.assign(Object.assign({},Jt),fn)),hr.scrollToField(pn,Jt)}},tn=fn=>{if(An==null||An(fn),fn.errorFields.length){const pn=fn.errorFields[0].name;if(Sn!==void 0){er(Sn,pn);return}Xt!==void 0&&er(Xt,pn)}};return qn(ve.createElement(z.pg.Provider,{value:Jn},ve.createElement(ge.n,{disabled:kn},ve.createElement(Je.Z.Provider,{value:sr},ve.createElement(z.RV,{validateMessages:mr},ve.createElement(z.q3.Provider,{value:br},ve.createElement(He.default,Object.assign({id:jn},Kn,{name:jn,onFinishFailed:tn,form:hr,ref:dr,style:Object.assign(Object.assign({},Ct),Pn),className:or}))))))))};var se=ve.forwardRef(ee),ne=ie(41799),he=ie(8654),xe=ie(22703),ot=ie(32383),Ee=ie(11592);function Fe(Ce){if(typeof Ce=="function")return Ce;const Be=(0,Ee.Z)(Ce);return Be.length<=1?Be[0]:Be}const qe=()=>{const{status:Ce,errors:Be=[],warnings:we=[]}=ve.useContext(z.aM);return{status:Ce,errors:Be,warnings:we}};qe.Context=z.aM;var bt=qe,ct=ie(16089);function Kt(Ce){const[Be,we]=ve.useState(Ce),Te=ve.useRef(null),Qe=ve.useRef([]),nn=ve.useRef(!1);ve.useEffect(()=>(nn.current=!1,()=>{nn.current=!0,ct.Z.cancel(Te.current),Te.current=null}),[]);function sn(Xt){nn.current||(Te.current===null&&(Qe.current=[],Te.current=(0,ct.Z)(()=>{Te.current=null,we(Ht=>{let Ct=Ht;return Qe.current.forEach(pt=>{Ct=pt(Ct)}),Ct})})),Qe.current.push(Xt))}return[Be,sn]}function Wt(){const{itemRef:Ce}=ve.useContext(z.q3),Be=ve.useRef({});function we(Te,Qe){const nn=Qe&&typeof Qe=="object"&&(0,he.C4)(Qe),sn=Te.join("_");return(Be.current.name!==sn||Be.current.originRef!==nn)&&(Be.current.name=sn,Be.current.originRef=nn,Be.current.ref=(0,he.sQ)(Ce(Te),nn)),Be.current.ref}return we}var Nt=ie(29194),rn=ie(34280),qt=ie(2738),on=ie(65970),ft=ie(70425),Gt=ie(5472);const Tt=Ce=>{const{formItemCls:Be}=Ce;return{"@media screen and (-ms-high-contrast: active), (-ms-high-contrast: none)":{[`${Be}-control`]:{display:"flex"}}}};var en=(0,Le.bk)(["Form","item-item"],(Ce,Be)=>{let{rootPrefixCls:we}=Be;const Te=$e(Ce,we);return[Tt(Te)]}),yn=function(Ce,Be){var we={};for(var Te in Ce)Object.prototype.hasOwnProperty.call(Ce,Te)&&Be.indexOf(Te)<0&&(we[Te]=Ce[Te]);if(Ce!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Qe=0,Te=Object.getOwnPropertySymbols(Ce);Qe<Te.length;Qe++)Be.indexOf(Te[Qe])<0&&Object.prototype.propertyIsEnumerable.call(Ce,Te[Qe])&&(we[Te[Qe]]=Ce[Te[Qe]]);return we};const Rn=24;var Pe=Ce=>{const{prefixCls:Be,status:we,labelCol:Te,wrapperCol:Qe,children:nn,errors:sn,warnings:Xt,_internalItemRender:Ht,extra:Ct,help:pt,fieldId:un,marginBottom:$n,onErrorVisibleChanged:Dn,label:kn}=Ce,pr=`${Be}-item`,gt=ve.useContext(z.q3),Ve=ve.useMemo(()=>{let Kn=Object.assign({},Qe||gt.wrapperCol||{});return kn===null&&!Te&&!Qe&>.labelCol&&[void 0,"xs","sm","md","lg","xl","xxl"].forEach(mr=>{const Qn=mr?[mr]:[],cr=(0,ft.U2)(gt.labelCol,Qn),Gn=typeof cr=="object"?cr:{},vr=(0,ft.U2)(Kn,Qn),qn=typeof vr=="object"?vr:{};"span"in Gn&&!("offset"in qn)&&Gn.span<Rn&&(Kn=(0,ft.t8)(Kn,[].concat(Qn,["offset"]),Gn.span))}),Kn},[Qe,gt]),Et=ye()(`${pr}-control`,Ve.className),Rt=ve.useMemo(()=>{const{labelCol:Kn,wrapperCol:sr}=gt;return yn(gt,["labelCol","wrapperCol"])},[gt]),Zt=ve.useRef(null),[hn,Hn]=ve.useState(0);(0,rn.Z)(()=>{Ct&&Zt.current?Hn(Zt.current.clientHeight):Hn(0)},[Ct]);const Sn=ve.createElement("div",{className:`${pr}-control-input`},ve.createElement("div",{className:`${pr}-control-input-content`},nn)),Tn=ve.useMemo(()=>({prefixCls:Be,status:we}),[Be,we]),An=$n!==null||sn.length||Xt.length?ve.createElement(z.Rk.Provider,{value:Tn},ve.createElement(De,{fieldId:un,errors:sn,warnings:Xt,help:pt,helpStatus:we,className:`${pr}-explain-connected`,onVisibleChanged:Dn})):null,jn={};un&&(jn.id=`${un}_extra`);const Pn=Ct?ve.createElement("div",Object.assign({},jn,{className:`${pr}-extra`,ref:Zt}),Ct):null,lr=An||Pn?ve.createElement("div",{className:`${pr}-additional`,style:$n?{minHeight:$n+hn}:{}},An,Pn):null,Jn=Ht&&Ht.mark==="pro_table_render"&&Ht.render?Ht.render(Ce,{input:Sn,errorList:An,extra:Pn}):ve.createElement(ve.Fragment,null,Sn,lr);return ve.createElement(z.q3.Provider,{value:Rt},ve.createElement(Gt.Z,Object.assign({},Ve,{className:Et}),Jn),ve.createElement(en,{prefixCls:Be}))},rt=ie(61485),St=ie(9017),_t=ie(85981),bn=ie(25399),In=function(Ce,Be){var we={};for(var Te in Ce)Object.prototype.hasOwnProperty.call(Ce,Te)&&Be.indexOf(Te)<0&&(we[Te]=Ce[Te]);if(Ce!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Qe=0,Te=Object.getOwnPropertySymbols(Ce);Qe<Te.length;Qe++)Be.indexOf(Te[Qe])<0&&Object.prototype.propertyIsEnumerable.call(Ce,Te[Qe])&&(we[Te[Qe]]=Ce[Te[Qe]]);return we};function rr(Ce){return Ce?typeof Ce=="object"&&!ve.isValidElement(Ce)?Ce:{title:Ce}:null}var Cn=Ce=>{let{prefixCls:Be,label:we,htmlFor:Te,labelCol:Qe,labelAlign:nn,colon:sn,required:Xt,requiredMark:Ht,tooltip:Ct,vertical:pt}=Ce;var un;const[$n]=(0,St.Z)("Form"),{labelAlign:Dn,labelCol:kn,labelWrap:pr,colon:gt}=ve.useContext(z.q3);if(!we)return null;const Ve=Qe||kn||{},Et=nn||Dn,Rt=`${Be}-item-label`,Zt=ye()(Rt,Et==="left"&&`${Rt}-left`,Ve.className,{[`${Rt}-wrap`]:!!pr});let hn=we;const Hn=sn===!0||gt!==!1&&sn!==!1;Hn&&!pt&&typeof we=="string"&&we.trim()&&(hn=we.replace(/[:|:]\s*$/,""));const Tn=rr(Ct);if(Tn){const{icon:Kn=ve.createElement(rt.Z,null)}=Tn,sr=In(Tn,["icon"]),mr=ve.createElement(bn.Z,Object.assign({},sr),ve.cloneElement(Kn,{className:`${Be}-item-tooltip`,title:"",onClick:Qn=>{Qn.preventDefault()},tabIndex:null}));hn=ve.createElement(ve.Fragment,null,hn,mr)}const An=Ht==="optional",jn=typeof Ht=="function",Pn=Ht===!1;jn?hn=Ht(hn,{required:!!Xt}):An&&!Xt&&(hn=ve.createElement(ve.Fragment,null,hn,ve.createElement("span",{className:`${Be}-item-optional`,title:""},($n==null?void 0:$n.optional)||((un=_t.Z.Form)===null||un===void 0?void 0:un.optional))));let lr;Pn?lr="hidden":(An||jn)&&(lr="optional");const Jn=ye()({[`${Be}-item-required`]:Xt,[`${Be}-item-required-mark-${lr}`]:lr,[`${Be}-item-no-colon`]:!Hn});return ve.createElement(Gt.Z,Object.assign({},Ve,{className:Zt}),ve.createElement("label",{htmlFor:Te,className:Jn,title:typeof we=="string"?we:""},hn))},Fn=ie(29679),xt=ie(19248),$t=ie(96512),vt=ie(58617);const Vt={success:Fn.Z,warning:$t.Z,error:xt.Z,validating:vt.Z};function Ut(Ce){let{children:Be,errors:we,warnings:Te,hasFeedback:Qe,validateStatus:nn,prefixCls:sn,meta:Xt,noStyle:Ht}=Ce;const Ct=`${sn}-item`,{feedbackIcons:pt}=ve.useContext(z.q3),un=kt(we,Te,Xt,null,!!Qe,nn),{isFormItemInput:$n,status:Dn,hasFeedback:kn,feedbackIcon:pr}=ve.useContext(z.aM),gt=ve.useMemo(()=>{var Ve;let Et;if(Qe){const Zt=Qe!==!0&&Qe.icons||pt,hn=un&&((Ve=Zt==null?void 0:Zt({status:un,errors:we,warnings:Te}))===null||Ve===void 0?void 0:Ve[un]),Hn=un&&Vt[un];Et=hn!==!1&&Hn?ve.createElement("span",{className:ye()(`${Ct}-feedback-icon`,`${Ct}-feedback-icon-${un}`)},hn||ve.createElement(Hn,null)):null}const Rt={status:un||"",errors:we,warnings:Te,hasFeedback:!!Qe,feedbackIcon:Et,isFormItemInput:!0};return Ht&&(Rt.status=(un!=null?un:Dn)||"",Rt.isFormItemInput=$n,Rt.hasFeedback=!!(Qe!=null?Qe:kn),Rt.feedbackIcon=Qe!==void 0?Rt.feedbackIcon:pr),Rt},[un,Qe,Ht,$n,Dn]);return ve.createElement(z.aM.Provider,{value:gt},Be)}var En=function(Ce,Be){var we={};for(var Te in Ce)Object.prototype.hasOwnProperty.call(Ce,Te)&&Be.indexOf(Te)<0&&(we[Te]=Ce[Te]);if(Ce!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Qe=0,Te=Object.getOwnPropertySymbols(Ce);Qe<Te.length;Qe++)Be.indexOf(Te[Qe])<0&&Object.prototype.propertyIsEnumerable.call(Ce,Te[Qe])&&(we[Te[Qe]]=Ce[Te[Qe]]);return we};function mn(Ce){const{prefixCls:Be,className:we,rootClassName:Te,style:Qe,help:nn,errors:sn,warnings:Xt,validateStatus:Ht,meta:Ct,hasFeedback:pt,hidden:un,children:$n,fieldId:Dn,required:kn,isRequired:pr,onSubItemMetaChange:gt,layout:Ve}=Ce,Et=En(Ce,["prefixCls","className","rootClassName","style","help","errors","warnings","validateStatus","meta","hasFeedback","hidden","children","fieldId","required","isRequired","onSubItemMetaChange","layout"]),Rt=`${Be}-item`,{requiredMark:Zt,vertical:hn}=ve.useContext(z.q3),Hn=hn||Ve==="vertical",Sn=ve.useRef(null),Tn=Oe(sn),An=Oe(Xt),jn=nn!=null,Pn=!!(jn||sn.length||Xt.length),lr=!!Sn.current&&(0,Nt.Z)(Sn.current),[Jn,Kn]=ve.useState(null);(0,rn.Z)(()=>{if(Pn&&Sn.current){const Gn=getComputedStyle(Sn.current);Kn(parseInt(Gn.marginBottom,10))}},[Pn,lr]);const sr=Gn=>{Gn||Kn(null)},Qn=function(){let Gn=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1;const vr=Gn?Tn:Ct.errors,qn=Gn?An:Ct.warnings;return kt(vr,qn,Ct,"",!!pt,Ht)}(),cr=ye()(Rt,we,Te,{[`${Rt}-with-help`]:jn||Tn.length||An.length,[`${Rt}-has-feedback`]:Qn&&pt,[`${Rt}-has-success`]:Qn==="success",[`${Rt}-has-warning`]:Qn==="warning",[`${Rt}-has-error`]:Qn==="error",[`${Rt}-is-validating`]:Qn==="validating",[`${Rt}-hidden`]:un,[`${Rt}-${Ve}`]:Ve});return ve.createElement("div",{className:cr,style:Qe,ref:Sn},ve.createElement(on.Z,Object.assign({className:`${Rt}-row`},(0,qt.Z)(Et,["_internalItemRender","colon","dependencies","extra","fieldKey","getValueFromEvent","getValueProps","htmlFor","id","initialValue","isListField","label","labelAlign","labelCol","labelWrap","messageVariables","name","normalize","noStyle","preserve","requiredMark","rules","shouldUpdate","trigger","tooltip","validateFirst","validateTrigger","valuePropName","wrapperCol","validateDebounce"])),ve.createElement(Cn,Object.assign({htmlFor:Dn},Ce,{requiredMark:Zt,required:kn!=null?kn:pr,prefixCls:Be,vertical:Hn})),ve.createElement(Pe,Object.assign({},Ce,Ct,{errors:Tn,warnings:An,prefixCls:Be,status:Qn,help:nn,marginBottom:Jn,onErrorVisibleChanged:sr}),ve.createElement(z.qI.Provider,{value:gt},ve.createElement(Ut,{prefixCls:Be,meta:Ct,errors:Ct.errors,warnings:Ct.warnings,hasFeedback:pt,validateStatus:Qn},$n)))),!!Jn&&ve.createElement("div",{className:`${Rt}-margin-offset`,style:{marginBottom:-Jn}}))}const xn="__SPLIT__",wn=null;function Bn(Ce,Be){const we=Object.keys(Ce),Te=Object.keys(Be);return we.length===Te.length&&we.every(Qe=>{const nn=Ce[Qe],sn=Be[Qe];return nn===sn||typeof nn=="function"||typeof sn=="function"})}const Zn=ve.memo(Ce=>{let{children:Be}=Ce;return Be},(Ce,Be)=>Bn(Ce.control,Be.control)&&Ce.update===Be.update&&Ce.childProps.length===Be.childProps.length&&Ce.childProps.every((we,Te)=>we===Be.childProps[Te]));function Yn(){return{errors:[],warnings:[],touched:!1,validating:!1,name:[],validated:!1}}function Wn(Ce){const{name:Be,noStyle:we,className:Te,dependencies:Qe,prefixCls:nn,shouldUpdate:sn,rules:Xt,children:Ht,required:Ct,label:pt,messageVariables:un,trigger:$n="onChange",validateTrigger:Dn,hidden:kn,help:pr,layout:gt}=Ce,{getPrefixCls:Ve}=ve.useContext(Pt.E_),{name:Et}=ve.useContext(z.q3),Rt=Fe(Ht),Zt=typeof Rt=="function",hn=ve.useContext(z.qI),{validateTrigger:Hn}=ve.useContext(He.FieldContext),Sn=Dn!==void 0?Dn:Hn,Tn=Be!=null,An=Ve("form",nn),jn=(0,Re.Z)(An),[Pn,lr,Jn]=at(An,jn),Kn=(0,ot.ln)("Form.Item"),sr=ve.useContext(He.ListContext),mr=ve.useRef(null),[Qn,cr]=Kt({}),[Gn,vr]=(0,ne.Z)(()=>Yn()),qn=dr=>{const er=sr==null?void 0:sr.getKey(dr.name);if(vr(dr.destroy?Yn():dr,!0),we&&pr!==!1&&hn){let tn=dr.name;if(dr.destroy)tn=mr.current||tn;else if(er!==void 0){const[fn,pn]=er;tn=[fn].concat((0,Ke.Z)(pn)),mr.current=tn}hn(dr,tn)}},Sr=(dr,er)=>{cr(tn=>{const fn=Object.assign({},tn),Jt=[].concat((0,Ke.Z)(dr.name.slice(0,-1)),(0,Ke.Z)(er)).join(xn);return dr.destroy?delete fn[Jt]:fn[Jt]=dr,fn})},[ar,or]=ve.useMemo(()=>{const dr=(0,Ke.Z)(Gn.errors),er=(0,Ke.Z)(Gn.warnings);return Object.values(Qn).forEach(tn=>{dr.push.apply(dr,(0,Ke.Z)(tn.errors||[])),er.push.apply(er,(0,Ke.Z)(tn.warnings||[]))}),[dr,er]},[Qn,Gn.errors,Gn.warnings]),hr=Wt();function xr(dr,er,tn){return we&&!kn?ve.createElement(Ut,{prefixCls:An,hasFeedback:Ce.hasFeedback,validateStatus:Ce.validateStatus,meta:Gn,errors:ar,warnings:or,noStyle:!0},dr):ve.createElement(mn,Object.assign({key:"row"},Ce,{className:ye()(Te,Jn,jn,lr),prefixCls:An,fieldId:er,isRequired:tn,errors:ar,warnings:or,meta:Gn,onSubItemMetaChange:Sr,layout:gt}),dr)}if(!Tn&&!Zt&&!Qe)return Pn(xr(Rt));let br={};return typeof pt=="string"?br.label=pt:Be&&(br.label=String(Be)),un&&(br=Object.assign(Object.assign({},br),un)),Pn(ve.createElement(He.Field,Object.assign({},Ce,{messageVariables:br,trigger:$n,validateTrigger:Sn,onMetaChange:qn}),(dr,er,tn)=>{const fn=et(Be).length&&er?er.name:[],pn=cn(fn,Et),Jt=Ct!==void 0?Ct:!!(Xt!=null&&Xt.some(an=>{if(an&&typeof an=="object"&&an.required&&!an.warningOnly)return!0;if(typeof an=="function"){const dn=an(tn);return(dn==null?void 0:dn.required)&&!(dn!=null&&dn.warningOnly)}return!1})),zn=Object.assign({},dr);let _n=null;if(Array.isArray(Rt)&&Tn)_n=Rt;else if(!(Zt&&(!(sn||Qe)||Tn))){if(!(Qe&&!Zt&&!Tn))if(ve.isValidElement(Rt)){const an=Object.assign(Object.assign({},Rt.props),zn);if(an.id||(an.id=pn),pr||ar.length>0||or.length>0||Ce.extra){const Ln=[];(pr||ar.length>0)&&Ln.push(`${pn}_help`),Ce.extra&&Ln.push(`${pn}_extra`),an["aria-describedby"]=Ln.join(" ")}ar.length>0&&(an["aria-invalid"]="true"),Jt&&(an["aria-required"]="true"),(0,he.Yr)(Rt)&&(an.ref=hr(fn,Rt)),new Set([].concat((0,Ke.Z)(et($n)),(0,Ke.Z)(et(Sn)))).forEach(Ln=>{an[Ln]=function(){for(var yr,Mr,Cr,Ar,Tr,Lr=arguments.length,Dr=new Array(Lr),Nr=0;Nr<Lr;Nr++)Dr[Nr]=arguments[Nr];(Cr=zn[Ln])===null||Cr===void 0||(yr=Cr).call.apply(yr,[zn].concat(Dr)),(Tr=(Ar=Rt.props)[Ln])===null||Tr===void 0||(Mr=Tr).call.apply(Mr,[Ar].concat(Dr))}});const Nn=[an["aria-required"],an["aria-invalid"],an["aria-describedby"]];_n=ve.createElement(Zn,{control:zn,update:Rt,childProps:Nn},(0,xe.Tm)(Rt,an))}else Zt&&(sn||Qe)&&!Tn?_n=Rt(tn):_n=Rt}return xr(_n,pn,Jt)}))}const ir=Wn;ir.useStatus=bt;var gn=ir,Dt=function(Ce,Be){var we={};for(var Te in Ce)Object.prototype.hasOwnProperty.call(Ce,Te)&&Be.indexOf(Te)<0&&(we[Te]=Ce[Te]);if(Ce!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Qe=0,Te=Object.getOwnPropertySymbols(Ce);Qe<Te.length;Qe++)Be.indexOf(Te[Qe])<0&&Object.prototype.propertyIsEnumerable.call(Ce,Te[Qe])&&(we[Te[Qe]]=Ce[Te[Qe]]);return we},Un=Ce=>{var{prefixCls:Be,children:we}=Ce,Te=Dt(Ce,["prefixCls","children"]);const{getPrefixCls:Qe}=ve.useContext(Pt.E_),nn=Qe("form",Be),sn=ve.useMemo(()=>({prefixCls:nn,status:"error"}),[nn]);return ve.createElement(He.List,Object.assign({},Te),(Xt,Ht,Ct)=>ve.createElement(z.Rk.Provider,{value:sn},we(Xt.map(pt=>Object.assign(Object.assign({},pt),{fieldKey:pt.key})),Ht,{errors:Ct.errors,warnings:Ct.warnings})))};function fr(){const{form:Ce}=ve.useContext(z.q3);return Ce}const ke=se;ke.Item=gn,ke.List=Un,ke.ErrorList=De,ke.useForm=ut,ke.useFormInstance=fr,ke.useWatch=He.useWatch,ke.Provider=z.RV,ke.create=()=>{};var _e=ke},75786:function(ln,Ft,ie){"use strict";ie.d(Ft,{Z:function(){return pr}});var z=ie(59301),Ke=ie(15277),ve=ie(92310),Ae=ie.n(ve),ye=ie(54476),be=ie(33885),Me=ie(20068),Re=ie(42978),Oe=ie(76190),fe=ie(75931),We=/margin|padding|width|height|max|min|offset/,Se={left:!0,top:!0},yt={cssFloat:1,styleFloat:1,float:1};function Xe(gt){return gt.nodeType===1?gt.ownerDocument.defaultView.getComputedStyle(gt,null):{}}function Le(gt,Ve,Et){if(Ve=Ve.toLowerCase(),Et==="auto"){if(Ve==="height")return gt.offsetHeight;if(Ve==="width")return gt.offsetWidth}return Ve in Se||(Se[Ve]=We.test(Ve)),Se[Ve]?parseFloat(Et)||0:Et}function Ge(gt,Ve){var Et=arguments.length,Rt=Xe(gt);return Ve=yt[Ve]?"cssFloat"in gt.style?"cssFloat":"styleFloat":Ve,Et===1?Rt:Le(gt,Ve,Rt[Ve]||gt.style[Ve])}function Ne(gt,Ve,Et){var Rt=arguments.length;if(Ve=yt[Ve]?"cssFloat"in gt.style?"cssFloat":"styleFloat":Ve,Rt===3)return typeof Et=="number"&&We.test(Ve)&&(Et="".concat(Et,"px")),gt.style[Ve]=Et,Et;for(var Zt in Ve)Ve.hasOwnProperty(Zt)&&Ne(gt,Zt,Ve[Zt]);return Xe(gt)}function dt(gt){return gt===document.body?document.documentElement.clientWidth:gt.offsetWidth}function It(gt){return gt===document.body?window.innerHeight||document.documentElement.clientHeight:gt.offsetHeight}function Bt(){var gt=Math.max(document.documentElement.scrollWidth,document.body.scrollWidth),Ve=Math.max(document.documentElement.scrollHeight,document.body.scrollHeight);return{width:gt,height:Ve}}function mt(){var gt=document.documentElement.clientWidth,Ve=window.innerHeight||document.documentElement.clientHeight;return{width:gt,height:Ve}}function st(){return{scrollLeft:Math.max(document.documentElement.scrollLeft,document.body.scrollLeft),scrollTop:Math.max(document.documentElement.scrollTop,document.body.scrollTop)}}function it(gt){var Ve=gt.getBoundingClientRect(),Et=document.documentElement;return{left:Ve.left+(window.pageXOffset||Et.scrollLeft)-(Et.clientLeft||document.body.clientLeft||0),top:Ve.top+(window.pageYOffset||Et.scrollTop)-(Et.clientTop||document.body.clientTop||0)}}var je=ie(18929),Ot=ie(55311),nt=ie(8224),tt=ie(10228),ht=ie(43403),$e=ie(77900),at=z.createContext(null),lt=function(Ve){var Et=Ve.visible,Rt=Ve.maskTransitionName,Zt=Ve.getContainer,hn=Ve.prefixCls,Hn=Ve.rootClassName,Sn=Ve.icons,Tn=Ve.countRender,An=Ve.showSwitch,jn=Ve.showProgress,Pn=Ve.current,lr=Ve.transform,Jn=Ve.count,Kn=Ve.scale,sr=Ve.minScale,mr=Ve.maxScale,Qn=Ve.closeIcon,cr=Ve.onActive,Gn=Ve.onClose,vr=Ve.onZoomIn,qn=Ve.onZoomOut,Sr=Ve.onRotateRight,ar=Ve.onRotateLeft,or=Ve.onFlipX,hr=Ve.onFlipY,xr=Ve.onReset,br=Ve.toolbarRender,dr=Ve.zIndex,er=Ve.image,tn=(0,z.useContext)(at),fn=Sn.rotateLeft,pn=Sn.rotateRight,Jt=Sn.zoomIn,zn=Sn.zoomOut,_n=Sn.close,an=Sn.left,dn=Sn.right,Nn=Sn.flipX,Ln=Sn.flipY,yr="".concat(hn,"-operations-operation");z.useEffect(function(){var Wr=function(Ur){Ur.keyCode===tt.Z.ESC&&Gn()};return Et&&window.addEventListener("keydown",Wr),function(){window.removeEventListener("keydown",Wr)}},[Et]);var Mr=function(jr,Ur){jr.preventDefault(),jr.stopPropagation(),cr(Ur)},Cr=z.useCallback(function(Wr){var jr=Wr.type,Ur=Wr.disabled,kr=Wr.onClick,Jr=Wr.icon;return z.createElement("div",{key:jr,className:Ae()(yr,"".concat(hn,"-operations-operation-").concat(jr),(0,Me.Z)({},"".concat(hn,"-operations-operation-disabled"),!!Ur)),onClick:kr},Jr)},[yr,hn]),Ar=An?Cr({icon:an,onClick:function(jr){return Mr(jr,-1)},type:"prev",disabled:Pn===0}):void 0,Tr=An?Cr({icon:dn,onClick:function(jr){return Mr(jr,1)},type:"next",disabled:Pn===Jn-1}):void 0,Lr=Cr({icon:Ln,onClick:hr,type:"flipY"}),Dr=Cr({icon:Nn,onClick:or,type:"flipX"}),Nr=Cr({icon:fn,onClick:ar,type:"rotateLeft"}),Fr=Cr({icon:pn,onClick:Sr,type:"rotateRight"}),Gr=Cr({icon:zn,onClick:qn,type:"zoomOut",disabled:Kn<=sr}),Qr=Cr({icon:Jt,onClick:vr,type:"zoomIn",disabled:Kn===mr}),ri=z.createElement("div",{className:"".concat(hn,"-operations")},Lr,Dr,Nr,Fr,Gr,Qr);return z.createElement($e.default,{visible:Et,motionName:Rt},function(Wr){var jr=Wr.className,Ur=Wr.style;return z.createElement(ht.Z,{open:!0,getContainer:Zt!=null?Zt:document.body},z.createElement("div",{className:Ae()("".concat(hn,"-operations-wrapper"),jr,Hn),style:(0,be.Z)((0,be.Z)({},Ur),{},{zIndex:dr})},Qn===null?null:z.createElement("button",{className:"".concat(hn,"-close"),onClick:Gn},Qn||_n),An&&z.createElement(z.Fragment,null,z.createElement("div",{className:Ae()("".concat(hn,"-switch-left"),(0,Me.Z)({},"".concat(hn,"-switch-left-disabled"),Pn===0)),onClick:function(Jr){return Mr(Jr,-1)}},an),z.createElement("div",{className:Ae()("".concat(hn,"-switch-right"),(0,Me.Z)({},"".concat(hn,"-switch-right-disabled"),Pn===Jn-1)),onClick:function(Jr){return Mr(Jr,1)}},dn)),z.createElement("div",{className:"".concat(hn,"-footer")},jn&&z.createElement("div",{className:"".concat(hn,"-progress")},Tn?Tn(Pn+1,Jn):"".concat(Pn+1," / ").concat(Jn)),br?br(ri,(0,be.Z)((0,be.Z)({icons:{prevIcon:Ar,nextIcon:Tr,flipYIcon:Lr,flipXIcon:Dr,rotateLeftIcon:Nr,rotateRightIcon:Fr,zoomOutIcon:Gr,zoomInIcon:Qr},actions:{onActive:cr,onFlipY:hr,onFlipX:or,onRotateLeft:ar,onRotateRight:Sr,onZoomOut:qn,onZoomIn:vr,onReset:xr,onClose:Gn},transform:lr},tn?{current:Pn,total:Jn}:{}),{},{image:er})):ri)))})},me=lt,At=ie(13697),De=ie(16089),He={x:0,y:0,rotate:0,scale:1,flipX:!1,flipY:!1};function Pt(gt,Ve,Et,Rt){var Zt=(0,z.useRef)(null),hn=(0,z.useRef)([]),Hn=(0,z.useState)(He),Sn=(0,Re.Z)(Hn,2),Tn=Sn[0],An=Sn[1],jn=function(Kn){An(He),(0,At.Z)(He,Tn)||Rt==null||Rt({transform:He,action:Kn})},Pn=function(Kn,sr){Zt.current===null&&(hn.current=[],Zt.current=(0,De.Z)(function(){An(function(mr){var Qn=mr;return hn.current.forEach(function(cr){Qn=(0,be.Z)((0,be.Z)({},Qn),cr)}),Zt.current=null,Rt==null||Rt({transform:Qn,action:sr}),Qn})})),hn.current.push((0,be.Z)((0,be.Z)({},Tn),Kn))},lr=function(Kn,sr,mr,Qn,cr){var Gn=gt.current,vr=Gn.width,qn=Gn.height,Sr=Gn.offsetWidth,ar=Gn.offsetHeight,or=Gn.offsetLeft,hr=Gn.offsetTop,xr=Kn,br=Tn.scale*Kn;br>Et?(br=Et,xr=Et/Tn.scale):br<Ve&&(br=cr?br:Ve,xr=br/Tn.scale);var dr=mr!=null?mr:innerWidth/2,er=Qn!=null?Qn:innerHeight/2,tn=xr-1,fn=tn*vr*.5,pn=tn*qn*.5,Jt=tn*(dr-Tn.x-or),zn=tn*(er-Tn.y-hr),_n=Tn.x-(Jt-fn),an=Tn.y-(zn-pn);if(Kn<1&&br===1){var dn=Sr*br,Nn=ar*br,Ln=mt(),yr=Ln.width,Mr=Ln.height;dn<=yr&&Nn<=Mr&&(_n=0,an=0)}Pn({x:_n,y:an,scale:br},sr)};return{transform:Tn,resetTransform:jn,updateTransform:Pn,dispatchZoomChange:lr}}var ge=ie(48736);function ce(gt,Ve,Et,Rt){var Zt=Ve+Et,hn=(Et-Rt)/2;if(Et>Rt){if(Ve>0)return(0,Me.Z)({},gt,hn);if(Ve<0&&Zt<Rt)return(0,Me.Z)({},gt,-hn)}else if(Ve<0||Zt>Rt)return(0,Me.Z)({},gt,Ve<0?hn:-hn);return{}}function Je(gt,Ve,Et,Rt){var Zt=mt(),hn=Zt.width,Hn=Zt.height,Sn=null;return gt<=hn&&Ve<=Hn?Sn={x:0,y:0}:(gt>hn||Ve>Hn)&&(Sn=(0,be.Z)((0,be.Z)({},ce("x",Et,gt,hn)),ce("y",Rt,Ve,Hn))),Sn}var jt=1,wt=1;function Ie(gt,Ve,Et,Rt,Zt,hn,Hn){var Sn=Zt.rotate,Tn=Zt.scale,An=Zt.x,jn=Zt.y,Pn=(0,z.useState)(!1),lr=(0,Re.Z)(Pn,2),Jn=lr[0],Kn=lr[1],sr=(0,z.useRef)({diffX:0,diffY:0,transformX:0,transformY:0}),mr=function(qn){!Ve||qn.button!==0||(qn.preventDefault(),qn.stopPropagation(),sr.current={diffX:qn.pageX-An,diffY:qn.pageY-jn,transformX:An,transformY:jn},Kn(!0))},Qn=function(qn){Et&&Jn&&hn({x:qn.pageX-sr.current.diffX,y:qn.pageY-sr.current.diffY},"move")},cr=function(){if(Et&&Jn){Kn(!1);var qn=sr.current,Sr=qn.transformX,ar=qn.transformY,or=An!==Sr&&jn!==ar;if(!or)return;var hr=gt.current.offsetWidth*Tn,xr=gt.current.offsetHeight*Tn,br=gt.current.getBoundingClientRect(),dr=br.left,er=br.top,tn=Sn%180!==0,fn=Je(tn?xr:hr,tn?hr:xr,dr,er);fn&&hn((0,be.Z)({},fn),"dragRebound")}},Gn=function(qn){if(!(!Et||qn.deltaY==0)){var Sr=Math.abs(qn.deltaY/100),ar=Math.min(Sr,wt),or=jt+ar*Rt;qn.deltaY>0&&(or=jt/or),Hn(or,"wheel",qn.clientX,qn.clientY)}};return(0,z.useEffect)(function(){var vr,qn,Sr,ar;if(Ve){Sr=(0,nt.Z)(window,"mouseup",cr,!1),ar=(0,nt.Z)(window,"mousemove",Qn,!1);try{window.top!==window.self&&(vr=(0,nt.Z)(window.top,"mouseup",cr,!1),qn=(0,nt.Z)(window.top,"mousemove",Qn,!1))}catch(or){(0,ge.Kp)(!1,"[rc-image] ".concat(or))}}return function(){var or,hr,xr,br;(or=Sr)===null||or===void 0||or.remove(),(hr=ar)===null||hr===void 0||hr.remove(),(xr=vr)===null||xr===void 0||xr.remove(),(br=qn)===null||br===void 0||br.remove()}},[Et,Jn,An,jn,Sn,Ve]),{isMoving:Jn,onMouseDown:mr,onMouseMove:Qn,onMouseUp:cr,onWheel:Gn}}function Ue(gt){return new Promise(function(Ve){if(!gt){Ve(!1);return}var Et=document.createElement("img");Et.onerror=function(){return Ve(!1)},Et.onload=function(){return Ve(!0)},Et.src=gt})}function et(gt){var Ve=gt.src,Et=gt.isCustomPlaceholder,Rt=gt.fallback,Zt=(0,z.useState)(Et?"loading":"normal"),hn=(0,Re.Z)(Zt,2),Hn=hn[0],Sn=hn[1],Tn=(0,z.useRef)(!1),An=Hn==="error";(0,z.useEffect)(function(){var Jn=!0;return Ue(Ve).then(function(Kn){!Kn&&Jn&&Sn("error")}),function(){Jn=!1}},[Ve]),(0,z.useEffect)(function(){Et&&!Tn.current?Sn("loading"):An&&Sn("normal")},[Ve]);var jn=function(){Sn("normal")},Pn=function(Kn){Tn.current=!1,Hn==="loading"&&Kn!==null&&Kn!==void 0&&Kn.complete&&(Kn.naturalWidth||Kn.naturalHeight)&&(Tn.current=!0,jn())},lr=An&&Rt?{src:Rt}:{onLoad:jn,src:Ve};return[Pn,lr,Hn]}function cn(gt,Ve){var Et=gt.x-Ve.x,Rt=gt.y-Ve.y;return Math.hypot(Et,Rt)}function kt(gt,Ve,Et,Rt){var Zt=cn(gt,Et),hn=cn(Ve,Rt);if(Zt===0&&hn===0)return[gt.x,gt.y];var Hn=Zt/(Zt+hn),Sn=gt.x+Hn*(Ve.x-gt.x),Tn=gt.y+Hn*(Ve.y-gt.y);return[Sn,Tn]}function Yt(gt,Ve,Et,Rt,Zt,hn,Hn){var Sn=Zt.rotate,Tn=Zt.scale,An=Zt.x,jn=Zt.y,Pn=(0,z.useState)(!1),lr=(0,Re.Z)(Pn,2),Jn=lr[0],Kn=lr[1],sr=(0,z.useRef)({point1:{x:0,y:0},point2:{x:0,y:0},eventType:"none"}),mr=function(qn){sr.current=(0,be.Z)((0,be.Z)({},sr.current),qn)},Qn=function(qn){if(Ve){qn.stopPropagation(),Kn(!0);var Sr=qn.touches,ar=Sr===void 0?[]:Sr;ar.length>1?mr({point1:{x:ar[0].clientX,y:ar[0].clientY},point2:{x:ar[1].clientX,y:ar[1].clientY},eventType:"touchZoom"}):mr({point1:{x:ar[0].clientX-An,y:ar[0].clientY-jn},eventType:"move"})}},cr=function(qn){var Sr=qn.touches,ar=Sr===void 0?[]:Sr,or=sr.current,hr=or.point1,xr=or.point2,br=or.eventType;if(ar.length>1&&br==="touchZoom"){var dr={x:ar[0].clientX,y:ar[0].clientY},er={x:ar[1].clientX,y:ar[1].clientY},tn=kt(hr,xr,dr,er),fn=(0,Re.Z)(tn,2),pn=fn[0],Jt=fn[1],zn=cn(dr,er)/cn(hr,xr);Hn(zn,"touchZoom",pn,Jt,!0),mr({point1:dr,point2:er,eventType:"touchZoom"})}else br==="move"&&(hn({x:ar[0].clientX-hr.x,y:ar[0].clientY-hr.y},"move"),mr({eventType:"move"}))},Gn=function(){if(Et){if(Jn&&Kn(!1),mr({eventType:"none"}),Rt>Tn)return hn({x:0,y:0,scale:Rt},"touchZoom");var qn=gt.current.offsetWidth*Tn,Sr=gt.current.offsetHeight*Tn,ar=gt.current.getBoundingClientRect(),or=ar.left,hr=ar.top,xr=Sn%180!==0,br=Je(xr?Sr:qn,xr?qn:Sr,or,hr);br&&hn((0,be.Z)({},br),"dragRebound")}};return(0,z.useEffect)(function(){var vr;return Et&&Ve&&(vr=(0,nt.Z)(window,"touchmove",function(qn){return qn.preventDefault()},{passive:!1})),function(){var qn;(qn=vr)===null||qn===void 0||qn.remove()}},[Et,Ve]),{isTouching:Jn,onTouchStart:Qn,onTouchMove:cr,onTouchEnd:Gn}}var ze=["fallback","src","imgRef"],zt=["prefixCls","src","alt","imageInfo","fallback","movable","onClose","visible","icons","rootClassName","closeIcon","getContainer","current","count","countRender","scaleStep","minScale","maxScale","transitionName","maskTransitionName","imageRender","imgCommonProps","toolbarRender","onTransform","onChange"],ut=function(Ve){var Et=Ve.fallback,Rt=Ve.src,Zt=Ve.imgRef,hn=(0,fe.Z)(Ve,ze),Hn=et({src:Rt,fallback:Et}),Sn=(0,Re.Z)(Hn,2),Tn=Sn[0],An=Sn[1];return z.createElement("img",(0,ye.Z)({ref:function(Pn){Zt.current=Pn,Tn(Pn)}},hn,An))},ae=function(Ve){var Et=Ve.prefixCls,Rt=Ve.src,Zt=Ve.alt,hn=Ve.imageInfo,Hn=Ve.fallback,Sn=Ve.movable,Tn=Sn===void 0?!0:Sn,An=Ve.onClose,jn=Ve.visible,Pn=Ve.icons,lr=Pn===void 0?{}:Pn,Jn=Ve.rootClassName,Kn=Ve.closeIcon,sr=Ve.getContainer,mr=Ve.current,Qn=mr===void 0?0:mr,cr=Ve.count,Gn=cr===void 0?1:cr,vr=Ve.countRender,qn=Ve.scaleStep,Sr=qn===void 0?.5:qn,ar=Ve.minScale,or=ar===void 0?1:ar,hr=Ve.maxScale,xr=hr===void 0?50:hr,br=Ve.transitionName,dr=br===void 0?"zoom":br,er=Ve.maskTransitionName,tn=er===void 0?"fade":er,fn=Ve.imageRender,pn=Ve.imgCommonProps,Jt=Ve.toolbarRender,zn=Ve.onTransform,_n=Ve.onChange,an=(0,fe.Z)(Ve,zt),dn=(0,z.useRef)(),Nn=(0,z.useContext)(at),Ln=Nn&&Gn>1,yr=Nn&&Gn>=1,Mr=(0,z.useState)(!0),Cr=(0,Re.Z)(Mr,2),Ar=Cr[0],Tr=Cr[1],Lr=Pt(dn,or,xr,zn),Dr=Lr.transform,Nr=Lr.resetTransform,Fr=Lr.updateTransform,Gr=Lr.dispatchZoomChange,Qr=Ie(dn,Tn,jn,Sr,Dr,Fr,Gr),ri=Qr.isMoving,Wr=Qr.onMouseDown,jr=Qr.onWheel,Ur=Yt(dn,Tn,jn,or,Dr,Fr,Gr),kr=Ur.isTouching,Jr=Ur.onTouchStart,Xr=Ur.onTouchMove,li=Ur.onTouchEnd,Ci=Dr.rotate,fi=Dr.scale,hi=Ae()((0,Me.Z)({},"".concat(Et,"-moving"),ri));(0,z.useEffect)(function(){Ar||Tr(!0)},[Ar]);var Ii=function(){Nr("close")},_r=function(){Gr(jt+Sr,"zoomIn")},si=function(){Gr(jt/(jt+Sr),"zoomOut")},Oi=function(){Fr({rotate:Ci+90},"rotateRight")},ki=function(){Fr({rotate:Ci-90},"rotateLeft")},qr=function(){Fr({flipX:!Dr.flipX},"flipX")},Ui=function(){Fr({flipY:!Dr.flipY},"flipY")},to=function(){Nr("reset")},wr=function(pi){var ui=Qn+pi;!Number.isInteger(ui)||ui<0||ui>Gn-1||(Tr(!1),Nr(pi<0?"prev":"next"),_n==null||_n(ui,Qn))},Br=function(pi){!jn||!Ln||(pi.keyCode===tt.Z.LEFT?wr(-1):pi.keyCode===tt.Z.RIGHT&&wr(1))},Or=function(pi){jn&&(fi!==1?Fr({x:0,y:0,scale:1},"doubleClick"):Gr(jt+Sr,"doubleClick",pi.clientX,pi.clientY))};(0,z.useEffect)(function(){var $r=(0,nt.Z)(window,"keydown",Br,!1);return function(){$r.remove()}},[jn,Ln,Qn]);var Pr=z.createElement(ut,(0,ye.Z)({},pn,{width:Ve.width,height:Ve.height,imgRef:dn,className:"".concat(Et,"-img"),alt:Zt,style:{transform:"translate3d(".concat(Dr.x,"px, ").concat(Dr.y,"px, 0) scale3d(").concat(Dr.flipX?"-":"").concat(fi,", ").concat(Dr.flipY?"-":"").concat(fi,", 1) rotate(").concat(Ci,"deg)"),transitionDuration:(!Ar||kr)&&"0s"},fallback:Hn,src:Rt,onWheel:jr,onMouseDown:Wr,onDoubleClick:Or,onTouchStart:Jr,onTouchMove:Xr,onTouchEnd:li,onTouchCancel:li})),Hr=(0,be.Z)({url:Rt,alt:Zt},hn);return z.createElement(z.Fragment,null,z.createElement(Ot.Z,(0,ye.Z)({transitionName:dr,maskTransitionName:tn,closable:!1,keyboard:!0,prefixCls:Et,onClose:An,visible:jn,classNames:{wrapper:hi},rootClassName:Jn,getContainer:sr},an,{afterClose:Ii}),z.createElement("div",{className:"".concat(Et,"-img-wrapper")},fn?fn(Pr,(0,be.Z)({transform:Dr,image:Hr},Nn?{current:Qn}:{})):Pr)),z.createElement(me,{visible:jn,transform:Dr,maskTransitionName:tn,closeIcon:Kn,getContainer:sr,prefixCls:Et,rootClassName:Jn,icons:lr,countRender:vr,showSwitch:Ln,showProgress:yr,current:Qn,count:Gn,scale:fi,minScale:or,maxScale:xr,toolbarRender:Jt,onActive:wr,onZoomIn:_r,onZoomOut:si,onRotateRight:Oi,onRotateLeft:ki,onFlipX:qr,onFlipY:Ui,onClose:An,onReset:to,zIndex:an.zIndex!==void 0?an.zIndex+1:void 0,image:Hr}))},te=ae,ee=ie(94480),oe=["crossOrigin","decoding","draggable","loading","referrerPolicy","sizes","srcSet","useMap","alt"];function se(gt){var Ve=z.useState({}),Et=(0,Re.Z)(Ve,2),Rt=Et[0],Zt=Et[1],hn=z.useCallback(function(Sn,Tn){return Zt(function(An){return(0,be.Z)((0,be.Z)({},An),{},(0,Me.Z)({},Sn,Tn))}),function(){Zt(function(An){var jn=(0,be.Z)({},An);return delete jn[Sn],jn})}},[]),Hn=z.useMemo(function(){return gt?gt.map(function(Sn){if(typeof Sn=="string")return{data:{src:Sn}};var Tn={};return Object.keys(Sn).forEach(function(An){["src"].concat((0,ee.Z)(oe)).includes(An)&&(Tn[An]=Sn[An])}),{data:Tn}}):Object.keys(Rt).reduce(function(Sn,Tn){var An=Rt[Tn],jn=An.canPreview,Pn=An.data;return jn&&Sn.push({data:Pn,id:Tn}),Sn},[])},[gt,Rt]);return[Hn,hn,!!gt]}var ne=["visible","onVisibleChange","getContainer","current","movable","minScale","maxScale","countRender","closeIcon","onChange","onTransform","toolbarRender","imageRender"],he=["src"],xe=function(Ve){var Et,Rt=Ve.previewPrefixCls,Zt=Rt===void 0?"rc-image-preview":Rt,hn=Ve.children,Hn=Ve.icons,Sn=Hn===void 0?{}:Hn,Tn=Ve.items,An=Ve.preview,jn=Ve.fallback,Pn=(0,Oe.Z)(An)==="object"?An:{},lr=Pn.visible,Jn=Pn.onVisibleChange,Kn=Pn.getContainer,sr=Pn.current,mr=Pn.movable,Qn=Pn.minScale,cr=Pn.maxScale,Gn=Pn.countRender,vr=Pn.closeIcon,qn=Pn.onChange,Sr=Pn.onTransform,ar=Pn.toolbarRender,or=Pn.imageRender,hr=(0,fe.Z)(Pn,ne),xr=se(Tn),br=(0,Re.Z)(xr,3),dr=br[0],er=br[1],tn=br[2],fn=(0,je.Z)(0,{value:sr}),pn=(0,Re.Z)(fn,2),Jt=pn[0],zn=pn[1],_n=(0,z.useState)(!1),an=(0,Re.Z)(_n,2),dn=an[0],Nn=an[1],Ln=((Et=dr[Jt])===null||Et===void 0?void 0:Et.data)||{},yr=Ln.src,Mr=(0,fe.Z)(Ln,he),Cr=(0,je.Z)(!!lr,{value:lr,onChange:function(kr,Jr){Jn==null||Jn(kr,Jr,Jt)}}),Ar=(0,Re.Z)(Cr,2),Tr=Ar[0],Lr=Ar[1],Dr=(0,z.useState)(null),Nr=(0,Re.Z)(Dr,2),Fr=Nr[0],Gr=Nr[1],Qr=z.useCallback(function(Ur,kr,Jr,Xr){var li=tn?dr.findIndex(function(Ci){return Ci.data.src===kr}):dr.findIndex(function(Ci){return Ci.id===Ur});zn(li<0?0:li),Lr(!0),Gr({x:Jr,y:Xr}),Nn(!0)},[dr,tn]);z.useEffect(function(){Tr?dn||zn(0):Nn(!1)},[Tr]);var ri=function(kr,Jr){zn(kr),qn==null||qn(kr,Jr)},Wr=function(){Lr(!1),Gr(null)},jr=z.useMemo(function(){return{register:er,onPreview:Qr}},[er,Qr]);return z.createElement(at.Provider,{value:jr},hn,z.createElement(te,(0,ye.Z)({"aria-hidden":!Tr,movable:mr,visible:Tr,prefixCls:Zt,closeIcon:vr,onClose:Wr,mousePosition:Fr,imgCommonProps:Mr,src:yr,fallback:jn,icons:Sn,minScale:Qn,maxScale:cr,getContainer:Kn,current:Jt,count:dr.length,countRender:Gn,onTransform:Sr,toolbarRender:ar,imageRender:or,onChange:ri},hr)))},ot=xe,Ee=0;function Fe(gt,Ve){var Et=z.useState(function(){return Ee+=1,String(Ee)}),Rt=(0,Re.Z)(Et,1),Zt=Rt[0],hn=z.useContext(at),Hn={data:Ve,canPreview:gt};return z.useEffect(function(){if(hn)return hn.register(Zt,Hn)},[]),z.useEffect(function(){hn&&hn.register(Zt,Hn)},[gt,Ve]),Zt}var qe=["src","alt","onPreviewClose","prefixCls","previewPrefixCls","placeholder","fallback","width","height","style","preview","className","onClick","onError","wrapperClassName","wrapperStyle","rootClassName"],bt=["src","visible","onVisibleChange","getContainer","mask","maskClassName","movable","icons","scaleStep","minScale","maxScale","imageRender","toolbarRender"],ct=function(Ve){var Et=Ve.src,Rt=Ve.alt,Zt=Ve.onPreviewClose,hn=Ve.prefixCls,Hn=hn===void 0?"rc-image":hn,Sn=Ve.previewPrefixCls,Tn=Sn===void 0?"".concat(Hn,"-preview"):Sn,An=Ve.placeholder,jn=Ve.fallback,Pn=Ve.width,lr=Ve.height,Jn=Ve.style,Kn=Ve.preview,sr=Kn===void 0?!0:Kn,mr=Ve.className,Qn=Ve.onClick,cr=Ve.onError,Gn=Ve.wrapperClassName,vr=Ve.wrapperStyle,qn=Ve.rootClassName,Sr=(0,fe.Z)(Ve,qe),ar=An&&An!==!0,or=(0,Oe.Z)(sr)==="object"?sr:{},hr=or.src,xr=or.visible,br=xr===void 0?void 0:xr,dr=or.onVisibleChange,er=dr===void 0?Zt:dr,tn=or.getContainer,fn=tn===void 0?void 0:tn,pn=or.mask,Jt=or.maskClassName,zn=or.movable,_n=or.icons,an=or.scaleStep,dn=or.minScale,Nn=or.maxScale,Ln=or.imageRender,yr=or.toolbarRender,Mr=(0,fe.Z)(or,bt),Cr=hr!=null?hr:Et,Ar=(0,je.Z)(!!br,{value:br,onChange:er}),Tr=(0,Re.Z)(Ar,2),Lr=Tr[0],Dr=Tr[1],Nr=et({src:Et,isCustomPlaceholder:ar,fallback:jn}),Fr=(0,Re.Z)(Nr,3),Gr=Fr[0],Qr=Fr[1],ri=Fr[2],Wr=(0,z.useState)(null),jr=(0,Re.Z)(Wr,2),Ur=jr[0],kr=jr[1],Jr=(0,z.useContext)(at),Xr=!!sr,li=function(){Dr(!1),kr(null)},Ci=Ae()(Hn,Gn,qn,(0,Me.Z)({},"".concat(Hn,"-error"),ri==="error")),fi=(0,z.useMemo)(function(){var si={};return oe.forEach(function(Oi){Ve[Oi]!==void 0&&(si[Oi]=Ve[Oi])}),si},oe.map(function(si){return Ve[si]})),hi=(0,z.useMemo)(function(){return(0,be.Z)((0,be.Z)({},fi),{},{src:Cr})},[Cr,fi]),Ii=Fe(Xr,hi),_r=function(Oi){var ki=it(Oi.target),qr=ki.left,Ui=ki.top;Jr?Jr.onPreview(Ii,Cr,qr,Ui):(kr({x:qr,y:Ui}),Dr(!0)),Qn==null||Qn(Oi)};return z.createElement(z.Fragment,null,z.createElement("div",(0,ye.Z)({},Sr,{className:Ci,onClick:Xr?_r:Qn,style:(0,be.Z)({width:Pn,height:lr},vr)}),z.createElement("img",(0,ye.Z)({},fi,{className:Ae()("".concat(Hn,"-img"),(0,Me.Z)({},"".concat(Hn,"-img-placeholder"),An===!0),mr),style:(0,be.Z)({height:lr},Jn),ref:Gr},Qr,{width:Pn,height:lr,onError:cr})),ri==="loading"&&z.createElement("div",{"aria-hidden":"true",className:"".concat(Hn,"-placeholder")},An),pn&&Xr&&z.createElement("div",{className:Ae()("".concat(Hn,"-mask"),Jt),style:{display:(Jn==null?void 0:Jn.display)==="none"?"none":void 0}},pn)),!Jr&&Xr&&z.createElement(te,(0,ye.Z)({"aria-hidden":!Lr,visible:Lr,prefixCls:Tn,onClose:li,mousePosition:Ur,src:Cr,alt:Rt,imageInfo:{width:Pn,height:lr},fallback:jn,getContainer:fn,icons:_n,movable:zn,scaleStep:an,minScale:dn,maxScale:Nn,rootClassName:qn,imageRender:Ln,imgCommonProps:fi,toolbarRender:yr},Mr)))};ct.PreviewGroup=ot;var Kt=ct,Wt=Kt,Nt=ie(75030),rn=ie(86641),qt=ie(48755),on=ie(83397),ft=ie(9017),Gt=ie(99267),Tt=ie(33853),en=ie(38819),yn={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"defs",attrs:{},children:[{tag:"style",attrs:{}}]},{tag:"path",attrs:{d:"M672 418H144c-17.7 0-32 14.3-32 32v414c0 17.7 14.3 32 32 32h528c17.7 0 32-14.3 32-32V450c0-17.7-14.3-32-32-32zm-44 402H188V494h440v326z"}},{tag:"path",attrs:{d:"M819.3 328.5c-78.8-100.7-196-153.6-314.6-154.2l-.2-64c0-6.5-7.6-10.1-12.6-6.1l-128 101c-4 3.1-3.9 9.1 0 12.3L492 318.6c5.1 4 12.7.4 12.6-6.1v-63.9c12.9.1 25.9.9 38.8 2.5 42.1 5.2 82.1 18.2 119 38.7 38.1 21.2 71.2 49.7 98.4 84.3 27.1 34.7 46.7 73.7 58.1 115.8a325.95 325.95 0 016.5 140.9h74.9c14.8-103.6-11.3-213-81-302.3z"}}]},name:"rotate-left",theme:"outlined"},Rn=yn,On=ie(7657),Pe=function(Ve,Et){return z.createElement(On.Z,(0,ye.Z)({},Ve,{ref:Et,icon:Rn}))},rt=z.forwardRef(Pe),St=rt,_t={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"defs",attrs:{},children:[{tag:"style",attrs:{}}]},{tag:"path",attrs:{d:"M480.5 251.2c13-1.6 25.9-2.4 38.8-2.5v63.9c0 6.5 7.5 10.1 12.6 6.1L660 217.6c4-3.2 4-9.2 0-12.3l-128-101c-5.1-4-12.6-.4-12.6 6.1l-.2 64c-118.6.5-235.8 53.4-314.6 154.2A399.75 399.75 0 00123.5 631h74.9c-.9-5.3-1.7-10.7-2.4-16.1-5.1-42.1-2.1-84.1 8.9-124.8 11.4-42.2 31-81.1 58.1-115.8 27.2-34.7 60.3-63.2 98.4-84.3 37-20.6 76.9-33.6 119.1-38.8z"}},{tag:"path",attrs:{d:"M880 418H352c-17.7 0-32 14.3-32 32v414c0 17.7 14.3 32 32 32h528c17.7 0 32-14.3 32-32V450c0-17.7-14.3-32-32-32zm-44 402H396V494h440v326z"}}]},name:"rotate-right",theme:"outlined"},bn=_t,In=function(Ve,Et){return z.createElement(On.Z,(0,ye.Z)({},Ve,{ref:Et,icon:bn}))},rr=z.forwardRef(In),Xn=rr,Cn={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M847.9 592H152c-4.4 0-8 3.6-8 8v60c0 4.4 3.6 8 8 8h605.2L612.9 851c-4.1 5.2-.4 13 6.3 13h72.5c4.9 0 9.5-2.2 12.6-6.1l168.8-214.1c16.5-21 1.6-51.8-25.2-51.8zM872 356H266.8l144.3-183c4.1-5.2.4-13-6.3-13h-72.5c-4.9 0-9.5 2.2-12.6 6.1L150.9 380.2c-16.5 21-1.6 51.8 25.1 51.8h696c4.4 0 8-3.6 8-8v-60c0-4.4-3.6-8-8-8z"}}]},name:"swap",theme:"outlined"},Fn=Cn,xt=function(Ve,Et){return z.createElement(On.Z,(0,ye.Z)({},Ve,{ref:Et,icon:Fn}))},$t=z.forwardRef(xt),vt=$t,Vt={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M637 443H519V309c0-4.4-3.6-8-8-8h-60c-4.4 0-8 3.6-8 8v134H325c-4.4 0-8 3.6-8 8v60c0 4.4 3.6 8 8 8h118v134c0 4.4 3.6 8 8 8h60c4.4 0 8-3.6 8-8V519h118c4.4 0 8-3.6 8-8v-60c0-4.4-3.6-8-8-8zm284 424L775 721c122.1-148.9 113.6-369.5-26-509-148-148.1-388.4-148.1-537 0-148.1 148.6-148.1 389 0 537 139.5 139.6 360.1 148.1 509 26l146 146c3.2 2.8 8.3 2.8 11 0l43-43c2.8-2.7 2.8-7.8 0-11zM696 696c-118.8 118.7-311.2 118.7-430 0-118.7-118.8-118.7-311.2 0-430 118.8-118.7 311.2-118.7 430 0 118.7 118.8 118.7 311.2 0 430z"}}]},name:"zoom-in",theme:"outlined"},Ut=Vt,En=function(Ve,Et){return z.createElement(On.Z,(0,ye.Z)({},Ve,{ref:Et,icon:Ut}))},mn=z.forwardRef(En),xn=mn,wn={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M637 443H325c-4.4 0-8 3.6-8 8v60c0 4.4 3.6 8 8 8h312c4.4 0 8-3.6 8-8v-60c0-4.4-3.6-8-8-8zm284 424L775 721c122.1-148.9 113.6-369.5-26-509-148-148.1-388.4-148.1-537 0-148.1 148.6-148.1 389 0 537 139.5 139.6 360.1 148.1 509 26l146 146c3.2 2.8 8.3 2.8 11 0l43-43c2.8-2.7 2.8-7.8 0-11zM696 696c-118.8 118.7-311.2 118.7-430 0-118.7-118.8-118.7-311.2 0-430 118.8-118.7 311.2-118.7 430 0 118.7 118.8 118.7 311.2 0 430z"}}]},name:"zoom-out",theme:"outlined"},Bn=wn,Zn=function(Ve,Et){return z.createElement(On.Z,(0,ye.Z)({},Ve,{ref:Et,icon:Bn}))},Yn=z.forwardRef(Zn),Wn=Yn,ir=ie(36237),gn=ie(17835),Dt=ie(64427),Qt=ie(63356),Un=ie(34925),fr=ie(99495),ke=ie(16931),_e=ie(51636);const Ce=gt=>({position:gt||"absolute",inset:0}),Be=gt=>{const{iconCls:Ve,motionDurationSlow:Et,paddingXXS:Rt,marginXXS:Zt,prefixCls:hn,colorTextLightSolid:Hn}=gt;return{position:"absolute",inset:0,display:"flex",alignItems:"center",justifyContent:"center",color:Hn,background:new gn.FastColor("#000").setA(.5).toRgbString(),cursor:"pointer",opacity:0,transition:`opacity ${Et}`,[`.${hn}-mask-info`]:Object.assign(Object.assign({},Qt.vS),{padding:`0 ${(0,ir.unit)(Rt)}`,[Ve]:{marginInlineEnd:Zt,svg:{verticalAlign:"baseline"}}})}},we=gt=>{const{previewCls:Ve,modalMaskBg:Et,paddingSM:Rt,marginXL:Zt,margin:hn,paddingLG:Hn,previewOperationColorDisabled:Sn,previewOperationHoverColor:Tn,motionDurationSlow:An,iconCls:jn,colorTextLightSolid:Pn}=gt,lr=new gn.FastColor(Et).setA(.1),Jn=lr.clone().setA(.2);return{[`${Ve}-footer`]:{position:"fixed",bottom:Zt,left:{_skip_check_:!0,value:"50%"},display:"flex",flexDirection:"column",alignItems:"center",color:gt.previewOperationColor,transform:"translateX(-50%)"},[`${Ve}-progress`]:{marginBottom:hn},[`${Ve}-close`]:{position:"fixed",top:Zt,right:{_skip_check_:!0,value:Zt},display:"flex",color:Pn,backgroundColor:lr.toRgbString(),borderRadius:"50%",padding:Rt,outline:0,border:0,cursor:"pointer",transition:`all ${An}`,"&:hover":{backgroundColor:Jn.toRgbString()},[`& > ${jn}`]:{fontSize:gt.previewOperationSize}},[`${Ve}-operations`]:{display:"flex",alignItems:"center",padding:`0 ${(0,ir.unit)(Hn)}`,backgroundColor:lr.toRgbString(),borderRadius:100,"&-operation":{marginInlineStart:Rt,padding:Rt,cursor:"pointer",transition:`all ${An}`,userSelect:"none",[`&:not(${Ve}-operations-operation-disabled):hover > ${jn}`]:{color:Tn},"&-disabled":{color:Sn,cursor:"not-allowed"},"&:first-of-type":{marginInlineStart:0},[`& > ${jn}`]:{fontSize:gt.previewOperationSize}}}}},Te=gt=>{const{modalMaskBg:Ve,iconCls:Et,previewOperationColorDisabled:Rt,previewCls:Zt,zIndexPopup:hn,motionDurationSlow:Hn}=gt,Sn=new gn.FastColor(Ve).setA(.1),Tn=Sn.clone().setA(.2);return{[`${Zt}-switch-left, ${Zt}-switch-right`]:{position:"fixed",insetBlockStart:"50%",zIndex:gt.calc(hn).add(1).equal(),display:"flex",alignItems:"center",justifyContent:"center",width:gt.imagePreviewSwitchSize,height:gt.imagePreviewSwitchSize,marginTop:gt.calc(gt.imagePreviewSwitchSize).mul(-1).div(2).equal(),color:gt.previewOperationColor,background:Sn.toRgbString(),borderRadius:"50%",transform:"translateY(-50%)",cursor:"pointer",transition:`all ${Hn}`,userSelect:"none","&:hover":{background:Tn.toRgbString()},"&-disabled":{"&, &:hover":{color:Rt,background:"transparent",cursor:"not-allowed",[`> ${Et}`]:{cursor:"not-allowed"}}},[`> ${Et}`]:{fontSize:gt.previewOperationSize}},[`${Zt}-switch-left`]:{insetInlineStart:gt.marginSM},[`${Zt}-switch-right`]:{insetInlineEnd:gt.marginSM}}},Qe=gt=>{const{motionEaseOut:Ve,previewCls:Et,motionDurationSlow:Rt,componentCls:Zt}=gt;return[{[`${Zt}-preview-root`]:{[Et]:{height:"100%",textAlign:"center",pointerEvents:"none"},[`${Et}-body`]:Object.assign(Object.assign({},Ce()),{overflow:"hidden"}),[`${Et}-img`]:{maxWidth:"100%",maxHeight:"70%",verticalAlign:"middle",transform:"scale3d(1, 1, 1)",cursor:"grab",transition:`transform ${Rt} ${Ve} 0s`,userSelect:"none","&-wrapper":Object.assign(Object.assign({},Ce()),{transition:`transform ${Rt} ${Ve} 0s`,display:"flex",justifyContent:"center",alignItems:"center","& > *":{pointerEvents:"auto"},"&::before":{display:"inline-block",width:1,height:"50%",marginInlineEnd:-1,content:'""'}})},[`${Et}-moving`]:{[`${Et}-preview-img`]:{cursor:"grabbing","&-wrapper":{transitionDuration:"0s"}}}}},{[`${Zt}-preview-root`]:{[`${Et}-wrap`]:{zIndex:gt.zIndexPopup}}},{[`${Zt}-preview-operations-wrapper`]:{position:"fixed",zIndex:gt.calc(gt.zIndexPopup).add(1).equal()},"&":[we(gt),Te(gt)]}]},nn=gt=>{const{componentCls:Ve}=gt;return{[Ve]:{position:"relative",display:"inline-block",[`${Ve}-img`]:{width:"100%",height:"auto",verticalAlign:"middle"},[`${Ve}-img-placeholder`]:{backgroundColor:gt.colorBgContainerDisabled,backgroundImage:"url('data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTYiIGhlaWdodD0iMTYiIHZpZXdCb3g9IjAgMCAxNiAxNiIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj48cGF0aCBkPSJNMTQuNSAyLjVoLTEzQS41LjUgMCAwIDAgMSAzdjEwYS41LjUgMCAwIDAgLjUuNWgxM2EuNS41IDAgMCAwIC41LS41VjNhLjUuNSAwIDAgMC0uNS0uNXpNNS4yODEgNC43NWExIDEgMCAwIDEgMCAyIDEgMSAwIDAgMSAwLTJ6bTguMDMgNi44M2EuMTI3LjEyNyAwIDAgMS0uMDgxLjAzSDIuNzY5YS4xMjUuMTI1IDAgMCAxLS4wOTYtLjIwN2wyLjY2MS0zLjE1NmEuMTI2LjEyNiAwIDAgMSAuMTc3LS4wMTZsLjAxNi4wMTZMNy4wOCAxMC4wOWwyLjQ3LTIuOTNhLjEyNi4xMjYgMCAwIDEgLjE3Ny0uMDE2bC4wMTUuMDE2IDMuNTg4IDQuMjQ0YS4xMjcuMTI3IDAgMCAxLS4wMi4xNzV6IiBmaWxsPSIjOEM4QzhDIiBmaWxsLXJ1bGU9Im5vbnplcm8iLz48L3N2Zz4=')",backgroundRepeat:"no-repeat",backgroundPosition:"center center",backgroundSize:"30%"},[`${Ve}-mask`]:Object.assign({},Be(gt)),[`${Ve}-mask:hover`]:{opacity:1},[`${Ve}-placeholder`]:Object.assign({},Ce())}}},sn=gt=>{const{previewCls:Ve}=gt;return{[`${Ve}-root`]:(0,Un._y)(gt,"zoom"),"&":(0,fr.J$)(gt,!0)}},Xt=gt=>({zIndexPopup:gt.zIndexPopupBase+80,previewOperationColor:new gn.FastColor(gt.colorTextLightSolid).setA(.65).toRgbString(),previewOperationHoverColor:new gn.FastColor(gt.colorTextLightSolid).setA(.85).toRgbString(),previewOperationColorDisabled:new gn.FastColor(gt.colorTextLightSolid).setA(.25).toRgbString(),previewOperationSize:gt.fontSizeIcon*1.5});var Ht=(0,ke.I$)("Image",gt=>{const Ve=`${gt.componentCls}-preview`,Et=(0,_e.mergeToken)(gt,{previewCls:Ve,modalMaskBg:new gn.FastColor("#000").setA(.45).toRgbString(),imagePreviewSwitchSize:gt.controlHeightLG});return[nn(Et),Qe(Et),(0,Dt.QA)((0,_e.mergeToken)(Et,{componentCls:Ve})),sn(Et)]},Xt),Ct=function(gt,Ve){var Et={};for(var Rt in gt)Object.prototype.hasOwnProperty.call(gt,Rt)&&Ve.indexOf(Rt)<0&&(Et[Rt]=gt[Rt]);if(gt!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Zt=0,Rt=Object.getOwnPropertySymbols(gt);Zt<Rt.length;Zt++)Ve.indexOf(Rt[Zt])<0&&Object.prototype.propertyIsEnumerable.call(gt,Rt[Zt])&&(Et[Rt[Zt]]=gt[Rt[Zt]]);return Et};const pt={rotateLeft:z.createElement(St,null),rotateRight:z.createElement(Xn,null),zoomIn:z.createElement(xn,null),zoomOut:z.createElement(Wn,null),close:z.createElement(Gt.Z,null),left:z.createElement(Tt.Z,null),right:z.createElement(en.Z,null),flipX:z.createElement(vt,null),flipY:z.createElement(vt,{rotate:90})};var $n=gt=>{var{previewPrefixCls:Ve,preview:Et}=gt,Rt=Ct(gt,["previewPrefixCls","preview"]);const{getPrefixCls:Zt}=z.useContext(qt.E_),hn=Zt("image",Ve),Hn=`${hn}-preview`,Sn=Zt(),Tn=(0,on.Z)(hn),[An,jn,Pn]=Ht(hn,Tn),[lr]=(0,Nt.Cn)("ImagePreview",typeof Et=="object"?Et.zIndex:void 0),Jn=z.useMemo(()=>{var Kn;if(Et===!1)return Et;const sr=typeof Et=="object"?Et:{},mr=Ae()(jn,Pn,Tn,(Kn=sr.rootClassName)!==null&&Kn!==void 0?Kn:"");return Object.assign(Object.assign({},sr),{transitionName:(0,rn.m)(Sn,"zoom",sr.transitionName),maskTransitionName:(0,rn.m)(Sn,"fade",sr.maskTransitionName),rootClassName:mr,zIndex:lr})},[Et]);return An(z.createElement(Wt.PreviewGroup,Object.assign({preview:Jn,previewPrefixCls:Hn,icons:pt},Rt)))},Dn=function(gt,Ve){var Et={};for(var Rt in gt)Object.prototype.hasOwnProperty.call(gt,Rt)&&Ve.indexOf(Rt)<0&&(Et[Rt]=gt[Rt]);if(gt!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Zt=0,Rt=Object.getOwnPropertySymbols(gt);Zt<Rt.length;Zt++)Ve.indexOf(Rt[Zt])<0&&Object.prototype.propertyIsEnumerable.call(gt,Rt[Zt])&&(Et[Rt[Zt]]=gt[Rt[Zt]]);return Et};const kn=gt=>{const{prefixCls:Ve,preview:Et,className:Rt,rootClassName:Zt,style:hn}=gt,Hn=Dn(gt,["prefixCls","preview","className","rootClassName","style"]),{getPrefixCls:Sn,getPopupContainer:Tn,className:An,style:jn,preview:Pn}=(0,qt.dj)("image"),[lr]=(0,ft.Z)("Image"),Jn=Sn("image",Ve),Kn=Sn(),sr=(0,on.Z)(Jn),[mr,Qn,cr]=Ht(Jn,sr),Gn=Ae()(Zt,Qn,cr,sr),vr=Ae()(Rt,Qn,An),[qn]=(0,Nt.Cn)("ImagePreview",typeof Et=="object"?Et.zIndex:void 0),Sr=z.useMemo(()=>{if(Et===!1)return Et;const or=typeof Et=="object"?Et:{},{getContainer:hr,closeIcon:xr,rootClassName:br}=or,dr=Dn(or,["getContainer","closeIcon","rootClassName"]);return Object.assign(Object.assign({mask:z.createElement("div",{className:`${Jn}-mask-info`},z.createElement(Ke.Z,null),lr==null?void 0:lr.preview),icons:pt},dr),{rootClassName:Ae()(Gn,br),getContainer:hr!=null?hr:Tn,transitionName:(0,rn.m)(Kn,"zoom",or.transitionName),maskTransitionName:(0,rn.m)(Kn,"fade",or.maskTransitionName),zIndex:qn,closeIcon:xr!=null?xr:Pn==null?void 0:Pn.closeIcon})},[Et,lr,Pn==null?void 0:Pn.closeIcon]),ar=Object.assign(Object.assign({},jn),hn);return mr(z.createElement(Wt,Object.assign({prefixCls:Jn,preview:Sr,rootClassName:Gn,className:vr,style:ar},Hn)))};kn.PreviewGroup=$n;var pr=kn},4875:function(ln,Ft,ie){"use strict";ie.d(Ft,{Z:function(){return On}});var z=ie(59301),Ke=ie(84105),ve=ie(87395),Ae=ie(92310),ye=ie.n(Ae),be=ie(54476),Me=ie(20068),Re=ie(76190),Oe=ie(42978),fe=ie(75931),We=ie(67732),Se=ie(83652);function yt(){return typeof BigInt=="function"}function Xe(Pe){return!Pe&&Pe!==0&&!Number.isNaN(Pe)||!String(Pe).trim()}function Le(Pe){var rt=Pe.trim(),St=rt.startsWith("-");St&&(rt=rt.slice(1)),rt=rt.replace(/(\.\d*[^0])0*$/,"$1").replace(/\.0*$/,"").replace(/^0+/,""),rt.startsWith(".")&&(rt="0".concat(rt));var _t=rt||"0",bn=_t.split("."),In=bn[0]||"0",rr=bn[1]||"0";In==="0"&&rr==="0"&&(St=!1);var Xn=St?"-":"";return{negative:St,negativeStr:Xn,trimStr:_t,integerStr:In,decimalStr:rr,fullStr:"".concat(Xn).concat(_t)}}function Ge(Pe){var rt=String(Pe);return!Number.isNaN(Number(rt))&&rt.includes("e")}function Ne(Pe){var rt=String(Pe);if(Ge(Pe)){var St=Number(rt.slice(rt.indexOf("e-")+2)),_t=rt.match(/\.(\d+)/);return _t!=null&&_t[1]&&(St+=_t[1].length),St}return rt.includes(".")&&It(rt)?rt.length-rt.indexOf(".")-1:0}function dt(Pe){var rt=String(Pe);if(Ge(Pe)){if(Pe>Number.MAX_SAFE_INTEGER)return String(yt()?BigInt(Pe).toString():Number.MAX_SAFE_INTEGER);if(Pe<Number.MIN_SAFE_INTEGER)return String(yt()?BigInt(Pe).toString():Number.MIN_SAFE_INTEGER);rt=Pe.toFixed(Ne(rt))}return Le(rt).fullStr}function It(Pe){return typeof Pe=="number"?!Number.isNaN(Pe):Pe?/^\s*-?\d+(\.\d+)?\s*$/.test(Pe)||/^\s*-?\d+\.\s*$/.test(Pe)||/^\s*-?\.\d+\s*$/.test(Pe):!1}var Bt=function(){function Pe(rt){if((0,We.Z)(this,Pe),(0,Me.Z)(this,"origin",""),(0,Me.Z)(this,"negative",void 0),(0,Me.Z)(this,"integer",void 0),(0,Me.Z)(this,"decimal",void 0),(0,Me.Z)(this,"decimalLen",void 0),(0,Me.Z)(this,"empty",void 0),(0,Me.Z)(this,"nan",void 0),Xe(rt)){this.empty=!0;return}if(this.origin=String(rt),rt==="-"||Number.isNaN(rt)){this.nan=!0;return}var St=rt;if(Ge(St)&&(St=Number(St)),St=typeof St=="string"?St:dt(St),It(St)){var _t=Le(St);this.negative=_t.negative;var bn=_t.trimStr.split(".");this.integer=BigInt(bn[0]);var In=bn[1]||"0";this.decimal=BigInt(In),this.decimalLen=In.length}else this.nan=!0}return(0,Se.Z)(Pe,[{key:"getMark",value:function(){return this.negative?"-":""}},{key:"getIntegerStr",value:function(){return this.integer.toString()}},{key:"getDecimalStr",value:function(){return this.decimal.toString().padStart(this.decimalLen,"0")}},{key:"alignDecimal",value:function(St){var _t="".concat(this.getMark()).concat(this.getIntegerStr()).concat(this.getDecimalStr().padEnd(St,"0"));return BigInt(_t)}},{key:"negate",value:function(){var St=new Pe(this.toString());return St.negative=!St.negative,St}},{key:"cal",value:function(St,_t,bn){var In=Math.max(this.getDecimalStr().length,St.getDecimalStr().length),rr=this.alignDecimal(In),Xn=St.alignDecimal(In),Cn=_t(rr,Xn).toString(),Fn=bn(In),xt=Le(Cn),$t=xt.negativeStr,vt=xt.trimStr,Vt="".concat($t).concat(vt.padStart(Fn+1,"0"));return new Pe("".concat(Vt.slice(0,-Fn),".").concat(Vt.slice(-Fn)))}},{key:"add",value:function(St){if(this.isInvalidate())return new Pe(St);var _t=new Pe(St);return _t.isInvalidate()?this:this.cal(_t,function(bn,In){return bn+In},function(bn){return bn})}},{key:"multi",value:function(St){var _t=new Pe(St);return this.isInvalidate()||_t.isInvalidate()?new Pe(NaN):this.cal(_t,function(bn,In){return bn*In},function(bn){return bn*2})}},{key:"isEmpty",value:function(){return this.empty}},{key:"isNaN",value:function(){return this.nan}},{key:"isInvalidate",value:function(){return this.isEmpty()||this.isNaN()}},{key:"equals",value:function(St){return this.toString()===(St==null?void 0:St.toString())}},{key:"lessEquals",value:function(St){return this.add(St.negate().toString()).toNumber()<=0}},{key:"toNumber",value:function(){return this.isNaN()?NaN:Number(this.toString())}},{key:"toString",value:function(){var St=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;return St?this.isInvalidate()?"":Le("".concat(this.getMark()).concat(this.getIntegerStr(),".").concat(this.getDecimalStr())).fullStr:this.origin}}]),Pe}(),mt=function(){function Pe(rt){if((0,We.Z)(this,Pe),(0,Me.Z)(this,"origin",""),(0,Me.Z)(this,"number",void 0),(0,Me.Z)(this,"empty",void 0),Xe(rt)){this.empty=!0;return}this.origin=String(rt),this.number=Number(rt)}return(0,Se.Z)(Pe,[{key:"negate",value:function(){return new Pe(-this.toNumber())}},{key:"add",value:function(St){if(this.isInvalidate())return new Pe(St);var _t=Number(St);if(Number.isNaN(_t))return this;var bn=this.number+_t;if(bn>Number.MAX_SAFE_INTEGER)return new Pe(Number.MAX_SAFE_INTEGER);if(bn<Number.MIN_SAFE_INTEGER)return new Pe(Number.MIN_SAFE_INTEGER);var In=Math.max(Ne(this.number),Ne(_t));return new Pe(bn.toFixed(In))}},{key:"multi",value:function(St){var _t=Number(St);if(this.isInvalidate()||Number.isNaN(_t))return new Pe(NaN);var bn=this.number*_t;if(bn>Number.MAX_SAFE_INTEGER)return new Pe(Number.MAX_SAFE_INTEGER);if(bn<Number.MIN_SAFE_INTEGER)return new Pe(Number.MIN_SAFE_INTEGER);var In=Math.max(Ne(this.number),Ne(_t));return new Pe(bn.toFixed(In))}},{key:"isEmpty",value:function(){return this.empty}},{key:"isNaN",value:function(){return Number.isNaN(this.number)}},{key:"isInvalidate",value:function(){return this.isEmpty()||this.isNaN()}},{key:"equals",value:function(St){return this.toNumber()===(St==null?void 0:St.toNumber())}},{key:"lessEquals",value:function(St){return this.add(St.negate().toString()).toNumber()<=0}},{key:"toNumber",value:function(){return this.number}},{key:"toString",value:function(){var St=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;return St?this.isInvalidate()?"":dt(this.number):this.origin}}]),Pe}();function st(Pe){return yt()?new Bt(Pe):new mt(Pe)}function it(Pe,rt,St){var _t=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1;if(Pe==="")return"";var bn=Le(Pe),In=bn.negativeStr,rr=bn.integerStr,Xn=bn.decimalStr,Cn="".concat(rt).concat(Xn),Fn="".concat(In).concat(rr);if(St>=0){var xt=Number(Xn[St]);if(xt>=5&&!_t){var $t=st(Pe).add("".concat(In,"0.").concat("0".repeat(St)).concat(10-xt));return it($t.toString(),rt,St,_t)}return St===0?Fn:"".concat(Fn).concat(rt).concat(Xn.padEnd(St,"0").slice(0,St))}return Cn===".0"?Fn:"".concat(Fn).concat(Cn)}var je=st,Ot=ie(36901),nt=ie(34280);function tt(Pe,rt){return typeof Proxy!="undefined"&&Pe?new Proxy(Pe,{get:function(_t,bn){if(rt[bn])return rt[bn];var In=_t[bn];return typeof In=="function"?In.bind(_t):In}}):Pe}var ht=ie(8654),$e=ie(48736);function at(Pe,rt){var St=(0,z.useRef)(null);function _t(){try{var In=Pe.selectionStart,rr=Pe.selectionEnd,Xn=Pe.value,Cn=Xn.substring(0,In),Fn=Xn.substring(rr);St.current={start:In,end:rr,value:Xn,beforeTxt:Cn,afterTxt:Fn}}catch(xt){}}function bn(){if(Pe&&St.current&&rt)try{var In=Pe.value,rr=St.current,Xn=rr.beforeTxt,Cn=rr.afterTxt,Fn=rr.start,xt=In.length;if(In.startsWith(Xn))xt=Xn.length;else if(In.endsWith(Cn))xt=In.length-St.current.afterTxt.length;else{var $t=Xn[Fn-1],vt=In.indexOf($t,Fn-1);vt!==-1&&(xt=vt+1)}Pe.setSelectionRange(xt,xt)}catch(Vt){(0,$e.ZP)(!1,"Something warning of cursor restore. Please fire issue about this: ".concat(Vt.message))}}return[_t,bn]}var lt=ie(49658),me=function(){var rt=(0,z.useState)(!1),St=(0,Oe.Z)(rt,2),_t=St[0],bn=St[1];return(0,nt.Z)(function(){bn((0,lt.Z)())},[]),_t},At=me,De=ie(16089),He=200,Pt=600;function ge(Pe){var rt=Pe.prefixCls,St=Pe.upNode,_t=Pe.downNode,bn=Pe.upDisabled,In=Pe.downDisabled,rr=Pe.onStep,Xn=z.useRef(),Cn=z.useRef([]),Fn=z.useRef();Fn.current=rr;var xt=function(){clearTimeout(Xn.current)},$t=function(Bn,Zn){Bn.preventDefault(),xt(),Fn.current(Zn);function Yn(){Fn.current(Zn),Xn.current=setTimeout(Yn,He)}Xn.current=setTimeout(Yn,Pt)};z.useEffect(function(){return function(){xt(),Cn.current.forEach(function(wn){return De.Z.cancel(wn)})}},[]);var vt=At();if(vt)return null;var Vt="".concat(rt,"-handler"),Ut=ye()(Vt,"".concat(Vt,"-up"),(0,Me.Z)({},"".concat(Vt,"-up-disabled"),bn)),En=ye()(Vt,"".concat(Vt,"-down"),(0,Me.Z)({},"".concat(Vt,"-down-disabled"),In)),mn=function(){return Cn.current.push((0,De.Z)(xt))},xn={unselectable:"on",role:"button",onMouseUp:mn,onMouseLeave:mn};return z.createElement("div",{className:"".concat(Vt,"-wrap")},z.createElement("span",(0,be.Z)({},xn,{onMouseDown:function(Bn){$t(Bn,!0)},"aria-label":"Increase Value","aria-disabled":bn,className:Ut}),St||z.createElement("span",{unselectable:"on",className:"".concat(rt,"-handler-up-inner")})),z.createElement("span",(0,be.Z)({},xn,{onMouseDown:function(Bn){$t(Bn,!1)},"aria-label":"Decrease Value","aria-disabled":In,className:En}),_t||z.createElement("span",{unselectable:"on",className:"".concat(rt,"-handler-down-inner")})))}function ce(Pe){var rt=typeof Pe=="number"?dt(Pe):Le(Pe).fullStr,St=rt.includes(".");return St?Le(rt.replace(/(\d)\.(\d)/g,"$1$2.")).fullStr:Pe+"0"}var Je=ie(30292),jt=function(){var Pe=(0,z.useRef)(0),rt=function(){De.Z.cancel(Pe.current)};return(0,z.useEffect)(function(){return rt},[]),function(St){rt(),Pe.current=(0,De.Z)(function(){St()})}},wt=["prefixCls","className","style","min","max","step","defaultValue","value","disabled","readOnly","upHandler","downHandler","keyboard","changeOnWheel","controls","classNames","stringMode","parser","formatter","precision","decimalSeparator","onChange","onInput","onPressEnter","onStep","changeOnBlur","domRef"],Ie=["disabled","style","prefixCls","value","prefix","suffix","addonBefore","addonAfter","className","classNames"],Ue=function(rt,St){return rt||St.isEmpty()?St.toString():St.toNumber()},et=function(rt){var St=je(rt);return St.isInvalidate()?null:St},cn=z.forwardRef(function(Pe,rt){var St=Pe.prefixCls,_t=Pe.className,bn=Pe.style,In=Pe.min,rr=Pe.max,Xn=Pe.step,Cn=Xn===void 0?1:Xn,Fn=Pe.defaultValue,xt=Pe.value,$t=Pe.disabled,vt=Pe.readOnly,Vt=Pe.upHandler,Ut=Pe.downHandler,En=Pe.keyboard,mn=Pe.changeOnWheel,xn=mn===void 0?!1:mn,wn=Pe.controls,Bn=wn===void 0?!0:wn,Zn=Pe.classNames,Yn=Pe.stringMode,Wn=Pe.parser,ir=Pe.formatter,gn=Pe.precision,Dt=Pe.decimalSeparator,Qt=Pe.onChange,Un=Pe.onInput,fr=Pe.onPressEnter,ke=Pe.onStep,_e=Pe.changeOnBlur,Ce=_e===void 0?!0:_e,Be=Pe.domRef,we=(0,fe.Z)(Pe,wt),Te="".concat(St,"-input"),Qe=z.useRef(null),nn=z.useState(!1),sn=(0,Oe.Z)(nn,2),Xt=sn[0],Ht=sn[1],Ct=z.useRef(!1),pt=z.useRef(!1),un=z.useRef(!1),$n=z.useState(function(){return je(xt!=null?xt:Fn)}),Dn=(0,Oe.Z)($n,2),kn=Dn[0],pr=Dn[1];function gt(pn){xt===void 0&&pr(pn)}var Ve=z.useCallback(function(pn,Jt){if(!Jt)return gn>=0?gn:Math.max(Ne(pn),Ne(Cn))},[gn,Cn]),Et=z.useCallback(function(pn){var Jt=String(pn);if(Wn)return Wn(Jt);var zn=Jt;return Dt&&(zn=zn.replace(Dt,".")),zn.replace(/[^\w.-]+/g,"")},[Wn,Dt]),Rt=z.useRef(""),Zt=z.useCallback(function(pn,Jt){if(ir)return ir(pn,{userTyping:Jt,input:String(Rt.current)});var zn=typeof pn=="number"?dt(pn):pn;if(!Jt){var _n=Ve(zn,Jt);if(It(zn)&&(Dt||_n>=0)){var an=Dt||".";zn=it(zn,an,_n)}}return zn},[ir,Ve,Dt]),hn=z.useState(function(){var pn=Fn!=null?Fn:xt;return kn.isInvalidate()&&["string","number"].includes((0,Re.Z)(pn))?Number.isNaN(pn)?"":pn:Zt(kn.toString(),!1)}),Hn=(0,Oe.Z)(hn,2),Sn=Hn[0],Tn=Hn[1];Rt.current=Sn;function An(pn,Jt){Tn(Zt(pn.isInvalidate()?pn.toString(!1):pn.toString(!Jt),Jt))}var jn=z.useMemo(function(){return et(rr)},[rr,gn]),Pn=z.useMemo(function(){return et(In)},[In,gn]),lr=z.useMemo(function(){return!jn||!kn||kn.isInvalidate()?!1:jn.lessEquals(kn)},[jn,kn]),Jn=z.useMemo(function(){return!Pn||!kn||kn.isInvalidate()?!1:kn.lessEquals(Pn)},[Pn,kn]),Kn=at(Qe.current,Xt),sr=(0,Oe.Z)(Kn,2),mr=sr[0],Qn=sr[1],cr=function(Jt){return jn&&!Jt.lessEquals(jn)?jn:Pn&&!Pn.lessEquals(Jt)?Pn:null},Gn=function(Jt){return!cr(Jt)},vr=function(Jt,zn){var _n=Jt,an=Gn(_n)||_n.isEmpty();if(!_n.isEmpty()&&!zn&&(_n=cr(_n)||_n,an=!0),!vt&&!$t&&an){var dn=_n.toString(),Nn=Ve(dn,zn);return Nn>=0&&(_n=je(it(dn,".",Nn)),Gn(_n)||(_n=je(it(dn,".",Nn,!0)))),_n.equals(kn)||(gt(_n),Qt==null||Qt(_n.isEmpty()?null:Ue(Yn,_n)),xt===void 0&&An(_n,zn)),_n}return kn},qn=jt(),Sr=function pn(Jt){if(mr(),Rt.current=Jt,Tn(Jt),!pt.current){var zn=Et(Jt),_n=je(zn);_n.isNaN()||vr(_n,!0)}Un==null||Un(Jt),qn(function(){var an=Jt;Wn||(an=Jt.replace(/。/g,".")),an!==Jt&&pn(an)})},ar=function(){pt.current=!0},or=function(){pt.current=!1,Sr(Qe.current.value)},hr=function(Jt){Sr(Jt.target.value)},xr=function(Jt){var zn;if(!(Jt&&lr||!Jt&&Jn)){Ct.current=!1;var _n=je(un.current?ce(Cn):Cn);Jt||(_n=_n.negate());var an=(kn||je(0)).add(_n.toString()),dn=vr(an,!1);ke==null||ke(Ue(Yn,dn),{offset:un.current?ce(Cn):Cn,type:Jt?"up":"down"}),(zn=Qe.current)===null||zn===void 0||zn.focus()}},br=function(Jt){var zn=je(Et(Sn)),_n;zn.isNaN()?_n=vr(kn,Jt):_n=vr(zn,Jt),xt!==void 0?An(kn,!1):_n.isNaN()||An(_n,!1)},dr=function(){Ct.current=!0},er=function(Jt){var zn=Jt.key,_n=Jt.shiftKey;Ct.current=!0,un.current=_n,zn==="Enter"&&(pt.current||(Ct.current=!1),br(!1),fr==null||fr(Jt)),En!==!1&&!pt.current&&["Up","ArrowUp","Down","ArrowDown"].includes(zn)&&(xr(zn==="Up"||zn==="ArrowUp"),Jt.preventDefault())},tn=function(){Ct.current=!1,un.current=!1};z.useEffect(function(){if(xn&&Xt){var pn=function(_n){xr(_n.deltaY<0),_n.preventDefault()},Jt=Qe.current;if(Jt)return Jt.addEventListener("wheel",pn,{passive:!1}),function(){return Jt.removeEventListener("wheel",pn)}}});var fn=function(){Ce&&br(!1),Ht(!1),Ct.current=!1};return(0,nt.o)(function(){kn.isInvalidate()||An(kn,!1)},[gn,ir]),(0,nt.o)(function(){var pn=je(xt);pr(pn);var Jt=je(Et(Sn));(!pn.equals(Jt)||!Ct.current||ir)&&An(pn,Ct.current)},[xt]),(0,nt.o)(function(){ir&&Qn()},[Sn]),z.createElement("div",{ref:Be,className:ye()(St,_t,(0,Me.Z)((0,Me.Z)((0,Me.Z)((0,Me.Z)((0,Me.Z)({},"".concat(St,"-focused"),Xt),"".concat(St,"-disabled"),$t),"".concat(St,"-readonly"),vt),"".concat(St,"-not-a-number"),kn.isNaN()),"".concat(St,"-out-of-range"),!kn.isInvalidate()&&!Gn(kn))),style:bn,onFocus:function(){Ht(!0)},onBlur:fn,onKeyDown:er,onKeyUp:tn,onCompositionStart:ar,onCompositionEnd:or,onBeforeInput:dr},Bn&&z.createElement(ge,{prefixCls:St,upNode:Vt,downNode:Ut,upDisabled:lr,downDisabled:Jn,onStep:xr}),z.createElement("div",{className:"".concat(Te,"-wrap")},z.createElement("input",(0,be.Z)({autoComplete:"off",role:"spinbutton","aria-valuemin":In,"aria-valuemax":rr,"aria-valuenow":kn.isInvalidate()?null:kn.toString(),step:Cn},we,{ref:(0,ht.sQ)(Qe,rt),className:Te,value:Sn,onChange:hr,disabled:$t,readOnly:vt}))))}),kt=z.forwardRef(function(Pe,rt){var St=Pe.disabled,_t=Pe.style,bn=Pe.prefixCls,In=bn===void 0?"rc-input-number":bn,rr=Pe.value,Xn=Pe.prefix,Cn=Pe.suffix,Fn=Pe.addonBefore,xt=Pe.addonAfter,$t=Pe.className,vt=Pe.classNames,Vt=(0,fe.Z)(Pe,Ie),Ut=z.useRef(null),En=z.useRef(null),mn=z.useRef(null),xn=function(Bn){mn.current&&(0,Je.nH)(mn.current,Bn)};return z.useImperativeHandle(rt,function(){return tt(mn.current,{focus:xn,nativeElement:Ut.current.nativeElement||En.current})}),z.createElement(Ot.BaseInput,{className:$t,triggerFocus:xn,prefixCls:In,value:rr,disabled:St,style:_t,prefix:Xn,suffix:Cn,addonAfter:xt,addonBefore:Fn,classNames:vt,components:{affixWrapper:"div",groupWrapper:"div",wrapper:"div",groupAddon:"div"},ref:Ut},z.createElement(cn,(0,be.Z)({prefixCls:In,disabled:St,ref:mn,domRef:En,className:vt==null?void 0:vt.input},Vt)))}),Yt=kt,ze=Yt,zt=ie(62487),ut=ie(82855),ae=ie(48755),te=ie(60840),ee=ie(2171),oe=ie(83397),se=ie(31756),ne=ie(56553),he=ie(24971),xe=ie(70045),ot=ie(36237),Ee=ie(53075),Fe=ie(64910),qe=ie(39082),bt=ie(63356),ct=ie(56119),Kt=ie(16931),Wt=ie(51636),Nt=ie(17835);const rn=Pe=>{var rt;const St=(rt=Pe.handleVisible)!==null&&rt!==void 0?rt:"auto",_t=Pe.controlHeightSM-Pe.lineWidth*2;return Object.assign(Object.assign({},(0,Fe.T)(Pe)),{controlWidth:90,handleWidth:_t,handleFontSize:Pe.fontSize/2,handleVisible:St,handleActiveBg:Pe.colorFillAlter,handleBg:Pe.colorBgContainer,filledHandleBg:new Nt.FastColor(Pe.colorFillSecondary).onBackground(Pe.colorBgContainer).toHexString(),handleHoverColor:Pe.colorPrimary,handleBorderColor:Pe.colorBorder,handleOpacity:St===!0?1:0,handleVisibleWidth:St===!0?_t:0})},qt=(Pe,rt)=>{let{componentCls:St,borderRadiusSM:_t,borderRadiusLG:bn}=Pe;const In=rt==="lg"?bn:_t;return{[`&-${rt}`]:{[`${St}-handler-wrap`]:{borderStartEndRadius:In,borderEndEndRadius:In},[`${St}-handler-up`]:{borderStartEndRadius:In},[`${St}-handler-down`]:{borderEndEndRadius:In}}}},on=Pe=>{const{componentCls:rt,lineWidth:St,lineType:_t,borderRadius:bn,inputFontSizeSM:In,inputFontSizeLG:rr,controlHeightLG:Xn,controlHeightSM:Cn,colorError:Fn,paddingInlineSM:xt,paddingBlockSM:$t,paddingBlockLG:vt,paddingInlineLG:Vt,colorTextDescription:Ut,motionDurationMid:En,handleHoverColor:mn,handleOpacity:xn,paddingInline:wn,paddingBlock:Bn,handleBg:Zn,handleActiveBg:Yn,colorTextDisabled:Wn,borderRadiusSM:ir,borderRadiusLG:gn,controlWidth:Dt,handleBorderColor:Qt,filledHandleBg:Un,lineHeightLG:fr,calc:ke}=Pe;return[{[rt]:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},(0,bt.Wf)(Pe)),(0,Ee.ik)(Pe)),{display:"inline-block",width:Dt,margin:0,padding:0,borderRadius:bn}),(0,qe.qG)(Pe,{[`${rt}-handler-wrap`]:{background:Zn,[`${rt}-handler-down`]:{borderBlockStart:`${(0,ot.unit)(St)} ${_t} ${Qt}`}}})),(0,qe.H8)(Pe,{[`${rt}-handler-wrap`]:{background:Un,[`${rt}-handler-down`]:{borderBlockStart:`${(0,ot.unit)(St)} ${_t} ${Qt}`}},"&:focus-within":{[`${rt}-handler-wrap`]:{background:Zn}}})),(0,qe.vc)(Pe,{[`${rt}-handler-wrap`]:{background:Zn,[`${rt}-handler-down`]:{borderBlockStart:`${(0,ot.unit)(St)} ${_t} ${Qt}`}}})),(0,qe.Mu)(Pe)),{"&-rtl":{direction:"rtl",[`${rt}-input`]:{direction:"rtl"}},"&-lg":{padding:0,fontSize:rr,lineHeight:fr,borderRadius:gn,[`input${rt}-input`]:{height:ke(Xn).sub(ke(St).mul(2)).equal(),padding:`${(0,ot.unit)(vt)} ${(0,ot.unit)(Vt)}`}},"&-sm":{padding:0,fontSize:In,borderRadius:ir,[`input${rt}-input`]:{height:ke(Cn).sub(ke(St).mul(2)).equal(),padding:`${(0,ot.unit)($t)} ${(0,ot.unit)(xt)}`}},"&-out-of-range":{[`${rt}-input-wrap`]:{input:{color:Fn}}},"&-group":Object.assign(Object.assign(Object.assign({},(0,bt.Wf)(Pe)),(0,Ee.s7)(Pe)),{"&-wrapper":Object.assign(Object.assign(Object.assign({display:"inline-block",textAlign:"start",verticalAlign:"top",[`${rt}-affix-wrapper`]:{width:"100%"},"&-lg":{[`${rt}-group-addon`]:{borderRadius:gn,fontSize:Pe.fontSizeLG}},"&-sm":{[`${rt}-group-addon`]:{borderRadius:ir}}},(0,qe.ir)(Pe)),(0,qe.S5)(Pe)),{[`&:not(${rt}-compact-first-item):not(${rt}-compact-last-item)${rt}-compact-item`]:{[`${rt}, ${rt}-group-addon`]:{borderRadius:0}},[`&:not(${rt}-compact-last-item)${rt}-compact-first-item`]:{[`${rt}, ${rt}-group-addon`]:{borderStartEndRadius:0,borderEndEndRadius:0}},[`&:not(${rt}-compact-first-item)${rt}-compact-last-item`]:{[`${rt}, ${rt}-group-addon`]:{borderStartStartRadius:0,borderEndStartRadius:0}}})}),[`&-disabled ${rt}-input`]:{cursor:"not-allowed"},[rt]:{"&-input":Object.assign(Object.assign(Object.assign(Object.assign({},(0,bt.Wf)(Pe)),{width:"100%",padding:`${(0,ot.unit)(Bn)} ${(0,ot.unit)(wn)}`,textAlign:"start",backgroundColor:"transparent",border:0,borderRadius:bn,outline:0,transition:`all ${En} linear`,appearance:"textfield",fontSize:"inherit"}),(0,Ee.nz)(Pe.colorTextPlaceholder)),{'&[type="number"]::-webkit-inner-spin-button, &[type="number"]::-webkit-outer-spin-button':{margin:0,appearance:"none"}})},[`&:hover ${rt}-handler-wrap, &-focused ${rt}-handler-wrap`]:{width:Pe.handleWidth,opacity:1}})},{[rt]:Object.assign(Object.assign(Object.assign({[`${rt}-handler-wrap`]:{position:"absolute",insetBlockStart:0,insetInlineEnd:0,width:Pe.handleVisibleWidth,opacity:xn,height:"100%",borderStartStartRadius:0,borderStartEndRadius:bn,borderEndEndRadius:bn,borderEndStartRadius:0,display:"flex",flexDirection:"column",alignItems:"stretch",transition:`all ${En}`,overflow:"hidden",[`${rt}-handler`]:{display:"flex",alignItems:"center",justifyContent:"center",flex:"auto",height:"40%",[`
|
|
|
${rt}-handler-up-inner,
|
|
|
${rt}-handler-down-inner
|
|
|
`]:{marginInlineEnd:0,fontSize:Pe.handleFontSize}}},[`${rt}-handler`]:{height:"50%",overflow:"hidden",color:Ut,fontWeight:"bold",lineHeight:0,textAlign:"center",cursor:"pointer",borderInlineStart:`${(0,ot.unit)(St)} ${_t} ${Qt}`,transition:`all ${En} linear`,"&:active":{background:Yn},"&:hover":{height:"60%",[`
|
|
|
${rt}-handler-up-inner,
|
|
|
${rt}-handler-down-inner
|
|
|
`]:{color:mn}},"&-up-inner, &-down-inner":Object.assign(Object.assign({},(0,bt.Ro)()),{color:Ut,transition:`all ${En} linear`,userSelect:"none"})},[`${rt}-handler-up`]:{borderStartEndRadius:bn},[`${rt}-handler-down`]:{borderEndEndRadius:bn}},qt(Pe,"lg")),qt(Pe,"sm")),{"&-disabled, &-readonly":{[`${rt}-handler-wrap`]:{display:"none"},[`${rt}-input`]:{color:"inherit"}},[`
|
|
|
${rt}-handler-up-disabled,
|
|
|
${rt}-handler-down-disabled
|
|
|
`]:{cursor:"not-allowed"},[`
|
|
|
${rt}-handler-up-disabled:hover &-handler-up-inner,
|
|
|
${rt}-handler-down-disabled:hover &-handler-down-inner
|
|
|
`]:{color:Wn}})}]},ft=Pe=>{const{componentCls:rt,paddingBlock:St,paddingInline:_t,inputAffixPadding:bn,controlWidth:In,borderRadiusLG:rr,borderRadiusSM:Xn,paddingInlineLG:Cn,paddingInlineSM:Fn,paddingBlockLG:xt,paddingBlockSM:$t,motionDurationMid:vt}=Pe;return{[`${rt}-affix-wrapper`]:Object.assign(Object.assign({[`input${rt}-input`]:{padding:`${(0,ot.unit)(St)} 0`}},(0,Ee.ik)(Pe)),{position:"relative",display:"inline-flex",alignItems:"center",width:In,padding:0,paddingInlineStart:_t,"&-lg":{borderRadius:rr,paddingInlineStart:Cn,[`input${rt}-input`]:{padding:`${(0,ot.unit)(xt)} 0`}},"&-sm":{borderRadius:Xn,paddingInlineStart:Fn,[`input${rt}-input`]:{padding:`${(0,ot.unit)($t)} 0`}},[`&:not(${rt}-disabled):hover`]:{zIndex:1},"&-focused, &:focus":{zIndex:1},[`&-disabled > ${rt}-disabled`]:{background:"transparent"},[`> div${rt}`]:{width:"100%",border:"none",outline:"none",[`&${rt}-focused`]:{boxShadow:"none !important"}},"&::before":{display:"inline-block",width:0,visibility:"hidden",content:'"\\a0"'},[`${rt}-handler-wrap`]:{zIndex:2},[rt]:{position:"static",color:"inherit","&-prefix, &-suffix":{display:"flex",flex:"none",alignItems:"center",pointerEvents:"none"},"&-prefix":{marginInlineEnd:bn},"&-suffix":{insetBlockStart:0,insetInlineEnd:0,height:"100%",marginInlineEnd:_t,marginInlineStart:bn,transition:`margin ${vt}`}},[`&:hover ${rt}-handler-wrap, &-focused ${rt}-handler-wrap`]:{width:Pe.handleWidth,opacity:1},[`&:not(${rt}-affix-wrapper-without-controls):hover ${rt}-suffix`]:{marginInlineEnd:Pe.calc(Pe.handleWidth).add(_t).equal()}})}};var Gt=(0,Kt.I$)("InputNumber",Pe=>{const rt=(0,Wt.mergeToken)(Pe,(0,Fe.e)(Pe));return[on(rt),ft(rt),(0,ct.c)(rt)]},rn,{unitless:{handleOpacity:!0}}),Tt=function(Pe,rt){var St={};for(var _t in Pe)Object.prototype.hasOwnProperty.call(Pe,_t)&&rt.indexOf(_t)<0&&(St[_t]=Pe[_t]);if(Pe!=null&&typeof Object.getOwnPropertySymbols=="function")for(var bn=0,_t=Object.getOwnPropertySymbols(Pe);bn<_t.length;bn++)rt.indexOf(_t[bn])<0&&Object.prototype.propertyIsEnumerable.call(Pe,_t[bn])&&(St[_t[bn]]=Pe[_t[bn]]);return St};const en=z.forwardRef((Pe,rt)=>{const{getPrefixCls:St,direction:_t}=z.useContext(ae.E_),bn=z.useRef(null);z.useImperativeHandle(rt,()=>bn.current);const{className:In,rootClassName:rr,size:Xn,disabled:Cn,prefixCls:Fn,addonBefore:xt,addonAfter:$t,prefix:vt,suffix:Vt,bordered:Ut,readOnly:En,status:mn,controls:xn,variant:wn}=Pe,Bn=Tt(Pe,["className","rootClassName","size","disabled","prefixCls","addonBefore","addonAfter","prefix","suffix","bordered","readOnly","status","controls","variant"]),Zn=St("input-number",Fn),Yn=(0,oe.Z)(Zn),[Wn,ir,gn]=Gt(Zn,Yn),{compactSize:Dt,compactItemClassnames:Qt}=(0,xe.ri)(Zn,_t);let Un=z.createElement(ve.Z,{className:`${Zn}-handler-up-inner`}),fr=z.createElement(Ke.Z,{className:`${Zn}-handler-down-inner`});const ke=typeof xn=="boolean"?xn:void 0;typeof xn=="object"&&(Un=typeof xn.upIcon=="undefined"?Un:z.createElement("span",{className:`${Zn}-handler-up-inner`},xn.upIcon),fr=typeof xn.downIcon=="undefined"?fr:z.createElement("span",{className:`${Zn}-handler-down-inner`},xn.downIcon));const{hasFeedback:_e,status:Ce,isFormItemInput:Be,feedbackIcon:we}=z.useContext(ne.aM),Te=(0,ut.F)(Ce,mn),Qe=(0,se.Z)(Dn=>{var kn;return(kn=Xn!=null?Xn:Dt)!==null&&kn!==void 0?kn:Dn}),nn=z.useContext(ee.Z),sn=Cn!=null?Cn:nn,[Xt,Ht]=(0,he.Z)("inputNumber",wn,Ut),Ct=_e&&z.createElement(z.Fragment,null,we),pt=ye()({[`${Zn}-lg`]:Qe==="large",[`${Zn}-sm`]:Qe==="small",[`${Zn}-rtl`]:_t==="rtl",[`${Zn}-in-form-item`]:Be},ir),un=`${Zn}-group`,$n=z.createElement(ze,Object.assign({ref:bn,disabled:sn,className:ye()(gn,Yn,In,rr,Qt),upHandler:Un,downHandler:fr,prefixCls:Zn,readOnly:En,controls:ke,prefix:vt,suffix:Ct||Vt,addonBefore:xt&&z.createElement(zt.Z,{form:!0,space:!0},xt),addonAfter:$t&&z.createElement(zt.Z,{form:!0,space:!0},$t),classNames:{input:pt,variant:ye()({[`${Zn}-${Xt}`]:Ht},(0,ut.Z)(Zn,Te,_e)),affixWrapper:ye()({[`${Zn}-affix-wrapper-sm`]:Qe==="small",[`${Zn}-affix-wrapper-lg`]:Qe==="large",[`${Zn}-affix-wrapper-rtl`]:_t==="rtl",[`${Zn}-affix-wrapper-without-controls`]:xn===!1||sn},ir),wrapper:ye()({[`${un}-rtl`]:_t==="rtl"},ir),groupWrapper:ye()({[`${Zn}-group-wrapper-sm`]:Qe==="small",[`${Zn}-group-wrapper-lg`]:Qe==="large",[`${Zn}-group-wrapper-rtl`]:_t==="rtl",[`${Zn}-group-wrapper-${Xt}`]:Ht},(0,ut.Z)(`${Zn}-group-wrapper`,Te,_e),ir)}},Bn));return Wn($n)}),yn=en,Rn=Pe=>z.createElement(te.ZP,{theme:{components:{InputNumber:{handleVisible:!0}}}},z.createElement(en,Object.assign({},Pe)));yn._InternalPanelDoNotUseOrYouWillBeFired=Rn;var On=yn},49397:function(ln,Ft,ie){"use strict";ie.d(Ft,{Z:function(){return mt}});var z=ie(59301),Ke=ie(92310),ve=ie.n(Ke),Ae=ie(36901),ye=ie(8654),be=ie(62487),Me=ie(86013),Re=ie(82855),Oe=ie(48755),fe=ie(2171),We=ie(83397),Se=ie(31756),yt=ie(56553),Xe=ie(24971),Le=ie(70045),Ge=ie(23826),Ne=ie(53075);function dt(st){return!!(st.prefix||st.suffix||st.allowClear||st.showCount)}var It=function(st,it){var je={};for(var Ot in st)Object.prototype.hasOwnProperty.call(st,Ot)&&it.indexOf(Ot)<0&&(je[Ot]=st[Ot]);if(st!=null&&typeof Object.getOwnPropertySymbols=="function")for(var nt=0,Ot=Object.getOwnPropertySymbols(st);nt<Ot.length;nt++)it.indexOf(Ot[nt])<0&&Object.prototype.propertyIsEnumerable.call(st,Ot[nt])&&(je[Ot[nt]]=st[Ot[nt]]);return je},mt=(0,z.forwardRef)((st,it)=>{const{prefixCls:je,bordered:Ot=!0,status:nt,size:tt,disabled:ht,onBlur:$e,onFocus:at,suffix:lt,allowClear:me,addonAfter:At,addonBefore:De,className:He,style:Pt,styles:ge,rootClassName:ce,onChange:Je,classNames:jt,variant:wt}=st,Ie=It(st,["prefixCls","bordered","status","size","disabled","onBlur","onFocus","suffix","allowClear","addonAfter","addonBefore","className","style","styles","rootClassName","onChange","classNames","variant"]),{getPrefixCls:Ue,direction:et,allowClear:cn,autoComplete:kt,className:Yt,style:ze,classNames:zt,styles:ut}=(0,Oe.dj)("input"),ae=Ue("input",je),te=(0,z.useRef)(null),ee=(0,We.Z)(ae),[oe,se,ne]=(0,Ne.TI)(ae,ce),[he]=(0,Ne.ZP)(ae,ee),{compactSize:xe,compactItemClassnames:ot}=(0,Le.ri)(ae,et),Ee=(0,Se.Z)(On=>{var Pe;return(Pe=tt!=null?tt:xe)!==null&&Pe!==void 0?Pe:On}),Fe=z.useContext(fe.Z),qe=ht!=null?ht:Fe,{status:bt,hasFeedback:ct,feedbackIcon:Kt}=(0,z.useContext)(yt.aM),Wt=(0,Re.F)(bt,nt),Nt=dt(st)||!!ct,rn=(0,z.useRef)(Nt),qt=(0,Ge.Z)(te,!0),on=On=>{qt(),$e==null||$e(On)},ft=On=>{qt(),at==null||at(On)},Gt=On=>{qt(),Je==null||Je(On)},Tt=(ct||lt)&&z.createElement(z.Fragment,null,lt,ct&&Kt),en=(0,Me.Z)(me!=null?me:cn),[yn,Rn]=(0,Xe.Z)("input",wt,Ot);return oe(he(z.createElement(Ae.default,Object.assign({ref:(0,ye.sQ)(it,te),prefixCls:ae,autoComplete:kt},Ie,{disabled:qe,onBlur:on,onFocus:ft,style:Object.assign(Object.assign({},ze),Pt),styles:Object.assign(Object.assign({},ut),ge),suffix:Tt,allowClear:en,className:ve()(He,ce,ne,ee,ot,Yt),onChange:Gt,addonBefore:De&&z.createElement(be.Z,{form:!0,space:!0},De),addonAfter:At&&z.createElement(be.Z,{form:!0,space:!0},At),classNames:Object.assign(Object.assign(Object.assign({},jt),zt),{input:ve()({[`${ae}-sm`]:Ee==="small",[`${ae}-lg`]:Ee==="large",[`${ae}-rtl`]:et==="rtl"},jt==null?void 0:jt.input,zt.input,se),variant:ve()({[`${ae}-${yn}`]:Rn},(0,Re.Z)(ae,Wt)),affixWrapper:ve()({[`${ae}-affix-wrapper-sm`]:Ee==="small",[`${ae}-affix-wrapper-lg`]:Ee==="large",[`${ae}-affix-wrapper-rtl`]:et==="rtl"},se),wrapper:ve()({[`${ae}-group-rtl`]:et==="rtl"},se),groupWrapper:ve()({[`${ae}-group-wrapper-sm`]:Ee==="small",[`${ae}-group-wrapper-lg`]:Ee==="large",[`${ae}-group-wrapper-rtl`]:et==="rtl",[`${ae}-group-wrapper-${yn}`]:Rn},(0,Re.Z)(`${ae}-group-wrapper`,Wt,ct),se)})}))))})},79809:function(ln,Ft,ie){"use strict";ie.d(Ft,{Z:function(){return it}});var z=ie(59301),Ke=ie(92310),ve=ie.n(Ke),Ae=ie(22711),ye=ie(86013),be=ie(82855),Me=ie(48755),Re=ie(2171),Oe=ie(83397),fe=ie(31756),We=ie(56553),Se=ie(24971),yt=ie(70045),Xe=ie(30292),Le=ie(53075),Ge=ie(16931),Ne=ie(51636),dt=ie(64910);const It=je=>{const{componentCls:Ot,paddingLG:nt}=je,tt=`${Ot}-textarea`;return{[`textarea${Ot}`]:{maxWidth:"100%",height:"auto",minHeight:je.controlHeight,lineHeight:je.lineHeight,verticalAlign:"bottom",transition:`all ${je.motionDurationSlow}`,resize:"vertical",[`&${Ot}-mouse-active`]:{transition:`all ${je.motionDurationSlow}, height 0s, width 0s`}},[`${Ot}-textarea-affix-wrapper-resize-dirty`]:{width:"auto"},[tt]:{position:"relative","&-show-count":{[`> ${Ot}`]:{height:"100%"},[`${Ot}-data-count`]:{position:"absolute",bottom:je.calc(je.fontSize).mul(je.lineHeight).mul(-1).equal(),insetInlineEnd:0,color:je.colorTextDescription,whiteSpace:"nowrap",pointerEvents:"none"}},[`
|
|
|
&-allow-clear > ${Ot},
|
|
|
&-affix-wrapper${tt}-has-feedback ${Ot}
|
|
|
`]:{paddingInlineEnd:nt},[`&-affix-wrapper${Ot}-affix-wrapper`]:{padding:0,[`> textarea${Ot}`]:{fontSize:"inherit",border:"none",outline:"none",background:"transparent",minHeight:je.calc(je.controlHeight).sub(je.calc(je.lineWidth).mul(2)).equal(),"&:focus":{boxShadow:"none !important"}},[`${Ot}-suffix`]:{margin:0,"> *:not(:last-child)":{marginInline:0},[`${Ot}-clear-icon`]:{position:"absolute",insetInlineEnd:je.paddingInline,insetBlockStart:je.paddingXS},[`${tt}-suffix`]:{position:"absolute",top:0,insetInlineEnd:je.paddingInline,bottom:0,zIndex:1,display:"inline-flex",alignItems:"center",margin:"auto",pointerEvents:"none"}}},[`&-affix-wrapper${Ot}-affix-wrapper-sm`]:{[`${Ot}-suffix`]:{[`${Ot}-clear-icon`]:{insetInlineEnd:je.paddingInlineSM}}}}}};var Bt=(0,Ge.I$)(["Input","TextArea"],je=>{const Ot=(0,Ne.mergeToken)(je,(0,dt.e)(je));return[It(Ot)]},dt.T,{resetFont:!1}),mt=function(je,Ot){var nt={};for(var tt in je)Object.prototype.hasOwnProperty.call(je,tt)&&Ot.indexOf(tt)<0&&(nt[tt]=je[tt]);if(je!=null&&typeof Object.getOwnPropertySymbols=="function")for(var ht=0,tt=Object.getOwnPropertySymbols(je);ht<tt.length;ht++)Ot.indexOf(tt[ht])<0&&Object.prototype.propertyIsEnumerable.call(je,tt[ht])&&(nt[tt[ht]]=je[tt[ht]]);return nt},it=(0,z.forwardRef)((je,Ot)=>{var nt;const{prefixCls:tt,bordered:ht=!0,size:$e,disabled:at,status:lt,allowClear:me,classNames:At,rootClassName:De,className:He,style:Pt,styles:ge,variant:ce,showCount:Je,onMouseDown:jt,onResize:wt}=je,Ie=mt(je,["prefixCls","bordered","size","disabled","status","allowClear","classNames","rootClassName","className","style","styles","variant","showCount","onMouseDown","onResize"]),{getPrefixCls:Ue,direction:et,allowClear:cn,autoComplete:kt,className:Yt,style:ze,classNames:zt,styles:ut}=(0,Me.dj)("textArea"),ae=z.useContext(Re.Z),te=at!=null?at:ae,{status:ee,hasFeedback:oe,feedbackIcon:se}=z.useContext(We.aM),ne=(0,be.F)(ee,lt),he=z.useRef(null);z.useImperativeHandle(Ot,()=>{var Rn;return{resizableTextArea:(Rn=he.current)===null||Rn===void 0?void 0:Rn.resizableTextArea,focus:On=>{var Pe,rt;(0,Xe.nH)((rt=(Pe=he.current)===null||Pe===void 0?void 0:Pe.resizableTextArea)===null||rt===void 0?void 0:rt.textArea,On)},blur:()=>{var On;return(On=he.current)===null||On===void 0?void 0:On.blur()}}});const xe=Ue("input",tt),ot=(0,Oe.Z)(xe),[Ee,Fe,qe]=(0,Le.TI)(xe,De),[bt]=Bt(xe,ot),{compactSize:ct,compactItemClassnames:Kt}=(0,yt.ri)(xe,et),Wt=(0,fe.Z)(Rn=>{var On;return(On=$e!=null?$e:ct)!==null&&On!==void 0?On:Rn}),[Nt,rn]=(0,Se.Z)("textArea",ce,ht),qt=(0,ye.Z)(me!=null?me:cn),[on,ft]=z.useState(!1),[Gt,Tt]=z.useState(!1),en=Rn=>{ft(!0),jt==null||jt(Rn);const On=()=>{ft(!1),document.removeEventListener("mouseup",On)};document.addEventListener("mouseup",On)},yn=Rn=>{var On,Pe;if(wt==null||wt(Rn),on&&typeof getComputedStyle=="function"){const rt=(Pe=(On=he.current)===null||On===void 0?void 0:On.nativeElement)===null||Pe===void 0?void 0:Pe.querySelector("textarea");rt&&getComputedStyle(rt).resize==="both"&&Tt(!0)}};return Ee(bt(z.createElement(Ae.default,Object.assign({autoComplete:kt},Ie,{style:Object.assign(Object.assign({},ze),Pt),styles:Object.assign(Object.assign({},ut),ge),disabled:te,allowClear:qt,className:ve()(qe,ot,He,De,Kt,Yt,Gt&&`${xe}-textarea-affix-wrapper-resize-dirty`),classNames:Object.assign(Object.assign(Object.assign({},At),zt),{textarea:ve()({[`${xe}-sm`]:Wt==="small",[`${xe}-lg`]:Wt==="large"},Fe,At==null?void 0:At.textarea,zt.textarea,on&&`${xe}-mouse-active`),variant:ve()({[`${xe}-${Nt}`]:rn},(0,be.Z)(xe,ne)),affixWrapper:ve()(`${xe}-textarea-affix-wrapper`,{[`${xe}-affix-wrapper-rtl`]:et==="rtl",[`${xe}-affix-wrapper-sm`]:Wt==="small",[`${xe}-affix-wrapper-lg`]:Wt==="large",[`${xe}-textarea-show-count`]:Je||((nt=je.count)===null||nt===void 0?void 0:nt.show)},Fe)}),prefixCls:xe,suffix:oe&&z.createElement("span",{className:`${xe}-textarea-suffix`},se),showCount:Je,ref:he,onResize:yn,onMouseDown:en}))))})},23826:function(ln,Ft,ie){"use strict";ie.d(Ft,{Z:function(){return Ke}});var z=ie(59301);function Ke(ve,Ae){const ye=(0,z.useRef)([]),be=()=>{ye.current.push(setTimeout(()=>{var Me,Re,Oe,fe;!((Me=ve.current)===null||Me===void 0)&&Me.input&&((Re=ve.current)===null||Re===void 0?void 0:Re.input.getAttribute("type"))==="password"&&(!((Oe=ve.current)===null||Oe===void 0)&&Oe.input.hasAttribute("value"))&&((fe=ve.current)===null||fe===void 0||fe.input.removeAttribute("value"))}))};return(0,z.useEffect)(()=>(Ae&&be(),()=>ye.current.forEach(Me=>{Me&&clearTimeout(Me)})),[]),be}},37568:function(ln,Ft,ie){"use strict";ie.d(Ft,{default:function(){return zt}});var z=ie(59301),Ke=ie(92310),ve=ie.n(Ke),Ae=ie(48755),ye=ie(56553),be=ie(53075),Re=ut=>{const{getPrefixCls:ae,direction:te}=(0,z.useContext)(Ae.E_),{prefixCls:ee,className:oe}=ut,se=ae("input-group",ee),ne=ae("input"),[he,xe,ot]=(0,be.ZP)(ne),Ee=ve()(se,ot,{[`${se}-lg`]:ut.size==="large",[`${se}-sm`]:ut.size==="small",[`${se}-compact`]:ut.compact,[`${se}-rtl`]:te==="rtl"},xe,oe),Fe=(0,z.useContext)(ye.aM),qe=(0,z.useMemo)(()=>Object.assign(Object.assign({},Fe),{isFormItemInput:!1}),[Fe]);return he(z.createElement("span",{className:Ee,style:ut.style,onMouseEnter:ut.onMouseEnter,onMouseLeave:ut.onMouseLeave,onFocus:ut.onFocus,onBlur:ut.onBlur},z.createElement(ye.aM.Provider,{value:qe},ut.children)))},Oe=ie(49397),fe=ie(94480),We=ie(6089),Se=ie(26112),yt=ie(82855),Xe=ie(31756),Le=ie(16931),Ge=ie(51636),Ne=ie(64910);const dt=ut=>{const{componentCls:ae,paddingXS:te}=ut;return{[ae]:{display:"inline-flex",alignItems:"center",flexWrap:"nowrap",columnGap:te,"&-rtl":{direction:"rtl"},[`${ae}-input`]:{textAlign:"center",paddingInline:ut.paddingXXS},[`&${ae}-sm ${ae}-input`]:{paddingInline:ut.calc(ut.paddingXXS).div(2).equal()},[`&${ae}-lg ${ae}-input`]:{paddingInline:ut.paddingXS}}}};var It=(0,Le.I$)(["Input","OTP"],ut=>{const ae=(0,Ge.mergeToken)(ut,(0,Ne.e)(ut));return[dt(ae)]},Ne.T),Bt=ie(16089),mt=function(ut,ae){var te={};for(var ee in ut)Object.prototype.hasOwnProperty.call(ut,ee)&&ae.indexOf(ee)<0&&(te[ee]=ut[ee]);if(ut!=null&&typeof Object.getOwnPropertySymbols=="function")for(var oe=0,ee=Object.getOwnPropertySymbols(ut);oe<ee.length;oe++)ae.indexOf(ee[oe])<0&&Object.prototype.propertyIsEnumerable.call(ut,ee[oe])&&(te[ee[oe]]=ut[ee[oe]]);return te},it=z.forwardRef((ut,ae)=>{const{value:te,onChange:ee,onActiveChange:oe,index:se,mask:ne}=ut,he=mt(ut,["value","onChange","onActiveChange","index","mask"]),xe=te&&typeof ne=="string"?ne:te,ot=ct=>{ee(se,ct.target.value)},Ee=z.useRef(null);z.useImperativeHandle(ae,()=>Ee.current);const Fe=()=>{(0,Bt.Z)(()=>{var ct;const Kt=(ct=Ee.current)===null||ct===void 0?void 0:ct.input;document.activeElement===Kt&&Kt&&Kt.select()})},qe=ct=>{const{key:Kt,ctrlKey:Wt,metaKey:Nt}=ct;Kt==="ArrowLeft"?oe(se-1):Kt==="ArrowRight"?oe(se+1):Kt==="z"&&(Wt||Nt)&&ct.preventDefault(),Fe()},bt=ct=>{ct.key==="Backspace"&&!te&&oe(se-1),Fe()};return z.createElement(Oe.Z,Object.assign({type:ne===!0?"password":"text"},he,{ref:Ee,value:xe,onInput:ot,onFocus:Fe,onKeyDown:qe,onKeyUp:bt,onMouseDown:Fe,onMouseUp:Fe}))}),je=function(ut,ae){var te={};for(var ee in ut)Object.prototype.hasOwnProperty.call(ut,ee)&&ae.indexOf(ee)<0&&(te[ee]=ut[ee]);if(ut!=null&&typeof Object.getOwnPropertySymbols=="function")for(var oe=0,ee=Object.getOwnPropertySymbols(ut);oe<ee.length;oe++)ae.indexOf(ee[oe])<0&&Object.prototype.propertyIsEnumerable.call(ut,ee[oe])&&(te[ee[oe]]=ut[ee[oe]]);return te};function Ot(ut){return(ut||"").split("")}const nt=ut=>{const{index:ae,prefixCls:te,separator:ee}=ut,oe=typeof ee=="function"?ee(ae):ee;return oe?z.createElement("span",{className:`${te}-separator`},oe):null};var ht=z.forwardRef((ut,ae)=>{const{prefixCls:te,length:ee=6,size:oe,defaultValue:se,value:ne,onChange:he,formatter:xe,separator:ot,variant:Ee,disabled:Fe,status:qe,autoFocus:bt,mask:ct,type:Kt,onInput:Wt,inputMode:Nt}=ut,rn=je(ut,["prefixCls","length","size","defaultValue","value","onChange","formatter","separator","variant","disabled","status","autoFocus","mask","type","onInput","inputMode"]),{getPrefixCls:qt,direction:on}=z.useContext(Ae.E_),ft=qt("otp",te),Gt=(0,Se.Z)(rn,{aria:!0,data:!0,attr:!0}),[Tt,en,yn]=It(ft),Rn=(0,Xe.Z)(vt=>oe!=null?oe:vt),On=z.useContext(ye.aM),Pe=(0,yt.F)(On.status,qe),rt=z.useMemo(()=>Object.assign(Object.assign({},On),{status:Pe,hasFeedback:!1,feedbackIcon:null}),[On,Pe]),St=z.useRef(null),_t=z.useRef({});z.useImperativeHandle(ae,()=>({focus:()=>{var vt;(vt=_t.current[0])===null||vt===void 0||vt.focus()},blur:()=>{var vt;for(let Vt=0;Vt<ee;Vt+=1)(vt=_t.current[Vt])===null||vt===void 0||vt.blur()},nativeElement:St.current}));const bn=vt=>xe?xe(vt):vt,[In,rr]=z.useState(()=>Ot(bn(se||"")));z.useEffect(()=>{ne!==void 0&&rr(Ot(ne))},[ne]);const Xn=(0,We.Z)(vt=>{rr(vt),Wt&&Wt(vt),he&&vt.length===ee&&vt.every(Vt=>Vt)&&vt.some((Vt,Ut)=>In[Ut]!==Vt)&&he(vt.join(""))}),Cn=(0,We.Z)((vt,Vt)=>{let Ut=(0,fe.Z)(In);for(let mn=0;mn<vt;mn+=1)Ut[mn]||(Ut[mn]="");Vt.length<=1?Ut[vt]=Vt:Ut=Ut.slice(0,vt).concat(Ot(Vt)),Ut=Ut.slice(0,ee);for(let mn=Ut.length-1;mn>=0&&!Ut[mn];mn-=1)Ut.pop();const En=bn(Ut.map(mn=>mn||" ").join(""));return Ut=Ot(En).map((mn,xn)=>mn===" "&&!Ut[xn]?Ut[xn]:mn),Ut}),Fn=(vt,Vt)=>{var Ut;const En=Cn(vt,Vt),mn=Math.min(vt+Vt.length,ee-1);mn!==vt&&En[vt]!==void 0&&((Ut=_t.current[mn])===null||Ut===void 0||Ut.focus()),Xn(En)},xt=vt=>{var Vt;(Vt=_t.current[vt])===null||Vt===void 0||Vt.focus()},$t={variant:Ee,disabled:Fe,status:Pe,mask:ct,type:Kt,inputMode:Nt};return Tt(z.createElement("div",Object.assign({},Gt,{ref:St,className:ve()(ft,{[`${ft}-sm`]:Rn==="small",[`${ft}-lg`]:Rn==="large",[`${ft}-rtl`]:on==="rtl"},yn,en)}),z.createElement(ye.aM.Provider,{value:rt},Array.from({length:ee}).map((vt,Vt)=>{const Ut=`otp-${Vt}`,En=In[Vt]||"";return z.createElement(z.Fragment,{key:Ut},z.createElement(it,Object.assign({ref:mn=>{_t.current[Vt]=mn},index:Vt,size:Rn,htmlSize:1,className:`${ft}-input`,onChange:Fn,value:En,onActiveChange:xt,autoFocus:Vt===0&&bt},$t)),Vt<ee-1&&z.createElement(nt,{separator:ot,index:Vt,prefixCls:ft}))}))))}),$e=ie(73331),at=ie(15277),lt=ie(2738),me=ie(8654),At=ie(2171),De=ie(23826),He=function(ut,ae){var te={};for(var ee in ut)Object.prototype.hasOwnProperty.call(ut,ee)&&ae.indexOf(ee)<0&&(te[ee]=ut[ee]);if(ut!=null&&typeof Object.getOwnPropertySymbols=="function")for(var oe=0,ee=Object.getOwnPropertySymbols(ut);oe<ee.length;oe++)ae.indexOf(ee[oe])<0&&Object.prototype.propertyIsEnumerable.call(ut,ee[oe])&&(te[ee[oe]]=ut[ee[oe]]);return te};const Pt=ut=>ut?z.createElement(at.Z,null):z.createElement($e.Z,null),ge={click:"onClick",hover:"onMouseOver"};var Je=z.forwardRef((ut,ae)=>{const{disabled:te,action:ee="click",visibilityToggle:oe=!0,iconRender:se=Pt}=ut,ne=z.useContext(At.Z),he=te!=null?te:ne,xe=typeof oe=="object"&&oe.visible!==void 0,[ot,Ee]=(0,z.useState)(()=>xe?oe.visible:!1),Fe=(0,z.useRef)(null);z.useEffect(()=>{xe&&Ee(oe.visible)},[xe,oe]);const qe=(0,De.Z)(Fe),bt=()=>{var Rn;if(he)return;ot&&qe();const On=!ot;Ee(On),typeof oe=="object"&&((Rn=oe.onVisibleChange)===null||Rn===void 0||Rn.call(oe,On))},ct=Rn=>{const On=ge[ee]||"",Pe=se(ot),rt={[On]:bt,className:`${Rn}-icon`,key:"passwordIcon",onMouseDown:St=>{St.preventDefault()},onMouseUp:St=>{St.preventDefault()}};return z.cloneElement(z.isValidElement(Pe)?Pe:z.createElement("span",null,Pe),rt)},{className:Kt,prefixCls:Wt,inputPrefixCls:Nt,size:rn}=ut,qt=He(ut,["className","prefixCls","inputPrefixCls","size"]),{getPrefixCls:on}=z.useContext(Ae.E_),ft=on("input",Nt),Gt=on("input-password",Wt),Tt=oe&&ct(Gt),en=ve()(Gt,Kt,{[`${Gt}-${rn}`]:!!rn}),yn=Object.assign(Object.assign({},(0,lt.Z)(qt,["suffix","iconRender","visibilityToggle"])),{type:ot?"text":"password",className:en,prefixCls:ft,suffix:Tt});return rn&&(yn.size=rn),z.createElement(Oe.Z,Object.assign({ref:(0,me.sQ)(ae,Fe)},yn))}),jt=ie(47472),wt=ie(22703),Ie=ie(7939),Ue=ie(70045),et=function(ut,ae){var te={};for(var ee in ut)Object.prototype.hasOwnProperty.call(ut,ee)&&ae.indexOf(ee)<0&&(te[ee]=ut[ee]);if(ut!=null&&typeof Object.getOwnPropertySymbols=="function")for(var oe=0,ee=Object.getOwnPropertySymbols(ut);oe<ee.length;oe++)ae.indexOf(ee[oe])<0&&Object.prototype.propertyIsEnumerable.call(ut,ee[oe])&&(te[ee[oe]]=ut[ee[oe]]);return te},kt=z.forwardRef((ut,ae)=>{const{prefixCls:te,inputPrefixCls:ee,className:oe,size:se,suffix:ne,enterButton:he=!1,addonAfter:xe,loading:ot,disabled:Ee,onSearch:Fe,onChange:qe,onCompositionStart:bt,onCompositionEnd:ct}=ut,Kt=et(ut,["prefixCls","inputPrefixCls","className","size","suffix","enterButton","addonAfter","loading","disabled","onSearch","onChange","onCompositionStart","onCompositionEnd"]),{getPrefixCls:Wt,direction:Nt}=z.useContext(Ae.E_),rn=z.useRef(!1),qt=Wt("input-search",te),on=Wt("input",ee),{compactSize:ft}=(0,Ue.ri)(qt,Nt),Gt=(0,Xe.Z)(Fn=>{var xt;return(xt=se!=null?se:ft)!==null&&xt!==void 0?xt:Fn}),Tt=z.useRef(null),en=Fn=>{Fn!=null&&Fn.target&&Fn.type==="click"&&Fe&&Fe(Fn.target.value,Fn,{source:"clear"}),qe==null||qe(Fn)},yn=Fn=>{var xt;document.activeElement===((xt=Tt.current)===null||xt===void 0?void 0:xt.input)&&Fn.preventDefault()},Rn=Fn=>{var xt,$t;Fe&&Fe(($t=(xt=Tt.current)===null||xt===void 0?void 0:xt.input)===null||$t===void 0?void 0:$t.value,Fn,{source:"input"})},On=Fn=>{rn.current||ot||Rn(Fn)},Pe=typeof he=="boolean"?z.createElement(jt.Z,null):null,rt=`${qt}-button`;let St;const _t=he||{},bn=_t.type&&_t.type.__ANT_BUTTON===!0;bn||_t.type==="button"?St=(0,wt.Tm)(_t,Object.assign({onMouseDown:yn,onClick:Fn=>{var xt,$t;($t=(xt=_t==null?void 0:_t.props)===null||xt===void 0?void 0:xt.onClick)===null||$t===void 0||$t.call(xt,Fn),Rn(Fn)},key:"enterButton"},bn?{className:rt,size:Gt}:{})):St=z.createElement(Ie.ZP,{className:rt,type:he?"primary":void 0,size:Gt,disabled:Ee,key:"enterButton",onMouseDown:yn,onClick:Rn,loading:ot,icon:Pe},he),xe&&(St=[St,(0,wt.Tm)(xe,{key:"addonAfter"})]);const In=ve()(qt,{[`${qt}-rtl`]:Nt==="rtl",[`${qt}-${Gt}`]:!!Gt,[`${qt}-with-button`]:!!he},oe),rr=Object.assign(Object.assign({},Kt),{className:In,prefixCls:on,type:"search"}),Xn=Fn=>{rn.current=!0,bt==null||bt(Fn)},Cn=Fn=>{rn.current=!1,ct==null||ct(Fn)};return z.createElement(Oe.Z,Object.assign({ref:(0,me.sQ)(Tt,ae),onPressEnter:On},rr,{size:Gt,onCompositionStart:Xn,onCompositionEnd:Cn,addonAfter:St,suffix:ne,onChange:en,disabled:Ee}))}),Yt=ie(79809);const ze=Oe.Z;ze.Group=Re,ze.Search=kt,ze.TextArea=Yt.Z,ze.Password=Je,ze.OTP=ht;var zt=ze},24303:function(ln,Ft,ie){"use strict";ie.d(Ft,{D:function(){return je},Z:function(){return tt}});var z=ie(59301),Ke=ie(54476),ve={icon:{tag:"svg",attrs:{viewBox:"0 0 1024 1024",focusable:"false"},children:[{tag:"path",attrs:{d:"M912 192H328c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h584c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8zm0 284H328c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h584c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8zm0 284H328c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h584c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8zM104 228a56 56 0 10112 0 56 56 0 10-112 0zm0 284a56 56 0 10112 0 56 56 0 10-112 0zm0 284a56 56 0 10112 0 56 56 0 10-112 0z"}}]},name:"bars",theme:"outlined"},Ae=ve,ye=ie(7657),be=function($e,at){return z.createElement(ye.Z,(0,Ke.Z)({},$e,{ref:at,icon:Ae}))},Me=z.forwardRef(be),Re=Me,Oe=ie(33853),fe=ie(38819),We=ie(92310),Se=ie.n(We),yt=ie(2738),Xe=ie(48755),Le=ie(6989),Ge=ie(36237),Ne=ie(48923),dt=ie(16931);const It=ht=>{const{componentCls:$e,siderBg:at,motionDurationMid:lt,motionDurationSlow:me,antCls:At,triggerHeight:De,triggerColor:He,triggerBg:Pt,headerHeight:ge,zeroTriggerWidth:ce,zeroTriggerHeight:Je,borderRadiusLG:jt,lightSiderBg:wt,lightTriggerColor:Ie,lightTriggerBg:Ue,bodyBg:et}=ht;return{[$e]:{position:"relative",minWidth:0,background:at,transition:`all ${lt}, background 0s`,"&-has-trigger":{paddingBottom:De},"&-right":{order:1},[`${$e}-children`]:{height:"100%",marginTop:-.1,paddingTop:.1,[`${At}-menu${At}-menu-inline-collapsed`]:{width:"auto"}},[`&-zero-width ${$e}-children`]:{overflow:"hidden"},[`${$e}-trigger`]:{position:"fixed",bottom:0,zIndex:1,height:De,color:He,lineHeight:(0,Ge.unit)(De),textAlign:"center",background:Pt,cursor:"pointer",transition:`all ${lt}`},[`${$e}-zero-width-trigger`]:{position:"absolute",top:ge,insetInlineEnd:ht.calc(ce).mul(-1).equal(),zIndex:1,width:ce,height:Je,color:He,fontSize:ht.fontSizeXL,display:"flex",alignItems:"center",justifyContent:"center",background:at,borderRadius:`0 ${(0,Ge.unit)(jt)} ${(0,Ge.unit)(jt)} 0`,cursor:"pointer",transition:`background ${me} ease`,"&::after":{position:"absolute",inset:0,background:"transparent",transition:`all ${me}`,content:'""'},"&:hover::after":{background:"rgba(255, 255, 255, 0.2)"},"&-right":{insetInlineStart:ht.calc(ce).mul(-1).equal(),borderRadius:`${(0,Ge.unit)(jt)} 0 0 ${(0,Ge.unit)(jt)}`}},"&-light":{background:wt,[`${$e}-trigger`]:{color:Ie,background:Ue},[`${$e}-zero-width-trigger`]:{color:Ie,background:Ue,border:`1px solid ${et}`,borderInlineStart:0}}}}};var Bt=(0,dt.I$)(["Layout","Sider"],ht=>[It(ht)],Ne.eh,{deprecatedTokens:Ne.jn}),mt=function(ht,$e){var at={};for(var lt in ht)Object.prototype.hasOwnProperty.call(ht,lt)&&$e.indexOf(lt)<0&&(at[lt]=ht[lt]);if(ht!=null&&typeof Object.getOwnPropertySymbols=="function")for(var me=0,lt=Object.getOwnPropertySymbols(ht);me<lt.length;me++)$e.indexOf(lt[me])<0&&Object.prototype.propertyIsEnumerable.call(ht,lt[me])&&(at[lt[me]]=ht[lt[me]]);return at};const st={xs:"479.98px",sm:"575.98px",md:"767.98px",lg:"991.98px",xl:"1199.98px",xxl:"1599.98px"},it=ht=>!Number.isNaN(Number.parseFloat(ht))&&isFinite(ht),je=z.createContext({}),Ot=(()=>{let ht=0;return function(){let $e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"";return ht+=1,`${$e}${ht}`}})();var tt=z.forwardRef((ht,$e)=>{const{prefixCls:at,className:lt,trigger:me,children:At,defaultCollapsed:De=!1,theme:He="dark",style:Pt={},collapsible:ge=!1,reverseArrow:ce=!1,width:Je=200,collapsedWidth:jt=80,zeroWidthTriggerStyle:wt,breakpoint:Ie,onCollapse:Ue,onBreakpoint:et}=ht,cn=mt(ht,["prefixCls","className","trigger","children","defaultCollapsed","theme","style","collapsible","reverseArrow","width","collapsedWidth","zeroWidthTriggerStyle","breakpoint","onCollapse","onBreakpoint"]),{siderHook:kt}=(0,z.useContext)(Le.V),[Yt,ze]=(0,z.useState)("collapsed"in ht?ht.collapsed:De),[zt,ut]=(0,z.useState)(!1);(0,z.useEffect)(()=>{"collapsed"in ht&&ze(ht.collapsed)},[ht.collapsed]);const ae=(Gt,Tt)=>{"collapsed"in ht||ze(Gt),Ue==null||Ue(Gt,Tt)},{getPrefixCls:te,direction:ee}=(0,z.useContext)(Xe.E_),oe=te("layout-sider",at),[se,ne,he]=Bt(oe),xe=(0,z.useRef)(null);xe.current=Gt=>{ut(Gt.matches),et==null||et(Gt.matches),Yt!==Gt.matches&&ae(Gt.matches,"responsive")},(0,z.useEffect)(()=>{function Gt(en){return xe.current(en)}let Tt;if(typeof window!="undefined"){const{matchMedia:en}=window;if(en&&Ie&&Ie in st){Tt=en(`screen and (max-width: ${st[Ie]})`);try{Tt.addEventListener("change",Gt)}catch(yn){Tt.addListener(Gt)}Gt(Tt)}}return()=>{try{Tt==null||Tt.removeEventListener("change",Gt)}catch(en){Tt==null||Tt.removeListener(Gt)}}},[Ie]),(0,z.useEffect)(()=>{const Gt=Ot("ant-sider-");return kt.addSider(Gt),()=>kt.removeSider(Gt)},[]);const ot=()=>{ae(!Yt,"clickTrigger")},Ee=(0,yt.Z)(cn,["collapsed"]),Fe=Yt?jt:Je,qe=it(Fe)?`${Fe}px`:String(Fe),bt=parseFloat(String(jt||0))===0?z.createElement("span",{onClick:ot,className:Se()(`${oe}-zero-width-trigger`,`${oe}-zero-width-trigger-${ce?"right":"left"}`),style:wt},me||z.createElement(Re,null)):null,ct=ee==="rtl"==!ce,Nt={expanded:ct?z.createElement(fe.Z,null):z.createElement(Oe.Z,null),collapsed:ct?z.createElement(Oe.Z,null):z.createElement(fe.Z,null)}[Yt?"collapsed":"expanded"],rn=me!==null?bt||z.createElement("div",{className:`${oe}-trigger`,onClick:ot,style:{width:qe}},me||Nt):null,qt=Object.assign(Object.assign({},Pt),{flex:`0 0 ${qe}`,maxWidth:qe,minWidth:qe,width:qe}),on=Se()(oe,`${oe}-${He}`,{[`${oe}-collapsed`]:!!Yt,[`${oe}-has-trigger`]:ge&&me!==null&&!bt,[`${oe}-below`]:!!zt,[`${oe}-zero-width`]:parseFloat(qe)===0},lt,ne,he),ft=z.useMemo(()=>({siderCollapsed:Yt}),[Yt]);return se(z.createElement(je.Provider,{value:ft},z.createElement("aside",Object.assign({className:on},Ee,{style:qt,ref:$e}),z.createElement("div",{className:`${oe}-children`},At),ge||zt&&bt?rn:null)))})},6989:function(ln,Ft,ie){"use strict";ie.d(Ft,{V:function(){return Ke}});var z=ie(59301);const Ke=z.createContext({siderHook:{addSider:()=>null,removeSider:()=>null}})},48923:function(ln,Ft,ie){"use strict";ie.d(Ft,{eh:function(){return Ae},jn:function(){return ye}});var z=ie(36237),Ke=ie(16931);const ve=be=>{const{antCls:Me,componentCls:Re,colorText:Oe,footerBg:fe,headerHeight:We,headerPadding:Se,headerColor:yt,footerPadding:Xe,fontSize:Le,bodyBg:Ge,headerBg:Ne}=be;return{[Re]:{display:"flex",flex:"auto",flexDirection:"column",minHeight:0,background:Ge,"&, *":{boxSizing:"border-box"},[`&${Re}-has-sider`]:{flexDirection:"row",[`> ${Re}, > ${Re}-content`]:{width:0}},[`${Re}-header, &${Re}-footer`]:{flex:"0 0 auto"},"&-rtl":{direction:"rtl"}},[`${Re}-header`]:{height:We,padding:Se,color:yt,lineHeight:(0,z.unit)(We),background:Ne,[`${Me}-menu`]:{lineHeight:"inherit"}},[`${Re}-footer`]:{padding:Xe,color:Oe,fontSize:Le,background:fe},[`${Re}-content`]:{flex:"auto",color:Oe,minHeight:0}}},Ae=be=>{const{colorBgLayout:Me,controlHeight:Re,controlHeightLG:Oe,colorText:fe,controlHeightSM:We,marginXXS:Se,colorTextLightSolid:yt,colorBgContainer:Xe}=be,Le=Oe*1.25;return{colorBgHeader:"#001529",colorBgBody:Me,colorBgTrigger:"#002140",bodyBg:Me,headerBg:"#001529",headerHeight:Re*2,headerPadding:`0 ${Le}px`,headerColor:fe,footerPadding:`${We}px ${Le}px`,footerBg:Me,siderBg:"#001529",triggerHeight:Oe+Se*2,triggerBg:"#002140",triggerColor:yt,zeroTriggerWidth:Oe,zeroTriggerHeight:Oe,lightSiderBg:Xe,lightTriggerBg:Xe,lightTriggerColor:fe}},ye=[["colorBgBody","bodyBg"],["colorBgHeader","headerBg"],["colorBgTrigger","triggerBg"]];Ft.ZP=(0,Ke.I$)("Layout",be=>[ve(be)],Ae,{deprecatedTokens:ye})},78857:function(ln,Ft,ie){"use strict";ie.d(Ft,{J:function(){return be}});var z=ie(59301),Ke=ie(8654),ve=ie(62487),Ae=function(Me,Re){var Oe={};for(var fe in Me)Object.prototype.hasOwnProperty.call(Me,fe)&&Re.indexOf(fe)<0&&(Oe[fe]=Me[fe]);if(Me!=null&&typeof Object.getOwnPropertySymbols=="function")for(var We=0,fe=Object.getOwnPropertySymbols(Me);We<fe.length;We++)Re.indexOf(fe[We])<0&&Object.prototype.propertyIsEnumerable.call(Me,fe[We])&&(Oe[fe[We]]=Me[fe[We]]);return Oe};const ye=z.createContext(null),be=z.forwardRef((Me,Re)=>{const{children:Oe}=Me,fe=Ae(Me,["children"]),We=z.useContext(ye),Se=z.useMemo(()=>Object.assign(Object.assign({},We),fe),[We,fe.prefixCls,fe.mode,fe.selectable,fe.rootClassName]),yt=(0,Ke.t4)(Oe),Xe=(0,Ke.x1)(Re,yt?(0,Ke.C4)(Oe):null);return z.createElement(ye.Provider,{value:Se},z.createElement(ve.Z,{space:!0},yt?z.cloneElement(Oe,{ref:Xe}):Oe))});Ft.Z=ye},93041:function(ln,Ft,ie){"use strict";ie.d(Ft,{default:function(){return se}});var z=ie(59301),Ke=ie(28321),ve=ie(24303),Ae=ie(18785),ye=ie(92310),be=ie.n(ye),Me=ie(6089),Re=ie(2738),Oe=ie(86641),fe=ie(22703),We=ie(48755),Se=ie(83397),Xe=(0,z.createContext)({prefixCls:"",firstLevel:!0,inlineCollapsed:!1}),Le=function(ne,he){var xe={};for(var ot in ne)Object.prototype.hasOwnProperty.call(ne,ot)&&he.indexOf(ot)<0&&(xe[ot]=ne[ot]);if(ne!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Ee=0,ot=Object.getOwnPropertySymbols(ne);Ee<ot.length;Ee++)he.indexOf(ot[Ee])<0&&Object.prototype.propertyIsEnumerable.call(ne,ot[Ee])&&(xe[ot[Ee]]=ne[ot[Ee]]);return xe},Ne=ne=>{const{prefixCls:he,className:xe,dashed:ot}=ne,Ee=Le(ne,["prefixCls","className","dashed"]),{getPrefixCls:Fe}=z.useContext(We.E_),qe=Fe("menu",he),bt=be()({[`${qe}-item-divider-dashed`]:!!ot},xe);return z.createElement(Ke.iz,Object.assign({className:bt},Ee))},dt=ie(11592),It=ie(25399),mt=ne=>{var he;const{className:xe,children:ot,icon:Ee,title:Fe,danger:qe,extra:bt}=ne,{prefixCls:ct,firstLevel:Kt,direction:Wt,disableMenuItemTitleTooltip:Nt,inlineCollapsed:rn}=z.useContext(Xe),qt=yn=>{const Rn=ot==null?void 0:ot[0],On=z.createElement("span",{className:be()(`${ct}-title-content`,{[`${ct}-title-content-with-extra`]:!!bt||bt===0})},ot);return(!Ee||z.isValidElement(ot)&&ot.type==="span")&&ot&&yn&&Kt&&typeof Rn=="string"?z.createElement("div",{className:`${ct}-inline-collapsed-noicon`},Rn.charAt(0)):On},{siderCollapsed:on}=z.useContext(ve.D);let ft=Fe;typeof Fe=="undefined"?ft=Kt?ot:"":Fe===!1&&(ft="");const Gt={title:ft};!on&&!rn&&(Gt.title=null,Gt.open=!1);const Tt=(0,dt.Z)(ot).length;let en=z.createElement(Ke.ck,Object.assign({},(0,Re.Z)(ne,["title","icon","danger"]),{className:be()({[`${ct}-item-danger`]:qe,[`${ct}-item-only-child`]:(Ee?Tt+1:Tt)===1},xe),title:typeof Fe=="string"?Fe:void 0}),(0,fe.Tm)(Ee,{className:be()(z.isValidElement(Ee)?(he=Ee.props)===null||he===void 0?void 0:he.className:"",`${ct}-item-icon`)}),qt(rn));return Nt||(en=z.createElement(It.Z,Object.assign({},Gt,{placement:Wt==="rtl"?"left":"right",classNames:{root:`${ct}-inline-collapsed-tooltip`}}),en)),en},st=ie(78857),it=ie(36237),je=ie(17835),Ot=ie(63356),nt=ie(34961),tt=ie(46e3),ht=ie(34925),$e=ie(16931),at=ie(51636),me=ne=>{const{componentCls:he,motionDurationSlow:xe,horizontalLineHeight:ot,colorSplit:Ee,lineWidth:Fe,lineType:qe,itemPaddingInline:bt}=ne;return{[`${he}-horizontal`]:{lineHeight:ot,border:0,borderBottom:`${(0,it.unit)(Fe)} ${qe} ${Ee}`,boxShadow:"none","&::after":{display:"block",clear:"both",height:0,content:'"\\20"'},[`${he}-item, ${he}-submenu`]:{position:"relative",display:"inline-block",verticalAlign:"bottom",paddingInline:bt},[`> ${he}-item:hover,
|
|
|
> ${he}-item-active,
|
|
|
> ${he}-submenu ${he}-submenu-title:hover`]:{backgroundColor:"transparent"},[`${he}-item, ${he}-submenu-title`]:{transition:[`border-color ${xe}`,`background ${xe}`].join(",")},[`${he}-submenu-arrow`]:{display:"none"}}}},De=ne=>{let{componentCls:he,menuArrowOffset:xe,calc:ot}=ne;return{[`${he}-rtl`]:{direction:"rtl"},[`${he}-submenu-rtl`]:{transformOrigin:"100% 0"},[`${he}-rtl${he}-vertical,
|
|
|
${he}-submenu-rtl ${he}-vertical`]:{[`${he}-submenu-arrow`]:{"&::before":{transform:`rotate(-45deg) translateY(${(0,it.unit)(ot(xe).mul(-1).equal())})`},"&::after":{transform:`rotate(45deg) translateY(${(0,it.unit)(xe)})`}}}}};const He=ne=>Object.assign({},(0,Ot.oN)(ne));var ge=(ne,he)=>{const{componentCls:xe,itemColor:ot,itemSelectedColor:Ee,subMenuItemSelectedColor:Fe,groupTitleColor:qe,itemBg:bt,subMenuItemBg:ct,itemSelectedBg:Kt,activeBarHeight:Wt,activeBarWidth:Nt,activeBarBorderWidth:rn,motionDurationSlow:qt,motionEaseInOut:on,motionEaseOut:ft,itemPaddingInline:Gt,motionDurationMid:Tt,itemHoverColor:en,lineType:yn,colorSplit:Rn,itemDisabledColor:On,dangerItemColor:Pe,dangerItemHoverColor:rt,dangerItemSelectedColor:St,dangerItemActiveBg:_t,dangerItemSelectedBg:bn,popupBg:In,itemHoverBg:rr,itemActiveBg:Xn,menuSubMenuBg:Cn,horizontalItemSelectedColor:Fn,horizontalItemSelectedBg:xt,horizontalItemBorderRadius:$t,horizontalItemHoverBg:vt}=ne;return{[`${xe}-${he}, ${xe}-${he} > ${xe}`]:{color:ot,background:bt,[`&${xe}-root:focus-visible`]:Object.assign({},He(ne)),[`${xe}-item`]:{"&-group-title, &-extra":{color:qe}},[`${xe}-submenu-selected > ${xe}-submenu-title`]:{color:Fe},[`${xe}-item, ${xe}-submenu-title`]:{color:ot,[`&:not(${xe}-item-disabled):focus-visible`]:Object.assign({},He(ne))},[`${xe}-item-disabled, ${xe}-submenu-disabled`]:{color:`${On} !important`},[`${xe}-item:not(${xe}-item-selected):not(${xe}-submenu-selected)`]:{[`&:hover, > ${xe}-submenu-title:hover`]:{color:en}},[`&:not(${xe}-horizontal)`]:{[`${xe}-item:not(${xe}-item-selected)`]:{"&:hover":{backgroundColor:rr},"&:active":{backgroundColor:Xn}},[`${xe}-submenu-title`]:{"&:hover":{backgroundColor:rr},"&:active":{backgroundColor:Xn}}},[`${xe}-item-danger`]:{color:Pe,[`&${xe}-item:hover`]:{[`&:not(${xe}-item-selected):not(${xe}-submenu-selected)`]:{color:rt}},[`&${xe}-item:active`]:{background:_t}},[`${xe}-item a`]:{"&, &:hover":{color:"inherit"}},[`${xe}-item-selected`]:{color:Ee,[`&${xe}-item-danger`]:{color:St},"a, a:hover":{color:"inherit"}},[`& ${xe}-item-selected`]:{backgroundColor:Kt,[`&${xe}-item-danger`]:{backgroundColor:bn}},[`&${xe}-submenu > ${xe}`]:{backgroundColor:Cn},[`&${xe}-popup > ${xe}`]:{backgroundColor:In},[`&${xe}-submenu-popup > ${xe}`]:{backgroundColor:In},[`&${xe}-horizontal`]:Object.assign(Object.assign({},he==="dark"?{borderBottom:0}:{}),{[`> ${xe}-item, > ${xe}-submenu`]:{top:rn,marginTop:ne.calc(rn).mul(-1).equal(),marginBottom:0,borderRadius:$t,"&::after":{position:"absolute",insetInline:Gt,bottom:0,borderBottom:`${(0,it.unit)(Wt)} solid transparent`,transition:`border-color ${qt} ${on}`,content:'""'},"&:hover, &-active, &-open":{background:vt,"&::after":{borderBottomWidth:Wt,borderBottomColor:Fn}},"&-selected":{color:Fn,backgroundColor:xt,"&:hover":{backgroundColor:xt},"&::after":{borderBottomWidth:Wt,borderBottomColor:Fn}}}}),[`&${xe}-root`]:{[`&${xe}-inline, &${xe}-vertical`]:{borderInlineEnd:`${(0,it.unit)(rn)} ${yn} ${Rn}`}},[`&${xe}-inline`]:{[`${xe}-sub${xe}-inline`]:{background:ct},[`${xe}-item`]:{position:"relative","&::after":{position:"absolute",insetBlock:0,insetInlineEnd:0,borderInlineEnd:`${(0,it.unit)(Nt)} solid ${Ee}`,transform:"scaleY(0.0001)",opacity:0,transition:[`transform ${Tt} ${ft}`,`opacity ${Tt} ${ft}`].join(","),content:'""'},[`&${xe}-item-danger`]:{"&::after":{borderInlineEndColor:St}}},[`${xe}-selected, ${xe}-item-selected`]:{"&::after":{transform:"scaleY(1)",opacity:1,transition:[`transform ${Tt} ${on}`,`opacity ${Tt} ${on}`].join(",")}}}}}};const ce=ne=>{const{componentCls:he,itemHeight:xe,itemMarginInline:ot,padding:Ee,menuArrowSize:Fe,marginXS:qe,itemMarginBlock:bt,itemWidth:ct,itemPaddingInline:Kt}=ne,Wt=ne.calc(Fe).add(Ee).add(qe).equal();return{[`${he}-item`]:{position:"relative",overflow:"hidden"},[`${he}-item, ${he}-submenu-title`]:{height:xe,lineHeight:(0,it.unit)(xe),paddingInline:Kt,overflow:"hidden",textOverflow:"ellipsis",marginInline:ot,marginBlock:bt,width:ct},[`> ${he}-item,
|
|
|
> ${he}-submenu > ${he}-submenu-title`]:{height:xe,lineHeight:(0,it.unit)(xe)},[`${he}-item-group-list ${he}-submenu-title,
|
|
|
${he}-submenu-title`]:{paddingInlineEnd:Wt}}};var jt=ne=>{const{componentCls:he,iconCls:xe,itemHeight:ot,colorTextLightSolid:Ee,dropdownWidth:Fe,controlHeightLG:qe,motionEaseOut:bt,paddingXL:ct,itemMarginInline:Kt,fontSizeLG:Wt,motionDurationFast:Nt,motionDurationSlow:rn,paddingXS:qt,boxShadowSecondary:on,collapsedWidth:ft,collapsedIconSize:Gt}=ne,Tt={height:ot,lineHeight:(0,it.unit)(ot),listStylePosition:"inside",listStyleType:"disc"};return[{[he]:{"&-inline, &-vertical":Object.assign({[`&${he}-root`]:{boxShadow:"none"}},ce(ne))},[`${he}-submenu-popup`]:{[`${he}-vertical`]:Object.assign(Object.assign({},ce(ne)),{boxShadow:on})}},{[`${he}-submenu-popup ${he}-vertical${he}-sub`]:{minWidth:Fe,maxHeight:`calc(100vh - ${(0,it.unit)(ne.calc(qe).mul(2.5).equal())})`,padding:"0",overflow:"hidden",borderInlineEnd:0,"&:not([class*='-active'])":{overflowX:"hidden",overflowY:"auto"}}},{[`${he}-inline`]:{width:"100%",[`&${he}-root`]:{[`${he}-item, ${he}-submenu-title`]:{display:"flex",alignItems:"center",transition:[`border-color ${rn}`,`background ${rn}`,`padding ${Nt} ${bt}`].join(","),[`> ${he}-title-content`]:{flex:"auto",minWidth:0,overflow:"hidden",textOverflow:"ellipsis"},"> *":{flex:"none"}}},[`${he}-sub${he}-inline`]:{padding:0,border:0,borderRadius:0,boxShadow:"none",[`& > ${he}-submenu > ${he}-submenu-title`]:Tt,[`& ${he}-item-group-title`]:{paddingInlineStart:ct}},[`${he}-item`]:Tt}},{[`${he}-inline-collapsed`]:{width:ft,[`&${he}-root`]:{[`${he}-item, ${he}-submenu ${he}-submenu-title`]:{[`> ${he}-inline-collapsed-noicon`]:{fontSize:Wt,textAlign:"center"}}},[`> ${he}-item,
|
|
|
> ${he}-item-group > ${he}-item-group-list > ${he}-item,
|
|
|
> ${he}-item-group > ${he}-item-group-list > ${he}-submenu > ${he}-submenu-title,
|
|
|
> ${he}-submenu > ${he}-submenu-title`]:{insetInlineStart:0,paddingInline:`calc(50% - ${(0,it.unit)(ne.calc(Gt).div(2).equal())} - ${(0,it.unit)(Kt)})`,textOverflow:"clip",[`
|
|
|
${he}-submenu-arrow,
|
|
|
${he}-submenu-expand-icon
|
|
|
`]:{opacity:0},[`${he}-item-icon, ${xe}`]:{margin:0,fontSize:Gt,lineHeight:(0,it.unit)(ot),"+ span":{display:"inline-block",opacity:0}}},[`${he}-item-icon, ${xe}`]:{display:"inline-block"},"&-tooltip":{pointerEvents:"none",[`${he}-item-icon, ${xe}`]:{display:"none"},"a, a:hover":{color:Ee}},[`${he}-item-group-title`]:Object.assign(Object.assign({},Ot.vS),{paddingInline:qt})}}]};const wt=ne=>{const{componentCls:he,motionDurationSlow:xe,motionDurationMid:ot,motionEaseInOut:Ee,motionEaseOut:Fe,iconCls:qe,iconSize:bt,iconMarginInlineEnd:ct}=ne;return{[`${he}-item, ${he}-submenu-title`]:{position:"relative",display:"block",margin:0,whiteSpace:"nowrap",cursor:"pointer",transition:[`border-color ${xe}`,`background ${xe}`,`padding calc(${xe} + 0.1s) ${Ee}`].join(","),[`${he}-item-icon, ${qe}`]:{minWidth:bt,fontSize:bt,transition:[`font-size ${ot} ${Fe}`,`margin ${xe} ${Ee}`,`color ${xe}`].join(","),"+ span":{marginInlineStart:ct,opacity:1,transition:[`opacity ${xe} ${Ee}`,`margin ${xe}`,`color ${xe}`].join(",")}},[`${he}-item-icon`]:Object.assign({},(0,Ot.Ro)()),[`&${he}-item-only-child`]:{[`> ${qe}, > ${he}-item-icon`]:{marginInlineEnd:0}}},[`${he}-item-disabled, ${he}-submenu-disabled`]:{background:"none !important",cursor:"not-allowed","&::after":{borderColor:"transparent !important"},a:{color:"inherit !important",cursor:"not-allowed",pointerEvents:"none"},[`> ${he}-submenu-title`]:{color:"inherit !important",cursor:"not-allowed"}}}},Ie=ne=>{const{componentCls:he,motionDurationSlow:xe,motionEaseInOut:ot,borderRadius:Ee,menuArrowSize:Fe,menuArrowOffset:qe}=ne;return{[`${he}-submenu`]:{"&-expand-icon, &-arrow":{position:"absolute",top:"50%",insetInlineEnd:ne.margin,width:Fe,color:"currentcolor",transform:"translateY(-50%)",transition:`transform ${xe} ${ot}, opacity ${xe}`},"&-arrow":{"&::before, &::after":{position:"absolute",width:ne.calc(Fe).mul(.6).equal(),height:ne.calc(Fe).mul(.15).equal(),backgroundColor:"currentcolor",borderRadius:Ee,transition:[`background ${xe} ${ot}`,`transform ${xe} ${ot}`,`top ${xe} ${ot}`,`color ${xe} ${ot}`].join(","),content:'""'},"&::before":{transform:`rotate(45deg) translateY(${(0,it.unit)(ne.calc(qe).mul(-1).equal())})`},"&::after":{transform:`rotate(-45deg) translateY(${(0,it.unit)(qe)})`}}}}},Ue=ne=>{const{antCls:he,componentCls:xe,fontSize:ot,motionDurationSlow:Ee,motionDurationMid:Fe,motionEaseInOut:qe,paddingXS:bt,padding:ct,colorSplit:Kt,lineWidth:Wt,zIndexPopup:Nt,borderRadiusLG:rn,subMenuItemBorderRadius:qt,menuArrowSize:on,menuArrowOffset:ft,lineType:Gt,groupTitleLineHeight:Tt,groupTitleFontSize:en}=ne;return[{"":{[xe]:Object.assign(Object.assign({},(0,Ot.dF)()),{"&-hidden":{display:"none"}})},[`${xe}-submenu-hidden`]:{display:"none"}},{[xe]:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},(0,Ot.Wf)(ne)),(0,Ot.dF)()),{marginBottom:0,paddingInlineStart:0,fontSize:ot,lineHeight:0,listStyle:"none",outline:"none",transition:`width ${Ee} cubic-bezier(0.2, 0, 0, 1) 0s`,"ul, ol":{margin:0,padding:0,listStyle:"none"},"&-overflow":{display:"flex",[`${xe}-item`]:{flex:"none"}},[`${xe}-item, ${xe}-submenu, ${xe}-submenu-title`]:{borderRadius:ne.itemBorderRadius},[`${xe}-item-group-title`]:{padding:`${(0,it.unit)(bt)} ${(0,it.unit)(ct)}`,fontSize:en,lineHeight:Tt,transition:`all ${Ee}`},[`&-horizontal ${xe}-submenu`]:{transition:[`border-color ${Ee} ${qe}`,`background ${Ee} ${qe}`].join(",")},[`${xe}-submenu, ${xe}-submenu-inline`]:{transition:[`border-color ${Ee} ${qe}`,`background ${Ee} ${qe}`,`padding ${Fe} ${qe}`].join(",")},[`${xe}-submenu ${xe}-sub`]:{cursor:"initial",transition:[`background ${Ee} ${qe}`,`padding ${Ee} ${qe}`].join(",")},[`${xe}-title-content`]:{transition:`color ${Ee}`,"&-with-extra":{display:"inline-flex",alignItems:"center",width:"100%"},[`> ${he}-typography-ellipsis-single-line`]:{display:"inline",verticalAlign:"unset"},[`${xe}-item-extra`]:{marginInlineStart:"auto",paddingInlineStart:ne.padding}},[`${xe}-item a`]:{"&::before":{position:"absolute",inset:0,backgroundColor:"transparent",content:'""'}},[`${xe}-item-divider`]:{overflow:"hidden",lineHeight:0,borderColor:Kt,borderStyle:Gt,borderWidth:0,borderTopWidth:Wt,marginBlock:Wt,padding:0,"&-dashed":{borderStyle:"dashed"}}}),wt(ne)),{[`${xe}-item-group`]:{[`${xe}-item-group-list`]:{margin:0,padding:0,[`${xe}-item, ${xe}-submenu-title`]:{paddingInline:`${(0,it.unit)(ne.calc(ot).mul(2).equal())} ${(0,it.unit)(ct)}`}}},"&-submenu":{"&-popup":{position:"absolute",zIndex:Nt,borderRadius:rn,boxShadow:"none",transformOrigin:"0 0",[`&${xe}-submenu`]:{background:"transparent"},"&::before":{position:"absolute",inset:0,zIndex:-1,width:"100%",height:"100%",opacity:0,content:'""'},[`> ${xe}`]:Object.assign(Object.assign(Object.assign({borderRadius:rn},wt(ne)),Ie(ne)),{[`${xe}-item, ${xe}-submenu > ${xe}-submenu-title`]:{borderRadius:qt},[`${xe}-submenu-title::after`]:{transition:`transform ${Ee} ${qe}`}})},"\n &-placement-leftTop,\n &-placement-bottomRight,\n ":{transformOrigin:"100% 0"},"\n &-placement-leftBottom,\n &-placement-topRight,\n ":{transformOrigin:"100% 100%"},"\n &-placement-rightBottom,\n &-placement-topLeft,\n ":{transformOrigin:"0 100%"},"\n &-placement-bottomLeft,\n &-placement-rightTop,\n ":{transformOrigin:"0 0"},"\n &-placement-leftTop,\n &-placement-leftBottom\n ":{paddingInlineEnd:ne.paddingXS},"\n &-placement-rightTop,\n &-placement-rightBottom\n ":{paddingInlineStart:ne.paddingXS},"\n &-placement-topRight,\n &-placement-topLeft\n ":{paddingBottom:ne.paddingXS},"\n &-placement-bottomRight,\n &-placement-bottomLeft\n ":{paddingTop:ne.paddingXS}}}),Ie(ne)),{[`&-inline-collapsed ${xe}-submenu-arrow,
|
|
|
&-inline ${xe}-submenu-arrow`]:{"&::before":{transform:`rotate(-45deg) translateX(${(0,it.unit)(ft)})`},"&::after":{transform:`rotate(45deg) translateX(${(0,it.unit)(ne.calc(ft).mul(-1).equal())})`}},[`${xe}-submenu-open${xe}-submenu-inline > ${xe}-submenu-title > ${xe}-submenu-arrow`]:{transform:`translateY(${(0,it.unit)(ne.calc(on).mul(.2).mul(-1).equal())})`,"&::after":{transform:`rotate(-45deg) translateX(${(0,it.unit)(ne.calc(ft).mul(-1).equal())})`},"&::before":{transform:`rotate(45deg) translateX(${(0,it.unit)(ft)})`}}})},{[`${he}-layout-header`]:{[xe]:{lineHeight:"inherit"}}}]},et=ne=>{var he,xe,ot;const{colorPrimary:Ee,colorError:Fe,colorTextDisabled:qe,colorErrorBg:bt,colorText:ct,colorTextDescription:Kt,colorBgContainer:Wt,colorFillAlter:Nt,colorFillContent:rn,lineWidth:qt,lineWidthBold:on,controlItemBgActive:ft,colorBgTextHover:Gt,controlHeightLG:Tt,lineHeight:en,colorBgElevated:yn,marginXXS:Rn,padding:On,fontSize:Pe,controlHeightSM:rt,fontSizeLG:St,colorTextLightSolid:_t,colorErrorHover:bn}=ne,In=(he=ne.activeBarWidth)!==null&&he!==void 0?he:0,rr=(xe=ne.activeBarBorderWidth)!==null&&xe!==void 0?xe:qt,Xn=(ot=ne.itemMarginInline)!==null&&ot!==void 0?ot:ne.marginXXS,Cn=new je.FastColor(_t).setA(.65).toRgbString();return{dropdownWidth:160,zIndexPopup:ne.zIndexPopupBase+50,radiusItem:ne.borderRadiusLG,itemBorderRadius:ne.borderRadiusLG,radiusSubMenuItem:ne.borderRadiusSM,subMenuItemBorderRadius:ne.borderRadiusSM,colorItemText:ct,itemColor:ct,colorItemTextHover:ct,itemHoverColor:ct,colorItemTextHoverHorizontal:Ee,horizontalItemHoverColor:Ee,colorGroupTitle:Kt,groupTitleColor:Kt,colorItemTextSelected:Ee,itemSelectedColor:Ee,subMenuItemSelectedColor:Ee,colorItemTextSelectedHorizontal:Ee,horizontalItemSelectedColor:Ee,colorItemBg:Wt,itemBg:Wt,colorItemBgHover:Gt,itemHoverBg:Gt,colorItemBgActive:rn,itemActiveBg:ft,colorSubItemBg:Nt,subMenuItemBg:Nt,colorItemBgSelected:ft,itemSelectedBg:ft,colorItemBgSelectedHorizontal:"transparent",horizontalItemSelectedBg:"transparent",colorActiveBarWidth:0,activeBarWidth:In,colorActiveBarHeight:on,activeBarHeight:on,colorActiveBarBorderSize:qt,activeBarBorderWidth:rr,colorItemTextDisabled:qe,itemDisabledColor:qe,colorDangerItemText:Fe,dangerItemColor:Fe,colorDangerItemTextHover:Fe,dangerItemHoverColor:Fe,colorDangerItemTextSelected:Fe,dangerItemSelectedColor:Fe,colorDangerItemBgActive:bt,dangerItemActiveBg:bt,colorDangerItemBgSelected:bt,dangerItemSelectedBg:bt,itemMarginInline:Xn,horizontalItemBorderRadius:0,horizontalItemHoverBg:"transparent",itemHeight:Tt,groupTitleLineHeight:en,collapsedWidth:Tt*2,popupBg:yn,itemMarginBlock:Rn,itemPaddingInline:On,horizontalLineHeight:`${Tt*1.15}px`,iconSize:Pe,iconMarginInlineEnd:rt-Pe,collapsedIconSize:St,groupTitleFontSize:Pe,darkItemDisabledColor:new je.FastColor(_t).setA(.25).toRgbString(),darkItemColor:Cn,darkDangerItemColor:Fe,darkItemBg:"#001529",darkPopupBg:"#001529",darkSubMenuItemBg:"#000c17",darkItemSelectedColor:_t,darkItemSelectedBg:Ee,darkDangerItemSelectedBg:Fe,darkItemHoverBg:"transparent",darkGroupTitleColor:Cn,darkItemHoverColor:_t,darkDangerItemHoverColor:bn,darkDangerItemSelectedColor:_t,darkDangerItemActiveBg:Fe,itemWidth:In?`calc(100% + ${rr}px)`:`calc(100% - ${Xn*2}px)`}};var cn=function(ne){let he=arguments.length>1&&arguments[1]!==void 0?arguments[1]:ne,xe=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0;return(0,$e.I$)("Menu",Ee=>{const{colorBgElevated:Fe,controlHeightLG:qe,fontSize:bt,darkItemColor:ct,darkDangerItemColor:Kt,darkItemBg:Wt,darkSubMenuItemBg:Nt,darkItemSelectedColor:rn,darkItemSelectedBg:qt,darkDangerItemSelectedBg:on,darkItemHoverBg:ft,darkGroupTitleColor:Gt,darkItemHoverColor:Tt,darkItemDisabledColor:en,darkDangerItemHoverColor:yn,darkDangerItemSelectedColor:Rn,darkDangerItemActiveBg:On,popupBg:Pe,darkPopupBg:rt}=Ee,St=Ee.calc(bt).div(7).mul(5).equal(),_t=(0,at.mergeToken)(Ee,{menuArrowSize:St,menuHorizontalHeight:Ee.calc(qe).mul(1.15).equal(),menuArrowOffset:Ee.calc(St).mul(.25).equal(),menuSubMenuBg:Fe,calc:Ee.calc,popupBg:Pe}),bn=(0,at.mergeToken)(_t,{itemColor:ct,itemHoverColor:Tt,groupTitleColor:Gt,itemSelectedColor:rn,subMenuItemSelectedColor:rn,itemBg:Wt,popupBg:rt,subMenuItemBg:Nt,itemActiveBg:"transparent",itemSelectedBg:qt,activeBarHeight:0,activeBarBorderWidth:0,itemHoverBg:ft,itemDisabledColor:en,dangerItemColor:Kt,dangerItemHoverColor:yn,dangerItemSelectedColor:Rn,dangerItemActiveBg:On,dangerItemSelectedBg:on,menuSubMenuBg:Nt,horizontalItemSelectedColor:rn,horizontalItemSelectedBg:qt});return[Ue(_t),me(_t),jt(_t),ge(_t,"light"),ge(bn,"dark"),De(_t),(0,nt.Z)(_t),(0,tt.oN)(_t,"slide-up"),(0,tt.oN)(_t,"slide-down"),(0,ht._y)(_t,"zoom-big")]},et,{deprecatedTokens:[["colorGroupTitle","groupTitleColor"],["radiusItem","itemBorderRadius"],["radiusSubMenuItem","subMenuItemBorderRadius"],["colorItemText","itemColor"],["colorItemTextHover","itemHoverColor"],["colorItemTextHoverHorizontal","horizontalItemHoverColor"],["colorItemTextSelected","itemSelectedColor"],["colorItemTextSelectedHorizontal","horizontalItemSelectedColor"],["colorItemTextDisabled","itemDisabledColor"],["colorDangerItemText","dangerItemColor"],["colorDangerItemTextHover","dangerItemHoverColor"],["colorDangerItemTextSelected","dangerItemSelectedColor"],["colorDangerItemBgActive","dangerItemActiveBg"],["colorDangerItemBgSelected","dangerItemSelectedBg"],["colorItemBg","itemBg"],["colorItemBgHover","itemHoverBg"],["colorSubItemBg","subMenuItemBg"],["colorItemBgActive","itemActiveBg"],["colorItemBgSelectedHorizontal","horizontalItemSelectedBg"],["colorActiveBarWidth","activeBarWidth"],["colorActiveBarHeight","activeBarHeight"],["colorActiveBarBorderSize","activeBarBorderWidth"],["colorItemBgSelected","itemSelectedBg"]],injectStyle:xe,unitless:{groupTitleLineHeight:!0}})(ne,he)},kt=ie(75030),ze=ne=>{var he;const{popupClassName:xe,icon:ot,title:Ee,theme:Fe}=ne,qe=z.useContext(Xe),{prefixCls:bt,inlineCollapsed:ct,theme:Kt}=qe,Wt=(0,Ke.Xl)();let Nt;if(!ot)Nt=ct&&!Wt.length&&Ee&&typeof Ee=="string"?z.createElement("div",{className:`${bt}-inline-collapsed-noicon`},Ee.charAt(0)):z.createElement("span",{className:`${bt}-title-content`},Ee);else{const on=z.isValidElement(Ee)&&Ee.type==="span";Nt=z.createElement(z.Fragment,null,(0,fe.Tm)(ot,{className:be()(z.isValidElement(ot)?(he=ot.props)===null||he===void 0?void 0:he.className:"",`${bt}-item-icon`)}),on?Ee:z.createElement("span",{className:`${bt}-title-content`},Ee))}const rn=z.useMemo(()=>Object.assign(Object.assign({},qe),{firstLevel:!1}),[qe]),[qt]=(0,kt.Cn)("Menu");return z.createElement(Xe.Provider,{value:rn},z.createElement(Ke.Wd,Object.assign({},(0,Re.Z)(ne,["icon"]),{title:Nt,popupClassName:be()(bt,xe,`${bt}-${Fe||Kt}`),popupStyle:Object.assign({zIndex:qt},ne.popupStyle)})))},zt=function(ne,he){var xe={};for(var ot in ne)Object.prototype.hasOwnProperty.call(ne,ot)&&he.indexOf(ot)<0&&(xe[ot]=ne[ot]);if(ne!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Ee=0,ot=Object.getOwnPropertySymbols(ne);Ee<ot.length;Ee++)he.indexOf(ot[Ee])<0&&Object.prototype.propertyIsEnumerable.call(ne,ot[Ee])&&(xe[ot[Ee]]=ne[ot[Ee]]);return xe};function ut(ne){return ne===null||ne===!1}const ae={item:mt,submenu:ze,divider:Ne};var ee=(0,z.forwardRef)((ne,he)=>{var xe;const ot=z.useContext(st.Z),Ee=ot||{},{getPrefixCls:Fe,getPopupContainer:qe,direction:bt,menu:ct}=z.useContext(We.E_),Kt=Fe(),{prefixCls:Wt,className:Nt,style:rn,theme:qt="light",expandIcon:on,_internalDisableMenuItemTitleTooltip:ft,inlineCollapsed:Gt,siderCollapsed:Tt,rootClassName:en,mode:yn,selectable:Rn,onClick:On,overflowedIndicatorPopupClassName:Pe}=ne,rt=zt(ne,["prefixCls","className","style","theme","expandIcon","_internalDisableMenuItemTitleTooltip","inlineCollapsed","siderCollapsed","rootClassName","mode","selectable","onClick","overflowedIndicatorPopupClassName"]),St=(0,Re.Z)(rt,["collapsedWidth"]);(xe=Ee.validator)===null||xe===void 0||xe.call(Ee,{mode:yn});const _t=(0,Me.Z)(function(){var mn;On==null||On.apply(void 0,arguments),(mn=Ee.onClick)===null||mn===void 0||mn.call(Ee)}),bn=Ee.mode||yn,In=Rn!=null?Rn:Ee.selectable,rr=Gt!=null?Gt:Tt,Xn={horizontal:{motionName:`${Kt}-slide-up`},inline:(0,Oe.Z)(Kt),other:{motionName:`${Kt}-zoom-big`}},Cn=Fe("menu",Wt||Ee.prefixCls),Fn=(0,Se.Z)(Cn),[xt,$t,vt]=cn(Cn,Fn,!ot),Vt=be()(`${Cn}-${qt}`,ct==null?void 0:ct.className,Nt),Ut=z.useMemo(()=>{var mn,xn;if(typeof on=="function"||ut(on))return on||null;if(typeof Ee.expandIcon=="function"||ut(Ee.expandIcon))return Ee.expandIcon||null;if(typeof(ct==null?void 0:ct.expandIcon)=="function"||ut(ct==null?void 0:ct.expandIcon))return(ct==null?void 0:ct.expandIcon)||null;const wn=(mn=on!=null?on:Ee==null?void 0:Ee.expandIcon)!==null&&mn!==void 0?mn:ct==null?void 0:ct.expandIcon;return(0,fe.Tm)(wn,{className:be()(`${Cn}-submenu-expand-icon`,z.isValidElement(wn)?(xn=wn.props)===null||xn===void 0?void 0:xn.className:void 0)})},[on,Ee==null?void 0:Ee.expandIcon,ct==null?void 0:ct.expandIcon,Cn]),En=z.useMemo(()=>({prefixCls:Cn,inlineCollapsed:rr||!1,direction:bt,firstLevel:!0,theme:qt,mode:bn,disableMenuItemTitleTooltip:ft}),[Cn,rr,bt,ft,qt]);return xt(z.createElement(st.Z.Provider,{value:null},z.createElement(Xe.Provider,{value:En},z.createElement(Ke.ZP,Object.assign({getPopupContainer:qe,overflowedIndicator:z.createElement(Ae.Z,null),overflowedIndicatorPopupClassName:be()(Cn,`${Cn}-${qt}`,Pe),mode:bn,selectable:In,onClick:_t},St,{inlineCollapsed:rr,style:Object.assign(Object.assign({},ct==null?void 0:ct.style),rn),className:Vt,prefixCls:Cn,direction:bt,defaultMotions:Xn,expandIcon:Ut,ref:he,rootClassName:be()(en,$t,Ee.rootClassName,vt,Fn),_internalComponents:ae})))))});const oe=(0,z.forwardRef)((ne,he)=>{const xe=(0,z.useRef)(null),ot=z.useContext(ve.D);return(0,z.useImperativeHandle)(he,()=>({menu:xe.current,focus:Ee=>{var Fe;(Fe=xe.current)===null||Fe===void 0||Fe.focus(Ee)}})),z.createElement(ee,Object.assign({ref:xe},ne,ot))});oe.Item=mt,oe.SubMenu=ze,oe.Divider=Ne,oe.ItemGroup=Ke.BW;var se=oe},82326:function(ln,Ft,ie){"use strict";var z=ie(59301),Ke=ie(92310),ve=ie.n(Ke),Ae=ie(37463),ye=ie(2738),be=ie(75030),Me=ie(86641),Re=ie(45915),Oe=ie(82855),fe=ie(48755),We=ie(38406),Se=ie(2171),yt=ie(83397),Xe=ie(31756),Le=ie(56553),Ge=ie(24971),Ne=ie(70045),dt=ie(57700),It=ie(1722),Bt=ie(90376),mt=ie(68525),st=ie(90005),it=function(ht,$e){var at={};for(var lt in ht)Object.prototype.hasOwnProperty.call(ht,lt)&&$e.indexOf(lt)<0&&(at[lt]=ht[lt]);if(ht!=null&&typeof Object.getOwnPropertySymbols=="function")for(var me=0,lt=Object.getOwnPropertySymbols(ht);me<lt.length;me++)$e.indexOf(lt[me])<0&&Object.prototype.propertyIsEnumerable.call(ht,lt[me])&&(at[lt[me]]=ht[lt[me]]);return at};const je="SECRET_COMBOBOX_MODE_DO_NOT_USE",Ot=(ht,$e)=>{var at;const{prefixCls:lt,bordered:me,className:At,rootClassName:De,getPopupContainer:He,popupClassName:Pt,dropdownClassName:ge,listHeight:ce=256,placement:Je,listItemHeight:jt,size:wt,disabled:Ie,notFoundContent:Ue,status:et,builtinPlacements:cn,dropdownMatchSelectWidth:kt,popupMatchSelectWidth:Yt,direction:ze,style:zt,allowClear:ut,variant:ae,dropdownStyle:te,transitionName:ee,tagRender:oe,maxCount:se,prefix:ne}=ht,he=it(ht,["prefixCls","bordered","className","rootClassName","getPopupContainer","popupClassName","dropdownClassName","listHeight","placement","listItemHeight","size","disabled","notFoundContent","status","builtinPlacements","dropdownMatchSelectWidth","popupMatchSelectWidth","direction","style","allowClear","variant","dropdownStyle","transitionName","tagRender","maxCount","prefix"]),{getPopupContainer:xe,getPrefixCls:ot,renderEmpty:Ee,direction:Fe,virtual:qe,popupMatchSelectWidth:bt,popupOverflow:ct}=z.useContext(fe.E_),Kt=(0,fe.dj)("select"),[,Wt]=(0,dt.ZP)(),Nt=jt!=null?jt:Wt==null?void 0:Wt.controlHeight,rn=ot("select",lt),qt=ot(),on=ze!=null?ze:Fe,{compactSize:ft,compactItemClassnames:Gt}=(0,Ne.ri)(rn,on),[Tt,en]=(0,Ge.Z)("select",ae,me),yn=(0,yt.Z)(rn),[Rn,On,Pe]=(0,Bt.Z)(rn,yn),rt=z.useMemo(()=>{const{mode:gn}=ht;if(gn!=="combobox")return gn===je?"combobox":gn},[ht.mode]),St=rt==="multiple"||rt==="tags",_t=(0,st.Z)(ht.suffixIcon,ht.showArrow),bn=(at=Yt!=null?Yt:kt)!==null&&at!==void 0?at:bt,{status:In,hasFeedback:rr,isFormItemInput:Xn,feedbackIcon:Cn}=z.useContext(Le.aM),Fn=(0,Oe.F)(In,et);let xt;Ue!==void 0?xt=Ue:rt==="combobox"?xt=null:xt=(Ee==null?void 0:Ee("Select"))||z.createElement(We.Z,{componentName:"Select"});const{suffixIcon:$t,itemIcon:vt,removeIcon:Vt,clearIcon:Ut}=(0,mt.Z)(Object.assign(Object.assign({},he),{multiple:St,hasFeedback:rr,feedbackIcon:Cn,showSuffixIcon:_t,prefixCls:rn,componentName:"Select"})),En=ut===!0?{clearIcon:Ut}:ut,mn=(0,ye.Z)(he,["suffixIcon","itemIcon"]),xn=ve()(Pt||ge,{[`${rn}-dropdown-${on}`]:on==="rtl"},De,Pe,yn,On),wn=(0,Xe.Z)(gn=>{var Dt;return(Dt=wt!=null?wt:ft)!==null&&Dt!==void 0?Dt:gn}),Bn=z.useContext(Se.Z),Zn=Ie!=null?Ie:Bn,Yn=ve()({[`${rn}-lg`]:wn==="large",[`${rn}-sm`]:wn==="small",[`${rn}-rtl`]:on==="rtl",[`${rn}-${Tt}`]:en,[`${rn}-in-form-item`]:Xn},(0,Oe.Z)(rn,Fn,rr),Gt,Kt.className,At,De,Pe,yn,On),Wn=z.useMemo(()=>Je!==void 0?Je:on==="rtl"?"bottomRight":"bottomLeft",[Je,on]),[ir]=(0,be.Cn)("SelectLike",te==null?void 0:te.zIndex);return Rn(z.createElement(Ae.ZP,Object.assign({ref:$e,virtual:qe,showSearch:Kt.showSearch},mn,{style:Object.assign(Object.assign({},Kt.style),zt),dropdownMatchSelectWidth:bn,transitionName:(0,Me.m)(qt,"slide-up",ee),builtinPlacements:(0,It.Z)(cn,ct),listHeight:ce,listItemHeight:Nt,mode:rt,prefixCls:rn,placement:Wn,direction:on,prefix:ne,suffixIcon:$t,menuItemSelectedIcon:vt,removeIcon:Vt,allowClear:En,notFoundContent:xt,className:Yn,getPopupContainer:He||xe,dropdownClassName:xn,disabled:Zn,dropdownStyle:Object.assign(Object.assign({},te),{zIndex:ir}),maxCount:St?se:void 0,tagRender:St?oe:void 0})))},nt=z.forwardRef(Ot),tt=(0,Re.Z)(nt,"dropdownAlign");nt.SECRET_COMBOBOX_MODE_DO_NOT_USE=je,nt.Option=Ae.Wx,nt.OptGroup=Ae.Xo,nt._InternalPanelDoNotUseOrYouWillBeFired=tt,Ft.default=nt},1722:function(ln,Ft){"use strict";const ie=Ke=>{const Ae={overflow:{adjustX:!0,adjustY:!0,shiftY:!0},htmlRegion:Ke==="scroll"?"scroll":"visible",dynamicInset:!0};return{bottomLeft:Object.assign(Object.assign({},Ae),{points:["tl","bl"],offset:[0,4]}),bottomRight:Object.assign(Object.assign({},Ae),{points:["tr","br"],offset:[0,4]}),topLeft:Object.assign(Object.assign({},Ae),{points:["bl","tl"],offset:[0,-4]}),topRight:Object.assign(Object.assign({},Ae),{points:["br","tr"],offset:[0,-4]})}};function z(Ke,ve){return Ke||ie(ve)}Ft.Z=z},90376:function(ln,Ft,ie){"use strict";ie.d(Ft,{Z:function(){return lt}});var z=ie(63356),Ke=ie(56119),ve=ie(16931),Ae=ie(51636),ye=ie(46e3),be=ie(93873);const Me=me=>{const{optionHeight:At,optionFontSize:De,optionLineHeight:He,optionPadding:Pt}=me;return{position:"relative",display:"block",minHeight:At,padding:Pt,color:me.colorText,fontWeight:"normal",fontSize:De,lineHeight:He,boxSizing:"border-box"}};var Oe=me=>{const{antCls:At,componentCls:De}=me,He=`${De}-item`,Pt=`&${At}-slide-up-enter${At}-slide-up-enter-active`,ge=`&${At}-slide-up-appear${At}-slide-up-appear-active`,ce=`&${At}-slide-up-leave${At}-slide-up-leave-active`,Je=`${De}-dropdown-placement-`,jt=`${He}-option-selected`;return[{[`${De}-dropdown`]:Object.assign(Object.assign({},(0,z.Wf)(me)),{position:"absolute",top:-9999,zIndex:me.zIndexPopup,boxSizing:"border-box",padding:me.paddingXXS,overflow:"hidden",fontSize:me.fontSize,fontVariant:"initial",backgroundColor:me.colorBgElevated,borderRadius:me.borderRadiusLG,outline:"none",boxShadow:me.boxShadowSecondary,[`
|
|
|
${Pt}${Je}bottomLeft,
|
|
|
${ge}${Je}bottomLeft
|
|
|
`]:{animationName:ye.fJ},[`
|
|
|
${Pt}${Je}topLeft,
|
|
|
${ge}${Je}topLeft,
|
|
|
${Pt}${Je}topRight,
|
|
|
${ge}${Je}topRight
|
|
|
`]:{animationName:ye.Qt},[`${ce}${Je}bottomLeft`]:{animationName:ye.Uw},[`
|
|
|
${ce}${Je}topLeft,
|
|
|
${ce}${Je}topRight
|
|
|
`]:{animationName:ye.ly},"&-hidden":{display:"none"},[He]:Object.assign(Object.assign({},Me(me)),{cursor:"pointer",transition:`background ${me.motionDurationSlow} ease`,borderRadius:me.borderRadiusSM,"&-group":{color:me.colorTextDescription,fontSize:me.fontSizeSM,cursor:"default"},"&-option":{display:"flex","&-content":Object.assign({flex:"auto"},z.vS),"&-state":{flex:"none",display:"flex",alignItems:"center"},[`&-active:not(${He}-option-disabled)`]:{backgroundColor:me.optionActiveBg},[`&-selected:not(${He}-option-disabled)`]:{color:me.optionSelectedColor,fontWeight:me.optionSelectedFontWeight,backgroundColor:me.optionSelectedBg,[`${He}-option-state`]:{color:me.colorPrimary}},"&-disabled":{[`&${He}-option-selected`]:{backgroundColor:me.colorBgContainerDisabled},color:me.colorTextDisabled,cursor:"not-allowed"},"&-grouped":{paddingInlineStart:me.calc(me.controlPaddingHorizontal).mul(2).equal()}},"&-empty":Object.assign(Object.assign({},Me(me)),{color:me.colorTextDisabled})}),[`${jt}:has(+ ${jt})`]:{borderEndStartRadius:0,borderEndEndRadius:0,[`& + ${jt}`]:{borderStartStartRadius:0,borderStartEndRadius:0}},"&-rtl":{direction:"rtl"}})},(0,ye.oN)(me,"slide-up"),(0,ye.oN)(me,"slide-down"),(0,be.Fm)(me,"move-up"),(0,be.Fm)(me,"move-down")]},fe=ie(26743),We=ie(36237);function Se(me,At){const{componentCls:De,inputPaddingHorizontalBase:He,borderRadius:Pt}=me,ge=me.calc(me.controlHeight).sub(me.calc(me.lineWidth).mul(2)).equal(),ce=At?`${De}-${At}`:"";return{[`${De}-single${ce}`]:{fontSize:me.fontSize,height:me.controlHeight,[`${De}-selector`]:Object.assign(Object.assign({},(0,z.Wf)(me,!0)),{display:"flex",borderRadius:Pt,flex:"1 1 auto",[`${De}-selection-wrap:after`]:{lineHeight:(0,We.unit)(ge)},[`${De}-selection-search`]:{position:"absolute",inset:0,width:"100%","&-input":{width:"100%",WebkitAppearance:"textfield"}},[`
|
|
|
${De}-selection-item,
|
|
|
${De}-selection-placeholder
|
|
|
`]:{display:"block",padding:0,lineHeight:(0,We.unit)(ge),transition:`all ${me.motionDurationSlow}, visibility 0s`,alignSelf:"center"},[`${De}-selection-placeholder`]:{transition:"none",pointerEvents:"none"},[["&:after",`${De}-selection-item:empty:after`,`${De}-selection-placeholder:empty:after`].join(",")]:{display:"inline-block",width:0,visibility:"hidden",content:'"\\a0"'}}),[`
|
|
|
&${De}-show-arrow ${De}-selection-item,
|
|
|
&${De}-show-arrow ${De}-selection-search,
|
|
|
&${De}-show-arrow ${De}-selection-placeholder
|
|
|
`]:{paddingInlineEnd:me.showArrowPaddingInlineEnd},[`&${De}-open ${De}-selection-item`]:{color:me.colorTextPlaceholder},[`&:not(${De}-customize-input)`]:{[`${De}-selector`]:{width:"100%",height:"100%",alignItems:"center",padding:`0 ${(0,We.unit)(He)}`,[`${De}-selection-search-input`]:{height:ge,fontSize:me.fontSize},"&:after":{lineHeight:(0,We.unit)(ge)}}},[`&${De}-customize-input`]:{[`${De}-selector`]:{"&:after":{display:"none"},[`${De}-selection-search`]:{position:"static",width:"100%"},[`${De}-selection-placeholder`]:{position:"absolute",insetInlineStart:0,insetInlineEnd:0,padding:`0 ${(0,We.unit)(He)}`,"&:after":{display:"none"}}}}}}}function yt(me){const{componentCls:At}=me,De=me.calc(me.controlPaddingHorizontalSM).sub(me.lineWidth).equal();return[Se(me),Se((0,Ae.mergeToken)(me,{controlHeight:me.controlHeightSM,borderRadius:me.borderRadiusSM}),"sm"),{[`${At}-single${At}-sm`]:{[`&:not(${At}-customize-input)`]:{[`${At}-selector`]:{padding:`0 ${(0,We.unit)(De)}`},[`&${At}-show-arrow ${At}-selection-search`]:{insetInlineEnd:me.calc(De).add(me.calc(me.fontSize).mul(1.5)).equal()},[`
|
|
|
&${At}-show-arrow ${At}-selection-item,
|
|
|
&${At}-show-arrow ${At}-selection-placeholder
|
|
|
`]:{paddingInlineEnd:me.calc(me.fontSize).mul(1.5).equal()}}}},Se((0,Ae.mergeToken)(me,{controlHeight:me.singleItemHeightLG,fontSize:me.fontSizeLG,borderRadius:me.borderRadiusLG}),"lg")]}const Xe=me=>{const{fontSize:At,lineHeight:De,lineWidth:He,controlHeight:Pt,controlHeightSM:ge,controlHeightLG:ce,paddingXXS:Je,controlPaddingHorizontal:jt,zIndexPopupBase:wt,colorText:Ie,fontWeightStrong:Ue,controlItemBgActive:et,controlItemBgHover:cn,colorBgContainer:kt,colorFillSecondary:Yt,colorBgContainerDisabled:ze,colorTextDisabled:zt,colorPrimaryHover:ut,colorPrimary:ae,controlOutline:te}=me,ee=Je*2,oe=He*2,se=Math.min(Pt-ee,Pt-oe),ne=Math.min(ge-ee,ge-oe),he=Math.min(ce-ee,ce-oe);return{INTERNAL_FIXED_ITEM_MARGIN:Math.floor(Je/2),zIndexPopup:wt+50,optionSelectedColor:Ie,optionSelectedFontWeight:Ue,optionSelectedBg:et,optionActiveBg:cn,optionPadding:`${(Pt-At*De)/2}px ${jt}px`,optionFontSize:At,optionLineHeight:De,optionHeight:Pt,selectorBg:kt,clearBg:kt,singleItemHeightLG:ce,multipleItemBg:Yt,multipleItemBorderColor:"transparent",multipleItemHeight:se,multipleItemHeightSM:ne,multipleItemHeightLG:he,multipleSelectorBgDisabled:ze,multipleItemColorDisabled:zt,multipleItemBorderColorDisabled:"transparent",showArrowPaddingInlineEnd:Math.ceil(me.fontSize*1.25),hoverBorderColor:ut,activeBorderColor:ae,activeOutlineColor:te,selectAffixPadding:Je}},Le=(me,At)=>{const{componentCls:De,antCls:He,controlOutlineWidth:Pt}=me;return{[`&:not(${De}-customize-input) ${De}-selector`]:{border:`${(0,We.unit)(me.lineWidth)} ${me.lineType} ${At.borderColor}`,background:me.selectorBg},[`&:not(${De}-disabled):not(${De}-customize-input):not(${He}-pagination-size-changer)`]:{[`&:hover ${De}-selector`]:{borderColor:At.hoverBorderHover},[`${De}-focused& ${De}-selector`]:{borderColor:At.activeBorderColor,boxShadow:`0 0 0 ${(0,We.unit)(Pt)} ${At.activeOutlineColor}`,outline:0},[`${De}-prefix`]:{color:At.color}}}},Ge=(me,At)=>({[`&${me.componentCls}-status-${At.status}`]:Object.assign({},Le(me,At))}),Ne=me=>({"&-outlined":Object.assign(Object.assign(Object.assign(Object.assign({},Le(me,{borderColor:me.colorBorder,hoverBorderHover:me.hoverBorderColor,activeBorderColor:me.activeBorderColor,activeOutlineColor:me.activeOutlineColor,color:me.colorText})),Ge(me,{status:"error",borderColor:me.colorError,hoverBorderHover:me.colorErrorHover,activeBorderColor:me.colorError,activeOutlineColor:me.colorErrorOutline,color:me.colorError})),Ge(me,{status:"warning",borderColor:me.colorWarning,hoverBorderHover:me.colorWarningHover,activeBorderColor:me.colorWarning,activeOutlineColor:me.colorWarningOutline,color:me.colorWarning})),{[`&${me.componentCls}-disabled`]:{[`&:not(${me.componentCls}-customize-input) ${me.componentCls}-selector`]:{background:me.colorBgContainerDisabled,color:me.colorTextDisabled}},[`&${me.componentCls}-multiple ${me.componentCls}-selection-item`]:{background:me.multipleItemBg,border:`${(0,We.unit)(me.lineWidth)} ${me.lineType} ${me.multipleItemBorderColor}`}})}),dt=(me,At)=>{const{componentCls:De,antCls:He}=me;return{[`&:not(${De}-customize-input) ${De}-selector`]:{background:At.bg,border:`${(0,We.unit)(me.lineWidth)} ${me.lineType} transparent`,color:At.color},[`&:not(${De}-disabled):not(${De}-customize-input):not(${He}-pagination-size-changer)`]:{[`&:hover ${De}-selector`]:{background:At.hoverBg},[`${De}-focused& ${De}-selector`]:{background:me.selectorBg,borderColor:At.activeBorderColor,outline:0}}}},It=(me,At)=>({[`&${me.componentCls}-status-${At.status}`]:Object.assign({},dt(me,At))}),Bt=me=>({"&-filled":Object.assign(Object.assign(Object.assign(Object.assign({},dt(me,{bg:me.colorFillTertiary,hoverBg:me.colorFillSecondary,activeBorderColor:me.activeBorderColor,color:me.colorText})),It(me,{status:"error",bg:me.colorErrorBg,hoverBg:me.colorErrorBgHover,activeBorderColor:me.colorError,color:me.colorError})),It(me,{status:"warning",bg:me.colorWarningBg,hoverBg:me.colorWarningBgHover,activeBorderColor:me.colorWarning,color:me.colorWarning})),{[`&${me.componentCls}-disabled`]:{[`&:not(${me.componentCls}-customize-input) ${me.componentCls}-selector`]:{borderColor:me.colorBorder,background:me.colorBgContainerDisabled,color:me.colorTextDisabled}},[`&${me.componentCls}-multiple ${me.componentCls}-selection-item`]:{background:me.colorBgContainer,border:`${(0,We.unit)(me.lineWidth)} ${me.lineType} ${me.colorSplit}`}})}),mt=me=>({"&-borderless":{[`${me.componentCls}-selector`]:{background:"transparent",border:`${(0,We.unit)(me.lineWidth)} ${me.lineType} transparent`},[`&${me.componentCls}-disabled`]:{[`&:not(${me.componentCls}-customize-input) ${me.componentCls}-selector`]:{color:me.colorTextDisabled}},[`&${me.componentCls}-multiple ${me.componentCls}-selection-item`]:{background:me.multipleItemBg,border:`${(0,We.unit)(me.lineWidth)} ${me.lineType} ${me.multipleItemBorderColor}`},[`&${me.componentCls}-status-error`]:{[`${me.componentCls}-prefix, ${me.componentCls}-selection-item`]:{color:me.colorError}},[`&${me.componentCls}-status-warning`]:{[`${me.componentCls}-prefix, ${me.componentCls}-selection-item`]:{color:me.colorWarning}}}}),st=(me,At)=>{const{componentCls:De,antCls:He}=me;return{[`&:not(${De}-customize-input) ${De}-selector`]:{borderWidth:`0 0 ${(0,We.unit)(me.lineWidth)} 0`,borderStyle:`none none ${me.lineType} none`,borderColor:At.borderColor,background:me.selectorBg,borderRadius:0},[`&:not(${De}-disabled):not(${De}-customize-input):not(${He}-pagination-size-changer)`]:{[`&:hover ${De}-selector`]:{borderColor:At.hoverBorderHover},[`${De}-focused& ${De}-selector`]:{borderColor:At.activeBorderColor,outline:0},[`${De}-prefix`]:{color:At.color}}}},it=(me,At)=>({[`&${me.componentCls}-status-${At.status}`]:Object.assign({},st(me,At))}),je=me=>({"&-underlined":Object.assign(Object.assign(Object.assign(Object.assign({},st(me,{borderColor:me.colorBorder,hoverBorderHover:me.hoverBorderColor,activeBorderColor:me.activeBorderColor,activeOutlineColor:me.activeOutlineColor,color:me.colorText})),it(me,{status:"error",borderColor:me.colorError,hoverBorderHover:me.colorErrorHover,activeBorderColor:me.colorError,activeOutlineColor:me.colorErrorOutline,color:me.colorError})),it(me,{status:"warning",borderColor:me.colorWarning,hoverBorderHover:me.colorWarningHover,activeBorderColor:me.colorWarning,activeOutlineColor:me.colorWarningOutline,color:me.colorWarning})),{[`&${me.componentCls}-disabled`]:{[`&:not(${me.componentCls}-customize-input) ${me.componentCls}-selector`]:{color:me.colorTextDisabled}},[`&${me.componentCls}-multiple ${me.componentCls}-selection-item`]:{background:me.multipleItemBg,border:`${(0,We.unit)(me.lineWidth)} ${me.lineType} ${me.multipleItemBorderColor}`}})});var nt=me=>({[me.componentCls]:Object.assign(Object.assign(Object.assign(Object.assign({},Ne(me)),Bt(me)),mt(me)),je(me))});const tt=me=>{const{componentCls:At}=me;return{position:"relative",transition:`all ${me.motionDurationMid} ${me.motionEaseInOut}`,input:{cursor:"pointer"},[`${At}-show-search&`]:{cursor:"text",input:{cursor:"auto",color:"inherit",height:"100%"}},[`${At}-disabled&`]:{cursor:"not-allowed",input:{cursor:"not-allowed"}}}},ht=me=>{const{componentCls:At}=me;return{[`${At}-selection-search-input`]:{margin:0,padding:0,background:"transparent",border:"none",outline:"none",appearance:"none",fontFamily:"inherit","&::-webkit-search-cancel-button":{display:"none",appearance:"none"}}}},$e=me=>{const{antCls:At,componentCls:De,inputPaddingHorizontalBase:He,iconCls:Pt}=me;return{[De]:Object.assign(Object.assign({},(0,z.Wf)(me)),{position:"relative",display:"inline-flex",cursor:"pointer",[`&:not(${De}-customize-input) ${De}-selector`]:Object.assign(Object.assign({},tt(me)),ht(me)),[`${De}-selection-item`]:Object.assign(Object.assign({flex:1,fontWeight:"normal",position:"relative",userSelect:"none"},z.vS),{[`> ${At}-typography`]:{display:"inline"}}),[`${De}-selection-placeholder`]:Object.assign(Object.assign({},z.vS),{flex:1,color:me.colorTextPlaceholder,pointerEvents:"none"}),[`${De}-arrow`]:Object.assign(Object.assign({},(0,z.Ro)()),{position:"absolute",top:"50%",insetInlineStart:"auto",insetInlineEnd:He,height:me.fontSizeIcon,marginTop:me.calc(me.fontSizeIcon).mul(-1).div(2).equal(),color:me.colorTextQuaternary,fontSize:me.fontSizeIcon,lineHeight:1,textAlign:"center",pointerEvents:"none",display:"flex",alignItems:"center",transition:`opacity ${me.motionDurationSlow} ease`,[Pt]:{verticalAlign:"top",transition:`transform ${me.motionDurationSlow}`,"> svg":{verticalAlign:"top"},[`&:not(${De}-suffix)`]:{pointerEvents:"auto"}},[`${De}-disabled &`]:{cursor:"not-allowed"},"> *:not(:last-child)":{marginInlineEnd:8}}),[`${De}-selection-wrap`]:{display:"flex",width:"100%",position:"relative",minWidth:0,"&:after":{content:'"\\a0"',width:0,overflow:"hidden"}},[`${De}-prefix`]:{flex:"none",marginInlineEnd:me.selectAffixPadding},[`${De}-clear`]:{position:"absolute",top:"50%",insetInlineStart:"auto",insetInlineEnd:He,zIndex:1,display:"inline-block",width:me.fontSizeIcon,height:me.fontSizeIcon,marginTop:me.calc(me.fontSizeIcon).mul(-1).div(2).equal(),color:me.colorTextQuaternary,fontSize:me.fontSizeIcon,fontStyle:"normal",lineHeight:1,textAlign:"center",textTransform:"none",cursor:"pointer",opacity:0,transition:`color ${me.motionDurationMid} ease, opacity ${me.motionDurationSlow} ease`,textRendering:"auto","&:before":{display:"block"},"&:hover":{color:me.colorTextTertiary}},[`&:hover ${De}-clear`]:{opacity:1,background:me.colorBgBase,borderRadius:"50%"}}),[`${De}-status`]:{"&-error, &-warning, &-success, &-validating":{[`&${De}-has-feedback`]:{[`${De}-clear`]:{insetInlineEnd:me.calc(He).add(me.fontSize).add(me.paddingXS).equal()}}}}}},at=me=>{const{componentCls:At}=me;return[{[At]:{[`&${At}-in-form-item`]:{width:"100%"}}},$e(me),yt(me),(0,fe.ZP)(me),Oe(me),{[`${At}-rtl`]:{direction:"rtl"}},(0,Ke.c)(me,{borderElCls:`${At}-selector`,focusElCls:`${At}-focused`})]};var lt=(0,ve.I$)("Select",(me,At)=>{let{rootPrefixCls:De}=At;const He=(0,Ae.mergeToken)(me,{rootPrefixCls:De,inputPaddingHorizontalBase:me.calc(me.paddingSM).sub(1).equal(),multipleSelectItemHeight:me.multipleItemHeight,selectHeight:me.controlHeight});return[at(He),nt(He)]},Xe,{unitless:{optionLineHeight:!0,optionSelectedFontWeight:!0}})},26743:function(ln,Ft,ie){"use strict";ie.d(Ft,{_z:function(){return be},gp:function(){return Ae}});var z=ie(36237),Ke=ie(63356),ve=ie(51636);const Ae=fe=>{const{multipleSelectItemHeight:We,paddingXXS:Se,lineWidth:yt,INTERNAL_FIXED_ITEM_MARGIN:Xe}=fe,Le=fe.max(fe.calc(Se).sub(yt).equal(),0),Ge=fe.max(fe.calc(Le).sub(Xe).equal(),0);return{basePadding:Le,containerPadding:Ge,itemHeight:(0,z.unit)(We),itemLineHeight:(0,z.unit)(fe.calc(We).sub(fe.calc(fe.lineWidth).mul(2)).equal())}},ye=fe=>{const{multipleSelectItemHeight:We,selectHeight:Se,lineWidth:yt}=fe;return fe.calc(Se).sub(We).div(2).sub(yt).equal()},be=fe=>{const{componentCls:We,iconCls:Se,borderRadiusSM:yt,motionDurationSlow:Xe,paddingXS:Le,multipleItemColorDisabled:Ge,multipleItemBorderColorDisabled:Ne,colorIcon:dt,colorIconHover:It,INTERNAL_FIXED_ITEM_MARGIN:Bt}=fe;return{[`${We}-selection-overflow`]:{position:"relative",display:"flex",flex:"auto",flexWrap:"wrap",maxWidth:"100%","&-item":{flex:"none",alignSelf:"center",maxWidth:"100%",display:"inline-flex"},[`${We}-selection-item`]:{display:"flex",alignSelf:"center",flex:"none",boxSizing:"border-box",maxWidth:"100%",marginBlock:Bt,borderRadius:yt,cursor:"default",transition:`font-size ${Xe}, line-height ${Xe}, height ${Xe}`,marginInlineEnd:fe.calc(Bt).mul(2).equal(),paddingInlineStart:Le,paddingInlineEnd:fe.calc(Le).div(2).equal(),[`${We}-disabled&`]:{color:Ge,borderColor:Ne,cursor:"not-allowed"},"&-content":{display:"inline-block",marginInlineEnd:fe.calc(Le).div(2).equal(),overflow:"hidden",whiteSpace:"pre",textOverflow:"ellipsis"},"&-remove":Object.assign(Object.assign({},(0,Ke.Ro)()),{display:"inline-flex",alignItems:"center",color:dt,fontWeight:"bold",fontSize:10,lineHeight:"inherit",cursor:"pointer",[`> ${Se}`]:{verticalAlign:"-0.2em"},"&:hover":{color:It}})}}}},Me=(fe,We)=>{const{componentCls:Se,INTERNAL_FIXED_ITEM_MARGIN:yt}=fe,Xe=`${Se}-selection-overflow`,Le=fe.multipleSelectItemHeight,Ge=ye(fe),Ne=We?`${Se}-${We}`:"",dt=Ae(fe);return{[`${Se}-multiple${Ne}`]:Object.assign(Object.assign({},be(fe)),{[`${Se}-selector`]:{display:"flex",alignItems:"center",width:"100%",height:"100%",paddingInline:dt.basePadding,paddingBlock:dt.containerPadding,borderRadius:fe.borderRadius,[`${Se}-disabled&`]:{background:fe.multipleSelectorBgDisabled,cursor:"not-allowed"},"&:after":{display:"inline-block",width:0,margin:`${(0,z.unit)(yt)} 0`,lineHeight:(0,z.unit)(Le),visibility:"hidden",content:'"\\a0"'}},[`${Se}-selection-item`]:{height:dt.itemHeight,lineHeight:(0,z.unit)(dt.itemLineHeight)},[`${Se}-selection-wrap`]:{alignSelf:"flex-start","&:after":{lineHeight:(0,z.unit)(Le),marginBlock:yt}},[`${Se}-prefix`]:{marginInlineStart:fe.calc(fe.inputPaddingHorizontalBase).sub(dt.basePadding).equal()},[`${Xe}-item + ${Xe}-item,
|
|
|
${Se}-prefix + ${Se}-selection-wrap
|
|
|
`]:{[`${Se}-selection-search`]:{marginInlineStart:0},[`${Se}-selection-placeholder`]:{insetInlineStart:0}},[`${Xe}-item-suffix`]:{minHeight:dt.itemHeight,marginBlock:yt},[`${Se}-selection-search`]:{display:"inline-flex",position:"relative",maxWidth:"100%",marginInlineStart:fe.calc(fe.inputPaddingHorizontalBase).sub(Ge).equal(),"\n &-input,\n &-mirror\n ":{height:Le,fontFamily:fe.fontFamily,lineHeight:(0,z.unit)(Le),transition:`all ${fe.motionDurationSlow}`},"&-input":{width:"100%",minWidth:4.1},"&-mirror":{position:"absolute",top:0,insetInlineStart:0,insetInlineEnd:"auto",zIndex:999,whiteSpace:"pre",visibility:"hidden"}},[`${Se}-selection-placeholder`]:{position:"absolute",top:"50%",insetInlineStart:fe.calc(fe.inputPaddingHorizontalBase).sub(dt.basePadding).equal(),insetInlineEnd:fe.inputPaddingHorizontalBase,transform:"translateY(-50%)",transition:`all ${fe.motionDurationSlow}`}})}};function Re(fe,We){const{componentCls:Se}=fe,yt=We?`${Se}-${We}`:"",Xe={[`${Se}-multiple${yt}`]:{fontSize:fe.fontSize,[`${Se}-selector`]:{[`${Se}-show-search&`]:{cursor:"text"}},[`
|
|
|
&${Se}-show-arrow ${Se}-selector,
|
|
|
&${Se}-allow-clear ${Se}-selector
|
|
|
`]:{paddingInlineEnd:fe.calc(fe.fontSizeIcon).add(fe.controlPaddingHorizontal).equal()}}};return[Me(fe,We),Xe]}const Oe=fe=>{const{componentCls:We}=fe,Se=(0,ve.mergeToken)(fe,{selectHeight:fe.controlHeightSM,multipleSelectItemHeight:fe.multipleItemHeightSM,borderRadius:fe.borderRadiusSM,borderRadiusSM:fe.borderRadiusXS}),yt=(0,ve.mergeToken)(fe,{fontSize:fe.fontSizeLG,selectHeight:fe.controlHeightLG,multipleSelectItemHeight:fe.multipleItemHeightLG,borderRadius:fe.borderRadiusLG,borderRadiusSM:fe.borderRadius});return[Re(fe),Re(Se,"sm"),{[`${We}-multiple${We}-sm`]:{[`${We}-selection-placeholder`]:{insetInline:fe.calc(fe.controlPaddingHorizontalSM).sub(fe.lineWidth).equal()},[`${We}-selection-search`]:{marginInlineStart:2}}},Re(yt,"lg")]};Ft.ZP=Oe},68525:function(ln,Ft,ie){"use strict";ie.d(Ft,{Z:function(){return Re}});var z=ie(59301),Ke=ie(40001),ve=ie(19248),Ae=ie(99267),ye=ie(84105),be=ie(58617),Me=ie(47472);function Re(Oe){let{suffixIcon:fe,clearIcon:We,menuItemSelectedIcon:Se,removeIcon:yt,loading:Xe,multiple:Le,hasFeedback:Ge,prefixCls:Ne,showSuffixIcon:dt,feedbackIcon:It,showArrow:Bt,componentName:mt}=Oe;const st=We!=null?We:z.createElement(ve.Z,null),it=tt=>fe===null&&!Ge&&!Bt?null:z.createElement(z.Fragment,null,dt!==!1&&tt,Ge&&It);let je=null;if(fe!==void 0)je=it(fe);else if(Xe)je=it(z.createElement(be.Z,{spin:!0}));else{const tt=`${Ne}-suffix`;je=ht=>{let{open:$e,showSearch:at}=ht;return it($e&&at?z.createElement(Me.Z,{className:tt}):z.createElement(ye.Z,{className:tt}))}}let Ot=null;Se!==void 0?Ot=Se:Le?Ot=z.createElement(Ke.Z,null):Ot=null;let nt=null;return yt!==void 0?nt=yt:nt=z.createElement(Ae.Z,null),{clearIcon:st,suffixIcon:je,itemIcon:Ot,removeIcon:nt}}},90005:function(ln,Ft,ie){"use strict";ie.d(Ft,{Z:function(){return z}});function z(Ke,ve){return ve!==void 0?ve:Ke!==null}},58755:function(ln,Ft,ie){"use strict";ie.d(Ft,{Z:function(){return At}});var z=ie(59301),Ke=ie(58617),ve=ie(92310),Ae=ie.n(ve),ye=ie(54476),be=ie(20068),Me=ie(42978),Re=ie(75931),Oe=ie(18929),fe=ie(10228),We=["prefixCls","className","checked","defaultChecked","disabled","loadingIcon","checkedChildren","unCheckedChildren","onClick","onChange","onKeyDown"],Se=z.forwardRef(function(De,He){var Pt,ge=De.prefixCls,ce=ge===void 0?"rc-switch":ge,Je=De.className,jt=De.checked,wt=De.defaultChecked,Ie=De.disabled,Ue=De.loadingIcon,et=De.checkedChildren,cn=De.unCheckedChildren,kt=De.onClick,Yt=De.onChange,ze=De.onKeyDown,zt=(0,Re.Z)(De,We),ut=(0,Oe.Z)(!1,{value:jt,defaultValue:wt}),ae=(0,Me.Z)(ut,2),te=ae[0],ee=ae[1];function oe(xe,ot){var Ee=te;return Ie||(Ee=xe,ee(Ee),Yt==null||Yt(Ee,ot)),Ee}function se(xe){xe.which===fe.Z.LEFT?oe(!1,xe):xe.which===fe.Z.RIGHT&&oe(!0,xe),ze==null||ze(xe)}function ne(xe){var ot=oe(!te,xe);kt==null||kt(ot,xe)}var he=Ae()(ce,Je,(Pt={},(0,be.Z)(Pt,"".concat(ce,"-checked"),te),(0,be.Z)(Pt,"".concat(ce,"-disabled"),Ie),Pt));return z.createElement("button",(0,ye.Z)({},zt,{type:"button",role:"switch","aria-checked":te,disabled:Ie,className:he,ref:He,onKeyDown:se,onClick:ne}),Ue,z.createElement("span",{className:"".concat(ce,"-inner")},z.createElement("span",{className:"".concat(ce,"-inner-checked")},et),z.createElement("span",{className:"".concat(ce,"-inner-unchecked")},cn)))});Se.displayName="Switch";var yt=Se,Xe=ie(12919),Le=ie(48755),Ge=ie(2171),Ne=ie(31756),dt=ie(36237),It=ie(17835),Bt=ie(63356),mt=ie(16931),st=ie(51636);const it=De=>{const{componentCls:He,trackHeightSM:Pt,trackPadding:ge,trackMinWidthSM:ce,innerMinMarginSM:Je,innerMaxMarginSM:jt,handleSizeSM:wt,calc:Ie}=De,Ue=`${He}-inner`,et=(0,dt.unit)(Ie(wt).add(Ie(ge).mul(2)).equal()),cn=(0,dt.unit)(Ie(jt).mul(2).equal());return{[He]:{[`&${He}-small`]:{minWidth:ce,height:Pt,lineHeight:(0,dt.unit)(Pt),[`${He}-inner`]:{paddingInlineStart:jt,paddingInlineEnd:Je,[`${Ue}-checked, ${Ue}-unchecked`]:{minHeight:Pt},[`${Ue}-checked`]:{marginInlineStart:`calc(-100% + ${et} - ${cn})`,marginInlineEnd:`calc(100% - ${et} + ${cn})`},[`${Ue}-unchecked`]:{marginTop:Ie(Pt).mul(-1).equal(),marginInlineStart:0,marginInlineEnd:0}},[`${He}-handle`]:{width:wt,height:wt},[`${He}-loading-icon`]:{top:Ie(Ie(wt).sub(De.switchLoadingIconSize)).div(2).equal(),fontSize:De.switchLoadingIconSize},[`&${He}-checked`]:{[`${He}-inner`]:{paddingInlineStart:Je,paddingInlineEnd:jt,[`${Ue}-checked`]:{marginInlineStart:0,marginInlineEnd:0},[`${Ue}-unchecked`]:{marginInlineStart:`calc(100% - ${et} + ${cn})`,marginInlineEnd:`calc(-100% + ${et} - ${cn})`}},[`${He}-handle`]:{insetInlineStart:`calc(100% - ${(0,dt.unit)(Ie(wt).add(ge).equal())})`}},[`&:not(${He}-disabled):active`]:{[`&:not(${He}-checked) ${Ue}`]:{[`${Ue}-unchecked`]:{marginInlineStart:Ie(De.marginXXS).div(2).equal(),marginInlineEnd:Ie(De.marginXXS).mul(-1).div(2).equal()}},[`&${He}-checked ${Ue}`]:{[`${Ue}-checked`]:{marginInlineStart:Ie(De.marginXXS).mul(-1).div(2).equal(),marginInlineEnd:Ie(De.marginXXS).div(2).equal()}}}}}}},je=De=>{const{componentCls:He,handleSize:Pt,calc:ge}=De;return{[He]:{[`${He}-loading-icon${De.iconCls}`]:{position:"relative",top:ge(ge(Pt).sub(De.fontSize)).div(2).equal(),color:De.switchLoadingIconColor,verticalAlign:"top"},[`&${He}-checked ${He}-loading-icon`]:{color:De.switchColor}}}},Ot=De=>{const{componentCls:He,trackPadding:Pt,handleBg:ge,handleShadow:ce,handleSize:Je,calc:jt}=De,wt=`${He}-handle`;return{[He]:{[wt]:{position:"absolute",top:Pt,insetInlineStart:Pt,width:Je,height:Je,transition:`all ${De.switchDuration} ease-in-out`,"&::before":{position:"absolute",top:0,insetInlineEnd:0,bottom:0,insetInlineStart:0,backgroundColor:ge,borderRadius:jt(Je).div(2).equal(),boxShadow:ce,transition:`all ${De.switchDuration} ease-in-out`,content:'""'}},[`&${He}-checked ${wt}`]:{insetInlineStart:`calc(100% - ${(0,dt.unit)(jt(Je).add(Pt).equal())})`},[`&:not(${He}-disabled):active`]:{[`${wt}::before`]:{insetInlineEnd:De.switchHandleActiveInset,insetInlineStart:0},[`&${He}-checked ${wt}::before`]:{insetInlineEnd:0,insetInlineStart:De.switchHandleActiveInset}}}}},nt=De=>{const{componentCls:He,trackHeight:Pt,trackPadding:ge,innerMinMargin:ce,innerMaxMargin:Je,handleSize:jt,calc:wt}=De,Ie=`${He}-inner`,Ue=(0,dt.unit)(wt(jt).add(wt(ge).mul(2)).equal()),et=(0,dt.unit)(wt(Je).mul(2).equal());return{[He]:{[Ie]:{display:"block",overflow:"hidden",borderRadius:100,height:"100%",paddingInlineStart:Je,paddingInlineEnd:ce,transition:`padding-inline-start ${De.switchDuration} ease-in-out, padding-inline-end ${De.switchDuration} ease-in-out`,[`${Ie}-checked, ${Ie}-unchecked`]:{display:"block",color:De.colorTextLightSolid,fontSize:De.fontSizeSM,transition:`margin-inline-start ${De.switchDuration} ease-in-out, margin-inline-end ${De.switchDuration} ease-in-out`,pointerEvents:"none",minHeight:Pt},[`${Ie}-checked`]:{marginInlineStart:`calc(-100% + ${Ue} - ${et})`,marginInlineEnd:`calc(100% - ${Ue} + ${et})`},[`${Ie}-unchecked`]:{marginTop:wt(Pt).mul(-1).equal(),marginInlineStart:0,marginInlineEnd:0}},[`&${He}-checked ${Ie}`]:{paddingInlineStart:ce,paddingInlineEnd:Je,[`${Ie}-checked`]:{marginInlineStart:0,marginInlineEnd:0},[`${Ie}-unchecked`]:{marginInlineStart:`calc(100% - ${Ue} + ${et})`,marginInlineEnd:`calc(-100% + ${Ue} - ${et})`}},[`&:not(${He}-disabled):active`]:{[`&:not(${He}-checked) ${Ie}`]:{[`${Ie}-unchecked`]:{marginInlineStart:wt(ge).mul(2).equal(),marginInlineEnd:wt(ge).mul(-1).mul(2).equal()}},[`&${He}-checked ${Ie}`]:{[`${Ie}-checked`]:{marginInlineStart:wt(ge).mul(-1).mul(2).equal(),marginInlineEnd:wt(ge).mul(2).equal()}}}}}},tt=De=>{const{componentCls:He,trackHeight:Pt,trackMinWidth:ge}=De;return{[He]:Object.assign(Object.assign(Object.assign(Object.assign({},(0,Bt.Wf)(De)),{position:"relative",display:"inline-block",boxSizing:"border-box",minWidth:ge,height:Pt,lineHeight:(0,dt.unit)(Pt),verticalAlign:"middle",background:De.colorTextQuaternary,border:"0",borderRadius:100,cursor:"pointer",transition:`all ${De.motionDurationMid}`,userSelect:"none",[`&:hover:not(${He}-disabled)`]:{background:De.colorTextTertiary}}),(0,Bt.Qy)(De)),{[`&${He}-checked`]:{background:De.switchColor,[`&:hover:not(${He}-disabled)`]:{background:De.colorPrimaryHover}},[`&${He}-loading, &${He}-disabled`]:{cursor:"not-allowed",opacity:De.switchDisabledOpacity,"*":{boxShadow:"none",cursor:"not-allowed"}},[`&${He}-rtl`]:{direction:"rtl"}})}},ht=De=>{const{fontSize:He,lineHeight:Pt,controlHeight:ge,colorWhite:ce}=De,Je=He*Pt,jt=ge/2,wt=2,Ie=Je-wt*2,Ue=jt-wt*2;return{trackHeight:Je,trackHeightSM:jt,trackMinWidth:Ie*2+wt*4,trackMinWidthSM:Ue*2+wt*2,trackPadding:wt,handleBg:ce,handleSize:Ie,handleSizeSM:Ue,handleShadow:`0 2px 4px 0 ${new It.FastColor("#00230b").setA(.2).toRgbString()}`,innerMinMargin:Ie/2,innerMaxMargin:Ie+wt+wt*2,innerMinMarginSM:Ue/2,innerMaxMarginSM:Ue+wt+wt*2}};var $e=(0,mt.I$)("Switch",De=>{const He=(0,st.mergeToken)(De,{switchDuration:De.motionDurationMid,switchColor:De.colorPrimary,switchDisabledOpacity:De.opacityLoading,switchLoadingIconSize:De.calc(De.fontSizeIcon).mul(.75).equal(),switchLoadingIconColor:`rgba(0, 0, 0, ${De.opacityLoading})`,switchHandleActiveInset:"-30%"});return[tt(He),nt(He),Ot(He),je(He),it(He)]},ht),at=function(De,He){var Pt={};for(var ge in De)Object.prototype.hasOwnProperty.call(De,ge)&&He.indexOf(ge)<0&&(Pt[ge]=De[ge]);if(De!=null&&typeof Object.getOwnPropertySymbols=="function")for(var ce=0,ge=Object.getOwnPropertySymbols(De);ce<ge.length;ce++)He.indexOf(ge[ce])<0&&Object.prototype.propertyIsEnumerable.call(De,ge[ce])&&(Pt[ge[ce]]=De[ge[ce]]);return Pt};const me=z.forwardRef((De,He)=>{const{prefixCls:Pt,size:ge,disabled:ce,loading:Je,className:jt,rootClassName:wt,style:Ie,checked:Ue,value:et,defaultChecked:cn,defaultValue:kt,onChange:Yt}=De,ze=at(De,["prefixCls","size","disabled","loading","className","rootClassName","style","checked","value","defaultChecked","defaultValue","onChange"]),[zt,ut]=(0,Oe.Z)(!1,{value:Ue!=null?Ue:et,defaultValue:cn!=null?cn:kt}),{getPrefixCls:ae,direction:te,switch:ee}=z.useContext(Le.E_),oe=z.useContext(Ge.Z),se=(ce!=null?ce:oe)||Je,ne=ae("switch",Pt),he=z.createElement("div",{className:`${ne}-handle`},Je&&z.createElement(Ke.Z,{className:`${ne}-loading-icon`})),[xe,ot,Ee]=$e(ne),Fe=(0,Ne.Z)(ge),qe=Ae()(ee==null?void 0:ee.className,{[`${ne}-small`]:Fe==="small",[`${ne}-loading`]:Je,[`${ne}-rtl`]:te==="rtl"},jt,wt,ot,Ee),bt=Object.assign(Object.assign({},ee==null?void 0:ee.style),Ie),ct=function(){ut(arguments.length<=0?void 0:arguments[0]),Yt==null||Yt.apply(void 0,arguments)};return xe(z.createElement(Xe.Z,{component:"Switch"},z.createElement(yt,Object.assign({},ze,{checked:zt,onChange:ct,prefixCls:ne,className:qe,style:bt,disabled:se,ref:He,loadingIcon:he}))))});me.__ANT_SWITCH=!0;var At=me},99498:function(ln,Ft,ie){(function(z){z(ie(89780))})(function(z){z.defineOption("placeholder","",function(Re,Oe,fe){var We=fe&&fe!=z.Init;if(Oe&&!We)Re.on("blur",ye),Re.on("change",be),Re.on("swapDoc",be),z.on(Re.getInputField(),"compositionupdate",Re.state.placeholderCompose=function(){Ae(Re)}),be(Re);else if(!Oe&&We){Re.off("blur",ye),Re.off("change",be),Re.off("swapDoc",be),z.off(Re.getInputField(),"compositionupdate",Re.state.placeholderCompose),Ke(Re);var Se=Re.getWrapperElement();Se.className=Se.className.replace(" CodeMirror-empty","")}Oe&&!Re.hasFocus()&&ye(Re)});function Ke(Re){Re.state.placeholder&&(Re.state.placeholder.parentNode.removeChild(Re.state.placeholder),Re.state.placeholder=null)}function ve(Re){Ke(Re);var Oe=Re.state.placeholder=document.createElement("pre");Oe.style.cssText="height: 0; overflow: visible",Oe.style.direction=Re.getOption("direction"),Oe.className="CodeMirror-placeholder CodeMirror-line-like";var fe=Re.getOption("placeholder");typeof fe=="string"&&(fe=document.createTextNode(fe)),Oe.appendChild(fe),Re.display.lineSpace.insertBefore(Oe,Re.display.lineSpace.firstChild)}function Ae(Re){setTimeout(function(){var Oe=!1,fe=Re.getInputField();fe.nodeName=="TEXTAREA"?Oe=!fe.value:Re.lineCount()==1&&(Oe=!/[^\u200b]/.test(fe.querySelector(".CodeMirror-line").textContent)),Oe?ve(Re):Ke(Re)},20)}function ye(Re){Me(Re)&&ve(Re)}function be(Re){var Oe=Re.getWrapperElement(),fe=Me(Re);Oe.className=Oe.className.replace(" CodeMirror-empty","")+(fe?" CodeMirror-empty":""),fe?ve(Re):Ke(Re)}function Me(Re){return Re.lineCount()===1&&Re.getLine(0)===""}})},25717:function(ln,Ft,ie){(function(z){z(ie(89780))})(function(z){var Ke={pairs:`()[]{}''""`,closeBefore:`)]}'":;>`,triples:"",explode:"[]{}"},ve=z.Pos;z.defineOption("autoCloseBrackets",!1,function(Le,Ge,Ne){Ne&&Ne!=z.Init&&(Le.removeKeyMap(ye),Le.state.closeBrackets=null),Ge&&(be(Ae(Ge,"pairs")),Le.state.closeBrackets=Ge,Le.addKeyMap(ye))});function Ae(Le,Ge){return Ge=="pairs"&&typeof Le=="string"?Le:typeof Le=="object"&&Le[Ge]!=null?Le[Ge]:Ke[Ge]}var ye={Backspace:Oe,Enter:fe};function be(Le){for(var Ge=0;Ge<Le.length;Ge++){var Ne=Le.charAt(Ge),dt="'"+Ne+"'";ye[dt]||(ye[dt]=Me(Ne))}}be(Ke.pairs+"`");function Me(Le){return function(Ge){return Se(Ge,Le)}}function Re(Le){var Ge=Le.state.closeBrackets;if(!Ge||Ge.override)return Ge;var Ne=Le.getModeAt(Le.getCursor());return Ne.closeBrackets||Ge}function Oe(Le){var Ge=Re(Le);if(!Ge||Le.getOption("disableInput"))return z.Pass;for(var Ne=Ae(Ge,"pairs"),dt=Le.listSelections(),It=0;It<dt.length;It++){if(!dt[It].empty())return z.Pass;var Bt=yt(Le,dt[It].head);if(!Bt||Ne.indexOf(Bt)%2!=0)return z.Pass}for(var It=dt.length-1;It>=0;It--){var mt=dt[It].head;Le.replaceRange("",ve(mt.line,mt.ch-1),ve(mt.line,mt.ch+1),"+delete")}}function fe(Le){var Ge=Re(Le),Ne=Ge&&Ae(Ge,"explode");if(!Ne||Le.getOption("disableInput"))return z.Pass;for(var dt=Le.listSelections(),It=0;It<dt.length;It++){if(!dt[It].empty())return z.Pass;var Bt=yt(Le,dt[It].head);if(!Bt||Ne.indexOf(Bt)%2!=0)return z.Pass}Le.operation(function(){var mt=Le.lineSeparator()||`
|
|
|
`;Le.replaceSelection(mt+mt,null),Le.execCommand("goCharLeft"),dt=Le.listSelections();for(var st=0;st<dt.length;st++){var it=dt[st].head.line;Le.indentLine(it,null,!0),Le.indentLine(it+1,null,!0)}})}function We(Le){var Ge=z.cmpPos(Le.anchor,Le.head)>0;return{anchor:new ve(Le.anchor.line,Le.anchor.ch+(Ge?-1:1)),head:new ve(Le.head.line,Le.head.ch+(Ge?1:-1))}}function Se(Le,Ge){var Ne=Re(Le);if(!Ne||Le.getOption("disableInput"))return z.Pass;var dt=Ae(Ne,"pairs"),It=dt.indexOf(Ge);if(It==-1)return z.Pass;for(var Bt=Ae(Ne,"closeBefore"),mt=Ae(Ne,"triples"),st=dt.charAt(It+1)==Ge,it=Le.listSelections(),je=It%2==0,Ot,nt=0;nt<it.length;nt++){var tt=it[nt],ht=tt.head,$e,at=Le.getRange(ht,ve(ht.line,ht.ch+1));if(je&&!tt.empty())$e="surround";else if((st||!je)&&at==Ge)st&&Xe(Le,ht)?$e="both":mt.indexOf(Ge)>=0&&Le.getRange(ht,ve(ht.line,ht.ch+3))==Ge+Ge+Ge?$e="skipThree":$e="skip";else if(st&&ht.ch>1&&mt.indexOf(Ge)>=0&&Le.getRange(ve(ht.line,ht.ch-2),ht)==Ge+Ge){if(ht.ch>2&&/\bstring/.test(Le.getTokenTypeAt(ve(ht.line,ht.ch-2))))return z.Pass;$e="addFour"}else if(st){var lt=ht.ch==0?" ":Le.getRange(ve(ht.line,ht.ch-1),ht);if(!z.isWordChar(at)&<!=Ge&&!z.isWordChar(lt))$e="both";else return z.Pass}else if(je&&(at.length===0||/\s/.test(at)||Bt.indexOf(at)>-1))$e="both";else return z.Pass;if(!Ot)Ot=$e;else if(Ot!=$e)return z.Pass}var me=It%2?dt.charAt(It-1):Ge,At=It%2?Ge:dt.charAt(It+1);Le.operation(function(){if(Ot=="skip")Le.execCommand("goCharRight");else if(Ot=="skipThree")for(var De=0;De<3;De++)Le.execCommand("goCharRight");else if(Ot=="surround"){for(var He=Le.getSelections(),De=0;De<He.length;De++)He[De]=me+He[De]+At;Le.replaceSelections(He,"around"),He=Le.listSelections().slice();for(var De=0;De<He.length;De++)He[De]=We(He[De]);Le.setSelections(He)}else Ot=="both"?(Le.replaceSelection(me+At,null),Le.triggerElectric(me+At),Le.execCommand("goCharLeft")):Ot=="addFour"&&(Le.replaceSelection(me+me+me+me,"before"),Le.execCommand("goCharRight"))})}function yt(Le,Ge){var Ne=Le.getRange(ve(Ge.line,Ge.ch-1),ve(Ge.line,Ge.ch+1));return Ne.length==2?Ne:null}function Xe(Le,Ge){var Ne=Le.getTokenAt(ve(Ge.line,Ge.ch+1));return/\bstring/.test(Ne.type)&&Ne.start==Ge.ch&&(Ge.ch==0||!/\bstring/.test(Le.getTokenTypeAt(Ge)))}})},6313:function(ln,Ft,ie){(function(z){z(ie(89780),ie(32855))})(function(z){z.defineOption("autoCloseTags",!1,function(Oe,fe,We){if(We!=z.Init&&We&&Oe.removeKeyMap("autoCloseTags"),!!fe){var Se={name:"autoCloseTags"};(typeof fe!="object"||fe.whenClosing!==!1)&&(Se["'/'"]=function(yt){return be(yt)}),(typeof fe!="object"||fe.whenOpening!==!1)&&(Se["'>'"]=function(yt){return Ae(yt)}),Oe.addKeyMap(Se)}});var Ke=["area","base","br","col","command","embed","hr","img","input","keygen","link","meta","param","source","track","wbr"],ve=["applet","blockquote","body","button","div","dl","fieldset","form","frameset","h1","h2","h3","h4","h5","h6","head","html","iframe","layer","legend","object","ol","p","select","table","ul"];function Ae(Oe){if(Oe.getOption("disableInput"))return z.Pass;for(var fe=Oe.listSelections(),We=[],Se=Oe.getOption("autoCloseTags"),yt=0;yt<fe.length;yt++){if(!fe[yt].empty())return z.Pass;var Xe=fe[yt].head,Le=Oe.getTokenAt(Xe),Ge=z.innerMode(Oe.getMode(),Le.state),Ne=Ge.state,dt=Ge.mode.xmlCurrentTag&&Ge.mode.xmlCurrentTag(Ne),It=dt&&dt.name;if(!It)return z.Pass;var Bt=Ge.mode.configuration=="html",mt=typeof Se=="object"&&Se.dontCloseTags||Bt&&Ke,st=typeof Se=="object"&&Se.indentTags||Bt&&ve;Le.end>Xe.ch&&(It=It.slice(0,It.length-Le.end+Xe.ch));var it=It.toLowerCase();if(!It||Le.type=="string"&&(Le.end!=Xe.ch||!/[\"\']/.test(Le.string.charAt(Le.string.length-1))||Le.string.length==1)||Le.type=="tag"&&dt.close||Le.string.indexOf("/")==Xe.ch-Le.start-1||mt&&Me(mt,it)>-1||Re(Oe,Ge.mode.xmlCurrentContext&&Ge.mode.xmlCurrentContext(Ne)||[],It,Xe,!0))return z.Pass;var je=typeof Se=="object"&&Se.emptyTags;if(je&&Me(je,It)>-1){We[yt]={text:"/>",newPos:z.Pos(Xe.line,Xe.ch+2)};continue}var Ot=st&&Me(st,it)>-1;We[yt]={indent:Ot,text:">"+(Ot?`
|
|
|
|
|
|
`:"")+"</"+It+">",newPos:Ot?z.Pos(Xe.line+1,0):z.Pos(Xe.line,Xe.ch+1)}}for(var nt=typeof Se=="object"&&Se.dontIndentOnAutoClose,yt=fe.length-1;yt>=0;yt--){var tt=We[yt];Oe.replaceRange(tt.text,fe[yt].head,fe[yt].anchor,"+insert");var ht=Oe.listSelections().slice(0);ht[yt]={head:tt.newPos,anchor:tt.newPos},Oe.setSelections(ht),!nt&&tt.indent&&(Oe.indentLine(tt.newPos.line,null,!0),Oe.indentLine(tt.newPos.line+1,null,!0))}}function ye(Oe,fe){for(var We=Oe.listSelections(),Se=[],yt=fe?"/":"</",Xe=Oe.getOption("autoCloseTags"),Le=typeof Xe=="object"&&Xe.dontIndentOnSlash,Ge=0;Ge<We.length;Ge++){if(!We[Ge].empty())return z.Pass;var Ne=We[Ge].head,dt=Oe.getTokenAt(Ne),It=z.innerMode(Oe.getMode(),dt.state),Bt=It.state;if(fe&&(dt.type=="string"||dt.string.charAt(0)!="<"||dt.start!=Ne.ch-1))return z.Pass;var mt,st=It.mode.name!="xml"&&Oe.getMode().name=="htmlmixed";if(st&&It.mode.name=="javascript")mt=yt+"script";else if(st&&It.mode.name=="css")mt=yt+"style";else{var it=It.mode.xmlCurrentContext&&It.mode.xmlCurrentContext(Bt);if(!it||it.length&&Re(Oe,it,it[it.length-1],Ne))return z.Pass;mt=yt+it[it.length-1]}Oe.getLine(Ne.line).charAt(dt.end)!=">"&&(mt+=">"),Se[Ge]=mt}if(Oe.replaceSelections(Se),We=Oe.listSelections(),!Le)for(var Ge=0;Ge<We.length;Ge++)(Ge==We.length-1||We[Ge].head.line<We[Ge+1].head.line)&&Oe.indentLine(We[Ge].head.line)}function be(Oe){return Oe.getOption("disableInput")?z.Pass:ye(Oe,!0)}z.commands.closeTag=function(Oe){return ye(Oe)};function Me(Oe,fe){if(Oe.indexOf)return Oe.indexOf(fe);for(var We=0,Se=Oe.length;We<Se;++We)if(Oe[We]==fe)return We;return-1}function Re(Oe,fe,We,Se,yt){if(!z.scanForClosingTag)return!1;var Xe=Math.min(Oe.lastLine()+1,Se.line+500),Le=z.scanForClosingTag(Oe,Se,null,Xe);if(!Le||Le.tag!=We)return!1;for(var Ge=yt?1:0,Ne=fe.length-1;Ne>=0&&fe[Ne]==We;Ne--)++Ge;Se=Le.to;for(var Ne=1;Ne<Ge;Ne++){var dt=z.scanForClosingTag(Oe,Se,null,Xe);if(!dt||dt.tag!=We)return!1;Se=dt.to}return!0}})},32855:function(ln,Ft,ie){(function(z){z(ie(89780))})(function(z){"use strict";var Ke=z.Pos;function ve(Ne,dt){return Ne.line-dt.line||Ne.ch-dt.ch}var Ae="A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD",ye=Ae+"-:.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040",be=new RegExp("<(/?)(["+Ae+"]["+ye+"]*)","g");function Me(Ne,dt,It,Bt){this.line=dt,this.ch=It,this.cm=Ne,this.text=Ne.getLine(dt),this.min=Bt?Math.max(Bt.from,Ne.firstLine()):Ne.firstLine(),this.max=Bt?Math.min(Bt.to-1,Ne.lastLine()):Ne.lastLine()}function Re(Ne,dt){var It=Ne.cm.getTokenTypeAt(Ke(Ne.line,dt));return It&&/\btag\b/.test(It)}function Oe(Ne){if(!(Ne.line>=Ne.max))return Ne.ch=0,Ne.text=Ne.cm.getLine(++Ne.line),!0}function fe(Ne){if(!(Ne.line<=Ne.min))return Ne.text=Ne.cm.getLine(--Ne.line),Ne.ch=Ne.text.length,!0}function We(Ne){for(;;){var dt=Ne.text.indexOf(">",Ne.ch);if(dt==-1){if(Oe(Ne))continue;return}if(!Re(Ne,dt+1)){Ne.ch=dt+1;continue}var It=Ne.text.lastIndexOf("/",dt),Bt=It>-1&&!/\S/.test(Ne.text.slice(It+1,dt));return Ne.ch=dt+1,Bt?"selfClose":"regular"}}function Se(Ne){for(;;){var dt=Ne.ch?Ne.text.lastIndexOf("<",Ne.ch-1):-1;if(dt==-1){if(fe(Ne))continue;return}if(!Re(Ne,dt+1)){Ne.ch=dt;continue}be.lastIndex=dt,Ne.ch=dt;var It=be.exec(Ne.text);if(It&&It.index==dt)return It}}function yt(Ne){for(;;){be.lastIndex=Ne.ch;var dt=be.exec(Ne.text);if(!dt){if(Oe(Ne))continue;return}if(!Re(Ne,dt.index+1)){Ne.ch=dt.index+1;continue}return Ne.ch=dt.index+dt[0].length,dt}}function Xe(Ne){for(;;){var dt=Ne.ch?Ne.text.lastIndexOf(">",Ne.ch-1):-1;if(dt==-1){if(fe(Ne))continue;return}if(!Re(Ne,dt+1)){Ne.ch=dt;continue}var It=Ne.text.lastIndexOf("/",dt),Bt=It>-1&&!/\S/.test(Ne.text.slice(It+1,dt));return Ne.ch=dt+1,Bt?"selfClose":"regular"}}function Le(Ne,dt){for(var It=[];;){var Bt=yt(Ne),mt,st=Ne.line,it=Ne.ch-(Bt?Bt[0].length:0);if(!Bt||!(mt=We(Ne)))return;if(mt!="selfClose")if(Bt[1]){for(var je=It.length-1;je>=0;--je)if(It[je]==Bt[2]){It.length=je;break}if(je<0&&(!dt||dt==Bt[2]))return{tag:Bt[2],from:Ke(st,it),to:Ke(Ne.line,Ne.ch)}}else It.push(Bt[2])}}function Ge(Ne,dt){for(var It=[];;){var Bt=Xe(Ne);if(!Bt)return;if(Bt=="selfClose"){Se(Ne);continue}var mt=Ne.line,st=Ne.ch,it=Se(Ne);if(!it)return;if(it[1])It.push(it[2]);else{for(var je=It.length-1;je>=0;--je)if(It[je]==it[2]){It.length=je;break}if(je<0&&(!dt||dt==it[2]))return{tag:it[2],from:Ke(Ne.line,Ne.ch),to:Ke(mt,st)}}}}z.registerHelper("fold","xml",function(Ne,dt){for(var It=new Me(Ne,dt.line,0);;){var Bt=yt(It);if(!Bt||It.line!=dt.line)return;var mt=We(It);if(!mt)return;if(!Bt[1]&&mt!="selfClose"){var st=Ke(It.line,It.ch),it=Le(It,Bt[2]);return it&&ve(it.from,st)>0?{from:st,to:it.from}:null}}}),z.findMatchingTag=function(Ne,dt,It){var Bt=new Me(Ne,dt.line,dt.ch,It);if(!(Bt.text.indexOf(">")==-1&&Bt.text.indexOf("<")==-1)){var mt=We(Bt),st=mt&&Ke(Bt.line,Bt.ch),it=mt&&Se(Bt);if(!(!mt||!it||ve(Bt,dt)>0)){var je={from:Ke(Bt.line,Bt.ch),to:st,tag:it[2]};return mt=="selfClose"?{open:je,close:null,at:"open"}:it[1]?{open:Ge(Bt,it[2]),close:je,at:"close"}:(Bt=new Me(Ne,st.line,st.ch,It),{open:je,close:Le(Bt,it[2]),at:"open"})}}},z.findEnclosingTag=function(Ne,dt,It,Bt){for(var mt=new Me(Ne,dt.line,dt.ch,It);;){var st=Ge(mt,Bt);if(!st)break;var it=new Me(Ne,dt.line,dt.ch,It),je=Le(it,st.tag);if(je)return{open:st,close:je}}},z.scanForClosingTag=function(Ne,dt,It,Bt){var mt=new Me(Ne,dt.line,dt.ch,Bt?{from:0,to:Bt}:null);return Le(mt,It)}})},89780:function(ln){(function(Ft,ie){ln.exports=ie()})(this,function(){"use strict";var Ft=navigator.userAgent,ie=navigator.platform,z=/gecko\/\d/i.test(Ft),Ke=/MSIE \d/.test(Ft),ve=/Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(Ft),Ae=/Edge\/(\d+)/.exec(Ft),ye=Ke||ve||Ae,be=ye&&(Ke?document.documentMode||6:+(Ae||ve)[1]),Me=!Ae&&/WebKit\//.test(Ft),Re=Me&&/Qt\/\d+\.\d+/.test(Ft),Oe=!Ae&&/Chrome\//.test(Ft),fe=/Opera\//.test(Ft),We=/Apple Computer/.test(navigator.vendor),Se=/Mac OS X 1\d\D([8-9]|\d\d)\D/.test(Ft),yt=/PhantomJS/.test(Ft),Xe=!Ae&&/AppleWebKit/.test(Ft)&&/Mobile\/\w+/.test(Ft),Le=/Android/.test(Ft),Ge=Xe||Le||/webOS|BlackBerry|Opera Mini|Opera Mobi|IEMobile/i.test(Ft),Ne=Xe||/Mac/.test(ie),dt=/\bCrOS\b/.test(Ft),It=/win/i.test(ie),Bt=fe&&Ft.match(/Version\/(\d*\.\d*)/);Bt&&(Bt=Number(Bt[1])),Bt&&Bt>=15&&(fe=!1,Me=!0);var mt=Ne&&(Re||fe&&(Bt==null||Bt<12.11)),st=z||ye&&be>=9;function it(a){return new RegExp("(^|\\s)"+a+"(?:$|\\s)\\s*")}var je=function(a,y){var x=a.className,b=it(y).exec(x);if(b){var E=x.slice(b.index+b[0].length);a.className=x.slice(0,b.index)+(E?b[1]+E:"")}};function Ot(a){for(var y=a.childNodes.length;y>0;--y)a.removeChild(a.firstChild);return a}function nt(a,y){return Ot(a).appendChild(y)}function tt(a,y,x,b){var E=document.createElement(a);if(x&&(E.className=x),b&&(E.style.cssText=b),typeof y=="string")E.appendChild(document.createTextNode(y));else if(y)for(var re=0;re<y.length;++re)E.appendChild(y[re]);return E}function ht(a,y,x,b){var E=tt(a,y,x,b);return E.setAttribute("role","presentation"),E}var $e;document.createRange?$e=function(a,y,x,b){var E=document.createRange();return E.setEnd(b||a,x),E.setStart(a,y),E}:$e=function(a,y,x){var b=document.body.createTextRange();try{b.moveToElementText(a.parentNode)}catch(E){return b}return b.collapse(!0),b.moveEnd("character",x),b.moveStart("character",y),b};function at(a,y){if(y.nodeType==3&&(y=y.parentNode),a.contains)return a.contains(y);do if(y.nodeType==11&&(y=y.host),y==a)return!0;while(y=y.parentNode)}function lt(){var a;try{a=document.activeElement}catch(y){a=document.body||null}for(;a&&a.shadowRoot&&a.shadowRoot.activeElement;)a=a.shadowRoot.activeElement;return a}function me(a,y){var x=a.className;it(y).test(x)||(a.className+=(x?" ":"")+y)}function At(a,y){for(var x=a.split(" "),b=0;b<x.length;b++)x[b]&&!it(x[b]).test(y)&&(y+=" "+x[b]);return y}var De=function(a){a.select()};Xe?De=function(a){a.selectionStart=0,a.selectionEnd=a.value.length}:ye&&(De=function(a){try{a.select()}catch(y){}});function He(a){var y=Array.prototype.slice.call(arguments,1);return function(){return a.apply(null,y)}}function Pt(a,y,x){y||(y={});for(var b in a)a.hasOwnProperty(b)&&(x!==!1||!y.hasOwnProperty(b))&&(y[b]=a[b]);return y}function ge(a,y,x,b,E){y==null&&(y=a.search(/[^\s\u00a0]/),y==-1&&(y=a.length));for(var re=b||0,le=E||0;;){var ue=a.indexOf(" ",re);if(ue<0||ue>=y)return le+(y-re);le+=ue-re,le+=x-le%x,re=ue+1}}var ce=function(){this.id=null,this.f=null,this.time=0,this.handler=He(this.onTimeout,this)};ce.prototype.onTimeout=function(a){a.id=0,a.time<=+new Date?a.f():setTimeout(a.handler,a.time-+new Date)},ce.prototype.set=function(a,y){this.f=y;var x=+new Date+a;(!this.id||x<this.time)&&(clearTimeout(this.id),this.id=setTimeout(this.handler,a),this.time=x)};function Je(a,y){for(var x=0;x<a.length;++x)if(a[x]==y)return x;return-1}var jt=50,wt={toString:function(){return"CodeMirror.Pass"}},Ie={scroll:!1},Ue={origin:"*mouse"},et={origin:"+move"};function cn(a,y,x){for(var b=0,E=0;;){var re=a.indexOf(" ",b);re==-1&&(re=a.length);var le=re-b;if(re==a.length||E+le>=y)return b+Math.min(le,y-E);if(E+=re-b,E+=x-E%x,b=re+1,E>=y)return b}}var kt=[""];function Yt(a){for(;kt.length<=a;)kt.push(ze(kt)+" ");return kt[a]}function ze(a){return a[a.length-1]}function zt(a,y){for(var x=[],b=0;b<a.length;b++)x[b]=y(a[b],b);return x}function ut(a,y,x){for(var b=0,E=x(y);b<a.length&&x(a[b])<=E;)b++;a.splice(b,0,y)}function ae(){}function te(a,y){var x;return Object.create?x=Object.create(a):(ae.prototype=a,x=new ae),y&&Pt(y,x),x}var ee=/[\u00df\u0587\u0590-\u05f4\u0600-\u06ff\u3040-\u309f\u30a0-\u30ff\u3400-\u4db5\u4e00-\u9fcc\uac00-\ud7af]/;function oe(a){return/\w/.test(a)||a>"\x80"&&(a.toUpperCase()!=a.toLowerCase()||ee.test(a))}function se(a,y){return y?y.source.indexOf("\\w")>-1&&oe(a)?!0:y.test(a):oe(a)}function ne(a){for(var y in a)if(a.hasOwnProperty(y)&&a[y])return!1;return!0}var he=/[\u0300-\u036f\u0483-\u0489\u0591-\u05bd\u05bf\u05c1\u05c2\u05c4\u05c5\u05c7\u0610-\u061a\u064b-\u065e\u0670\u06d6-\u06dc\u06de-\u06e4\u06e7\u06e8\u06ea-\u06ed\u0711\u0730-\u074a\u07a6-\u07b0\u07eb-\u07f3\u0816-\u0819\u081b-\u0823\u0825-\u0827\u0829-\u082d\u0900-\u0902\u093c\u0941-\u0948\u094d\u0951-\u0955\u0962\u0963\u0981\u09bc\u09be\u09c1-\u09c4\u09cd\u09d7\u09e2\u09e3\u0a01\u0a02\u0a3c\u0a41\u0a42\u0a47\u0a48\u0a4b-\u0a4d\u0a51\u0a70\u0a71\u0a75\u0a81\u0a82\u0abc\u0ac1-\u0ac5\u0ac7\u0ac8\u0acd\u0ae2\u0ae3\u0b01\u0b3c\u0b3e\u0b3f\u0b41-\u0b44\u0b4d\u0b56\u0b57\u0b62\u0b63\u0b82\u0bbe\u0bc0\u0bcd\u0bd7\u0c3e-\u0c40\u0c46-\u0c48\u0c4a-\u0c4d\u0c55\u0c56\u0c62\u0c63\u0cbc\u0cbf\u0cc2\u0cc6\u0ccc\u0ccd\u0cd5\u0cd6\u0ce2\u0ce3\u0d3e\u0d41-\u0d44\u0d4d\u0d57\u0d62\u0d63\u0dca\u0dcf\u0dd2-\u0dd4\u0dd6\u0ddf\u0e31\u0e34-\u0e3a\u0e47-\u0e4e\u0eb1\u0eb4-\u0eb9\u0ebb\u0ebc\u0ec8-\u0ecd\u0f18\u0f19\u0f35\u0f37\u0f39\u0f71-\u0f7e\u0f80-\u0f84\u0f86\u0f87\u0f90-\u0f97\u0f99-\u0fbc\u0fc6\u102d-\u1030\u1032-\u1037\u1039\u103a\u103d\u103e\u1058\u1059\u105e-\u1060\u1071-\u1074\u1082\u1085\u1086\u108d\u109d\u135f\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17b7-\u17bd\u17c6\u17c9-\u17d3\u17dd\u180b-\u180d\u18a9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193b\u1a17\u1a18\u1a56\u1a58-\u1a5e\u1a60\u1a62\u1a65-\u1a6c\u1a73-\u1a7c\u1a7f\u1b00-\u1b03\u1b34\u1b36-\u1b3a\u1b3c\u1b42\u1b6b-\u1b73\u1b80\u1b81\u1ba2-\u1ba5\u1ba8\u1ba9\u1c2c-\u1c33\u1c36\u1c37\u1cd0-\u1cd2\u1cd4-\u1ce0\u1ce2-\u1ce8\u1ced\u1dc0-\u1de6\u1dfd-\u1dff\u200c\u200d\u20d0-\u20f0\u2cef-\u2cf1\u2de0-\u2dff\u302a-\u302f\u3099\u309a\ua66f-\ua672\ua67c\ua67d\ua6f0\ua6f1\ua802\ua806\ua80b\ua825\ua826\ua8c4\ua8e0-\ua8f1\ua926-\ua92d\ua947-\ua951\ua980-\ua982\ua9b3\ua9b6-\ua9b9\ua9bc\uaa29-\uaa2e\uaa31\uaa32\uaa35\uaa36\uaa43\uaa4c\uaab0\uaab2-\uaab4\uaab7\uaab8\uaabe\uaabf\uaac1\uabe5\uabe8\uabed\udc00-\udfff\ufb1e\ufe00-\ufe0f\ufe20-\ufe26\uff9e\uff9f]/;function xe(a){return a.charCodeAt(0)>=768&&he.test(a)}function ot(a,y,x){for(;(x<0?y>0:y<a.length)&&xe(a.charAt(y));)y+=x;return y}function Ee(a,y,x){for(var b=y>x?-1:1;;){if(y==x)return y;var E=(y+x)/2,re=b<0?Math.ceil(E):Math.floor(E);if(re==y)return a(re)?y:x;a(re)?x=re:y=re+b}}function Fe(a,y,x,b){if(!a)return b(y,x,"ltr",0);for(var E=!1,re=0;re<a.length;++re){var le=a[re];(le.from<x&&le.to>y||y==x&&le.to==y)&&(b(Math.max(le.from,y),Math.min(le.to,x),le.level==1?"rtl":"ltr",re),E=!0)}E||b(y,x,"ltr")}var qe=null;function bt(a,y,x){var b;qe=null;for(var E=0;E<a.length;++E){var re=a[E];if(re.from<y&&re.to>y)return E;re.to==y&&(re.from!=re.to&&x=="before"?b=E:qe=E),re.from==y&&(re.from!=re.to&&x!="before"?b=E:qe=E)}return b!=null?b:qe}var ct=function(){var a="bbbbbbbbbtstwsbbbbbbbbbbbbbbssstwNN%%%NNNNNN,N,N1111111111NNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNbbbbbbsbbbbbbbbbbbbbbbbbbbbbbbbbb,N%%%%NNNNLNNNNN%%11NLNNN1LNNNNNLLLLLLLLLLLLLLLLLLLLLLLNLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLN",y="nnnnnnNNr%%r,rNNmmmmmmmmmmmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmmmmmmmmmmmmmmmnnnnnnnnnn%nnrrrmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmnNmmmmmmrrmmNmmmmrr1111111111";function x(pe){return pe<=247?a.charAt(pe):1424<=pe&&pe<=1524?"R":1536<=pe&&pe<=1785?y.charAt(pe-1536):1774<=pe&&pe<=2220?"r":8192<=pe&&pe<=8203?"w":pe==8204?"b":"L"}var b=/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac]/,E=/[stwN]/,re=/[LRr]/,le=/[Lb1n]/,ue=/[1n]/;function de(pe,Ze,Ye){this.level=pe,this.from=Ze,this.to=Ye}return function(pe,Ze){var Ye=Ze=="ltr"?"L":"R";if(pe.length==0||Ze=="ltr"&&!b.test(pe))return!1;for(var Lt=pe.length,Mt=[],vn=0;vn<Lt;++vn)Mt.push(x(pe.charCodeAt(vn)));for(var Mn=0,Vn=Ye;Mn<Lt;++Mn){var tr=Mt[Mn];tr=="m"?Mt[Mn]=Vn:Vn=tr}for(var ur=0,nr=Ye;ur<Lt;++ur){var gr=Mt[ur];gr=="1"&&nr=="r"?Mt[ur]="n":re.test(gr)&&(nr=gr,gr=="r"&&(Mt[ur]="R"))}for(var Ir=1,Er=Mt[0];Ir<Lt-1;++Ir){var zr=Mt[Ir];zr=="+"&&Er=="1"&&Mt[Ir+1]=="1"?Mt[Ir]="1":zr==","&&Er==Mt[Ir+1]&&(Er=="1"||Er=="n")&&(Mt[Ir]=Er),Er=zr}for(var Yr=0;Yr<Lt;++Yr){var bi=Mt[Yr];if(bi==",")Mt[Yr]="N";else if(bi=="%"){var ti=void 0;for(ti=Yr+1;ti<Lt&&Mt[ti]=="%";++ti);for(var Wi=Yr&&Mt[Yr-1]=="!"||ti<Lt&&Mt[ti]=="1"?"1":"N",Ri=Yr;Ri<ti;++Ri)Mt[Ri]=Wi;Yr=ti-1}}for(var ci=0,Fi=Ye;ci<Lt;++ci){var Ei=Mt[ci];Fi=="L"&&Ei=="1"?Mt[ci]="L":re.test(Ei)&&(Fi=Ei)}for(var vi=0;vi<Lt;++vi)if(E.test(Mt[vi])){var di=void 0;for(di=vi+1;di<Lt&&E.test(Mt[di]);++di);for(var ni=(vi?Mt[vi-1]:Ye)=="L",zi=(di<Lt?Mt[di]:Ye)=="L",Vo=ni==zi?ni?"L":"R":Ye,xo=vi;xo<di;++xo)Mt[xo]=Vo;vi=di-1}for(var Di=[],oo,xi=0;xi<Lt;)if(le.test(Mt[xi])){var bl=xi;for(++xi;xi<Lt&&le.test(Mt[xi]);++xi);Di.push(new de(0,bl,xi))}else{var uo=xi,Po=Di.length,Do=Ze=="rtl"?1:0;for(++xi;xi<Lt&&Mt[xi]!="L";++xi);for(var Li=uo;Li<xi;)if(ue.test(Mt[Li])){uo<Li&&(Di.splice(Po,0,new de(1,uo,Li)),Po+=Do);var Uo=Li;for(++Li;Li<xi&&ue.test(Mt[Li]);++Li);Di.splice(Po,0,new de(2,Uo,Li)),Po+=Do,uo=Li}else++Li;uo<xi&&Di.splice(Po,0,new de(1,uo,xi))}return Ze=="ltr"&&(Di[0].level==1&&(oo=pe.match(/^\s+/))&&(Di[0].from=oo[0].length,Di.unshift(new de(0,0,oo[0].length))),ze(Di).level==1&&(oo=pe.match(/\s+$/))&&(ze(Di).to-=oo[0].length,Di.push(new de(0,Lt-oo[0].length,Lt)))),Ze=="rtl"?Di.reverse():Di}}();function Kt(a,y){var x=a.order;return x==null&&(x=a.order=ct(a.text,y)),x}var Wt=[],Nt=function(a,y,x){if(a.addEventListener)a.addEventListener(y,x,!1);else if(a.attachEvent)a.attachEvent("on"+y,x);else{var b=a._handlers||(a._handlers={});b[y]=(b[y]||Wt).concat(x)}};function rn(a,y){return a._handlers&&a._handlers[y]||Wt}function qt(a,y,x){if(a.removeEventListener)a.removeEventListener(y,x,!1);else if(a.detachEvent)a.detachEvent("on"+y,x);else{var b=a._handlers,E=b&&b[y];if(E){var re=Je(E,x);re>-1&&(b[y]=E.slice(0,re).concat(E.slice(re+1)))}}}function on(a,y){var x=rn(a,y);if(x.length)for(var b=Array.prototype.slice.call(arguments,2),E=0;E<x.length;++E)x[E].apply(null,b)}function ft(a,y,x){return typeof y=="string"&&(y={type:y,preventDefault:function(){this.defaultPrevented=!0}}),on(a,x||y.type,a,y),On(y)||y.codemirrorIgnore}function Gt(a){var y=a._handlers&&a._handlers.cursorActivity;if(y)for(var x=a.curOp.cursorActivityHandlers||(a.curOp.cursorActivityHandlers=[]),b=0;b<y.length;++b)Je(x,y[b])==-1&&x.push(y[b])}function Tt(a,y){return rn(a,y).length>0}function en(a){a.prototype.on=function(y,x){Nt(this,y,x)},a.prototype.off=function(y,x){qt(this,y,x)}}function yn(a){a.preventDefault?a.preventDefault():a.returnValue=!1}function Rn(a){a.stopPropagation?a.stopPropagation():a.cancelBubble=!0}function On(a){return a.defaultPrevented!=null?a.defaultPrevented:a.returnValue==!1}function Pe(a){yn(a),Rn(a)}function rt(a){return a.target||a.srcElement}function St(a){var y=a.which;return y==null&&(a.button&1?y=1:a.button&2?y=3:a.button&4&&(y=2)),Ne&&a.ctrlKey&&y==1&&(y=3),y}var _t=function(){if(ye&&be<9)return!1;var a=tt("div");return"draggable"in a||"dragDrop"in a}(),bn;function In(a){if(bn==null){var y=tt("span","\u200B");nt(a,tt("span",[y,document.createTextNode("x")])),a.firstChild.offsetHeight!=0&&(bn=y.offsetWidth<=1&&y.offsetHeight>2&&!(ye&&be<8))}var x=bn?tt("span","\u200B"):tt("span","\xA0",null,"display: inline-block; width: 1px; margin-right: -1px");return x.setAttribute("cm-text",""),x}var rr;function Xn(a){if(rr!=null)return rr;var y=nt(a,document.createTextNode("A\u062EA")),x=$e(y,0,1).getBoundingClientRect(),b=$e(y,1,2).getBoundingClientRect();return Ot(a),!x||x.left==x.right?!1:rr=b.right-x.right<3}var Cn=`
|
|
|
|
|
|
b`.split(/\n/).length!=3?function(a){for(var y=0,x=[],b=a.length;y<=b;){var E=a.indexOf(`
|
|
|
`,y);E==-1&&(E=a.length);var re=a.slice(y,a.charAt(E-1)=="\r"?E-1:E),le=re.indexOf("\r");le!=-1?(x.push(re.slice(0,le)),y+=le+1):(x.push(re),y=E+1)}return x}:function(a){return a.split(/\r\n?|\n/)},Fn=window.getSelection?function(a){try{return a.selectionStart!=a.selectionEnd}catch(y){return!1}}:function(a){var y;try{y=a.ownerDocument.selection.createRange()}catch(x){}return!y||y.parentElement()!=a?!1:y.compareEndPoints("StartToEnd",y)!=0},xt=function(){var a=tt("div");return"oncopy"in a?!0:(a.setAttribute("oncopy","return;"),typeof a.oncopy=="function")}(),$t=null;function vt(a){if($t!=null)return $t;var y=nt(a,tt("span","x")),x=y.getBoundingClientRect(),b=$e(y,0,1).getBoundingClientRect();return $t=Math.abs(x.left-b.left)>1}var Vt={},Ut={};function En(a,y){arguments.length>2&&(y.dependencies=Array.prototype.slice.call(arguments,2)),Vt[a]=y}function mn(a,y){Ut[a]=y}function xn(a){if(typeof a=="string"&&Ut.hasOwnProperty(a))a=Ut[a];else if(a&&typeof a.name=="string"&&Ut.hasOwnProperty(a.name)){var y=Ut[a.name];typeof y=="string"&&(y={name:y}),a=te(y,a),a.name=y.name}else{if(typeof a=="string"&&/^[\w\-]+\/[\w\-]+\+xml$/.test(a))return xn("application/xml");if(typeof a=="string"&&/^[\w\-]+\/[\w\-]+\+json$/.test(a))return xn("application/json")}return typeof a=="string"?{name:a}:a||{name:"null"}}function wn(a,y){y=xn(y);var x=Vt[y.name];if(!x)return wn(a,"text/plain");var b=x(a,y);if(Bn.hasOwnProperty(y.name)){var E=Bn[y.name];for(var re in E)E.hasOwnProperty(re)&&(b.hasOwnProperty(re)&&(b["_"+re]=b[re]),b[re]=E[re])}if(b.name=y.name,y.helperType&&(b.helperType=y.helperType),y.modeProps)for(var le in y.modeProps)b[le]=y.modeProps[le];return b}var Bn={};function Zn(a,y){var x=Bn.hasOwnProperty(a)?Bn[a]:Bn[a]={};Pt(y,x)}function Yn(a,y){if(y===!0)return y;if(a.copyState)return a.copyState(y);var x={};for(var b in y){var E=y[b];E instanceof Array&&(E=E.concat([])),x[b]=E}return x}function Wn(a,y){for(var x;a.innerMode&&(x=a.innerMode(y),!(!x||x.mode==a));)y=x.state,a=x.mode;return x||{mode:a,state:y}}function ir(a,y,x){return a.startState?a.startState(y,x):!0}var gn=function(a,y,x){this.pos=this.start=0,this.string=a,this.tabSize=y||8,this.lastColumnPos=this.lastColumnValue=0,this.lineStart=0,this.lineOracle=x};gn.prototype.eol=function(){return this.pos>=this.string.length},gn.prototype.sol=function(){return this.pos==this.lineStart},gn.prototype.peek=function(){return this.string.charAt(this.pos)||void 0},gn.prototype.next=function(){if(this.pos<this.string.length)return this.string.charAt(this.pos++)},gn.prototype.eat=function(a){var y=this.string.charAt(this.pos),x;if(typeof a=="string"?x=y==a:x=y&&(a.test?a.test(y):a(y)),x)return++this.pos,y},gn.prototype.eatWhile=function(a){for(var y=this.pos;this.eat(a););return this.pos>y},gn.prototype.eatSpace=function(){for(var a=this.pos;/[\s\u00a0]/.test(this.string.charAt(this.pos));)++this.pos;return this.pos>a},gn.prototype.skipToEnd=function(){this.pos=this.string.length},gn.prototype.skipTo=function(a){var y=this.string.indexOf(a,this.pos);if(y>-1)return this.pos=y,!0},gn.prototype.backUp=function(a){this.pos-=a},gn.prototype.column=function(){return this.lastColumnPos<this.start&&(this.lastColumnValue=ge(this.string,this.start,this.tabSize,this.lastColumnPos,this.lastColumnValue),this.lastColumnPos=this.start),this.lastColumnValue-(this.lineStart?ge(this.string,this.lineStart,this.tabSize):0)},gn.prototype.indentation=function(){return ge(this.string,null,this.tabSize)-(this.lineStart?ge(this.string,this.lineStart,this.tabSize):0)},gn.prototype.match=function(a,y,x){if(typeof a=="string"){var b=function(le){return x?le.toLowerCase():le},E=this.string.substr(this.pos,a.length);if(b(E)==b(a))return y!==!1&&(this.pos+=a.length),!0}else{var re=this.string.slice(this.pos).match(a);return re&&re.index>0?null:(re&&y!==!1&&(this.pos+=re[0].length),re)}},gn.prototype.current=function(){return this.string.slice(this.start,this.pos)},gn.prototype.hideFirstChars=function(a,y){this.lineStart+=a;try{return y()}finally{this.lineStart-=a}},gn.prototype.lookAhead=function(a){var y=this.lineOracle;return y&&y.lookAhead(a)},gn.prototype.baseToken=function(){var a=this.lineOracle;return a&&a.baseToken(this.pos)};function Dt(a,y){if(y-=a.first,y<0||y>=a.size)throw new Error("There is no line "+(y+a.first)+" in the document.");for(var x=a;!x.lines;)for(var b=0;;++b){var E=x.children[b],re=E.chunkSize();if(y<re){x=E;break}y-=re}return x.lines[y]}function Qt(a,y,x){var b=[],E=y.line;return a.iter(y.line,x.line+1,function(re){var le=re.text;E==x.line&&(le=le.slice(0,x.ch)),E==y.line&&(le=le.slice(y.ch)),b.push(le),++E}),b}function Un(a,y,x){var b=[];return a.iter(y,x,function(E){b.push(E.text)}),b}function fr(a,y){var x=y-a.height;if(x)for(var b=a;b;b=b.parent)b.height+=x}function ke(a){if(a.parent==null)return null;for(var y=a.parent,x=Je(y.lines,a),b=y.parent;b;y=b,b=b.parent)for(var E=0;b.children[E]!=y;++E)x+=b.children[E].chunkSize();return x+y.first}function _e(a,y){var x=a.first;e:do{for(var b=0;b<a.children.length;++b){var E=a.children[b],re=E.height;if(y<re){a=E;continue e}y-=re,x+=E.chunkSize()}return x}while(!a.lines);for(var le=0;le<a.lines.length;++le){var ue=a.lines[le],de=ue.height;if(y<de)break;y-=de}return x+le}function Ce(a,y){return y>=a.first&&y<a.first+a.size}function Be(a,y){return String(a.lineNumberFormatter(y+a.firstLineNumber))}function we(a,y,x){if(x===void 0&&(x=null),!(this instanceof we))return new we(a,y,x);this.line=a,this.ch=y,this.sticky=x}function Te(a,y){return a.line-y.line||a.ch-y.ch}function Qe(a,y){return a.sticky==y.sticky&&Te(a,y)==0}function nn(a){return we(a.line,a.ch)}function sn(a,y){return Te(a,y)<0?y:a}function Xt(a,y){return Te(a,y)<0?a:y}function Ht(a,y){return Math.max(a.first,Math.min(y,a.first+a.size-1))}function Ct(a,y){if(y.line<a.first)return we(a.first,0);var x=a.first+a.size-1;return y.line>x?we(x,Dt(a,x).text.length):pt(y,Dt(a,y.line).text.length)}function pt(a,y){var x=a.ch;return x==null||x>y?we(a.line,y):x<0?we(a.line,0):a}function un(a,y){for(var x=[],b=0;b<y.length;b++)x[b]=Ct(a,y[b]);return x}var $n=function(a,y){this.state=a,this.lookAhead=y},Dn=function(a,y,x,b){this.state=y,this.doc=a,this.line=x,this.maxLookAhead=b||0,this.baseTokens=null,this.baseTokenPos=1};Dn.prototype.lookAhead=function(a){var y=this.doc.getLine(this.line+a);return y!=null&&a>this.maxLookAhead&&(this.maxLookAhead=a),y},Dn.prototype.baseToken=function(a){if(!this.baseTokens)return null;for(;this.baseTokens[this.baseTokenPos]<=a;)this.baseTokenPos+=2;var y=this.baseTokens[this.baseTokenPos+1];return{type:y&&y.replace(/( |^)overlay .*/,""),size:this.baseTokens[this.baseTokenPos]-a}},Dn.prototype.nextLine=function(){this.line++,this.maxLookAhead>0&&this.maxLookAhead--},Dn.fromSaved=function(a,y,x){return y instanceof $n?new Dn(a,Yn(a.mode,y.state),x,y.lookAhead):new Dn(a,Yn(a.mode,y),x)},Dn.prototype.save=function(a){var y=a!==!1?Yn(this.doc.mode,this.state):this.state;return this.maxLookAhead>0?new $n(y,this.maxLookAhead):y};function kn(a,y,x,b){var E=[a.state.modeGen],re={};Sn(a,y.text,a.doc.mode,x,function(pe,Ze){return E.push(pe,Ze)},re,b);for(var le=x.state,ue=function(pe){x.baseTokens=E;var Ze=a.state.overlays[pe],Ye=1,Lt=0;x.state=!0,Sn(a,y.text,Ze.mode,x,function(Mt,vn){for(var Mn=Ye;Lt<Mt;){var Vn=E[Ye];Vn>Mt&&E.splice(Ye,1,Mt,E[Ye+1],Vn),Ye+=2,Lt=Math.min(Mt,Vn)}if(vn)if(Ze.opaque)E.splice(Mn,Ye-Mn,Mt,"overlay "+vn),Ye=Mn+2;else for(;Mn<Ye;Mn+=2){var tr=E[Mn+1];E[Mn+1]=(tr?tr+" ":"")+"overlay "+vn}},re),x.state=le,x.baseTokens=null,x.baseTokenPos=1},de=0;de<a.state.overlays.length;++de)ue(de);return{styles:E,classes:re.bgClass||re.textClass?re:null}}function pr(a,y,x){if(!y.styles||y.styles[0]!=a.state.modeGen){var b=gt(a,ke(y)),E=y.text.length>a.options.maxHighlightLength&&Yn(a.doc.mode,b.state),re=kn(a,y,b);E&&(b.state=E),y.stateAfter=b.save(!E),y.styles=re.styles,re.classes?y.styleClasses=re.classes:y.styleClasses&&(y.styleClasses=null),x===a.doc.highlightFrontier&&(a.doc.modeFrontier=Math.max(a.doc.modeFrontier,++a.doc.highlightFrontier))}return y.styles}function gt(a,y,x){var b=a.doc,E=a.display;if(!b.mode.startState)return new Dn(b,!0,y);var re=Tn(a,y,x),le=re>b.first&&Dt(b,re-1).stateAfter,ue=le?Dn.fromSaved(b,le,re):new Dn(b,ir(b.mode),re);return b.iter(re,y,function(de){Ve(a,de.text,ue);var pe=ue.line;de.stateAfter=pe==y-1||pe%5==0||pe>=E.viewFrom&&pe<E.viewTo?ue.save():null,ue.nextLine()}),x&&(b.modeFrontier=ue.line),ue}function Ve(a,y,x,b){var E=a.doc.mode,re=new gn(y,a.options.tabSize,x);for(re.start=re.pos=b||0,y==""&&Et(E,x.state);!re.eol();)Rt(E,re,x.state),re.start=re.pos}function Et(a,y){if(a.blankLine)return a.blankLine(y);if(a.innerMode){var x=Wn(a,y);if(x.mode.blankLine)return x.mode.blankLine(x.state)}}function Rt(a,y,x,b){for(var E=0;E<10;E++){b&&(b[0]=Wn(a,x).mode);var re=a.token(y,x);if(y.pos>y.start)return re}throw new Error("Mode "+a.name+" failed to advance stream.")}var Zt=function(a,y,x){this.start=a.start,this.end=a.pos,this.string=a.current(),this.type=y||null,this.state=x};function hn(a,y,x,b){var E=a.doc,re=E.mode,le;y=Ct(E,y);var ue=Dt(E,y.line),de=gt(a,y.line,x),pe=new gn(ue.text,a.options.tabSize,de),Ze;for(b&&(Ze=[]);(b||pe.pos<y.ch)&&!pe.eol();)pe.start=pe.pos,le=Rt(re,pe,de.state),b&&Ze.push(new Zt(pe,le,Yn(E.mode,de.state)));return b?Ze:new Zt(pe,le,de.state)}function Hn(a,y){if(a)for(;;){var x=a.match(/(?:^|\s+)line-(background-)?(\S+)/);if(!x)break;a=a.slice(0,x.index)+a.slice(x.index+x[0].length);var b=x[1]?"bgClass":"textClass";y[b]==null?y[b]=x[2]:new RegExp("(?:^|\\s)"+x[2]+"(?:$|\\s)").test(y[b])||(y[b]+=" "+x[2])}return a}function Sn(a,y,x,b,E,re,le){var ue=x.flattenSpans;ue==null&&(ue=a.options.flattenSpans);var de=0,pe=null,Ze=new gn(y,a.options.tabSize,b),Ye,Lt=a.options.addModeClass&&[null];for(y==""&&Hn(Et(x,b.state),re);!Ze.eol();){if(Ze.pos>a.options.maxHighlightLength?(ue=!1,le&&Ve(a,y,b,Ze.pos),Ze.pos=y.length,Ye=null):Ye=Hn(Rt(x,Ze,b.state,Lt),re),Lt){var Mt=Lt[0].name;Mt&&(Ye="m-"+(Ye?Mt+" "+Ye:Mt))}if(!ue||pe!=Ye){for(;de<Ze.start;)de=Math.min(Ze.start,de+5e3),E(de,pe);pe=Ye}Ze.start=Ze.pos}for(;de<Ze.pos;){var vn=Math.min(Ze.pos,de+5e3);E(vn,pe),de=vn}}function Tn(a,y,x){for(var b,E,re=a.doc,le=x?-1:y-(a.doc.mode.innerMode?1e3:100),ue=y;ue>le;--ue){if(ue<=re.first)return re.first;var de=Dt(re,ue-1),pe=de.stateAfter;if(pe&&(!x||ue+(pe instanceof $n?pe.lookAhead:0)<=re.modeFrontier))return ue;var Ze=ge(de.text,null,a.options.tabSize);(E==null||b>Ze)&&(E=ue-1,b=Ze)}return E}function An(a,y){if(a.modeFrontier=Math.min(a.modeFrontier,y),!(a.highlightFrontier<y-10)){for(var x=a.first,b=y-1;b>x;b--){var E=Dt(a,b).stateAfter;if(E&&(!(E instanceof $n)||b+E.lookAhead<y)){x=b+1;break}}a.highlightFrontier=Math.min(a.highlightFrontier,x)}}var jn=!1,Pn=!1;function lr(){jn=!0}function Jn(){Pn=!0}function Kn(a,y,x){this.marker=a,this.from=y,this.to=x}function sr(a,y){if(a)for(var x=0;x<a.length;++x){var b=a[x];if(b.marker==y)return b}}function mr(a,y){for(var x,b=0;b<a.length;++b)a[b]!=y&&(x||(x=[])).push(a[b]);return x}function Qn(a,y){a.markedSpans=a.markedSpans?a.markedSpans.concat([y]):[y],y.marker.attachLine(a)}function cr(a,y,x){var b;if(a)for(var E=0;E<a.length;++E){var re=a[E],le=re.marker,ue=re.from==null||(le.inclusiveLeft?re.from<=y:re.from<y);if(ue||re.from==y&&le.type=="bookmark"&&(!x||!re.marker.insertLeft)){var de=re.to==null||(le.inclusiveRight?re.to>=y:re.to>y);(b||(b=[])).push(new Kn(le,re.from,de?null:re.to))}}return b}function Gn(a,y,x){var b;if(a)for(var E=0;E<a.length;++E){var re=a[E],le=re.marker,ue=re.to==null||(le.inclusiveRight?re.to>=y:re.to>y);if(ue||re.from==y&&le.type=="bookmark"&&(!x||re.marker.insertLeft)){var de=re.from==null||(le.inclusiveLeft?re.from<=y:re.from<y);(b||(b=[])).push(new Kn(le,de?null:re.from-y,re.to==null?null:re.to-y))}}return b}function vr(a,y){if(y.full)return null;var x=Ce(a,y.from.line)&&Dt(a,y.from.line).markedSpans,b=Ce(a,y.to.line)&&Dt(a,y.to.line).markedSpans;if(!x&&!b)return null;var E=y.from.ch,re=y.to.ch,le=Te(y.from,y.to)==0,ue=cr(x,E,le),de=Gn(b,re,le),pe=y.text.length==1,Ze=ze(y.text).length+(pe?E:0);if(ue)for(var Ye=0;Ye<ue.length;++Ye){var Lt=ue[Ye];if(Lt.to==null){var Mt=sr(de,Lt.marker);Mt?pe&&(Lt.to=Mt.to==null?null:Mt.to+Ze):Lt.to=E}}if(de)for(var vn=0;vn<de.length;++vn){var Mn=de[vn];if(Mn.to!=null&&(Mn.to+=Ze),Mn.from==null){var Vn=sr(ue,Mn.marker);Vn||(Mn.from=Ze,pe&&(ue||(ue=[])).push(Mn))}else Mn.from+=Ze,pe&&(ue||(ue=[])).push(Mn)}ue&&(ue=qn(ue)),de&&de!=ue&&(de=qn(de));var tr=[ue];if(!pe){var ur=y.text.length-2,nr;if(ur>0&&ue)for(var gr=0;gr<ue.length;++gr)ue[gr].to==null&&(nr||(nr=[])).push(new Kn(ue[gr].marker,null,null));for(var Ir=0;Ir<ur;++Ir)tr.push(nr);tr.push(de)}return tr}function qn(a){for(var y=0;y<a.length;++y){var x=a[y];x.from!=null&&x.from==x.to&&x.marker.clearWhenEmpty!==!1&&a.splice(y--,1)}return a.length?a:null}function Sr(a,y,x){var b=null;if(a.iter(y.line,x.line+1,function(Mt){if(Mt.markedSpans)for(var vn=0;vn<Mt.markedSpans.length;++vn){var Mn=Mt.markedSpans[vn].marker;Mn.readOnly&&(!b||Je(b,Mn)==-1)&&(b||(b=[])).push(Mn)}}),!b)return null;for(var E=[{from:y,to:x}],re=0;re<b.length;++re)for(var le=b[re],ue=le.find(0),de=0;de<E.length;++de){var pe=E[de];if(!(Te(pe.to,ue.from)<0||Te(pe.from,ue.to)>0)){var Ze=[de,1],Ye=Te(pe.from,ue.from),Lt=Te(pe.to,ue.to);(Ye<0||!le.inclusiveLeft&&!Ye)&&Ze.push({from:pe.from,to:ue.from}),(Lt>0||!le.inclusiveRight&&!Lt)&&Ze.push({from:ue.to,to:pe.to}),E.splice.apply(E,Ze),de+=Ze.length-3}}return E}function ar(a){var y=a.markedSpans;if(y){for(var x=0;x<y.length;++x)y[x].marker.detachLine(a);a.markedSpans=null}}function or(a,y){if(y){for(var x=0;x<y.length;++x)y[x].marker.attachLine(a);a.markedSpans=y}}function hr(a){return a.inclusiveLeft?-1:0}function xr(a){return a.inclusiveRight?1:0}function br(a,y){var x=a.lines.length-y.lines.length;if(x!=0)return x;var b=a.find(),E=y.find(),re=Te(b.from,E.from)||hr(a)-hr(y);if(re)return-re;var le=Te(b.to,E.to)||xr(a)-xr(y);return le||y.id-a.id}function dr(a,y){var x=Pn&&a.markedSpans,b;if(x)for(var E=void 0,re=0;re<x.length;++re)E=x[re],E.marker.collapsed&&(y?E.from:E.to)==null&&(!b||br(b,E.marker)<0)&&(b=E.marker);return b}function er(a){return dr(a,!0)}function tn(a){return dr(a,!1)}function fn(a,y){var x=Pn&&a.markedSpans,b;if(x)for(var E=0;E<x.length;++E){var re=x[E];re.marker.collapsed&&(re.from==null||re.from<y)&&(re.to==null||re.to>y)&&(!b||br(b,re.marker)<0)&&(b=re.marker)}return b}function pn(a,y,x,b,E){var re=Dt(a,y),le=Pn&&re.markedSpans;if(le)for(var ue=0;ue<le.length;++ue){var de=le[ue];if(de.marker.collapsed){var pe=de.marker.find(0),Ze=Te(pe.from,x)||hr(de.marker)-hr(E),Ye=Te(pe.to,b)||xr(de.marker)-xr(E);if(!(Ze>=0&&Ye<=0||Ze<=0&&Ye>=0)&&(Ze<=0&&(de.marker.inclusiveRight&&E.inclusiveLeft?Te(pe.to,x)>=0:Te(pe.to,x)>0)||Ze>=0&&(de.marker.inclusiveRight&&E.inclusiveLeft?Te(pe.from,b)<=0:Te(pe.from,b)<0)))return!0}}}function Jt(a){for(var y;y=er(a);)a=y.find(-1,!0).line;return a}function zn(a){for(var y;y=tn(a);)a=y.find(1,!0).line;return a}function _n(a){for(var y,x;y=tn(a);)a=y.find(1,!0).line,(x||(x=[])).push(a);return x}function an(a,y){var x=Dt(a,y),b=Jt(x);return x==b?y:ke(b)}function dn(a,y){if(y>a.lastLine())return y;var x=Dt(a,y),b;if(!Nn(a,x))return y;for(;b=tn(x);)x=b.find(1,!0).line;return ke(x)+1}function Nn(a,y){var x=Pn&&y.markedSpans;if(x){for(var b=void 0,E=0;E<x.length;++E)if(b=x[E],!!b.marker.collapsed){if(b.from==null)return!0;if(!b.marker.widgetNode&&b.from==0&&b.marker.inclusiveLeft&&Ln(a,y,b))return!0}}}function Ln(a,y,x){if(x.to==null){var b=x.marker.find(1,!0);return Ln(a,b.line,sr(b.line.markedSpans,x.marker))}if(x.marker.inclusiveRight&&x.to==y.text.length)return!0;for(var E=void 0,re=0;re<y.markedSpans.length;++re)if(E=y.markedSpans[re],E.marker.collapsed&&!E.marker.widgetNode&&E.from==x.to&&(E.to==null||E.to!=x.from)&&(E.marker.inclusiveLeft||x.marker.inclusiveRight)&&Ln(a,y,E))return!0}function yr(a){a=Jt(a);for(var y=0,x=a.parent,b=0;b<x.lines.length;++b){var E=x.lines[b];if(E==a)break;y+=E.height}for(var re=x.parent;re;x=re,re=x.parent)for(var le=0;le<re.children.length;++le){var ue=re.children[le];if(ue==x)break;y+=ue.height}return y}function Mr(a){if(a.height==0)return 0;for(var y=a.text.length,x,b=a;x=er(b);){var E=x.find(0,!0);b=E.from.line,y+=E.from.ch-E.to.ch}for(b=a;x=tn(b);){var re=x.find(0,!0);y-=b.text.length-re.from.ch,b=re.to.line,y+=b.text.length-re.to.ch}return y}function Cr(a){var y=a.display,x=a.doc;y.maxLine=Dt(x,x.first),y.maxLineLength=Mr(y.maxLine),y.maxLineChanged=!0,x.iter(function(b){var E=Mr(b);E>y.maxLineLength&&(y.maxLineLength=E,y.maxLine=b)})}var Ar=function(a,y,x){this.text=a,or(this,y),this.height=x?x(this):1};Ar.prototype.lineNo=function(){return ke(this)},en(Ar);function Tr(a,y,x,b){a.text=y,a.stateAfter&&(a.stateAfter=null),a.styles&&(a.styles=null),a.order!=null&&(a.order=null),ar(a),or(a,x);var E=b?b(a):1;E!=a.height&&fr(a,E)}function Lr(a){a.parent=null,ar(a)}var Dr={},Nr={};function Fr(a,y){if(!a||/^\s*$/.test(a))return null;var x=y.addModeClass?Nr:Dr;return x[a]||(x[a]=a.replace(/\S+/g,"cm-$&"))}function Gr(a,y){var x=ht("span",null,null,Me?"padding-right: .1px":null),b={pre:ht("pre",[x],"CodeMirror-line"),content:x,col:0,pos:0,cm:a,trailingSpace:!1,splitSpaces:a.getOption("lineWrapping")};y.measure={};for(var E=0;E<=(y.rest?y.rest.length:0);E++){var re=E?y.rest[E-1]:y.line,le=void 0;b.pos=0,b.addToken=ri,Xn(a.display.measure)&&(le=Kt(re,a.doc.direction))&&(b.addToken=jr(b.addToken,le)),b.map=[];var ue=y!=a.display.externalMeasured&&ke(re);kr(re,b,pr(a,re,ue)),re.styleClasses&&(re.styleClasses.bgClass&&(b.bgClass=At(re.styleClasses.bgClass,b.bgClass||"")),re.styleClasses.textClass&&(b.textClass=At(re.styleClasses.textClass,b.textClass||""))),b.map.length==0&&b.map.push(0,0,b.content.appendChild(In(a.display.measure))),E==0?(y.measure.map=b.map,y.measure.cache={}):((y.measure.maps||(y.measure.maps=[])).push(b.map),(y.measure.caches||(y.measure.caches=[])).push({}))}if(Me){var de=b.content.lastChild;(/\bcm-tab\b/.test(de.className)||de.querySelector&&de.querySelector(".cm-tab"))&&(b.content.className="cm-tab-wrap-hack")}return on(a,"renderLine",a,y.line,b.pre),b.pre.className&&(b.textClass=At(b.pre.className,b.textClass||"")),b}function Qr(a){var y=tt("span","\u2022","cm-invalidchar");return y.title="\\u"+a.charCodeAt(0).toString(16),y.setAttribute("aria-label",y.title),y}function ri(a,y,x,b,E,re,le){if(y){var ue=a.splitSpaces?Wr(y,a.trailingSpace):y,de=a.cm.state.specialChars,pe=!1,Ze;if(!de.test(y))a.col+=y.length,Ze=document.createTextNode(ue),a.map.push(a.pos,a.pos+y.length,Ze),ye&&be<9&&(pe=!0),a.pos+=y.length;else{Ze=document.createDocumentFragment();for(var Ye=0;;){de.lastIndex=Ye;var Lt=de.exec(y),Mt=Lt?Lt.index-Ye:y.length-Ye;if(Mt){var vn=document.createTextNode(ue.slice(Ye,Ye+Mt));ye&&be<9?Ze.appendChild(tt("span",[vn])):Ze.appendChild(vn),a.map.push(a.pos,a.pos+Mt,vn),a.col+=Mt,a.pos+=Mt}if(!Lt)break;Ye+=Mt+1;var Mn=void 0;if(Lt[0]==" "){var Vn=a.cm.options.tabSize,tr=Vn-a.col%Vn;Mn=Ze.appendChild(tt("span",Yt(tr),"cm-tab")),Mn.setAttribute("role","presentation"),Mn.setAttribute("cm-text"," "),a.col+=tr}else Lt[0]=="\r"||Lt[0]==`
|
|
|
`?(Mn=Ze.appendChild(tt("span",Lt[0]=="\r"?"\u240D":"\u2424","cm-invalidchar")),Mn.setAttribute("cm-text",Lt[0]),a.col+=1):(Mn=a.cm.options.specialCharPlaceholder(Lt[0]),Mn.setAttribute("cm-text",Lt[0]),ye&&be<9?Ze.appendChild(tt("span",[Mn])):Ze.appendChild(Mn),a.col+=1);a.map.push(a.pos,a.pos+1,Mn),a.pos++}}if(a.trailingSpace=ue.charCodeAt(y.length-1)==32,x||b||E||pe||re||le){var ur=x||"";b&&(ur+=b),E&&(ur+=E);var nr=tt("span",[Ze],ur,re);if(le)for(var gr in le)le.hasOwnProperty(gr)&&gr!="style"&&gr!="class"&&nr.setAttribute(gr,le[gr]);return a.content.appendChild(nr)}a.content.appendChild(Ze)}}function Wr(a,y){if(a.length>1&&!/ /.test(a))return a;for(var x=y,b="",E=0;E<a.length;E++){var re=a.charAt(E);re==" "&&x&&(E==a.length-1||a.charCodeAt(E+1)==32)&&(re="\xA0"),b+=re,x=re==" "}return b}function jr(a,y){return function(x,b,E,re,le,ue,de){E=E?E+" cm-force-border":"cm-force-border";for(var pe=x.pos,Ze=pe+b.length;;){for(var Ye=void 0,Lt=0;Lt<y.length&&(Ye=y[Lt],!(Ye.to>pe&&Ye.from<=pe));Lt++);if(Ye.to>=Ze)return a(x,b,E,re,le,ue,de);a(x,b.slice(0,Ye.to-pe),E,re,null,ue,de),re=null,b=b.slice(Ye.to-pe),pe=Ye.to}}}function Ur(a,y,x,b){var E=!b&&x.widgetNode;E&&a.map.push(a.pos,a.pos+y,E),!b&&a.cm.display.input.needsContentAttribute&&(E||(E=a.content.appendChild(document.createElement("span"))),E.setAttribute("cm-marker",x.id)),E&&(a.cm.display.input.setUneditable(E),a.content.appendChild(E)),a.pos+=y,a.trailingSpace=!1}function kr(a,y,x){var b=a.markedSpans,E=a.text,re=0;if(!b){for(var le=1;le<x.length;le+=2)y.addToken(y,E.slice(re,re=x[le]),Fr(x[le+1],y.cm.options));return}for(var ue=E.length,de=0,pe=1,Ze="",Ye,Lt,Mt=0,vn,Mn,Vn,tr,ur;;){if(Mt==de){vn=Mn=Vn=Lt="",ur=null,tr=null,Mt=1/0;for(var nr=[],gr=void 0,Ir=0;Ir<b.length;++Ir){var Er=b[Ir],zr=Er.marker;if(zr.type=="bookmark"&&Er.from==de&&zr.widgetNode)nr.push(zr);else if(Er.from<=de&&(Er.to==null||Er.to>de||zr.collapsed&&Er.to==de&&Er.from==de)){if(Er.to!=null&&Er.to!=de&&Mt>Er.to&&(Mt=Er.to,Mn=""),zr.className&&(vn+=" "+zr.className),zr.css&&(Lt=(Lt?Lt+";":"")+zr.css),zr.startStyle&&Er.from==de&&(Vn+=" "+zr.startStyle),zr.endStyle&&Er.to==Mt&&(gr||(gr=[])).push(zr.endStyle,Er.to),zr.title&&((ur||(ur={})).title=zr.title),zr.attributes)for(var Yr in zr.attributes)(ur||(ur={}))[Yr]=zr.attributes[Yr];zr.collapsed&&(!tr||br(tr.marker,zr)<0)&&(tr=Er)}else Er.from>de&&Mt>Er.from&&(Mt=Er.from)}if(gr)for(var bi=0;bi<gr.length;bi+=2)gr[bi+1]==Mt&&(Mn+=" "+gr[bi]);if(!tr||tr.from==de)for(var ti=0;ti<nr.length;++ti)Ur(y,0,nr[ti]);if(tr&&(tr.from||0)==de){if(Ur(y,(tr.to==null?ue+1:tr.to)-de,tr.marker,tr.from==null),tr.to==null)return;tr.to==de&&(tr=!1)}}if(de>=ue)break;for(var Wi=Math.min(ue,Mt);;){if(Ze){var Ri=de+Ze.length;if(!tr){var ci=Ri>Wi?Ze.slice(0,Wi-de):Ze;y.addToken(y,ci,Ye?Ye+vn:vn,Vn,de+ci.length==Mt?Mn:"",Lt,ur)}if(Ri>=Wi){Ze=Ze.slice(Wi-de),de=Wi;break}de=Ri,Vn=""}Ze=E.slice(re,re=x[pe++]),Ye=Fr(x[pe++],y.cm.options)}}}function Jr(a,y,x){this.line=y,this.rest=_n(y),this.size=this.rest?ke(ze(this.rest))-x+1:1,this.node=this.text=null,this.hidden=Nn(a,y)}function Xr(a,y,x){for(var b=[],E,re=y;re<x;re=E){var le=new Jr(a.doc,Dt(a.doc,re),re);E=re+le.size,b.push(le)}return b}var li=null;function Ci(a){li?li.ops.push(a):a.ownsGroup=li={ops:[a],delayedCallbacks:[]}}function fi(a){var y=a.delayedCallbacks,x=0;do{for(;x<y.length;x++)y[x].call(null);for(var b=0;b<a.ops.length;b++){var E=a.ops[b];if(E.cursorActivityHandlers)for(;E.cursorActivityCalled<E.cursorActivityHandlers.length;)E.cursorActivityHandlers[E.cursorActivityCalled++].call(null,E.cm)}}while(x<y.length)}function hi(a,y){var x=a.ownsGroup;if(x)try{fi(x)}finally{li=null,y(x)}}var Ii=null;function _r(a,y){var x=rn(a,y);if(x.length){var b=Array.prototype.slice.call(arguments,2),E;li?E=li.delayedCallbacks:Ii?E=Ii:(E=Ii=[],setTimeout(si,0));for(var re=function(ue){E.push(function(){return x[ue].apply(null,b)})},le=0;le<x.length;++le)re(le)}}function si(){var a=Ii;Ii=null;for(var y=0;y<a.length;++y)a[y]()}function Oi(a,y,x,b){for(var E=0;E<y.changes.length;E++){var re=y.changes[E];re=="text"?to(a,y):re=="gutter"?Br(a,y,x,b):re=="class"?wr(a,y):re=="widget"&&Or(a,y,b)}y.changes=null}function ki(a){return a.node==a.text&&(a.node=tt("div",null,null,"position: relative"),a.text.parentNode&&a.text.parentNode.replaceChild(a.node,a.text),a.node.appendChild(a.text),ye&&be<8&&(a.node.style.zIndex=2)),a.node}function qr(a,y){var x=y.bgClass?y.bgClass+" "+(y.line.bgClass||""):y.line.bgClass;if(x&&(x+=" CodeMirror-linebackground"),y.background)x?y.background.className=x:(y.background.parentNode.removeChild(y.background),y.background=null);else if(x){var b=ki(y);y.background=b.insertBefore(tt("div",null,x),b.firstChild),a.display.input.setUneditable(y.background)}}function Ui(a,y){var x=a.display.externalMeasured;return x&&x.line==y.line?(a.display.externalMeasured=null,y.measure=x.measure,x.built):Gr(a,y)}function to(a,y){var x=y.text.className,b=Ui(a,y);y.text==y.node&&(y.node=b.pre),y.text.parentNode.replaceChild(b.pre,y.text),y.text=b.pre,b.bgClass!=y.bgClass||b.textClass!=y.textClass?(y.bgClass=b.bgClass,y.textClass=b.textClass,wr(a,y)):x&&(y.text.className=x)}function wr(a,y){qr(a,y),y.line.wrapClass?ki(y).className=y.line.wrapClass:y.node!=y.text&&(y.node.className="");var x=y.textClass?y.textClass+" "+(y.line.textClass||""):y.line.textClass;y.text.className=x||""}function Br(a,y,x,b){if(y.gutter&&(y.node.removeChild(y.gutter),y.gutter=null),y.gutterBackground&&(y.node.removeChild(y.gutterBackground),y.gutterBackground=null),y.line.gutterClass){var E=ki(y);y.gutterBackground=tt("div",null,"CodeMirror-gutter-background "+y.line.gutterClass,"left: "+(a.options.fixedGutter?b.fixedPos:-b.gutterTotalWidth)+"px; width: "+b.gutterTotalWidth+"px"),a.display.input.setUneditable(y.gutterBackground),E.insertBefore(y.gutterBackground,y.text)}var re=y.line.gutterMarkers;if(a.options.lineNumbers||re){var le=ki(y),ue=y.gutter=tt("div",null,"CodeMirror-gutter-wrapper","left: "+(a.options.fixedGutter?b.fixedPos:-b.gutterTotalWidth)+"px");if(a.display.input.setUneditable(ue),le.insertBefore(ue,y.text),y.line.gutterClass&&(ue.className+=" "+y.line.gutterClass),a.options.lineNumbers&&(!re||!re["CodeMirror-linenumbers"])&&(y.lineNumber=ue.appendChild(tt("div",Be(a.options,x),"CodeMirror-linenumber CodeMirror-gutter-elt","left: "+b.gutterLeft["CodeMirror-linenumbers"]+"px; width: "+a.display.lineNumInnerWidth+"px"))),re)for(var de=0;de<a.display.gutterSpecs.length;++de){var pe=a.display.gutterSpecs[de].className,Ze=re.hasOwnProperty(pe)&&re[pe];Ze&&ue.appendChild(tt("div",[Ze],"CodeMirror-gutter-elt","left: "+b.gutterLeft[pe]+"px; width: "+b.gutterWidth[pe]+"px"))}}}function Or(a,y,x){y.alignable&&(y.alignable=null);for(var b=it("CodeMirror-linewidget"),E=y.node.firstChild,re=void 0;E;E=re)re=E.nextSibling,b.test(E.className)&&y.node.removeChild(E);Hr(a,y,x)}function Pr(a,y,x,b){var E=Ui(a,y);return y.text=y.node=E.pre,E.bgClass&&(y.bgClass=E.bgClass),E.textClass&&(y.textClass=E.textClass),wr(a,y),Br(a,y,x,b),Hr(a,y,b),y.node}function Hr(a,y,x){if($r(a,y.line,y,x,!0),y.rest)for(var b=0;b<y.rest.length;b++)$r(a,y.rest[b],y,x,!1)}function $r(a,y,x,b,E){if(y.widgets)for(var re=ki(x),le=0,ue=y.widgets;le<ue.length;++le){var de=ue[le],pe=tt("div",[de.node],"CodeMirror-linewidget"+(de.className?" "+de.className:""));de.handleMouseEvents||pe.setAttribute("cm-ignore-events","true"),pi(de,pe,x,b),a.display.input.setUneditable(pe),E&&de.above?re.insertBefore(pe,x.gutter||x.text):re.appendChild(pe),_r(de,"redraw")}}function pi(a,y,x,b){if(a.noHScroll){(x.alignable||(x.alignable=[])).push(y);var E=b.wrapperWidth;y.style.left=b.fixedPos+"px",a.coverGutter||(E-=b.gutterTotalWidth,y.style.paddingLeft=b.gutterTotalWidth+"px"),y.style.width=E+"px"}a.coverGutter&&(y.style.zIndex=5,y.style.position="relative",a.noHScroll||(y.style.marginLeft=-b.gutterTotalWidth+"px"))}function ui(a){if(a.height!=null)return a.height;var y=a.doc.cm;if(!y)return 0;if(!at(document.body,a.node)){var x="position: relative;";a.coverGutter&&(x+="margin-left: -"+y.display.gutters.offsetWidth+"px;"),a.noHScroll&&(x+="width: "+y.display.wrapper.clientWidth+"px;"),nt(y.display.measure,tt("div",[a.node],null,x))}return a.height=a.node.parentNode.offsetHeight}function wi(a,y){for(var x=rt(y);x!=a.wrapper;x=x.parentNode)if(!x||x.nodeType==1&&x.getAttribute("cm-ignore-events")=="true"||x.parentNode==a.sizer&&x!=a.mover)return!0}function ii(a){return a.lineSpace.offsetTop}function _i(a){return a.mover.offsetHeight-a.lineSpace.offsetHeight}function no(a){if(a.cachedPaddingH)return a.cachedPaddingH;var y=nt(a.measure,tt("pre","x","CodeMirror-line-like")),x=window.getComputedStyle?window.getComputedStyle(y):y.currentStyle,b={left:parseInt(x.paddingLeft),right:parseInt(x.paddingRight)};return!isNaN(b.left)&&!isNaN(b.right)&&(a.cachedPaddingH=b),b}function $i(a){return jt-a.display.nativeBarWidth}function ro(a){return a.display.scroller.clientWidth-$i(a)-a.display.barWidth}function ao(a){return a.display.scroller.clientHeight-$i(a)-a.display.barHeight}function Yi(a,y,x){var b=a.options.lineWrapping,E=b&&ro(a);if(!y.measure.heights||b&&y.measure.width!=E){var re=y.measure.heights=[];if(b){y.measure.width=E;for(var le=y.text.firstChild.getClientRects(),ue=0;ue<le.length-1;ue++){var de=le[ue],pe=le[ue+1];Math.abs(de.bottom-pe.bottom)>2&&re.push((de.bottom+pe.top)/2-x.top)}}re.push(x.bottom-x.top)}}function ko(a,y,x){if(a.line==y)return{map:a.measure.map,cache:a.measure.cache};for(var b=0;b<a.rest.length;b++)if(a.rest[b]==y)return{map:a.measure.maps[b],cache:a.measure.caches[b]};for(var E=0;E<a.rest.length;E++)if(ke(a.rest[E])>x)return{map:a.measure.maps[E],cache:a.measure.caches[E],before:!0}}function Ga(a,y){y=Jt(y);var x=ke(y),b=a.display.externalMeasured=new Jr(a.doc,y,x);b.lineN=x;var E=b.built=Gr(a,b);return b.text=E.pre,nt(a.display.lineMeasure,E.pre),b}function ya(a,y,x,b){return Ki(a,co(a,y),x,b)}function io(a,y){if(y>=a.display.viewFrom&&y<a.display.viewTo)return a.display.view[So(a,y)];var x=a.display.externalMeasured;if(x&&y>=x.lineN&&y<x.lineN+x.size)return x}function co(a,y){var x=ke(y),b=io(a,x);b&&!b.text?b=null:b&&b.changes&&(Oi(a,b,x,fo(a)),a.curOp.forceUpdate=!0),b||(b=Ga(a,y));var E=ko(b,y,x);return{line:y,view:b,rect:null,map:E.map,cache:E.cache,before:E.before,hasHeights:!1}}function Ki(a,y,x,b,E){y.before&&(x=-1);var re=x+(b||""),le;return y.cache.hasOwnProperty(re)?le=y.cache[re]:(y.rect||(y.rect=y.view.text.getBoundingClientRect()),y.hasHeights||(Yi(a,y.view,y.rect),y.hasHeights=!0),le=Ca(a,y,x,b),le.bogus||(y.cache[re]=le)),{left:le.left,right:le.right,top:E?le.rtop:le.top,bottom:E?le.rbottom:le.bottom}}var ba={left:0,right:0,top:0,bottom:0};function xa(a,y,x){for(var b,E,re,le,ue,de,pe=0;pe<a.length;pe+=3)if(ue=a[pe],de=a[pe+1],y<ue?(E=0,re=1,le="left"):y<de?(E=y-ue,re=E+1):(pe==a.length-3||y==de&&a[pe+3]>y)&&(re=de-ue,E=re-1,y>=de&&(le="right")),E!=null){if(b=a[pe+2],ue==de&&x==(b.insertLeft?"left":"right")&&(le=x),x=="left"&&E==0)for(;pe&&a[pe-2]==a[pe-3]&&a[pe-1].insertLeft;)b=a[(pe-=3)+2],le="left";if(x=="right"&&E==de-ue)for(;pe<a.length-3&&a[pe+3]==a[pe+4]&&!a[pe+5].insertLeft;)b=a[(pe+=3)+2],le="right";break}return{node:b,start:E,end:re,collapse:le,coverStart:ue,coverEnd:de}}function Va(a,y){var x=ba;if(y=="left")for(var b=0;b<a.length&&(x=a[b]).left==x.right;b++);else for(var E=a.length-1;E>=0&&(x=a[E]).left==x.right;E--);return x}function Ca(a,y,x,b){var E=xa(y.map,x,b),re=E.node,le=E.start,ue=E.end,de=E.collapse,pe;if(re.nodeType==3){for(var Ze=0;Ze<4;Ze++){for(;le&&xe(y.line.text.charAt(E.coverStart+le));)--le;for(;E.coverStart+ue<E.coverEnd&&xe(y.line.text.charAt(E.coverStart+ue));)++ue;if(ye&&be<9&&le==0&&ue==E.coverEnd-E.coverStart?pe=re.parentNode.getBoundingClientRect():pe=Va($e(re,le,ue).getClientRects(),b),pe.left||pe.right||le==0)break;ue=le,le=le-1,de="right"}ye&&be<11&&(pe=Ua(a.display.measure,pe))}else{le>0&&(de=b="right");var Ye;a.options.lineWrapping&&(Ye=re.getClientRects()).length>1?pe=Ye[b=="right"?Ye.length-1:0]:pe=re.getBoundingClientRect()}if(ye&&be<9&&!le&&(!pe||!pe.left&&!pe.right)){var Lt=re.parentNode.getClientRects()[0];Lt?pe={left:Lt.left,right:Lt.left+Qi(a.display),top:Lt.top,bottom:Lt.bottom}:pe=ba}for(var Mt=pe.top-y.rect.top,vn=pe.bottom-y.rect.top,Mn=(Mt+vn)/2,Vn=y.view.measure.heights,tr=0;tr<Vn.length-1&&!(Mn<Vn[tr]);tr++);var ur=tr?Vn[tr-1]:0,nr=Vn[tr],gr={left:(de=="right"?pe.right:pe.left)-y.rect.left,right:(de=="left"?pe.left:pe.right)-y.rect.left,top:ur,bottom:nr};return!pe.left&&!pe.right&&(gr.bogus=!0),a.options.singleCursorHeightPerLine||(gr.rtop=Mt,gr.rbottom=vn),gr}function Ua(a,y){if(!window.screen||screen.logicalXDPI==null||screen.logicalXDPI==screen.deviceXDPI||!vt(a))return y;var x=screen.logicalXDPI/screen.deviceXDPI,b=screen.logicalYDPI/screen.deviceYDPI;return{left:y.left*x,right:y.right*x,top:y.top*b,bottom:y.bottom*b}}function _o(a){if(a.measure&&(a.measure.cache={},a.measure.heights=null,a.rest))for(var y=0;y<a.rest.length;y++)a.measure.caches[y]={}}function Ko(a){a.display.externalMeasure=null,Ot(a.display.lineMeasure);for(var y=0;y<a.display.view.length;y++)_o(a.display.view[y])}function Co(a){Ko(a),a.display.cachedCharWidth=a.display.cachedTextHeight=a.display.cachedPaddingH=null,a.options.lineWrapping||(a.display.maxLineChanged=!0),a.display.lineNumChars=null}function Xo(){return Oe&&Le?-(document.body.getBoundingClientRect().left-parseInt(getComputedStyle(document.body).marginLeft)):window.pageXOffset||(document.documentElement||document.body).scrollLeft}function wa(){return Oe&&Le?-(document.body.getBoundingClientRect().top-parseInt(getComputedStyle(document.body).marginTop)):window.pageYOffset||(document.documentElement||document.body).scrollTop}function Yo(a){var y=0;if(a.widgets)for(var x=0;x<a.widgets.length;++x)a.widgets[x].above&&(y+=ui(a.widgets[x]));return y}function To(a,y,x,b,E){if(!E){var re=Yo(y);x.top+=re,x.bottom+=re}if(b=="line")return x;b||(b="local");var le=yr(y);if(b=="local"?le+=ii(a.display):le-=a.display.viewOffset,b=="page"||b=="window"){var ue=a.display.lineSpace.getBoundingClientRect();le+=ue.top+(b=="window"?0:wa());var de=ue.left+(b=="window"?0:Xo());x.left+=de,x.right+=de}return x.top+=le,x.bottom+=le,x}function Sa(a,y,x){if(x=="div")return y;var b=y.left,E=y.top;if(x=="page")b-=Xo(),E-=wa();else if(x=="local"||!x){var re=a.display.sizer.getBoundingClientRect();b+=re.left,E+=re.top}var le=a.display.lineSpace.getBoundingClientRect();return{left:b-le.left,top:E-le.top}}function Lo(a,y,x,b,E){return b||(b=Dt(a.doc,y.line)),To(a,b,ya(a,b,y.ch,E),x)}function Bi(a,y,x,b,E,re){b=b||Dt(a.doc,y.line),E||(E=co(a,b));function le(vn,Mn){var Vn=Ki(a,E,vn,Mn?"right":"left",re);return Mn?Vn.left=Vn.right:Vn.right=Vn.left,To(a,b,Vn,x)}var ue=Kt(b,a.doc.direction),de=y.ch,pe=y.sticky;if(de>=b.text.length?(de=b.text.length,pe="before"):de<=0&&(de=0,pe="after"),!ue)return le(pe=="before"?de-1:de,pe=="before");function Ze(vn,Mn,Vn){var tr=ue[Mn],ur=tr.level==1;return le(Vn?vn-1:vn,ur!=Vn)}var Ye=bt(ue,de,pe),Lt=qe,Mt=Ze(de,Ye,pe=="before");return Lt!=null&&(Mt.other=Ze(de,Lt,pe!="before")),Mt}function Zr(a,y){var x=0;y=Ct(a.doc,y),a.options.lineWrapping||(x=Qi(a.display)*y.ch);var b=Dt(a.doc,y.line),E=yr(b)+ii(a.display);return{left:x,right:x,top:E,bottom:E+b.height}}function Rr(a,y,x,b,E){var re=we(a,y,x);return re.xRel=E,b&&(re.outside=b),re}function Si(a,y,x){var b=a.doc;if(x+=a.display.viewOffset,x<0)return Rr(b.first,0,null,-1,-1);var E=_e(b,x),re=b.first+b.size-1;if(E>re)return Rr(b.first+b.size-1,Dt(b,re).text.length,null,1,1);y<0&&(y=0);for(var le=Dt(b,E);;){var ue=Ji(a,le,E,y,x),de=fn(le,ue.ch+(ue.xRel>0||ue.outside>0?1:0));if(!de)return ue;var pe=de.find(1);if(pe.line==E)return pe;le=Dt(b,E=pe.line)}}function Mi(a,y,x,b){b-=Yo(y);var E=y.text.length,re=Ee(function(le){return Ki(a,x,le-1).bottom<=b},E,0);return E=Ee(function(le){return Ki(a,x,le).top>b},re,E),{begin:re,end:E}}function oi(a,y,x,b){x||(x=co(a,y));var E=To(a,y,Ki(a,x,b),"line").top;return Mi(a,y,x,E)}function mi(a,y,x,b){return a.bottom<=x?!1:a.top>x?!0:(b?a.left:a.right)>y}function Ji(a,y,x,b,E){E-=yr(y);var re=co(a,y),le=Yo(y),ue=0,de=y.text.length,pe=!0,Ze=Kt(y,a.doc.direction);if(Ze){var Ye=(a.options.lineWrapping?lo:Xi)(a,y,x,re,Ze,b,E);pe=Ye.level!=1,ue=pe?Ye.from:Ye.to-1,de=pe?Ye.to:Ye.from-1}var Lt=null,Mt=null,vn=Ee(function(Ir){var Er=Ki(a,re,Ir);return Er.top+=le,Er.bottom+=le,mi(Er,b,E,!1)?(Er.top<=E&&Er.left<=b&&(Lt=Ir,Mt=Er),!0):!1},ue,de),Mn,Vn,tr=!1;if(Mt){var ur=b-Mt.left<Mt.right-b,nr=ur==pe;vn=Lt+(nr?0:1),Vn=nr?"after":"before",Mn=ur?Mt.left:Mt.right}else{!pe&&(vn==de||vn==ue)&&vn++,Vn=vn==0?"after":vn==y.text.length?"before":Ki(a,re,vn-(pe?1:0)).bottom+le<=E==pe?"after":"before";var gr=Bi(a,we(x,vn,Vn),"line",y,re);Mn=gr.left,tr=E<gr.top?-1:E>=gr.bottom?1:0}return vn=ot(y.text,vn,1),Rr(x,vn,Vn,tr,b-Mn)}function Xi(a,y,x,b,E,re,le){var ue=Ee(function(Ye){var Lt=E[Ye],Mt=Lt.level!=1;return mi(Bi(a,we(x,Mt?Lt.to:Lt.from,Mt?"before":"after"),"line",y,b),re,le,!0)},0,E.length-1),de=E[ue];if(ue>0){var pe=de.level!=1,Ze=Bi(a,we(x,pe?de.from:de.to,pe?"after":"before"),"line",y,b);mi(Ze,re,le,!0)&&Ze.top>le&&(de=E[ue-1])}return de}function lo(a,y,x,b,E,re,le){var ue=Mi(a,y,b,le),de=ue.begin,pe=ue.end;/\s/.test(y.text.charAt(pe-1))&&pe--;for(var Ze=null,Ye=null,Lt=0;Lt<E.length;Lt++){var Mt=E[Lt];if(!(Mt.from>=pe||Mt.to<=de)){var vn=Mt.level!=1,Mn=Ki(a,b,vn?Math.min(pe,Mt.to)-1:Math.max(de,Mt.from)).right,Vn=Mn<re?re-Mn+1e9:Mn-re;(!Ze||Ye>Vn)&&(Ze=Mt,Ye=Vn)}}return Ze||(Ze=E[E.length-1]),Ze.from<de&&(Ze={from:de,to:Ze.to,level:Ze.level}),Ze.to>pe&&(Ze={from:Ze.from,to:pe,level:Ze.level}),Ze}var Hi;function Zi(a){if(a.cachedTextHeight!=null)return a.cachedTextHeight;if(Hi==null){Hi=tt("pre",null,"CodeMirror-line-like");for(var y=0;y<49;++y)Hi.appendChild(document.createTextNode("x")),Hi.appendChild(tt("br"));Hi.appendChild(document.createTextNode("x"))}nt(a.measure,Hi);var x=Hi.offsetHeight/50;return x>3&&(a.cachedTextHeight=x),Ot(a.measure),x||1}function Qi(a){if(a.cachedCharWidth!=null)return a.cachedCharWidth;var y=tt("span","xxxxxxxxxx"),x=tt("pre",[y],"CodeMirror-line-like");nt(a.measure,x);var b=y.getBoundingClientRect(),E=(b.right-b.left)/10;return E>2&&(a.cachedCharWidth=E),E||10}function fo(a){for(var y=a.display,x={},b={},E=y.gutters.clientLeft,re=y.gutters.firstChild,le=0;re;re=re.nextSibling,++le){var ue=a.display.gutterSpecs[le].className;x[ue]=re.offsetLeft+re.clientLeft+E,b[ue]=re.clientWidth}return{fixedPos:_a(y),gutterTotalWidth:y.gutters.offsetWidth,gutterLeft:x,gutterWidth:b,wrapperWidth:y.wrapper.clientWidth}}function _a(a){return a.scroller.getBoundingClientRect().left-a.sizer.getBoundingClientRect().left}function Cl(a){var y=Zi(a.display),x=a.options.lineWrapping,b=x&&Math.max(5,a.display.scroller.clientWidth/Qi(a.display)-3);return function(E){if(Nn(a.doc,E))return 0;var re=0;if(E.widgets)for(var le=0;le<E.widgets.length;le++)E.widgets[le].height&&(re+=E.widgets[le].height);return x?re+(Math.ceil(E.text.length/b)||1)*y:re+y}}function Ka(a){var y=a.doc,x=Cl(a);y.iter(function(b){var E=x(b);E!=b.height&&fr(b,E)})}function wo(a,y,x,b){var E=a.display;if(!x&&rt(y).getAttribute("cm-not-content")=="true")return null;var re,le,ue=E.lineSpace.getBoundingClientRect();try{re=y.clientX-ue.left,le=y.clientY-ue.top}catch(Ye){return null}var de=Si(a,re,le),pe;if(b&&de.xRel>0&&(pe=Dt(a.doc,de.line).text).length==de.ch){var Ze=ge(pe,pe.length,a.options.tabSize)-pe.length;de=we(de.line,Math.max(0,Math.round((re-no(a.display).left)/Qi(a.display))-Ze))}return de}function So(a,y){if(y>=a.display.viewTo||(y-=a.display.viewFrom,y<0))return null;for(var x=a.display.view,b=0;b<x.length;b++)if(y-=x[b].size,y<0)return b}function Ai(a,y,x,b){y==null&&(y=a.doc.first),x==null&&(x=a.doc.first+a.doc.size),b||(b=0);var E=a.display;if(b&&x<E.viewTo&&(E.updateLineNumbers==null||E.updateLineNumbers>y)&&(E.updateLineNumbers=y),a.curOp.viewChanged=!0,y>=E.viewTo)Pn&&an(a.doc,y)<E.viewTo&&po(a);else if(x<=E.viewFrom)Pn&&dn(a.doc,x+b)>E.viewFrom?po(a):(E.viewFrom+=b,E.viewTo+=b);else if(y<=E.viewFrom&&x>=E.viewTo)po(a);else if(y<=E.viewFrom){var re=Ea(a,x,x+b,1);re?(E.view=E.view.slice(re.index),E.viewFrom=re.lineN,E.viewTo+=b):po(a)}else if(x>=E.viewTo){var le=Ea(a,y,y,-1);le?(E.view=E.view.slice(0,le.index),E.viewTo=le.lineN):po(a)}else{var ue=Ea(a,y,y,-1),de=Ea(a,x,x+b,1);ue&&de?(E.view=E.view.slice(0,ue.index).concat(Xr(a,ue.lineN,de.lineN)).concat(E.view.slice(de.index)),E.viewTo+=b):po(a)}var pe=E.externalMeasured;pe&&(x<pe.lineN?pe.lineN+=b:y<pe.lineN+pe.size&&(E.externalMeasured=null))}function ho(a,y,x){a.curOp.viewChanged=!0;var b=a.display,E=a.display.externalMeasured;if(E&&y>=E.lineN&&y<E.lineN+E.size&&(b.externalMeasured=null),!(y<b.viewFrom||y>=b.viewTo)){var re=b.view[So(a,y)];if(re.node!=null){var le=re.changes||(re.changes=[]);Je(le,x)==-1&&le.push(x)}}}function po(a){a.display.viewFrom=a.display.viewTo=a.doc.first,a.display.view=[],a.display.viewOffset=0}function Ea(a,y,x,b){var E=So(a,y),re,le=a.display.view;if(!Pn||x==a.doc.first+a.doc.size)return{index:E,lineN:x};for(var ue=a.display.viewFrom,de=0;de<E;de++)ue+=le[de].size;if(ue!=y){if(b>0){if(E==le.length-1)return null;re=ue+le[E].size-y,E++}else re=ue-y;y+=re,x+=re}for(;an(a.doc,x)!=x;){if(E==(b<0?0:le.length-1))return null;x+=b*le[E-(b<0?1:0)].size,E+=b}return{index:E,lineN:x}}function $s(a,y,x){var b=a.display,E=b.view;E.length==0||y>=b.viewTo||x<=b.viewFrom?(b.view=Xr(a,y,x),b.viewFrom=y):(b.viewFrom>y?b.view=Xr(a,y,b.viewFrom).concat(b.view):b.viewFrom<y&&(b.view=b.view.slice(So(a,y))),b.viewFrom=y,b.viewTo<x?b.view=b.view.concat(Xr(a,b.viewTo,x)):b.viewTo>x&&(b.view=b.view.slice(0,So(a,x)))),b.viewTo=x}function wl(a){for(var y=a.display.view,x=0,b=0;b<y.length;b++){var E=y[b];!E.hidden&&(!E.node||E.changes)&&++x}return x}function Jo(a){a.display.input.showSelection(a.display.input.prepareSelection())}function Sl(a,y){y===void 0&&(y=!0);for(var x=a.doc,b={},E=b.cursors=document.createDocumentFragment(),re=b.selection=document.createDocumentFragment(),le=0;le<x.sel.ranges.length;le++)if(!(!y&&le==x.sel.primIndex)){var ue=x.sel.ranges[le];if(!(ue.from().line>=a.display.viewTo||ue.to().line<a.display.viewFrom)){var de=ue.empty();(de||a.options.showCursorWhenSelecting)&&El(a,ue.head,E),de||Hs(a,ue,re)}}return b}function El(a,y,x){var b=Bi(a,y,"div",null,null,!a.options.singleCursorHeightPerLine),E=x.appendChild(tt("div","\xA0","CodeMirror-cursor"));if(E.style.left=b.left+"px",E.style.top=b.top+"px",E.style.height=Math.max(0,b.bottom-b.top)*a.options.cursorHeight+"px",b.other){var re=x.appendChild(tt("div","\xA0","CodeMirror-cursor CodeMirror-secondarycursor"));re.style.display="",re.style.left=b.other.left+"px",re.style.top=b.other.top+"px",re.style.height=(b.other.bottom-b.other.top)*.85+"px"}}function Ia(a,y){return a.top-y.top||a.left-y.left}function Hs(a,y,x){var b=a.display,E=a.doc,re=document.createDocumentFragment(),le=no(a.display),ue=le.left,de=Math.max(b.sizerWidth,ro(a)-b.sizer.offsetLeft)-le.right,pe=E.direction=="ltr";function Ze(nr,gr,Ir,Er){gr<0&&(gr=0),gr=Math.round(gr),Er=Math.round(Er),re.appendChild(tt("div",null,"CodeMirror-selected","position: absolute; left: "+nr+`px;
|
|
|
top: `+gr+"px; width: "+(Ir==null?de-nr:Ir)+`px;
|
|
|
height: `+(Er-gr)+"px"))}function Ye(nr,gr,Ir){var Er=Dt(E,nr),zr=Er.text.length,Yr,bi;function ti(ci,Fi){return Lo(a,we(nr,ci),"div",Er,Fi)}function Wi(ci,Fi,Ei){var vi=oi(a,Er,null,ci),di=Fi=="ltr"==(Ei=="after")?"left":"right",ni=Ei=="after"?vi.begin:vi.end-(/\s/.test(Er.text.charAt(vi.end-1))?2:1);return ti(ni,di)[di]}var Ri=Kt(Er,E.direction);return Fe(Ri,gr||0,Ir==null?zr:Ir,function(ci,Fi,Ei,vi){var di=Ei=="ltr",ni=ti(ci,di?"left":"right"),zi=ti(Fi-1,di?"right":"left"),Vo=gr==null&&ci==0,xo=Ir==null&&Fi==zr,Di=vi==0,oo=!Ri||vi==Ri.length-1;if(zi.top-ni.top<=3){var xi=(pe?Vo:xo)&&Di,bl=(pe?xo:Vo)&&oo,uo=xi?ue:(di?ni:zi).left,Po=bl?de:(di?zi:ni).right;Ze(uo,ni.top,Po-uo,ni.bottom)}else{var Do,Li,Uo,xl;di?(Do=pe&&Vo&&Di?ue:ni.left,Li=pe?de:Wi(ci,Ei,"before"),Uo=pe?ue:Wi(Fi,Ei,"after"),xl=pe&&xo&&oo?de:zi.right):(Do=pe?Wi(ci,Ei,"before"):ue,Li=!pe&&Vo&&Di?de:ni.right,Uo=!pe&&xo&&oo?ue:zi.left,xl=pe?Wi(Fi,Ei,"after"):de),Ze(Do,ni.top,Li-Do,ni.bottom),ni.bottom<zi.top&&Ze(ue,ni.bottom,null,zi.top),Ze(Uo,zi.top,xl-Uo,zi.bottom)}(!Yr||Ia(ni,Yr)<0)&&(Yr=ni),Ia(zi,Yr)<0&&(Yr=zi),(!bi||Ia(ni,bi)<0)&&(bi=ni),Ia(zi,bi)<0&&(bi=zi)}),{start:Yr,end:bi}}var Lt=y.from(),Mt=y.to();if(Lt.line==Mt.line)Ye(Lt.line,Lt.ch,Mt.ch);else{var vn=Dt(E,Lt.line),Mn=Dt(E,Mt.line),Vn=Jt(vn)==Jt(Mn),tr=Ye(Lt.line,Lt.ch,Vn?vn.text.length+1:null).end,ur=Ye(Mt.line,Vn?0:null,Mt.ch).start;Vn&&(tr.top<ur.top-2?(Ze(tr.right,tr.top,null,tr.bottom),Ze(ue,ur.top,ur.left,ur.bottom)):Ze(tr.right,tr.top,ur.left-tr.right,tr.bottom)),tr.bottom<ur.top&&Ze(ue,tr.bottom,null,ur.top)}x.appendChild(re)}function Xa(a){if(a.state.focused){var y=a.display;clearInterval(y.blinker);var x=!0;y.cursorDiv.style.visibility="",a.options.cursorBlinkRate>0?y.blinker=setInterval(function(){a.hasFocus()||Bo(a),y.cursorDiv.style.visibility=(x=!x)?"":"hidden"},a.options.cursorBlinkRate):a.options.cursorBlinkRate<0&&(y.cursorDiv.style.visibility="hidden")}}function Il(a){a.state.focused||(a.display.input.focus(),Ya(a))}function Ol(a){a.state.delayingBlurEvent=!0,setTimeout(function(){a.state.delayingBlurEvent&&(a.state.delayingBlurEvent=!1,Bo(a))},100)}function Ya(a,y){a.state.delayingBlurEvent&&(a.state.delayingBlurEvent=!1),a.options.readOnly!="nocursor"&&(a.state.focused||(on(a,"focus",a,y),a.state.focused=!0,me(a.display.wrapper,"CodeMirror-focused"),!a.curOp&&a.display.selForContextMenu!=a.doc.sel&&(a.display.input.reset(),Me&&setTimeout(function(){return a.display.input.reset(!0)},20)),a.display.input.receivedFocus()),Xa(a))}function Bo(a,y){a.state.delayingBlurEvent||(a.state.focused&&(on(a,"blur",a,y),a.state.focused=!1,je(a.display.wrapper,"CodeMirror-focused")),clearInterval(a.display.blinker),setTimeout(function(){a.state.focused||(a.display.shift=!1)},150))}function Oa(a){for(var y=a.display,x=y.lineDiv.offsetTop,b=0;b<y.view.length;b++){var E=y.view[b],re=a.options.lineWrapping,le=void 0,ue=0;if(!E.hidden){if(ye&&be<8){var de=E.node.offsetTop+E.node.offsetHeight;le=de-x,x=de}else{var pe=E.node.getBoundingClientRect();le=pe.bottom-pe.top,!re&&E.text.firstChild&&(ue=E.text.firstChild.getBoundingClientRect().right-pe.left-1)}var Ze=E.line.height-le;if((Ze>.005||Ze<-.005)&&(fr(E.line,le),Ml(E.line),E.rest))for(var Ye=0;Ye<E.rest.length;Ye++)Ml(E.rest[Ye]);if(ue>a.display.sizerWidth){var Lt=Math.ceil(ue/Qi(a.display));Lt>a.display.maxLineLength&&(a.display.maxLineLength=Lt,a.display.maxLine=E.line,a.display.maxLineChanged=!0)}}}}function Ml(a){if(a.widgets)for(var y=0;y<a.widgets.length;++y){var x=a.widgets[y],b=x.node.parentNode;b&&(x.height=b.offsetHeight)}}function Ma(a,y,x){var b=x&&x.top!=null?Math.max(0,x.top):a.scroller.scrollTop;b=Math.floor(b-ii(a));var E=x&&x.bottom!=null?x.bottom:b+a.wrapper.clientHeight,re=_e(y,b),le=_e(y,E);if(x&&x.ensure){var ue=x.ensure.from.line,de=x.ensure.to.line;ue<re?(re=ue,le=_e(y,yr(Dt(y,ue))+a.wrapper.clientHeight)):Math.min(de,y.lastLine())>=le&&(re=_e(y,yr(Dt(y,de))-a.wrapper.clientHeight),le=de)}return{from:re,to:Math.max(le,re+1)}}function Zs(a,y){if(!ft(a,"scrollCursorIntoView")){var x=a.display,b=x.sizer.getBoundingClientRect(),E=null;if(y.top+b.top<0?E=!0:y.bottom+b.top>(window.innerHeight||document.documentElement.clientHeight)&&(E=!1),E!=null&&!yt){var re=tt("div","\u200B",null,`position: absolute;
|
|
|
top: `+(y.top-x.viewOffset-ii(a.display))+`px;
|
|
|
height: `+(y.bottom-y.top+$i(a)+x.barHeight)+`px;
|
|
|
left: `+y.left+"px; width: "+Math.max(2,y.right-y.left)+"px;");a.display.lineSpace.appendChild(re),re.scrollIntoView(E),a.display.lineSpace.removeChild(re)}}}function js(a,y,x,b){b==null&&(b=0);var E;!a.options.lineWrapping&&y==x&&(y=y.ch?we(y.line,y.sticky=="before"?y.ch-1:y.ch,"after"):y,x=y.sticky=="before"?we(y.line,y.ch+1,"before"):y);for(var re=0;re<5;re++){var le=!1,ue=Bi(a,y),de=!x||x==y?ue:Bi(a,x);E={left:Math.min(ue.left,de.left),top:Math.min(ue.top,de.top)-b,right:Math.max(ue.left,de.left),bottom:Math.max(ue.bottom,de.bottom)+b};var pe=Ja(a,E),Ze=a.doc.scrollTop,Ye=a.doc.scrollLeft;if(pe.scrollTop!=null&&(qo(a,pe.scrollTop),Math.abs(a.doc.scrollTop-Ze)>1&&(le=!0)),pe.scrollLeft!=null&&(Eo(a,pe.scrollLeft),Math.abs(a.doc.scrollLeft-Ye)>1&&(le=!0)),!le)break}return E}function Ws(a,y){var x=Ja(a,y);x.scrollTop!=null&&qo(a,x.scrollTop),x.scrollLeft!=null&&Eo(a,x.scrollLeft)}function Ja(a,y){var x=a.display,b=Zi(a.display);y.top<0&&(y.top=0);var E=a.curOp&&a.curOp.scrollTop!=null?a.curOp.scrollTop:x.scroller.scrollTop,re=ao(a),le={};y.bottom-y.top>re&&(y.bottom=y.top+re);var ue=a.doc.height+_i(x),de=y.top<b,pe=y.bottom>ue-b;if(y.top<E)le.scrollTop=de?0:y.top;else if(y.bottom>E+re){var Ze=Math.min(y.top,(pe?ue:y.bottom)-re);Ze!=E&&(le.scrollTop=Ze)}var Ye=a.options.fixedGutter?0:x.gutters.offsetWidth,Lt=a.curOp&&a.curOp.scrollLeft!=null?a.curOp.scrollLeft:x.scroller.scrollLeft-Ye,Mt=ro(a)-x.gutters.offsetWidth,vn=y.right-y.left>Mt;return vn&&(y.right=y.left+Mt),y.left<10?le.scrollLeft=0:y.left<Lt?le.scrollLeft=Math.max(0,y.left+Ye-(vn?0:10)):y.right>Mt+Lt-3&&(le.scrollLeft=y.right+(vn?0:10)-Mt),le}function Qa(a,y){y!=null&&(Pa(a),a.curOp.scrollTop=(a.curOp.scrollTop==null?a.doc.scrollTop:a.curOp.scrollTop)+y)}function Ao(a){Pa(a);var y=a.getCursor();a.curOp.scrollToPos={from:y,to:y,margin:a.options.cursorScrollMargin}}function Qo(a,y,x){(y!=null||x!=null)&&Pa(a),y!=null&&(a.curOp.scrollLeft=y),x!=null&&(a.curOp.scrollTop=x)}function Gs(a,y){Pa(a),a.curOp.scrollToPos=y}function Pa(a){var y=a.curOp.scrollToPos;if(y){a.curOp.scrollToPos=null;var x=Zr(a,y.from),b=Zr(a,y.to);Pl(a,x,b,y.margin)}}function Pl(a,y,x,b){var E=Ja(a,{left:Math.min(y.left,x.left),top:Math.min(y.top,x.top)-b,right:Math.max(y.right,x.right),bottom:Math.max(y.bottom,x.bottom)+b});Qo(a,E.scrollLeft,E.scrollTop)}function qo(a,y){Math.abs(a.doc.scrollTop-y)<2||(z||el(a,{top:y}),Dl(a,y,!0),z&&el(a),na(a,100))}function Dl(a,y,x){y=Math.max(0,Math.min(a.display.scroller.scrollHeight-a.display.scroller.clientHeight,y)),!(a.display.scroller.scrollTop==y&&!x)&&(a.doc.scrollTop=y,a.display.scrollbars.setScrollTop(y),a.display.scroller.scrollTop!=y&&(a.display.scroller.scrollTop=y))}function Eo(a,y,x,b){y=Math.max(0,Math.min(y,a.display.scroller.scrollWidth-a.display.scroller.clientWidth)),!((x?y==a.doc.scrollLeft:Math.abs(a.doc.scrollLeft-y)<2)&&!b)&&(a.doc.scrollLeft=y,Al(a),a.display.scroller.scrollLeft!=y&&(a.display.scroller.scrollLeft=y),a.display.scrollbars.setScrollLeft(y))}function ea(a){var y=a.display,x=y.gutters.offsetWidth,b=Math.round(a.doc.height+_i(a.display));return{clientHeight:y.scroller.clientHeight,viewHeight:y.wrapper.clientHeight,scrollWidth:y.scroller.scrollWidth,clientWidth:y.scroller.clientWidth,viewWidth:y.wrapper.clientWidth,barLeft:a.options.fixedGutter?x:0,docHeight:b,scrollHeight:b+$i(a)+y.barHeight,nativeBarWidth:y.nativeBarWidth,gutterWidth:x}}var Io=function(a,y,x){this.cm=x;var b=this.vert=tt("div",[tt("div",null,null,"min-width: 1px")],"CodeMirror-vscrollbar"),E=this.horiz=tt("div",[tt("div",null,null,"height: 100%; min-height: 1px")],"CodeMirror-hscrollbar");b.tabIndex=E.tabIndex=-1,a(b),a(E),Nt(b,"scroll",function(){b.clientHeight&&y(b.scrollTop,"vertical")}),Nt(E,"scroll",function(){E.clientWidth&&y(E.scrollLeft,"horizontal")}),this.checkedZeroWidth=!1,ye&&be<8&&(this.horiz.style.minHeight=this.vert.style.minWidth="18px")};Io.prototype.update=function(a){var y=a.scrollWidth>a.clientWidth+1,x=a.scrollHeight>a.clientHeight+1,b=a.nativeBarWidth;if(x){this.vert.style.display="block",this.vert.style.bottom=y?b+"px":"0";var E=a.viewHeight-(y?b:0);this.vert.firstChild.style.height=Math.max(0,a.scrollHeight-a.clientHeight+E)+"px"}else this.vert.style.display="",this.vert.firstChild.style.height="0";if(y){this.horiz.style.display="block",this.horiz.style.right=x?b+"px":"0",this.horiz.style.left=a.barLeft+"px";var re=a.viewWidth-a.barLeft-(x?b:0);this.horiz.firstChild.style.width=Math.max(0,a.scrollWidth-a.clientWidth+re)+"px"}else this.horiz.style.display="",this.horiz.firstChild.style.width="0";return!this.checkedZeroWidth&&a.clientHeight>0&&(b==0&&this.zeroWidthHack(),this.checkedZeroWidth=!0),{right:x?b:0,bottom:y?b:0}},Io.prototype.setScrollLeft=function(a){this.horiz.scrollLeft!=a&&(this.horiz.scrollLeft=a),this.disableHoriz&&this.enableZeroWidthBar(this.horiz,this.disableHoriz,"horiz")},Io.prototype.setScrollTop=function(a){this.vert.scrollTop!=a&&(this.vert.scrollTop=a),this.disableVert&&this.enableZeroWidthBar(this.vert,this.disableVert,"vert")},Io.prototype.zeroWidthHack=function(){var a=Ne&&!Se?"12px":"18px";this.horiz.style.height=this.vert.style.width=a,this.horiz.style.pointerEvents=this.vert.style.pointerEvents="none",this.disableHoriz=new ce,this.disableVert=new ce},Io.prototype.enableZeroWidthBar=function(a,y,x){a.style.pointerEvents="auto";function b(){var E=a.getBoundingClientRect(),re=x=="vert"?document.elementFromPoint(E.right-1,(E.top+E.bottom)/2):document.elementFromPoint((E.right+E.left)/2,E.bottom-1);re!=a?a.style.pointerEvents="none":y.set(1e3,b)}y.set(1e3,b)},Io.prototype.clear=function(){var a=this.horiz.parentNode;a.removeChild(this.horiz),a.removeChild(this.vert)};var ta=function(){};ta.prototype.update=function(){return{bottom:0,right:0}},ta.prototype.setScrollLeft=function(){},ta.prototype.setScrollTop=function(){},ta.prototype.clear=function(){};function No(a,y){y||(y=ea(a));var x=a.display.barWidth,b=a.display.barHeight;kl(a,y);for(var E=0;E<4&&x!=a.display.barWidth||b!=a.display.barHeight;E++)x!=a.display.barWidth&&a.options.lineWrapping&&Oa(a),kl(a,ea(a)),x=a.display.barWidth,b=a.display.barHeight}function kl(a,y){var x=a.display,b=x.scrollbars.update(y);x.sizer.style.paddingRight=(x.barWidth=b.right)+"px",x.sizer.style.paddingBottom=(x.barHeight=b.bottom)+"px",x.heightForcer.style.borderBottom=b.bottom+"px solid transparent",b.right&&b.bottom?(x.scrollbarFiller.style.display="block",x.scrollbarFiller.style.height=b.bottom+"px",x.scrollbarFiller.style.width=b.right+"px"):x.scrollbarFiller.style.display="",b.bottom&&a.options.coverGutterNextToScrollbar&&a.options.fixedGutter?(x.gutterFiller.style.display="block",x.gutterFiller.style.height=b.bottom+"px",x.gutterFiller.style.width=y.gutterWidth+"px"):x.gutterFiller.style.display=""}var Tl={native:Io,null:ta};function Ll(a){a.display.scrollbars&&(a.display.scrollbars.clear(),a.display.scrollbars.addClass&&je(a.display.wrapper,a.display.scrollbars.addClass)),a.display.scrollbars=new Tl[a.options.scrollbarStyle](function(y){a.display.wrapper.insertBefore(y,a.display.scrollbarFiller),Nt(y,"mousedown",function(){a.state.focused&&setTimeout(function(){return a.display.input.focus()},0)}),y.setAttribute("cm-not-content","true")},function(y,x){x=="horizontal"?Eo(a,y):qo(a,y)},a),a.display.scrollbars.addClass&&me(a.display.wrapper,a.display.scrollbars.addClass)}var Vs=0;function Oo(a){a.curOp={cm:a,viewChanged:!1,startHeight:a.doc.height,forceUpdate:!1,updateInput:0,typing:!1,changeObjs:null,cursorActivityHandlers:null,cursorActivityCalled:0,selectionChanged:!1,updateMaxLine:!1,scrollLeft:null,scrollTop:null,scrollToPos:null,focus:!1,id:++Vs},Ci(a.curOp)}function Mo(a){var y=a.curOp;y&&hi(y,function(x){for(var b=0;b<x.ops.length;b++)x.ops[b].cm.curOp=null;Us(x)})}function Us(a){for(var y=a.ops,x=0;x<y.length;x++)_s(y[x]);for(var b=0;b<y.length;b++)Ks(y[b]);for(var E=0;E<y.length;E++)Xs(y[E]);for(var re=0;re<y.length;re++)Ys(y[re]);for(var le=0;le<y.length;le++)Js(y[le])}function _s(a){var y=a.cm,x=y.display;qs(y),a.updateMaxLine&&Cr(y),a.mustUpdate=a.viewChanged||a.forceUpdate||a.scrollTop!=null||a.scrollToPos&&(a.scrollToPos.from.line<x.viewFrom||a.scrollToPos.to.line>=x.viewTo)||x.maxLineChanged&&y.options.lineWrapping,a.update=a.mustUpdate&&new Da(y,a.mustUpdate&&{top:a.scrollTop,ensure:a.scrollToPos},a.forceUpdate)}function Ks(a){a.updatedDisplay=a.mustUpdate&&qa(a.cm,a.update)}function Xs(a){var y=a.cm,x=y.display;a.updatedDisplay&&Oa(y),a.barMeasure=ea(y),x.maxLineChanged&&!y.options.lineWrapping&&(a.adjustWidthTo=ya(y,x.maxLine,x.maxLine.text.length).left+3,y.display.sizerWidth=a.adjustWidthTo,a.barMeasure.scrollWidth=Math.max(x.scroller.clientWidth,x.sizer.offsetLeft+a.adjustWidthTo+$i(y)+y.display.barWidth),a.maxScrollLeft=Math.max(0,x.sizer.offsetLeft+a.adjustWidthTo-ro(y))),(a.updatedDisplay||a.selectionChanged)&&(a.preparedSelection=x.input.prepareSelection())}function Ys(a){var y=a.cm;a.adjustWidthTo!=null&&(y.display.sizer.style.minWidth=a.adjustWidthTo+"px",a.maxScrollLeft<y.doc.scrollLeft&&Eo(y,Math.min(y.display.scroller.scrollLeft,a.maxScrollLeft),!0),y.display.maxLineChanged=!1);var x=a.focus&&a.focus==lt();a.preparedSelection&&y.display.input.showSelection(a.preparedSelection,x),(a.updatedDisplay||a.startHeight!=y.doc.height)&&No(y,a.barMeasure),a.updatedDisplay&&nl(y,a.barMeasure),a.selectionChanged&&Xa(y),y.state.focused&&a.updateInput&&y.display.input.reset(a.typing),x&&Il(a.cm)}function Js(a){var y=a.cm,x=y.display,b=y.doc;if(a.updatedDisplay&&Bl(y,a.update),x.wheelStartX!=null&&(a.scrollTop!=null||a.scrollLeft!=null||a.scrollToPos)&&(x.wheelStartX=x.wheelStartY=null),a.scrollTop!=null&&Dl(y,a.scrollTop,a.forceScroll),a.scrollLeft!=null&&Eo(y,a.scrollLeft,!0,!0),a.scrollToPos){var E=js(y,Ct(b,a.scrollToPos.from),Ct(b,a.scrollToPos.to),a.scrollToPos.margin);Zs(y,E)}var re=a.maybeHiddenMarkers,le=a.maybeUnhiddenMarkers;if(re)for(var ue=0;ue<re.length;++ue)re[ue].lines.length||on(re[ue],"hide");if(le)for(var de=0;de<le.length;++de)le[de].lines.length&&on(le[de],"unhide");x.wrapper.offsetHeight&&(b.scrollTop=y.display.scroller.scrollTop),a.changeObjs&&on(y,"changes",y,a.changeObjs),a.update&&a.update.finish()}function ji(a,y){if(a.curOp)return y();Oo(a);try{return y()}finally{Mo(a)}}function gi(a,y){return function(){if(a.curOp)return y.apply(a,arguments);Oo(a);try{return y.apply(a,arguments)}finally{Mo(a)}}}function Ti(a){return function(){if(this.curOp)return a.apply(this,arguments);Oo(this);try{return a.apply(this,arguments)}finally{Mo(this)}}}function yi(a){return function(){var y=this.cm;if(!y||y.curOp)return a.apply(this,arguments);Oo(y);try{return a.apply(this,arguments)}finally{Mo(y)}}}function na(a,y){a.doc.highlightFrontier<a.display.viewTo&&a.state.highlight.set(y,He(Qs,a))}function Qs(a){var y=a.doc;if(!(y.highlightFrontier>=a.display.viewTo)){var x=+new Date+a.options.workTime,b=gt(a,y.highlightFrontier),E=[];y.iter(b.line,Math.min(y.first+y.size,a.display.viewTo+500),function(re){if(b.line>=a.display.viewFrom){var le=re.styles,ue=re.text.length>a.options.maxHighlightLength?Yn(y.mode,b.state):null,de=kn(a,re,b,!0);ue&&(b.state=ue),re.styles=de.styles;var pe=re.styleClasses,Ze=de.classes;Ze?re.styleClasses=Ze:pe&&(re.styleClasses=null);for(var Ye=!le||le.length!=re.styles.length||pe!=Ze&&(!pe||!Ze||pe.bgClass!=Ze.bgClass||pe.textClass!=Ze.textClass),Lt=0;!Ye&&Lt<le.length;++Lt)Ye=le[Lt]!=re.styles[Lt];Ye&&E.push(b.line),re.stateAfter=b.save(),b.nextLine()}else re.text.length<=a.options.maxHighlightLength&&Ve(a,re.text,b),re.stateAfter=b.line%5==0?b.save():null,b.nextLine();if(+new Date>x)return na(a,a.options.workDelay),!0}),y.highlightFrontier=b.line,y.modeFrontier=Math.max(y.modeFrontier,b.line),E.length&&ji(a,function(){for(var re=0;re<E.length;re++)ho(a,E[re],"text")})}}var Da=function(a,y,x){var b=a.display;this.viewport=y,this.visible=Ma(b,a.doc,y),this.editorIsHidden=!b.wrapper.offsetWidth,this.wrapperHeight=b.wrapper.clientHeight,this.wrapperWidth=b.wrapper.clientWidth,this.oldDisplayWidth=ro(a),this.force=x,this.dims=fo(a),this.events=[]};Da.prototype.signal=function(a,y){Tt(a,y)&&this.events.push(arguments)},Da.prototype.finish=function(){for(var a=0;a<this.events.length;a++)on.apply(null,this.events[a])};function qs(a){var y=a.display;!y.scrollbarsClipped&&y.scroller.offsetWidth&&(y.nativeBarWidth=y.scroller.offsetWidth-y.scroller.clientWidth,y.heightForcer.style.height=$i(a)+"px",y.sizer.style.marginBottom=-y.nativeBarWidth+"px",y.sizer.style.borderRightWidth=$i(a)+"px",y.scrollbarsClipped=!0)}function eu(a){if(a.hasFocus())return null;var y=lt();if(!y||!at(a.display.lineDiv,y))return null;var x={activeElt:y};if(window.getSelection){var b=window.getSelection();b.anchorNode&&b.extend&&at(a.display.lineDiv,b.anchorNode)&&(x.anchorNode=b.anchorNode,x.anchorOffset=b.anchorOffset,x.focusNode=b.focusNode,x.focusOffset=b.focusOffset)}return x}function tu(a){if(!(!a||!a.activeElt||a.activeElt==lt())&&(a.activeElt.focus(),!/^(INPUT|TEXTAREA)$/.test(a.activeElt.nodeName)&&a.anchorNode&&at(document.body,a.anchorNode)&&at(document.body,a.focusNode))){var y=window.getSelection(),x=document.createRange();x.setEnd(a.anchorNode,a.anchorOffset),x.collapse(!1),y.removeAllRanges(),y.addRange(x),y.extend(a.focusNode,a.focusOffset)}}function qa(a,y){var x=a.display,b=a.doc;if(y.editorIsHidden)return po(a),!1;if(!y.force&&y.visible.from>=x.viewFrom&&y.visible.to<=x.viewTo&&(x.updateLineNumbers==null||x.updateLineNumbers>=x.viewTo)&&x.renderedView==x.view&&wl(a)==0)return!1;Nl(a)&&(po(a),y.dims=fo(a));var E=b.first+b.size,re=Math.max(y.visible.from-a.options.viewportMargin,b.first),le=Math.min(E,y.visible.to+a.options.viewportMargin);x.viewFrom<re&&re-x.viewFrom<20&&(re=Math.max(b.first,x.viewFrom)),x.viewTo>le&&x.viewTo-le<20&&(le=Math.min(E,x.viewTo)),Pn&&(re=an(a.doc,re),le=dn(a.doc,le));var ue=re!=x.viewFrom||le!=x.viewTo||x.lastWrapHeight!=y.wrapperHeight||x.lastWrapWidth!=y.wrapperWidth;$s(a,re,le),x.viewOffset=yr(Dt(a.doc,x.viewFrom)),a.display.mover.style.top=x.viewOffset+"px";var de=wl(a);if(!ue&&de==0&&!y.force&&x.renderedView==x.view&&(x.updateLineNumbers==null||x.updateLineNumbers>=x.viewTo))return!1;var pe=eu(a);return de>4&&(x.lineDiv.style.display="none"),nu(a,x.updateLineNumbers,y.dims),de>4&&(x.lineDiv.style.display=""),x.renderedView=x.view,tu(pe),Ot(x.cursorDiv),Ot(x.selectionDiv),x.gutters.style.height=x.sizer.style.minHeight=0,ue&&(x.lastWrapHeight=y.wrapperHeight,x.lastWrapWidth=y.wrapperWidth,na(a,400)),x.updateLineNumbers=null,!0}function Bl(a,y){for(var x=y.viewport,b=!0;;b=!1){if(!b||!a.options.lineWrapping||y.oldDisplayWidth==ro(a)){if(x&&x.top!=null&&(x={top:Math.min(a.doc.height+_i(a.display)-ao(a),x.top)}),y.visible=Ma(a.display,a.doc,x),y.visible.from>=a.display.viewFrom&&y.visible.to<=a.display.viewTo)break}else b&&(y.visible=Ma(a.display,a.doc,x));if(!qa(a,y))break;Oa(a);var E=ea(a);Jo(a),No(a,E),nl(a,E),y.force=!1}y.signal(a,"update",a),(a.display.viewFrom!=a.display.reportedViewFrom||a.display.viewTo!=a.display.reportedViewTo)&&(y.signal(a,"viewportChange",a,a.display.viewFrom,a.display.viewTo),a.display.reportedViewFrom=a.display.viewFrom,a.display.reportedViewTo=a.display.viewTo)}function el(a,y){var x=new Da(a,y);if(qa(a,x)){Oa(a),Bl(a,x);var b=ea(a);Jo(a),No(a,b),nl(a,b),x.finish()}}function nu(a,y,x){var b=a.display,E=a.options.lineNumbers,re=b.lineDiv,le=re.firstChild;function ue(vn){var Mn=vn.nextSibling;return Me&&Ne&&a.display.currentWheelTarget==vn?vn.style.display="none":vn.parentNode.removeChild(vn),Mn}for(var de=b.view,pe=b.viewFrom,Ze=0;Ze<de.length;Ze++){var Ye=de[Ze];if(!Ye.hidden)if(!Ye.node||Ye.node.parentNode!=re){var Lt=Pr(a,Ye,pe,x);re.insertBefore(Lt,le)}else{for(;le!=Ye.node;)le=ue(le);var Mt=E&&y!=null&&y<=pe&&Ye.lineNumber;Ye.changes&&(Je(Ye.changes,"gutter")>-1&&(Mt=!1),Oi(a,Ye,pe,x)),Mt&&(Ot(Ye.lineNumber),Ye.lineNumber.appendChild(document.createTextNode(Be(a.options,pe)))),le=Ye.node.nextSibling}pe+=Ye.size}for(;le;)le=ue(le)}function tl(a){var y=a.gutters.offsetWidth;a.sizer.style.marginLeft=y+"px"}function nl(a,y){a.display.sizer.style.minHeight=y.docHeight+"px",a.display.heightForcer.style.top=y.docHeight+"px",a.display.gutters.style.height=y.docHeight+a.display.barHeight+$i(a)+"px"}function Al(a){var y=a.display,x=y.view;if(!(!y.alignWidgets&&(!y.gutters.firstChild||!a.options.fixedGutter))){for(var b=_a(y)-y.scroller.scrollLeft+a.doc.scrollLeft,E=y.gutters.offsetWidth,re=b+"px",le=0;le<x.length;le++)if(!x[le].hidden){a.options.fixedGutter&&(x[le].gutter&&(x[le].gutter.style.left=re),x[le].gutterBackground&&(x[le].gutterBackground.style.left=re));var ue=x[le].alignable;if(ue)for(var de=0;de<ue.length;de++)ue[de].style.left=re}a.options.fixedGutter&&(y.gutters.style.left=b+E+"px")}}function Nl(a){if(!a.options.lineNumbers)return!1;var y=a.doc,x=Be(a.options,y.first+y.size-1),b=a.display;if(x.length!=b.lineNumChars){var E=b.measure.appendChild(tt("div",[tt("div",x)],"CodeMirror-linenumber CodeMirror-gutter-elt")),re=E.firstChild.offsetWidth,le=E.offsetWidth-re;return b.lineGutter.style.width="",b.lineNumInnerWidth=Math.max(re,b.lineGutter.offsetWidth-le)+1,b.lineNumWidth=b.lineNumInnerWidth+le,b.lineNumChars=b.lineNumInnerWidth?x.length:-1,b.lineGutter.style.width=b.lineNumWidth+"px",tl(a.display),!0}return!1}function rl(a,y){for(var x=[],b=!1,E=0;E<a.length;E++){var re=a[E],le=null;if(typeof re!="string"&&(le=re.style,re=re.className),re=="CodeMirror-linenumbers")if(y)b=!0;else continue;x.push({className:re,style:le})}return y&&!b&&x.push({className:"CodeMirror-linenumbers",style:null}),x}function Rl(a){var y=a.gutters,x=a.gutterSpecs;Ot(y),a.lineGutter=null;for(var b=0;b<x.length;++b){var E=x[b],re=E.className,le=E.style,ue=y.appendChild(tt("div",null,"CodeMirror-gutter "+re));le&&(ue.style.cssText=le),re=="CodeMirror-linenumbers"&&(a.lineGutter=ue,ue.style.width=(a.lineNumWidth||1)+"px")}y.style.display=x.length?"":"none",tl(a)}function ra(a){Rl(a.display),Ai(a),Al(a)}function ru(a,y,x,b){var E=this;this.input=x,E.scrollbarFiller=tt("div",null,"CodeMirror-scrollbar-filler"),E.scrollbarFiller.setAttribute("cm-not-content","true"),E.gutterFiller=tt("div",null,"CodeMirror-gutter-filler"),E.gutterFiller.setAttribute("cm-not-content","true"),E.lineDiv=ht("div",null,"CodeMirror-code"),E.selectionDiv=tt("div",null,null,"position: relative; z-index: 1"),E.cursorDiv=tt("div",null,"CodeMirror-cursors"),E.measure=tt("div",null,"CodeMirror-measure"),E.lineMeasure=tt("div",null,"CodeMirror-measure"),E.lineSpace=ht("div",[E.measure,E.lineMeasure,E.selectionDiv,E.cursorDiv,E.lineDiv],null,"position: relative; outline: none");var re=ht("div",[E.lineSpace],"CodeMirror-lines");E.mover=tt("div",[re],null,"position: relative"),E.sizer=tt("div",[E.mover],"CodeMirror-sizer"),E.sizerWidth=null,E.heightForcer=tt("div",null,null,"position: absolute; height: "+jt+"px; width: 1px;"),E.gutters=tt("div",null,"CodeMirror-gutters"),E.lineGutter=null,E.scroller=tt("div",[E.sizer,E.heightForcer,E.gutters],"CodeMirror-scroll"),E.scroller.setAttribute("tabIndex","-1"),E.wrapper=tt("div",[E.scrollbarFiller,E.gutterFiller,E.scroller],"CodeMirror"),ye&&be<8&&(E.gutters.style.zIndex=-1,E.scroller.style.paddingRight=0),!Me&&!(z&&Ge)&&(E.scroller.draggable=!0),a&&(a.appendChild?a.appendChild(E.wrapper):a(E.wrapper)),E.viewFrom=E.viewTo=y.first,E.reportedViewFrom=E.reportedViewTo=y.first,E.view=[],E.renderedView=null,E.externalMeasured=null,E.viewOffset=0,E.lastWrapHeight=E.lastWrapWidth=0,E.updateLineNumbers=null,E.nativeBarWidth=E.barHeight=E.barWidth=0,E.scrollbarsClipped=!1,E.lineNumWidth=E.lineNumInnerWidth=E.lineNumChars=null,E.alignWidgets=!1,E.cachedCharWidth=E.cachedTextHeight=E.cachedPaddingH=null,E.maxLine=null,E.maxLineLength=0,E.maxLineChanged=!1,E.wheelDX=E.wheelDY=E.wheelStartX=E.wheelStartY=null,E.shift=!1,E.selForContextMenu=null,E.activeTouch=null,E.gutterSpecs=rl(b.gutters,b.lineNumbers),Rl(E),x.init(E)}var ka=0,Gi=null;ye?Gi=-.53:z?Gi=15:Oe?Gi=-.7:We&&(Gi=-1/3);function Fl(a){var y=a.wheelDeltaX,x=a.wheelDeltaY;return y==null&&a.detail&&a.axis==a.HORIZONTAL_AXIS&&(y=a.detail),x==null&&a.detail&&a.axis==a.VERTICAL_AXIS?x=a.detail:x==null&&(x=a.wheelDelta),{x:y,y:x}}function iu(a){var y=Fl(a);return y.x*=Gi,y.y*=Gi,y}function zl(a,y){var x=Fl(y),b=x.x,E=x.y,re=a.display,le=re.scroller,ue=le.scrollWidth>le.clientWidth,de=le.scrollHeight>le.clientHeight;if(b&&ue||E&&de){if(E&&Ne&&Me){e:for(var pe=y.target,Ze=re.view;pe!=le;pe=pe.parentNode)for(var Ye=0;Ye<Ze.length;Ye++)if(Ze[Ye].node==pe){a.display.currentWheelTarget=pe;break e}}if(b&&!z&&!fe&&Gi!=null){E&&de&&qo(a,Math.max(0,le.scrollTop+E*Gi)),Eo(a,Math.max(0,le.scrollLeft+b*Gi)),(!E||E&&de)&&yn(y),re.wheelStartX=null;return}if(E&&Gi!=null){var Lt=E*Gi,Mt=a.doc.scrollTop,vn=Mt+re.wrapper.clientHeight;Lt<0?Mt=Math.max(0,Mt+Lt-50):vn=Math.min(a.doc.height,vn+Lt+50),el(a,{top:Mt,bottom:vn})}ka<20&&(re.wheelStartX==null?(re.wheelStartX=le.scrollLeft,re.wheelStartY=le.scrollTop,re.wheelDX=b,re.wheelDY=E,setTimeout(function(){if(re.wheelStartX!=null){var Mn=le.scrollLeft-re.wheelStartX,Vn=le.scrollTop-re.wheelStartY,tr=Vn&&re.wheelDY&&Vn/re.wheelDY||Mn&&re.wheelDX&&Mn/re.wheelDX;re.wheelStartX=re.wheelStartY=null,tr&&(Gi=(Gi*ka+tr)/(ka+1),++ka)}},200)):(re.wheelDX+=b,re.wheelDY+=E))}}var Vi=function(a,y){this.ranges=a,this.primIndex=y};Vi.prototype.primary=function(){return this.ranges[this.primIndex]},Vi.prototype.equals=function(a){if(a==this)return!0;if(a.primIndex!=this.primIndex||a.ranges.length!=this.ranges.length)return!1;for(var y=0;y<this.ranges.length;y++){var x=this.ranges[y],b=a.ranges[y];if(!Qe(x.anchor,b.anchor)||!Qe(x.head,b.head))return!1}return!0},Vi.prototype.deepCopy=function(){for(var a=[],y=0;y<this.ranges.length;y++)a[y]=new Vr(nn(this.ranges[y].anchor),nn(this.ranges[y].head));return new Vi(a,this.primIndex)},Vi.prototype.somethingSelected=function(){for(var a=0;a<this.ranges.length;a++)if(!this.ranges[a].empty())return!0;return!1},Vi.prototype.contains=function(a,y){y||(y=a);for(var x=0;x<this.ranges.length;x++){var b=this.ranges[x];if(Te(y,b.from())>=0&&Te(a,b.to())<=0)return x}return-1};var Vr=function(a,y){this.anchor=a,this.head=y};Vr.prototype.from=function(){return Xt(this.anchor,this.head)},Vr.prototype.to=function(){return sn(this.anchor,this.head)},Vr.prototype.empty=function(){return this.head.line==this.anchor.line&&this.head.ch==this.anchor.ch};function qi(a,y,x){var b=a&&a.options.selectionsMayTouch,E=y[x];y.sort(function(Lt,Mt){return Te(Lt.from(),Mt.from())}),x=Je(y,E);for(var re=1;re<y.length;re++){var le=y[re],ue=y[re-1],de=Te(ue.to(),le.from());if(b&&!le.empty()?de>0:de>=0){var pe=Xt(ue.from(),le.from()),Ze=sn(ue.to(),le.to()),Ye=ue.empty()?le.from()==le.head:ue.from()==ue.head;re<=x&&--x,y.splice(--re,2,new Vr(Ye?Ze:pe,Ye?pe:Ze))}}return new Vi(y,x)}function mo(a,y){return new Vi([new Vr(a,y||a)],0)}function vo(a){return a.text?we(a.from.line+a.text.length-1,ze(a.text).length+(a.text.length==1?a.from.ch:0)):a.to}function $l(a,y){if(Te(a,y.from)<0)return a;if(Te(a,y.to)<=0)return vo(y);var x=a.line+y.text.length-(y.to.line-y.from.line)-1,b=a.ch;return a.line==y.to.line&&(b+=vo(y).ch-y.to.ch),we(x,b)}function il(a,y){for(var x=[],b=0;b<a.sel.ranges.length;b++){var E=a.sel.ranges[b];x.push(new Vr($l(E.anchor,y),$l(E.head,y)))}return qi(a.cm,x,a.sel.primIndex)}function Hl(a,y,x){return a.line==y.line?we(x.line,a.ch-y.ch+x.ch):we(x.line+(a.line-y.line),a.ch)}function ou(a,y,x){for(var b=[],E=we(a.first,0),re=E,le=0;le<y.length;le++){var ue=y[le],de=Hl(ue.from,E,re),pe=Hl(vo(ue),E,re);if(E=ue.to,re=pe,x=="around"){var Ze=a.sel.ranges[le],Ye=Te(Ze.head,Ze.anchor)<0;b[le]=new Vr(Ye?pe:de,Ye?de:pe)}else b[le]=new Vr(de,de)}return new Vi(b,a.sel.primIndex)}function ol(a){a.doc.mode=wn(a.options,a.doc.modeOption),ia(a)}function ia(a){a.doc.iter(function(y){y.stateAfter&&(y.stateAfter=null),y.styles&&(y.styles=null)}),a.doc.modeFrontier=a.doc.highlightFrontier=a.doc.first,na(a,100),a.state.modeGen++,a.curOp&&Ai(a)}function Zl(a,y){return y.from.ch==0&&y.to.ch==0&&ze(y.text)==""&&(!a.cm||a.cm.options.wholeLineUpdateBefore)}function al(a,y,x,b){function E(ur){return x?x[ur]:null}function re(ur,nr,gr){Tr(ur,nr,gr,b),_r(ur,"change",ur,y)}function le(ur,nr){for(var gr=[],Ir=ur;Ir<nr;++Ir)gr.push(new Ar(pe[Ir],E(Ir),b));return gr}var ue=y.from,de=y.to,pe=y.text,Ze=Dt(a,ue.line),Ye=Dt(a,de.line),Lt=ze(pe),Mt=E(pe.length-1),vn=de.line-ue.line;if(y.full)a.insert(0,le(0,pe.length)),a.remove(pe.length,a.size-pe.length);else if(Zl(a,y)){var Mn=le(0,pe.length-1);re(Ye,Ye.text,Mt),vn&&a.remove(ue.line,vn),Mn.length&&a.insert(ue.line,Mn)}else if(Ze==Ye)if(pe.length==1)re(Ze,Ze.text.slice(0,ue.ch)+Lt+Ze.text.slice(de.ch),Mt);else{var Vn=le(1,pe.length-1);Vn.push(new Ar(Lt+Ze.text.slice(de.ch),Mt,b)),re(Ze,Ze.text.slice(0,ue.ch)+pe[0],E(0)),a.insert(ue.line+1,Vn)}else if(pe.length==1)re(Ze,Ze.text.slice(0,ue.ch)+pe[0]+Ye.text.slice(de.ch),E(0)),a.remove(ue.line+1,vn);else{re(Ze,Ze.text.slice(0,ue.ch)+pe[0],E(0)),re(Ye,Lt+Ye.text.slice(de.ch),Mt);var tr=le(1,pe.length-1);vn>1&&a.remove(ue.line+1,vn-1),a.insert(ue.line+1,tr)}_r(a,"change",a,y)}function go(a,y,x){function b(E,re,le){if(E.linked)for(var ue=0;ue<E.linked.length;++ue){var de=E.linked[ue];if(de.doc!=re){var pe=le&&de.sharedHist;x&&!pe||(y(de.doc,pe),b(de.doc,E,pe))}}}b(a,null,!0)}function jl(a,y){if(y.cm)throw new Error("This document is already in use.");a.doc=y,y.cm=a,Ka(a),ol(a),Wl(a),a.options.lineWrapping||Cr(a),a.options.mode=y.modeOption,Ai(a)}function Wl(a){(a.doc.direction=="rtl"?me:je)(a.display.lineDiv,"CodeMirror-rtl")}function au(a){ji(a,function(){Wl(a),Ai(a)})}function Ta(a){this.done=[],this.undone=[],this.undoDepth=1/0,this.lastModTime=this.lastSelTime=0,this.lastOp=this.lastSelOp=null,this.lastOrigin=this.lastSelOrigin=null,this.generation=this.maxGeneration=a||1}function ll(a,y){var x={from:nn(y.from),to:vo(y),text:Qt(a,y.from,y.to)};return Ul(a,x,y.from.line,y.to.line+1),go(a,function(b){return Ul(b,x,y.from.line,y.to.line+1)},!0),x}function Gl(a){for(;a.length;){var y=ze(a);if(y.ranges)a.pop();else break}}function lu(a,y){if(y)return Gl(a.done),ze(a.done);if(a.done.length&&!ze(a.done).ranges)return ze(a.done);if(a.done.length>1&&!a.done[a.done.length-2].ranges)return a.done.pop(),ze(a.done)}function Vl(a,y,x,b){var E=a.history;E.undone.length=0;var re=+new Date,le,ue;if((E.lastOp==b||E.lastOrigin==y.origin&&y.origin&&(y.origin.charAt(0)=="+"&&E.lastModTime>re-(a.cm?a.cm.options.historyEventDelay:500)||y.origin.charAt(0)=="*"))&&(le=lu(E,E.lastOp==b)))ue=ze(le.changes),Te(y.from,y.to)==0&&Te(y.from,ue.to)==0?ue.to=vo(y):le.changes.push(ll(a,y));else{var de=ze(E.done);for((!de||!de.ranges)&&La(a.sel,E.done),le={changes:[ll(a,y)],generation:E.generation},E.done.push(le);E.done.length>E.undoDepth;)E.done.shift(),E.done[0].ranges||E.done.shift()}E.done.push(x),E.generation=++E.maxGeneration,E.lastModTime=E.lastSelTime=re,E.lastOp=E.lastSelOp=b,E.lastOrigin=E.lastSelOrigin=y.origin,ue||on(a,"historyAdded")}function su(a,y,x,b){var E=y.charAt(0);return E=="*"||E=="+"&&x.ranges.length==b.ranges.length&&x.somethingSelected()==b.somethingSelected()&&new Date-a.history.lastSelTime<=(a.cm?a.cm.options.historyEventDelay:500)}function uu(a,y,x,b){var E=a.history,re=b&&b.origin;x==E.lastSelOp||re&&E.lastSelOrigin==re&&(E.lastModTime==E.lastSelTime&&E.lastOrigin==re||su(a,re,ze(E.done),y))?E.done[E.done.length-1]=y:La(y,E.done),E.lastSelTime=+new Date,E.lastSelOrigin=re,E.lastSelOp=x,b&&b.clearRedo!==!1&&Gl(E.undone)}function La(a,y){var x=ze(y);x&&x.ranges&&x.equals(a)||y.push(a)}function Ul(a,y,x,b){var E=y["spans_"+a.id],re=0;a.iter(Math.max(a.first,x),Math.min(a.first+a.size,b),function(le){le.markedSpans&&((E||(E=y["spans_"+a.id]={}))[re]=le.markedSpans),++re})}function cu(a){if(!a)return null;for(var y,x=0;x<a.length;++x)a[x].marker.explicitlyCleared?y||(y=a.slice(0,x)):y&&y.push(a[x]);return y?y.length?y:null:a}function du(a,y){var x=y["spans_"+a.id];if(!x)return null;for(var b=[],E=0;E<y.text.length;++E)b.push(cu(x[E]));return b}function _l(a,y){var x=du(a,y),b=vr(a,y);if(!x)return b;if(!b)return x;for(var E=0;E<x.length;++E){var re=x[E],le=b[E];if(re&&le)e:for(var ue=0;ue<le.length;++ue){for(var de=le[ue],pe=0;pe<re.length;++pe)if(re[pe].marker==de.marker)continue e;re.push(de)}else le&&(x[E]=le)}return x}function Ro(a,y,x){for(var b=[],E=0;E<a.length;++E){var re=a[E];if(re.ranges){b.push(x?Vi.prototype.deepCopy.call(re):re);continue}var le=re.changes,ue=[];b.push({changes:ue});for(var de=0;de<le.length;++de){var pe=le[de],Ze=void 0;if(ue.push({from:pe.from,to:pe.to,text:pe.text}),y)for(var Ye in pe)(Ze=Ye.match(/^spans_(\d+)$/))&&Je(y,Number(Ze[1]))>-1&&(ze(ue)[Ye]=pe[Ye],delete pe[Ye])}}return b}function sl(a,y,x,b){if(b){var E=a.anchor;if(x){var re=Te(y,E)<0;re!=Te(x,E)<0?(E=y,y=x):re!=Te(y,x)<0&&(y=x)}return new Vr(E,y)}else return new Vr(x||y,y)}function Ba(a,y,x,b,E){E==null&&(E=a.cm&&(a.cm.display.shift||a.extend)),Pi(a,new Vi([sl(a.sel.primary(),y,x,E)],0),b)}function Kl(a,y,x){for(var b=[],E=a.cm&&(a.cm.display.shift||a.extend),re=0;re<a.sel.ranges.length;re++)b[re]=sl(a.sel.ranges[re],y[re],null,E);var le=qi(a.cm,b,a.sel.primIndex);Pi(a,le,x)}function ul(a,y,x,b){var E=a.sel.ranges.slice(0);E[y]=x,Pi(a,qi(a.cm,E,a.sel.primIndex),b)}function Xl(a,y,x,b){Pi(a,mo(y,x),b)}function fu(a,y,x){var b={ranges:y.ranges,update:function(E){this.ranges=[];for(var re=0;re<E.length;re++)this.ranges[re]=new Vr(Ct(a,E[re].anchor),Ct(a,E[re].head))},origin:x&&x.origin};return on(a,"beforeSelectionChange",a,b),a.cm&&on(a.cm,"beforeSelectionChange",a.cm,b),b.ranges!=y.ranges?qi(a.cm,b.ranges,b.ranges.length-1):y}function Yl(a,y,x){var b=a.history.done,E=ze(b);E&&E.ranges?(b[b.length-1]=y,Aa(a,y,x)):Pi(a,y,x)}function Pi(a,y,x){Aa(a,y,x),uu(a,a.sel,a.cm?a.cm.curOp.id:NaN,x)}function Aa(a,y,x){(Tt(a,"beforeSelectionChange")||a.cm&&Tt(a.cm,"beforeSelectionChange"))&&(y=fu(a,y,x));var b=x&&x.bias||(Te(y.primary().head,a.sel.primary().head)<0?-1:1);Jl(a,ql(a,y,b,!0)),!(x&&x.scroll===!1)&&a.cm&&Ao(a.cm)}function Jl(a,y){y.equals(a.sel)||(a.sel=y,a.cm&&(a.cm.curOp.updateInput=1,a.cm.curOp.selectionChanged=!0,Gt(a.cm)),_r(a,"cursorActivity",a))}function Ql(a){Jl(a,ql(a,a.sel,null,!1))}function ql(a,y,x,b){for(var E,re=0;re<y.ranges.length;re++){var le=y.ranges[re],ue=y.ranges.length==a.sel.ranges.length&&a.sel.ranges[re],de=Na(a,le.anchor,ue&&ue.anchor,x,b),pe=Na(a,le.head,ue&&ue.head,x,b);(E||de!=le.anchor||pe!=le.head)&&(E||(E=y.ranges.slice(0,re)),E[re]=new Vr(de,pe))}return E?qi(a.cm,E,y.primIndex):y}function Fo(a,y,x,b,E){var re=Dt(a,y.line);if(re.markedSpans)for(var le=0;le<re.markedSpans.length;++le){var ue=re.markedSpans[le],de=ue.marker,pe="selectLeft"in de?!de.selectLeft:de.inclusiveLeft,Ze="selectRight"in de?!de.selectRight:de.inclusiveRight;if((ue.from==null||(pe?ue.from<=y.ch:ue.from<y.ch))&&(ue.to==null||(Ze?ue.to>=y.ch:ue.to>y.ch))){if(E&&(on(de,"beforeCursorEnter"),de.explicitlyCleared))if(re.markedSpans){--le;continue}else break;if(!de.atomic)continue;if(x){var Ye=de.find(b<0?1:-1),Lt=void 0;if((b<0?Ze:pe)&&(Ye=es(a,Ye,-b,Ye&&Ye.line==y.line?re:null)),Ye&&Ye.line==y.line&&(Lt=Te(Ye,x))&&(b<0?Lt<0:Lt>0))return Fo(a,Ye,y,b,E)}var Mt=de.find(b<0?-1:1);return(b<0?pe:Ze)&&(Mt=es(a,Mt,b,Mt.line==y.line?re:null)),Mt?Fo(a,Mt,y,b,E):null}}return y}function Na(a,y,x,b,E){var re=b||1,le=Fo(a,y,x,re,E)||!E&&Fo(a,y,x,re,!0)||Fo(a,y,x,-re,E)||!E&&Fo(a,y,x,-re,!0);return le||(a.cantEdit=!0,we(a.first,0))}function es(a,y,x,b){return x<0&&y.ch==0?y.line>a.first?Ct(a,we(y.line-1)):null:x>0&&y.ch==(b||Dt(a,y.line)).text.length?y.line<a.first+a.size-1?we(y.line+1,0):null:new we(y.line,y.ch+x)}function ts(a){a.setSelection(we(a.firstLine(),0),we(a.lastLine()),Ie)}function ns(a,y,x){var b={canceled:!1,from:y.from,to:y.to,text:y.text,origin:y.origin,cancel:function(){return b.canceled=!0}};return x&&(b.update=function(E,re,le,ue){E&&(b.from=Ct(a,E)),re&&(b.to=Ct(a,re)),le&&(b.text=le),ue!==void 0&&(b.origin=ue)}),on(a,"beforeChange",a,b),a.cm&&on(a.cm,"beforeChange",a.cm,b),b.canceled?(a.cm&&(a.cm.curOp.updateInput=2),null):{from:b.from,to:b.to,text:b.text,origin:b.origin}}function zo(a,y,x){if(a.cm){if(!a.cm.curOp)return gi(a.cm,zo)(a,y,x);if(a.cm.state.suppressEdits)return}if(!((Tt(a,"beforeChange")||a.cm&&Tt(a.cm,"beforeChange"))&&(y=ns(a,y,!0),!y))){var b=jn&&!x&&Sr(a,y.from,y.to);if(b)for(var E=b.length-1;E>=0;--E)rs(a,{from:b[E].from,to:b[E].to,text:E?[""]:y.text,origin:y.origin});else rs(a,y)}}function rs(a,y){if(!(y.text.length==1&&y.text[0]==""&&Te(y.from,y.to)==0)){var x=il(a,y);Vl(a,y,x,a.cm?a.cm.curOp.id:NaN),oa(a,y,x,vr(a,y));var b=[];go(a,function(E,re){!re&&Je(b,E.history)==-1&&(ls(E.history,y),b.push(E.history)),oa(E,y,null,vr(E,y))})}}function Ra(a,y,x){var b=a.cm&&a.cm.state.suppressEdits;if(!(b&&!x)){for(var E=a.history,re,le=a.sel,ue=y=="undo"?E.done:E.undone,de=y=="undo"?E.undone:E.done,pe=0;pe<ue.length&&(re=ue[pe],!(x?re.ranges&&!re.equals(a.sel):!re.ranges));pe++);if(pe!=ue.length){for(E.lastOrigin=E.lastSelOrigin=null;;)if(re=ue.pop(),re.ranges){if(La(re,de),x&&!re.equals(a.sel)){Pi(a,re,{clearRedo:!1});return}le=re}else if(b){ue.push(re);return}else break;var Ze=[];La(le,de),de.push({changes:Ze,generation:E.generation}),E.generation=re.generation||++E.maxGeneration;for(var Ye=Tt(a,"beforeChange")||a.cm&&Tt(a.cm,"beforeChange"),Lt=function(Mn){var Vn=re.changes[Mn];if(Vn.origin=y,Ye&&!ns(a,Vn,!1))return ue.length=0,{};Ze.push(ll(a,Vn));var tr=Mn?il(a,Vn):ze(ue);oa(a,Vn,tr,_l(a,Vn)),!Mn&&a.cm&&a.cm.scrollIntoView({from:Vn.from,to:vo(Vn)});var ur=[];go(a,function(nr,gr){!gr&&Je(ur,nr.history)==-1&&(ls(nr.history,Vn),ur.push(nr.history)),oa(nr,Vn,null,_l(nr,Vn))})},Mt=re.changes.length-1;Mt>=0;--Mt){var vn=Lt(Mt);if(vn)return vn.v}}}}function is(a,y){if(y!=0&&(a.first+=y,a.sel=new Vi(zt(a.sel.ranges,function(E){return new Vr(we(E.anchor.line+y,E.anchor.ch),we(E.head.line+y,E.head.ch))}),a.sel.primIndex),a.cm)){Ai(a.cm,a.first,a.first-y,y);for(var x=a.cm.display,b=x.viewFrom;b<x.viewTo;b++)ho(a.cm,b,"gutter")}}function oa(a,y,x,b){if(a.cm&&!a.cm.curOp)return gi(a.cm,oa)(a,y,x,b);if(y.to.line<a.first){is(a,y.text.length-1-(y.to.line-y.from.line));return}if(!(y.from.line>a.lastLine())){if(y.from.line<a.first){var E=y.text.length-1-(a.first-y.from.line);is(a,E),y={from:we(a.first,0),to:we(y.to.line+E,y.to.ch),text:[ze(y.text)],origin:y.origin}}var re=a.lastLine();y.to.line>re&&(y={from:y.from,to:we(re,Dt(a,re).text.length),text:[y.text[0]],origin:y.origin}),y.removed=Qt(a,y.from,y.to),x||(x=il(a,y)),a.cm?hu(a.cm,y,b):al(a,y,b),Aa(a,x,Ie),a.cantEdit&&Na(a,we(a.firstLine(),0))&&(a.cantEdit=!1)}}function hu(a,y,x){var b=a.doc,E=a.display,re=y.from,le=y.to,ue=!1,de=re.line;a.options.lineWrapping||(de=ke(Jt(Dt(b,re.line))),b.iter(de,le.line+1,function(Mt){if(Mt==E.maxLine)return ue=!0,!0})),b.sel.contains(y.from,y.to)>-1&&Gt(a),al(b,y,x,Cl(a)),a.options.lineWrapping||(b.iter(de,re.line+y.text.length,function(Mt){var vn=Mr(Mt);vn>E.maxLineLength&&(E.maxLine=Mt,E.maxLineLength=vn,E.maxLineChanged=!0,ue=!1)}),ue&&(a.curOp.updateMaxLine=!0)),An(b,re.line),na(a,400);var pe=y.text.length-(le.line-re.line)-1;y.full?Ai(a):re.line==le.line&&y.text.length==1&&!Zl(a.doc,y)?ho(a,re.line,"text"):Ai(a,re.line,le.line+1,pe);var Ze=Tt(a,"changes"),Ye=Tt(a,"change");if(Ye||Ze){var Lt={from:re,to:le,text:y.text,removed:y.removed,origin:y.origin};Ye&&_r(a,"change",a,Lt),Ze&&(a.curOp.changeObjs||(a.curOp.changeObjs=[])).push(Lt)}a.display.selForContextMenu=null}function $o(a,y,x,b,E){var re;b||(b=x),Te(b,x)<0&&(re=[b,x],x=re[0],b=re[1]),typeof y=="string"&&(y=a.splitLines(y)),zo(a,{from:x,to:b,text:y,origin:E})}function os(a,y,x,b){x<a.line?a.line+=b:y<a.line&&(a.line=y,a.ch=0)}function as(a,y,x,b){for(var E=0;E<a.length;++E){var re=a[E],le=!0;if(re.ranges){re.copied||(re=a[E]=re.deepCopy(),re.copied=!0);for(var ue=0;ue<re.ranges.length;ue++)os(re.ranges[ue].anchor,y,x,b),os(re.ranges[ue].head,y,x,b);continue}for(var de=0;de<re.changes.length;++de){var pe=re.changes[de];if(x<pe.from.line)pe.from=we(pe.from.line+b,pe.from.ch),pe.to=we(pe.to.line+b,pe.to.ch);else if(y<=pe.to.line){le=!1;break}}le||(a.splice(0,E+1),E=0)}}function ls(a,y){var x=y.from.line,b=y.to.line,E=y.text.length-(b-x)-1;as(a.done,x,b,E),as(a.undone,x,b,E)}function aa(a,y,x,b){var E=y,re=y;return typeof y=="number"?re=Dt(a,Ht(a,y)):E=ke(y),E==null?null:(b(re,E)&&a.cm&&ho(a.cm,E,x),re)}function la(a){this.lines=a,this.parent=null;for(var y=0,x=0;x<a.length;++x)a[x].parent=this,y+=a[x].height;this.height=y}la.prototype={chunkSize:function(){return this.lines.length},removeInner:function(a,y){for(var x=a,b=a+y;x<b;++x){var E=this.lines[x];this.height-=E.height,Lr(E),_r(E,"delete")}this.lines.splice(a,y)},collapse:function(a){a.push.apply(a,this.lines)},insertInner:function(a,y,x){this.height+=x,this.lines=this.lines.slice(0,a).concat(y).concat(this.lines.slice(a));for(var b=0;b<y.length;++b)y[b].parent=this},iterN:function(a,y,x){for(var b=a+y;a<b;++a)if(x(this.lines[a]))return!0}};function sa(a){this.children=a;for(var y=0,x=0,b=0;b<a.length;++b){var E=a[b];y+=E.chunkSize(),x+=E.height,E.parent=this}this.size=y,this.height=x,this.parent=null}sa.prototype={chunkSize:function(){return this.size},removeInner:function(a,y){this.size-=y;for(var x=0;x<this.children.length;++x){var b=this.children[x],E=b.chunkSize();if(a<E){var re=Math.min(y,E-a),le=b.height;if(b.removeInner(a,re),this.height-=le-b.height,E==re&&(this.children.splice(x--,1),b.parent=null),(y-=re)==0)break;a=0}else a-=E}if(this.size-y<25&&(this.children.length>1||!(this.children[0]instanceof la))){var ue=[];this.collapse(ue),this.children=[new la(ue)],this.children[0].parent=this}},collapse:function(a){for(var y=0;y<this.children.length;++y)this.children[y].collapse(a)},insertInner:function(a,y,x){this.size+=y.length,this.height+=x;for(var b=0;b<this.children.length;++b){var E=this.children[b],re=E.chunkSize();if(a<=re){if(E.insertInner(a,y,x),E.lines&&E.lines.length>50){for(var le=E.lines.length%25+25,ue=le;ue<E.lines.length;){var de=new la(E.lines.slice(ue,ue+=25));E.height-=de.height,this.children.splice(++b,0,de),de.parent=this}E.lines=E.lines.slice(0,le),this.maybeSpill()}break}a-=re}},maybeSpill:function(){if(!(this.children.length<=10)){var a=this;do{var y=a.children.splice(a.children.length-5,5),x=new sa(y);if(a.parent){a.size-=x.size,a.height-=x.height;var E=Je(a.parent.children,a);a.parent.children.splice(E+1,0,x)}else{var b=new sa(a.children);b.parent=a,a.children=[b,x],a=b}x.parent=a.parent}while(a.children.length>10);a.parent.maybeSpill()}},iterN:function(a,y,x){for(var b=0;b<this.children.length;++b){var E=this.children[b],re=E.chunkSize();if(a<re){var le=Math.min(y,re-a);if(E.iterN(a,le,x))return!0;if((y-=le)==0)break;a=0}else a-=re}}};var ua=function(a,y,x){if(x)for(var b in x)x.hasOwnProperty(b)&&(this[b]=x[b]);this.doc=a,this.node=y};ua.prototype.clear=function(){var a=this.doc.cm,y=this.line.widgets,x=this.line,b=ke(x);if(!(b==null||!y)){for(var E=0;E<y.length;++E)y[E]==this&&y.splice(E--,1);y.length||(x.widgets=null);var re=ui(this);fr(x,Math.max(0,x.height-re)),a&&(ji(a,function(){ss(a,x,-re),ho(a,b,"widget")}),_r(a,"lineWidgetCleared",a,this,b))}},ua.prototype.changed=function(){var a=this,y=this.height,x=this.doc.cm,b=this.line;this.height=null;var E=ui(this)-y;E&&(Nn(this.doc,b)||fr(b,b.height+E),x&&ji(x,function(){x.curOp.forceUpdate=!0,ss(x,b,E),_r(x,"lineWidgetChanged",x,a,ke(b))}))},en(ua);function ss(a,y,x){yr(y)<(a.curOp&&a.curOp.scrollTop||a.doc.scrollTop)&&Qa(a,x)}function pu(a,y,x,b){var E=new ua(a,x,b),re=a.cm;return re&&E.noHScroll&&(re.display.alignWidgets=!0),aa(a,y,"widget",function(le){var ue=le.widgets||(le.widgets=[]);if(E.insertAt==null?ue.push(E):ue.splice(Math.min(ue.length-1,Math.max(0,E.insertAt)),0,E),E.line=le,re&&!Nn(a,le)){var de=yr(le)<a.scrollTop;fr(le,le.height+ui(E)),de&&Qa(re,E.height),re.curOp.forceUpdate=!0}return!0}),re&&_r(re,"lineWidgetAdded",re,E,typeof y=="number"?y:ke(y)),E}var us=0,yo=function(a,y){this.lines=[],this.type=y,this.doc=a,this.id=++us};yo.prototype.clear=function(){if(!this.explicitlyCleared){var a=this.doc.cm,y=a&&!a.curOp;if(y&&Oo(a),Tt(this,"clear")){var x=this.find();x&&_r(this,"clear",x.from,x.to)}for(var b=null,E=null,re=0;re<this.lines.length;++re){var le=this.lines[re],ue=sr(le.markedSpans,this);a&&!this.collapsed?ho(a,ke(le),"text"):a&&(ue.to!=null&&(E=ke(le)),ue.from!=null&&(b=ke(le))),le.markedSpans=mr(le.markedSpans,ue),ue.from==null&&this.collapsed&&!Nn(this.doc,le)&&a&&fr(le,Zi(a.display))}if(a&&this.collapsed&&!a.options.lineWrapping)for(var de=0;de<this.lines.length;++de){var pe=Jt(this.lines[de]),Ze=Mr(pe);Ze>a.display.maxLineLength&&(a.display.maxLine=pe,a.display.maxLineLength=Ze,a.display.maxLineChanged=!0)}b!=null&&a&&this.collapsed&&Ai(a,b,E+1),this.lines.length=0,this.explicitlyCleared=!0,this.atomic&&this.doc.cantEdit&&(this.doc.cantEdit=!1,a&&Ql(a.doc)),a&&_r(a,"markerCleared",a,this,b,E),y&&Mo(a),this.parent&&this.parent.clear()}},yo.prototype.find=function(a,y){a==null&&this.type=="bookmark"&&(a=1);for(var x,b,E=0;E<this.lines.length;++E){var re=this.lines[E],le=sr(re.markedSpans,this);if(le.from!=null&&(x=we(y?re:ke(re),le.from),a==-1))return x;if(le.to!=null&&(b=we(y?re:ke(re),le.to),a==1))return b}return x&&{from:x,to:b}},yo.prototype.changed=function(){var a=this,y=this.find(-1,!0),x=this,b=this.doc.cm;!y||!b||ji(b,function(){var E=y.line,re=ke(y.line),le=io(b,re);if(le&&(_o(le),b.curOp.selectionChanged=b.curOp.forceUpdate=!0),b.curOp.updateMaxLine=!0,!Nn(x.doc,E)&&x.height!=null){var ue=x.height;x.height=null;var de=ui(x)-ue;de&&fr(E,E.height+de)}_r(b,"markerChanged",b,a)})},yo.prototype.attachLine=function(a){if(!this.lines.length&&this.doc.cm){var y=this.doc.cm.curOp;(!y.maybeHiddenMarkers||Je(y.maybeHiddenMarkers,this)==-1)&&(y.maybeUnhiddenMarkers||(y.maybeUnhiddenMarkers=[])).push(this)}this.lines.push(a)},yo.prototype.detachLine=function(a){if(this.lines.splice(Je(this.lines,a),1),!this.lines.length&&this.doc.cm){var y=this.doc.cm.curOp;(y.maybeHiddenMarkers||(y.maybeHiddenMarkers=[])).push(this)}},en(yo);function Ho(a,y,x,b,E){if(b&&b.shared)return mu(a,y,x,b,E);if(a.cm&&!a.cm.curOp)return gi(a.cm,Ho)(a,y,x,b,E);var re=new yo(a,E),le=Te(y,x);if(b&&Pt(b,re,!1),le>0||le==0&&re.clearWhenEmpty!==!1)return re;if(re.replacedWith&&(re.collapsed=!0,re.widgetNode=ht("span",[re.replacedWith],"CodeMirror-widget"),b.handleMouseEvents||re.widgetNode.setAttribute("cm-ignore-events","true"),b.insertLeft&&(re.widgetNode.insertLeft=!0)),re.collapsed){if(pn(a,y.line,y,x,re)||y.line!=x.line&&pn(a,x.line,y,x,re))throw new Error("Inserting collapsed marker partially overlapping an existing one");Jn()}re.addToHistory&&Vl(a,{from:y,to:x,origin:"markText"},a.sel,NaN);var ue=y.line,de=a.cm,pe;if(a.iter(ue,x.line+1,function(Ye){de&&re.collapsed&&!de.options.lineWrapping&&Jt(Ye)==de.display.maxLine&&(pe=!0),re.collapsed&&ue!=y.line&&fr(Ye,0),Qn(Ye,new Kn(re,ue==y.line?y.ch:null,ue==x.line?x.ch:null)),++ue}),re.collapsed&&a.iter(y.line,x.line+1,function(Ye){Nn(a,Ye)&&fr(Ye,0)}),re.clearOnEnter&&Nt(re,"beforeCursorEnter",function(){return re.clear()}),re.readOnly&&(lr(),(a.history.done.length||a.history.undone.length)&&a.clearHistory()),re.collapsed&&(re.id=++us,re.atomic=!0),de){if(pe&&(de.curOp.updateMaxLine=!0),re.collapsed)Ai(de,y.line,x.line+1);else if(re.className||re.startStyle||re.endStyle||re.css||re.attributes||re.title)for(var Ze=y.line;Ze<=x.line;Ze++)ho(de,Ze,"text");re.atomic&&Ql(de.doc),_r(de,"markerAdded",de,re)}return re}var ca=function(a,y){this.markers=a,this.primary=y;for(var x=0;x<a.length;++x)a[x].parent=this};ca.prototype.clear=function(){if(!this.explicitlyCleared){this.explicitlyCleared=!0;for(var a=0;a<this.markers.length;++a)this.markers[a].clear();_r(this,"clear")}},ca.prototype.find=function(a,y){return this.primary.find(a,y)},en(ca);function mu(a,y,x,b,E){b=Pt(b),b.shared=!1;var re=[Ho(a,y,x,b,E)],le=re[0],ue=b.widgetNode;return go(a,function(de){ue&&(b.widgetNode=ue.cloneNode(!0)),re.push(Ho(de,Ct(de,y),Ct(de,x),b,E));for(var pe=0;pe<de.linked.length;++pe)if(de.linked[pe].isParent)return;le=ze(re)}),new ca(re,le)}function cs(a){return a.findMarks(we(a.first,0),a.clipPos(we(a.lastLine())),function(y){return y.parent})}function vu(a,y){for(var x=0;x<y.length;x++){var b=y[x],E=b.find(),re=a.clipPos(E.from),le=a.clipPos(E.to);if(Te(re,le)){var ue=Ho(a,re,le,b.primary,b.primary.type);b.markers.push(ue),ue.parent=b}}}function gu(a){for(var y=function(b){var E=a[b],re=[E.primary.doc];go(E.primary.doc,function(de){return re.push(de)});for(var le=0;le<E.markers.length;le++){var ue=E.markers[le];Je(re,ue.doc)==-1&&(ue.parent=null,E.markers.splice(le--,1))}},x=0;x<a.length;x++)y(x)}var yu=0,Ni=function(a,y,x,b,E){if(!(this instanceof Ni))return new Ni(a,y,x,b,E);x==null&&(x=0),sa.call(this,[new la([new Ar("",null)])]),this.first=x,this.scrollTop=this.scrollLeft=0,this.cantEdit=!1,this.cleanGeneration=1,this.modeFrontier=this.highlightFrontier=x;var re=we(x,0);this.sel=mo(re),this.history=new Ta(null),this.id=++yu,this.modeOption=y,this.lineSep=b,this.direction=E=="rtl"?"rtl":"ltr",this.extend=!1,typeof a=="string"&&(a=this.splitLines(a)),al(this,{from:re,to:re,text:a}),Pi(this,mo(re),Ie)};Ni.prototype=te(sa.prototype,{constructor:Ni,iter:function(a,y,x){x?this.iterN(a-this.first,y-a,x):this.iterN(this.first,this.first+this.size,a)},insert:function(a,y){for(var x=0,b=0;b<y.length;++b)x+=y[b].height;this.insertInner(a-this.first,y,x)},remove:function(a,y){this.removeInner(a-this.first,y)},getValue:function(a){var y=Un(this,this.first,this.first+this.size);return a===!1?y:y.join(a||this.lineSeparator())},setValue:yi(function(a){var y=we(this.first,0),x=this.first+this.size-1;zo(this,{from:y,to:we(x,Dt(this,x).text.length),text:this.splitLines(a),origin:"setValue",full:!0},!0),this.cm&&Qo(this.cm,0,0),Pi(this,mo(y),Ie)}),replaceRange:function(a,y,x,b){y=Ct(this,y),x=x?Ct(this,x):y,$o(this,a,y,x,b)},getRange:function(a,y,x){var b=Qt(this,Ct(this,a),Ct(this,y));return x===!1?b:b.join(x||this.lineSeparator())},getLine:function(a){var y=this.getLineHandle(a);return y&&y.text},getLineHandle:function(a){if(Ce(this,a))return Dt(this,a)},getLineNumber:function(a){return ke(a)},getLineHandleVisualStart:function(a){return typeof a=="number"&&(a=Dt(this,a)),Jt(a)},lineCount:function(){return this.size},firstLine:function(){return this.first},lastLine:function(){return this.first+this.size-1},clipPos:function(a){return Ct(this,a)},getCursor:function(a){var y=this.sel.primary(),x;return a==null||a=="head"?x=y.head:a=="anchor"?x=y.anchor:a=="end"||a=="to"||a===!1?x=y.to():x=y.from(),x},listSelections:function(){return this.sel.ranges},somethingSelected:function(){return this.sel.somethingSelected()},setCursor:yi(function(a,y,x){Xl(this,Ct(this,typeof a=="number"?we(a,y||0):a),null,x)}),setSelection:yi(function(a,y,x){Xl(this,Ct(this,a),Ct(this,y||a),x)}),extendSelection:yi(function(a,y,x){Ba(this,Ct(this,a),y&&Ct(this,y),x)}),extendSelections:yi(function(a,y){Kl(this,un(this,a),y)}),extendSelectionsBy:yi(function(a,y){var x=zt(this.sel.ranges,a);Kl(this,un(this,x),y)}),setSelections:yi(function(a,y,x){if(a.length){for(var b=[],E=0;E<a.length;E++)b[E]=new Vr(Ct(this,a[E].anchor),Ct(this,a[E].head));y==null&&(y=Math.min(a.length-1,this.sel.primIndex)),Pi(this,qi(this.cm,b,y),x)}}),addSelection:yi(function(a,y,x){var b=this.sel.ranges.slice(0);b.push(new Vr(Ct(this,a),Ct(this,y||a))),Pi(this,qi(this.cm,b,b.length-1),x)}),getSelection:function(a){for(var y=this.sel.ranges,x,b=0;b<y.length;b++){var E=Qt(this,y[b].from(),y[b].to());x=x?x.concat(E):E}return a===!1?x:x.join(a||this.lineSeparator())},getSelections:function(a){for(var y=[],x=this.sel.ranges,b=0;b<x.length;b++){var E=Qt(this,x[b].from(),x[b].to());a!==!1&&(E=E.join(a||this.lineSeparator())),y[b]=E}return y},replaceSelection:function(a,y,x){for(var b=[],E=0;E<this.sel.ranges.length;E++)b[E]=a;this.replaceSelections(b,y,x||"+input")},replaceSelections:yi(function(a,y,x){for(var b=[],E=this.sel,re=0;re<E.ranges.length;re++){var le=E.ranges[re];b[re]={from:le.from(),to:le.to(),text:this.splitLines(a[re]),origin:x}}for(var ue=y&&y!="end"&&ou(this,b,y),de=b.length-1;de>=0;de--)zo(this,b[de]);ue?Yl(this,ue):this.cm&&Ao(this.cm)}),undo:yi(function(){Ra(this,"undo")}),redo:yi(function(){Ra(this,"redo")}),undoSelection:yi(function(){Ra(this,"undo",!0)}),redoSelection:yi(function(){Ra(this,"redo",!0)}),setExtending:function(a){this.extend=a},getExtending:function(){return this.extend},historySize:function(){for(var a=this.history,y=0,x=0,b=0;b<a.done.length;b++)a.done[b].ranges||++y;for(var E=0;E<a.undone.length;E++)a.undone[E].ranges||++x;return{undo:y,redo:x}},clearHistory:function(){var a=this;this.history=new Ta(this.history.maxGeneration),go(this,function(y){return y.history=a.history},!0)},markClean:function(){this.cleanGeneration=this.changeGeneration(!0)},changeGeneration:function(a){return a&&(this.history.lastOp=this.history.lastSelOp=this.history.lastOrigin=null),this.history.generation},isClean:function(a){return this.history.generation==(a||this.cleanGeneration)},getHistory:function(){return{done:Ro(this.history.done),undone:Ro(this.history.undone)}},setHistory:function(a){var y=this.history=new Ta(this.history.maxGeneration);y.done=Ro(a.done.slice(0),null,!0),y.undone=Ro(a.undone.slice(0),null,!0)},setGutterMarker:yi(function(a,y,x){return aa(this,a,"gutter",function(b){var E=b.gutterMarkers||(b.gutterMarkers={});return E[y]=x,!x&&ne(E)&&(b.gutterMarkers=null),!0})}),clearGutter:yi(function(a){var y=this;this.iter(function(x){x.gutterMarkers&&x.gutterMarkers[a]&&aa(y,x,"gutter",function(){return x.gutterMarkers[a]=null,ne(x.gutterMarkers)&&(x.gutterMarkers=null),!0})})}),lineInfo:function(a){var y;if(typeof a=="number"){if(!Ce(this,a)||(y=a,a=Dt(this,a),!a))return null}else if(y=ke(a),y==null)return null;return{line:y,handle:a,text:a.text,gutterMarkers:a.gutterMarkers,textClass:a.textClass,bgClass:a.bgClass,wrapClass:a.wrapClass,widgets:a.widgets}},addLineClass:yi(function(a,y,x){return aa(this,a,y=="gutter"?"gutter":"class",function(b){var E=y=="text"?"textClass":y=="background"?"bgClass":y=="gutter"?"gutterClass":"wrapClass";if(!b[E])b[E]=x;else{if(it(x).test(b[E]))return!1;b[E]+=" "+x}return!0})}),removeLineClass:yi(function(a,y,x){return aa(this,a,y=="gutter"?"gutter":"class",function(b){var E=y=="text"?"textClass":y=="background"?"bgClass":y=="gutter"?"gutterClass":"wrapClass",re=b[E];if(re)if(x==null)b[E]=null;else{var le=re.match(it(x));if(!le)return!1;var ue=le.index+le[0].length;b[E]=re.slice(0,le.index)+(!le.index||ue==re.length?"":" ")+re.slice(ue)||null}else return!1;return!0})}),addLineWidget:yi(function(a,y,x){return pu(this,a,y,x)}),removeLineWidget:function(a){a.clear()},markText:function(a,y,x){return Ho(this,Ct(this,a),Ct(this,y),x,x&&x.type||"range")},setBookmark:function(a,y){var x={replacedWith:y&&(y.nodeType==null?y.widget:y),insertLeft:y&&y.insertLeft,clearWhenEmpty:!1,shared:y&&y.shared,handleMouseEvents:y&&y.handleMouseEvents};return a=Ct(this,a),Ho(this,a,a,x,"bookmark")},findMarksAt:function(a){a=Ct(this,a);var y=[],x=Dt(this,a.line).markedSpans;if(x)for(var b=0;b<x.length;++b){var E=x[b];(E.from==null||E.from<=a.ch)&&(E.to==null||E.to>=a.ch)&&y.push(E.marker.parent||E.marker)}return y},findMarks:function(a,y,x){a=Ct(this,a),y=Ct(this,y);var b=[],E=a.line;return this.iter(a.line,y.line+1,function(re){var le=re.markedSpans;if(le)for(var ue=0;ue<le.length;ue++){var de=le[ue];!(de.to!=null&&E==a.line&&a.ch>=de.to||de.from==null&&E!=a.line||de.from!=null&&E==y.line&&de.from>=y.ch)&&(!x||x(de.marker))&&b.push(de.marker.parent||de.marker)}++E}),b},getAllMarks:function(){var a=[];return this.iter(function(y){var x=y.markedSpans;if(x)for(var b=0;b<x.length;++b)x[b].from!=null&&a.push(x[b].marker)}),a},posFromIndex:function(a){var y,x=this.first,b=this.lineSeparator().length;return this.iter(function(E){var re=E.text.length+b;if(re>a)return y=a,!0;a-=re,++x}),Ct(this,we(x,y))},indexFromPos:function(a){a=Ct(this,a);var y=a.ch;if(a.line<this.first||a.ch<0)return 0;var x=this.lineSeparator().length;return this.iter(this.first,a.line,function(b){y+=b.text.length+x}),y},copy:function(a){var y=new Ni(Un(this,this.first,this.first+this.size),this.modeOption,this.first,this.lineSep,this.direction);return y.scrollTop=this.scrollTop,y.scrollLeft=this.scrollLeft,y.sel=this.sel,y.extend=!1,a&&(y.history.undoDepth=this.history.undoDepth,y.setHistory(this.getHistory())),y},linkedDoc:function(a){a||(a={});var y=this.first,x=this.first+this.size;a.from!=null&&a.from>y&&(y=a.from),a.to!=null&&a.to<x&&(x=a.to);var b=new Ni(Un(this,y,x),a.mode||this.modeOption,y,this.lineSep,this.direction);return a.sharedHist&&(b.history=this.history),(this.linked||(this.linked=[])).push({doc:b,sharedHist:a.sharedHist}),b.linked=[{doc:this,isParent:!0,sharedHist:a.sharedHist}],vu(b,cs(this)),b},unlinkDoc:function(a){if(a instanceof ei&&(a=a.doc),this.linked)for(var y=0;y<this.linked.length;++y){var x=this.linked[y];if(x.doc==a){this.linked.splice(y,1),a.unlinkDoc(this),gu(cs(this));break}}if(a.history==this.history){var b=[a.id];go(a,function(E){return b.push(E.id)},!0),a.history=new Ta(null),a.history.done=Ro(this.history.done,b),a.history.undone=Ro(this.history.undone,b)}},iterLinkedDocs:function(a){go(this,a)},getMode:function(){return this.mode},getEditor:function(){return this.cm},splitLines:function(a){return this.lineSep?a.split(this.lineSep):Cn(a)},lineSeparator:function(){return this.lineSep||`
|
|
|
`},setDirection:yi(function(a){a!="rtl"&&(a="ltr"),a!=this.direction&&(this.direction=a,this.iter(function(y){return y.order=null}),this.cm&&au(this.cm))})}),Ni.prototype.eachLine=Ni.prototype.iter;var ds=0;function bu(a){var y=this;if(fs(y),!(ft(y,a)||wi(y.display,a))){yn(a),ye&&(ds=+new Date);var x=wo(y,a,!0),b=a.dataTransfer.files;if(!(!x||y.isReadOnly()))if(b&&b.length&&window.FileReader&&window.File)for(var E=b.length,re=Array(E),le=0,ue=function(){++le==E&&gi(y,function(){x=Ct(y.doc,x);var Mt={from:x,to:x,text:y.doc.splitLines(re.filter(function(vn){return vn!=null}).join(y.doc.lineSeparator())),origin:"paste"};zo(y.doc,Mt),Yl(y.doc,mo(Ct(y.doc,x),Ct(y.doc,vo(Mt))))})()},de=function(Mt,vn){if(y.options.allowDropFileTypes&&Je(y.options.allowDropFileTypes,Mt.type)==-1){ue();return}var Mn=new FileReader;Mn.onerror=function(){return ue()},Mn.onload=function(){var Vn=Mn.result;if(/[\x00-\x08\x0e-\x1f]{2}/.test(Vn)){ue();return}re[vn]=Vn,ue()},Mn.readAsText(Mt)},pe=0;pe<b.length;pe++)de(b[pe],pe);else{if(y.state.draggingText&&y.doc.sel.contains(x)>-1){y.state.draggingText(a),setTimeout(function(){return y.display.input.focus()},20);return}try{var Ze=a.dataTransfer.getData("Text");if(Ze){var Ye;if(y.state.draggingText&&!y.state.draggingText.copy&&(Ye=y.listSelections()),Aa(y.doc,mo(x,x)),Ye)for(var Lt=0;Lt<Ye.length;++Lt)$o(y.doc,"",Ye[Lt].anchor,Ye[Lt].head,"drag");y.replaceSelection(Ze,"around","paste"),y.display.input.focus()}}catch(Mt){}}}}function xu(a,y){if(ye&&(!a.state.draggingText||+new Date-ds<100)){Pe(y);return}if(!(ft(a,y)||wi(a.display,y))&&(y.dataTransfer.setData("Text",a.getSelection()),y.dataTransfer.effectAllowed="copyMove",y.dataTransfer.setDragImage&&!We)){var x=tt("img",null,null,"position: fixed; left: 0; top: 0;");x.src="data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==",fe&&(x.width=x.height=1,a.display.wrapper.appendChild(x),x._top=x.offsetTop),y.dataTransfer.setDragImage(x,0,0),fe&&x.parentNode.removeChild(x)}}function Cu(a,y){var x=wo(a,y);if(x){var b=document.createDocumentFragment();El(a,x,b),a.display.dragCursor||(a.display.dragCursor=tt("div",null,"CodeMirror-cursors CodeMirror-dragcursors"),a.display.lineSpace.insertBefore(a.display.dragCursor,a.display.cursorDiv)),nt(a.display.dragCursor,b)}}function fs(a){a.display.dragCursor&&(a.display.lineSpace.removeChild(a.display.dragCursor),a.display.dragCursor=null)}function hs(a){if(document.getElementsByClassName){for(var y=document.getElementsByClassName("CodeMirror"),x=[],b=0;b<y.length;b++){var E=y[b].CodeMirror;E&&x.push(E)}x.length&&x[0].operation(function(){for(var re=0;re<x.length;re++)a(x[re])})}}var ps=!1;function wu(){ps||(Su(),ps=!0)}function Su(){var a;Nt(window,"resize",function(){a==null&&(a=setTimeout(function(){a=null,hs(Eu)},100))}),Nt(window,"blur",function(){return hs(Bo)})}function Eu(a){var y=a.display;y.cachedCharWidth=y.cachedTextHeight=y.cachedPaddingH=null,y.scrollbarsClipped=!1,a.setSize()}for(var bo={3:"Pause",8:"Backspace",9:"Tab",13:"Enter",16:"Shift",17:"Ctrl",18:"Alt",19:"Pause",20:"CapsLock",27:"Esc",32:"Space",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"Left",38:"Up",39:"Right",40:"Down",44:"PrintScrn",45:"Insert",46:"Delete",59:";",61:"=",91:"Mod",92:"Mod",93:"Mod",106:"*",107:"=",109:"-",110:".",111:"/",145:"ScrollLock",173:"-",186:";",187:"=",188:",",189:"-",190:".",191:"/",192:"`",219:"[",220:"\\",221:"]",222:"'",224:"Mod",63232:"Up",63233:"Down",63234:"Left",63235:"Right",63272:"Delete",63273:"Home",63275:"End",63276:"PageUp",63277:"PageDown",63302:"Insert"},da=0;da<10;da++)bo[da+48]=bo[da+96]=String(da);for(var Fa=65;Fa<=90;Fa++)bo[Fa]=String.fromCharCode(Fa);for(var fa=1;fa<=12;fa++)bo[fa+111]=bo[fa+63235]="F"+fa;var so={};so.basic={Left:"goCharLeft",Right:"goCharRight",Up:"goLineUp",Down:"goLineDown",End:"goLineEnd",Home:"goLineStartSmart",PageUp:"goPageUp",PageDown:"goPageDown",Delete:"delCharAfter",Backspace:"delCharBefore","Shift-Backspace":"delCharBefore",Tab:"defaultTab","Shift-Tab":"indentAuto",Enter:"newlineAndIndent",Insert:"toggleOverwrite",Esc:"singleSelection"},so.pcDefault={"Ctrl-A":"selectAll","Ctrl-D":"deleteLine","Ctrl-Z":"undo","Shift-Ctrl-Z":"redo","Ctrl-Y":"redo","Ctrl-Home":"goDocStart","Ctrl-End":"goDocEnd","Ctrl-Up":"goLineUp","Ctrl-Down":"goLineDown","Ctrl-Left":"goGroupLeft","Ctrl-Right":"goGroupRight","Alt-Left":"goLineStart","Alt-Right":"goLineEnd","Ctrl-Backspace":"delGroupBefore","Ctrl-Delete":"delGroupAfter","Ctrl-S":"save","Ctrl-F":"find","Ctrl-G":"findNext","Shift-Ctrl-G":"findPrev","Shift-Ctrl-F":"replace","Shift-Ctrl-R":"replaceAll","Ctrl-[":"indentLess","Ctrl-]":"indentMore","Ctrl-U":"undoSelection","Shift-Ctrl-U":"redoSelection","Alt-U":"redoSelection",fallthrough:"basic"},so.emacsy={"Ctrl-F":"goCharRight","Ctrl-B":"goCharLeft","Ctrl-P":"goLineUp","Ctrl-N":"goLineDown","Alt-F":"goWordRight","Alt-B":"goWordLeft","Ctrl-A":"goLineStart","Ctrl-E":"goLineEnd","Ctrl-V":"goPageDown","Shift-Ctrl-V":"goPageUp","Ctrl-D":"delCharAfter","Ctrl-H":"delCharBefore","Alt-D":"delWordAfter","Alt-Backspace":"delWordBefore","Ctrl-K":"killLine","Ctrl-T":"transposeChars","Ctrl-O":"openLine"},so.macDefault={"Cmd-A":"selectAll","Cmd-D":"deleteLine","Cmd-Z":"undo","Shift-Cmd-Z":"redo","Cmd-Y":"redo","Cmd-Home":"goDocStart","Cmd-Up":"goDocStart","Cmd-End":"goDocEnd","Cmd-Down":"goDocEnd","Alt-Left":"goGroupLeft","Alt-Right":"goGroupRight","Cmd-Left":"goLineLeft","Cmd-Right":"goLineRight","Alt-Backspace":"delGroupBefore","Ctrl-Alt-Backspace":"delGroupAfter","Alt-Delete":"delGroupAfter","Cmd-S":"save","Cmd-F":"find","Cmd-G":"findNext","Shift-Cmd-G":"findPrev","Cmd-Alt-F":"replace","Shift-Cmd-Alt-F":"replaceAll","Cmd-[":"indentLess","Cmd-]":"indentMore","Cmd-Backspace":"delWrappedLineLeft","Cmd-Delete":"delWrappedLineRight","Cmd-U":"undoSelection","Shift-Cmd-U":"redoSelection","Ctrl-Up":"goDocStart","Ctrl-Down":"goDocEnd",fallthrough:["basic","emacsy"]},so.default=Ne?so.macDefault:so.pcDefault;function Iu(a){var y=a.split(/-(?!$)/);a=y[y.length-1];for(var x,b,E,re,le=0;le<y.length-1;le++){var ue=y[le];if(/^(cmd|meta|m)$/i.test(ue))re=!0;else if(/^a(lt)?$/i.test(ue))x=!0;else if(/^(c|ctrl|control)$/i.test(ue))b=!0;else if(/^s(hift)?$/i.test(ue))E=!0;else throw new Error("Unrecognized modifier name: "+ue)}return x&&(a="Alt-"+a),b&&(a="Ctrl-"+a),re&&(a="Cmd-"+a),E&&(a="Shift-"+a),a}function Ou(a){var y={};for(var x in a)if(a.hasOwnProperty(x)){var b=a[x];if(/^(name|fallthrough|(de|at)tach)$/.test(x))continue;if(b=="..."){delete a[x];continue}for(var E=zt(x.split(" "),Iu),re=0;re<E.length;re++){var le=void 0,ue=void 0;re==E.length-1?(ue=E.join(" "),le=b):(ue=E.slice(0,re+1).join(" "),le="...");var de=y[ue];if(!de)y[ue]=le;else if(de!=le)throw new Error("Inconsistent bindings for "+ue)}delete a[x]}for(var pe in y)a[pe]=y[pe];return a}function Zo(a,y,x,b){y=za(y);var E=y.call?y.call(a,b):y[a];if(E===!1)return"nothing";if(E==="...")return"multi";if(E!=null&&x(E))return"handled";if(y.fallthrough){if(Object.prototype.toString.call(y.fallthrough)!="[object Array]")return Zo(a,y.fallthrough,x,b);for(var re=0;re<y.fallthrough.length;re++){var le=Zo(a,y.fallthrough[re],x,b);if(le)return le}}}function ms(a){var y=typeof a=="string"?a:bo[a.keyCode];return y=="Ctrl"||y=="Alt"||y=="Shift"||y=="Mod"}function vs(a,y,x){var b=a;return y.altKey&&b!="Alt"&&(a="Alt-"+a),(mt?y.metaKey:y.ctrlKey)&&b!="Ctrl"&&(a="Ctrl-"+a),(mt?y.ctrlKey:y.metaKey)&&b!="Mod"&&(a="Cmd-"+a),!x&&y.shiftKey&&b!="Shift"&&(a="Shift-"+a),a}function gs(a,y){if(fe&&a.keyCode==34&&a.char)return!1;var x=bo[a.keyCode];return x==null||a.altGraphKey?!1:(a.keyCode==3&&a.code&&(x=a.code),vs(x,a,y))}function za(a){return typeof a=="string"?so[a]:a}function jo(a,y){for(var x=a.doc.sel.ranges,b=[],E=0;E<x.length;E++){for(var re=y(x[E]);b.length&&Te(re.from,ze(b).to)<=0;){var le=b.pop();if(Te(le.from,re.from)<0){re.from=le.from;break}}b.push(re)}ji(a,function(){for(var ue=b.length-1;ue>=0;ue--)$o(a.doc,"",b[ue].from,b[ue].to,"+delete");Ao(a)})}function cl(a,y,x){var b=ot(a.text,y+x,x);return b<0||b>a.text.length?null:b}function dl(a,y,x){var b=cl(a,y.ch,x);return b==null?null:new we(y.line,b,x<0?"after":"before")}function fl(a,y,x,b,E){if(a){y.doc.direction=="rtl"&&(E=-E);var re=Kt(x,y.doc.direction);if(re){var le=E<0?ze(re):re[0],ue=E<0==(le.level==1),de=ue?"after":"before",pe;if(le.level>0||y.doc.direction=="rtl"){var Ze=co(y,x);pe=E<0?x.text.length-1:0;var Ye=Ki(y,Ze,pe).top;pe=Ee(function(Lt){return Ki(y,Ze,Lt).top==Ye},E<0==(le.level==1)?le.from:le.to-1,pe),de=="before"&&(pe=cl(x,pe,1))}else pe=E<0?le.to:le.from;return new we(b,pe,de)}}return new we(b,E<0?x.text.length:0,E<0?"before":"after")}function Mu(a,y,x,b){var E=Kt(y,a.doc.direction);if(!E)return dl(y,x,b);x.ch>=y.text.length?(x.ch=y.text.length,x.sticky="before"):x.ch<=0&&(x.ch=0,x.sticky="after");var re=bt(E,x.ch,x.sticky),le=E[re];if(a.doc.direction=="ltr"&&le.level%2==0&&(b>0?le.to>x.ch:le.from<x.ch))return dl(y,x,b);var ue=function(tr,ur){return cl(y,tr instanceof we?tr.ch:tr,ur)},de,pe=function(tr){return a.options.lineWrapping?(de=de||co(a,y),oi(a,y,de,tr)):{begin:0,end:y.text.length}},Ze=pe(x.sticky=="before"?ue(x,-1):x.ch);if(a.doc.direction=="rtl"||le.level==1){var Ye=le.level==1==b<0,Lt=ue(x,Ye?1:-1);if(Lt!=null&&(Ye?Lt<=le.to&&Lt<=Ze.end:Lt>=le.from&&Lt>=Ze.begin)){var Mt=Ye?"before":"after";return new we(x.line,Lt,Mt)}}var vn=function(tr,ur,nr){for(var gr=function(Yr,bi){return bi?new we(x.line,ue(Yr,1),"before"):new we(x.line,Yr,"after")};tr>=0&&tr<E.length;tr+=ur){var Ir=E[tr],Er=ur>0==(Ir.level!=1),zr=Er?nr.begin:ue(nr.end,-1);if(Ir.from<=zr&&zr<Ir.to||(zr=Er?Ir.from:ue(Ir.to,-1),nr.begin<=zr&&zr<nr.end))return gr(zr,Er)}},Mn=vn(re+b,b,Ze);if(Mn)return Mn;var Vn=b>0?Ze.end:ue(Ze.begin,-1);return Vn!=null&&!(b>0&&Vn==y.text.length)&&(Mn=vn(b>0?0:E.length-1,b,pe(Vn)),Mn)?Mn:null}var ha={selectAll:ts,singleSelection:function(a){return a.setSelection(a.getCursor("anchor"),a.getCursor("head"),Ie)},killLine:function(a){return jo(a,function(y){if(y.empty()){var x=Dt(a.doc,y.head.line).text.length;return y.head.ch==x&&y.head.line<a.lastLine()?{from:y.head,to:we(y.head.line+1,0)}:{from:y.head,to:we(y.head.line,x)}}else return{from:y.from(),to:y.to()}})},deleteLine:function(a){return jo(a,function(y){return{from:we(y.from().line,0),to:Ct(a.doc,we(y.to().line+1,0))}})},delLineLeft:function(a){return jo(a,function(y){return{from:we(y.from().line,0),to:y.from()}})},delWrappedLineLeft:function(a){return jo(a,function(y){var x=a.charCoords(y.head,"div").top+5,b=a.coordsChar({left:0,top:x},"div");return{from:b,to:y.from()}})},delWrappedLineRight:function(a){return jo(a,function(y){var x=a.charCoords(y.head,"div").top+5,b=a.coordsChar({left:a.display.lineDiv.offsetWidth+100,top:x},"div");return{from:y.from(),to:b}})},undo:function(a){return a.undo()},redo:function(a){return a.redo()},undoSelection:function(a){return a.undoSelection()},redoSelection:function(a){return a.redoSelection()},goDocStart:function(a){return a.extendSelection(we(a.firstLine(),0))},goDocEnd:function(a){return a.extendSelection(we(a.lastLine()))},goLineStart:function(a){return a.extendSelectionsBy(function(y){return ys(a,y.head.line)},{origin:"+move",bias:1})},goLineStartSmart:function(a){return a.extendSelectionsBy(function(y){return bs(a,y.head)},{origin:"+move",bias:1})},goLineEnd:function(a){return a.extendSelectionsBy(function(y){return Pu(a,y.head.line)},{origin:"+move",bias:-1})},goLineRight:function(a){return a.extendSelectionsBy(function(y){var x=a.cursorCoords(y.head,"div").top+5;return a.coordsChar({left:a.display.lineDiv.offsetWidth+100,top:x},"div")},et)},goLineLeft:function(a){return a.extendSelectionsBy(function(y){var x=a.cursorCoords(y.head,"div").top+5;return a.coordsChar({left:0,top:x},"div")},et)},goLineLeftSmart:function(a){return a.extendSelectionsBy(function(y){var x=a.cursorCoords(y.head,"div").top+5,b=a.coordsChar({left:0,top:x},"div");return b.ch<a.getLine(b.line).search(/\S/)?bs(a,y.head):b},et)},goLineUp:function(a){return a.moveV(-1,"line")},goLineDown:function(a){return a.moveV(1,"line")},goPageUp:function(a){return a.moveV(-1,"page")},goPageDown:function(a){return a.moveV(1,"page")},goCharLeft:function(a){return a.moveH(-1,"char")},goCharRight:function(a){return a.moveH(1,"char")},goColumnLeft:function(a){return a.moveH(-1,"column")},goColumnRight:function(a){return a.moveH(1,"column")},goWordLeft:function(a){return a.moveH(-1,"word")},goGroupRight:function(a){return a.moveH(1,"group")},goGroupLeft:function(a){return a.moveH(-1,"group")},goWordRight:function(a){return a.moveH(1,"word")},delCharBefore:function(a){return a.deleteH(-1,"codepoint")},delCharAfter:function(a){return a.deleteH(1,"char")},delWordBefore:function(a){return a.deleteH(-1,"word")},delWordAfter:function(a){return a.deleteH(1,"word")},delGroupBefore:function(a){return a.deleteH(-1,"group")},delGroupAfter:function(a){return a.deleteH(1,"group")},indentAuto:function(a){return a.indentSelection("smart")},indentMore:function(a){return a.indentSelection("add")},indentLess:function(a){return a.indentSelection("subtract")},insertTab:function(a){return a.replaceSelection(" ")},insertSoftTab:function(a){for(var y=[],x=a.listSelections(),b=a.options.tabSize,E=0;E<x.length;E++){var re=x[E].from(),le=ge(a.getLine(re.line),re.ch,b);y.push(Yt(b-le%b))}a.replaceSelections(y)},defaultTab:function(a){a.somethingSelected()?a.indentSelection("add"):a.execCommand("insertTab")},transposeChars:function(a){return ji(a,function(){for(var y=a.listSelections(),x=[],b=0;b<y.length;b++)if(y[b].empty()){var E=y[b].head,re=Dt(a.doc,E.line).text;if(re){if(E.ch==re.length&&(E=new we(E.line,E.ch-1)),E.ch>0)E=new we(E.line,E.ch+1),a.replaceRange(re.charAt(E.ch-1)+re.charAt(E.ch-2),we(E.line,E.ch-2),E,"+transpose");else if(E.line>a.doc.first){var le=Dt(a.doc,E.line-1).text;le&&(E=new we(E.line,1),a.replaceRange(re.charAt(0)+a.doc.lineSeparator()+le.charAt(le.length-1),we(E.line-1,le.length-1),E,"+transpose"))}}x.push(new Vr(E,E))}a.setSelections(x)})},newlineAndIndent:function(a){return ji(a,function(){for(var y=a.listSelections(),x=y.length-1;x>=0;x--)a.replaceRange(a.doc.lineSeparator(),y[x].anchor,y[x].head,"+input");y=a.listSelections();for(var b=0;b<y.length;b++)a.indentLine(y[b].from().line,null,!0);Ao(a)})},openLine:function(a){return a.replaceSelection(`
|
|
|
`,"start")},toggleOverwrite:function(a){return a.toggleOverwrite()}};function ys(a,y){var x=Dt(a.doc,y),b=Jt(x);return b!=x&&(y=ke(b)),fl(!0,a,b,y,1)}function Pu(a,y){var x=Dt(a.doc,y),b=zn(x);return b!=x&&(y=ke(b)),fl(!0,a,x,y,-1)}function bs(a,y){var x=ys(a,y.line),b=Dt(a.doc,x.line),E=Kt(b,a.doc.direction);if(!E||E[0].level==0){var re=Math.max(x.ch,b.text.search(/\S/)),le=y.line==x.line&&y.ch<=re&&y.ch;return we(x.line,le?0:re,x.sticky)}return x}function $a(a,y,x){if(typeof y=="string"&&(y=ha[y],!y))return!1;a.display.input.ensurePolled();var b=a.display.shift,E=!1;try{a.isReadOnly()&&(a.state.suppressEdits=!0),x&&(a.display.shift=!1),E=y(a)!=wt}finally{a.display.shift=b,a.state.suppressEdits=!1}return E}function Du(a,y,x){for(var b=0;b<a.state.keyMaps.length;b++){var E=Zo(y,a.state.keyMaps[b],x,a);if(E)return E}return a.options.extraKeys&&Zo(y,a.options.extraKeys,x,a)||Zo(y,a.options.keyMap,x,a)}var ku=new ce;function pa(a,y,x,b){var E=a.state.keySeq;if(E){if(ms(y))return"handled";if(/\'$/.test(y)?a.state.keySeq=null:ku.set(50,function(){a.state.keySeq==E&&(a.state.keySeq=null,a.display.input.reset())}),xs(a,E+" "+y,x,b))return!0}return xs(a,y,x,b)}function xs(a,y,x,b){var E=Du(a,y,b);return E=="multi"&&(a.state.keySeq=y),E=="handled"&&_r(a,"keyHandled",a,y,x),(E=="handled"||E=="multi")&&(yn(x),Xa(a)),!!E}function Cs(a,y){var x=gs(y,!0);return x?y.shiftKey&&!a.state.keySeq?pa(a,"Shift-"+x,y,function(b){return $a(a,b,!0)})||pa(a,x,y,function(b){if(typeof b=="string"?/^go[A-Z]/.test(b):b.motion)return $a(a,b)}):pa(a,x,y,function(b){return $a(a,b)}):!1}function Tu(a,y,x){return pa(a,"'"+x+"'",y,function(b){return $a(a,b,!0)})}var hl=null;function ws(a){var y=this;if(!(a.target&&a.target!=y.display.input.getField())&&(y.curOp.focus=lt(),!ft(y,a))){ye&&be<11&&a.keyCode==27&&(a.returnValue=!1);var x=a.keyCode;y.display.shift=x==16||a.shiftKey;var b=Cs(y,a);fe&&(hl=b?x:null,!b&&x==88&&!xt&&(Ne?a.metaKey:a.ctrlKey)&&y.replaceSelection("",null,"cut")),z&&!Ne&&!b&&x==46&&a.shiftKey&&!a.ctrlKey&&document.execCommand&&document.execCommand("cut"),x==18&&!/\bCodeMirror-crosshair\b/.test(y.display.lineDiv.className)&&Lu(y)}}function Lu(a){var y=a.display.lineDiv;me(y,"CodeMirror-crosshair");function x(b){(b.keyCode==18||!b.altKey)&&(je(y,"CodeMirror-crosshair"),qt(document,"keyup",x),qt(document,"mouseover",x))}Nt(document,"keyup",x),Nt(document,"mouseover",x)}function Ss(a){a.keyCode==16&&(this.doc.sel.shift=!1),ft(this,a)}function Es(a){var y=this;if(!(a.target&&a.target!=y.display.input.getField())&&!(wi(y.display,a)||ft(y,a)||a.ctrlKey&&!a.altKey||Ne&&a.metaKey)){var x=a.keyCode,b=a.charCode;if(fe&&x==hl){hl=null,yn(a);return}if(!(fe&&(!a.which||a.which<10)&&Cs(y,a))){var E=String.fromCharCode(b==null?x:b);E!="\b"&&(Tu(y,a,E)||y.display.input.onKeyPress(a))}}}var Bu=400,pl=function(a,y,x){this.time=a,this.pos=y,this.button=x};pl.prototype.compare=function(a,y,x){return this.time+Bu>a&&Te(y,this.pos)==0&&x==this.button};var ma,va;function Au(a,y){var x=+new Date;return va&&va.compare(x,a,y)?(ma=va=null,"triple"):ma&&ma.compare(x,a,y)?(va=new pl(x,a,y),ma=null,"double"):(ma=new pl(x,a,y),va=null,"single")}function Is(a){var y=this,x=y.display;if(!(ft(y,a)||x.activeTouch&&x.input.supportsTouch())){if(x.input.ensurePolled(),x.shift=a.shiftKey,wi(x,a)){Me||(x.scroller.draggable=!1,setTimeout(function(){return x.scroller.draggable=!0},100));return}if(!ml(y,a)){var b=wo(y,a),E=St(a),re=b?Au(b,E):"single";window.focus(),E==1&&y.state.selectingText&&y.state.selectingText(a),!(b&&Nu(y,E,b,re,a))&&(E==1?b?Fu(y,b,re,a):rt(a)==x.scroller&&yn(a):E==2?(b&&Ba(y.doc,b),setTimeout(function(){return x.input.focus()},20)):E==3&&(st?y.display.input.onContextMenu(a):Ol(y)))}}}function Nu(a,y,x,b,E){var re="Click";return b=="double"?re="Double"+re:b=="triple"&&(re="Triple"+re),re=(y==1?"Left":y==2?"Middle":"Right")+re,pa(a,vs(re,E),E,function(le){if(typeof le=="string"&&(le=ha[le]),!le)return!1;var ue=!1;try{a.isReadOnly()&&(a.state.suppressEdits=!0),ue=le(a,x)!=wt}finally{a.state.suppressEdits=!1}return ue})}function Ru(a,y,x){var b=a.getOption("configureMouse"),E=b?b(a,y,x):{};if(E.unit==null){var re=dt?x.shiftKey&&x.metaKey:x.altKey;E.unit=re?"rectangle":y=="single"?"char":y=="double"?"word":"line"}return(E.extend==null||a.doc.extend)&&(E.extend=a.doc.extend||x.shiftKey),E.addNew==null&&(E.addNew=Ne?x.metaKey:x.ctrlKey),E.moveOnDrag==null&&(E.moveOnDrag=!(Ne?x.altKey:x.ctrlKey)),E}function Fu(a,y,x,b){ye?setTimeout(He(Il,a),0):a.curOp.focus=lt();var E=Ru(a,x,b),re=a.doc.sel,le;a.options.dragDrop&&_t&&!a.isReadOnly()&&x=="single"&&(le=re.contains(y))>-1&&(Te((le=re.ranges[le]).from(),y)<0||y.xRel>0)&&(Te(le.to(),y)>0||y.xRel<0)?zu(a,b,y,E):$u(a,b,y,E)}function zu(a,y,x,b){var E=a.display,re=!1,le=gi(a,function(pe){Me&&(E.scroller.draggable=!1),a.state.draggingText=!1,qt(E.wrapper.ownerDocument,"mouseup",le),qt(E.wrapper.ownerDocument,"mousemove",ue),qt(E.scroller,"dragstart",de),qt(E.scroller,"drop",le),re||(yn(pe),b.addNew||Ba(a.doc,x,null,null,b.extend),Me&&!We||ye&&be==9?setTimeout(function(){E.wrapper.ownerDocument.body.focus({preventScroll:!0}),E.input.focus()},20):E.input.focus())}),ue=function(pe){re=re||Math.abs(y.clientX-pe.clientX)+Math.abs(y.clientY-pe.clientY)>=10},de=function(){return re=!0};Me&&(E.scroller.draggable=!0),a.state.draggingText=le,le.copy=!b.moveOnDrag,E.scroller.dragDrop&&E.scroller.dragDrop(),Nt(E.wrapper.ownerDocument,"mouseup",le),Nt(E.wrapper.ownerDocument,"mousemove",ue),Nt(E.scroller,"dragstart",de),Nt(E.scroller,"drop",le),Ol(a),setTimeout(function(){return E.input.focus()},20)}function Os(a,y,x){if(x=="char")return new Vr(y,y);if(x=="word")return a.findWordAt(y);if(x=="line")return new Vr(we(y.line,0),Ct(a.doc,we(y.line+1,0)));var b=x(a,y);return new Vr(b.from,b.to)}function $u(a,y,x,b){var E=a.display,re=a.doc;yn(y);var le,ue,de=re.sel,pe=de.ranges;if(b.addNew&&!b.extend?(ue=re.sel.contains(x),ue>-1?le=pe[ue]:le=new Vr(x,x)):(le=re.sel.primary(),ue=re.sel.primIndex),b.unit=="rectangle")b.addNew||(le=new Vr(x,x)),x=wo(a,y,!0,!0),ue=-1;else{var Ze=Os(a,x,b.unit);b.extend?le=sl(le,Ze.anchor,Ze.head,b.extend):le=Ze}b.addNew?ue==-1?(ue=pe.length,Pi(re,qi(a,pe.concat([le]),ue),{scroll:!1,origin:"*mouse"})):pe.length>1&&pe[ue].empty()&&b.unit=="char"&&!b.extend?(Pi(re,qi(a,pe.slice(0,ue).concat(pe.slice(ue+1)),0),{scroll:!1,origin:"*mouse"}),de=re.sel):ul(re,ue,le,Ue):(ue=0,Pi(re,new Vi([le],0),Ue),de=re.sel);var Ye=x;function Lt(nr){if(Te(Ye,nr)!=0)if(Ye=nr,b.unit=="rectangle"){for(var gr=[],Ir=a.options.tabSize,Er=ge(Dt(re,x.line).text,x.ch,Ir),zr=ge(Dt(re,nr.line).text,nr.ch,Ir),Yr=Math.min(Er,zr),bi=Math.max(Er,zr),ti=Math.min(x.line,nr.line),Wi=Math.min(a.lastLine(),Math.max(x.line,nr.line));ti<=Wi;ti++){var Ri=Dt(re,ti).text,ci=cn(Ri,Yr,Ir);Yr==bi?gr.push(new Vr(we(ti,ci),we(ti,ci))):Ri.length>ci&&gr.push(new Vr(we(ti,ci),we(ti,cn(Ri,bi,Ir))))}gr.length||gr.push(new Vr(x,x)),Pi(re,qi(a,de.ranges.slice(0,ue).concat(gr),ue),{origin:"*mouse",scroll:!1}),a.scrollIntoView(nr)}else{var Fi=le,Ei=Os(a,nr,b.unit),vi=Fi.anchor,di;Te(Ei.anchor,vi)>0?(di=Ei.head,vi=Xt(Fi.from(),Ei.anchor)):(di=Ei.anchor,vi=sn(Fi.to(),Ei.head));var ni=de.ranges.slice(0);ni[ue]=Hu(a,new Vr(Ct(re,vi),di)),Pi(re,qi(a,ni,ue),Ue)}}var Mt=E.wrapper.getBoundingClientRect(),vn=0;function Mn(nr){var gr=++vn,Ir=wo(a,nr,!0,b.unit=="rectangle");if(Ir)if(Te(Ir,Ye)!=0){a.curOp.focus=lt(),Lt(Ir);var Er=Ma(E,re);(Ir.line>=Er.to||Ir.line<Er.from)&&setTimeout(gi(a,function(){vn==gr&&Mn(nr)}),150)}else{var zr=nr.clientY<Mt.top?-20:nr.clientY>Mt.bottom?20:0;zr&&setTimeout(gi(a,function(){vn==gr&&(E.scroller.scrollTop+=zr,Mn(nr))}),50)}}function Vn(nr){a.state.selectingText=!1,vn=1/0,nr&&(yn(nr),E.input.focus()),qt(E.wrapper.ownerDocument,"mousemove",tr),qt(E.wrapper.ownerDocument,"mouseup",ur),re.history.lastSelOrigin=null}var tr=gi(a,function(nr){nr.buttons===0||!St(nr)?Vn(nr):Mn(nr)}),ur=gi(a,Vn);a.state.selectingText=ur,Nt(E.wrapper.ownerDocument,"mousemove",tr),Nt(E.wrapper.ownerDocument,"mouseup",ur)}function Hu(a,y){var x=y.anchor,b=y.head,E=Dt(a.doc,x.line);if(Te(x,b)==0&&x.sticky==b.sticky)return y;var re=Kt(E);if(!re)return y;var le=bt(re,x.ch,x.sticky),ue=re[le];if(ue.from!=x.ch&&ue.to!=x.ch)return y;var de=le+(ue.from==x.ch==(ue.level!=1)?0:1);if(de==0||de==re.length)return y;var pe;if(b.line!=x.line)pe=(b.line-x.line)*(a.doc.direction=="ltr"?1:-1)>0;else{var Ze=bt(re,b.ch,b.sticky),Ye=Ze-le||(b.ch-x.ch)*(ue.level==1?-1:1);Ze==de-1||Ze==de?pe=Ye<0:pe=Ye>0}var Lt=re[de+(pe?-1:0)],Mt=pe==(Lt.level==1),vn=Mt?Lt.from:Lt.to,Mn=Mt?"after":"before";return x.ch==vn&&x.sticky==Mn?y:new Vr(new we(x.line,vn,Mn),b)}function Ms(a,y,x,b){var E,re;if(y.touches)E=y.touches[0].clientX,re=y.touches[0].clientY;else try{E=y.clientX,re=y.clientY}catch(Lt){return!1}if(E>=Math.floor(a.display.gutters.getBoundingClientRect().right))return!1;b&&yn(y);var le=a.display,ue=le.lineDiv.getBoundingClientRect();if(re>ue.bottom||!Tt(a,x))return On(y);re-=ue.top-le.viewOffset;for(var de=0;de<a.display.gutterSpecs.length;++de){var pe=le.gutters.childNodes[de];if(pe&&pe.getBoundingClientRect().right>=E){var Ze=_e(a.doc,re),Ye=a.display.gutterSpecs[de];return on(a,x,a,Ze,Ye.className,y),On(y)}}}function ml(a,y){return Ms(a,y,"gutterClick",!0)}function Ps(a,y){wi(a.display,y)||Zu(a,y)||ft(a,y,"contextmenu")||st||a.display.input.onContextMenu(y)}function Zu(a,y){return Tt(a,"gutterContextMenu")?Ms(a,y,"gutterContextMenu",!1):!1}function Ds(a){a.display.wrapper.className=a.display.wrapper.className.replace(/\s*cm-s-\S+/g,"")+a.options.theme.replace(/(^|\s)\s*/g," cm-s-"),Co(a)}var Wo={toString:function(){return"CodeMirror.Init"}},ks={},Ha={};function ju(a){var y=a.optionHandlers;function x(b,E,re,le){a.defaults[b]=E,re&&(y[b]=le?function(ue,de,pe){pe!=Wo&&re(ue,de,pe)}:re)}a.defineOption=x,a.Init=Wo,x("value","",function(b,E){return b.setValue(E)},!0),x("mode",null,function(b,E){b.doc.modeOption=E,ol(b)},!0),x("indentUnit",2,ol,!0),x("indentWithTabs",!1),x("smartIndent",!0),x("tabSize",4,function(b){ia(b),Co(b),Ai(b)},!0),x("lineSeparator",null,function(b,E){if(b.doc.lineSep=E,!!E){var re=[],le=b.doc.first;b.doc.iter(function(de){for(var pe=0;;){var Ze=de.text.indexOf(E,pe);if(Ze==-1)break;pe=Ze+E.length,re.push(we(le,Ze))}le++});for(var ue=re.length-1;ue>=0;ue--)$o(b.doc,E,re[ue],we(re[ue].line,re[ue].ch+E.length))}}),x("specialChars",/[\u0000-\u001f\u007f-\u009f\u00ad\u061c\u200b-\u200c\u200e\u200f\u2028\u2029\ufeff\ufff9-\ufffc]/g,function(b,E,re){b.state.specialChars=new RegExp(E.source+(E.test(" ")?"":"| "),"g"),re!=Wo&&b.refresh()}),x("specialCharPlaceholder",Qr,function(b){return b.refresh()},!0),x("electricChars",!0),x("inputStyle",Ge?"contenteditable":"textarea",function(){throw new Error("inputStyle can not (yet) be changed in a running editor")},!0),x("spellcheck",!1,function(b,E){return b.getInputField().spellcheck=E},!0),x("autocorrect",!1,function(b,E){return b.getInputField().autocorrect=E},!0),x("autocapitalize",!1,function(b,E){return b.getInputField().autocapitalize=E},!0),x("rtlMoveVisually",!It),x("wholeLineUpdateBefore",!0),x("theme","default",function(b){Ds(b),ra(b)},!0),x("keyMap","default",function(b,E,re){var le=za(E),ue=re!=Wo&&za(re);ue&&ue.detach&&ue.detach(b,le),le.attach&&le.attach(b,ue||null)}),x("extraKeys",null),x("configureMouse",null),x("lineWrapping",!1,Gu,!0),x("gutters",[],function(b,E){b.display.gutterSpecs=rl(E,b.options.lineNumbers),ra(b)},!0),x("fixedGutter",!0,function(b,E){b.display.gutters.style.left=E?_a(b.display)+"px":"0",b.refresh()},!0),x("coverGutterNextToScrollbar",!1,function(b){return No(b)},!0),x("scrollbarStyle","native",function(b){Ll(b),No(b),b.display.scrollbars.setScrollTop(b.doc.scrollTop),b.display.scrollbars.setScrollLeft(b.doc.scrollLeft)},!0),x("lineNumbers",!1,function(b,E){b.display.gutterSpecs=rl(b.options.gutters,E),ra(b)},!0),x("firstLineNumber",1,ra,!0),x("lineNumberFormatter",function(b){return b},ra,!0),x("showCursorWhenSelecting",!1,Jo,!0),x("resetSelectionOnContextMenu",!0),x("lineWiseCopyCut",!0),x("pasteLinesPerSelection",!0),x("selectionsMayTouch",!1),x("readOnly",!1,function(b,E){E=="nocursor"&&(Bo(b),b.display.input.blur()),b.display.input.readOnlyChanged(E)}),x("screenReaderLabel",null,function(b,E){E=E===""?null:E,b.display.input.screenReaderLabelChanged(E)}),x("disableInput",!1,function(b,E){E||b.display.input.reset()},!0),x("dragDrop",!0,Wu),x("allowDropFileTypes",null),x("cursorBlinkRate",530),x("cursorScrollMargin",0),x("cursorHeight",1,Jo,!0),x("singleCursorHeightPerLine",!0,Jo,!0),x("workTime",100),x("workDelay",100),x("flattenSpans",!0,ia,!0),x("addModeClass",!1,ia,!0),x("pollInterval",100),x("undoDepth",200,function(b,E){return b.doc.history.undoDepth=E}),x("historyEventDelay",1250),x("viewportMargin",10,function(b){return b.refresh()},!0),x("maxHighlightLength",1e4,ia,!0),x("moveInputWithCursor",!0,function(b,E){E||b.display.input.resetPosition()}),x("tabindex",null,function(b,E){return b.display.input.getField().tabIndex=E||""}),x("autofocus",null),x("direction","ltr",function(b,E){return b.doc.setDirection(E)},!0),x("phrases",null)}function Wu(a,y,x){var b=x&&x!=Wo;if(!y!=!b){var E=a.display.dragFunctions,re=y?Nt:qt;re(a.display.scroller,"dragstart",E.start),re(a.display.scroller,"dragenter",E.enter),re(a.display.scroller,"dragover",E.over),re(a.display.scroller,"dragleave",E.leave),re(a.display.scroller,"drop",E.drop)}}function Gu(a){a.options.lineWrapping?(me(a.display.wrapper,"CodeMirror-wrap"),a.display.sizer.style.minWidth="",a.display.sizerWidth=null):(je(a.display.wrapper,"CodeMirror-wrap"),Cr(a)),Ka(a),Ai(a),Co(a),setTimeout(function(){return No(a)},100)}function ei(a,y){var x=this;if(!(this instanceof ei))return new ei(a,y);this.options=y=y?Pt(y):{},Pt(ks,y,!1);var b=y.value;typeof b=="string"?b=new Ni(b,y.mode,null,y.lineSeparator,y.direction):y.mode&&(b.modeOption=y.mode),this.doc=b;var E=new ei.inputStyles[y.inputStyle](this),re=this.display=new ru(a,b,E,y);re.wrapper.CodeMirror=this,Ds(this),y.lineWrapping&&(this.display.wrapper.className+=" CodeMirror-wrap"),Ll(this),this.state={keyMaps:[],overlays:[],modeGen:0,overwrite:!1,delayingBlurEvent:!1,focused:!1,suppressEdits:!1,pasteIncoming:-1,cutIncoming:-1,selectingText:!1,draggingText:!1,highlight:new ce,keySeq:null,specialChars:null},y.autofocus&&!Ge&&re.input.focus(),ye&&be<11&&setTimeout(function(){return x.display.input.reset(!0)},20),Vu(this),wu(),Oo(this),this.curOp.forceUpdate=!0,jl(this,b),y.autofocus&&!Ge||this.hasFocus()?setTimeout(function(){x.hasFocus()&&!x.state.focused&&Ya(x)},20):Bo(this);for(var le in Ha)Ha.hasOwnProperty(le)&&Ha[le](this,y[le],Wo);Nl(this),y.finishInit&&y.finishInit(this);for(var ue=0;ue<vl.length;++ue)vl[ue](this);Mo(this),Me&&y.lineWrapping&&getComputedStyle(re.lineDiv).textRendering=="optimizelegibility"&&(re.lineDiv.style.textRendering="auto")}ei.defaults=ks,ei.optionHandlers=Ha;function Vu(a){var y=a.display;Nt(y.scroller,"mousedown",gi(a,Is)),ye&&be<11?Nt(y.scroller,"dblclick",gi(a,function(de){if(!ft(a,de)){var pe=wo(a,de);if(!(!pe||ml(a,de)||wi(a.display,de))){yn(de);var Ze=a.findWordAt(pe);Ba(a.doc,Ze.anchor,Ze.head)}}})):Nt(y.scroller,"dblclick",function(de){return ft(a,de)||yn(de)}),Nt(y.scroller,"contextmenu",function(de){return Ps(a,de)}),Nt(y.input.getField(),"contextmenu",function(de){y.scroller.contains(de.target)||Ps(a,de)});var x,b={end:0};function E(){y.activeTouch&&(x=setTimeout(function(){return y.activeTouch=null},1e3),b=y.activeTouch,b.end=+new Date)}function re(de){if(de.touches.length!=1)return!1;var pe=de.touches[0];return pe.radiusX<=1&&pe.radiusY<=1}function le(de,pe){if(pe.left==null)return!0;var Ze=pe.left-de.left,Ye=pe.top-de.top;return Ze*Ze+Ye*Ye>20*20}Nt(y.scroller,"touchstart",function(de){if(!ft(a,de)&&!re(de)&&!ml(a,de)){y.input.ensurePolled(),clearTimeout(x);var pe=+new Date;y.activeTouch={start:pe,moved:!1,prev:pe-b.end<=300?b:null},de.touches.length==1&&(y.activeTouch.left=de.touches[0].pageX,y.activeTouch.top=de.touches[0].pageY)}}),Nt(y.scroller,"touchmove",function(){y.activeTouch&&(y.activeTouch.moved=!0)}),Nt(y.scroller,"touchend",function(de){var pe=y.activeTouch;if(pe&&!wi(y,de)&&pe.left!=null&&!pe.moved&&new Date-pe.start<300){var Ze=a.coordsChar(y.activeTouch,"page"),Ye;!pe.prev||le(pe,pe.prev)?Ye=new Vr(Ze,Ze):!pe.prev.prev||le(pe,pe.prev.prev)?Ye=a.findWordAt(Ze):Ye=new Vr(we(Ze.line,0),Ct(a.doc,we(Ze.line+1,0))),a.setSelection(Ye.anchor,Ye.head),a.focus(),yn(de)}E()}),Nt(y.scroller,"touchcancel",E),Nt(y.scroller,"scroll",function(){y.scroller.clientHeight&&(qo(a,y.scroller.scrollTop),Eo(a,y.scroller.scrollLeft,!0),on(a,"scroll",a))}),Nt(y.scroller,"mousewheel",function(de){return zl(a,de)}),Nt(y.scroller,"DOMMouseScroll",function(de){return zl(a,de)}),Nt(y.wrapper,"scroll",function(){return y.wrapper.scrollTop=y.wrapper.scrollLeft=0}),y.dragFunctions={enter:function(de){ft(a,de)||Pe(de)},over:function(de){ft(a,de)||(Cu(a,de),Pe(de))},start:function(de){return xu(a,de)},drop:gi(a,bu),leave:function(de){ft(a,de)||fs(a)}};var ue=y.input.getField();Nt(ue,"keyup",function(de){return Ss.call(a,de)}),Nt(ue,"keydown",gi(a,ws)),Nt(ue,"keypress",gi(a,Es)),Nt(ue,"focus",function(de){return Ya(a,de)}),Nt(ue,"blur",function(de){return Bo(a,de)})}var vl=[];ei.defineInitHook=function(a){return vl.push(a)};function ga(a,y,x,b){var E=a.doc,re;x==null&&(x="add"),x=="smart"&&(E.mode.indent?re=gt(a,y).state:x="prev");var le=a.options.tabSize,ue=Dt(E,y),de=ge(ue.text,null,le);ue.stateAfter&&(ue.stateAfter=null);var pe=ue.text.match(/^\s*/)[0],Ze;if(!b&&!/\S/.test(ue.text))Ze=0,x="not";else if(x=="smart"&&(Ze=E.mode.indent(re,ue.text.slice(pe.length),ue.text),Ze==wt||Ze>150)){if(!b)return;x="prev"}x=="prev"?y>E.first?Ze=ge(Dt(E,y-1).text,null,le):Ze=0:x=="add"?Ze=de+a.options.indentUnit:x=="subtract"?Ze=de-a.options.indentUnit:typeof x=="number"&&(Ze=de+x),Ze=Math.max(0,Ze);var Ye="",Lt=0;if(a.options.indentWithTabs)for(var Mt=Math.floor(Ze/le);Mt;--Mt)Lt+=le,Ye+=" ";if(Lt<Ze&&(Ye+=Yt(Ze-Lt)),Ye!=pe)return $o(E,Ye,we(y,0),we(y,pe.length),"+input"),ue.stateAfter=null,!0;for(var vn=0;vn<E.sel.ranges.length;vn++){var Mn=E.sel.ranges[vn];if(Mn.head.line==y&&Mn.head.ch<pe.length){var Vn=we(y,pe.length);ul(E,vn,new Vr(Vn,Vn));break}}}var eo=null;function Za(a){eo=a}function gl(a,y,x,b,E){var re=a.doc;a.display.shift=!1,b||(b=re.sel);var le=+new Date-200,ue=E=="paste"||a.state.pasteIncoming>le,de=Cn(y),pe=null;if(ue&&b.ranges.length>1)if(eo&&eo.text.join(`
|
|
|
`)==y){if(b.ranges.length%eo.text.length==0){pe=[];for(var Ze=0;Ze<eo.text.length;Ze++)pe.push(re.splitLines(eo.text[Ze]))}}else de.length==b.ranges.length&&a.options.pasteLinesPerSelection&&(pe=zt(de,function(tr){return[tr]}));for(var Ye=a.curOp.updateInput,Lt=b.ranges.length-1;Lt>=0;Lt--){var Mt=b.ranges[Lt],vn=Mt.from(),Mn=Mt.to();Mt.empty()&&(x&&x>0?vn=we(vn.line,vn.ch-x):a.state.overwrite&&!ue?Mn=we(Mn.line,Math.min(Dt(re,Mn.line).text.length,Mn.ch+ze(de).length)):ue&&eo&&eo.lineWise&&eo.text.join(`
|
|
|
`)==de.join(`
|
|
|
`)&&(vn=Mn=we(vn.line,0)));var Vn={from:vn,to:Mn,text:pe?pe[Lt%pe.length]:de,origin:E||(ue?"paste":a.state.cutIncoming>le?"cut":"+input")};zo(a.doc,Vn),_r(a,"inputRead",a,Vn)}y&&!ue&&Ls(a,y),Ao(a),a.curOp.updateInput<2&&(a.curOp.updateInput=Ye),a.curOp.typing=!0,a.state.pasteIncoming=a.state.cutIncoming=-1}function Ts(a,y){var x=a.clipboardData&&a.clipboardData.getData("Text");if(x)return a.preventDefault(),!y.isReadOnly()&&!y.options.disableInput&&ji(y,function(){return gl(y,x,0,null,"paste")}),!0}function Ls(a,y){if(!(!a.options.electricChars||!a.options.smartIndent))for(var x=a.doc.sel,b=x.ranges.length-1;b>=0;b--){var E=x.ranges[b];if(!(E.head.ch>100||b&&x.ranges[b-1].head.line==E.head.line)){var re=a.getModeAt(E.head),le=!1;if(re.electricChars){for(var ue=0;ue<re.electricChars.length;ue++)if(y.indexOf(re.electricChars.charAt(ue))>-1){le=ga(a,E.head.line,"smart");break}}else re.electricInput&&re.electricInput.test(Dt(a.doc,E.head.line).text.slice(0,E.head.ch))&&(le=ga(a,E.head.line,"smart"));le&&_r(a,"electricInput",a,E.head.line)}}}function Bs(a){for(var y=[],x=[],b=0;b<a.doc.sel.ranges.length;b++){var E=a.doc.sel.ranges[b].head.line,re={anchor:we(E,0),head:we(E+1,0)};x.push(re),y.push(a.getRange(re.anchor,re.head))}return{text:y,ranges:x}}function As(a,y,x,b){a.setAttribute("autocorrect",x?"":"off"),a.setAttribute("autocapitalize",b?"":"off"),a.setAttribute("spellcheck",!!y)}function Ns(){var a=tt("textarea",null,null,"position: absolute; bottom: -1em; padding: 0; width: 1px; height: 1em; outline: none"),y=tt("div",[a],null,"overflow: hidden; position: relative; width: 3px; height: 0px;");return Me?a.style.width="1000px":a.setAttribute("wrap","off"),Xe&&(a.style.border="1px solid black"),As(a),y}function Uu(a){var y=a.optionHandlers,x=a.helpers={};a.prototype={constructor:a,focus:function(){window.focus(),this.display.input.focus()},setOption:function(b,E){var re=this.options,le=re[b];re[b]==E&&b!="mode"||(re[b]=E,y.hasOwnProperty(b)&&gi(this,y[b])(this,E,le),on(this,"optionChange",this,b))},getOption:function(b){return this.options[b]},getDoc:function(){return this.doc},addKeyMap:function(b,E){this.state.keyMaps[E?"push":"unshift"](za(b))},removeKeyMap:function(b){for(var E=this.state.keyMaps,re=0;re<E.length;++re)if(E[re]==b||E[re].name==b)return E.splice(re,1),!0},addOverlay:Ti(function(b,E){var re=b.token?b:a.getMode(this.options,b);if(re.startState)throw new Error("Overlays may not be stateful.");ut(this.state.overlays,{mode:re,modeSpec:b,opaque:E&&E.opaque,priority:E&&E.priority||0},function(le){return le.priority}),this.state.modeGen++,Ai(this)}),removeOverlay:Ti(function(b){for(var E=this.state.overlays,re=0;re<E.length;++re){var le=E[re].modeSpec;if(le==b||typeof b=="string"&&le.name==b){E.splice(re,1),this.state.modeGen++,Ai(this);return}}}),indentLine:Ti(function(b,E,re){typeof E!="string"&&typeof E!="number"&&(E==null?E=this.options.smartIndent?"smart":"prev":E=E?"add":"subtract"),Ce(this.doc,b)&&ga(this,b,E,re)}),indentSelection:Ti(function(b){for(var E=this.doc.sel.ranges,re=-1,le=0;le<E.length;le++){var ue=E[le];if(ue.empty())ue.head.line>re&&(ga(this,ue.head.line,b,!0),re=ue.head.line,le==this.doc.sel.primIndex&&Ao(this));else{var de=ue.from(),pe=ue.to(),Ze=Math.max(re,de.line);re=Math.min(this.lastLine(),pe.line-(pe.ch?0:1))+1;for(var Ye=Ze;Ye<re;++Ye)ga(this,Ye,b);var Lt=this.doc.sel.ranges;de.ch==0&&E.length==Lt.length&&Lt[le].from().ch>0&&ul(this.doc,le,new Vr(de,Lt[le].to()),Ie)}}}),getTokenAt:function(b,E){return hn(this,b,E)},getLineTokens:function(b,E){return hn(this,we(b),E,!0)},getTokenTypeAt:function(b){b=Ct(this.doc,b);var E=pr(this,Dt(this.doc,b.line)),re=0,le=(E.length-1)/2,ue=b.ch,de;if(ue==0)de=E[2];else for(;;){var pe=re+le>>1;if((pe?E[pe*2-1]:0)>=ue)le=pe;else if(E[pe*2+1]<ue)re=pe+1;else{de=E[pe*2+2];break}}var Ze=de?de.indexOf("overlay "):-1;return Ze<0?de:Ze==0?null:de.slice(0,Ze-1)},getModeAt:function(b){var E=this.doc.mode;return E.innerMode?a.innerMode(E,this.getTokenAt(b).state).mode:E},getHelper:function(b,E){return this.getHelpers(b,E)[0]},getHelpers:function(b,E){var re=[];if(!x.hasOwnProperty(E))return re;var le=x[E],ue=this.getModeAt(b);if(typeof ue[E]=="string")le[ue[E]]&&re.push(le[ue[E]]);else if(ue[E])for(var de=0;de<ue[E].length;de++){var pe=le[ue[E][de]];pe&&re.push(pe)}else ue.helperType&&le[ue.helperType]?re.push(le[ue.helperType]):le[ue.name]&&re.push(le[ue.name]);for(var Ze=0;Ze<le._global.length;Ze++){var Ye=le._global[Ze];Ye.pred(ue,this)&&Je(re,Ye.val)==-1&&re.push(Ye.val)}return re},getStateAfter:function(b,E){var re=this.doc;return b=Ht(re,b==null?re.first+re.size-1:b),gt(this,b+1,E).state},cursorCoords:function(b,E){var re,le=this.doc.sel.primary();return b==null?re=le.head:typeof b=="object"?re=Ct(this.doc,b):re=b?le.from():le.to(),Bi(this,re,E||"page")},charCoords:function(b,E){return Lo(this,Ct(this.doc,b),E||"page")},coordsChar:function(b,E){return b=Sa(this,b,E||"page"),Si(this,b.left,b.top)},lineAtHeight:function(b,E){return b=Sa(this,{top:b,left:0},E||"page").top,_e(this.doc,b+this.display.viewOffset)},heightAtLine:function(b,E,re){var le=!1,ue;if(typeof b=="number"){var de=this.doc.first+this.doc.size-1;b<this.doc.first?b=this.doc.first:b>de&&(b=de,le=!0),ue=Dt(this.doc,b)}else ue=b;return To(this,ue,{top:0,left:0},E||"page",re||le).top+(le?this.doc.height-yr(ue):0)},defaultTextHeight:function(){return Zi(this.display)},defaultCharWidth:function(){return Qi(this.display)},getViewport:function(){return{from:this.display.viewFrom,to:this.display.viewTo}},addWidget:function(b,E,re,le,ue){var de=this.display;b=Bi(this,Ct(this.doc,b));var pe=b.bottom,Ze=b.left;if(E.style.position="absolute",E.setAttribute("cm-ignore-events","true"),this.display.input.setUneditable(E),de.sizer.appendChild(E),le=="over")pe=b.top;else if(le=="above"||le=="near"){var Ye=Math.max(de.wrapper.clientHeight,this.doc.height),Lt=Math.max(de.sizer.clientWidth,de.lineSpace.clientWidth);(le=="above"||b.bottom+E.offsetHeight>Ye)&&b.top>E.offsetHeight?pe=b.top-E.offsetHeight:b.bottom+E.offsetHeight<=Ye&&(pe=b.bottom),Ze+E.offsetWidth>Lt&&(Ze=Lt-E.offsetWidth)}E.style.top=pe+"px",E.style.left=E.style.right="",ue=="right"?(Ze=de.sizer.clientWidth-E.offsetWidth,E.style.right="0px"):(ue=="left"?Ze=0:ue=="middle"&&(Ze=(de.sizer.clientWidth-E.offsetWidth)/2),E.style.left=Ze+"px"),re&&Ws(this,{left:Ze,top:pe,right:Ze+E.offsetWidth,bottom:pe+E.offsetHeight})},triggerOnKeyDown:Ti(ws),triggerOnKeyPress:Ti(Es),triggerOnKeyUp:Ss,triggerOnMouseDown:Ti(Is),execCommand:function(b){if(ha.hasOwnProperty(b))return ha[b].call(null,this)},triggerElectric:Ti(function(b){Ls(this,b)}),findPosH:function(b,E,re,le){var ue=1;E<0&&(ue=-1,E=-E);for(var de=Ct(this.doc,b),pe=0;pe<E&&(de=yl(this.doc,de,ue,re,le),!de.hitSide);++pe);return de},moveH:Ti(function(b,E){var re=this;this.extendSelectionsBy(function(le){return re.display.shift||re.doc.extend||le.empty()?yl(re.doc,le.head,b,E,re.options.rtlMoveVisually):b<0?le.from():le.to()},et)}),deleteH:Ti(function(b,E){var re=this.doc.sel,le=this.doc;re.somethingSelected()?le.replaceSelection("",null,"+delete"):jo(this,function(ue){var de=yl(le,ue.head,b,E,!1);return b<0?{from:de,to:ue.head}:{from:ue.head,to:de}})}),findPosV:function(b,E,re,le){var ue=1,de=le;E<0&&(ue=-1,E=-E);for(var pe=Ct(this.doc,b),Ze=0;Ze<E;++Ze){var Ye=Bi(this,pe,"div");if(de==null?de=Ye.left:Ye.left=de,pe=Rs(this,Ye,ue,re),pe.hitSide)break}return pe},moveV:Ti(function(b,E){var re=this,le=this.doc,ue=[],de=!this.display.shift&&!le.extend&&le.sel.somethingSelected();if(le.extendSelectionsBy(function(Ze){if(de)return b<0?Ze.from():Ze.to();var Ye=Bi(re,Ze.head,"div");Ze.goalColumn!=null&&(Ye.left=Ze.goalColumn),ue.push(Ye.left);var Lt=Rs(re,Ye,b,E);return E=="page"&&Ze==le.sel.primary()&&Qa(re,Lo(re,Lt,"div").top-Ye.top),Lt},et),ue.length)for(var pe=0;pe<le.sel.ranges.length;pe++)le.sel.ranges[pe].goalColumn=ue[pe]}),findWordAt:function(b){var E=this.doc,re=Dt(E,b.line).text,le=b.ch,ue=b.ch;if(re){var de=this.getHelper(b,"wordChars");(b.sticky=="before"||ue==re.length)&&le?--le:++ue;for(var pe=re.charAt(le),Ze=se(pe,de)?function(Ye){return se(Ye,de)}:/\s/.test(pe)?function(Ye){return/\s/.test(Ye)}:function(Ye){return!/\s/.test(Ye)&&!se(Ye)};le>0&&Ze(re.charAt(le-1));)--le;for(;ue<re.length&&Ze(re.charAt(ue));)++ue}return new Vr(we(b.line,le),we(b.line,ue))},toggleOverwrite:function(b){b!=null&&b==this.state.overwrite||((this.state.overwrite=!this.state.overwrite)?me(this.display.cursorDiv,"CodeMirror-overwrite"):je(this.display.cursorDiv,"CodeMirror-overwrite"),on(this,"overwriteToggle",this,this.state.overwrite))},hasFocus:function(){return this.display.input.getField()==lt()},isReadOnly:function(){return!!(this.options.readOnly||this.doc.cantEdit)},scrollTo:Ti(function(b,E){Qo(this,b,E)}),getScrollInfo:function(){var b=this.display.scroller;return{left:b.scrollLeft,top:b.scrollTop,height:b.scrollHeight-$i(this)-this.display.barHeight,width:b.scrollWidth-$i(this)-this.display.barWidth,clientHeight:ao(this),clientWidth:ro(this)}},scrollIntoView:Ti(function(b,E){b==null?(b={from:this.doc.sel.primary().head,to:null},E==null&&(E=this.options.cursorScrollMargin)):typeof b=="number"?b={from:we(b,0),to:null}:b.from==null&&(b={from:b,to:null}),b.to||(b.to=b.from),b.margin=E||0,b.from.line!=null?Gs(this,b):Pl(this,b.from,b.to,b.margin)}),setSize:Ti(function(b,E){var re=this,le=function(de){return typeof de=="number"||/^\d+$/.test(String(de))?de+"px":de};b!=null&&(this.display.wrapper.style.width=le(b)),E!=null&&(this.display.wrapper.style.height=le(E)),this.options.lineWrapping&&Ko(this);var ue=this.display.viewFrom;this.doc.iter(ue,this.display.viewTo,function(de){if(de.widgets){for(var pe=0;pe<de.widgets.length;pe++)if(de.widgets[pe].noHScroll){ho(re,ue,"widget");break}}++ue}),this.curOp.forceUpdate=!0,on(this,"refresh",this)}),operation:function(b){return ji(this,b)},startOperation:function(){return Oo(this)},endOperation:function(){return Mo(this)},refresh:Ti(function(){var b=this.display.cachedTextHeight;Ai(this),this.curOp.forceUpdate=!0,Co(this),Qo(this,this.doc.scrollLeft,this.doc.scrollTop),tl(this.display),(b==null||Math.abs(b-Zi(this.display))>.5||this.options.lineWrapping)&&Ka(this),on(this,"refresh",this)}),swapDoc:Ti(function(b){var E=this.doc;return E.cm=null,this.state.selectingText&&this.state.selectingText(),jl(this,b),Co(this),this.display.input.reset(),Qo(this,b.scrollLeft,b.scrollTop),this.curOp.forceScroll=!0,_r(this,"swapDoc",this,E),E}),phrase:function(b){var E=this.options.phrases;return E&&Object.prototype.hasOwnProperty.call(E,b)?E[b]:b},getInputField:function(){return this.display.input.getField()},getWrapperElement:function(){return this.display.wrapper},getScrollerElement:function(){return this.display.scroller},getGutterElement:function(){return this.display.gutters}},en(a),a.registerHelper=function(b,E,re){x.hasOwnProperty(b)||(x[b]=a[b]={_global:[]}),x[b][E]=re},a.registerGlobalHelper=function(b,E,re,le){a.registerHelper(b,E,le),x[b]._global.push({pred:re,val:le})}}function yl(a,y,x,b,E){var re=y,le=x,ue=Dt(a,y.line),de=E&&a.direction=="rtl"?-x:x;function pe(){var ur=y.line+de;return ur<a.first||ur>=a.first+a.size?!1:(y=new we(ur,y.ch,y.sticky),ue=Dt(a,ur))}function Ze(ur){var nr;if(b=="codepoint"){var gr=ue.text.charCodeAt(y.ch+(b>0?0:-1));isNaN(gr)?nr=null:nr=new we(y.line,Math.max(0,Math.min(ue.text.length,y.ch+x*(gr>=55296&&gr<56320?2:1))),-x)}else E?nr=Mu(a.cm,ue,y,x):nr=dl(ue,y,x);if(nr==null)if(!ur&&pe())y=fl(E,a.cm,ue,y.line,de);else return!1;else y=nr;return!0}if(b=="char"||b=="codepoint")Ze();else if(b=="column")Ze(!0);else if(b=="word"||b=="group")for(var Ye=null,Lt=b=="group",Mt=a.cm&&a.cm.getHelper(y,"wordChars"),vn=!0;!(x<0&&!Ze(!vn));vn=!1){var Mn=ue.text.charAt(y.ch)||`
|
|
|
`,Vn=se(Mn,Mt)?"w":Lt&&Mn==`
|
|
|
`?"n":!Lt||/\s/.test(Mn)?null:"p";if(Lt&&!vn&&!Vn&&(Vn="s"),Ye&&Ye!=Vn){x<0&&(x=1,Ze(),y.sticky="after");break}if(Vn&&(Ye=Vn),x>0&&!Ze(!vn))break}var tr=Na(a,y,re,le,!0);return Qe(re,tr)&&(tr.hitSide=!0),tr}function Rs(a,y,x,b){var E=a.doc,re=y.left,le;if(b=="page"){var ue=Math.min(a.display.wrapper.clientHeight,window.innerHeight||document.documentElement.clientHeight),de=Math.max(ue-.5*Zi(a.display),3);le=(x>0?y.bottom:y.top)+x*de}else b=="line"&&(le=x>0?y.bottom+3:y.top-3);for(var pe;pe=Si(a,re,le),!!pe.outside;){if(x<0?le<=0:le>=E.height){pe.hitSide=!0;break}le+=x*5}return pe}var Kr=function(a){this.cm=a,this.lastAnchorNode=this.lastAnchorOffset=this.lastFocusNode=this.lastFocusOffset=null,this.polling=new ce,this.composing=null,this.gracePeriod=!1,this.readDOMTimeout=null};Kr.prototype.init=function(a){var y=this,x=this,b=x.cm,E=x.div=a.lineDiv;As(E,b.options.spellcheck,b.options.autocorrect,b.options.autocapitalize);function re(ue){for(var de=ue.target;de;de=de.parentNode){if(de==E)return!0;if(/\bCodeMirror-(?:line)?widget\b/.test(de.className))break}return!1}Nt(E,"paste",function(ue){!re(ue)||ft(b,ue)||Ts(ue,b)||be<=11&&setTimeout(gi(b,function(){return y.updateFromDOM()}),20)}),Nt(E,"compositionstart",function(ue){y.composing={data:ue.data,done:!1}}),Nt(E,"compositionupdate",function(ue){y.composing||(y.composing={data:ue.data,done:!1})}),Nt(E,"compositionend",function(ue){y.composing&&(ue.data!=y.composing.data&&y.readFromDOMSoon(),y.composing.done=!0)}),Nt(E,"touchstart",function(){return x.forceCompositionEnd()}),Nt(E,"input",function(){y.composing||y.readFromDOMSoon()});function le(ue){if(!(!re(ue)||ft(b,ue))){if(b.somethingSelected())Za({lineWise:!1,text:b.getSelections()}),ue.type=="cut"&&b.replaceSelection("",null,"cut");else if(b.options.lineWiseCopyCut){var de=Bs(b);Za({lineWise:!0,text:de.text}),ue.type=="cut"&&b.operation(function(){b.setSelections(de.ranges,0,Ie),b.replaceSelection("",null,"cut")})}else return;if(ue.clipboardData){ue.clipboardData.clearData();var pe=eo.text.join(`
|
|
|
`);if(ue.clipboardData.setData("Text",pe),ue.clipboardData.getData("Text")==pe){ue.preventDefault();return}}var Ze=Ns(),Ye=Ze.firstChild;b.display.lineSpace.insertBefore(Ze,b.display.lineSpace.firstChild),Ye.value=eo.text.join(`
|
|
|
`);var Lt=document.activeElement;De(Ye),setTimeout(function(){b.display.lineSpace.removeChild(Ze),Lt.focus(),Lt==E&&x.showPrimarySelection()},50)}}Nt(E,"copy",le),Nt(E,"cut",le)},Kr.prototype.screenReaderLabelChanged=function(a){a?this.div.setAttribute("aria-label",a):this.div.removeAttribute("aria-label")},Kr.prototype.prepareSelection=function(){var a=Sl(this.cm,!1);return a.focus=document.activeElement==this.div,a},Kr.prototype.showSelection=function(a,y){!a||!this.cm.display.view.length||((a.focus||y)&&this.showPrimarySelection(),this.showMultipleSelections(a))},Kr.prototype.getSelection=function(){return this.cm.display.wrapper.ownerDocument.getSelection()},Kr.prototype.showPrimarySelection=function(){var a=this.getSelection(),y=this.cm,x=y.doc.sel.primary(),b=x.from(),E=x.to();if(y.display.viewTo==y.display.viewFrom||b.line>=y.display.viewTo||E.line<y.display.viewFrom){a.removeAllRanges();return}var re=ja(y,a.anchorNode,a.anchorOffset),le=ja(y,a.focusNode,a.focusOffset);if(!(re&&!re.bad&&le&&!le.bad&&Te(Xt(re,le),b)==0&&Te(sn(re,le),E)==0)){var ue=y.display.view,de=b.line>=y.display.viewFrom&&Fs(y,b)||{node:ue[0].measure.map[2],offset:0},pe=E.line<y.display.viewTo&&Fs(y,E);if(!pe){var Ze=ue[ue.length-1].measure,Ye=Ze.maps?Ze.maps[Ze.maps.length-1]:Ze.map;pe={node:Ye[Ye.length-1],offset:Ye[Ye.length-2]-Ye[Ye.length-3]}}if(!de||!pe){a.removeAllRanges();return}var Lt=a.rangeCount&&a.getRangeAt(0),Mt;try{Mt=$e(de.node,de.offset,pe.offset,pe.node)}catch(vn){}Mt&&(!z&&y.state.focused?(a.collapse(de.node,de.offset),Mt.collapsed||(a.removeAllRanges(),a.addRange(Mt))):(a.removeAllRanges(),a.addRange(Mt)),Lt&&a.anchorNode==null?a.addRange(Lt):z&&this.startGracePeriod()),this.rememberSelection()}},Kr.prototype.startGracePeriod=function(){var a=this;clearTimeout(this.gracePeriod),this.gracePeriod=setTimeout(function(){a.gracePeriod=!1,a.selectionChanged()&&a.cm.operation(function(){return a.cm.curOp.selectionChanged=!0})},20)},Kr.prototype.showMultipleSelections=function(a){nt(this.cm.display.cursorDiv,a.cursors),nt(this.cm.display.selectionDiv,a.selection)},Kr.prototype.rememberSelection=function(){var a=this.getSelection();this.lastAnchorNode=a.anchorNode,this.lastAnchorOffset=a.anchorOffset,this.lastFocusNode=a.focusNode,this.lastFocusOffset=a.focusOffset},Kr.prototype.selectionInEditor=function(){var a=this.getSelection();if(!a.rangeCount)return!1;var y=a.getRangeAt(0).commonAncestorContainer;return at(this.div,y)},Kr.prototype.focus=function(){this.cm.options.readOnly!="nocursor"&&((!this.selectionInEditor()||document.activeElement!=this.div)&&this.showSelection(this.prepareSelection(),!0),this.div.focus())},Kr.prototype.blur=function(){this.div.blur()},Kr.prototype.getField=function(){return this.div},Kr.prototype.supportsTouch=function(){return!0},Kr.prototype.receivedFocus=function(){var a=this;this.selectionInEditor()?this.pollSelection():ji(this.cm,function(){return a.cm.curOp.selectionChanged=!0});function y(){a.cm.state.focused&&(a.pollSelection(),a.polling.set(a.cm.options.pollInterval,y))}this.polling.set(this.cm.options.pollInterval,y)},Kr.prototype.selectionChanged=function(){var a=this.getSelection();return a.anchorNode!=this.lastAnchorNode||a.anchorOffset!=this.lastAnchorOffset||a.focusNode!=this.lastFocusNode||a.focusOffset!=this.lastFocusOffset},Kr.prototype.pollSelection=function(){if(!(this.readDOMTimeout!=null||this.gracePeriod||!this.selectionChanged())){var a=this.getSelection(),y=this.cm;if(Le&&Oe&&this.cm.display.gutterSpecs.length&&_u(a.anchorNode)){this.cm.triggerOnKeyDown({type:"keydown",keyCode:8,preventDefault:Math.abs}),this.blur(),this.focus();return}if(!this.composing){this.rememberSelection();var x=ja(y,a.anchorNode,a.anchorOffset),b=ja(y,a.focusNode,a.focusOffset);x&&b&&ji(y,function(){Pi(y.doc,mo(x,b),Ie),(x.bad||b.bad)&&(y.curOp.selectionChanged=!0)})}}},Kr.prototype.pollContent=function(){this.readDOMTimeout!=null&&(clearTimeout(this.readDOMTimeout),this.readDOMTimeout=null);var a=this.cm,y=a.display,x=a.doc.sel.primary(),b=x.from(),E=x.to();if(b.ch==0&&b.line>a.firstLine()&&(b=we(b.line-1,Dt(a.doc,b.line-1).length)),E.ch==Dt(a.doc,E.line).text.length&&E.line<a.lastLine()&&(E=we(E.line+1,0)),b.line<y.viewFrom||E.line>y.viewTo-1)return!1;var re,le,ue;b.line==y.viewFrom||(re=So(a,b.line))==0?(le=ke(y.view[0].line),ue=y.view[0].node):(le=ke(y.view[re].line),ue=y.view[re-1].node.nextSibling);var de=So(a,E.line),pe,Ze;if(de==y.view.length-1?(pe=y.viewTo-1,Ze=y.lineDiv.lastChild):(pe=ke(y.view[de+1].line)-1,Ze=y.view[de+1].node.previousSibling),!ue)return!1;for(var Ye=a.doc.splitLines(Ku(a,ue,Ze,le,pe)),Lt=Qt(a.doc,we(le,0),we(pe,Dt(a.doc,pe).text.length));Ye.length>1&&Lt.length>1;)if(ze(Ye)==ze(Lt))Ye.pop(),Lt.pop(),pe--;else if(Ye[0]==Lt[0])Ye.shift(),Lt.shift(),le++;else break;for(var Mt=0,vn=0,Mn=Ye[0],Vn=Lt[0],tr=Math.min(Mn.length,Vn.length);Mt<tr&&Mn.charCodeAt(Mt)==Vn.charCodeAt(Mt);)++Mt;for(var ur=ze(Ye),nr=ze(Lt),gr=Math.min(ur.length-(Ye.length==1?Mt:0),nr.length-(Lt.length==1?Mt:0));vn<gr&&ur.charCodeAt(ur.length-vn-1)==nr.charCodeAt(nr.length-vn-1);)++vn;if(Ye.length==1&&Lt.length==1&&le==b.line)for(;Mt&&Mt>b.ch&&ur.charCodeAt(ur.length-vn-1)==nr.charCodeAt(nr.length-vn-1);)Mt--,vn++;Ye[Ye.length-1]=ur.slice(0,ur.length-vn).replace(/^\u200b+/,""),Ye[0]=Ye[0].slice(Mt).replace(/\u200b+$/,"");var Ir=we(le,Mt),Er=we(pe,Lt.length?ze(Lt).length-vn:0);if(Ye.length>1||Ye[0]||Te(Ir,Er))return $o(a.doc,Ye,Ir,Er,"+input"),!0},Kr.prototype.ensurePolled=function(){this.forceCompositionEnd()},Kr.prototype.reset=function(){this.forceCompositionEnd()},Kr.prototype.forceCompositionEnd=function(){this.composing&&(clearTimeout(this.readDOMTimeout),this.composing=null,this.updateFromDOM(),this.div.blur(),this.div.focus())},Kr.prototype.readFromDOMSoon=function(){var a=this;this.readDOMTimeout==null&&(this.readDOMTimeout=setTimeout(function(){if(a.readDOMTimeout=null,a.composing)if(a.composing.done)a.composing=null;else return;a.updateFromDOM()},80))},Kr.prototype.updateFromDOM=function(){var a=this;(this.cm.isReadOnly()||!this.pollContent())&&ji(this.cm,function(){return Ai(a.cm)})},Kr.prototype.setUneditable=function(a){a.contentEditable="false"},Kr.prototype.onKeyPress=function(a){a.charCode==0||this.composing||(a.preventDefault(),this.cm.isReadOnly()||gi(this.cm,gl)(this.cm,String.fromCharCode(a.charCode==null?a.keyCode:a.charCode),0))},Kr.prototype.readOnlyChanged=function(a){this.div.contentEditable=String(a!="nocursor")},Kr.prototype.onContextMenu=function(){},Kr.prototype.resetPosition=function(){},Kr.prototype.needsContentAttribute=!0;function Fs(a,y){var x=io(a,y.line);if(!x||x.hidden)return null;var b=Dt(a.doc,y.line),E=ko(x,b,y.line),re=Kt(b,a.doc.direction),le="left";if(re){var ue=bt(re,y.ch);le=ue%2?"right":"left"}var de=xa(E.map,y.ch,le);return de.offset=de.collapse=="right"?de.end:de.start,de}function _u(a){for(var y=a;y;y=y.parentNode)if(/CodeMirror-gutter-wrapper/.test(y.className))return!0;return!1}function Go(a,y){return y&&(a.bad=!0),a}function Ku(a,y,x,b,E){var re="",le=!1,ue=a.doc.lineSeparator(),de=!1;function pe(Mt){return function(vn){return vn.id==Mt}}function Ze(){le&&(re+=ue,de&&(re+=ue),le=de=!1)}function Ye(Mt){Mt&&(Ze(),re+=Mt)}function Lt(Mt){if(Mt.nodeType==1){var vn=Mt.getAttribute("cm-text");if(vn){Ye(vn);return}var Mn=Mt.getAttribute("cm-marker"),Vn;if(Mn){var tr=a.findMarks(we(b,0),we(E+1,0),pe(+Mn));tr.length&&(Vn=tr[0].find(0))&&Ye(Qt(a.doc,Vn.from,Vn.to).join(ue));return}if(Mt.getAttribute("contenteditable")=="false")return;var ur=/^(pre|div|p|li|table|br)$/i.test(Mt.nodeName);if(!/^br$/i.test(Mt.nodeName)&&Mt.textContent.length==0)return;ur&&Ze();for(var nr=0;nr<Mt.childNodes.length;nr++)Lt(Mt.childNodes[nr]);/^(pre|p)$/i.test(Mt.nodeName)&&(de=!0),ur&&(le=!0)}else Mt.nodeType==3&&Ye(Mt.nodeValue.replace(/\u200b/g,"").replace(/\u00a0/g," "))}for(;Lt(y),y!=x;)y=y.nextSibling,de=!1;return re}function ja(a,y,x){var b;if(y==a.display.lineDiv){if(b=a.display.lineDiv.childNodes[x],!b)return Go(a.clipPos(we(a.display.viewTo-1)),!0);y=null,x=0}else for(b=y;;b=b.parentNode){if(!b||b==a.display.lineDiv)return null;if(b.parentNode&&b.parentNode==a.display.lineDiv)break}for(var E=0;E<a.display.view.length;E++){var re=a.display.view[E];if(re.node==b)return Xu(re,y,x)}}function Xu(a,y,x){var b=a.text.firstChild,E=!1;if(!y||!at(b,y))return Go(we(ke(a.line),0),!0);if(y==b&&(E=!0,y=b.childNodes[x],x=0,!y)){var re=a.rest?ze(a.rest):a.line;return Go(we(ke(re),re.text.length),E)}var le=y.nodeType==3?y:null,ue=y;for(!le&&y.childNodes.length==1&&y.firstChild.nodeType==3&&(le=y.firstChild,x&&(x=le.nodeValue.length));ue.parentNode!=b;)ue=ue.parentNode;var de=a.measure,pe=de.maps;function Ze(Vn,tr,ur){for(var nr=-1;nr<(pe?pe.length:0);nr++)for(var gr=nr<0?de.map:pe[nr],Ir=0;Ir<gr.length;Ir+=3){var Er=gr[Ir+2];if(Er==Vn||Er==tr){var zr=ke(nr<0?a.line:a.rest[nr]),Yr=gr[Ir]+ur;return(ur<0||Er!=Vn)&&(Yr=gr[Ir+(ur?1:0)]),we(zr,Yr)}}}var Ye=Ze(le,ue,x);if(Ye)return Go(Ye,E);for(var Lt=ue.nextSibling,Mt=le?le.nodeValue.length-x:0;Lt;Lt=Lt.nextSibling){if(Ye=Ze(Lt,Lt.firstChild,0),Ye)return Go(we(Ye.line,Ye.ch-Mt),E);Mt+=Lt.textContent.length}for(var vn=ue.previousSibling,Mn=x;vn;vn=vn.previousSibling){if(Ye=Ze(vn,vn.firstChild,-1),Ye)return Go(we(Ye.line,Ye.ch+Mn),E);Mn+=vn.textContent.length}}var ai=function(a){this.cm=a,this.prevInput="",this.pollingFast=!1,this.polling=new ce,this.hasSelection=!1,this.composing=null};ai.prototype.init=function(a){var y=this,x=this,b=this.cm;this.createField(a);var E=this.textarea;a.wrapper.insertBefore(this.wrapper,a.wrapper.firstChild),Xe&&(E.style.width="0px"),Nt(E,"input",function(){ye&&be>=9&&y.hasSelection&&(y.hasSelection=null),x.poll()}),Nt(E,"paste",function(le){ft(b,le)||Ts(le,b)||(b.state.pasteIncoming=+new Date,x.fastPoll())});function re(le){if(!ft(b,le)){if(b.somethingSelected())Za({lineWise:!1,text:b.getSelections()});else if(b.options.lineWiseCopyCut){var ue=Bs(b);Za({lineWise:!0,text:ue.text}),le.type=="cut"?b.setSelections(ue.ranges,null,Ie):(x.prevInput="",E.value=ue.text.join(`
|
|
|
`),De(E))}else return;le.type=="cut"&&(b.state.cutIncoming=+new Date)}}Nt(E,"cut",re),Nt(E,"copy",re),Nt(a.scroller,"paste",function(le){if(!(wi(a,le)||ft(b,le))){if(!E.dispatchEvent){b.state.pasteIncoming=+new Date,x.focus();return}var ue=new Event("paste");ue.clipboardData=le.clipboardData,E.dispatchEvent(ue)}}),Nt(a.lineSpace,"selectstart",function(le){wi(a,le)||yn(le)}),Nt(E,"compositionstart",function(){var le=b.getCursor("from");x.composing&&x.composing.range.clear(),x.composing={start:le,range:b.markText(le,b.getCursor("to"),{className:"CodeMirror-composing"})}}),Nt(E,"compositionend",function(){x.composing&&(x.poll(),x.composing.range.clear(),x.composing=null)})},ai.prototype.createField=function(a){this.wrapper=Ns(),this.textarea=this.wrapper.firstChild},ai.prototype.screenReaderLabelChanged=function(a){a?this.textarea.setAttribute("aria-label",a):this.textarea.removeAttribute("aria-label")},ai.prototype.prepareSelection=function(){var a=this.cm,y=a.display,x=a.doc,b=Sl(a);if(a.options.moveInputWithCursor){var E=Bi(a,x.sel.primary().head,"div"),re=y.wrapper.getBoundingClientRect(),le=y.lineDiv.getBoundingClientRect();b.teTop=Math.max(0,Math.min(y.wrapper.clientHeight-10,E.top+le.top-re.top)),b.teLeft=Math.max(0,Math.min(y.wrapper.clientWidth-10,E.left+le.left-re.left))}return b},ai.prototype.showSelection=function(a){var y=this.cm,x=y.display;nt(x.cursorDiv,a.cursors),nt(x.selectionDiv,a.selection),a.teTop!=null&&(this.wrapper.style.top=a.teTop+"px",this.wrapper.style.left=a.teLeft+"px")},ai.prototype.reset=function(a){if(!(this.contextMenuPending||this.composing)){var y=this.cm;if(y.somethingSelected()){this.prevInput="";var x=y.getSelection();this.textarea.value=x,y.state.focused&&De(this.textarea),ye&&be>=9&&(this.hasSelection=x)}else a||(this.prevInput=this.textarea.value="",ye&&be>=9&&(this.hasSelection=null))}},ai.prototype.getField=function(){return this.textarea},ai.prototype.supportsTouch=function(){return!1},ai.prototype.focus=function(){if(this.cm.options.readOnly!="nocursor"&&(!Ge||lt()!=this.textarea))try{this.textarea.focus()}catch(a){}},ai.prototype.blur=function(){this.textarea.blur()},ai.prototype.resetPosition=function(){this.wrapper.style.top=this.wrapper.style.left=0},ai.prototype.receivedFocus=function(){this.slowPoll()},ai.prototype.slowPoll=function(){var a=this;this.pollingFast||this.polling.set(this.cm.options.pollInterval,function(){a.poll(),a.cm.state.focused&&a.slowPoll()})},ai.prototype.fastPoll=function(){var a=!1,y=this;y.pollingFast=!0;function x(){var b=y.poll();!b&&!a?(a=!0,y.polling.set(60,x)):(y.pollingFast=!1,y.slowPoll())}y.polling.set(20,x)},ai.prototype.poll=function(){var a=this,y=this.cm,x=this.textarea,b=this.prevInput;if(this.contextMenuPending||!y.state.focused||Fn(x)&&!b&&!this.composing||y.isReadOnly()||y.options.disableInput||y.state.keySeq)return!1;var E=x.value;if(E==b&&!y.somethingSelected())return!1;if(ye&&be>=9&&this.hasSelection===E||Ne&&/[\uf700-\uf7ff]/.test(E))return y.display.input.reset(),!1;if(y.doc.sel==y.display.selForContextMenu){var re=E.charCodeAt(0);if(re==8203&&!b&&(b="\u200B"),re==8666)return this.reset(),this.cm.execCommand("undo")}for(var le=0,ue=Math.min(b.length,E.length);le<ue&&b.charCodeAt(le)==E.charCodeAt(le);)++le;return ji(y,function(){gl(y,E.slice(le),b.length-le,null,a.composing?"*compose":null),E.length>1e3||E.indexOf(`
|
|
|
`)>-1?x.value=a.prevInput="":a.prevInput=E,a.composing&&(a.composing.range.clear(),a.composing.range=y.markText(a.composing.start,y.getCursor("to"),{className:"CodeMirror-composing"}))}),!0},ai.prototype.ensurePolled=function(){this.pollingFast&&this.poll()&&(this.pollingFast=!1)},ai.prototype.onKeyPress=function(){ye&&be>=9&&(this.hasSelection=null),this.fastPoll()},ai.prototype.onContextMenu=function(a){var y=this,x=y.cm,b=x.display,E=y.textarea;y.contextMenuPending&&y.contextMenuPending();var re=wo(x,a),le=b.scroller.scrollTop;if(!re||fe)return;var ue=x.options.resetSelectionOnContextMenu;ue&&x.doc.sel.contains(re)==-1&&gi(x,Pi)(x.doc,mo(re),Ie);var de=E.style.cssText,pe=y.wrapper.style.cssText,Ze=y.wrapper.offsetParent.getBoundingClientRect();y.wrapper.style.cssText="position: static",E.style.cssText=`position: absolute; width: 30px; height: 30px;
|
|
|
top: `+(a.clientY-Ze.top-5)+"px; left: "+(a.clientX-Ze.left-5)+`px;
|
|
|
z-index: 1000; background: `+(ye?"rgba(255, 255, 255, .05)":"transparent")+`;
|
|
|
outline: none; border-width: 0; outline: none; overflow: hidden; opacity: .05; filter: alpha(opacity=5);`;var Ye;Me&&(Ye=window.scrollY),b.input.focus(),Me&&window.scrollTo(null,Ye),b.input.reset(),x.somethingSelected()||(E.value=y.prevInput=" "),y.contextMenuPending=Mt,b.selForContextMenu=x.doc.sel,clearTimeout(b.detectingSelectAll);function Lt(){if(E.selectionStart!=null){var Mn=x.somethingSelected(),Vn="\u200B"+(Mn?E.value:"");E.value="\u21DA",E.value=Vn,y.prevInput=Mn?"":"\u200B",E.selectionStart=1,E.selectionEnd=Vn.length,b.selForContextMenu=x.doc.sel}}function Mt(){if(y.contextMenuPending==Mt&&(y.contextMenuPending=!1,y.wrapper.style.cssText=pe,E.style.cssText=de,ye&&be<9&&b.scrollbars.setScrollTop(b.scroller.scrollTop=le),E.selectionStart!=null)){(!ye||ye&&be<9)&&Lt();var Mn=0,Vn=function(){b.selForContextMenu==x.doc.sel&&E.selectionStart==0&&E.selectionEnd>0&&y.prevInput=="\u200B"?gi(x,ts)(x):Mn++<10?b.detectingSelectAll=setTimeout(Vn,500):(b.selForContextMenu=null,b.input.reset())};b.detectingSelectAll=setTimeout(Vn,200)}}if(ye&&be>=9&&Lt(),st){Pe(a);var vn=function(){qt(window,"mouseup",vn),setTimeout(Mt,20)};Nt(window,"mouseup",vn)}else setTimeout(Mt,50)},ai.prototype.readOnlyChanged=function(a){a||this.reset(),this.textarea.disabled=a=="nocursor",this.textarea.readOnly=!!a},ai.prototype.setUneditable=function(){},ai.prototype.needsContentAttribute=!1;function Yu(a,y){if(y=y?Pt(y):{},y.value=a.value,!y.tabindex&&a.tabIndex&&(y.tabindex=a.tabIndex),!y.placeholder&&a.placeholder&&(y.placeholder=a.placeholder),y.autofocus==null){var x=lt();y.autofocus=x==a||a.getAttribute("autofocus")!=null&&x==document.body}function b(){a.value=ue.getValue()}var E;if(a.form&&(Nt(a.form,"submit",b),!y.leaveSubmitMethodAlone)){var re=a.form;E=re.submit;try{var le=re.submit=function(){b(),re.submit=E,re.submit(),re.submit=le}}catch(de){}}y.finishInit=function(de){de.save=b,de.getTextArea=function(){return a},de.toTextArea=function(){de.toTextArea=isNaN,b(),a.parentNode.removeChild(de.getWrapperElement()),a.style.display="",a.form&&(qt(a.form,"submit",b),!y.leaveSubmitMethodAlone&&typeof a.form.submit=="function"&&(a.form.submit=E))}},a.style.display="none";var ue=ei(function(de){return a.parentNode.insertBefore(de,a.nextSibling)},y);return ue}function Ju(a){a.off=qt,a.on=Nt,a.wheelEventPixels=iu,a.Doc=Ni,a.splitLines=Cn,a.countColumn=ge,a.findColumn=cn,a.isWordChar=oe,a.Pass=wt,a.signal=on,a.Line=Ar,a.changeEnd=vo,a.scrollbarModel=Tl,a.Pos=we,a.cmpPos=Te,a.modes=Vt,a.mimeModes=Ut,a.resolveMode=xn,a.getMode=wn,a.modeExtensions=Bn,a.extendMode=Zn,a.copyState=Yn,a.startState=ir,a.innerMode=Wn,a.commands=ha,a.keyMap=so,a.keyName=gs,a.isModifierKey=ms,a.lookupKey=Zo,a.normalizeKeyMap=Ou,a.StringStream=gn,a.SharedTextMarker=ca,a.TextMarker=yo,a.LineWidget=ua,a.e_preventDefault=yn,a.e_stopPropagation=Rn,a.e_stop=Pe,a.addClass=me,a.contains=at,a.rmClass=je,a.keyNames=bo}ju(ei),Uu(ei);var Qu="iter insert remove copy getEditor constructor".split(" ");for(var Wa in Ni.prototype)Ni.prototype.hasOwnProperty(Wa)&&Je(Qu,Wa)<0&&(ei.prototype[Wa]=function(a){return function(){return a.apply(this.doc,arguments)}}(Ni.prototype[Wa]));return en(Ni),ei.inputStyles={textarea:ai,contenteditable:Kr},ei.defineMode=function(a){!ei.defaults.mode&&a!="null"&&(ei.defaults.mode=a),En.apply(this,arguments)},ei.defineMIME=mn,ei.defineMode("null",function(){return{token:function(a){return a.skipToEnd()}}}),ei.defineMIME("text/plain","null"),ei.defineExtension=function(a,y){ei.prototype[a]=y},ei.defineDocExtension=function(a,y){Ni.prototype[a]=y},ei.fromTextArea=Yu,Ju(ei),ei.version="5.58.2",ei})},25419:function(ln,Ft,ie){(function(z){z(ie(89780),ie(15525),ie(98101))})(function(z){"use strict";z.defineMode("markdown",function(Ke,ve){var Ae=z.getMode(Ke,"text/html"),ye=Ae.name=="null";function be(ge){if(z.findModeByName){var ce=z.findModeByName(ge);ce&&(ge=ce.mime||ce.mimes[0])}var Je=z.getMode(Ke,ge);return Je.name=="null"?null:Je}ve.highlightFormatting===void 0&&(ve.highlightFormatting=!1),ve.maxBlockquoteDepth===void 0&&(ve.maxBlockquoteDepth=0),ve.taskLists===void 0&&(ve.taskLists=!1),ve.strikethrough===void 0&&(ve.strikethrough=!1),ve.emoji===void 0&&(ve.emoji=!1),ve.fencedCodeBlockHighlighting===void 0&&(ve.fencedCodeBlockHighlighting=!0),ve.fencedCodeBlockDefaultMode===void 0&&(ve.fencedCodeBlockDefaultMode="text/plain"),ve.xml===void 0&&(ve.xml=!0),ve.tokenTypeOverrides===void 0&&(ve.tokenTypeOverrides={});var Me={header:"header",code:"comment",quote:"quote",list1:"variable-2",list2:"variable-3",list3:"keyword",hr:"hr",image:"image",imageAltText:"image-alt-text",imageMarker:"image-marker",formatting:"formatting",linkInline:"link",linkEmail:"link",linkText:"link",linkHref:"string",em:"em",strong:"strong",strikethrough:"strikethrough",emoji:"builtin"};for(var Re in Me)Me.hasOwnProperty(Re)&&ve.tokenTypeOverrides[Re]&&(Me[Re]=ve.tokenTypeOverrides[Re]);var Oe=/^([*\-_])(?:\s*\1){2,}\s*$/,fe=/^(?:[*\-+]|^[0-9]+([.)]))\s+/,We=/^\[(x| )\](?=\s)/i,Se=ve.allowAtxHeaderWithoutSpace?/^(#+)/:/^(#+)(?: |$)/,yt=/^ {0,3}(?:\={1,}|-{2,})\s*$/,Xe=/^[^#!\[\]*_\\<>` "'(~:]+/,Le=/^(~~~+|```+)[ \t]*([\w\/+#-]*)[^\n`]*$/,Ge=/^\s*\[[^\]]+?\]:.*$/,Ne=/[!"#$%&'()*+,\-.\/:;<=>?@\[\\\]^_`{|}~\xA1\xA7\xAB\xB6\xB7\xBB\xBF\u037E\u0387\u055A-\u055F\u0589\u058A\u05BE\u05C0\u05C3\u05C6\u05F3\u05F4\u0609\u060A\u060C\u060D\u061B\u061E\u061F\u066A-\u066D\u06D4\u0700-\u070D\u07F7-\u07F9\u0830-\u083E\u085E\u0964\u0965\u0970\u0AF0\u0DF4\u0E4F\u0E5A\u0E5B\u0F04-\u0F12\u0F14\u0F3A-\u0F3D\u0F85\u0FD0-\u0FD4\u0FD9\u0FDA\u104A-\u104F\u10FB\u1360-\u1368\u1400\u166D\u166E\u169B\u169C\u16EB-\u16ED\u1735\u1736\u17D4-\u17D6\u17D8-\u17DA\u1800-\u180A\u1944\u1945\u1A1E\u1A1F\u1AA0-\u1AA6\u1AA8-\u1AAD\u1B5A-\u1B60\u1BFC-\u1BFF\u1C3B-\u1C3F\u1C7E\u1C7F\u1CC0-\u1CC7\u1CD3\u2010-\u2027\u2030-\u2043\u2045-\u2051\u2053-\u205E\u207D\u207E\u208D\u208E\u2308-\u230B\u2329\u232A\u2768-\u2775\u27C5\u27C6\u27E6-\u27EF\u2983-\u2998\u29D8-\u29DB\u29FC\u29FD\u2CF9-\u2CFC\u2CFE\u2CFF\u2D70\u2E00-\u2E2E\u2E30-\u2E42\u3001-\u3003\u3008-\u3011\u3014-\u301F\u3030\u303D\u30A0\u30FB\uA4FE\uA4FF\uA60D-\uA60F\uA673\uA67E\uA6F2-\uA6F7\uA874-\uA877\uA8CE\uA8CF\uA8F8-\uA8FA\uA8FC\uA92E\uA92F\uA95F\uA9C1-\uA9CD\uA9DE\uA9DF\uAA5C-\uAA5F\uAADE\uAADF\uAAF0\uAAF1\uABEB\uFD3E\uFD3F\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE61\uFE63\uFE68\uFE6A\uFE6B\uFF01-\uFF03\uFF05-\uFF0A\uFF0C-\uFF0F\uFF1A\uFF1B\uFF1F\uFF20\uFF3B-\uFF3D\uFF3F\uFF5B\uFF5D\uFF5F-\uFF65]|\uD800[\uDD00-\uDD02\uDF9F\uDFD0]|\uD801\uDD6F|\uD802[\uDC57\uDD1F\uDD3F\uDE50-\uDE58\uDE7F\uDEF0-\uDEF6\uDF39-\uDF3F\uDF99-\uDF9C]|\uD804[\uDC47-\uDC4D\uDCBB\uDCBC\uDCBE-\uDCC1\uDD40-\uDD43\uDD74\uDD75\uDDC5-\uDDC9\uDDCD\uDDDB\uDDDD-\uDDDF\uDE38-\uDE3D\uDEA9]|\uD805[\uDCC6\uDDC1-\uDDD7\uDE41-\uDE43\uDF3C-\uDF3E]|\uD809[\uDC70-\uDC74]|\uD81A[\uDE6E\uDE6F\uDEF5\uDF37-\uDF3B\uDF44]|\uD82F\uDC9F|\uD836[\uDE87-\uDE8B]/,dt=" ";function It(ge,ce,Je){return ce.f=ce.inline=Je,Je(ge,ce)}function Bt(ge,ce,Je){return ce.f=ce.block=Je,Je(ge,ce)}function mt(ge){return!ge||!/\S/.test(ge.string)}function st(ge){if(ge.linkTitle=!1,ge.linkHref=!1,ge.linkText=!1,ge.em=!1,ge.strong=!1,ge.strikethrough=!1,ge.quote=0,ge.indentedCode=!1,ge.f==je){var ce=ye;if(!ce){var Je=z.innerMode(Ae,ge.htmlState);ce=Je.mode.name=="xml"&&Je.state.tagStart===null&&!Je.state.context&&Je.state.tokenize.isInText}ce&&(ge.f=ht,ge.block=it,ge.htmlState=null)}return ge.trailingSpace=0,ge.trailingSpaceNewLine=!1,ge.prevLine=ge.thisLine,ge.thisLine={stream:null},null}function it(ge,ce){var Je=ge.column()===ce.indentation,jt=mt(ce.prevLine.stream),wt=ce.indentedCode,Ie=ce.prevLine.hr,Ue=ce.list!==!1,et=(ce.listStack[ce.listStack.length-1]||0)+3;ce.indentedCode=!1;var cn=ce.indentation;if(ce.indentationDiff===null&&(ce.indentationDiff=ce.indentation,Ue)){for(ce.list=null;cn<ce.listStack[ce.listStack.length-1];)ce.listStack.pop(),ce.listStack.length?ce.indentation=ce.listStack[ce.listStack.length-1]:ce.list=!1;ce.list!==!1&&(ce.indentationDiff=cn-ce.listStack[ce.listStack.length-1])}var kt=!jt&&!Ie&&!ce.prevLine.header&&(!Ue||!wt)&&!ce.prevLine.fencedCodeEnd,Yt=(ce.list===!1||Ie||jt)&&ce.indentation<=et&&ge.match(Oe),ze=null;if(ce.indentationDiff>=4&&(wt||ce.prevLine.fencedCodeEnd||ce.prevLine.header||jt))return ge.skipToEnd(),ce.indentedCode=!0,Me.code;if(ge.eatSpace())return null;if(Je&&ce.indentation<=et&&(ze=ge.match(Se))&&ze[1].length<=6)return ce.quote=0,ce.header=ze[1].length,ce.thisLine.header=!0,ve.highlightFormatting&&(ce.formatting="header"),ce.f=ce.inline,nt(ce);if(ce.indentation<=et&&ge.eat(">"))return ce.quote=Je?1:ce.quote+1,ve.highlightFormatting&&(ce.formatting="quote"),ge.eatSpace(),nt(ce);if(!Yt&&!ce.setext&&Je&&ce.indentation<=et&&(ze=ge.match(fe))){var zt=ze[1]?"ol":"ul";return ce.indentation=cn+ge.current().length,ce.list=!0,ce.quote=0,ce.listStack.push(ce.indentation),ce.em=!1,ce.strong=!1,ce.code=!1,ce.strikethrough=!1,ve.taskLists&&ge.match(We,!1)&&(ce.taskList=!0),ce.f=ce.inline,ve.highlightFormatting&&(ce.formatting=["list","list-"+zt]),nt(ce)}else{if(Je&&ce.indentation<=et&&(ze=ge.match(Le,!0)))return ce.quote=0,ce.fencedEndRE=new RegExp(ze[1]+"+ *$"),ce.localMode=ve.fencedCodeBlockHighlighting&&be(ze[2]||ve.fencedCodeBlockDefaultMode),ce.localMode&&(ce.localState=z.startState(ce.localMode)),ce.f=ce.block=Ot,ve.highlightFormatting&&(ce.formatting="code-block"),ce.code=-1,nt(ce);if(ce.setext||(!kt||!Ue)&&!ce.quote&&ce.list===!1&&!ce.code&&!Yt&&!Ge.test(ge.string)&&(ze=ge.lookAhead(1))&&(ze=ze.match(yt)))return ce.setext?(ce.header=ce.setext,ce.setext=0,ge.skipToEnd(),ve.highlightFormatting&&(ce.formatting="header")):(ce.header=ze[0].charAt(0)=="="?1:2,ce.setext=ce.header),ce.thisLine.header=!0,ce.f=ce.inline,nt(ce);if(Yt)return ge.skipToEnd(),ce.hr=!0,ce.thisLine.hr=!0,Me.hr;if(ge.peek()==="[")return It(ge,ce,At)}return It(ge,ce,ce.inline)}function je(ge,ce){var Je=Ae.token(ge,ce.htmlState);if(!ye){var jt=z.innerMode(Ae,ce.htmlState);(jt.mode.name=="xml"&&jt.state.tagStart===null&&!jt.state.context&&jt.state.tokenize.isInText||ce.md_inside&&ge.current().indexOf(">")>-1)&&(ce.f=ht,ce.block=it,ce.htmlState=null)}return Je}function Ot(ge,ce){var Je=ce.listStack[ce.listStack.length-1]||0,jt=ce.indentation<Je,wt=Je+3;if(ce.fencedEndRE&&ce.indentation<=wt&&(jt||ge.match(ce.fencedEndRE))){ve.highlightFormatting&&(ce.formatting="code-block");var Ie;return jt||(Ie=nt(ce)),ce.localMode=ce.localState=null,ce.block=it,ce.f=ht,ce.fencedEndRE=null,ce.code=0,ce.thisLine.fencedCodeEnd=!0,jt?Bt(ge,ce,ce.block):Ie}else return ce.localMode?ce.localMode.token(ge,ce.localState):(ge.skipToEnd(),Me.code)}function nt(ge){var ce=[];if(ge.formatting){ce.push(Me.formatting),typeof ge.formatting=="string"&&(ge.formatting=[ge.formatting]);for(var Je=0;Je<ge.formatting.length;Je++)ce.push(Me.formatting+"-"+ge.formatting[Je]),ge.formatting[Je]==="header"&&ce.push(Me.formatting+"-"+ge.formatting[Je]+"-"+ge.header),ge.formatting[Je]==="quote"&&(!ve.maxBlockquoteDepth||ve.maxBlockquoteDepth>=ge.quote?ce.push(Me.formatting+"-"+ge.formatting[Je]+"-"+ge.quote):ce.push("error"))}if(ge.taskOpen)return ce.push("meta"),ce.length?ce.join(" "):null;if(ge.taskClosed)return ce.push("property"),ce.length?ce.join(" "):null;if(ge.linkHref?ce.push(Me.linkHref,"url"):(ge.strong&&ce.push(Me.strong),ge.em&&ce.push(Me.em),ge.strikethrough&&ce.push(Me.strikethrough),ge.emoji&&ce.push(Me.emoji),ge.linkText&&ce.push(Me.linkText),ge.code&&ce.push(Me.code),ge.image&&ce.push(Me.image),ge.imageAltText&&ce.push(Me.imageAltText,"link"),ge.imageMarker&&ce.push(Me.imageMarker)),ge.header&&ce.push(Me.header,Me.header+"-"+ge.header),ge.quote&&(ce.push(Me.quote),!ve.maxBlockquoteDepth||ve.maxBlockquoteDepth>=ge.quote?ce.push(Me.quote+"-"+ge.quote):ce.push(Me.quote+"-"+ve.maxBlockquoteDepth)),ge.list!==!1){var jt=(ge.listStack.length-1)%3;jt?jt===1?ce.push(Me.list2):ce.push(Me.list3):ce.push(Me.list1)}return ge.trailingSpaceNewLine?ce.push("trailing-space-new-line"):ge.trailingSpace&&ce.push("trailing-space-"+(ge.trailingSpace%2?"a":"b")),ce.length?ce.join(" "):null}function tt(ge,ce){if(ge.match(Xe,!0))return nt(ce)}function ht(ge,ce){var Je=ce.text(ge,ce);if(typeof Je!="undefined")return Je;if(ce.list)return ce.list=null,nt(ce);if(ce.taskList){var jt=ge.match(We,!0)[1]===" ";return jt?ce.taskOpen=!0:ce.taskClosed=!0,ve.highlightFormatting&&(ce.formatting="task"),ce.taskList=!1,nt(ce)}if(ce.taskOpen=!1,ce.taskClosed=!1,ce.header&&ge.match(/^#+$/,!0))return ve.highlightFormatting&&(ce.formatting="header"),nt(ce);var wt=ge.next();if(ce.linkTitle){ce.linkTitle=!1;var Ie=wt;wt==="("&&(Ie=")"),Ie=(Ie+"").replace(/([.?*+^\[\]\\(){}|-])/g,"\\$1");var Ue="^\\s*(?:[^"+Ie+"\\\\]+|\\\\\\\\|\\\\.)"+Ie;if(ge.match(new RegExp(Ue),!0))return Me.linkHref}if(wt==="`"){var et=ce.formatting;ve.highlightFormatting&&(ce.formatting="code"),ge.eatWhile("`");var cn=ge.current().length;if(ce.code==0&&(!ce.quote||cn==1))return ce.code=cn,nt(ce);if(cn==ce.code){var kt=nt(ce);return ce.code=0,kt}else return ce.formatting=et,nt(ce)}else if(ce.code)return nt(ce);if(wt==="\\"&&(ge.next(),ve.highlightFormatting)){var Yt=nt(ce),ze=Me.formatting+"-escape";return Yt?Yt+" "+ze:ze}if(wt==="!"&&ge.match(/\[[^\]]*\] ?(?:\(|\[)/,!1))return ce.imageMarker=!0,ce.image=!0,ve.highlightFormatting&&(ce.formatting="image"),nt(ce);if(wt==="["&&ce.imageMarker&&ge.match(/[^\]]*\](\(.*?\)| ?\[.*?\])/,!1))return ce.imageMarker=!1,ce.imageAltText=!0,ve.highlightFormatting&&(ce.formatting="image"),nt(ce);if(wt==="]"&&ce.imageAltText){ve.highlightFormatting&&(ce.formatting="image");var Yt=nt(ce);return ce.imageAltText=!1,ce.image=!1,ce.inline=ce.f=at,Yt}if(wt==="["&&!ce.image)return ce.linkText&&ge.match(/^.*?\]/)||(ce.linkText=!0,ve.highlightFormatting&&(ce.formatting="link")),nt(ce);if(wt==="]"&&ce.linkText){ve.highlightFormatting&&(ce.formatting="link");var Yt=nt(ce);return ce.linkText=!1,ce.inline=ce.f=ge.match(/\(.*?\)| ?\[.*?\]/,!1)?at:ht,Yt}if(wt==="<"&&ge.match(/^(https?|ftps?):\/\/(?:[^\\>]|\\.)+>/,!1)){ce.f=ce.inline=$e,ve.highlightFormatting&&(ce.formatting="link");var Yt=nt(ce);return Yt?Yt+=" ":Yt="",Yt+Me.linkInline}if(wt==="<"&&ge.match(/^[^> \\]+@(?:[^\\>]|\\.)+>/,!1)){ce.f=ce.inline=$e,ve.highlightFormatting&&(ce.formatting="link");var Yt=nt(ce);return Yt?Yt+=" ":Yt="",Yt+Me.linkEmail}if(ve.xml&&wt==="<"&&ge.match(/^(!--|\?|!\[CDATA\[|[a-z][a-z0-9-]*(?:\s+[a-z_:.\-]+(?:\s*=\s*[^>]+)?)*\s*(?:>|$))/i,!1)){var zt=ge.string.indexOf(">",ge.pos);if(zt!=-1){var ut=ge.string.substring(ge.start,zt);/markdown\s*=\s*('|"){0,1}1('|"){0,1}/.test(ut)&&(ce.md_inside=!0)}return ge.backUp(1),ce.htmlState=z.startState(Ae),Bt(ge,ce,je)}if(ve.xml&&wt==="<"&&ge.match(/^\/\w*?>/))return ce.md_inside=!1,"tag";if(wt==="*"||wt==="_"){for(var ae=1,te=ge.pos==1?" ":ge.string.charAt(ge.pos-2);ae<3&&ge.eat(wt);)ae++;var ee=ge.peek()||" ",oe=!/\s/.test(ee)&&(!Ne.test(ee)||/\s/.test(te)||Ne.test(te)),se=!/\s/.test(te)&&(!Ne.test(te)||/\s/.test(ee)||Ne.test(ee)),ne=null,he=null;if(ae%2&&(!ce.em&&oe&&(wt==="*"||!se||Ne.test(te))?ne=!0:ce.em==wt&&se&&(wt==="*"||!oe||Ne.test(ee))&&(ne=!1)),ae>1&&(!ce.strong&&oe&&(wt==="*"||!se||Ne.test(te))?he=!0:ce.strong==wt&&se&&(wt==="*"||!oe||Ne.test(ee))&&(he=!1)),he!=null||ne!=null){ve.highlightFormatting&&(ce.formatting=ne==null?"strong":he==null?"em":"strong em"),ne===!0&&(ce.em=wt),he===!0&&(ce.strong=wt);var kt=nt(ce);return ne===!1&&(ce.em=!1),he===!1&&(ce.strong=!1),kt}}else if(wt===" "&&(ge.eat("*")||ge.eat("_"))){if(ge.peek()===" ")return nt(ce);ge.backUp(1)}if(ve.strikethrough){if(wt==="~"&&ge.eatWhile(wt)){if(ce.strikethrough){ve.highlightFormatting&&(ce.formatting="strikethrough");var kt=nt(ce);return ce.strikethrough=!1,kt}else if(ge.match(/^[^\s]/,!1))return ce.strikethrough=!0,ve.highlightFormatting&&(ce.formatting="strikethrough"),nt(ce)}else if(wt===" "&&ge.match(/^~~/,!0)){if(ge.peek()===" ")return nt(ce);ge.backUp(2)}}if(ve.emoji&&wt===":"&&ge.match(/^(?:[a-z_\d+][a-z_\d+-]*|\-[a-z_\d+][a-z_\d+-]*):/)){ce.emoji=!0,ve.highlightFormatting&&(ce.formatting="emoji");var xe=nt(ce);return ce.emoji=!1,xe}return wt===" "&&(ge.match(/^ +$/,!1)?ce.trailingSpace++:ce.trailingSpace&&(ce.trailingSpaceNewLine=!0)),nt(ce)}function $e(ge,ce){var Je=ge.next();if(Je===">"){ce.f=ce.inline=ht,ve.highlightFormatting&&(ce.formatting="link");var jt=nt(ce);return jt?jt+=" ":jt="",jt+Me.linkInline}return ge.match(/^[^>]+/,!0),Me.linkInline}function at(ge,ce){if(ge.eatSpace())return null;var Je=ge.next();return Je==="("||Je==="["?(ce.f=ce.inline=me(Je==="("?")":"]"),ve.highlightFormatting&&(ce.formatting="link-string"),ce.linkHref=!0,nt(ce)):"error"}var lt={")":/^(?:[^\\\(\)]|\\.|\((?:[^\\\(\)]|\\.)*\))*?(?=\))/,"]":/^(?:[^\\\[\]]|\\.|\[(?:[^\\\[\]]|\\.)*\])*?(?=\])/};function me(ge){return function(ce,Je){var jt=ce.next();if(jt===ge){Je.f=Je.inline=ht,ve.highlightFormatting&&(Je.formatting="link-string");var wt=nt(Je);return Je.linkHref=!1,wt}return ce.match(lt[ge]),Je.linkHref=!0,nt(Je)}}function At(ge,ce){return ge.match(/^([^\]\\]|\\.)*\]:/,!1)?(ce.f=De,ge.next(),ve.highlightFormatting&&(ce.formatting="link"),ce.linkText=!0,nt(ce)):It(ge,ce,ht)}function De(ge,ce){if(ge.match(/^\]:/,!0)){ce.f=ce.inline=He,ve.highlightFormatting&&(ce.formatting="link");var Je=nt(ce);return ce.linkText=!1,Je}return ge.match(/^([^\]\\]|\\.)+/,!0),Me.linkText}function He(ge,ce){return ge.eatSpace()?null:(ge.match(/^[^\s]+/,!0),ge.peek()===void 0?ce.linkTitle=!0:ge.match(/^(?:\s+(?:"(?:[^"\\]|\\\\|\\.)+"|'(?:[^'\\]|\\\\|\\.)+'|\((?:[^)\\]|\\\\|\\.)+\)))?/,!0),ce.f=ce.inline=ht,Me.linkHref+" url")}var Pt={startState:function(){return{f:it,prevLine:{stream:null},thisLine:{stream:null},block:it,htmlState:null,indentation:0,inline:ht,text:tt,formatting:!1,linkText:!1,linkHref:!1,linkTitle:!1,code:0,em:!1,strong:!1,header:0,setext:0,hr:!1,taskList:!1,list:!1,listStack:[],quote:0,trailingSpace:0,trailingSpaceNewLine:!1,strikethrough:!1,emoji:!1,fencedEndRE:null}},copyState:function(ge){return{f:ge.f,prevLine:ge.prevLine,thisLine:ge.thisLine,block:ge.block,htmlState:ge.htmlState&&z.copyState(Ae,ge.htmlState),indentation:ge.indentation,localMode:ge.localMode,localState:ge.localMode?z.copyState(ge.localMode,ge.localState):null,inline:ge.inline,text:ge.text,formatting:!1,linkText:ge.linkText,linkTitle:ge.linkTitle,linkHref:ge.linkHref,code:ge.code,em:ge.em,strong:ge.strong,strikethrough:ge.strikethrough,emoji:ge.emoji,header:ge.header,setext:ge.setext,hr:ge.hr,taskList:ge.taskList,list:ge.list,listStack:ge.listStack.slice(0),quote:ge.quote,indentedCode:ge.indentedCode,trailingSpace:ge.trailingSpace,trailingSpaceNewLine:ge.trailingSpaceNewLine,md_inside:ge.md_inside,fencedEndRE:ge.fencedEndRE}},token:function(ge,ce){if(ce.formatting=!1,ge!=ce.thisLine.stream){if(ce.header=0,ce.hr=!1,ge.match(/^\s*$/,!0))return st(ce),null;if(ce.prevLine=ce.thisLine,ce.thisLine={stream:ge},ce.taskList=!1,ce.trailingSpace=0,ce.trailingSpaceNewLine=!1,!ce.localState&&(ce.f=ce.block,ce.f!=je)){var Je=ge.match(/^\s*/,!0)[0].replace(/\t/g,dt).length;if(ce.indentation=Je,ce.indentationDiff=null,Je>0)return null}}return ce.f(ge,ce)},innerMode:function(ge){return ge.block==je?{state:ge.htmlState,mode:Ae}:ge.localState?{state:ge.localState,mode:ge.localMode}:{state:ge,mode:Pt}},indent:function(ge,ce,Je){return ge.block==je&&Ae.indent?Ae.indent(ge.htmlState,ce,Je):ge.localState&&ge.localMode.indent?ge.localMode.indent(ge.localState,ce,Je):z.Pass},blankLine:st,getType:nt,blockCommentStart:"<!--",blockCommentEnd:"-->",closeBrackets:"()[]{}''\"\"``",fold:"markdown"};return Pt},"xml"),z.defineMIME("text/markdown","markdown"),z.defineMIME("text/x-markdown","markdown")})},98101:function(ln,Ft,ie){(function(z){z(ie(89780))})(function(z){"use strict";z.modeInfo=[{name:"APL",mime:"text/apl",mode:"apl",ext:["dyalog","apl"]},{name:"PGP",mimes:["application/pgp","application/pgp-encrypted","application/pgp-keys","application/pgp-signature"],mode:"asciiarmor",ext:["asc","pgp","sig"]},{name:"ASN.1",mime:"text/x-ttcn-asn",mode:"asn.1",ext:["asn","asn1"]},{name:"Asterisk",mime:"text/x-asterisk",mode:"asterisk",file:/^extensions\.conf$/i},{name:"Brainfuck",mime:"text/x-brainfuck",mode:"brainfuck",ext:["b","bf"]},{name:"C",mime:"text/x-csrc",mode:"clike",ext:["c","h","ino"]},{name:"C++",mime:"text/x-c++src",mode:"clike",ext:["cpp","c++","cc","cxx","hpp","h++","hh","hxx"],alias:["cpp"]},{name:"Cobol",mime:"text/x-cobol",mode:"cobol",ext:["cob","cpy"]},{name:"C#",mime:"text/x-csharp",mode:"clike",ext:["cs"],alias:["csharp","cs"]},{name:"Clojure",mime:"text/x-clojure",mode:"clojure",ext:["clj","cljc","cljx"]},{name:"ClojureScript",mime:"text/x-clojurescript",mode:"clojure",ext:["cljs"]},{name:"Closure Stylesheets (GSS)",mime:"text/x-gss",mode:"css",ext:["gss"]},{name:"CMake",mime:"text/x-cmake",mode:"cmake",ext:["cmake","cmake.in"],file:/^CMakeLists\.txt$/},{name:"CoffeeScript",mimes:["application/vnd.coffeescript","text/coffeescript","text/x-coffeescript"],mode:"coffeescript",ext:["coffee"],alias:["coffee","coffee-script"]},{name:"Common Lisp",mime:"text/x-common-lisp",mode:"commonlisp",ext:["cl","lisp","el"],alias:["lisp"]},{name:"Cypher",mime:"application/x-cypher-query",mode:"cypher",ext:["cyp","cypher"]},{name:"Cython",mime:"text/x-cython",mode:"python",ext:["pyx","pxd","pxi"]},{name:"Crystal",mime:"text/x-crystal",mode:"crystal",ext:["cr"]},{name:"CSS",mime:"text/css",mode:"css",ext:["css"]},{name:"CQL",mime:"text/x-cassandra",mode:"sql",ext:["cql"]},{name:"D",mime:"text/x-d",mode:"d",ext:["d"]},{name:"Dart",mimes:["application/dart","text/x-dart"],mode:"dart",ext:["dart"]},{name:"diff",mime:"text/x-diff",mode:"diff",ext:["diff","patch"]},{name:"Django",mime:"text/x-django",mode:"django"},{name:"Dockerfile",mime:"text/x-dockerfile",mode:"dockerfile",file:/^Dockerfile$/},{name:"DTD",mime:"application/xml-dtd",mode:"dtd",ext:["dtd"]},{name:"Dylan",mime:"text/x-dylan",mode:"dylan",ext:["dylan","dyl","intr"]},{name:"EBNF",mime:"text/x-ebnf",mode:"ebnf"},{name:"ECL",mime:"text/x-ecl",mode:"ecl",ext:["ecl"]},{name:"edn",mime:"application/edn",mode:"clojure",ext:["edn"]},{name:"Eiffel",mime:"text/x-eiffel",mode:"eiffel",ext:["e"]},{name:"Elm",mime:"text/x-elm",mode:"elm",ext:["elm"]},{name:"Embedded Javascript",mime:"application/x-ejs",mode:"htmlembedded",ext:["ejs"]},{name:"Embedded Ruby",mime:"application/x-erb",mode:"htmlembedded",ext:["erb"]},{name:"Erlang",mime:"text/x-erlang",mode:"erlang",ext:["erl"]},{name:"Esper",mime:"text/x-esper",mode:"sql"},{name:"Factor",mime:"text/x-factor",mode:"factor",ext:["factor"]},{name:"FCL",mime:"text/x-fcl",mode:"fcl"},{name:"Forth",mime:"text/x-forth",mode:"forth",ext:["forth","fth","4th"]},{name:"Fortran",mime:"text/x-fortran",mode:"fortran",ext:["f","for","f77","f90","f95"]},{name:"F#",mime:"text/x-fsharp",mode:"mllike",ext:["fs"],alias:["fsharp"]},{name:"Gas",mime:"text/x-gas",mode:"gas",ext:["s"]},{name:"Gherkin",mime:"text/x-feature",mode:"gherkin",ext:["feature"]},{name:"GitHub Flavored Markdown",mime:"text/x-gfm",mode:"gfm",file:/^(readme|contributing|history)\.md$/i},{name:"Go",mime:"text/x-go",mode:"go",ext:["go"]},{name:"Groovy",mime:"text/x-groovy",mode:"groovy",ext:["groovy","gradle"],file:/^Jenkinsfile$/},{name:"HAML",mime:"text/x-haml",mode:"haml",ext:["haml"]},{name:"Haskell",mime:"text/x-haskell",mode:"haskell",ext:["hs"]},{name:"Haskell (Literate)",mime:"text/x-literate-haskell",mode:"haskell-literate",ext:["lhs"]},{name:"Haxe",mime:"text/x-haxe",mode:"haxe",ext:["hx"]},{name:"HXML",mime:"text/x-hxml",mode:"haxe",ext:["hxml"]},{name:"ASP.NET",mime:"application/x-aspx",mode:"htmlembedded",ext:["aspx"],alias:["asp","aspx"]},{name:"HTML",mime:"text/html",mode:"htmlmixed",ext:["html","htm","handlebars","hbs"],alias:["xhtml"]},{name:"HTTP",mime:"message/http",mode:"http"},{name:"IDL",mime:"text/x-idl",mode:"idl",ext:["pro"]},{name:"Pug",mime:"text/x-pug",mode:"pug",ext:["jade","pug"],alias:["jade"]},{name:"Java",mime:"text/x-java",mode:"clike",ext:["java"]},{name:"Java Server Pages",mime:"application/x-jsp",mode:"htmlembedded",ext:["jsp"],alias:["jsp"]},{name:"JavaScript",mimes:["text/javascript","text/ecmascript","application/javascript","application/x-javascript","application/ecmascript"],mode:"javascript",ext:["js"],alias:["ecmascript","js","node"]},{name:"JSON",mimes:["application/json","application/x-json"],mode:"javascript",ext:["json","map"],alias:["json5"]},{name:"JSON-LD",mime:"application/ld+json",mode:"javascript",ext:["jsonld"],alias:["jsonld"]},{name:"JSX",mime:"text/jsx",mode:"jsx",ext:["jsx"]},{name:"Jinja2",mime:"text/jinja2",mode:"jinja2",ext:["j2","jinja","jinja2"]},{name:"Julia",mime:"text/x-julia",mode:"julia",ext:["jl"]},{name:"Kotlin",mime:"text/x-kotlin",mode:"clike",ext:["kt"]},{name:"LESS",mime:"text/x-less",mode:"css",ext:["less"]},{name:"LiveScript",mime:"text/x-livescript",mode:"livescript",ext:["ls"],alias:["ls"]},{name:"Lua",mime:"text/x-lua",mode:"lua",ext:["lua"]},{name:"Markdown",mime:"text/x-markdown",mode:"markdown",ext:["markdown","md","mkd"]},{name:"mIRC",mime:"text/mirc",mode:"mirc"},{name:"MariaDB SQL",mime:"text/x-mariadb",mode:"sql"},{name:"Mathematica",mime:"text/x-mathematica",mode:"mathematica",ext:["m","nb","wl","wls"]},{name:"Modelica",mime:"text/x-modelica",mode:"modelica",ext:["mo"]},{name:"MUMPS",mime:"text/x-mumps",mode:"mumps",ext:["mps"]},{name:"MS SQL",mime:"text/x-mssql",mode:"sql"},{name:"mbox",mime:"application/mbox",mode:"mbox",ext:["mbox"]},{name:"MySQL",mime:"text/x-mysql",mode:"sql"},{name:"Nginx",mime:"text/x-nginx-conf",mode:"nginx",file:/nginx.*\.conf$/i},{name:"NSIS",mime:"text/x-nsis",mode:"nsis",ext:["nsh","nsi"]},{name:"NTriples",mimes:["application/n-triples","application/n-quads","text/n-triples"],mode:"ntriples",ext:["nt","nq"]},{name:"Objective-C",mime:"text/x-objectivec",mode:"clike",ext:["m"],alias:["objective-c","objc"]},{name:"Objective-C++",mime:"text/x-objectivec++",mode:"clike",ext:["mm"],alias:["objective-c++","objc++"]},{name:"OCaml",mime:"text/x-ocaml",mode:"mllike",ext:["ml","mli","mll","mly"]},{name:"Octave",mime:"text/x-octave",mode:"octave",ext:["m"]},{name:"Oz",mime:"text/x-oz",mode:"oz",ext:["oz"]},{name:"Pascal",mime:"text/x-pascal",mode:"pascal",ext:["p","pas"]},{name:"PEG.js",mime:"null",mode:"pegjs",ext:["jsonld"]},{name:"Perl",mime:"text/x-perl",mode:"perl",ext:["pl","pm"]},{name:"PHP",mimes:["text/x-php","application/x-httpd-php","application/x-httpd-php-open"],mode:"php",ext:["php","php3","php4","php5","php7","phtml"]},{name:"Pig",mime:"text/x-pig",mode:"pig",ext:["pig"]},{name:"Plain Text",mime:"text/plain",mode:"null",ext:["txt","text","conf","def","list","log"]},{name:"PLSQL",mime:"text/x-plsql",mode:"sql",ext:["pls"]},{name:"PostgreSQL",mime:"text/x-pgsql",mode:"sql"},{name:"PowerShell",mime:"application/x-powershell",mode:"powershell",ext:["ps1","psd1","psm1"]},{name:"Properties files",mime:"text/x-properties",mode:"properties",ext:["properties","ini","in"],alias:["ini","properties"]},{name:"ProtoBuf",mime:"text/x-protobuf",mode:"protobuf",ext:["proto"]},{name:"Python",mime:"text/x-python",mode:"python",ext:["BUILD","bzl","py","pyw"],file:/^(BUCK|BUILD)$/},{name:"Puppet",mime:"text/x-puppet",mode:"puppet",ext:["pp"]},{name:"Q",mime:"text/x-q",mode:"q",ext:["q"]},{name:"R",mime:"text/x-rsrc",mode:"r",ext:["r","R"],alias:["rscript"]},{name:"reStructuredText",mime:"text/x-rst",mode:"rst",ext:["rst"],alias:["rst"]},{name:"RPM Changes",mime:"text/x-rpm-changes",mode:"rpm"},{name:"RPM Spec",mime:"text/x-rpm-spec",mode:"rpm",ext:["spec"]},{name:"Ruby",mime:"text/x-ruby",mode:"ruby",ext:["rb"],alias:["jruby","macruby","rake","rb","rbx"]},{name:"Rust",mime:"text/x-rustsrc",mode:"rust",ext:["rs"]},{name:"SAS",mime:"text/x-sas",mode:"sas",ext:["sas"]},{name:"Sass",mime:"text/x-sass",mode:"sass",ext:["sass"]},{name:"Scala",mime:"text/x-scala",mode:"clike",ext:["scala"]},{name:"Scheme",mime:"text/x-scheme",mode:"scheme",ext:["scm","ss"]},{name:"SCSS",mime:"text/x-scss",mode:"css",ext:["scss"]},{name:"Shell",mimes:["text/x-sh","application/x-sh"],mode:"shell",ext:["sh","ksh","bash"],alias:["bash","sh","zsh"],file:/^PKGBUILD$/},{name:"Sieve",mime:"application/sieve",mode:"sieve",ext:["siv","sieve"]},{name:"Slim",mimes:["text/x-slim","application/x-slim"],mode:"slim",ext:["slim"]},{name:"Smalltalk",mime:"text/x-stsrc",mode:"smalltalk",ext:["st"]},{name:"Smarty",mime:"text/x-smarty",mode:"smarty",ext:["tpl"]},{name:"Solr",mime:"text/x-solr",mode:"solr"},{name:"SML",mime:"text/x-sml",mode:"mllike",ext:["sml","sig","fun","smackspec"]},{name:"Soy",mime:"text/x-soy",mode:"soy",ext:["soy"],alias:["closure template"]},{name:"SPARQL",mime:"application/sparql-query",mode:"sparql",ext:["rq","sparql"],alias:["sparul"]},{name:"Spreadsheet",mime:"text/x-spreadsheet",mode:"spreadsheet",alias:["excel","formula"]},{name:"SQL",mime:"text/x-sql",mode:"sql",ext:["sql"]},{name:"SQLite",mime:"text/x-sqlite",mode:"sql"},{name:"Squirrel",mime:"text/x-squirrel",mode:"clike",ext:["nut"]},{name:"Stylus",mime:"text/x-styl",mode:"stylus",ext:["styl"]},{name:"Swift",mime:"text/x-swift",mode:"swift",ext:["swift"]},{name:"sTeX",mime:"text/x-stex",mode:"stex"},{name:"LaTeX",mime:"text/x-latex",mode:"stex",ext:["text","ltx","tex"],alias:["tex"]},{name:"SystemVerilog",mime:"text/x-systemverilog",mode:"verilog",ext:["v","sv","svh"]},{name:"Tcl",mime:"text/x-tcl",mode:"tcl",ext:["tcl"]},{name:"Textile",mime:"text/x-textile",mode:"textile",ext:["textile"]},{name:"TiddlyWiki",mime:"text/x-tiddlywiki",mode:"tiddlywiki"},{name:"Tiki wiki",mime:"text/tiki",mode:"tiki"},{name:"TOML",mime:"text/x-toml",mode:"toml",ext:["toml"]},{name:"Tornado",mime:"text/x-tornado",mode:"tornado"},{name:"troff",mime:"text/troff",mode:"troff",ext:["1","2","3","4","5","6","7","8","9"]},{name:"TTCN",mime:"text/x-ttcn",mode:"ttcn",ext:["ttcn","ttcn3","ttcnpp"]},{name:"TTCN_CFG",mime:"text/x-ttcn-cfg",mode:"ttcn-cfg",ext:["cfg"]},{name:"Turtle",mime:"text/turtle",mode:"turtle",ext:["ttl"]},{name:"TypeScript",mime:"application/typescript",mode:"javascript",ext:["ts"],alias:["ts"]},{name:"TypeScript-JSX",mime:"text/typescript-jsx",mode:"jsx",ext:["tsx"],alias:["tsx"]},{name:"Twig",mime:"text/x-twig",mode:"twig"},{name:"Web IDL",mime:"text/x-webidl",mode:"webidl",ext:["webidl"]},{name:"VB.NET",mime:"text/x-vb",mode:"vb",ext:["vb"]},{name:"VBScript",mime:"text/vbscript",mode:"vbscript",ext:["vbs"]},{name:"Velocity",mime:"text/velocity",mode:"velocity",ext:["vtl"]},{name:"Verilog",mime:"text/x-verilog",mode:"verilog",ext:["v"]},{name:"VHDL",mime:"text/x-vhdl",mode:"vhdl",ext:["vhd","vhdl"]},{name:"Vue.js Component",mimes:["script/x-vue","text/x-vue"],mode:"vue",ext:["vue"]},{name:"XML",mimes:["application/xml","text/xml"],mode:"xml",ext:["xml","xsl","xsd","svg"],alias:["rss","wsdl","xsd"]},{name:"XQuery",mime:"application/xquery",mode:"xquery",ext:["xy","xquery"]},{name:"Yacas",mime:"text/x-yacas",mode:"yacas",ext:["ys"]},{name:"YAML",mimes:["text/x-yaml","text/yaml"],mode:"yaml",ext:["yaml","yml"],alias:["yml"]},{name:"Z80",mime:"text/x-z80",mode:"z80",ext:["z80"]},{name:"mscgen",mime:"text/x-mscgen",mode:"mscgen",ext:["mscgen","mscin","msc"]},{name:"xu",mime:"text/x-xu",mode:"mscgen",ext:["xu"]},{name:"msgenny",mime:"text/x-msgenny",mode:"mscgen",ext:["msgenny"]},{name:"WebAssembly",mime:"text/webassembly",mode:"wast",ext:["wat","wast"]}];for(var Ke=0;Ke<z.modeInfo.length;Ke++){var ve=z.modeInfo[Ke];ve.mimes&&(ve.mime=ve.mimes[0])}z.findModeByMIME=function(Ae){Ae=Ae.toLowerCase();for(var ye=0;ye<z.modeInfo.length;ye++){var be=z.modeInfo[ye];if(be.mime==Ae)return be;if(be.mimes){for(var Me=0;Me<be.mimes.length;Me++)if(be.mimes[Me]==Ae)return be}}if(/\+xml$/.test(Ae))return z.findModeByMIME("application/xml");if(/\+json$/.test(Ae))return z.findModeByMIME("application/json")},z.findModeByExtension=function(Ae){Ae=Ae.toLowerCase();for(var ye=0;ye<z.modeInfo.length;ye++){var be=z.modeInfo[ye];if(be.ext){for(var Me=0;Me<be.ext.length;Me++)if(be.ext[Me]==Ae)return be}}},z.findModeByFileName=function(Ae){for(var ye=0;ye<z.modeInfo.length;ye++){var be=z.modeInfo[ye];if(be.file&&be.file.test(Ae))return be}var Me=Ae.lastIndexOf("."),Re=Me>-1&&Ae.substring(Me+1,Ae.length);if(Re)return z.findModeByExtension(Re)},z.findModeByName=function(Ae){Ae=Ae.toLowerCase();for(var ye=0;ye<z.modeInfo.length;ye++){var be=z.modeInfo[ye];if(be.name.toLowerCase()==Ae)return be;if(be.alias){for(var Me=0;Me<be.alias.length;Me++)if(be.alias[Me].toLowerCase()==Ae)return be}}}})},67549:function(ln,Ft,ie){(function(z){z(ie(89780))})(function(z){"use strict";z.defineMode("stex",function(Ke,ve){"use strict";function Ae(Xe,Le){Xe.cmdState.push(Le)}function ye(Xe){return Xe.cmdState.length>0?Xe.cmdState[Xe.cmdState.length-1]:null}function be(Xe){var Le=Xe.cmdState.pop();Le&&Le.closeBracket()}function Me(Xe){for(var Le=Xe.cmdState,Ge=Le.length-1;Ge>=0;Ge--){var Ne=Le[Ge];if(Ne.name!="DEFAULT")return Ne}return{styleIdentifier:function(){return null}}}function Re(Xe,Le,Ge){return function(){this.name=Xe,this.bracketNo=0,this.style=Le,this.styles=Ge,this.argument=null,this.styleIdentifier=function(){return this.styles[this.bracketNo-1]||null},this.openBracket=function(){return this.bracketNo++,"bracket"},this.closeBracket=function(){}}}var Oe={};Oe.importmodule=Re("importmodule","tag",["string","builtin"]),Oe.documentclass=Re("documentclass","tag",["","atom"]),Oe.usepackage=Re("usepackage","tag",["atom"]),Oe.begin=Re("begin","tag",["atom"]),Oe.end=Re("end","tag",["atom"]),Oe.label=Re("label","tag",["atom"]),Oe.ref=Re("ref","tag",["atom"]),Oe.eqref=Re("eqref","tag",["atom"]),Oe.cite=Re("cite","tag",["atom"]),Oe.bibitem=Re("bibitem","tag",["atom"]),Oe.Bibitem=Re("Bibitem","tag",["atom"]),Oe.RBibitem=Re("RBibitem","tag",["atom"]),Oe.DEFAULT=function(){this.name="DEFAULT",this.style="tag",this.styleIdentifier=this.openBracket=this.closeBracket=function(){}};function fe(Xe,Le){Xe.f=Le}function We(Xe,Le){var Ge;if(Xe.match(/^\\[a-zA-Z@]+/)){var Ne=Xe.current().slice(1);return Ge=Oe.hasOwnProperty(Ne)?Oe[Ne]:Oe.DEFAULT,Ge=new Ge,Ae(Le,Ge),fe(Le,yt),Ge.style}if(Xe.match(/^\\[$&%#{}_]/)||Xe.match(/^\\[,;!\/\\]/))return"tag";if(Xe.match("\\["))return fe(Le,function(It,Bt){return Se(It,Bt,"\\]")}),"keyword";if(Xe.match("\\("))return fe(Le,function(It,Bt){return Se(It,Bt,"\\)")}),"keyword";if(Xe.match("$$"))return fe(Le,function(It,Bt){return Se(It,Bt,"$$")}),"keyword";if(Xe.match("$"))return fe(Le,function(It,Bt){return Se(It,Bt,"$")}),"keyword";var dt=Xe.next();if(dt=="%")return Xe.skipToEnd(),"comment";if(dt=="}"||dt=="]"){if(Ge=ye(Le),Ge)Ge.closeBracket(dt),fe(Le,yt);else return"error";return"bracket"}else return dt=="{"||dt=="["?(Ge=Oe.DEFAULT,Ge=new Ge,Ae(Le,Ge),"bracket"):/\d/.test(dt)?(Xe.eatWhile(/[\w.%]/),"atom"):(Xe.eatWhile(/[\w\-_]/),Ge=Me(Le),Ge.name=="begin"&&(Ge.argument=Xe.current()),Ge.styleIdentifier())}function Se(Xe,Le,Ge){if(Xe.eatSpace())return null;if(Ge&&Xe.match(Ge))return fe(Le,We),"keyword";if(Xe.match(/^\\[a-zA-Z@]+/))return"tag";if(Xe.match(/^[a-zA-Z]+/))return"variable-2";if(Xe.match(/^\\[$&%#{}_]/)||Xe.match(/^\\[,;!\/]/)||Xe.match(/^[\^_&]/))return"tag";if(Xe.match(/^[+\-<>|=,\/@!*:;'"`~#?]/))return null;if(Xe.match(/^(\d+\.\d*|\d*\.\d+|\d+)/))return"number";var Ne=Xe.next();return Ne=="{"||Ne=="}"||Ne=="["||Ne=="]"||Ne=="("||Ne==")"?"bracket":Ne=="%"?(Xe.skipToEnd(),"comment"):"error"}function yt(Xe,Le){var Ge=Xe.peek(),Ne;return Ge=="{"||Ge=="["?(Ne=ye(Le),Ne.openBracket(Ge),Xe.eat(Ge),fe(Le,We),"bracket"):/[ \t\r]/.test(Ge)?(Xe.eat(Ge),null):(fe(Le,We),be(Le),We(Xe,Le))}return{startState:function(){var Xe=ve.inMathMode?function(Le,Ge){return Se(Le,Ge)}:We;return{cmdState:[],f:Xe}},copyState:function(Xe){return{cmdState:Xe.cmdState.slice(),f:Xe.f}},token:function(Xe,Le){return Le.f(Xe,Le)},blankLine:function(Xe){Xe.f=We,Xe.cmdState.length=0},lineComment:"%"}}),z.defineMIME("text/x-stex","stex"),z.defineMIME("text/x-latex","stex")})},15525:function(ln,Ft,ie){(function(z){z(ie(89780))})(function(z){"use strict";var Ke={autoSelfClosers:{area:!0,base:!0,br:!0,col:!0,command:!0,embed:!0,frame:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0,menuitem:!0},implicitlyClosed:{dd:!0,li:!0,optgroup:!0,option:!0,p:!0,rp:!0,rt:!0,tbody:!0,td:!0,tfoot:!0,th:!0,tr:!0},contextGrabbers:{dd:{dd:!0,dt:!0},dt:{dd:!0,dt:!0},li:{li:!0},option:{option:!0,optgroup:!0},optgroup:{optgroup:!0},p:{address:!0,article:!0,aside:!0,blockquote:!0,dir:!0,div:!0,dl:!0,fieldset:!0,footer:!0,form:!0,h1:!0,h2:!0,h3:!0,h4:!0,h5:!0,h6:!0,header:!0,hgroup:!0,hr:!0,menu:!0,nav:!0,ol:!0,p:!0,pre:!0,section:!0,table:!0,ul:!0},rp:{rp:!0,rt:!0},rt:{rp:!0,rt:!0},tbody:{tbody:!0,tfoot:!0},td:{td:!0,th:!0},tfoot:{tbody:!0},th:{td:!0,th:!0},thead:{tbody:!0,tfoot:!0},tr:{tr:!0}},doNotIndent:{pre:!0},allowUnquoted:!0,allowMissing:!0,caseFold:!0},ve={autoSelfClosers:{},implicitlyClosed:{},contextGrabbers:{},doNotIndent:{},allowUnquoted:!1,allowMissing:!1,allowMissingTagName:!1,caseFold:!1};z.defineMode("xml",function(Ae,ye){var be=Ae.indentUnit,Me={},Re=ye.htmlMode?Ke:ve;for(var Oe in Re)Me[Oe]=Re[Oe];for(var Oe in ye)Me[Oe]=ye[Oe];var fe,We;function Se($e,at){function lt(De){return at.tokenize=De,De($e,at)}var me=$e.next();if(me=="<")return $e.eat("!")?$e.eat("[")?$e.match("CDATA[")?lt(Le("atom","]]>")):null:$e.match("--")?lt(Le("comment","-->")):$e.match("DOCTYPE",!0,!0)?($e.eatWhile(/[\w\._\-]/),lt(Ge(1))):null:$e.eat("?")?($e.eatWhile(/[\w\._\-]/),at.tokenize=Le("meta","?>"),"meta"):(fe=$e.eat("/")?"closeTag":"openTag",at.tokenize=yt,"tag bracket");if(me=="&"){var At;return $e.eat("#")?$e.eat("x")?At=$e.eatWhile(/[a-fA-F\d]/)&&$e.eat(";"):At=$e.eatWhile(/[\d]/)&&$e.eat(";"):At=$e.eatWhile(/[\w\.\-:]/)&&$e.eat(";"),At?"atom":"error"}else return $e.eatWhile(/[^&<]/),null}Se.isInText=!0;function yt($e,at){var lt=$e.next();if(lt==">"||lt=="/"&&$e.eat(">"))return at.tokenize=Se,fe=lt==">"?"endTag":"selfcloseTag","tag bracket";if(lt=="=")return fe="equals",null;if(lt=="<"){at.tokenize=Se,at.state=Bt,at.tagName=at.tagStart=null;var me=at.tokenize($e,at);return me?me+" tag error":"tag error"}else return/[\'\"]/.test(lt)?(at.tokenize=Xe(lt),at.stringStartCol=$e.column(),at.tokenize($e,at)):($e.match(/^[^\s\u00a0=<>\"\']*[^\s\u00a0=<>\"\'\/]/),"word")}function Xe($e){var at=function(lt,me){for(;!lt.eol();)if(lt.next()==$e){me.tokenize=yt;break}return"string"};return at.isInAttribute=!0,at}function Le($e,at){return function(lt,me){for(;!lt.eol();){if(lt.match(at)){me.tokenize=Se;break}lt.next()}return $e}}function Ge($e){return function(at,lt){for(var me;(me=at.next())!=null;){if(me=="<")return lt.tokenize=Ge($e+1),lt.tokenize(at,lt);if(me==">")if($e==1){lt.tokenize=Se;break}else return lt.tokenize=Ge($e-1),lt.tokenize(at,lt)}return"meta"}}function Ne($e,at,lt){this.prev=$e.context,this.tagName=at,this.indent=$e.indented,this.startOfLine=lt,(Me.doNotIndent.hasOwnProperty(at)||$e.context&&$e.context.noIndent)&&(this.noIndent=!0)}function dt($e){$e.context&&($e.context=$e.context.prev)}function It($e,at){for(var lt;;){if(!$e.context||(lt=$e.context.tagName,!Me.contextGrabbers.hasOwnProperty(lt)||!Me.contextGrabbers[lt].hasOwnProperty(at)))return;dt($e)}}function Bt($e,at,lt){return $e=="openTag"?(lt.tagStart=at.column(),mt):$e=="closeTag"?st:Bt}function mt($e,at,lt){return $e=="word"?(lt.tagName=at.current(),We="tag",Ot):Me.allowMissingTagName&&$e=="endTag"?(We="tag bracket",Ot($e,at,lt)):(We="error",mt)}function st($e,at,lt){if($e=="word"){var me=at.current();return lt.context&<.context.tagName!=me&&Me.implicitlyClosed.hasOwnProperty(lt.context.tagName)&&dt(lt),lt.context&<.context.tagName==me||Me.matchClosing===!1?(We="tag",it):(We="tag error",je)}else return Me.allowMissingTagName&&$e=="endTag"?(We="tag bracket",it($e,at,lt)):(We="error",je)}function it($e,at,lt){return $e!="endTag"?(We="error",it):(dt(lt),Bt)}function je($e,at,lt){return We="error",it($e,at,lt)}function Ot($e,at,lt){if($e=="word")return We="attribute",nt;if($e=="endTag"||$e=="selfcloseTag"){var me=lt.tagName,At=lt.tagStart;return lt.tagName=lt.tagStart=null,$e=="selfcloseTag"||Me.autoSelfClosers.hasOwnProperty(me)?It(lt,me):(It(lt,me),lt.context=new Ne(lt,me,At==lt.indented)),Bt}return We="error",Ot}function nt($e,at,lt){return $e=="equals"?tt:(Me.allowMissing||(We="error"),Ot($e,at,lt))}function tt($e,at,lt){return $e=="string"?ht:$e=="word"&&Me.allowUnquoted?(We="string",Ot):(We="error",Ot($e,at,lt))}function ht($e,at,lt){return $e=="string"?ht:Ot($e,at,lt)}return{startState:function($e){var at={tokenize:Se,state:Bt,indented:$e||0,tagName:null,tagStart:null,context:null};return $e!=null&&(at.baseIndent=$e),at},token:function($e,at){if(!at.tagName&&$e.sol()&&(at.indented=$e.indentation()),$e.eatSpace())return null;fe=null;var lt=at.tokenize($e,at);return(lt||fe)&<!="comment"&&(We=null,at.state=at.state(fe||lt,$e,at),We&&(lt=We=="error"?lt+" error":We)),lt},indent:function($e,at,lt){var me=$e.context;if($e.tokenize.isInAttribute)return $e.tagStart==$e.indented?$e.stringStartCol+1:$e.indented+be;if(me&&me.noIndent)return z.Pass;if($e.tokenize!=yt&&$e.tokenize!=Se)return lt?lt.match(/^(\s*)/)[0].length:0;if($e.tagName)return Me.multilineTagIndentPastTag!==!1?$e.tagStart+$e.tagName.length+2:$e.tagStart+be*(Me.multilineTagIndentFactor||1);if(Me.alignCDATA&&/<!\[CDATA\[/.test(at))return 0;var At=at&&/^<(\/)?([\w_:\.-]*)/.exec(at);if(At&&At[1])for(;me;)if(me.tagName==At[2]){me=me.prev;break}else if(Me.implicitlyClosed.hasOwnProperty(me.tagName))me=me.prev;else break;else if(At)for(;me;){var De=Me.contextGrabbers[me.tagName];if(De&&De.hasOwnProperty(At[2]))me=me.prev;else break}for(;me&&me.prev&&!me.startOfLine;)me=me.prev;return me?me.indent+be:$e.baseIndent||0},electricInput:/<\/[\s\w:]+>$/,blockCommentStart:"<!--",blockCommentEnd:"-->",configuration:Me.htmlMode?"html":"xml",helperType:Me.htmlMode?"html":"xml",skipAttribute:function($e){$e.state==tt&&($e.state=Ot)},xmlCurrentTag:function($e){return $e.tagName?{name:$e.tagName,close:$e.type=="closeTag"}:null},xmlCurrentContext:function($e){for(var at=[],lt=$e.context;lt;lt=lt.prev)lt.tagName&&at.push(lt.tagName);return at.reverse()}}}),z.defineMIME("text/xml","xml"),z.defineMIME("application/xml","xml"),z.mimeModes.hasOwnProperty("text/html")||z.defineMIME("text/html",{name:"xml",htmlMode:!0})})},2859:function(ln,Ft,ie){"use strict";ie.d(Ft,{hP:function(){return ut}});var z=function(ae,te){return(z=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(ee,oe){ee.__proto__=oe}||function(ee,oe){for(var se in oe)Object.prototype.hasOwnProperty.call(oe,se)&&(ee[se]=oe[se])})(ae,te)};function Ke(ae,te){function ee(){this.constructor=ae}z(ae,te),ae.prototype=te===null?Object.create(te):(ee.prototype=te.prototype,new ee)}function ve(ae,te,ee,oe){return new(ee||(ee=Promise))(function(se,ne){function he(Ee){try{ot(oe.next(Ee))}catch(Fe){ne(Fe)}}function xe(Ee){try{ot(oe.throw(Ee))}catch(Fe){ne(Fe)}}function ot(Ee){var Fe;Ee.done?se(Ee.value):(Fe=Ee.value,Fe instanceof ee?Fe:new ee(function(qe){qe(Fe)})).then(he,xe)}ot((oe=oe.apply(ae,te||[])).next())})}function Ae(ae,te){var ee,oe,se,ne,he={label:0,sent:function(){if(1&se[0])throw se[1];return se[1]},trys:[],ops:[]};return ne={next:xe(0),throw:xe(1),return:xe(2)},typeof Symbol=="function"&&(ne[Symbol.iterator]=function(){return this}),ne;function xe(ot){return function(Ee){return function(Fe){if(ee)throw new TypeError("Generator is already executing.");for(;he;)try{if(ee=1,oe&&(se=2&Fe[0]?oe.return:Fe[0]?oe.throw||((se=oe.return)&&se.call(oe),0):oe.next)&&!(se=se.call(oe,Fe[1])).done)return se;switch(oe=0,se&&(Fe=[2&Fe[0],se.value]),Fe[0]){case 0:case 1:se=Fe;break;case 4:return he.label++,{value:Fe[1],done:!1};case 5:he.label++,oe=Fe[1],Fe=[0];continue;case 7:Fe=he.ops.pop(),he.trys.pop();continue;default:if(se=he.trys,!((se=se.length>0&&se[se.length-1])||Fe[0]!==6&&Fe[0]!==2)){he=0;continue}if(Fe[0]===3&&(!se||Fe[1]>se[0]&&Fe[1]<se[3])){he.label=Fe[1];break}if(Fe[0]===6&&he.label<se[1]){he.label=se[1],se=Fe;break}if(se&&he.label<se[2]){he.label=se[2],he.ops.push(Fe);break}se[2]&&he.ops.pop(),he.trys.pop();continue}Fe=te.call(ae,he)}catch(qe){Fe=[6,qe],oe=0}finally{ee=se=0}if(5&Fe[0])throw Fe[1];return{value:Fe[0]?Fe[1]:void 0,done:!0}}([ot,Ee])}}}function ye(){for(var ae=0,te=0,ee=arguments.length;te<ee;te++)ae+=arguments[te].length;var oe=Array(ae),se=0;for(te=0;te<ee;te++)for(var ne=arguments[te],he=0,xe=ne.length;he<xe;he++,se++)oe[se]=ne[he];return oe}var be=function(){function ae(){}return ae.createDefs=function(){return document.createElementNS("http://www.w3.org/2000/svg","defs")},ae.setAttributes=function(te,ee){for(var oe=0,se=ee;oe<se.length;oe++){var ne=se[oe],he=ne[0],xe=ne[1];te.setAttribute(he,xe)}},ae.createRect=function(te,ee,oe){var se=document.createElementNS("http://www.w3.org/2000/svg","rect");return se.setAttribute("width",te.toString()),se.setAttribute("height",ee.toString()),oe&&ae.setAttributes(se,oe),se},ae.createLine=function(te,ee,oe,se,ne){var he=document.createElementNS("http://www.w3.org/2000/svg","line");return he.setAttribute("x1",te.toString()),he.setAttribute("y1",ee.toString()),he.setAttribute("x2",oe.toString()),he.setAttribute("y2",se.toString()),ne&&ae.setAttributes(he,ne),he},ae.createPolygon=function(te,ee){var oe=document.createElementNS("http://www.w3.org/2000/svg","polygon");return oe.setAttribute("points",te),ee&&ae.setAttributes(oe,ee),oe},ae.createCircle=function(te,ee){var oe=document.createElementNS("http://www.w3.org/2000/svg","circle");return oe.setAttribute("cx",(te/2).toString()),oe.setAttribute("cy",(te/2).toString()),oe.setAttribute("r",te.toString()),ee&&ae.setAttributes(oe,ee),oe},ae.createEllipse=function(te,ee,oe){var se=document.createElementNS("http://www.w3.org/2000/svg","ellipse");return se.setAttribute("cx",(te/2).toString()),se.setAttribute("cy",(ee/2).toString()),se.setAttribute("rx",(te/2).toString()),se.setAttribute("ry",(ee/2).toString()),oe&&ae.setAttributes(se,oe),se},ae.createGroup=function(te){var ee=document.createElementNS("http://www.w3.org/2000/svg","g");return te&&ae.setAttributes(ee,te),ee},ae.createTransform=function(){return document.createElementNS("http://www.w3.org/2000/svg","svg").createSVGTransform()},ae.createMarker=function(te,ee,oe,se,ne,he,xe){var ot=document.createElementNS("http://www.w3.org/2000/svg","marker");return ae.setAttributes(ot,[["id",te],["orient",ee],["markerWidth",oe.toString()],["markerHeight",se.toString()],["refX",ne.toString()],["refY",he.toString()]]),ot.appendChild(xe),ot},ae.createText=function(te){var ee=document.createElementNS("http://www.w3.org/2000/svg","text");return ee.setAttribute("x","0"),ee.setAttribute("y","0"),te&&ae.setAttributes(ee,te),ee},ae.createTSpan=function(te,ee){var oe=document.createElementNS("http://www.w3.org/2000/svg","tspan");return oe.textContent=te,ee&&ae.setAttributes(oe,ee),oe},ae.createImage=function(te){var ee=document.createElementNS("http://www.w3.org/2000/svg","image");return te&&ae.setAttributes(ee,te),ee},ae.createPoint=function(te,ee){var oe=document.createElementNS("http://www.w3.org/2000/svg","svg").createSVGPoint();return oe.x=te,oe.y=ee,oe},ae.createPath=function(te,ee){var oe=document.createElementNS("http://www.w3.org/2000/svg","path");return oe.setAttribute("d",te),ee&&ae.setAttributes(oe,ee),oe},ae}(),Me=function(){function ae(){}return ae.addKey=function(te){ae.key=te},Object.defineProperty(ae,"isLicensed",{get:function(){return!!ae.key&&new RegExp(/^MJS2-[A-Z][0-9]{3}-[A-Z][0-9]{3}-[0-9]{4}$/,"i").test(ae.key)},enumerable:!1,configurable:!0}),ae}(),Re=function(){function ae(){this.naturalSize=!1,this.imageType="image/png",this.markersOnly=!1}return ae.prototype.rasterize=function(te,ee,oe){var se=this;return new Promise(function(ne){var he=oe!==void 0?oe:document.createElement("canvas");te===null&&(se.markersOnly=!0,se.naturalSize=!1);var xe=document.createElementNS("http://www.w3.org/2000/svg","svg");xe.setAttribute("xmlns","http://www.w3.org/2000/svg"),xe.setAttribute("width",ee.width.baseVal.valueAsString),xe.setAttribute("height",ee.height.baseVal.valueAsString),xe.setAttribute("viewBox","0 0 "+ee.viewBox.baseVal.width.toString()+" "+ee.viewBox.baseVal.height.toString()),xe.innerHTML=ee.innerHTML,se.naturalSize===!0?(xe.width.baseVal.value=te.naturalWidth,xe.height.baseVal.value=te.naturalHeight):se.width!==void 0&&se.height!==void 0&&(xe.width.baseVal.value=se.width,xe.height.baseVal.value=se.height),he.width=xe.width.baseVal.value,he.height=xe.height.baseVal.value;var ot=xe.outerHTML,Ee=he.getContext("2d");se.markersOnly!==!0&&Ee.drawImage(te,0,0,he.width,he.height);var Fe=window.URL,qe=new Image(he.width,he.height);qe.setAttribute("crossOrigin","anonymous");var bt=new Blob([ot],{type:"image/svg+xml"}),ct=Fe.createObjectURL(bt);qe.onload=function(){Ee.drawImage(qe,0,0),Fe.revokeObjectURL(ct);var Kt=he.toDataURL(se.imageType,se.imageQuality);ne(Kt)},qe.src=ct})},ae}(),Oe=function(){},fe=function(){function ae(te){this._classNamePrefixBase="__markerjs2_",this.classes=[],this.rules=[],this.settings=this.defaultSettings,this._classNamePrefix=this._classNamePrefixBase+"_"+te+"_"}return Object.defineProperty(ae.prototype,"classNamePrefixBase",{get:function(){return this._classNamePrefixBase},enumerable:!1,configurable:!0}),Object.defineProperty(ae.prototype,"classNamePrefix",{get:function(){return this._classNamePrefix},enumerable:!1,configurable:!0}),Object.defineProperty(ae.prototype,"defaultSettings",{get:function(){return{canvasBackgroundColor:"#ffffff",toolbarBackgroundColor:"#111111",toolbarBackgroundHoverColor:"#333333",toolbarColor:"#eeeeee",toolbarHeight:40,toolboxColor:"#eeeeee",toolboxAccentColor:"#3080c3",undoButtonVisible:!0,redoButtonVisible:!1,zoomButtonVisible:!1,zoomOutButtonVisible:!1,clearButtonVisible:!1,resultButtonBlockVisible:!0,logoPosition:"left"}},enumerable:!1,configurable:!0}),Object.defineProperty(ae.prototype,"fadeInAnimationClassName",{get:function(){return this.classNamePrefix+"fade_in"},enumerable:!1,configurable:!0}),Object.defineProperty(ae.prototype,"fadeOutAnimationClassName",{get:function(){return this.classNamePrefix+"fade_out"},enumerable:!1,configurable:!0}),ae.prototype.addClass=function(te){return this.styleSheet===void 0&&this.addStyleSheet(),te.name=""+this.classNamePrefix+te.localName,this.classes.push(te),this.styleSheet.sheet.insertRule("."+te.name+" {"+te.style+"}",this.styleSheet.sheet.cssRules.length),te},ae.prototype.addRule=function(te){this.styleSheet===void 0&&this.addStyleSheet(),this.rules.push(te),this.styleSheet.sheet.insertRule(te.selector+" {"+te.style+"}",this.styleSheet.sheet.cssRules.length)},ae.prototype.addStyleSheet=function(){var te;this.styleSheet=document.createElement("style"),((te=this.styleSheetRoot)!==null&&te!==void 0?te:document.head).appendChild(this.styleSheet),this.addRule(new We("."+this.classNamePrefix+" h3","font-family: sans-serif")),this.addRule(new We("@keyframes "+this.classNamePrefix+"_fade_in_animation_frames",`
|
|
|
from {
|
|
|
opacity: 0;
|
|
|
}
|
|
|
to {
|
|
|
opacity: 1;
|
|
|
}
|
|
|
`)),this.addRule(new We("@keyframes "+this.classNamePrefix+"_fade_out_animation_frames",`
|
|
|
from {
|
|
|
opacity: 1;
|
|
|
}
|
|
|
to {
|
|
|
opacity: 0;
|
|
|
}
|
|
|
`)),this.addClass(new Se("fade_in",`
|
|
|
animation-duration: 0.3s;
|
|
|
animation-name: `+this.classNamePrefix+`_fade_in_animation_frames;
|
|
|
`)),this.addClass(new Se("fade_out",`
|
|
|
animation-duration: 0.3s;
|
|
|
animation-name: `+this.classNamePrefix+`_fade_out_animation_frames;
|
|
|
`))},ae.prototype.removeStyleSheet=function(){var te;this.styleSheet&&(((te=this.styleSheetRoot)!==null&&te!==void 0?te:document.head).removeChild(this.styleSheet),this.styleSheet=void 0)},ae}(),We=function(ae,te){this.selector=ae,this.style=te},Se=function(ae,te){this.localName=ae,this.style=te},yt=function(){function ae(te,ee,oe,se,ne){this.buttons=[],this.markerButtons=[],this.buttonClickListeners=[],this.markerjsContainer=te,this.displayMode=ee,this.markerItems=oe,this.uiStyleSettings=se,this.styles=ne,this.addStyles(),this.adjustLayout=this.adjustLayout.bind(this),this.overflowButtonClicked=this.overflowButtonClicked.bind(this),this.setCurrentMarker=this.setCurrentMarker.bind(this)}return ae.prototype.show=function(te){var ee=this;this.uiContainer=document.createElement("div"),this.uiContainer.style.visibility=te,this.uiContainer.className=this.toolbarStyleClass.name+" "+this.styles.fadeInAnimationClassName+" "+(this.uiStyleSettings.toolbarStyleColorsClassName?this.uiStyleSettings.toolbarStyleColorsClassName:this.toolbarStyleColorsClass.name);var oe=document.createElement("div");oe.className=this.toolbarBlockStyleClass.name,oe.style.whiteSpace="nowrap",this.uiContainer.appendChild(oe),this.addActionButton(oe,'<svg viewBox="0 0 24 24"><path d="M10.07 14.27a.997.997 0 011.33.48l2.3 4.99 1.8-.85-2.31-4.98c-.24-.5-.02-1.1.48-1.33l.28-.08 2.3-.45L8 5.12V15.9l1.82-1.47.25-.16m3.57 7.7a.99.99 0 01-1.33-.47l-2.18-4.74-2.51 2.02c-.17.14-.38.22-.62.22a1 1 0 01-1-1V3a1 1 0 011-1c.24 0 .47.09.64.23l.01-.01 11.49 9.64a1.001 1.001 0 01-.44 1.75l-3.16.62 2.2 4.73c.26.5.02 1.09-.48 1.32l-3.62 1.69z"/></svg>',"select"),this.addActionButton(oe,'<svg viewBox="0 0 24 24"><path d="M9 3v1H4v2h1v13a2 2 0 002 2h10a2 2 0 002-2V6h1V4h-5V3H9M7 6h10v13H7V6m2 2v9h2V8H9m4 0v9h2V8h-2z"/></svg>',"delete"),this.uiStyleSettings.clearButtonVisible&&this.addActionButton(oe,'<svg viewBox="0 0 24 24"><path d="M19.36 2.72l1.42 1.42-5.72 5.71c1.07 1.54 1.22 3.39.32 4.59L9.06 8.12c1.2-.9 3.05-.75 4.59.32l5.71-5.72M5.93 17.57c-2.01-2.01-3.24-4.41-3.58-6.65l4.88-2.09 7.44 7.44-2.09 4.88c-2.24-.34-4.64-1.57-6.65-3.58z"/></svg>',"clear"),this.uiStyleSettings.undoButtonVisible&&this.addActionButton(oe,'<svg viewBox="0 0 24 24"><path d="M12.5 8c-2.65 0-5.05 1-6.9 2.6L2 7v9h9l-3.62-3.62c1.39-1.16 3.16-1.88 5.12-1.88 3.54 0 6.55 2.31 7.6 5.5l2.37-.78C21.08 11.03 17.15 8 12.5 8z"/></svg>',"undo"),this.uiStyleSettings.redoButtonVisible&&this.addActionButton(oe,'<svg viewBox="0 0 24 24"><path d="M18.4 10.6C16.55 9 14.15 8 11.5 8c-4.65 0-8.58 3.03-9.96 7.22L3.9 16a8.002 8.002 0 017.6-5.5c1.95 0 3.73.72 5.12 1.88L13 16h9V7l-3.6 3.6z"/></svg>',"redo"),this.uiStyleSettings.zoomButtonVisible&&this.addActionButton(oe,'<svg viewBox="0 0 24 24"><path d="M15.5 14l5 5-1.5 1.5-5-5v-.79l-.27-.28A6.471 6.471 0 019.5 16 6.5 6.5 0 013 9.5 6.5 6.5 0 019.5 3 6.5 6.5 0 0116 9.5c0 1.61-.59 3.09-1.57 4.23l.28.27h.79m-6 0C12 14 14 12 14 9.5S12 5 9.5 5 5 7 5 9.5 7 14 9.5 14m2.5-4h-2v2H9v-2H7V9h2V7h1v2h2v1z"/></svg>',"zoom"),this.uiStyleSettings.zoomButtonVisible&&this.uiStyleSettings.zoomOutButtonVisible&&this.addActionButton(oe,'<svg viewBox="0 0 24 24"><path d="M15.5 14h-.79l-.28-.27A6.471 6.471 0 0016 9.5 6.5 6.5 0 009.5 3 6.5 6.5 0 003 9.5 6.5 6.5 0 009.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 5 1.5-1.5-5-5m-6 0C7 14 5 12 5 9.5S7 5 9.5 5 14 7 14 9.5 12 14 9.5 14M7 9h5v1H7V9z"/></svg>',"zoom-out"),this.uiStyleSettings.notesButtonVisible&&this.addActionButton(oe,'<svg viewBox="0 0 24 24"><path d="M18.13 12l1.26-1.26c.44-.44 1-.68 1.61-.74V9l-6-6H5c-1.11 0-2 .89-2 2v14a2 2 0 002 2h6v-1.87l.13-.13H5V5h7v7h6.13M14 4.5l5.5 5.5H14V4.5m5.13 9.33l2.04 2.04L15.04 22H13v-2.04l6.13-6.13m3.72.36l-.98.98-2.04-2.04.98-.98c.19-.2.52-.2.72 0l1.32 1.32c.2.2.2.53 0 .72z"/></svg>',"notes"),this.markerButtonBlock=document.createElement("div"),this.markerButtonBlock.className=this.toolbarBlockStyleClass.name,this.markerButtonBlock.style.flexGrow="2",this.markerButtonBlock.style.textAlign="center",this.uiContainer.appendChild(this.markerButtonBlock),this.markerButtonOverflowBlock=document.createElement("div"),this.markerButtonOverflowBlock.className=this.toolbarOverflowBlockStyleClass.name+" "+(this.uiStyleSettings.toolbarOverflowBlockStyleColorsClassName?this.uiStyleSettings.toolbarOverflowBlockStyleColorsClassName:this.toolbarOverflowBlockStyleColorsClass.name),this.markerButtonOverflowBlock.style.display="none",this.uiContainer.appendChild(this.markerButtonOverflowBlock),this.markerItems&&(this.markerItems.forEach(function(ne){var he=document.createElement("div");he.className=""+ee.toolbarButtonStyleClass.name,he.setAttribute("data-type-name",ne.typeName),he.innerHTML=ne.icon,he.addEventListener("click",function(){ee.markerToolbarButtonClicked(he,ne)}),ee.buttons.push(he),ee.markerButtons.push(he)}),this.overflowButton=document.createElement("div"),this.overflowButton.className=this.toolbarButtonStyleClass.name+" "+(this.uiStyleSettings.toolbarButtonStyleColorsClassName?this.uiStyleSettings.toolbarButtonStyleColorsClassName:this.toolbarButtonStyleColorsClass.name),this.overflowButton.innerHTML='<svg viewBox="0 0 24 24"><path d="M12 16a2 2 0 012 2 2 2 0 01-2 2 2 2 0 01-2-2 2 2 0 012-2m0-6a2 2 0 012 2 2 2 0 01-2 2 2 2 0 01-2-2 2 2 0 012-2m0-6a2 2 0 012 2 2 2 0 01-2 2 2 2 0 01-2-2 2 2 0 012-2z"/></svg>',this.overflowButton.addEventListener("click",this.overflowButtonClicked),this.markerButtonBlock.appendChild(this.overflowButton));var se=document.createElement("div");se.className=this.toolbarBlockStyleClass.name,se.style.whiteSpace="nowrap",se.style.display=this.uiStyleSettings.resultButtonBlockVisible!==!1?"":"none",this.uiContainer.appendChild(se),this.addActionButton(se,'<svg viewBox="0 0 24 24"><path d="M9 20.42l-6.21-6.21 2.83-2.83L9 14.77l9.88-9.89 2.83 2.83L9 20.42z"/></svg>',"render"),this.addActionButton(se,'<svg viewBox="0 0 24 24"><path d="M20 6.91L17.09 4 12 9.09 6.91 4 4 6.91 9.09 12 4 17.09 6.91 20 12 14.91 17.09 20 20 17.09 14.91 12 20 6.91z"/></svg>',"close"),this.markerjsContainer.appendChild(this.uiContainer),this.setSelectMode(),this.setCurrentMarker(),this.adjustLayout()},ae.prototype.addButtonClickListener=function(te){this.buttonClickListeners.push(te)},ae.prototype.removeButtonClickListener=function(te){this.buttonClickListeners.indexOf(te)>-1&&this.buttonClickListeners.splice(this.buttonClickListeners.indexOf(te),1)},ae.prototype.setSelectMode=function(){this.resetButtonStyles(),this.setActiveButton(this.buttons[0])},ae.prototype.adjustLayout=function(){if(this.markerButtons&&this.markerButtons.length>0){var te=Math.floor(this.markerButtonBlock.clientWidth/this.uiStyleSettings.toolbarHeight)-1;this.markerButtonBlock.innerHTML="",this.markerButtonOverflowBlock.innerHTML="";for(var ee=0;ee<this.markerButtons.length;ee++)ee<te||ee===te&&this.markerButtons.length-1===te?this.markerButtonBlock.appendChild(this.markerButtons[ee]):(ee===te&&this.markerButtonBlock.appendChild(this.overflowButton),this.markerButtonOverflowBlock.appendChild(this.markerButtons[ee]))}},ae.prototype.overflowButtonClicked=function(){this.markerButtonOverflowBlock.style.display!=="none"?(this.markerButtonOverflowBlock.className=this.markerButtonOverflowBlock.className.replace(this.styles.fadeInAnimationClassName,""),this.markerButtonOverflowBlock.style.display="none"):(this.markerButtonOverflowBlock.className+=" "+this.styles.fadeInAnimationClassName,this.markerButtonOverflowBlock.style.top=this.uiContainer.offsetTop+this.overflowButton.offsetHeight+"px",this.markerButtonOverflowBlock.style.right=this.uiContainer.offsetWidth-this.overflowButton.offsetLeft-this.overflowButton.offsetWidth+2*this.uiContainer.offsetLeft+"px",this.markerButtonOverflowBlock.style.display="inline-block")},ae.prototype.resetButtonStyles=function(){var te=this;this.buttons.forEach(function(ee){ee.className=ee.className.replace(te.uiStyleSettings.toolbarButtonStyleColorsClassName?te.uiStyleSettings.toolbarButtonStyleColorsClassName:te.toolbarButtonStyleColorsClass.name,"").trim(),ee.className=ee.className.replace(te.uiStyleSettings.toolbarActiveButtonStyleColorsClassName?te.uiStyleSettings.toolbarActiveButtonStyleColorsClassName:te.toolbarActiveButtonStyleColorsClass.name,"").trim(),ee.className+=" "+(te.uiStyleSettings.toolbarButtonStyleColorsClassName?te.uiStyleSettings.toolbarButtonStyleColorsClassName:te.toolbarButtonStyleColorsClass.name)})},ae.prototype.addActionButton=function(te,ee,oe){var se=this,ne=document.createElement("div");switch(ne.className=""+this.toolbarButtonStyleClass.name,ne.innerHTML=ee,ne.setAttribute("data-action",oe),ne.addEventListener("click",function(){se.actionToolbarButtonClicked(ne,oe)}),oe){case"select":ne.style.fill=this.uiStyleSettings.selectButtonColor;break;case"delete":case"clear":ne.style.fill=this.uiStyleSettings.deleteButtonColor;break;case"undo":case"redo":ne.style.fill=this.uiStyleSettings.selectButtonColor;break;case"render":ne.style.fill=this.uiStyleSettings.okButtonColor;break;case"close":ne.style.fill=this.uiStyleSettings.closeButtonColor}te.appendChild(ne),this.buttons.push(ne)},ae.prototype.addStyles=function(){this.toolbarStyleClass=this.styles.addClass(new Se("toolbar",`
|
|
|
width: 100%;
|
|
|
flex-shrink: 0;
|
|
|
display: flex;
|
|
|
flex-direction: row;
|
|
|
justify-content: space-between;
|
|
|
height: `+this.uiStyleSettings.toolbarHeight+`px;
|
|
|
box-sizing: content-box;
|
|
|
`+(this.displayMode==="inline"?"border-top-left-radius: "+Math.round(this.uiStyleSettings.toolbarHeight/10)+"px;":"")+`
|
|
|
`+(this.displayMode==="inline"?"border-top-right-radius: "+Math.round(this.uiStyleSettings.toolbarHeight/10)+"px;":"")+`
|
|
|
overflow: hidden;
|
|
|
`)),this.toolbarStyleColorsClass=this.styles.addClass(new Se("toolbar_colors",`
|
|
|
background-color: `+this.uiStyleSettings.toolbarBackgroundColor+`;
|
|
|
box-shadow: 0px 3px rgba(33, 33, 33, 0.1);
|
|
|
`)),this.toolbarBlockStyleClass=this.styles.addClass(new Se("toolbar-block",`
|
|
|
display: inline-block;
|
|
|
box-sizing: content-box;
|
|
|
`)),this.toolbarOverflowBlockStyleClass=this.styles.addClass(new Se("toolbar-overflow-block",`
|
|
|
position: absolute;
|
|
|
top: `+this.uiStyleSettings.toolbarHeight+`px;
|
|
|
max-width: `+2*this.uiStyleSettings.toolbarHeight+`px;
|
|
|
z-index: 10;
|
|
|
box-sizing: content-box;
|
|
|
`)),this.toolbarOverflowBlockStyleColorsClass=this.styles.addClass(new Se("toolbar-overflow-block_colors",`
|
|
|
background-color: `+this.uiStyleSettings.toolbarBackgroundColor+`;
|
|
|
`));var te=this.uiStyleSettings.toolbarHeight/4;this.toolbarButtonStyleClass=this.styles.addClass(new Se("toolbar_button",`
|
|
|
display: inline-block;
|
|
|
width: `+(this.uiStyleSettings.toolbarHeight-2*te)+`px;
|
|
|
height: `+(this.uiStyleSettings.toolbarHeight-2*te)+`px;
|
|
|
padding: `+te+`px;
|
|
|
box-sizing: content-box;
|
|
|
`)),this.toolbarButtonStyleColorsClass=this.styles.addClass(new Se("toolbar_button_colors",`
|
|
|
fill: `+this.uiStyleSettings.toolbarColor+`;
|
|
|
`)),this.toolbarActiveButtonStyleColorsClass=this.styles.addClass(new Se("toolbar_active_button",`
|
|
|
fill: `+this.uiStyleSettings.toolbarColor+`;
|
|
|
background-color: `+this.uiStyleSettings.toolbarBackgroundHoverColor+`
|
|
|
`)),this.styles.addRule(new We("."+this.toolbarButtonStyleClass.name+" svg",`
|
|
|
height: `+this.uiStyleSettings.toolbarHeight/2+`px;
|
|
|
`)),this.styles.addRule(new We("."+this.toolbarButtonStyleColorsClass.name+":hover",`
|
|
|
background-color: `+this.uiStyleSettings.toolbarBackgroundHoverColor+`
|
|
|
`))},ae.prototype.markerToolbarButtonClicked=function(te,ee){this.setActiveButton(te),this.buttonClickListeners&&this.buttonClickListeners.length>0&&this.buttonClickListeners.forEach(function(oe){return oe("marker",ee)}),this.markerButtonOverflowBlock.style.display="none"},ae.prototype.actionToolbarButtonClicked=function(te,ee){this.buttonClickListeners&&this.buttonClickListeners.length>0&&this.buttonClickListeners.forEach(function(oe){return oe("action",ee)}),this.markerButtonOverflowBlock.style.display="none",this.setActiveButton(this.buttons[0])},ae.prototype.setActiveButton=function(te){this.resetButtonStyles(),te.className=te.className.replace(this.uiStyleSettings.toolbarButtonStyleColorsClassName?this.uiStyleSettings.toolbarButtonStyleColorsClassName:this.toolbarButtonStyleColorsClass.name,"").trim(),te.className+=" "+(this.uiStyleSettings.toolbarActiveButtonStyleColorsClassName?this.uiStyleSettings.toolbarActiveButtonStyleColorsClassName:this.toolbarActiveButtonStyleColorsClass.name)},ae.prototype.setActiveMarkerButton=function(te){var ee=this.markerButtons.find(function(oe){return oe.getAttribute("data-type-name")===te});ee&&this.setActiveButton(ee)},ae.prototype.setCurrentMarker=function(te){var ee=this;this.currentMarker=te,this.buttons.filter(function(oe){return/delete|notes/.test(oe.getAttribute("data-action"))}).forEach(function(oe){ee.currentMarker===void 0?(oe.style.fillOpacity="0.4",oe.style.pointerEvents="none"):(oe.style.fillOpacity="1",oe.style.pointerEvents="all")})},ae}(),Xe=function(){function ae(te,ee,oe,se){this.panels=[],this.panelButtons=[],this.markerjsContainer=te,this.displayMode=ee,this.uiStyleSettings=oe,this.styles=se,this.panelButtonClick=this.panelButtonClick.bind(this),this.addStyles()}return ae.prototype.addStyles=function(){var te;this.toolboxStyleClass=this.styles.addClass(new Se("toolbox",`
|
|
|
width: 100%;
|
|
|
flex-shrink: 0;
|
|
|
display: flex;
|
|
|
flex-direction: column;
|
|
|
font-family: sans-serif;
|
|
|
`+(this.displayMode==="popup"?"height:"+2.5*this.uiStyleSettings.toolbarHeight+"px;":"")+`
|
|
|
box-sizing: content-box;
|
|
|
`+(this.displayMode==="popup"?"background-color: "+this.uiStyleSettings.canvasBackgroundColor+";":"")+`
|
|
|
`+(this.displayMode==="inline"?"border-bottom-left-radius: "+Math.round(this.uiStyleSettings.toolbarHeight/10)+"px;":"")+`
|
|
|
`+(this.displayMode==="inline"?"border-bottom-right-radius: "+Math.round(this.uiStyleSettings.toolbarHeight/10)+"px;":"")+`
|
|
|
overflow: hidden;
|
|
|
`)),this.toolboxStyleColorsClass=this.styles.addClass(new Se("toolbox_colors",`
|
|
|
color: `+this.uiStyleSettings.toolboxColor+`;
|
|
|
`));var ee=this.uiStyleSettings.toolbarHeight/4;this.toolboxButtonRowStyleClass=this.styles.addClass(new Se("toolbox-button-row",`
|
|
|
display: flex;
|
|
|
cursor: default;
|
|
|
box-sizing: content-box;
|
|
|
`)),this.toolboxButtonRowStyleColorsClass=this.styles.addClass(new Se("toolbox-button-row_colors",`
|
|
|
background-color: `+this.uiStyleSettings.toolbarBackgroundColor+`;
|
|
|
`)),this.toolboxPanelRowStyleClass=this.styles.addClass(new Se("toolbox-panel-row",`
|
|
|
display: flex;
|
|
|
`+(this.displayMode==="inline"?"position: absolute;":"")+`
|
|
|
`+(this.displayMode==="inline"?"bottom: "+this.uiStyleSettings.toolbarHeight+"px;":"")+`
|
|
|
cursor: default;
|
|
|
height: `+1.5*this.uiStyleSettings.toolbarHeight+`px;
|
|
|
`+(this.displayMode==="inline"?"width: 100%;":"")+`
|
|
|
box-sizing: content-box;
|
|
|
`)),this.toolboxPanelRowStyleColorsClass=this.styles.addClass(new Se("toolbox-panel-row_colors",`
|
|
|
background-color: `+((te=this.uiStyleSettings.toolboxBackgroundColor)!==null&&te!==void 0?te:this.uiStyleSettings.toolbarBackgroundHoverColor)+`;
|
|
|
`)),this.toolboxButtonStyleClass=this.styles.addClass(new Se("toolbox_button",`
|
|
|
display: inline-block;
|
|
|
width: `+(this.uiStyleSettings.toolbarHeight-2*ee)+`px;
|
|
|
height: `+(this.uiStyleSettings.toolbarHeight-2*ee)+`px;
|
|
|
padding: `+ee+`px;
|
|
|
box-sizing: content-box;
|
|
|
`)),this.toolboxButtonStyleColorsClass=this.styles.addClass(new Se("toolbox-button_colors",`
|
|
|
fill: `+this.uiStyleSettings.toolbarColor+`;
|
|
|
`)),this.toolboxActiveButtonStyleColorsClass=this.styles.addClass(new Se("toolbox-active-button_colors",`
|
|
|
background-color: `+this.uiStyleSettings.toolbarBackgroundHoverColor+`;
|
|
|
fill: `+this.uiStyleSettings.toolbarColor+`;
|
|
|
`)),this.styles.addRule(new We("."+this.toolboxButtonStyleColorsClass.name+":hover",`
|
|
|
background-color: `+this.uiStyleSettings.toolbarBackgroundHoverColor+`
|
|
|
`)),this.styles.addRule(new We("."+this.toolboxButtonStyleClass.name+" svg",`
|
|
|
height: `+this.uiStyleSettings.toolbarHeight/2+`px;
|
|
|
`))},ae.prototype.show=function(te){var ee;this.uiContainer=document.createElement("div"),this.uiContainer.style.visibility=te,this.uiContainer.className=this.toolboxStyleClass.name+" "+((ee=this.uiStyleSettings.toolboxStyleColorsClassName)!==null&&ee!==void 0?ee:this.toolboxStyleColorsClass.name),this.markerjsContainer.appendChild(this.uiContainer)},ae.prototype.setPanelButtons=function(te){var ee,oe,se=this;this.panels=te,this.uiContainer!==void 0&&(this.uiContainer.innerHTML="",this.panelRow=document.createElement("div"),this.panelRow.className=this.toolboxPanelRowStyleClass.name+" "+((ee=this.uiStyleSettings.toolboxPanelRowStyleColorsClassName)!==null&&ee!==void 0?ee:this.toolboxPanelRowStyleColorsClass.name),this.uiContainer.appendChild(this.panelRow),this.buttonRow=document.createElement("div"),this.buttonRow.className=this.toolboxButtonRowStyleClass.name+" "+((oe=this.uiStyleSettings.toolboxButtonRowStyleColorsClassName)!==null&&oe!==void 0?oe:this.toolboxButtonRowStyleColorsClass.name)+" ",this.uiContainer.appendChild(this.buttonRow),this.panelButtons.splice(0),this.panels.forEach(function(ne){var he;ne.uiStyleSettings=se.uiStyleSettings;var xe=document.createElement("div");xe.className=se.toolboxButtonStyleClass.name+" "+((he=se.uiStyleSettings.toolboxButtonStyleColorsClassName)!==null&&he!==void 0?he:se.toolboxButtonStyleColorsClass.name),xe.innerHTML=ne.icon,xe.title=ne.title,xe.addEventListener("click",function(){se.panelButtonClick(ne)}),se.panelButtons.push(xe),se.buttonRow.appendChild(xe)}),this.displayMode==="inline"?this.panelRow.style.display="none":this.panelRow.style.visibility="hidden")},ae.prototype.panelButtonClick=function(te){var ee=this,oe=-1;if(te!==this.activePanel){oe=this.panels.indexOf(te),this.panelRow.innerHTML="";var se=te.getUi();se.style.margin=this.uiStyleSettings.toolbarHeight/4+"px",this.panelRow.appendChild(se),this.panelRow.style.display="flex",this.panelRow.style.visibility="visible",this.panelRow.className=this.panelRow.className.replace(this.styles.fadeOutAnimationClassName,""),this.panelRow.className+=" "+this.styles.fadeInAnimationClassName,this.activePanel=te}else this.activePanel=void 0,this.panelRow.className=this.panelRow.className.replace(this.styles.fadeInAnimationClassName,""),this.panelRow.className+=" "+this.styles.fadeOutAnimationClassName,setTimeout(function(){ee.displayMode==="inline"?ee.panelRow.style.display="none":ee.panelRow.style.visibility="hidden"},200);this.panelButtons.forEach(function(ne,he){var xe,ot;ne.className=ee.toolboxButtonStyleClass.name+" "+(he===oe?""+((xe=ee.uiStyleSettings.toolboxActiveButtonStyleColorsClassName)!==null&&xe!==void 0?xe:ee.toolboxActiveButtonStyleColorsClass.name):""+((ot=ee.uiStyleSettings.toolboxButtonStyleColorsClassName)!==null&&ot!==void 0?ot:ee.toolboxButtonStyleColorsClass.name))})},ae}(),Le=function(ae,te){this.title=ae,this.icon=te},Ge=function(ae){function te(ee,oe,se,ne){var he=ae.call(this,ee,ne||'<svg viewBox="0 0 24 24"><path d="M17.5 12a1.5 1.5 0 01-1.5-1.5A1.5 1.5 0 0117.5 9a1.5 1.5 0 011.5 1.5 1.5 1.5 0 01-1.5 1.5m-3-4A1.5 1.5 0 0113 6.5 1.5 1.5 0 0114.5 5 1.5 1.5 0 0116 6.5 1.5 1.5 0 0114.5 8m-5 0A1.5 1.5 0 018 6.5 1.5 1.5 0 019.5 5 1.5 1.5 0 0111 6.5 1.5 1.5 0 019.5 8m-3 4A1.5 1.5 0 015 10.5 1.5 1.5 0 016.5 9 1.5 1.5 0 018 10.5 1.5 1.5 0 016.5 12M12 3a9 9 0 00-9 9 9 9 0 009 9 1.5 1.5 0 001.5-1.5c0-.39-.15-.74-.39-1-.23-.27-.38-.62-.38-1a1.5 1.5 0 011.5-1.5H16a5 5 0 005-5c0-4.42-4.03-8-9-8z"/></svg>')||this;return he.colors=[],he.addTransparent=!1,he.colorBoxes=[],he.colors=oe,he.currentColor=se,he.setCurrentColor=he.setCurrentColor.bind(he),he.getColorBox=he.getColorBox.bind(he),he}return Ke(te,ae),te.prototype.getUi=function(){var ee=this,oe=document.createElement("div");return oe.style.overflow="hidden",oe.style.whiteSpace="nowrap",this.colors.forEach(function(se){var ne=ee.getColorBox(se);oe.appendChild(ne),ee.colorBoxes.push(ne)}),oe},te.prototype.getColorBox=function(ee){var oe=this,se=this.uiStyleSettings.toolbarHeight/4,ne=this.uiStyleSettings.toolbarHeight-se,he=document.createElement("div");he.style.display="inline-block",he.style.boxSizing="content-box",he.style.width=ne-2+"px",he.style.height=ne-2+"px",he.style.padding="1px",he.style.marginRight="2px",he.style.marginBottom="2px",he.style.borderWidth="2px",he.style.borderStyle="solid",he.style.borderRadius=(ne+2)/2+"px",he.style.borderColor=ee===this.currentColor?this.uiStyleSettings.toolboxAccentColor:"transparent",he.addEventListener("click",function(){oe.setCurrentColor(ee,he)});var xe=document.createElement("div");return xe.style.display="inline-block",xe.style.width=ne-2+"px",xe.style.height=ne-2+"px",xe.style.backgroundColor=ee,xe.style.borderRadius=ne/2+"px",ee==="transparent"&&(xe.style.fill=this.uiStyleSettings.toolboxAccentColor,xe.innerHTML=`<svg viewBox="0 0 24 24">
|
|
|
<path d="M2,5.27L3.28,4L20,20.72L18.73,22L15.65,18.92C14.5,19.3 13.28,19.5 12,19.5C7,19.5 2.73,16.39 1,12C1.69,10.24 2.79,8.69 4.19,7.46L2,5.27M12,9A3,3 0 0,1 15,12C15,12.35 14.94,12.69 14.83,13L11,9.17C11.31,9.06 11.65,9 12,9M12,4.5C17,4.5 21.27,7.61 23,12C22.18,14.08 20.79,15.88 19,17.19L17.58,15.76C18.94,14.82 20.06,13.54 20.82,12C19.17,8.64 15.76,6.5 12,6.5C10.91,6.5 9.84,6.68 8.84,7L7.3,5.47C8.74,4.85 10.33,4.5 12,4.5M3.18,12C4.83,15.36 8.24,17.5 12,17.5C12.69,17.5 13.37,17.43 14,17.29L11.72,15C10.29,14.85 9.15,13.71 9,12.28L5.6,8.87C4.61,9.72 3.78,10.78 3.18,12Z" />
|
|
|
</svg>`),he.appendChild(xe),he},te.prototype.setCurrentColor=function(ee,oe){var se=this;this.currentColor=ee,this.colorBoxes.forEach(function(ne){ne.style.borderColor=ne===oe?se.uiStyleSettings.toolboxAccentColor:"transparent"}),this.onColorChanged&&this.onColorChanged(ee)},te}(Le),Ne=function(){function ae(te,ee,oe){this._state="new",this._isSelected=!1,this._container=te,this._overlayContainer=ee,this.globalSettings=oe,this.stateChanged=this.stateChanged.bind(this),this.colorChanged=this.colorChanged.bind(this),this.fillColorChanged=this.fillColorChanged.bind(this)}return Object.defineProperty(ae.prototype,"typeName",{get:function(){return Object.getPrototypeOf(this).constructor.typeName},enumerable:!1,configurable:!0}),Object.defineProperty(ae.prototype,"container",{get:function(){return this._container},enumerable:!1,configurable:!0}),Object.defineProperty(ae.prototype,"overlayContainer",{get:function(){return this._overlayContainer},enumerable:!1,configurable:!0}),Object.defineProperty(ae.prototype,"state",{get:function(){return this._state},enumerable:!1,configurable:!0}),Object.defineProperty(ae.prototype,"toolboxPanels",{get:function(){return[]},enumerable:!1,configurable:!0}),ae.prototype.ownsTarget=function(te){return!1},Object.defineProperty(ae.prototype,"isSelected",{get:function(){return this._isSelected},enumerable:!1,configurable:!0}),ae.prototype.select=function(){this.container.style.cursor="move",this._isSelected=!0,this.manipulationStartState=this.getState()},ae.prototype.deselect=function(){this.container.style.cursor="default",this._isSelected=!1,this.stateChanged()},ae.prototype.pointerDown=function(te,ee){},ae.prototype.dblClick=function(te,ee){},ae.prototype.manipulate=function(te){},ae.prototype.pointerUp=function(te){this.stateChanged()},ae.prototype.dispose=function(){},ae.prototype.addMarkerVisualToContainer=function(te){this.container.childNodes.length>0?this.container.insertBefore(te,this.container.childNodes[0]):this.container.appendChild(te)},ae.prototype.getState=function(){return{typeName:ae.typeName,state:this.state,notes:this.notes}},ae.prototype.restoreState=function(te){this._state=te.state,this.notes=te.notes},ae.prototype.scale=function(te,ee){},ae.prototype.colorChanged=function(te){this.onColorChanged&&this.onColorChanged(te),this.stateChanged()},ae.prototype.fillColorChanged=function(te){this.onFillColorChanged&&this.onFillColorChanged(te),this.stateChanged()},ae.prototype.stateChanged=function(){if(this.onStateChanged&&this.state!=="creating"&&this.state!=="new"){var te=this.getState();this.manipulationStartState!==void 0&&(this.manipulationStartState.state="select"),te.state="select",JSON.stringify(this.manipulationStartState)!=JSON.stringify(te)&&this.onStateChanged(this)}},ae.typeName="MarkerBase",ae}(),dt=function(){function ae(){this.findGripByVisual=this.findGripByVisual.bind(this)}return ae.prototype.findGripByVisual=function(te){return this.topLeft.ownsTarget(te)?this.topLeft:this.topCenter.ownsTarget(te)?this.topCenter:this.topRight.ownsTarget(te)?this.topRight:this.centerLeft.ownsTarget(te)?this.centerLeft:this.centerRight.ownsTarget(te)?this.centerRight:this.bottomLeft.ownsTarget(te)?this.bottomLeft:this.bottomCenter.ownsTarget(te)?this.bottomCenter:this.bottomRight.ownsTarget(te)?this.bottomRight:void 0},ae}(),It=function(){function ae(){this.GRIP_SIZE=10,this.visual=be.createGroup(),this.visual.appendChild(be.createCircle(1.5*this.GRIP_SIZE,[["fill","transparent"]])),this.visual.appendChild(be.createCircle(this.GRIP_SIZE,[["fill","#cccccc"],["fill-opacity","0.7"],["stroke","#333333"],["stroke-width","2"],["stroke-opacity","0.7"]]))}return ae.prototype.ownsTarget=function(te){return te===this.visual||te===this.visual.childNodes[0]||te===this.visual.childNodes[1]},ae}(),Bt=function(){function ae(){}return ae.toITransformMatrix=function(te){return{a:te.a,b:te.b,c:te.c,d:te.d,e:te.e,f:te.f}},ae.toSVGMatrix=function(te,ee){return te.a=ee.a,te.b=ee.b,te.c=ee.c,te.d=ee.d,te.e=ee.e,te.f=ee.f,te},ae}(),mt=function(ae){function te(ee,oe,se){var ne=ae.call(this,ee,oe,se)||this;return ne.left=0,ne.top=0,ne.width=0,ne.height=0,ne.defaultSize={x:50,y:20},ne.offsetX=0,ne.offsetY=0,ne.rotationAngle=0,ne.CB_DISTANCE=10,ne._suppressMarkerCreateEvent=!1,ne.container.transform.baseVal.appendItem(be.createTransform()),ne.setupControlBox(),ne}return Ke(te,ae),Object.defineProperty(te.prototype,"centerX",{get:function(){return this.left+this.width/2},enumerable:!1,configurable:!0}),Object.defineProperty(te.prototype,"centerY",{get:function(){return this.top+this.height/2},enumerable:!1,configurable:!0}),Object.defineProperty(te.prototype,"visual",{get:function(){return this._visual},set:function(ee){this._visual=ee;var oe=be.createTransform();this._visual.transform.baseVal.appendItem(oe)},enumerable:!1,configurable:!0}),te.prototype.ownsTarget=function(ee){return!!ae.prototype.ownsTarget.call(this,ee)||!!(this.controlGrips.findGripByVisual(ee)!==void 0||this.rotatorGrip!==void 0&&this.rotatorGrip.ownsTarget(ee))},te.prototype.pointerDown=function(ee,oe){ae.prototype.pointerDown.call(this,ee,oe),this.state==="new"&&(this.left=ee.x,this.top=ee.y),this.manipulationStartLeft=this.left,this.manipulationStartTop=this.top,this.manipulationStartWidth=this.width,this.manipulationStartHeight=this.height;var se=this.unrotatePoint(ee);if(this.manipulationStartX=se.x,this.manipulationStartY=se.y,this.offsetX=se.x-this.left,this.offsetY=se.y-this.top,this.state!=="new")if(this.select(),this.activeGrip=this.controlGrips.findGripByVisual(oe),this.activeGrip!==void 0)this._state="resize";else if(this.rotatorGrip!==void 0&&this.rotatorGrip.ownsTarget(oe)){this.activeGrip=this.rotatorGrip;var ne=this.rotatePoint({x:this.centerX,y:this.centerY});this.left=ne.x-this.width/2,this.top=ne.y-this.height/2,this.moveVisual({x:this.left,y:this.top});var he=this.container.transform.baseVal.getItem(0);he.setRotate(this.rotationAngle,this.centerX,this.centerY),this.container.transform.baseVal.replaceItem(he,0),this.adjustControlBox(),this._state="rotate"}else this._state="move"},te.prototype.pointerUp=function(ee){var oe=this.state;ae.prototype.pointerUp.call(this,ee),this.state==="creating"&&this.width<10&&this.height<10?(this.width=this.defaultSize.x,this.height=this.defaultSize.y):this.manipulate(ee),this._state="select",oe==="creating"&&this.onMarkerCreated&&this._suppressMarkerCreateEvent===!1&&this.onMarkerCreated(this)},te.prototype.moveVisual=function(ee){this.visual.style.transform="translate("+ee.x+"px, "+ee.y+"px)"},te.prototype.manipulate=function(ee){var oe=this.unrotatePoint(ee);this.state==="creating"?this.resize(ee):this.state==="move"?(this.left=this.manipulationStartLeft+(oe.x-this.manipulationStartLeft)-this.offsetX,this.top=this.manipulationStartTop+(oe.y-this.manipulationStartTop)-this.offsetY,this.moveVisual({x:this.left,y:this.top}),this.adjustControlBox()):this.state==="resize"?this.resize(oe):this.state==="rotate"&&this.rotate(ee)},te.prototype.resize=function(ee){var oe=this.manipulationStartLeft,se=this.manipulationStartWidth,ne=this.manipulationStartTop,he=this.manipulationStartHeight;switch(this.activeGrip){case this.controlGrips.bottomLeft:case this.controlGrips.centerLeft:case this.controlGrips.topLeft:oe=this.manipulationStartLeft+ee.x-this.manipulationStartX,se=this.manipulationStartWidth+this.manipulationStartLeft-oe;break;case this.controlGrips.bottomRight:case this.controlGrips.centerRight:case this.controlGrips.topRight:case void 0:se=this.manipulationStartWidth+ee.x-this.manipulationStartX}switch(this.activeGrip){case this.controlGrips.topCenter:case this.controlGrips.topLeft:case this.controlGrips.topRight:ne=this.manipulationStartTop+ee.y-this.manipulationStartY,he=this.manipulationStartHeight+this.manipulationStartTop-ne;break;case this.controlGrips.bottomCenter:case this.controlGrips.bottomLeft:case this.controlGrips.bottomRight:case void 0:he=this.manipulationStartHeight+ee.y-this.manipulationStartY}se>=0?(this.left=oe,this.width=se):(this.left=oe+se,this.width=-se),he>=0?(this.top=ne,this.height=he):(this.top=ne+he,this.height=-he),this.setSize()},te.prototype.setSize=function(){this.moveVisual({x:this.left,y:this.top}),this.adjustControlBox()},te.prototype.rotate=function(ee){if(Math.abs(ee.x-this.centerX)>.1){var oe=Math.sign(ee.x-this.centerX);this.rotationAngle=180*Math.atan((ee.y-this.centerY)/(ee.x-this.centerX))/Math.PI+90*oe,this.applyRotation()}},te.prototype.applyRotation=function(){var ee=this.container.transform.baseVal.getItem(0);ee.setRotate(this.rotationAngle,this.centerX,this.centerY),this.container.transform.baseVal.replaceItem(ee,0)},te.prototype.rotatePoint=function(ee){if(this.rotationAngle===0)return ee;var oe=this.container.getCTM(),se=be.createPoint(ee.x,ee.y);return{x:(se=se.matrixTransform(oe)).x,y:se.y}},te.prototype.unrotatePoint=function(ee){if(this.rotationAngle===0)return ee;var oe=this.container.getCTM();oe=oe.inverse();var se=be.createPoint(ee.x,ee.y);return{x:(se=se.matrixTransform(oe)).x,y:se.y}},te.prototype.select=function(){ae.prototype.select.call(this),this.adjustControlBox(),this.controlBox.style.display=""},te.prototype.deselect=function(){ae.prototype.deselect.call(this),this.controlBox.style.display="none"},te.prototype.setupControlBox=function(){this.controlBox=be.createGroup();var ee=be.createTransform();ee.setTranslate(-this.CB_DISTANCE/2,-this.CB_DISTANCE/2),this.controlBox.transform.baseVal.appendItem(ee),this.container.appendChild(this.controlBox),this.controlRect=be.createRect(this.width+this.CB_DISTANCE,this.height+this.CB_DISTANCE,[["stroke","black"],["stroke-width","1"],["stroke-opacity","0.5"],["stroke-dasharray","3, 2"],["fill","transparent"],["pointer-events","none"]]),this.controlBox.appendChild(this.controlRect),this.globalSettings.disableRotation!==!0&&(this.rotatorGripLine=be.createLine((this.width+2*this.CB_DISTANCE)/2,this.top-this.CB_DISTANCE,(this.width+2*this.CB_DISTANCE)/2,this.top-3*this.CB_DISTANCE,[["stroke","black"],["stroke-width","1"],["stroke-opacity","0.5"],["stroke-dasharray","3, 2"]]),this.controlBox.appendChild(this.rotatorGripLine)),this.controlGrips=new dt,this.addControlGrips(),this.controlBox.style.display="none"},te.prototype.adjustControlBox=function(){var ee=this.controlBox.transform.baseVal.getItem(0);ee.setTranslate(this.left-this.CB_DISTANCE/2,this.top-this.CB_DISTANCE/2),this.controlBox.transform.baseVal.replaceItem(ee,0),this.controlRect.setAttribute("width",(this.width+this.CB_DISTANCE).toString()),this.controlRect.setAttribute("height",(this.height+this.CB_DISTANCE).toString()),this.rotatorGripLine!==void 0&&(this.rotatorGripLine.setAttribute("x1",((this.width+this.CB_DISTANCE)/2).toString()),this.rotatorGripLine.setAttribute("y1",(-this.CB_DISTANCE/2).toString()),this.rotatorGripLine.setAttribute("x2",((this.width+this.CB_DISTANCE)/2).toString()),this.rotatorGripLine.setAttribute("y2",(3*-this.CB_DISTANCE).toString())),this.positionGrips()},te.prototype.addControlGrips=function(){this.controlGrips.topLeft=this.createGrip(),this.controlGrips.topCenter=this.createGrip(),this.controlGrips.topRight=this.createGrip(),this.controlGrips.centerLeft=this.createGrip(),this.controlGrips.centerRight=this.createGrip(),this.controlGrips.bottomLeft=this.createGrip(),this.controlGrips.bottomCenter=this.createGrip(),this.controlGrips.bottomRight=this.createGrip(),this.globalSettings.disableRotation!==!0&&(this.rotatorGrip=this.createGrip()),this.positionGrips()},te.prototype.createGrip=function(){var ee=new It;return ee.visual.transform.baseVal.appendItem(be.createTransform()),this.controlBox.appendChild(ee.visual),ee},te.prototype.positionGrips=function(){var ee=this.controlGrips.topLeft.GRIP_SIZE,oe=-ee/2,se=oe,ne=(this.width+this.CB_DISTANCE)/2-ee/2,he=(this.height+this.CB_DISTANCE)/2-ee/2,xe=this.height+this.CB_DISTANCE-ee/2,ot=this.width+this.CB_DISTANCE-ee/2;this.positionGrip(this.controlGrips.topLeft.visual,oe,se),this.positionGrip(this.controlGrips.topCenter.visual,ne,se),this.positionGrip(this.controlGrips.topRight.visual,ot,se),this.positionGrip(this.controlGrips.centerLeft.visual,oe,he),this.positionGrip(this.controlGrips.centerRight.visual,ot,he),this.positionGrip(this.controlGrips.bottomLeft.visual,oe,xe),this.positionGrip(this.controlGrips.bottomCenter.visual,ne,xe),this.positionGrip(this.controlGrips.bottomRight.visual,ot,xe),this.rotatorGrip!==void 0&&this.positionGrip(this.rotatorGrip.visual,ne,se-3*this.CB_DISTANCE)},te.prototype.positionGrip=function(ee,oe,se){var ne=ee.transform.baseVal.getItem(0);ne.setTranslate(oe,se),ee.transform.baseVal.replaceItem(ne,0)},te.prototype.hideControlBox=function(){this.controlBox.style.display="none"},te.prototype.showControlBox=function(){this.controlBox.style.display=""},te.prototype.getState=function(){return Object.assign({left:this.left,top:this.top,width:this.width,height:this.height,rotationAngle:this.rotationAngle,visualTransformMatrix:Bt.toITransformMatrix(this.visual.transform.baseVal.getItem(0).matrix),containerTransformMatrix:Bt.toITransformMatrix(this.container.transform.baseVal.getItem(0).matrix)},ae.prototype.getState.call(this))},te.prototype.restoreState=function(ee){ae.prototype.restoreState.call(this,ee);var oe=ee;this.left=oe.left,this.top=oe.top,this.width=oe.width,this.height=oe.height,this.rotationAngle=oe.rotationAngle,this.visual.transform.baseVal.getItem(0).setMatrix(Bt.toSVGMatrix(this.visual.transform.baseVal.getItem(0).matrix,oe.visualTransformMatrix)),this.container.transform.baseVal.getItem(0).setMatrix(Bt.toSVGMatrix(this.container.transform.baseVal.getItem(0).matrix,oe.containerTransformMatrix))},te.prototype.scale=function(ee,oe){ae.prototype.scale.call(this,ee,oe);var se=this.rotatePoint({x:this.left,y:this.top}),ne=this.unrotatePoint({x:se.x*ee,y:se.y*oe});this.left=ne.x,this.top=ne.y,this.width=this.width*ee,this.height=this.height*oe,this.adjustControlBox()},te}(Ne),st=function(ae){function te(ee,oe,se){var ne=ae.call(this,ee,oe,se)||this;return ne.fillColor="transparent",ne.strokeColor="transparent",ne.strokeWidth=0,ne.strokeDasharray="",ne.opacity=1,ne.setStrokeColor=ne.setStrokeColor.bind(ne),ne.setFillColor=ne.setFillColor.bind(ne),ne.setStrokeWidth=ne.setStrokeWidth.bind(ne),ne.setStrokeDasharray=ne.setStrokeDasharray.bind(ne),ne.createVisual=ne.createVisual.bind(ne),ne}return Ke(te,ae),te.prototype.ownsTarget=function(ee){return!(!ae.prototype.ownsTarget.call(this,ee)&&ee!==this.visual)},te.prototype.createVisual=function(){this.visual=be.createRect(1,1,[["fill",this.fillColor],["stroke",this.strokeColor],["stroke-width",this.strokeWidth.toString()],["stroke-dasharray",this.strokeDasharray],["opacity",this.opacity.toString()]]),this.addMarkerVisualToContainer(this.visual)},te.prototype.pointerDown=function(ee,oe){ae.prototype.pointerDown.call(this,ee,oe),this.state==="new"&&(this.createVisual(),this.moveVisual(ee),this._state="creating")},te.prototype.manipulate=function(ee){ae.prototype.manipulate.call(this,ee)},te.prototype.resize=function(ee){ae.prototype.resize.call(this,ee),this.setSize()},te.prototype.setSize=function(){ae.prototype.setSize.call(this),be.setAttributes(this.visual,[["width",this.width.toString()],["height",this.height.toString()]])},te.prototype.pointerUp=function(ee){ae.prototype.pointerUp.call(this,ee),this.setSize()},te.prototype.setStrokeColor=function(ee){this.strokeColor=ee,this.visual&&be.setAttributes(this.visual,[["stroke",this.strokeColor]]),this.colorChanged(ee),this.stateChanged()},te.prototype.setFillColor=function(ee){this.fillColor=ee,this.visual&&be.setAttributes(this.visual,[["fill",this.fillColor]]),this.stateChanged()},te.prototype.setStrokeWidth=function(ee){this.strokeWidth=ee,this.visual&&be.setAttributes(this.visual,[["stroke-width",this.strokeWidth.toString()]]),this.stateChanged()},te.prototype.setStrokeDasharray=function(ee){this.strokeDasharray=ee,this.visual&&be.setAttributes(this.visual,[["stroke-dasharray",this.strokeDasharray]]),this.stateChanged()},te.prototype.getState=function(){return Object.assign({fillColor:this.fillColor,strokeColor:this.strokeColor,strokeWidth:this.strokeWidth,strokeDasharray:this.strokeDasharray,opacity:this.opacity},ae.prototype.getState.call(this))},te.prototype.restoreState=function(ee){var oe=ee;this.fillColor=oe.fillColor,this.strokeColor=oe.strokeColor,this.strokeWidth=oe.strokeWidth,this.strokeDasharray=oe.strokeDasharray,this.opacity=oe.opacity,this.createVisual(),ae.prototype.restoreState.call(this,ee),this.setSize()},te.prototype.scale=function(ee,oe){ae.prototype.scale.call(this,ee,oe),this.setSize()},te.title="Rectangle marker",te}(mt),it=function(ae){function te(ee,oe,se,ne){var he=ae.call(this,ee,ne||'<svg viewBox="0 0 24 24"><path d="M3 17h18v-2H3v2m0 3h18v-1H3v1m0-7h18v-3H3v3m0-9v4h18V4H3z"/></svg>')||this;return he.widths=[],he.widthBoxes=[],he.widths=oe,he.currentWidth=se,he.setCurrentWidth=he.setCurrentWidth.bind(he),he}return Ke(te,ae),te.prototype.getUi=function(){var ee=this,oe=document.createElement("div");return oe.style.display="flex",oe.style.overflow="hidden",oe.style.flexGrow="2",this.widths.forEach(function(se){var ne=document.createElement("div");ne.style.display="flex",ne.style.flexGrow="2",ne.style.alignItems="center",ne.style.justifyContent="space-between",ne.style.padding="5px",ne.style.borderWidth="2px",ne.style.borderStyle="solid",ne.style.borderColor=se===ee.currentWidth?ee.uiStyleSettings.toolboxAccentColor:"transparent",ne.addEventListener("click",function(){ee.setCurrentWidth(se,ne)}),oe.appendChild(ne);var he=document.createElement("div");he.innerText=se.toString(),he.style.marginRight="5px",ne.appendChild(he);var xe=document.createElement("div");xe.style.minHeight="20px",xe.style.flexGrow="2",xe.style.display="flex",xe.style.alignItems="center";var ot=document.createElement("hr");ot.style.minWidth="20px",ot.style.border="0px",ot.style.borderTop=se+"px solid "+ee.uiStyleSettings.toolboxColor,ot.style.flexGrow="2",xe.appendChild(ot),ne.appendChild(xe),ee.widthBoxes.push(ne)}),oe},te.prototype.setCurrentWidth=function(ee,oe){var se=this;this.currentWidth=ee,this.widthBoxes.forEach(function(ne){ne.style.borderColor=ne===oe?se.uiStyleSettings.toolboxAccentColor:"transparent"}),this.onWidthChanged&&this.onWidthChanged(this.currentWidth)},te}(Le),je=function(ae){function te(ee,oe,se,ne){var he=ae.call(this,ee,ne||'<svg viewBox="0 0 24 24"><path d="M3 16h5v-2H3v2m6.5 0h5v-2h-5v2m6.5 0h5v-2h-5v2M3 20h2v-2H3v2m4 0h2v-2H7v2m4 0h2v-2h-2v2m4 0h2v-2h-2v2m4 0h2v-2h-2v2M3 12h8v-2H3v2m10 0h8v-2h-8v2M3 4v4h18V4H3z"/></svg>')||this;return he.styles=[],he.styleBoxes=[],he.styles=oe,he.currentStyle=se,he.setCurrentStyle=he.setCurrentStyle.bind(he),he}return Ke(te,ae),te.prototype.getUi=function(){var ee=this,oe=document.createElement("div");return oe.style.display="flex",oe.style.overflow="hidden",oe.style.flexGrow="2",this.styles.forEach(function(se){var ne=document.createElement("div");ne.style.display="flex",ne.style.alignItems="center",ne.style.justifyContent="space-between",ne.style.padding="5px",ne.style.borderWidth="2px",ne.style.borderStyle="solid",ne.style.overflow="hidden",ne.style.maxWidth=100/ee.styles.length-5+"%",ne.style.borderColor=se===ee.currentStyle?ee.uiStyleSettings.toolboxAccentColor:"transparent",ne.addEventListener("click",function(){ee.setCurrentStyle(se,ne)}),oe.appendChild(ne);var he=document.createElement("div");he.style.minHeight="20px",he.style.flexGrow="2",he.style.overflow="hidden";var xe=`<svg width="100" height="20">
|
|
|
<line x1="0" y1="10" x2="100" y2="10" stroke="`+ee.uiStyleSettings.toolboxColor+'" stroke-width="3" '+(se!==""?'stroke-dasharray="'+se+'"':"")+` />
|
|
|
</svg>`;he.innerHTML=xe,ne.appendChild(he),ee.styleBoxes.push(ne)}),oe},te.prototype.setCurrentStyle=function(ee,oe){var se=this;this.currentStyle=ee,this.styleBoxes.forEach(function(ne){ne.style.borderColor=ne===oe?se.uiStyleSettings.toolboxAccentColor:"transparent"}),this.onStyleChanged&&this.onStyleChanged(this.currentStyle)},te}(Le),Ot=function(ae){function te(ee,oe,se){var ne=ae.call(this,ee,oe,se)||this;return ne.strokeColor=se.defaultColor,ne.strokeWidth=se.defaultStrokeWidth,ne.strokeDasharray=se.defaultStrokeDasharray,ne.strokePanel=new Ge("Line color",se.defaultColorSet,se.defaultColor),ne.strokePanel.onColorChanged=ne.setStrokeColor,ne.strokeWidthPanel=new it("Line width",se.defaultStrokeWidths,se.defaultStrokeWidth),ne.strokeWidthPanel.onWidthChanged=ne.setStrokeWidth,ne.strokeStylePanel=new je("Line style",se.defaultStrokeDasharrays,se.defaultStrokeDasharray),ne.strokeStylePanel.onStyleChanged=ne.setStrokeDasharray,ne}return Ke(te,ae),Object.defineProperty(te.prototype,"toolboxPanels",{get:function(){return[this.strokePanel,this.strokeWidthPanel,this.strokeStylePanel]},enumerable:!1,configurable:!0}),te.prototype.getState=function(){var ee=ae.prototype.getState.call(this);return ee.typeName=te.typeName,ee},te.typeName="FrameMarker",te.title="Frame marker",te.icon='<svg viewBox="0 0 24 24"><path d="M4 6v13h16V6H4m14 11H6V8h12v9z"/></svg>',te}(st),nt=function(){this.defaultColorSet=["#EF4444","#10B981","#2563EB","#FFFF00","#7C3AED","#F472B6","#000000","#FFFFFF"],this.defaultColor=this.defaultColorSet[0],this.defaultFillColor=this.defaultColorSet[0],this.defaultStrokeColor=this.defaultColorSet[7],this.defaultHighlightColor=this.defaultColorSet[3],this.defaultStrokeWidth=3,this.defaultStrokeDasharray="",this.defaultHighlightOpacity=.5,this.defaultFontFamily="Helvetica, Arial, sans-serif",this.defaultStrokeWidths=[1,2,3,5,10],this.defaultStrokeDasharrays=["","3","12 3","9 6 3 6"],this.defaultOpacitySteps=[.1,.25,.5,.75,1],this.displayMode="inline",this.defaultFontFamilies=['Times, "Times New Roman", serif',"Helvetica, Arial, sans-serif",'Courier, "Courier New", monospace',"cursive","fantasy"],this.popupMargin=30,this.newFreehandMarkerOnPointerUp=!1,this.defaultColorsFollowCurrentColors=!1,this.freehandPixelRatio=1,this.disableRotation=!1,this.defaultCaptionFontSize="1rem",this.defaultCaptionText="Text"},tt=function(ae){function te(ee,oe,se){var ne=ae.call(this,ee,oe,se)||this;return ne.x1=0,ne.y1=0,ne.x2=0,ne.y2=0,ne.defaultLength=50,ne.manipulationStartX=0,ne.manipulationStartY=0,ne.manipulationStartX1=0,ne.manipulationStartY1=0,ne.manipulationStartX2=0,ne.manipulationStartY2=0,ne.setupControlBox(),ne}return Ke(te,ae),te.prototype.ownsTarget=function(ee){return!!ae.prototype.ownsTarget.call(this,ee)||!(!this.grip1.ownsTarget(ee)&&!this.grip2.ownsTarget(ee))},te.prototype.pointerDown=function(ee,oe){ae.prototype.pointerDown.call(this,ee,oe),this.manipulationStartX=ee.x,this.manipulationStartY=ee.y,this.state==="new"&&(this.x1=ee.x,this.y1=ee.y,this.x2=ee.x,this.y2=ee.y),this.manipulationStartX1=this.x1,this.manipulationStartY1=this.y1,this.manipulationStartX2=this.x2,this.manipulationStartY2=this.y2,this.state!=="new"&&(this.select(),this.grip1.ownsTarget(oe)?this.activeGrip=this.grip1:this.grip2.ownsTarget(oe)?this.activeGrip=this.grip2:this.activeGrip=void 0,this.activeGrip?this._state="resize":this._state="move")},te.prototype.pointerUp=function(ee){var oe=this.state;ae.prototype.pointerUp.call(this,ee),this.state==="creating"&&Math.abs(this.x1-this.x2)<10&&Math.abs(this.y1-this.y2)<10?(this.x2=this.x1+this.defaultLength,this.adjustVisual(),this.adjustControlBox()):this.manipulate(ee),this._state="select",oe==="creating"&&this.onMarkerCreated&&this.onMarkerCreated(this)},te.prototype.adjustVisual=function(){},te.prototype.manipulate=function(ee){this.state==="creating"?this.resize(ee):this.state==="move"?(this.x1=this.manipulationStartX1+ee.x-this.manipulationStartX,this.y1=this.manipulationStartY1+ee.y-this.manipulationStartY,this.x2=this.manipulationStartX2+ee.x-this.manipulationStartX,this.y2=this.manipulationStartY2+ee.y-this.manipulationStartY,this.adjustVisual(),this.adjustControlBox()):this.state==="resize"&&this.resize(ee)},te.prototype.resize=function(ee){switch(this.activeGrip){case this.grip1:this.x1=ee.x,this.y1=ee.y;break;case this.grip2:case void 0:this.x2=ee.x,this.y2=ee.y}this.adjustVisual(),this.adjustControlBox()},te.prototype.select=function(){ae.prototype.select.call(this),this.adjustControlBox(),this.controlBox.style.display=""},te.prototype.deselect=function(){ae.prototype.deselect.call(this),this.controlBox.style.display="none"},te.prototype.setupControlBox=function(){this.controlBox=be.createGroup(),this.container.appendChild(this.controlBox),this.addControlGrips(),this.controlBox.style.display="none"},te.prototype.adjustControlBox=function(){this.positionGrips()},te.prototype.addControlGrips=function(){this.grip1=this.createGrip(),this.grip2=this.createGrip(),this.positionGrips()},te.prototype.createGrip=function(){var ee=new It;return ee.visual.transform.baseVal.appendItem(be.createTransform()),this.controlBox.appendChild(ee.visual),ee},te.prototype.positionGrips=function(){var ee=this.grip1.GRIP_SIZE;this.positionGrip(this.grip1.visual,this.x1-ee/2,this.y1-ee/2),this.positionGrip(this.grip2.visual,this.x2-ee/2,this.y2-ee/2)},te.prototype.positionGrip=function(ee,oe,se){var ne=ee.transform.baseVal.getItem(0);ne.setTranslate(oe,se),ee.transform.baseVal.replaceItem(ne,0)},te.prototype.getState=function(){return Object.assign({x1:this.x1,y1:this.y1,x2:this.x2,y2:this.y2},ae.prototype.getState.call(this))},te.prototype.restoreState=function(ee){ae.prototype.restoreState.call(this,ee);var oe=ee;this.x1=oe.x1,this.y1=oe.y1,this.x2=oe.x2,this.y2=oe.y2},te.prototype.scale=function(ee,oe){ae.prototype.scale.call(this,ee,oe),this.x1=this.x1*ee,this.y1=this.y1*oe,this.x2=this.x2*ee,this.y2=this.y2*oe,this.adjustVisual(),this.adjustControlBox()},te}(Ne),ht=function(ae){function te(ee,oe,se){var ne=ae.call(this,ee,oe,se)||this;return ne.strokeColor="transparent",ne.strokeWidth=0,ne.strokeDasharray="",ne.setStrokeColor=ne.setStrokeColor.bind(ne),ne.setStrokeWidth=ne.setStrokeWidth.bind(ne),ne.setStrokeDasharray=ne.setStrokeDasharray.bind(ne),ne.strokeColor=se.defaultColor,ne.strokeWidth=se.defaultStrokeWidth,ne.strokeDasharray=se.defaultStrokeDasharray,ne.strokePanel=new Ge("Line color",se.defaultColorSet,se.defaultColor),ne.strokePanel.onColorChanged=ne.setStrokeColor,ne.strokeWidthPanel=new it("Line width",se.defaultStrokeWidths,se.defaultStrokeWidth),ne.strokeWidthPanel.onWidthChanged=ne.setStrokeWidth,ne.strokeStylePanel=new je("Line style",se.defaultStrokeDasharrays,se.defaultStrokeDasharray),ne.strokeStylePanel.onStyleChanged=ne.setStrokeDasharray,ne}return Ke(te,ae),te.prototype.ownsTarget=function(ee){return!(!ae.prototype.ownsTarget.call(this,ee)&&ee!==this.visual&&ee!==this.selectorLine&&ee!==this.visibleLine)},te.prototype.createVisual=function(){this.visual=be.createGroup(),this.selectorLine=be.createLine(this.x1,this.y1,this.x2,this.y2,[["stroke","transparent"],["stroke-width",(this.strokeWidth+10).toString()]]),this.visibleLine=be.createLine(this.x1,this.y1,this.x2,this.y2,[["stroke",this.strokeColor],["stroke-width",this.strokeWidth.toString()]]),this.visual.appendChild(this.selectorLine),this.visual.appendChild(this.visibleLine),this.addMarkerVisualToContainer(this.visual)},te.prototype.pointerDown=function(ee,oe){ae.prototype.pointerDown.call(this,ee,oe),this.state==="new"&&(this.createVisual(),this.adjustVisual(),this._state="creating")},te.prototype.adjustVisual=function(){this.selectorLine&&this.visibleLine&&(this.selectorLine.setAttribute("x1",this.x1.toString()),this.selectorLine.setAttribute("y1",this.y1.toString()),this.selectorLine.setAttribute("x2",this.x2.toString()),this.selectorLine.setAttribute("y2",this.y2.toString()),this.visibleLine.setAttribute("x1",this.x1.toString()),this.visibleLine.setAttribute("y1",this.y1.toString()),this.visibleLine.setAttribute("x2",this.x2.toString()),this.visibleLine.setAttribute("y2",this.y2.toString()),be.setAttributes(this.visibleLine,[["stroke",this.strokeColor]]),be.setAttributes(this.visibleLine,[["stroke-width",this.strokeWidth.toString()]]),be.setAttributes(this.visibleLine,[["stroke-dasharray",this.strokeDasharray.toString()]]))},te.prototype.setStrokeColor=function(ee){this.strokeColor=ee,this.adjustVisual(),this.colorChanged(ee)},te.prototype.setStrokeWidth=function(ee){this.strokeWidth=ee,this.adjustVisual()},te.prototype.setStrokeDasharray=function(ee){this.strokeDasharray=ee,this.adjustVisual(),this.stateChanged()},Object.defineProperty(te.prototype,"toolboxPanels",{get:function(){return[this.strokePanel,this.strokeWidthPanel,this.strokeStylePanel]},enumerable:!1,configurable:!0}),te.prototype.getState=function(){var ee=Object.assign({strokeColor:this.strokeColor,strokeWidth:this.strokeWidth,strokeDasharray:this.strokeDasharray},ae.prototype.getState.call(this));return ee.typeName=te.typeName,ee},te.prototype.restoreState=function(ee){ae.prototype.restoreState.call(this,ee);var oe=ee;this.strokeColor=oe.strokeColor,this.strokeWidth=oe.strokeWidth,this.strokeDasharray=oe.strokeDasharray,this.createVisual(),this.adjustVisual()},te.typeName="LineMarker",te.title="Line marker",te.icon='<svg viewBox="0 0 24 24"><path d="M19 13H5v-2h14v2z"/></svg>',te}(tt),$e=function(ae){function te(ee,oe,se,ne){var he=ae.call(this,ee,ne||'<svg viewBox="0 0 24 24"><path d="M17 8h3v12h1v1h-4v-1h1v-3h-4l-1.5 3H14v1h-4v-1h1l6-12m1 1l-3.5 7H18V9M5 3h5c1.11 0 2 .89 2 2v11H9v-5H6v5H3V5c0-1.11.89-2 2-2m1 2v4h3V5H6z"/></svg>')||this;return he.fonts=[],he.fontBoxes=[],he.fonts=oe,he.currentFont=se,he.setCurrentFont=he.setCurrentFont.bind(he),he}return Ke(te,ae),te.prototype.getUi=function(){var ee=this,oe=document.createElement("div");return oe.style.overflow="hidden",oe.style.flexGrow="2",this.fonts.forEach(function(se){var ne=document.createElement("div");ne.style.display="inline-block",ne.style.alignItems="center",ne.style.justifyContent="space-between",ne.style.padding="5px",ne.style.borderWidth="2px",ne.style.borderStyle="solid",ne.style.overflow="hidden",ne.style.maxWidth=100/ee.fonts.length-5+"%",ne.style.borderColor=se===ee.currentFont?ee.uiStyleSettings.toolboxAccentColor:"transparent",ne.addEventListener("click",function(){ee.setCurrentFont(se,ne)}),oe.appendChild(ne);var he=document.createElement("div");he.style.display="flex",he.style.minHeight="20px",he.style.flexGrow="2",he.style.fontFamily=se,he.style.overflow="hidden";var xe=document.createElement("div");xe.style.whiteSpace="nowrap",xe.style.overflow="hidden",xe.style.textOverflow="ellipsis",xe.innerHTML="The quick brown fox jumps over the lazy dog",he.appendChild(xe),ne.appendChild(he),ee.fontBoxes.push(ne)}),oe},te.prototype.setCurrentFont=function(ee,oe){var se=this;this.currentFont=ee,this.fontBoxes.forEach(function(ne){ne.style.borderColor=ne===oe?se.uiStyleSettings.toolboxAccentColor:"transparent"}),this.onFontChanged&&this.onFontChanged(this.currentFont)},te}(Le),at=function(ae){function te(ee,oe,se){var ne=ae.call(this,ee,oe,se)||this;return ne.color="transparent",ne.padding=5,ne.DEFAULT_TEXT="\u8BF7\u8F93\u5165\u6587\u672C",ne.text=ne.DEFAULT_TEXT,ne.isMoved=!1,ne.color=se.defaultColor,ne.fontFamily=se.defaultFontFamily,ne.defaultSize={x:100,y:30},ne.setColor=ne.setColor.bind(ne),ne.setFont=ne.setFont.bind(ne),ne.renderText=ne.renderText.bind(ne),ne.sizeText=ne.sizeText.bind(ne),ne.textEditDivClicked=ne.textEditDivClicked.bind(ne),ne.showTextEditor=ne.showTextEditor.bind(ne),ne.setSize=ne.setSize.bind(ne),ne.positionTextEditor=ne.positionTextEditor.bind(ne),ne.colorPanel=new Ge("Color",se.defaultColorSet,se.defaultColor),ne.colorPanel.onColorChanged=ne.setColor,ne.fontFamilyPanel=new $e("Font",se.defaultFontFamilies,se.defaultFontFamily),ne.fontFamilyPanel.onFontChanged=ne.setFont,ne}return Ke(te,ae),te.prototype.ownsTarget=function(ee){if(ae.prototype.ownsTarget.call(this,ee)||ee===this.visual||ee===this.textElement||ee===this.bgRectangle)return!0;var oe=!1;return this.textElement.childNodes.forEach(function(se){se===ee&&(oe=!0)}),oe},te.prototype.createVisual=function(){this.visual=be.createGroup(),this.bgRectangle=be.createRect(1,1,[["fill","transparent"]]),this.visual.appendChild(this.bgRectangle),this.textElement=be.createText([["fill",this.color],["font-family",this.fontFamily],["font-size","16px"],["x","0"],["y","0"]]),this.textElement.transform.baseVal.appendItem(be.createTransform()),this.textElement.transform.baseVal.appendItem(be.createTransform()),this.visual.appendChild(this.textElement),this.addMarkerVisualToContainer(this.visual),this.renderText()},te.prototype.pointerDown=function(ee,oe){ae.prototype.pointerDown.call(this,ee,oe),this.isMoved=!1,this.pointerDownPoint=ee,this.pointerDownTimestamp=Date.now(),this.state==="new"&&(this.createVisual(),this.moveVisual(ee),this._state="creating")},te.prototype.renderText=function(){var ee=this;if(this.textElement){for(;this.textElement.lastChild;)this.textElement.removeChild(this.textElement.lastChild);this.text.split(/\r\n|[\n\v\f\r\x85\u2028\u2029]/).forEach(function(oe){ee.textElement.appendChild(be.createTSpan(oe.trim()===""?" ":oe.trim(),[["x","0"],["dy","1.2em"]]))}),setTimeout(this.sizeText,10)}},te.prototype.getTextScale=function(){var ee=this.textElement.getBBox(),oe=1;if(ee.width>0&&ee.height>0){var se=(1*this.width-this.width*this.padding*2/100)/ee.width,ne=(1*this.height-this.height*this.padding*2/100)/ee.height;oe=Math.min(se,ne)}return oe},te.prototype.getTextPosition=function(ee){var oe=this.textElement.getBBox(),se=0,ne=0;return oe.width>0&&oe.height>0&&(se=(this.width-oe.width*ee)/2,ne=this.height/2-oe.height*ee/2),{x:se,y:ne}},te.prototype.sizeText=function(){var ee=this.textElement.getBBox(),oe=this.getTextScale(),se=this.getTextPosition(oe);se.y-=ee.y*oe,navigator.userAgent.indexOf("Edge/")>-1?this.textElement.style.transform="translate("+se.x+"px, "+se.y+"px) scale("+oe+", "+oe+")":(this.textElement.transform.baseVal.getItem(0).setTranslate(se.x,se.y),this.textElement.transform.baseVal.getItem(1).setScale(oe,oe))},te.prototype.manipulate=function(ee){ae.prototype.manipulate.call(this,ee),this.pointerDownPoint!==void 0&&(this.isMoved=Math.abs(ee.x-this.pointerDownPoint.x)>5||Math.abs(ee.y-this.pointerDownPoint.y)>5)},te.prototype.resize=function(ee){ae.prototype.resize.call(this,ee),this.isMoved=!0,this.setSize(),this.sizeText()},te.prototype.setSize=function(){ae.prototype.setSize.call(this),this.visual&&this.bgRectangle&&(be.setAttributes(this.visual,[["width",this.width.toString()],["height",this.height.toString()]]),be.setAttributes(this.bgRectangle,[["width",this.width.toString()],["height",this.height.toString()]]))},te.prototype.pointerUp=function(ee){var oe=this.state;oe==="creating"&&(this._suppressMarkerCreateEvent=!0),ae.prototype.pointerUp.call(this,ee),this.setSize(),(oe==="creating"||!this.isMoved&&Date.now()-this.pointerDownTimestamp>500)&&this.showTextEditor(),this.pointerDownPoint=void 0},te.prototype.showTextEditor=function(){var ee=this;this._state="edit",this.overlayContainer.innerHTML="",this.textEditDiv=document.createElement("div"),this.textEditDiv.style.flexGrow="2",this.textEditDiv.style.alignItems="center",this.textEditDiv.style.justifyContent="center",this.textEditDiv.style.pointerEvents="auto",this.textEditDiv.style.overflow="hidden",this.textEditor=document.createElement("div"),this.textEditor.style.position="absolute",this.textEditor.style.fontFamily=this.fontFamily,this.textEditor.style.lineHeight="1em",this.textEditor.innerText=this.text,this.textEditor.contentEditable="true",this.textEditor.style.color=this.color,this.textEditor.style.whiteSpace="pre",this.positionTextEditor(),this.textEditor.addEventListener("pointerup",function(oe){oe.stopPropagation()}),this.textEditor.addEventListener("input",function(){for(var oe=Number.parseFloat(ee.textEditor.style.fontSize);ee.textEditor.clientWidth>=Number.parseInt(ee.textEditor.style.maxWidth)&&oe>.9;)oe-=.1,ee.textEditor.style.fontSize=Math.max(oe,.9)+"em"}),this.textEditor.addEventListener("keyup",function(oe){oe.cancelBubble=!0}),this.textEditor.addEventListener("paste",function(oe){if(oe.clipboardData){var se=oe.clipboardData.getData("text"),ne=window.getSelection();if(!ne.rangeCount)return!1;ne.deleteFromDocument(),ne.getRangeAt(0).insertNode(document.createTextNode(se)),oe.preventDefault()}}),this.textEditDiv.addEventListener("pointerup",function(){ee.textEditDivClicked(ee.textEditor.innerText)}),this.textEditDiv.appendChild(this.textEditor),this.overlayContainer.appendChild(this.textEditDiv),this.hideVisual(),this.textEditor.focus(),document.execCommand("selectAll")},te.prototype.positionTextEditor=function(){if(this.state==="edit")if(this.textEditor===void 0)this.showTextEditor();else{this.textElement.style.display="";var ee=this.getTextScale(),oe=this.rotatePoint({x:this.left+this.width/2,y:this.top+this.height/2}),se=this.textElement.getBBox(),ne={x:se.width*ee,y:se.height*ee};oe.x-=ne.x/2,oe.y-=ne.y/2,this.textEditor.style.top=oe.y+"px",this.textEditor.style.left=oe.x+"px",this.textEditor.style.maxWidth=this.overlayContainer.offsetWidth-oe.x+"px",this.textEditor.style.fontSize=Math.max(16*ee,12)+"px",this.textElement.style.display="none"}},te.prototype.textEditDivClicked=function(ee){this.text=ee.trim(),this.overlayContainer.innerHTML="",this.renderText(),this.showVisual(),this._suppressMarkerCreateEvent&&(this._suppressMarkerCreateEvent=!1,this.onMarkerCreated&&this.onMarkerCreated(this)),this.stateChanged()},te.prototype.select=function(){ae.prototype.select.call(this),this.state==="edit"&&this.textEditDivClicked(this.textEditor.innerText)},te.prototype.deselect=function(){this.state==="edit"&&this.textEditDivClicked(this.textEditor.innerText),ae.prototype.deselect.call(this)},te.prototype.dblClick=function(ee,oe){ae.prototype.dblClick.call(this,ee,oe),this.showTextEditor()},te.prototype.setColor=function(ee){this.textElement&&be.setAttributes(this.textElement,[["fill",ee]]),this.color=ee,this.textEditor&&(this.textEditor.style.color=this.color),this.colorChanged(ee)},te.prototype.setFont=function(ee){this.textElement&&be.setAttributes(this.textElement,[["font-family",ee]]),this.fontFamily=ee,this.textEditor&&(this.textEditor.style.fontFamily=this.fontFamily),this.renderText(),this.stateChanged()},te.prototype.hideVisual=function(){this.textElement.style.display="none",this.hideControlBox()},te.prototype.showVisual=function(){this.state==="edit"&&(this._state="select"),this.textElement.style.display="",this.showControlBox()},Object.defineProperty(te.prototype,"toolboxPanels",{get:function(){return[this.colorPanel,this.fontFamilyPanel]},enumerable:!1,configurable:!0}),te.prototype.getState=function(){var ee=Object.assign({color:this.color,fontFamily:this.fontFamily,padding:this.padding,text:this.text},ae.prototype.getState.call(this));return ee.typeName=te.typeName,ee},te.prototype.restoreState=function(ee){var oe=ee;this.color=oe.color,this.fontFamily=oe.fontFamily,this.padding=oe.padding,this.text=oe.text,this.createVisual(),ae.prototype.restoreState.call(this,ee),this.setSize()},te.prototype.scale=function(ee,oe){ae.prototype.scale.call(this,ee,oe),this.setSize(),this.sizeText(),this.positionTextEditor()},te.typeName="TextMarker",te.title="Text marker",te.icon='<svg viewBox="0 0 24 24"><path d="M9.6 14L12 7.7l2.4 6.3M11 5L5.5 19h2.2l1.1-3H15l1.1 3h2.2L13 5h-2z"/></svg>',te}(mt),lt=function(ae){function te(ee,oe,se){var ne=ae.call(this,ee,oe,se)||this;return ne.color="transparent",ne.lineWidth=3,ne.drawing=!1,ne.pixelRatio=1,ne.color=se.defaultColor,ne.lineWidth=se.defaultStrokeWidth,ne.pixelRatio=se.freehandPixelRatio,ne.setColor=ne.setColor.bind(ne),ne.addCanvas=ne.addCanvas.bind(ne),ne.finishCreation=ne.finishCreation.bind(ne),ne.setLineWidth=ne.setLineWidth.bind(ne),ne.colorPanel=new Ge("Color",se.defaultColorSet,se.defaultColor),ne.colorPanel.onColorChanged=ne.setColor,ne.lineWidthPanel=new it("Line width",se.defaultStrokeWidths,se.defaultStrokeWidth),ne.lineWidthPanel.onWidthChanged=ne.setLineWidth,ne}return Ke(te,ae),te.prototype.ownsTarget=function(ee){return!(!ae.prototype.ownsTarget.call(this,ee)&&ee!==this.visual&&ee!==this.drawingImage)},te.prototype.createVisual=function(){this.visual=be.createGroup(),this.drawingImage=be.createImage(),this.visual.appendChild(this.drawingImage);var ee=be.createTransform();this.visual.transform.baseVal.appendItem(ee),this.addMarkerVisualToContainer(this.visual)},te.prototype.pointerDown=function(ee,oe){this.state==="new"&&(this.addCanvas(),this.createVisual(),this._state="creating"),this.state==="creating"?(this.canvasContext.strokeStyle=this.color,this.canvasContext.lineWidth=this.lineWidth,this.canvasContext.beginPath(),this.canvasContext.moveTo(ee.x,ee.y),this.drawing=!0):ae.prototype.pointerDown.call(this,ee,oe)},te.prototype.manipulate=function(ee){this.state==="creating"?this.drawing&&(this.canvasContext.lineTo(ee.x,ee.y),this.canvasContext.stroke()):ae.prototype.manipulate.call(this,ee)},te.prototype.resize=function(ee){ae.prototype.resize.call(this,ee),be.setAttributes(this.visual,[["width",this.width.toString()],["height",this.height.toString()]]),be.setAttributes(this.drawingImage,[["width",this.width.toString()],["height",this.height.toString()]])},te.prototype.pointerUp=function(ee){this._state==="creating"?this.drawing&&(this.canvasContext.closePath(),this.drawing=!1,this.globalSettings.newFreehandMarkerOnPointerUp&&this.finishCreation()):ae.prototype.pointerUp.call(this,ee)},te.prototype.addCanvas=function(){this.overlayContainer.innerHTML="",this.canvasElement=document.createElement("canvas"),this.canvasElement.width=this.overlayContainer.clientWidth*this.pixelRatio,this.canvasElement.height=this.overlayContainer.clientHeight*this.pixelRatio,this.canvasContext=this.canvasElement.getContext("2d"),this.canvasContext.scale(this.pixelRatio,this.pixelRatio),this.overlayContainer.appendChild(this.canvasElement)},te.prototype.select=function(){this.state==="creating"&&this.finishCreation(),ae.prototype.select.call(this)},te.prototype.deselect=function(){this.state==="creating"&&this.finishCreation(),ae.prototype.deselect.call(this)},te.prototype.finishCreation=function(){for(var ee=this.canvasContext.getImageData(0,0,this.canvasElement.width,this.canvasElement.height),oe=[this.canvasElement.width+1,this.canvasElement.height+1,-1,-1],se=oe[0],ne=oe[1],he=oe[2],xe=oe[3],ot=!1,Ee=0;Ee<this.canvasElement.height;Ee++)for(var Fe=0;Fe<this.canvasElement.width;Fe++)ee.data[Ee*this.canvasElement.width*4+4*Fe+3]>0&&(ot=!0,Ee<ne&&(ne=Ee),Fe<se&&(se=Fe),Ee>xe&&(xe=Ee),Fe>he&&(he=Fe));if(ot){this.left=se/this.pixelRatio,this.top=ne/this.pixelRatio,this.width=(he-se)/this.pixelRatio,this.height=(xe-ne)/this.pixelRatio;var qe=document.createElement("canvas");qe.width=he-se,qe.height=xe-ne,qe.getContext("2d").putImageData(this.canvasContext.getImageData(se,ne,he-se,xe-ne),0,0),this.drawingImgUrl=qe.toDataURL("image/png"),this.setDrawingImage(),this._state="select",this.onMarkerCreated&&this.onMarkerCreated(this)}this.overlayContainer.innerHTML=""},te.prototype.setDrawingImage=function(){be.setAttributes(this.drawingImage,[["width",this.width.toString()],["height",this.height.toString()]]),be.setAttributes(this.drawingImage,[["href",this.drawingImgUrl]]),this.moveVisual({x:this.left,y:this.top})},te.prototype.setColor=function(ee){this.color=ee,this.colorChanged(ee)},te.prototype.setLineWidth=function(ee){this.lineWidth=ee},Object.defineProperty(te.prototype,"toolboxPanels",{get:function(){return this.state==="new"||this.state==="creating"?[this.colorPanel,this.lineWidthPanel]:[]},enumerable:!1,configurable:!0}),te.prototype.getState=function(){var ee=Object.assign({drawingImgUrl:this.drawingImgUrl},ae.prototype.getState.call(this));return ee.typeName=te.typeName,ee},te.prototype.restoreState=function(ee){this.createVisual(),ae.prototype.restoreState.call(this,ee),this.drawingImgUrl=ee.drawingImgUrl,this.setDrawingImage()},te.prototype.scale=function(ee,oe){ae.prototype.scale.call(this,ee,oe),this.setDrawingImage()},te.typeName="FreehandMarker",te.title="Freehand marker",te.icon='<svg viewBox="0 0 24 24"><path d="M9.75 20.85c1.78-.7 1.39-2.63.49-3.85-.89-1.25-2.12-2.11-3.36-2.94A9.817 9.817 0 014.54 12c-.28-.33-.85-.94-.27-1.06.59-.12 1.61.46 2.13.68.91.38 1.81.82 2.65 1.34l1.01-1.7C8.5 10.23 6.5 9.32 4.64 9.05c-1.06-.16-2.18.06-2.54 1.21-.32.99.19 1.99.77 2.77 1.37 1.83 3.5 2.71 5.09 4.29.34.33.75.72.95 1.18.21.44.16.47-.31.47-1.24 0-2.79-.97-3.8-1.61l-1.01 1.7c1.53.94 4.09 2.41 5.96 1.79m11.09-15.6c.22-.22.22-.58 0-.79l-1.3-1.3a.562.562 0 00-.78 0l-1.02 1.02 2.08 2.08M11 10.92V13h2.08l6.15-6.15-2.08-2.08L11 10.92z"/></svg>',te}(mt),me=function(ae){function te(ee,oe,se){var ne=ae.call(this,ee,se||'<svg viewBox="0 0 24 24"><path d="M8 14v4l-6-6 6-6v4h8V6l6 6-6 6v-4H8z"/></svg>')||this;return ne.typeBoxes=[],ne.currentType=oe,ne.setCurrentType=ne.setCurrentType.bind(ne),ne}return Ke(te,ae),te.prototype.getUi=function(){var ee=this,oe=document.createElement("div");oe.style.display="flex",oe.style.overflow="hidden",oe.style.flexGrow="2";for(var se=function(xe){var ot="both";switch(xe){case 0:ot="both";break;case 1:ot="start";break;case 2:ot="end";break;case 3:ot="none"}var Ee=document.createElement("div");if(Ee.style.display="flex",Ee.style.flexGrow="2",Ee.style.alignItems="center",Ee.style.justifyContent="space-between",Ee.style.padding="5px",Ee.style.borderWidth="2px",Ee.style.borderStyle="solid",Ee.style.borderColor=ot===ne.currentType?ne.uiStyleSettings.toolboxAccentColor:"transparent",Ee.addEventListener("click",function(){ee.setCurrentType(ot,Ee)}),oe.appendChild(Ee),ot==="both"||ot==="start"){var Fe=document.createElement("div");Fe.style.display="flex",Fe.style.alignItems="center",Fe.style.minHeight="20px",Fe.innerHTML=`<svg viewBox="0 0 10 10" width="10" height="10" xmlns="http://www.w3.org/2000/svg">
|
|
|
<polygon points="0,5 10,0 10,10" fill="`+(ne.uiStyleSettings!==void 0?ne.uiStyleSettings.toolboxColor:"#eeeeee")+`" />
|
|
|
</svg>`,Fe.style.marginLeft="5px",Ee.appendChild(Fe)}var qe=document.createElement("div");qe.style.display="flex",qe.style.alignItems="center",qe.style.minHeight="20px",qe.style.flexGrow="2";var bt=document.createElement("hr");if(bt.style.minWidth="20px",bt.style.border="0px",bt.style.borderTop="3px solid "+(ne.uiStyleSettings!==void 0?ne.uiStyleSettings.toolboxColor:"#eeeeee"),bt.style.flexGrow="2",qe.appendChild(bt),Ee.appendChild(qe),ot==="both"||ot==="end"){var ct=document.createElement("div");ct.style.display="flex",ct.style.alignItems="center",ct.style.minHeight="20px",ct.innerHTML=`<svg viewBox="0 0 10 10" width="10" height="10" xmlns="http://www.w3.org/2000/svg">
|
|
|
<polygon points="0,0 10,5 0,10" fill="`+(ne.uiStyleSettings!==void 0?ne.uiStyleSettings.toolboxColor:"#eeeeee")+`" />
|
|
|
</svg>`,ct.style.marginRight="5px",Ee.appendChild(ct)}ne.typeBoxes.push(Ee)},ne=this,he=0;he<4;he++)se(he);return oe},te.prototype.setCurrentType=function(ee,oe){var se=this;this.currentType=ee,this.typeBoxes.forEach(function(ne){ne.style.borderColor=ne===oe?se.uiStyleSettings!==void 0?se.uiStyleSettings.toolboxAccentColor:"#3080c3":"transparent"}),this.onArrowTypeChanged&&this.onArrowTypeChanged(this.currentType)},te}(Le),At=function(ae){function te(ee,oe,se){var ne=ae.call(this,ee,oe,se)||this;return ne.arrowType="end",ne.arrowBaseHeight=10,ne.arrowBaseWidth=10,ne.getArrowPoints=ne.getArrowPoints.bind(ne),ne.setArrowType=ne.setArrowType.bind(ne),ne.arrowTypePanel=new me("Arrow type","end"),ne.arrowTypePanel.onArrowTypeChanged=ne.setArrowType,ne}return Ke(te,ae),te.prototype.ownsTarget=function(ee){return!(!ae.prototype.ownsTarget.call(this,ee)&&ee!==this.arrow1&&ee!==this.arrow2)},te.prototype.getArrowPoints=function(ee,oe){var se=this.arrowBaseWidth+2*this.strokeWidth,ne=this.arrowBaseHeight+2*this.strokeWidth;return ee-se/2+","+(oe+ne/2)+" "+ee+","+(oe-ne/2)+" "+(ee+se/2)+","+(oe+ne/2)},te.prototype.createTips=function(){this.arrow1=be.createPolygon(this.getArrowPoints(this.x1,this.y1),[["fill",this.strokeColor]]),this.arrow1.transform.baseVal.appendItem(be.createTransform()),this.visual.appendChild(this.arrow1),this.arrow2=be.createPolygon(this.getArrowPoints(this.x2,this.y2),[["fill",this.strokeColor]]),this.arrow2.transform.baseVal.appendItem(be.createTransform()),this.visual.appendChild(this.arrow2)},te.prototype.pointerDown=function(ee,oe){ae.prototype.pointerDown.call(this,ee,oe),this.state==="creating"&&this.createTips()},te.prototype.adjustVisual=function(){if(ae.prototype.adjustVisual.call(this),this.arrow1&&this.arrow2){this.arrow1.style.display=this.arrowType==="both"||this.arrowType==="start"?"":"none",this.arrow2.style.display=this.arrowType==="both"||this.arrowType==="end"?"":"none",be.setAttributes(this.arrow1,[["points",this.getArrowPoints(this.x1,this.y1)],["fill",this.strokeColor]]),be.setAttributes(this.arrow2,[["points",this.getArrowPoints(this.x2,this.y2)],["fill",this.strokeColor]]);var ee=0;Math.abs(this.x1-this.x2)>.1&&(ee=180*Math.atan((this.y2-this.y1)/(this.x2-this.x1))/Math.PI+90*Math.sign(this.x1-this.x2));var oe=this.arrow1.transform.baseVal.getItem(0);oe.setRotate(ee,this.x1,this.y1),this.arrow1.transform.baseVal.replaceItem(oe,0);var se=this.arrow2.transform.baseVal.getItem(0);se.setRotate(ee+180,this.x2,this.y2),this.arrow2.transform.baseVal.replaceItem(se,0)}},te.prototype.setArrowType=function(ee){this.arrowType=ee,this.adjustVisual(),this.stateChanged()},Object.defineProperty(te.prototype,"toolboxPanels",{get:function(){return[this.strokePanel,this.strokeWidthPanel,this.strokeStylePanel,this.arrowTypePanel]},enumerable:!1,configurable:!0}),te.prototype.getState=function(){var ee=Object.assign({arrowType:this.arrowType},ae.prototype.getState.call(this));return ee.typeName=te.typeName,ee},te.prototype.restoreState=function(ee){ae.prototype.restoreState.call(this,ee);var oe=ee;this.arrowType=oe.arrowType,this.createTips(),this.adjustVisual()},te.typeName="ArrowMarker",te.title="Arrow marker",te.icon='<svg viewBox="0 0 24 24"><path d="M19 6.41L17.59 5 7 15.59V9H5v10h10v-2H8.41L19 6.41z"/></svg>',te}(ht),De=function(ae){function te(ee,oe,se){var ne=ae.call(this,ee,oe,se)||this;return ne.fillColor=se.defaultFillColor,ne.strokeWidth=0,ne.fillPanel=new Ge("Color",se.defaultColorSet,se.defaultFillColor),ne.fillPanel.onColorChanged=ne.setFillColor,ne}return Ke(te,ae),Object.defineProperty(te.prototype,"toolboxPanels",{get:function(){return[this.fillPanel]},enumerable:!1,configurable:!0}),te.prototype.getState=function(){var ee=ae.prototype.getState.call(this);return ee.typeName=te.typeName,ee},te.typeName="CoverMarker",te.title="Cover marker",te.icon='<svg viewBox="0 0 24 24"><path d="M4 6v13h16V6H4z"/></svg>',te}(st),He=function(ae){function te(ee,oe,se,ne){var he=ae.call(this,ee,ne||'<svg viewBox="0 0 24 24"><path d="M17.66 8L12 2.35 6.34 8A8.02 8.02 0 004 13.64c0 2 .78 4.11 2.34 5.67a7.99 7.99 0 0011.32 0c1.56-1.56 2.34-3.67 2.34-5.67S19.22 9.56 17.66 8M6 14c0-2 .62-3.27 1.76-4.4L12 5.27l4.24 4.38C17.38 10.77 18 12 18 14H6z"/></svg>')||this;return he.opacities=[],he.opacityBoxes=[],he.opacities=oe,he.currentOpacity=se,he.setCurrentOpacity=he.setCurrentOpacity.bind(he),he}return Ke(te,ae),te.prototype.getUi=function(){var ee=this,oe=document.createElement("div");return oe.style.display="flex",oe.style.overflow="hidden",oe.style.flexGrow="2",oe.style.justifyContent="space-between",this.opacities.forEach(function(se){var ne=document.createElement("div");ne.style.display="flex",ne.style.alignItems="center",ne.style.justifyContent="center",ne.style.padding="5px",ne.style.borderWidth="2px",ne.style.borderStyle="solid",ne.style.borderColor=se===ee.currentOpacity?ee.uiStyleSettings.toolboxAccentColor:"transparent",ne.addEventListener("click",function(){ee.setCurrentOpacity(se,ne)}),oe.appendChild(ne);var he=document.createElement("div");he.innerText=100*se+"%",ne.appendChild(he),ee.opacityBoxes.push(ne)}),oe},te.prototype.setCurrentOpacity=function(ee,oe){var se=this;this.currentOpacity=ee,this.opacityBoxes.forEach(function(ne){ne.style.borderColor=ne===oe?se.uiStyleSettings.toolboxAccentColor:"transparent"}),this.onOpacityChanged&&this.onOpacityChanged(this.currentOpacity)},te}(Le),Pt=function(ae){function te(ee,oe,se){var ne=ae.call(this,ee,oe,se)||this;return ne.setOpacity=ne.setOpacity.bind(ne),ne.fillColor=se.defaultHighlightColor,ne.strokeWidth=0,ne.opacity=se.defaultHighlightOpacity,ne.fillPanel=new Ge("Color",se.defaultColorSet,ne.fillColor),ne.fillPanel.onColorChanged=ne.setFillColor,ne.opacityPanel=new He("Opacity",se.defaultOpacitySteps,ne.opacity),ne.opacityPanel.onOpacityChanged=ne.setOpacity,ne}return Ke(te,ae),te.prototype.setOpacity=function(ee){this.opacity=ee,this.visual&&be.setAttributes(this.visual,[["opacity",this.opacity.toString()]]),this.stateChanged()},Object.defineProperty(te.prototype,"toolboxPanels",{get:function(){return[this.fillPanel,this.opacityPanel]},enumerable:!1,configurable:!0}),te.prototype.getState=function(){var ee=ae.prototype.getState.call(this);return ee.typeName=te.typeName,ee},te.typeName="HighlightMarker",te.title="Highlight marker",te.icon='<svg viewBox="0 0 24 24"><path d="M18.5 1.15c-.53 0-1.04.19-1.43.58l-5.81 5.82 5.65 5.65 5.82-5.81c.77-.78.77-2.04 0-2.83l-2.84-2.83c-.39-.39-.89-.58-1.39-.58M10.3 8.5l-5.96 5.96c-.78.78-.78 2.04.02 2.85C3.14 18.54 1.9 19.77.67 21h5.66l.86-.86c.78.76 2.03.75 2.81-.02l5.95-5.96"/></svg>',te}(De),ge='<svg viewBox="0 0 24 24"><path d="M9.62 12L12 5.67 14.37 12M11 3L5.5 17h2.25l1.12-3h6.25l1.13 3h2.25L13 3h-2z"/></svg>',ce='<svg viewBox="0 0 24 24"><path d="M19 11.5s-2 2.17-2 3.5a2 2 0 002 2 2 2 0 002-2c0-1.33-2-3.5-2-3.5M5.21 10L10 5.21 14.79 10m1.77-1.06L7.62 0 6.21 1.41l2.38 2.38-5.15 5.15c-.59.56-.59 1.53 0 2.12l5.5 5.5c.29.29.68.44 1.06.44s.77-.15 1.06-.44l5.5-5.5c.59-.59.59-1.56 0-2.12z"/></svg>',Je=function(ae){function te(ee,oe,se){var ne=ae.call(this,ee,oe,se)||this;return ne.bgColor="transparent",ne.tipPosition={x:0,y:0},ne.tipBase1Position={x:0,y:0},ne.tipBase2Position={x:0,y:0},ne.tipMoving=!1,ne.color=se.defaultStrokeColor,ne.bgColor=se.defaultFillColor,ne.fontFamily=se.defaultFontFamily,ne.defaultSize={x:100,y:30},ne.setBgColor=ne.setBgColor.bind(ne),ne.getTipPoints=ne.getTipPoints.bind(ne),ne.positionTip=ne.positionTip.bind(ne),ne.setTipPoints=ne.setTipPoints.bind(ne),ne.colorPanel=new Ge("Text color",se.defaultColorSet,ne.color,ge),ne.colorPanel.onColorChanged=ne.setColor,ne.bgColorPanel=new Ge("Fill color",se.defaultColorSet,ne.bgColor,ce),ne.bgColorPanel.onColorChanged=ne.setBgColor,ne.fontFamilyPanel=new $e("Font",se.defaultFontFamilies,se.defaultFontFamily),ne.fontFamilyPanel.onFontChanged=ne.setFont,ne.tipGrip=new It,ne.tipGrip.visual.transform.baseVal.appendItem(be.createTransform()),ne.controlBox.appendChild(ne.tipGrip.visual),ne}return Ke(te,ae),te.prototype.ownsTarget=function(ee){return ae.prototype.ownsTarget.call(this,ee)||this.tipGrip.ownsTarget(ee)||this.tip===ee},te.prototype.createTip=function(){be.setAttributes(this.bgRectangle,[["fill",this.bgColor],["rx","10px"]]),this.tip=be.createPolygon(this.getTipPoints(),[["fill",this.bgColor]]),this.visual.appendChild(this.tip)},te.prototype.pointerDown=function(ee,oe){this.state==="new"&&ae.prototype.pointerDown.call(this,ee,oe),this.state==="creating"?this.createTip():this.tipGrip.ownsTarget(oe)?(this.manipulationStartLeft=this.left,this.manipulationStartTop=this.top,this.tipMoving=!0):ae.prototype.pointerDown.call(this,ee,oe)},te.prototype.pointerUp=function(ee){if(this.tipMoving)this.tipMoving=!1,this.isMoved=!0,ae.prototype.pointerUp.call(this,ee);else{var oe=this.state==="creating";ae.prototype.pointerUp.call(this,ee),this.setTipPoints(oe),this.positionTip()}},te.prototype.manipulate=function(ee){if(this.tipMoving){var oe=this.unrotatePoint(ee);this.tipPosition={x:oe.x-this.manipulationStartLeft,y:oe.y-this.manipulationStartTop},this.positionTip()}else ae.prototype.manipulate.call(this,ee)},te.prototype.setBgColor=function(ee){this.bgRectangle&&this.tip&&(be.setAttributes(this.bgRectangle,[["fill",ee]]),be.setAttributes(this.tip,[["fill",ee]])),this.bgColor=ee,this.fillColorChanged(ee)},te.prototype.getTipPoints=function(){return this.setTipPoints(this.state==="creating"),this.tipBase1Position.x+","+this.tipBase1Position.y+" "+this.tipBase2Position.x+","+this.tipBase2Position.y+" "+this.tipPosition.x+","+this.tipPosition.y},te.prototype.setTipPoints=function(ee){ee===void 0&&(ee=!1);var oe=Math.min(this.height/2,15),se=this.height/5;ee&&(this.tipPosition={x:oe+se/2,y:this.height+20});var ne=Math.atan(this.height/2/(this.width/2));this.tipPosition.x<this.width/2&&this.tipPosition.y<this.height/2?ne<Math.atan((this.height/2-this.tipPosition.y)/(this.width/2-this.tipPosition.x))?(se=this.width/5,oe=Math.min(this.width/2,15),this.tipBase1Position={x:oe,y:0},this.tipBase2Position={x:oe+se,y:0}):(this.tipBase1Position={x:0,y:oe},this.tipBase2Position={x:0,y:oe+se}):this.tipPosition.x>=this.width/2&&this.tipPosition.y<this.height/2?ne<Math.atan((this.height/2-this.tipPosition.y)/(this.tipPosition.x-this.width/2))?(se=this.width/5,oe=Math.min(this.width/2,15),this.tipBase1Position={x:this.width-oe-se,y:0},this.tipBase2Position={x:this.width-oe,y:0}):(this.tipBase1Position={x:this.width,y:oe},this.tipBase2Position={x:this.width,y:oe+se}):this.tipPosition.x>=this.width/2&&this.tipPosition.y>=this.height/2?ne<Math.atan((this.tipPosition.y-this.height/2)/(this.tipPosition.x-this.width/2))?(se=this.width/5,oe=Math.min(this.width/2,15),this.tipBase1Position={x:this.width-oe-se,y:this.height},this.tipBase2Position={x:this.width-oe,y:this.height}):(this.tipBase1Position={x:this.width,y:this.height-oe-se},this.tipBase2Position={x:this.width,y:this.height-oe}):ne<Math.atan((this.tipPosition.y-this.height/2)/(this.width/2-this.tipPosition.x))?(se=this.width/5,oe=Math.min(this.width/2,15),this.tipBase1Position={x:oe,y:this.height},this.tipBase2Position={x:oe+se,y:this.height}):(this.tipBase1Position={x:0,y:this.height-oe},this.tipBase2Position={x:0,y:this.height-oe-se})},te.prototype.resize=function(ee){ae.prototype.resize.call(this,ee),this.positionTip()},te.prototype.positionTip=function(){be.setAttributes(this.tip,[["points",this.getTipPoints()]]);var ee=this.tipGrip.visual.transform.baseVal.getItem(0);ee.setTranslate(this.tipPosition.x,this.tipPosition.y),this.tipGrip.visual.transform.baseVal.replaceItem(ee,0)},Object.defineProperty(te.prototype,"toolboxPanels",{get:function(){return[this.colorPanel,this.bgColorPanel,this.fontFamilyPanel]},enumerable:!1,configurable:!0}),te.prototype.select=function(){this.positionTip(),ae.prototype.select.call(this)},te.prototype.getState=function(){var ee=Object.assign({bgColor:this.bgColor,tipPosition:this.tipPosition},ae.prototype.getState.call(this));return ee.typeName=te.typeName,ee},te.prototype.restoreState=function(ee){var oe=ee;this.bgColor=oe.bgColor,this.tipPosition=oe.tipPosition,ae.prototype.restoreState.call(this,ee),this.createTip(),this.setTipPoints()},te.prototype.scale=function(ee,oe){ae.prototype.scale.call(this,ee,oe),this.tipPosition={x:this.tipPosition.x*ee,y:this.tipPosition.y*oe},this.positionTip()},te.typeName="CalloutMarker",te.title="Callout marker",te.icon='<svg viewBox="0 0 24 24"><path d="M4 2h16a2 2 0 012 2v12a2 2 0 01-2 2h-4l-4 4-4-4H4a2 2 0 01-2-2V4a2 2 0 012-2m0 2v12h4.83L12 19.17 15.17 16H20V4H4m2 3h12v2H6V7m0 4h10v2H6v-2z"/></svg>',te}(at),jt=function(ae){function te(ee,oe,se){var ne=ae.call(this,ee,oe,se)||this;return ne.fillColor="transparent",ne.strokeColor="transparent",ne.strokeWidth=0,ne.strokeDasharray="",ne.opacity=1,ne.strokeColor=se.defaultColor,ne.strokeWidth=se.defaultStrokeWidth,ne.strokeDasharray=se.defaultStrokeDasharray,ne.fillColor=se.defaultFillColor,ne.setStrokeColor=ne.setStrokeColor.bind(ne),ne.setFillColor=ne.setFillColor.bind(ne),ne.setStrokeWidth=ne.setStrokeWidth.bind(ne),ne.setStrokeDasharray=ne.setStrokeDasharray.bind(ne),ne.setOpacity=ne.setOpacity.bind(ne),ne.createVisual=ne.createVisual.bind(ne),ne.strokePanel=new Ge("Line color",ye(se.defaultColorSet,["transparent"]),se.defaultColor),ne.strokePanel.onColorChanged=ne.setStrokeColor,ne.fillPanel=new Ge("Fill color",ye(se.defaultColorSet,["transparent"]),ne.fillColor,ce),ne.fillPanel.onColorChanged=ne.setFillColor,ne.strokeWidthPanel=new it("Line width",se.defaultStrokeWidths,se.defaultStrokeWidth),ne.strokeWidthPanel.onWidthChanged=ne.setStrokeWidth,ne.strokeStylePanel=new je("Line style",se.defaultStrokeDasharrays,se.defaultStrokeDasharray),ne.strokeStylePanel.onStyleChanged=ne.setStrokeDasharray,ne.opacityPanel=new He("Opacity",se.defaultOpacitySteps,ne.opacity),ne.opacityPanel.onOpacityChanged=ne.setOpacity,ne}return Ke(te,ae),te.prototype.ownsTarget=function(ee){return!(!ae.prototype.ownsTarget.call(this,ee)&&ee!==this.visual)},te.prototype.createVisual=function(){this.visual=be.createEllipse(this.width/2,this.height/2,[["fill",this.fillColor],["stroke",this.strokeColor],["stroke-width",this.strokeWidth.toString()],["stroke-dasharray",this.strokeDasharray],["opacity",this.opacity.toString()]]),this.addMarkerVisualToContainer(this.visual)},te.prototype.pointerDown=function(ee,oe){ae.prototype.pointerDown.call(this,ee,oe),this.state==="new"&&(this.createVisual(),this.moveVisual(ee),this._state="creating")},te.prototype.manipulate=function(ee){ae.prototype.manipulate.call(this,ee)},te.prototype.resize=function(ee){ae.prototype.resize.call(this,ee),this.setSize()},te.prototype.setSize=function(){ae.prototype.setSize.call(this),be.setAttributes(this.visual,[["cx",(this.width/2).toString()],["cy",(this.height/2).toString()],["rx",(this.width/2).toString()],["ry",(this.height/2).toString()]])},te.prototype.pointerUp=function(ee){ae.prototype.pointerUp.call(this,ee),this.setSize()},te.prototype.setStrokeColor=function(ee){this.strokeColor=ee,this.visual&&be.setAttributes(this.visual,[["stroke",this.strokeColor]]),this.colorChanged(ee),this.stateChanged()},te.prototype.setFillColor=function(ee){this.fillColor=ee,this.visual&&be.setAttributes(this.visual,[["fill",this.fillColor]]),this.fillColorChanged(ee),this.stateChanged()},te.prototype.setStrokeWidth=function(ee){this.strokeWidth=ee,this.visual&&be.setAttributes(this.visual,[["stroke-width",this.strokeWidth.toString()]]),this.stateChanged()},te.prototype.setStrokeDasharray=function(ee){this.strokeDasharray=ee,this.visual&&be.setAttributes(this.visual,[["stroke-dasharray",this.strokeDasharray]]),this.stateChanged()},te.prototype.setOpacity=function(ee){this.opacity=ee,this.visual&&be.setAttributes(this.visual,[["opacity",this.opacity.toString()]]),this.stateChanged()},Object.defineProperty(te.prototype,"toolboxPanels",{get:function(){return[this.strokePanel,this.fillPanel,this.strokeWidthPanel,this.strokeStylePanel,this.opacityPanel]},enumerable:!1,configurable:!0}),te.prototype.getState=function(){var ee=Object.assign({fillColor:this.fillColor,strokeColor:this.strokeColor,strokeWidth:this.strokeWidth,strokeDasharray:this.strokeDasharray,opacity:this.opacity},ae.prototype.getState.call(this));return ee.typeName=te.typeName,ee},te.prototype.restoreState=function(ee){var oe=ee;this.fillColor=oe.fillColor,this.strokeColor=oe.strokeColor,this.strokeWidth=oe.strokeWidth,this.strokeDasharray=oe.strokeDasharray,this.opacity=oe.opacity,this.createVisual(),ae.prototype.restoreState.call(this,ee),this.setSize()},te.prototype.scale=function(ee,oe){ae.prototype.scale.call(this,ee,oe),this.setSize()},te.typeName="EllipseMarker",te.title="Ellipse marker",te.icon='<svg viewBox="0 0 24 24"><path d="M12 4C6.5 4 2 7.58 2 12s4.5 8 10 8 10-3.58 10-8-4.5-8-10-8z"/></svg>',te}(mt),wt=function(ae){function te(ee,oe,se){return ae.call(this,ee,oe,se)||this}return Ke(te,ae),Object.defineProperty(te.prototype,"tipLength",{get:function(){return 10+3*this.strokeWidth},enumerable:!1,configurable:!0}),te.prototype.ownsTarget=function(ee){return!(!ae.prototype.ownsTarget.call(this,ee)&&ee!==this.tip1&&ee!==this.tip2)},te.prototype.createTips=function(){this.tip1=be.createLine(this.x1-this.tipLength/2,this.y1,this.x1+this.tipLength/2,this.y1,[["stroke",this.strokeColor],["stroke-width",this.strokeWidth.toString()]]),this.tip1.transform.baseVal.appendItem(be.createTransform()),this.visual.appendChild(this.tip1),this.tip2=be.createLine(this.x2-this.tipLength/2,this.y2,this.x2+this.tipLength/2,this.y2,[["stroke",this.strokeColor],["stroke-width",this.strokeWidth.toString()]]),this.tip2.transform.baseVal.appendItem(be.createTransform()),this.visual.appendChild(this.tip2)},te.prototype.pointerDown=function(ee,oe){ae.prototype.pointerDown.call(this,ee,oe),this.state==="creating"&&this.createTips()},te.prototype.adjustVisual=function(){if(ae.prototype.adjustVisual.call(this),this.tip1&&this.tip2&&(be.setAttributes(this.tip1,[["x1",(this.x1-this.tipLength/2).toString()],["y1",this.y1.toString()],["x2",(this.x1+this.tipLength/2).toString()],["y2",this.y1.toString()],["stroke",this.strokeColor],["stroke-width",this.strokeWidth.toString()]]),be.setAttributes(this.tip2,[["x1",(this.x2-this.tipLength/2).toString()],["y1",this.y2.toString()],["x2",(this.x2+this.tipLength/2).toString()],["y2",this.y2.toString()],["stroke",this.strokeColor],["stroke-width",this.strokeWidth.toString()]]),Math.abs(this.x1-this.x2)>.1)){var ee=180*Math.atan((this.y2-this.y1)/(this.x2-this.x1))/Math.PI+90*Math.sign(this.x1-this.x2),oe=this.tip1.transform.baseVal.getItem(0);oe.setRotate(ee,this.x1,this.y1),this.tip1.transform.baseVal.replaceItem(oe,0);var se=this.tip2.transform.baseVal.getItem(0);se.setRotate(ee+180,this.x2,this.y2),this.tip2.transform.baseVal.replaceItem(se,0)}},Object.defineProperty(te.prototype,"toolboxPanels",{get:function(){return[this.strokePanel,this.strokeWidthPanel,this.strokeStylePanel]},enumerable:!1,configurable:!0}),te.prototype.getState=function(){var ee=ae.prototype.getState.call(this);return ee.typeName=te.typeName,ee},te.prototype.restoreState=function(ee){ae.prototype.restoreState.call(this,ee),this.createTips(),this.adjustVisual()},te.typeName="MeasurementMarker",te.title="Measurement marker",te.icon='<svg viewBox="0 0 24 24"><path d="M1.39 18.36l1.77-1.76L4.58 18l1.06-1.05-1.42-1.41 1.42-1.42 2.47 2.48 1.06-1.06-2.47-2.48 1.41-1.41 1.42 1.41L10.59 12l-1.42-1.41 1.42-1.42 2.47 2.48 1.06-1.06-2.47-2.48 1.41-1.41 1.41 1.41 1.07-1.06-1.42-1.41 1.42-1.42L18 6.7l1.07-1.06-2.47-2.48 1.76-1.77 4.25 4.25L5.64 22.61l-4.25-4.25z"/></svg>',te}(ht),Ie=function(ae){function te(ee,oe,se){var ne=ae.call(this,ee,oe,se)||this;return ne.strokePanel.colors=se.defaultColorSet,ne.fillColor="transparent",ne}return Ke(te,ae),Object.defineProperty(te.prototype,"toolboxPanels",{get:function(){return[this.strokePanel,this.strokeWidthPanel,this.strokeStylePanel]},enumerable:!1,configurable:!0}),te.prototype.getState=function(){var ee=ae.prototype.getState.call(this);return ee.typeName=te.typeName,ee},te.typeName="EllipseFrameMarker",te.title="Ellipse frame marker",te.icon='<svg viewBox="0 0 24 24"><path d="M12 6c4.41 0 8 2.69 8 6s-3.59 6-8 6-8-2.69-8-6 3.59-6 8-6m0-2C6.5 4 2 7.58 2 12s4.5 8 10 8 10-3.58 10-8-4.5-8-10-8z"/></svg>',te}(jt),Ue=function(){function ae(){this.undoStack=[],this.redoStack=[]}return Object.defineProperty(ae.prototype,"isUndoPossible",{get:function(){return this.undoStack.length>0},enumerable:!1,configurable:!0}),Object.defineProperty(ae.prototype,"isRedoPossible",{get:function(){return this.redoStack.length>0},enumerable:!1,configurable:!0}),Object.defineProperty(ae.prototype,"undoStepCount",{get:function(){return this.undoStack.length},enumerable:!1,configurable:!0}),Object.defineProperty(ae.prototype,"redoStepCount",{get:function(){return this.redoStack.length},enumerable:!1,configurable:!0}),ae.prototype.addUndoStep=function(te){this.undoStack.length!==0&&JSON.stringify(this.undoStack[this.undoStack.length-1])===JSON.stringify(te)||(this.undoStack.push(te),JSON.stringify(this.lastRedoStep)!==JSON.stringify(te)&&this.redoStack.splice(0,this.redoStack.length))},ae.prototype.replaceLastUndoStep=function(te){this.undoStack.length>0&&(this.undoStack[this.undoStack.length-1]=te)},ae.prototype.getLastUndoStep=function(){return this.undoStack.length>0?this.undoStack[this.undoStack.length-1]:void 0},ae.prototype.undo=function(){if(this.undoStack.length>1){var te=this.undoStack.pop();return te!==void 0&&this.redoStack.push(te),this.undoStack.length>0?this.undoStack[this.undoStack.length-1]:void 0}},ae.prototype.redo=function(){return this.lastRedoStep=this.redoStack.pop(),this.lastRedoStep},ae}(),et=function(ae){function te(ee,oe,se){var ne=ae.call(this,ee,oe,se)||this;return ne.strokeColor="transparent",ne.strokeWidth=0,ne.strokeDasharray="",ne.curveX=0,ne.curveY=0,ne.manipulationStartCurveX=0,ne.manipulationStartCurveY=0,ne.setStrokeColor=ne.setStrokeColor.bind(ne),ne.setStrokeWidth=ne.setStrokeWidth.bind(ne),ne.setStrokeDasharray=ne.setStrokeDasharray.bind(ne),ne.positionGrips=ne.positionGrips.bind(ne),ne.addControlGrips=ne.addControlGrips.bind(ne),ne.adjustVisual=ne.adjustVisual.bind(ne),ne.setupControlBox=ne.setupControlBox.bind(ne),ne.resize=ne.resize.bind(ne),ne.strokeColor=se.defaultColor,ne.strokeWidth=se.defaultStrokeWidth,ne.strokeDasharray=se.defaultStrokeDasharray,ne.strokePanel=new Ge("Line color",se.defaultColorSet,se.defaultColor),ne.strokePanel.onColorChanged=ne.setStrokeColor,ne.strokeWidthPanel=new it("Line width",se.defaultStrokeWidths,se.defaultStrokeWidth),ne.strokeWidthPanel.onWidthChanged=ne.setStrokeWidth,ne.strokeStylePanel=new je("Line style",se.defaultStrokeDasharrays,se.defaultStrokeDasharray),ne.strokeStylePanel.onStyleChanged=ne.setStrokeDasharray,ne}return Ke(te,ae),te.prototype.ownsTarget=function(ee){return!(!ae.prototype.ownsTarget.call(this,ee)&&ee!==this.visual&&ee!==this.selectorCurve&&ee!==this.visibleCurve&&!this.curveGrip.ownsTarget(ee))},te.prototype.getPathD=function(){return"M "+this.x1+" "+this.y1+" Q "+this.curveX+" "+this.curveY+", "+this.x2+" "+this.y2},te.prototype.createVisual=function(){this.visual=be.createGroup(),this.selectorCurve=be.createPath(this.getPathD(),[["stroke","transparent"],["stroke-width",(this.strokeWidth+10).toString()],["fill","transparent"]]),this.visibleCurve=be.createPath(this.getPathD(),[["stroke",this.strokeColor],["stroke-width",this.strokeWidth.toString()],["fill","transparent"]]),this.visual.appendChild(this.selectorCurve),this.visual.appendChild(this.visibleCurve),this.addMarkerVisualToContainer(this.visual)},te.prototype.pointerDown=function(ee,oe){ae.prototype.pointerDown.call(this,ee,oe),this.manipulationStartCurveX=this.curveX,this.manipulationStartCurveY=this.curveY,this.state==="new"&&(this.curveX=ee.x,this.curveY=ee.y),this.state==="new"?(this.createVisual(),this.adjustVisual(),this._state="creating"):this.curveGrip.ownsTarget(oe)&&(this.activeGrip=this.curveGrip,this._state="resize")},te.prototype.adjustVisual=function(){this.selectorCurve&&this.visibleCurve&&(this.selectorCurve.setAttribute("d",this.getPathD()),this.visibleCurve.setAttribute("d",this.getPathD()),be.setAttributes(this.visibleCurve,[["stroke",this.strokeColor]]),be.setAttributes(this.visibleCurve,[["stroke-width",this.strokeWidth.toString()]]),be.setAttributes(this.visibleCurve,[["stroke-dasharray",this.strokeDasharray.toString()]]))},te.prototype.setupControlBox=function(){ae.prototype.setupControlBox.call(this),this.curveControlLine1=be.createLine(this.x1,this.y1,this.curveX,this.curveY,[["stroke","black"],["stroke-width","1"],["stroke-opacity","0.5"],["stroke-dasharray","3, 2"]]),this.curveControlLine2=be.createLine(this.x2,this.y2,this.curveX,this.curveY,[["stroke","black"],["stroke-width","1"],["stroke-opacity","0.5"],["stroke-dasharray","3, 2"]]),this.controlBox.insertBefore(this.curveControlLine1,this.controlBox.firstChild),this.controlBox.insertBefore(this.curveControlLine2,this.controlBox.firstChild)},te.prototype.addControlGrips=function(){this.curveGrip=this.createGrip(),this.curveX=0,this.curveY=0,ae.prototype.addControlGrips.call(this)},te.prototype.positionGrips=function(){ae.prototype.positionGrips.call(this);var ee=this.curveGrip.GRIP_SIZE;this.positionGrip(this.curveGrip.visual,this.curveX-ee/2,this.curveY-ee/2),this.curveControlLine1&&this.curveControlLine2&&(this.curveControlLine1.setAttribute("x1",this.x1.toString()),this.curveControlLine1.setAttribute("y1",this.y1.toString()),this.curveControlLine1.setAttribute("x2",this.curveX.toString()),this.curveControlLine1.setAttribute("y2",this.curveY.toString()),this.curveControlLine2.setAttribute("x1",this.x2.toString()),this.curveControlLine2.setAttribute("y1",this.y2.toString()),this.curveControlLine2.setAttribute("x2",this.curveX.toString()),this.curveControlLine2.setAttribute("y2",this.curveY.toString()))},te.prototype.manipulate=function(ee){this.state==="move"&&(this.curveX=this.manipulationStartCurveX+ee.x-this.manipulationStartX,this.curveY=this.manipulationStartCurveY+ee.y-this.manipulationStartY),ae.prototype.manipulate.call(this,ee)},te.prototype.resize=function(ee){this.activeGrip===this.curveGrip&&(this.curveX=ee.x,this.curveY=ee.y),ae.prototype.resize.call(this,ee),this.state==="creating"&&(this.curveX=this.x1+(this.x2-this.x1)/2,this.curveY=this.y1+(this.y2-this.y1)/2)},te.prototype.setStrokeColor=function(ee){this.strokeColor=ee,this.adjustVisual(),this.colorChanged(ee)},te.prototype.setStrokeWidth=function(ee){this.strokeWidth=ee,this.adjustVisual()},te.prototype.setStrokeDasharray=function(ee){this.strokeDasharray=ee,this.adjustVisual()},te.prototype.scale=function(ee,oe){this.curveX=this.curveX*ee,this.curveY=this.curveY*oe,ae.prototype.scale.call(this,ee,oe)},Object.defineProperty(te.prototype,"toolboxPanels",{get:function(){return[this.strokePanel,this.strokeWidthPanel,this.strokeStylePanel]},enumerable:!1,configurable:!0}),te.prototype.getState=function(){var ee=Object.assign({strokeColor:this.strokeColor,strokeWidth:this.strokeWidth,strokeDasharray:this.strokeDasharray,curveX:this.curveX,curveY:this.curveY},ae.prototype.getState.call(this));return ee.typeName=te.typeName,ee},te.prototype.restoreState=function(ee){ae.prototype.restoreState.call(this,ee);var oe=ee;this.strokeColor=oe.strokeColor,this.strokeWidth=oe.strokeWidth,this.strokeDasharray=oe.strokeDasharray,this.curveX=oe.curveX,this.curveY=oe.curveY,this.createVisual(),this.adjustVisual()},te.typeName="CurveMarker",te.title="Curve marker",te.icon='<svg viewBox="0 0 24 24"><path d="M18.5 2A1.5 1.5 0 0120 3.5 1.5 1.5 0 0118.5 5c-.23 0-.45-.05-.65-.15l-3.69 3.7.34.45c2.19-1.26 4.76-2 7.5-2l1 .03v2.01L22 9c-2.58 0-5 .75-7 2.04A3.96 3.96 0 0111.04 15C9.75 17 9 19.42 9 22l.04 1H7.03L7 22c0-2.74.74-5.31 2-7.5l-.45-.34-3.7 3.69c.1.2.15.42.15.65A1.5 1.5 0 013.5 20 1.5 1.5 0 012 18.5 1.5 1.5 0 013.5 17c.23 0 .45.05.65.15l3.69-3.7C7.31 12.78 7 11.92 7 11a4 4 0 014-4c.92 0 1.78.31 2.45.84l3.7-3.69c-.1-.2-.15-.42-.15-.65A1.5 1.5 0 0118.5 2M11 9a2 2 0 00-2 2 2 2 0 002 2 2 2 0 002-2 2 2 0 00-2-2z"/></svg>',te}(tt),cn=function(ae){function te(ee,oe,se){var ne=ae.call(this,ee,oe,se)||this;return ne.fillColor="transparent",ne.strokeColor="transparent",ne.strokeWidth=0,ne.strokeDasharray="",ne.textColor="transparent",ne.fontSize="1rem",ne.isMoved=!1,ne.captionText="Caption",ne.PADDING=5,ne.captionBoxWidth=0,ne.captionBoxHeight=0,ne.strokeColor=se.defaultColor,ne.strokeWidth=se.defaultStrokeWidth,ne.strokeDasharray=se.defaultStrokeDasharray,ne.fillColor=se.defaultFillColor,ne.textColor=se.defaultStrokeColor,ne.fontFamily=se.defaultFontFamily,ne.fontSize=se.defaultCaptionFontSize,ne.captionText=se.defaultCaptionText,ne.setStrokeColor=ne.setStrokeColor.bind(ne),ne.setFillColor=ne.setFillColor.bind(ne),ne.setStrokeWidth=ne.setStrokeWidth.bind(ne),ne.setStrokeDasharray=ne.setStrokeDasharray.bind(ne),ne.createVisual=ne.createVisual.bind(ne),ne.sizeCaption=ne.sizeCaption.bind(ne),ne.setCaptionText=ne.setCaptionText.bind(ne),ne.showTextEditor=ne.showTextEditor.bind(ne),ne.positionTextEditor=ne.positionTextEditor.bind(ne),ne.finishTextEditing=ne.finishTextEditing.bind(ne),ne.setFont=ne.setFont.bind(ne),ne.setTextColor=ne.setTextColor.bind(ne),ne.strokePanel=new Ge("Line color",ye(se.defaultColorSet,["transparent"]),ne.strokeColor),ne.strokePanel.onColorChanged=ne.setStrokeColor,ne.fillPanel=new Ge("Fill color",ye(se.defaultColorSet,["transparent"]),ne.fillColor,ce),ne.fillPanel.onColorChanged=ne.setFillColor,ne.strokeWidthPanel=new it("Line width",se.defaultStrokeWidths,se.defaultStrokeWidth),ne.strokeWidthPanel.onWidthChanged=ne.setStrokeWidth,ne.strokeStylePanel=new je("Line style",se.defaultStrokeDasharrays,se.defaultStrokeDasharray),ne.strokeStylePanel.onStyleChanged=ne.setStrokeDasharray,ne.fontFamilyPanel=new $e("Font",se.defaultFontFamilies,se.defaultFontFamily),ne.fontFamilyPanel.onFontChanged=ne.setFont,ne.textColorPanel=new Ge("Text color",se.defaultColorSet,ne.textColor,ge),ne.textColorPanel.onColorChanged=ne.setTextColor,ne}return Ke(te,ae),te.prototype.ownsTarget=function(ee){return!(!ae.prototype.ownsTarget.call(this,ee)&&ee!==this.visual&&ee!==this.frame&&ee!==this.captionBg&&ee!==this.captionElement)},te.prototype.createVisual=function(){this.visual=be.createGroup(),this.addMarkerVisualToContainer(this.visual),this.captionBg=be.createRect(1,1,[["fill",this.fillColor]]),this.visual.appendChild(this.captionBg),this.captionElement=be.createText([["fill",this.textColor],["font-family",this.fontFamily]]),this.captionElement.style.fontSize=this.fontSize,this.captionElement.style.textAnchor="start",this.captionElement.style.dominantBaseline="text-before-edge",this.captionElement.textContent=this.captionText,this.visual.appendChild(this.captionElement),this.frame=be.createRect(this.width,this.height,[["fill","transparent"],["stroke",this.strokeColor],["stroke-width",this.strokeWidth.toString()],["stroke-dasharray",this.strokeDasharray]]),this.visual.appendChild(this.frame),this.sizeCaption()},te.prototype.setCaptionText=function(ee){this.captionText=ee,this.captionElement.textContent=this.captionText,this.sizeCaption()},te.prototype.pointerDown=function(ee,oe){ae.prototype.pointerDown.call(this,ee,oe),this.isMoved=!1,this.pointerDownPoint=ee,this.pointerDownTimestamp=Date.now(),this.state==="new"&&(this.createVisual(),this.moveVisual(ee),this._state="creating")},te.prototype.manipulate=function(ee){ae.prototype.manipulate.call(this,ee),this.pointerDownPoint!==void 0&&(this.isMoved=Math.abs(ee.x-this.pointerDownPoint.x)>5||Math.abs(ee.y-this.pointerDownPoint.y)>5)},te.prototype.resize=function(ee){ae.prototype.resize.call(this,ee),this.setSize()},te.prototype.sizeCaption=function(){var ee=this.captionElement.getBBox();this.captionText.trim()!==""?(this.captionBoxWidth=ee.width+2*this.PADDING,this.captionBoxHeight=ee.height+2*this.PADDING):(this.captionBoxWidth=0,this.captionBoxHeight=0),be.setAttributes(this.captionBg,[["width",this.captionBoxWidth.toString()],["height",this.captionBoxHeight.toString()],["clip-path","path('M0,0 H"+this.width+" V"+this.height+" H"+-this.width+" Z')"]]),be.setAttributes(this.captionElement,[["x",this.PADDING.toString()],["y",this.PADDING.toString()],["clip-path","path('M0,0 H"+(this.width-this.PADDING)+" V"+this.height+" H"+(-this.width-this.PADDING)+" Z')"]])},te.prototype.showTextEditor=function(){var ee=this;this._state="edit",this.overlayContainer.innerHTML="",this.textEditDiv=document.createElement("div"),this.textEditDiv.style.flexGrow="2",this.textEditDiv.style.alignItems="center",this.textEditDiv.style.justifyContent="center",this.textEditDiv.style.pointerEvents="auto",this.textEditDiv.style.overflow="hidden",this.textEditBox=document.createElement("input"),this.textEditBox.style.position="absolute",this.textEditBox.style.width=this.width+"px",this.captionBoxHeight>0&&(this.textEditBox.style.height=this.captionBoxHeight+"px"),this.textEditBox.style.fontSize=this.fontSize,this.textEditBox.style.fontFamily=this.fontFamily,this.textEditBox.style.backgroundColor=this.fillColor,this.textEditBox.style.color=this.textColor,this.textEditBox.style.borderWidth="0",this.textEditBox.setAttribute("value",this.captionText),this.textEditBox.select(),this.textEditDiv.appendChild(this.textEditBox),this.overlayContainer.appendChild(this.textEditDiv),this.textEditBox.addEventListener("pointerup",function(oe){oe.stopPropagation()}),this.textEditBox.addEventListener("keypress",function(oe){oe.key==="Enter"&&ee.finishTextEditing(ee.textEditBox.value)}),this.textEditBox.addEventListener("keyup",function(oe){oe.cancelBubble=!0}),this.textEditBox.addEventListener("blur",function(){ee.finishTextEditing(ee.textEditBox.value)}),this.textEditDiv.addEventListener("pointerup",function(){ee.finishTextEditing(ee.textEditBox.value)}),this.positionTextEditor(),this.textEditBox.focus()},te.prototype.positionTextEditor=function(){this.state==="edit"&&(this.textEditBox===void 0?this.showTextEditor():(this.textEditBox.style.left=this.left+"px",this.textEditBox.style.top=this.top+"px",this.textEditBox.style.transform="rotate("+this.rotationAngle+"deg)",this.textEditBox.style.transformOrigin=this.width/2+"px "+this.height/2+"px"))},te.prototype.finishTextEditing=function(ee){this.setCaptionText(ee.trim()),this.overlayContainer.innerHTML="",this.stateChanged()},te.prototype.setFont=function(ee){this.captionElement&&be.setAttributes(this.captionElement,[["font-family",ee]]),this.fontFamily=ee,this.textEditBox&&(this.textEditBox.style.fontFamily=this.fontFamily),this.sizeCaption(),this.stateChanged()},te.prototype.setTextColor=function(ee){this.captionElement&&be.setAttributes(this.captionElement,[["fill",ee]]),this.textColor=ee,this.textEditBox&&(this.textEditBox.style.color=this.textColor),this.stateChanged()},te.prototype.setSize=function(){ae.prototype.setSize.call(this),be.setAttributes(this.frame,[["width",this.width.toString()],["height",this.height.toString()]]),this.sizeCaption()},te.prototype.pointerUp=function(ee){ae.prototype.pointerUp.call(this,ee),this.setSize(),!this.isMoved&&Date.now()-this.pointerDownTimestamp>500&&this.showTextEditor(),this.pointerDownPoint=void 0},te.prototype.dblClick=function(ee,oe){ae.prototype.dblClick.call(this,ee,oe),this.showTextEditor()},te.prototype.setStrokeColor=function(ee){this.strokeColor=ee,this.frame&&be.setAttributes(this.frame,[["stroke",this.strokeColor]]),this.colorChanged(ee),this.stateChanged()},te.prototype.setFillColor=function(ee){this.fillColor=ee,this.captionBg&&be.setAttributes(this.captionBg,[["fill",this.fillColor]]),this.fillColorChanged(ee),this.stateChanged()},te.prototype.setStrokeWidth=function(ee){this.strokeWidth=ee,this.frame&&be.setAttributes(this.frame,[["stroke-width",this.strokeWidth.toString()]]),this.stateChanged()},te.prototype.setStrokeDasharray=function(ee){this.strokeDasharray=ee,this.frame&&be.setAttributes(this.frame,[["stroke-dasharray",this.strokeDasharray]]),this.stateChanged()},Object.defineProperty(te.prototype,"toolboxPanels",{get:function(){return[this.strokePanel,this.fillPanel,this.strokeWidthPanel,this.strokeStylePanel,this.fontFamilyPanel,this.textColorPanel]},enumerable:!1,configurable:!0}),te.prototype.getState=function(){var ee=Object.assign({fillColor:this.fillColor,strokeColor:this.strokeColor,strokeWidth:this.strokeWidth,strokeDasharray:this.strokeDasharray,opacity:1,textColor:this.textColor,fontFamily:this.fontFamily,fontSize:this.fontSize,captionText:this.captionText},ae.prototype.getState.call(this));return ee.typeName=this.typeName,ee},te.prototype.restoreState=function(ee){var oe=ee;this.fillColor=oe.fillColor,this.strokeColor=oe.strokeColor,this.strokeWidth=oe.strokeWidth,this.strokeDasharray=oe.strokeDasharray,this.textColor=oe.textColor,this.fontFamily=oe.fontFamily,this.captionText=oe.captionText,this.fontSize=oe.fontSize,this.createVisual(),ae.prototype.restoreState.call(this,ee),this.setSize()},te.prototype.scale=function(ee,oe){ae.prototype.scale.call(this,ee,oe),this.setSize()},te.typeName="CaptionFrameMarker",te.title="Caption frame marker",te.icon='<svg viewBox="0 0 24 24"><path d="M5 3c-1.11 0-2 .89-2 2v14c0 1.11.89 2 2 2h14c1.11 0 2-.89 2-2V5c0-1.11-.89-2-2-2H5m0 2h14v14H5V5m2 2v2h10V7H7z"/></svg>',te}(mt),kt=function(){function ae(te,ee){ee===void 0&&(ee=!1),this.cancelable=!1,this._defaultPrevented=!1,this.markerArea=te,this.cancelable=ee}return Object.defineProperty(ae.prototype,"defaultPrevented",{get:function(){return this._defaultPrevented},enumerable:!1,configurable:!0}),ae.prototype.preventDefault=function(){this._defaultPrevented=!0},ae}(),Yt=function(ae){function te(ee,oe,se){var ne=ae.call(this,ee,!1)||this;return ne.dataUrl=oe,ne.state=se,ne}return Ke(te,ae),te}(kt),ze=function(ae){function te(ee,oe,se){se===void 0&&(se=!1);var ne=ae.call(this,ee,se)||this;return ne.marker=oe,ne}return Ke(te,ae),te}(kt),zt=function(){function ae(){this.render=[],this.beforeclose=[],this.close=[],this.show=[],this.restorestate=[],this.statechange=[],this.markerselect=[],this.markerdeselect=[],this.markercreating=[],this.markercreate=[],this.markerbeforedelete=[],this.markerdelete=[],this.markerchange=[],this.focus=[],this.blur=[]}return ae.prototype.addEventListener=function(te,ee){this[te].push(ee)},ae.prototype.removeEventListener=function(te,ee){var oe=this[te].indexOf(ee);oe>-1&&this[te].splice(oe,1)},ae}(),ut=function(){function ae(te){this.touchPoints=0,this._availableMarkerTypes=this.DEFAULT_MARKER_TYPES,this.mode="select",this.markers=[],this.isDragging=!1,this.renderEventListeners=[],this.closeEventListeners=[],this.settings=new nt,this._isOpen=!1,this.undoRedoManager=new Ue,this.renderAtNaturalSize=!1,this.renderImageType="image/png",this.renderMarkersOnly=!1,this.zoomSteps=[1,1.5,2,4],this._zoomLevel=1,this._isResizing=!1,this.prevPanPoint={x:0,y:0},this.eventListeners=new zt,this._silentRenderMode=!1,this._isFocused=!1,this._instanceNo=ae.instanceCounter++,this.styles=new fe(this.instanceNo),this.uiStyleSettings=this.styles.settings,this.target=te,this.targetRoot=document.body,this.width=te.clientWidth,this.height=te.clientHeight,this.styles.removeStyleSheet(),this.open=this.open.bind(this),this.setTopLeft=this.setTopLeft.bind(this),this.toolbarButtonClicked=this.toolbarButtonClicked.bind(this),this.createNewMarker=this.createNewMarker.bind(this),this.addNewMarker=this.addNewMarker.bind(this),this.markerCreated=this.markerCreated.bind(this),this.setCurrentMarker=this.setCurrentMarker.bind(this),this.onPointerDown=this.onPointerDown.bind(this),this.onDblClick=this.onDblClick.bind(this),this.onPointerMove=this.onPointerMove.bind(this),this.onPointerUp=this.onPointerUp.bind(this),this.onPointerOut=this.onPointerOut.bind(this),this.onKeyUp=this.onKeyUp.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.deleteSelectedMarker=this.deleteSelectedMarker.bind(this),this.setWindowHeight=this.setWindowHeight.bind(this),this.removeMarker=this.removeMarker.bind(this),this.colorChanged=this.colorChanged.bind(this),this.fillColorChanged=this.fillColorChanged.bind(this),this.onPopupTargetResize=this.onPopupTargetResize.bind(this),this.showNotesEditor=this.showNotesEditor.bind(this),this.hideNotesEditor=this.hideNotesEditor.bind(this),this.stepZoom=this.stepZoom.bind(this),this.focus=this.focus.bind(this),this.blur=this.blur.bind(this),this.markerStateChanged=this.markerStateChanged.bind(this),this.switchToSelectMode=this.switchToSelectMode.bind(this),this.addDefs=this.addDefs.bind(this),this.addDefsToImage=this.addDefsToImage.bind(this)}return Object.defineProperty(ae.prototype,"ALL_MARKER_TYPES",{get:function(){return[Ot,lt,At,at,Ie,jt,Pt,Je,wt,De,ht,et,cn]},enumerable:!1,configurable:!0}),Object.defineProperty(ae.prototype,"DEFAULT_MARKER_TYPES",{get:function(){return[Ot,lt,At,at,jt,Pt,Je]},enumerable:!1,configurable:!0}),Object.defineProperty(ae.prototype,"BASIC_MARKER_TYPES",{get:function(){return[Ot,lt,At,at,Pt]},enumerable:!1,configurable:!0}),Object.defineProperty(ae.prototype,"availableMarkerTypes",{get:function(){return this._availableMarkerTypes},set:function(te){var ee=this;this._availableMarkerTypes.splice(0),te.forEach(function(oe){if(typeof oe=="string"){var se=ee.ALL_MARKER_TYPES.find(function(ne){return ne.typeName===oe});se!==void 0&&ee._availableMarkerTypes.push(se)}else ee._availableMarkerTypes.push(oe)})},enumerable:!1,configurable:!0}),Object.defineProperty(ae.prototype,"currentMarker",{get:function(){return this._currentMarker},enumerable:!1,configurable:!0}),Object.defineProperty(ae.prototype,"isOpen",{get:function(){return this._isOpen},enumerable:!1,configurable:!0}),Object.defineProperty(ae.prototype,"isUndoPossible",{get:function(){return!(!this.undoRedoManager||!this.undoRedoManager.isUndoPossible)},enumerable:!1,configurable:!0}),Object.defineProperty(ae.prototype,"isRedoPossible",{get:function(){return!(!this.undoRedoManager||!this.undoRedoManager.isRedoPossible)},enumerable:!1,configurable:!0}),Object.defineProperty(ae.prototype,"zoomLevel",{get:function(){return this._zoomLevel},set:function(te){this._zoomLevel=te,this.editorCanvas&&this.contentDiv&&(this.editorCanvas.style.transform="scale("+this._zoomLevel+")",this.contentDiv.scrollTo({left:(this.editorCanvas.clientWidth*this._zoomLevel-this.contentDiv.clientWidth)/2,top:(this.editorCanvas.clientHeight*this._zoomLevel-this.contentDiv.clientHeight)/2}))},enumerable:!1,configurable:!0}),Object.defineProperty(ae.prototype,"instanceNo",{get:function(){return this._instanceNo},enumerable:!1,configurable:!0}),ae.prototype.open=function(){this.setupResizeObserver(),this.setEditingTarget(),this.setTopLeft(),this.initMarkerCanvas(),this.initOverlay(),this.attachEvents(),this.settings.displayMode==="popup"&&this.onPopupTargetResize(),Me.isLicensed||this.addLogo(),this._isOpen=!0,this._isFocused=!0},ae.prototype.show=function(){var te=this;this.styles.styleSheetRoot===void 0&&Oe.styleSheetRoot!==void 0&&(this.styles.styleSheetRoot=Oe.styleSheetRoot),this.setWindowHeight(),this.showUI(),this.open(),this.eventListeners.show.forEach(function(ee){return ee(new kt(te))})},ae.prototype.render=function(){return ve(this,void 0,void 0,function(){var te;return Ae(this,function(ee){switch(ee.label){case 0:return this.setCurrentMarker(),(te=new Re).naturalSize=this.renderAtNaturalSize,te.imageType=this.renderImageType,te.imageQuality=this.renderImageQuality,te.markersOnly=this.renderMarkersOnly,te.width=this.renderWidth,te.height=this.renderHeight,[4,te.rasterize(this.target instanceof HTMLImageElement?this.target:null,this.markerImage,this.renderTarget)];case 1:return ee.sent(),[4,te.rasterize(this.target instanceof HTMLImageElement?this.target:null,this.markerImage,this.renderTarget)];case 2:return[2,ee.sent()]}})})},ae.prototype.close=function(te){var ee=this;if(te===void 0&&(te=!1),this.isOpen){var oe=!1;te||this.eventListeners.beforeclose.forEach(function(se){var ne=new kt(ee,!0);se(ne),ne.defaultPrevented&&(oe=!0)}),oe||(this.coverDiv&&this.closeUI(),this.targetObserver&&(this.targetObserver.unobserve(this.target),this.targetObserver.unobserve(this.editorCanvas)),this.settings.displayMode==="popup"&&window.removeEventListener("resize",this.setWindowHeight),this.eventListeners.close.forEach(function(se){return se(new kt(ee))}),this.detachEvents(),this._isOpen=!1)}},ae.prototype.addMarkersToToolbar=function(){for(var te,ee=[],oe=0;oe<arguments.length;oe++)ee[oe]=arguments[oe];(te=this._availableMarkerTypes).push.apply(te,ee)},ae.prototype.addRenderEventListener=function(te){this.addEventListener("render",function(ee){te(ee.dataUrl,ee.state)})},ae.prototype.removeRenderEventListener=function(te){},ae.prototype.addCloseEventListener=function(te){this.addEventListener("close",function(){te()})},ae.prototype.removeCloseEventListener=function(te){},ae.prototype.setupResizeObserver=function(){var te=this;this.settings.displayMode==="inline"?window.ResizeObserver&&(this.targetObserver=new ResizeObserver(function(){te.resize(te.target.clientWidth,te.target.clientHeight)}),this.targetObserver.observe(this.target)):this.settings.displayMode==="popup"&&(window.ResizeObserver&&(this.targetObserver=new ResizeObserver(function(){return te.onPopupTargetResize()}),this.targetObserver.observe(this.editorCanvas)),window.addEventListener("resize",this.setWindowHeight))},ae.prototype.onPopupTargetResize=function(){var te=1*this.target.clientWidth/this.target.clientHeight,ee=this.editorCanvas.clientWidth/te>this.editorCanvas.clientHeight?this.editorCanvas.clientHeight*te:this.editorCanvas.clientWidth,oe=ee<this.editorCanvas.clientWidth?this.editorCanvas.clientHeight:this.editorCanvas.clientWidth/te;this.resize(ee,oe)},ae.prototype.setWindowHeight=function(){this.windowHeight=window.innerHeight},ae.prototype.resize=function(te,ee){this._isResizing=!0;var oe=te/this.imageWidth,se=ee/this.imageHeight;this.imageWidth=Math.round(te),this.imageHeight=Math.round(ee),this.target instanceof HTMLImageElement&&this.editingTarget instanceof HTMLImageElement&&(this.editingTarget.src=this.target.src),this.editingTarget.width=this.imageWidth,this.editingTarget.height=this.imageHeight,this.editingTarget.style.width=this.imageWidth+"px",this.editingTarget.style.height=this.imageHeight+"px",this.markerImage.setAttribute("width",this.imageWidth.toString()),this.markerImage.setAttribute("height",this.imageHeight.toString()),this.markerImage.setAttribute("viewBox","0 0 "+this.imageWidth.toString()+" "+this.imageHeight.toString()),this.markerImageHolder.style.width=this.imageWidth+"px",this.markerImageHolder.style.height=this.imageHeight+"px",this.overlayContainer.style.width=this.imageWidth+"px",this.overlayContainer.style.height=this.imageHeight+"px",this.settings.displayMode!=="popup"?this.coverDiv.style.width=this.imageWidth.toString()+"px":(this.setTopLeft(),this.positionMarkerImage()),this.toolbar!==void 0&&this.toolbar.adjustLayout(),this.positionLogo(),this.scaleMarkers(oe,se),this._isResizing=!1},ae.prototype.scaleMarkers=function(te,ee){var oe,se=this;this._currentMarker&&this._currentMarker instanceof at?this._currentMarker.scale(te,ee):(oe=this._currentMarker,this.setCurrentMarker()),this.markers.forEach(function(ne){ne!==se._currentMarker&&ne.scale(te,ee)}),oe!==void 0&&this.setCurrentMarker(oe)},ae.prototype.setEditingTarget=function(){this.imageWidth=Math.round(this.target.clientWidth),this.imageHeight=Math.round(this.target.clientHeight),this.target instanceof HTMLImageElement&&this.editingTarget instanceof HTMLImageElement&&(this.editingTarget.src=this.target.src),this.editingTarget.width=this.imageWidth,this.editingTarget.height=this.imageHeight,this.editingTarget.style.width=this.imageWidth+"px",this.editingTarget.style.height=this.imageHeight+"px"},ae.prototype.setTopLeft=function(){var te=this.editingTarget.getBoundingClientRect(),ee=this.editorCanvas.getBoundingClientRect();this.left=te.left-ee.left,this.top=te.top-ee.top},ae.prototype.initMarkerCanvas=function(){this.markerImageHolder=document.createElement("div"),this.markerImageHolder.style.setProperty("touch-action","pinch-zoom"),this.markerImage=document.createElementNS("http://www.w3.org/2000/svg","svg"),this.markerImage.setAttribute("xmlns","http://www.w3.org/2000/svg"),this.markerImage.setAttribute("width",this.imageWidth.toString()),this.markerImage.setAttribute("height",this.imageHeight.toString()),this.markerImage.setAttribute("viewBox","0 0 "+this.imageWidth.toString()+" "+this.imageHeight.toString()),this.markerImage.style.pointerEvents="auto",this.markerImageHolder.style.position="absolute",this.markerImageHolder.style.width=this.imageWidth+"px",this.markerImageHolder.style.height=this.imageHeight+"px",this.markerImageHolder.style.transformOrigin="top left",this.positionMarkerImage(),this.markerImageHolder.appendChild(this.markerImage),this.editorCanvas.appendChild(this.markerImageHolder)},ae.prototype.addDefs=function(){for(var te,ee=[],oe=0;oe<arguments.length;oe++)ee[oe]=arguments[oe];this.defs=be.createDefs(),this.addDefsToImage(),(te=this.defs).append.apply(te,ee)},ae.prototype.addDefsToImage=function(){this.defs&&this.markerImage.insertBefore(this.defs,this.markerImage.firstChild)},ae.prototype.initOverlay=function(){this.overlayContainer=document.createElement("div"),this.overlayContainer.style.position="absolute",this.overlayContainer.style.left="0px",this.overlayContainer.style.top="0px",this.overlayContainer.style.width=this.imageWidth+"px",this.overlayContainer.style.height=this.imageHeight+"px",this.overlayContainer.style.display="flex",this.markerImageHolder.appendChild(this.overlayContainer)},ae.prototype.positionMarkerImage=function(){this.markerImageHolder.style.top=this.top/this.zoomLevel+"px",this.markerImageHolder.style.left=this.left/this.zoomLevel+"px"},ae.prototype.attachEvents=function(){this.markerImage.addEventListener("pointerdown",this.onPointerDown),this.markerImage.addEventListener("dblclick",this.onDblClick),this.attachWindowEvents()},ae.prototype.attachWindowEvents=function(){window.addEventListener("pointermove",this.onPointerMove),window.addEventListener("pointerup",this.onPointerUp),window.addEventListener("pointercancel",this.onPointerOut),window.addEventListener("pointerout",this.onPointerOut),window.addEventListener("pointerleave",this.onPointerUp),window.addEventListener("resize",this.onWindowResize),window.addEventListener("keyup",this.onKeyUp)},ae.prototype.detachEvents=function(){this.markerImage.removeEventListener("pointerdown",this.onPointerDown),this.markerImage.removeEventListener("dblclick",this.onDblClick),this.detachWindowEvents()},ae.prototype.detachWindowEvents=function(){window.removeEventListener("pointermove",this.onPointerMove),window.removeEventListener("pointerup",this.onPointerUp),window.removeEventListener("pointercancel",this.onPointerOut),window.removeEventListener("pointerout",this.onPointerOut),window.removeEventListener("pointerleave",this.onPointerUp),window.removeEventListener("resize",this.onWindowResize),window.removeEventListener("keyup",this.onKeyUp)},ae.prototype.addLogo=function(){this.logoUI=document.createElement("div"),this.logoUI.style.display="inline-block",this.logoUI.style.margin="0px",this.logoUI.style.padding="0px",this.logoUI.style.fill="#333333";var te=document.createElement("a");te.href="https://markerjs.com/",te.target="_blank",te.innerHTML='<svg viewBox="0 0 112 96" xmlns="http://www.w3.org/2000/svg" fill-rule="evenodd" clip-rule="evenodd" stroke-linejoin="round" stroke-miterlimit="1.414"><path fill="#e5f20d" fill-opacity=".647" d="M0 40.386h111.96V95.62H0z"/><path d="M93.61 61.452c0 .987-.328 1.831-.987 2.53-.657.7-1.52 1.048-2.591 1.048-1.481 0-2.222-.74-2.222-2.22 0-16.617-.533-29.347-1.604-38.192-1.068-8.842-2.92-13.265-5.552-13.265-4.443 0-10.94 15.509-19.497 46.52v.124c0 .987-.328 1.831-.987 2.53-.657.7-1.52 1.048-2.592 1.048-1.48 0-2.22-.74-2.22-2.22 0-3.29.165-8.392.493-15.302.33-7.732.494-13.82.494-18.262 0-6.17-.186-10.55-.556-13.142-.37-2.591-1.172-3.887-2.406-3.887-2.796 0-6.333 5.12-10.612 15.363C38.494 34.367 34.01 46.44 29.32 60.34l-1.11 3.209a5.714 5.714 0 01-1.42 2.097c-.617.578-1.295.864-2.036.864-.987 0-1.644-.081-1.974-.247-.328-.162-.533-.656-.617-1.48-.41-4.03-.74-9.418-.987-16.165-.163-1.728-.329-4.566-.494-8.515-.822-13.901-1.562-23.3-2.221-28.196-.657-4.893-.987-7.628-.987-8.205 0-.657.33-1.44.987-2.345.659-.903 1.276-1.357 1.85-1.357 1.319 0 2.387.947 3.21 2.838.411.906.863 4.526 1.357 10.859.493 6.335.905 14.19 1.233 23.568l.617 18.88c4.527-13.983 9.216-26.673 14.068-38.068C45.65 6.686 50.093.988 54.123.988c2.715 0 4.566 1.974 5.553 5.923.987 3.949 1.481 9.667 1.481 17.152 0 3.949-.081 9.625-.247 17.029l-.123 5.676c3.373-11.762 6.725-21.634 10.057-29.615 3.331-7.979 6.685-11.97 10.056-11.97 8.475 0 12.71 18.757 12.71 56.269z" fill-rule="nonzero"/></svg>',te.title="Powered by marker.js",te.style.display="grid",te.style.alignItems="center",te.style.justifyItems="center",te.style.padding="3px",te.style.width="20px",te.style.height="20px",this.logoUI.appendChild(te),this.editorCanvas.appendChild(this.logoUI),this.logoUI.style.position="absolute",this.logoUI.style.pointerEvents="all",this.positionLogo()},ae.prototype.positionLogo=function(){this.logoUI&&(this.uiStyleSettings.logoPosition!=="right"?this.logoUI.style.left=this.markerImageHolder.offsetLeft+10+"px":this.logoUI.style.left=this.markerImageHolder.offsetLeft+this.markerImageHolder.offsetWidth-this.logoUI.clientWidth-10+"px",this.logoUI.style.top=this.markerImageHolder.offsetTop+this.markerImageHolder.offsetHeight-this.logoUI.clientHeight-10+"px")},ae.prototype.overrideOverflow=function(){this.scrollXState=window.scrollX,this.scrollYState=window.scrollY,this.bodyOverflowState=document.body.style.overflow,window.scroll({top:0,left:0}),document.body.style.overflow="hidden"},ae.prototype.restoreOverflow=function(){document.body.style.overflow=this.bodyOverflowState,window.scroll({top:this.scrollYState,left:this.scrollXState})},ae.prototype.showUI=function(){switch(this.settings.displayMode==="popup"&&this.overrideOverflow(),this.coverDiv=document.createElement("div"),this.coverDiv.style.visibility=this._silentRenderMode?"hidden":"visible",this.coverDiv.className=this.styles.classNamePrefixBase+" "+this.styles.classNamePrefix,this.coverDiv.style.fontSize="16px",this.coverDiv.style.userSelect="none",this.settings.displayMode){case"inline":this.coverDiv.style.position="absolute";var te=this.settings.uiOffsetTop!==void 0?this.target.offsetTop+this.settings.uiOffsetTop:this.target.offsetTop>this.styles.settings.toolbarHeight?this.target.offsetTop-this.styles.settings.toolbarHeight:0;this.coverDiv.style.top=te+"px",this.coverDiv.style.left=this.target.offsetLeft.toString()+"px",this.coverDiv.style.width=this.target.offsetWidth.toString()+"px",this.coverDiv.style.zIndex=this.uiStyleSettings.zIndex!==void 0?this.uiStyleSettings.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.uiStyleSettings.zIndex!==void 0?this.uiStyleSettings.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.settings.displayMode==="popup"?this.settings.popupMargin+"px":"0px",this.uiDiv.style.border="0px",this.coverDiv.appendChild(this.uiDiv),this.toolbar=new yt(this.uiDiv,this.settings.displayMode,this._availableMarkerTypes,this.uiStyleSettings,this.styles),this.toolbar.addButtonClickListener(this.toolbarButtonClicked),this.toolbar.show(this._silentRenderMode||this.uiStyleSettings.hideToolbar?"hidden":"visible"),this.contentDiv=document.createElement("div"),this.contentDiv.style.display="flex",this.contentDiv.style.flexDirection="row",this.contentDiv.style.flexGrow="2",this.contentDiv.style.flexShrink="1",this.settings.displayMode==="popup"&&(this.contentDiv.style.backgroundColor=this.uiStyleSettings.canvasBackgroundColor,this.contentDiv.style.maxHeight=this.windowHeight-2*this.settings.popupMargin-3.5*this.uiStyleSettings.toolbarHeight+"px",this.contentDiv.style.maxWidth="calc(100vw - "+2*this.settings.popupMargin+"px)"),this.contentDiv.style.overflow="auto",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.settings.displayMode==="popup"&&(this.editorCanvas.style.alignItems="center",this.editorCanvas.style.justifyContent="center"),this.editorCanvas.style.pointerEvents="none",this.editorCanvas.style.transformOrigin="left top",this.editorCanvas.style.transform="scale("+this.zoomLevel+")",this.contentDiv.appendChild(this.editorCanvas),this.editingTarget=this.target instanceof HTMLImageElement?document.createElement("img"):document.createElement("canvas"),this.settings.uiOffsetTop===void 0&&this.target.offsetTop<this.styles.settings.toolbarHeight&&(this.editingTarget.style.marginTop=this.target.offsetTop-this.styles.settings.toolbarHeight+"px"),this.editorCanvas.appendChild(this.editingTarget),this.toolbox=new Xe(this.uiDiv,this.settings.displayMode,this.uiStyleSettings,this.styles),this.toolbox.show(this._silentRenderMode||this.uiStyleSettings.hideToolbox?"hidden":"visible")},ae.prototype.closeUI=function(){this.settings.displayMode==="popup"&&this.restoreOverflow(),this.targetRoot.removeChild(this.coverDiv)},ae.prototype.removeMarker=function(te){this.markerImage.removeChild(te.container),this.markers.indexOf(te)>-1&&this.markers.splice(this.markers.indexOf(te),1),te.dispose()},ae.prototype.switchToSelectMode=function(){this.mode="select",this.hideNotesEditor(),this._currentMarker!==void 0&&(this._currentMarker.state!=="new"?this._currentMarker.select():(this.removeMarker(this._currentMarker),this.setCurrentMarker(),this.markerImage.style.cursor="default"),this.addUndoStep())},ae.prototype.toolbarButtonClicked=function(te,ee){if(te==="marker"&&ee!==void 0)this.createNewMarker(ee);else if(te==="action")switch(ee){case"select":this.switchToSelectMode(),this.switchToSelectMode();break;case"delete":this.deleteSelectedMarker();break;case"clear":this.clear();break;case"undo":this.undo();break;case"redo":this.redo();break;case"zoom":this.stepZoom();break;case"zoom-out":this.zoomLevel=1;break;case"notes":this.notesArea===void 0?(this.switchToSelectMode(),this.zoomLevel=1,this.showNotesEditor()):this.switchToSelectMode();break;case"close":this.close();break;case"render":this.switchToSelectMode(),this.startRenderAndClose()}},ae.prototype.deleteSelectedMarker=function(){var te=this;if(this._currentMarker!==void 0){var ee=!1;if(this.eventListeners.markerbeforedelete.forEach(function(se){var ne=new ze(te,te._currentMarker,!0);se(ne),ne.defaultPrevented&&(ee=!0)}),!ee){var oe=this._currentMarker;this._currentMarker.dispose(),this.markerImage.removeChild(this._currentMarker.container),this.markers.splice(this.markers.indexOf(this._currentMarker),1),this.setCurrentMarker(),this.addUndoStep(),this.eventListeners.markerdelete.forEach(function(se){return se(new ze(te,oe))})}}},ae.prototype.clear=function(){var te=this,ee=!1;if(this.markers.length>0&&(this.eventListeners.markerbeforedelete.forEach(function(he){var xe=new ze(te,void 0,!0);he(xe),xe.defaultPrevented&&(ee=!0)}),!ee)){this.setCurrentMarker();for(var oe=function(he){var xe=se.markers[he];se.setCurrentMarker(se.markers[he]),se._currentMarker.dispose(),se.markerImage.removeChild(se._currentMarker.container),se.markers.splice(se.markers.indexOf(se._currentMarker),1),se.eventListeners.markerdelete.forEach(function(ot){return ot(new ze(te,xe))})},se=this,ne=this.markers.length-1;ne>=0;ne--)oe(ne);this.addUndoStep()}},Object.defineProperty(ae.prototype,"isNotesAreaOpen",{get:function(){return this.notesArea!==void 0},enumerable:!1,configurable:!0}),ae.prototype.showNotesEditor=function(){var te;this._currentMarker!==void 0&&(this.overlayContainer.innerHTML="",this.notesArea=document.createElement("textarea"),this.notesArea.className=this.uiStyleSettings.notesAreaStyleClassName,this.notesArea.style.pointerEvents="auto",this.notesArea.style.alignSelf="stretch",this.notesArea.style.width="100%",this.notesArea.style.margin=this.uiStyleSettings.toolbarHeight/4+"px",this.notesArea.value=(te=this._currentMarker.notes)!==null&&te!==void 0?te:"",this.overlayContainer.appendChild(this.notesArea))},ae.prototype.hideNotesEditor=function(){this.isNotesAreaOpen&&(this._currentMarker!==void 0&&(this._currentMarker.notes=this.notesArea.value.trim()!==""?this.notesArea.value:void 0),this.overlayContainer.removeChild(this.notesArea),this.notesArea=void 0)},ae.prototype.selectLastMarker=function(){this.markers.length>0?this.setCurrentMarker(this.markers[this.markers.length-1]):this.setCurrentMarker()},ae.prototype.addUndoStep=function(){var te=this;if(this._currentMarker===void 0||this._currentMarker.state!=="edit"){var ee=this.getState(),oe=this.undoRedoManager.getLastUndoStep();if(!oe||oe.width===ee.width&&oe.height===ee.height){var se=this.undoRedoManager.undoStepCount;this.undoRedoManager.addUndoStep(ee),se<this.undoRedoManager.undoStepCount&&this.eventListeners.statechange.forEach(function(ne){return ne(new kt(te))})}else this.undoRedoManager.replaceLastUndoStep(ee),this.eventListeners.statechange.forEach(function(ne){return ne(new kt(te))})}},ae.prototype.undo=function(){this.switchToSelectMode(),this.addUndoStep(),this.undoStep()},ae.prototype.undoStep=function(){var te=this,ee=this.undoRedoManager.undo();ee!==void 0&&(this.restoreState(ee),this.addDefsToImage(),this.selectLastMarker(),this.eventListeners.statechange.forEach(function(oe){return oe(new kt(te))}))},ae.prototype.redo=function(){this.switchToSelectMode(),this.redoStep()},ae.prototype.redoStep=function(){var te=this,ee=this.undoRedoManager.redo();ee!==void 0&&(this.restoreState(ee),this.addDefsToImage(),this.selectLastMarker(),this.eventListeners.statechange.forEach(function(oe){return oe(new kt(te))}))},ae.prototype.stepZoom=function(){var te=this.zoomSteps.indexOf(this.zoomLevel);this.zoomLevel=te<this.zoomSteps.length-1?this.zoomSteps[te+1]:this.zoomSteps[0]},ae.prototype.panTo=function(te){this.contentDiv.scrollBy({left:this.prevPanPoint.x-te.x,top:this.prevPanPoint.y-te.y}),this.prevPanPoint=te},ae.prototype.startRenderAndClose=function(){return ve(this,void 0,void 0,function(){var te,ee,oe=this;return Ae(this,function(se){switch(se.label){case 0:return[4,this.render()];case 1:return te=se.sent(),ee=this.getState(),this.eventListeners.render.forEach(function(ne){return ne(new Yt(oe,te,ee))}),this.close(!0),[2]}})})},ae.prototype.getState=function(te){te===!0&&this.setCurrentMarker();var ee={width:this.imageWidth,height:this.imageHeight,markers:[]};return this.markers.forEach(function(oe){return ee.markers.push(oe.getState())}),ee},ae.prototype.restoreState=function(te){var ee=this;for(this.markers.splice(0);this.markerImage.lastChild;)this.markerImage.removeChild(this.markerImage.lastChild);te.markers.forEach(function(oe){var se=ee._availableMarkerTypes.find(function(he){return he.typeName===oe.typeName});if(se!==void 0){var ne=ee.addNewMarker(se);ne.restoreState(oe),ee.markers.push(ne)}}),te.width&&te.height&&(te.width!==this.imageWidth||te.height!==this.imageHeight)&&this.scaleMarkers(this.imageWidth/te.width,this.imageHeight/te.height),this.eventListeners.restorestate.forEach(function(oe){return oe(new kt(ee))})},ae.prototype.addNewMarker=function(te){var ee=be.createGroup();return this.markerImage.appendChild(ee),new te(ee,this.overlayContainer,this.settings)},ae.prototype.createNewMarker=function(te){var ee,oe=this;(ee=typeof te=="string"?this._availableMarkerTypes.find(function(se){return se.typeName===te}):te)&&(this.setCurrentMarker(),this.addUndoStep(),this._currentMarker=this.addNewMarker(ee),this._currentMarker.onMarkerCreated=this.markerCreated,this._currentMarker.onColorChanged=this.colorChanged,this._currentMarker.onFillColorChanged=this.fillColorChanged,this._currentMarker.onStateChanged=this.markerStateChanged,this.markerImage.style.cursor="crosshair",this.toolbar.setActiveMarkerButton(ee.typeName),this.toolbox.setPanelButtons(this._currentMarker.toolboxPanels),this.eventListeners.markercreating.forEach(function(se){return se(new ze(oe,oe._currentMarker))}))},ae.prototype.markerCreated=function(te){var ee=this;this.mode="select",this.markerImage.style.cursor="default",this.markers.push(te),this.setCurrentMarker(te),te instanceof lt&&this.settings.newFreehandMarkerOnPointerUp?this.createNewMarker(lt):this.toolbar.setSelectMode(),this.addUndoStep(),this.eventListeners.markercreate.forEach(function(oe){return oe(new ze(ee,ee._currentMarker))})},ae.prototype.colorChanged=function(te){this.settings.defaultColorsFollowCurrentColors&&(this.settings.defaultColor=te,this.settings.defaultStrokeColor=te)},ae.prototype.fillColorChanged=function(te){this.settings.defaultColorsFollowCurrentColors&&(this.settings.defaultFillColor=te)},ae.prototype.markerStateChanged=function(te){var ee=this;this.eventListeners.markerchange.forEach(function(oe){return oe(new ze(ee,te))})},ae.prototype.setCurrentMarker=function(te){var ee=this;this._currentMarker!==te&&this._currentMarker!==void 0&&(this._currentMarker.deselect(),this.toolbar.setCurrentMarker(),this.toolbox.setPanelButtons([]),this._isResizing||this.eventListeners.markerdeselect.forEach(function(oe){return oe(new ze(ee,ee._currentMarker))})),this._currentMarker=te,this._currentMarker===void 0||this._currentMarker.isSelected||(this._currentMarker.state!=="new"&&this._currentMarker.select(),this.toolbar.setCurrentMarker(this._currentMarker),this.toolbox.setPanelButtons(this._currentMarker.toolboxPanels),this._isResizing||this.eventListeners.markerselect.forEach(function(oe){return oe(new ze(ee,ee._currentMarker))}))},ae.prototype.onPointerDown=function(te){if(this._isFocused||this.focus(),this.touchPoints++,this.touchPoints===1||te.pointerType!=="touch")if(this._currentMarker===void 0||this._currentMarker.state!=="new"&&this._currentMarker.state!=="creating"){if(this.mode==="select"){var ee=this.markers.find(function(oe){return oe.ownsTarget(te.target)});ee!==void 0?(this.setCurrentMarker(ee),this.isDragging=!0,this._currentMarker.pointerDown(this.clientToLocalCoordinates(te.clientX,te.clientY),te.target)):(this.setCurrentMarker(),this.isDragging=!0,this.prevPanPoint={x:te.clientX,y:te.clientY})}}else this.isDragging=!0,this._currentMarker.pointerDown(this.clientToLocalCoordinates(te.clientX,te.clientY))},ae.prototype.onDblClick=function(te){if(this._isFocused||this.focus(),this.mode==="select"){var ee=this.markers.find(function(oe){return oe.ownsTarget(te.target)});ee!==void 0&&ee!==this._currentMarker&&this.setCurrentMarker(ee),this._currentMarker!==void 0?this._currentMarker.dblClick(this.clientToLocalCoordinates(te.clientX,te.clientY),te.target):this.setCurrentMarker()}},ae.prototype.onPointerMove=function(te){this.touchPoints!==1&&te.pointerType==="touch"||(this._currentMarker!==void 0||this.isDragging)&&(this._currentMarker!==void 0&&this._currentMarker.state==="edit"||te.preventDefault(),this._currentMarker!==void 0?this._currentMarker.manipulate(this.clientToLocalCoordinates(te.clientX,te.clientY)):this.zoomLevel>1&&this.panTo({x:te.clientX,y:te.clientY}))},ae.prototype.onPointerUp=function(te){this.touchPoints>0&&this.touchPoints--,this.touchPoints===0&&this.isDragging&&this._currentMarker!==void 0&&this._currentMarker.pointerUp(this.clientToLocalCoordinates(te.clientX,te.clientY)),this.isDragging=!1,this.addUndoStep()},ae.prototype.onPointerOut=function(){this.touchPoints>0&&this.touchPoints--},ae.prototype.onKeyUp=function(te){this._currentMarker===void 0||this.notesArea!==void 0||te.key!=="Delete"&&te.key!=="Backspace"||this.deleteSelectedMarker()},ae.prototype.clientToLocalCoordinates=function(te,ee){var oe=this.markerImage.getBoundingClientRect();return{x:(te-oe.left)/this.zoomLevel,y:(ee-oe.top)/this.zoomLevel}},ae.prototype.onWindowResize=function(){this.positionUI()},ae.prototype.positionUI=function(){switch(this.setTopLeft(),this.settings.displayMode){case"inline":var te=this.target.getClientRects().item(0).y>this.styles.settings.toolbarHeight?this.target.offsetTop-this.styles.settings.toolbarHeight:0;this.coverDiv.style.top=te+"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=this.windowHeight-2*this.settings.popupMargin-3.5*this.styles.settings.toolbarHeight+"px"}this.positionMarkerImage(),this.positionLogo()},ae.prototype.addLicenseKey=function(te){Me.addKey(te)},ae.prototype.addEventListener=function(te,ee){this.eventListeners.addEventListener(te,ee)},ae.prototype.removeEventListener=function(te,ee){this.eventListeners.removeEventListener(te,ee)},ae.prototype.renderState=function(te){this._silentRenderMode=!0,this.settings.displayMode="inline",this.isOpen||this.show(),this.restoreState(te),this.startRenderAndClose(),this._silentRenderMode=!1},Object.defineProperty(ae.prototype,"isFocused",{get:function(){return this._isFocused},enumerable:!1,configurable:!0}),ae.prototype.focus=function(){var te=this;this._isFocused||(this.attachWindowEvents(),this._isFocused=!0,this._previousCurrentMarker!==void 0&&this.setCurrentMarker(this._previousCurrentMarker),this.eventListeners.focus.forEach(function(ee){return ee(new kt(te))}))},ae.prototype.blur=function(){var te=this;this._isFocused&&(this.detachWindowEvents(),this._isFocused=!1,this._previousCurrentMarker=this._currentMarker,this.setCurrentMarker(),this.eventListeners.blur.forEach(function(ee){return ee(new kt(te))}))},ae.instanceCounter=0,ae}()},6551:function(ln,Ft,ie){"use strict";ie.d(Ft,{ZP:function(){return Me}});var z=ie(42978),Ke=ie(59301),ve=ie(47273),Ae=0,ye=(0,ve.Z)();function be(){var Re;return ye?(Re=Ae,Ae+=1):Re="TEST_OR_SSR",Re}function Me(Re){var Oe=Ke.useState(),fe=(0,z.Z)(Oe,2),We=fe[0],Se=fe[1];return Ke.useEffect(function(){Se("rc_select_".concat(be()))},[]),Re||We}},37463:function(ln,Ft,ie){"use strict";ie.d(Ft,{Ac:function(){return ft},Xo:function(){return Tt},Wx:function(){return yn},ZP:function(){return fr},lk:function(){return Bt}});var z=ie(54476),Ke=ie(94480),ve=ie(20068),Ae=ie(33885),ye=ie(42978),be=ie(75931),Me=ie(76190),Re=ie(18929),Oe=ie(48736),fe=ie(59301),We=ie(92310),Se=ie.n(We),yt=ie(34280),Xe=ie(49658),Le=ie(8654),Ge=function(_e){var Ce=_e.className,Be=_e.customizeIcon,we=_e.customizeIconProps,Te=_e.children,Qe=_e.onMouseDown,nn=_e.onClick,sn=typeof Be=="function"?Be(we):Be;return fe.createElement("span",{className:Ce,onMouseDown:function(Ht){Ht.preventDefault(),Qe==null||Qe(Ht)},style:{userSelect:"none",WebkitUserSelect:"none"},unselectable:"on",onClick:nn,"aria-hidden":!0},sn!==void 0?sn:fe.createElement("span",{className:Se()(Ce.split(/\s+/).map(function(Xt){return"".concat(Xt,"-icon")}))},Te))},Ne=Ge,dt=function(_e,Ce,Be,we,Te){var Qe=arguments.length>5&&arguments[5]!==void 0?arguments[5]:!1,nn=arguments.length>6?arguments[6]:void 0,sn=arguments.length>7?arguments[7]:void 0,Xt=fe.useMemo(function(){if((0,Me.Z)(we)==="object")return we.clearIcon;if(Te)return Te},[we,Te]),Ht=fe.useMemo(function(){return!!(!Qe&&we&&(Be.length||nn)&&!(sn==="combobox"&&nn===""))},[we,Qe,Be.length,nn,sn]);return{allowClear:Ht,clearIcon:fe.createElement(Ne,{className:"".concat(_e,"-clear"),onMouseDown:Ce,customizeIcon:Xt},"\xD7")}},It=fe.createContext(null);function Bt(){return fe.useContext(It)}function mt(){var ke=arguments.length>0&&arguments[0]!==void 0?arguments[0]:10,_e=fe.useState(!1),Ce=(0,ye.Z)(_e,2),Be=Ce[0],we=Ce[1],Te=fe.useRef(null),Qe=function(){window.clearTimeout(Te.current)};fe.useEffect(function(){return Qe},[]);var nn=function(Xt,Ht){Qe(),Te.current=window.setTimeout(function(){we(Xt),Ht&&Ht()},ke)};return[Be,nn,Qe]}function st(){var ke=arguments.length>0&&arguments[0]!==void 0?arguments[0]:250,_e=fe.useRef(null),Ce=fe.useRef(null);fe.useEffect(function(){return function(){window.clearTimeout(Ce.current)}},[]);function Be(we){(we||_e.current===null)&&(_e.current=we),window.clearTimeout(Ce.current),Ce.current=window.setTimeout(function(){_e.current=null},ke)}return[function(){return _e.current},Be]}function it(ke,_e,Ce,Be){var we=fe.useRef(null);we.current={open:_e,triggerOpen:Ce,customizedTrigger:Be},fe.useEffect(function(){function Te(Qe){var nn;if(!((nn=we.current)!==null&&nn!==void 0&&nn.customizedTrigger)){var sn=Qe.target;sn.shadowRoot&&Qe.composed&&(sn=Qe.composedPath()[0]||sn),we.current.open&&ke().filter(function(Xt){return Xt}).every(function(Xt){return!Xt.contains(sn)&&Xt!==sn})&&we.current.triggerOpen(!1)}}return window.addEventListener("mousedown",Te),function(){return window.removeEventListener("mousedown",Te)}},[])}var je=ie(10228);function Ot(ke){return ke&&![je.Z.ESC,je.Z.SHIFT,je.Z.BACKSPACE,je.Z.TAB,je.Z.WIN_KEY,je.Z.ALT,je.Z.META,je.Z.WIN_KEY_RIGHT,je.Z.CTRL,je.Z.SEMICOLON,je.Z.EQUALS,je.Z.CAPS_LOCK,je.Z.CONTEXT_MENU,je.Z.F1,je.Z.F2,je.Z.F3,je.Z.F4,je.Z.F5,je.Z.F6,je.Z.F7,je.Z.F8,je.Z.F9,je.Z.F10,je.Z.F11,je.Z.F12].includes(ke)}var nt=ie(26112),tt=ie(83836);function ht(ke,_e,Ce){var Be=(0,Ae.Z)((0,Ae.Z)({},ke),Ce?_e:{});return Object.keys(_e).forEach(function(we){var Te=_e[we];typeof Te=="function"&&(Be[we]=function(){for(var Qe,nn=arguments.length,sn=new Array(nn),Xt=0;Xt<nn;Xt++)sn[Xt]=arguments[Xt];return Te.apply(void 0,sn),(Qe=ke[we])===null||Qe===void 0?void 0:Qe.call.apply(Qe,[ke].concat(sn))})}),Be}var $e=ht,at=["prefixCls","id","inputElement","autoFocus","autoComplete","editable","activeDescendantId","value","open","attrs"],lt=function(_e,Ce){var Be=_e.prefixCls,we=_e.id,Te=_e.inputElement,Qe=_e.autoFocus,nn=_e.autoComplete,sn=_e.editable,Xt=_e.activeDescendantId,Ht=_e.value,Ct=_e.open,pt=_e.attrs,un=(0,be.Z)(_e,at),$n=Te||fe.createElement("input",null),Dn=$n,kn=Dn.ref,pr=Dn.props;return(0,Oe.Kp)(!("maxLength"in $n.props),"Passing 'maxLength' to input element directly may not work because input in BaseSelect is controlled."),$n=fe.cloneElement($n,(0,Ae.Z)((0,Ae.Z)((0,Ae.Z)({type:"search"},$e(un,pr,!0)),{},{id:we,ref:(0,Le.sQ)(Ce,kn),autoComplete:nn||"off",autoFocus:Qe,className:Se()("".concat(Be,"-selection-search-input"),pr==null?void 0:pr.className),role:"combobox","aria-expanded":Ct||!1,"aria-haspopup":"listbox","aria-owns":"".concat(we,"_list"),"aria-autocomplete":"list","aria-controls":"".concat(we,"_list"),"aria-activedescendant":Ct?Xt:void 0},pt),{},{value:sn?Ht:"",readOnly:!sn,unselectable:sn?null:"on",style:(0,Ae.Z)((0,Ae.Z)({},pr.style),{},{opacity:sn?null:0})})),$n},me=fe.forwardRef(lt),At=me;function De(ke){return Array.isArray(ke)?ke:ke!==void 0?[ke]:[]}var He=typeof window!="undefined"&&window.document&&window.document.documentElement,Pt=He;function ge(ke){return ke!=null}function ce(ke){return!ke&&ke!==0}function Je(ke){return["string","number"].includes((0,Me.Z)(ke))}function jt(ke){var _e=void 0;return ke&&(Je(ke.title)?_e=ke.title.toString():Je(ke.label)&&(_e=ke.label.toString())),_e}function wt(ke,_e){Pt?fe.useLayoutEffect(ke,_e):fe.useEffect(ke,_e)}function Ie(ke){var _e;return(_e=ke.key)!==null&&_e!==void 0?_e:ke.value}var Ue=function(_e){_e.preventDefault(),_e.stopPropagation()},et=function(_e){var Ce=_e.id,Be=_e.prefixCls,we=_e.values,Te=_e.open,Qe=_e.searchValue,nn=_e.autoClearSearchValue,sn=_e.inputRef,Xt=_e.placeholder,Ht=_e.disabled,Ct=_e.mode,pt=_e.showSearch,un=_e.autoFocus,$n=_e.autoComplete,Dn=_e.activeDescendantId,kn=_e.tabIndex,pr=_e.removeIcon,gt=_e.maxTagCount,Ve=_e.maxTagTextLength,Et=_e.maxTagPlaceholder,Rt=Et===void 0?function(pn){return"+ ".concat(pn.length," ...")}:Et,Zt=_e.tagRender,hn=_e.onToggleOpen,Hn=_e.onRemove,Sn=_e.onInputChange,Tn=_e.onInputPaste,An=_e.onInputKeyDown,jn=_e.onInputMouseDown,Pn=_e.onInputCompositionStart,lr=_e.onInputCompositionEnd,Jn=_e.onInputBlur,Kn=fe.useRef(null),sr=(0,fe.useState)(0),mr=(0,ye.Z)(sr,2),Qn=mr[0],cr=mr[1],Gn=(0,fe.useState)(!1),vr=(0,ye.Z)(Gn,2),qn=vr[0],Sr=vr[1],ar="".concat(Be,"-selection"),or=Te||Ct==="multiple"&&nn===!1||Ct==="tags"?Qe:"",hr=Ct==="tags"||Ct==="multiple"&&nn===!1||pt&&(Te||qn);wt(function(){cr(Kn.current.scrollWidth)},[or]);var xr=function(Jt,zn,_n,an,dn){return fe.createElement("span",{title:jt(Jt),className:Se()("".concat(ar,"-item"),(0,ve.Z)({},"".concat(ar,"-item-disabled"),_n))},fe.createElement("span",{className:"".concat(ar,"-item-content")},zn),an&&fe.createElement(Ne,{className:"".concat(ar,"-item-remove"),onMouseDown:Ue,onClick:dn,customizeIcon:pr},"\xD7"))},br=function(Jt,zn,_n,an,dn,Nn){var Ln=function(Mr){Ue(Mr),hn(!Te)};return fe.createElement("span",{onMouseDown:Ln},Zt({label:zn,value:Jt,disabled:_n,closable:an,onClose:dn,isMaxTag:!!Nn}))},dr=function(Jt){var zn=Jt.disabled,_n=Jt.label,an=Jt.value,dn=!Ht&&!zn,Nn=_n;if(typeof Ve=="number"&&(typeof _n=="string"||typeof _n=="number")){var Ln=String(Nn);Ln.length>Ve&&(Nn="".concat(Ln.slice(0,Ve),"..."))}var yr=function(Cr){Cr&&Cr.stopPropagation(),Hn(Jt)};return typeof Zt=="function"?br(an,Nn,zn,dn,yr):xr(Jt,Nn,zn,dn,yr)},er=function(Jt){if(!we.length)return null;var zn=typeof Rt=="function"?Rt(Jt):Rt;return typeof Zt=="function"?br(void 0,zn,!1,!1,void 0,!0):xr({title:zn},zn,!1)},tn=fe.createElement("div",{className:"".concat(ar,"-search"),style:{width:Qn},onFocus:function(){Sr(!0)},onBlur:function(){Sr(!1)}},fe.createElement(At,{ref:sn,open:Te,prefixCls:Be,id:Ce,inputElement:null,disabled:Ht,autoFocus:un,autoComplete:$n,editable:hr,activeDescendantId:Dn,value:or,onKeyDown:An,onMouseDown:jn,onChange:Sn,onPaste:Tn,onCompositionStart:Pn,onCompositionEnd:lr,onBlur:Jn,tabIndex:kn,attrs:(0,nt.Z)(_e,!0)}),fe.createElement("span",{ref:Kn,className:"".concat(ar,"-search-mirror"),"aria-hidden":!0},or,"\xA0")),fn=fe.createElement(tt.Z,{prefixCls:"".concat(ar,"-overflow"),data:we,renderItem:dr,renderRest:er,suffix:tn,itemKey:Ie,maxCount:gt});return fe.createElement("span",{className:"".concat(ar,"-wrap")},fn,!we.length&&!or&&fe.createElement("span",{className:"".concat(ar,"-placeholder")},Xt))},cn=et,kt=function(_e){var Ce=_e.inputElement,Be=_e.prefixCls,we=_e.id,Te=_e.inputRef,Qe=_e.disabled,nn=_e.autoFocus,sn=_e.autoComplete,Xt=_e.activeDescendantId,Ht=_e.mode,Ct=_e.open,pt=_e.values,un=_e.placeholder,$n=_e.tabIndex,Dn=_e.showSearch,kn=_e.searchValue,pr=_e.activeValue,gt=_e.maxLength,Ve=_e.onInputKeyDown,Et=_e.onInputMouseDown,Rt=_e.onInputChange,Zt=_e.onInputPaste,hn=_e.onInputCompositionStart,Hn=_e.onInputCompositionEnd,Sn=_e.onInputBlur,Tn=_e.title,An=fe.useState(!1),jn=(0,ye.Z)(An,2),Pn=jn[0],lr=jn[1],Jn=Ht==="combobox",Kn=Jn||Dn,sr=pt[0],mr=kn||"";Jn&&pr&&!Pn&&(mr=pr),fe.useEffect(function(){Jn&&lr(!1)},[Jn,pr]);var Qn=Ht!=="combobox"&&!Ct&&!Dn?!1:!!mr,cr=Tn===void 0?jt(sr):Tn,Gn=fe.useMemo(function(){return sr?null:fe.createElement("span",{className:"".concat(Be,"-selection-placeholder"),style:Qn?{visibility:"hidden"}:void 0},un)},[sr,Qn,un,Be]);return fe.createElement("span",{className:"".concat(Be,"-selection-wrap")},fe.createElement("span",{className:"".concat(Be,"-selection-search")},fe.createElement(At,{ref:Te,prefixCls:Be,id:we,open:Ct,inputElement:Ce,disabled:Qe,autoFocus:nn,autoComplete:sn,editable:Kn,activeDescendantId:Xt,value:mr,onKeyDown:Ve,onMouseDown:Et,onChange:function(qn){lr(!0),Rt(qn)},onPaste:Zt,onCompositionStart:hn,onCompositionEnd:Hn,onBlur:Sn,tabIndex:$n,attrs:(0,nt.Z)(_e,!0),maxLength:Jn?gt:void 0})),!Jn&&sr?fe.createElement("span",{className:"".concat(Be,"-selection-item"),title:cr,style:Qn?{visibility:"hidden"}:void 0},sr.label):null,Gn)},Yt=kt,ze=function(_e,Ce){var Be=(0,fe.useRef)(null),we=(0,fe.useRef)(!1),Te=_e.prefixCls,Qe=_e.open,nn=_e.mode,sn=_e.showSearch,Xt=_e.tokenWithEnter,Ht=_e.disabled,Ct=_e.prefix,pt=_e.autoClearSearchValue,un=_e.onSearch,$n=_e.onSearchSubmit,Dn=_e.onToggleOpen,kn=_e.onInputKeyDown,pr=_e.onInputBlur,gt=_e.domRef;fe.useImperativeHandle(Ce,function(){return{focus:function(cr){Be.current.focus(cr)},blur:function(){Be.current.blur()}}});var Ve=st(0),Et=(0,ye.Z)(Ve,2),Rt=Et[0],Zt=Et[1],hn=function(cr){var Gn=cr.which,vr=Be.current instanceof HTMLTextAreaElement;!vr&&Qe&&(Gn===je.Z.UP||Gn===je.Z.DOWN)&&cr.preventDefault(),kn&&kn(cr),Gn===je.Z.ENTER&&nn==="tags"&&!we.current&&!Qe&&($n==null||$n(cr.target.value)),!(vr&&!Qe&&~[je.Z.UP,je.Z.DOWN,je.Z.LEFT,je.Z.RIGHT].indexOf(Gn))&&Ot(Gn)&&Dn(!0)},Hn=function(){Zt(!0)},Sn=(0,fe.useRef)(null),Tn=function(cr){un(cr,!0,we.current)!==!1&&Dn(!0)},An=function(){we.current=!0},jn=function(cr){we.current=!1,nn!=="combobox"&&Tn(cr.target.value)},Pn=function(cr){var Gn=cr.target.value;if(Xt&&Sn.current&&/[\r\n]/.test(Sn.current)){var vr=Sn.current.replace(/[\r\n]+$/,"").replace(/\r\n/g," ").replace(/[\r\n]/g," ");Gn=Gn.replace(vr,Sn.current)}Sn.current=null,Tn(Gn)},lr=function(cr){var Gn=cr.clipboardData,vr=Gn==null?void 0:Gn.getData("text");Sn.current=vr||""},Jn=function(cr){var Gn=cr.target;if(Gn!==Be.current){var vr=document.body.style.msTouchAction!==void 0;vr?setTimeout(function(){Be.current.focus()}):Be.current.focus()}},Kn=function(cr){var Gn=Rt();cr.target!==Be.current&&!Gn&&!(nn==="combobox"&&Ht)&&cr.preventDefault(),(nn!=="combobox"&&(!sn||!Gn)||!Qe)&&(Qe&&pt!==!1&&un("",!0,!1),Dn())},sr={inputRef:Be,onInputKeyDown:hn,onInputMouseDown:Hn,onInputChange:Pn,onInputPaste:lr,onInputCompositionStart:An,onInputCompositionEnd:jn,onInputBlur:pr},mr=nn==="multiple"||nn==="tags"?fe.createElement(cn,(0,z.Z)({},_e,sr)):fe.createElement(Yt,(0,z.Z)({},_e,sr));return fe.createElement("div",{ref:gt,className:"".concat(Te,"-selector"),onClick:Jn,onMouseDown:Kn},Ct&&fe.createElement("div",{className:"".concat(Te,"-prefix")},Ct),mr)},zt=fe.forwardRef(ze),ut=zt,ae=ie(65030),te=["prefixCls","disabled","visible","children","popupElement","animation","transitionName","dropdownStyle","dropdownClassName","direction","placement","builtinPlacements","dropdownMatchSelectWidth","dropdownRender","dropdownAlign","getPopupContainer","empty","getTriggerDOMNode","onPopupVisibleChange","onPopupMouseEnter"],ee=function(_e){var Ce=_e===!0?0:1;return{bottomLeft:{points:["tl","bl"],offset:[0,4],overflow:{adjustX:Ce,adjustY:1},htmlRegion:"scroll"},bottomRight:{points:["tr","br"],offset:[0,4],overflow:{adjustX:Ce,adjustY:1},htmlRegion:"scroll"},topLeft:{points:["bl","tl"],offset:[0,-4],overflow:{adjustX:Ce,adjustY:1},htmlRegion:"scroll"},topRight:{points:["br","tr"],offset:[0,-4],overflow:{adjustX:Ce,adjustY:1},htmlRegion:"scroll"}}},oe=function(_e,Ce){var Be=_e.prefixCls,we=_e.disabled,Te=_e.visible,Qe=_e.children,nn=_e.popupElement,sn=_e.animation,Xt=_e.transitionName,Ht=_e.dropdownStyle,Ct=_e.dropdownClassName,pt=_e.direction,un=pt===void 0?"ltr":pt,$n=_e.placement,Dn=_e.builtinPlacements,kn=_e.dropdownMatchSelectWidth,pr=_e.dropdownRender,gt=_e.dropdownAlign,Ve=_e.getPopupContainer,Et=_e.empty,Rt=_e.getTriggerDOMNode,Zt=_e.onPopupVisibleChange,hn=_e.onPopupMouseEnter,Hn=(0,be.Z)(_e,te),Sn="".concat(Be,"-dropdown"),Tn=nn;pr&&(Tn=pr(nn));var An=fe.useMemo(function(){return Dn||ee(kn)},[Dn,kn]),jn=sn?"".concat(Sn,"-").concat(sn):Xt,Pn=typeof kn=="number",lr=fe.useMemo(function(){return Pn?null:kn===!1?"minWidth":"width"},[kn,Pn]),Jn=Ht;Pn&&(Jn=(0,Ae.Z)((0,Ae.Z)({},Jn),{},{width:kn}));var Kn=fe.useRef(null);return fe.useImperativeHandle(Ce,function(){return{getPopupElement:function(){var mr;return(mr=Kn.current)===null||mr===void 0?void 0:mr.popupElement}}}),fe.createElement(ae.Z,(0,z.Z)({},Hn,{showAction:Zt?["click"]:[],hideAction:Zt?["click"]:[],popupPlacement:$n||(un==="rtl"?"bottomRight":"bottomLeft"),builtinPlacements:An,prefixCls:Sn,popupTransitionName:jn,popup:fe.createElement("div",{onMouseEnter:hn},Tn),ref:Kn,stretch:lr,popupAlign:gt,popupVisible:Te,getPopupContainer:Ve,popupClassName:Se()(Ct,(0,ve.Z)({},"".concat(Sn,"-empty"),Et)),popupStyle:Jn,getTriggerDOMNode:Rt,onPopupVisibleChange:Zt}),Qe)},se=fe.forwardRef(oe),ne=se,he=ie(66712);function xe(ke,_e){var Ce=ke.key,Be;return"value"in ke&&(Be=ke.value),Ce!=null?Ce:Be!==void 0?Be:"rc-index-key-".concat(_e)}function ot(ke){return typeof ke!="undefined"&&!Number.isNaN(ke)}function Ee(ke,_e){var Ce=ke||{},Be=Ce.label,we=Ce.value,Te=Ce.options,Qe=Ce.groupLabel,nn=Be||(_e?"children":"label");return{label:nn,value:we||"value",options:Te||"options",groupLabel:Qe||nn}}function Fe(ke){var _e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},Ce=_e.fieldNames,Be=_e.childrenAsData,we=[],Te=Ee(Ce,!1),Qe=Te.label,nn=Te.value,sn=Te.options,Xt=Te.groupLabel;function Ht(Ct,pt){Array.isArray(Ct)&&Ct.forEach(function(un){if(pt||!(sn in un)){var $n=un[nn];we.push({key:xe(un,we.length),groupOption:pt,data:un,label:un[Qe],value:$n})}else{var Dn=un[Xt];Dn===void 0&&Be&&(Dn=un.label),we.push({key:xe(un,we.length),group:!0,data:un,label:Dn}),Ht(un[sn],!0)}})}return Ht(ke,!1),we}function qe(ke){var _e=(0,Ae.Z)({},ke);return"props"in _e||Object.defineProperty(_e,"props",{get:function(){return(0,Oe.ZP)(!1,"Return type is option instead of Option instance. Please read value directly instead of reading from `props`."),_e}}),_e}var bt=function(_e,Ce,Be){if(!Ce||!Ce.length)return null;var we=!1,Te=function nn(sn,Xt){var Ht=(0,he.Z)(Xt),Ct=Ht[0],pt=Ht.slice(1);if(!Ct)return[sn];var un=sn.split(Ct);return we=we||un.length>1,un.reduce(function($n,Dn){return[].concat((0,Ke.Z)($n),(0,Ke.Z)(nn(Dn,pt)))},[]).filter(Boolean)},Qe=Te(_e,Ce);return we?typeof Be!="undefined"?Qe.slice(0,Be):Qe:null},ct=fe.createContext(null),Kt=ct;function Wt(ke){var _e=ke.visible,Ce=ke.values;if(!_e)return null;var Be=50;return fe.createElement("span",{"aria-live":"polite",style:{width:0,height:0,position:"absolute",overflow:"hidden",opacity:0}},"".concat(Ce.slice(0,Be).map(function(we){var Te=we.label,Qe=we.value;return["number","string"].includes((0,Me.Z)(Te))?Te:Qe}).join(", ")),Ce.length>Be?", ...":null)}var Nt=["id","prefixCls","className","showSearch","tagRender","direction","omitDomProps","displayValues","onDisplayValuesChange","emptyOptions","notFoundContent","onClear","mode","disabled","loading","getInputElement","getRawInputElement","open","defaultOpen","onDropdownVisibleChange","activeValue","onActiveValueChange","activeDescendantId","searchValue","autoClearSearchValue","onSearch","onSearchSplit","tokenSeparators","allowClear","prefix","suffixIcon","clearIcon","OptionList","animation","transitionName","dropdownStyle","dropdownClassName","dropdownMatchSelectWidth","dropdownRender","dropdownAlign","placement","builtinPlacements","getPopupContainer","showAction","onFocus","onBlur","onKeyUp","onKeyDown","onMouseDown"],rn=["value","onChange","removeIcon","placeholder","autoFocus","maxTagCount","maxTagTextLength","maxTagPlaceholder","choiceTransitionName","onInputKeyDown","onPopupScroll","tabIndex"],qt=function(_e){return _e==="tags"||_e==="multiple"},on=fe.forwardRef(function(ke,_e){var Ce,Be=ke.id,we=ke.prefixCls,Te=ke.className,Qe=ke.showSearch,nn=ke.tagRender,sn=ke.direction,Xt=ke.omitDomProps,Ht=ke.displayValues,Ct=ke.onDisplayValuesChange,pt=ke.emptyOptions,un=ke.notFoundContent,$n=un===void 0?"Not Found":un,Dn=ke.onClear,kn=ke.mode,pr=ke.disabled,gt=ke.loading,Ve=ke.getInputElement,Et=ke.getRawInputElement,Rt=ke.open,Zt=ke.defaultOpen,hn=ke.onDropdownVisibleChange,Hn=ke.activeValue,Sn=ke.onActiveValueChange,Tn=ke.activeDescendantId,An=ke.searchValue,jn=ke.autoClearSearchValue,Pn=ke.onSearch,lr=ke.onSearchSplit,Jn=ke.tokenSeparators,Kn=ke.allowClear,sr=ke.prefix,mr=ke.suffixIcon,Qn=ke.clearIcon,cr=ke.OptionList,Gn=ke.animation,vr=ke.transitionName,qn=ke.dropdownStyle,Sr=ke.dropdownClassName,ar=ke.dropdownMatchSelectWidth,or=ke.dropdownRender,hr=ke.dropdownAlign,xr=ke.placement,br=ke.builtinPlacements,dr=ke.getPopupContainer,er=ke.showAction,tn=er===void 0?[]:er,fn=ke.onFocus,pn=ke.onBlur,Jt=ke.onKeyUp,zn=ke.onKeyDown,_n=ke.onMouseDown,an=(0,be.Z)(ke,Nt),dn=qt(kn),Nn=(Qe!==void 0?Qe:dn)||kn==="combobox",Ln=(0,Ae.Z)({},an);rn.forEach(function(Zr){delete Ln[Zr]}),Xt==null||Xt.forEach(function(Zr){delete Ln[Zr]});var yr=fe.useState(!1),Mr=(0,ye.Z)(yr,2),Cr=Mr[0],Ar=Mr[1];fe.useEffect(function(){Ar((0,Xe.Z)())},[]);var Tr=fe.useRef(null),Lr=fe.useRef(null),Dr=fe.useRef(null),Nr=fe.useRef(null),Fr=fe.useRef(null),Gr=fe.useRef(!1),Qr=mt(),ri=(0,ye.Z)(Qr,3),Wr=ri[0],jr=ri[1],Ur=ri[2];fe.useImperativeHandle(_e,function(){var Zr,Rr;return{focus:(Zr=Nr.current)===null||Zr===void 0?void 0:Zr.focus,blur:(Rr=Nr.current)===null||Rr===void 0?void 0:Rr.blur,scrollTo:function(Mi){var oi;return(oi=Fr.current)===null||oi===void 0?void 0:oi.scrollTo(Mi)},nativeElement:Tr.current||Lr.current}});var kr=fe.useMemo(function(){var Zr;if(kn!=="combobox")return An;var Rr=(Zr=Ht[0])===null||Zr===void 0?void 0:Zr.value;return typeof Rr=="string"||typeof Rr=="number"?String(Rr):""},[An,kn,Ht]),Jr=kn==="combobox"&&typeof Ve=="function"&&Ve()||null,Xr=typeof Et=="function"&&Et(),li=(0,Le.x1)(Lr,Xr==null||(Ce=Xr.props)===null||Ce===void 0?void 0:Ce.ref),Ci=fe.useState(!1),fi=(0,ye.Z)(Ci,2),hi=fi[0],Ii=fi[1];(0,yt.Z)(function(){Ii(!0)},[]);var _r=(0,Re.Z)(!1,{defaultValue:Zt,value:Rt}),si=(0,ye.Z)(_r,2),Oi=si[0],ki=si[1],qr=hi?Oi:!1,Ui=!$n&&pt;(pr||Ui&&qr&&kn==="combobox")&&(qr=!1);var to=Ui?!1:qr,wr=fe.useCallback(function(Zr){var Rr=Zr!==void 0?Zr:!qr;pr||(ki(Rr),qr!==Rr&&(hn==null||hn(Rr)))},[pr,qr,ki,hn]),Br=fe.useMemo(function(){return(Jn||[]).some(function(Zr){return[`
|
|
|
`,`\r
|
|
|
`].includes(Zr)})},[Jn]),Or=fe.useContext(Kt)||{},Pr=Or.maxCount,Hr=Or.rawValues,$r=function(Rr,Si,Mi){if(!(dn&&ot(Pr)&&(Hr==null?void 0:Hr.size)>=Pr)){var oi=!0,mi=Rr;Sn==null||Sn(null);var Ji=bt(Rr,Jn,ot(Pr)?Pr-Hr.size:void 0),Xi=Mi?null:Ji;return kn!=="combobox"&&Xi&&(mi="",lr==null||lr(Xi),wr(!1),oi=!1),Pn&&kr!==mi&&Pn(mi,{source:Si?"typing":"effect"}),oi}},pi=function(Rr){!Rr||!Rr.trim()||Pn(Rr,{source:"submit"})};fe.useEffect(function(){!qr&&!dn&&kn!=="combobox"&&$r("",!1,!1)},[qr]),fe.useEffect(function(){Oi&&pr&&ki(!1),pr&&!Gr.current&&jr(!1)},[pr]);var ui=st(),wi=(0,ye.Z)(ui,2),ii=wi[0],_i=wi[1],no=fe.useRef(!1),$i=function(Rr){var Si=ii(),Mi=Rr.key,oi=Mi==="Enter";if(oi&&(kn!=="combobox"&&Rr.preventDefault(),qr||wr(!0)),_i(!!kr),Mi==="Backspace"&&!Si&&dn&&!kr&&Ht.length){for(var mi=(0,Ke.Z)(Ht),Ji=null,Xi=mi.length-1;Xi>=0;Xi-=1){var lo=mi[Xi];if(!lo.disabled){mi.splice(Xi,1),Ji=lo;break}}Ji&&Ct(mi,{type:"remove",values:[Ji]})}for(var Hi=arguments.length,Zi=new Array(Hi>1?Hi-1:0),Qi=1;Qi<Hi;Qi++)Zi[Qi-1]=arguments[Qi];if(qr&&(!oi||!no.current)){var fo;oi&&(no.current=!0),(fo=Fr.current)===null||fo===void 0||fo.onKeyDown.apply(fo,[Rr].concat(Zi))}zn==null||zn.apply(void 0,[Rr].concat(Zi))},ro=function(Rr){for(var Si=arguments.length,Mi=new Array(Si>1?Si-1:0),oi=1;oi<Si;oi++)Mi[oi-1]=arguments[oi];if(qr){var mi;(mi=Fr.current)===null||mi===void 0||mi.onKeyUp.apply(mi,[Rr].concat(Mi))}Rr.key==="Enter"&&(no.current=!1),Jt==null||Jt.apply(void 0,[Rr].concat(Mi))},ao=function(Rr){var Si=Ht.filter(function(Mi){return Mi!==Rr});Ct(Si,{type:"remove",values:[Rr]})},Yi=function(){no.current=!1},ko=fe.useRef(!1),Ga=function(){jr(!0),pr||(fn&&!ko.current&&fn.apply(void 0,arguments),tn.includes("focus")&&wr(!0)),ko.current=!0},ya=function(){Gr.current=!0,jr(!1,function(){ko.current=!1,Gr.current=!1,wr(!1)}),!pr&&(kr&&(kn==="tags"?Pn(kr,{source:"submit"}):kn==="multiple"&&Pn("",{source:"blur"})),pn&&pn.apply(void 0,arguments))},io=[];fe.useEffect(function(){return function(){io.forEach(function(Zr){return clearTimeout(Zr)}),io.splice(0,io.length)}},[]);var co=function(Rr){var Si,Mi=Rr.target,oi=(Si=Dr.current)===null||Si===void 0?void 0:Si.getPopupElement();if(oi&&oi.contains(Mi)){var mi=setTimeout(function(){var Hi=io.indexOf(mi);if(Hi!==-1&&io.splice(Hi,1),Ur(),!Cr&&!oi.contains(document.activeElement)){var Zi;(Zi=Nr.current)===null||Zi===void 0||Zi.focus()}});io.push(mi)}for(var Ji=arguments.length,Xi=new Array(Ji>1?Ji-1:0),lo=1;lo<Ji;lo++)Xi[lo-1]=arguments[lo];_n==null||_n.apply(void 0,[Rr].concat(Xi))},Ki=fe.useState({}),ba=(0,ye.Z)(Ki,2),xa=ba[1];function Va(){xa({})}var Ca;Xr&&(Ca=function(Rr){wr(Rr)}),it(function(){var Zr;return[Tr.current,(Zr=Dr.current)===null||Zr===void 0?void 0:Zr.getPopupElement()]},to,wr,!!Xr);var Ua=fe.useMemo(function(){return(0,Ae.Z)((0,Ae.Z)({},ke),{},{notFoundContent:$n,open:qr,triggerOpen:to,id:Be,showSearch:Nn,multiple:dn,toggleOpen:wr})},[ke,$n,to,qr,Be,Nn,dn,wr]),_o=!!mr||gt,Ko;_o&&(Ko=fe.createElement(Ne,{className:Se()("".concat(we,"-arrow"),(0,ve.Z)({},"".concat(we,"-arrow-loading"),gt)),customizeIcon:mr,customizeIconProps:{loading:gt,searchValue:kr,open:qr,focused:Wr,showSearch:Nn}}));var Co=function(){var Rr;Dn==null||Dn(),(Rr=Nr.current)===null||Rr===void 0||Rr.focus(),Ct([],{type:"clear",values:Ht}),$r("",!1,!1)},Xo=dt(we,Co,Ht,Kn,Qn,pr,kr,kn),wa=Xo.allowClear,Yo=Xo.clearIcon,To=fe.createElement(cr,{ref:Fr}),Sa=Se()(we,Te,(0,ve.Z)((0,ve.Z)((0,ve.Z)((0,ve.Z)((0,ve.Z)((0,ve.Z)((0,ve.Z)((0,ve.Z)((0,ve.Z)((0,ve.Z)({},"".concat(we,"-focused"),Wr),"".concat(we,"-multiple"),dn),"".concat(we,"-single"),!dn),"".concat(we,"-allow-clear"),Kn),"".concat(we,"-show-arrow"),_o),"".concat(we,"-disabled"),pr),"".concat(we,"-loading"),gt),"".concat(we,"-open"),qr),"".concat(we,"-customize-input"),Jr),"".concat(we,"-show-search"),Nn)),Lo=fe.createElement(ne,{ref:Dr,disabled:pr,prefixCls:we,visible:to,popupElement:To,animation:Gn,transitionName:vr,dropdownStyle:qn,dropdownClassName:Sr,direction:sn,dropdownMatchSelectWidth:ar,dropdownRender:or,dropdownAlign:hr,placement:xr,builtinPlacements:br,getPopupContainer:dr,empty:pt,getTriggerDOMNode:function(Rr){return Lr.current||Rr},onPopupVisibleChange:Ca,onPopupMouseEnter:Va},Xr?fe.cloneElement(Xr,{ref:li}):fe.createElement(ut,(0,z.Z)({},ke,{domRef:Lr,prefixCls:we,inputElement:Jr,ref:Nr,id:Be,prefix:sr,showSearch:Nn,autoClearSearchValue:jn,mode:kn,activeDescendantId:Tn,tagRender:nn,values:Ht,open:qr,onToggleOpen:wr,activeValue:Hn,searchValue:kr,onSearch:$r,onSearchSubmit:pi,onRemove:ao,tokenWithEnter:Br,onInputBlur:Yi}))),Bi;return Xr?Bi=Lo:Bi=fe.createElement("div",(0,z.Z)({className:Sa},Ln,{ref:Tr,onMouseDown:co,onKeyDown:$i,onKeyUp:ro,onFocus:Ga,onBlur:ya}),fe.createElement(Wt,{visible:Wr&&!qr,values:Ht}),Lo,Ko,wa&&Yo),fe.createElement(It.Provider,{value:Ua},Bi)}),ft=on,Gt=function(){return null};Gt.isSelectOptGroup=!0;var Tt=Gt,en=function(){return null};en.isSelectOption=!0;var yn=en,Rn=ie(80547),On=ie(2738),Pe=ie(48911);function rt(){return/(mac\sos|macintosh)/i.test(navigator.appVersion)}var St=["disabled","title","children","style","className"];function _t(ke){return typeof ke=="string"||typeof ke=="number"}var bn=function(_e,Ce){var Be=Bt(),we=Be.prefixCls,Te=Be.id,Qe=Be.open,nn=Be.multiple,sn=Be.mode,Xt=Be.searchValue,Ht=Be.toggleOpen,Ct=Be.notFoundContent,pt=Be.onPopupScroll,un=fe.useContext(Kt),$n=un.maxCount,Dn=un.flattenOptions,kn=un.onActiveValue,pr=un.defaultActiveFirstOption,gt=un.onSelect,Ve=un.menuItemSelectedIcon,Et=un.rawValues,Rt=un.fieldNames,Zt=un.virtual,hn=un.direction,Hn=un.listHeight,Sn=un.listItemHeight,Tn=un.optionRender,An="".concat(we,"-item"),jn=(0,Rn.Z)(function(){return Dn},[Qe,Dn],function(er,tn){return tn[0]&&er[1]!==tn[1]}),Pn=fe.useRef(null),lr=fe.useMemo(function(){return nn&&ot($n)&&(Et==null?void 0:Et.size)>=$n},[nn,$n,Et==null?void 0:Et.size]),Jn=function(tn){tn.preventDefault()},Kn=function(tn){var fn;(fn=Pn.current)===null||fn===void 0||fn.scrollTo(typeof tn=="number"?{index:tn}:tn)},sr=fe.useCallback(function(er){return sn==="combobox"?!1:Et.has(er)},[sn,(0,Ke.Z)(Et).toString(),Et.size]),mr=function(tn){for(var fn=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1,pn=jn.length,Jt=0;Jt<pn;Jt+=1){var zn=(tn+Jt*fn+pn)%pn,_n=jn[zn]||{},an=_n.group,dn=_n.data;if(!an&&!(dn!=null&&dn.disabled)&&(sr(dn.value)||!lr))return zn}return-1},Qn=fe.useState(function(){return mr(0)}),cr=(0,ye.Z)(Qn,2),Gn=cr[0],vr=cr[1],qn=function(tn){var fn=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;vr(tn);var pn={source:fn?"keyboard":"mouse"},Jt=jn[tn];if(!Jt){kn(null,-1,pn);return}kn(Jt.value,tn,pn)};(0,fe.useEffect)(function(){qn(pr!==!1?mr(0):-1)},[jn.length,Xt]);var Sr=fe.useCallback(function(er){return sn==="combobox"?String(er).toLowerCase()===Xt.toLowerCase():Et.has(er)},[sn,Xt,(0,Ke.Z)(Et).toString(),Et.size]);(0,fe.useEffect)(function(){var er=setTimeout(function(){if(!nn&&Qe&&Et.size===1){var fn=Array.from(Et)[0],pn=jn.findIndex(function(Jt){var zn=Jt.data;return Xt?String(zn.value).startsWith(Xt):zn.value===fn});pn!==-1&&(qn(pn),Kn(pn))}});if(Qe){var tn;(tn=Pn.current)===null||tn===void 0||tn.scrollTo(void 0)}return function(){return clearTimeout(er)}},[Qe,Xt]);var ar=function(tn){tn!==void 0&>(tn,{selected:!Et.has(tn)}),nn||Ht(!1)};if(fe.useImperativeHandle(Ce,function(){return{onKeyDown:function(tn){var fn=tn.which,pn=tn.ctrlKey;switch(fn){case je.Z.N:case je.Z.P:case je.Z.UP:case je.Z.DOWN:{var Jt=0;if(fn===je.Z.UP?Jt=-1:fn===je.Z.DOWN?Jt=1:rt()&&pn&&(fn===je.Z.N?Jt=1:fn===je.Z.P&&(Jt=-1)),Jt!==0){var zn=mr(Gn+Jt,Jt);Kn(zn),qn(zn,!0)}break}case je.Z.TAB:case je.Z.ENTER:{var _n,an=jn[Gn];an&&!(an!=null&&(_n=an.data)!==null&&_n!==void 0&&_n.disabled)&&!lr?ar(an.value):ar(void 0),Qe&&tn.preventDefault();break}case je.Z.ESC:Ht(!1),Qe&&tn.stopPropagation()}},onKeyUp:function(){},scrollTo:function(tn){Kn(tn)}}}),jn.length===0)return fe.createElement("div",{role:"listbox",id:"".concat(Te,"_list"),className:"".concat(An,"-empty"),onMouseDown:Jn},Ct);var or=Object.keys(Rt).map(function(er){return Rt[er]}),hr=function(tn){return tn.label};function xr(er,tn){var fn=er.group;return{role:fn?"presentation":"option",id:"".concat(Te,"_list_").concat(tn)}}var br=function(tn){var fn=jn[tn];if(!fn)return null;var pn=fn.data||{},Jt=pn.value,zn=fn.group,_n=(0,nt.Z)(pn,!0),an=hr(fn);return fn?fe.createElement("div",(0,z.Z)({"aria-label":typeof an=="string"&&!zn?an:null},_n,{key:tn},xr(fn,tn),{"aria-selected":Sr(Jt)}),Jt):null},dr={role:"listbox",id:"".concat(Te,"_list")};return fe.createElement(fe.Fragment,null,Zt&&fe.createElement("div",(0,z.Z)({},dr,{style:{height:0,width:0,overflow:"hidden"}}),br(Gn-1),br(Gn),br(Gn+1)),fe.createElement(Pe.Z,{itemKey:"key",ref:Pn,data:jn,height:Hn,itemHeight:Sn,fullHeight:!1,onMouseDown:Jn,onScroll:pt,virtual:Zt,direction:hn,innerProps:Zt?null:dr},function(er,tn){var fn=er.group,pn=er.groupOption,Jt=er.data,zn=er.label,_n=er.value,an=Jt.key;if(fn){var dn,Nn=(dn=Jt.title)!==null&&dn!==void 0?dn:_t(zn)?zn.toString():void 0;return fe.createElement("div",{className:Se()(An,"".concat(An,"-group"),Jt.className),title:Nn},zn!==void 0?zn:an)}var Ln=Jt.disabled,yr=Jt.title,Mr=Jt.children,Cr=Jt.style,Ar=Jt.className,Tr=(0,be.Z)(Jt,St),Lr=(0,On.Z)(Tr,or),Dr=sr(_n),Nr=Ln||!Dr&&lr,Fr="".concat(An,"-option"),Gr=Se()(An,Fr,Ar,(0,ve.Z)((0,ve.Z)((0,ve.Z)((0,ve.Z)({},"".concat(Fr,"-grouped"),pn),"".concat(Fr,"-active"),Gn===tn&&!Nr),"".concat(Fr,"-disabled"),Nr),"".concat(Fr,"-selected"),Dr)),Qr=hr(er),ri=!Ve||typeof Ve=="function"||Dr,Wr=typeof Qr=="number"?Qr:Qr||_n,jr=_t(Wr)?Wr.toString():void 0;return yr!==void 0&&(jr=yr),fe.createElement("div",(0,z.Z)({},(0,nt.Z)(Lr),Zt?{}:xr(er,tn),{"aria-selected":Sr(_n),className:Gr,title:jr,onMouseMove:function(){Gn===tn||Nr||qn(tn)},onClick:function(){Nr||ar(_n)},style:Cr}),fe.createElement("div",{className:"".concat(Fr,"-content")},typeof Tn=="function"?Tn(er,{index:tn}):Wr),fe.isValidElement(Ve)||Dr,ri&&fe.createElement(Ne,{className:"".concat(An,"-option-state"),customizeIcon:Ve,customizeIconProps:{value:_n,disabled:Nr,isSelected:Dr}},Dr?"\u2713":null))}))},In=fe.forwardRef(bn),rr=In,Xn=function(ke,_e){var Ce=fe.useRef({values:new Map,options:new Map}),Be=fe.useMemo(function(){var Te=Ce.current,Qe=Te.values,nn=Te.options,sn=ke.map(function(Ct){if(Ct.label===void 0){var pt;return(0,Ae.Z)((0,Ae.Z)({},Ct),{},{label:(pt=Qe.get(Ct.value))===null||pt===void 0?void 0:pt.label})}return Ct}),Xt=new Map,Ht=new Map;return sn.forEach(function(Ct){Xt.set(Ct.value,Ct),Ht.set(Ct.value,_e.get(Ct.value)||nn.get(Ct.value))}),Ce.current.values=Xt,Ce.current.options=Ht,sn},[ke,_e]),we=fe.useCallback(function(Te){return _e.get(Te)||Ce.current.options.get(Te)},[_e]);return[Be,we]};function Cn(ke,_e){return De(ke).join("").toUpperCase().includes(_e)}var Fn=function(ke,_e,Ce,Be,we){return fe.useMemo(function(){if(!Ce||Be===!1)return ke;var Te=_e.options,Qe=_e.label,nn=_e.value,sn=[],Xt=typeof Be=="function",Ht=Ce.toUpperCase(),Ct=Xt?Be:function(un,$n){return we?Cn($n[we],Ht):$n[Te]?Cn($n[Qe!=="children"?Qe:"label"],Ht):Cn($n[nn],Ht)},pt=Xt?function(un){return qe(un)}:function(un){return un};return ke.forEach(function(un){if(un[Te]){var $n=Ct(Ce,pt(un));if($n)sn.push(un);else{var Dn=un[Te].filter(function(kn){return Ct(Ce,pt(kn))});Dn.length&&sn.push((0,Ae.Z)((0,Ae.Z)({},un),{},(0,ve.Z)({},Te,Dn)))}return}Ct(Ce,pt(un))&&sn.push(un)}),sn},[ke,Be,we,Ce,_e])},xt=ie(6551),$t=ie(11592),vt=["children","value"],Vt=["children"];function Ut(ke){var _e=ke,Ce=_e.key,Be=_e.props,we=Be.children,Te=Be.value,Qe=(0,be.Z)(Be,vt);return(0,Ae.Z)({key:Ce,value:Te!==void 0?Te:Ce,children:we},Qe)}function En(ke){var _e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;return(0,$t.Z)(ke).map(function(Ce,Be){if(!fe.isValidElement(Ce)||!Ce.type)return null;var we=Ce,Te=we.type.isSelectOptGroup,Qe=we.key,nn=we.props,sn=nn.children,Xt=(0,be.Z)(nn,Vt);return _e||!Te?Ut(Ce):(0,Ae.Z)((0,Ae.Z)({key:"__RC_SELECT_GRP__".concat(Qe===null?Be:Qe,"__"),label:Qe},Xt),{},{options:En(sn)})}).filter(function(Ce){return Ce})}var mn=function(_e,Ce,Be,we,Te){return fe.useMemo(function(){var Qe=_e,nn=!_e;nn&&(Qe=En(Ce));var sn=new Map,Xt=new Map,Ht=function(un,$n,Dn){Dn&&typeof Dn=="string"&&un.set($n[Dn],$n)},Ct=function pt(un){for(var $n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,Dn=0;Dn<un.length;Dn+=1){var kn=un[Dn];!kn[Be.options]||$n?(sn.set(kn[Be.value],kn),Ht(Xt,kn,Be.label),Ht(Xt,kn,we),Ht(Xt,kn,Te)):pt(kn[Be.options],!0)}};return Ct(Qe),{options:Qe,valueOptions:sn,labelOptions:Xt}},[_e,Ce,Be,we,Te])},xn=mn;function wn(ke){var _e=fe.useRef();_e.current=ke;var Ce=fe.useCallback(function(){return _e.current.apply(_e,arguments)},[]);return Ce}function Bn(ke){var _e=ke.mode,Ce=ke.options,Be=ke.children,we=ke.backfill,Te=ke.allowClear,Qe=ke.placeholder,nn=ke.getInputElement,sn=ke.showSearch,Xt=ke.onSearch,Ht=ke.defaultOpen,Ct=ke.autoFocus,pt=ke.labelInValue,un=ke.value,$n=ke.inputValue,Dn=ke.optionLabelProp,kn=isMultiple(_e),pr=sn!==void 0?sn:kn||_e==="combobox",gt=Ce||convertChildrenToData(Be);if(warning(_e!=="tags"||gt.every(function(Zt){return!Zt.disabled}),"Please avoid setting option to disabled in tags mode since user can always type text as tag."),_e==="tags"||_e==="combobox"){var Ve=gt.some(function(Zt){return Zt.options?Zt.options.some(function(hn){return typeof("value"in hn?hn.value:hn.key)=="number"}):typeof("value"in Zt?Zt.value:Zt.key)=="number"});warning(!Ve,"`value` of Option should not use number type when `mode` is `tags` or `combobox`.")}if(warning(_e!=="combobox"||!Dn,"`combobox` mode not support `optionLabelProp`. Please set `value` on Option directly."),warning(_e==="combobox"||!we,"`backfill` only works with `combobox` mode."),warning(_e==="combobox"||!nn,"`getInputElement` only work with `combobox` mode."),noteOnce(_e!=="combobox"||!nn||!Te||!Qe,"Customize `getInputElement` should customize clear and placeholder logic instead of configuring `allowClear` and `placeholder`."),Xt&&!pr&&_e!=="combobox"&&_e!=="tags"&&warning(!1,"`onSearch` should work with `showSearch` instead of use alone."),noteOnce(!Ht||Ct,"`defaultOpen` makes Select open without focus which means it will not close by click outside. You can set `autoFocus` if needed."),un!=null){var Et=toArray(un);warning(!pt||Et.every(function(Zt){return _typeof(Zt)==="object"&&("key"in Zt||"value"in Zt)}),"`value` should in shape of `{ value: string | number, label?: ReactNode }` when you set `labelInValue` to `true`"),warning(!kn||Array.isArray(un),"`value` should be array when `mode` is `multiple` or `tags`")}if(Be){var Rt=null;toNodeArray(Be).some(function(Zt){if(!React.isValidElement(Zt)||!Zt.type)return!1;var hn=Zt,Hn=hn.type;if(Hn.isSelectOption)return!1;if(Hn.isSelectOptGroup){var Sn=toNodeArray(Zt.props.children).every(function(Tn){return!React.isValidElement(Tn)||!Zt.type||Tn.type.isSelectOption?!0:(Rt=Tn.type,!1)});return!Sn}return Rt=Hn,!0}),Rt&&warning(!1,"`children` should be `Select.Option` or `Select.OptGroup` instead of `".concat(Rt.displayName||Rt.name||Rt,"`.")),warning($n===void 0,"`inputValue` is deprecated, please use `searchValue` instead.")}}function Zn(ke,_e){if(ke){var Ce=function Be(we){for(var Te=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,Qe=0;Qe<we.length;Qe++){var nn=we[Qe];if(nn[_e==null?void 0:_e.value]===null)return warning(!1,"`value` in Select options should not be `null`."),!0;if(!Te&&Array.isArray(nn[_e==null?void 0:_e.options])&&Be(nn[_e==null?void 0:_e.options],!0))break}};Ce(ke)}}var Yn=null,Wn=["id","mode","prefixCls","backfill","fieldNames","inputValue","searchValue","onSearch","autoClearSearchValue","onSelect","onDeselect","dropdownMatchSelectWidth","filterOption","filterSort","optionFilterProp","optionLabelProp","options","optionRender","children","defaultActiveFirstOption","menuItemSelectedIcon","virtual","direction","listHeight","listItemHeight","labelRender","value","defaultValue","labelInValue","onChange","maxCount"],ir=["inputValue"];function gn(ke){return!ke||(0,Me.Z)(ke)!=="object"}var Dt=fe.forwardRef(function(ke,_e){var Ce=ke.id,Be=ke.mode,we=ke.prefixCls,Te=we===void 0?"rc-select":we,Qe=ke.backfill,nn=ke.fieldNames,sn=ke.inputValue,Xt=ke.searchValue,Ht=ke.onSearch,Ct=ke.autoClearSearchValue,pt=Ct===void 0?!0:Ct,un=ke.onSelect,$n=ke.onDeselect,Dn=ke.dropdownMatchSelectWidth,kn=Dn===void 0?!0:Dn,pr=ke.filterOption,gt=ke.filterSort,Ve=ke.optionFilterProp,Et=ke.optionLabelProp,Rt=ke.options,Zt=ke.optionRender,hn=ke.children,Hn=ke.defaultActiveFirstOption,Sn=ke.menuItemSelectedIcon,Tn=ke.virtual,An=ke.direction,jn=ke.listHeight,Pn=jn===void 0?200:jn,lr=ke.listItemHeight,Jn=lr===void 0?20:lr,Kn=ke.labelRender,sr=ke.value,mr=ke.defaultValue,Qn=ke.labelInValue,cr=ke.onChange,Gn=ke.maxCount,vr=(0,be.Z)(ke,Wn),qn=(0,xt.ZP)(Ce),Sr=qt(Be),ar=!!(!Rt&&hn),or=fe.useMemo(function(){return pr===void 0&&Be==="combobox"?!1:pr},[pr,Be]),hr=fe.useMemo(function(){return Ee(nn,ar)},[JSON.stringify(nn),ar]),xr=(0,Re.Z)("",{value:Xt!==void 0?Xt:sn,postState:function(Br){return Br||""}}),br=(0,ye.Z)(xr,2),dr=br[0],er=br[1],tn=xn(Rt,hn,hr,Ve,Et),fn=tn.valueOptions,pn=tn.labelOptions,Jt=tn.options,zn=fe.useCallback(function(wr){var Br=De(wr);return Br.map(function(Or){var Pr,Hr,$r,pi,ui;if(gn(Or))Pr=Or;else{var wi;$r=Or.key,Hr=Or.label,Pr=(wi=Or.value)!==null&&wi!==void 0?wi:$r}var ii=fn.get(Pr);if(ii){var _i;if(Hr===void 0&&(Hr=ii==null?void 0:ii[Et||hr.label]),$r===void 0&&($r=(_i=ii==null?void 0:ii.key)!==null&&_i!==void 0?_i:Pr),pi=ii==null?void 0:ii.disabled,ui=ii==null?void 0:ii.title,0)var no}return{label:Hr,value:Pr,key:$r,disabled:pi,title:ui}})},[hr,Et,fn]),_n=(0,Re.Z)(mr,{value:sr}),an=(0,ye.Z)(_n,2),dn=an[0],Nn=an[1],Ln=fe.useMemo(function(){var wr,Br=Sr&&dn===null?[]:dn,Or=zn(Br);return Be==="combobox"&&ce((wr=Or[0])===null||wr===void 0?void 0:wr.value)?[]:Or},[dn,zn,Be,Sr]),yr=Xn(Ln,fn),Mr=(0,ye.Z)(yr,2),Cr=Mr[0],Ar=Mr[1],Tr=fe.useMemo(function(){if(!Be&&Cr.length===1){var wr=Cr[0];if(wr.value===null&&(wr.label===null||wr.label===void 0))return[]}return Cr.map(function(Br){var Or;return(0,Ae.Z)((0,Ae.Z)({},Br),{},{label:(Or=typeof Kn=="function"?Kn(Br):Br.label)!==null&&Or!==void 0?Or:Br.value})})},[Be,Cr,Kn]),Lr=fe.useMemo(function(){return new Set(Cr.map(function(wr){return wr.value}))},[Cr]);fe.useEffect(function(){if(Be==="combobox"){var wr,Br=(wr=Cr[0])===null||wr===void 0?void 0:wr.value;er(ge(Br)?String(Br):"")}},[Cr]);var Dr=wn(function(wr,Br){var Or=Br!=null?Br:wr;return(0,ve.Z)((0,ve.Z)({},hr.value,wr),hr.label,Or)}),Nr=fe.useMemo(function(){if(Be!=="tags")return Jt;var wr=(0,Ke.Z)(Jt),Br=function(Pr){return fn.has(Pr)};return(0,Ke.Z)(Cr).sort(function(Or,Pr){return Or.value<Pr.value?-1:1}).forEach(function(Or){var Pr=Or.value;Br(Pr)||wr.push(Dr(Pr,Or.label))}),wr},[Dr,Jt,fn,Cr,Be]),Fr=Fn(Nr,hr,dr,or,Ve),Gr=fe.useMemo(function(){return Be!=="tags"||!dr||Fr.some(function(wr){return wr[Ve||"value"]===dr})||Fr.some(function(wr){return wr[hr.value]===dr})?Fr:[Dr(dr)].concat((0,Ke.Z)(Fr))},[Dr,Ve,Be,Fr,dr,hr]),Qr=function wr(Br){var Or=(0,Ke.Z)(Br).sort(function(Pr,Hr){return gt(Pr,Hr,{searchValue:dr})});return Or.map(function(Pr){return Array.isArray(Pr.options)?(0,Ae.Z)((0,Ae.Z)({},Pr),{},{options:Pr.options.length>0?wr(Pr.options):Pr.options}):Pr})},ri=fe.useMemo(function(){return gt?Qr(Gr):Gr},[Gr,gt,dr]),Wr=fe.useMemo(function(){return Fe(ri,{fieldNames:hr,childrenAsData:ar})},[ri,hr,ar]),jr=function(Br){var Or=zn(Br);if(Nn(Or),cr&&(Or.length!==Cr.length||Or.some(function($r,pi){var ui;return((ui=Cr[pi])===null||ui===void 0?void 0:ui.value)!==($r==null?void 0:$r.value)}))){var Pr=Qn?Or:Or.map(function($r){return $r.value}),Hr=Or.map(function($r){return qe(Ar($r.value))});cr(Sr?Pr:Pr[0],Sr?Hr:Hr[0])}},Ur=fe.useState(null),kr=(0,ye.Z)(Ur,2),Jr=kr[0],Xr=kr[1],li=fe.useState(0),Ci=(0,ye.Z)(li,2),fi=Ci[0],hi=Ci[1],Ii=Hn!==void 0?Hn:Be!=="combobox",_r=fe.useCallback(function(wr,Br){var Or=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},Pr=Or.source,Hr=Pr===void 0?"keyboard":Pr;hi(Br),Qe&&Be==="combobox"&&wr!==null&&Hr==="keyboard"&&Xr(String(wr))},[Qe,Be]),si=function(Br,Or,Pr){var Hr=function(){var ao,Yi=Ar(Br);return[Qn?{label:Yi==null?void 0:Yi[hr.label],value:Br,key:(ao=Yi==null?void 0:Yi.key)!==null&&ao!==void 0?ao:Br}:Br,qe(Yi)]};if(Or&&un){var $r=Hr(),pi=(0,ye.Z)($r,2),ui=pi[0],wi=pi[1];un(ui,wi)}else if(!Or&&$n&&Pr!=="clear"){var ii=Hr(),_i=(0,ye.Z)(ii,2),no=_i[0],$i=_i[1];$n(no,$i)}},Oi=wn(function(wr,Br){var Or,Pr=Sr?Br.selected:!0;Pr?Or=Sr?[].concat((0,Ke.Z)(Cr),[wr]):[wr]:Or=Cr.filter(function(Hr){return Hr.value!==wr}),jr(Or),si(wr,Pr),Be==="combobox"?Xr(""):(!qt||pt)&&(er(""),Xr(""))}),ki=function(Br,Or){jr(Br);var Pr=Or.type,Hr=Or.values;(Pr==="remove"||Pr==="clear")&&Hr.forEach(function($r){si($r.value,!1,Pr)})},qr=function(Br,Or){if(er(Br),Xr(null),Or.source==="submit"){var Pr=(Br||"").trim();if(Pr){var Hr=Array.from(new Set([].concat((0,Ke.Z)(Lr),[Pr])));jr(Hr),si(Pr,!0),er("")}return}Or.source!=="blur"&&(Be==="combobox"&&jr(Br),Ht==null||Ht(Br))},Ui=function(Br){var Or=Br;Be!=="tags"&&(Or=Br.map(function(Hr){var $r=pn.get(Hr);return $r==null?void 0:$r.value}).filter(function(Hr){return Hr!==void 0}));var Pr=Array.from(new Set([].concat((0,Ke.Z)(Lr),(0,Ke.Z)(Or))));jr(Pr),Pr.forEach(function(Hr){si(Hr,!0)})},to=fe.useMemo(function(){var wr=Tn!==!1&&kn!==!1;return(0,Ae.Z)((0,Ae.Z)({},tn),{},{flattenOptions:Wr,onActiveValue:_r,defaultActiveFirstOption:Ii,onSelect:Oi,menuItemSelectedIcon:Sn,rawValues:Lr,fieldNames:hr,virtual:wr,direction:An,listHeight:Pn,listItemHeight:Jn,childrenAsData:ar,maxCount:Gn,optionRender:Zt})},[Gn,tn,Wr,_r,Ii,Oi,Sn,Lr,hr,Tn,kn,An,Pn,Jn,ar,Zt]);return fe.createElement(Kt.Provider,{value:to},fe.createElement(ft,(0,z.Z)({},vr,{id:qn,prefixCls:Te,ref:_e,omitDomProps:ir,mode:Be,displayValues:Tr,onDisplayValuesChange:ki,direction:An,searchValue:dr,onSearch:qr,autoClearSearchValue:pt,onSearchSplit:Ui,dropdownMatchSelectWidth:kn,OptionList:rr,emptyOptions:!Wr.length,activeValue:Jr,activeDescendantId:"".concat(qn,"_list_").concat(fi)})))}),Qt=Dt;Qt.Option=yn,Qt.OptGroup=Tt;var Un=Qt,fr=Un},22711:function(ln,Ft,ie){"use strict";ie.r(Ft),ie.d(Ft,{ResizableTextArea:function(){return $e},default:function(){return At}});var z=ie(54476),Ke=ie(20068),ve=ie(33885),Ae=ie(94480),ye=ie(42978),be=ie(75931),Me=ie(92310),Re=ie.n(Me),Oe=ie(36901),fe=ie(66003),We=ie(30292),Se=ie(18929),yt=ie(59301),Xe=ie(76190),Le=ie(29301),Ge=ie(34280),Ne=ie(16089),dt=`
|
|
|
min-height:0 !important;
|
|
|
max-height:none !important;
|
|
|
height:0 !important;
|
|
|
visibility:hidden !important;
|
|
|
overflow:hidden !important;
|
|
|
position:absolute !important;
|
|
|
z-index:-1000 !important;
|
|
|
top:0 !important;
|
|
|
right:0 !important;
|
|
|
pointer-events: none !important;
|
|
|
`,It=["letter-spacing","line-height","padding-top","padding-bottom","font-family","font-weight","font-size","font-variant","text-rendering","text-transform","width","text-indent","padding-left","padding-right","border-width","box-sizing","word-break","white-space"],Bt={},mt;function st(De){var He=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,Pt=De.getAttribute("id")||De.getAttribute("data-reactid")||De.getAttribute("name");if(He&&Bt[Pt])return Bt[Pt];var ge=window.getComputedStyle(De),ce=ge.getPropertyValue("box-sizing")||ge.getPropertyValue("-moz-box-sizing")||ge.getPropertyValue("-webkit-box-sizing"),Je=parseFloat(ge.getPropertyValue("padding-bottom"))+parseFloat(ge.getPropertyValue("padding-top")),jt=parseFloat(ge.getPropertyValue("border-bottom-width"))+parseFloat(ge.getPropertyValue("border-top-width")),wt=It.map(function(Ue){return"".concat(Ue,":").concat(ge.getPropertyValue(Ue))}).join(";"),Ie={sizingStyle:wt,paddingSize:Je,borderSize:jt,boxSizing:ce};return He&&Pt&&(Bt[Pt]=Ie),Ie}function it(De){var He=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,Pt=arguments.length>2&&arguments[2]!==void 0?arguments[2]:null,ge=arguments.length>3&&arguments[3]!==void 0?arguments[3]:null;mt||(mt=document.createElement("textarea"),mt.setAttribute("tab-index","-1"),mt.setAttribute("aria-hidden","true"),mt.setAttribute("name","hiddenTextarea"),document.body.appendChild(mt)),De.getAttribute("wrap")?mt.setAttribute("wrap",De.getAttribute("wrap")):mt.removeAttribute("wrap");var ce=st(De,He),Je=ce.paddingSize,jt=ce.borderSize,wt=ce.boxSizing,Ie=ce.sizingStyle;mt.setAttribute("style","".concat(Ie,";").concat(dt)),mt.value=De.value||De.placeholder||"";var Ue=void 0,et=void 0,cn,kt=mt.scrollHeight;if(wt==="border-box"?kt+=jt:wt==="content-box"&&(kt-=Je),Pt!==null||ge!==null){mt.value=" ";var Yt=mt.scrollHeight-Je;Pt!==null&&(Ue=Yt*Pt,wt==="border-box"&&(Ue=Ue+Je+jt),kt=Math.max(Ue,kt)),ge!==null&&(et=Yt*ge,wt==="border-box"&&(et=et+Je+jt),cn=kt>et?"":"hidden",kt=Math.min(et,kt))}var ze={height:kt,overflowY:cn,resize:"none"};return Ue&&(ze.minHeight=Ue),et&&(ze.maxHeight=et),ze}var je=["prefixCls","defaultValue","value","autoSize","onResize","className","style","disabled","onChange","onInternalAutoSize"],Ot=0,nt=1,tt=2,ht=yt.forwardRef(function(De,He){var Pt=De,ge=Pt.prefixCls,ce=Pt.defaultValue,Je=Pt.value,jt=Pt.autoSize,wt=Pt.onResize,Ie=Pt.className,Ue=Pt.style,et=Pt.disabled,cn=Pt.onChange,kt=Pt.onInternalAutoSize,Yt=(0,be.Z)(Pt,je),ze=(0,Se.Z)(ce,{value:Je,postState:function(yn){return yn!=null?yn:""}}),zt=(0,ye.Z)(ze,2),ut=zt[0],ae=zt[1],te=function(yn){ae(yn.target.value),cn==null||cn(yn)},ee=yt.useRef();yt.useImperativeHandle(He,function(){return{textArea:ee.current}});var oe=yt.useMemo(function(){return jt&&(0,Xe.Z)(jt)==="object"?[jt.minRows,jt.maxRows]:[]},[jt]),se=(0,ye.Z)(oe,2),ne=se[0],he=se[1],xe=!!jt,ot=function(){try{if(document.activeElement===ee.current){var yn=ee.current,Rn=yn.selectionStart,On=yn.selectionEnd,Pe=yn.scrollTop;ee.current.setSelectionRange(Rn,On),ee.current.scrollTop=Pe}}catch(rt){}},Ee=yt.useState(tt),Fe=(0,ye.Z)(Ee,2),qe=Fe[0],bt=Fe[1],ct=yt.useState(),Kt=(0,ye.Z)(ct,2),Wt=Kt[0],Nt=Kt[1],rn=function(){bt(Ot)};(0,Ge.Z)(function(){xe&&rn()},[Je,ne,he,xe]),(0,Ge.Z)(function(){if(qe===Ot)bt(nt);else if(qe===nt){var en=it(ee.current,!1,ne,he);bt(tt),Nt(en)}else ot()},[qe]);var qt=yt.useRef(),on=function(){Ne.Z.cancel(qt.current)},ft=function(yn){qe===tt&&(wt==null||wt(yn),jt&&(on(),qt.current=(0,Ne.Z)(function(){rn()})))};yt.useEffect(function(){return on},[]);var Gt=xe?Wt:null,Tt=(0,ve.Z)((0,ve.Z)({},Ue),Gt);return(qe===Ot||qe===nt)&&(Tt.overflowY="hidden",Tt.overflowX="hidden"),yt.createElement(Le.Z,{onResize:ft,disabled:!(jt||wt)},yt.createElement("textarea",(0,z.Z)({},Yt,{ref:ee,style:Tt,className:Re()(ge,Ie,(0,Ke.Z)({},"".concat(ge,"-disabled"),et)),disabled:et,value:ut,onChange:te})))}),$e=ht,at=["defaultValue","value","onFocus","onBlur","onChange","allowClear","maxLength","onCompositionStart","onCompositionEnd","suffix","prefixCls","showCount","count","className","style","disabled","hidden","classNames","styles","onResize","onClear","onPressEnter","readOnly","autoSize","onKeyDown"],lt=yt.forwardRef(function(De,He){var Pt,ge=De.defaultValue,ce=De.value,Je=De.onFocus,jt=De.onBlur,wt=De.onChange,Ie=De.allowClear,Ue=De.maxLength,et=De.onCompositionStart,cn=De.onCompositionEnd,kt=De.suffix,Yt=De.prefixCls,ze=Yt===void 0?"rc-textarea":Yt,zt=De.showCount,ut=De.count,ae=De.className,te=De.style,ee=De.disabled,oe=De.hidden,se=De.classNames,ne=De.styles,he=De.onResize,xe=De.onClear,ot=De.onPressEnter,Ee=De.readOnly,Fe=De.autoSize,qe=De.onKeyDown,bt=(0,be.Z)(De,at),ct=(0,Se.Z)(ge,{value:ce,defaultValue:ge}),Kt=(0,ye.Z)(ct,2),Wt=Kt[0],Nt=Kt[1],rn=Wt==null?"":String(Wt),qt=yt.useState(!1),on=(0,ye.Z)(qt,2),ft=on[0],Gt=on[1],Tt=yt.useRef(!1),en=yt.useState(null),yn=(0,ye.Z)(en,2),Rn=yn[0],On=yn[1],Pe=(0,yt.useRef)(null),rt=(0,yt.useRef)(null),St=function(){var Qt;return(Qt=rt.current)===null||Qt===void 0?void 0:Qt.textArea},_t=function(){St().focus()};(0,yt.useImperativeHandle)(He,function(){var Dt;return{resizableTextArea:rt.current,focus:_t,blur:function(){St().blur()},nativeElement:((Dt=Pe.current)===null||Dt===void 0?void 0:Dt.nativeElement)||St()}}),(0,yt.useEffect)(function(){Gt(function(Dt){return!ee&&Dt})},[ee]);var bn=yt.useState(null),In=(0,ye.Z)(bn,2),rr=In[0],Xn=In[1];yt.useEffect(function(){if(rr){var Dt;(Dt=St()).setSelectionRange.apply(Dt,(0,Ae.Z)(rr))}},[rr]);var Cn=(0,fe.Z)(ut,zt),Fn=(Pt=Cn.max)!==null&&Pt!==void 0?Pt:Ue,xt=Number(Fn)>0,$t=Cn.strategy(rn),vt=!!Fn&&$t>Fn,Vt=function(Qt,Un){var fr=Un;!Tt.current&&Cn.exceedFormatter&&Cn.max&&Cn.strategy(Un)>Cn.max&&(fr=Cn.exceedFormatter(Un,{max:Cn.max}),Un!==fr&&Xn([St().selectionStart||0,St().selectionEnd||0])),Nt(fr),(0,We.rJ)(Qt.currentTarget,Qt,wt,fr)},Ut=function(Qt){Tt.current=!0,et==null||et(Qt)},En=function(Qt){Tt.current=!1,Vt(Qt,Qt.currentTarget.value),cn==null||cn(Qt)},mn=function(Qt){Vt(Qt,Qt.target.value)},xn=function(Qt){Qt.key==="Enter"&&ot&&ot(Qt),qe==null||qe(Qt)},wn=function(Qt){Gt(!0),Je==null||Je(Qt)},Bn=function(Qt){Gt(!1),jt==null||jt(Qt)},Zn=function(Qt){Nt(""),_t(),(0,We.rJ)(St(),Qt,wt)},Yn=kt,Wn;Cn.show&&(Cn.showFormatter?Wn=Cn.showFormatter({value:rn,count:$t,maxLength:Fn}):Wn="".concat($t).concat(xt?" / ".concat(Fn):""),Yn=yt.createElement(yt.Fragment,null,Yn,yt.createElement("span",{className:Re()("".concat(ze,"-data-count"),se==null?void 0:se.count),style:ne==null?void 0:ne.count},Wn)));var ir=function(Qt){var Un;he==null||he(Qt),(Un=St())!==null&&Un!==void 0&&Un.style.height&&On(!0)},gn=!Fe&&!zt&&!Ie;return yt.createElement(Oe.BaseInput,{ref:Pe,value:rn,allowClear:Ie,handleReset:Zn,suffix:Yn,prefixCls:ze,classNames:(0,ve.Z)((0,ve.Z)({},se),{},{affixWrapper:Re()(se==null?void 0:se.affixWrapper,(0,Ke.Z)((0,Ke.Z)({},"".concat(ze,"-show-count"),zt),"".concat(ze,"-textarea-allow-clear"),Ie))}),disabled:ee,focused:ft,className:Re()(ae,vt&&"".concat(ze,"-out-of-range")),style:(0,ve.Z)((0,ve.Z)({},te),Rn&&!gn?{height:"auto"}:{}),dataAttrs:{affixWrapper:{"data-count":typeof Wn=="string"?Wn:void 0}},hidden:oe,readOnly:Ee,onClear:xe},yt.createElement($e,(0,z.Z)({},bt,{autoSize:Fe,maxLength:Ue,onKeyDown:xn,onChange:mn,onFocus:wn,onBlur:Bn,onCompositionStart:Ut,onCompositionEnd:En,className:Re()(se==null?void 0:se.textarea),style:(0,ve.Z)((0,ve.Z)({},ne==null?void 0:ne.textarea),{},{resize:te==null?void 0:te.resize}),disabled:ee,prefixCls:ze,onResize:ir,ref:rt,readOnly:Ee})))}),me=lt,At=me},8224:function(ln,Ft,ie){"use strict";ie.d(Ft,{Z:function(){return Ke}});var z=ie(4676);function Ke(ve,Ae,ye,be){var Me=z.unstable_batchedUpdates?function(Oe){z.unstable_batchedUpdates(ye,Oe)}:ye;return ve!=null&&ve.addEventListener&&ve.addEventListener(Ae,Me,be),{remove:function(){ve!=null&&ve.removeEventListener&&ve.removeEventListener(Ae,Me,be)}}}},48911:function(ln,Ft,ie){"use strict";ie.d(Ft,{Z:function(){return ut}});var z=ie(54476),Ke=ie(76190),ve=ie(33885),Ae=ie(20068),ye=ie(42978),be=ie(75931),Me=ie(92310),Re=ie.n(Me),Oe=ie(29301),fe=ie(70425),We=ie(34280),Se=ie(59301),yt=ie(4676),Xe=Se.forwardRef(function(ae,te){var ee=ae.height,oe=ae.offsetY,se=ae.offsetX,ne=ae.children,he=ae.prefixCls,xe=ae.onInnerResize,ot=ae.innerProps,Ee=ae.rtl,Fe=ae.extra,qe={},bt={display:"flex",flexDirection:"column"};return oe!==void 0&&(qe={height:ee,position:"relative",overflow:"hidden"},bt=(0,ve.Z)((0,ve.Z)({},bt),{},(0,Ae.Z)((0,Ae.Z)((0,Ae.Z)((0,Ae.Z)((0,Ae.Z)({transform:"translateY(".concat(oe,"px)")},Ee?"marginRight":"marginLeft",-se),"position","absolute"),"left",0),"right",0),"top",0))),Se.createElement("div",{style:qe},Se.createElement(Oe.Z,{onResize:function(Kt){var Wt=Kt.offsetHeight;Wt&&xe&&xe()}},Se.createElement("div",(0,z.Z)({style:bt,className:Re()((0,Ae.Z)({},"".concat(he,"-holder-inner"),he)),ref:te},ot),ne,Fe)))});Xe.displayName="Filler";var Le=Xe;function Ge(ae){var te=ae.children,ee=ae.setRef,oe=Se.useCallback(function(se){ee(se)},[]);return Se.cloneElement(te,{ref:oe})}function Ne(ae,te,ee,oe,se,ne,he,xe){var ot=xe.getKey;return ae.slice(te,ee+1).map(function(Ee,Fe){var qe=te+Fe,bt=he(Ee,qe,{style:{width:oe},offsetX:se}),ct=ot(Ee);return Se.createElement(Ge,{key:ct,setRef:function(Wt){return ne(Ee,Wt)}},bt)})}function dt(ae,te,ee,oe){var se=ee-ae,ne=te-ee,he=Math.min(se,ne)*2;if(oe<=he){var xe=Math.floor(oe/2);return oe%2?ee+xe+1:ee-xe}return se>ne?ee-(oe-ne):ee+(oe-se)}function It(ae,te,ee){var oe=ae.length,se=te.length,ne,he;if(oe===0&&se===0)return null;oe<se?(ne=ae,he=te):(ne=te,he=ae);var xe={__EMPTY_ITEM__:!0};function ot(Kt){return Kt!==void 0?ee(Kt):xe}for(var Ee=null,Fe=Math.abs(oe-se)!==1,qe=0;qe<he.length;qe+=1){var bt=ot(ne[qe]),ct=ot(he[qe]);if(bt!==ct){Ee=qe,Fe=Fe||bt!==ot(he[qe+1]);break}}return Ee===null?null:{index:Ee,multiple:Fe}}function Bt(ae,te,ee){var oe=Se.useState(ae),se=(0,ye.Z)(oe,2),ne=se[0],he=se[1],xe=Se.useState(null),ot=(0,ye.Z)(xe,2),Ee=ot[0],Fe=ot[1];return Se.useEffect(function(){var qe=It(ne||[],ae||[],te);(qe==null?void 0:qe.index)!==void 0&&(ee==null||ee(qe.index),Fe(ae[qe.index])),he(ae)},[ae]),[Ee]}var mt=ie(16089),st=(typeof navigator=="undefined"?"undefined":(0,Ke.Z)(navigator))==="object"&&/Firefox/i.test(navigator.userAgent),it=st,je=function(ae,te,ee,oe){var se=(0,Se.useRef)(!1),ne=(0,Se.useRef)(null);function he(){clearTimeout(ne.current),se.current=!0,ne.current=setTimeout(function(){se.current=!1},50)}var xe=(0,Se.useRef)({top:ae,bottom:te,left:ee,right:oe});return xe.current.top=ae,xe.current.bottom=te,xe.current.left=ee,xe.current.right=oe,function(ot,Ee){var Fe=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,qe=ot?Ee<0&&xe.current.left||Ee>0&&xe.current.right:Ee<0&&xe.current.top||Ee>0&&xe.current.bottom;return Fe&&qe?(clearTimeout(ne.current),se.current=!1):(!qe||se.current)&&he(),!se.current&&qe}};function Ot(ae,te,ee,oe,se,ne,he){var xe=(0,Se.useRef)(0),ot=(0,Se.useRef)(null),Ee=(0,Se.useRef)(null),Fe=(0,Se.useRef)(!1),qe=je(te,ee,oe,se);function bt(qt,on){if(mt.Z.cancel(ot.current),!qe(!1,on)){var ft=qt;if(!ft._virtualHandled)ft._virtualHandled=!0;else return;xe.current+=on,Ee.current=on,it||ft.preventDefault(),ot.current=(0,mt.Z)(function(){var Gt=Fe.current?10:1;he(xe.current*Gt,!1),xe.current=0})}}function ct(qt,on){he(on,!0),it||qt.preventDefault()}var Kt=(0,Se.useRef)(null),Wt=(0,Se.useRef)(null);function Nt(qt){if(ae){mt.Z.cancel(Wt.current),Wt.current=(0,mt.Z)(function(){Kt.current=null},2);var on=qt.deltaX,ft=qt.deltaY,Gt=qt.shiftKey,Tt=on,en=ft;(Kt.current==="sx"||!Kt.current&&Gt&&ft&&!on)&&(Tt=ft,en=0,Kt.current="sx");var yn=Math.abs(Tt),Rn=Math.abs(en);Kt.current===null&&(Kt.current=ne&&yn>Rn?"x":"y"),Kt.current==="y"?bt(qt,en):ct(qt,Tt)}}function rn(qt){ae&&(Fe.current=qt.detail===Ee.current)}return[Nt,rn]}function nt(ae,te,ee,oe){var se=Se.useMemo(function(){return[new Map,[]]},[ae,ee.id,oe]),ne=(0,ye.Z)(se,2),he=ne[0],xe=ne[1],ot=function(Fe){var qe=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Fe,bt=he.get(Fe),ct=he.get(qe);if(bt===void 0||ct===void 0)for(var Kt=ae.length,Wt=xe.length;Wt<Kt;Wt+=1){var Nt,rn=ae[Wt],qt=te(rn);he.set(qt,Wt);var on=(Nt=ee.get(qt))!==null&&Nt!==void 0?Nt:oe;if(xe[Wt]=(xe[Wt-1]||0)+on,qt===Fe&&(bt=Wt),qt===qe&&(ct=Wt),bt!==void 0&&ct!==void 0)break}return{top:xe[bt-1]||0,bottom:xe[ct]}};return ot}var tt=ie(67732),ht=ie(83652),$e=function(){function ae(){(0,tt.Z)(this,ae),(0,Ae.Z)(this,"maps",void 0),(0,Ae.Z)(this,"id",0),(0,Ae.Z)(this,"diffRecords",new Map),this.maps=Object.create(null)}return(0,ht.Z)(ae,[{key:"set",value:function(ee,oe){this.diffRecords.set(ee,this.maps[ee]),this.maps[ee]=oe,this.id+=1}},{key:"get",value:function(ee){return this.maps[ee]}},{key:"resetRecord",value:function(){this.diffRecords.clear()}},{key:"getRecord",value:function(){return this.diffRecords}}]),ae}(),at=$e;function lt(ae){var te=parseFloat(ae);return isNaN(te)?0:te}function me(ae,te,ee){var oe=Se.useState(0),se=(0,ye.Z)(oe,2),ne=se[0],he=se[1],xe=(0,Se.useRef)(new Map),ot=(0,Se.useRef)(new at),Ee=(0,Se.useRef)(0);function Fe(){Ee.current+=1}function qe(){var ct=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1;Fe();var Kt=function(){var rn=!1;xe.current.forEach(function(qt,on){if(qt&&qt.offsetParent){var ft=qt.offsetHeight,Gt=getComputedStyle(qt),Tt=Gt.marginTop,en=Gt.marginBottom,yn=lt(Tt),Rn=lt(en),On=ft+yn+Rn;ot.current.get(on)!==On&&(ot.current.set(on,On),rn=!0)}}),rn&&he(function(qt){return qt+1})};if(ct)Kt();else{Ee.current+=1;var Wt=Ee.current;Promise.resolve().then(function(){Wt===Ee.current&&Kt()})}}function bt(ct,Kt){var Wt=ae(ct),Nt=xe.current.get(Wt);Kt?(xe.current.set(Wt,Kt),qe()):xe.current.delete(Wt),!Nt!=!Kt&&(Kt?te==null||te(ct):ee==null||ee(ct))}return(0,Se.useEffect)(function(){return Fe},[]),[bt,qe,ot.current,ne]}var At=14/15;function De(ae,te,ee){var oe=(0,Se.useRef)(!1),se=(0,Se.useRef)(0),ne=(0,Se.useRef)(0),he=(0,Se.useRef)(null),xe=(0,Se.useRef)(null),ot,Ee=function(ct){if(oe.current){var Kt=Math.ceil(ct.touches[0].pageX),Wt=Math.ceil(ct.touches[0].pageY),Nt=se.current-Kt,rn=ne.current-Wt,qt=Math.abs(Nt)>Math.abs(rn);qt?se.current=Kt:ne.current=Wt;var on=ee(qt,qt?Nt:rn,!1,ct);on&&ct.preventDefault(),clearInterval(xe.current),on&&(xe.current=setInterval(function(){qt?Nt*=At:rn*=At;var ft=Math.floor(qt?Nt:rn);(!ee(qt,ft,!0)||Math.abs(ft)<=.1)&&clearInterval(xe.current)},16))}},Fe=function(){oe.current=!1,ot()},qe=function(ct){ot(),ct.touches.length===1&&!oe.current&&(oe.current=!0,se.current=Math.ceil(ct.touches[0].pageX),ne.current=Math.ceil(ct.touches[0].pageY),he.current=ct.target,he.current.addEventListener("touchmove",Ee,{passive:!1}),he.current.addEventListener("touchend",Fe,{passive:!0}))};ot=function(){he.current&&(he.current.removeEventListener("touchmove",Ee),he.current.removeEventListener("touchend",Fe))},(0,We.Z)(function(){return ae&&te.current.addEventListener("touchstart",qe,{passive:!0}),function(){var bt;(bt=te.current)===null||bt===void 0||bt.removeEventListener("touchstart",qe),ot(),clearInterval(xe.current)}},[ae])}function He(ae){return Math.floor(Math.pow(ae,.5))}function Pt(ae,te){var ee="touches"in ae?ae.touches[0]:ae;return ee[te?"pageX":"pageY"]-window[te?"scrollX":"scrollY"]}function ge(ae,te,ee){Se.useEffect(function(){var oe=te.current;if(ae&&oe){var se=!1,ne,he,xe=function(){mt.Z.cancel(ne)},ot=function bt(){xe(),ne=(0,mt.Z)(function(){ee(he),bt()})},Ee=function(){se=!1,xe()},Fe=function(ct){if(!(ct.target.draggable||ct.button!==0)){var Kt=ct;Kt._virtualHandled||(Kt._virtualHandled=!0,se=!0)}},qe=function(ct){if(se){var Kt=Pt(ct,!1),Wt=oe.getBoundingClientRect(),Nt=Wt.top,rn=Wt.bottom;if(Kt<=Nt){var qt=Nt-Kt;he=-He(qt),ot()}else if(Kt>=rn){var on=Kt-rn;he=He(on),ot()}else xe()}};return oe.addEventListener("mousedown",Fe),oe.ownerDocument.addEventListener("mouseup",Ee),oe.ownerDocument.addEventListener("mousemove",qe),oe.ownerDocument.addEventListener("dragend",Ee),function(){oe.removeEventListener("mousedown",Fe),oe.ownerDocument.removeEventListener("mouseup",Ee),oe.ownerDocument.removeEventListener("mousemove",qe),oe.ownerDocument.removeEventListener("dragend",Ee),xe()}}},[ae])}var ce=10;function Je(ae,te,ee,oe,se,ne,he,xe){var ot=Se.useRef(),Ee=Se.useState(null),Fe=(0,ye.Z)(Ee,2),qe=Fe[0],bt=Fe[1];return(0,We.Z)(function(){if(qe&&qe.times<ce){if(!ae.current){bt(function(Cn){return(0,ve.Z)({},Cn)});return}ne();var ct=qe.targetAlign,Kt=qe.originAlign,Wt=qe.index,Nt=qe.offset,rn=ae.current.clientHeight,qt=!1,on=ct,ft=null;if(rn){for(var Gt=ct||Kt,Tt=0,en=0,yn=0,Rn=Math.min(te.length-1,Wt),On=0;On<=Rn;On+=1){var Pe=se(te[On]);en=Tt;var rt=ee.get(Pe);yn=en+(rt===void 0?oe:rt),Tt=yn}for(var St=Gt==="top"?Nt:rn-Nt,_t=Rn;_t>=0;_t-=1){var bn=se(te[_t]),In=ee.get(bn);if(In===void 0){qt=!0;break}if(St-=In,St<=0)break}switch(Gt){case"top":ft=en-Nt;break;case"bottom":ft=yn-rn+Nt;break;default:{var rr=ae.current.scrollTop,Xn=rr+rn;en<rr?on="top":yn>Xn&&(on="bottom")}}ft!==null&&he(ft),ft!==qe.lastTop&&(qt=!0)}qt&&bt((0,ve.Z)((0,ve.Z)({},qe),{},{times:qe.times+1,targetAlign:on,lastTop:ft}))}},[qe,ae.current]),function(ct){if(ct==null){xe();return}if(mt.Z.cancel(ot.current),typeof ct=="number")he(ct);else if(ct&&(0,Ke.Z)(ct)==="object"){var Kt,Wt=ct.align;"index"in ct?Kt=ct.index:Kt=te.findIndex(function(qt){return se(qt)===ct.key});var Nt=ct.offset,rn=Nt===void 0?0:Nt;bt({times:0,index:Kt,offset:rn,originAlign:Wt})}}}var jt=Se.forwardRef(function(ae,te){var ee=ae.prefixCls,oe=ae.rtl,se=ae.scrollOffset,ne=ae.scrollRange,he=ae.onStartMove,xe=ae.onStopMove,ot=ae.onScroll,Ee=ae.horizontal,Fe=ae.spinSize,qe=ae.containerSize,bt=ae.style,ct=ae.thumbStyle,Kt=ae.showScrollBar,Wt=Se.useState(!1),Nt=(0,ye.Z)(Wt,2),rn=Nt[0],qt=Nt[1],on=Se.useState(null),ft=(0,ye.Z)(on,2),Gt=ft[0],Tt=ft[1],en=Se.useState(null),yn=(0,ye.Z)(en,2),Rn=yn[0],On=yn[1],Pe=!oe,rt=Se.useRef(),St=Se.useRef(),_t=Se.useState(Kt),bn=(0,ye.Z)(_t,2),In=bn[0],rr=bn[1],Xn=Se.useRef(),Cn=function(){Kt===!0||Kt===!1||(clearTimeout(Xn.current),rr(!0),Xn.current=setTimeout(function(){rr(!1)},3e3))},Fn=ne-qe||0,xt=qe-Fe||0,$t=Se.useMemo(function(){if(se===0||Fn===0)return 0;var Zn=se/Fn;return Zn*xt},[se,Fn,xt]),vt=function(Yn){Yn.stopPropagation(),Yn.preventDefault()},Vt=Se.useRef({top:$t,dragging:rn,pageY:Gt,startTop:Rn});Vt.current={top:$t,dragging:rn,pageY:Gt,startTop:Rn};var Ut=function(Yn){qt(!0),Tt(Pt(Yn,Ee)),On(Vt.current.top),he(),Yn.stopPropagation(),Yn.preventDefault()};Se.useEffect(function(){var Zn=function(gn){gn.preventDefault()},Yn=rt.current,Wn=St.current;return Yn.addEventListener("touchstart",Zn,{passive:!1}),Wn.addEventListener("touchstart",Ut,{passive:!1}),function(){Yn.removeEventListener("touchstart",Zn),Wn.removeEventListener("touchstart",Ut)}},[]);var En=Se.useRef();En.current=Fn;var mn=Se.useRef();mn.current=xt,Se.useEffect(function(){if(rn){var Zn,Yn=function(gn){var Dt=Vt.current,Qt=Dt.dragging,Un=Dt.pageY,fr=Dt.startTop;mt.Z.cancel(Zn);var ke=rt.current.getBoundingClientRect(),_e=qe/(Ee?ke.width:ke.height);if(Qt){var Ce=(Pt(gn,Ee)-Un)*_e,Be=fr;!Pe&&Ee?Be-=Ce:Be+=Ce;var we=En.current,Te=mn.current,Qe=Te?Be/Te:0,nn=Math.ceil(Qe*we);nn=Math.max(nn,0),nn=Math.min(nn,we),Zn=(0,mt.Z)(function(){ot(nn,Ee)})}},Wn=function(){qt(!1),xe()};return window.addEventListener("mousemove",Yn,{passive:!0}),window.addEventListener("touchmove",Yn,{passive:!0}),window.addEventListener("mouseup",Wn,{passive:!0}),window.addEventListener("touchend",Wn,{passive:!0}),function(){window.removeEventListener("mousemove",Yn),window.removeEventListener("touchmove",Yn),window.removeEventListener("mouseup",Wn),window.removeEventListener("touchend",Wn),mt.Z.cancel(Zn)}}},[rn]),Se.useEffect(function(){return Cn(),function(){clearTimeout(Xn.current)}},[se]),Se.useImperativeHandle(te,function(){return{delayHidden:Cn}});var xn="".concat(ee,"-scrollbar"),wn={position:"absolute",visibility:In?null:"hidden"},Bn={position:"absolute",borderRadius:99,background:"var(--rc-virtual-list-scrollbar-bg, rgba(0, 0, 0, 0.5))",cursor:"pointer",userSelect:"none"};return Ee?(Object.assign(wn,{height:8,left:0,right:0,bottom:0}),Object.assign(Bn,(0,Ae.Z)({height:"100%",width:Fe},Pe?"left":"right",$t))):(Object.assign(wn,(0,Ae.Z)({width:8,top:0,bottom:0},Pe?"right":"left",0)),Object.assign(Bn,{width:"100%",height:Fe,top:$t})),Se.createElement("div",{ref:rt,className:Re()(xn,(0,Ae.Z)((0,Ae.Z)((0,Ae.Z)({},"".concat(xn,"-horizontal"),Ee),"".concat(xn,"-vertical"),!Ee),"".concat(xn,"-visible"),In)),style:(0,ve.Z)((0,ve.Z)({},wn),bt),onMouseDown:vt,onMouseMove:Cn},Se.createElement("div",{ref:St,className:Re()("".concat(xn,"-thumb"),(0,Ae.Z)({},"".concat(xn,"-thumb-moving"),rn)),style:(0,ve.Z)((0,ve.Z)({},Bn),ct),onMouseDown:Ut}))}),wt=jt,Ie=20;function Ue(){var ae=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,te=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,ee=ae/te*ae;return isNaN(ee)&&(ee=0),ee=Math.max(ee,Ie),Math.floor(ee)}var et=["prefixCls","className","height","itemHeight","fullHeight","style","data","children","itemKey","virtual","direction","scrollWidth","component","onScroll","onVirtualScroll","onVisibleChange","innerProps","extraRender","styles","showScrollBar"],cn=[],kt={overflowY:"auto",overflowAnchor:"none"};function Yt(ae,te){var ee=ae.prefixCls,oe=ee===void 0?"rc-virtual-list":ee,se=ae.className,ne=ae.height,he=ae.itemHeight,xe=ae.fullHeight,ot=xe===void 0?!0:xe,Ee=ae.style,Fe=ae.data,qe=ae.children,bt=ae.itemKey,ct=ae.virtual,Kt=ae.direction,Wt=ae.scrollWidth,Nt=ae.component,rn=Nt===void 0?"div":Nt,qt=ae.onScroll,on=ae.onVirtualScroll,ft=ae.onVisibleChange,Gt=ae.innerProps,Tt=ae.extraRender,en=ae.styles,yn=ae.showScrollBar,Rn=yn===void 0?"optional":yn,On=(0,be.Z)(ae,et),Pe=Se.useCallback(function(tn){return typeof bt=="function"?bt(tn):tn==null?void 0:tn[bt]},[bt]),rt=me(Pe,null,null),St=(0,ye.Z)(rt,4),_t=St[0],bn=St[1],In=St[2],rr=St[3],Xn=!!(ct!==!1&&ne&&he),Cn=Se.useMemo(function(){return Object.values(In.maps).reduce(function(tn,fn){return tn+fn},0)},[In.id,In.maps]),Fn=Xn&&Fe&&(Math.max(he*Fe.length,Cn)>ne||!!Wt),xt=Kt==="rtl",$t=Re()(oe,(0,Ae.Z)({},"".concat(oe,"-rtl"),xt),se),vt=Fe||cn,Vt=(0,Se.useRef)(),Ut=(0,Se.useRef)(),En=(0,Se.useRef)(),mn=(0,Se.useState)(0),xn=(0,ye.Z)(mn,2),wn=xn[0],Bn=xn[1],Zn=(0,Se.useState)(0),Yn=(0,ye.Z)(Zn,2),Wn=Yn[0],ir=Yn[1],gn=(0,Se.useState)(!1),Dt=(0,ye.Z)(gn,2),Qt=Dt[0],Un=Dt[1],fr=function(){Un(!0)},ke=function(){Un(!1)},_e={getKey:Pe};function Ce(tn){Bn(function(fn){var pn;typeof tn=="function"?pn=tn(fn):pn=tn;var Jt=Hn(pn);return Vt.current.scrollTop=Jt,Jt})}var Be=(0,Se.useRef)({start:0,end:vt.length}),we=(0,Se.useRef)(),Te=Bt(vt,Pe),Qe=(0,ye.Z)(Te,1),nn=Qe[0];we.current=nn;var sn=Se.useMemo(function(){if(!Xn)return{scrollHeight:void 0,start:0,end:vt.length-1,offset:void 0};if(!Fn){var tn;return{scrollHeight:((tn=Ut.current)===null||tn===void 0?void 0:tn.offsetHeight)||0,start:0,end:vt.length-1,offset:void 0}}for(var fn=0,pn,Jt,zn,_n=vt.length,an=0;an<_n;an+=1){var dn=vt[an],Nn=Pe(dn),Ln=In.get(Nn),yr=fn+(Ln===void 0?he:Ln);yr>=wn&&pn===void 0&&(pn=an,Jt=fn),yr>wn+ne&&zn===void 0&&(zn=an),fn=yr}return pn===void 0&&(pn=0,Jt=0,zn=Math.ceil(ne/he)),zn===void 0&&(zn=vt.length-1),zn=Math.min(zn+1,vt.length-1),{scrollHeight:fn,start:pn,end:zn,offset:Jt}},[Fn,Xn,wn,vt,rr,ne]),Xt=sn.scrollHeight,Ht=sn.start,Ct=sn.end,pt=sn.offset;Be.current.start=Ht,Be.current.end=Ct,Se.useLayoutEffect(function(){var tn=In.getRecord();if(tn.size===1){var fn=Array.from(tn.keys())[0],pn=tn.get(fn),Jt=vt[Ht];if(Jt&&pn===void 0){var zn=Pe(Jt);if(zn===fn){var _n=In.get(fn),an=_n-he;Ce(function(dn){return dn+an})}}}In.resetRecord()},[Xt]);var un=Se.useState({width:0,height:ne}),$n=(0,ye.Z)(un,2),Dn=$n[0],kn=$n[1],pr=function(fn){kn({width:fn.offsetWidth,height:fn.offsetHeight})},gt=(0,Se.useRef)(),Ve=(0,Se.useRef)(),Et=Se.useMemo(function(){return Ue(Dn.width,Wt)},[Dn.width,Wt]),Rt=Se.useMemo(function(){return Ue(Dn.height,Xt)},[Dn.height,Xt]),Zt=Xt-ne,hn=(0,Se.useRef)(Zt);hn.current=Zt;function Hn(tn){var fn=tn;return Number.isNaN(hn.current)||(fn=Math.min(fn,hn.current)),fn=Math.max(fn,0),fn}var Sn=wn<=0,Tn=wn>=Zt,An=Wn<=0,jn=Wn>=Wt,Pn=je(Sn,Tn,An,jn),lr=function(){return{x:xt?-Wn:Wn,y:wn}},Jn=(0,Se.useRef)(lr()),Kn=(0,fe.zX)(function(tn){if(on){var fn=(0,ve.Z)((0,ve.Z)({},lr()),tn);(Jn.current.x!==fn.x||Jn.current.y!==fn.y)&&(on(fn),Jn.current=fn)}});function sr(tn,fn){var pn=tn;fn?((0,yt.flushSync)(function(){ir(pn)}),Kn()):Ce(pn)}function mr(tn){var fn=tn.currentTarget.scrollTop;fn!==wn&&Ce(fn),qt==null||qt(tn),Kn()}var Qn=function(fn){var pn=fn,Jt=Wt?Wt-Dn.width:0;return pn=Math.max(pn,0),pn=Math.min(pn,Jt),pn},cr=(0,fe.zX)(function(tn,fn){fn?((0,yt.flushSync)(function(){ir(function(pn){var Jt=pn+(xt?-tn:tn);return Qn(Jt)})}),Kn()):Ce(function(pn){var Jt=pn+tn;return Jt})}),Gn=Ot(Xn,Sn,Tn,An,jn,!!Wt,cr),vr=(0,ye.Z)(Gn,2),qn=vr[0],Sr=vr[1];De(Xn,Vt,function(tn,fn,pn,Jt){var zn=Jt;return Pn(tn,fn,pn)?!1:!zn||!zn._virtualHandled?(zn&&(zn._virtualHandled=!0),qn({preventDefault:function(){},deltaX:tn?fn:0,deltaY:tn?0:fn}),!0):!1}),ge(Fn,Vt,function(tn){Ce(function(fn){return fn+tn})}),(0,We.Z)(function(){function tn(pn){var Jt=Sn&&pn.detail<0,zn=Tn&&pn.detail>0;Xn&&!Jt&&!zn&&pn.preventDefault()}var fn=Vt.current;return fn.addEventListener("wheel",qn,{passive:!1}),fn.addEventListener("DOMMouseScroll",Sr,{passive:!0}),fn.addEventListener("MozMousePixelScroll",tn,{passive:!1}),function(){fn.removeEventListener("wheel",qn),fn.removeEventListener("DOMMouseScroll",Sr),fn.removeEventListener("MozMousePixelScroll",tn)}},[Xn,Sn,Tn]),(0,We.Z)(function(){if(Wt){var tn=Qn(Wn);ir(tn),Kn({x:tn})}},[Dn.width,Wt]);var ar=function(){var fn,pn;(fn=gt.current)===null||fn===void 0||fn.delayHidden(),(pn=Ve.current)===null||pn===void 0||pn.delayHidden()},or=Je(Vt,vt,In,he,Pe,function(){return bn(!0)},Ce,ar);Se.useImperativeHandle(te,function(){return{nativeElement:En.current,getScrollInfo:lr,scrollTo:function(fn){function pn(Jt){return Jt&&(0,Ke.Z)(Jt)==="object"&&("left"in Jt||"top"in Jt)}pn(fn)?(fn.left!==void 0&&ir(Qn(fn.left)),or(fn.top)):or(fn)}}}),(0,We.Z)(function(){if(ft){var tn=vt.slice(Ht,Ct+1);ft(tn,vt)}},[Ht,Ct,vt]);var hr=nt(vt,Pe,In,he),xr=Tt==null?void 0:Tt({start:Ht,end:Ct,virtual:Fn,offsetX:Wn,offsetY:pt,rtl:xt,getSize:hr}),br=Ne(vt,Ht,Ct,Wt,Wn,_t,qe,_e),dr=null;ne&&(dr=(0,ve.Z)((0,Ae.Z)({},ot?"height":"maxHeight",ne),kt),Xn&&(dr.overflowY="hidden",Wt&&(dr.overflowX="hidden"),Qt&&(dr.pointerEvents="none")));var er={};return xt&&(er.dir="rtl"),Se.createElement("div",(0,z.Z)({ref:En,style:(0,ve.Z)((0,ve.Z)({},Ee),{},{position:"relative"}),className:$t},er,On),Se.createElement(Oe.Z,{onResize:pr},Se.createElement(rn,{className:"".concat(oe,"-holder"),style:dr,ref:Vt,onScroll:mr,onMouseEnter:ar},Se.createElement(Le,{prefixCls:oe,height:Xt,offsetX:Wn,offsetY:pt,scrollWidth:Wt,onInnerResize:bn,ref:Ut,innerProps:Gt,rtl:xt,extra:xr},br))),Fn&&Xt>ne&&Se.createElement(wt,{ref:gt,prefixCls:oe,scrollOffset:wn,scrollRange:Xt,rtl:xt,onScroll:sr,onStartMove:fr,onStopMove:ke,spinSize:Rt,containerSize:Dn.height,style:en==null?void 0:en.verticalScrollBar,thumbStyle:en==null?void 0:en.verticalScrollBarThumb,showScrollBar:Rn}),Fn&&Wt>Dn.width&&Se.createElement(wt,{ref:Ve,prefixCls:oe,scrollOffset:Wn,scrollRange:Wt,rtl:xt,onScroll:sr,onStartMove:fr,onStopMove:ke,spinSize:Et,containerSize:Dn.width,horizontal:!0,style:en==null?void 0:en.horizontalScrollBar,thumbStyle:en==null?void 0:en.horizontalScrollBarThumb,showScrollBar:Rn}))}var ze=Se.forwardRef(Yt);ze.displayName="List";var zt=ze,ut=zt},93314:function(ln){"use strict";ln.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAMwAAACaCAYAAADl9acYAAAAAXNSR0IArs4c6QAAIABJREFUeF7tXQd4U1Ubfs/NaJtO9kzLahFQEJkiUBBFUFFkCCjiAAVFERT5FREQQQXBBcpysWRP2RtkKRsEOphNodCZdDfjnv85CU2TZt2bhABNDw9PmtzvrO+c957xLQIP0pkz1yrQIEmwwcDzHhTj91klEo7jpcG5zetWUJdmRjmPvTM9GI9JgSGvadOoLE9KJJ5kPp2YXLtZdO1kT8ooz2vigCNelvPYezPEG7z0CDAn4pJqPvJA5A3vdcl/S3LEy3Iee29OeIOX5YDx3nh4VFI5YDxin6DM5YARxKb7g6gcMHd+nMoBc+d57LKGhCQ1ZURBCoVL2nKCO8sBZWW50x1TOWDuLP8FlV4OGEFs8glROWB8wmbPKikHjGf882bucsB4k5t3qKxywNwhxrpRbJkGTOx0ehlA3d9e5VEtzA3ulGe55zmg1QOfrCVo34BgQGvr5rLDRl4RRZG+5NjBESBc4FHw1LlrCAuPsCo0JjKi7J5hYqfTXADBq4byCJLf82Nf3kA3OfD9LgKdgeCzZ4CUTJ1VKQFyKQgpmeMSjiKvQC+oplspN/wOMDcBVFv0Bo+KwYJ4VE50H3Jg7j6CWzkEX74A3MrSgTfeKZpSaBCHcAVn/JunBHlFPDR5BkG9LMjPt7mZLOtbskQADea9wqOW9coqiGHlRPcHBxYcJriQQvB9P+v2cqCwWFxgoOJk6JeTNX4HmJMAHv6xP4/6VXw/+OxNx/bM/pIohdUE9VW/VxwjOHiJYO5A6xolpGSpYW3jIW4w/A8wM+h+UHSY2pvHgzV9NXymeor0wPc7Cf7XzWJ/4Nsm+Ly2LzZx+OwZ3yuVbzhNsPEMwcI3rM8wMikHiURi5gNbbQoKrc84zpjkj2eYzQC6f96DomUd305ctrp8tp5gSk/f1utzlFhUOHYthy9f8D1gdpwnWHiEYOVQ6zNM6QM/AY+CImHnF9YtfwTMCgB9P+5G0SHa9xP3bk2gT9cBU3r6Hjp95nBYNcz3gDlwkRhX843vlfS59PmFHfjFzgC/2pJ1nEEnEIpIAG+834Wia2Ox7PJ8wt0twLz7J8Gsl3zf316zCVYPsz5oe85F1yUcu0YwcQPBjlElZyjL8wsrQeyBn+XxK8DETqefgyACFCPe6kjxfDPfT6C7BpilBLMG+L6/A34h+P1VikCZ60nuTYpzN4AxqznjCqPOMZ1RSp9f2OVLYZH1lbOrNvjVlswIGEAKYOyrj1K82NL3E+huAWbEMnbFSn1+Qzd4AcE3fajPZV6X04D3lnHGM4xOawKFJwLLYiD5H2AoCkHwJQMLA42v090CzJjVBBN7UCh8rN3AgDrqCYq6lX3L6RQ1MGQRhwWvA7UrALbnFzCJjOhG+d2WjFCkUYKZPZpSDIv1PWDGrycY34NCahI0+yxN/Ivg3c4UlUN8VqWxok/XEfRrSdG0tm/rzcoHBv7KYc5AILqqLWDcOb/45RmGEFyhFL8/0Yga33y+Tl9uJhjxOEVIoG9rnrqVKSJSRFb0fb3tG1A81sC39TLRSu85HL57Eaii0Bm3oqEKqZXSJaUURUxTU0Tyuy0ZAc5SYCUbxE+6+x4w3+0kGNiWooqP3/Qz9xB0bUTRsLqI2eEFUlbvA9WBJxv5ltdMit9jFocpLwB1InQIkBEQTmLUHStOBoMBOr24K2+/AwwPHOKArS2iKCY9VzKIg34jyMgTv6f1wpwqL8JLHKgUTLHwjZIxZTKg0V2Bzg2tLzvYBYA75xe/25J1mkEnGAzYyXE40KQmMK23uLeLN8b1j0ME7epTxFTzRmnCy/jzXyCqIny+NVryDzFeKfd+xLcrDOMMO8MMfgx45iFrOZA7AstiTvvVoZ91usM3tClHcLpeZWDmAN8DZtlRgkY1KJr5+BC87hQQLAeebCwcZN6gXH6MgG2P+rfyDmD+WLoV8xZugkIRiNh2TTHghcfRoF4tFBZpkXgpGQ81rmdu9puLOLzwMPBYPR1Cgzw/v7CC/WpLxjrc/jtaT2LApRrhwC+DfA+Y9aeI0dKzbT3vTCChk3r7eaBABzzfTGgO79CtPUmM9b7U2jv9bf3kOyjSlihLcoSg93MdkZ2Th227j2Hoq8/inTeeNzZ+xFIOsTHAsw/pAeL5+cUvAdPuG1pVRnArQgEsGex7wGw7RxAgBTo19M4EEjqtD1wEkrPYm15oDu/QbfkPSM0hHsu8du0/gSnfLkFGVrbThjFLynULJ6FOZHUw2RNbyd/qUJLFHZV+ywr9aksWO4Ou0BK8KueRz/bVq++CUuD+RGbhB3R/0LeAOZEEnFIRvPGYb+vdGw+cvU7w3uOe1dv+mfeRk5svCMUfvz8AA3o9jgkbCJQVgPe7lGTz5MDvj4f+VXs/JH1ip1PmAkHy17u8z42bjl4lxjf9C809m0CCZo4FUVwKsDPOJLz0ZTp6Fdh6jtnWe1bvuCm/4q/tRwQ1/b03e2LIwGfw1RaCkADg425AOvPkYCHZd0cG43dbsk4zaDFgWHiHcG85wjBQoEhnMhAzf5r/Jihkf9/+fjXDtDXqGA108+Eqcy0DYAfwMU95NnEFzVgLovibwK8HCab19qze61s24Pf5K7A5KwB5vHM1CblMij9m/Q87rtc1jsek54CMPIBayGD0BgP0ImUw/gwYFiqjllhHGAcvAkuPcijU8cgv0KGgSGv8LNJqweu1MOh14A3ss+S78W+Dzuo3RsPoTy0YgIjQALFz0C36tBzg570EE3p4NnHFVn5TA0zaSPDzy57Vu2bIS6jF67BDHYBHgnVI0kow+6ZjLyZNm9RD+35jkZINfNO7ZIVhEn+e16NQ6157/OqWjJ1h9n1IXoydTi8AeGD+KzxqinCEsfkswfBJC2HQacXOG7v0B+e9CGXVUK+U5aoQdm5iE3eqh296R/XoDEBu0e3/hcz3FzF+Z292trI91Zgav7N2tKrDrrfFTdgTI4dAl61BipZDDXYINRCMvBrusNvBikAMHT8LTM3/pwElK4xMAuQV6uBuKK4yA5hEVfY8SvmmHCETGyjDtzqbQLHf0KMgaCnWEcaW/whGT1mAHHZP6oW09bueaFy3khdKcl0EO+y+v4xgphs2MWxbs+K46bLCDIoi6+9iVLKY4PbTp8UB5t8h/UB53qimz1aJA9lyLExz7H1vyMCnUa15L/x9EfhtkIk/nh74y9ShPz5JnUGA26qFZIdcTofWqR5xxd5Uip1O9wDoJNYRxs4LBB9PXYxUdaHrGSqAYuWUp9GmSQ0BlN4h8cTq8qVfOGgKStpBeAoJb4DEYPrPsU89b/5e/LvEYPubLCIQX06NEtWpfwa/yA4h0FEgqVCK71OCUeTARdLLfbpg9PAXsfGsBBtOA0uHmKpyV0PZsqFl5lo5QaXWgRqNw4pTHiEYGa2M+KX0yMROpxsA9BDrCGNvAsG4GcuQdMt45eJx+nXsk3iyNbOY9k161wOry8/GqZCr1t4GBA/O3T0Nm7gSDl/89IBRHiU0nRk3CgU3knEmT4pZN51rrjI5TN2oGmCOMP44BKx7B8jINemP8ZRCK2Y5LNXAMrMlS0hSpwKw9TRGME+XHf5ekybEfPCInU7/BDBArCOMw5cIPvt+JRJUGqHj7JRu2rsd0P+JGBuanELTTVpwwO3/cnjFxNcTwMz95hquxud5pd+skIEfR6NJA+F2y6o1S3Fj4xpj/X9lBmK7OsDuChMUKMf+v36AXC4Fc4QxYwew/X0gM8/k5VKvN0BvcF9gfc8CJuGWuh4twgoQnJSBzK+nDP+3eLTsBahJSNL8DdD29kaUAFsDSU4vpVJp3FTETqdzAbwl1hHGySSCCTPX41RimlcmzthBrTCsV1Obss5cJ2hWXQupTIoiHUW+1nRYZkcn5kRbTzlIOQq5hBmimfRu2RwoeU4gl5rAFiI3Odpmb/NRK0zXu+zgKzZtWZWK/VvTxWZzSP/EK5HoEivcxsFQWIBzk8caVxmWmMT+g6thNlfMg/p1xYfv9DXSMEcYEzYAu247wnBXQ9myE/fslixRpf6FUgw2N5bgDChmk6Lw33MMqkqlg8JeVKmn8hRjHI0QIdgbiJynGWhiZ9AZoPhgaEeK50Q4wmDCvwmzt+HwGe8EcH67V1N8MshWV4UBpnlNLQID3Lcn5nkKrZ6iUEex4azEqC08di0BW1XDgsTP+2NHsrH6F+/0m9Xetns1PN9b3IWHPi8XyetXIOPoEeg1WbhYKMGK9CCoiiSoWq0SnuvWzqhLVuyoz+wI411mmi3epZI9Lt2zgElIUht9INtpdDJPMUsSGf59NCFFxc8TknI6AoZ9LqbCmj+V4X33zMAEAOMHtaXoJ0KLVpUJjJuzD3v+vSh+xtnJ0ffxaMwY0dHuCtO8pg6BAcK3LI4axCTai/4hRsBM3kww5DGK6o5vYx32S52pw9QxbEi8k6o2DMeoj2q5VVhqNnB29JsI0TP5M6Dj5Gg7dwmkpVZOsyOMtyg4joDyBhRq3d+Osbru3S2ZSp0LCmf+9ZM5CUY3qBWx3LREUy5RpbkKQOl0FAimvrksPAME08Q6wmD74DGz/8H2A/+5NdClM8U2r4VFE7rZBcwjtXQIkHsOGLbSLP7XBJhvdxD0fJiinhs+pVk5n41IBM/UFryQSHggvpxRooovpsgdFwjoD8MQri3ZIso/XYzm9a2FwDfUAFPxX/AaRYSCeCR/KW7fvQuYJE0RQF3vSQh2UQn3bsOaYXEJSZrPADrJBfP5BceCVx+4LO0r1hGG3gC8//Np/LXrmJjxdUhbv1YE9vzU22eAmbOPBRmieNCNFzvP8/jhaxVSL3vn4M9zBJN/bgSZgJsyplZ0KQ24oSZgq8vmE4V4+9hrkNIS8O5uPhbNOz+CprWpWRhd7Ahj9svMYM871rT38pbM/q2XvelHoeU4bpxBgt+Jjr8MAqfi80NXZEW/H1UEuOMIY/zCRPyxZr9XABMSJMP5pbelahYlsjNMi1p6402Pp8lyhWEhIBpVp2hdV1yp6nwgPAhYvzQF/+zOEpfZCfXgz6LRIMrxKsq0B5YcKsL6UxRFvBygelBdLjhZGMCx/RfTKWMCUGZzbAClvJEmtiGH97oEGLdhzBHGjL4UDyvLOmBUmn9AaamAay7GimAXgdErzG1RlX36k9el+PlgsPFtK9YRxtwtNzBl7havTZoLywYhuJRbSCNgauvBlAg9TQYDjyVHOeOWbOVxoEoo0Mn2JttpNZvOcmhfn0KTXoTr8TlITSnCrRSt8TMvV7gj79KVPDskCo+1tb/rZkLScavzcTlTARBrZUu+MB1coHNHZ8rQXEzvH4T+8yWY9DzQrj6QptFDzzRlPUj37JbM5pZMeCfZK5CNgsPt3PlbEny3LwSlHWEIqWLzcTWGfbFaCKkgml0zeyNaaa3QdqcAs+msSa2k+4OCmmYm2nyWQ98W9idabo4eqSla3EopMn6m3mRgKkJ6KlM6dV5Plz418ES3CjZE7Ar9w2X5UGXbv3bmC1NBAiqBEOf34zFhKlzLq40PuxK0i8qFutBzRdd7FjDx1zSDCKELxA2tmZoyyztqqc9tUdDlDAm+2hUCdxxhHIwrwOAJy5EvIkSCsz78Nq4rnmhpfU/BANOytgEydwQmpSpjQro/b68we+JNArzej4jjKouz0q+luDwGAzWCxnI1Kr0qPfpEZTzXv6pVwUzf6+MVBTiX6vi+hxoKQfUF4AJswWZZGF+UCUN2IsYMaINnbcVd4jp0m/qePcNcvJlTldcaUm5vVN3qnKNM1zUcJm4LhTuOMP65qMWYGWtxJcU76jGT3nwUrz1j7ZnCCBilAbLS96RucIFJtv88ZpLD/HMZSEgFXmkrrqANp2yjEYsroYRar6f44I3zxh9qNwnH8FHWNxBLj2ix6F85SKltmGV9lBrAF6RConCuh8fotCn7MSC2Fob3ELkPddDBexYwrL2JSZqtFPQpdwfHUT7mf+zjTWFwxxHG8St6zPhtCw6cZXcSnqdhLzTF2FethZcMMK2UBki9DBgmbz18mYAJbMUk5shiYBsxORzT5ucZ8PHbcUaC4OpBGDe55AbiShqP9/40gHLOt058UZbxXMPJnQuUKK+DLi8DEs0R/PJBLIIVwjULHPXgnt2SsQbHq7JeIJSYFIi8mNgeeeT6cFRQAItFOsL4L5li0do9WLrLriK06FZ2e7QO5v3PwugcgDcBo9MbsPT2CnMxFcYwdiNFuMhlKjcs/J23AMMEoONHJhj5JA2T44tvS2TTo5cX4kKqY5X9YuYacq9CEhzlMngmr8uGQasFLUpDPcUV/DCiKwrcNBwrrvueBsyKFVTSvG32aQraRPRMdJKBWaa+vSrcqNAo1hEGsyD8Y/1R/LzmjFea1EBZAbtn9rIqywiYSB5Siecey3U6A5YeN23JmCCPORIcK8IWhV0ps1Wpj8hzjyPmsDPN5P+ZNCWInMOXPz9g/PtgohZfbpEZ3SE5TxSGXBUkIa61vPnCDLCzFEuGrOMY1q02Xunq2VS6p7dkrKOJ17N7UAPP1PG9moatCoOBJ9go0hEGe+P+vC4e3yw84JX2VAoLxMmFL9sApnUkD4kXAKPV6bHsuNQIGDb5p28nmCwixmZSJnA5jeCZh1x3NzfpKi7M/xlFGRmo0qoNqnfohPAG1mcH1dUCfDP+sqkwjuCreY2Mf478swiJGa6V3Az518EFVgHhXMu0DYUZ4G8Dhuqy0Sg0EfM+8myHf88DhjEzIUmzAaA9XA+ZcIqR60KRp+XgjiOM3Sdu4s0vtyAkSIrgQCmCg6QIYZ+BMuPf7Dfzs9vP2bPi34ICZTh2szJ6NM41HuyrV7f2G8tWmNZRPCSc5yuMJWCYGcjHawm+7Sv8DPPfdSBfS9C5oWveHhg+GFqNyfRBEhgIeWgY2kz7AZysRDh5KT4fP0y5vZ0lwBdzGoO9FwbOK4S6KMDpCkP1eaD6fCNghCSDNhe8zmTsVznrMD59XIGa7Wx194SUVUxzT2/JihuZmJJThWoNZ0HgNY/EH28MRUY+B7GOMFibcrJzkJuXB3Z1zXHc7U9ivNlh0mX2aXpm/7ekLA57E6R44zHm5slWAs0A0ybKpDDoaWLhHJafMK0wLIm1ujx0iYD56WgrQO3ryuplSN6xzajkqM83+RCr1aUrol95A5zUJIT971QO5n2bZPybXYRNntsYvx4guLJrL1qkbsD2moOQHP6wlUskRkt5PfiCm5AEC/exa9DmgNcVoVL2KQy59RsqhAQg6tPvwAU5U1F0zvH7AjCsC4mqnE6UGpitvsfSJ0IIHb8lmNzIlkCsIwxPJzDLf10NrDtJMNyBjzDvAkaH5SdkbgOGOf5oVAN4sKawnl+YOwspf+81EzPIh9VvgCbvfoDAKlVx9JAai+ZcNz4PVBBE9W+M07uPo9/laeBgknSeC22ObbVeQ06QCRzselivuQhZBNveCX+JGAoyEZEThyE3fkIYNa00yh69UPdF6y2wsJ6ZqO6LLZl5pUlW9wHFMkrh6mTokgdf7QzG5UwpxDrCcFmwAAImPPztIMHorva3RkbA1GEhGoRPDkfVMj/EVoARaabM2vliCxj9QQtJ1GDAtU3rcGPXDmjVWWDfWWJbtHp9BiCwRScU6KQICJRg4VEp4g8ex4tXvrFSpGT0JxXNsKraIEgVFaHLuQ5ZSE1wAeLsEioRFZ5PnAVlTok5hiQwCG1+mAupwr1V5r4CDGNkgkrzEij93Znqi5CB/XafAhduySDWEYaQsl3RFGiB6Tsce4NkgGlbx+WtqatqjM9ZlOAVJ0tWmPeWEvzYX3gYcOY9cuKzsLE1EVK5oagQJ7/4DDlXS67gZTVqI6dlXxwNaIXrJ06j75UZkFhoHbNyK7Zqh2E3usHAlCupDgFhtSAJEmdsxsqJqZSHevmJaHPoC6vm1nvpNdTu7t6R+L4DjAk06t7M+tKuDb+QkQTw00EFTl2XQawjDIHFOyVj6h+frSeY4uC2it1MRVXgIeUIpBLTWcjdxMJArDgpN2/JPlpF8PlzwoPDjl9v0vZ1N2k1apz+ehJyVaZzS3HimUMKIoWUWrusqtDqUTR46308/bUKekghU1QBkbq+PbPXPkNuEog8DAOS5+ABzVEzSWj9GDSf+JVbXbovAcNs+oODFYSjsp8oqCm2gcj06z9BOHJNbjTZ7RDt/oQQWa2ZXEw0ZWY1yYzYGdCYuj5L7AJNwgBlvHRgj3mjnfvtx0YlS/Zcp9dj6wU5nmpiysccdLMYm5UECr3HruHwQ3/P+KPLzcWZ6VOQfdG5xWbVzl0R9fJgEI7DjO0Eu85rQSTuH1lbV45HbmYSzl1OR+2im4g0ZEJpyETdAC26zpnv1tDdt4AptulPNJ1rplMKUY6uFh8PxL5LARDrCMMtLtvJJAYw3qqTlcOCw7JYLUoBwWHZWWvBIYJxz3jeAiZxv7R0AZJ3bIetdT1B7T4voebTPc0VMbe2G08Wur26sII+6JyD5x4JQU6+FkfOp+DA2es4fO4GsvO1qFk5BE3qVEaTupWNn9G1K0AmILT1fQ8YxhhKqfTi9ewBoPQjSiFAxAasOh2AbfGBRr0qMY4wPJ86phLuFmBm7ibo2oSioYAL+uPXgKvpBIMe9VavgctnE5C7fyuyz58Bc2oRVKMWaj7XBxVbWGuELjxMsOxIAYjUtaqMo9Z90CkHz7WwXkoNPMXZy2k4ePYGDvx3HVdSTHIjBqCVn7verJQJwBQzjKnzJyRlPcZJuJ6UxwsAHEoP/joXgA3nAiHWEYa3ps7dAgyTeTwSRdHcuecDYzdXHCN4oBrwaH3v9Fqr55GWmY2ICNe3XWtOEvyy17MVZmRsLnq2dH4bdv5qBt6Ytg3d29TDOAFvhjIFmNLDGp+c1UxCycs8xTu3jcrMJDvi5VhxOghiHWF4Z+rcvRXGGBy2EvCYABB8sZHggycpqoa6f+lgya/MXC20RUUIDXV9gGJueb/d5tkZ5r0OOejd2nldm/+5gkkLDuOzQe3QrY1r2+0yDZjiwbp4PUNJeelKSqlZSX3/ZRkWHVNArCMMbwFm/AaC8c9Qt65rPWkDCw7Lggw9YVLhcprWnCCoH5qKGmHUaC4tl8sgl0kgl7FPqWhdt6upuQiWc1AoXN96MSd849ez62/31YPeeSwHL7Z1DpixvxzA7hNJWP9lL1RmjgtcJL8ADOOBSkWDCqiGaQoYlYn+TZJh/hEF3HGE4YqpQp7/sC0PrzRPhYxPg9yQjmCkoTA/HUV5aZDq0wBZBQQ0my6kKFE028/BGODpOYHBYfPy8qDT6aDT6Y2flolpUxeDhznscAWkfxKzEFNDAbncteIk8xIzYinxSBj1VrtcvPSo4y0Zs0Z96qPVqFpBgcXjnhXEx/saMCZfZNmTQCjTmZCAEC0oUglPU3iOnDEYtCcb16nCrDaN6ZxKU1HK0xOEIOrMDSlmHnDPEYZLzhoKAW0aivLSQXRpCKRp4HTpKMxNAy1KN36XE+cRAHjKIb/pckhk7h967bXz70STao47wWHZ9bZebwJOMYDY38Zrb4vEtKwZeAKMq5IJSDKZFOuPpqFr8yqCNBjYDd3AXwwgnPu+2Qa3zccrjzleNY7G3cR7P+7G8+2jMWaAMH8r9zVg4pKynudA1jmawExnjKf8fwRkAwF+j46MuJSoyupEKdkdnyoh0/e65wjDUX1c3MdA3hUEEO+YL6fU+BwRNUQa07tAM7v5OpNM8LoXg8PqDXrotHrojUDSQafXgXmrKZ3i0uV4vKkwiT2TJ/WcqYWBBLp8PzkieK1NIV5r71iO8/2qE1i2O8542GeHfiHpvgbMRVX2RzzlpwnpKCGEOa76i5dynxCeTriaTvpP2RnqliMMhwC9MBaBBaeFNEcQTU7FvpDWeU0QrVCiCynA7jjHip9Cy3FFxxz/mVYi0//sPD2u5wWgXUOBSmkAXvtVj7R819s3R215ta0Orz/m2FVVnwkbkJyWa7xOZtfKQtJ9DZiEpKzXAfKbkI6W0JAiQrDyZjZ5adyWUM4dRxiO6qOqRVCkLRPXHCfUt2gjhLXw7jmGBYdl18Uf+Tg47K4LBCz0uZh6P1oJnL/p/qH/5dYGvNnBfv5rN7PRb9JGVAoLwoavrC1enQ3gfQ2YC1ey6kil3CV2lhE7S7MKuMIxf4UGuuMIw1FdhszjCLk6XmxTHNLrqRT5TVdAJnNfPaR04cbgsPsIJjzrmbqL2E4evgxsPy+uXubM7+Vfmbss9661X2lDMdhuABRgyc4LmLnmJGKbKfHlW8KNyu5rwLBBS0zSbKBuWGOyWCoj1rrnCMPRZNEX5SLk3ACmVih2PjmkV9WYiso1RHrec1I7i1HJ5Ct3Kjiso6rPXgeY9P6bPsKB2uSRWKSlZbjNy3FjhuOTD5kIzja9891OnEhMxVs9muHVbsL5e98DJu5ydkNOxh934enfhmPsUDl0ZRgCZUS0IwyHWzJmqPPfcATorrk9yKUzZld5DTKlKUCQNxLr98jlJhV/X6ZrmcBXmwnmDBReb2R0CxQWmiOaiG5uj+5dsOyPH23yMd2ybmNWg6nJfDv8cbRpLDzO6H0PGMaN2zYyi8Q6/Ru+Ogw6A8FfIh1hOBs5evE7KLJ3ih5cRxluSR5FWLNxXiuPFeRJ6D53G5KWC3y4gmDhG8IAw7Ssa9Vlpsrup8jaNXHh+A6bAnYcu4bPfjto/H3z1D4IZ5JcgalMAIb1NVGlHkwpmQ1QwRf3H6wPRU6Re44wHPHXcGMTQm7+LJD9rsnU+soIaO2ux1z75Yu163fdStcUuYXA6wsIVg4VBpjMLDUeaOrgAOK6OjNFcvwhVCiluzbh90PYdvQqqlcMxuovSjSkhRRbZgDDOnsxOaczpYaFlEKQp4Sxm0KQlidxyxGGI+Zqs+IRfuUDIbwXTJMWsxghIc79CAsu7C6Ndg0lAAAdVklEQVStMEws88Jsgg3DhQEmSXUdLdt55hLJuIKs/g2x7UvcdrJtWPcxq40q/h2bKfGViAM/K69MAYZ16NKlzHCDlHwBwr0FUKdr7efbQpCs8a4jjMKCfITHDQRH3d97l578qmqTUblWczGYcErLzjDT+/hej63HLA5r32YOCl135dyFeHTuahtsynVOa4qvPv8II4aVyLJOXUzFsG9NW+bXuz+EISK9lJc5wBSz69KNzEheLxlFQVnEIrvmUlN3B+NiuncdYWi1OsjjP0KQznvxIDVVh0Bem1kreCcZg8N2pwhzX4juVkN6zebwx+u8oHr/OXoCPXrZBpsSW/GAvj3wy6yvzdl+WnsKi3aYnKFPHtIBnZu79qBpWWeZBUxxJ69coYE6ae4zlOqfIyBPM59uxc++36/AuZvedYTBJNz6+OkIL3AVn1b40N8K6oawRu8Jz+CCcvImgiEdKKoLF7p7pe4B8zl8148XVO+uPQcwYNAwj+tt0iga/+4t0Z4a8MUms9HY0vE9ECnUHc7tlpR5wFhyfA+l0lqq7L4A/QlAhTmHgnA8We51Rxh5FxejcvZSjwe7uIAk/cOo0nqK18qbsYPghebUGO7Dl+n1Pzh89iwvqN71G7fhzbc/9Lh5LALCzr+PQVMkR2w0Na4u566m49J1tVElRqyDEb8CTDH3LyblPMhTw67fjwZVPXTV+44wspP2oVq6IBU3QRPiprYWwtvOE0QrhGj2PoKO0dSoR+fL9O5SDm/H8oLq/XP5Gowc7R2tic9/XIlNyU2wY5RH1gJGVvklYFjHL6k0Ty85EbhxV6KceNsRRuatS6h1fYTX5mK+IQR5TZcbDb+8kVhw2MY1KFrV8UZpwsv4ZC3BCw8LC0o7/7fF+HRCydnDWS1FOSmQh1S363aX5XtlxGTEBfbCxveAIMFCB/s1+i1gGDsGL9Cvvpgm6eVtRxgZGZmomTQYHNUKn01OKHlIcEG5AfWE+eB2WefKY0DVMCDWO0G5XNZXTMDOTu3qUzxuinDhNH0/cx6+nGYrpS+diflxLkhPgFRRGfIQ+wzq9OxA5DUei5VDgYruObw0V+vXgOn8LR3L85jibUcY6iw1KiV9CLnhpqt5Ieg5DxkOV16PRyKFyTBcFbrxDPNZJj44rKtyXT1nvsYaVqeC4k1OmfoDfpjl2ncYb9CiMOOS0edyUOVoEGM4cuvUuGkrBHdbgIVvALWs4++6arLNc78GTOx0yq6efvS2I4zs7ByEJY1HkNYUactZ4kkg9FwE9JIKMEgijH8bjN/Z36bftCQcudLaeKC6q9KEPd8dB2Tliw8OK6x0x1Q/7SWoGkrRt4XrksZN/Brzfl3skpB59S9IN13hy0KrQxZkK+ANCQ1Do7ePYO5AoIF1DFqX5Zcm8G/AfENfB8Fv3naEkZubi6CkbxCou2yc9CZARJgBwcCRVlgZV3KC0aSmAhwnQYBcYowHI5FIwIN9MjPfkt/shcUQPdq3Mxy5DLDwfQNFBod1t77ifMyxuVxCBdX7wZgJWLzUdXh3Zh7NtmSgPCQBIQgIt+8/qtmw3fj5zep4yDoGregu+TVgOk2nTNl8pbcdYeTnFyA9U2MMDhQYIIFcwoGTSGCgnHHLECTnIJVIMG2H1BjywtcCRBYc9shlgrdEBocVPbtKZVjyDwGLLyqk3mHvjsGa9ZtdV0k4FGZdBa/NM/JbUcX+wSy692z8PDoWAjwpOa3TvwEzjXajHLa0b0DxSXfvnA9cj3AJxfe7TG5bq4aKyeU5bWIqsOkswcguvu3zyuPE6IBDSL2DBr+Hrdv3uOxshVqNkZqwH7q8NCNtYKUG4CS2V2G1OozE7ClvoZOHFx3+DZjptD0F/m4RRTHpOd9OHja4c/cRdHuQGh3r+TKxScuMuXz9kmDRmM/dgKB6+wwYgv0HjrhkS6+Bb2PlbzNQpDbZILEtGdualU4VH3gaX0/92ii89HZSVpY7NQllzvOLfYG7W7d7Nqe3a/NGA1hR7WfQZhKKU0yAN62396wkhTKFyUPa1qVo6KXDvNB62YH/2x0EXzzv/cnjrA07zhPsT4SgepkeGdMnc5V++nE6Phz/PTITmEIlhSykOmQK24M/W3mmzV2Lpxp7f5z9BjCPT6P1DRwuetMRhqsBtnzOnFHEVAMeVvp24hbpmata4lHcFzH9LKZl8TJXn4Cgep98+kWcPmtSknSWVi/7BZNmrsc/G2eC1xVAqqgEeYjtVRjhpPji1wN49qE7x+uYyAi7C4E3XvA+XWFU6Vo1ABsP2MzJwvDlMnjTEYarAbZ8zrYoVUKBR+vduUF01J67YUR2OhmYs49g9suu+9uhy/OIT2DyFedpz/bVWLXtFL77/F3o8zMhCQxHQJh9nZ/RU5diYJc7p95QZgCTnKHLppTaHK3Zm3bwYhkqKIDFg72/VLsabLZFYbYhnRu6nkCuyhL7/G4AJuEWwKT9QsyUWz3WDdeSkl1268zR3ThwLgtDBzyFIo0KnDwYgRH2VfYrP/jCzKTdX3pPZ8ll60wE990Kk5yhi6OU2kSaZx5OBy2UIkDqPUcYAnloJDtwkSC7AHj6Dm4THK4wIoPDiumXI1pVJjBqBcGqYa5fEA+16IxbqaabL2cp+dJJ3MqRoGXL1si7cRKcNAiBFe2vIopqDZemn133kqsyvf38fgTMJkops4WxSUOWSFGoI9joRUcYQhl+SgUkZZK7EtBp3DpgsjhzdqHdckiXlQcMWcReTq4Bw+z5mV2/sxQcrMCVuH+NoQof7DwESf/+aTz4B1WyH8tDHl7zhDpxlwA9A4+7alXAfQcYVYb2V1C8YY8N7y6XQl1AsGoojyD3vZK6zWHm9siDmK9u13u3Mgrtb71GbZCbm+e0mbVq1cDJIyavMK99OAvrfp0IfVEOFJWj7earUKUG9mxZ45WuOzqv2Cv8vgNMcqZuCuXpWHudGb1GipvZxKuOMLwyIn5eSGSDR8AiQDtLDzZ+ALu3rTKSzPrzAMa//xK0OSlQVLHZfd8uhuDQ/p1QKDyPiFCmAaNK17KD3g/2mP/ZXxJcyeAw/xUeNT3UZPXzOe7V7tes2wx6vcFpme3btcaa5SbX2gfP56Dnk62NipiKqo7tB1at+BMPPdjE47a6kr1YVnD/rTAZ+r6U8ivscWnyVgnibnL4sT+P+l6yN/F4NMoLQLXIh2zizpRmy9PduuCP+ab3YE4h8OCjzyMzfrvDMwyjm/rVZPR8vofHHC7TgLmRpetoMFC7Ximm75TgVDJn1G96srHrw6jHnC4vQBAHqipd+zvu/2JP/Dhjsrm8zv0n4sSWHx3KYRjh0DcH44NRnt8sl2nApGTROnqD7oq9kZq1T4IjV0Q7/xc06OVE7nPg6DS2bXL+AqvW4hVEdvnEXEna2bW4uGY4pEGO99ZPPv4YZs3y3DNpmQYM42hyujaBAjbXJxvOcFhxggHGI+UD92dGeU67HDg6/SGAd36GqfHoMNTuULJaFGZexem5T4CTOL7ufCCmAf7dv0EQ11MyrWN6WmYq84C5lqEdyVF8J4hTlkQc+URZUSbMG4PowsVlSEhSO3zlBtm5+alR0UOPD+KaZ5fa0aQryM+3oi/d/ocfaYOCQudxQCeOHYUPRrxpLocZk8U0i8Wt1HSHLQ+Qy3Hj0jFjzE1Xya8Bw4IuJWfoFgJ42RWjip8TQlbVqijtbwz3dw8kfwJM23YdkaXWOOX6tMljMWzIQCuawW9/hJVrNznNt37Fr+jc8VGXI+rXgCnmjipT353w/Es80IIALDAIM56QMFBQSpmkLAUEJzmeX1qrSuBfLrnqQwJ/AkyXJ7sh+bo5ALZdLs+cPgmvDuxj9ezPFesxbETJucZexrfeeAnTv3QdQqTMAyY5TdeZEspcjdjXjfDm5Ka4REDerF1F5tos0Ev1+hNger7QGxfiLzrl3PyfpqJfb+sr4vSMTDR4qCOYy15HSVmrJs4ddx3Dp8wDRpWhvQQKYfGjvTGJCS4rK8nvPDhvt9WfADPwlUE4etx5ROpFv/6A55950mYkn+zxMv45etLpCB/esw5NGjm3Vy77gEnX+lyQIua2xFOM+hNghg8fjp17Djhl2aolc9C1i21A1x9//h3jJn3jNO+EsaPwocWFgT3isg+Y8hXGatzv51uyTz75GGvWb3E66Teu+h0dLYIlFRNfuapCs7bOgzG1a9MCW9ezKI+OU5kHTPkZxnrw72fAfP3VFPy+yK42k7mTOzf+idYt7cfB7PBkH6cmzsz/29ULhxAe5thlT5kHjOV0SUzKfp6CLwkMAnIjJjLcyo3bRZV6Kk8xxpyPIjsmqiQgYkKS5jpAzfauBFzP6Miw9Z5urdzN709bsjmzZ+K7mb84ZdWBnavR9MFGdmm+/XE+Jn7pXOy2cP536NnD8UrkX4BRaSZQSieauUnIphhl+LNWoFJpFlFKSy7yCYmLUYabRyBBpdkISp8pzkMImRitDP/c3QnvaT5/AsyyJQswYcq3Tll29O+NaBht/45HyLZs0Et9MOvbSQ7r8DfArKOUPm/BjSkxkRFWl++JKvUuSvF4CSCwO1oZ0aX4e0KSmmn2fWoBmPXRynAf2ymW9MCfALNt8zqMGD3BKWDOHt2BKKVj36+du/XD8VNnHZZRu2YNnD+xqxwwjAOJKvU1SlHiDYGgT4wywspZb8I19QUQlBhPULokJqqCecVJUKl7g8JkocS0zQiSopURUZ6uFO7m9yfA/HtoL14Z8r5TViWe2Y9qVR2HUftp7kJ84iLGjLNVqsysMKcTk2s3i67t0KXIheTsSlJK0yilJRqVFPVjoiIuW59z1Ew5q8T9EsE3McoI85km4Zq6HgjMvn4IIVRPSJVGtcMy3J30nuTzJ8AkXjiJZ3uXRD+2xzdV/BGEhzsO1JlyMxWNHnncqRDzmymfYuhg+9pS3gKMq/kqZE54pBp85sy1CjRIEmww2BfnKoKC23NEsrzk/IKc/PycRjzTzrudQoLCAi3BwH6mlH6eV5Bjjo3HEUIUitALoDBfpfDU0C+/IM+5gEAIB9ygCVGEXXeUrawpX2bcvIx2jzuPHJ167SQCA5yHZevR9w3s+9uxy9mnn+qMZQtYyFPb5Awwaek3BcUBkEg4jhQY8po2jcpyY8gtprAnuV3kTVCpPwKFOcgkIdgbrYzobJntokrTgKfUKjY4B/RvEBlRAjTT1m4Ppehk0fIxMcoI51KxO9Q3f1phaFEmHmhuNWQ2XNWknHMYpq+YePGytXhnpPkYalNGSEgwkuIOQyq11V721grjjeng0QrjqgGJKs0SSqmF/ynyfUxk+CjLfAlJWR0BYmWFKZVyHevVDPvbmk7zHUBHFv9GCPkzWhkuWOPZVVvFPPcnwFQI5lE1qrlD9jA1/bSkUy7Zl52TiwYPdkBhUZFD2u0blqBta9u6/AcwSZrzFNR8PcxR8mqDqHCm2m9O8Uma/gTUKjY4R0h0A2W4lcbfxWuaQTyhC8yAAbkQHRne2OVI3QECfwIME7pWr9sC+QUFdjkZFhqK5MR/BHH5taEfOtUa+GT0u/hk9Ds2ZfkFYG7coIo8gyabUpiDHUqItGl9ZYjV/WJikmYUBbW66A+RhgfXrEmsLJsuqXIfMlD9mZIVBoZgSXhYaTpBI+chkb8BpknLJ6BKvmGXa1WrVMbFs/sFcXT7rv3o8/Iwh7SO1GT8AjCJydmPUp4/ZMGdwmhleCghRG+11VKpp4HiI4vfNDGRETbG4JRSaaJKk8Ni9ZhBw3HtomuHHRY0Wl4kEgsYL1bt9aJcWVyyCnv1HYBz5+x78K9Zswb27NwqqF16gwGxnZ9Eerr9y01mffnv4QNQKIIElceIfKl0y+q7Y2eY+CTNOwS05NqDkKMxyvDWpTmRqNIsppRanEXIhRgHW60ElYb5I21VXAYFGd4wMtxzTwqCh8dE6G+AGfzW2zhwwPLdV8KwunXqYOtm4VpKX0+bjt//cKxs+cu8n9Gh/WOCR6TMACZRlT2PUr7E0Jtw82KUYUNLcyL+mno3ISi5hiFkV4wy/Al7HEtQZc8F5d8q2ZZx86OVYebvgrnsIaG/Aeaj/43Fhr/smxs3bBiDDWtXCubohbg49OzVzyH9kMGv46MPzXc7LsstO4BJ0hyloC3Nkxt4JzoyYnZpDiRcU8eBwOxTlFK6uGFUhVfscSoxSf02BcwrCgE5Fh0Zbl5xXHLXSwRiAXM/ayuztn88/mv8PM/qrsbMyRbNH8KeLVYSAJdcZnKd/87H26Vr3uxB7NtmrR1d5s8w7LxxUZWdQ0Etzhvk0eja4TaSq4Qko4cFs5iYI9y0Bsqw/9kFTLKmLeWp+cxCQAobKMNszkUuR8xDAn8DzLTv5mDy1B/tcq1d25bYus4+mByxedacBRg7cardxxzH4VrcYSt1/zIPmMuqzKZ6ylnatRpCpPlhNWvWtLr5unmTBmdrNbmWnCOUjIqOCv/eHjdv3LihyNUrspmzjOLnUsI3q6esaL498xALgrL7G2B+W7gcI8fYVw5/PPYxrFvO3DcIT2npGWj4cGfo9Vb3P+YCmMSfSf6LU5kHTPy17FcJ4f8o2Y6R89GR4Taepy+pNNEGShOsAYN+0VERDi2WEpM05yioWf5CKfdaw6gws3xG+LC5T+lvgNmwaQcGDravgNm9a2csX2hfpcUZh/u/+i42b9ttl2T40Ffx1eclm4wyD5jEJM131FoqvyRaGW7tuMqo7pIVSynZa8k1Cr5jw8iKVlJ+y+elb9UIyPfRpbQH3IeCsJz+BphDR46jW0+7x0qj4RczABObNm7ZhZdef89uNmaMxozS/GaFSVSp91KKWAtufBQTGTG9NHcuXtf05w3WUn4CNIiOjHAYhTQhST0agFmHjBDsi1ZGlOiYiR05N+j9DTDxiZfRqoOVzZ+Za/369MD8WfbPI85Yq9Pp0fDhTmDumEondo5hZssRtzWgy/QKw1T5L6o0WZbq+pTiiYZRETYWQolJ2R9Q8DMsGRakDFcoCbGvhwEg/pq6CyEwO7MigKaBMrwCU/l3Y+67lcXfAMNC9tVp1M4ur159uQ9mznBsLemMwWMnTMOsueaduxXp0j9m4ZluJpvCMg2YxCR1fQqY9cDYRA4MC6usDCc2r5KEJDVbKdiKUZzUMZERFZwxWaXSVCwE0i1tbFytSm6hwkkmR4Cxp9rPirnfr5WZM75KymYwGGw99Qr1XmmPnefjEtG2k6UxbgmV5TmmbAMmWd2H8jBLsgjBtWhlhN1wuglJmiWAlTbz+Rg7lwOlmZ2oUl+lFGaLS8Khb3TtCLNFprcBUro8fwMM6z/zYpmaZutc/L23X8eUCZaaTeK437l7Pxw/aWu+3Oyhxvh7h2lIyzZgktRTKGCOY0kI1kUrI+xaICUkqZl715LzB8WumKgIu1J+y2FIVKnXUgqzTT8BvoyOjHBsbCFuDF1SiwWMywLvIoEQXTLWvB49+yAhwcpsydjqYUOHYNT79g/vQrq1bPkqTPj8CxtSdo759/DfCA1lLrcdp/te0p+g0myCRWhx5jGmYVQFu5f4CSpNHCg1S/kJIYuileGDXDE6/lrWBOY5xkxHyOYYZbjZq4yr/J4+90fAvPbGWzh8xFaNf8S772D4OzYaT4JZnJubi/Ydu9gNqTF39kx0irX1qGlZuM8Bc+PGZa86k8jVVzwGwOwRQQLD4CCpxq5LkFxDxXOgCC5mAOEwO5jLdHnlUqAP72KA5FcLxqWHSDPNajiCR8tNwlx9xav2sjo6w9ymTeCobjTR3bpjQlaDvLbddjnrptAV5oPRH2PTZlsPmLVrVv1q7+bf57rJSmO2Zu36TM3LLzArmAVWqo+qD/dD96c6Y1T3CiASx/F1JNpku9t9T9rjLO8d01a+Uw0uL/fucCCoSqPvCYGN9JJS8n5B2nn7ejMCmxpUpUl7TsL9HRHdBVWbD0CYspXRNZA+Lz394IQq91SI4HLACBxUfydTVGs8FpROseUDHZafGufRCtNxOh1nyM+YKFVUMqs86fLSaW7y0U1n5j/teahlLw5eOWC8yMyyXJSiWqMhoLBRGiOUvpaXFueRalLsdPongAGMfwUZl6G4sARtcw4e/XrXNhv7qbvN43sCMGcSUyy1Asw8aRpdw+gcw9FzMcwrLktMnnLaEg4oqjV8DpSzsRSjPAYUpF9Y5gmvOs2gbXke069tm8A9l7enaYNQWXCAhKMNK4ZFdl6yxqHfO0/qdDfvPQEYdxtfns93HIj9xpBm0BVUpgYteH0ReL0W1FAEWXDl/w5+VvEhIS1JSbli98VYnLdGjbr7furWZVGYXDawYlAAgmTSMY8vXn1XXGk56k+ZBYw3ViV7TLvXVipXk1DIRHZGwyYxex47nf4LwJ6xXuK+0cR5CDERjdjzWs8IXsvdvJRTGDDt7HXt9QLtmIJbF34QUcQdJS2zgLmjXPPHwmu2UCj0+SxYr1XiCN8l91a8fT19kXwqBv9Xg975fuHZaw9reZN6YLWqlfYe2rGoRO4motxiwIvI4pS0HDDe4qSflDPrqS5aA6UyAtAR23dz3u52gyffH3vj9HYWrcE0Nyl0lCOjC255dnXtrXaWA8ZbnPSTcna/3PsyBa0LILPLkjWVvN3tyk2emp+fljTEVC5N43j0zU2Ps/KM6u06xZRXDhgx3Cqnxe6Xe12gYKFJSF6XJaudK3qJ5xdRVG3ETNvZJcI5nqPPFt6ME629IL5a4TnKNGAopfLkbIRIDAgBj2BQnUJPiUIqQRD7JNSgAIgCBIGUkkCOIIAHH0gIFwBKAkH5QEogJwRyUCKn4OWEcDJCIQeBnFLIACoFAfOgLQX7TnH7O5UCHAdQCQjhQKkEIKbvAGf8m4DAFAqEEGIcCnLbbMH4m3FDAtDbtj70dtADCmb7w/6B8gB4gBiMfxNiAGW/se8sogLRg0IPYvyvA2D6DqIn7DuFlhJoKeV1BJwWhGophZZQaEG4QhBaSClfxIEr/HbR1mZrli2unp/8X6tcHW92bhJdv/6cLRvW/AIiyweHPIMEubXDkEsI0QqfhibK4KqNXqEA86hxOF9X1B1Zl5mDlHsq3dOASU2lIQYZKuv0usrgSCUJIRUBvgLlSQVKEMGBhPOgEaB8OEDCKBBGYAyJEUKBEAI2ocuTOxw4dfoMzp0/j/j4RJw5+x/i4uJZGBKbotq0boWFf9jGwKSAjgDMwUkuBXIIkA3QbBBOw4GoeVANoVATjmYBXJaB0syWrR79SSaX33rhuef7zpr2P/u+ad3pjBfz3BXAUEq5lCzUNhj0dQmhUQBRArQWBalBCGoAtBqlqAZAuM9QLzKlvCjgzaHDceCgydslc+Eqk8nNoSiYIRn7r9PpUCEiAn/vMxvAepN1BYTgFkBuUYoUApoCEBYcWEUpuSaRSK/UqIBkQghbZX2W7jhgKKWylCx9WwOPdoTQhylIE0IRbemzzGe9La+oTHGA+aWjBIkE9Byl5JSEw6EaFaRHCCFs+3lH0h0FTHK6bjIFhoNtm8pTOQd8wgGiJsBPtSvLrAIPe6vqOw8YguGg5YDx1oCVl+OCA4SoCb1PAcO6Zt6SAe0IpQ9TigcBRANwHhSxfGaUc8A1B1g4s0RC8B8l5JQE9/mWzFF/iw/9hOjrGkCiYKDmQz9AaxKCqpSSagAtP/S7njRllIIUEELZgT+VgqZwIDeMh34JUUlAr1FaRg/9noxm8bUy1esq6+1cK5vORiS8/FrZEy7fmbzOrpUBqgGImhCoCUqulaU8zSBSWbpEh/SqVYmVz+0700rxpd7RM4z45ng3hz3BJSREoadQSDkSZKBQgPIKUAeCS8IHMiElE16aBZeAnICTWQouCYHUJMQ0Ci9vCy6JlIJKOJOAkqNMcGkrwCTMFJdYCCwtBZilBZbsO5NWwiQPoaUFlsQouGQSS8oTkzCzRHAJGIWVtLTgEryOAtpiwSUTWjJhJqi14JKnKCKEFoKgEITLlxDk63laICXIh4Hme0Nw6d3RvzOl/R8AdGoXzom1qQAAAABJRU5ErkJggg=="},16722:function(ln,Ft,ie){"use strict";ie.d(Ft,{Z:function(){return Re}});const z=Oe=>typeof Oe=="object"&&Oe!=null&&Oe.nodeType===1,Ke=(Oe,fe)=>(!fe||Oe!=="hidden")&&Oe!=="visible"&&Oe!=="clip",ve=(Oe,fe)=>{if(Oe.clientHeight<Oe.scrollHeight||Oe.clientWidth<Oe.scrollWidth){const We=getComputedStyle(Oe,null);return Ke(We.overflowY,fe)||Ke(We.overflowX,fe)||(Se=>{const yt=(Xe=>{if(!Xe.ownerDocument||!Xe.ownerDocument.defaultView)return null;try{return Xe.ownerDocument.defaultView.frameElement}catch(Le){return null}})(Se);return!!yt&&(yt.clientHeight<Se.scrollHeight||yt.clientWidth<Se.scrollWidth)})(Oe)}return!1},Ae=(Oe,fe,We,Se,yt,Xe,Le,Ge)=>Xe<Oe&&Le>fe||Xe>Oe&&Le<fe?0:Xe<=Oe&&Ge<=We||Le>=fe&&Ge>=We?Xe-Oe-Se:Le>fe&&Ge<We||Xe<Oe&&Ge>We?Le-fe+yt:0,ye=Oe=>{const fe=Oe.parentElement;return fe==null?Oe.getRootNode().host||null:fe},be=(Oe,fe)=>{var We,Se,yt,Xe;if(typeof document=="undefined")return[];const{scrollMode:Le,block:Ge,inline:Ne,boundary:dt,skipOverflowHiddenElements:It}=fe,Bt=typeof dt=="function"?dt:wt=>wt!==dt;if(!z(Oe))throw new TypeError("Invalid target");const mt=document.scrollingElement||document.documentElement,st=[];let it=Oe;for(;z(it)&&Bt(it);){if(it=ye(it),it===mt){st.push(it);break}it!=null&&it===document.body&&ve(it)&&!ve(document.documentElement)||it!=null&&ve(it,It)&&st.push(it)}const je=(Se=(We=window.visualViewport)==null?void 0:We.width)!=null?Se:innerWidth,Ot=(Xe=(yt=window.visualViewport)==null?void 0:yt.height)!=null?Xe:innerHeight,{scrollX:nt,scrollY:tt}=window,{height:ht,width:$e,top:at,right:lt,bottom:me,left:At}=Oe.getBoundingClientRect(),{top:De,right:He,bottom:Pt,left:ge}=(wt=>{const Ie=window.getComputedStyle(wt);return{top:parseFloat(Ie.scrollMarginTop)||0,right:parseFloat(Ie.scrollMarginRight)||0,bottom:parseFloat(Ie.scrollMarginBottom)||0,left:parseFloat(Ie.scrollMarginLeft)||0}})(Oe);let ce=Ge==="start"||Ge==="nearest"?at-De:Ge==="end"?me+Pt:at+ht/2-De+Pt,Je=Ne==="center"?At+$e/2-ge+He:Ne==="end"?lt+He:At-ge;const jt=[];for(let wt=0;wt<st.length;wt++){const Ie=st[wt],{height:Ue,width:et,top:cn,right:kt,bottom:Yt,left:ze}=Ie.getBoundingClientRect();if(Le==="if-needed"&&at>=0&&At>=0&&me<=Ot&<<=je&&(Ie===mt&&!ve(Ie)||at>=cn&&me<=Yt&&At>=ze&<<=kt))return jt;const zt=getComputedStyle(Ie),ut=parseInt(zt.borderLeftWidth,10),ae=parseInt(zt.borderTopWidth,10),te=parseInt(zt.borderRightWidth,10),ee=parseInt(zt.borderBottomWidth,10);let oe=0,se=0;const ne="offsetWidth"in Ie?Ie.offsetWidth-Ie.clientWidth-ut-te:0,he="offsetHeight"in Ie?Ie.offsetHeight-Ie.clientHeight-ae-ee:0,xe="offsetWidth"in Ie?Ie.offsetWidth===0?0:et/Ie.offsetWidth:0,ot="offsetHeight"in Ie?Ie.offsetHeight===0?0:Ue/Ie.offsetHeight:0;if(mt===Ie)oe=Ge==="start"?ce:Ge==="end"?ce-Ot:Ge==="nearest"?Ae(tt,tt+Ot,Ot,ae,ee,tt+ce,tt+ce+ht,ht):ce-Ot/2,se=Ne==="start"?Je:Ne==="center"?Je-je/2:Ne==="end"?Je-je:Ae(nt,nt+je,je,ut,te,nt+Je,nt+Je+$e,$e),oe=Math.max(0,oe+tt),se=Math.max(0,se+nt);else{oe=Ge==="start"?ce-cn-ae:Ge==="end"?ce-Yt+ee+he:Ge==="nearest"?Ae(cn,Yt,Ue,ae,ee+he,ce,ce+ht,ht):ce-(cn+Ue/2)+he/2,se=Ne==="start"?Je-ze-ut:Ne==="center"?Je-(ze+et/2)+ne/2:Ne==="end"?Je-kt+te+ne:Ae(ze,kt,et,ut,te+ne,Je,Je+$e,$e);const{scrollLeft:Ee,scrollTop:Fe}=Ie;oe=ot===0?0:Math.max(0,Math.min(Fe+oe/ot,Ie.scrollHeight-Ue/ot+he)),se=xe===0?0:Math.max(0,Math.min(Ee+se/xe,Ie.scrollWidth-et/xe+ne)),ce+=Fe-oe,Je+=Ee-se}jt.push({el:Ie,top:oe,left:se})}return jt},Me=Oe=>Oe===!1?{block:"end",inline:"nearest"}:(fe=>fe===Object(fe)&&Object.keys(fe).length!==0)(Oe)?Oe:{block:"start",inline:"nearest"};function Re(Oe,fe){if(!Oe.isConnected||!(yt=>{let Xe=yt;for(;Xe&&Xe.parentNode;){if(Xe.parentNode===document)return!0;Xe=Xe.parentNode instanceof ShadowRoot?Xe.parentNode.host:Xe.parentNode}return!1})(Oe))return;const We=(yt=>{const Xe=window.getComputedStyle(yt);return{top:parseFloat(Xe.scrollMarginTop)||0,right:parseFloat(Xe.scrollMarginRight)||0,bottom:parseFloat(Xe.scrollMarginBottom)||0,left:parseFloat(Xe.scrollMarginLeft)||0}})(Oe);if((yt=>typeof yt=="object"&&typeof yt.behavior=="function")(fe))return fe.behavior(be(Oe,fe));const Se=typeof fe=="boolean"||fe==null?void 0:fe.behavior;for(const{el:yt,top:Xe,left:Le}of be(Oe,Me(fe))){const Ge=Xe-We.top+We.bottom,Ne=Le-We.left+We.right;yt.scroll({top:Ge,left:Ne,behavior:Se})}}}}]);
|