1 |
- import{d as k,x as b,r as _,y as v,a as e,V as x,A as l,F as I,C as u,q as C,S as B,R,a5 as E,h as d,D as z,E as L}from"./index-d1417ca9.js";import{M as A}from"./index-d6482305.js";import{g as c,s}from"./index-644612cc.js";import{I as m}from"./index-5df8d95f.js";const P="_woringBook_k99iz_1",H="_woringHeader_k99iz_6",N="_leftArrow_k99iz_11",D="_title_k99iz_14",M="_woringSecgtion_k99iz_37",O="_woringImg_k99iz_44",n={woringBook:P,woringHeader:H,leftArrow:N,title:D,woringSecgtion:M,woringImg:O},T=""+new URL("ai-exam-ac155650.png",import.meta.url).href,U=""+new URL("woring-practice-5f4735ad.png",import.meta.url).href,$=""+new URL("woring-stat-fe2f9a06.png",import.meta.url).href,F=k({name:"woring",emits:["close"],setup(i,{emit:f}){const o=b({box:{},show:!1,steps:[{ele:"",eleRect:{},img:c("woring1.png"),handStyle:{top:"2.7rem",left:"4.5rem"},imgStyle:{top:"3.3rem",left:"2.1rem"},btnsStyle:{top:"6.2rem",left:"3.5rem"}},{ele:"",eleRect:{},img:c("woring2.png"),handStyle:{top:"2.7rem",left:"4.5rem"},imgStyle:{top:"3.3rem",left:"2.1rem"},btnsStyle:{top:"6.2rem",left:"3.5rem"}},{ele:"",img:c("woring3.png"),handStyle:{top:"-1.43rem",left:"4.5rem",transform:"rotate(180deg)"},imgStyle:{top:"-5.4rem",left:"2.1rem"},btnsStyle:{top:"-2.4rem",left:"2.5rem"}}],step:0}),r=_(!1),p=()=>{const t=document.getElementById(`woring-${o.step}`);if(t){const a=t.getBoundingClientRect();o.box={left:a.x+"px",top:a.y+"px",width:a.width+"px",height:a.height+"px"}}};v(()=>{setTimeout(()=>{const t=localStorage.getItem("guideInfo");t&&JSON.parse(t).woring?r.value=!1:r.value=!0,p()},300)});const w=()=>{if(o.step>=3){g();return}o.step=o.step+1,p()},g=()=>{let t=JSON.parse(localStorage.getItem("guideInfo")||"{}");t?t.woring=!0:t={woring:!0},localStorage.setItem("guideInfo",JSON.stringify(t)),r.value=!1};return()=>e(x,{teleport:"body",overlay:!1,closeOnClickOverlay:!1,class:["popup-custom",s.guidePopup],show:r.value,"onUpdate:show":t=>r.value=t},{default:()=>[e("div",{class:s.content,onClick:()=>w()},[e("div",{class:[s.backBtn,s.right],onClick:t=>{t.stopPropagation(),g()}},[l("跳过")]),e("div",{class:s.box,style:o.box,id:`modeType-${o.step}`},[o.steps.map((t,a)=>{var y,h;return e("div",{onClick:S=>S.stopPropagation(),class:s.item,style:{display:a===o.step?"":"none",left:`${(y=t.eleRect)==null?void 0:y.left}px`,top:`${(h=t.eleRect)==null?void 0:h.top}px`}},[e("img",{class:s.img,style:t.imgStyle,src:t.img},null),e("img",{class:s.iconHead,style:t.handStyle,src:c("indexDot.png")},null),e("div",{class:s.btns,style:t.btnsStyle},[o.step+1==o.steps.length?e(I,null,[e(u,{class:s.btn,round:!0,color:"transparent",style:{"border-color":"#fff"},type:"primary",onClick:()=>{o.step=0,p()}},{default:()=>[l("再看一遍")]}),e(u,{class:[s.btn,s.endBtn],round:!0,type:"primary",onClick:()=>g()},{default:()=>[l("完成")]})]):e(u,{class:s.btn,round:!0,type:"primary",onClick:()=>w()},{default:()=>[l("下一步 ("),o.step+1,l("/"),o.steps.length,l(")")]})])])})])])]})}}),G=k({name:"wroing-book",setup(){const i=C(),f=async()=>{try{const{data:o}=await z.post("/edu-app/studentUnitExamination/errorEdition",{hideLoading:!1,data:{page:1,rows:50}});(o||{}).total>0?i.push({path:"/error-question-mode"}):setTimeout(()=>{L("暂无错题")},100)}catch(o){}};return()=>e("div",{class:n.woringBook},[e(A,{position:"top"},{default:()=>[e(B,{border:!1,background:"transparent"},{content:()=>e("div",{class:n.woringHeader},[e("i",{onClick:()=>{R().isApp?E({api:"goBack"}):i.back()},class:["van-badge__wrapper van-icon van-icon-arrow-left van-nav-bar__arrow",n.leftArrow]},null),e("span",{class:n.title},[e("i",null,null)])])})]}),e("div",{class:n.woringSecgtion},[e(m,d({id:"woring-0"},{lazyLoad:!0,src:$,class:n.woringImg,onClick:()=>i.push("wroing-stat")}),null),e(m,d({id:"woring-1"},{lazyLoad:!0,src:U,class:n.woringImg,onClick:f}),null),e(m,d({id:"woring-2"},{lazyLoad:!0,src:T,class:n.woringImg,onClick:()=>i.push("ai-exam")}),null)]),e(F,null,null)])}});export{G as default};
|