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__Problemset__Preview__ind...

2 lines
20 KiB

"use strict";(self.webpackChunk=self.webpackChunk||[]).push([[1581],{92399:function(ne,k,s){s.d(k,{Z:function(){return O}});var t=s(59301),C=s(5112),v=s(31272),u={flexRow:"flexRow____Sm4b",flexColumn:"flexColumn___mQNZs",action:"action___QUVEn",setScore:"setScore___yZ0Yb",delete:"delete___e4taL",content:"content___jR4Y6",titleWrap:"titleWrap___zsXYY",titleNumber:"titleNumber___p60vi",score:"score___DbCHw",titleHtml:"titleHtml___FALbj",answerWrap:"answerWrap___uPjYq",answer:"answer___pfiPk",answerText:"answerText___K3TNr"},S=s(24334),h=s(15411),e=s(59301);const c=["A\uFF0E","B\uFF0E","C\uFF0E","D\uFF0E","E\uFF0E","F\uFF0E","G\uFF0E","H\uFF0E","I\uFF0E","J\uFF0E","K\uFF0E","L\uFF0E","M\uFF0E","N\uFF0E","O\uFF0E","P\uFF0E","Q\uFF0E","R\uFF0E","S\uFF0E","T\uFF0E","U\uFF0E","V\uFF0E","W\uFF0E","X\uFF0E","Y\uFF0E","Z\uFF0E"],K=[{type:"single",name:"\u5355\u9009\u9898"},{type:"multiple",name:"\u591A\u9009\u9898"},{type:"judgement",name:"\u5224\u65AD\u9898"},{type:"completion",name:"\u586B\u7A7A\u9898"},{type:"subjective",name:"\u7B80\u7B54\u9898"}];var O=({index:A,typeName:g,type:p,data:n={},inMouseId:$,isshow:Z,onSetScore:M=()=>{},onDelete:W=()=>{},onMouseEnter:T=()=>{},showAnswer:f=!1})=>{var z;const[B,R]=(0,t.useState)(!1),J=()=>{var a;return e.createElement("div",{className:u.answerWrap},(a=n==null?void 0:n.choices)==null?void 0:a.map((l,_)=>e.createElement("div",{className:`${u.flexRow} mt15`,key:_},e.createElement("div",{style:{lineHeight:"24px",flexShrink:0}},c[_]),e.createElement("div",{className:`${u.answer} ml5`},e.createElement(v.Z,{value:l==null?void 0:l.choice_text})))),f&&e.createElement("div",{className:`mt10 ${u.answerText}`},"\u53C2\u8003\u7B54\u6848\uFF1A",n==null?void 0:n.standard_answer_show))},q=()=>{var a;return e.createElement("div",{className:u.answerWrap},e.createElement("div",{className:`${u.flexRow} mt15`},(a=n==null?void 0:n.choices)==null?void 0:a.map((l,_)=>e.createElement(C.ZP,{disabled:!0,key:_},l==null?void 0:l.choice_text))),f&&e.createElement("div",{className:`mt10 ${u.answerText}`},"\u53C2\u8003\u7B54\u6848\uFF1A",n==null?void 0:n.standard_answer_show))},i=()=>{var a;return e.createElement("div",{className:u.answerWrap},e.createElement("div",{className:`${u.flexRow} mt15`},e.createElement(v.Z,{value:(a=n==null?void 0:n.program_attr)==null?void 0:a.description})),f&&e.createElement("div",{className:"mt15"},e.createElement("div",{className:u.answerText},"\u53C2\u8003\u7B54\u6848\uFF1A",!(n!=null&&n.answer_text)&&"\u6682\u65E0"),e.createElement(v.Z,{value:(n==null?void 0:n.answer_text)||""})))},d=()=>{var a;return e.createElement("div",{className:u.answerWrap},f&&e.createElement("div",{className:`${u.flexColumn} mt15`},(a=n==null?void 0:n.standard_answer)==null?void 0:a.map((l,_)=>e.createElement("div",null,(l==null?void 0:l.model)===1?e.createElement(v.Z,{key:_,value:`\u53C2\u8003\u7B54\u6848\uFF08\u586B\u7A7A${l.position}\uFF09\uFF1A${l.answer_text.join("\u3001")}`,className:u.answerText}):e.createElement("span",{style:{display:"inline-flex",alignItems:"center",marginBottom:5}},"\u53C2\u8003\u7B54\u6848\uFF08\u586B\u7A7A ",l.position,"\uFF09\uFF1A",e.createElement(h.Z,{disabled:!0,width:"180px",value:l.answer_text.join("\u3001")}))))))},r=()=>{var a;return e.createElement("div",{className:u.answerWrap},f&&e.createElement("div",{className:"mt15"},e.createElement("div",{className:u.answerText},"\u53C2\u8003\u7B54\u6848\uFF1A"),e.createElement(v.Z,{value:(a=n==null?void 0:n.answer_texts)==null?void 0:a[0],className:u.answerText})))},m=()=>{var a,l;return e.createElement("div",{className:u.answerWrap,style:{marginTop:10}},e.createElement(v.Z,{showProgramFill:!0,disabledFill:!0,value:S.Base64.decode((a=n==null?void 0:n.program_attr)==null?void 0:a.code)}),f&&e.createElement("div",{className:`${u.flexColumn} mt15`},(l=n==null?void 0:n.standard_answer)==null?void 0:l.map((_,P)=>e.createElement(v.Z,{key:P,value:`\u53C2\u8003\u7B54\u6848\uFF08\u586B\u7A7A${_.position}\uFF09\uFF1A${_.answer_text}`}))))},w=()=>{var a;return e.createElement("div",{className:u.answerWrap},e.createElement("div",{className:"mt10"},"\u9636\u6BB5\u6210\u7EE9"),(a=n==null?void 0:n.shixun)==null?void 0:a.map((l,_)=>{var P,G;return e.createElement("div",null,e.createElement("div",{className:"mt10 font14",key:_},"\u7B2C",_+1,"\u5173 ",l==null?void 0:l.challenge_name," \uFF08",l.challenge_score,"\u5206\uFF09"),f&&e.createElement("div",null,e.createElement("div",{className:u.answerText},"\u53C2\u8003\u7B54\u6848\uFF1A",((P=l.challenge_answers)==null?void 0:P.length)===0?"\u6682\u65E0":""),(G=l.challenge_answers)==null?void 0:G.map((H,X)=>e.createElement("div",{className:"mt15"},e.createElement("div",null,"\u7EA7\u522B",X+1,"\uFF1A",H.name),e.createElement(v.Z,{value:(H==null?void 0:H.contents)||"",className:u.answerText})))))}))},D=()=>{var a;return e.createElement("div",{className:u.answerWrap,style:{display:B&&"none"}},(a=n==null?void 0:n.sub_questions)==null?void 0:a.map((l,_)=>{var P,G,H,X,ee;const x=`<span style="margin-right: 10px">${A+1}.${_+1}</span><span>\uFF08${(P=K.find(E=>E.type==l.item_type))==null?void 0:P.name}\uFF09</span><span class="c-grey-999">\uFF08${l.score}\u5206\uFF09</span>`;return e.createElement(t.Fragment,{key:l==null?void 0:l.id},e.createElement("div",{className:u.titleWrap,style:{marginTop:16}},e.createElement(v.Z,{className:u.titleHtml,value:x+l.name})),(l.item_type=="single"||l.item_type=="multiple")&&e.createElement(e.Fragment,null,(G=l==null?void 0:l.choices)==null?void 0:G.map((E,I)=>e.createElement("div",{className:`${u.flexRow} mt15`,key:I},e.createElement("div",{style:{lineHeight:"24px",flexShrink:0}},c[I]),e.createElement("div",{className:`${u.answer} ml5`},e.createElement(v.Z,{value:E==null?void 0:E.choice_text})))),f&&e.createElement("div",{className:`mt10 ${u.answerText}`},"\u53C2\u8003\u7B54\u6848\uFF1A",l==null?void 0:l.standard_answer_show)),l.item_type=="judgement"&&e.createElement("div",{className:u.answerWrap},e.createElement("div",{className:`${u.flexRow} mt15`},(H=l==null?void 0:l.choices)==null?void 0:H.map((E,I)=>e.createElement(C.ZP,{disabled:!0,key:I},E==null?void 0:E.choice_text))),f&&e.createElement("div",{className:`mt10 ${u.answerText}`},"\u53C2\u8003\u7B54\u6848\uFF1A",l==null?void 0:l.standard_answer_show)),l.item_type=="completion"&&e.createElement("div",{className:u.answerWrap},f&&e.createElement("div",{className:`${u.flexColumn} mt15`},(X=l==null?void 0:l.standard_answer)==null?void 0:X.map((E,I)=>e.createElement("div",null,(E==null?void 0:E.model)===1?e.createElement(v.Z,{key:I,value:`\u53C2\u8003\u7B54\u6848\uFF08\u586B\u7A7A${E.position}\uFF09\uFF1A${E.answer_text.join("\u3001")}`,className:u.answerText}):e.createElement("span",null,"\u53C2\u8003\u7B54\u6848\uFF08\u586B\u7A7A$",E.position,"\uFF09\uFF1A",e.createElement(h.Z,{value:E.answer_text.join("\u3001")})))))),l.item_type=="subjective"&&e.createElement("div",{className:u.answerWrap},f&&e.createElement("div",{className:"mt15"},e.createElement("div",{className:u.answerText},"\u53C2\u8003\u7B54\u6848\uFF1A"),e.createElement(v.Z,{value:(ee=l==null?void 0:l.answer_texts)==null?void 0:ee[0],className:u.answerText}))))}))},y=()=>{const a={SINGLE:J,MULTIPLE:J,JUDGMENT:q,PROGRAM:i,COMPLETION:d,SUBJECTIVE:r,PRACTICAL:w,COMBINATION:D,BPROGRAM:m};return a[p]?a[p]():null},b=(a,l)=>{var _;return`<span style="margin-right: -10px">${l+1}\u3001</span><span class="c-grey-999">\uFF08${(a==null?void 0:a.item_type)==="combination"?`\u5171${(_=a==null?void 0:a.sub_questions)==null?void 0:_.length}\u5C0F\u9898\uFF0C`:""}${a.score}\u5206\uFF09</span> `};return e.createElement("div",{onMouseEnter:()=>T(n.id)},$===n.id&&e.createElement("div",{className:u.action},e.createElement("div",{className:u.setScore,onClick:()=>M(n.id,g,n==null?void 0:n.shixun,n.score,n)},"\u8BBE\u7F6E\u5F97\u5206"),e.createElement("div",{className:u.delete,onClick:()=>W(n.id)},"\u5220\u9664")),e.createElement("div",{className:u.content},e.createElement("div",{className:u.titleWrap,style:{justifyContent:"space-between"}},(n==null?void 0:n.item_type)==="bprogram"?e.createElement(v.Z,{className:u.titleHtml,value:b(n,A)+((z=n==null?void 0:n.program_attr)==null?void 0:z.description)}):e.createElement(v.Z,{className:u.titleHtml,value:b(n,A)+((n==null?void 0:n.item_type)==="combination"?"\uFF08\u9898\u5E72\uFF09":"")+(n.name||(n==null?void 0:n.shixun_name))}),(n==null?void 0:n.item_type)==="combination"&&!Z&&e.createElement("span",{onClick:a=>{R(!B)},style:{textAlign:"end",flexShrink:0,cursor:"pointer"}},B?"\u5C55\u5F00":"\u6536\u8D77")),y()))}},29487:function(ne,k,s){s.d(k,{t:function(){return A}});var t=s(59301),C=s(3113),v={buttonFixed:"buttonFixed___vyq30",button:"button___hxmYv",buttonWrap:"buttonWrap___uK8dl"},u=s(92310),S=s.n(u),h=Object.defineProperty,e=Object.getOwnPropertySymbols,c=Object.prototype.hasOwnProperty,K=Object.prototype.propertyIsEnumerable,j=(g,p,n)=>p in g?h(g,p,{enumerable:!0,configurable:!0,writable:!0,value:n}):g[p]=n,O=(g,p)=>{for(var n in p||(p={}))c.call(p,n)&&j(g,n,p[n]);if(e)for(var n of e(p))K.call(p,n)&&j(g,n,p[n]);return g};const A=({cancelText:g="\u53D6\u6D88",okText:p="\u786E\u5B9A",loading:n=!1,hasOkBtn:$=!0,hasCancelBtn:Z=!0,okButtonProps:M={},onCancel:W=()=>{},onOk:T=()=>{},className:f=""})=>t.createElement("div",{className:S()(v.buttonFixed,f)},t.createElement("div",{className:v.buttonWrap},Z&&t.createElement(C.ZP,{size:"middle",className:`${v.button} mr20`,onClick:W},g),$&&t.createElement(C.ZP,O({size:"middle",type:"primary",className:`${v.button} mr20`,loading:n,onClick:T},M),p)))},15411:function(ne,k,s){var t=s(59301),C=s(50630),v=s(48136),u=s(248),S=s(43418),h=s(59301);const e=(0,t.forwardRef)(({callback:c,width:K,onChange:j,disabled:O,readOnly:A,type:g="",value:p="",style:n={}},$)=>{const Z=(0,t.useRef)(),M=(0,t.useRef)(),[W,T]=(0,t.useState)(0),[f,z]=(0,t.useState)(0),[B,R]=(0,t.useState)(!1),J=()=>{var r=document.createElement("div");r.innerHTML=Z.current.getValue();var m=r.innerText;return c&&c(m),m};(0,t.useImperativeHandle)($,()=>({getData:J}));const q=r=>{r.preventDefault();const m=r.clientX-W,w=r.clientY-f;document.body.onmousemove=D=>{let y=D.clientX-m,b=D.clientY-w;const a=document.getElementsByClassName("markdown-popup-form")[0],l=window.innerWidth-a.offsetWidth,_=window.innerHeight-a.offsetHeight;y=Math.max(0,Math.min(y,l)),b=Math.max(0,Math.min(b,_)),i(D.clientX,D.clientY,m,w)&&(T(y),z(b))},document.body.onmouseup=function(){document.body.onmousemove=null}},i=(r,m,w,D)=>{const y=document.body.clientHeight,b=document.body.clientWidth;return r<20&&w>r||r>b-20&&w<r||m<20&&D>m||m>y-20&&D<m?(document.body.onmousemove=null,document.body.onmouseup=null,!1):!0};(0,t.useEffect)(()=>{B&&setTimeout(()=>{const r=document.getElementsByClassName("markdown-popup-form")[0],m=window.innerWidth/2-r.offsetWidth/2,w=window.innerHeight/2-r.offsetHeight/2;T(m),z(w)},0)},[B]);const d=()=>{O||A||R(!0)};return h.createElement("div",{style:n},h.createElement("div",{style:{width:K||"100%",position:"relative"},className:`${C.Z.mathFillWrap} ${O||A?"cursorDefault":""}`,onClick:()=>d()},h.createElement("math-field",{disabled:O,locale:"zh_cn",class:`${C.Z.mathField} ${g}`,readOnly:A,placeholder:"\u8BF7\u8F93\u5165\u516C\u5F0F",ref:Z,style:{width:"100%",fontSize:p?18:14},value:p||""})),h.createElement(S.default,{maskClosable:!1,centered:!0,width:860,style:{position:"absolute",left:W,top:f},title:h.createElement("div",{style:{cursor:"move"},onMouseDown:q},"\u8F93\u5165\u516C\u5F0F"),open:B,onOk:()=>{const r=M.current.getData();Z.current.setValue(r),j(r),R(!1)},onCancel:()=>{R(!1)},destroyOnClose:!0,className:"markdown-popup-form"},h.createElement(u.Z,{value:p,ref:M,onChange:j,showSaveButton:!1})))});k.Z=e},2473:function(ne,k,s){s.r(k),s.d(k,{default:function(){return q},formatTypeNameToDefaultScore:function(){return R}});var t=s(59301),C=s(63144),v=s(43418),u=s(26220),S=s(66104),h=s(40316),e=s(92399),c={bg:"bg___uBTSf",wrap:"wrap___u47s7",flexRow:"flexRow___QK3mq",flexColumn:"flexColumn___IEH4c",flexJustifyBetween:"flexJustifyBetween___VROqY",relative:"relative___iGg_n",questionNumber:"questionNumber___CYWUo",score:"score___pHhZR",selectTopicButton:"selectTopicButton___aNhaw",line:"line___zzL1y",dragTip:"dragTip___eJpug",typeActive:"typeActive___cHbxQ",mouseTypeActive:"mouseTypeActive___THFkb",typeName:"typeName___PsYTO",typeNumber:"typeNumber___IW6t9",typeAction:"typeAction___gdIEg",setScore:"setScore___ftbgZ",delete:"delete___d1fFi",modal:"modal___COzbG",modalColumn:"modalColumn___Z8nDu",shixunModal:"shixunModal___xxSWV",shixunScore:"shixunScore___zrpkw"},K=s(29487),j=s(89392),O=s.n(j),A=s(85143),g=Object.defineProperty,p=Object.defineProperties,n=Object.getOwnPropertyDescriptors,$=Object.getOwnPropertySymbols,Z=Object.prototype.hasOwnProperty,M=Object.prototype.propertyIsEnumerable,W=(i,d,r)=>d in i?g(i,d,{enumerable:!0,configurable:!0,writable:!0,value:r}):i[d]=r,T=(i,d)=>{for(var r in d||(d={}))Z.call(d,r)&&W(i,r,d[r]);if($)for(var r of $(d))M.call(d,r)&&W(i,r,d[r]);return i},f=(i,d)=>p(i,n(d)),z=(i,d)=>{var r={};for(var m in i)Z.call(i,m)&&d.indexOf(m)<0&&(r[m]=i[m]);if(i!=null&&$)for(var m of $(i))d.indexOf(m)<0&&M.call(i,m)&&(r[m]=i[m]);return r},B=(i,d,r)=>new Promise((m,w)=>{var D=a=>{try{b(r.next(a))}catch(l){w(l)}},y=a=>{try{b(r.throw(a))}catch(l){w(l)}},b=a=>a.done?m(a.value):Promise.resolve(a.value).then(D,y);b((r=r.apply(i,d)).next())});const R=i=>({\u5355\u9009\u9898:2,\u591A\u9009\u9898:5,\u586B\u7A7A\u9898:2,\u5224\u65AD\u9898:2,\u7B80\u7B54\u9898:10,\u7F16\u7A0B\u9898:10,\u5B9E\u8BAD\u9898:5,\u7EC4\u5408\u9898:10})[i]||0,J=i=>{var d=i,{problemsetPreview:r,user:m,globalSetting:w,loading:D,dispatch:y}=d,b=z(d,["problemsetPreview","user","globalSetting","loading","dispatch"]),a,l,_,P;const[G,H]=(0,t.useState)(),[X,ee]=(0,t.useState)(),x=(0,t.useRef)();console.log(r,"problemsetPreview"),(0,t.useEffect)(()=>(y({type:"globalSetting/footerToggle",payload:!1}),()=>{y({type:"globalSetting/footerToggle",payload:!0})}),[]),(0,t.useEffect)(()=>{E()},[]);const E=()=>{y({type:"problemsetPreview/getPaperData"})},I=(o,N,L=[],V,le)=>{var te;const Y=O().cloneDeep(le),Q=O().cloneDeep(L).map(F=>f(T({},F),{challenge_score:F.challenge_score||5}));if(x.current=V||R(N),N==="\u5B9E\u8BAD\u9898")return v.default.confirm({centered:!0,width:530,title:"\u8BBE\u7F6E\u5206\u6570",content:t.createElement("div",{className:c.shixunModal},t.createElement("div",null,"\u5173\u5361\uFF1A"),Q==null?void 0:Q.map((F,U)=>t.createElement("div",{className:c.shixunScore},U+1,"\u3001",F.challenge_name,t.createElement("div",{style:{minWidth:"130px"}},t.createElement(u.Z,{defaultValue:F.challenge_score,min:1,onChange:ue=>{F.challenge_score=ue}}),t.createElement("span",{className:"ml5"},"\u5206/\u9898"))))),okText:"\u786E\u8BA4",cancelText:"\u53D6\u6D88",onOk:()=>B(void 0,null,function*(){yield(0,A.Cc)({id:o,challenge_scores:Q.map(F=>({challenge_id:F.challenge_id,score:F.challenge_score}))}),x.current=null,E()})});if(N==="\u7EC4\u5408\u9898")return v.default.confirm({centered:!0,width:530,title:"\u8BBE\u7F6E\u5206\u6570",content:t.createElement("div",{className:c.shixunModal,style:{maxHeight:200,overflow:"auto"}},(te=Y==null?void 0:Y.sub_questions)==null?void 0:te.map((F,U)=>t.createElement("div",{className:c.shixunScore},"\u7B2C",U+1,"\u5C0F\u9898",t.createElement("div",{style:{minWidth:"130px"}},t.createElement(u.Z,{defaultValue:F.score,min:1,onChange:ue=>{F.score=ue}}),t.createElement("span",{className:"ml5"},"\u5206"))))),okText:"\u786E\u8BA4",cancelText:"\u53D6\u6D88",onOk:()=>B(void 0,null,function*(){var F;yield(0,A.Vl)({id:o,subs:(F=Y==null?void 0:Y.sub_questions)==null?void 0:F.map(U=>({basket_id:U.basket_id,score:U.score}))}),x.current=null,E()})});v.default.confirm({centered:!0,title:"\u8BBE\u7F6E\u5206\u6570",content:t.createElement("div",{className:""},t.createElement("span",null,"\u672C\u9898\u5206\u503C\uFF1A"),t.createElement(u.Z,{min:1,defaultValue:x.current,onChange:F=>{x.current=F}}),t.createElement("span",{className:"ml5"},"\u5206/\u9898"),t.createElement("br",null),N==="\u586B\u7A7A\u9898"&&t.createElement("div",{style:{color:"rgb(255, 0, 0)"}},"\u6BCF\u7A7A\u5206\u503C\u6309\u6BCF\u9898\u5206\u503C\u53D6\u5E73\u5747\u5206\u8BA1\u7B97")),okText:"\u786E\u8BA4",cancelText:"\u53D6\u6D88",onOk:()=>B(void 0,null,function*(){yield y({type:"problemsetPreview/setScore",payload:{id:o,score:x.current}}),x.current=null,E()})})},ae=o=>{v.default.confirm({centered:!0,title:"\u63D0\u793A",content:t.createElement("div",{className:c.modal},"\u786E\u8BA4\u5220\u9664\u8BE5\u8BD5\u9898\uFF1F"),okText:"\u786E\u8BA4",cancelText:"\u53D6\u6D88",onOk:()=>B(void 0,null,function*(){yield y({type:"problemsetPreview/handleDelete",payload:{id:o}}),E()})})},re=(o,N)=>{x.current=R(N),v.default.confirm({centered:!0,title:"\u6279\u91CF\u8BBE\u7F6E\u5206\u6570",content:t.createElement("div",{className:""},t.createElement("span",null,N==="\u7EC4\u5408\u9898"?"\u7EC4\u5408\u9898\u4E2D\u7684\u6BCF\u5C0F\u9898":N,"\uFF1A"),t.createElement(u.Z,{min:1,defaultValue:x.current,onChange:L=>{x.current=L}}),t.createElement("span",{className:"ml5"},"\u5206/\u9898"),t.createElement("br",null),N==="\u586B\u7A7A\u9898"&&t.createElement("div",{style:{color:"rgb(255, 0, 0)"}},"\u6BCF\u7A7A\u5206\u503C\u6309\u6BCF\u9898\u5206\u503C\u53D6\u5E73\u5747\u5206\u8BA1\u7B97")),okText:"\u786E\u8BA4",cancelText:"\u53D6\u6D88",onOk:()=>B(void 0,null,function*(){yield y({type:"problemsetPreview/batchSetScore",payload:{item_type:o,score:x.current}}),x.current=null,E()})})},se=o=>{v.default.confirm({centered:!0,title:"\u63D0\u793A",content:t.createElement("div",{className:c.modalColumn},t.createElement("p",null,"\u5220\u9664\u5927\u9898\uFF0C\u5C06\u5220\u9664\u8BE5\u5927\u9898\u4E0B\u6240\u6709\u5C0F\u9898"),t.createElement("p",null,"\u786E\u8BA4\u5220\u9664\u8BE5\u5927\u9898\uFF1F")),okText:"\u786E\u8BA4",cancelText:"\u53D6\u6D88",onOk:()=>B(void 0,null,function*(){yield y({type:"problemsetPreview/batchDelete",payload:{item_type:o}}),E()})})},oe=(o,N)=>B(void 0,null,function*(){if(!o.destination||!o.source)return;const L=N.questions[o.source.index].id,V=o.destination.index+1;(yield y({type:"problemsetPreview/adjustPosition",payload:{id:L,position:V}})).status!==-1&&E()});return t.createElement("section",{className:c.bg},t.createElement(S.Z,{className:"mt30",separator:">"},t.createElement(S.Z.Item,null,"\u8BD5\u9898\u5E93"),t.createElement(S.Z.Item,{href:"/problemset"},"\u4EBA\u5DE5\u7EC4\u5377"),t.createElement(S.Z.Item,null,"\u8BD5\u5377\u9884\u89C8")),t.createElement("div",{className:c.wrap},t.createElement("div",{className:"pt20 pb20"},t.createElement("div",{className:`${c.flexRow} ${c.flexJustifyBetween}`},t.createElement("div",null,t.createElement("span",{className:c.questionNumber},"\u9898\u6570\uFF1A",(a=r.paperData)==null?void 0:a.all_questions_count),t.createElement("span",{className:c.score},"\u603B\u5206\uFF1A",(l=r.paperData)==null?void 0:l.all_score)),t.createElement("div",{className:c.selectTopicButton,onClick:()=>C.history.push("/problemset/preview_select")},"\u7EE7\u7EED\u9009\u9898")),t.createElement("div",{className:c.line}),t.createElement("div",{className:c.dragTip},"\u5C0F\u9898\u4E4B\u95F4\u53EF\u4EE5\u62D6\u52A8\u6392\u5E8F"),(P=(_=r.paperData)==null?void 0:_.questionList)==null?void 0:P.map((o,N)=>{const L=o.type===X;return console.log(o,"paperItem"),t.createElement("div",{className:`${c.relative} mt20 mb20`,key:N},t.createElement("div",{className:`${c.typeActive} ${L?c.mouseTypeActive:""}`,onMouseEnter:()=>{ee(o.type),H(null)}},t.createElement("span",{className:`${c.typeName} ${L?"ml20":""}`},o.number,"\u3001",o.name),t.createElement("span",{className:c.typeNumber},"\uFF08\u5171",o.questions_count,"\u9898\uFF0C",(o==null?void 0:o.type)==="COMBINATION"?`\u5305\u542B${o==null?void 0:o.sub_questions_count}\u5C0F\u9898\uFF0C`:"","\u5171",o.questions_score,"\u5206\uFF09")),L&&t.createElement("div",{className:`${c.typeAction} ${c.flexRow}`},o.type!=="PRACTICAL"&&t.createElement("div",{className:c.setScore,onClick:()=>re(o.type,o.name)},"\u6279\u91CF\u8BBE\u7F6E\u5F97\u5206"),t.createElement("div",{className:c.delete,onClick:()=>se(o.type)},"\u5220\u9664")),t.createElement(h.Z5,{onDragEnd:V=>oe(V,o)},t.createElement(h.bK,{droppableId:N.toString()},(V,le)=>{var te;return t.createElement("div",f(T({className:"mt20",ref:V.innerRef},V.droppableProps),{onScroll:()=>{}}),(te=o.questions)==null?void 0:te.map((Y,Q)=>t.createElement(h._l,{draggableId:Y.id.toString(),index:Q,key:Y.id},F=>t.createElement("div",T(T({ref:F.innerRef},F.draggableProps),F.dragHandleProps),t.createElement(e.Z,{index:Q,typeName:o.name,type:o.type,data:Y,inMouseId:G,onSetScore:I,onDelete:ae,onMouseEnter:U=>{H(U),ee(null)}})))))})))}))),t.createElement(K.t,{okText:"\u4FDD\u5B58\u8BD5\u5377",onCancel:()=>C.history.replace("/problemset"),onOk:()=>C.history.push("/problemset/preview_new")}))};var q=(0,C.connect)(({problemsetPreview:i,user:d,loading:r,globalSetting:m})=>({problemsetPreview:i,user:d,globalSetting:m,loading:r.effects}))(J)}}]);