【发布时间】:2018-11-04 23:19:57
【问题描述】:
我正在使用 RadListView 尝试使用标题功能。如果我尝试在标题中使用 StackLayout,它会在内容加载后消失。但如果标题是一个元素(例如标签),它可以正常工作。该问题仅出现在 Android 上。
<GridLayout>
<RadListView [items]="products">
<ng-template tkListItemTemplate let-item="item">
<StackLayout orientation="vertical">
<Label class="nameLabel" text="test title"></Label>
<Label class="descriptionLabel" text="test description"></Label>
</StackLayout>
</ng-template>
<ng-template tkListViewHeader>
<StackLayout orientation="vertical">
<Label text="This is header row 1"></Label>
<Label text="This is header row 2"></Label>
</StackLayout>
</ng-template>
</RadListView>
</GridLayout>
加载前:
加载后:
【问题讨论】:
-
直到你得到正确的回应:你能试着给标题设置一个高度为 100 吗?
-
我无法使用文档中的相同示例重现该问题,除非使用 StackLayout 进行带有 2 个标签的标题视图。您能否尝试创建一个 Playground 示例,我们可以在其中看到问题。
标签: nativescript nativescript-angular nativescript-telerik-ui