primitive icon indicating copy to clipboard operation
primitive copied to clipboard

Use viewbox so svg is not a fixed size (easier to animate)

Open evanfuture opened this issue 8 years ago • 0 comments

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]).

evanfuture avatar Jan 19 '18 09:01 evanfuture