Background overlay does not inherit border radius

When I create a div with an image backgound and add a gradient overlay the overlay is not inheriting the border radius I applied to the div.

Is this expected behaviour? If it is, how might I get the overlay to respect the border radius?

Either:

Or:

4 Likes

Thanks @Marius !

Post must be at least twenty characterssssssssssss :sunglasses:

2 Likes

@Marius thanks.
But I noticed if you have a filter on the background, for example a blur, that this doesn’t do the trick:

The div is relative, overflow is hidden.
How to solve this?

Hi @Lijn-B,

Using the second option shared by @Marius should work:

2 Likes

@StrangeTech Thanks Dan,

I noticed that I had to have a border line. I removed that and than it doesn’t work. So I added a transparent border line and that does the trick.

Thanks again, also you @Marius

2 Likes