-
Notifications
You must be signed in to change notification settings - Fork 29.7k
Update TabBar and TabBar.secondary to use indicator height/color M3 tokens
#145753
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
Update TabBar and TabBar.secondary to use indicator height/color M3 tokens
#145753
Conversation
52918f5 to
69020e2
Compare
Piinks
left a comment
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 with just a nit! 🙂
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: Can you convert this to a switch assignment?
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 nice.
final bool primaryWithLabelIndicator = switch (indicatorSize) {
TabBarIndicatorSize.label => widget._isPrimary,
TabBarIndicatorSize.tab => false,
};69020e2 to
b528e65
Compare
…t/color M3 tokens (flutter/flutter#145753)
…t/color M3 tokens (flutter/flutter#145753)
…M3 tokens (flutter#145753) fixes [Secondary `TabBar` indicator height token is missing ](flutter#124965) ### Code sample <details> <summary>expand to view the code sample</summary> ```dart import 'package:flutter/material.dart'; void main() => runApp(const MyApp()); class MyApp extends StatelessWidget { const MyApp({super.key}); @OverRide Widget build(BuildContext context) { return MaterialApp( debugShowCheckedModeBanner: false, home: DefaultTabController( length: 2, child: Scaffold( appBar: AppBar( title: const Text('Sample'), bottom: const TabBar.secondary( tabs: <Widget>[ Tab(icon: Icon(Icons.directions_car)), Tab(icon: Icon(Icons.directions_transit)), ], ), ), floatingActionButton: FloatingActionButton( onPressed: () {}, child: const Icon(Icons.add), ), ), ), ); } } ``` </details>
…t/color M3 tokens (flutter/flutter#145753)
Manual roll Flutter from dbdcead to 89ea492 (54 revisions) Manual roll requested by [email protected] flutter/flutter@dbdcead...89ea492 2024-03-28 [email protected] Roll Flutter Engine from f71e5ad8586b to a396dc1a03a9 (3 revisions) (flutter/flutter#145928) 2024-03-28 [email protected] Roll Flutter Engine from 043af350ae85 to f71e5ad8586b (1 revision) (flutter/flutter#145919) 2024-03-28 [email protected] Refactor skp_generator_tests (flutter/flutter#145871) 2024-03-28 [email protected] Roll Flutter Engine from 7c9d5adb6ff8 to 043af350ae85 (2 revisions) (flutter/flutter#145917) 2024-03-28 [email protected] Update `TabBar` and `TabBar.secondary` to use indicator height/color M3 tokens (flutter/flutter#145753) 2024-03-28 [email protected] Roll Packages from e6b3e11 to 924c7e6 (5 revisions) (flutter/flutter#145915) 2024-03-28 [email protected] Add `viewId` to `TextInputConfiguration` (flutter/flutter#145708) 2024-03-28 [email protected] Roll Flutter Engine from 9df2d3a0778e to 7c9d5adb6ff8 (3 revisions) (flutter/flutter#145909) 2024-03-28 [email protected] Manual roll Flutter Engine from c602abdbae16 to 9df2d3a0778e (10 revisions) (flutter/flutter#145903) 2024-03-28 98614782+auto-submit[bot]@users.noreply.github.com Reverts "Roll Flutter Engine from c602abdbae16 to 922c7b133bc2 (7 revisions) (#145877)" (flutter/flutter#145901) 2024-03-28 98614782+auto-submit[bot]@users.noreply.github.com Reverts "Roll Flutter Engine from 922c7b133bc2 to b3516c4c5683 (1 revision) (#145879)" (flutter/flutter#145900) 2024-03-28 [email protected] Roll Flutter Engine from 922c7b133bc2 to b3516c4c5683 (1 revision) (flutter/flutter#145879) 2024-03-28 [email protected] Roll Flutter Engine from c602abdbae16 to 922c7b133bc2 (7 revisions) (flutter/flutter#145877) 2024-03-28 [email protected] Remove deprecated `TextTheme` members (flutter/flutter#139255) 2024-03-27 [email protected] [WIP] Predictive back support for routes (flutter/flutter#141373) 2024-03-27 [email protected] Roll Flutter Engine from 73c145c9ac3a to c602abdbae16 (1 revision) (flutter/flutter#145865) 2024-03-27 [email protected] Roll Flutter Engine from d65662541682 to 73c145c9ac3a (8 revisions) (flutter/flutter#145862) 2024-03-27 [email protected] Roll Flutter Engine from b7dddee939f2 to d65662541682 (2 revisions) (flutter/flutter#145851) 2024-03-27 [email protected] Roll Flutter Engine from 00dab0d9d310 to b7dddee939f2 (2 revisions) (flutter/flutter#145841) 2024-03-27 [email protected] Roll Packages from ab1630b to e6b3e11 (6 revisions) (flutter/flutter#145833) 2024-03-27 [email protected] Refactor web long running tests (flutter/flutter#145776) 2024-03-27 [email protected] Roll Flutter Engine from da64c6bcbbb6 to 00dab0d9d310 (1 revision) (flutter/flutter#145830) 2024-03-27 [email protected] Roll Flutter Engine from d6c6ba5aa157 to da64c6bcbbb6 (1 revision) (flutter/flutter#145811) 2024-03-27 [email protected] Roll Flutter Engine from 064a4f5d9042 to d6c6ba5aa157 (1 revision) (flutter/flutter#145807) 2024-03-27 [email protected] Roll Flutter Engine from cad8e7a9ad70 to 064a4f5d9042 (1 revision) (flutter/flutter#145805) 2024-03-27 [email protected] Roll Flutter Engine from 441005698702 to cad8e7a9ad70 (1 revision) (flutter/flutter#145804) 2024-03-27 [email protected] Roll Flutter Engine from d872d50e53f4 to 441005698702 (1 revision) (flutter/flutter#145803) 2024-03-27 [email protected] Roll Flutter Engine from 92ebd47dd8a8 to d872d50e53f4 (6 revisions) (flutter/flutter#145801) 2024-03-27 [email protected] Update localization files. (flutter/flutter#145780) 2024-03-27 [email protected] Roll Flutter Engine from 026d8902e3b5 to 92ebd47dd8a8 (1 revision) (flutter/flutter#145788) 2024-03-26 [email protected] [web] Add BackgroundIsolateBinaryMessenger.ensureInitialized to web. (flutter/flutter#145786) 2024-03-26 49699333+dependabot[bot]@users.noreply.github.com Bump codecov/codecov-action from 4.1.0 to 4.1.1 (flutter/flutter#145787) 2024-03-26 [email protected] Roll pub packages and regenerate gradle lockfiles (flutter/flutter#145727) 2024-03-26 [email protected] Roll Flutter Engine from 5c7aea6f20fc to 026d8902e3b5 (1 revision) (flutter/flutter#145785) 2024-03-26 [email protected] Roll Flutter Engine from baede78d2352 to 5c7aea6f20fc (2 revisions) (flutter/flutter#145784) 2024-03-26 [email protected] Roll Flutter Engine from cffd1dcfe6a5 to baede78d2352 (2 revisions) (flutter/flutter#145778) 2024-03-26 [email protected] Correct typo: "Free" to "Three" in comments (flutter/flutter#145689) 2024-03-26 [email protected] Fix disabled `DropdownMenu` doesn't defer the mouse cursor (flutter/flutter#145686) 2024-03-26 [email protected] Roll Flutter Engine from b2d93a64cbc7 to cffd1dcfe6a5 (9 revisions) (flutter/flutter#145773) 2024-03-26 [email protected] Roll Packages from 28d126c to ab1630b (1 revision) (flutter/flutter#145755) 2024-03-26 [email protected] Memory leaks clean up 2 (flutter/flutter#145757) 2024-03-26 [email protected] Fix memory leak in Overlay.wrap. (flutter/flutter#145744) 2024-03-26 [email protected] Be tolerant of backticks around directory name in `pub` output. (flutter/flutter#145768) 2024-03-26 [email protected] Fix `ExpansionTile` Expanded/Collapsed announcement is interrupted by VoiceOver (flutter/flutter#143936) ...
…t/color M3 tokens (flutter/flutter#145753)
fixes Secondary
TabBarindicator height token is missingCode sample
expand to view the code sample
Pre-launch Checklist
///).If you need help, consider asking for advice on the #hackers-new channel on Discord.