"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var t=require("react"),e=require("primereact/paginator"),r=require("primereact/utils"),n=require("primereact/ripple"),o=require("primereact/api");function a(t){return t&&"object"==typeof t&&"default"in t?t:{default:t}}var i=a(t);function s(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);ra?1:0,e.props.sortOrder*i})),n}return null}},{key:"renderLoader",value:function(){if(this.props.loading){var t=r.classNames("p-dataview-loading-icon pi-spin",this.props.loadingIcon);return i.default.createElement("div",{className:"p-dataview-loading-overlay p-component-overlay"},i.default.createElement("i",{className:t}))}return null}},{key:"renderTopPaginator",value:function(){return!this.props.paginator||"bottom"===this.props.paginatorPosition&&"both"!==this.props.paginatorPosition?null:this.createPaginator("top")}},{key:"renderBottomPaginator",value:function(){return!this.props.paginator||"top"===this.props.paginatorPosition&&"both"!==this.props.paginatorPosition?null:this.createPaginator("bottom")}},{key:"renderEmptyMessage",value:function(){if(!this.props.loading){var t=this.props.emptyMessage||o.localeOption("emptyMessage");return i.default.createElement("div",{className:"p-col-12 col-12 p-dataview-emptymessage"},t)}return null}},{key:"renderHeader",value:function(){return this.props.header?i.default.createElement("div",{className:"p-dataview-header"},this.props.header):null}},{key:"renderFooter",value:function(){return this.props.footer?i.default.createElement("div",{className:"p-dataview-footer"}," ",this.props.footer):null}},{key:"renderItems",value:function(t){var e=this;if(t&&t.length){if(this.props.paginator){for(var r=this.props.onPage?this.props.rows:this.state.rows,n=this.props.lazy?0:this.props.onPage?this.props.first:this.state.first,o=this.getTotalRecords(),a=Math.min(r+n,o),s=[],l=n;l