Skip to content
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

Supported collapsing non-primary TabBar on Material 3 #824

Merged
merged 1 commit into from
Oct 15, 2024

Conversation

grahammendick
Copy link
Owner

Adding a Material 3 theme to the Twitter sample stopped the collapsing TabBar on Notifications scene from working.
Turning off liftOnScroll on the NavigationBar (AppBarLayout) gets it working again.

Would be a lot of work to get liftOnScroll to work with the ViewPager. Not worth it until support turning off scroll on the Toolbar (SCROLL_FLAG_NO_SCROLL flag) and even then Android Material doesn't allow programmatic setting of liftOnScroll colors.

Turned off liftOnScroll because it [doesn't work with ViewPager](material-components/material-components-android#163). Could get it to work by dynamically setting the liftOnScrollTargetView - but not worth the difficulty for now. For liftOnScroll to work would need to support no_scroll flag on the Toolbar. Even if did that can't configure the colors for the lift on scroll programmatically so not worth the hassle.
Best to turn it off for now to get the collapsing tabbar back
@grahammendick grahammendick merged commit 28c92f9 into master Oct 15, 2024
@grahammendick grahammendick deleted the collapsing-tabbar branch October 15, 2024 17:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant