Skip to content

fix: restore table height virtualization classname (BED-9057)#3054

Open
dcairnsspecterops wants to merge 3 commits into
mainfrom
bugfix-virtualization-issue
Open

fix: restore table height virtualization classname (BED-9057)#3054
dcairnsspecterops wants to merge 3 commits into
mainfrom
bugfix-virtualization-issue

Conversation

@dcairnsspecterops

@dcairnsspecterops dcairnsspecterops commented Jul 25, 2026

Copy link
Copy Markdown
Contributor

Description

Screen.Recording.2026-07-24.at.5.34.53.PM.mov

Describe your changes in detail

Motivation and Context

Resolves <TICKET_OR_ISSUE_NUMBER>

Why is this change required? What problem does it solve?

How Has This Been Tested?

Please describe in detail how you tested your changes.
Include details of your testing environment, and the tests you ran to
see how your change affects other areas of the code, etc.

Screenshots (optional):

Types of changes

  • Chore (a change that does not modify the application functionality)
  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Database Migrations

Checklist:

Summary by CodeRabbit

Summary by CodeRabbit

  • Bug Fixes
    • Improved the Explore table layout by updating how scrolling and height are handled, ensuring the table remains readable and well-fitted in smaller window sizes.
    • Adjusted Explore table interaction by removing drag-and-drop support from the table behavior.

@coderabbitai

coderabbitai Bot commented Jul 25, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Repository YAML (base), Organization UI (inherited)

Review profile: CHILL

Plan: Pro

Run ID: 307551d6-dbd3-4d03-9eeb-b42c43c8cb39

📥 Commits

Reviewing files that changed from the base of the PR and between 2bca121 and 5473bd7.

📒 Files selected for processing (1)
  • packages/javascript/bh-shared-ui/src/components/ExploreTable/ExploreTable.tsx
🚧 Files skipped from review as they are similar to previous changes (1)
  • packages/javascript/bh-shared-ui/src/components/ExploreTable/ExploreTable.tsx

📝 Walkthrough

Walkthrough

ExploreTable removes the ScrollArea wrapper and applies overflow and conditional height classes directly to MemoDataTable. The enableDragAndDrop prop is also removed.

Changes

ExploreTable styling

Layer / File(s) Summary
MemoDataTable container styling
packages/javascript/bh-shared-ui/src/components/ExploreTable/ExploreTable.tsx
Removes the ScrollArea wrapper and enableDragAndDrop prop, then adds overflow-auto and conditional viewport-based height classes to MemoDataTable.

Estimated code review effort: 1 (Trivial) | ~2 minutes

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Description check ⚠️ Warning The description is mostly the template skeleton and lacks filled-in change details, testing, and a valid ticket reference. Replace placeholders with a real summary, the exact issue or ticket in 'Resolves', testing details, selected change type, and completed checklist items.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly summarizes the main change: restoring the table height virtualization classname for BED-9057.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch bugfix-virtualization-issue

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

@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 current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In
`@packages/javascript/bh-shared-ui/src/components/ExploreTable/ExploreTable.tsx`:
- Line 226: Update the ExploreTable wrapper around MemoDataTable so its height
reflects isExpanded: use the expanded available-height calculation when expanded
and retain the collapsed viewport height otherwise, or allow the parent
grid/ScrollArea to determine it. Ensure virtualization receives the correct
height in both states and add coverage for collapsed and expanded rendering.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository YAML (base), Organization UI (inherited)

Review profile: CHILL

Plan: Pro

Run ID: dc190072-a5db-4d28-b65c-c779f9394105

📥 Commits

Reviewing files that changed from the base of the PR and between 1968388 and 5bab32e.

📒 Files selected for processing (1)
  • packages/javascript/bh-shared-ui/src/components/ExploreTable/ExploreTable.tsx

onColumnOrderChange={(newOrder) => {
setColumnOrder(newOrder);
}}
className='overflow-auto h-[calc(50vh-72px)]'

@coderabbitai coderabbitai Bot Jul 25, 2026

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.

🎯 Functional Correctness | 🟠 Major | ⚡ Quick win

Make the table height responsive to expanded mode.

The wrapper expands from h-1/2 to h-[calc(100%-72px)], but MemoDataTable always receives h-[calc(50vh-72px)]. In expanded mode, virtualization can therefore measure only the collapsed-height viewport, leaving unused space and incorrect scrolling behavior. Make the height conditional on isExpanded or let the surrounding grid/ScrollArea provide the available height, and add coverage for both states.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In
`@packages/javascript/bh-shared-ui/src/components/ExploreTable/ExploreTable.tsx`
at line 226, Update the ExploreTable wrapper around MemoDataTable so its height
reflects isExpanded: use the expanded available-height calculation when expanded
and retain the collapsed viewport height otherwise, or allow the parent
grid/ScrollArea to determine it. Ensure virtualization receives the correct
height in both states and add coverage for collapsed and expanded rendering.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Wow, smart bunny

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.

@dcairnsspecterops, happy to help! 🐇✨

@dcairnsspecterops dcairnsspecterops changed the title fix: restore table height virtualization classname fix: restore table height virtualization classname (BED-9057) Jul 25, 2026
@coderabbitai coderabbitai Bot added the user interface A pull request containing changes affecting the UI code. label Jul 25, 2026

@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 current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In
`@packages/javascript/bh-shared-ui/src/components/ExploreTable/ExploreTable.tsx`:
- Around line 225-229: Update the height-class conditions in the ExploreTable
container’s cn call so the 100vh height uses isExpanded instead of repeating
!isExpanded. Preserve the existing collapsed height condition and ensure exactly
one viewport height class applies in each state.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository YAML (base), Organization UI (inherited)

Review profile: CHILL

Plan: Pro

Run ID: d8072125-f782-4b5d-adcd-9b0adf6285d0

📥 Commits

Reviewing files that changed from the base of the PR and between 5bab32e and 2bca121.

📒 Files selected for processing (1)
  • packages/javascript/bh-shared-ui/src/components/ExploreTable/ExploreTable.tsx

Comment on lines +225 to +229
className={cn('overflow-auto', {
// TODO: why is header disappearing on bottom scroll? One extra overflow element somewhere
'h-[calc(50vh-72px)]': !isExpanded,
'h-[calc(100vh-72px)]': !isExpanded,
})}

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.

🎯 Functional Correctness | 🟠 Major | ⚡ Quick win

Fix the expanded-height condition.

Line 228 repeats !isExpanded; twMerge leaves collapsed mode at h-[calc(100vh-72px)], while expanded mode gets no height class. This breaks the virtualization viewport in both states. Use isExpanded on line 228.

Proposed fix
                     className={cn('overflow-auto', {
                         // TODO: why is header disappearing on bottom scroll? One extra overflow element somewhere
                         'h-[calc(50vh-72px)]': !isExpanded,
-                        'h-[calc(100vh-72px)]': !isExpanded,
+                        'h-[calc(100vh-72px)]': isExpanded,
                     })}
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In
`@packages/javascript/bh-shared-ui/src/components/ExploreTable/ExploreTable.tsx`
around lines 225 - 229, Update the height-class conditions in the ExploreTable
container’s cn call so the 100vh height uses isExpanded instead of repeating
!isExpanded. Preserve the existing collapsed height condition and ensure exactly
one viewport height class applies in each state.

@coderabbitai coderabbitai Bot removed the user interface A pull request containing changes affecting the UI code. label Jul 25, 2026
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