1 |
- !function(){function e(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function t(t){for(var r=1;r<arguments.length;r++){var o=null!=arguments[r]?arguments[r]:{};r%2?e(Object(o),!0).forEach((function(e){n(t,e,o[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(o)):e(Object(o)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(o,e))}))}return t}function n(e,t,n){return(t=function(e){var t=function(e,t){if("object"!=typeof e||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!=typeof r)return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function r(e,t,n,r,o,l,i){try{var a=e[l](i),s=a.value}catch(c){return void n(c)}a.done?t(s):Promise.resolve(s).then(r,o)}function o(e){return function(){var t=this,n=arguments;return new Promise((function(o,l){var i=e.apply(t,n);function a(e){r(i,o,l,a,s,"next",e)}function s(e){r(i,o,l,a,s,"throw",e)}a(void 0)}))}}System.register(["./index-legacy-e6be1dcb.js","./index-legacy-3fae0ac6.js","./index.module-legacy-a6053494.js","./index-legacy-cdd7affc.js","./api-legacy-b6116bbf.js","./index-legacy-96b15b0b.js","./index-legacy-d3534fc9.js","./index-legacy-72ad1f03.js"],(function(e,n){"use strict";var r,l,i,a,s,c,u,d,p,g,y,m,f,v,b,w,h,k,S,x,j,C,O,P,I,D,T,E,N;return{setters:[e=>{r=e.d,l=e.x,i=e.r,a=e.y,s=e.Q,c=e.a,u=e.R,d=e.A,p=e.F,g=e.C,y=e.q,m=e.P,f=e.V,v=e.h,b=e.a2,w=e.a3,h=e.D,k=e.N},e=>{S=e.M},e=>{x=e.s},e=>{j=e.u,C=e.a},e=>{O=e.g,P=e.s,I=e.a,D=e.b},e=>{T=e.C,E=e.a},e=>{N=e.I},null],execute:function(){const R=""+new URL("library-1-96754f77.png",n.meta.url).href,q=""+new URL("library-2-18c7f885.png",n.meta.url).href,L=""+new URL("library-3-784f5dd5.png",n.meta.url).href,U=r({name:"knowledge-guide",emits:["close"],setup(e,{emit:n}){const r=l({box:{},show:!1,steps:[{ele:"",eleRect:{},img:O("knowledge1.png"),handStyle:{top:"1.3rem",left:"1.5rem"},imgStyle:{width:"5.46rem",height:"2.30rem",top:"1.9rem"},btnsStyle:{top:"4.5rem",left:"1rem"},boxStyle:{transform:"scale(1.2)!important"}},{ele:"",eleRect:{},img:O("knowledge2.png"),handStyle:{top:"1.3rem",left:"1.5rem"},imgStyle:{top:"1.9rem",left:"-1.5rem"},btnsStyle:{top:"4.5rem"},boxStyle:{transform:"scale(1.2)!important"}},{ele:"",img:O("knowledge3.png"),handStyle:{top:"4.1rem",left:"3.6rem"},imgStyle:{top:"4.8rem",left:"1.2rem",width:"7.2rem",height:"3.45rem"},btnsStyle:{top:"8.8rem",left:"2.3rem",transform:"scale(1.2)"},boxStyle:{transform:"scale(1)"}}],step:0}),y=i(!1),m=i({}),f=function(){var e=o((function*(){try{const t=yield I({guideTag:"guideInfo"});var e;if(t.data)m.value=JSON.parse(null===(e=t.data)||void 0===e?void 0:e.guideValue)||null;else m.value={};m.value&&m.value.knowledge?y.value=!1:y.value=!0}catch(t){console.log(t)}}));return function(){return e.apply(this,arguments)}}(),v=()=>{const e=document.getElementById(`knowledge-${r.step}`);if(console.log(e,"ele"),e){const t=e.getBoundingClientRect();r.box={left:t.x+"px",top:t.y+"px",width:t.width+"px",height:t.height+"px"}}else w()};a((()=>{f(),v(),window.addEventListener("resize",b)}));const b=()=>{v()};s((()=>{window.removeEventListener("resize",b)}));const w=()=>{console.log(r.step,""),r.step>=2?h():(r.step=r.step+1,v())},h=function(){var e=o((function*(){m.value?m.value.knowledge=!0:m.value={knowledge:!0};try{yield D({guideTag:"guideInfo",guideValue:JSON.stringify(m.value)})}catch(e){console.log(e)}y.value=!1}));return function(){return e.apply(this,arguments)}}();return()=>c(u,{teleport:"body",overlay:!1,closeOnClickOverlay:!1,class:["popup-custom",P.guidePopup],show:y.value,"onUpdate:show":e=>y.value=e},{default:()=>[c("div",{class:P.content,onClick:()=>w()},[r.step!=r.steps.length-1&&c("div",{class:[P.backBtn,P.right],onClick:e=>{e.stopPropagation(),h()}},[d("跳过")]),c("div",{class:[P.box,P.noscalc],style:t(t({},r.box),r.steps[r.step].boxStyle),id:`modeType-${r.step}`},[r.steps.map(((e,t)=>{var n,o;return c("div",{onClick:e=>e.stopPropagation(),class:P.item,style:{display:t===r.step?"":"none",left:`${null===(n=e.eleRect)||void 0===n?void 0:n.left}px`,top:`${null===(o=e.eleRect)||void 0===o?void 0:o.top}px`}},[c("img",{class:P.img,style:e.imgStyle,src:e.img},null),c("img",{class:P.iconHead,style:e.handStyle,src:O("indexDot.png")},null),c("div",{class:P.btns,style:e.btnsStyle},[r.step+1==r.steps.length?c(p,null,[c(g,{class:P.btn,round:!0,color:"transparent",style:{"border-color":"#fff"},type:"primary",onClick:()=>{r.step=0,v()}},{default:()=>[d("再看一遍")]}),c(g,{class:[P.btn,P.endBtn],round:!0,type:"primary",onClick:()=>h()},{default:()=>[d("完成")]})]):c(g,{class:P.btn,round:!0,type:"primary",onClick:()=>w()},{default:()=>[d("下一步 ("),r.step+1,d("/"),r.steps.length,d(")")]})])])}))])])]})}});e("default",r({name:"knowledge-ligrary",setup(){const e=y(),t=m(),n=i(),r=l({cid:t.query.cid,list:[],activeNames:sessionStorage.getItem("knowledge-ligrary-key")?Number(sessionStorage.getItem("knowledge-ligrary-key")):0,background:"transparent",color:"#fff"}),s=function(){var e=o((function*(){try{const{data:e}=yield h.post("/edu-app/lessonCourseware/queryStudentLessonDetail",{requestType:"form",data:{lessonCoursewareId:r.cid}});r.list=e,n.value=!0}catch(e){}}));return function(){return e.apply(this,arguments)}}(),u=e=>e%3==1?R:e%3==2?q:e%3==0?L:void 0,p=function(){var t=o((function*(t){try{const{data:n}=yield h.get("/edu-app/studentUnitExamination/checkKnowledgePointIds",{params:{lessonCoursewareId:r.cid}});if(!n)return void setTimeout((()=>{k("暂无题目")}),100);"TEST"===t?e.push({path:"/examination-mode",query:{lessonCoursewareId:r.cid}}):e.push({path:"/practice-mode",query:{lessonCoursewareId:r.cid}})}catch(n){}}));return function(e){return t.apply(this,arguments)}}();return a((()=>{j(document,"scroll",(()=>{const{y:e}=C();e.value>52?(r.background="#fff",r.color="#323333"):(r.background="transparent",r.color="#fff")})),s()})),()=>{let t;return c("div",{class:x.knowledgeLibrary},[c(S,{position:"top"},{default:()=>[c(f,{border:!1,background:r.background,color:r.color},{right:()=>c("div",{class:[x.wroingBtn],onClick:()=>e.push("/wroing-book")},[c("i",{class:x.iconWroing},null),d("错题本")])})]}),c("div",{class:x.btnGroup},[c("div",{id:"knowledge-0",class:x.btnPractice,onClick:()=>p("PRACTICE")},null),c("div",{id:"knowledge-1",class:x.btnTest,onClick:()=>p("TEST")},null)]),c("div",{class:[x.containerSection,x.librarySection]},[c(T,{modelValue:r.activeNames,"onUpdate:modelValue":e=>r.activeNames=e,accordion:!0,border:!1,onChange:e=>{sessionStorage.setItem("knowledge-ligrary-key",e)}},(o=t=r.list.map(((t,n)=>c(E,{title:t.lessonCoursewareDetailName,name:n,value:r.activeNames===n?"收起":"展开",border:!1},{default:()=>[t.knowledgeDetails&&t.knowledgeDetails.map(((t,n)=>c("div",{class:x.unitItem,onClick:()=>e.push({path:"/unit-detail",query:{detailId:t.lessonCoursewareKnowledgeDetailId}})},[c(N,v({id:0==n?"knowledge-2":""},{class:x.unitImg,lazyLoad:!0,src:u(n)}),null),c("p",{class:x.name},[c("span",null,[t.name])])]))),t.knowledgeDetails&&t.knowledgeDetails.length<=0&&c(b,{description:"暂无章节"},null)]}))),"function"==typeof o||"[object Object]"===Object.prototype.toString.call(o)&&!w(o)?t:{default:()=>[t]}))]),n.value&&c(U,null,null)]);var o}}}))}}}))}();
|