Skip to content

fix: Don't show empty footer in data table - #412

Merged
ilyabo merged 4 commits into
mainfrom
fix--Should-show-footer-in-DataTablePaginated
Mar 3, 2026
Merged

ilyabo merged 4 commits into
mainfrom
fix--Should-show-footer-in-DataTablePaginated

Conversation

@ilyabo

@ilyabo ilyabo commented Mar 3, 2026 •

Copy link
Copy Markdown
Collaborator

Also removed deprecated DataTableVirtualized

Summary by CodeRabbit

  • Chores

    • Removed an unused dependency from the data table package.
  • Bug Fixes

    • Data table footer now only displays when pagination, row count, or footer actions are present.
  • Refactor

    • Virtualized table implementation removed; public exports updated accordingly.
  • New Features

    • Added arrow-style paginated table, column type badge, and query actions menu to public exports.

@coderabbitai

coderabbitai Bot commented Mar 3, 2026 •

Copy link
Copy Markdown
Contributor

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info

Configuration used: defaults

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between a751b8c and 44537e1.

📒 Files selected for processing (1)
  • packages/data-table/src/DataTablePaginated.tsx
🚧 Files skipped from review as they are similar to previous changes (1)
  • packages/data-table/src/DataTablePaginated.tsx

📝 Walkthrough

Walkthrough

Removes the virtualized data-table implementation and its react-virtual dependency, gates the paginated table footer behind a new flag, and updates public exports to add paginated/auxiliary components while removing virtualized exports.

Changes

Cohort / File(s) Summary
Dependency
packages/data-table/package.json
Removed dependency react-virtual (v2.10.4) from the data-table package.
Removed virtualized component
packages/data-table/src/DataTableVirtualized.tsx
Deleted the entire virtualized table file, including exported types (DataTableVirtualizedProps, DataTableProps) and components (DataTableVirtualized, DataTableWithLoader).
Paginated table
packages/data-table/src/DataTablePaginated.tsx
Added shouldShowFooter boolean and wrapped all footer UI so the footer renders only when pagination, numeric numRows, or footerActions are present.
Public API exports
packages/data-table/src/index.ts
Removed exports related to DataTableVirtualized; added exports for ColumnTypeBadge, DataTableArrowPaginated (and its props type), and QueryDataTableActionsMenu.

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~45 minutes

Poem

🐰 I hopped along the table rows,
Farewell to virtualized flows—
A footer waits, now shown or slept,
New badges, arrows neatly kept.
🍃 Hop, review, and onward go!

🚥 Pre-merge checks | ✅ 2 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Title check ⚠️ Warning The title addresses the main fix (conditional footer rendering) but omits the equally significant removal of the deprecated DataTableVirtualized component and its exports. Update the title to reflect both major changes, such as: 'fix: Don't show empty footer and remove deprecated DataTableVirtualized' or 'refactor: Replace DataTableVirtualized and conditionally show footer'.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Docstring Coverage ✅ Passed Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
  • 📝 Generate docstrings (stacked PR)
  • 📝 Generate docstrings (commit on current branch)
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch fix--Should-show-footer-in-DataTablePaginated

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@packages/data-table/src/DataTablePaginated.tsx`:
- Line 145: The footer visibility logic in the DataTablePaginated component
currently only checks pagination and numRows, which hides the footer when only
footerActions exist and still shows it for non-finite numRows; update the
shouldShowFooter calculation to also consider footerActions and only treat
numRows as valid when it's a finite number (e.g., include footerActions in the
OR and replace the simple numRows !== undefined check with a Number.isFinite/
isFinite check against numRows) so the footer renders when footerActions are
provided and only when numRows is a finite count.

ℹ️ Review info

Configuration used: defaults

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 60a639e and a751b8c.

⛔ Files ignored due to path filters (1)
  • pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
📒 Files selected for processing (4)
  • packages/data-table/package.json
  • packages/data-table/src/DataTablePaginated.tsx
  • packages/data-table/src/DataTableVirtualized.tsx
  • packages/data-table/src/index.ts
💤 Files with no reviewable changes (1)
  • packages/data-table/src/DataTableVirtualized.tsx

Comment thread packages/data-table/src/DataTablePaginated.tsx Outdated
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
@ilyabo
ilyabo merged commit 00fe136 into main Mar 3, 2026
4 checks passed
@ilyabo
ilyabo deleted the fix--Should-show-footer-in-DataTablePaginated branch March 3, 2026 15:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant