App hangs when ListView uses dynamic size for the cells:
iOS 16.7.5: Does not hangWhen using load on demand mode manual, and collapsing groups, one item left not collapsed.
If the ListView ItemTemplate contains more elements and you try to load more items (>15 items), there is a crash on iOS related to layout arrangements.
To workaround the issue, set explicitly ItemLength:
<telerikDataControls:RadListView.LayoutDefinition>
<telerikListView:ListViewLinearLayout ItemLength="400" />
</telerikDataControls:RadListView.LayoutDefinition>
Go to QSF ListView->selection example
1. Select the 2nd row and swiped it to the left
2. While the row above is still in the left-swiped mode with its red delete button still visible, click on a DIFFERENT row (say the 3rd row) AND scroll the ListView.
Video attached.
Exception occurs when there are no items in the collection and load on demand mode is automatic:
public ViewModel()
{
this.Source = new ObservableCollection<string>();
//for (int i = 0; i < 14; i++)
//{
// this.Source.Add(string.Format("Item {0}", i));
//}
this.LoadItemsCommand = new Command(this.LoadItemsCommandExecute);
}
When Group Header template is used and the visibility of an element in the template is changed, the template does not recreate as expected.
For example add entry /editor in the template and change its visibility
On iOS the editor/entry overlaps the group header and cannot type in it.
On UWP : The editor is visualized as expected but then we change its visibility to false, the space for the editor is still visible. The group header does not layout as expected.
Solution:
You have to collapse/expand the group header so the template in the group header to layout as expected
With iOS 16 some changes are introduced to the UICollectionView. This breaks the layout of the ListView with dynamically sized items.
When adding swipe content, it block the button to be clicked when the items in the cell matches the swipe offset value,
a. reduce the swipe offset.
b. place the minus button further to the left, so the button width to match the ListView swipe offset
Sample setup:
<telerikDataControls:RadListView x:Name="listView"
IsItemSwipeEnabled="True"
SwipeOffset="90, 0, 0, 0"
SwipeThreshold="20"
ItemsSource="{Binding Source}"
SelectionMode="None">
<telerikDataControls:RadListView.ItemTemplate>
<DataTemplate>
<listView:ListViewTemplateCell>
<listView:ListViewTemplateCell.View>
<Grid ColumnDefinitions="*,90">
<!-- >> changed second row to 90 pixels, which is swipe offset -->
<Label
FontAttributes="Bold"
FontSize="16"
Text="{Binding Sender}"
TextColor="Black" />
<StackLayout Grid.Column="1"
Orientation="Horizontal">
<Button
Clicked="Button_Clicked_1"
Text="+++"
TextColor="Gray" />
<Button
Clicked="Button_Clicked"
Text="---" />
</StackLayout>
</Grid>
</listView:ListViewTemplateCell.View>
</listView:ListViewTemplateCell>
</DataTemplate>
</telerikDataControls:RadListView.ItemTemplate>
<telerikDataControls:RadListView.ItemSwipeContentTemplate>
<DataTemplate>
<Grid
Margin="0"
Padding="0"
ColumnSpacing="0"
RowSpacing="0">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="90" />
<ColumnDefinition Width="*" />
</Grid.ColumnDefinitions>
<telerikInput:RadButton
Grid.Column="0"
Margin="0"
BackgroundColor="Red"
Clicked="RadButton_Clicked"
FontFamily="FontAwesomeSolid"
FontSize="Medium"
Text=""
WidthRequest="90" />
</Grid>
</DataTemplate>
</telerikDataControls:RadListView.ItemSwipeContentTemplate>
</telerikDataControls:RadListView>
is thrown when navigating to another view using ListView SelectedItem and removing the view where the ListView is placed.
Workaround:
Instead of removing the view, change the view visibility.