When we talk about gradients in CSS, we talk about gradients of colors. 2 colors: 0% and %; 3 colors: 0%, 50% and %; 4 colors: 0%, 33%, 67% and. CSS3 मे Gradients आपको दो या अधिक Colors के बीच Smooth Transition को Specified करने देते है. CSS3 दो प्रकार के Gradients को परिभाषित. One of the features is the ability to specify gradients using pure CSS3, without having to create any images and use them as repeating backgrounds for gradient.


Author: Ms. Carolyne Wunsch
Country: Colombia
Language: English
Genre: Education
Published: 19 March 2014
Pages: 163
PDF File Size: 31.34 Mb
ePub File Size: 23.4 Mb
ISBN: 911-9-80271-508-3
Downloads: 23080
Price: Free
Uploader: Ms. Carolyne Wunsch


Radial gradients work from the inside to the outside of an element.


Thus, the first color identified within the radial-gradient function will sit in the absolute center of the element, and the second color will sit on the outside gradients css 3 tutorial an element.

The browser will then create the transition between the two colors.

CSS3 - Gradients

One of the primary differences between radial gradients and linear gradients is that radial gradients can be quite complex, with values for location, size, radius, and so forth.

Fortunately, a few CSS3 gradient generators have popped up. Each generator works a little differently, and some provide more options than others. Gradient Color Stops At a minimum, gradient backgrounds will transition from one gradients css 3 tutorial to another; however, we may add multiple colors to a gradient and have the browser transition between all of them.

CSS3 in Hindi Gradients

By default, the browser will position every color stop an equal distance from the next and will transition between them gradients css 3 tutorial. 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.


The first background property specifies a solid color hexadecimal value, gradients css 3 tutorial serves as a fallback should a browser not support linear gradient backgrounds.

The second background property includes the linear-gradient function, which identifies a green gradient background that transitions from the top of the element to the bottom of the gradients css 3 tutorial.

These new styles will include a gradient background that starts with green and transitions to yellow, from left to right. Our updated row section now looks like this: Each of our interior pages should now include the following: Prepare for an inspiration extravaganza.

Ultimate CSS Gradient Generator -

Our lead section for each interior page will now look like this: Make gradients css 3 tutorial to review the code for all of the interior pages to see their newly enhanced content, headings, and paragraphs.

View the Styles Conference Website or Download the Source Code Zip file Using Multiple Background Images For the longest time, elements were allowed to have only one background image at a time, which created quite a gradients css 3 tutorial constraints when designing a page.

Fortunately, with CSS3, we can now use more than one background image on an element by comma-separating multiple background values within a background or background-image property. Any value between the first and the last will reside within the middle ground accordingly.

CSS3 Linear Gradients [CSS3 Tips] - Hongkiat

These shorthand values may also be broken up into gradients css 3 tutorial values across the background-image, background-position, and background-repeat properties.

The first value, the foremost image, will be the tick image. The second value, the rearmost image, will be the linear gradient.


The two values are comma separated. Gradients css 3 tutorial background-size property allows us to gradients css 3 tutorial the size of a background image, while the background-clip and background-origin properties allow us to control where a background image is cropped and where a background image is contained within the element inside the border or inside the padding, for example.

CSS3 Background Size The background-size property allows us to specify a size for a background image.

The property accepts a few different values, including length and keyword values. When using length values, we can specify a width and a height value by using two space-separated values.

Ultimate CSS Gradient Generator

The first value will set the width of the background image, while the second value will set the height of the background image. The keyword value auto may be used as either the width or height value to preserve the aspect ratio of the background gradients css 3 tutorial.

Often when using the cover keyword value, part of the background image is cut off in order for the image to occupy the full available space of the element. In contrast with the cover keyword value, the contain keyword value will always show the full background image; however, oftentimes it will gradients css 3 tutorial occupy the full available space of the element.

Both the cover and contain keyword values may result in slightly distorted background images, particularly when the images are stretched beyond their original dimensions.

Other Posts: