CharlieW
CharlieW

Reputation: 45

Image gradient with css

I wish to add a radial gradient on an image. I want to make it fade into the background. So like it goes from transparent to the background color. I've been stuck on this for a while and filters don't seem to work with radial gradients. Heres my messy code:

Html:

<div class="spoiler-image">
     <img class="spoiler-img vignette" src="/src/assets/images/ViewPointimg.png" alt="Error 103">
</div>

Css:

.spoiler-image {
    float: right;
    margin-top: 175px;
    margin-right: 200px;
}

Upvotes: 0

Views: 42

Answers (1)

UmairFarooq
UmairFarooq

Reputation: 1315

Try Opacity:50%; or any number that blens in perfectly

Upvotes: 1

Related Questions