Skip to content

Instantly share code, notes, and snippets.

@robertg042
Created May 11, 2018 21:32
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 robertg042/89757ac193575912c81ca4513055f042 to your computer and use it in GitHub Desktop.
Save robertg042/89757ac193575912c81ca4513055f042 to your computer and use it in GitHub Desktop.
css effects
.reveal {
position: relative;
}
.reveal::after {
position: absolute;
left: 0;
bottom: 0;
right: 0;
top: 0;
content: '';
background: 0 center no-repeat;
background-image: linear-gradient(90deg,rgba(36,101,178,0) 0%,rgba(36,101,178,1) 0%);
background-clip: border-box;
opacity: 0;
transition: none;
}
.reveal:hover:after {
opacity: 1;
background-position: 6rem center;
transition: background-position 1s ease-out;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment