Skip to content Skip to sidebar Skip to footer

Rounded Corners and Shadows for Images using CSS

Here are some custom border styles that you can apply to your Blogger images by using the border-radius property and specifying all four borders at once, or by applying rounded borders to only part of the border.

One of the advantages of CSS3 is that we can apply rounded borders without getting too complicated, and one option is to use those borders or borders on an image in a blog post and add some transition effects like drop shadows to it. and rounded edges accompanied by transitions.

Note: For more information on how to add rounded edges to images, please visit the following link:
- CSS basics. How to apply rounded edges to image n. one
- CSS basics. How to apply rounded edges to image n. 2

Below are some examples of these boundaries and how they behave when an image is hovered over them.
If you want to use one of these styles, copy the code below the image, go to the " Templates " section, click the " Edit HTML " button, then paste the code first ]]> (CTRL + F to find)

.post-body img {
limit: 0;
coating: 0;
-moz-transitions: all 1;
-webkit-transition: all 1;
-o-transitions: all 1;
}
.post-body img: point {
Shadow box: 0px 0px 15px #000; /* shadow */
border radius: 50%; /* rounded edges */
-moz-transitions: all 1;
-webkit-transition: all 1;
-o-transitions: all 1;
cursor: pointer;
}
.post-body img {
background: #FFF; /* Background color around the image */
padding: 15px; /* space between border and image */
-moz-transitions: all 1;
-webkit-transition: all 1;
-o-transitions: all 1;
}
.post-body img: point {
Shadow box: 0px 0px 15px #000; /* shadow */
border radius: 0% 50%; /* rounded edges */
-moz-transitions: all 1;
-webkit-transition: all 1;
-o-transitions: all 1;
cursor: pointer;
}
.post-body img {
background: #FFF; /* background color around the image * /
padding: 15px; /* Space between the border and the image */
edge radius: 50% 0; /* rounded edges */
Shadow box: 0px 0px 15px #000; /* shadow */
-moz-transitions: all 1;
-webkit-transition: all 1;
-o-transitions: all 1;
}
.post-body img: point {
edge radius: 0; /* This removes the edge softness (value 0) */
-moz-transitions: all 1;
-webkit-transition: all 1;
-o-transitions: all 1;
cursor: pointer;
}
.post-body img {
Shadow box: 0px 0px 15px #000; /* shadow */
border radius: 50%; /* rounded edges */
limit: 0;
coating: 0;
-moz-transitions: all 1;
-webkit-transition: all 1;
-o-transitions: all 1;
}
.post-body img: point {
field shadow: 0; /* This removes the shadow (value 0) */
edge radius: 0; /* This removes the edge softness (value 0) */
-moz-transitions: all 1;
-webkit-transition: all 1;
-o-transitions: all 1;
cursor: pointer;
}
.post-body img {
border radius: 45% / 20%; /* rounded edges */
Shadow box: 0px 0px 15px #000; /* shadow */
coating: 0;
-moz-transitions: all 1;
-webkit-transition: all 1;
-o-transitions: all 1;
}
.post-body img: point {
edge radius: 0; /* This removes the edge softness (value 0) */
-moz-transitions: all 1;
-webkit-transition: all 1;
-o-transitions: all 1;
cursor: pointer;
}
This effect will be applied to all images uploaded to the Blogger post. But if you want to apply it only to certain images, change .post-body img to .rounded and .post-body img:hover to .rounded:hover Then add a rounded class selector to the image code:
class="round" src=" image URL "/>
These are just a few examples, but you can change them anytime by adding or removing more CSS styles, depending on your personal taste and needs. But as you can see, we can make images much more attractive and it's done only with CSS ;)

Post a Comment for "Rounded Corners and Shadows for Images using CSS"