The type variable value of { supports | rgb : Supported } is there because
CSS has so many overloaded values. For example, it's important that
display none and flex none both compile, yet whereas display block should
compile, flex block should not. Having open records in the type variables
for Value makes satisfying these overlapping constraints possible.
For convenience, there are type aliases for certain values which are often
reused. Color is one of these.
limeGreen : Css.Color
limeGreen =
rgb 0 100 44
This is structured like an opaque type but is fully exposed. This is so separate
CSS modules like Css.Media can integrate with this.
A value that can be passed to a CSS property.
The type variable value of
{ supports | rgb : Supported }is there because CSS has so many overloaded values. For example, it's important thatdisplay noneandflex noneboth compile, yet whereasdisplay blockshould compile,flex blockshould not. Having open records in the type variables forValuemakes satisfying these overlapping constraints possible.For convenience, there are type aliases for certain values which are often reused.
Coloris one of these.This is structured like an opaque type but is fully exposed. This is so separate CSS modules like
Css.Mediacan integrate with this.