-
-
Notifications
You must be signed in to change notification settings - Fork 239
Description
From @mmeven on November 21, 2018 15:18
Environment
- CLI: 5.0.0-2018-10-15-12485
- Cross-platform modules: 5.2.0-2018-11-19-184627-02
- Android Runtime: 5.0.0
- iOS Runtime: 5.1.0-2018-11-19-091441-01
Describe the bug
The issue is caused when a child layout of an ng-template can have a different height depending of the item displayed. It results in layouts being displayed on top of each other for items not at the top of the list (not displayed before scrolling), even though the parent layout has set its size to be able to contain every child layout.
To Reproduce
Create a component containing a ListView. The template for the items must be made of a parent Layout, and several child Layouts (at least 2) with one having a varying height, with a Label that is not displayed every time for exemple.
Expected behavior
The child Layouts should be displayed like this :

What happens
But this is what happens :

Sample project
https://github.com/mmeven/nativescript-listview-issue
Additional context
I did not manage to reproduce this issue with versions before 5.0.0, with tns-core-modules 4.2.1 and tns-ios 4.2.0 it works just fine. The "expected behavior" screenshot was done using those previous versions.
Copied from original issue: NativeScript/NativeScript#6594