Updated edit extension

This commit is contained in:
markseu 2020-01-07 16:02:59 +01:00
parent 6079fba9aa
commit 0499868f52
3 changed files with 5 additions and 1 deletions

View file

@ -825,6 +825,10 @@ yellow.edit = {
request.open("POST", window.location.pathname, true);
request.onload = function() { if (this.status==200) { thisObject.uploadFileDone.call(thisObject, elementText, this.responseText); } else { thisObject.uploadFileError.call(thisObject, elementText, this.responseText); } };
request.send(formData);
} else {
var textError = extensions.indexOf(extension)!=-1 ? "file too big!" : "format not supported!";
var textNew = "[Can't upload file '"+file.name+"', "+textError+"]";
yellow.editor.setMarkdown(elementText, textNew, "insert");
}
},

View file

@ -4,7 +4,7 @@
// This file may be used and distributed under the terms of the public license.
class YellowEdit {
const VERSION = "0.8.15";
const VERSION = "0.8.16";
const TYPE = "feature";
public $yellow; //access to API
public $response; //web response