Merge pull request #345 from jbutz/development

Prevent onclick event from bubbling
pull/347/merge
Wes Cossick 8 years ago
commit 97154e2bfc

@ -1696,7 +1696,8 @@ SimpleMDE.prototype.createToolbar = function(items) {
// bind events, special for info // bind events, special for info
if(item.action) { if(item.action) {
if(typeof item.action === "function") { if(typeof item.action === "function") {
el.onclick = function() { el.onclick = function(e) {
e.preventDefault();
item.action(self); item.action(self);
}; };
} else if(typeof item.action === "string") { } else if(typeof item.action === "string") {

Loading…
Cancel
Save