Browse Source

web (breaking change): move `combine` and `feature` functions to GenericStyleSheetBuilder scope (in CSSMediaRule.kt) (#1508)

Co-authored-by: Oleksandr Karpovich <oleksandr.karpovich@jetbrains.com>
pull/1504/head
Oleksandr Karpovich 3 years ago committed by GitHub
parent
commit
4623985462
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 4
      web/core/src/jsMain/kotlin/org/jetbrains/compose/web/css/CSSMediaRule.kt

4
web/core/src/jsMain/kotlin/org/jetbrains/compose/web/css/CSSMediaRule.kt

@ -97,7 +97,7 @@ inline fun <TBuilder> GenericStyleSheetBuilder<TBuilder>.media(
media(feature(name, value), rulesBuild)
}
fun feature(
fun <TBuilder> GenericStyleSheetBuilder<TBuilder>.feature(
name: String,
value: StylePropertyValue? = null
) = CSSMediaQuery.MediaFeature(name, value)
@ -110,7 +110,7 @@ inline fun <TBuilder> GenericStyleSheetBuilder<TBuilder>.media(
media(combine(*mediaList), rulesBuild)
}
fun combine(
fun <TBuilder> GenericStyleSheetBuilder<TBuilder>.combine(
vararg mediaList: CSSMediaQuery
) = CSSMediaQuery.Combine(mediaList.toMutableList())

Loading…
Cancel
Save