[Tabs] Misplacement of the tab indicator if the parent AppBar width change
See original GitHub issue- The issue is present in the latest release.
- I have searched the issues of this repository and believe that this is not a duplicate.
This issue may be related to the issue #8379.
Current Behavior 😯
I use the example of AppBar providing here, I added tabs in the middle of the AppBar. When the side bar is opened, the indicator below the selected Tab is not correct positioned.
As an image worth a thousand words:
Expected Behavior 🤔
When I open the side bar, I expect the indicator to be well positioned under the selected Tab.
Steps to Reproduce 🕹
You can find a link to sandbox which reproduce the case. There’s also the same case is this repository.
Steps:
- Click on the menu button (top left of the screen),
- Pay attention to the position of the Tab indicator,
- Click on the left chevron icon to close the side bar,
- Pay attention to the position of the Tab indicator.
Your Environment 🌎
Even with the latest releases of material-ui (with sandbox), the behavior is the same.
`npx @material-ui/envinfo`
System:
OS: Linux 4.15 Ubuntu 18.04.5 LTS (Bionic Beaver)
Binaries:
Node: 13.7.0 - ~/install/node-v13.7.0-linux-x64/bin/node
Yarn: Not Found
npm: 6.14.9 - ~/install/node-v13.7.0-linux-x64/bin/npm
Browsers:
Chrome: 87.0.4280.66 (I use chrome!)
Firefox: 83.0
npmPackages:
@material-ui/core: ^4.11.2 => 4.11.2
@material-ui/icons: ^4.11.2 => 4.11.2
@material-ui/styles: 4.11.2
@material-ui/system: 4.11.2
@material-ui/types: 5.1.0
@material-ui/utils: 4.11.2
@types/react: 17.0.0
react: ^17.0.1 => 17.0.1
react-dom: ^17.0.1 => 17.0.1
Issue Analytics
- State:
- Created 3 years ago
- Comments:5 (3 by maintainers)
Top Results From Across the Web
[Tabs] Misplacement of the tab indicator if the parent AppBar ...
I use the example of AppBar providing here, I added tabs in the middle of the AppBar. When the side bar is opened,...
Read more >How to change tabs width in material UI - Stack Overflow
If you want tabs of fixed width, you need to override the root css class passed to the Tab component, where you have...
Read more >Flutter TabBar: A complete tutorial with examples
How to customize the tab indicator in TabBar; Making scrollable tabs with TabBar; Changing tabs programmatically; Listening for tab change event ...
Read more >Release Notes for Office Current Channel (Preview)
We fixed an issue where Excel would incorrectly use a fixed width rather than the full width space when converting text to column....
Read more >Overlay - PTC Support
Holemaking Cycle Types and Tabs ... To Display the Manufacturing Parent/Child Relationships ... About Length versus Thickness Indicator.
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
@frozar In your case, I would apply the action ref and do:
https://codesandbox.io/s/practical-payne-s2pkw?file=/src/index.js:2725-2998
When I read the previous issues, I realise that there is a lot written on this topic and that is still a hot topic.
As this issue is popular, it would be really helpful to have a basic example of the
updateIndicator()
method. It would save a lot of time to many people and also provide a concrete example of the current recommended work around on this issue.@oliviertassinari Can you fix the basic case I provided in my sandbox link to show how to use
updateIndicator()
method please?I would really like to contribute to material-ui lib but I’m honestly, I’m not ready for this. There’s still a lot of things that doesn’t fit in my head currently ^^’