nillud-data-table 1.5.5 → 1.5.6

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.
Files changed (2) hide show
  1. package/dist/index.js +4 -1
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -600,7 +600,10 @@ var DataTable = forwardRef(({
600
600
  const c = localStorage.getItem(`${tableName}-counts`);
601
601
  if (s) setSortBy(JSON.parse(s));
602
602
  if (f) setFilters(JSON.parse(f));
603
- if (c && paginationCounts && paginationCounts.includes(+c)) setPaginationSize(c === "all" ? 0 : Number(c));
603
+ if (paginationCounts) {
604
+ if (c && paginationCounts.includes(+c)) setPaginationSize(c === "all" ? 0 : Number(c));
605
+ else setPaginationSize(paginationCounts[0]);
606
+ }
604
607
  } catch (e) {
605
608
  console.error("Error parsing localStorage data:", e);
606
609
  setSortBy({ col: "", type: "asc" });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "nillud-data-table",
3
- "version": "1.5.5",
3
+ "version": "1.5.6",
4
4
  "type": "module",
5
5
  "main": "./dist/index.js",
6
6
  "module": "./dist/index.js",