Skip to content

Conversation

evanfuture
Copy link

Using width and height on an svg element defeats the purpose of using svg. It is better to use the viewbox. I applied the scale to the viewbox instead of the polygons to simplify future animations. (This article explains it nicely: https://css-tricks.com/scale-svg/ )

Also, I added a conditional to only apply fill-opacity to individual elements if they are different from the 1st shape's alpha channel (maybe there's a better way to do this than array[0]).

Also, only apply opacity to individual elements if they are different (maybe there's a better way to do this)
bmaltais added a commit to bmaltais/primitive that referenced this pull request Jul 9, 2018
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 this pull request may close these issues.

1 participant