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

🅱️ Horizontal List Bug (Layout Problem for height not updated correctly) #759

Open
2 tasks
SherifMega opened this issue Mar 8, 2023 · 1 comment
Open
2 tasks

Comments

@SherifMega
Copy link

Current behavior

🅱️ Horizontal List Bug (Layout Problem for height)
create List horizontal with any data try to switch from portrait - landscape - portrait again
you will see thats list height is not updated correctly (cropped!) and sounds cache previous height for landscape

regarding some investigation i made console.log from inside _setFinalDimensions
console.log(this._totalWidth, ' - ', this._totalHeight)
recyclerlistview/dist/reactnative/core/layoutmanager/LayoutManager.js

1250 - 952
530 - 952
500 - 952
500 - 696
❌ 500 - 696 (should back again to correct height 952)

also if you tried that from (onLayout) you will see that width and height not updated correctly
<FlashList onLayout={(event) => { console.warn(event.nativeEvent.layout.width, '-', event.nativeEvent.layout.height) }} horizontal

bug.webm

Expected behavior

List height should be full as it was in beginning before rotate.

To Reproduce

try to switch horizontal flashlist from portrait - landscape - portrait again
you will see list is cropped in height when back again to portrait
you can also check width and height from onLayout to check wrong values.

Platform:

  • iOS
  • Android

Environment

"@shopify/flash-list": "^1.4.1",
"expo": "~47.0.12",

@chramos
Copy link

chramos commented Nov 30, 2023

are you reporting a flash-list bug here?

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

No branches or pull requests

2 participants