Skip to content

Commit

Permalink
build: compose 1.7 and kotlin 2.0
Browse files Browse the repository at this point in the history
  • Loading branch information
oxyroid committed May 26, 2024
1 parent 4cb7a44 commit 6f74e04
Show file tree
Hide file tree
Showing 22 changed files with 296 additions and 235 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -19,3 +19,4 @@ local.properties
jks.txt
*.jks
/sample/
/.kotlin
2 changes: 0 additions & 2 deletions androidApp/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,4 @@ dependencies {
implementation(libs.androidx.hilt.work)

debugImplementation(libs.squareup.leakcanary)

implementation(libs.androidx.compose.material3.adaptive)
}
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ internal fun RemoteControlSheet(
if (visible) {
ModalBottomSheet(
sheetState = sheetState,
windowInsets = WindowInsets(0),
// windowInsets = WindowInsets(0),
onDismissRequest = {
if (!searchingOrConnecting) onDismissRequest()
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import androidx.compose.foundation.shape.RoundedCornerShape
import androidx.compose.material.icons.Icons
import androidx.compose.material.icons.rounded.ArrowBackIosNew
import androidx.compose.material.icons.rounded.Delete
import androidx.compose.material.ripple.rememberRipple
import androidx.compose.material3.ripple
import com.m3u.material.components.Icon
import androidx.compose.material3.MaterialTheme
import androidx.compose.material3.Text
Expand Down Expand Up @@ -111,7 +111,7 @@ internal fun VirtualNumberKeyboard(
)
}
},
indication = rememberRipple(color = MaterialTheme.colorScheme.primary),
indication = ripple(color = MaterialTheme.colorScheme.primary),
interactionSource = remember { MutableInteractionSource() }
),
horizontalAlignment = Alignment.CenterHorizontally,
Expand Down Expand Up @@ -139,7 +139,7 @@ internal fun VirtualNumberKeyboard(
onCode("")
}
},
indication = rememberRipple(color = MaterialTheme.colorScheme.primary),
indication = ripple(color = MaterialTheme.colorScheme.primary),
interactionSource = remember { MutableInteractionSource() }
),
horizontalAlignment = Alignment.CenterHorizontally,
Expand Down
2 changes: 1 addition & 1 deletion features/playlist/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ dependencies {
implementation(libs.androidx.core.ktx)

// for m2 BackdropScaffold only
implementation("androidx.compose.material:material:${libs.versions.androidx.compose}")
implementation("androidx.compose.material:material")

implementation(libs.androidx.lifecycle.runtime.ktx)
implementation(libs.androidx.lifecycle.runtime.compose)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -347,7 +347,7 @@ class PlaylistViewModel @Inject constructor(
)

@OptIn(FlowPreview::class)
private val categories = flatmapCombined(playlistUrl, query) { playlistUrl, query ->
private val categories: Flow<List<String>> = flatmapCombined(playlistUrl, query) { playlistUrl, query ->
playlistRepository.observeCategoriesByPlaylistUrlIgnoreHidden(playlistUrl, query)
}
.let { flow ->
Expand All @@ -360,8 +360,7 @@ class PlaylistViewModel @Inject constructor(
internal val channels: StateFlow<List<Channel>> = combine(
playlistUrl,
categories,
query,
sort
query, sort
) { playlistUrl, categories, query, sort ->
ChannelParameters(
playlistUrl = playlistUrl,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,13 +25,13 @@ import androidx.compose.material.icons.Icons
import androidx.compose.material.icons.rounded.Menu
import androidx.compose.material.icons.rounded.PushPin
import androidx.compose.material.icons.rounded.VisibilityOff
import androidx.compose.material.ripple.rememberRipple
import androidx.compose.material3.Card
import androidx.compose.material3.CardDefaults
import androidx.compose.material3.HorizontalDivider
import androidx.compose.material3.LocalContentColor
import androidx.compose.material3.MaterialTheme
import androidx.compose.material3.Text
import androidx.compose.material3.ripple
import androidx.compose.runtime.Composable
import androidx.compose.runtime.CompositionLocalProvider
import androidx.compose.runtime.LaunchedEffect
Expand Down Expand Up @@ -213,7 +213,7 @@ private fun PlaylistTabRowItem(
}
)
) {
val indication = if (hasOtherFocused) null else rememberRipple()
val indication = if (hasOtherFocused) null else ripple()
val shape = if (isExpanded) RectangleShape
else RoundedCornerShape(topStart = 12.dp, topEnd = 12.dp)
Card(
Expand Down
2 changes: 2 additions & 0 deletions features/setting/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -60,4 +60,6 @@ dependencies {
implementation(libs.androidx.hilt.work)

implementation(libs.androidx.compose.material3.adaptive)
implementation(libs.androidx.compose.material3.adaptive.navigation)
implementation(libs.androidx.compose.material3.adaptive.layout)
}
Loading

0 comments on commit 6f74e04

Please sign in to comment.