Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

animate background gradient change of featurelet buttons #2

Open
floatingatoll opened this issue Jun 24, 2012 · 1 comment
Open

animate background gradient change of featurelet buttons #2

floatingatoll opened this issue Jun 24, 2012 · 1 comment

Comments

@floatingatoll
Copy link

when :hover on a featurelet button, the border fades in smoothly over 0.5s, but the background gradient snaps from A to B instantly, creating a distracting flash effect.

@floatingatoll
Copy link
Author

i was able to fix this by changing .featurelet .inner's color-stop to rgba(0,0,0,0) and setting background-color to color A, and then removing all background-image lines from :hover and setting background-color to color B.

approximately:

 .featurelet .inner {
-  background-image: -webkit-gradient(linear, 50% 0%, 50% 100%, color-stop(0%, #a46a42), color-stop(100%, #6e472c));
+  background-color: #6e472c;
+  background-image: -webkit-gradient(linear, 50% 0%, 50% 100%, color-stop(0%, #a46a42), color-stop(100%, rgba(0,0,0,0)));

and:

 .featurelet .inner:hover {
-  background-image: -webkit-gradient(linear, 50% 0%, 50% 100%, color-stop(0%, #a46a42), color-stop(100%, #492f1e));
+  background-color: #492f1e;

I imagine this can be done in SCSS, but I don't seem to have a working ruby install sufficient to deal with the @include "compass" bit.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant