/*!
Copyright (c) 2026 Lenovo SSG BASD. All rights reserved.
@license Proprietary

This software is the confidential and proprietary property of Lenovo SSG BASD.
You shall not disclose such Confidential Information and shall use it only in
accordance with the terms of the license agreement.

--- Build Info ---
Version: 1.1.1
Build Time: 2026/2/26 17:21:00
Build Commit: 81e556ed827e2f043668506dae6fae8dbb9ef395
*/
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});require('./Pager.css');const e=require("vue"),t=require("../../../hooks/useLocale.js"),a=require("../../../Button/index.js");;/* empty css            */const l=require("../../../_virtual/_plugin-vue_export-helper.js"),r={class:"gsc-pager"},o={class:"text-sm gsc-text-secondary"},s=["value"],u=["value"],n={class:"gsc-pager-jumper text-sm"},i=["value"],c={class:"gsc-text-secondary"},p={__name:"Pager",props:{page:{type:Number,default:1},pageSize:{type:Number,default:10},total:{type:Number,default:0},pageSizeOptions:{type:Array,default:()=>[10,20,50,100]}},emits:["update:page","update:pageSize"],setup(l){const p=l,{t:d}=t.useLocale(),g=e.computed(()=>Math.max(1,Math.ceil((p.total||0)/(p.pageSize||1))));return(t,p)=>(e.openBlock(),e.createElementBlock("div",r,[e.createElementVNode("div",o,e.toDisplayString(e.unref(d)("gsc.grid.pager.total",{total:l.total})),1),e.createElementVNode("select",{class:"gsc-control gsc-control-auto",value:l.pageSize,onChange:p[0]||(p[0]=e=>t.$emit("update:pageSize",Number(e.target.value)))},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.pageSizeOptions,t=>(e.openBlock(),e.createElementBlock("option",{key:t,value:t},e.toDisplayString(e.unref(d)("gsc.grid.pager.pageSize",{size:t})),9,u))),128))],40,s),e.createVNode(e.unref(a.GscButton),{variant:"default",size:"icon",disabled:l.page<=1,onClick:p[1]||(p[1]=e=>t.$emit("update:page",l.page-1))},{default:e.withCtx(()=>[...p[4]||(p[4]=[e.createElementVNode("span",{"aria-hidden":"true"},"‹",-1)])]),_:1},8,["disabled"]),e.createElementVNode("div",n,[e.createElementVNode("input",{class:"gsc-control gsc-control-page gsc-control-center",value:l.page,onChange:p[2]||(p[2]=e=>t.$emit("update:page",Number(e.target.value||1)))},null,40,i),e.createElementVNode("span",c,"/ "+e.toDisplayString(g.value),1)]),e.createVNode(e.unref(a.GscButton),{variant:"default",size:"icon",disabled:l.page>=g.value,onClick:p[3]||(p[3]=e=>t.$emit("update:page",l.page+1))},{default:e.withCtx(()=>[...p[5]||(p[5]=[e.createElementVNode("span",{"aria-hidden":"true"},"›",-1)])]),_:1},8,["disabled"])]))}},d=l.default(p,[["__scopeId","data-v-6df635e7"]]);exports.default=d;