[Tabs] Active tab cannon be seen when child of AppBar
See original GitHub issueDuplicates
- I have searched the existing issues
Latest version
- I have tested the latest version
Current behavior 😯
Without changing the default theme, the text color of an active tab is the same as its background color, which makes it invisible. Other (non-active) tabs are displayed as expected.
Note: before upgrading to material v5 there was no issue.
Expected behavior 🤔
By default the text color of the active tab should be different than its background color.
Steps to reproduce 🕹
Steps:
- Define a
Tabs
with 2Tab
s under anAppBar
- Make sure one of the tabs is activated. –> the active tab text cannot be seen
Minimum reproduction: https://codesandbox.io/s/mui-v5-forked-gkx3v?file=/src/App.tsx
Context 🔦
No response
Your environment 🌎
`npx @mui/envinfo`
Don't forget to mention which browser you used.
Output from `npx @mui/envinfo` goes here.
Issue Analytics
- State:
- Created 2 years ago
- Comments:5 (4 by maintainers)
Top Results From Across the Web
[Tabs] Active tab cannon be seen when child of AppBar #30394
Without changing the default theme, the text color of an active tab is the same as its background color, which makes it invisible....
Read more >Work with tabs - Flutter documentation
Working with tabs is a common pattern in apps that follow the Material Design guidelines. Flutter includes a convenient way to create tab...
Read more >Flutter Appbar (actions) with child tabs - dart - Stack Overflow
I found the solution by making my parent widget as an InheritedWidget so I can access to it's data from child. Here's an...
Read more >How to Implement Tabs With AppBar in Flutter - YouTube
Learn How to Implement Tab along with Tabbar in Flutter at the bottom of the AppBar. Working with tabs is a common pattern...
Read more >Flutter Boring Tab to Cool Tab - Medium
First, we need to create a basic tab. In here I used DefaultTabController.You can assign DefaultTabController to a home parameter of the MaterialApp...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@Metheny80 Please check v4 docs https://v4.mui.com/components/tabs/#simple-tabs in this default color is white but in v5 https://mui.com/components/tabs/#basic-tabs default color is blue. You can customize it according to your requirements.
See also: https://mui.com/guides/migration-v4/#tabs