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
1.5 KiB
2 lines
1.5 KiB
import{a0 as b,_ as B}from"./index-Ngk4ShPB.js";import{d as C,H as p,e as N,v as U,w as s,A as a,t as i,k as n,j as _}from"./@vue-M2CzPUka.js";import{S as V,I as z,T as I,b as R,e as S,i as T}from"./naive-ui-CFtxauK_.js";const W={class:"whisper-wrap"},$={class:"whisper-line"},j={class:"whisper-line send-wrap"},A=C({__name:"whisper",props:{show:{type:Boolean,default:!1},user:{}},emits:["success"],setup(r,{emit:u}){const d=r,o=p(""),t=p(!1),m=u,c=()=>{m("success")},h=()=>{t.value=!0,b({user_id:d.user.id,content:o.value}).then(e=>{window.$message.success("发送成功"),t.value=!1,o.value="",c()}).catch(e=>{t.value=!1})};return(e,l)=>{const w=V,f=z,v=I,g=R,y=S,x=T;return N(),U(x,{show:e.show,"onUpdate:show":c,class:"whisper-card",preset:"card",size:"small",title:"私信","mask-closable":!1,bordered:!1,style:{width:"360px"}},{default:s(()=>[_("div",W,[n(v,{"show-icon":!1},{default:s(()=>[a(" 即将发送私信给: "),n(f,{style:{"max-width":"100%"}},{default:s(()=>[n(w,{type:"success"},{default:s(()=>[a(i(e.user.nickname)+"@"+i(e.user.username),1)]),_:1})]),_:1})]),_:1}),_("div",$,[n(g,{type:"textarea",placeholder:"请输入私信内容(请勿发送不和谐内容,否则将会被封号)",autosize:{minRows:5,maxRows:10},value:o.value,"onUpdate:value":l[0]||(l[0]=k=>o.value=k),maxlength:"200","show-count":""},null,8,["value"])]),_("div",j,[n(y,{strong:"",secondary:"",type:"primary",loading:t.value,onClick:h},{default:s(()=>[a(" 发送 ")]),_:1},8,["loading"])])])]),_:1},8,["show"])}}}),q=B(A,[["__scopeId","data-v-0cbfe47c"]]);export{q as _};
|