package styled-ppx

  1. Overview
  2. Docs
Legend:
Library
Module
Module type
Parameter
Class
Class type
type rgb = int * int * int
type 'a calc_min_max = [
  1. | `calc of [ `add of 'a * 'a | `sub of 'a * 'a | `mult of 'a * 'a ]
  2. | `min of 'a array
  3. | `max of 'a array
]
type rgba = int * int * int * [ `num of float | Percentage.t | Percentage.t calc_min_max ]
type hsla = [ Angle.t | Angle.t calc_min_max ] * [ Percentage.t | Percentage.t calc_min_max ] * [ Percentage.t | Percentage.t calc_min_max ] * [ `num of float | `percent of float | Percentage.t calc_min_max ]
type 'a colorMix = ColorMixMethod.t * ('a * Percentage.t) * ('a * Percentage.t)
type t = [
  1. | `rgb of rgb
  2. | `colorMix of t colorMix
  3. | `rgba of rgba
  4. | `hsl of hsl
  5. | `hsla of hsla
  6. | `hex of string
  7. | `transparent
  8. | `currentColor
]
val rgb : 'a -> 'b -> 'c -> [> `rgb of 'a * 'b * 'c ]
val rgba : 'a -> 'b -> 'c -> 'd -> [> `rgba of 'a * 'b * 'c * 'd ]
val hsl : 'a -> 'b -> 'c -> [> `hsl of 'a * 'b * 'c ]
val hsla : 'a -> 'b -> 'c -> 'd -> [> `hsla of 'a * 'b * 'c * 'd ]
val hex : 'a -> [> `hex of 'a ]
val transparent : [> `transparent ]
val currentColor : [> `currentColor ]
val string_of_angle : [< `calc of [< `add of [< `deg of Js.Float.t | `grad of Js.Float.t | `rad of Js.Float.t | `turn of Js.Float.t ] as 'a * 'a | `mult of 'a * 'a | `sub of 'a * 'a ] | `deg of Js.Float.t | `grad of Js.Float.t | `max of 'a Belt.Array.t | `min of 'a Belt.Array.t | `rad of Js.Float.t | `turn of Js.Float.t ] -> string
val string_of_alpha : [< `calc of [< `add of [< `percent of Js.Float.t ] as 'a * 'a | `mult of 'a * 'a | `sub of 'a * 'a ] | `max of 'a Belt.Array.t | `min of 'a Belt.Array.t | `num of Js.Float.t | `percent of Js.Float.t ] -> string
val string_of_alpha' : [< `calc of [< `add of [< `percent of Js.Float.t ] as 'a * 'a | `mult of 'a * 'a | `sub of 'a * 'a ] | `max of 'a Belt.Array.t | `min of 'a Belt.Array.t | `percent of Js.Float.t ] -> string
val rgb_to_string : Js.Int.t -> Js.Int.t -> Js.Int.t -> string
val toString : [< `colorMix of [< `in1 of [< `a98Rgb | `displayP3 | `hsl | `hwb | `lab | `lch | `oklab | `oklch | `prophotoRgb | `rec2020 | `srgb | `srgbLinear | `xyz | `xyzD50 | `xyzD65 ] | `in2 of [< `hsl | `hwb | `lch | `oklch ] * [< `decreasing | `increasing | `longer | `shorter ] ] * ('a * [< `percent of Js.Float.t ] as 'b) * ('a * 'b) | `currentColor | `hex of string | `hsl of [< `calc of [< `add of [< `deg of Js.Float.t | `grad of Js.Float.t | `rad of Js.Float.t | `turn of Js.Float.t ] as 'c * 'c | `mult of 'c * 'c | `sub of 'c * 'c ] | `deg of Js.Float.t | `grad of Js.Float.t | `max of 'c Belt.Array.t | `min of 'c Belt.Array.t | `rad of Js.Float.t | `turn of Js.Float.t ] * [< `calc of [< `add of [< `percent of Js.Float.t ] as 'd * 'd | `mult of 'd * 'd | `sub of 'd * 'd ] | `max of 'd Belt.Array.t | `min of 'd Belt.Array.t | `percent of Js.Float.t ] * [< `calc of [< `add of [< `percent of Js.Float.t ] as 'e * 'e | `mult of 'e * 'e | `sub of 'e * 'e ] | `max of 'e Belt.Array.t | `min of 'e Belt.Array.t | `percent of Js.Float.t ] | `hsla of [< `calc of [< `add of [< `deg of Js.Float.t | `grad of Js.Float.t | `rad of Js.Float.t | `turn of Js.Float.t ] as 'f * 'f | `mult of 'f * 'f | `sub of 'f * 'f ] | `deg of Js.Float.t | `grad of Js.Float.t | `max of 'f Belt.Array.t | `min of 'f Belt.Array.t | `rad of Js.Float.t | `turn of Js.Float.t ] * [< `calc of [< `add of [< `percent of Js.Float.t ] as 'g * 'g | `mult of 'g * 'g | `sub of 'g * 'g ] | `max of 'g Belt.Array.t | `min of 'g Belt.Array.t | `percent of Js.Float.t ] * [< `calc of [< `add of [< `percent of Js.Float.t ] as 'h * 'h | `mult of 'h * 'h | `sub of 'h * 'h ] | `max of 'h Belt.Array.t | `min of 'h Belt.Array.t | `percent of Js.Float.t ] * [< `calc of [< `add of [< `percent of Js.Float.t ] as 'i * 'i | `mult of 'i * 'i | `sub of 'i * 'i ] | `max of 'i Belt.Array.t | `min of 'i Belt.Array.t | `num of Js.Float.t | `percent of Js.Float.t ] | `rgb of Js.Int.t * Js.Int.t * Js.Int.t | `rgba of Js.Int.t * Js.Int.t * Js.Int.t * [< `calc of [< `add of [< `percent of Js.Float.t ] as 'j * 'j | `mult of 'j * 'j | `sub of 'j * 'j ] | `max of 'j Belt.Array.t | `min of 'j Belt.Array.t | `num of Js.Float.t | `percent of Js.Float.t ] | `transparent ] as 'a -> string
val string_of_color : ([< `colorMix of [< `in1 of [< `a98Rgb | `displayP3 | `hsl | `hwb | `lab | `lch | `oklab | `oklch | `prophotoRgb | `rec2020 | `srgb | `srgbLinear | `xyz | `xyzD50 | `xyzD65 ] | `in2 of [< `hsl | `hwb | `lch | `oklch ] * [< `decreasing | `increasing | `longer | `shorter ] ] * 'a * 'a | `currentColor | `hex of string | `hsl of [< `calc of [< `add of [< `deg of Js.Float.t | `grad of Js.Float.t | `rad of Js.Float.t | `turn of Js.Float.t ] as 'c * 'c | `mult of 'c * 'c | `sub of 'c * 'c ] | `deg of Js.Float.t | `grad of Js.Float.t | `max of 'c Belt.Array.t | `min of 'c Belt.Array.t | `rad of Js.Float.t | `turn of Js.Float.t ] * [< `calc of [< `add of [< `percent of Js.Float.t ] as 'd * 'd | `mult of 'd * 'd | `sub of 'd * 'd ] | `max of 'd Belt.Array.t | `min of 'd Belt.Array.t | `percent of Js.Float.t ] * [< `calc of [< `add of [< `percent of Js.Float.t ] as 'e * 'e | `mult of 'e * 'e | `sub of 'e * 'e ] | `max of 'e Belt.Array.t | `min of 'e Belt.Array.t | `percent of Js.Float.t ] | `hsla of [< `calc of [< `add of [< `deg of Js.Float.t | `grad of Js.Float.t | `rad of Js.Float.t | `turn of Js.Float.t ] as 'f * 'f | `mult of 'f * 'f | `sub of 'f * 'f ] | `deg of Js.Float.t | `grad of Js.Float.t | `max of 'f Belt.Array.t | `min of 'f Belt.Array.t | `rad of Js.Float.t | `turn of Js.Float.t ] * [< `calc of [< `add of [< `percent of Js.Float.t ] as 'g * 'g | `mult of 'g * 'g | `sub of 'g * 'g ] | `max of 'g Belt.Array.t | `min of 'g Belt.Array.t | `percent of Js.Float.t ] * [< `calc of [< `add of [< `percent of Js.Float.t ] as 'h * 'h | `mult of 'h * 'h | `sub of 'h * 'h ] | `max of 'h Belt.Array.t | `min of 'h Belt.Array.t | `percent of Js.Float.t ] * [< `calc of [< `add of [< `percent of Js.Float.t ] as 'i * 'i | `mult of 'i * 'i | `sub of 'i * 'i ] | `max of 'i Belt.Array.t | `min of 'i Belt.Array.t | `num of Js.Float.t | `percent of Js.Float.t ] | `rgb of Js.Int.t * Js.Int.t * Js.Int.t | `rgba of Js.Int.t * Js.Int.t * Js.Int.t * [< `calc of [< `add of [< `percent of Js.Float.t ] as 'j * 'j | `mult of 'j * 'j | `sub of 'j * 'j ] | `max of 'j Belt.Array.t | `min of 'j Belt.Array.t | `num of Js.Float.t | `percent of Js.Float.t ] | `transparent ] as 'b * [< `percent of Js.Float.t ] as 'k) as 'a -> 'a -> string
val string_of_actual_color : ([< `colorMix of [< `in1 of [< `a98Rgb | `displayP3 | `hsl | `hwb | `lab | `lch | `oklab | `oklch | `prophotoRgb | `rec2020 | `srgb | `srgbLinear | `xyz | `xyzD50 | `xyzD65 ] | `in2 of [< `hsl | `hwb | `lch | `oklch ] * [< `decreasing | `increasing | `longer | `shorter ] ] * 'a * 'a | `currentColor | `hex of string | `hsl of [< `calc of [< `add of [< `deg of Js.Float.t | `grad of Js.Float.t | `rad of Js.Float.t | `turn of Js.Float.t ] as 'b * 'b | `mult of 'b * 'b | `sub of 'b * 'b ] | `deg of Js.Float.t | `grad of Js.Float.t | `max of 'b Belt.Array.t | `min of 'b Belt.Array.t | `rad of Js.Float.t | `turn of Js.Float.t ] * [< `calc of [< `add of [< `percent of Js.Float.t ] as 'c * 'c | `mult of 'c * 'c | `sub of 'c * 'c ] | `max of 'c Belt.Array.t | `min of 'c Belt.Array.t | `percent of Js.Float.t ] * [< `calc of [< `add of [< `percent of Js.Float.t ] as 'd * 'd | `mult of 'd * 'd | `sub of 'd * 'd ] | `max of 'd Belt.Array.t | `min of 'd Belt.Array.t | `percent of Js.Float.t ] | `hsla of [< `calc of [< `add of [< `deg of Js.Float.t | `grad of Js.Float.t | `rad of Js.Float.t | `turn of Js.Float.t ] as 'e * 'e | `mult of 'e * 'e | `sub of 'e * 'e ] | `deg of Js.Float.t | `grad of Js.Float.t | `max of 'e Belt.Array.t | `min of 'e Belt.Array.t | `rad of Js.Float.t | `turn of Js.Float.t ] * [< `calc of [< `add of [< `percent of Js.Float.t ] as 'f * 'f | `mult of 'f * 'f | `sub of 'f * 'f ] | `max of 'f Belt.Array.t | `min of 'f Belt.Array.t | `percent of Js.Float.t ] * [< `calc of [< `add of [< `percent of Js.Float.t ] as 'g * 'g | `mult of 'g * 'g | `sub of 'g * 'g ] | `max of 'g Belt.Array.t | `min of 'g Belt.Array.t | `percent of Js.Float.t ] * [< `calc of [< `add of [< `percent of Js.Float.t ] as 'h * 'h | `mult of 'h * 'h | `sub of 'h * 'h ] | `max of 'h Belt.Array.t | `min of 'h Belt.Array.t | `num of Js.Float.t | `percent of Js.Float.t ] | `rgb of Js.Int.t * Js.Int.t * Js.Int.t | `rgba of Js.Int.t * Js.Int.t * Js.Int.t * [< `calc of [< `add of [< `percent of Js.Float.t ] as 'i * 'i | `mult of 'i * 'i | `sub of 'i * 'i ] | `max of 'i Belt.Array.t | `min of 'i Belt.Array.t | `num of Js.Float.t | `percent of Js.Float.t ] | `transparent ] * [< `percent of Js.Float.t ]) as 'a -> string
OCaml

Innovation. Community. Security.