Update web components to kotlin 1.5 and the new version of Compose Core (with kotlin 1.5)

Co-authored-by: Oleksandr Karpovich <oleksandr.karpovich@jetbrains.com>
This commit is contained in:
Shagen Ogandzhanian
2021-05-24 11:20:11 +02:00
parent 6dd94e8edb
commit 4aa25306a4
3 changed files with 9 additions and 5 deletions

View File

@@ -1,7 +1,7 @@
import org.gradle.api.publish.PublishingExtension
plugins {
id("org.jetbrains.kotlin.multiplatform") version("1.4.32") apply(false)
id("org.jetbrains.kotlin.multiplatform") version("1.5.0") apply(false)
}
val COMPOSE_WEB_VERSION: String by project

View File

@@ -1,2 +1,2 @@
COMPOSE_CORE_VERSION = 0.0.8-SNAPSHOT
COMPOSE_WEB_VERSION = 0.0.9-SNAPSHOT
COMPOSE_CORE_VERSION = 0.0.10-SNAPSHOT
COMPOSE_WEB_VERSION = 0.0.10-SNAPSHOT

View File

@@ -7,7 +7,9 @@ import androidx.compose.web.renderComposableInBody
import kotlin.properties.ReadOnlyProperty
import kotlin.reflect.KProperty
internal class TestCase(val composable: @Composable () -> Unit) {
internal class TestCase {
lateinit var composable: @Composable () -> Unit
operator fun provideDelegate(
thisRef: Any,
property: KProperty<*>
@@ -21,7 +23,9 @@ internal class TestCase(val composable: @Composable () -> Unit) {
}
internal fun testCase(composable: @Composable () -> Unit): TestCase {
return TestCase(composable)
return TestCase().apply {
this.composable = composable
}
}
internal val testCases = mutableMapOf<String, TestCase>()