Repository navigation
[material_ui] Migrate M3 FAB template to use new gen_defaults - #12921
Conversation
There was a problem hiding this comment.
Code Review
This pull request migrates the Material 3 Floating Action Button (FAB) defaults to a generated implementation using the Material Design token database. Specifically, it removes the hardcoded _FABDefaultsM3 class from floating_action_button.dart and references it as a generated part file. It introduces the FabTemplateM3 template generator, enables it in the generation tool, and adds corresponding unit tests to verify the generated output. There are no review comments, so I have no additional feedback to provide.
| // packages/material_ui/tool/gen_defaults/bin/gen_defaults.dart. | ||
| part of '../floating_action_button.dart'; | ||
|
|
||
| class _FABDefaultsM3 extends FloatingActionButtonThemeData { |
There was a problem hiding this comment.
Out of curiosity - do you know the reasoning behind when we call it FAB vs FloatingActionButton?
There was a problem hiding this comment.
Nope, I think we have fab before I joined the team. I know we have "avoid abbreviation" rule in the style guide, so I guess we named it fab because in material design it is a recognizable enough:)
…ration # Conflicts: # packages/material_ui/tool/gen_defaults/bin/gen_defaults.dart # packages/material_ui/tool/gen_defaults/test/gen_defaults_test.dart
…er#193578) flutter/packages@3c6ce59...0ba9a82 2026-09-30 [email protected] [image_picker_ios] PR 1/5 Add injectable protocol seams and migrate leaf native tests to Swift Testing (flutter/packages#12897) 2026-09-30 [email protected] [material_ui] Migrate M3 Dialog template to use new gen_defaults (flutter/packages#12917) 2026-09-30 [email protected] [material_ui] Migrate M3 FAB template to use new gen_defaults (flutter/packages#12921) 2026-09-30 [email protected] [material_ui] Migrate M3 DatePicker template to use new gen_defaults (flutter/packages#12914) 2026-09-29 [email protected] [material_ui] Document that TextField.decoration is merged with InputDecorationTheme (flutter/packages#12493) 2026-09-29 [email protected] [camera_android_camerax] Move misplaced Javadoc above annotations (flutter/packages#13040) 2026-09-29 [email protected] [vector_graphics] Remove unnecessary Material imports (flutter/packages#12798) 2026-09-29 [email protected] Roll Flutter from c5a061b to 55b8f88 (8 revisions) (flutter/packages#13066) 2026-09-29 [email protected] [webview_flutter_wkwebview] Regenerate with pigeon 29.0.4 (flutter/packages#12923) 2026-09-29 [email protected] [url_launcher] Convert unit tests to Kotlin (flutter/packages#13018) 2026-09-29 [email protected] [material_ui, cupertino_ui] Fix unresolved doc comment references (flutter/packages#13044) If this roll has caused a breakage, revert this CL and set the roller to dry run mode using the controls here: https://autoroll.skia.org/r/flutter-packages-flutter-autoroll Please CC [email protected] on the revert to ensure that a human is aware of the problem. To file a bug in Flutter: 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
Work toward flutter/flutter#187899.
Fixes flutter/flutter#188415.
This PR migrates the M3 FloatingActionButton defaults template to use the new
gen_defaultsinmaterial_ui. The generated defaults remain unchanged.Pre-Review Checklist
[shared_preferences]///).