Permalink
Browse files

Avoid awkward wrapping

  • Loading branch information...
1 parent 749addf commit 31e387066e508c1ff4ce956202a9f983ecdab1a2 @lukeapage lukeapage committed Oct 21, 2012
Showing with 20 additions and 15 deletions.
  1. +20 −15 templates/pages/doc.md
View
@@ -393,21 +393,26 @@ Color functions
LESS provides a variety of functions which transform colors. Colors are first converted to
the *HSL* color-space, and then manipulated at the channel level:
- lighten(@color, 10%); // return a color 10 percentage points *lighter* than @color
- darken(@color, 10%); // return a color 10 percentage points *darker* than @color
-
- saturate(@color, 10%); // return a color 10 percentage points *more* saturated than @color
- desaturate(@color, 10%); // return a color 10 percentage points *less* saturated than @color
-
- fadein(@color, 10%); // return a color 10 percentage points *less* transparent than @color
- fadeout(@color, 10%); // return a color 10 percentage points *more* transparent than @color
- fade(@color, 50%); // return @color with 50% transparency
-
- spin(@color, 10); // return a color with a 10 degree larger in hue than @color
- spin(@color, -10); // return a color with a 10 degree smaller hue than @color
-
- mix(@color1, @color2, @weight); // return a mix of @color1 and @color2, default weight 50%
- contrast(@color1, @darkcolor, @lightcolor); // return @darkcolor if @color1 is >50% luma (i.e. is a light color), otherwise return @lightcolor
+ lighten(@color, 10%); // return a color 10 percentage points *lighter* than @color
+ darken(@color, 10%); // return a color 10 percentage points *darker* than @color
+
+ saturate(@color, 10%); // return a color 10 percentage points *more* saturated than @color
+ desaturate(@color, 10%); // return a color 10 percentage points *less* saturated than @color
+
+ fadein(@color, 10%);
+ // return a color 10 percentage points *less* transparent than @color
+ fadeout(@color, 10%);
+ // return a color 10 percentage points *more* transparent than @color
+ fade(@color, 50%); // return @color with 50% transparency
+
+ spin(@color, 10); // return a color with a 10 degree larger in hue than @color
+ spin(@color, -10); // return a color with a 10 degree smaller hue than @color
+
+ mix(@color1, @color2, @weight);
+ // return a mix of @color1 and @color2, default weight 50%
+ contrast(@color1, @darkcolor, @lightcolor);
+ // return @darkcolor if @color1 is >50% luma (i.e. is a light color),
+ // otherwise return @lightcolor
Using them is pretty straightforward:

0 comments on commit 31e3870

Please sign in to comment.