-
Notifications
You must be signed in to change notification settings - Fork 28.9k
add AnimatedSlide widget #86395
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add AnimatedSlide widget #86395
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks great. A couple of minor things to change and it should be good to go.
@flar |
I guess it became unclear now what lines I actually changed. |
It looks like you got the space at the end of the file, but the |
The docs are failing with the following error:
It looks like you mention another widget and in that comment you attempt to reference one of its properties (alignment) that is not in scope for the comment for your widget. You might have copied the comment from AnimatedContainer which got away with this because it also has an alignment property - which means its comment has a bug in that it is referencing the wrong property and the checks failed to notice due to serendipity. The AnimatedPadding makes this reference to another widget's property correctly It would be nice to fix AnimatedContainer's comment reference as well while you are fixing that up in your own doc comment. |
@flar Thanks a lot for your help. I changed docs references to |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
While Flutter already provides easy-to-use implicitly animated widgets, like AnimatedOpacity or AnimatedPositioned (and now also AnimatedScale and AnimatedRotation), there's no such widget for item's offset animation — which would behave the same as
SlideTransition
, but wouldn't require AnimationController to be provided.This PR adds
AnimatedOffset
widget to resolve this, which could be considered an implicitly animated version ofTransform.translate
.Fixes: #86081
Pre-launch Checklist
///
).