Open lyqht opened 2 months ago
Same here. If I remove the logo in mini-qr-code-generator.vercel.app with preset "Default" and try to open the SVG in Illustrator, I get the error message
Clipping is lost when exporting to SVG Tiny format
After confirming the message with "OK", I can only see the corner elements in Illustrator:
All the other elements are there somehow which can be seen by pressing CTRL+a, but they are not filled:
I might have to create a fork of the qr code library that i'm using to generate the qr code to fix this issue, it's not trivial
Hello @rucksman, i merged a fix, give it a try, it should work now!
Unfortunately it does not work for me.
First try: Used default profile in https://mini-qr-code-generator.vercel.app/. There is an error message in Illustrator (something like "Clipping is lost when exporting to SVG Tiny format"). After confirming with "OK", again there are no elements visible, at least the logo is there: And as before after selecting everthing, I can see that the elements exist (but are not visible):
Second try: Uploaded a SVG for the image. Same error message and no logo at all:
Third try: As before but with a PNG. Same error on opening, logo is there, but no other elements visible:
Aww, It looked fine on Inkscape, but Illustrator probably processes it differently, i will reopen the issue. Thanks for helping to replicate!
Description
Why this happens
In https://github.com/tsayen/dom-to-image/issues/64, it was mentioned that
toSvgElement
doesn't actually create a proper SVG element with paths/shapes. It simply creates aforeignObject
, which is usually recognizable on web browsers. This is also why the exported SVGs render as expected on this GitHub repo's README.md.However graphic editor softwares like InkScape, Adobe illustrator cannot recognize the SVG file format.
Issue
This issue is reported by Mihai Scelcunov
Logo missing