14:07Add an overlay to a background-image with one line of CSS
From the creator
Looking to take control of your CSS? Check out my course CSS Demystified π https://cssdemystified.com/?utm_campaign=general&utm_source=youtube&utm_medium=border-image π Links β Temaniβs article on border-image: https://www.smashingmagazine.com/2024/01/css-border-image-property β CSS Demystified: https://cssdemystified.com/?utm_campaign=general&utm_source=youtube&utm_medium=border-image β The finished code from this video: https://codepen.io/kevinpowell/pen/yLWNbdJ β Timestamps 00:00 - Introduction 00:11 - The long way with a pseudo-element 01:00 - Using a border-image instead 03:10 - CSS Demystified 03:42 - The fill keyword 04:20 - Making the gradient transparent 04:50 - Removing the extra space around the image 05:09 - Using the border-image shorthand to make it one line of CSS #css -- Come hang out with other dev's in my Discord Community π¬ https://discord.gg/nTYCvrK Keep up to date with everything I'm up to β https://www.kevinpowell.co/newsletter Come hang out with me live every Monday on Twitch! πΊ https://www.twitch.tv/kevinpowellcss --- Help support my channel π¨βπ Get a course: https://www.kevinpowell.co/courses π Buy a shirt: https://teespring.com/stores/making-the-internet-awesome π Support me on Patreon: https://www.patreon.com/kevinpowell --- My editor: VS Code - https://code.visualstudio.com/ --- I'm on some other places on the internet too! If you'd like a behind the scenes and previews of what's coming up on my YouTube channel, make sure to follow me
Published 2024-05-22 Β· Watch on YouTube β
Availability and playback restrictions are controlled by the original channel.





