77: Dependency updates r=msfjarvis a=msfjarvis

Updates Compose, Accompanist, browser, core-ktx and drops some now deprecated artifacts. Also fixes a navigation bug that caused backstack to pop indefinitely even when on the same screen.

bors r+

Co-authored-by: Harsh Shandilya <me@msfjarvis.dev>
This commit is contained in:
bors[bot] 2020-11-11 20:35:31 +00:00 committed by GitHub
commit 9eae76442f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 10 additions and 16 deletions

View file

@ -74,14 +74,11 @@ dependencies {
implementation(Dependencies.AndroidX.Compose.compiler) implementation(Dependencies.AndroidX.Compose.compiler)
implementation(Dependencies.AndroidX.Compose.foundation) implementation(Dependencies.AndroidX.Compose.foundation)
implementation(Dependencies.AndroidX.Compose.foundationLayout) implementation(Dependencies.AndroidX.Compose.foundationLayout)
implementation(Dependencies.AndroidX.Compose.foundationText)
implementation(Dependencies.AndroidX.Compose.material) implementation(Dependencies.AndroidX.Compose.material)
implementation(Dependencies.AndroidX.Compose.navigation) implementation(Dependencies.AndroidX.Compose.navigation)
implementation(Dependencies.AndroidX.Compose.runtime) implementation(Dependencies.AndroidX.Compose.runtime)
implementation(Dependencies.AndroidX.Compose.ui) implementation(Dependencies.AndroidX.Compose.ui)
implementation(Dependencies.AndroidX.Compose.uiTooling) implementation(Dependencies.AndroidX.Compose.uiTooling)
implementation(Dependencies.AndroidX.Compose.uiText)
implementation(Dependencies.AndroidX.Compose.uiTextAndroid)
implementation(Dependencies.AndroidX.Compose.uiUnit) implementation(Dependencies.AndroidX.Compose.uiUnit)
implementation(Dependencies.AndroidX.Hilt.dagger) implementation(Dependencies.AndroidX.Hilt.dagger)
implementation(Dependencies.AndroidX.Hilt.hiltLifecycleViewmodel) implementation(Dependencies.AndroidX.Hilt.hiltLifecycleViewmodel)

View file

@ -2,12 +2,12 @@ package dev.msfjarvis.lobsters.ui.main
import android.os.Bundle import android.os.Bundle
import androidx.appcompat.app.AppCompatActivity import androidx.appcompat.app.AppCompatActivity
import androidx.compose.foundation.Text
import androidx.compose.foundation.layout.padding import androidx.compose.foundation.layout.padding
import androidx.compose.foundation.lazy.rememberLazyListState import androidx.compose.foundation.lazy.rememberLazyListState
import androidx.compose.material.BottomNavigation import androidx.compose.material.BottomNavigation
import androidx.compose.material.BottomNavigationItem import androidx.compose.material.BottomNavigationItem
import androidx.compose.material.Scaffold import androidx.compose.material.Scaffold
import androidx.compose.material.Text
import androidx.compose.runtime.Composable import androidx.compose.runtime.Composable
import androidx.compose.runtime.Providers import androidx.compose.runtime.Providers
import androidx.compose.runtime.collectAsState import androidx.compose.runtime.collectAsState
@ -100,8 +100,8 @@ fun LobstersBottomNav(
selected = currentRoute == screen.route, selected = currentRoute == screen.route,
alwaysShowLabels = false, alwaysShowLabels = false,
onClick = { onClick = {
navController.popBackStack(navController.graph.startDestination, false)
if (currentRoute != screen.route) { if (currentRoute != screen.route) {
navController.popBackStack(navController.graph.startDestination, false)
navController.navigate(screen.route) navController.navigate(screen.route)
} }
} }

View file

@ -1,10 +1,10 @@
package dev.msfjarvis.lobsters.ui.posts package dev.msfjarvis.lobsters.ui.posts
import androidx.compose.foundation.Text
import androidx.compose.foundation.layout.Arrangement import androidx.compose.foundation.layout.Arrangement
import androidx.compose.foundation.layout.Column import androidx.compose.foundation.layout.Column
import androidx.compose.foundation.layout.fillMaxSize import androidx.compose.foundation.layout.fillMaxSize
import androidx.compose.foundation.layout.padding import androidx.compose.foundation.layout.padding
import androidx.compose.material.Text
import androidx.compose.runtime.Composable import androidx.compose.runtime.Composable
import androidx.compose.ui.Alignment import androidx.compose.ui.Alignment
import androidx.compose.ui.Modifier import androidx.compose.ui.Modifier

View file

@ -1,6 +1,5 @@
package dev.msfjarvis.lobsters.ui.posts package dev.msfjarvis.lobsters.ui.posts
import androidx.compose.foundation.Text
import androidx.compose.foundation.background import androidx.compose.foundation.background
import androidx.compose.foundation.clickable import androidx.compose.foundation.clickable
import androidx.compose.foundation.layout.Arrangement import androidx.compose.foundation.layout.Arrangement
@ -12,6 +11,7 @@ import androidx.compose.foundation.layout.width
import androidx.compose.foundation.lazy.LazyColumnFor import androidx.compose.foundation.lazy.LazyColumnFor
import androidx.compose.foundation.shape.RoundedCornerShape import androidx.compose.foundation.shape.RoundedCornerShape
import androidx.compose.material.Surface import androidx.compose.material.Surface
import androidx.compose.material.Text
import androidx.compose.material.ripple.RippleIndication import androidx.compose.material.ripple.RippleIndication
import androidx.compose.runtime.Composable import androidx.compose.runtime.Composable
import androidx.compose.ui.Modifier import androidx.compose.ui.Modifier

View file

@ -16,7 +16,7 @@
package dev.msfjarvis.lobsters.util package dev.msfjarvis.lobsters.util
import androidx.annotation.DrawableRes import androidx.annotation.DrawableRes
import androidx.compose.foundation.AmbientContentColor import androidx.compose.material.AmbientContentColor
import androidx.compose.material.Icon import androidx.compose.material.Icon
import androidx.compose.runtime.Composable import androidx.compose.runtime.Composable
import androidx.compose.ui.Modifier import androidx.compose.ui.Modifier

View file

@ -7,7 +7,7 @@ private const val ANDROIDX_HILT_VERSION = "1.0.0-alpha02"
private const val DAGGER_HILT_VERSION = "2.29.1-alpha" private const val DAGGER_HILT_VERSION = "2.29.1-alpha"
object Dependencies { object Dependencies {
const val COMPOSE_VERSION = "1.0.0-alpha06" const val COMPOSE_VERSION = "1.0.0-alpha07"
object Kotlin { object Kotlin {
object Coroutines { object Coroutines {
@ -38,8 +38,8 @@ object Dependencies {
const val activityKtx = "androidx.activity:activity-ktx:1.2.0-beta01" const val activityKtx = "androidx.activity:activity-ktx:1.2.0-beta01"
const val appCompat = "androidx.appcompat:appcompat:1.3.0-alpha02" const val appCompat = "androidx.appcompat:appcompat:1.3.0-alpha02"
const val browser = "androidx.browser:browser:1.3.0-beta01" const val browser = "androidx.browser:browser:1.3.0-rc01"
const val coreKtx = "androidx.core:core-ktx:1.5.0-alpha04" const val coreKtx = "androidx.core:core-ktx:1.5.0-alpha05"
const val coreLibraryDesugaring = "com.android.tools:desugar_jdk_libs:1.0.10" const val coreLibraryDesugaring = "com.android.tools:desugar_jdk_libs:1.0.10"
const val material = "com.google.android.material:material:1.3.0-alpha03" const val material = "com.google.android.material:material:1.3.0-alpha03"
@ -48,13 +48,10 @@ object Dependencies {
const val compiler = "androidx.compose.compiler:compiler:$COMPOSE_VERSION" const val compiler = "androidx.compose.compiler:compiler:$COMPOSE_VERSION"
const val foundation = "androidx.compose.foundation:foundation:$COMPOSE_VERSION" const val foundation = "androidx.compose.foundation:foundation:$COMPOSE_VERSION"
const val foundationLayout = "androidx.compose.foundation:foundation-layout:$COMPOSE_VERSION" const val foundationLayout = "androidx.compose.foundation:foundation-layout:$COMPOSE_VERSION"
const val foundationText = "androidx.compose.foundation:foundation-text:$COMPOSE_VERSION"
const val material = "androidx.compose.material:material:$COMPOSE_VERSION" const val material = "androidx.compose.material:material:$COMPOSE_VERSION"
const val navigation = "androidx.navigation:navigation-compose:1.0.0-alpha01" const val navigation = "androidx.navigation:navigation-compose:1.0.0-alpha02"
const val runtime = "androidx.compose.runtime:runtime:$COMPOSE_VERSION" const val runtime = "androidx.compose.runtime:runtime:$COMPOSE_VERSION"
const val ui = "androidx.compose.ui:ui:$COMPOSE_VERSION" const val ui = "androidx.compose.ui:ui:$COMPOSE_VERSION"
const val uiText = "androidx.compose.ui:ui-text:$COMPOSE_VERSION"
const val uiTextAndroid = "androidx.compose.ui:ui-text-android:$COMPOSE_VERSION"
const val uiUnit = "androidx.compose.ui:ui-unit:$COMPOSE_VERSION" const val uiUnit = "androidx.compose.ui:ui-unit:$COMPOSE_VERSION"
const val uiTooling = "androidx.ui:ui-tooling:$COMPOSE_VERSION" const val uiTooling = "androidx.ui:ui-tooling:$COMPOSE_VERSION"
} }
@ -85,7 +82,7 @@ object Dependencies {
object ThirdParty { object ThirdParty {
const val accompanist = "dev.chrisbanes.accompanist:accompanist-coil:0.3.2" const val accompanist = "dev.chrisbanes.accompanist:accompanist-coil:0.3.3.1"
const val customtabs = "saschpe.android:customtabs:3.0.2" const val customtabs = "saschpe.android:customtabs:3.0.2"
object Roomigrant { object Roomigrant {