fixed link generation
This commit is contained in:
parent
fe30758a93
commit
1cd4196765
|
@ -306,10 +306,10 @@ class CCPMethodEditorController extends HTMLElement{
|
|||
}
|
||||
).then(data=>{
|
||||
const filename = data.title + "-" + data.version + ".json"
|
||||
const objectURL = URL.createObjectURL(data)
|
||||
const datastr = "data:text/json;charset=utf-8," + encodeURIComponent(JSON.stringify(data));
|
||||
var tmplnk = document.createElement("a")
|
||||
tmplnk.download = filename
|
||||
tmplnk.href = objectURL
|
||||
tmplnk.href = datastr
|
||||
document.body.appendChild(tmplnk)
|
||||
tmplnk.click()
|
||||
document.body.removeChild(tmplnk)
|
||||
|
|
Loading…
Reference in New Issue