import{r as t,G as r,k as p}from"./entry.Ddy3dMw-.js";const m=(v,g)=>{const a=t(0),i=t(void 0),l=t(void 0),o=t({page:0,pages:0,offset:0,limit:0,total:0});return{pageNum:a,paginationState:o,loadMore:async(n,s)=>{var u;(n!==i.value||s!==l.value)&&(a.value=0,o.value={page:0,pages:0,offset:0,limit:0,total:0}),a.value++,i.value=n,l.value=s;const f=g(v,a.value,n,s);r({loading:!0});const e=await p(f);return e.data.value&&(o.value=(u=e.data.value.result)==null?void 0:u.pagination,r({loading:!1})),e}}};export{m as u};