-
Notifications
You must be signed in to change notification settings - Fork 39
Open
Description
Need an option to make item anchor automatically change to SelectedItemAnchor.END when it's on the end of the list.
I'm trying using GetX Obs to change the anchor, but it kinda buggy right now.
Obx(() {
final itemAnchor = (controller.newsIndex.value + 1) >=
(controller.listNews.length - 1)
? SelectedItemAnchor.END
: SelectedItemAnchor.START;
return ScrollSnapList(
itemCount: controller.listNews.length,
itemSize: 264,
onItemFocus: (i) => controller.newsIndex.value = i,
itemBuilder: (_, i) => _newsItem(controller.listNews[i]),
selectedItemAnchor: itemAnchor,
endOfListTolerance: 200,
);
})Metadata
Metadata
Assignees
Labels
No labels
