You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Add layout-aware drop targeting for custom layouts (#605)
_Describe your changes here. Please include screenshots if they're
visual!_
This change allows custom ListLayout implementations to override
drop target determination during interactive item reordering.
- Add targetIndexPath(forInteractivelyMovingItem:withPosition:) protocol
method to ListLayout with default nil implementation
- Add CollectionViewLayout override that delegates to custom layout
- Add isReorderable property on ListLayoutContent.ItemInfo to expose
whether an item has reordering enabled
### Checklist
Please do the following before merging:
- [x] Ensure any public-facing changes are reflected in the
[changelog](https://github.com/square/Listable/blob/main/CHANGELOG.md).
Include them in the `Main` section.
Copy file name to clipboardExpand all lines: CHANGELOG.md
+3Lines changed: 3 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -4,6 +4,9 @@
4
4
5
5
### Added
6
6
7
+
- Added `targetIndexPath(forInteractivelyMovingItem:withPosition:)` protocol method to `ListLayout`, allowing custom layouts to override drop target determination during interactive reordering.
8
+
- Added `isReorderable` property on `ListLayoutContent.ItemInfo` to check if an item has reordering enabled.
0 commit comments