mirror of
https://github.com/silenty4ng/k5web
synced 2024-11-14 14:33:23 +00:00
2 lines
6.4 KiB
JavaScript
2 lines
6.4 KiB
JavaScript
import{d as N,r as W,bI as Z,C as j,aE as q,aH as a,aI as n,aM as o,aN as _,u as m,a$ as X,b0 as Y,G as e,bw as tt,bJ as ot,bG as nt,b8 as at,bi as et,bK as ut,bm as rt,bn as ct,D as it}from"./arco.c29bba08.js";import{v as st,s as lt,_ as G}from"./index.1c489121.js";/* empty css *//* empty css *//* empty css *//* empty css *//* empty css *//* empty css */import{e as _t,a as i,b as s}from"./serial.c6b76da8.js";import{L as pt}from"./index.28526de4.js";import"./chart.34708d29.js";import"./vue.437ba699.js";const dt=""+new URL("../gy.png",import.meta.url).href,mt=""+new URL("../jjgg.jpg",import.meta.url).href,l=h=>(rt("data-v-a221d468"),h=h(),ct(),h),ht=l(()=>e("br",null,null,-1)),ft=l(()=>e("br",null,null,-1)),gt=l(()=>e("br",null,null,-1)),wt=l(()=>e("br",null,null,-1)),Ft=l(()=>e("br",null,null,-1)),bt=l(()=>e("br",null,null,-1)),kt=l(()=>e("img",{class:"tencent",style:{"margin-bottom":"10px"},width:"200px",src:dt},null,-1)),yt=l(()=>e("div",{style:{border:"1px dashed",display:"inline-block"}},[e("img",{style:{margin:"20px"},class:"tencent",height:"200px",src:mt})],-1)),Bt=l(()=>e("br",null,null,-1)),vt=l(()=>e("br",null,null,-1)),Et=N({__name:"banner",setup(h){const{t:c}=st.exports.useI18n(),t=lt(),B=W({eepromSize:c("workplace.clickCheck")}),U=async()=>{var f,F,b,k,y,d,p,g,w,A,C,P,M,D,x,$,I,z,V,T,L;let r=c("workplace.unk");const S=[Math.round(Math.random()*256),Math.round(Math.random()*256),Math.round(Math.random()*256),Math.round(Math.random()*256),Math.round(Math.random()*256),Math.round(Math.random()*256),Math.round(Math.random()*256),Math.round(Math.random()*256)];await _t(t.connectPort);const u=new Uint8Array(S);if(((f=t.configuration)==null?void 0:f.uart)=="official"){const v=await i(t.connectPort,0,8,(F=t.configuration)==null?void 0:F.uart);await s(t.connectPort,0,u,8,(b=t.configuration)==null?void 0:b.uart);const E=await i(t.connectPort,0,8,(k=t.configuration)==null?void 0:k.uart);u.toString()==E.toString()&&(r=c("global.8kb")),await s(t.connectPort,0,v,8,(y=t.configuration)==null?void 0:y.uart)}else{const v=await i(t.connectPort,0,8,(d=t.configuration)==null?void 0:d.uart);await s(t.connectPort,0,u,8,(p=t.configuration)==null?void 0:p.uart);const E=await i(t.connectPort,0,8,(g=t.configuration)==null?void 0:g.uart);u.toString()==E.toString()&&(r=c("global.8kb")),await s(t.connectPort,0,v,8,(w=t.configuration)==null?void 0:w.uart);const K=await i(t.connectPort,131064,8,(A=t.configuration)==null?void 0:A.uart);await s(t.connectPort,131064,u,8,(C=t.configuration)==null?void 0:C.uart);const O=await i(t.connectPort,131064,8,(P=t.configuration)==null?void 0:P.uart);u.toString()==O.toString()&&(r=c("global.128kb")),await s(t.connectPort,131064,K,8,(M=t.configuration)==null?void 0:M.uart);const Q=await i(t.connectPort,262136,8,(D=t.configuration)==null?void 0:D.uart);await s(t.connectPort,262136,u,8,(x=t.configuration)==null?void 0:x.uart);const R=await i(t.connectPort,262136,8,($=t.configuration)==null?void 0:$.uart);u.toString()==R.toString()&&(r=c("global.256kb")),await s(t.connectPort,262136,Q,8,(I=t.configuration)==null?void 0:I.uart);const H=await i(t.connectPort,524280,8,(z=t.configuration)==null?void 0:z.uart);await s(t.connectPort,524280,u,8,(V=t.configuration)==null?void 0:V.uart);const J=await i(t.connectPort,524280,8,(T=t.configuration)==null?void 0:T.uart);u.toString()==J.toString()&&(r=c("global.512kb")),await s(t.connectPort,524280,H,8,(L=t.configuration)==null?void 0:L.uart)}B.eepromSize=r};return(r,S)=>{const u=tt,f=ot,F=nt,b=at,k=Z,y=et,d=pt,p=ut;return j(),q(f,{class:"banner"},{default:a(()=>[n(f,null,{default:a(()=>[n(u,{heading:5,style:{"margin-top":"0"}},{default:a(()=>[o(_(m(t).connectState?r.$t("workplace.welcomeSuc"):r.$t("workplace.welcome")),1)]),_:1})]),_:1}),n(F,{class:"panel-border"}),n(y,null,{default:a(()=>[X(n(k,{style:{marginTop:"2em",marginBottom:"2em"},title:r.$t("workplace.info")},{default:a(()=>{var g,w;return[o(_(r.$t("workplace.current"))+_(m(t).firmwareVersion)+" ",1),ht,o(" "+_(r.$t("workplace.writeconfig"))+_((g=m(t).configuration)==null?void 0:g.name)+" ",1),ft,o(" "+_(r.$t("workplace.eepromSize"))+_(B.eepromSize)+" "+_(B.eepromSize!=m(c)("workplace.clickCheck")&&((w=m(t).configuration)==null?void 0:w.uart)=="official"?m(c)("workplace.clickNotice"):"")+" ",1),n(b,{size:"mini",type:"primary",onClick:U},{default:a(()=>[o(_(r.$t("workplace.checkIt")),1)]),_:1})]}),_:1},8,["title"]),[[Y,m(t).connectState]])]),_:1}),e("div",null,[n(u,{heading:5},{default:a(()=>[o("\u8BF4\u660E\uFF1A")]),_:1}),n(p,null,{default:a(()=>[o("\u25C6 \u4F7F\u7528\u5E94\u7B2C\u4E00\u65F6\u95F4"),n(d,{theme:"primary",href:"/#/tool/backup"},{default:a(()=>[o("\u5907\u4EFD")]),_:1}),o("\u914D\u7F6E\u53CA\u6821\u51C6\u6570\u636E\u3002")]),_:1}),gt,n(p,null,{default:a(()=>[o("\u25C6 \u9664\u201C\u56FA\u4EF6\u5347\u7EA7\u201D\u529F\u80FD\u624B\u53F0\u5E94\u5904\u4E8E\u5237\u673A\u6A21\u5F0F\u70B9\u51FB\u66F4\u65B0\u6309\u94AE\u9009\u62E9\u8BBE\u5907\u66F4\u65B0\uFF0C\u5176\u4F59\u529F\u80FD\u624B\u53F0\u5747\u9700\u8981\u5728\u6B63\u5E38\u6A21\u5F0F\u8FDE\u63A5\u3002")]),_:1}),wt,n(p,null,{default:a(()=>[o("\u25C6 \u841D\u535C\uFF08LOSEHU\uFF09\u56FA\u4EF6\u76F8\u5173\u95EE\u9898\u8BF7\u79FB\u6B65\uFF1A"),n(d,{theme:"primary",href:"https://github.com/losehu/uv-k5-firmware-custom",target:"_blank"},{default:a(()=>[o("https://github.com/losehu/uv-k5-firmware-custom")]),_:1}),o(" \u3002")]),_:1}),Ft,n(p,null,{default:a(()=>[o("\u25C6 K5Web \u4F7F\u7528\u89C6\u9891\u6559\u7A0B\uFF08BG7QJV\uFF09\uFF1A"),n(d,{theme:"primary",href:"https://www.douyin.com/video/7378314511419313458",target:"_blank"},{default:a(()=>[o("https://www.douyin.com/video/7378314511419313458")]),_:1}),o(" \u3002")]),_:1}),bt,n(p,null,{default:a(()=>[o("\u25C6 K5Web \u4F7F\u7528\u89C6\u9891\u6559\u7A0B\uFF08BG3ODZ\uFF09\uFF1A"),n(d,{theme:"primary",href:"https://www.bilibili.com/video/BV1Q4421D75x",target:"_blank"},{default:a(()=>[o("https://www.bilibili.com/video/BV1Q4421D75x")]),_:1}),o(" \u3002")]),_:1})]),e("div",null,[n(u,{heading:5},{default:a(()=>[o("\u5E0C\u671B\u5DE5\u7A0B1+1\u52A9\u5B66\u884C\u52A8\uFF1A")]),_:1}),kt]),e("div",null,[n(u,{heading:5},{default:a(()=>[o("\u5E7F\u544A\u533A\uFF1A")]),_:1}),yt]),Bt,vt]),_:1})}}});const St=G(Et,[["__scopeId","data-v-a221d468"]]),At={class:"container"},Ct={class:"left-side"},Pt={class:"panel"},Mt={name:"Dashboard"},Dt=N({...Mt,setup(h){return(c,t)=>(j(),it("div",At,[e("div",Ct,[e("div",Pt,[n(St)])])]))}});const Ot=G(Dt,[["__scopeId","data-v-8f743d99"]]);export{Ot as default};
|