transparentize

transparentize($color, $amount) Also known as: fade_out

Makes a color more transparent. Takes a color and a number between 0 and 1, and returns a color with the opacity decreased by that amount.

Examples:

transparentize(rgba(0, 0, 0, 0.5), 0.1) => rgba(0, 0, 0, 0.4)
transparentize(rgba(0, 0, 0, 0.8), 0.2) => rgba(0, 0, 0, 0.6)

Parameters:

  • $color (Color)
  • $amount (Number) The amount to decrease the opacity by, between 0 and 1

Returns:

  • (Color)

Raises:

  • (ArgumentError) if $amount is out of bounds, or either parameter is the wrong type
doc_Sass
2016-11-11 13:09:27
Comments
Leave a Comment

Please login to continue.