import{A as e,D as t,M as n,O as r,S as i,T as a,_ as o,b as s,m as c,o as l,w as u,x as d,y as f}from"./index-jy40eMQa.js";import{t as p}from"./admin-CqpMrZ_s.js";var m={class:`dashboard`},h={class:`stats-grid`},g={class:`stat-card`},_={class:`stat-icon users`},v={class:`stat-content`},y={class:`stat-value`},b={class:`stat-card`},x={class:`stat-icon active`},S={class:`stat-content`},C={class:`stat-value`},w={class:`stat-card`},T={class:`stat-icon bookmarks`},E={class:`stat-content`},D={class:`stat-value`},O={class:`stat-card`},k={class:`stat-icon devices`},A={class:`stat-content`},j={class:`stat-value`},M={class:`stats-row`},N={class:`stat-card small`},P={class:`stat-value`},F={class:`stat-card small`},I={class:`stat-value`},L={class:`stat-card small`},R={class:`stat-value`},z={class:`stat-card small`},B={class:`stat-value warning`},V=l(s({__name:`DashboardView`,setup(s){let l=e(!0),V=e(null);return d(async()=>{try{let e=await p.getStatistics();e.success&&e.data&&(V.value=e.data)}finally{l.value=!1}}),(e,s)=>{let d=u(`User`),p=u(`el-icon`),H=u(`UserFilled`),U=u(`Collection`),W=u(`Monitor`),G=a(`loading`);return i(),o(`div`,m,[s[8]||=c(`h2`,{class:`page-title`},`仪表盘`,-1),r((i(),o(`div`,h,[c(`div`,g,[c(`div`,_,[f(p,{size:`28`},{default:t(()=>[f(d)]),_:1})]),c(`div`,v,[c(`div`,y,n(V.value?.totalUsers||0),1),s[0]||=c(`div`,{class:`stat-label`},`总用户数`,-1)])]),c(`div`,b,[c(`div`,x,[f(p,{size:`28`},{default:t(()=>[f(H)]),_:1})]),c(`div`,S,[c(`div`,C,n(V.value?.activeUsersLast7Days||0),1),s[1]||=c(`div`,{class:`stat-label`},`7日活跃用户`,-1)])]),c(`div`,w,[c(`div`,T,[f(p,{size:`28`},{default:t(()=>[f(U)]),_:1})]),c(`div`,E,[c(`div`,D,n(V.value?.totalBookmarks||0),1),s[2]||=c(`div`,{class:`stat-label`},`总书签数`,-1)])]),c(`div`,O,[c(`div`,k,[f(p,{size:`28`},{default:t(()=>[f(W)]),_:1})]),c(`div`,A,[c(`div`,j,n(V.value?.totalDevices||0),1),s[3]||=c(`div`,{class:`stat-label`},`总设备数`,-1)])])])),[[G,l.value]]),c(`div`,M,[c(`div`,N,[s[4]||=c(`div`,{class:`stat-label`},`今日新增用户`,-1),c(`div`,P,n(V.value?.newUsersToday||0),1)]),c(`div`,F,[s[5]||=c(`div`,{class:`stat-label`},`本周新增用户`,-1),c(`div`,I,n(V.value?.newUsersThisWeek||0),1)]),c(`div`,L,[s[6]||=c(`div`,{class:`stat-label`},`本月新增用户`,-1),c(`div`,R,n(V.value?.newUsersThisMonth||0),1)]),c(`div`,z,[s[7]||=c(`div`,{class:`stat-label`},`禁用用户数`,-1),c(`div`,B,n(V.value?.disabledUsers||0),1)])])])}}}),[[`__scopeId`,`data-v-9e5f3ec2`]]);export{V as default};