Adjust tab indicator visual (#9219)

Now behaves like the non-compose indicator by showing the swipe progress too

(cherry picked from commit 18e55aa25fe7ea63e66a99d1373fbdb449a358d7)

# Conflicts:
#	app/src/main/java/eu/kanade/presentation/library/components/LibraryTabs.kt
#	presentation-core/src/main/java/tachiyomi/presentation/core/components/material/Tabs.kt
This commit is contained in:
Ivan Iskandar
2023-03-17 09:20:25 +07:00
committed by Jobobby04
parent 9798289270
commit 7e81fa6723
6 changed files with 81 additions and 10 deletions
@@ -56,7 +56,7 @@ fun TabbedDialog(
TabRow(
modifier = Modifier.weight(1f),
selectedTabIndex = pagerState.currentPage,
indicator = { TabIndicator(it[pagerState.currentPage]) },
indicator = { TabIndicator(it[pagerState.currentPage], pagerState.currentPageOffsetFraction) },
divider = {},
) {
tabTitles.fastForEachIndexed { i, tab ->
@@ -69,7 +69,7 @@ fun TabbedScreen(
) {
TabRow(
selectedTabIndex = state.currentPage,
indicator = { TabIndicator(it[state.currentPage]) },
indicator = { TabIndicator(it[state.currentPage], state.currentPageOffsetFraction) },
) {
tabs.forEachIndexed { index, tab ->
Tab(