Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 10 additions & 2 deletions src/recyclerview/layout-managers/LinearLayoutManager.ts
Original file line number Diff line number Diff line change
Expand Up @@ -135,8 +135,16 @@ export class RVLinearLayoutManagerImpl extends RVLayoutManager {
layout.minHeight = targetMinHeight;
}
newTallestItem.minHeight = 0;
this.tallestItem = newTallestItem;
this.tallestItemHeight = newTallestItem.height;
// When items shrink (targetMinHeight = 0), reset tracking so the
// next cycle re-detects the tallest item after repaint and properly
// re-applies minHeight for all layouts.
if (targetMinHeight === 0) {
this.tallestItem = undefined;
this.tallestItemHeight = 0;
} else {
this.tallestItem = newTallestItem;
this.tallestItemHeight = newTallestItem.height;
}
}
}

Expand Down
Loading