PolymerElements / iron-iconset-svg

Represents a source of icons expressed as a collection of inline SVGs
https://www.webcomponents.org/element/PolymerElements/iron-iconset-svg
37 stars 34 forks source link

Why not allow non-square icons? #3

Closed dhpollack closed 8 years ago

dhpollack commented 9 years ago

It seems fairly trivial to add non-square icons. All one would have to do is change line change the cloneIcon function to allow for an x-size and a y-size and then change the set viewBox function to reflect this change. But perhaps there is a reason you only allow square icons.

Is there a reason we couldn't have an size for length and width so we could add non-square icon sets?

dhpollack commented 9 years ago

@cdata any opinion on this? I wouldn't mind creating a pull request to add this functionality.

jennvoss commented 9 years ago

I submitted a pull request to allow this: https://github.com/PolymerElements/iron-iconset-svg/pull/13

If you set a viewBox attribute on your svg's, this change will respect that value instead of resetting it to the iconset size. I've been using this in my own project without any issues, but if you see a downside to this please let me know.

dhpollack commented 9 years ago

@jennvoss cool!

notwaldorf commented 8 years ago

This looks like it's been fixed