Liferay.Loader.define("data-engine-js-components-web@1.0.55/js/custom/form/components/Pagination.es",["module","exports","require","@frontend-taglib-clay$clayui/pagination","liferay!frontend-js-react-web$classnames","liferay!frontend-js-react-web$react","../../../core/actions/eventTypes.es","../../../core/hooks/useEvaluate.es","../../../core/hooks/useForm.es","../../../core/hooks/usePage.es","../../../utils/formId.es","../thunks/nextPage.es","../thunks/previousPage.es"],(function(e,a,t){window;{Object.defineProperty(a,"__esModule",{value:!0}),a.Pagination=function({activePage:e,pages:a}){const{containerElement:t}=(0,u.usePage)(),f=(0,i.useForm)(),m=(0,l.useEvaluate)(g.default),p=(0,l.useEvaluate)(d.default);return o.default.createElement(n.default,{className:"ddm-pagination justify-content-center"},o.default.createElement("li",{className:(0,s.default)("page-item",{"visibility-hidden":0===e})},o.default.createElement("button",{className:"page-link",onClick:()=>f(m({activePage:e,formId:(0,c.getFormId)((0,c.getFormNode)(t.current))})),type:"button"},"«",o.default.createElement("span",{className:"sr-only"},Liferay.Language.get("previous")))),a.map(((a,t)=>o.default.createElement(n.default.Item,{active:e===t,disabled:!a.enabled,key:t,onClick:()=>f({payload:{activePage:t},type:r.EVENT_TYPES.PAGE.CHANGE})},"paginated_success"===a.paginationItemRenderer?Liferay.Language.get("success-page"):t+1))),o.default.createElement("li",{className:(0,s.default)("page-item",{"visibility-hidden":e===a.length-1||-1===e})},o.default.createElement("button",{className:"page-link",onClick:()=>f(p({activePage:e,formId:(0,c.getFormId)((0,c.getFormNode)(t.current))})),type:"button"},"»",o.default.createElement("span",{className:"sr-only"},Liferay.Language.get("next")))))};var n=f(t("@frontend-taglib-clay$clayui/pagination")),s=f(t("liferay!frontend-js-react-web$classnames")),o=f(t("liferay!frontend-js-react-web$react")),r=t("../../../core/actions/eventTypes.es"),l=t("../../../core/hooks/useEvaluate.es"),i=t("../../../core/hooks/useForm.es"),u=t("../../../core/hooks/usePage.es"),c=t("../../../utils/formId.es"),d=f(t("../thunks/nextPage.es")),g=f(t("../thunks/previousPage.es"));function f(e){return e&&e.__esModule?e:{default:e}}}}));
//# sourceMappingURL=Pagination.es.js.map