import{defineComponent as N,computed as T,toRef as w,createVNode as e,createTextVNode as z}from"vue";import{RightOutlined as g,LeftOutlined as v,DoubleRightOutlined as b,DoubleLeftOutlined as C}from"@antsoo-lib/icons";import I from"../_util/classNames.mjs";import R from"../_util/hooks/useBreakpoint.mjs";import{functionType as l,booleanType as i,stringType as j,someType as B,arrayType as L}from"../_util/type.mjs";import D from"../config-provider/hooks/useConfigInject.mjs";import{useLocaleReceiver as M}from"../locale/LocaleReceiver.mjs";import V from"../vc-pagination/Pagination.mjs";import A from"../vc-pagination/locale/en_US.mjs";import U,{MiddleSelect as E}from"./Select.mjs";import J from"./style/index.mjs";const Q=()=>({total:Number,defaultCurrent:Number,disabled:i(),current:Number,defaultPageSize:Number,pageSize:Number,hideOnSinglePage:i(),showSizeChanger:i(),pageSizeOptions:L(),buildOptionText:l(),showQuickJumper:B([Boolean,Object]),showTotal:l(),size:j(),simple:i(),locale:Object,prefixCls:String,selectPrefixCls:String,totalBoundaryShowSizeChanger:Number,selectComponentClass:String,itemRender:l(),role:String,responsive:Boolean,showLessItems:i(),onChange:l(),onShowSizeChange:l(),"onUpdate:current":l(),"onUpdate:pageSize":l()}),te=N({compatConfig:{MODE:3},name:"APagination",inheritAttrs:!1,props:Q(),setup(s,{slots:p,attrs:f}){const{prefixCls:n,configProvider:S,direction:o,size:d}=D("pagination",s),[x,P]=J(n),h=T(()=>S.getPrefixCls("select",s.selectPrefixCls)),$=R(),[O]=M("Pagination",A,w(s,"locale")),k=t=>{const a=e("span",{class:`${t}-item-ellipsis`},[z("•••")]),c=e("button",{class:`${t}-item-link`,type:"button",tabindex:-1},[o.value==="rtl"?e(g,null,null):e(v,null,null)]),u=e("button",{class:`${t}-item-link`,type:"button",tabindex:-1},[o.value==="rtl"?e(v,null,null):e(g,null,null)]),m=e("a",{rel:"nofollow",class:`${t}-item-link`},[e("div",{class:`${t}-item-container`},[o.value==="rtl"?e(b,{class:`${t}-item-link-icon`},null):e(C,{class:`${t}-item-link-icon`},null),a])]),r=e("a",{rel:"nofollow",class:`${t}-item-link`},[e("div",{class:`${t}-item-container`},[o.value==="rtl"?e(C,{class:`${t}-item-link-icon`},null):e(b,{class:`${t}-item-link-icon`},null),a])]);return{prevIcon:c,nextIcon:u,jumpPrevIcon:m,jumpNextIcon:r}};return()=>{const{itemRender:t=p.itemRender,buildOptionText:a=p.buildOptionText,selectComponentClass:c,responsive:u,...m}=s,r=d.value==="small"||!!($.value?.xs&&!d.value&&u),y={...m,...k(n.value),prefixCls:n.value,selectPrefixCls:h.value,selectComponentClass:c||(r?U:E),locale:O.value,buildOptionText:a,...f,class:I({[`${n.value}-mini`]:r,[`${n.value}-rtl`]:o.value==="rtl"},f.class,P.value),itemRender:t};return x(e(V,y,null))}}});export{te as default,Q as paginationProps};
