Skip to content

Commit

Permalink
[All] Update to Compose 1.1.1 (#743)
Browse files Browse the repository at this point in the history
* [All] Update to Compose 1.1.1

This also updates spotless to 6.3, ktlint to 0.44.0, and some other
minor/bugfix library updates.

* Updated accompanist and material libraries

* Updated material3 to 1.0.0-alpha06

* Disabled CityMapViewTests

Co-authored-by: Ian G. Clifton <IanGClifton@users.noreply.github.com>
  • Loading branch information
IanGClifton and IanGClifton authored Mar 1, 2022
1 parent 304f0db commit ce62e3f
Show file tree
Hide file tree
Showing 17 changed files with 58 additions and 59 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -33,13 +33,15 @@ import dagger.hilt.android.testing.HiltAndroidTest
import junit.framework.TestCase.assertEquals
import junit.framework.TestCase.assertTrue
import org.junit.Before
import org.junit.Ignore
import org.junit.Rule
import org.junit.Test
import java.util.concurrent.CountDownLatch
import java.util.concurrent.TimeUnit
import javax.inject.Inject
import kotlin.math.pow

@Ignore("To be fixed in https://github.com/android/compose-samples/issues/746")
@HiltAndroidTest
class CityMapViewTests {
@Inject
Expand Down
2 changes: 1 addition & 1 deletion Crane/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ buildscript {
}

plugins {
id 'com.diffplug.spotless' version '6.2.0'
id 'com.diffplug.spotless' version '6.3.0'
}

subprojects {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,11 @@
package com.example.crane.buildsrc

object Versions {
const val ktLint = "0.43.2"
const val ktLint = "0.44.0"
}

object Libs {
const val androidGradlePlugin = "com.android.tools.build:gradle:7.1.1"
const val androidGradlePlugin = "com.android.tools.build:gradle:7.1.2"
const val ktLint = "com.pinterest:ktlint:${Versions.ktLint}"

object GoogleMaps {
Expand All @@ -34,7 +34,7 @@ object Libs {
}

object Accompanist {
const val version = "0.23.0"
const val version = "0.23.1"
const val insets = "com.google.accompanist:accompanist-insets:$version"
}

Expand All @@ -60,7 +60,7 @@ object Libs {

object Compose {
const val snapshot = ""
const val version = "1.1.0"
const val version = "1.1.1"

const val runtime = "androidx.compose.runtime:runtime:$version"
const val runtimeLivedata = "androidx.compose.runtime:runtime-livedata:$version"
Expand All @@ -75,7 +75,7 @@ object Libs {
}

object Lifecycle {
private const val version = "2.4.0"
private const val version = "2.4.1"
const val viewModelCompose = "androidx.lifecycle:lifecycle-viewmodel-compose:$version"
const val viewModelKtx = "androidx.lifecycle:lifecycle-viewmodel-ktx:$version"
}
Expand Down
10 changes: 5 additions & 5 deletions JetNews/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -112,12 +112,12 @@ dependencies {
implementation 'androidx.core:core-ktx:1.7.0'
implementation "androidx.activity:activity-compose:1.4.0"

implementation "androidx.lifecycle:lifecycle-viewmodel-ktx:2.4.0"
implementation "androidx.lifecycle:lifecycle-viewmodel-savedstate:2.4.0"
implementation "androidx.lifecycle:lifecycle-livedata-ktx:2.4.0"
implementation "androidx.lifecycle:lifecycle-viewmodel-compose:2.4.0"
implementation "androidx.lifecycle:lifecycle-viewmodel-ktx:2.4.1"
implementation "androidx.lifecycle:lifecycle-viewmodel-savedstate:2.4.1"
implementation "androidx.lifecycle:lifecycle-livedata-ktx:2.4.1"
implementation "androidx.lifecycle:lifecycle-viewmodel-compose:2.4.1"

implementation 'androidx.navigation:navigation-compose:2.4.0'
implementation 'androidx.navigation:navigation-compose:2.4.1'

implementation "androidx.window:window:1.0.0"

Expand Down
10 changes: 5 additions & 5 deletions JetNews/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -16,23 +16,23 @@

buildscript {
ext.kotlin_version = '1.6.10'
ext.compose_version = '1.1.0'
ext.compose_version = '1.1.1'
ext.coroutines_version = '1.6.0'
ext.accompanist_version = '0.23.0'
ext.accompanist_version = '0.23.1'

repositories {
google()
mavenCentral()
}

dependencies {
classpath 'com.android.tools.build:gradle:7.1.0'
classpath 'com.android.tools.build:gradle:7.1.2'
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
}
}

plugins {
id 'com.diffplug.spotless' version '6.2.0'
id 'com.diffplug.spotless' version '6.3.0'
}

subprojects {
Expand All @@ -48,7 +48,7 @@ subprojects {
targetExclude("$buildDir/**/*.kt")
targetExclude('bin/**/*.kt')

ktlint("0.43.2")
ktlint("0.44.0")
licenseHeaderFile rootProject.file('spotless/copyright.kt')
}
}
Expand Down
2 changes: 1 addition & 1 deletion Jetcaster/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ buildscript {
}

plugins {
id 'com.diffplug.spotless' version '6.2.0'
id 'com.diffplug.spotless' version '6.3.0'
}

subprojects {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,15 +17,15 @@
package com.example.jetcaster.buildsrc

object Versions {
const val ktlint = "0.43.2"
const val ktlint = "0.44.0"
}

object Libs {
const val androidGradlePlugin = "com.android.tools.build:gradle:7.1.0"
const val androidGradlePlugin = "com.android.tools.build:gradle:7.1.2"
const val jdkDesugar = "com.android.tools:desugar_jdk_libs:1.1.5"

object Accompanist {
const val version = "0.23.0"
const val version = "0.23.1"
const val insets = "com.google.accompanist:accompanist-insets:$version"
const val pager = "com.google.accompanist:accompanist-pager:$version"
}
Expand Down Expand Up @@ -71,7 +71,7 @@ object Libs {

object Compose {
const val snapshot = ""
const val version = "1.1.0"
const val version = "1.1.1"

@get:JvmStatic
val snapshotUrl: String
Expand All @@ -90,14 +90,14 @@ object Libs {
}

object Lifecycle {
private const val version = "2.4.0"
private const val version = "2.4.1"
const val runtime = "androidx.lifecycle:lifecycle-runtime-ktx:$version"
const val viewModelCompose = "androidx.lifecycle:lifecycle-viewmodel-compose:$version"
const val viewmodel = "androidx.lifecycle:lifecycle-viewmodel-ktx:$version"
}

object Navigation {
const val navigation = "androidx.navigation:navigation-compose:2.4.0"
const val navigation = "androidx.navigation:navigation-compose:2.4.1"
}

object Test {
Expand All @@ -114,7 +114,7 @@ object Libs {
}

object Room {
private const val version = "2.4.0"
private const val version = "2.4.2"
const val runtime = "androidx.room:room-runtime:${version}"
const val ktx = "androidx.room:room-ktx:${version}"
const val compiler = "androidx.room:room-compiler:${version}"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ package com.example.compose.jetchat.components
import androidx.compose.material3.DrawerState
import androidx.compose.material3.DrawerValue.Closed
import androidx.compose.material3.ExperimentalMaterial3Api
import androidx.compose.material3.NavigationDrawer
import androidx.compose.material3.ModalNavigationDrawer
import androidx.compose.material3.rememberDrawerState
import androidx.compose.runtime.Composable
import com.example.compose.jetchat.theme.JetchatTheme
Expand All @@ -33,7 +33,7 @@ fun JetchatScaffold(
content: @Composable () -> Unit
) {
JetchatTheme {
NavigationDrawer(
ModalNavigationDrawer(
drawerState = drawerState,
drawerContent = {
JetchatDrawer(
Expand Down
2 changes: 1 addition & 1 deletion Jetchat/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ buildscript {
}

plugins {
id 'com.diffplug.spotless' version '6.2.0'
id 'com.diffplug.spotless' version '6.3.0'
}

subprojects {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,19 +17,19 @@
package com.example.compose.jetchat.buildsrc

object Versions {
const val ktlint = "0.43.2"
const val ktlint = "0.44.0"
}

object Libs {
const val androidGradlePlugin = "com.android.tools.build:gradle:7.1.0"
const val androidGradlePlugin = "com.android.tools.build:gradle:7.1.2"
const val jdkDesugar = "com.android.tools:desugar_jdk_libs:1.1.5"

const val junit = "junit:junit:4.13"

const val material3 = "com.google.android.material:material:1.5.0-rc01"
const val material3 = "com.google.android.material:material:1.6.0-alpha02"

object Accompanist {
const val version = "0.23.0"
const val version = "0.23.1"
const val insets = "com.google.accompanist:accompanist-insets:$version"
}

Expand Down Expand Up @@ -57,7 +57,7 @@ object Libs {

object Compose {
const val snapshot = ""
const val version = "1.1.0"
const val version = "1.1.1"

const val foundation = "androidx.compose.foundation:foundation:$version"
const val layout = "androidx.compose.foundation:foundation-layout:$version"
Expand All @@ -75,14 +75,14 @@ object Libs {

object Material3 {
const val snapshot = ""
const val version = "1.0.0-alpha04"
const val version = "1.0.0-alpha06"

const val material3 = "androidx.compose.material3:material3:$version"
}
}

object Navigation {
private const val version = "2.4.0"
private const val version = "2.4.1"
const val fragment = "androidx.navigation:navigation-fragment-ktx:$version"
const val uiKtx = "androidx.navigation:navigation-ui-ktx:$version"
}
Expand All @@ -101,7 +101,7 @@ object Libs {
}

object Lifecycle {
private const val version = "2.4.0"
private const val version = "2.4.1"
const val extensions = "androidx.lifecycle:lifecycle-extensions:$version"
const val livedata = "androidx.lifecycle:lifecycle-livedata-ktx:$version"
const val viewmodel = "androidx.lifecycle:lifecycle-viewmodel-ktx:$version"
Expand Down
2 changes: 1 addition & 1 deletion Jetsnack/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ buildscript {
}

plugins {
id 'com.diffplug.spotless' version '6.2.0'
id 'com.diffplug.spotless' version '6.3.0'
}

subprojects {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,14 +17,14 @@
package com.example.jetsnack.buildsrc

object Versions {
const val ktlint = "0.43.2"
const val ktlint = "0.44.0"
}

object Libs {
const val androidGradlePlugin = "com.android.tools.build:gradle:7.1.0"
const val androidGradlePlugin = "com.android.tools.build:gradle:7.1.2"

object Accompanist {
const val version = "0.23.0"
const val version = "0.23.1"
const val insets = "com.google.accompanist:accompanist-insets:$version"
const val systemuicontroller = "com.google.accompanist:accompanist-systemuicontroller:$version"
const val flowlayouts = "com.google.accompanist:accompanist-flowlayout:$version"
Expand All @@ -49,7 +49,7 @@ object Libs {

object Compose {
const val snapshot = ""
const val version = "1.1.0"
const val version = "1.1.1"

const val foundation = "androidx.compose.foundation:foundation:${version}"
const val layout = "androidx.compose.foundation:foundation-layout:${version}"
Expand All @@ -69,11 +69,11 @@ object Libs {
}

object Lifecycle {
const val viewModelCompose = "androidx.lifecycle:lifecycle-viewmodel-compose:2.4.0"
const val viewModelCompose = "androidx.lifecycle:lifecycle-viewmodel-compose:2.4.1"
}

object Navigation {
const val navigationCompose = "androidx.navigation:navigation-compose:2.4.0"
const val navigationCompose = "androidx.navigation:navigation-compose:2.4.1"
}

object ConstraintLayout {
Expand Down
1 change: 0 additions & 1 deletion Jetsurvey/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,6 @@ dependencies {
implementation Libs.AndroidX.Navigation.fragment
implementation Libs.AndroidX.Navigation.uiKtx
implementation Libs.AndroidX.Material.material
implementation Libs.material

implementation Libs.AndroidX.Lifecycle.viewmodel
implementation Libs.AndroidX.Lifecycle.viewModelCompose
Expand Down
2 changes: 1 addition & 1 deletion Jetsurvey/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ buildscript {
}

plugins {
id 'com.diffplug.spotless' version '6.2.0'
id 'com.diffplug.spotless' version '6.3.0'
}

subprojects {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,19 +17,17 @@
package com.example.compose.jetsurvey.buildsrc

object Versions {
const val ktlint = "0.43.2"
const val ktlint = "0.44.0"
}

object Libs {
const val androidGradlePlugin = "com.android.tools.build:gradle:7.1.0"
const val androidGradlePlugin = "com.android.tools.build:gradle:7.1.2"
const val jdkDesugar = "com.android.tools:desugar_jdk_libs:1.1.5"

const val junit = "junit:junit:4.13"

const val material = "com.google.android.material:material:1.3.0"

object Accompanist {
const val version = "0.23.0"
const val version = "0.23.1"
const val permissions = "com.google.accompanist:accompanist-permissions:$version"
}

Expand All @@ -52,7 +50,7 @@ object Libs {
const val coreKtx = "androidx.core:core-ktx:1.7.0"

object Lifecycle {
private const val version = "2.4.0"
private const val version = "2.4.1"
const val viewModelCompose = "androidx.lifecycle:lifecycle-viewmodel-compose:$version"
const val viewmodel = "androidx.lifecycle:lifecycle-viewmodel-ktx:$version"
}
Expand All @@ -63,7 +61,7 @@ object Libs {

object Compose {
const val snapshot = ""
const val version = "1.1.0"
const val version = "1.1.1"

@get:JvmStatic
val snapshotUrl: String
Expand All @@ -82,13 +80,13 @@ object Libs {
}

object Navigation {
private const val version = "2.4.0"
private const val version = "2.4.1"
const val fragment = "androidx.navigation:navigation-fragment-ktx:$version"
const val uiKtx = "androidx.navigation:navigation-ui-ktx:$version"
}

object Material {
private const val version = "1.3.0"
private const val version = "1.6.0-alpha02"
const val material = "com.google.android.material:material:$version"
}

Expand Down
Loading

0 comments on commit ce62e3f

Please sign in to comment.