import{f as e}from"./index-d76b1e7a.js";import{e as a,b as l}from"./useRouter.2bdb47a0.js";const u=u=>{const v=e(1),t=e(10),s=e(""),i=e(""),r=e(""),n=e(""),o=e(""),d=e(!1),p=e(!1),m=e(!1),c=e([]),y=async()=>{if(p.value||d.value)return;p.value=!0;const e=await u({page:v.value,limit:t.value,keyword:s.value,type:i.value,sid:r.value,news:n.value,isIntegral:o.value});m.value=!1,e&&(e.length<=0&&(1===v.value?m.value=!0:d.value=!0),c.value=c.value.concat(e)),p.value=!1};return a((()=>{})),l((()=>{p.value||d.value||(v.value+=1,y())})),{type:i,dataList:c,page:v,limit:t,keyword:s,loading:p,loadend:d,listEmpty:m,news:n,sid:r,refresh:()=>{d.value=!1,p.value=!1,v.value=1,c.value=[],y()}}};export{u};
