-
Notifications
You must be signed in to change notification settings - Fork 28.7k
Normalize BottomAppBarTheme #168586
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
Normalize BottomAppBarTheme #168586
Conversation
This comment was marked as outdated.
This comment was marked as outdated.
20bdbc2
to
71d59a6
Compare
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.
Thank you so much for helping make some progress on the theme system cleanup!! This looks great! Just left some comments.
Signed-off-by: huycozy <[email protected]>
Signed-off-by: huycozy <[email protected]>
Signed-off-by: huycozy <[email protected]>
Signed-off-by: huycozy <[email protected]>
71d59a6
to
5270b9c
Compare
…pBarTheme Signed-off-by: huycozy <[email protected]>
5270b9c
to
d178dbd
Compare
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! Thanks for helping add this! Please do not submit this for now. Let's see if the google testing will be triggered. The test recently is not super stable.
1328134
to
43c1667
Compare
…pBarTheme Signed-off-by: huycozy <[email protected]>
43c1667
to
4d071ab
Compare
Signed-off-by: huycozy <[email protected]>
flutter/flutter@0b9f928...9a78af5 2025-05-15 [email protected] Manual pub package roll (flutter/flutter#168916) 2025-05-15 [email protected] Remove unnecessary `bringup: true` for release-channel only `Linux flutter_packaging`. (flutter/flutter#168761) 2025-05-15 [email protected] Revert: "Run `flutter_packaging` builders on release candidates (flutter/flutter#168917) 2025-05-15 [email protected] Roll Dart SDK from a6c25e31caa7 to c9640c3a4440 (1 revision) (flutter/flutter#168911) 2025-05-15 [email protected] Roll Packages from 1468581 to 2dff621 (4 revisions) (flutter/flutter#168908) 2025-05-15 [email protected] Roll Dart SDK from b3520981e0f0 to a6c25e31caa7 (11 revisions) (flutter/flutter#168895) 2025-05-15 [email protected] Roll Fuchsia Linux SDK from fSvuEJgRmHxnewRJr... to Jj-iDG5uPOsFgY2_H... (flutter/flutter#168893) 2025-05-15 [email protected] Fix mac_ios_engine_ddm config with missing ci/ios_debug_sim_ddm config (flutter/flutter#168888) 2025-05-15 [email protected] [native assets] Remove `KernelSnapshot` dependency in build (flutter/flutter#168742) 2025-05-15 [email protected] iOS,macOS: Migrate logging to Logger/FlutterLogger (flutter/flutter#168568) 2025-05-15 [email protected] Skip hot reload breakpoints test when running with web (flutter/flutter#168873) 2025-05-15 [email protected] CupertinoSliverNavigationBar respects accessibility text scaling (flutter/flutter#168866) 2025-05-15 [email protected] [display_list] paint cleanup. (flutter/flutter#168082) 2025-05-15 [email protected] Add a new CI build for iOS DDM-enabled artifacts (flutter/flutter#168717) 2025-05-15 98614782+auto-submit[bot]@users.noreply.github.com Reverts "Implements UISceneDelegate dynamically w/ FlutterLaunchEngine (#168396)" (flutter/flutter#168880) 2025-05-14 [email protected] Implements UISceneDelegate dynamically w/ FlutterLaunchEngine (flutter/flutter#168396) 2025-05-14 [email protected] Mark web_tool_tests_1_2 as bringup. (flutter/flutter#168871) 2025-05-14 [email protected] Marks Mac_mokey run_debug_test_android to be unflaky (flutter/flutter#167634) 2025-05-14 [email protected] Reland "Clip search artifacts in CupertinoSliverNavigationBar searchable-to-searchable transitions" (flutter/flutter#168772) 2025-05-14 [email protected] Remove references to `team-release`. (flutter/flutter#168780) 2025-05-14 [email protected] Make Cupertino sheet set the systemUIStyle through an AnnotatedRegion (flutter/flutter#168182) 2025-05-14 98614782+auto-submit[bot]@users.noreply.github.com Reverts "Use live region in error text input decorator for Android (#165531)" (flutter/flutter#168848) 2025-05-14 [email protected] Normalize BottomAppBarTheme (flutter/flutter#168586) 2025-05-14 [email protected] Roll Packages from 2e166de to 1468581 (2 revisions) (flutter/flutter#168828) 2025-05-14 [email protected] macOS,iOS: fix swift target triple (flutter/flutter#168749) 2025-05-14 [email protected] Further update `Engine-artifacts.md`. (flutter/flutter#168779) If this roll has caused a breakage, revert this CL and stop the roller using the controls here: https://autoroll.skia.org/r/flutter-packages Please CC [email protected] on the revert to ensure that a human is aware of the problem. To file a bug in Packages: https://github.com/flutter/flutter/issues/new/choose To report a problem with the AutoRoller itself, please file a bug: https://issues.skia.org/issues/new?component=1389291&template=1850622 Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
I'll be working on fixing the google testing once the PR to change theme type from |
Thank you! I filed #168966 following this. |
This is following #168586: See #168586 (comment) for the context of this. ## Pre-launch Checklist - [x] I read the [Contributor Guide] and followed the process outlined there for submitting PRs. - [x] I read the [Tree Hygiene] wiki page, which explains my responsibilities. - [x] I read and followed the [Flutter Style Guide], including [Features we expect every widget to implement]. - [x] I signed the [CLA]. - [x] I listed at least one issue that this PR fixes in the description above. - [x] I updated/added relevant documentation (doc comments with `///`). - [x] I added new tests to check the change I am making, or this PR is [test-exempt]. - [x] I followed the [breaking change policy] and added [Data Driven Fixes] where supported. - [x] All existing and new tests are passing. If you need help, consider asking for advice on the #hackers-new channel on [Discord]. <!-- Links --> [Contributor Guide]: https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md#overview [Tree Hygiene]: https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md [test-exempt]: https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md#tests [Flutter Style Guide]: https://github.com/flutter/flutter/blob/main/docs/contributing/Style-guide-for-Flutter-repo.md [Features we expect every widget to implement]: https://github.com/flutter/flutter/blob/main/docs/contributing/Style-guide-for-Flutter-repo.md#features-we-expect-every-widget-to-implement [CLA]: https://cla.developers.google.com/ [flutter/tests]: https://github.com/flutter/tests [breaking change policy]: https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md#handling-breaking-changes [Discord]: https://github.com/flutter/flutter/blob/main/docs/contributing/Chat.md [Data Driven Fixes]: https://github.com/flutter/flutter/blob/main/docs/contributing/Data-driven-Fixes.md Signed-off-by: huycozy <[email protected]>
FYI @huycozy, this change breaks builds using the See report: rydmike/flex_color_scheme#283 The package in a few places returns:
To create a custom version of The package also requires explicit type specifications of all types, which this migration does not consider. Because of this, this change breaks any build that uses lint The fix is of course simple enough, just change all refs to This of course may cause friction among FlexColorScheme users that venture to the master channel, as shown in example issue above. For most of the the earlier component theme normalizations, I noticed that the parallel usage of both This way an update to use the new Why was this not done in this case? The change of course also updates a number of internal tests that would fail and not compile if they had not been fixed. Which of course is one of the marks of a breaking change. |
Thanks for sharing your case, @rydmike!
Along with this PR, I also filed the breaking change documentation PR at flutter/website#12057 ( it's not ready for review yet as I need to wait for #169130 (AppBarTheme normalization) and #168981 (InputDecorationTheme normalization) to land first. And I'm unfortunately also not sure which stable or beta release will pack this commit.
This sounds a bit strange compared to the release process I'm familiar with, see Flutter's channels. Could you please elaborate on this? Typically, the fix/commit is landed on main/master first, then beta and stable. Maybe @QuncCccccc can help us figure out how to achieve this or verify if this is correct and helpful for users in the release process, and for similar PRs in the future (if there are any more)? |
Sorry for the inconvenience! I think we kept BottomAppBarTheme actually in this PR. We currently don't have any plan to remove the existing properties in This PR #168966 will cause breaking changes because we change the type of |
This PR is to make
BottomAppBarTheme
conform to Flutter Material's conventions for component themes:BottomAppBarThemeData
class which defines overrides for the defaults forBottomAppBar
properties.BottomAppBarTheme
constructor parameters:BottomAppBarThemeData? data
andWidget? child
. This is now the preferred way to configure aBottomAppBarTheme
:These two properties are made nullable to not break existing apps which has customized
ThemeData.bottomAppBarTheme
.BottomAppBarTheme
to be anInheritedWidget
subclass.BottomAppBarTheme
toBottomAppBarThemeData
.BottomAppBarTheme bottomAppBarTheme
property toBottomAppBarThemeData bottomAppBarTheme
inThemeData
andThemeData.copyWith()
. This may cause breaking changes, a migration guide will be created on website repo.BottomAppBarThemeData
and update the existingBottomAppBarTheme
tests. And also turn totrue
foruseMaterial3
(along with usages accordingly) at the common method_withTheme()
sinceuseMaterial3
is true by default.Pre-launch Checklist
///
).If you need help, consider asking for advice on the #hackers-new channel on Discord.