import{defineComponent as u,createVNode as i}from"vue";import m from"../_util/classNames.mjs";import y from"../_util/vue-types/index.mjs";const P=u({compatConfig:{MODE:3},name:"Pager",inheritAttrs:!1,props:{rootPrefixCls:String,page:Number,active:{type:Boolean,default:void 0},last:{type:Boolean,default:void 0},locale:y.object,showTitle:{type:Boolean,default:void 0},itemRender:{type:Function,default:()=>{}},onClick:{type:Function},onKeypress:{type:Function}},eimt:["click","keypress"],setup(e,{emit:o,attrs:s}){const a=()=>{o("click",e.page)},c=n=>{o("keypress",n,a,e.page)};return()=>{const{showTitle:n,page:l,itemRender:r}=e,{class:d,style:f}=s,t=`${e.rootPrefixCls}-item`,p=m(t,`${t}-${e.page}`,{[`${t}-active`]:e.active,[`${t}-disabled`]:!e.page},d);return i("li",{onClick:a,onKeypress:c,title:n?String(l):null,tabindex:"0",class:p,style:f},[r({page:l,type:"page",originalElement:i("a",{rel:"nofollow"},[l])})])}}});export{P as default};
