You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
NewEduCoderBuild/p__Classrooms__Lists__Gradu...

1 line
105 KiB

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

(self.webpackChunk=self.webpackChunk||[]).push([[3317,50439,5249],{83156:function(module,exports,__webpack_require__){var __WEBPACK_AMD_DEFINE_ARRAY__,__WEBPACK_AMD_DEFINE_RESULT__,_typeof=__webpack_require__(31468).default;(function(){if("function"!=typeof window.GGBApplet){var isRenderGGBElementEnabled=!1,scriptLoadStarted=!1,html5AppletsToProcess=null,ggbHTML5LoadedCodebaseIsWebSimple=!1,ggbHTML5LoadedCodebaseVersion=null,ggbHTML5LoadedScript=null,GGBApplet=function(){"use strict";for(var e={},l="5.0",t={},n=null,a=!1,i=!1,o=null,r=!1,s=null,u=null,c=0;c<arguments.length;c++){var d=arguments[c];if(null!==d)switch(_typeof(d)){case"number":l=d.toFixed(1);break;case"string":d.match(new RegExp("^[0-9]\\.[0-9]+$"))?l=d:o=d;break;case"object":void 0!==d.is3D?n=d:t=d;break;case"boolean":a=d,i=!0}}null===n&&(n={is3D:!1,AV:!1,SV:!1,CV:!1,EV2:!1,CP:!1,PC:!1,DA:!1,FI:!1,PV:!1,macro:!1},void 0===t.material_id||i||(a=!0)),null!==o&&void 0===t.id&&(t.id=o);var p="",v=!1,f=null,h=null,b=null,m=!1,g=null,w=null,y=null;void 0!==t.height&&(t.height=Math.round(t.height)),void 0!==t.width&&(t.width=Math.round(t.width));var x=function(e){return parseFloat(e)>4?parseFloat(e):5};function _(){try{return window.self!==window.top}catch(e){return!0}}function k(){return(!t.hasOwnProperty("screenshotGenerator")||!t.screenshotGenerator)&&Math.max(screen.width,screen.height)<800}e.setHTML5Codebase=function(e,l){u=e,R(e,l)},e.setJavaCodebase=e.setJavaCodebaseVersion=e.isCompiledInstalled=e.setPreCompiledScriptPath=e.setPreCompiledResourcePath=function(){},e.setHTML5CodebaseVersion=function(e,l){var t=parseFloat(e);NaN!==t&&t<5?console.log("The GeoGebra HTML5 codebase version "+t+" is deprecated. Using version latest instead."):(s=e,O(e,l))},e.getHTML5CodebaseVersion=function(){return h},e.getParameters=function(){return t},e.setFontsCSSURL=function(e){y=e},e.setGiacJSURL=function(e){},e.setJNLPFile=function(e){e},e.setJNLPBaseDir=function(e){},e.inject=function(){function l(){return window.frameElement&&window.frameElement.getAttribute("data-singleton")}for(var n,a="auto",i=t.id,o=!1,s=0;s<arguments.length;s++){var u=arguments[s];"string"==typeof u?(u=u.toLowerCase()).match(/^(prefer)?(java|html5|compiled|auto|screenshot)$/)?a=u:i=arguments[s]:"boolean"==typeof u?o=u:u instanceof HTMLElement&&(n=u)}function c(){if(r){a=A(a);var s=n||document.getElementById(i);if(s)if(e.removeExistingApplet(s,!1),void 0===t.width&&s.clientWidth&&(t.width=s.clientWidth),void 0===t.height&&s.clientHeight&&(t.height=s.clientHeight),t.width&&t.height||"html5"!==a||(delete t.width,delete t.height),f=a,"screenshot"===a)P(s,t);else{var u=!1;t.hasOwnProperty("playButton")&&t.playButton||t.hasOwnProperty("clickToLoad")&&t.clickToLoad?u=!0:t.hasOwnProperty("playButtonAutoDecide")&&t.playButtonAutoDecide&&(u=(!_()||l())&&k()),u?(f="screenshot",E(s,t,o,a)):j(s,t,o)}else console.log("possibly bug on ajax loading? ")}else setTimeout(c,200)}c()},e.getViews=function(){return n},e.isJavaInstalled=function(){return!1};var S=function(l){var a=function(){t.onError&&t.onError(),Z("Error: Fetching material (id "+t.material_id+") failed.",t)},i=location.host.match(/(www|stage|beta|groot|alpha).geogebra.(org|net)/)?location.host:"www.geogebra.org",o="/materials/"+t.material_id+"?scope=basic";T("https://"+i+"/api/proxy.php?path="+encodeURIComponent(o),(function(i){var o=JSON.parse(i),r=o.elements?o.elements.filter((function(e){return"G"==e.type||"E"==e.type}))[0]:o;if(r&&r.url){t.fileName=r.url,B(r.settings||{}),n.is3D=!0;var s="https://www.geogebra.org/images/";e.setPreviewImage(g||r.previewUrl,s+"GeoGebra_loading.png",s+"applet_play.png"),l()}else a()}),a)};function B(e){["enableLabelDrags","enableShiftDragZoom","enableRightClick"].forEach((function(l){e[l]=!!e[l]})),["width","height","showToolBar","showMenuBar","showAlgebraInput","allowStyleBar","showResetIcon","enableLabelDrags","enableShiftDragZoom","enableRightClick","appName"].forEach((function(l){void 0===t[l]&&void 0!==e[l]&&(t[l]=e[l])})),void 0===t.showToolBarHelp&&(t.showToolBarHelp=t.showToolBar)}function T(e,l,t){var n=new XMLHttpRequest;n.open("GET",e),n.onload=function(){l(n.responseText)},n.onerror=t,n.send()}e.isHTML5Installed=function(){return!0},e.getLoadedAppletType=function(){return f},e.setPreviewImage=function(e,l,t){g=e,w=l,t},e.removeExistingApplet=function(e,l){var n;"string"==typeof e&&(e=document.getElementById(e)),f=null;var a=null;for(n=0;n<e.childNodes.length;n++){var i=e.childNodes[n],o=i.className;"applet_screenshot"===o?l?(i.style.display="block",f="screenshot"):i.style.display="none":"applet_scaler prerender"!==o&&(e.removeChild(i),a=o&&-1!=o.indexOf("appletParameters")?i.id:null,n--)}var r=void 0!==t.id?t.id:a,s=window[r];s&&"function"==typeof s.getBase64&&(s.remove(),window[r]=null)},e.refreshHitPoints=function(){if(x(ggbHTML5LoadedCodebaseVersion)>=5)return!0;var l=e.getAppletObject();return!(!l||"function"!=typeof l.recalculateEnvironments)&&(l.recalculateEnvironments(),!0)},e.startAnimation=function(){var l=e.getAppletObject();return!(!l||"function"!=typeof l.startAnimation)&&(l.startAnimation(),!0)},e.stopAnimation=function(){var l=e.getAppletObject();return!(!l||"function"!=typeof l.stopAnimation)&&(l.stopAnimation(),!0)},e.getAppletObject=function(){var e=void 0!==t.id?t.id:"ggbApplet";return window[e]},e.resize=function(){};var C=function(e){return e&&"false"!==e},j=function(l,t,n){x(h)<=4.2&&(n=!0);var a=!isRenderGGBElementEnabled&&!scriptLoadStarted;(!isRenderGGBElementEnabled&&!scriptLoadStarted||ggbHTML5LoadedCodebaseVersion!==h||ggbHTML5LoadedCodebaseIsWebSimple&&!m)&&(a=!0,isRenderGGBElementEnabled=!1,scriptLoadStarted=!1);var i=document.createElement("div");i.classList.add("appletParameters","notranslate");var o=t.width,r=t.height;if(t.disableAutoScale=void 0===t.disableAutoScale?GGBAppletUtils.isFlexibleWorksheetEditor():t.disableAutoScale,void 0!==t.width)if(x(h)<=4.4)C(t.showToolBar)&&(t.height-=7),C(t.showAlgebraInput)&&(t.height-=37),t.width<605&&C(t.showToolBar)&&(t.width=605,o=605);else{var c=100;(C(t.showToolBar)||C(t.showMenuBar))&&(t.hasOwnProperty("customToolBar")&&(t.customToolbar=t.customToolBar),c=C(t.showMenuBar)?245:155),o<c&&(t.width=c,o=c)}for(var d in i.style.border="none",i.style.display="inline-block",t)t.hasOwnProperty(d)&&"appletOnLoad"!==d&&i.setAttribute("data-param-"+d,t[d]);y&&i.setAttribute("data-param-fontscssurl",y),e.resize=function(){GGBAppletUtils.responsiveResize(l,t)},window.addEventListener("resize",(function(l){e.resize()}));var v="function"==typeof t.appletOnLoad?t.appletOnLoad:function(){};if(n||void 0===t.width){var f=document.createElement("div");f.className="applet_scaler",f.style.position="relative",f.style.display="block",f.appendChild(i),l.appendChild(f),t.appletOnLoad=function(l){e.resize(),v(l)}}else{t.hasOwnProperty("showSplash")||i.setAttribute("data-param-showSplash","false");var g=l.querySelector(".applet_scaler.prerender"),w=null!==g;if(w)_=g.querySelector(".ggb_preview");else{var _=M(o,r,t.borderColor,!1);(g=document.createElement("div")).className="applet_scaler",g.style.position="relative",g.style.display="block",g.style.width=o+"px",g.style.height=r+"px"}window.GGBT_spinner&&window.GGBT_spinner.attachSpinner(g,"66%"),x(h)>=5?(t.appletOnLoad=function(e){var t=l.querySelector(".ggb_preview");t&&t.parentNode.removeChild(t),window.GGBT_spinner&&window.GGBT_spinner.removeSpinner(g),window.GGBT_wsf_view&&$(window).trigger("resize"),v(e)},w||g.appendChild(_)):i.appendChild(_),g.appendChild(i),w||l.appendChild(g),setTimeout((function(){e.resize()}),1)}function k(e,l){l&&"function"==typeof l.appletOnLoad&&"function"==typeof renderGGBElement?renderGGBElement(e,l.appletOnLoad):renderGGBElement(e),Z("GeoGebra HTML5 applet injected and rendered with previously loaded codebase.",l)}function S(e,l){"undefined"==typeof renderGGBElement?(null===html5AppletsToProcess&&(html5AppletsToProcess=[]),html5AppletsToProcess.push({article:e,params:l}),window.renderGGBElementReady=function(){isRenderGGBElementEnabled=!0,null!==html5AppletsToProcess&&html5AppletsToProcess.length&&(html5AppletsToProcess.forEach((function(e){k(e.article,e.params)})),html5AppletsToProcess=null)},x(h)<5&&(e.className+=" geogebraweb")):k(e,l)}if(a){scriptLoadStarted=!0;for(var B=0;B<i.childNodes.length;B++){"TABLE"===i.childNodes[B].tagName&&(i.removeChild(i.childNodes[B]),B--)}if(null!==ggbHTML5LoadedScript){var T=document.querySelector('script[src="'+ggbHTML5LoadedScript+'"]');null!=T&&T.parentNode.removeChild(T)}var j=document.createElement("script"),P=function(){S(i,t)};j.src=p+b,ggbHTML5LoadedCodebaseIsWebSimple=m,ggbHTML5LoadedCodebaseVersion=h,ggbHTML5LoadedScript=j.src,Z("GeoGebra HTML5 codebase loaded: '"+p+"'.",t),u||s&&"5.0"!=s?p.requirejs?__webpack_require__.e(58162).then(function(){var e=[__webpack_require__(58162)];P.apply(null,e)}.bind(this)).catch(__webpack_require__.oe):(j.onload=P,l.appendChild(j)):(m?webSimple.succeeded=webSimple.succeeded||webSimple():web3d.succeeded=web3d.succeeded||web3d(),P())}else S(i,t);t.height=r,t.width=o},P=function(l,t,n){var a=M(t.width,t.height,t.borderColor,n),i=document.createElement("div");i.style.position="relative",i.style.display="block",i.style.width=t.width+"px",i.style.height=t.height+"px",i.className="applet_screenshot applet_scaler"+(n?" applet_screenshot_play":""),i.appendChild(a);var o=GGBAppletUtils.getScale(t,l,n);n?(l.appendChild(N()),window.GGBT_wsf_view||(l.style.position="relative")):window.GGBT_spinner&&window.GGBT_spinner.attachSpinner(i,"66%"),l.appendChild(i),1===o||isNaN(o)||(GGBAppletUtils.scaleElement(i,o),i.style.width=t.width+"px",i.style.height=t.height+"px",i.parentNode.style.width=t.width*o+"px",i.parentNode.style.height=t.height*o+"px"),e.resize=function(){L(l,a,i,n)},window.addEventListener("resize",(function(l){e.resize()})),e.resize()};function L(e,l,n,a){if(e.contains(l)){if("object"===_typeof(window.GGBT_wsf_view)&&window.GGBT_wsf_view.isFullscreen()){if("fullscreencontent"!==e.id)return;window.GGBT_wsf_view.setCloseBtnPosition(e)}var i=GGBAppletUtils.getScale(t,e,a);null!==n.parentNode&&(isNaN(i)||1===i?(GGBAppletUtils.scaleElement(n,1),n.parentNode.style.width=t.width+"px",n.parentNode.style.height=t.height+"px"):(GGBAppletUtils.scaleElement(n,i),n.parentNode.style.width=t.width*i+"px",n.parentNode.style.height=t.height*i+"px")),"object"===_typeof(window.GGBT_wsf_view)&&window.GGBT_wsf_view.isFullscreen()&&GGBAppletUtils.positionCenter(e),"object"===_typeof(window.GGBT_ws_header_footer)&&window.GGBT_ws_header_footer.setWsScrollerHeight()}}e.onExitFullscreen=function(e,l){l.appendChild(e)};var E=function(e,l,t,n){P(e,l,!0);for(var a=function(){var t=[];for(o=0;o<e.childNodes.length;o++)t.push(e.childNodes[o]);if(window.GGBT_wsf_view){var a=window.GGBT_wsf_view.renderFullScreen(e,l.id),i=document.getElementById("fullscreencontainer"),r=jQuery(e).find(".fullscreencontent");r.length>0?(a.remove(),r.attr("id","fullscreencontent").show(),jQuery(i).append(r),window.dispatchEvent(new Event("resize"))):j(a,l,!1),window.GGBT_wsf_view.launchFullScreen(i)}else f=n,j(e,l,!1);if(!window.GGBT_wsf_view)for(o=0;o<t.length;o++)e.removeChild(t[o])},i=e.getElementsByClassName("ggb_preview_play"),o=0;o<i.length;o++)i[o].addEventListener("click",a,!1),i[o].addEventListener("ontouchstart",a,!1);"function"==typeof window.ggbAppletPlayerOnload&&window.ggbAppletPlayerOnload(e),k()&&window.GGBT_wsf_view&&$(".wsf-element-fullscreen-button").remove()},N=function(){var e=document.createElement("div");if(e.className="ggb_preview_play icon-applet-play",!window.GGBT_wsf_view){var l='.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");}',t=document.createElement("style");t.styleSheet?t.styleSheet.cssText=l:t.appendChild(document.createTextNode(l)),document.getElementsByTagName("head")[0].appendChild(t)}return e},M=function(e,l,t,n){var a=document.createElement("div");a.className="ggb_preview",a.style.position="absolute",a.style.zIndex="90",a.style.width=e-2+"px",a.style.height=l-2+"px",a.style.top="0px",a.style.left="0px",a.style.overflow="hidden",a.style.backgroundColor="white";var i="lightgrey";void 0!==t&&(i="none"===t?"transparent":t),a.style.border="1px solid "+i;var o,r,s,u=document.createElement("img");if((u.style.position="relative",u.style.zIndex="1000",u.style.top="-1px",u.style.left="-1px",null!==g&&u.setAttribute("src",g),u.style.opacity=.7,null!==w)&&!n){(o=document.createElement("img")).style.position="absolute",o.style.zIndex="1001",o.style.opacity=1,u.style.opacity=.3,(r=360)>e/4*3&&(r=e/4*3),s=r/5.8,o.setAttribute("src",w),o.setAttribute("width",r),o.setAttribute("height",s);var c=(e-r)/2,d=(l-s)/2;o.style.left=c+"px",o.style.top=d+"px",a.appendChild(o)}return a.appendChild(u),a},A=function(e){return"html5"===(e=e.toLowerCase())||"screenshot"===e?e:"html5"},G=["web","webSimple","web3d","tablet","tablet3d","phone"],O=function(e,l){if(h=e,l)R(h,!0);else{var i,o,r=!a;if(r){var s=x(h);!isNaN(s)&&s<4.4&&(r=!1)}i="http"===window.location.protocol.substr(0,4)?window.location.protocol:"http:";var u=h.indexOf("//");for(var c in o=u>0?h:0===u?i+h:"https://www.geogebra.org/apps/5.2.814.0/",G)if(h.slice(-1*G[c].length)===G[c]||h.slice(-1*(G[c].length+1))===G[c]+"/")return void R(o,!1);GGBAppletUtils.isFlexibleWorksheetEditor()||!r||n.is3D||n.AV||n.SV||n.CV||n.EV2||n.CP||n.PC||n.DA||n.FI||n.PV||C(t.showToolBar)||C(t.showMenuBar)||C(t.showAlgebraInput)||C(t.enableRightClick)||t.appName&&"classic"!=t.appName?o+="web3d/":o+="webSimple/",R(o,!1)}},R=function(e,l){if(e.requirejs)p=e;else{"/"!==e.slice(-1)&&(e+="/"),p=e,null===l&&(l=-1===e.indexOf("http")),v=l,b="web.nocache.js",m=!1;var t=p.split("/");t.length>1&&(l||"webSimple"!==t[t.length-2]?G.indexOf(t[t.length-2])>=0&&(b=t[t.length-2]+".nocache.js"):(b="webSimple.nocache.js",m=!0)),t=e.split("/"),"test"===(h=t[t.length-3]).substr(0,4)?h=h.substr(4,1)+"."+h.substr(5,1):"war"!==h.substr(0,3)&&"beta"!==h.substr(0,4)||(h="5.0");var n=parseFloat(h);NaN!==n&&n<5&&e.indexOf("geogebra.org")>=0&&(console.log("The GeoGebra HTML5 codebase version "+n+" is deprecated. Using version latest instead."),O("5.0",l))}},Z=function(e,l){window.console&&window.console.log&&(!l||void 0===l.showLogging||l.showLogging&&"false"!==l.showLogging)&&console.log(e)};function I(){var e=l;null!==s?e=s:parseFloat(e)<5&&(e="5.0"),O(e,!1),null!==u&&R(u,v),r=!0}return void 0!==t.material_id?S(I):I(),e},GGBAppletUtils=function(){"use strict";function e(){return void 0!==window.GGBT_wsf_edit}function l(e,l){1!=l?(e.style.transformOrigin="0% 0% 0px",e.style.webkitTransformOrigin="0% 0% 0px",e.style.transform="scale("+l+","+l+")",e.style.webkitTransform="scale("+l+","+l+")",e.style.maxWidth="initial",null!==e.querySelector(".ggb_preview")&&(e.querySelector(".ggb_preview").style.maxWidth="initial"),void 0!==e.querySelectorAll(".ggb_preview img")[0]&&(e.querySelectorAll(".ggb_preview img")[0].style.maxWidth="initial"),void 0!==e.querySelectorAll(".ggb_preview img")[1]&&(e.querySelectorAll(".ggb_preview img")[1].style.maxWidth="initial")):(e.style.transform="none",e.style.webkitTransform="none")}function t(e,l,t,n,a){if(e.isScreenshoGenerator)return 1;var i,o=void 0!==n&&n,r=null!=e.noScaleMargin&&e.noScaleMargin,s=(i=e.autoHeight)&&"false"!==i,u=function(e,l,t,n,a,i){var o=null;if(null!=i&&""!=i)for(var r=e.parentNode;null!=r;){if((" "+r.className+" ").indexOf(" "+i+" ")>-1){o=r;break}r=r.parentNode}var s=0,u=0,c=0,d=0,p=0,v=0,f=0;if(o)s=o.offsetWidth,u=Math.max(n?o.offsetWidth:0,o.offsetHeight);else{if(window.innerWidth&&document.documentElement.clientWidth?(s=Math.min(window.innerWidth,document.documentElement.clientWidth),u=Math.min(window.innerHeight,document.documentElement.clientHeight),c=s):(s=window.innerWidth,u=window.innerHeight,c=window.innerWidth),e){var h=e.getBoundingClientRect();h.left>0&&h.left<=s&&(void 0===a||!a)&&("rtl"===document.dir?(p=s-h.width-h.left,v=c<=480?10:30):(v=h.left,p=c<=480?10:30),d=v+p)}e&&"object"===_typeof(window.GGBT_wsf_view)&&window.GGBT_wsf_view.isFullscreen()&&(e.getBoundingClientRect(),"closePositionRight"===window.GGBT_wsf_view.getCloseBtnPosition()?(d=40,f=0):"closePositionTop"===window.GGBT_wsf_view.getCloseBtnPosition()&&(d=0,f=40))}return e&&((void 0===t||!t)&&l>0&&l+d<s?s=l:s-=d,"object"!==_typeof(window.GGBT_wsf_view)||!window.GGBT_wsf_view.isFullscreen()||void 0!==t&&t||(u-=f)),{width:s,height:u}}(l,e.width,t,s,o&&window.GGBT_wsf_view||r,a),c=parseInt(u.width),d=e.width,p=e.height;if(void 0===d){var v=l.querySelector(".appletParameters");v&&(d=v.offsetWidth,p=v.offsetHeight)}var f=c/d,h=o?1:u.height/p;return void 0===t||t||(f=Math.min(1,f),h=Math.min(1,h)),Math.min(f,h)}function n(e,l,n){var a,i=1,o=!1;return e.hasOwnProperty("allowUpscale")&&(o=e.allowUpscale),e.hasOwnProperty("scale")&&(i=parseFloat(e.scale),(isNaN(i)||null===i||0===i)&&(i=1),i>1&&(o=!0)),l&&"object"===_typeof(window.GGBT_wsf_view)&&window.GGBT_wsf_view.isFullscreen()&&(o=!0),e.hasOwnProperty("disableAutoScale")&&e.disableAutoScale?i:(a=t(e,l,o,n,e.scaleContainerClass),!o||e.hasOwnProperty("scale")&&1!==i?Math.min(i,a):a)}function a(e){var l=Math.min(window.innerWidth,document.documentElement.clientWidth),t=Math.min(window.innerHeight,document.documentElement.clientHeight),n=e.getBoundingClientRect(),a=(l-n.width)/2,i=(t-n.height)/2;i<0&&(i=0),e.style.position="relative","closePositionRight"===window.GGBT_wsf_view.getCloseBtnPosition()?(e.style.left=a<40?"40px":a+"px",e.style.top=i+"px"):"closePositionTop"===window.GGBT_wsf_view.getCloseBtnPosition()&&(e.style.top=i<40?"40px":i+"px",e.style.left=a+"px")}return{responsiveResize:function(t,i){var o=t.querySelector(".appletParameters");if(o){if("object"===_typeof(window.GGBT_wsf_view)&&window.GGBT_wsf_view.isFullscreen()){if(i.id!==o.getAttribute("data-param-id"))return;window.GGBT_wsf_view.setCloseBtnPosition(t)}if(o.parentElement&&/fullscreen/.test(o.parentElement.className))return;var r=n(i,t);e()&&o.setAttribute("data-param-scale",r);for(var s=null,u=0;u<t.childNodes.length;u++)if(void 0!==t.childNodes[u].className&&t.childNodes[u].className.match(/^applet_scaler/)){s=t.childNodes[u];break}if(null!==s&&null!==s.querySelector(".noscale"))return;var c=void 0!==i.id?i.id:"ggbApplet",d=window[c];null!=d&&d.recalculateEnvironments||null===s||s.className.match(/fullscreen/)||(s.parentNode.style.transform="",isNaN(r)||1===r?(l(s,1),s.parentNode.style.width=i.width+"px",s.parentNode.style.height=i.height+"px"):(s.parentNode.style.width=i.width*r+"px",s.parentNode.style.height=i.height*r+"px",l(s,r))),"object"===_typeof(window.GGBT_wsf_view)&&window.GGBT_wsf_view.isFullscreen()&&a(t),window.GGBT_wsf_view&&!window.GGBT_wsf_view.isFullscreen()&&window.GGBT_wsf_general.adjustContentToResize($(o).parents(".content-added-content"))}},isFlexibleWorksheetEditor:e,positionCenter:a,getScale:n,scaleElement:l}}();__WEBPACK_AMD_DEFINE_ARRAY__=[],__WEBPACK_AMD_DEFINE_RESULT__=function(){return GGBApplet}.apply(exports,__WEBPACK_AMD_DEFINE_ARRAY__),void 0===__WEBPACK_AMD_DEFINE_RESULT__||(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 e=n.location.search;return-1!=e.indexOf(J)||-1!=e.indexOf(K)}function q(e,l){}q(H,I),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||{},t;function u(){return v(),t}function v(){if(!t){var e=o.createElement(Q);if(e.id=L,e.style.cssText=R+S,e.tabIndex=-1,o.body.appendChild(e),t=e.contentWindow.document,-1==navigator.userAgent.indexOf(T)){t.open();var l=document.compatMode==U?V:W;t.write(l+X),t.close()}}}function w(e){q(cb,eb),function(e){function l(){return _typeof(o.readyState)==Y?_typeof(o.body)!=Y&&null!=o.body:/loaded|complete/.test(o.readyState)}var t=l();if(t)e();else{o.addEventListener&&o.addEventListener(Z,a,!1);var n=setInterval((function(){a()}),$)}function a(){if(!t){if(!l())return;t=!0,e(),o.removeEventListener&&o.removeEventListener(Z,a,!1),n&&clearInterval(n)}}}((function(){var l,t,n,a;l=e,t=u(),n=t.body,(a=t.createElement(_)).language=ab,a.crossOrigin=W,a.src=l,webModule.__errFn&&(a.onerror=function(){webModule.__errFn(L,new Error(bb+l))}),n.appendChild(a),q(cb,db)}))}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(e){alert(nb+k+ob)}}else if(j==pb&&(k=i.getAttribute(kb),k))try{e=eval(k)}catch(e){alert(nb+k+qb)}}}__gwt_getMetaProperty=function(e){var l=c[e];return null==l?null:l},r=d,webModule.__errFn=e}function B(){function e(e){var l=e.lastIndexOf(rb);-1==l&&(l=e.length);var t=e.indexOf(sb);-1==t&&(t=e.length);var n=e.lastIndexOf(tb,Math.min(t,l));return n>=O?e.substring(O,n+P):W}var l,t=null!=(l=__gwt_getMetaProperty(wb))?l:W;return t==W&&(t=function(){for(var l=o.getElementsByTagName(_),t=O;t<l.length;++t)if(-1!=l[t].src.indexOf(xb))return e(l[t].src);return W}()),t==W&&(t=function(){var e=o.getElementsByTagName(yb);return e.length>O?e[e.length-P].href:W}()),t==W&&function(){var e=o.location;return e.href==e.protocol+zb+e.host+e.pathname+e.search+e.hash}()&&(t=e(o.location.href)),t=function(l){if(l.match(/^\w+:\/\//));else{var t=o.createElement(ub);t.src=l+vb,l=e(t.src)}return l}(t),t}function C(e){return e.match(/^\//)||e.match(/^[a-zA-Z]+:\/\//)?e:webModule.__moduleBase+e}function D(){var e,l=O,t=[],a=[];function i(e){var l=a[e](),n=t[e];if(l in n)return l;var i=[];for(var o in n)i[n[o]]=o;throw r&&r(e,i,l),null}if(__gwt_isKnownPropertyValue=function(e,l){return l in t[e]},webModule.__getPropMap=function(){var e={};for(var l in t)t.hasOwnProperty(l)&&(e[l]=i(l));return e},webModule.__computePropValue=i,n.__gwt_activeModules[L].bindings=webModule.__getPropMap,p())return C(Bb);try{var o=(e=Cb).indexOf(Db);-1!=o&&(l=parseInt(e.substring(o+P),$),e=e.substring(O,o))}catch(e){}return webModule.__softPermutationId=l,C(e+Eb)}function F(){n.__gwt_stylesLoaded||(n.__gwt_stylesLoaded={})}s[L]={moduleName:L},webModule.__moduleStartupDone=function(e){var l=s[L].bindings;s[L].bindings=function(){for(var t=l?l():{},n=e[webModule.__softPermutationId],a=O;a<n.length;a++){var i=n[a];t[i[O]]=i[P]}return t}},webModule.__startLoadingFragment=function(e){return C(e)},webModule.__installRunAsyncCode=function(e){var l=u(),t=l.body,n=l.createElement(_);n.language=ab,n.text=e,t.appendChild(n),t.removeChild(n)},A(),webModule.__moduleBase="/js/mathematicalGraphics/"+name+"/",s[L].moduleBase=webModule.__moduleBase;var G=D();return F(),w(G),!0}return webModule},"function"!=typeof window.web3d&&(window.web3d=GGBAppletUtils.makeModule("web3d","A18F540516513B1292CA7CEF2F6AFC7E")),"function"!=typeof window.webSimple&&(window.webSimple=GGBAppletUtils.makeModule("webSimple","96B09BF1B436BF53F0DF54116700F16A")),window.GGBApplet=GGBApplet}else console.warn("deployggb.js was loaded twice")})()},18468:function(e,l,t){"use strict";function n(e){var l=!0;if(e.length>0){for(var t=0;t<e.length;t++)if(0==e[t].compile_success||!e[t].compile_success){l=!1;break}}else l=!1;return l}function a(e){for(var l=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",t=[],n=0;n<e.length;n++){var a=e[n],i=l?"".concat(l,"/").concat(a.name):"".concat(a.name);t.push({title:a.name,type:a.type,isLeaf:"tree"!==a.type,key:i})}return t}function i(e,l,t){for(var n=0;n<e.length;n++){var a=e[n];if(a.key===l){a.children=t;break}a.children&&i(a.children,l,t)}return e}function o(e,l,t){var n;return function(){var a=this,i=arguments,o=function(){n=null,t||e.apply(a,i)},r=t&&!n;clearTimeout(n),n=setTimeout(o,l),r&&e.apply(a,i)}}t.d(l,{Ax:function(){return i},Ds:function(){return o},KI:function(){return r},SI:function(){return a},f1:function(){return n}});var r=t(15309).Z.API_SERVER},84093:function(e,l,t){"use strict";t.d(l,{Z:function(){return y}});var n=t(7557),a=t.n(n),i=t(41498),o=t.n(i),r=t(79800),s=t.n(r),u=t(59301),c="imageDimensions___a7crR",d="img___Kroat",p="fullWidth___c492T",v=t(92310),f=t.n(v),h=t(71418),b=t(2859),m=t(79311),g=t(27627),w=t(37712),y=function(e){var l=e.data,t=e.className,n=e.fullWidth,i=e.style,r=void 0===i?{}:i,v=e.onClose,y=e.onOk,x=e.showFullTools,_=e.noAssociationId,k=(0,u.useRef)(null),S=(0,u.useRef)(null),B=(0,u.useRef)(null),T=(0,u.useRef)(null),C=(0,u.useState)(!1),j=s()(C,2),P=j[0],L=j[1],E=(0,u.useState)("正在加载中"),N=s()(E,2),M=N[0],A=N[1];(0,u.useEffect)((function(){B.current||(B.current=document.createElement("style"),document.head.appendChild(B.current)),null!=l&&l.visible?(document.body.setAttribute("data-custom","y-hidden"),B.current.innerHTML=" html { overflow-y: hidden; }",null!=l&&l.src&&G()):(document.body.removeAttribute("data-custom"),B.current&&(document.head.removeChild(B.current),B.current=null))}),[null==l?void 0:l.visible]);var G=function(){var e=o()(a()().mark((function e(){var t;return a()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return L(!0),A("正在加载中"),e.next=4,(0,g.ZJ)(null==l?void 0:l.src);case 4:t=e.sent,k.current.src="",k.current.src=t,k.current.onload=function(){R()},L(!1),A("");case 10:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}(),O=function(){var e=o()(a()().mark((function e(t){var n;return a()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return L(!0),A("正在保存中"),e.next=4,(0,m.ZP)("/api/attachments.json",{method:"post",body:{file_type:"base64",original_filename:l.title,file:t.dataUrl}});case 4:if(null==(n=e.sent)||!n.id||_){e.next=12;break}return e.next=8,(0,m.ZP)("/api/attachments/".concat(l.id,"/add_subitem.json"),{method:"post",body:{subitem_id:null==n?void 0:n.id,settings:JSON.stringify(t.state)}});case 8:0===e.sent.status&&y(),e.next=13;break;case 12:null!=n&&n.id&&y(n);case 13:L(!1),A("");case 15:case"end":return e.stop()}}),e)})));return function(l){return e.apply(this,arguments)}}(),R=function(){S.current=new b.hP(k.current),S.current.targetRoot=T.current,S.current.addEventListener("render",O),S.current.addEventListener("beforeclose",v),x&&(S.current.availableMarkerTypes=S.current.ALL_MARKER_TYPES,S.current.uiStyleSettings.redoButtonVisible=!0,S.current.uiStyleSettings.notesButtonVisible=!0,S.current.uiStyleSettings.zoomButtonVisible=!0,S.current.uiStyleSettings.zoomOutButtonVisible=!0,S.current.uiStyleSettings.clearButtonVisible=!0),window.markerArea=S.current.uiStyleSettings,S.current.show(),null!=l&&l.snapshotData&&S.current.restoreState(l.snapshotData),setTimeout((function(){var e;window.scrollTo(0,0),(e=document.querySelector('a[href="https://markerjs.com/"]'))&&e.parentNode&&(e.parentNode.style.display="none"),[{name:'[data-action="select"]',title:"选择"},{name:'[data-action="delete"]',title:"删除元素"},{name:'[data-action="undo"]',title:"撤销"},{name:'[data-type-name="FrameMarker"]',title:"矩形"},{name:'[data-type-name="FreehandMarker"]',title:"画线"},{name:'[data-type-name="ArrowMarker"]',title:"箭头"},{name:'[data-type-name="TextMarker"]',title:"文本"},{name:'[data-type-name="EllipseMarker"]',title:"椭圆"},{name:'[data-type-name="HighlightMarker"]',title:"方块"},{name:'[data-type-name="CalloutMarker"]',title:"注释"},{name:'[data-action="render"]',title:"保存"},{name:'[data-action="close"]',title:"退出"}].forEach((function(e){var l=document.querySelector(e.name);l&&l.setAttribute("title",e.title)}))}),300)};return(0,w.jsx)(u.Fragment,{children:(null==l?void 0:l.visible)&&(0,w.jsx)(h.Z,{spinning:P,tip:M,style:{position:"absolute"},children:(0,w.jsx)("div",{ref:T,className:f()(c,t,n?p:""),style:r,children:(0,w.jsx)("img",{className:d,ref:k})})})})}},35028:function(e,l,t){"use strict";t.d(l,{h:function(){return m}});var n=t(82242),a=t.n(n),i=t(79800),o=t.n(i),r=t(59301),s=t(57809),u=t(78241),c=t(3113),d=t(89780),p=t.n(d),v=(t(48860),t(48838),t(37712)),f=s.default.Option,h={labelCol:{span:4},wrapperCol:{span:20}},b={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"]};function m(e){var l=e.value,t=e.onChange,n=e.mode,i=e.options,s=void 0===i?{}:i,u=(0,r.useRef)(),c=(0,r.useState)(),d=o()(c,2),f=d[0],h=d[1];return(0,r.useEffect)((function(){if(f){var e=function(e){var l=e.getValue();t&&t(l)};return f.on("change",e),function(){f.off("change",e)}}}),[f,t]),(0,r.useEffect)((function(){f&&f.setOption("mode",n)}),[f,n]),(0,r.useEffect)((function(){f&&(l===f.getValue()&&""!==l||setTimeout((function(){f.setValue(l||"")}),300))}),[f,l]),(0,r.useEffect)((function(){if(u.current&&!f){var e=p().fromTextArea(u.current,a()({mode:n,lineNumbers:!0,lineWrapping:!0,autoCloseBrackets:!0,tabSize:4,autofocus:!0,autoCloseTags:!0,matchBrackets:!0,styleActiveLine:!0},s));h(e)}}),[u.current,f]),(0,v.jsx)("div",{className:"my-codemirror-container",children:(0,v.jsx)("textarea",{ref:u})})}l.Z=function(e){var l=e.callback,t=e.onCancel,n=(0,r.useState)("python"),i=o()(n,2),d=i[0],p=i[1];return(0,v.jsxs)(u.Z,a()(a()({},h),{},{className:"code-block-panel",initialValues:{language:"python",content:""},onFinish:function(e){l(e)},style:{width:500},children:[(0,v.jsx)(u.Z.Item,{label:"代码语言",name:"language",children:(0,v.jsx)(s.default,{getPopupContainer:function(e){return e.parentNode},onChange:function(e){p(b[e][1])},children:Object.keys(b).map((function(e){return(0,v.jsx)(f,{value:e,children:b[e][0]},e)}))})}),(0,v.jsx)(u.Z.Item,{label:"代码内容",name:"content",rules:[{required:!0,message:"请输入代码内容"}],children:(0,v.jsx)(m,{mode:d})}),(0,v.jsxs)("div",{className:"flex-container flex-end",children:[(0,v.jsx)(c.ZP,{type:"primary",htmlType:"submit",style:{marginRight:10},children:"确定"}),(0,v.jsx)(c.ZP,{type:"ghost",onClick:t,children:"取消"})]})]}))}},7575:function(e,l,t){"use strict";t.d(l,{Z:function(){return xe}});var n=t(91232),a=t.n(n),i=t(79800),o=t.n(i),r=t(85573),s=t.n(r),u=t(59301),c=t(89780),d=t.n(c),p=t(76374),v=(t(48860),t(6313),t(25717),t(99498),t(25419),t(67549),t(82011)),f=t(37712),h=function(e){var l=e.value,t=void 0===l?"":l,n=(e.className,e.showTextOnly,e.showLines,e.style,(0,u.useMemo)((function(){return""}),[t]));return(0,f.jsx)(f.Fragment,{children:(0,f.jsx)("div",{dangerouslySetInnerHTML:{__html:n}})})},b=t(82242),m=t.n(b),g=[{title:"粗体",icon:"md-iconfont icon-bold",actionName:"bold"},{title:"斜体",icon:"md-iconfont icon-italic",actionName:"italic"},"|",{title:"无序列表",icon:"md-iconfont icon-unorder-list",actionName:"list-ul"},{title:"有序列表",icon:"md-iconfont icon-order-list",actionName:"list-ol"},"|",{title:"行内代码",icon:"md-iconfont icon-code",actionName:"code"},{title:"代码块(多语言风格)",icon:"md-iconfont icon-file-code",actionName:"code-block"},{title:"链接",icon:"md-iconfont icon-link",actionName:"link"},"|",{title:"行内公式",icon:"md-iconfont icon-sum",actionName:"inline-latex"},{title:"数学图像",icon:"iconfont icon-shuxuetuxiang2",actionName:"maths-latex"},{title:"多行公式",icon:"iconfont icon-jisuan1",actionName:"latex"},"|",{title:"添加图片",icon:"md-iconfont icon-picture",actionName:"upload-image"},{title:"插入画图",icon:"iconfont icon-sheji",actionName:"draw-image"},{title:"插入流程图",icon:"iconfont icon-liucheng",actionName:"add-flowchart"},{title:"表格",icon:"md-iconfont icon-table",actionName:"add-table"},"|",{title:"换行",icon:"md-iconfont icon-minus",actionName:"line-break"},{title:"清空",icon:"md-iconfont icon-eraser",actionName:"eraser"}];function w(e){var l=e.onActionCallback,t=e.title,n=e.icon,a=e.actionName,i=e.className,o=void 0===i?"":i,r=e.children;return(0,f.jsxs)("a",{title:t,className:o,onClick:function(){l(a)},children:[(0,f.jsx)("i",{className:"".concat(n)}),r]})}var y=function(e){var l=e.watch,t=e.showNullButton,n=e.showNullProgramButton,a=e.onActionCallback,i=e.fullScreen,o=e.insertTemp,r=e.hidetoolBar,s=e.extraUse,u=[].concat(g,[{title:"".concat(l?"关闭实时预览":"开启实时预览"),icon:"".concat(l?"md-iconfont icon-eye-slash":"md-iconfont icon-eye"),actionName:"trigger-watch"}]);return(0,f.jsxs)("ul",{className:"markdown-toolbar-container",children:[!r&&u.map((function(e,l){return(0,f.jsx)("li",{children:e.actionName?(0,f.jsx)(w,m()(m()({},e),{},{onActionCallback:a})):(0,f.jsx)("span",{className:"v-line"})},l)})),t?(0,f.jsx)("li",{children:(0,f.jsx)(w,{icon:"md-iconfont icon-edit insert-blank",className:"btn-null",title:"增加填空",actionName:"add-null-ch",onActionCallback:a,children:(0,f.jsx)("span",{className:"fill-tip",children:"点击插入\b填空项"})})}):null,n?(0,f.jsxs)(f.Fragment,{children:[(0,f.jsx)("li",{children:(0,f.jsx)(w,{icon:"md-iconfont icon-edit insert-blank",className:"btn-null",title:"增加填空",actionName:"add-signal",onActionCallback:a,children:(0,f.jsx)("span",{className:"fill-tip",children:"+单行填空项"})})}),(0,f.jsx)("li",{children:(0,f.jsx)(w,{icon:"md-iconfont icon-uniE900 insert-blank",className:"btn-null",title:"增加填空",actionName:"add-multiple",onActionCallback:a,children:(0,f.jsx)("span",{className:"fill-tip",children:"+多行填空项"})})})]}):null,o&&(0,f.jsx)("li",{children:(0,f.jsx)(w,{icon:"md-iconfont icon-edit",className:"btn-null",title:"插入模板",actionName:"inster-template-".concat(o),onActionCallback:a,children:(0,f.jsx)("span",{className:"fill-tip",children:"插入模板"})})}),s&&(0,f.jsx)("li",{children:s}),(0,f.jsx)("li",{className:"btn-full-screen",children:(0,f.jsx)(w,{icon:"".concat(i?"md-iconfont icon-shrink":"md-iconfont icon-enlarge"),title:i?"关闭全屏":"开启全屏",actionName:"trigger-full-screen",onActionCallback:a})})]})},x=t(56386),_=t(78241),k=t(92832),S=t(3113),B={labelCol:{span:4},wrapperCol:{span:20}},T=function(e){var l=e.callback,t=e.onCancel;return(0,f.jsxs)(_.Z,m()(m()({},B),{},{initialValues:{link:"http://",title:""},className:"link-panel",onFinish:function(e){l(e)},style:{width:500},children:[(0,f.jsx)(_.Z.Item,{label:"链接地址",name:"link",rules:[{required:!0,message:"请输入链接地址"}],children:(0,f.jsx)(k.Z,{})}),(0,f.jsx)(_.Z.Item,{label:"链接标题",name:"title",rules:[{required:!0,message:"请输入链接标题"}],children:(0,f.jsx)(k.Z,{})}),(0,f.jsxs)("div",{className:"flex-container flex-end",children:[(0,f.jsx)(S.ZP,{type:"primary",htmlType:"submit",style:{marginRight:10},children:"确定"}),(0,f.jsx)(S.ZP,{type:"ghost",onClick:t,children:"取消"})]})]}))},C=t(35028),j=t(8899),P=t(95237),L=t(84093),E=function(e){var l=e.callback,t=e.onCancel,n=document.createElement("canvas"),a=n.getContext("2d");n.width=1e3,n.height=800,a.fillStyle="#ffffff",a.fillRect(0,0,n.width,n.height);var i=n.toDataURL("image/png");return(0,f.jsx)(P.Z,{style:{height:"100vh"},children:(0,f.jsx)(L.Z,{fullWidth:!0,noAssociationId:!0,showFullTools:!0,data:{src:i,visible:!0,title:String(Date.now())},onOk:function(e){l({src:e.url})},onClose:t})})},N=t(7557),M=t.n(N),A=t(41498),G=t.n(A),O=t(37205),R=t.n(O),Z=t(12378);function I(){go.CommandHandler.call(this),this._arrowKeyBehavior="move",this._pasteOffset=new go.Point(10,10),this._lastPasteOffset=new go.Point(0,0)}go.Diagram.inherit(I,go.CommandHandler),I.prototype.canAlignSelection=function(){var e=this.diagram;return null!==e&&!e.isReadOnly&&!e.isModelReadOnly&&!(e.selection.count<2)},I.prototype.alignLeft=function(){var e=this.diagram;e.startTransaction("aligning left");var l=1/0;e.selection.each((function(e){e instanceof go.Link||(l=Math.min(e.position.x,l))})),e.selection.each((function(e){e instanceof go.Link||e.move(new go.Point(l,e.position.y))})),e.commitTransaction("aligning left")},I.prototype.alignRight=function(){var e=this.diagram;e.startTransaction("aligning right");var l=-1/0;e.selection.each((function(e){if(!(e instanceof go.Link)){var t=e.actualBounds.x+e.actualBounds.width;l=Math.max(t,l)}})),e.selection.each((function(e){e instanceof go.Link||e.move(new go.Point(l-e.actualBounds.width,e.position.y))})),e.commitTransaction("aligning right")},I.prototype.alignTop=function(){var e=this.diagram;e.startTransaction("alignTop");var l=1/0;e.selection.each((function(e){e instanceof go.Link||(l=Math.min(e.position.y,l))})),e.selection.each((function(e){e instanceof go.Link||e.move(new go.Point(e.position.x,l))})),e.commitTransaction("alignTop")},I.prototype.alignBottom=function(){var e=this.diagram;e.startTransaction("aligning bottom");var l=-1/0;e.selection.each((function(e){if(!(e instanceof go.Link)){var t=e.actualBounds.y+e.actualBounds.height;l=Math.max(t,l)}})),e.selection.each((function(e){e instanceof go.Link||e.move(new go.Point(e.actualBounds.x,l-e.actualBounds.height))})),e.commitTransaction("aligning bottom")},I.prototype.alignCenterX=function(){var e=this.diagram,l=e.selection.first();if(l){e.startTransaction("aligning Center X");var t=l.actualBounds.x+l.actualBounds.width/2;e.selection.each((function(e){e instanceof go.Link||e.move(new go.Point(t-e.actualBounds.width/2,e.actualBounds.y))})),e.commitTransaction("aligning Center X")}},I.prototype.alignCenterY=function(){var e=this.diagram,l=e.selection.first();if(l){e.startTransaction("aligning Center Y");var t=l.actualBounds.y+l.actualBounds.height/2;e.selection.each((function(e){e instanceof go.Link||e.move(new go.Point(e.actualBounds.x,t-e.actualBounds.height/2))})),e.commitTransaction("aligning Center Y")}},I.prototype.alignColumn=function(e){var l=this.diagram;l.startTransaction("align Column"),void 0===e&&(e=0),e=parseFloat(e);var t=new Array;l.selection.each((function(e){e instanceof go.Link||t.push(e)}));for(var n=0;n<t.length-1;n++){var a=t[n],i=a.actualBounds.y+a.actualBounds.height+e;t[n+1].move(new go.Point(a.actualBounds.x,i))}l.commitTransaction("align Column")},I.prototype.alignRow=function(e){void 0===e&&(e=0),e=parseFloat(e);var l=this.diagram;l.startTransaction("align Row");var t=new Array;l.selection.each((function(e){e instanceof go.Link||t.push(e)}));for(var n=0;n<t.length-1;n++){var a=t[n],i=a.actualBounds.x+a.actualBounds.width+e;t[n+1].move(new go.Point(i,a.actualBounds.y))}l.commitTransaction("align Row")},I.prototype.canRotate=function(e){var l=this.diagram;return null!==l&&!l.isReadOnly&&!l.isModelReadOnly&&!(l.selection.count<1)},I.prototype.rotate=function(e){var l;void 0===e&&(e=90),(l=this.diagram).startTransaction("rotate "+e.toString()),(l=this.diagram).selection.each((function(l){l instanceof go.Link||l instanceof go.Group||(l.angle+=e)})),l.commitTransaction("rotate "+e.toString())},I.prototype.pullToFront=function(){var e=this.diagram;e.startTransaction("pullToFront");var l=new go.Map;e.selection.each((function(e){l.set(e.layer,0)})),l.iteratorKeys.each((function(e){var t=0;e.parts.each((function(e){if(!e.isSelected){var l=e.zOrder;isNaN(l)?e.zOrder=0:t=Math.max(t,l)}})),l.set(e,t)})),e.selection.each((function(e){I._assignZOrder(e,l.get(e.layer)+1)})),e.commitTransaction("pullToFront")},I.prototype.pushToBack=function(){var e=this.diagram;e.startTransaction("pushToBack");var l=new go.Map;e.selection.each((function(e){l.set(e.layer,0)})),l.iteratorKeys.each((function(e){var t=0;e.parts.each((function(e){if(!e.isSelected){var l=e.zOrder;isNaN(l)?e.zOrder=0:t=Math.min(t,l)}})),l.set(e,t)})),e.selection.each((function(e){I._assignZOrder(e,l.get(e.layer)-1-I._findGroupDepth(e))})),e.commitTransaction("pushToBack")},I._assignZOrder=function(e,l,t){void 0===t&&(t=e),e.layer===t.layer&&(e.zOrder=l),e instanceof go.Group&&e.memberParts.each((function(e){I._assignZOrder(e,l+1,t)}))},I._findGroupDepth=function(e){if(e instanceof go.Group){var l=0;return e.memberParts.each((function(e){l=Math.max(l,I._findGroupDepth(e))})),l+1}return 0},I.prototype.doKeyDown=function(){var e=this.diagram;if(null!==e){var l=e.lastInput;if("Up"===l.key||"Down"===l.key||"Left"===l.key||"Right"===l.key){var t=this.arrowKeyBehavior;if("none"===t)return;if("select"===t)return void this._arrowKeySelect();if("move"===t)return void this._arrowKeyMove();if("tree"===t)return void this._arrowKeyTree()}go.CommandHandler.prototype.doKeyDown.call(this)}},I.prototype._getAllParts=function(){var e=new Array;return this.diagram.nodes.each((function(l){e.push(l)})),this.diagram.parts.each((function(l){e.push(l)})),e},I.prototype._arrowKeyMove=function(){var e=this.diagram,l=e.lastInput,t=0,n=0;if(l.control||l.meta)t=1,n=1;else if(null!==e.grid){var a=e.grid.gridCellSize;n=a.width,t=a.height}e.startTransaction("arrowKeyMove"),e.selection.each((function(e){"Up"===l.key?e.move(new go.Point(e.actualBounds.x,e.actualBounds.y-t)):"Down"===l.key?e.move(new go.Point(e.actualBounds.x,e.actualBounds.y+t)):"Left"===l.key?e.move(new go.Point(e.actualBounds.x-n,e.actualBounds.y)):"Right"===l.key&&e.move(new go.Point(e.actualBounds.x+n,e.actualBounds.y))})),e.commitTransaction("arrowKeyMove")},I.prototype._arrowKeySelect=function(){var e=this.diagram,l=e.lastInput,t=null;"Up"===l.key?t=this._findNearestPartTowards(270):"Down"===l.key?t=this._findNearestPartTowards(90):"Left"===l.key?t=this._findNearestPartTowards(180):"Right"===l.key&&(t=this._findNearestPartTowards(0)),null!==t&&(l.shift?t.isSelected=!0:l.control||l.meta?t.isSelected=!t.isSelected:e.select(t))},I.prototype._findNearestPartTowards=function(e){var l=this.diagram.selection.first();if(null===l)return null;for(var t=l.actualBounds.center,n=this._getAllParts(),a=1/0,i=l,o=0;o<n.length;o++){var r=n[o];if(r!==l&&r.canSelect()){var s=r.actualBounds.center,u=t.directionPoint(s),c=this._angleCloseness(u,e);if(c<=45){var d=t.distanceSquaredPoint(s);(d*=1+Math.sin(c*Math.PI/180))<a&&(a=d,i=r)}}}return i},I.prototype._angleCloseness=function(e,l){return Math.min(Math.abs(l-e),Math.min(Math.abs(l+360-e),Math.abs(l-360-e)))},I.prototype._arrowKeyTree=function(){var e=this.diagram,l=e.selection.first();if(l instanceof go.Node){var t=e.lastInput;if("Right"===t.key)if(l.isTreeLeaf);else if(l.isTreeExpanded){null!==(a=this._sortTreeChildrenByY(l).first())&&e.select(a)}else e.commandHandler.canExpandTree(l)&&e.commandHandler.expandTree(l);else if("Left"===t.key){if(!l.isTreeLeaf&&l.isTreeExpanded)e.commandHandler.canCollapseTree(l)&&e.commandHandler.collapseTree(l);else null!==(i=l.findTreeParentNode())&&e.select(i)}else if("Up"===t.key){if(null!==(i=l.findTreeParentNode()))if((r=(o=this._sortTreeChildrenByY(i)).indexOf(l))>0){for(var n=o.elt(r-1);null!==n&&n.isTreeExpanded&&!n.isTreeLeaf;){n=this._sortTreeChildrenByY(n).last()}null!==n&&e.select(n)}else e.select(i)}else if("Down"===t.key){var a;if(l.isTreeExpanded&&!l.isTreeLeaf)null!==(a=this._sortTreeChildrenByY(l).first())&&e.select(a);else for(;null!==l;){var i,o,r;if(null===(i=l.findTreeParentNode()))break;if((r=(o=this._sortTreeChildrenByY(i)).indexOf(l))<o.length-1){e.select(o.elt(r+1));break}l=i}}var s=e.selection.first();null!==s&&e.scrollToRect(s.actualBounds)}},I.prototype._sortTreeChildrenByY=function(e){var l=(new go.List).addAll(e.findTreeChildrenNodes());return l.sort((function(e,l){var t=e.location,n=l.location;return t.y<n.y?-1:t.y>n.y?1:t.x<n.x?-1:t.x>n.x?1:0})),l},I.prototype.copyToClipboard=function(e){go.CommandHandler.prototype.copyToClipboard.call(this,e),this._lastPasteOffset.set(this.pasteOffset)},I.prototype.pasteFromClipboard=function(){var e=go.CommandHandler.prototype.pasteFromClipboard.call(this);return this.diagram.moveParts(e,this._lastPasteOffset),this._lastPasteOffset.add(this.pasteOffset),e},Object.defineProperty(I.prototype,"arrowKeyBehavior",{get:function(){return this._arrowKeyBehavior},set:function(e){if("move"!==e&&"select"!==e&&"scroll"!==e&&"tree"!==e&&"none"!==e)throw new Error('DrawCommandHandler.arrowKeyBehavior must be either "move", "select", "scroll", "tree", or "none", not: '+e);this._arrowKeyBehavior=e}}),Object.defineProperty(I.prototype,"pasteOffset",{get:function(){return this._pasteOffset},set:function(e){if(!(e instanceof go.Point))throw new Error("DrawCommandHandler.pasteOffset must be a Point, not: "+e);this._pasteOffset.set(e)}});var F=I,D=(t(15379),t(85160)),H=t(43418),W=t(43604),z=t(79311),V="myPaletteDiv___Xjz2I",q="maxH60___Pd4Re";window.go=Z;var U=function(e){var l=e.onCancel,t=e.callback,n=(0,u.useRef)(),a=(0,u.useRef)(),i=(0,u.useRef)(),r=(0,u.useRef)(!1),s=(0,u.useRef)(!1),c=(0,u.useState)(0),d=o()(c,2),p=d[0],v=d[1],h=function(){var e=G()(M()().mark((function e(){var l,a;return M()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return l=n.current.makeImage(),e.next=3,(0,z.ZP)("/api/attachments.json",{method:"post",body:{file_type:"base64",original_filename:Date.now(),file:l.src}});case 3:a=e.sent,t({src:a.url});case 5:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}();return(0,u.useEffect)((function(){v(p+1)}),[]),(0,f.jsx)("div",{ref:s,className:r.current?"".concat(q," body-overflow-initial"):"body-overflow-initial",children:(0,f.jsx)(H.Z,{width:1200,icon:null,footer:null,closable:!0,visible:!!p,destroyOnClose:!0,maskClosable:!1,getContainer:s.current,rootClassName:"zIndex-9999",title:(0,f.jsxs)(P.Z,{children:[(0,f.jsx)(W.Z,{flex:1,children:"插入流程图"}),(0,f.jsx)(W.Z,{onClick:function(){r.current=!r.current,v(p+1)},children:(0,f.jsx)("span",{className:"current c-blue mr30",style:{fontWeight:400},children:"展开/收起"})})]}),onCancel:l,children:(0,f.jsxs)("div",{style:{width:"100%",height:"80vh",overflow:"hidden",position:"relative"},children:[(0,f.jsxs)("div",{style:{display:"flex",height:"100%"},children:[(0,f.jsxs)("div",{style:{width:"300px",height:"100%"},children:[(0,f.jsx)("div",{style:{background:"#fff",position:"relative",zIndex:12,fontSize:16,color:"#3061d0"},children:"图形库"}),(0,f.jsx)("div",{style:{height:"calc(100% - 50px)"},className:V,ref:i})]}),(0,f.jsxs)("div",{style:{flex:1,position:"relative"},children:[(0,f.jsx)(D.FI,{initDiagram:function(){var e=Z.GraphObject.make,l="#ff3333",t="#3358ff",o="#25ad23",r="#d533ff",s="#7d33ff",u="#ff6233",c="#ffffff",d="#000000",p="#fffcd5",v="#d5ebff",f="#f2dfe0",h="#a5d2fa",b="#cccccc",m="#b3e6b3",g="#fcbbbd";function w(l,t){var n=function(e,t){e.handled=!0,e.diagram.model.commit((function(n){var a=t.part.adornedPart,i=(new Z.Point).setRectSpot(a.actualBounds,l);i.subtract(a.location),i.scale(2,2),i.x+=130*Math.sign(i.x),i.y+=130*Math.sign(i.y),i.add(a.location),i.snapToGridPoint(e.diagram.grid.gridOrigin,e.diagram.grid.gridCellSize);var o=n.copyNodeData(a.data);n.setGroupKeyForNodeData(o,n.getGroupKeyForNodeData(a.data)),n.addNodeData(o);var r={from:a.key,to:n.getKeyForNodeData(o)};n.addLinkData(r);var s=e.diagram.findNodeForData(o);s.location=i,e.diagram.select(s),setTimeout((function(){e.diagram.commandHandler.editTextBlock()}),20)}))};return e(Z.Shape,{figure:t,alignment:l,alignmentFocus:l.opposite(),width:l.equals(Z.Spot.Top)||l.equals(Z.Spot.Bottom)?25:18,height:l.equals(Z.Spot.Top)||l.equals(Z.Spot.Bottom)?18:25,fill:"orange",stroke:c,strokeWidth:4,mouseEnter:function(e,l){return l.fill="dodgerblue"},mouseLeave:function(e,l){return l.fill="orange"},isActionable:!0,click:n,contextClick:n})}function y(l){return e(Z.Shape,{fill:"orange",stroke:"rgba(0, 0, 0, 0)",strokeWidth:15,background:"transparent",geometryString:"F1 M0 0 b 0 360 -4 0 4 z M10 0 b 0 360 -4 0 4 z M20 0 b 0 360 -4 0 4",isActionable:!0,cursor:"context-menu",mouseEnter:function(e,l){return l.fill="dodgerblue"},mouseLeave:function(e,l){return l.fill="orange"},click:function(e,l){e.diagram.commandHandler.showContextMenu(l.part.adornedPart)}},l||{})}function x(e,l){return function(t,n){t.handled=!0,t.diagram.model.commit((function(t){t.set(n.part.adornedPart.data,e,l)}))}}function _(l,t){return t||(t="color"),e(Z.Shape,{width:16,height:16,stroke:"lightgray",fill:l,margin:1,background:"transparent",mouseEnter:function(e,l){return l.stroke="dodgerblue"},mouseLeave:function(e,l){return l.stroke="lightgray"},click:x(t,l),contextClick:x(t,l)})}function k(){return[e("ContextMenuButton",e(Z.Panel,"Horizontal",_(c,"fill"),_(p,"fill"),_(v,"fill"),_(f,"fill"))),e("ContextMenuButton",e(Z.Panel,"Horizontal",_(b,"fill"),_(m,"fill"),_(h,"fill"),_(g,"fill")))]}function S(){return[e("ContextMenuButton",e(Z.Panel,"Horizontal",_(d),_(o),_(t),_(l))),e("ContextMenuButton",e(Z.Panel,"Horizontal",_(c),_(r),_(s),_(u)))]}function B(l,t){return t||(t="thickness"),e(Z.Shape,"LineH",{width:16,height:16,strokeWidth:l,margin:1,background:"transparent",mouseEnter:function(e,l){return l.background="dodgerblue"},mouseLeave:function(e,l){return l.background="transparent"},click:x(t,l),contextClick:x(t,l)})}function T(l,t){return t||(t="dash"),e(Z.Shape,"LineH",{width:24,height:16,strokeWidth:2,strokeDashArray:l,margin:1,background:"transparent",mouseEnter:function(e,l){return l.background="dodgerblue"},mouseLeave:function(e,l){return l.background="transparent"},click:x(t,l),contextClick:x(t,l)})}function C(){return[e("ContextMenuButton",e(Z.Panel,"Horizontal",B(1),B(2),B(3),B(4))),e("ContextMenuButton",e(Z.Panel,"Horizontal",T(null),T([2,4]),T([4,4])))]}function j(l,t){return t||(t="figure"),e(Z.Shape,{width:32,height:32,scale:.5,fill:"lightgray",figure:l,margin:1,background:"transparent",mouseEnter:function(e,l){return l.fill="dodgerblue"},mouseLeave:function(e,l){return l.fill="lightgray"},click:x(t,l),contextClick:x(t,l)})}function P(l){return e(Z.Shape,{stroke:"dodgerblue",strokeWidth:2,strokeCap:"square",geometryString:"M0 0 M4 2 H3 M4 "+(l+4).toString()+" H3"})}function L(l){var t="M0 0 M8 16 M0 8 L16 8 M12 11 L16 8 L12 5";return 0===l?t="M0 0 M16 16 M0 8 L16 8":2===l&&(t="M0 0 M16 16 M0 8 L16 8 M12 11 L16 8 L12 5 M4 11 L0 8 L4 5"),e(Z.Shape,{geometryString:t,margin:2,background:"transparent",mouseEnter:function(e,l){return l.background="dodgerblue"},mouseLeave:function(e,l){return l.background="transparent"},click:x("dir",l),contextClick:x("dir",l)})}function E(l){var t=function(e,t){e.handled=!0,e.diagram.model.commit((function(e){var n=t.part.adornedPart;e.set(n.data,l?"toSpot":"fromSpot",Z.Spot.stringify(Z.Spot.AllSides)),(l?n.toNode:n.fromNode).invalidateConnectedLinks()}))};return e(Z.Shape,{width:12,height:12,fill:"transparent",mouseEnter:function(e,l){return l.background="dodgerblue"},mouseLeave:function(e,l){return l.background="transparent"},click:t,contextClick:t})}function N(l,t){var n=0,a=Z.Spot.RightSide;l.equals(Z.Spot.Top)?(n=270,a=Z.Spot.TopSide):l.equals(Z.Spot.Left)?(n=180,a=Z.Spot.LeftSide):l.equals(Z.Spot.Bottom)&&(n=90,a=Z.Spot.BottomSide),t||(n-=180);var i=function(e,l){e.handled=!0,e.diagram.model.commit((function(e){var n=l.part.adornedPart;e.set(n.data,t?"toSpot":"fromSpot",Z.Spot.stringify(a)),(t?n.toNode:n.fromNode).invalidateConnectedLinks()}))};return e(Z.Shape,{alignment:l,alignmentFocus:l.opposite(),geometryString:"M0 0 M12 12 M12 6 L1 6 L4 4 M1 6 L4 8",angle:n,background:"transparent",mouseEnter:function(e,l){return l.background="dodgerblue"},mouseLeave:function(e,l){return l.background="transparent"},click:i,contextClick:i})}return n.current=new Z.Diagram(a.current,{padding:20,grid:e(Z.Panel,"Grid",e(Z.Shape,"LineH",{stroke:"lightgray",strokeWidth:.5}),e(Z.Shape,"LineV",{stroke:"lightgray",strokeWidth:.5})),"draggingTool.isGridSnapEnabled":!0,handlesDragDropForTopLevelParts:!0,mouseDrop:function(e){e.diagram.commandHandler.addTopLevelParts(e.diagram.selection,!0)||e.diagram.currentTool.doCancel()},commandHandler:e(F),"clickCreatingTool.archetypeNodeData":{text:"未命名",fill:null,stroke:null,borderColor:"rgba(0,0,0,0)"},PartCreated:function(e){var l=e.subject;l.location=l.location.copy().snapToGridPoint(e.diagram.grid.gridOrigin,e.diagram.grid.gridCellSize),setTimeout((function(){e.diagram.commandHandler.editTextBlock()}),20)},"commandHandler.archetypeGroupData":{isGroup:!0,text:"NEW GROUP"},SelectionGrouped:function(e){e.subject;setTimeout((function(){e.diagram.commandHandler.editTextBlock()}))},LinkRelinked:function(e){e.parameter.part.invalidateConnectedLinks();var l=e.subject;e.diagram.toolManager.linkingTool.isForwards?l.toNode.invalidateConnectedLinks():l.fromNode.invalidateConnectedLinks()},"undoManager.isEnabled":!0}),n.current.nodeTemplate=e(Z.Node,"Auto",{locationSpot:Z.Spot.Center,locationObjectName:"SHAPE",desiredSize:new Z.Size(120,60),minSize:new Z.Size(40,40),resizable:!0,resizeCellSize:new Z.Size(10,10),rotatable:!0},new Z.Binding("location","loc",Z.Point.parse).makeTwoWay(Z.Point.stringify),new Z.Binding("desiredSize","size",Z.Size.parse).makeTwoWay(Z.Size.stringify),e(Z.Shape,{name:"SHAPE",fill:c,cursor:"pointer",portId:"",fromLinkable:!0,toLinkable:!0,fromLinkableDuplicates:!0,toLinkableDuplicates:!0,fromSpot:Z.Spot.AllSides,toSpot:Z.Spot.AllSides},new Z.Binding("figure"),new Z.Binding("fill"),new Z.Binding("stroke","borderColor"),new Z.Binding("strokeWidth","thickness"),new Z.Binding("strokeDashArray","dash")),e(Z.Shape,{width:100,height:20,strokeWidth:0,fill:"transparent"}),e(Z.TextBlock,{margin:1,textAlign:"center",overflow:Z.TextBlock.OverflowEllipsis,editable:!0},new Z.Binding("text").makeTwoWay(),new Z.Binding("stroke","color"))),n.current.nodeTemplate.toolTip=e("ToolTip",e(Z.Panel,"Vertical",{maxSize:new Z.Size(200,NaN)},e(Z.TextBlock,{font:"bold 10pt sans-serif",textAlign:"center"},new Z.Binding("text")),e(Z.TextBlock,{font:"10pt sans-serif",textAlign:"center"},new Z.Binding("text","details")))),n.current.nodeTemplate.selectionAdornmentTemplate=e(Z.Adornment,"Spot",e(Z.Placeholder,{padding:10}),w(Z.Spot.Top,"TriangleUp"),w(Z.Spot.Left,"TriangleLeft"),w(Z.Spot.Right,"TriangleRight"),w(Z.Spot.Bottom,"TriangleDown"),y({alignment:new Z.Spot(.75,0)})),n.current.nodeTemplate.contextMenu=e("ContextMenu",e("ContextMenuButton",e(Z.Panel,"Horizontal",j("Rectangle"),j("RoundedRectangle"),j("Ellipse"),j("Diamond"))),e("ContextMenuButton",e(Z.Panel,"Horizontal",j("Parallelogram2"),j("ManualOperation"),j("Procedure"),j("Cylinder1"))),e("ContextMenuButton",e(Z.Panel,"Horizontal",j("Terminator"),j("CreateRequest"),j("Document"),j("TriangleDown"))),k(),S(),C()),n.current.groupTemplate=e(Z.Group,"Spot",{layerName:"Background",ungroupable:!0,locationSpot:Z.Spot.Center,selectionObjectName:"BODY",computesBoundsAfterDrag:!0,handlesDragDropForMembers:!0,mouseDrop:function(e,l){l.addMembers(l.diagram.selection,!0)||l.diagram.currentTool.doCancel()},avoidable:!1},new Z.Binding("location","loc",Z.Point.parse).makeTwoWay(Z.Point.stringify),e(Z.Panel,"Auto",{name:"BODY"},e(Z.Shape,{parameter1:10,fill:c,strokeWidth:2,cursor:"pointer",fromLinkable:!0,toLinkable:!0,fromLinkableDuplicates:!0,toLinkableDuplicates:!0,fromSpot:Z.Spot.AllSides,toSpot:Z.Spot.AllSides},new Z.Binding("fill"),new Z.Binding("stroke","color"),new Z.Binding("strokeWidth","thickness"),new Z.Binding("strokeDashArray","dash")),e(Z.Placeholder,{background:"transparent",margin:20})),e(Z.TextBlock,{alignment:Z.Spot.Top,alignmentFocus:Z.Spot.Bottom,font:"bold 12pt sans-serif",editable:!0},new Z.Binding("text"),new Z.Binding("stroke","color"))),n.current.groupTemplate.selectionAdornmentTemplate=e(Z.Adornment,"Spot",e(Z.Panel,"Auto",e(Z.Shape,{fill:null,stroke:"dodgerblue",strokeWidth:3}),e(Z.Placeholder,{margin:1.5})),y({alignment:Z.Spot.TopRight,alignmentFocus:Z.Spot.BottomRight})),n.current.groupTemplate.contextMenu=e("ContextMenu",k(),S(),C()),n.current.linkTemplate=e(Z.Link,{layerName:"Foreground",routing:Z.Link.AvoidsNodes,corner:10,fromShortLength:10,toShortLength:15,relinkableFrom:!0,relinkableTo:!0,reshapable:!0,resegmentable:!0},new Z.Binding("fromSpot","fromSpot",Z.Spot.parse),new Z.Binding("toSpot","toSpot",Z.Spot.parse),new Z.Binding("fromShortLength","dir",(function(e){return e>=1?10:0})),new Z.Binding("toShortLength","dir",(function(e){return e>=1?10:0})),new Z.Binding("points").makeTwoWay(),e(Z.Shape,{strokeWidth:2},new Z.Binding("stroke","color"),new Z.Binding("strokeWidth","thickness"),new Z.Binding("strokeDashArray","dash")),e(Z.Shape,{segmentIndex:0,segmentOffset:new Z.Point(15,0),segmentOrientation:Z.Link.OrientAlong,alignmentFocus:Z.Spot.Right,figure:"circle",width:10,strokeWidth:0},new Z.Binding("fill","color"),new Z.Binding("visible","dir",(function(e){return 1===e}))),e(Z.Shape,{segmentIndex:-1,segmentOffset:new Z.Point(-10,6),segmentOrientation:Z.Link.OrientPlus90,alignmentFocus:Z.Spot.Right,figure:"triangle",width:12,height:12,strokeWidth:0},new Z.Binding("fill","color"),new Z.Binding("visible","dir",(function(e){return e>=1})),new Z.Binding("width","thickness",(function(e){return 7+3*e})),new Z.Binding("height","thickness",(function(e){return 7+3*e})),new Z.Binding("segmentOffset","thickness",(function(e){return new Z.Point(-15,4+1.5*e)}))),e(Z.Shape,{segmentIndex:0,segmentOffset:new Z.Point(15,-6),segmentOrientation:Z.Link.OrientMinus90,alignmentFocus:Z.Spot.Right,figure:"triangle",width:12,height:12,strokeWidth:0},new Z.Binding("fill","color"),new Z.Binding("visible","dir",(function(e){return 2===e})),new Z.Binding("width","thickness",(function(e){return 7+3*e})),new Z.Binding("height","thickness",(function(e){return 7+3*e})),new Z.Binding("segmentOffset","thickness",(function(e){return new Z.Point(-15,4+1.5*e)}))),e(Z.TextBlock,{alignmentFocus:new Z.Spot(0,1,-4,0),editable:!0},new Z.Binding("text").makeTwoWay(),new Z.Binding("stroke","color"))),n.current.linkTemplate.selectionAdornmentTemplate=e(Z.Adornment,e(Z.Shape,{isPanelMain:!0,stroke:"transparent",strokeWidth:6,pathPattern:P(2)},new Z.Binding("pathPattern","thickness",P)),y({alignmentFocus:new Z.Spot(0,0,-6,-4)})),n.current.linkTemplate.contextMenu=e("ContextMenu",S(),C(),e("ContextMenuButton",e(Z.Panel,"Horizontal",L(0),L(1),L(2))),e("ContextMenuButton",e(Z.Panel,"Horizontal",e(Z.Panel,"Spot",E(!1),N(Z.Spot.Top,!1),N(Z.Spot.Left,!1),N(Z.Spot.Right,!1),N(Z.Spot.Bottom,!1)),e(Z.Panel,"Spot",{margin:new Z.Margin(0,0,0,2)},E(!0),N(Z.Spot.Top,!0),N(Z.Spot.Left,!0),N(Z.Spot.Right,!0),N(Z.Spot.Bottom,!0))))),new Z.Palette(i.current,{maxSelectionCount:1,linkTemplate:e(Z.Link,{locationSpot:Z.Spot.Center,selectionAdornmentTemplate:e(Z.Adornment,"Link",{locationSpot:Z.Spot.Center},e(Z.Shape,{isPanelMain:!0,fill:null,stroke:"deepskyblue",strokeWidth:0}),e(Z.Shape,{toArrow:"Standard",stroke:null}))},{routing:Z.Link.AvoidsNodes,curve:Z.Link.JumpOver,corner:5,toShortLength:4},new Z.Binding("points"),e(Z.Shape,{isPanelMain:!0,strokeWidth:2}),e(Z.Shape,{toArrow:"Standard",stroke:null})),model:new Z.GraphLinksModel([{text:"未命名",size:"100 100",fill:null,stroke:"#000"}].concat(R()(Z.Shape.getFigureGenerators().toArray().map((function(e){return{text:"未命名",size:"100 100",figure:e.key,fill:"white",stroke:"#666",borderColor:"#000"}})))))}).nodeTemplate=e(Z.Node,"Auto",{locationSpot:Z.Spot.Center},new Z.Binding("location","location",Z.Point.parse).makeTwoWay(Z.Point.stringify),e(Z.Shape,"Circle",{fill:"white",stroke:"gray",strokeWidth:2,width:20,height:20,portId:"",fromLinkable:!0,toLinkable:!0,fromLinkableDuplicates:!0,toLinkableDuplicates:!0,fromLinkableSelfNode:!0,toLinkableSelfNode:!0},new Z.Binding("stroke").makeTwoWay(),new Z.Binding("fill").makeTwoWay(),new Z.Binding("figure")),e(Z.TextBlock,{margin:new Z.Margin(5,5,3,5),font:"10pt sans-serif",minSize:new Z.Size(16,16),maxSize:new Z.Size(10,NaN),textAlign:"center",editable:!0},new Z.Binding("key").makeTwoWay())),setTimeout((function(){n.current.grid=e(Z.Panel,"Grid",e(Z.Shape,"LineH",{stroke:"lightgray",strokeWidth:.5}),e(Z.Shape,"LineV",{stroke:"lightgray",strokeWidth:.5})),n.current.grid.visible=!0,n.current.grid.gridCellStroke="darkgray",n.current.grid.gridCellStrokeWidth=1}),300),window.myDiagrams=n.current,n.current},divClassName:"diagram-component",style:{height:"80vh"}}),(0,f.jsx)("div",{ref:a})]})]}),(0,f.jsx)("div",{className:"tr",children:(0,f.jsx)(S.ZP,{size:"large",onClick:h,style:{position:"absolute",right:0,bottom:0,zIndex:8},type:"primary",children:"保存到编辑器"})})]})})})},K=t(5112),Y=t(94001),J=K.ZP.Group,X={margin:"0 8px"},$=function(e){var l=e.callback,t=e.onCancel;return(0,f.jsxs)(_.Z,{className:"add-table-panel",initialValues:{row:3,col:2,align:"default"},onFinish:function(e){l(e)},children:[(0,f.jsxs)("div",{className:"flex-container",style:{alignItems:"baseline"},children:[(0,f.jsx)("span",{style:X,children:"单元格数:"}),(0,f.jsx)("span",{style:X,children:"行数"}),(0,f.jsx)(_.Z.Item,{name:"row",rules:[{required:!0,message:"请输入行数"}],children:(0,f.jsx)(Y.Z,{})}),(0,f.jsx)("span",{style:X,children:"列数"}),(0,f.jsx)(_.Z.Item,{name:"col",rules:[{required:!0,message:"请输入列数"}],children:(0,f.jsx)(Y.Z,{})})]}),(0,f.jsxs)("div",{className:"flex-container",style:{marginTop:12,alignItems:"baseline"},children:[(0,f.jsx)("span",{style:X,children:"对齐方式:"}),(0,f.jsx)(_.Z.Item,{name:"align",children:(0,f.jsxs)(J,{children:[(0,f.jsx)(K.ZP,{value:"default",children:(0,f.jsx)("i",{className:"fa fa-align-justify"})}),(0,f.jsx)(K.ZP,{value:"left",children:(0,f.jsx)("i",{className:"fa fa-align-left"})}),(0,f.jsx)(K.ZP,{value:"center",children:(0,f.jsx)("i",{className:"fa fa-align-center"})}),(0,f.jsx)(K.ZP,{value:"right",children:(0,f.jsx)("i",{className:"fa fa-align-right"})})]})})]}),(0,f.jsxs)("div",{className:"flex-container flex-end",children:[(0,f.jsx)(S.ZP,{type:"primary",htmlType:"submit",style:{marginRight:10},children:"确定"}),(0,f.jsx)(S.ZP,{type:"ghost",onClick:t,children:"取消"})]})]})},Q=t(78673),ee=t(83156),le=t.n(ee),te=(0,u.forwardRef)((function(e,l){var t=e.use3d,n=e.width,a=e.height,i=e.callback,r=(e.showSaveButton,(0,u.useRef)()),s=(0,u.useRef)(),c=(0,u.useState)(!1),d=o()(c,2),p=d[0],v=d[1],h=(0,u.useRef)({id:r,appName:"graphing",width:n||1e3,height:a||600,showToolBar:!0,showMenuBar:!0,allowStyleBar:!0,showAlgebraInput:!0,enableLabelDrags:!1,enableShiftDragZoom:!0,showToolBarHelp:!1,errorDialogsActive:!0,showTutorialLink:!0,showLogging:!0,useBrowserForJS:!1});(0,u.useEffect)((function(){s.current=new(le())(h.current,!0),window.onload=function(){s.current.inject("applet_container")}}),[]);var b=function(){var e=window.ggbApplet.getPNGBase64(1,!0,72);return i&&i(e),e};return(0,u.useEffect)((function(){h.current.appName=p?"3D":"graphing",s.current.inject("applet_container")}),[p]),(0,u.useEffect)((function(){v(t)}),[t]),(0,u.useImperativeHandle)(l,(function(){return{getImgData:b}})),(0,f.jsxs)(f.Fragment,{children:[(0,f.jsx)("div",{style:{width:"100%",height:"100%"},id:"applet_container",ref:r}),(0,f.jsxs)(P.Z,{align:"middle",children:[(0,f.jsx)(W.Z,{flex:1,children:(0,f.jsx)(Q.Z,{size:"default",checkedChildren:"关闭3D图像",unCheckedChildren:"开启3D图像",checked:p,onChange:function(e){return v(e)}})}),(0,f.jsx)(W.Z,{children:(0,f.jsx)(S.ZP,{size:"large",onClick:b,style:{zIndex:8,marginTop:10},type:"primary",children:"保存到编辑器"})})]})]})})),ne=t(97618),ae=t(15309),ie=t(8591),oe="link",re="upload-image",se="add-flowchart",ue="draw-image",ce="code-block",de="add-table",pe="------------",ve={default:pe,left:":".concat(pe),center:":".concat(pe,":"),right:"".concat(pe,":")},fe=t(70325);var he="@▁▁@",be=["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 me(e){return/^\d+$/.test(e)?"".concat(e,"px"):e}var ge=navigator.platform.toUpperCase().indexOf("MAC")>=0?"Cmd":"Ctrl",we=s()(s()({},ge+"-B","bold"),ge+"-I","italic"),ye=s()(s()(s()(s()(s()(s()(s()(s()({},oe,"添加链接"),ce,"添加代码块"),re,"添加图片"),ue,"添加画图"),se,"插入流程图"),de,"添加表格"),"maths-latex","数学图像"),"inline-latex","LATEX公式"),xe=function(e){var l=e.defaultValue,t=void 0===l?"":l,n=e.onChange,i=e.width,r=void 0===i?"100%":i,c=e.height,b=void 0===c?400:c,m=e.miniToolbar,g=void 0!==m&&m,w=e.isFocus,_=void 0!==w&&w,k=e.watch,S=e.insertTemp,B=e.mode,P=void 0===B?"markdown":B,L=e.id,N=void 0===L?"markdown-editor-id":L,M=e.showResizeBar,A=void 0!==M&&M,G=e.noStorage,O=void 0!==G&&G,R=e.showNullButton,Z=void 0!==R&&R,I=e.showNullProgramButton,F=void 0!==I&&I,D=e.hidetoolBar,W=void 0!==D&&D,z=e.fullScreen,V=void 0!==z&&z,q=e.onBlur,K=e.onCMBeforeChange,Y=e.onFullScreen,J=e.className,X=void 0===J?"":J,Q=e.disablePaste,ee=void 0!==Q&&Q,le=e.disabled,pe=void 0!==le&&le,ge=e.disabledFill,xe=void 0!==ge&&ge,_e=e.placeholder,ke=void 0===_e?"":_e,Se=e.values,Be=void 0===Se?"":Se,Te=e.extraUse,Ce=(0,u.useState)(null),je=o()(Ce,2),Pe=je[0],Le=je[1],Ee=(0,u.useState)(t),Ne=o()(Ee,2),Me=Ne[0],Ae=Ne[1],Ge=(0,u.useState)(k),Oe=o()(Ge,2),Re=Oe[0],Ze=Oe[1],Ie=(0,u.useState)(V),Fe=o()(Ie,2),De=Fe[0],He=Fe[1],We=(0,u.useState)(""),ze=o()(We,2),Ve=ze[0],qe=ze[1],Ue=(0,u.useState)(0),Ke=o()(Ue,2),Ye=Ke[0],Je=Ke[1],Xe=(0,u.useState)(b),$e=o()(Xe,2),Qe=$e[0],el=$e[1],ll=(0,u.useState)(!1),tl=o()(ll,2),nl=(tl[0],tl[1]),al=(0,u.useState)(0),il=o()(al,2),ol=il[0],rl=il[1],sl=(0,u.useState)(0),ul=o()(sl,2),cl=ul[0],dl=ul[1],pl=(0,u.useRef)(),vl=(0,u.useRef)(),fl=(0,u.useRef)(),hl=(0,u.useRef)();(0,u.useEffect)((function(){var e=window.scrollY||window.pageYOffset;Ae(Be),null==Pe||Pe.setValue(Be),window.scrollTo(0,e)}),[Be]),(0,u.useEffect)((function(){null==Y||Y(De)}),[De]),(0,u.useEffect)((function(){if(pl.current){var e=function(e,t){if(!ee){var n=t.clipboardData;if(n){var a=n.types.toString(),i=n.items;if("Files"===a||n.types.indexOf("Files")>-1){if(t.preventDefault(),"stex"==P)return;try{var o,r=i[1];"file"===(null===(o=i[0])||void 0===o?void 0:o.kind)&&(r=i[0]);var s=r.getAsFile(),u=s.name.split(".").pop();(0,j.I)(s,(function(e){var t,n,a;e.id?(null==s||null===(t=s.type)||void 0===t?void 0:t.indexOf("image"))>-1?l.replaceSelection("![,](/api/attachments/".concat(e.id,"?type=").concat(e.content_type,")")):(null==s||null===(n=s.type)||void 0===n?void 0:n.indexOf("video"))>-1?l.replaceSelection('<video width="100%" controls src="'.concat(ae.Z.API_SERVER,"/api/attachments/").concat(e.id,'"></video>')):(null==s||null===(a=s.type)||void 0===a?void 0:a.indexOf("pdf"))>-1?l.replaceSelection('<a href="'.concat(ae.Z.API_SERVER,"/api/attachments/").concat(e.id,"?type=").concat(s.type,'&disposition=inline" target="_blank">').concat(s.name,"</a>")):be.includes(u)?l.replaceSelection('<a href="'.concat(ae.Z.API_SERVER,"/api/attachments/").concat(e.id,'?type=office&disposition=inline" target="_blank">').concat(s.name,"</a>")):l.replaceSelection("[".concat(s.name,"](").concat(ae.Z.API_SERVER,"/api/attachments/").concat(e.id,"?type=").concat(e.content_type,")")):401===(null==e?void 0:e.status)&&(document.location.href="/user/login")}))}catch(t){ie.ZP.warning("请使用chrome浏览器粘贴")}return!0}return!0}return!0}t.preventDefault()},l=d().fromTextArea(pl.current,{mode:P,lineNumbers:!g,lineWrapping:!0,value:t,autoCloseTags:!0,autoCloseBrackets:!0});return l.on("keyup",(function(e,t){8===t.keyCode&&(""==e.getValue()?l.setOption("placeholder",ke):l.setOption("placeholder",null))})),l.on("keydown",(function(e,l){if(8===l.keyCode){var t=function(e,l){var t=e.getDoc(),n=t.getCursor(),a=t.getLine(n.line),i=a.charAt(n.ch-1),o=a.lastIndexOf("@▁@",n.ch),r=a.lastIndexOf("@▁▁@",n.ch),s=o>r?o:r,u=o>r?3:4;if(-1===he.indexOf(i))return null;if(console.log("change1:",l,e,a,n,s,o,r,i),s>=0&&n.ch-s<5){var c=s+u;return t.replaceRange("",{line:n.line,ch:s},{line:n.line,ch:c}),{line:n.line,ch:c}}return null}(e);t&&l.preventDefault()}})),_&&l.focus(),l.on("paste",e),pe&&l.on("beforeChange",(function(e,l){"paste"!==l.origin&&"+input"!==l.origin||l.cancel()})),Le(l),function(){l.off("paste",e)}}}),[]);var bl=(0,u.useCallback)((function(){vl.current}),[Qe,vl,De]);(0,u.useEffect)((function(){if(Pe){var e=function(){var e=new p.Z((function(e){var l,t=a()(e);try{for(t.s();!(l=t.n()).done;){var n=l.value;(n.target.offsetHeight>0||n.target.offsetWidth>0)&&(bl(),Pe.setSize("100%","100%"),Pe.refresh())}}catch(e){t.e(e)}finally{t.f()}}));return e.observe(pl.current.parentElement),e}();return function(){var l,t;null!==(l=pl.current)&&void 0!==l&&l.parentElement&&e.unobserve(null===(t=pl.current)||void 0===t?void 0:t.parentElement)}}}),[Pe,bl]),(0,u.useEffect)((function(){if(Pe){for(var e=[],l=function(){var l=o()(n[t],2),a=l[0],i=l[1],r=s()({},a,(function(){ml(i)}));e.push(r),Pe.addKeyMap(r)},t=0,n=Object.entries(we);t<n.length;t++)l();return function(){for(var l=0,t=e;l<t.length;l++){var n=t[l];Pe.removeKeyMap(n)}}}}),[Pe]),(0,u.useEffect)((function(){V!==De&&He(V)}),[V]),(0,fe.Z)((function(){if(!O&&Ye>0){var e=(new Date).getTime(),l=window.sessionStorage.getItem(N);e>=Ye+1e4&&(!l||l!==Me)&&(window.sessionStorage.setItem(N,Me),nl(!0))}}),1e4),(0,u.useEffect)((function(){Ze(k)}),[Pe,k]),(0,u.useEffect)((function(){Pe&&_&&Pe.focus()}),[Pe,_]),(0,u.useEffect)((function(){if(Re&&Pe){var e=function(e){var l=e.target;if(hl.current){var t=l.scrollTop/l.scrollHeight;hl.current.scrollTop=hl.current.scrollHeight*t}},l=Pe.getScrollerElement();return l.addEventListener("scroll",e),function(){l.removeEventListener("scroll",e)}}}),[Pe,Re]),(0,u.useEffect)((function(){if(Pe&&K){var e=function(e,l){K(e,l)};return Pe.on("beforeChange",e),function(){Pe.off("beforeChange",e)}}}),[Pe,K]),(0,u.useEffect)((function(){if(Pe&&q){var e=function(){q(Pe.getValue())};return Pe.on("blur",e),function(){Pe.off("blur",e)}}}),[Pe,q]),(0,u.useEffect)((function(){if(Pe){var e=function(e,l){var t=e.getValue();Ae(t),Je((new Date).getTime()),e.getScrollerElement().dispatchEvent(new CustomEvent("scroll")),n&&(F?n(t,_l(t)):n(t))};return Pe.on("change",e),function(){Pe.off("change",e)}}}),[Pe,n]),(0,u.useEffect)((function(){if(Pe)if(null==t)Pe.setValue(""),Ae("");else{var e=window.scrollY||window.pageYOffset;t!==Pe.getValue()&&(Pe.setValue(t),Ae(t),Pe.setCursor(pe?1:Pe.lineCount(),0),window.scrollTo(0,e))}}),[Pe,t]);var ml=(0,u.useCallback)((function(e){var l=Pe.getCursor(),t=Pe.getSelection(),n=t.split("\n");switch(e){case"bold":return Pe.replaceSelection("**"+t+"**"),""===t&&Pe.setCursor(l.line,l.ch+2),Pe.focus();case"italic":return Pe.replaceSelection("*"+t+"*"),""===t&&Pe.setCursor(l.line,l.ch+1),Pe.focus();case"code":return Pe.replaceSelection("`"+t+"`"),""===t&&Pe.setCursor(l.line,l.ch+1),Pe.focus();case"inline-latex":return qe("inline-latex"),Pe.focus();case"latex":return Pe.replaceSelection("```latex\n"+t+"\n```"),Pe.setCursor(l.line+1,t.length+1),Pe.focus();case"line-break":return Pe.replaceSelection("<br/>\n"),Pe.focus();case"list-ul":return""===t?Pe.replaceSelection("- "+t):Pe.replaceSelection(n.map((function(e){return""===e?"":"- ".concat(e)})).join("\n")),Pe.focus();case"list-ol":return""===t?Pe.replaceSelection("1. "+t):Pe.replaceSelection(n.map((function(e,l){return""===e?"":"".concat(l+1,". ").concat(e)})).join("\n")),Pe.focus();case"add-null-ch":return""===t&&Pe.setCursor(l.line,l.ch),Pe.replaceSelection("▁"),Pe.focus();case"add-signal":return""===t&&Pe.setCursor(l.line,l.ch),Pe.replaceSelection("@▁@"),Pe.focus();case"add-multiple":return""===t&&Pe.setCursor(l.line,l.ch),Pe.replaceSelection(he),Pe.focus();case"inster-template-1":return""===t&&Pe.setCursor(l.line,l.ch),Pe.replaceSelection("\n**模板标题**\n模板正文内容可输入文本内容和粘贴图片等操作"),Pe.focus();case"eraser":return Pe.setValue(""),Pe.focus();case"trigger-watch":return Ze(!Re),Pe.focus();case"trigger-full-screen":return He(!De),Pe.focus();case oe:return void qe(oe);case ce:return void qe(ce);case re:return void qe(re);case ue:return void qe(ue);case"maths-latex":return void qe("maths-latex");case se:return void qe(se);case de:return void qe(de);default:throw new Error}}),[Pe,Re,De]),gl=(0,u.useCallback)((function(e,l){var t,n,a,i,o;switch(qe(""),Ve){case oe:var r=e.title,s=e.link;return Pe.replaceSelection("[".concat(r,"](").concat(s,")")),Pe.focus();case ce:var u=e.language,c=e.content;return Pe.replaceSelection(["```"+u,c,"```"].join("\n")),Pe.focus();case"maths-latex":for(var d=atob(e),p=new Uint8Array(d.length),v=0;v<d.length;v++)p[v]=d.charCodeAt(v);var f=new Blob([p],{type:"image/png"});(0,j.I)(f,(function(e){e.id?Pe.replaceSelection("![,](/api/attachments/".concat(e.id,"?type=").concat(e.content_type,")")):401===(null==e?void 0:e.status)&&(document.location.href="/user/login")}));break;case"inline-latex":Pe.replaceSelection("`$$"+e+"$$`");break;case re:case ue:case"add-flowchart":var h=e.src,b=e.alt,m=l,g=null==m||null===(t=m.name)||void 0===t||null===(t=t.split("."))||void 0===t||null===(n=t.pop)||void 0===n?void 0:n.call(t);return(null==m||null===(a=m.type)||void 0===a?void 0:a.indexOf("image"))>-1||null==m||!m.type?b?Pe.replaceSelection("![ ".concat(b," ]( ").concat(h,' "').concat(b,'" )')):Pe.replaceSelection("![,](".concat(h,")")):(null==m||null===(i=m.type)||void 0===i?void 0:i.indexOf("video"))>-1?Pe.replaceSelection('<video width="100%" controls src="'.concat(ae.Z.API_SERVER).concat(h,'"></video>')):(null==m||null===(o=m.type)||void 0===o?void 0:o.indexOf("pdf"))>-1?Pe.replaceSelection('<a href="'.concat(ae.Z.API_SERVER).concat(h,"?type=").concat(m.type,'&disposition=inline" target="_blank">').concat(m.name,"</a>")):be.includes(g)?Pe.replaceSelection('<a href="'.concat(ae.Z.API_SERVER).concat(h,'?type=office&disposition=inline" target="_blank">').concat(m.name,"</a>")):Pe.replaceSelection("[".concat(m.name,"](").concat(ae.Z.API_SERVER).concat(h,")")),Pe.focus();case de:for(var w=e.row,y=e.col,x=e.align,_="\n",k=0;k<w;k++){for(var S=[],B=[],T=0;T<y;T++)1===k&&B.push(ve[x]),S.push(" ");1===k&&(_+="| ".concat(B.join(" | ")," |\n")),_+="| ".concat(S.join(1===y?"":" | ")," |\n")}return Pe.replaceSelection(_+"\n"),Pe.focus();default:throw new Error}}),[Pe,Ve]),wl=(0,u.useMemo)((function(){switch(Ve){case oe:return(0,f.jsx)(T,{callback:gl,onCancel:yl});case ce:return(0,f.jsx)(C.Z,{callback:gl,onCancel:yl});case re:return(0,f.jsx)(j.Z,{callback:gl,onCancel:yl});case se:return(0,f.jsx)(U,{callback:gl,onCancel:yl});case de:return(0,f.jsx)($,{callback:gl,onCancel:yl});case"maths-latex":return(0,f.jsx)(te,{showSaveButton:!0,callback:gl});case"inline-latex":return(0,f.jsx)(ne.Z,{showSaveButton:!0,callback:gl});default:return null}}),[Ve]);function yl(){qe("")}(0,u.useEffect)((function(){if(fl.current){var e=function(e){a=!0,i=e.pageY},l=function(){a=!1},t=function(e){if(a){var l=e.pageY-i;l<0&&(l=0),l>300&&(l=300),el(b+l+"px")}},n=fl.current,a=!1,i=0;return n.addEventListener("mousedown",e),document.addEventListener("mousemove",t),document.addEventListener("mouseup",l),function(){n.removeEventListener("mousedown",e),document.removeEventListener("mousemove",t),document.removeEventListener("mouseup",l)}}}),[Pe,fl]),(0,u.useEffect)((function(){el(b)}),[b]);var xl={width:me(r),height:me(Qe)},_l=((0,u.useMemo)((function(){if(Ye){var e=new Date(Ye),l=e.getHours(),t=e.getMinutes(),n=e.getSeconds();return t=t<10?"0"+t:t,n=n<10?"0"+n:n,"".concat(l=l<10?"0"+l:l,":").concat(t,":").concat(n)}return 0}),[Ye]),function(e){var l=[];if(F){e=e.replace(/(@▁▁@|@▁@)/g,(function(e,t,n){l.push({multiLine:!("@▁@"===e)})}))}return l});(0,u.useEffect)((function(){ye[Ve]&&Ve!==ue&&Ve!==se&&setTimeout((function(){var e=document.getElementsByClassName("markdown-popup-form")[0],l=window.innerWidth/2-e.offsetWidth/2,t=window.innerHeight/2-e.offsetHeight/2;rl(l),dl(t)}),0)}),[Ve]);var kl=function(e,l,t,n){var a=document.body.clientHeight,i=document.body.clientWidth;return!(e<20&&t>e||e>i-20&&t<e||l<20&&n>l||l>a-20&&n<l)||(document.body.onmousemove=null,document.body.onmouseup=null,!1)};return(0,f.jsxs)(u.Fragment,{children:[(0,f.jsx)("div",{className:"markdown-editor-wrapper",ref:vl,children:(0,f.jsxs)("div",{className:"markdown-editor-container ".concat(X," ").concat(Re?"on-preview":""," ").concat(g?"mini":""," ").concat(De?"full-screen":""),style:xl,children:[(0,f.jsx)(y,{insertTemp:S,watch:Re,fullScreen:De,showNullButton:Z,showNullProgramButton:F,onActionCallback:ml,hidetoolBar:W,extraUse:Te}),(0,f.jsxs)("div",{className:"markdown-editor-body",children:[(0,f.jsx)("div",{className:"codemirror-container",children:(0,f.jsx)("textarea",{ref:pl,placeholder:ke})}),Re?(0,f.jsxs)("div",{ref:hl,className:"preview-container",children:["stex"===P&&(0,f.jsx)(h,{value:Me}),"stex"!==P&&(0,f.jsx)(v.Z,{disabledFill:xe,showProgramFill:F,value:Me})]}):null]})]})}),A?(0,f.jsx)("a",{ref:fl,className:"editor-resize"}):null,Ve===ue&&(0,f.jsx)(E,{callback:gl,onCancel:yl}),Ve===se&&(0,f.jsx)(U,{callback:gl,onCancel:yl}),(0,f.jsx)(x.Z,{children:ye[Ve]&&Ve!==ue&&Ve!==se?(0,f.jsx)(H.Z,{maskClosable:!1,centered:!0,style:{position:"absolute",left:ol,top:cl},title:(0,f.jsx)("div",{style:{cursor:"move"},onMouseDown:function(e){e.preventDefault();var l=e.clientX-ol,t=e.clientY-cl;document.body.onmousemove=function(e){var n=e.clientX-l,a=e.clientY-t,i=document.getElementsByClassName("markdown-popup-form")[0],o=window.innerWidth-i.offsetWidth,r=window.innerHeight-i.offsetHeight;n=Math.max(0,Math.min(n,o)),a=Math.max(0,Math.min(a,r)),kl(e.clientX,e.clientY,l,t)&&(rl(n),dl(a))},document.body.onmouseup=function(){document.body.onmousemove=null}},children:ye[Ve]}),open:!0,onCancel:yl,footer:null,destroyOnClose:!0,width:Ve===se?"1200px":null,height:Ve===se?"80vh":null,className:"markdown-popup-form",children:wl}):null})]})}},8899:function(e,l,t){"use strict";t.d(l,{Z:function(){return m},I:function(){return w}});var n=t(82242),a=t.n(n),i=t(79800),o=t.n(i),r=t(78241),s=t(8591),u=t(92832),c=t(3113),d=t(18468),p=t(59301),v=t(37712),f=r.Z.useForm,h={width:280,marginRight:10},b={labelCol:{span:5},wrapperCol:{span:19}},m=function(e){var l=e.callback,t=e.onCancel,n=f(),i=o()(n,1)[0],d=(0,p.useRef)();function m(e,l){-1!==e.status?i.setFieldsValue({src:"/api/attachments/".concat(e.id),type:l.type}):s.ZP.error(e.message)}return(0,v.jsxs)(r.Z,a()(a()({form:i},b),{},{className:"upload-image-panel",onFinish:function(e){l(e,d.current)},style:{width:470,overflow:"hidden"},children:[(0,v.jsx)(r.Z.Item,{label:"图片地址",required:!0,children:(0,v.jsxs)("div",{className:"flex-container",children:[(0,v.jsx)(r.Z.Item,{noStyle:!0,name:"src",rules:[{required:!0,message:"请输入图片地址"}],children:(0,v.jsx)(u.Z,{style:h})}),(0,v.jsx)(g,{onFileChange:function(e){var l=e.target.files[0];d.current=l,w(l,m)}})]})}),(0,v.jsx)(r.Z.Item,{label:"图片描述",name:"alt",children:(0,v.jsx)(u.Z,{style:{width:264}})}),(0,v.jsxs)(r.Z.Item,{style:{textAlign:"right"},children:[(0,v.jsx)(c.ZP,{type:"primary",htmlType:"submit",style:{marginRight:10},children:"确定"}),(0,v.jsx)(c.ZP,{type:"default",onClick:t,children:"取消"})]})]}))};function g(e){var l=e.onFileChange;return(0,v.jsxs)("label",{className:"upload-button",style:{cursor:"pointer"},children:["本地上传",(0,v.jsx)("input",{type:"file",onChange:l})]})}function w(e,l){if(!e)throw new String("没有文件");var t=new FormData;t.append("editormd-image-file",e),t.append("file_param_name","editormd-image-file"),t.append("byxhr","true");var n=new window.XMLHttpRequest;n.withCredentials=!0,n.addEventListener("load",(function(t){l(JSON.parse(t.target.responseText),e)}),!1),n.addEventListener("error",(function(e){console.error(e)}),!1),n.open("POST","".concat(d.KI,"/api/attachments.json")),n.send(t)}},56386:function(e,l,t){"use strict";t.d(l,{Z:function(){return v}});var n=t(82100),a=t.n(n),i=t(29186),o=t.n(i),r=t(80619),s=t.n(r),u=t(47074),c=t.n(u),d=t(59301),p=t(4676),v=function(e){s()(t,e);var l=c()(t);function t(e){var n;a()(this,t),n=l.call(this,e);var i=window.document;return n.node=i.createElement("div"),i.body.appendChild(n.node),n}return o()(t,[{key:"render",value:function(){var e=this.props.children;return(0,p.createPortal)(e,this.node)}},{key:"componentWillUnmount",value:function(){window.document.body.removeChild(this.node)}}]),t}(d.Component)},70325:function(e,l,t){"use strict";t.d(l,{Z:function(){return a}});var n=t(59301);function a(e,l){var t=(0,n.useRef)();(0,n.useEffect)((function(){t.current=e})),(0,n.useEffect)((function(){if(null!==l){var e=setInterval((function(){t.current()}),l);return function(){return clearInterval(e)}}}),[l])}},86955:function(e,l,t){"use strict";t.r(l),t.d(l,{default:function(){return N}});var n=t(7557),a=t.n(n),i=t(82242),o=t.n(i),r=t(41498),s=t.n(r),u=t(79800),c=t.n(u),d=t(39647),p=t.n(d),v=t(59301),f=t(7575),h=t(51876),b=t(20834),m=t(44e3),g=t(78241),w=t(8591),y=t(66104),x=t(95237),_=t(43604),k=t(57809),S=t(92832),B=t(28103),T=t(19842),C=t(3113),j=t(50439),P={flex_box_center:"flex_box_center___JefHi",flex_space_between:"flex_space_between___N1h0l",flex_box_vertical_center:"flex_box_vertical_center___Mtb4t",flex_box_center_end:"flex_box_center_end___F6G6K",flex_box_column:"flex_box_column___JldFX",bg:"bg___Hgook",title:"title____XaYs",titleLeft:"titleLeft___xe0PB",titleRight:"titleRight___wML5g",btns:"btns___l22_n"},L=t(37712),E=["graduation","globalSetting","loading","user","dispatch"],N=(b.Z.SubMenu,m.Z.Content,m.Z.Sider,(0,h.connect)((function(e){var l=e.graduation,t=e.loading,n=e.user;return{graduation:l,globalSetting:e.globalSetting,user:n,loading:t.effects}}))((function(e){var l,t,n,i,r,u,d,b=e.graduation,m=(e.globalSetting,e.loading,e.user),N=e.dispatch,M=(p()(e,E),(0,h.useParams)()),A=((0,h.useLocation)(),m.userInfo),G=g.Z.useForm(),O=c()(G,1)[0],R=b.addTopicData,Z=function(){var e=s()(a()().mark((function e(){var l,t,n;return a()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return l=O.getFieldsValue(),(t=o()({},l)).city&&(t.province=t.city[0],t.city=t.city[1]),e.next=5,N({type:"graduation/addTopic",payload:{coursesId:M.coursesId,attachment_ids:[],graduation_topic:t}});case 5:(n=e.sent).status?w.ZP.error(n.message):h.history.push("/classrooms/".concat(M.coursesId,"/graduation_topics/").concat(M.categoryId));case 7:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}();return(0,v.useEffect)((function(){N({type:"graduation/addTopicDefaultData",payload:o()({},M)})}),[M.coursesId]),(0,L.jsxs)("section",{className:"edu-container",children:[(0,L.jsxs)("section",{className:"animated fadeIn",children:[(0,L.jsx)("aside",{className:"mt10",children:A&&(0,L.jsxs)(y.Z,{separator:">",children:[(0,L.jsx)(y.Z.Item,{children:(0,L.jsx)(h.Link,{to:"".concat(A.first_category_url),children:null==A||null===(l=A.course)||void 0===l?void 0:l.course_name})}),(0,L.jsx)(y.Z.Item,{children:(0,L.jsx)(h.Link,{to:"/classrooms/".concat(M.coursesId,"/graduation_topics/").concat(M.categoryId),children:"毕设选题"})}),(0,L.jsx)(y.Z.Item,{children:"新建"})]})}),(0,L.jsx)("aside",{className:[P.title,"mt20"].join(" "),children:(0,L.jsxs)(x.Z,{style:{width:"100%"},children:[(0,L.jsx)(_.Z,{flex:"1",children:(0,L.jsx)("strong",{className:"font20 ml5",children:"新建毕设选题"})}),(0,L.jsx)(_.Z,{children:(0,L.jsx)(h.Link,{className:"font16 c-light-black",to:"/classrooms/".concat(M.coursesId,"/exercise"),children:"返回"})})]})})]}),(0,L.jsx)("section",{className:[P.bg,"pt30","pl30","pr30","pb30","mt20"].join(" "),children:(0,L.jsxs)(g.Z,{layout:"vertical",form:O,scrollToFirstError:!0,onFinish:function(){var e=s()(a()().mark((function e(l){return a()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:Z();case 1:case"end":return e.stop()}}),e)})));return function(l){return e.apply(this,arguments)}}(),children:[(0,L.jsx)(g.Z.Item,{name:"tea_id",label:"指导老师:",rules:[{required:!0,message:"请选择指导老师"}],children:(0,L.jsx)(k.default,{size:"middle",placeholder:"请选择指导老师",style:{width:200},children:null===(t=R.teacher_list)||void 0===t?void 0:t.map((function(e,l){return(0,L.jsx)(k.default.Option,{value:e.id,children:e.name},l)}))})}),(0,L.jsx)(g.Z.Item,{name:"name",label:"选题名称:",rules:[{required:!0,message:"请填写试卷标题"}],children:(0,L.jsx)(S.Z,{maxLength:60,size:"middle",placeholder:"试卷标题最大限制60个字符"})}),(0,L.jsx)(B.Z,{}),(0,L.jsx)(g.Z.Item,{label:"选题简介",name:"description",rules:[{required:!0,message:"请输入内容"}],children:(0,L.jsx)(f.Z,{watch:!0,placeholder:"请简要说明选题内容最大限制5000个字符"})}),(0,L.jsxs)(x.Z,{gutter:[20,0],children:[(0,L.jsx)(_.Z,{flex:"1",children:(0,L.jsx)(g.Z.Item,{name:"topic_type",children:(0,L.jsx)(k.default,{size:"middle",placeholder:"请选择选题类型",children:null===(n=R.topic_type)||void 0===n?void 0:n.map((function(e,l){return(0,L.jsx)(k.default.Option,{value:e.id,children:e.name},l)}))})})}),(0,L.jsx)(_.Z,{flex:"1",children:(0,L.jsx)(g.Z.Item,{name:"topic_source",children:(0,L.jsx)(k.default,{size:"middle",placeholder:"请选择选题来源",children:null===(i=R.topic_source)||void 0===i?void 0:i.map((function(e,l){return(0,L.jsx)(k.default.Option,{value:e.id,children:e.name},l)}))})})}),(0,L.jsx)(_.Z,{flex:"1",children:(0,L.jsx)(g.Z.Item,{name:"topic_property_first",children:(0,L.jsx)(k.default,{size:"middle",placeholder:"请选择选题性质1",children:null===(r=R.topic_property_first)||void 0===r?void 0:r.map((function(e,l){return(0,L.jsx)(k.default.Option,{value:e.id,children:e.name},l)}))})})}),(0,L.jsx)(_.Z,{flex:"1",children:(0,L.jsx)(g.Z.Item,{name:"topic_property_second",children:(0,L.jsx)(k.default,{size:"middle",placeholder:"请选择选题性质2",children:null===(u=R.topic_property_second)||void 0===u?void 0:u.map((function(e,l){return(0,L.jsx)(k.default.Option,{value:e.id,children:e.name},l)}))})})}),(0,L.jsx)(_.Z,{flex:"150px"})]}),(0,L.jsx)(B.Z,{}),(0,L.jsx)(g.Z.Item,{name:"source_unit",label:"选题来源单位:",children:(0,L.jsx)(S.Z,{width:"200",size:"middle",style:{width:200},placeholder:"请填写来源单位"})}),(0,L.jsx)(g.Z.Item,{name:"topic_repeat",label:"选题重复情况:",children:(0,L.jsx)(k.default,{size:"middle",placeholder:"请选择重复情况",style:{width:200},children:null===(d=R.topic_repeat)||void 0===d?void 0:d.map((function(e,l){return(0,L.jsx)(k.default.Option,{value:e.id,children:e.name},l)}))})}),(0,L.jsx)(g.Z.Item,{name:"city",label:"调研或实习地点:",children:(0,L.jsx)(T.Z,{size:"middle",style:{width:200},options:j.P,placeholder:"请选择所在地"})})]})}),(0,L.jsxs)("aside",{className:P.btns,children:[(0,L.jsx)(C.ZP,{type:"primary",onClick:function(){O.submit()},children:"保存"}),(0,L.jsx)(h.Link,{to:"/classrooms/".concat(M.coursesId,"/graduation_topics/").concat(M.categoryId),children:"取消"})]})]})})))},50439:function(e,l,t){"use strict";t.d(l,{P:function(){return n}});var n=[{value:"北京",label:"北京",children:[{value:"东城",label:"东城"},{value:"西城",label:"西城"},{value:"朝阳",label:"朝阳"},{value:"丰台",label:"丰台"},{value:"石景山",label:"石景山"},{value:"海淀",label:"海淀"},{value:"门头沟",label:"门头沟"},{value:"房山",label:"房山"},{value:"通州",label:"通州"},{value:"顺义",label:"顺义"},{value:"昌平",label:"昌平"},{value:"大兴",label:"大兴"},{value:"平谷",label:"平谷"},{value:"怀柔",label:"怀柔"},{value:"密云",label:"密云"},{value:"延庆",label:"延庆"}]},{value:"上海",label:"上海",children:[{value:"崇明",label:"崇明"},{value:"黄浦",label:"黄浦"},{value:"卢湾",label:"卢湾"},{value:"徐汇",label:"徐汇"},{value:"长宁",label:"长宁"},{value:"静安",label:"静安"},{value:"普陀",label:"普陀"},{value:"闸北",label:"闸北"},{value:"虹口",label:"虹口"},{value:"杨浦",label:"杨浦"},{value:"闵行",label:"闵行"},{value:"宝山",label:"宝山"},{value:"嘉定",label:"嘉定"},{value:"浦东",label:"浦东"},{value:"金山",label:"金山"},{value:"松江",label:"松江"},{value:"青浦",label:"青浦"},{value:"南汇",label:"南汇"},{value:"奉贤",label:"奉贤"}]},{value:"广东",label:"广东",children:[{value:"广州",label:"广州"},{value:"深圳",label:"深圳"},{value:"珠海",label:"珠海"},{value:"东莞",label:"东莞"},{value:"中山",label:"中山"},{value:"佛山",label:"佛山"},{value:"惠州",label:"惠州"},{value:"河源",label:"河源"},{value:"潮州",label:"潮州"},{value:"江门",label:"江门"},{value:"揭阳",label:"揭阳"},{value:"茂名",label:"茂名"},{value:"梅州",label:"梅州"},{value:"清远",label:"清远"},{value:"汕头",label:"汕头"},{value:"汕尾",label:"汕尾"},{value:"韶关",label:"韶关"},{value:"顺德",label:"顺德"},{value:"阳江",label:"阳江"},{value:"云浮",label:"云浮"},{value:"湛江",label:"湛江"},{value:"肇庆",label:"肇庆"}]},{value:"江苏",label:"江苏",children:[{value:"南京",label:"南京"},{value:"常熟",label:"常熟"},{value:"常州",label:"常州"},{value:"海门",label:"海门"},{value:"淮安",label:"淮安"},{value:"江都",label:"江都"},{value:"江阴",label:"江阴"},{value:"昆山",label:"昆山"},{value:"连云港",label:"连云港"},{value:"南通",label:"南通"},{value:"启东",label:"启东"},{value:"沭阳",label:"沭阳"},{value:"宿迁",label:"宿迁"},{value:"苏州",label:"苏州"},{value:"太仓",label:"太仓"},{value:"泰州",label:"泰州"},{value:"同里",label:"同里"},{value:"无锡",label:"无锡"},{value:"徐州",label:"徐州"},{value:"盐城",label:"盐城"},{value:"扬州",label:"扬州"},{value:"宜兴",label:"宜兴"},{value:"仪征",label:"仪征"},{value:"张家港",label:"张家港"},{value:"镇江",label:"镇江"}]},{value:"重庆",label:"重庆",children:[{value:"万州",label:"万州"},{value:"涪陵",label:"涪陵"},{value:"渝中",label:"渝中"},{value:"大渡口",label:"大渡口"},{value:"江北",label:"江北"},{value:"沙坪坝",label:"沙坪坝"},{value:"九龙坡",label:"九龙坡"},{value:"南岸",label:"南岸"},{value:"北碚",label:"北碚"},{value:"万盛",label:"万盛"},{value:"双挢",label:"双挢"},{value:"渝北",label:"渝北"},{value:"巴南",label:"巴南"},{value:"黔江",label:"黔江"},{value:"长寿",label:"长寿"},{value:"綦江",label:"綦江"},{value:"潼南",label:"潼南"},{value:"铜梁",label:"铜梁"},{value:"大足",label:"大足"},{value:"荣昌",label:"荣昌"},{value:"壁山",label:"壁山"},{value:"梁平",label:"梁平"},{value:"城口",label:"城口"},{value:"丰都",label:"丰都"},{value:"垫江",label:"垫江"},{value:"武隆",label:"武隆"},{value:"忠县",label:"忠县"},{value:"开县",label:"开县"},{value:"云阳",label:"云阳"},{value:"奉节",label:"奉节"},{value:"巫山",label:"巫山"},{value:"巫溪",label:"巫溪"},{value:"石柱",label:"石柱"},{value:"秀山",label:"秀山"},{value:"酉阳",label:"酉阳"},{value:"彭水",label:"彭水"},{value:"江津",label:"江津"},{value:"合川",label:"合川"},{value:"永川",label:"永川"},{value:"南川",label:"南川"}]},{value:"安徽",label:"安徽",children:[{value:"合肥",label:"合肥"},{value:"安庆",label:"安庆"},{value:"蚌埠",label:"蚌埠"},{value:"亳州",label:"亳州"},{value:"巢湖",label:"巢湖"},{value:"滁州",label:"滁州"},{value:"阜阳",label:"阜阳"},{value:"贵池",label:"贵池"},{value:"淮北",label:"淮北"},{value:"淮化",label:"淮化"},{value:"淮南",label:"淮南"},{value:"黄山",label:"黄山"},{value:"九华山",label:"九华山"},{value:"六安",label:"六安"},{value:"马鞍山",label:"马鞍山"},{value:"宿州",label:"宿州"},{value:"铜陵",label:"铜陵"},{value:"屯溪",label:"屯溪"},{value:"芜湖",label:"芜湖"},{value:"宣城",label:"宣城"}]},{value:"福建",label:"福建",children:[{value:"福州",label:"福州"},{value:"厦门",label:"厦门"},{value:"泉州",label:"泉州"},{value:"漳州",label:"漳州"},{value:"龙岩",label:"龙岩"},{value:"南平",label:"南平"},{value:"宁德",label:"宁德"},{value:"莆田",label:"莆田"},{value:"三明",label:"三明"}]},{value:"甘肃",label:"甘肃",children:[{value:"兰州",label:"兰州"},{value:"嘉峪关",label:"嘉峪关"},{value:"白银",label:"白银"},{value:"定西",label:"定西"},{value:"敦煌",label:"敦煌"},{value:"甘南",label:"甘南"},{value:"金昌",label:"金昌"},{value:"酒泉",label:"酒泉"},{value:"临夏",label:"临夏"},{value:"平凉",label:"平凉"},{value:"天水",label:"天水"},{value:"陇南",label:"陇南"},{value:"武威",label:"武威"},{value:"西峰",label:"西峰"},{value:"张掖",label:"张掖"}]},{value:"广西",label:"广西",children:[{value:"南宁",label:"南宁"},{value:"来宾",label:"来宾"},{value:"百色",label:"百色"},{value:"北海",label:"北海"},{value:"桂林",label:"桂林"},{value:"防城港",label:"防城港"},{value:"贵港",label:"贵港"},{value:"河池",label:"河池"},{value:"贺州",label:"贺州"},{value:"柳州",label:"柳州"},{value:"钦州",label:"钦州"},{value:"梧州",label:"梧州"},{value:"玉林",label:"玉林"}]},{value:"贵州",label:"贵州",children:[{value:"贵阳",label:"贵阳"},{value:"安顺",label:"安顺"},{value:"毕节",label:"毕节"},{value:"都匀",label:"都匀"},{value:"凯里",label:"凯里"},{value:"六盘水",label:"六盘水"},{value:"铜仁",label:"铜仁"},{value:"兴义",label:"兴义"},{value:"玉屏",label:"玉屏"},{value:"遵义",label:"遵义"}]},{value:"海南",label:"海南",children:[{value:"海口",label:"海口"},{value:"儋县",label:"儋县"},{value:"陵水",label:"陵水"},{value:"琼海",label:"琼海"},{value:"三亚",label:"三亚"},{value:"通什",label:"通什"},{value:"万宁",label:"万宁"}]},{value:"河北",label:"河北",children:[{value:"石家庄",label:"石家庄"},{value:"保定",label:"保定"},{value:"北戴河",label:"北戴河"},{value:"沧州",label:"沧州"},{value:"承德",label:"承德"},{value:"丰润",label:"丰润"},{value:"邯郸",label:"邯郸"},{value:"衡水",label:"衡水"},{value:"廊坊",label:"廊坊"},{value:"南戴河",label:"南戴河"},{value:"秦皇岛",label:"秦皇岛"},{value:"唐山",label:"唐山"},{value:"新城",label:"新城"},{value:"邢台",label:"邢台"},{value:"张家口",label:"张家口"}]},{value:"黑龙江",label:"黑龙江",children:[{value:"哈尔滨",label:"哈尔滨"},{value:"北安",label:"北安"},{value:"大庆",label:"大庆"},{value:"大兴安岭",label:"大兴安岭"},{value:"鹤岗",label:"鹤岗"},{value:"黑河",label:"黑河"},{value:"佳木斯",label:"佳木斯"},{value:"鸡西",label:"鸡西"},{value:"牡丹江",label:"牡丹江"},{value:"齐齐哈尔",label:"齐齐哈尔"},{value:"七台河",label:"七台河"},{value:"双鸭山",label:"双鸭山"},{value:"绥化",label:"绥化"},{value:"伊春",label:"伊春"}]},{value:"河南",label:"河南",children:[{value:"郑州",label:"郑州"},{value:"安阳",label:"安阳"},{value:"鹤壁",label:"鹤壁"},{value:"潢川",label:"潢川"},{value:"焦作",label:"焦作"},{value:"济源",label:"济源"},{value:"开封",label:"开封"},{value:"漯河",label:"漯河"},{value:"洛阳",label:"洛阳"},{value:"南阳",label:"南阳"},{value:"平顶山",label:"平顶山"},{value:"濮阳",label:"濮阳"},{value:"三门峡",label:"三门峡"},{value:"商丘",label:"商丘"},{value:"新乡",label:"新乡"},{value:"信阳",label:"信阳"},{value:"许昌",label:"许昌"},{value:"周口",label:"周口"},{value:"驻马店",label:"驻马店"}]},{value:"香港",label:"香港",children:[{value:"香港",label:"香港"},{value:"九龙",label:"九龙"},{value:"新界",label:"新界"}]},{value:"湖北",label:"湖北",children:[{value:"武汉",label:"武汉"},{value:"天门",label:"天门"},{value:"恩施",label:"恩施"},{value:"鄂州",label:"鄂州"},{value:"黄冈",label:"黄冈"},{value:"黄石",label:"黄石"},{value:"荆门",label:"荆门"},{value:"荆州",label:"荆州"},{value:"潜江",label:"潜江"},{value:"十堰",label:"十堰"},{value:"随州",label:"随州"},{value:"武穴",label:"武穴"},{value:"仙桃",label:"仙桃"},{value:"咸宁",label:"咸宁"},{value:"襄阳",label:"襄阳"},{value:"襄樊",label:"襄樊"},{value:"孝感",label:"孝感"},{value:"宜昌",label:"宜昌"}]},{value:"湖南",label:"湖南",children:[{value:"长沙",label:"长沙"},{value:"常德",label:"常德"},{value:"郴州",label:"郴州"},{value:"衡阳",label:"衡阳"},{value:"怀化",label:"怀化"},{value:"吉首",label:"吉首"},{value:"娄底",label:"娄底"},{value:"邵阳",label:"邵阳"},{value:"湘潭",label:"湘潭"},{value:"益阳",label:"益阳"},{value:"岳阳",label:"岳阳"},{value:"永州",label:"永州"},{value:"张家界",label:"张家界"},{value:"株洲",label:"株洲"}]},{value:"江西",label:"江西",children:[{value:"南昌",label:"南昌"},{value:"抚州",label:"抚州"},{value:"赣州",label:"赣州"},{value:"吉安",label:"吉安"},{value:"景德镇",label:"景德镇"},{value:"井冈山",label:"井冈山"},{value:"九江",label:"九江"},{value:"庐山",label:"庐山"},{value:"萍乡",label:"萍乡"},{value:"上饶",label:"上饶"},{value:"新余",label:"新余"},{value:"宜春",label:"宜春"},{value:"鹰潭",label:"鹰潭"}]},{value:"吉林",label:"吉林",children:[{value:"长春",label:"长春"},{value:"吉林",label:"吉林"},{value:"白城",label:"白城"},{value:"白山",label:"白山"},{value:"珲春",label:"珲春"},{value:"辽源",label:"辽源"},{value:"梅河",label:"梅河"},{value:"四平",label:"四平"},{value:"松原",label:"松原"},{value:"通化",label:"通化"},{value:"延吉",label:"延吉"}]},{value:"辽宁",label:"辽宁",children:[{value:"沈阳",label:"沈阳"},{value:"鞍山",label:"鞍山"},{value:"本溪",label:"本溪"},{value:"朝阳",label:"朝阳"},{value:"大连",label:"大连"},{value:"丹东",label:"丹东"},{value:"抚顺",label:"抚顺"},{value:"阜新",label:"阜新"},{value:"葫芦岛",label:"葫芦岛"},{value:"锦州",label:"锦州"},{value:"辽阳",label:"辽阳"},{value:"盘锦",label:"盘锦"},{value:"铁岭",label:"铁岭"},{value:"营口",label:"营口"}]},{value:"澳门",label:"澳门",children:[{value:"澳门",label:"澳门"}]},{value:"内蒙古",label:"内蒙古",children:[{value:"呼和浩特",label:"呼和浩特"},{value:"阿拉善盟",label:"阿拉善盟"},{value:"包头",label:"包头"},{value:"赤峰",label:"赤峰"},{value:"东胜",label:"东胜"},{value:"海拉尔",label:"海拉尔"},{value:"集宁",label:"集宁"},{value:"临河",label:"临河"},{value:"通辽",label:"通辽"},{value:"乌海",label:"乌海"},{value:"乌兰浩特",label:"乌兰浩特"},{value:"锡林浩特",label:"锡林浩特"}]},{value:"宁夏",label:"宁夏",children:[{value:"银川",label:"银川"},{value:"固源",label:"固源"},{value:"石嘴山",label:"石嘴山"},{value:"吴忠",label:"吴忠"}]},{value:"青海",label:"青海",children:[{value:"西宁",label:"西宁"},{value:"德令哈",label:"德令哈"},{value:"格尔木",label:"格尔木"},{value:"共和",label:"共和"},{value:"海东",label:"海东"},{value:"海晏",label:"海晏"},{value:"玛沁",label:"玛沁"},{value:"同仁",label:"同仁"},{value:"玉树",label:"玉树"}]},{value:"山东",label:"山东",children:[{value:"济南",label:"济南"},{value:"滨州",label:"滨州"},{value:"兖州",label:"兖州"},{value:"德州",label:"德州"},{value:"东营",label:"东营"},{value:"菏泽",label:"菏泽"},{value:"济宁",label:"济宁"},{value:"莱芜",label:"莱芜"},{value:"聊城",label:"聊城"},{value:"临沂",label:"临沂"},{value:"蓬莱",label:"蓬莱"},{value:"青岛",label:"青岛"},{value:"曲阜",label:"曲阜"},{value:"日照",label:"日照"},{value:"泰安",label:"泰安"},{value:"潍坊",label:"潍坊"},{value:"威海",label:"威海"},{value:"烟台",label:"烟台"},{value:"枣庄",label:"枣庄"},{value:"淄博",label:"淄博"}]},{value:"山西",label:"山西",children:[{value:"太原",label:"太原"},{value:"吕梁",label:"吕梁"},{value:"长治",label:"长治"},{value:"大同",label:"大同"},{value:"候马",label:"候马"},{value:"晋城",label:"晋城"},{value:"离石",label:"离石"},{value:"临汾",label:"临汾"},{value:"宁武",label:"宁武"},{value:"朔州",label:"朔州"},{value:"忻州",label:"忻州"},{value:"阳泉",label:"阳泉"},{value:"榆次",label:"榆次"},{value:"晋中",label:"晋中"},{value:"运城",label:"运城"}]},{value:"陕西",label:"陕西",children:[{value:"西安",label:"西安"},{value:"安康",label:"安康"},{value:"宝鸡",label:"宝鸡"},{value:"汉中",label:"汉中"},{value:"渭南",label:"渭南"},{value:"商州",label:"商州"},{value:"绥德",label:"绥德"},{value:"铜川",label:"铜川"},{value:"咸阳",label:"咸阳"},{value:"延安",label:"延安"},{value:"榆林",label:"榆林"}]},{value:"四川",label:"四川",children:[{value:"成都",label:"成都"},{value:"巴中",label:"巴中"},{value:"达川",label:"达川"},{value:"德阳",label:"德阳"},{value:"都江堰",label:"都江堰"},{value:"峨眉山",label:"峨眉山"},{value:"涪陵",label:"涪陵"},{value:"广安",label:"广安"},{value:"广元",label:"广元"},{value:"九寨沟",label:"九寨沟"},{value:"康定",label:"康定"},{value:"乐山",label:"乐山"},{value:"泸州",label:"泸州"},{value:"马尔康",label:"马尔康"},{value:"绵阳",label:"绵阳"},{value:"眉山",label:"眉山"},{value:"南充",label:"南充"},{value:"内江",label:"内江"},{value:"攀枝花",label:"攀枝花"},{value:"遂宁",label:"遂宁"},{value:"汶川",label:"汶川"},{value:"西昌",label:"西昌"},{value:"雅安",label:"雅安"},{value:"宜宾",label:"宜宾"},{value:"自贡",label:"自贡"},{value:"资阳",label:"资阳"}]},{value:"台湾",label:"台湾",children:[{value:"台北",label:"台北"},{value:"基隆",label:"基隆"},{value:"台南",label:"台南"},{value:"台中",label:"台中"},{value:"高雄",label:"高雄"},{value:"屏东",label:"屏东"},{value:"南投",label:"南投"},{value:"云林",label:"云林"},{value:"新竹",label:"新竹"},{value:"彰化",label:"彰化"},{value:"苗栗",label:"苗栗"},{value:"嘉义",label:"嘉义"},{value:"桃园",label:"桃园"},{value:"宜兰",label:"宜兰"},{value:"台东",label:"台东"},{value:"金门",label:"金门"},{value:"马祖",label:"马祖"},{value:"澎湖",label:"澎湖"}]},{value:"天津",label:"天津",children:[{value:"天津",label:"天津"},{value:"和平",label:"和平"},{value:"东丽",label:"东丽"},{value:"河东",label:"河东"},{value:"西青",label:"西青"},{value:"河西",label:"河西"},{value:"津南",label:"津南"},{value:"南开",label:"南开"},{value:"北辰",label:"北辰"},{value:"河北",label:"河北"},{value:"武清",label:"武清"},{value:"红挢",label:"红挢"},{value:"塘沽",label:"塘沽"},{value:"汉沽",label:"汉沽"},{value:"大港",label:"大港"},{value:"宁河",label:"宁河"},{value:"静海",label:"静海"},{value:"宝坻",label:"宝坻"},{value:"蓟县",label:"蓟县"}]},{value:"新疆",label:"新疆",children:[{value:"乌鲁木齐",label:"乌鲁木齐"},{value:"阿克苏",label:"阿克苏"},{value:"阿勒泰",label:"阿勒泰"},{value:"阿图什",label:"阿图什"},{value:"博乐",label:"博乐"},{value:"昌吉",label:"昌吉"},{value:"东山",label:"东山"},{value:"哈密",label:"哈密"},{value:"和田",label:"和田"},{value:"喀什",label:"喀什"},{value:"克拉玛依",label:"克拉玛依"},{value:"库车",label:"库车"},{value:"库尔勒",label:"库尔勒"},{value:"奎屯",label:"奎屯"},{value:"石河子",label:"石河子"},{value:"塔城",label:"塔城"},{value:"吐鲁番",label:"吐鲁番"},{value:"伊宁",label:"伊宁"}]},{value:"西藏",label:"西藏",children:[{value:"拉萨",label:"拉萨"},{value:"阿里",label:"阿里"},{value:"昌都",label:"昌都"},{value:"林芝",label:"林芝"},{value:"那曲",label:"那曲"},{value:"日喀则",label:"日喀则"},{value:"山南",label:"山南"}]},{value:"云南",label:"云南",children:[{value:"昆明",label:"昆明"},{value:"大理",label:"大理"},{value:"保山",label:"保山"},{value:"楚雄",label:"楚雄"},{value:"大理",label:"大理"},{value:"东川",label:"东川"},{value:"个旧",label:"个旧"},{value:"景洪",label:"景洪"},{value:"开远",label:"开远"},{value:"临沧",label:"临沧"},{value:"丽江",label:"丽江"},{value:"六库",label:"六库"},{value:"潞西",label:"潞西"},{value:"曲靖",label:"曲靖"},{value:"思茅",label:"思茅"},{value:"文山",label:"文山"},{value:"西双版纳",label:"西双版纳"},{value:"玉溪",label:"玉溪"},{value:"中甸",label:"中甸"},{value:"昭通",label:"昭通"}]},{value:"浙江",label:"浙江",children:[{value:"杭州",label:"杭州"},{value:"温州",label:"温州"},{value:"安吉",label:"安吉"},{value:"慈溪",label:"慈溪"},{value:"定海",label:"定海"},{value:"奉化",label:"奉化"},{value:"海盐",label:"海盐"},{value:"黄岩",label:"黄岩"},{value:"湖州",label:"湖州"},{value:"嘉兴",label:"嘉兴"},{value:"金华",label:"金华"},{value:"临安",label:"临安"},{value:"临海",label:"临海"},{value:"丽水",label:"丽水"},{value:"宁波",label:"宁波"},{value:"瓯海",label:"瓯海"},{value:"平湖",label:"平湖"},{value:"千岛湖",label:"千岛湖"},{value:"衢州",label:"衢州"},{value:"江山",label:"江山"},{value:"瑞安",label:"瑞安"},{value:"绍兴",label:"绍兴"},{value:"嵊州",label:"嵊州"},{value:"台州",label:"台州"},{value:"温岭",label:"温岭"},{value:"余姚",label:"余姚"},{value:"舟山",label:"舟山"}]},{value:"海外",label:"海外",children:[{value:"美国",label:"美国"},{value:"日本",label:"日本"},{value:"英国",label:"英国"},{value:"法国",label:"法国"},{value:"德国",label:"德国"},{value:"其他",label:"其他"}]}]}}]);