\SassScriptFunctions
SassScript functions class.
A collection of functions for use in SassSCript.
Synopsis
class SassScriptFunctions
{
- // constants
- const DECREASE = false;
- const INCREASE = true;
- // members
- public static boolean $parser = FALSE;
- // methods
- public static void option()
- public static new rgb()
- public static new rgba()
- public static new hsl()
- public static new hsla()
- public static new red()
- public static new green()
- public static new blue()
- public static new hue()
- public static new saturation()
- public static new lightness()
- public static new alpha()
- public static new opacity()
- public static new adjust_hue()
- public static new lighten()
- public static new darken()
- public static new saturate()
- public static new desaturate()
- public static new opacify()
- public static new transparentize()
- public static new fade_in()
- public static new fade_out()
- public static new complement()
- public static new grayscale()
- public static new greyscale()
- public static new invert()
- public static new mix()
- public static SassColour adjust_color()
- public static SassColour scale_color()
- public static SassColour change_color()
- public static void adjust()
- public static SassNumber abs()
- public static new ceil()
- public static new floor()
- public static new round()
- public static new comparable()
- public static new percentage()
- public static void max()
- public static void min()
- public static new unit()
- public static new units()
- public static new unitless()
- public static new quote()
- public static new unquote()
- public static get_var()
- public static SassNumber length()
- public static anything nth()
- public static void join()
- public static void append()
- public static void _if()
- public static new type_of()
- public static the inRange()
Constants
Name | Value |
---|---|
DECREASE | false |
INCREASE | true |
Members
public
- $parser
Methods
public
- _if() — An inline "if-else" statement.
- abs() — Finds the absolute value of a number.
- adjust() — Adjusts the colour
- adjust_color() — Adjusts one or more property of the color by the value requested.
- adjust_hue() — Changes the hue of a colour while retaining the lightness and saturation.
- alpha() — Returns the alpha component (opacity) of a colour.
- append()
- blue() — Returns the blue component of a colour.
- ceil() — Rounds a number up to the nearest whole number.
- change_color() — Changes one or more properties of the color to the requested value
- comparable() — Returns true if two numbers are similar enough to be added, subtracted, or compared.
- complement() — Returns the complement of a colour.
- darken() — Makes a colour darker.
- desaturate() — Makes a colour less saturated.
- fade_in() — Makes a colour more opaque.
- fade_out() — Makes a colour more transparent.
- floor() — Rounds down to the nearest whole number.
- get_var() — Returns the variable whose name is the string.
- grayscale() — Greyscale for non-english speakers.
- green() — Returns the green component of a colour.
- greyscale() — Converts a colour to greyscale.
- hsl() — Creates a SassColour object from hue, saturation, and lightness.
- hsla() — Creates a SassColour object from hue, saturation, lightness and alpha channel (opacity).
- hue() — Returns the hue component of a colour.
- inRange() — Ensures the value is within the given range, clipping it if needed.
- invert() — Inverts a colour.
- join()
- length() — Returns the length of the $list
- lighten() — Makes a colour lighter.
- lightness() — Returns the lightness component of a colour.
- max()
- min()
- mix() — Mixes two colours together.
- nth() — Returns the nth value ofthe $list
- opacify() — Makes a colour more opaque.
- opacity() — Returns the alpha component (opacity) of a colour.
- option()
- percentage() — Converts a decimal number to a percentage.
- quote() — Add quotes to a string if the string isn't quoted, or returns the same string if it is.
- red() — Returns the red component of a colour.
- rgb() — Creates a SassColour object from red, green, and blue values.
- rgba() — Creates a SassColour object from red, green, and blue values and alpha channel (opacity).
- round() — Rounds a number to the nearest whole number.
- saturate() — Makes a colour more saturated.
- saturation() — Returns the saturation component of a colour.
- scale_color() — Scales one or more property of the color by the percentage requested.
- transparentize() — Makes a colour more transparent.
- type_of() — Inspects the type of the argument, returning it as an unquoted string.
- unit() — Inspects the unit of the number, returning it as a quoted string.
- unitless() — Inspects the unit of the number, returning a boolean indicating if it is unitless.
- units() — Inspects the units of the number, returning it as a quoted string.
- unquote() — Removes quotes from a string if the string is quoted, or returns the same string if it's not.