Skip to content

Table header in TableView using asyncList is not visible #3159

@ihgrant

Description

@ihgrant

🐛 Bug Report

In a TableView that uses an async list as a data source with a maxHeight prop defined, the table header is not visible.

🤔 Expected Behavior

When a TableView is rendered using an asynclist as datasource with a maxHeight prop defined, the table headers should be visible.

😯 Current Behavior

Currently, the table headers are not visible: https://codesandbox.io/s/exciting-gates-vurwv0

💁 Possible Solution

@snowystinger suggested on Slack that a flex rule be added to the .spectrum-Table-headWrapper class, which seemed to resolve the issue for me when applied via devtools. Will submit a PR with this fix.

🔦 Context

We're using async tables to display data that needs column headers for legibility and to be sortable. We are setting a maxHeight on the TableView in order to make use of the infinite scrolling function, because the height of the TableView's container is not fixed.

💻 Code Sample

https://codesandbox.io/s/exciting-gates-vurwv0

🌍 Your Environment

Software Version(s)
react-spectrum 3.17.0
Browser Vivaldi 5.2.2623.48 (Stable channel) (x86_64)
Operating System macOS 12.3.1

🧢 Your Company/Team

Adobe/Marketo Customer Engineering

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions