grommet / grommet-designer

Apache License 2.0
36 stars 18 forks source link

JSON export incomplete #92

Closed IntranetFactory closed 3 years ago

IntranetFactory commented 3 years ago

I opened https://designer.grommet.io/undefined?id=Card-eric-soderberg-hpe-com&mode=edit, select share, Download - the resulting file is just 413 bytes and seems to be truncated:

{"name":"Card","screens":{"1":{"id":1,"root":25,"name":"Card"}},"screenOrder":[1],"components":{"3":{"id":3,"type":"Box","props":{"align":"center","pad":"small","background":{"0":"b","1":"r","2":"a","3":"n","4":"d","color":"white","image":"url('data:image/svg+xml;utf8,<svgxmlns=\"http://www.w3.org/2000/svg\"width=\"130\"height=\"192\"viewBox=\"240140192\">\n<gfill=\"none\"fill-rule=\"evenodd\">\n<pathstroke=\"
ericsoderberghp commented 3 years ago

It seems to be working for me. If I export from one browser and then import in a different browser, it works. The JSON format is a compact description of the design. What were you expecting to see?

IntranetFactory commented 3 years ago

The above code is the code from the downloaded file. It seems to end early with <pathstroke=\" I've renamed the whole file and attached it: Card.json.txt

Uploading fails with Unexpected end of JSON input. I'm using Chrome 90 on Windows.

ericsoderberghp commented 3 years ago

Interesting. I see the truncation you have sent. It looks like it can be reproduced on Chrome and Firefox but not on Safari. I will look into it ...

ericsoderberghp commented 3 years ago

Thanks for reporting the issue. It should be fixed now.