Skip to content

Instantly share code, notes, and snippets.

@herrernst
Created October 7, 2016 08:11
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 herrernst/109fe9548404a771a4d39b0f8a61e7d9 to your computer and use it in GitHub Desktop.
Save herrernst/109fe9548404a771a4d39b0f8a61e7d9 to your computer and use it in GitHub Desktop.
<!doctype html>
<title>gradient gray alpha</title>
<meta name="viewport" content="width=device-width">
<style>
.gradient {
width: 768px;
height: 300px;
background-image: linear-gradient(to right, rgba(0, 0, 0, 0.5), rgb(128, 128, 128));
}
</style>
<h2>Css gradient from black 0.5% alpha to 50% gray</h2>
<div class="gradient">
</div>
<p>
Results: Uniform in Chrome, messed up in Safari because of known Safari bug; shaky in Firefox and IE
</p>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment