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

Refactor/update dependencies #206

Merged
merged 3 commits into from
Mar 29, 2024
Merged
Show file tree
Hide file tree
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
1 change: 1 addition & 0 deletions data/market-remote/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ dependencies {
implementation(kotlinx.serialization.json)
implementation(kotlinx.serialization.converter)
implementation(logging.interceptor)
implementation(lifecycle.viewmodel.ktx)
debugImplementation(chucker)
releaseImplementation(chucker.no.op)
androidTestImplementation(runner)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import androidx.compose.foundation.layout.padding
import androidx.compose.foundation.layout.size
import androidx.compose.foundation.shape.CircleShape
import androidx.compose.foundation.shape.RoundedCornerShape
import androidx.compose.material3.Divider
import androidx.compose.material3.HorizontalDivider
import androidx.compose.runtime.Composable
import androidx.compose.ui.Alignment
import androidx.compose.ui.Modifier
Expand Down Expand Up @@ -81,7 +81,7 @@ fun MarketDetailLoadingView() {
.shimmerEffect(),
)
}
Divider(color = Color.Gray)
HorizontalDivider(color = Color.Gray)
Row(
modifier = Modifier
.padding(16.dp)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ import androidx.compose.foundation.layout.size
import androidx.compose.foundation.rememberScrollState
import androidx.compose.foundation.shape.CircleShape
import androidx.compose.foundation.verticalScroll
import androidx.compose.material3.Divider
import androidx.compose.material3.FloatingActionButton
import androidx.compose.material3.HorizontalDivider
import androidx.compose.material3.MaterialTheme
import androidx.compose.material3.Surface
import androidx.compose.material3.Text
Expand Down Expand Up @@ -233,7 +233,7 @@ private fun MarketData() {
style = MaterialTheme.typography.titleLarge,
)
}
Divider(color = Color.Gray)
HorizontalDivider(color = Color.Gray)
}

fun formatNumber(number: Long?): String {
Expand Down
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
# http://www.gradle.org/docs/current/userguide/build_environment.html
# Specifies the JVM arguments used for the daemon process.
# The setting is particularly useful for tweaking memory settings.
org.gradle.jvmargs=-Xmx2048m -Dfile.encoding=UTF-8
org.gradle.jvmargs=-Xmx4096m -Dfile.encoding=UTF-8
# When configured, Gradle will run in incubating parallel mode.
# This option should only be used with decoupled projects. More details, visit
# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
Expand Down
36 changes: 18 additions & 18 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,43 +6,43 @@ projectTargetSdkVersion = "34"
projectCompileSdkVersion = "34"
projectVersionCode = "1"

kotlin = "1.9.10"
kotlin = "1.9.23"
kotlinter = "3.16.0"
ksp = "1.9.10-1.0.13"
kotlinxImmutableCollection = "0.3.5"
androidGradlePlugin = "8.1.3"
androidGradlePlugin = "8.1.4"

ktx = "1.12.0"

composeBOM = "2023.10.01"
composeActivity = "1.8.0"
composeBOM = "2024.03.00"
composeActivity = "1.8.2"
composeCoil = "2.2.2"
composeCompiler = "1.5.3"
composeMaterial3 = "1.1.2"
composeCompiler = "1.5.11"
composeMaterial3 = "1.2.1"

detekt = "1.23.1"
hilt = "2.48"
androidHiltCompiler = "1.1.0"
hiltNavigationCompose = "1.1.0"
hiltWork = "1.1.0"
hilt = "2.50"
androidHiltCompiler = "1.2.0"
hiltNavigationCompose = "1.2.0"
hiltWork = "1.2.0"
javaxInject = "1"
lottieAnimation = "6.1.0"

coroutinesCore = "1.7.3"

lifeCycle = "2.6.2"
lifeCycleViewModelKtx = "2.6.2"
lifeCycleRuntimeCompose = "2.6.2"
lifeCycle = "2.7.0"
lifeCycleViewModelKtx = "2.7.0"
lifeCycleRuntimeCompose = "2.7.0"

navigationCompose = "2.7.5"
navigationCompose = "2.7.7"

retrofit = "2.9.0"
loggingInterceptor = "4.11.0"
chucker = "3.5.2"
kotlinx-serialization = "1.6.0"
kotlinx-serialization-converter = "1.0.0"

sqldelight = "2.0.0"
sqldelight = "2.0.1"

junit = "4.13.2"
junitExt = "1.1.5"
Expand All @@ -53,13 +53,13 @@ runner = "1.5.2"

startupRuntime = "1.1.1"

workRuntimeKtx = "2.8.1"
workRuntimeKtx = "2.9.0"

windowsSizeClass = "1.1.2"
windowsSizeClass = "1.2.1"
adaptive = "0.26.2-beta"

kotest = "5.7.2"
espressoCore = "3.4.0"
espressoCore = "3.5.1"

[libraries]
androidx-ktx = { group = "androidx.core", name = "core-ktx", version.ref = "ktx" }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,11 @@ import androidx.compose.foundation.layout.padding
import androidx.compose.foundation.shape.RoundedCornerShape
import androidx.compose.material.icons.Icons
import androidx.compose.material.icons.filled.Delete
import androidx.compose.material3.DismissState
import androidx.compose.material3.DismissValue
import androidx.compose.material3.ExperimentalMaterial3Api
import androidx.compose.material3.Icon
import androidx.compose.material3.MaterialTheme
import androidx.compose.material3.SwipeToDismissBoxState
import androidx.compose.material3.SwipeToDismissBoxValue
import androidx.compose.runtime.Composable
import androidx.compose.runtime.getValue
import androidx.compose.ui.Alignment
Expand All @@ -27,10 +27,10 @@ import androidx.compose.ui.unit.dp

@OptIn(ExperimentalMaterial3Api::class)
@Composable
fun DismissBackgroundSwipe(modifier: Modifier, dismissState: DismissState) {
fun DismissBackgroundSwipe(modifier: Modifier, dismissState: SwipeToDismissBoxState) {
val color by animateColorAsState(
targetValue = when (dismissState.targetValue) {
DismissValue.DismissedToStart -> if (isSystemInDarkTheme()) {
SwipeToDismissBoxValue.EndToStart -> if (isSystemInDarkTheme()) {
MaterialTheme.colorScheme.errorContainer
} else {
Color.Red
Expand All @@ -42,7 +42,7 @@ fun DismissBackgroundSwipe(modifier: Modifier, dismissState: DismissState) {
)

val iconScale by animateFloatAsState(
targetValue = if (dismissState.targetValue == DismissValue.Default) 0.8f else 1.1f,
targetValue = if (dismissState.targetValue == SwipeToDismissBoxValue.StartToEnd) 0.8f else 1.1f,
label = "",
)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ fun FavoriteIcon(
keyframes {
durationMillis = 300
1f at 0
1.3f at 150 with FastOutSlowInEasing
1.3f at 150 using FastOutSlowInEasing
1f at 300
}
} else {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,15 +24,14 @@ import androidx.compose.foundation.shape.CircleShape
import androidx.compose.foundation.shape.RoundedCornerShape
import androidx.compose.material3.Card
import androidx.compose.material3.CardDefaults
import androidx.compose.material3.DismissDirection
import androidx.compose.material3.DismissValue
import androidx.compose.material3.ExperimentalMaterial3Api
import androidx.compose.material3.Icon
import androidx.compose.material3.MaterialTheme
import androidx.compose.material3.Surface
import androidx.compose.material3.SwipeToDismiss
import androidx.compose.material3.SwipeToDismissBoxValue
import androidx.compose.material3.Text
import androidx.compose.material3.rememberDismissState
import androidx.compose.material3.rememberSwipeToDismissBoxState
import androidx.compose.runtime.Composable
import androidx.compose.runtime.LaunchedEffect
import androidx.compose.runtime.getValue
Expand Down Expand Up @@ -74,9 +73,9 @@ fun MarketItem(
var show by remember {
mutableStateOf(true)
}
val dismissState = rememberDismissState(
val dismissState = rememberSwipeToDismissBoxState(
confirmValueChange = {
if (it == DismissValue.DismissedToStart) {
if (it == SwipeToDismissBoxValue.EndToStart) {
show = false
true
} else {
Expand All @@ -90,7 +89,7 @@ fun MarketItem(
AnimatedVisibility(visible = show, exit = fadeOut(spring())) {
SwipeToDismiss(
state = dismissState,
directions = setOf(DismissDirection.EndToStart),
directions = setOf(SwipeToDismissBoxValue.EndToStart),
background = {
DismissBackgroundSwipe(
modifier = Modifier,
Expand Down
Loading