Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Table: Horizontal Overflow on Initial Load of Virtual Scrolling Table Populated with Remote Data #5569

Open
cjwang18 opened this issue Jul 16, 2020 · 0 comments
Assignees
Milestone

Comments

@cjwang18
Copy link

cjwang18 commented Jul 16, 2020

Reproduction link

https://stackblitz.com/edit/ng-zorro-antd-ivy-yphffm

Steps to reproduce

  • Load the stackblitz
  • Open preview in new window
  • Horizontal scrollbar should be visible after data is loaded in table
  • Toggling the visible columns via the select seems to resolve the issue

What is expected?

There should not be horizontal overflow present upon initial load of the table.

What is actually happening?

  • A horizontal scrollbar is visible on the <cdk-virtual-scroll-viewport>
    • Perhaps the widths of the columns are not being calculated correctly.
    • I'm just speculating, but the amount of overflow seems to match the width of the vertical scrollbar.
  • Using the nzLoading attribute on the table doesn't change the initial behavior

Initial Load with Mouse
image

After Toggling Visible Columns with Mouse
image

Potential Cause

Potential Workaround

  • Set *ngIf="loading" on the table, but this is not ideal
Environment Info
ng-zorro-antd 9.3.0
Browser Google Chrome 83.0.4103.116 (Official Build) (64-bit)
OS macOS 10.15.5

  • Only some columns have widths specified
  • Example contains additional code for layout and making the table full width and height on the page
@cjwang18 cjwang18 changed the title Horizontal Overflow on Initial Load of Virtual Scrolling Table Populated with Remote Data Table: Horizontal Overflow on Initial Load of Virtual Scrolling Table Populated with Remote Data Jul 28, 2020
@hsuanxyz hsuanxyz added this to the backlog milestone Oct 23, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants