HTML and CSS Reference
In-Depth Information
Figure 7.7 A linear gradient background including three colors transitioning from the
left to the right of an element
By default, the browser will position every color stop an equal distance from the next and
will transition between them accordingly. If more control over how colors are positioned
is desired, a location along the gradient may be identified for each color stop. The location
should be declared as a length value and should fall after the color value (see Figure 7.8 ) .
Click here to view code image
1. div {
2. background: #648880;
3. background: linear-gradient(to right, #f6f1d3, #648880 85%,
#293f50);
4. }
Search WWH ::




Custom Search