fluentui icon indicating copy to clipboard operation
fluentui copied to clipboard

List: re-evaluate windows on element resize

Open SumiranAgg opened this issue 8 years ago • 10 comments

Bug Report

  • Browser and OS versions: Microsoft Edge 41.16354.1001.0

Priorities and help requested (not applicable if asking question):

Are you willing to submit a PR to fix? No

Requested priority: Normal

Products/sites affected: VSTS

Describe the issue:

On zoom (>=200%), few items are missing at the end of the list. (Usually few ms-List-pages are missing from the end) This also results in wrong SizeOfSet value in inspect tool to the observer, as only few items are visible and SizeOfSet shows actual list size.

Actual behavior:

Few items are missing and blank space appears instead.

Expected behavior:

All items should be visible.

SumiranAgg avatar Feb 08 '18 12:02 SumiranAgg

@cschleiden can you help us understand if this is an issue with the List or with VSTS? We're having a tough time reproing, both on the Fabric site and in a few lists in VSTS.

Jahnp avatar Feb 08 '18 23:02 Jahnp

@Jahnp I can't repro either. @SumiranAgg can you please provide more details?

cschleiden avatar Feb 09 '18 01:02 cschleiden

@Jahnp The issue appears when there is no vertical scrollbar. For instance in first example on link: https://developer.microsoft.com/en-us/fabric#/components/list If you remove max-height prop div class "ExampleCard-example x-hidden-focus", only 143 items are visible from 4999 items.

SumiranAgg avatar Feb 11 '18 10:02 SumiranAgg

If you do this, the list doesn't know that its viewport changed.

cschleiden avatar Feb 12 '18 18:02 cschleiden

So is it recommended to use max-height if the list is large?

SumiranAgg avatar Feb 13 '18 08:02 SumiranAgg

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions to Fabric React!

stale[bot] avatar Apr 11 '18 04:04 stale[bot]

Any update on this?

SumiranAgg avatar Aug 21 '18 08:08 SumiranAgg

It is possible to use element resize to get a javascript callback when this occurs. But this could introduce other perf issues.

dzearing avatar Oct 02 '18 20:10 dzearing

https://codepen.io/dzearing/pen/KGVdyx?editors=1111

This example uses element resize hacks to get a script callback when the element changes size, or the viewport zooms. Possible to hook this up to forceUpdate.

dzearing avatar Oct 02 '18 21:10 dzearing

This issue has been automatically marked as stale because it has marked as requiring author feedback but has not had any activity for 4 days. It will be closed if no further activity occurs within 3 days of this comment. Thank you for your contributions to Fabric React!

msft-github-bot avatar Dec 31 '18 19:12 msft-github-bot