Skip to content

Commit

Permalink
Revert "refactor: add toggle to always show buttons"
Browse files Browse the repository at this point in the history
This reverts commit 375d544.
  • Loading branch information
Boy0000 committed Aug 20, 2024
1 parent 375d544 commit af27dc8
Showing 1 changed file with 2 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ fun <T> Scrollable(
isHideTooltip = true
}
},
alwaysShowButtons: Boolean = false,
content: @Composable (page: List<T>) -> Unit,
) {
var size by remember { mutableStateOf(Size(0, 0)) }
Expand All @@ -50,9 +49,9 @@ fun <T> Scrollable(
position = navbarPosition,
navbar = {
NavbarButtons(navbarPosition, navbarBackground) {
if (alwaysShowButtons || line > 0) previousButton()
if (line > 0) previousButton()
else Spacer(1, 1)
if (alwaysShowButtons || end < items.size) nextButton()
if (end < items.size) nextButton()
else Spacer(1, 1)
}
},
Expand Down

0 comments on commit af27dc8

Please sign in to comment.