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/14663.1c177375.async.js

1 line
30 KiB

This file contains invisible Unicode characters!

This file contains invisible Unicode characters that may be processed differently from what appears below. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to reveal hidden characters.

"use strict";(self.webpackChunk=self.webpackChunk||[]).push([[14663],{28563:function(e,t,n){n.d(t,{Z:function(){return c}});var r=n(5891),a=n(59301),o={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M872 474H286.9l350.2-304c5.6-4.9 2.2-14-5.2-14h-88.5c-3.9 0-7.6 1.4-10.5 3.9L155 487.8a31.96 31.96 0 000 48.3L535.1 866c1.5 1.3 3.3 2 5.2 2h91.5c7.4 0 10.8-9.2 5.2-14L286.9 550H872c4.4 0 8-3.6 8-8v-60c0-4.4-3.6-8-8-8z"}}]},name:"arrow-left",theme:"outlined"},i=n(22589),l=function(e,t){return a.createElement(i.Z,(0,r.Z)({},e,{ref:t,icon:o}))};var c=a.forwardRef(l)},94398:function(e,t,n){var r=n(82242),a=n.n(r),o=(n(59301),n(93314)),i=n(3113),l=n(37712);t.Z=function(e){var t=e.img,n=e.buttonProps,r=void 0===n?{}:n,c=e.styles,s=void 0===c?{}:c,u=e.customText,d=e.ButtonText,p=e.ButtonClick,f=e.Buttonclass,m=e.ButtonTwo,h=e.imgStyles,v=e.loading,g=void 0!==v&&v;return(0,l.jsxs)("section",{className:"tc animated fadeIn",style:a()(a()({},{color:"#999",margin:"100px auto",visibility:g?"hidden":"visible"}),s),children:[(0,l.jsx)("img",{src:t||o,style:a()(a()({},h),{},{pointerEvents:"none",userSelect:"none"})}),(0,l.jsx)("p",{className:"mt20 font14",children:u||"暂时还没有相关数据哦!"}),d&&(0,l.jsx)(i.ZP,a()(a()({className:f,onClick:p},r),{},{children:d})),m&&m]})}},33215:function(e,t,n){n.d(t,{Z:function(){return j}});var r=n(82242),a=n.n(r),o=n(7557),i=n.n(o),l=n(41498),c=n.n(l),s=n(79800),u=n.n(s),d=n(59301),p={wrp:"wrp___dq7YK",bgBlack:"bgBlack___ARIUV",monaco:"monaco___VnZC3",darkBlue:"darkBlue___UprA9",close:"close___LKoWu",embed:"embed___hvpEJ"},f=n(3113),m=n(38827),h=n(85860),v=n(6848),g=n(65327),x=n(18846),b=n(94398),y=n(19219),w=n(94843),E=n(37712),j=function(e){var t,n,r,o,l,s,j=e.editOffice,O=void 0===j?"view":j,S=e.data,k=(e.theme,e.type),_=e.filename,C=e.monacoEditor,A=e.className,Z=e.style,N=e.close,B=e.onClose,P=e.hasMask,L=e.disabledDownload,R=e.onImgDimensions,T=e.showNodata,I=e.recordInfo,M=(0,d.useState)("https://view.officeapps.live.com/op/view.aspx?src=http://testgs.educoder.net//rails/active_storage/blobs/eyJfcmFpbHMiOnsibWVzc2FnZSI6IkJBaHBCZz09IiwiZXhwIjpudWxsLCJwdXIiOiJibG9iX2lkIn19--03541f6234b93d7ac3b2d84e7eb0e6594a952945/1.ppt"),F=u()(M,2),z=(F[0],F[1],(0,d.useState)("")),$=u()(z,2),H=($[0],$[1]),D=(0,d.useState)(),W=u()(D,2),V=W[0],X=W[1],J="build"===window.ENV?"/react/build":"",U=location.host.startsWith("localhost")?y.Z.PROXY_SERVER:y.Z.API_SERVER,q=(0,d.useRef)();null!==(t=S)&&void 0!==t&&t.startsWith("/api")&&"txt"!==k&&(S=y.Z.API_SERVER+S);_&&C&&(C.filename=_),(0,d.useEffect)((function(){var e,t=null===(e=document.cookie)||void 0===e||null===(e=e.replace(/\s/g,""))||void 0===e?void 0:e.split(";");null==t||t.map((function(e){var t=e.split("=");"_educoder_session"===t[0]&&H(t[1])}))}),[]),(0,d.useEffect)((function(){var e;"office"===k&&(S.indexOf("bigfilescdn.")>-1||S.indexOf("bigfiles1")>-1?X({url:S,fileType:(e=S,e.substring(e.lastIndexOf("/")+1).split(".").pop()),model:S.indexOf("model=edit")?"edit":"view"}):K())}),[k,S]);var K=function(){var e=c()(i()().mark((function e(){var t,n,r;return i()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return console.log("data:",S),t=S,S.startsWith("http")||(t=location.origin+t),n=new URL(t).pathname.split("/").pop(),e.next=6,(0,x.gJ)({attachment_id:n});case 6:(r=e.sent).url=U+r.url,X(r);case 9:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}(),Q=function(){S.startsWith("http")||S.startsWith("blob:")?Y():(0,g.Sv)(_||"educoder",S,_)},Y=function(){I&&(0,w.fc)({id:null==I?void 0:I.id,watch_type:1,course_id:null==I?void 0:I.course_id}),(0,g.Nd)(_||"educoder",decodeURIComponent(S))};return(0,E.jsxs)("div",{style:a()({},Z||{}),className:"".concat(P&&p.bgBlack," ").concat(k?p.wrp:"hide"),children:[N&&(0,E.jsxs)("div",{className:p.close,ref:q,children:[!!R&&(0,E.jsx)(v.Z,{title:"点击对图片进行批注",getPopupContainer:function(){return q.current},children:(0,E.jsx)("span",{onClick:function(){B(),R()},children:(0,E.jsx)("i",{className:"icon-yulanpizhu"})})}),!L&&(0,E.jsx)(v.Z,{title:"点击下载此文件",getPopupContainer:function(){return q.current},children:(0,E.jsx)("span",{onClick:Y,children:(0,E.jsx)("i",{className:"icon-quxiaozhiding"})})}),(0,E.jsx)(v.Z,{title:"关闭",getPopupContainer:function(){return q.current},children:(0,E.jsx)("span",{className:"",onClick:B,children:(0,E.jsx)("i",{className:"icon-guanbi1"})})})]}),(0,E.jsx)("div",{className:"".concat(p[A]," ").concat(A," ").concat(p.monaco," ").concat("txt"===k?"show":"hide"),children:"txt"===k&&(0,E.jsx)(E.Fragment,{children:(0,E.jsx)(h.ZP,a()({},C))})}),"audio"===k&&(0,E.jsx)("audio",{src:"".concat((null===(n=S)||void 0===n?void 0:n.indexOf("http://"))>-1||(null===(r=S)||void 0===r?void 0:r.indexOf("https://"))>-1?"":"data:audio/mp3;base64,").concat(S),autoPlay:!0}),"video"===k&&(0,E.jsx)(E.Fragment,{children:(null===(o=S)||void 0===o?void 0:o.indexOf("http"))>-1?(0,E.jsx)("video",{controls:!0,src:"".concat(S),autoPlay:!0}):(0,E.jsx)("video",{controls:!0,src:"data:video/mp4;base64,".concat(S),autoPlay:!0})}),"office"===k&&V&&(0,E.jsx)("iframe",{src:"".concat(J,"/office.html?key=").concat(V.key,"&url=").concat(btoa(V.url),"&callbackUrl=").concat(U+V.callbackUrl,"&fileType=").concat(V.fileType,"&title=").concat(V.title,"&model=").concat(O,"&officeServer=").concat(y.Z.ONLYOFFICE,"&disabledDownload=").concat(!!L)}),"html"===k&&(0,E.jsx)("iframe",{src:S+"&disposition=inline"}),"pdf"===k&&(0,E.jsx)("iframe",{src:"".concat(J,"/js/pdfview/index.html?filename=").concat(_||"educoder.pdf","&url=").concat(encodeURIComponent(S),"&disabledDownload=").concat(!!L)}),"image"===k&&(0,E.jsx)("img",{src:"".concat((null===(l=S)||void 0===l?void 0:l.indexOf("http://"))>-1||(null===(s=S)||void 0===s?void 0:s.indexOf("https://"))>-1?"":"data:image/png;base64,").concat(S)}),("other"===k||"download"===k)&&(0,E.jsx)(E.Fragment,{children:T?(0,E.jsx)(b.Z,{customText:"当前文件不支持预览,可点击下载查看",ButtonTwo:(0,E.jsx)(f.ZP,{icon:(0,E.jsx)("i",{className:"iconfont icon-xiazai4 font14"}),type:"primary",size:"middle",onClick:Q,disabled:L,children:"下载"})}):(0,E.jsxs)(f.ZP,{type:"primary",size:"middle",onClick:Q,disabled:L,children:[(0,E.jsx)(m.Z,{}),"点击下载"]})})]})}},40848:function(e,t,n){n.d(t,{z:function(){return E}});var r=n(82242),a=n.n(r),o=n(37205),i=n.n(o),l=n(91232),c=n.n(l),s=n(79800),u=n.n(s),d=n(59301),p=(n(12530),n(63855)),f=(n(64018),n(24830)),m=n(19219),h=n(65327),v=n(15342),g=n(1012),x=n(33215),b=n(37712),y="@▁@",w=/<pre[^>]*>/g;var E=function(e,t){e=e||"";var n=/(?:https?:\/\/[^\/]+)?\/api\/attachments\/([A-Za-z0-9+/=]+)(\?.*?)?\)|(?:https?:\/\/[^\/]+)?\/api\/attachments\/([A-Za-z0-9+/=]+)(\?.*?)?|(?:https?:\/\/[^\/]+)?\/attachments\/download\/([A-Za-z0-9+/=]+)(\?.*?)?\//g;return t?e.replaceAll("https://www.educoder.net","").replaceAll("https://www-cdn.educoder.net","").replaceAll("//api/attachments","/api/attachments").replace(n,(function(e,t,n,r,a,o,i){var l=t||r||o,c=n||a||i||"?";return m.Z.API_SERVER+"/api/attachments/"+l+c+"&t="+(0,h.Jn)(l,Date.now())+(e.indexOf(")")>-1?")":"&")})).replaceAll('src="(','src="').replaceAll("src='(",'src="'):e=e.replace(/(?:https?:\/\/[^\/]+)?\/attachments\/download\/([A-Za-z0-9+/=]+)(\?.*?)?\//g,(function(e,t,n,r,a,o,i){var l=t||r||o,c=n||a||i||"?";return m.Z.API_SERVER+"/attachments/download/"+l+c+"&t="+(0,h.Jn)(l,Date.now())+(e.indexOf(")")>-1?")":"&")})).replace(n,(function(e,t,n,r,a,o,i){var l=t||r||o,c=n||a||i||"?";return m.Z.API_SERVER+"/api/attachments/"+l+c+"&t="+(0,h.Jn)(l,Date.now())+(e.indexOf(")")>-1?")":"&")})).replace(/\"(?:https?:\/\/[^\/]+)?\/api\/attachments\/([A-Za-z0-9+/=]+)(\?.*?)?|\"(?:https?:\/\/[^\/]+)?\/attachments\/download\/([A-Za-z0-9+/=]+)(\?.*?)?\//g,(function(e,t,n,r,a){var o=t||r,i=n||a||"";return'"'+m.Z.API_SERVER+"/api/attachments/"+o+i+o+i+"&t="+(0,h.Jn)(o,Date.now())})).replace(/\(\s+(?:https?:\/\/[^\/]+)?\/files\/uploads\/([A-Za-z0-9+/=]+)(\?.*?)?|\"(?:https?:\/\/[^\/]+)?\/files\/uploads\/([A-Za-z0-9+/=]+)(\?.*?)?\//g,(function(e,t,n,r,a){var o=t||r,i=n||a||"";return"("+m.Z.API_SERVER+"/files/uploads/"+o+i+o+i+"&t="+(0,h.Jn)(o,Date.now())})).replaceAll('src="(','src="').replaceAll("src='(",'src="').replaceAll("http://video.educoder","https://video.educoder").replaceAll("http://www.educoder.net/api","https://data.educoder.net/api").replaceAll("https://www.educoder.net/api","https://data.educoder.net/api").replace(/\r\n/g,"\n")};t.Z=function(e){var t=e.value,n=void 0===t?"":t,r=e.className,o=e.showTextOnly,l=e.showLines,s=e.style,h=void 0===s?{}:s,E=e.stylesPrev,j=void 0===E?{}:E,O=e.highlightKeywords,S=e.showProgramFill,k=(e.isProgramFill,e.disabledFill),_=void 0!==k&&k,C=e.programFillValue,A=e.onFillChange,Z=void 0===A?function(e){}:A,N=e.onFillBlur,B=void 0===N?function(){}:N,P=e.onFillFocus,L=void 0===P?function(){}:P,R=String(n),T=(0,d.useState)(""),I=u()(T,2),M=I[0],F=I[1],z=(0,d.useState)("office"),$=u()(z,2),H=$[0],D=$[1],W=(0,d.useState)([]),V=u()(W,2),X=V[0],J=V[1],U=(0,d.useRef)("a"+(0,g.Z)()),q={};var K=function(e){return e.replace(/<style.*?>([\s\S]+?)<\/style>/gim,(function(e,t){var n=t.replace(/(\n|\r)/g,"").split("}"),r=[];return n.map((function(e){""!=e&&r.push(".".concat(U.current," ").concat(e))})),"<style>".concat(r.join("}"),"</style>")}))},Q=(0,d.useMemo)((function(){try{R=R.replace(/\(\/attachments\/download\//g,"("+m.Z.API_SERVER+"/attachments/download/").replace(/\(\s+\/api\/attachments\/|\(\/api\/attachments\//g,"("+m.Z.API_SERVER+"/api/attachments/").replace(/\"\/api\/attachments\/|\"\/attachments\/download\//g,'"'+m.Z.API_SERVER+"/api/attachments/").replace(/\(\s+\/files\/uploads\/|\"\/files\/uploads\//g,'"'+m.Z.API_SERVER+"/files/uploads/").replaceAll("http://video.educoder","https://video.educoder").replaceAll("http://www.educoder.net/api","https://data.educoder.net/api").replaceAll("https://www.educoder.net/api","https://data.educoder.net/api").replace(/\r\n/g,"\n")}catch(e){}if(S){var e=-1;return R=R.replaceAll("<","&lt;").replaceAll(">","&gt;").replace(/(@▁▁@|@▁@)/g,(function(t,n,r){var a;return function(e,t,n){var r=document.createElement(e===y?"input":"textarea");r.style.width="100%",r.style.height=e===y?"40px":"151px",r.rows=5,r.spellcheck=!1,r.name="edu-program-fill",r.placeholder="请输入",r.dataset.id=t;var a=Object.keys(q).length;return q[a]=r,'<span class="edu-program-fill-wrap '.concat(e===y?"":"show",'" style="width:').concat(e===y?"400px":"100%",'" title=').concat(n||"","><span>").concat(r.outerHTML,'<span class="edu-program-fill-score" style="margin:0 6px"></span></span></span>')}(t,++e,null==C||null===(a=C[e])||void 0===a?void 0:a.value.replaceAll("<","&lt;").replaceAll(">","&gt;"))})),'<pre style="background:#fff;padding:4px">'.concat(K(R||""),"</pre>")}var t=K(R);t=(0,p.ZP)(t);var n=(0,p.ez)();R.match(/\[TOC\]/)&&(t=t.replace("<p>[TOC]</p>",(0,p.Qv)()),(0,p.Iy)()),t=t.replace(/(__special_katext_id_\d+__)/g,(function(e,t){var r=n[t],a=r.type,o=r.expression;return(0,v.renderToString)(function(e){var t=document.createElement("div");return t.innerHTML=e,0===t.childNodes.length?"":t.childNodes[0].nodeValue}(o)||"",{displayMode:"block"===a,throwOnError:!1,output:"html"})})),t=t.replace(/▁/g,"▁▁▁▁▁"),(0,p.AL)();var r=document.createElement("div");return r.innerHTML=t,o?r.innerText:O?(te(r,O.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")),r.innerHTML):(setTimeout((function(){return ae()}),500),r.innerHTML)}),[R,O]);(0,d.useEffect)((function(){ne.current&&ne.current.querySelectorAll(["input","textarea"]).forEach((function(e){e.oninput=Y,e.onblur=G,e.onfocus=ee}))}),[X]),(0,d.useEffect)((function(){if(null!=C&&C.length)try{var e,t=ne.current.querySelectorAll(".edu-program-fill-score"),n=ne.current.querySelectorAll('[name="edu-program-fill"]'),r=c()(n.entries());try{for(r.s();!(e=r.n()).done;){var a,o,i,l=u()(e.value,2),s=l[0],d=l[1];d.value=(null==C||null===(a=C[s])||void 0===a?void 0:a.value)||"","warning"===(null==C||null===(o=C[s])||void 0===o?void 0:o.type)?d.className="program-fill-warning":"success"===(null==C||null===(i=C[s])||void 0===i?void 0:i.type)?d.className="program-fill-success":d.className=""}}catch(e){r.e(e)}finally{r.f()}var p,f=c()(t.entries());try{for(f.s();!(p=f.n()).done;){var m,h,v=u()(p.value,2),g=v[0];v[1].innerHTML=null!=C&&null!==(m=C[g])&&void 0!==m&&m.score?"".concat(null==C||null===(h=C[g])||void 0===h?void 0:h.score,"分"):""}}catch(e){f.e(e)}finally{f.f()}J(C)}catch(e){console.log(e,"error")}}),[C]);var Y=function(e){X[e.target.dataset.id]=X[e.target.dataset.id]||{},X[e.target.dataset.id].value=e.target.value,J(i()(X)),Z(X,e.target.dataset.id)},G=function(e){X[e.target.dataset.id]=X[e.target.dataset.id]||{},X[e.target.dataset.id].value=e.target.value,J(i()(X)),B(X,e.target.dataset.id)},ee=function(e){X[e.target.dataset.id]=X[e.target.dataset.id]||{},X[e.target.dataset.id].value=e.target.value,J(i()(X)),L(X,e.target.dataset.id)};function te(e,t){return e.childNodes.forEach((function(e){if(e.childNodes.length>0)te(e,t);else if("IMG"!==e.nodeName)if(e.innerHTML){var n;e.innerHTML=null===(n=e.innerHTML)||void 0===n?void 0:n.replace(new RegExp(t,"gi"),'<span style="color:#0152d9;background-color:#1890ff33">$&</span>')}else{var r=document.createElement("span");r.innerHTML=e.textContent.replace(new RegExp(t,"gi"),'<span style="color:#0152d9;background-color:#1890ff33">$&</span>'),e.replaceWith(r)}}))}var ne=(0,d.useRef)();function re(e){var t=e.target;if("A"===t.tagName.toUpperCase()){var n=t.getAttribute("href");if(n.indexOf("office")>-1)e.preventDefault(),F(n),D("office");else if(n.indexOf("application/pdf")>-1)e.preventDefault(),F(n),D("pdf");else if(n.indexOf("text/html")>-1)e.preventDefault(),F(n),D("html");else if(n.startsWith("#")){e.preventDefault();var r=document.getElementById(n.replace("#",""));r&&r.scrollIntoView(!0)}}}p.jb.WebkitLineClamp=l,l&&(h=a()(a()({},h),p.jb));var ae=function(){var e,t=null===(e=ne.current)||void 0===e?void 0:e.querySelectorAll("video");null==t||t.forEach((function(e){if(e.oncontextmenu=function(){return!1},e.src.indexOf(".m3u8")>-1)if(e.canPlayType("application/vnd.apple.mpegurl"));else if(f.ZP.isSupported()){var t=new f.ZP;t.loadSource(e.src),t.attachMedia(e)}}))};return(0,d.useEffect)((function(){if(ne.current&&Q&&Q.match(w)&&window.PR.prettyPrint(),ne.current)return ne.current.addEventListener("click",re),function(){var e;null===(e=ne.current)||void 0===e||e.removeEventListener("click",re),(0,p.AL)(),(0,p.Iy)()}}),[Q,ne.current,re]),(0,d.useEffect)((function(){var e,t=function(e){e.preventDefault(),e.clipboardData.setData("text",window.getSelection().toString())};return null===(e=ne.current)||void 0===e||e.addEventListener("copy",t),function(){var e;null===(e=ne.current)||void 0===e||e.removeEventListener("copy",t)}}),[ne.current]),(0,b.jsxs)(b.Fragment,{children:[o&&(0,b.jsx)("div",{ref:ne,children:Q}),!o&&(0,b.jsx)("div",{ref:ne,style:a()({},h),className:"".concat(r||""," ").concat(_?"disabled-fill":""," markdown-body ").concat(U.current),dangerouslySetInnerHTML:{__html:Q}}),(0,b.jsx)(x.Z,{close:!0,data:M,type:null!=M&&M.length?H:"",style:a()({},j),onClose:function(){return F("")}})]})}},24578:function(e,t,n){n.d(t,{H:function(){return p}});var r=n(37205),a=n.n(r),o=n(59301),i=n(78241),l=n(92832),c=n(42441),s=n(40848),u=n(37712),d=function(e){var t=e.form,n=e.index,r=void 0===n?1:n,s=e.field,d=e.ParentName,p=void 0===d?[]:d;"string"!=typeof p&&"number"!=typeof p||(p=[p]);var f=i.Z.useWatch([].concat(a()(p),[s.name,"chart_1"]),{form:t}),m=i.Z.useWatch([].concat(a()(p),[s.name,"chart_2"]),{form:t}),h=i.Z.useWatch([].concat(a()(p),[s.name,"name"]),{form:t}),v=i.Z.useWatch([].concat(a()(p),[s.name,"question_type"]),{form:t}),g=(0,o.useMemo)((function(){var e=[],t=[];return null==f||f.forEach((function(n){e.push(null==n?void 0:n.x_axis),t.push(null==n?void 0:n.y_axis)})),{tooltip:{},grid:{left:"7%",right:"5%",bottom:"15%",top:"15%",containLabel:!0},xAxis:{type:"category",data:[].concat(a()(e||[]),[[4,5,6,7,8].includes(v)?"分数区间":"答对题数(单位:题)"]),axisTick:{show:!1},axisLine:{lineStyle:{color:"#EBEBEB"}},axisLabel:{color:"#666666",interval:0}},yAxis:{name:"人数(单位:人)",nameTextStyle:{color:"#666",padding:[0,0,10,0]},type:"value",splitLine:{show:!1},axisLine:{show:!0,lineStyle:{color:"#EBEBEB"}},axisLabel:{color:"#666666"}},series:[{data:t,barMaxWidth:"40px",itemStyle:{color:"#A2BEFF",borderColor:"#165DFF"},type:"bar"}]}}),[f]),x=(0,o.useMemo)((function(){var e=[],t=[];return null==m||m.forEach((function(n){e.push(null==n?void 0:n.x_axis),t.push(Math.round(1e4*(null==n?void 0:n.y_axis))/100)})),{tooltip:{},grid:{left:"5%",right:"5%",bottom:"7%",containLabel:!0},xAxis:{type:"category",data:[].concat(a()(e||[]),["题目"]),axisTick:{show:!1},axisLine:{lineStyle:{color:"#EBEBEB"}},axisLabel:{color:"#666666",interval:0,formatter:function(e,t){return"题目"!==e?"".concat(t+1,"\n\n{subtext|").concat((e.length>6?null==e?void 0:e.slice(0,6):e).split("").join("\n"),"}"):e},rich:{subtext:{align:"center",color:"#666",lineHeight:15}}}},yAxis:{name:"平均得分",nameTextStyle:{color:"#666",padding:[0,0,10,0]},type:"value",splitLine:{show:!1},axisLine:{show:!0,lineStyle:{color:"#EBEBEB"}},axisLabel:{color:"#666666"}},series:[{data:t,barMaxWidth:"40px",itemStyle:{color:"#2EC25B"},type:"bar",label:{color:"#666",show:!0,position:"top",valueAnimation:!0,formatter:"{c}%"}}]}}),[m]);return(0,u.jsxs)(u.Fragment,{children:[(0,u.jsxs)("div",{className:"text-500 font14 mb10",children:[r,".",h]}),(0,u.jsx)(i.Z.Item,{name:[s.name,"content"],children:(0,u.jsx)(l.Z.TextArea,{rows:3})}),(0,u.jsxs)("div",{className:"mt20",children:[(0,u.jsx)("div",{className:"font14 mb10",children:"学员答题情况"}),(0,u.jsx)(c.Z,{className:"bg-white",style:{border:"1px solid #EBEBEB"},option:g})]}),(0,u.jsxs)("div",{className:"mt20",children:[(0,u.jsx)("div",{className:"font14 mb10",children:"各小题答题情况"}),(0,u.jsx)(c.Z,{className:"bg-white",style:{border:"1px solid #EBEBEB",height:331},option:x})]})]})};t.Z=o.memo(d);var p=o.memo((function(e){e.form;var t=e.index,n=void 0===t?1:t,r=e.data,i=(0,o.useMemo)((function(){var e,t=[],n=[];return null==r||null===(e=r.chart_1)||void 0===e||e.forEach((function(e){t.push(null==e?void 0:e.x_axis),n.push(null==e?void 0:e.y_axis)})),{tooltip:{},grid:{left:"5%",right:"5%",bottom:"15%",top:"20%",containLabel:!0},xAxis:{type:"category",data:[].concat(a()(t||[]),[[4,5,6,7,8].includes(null==r?void 0:r.question_type)?"分数区间":"答对题数(单位:题)"]),axisTick:{show:!1},axisLine:{lineStyle:{color:"#EBEBEB"}},axisLabel:{color:"#666666",interval:0}},yAxis:{name:"人数(单位:人)",nameTextStyle:{color:"#666",padding:[0,0,10,0]},type:"value",splitLine:{show:!1},axisLine:{show:!0,lineStyle:{color:"#EBEBEB"}},axisLabel:{color:"#666666"}},series:[{data:n,barMaxWidth:"40px",itemStyle:{color:"#A2BEFF",borderColor:"#165DFF"},type:"bar"}]}}),[null==r?void 0:r.chart_1]),l=(0,o.useMemo)((function(){var e,t=[],n=[];return null==r||null===(e=r.chart_2)||void 0===e||e.forEach((function(e){t.push(null==e?void 0:e.x_axis),n.push(Math.round(1e4*(null==e?void 0:e.y_axis))/100)})),{tooltip:{},grid:{left:"5%",right:"5%",bottom:"7%",containLabel:!0},xAxis:{type:"category",data:[].concat(a()(t||[]),["题目"]),axisTick:{show:!1},axisLine:{lineStyle:{color:"#EBEBEB"}},axisLabel:{color:"#666666",interval:0,formatter:function(e,t){return"题目"!==e?"".concat(t+1,"\n\n{subtext|").concat((e.length>6?null==e?void 0:e.slice(0,6):e).split("").join("\n"),"}"):e},rich:{subtext:{align:"center",color:"#666",lineHeight:15}}}},yAxis:{name:"平均得分",nameTextStyle:{color:"#666",padding:[0,0,10,0]},type:"value",splitLine:{show:!1},axisLine:{show:!0,lineStyle:{color:"#EBEBEB"}},axisLabel:{color:"#666666"}},series:[{data:n,barMaxWidth:"40px",itemStyle:{color:"#2EC25B"},type:"bar",label:{color:"#666",show:!0,position:"top",valueAnimation:!0,formatter:"{c}%"}}]}}),[null==r?void 0:r.chart_2]);return(0,u.jsxs)("div",{className:"text-start pl10 pr10",children:[(0,u.jsxs)("div",{className:"text-500 font14 mb10 c-black",children:[n,".",null==r?void 0:r.name]}),(0,u.jsx)("div",{children:(0,u.jsx)(s.Z,{className:"font14 c-grey-333",value:null==r?void 0:r.content})}),(0,u.jsxs)("div",{className:"mt20",children:[(0,u.jsx)(c.Z,{className:"bg-white",style:{background:"#F6F7F9"},option:i}),(0,u.jsxs)("div",{className:"font14 mt10 text-center",children:["图",2*n-1,"  ",null==r?void 0:r.name,"答题得分情况分布"]})]}),(0,u.jsxs)("div",{className:"mt20",children:[(0,u.jsx)(c.Z,{className:"bg-white",style:{background:"#F6F7F9",height:331},option:l}),(0,u.jsxs)("div",{className:"font14 mt10 text-center",children:["图",2*n,"  ",null==r?void 0:r.name,"各小题得分率"]})]})]})}))},34119:function(e,t,n){n.d(t,{U:function(){return p}});var r=n(7557),a=n.n(r),o=n(82242),i=n.n(o),l=n(41498),c=n.n(l),s=n(79800),u=n.n(s),d=n(59301);function p(e,t){var n=(0,d.useState)(t),r=u()(n,2),o=r[0],l=r[1],s=(0,d.useState)(!1),p=u()(s,2),f=p[0],m=p[1],h=(0,d.useState)(),v=u()(h,2),g=v[0],x=v[1],b=function(){var n=c()(a()().mark((function n(r){var c,s,u,d=arguments;return a()().wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return c=d.length>1&&void 0!==d[1]&&d[1],s=c?t:i()(i()({},o),r),m(!0),l(s),n.next=6,e(s);case 6:return u=n.sent,m(!1),x(u),n.abrupt("return",u);case 10:case"end":return n.stop()}}),n)})));return function(e){return n.apply(this,arguments)}}();return[o,f,b,g]}},63855:function(e,t,n){n.d(t,{AL:function(){return E},Iy:function(){return p},Qv:function(){return h},ez:function(){return w},jb:function(){return f}});var r=n(79800),a=n.n(r),o=n(32834),i=n.n(o),l=n(11690);var c=[],s=["<ul>"],u=new(i().Renderer),d=/^ *(#{1,6}) *([^\n]+?) *(?:#+ *)?(?:\n+|$)/;function p(){c.length=0,s=["<ul>"]}var f={overflow:"hidden",WebkitBoxOrient:"vertical",display:"-webkit-box",WebkitLineClamp:2};function m(e,t,n,r){if(t>=e.length||e[t].level<=n)return t;var a=e[t];r.push("<li><a href='#"+a.anchor+"'>"+a.text+"</a>");var o=[];return t=m(e,++t,a.level,o),o.length>0&&(r.push("<ul>"),o.forEach((function(e){r.push(e)})),r.push("</ul>")),r.push("</li>"),t=m(e,t,n,r)}function h(){return m(c,0,0,s),s.push("</ul>"),s.join("")}var v={heading:function(e){var t=d.exec(e);if(t)return{type:"heading",raw:t[0],depth:t[1].length,text:t[2]}},fences:function(e){var t=this.rules.block.fences.exec(e);if(t){var n=t[0],r=function(e,t){var n=e.match(/^(\s+)(?:```)/);if(null===n)return t;var r=n[1];return t.split("\n").map((function(e){var t=e.match(/^\s+/);return null===t?e:a()(t,1)[0].length>=r.length?e.slice(r.length):e})).join("\n")}(n,t[3]||""),o=t[2]?t[2].trim():t[2];if(["latex","katex","math"].indexOf(o)>=0){var i=b(),l=r;r=i,y[i]={type:"block",expression:l}}return{type:"code",raw:n,lang:o,text:r}}}},g=/(?:\${2})([^\n`]+?)(?:\${2})/gi,x=0,b=function(){return"__special_katext_id_".concat(x++,"__")},y={};function w(){return y}function E(){x=0,y={}}function j(e){return e=e.replace(g,(function(e,t){var n=b();return y[n]={type:"inline",expression:t},n}))}var O=u.listitem;u.listitem=function(e){return O(j(e))};var S=u.paragraph;u.paragraph=function(e){return S(j(e))};var k=u.tablecell;u.tablecell=function(e,t){return k(j(e),t)},u.code=function(e,t,n){var r=(t||"").match(/\S*/)[0];return r?["latex","katex","math"].indexOf(r)>=0?"<p class='editormd-tex'>".concat(e,"</p>"):'<pre class="prettyprint linenums"><code class="language-'.concat(t,'">').concat(n?e:(0,l.escape)(e,!0),"</code></pre>\n"):'<pre class="prettyprint linenums"><code>'+(n?e:(0,l.escape)(e,!0))+"</code></pre>"},u.heading=function(e,t,n){var r=this.options.headerPrefix+n.toLowerCase().replace(/[^\w\\u4e00-\\u9fa5]]+/g,"-");return c.push({anchor:r,level:t,text:e}),"<h"+t+' id="'+r+'">'+e+"</h"+t+">"},i().setOptions({silent:!0,gfm:!0,pedantic:!1}),i().use({tokenizer:v,renderer:u}),t.ZP=i()},66104:function(e,t,n){n.d(t,{Z:function(){return Z}});var r=n(92310),a=n.n(r),o=n(75440),i=n(47413),l=n(59301),c=n(92343),s=n(36355),u=n(78386),d=n(91857);const p=e=>{let{children:t}=e;const{getPrefixCls:n}=l.useContext(s.E_),r=n("breadcrumb");return l.createElement("li",{className:`${r}-separator`,"aria-hidden":"true"},""===t?t:t||"/")};p.__ANT_BREADCRUMB_SEPARATOR=!0;var f=p,m=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var a=0;for(r=Object.getOwnPropertySymbols(e);a<r.length;a++)t.indexOf(r[a])<0&&Object.prototype.propertyIsEnumerable.call(e,r[a])&&(n[r[a]]=e[r[a]])}return n};function h(e,t,n,r){if(null==n)return null;const{className:o,onClick:c}=t,s=m(t,["className","onClick"]),u=Object.assign(Object.assign({},(0,i.Z)(s,{data:!0,aria:!0})),{onClick:c});return void 0!==r?l.createElement("a",Object.assign({},u,{className:a()(`${e}-link`,o),href:r}),n):l.createElement("span",Object.assign({},u,{className:a()(`${e}-link`,o)}),n)}function v(e,t){return(n,r,a,o,i)=>{if(t)return t(n,r,a,o);const l=function(e,t){if(void 0===e.title||null===e.title)return null;const n=Object.keys(t).join("|");return"object"==typeof e.title?e.title:String(e.title).replace(new RegExp(`:(${n})`,"g"),((e,n)=>t[n]||e))}(n,r);return h(e,n,l,i)}}var g=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var a=0;for(r=Object.getOwnPropertySymbols(e);a<r.length;a++)t.indexOf(r[a])<0&&Object.prototype.propertyIsEnumerable.call(e,r[a])&&(n[r[a]]=e[r[a]])}return n};const x=e=>{const{prefixCls:t,separator:n="/",children:r,menu:a,overlay:o,dropdownProps:i,href:c}=e;const s=(e=>{if(a||o){const n=Object.assign({},i);if(a){const e=a||{},{items:t}=e,r=g(e,["items"]);n.menu=Object.assign(Object.assign({},r),{items:null==t?void 0:t.map(((e,t)=>{var{key:n,title:r,label:a,path:o}=e,i=g(e,["key","title","label","path"]);let s=null!=a?a:r;return o&&(s=l.createElement("a",{href:`${c}${o}`},s)),Object.assign(Object.assign({},i),{key:null!=n?n:t,label:s})}))})}else o&&(n.overlay=o);return l.createElement(d.Z,Object.assign({placement:"bottom"},n),l.createElement("span",{className:`${t}-overlay-link`},e,l.createElement(u.Z,null)))}return e})(r);return null!=s?l.createElement(l.Fragment,null,l.createElement("li",null,s),n&&l.createElement(f,null,n)):null},b=e=>{const{prefixCls:t,children:n,href:r}=e,a=g(e,["prefixCls","children","href"]),{getPrefixCls:o}=l.useContext(s.E_),i=o("breadcrumb",t);return l.createElement(x,Object.assign({},a,{prefixCls:i}),h(i,a,n,r))};b.__ANT_BREADCRUMB_ITEM=!0;var y=b,w=n(17313),E=n(83116),j=n(37613);const O=e=>{const{componentCls:t,iconCls:n}=e;return{[t]:Object.assign(Object.assign({},(0,w.Wf)(e)),{color:e.itemColor,fontSize:e.fontSize,[n]:{fontSize:e.iconFontSize},ol:{display:"flex",flexWrap:"wrap",margin:0,padding:0,listStyle:"none"},a:Object.assign({color:e.linkColor,transition:`color ${e.motionDurationMid}`,padding:`0 ${e.paddingXXS}px`,borderRadius:e.borderRadiusSM,height:e.lineHeight*e.fontSize,display:"inline-block",marginInline:-e.marginXXS,"&:hover":{color:e.linkHoverColor,backgroundColor:e.colorBgTextHover}},(0,w.Qy)(e)),"li:last-child":{color:e.lastItemColor},[`${t}-separator`]:{marginInline:e.separatorMargin,color:e.separatorColor},[`${t}-link`]:{[`\n > ${n} + span,\n > ${n} + a\n `]:{marginInlineStart:e.marginXXS}},[`${t}-overlay-link`]:{borderRadius:e.borderRadiusSM,height:e.lineHeight*e.fontSize,display:"inline-block",padding:`0 ${e.paddingXXS}px`,marginInline:-e.marginXXS,[`> ${n}`]:{marginInlineStart:e.marginXXS,fontSize:e.fontSizeIcon},"&:hover":{color:e.linkHoverColor,backgroundColor:e.colorBgTextHover,a:{color:e.linkHoverColor}},a:{"&:hover":{backgroundColor:"transparent"}}},[`&${e.componentCls}-rtl`]:{direction:"rtl"}})}};var S=(0,E.Z)("Breadcrumb",(e=>{const t=(0,j.TS)(e,{});return[O(t)]}),(e=>({itemColor:e.colorTextDescription,lastItemColor:e.colorText,iconFontSize:e.fontSize,linkColor:e.colorTextDescription,linkHoverColor:e.colorText,separatorColor:e.colorTextDescription,separatorMargin:e.marginXS}))),k=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var a=0;for(r=Object.getOwnPropertySymbols(e);a<r.length;a++)t.indexOf(r[a])<0&&Object.prototype.propertyIsEnumerable.call(e,r[a])&&(n[r[a]]=e[r[a]])}return n};function _(e){const{breadcrumbName:t,children:n}=e,r=k(e,["breadcrumbName","children"]),a=Object.assign({title:t},r);return n&&(a.menu={items:n.map((e=>{var{breadcrumbName:t}=e,n=k(e,["breadcrumbName"]);return Object.assign(Object.assign({},n),{title:t})}))}),a}var C=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var a=0;for(r=Object.getOwnPropertySymbols(e);a<r.length;a++)t.indexOf(r[a])<0&&Object.prototype.propertyIsEnumerable.call(e,r[a])&&(n[r[a]]=e[r[a]])}return n};const A=e=>{const{prefixCls:t,separator:n="/",style:r,className:u,rootClassName:d,routes:p,items:m,children:h,itemRender:g,params:b={}}=e,y=C(e,["prefixCls","separator","style","className","rootClassName","routes","items","children","itemRender","params"]),{getPrefixCls:w,direction:E,breadcrumb:j}=l.useContext(s.E_);let O;const k=w("breadcrumb",t),[A,Z]=S(k),N=function(e,t){return(0,l.useMemo)((()=>e||(t?t.map(_):null)),[e,t])}(m,p);const B=v(k,g);if(N&&N.length>0){const e=[],t=m||p;O=N.map(((r,a)=>{const{path:o,key:c,type:s,menu:u,overlay:d,onClick:p,className:m,separator:h,dropdownProps:v}=r,g=((e,t)=>{if(void 0===t)return t;let n=(t||"").replace(/^\//,"");return Object.keys(e).forEach((t=>{n=n.replace(`:${t}`,e[t])})),n})(b,o);void 0!==g&&e.push(g);const y=null!=c?c:a;if("separator"===s)return l.createElement(f,{key:y},h);const w={},E=a===N.length-1;u?w.menu=u:d&&(w.overlay=d);let{href:j}=r;return e.length&&void 0!==g&&(j=`#/${e.join("/")}`),l.createElement(x,Object.assign({key:y},w,(0,i.Z)(r,{data:!0,aria:!0}),{className:m,dropdownProps:v,href:j,separator:E?"":n,onClick:p,prefixCls:k}),B(r,b,t,e,j))}))}else if(h){const e=(0,o.Z)(h).length;O=(0,o.Z)(h).map(((t,r)=>{if(!t)return t;const a=r===e-1;return(0,c.Tm)(t,{separator:a?"":n,key:r})}))}const P=a()(k,null==j?void 0:j.className,{[`${k}-rtl`]:"rtl"===E},u,d,Z),L=Object.assign(Object.assign({},null==j?void 0:j.style),r);return A(l.createElement("nav",Object.assign({className:P,style:L},y),l.createElement("ol",null,O)))};A.Item=y,A.Separator=f;var Z=A}}]);