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
9.3 KiB
2 lines
9.3 KiB
1 year ago
|
import{_ as fe}from"./whisper-7dcedd50.js";import{_ as he,a as ge}from"./post-item.vue_vue_type_style_index_0_lang-a5e9cab2.js";import{_ as ke}from"./post-skeleton-4d2b103e.js";import{_ as ye}from"./main-nav.vue_vue_type_style_index_0_lang-2982e04a.js";import{d as we,H as n,b as be,E as Pe,r as Ie,f as o,k as u,bf as _,q as d,w as c,Y as m,e,j as f,x as I,A as E,y as ae,F as y,u as w}from"./@vue-a481fc63.js";import{u as Te}from"./vuex-44de225f.js";import{b as Me}from"./vue-router-e5a2430e.js";import{e as x,F as ze,_ as qe}from"./index-4a465428.js";import{W as xe}from"./v3-infinite-loading-2c58ec2f.js";import{F as Se,a as $e,o as Ce,M as Le,f as Be,g as Fe,I as Ne,k as Ve,G as De}from"./naive-ui-d8de3dda.js";import"./content-0e30acaf.js";import"./@vicons-7a4ef312.js";import"./paopao-video-player-2fe58954.js";import"./copy-to-clipboard-4ef7d3eb.js";import"./@babel-725317a4.js";import"./toggle-selection-93f4ad84.js";import"./vooks-6d99783e.js";import"./evtd-b614532e.js";import"./axios-4a70c6fc.js";import"./moment-2ab8298d.js";/* empty css */import"./seemly-76b7b838.js";import"./vueuc-39372edb.js";import"./@css-render-7124a1a5.js";import"./vdirs-b0483831.js";import"./@juggle-41516555.js";import"./css-render-6a5c5852.js";import"./@emotion-8a8e73f6.js";import"./lodash-es-8412e618.js";import"./treemate-25c27bff.js";import"./async-validator-dee29e8b.js";import"./date-fns-975a2d8f.js";const Ue={class:"profile-baseinfo"},We={class:"avatar"},je={class:"base-info"},Ee={class:"username"},He={class:"userinfo"},Re={class:"info-item"},Ae={class:"info-item"},Ge={class:"userinfo"},Ye={class:"info-item"},Je={class:"info-item"},Ke={key:0,class:"skeleton-wrap"},Oe={key:1},Qe={key:0,class:"empty-wrap"},Xe={key:1},Ze={key:0},ea={key:1},aa={key:2},ta={key:3},sa={key:4},la={key:2},oa={key:0},na={key:1},ua={key:2},ia={key:3},ra={key:4},ca={class:"load-more-wrap"},va={class:"load-more-spinner"},_a=we({__name:"Profile",setup(ma){const i=Te(),T=Me(),v=n(!1),b=n(!1),s=n([]),S=n([]),$=n([]),C=n([]),L=n([]),B=n([]),p=n("post"),H=n(+T.query.p||1),R=n(1),A=n(1),G=n(1),Y=n(1),t=n(+T.query.p||1),h=n(20),r=n(0),J=n(0),K=n(0),O=n(0),Q=n(0),X=n(0),F=n(!1),Z=n({id:0,avatar:"",username:"",nickname:"",is_admin:!1,is_friend:!0,is_following:!1,created_on:0,follows:0,followings:0,status:1}),g=a=>{Z.value=a,F.value=!0},te=()=>{F.value=!1},N=()=>{switch(p.value){case"post":V();break;case"comment":D();break;case"highlight":U();break;case"media":W();break;case"star":j();break}},V=()=>{v.value=!0,x({username:i.state.userInfo.username,style:"post",page:t.value,page_size:h.value}).then(a=>{v.value=!1,a.list.length===0&&(b.value=!0),t.value>1?s.value=s.value.concat(a.list):(s.value=a.list||[],window.scrollTo(0,0)),r.value=Math.ceil(a.pager.total_rows/h.value),S.value=s.value,J.value=r.value}).catch(a=>{s.value=[],t.value>1&&t.value--,v.value=!1})},D=()=>{v.value=!0,x({username:i.state.userInfo.username,style:"comment",page:t.value,page_size:h.value}).then(a=>{v.value=!1,a.list.length===0&&(b.value=!0),t.value>1?s.value=s.value.concat(a.list):(s.value=a.list||[],window.scrollTo(0,0)),r.value=Math.ceil(a.pager.total_rows/h.value),$.value=s.value,K.value=r.value}).catch(a=>{s.value=[],t.value>1&&t.value--,v.value=!1})},U=()=>{v.value=!0,x({username:i.state.userInfo.username,style:"highlight",page:t.value,page_size:h.value}).then(a=>{v.value=!1,a.list.length===0&&(b.value=!0),t.value>1?s.value=s.value.concat(a.list):(s.value=a.list||[],window.scrollTo(0,0)),r.value=Math.ceil(a.pager.total_rows/h.value),C.value=s.value,O.value=r.value}).catch(a=>{s.value=[],t.value>1&&t.value--,v.value=!1})},W=()=>{v.value=!0,x({username:i.state.userInfo.username,style:"media",page:t.value,page_size:h.value}).then(a=>{v.value=!1,a.list.length===0&&(b.value=!0),t.value>1?s.value=s.value.concat(a.list):(s.value=a.list||[],window.scrollTo(0,0)),r.value=Math.ceil(a.pager.total_rows/h.value),L.value=s.value,Q.value=r.value}).catch(a=>{s.value=[],t.value>1&&t.value--,v.value=!1})},j=()=>{v.value=!0,x({username:i.state.userInfo.username,style:"star",page:t.value,page_size:h.value}).then
|