Skip to content

Commit

Permalink
探索页允许纵向滚动
Browse files Browse the repository at this point in the history
  • Loading branch information
Him188 committed Nov 1, 2024
1 parent e06bebf commit 9858a77
Showing 1 changed file with 6 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@

package me.him188.ani.app.ui.exploration

import androidx.compose.foundation.ScrollState
import androidx.compose.foundation.layout.Column
import androidx.compose.foundation.layout.PaddingValues
import androidx.compose.foundation.layout.WindowInsets
Expand All @@ -18,6 +19,7 @@ import androidx.compose.foundation.layout.fillMaxWidth
import androidx.compose.foundation.layout.only
import androidx.compose.foundation.layout.padding
import androidx.compose.foundation.lazy.LazyListState
import androidx.compose.foundation.verticalScroll
import androidx.compose.material.icons.Icons
import androidx.compose.material.icons.rounded.Search
import androidx.compose.material.icons.rounded.Settings
Expand Down Expand Up @@ -64,6 +66,9 @@ class ExplorationPageState(

val trendingSubjectsCarouselState = CarouselState(itemCount = { trendingSubjectsState.numItems })
val followedSubjectsLazyRowState = LazyListState()


val pageScrollState = ScrollState(0)
}

@Composable
Expand Down Expand Up @@ -111,7 +116,7 @@ fun ExplorationPage(
PaddingValues(horizontal = horizontalPadding)

val navigator = LocalNavigator.current
Column(Modifier.padding(topBarPadding)) {
Column(Modifier.padding(topBarPadding).verticalScroll(state.pageScrollState)) {
NavTitleHeader(
title = { Text("最高热度") },
contentPadding = horizontalContentPadding,
Expand Down

0 comments on commit 9858a77

Please sign in to comment.