At 15:39 +0000 6/6/13, Angela French wrote:
So in my syntax, what is the "to" doing?
It's saying the the direction of the gradient ray points to the
bottom of the element. In other words, the gradient from from the
top TO the bottom. If you changed it to read:
background-image: linear-gradient(to left, red, yellow);
...then the gradient would run from right TO left. Similarly:
background-image: linear-gradient(to top left, red, yellow);
...means from bottom right TO top left, though not precisely into the
top left corner. An old-ish post of mine hopefully makes it a little
more clear:
<http://meyerweb.com/eric/thoughts/2012/04/26/lineargradient-keywords/>.
(Note that it's from April 2012, so some of the "this is how browsers
behave right now" bits may no longer be accurate.)
--
Eric A. Meyer (http://meyerweb.com/eric/), List Chaperone
"CSS is much too interesting and elegant to be not taken seriously."
-- Martina Kosloff (http://mako4css.com/)
______________________________________________________________________
css-discuss [css-d@lists.css-discuss.org]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
List policies -- http://css-discuss.org/policies.html
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/