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

Boolti-325 style: 공연 상세 출연진 목록 오버 스크롤 애니메이션 제거 #327

Merged
merged 1 commit into from
Nov 8, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ package com.nexters.boolti.presentation.screen.showdetail
import android.content.Intent
import android.os.Build
import androidx.activity.compose.BackHandler
import androidx.compose.foundation.ExperimentalFoundationApi
import androidx.compose.foundation.LocalOverscrollConfiguration
import androidx.compose.foundation.background
import androidx.compose.foundation.border
import androidx.compose.foundation.clickable
Expand Down Expand Up @@ -37,6 +39,7 @@ import androidx.compose.material3.TabRowDefaults
import androidx.compose.material3.TabRowDefaults.tabIndicatorOffset
import androidx.compose.material3.Text
import androidx.compose.runtime.Composable
import androidx.compose.runtime.CompositionLocalProvider
import androidx.compose.runtime.LaunchedEffect
import androidx.compose.runtime.getValue
import androidx.compose.runtime.mutableStateOf
Expand Down Expand Up @@ -506,6 +509,7 @@ private fun LazyListScope.ShowInfoTab(
}
}

@OptIn(ExperimentalFoundationApi::class)
@Suppress("FunctionName")
fun LazyListScope.CastTab(
teams: List<CastTeams>,
Expand Down Expand Up @@ -553,14 +557,19 @@ fun LazyListScope.CastTab(
* 중첩 Lazy 레이아웃 처리를 위해 높이 고정 필요
*/
val gridHeight = memberHeight * rows + spacedBySize * (rows - 1)
LazyVerticalGrid(
modifier = Modifier.height(gridHeight),
columns = GridCells.Fixed(spanCount),
verticalArrangement = Arrangement.spacedBy(spacedBySize),
horizontalArrangement = Arrangement.spacedBy(16.dp),
) {
items(team.members) { member ->
Cast(memberHeight, member, onClick = { onClickMember(member.userCode) })
CompositionLocalProvider(LocalOverscrollConfiguration provides null) {
LazyVerticalGrid(
modifier = Modifier.height(gridHeight),
columns = GridCells.Fixed(spanCount),
verticalArrangement = Arrangement.spacedBy(spacedBySize),
horizontalArrangement = Arrangement.spacedBy(16.dp),
) {
items(team.members) { member ->
Cast(
memberHeight,
member,
onClick = { onClickMember(member.userCode) })
}
}
}
}
Expand Down
Loading