Skip to content

Commit

Permalink
Merge pull request #94 from bitfunk/feature/bump-dependencies
Browse files Browse the repository at this point in the history
Bump dependencies
  • Loading branch information
wmontwe authored Feb 20, 2023
2 parents d7407c0 + ba7e746 commit afe9bba
Show file tree
Hide file tree
Showing 87 changed files with 2,262 additions and 1,389 deletions.
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ build-cache/

# Others
captures/
kotlin-js-store

## OS X Finder
.DS_Store
34 changes: 19 additions & 15 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,37 +37,41 @@ See [changeset](https://github.com/wmontwe/blueprint-mobile-kmp/compare/v1.0.0..
### Bumped

- Android target API 31 -> 33
- Gradle 7.2 -> 7.5
- Android Gradle Plugin 7.1.0 -> 7.3.1
- Gradle 7.2 -> 8.0.1
- Android Gradle Plugin 7.1.0 -> 7.4.1
- Jetpack Compose 1.0.5 -> 1.3.1
- Jetpack Compose Compiler 1.0.5 -> 1.3.2
- Jetbrains Compose 1.0.1 -> 1.2.1
- AndroidX AppCompat 1.4.2 -> 1.5.1
- Jetpack Compose Compiler 1.0.5 -> 1.4.0
- Jetbrains Compose 1.0.1 -> 1.3.0
- AndroidX AppCompat 1.4.2 -> 1.6.1
- AndroidX CoreKtx 1.7.0 -> 1.9.0
- AndroidX Activity Compose 1.4.0 -> 1.6.1
- AndroidX Test 1.4.0 -> 1.5.0
- AndroidX Test Orchestrator 1.4.1 -> 1.4.2
- AndroidX Test Junit Ktx 1.1.3 -> 1.1.4
- AndroidX Test Espresso 3.4.0 -> 3.5.0
- Accompanist 0.20.3 -> 0.27.1
- Material 1.6.0-alpha01 -> 1.7.0
- Kotlin 1.6.10 -> 1.7.20
- AndroidX Test Junit Ktx 1.1.3 -> 1.1.5
- AndroidX Test Espresso 3.4.0 -> 3.5.1
- Accompanist 0.20.3 -> 0.28.1
- Material 1.6.0-alpha01 -> 1.8.0
- Kotlin 1.6.10 -> 1.8.0
- Kotlin Coroutines 1.6.0 -> 1.6.4
- AndroidX Compose UI 1.1.1 -> 1.2.1
- Kakaocup Compose 0.0.6 -> 0.2.0
- Material Compose 1.1.0-rc03 -> 1.3.1
- Material3 Compose 1.0.0-alpha04 -> 1.0.0-alpha14
- SqlDelight 1.5.3 -> 1.5.4
- Material3 Compose 1.0.0-alpha04 -> 1.0.1
- SqlDelight 1.5.3 -> 1.5.5
- Decompose 0.5.2 -> 0.8.0
- Ktor 1.6.2 -> 2.1.3
- Koin 3.1.4 -> 3.3.1
- Koin 3.1.4 -> 3.3.3
- Kotlin Serialization 1.2.2 -> 1.4.1
- Robolectric 4.5.1 -> 4.9
- Coil Compose 1.3.2 -> 2.2.2
- Android Desugar 1.0.9 -> 1.2.2
- Bitfunk Versioning 0.1.1 -> 0.1.2
- KakaoCup Compose 0.2.0 -> 0.2.1
- Bitfunk Versioning 0.1.1 -> 0.2.0
- KakaoCup Compose 0.2.0 -> 0.2.2
- MkDocs 2.4.0 -> 3.0.0
- Bitfunk Quality 0.1.1 -> 0.2.0
- Version Update 0.44.0 -> 0.45.0
- JUnit Jupiter 5.9.1 -> 5.9.2
- Android Desugar 1.2.2 -> 2.0.2

### Deprecated

Expand Down
6 changes: 3 additions & 3 deletions Dangerfile.df.kts
Original file line number Diff line number Diff line change
Expand Up @@ -66,23 +66,23 @@ danger(args) {
"\nrelease/1.2(.3)(/prepare-1.2.3)\n" +
"\nfeature/(ISSUE-123)/add|change|remove|fix|bump|security-feature-title\n" +
"\n\n" +
"\n Current name: $branchName"
"\n Current name: $branchName",
)
}

if (isFeatureBranch) {
if (!isFeatureTitle) {
fail(
"Title is not following our pattern:\n" +
"\n[issue_id](optional) Add|Change|Remove|Fix|Bump|Security {Feature title}"
"\n[issue_id](optional) Add|Change|Remove|Fix|Bump|Security {Feature title}",
)
}
}

if (isReleaseBranch) {
if (!isReleaseTitle) {
fail(
"Title is not following our pattern: Prepare Release major.minor.patch (1.2.0)"
"Title is not following our pattern: Prepare Release major.minor.patch (1.2.0)",
)
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ class MainActivity : ComponentActivity() {

private fun createRootComponent(componentContext: ComponentContext): RootComponentContract.Component {
return RootComponent(
componentContext = componentContext
componentContext = componentContext,
)
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ import eu.upwolf.mobile.blueprint.common.ui.theme.AppThemeMain

@Composable
fun MainApp(
content: @Composable () -> Unit
content: @Composable () -> Unit,
) {
ProvideWindowInsets(windowInsetsAnimationsEnabled = true) {
AppThemeMain {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ fun CounterUi(counter: Counter) {

Column {
Text(
text = state.count.toString()
text = state.count.toString(),
)

Button(onClick = counter::increment) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ import com.arkivanov.decompose.ComponentContext

class MainComponent(
componentContext: ComponentContext,
private val onBottomBarItem: () -> Unit
private val onBottomBarItem: () -> Unit,
) : MainContract, ComponentContext by componentContext {

override fun onBottomBarItemClicked() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,14 +28,14 @@ import androidx.compose.ui.Modifier
@Composable
fun MainContent(
main: MainContract,
modifier: Modifier = Modifier
modifier: Modifier = Modifier,
) {
Box(
modifier = modifier,
contentAlignment = Alignment.Center
contentAlignment = Alignment.Center,
) {
Button(
onClick = main::onBottomBarItemClicked
onClick = main::onBottomBarItemClicked,
) {
Text(text = "Go to Feature1")
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,37 +35,37 @@ import eu.upwolf.mobile.blueprint.common.ui.theme.AppTheme
@OptIn(ExperimentalMaterial3Api::class)
@Composable
fun AppScaffold(
content: @Composable (PaddingValues) -> Unit
content: @Composable (PaddingValues) -> Unit,
) {
// val navController = rememberNavController()

Scaffold(
topBar = {
TopAppBar(
contentPadding = rememberInsetsPaddingValues(
insets = LocalWindowInsets.current.statusBars
insets = LocalWindowInsets.current.statusBars,
),
backgroundColor = AppTheme.colorScheme.primary,
title = {
Text(
text = stringResource(id = R.string.app_name),
color = AppTheme.colorScheme.onPrimary
color = AppTheme.colorScheme.onPrimary,
)
}
},
)
},
content = content
content = content,
)
}

@Preview(
name = "Light preview",
showBackground = true
showBackground = true,
)
@Preview(
name = "Dark preview",
showBackground = true,
uiMode = Configuration.UI_MODE_NIGHT_YES
uiMode = Configuration.UI_MODE_NIGHT_YES,
)
@Composable
fun DefaultPreview() {
Expand Down
3 changes: 2 additions & 1 deletion app-android/src/main/res/mipmap-anydpi-v26/ic_launcher.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,5 @@
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
<background android:drawable="@color/ic_launcher_background"/>
<foreground android:drawable="@drawable/ic_launcher_foreground"/>
</adaptive-icon>
<monochrome android:drawable="@drawable/ic_launcher_foreground"/>
</adaptive-icon>
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,5 @@
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
<background android:drawable="@color/ic_launcher_background"/>
<foreground android:drawable="@drawable/ic_launcher_foreground"/>
</adaptive-icon>
<monochrome android:drawable="@drawable/ic_launcher_foreground"/>
</adaptive-icon>
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ fun main() {
Window(
onCloseRequest = ::exitApplication,
title = "Blueprint",
state = windowState
state = windowState,
) {
MainApp {
RootContent(root)
Expand All @@ -56,6 +56,6 @@ fun main() {

private fun createRootComponent(componentContext: ComponentContext): RootComponentContract.Component {
return RootComponent(
componentContext = componentContext
componentContext = componentContext,
)
}
Original file line number Diff line number Diff line change
Expand Up @@ -41,26 +41,26 @@ fun DesignSystem() {
val isDarkState = remember { mutableStateOf(false) }

AppThemeMain(
darkTheme = isDarkState.value
darkTheme = isDarkState.value,
) {
AppSurface(
modifier = Modifier.fillMaxSize()
modifier = Modifier.fillMaxSize(),
) {
Column(
modifier = Modifier
.padding(AppTheme.dimension.spacingDouble),
horizontalAlignment = Alignment.CenterHorizontally
horizontalAlignment = Alignment.CenterHorizontally,
) {
HeadlineLarge(if (isDarkState.value) "Theme is Dark" else "Theme is Light")

Spacer(
modifier = Modifier.height(AppTheme.dimension.spacingDouble)
modifier = Modifier.height(AppTheme.dimension.spacingDouble),
)

ThemeSwitch(isDarkState.value) { isDarkState.value = !isDarkState.value }

Spacer(
modifier = Modifier.height(AppTheme.dimension.spacingDouble)
modifier = Modifier.height(AppTheme.dimension.spacingDouble),
)

ThemeOverview()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ import androidx.compose.runtime.Composable
@Preview
@Composable
fun MainApp(
content: @Composable () -> Unit
content: @Composable () -> Unit,
) {
content()
}
4 changes: 2 additions & 2 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,8 @@ reportConfig {
coverageReportSourceDirs.set(
listOf(
"$projectDir/plugin-development/build/reports/jacoco/testCodeCoverageReport",
"$projectDir/plugins/build/reports/jacoco/testCodeCoverageReport"
)
"$projectDir/plugins/build/reports/jacoco/testCodeCoverageReport",
),
)
}

Expand Down
14 changes: 6 additions & 8 deletions common/database/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -42,15 +42,13 @@ kotlin {
implementation(libs.sqldelight.androidDriver)
}
}
androidTest {
dependencies {
implementation(libs.sqldelight.sqliteDriver)
}
val androidUnitTest = maybeCreate("androidUnitTest")
androidUnitTest.dependencies {
implementation(libs.sqldelight.sqliteDriver)
}
androidAndroidTest {
dependencies {
implementation(libs.sqldelight.androidDriver)
}
val androidInstrumentedTest = maybeCreate("androidInstrumentedTest")
androidInstrumentedTest.dependencies {
implementation(libs.sqldelight.androidDriver)
}

jvmMain {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,14 +23,14 @@ import com.squareup.sqldelight.android.AndroidSqliteDriver
import com.squareup.sqldelight.db.SqlDriver

actual class CommonDriverFactory(
private val context: Context
private val context: Context,
) : CommonDatabaseContract.DriverFactory {

actual override suspend fun createDriver(schema: SqlDriver.Schema): SqlDriver {
return AndroidSqliteDriver(
schema = schema,
context = context,
name = CommonDatabaseContract.DATABASE_NAME
name = CommonDatabaseContract.DATABASE_NAME,
)
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ import com.squareup.sqldelight.db.SqlDriver
// - add logger
// - add background dispatcher
class CommonDatabase(
private val driverProvider: suspend (SqlDriver.Schema) -> SqlDriver
private val driverProvider: suspend (SqlDriver.Schema) -> SqlDriver,
) : CommonDatabaseContract {

private var database: CommonSqlDatabase? = null
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ actual object CommonTestDriverFactory : CommonDatabaseContract.DriverFactory {
actual override suspend fun createDriver(schema: SqlDriver.Schema): SqlDriver {
return NativeSqliteDriver(
schema = schema,
name = CommonDatabaseContract.DATABASE_NAME
name = CommonDatabaseContract.DATABASE_NAME,
)
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -43,18 +43,18 @@ internal val LocalImageVectorCache = staticCompositionLocalOf<ImageVectorCache>

@Composable
fun ProvideImageVectorCache(
content: @Composable () -> Unit
content: @Composable () -> Unit,
) {
val context = LocalContext.current
var configuration by remember {
mutableStateOf(
context.resources.configuration,
neverEqualPolicy()
neverEqualPolicy(),
)
}
val imageVectorCache = obtainImageVectorCache(context, configuration)
CompositionLocalProvider(
LocalImageVectorCache provides imageVectorCache
LocalImageVectorCache provides imageVectorCache,
) {
content()
}
Expand All @@ -64,7 +64,7 @@ fun ProvideImageVectorCache(
@Composable
private fun obtainImageVectorCache(
context: Context,
configuration: Configuration?
configuration: Configuration?,
): ImageVectorCache {
val imageVectorCache = remember { ImageVectorCache() }
var currentConfiguration = remember { configuration }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ internal object AndroidVectorResources {
android.R.attr.autoMirrored,
android.R.attr.tintMode,
android.R.attr.viewportWidth,
android.R.attr.viewportHeight
android.R.attr.viewportHeight,
)
val STYLEABLE_VECTOR_DRAWABLE_VIEWPORT_HEIGHT = 8
val STYLEABLE_VECTOR_DRAWABLE_VIEWPORT_WIDTH = 7
Expand All @@ -42,7 +42,7 @@ internal object AndroidVectorResources {
android.R.attr.scaleY,
android.R.attr.rotation,
android.R.attr.translateX,
android.R.attr.translateY
android.R.attr.translateY,
)
val STYLEABLE_VECTOR_DRAWABLE_GROUP_NAME = 0
val STYLEABLE_VECTOR_DRAWABLE_GROUP_PIVOT_X = 1
Expand All @@ -69,7 +69,7 @@ internal object AndroidVectorResources {
android.R.attr.strokeAlpha,
android.R.attr.fillAlpha,
// android.R.attr.fillType is in API level 24+ use hardcoded value to extract the attribute if it exists
0x101051E
0x101051E,
)
val STYLEABLE_VECTOR_DRAWABLE_PATH_FILL_ALPHA = 12
val STYLEABLE_VECTOR_DRAWABLE_PATH_FILL_COLOR = 1
Expand Down
Loading

0 comments on commit afe9bba

Please sign in to comment.