mirror of https://github.com/rocboss/paopao-ce
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
2 lines
2.3 KiB
2 lines
2.3 KiB
2 years ago
|
import{_ as R}from"./post-item.vue_vue_type_style_index_0_lang-ce942869.js";import{_ as U}from"./post-skeleton-40e81755.js";import{_ as V}from"./main-nav.vue_vue_type_style_index_0_lang-d6b3b6a4.js";import{d as $,r as l,a2 as D,Y as o,a4 as e,a3 as _,a6 as h,a5 as r,a7 as d,ai as M,b4 as q,W as t,Z as s,aa as f,ab as E,ac as F,$ as L,ae as T,aR as W,aS as Y,al as Z}from"./index-c17d3913.js";import{_ as j}from"./List-28c5febd.js";import{_ as A}from"./Pagination-84d10fc7.js";import{a as G,_ as H}from"./Skeleton-ca436747.js";import"./content-c9c72716.js";import"./formatTime-09781e30.js";import"./Thing-2157b754.js";const J={class:"profile-baseinfo"},K={class:"avatar"},O={class:"base-info"},Q={class:"username"},X={class:"uid"},ee={key:0,class:"pagination-wrap"},te={key:0,class:"skeleton-wrap"},ae={key:1},se={key:0,class:"empty-wrap"},ne=$({__name:"Profile",setup(oe){const a=L(),k=M(),c=l(!1),i=l([]),p=l(+k.query.p||1),u=l(20),m=l(0),g=()=>{c.value=!0,q({username:a.state.userInfo.username,page:p.value,page_size:u.value}).then(n=>{c.value=!1,i.value=n.list,m.value=Math.ceil(n.pager.total_rows/u.value),window.scrollTo(0,0)}).catch(n=>{c.value=!1})},y=n=>{p.value=n,g()};return D(()=>{g()}),(n,_e)=>{const w=V,b=T,I=A,P=W,x=Y,z=U,B=G,S=R,C=H,N=j;return t(),o("div",null,[e(w,{title:"主页"}),_(a).state.userInfo.id>0?(t(),h(N,{key:0,class:"main-content-wrap profile-wrap",bordered:""},{footer:r(()=>[m.value>1?(t(),o("div",ee,[e(I,{page:p.value,"onUpdate:page":y,"page-slot":_(a).state.collapsedRight?5:8,"page-count":m.value},null,8,["page","page-slot","page-count"])])):d("",!0)]),default:r(()=>[s("div",J,[s("div",K,[e(b,{size:"large",src:_(a).state.userInfo.avatar},null,8,["src"])]),s("div",O,[s("div",Q,[s("strong",null,f(_(a).state.userInfo.nickname),1),s("span",null," @"+f(_(a).state.userInfo.username),1)]),s("div",X,"UID. "+f(_(a).state.userInfo.id),1)])]),e(x,{class:"profile-tabs-wrap",animated:""},{default:r(()=>[e(P,{name:"post",tab:"泡泡"})]),_:1}),c.value?(t(),o("div",te,[e(z,{num:u.value},null,8,["num"])])):(t(),o("div",ae,[i.value.length===0?(t(),o("div",se,[e(B,{size:"large",description:"暂无数据"})])):d("",!0),(t(!0),o(E,null,F(i.value,v=>(t(),h(C,{key:v.id},{default:r(()=>[e(S,{post:v},null,8,["post"])]),_:2},1024))),128))]))]),_:1})):d("",!0)])}}});const ve=Z(ne,[["__scopeId","data-v-9040c022"]]);export{ve as default};
|