It’s time to get me up to speed with modern CSS. There’s so much new in CSS that I know too little about. To change that I’ve started #100DaysOfMoreOrLessModernCSS. Why more or less modern CSS? Because some topics will be about cutting-edge features, while other stuff has been around for quite a while already, but I just have little to no experience with it.
You can use
mask properties to apply a mask to an element.
Let's say you have an image and a logo. You can use the logo to mask the image.
There are a bunch of properties you can use to adjust the styling of the mask.
- mask-clip (MDN)
- mask-composite (MDN)
- mask-image (MDN)
- mask-mode (MDN)
- mask-origin (MDN)
- mask-position (MDN)
- mask-repeat (MDN)
- mask-size (MDN)
You can also apply a mask to an element.
-webkit-prefix for some browsers.
See on CodePen.