-
Notifications
You must be signed in to change notification settings - Fork 28.7k
Fix ListTile
Material issues (Add self-contained Material
)
#102310
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
Conversation
f9c8a9b
to
61c7ed1
Compare
Improved no longer used import
61c7ed1
to
ea2355b
Compare
I am wondering if this PR would also require to update the ListTile docs. Specifically, this part where it says the ListTile needs to be ancestor of a Material Widget for the colors to take effect.
|
That's a good idea, I'll update the docs once this PRs gets an initial review. |
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.
I wonder if there is a reason ListTile does not have a self-containing Material, especially since it was specifically documented that the user needs to supply a Material ancestor, rather than just adding one in like this.
My first guess would be how it affects the Inkwell in the ListTile, but I am not entirely sure. @HansMuller do you recall why ListTile does not contain Material?
I believe the original idea was that none of the components would have an intrinsic Material widget and that ink splashes would be rendered on the common "material" substrate without respect for their components' boundaries. That no longer matches the Material design and it turned out to be impractical in some cases. In this case cost is also a factor; applications may build large number of ListTiles and Material widgets aren't super-cheap. |
Ahh so it sounds like having one Material ancestor for potentially many ListTiles is more efficient? |
It's less Material widgets, so yes. |
If you look at the linked issues, they need to add
from #89642 |
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.
That sounds like a reasonable decision for the developer to make to me. It could be that we just need more documentation and example code for each of these issues, and particularly some docs on the performance implications.
Thank you! Sounds good to me, I would like to close all the linked issues with docs and examples. Closing this PR as a result. |
Filed #105760 |
Closed all the linked issues under #105760 |
This PR fixes the following issues
fixes #89642
minimal code sample
Video previews
Bug
transition.bug.mov
Fixed
transition.fixed.mov
fixes #89550
minimal code sample
Video previews
Bug
hero.bug.mov
Fixed
hero.fix.mov
fixes #85256
minimal code sample
Screenshot previews
Bug
Fixed
fixes #83124
minimal code sample
Video previews
Bug
animation.bug.mov
Fixed
aniamtion.fix.mov
fixes #84989
minimal code sample
Video previews
Bug
Screen.Recording.2022-04-22.at.17.25.00.mov
Fixed
Screen.Recording.2022-04-22.at.17.23.33.mov
Pre-launch Checklist
///
).If you need help, consider asking for advice on the #hackers-new channel on Discord.