Skip to content

Commit

Permalink
Merge pull request #6 from ImaginativeShohag/dev
Browse files Browse the repository at this point in the history
Dev
  • Loading branch information
ImaginativeShohag authored Feb 10, 2022
2 parents 5b7b68f + ac648af commit b418e24
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 25 deletions.
2 changes: 1 addition & 1 deletion app/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ android {
minSdk = BuildConfigConst.minSdk
targetSdk = BuildConfigConst.targetSdk
versionCode = 1
versionName = "4.0.0.000000" // Major.Minor.Patch.YYMMDD
versionName = "4.0.0.220210" // Major.Minor.Patch.YYMMDD
vectorDrawables.useSupportLibrary = true

testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ import org.imaginativeworld.whynotcompose.repositories.MockData
fun SwipeRefreshScreen() {
val scope = rememberCoroutineScope()

val items = remember { mutableStateOf(MockData.dummyListItem.toMutableList()) }
val items = remember { mutableStateOf(MockData.dummyListItem) }

val isRefreshing = remember { mutableStateOf(false) }

Expand All @@ -80,11 +80,7 @@ fun SwipeRefreshScreen() {

delay(2000)

items.value = items.value.run {
shuffle()

toMutableList()
}
items.value = items.value.shuffled()

isRefreshing.value = false
}
Expand All @@ -96,7 +92,7 @@ fun SwipeRefreshScreen() {
@Composable
fun SwipeRefreshScreenSkeletonPreview() {
AppTheme {
val items = remember { mutableStateOf(MockData.dummyListItem.toMutableList()) }
val items = remember { mutableStateOf(MockData.dummyListItem) }

SwipeRefreshScreenSkeleton(
items = items.value,
Expand All @@ -108,7 +104,7 @@ fun SwipeRefreshScreenSkeletonPreview() {
@Composable
fun SwipeRefreshScreenSkeletonPreviewDark() {
AppTheme {
val items = remember { mutableStateOf(MockData.dummyListItem.toMutableList()) }
val items = remember { mutableStateOf(MockData.dummyListItem) }

SwipeRefreshScreenSkeleton(
items = items.value,
Expand Down Expand Up @@ -156,10 +152,10 @@ fun SwipeRefreshScreenSkeleton(
.fillMaxSize(),
contentPadding = PaddingValues(start = 16.dp, end = 16.dp, bottom = 8.dp)
) {
items(items) { item ->

items(items, key = { it.id }) { item ->
ListItem(
modifier = Modifier
.animateItemPlacement()
.padding(top = 8.dp)
.background(
color = MaterialTheme.colors.onBackground.copy(alpha = .1f),
Expand Down
2 changes: 1 addition & 1 deletion build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ buildscript {
}

plugins {
id("com.diffplug.spotless") version "6.1.2"
id("com.diffplug.spotless") version "6.2.2"
}

subprojects {
Expand Down
27 changes: 14 additions & 13 deletions buildSrc/src/main/kotlin/Libs.kt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
object Libs {
const val androidGradlePlugin = "com.android.tools.build:gradle:7.2.0-beta01"
const val androidGradlePlugin = "com.android.tools.build:gradle:7.2.0-beta02"

const val secretsGradlePlugin =
"com.google.android.libraries.mapsplatform.secrets-gradle-plugin:secrets-gradle-plugin:2.0.0"
Expand All @@ -24,7 +24,7 @@ object Libs {
}

object Yalantis {
const val uCrop = "com.github.yalantis:ucrop:2.2.7"
const val uCrop = "com.github.yalantis:ucrop:2.2.8"
}

object Airbnb {
Expand All @@ -39,7 +39,7 @@ object Libs {
const val exoplayer = "com.google.android.exoplayer:exoplayer:2.16.1"

object Firebase {
const val bom = "com.google.firebase:firebase-bom:29.0.3"
const val bom = "com.google.firebase:firebase-bom:29.0.4"

const val analytics = "com.google.firebase:firebase-analytics-ktx"
}
Expand All @@ -57,7 +57,7 @@ object Libs {
}

object Accompanist {
private const val version = "0.22.1-rc"
private const val version = "0.23.0"

const val insets = "com.google.accompanist:accompanist-insets:$version"
const val systemuicontroller =
Expand Down Expand Up @@ -90,11 +90,12 @@ object Libs {
const val androidGradlePlugin = "com.google.dagger:hilt-android-gradle-plugin:$version"
const val core = "com.google.dagger:hilt-android:$version"
const val compiler = "com.google.dagger:hilt-compiler:$version"
const val navigationCompose = "androidx.hilt:hilt-navigation-compose:1.0.0-rc01"

const val navigationCompose = "androidx.hilt:hilt-navigation-compose:1.0.0"
}

object AndroidX {
const val appcompat = "androidx.appcompat:appcompat:1.4.0"
const val appcompat = "androidx.appcompat:appcompat:1.4.1"
const val coreKtx = "androidx.core:core-ktx:1.7.0"
const val swipeRefreshLayout = "androidx.swiperefreshlayout:swiperefreshlayout:1.1.0"

Expand All @@ -103,7 +104,7 @@ object Libs {
}

object Compose {
const val version = "1.1.0-rc03"
const val version = "1.1.0"
const val compilerVersion = version

const val compiler = "androidx.compose.compiler:compiler:$compilerVersion"
Expand Down Expand Up @@ -134,13 +135,13 @@ object Libs {
}

object ConstraintLayout {
private const val version = "1.0.0-rc02"
private const val version = "1.0.0"

const val compose = "androidx.constraintlayout:constraintlayout-compose:$version"
}

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"
Expand All @@ -151,7 +152,7 @@ object Libs {
}

object Navigation {
private const val version = "2.4.0-rc01"
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 @@ -167,7 +168,7 @@ object Libs {
}

object Room {
private const val version = "2.4.0"
private const val version = "2.4.1"

const val runtime = "androidx.room:room-runtime:$version"
const val compiler = "androidx.room:room-compiler:$version"
Expand All @@ -193,7 +194,7 @@ object Libs {
object OneSignal {
const val gradlePlugin = "gradle.plugin.com.onesignal:onesignal-gradle-plugin:0.14.0"

const val core = "com.onesignal:OneSignal:4.6.3"
const val core = "com.onesignal:OneSignal:4.6.7"
}

object Square {
Expand All @@ -204,7 +205,7 @@ object Libs {
const val converterMoshi = "com.squareup.retrofit2:converter-moshi:$version"
}

const val okhttpLoggingInterceptor = "com.squareup.okhttp3:logging-interceptor:4.9.1"
const val okhttpLoggingInterceptor = "com.squareup.okhttp3:logging-interceptor:4.9.3"

object Moshi {
private const val version = "1.13.0"
Expand Down

0 comments on commit b418e24

Please sign in to comment.