mix

mix($color1, $color2, $weight:50%) Mixes two colors together. Specifically, takes the average of each of the RGB components, optionally weighted by the given percentage. The opacity of the colors is also considered when weighting the components. The weight specifies the amount of the first color that should be included in the returned color. The default, 50%, means that half the first color and half the second color should be used. 25% means that a quarter of the first color and three quarter

map_values

map_values($map) Returns a list of all values in a map. This list may include duplicate values, if multiple keys have the same value. Examples: map-values(("foo": 1, "bar": 2)) => 1, 2 map-values(("foo": 1, "bar": 2, "baz": 1)) => 1, 2, 1 Parameters: $map (Map) Returns: (List) — the list of values, comma-separated Raises: (ArgumentError) — if $map is not a map

max

max($numbers...) Finds the maximum of several numbers. This function takes any number of arguments. Examples: max(1px, 4px) => 4px max(5em, 3em, 4em) => 5em Parameters: $numbers ([Number]) Returns: (Number) Raises: (ArgumentError) — if any argument isn’t a number, or if not all of the arguments have comparable units

min

min($numbers...) Finds the minimum of several numbers. This function takes any number of arguments. Examples: min(1px, 4px) => 1px min(5em, 3em, 4em) => 3em Parameters: $numbers ([Number]) Returns: (Number) Raises: (ArgumentError) — if any argument isn’t a number, or if not all of the arguments have comparable units

map_merge

map_merge($map1, $map2) Merges two maps together into a new map. Keys in $map2 will take precedence over keys in $map1. This is the best way to add new values to a map. All keys in the returned map that also appear in $map1 will have the same order as in $map1. New keys from $map2 will be placed at the end of the map. Like all map functions, map-merge() returns a new map rather than modifying its arguments in place. Examples: map-merge(("foo": 1), ("bar": 2)) => ("foo": 1, "bar": 2) map-

map_remove

map_remove($map, $keys...) Returns a new map with keys removed. Like all map functions, map-merge() returns a new map rather than modifying its arguments in place. Examples: map-remove(("foo": 1, "bar": 2), "bar") => ("foo": 1) map-remove(("foo": 1, "bar": 2, "baz": 3), "bar", "baz") => ("foo": 1) map-remove(("foo": 1, "bar": 2), "baz") => ("foo": 1, "bar": 2) Parameters: $map (Map) $keys ([Base]) Returns: (Map) Raises: (ArgumentError) — if $map is not a map

map_has_key

map_has_key($map, $key) Returns whether a map has a value associated with a given key. Examples: map-has-key(("foo": 1, "bar": 2), "foo") => true map-has-key(("foo": 1, "bar": 2), "baz") => false Parameters: $map (Map) $key (Base) Returns: (Bool) Raises: (ArgumentError) — if $map is not a map

map_keys

map_keys($map) Returns a list of all keys in a map. Examples: map-keys(("foo": 1, "bar": 2)) => "foo", "bar" Parameters: $map (Map) Returns: (List) — the list of keys, comma-separated Raises: (ArgumentError) — if $map is not a map

list_separator

list_separator($list) Returns the separator of a list. If the list doesn’t have a separator due to having fewer than two elements, returns space. Examples: list-separator(1px 2px 3px) => space list-separator(1px, 2px, 3px) => comma list-separator('foo') => space Parameters: $list (Base) Returns: (String) — comma or space

lightness

lightness($color) Returns the lightness component of a color. See the CSS3 HSL specification. Calculated from RGB where necessary via this algorithm. Parameters: $color (Color) Returns: (Number) — The lightness component, between 0% and 100% Raises: (ArgumentError) — if $color isn’t a color