-
Notifications
You must be signed in to change notification settings - Fork 31
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #27 from TatsuUkraine/release-2.0.0
Release 2.0.0
- Loading branch information
Showing
12 changed files
with
819 additions
and
262 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
# Migration guide | ||
|
||
## Migration From v1.x.x to v2.x.x | ||
|
||
### Child count params | ||
|
||
In `InfiniteList` next params for max child count was renamed: | ||
- `minChildCount` was renamed to `negChildCount` and now it works with | ||
positive numbers | ||
- `maxChildCount` was renamed to `posChildCount` and, as before, it | ||
works with positive numbers | ||
|
||
### Header alignment | ||
|
||
Param `headerAlignment` in `InfiniteListItem` was replaced with 2 | ||
params: `mainAxisAlignment` and `crossAxisAlignment` | ||
|
||
Main axis is placed with scroll direction: vertical or horizontal. | ||
|
||
With `mainAxisAlignment: HeaderMainAxisAlignment.start` and vertical | ||
scroll header will stick to the top edge, with horizontal scroll - to | ||
the left edge. Similar with `mainAxisAlignment: | ||
HeaderMainAxisAlignment.end` - bottom and right side respectively. | ||
|
||
`crossAxisAlignment` doesn't affect stick side. It just places header to | ||
the left or right side for the vertical scroll, and top or bottom - for | ||
horizontal scroll. | ||
|
||
New parameter was added for relative positioning: `positionAxis` which | ||
defines what direction should be used during layout - column or row. | ||
|
||
### List item layout | ||
|
||
Comparing to v1, v2 by default uses relative positioning. | ||
|
||
To make header overlay content use constructor `overlay`. It's available | ||
in both `InfiniteListItem` and `StickyListItem` widgets. | ||
|
||
### Initial header render | ||
|
||
In default constructor param `initialHeaderBuild` was removed. | ||
|
||
Since default constructor uses relative positioning, header is required | ||
to calculate appropriate item size. | ||
|
||
`initialHeaderBuild` is still available in `overlay` constructors and | ||
affects header render like it was before in v1.x.x |
Oops, something went wrong.