|
|
(self.webpackChunk=self.webpackChunk||[]).push([[48431,88699,52720],{22596:function(e,n,t){"use strict";t.d(n,{Z:function(){return l}});var r=t(4751),i=t(59301),a={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"},o=t(68475),s=function(e,n){return i.createElement(o.Z,(0,r.Z)({},e,{ref:n,icon:a}))};var l=i.forwardRef(s)},44770:function(e,n,t){"use strict";t.d(n,{Z:function(){return l}});var r=t(4751),i=t(59301),a={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"defs",attrs:{},children:[{tag:"style",attrs:{}}]},{tag:"path",attrs:{d:"M632 698.3l141.9-112a8 8 0 000-12.6L632 461.7c-5.3-4.2-13-.4-13 6.3v76H295c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h324v76c0 6.7 7.8 10.4 13 6.3zm261.3-405L730.7 130.7c-7.5-7.5-16.7-13-26.7-16V112H144c-17.7 0-32 14.3-32 32v278c0 4.4 3.6 8 8 8h56c4.4 0 8-3.6 8-8V184h136v136c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V205.8l136 136V422c0 4.4 3.6 8 8 8h56c4.4 0 8-3.6 8-8v-83.5c0-17-6.7-33.2-18.7-45.2zM640 288H384V184h256v104zm264 436h-56c-4.4 0-8 3.6-8 8v108H184V732c0-4.4-3.6-8-8-8h-56c-4.4 0-8 3.6-8 8v148c0 17.7 14.3 32 32 32h736c17.7 0 32-14.3 32-32V732c0-4.4-3.6-8-8-8z"}}]},name:"delivered-procedure",theme:"outlined"},o=t(68475),s=function(e,n){return i.createElement(o.Z,(0,r.Z)({},e,{ref:n,icon:a}))};var l=i.forwardRef(s)},22415:function(e,n,t){"use strict";t.d(n,{Z:function(){return l}});var r=t(4751),i=t(59301),a={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M482 152h60q8 0 8 8v704q0 8-8 8h-60q-8 0-8-8V160q0-8 8-8z"}},{tag:"path",attrs:{d:"M192 474h672q8 0 8 8v60q0 8-8 8H160q-8 0-8-8v-60q0-8 8-8z"}}]},name:"plus",theme:"outlined"},o=t(68475),s=function(e,n){return i.createElement(o.Z,(0,r.Z)({},e,{ref:n,icon:a}))};var l=i.forwardRef(s)},44539:function(e,n,t){"use strict";t.d(n,{Z:function(){return l}});var r=t(4751),i=t(59301),a={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M909.1 209.3l-56.4 44.1C775.8 155.1 656.2 92 521.9 92 290 92 102.3 279.5 102 511.5 101.7 743.7 289.8 932 521.9 932c181.3 0 335.8-115 394.6-276.1 1.5-4.2-.7-8.9-4.9-10.3l-56.7-19.5a8 8 0 00-10.1 4.8c-1.8 5-3.8 10-5.9 14.9-17.3 41-42.1 77.8-73.7 109.4A344.77 344.77 0 01655.9 829c-42.3 17.9-87.4 27-133.8 27-46.5 0-91.5-9.1-133.8-27A341.5 341.5 0 01279 755.2a342.16 342.16 0 01-73.7-109.4c-17.9-42.4-27-87.4-27-133.9s9.1-91.5 27-133.9c17.3-41 42.1-77.8 73.7-109.4 31.6-31.6 68.4-56.4 109.3-73.8 42.3-17.9 87.4-27 133.8-27 46.5 0 91.5 9.1 133.8 27a341.5 341.5 0 01109.3 73.8c9.9 9.9 19.2 20.4 27.8 31.4l-60.2 47a8 8 0 003 14.1l175.6 43c5 1.2 9.9-2.6 9.9-7.7l.8-180.9c-.1-6.6-7.8-10.3-13-6.2z"}}]},name:"reload",theme:"outlined"},o=t(68475),s=function(e,n){return i.createElement(o.Z,(0,r.Z)({},e,{ref:n,icon:a}))};var l=i.forwardRef(s)},80814:function(e,n,t){"use strict";t.d(n,{Z:function(){return l}});var r=t(4751),i=t(59301),a={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M924.8 625.7l-65.5-56c3.1-19 4.7-38.4 4.7-57.8s-1.6-38.8-4.7-57.8l65.5-56a32.03 32.03 0 009.3-35.2l-.9-2.6a443.74 443.74 0 00-79.7-137.9l-1.8-2.1a32.12 32.12 0 00-35.1-9.5l-81.3 28.9c-30-24.6-63.5-44-99.7-57.6l-15.7-85a32.05 32.05 0 00-25.8-25.7l-2.7-.5c-52.1-9.4-106.9-9.4-159 0l-2.7.5a32.05 32.05 0 00-25.8 25.7l-15.8 85.4a351.86 351.86 0 00-99 57.4l-81.9-29.1a32 32 0 00-35.1 9.5l-1.8 2.1a446.02 446.02 0 00-79.7 137.9l-.9 2.6c-4.5 12.5-.8 26.5 9.3 35.2l66.3 56.6c-3.1 18.8-4.6 38-4.6 57.1 0 19.2 1.5 38.4 4.6 57.1L99 625.5a32.03 32.03 0 00-9.3 35.2l.9 2.6c18.1 50.4 44.9 96.9 79.7 137.9l1.8 2.1a32.12 32.12 0 0035.1 9.5l81.9-29.1c29.8 24.5 63.1 43.9 99 57.4l15.8 85.4a32.05 32.05 0 0025.8 25.7l2.7.5a449.4 449.4 0 00159 0l2.7-.5a32.05 32.05 0 0025.8-25.7l15.7-85a350 350 0 0099.7-57.6l81.3 28.9a32 32 0 0035.1-9.5l1.8-2.1c34.8-41.1 61.6-87.5 79.7-137.9l.9-2.6c4.5-12.3.8-26.3-9.3-35zM788.3 465.9c2.5 15.1 3.8 30.6 3.8 46.1s-1.3 31-3.8 46.1l-6.6 40.1 74.7 63.9a370.03 370.03 0 01-42.6 73.6L721 702.8l-31.4 25.8c-23.9 19.6-50.5 35-79.3 45.8l-38.1 14.3-17.9 97a377.5 377.5 0 01-85 0l-17.9-97.2-37.8-14.5c-28.5-10.8-55-26.2-78.7-45.7l-31.4-25.9-93.4 33.2c-17-22.9-31.2-47.6-42.6-73.6l75.5-64.5-6.5-40c-2.4-14.9-3.7-30.3-3.7-45.5 0-15.3 1.2-30.6 3.7-45.5l6.5-40-75.5-64.5c11.3-26.1 25.6-50.7 42.6-73.6l93.4 33.2 31.4-25.9c23.7-19.5 50.2-34.9 78.7-45.7l37.9-14.3 17.9-97.2c28.1-3.2 56.8-3.2 85 0l17.9 97 38.1 14.3c28.7 10.8 55.4 26.2 79.3 45.8l31.4 25.8 92.8-32.9c17 22.9 31.2 47.6 42.6 73.6L781.8 426l6.5 39.9zM512 326c-97.2 0-176 78.8-176 176s78.8 176 176 176 176-78.8 176-176-78.8-176-176-176zm79.2 255.2A111.6 111.6 0 01512 614c-29.9 0-58-11.7-79.2-32.8A111.6 111.6 0 01400 502c0-29.9 11.7-58 32.8-79.2C454 401.6 482.1 390 512 390c29.9 0 58 11.6 79.2 32.8A111.6 111.6 0 01624 502c0 29.9-11.7 58-32.8 79.2z"}}]},name:"setting",theme:"outlined"},o=t(68475),s=function(e,n){return i.createElement(o.Z,(0,r.Z)({},e,{ref:n,icon:a}))};var l=i.forwardRef(s)},86505:function(e,n,t){"use strict";t.r(n);var r=t(91232),i=t.n(r),a=t(7557),o=t.n(a),s=t(82242),l=t.n(s),c=t(41498),d=t.n(c),u=t(79800),h=t.n(u),p=t(39647),f=t.n(p),x=t(59301),m=t(96707),v=t(98135),g=t(43418),y=t(95237),j=t(43604),b=t(5112),w=t(24905),_=t(28103),Z=t(66104),k=t(38854),S=t(3113),C=t(8591),O=t(53864),N=t(86129),E=t.n(N),I=t(22596),q=t(65041),A=t(44770),P=t(86984),$=t(80814),z=t(76794),B=t(44132),H=t(76279),M=t(52565),D=t(25091),R=t(69543),T=t(58637),F=t(99232),L=t.n(F),Y=t(44425),X=t.n(Y),V=t(22961),W=t(66510),U=t(74542),G=t(24334),J=t(57265),Q=t(68339),K=t(37712),ee=["exercise","globalSetting","loading","user","dispatch"],ne=v.Z.TextArea;n.default=(0,m.connect)((function(e){var n=e.exercise,t=e.loading,r=e.user;return{exercise:n,globalSetting:e.globalSetting,user:r,loading:t.effects}}))((function(e){var n,r,a,s,c,u,p,v,N=e.exercise,F=(e.globalSetting,e.loading,e.user),Y=e.dispatch,te=(f()(e,ee),(0,m.useParams)()),re=F.userInfo,ie=(0,x.useState)({}),ae=h()(ie,2),oe=ae[0],se=ae[1],le=(0,x.useRef)(),ce=(0,x.useRef)(!1),de=(0,x.useState)(!1),ue=h()(de,2),he=(ue[0],ue[1]),pe=(0,x.useState)({}),fe=h()(pe,2),xe=fe[0],me=fe[1],ve=(0,x.useState)(new(E())),ge=h()(ve,2),ye=ge[0],je=ge[1],be=(0,x.useState)([]),we=h()(be,2),_e=we[0],Ze=we[1],ke=(0,x.useState)(!1),Se=h()(ke,2),Ce=Se[0],Oe=Se[1],Ne=(0,x.useState)(!1),Ee=h()(Ne,2),Ie=Ee[0],qe=Ee[1],Ae=(0,x.useState)(!1),Pe=h()(Ae,2),$e=Pe[0],ze=Pe[1],Be=(0,x.useState)(!1),He=h()(Be,2),Me=He[0],De=He[1],Re=(0,x.useState)(!1),Te=h()(Re,2),Fe=Te[0],Le=Te[1],Ye=(0,x.useState)(!1),Xe=h()(Ye,2),Ve=Xe[0],We=Xe[1],Ue=(0,x.useState)(!1),Ge=h()(Ue,2),Je=Ge[0],Qe=Ge[1],Ke=(0,x.useState)(""),en=h()(Ke,2),nn=en[0],tn=en[1];(0,x.useEffect)((function(){null!=re&&re.login&&sn();try{Ze(JSON.parse(localStorage.total_exercise_users))}catch(e){}}),[te.userId,te.coursesId,te.exerciseId,re]);var rn=function(){document.querySelectorAll("canvas").forEach((function(e){(!e.clientWidth||!e.clientHeight)&&e.remove()}))},an=function(){document.body.scrollIntoView()},on=function(e){var n,t,r,i=null==e||null===(n=e.exercise_answer_user)||void 0===n?void 0:n.user_id;if(null!=e&&null!==(t=e.exercise)&&void 0!==t&&t.question_random||null!=e&&null!==(r=e.exercise)&&void 0!==r&&r.choice_random){var a,o=1;e.exercise.question_random=null==e||null===(a=e.exercise_question_types)||void 0===a?void 0:a.map((function(n){var t,r;return null!=e&&null!==(t=e.exercise)&&void 0!==t&&t.choice_random&&(0!==n.question_type&&1!==n.question_type||n.items.map((function(e){return e.question_choices=(0,H.M2)(e.question_choices,i),e})),7===n.question_type&&n.items.forEach((function(e){e.sub_exercise_questions.forEach((function(e){e.question_choices=(0,H.M2)(e.question_choices,i)}))}))),null!=e&&null!==(r=e.exercise)&&void 0!==r&&r.question_random&&(n.items=(0,H.M2)(n.items,i)),n.items.map((function(e){return e.question_num=o,o++,e})),n}))}},sn=function(){var e=d()(o()().mark((function e(){var n;return o()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(Y({type:"exercise/getExerciseExportHeadData",payload:{id:te.exerciseId||te.categoryId,identify:te.userId||null}}),!te.userId){e.next=9;break}return e.next=4,Y({type:"exercise/getReviewExercise",payload:{exerciseId:te.exerciseId,login:te.userId}});case 4:n=e.sent,on(n),ce.current=!1,e.next=13;break;case 9:return e.next=11,Y({type:"exercise/editExercise",payload:{coursesId:te.coursesId,categoryId:te.exerciseId}});case 11:n=e.sent,ce.current=!0;case 13:me(l()({},n||{})),setTimeout((function(){document.getElementById("export-id-all")}),1500);case 15:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}(),ln=function(){ye.generateAsync({type:"blob"}).then((function(e){var n,t,r,i=document.createElement("a");i.href=window.URL.createObjectURL(e),i.download=Object.keys(ye.files).length>1?(null==xe||null===(n=xe.exercise)||void 0===n?void 0:n.exercise_name)+".zip":((null==N||null===(t=N.exerciseExportHeadData)||void 0===t?void 0:t.user)||(null==xe||null===(r=xe.exercise)||void 0===r?void 0:r.exercise_name))+".zip",document.body.appendChild(i);var a=document.createEvent("MouseEvents");a.initEvent("click",!1,!1),i.dispatchEvent(a),document.body.removeChild(i),je(new(E()))})),qe(!1),De(!1),ze(!1),Oe(!1)},cn=function(){var e=d()(o()().mark((function e(n){var t,r,i,a,s,c,u,h,p,f,x,m,v;return o()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return v=function(){return v=d()(o()().mark((function e(){var n;return o()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r++,ce.current=!1,an(),e.next=5,Y({type:"exercise/getExerciseExportHeadData",payload:{id:te.exerciseId||te.categoryId,identify:_e[r-1].user_login}});case 5:return e.next=7,Y({type:"exercise/getReviewExercise",payload:{exerciseId:te.exerciseId,login:_e[r-1].user_login}});case 7:n=e.sent,on(n),me(l()({},n||{})),setTimeout(d()(o()().mark((function e(){var n,t,s;return o()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:rn(),n=X()(),t=o()().mark((function e(t){return o()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,n.set(h).from(a[t]).toContainer().toCanvas().toPdf().get("pdf").then(function(){var e=d()(o()().mark((function e(n){return o()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!(t<a.length-1)){e.next=3;break}return e.next=3,n.addPage();case 3:case"end":return e.stop()}}),e)})));return function(n){return e.apply(this,arguments)}}());case 2:case"end":return e.stop()}}),e)})),s=0;case 4:if(!(s<a.length)){e.next=9;break}return e.delegateYield(t(s),"t0",6);case 6:s++,e.next=4;break;case 9:ye.file("".concat(_e[r-1].user_name,"-").concat(L()().format("YYYY-MM-DD HH:mm:ss"),".pdf"),n.output("blob")),i.update({content:(0,K.jsxs)("div",{children:["当前进度: ",(0,K.jsx)("span",{className:"c-blue",children:r+1}),"/",null==_e?void 0:_e.length]})}),r==(null==_e?void 0:_e.length)?(i.destroy(),he(!1),ln()):m();case 12:case"end":return e.stop()}}),e)}))),2600);case 11:case"end":return e.stop()}}),e)}))),v.apply(this,arguments)},m=function(){return v.apply(this,arguments)},"all"===n?ce.current=!1:te.userId||(ce.current=!0),an(),Oe(!0),r=0,"all"!==n&&he(!0),i=g.Z.info({width:460,title:(0,K.jsxs)("div",{children:["正在导出试卷,",(0,K.jsx)("span",{className:"c-red",children:"请勿关闭或操作当前浏览器窗口"})]}),content:"all"===n?(0,K.jsxs)("div",{children:["当前进度: ",(0,K.jsx)("span",{className:"c-blue",children:r+1}),"/",null==_e?void 0:_e.length]}):null,maskClosable:!1,className:z.Z.modal,onOk:function(){}}),rn(),e.next=11,new Promise((function(e,n){setTimeout((function(){e("")}),1e3)}));case 11:a=le.current.children,s="".concat(L()().format("YYYY-MM-DD HH:mm:ss")),null!==(t=N.exerciseExportHeadData)&&void 0!==t&&t.user&&(s="".concat((null===(c=N.exerciseExportHeadData)||void 0===c?void 0:c.student_id)||"").concat(null===(u=N.exerciseExportHeadData)||void 0===u?void 0:u.user)),h={html2canvas:{letterRendering:!0,useCORS:!0,allowTaint:!1},jsPDF:{unit:"in",format:"letter",orientation:"portrait"},pagebreak:{mode:["avoid-all"]}},p=X()(),f=o()().mark((function e(n){return o()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,p.set(h).from(a[n]).toContainer().toCanvas().toPdf().get("pdf").then(function(){var e=d()(o()().mark((function e(t){return o()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!(n<a.length-1)){e.next=3;break}return e.next=3,t.addPage();case 3:case"end":return e.stop()}}),e)})));return function(n){return e.apply(this,arguments)}}());case 2:case"end":return e.stop()}}),e)})),x=0;case 18:if(!(x<a.length)){e.next=23;break}return e.delegateYield(f(x),"t0",20);case 20:x++,e.next=18;break;case 23:null!=_e&&_e.length&&"all"===n?m():(ye.file("".concat(s,".pdf"),p.output("blob"),{base64:!1}),i.destroy(),he(!1),ln());case 24:case"end":return e.stop()}}),e)})));return function(n){return e.apply(this,arguments)}}(),dn=function(){var e=d()(o()().mark((function e(n){var t,r,i,a,s,c,u;return o()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return u=function(){return(u=d()(o()().mark((function e(){var n;return o()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r++,ce.current=!1,an(),e.next=5,Y({type:"exercise/getExerciseExportHeadData",payload:{id:te.exerciseId||te.categoryId,identify:_e[r-1].user_login}});case 5:return e.next=7,Y({type:"exercise/getReviewExercise",payload:{exerciseId:te.exerciseId,login:_e[r-1].user_login}});case 7:n=e.sent,on(n),me(l()({},n||{})),setTimeout(d()(o()().mark((function e(){var n,t;return o()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=te.exerciseId,t=(0,H.NY)({url:Q.Z.API_SERVER+"/api/exercises/".concat(n,"/user_exercise_detail.json"),query:{exercise_id:n,login:_e[r-1].user_login,middle_export:1,is_export_comment:Fe?1:0}}),e.next=4,(0,H.Br)(t).then((function(e){ye.file("".concat(_e[r-1].user_name,".docx"),e)}));case 4:i.update({content:(0,K.jsxs)("div",{children:["当前进度: ",(0,K.jsx)("span",{className:"c-blue",children:r+1}),"/",null==_e?void 0:_e.length]})}),r==(null==_e?void 0:_e.length)?(i.destroy(),he(!1),ln()):c();case 6:case"end":return e.stop()}}),e)}))),2600);case 11:case"end":return e.stop()}}),e)})))).apply(this,arguments)},c=function(){return u.apply(this,arguments)},ce.current=!1,an(),Oe(!0),r=0,"all"!==n&&he(!0),i=g.Z.info({width:460,title:(0,K.jsxs)("div",{children:["正在导出试卷,",(0,K.jsx)("span",{className:"c-red",children:"请勿关闭或操作当前浏览器窗口"})]}),content:"all"===n?(0,K.jsxs)("div",{children:["当前进度: ",(0,K.jsx)("span",{className:"c-blue",children:r+1}),"/",null==_e?void 0:_e.length]}):null,maskClosable:!1,className:z.Z.modal,onOk:function(){}}),e.next=10,new Promise((function(e,n){setTimeout((function(){e("")}),1e3)}));case 10:le.current.children,"".concat(L()().format("YYYY-MM-DD HH:mm:ss")),null!==(t=N.exerciseExportHeadData)&&void 0!==t&&t.user&&"".concat((null===(a=N.exerciseExportHeadData)||void 0===a?void 0:a.student_id)||"").concat(null===(s=N.exerciseExportHeadData)||void 0===s?void 0:s.user),c();case 14:case"end":return e.stop()}}),e)})));return function(n){return e.apply(this,arguments)}}(),un=function(e,n){var t,r,i,a,o,s,c,d,u,h,p,f,x,m,v;return(0,K.jsxs)(K.Fragment,{children:[(0,K.jsxs)("div",{style:{display:"flex"},className:z.Z.programTitle,children:[(0,K.jsxs)("span",{style:{flexShrink:0},className:"font18",children:[n,"."]}),(0,K.jsx)(B.Z,{value:e.question_title}),(0,K.jsxs)("span",{style:{flexShrink:0},className:"font16",children:["(",7===(null==e?void 0:e.question_type)?"共".concat(null==e?void 0:e.sub_q_count,"小题"):""," ",e.question_score,"分)"]})]}),e.question_type===W.c.Single&&(0,K.jsx)(K.Fragment,{children:null===(t=e.question_choices)||void 0===t?void 0:t.map((function(n,t){var r;return(0,K.jsxs)(y.Z,{children:[(0,K.jsx)(j.Z,{flex:"25px",children:(0,K.jsx)("div",{style:{width:25,overflow:"hidden"},children:(0,K.jsx)(b.ZP,{checked:null===(r=e.user_answer)||void 0===r?void 0:r.includes(n.choice_id),style:{width:25}})})}),(0,K.jsx)(j.Z,{flex:"1",children:(0,K.jsx)(B.Z,{value:n.choice_text||""})})]},t)}))}),e.question_type===W.c.Multiple&&(0,K.jsx)(K.Fragment,{children:null===(r=e.question_choices)||void 0===r?void 0:r.map((function(n,t){var r;return(0,K.jsxs)(y.Z,{children:[(0,K.jsx)(j.Z,{flex:"25px",children:(0,K.jsx)("div",{style:{width:25,overflow:"hidden"},children:(0,K.jsx)(w.Z,{checked:null===(r=e.user_answer)||void 0===r?void 0:r.includes(n.choice_id),style:{width:25}})})}),(0,K.jsx)(j.Z,{flex:"1",children:(0,K.jsx)(B.Z,{value:n.choice_text||""})})]},t)}))}),e.question_type===W.c.Judge&&(0,K.jsx)("div",{className:z.Z.flexRow,children:null===(i=e.question_choices)||void 0===i?void 0:i.map((function(n,t){var r;return(0,K.jsxs)(y.Z,{children:[(0,K.jsx)(j.Z,{flex:"25px",children:(0,K.jsx)("div",{style:{width:25,overflow:"hidden"},children:(0,K.jsx)(b.ZP,{checked:null===(r=e.user_answer)||void 0===r?void 0:r.includes(n.choice_id),style:{width:25}})})}),(0,K.jsx)(j.Z,{flex:"1",children:n.choice_text})]},t)}))}),e.question_type===W.c.Fill&&!ce.current&&(0,K.jsx)(M.Z,{item:e,answerData:xe,changeScoreData:oe,textValue:null===(a=oe[e.q_position])||void 0===a?void 0:a.text,textOnChange:function(n){oe[e.q_position].text=n,se(l()({},oe))},seeAnswerVisible:!1}),e.question_type===W.c.Shixun&&(0,K.jsx)(D.Z,{item:e,answerData:xe,hasChangeScore:!1,autoHeight:Ce}),e.question_type===W.c.Subjective&&null!=e&&null!==(o=e.user_answer)&&void 0!==o&&o[0]?(0,K.jsxs)("div",{className:z.Z.simpleBg,children:[(0,K.jsx)("aside",{className:"font14 c-light-primary mb5",children:"学生答题"}),(0,K.jsx)("div",{children:Me?(0,K.jsx)(B.Z,{value:null==e||null===(s=e.user_answer_light)||void 0===s?void 0:s[0]}):(0,K.jsx)(B.Z,{value:null==e||null===(c=e.user_answer)||void 0===c?void 0:c[0]})})]}):null,e.question_type===W.c.Program&&(0,K.jsx)(R.Z,{item:e,answerData:xe,autoHeight:Ce}),e.question_type===W.c.Combine&&(0,K.jsx)(K.Fragment,{children:null===(d=e.sub_exercise_questions)||void 0===d?void 0:d.map((function(e,t){var r,i;return(0,K.jsxs)("div",{style:{marginLeft:10},children:[(0,K.jsxs)("span",{style:{fontSize:"16px"},children:[n,".",t+1,"(单选题)",null==e?void 0:e.question_title,"(",null==e?void 0:e.question_score,"分)"]}),null===(r=e.question_choices)||void 0===r?void 0:r.map((function(n,t){var r;return(0,K.jsxs)(y.Z,{children:[(0,K.jsx)(j.Z,{flex:"25px",children:(0,K.jsx)("div",{style:{width:25,overflow:"hidden"},children:(0,K.jsx)(b.ZP,{checked:null===(r=e.user_answer)||void 0===r?void 0:r.includes(n.choice_id),style:{width:25}})})}),(0,K.jsx)(j.Z,{flex:"1",children:(0,K.jsx)(B.Z,{value:n.choice_text||""})})]},t)})),(null==e?void 0:e.standard_answer_show)&&Ie&&(0,K.jsxs)("span",{className:"font16 ",children:["正确答案:",null==e?void 0:e.standard_answer_show]}),((null==e?void 0:e.standard_answer_show)||(null==e||null===(i=e.standard_answer)||void 0===i?void 0:i.length)>0)&&Ie&&(0,K.jsxs)(y.Z,{style:{marginTop:14},children:[(0,K.jsx)("span",{className:"font16 ",children:"解析:"}),(0,K.jsx)(B.Z,{className:z.Z.renderHtml,value:(null==e?void 0:e.analysis)||"暂无解析"})]})]})}))}),8===e.question_type&&(0,K.jsx)(K.Fragment,{children:(0,K.jsx)("div",{style:{padding:"20px 30px"},children:(0,K.jsx)(B.Z,{showProgramFill:!0,disabledFill:!0,value:G.Base64.decode((null==e||null===(u=e.program_attr)||void 0===u?void 0:u.code)||"")})})}),Ie&&(0,K.jsxs)("div",{style:{marginTop:10},children:[(null==e?void 0:e.question_type)<3&&(null==e?void 0:e.standard_answer_show)&&(0,K.jsxs)("span",{className:"font16 ",children:["正确答案:",null==e?void 0:e.standard_answer_show]}),!(null==e||null===(h=e.standard_answer)||void 0===h||!h.length)&&Ie&&3===(null==e?void 0:e.question_type)&&(0,K.jsx)("div",{children:null==e||null===(p=e.standard_answer)||void 0===p?void 0:p.map((function(e,n){return(0,K.jsxs)("div",{children:[(0,K.jsxs)("span",{children:["参考答案:(填空",n+1,"):"]}),(0,K.jsx)("div",{children:(0,K.jsx)(ne,{autoSize:!0,disabled:!0,value:null==e?void 0:e.answer_text[0]})})]})}))}),!(null==e||null===(f=e.standard_answer)||void 0===f||!f.length)&&Ie&&8===(null==e?void 0:e.question_type)&&(0,K.jsx)("div",{children:null==e||null===(x=e.standard_answer)||void 0===x?void 0:x.map((function(e,n){return(0,K.jsxs)("div",{children:[(0,K.jsxs)("span",{children:["参考答案:(填空",n+1,"):"]}),(0,K.jsx)("div",{children:(0,K.jsx)(ne,{autoSize:!0,disabled:!0,value:(null==e?void 0:e.answer_text)||""})})]})}))}),(null==e?void 0:e.standard_answer)&&4===(null==e?void 0:e.question_type)&&(0,K.jsxs)("div",{children:[(0,K.jsx)("p",{className:"mt10 mb0",children:"参考答案:"}),(0,K.jsx)("div",{style:{border:"1px solid #eee",background:"#f5f5f5",borderRadius:4,padding:5},children:(0,K.jsx)(B.Z,{value:null==e||null===(m=e.standard_answer)||void 0===m?void 0:m[0]})})]}),(null==e?void 0:e.answer_text)&&6===(null==e?void 0:e.question_type)&&(0,K.jsxs)("div",{children:[(0,K.jsx)("p",{className:"mt10 mb0",children:"参考答案:"}),(0,K.jsx)("div",{style:{border:"1px solid #eee",background:"#f5f5f5",borderRadius:4,padding:5},children:(0,K.jsx)(B.Z,{value:null==e?void 0:e.answer_text})})]}),(null==e?void 0:e.question_type)<=4&&((null==e?void 0:e.standard_answer_show)||(null==e||null===(v=e.standard_answer)||void 0===v?void 0:v.length)>0)&&(0,K.jsxs)(y.Z,{style:{marginTop:14},children:[(0,K.jsx)("span",{className:"font16 ",children:"解析:"}),(0,K.jsx)(B.Z,{className:z.Z.renderHtml,value:(null==e?void 0:e.analysis)||"暂无解析"})]})]}),$e&&!Number.isNaN(parseFloat(null==e?void 0:e.user_score))&&(null==e?void 0:e.question_type)!==W.c.Shixun&&(0,K.jsxs)("span",{children:[(0,K.jsx)("span",{style:{color:"#0152d9"},children:"学生得分:"}),null==e?void 0:e.user_score,"分"]}),(null==e?void 0:e.answer_comments)&&Me&&(0,K.jsx)(U.Z,{newuserCommentVisible:Fe,list:null==e?void 0:e.answer_comments}),(0,K.jsx)(_.Z,{style:ce.current?{marginTop:30}:{}})]})},hn=function(e){var n=["零","一","二","三","四","五","六","七","八","九"],t=["","十","百","千","万"];e=parseInt(e);var r=function(e){for(var r=e.toString().split("").reverse(),i="",a=0;a<r.length;a++)i=(0==a&&0==r[a]||a>0&&0==r[a]&&0==r[a-1]?"":n[r[a]]+(0==r[a]?t[0]:t[a]))+i;return i},i=Math.floor(e/1e4),a=e%1e4;return a.toString().length<4&&(a="0"+a),i?r(i)+"万"+r(a):r(e)},pn=(0,x.useCallback)((function(){var e,n,t,r,a=(null==N||null===(e=N.exerciseExportHeadData)||void 0===e||null===(e=e.exercise_header)||void 0===e?void 0:e.export_page_num)||40,o=[],s=1,c=i()((null==xe||null===(t=xe.exercise_question_types)||void 0===t?void 0:t.entries())||[]);try{var d=function(){var e=h()(r.value,2),n=e[0],t=e[1];t.items.forEach((function(e,r){0===r?o.push(l()(l()({},t),{},{items:null,category:n+1,questionDetail:e,questionIndex:s})):o.push({questionDetail:e,questionIndex:s}),s++}))};for(c.s();!(r=c.n()).done;)d()}catch(e){c.e(e)}finally{c.f()}return null!=o&&o.length?null===(n=new Array(Math.ceil((null==o?void 0:o.length)/a)))||void 0===n||null===(n=n.fill([]))||void 0===n||null===(n=n.map((function(e,n){return o.slice(n*a,n*a+a)})))||void 0===n?void 0:n.map((function(e,n){return(0,K.jsxs)("div",{className:"pl60 pr30",style:{minHeight:0===n?1e3:"auto"},children:[0===n&&(0,K.jsxs)(K.Fragment,{children:[(0,K.jsx)(T.Z,{isExportBlank:ce.current}),(0,K.jsx)(_.Z,{className:z.Z.divider})]}),null==e?void 0:e.map((function(e,n){return t=e,r=e.questionIndex,t.category?(0,K.jsxs)("div",{children:[(0,K.jsxs)("div",{children:[(0,K.jsxs)("span",{className:"font16 c-light-primary",children:[hn(null==t?void 0:t.category),"、",t.name]}),(0,K.jsxs)("span",{className:"c-grey-999",children:["(共",t.count,"题,",7===(null==t?void 0:t.question_type)?"包含".concat(null==t?void 0:t.sub_count,"小题;"):"","共",t.score,"分)"]})]}),un(t.questionDetail,r)]}):un(t.questionDetail,r);var t,r}))]},n)})):null}),[xe,N,Ce]),fn=(0,x.useState)({num:1}),xn=h()(fn,2),mn=xn[0],vn=xn[1];return(0,K.jsxs)("section",{className:"edu-container",children:[(0,K.jsxs)("section",{className:"animated fadeIn",children:[(0,K.jsx)("aside",{className:"mt10",children:re&&(0,K.jsxs)(Z.Z,{separator:">",children:[(0,K.jsx)(Z.Z.Item,{children:(0,K.jsx)(m.Link,{to:"/classrooms/".concat(te.coursesId,"/exercise"),children:null==re||null===(n=re.course)||void 0===n?void 0:n.course_name})}),(0,K.jsx)(Z.Z.Item,{children:(0,K.jsx)(m.Link,{to:"/classrooms/".concat(te.coursesId,"/exercise"),children:"试卷列表"})}),(0,K.jsx)(Z.Z.Item,{children:(0,K.jsx)(m.Link,{to:"/classrooms/".concat(te.coursesId,"/exercise/").concat(null==xe||null===(r=xe.exercise)||void 0===r?void 0:r.id,"/detail"),children:"试卷详情"})}),(0,K.jsx)(Z.Z.Item,{children:(null==xe||null===(a=xe.exercise_answer_user)||void 0===a?void 0:a.user_name)||(null==xe||null===(s=xe.exercise)||void 0===s?void 0:s.exercise_name)})]})}),(0,K.jsx)("aside",{className:[z.Z.title,"mt20"].join(" "),children:(0,K.jsxs)(y.Z,{style:{width:"100%"},children:[(0,K.jsxs)(j.Z,{flex:"1",style:{lineHeight:"24px"},children:[(0,K.jsx)(m.Link,{to:"/classrooms/".concat(te.coursesId,"/exercise/").concat(null==xe||null===(c=xe.exercise)||void 0===c?void 0:c.id,"/detail"),children:(0,K.jsx)(I.Z,{className:"font16 c-black"})}),(0,H.vB)(null===(u=xe.exercise)||void 0===u?void 0:u.exercise_status),(0,K.jsx)("strong",{className:"font20 ml5",children:null==xe||null===(p=xe.exercise)||void 0===p?void 0:p.exercise_name})]}),(0,K.jsx)(j.Z,{children:(0,K.jsx)(k.Z,{menu:{items:[{label:(0,K.jsxs)(S.ZP,{type:"text",onClick:function(){qe(!0),tn(""),Qe(!0)},children:[(0,K.jsx)(q.Z,{}),"导出空白试卷+答案"]}),key:"1",show:!0},{label:(0,K.jsxs)(S.ZP,{type:"text",onClick:function(){tn(""),Qe(!0)},children:[(0,K.jsx)(q.Z,{}),"导出空白试卷"]}),key:"2",show:!0},{label:(0,K.jsxs)(S.ZP,{type:"text",onClick:function(){tn(""),Le(!1),We(!0)},children:[(0,K.jsx)(q.Z,{}),"导出所有学生试卷"]}),key:"3",show:(0,V.GJ)()}].filter((function(e){return e.show})).map((function(e){return{label:e.label,key:e.key}}))},children:(0,K.jsxs)(S.ZP,{className:z.Z.exportBtn,children:[(0,K.jsx)(A.Z,{}),"导出",(0,K.jsx)(P.Z,{})]})})}),(0,K.jsx)(j.Z,{className:"ml20",children:(0,K.jsx)(S.ZP,{icon:(0,K.jsx)($.Z,{}),className:z.Z.exportBtn,onClick:function(){Y({type:"exercise/setActionTabs",payload:{key:"exportSetting"}})},children:"导出设置"})}),(0,K.jsx)(j.Z,{})]})})]}),(0,K.jsxs)(g.Z,{title:"导出试卷选择",open:Ve,footer:(0,K.jsxs)("div",{children:[(0,K.jsx)(S.ZP,{type:"primary",onClick:function(){De(!0),ze(!0),""!=nn?("pdf"==nn?cn("all"):"word"==nn&&((null==_e?void 0:_e.length)>0?dn("all"):C.ZP.info("没有可导出的学生试卷")),We(!1)):C.ZP.info("请选择一种导出格式")},children:"是"}),(0,K.jsx)(S.ZP,{onClick:function(){We(!1)},children:"否"})]}),onCancel:function(){return We(!1)},children:["是否连同评阅教师、教师评语一起导出?",(0,K.jsx)("p",{style:{display:"flex",alignItems:"center"},children:(0,K.jsx)(w.Z,{style:{fontSize:14},onChange:function(e){Le(e.target.checked)},children:"只导出最新的评阅记录"})}),(0,K.jsx)("div",{style:{fontSize:16,margin:"15px 0"},children:"请选择需要导出的格式"}),(0,K.jsx)("div",{className:z.Z.export_type_modal,children:(0,K.jsxs)("div",{className:z.Z.export_type_modal_con,children:[(0,K.jsxs)("div",{className:z.Z.type_item,children:[(0,K.jsx)("div",{className:"".concat(z.Z.img_warp," ").concat("pdf"==nn?z.Z.img_warp_active:""),onClick:function(){return tn("pdf")},children:(0,K.jsx)("img",{src:t(45614),width:70,height:70})}),"pdf格式"]}),(0,K.jsxs)("div",{className:z.Z.type_item,children:[(0,K.jsx)("div",{className:"".concat(z.Z.img_warp," ").concat("word"==nn?z.Z.img_warp_active:""),onClick:function(){return tn("word")},children:(0,K.jsx)("img",{src:t(38347),width:70,height:70})}),"word格式"]})]})})]}),(0,K.jsxs)("div",{className:"".concat(z.Z.bg," pt30 mt20"),children:[(null==xe||null===(v=xe.exercise)||void 0===v?void 0:v.is_random)&&(0,K.jsx)(O.Z,{className:"".concat(z.Z.paginationWrapper),showTotal:function(e){return(0,K.jsxs)("span",{className:z.Z.totalText,style:{marginLeft:20},children:["共计",(0,K.jsx)("span",{className:z.Z.num,children:e}),"份试卷"]})},total:null==xe?void 0:xe.exercise_count,pageSize:1,current:mn.num,showSizeChanger:!1,onChange:function(){var e=d()(o()().mark((function e(n){var t;return o()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return vn({num:n}),e.next=3,Y({type:"exercise/editExercise",payload:{coursesId:te.coursesId,categoryId:te.exerciseId,num:n-1}});case 3:t=e.sent,me(t);case 5:case"end":return e.stop()}}),e)})));return function(n){return e.apply(this,arguments)}}(),showQuickJumper:!0,hideOnSinglePage:!1}),(0,K.jsx)("section",{id:"export-all",className:[z.Z.bg,"pt30","pb30","mt20","mb20","relative"].join(" "),ref:le,children:pn()})]}),(0,K.jsx)(g.Z,{width:450,title:"请选择需要导出的格式",open:Je,onCancel:function(){return Qe(!1)},onOk:d()(o()().mark((function e(){return o()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(""!=nn){e.next=5;break}return C.ZP.info("请选择一种导出格式"),e.abrupt("return");case 5:"pdf"==nn?cn(""):"word"==nn&&(0,J.YX)({coursesId:te.coursesId,categoryId:te.exerciseId,middle_export:1,export_type:Ie?1:0});case 6:Qe(!1);case 7:case"end":return e.stop()}}),e)}))),children:(0,K.jsx)("div",{className:z.Z.export_type_modal,children:(0,K.jsxs)("div",{className:z.Z.export_type_modal_con,children:[(0,K.jsxs)("div",{className:z.Z.type_item,children:[(0,K.jsx)("div",{className:"".concat(z.Z.img_warp," ").concat("pdf"==nn?z.Z.img_warp_active:""),onClick:function(){return tn("pdf")},children:(0,K.jsx)("img",{src:t(45614),width:70,height:70})}),"pdf格式"]}),(0,K.jsxs)("div",{className:z.Z.type_item,children:[(0,K.jsx)("div",{className:"".concat(z.Z.img_warp," ").concat("word"==nn?z.Z.img_warp_active:""),onClick:function(){return tn("word")},children:(0,K.jsx)("img",{src:t(38347),width:70,height:70})}),"word格式"]})]})})})]})}))},66104:function(e,n,t){"use strict";t.d(n,{Z:function(){return E}});var r=t(92310),i=t.n(r),a=t(89616),o=t(19155),s=t(59301),l=t(92343),c=t(36355),d=t(43501),u=t(91857);const h=e=>{let{children:n}=e;const{getPrefixCls:t}=s.useContext(c.E_),r=t("breadcrumb");return s.createElement("li",{className:`${r}-separator`,"aria-hidden":"true"},""===n?n:n||"/")};h.__ANT_BREADCRUMB_SEPARATOR=!0;var p=h,f=function(e,n){var t={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&n.indexOf(r)<0&&(t[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(r=Object.getOwnPropertySymbols(e);i<r.length;i++)n.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(t[r[i]]=e[r[i]])}return t};function x(e,n,t,r){if(null==t)return null;const{className:a,onClick:l}=n,c=f(n,["className","onClick"]),d=Object.assign(Object.assign({},(0,o.Z)(c,{data:!0,aria:!0})),{onClick:l});return void 0!==r?s.createElement("a",Object.assign({},d,{className:i()(`${e}-link`,a),href:r}),t):s.createElement("span",Object.assign({},d,{className:i()(`${e}-link`,a)}),t)}function m(e,n){return(t,r,i,a,o)=>{if(n)return n(t,r,i,a);const s=function(e,n){if(void 0===e.title||null===e.title)return null;const t=Object.keys(n).join("|");return"object"==typeof e.title?e.title:String(e.title).replace(new RegExp(`:(${t})`,"g"),((e,t)=>n[t]||e))}(t,r);return x(e,t,s,o)}}var v=function(e,n){var t={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&n.indexOf(r)<0&&(t[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(r=Object.getOwnPropertySymbols(e);i<r.length;i++)n.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(t[r[i]]=e[r[i]])}return t};const g=e=>{const{prefixCls:n,separator:t="/",children:r,menu:i,overlay:a,dropdownProps:o,href:l}=e;const c=(e=>{if(i||a){const t=Object.assign({},o);if(i){const e=i||{},{items:n}=e,r=v(e,["items"]);t.menu=Object.assign(Object.assign({},r),{items:null==n?void 0:n.map(((e,n)=>{var{key:t,title:r,label:i,path:a}=e,o=v(e,["key","title","label","path"]);let c=null!=i?i:r;return a&&(c=s.createElement("a",{href:`${l}${a}`},c)),Object.assign(Object.assign({},o),{key:null!=t?t:n,label:c})}))})}else a&&(t.overlay=a);return s.createElement(u.Z,Object.assign({placement:"bottom"},t),s.createElement("span",{className:`${n}-overlay-link`},e,s.createElement(d.Z,null)))}return e})(r);return null!=c?s.createElement(s.Fragment,null,s.createElement("li",null,c),t&&s.createElement(p,null,t)):null},y=e=>{const{prefixCls:n,children:t,href:r}=e,i=v(e,["prefixCls","children","href"]),{getPrefixCls:a}=s.useContext(c.E_),o=a("breadcrumb",n);return s.createElement(g,Object.assign({},i,{prefixCls:o}),x(o,i,t,r))};y.__ANT_BREADCRUMB_ITEM=!0;var j=y,b=t(17313),w=t(83116),_=t(37613);const Z=e=>{const{componentCls:n,iconCls:t}=e;return{[n]:Object.assign(Object.assign({},(0,b.Wf)(e)),{color:e.itemColor,fontSize:e.fontSize,[t]:{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,b.Qy)(e)),"li:last-child":{color:e.lastItemColor},[`${n}-separator`]:{marginInline:e.separatorMargin,color:e.separatorColor},[`${n}-link`]:{[`\n > ${t} + span,\n > ${t} + a\n `]:{marginInlineStart:e.marginXXS}},[`${n}-overlay-link`]:{borderRadius:e.borderRadiusSM,height:e.lineHeight*e.fontSize,display:"inline-block",padding:`0 ${e.paddingXXS}px`,marginInline:-e.marginXXS,[`> ${t}`]:{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 k=(0,w.Z)("Breadcrumb",(e=>{const n=(0,_.TS)(e,{});return[Z(n)]}),(e=>({itemColor:e.colorTextDescription,lastItemColor:e.colorText,iconFontSize:e.fontSize,linkColor:e.colorTextDescription,linkHoverColor:e.colorText,separatorColor:e.colorTextDescription,separatorMargin:e.marginXS}))),S=function(e,n){var t={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&n.indexOf(r)<0&&(t[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(r=Object.getOwnPropertySymbols(e);i<r.length;i++)n.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(t[r[i]]=e[r[i]])}return t};function C(e){const{breadcrumbName:n,children:t}=e,r=S(e,["breadcrumbName","children"]),i=Object.assign({title:n},r);return t&&(i.menu={items:t.map((e=>{var{breadcrumbName:n}=e,t=S(e,["breadcrumbName"]);return Object.assign(Object.assign({},t),{title:n})}))}),i}var O=function(e,n){var t={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&n.indexOf(r)<0&&(t[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(r=Object.getOwnPropertySymbols(e);i<r.length;i++)n.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(t[r[i]]=e[r[i]])}return t};const N=e=>{const{prefixCls:n,separator:t="/",style:r,className:d,rootClassName:u,routes:h,items:f,children:x,itemRender:v,params:y={}}=e,j=O(e,["prefixCls","separator","style","className","rootClassName","routes","items","children","itemRender","params"]),{getPrefixCls:b,direction:w,breadcrumb:_}=s.useContext(c.E_);let Z;const S=b("breadcrumb",n),[N,E]=k(S),I=function(e,n){return(0,s.useMemo)((()=>e||(n?n.map(C):null)),[e,n])}(f,h);const q=m(S,v);if(I&&I.length>0){const e=[],n=f||h;Z=I.map(((r,i)=>{const{path:a,key:l,type:c,menu:d,overlay:u,onClick:h,className:f,separator:x,dropdownProps:m}=r,v=((e,n)=>{if(void 0===n)return n;let t=(n||"").replace(/^\//,"");return Object.keys(e).forEach((n=>{t=t.replace(`:${n}`,e[n])})),t})(y,a);void 0!==v&&e.push(v);const j=null!=l?l:i;if("separator"===c)return s.createElement(p,{key:j},x);const b={},w=i===I.length-1;d?b.menu=d:u&&(b.overlay=u);let{href:_}=r;return e.length&&void 0!==v&&(_=`#/${e.join("/")}`),s.createElement(g,Object.assign({key:j},b,(0,o.Z)(r,{data:!0,aria:!0}),{className:f,dropdownProps:m,href:_,separator:w?"":t,onClick:h,prefixCls:S}),q(r,y,n,e,_))}))}else if(x){const e=(0,a.Z)(x).length;Z=(0,a.Z)(x).map(((n,r)=>{if(!n)return n;const i=r===e-1;return(0,l.Tm)(n,{separator:i?"":t,key:r})}))}const A=i()(S,null==_?void 0:_.className,{[`${S}-rtl`]:"rtl"===w},d,u,E),P=Object.assign(Object.assign({},null==_?void 0:_.style),r);return N(s.createElement("nav",Object.assign({className:A,style:P},j),s.createElement("ol",null,Z)))};N.Item=j,N.Separator=p;var E=N},28103:function(e,n,t){"use strict";t.d(n,{Z:function(){return p}});var r=t(92310),i=t.n(r),a=t(59301),o=t(36355),s=t(17313),l=t(83116),c=t(37613);const d=e=>{const{componentCls:n,sizePaddingEdgeHorizontal:t,colorSplit:r,lineWidth:i,textPaddingInline:a,orientationMargin:o,verticalMarginInline:l}=e;return{[n]:Object.assign(Object.assign({},(0,s.Wf)(e)),{borderBlockStart:`${i}px solid ${r}`,"&-vertical":{position:"relative",top:"-0.06em",display:"inline-block",height:"0.9em",marginInline:l,marginBlock:0,verticalAlign:"middle",borderTop:0,borderInlineStart:`${i}px solid ${r}`},"&-horizontal":{display:"flex",clear:"both",width:"100%",minWidth:"100%",margin:`${e.dividerHorizontalGutterMargin}px 0`},[`&-horizontal${n}-with-text`]:{display:"flex",alignItems:"center",margin:`${e.dividerHorizontalWithTextGutterMargin}px 0`,color:e.colorTextHeading,fontWeight:500,fontSize:e.fontSizeLG,whiteSpace:"nowrap",textAlign:"center",borderBlockStart:`0 ${r}`,"&::before, &::after":{position:"relative",width:"50%",borderBlockStart:`${i}px solid transparent`,borderBlockStartColor:"inherit",borderBlockEnd:0,transform:"translateY(50%)",content:"''"}},[`&-horizontal${n}-with-text-left`]:{"&::before":{width:100*o+"%"},"&::after":{width:100-100*o+"%"}},[`&-horizontal${n}-with-text-right`]:{"&::before":{width:100-100*o+"%"},"&::after":{width:100*o+"%"}},[`${n}-inner-text`]:{display:"inline-block",paddingBlock:0,paddingInline:a},"&-dashed":{background:"none",borderColor:r,borderStyle:"dashed",borderWidth:`${i}px 0 0`},[`&-horizontal${n}-with-text${n}-dashed`]:{"&::before, &::after":{borderStyle:"dashed none none"}},[`&-vertical${n}-dashed`]:{borderInlineStartWidth:i,borderInlineEnd:0,borderBlockStart:0,borderBlockEnd:0},[`&-plain${n}-with-text`]:{color:e.colorText,fontWeight:"normal",fontSize:e.fontSize},[`&-horizontal${n}-with-text-left${n}-no-default-orientation-margin-left`]:{"&::before":{width:0},"&::after":{width:"100%"},[`${n}-inner-text`]:{paddingInlineStart:t}},[`&-horizontal${n}-with-text-right${n}-no-default-orientation-margin-right`]:{"&::before":{width:"100%"},"&::after":{width:0},[`${n}-inner-text`]:{paddingInlineEnd:t}}})}};var u=(0,l.Z)("Divider",(e=>{const n=(0,c.TS)(e,{dividerHorizontalWithTextGutterMargin:e.margin,dividerHorizontalGutterMargin:e.marginLG,sizePaddingEdgeHorizontal:0});return[d(n)]}),(e=>({textPaddingInline:"1em",orientationMargin:.05,verticalMarginInline:e.marginXS}))),h=function(e,n){var t={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&n.indexOf(r)<0&&(t[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(r=Object.getOwnPropertySymbols(e);i<r.length;i++)n.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(t[r[i]]=e[r[i]])}return t};var p=e=>{const{getPrefixCls:n,direction:t,divider:r}=a.useContext(o.E_),{prefixCls:s,type:l="horizontal",orientation:c="center",orientationMargin:d,className:p,rootClassName:f,children:x,dashed:m,plain:v,style:g}=e,y=h(e,["prefixCls","type","orientation","orientationMargin","className","rootClassName","children","dashed","plain","style"]),j=n("divider",s),[b,w]=u(j),_=c.length>0?`-${c}`:c,Z=!!x,k="left"===c&&null!=d,S="right"===c&&null!=d,C=i()(j,null==r?void 0:r.className,w,`${j}-${l}`,{[`${j}-with-text`]:Z,[`${j}-with-text${_}`]:Z,[`${j}-dashed`]:!!m,[`${j}-plain`]:!!v,[`${j}-rtl`]:"rtl"===t,[`${j}-no-default-orientation-margin-left`]:k,[`${j}-no-default-orientation-margin-right`]:S},p,f),O=a.useMemo((()=>"number"==typeof d?d:/^\d+$/.test(d)?Number(d):d),[d]),N=Object.assign(Object.assign({},k&&{marginLeft:O}),S&&{marginRight:O});return b(a.createElement("div",Object.assign({className:C,style:Object.assign(Object.assign({},null==r?void 0:r.style),g)},y,{role:"separator"}),x&&"vertical"!==l&&a.createElement("span",{className:`${j}-inner-text`,style:N},x)))}},24334:function(e,n,t){var r,i;i="undefined"!=typeof self?self:"undefined"!=typeof window?window:void 0!==t.g?t.g:this,e.exports=function(t){"use strict";var i,a=(t=t||{}).Base64,o="2.6.4",s="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",l=function(e){for(var n={},t=0,r=e.length;t<r;t++)n[e.charAt(t)]=t;return n}(s),c=String.fromCharCode,d=function(e){if(e.length<2)return(n=e.charCodeAt(0))<128?e:n<2048?c(192|n>>>6)+c(128|63&n):c(224|n>>>12&15)+c(128|n>>>6&63)+c(128|63&n);var n=65536+1024*(e.charCodeAt(0)-55296)+(e.charCodeAt(1)-56320);return c(240|n>>>18&7)+c(128|n>>>12&63)+c(128|n>>>6&63)+c(128|63&n)},u=/[\uD800-\uDBFF][\uDC00-\uDFFFF]|[^\x00-\x7F]/g,h=function(e){return e.replace(u,d)},p=function(e){var n=[0,2,1][e.length%3],t=e.charCodeAt(0)<<16|(e.length>1?e.charCodeAt(1):0)<<8|(e.length>2?e.charCodeAt(2):0);return[s.charAt(t>>>18),s.charAt(t>>>12&63),n>=2?"=":s.charAt(t>>>6&63),n>=1?"=":s.charAt(63&t)].join("")},f=t.btoa&&"function"==typeof t.btoa?function(e){return t.btoa(e)}:function(e){if(e.match(/[^\x00-\xFF]/))throw new RangeError("The string contains invalid characters.");return e.replace(/[\s\S]{1,3}/g,p)},x=function(e){return f(h(String(e)))},m=function(e){return e.replace(/[+\/]/g,(function(e){return"+"==e?"-":"_"})).replace(/=/g,"")},v=function(e,n){return n?m(x(e)):x(e)},g=function(e){return v(e,!0)};t.Uint8Array&&(i=function(e,n){for(var t="",r=0,i=e.length;r<i;r+=3){var a=e[r],o=e[r+1],l=e[r+2],c=a<<16|o<<8|l;t+=s.charAt(c>>>18)+s.charAt(c>>>12&63)+(void 0!==o?s.charAt(c>>>6&63):"=")+(void 0!==l?s.charAt(63&c):"=")}return n?m(t):t});var y,j=/[\xC0-\xDF][\x80-\xBF]|[\xE0-\xEF][\x80-\xBF]{2}|[\xF0-\xF7][\x80-\xBF]{3}/g,b=function(e){switch(e.length){case 4:var n=((7&e.charCodeAt(0))<<18|(63&e.charCodeAt(1))<<12|(63&e.charCodeAt(2))<<6|63&e.charCodeAt(3))-65536;return c(55296+(n>>>10))+c(56320+(1023&n));case 3:return c((15&e.charCodeAt(0))<<12|(63&e.charCodeAt(1))<<6|63&e.charCodeAt(2));default:return c((31&e.charCodeAt(0))<<6|63&e.charCodeAt(1))}},w=function(e){return e.replace(j,b)},_=function(e){var n=e.length,t=n%4,r=(n>0?l[e.charAt(0)]<<18:0)|(n>1?l[e.charAt(1)]<<12:0)|(n>2?l[e.charAt(2)]<<6:0)|(n>3?l[e.charAt(3)]:0),i=[c(r>>>16),c(r>>>8&255),c(255&r)];return i.length-=[0,0,2,1][t],i.join("")},Z=t.atob&&"function"==typeof t.atob?function(e){return t.atob(e)}:function(e){return e.replace(/\S{1,4}/g,_)},k=function(e){return Z(String(e).replace(/[^A-Za-z0-9\+\/]/g,""))},S=function(e){return w(Z(e))},C=function(e){return String(e).replace(/[-_]/g,(function(e){return"-"==e?"+":"/"})).replace(/[^A-Za-z0-9\+\/]/g,"")},O=function(e){return S(C(e))};t.Uint8Array&&(y=function(e){return Uint8Array.from(k(C(e)),(function(e){return e.charCodeAt(0)}))});var N=function(){var e=t.Base64;return t.Base64=a,e};if(t.Base64={VERSION:o,atob:k,btoa:f,fromBase64:O,toBase64:v,utob:h,encode:v,encodeURI:g,btou:w,decode:O,noConflict:N,fromUint8Array:i,toUint8Array:y},"function"==typeof Object.defineProperty){var E=function(e){return{value:e,enumerable:!1,writable:!0,configurable:!0}};t.Base64.extendString=function(){Object.defineProperty(String.prototype,"fromBase64",E((function(){return O(this)}))),Object.defineProperty(String.prototype,"toBase64",E((function(e){return v(this,e)}))),Object.defineProperty(String.prototype,"toBase64URI",E((function(){return v(this,!0)})))}}return t.Meteor&&(Base64=t.Base64),e.exports?e.exports.Base64=t.Base64:void 0===(r=function(){return t.Base64}.apply(n,[]))||(e.exports=r),{Base64:t.Base64}}(i)}}]); |