hypertext icon indicating copy to clipboard operation
hypertext copied to clipboard

add svg support

Open vidhanio opened this issue 2 years ago • 2 comments

vidhanio avatar Jan 13 '24 14:01 vidhanio

Would love to add interest to SVG support, looked at that PR mentioned and it does work out of the box no real issues. I saw you didn't like the feature flag and maybe wanted some more documentation surrounding those elements. I started going through and trying to make those fixes but while doing so I had a couple questions for your preference on it

Brocktho avatar Jan 04 '25 23:01 Brocktho

Would you prefer that all SVG elements are added inside the elements! macro? or rather have them sidecar (in their own svg_elements!) like that pull request draft has? If putting them all into the elements! macro the svg global props are much more limited than most elements and would either want a refactor of many existing elements or to accept that about 20 attributes are "acceptable" for svg elements to have on them but not technically valid by spec.

While I was digging into this I also found a number of "GlobalAttributes" that aren't technically global based on the spec here: MDN Dev Docs. Would you like those to be refactored? Or I'm assuming some of these are custom element attributes for web components that I might not know of? (some examples: autofocus, enterkeyhint, is, itemid, etc.)

Curious what you'd prefer, I'd be fine to do any of the options (sidecar, add them to main elements without refactor, add them to main elements with larger refactor)

Brocktho avatar Jan 05 '25 02:01 Brocktho