import{l as e,s as a,k as s}from"./page_layout.js?v=1763625242172";import{d$ as p}from"./naive.js?v=1763625242172";import{k as i,ad as o,c as t,ae as r,R as u,a2 as l,ay as n,a3 as g,U as c,a4 as d,s as z,n as f}from"./vue.js?v=1763625242172";const m={class:"ml-8px text-14px"},v=i({__name:"index",props:o({storeKey:{default:""},pageSizes:{default:()=>[10,20,50,100]},showTotal:{type:Boolean,default:!0},showSizePicker:{type:Boolean,default:!0},showQuickJumper:{type:Boolean,default:!0},onUpdatePageSize:{}},{page:{},pageModifiers:{},pageSize:{},pageSizeModifiers:{}}),emits:o(["refresh"],["update:page","update:pageSize"]),setup(i,{emit:o}){const v=i,h=o,k=t((()=>{const{storeKey:e}=v;return e?"".concat(e,"-page"):""})),S=r(i,"page"),w=r(i,"pageSize"),y=e=>{S.value=e,h("refresh")},x=a=>{var s;S.value=1,w.value=a,null==(s=v.onUpdatePageSize)||s.call(v,e(a)),P(a),f((()=>{h("refresh")}))},P=e=>{k.value&&a(k.value,String(e))};return(()=>{var a;if(k.value){const p=s(k.value);p&&(w.value=e(p),null==(a=v.onUpdatePageSize)||a.call(v,e(p)))}})(),(e,a)=>{const s=p;return u(),l(s,z(e.$attrs,{page:S.value,"onUpdate:page":[a[0]||(a[0]=e=>S.value=e),y],"page-size":w.value,"onUpdate:pageSize":[a[1]||(a[1]=e=>w.value=e),x],"show-size-picker":e.showSizePicker,"show-quick-jumper":e.showQuickJumper,"page-sizes":e.pageSizes,"display-order":["pages","size-picker","quick-jumper"]}),n({_:2},[e.showTotal?{name:"suffix",fn:g((({itemCount:a})=>[c("span",m,d(e.$t("Public.Table.Page.index_4",[a])),1)])),key:"0"}:void 0]),1040,["page","page-size","show-size-picker","show-quick-jumper","page-sizes"])}}});export{v as _};
