Skip to content

Instantly share code, notes, and snippets.

@JeffersonBledsoe
Created March 18, 2022 14:01
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save JeffersonBledsoe/548f4aa732f139d8eaf77e36933d9e22 to your computer and use it in GitHub Desktop.
Save JeffersonBledsoe/548f4aa732f139d8eaf77e36933d9e22 to your computer and use it in GitHub Desktop.
Trick to lighten/ darken a background colour that is IE compatible
/* Change `0.15` to adjust the effect. Closer to 1 will apply the effect more. Change to black to darken */
.item:focus,
.item:hover {
background-image: linear-gradient(
rgba(var(--white-rgb), 0.15),
rgba(var(--white-rgb), 0.15)
);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment