Skip to content

feat(datatable): add bottom selected text#729

Merged
paanSinghCoder merged 1 commit intomainfrom
feat/datatable-design-improvements
Apr 7, 2026
Merged

feat(datatable): add bottom selected text#729
paanSinghCoder merged 1 commit intomainfrom
feat/datatable-design-improvements

Conversation

@paanSinghCoder
Copy link
Copy Markdown
Contributor

@paanSinghCoder paanSinghCoder commented Apr 6, 2026

Description

feat: add hidden by filters text

Three scenarios:

  • Server + totalRowCount: show exact hidden count (X items hidden by filters) using API total and loaded/visible rows.
  • Server without totalRowCount: show only generic hint (Some items might be hidden by filters) when filter/search is active.
  • Client with full data: compute exact hidden count locally from pre-filter vs post-filter rows and show it when > 0.

Type of Change

  • Bug fix (non-breaking change that fixes an issue)
  • New feature (non-breaking change that adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation update
  • Refactor (no functional changes, no bug fixes just code improvements)
  • Chore (changes to the build process or auxiliary tools and libraries such as documentation generation)
  • Style (changes that do not affect the meaning of the code (white-space, formatting, etc))
  • Test (adding missing tests or correcting existing tests)
  • Improvement (Improvements to existing code)
  • Other (please specify)

How Has This Been Tested?

[Describe the tests that you ran to verify your changes]

Checklist:

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation (.mdx files)
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works

Screenshots (if appropriate):

[Add screenshots here]

Related Issues

[Link any related issues here using #issue-number]

@vercel
Copy link
Copy Markdown

vercel bot commented Apr 6, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
apsara Ready Ready Preview, Comment Apr 6, 2026 0:09am

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai bot commented Apr 6, 2026

📝 Walkthrough

Walkthrough

This change introduces a "Filter Summary Footer" feature to the DataTable component. A new optional totalRowCount prop is added to the DataTable interface and context to support server-mode row tracking. The Content component now conditionally renders a footer when filtering is active, displaying either a calculated hidden-row count (for client mode) or the provided totalRowCount (for server mode) alongside a "Clear Filters" button. Three new utility functions (countLeafRows, getClientHiddenLeafRowCount, hasActiveTableFiltering) support the filtering logic. Corresponding CSS styling, tests, and documentation updates are included to complete the feature.

Sequence Diagram(s)

Skipping this section—the changes, while spanning multiple files, represent a straightforward UI feature addition with simple, self-evident interactions rather than a complex multi-step flow requiring visualization.

Suggested reviewers

  • rsbh
🚥 Pre-merge checks | ✅ 1 | ❌ 2

❌ Failed checks (1 warning, 1 inconclusive)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 37.50% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
Title check ❓ Inconclusive The title 'add bottom selected text' is vague and does not accurately describe the actual change, which adds a filter summary footer showing hidden row counts and clear filters functionality. Revise the title to more clearly describe the feature, such as 'feat(datatable): add filter summary footer with hidden row count' or similar.
✅ Passed checks (1 passed)
Check name Status Explanation
Description check ✅ Passed The pull request description clearly describes the feature: displaying hidden-by-filters text with three specific scenarios (server with totalRowCount, server without, and client mode).

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


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.

@paanSinghCoder paanSinghCoder merged commit 0ff844a into main Apr 7, 2026
5 checks passed
@paanSinghCoder paanSinghCoder deleted the feat/datatable-design-improvements branch April 7, 2026 06:12
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.

2 participants