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

strange color & gap at gradient edge #4

Closed
Rplus opened this issue Jun 21, 2015 · 7 comments · Fixed by #26
Closed

strange color & gap at gradient edge #4

Rplus opened this issue Jun 21, 2015 · 7 comments · Fixed by #26

Comments

@Rplus
Copy link
Contributor

Rplus commented Jun 21, 2015

// demo code
$circle-count: 18;

.circle {
  background-image:
    repeating-conic-gradient(
      #fff 0 #{180deg / $circle-count},
      #000 0 #{360deg / $circle-count}
    );
}

reproduce:
https://jsbin.com/cofege/1/edit?css,output

image

@LeaVerou
Copy link
Owner

Thanks! Does it only happen with specific values for $circle-count? That would be useful for debugging, if you have some time to experiment!

@LeaVerou
Copy link
Owner

Btw, completely unrelated to this bug, but you don’t need that many elements for this effects, you can do it with just one element with a conic gradient, a radial gradient and blending modes: http://codepen.io/leaverou/pen/WvZmrM?editors=010

@LeaVerou
Copy link
Owner

Also thanks for the updated screenshot!

@Rplus
Copy link
Contributor Author

Rplus commented Jun 23, 2015

The pen is so cool and helpful!

ps:
The strange color appear at that pen, when the $n in other number
image

@LeaVerou
Copy link
Owner

Yup, I know it happens there too, I was just suggesting a better way for this, regardless of the rounding error that is causing that weird gap for some stop positions.

@Hypnosphi
Copy link
Contributor

Hypnosphi commented Mar 27, 2018

Here's the most obvious reproduction I was able to find:
https://codepen.io/anon/pen/bvapKd
screen shot 2018-03-28 at 00 23 25

I'll try to work on a PR fixing this

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

Successfully merging a pull request may close this issue.

3 participants