diff --git a/web/core/src/jsTest/kotlin/StaticComposableTests.kt b/web/core/src/jsTest/kotlin/StaticComposableTests.kt index 3c70c79da7..ee797b1f32 100644 --- a/web/core/src/jsTest/kotlin/StaticComposableTests.kt +++ b/web/core/src/jsTest/kotlin/StaticComposableTests.kt @@ -1,8 +1,6 @@ package org.jetbrains.compose.web.core.tests -import org.jetbrains.compose.web.css.Color import org.jetbrains.compose.web.css.Position -import org.jetbrains.compose.web.css.border import org.jetbrains.compose.web.css.bottom import org.jetbrains.compose.web.css.color import org.jetbrains.compose.web.css.left diff --git a/web/core/src/jsTest/kotlin/css/CSSBorderTests.kt b/web/core/src/jsTest/kotlin/css/CSSBorderTests.kt index 20b34d2dce..3166fba1c2 100644 --- a/web/core/src/jsTest/kotlin/css/CSSBorderTests.kt +++ b/web/core/src/jsTest/kotlin/css/CSSBorderTests.kt @@ -5,6 +5,7 @@ package org.jetbrains.compose.web.core.tests.css +import kotlinx.browser.window import org.jetbrains.compose.web.core.tests.runTest import org.jetbrains.compose.web.css.* import org.jetbrains.compose.web.dom.Div @@ -23,13 +24,21 @@ class CSSBorderTests { } assertEquals("1px solid red", (root.children[0] as HTMLElement).style.border) - root.children[1]?.let { - val el = it.unsafeCast() + (root.children[1] as HTMLElement).let { el -> assertEquals("green", el.style.getPropertyValue("border-color")) assertEquals("3px", el.style.getPropertyValue("border-width")) } } + @Test + fun borderThreeValues() = runTest { + composition { + Div({ style { border(3.px, LineStyle.Dotted, Color("green")) } }) + } + + assertEquals("3px dotted green", (root.children[0] as HTMLElement).style.border) + } + @Test fun borderRadius() = runTest { composition {