diff --git a/build.gradle.kts b/build.gradle.kts index 9193f9e..9a23b50 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -1,5 +1,5 @@ plugins { - kotlin("multiplatform") version "1.5.31" + kotlin("multiplatform") version "1.6.10" `maven-publish` signing id("org.jetbrains.dokka") version "1.5.31" @@ -7,11 +7,10 @@ } group = "nl.astraeus" -version = "1.0.5-SNAPSHOT" +version = "1.0.6" repositories { mavenCentral() - maven { setUrl("https://dl.bintray.com/kotlin/kotlin-eap") } } kotlin { diff --git a/build.gradle.kts b/build.gradle.kts index 9193f9e..9a23b50 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -1,5 +1,5 @@ plugins { - kotlin("multiplatform") version "1.5.31" + kotlin("multiplatform") version "1.6.10" `maven-publish` signing id("org.jetbrains.dokka") version "1.5.31" @@ -7,11 +7,10 @@ } group = "nl.astraeus" -version = "1.0.5-SNAPSHOT" +version = "1.0.6" repositories { mavenCentral() - maven { setUrl("https://dl.bintray.com/kotlin/kotlin-eap") } } kotlin { diff --git a/settings.gradle.kts b/settings.gradle.kts index a22324a..09b3ea5 100644 --- a/settings.gradle.kts +++ b/settings.gradle.kts @@ -1,7 +1,5 @@ pluginManagement { repositories { - maven { setUrl("https://dl.bintray.com/kotlin/kotlin-eap") } - mavenCentral() maven { setUrl("https://plugins.gradle.org/m2/") } diff --git a/build.gradle.kts b/build.gradle.kts index 9193f9e..9a23b50 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -1,5 +1,5 @@ plugins { - kotlin("multiplatform") version "1.5.31" + kotlin("multiplatform") version "1.6.10" `maven-publish` signing id("org.jetbrains.dokka") version "1.5.31" @@ -7,11 +7,10 @@ } group = "nl.astraeus" -version = "1.0.5-SNAPSHOT" +version = "1.0.6" repositories { mavenCentral() - maven { setUrl("https://dl.bintray.com/kotlin/kotlin-eap") } } kotlin { diff --git a/settings.gradle.kts b/settings.gradle.kts index a22324a..09b3ea5 100644 --- a/settings.gradle.kts +++ b/settings.gradle.kts @@ -1,7 +1,5 @@ pluginManagement { repositories { - maven { setUrl("https://dl.bintray.com/kotlin/kotlin-eap") } - mavenCentral() maven { setUrl("https://plugins.gradle.org/m2/") } diff --git a/src/commonMain/kotlin/nl/astraeus/css/style/CssFunctions.kt b/src/commonMain/kotlin/nl/astraeus/css/style/CssFunctions.kt deleted file mode 100644 index e49c1d4..0000000 --- a/src/commonMain/kotlin/nl/astraeus/css/style/CssFunctions.kt +++ /dev/null @@ -1,11 +0,0 @@ -package nl.astraeus.css.style - -import nl.astraeus.css.properties.Color - -object CssFunctions { - - fun darken(color: Color, percentage: Int): Color { - return color - } - -} diff --git a/build.gradle.kts b/build.gradle.kts index 9193f9e..9a23b50 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -1,5 +1,5 @@ plugins { - kotlin("multiplatform") version "1.5.31" + kotlin("multiplatform") version "1.6.10" `maven-publish` signing id("org.jetbrains.dokka") version "1.5.31" @@ -7,11 +7,10 @@ } group = "nl.astraeus" -version = "1.0.5-SNAPSHOT" +version = "1.0.6" repositories { mavenCentral() - maven { setUrl("https://dl.bintray.com/kotlin/kotlin-eap") } } kotlin { diff --git a/settings.gradle.kts b/settings.gradle.kts index a22324a..09b3ea5 100644 --- a/settings.gradle.kts +++ b/settings.gradle.kts @@ -1,7 +1,5 @@ pluginManagement { repositories { - maven { setUrl("https://dl.bintray.com/kotlin/kotlin-eap") } - mavenCentral() maven { setUrl("https://plugins.gradle.org/m2/") } diff --git a/src/commonMain/kotlin/nl/astraeus/css/style/CssFunctions.kt b/src/commonMain/kotlin/nl/astraeus/css/style/CssFunctions.kt deleted file mode 100644 index e49c1d4..0000000 --- a/src/commonMain/kotlin/nl/astraeus/css/style/CssFunctions.kt +++ /dev/null @@ -1,11 +0,0 @@ -package nl.astraeus.css.style - -import nl.astraeus.css.properties.Color - -object CssFunctions { - - fun darken(color: Color, percentage: Int): Color { - return color - } - -} diff --git a/src/commonMain/kotlin/nl/astraeus/css/style/Style.kt b/src/commonMain/kotlin/nl/astraeus/css/style/Style.kt index 74079ae..28d440c 100644 --- a/src/commonMain/kotlin/nl/astraeus/css/style/Style.kt +++ b/src/commonMain/kotlin/nl/astraeus/css/style/Style.kt @@ -222,7 +222,7 @@ if (css.isNotBlank()) { val builder = StringBuilder() - check (allowCommaInSelector || !name.contains(',')) { + check (allowCommaInSelector || (name.indexOf(',') == -1)) { "Comma is not allowed in selector (option is set in generateCss call)" } @@ -862,6 +862,10 @@ props["content"] = prp(content) } + fun content(content: String) { + props["content"] = prp(content) + } + fun counterIncrement(increment: String) { props["counter-increment"] = prp(increment) } @@ -1610,6 +1614,8 @@ addStyle("::${selector.description()}", style) } + fun not(name: DescriptionProvider): DescriptionProvider = ValueDescriptionProvider(":not(${name.description()})") + @Deprecated("Use select(not(...)) instead.") fun not(selector: DescriptionProvider, style: Css) { addStyle(":not(${selector.description()})", style) } diff --git a/build.gradle.kts b/build.gradle.kts index 9193f9e..9a23b50 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -1,5 +1,5 @@ plugins { - kotlin("multiplatform") version "1.5.31" + kotlin("multiplatform") version "1.6.10" `maven-publish` signing id("org.jetbrains.dokka") version "1.5.31" @@ -7,11 +7,10 @@ } group = "nl.astraeus" -version = "1.0.5-SNAPSHOT" +version = "1.0.6" repositories { mavenCentral() - maven { setUrl("https://dl.bintray.com/kotlin/kotlin-eap") } } kotlin { diff --git a/settings.gradle.kts b/settings.gradle.kts index a22324a..09b3ea5 100644 --- a/settings.gradle.kts +++ b/settings.gradle.kts @@ -1,7 +1,5 @@ pluginManagement { repositories { - maven { setUrl("https://dl.bintray.com/kotlin/kotlin-eap") } - mavenCentral() maven { setUrl("https://plugins.gradle.org/m2/") } diff --git a/src/commonMain/kotlin/nl/astraeus/css/style/CssFunctions.kt b/src/commonMain/kotlin/nl/astraeus/css/style/CssFunctions.kt deleted file mode 100644 index e49c1d4..0000000 --- a/src/commonMain/kotlin/nl/astraeus/css/style/CssFunctions.kt +++ /dev/null @@ -1,11 +0,0 @@ -package nl.astraeus.css.style - -import nl.astraeus.css.properties.Color - -object CssFunctions { - - fun darken(color: Color, percentage: Int): Color { - return color - } - -} diff --git a/src/commonMain/kotlin/nl/astraeus/css/style/Style.kt b/src/commonMain/kotlin/nl/astraeus/css/style/Style.kt index 74079ae..28d440c 100644 --- a/src/commonMain/kotlin/nl/astraeus/css/style/Style.kt +++ b/src/commonMain/kotlin/nl/astraeus/css/style/Style.kt @@ -222,7 +222,7 @@ if (css.isNotBlank()) { val builder = StringBuilder() - check (allowCommaInSelector || !name.contains(',')) { + check (allowCommaInSelector || (name.indexOf(',') == -1)) { "Comma is not allowed in selector (option is set in generateCss call)" } @@ -862,6 +862,10 @@ props["content"] = prp(content) } + fun content(content: String) { + props["content"] = prp(content) + } + fun counterIncrement(increment: String) { props["counter-increment"] = prp(increment) } @@ -1610,6 +1614,8 @@ addStyle("::${selector.description()}", style) } + fun not(name: DescriptionProvider): DescriptionProvider = ValueDescriptionProvider(":not(${name.description()})") + @Deprecated("Use select(not(...)) instead.") fun not(selector: DescriptionProvider, style: Css) { addStyle(":not(${selector.description()})", style) } diff --git a/src/commonTest/kotlin/nl/astraeus/css/TestCalcExpression.kt b/src/commonTest/kotlin/nl/astraeus/css/TestCalcExpression.kt index 65739cf..a01ef72 100644 --- a/src/commonTest/kotlin/nl/astraeus/css/TestCalcExpression.kt +++ b/src/commonTest/kotlin/nl/astraeus/css/TestCalcExpression.kt @@ -9,7 +9,6 @@ class TestCalcExpression { - @Test fun testCalcExpression() { val a = calc(10.px + 20.px - 5.em)