import{d as V,r as R,D as j,j as W,o as w,K as D,Y as l,a as v,L as o,c as E,e as I,P as K,Z as M,O as S,U as m,_ as te,F as de,$ as pe,M as q,w as H,n as oe,s as b,a0 as me,Q,a1 as _e,a2 as he}from"./@vue-f70ab1bd.js";import{c as ge,a as fe,u as se,b as ve}from"./vue-router-29025daf.js";import{c as we,u as z}from"./vuex-cc1858c6.js";import{a as ye}from"./axios-707ed124.js";import{_ as ke,N as be,a as ne,b as re,c as Pe,d as Oe,e as ae,f as Ae,g as Le,h as le,i as Re,j as x,k as Ee,u as Ce,l as $e,m as Ie,n as Se,o as Te,p as Ue,q as Ke,r as Me,s as qe,t as Ne}from"./naive-ui-ddb574dd.js";import{S as De,M as xe,L as Ve,C as ze,B as Be,P as We,W as Fe,a as je,H as G,b as J,c as Y}from"./@vicons-fc06a0bb.js";/* empty css */import"./seemly-76b7b838.js";import"./vueuc-804c4158.js";import"./evtd-b614532e.js";import"./@css-render-66126308.js";import"./vooks-dfdd6eef.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";(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const c of document.querySelectorAll('link[rel="modulepreload"]'))p(c);new MutationObserver(c=>{for(const n of c)if(n.type==="childList")for(const h of n.addedNodes)h.tagName==="LINK"&&h.rel==="modulepreload"&&p(h)}).observe(document,{childList:!0,subtree:!0});function a(c){const n={};return c.integrity&&(n.integrity=c.integrity),c.referrerPolicy&&(n.referrerPolicy=c.referrerPolicy),c.crossOrigin==="use-credentials"?n.credentials="include":c.crossOrigin==="anonymous"?n.credentials="omit":n.credentials="same-origin",n}function p(c){if(c.ep)return;c.ep=!0;const n=a(c);fetch(c.href,n)}})();const He="modulepreload",Qe=function(e){return"/"+e},Z={},O=function(t,a,p){if(!a||a.length===0)return t();const c=document.getElementsByTagName("link");return Promise.all(a.map(n=>{if(n=Qe(n),n in Z)return;Z[n]=!0;const h=n.endsWith(".css"),d=h?'[rel="stylesheet"]':"";if(!!p)for(let y=c.length-1;y>=0;y--){const _=c[y];if(_.href===n&&(!h||_.rel==="stylesheet"))return}else if(document.querySelector(`link[href="${n}"]${d}`))return;const g=document.createElement("link");if(g.rel=h?"stylesheet":He,h||(g.as="script",g.crossOrigin=""),g.href=n,document.head.appendChild(g),h)return new Promise((y,_)=>{g.addEventListener("load",y),g.addEventListener("error",()=>_(new Error(`Unable to preload CSS for ${n}`)))})})).then(()=>t())},Ge=[{path:"/",name:"home",meta:{title:"广场",keepAlive:!0},component:()=>O(()=>import("./Home-3911c155.js"),["assets/Home-3911c155.js","assets/post-item.vue_vue_type_style_index_0_lang-02b1501b.js","assets/content-16569a30.js","assets/@vue-f70ab1bd.js","assets/@vicons-fc06a0bb.js","assets/naive-ui-ddb574dd.js","assets/seemly-76b7b838.js","assets/vueuc-804c4158.js","assets/evtd-b614532e.js","assets/@css-render-66126308.js","assets/vooks-dfdd6eef.js","assets/vdirs-b0483831.js","assets/@juggle-41516555.js","assets/css-render-6a5c5852.js","assets/@emotion-8a8e73f6.js","assets/lodash-es-8412e618.js","assets/treemate-25c27bff.js","assets/async-validator-dee29e8b.js","assets/date-fns-975a2d8f.js","assets/nonesir-video-29a967e9.js","assets/content-cc55174b.css","assets/vuex-cc1858c6.js","assets/vue-router-29025daf.js","assets/formatTime-936c40eb.js","assets/moment-b7869f98.js","assets/post-item-3a63e077.css","assets/post-skeleton-a5bf805a.js","assets/post-skeleton-f1900002.css","assets/lodash-3329902d.js","assets/copy-to-clipboard-ca358197.js","assets/toggle-selection-93f4ad84.js","assets/IEnum-ea67d3af.js","assets/main-nav.vue_vue_type_style_index_0_lang-d6d2ed7f.js","assets/main-nav-3ef9bae6.css","assets/axios-707ed124.js","assets/Home-47eb20e2.css","assets/vfonts-7afd136d.css"])},{path:"/post",name:"post",meta:{title:"话题详情"},component:()=>O(()=>import("./Post-7f43efba.js"),["assets/Post-7f43efba.js","assets/naive-ui-ddb574dd.js","assets/seemly-76b7b838.js","assets/@vue-f70ab1bd.js","assets/vueuc-804c4158.js","assets/evtd-b614532e.js","assets/@css-render-66126308.js","assets/vooks-dfdd6eef.js","assets/vdirs-b0483831.js","assets/@juggle-41516555.js","assets/css-render-6a5c5852.js","assets/@emotion-8a8e73f6.js","assets/lodash-es-8412e618.js","assets/treemate-25c27bff.js","assets/async-validator-dee29e8b.js","assets/date-fns-975a2d8f.js","assets/vuex-cc1858c6.js","assets/formatTime-936c40eb.js","assets/moment-b7869f98.js","assets/@vicons-fc06a0bb.js","assets/content-16569a30.js","assets/nonesir-video-29a967e9.js","assets/content-cc55174b.css","assets/vue-router-29025daf.js","assets/post-skeleton-a5bf805a.js","assets/post-skeleton-f1900002.css","assets/lodash-3329902d.js","assets/copy-to-clipboard-ca358197.js","assets/toggle-selection-93f4ad84.js","assets/IEnum-ea67d3af.js","assets/main-nav.vue_vue_type_style_index_0_lang-d6d2ed7f.js","assets/main-nav-3ef9bae6.css","assets/axios-707ed124.js","assets/Post-2deb7ac3.css","assets/vfonts-7afd136d.css"])},{path:"/topic",name:"topic",meta:{title:"话题"},component:()=>O(()=>import("./Topic-bda87938.js"),["assets/Topic-bda87938.js","assets/main-nav.vue_vue_type_style_index_0_lang-d6d2ed7f.js","assets/vuex-cc1858c6.js","assets/@vue-f70ab1bd.js","assets/vue-router-29025daf.js","assets/vooks-dfdd6eef.js","assets/evtd-b614532e.js","assets/@vicons-fc06a0bb.js","assets/naive-ui-ddb574dd.js","assets/seemly-76b7b838.js","assets/vueuc-804c4158.js","assets/@css-render-66126308.js","assets/vdirs-b0483831.js","assets/@juggle-41516555.js","assets/css-render-6a5c5852.js","assets/@emotion-8a8e73f6.js","assets/lodash-es-8412e618.js","assets/treemate-25c27bff.js","assets/async-validator-dee29e8b.js","assets/date-fns-975a2d8f.js","assets/main-nav-3ef9bae6.css","assets/axios-707ed124.js","assets/Topic-3a36c606.css","assets/vfonts-7afd136d.css"])},{path:"/anouncement",name:"anouncement",meta:{title:"公告"},component:()=>O(()=>import("./Anouncement-a1be6332.js"),["assets/Anouncement-a1be6332.js","assets/post-skeleton-a5bf805a.js","assets/naive-ui-ddb574dd.js","assets/seemly-76b7b838.js","assets/@vue-f70ab1bd.js","assets/vueuc-804c4158.js","assets/evtd-b614532e.js","assets/@css-render-66126308.js","assets/vooks-dfdd6eef.js","assets/vdirs-b0483831.js","assets/@juggle-41516555.js","assets/css-render-6a5c5852.js","assets/@emotion-8a8e73f6.js","assets/lodash-es-8412e618.js","assets/treemate-25c27bff.js","assets/async-validator-dee29e8b.js","assets/date-fns-975a2d8f.js","assets/post-skeleton-f1900002.css","assets/main-nav.vue_vue_type_style_index_0_lang-d6d2ed7f.js","assets/vuex-cc1858c6.js","assets/vue-router-29025daf.js","assets/@vicons-fc06a0bb.js","assets/main-nav-3ef9bae6.css","assets/formatTime-936c40eb.js","assets/moment-b7869f98.js","assets/axios-707ed124.js","assets/Anouncement-662e2d95.css","assets/vfonts-7afd136d.css"])},{path:"/profile",name:"profile",meta:{title:"主页"},component:()=>O(()=>import("./Profile-2e9667f8.js"),["assets/Profile-2e9667f8.js","assets/post-item.vue_vue_type_style_index_0_lang-02b1501b.js","assets/content-16569a30.js","assets/@vue-f70ab1bd.js","assets/@vicons-fc06a0bb.js","assets/naive-ui-ddb574dd.js","assets/seemly-76b7b838.js","assets/vueuc-804c4158.js","assets/evtd-b614532e.js","assets/@css-render-66126308.js","assets/vooks-dfdd6eef.js","assets/vdirs-b0483831.js","assets/@juggle-41516555.js","assets/css-render-6a5c5852.js","assets/@emotion-8a8e73f6.js","assets/lodash-es-8412e618.js","assets/treemate-25c27bff.js","assets/async-validator-dee29e8b.js","assets/date-fns-975a2d8f.js","assets/nonesir-video-29a967e9.js","assets/content-cc55174b.css","assets/vuex-cc1858c6.js","assets/vue-router-29025daf.js","assets/formatTime-936c40eb.js","assets/moment-b7869f98.js","assets/post-item-3a63e077.css","assets/post-skeleton-a5bf805a.js","assets/post-skeleton-f1900002.css","assets/main-nav.vue_vue_type_style_index_0_lang-d6d2ed7f.js","assets/main-nav-3ef9bae6.css","assets/axios-707ed124.js","assets/Profile-5d71a5c2.css","assets/vfonts-7afd136d.css"])},{path:"/user",name:"user",meta:{title:"用户详情"},component:()=>O(()=>import("./User-656cd0cb.js"),["assets/User-656cd0cb.js","assets/post-item.vue_vue_type_style_index_0_lang-02b1501b.js","assets/content-16569a30.js","assets/@vue-f70ab1bd.js","assets/@vicons-fc06a0bb.js","assets/naive-ui-ddb574dd.js","assets/seemly-76b7b838.js","assets/vueuc-804c4158.js","assets/evtd-b614532e.js","assets/@css-render-66126308.js","assets/vooks-dfdd6eef.js","assets/vdirs-b0483831.js","assets/@juggle-41516555.js","assets/css-render-6a5c5852.js","assets/@emotion-8a8e73f6.js","assets/lodash-es-8412e618.js","assets/treemate-25c27bff.js","assets/async-validator-dee29e8b.js","assets/date-fns-975a2d8f.js","assets/nonesir-video-29a967e9.js","assets/content-cc55174b.css","assets/vuex-cc1858c6.js","assets/vue-router-29025daf.js","assets/formatTime-936c40eb.js","assets/moment-b7869f98.js","assets/post-item-3a63e077.css","assets/post-skeleton-a5bf805a.js","assets/post-skeleton-f1900002.css","assets/main-nav.vue_vue_type_style_index_0_lang-d6d2ed7f.js","assets/main-nav-3ef9bae6.css","assets/axios-707ed124.js","assets/User-4f525d0f.css","assets/vfonts-7afd136d.css"])},{path:"/messages",name:"messages",meta:{title:"消息"},component:()=>O(()=>import("./Messages-4d43818f.js"),["assets/Messages-4d43818f.js","assets/@vue-f70ab1bd.js","assets/vue-router-29025daf.js","assets/formatTime-936c40eb.js","assets/moment-b7869f98.js","assets/@vicons-fc06a0bb.js","assets/naive-ui-ddb574dd.js","assets/seemly-76b7b838.js","assets/vueuc-804c4158.js","assets/evtd-b614532e.js","assets/@css-render-66126308.js","assets/vooks-dfdd6eef.js","assets/vdirs-b0483831.js","assets/@juggle-41516555.js","assets/css-render-6a5c5852.js","assets/@emotion-8a8e73f6.js","assets/lodash-es-8412e618.js","assets/treemate-25c27bff.js","assets/async-validator-dee29e8b.js","assets/date-fns-975a2d8f.js","assets/main-nav.vue_vue_type_style_index_0_lang-d6d2ed7f.js","assets/vuex-cc1858c6.js","assets/main-nav-3ef9bae6.css","assets/axios-707ed124.js","assets/Messages-7ed31ecd.css","assets/vfonts-7afd136d.css"])},{path:"/collection",name:"collection",meta:{title:"收藏"},component:()=>O(()=>import("./Collection-cbec4856.js"),["assets/Collection-cbec4856.js","assets/post-item.vue_vue_type_style_index_0_lang-02b1501b.js","assets/content-16569a30.js","assets/@vue-f70ab1bd.js","assets/@vicons-fc06a0bb.js","assets/naive-ui-ddb574dd.js","assets/seemly-76b7b838.js","assets/vueuc-804c4158.js","assets/evtd-b614532e.js","assets/@css-render-66126308.js","assets/vooks-dfdd6eef.js","assets/vdirs-b0483831.js","assets/@juggle-41516555.js","assets/css-render-6a5c5852.js","assets/@emotion-8a8e73f6.js","assets/lodash-es-8412e618.js","assets/treemate-25c27bff.js","assets/async-validator-dee29e8b.js","assets/date-fns-975a2d8f.js","assets/nonesir-video-29a967e9.js","assets/content-cc55174b.css","assets/vuex-cc1858c6.js","assets/vue-router-29025daf.js","assets/formatTime-936c40eb.js","assets/moment-b7869f98.js","assets/post-item-3a63e077.css","assets/post-skeleton-a5bf805a.js","assets/post-skeleton-f1900002.css","assets/main-nav.vue_vue_type_style_index_0_lang-d6d2ed7f.js","assets/main-nav-3ef9bae6.css","assets/axios-707ed124.js","assets/Collection-e1365ea0.css","assets/vfonts-7afd136d.css"])},{path:"/contacts",name:"contacts",meta:{title:"好友"},component:()=>O(()=>import("./Contacts-f0348211.js"),["assets/Contacts-f0348211.js","assets/vue-router-29025daf.js","assets/@vue-f70ab1bd.js","assets/naive-ui-ddb574dd.js","assets/seemly-76b7b838.js","assets/vueuc-804c4158.js","assets/evtd-b614532e.js","assets/@css-render-66126308.js","assets/vooks-dfdd6eef.js","assets/vdirs-b0483831.js","assets/@juggle-41516555.js","assets/css-render-6a5c5852.js","assets/@emotion-8a8e73f6.js","assets/lodash-es-8412e618.js","assets/treemate-25c27bff.js","assets/async-validator-dee29e8b.js","assets/date-fns-975a2d8f.js","assets/post-skeleton-a5bf805a.js","assets/post-skeleton-f1900002.css","assets/main-nav.vue_vue_type_style_index_0_lang-d6d2ed7f.js","assets/vuex-cc1858c6.js","assets/@vicons-fc06a0bb.js","assets/main-nav-3ef9bae6.css","assets/axios-707ed124.js","assets/Contacts-b60e5e0d.css","assets/vfonts-7afd136d.css"])},{path:"/wallet",name:"wallet",meta:{title:"钱包"},component:()=>O(()=>import("./Wallet-5214dc90.js"),["assets/Wallet-5214dc90.js","assets/post-skeleton-a5bf805a.js","assets/naive-ui-ddb574dd.js","assets/seemly-76b7b838.js","assets/@vue-f70ab1bd.js","assets/vueuc-804c4158.js","assets/evtd-b614532e.js","assets/@css-render-66126308.js","assets/vooks-dfdd6eef.js","assets/vdirs-b0483831.js","assets/@juggle-41516555.js","assets/css-render-6a5c5852.js","assets/@emotion-8a8e73f6.js","assets/lodash-es-8412e618.js","assets/treemate-25c27bff.js","assets/async-validator-dee29e8b.js","assets/date-fns-975a2d8f.js","assets/post-skeleton-f1900002.css","assets/main-nav.vue_vue_type_style_index_0_lang-d6d2ed7f.js","assets/vuex-cc1858c6.js","assets/vue-router-29025daf.js","assets/@vicons-fc06a0bb.js","assets/main-nav-3ef9bae6.css","assets/qrcode-23069ad7.js","assets/encode-utf8-f813de00.js","assets/dijkstrajs-59d11638.js","assets/formatTime-936c40eb.js","assets/moment-b7869f98.js","assets/axios-707ed124.js","assets/Wallet-77044929.css","assets/vfonts-7afd136d.css"])},{path:"/setting",name:"setting",meta:{title:"设置"},component:()=>O(()=>import("./Setting-0e822006.js"),["assets/Setting-0e822006.js","assets/main-nav.vue_vue_type_style_index_0_lang-d6d2ed7f.js","assets/vuex-cc1858c6.js","assets/@vue-f70ab1bd.js","assets/vue-router-29025daf.js","assets/vooks-dfdd6eef.js","assets/evtd-b614532e.js","assets/@vicons-fc06a0bb.js","assets/naive-ui-ddb574dd.js","assets/seemly-76b7b838.js","assets/vueuc-804c4158.js","assets/@css-render-66126308.js","assets/vdirs-b0483831.js","assets/@juggle-41516555.js","assets/css-render-6a5c5852.js","assets/@emotion-8a8e73f6.js","assets/lodash-es-8412e618.js","assets/treemate-25c27bff.js","assets/async-validator-dee29e8b.js","assets/date-fns-975a2d8f.js","assets/main-nav-3ef9bae6.css","assets/axios-707ed124.js","assets/Setting-bfd24152.css","assets/vfonts-7afd136d.css"])},{path:"/404",name:"404",meta:{title:"404"},component:()=>O(()=>import("./404-ffb0e783.js"),["assets/404-ffb0e783.js","assets/main-nav.vue_vue_type_style_index_0_lang-d6d2ed7f.js","assets/vuex-cc1858c6.js","assets/@vue-f70ab1bd.js","assets/vue-router-29025daf.js","assets/vooks-dfdd6eef.js","assets/evtd-b614532e.js","assets/@vicons-fc06a0bb.js","assets/naive-ui-ddb574dd.js","assets/seemly-76b7b838.js","assets/vueuc-804c4158.js","assets/@css-render-66126308.js","assets/vdirs-b0483831.js","assets/@juggle-41516555.js","assets/css-render-6a5c5852.js","assets/@emotion-8a8e73f6.js","assets/lodash-es-8412e618.js","assets/treemate-25c27bff.js","assets/async-validator-dee29e8b.js","assets/date-fns-975a2d8f.js","assets/main-nav-3ef9bae6.css","assets/axios-707ed124.js","assets/404-020b2afd.css","assets/vfonts-7afd136d.css"])},{path:"/:pathMatch(.*)",redirect:"/404"}],ue=ge({history:fe(),routes:Ge});ue.beforeEach((e,t,a)=>{document.title=`${e.meta.title} | 泡泡 - 一个清新文艺的微社区`,a()});const Je=we({state:{refresh:Date.now(),theme:localStorage.getItem("PAOPAO_THEME"),collapsedLeft:document.body.clientWidth<=821,collapsedRight:document.body.clientWidth<=821,drawerModelShow:document.body.clientWidth<=821,desktopModelShow:document.body.clientWidth>821,authModalShow:!1,authModelTab:"signin",userInfo:{id:0,username:"",nickname:""}},mutations:{refresh(e,t){e.refresh=t||Date.now()},triggerTheme(e,t){e.theme=t},triggerAuth(e,t){e.authModalShow=t},triggerAuthKey(e,t){e.authModelTab=t},triggerCollapsedLeft(e,t){e.collapsedLeft=t,e.drawerModelShow=t,e.desktopModelShow=!t},triggerCollapsedRight(e,t){e.collapsedRight=t},updateUserinfo(e,t){e.userInfo=t},userLogout(e){localStorage.removeItem("PAOPAO_TOKEN"),e.userInfo={id:0,nickname:"",username:""}}},actions:{},modules:{}}),F=ye.create({baseURL:"",timeout:3e4});F.interceptors.request.use(e=>(localStorage.getItem("PAOPAO_TOKEN")&&(e.headers.Authorization="Bearer "+localStorage.getItem("PAOPAO_TOKEN")),e),e=>Promise.reject(e));F.interceptors.response.use(e=>{const{data:t={},code:a=0}=(e==null?void 0:e.data)||{};if(+a==0)return t||{};Promise.reject((e==null?void 0:e.data)||{})},(e={})=>{var a;const{response:t={}}=e||{};return+(t==null?void 0:t.status)==401?(localStorage.removeItem("PAOPAO_TOKEN"),(t==null?void 0:t.data.code)!==10005?window.$message.warning((t==null?void 0:t.data.msg)||"鉴权失败"):window.$store.commit("triggerAuth",!0)):window.$message.error(((a=t==null?void 0:t.data)==null?void 0:a.msg)||"请求失败"),Promise.reject((t==null?void 0:t.data)||{})});function s(e){return F(e)}const X=e=>s({method:"post",url:"/v1/auth/login",data:e}),Ye=e=>s({method:"post",url:"/v1/auth/register",data:e}),B=(e="")=>s({method:"get",url:"/v1/user/info",headers:{Authorization:`Bearer ${e}`}}),Ze={class:"auth-wrap"},Xe={key:0},et=V({__name:"auth",setup(e){const t=R("true".toLowerCase()==="true"),a=z(),p=R(!1),c=R(),n=j({username:"",password:""}),h=R(),d=j({username:"",password:"",repassword:""}),C={username:{required:!0,message:"请输入账户名"},password:{required:!0,message:"请输入密码"},repassword:[{required:!0,message:"请输入密码"},{validator:(_,u)=>!!d.password&&d.password.startsWith(u)&&d.password.length>=u.length,message:"两次密码输入不一致",trigger:"input"}]},g=_=>{var u;_.preventDefault(),_.stopPropagation(),(u=c.value)==null||u.validate(P=>{P||(p.value=!0,X({username:n.username,password:n.password}).then(i=>{const r=(i==null?void 0:i.token)||"";return localStorage.setItem("PAOPAO_TOKEN",r),B(r)}).then(i=>{window.$message.success("登录成功"),p.value=!1,a.commit("updateUserinfo",i),a.commit("triggerAuth",!1),n.username="",n.password=""}).catch(i=>{p.value=!1}))})},y=_=>{var u;_.preventDefault(),_.stopPropagation(),(u=h.value)==null||u.validate(P=>{P||(p.value=!0,Ye({username:d.username,password:d.password}).then(i=>X({username:d.username,password:d.password})).then(i=>{const r=(i==null?void 0:i.token)||"";return localStorage.setItem("PAOPAO_TOKEN",r),B(r)}).then(i=>{window.$message.success("注册成功"),p.value=!1,a.commit("updateUserinfo",i),a.commit("triggerAuth",!1),d.username="",d.password="",d.repassword=""}).catch(i=>{p.value=!1}))})};return W(()=>{const _=localStorage.getItem("PAOPAO_TOKEN")||"";_?B(_).then(u=>{a.commit("updateUserinfo",u),a.commit("triggerAuth",!1)}).catch(u=>{a.commit("userLogout")}):a.commit("userLogout")}),(_,u)=>{const P=ke,i=be,r=ne,f=re,A=Pe,T=Oe,U=ae,L=Ae,N=Le,$=le,ie=Re;return w(),D(ie,{show:m(a).state.authModalShow,"onUpdate:show":u[7]||(u[7]=k=>m(a).state.authModalShow=k),class:"auth-card",preset:"card",size:"small","mask-closable":!1,bordered:!1,style:{width:"360px"}},{default:l(()=>[v("div",Ze,[o($,{bordered:!1},{default:l(()=>[t.value?S("",!0):(w(),E("div",Xe,[o(r,{justify:"center"},{default:l(()=>[o(i,null,{default:l(()=>[o(P,{type:"success"},{default:l(()=>[I("账号登录")]),_:1})]),_:1})]),_:1}),o(T,{ref_key:"loginRef",ref:c,model:n,rules:{username:{required:!0,message:"请输入账户名"},password:{required:!0,message:"请输入密码"}}},{default:l(()=>[o(A,{label:"账户",path:"username"},{default:l(()=>[o(f,{value:n.username,"onUpdate:value":u[0]||(u[0]=k=>n.username=k),placeholder:"请输入用户名",onKeyup:K(M(g,["prevent"]),["enter"])},null,8,["value","onKeyup"])]),_:1}),o(A,{label:"密码",path:"password"},{default:l(()=>[o(f,{type:"password","show-password-on":"mousedown",value:n.password,"onUpdate:value":u[1]||(u[1]=k=>n.password=k),placeholder:"请输入账户密码",onKeyup:K(M(g,["prevent"]),["enter"])},null,8,["value","onKeyup"])]),_:1})]),_:1},8,["model"]),o(U,{type:"primary",block:"",secondary:"",strong:"",loading:p.value,onClick:g},{default:l(()=>[I(" 登录 ")]),_:1},8,["loading"])])),t.value?(w(),D(N,{key:1,"default-value":m(a).state.authModelTab,size:"large","justify-content":"space-evenly"},{default:l(()=>[o(L,{name:"signin",tab:"登录"},{default:l(()=>[o(T,{ref_key:"loginRef",ref:c,model:n,rules:{username:{required:!0,message:"请输入账户名"},password:{required:!0,message:"请输入密码"}}},{default:l(()=>[o(A,{label:"账户",path:"username"},{default:l(()=>[o(f,{value:n.username,"onUpdate:value":u[2]||(u[2]=k=>n.username=k),placeholder:"请输入用户名",onKeyup:K(M(g,["prevent"]),["enter"])},null,8,["value","onKeyup"])]),_:1}),o(A,{label:"密码",path:"password"},{default:l(()=>[o(f,{type:"password","show-password-on":"mousedown",value:n.password,"onUpdate:value":u[3]||(u[3]=k=>n.password=k),placeholder:"请输入账户密码",onKeyup:K(M(g,["prevent"]),["enter"])},null,8,["value","onKeyup"])]),_:1})]),_:1},8,["model"]),o(U,{type:"primary",block:"",secondary:"",strong:"",loading:p.value,onClick:g},{default:l(()=>[I(" 登录 ")]),_:1},8,["loading"])]),_:1}),o(L,{name:"signup",tab:"注册"},{default:l(()=>[o(T,{ref_key:"registerRef",ref:h,model:d,rules:C},{default:l(()=>[o(A,{label:"用户名",path:"username"},{default:l(()=>[o(f,{value:d.username,"onUpdate:value":u[4]||(u[4]=k=>d.username=k),placeholder:"用户名注册后无法修改"},null,8,["value"])]),_:1}),o(A,{label:"密码",path:"password"},{default:l(()=>[o(f,{type:"password","show-password-on":"mousedown",placeholder:"密码不少于6位",value:d.password,"onUpdate:value":u[5]||(u[5]=k=>d.password=k),onKeyup:K(M(y,["prevent"]),["enter"])},null,8,["value","onKeyup"])]),_:1}),o(A,{label:"重复密码",path:"repassword"},{default:l(()=>[o(f,{type:"password","show-password-on":"mousedown",placeholder:"请再次输入密码",value:d.repassword,"onUpdate:value":u[6]||(u[6]=k=>d.repassword=k),onKeyup:K(M(y,["prevent"]),["enter"])},null,8,["value","onKeyup"])]),_:1})]),_:1},8,["model"]),o(U,{type:"primary",block:"",secondary:"",strong:"",loading:p.value,onClick:y},{default:l(()=>[I(" 注册 ")]),_:1},8,["loading"])]),_:1})]),_:1},8,["default-value"])):S("",!0)]),_:1})])]),_:1},8,["show"])}}});const ce=(e,t)=>{const a=e.__vccOpts||e;for(const[p,c]of t)a[p]=c;return a},tt=ce(et,[["__scopeId","data-v-52205ad0"]]),Qt=e=>s({method:"get",url:"/v1/posts",params:e}),ot=e=>s({method:"get",url:"/v1/tags",params:e}),Gt=e=>s({method:"get",url:"/v1/post",params:e}),Jt=e=>s({method:"get",url:"/v1/post/star",params:e}),Yt=e=>s({method:"post",url:"/v1/post/star",data:e}),Zt=e=>s({method:"get",url:"/v1/post/collection",params:e}),Xt=e=>s({method:"post",url:"/v1/post/collection",data:e}),eo=e=>s({method:"get",url:"/v1/post/comments",params:e}),to=e=>s({method:"get",url:"/v1/user/contacts",params:e}),oo=e=>s({method:"post",url:"/v1/post",data:e}),so=e=>s({method:"delete",url:"/v1/post",data:e}),no=e=>s({method:"post",url:"/v1/post/lock",data:e}),ro=e=>s({method:"post",url:"/v1/post/stick",data:e}),ao=e=>s({method:"post",url:"/v1/post/visibility",data:e}),lo=e=>s({method:"post",url:"/v1/post/comment",data:e}),uo=e=>s({method:"delete",url:"/v1/post/comment",data:e}),co=e=>s({method:"post",url:"/v1/post/comment/reply",data:e}),io=e=>s({method:"delete",url:"/v1/post/comment/reply",data:e}),st={key:0,class:"rightbar-wrap"},nt={class:"search-wrap"},rt={class:"post-num"},at={class:"copyright"},lt=["href"],ut=["href"],ct=V({__name:"rightbar",setup(e){const t=R([]),a=R(!1),p=R(""),c=z(),n=se(),h="2023 paopao.info",d="Roc's Me",C="",g="泡泡(PaoPao)开源社区",y="https://www.paopao.info",_=()=>{a.value=!0,ot({type:"hot",num:12}).then(i=>{t.value=i.topics,a.value=!1}).catch(i=>{a.value=!1})},u=i=>i>=1e3?(i/1e3).toFixed(1)+"k":i,P=()=>{n.push({name:"home",query:{q:p.value}})};return W(()=>{_()}),(i,r)=>{const f=x,A=re,T=te("router-link"),U=Ee,L=le,N=ne;return m(c).state.collapsedRight?S("",!0):(w(),E("div",st,[v("div",nt,[o(A,{round:"",clearable:"",placeholder:"搜一搜...",value:p.value,"onUpdate:value":r[0]||(r[0]=$=>p.value=$),onKeyup:K(M(P,["prevent"]),["enter"])},{prefix:l(()=>[o(f,{component:m(De)},null,8,["component"])]),_:1},8,["value","onKeyup"])]),o(L,{class:"hottopic-wrap",title:"热门话题",embedded:"",bordered:!1,size:"small"},{default:l(()=>[o(U,{show:a.value},{default:l(()=>[(w(!0),E(de,null,pe(t.value,$=>(w(),E("div",{class:"hot-tag-item",key:$.id},[o(T,{class:"hash-link",to:{name:"home",query:{q:$.tag,t:"tag"}}},{default:l(()=>[I(" #"+q($.tag),1)]),_:2},1032,["to"]),v("div",rt,q(u($.quote_num)),1)]))),128))]),_:1},8,["show"])]),_:1}),o(L,{class:"copyright-wrap",embedded:"",bordered:!1,size:"small"},{default:l(()=>[v("div",at,"© "+q(m(h)),1),v("div",null,[o(N,null,{default:l(()=>[v("a",{href:m(C),target:"_blank",class:"hash-link"},q(m(d)),9,lt),v("a",{href:m(y),target:"_blank",class:"hash-link"},q(m(g)),9,ut)]),_:1})])]),_:1})]))}}});const it=ce(ct,[["__scopeId","data-v-9c65d923"]]),po=(e={})=>s({method:"get",url:"/v1/captcha",params:e}),mo=e=>s({method:"post",url:"/v1/captcha",data:e}),_o=e=>s({method:"post",url:"/v1/user/whisper",data:e}),ho=e=>s({method:"post",url:"/v1/friend/requesting",data:e}),go=e=>s({method:"post",url:"/v1/friend/add",data:e}),fo=e=>s({method:"post",url:"/v1/friend/reject",data:e}),vo=e=>s({method:"post",url:"/v1/friend/delete",data:e}),wo=e=>s({method:"post",url:"/v1/user/phone",data:e}),yo=e=>s({method:"post",url:"/v1/user/activate",data:e}),ko=e=>s({method:"post",url:"/v1/user/password",data:e}),bo=e=>s({method:"post",url:"/v1/user/nickname",data:e}),Po=e=>s({method:"post",url:"/v1/user/avatar",data:e}),ee=(e={})=>s({method:"get",url:"/v1/user/msgcount/unread",params:e}),Oo=e=>s({method:"get",url:"/v1/user/messages",params:e}),Ao=e=>s({method:"post",url:"/v1/user/message/read",data:e}),Lo=e=>s({method:"get",url:"/v1/user/collections",params:e}),Ro=e=>s({method:"get",url:"/v1/user/profile",params:e}),Eo=e=>s({method:"get",url:"/v1/user/posts",params:e}),Co=e=>s({method:"get",url:"/v1/user/wallet/bills",params:e}),$o=e=>s({method:"post",url:"/v1/user/recharge",data:e}),Io=e=>s({method:"get",url:"/v1/user/recharge",params:e}),So=e=>s({method:"get",url:"/v1/suggest/users",params:e}),To=e=>s({method:"get",url:"/v1/suggest/tags",params:e}),Uo=e=>s({method:"get",url:"/v1/attachment/precheck",params:e}),Ko=e=>s({method:"get",url:"/v1/attachment",params:e}),Mo=e=>s({method:"post",url:"/v1/admin/user/status",data:e}),dt="/assets/logo-52afee68.png",pt={class:"sidebar-wrap"},mt={class:"logo-wrap"},_t={key:0,class:"user-wrap"},ht={class:"user-info"},gt={class:"nickname"},ft={class:"nickname-txt"},vt={class:"username"},wt={class:"user-mini-wrap"},yt={key:1,class:"user-wrap"},kt={key:0,class:"login-only-wrap"},bt={key:1,class:"login-wrap"},Pt=V({__name:"sidebar",setup(e){const t=z(),a=ve(),p=se(),c=R(!1),n=R(a.name||""),h=R(),d=R("true".toLowerCase()==="true");H(a,()=>{n.value=a.name}),H(t.state,()=>{t.state.userInfo.id>0?h.value||(ee().then(r=>{c.value=r.count>0}).catch(r=>{console.log(r)}),h.value=setInterval(()=>{ee().then(r=>{c.value=r.count>0}).catch(r=>{console.log(r)})},5e3)):h.value&&clearInterval(h.value)}),W(()=>{window.onresize=()=>{t.commit("triggerCollapsedLeft",document.body.clientWidth<=821),t.commit("triggerCollapsedRight",document.body.clientWidth<=821)}});const C=oe(()=>{const r=[{label:"广场",key:"home",icon:()=>b(G),href:"/"},{label:"话题",key:"topic",icon:()=>b(J),href:"/topic"}];return"false".toLowerCase()==="true"&&r.push({label:"公告",key:"anouncement",icon:()=>b(xe),href:"/anouncement"}),r.push({label:"主页",key:"profile",icon:()=>b(Ve),href:"/profile"}),r.push({label:"消息",key:"messages",icon:()=>b(ze),href:"/messages"}),r.push({label:"收藏",key:"collection",icon:()=>b(Be),href:"/collection"}),r.push({label:"好友",key:"contacts",icon:()=>b(We),href:"/contacts"}),"false".toLocaleLowerCase()==="true"&&r.push({label:"钱包",key:"wallet",icon:()=>b(Fe),href:"/wallet"}),r.push({label:"设置",key:"setting",icon:()=>b(je),href:"/setting"}),t.state.userInfo.id>0?r:[{label:"广场",key:"home",icon:()=>b(G),href:"/"},{label:"话题",key:"topic",icon:()=>b(J),href:"/topic"}]}),g=r=>"href"in r?b("div",{},r.label):r.label,y=r=>r.key==="messages"?b($e,{dot:!0,show:c.value,processing:!0},{default:()=>b(x,{color:r.key===n.value?"var(--n-item-icon-color-active)":"var(--n-item-icon-color)"},{default:r.icon})}):b(x,null,{default:r.icon}),_=(r,f={})=>{n.value=r,p.push({name:r})},u=()=>{a.path==="/"&&t.commit("refresh"),_("home")},P=r=>{t.commit("triggerAuth",!0),t.commit("triggerAuthKey",r)},i=()=>{t.commit("userLogout")};return window.$store=t,window.$message=Ce(),(r,f)=>{const A=Ie,T=Se,U=Te,L=ae;return w(),E("div",pt,[v("div",mt,[o(A,{class:"logo-img",width:"36",src:m(dt),"preview-disabled":!0,onClick:u},null,8,["src"])]),o(T,{accordion:!0,"icon-size":24,options:m(C),"render-label":g,"render-icon":y,value:n.value,"onUpdate:value":_},null,8,["options","value"]),m(t).state.userInfo.id>0?(w(),E("div",_t,[o(U,{class:"user-avatar",round:"",size:34,src:m(t).state.userInfo.avatar},null,8,["src"]),v("div",ht,[v("div",gt,[v("span",ft,q(m(t).state.userInfo.nickname),1),o(L,{class:"logout",quaternary:"",circle:"",size:"tiny",onClick:i},{icon:l(()=>[o(m(x),null,{default:l(()=>[o(m(Y))]),_:1})]),_:1})]),v("div",vt,"@"+q(m(t).state.userInfo.username),1)]),v("div",wt,[o(L,{class:"logout",quaternary:"",circle:"",onClick:i},{icon:l(()=>[o(m(x),{size:24},{default:l(()=>[o(m(Y))]),_:1})]),_:1})])])):(w(),E("div",yt,[d.value?S("",!0):(w(),E("div",kt,[o(L,{strong:"",secondary:"",round:"",type:"primary",onClick:f[0]||(f[0]=N=>P("signin"))},{default:l(()=>[I(" 登录 ")]),_:1})])),d.value?(w(),E("div",bt,[o(L,{strong:"",secondary:"",round:"",type:"primary",onClick:f[1]||(f[1]=N=>P("signin"))},{default:l(()=>[I(" 登录 ")]),_:1}),o(L,{strong:"",secondary:"",round:"",type:"info",onClick:f[2]||(f[2]=N=>P("signup"))},{default:l(()=>[I(" 注册 ")]),_:1})])):S("",!0)]))])}}});const Ot={"has-sider":"",class:"main-wrap",position:"static"},At={key:0},Lt={class:"content-wrap"},Rt=V({__name:"App",setup(e){const t=z(),a=oe(()=>t.state.theme==="dark"?Ke:null);return(p,c)=>{const n=Pt,h=te("router-view"),d=it,C=tt,g=Me,y=qe,_=Ne,u=Ue;return w(),D(u,{theme:m(a)},{default:l(()=>[o(y,null,{default:l(()=>[o(g,null,{default:l(()=>{var P;return[v("div",{class:_e(["app-container",{dark:((P=m(a))==null?void 0:P.name)==="dark"}])},[v("div",Ot,[m(t).state.desktopModelShow?(w(),E("div",At,[o(n)])):S("",!0),v("div",Lt,[o(h,{class:"app-wrap"},{default:l(({Component:i})=>[(w(),D(me,null,[p.$route.meta.keepAlive?(w(),D(Q(i),{key:0})):S("",!0)],1024)),p.$route.meta.keepAlive?S("",!0):(w(),D(Q(i),{key:0}))]),_:1})]),o(d)]),o(C)],2)]}),_:1})]),_:1}),o(_)]),_:1},8,["theme"])}}});he(Rt).use(ue).use(Je).mount("#app");export{fo as A,Ao as B,Oo as C,Lo as D,Uo as E,Ko as F,to as G,B as H,Co as I,$o as J,Io as K,po as L,Po as M,ko as N,wo as O,yo as P,bo as Q,mo as R,Pt as S,ce as _,To as a,Qt as b,oo as c,co as d,io as e,uo as f,So as g,lo as h,Jt as i,Zt as j,so as k,no as l,Xt as m,Gt as n,eo as o,Yt as p,ot as q,Eo as r,ro as s,_o as t,ho as u,ao as v,Ro as w,vo as x,Mo as y,go as z};