Answer the question
In order to leave comments, you need to log in
How to cut out a piece from a background that is given a color?
Hello!
There is a first block with bg-image. A layer above is the next-second block, but with already bg in the form of #fff, i.e. the first block with the #fff background overlaps the second block with the bg-image.
Is it possible to cut out part of the background of the second block so that we can see the image of the first block through this `hole`?
Screenshot:
Thank you!
Answer the question
In order to leave comments, you need to log in
clip and clip-path properties (it will be easier to prepare a mask and cut it out)
https://www.sarasoueidan.com/blog/css-svg-clipping/
<svg>
<defs>
<clipPath id="clipping">
<polygon points="98.4999978 153.75..."/> // ваша маска
</clipPath>
</defs>
</svg>
.item {
clip-path: url(#clipping);
}
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question