-
Notifications
You must be signed in to change notification settings - Fork 28.6k
Add convenience static members to AlignmentGeometry #169709
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
base: master
Are you sure you want to change the base?
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.
LGTM 👍
/// A property or argument of this type accepts classes created either with [ | ||
/// Alignment] and its variants, or [AlignmentDirectional.new]. | ||
/// A property or argument of this type accepts classes created either with | ||
/// [Alignment] and its variants, or [AlignmentDirectional.new]. |
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.
Good catch.
/// The top left corner. | ||
static const AlignmentGeometry topLeft = Alignment.topLeft; |
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.
Nit: Would it be useful to link these to their Alignment equivalent in the docs? Or maybe AlignmentGeometry shouldn't technically know about Alignment? Anyway, up to you.
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.
Added!
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.
Also LGTM! Thanks!
This adds convenience members to
AlignmentGeometry
in preparation for Dart shorthands.Before:
After (with Dart shorthands):
Prior art: #165597
Pre-launch Checklist
///
).If you need help, consider asking for advice on the #hackers-new channel on Discord.