@kayord/ui 2.1.1 → 2.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -125,6 +125,7 @@ export function createGrid(options) {
125
125
  manualPagination: (dataGridProps?.isPaginationEnabled ?? true) == false ? true : dataGridProps?.manualPagination,
126
126
  manualSorting: dataGridProps.manualSorting,
127
127
  columnResizeMode: "onChange",
128
+ rowCount: dataGridProps.rowCount,
128
129
  enableColumnResizing: true,
129
130
  defaultColumn: {
130
131
  minSize: 0,
@@ -211,6 +212,10 @@ export function createGrid(options) {
211
212
  subscribeToTable();
212
213
  return table.getState();
213
214
  },
215
+ getPageCount: () => {
216
+ subscribeToTable();
217
+ return table.getPageCount();
218
+ },
214
219
  getColumn: (columnId) => {
215
220
  subscribeToTable();
216
221
  return table.getColumn(columnId);
@@ -16,6 +16,7 @@ export interface DataGridOptions<TData extends RowData> {
16
16
  dataGridProps?: DataGridProps;
17
17
  }
18
18
  export interface DataGridProps {
19
+ rowCount?: number;
19
20
  isPaginationEnabled?: boolean;
20
21
  manualPagination?: boolean;
21
22
  enableRowSelectionUI?: boolean;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@kayord/ui",
3
3
  "private": false,
4
- "version": "2.1.1",
4
+ "version": "2.1.2",
5
5
  "exports": {
6
6
  ".": {
7
7
  "types": "./dist/index.d.ts",