You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In github comment box, you have the option to drag/drop, paste or select file/images. This plugin lacks the "select" using file input.
I achieved this by directly modifying a dist js (jquery version) by adding the option bindedFileInput. This should trigger the upload when change event occurs on the input element. I'm not that familiar with grunt/npm and don't have the time implement a build so if your kind enough to add this bits of code for me that would be awesome.
/** * called on bindedFileInput change event occured * @param {Event} e * @return {Boolean} if the event was handled */inlineAttachment.prototype.onBindedFileInputChange=function(e){varresult=false,files=e.target.files||[];for(vari=0;i<files.length;i++){varfile=files[i];if(this.isFileAllowed(file)){result=true;this.onFileInserted(file);this.uploadFile(file);}}if(result){e.preventDefault();}returnresult;}
add the option to defaults
/** * Binded File Input element to trigger uploaded when changed */bindedFileInput: undefined,
great plugin btw.
The text was updated successfully, but these errors were encountered:
In github comment box, you have the option to drag/drop, paste or select file/images. This plugin lacks the "select" using file input.
I achieved this by directly modifying a dist js (jquery version) by adding the option
bindedFileInput
. This should trigger the upload whenchange
event occurs on the input element. I'm not that familiar with grunt/npm and don't have the time implement a build so if your kind enough to add this bits of code for me that would be awesome.init (jquery)
inside class definition
add the option to defaults
great plugin btw.
The text was updated successfully, but these errors were encountered: