fix(table): sticky header & content placement in virtualized table#5184
Conversation
…m content placement fix
🦋 Changeset detectedLatest commit: ed4a5fc The changes in this PR will be included in the next version bump. This PR includes changesets to release 2 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
|
@Hova25 is attempting to deploy a commit to the HeroUI Inc Team on Vercel. A member of the Team first needs to authorize it. |
|
""" WalkthroughThe pull request adds a new changelog entry for the “@heroui/table” package and implements several adjustments in the virtualized table component. The changes include restructuring property handling, conditional content rendering modifications, and simplified prop passing. A new story export is introduced to enable a sticky header configuration, and a theme update adjusts the table’s body styling. These modifications collectively address the header stickiness issue reported in the linked bug. Changes
Sequence Diagram(s)sequenceDiagram
participant S as Storybook
participant VT as VirtualizedTable
participant CP as TableProp Generator
participant RV as RowVirtualizer
S->>VT: Render VirtualizedWithHeaderSticky
VT->>CP: getTableProps()
CP-->>VT: Return tableProps
VT->>RV: getTotalSize()
RV-->>VT: Return totalSize
VT->>VT: Calculate dynamic height style using totalSize & headerHeight
alt Check topContentPlacement
VT->>S: Render topContent (outside Wrapper)
else Alternative placement
VT->>VT: Render topContent inside main structure
end
VT->>S: Render table header with sticky behavior if isHeaderSticky is true
VT->>S: Render table rows via VirtualizedTableBody
Assessment against linked issues
Tip ⚡💬 Agentic Chat (Pro Plan, General Availability)
📜 Recent review detailsConfiguration used: .coderabbit.yaml 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
⏰ Context from checks skipped due to timeout of 90000ms (6)
🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
Documentation and Community
|
@heroui/accordion
@heroui/autocomplete
@heroui/alert
@heroui/avatar
@heroui/badge
@heroui/breadcrumbs
@heroui/button
@heroui/calendar
@heroui/card
@heroui/checkbox
@heroui/chip
@heroui/code
@heroui/date-input
@heroui/date-picker
@heroui/divider
@heroui/drawer
@heroui/dropdown
@heroui/form
@heroui/image
@heroui/input
@heroui/input-otp
@heroui/kbd
@heroui/link
@heroui/listbox
@heroui/menu
@heroui/modal
@heroui/navbar
@heroui/number-input
@heroui/pagination
@heroui/popover
@heroui/progress
@heroui/radio
@heroui/ripple
@heroui/scroll-shadow
@heroui/select
@heroui/skeleton
@heroui/slider
@heroui/snippet
@heroui/spacer
@heroui/switch
@heroui/spinner
@heroui/table
@heroui/tabs
@heroui/toast
@heroui/tooltip
@heroui/user
@heroui/react
@heroui/system
@heroui/system-rsc
@heroui/theme
@heroui/use-aria-accordion
@heroui/use-aria-accordion-item
@heroui/use-aria-button
@heroui/use-aria-link
@heroui/use-aria-modal-overlay
@heroui/use-aria-multiselect
@heroui/use-callback-ref
@heroui/use-clipboard
@heroui/use-data-scroll-overflow
@heroui/use-disclosure
@heroui/use-draggable
@heroui/use-image
@heroui/use-infinite-scroll
@heroui/use-intersection-observer
@heroui/use-is-mobile
@heroui/use-is-mounted
@heroui/use-measure
@heroui/use-pagination
@heroui/use-real-shape
@heroui/use-ref-state
@heroui/use-resize
@heroui/use-safe-layout-effect
@heroui/use-scroll-position
@heroui/use-ssr
@heroui/use-theme
@heroui/use-update-effect
@heroui/aria-utils
@heroui/dom-animation
@heroui/framer-utils
@heroui/react-rsc-utils
@heroui/react-utils
@heroui/shared-icons
@heroui/shared-utils
@heroui/stories-utils
@heroui/test-utils
commit: |
wingkwong
left a comment
There was a problem hiding this comment.
please edit PR description to explain the changes.
|
Thanks for the PR review @wingkwong, I've applied the suggested changes. |
|
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
Closes #5149
📝 Description
Fix header sticky in virtualized table
I have fixed also topContent outside placement and bottomContent outside placement in virtualized table
⛳️ Current behavior (updates)
🚀 New behavior
💣 Is this a breaking change (Yes/No)
No
Summary by CodeRabbit
New Features
Bug Fixes
Style