Merge pull request #457 from acrox999/bluditv2

Added pagebreak button to SimpleMDE
This commit is contained in:
Diego Najar 2017-08-10 19:32:43 +02:00 committed by GitHub
commit 647b815362
1 changed files with 13 additions and 1 deletions

View File

@ -127,7 +127,19 @@ class pluginsimpleMDE extends Plugin {
uniqueId: "'.$autosaveID.'", uniqueId: "'.$autosaveID.'",
delay: 1000, delay: 1000,
}, },
toolbar: ['.Sanitize::htmlDecode($this->getDbField('toolbar')).'] toolbar: [ {
name: "pageBreak",
action: function addPageBreak(editor){
var cm = editor.codemirror;
output = "\n<!-- pagebreak -->\n\n";
cm.replaceSelection(output);
},
className: "fa fa-book",
title: "Pagebreak",
},
"|",
'.Sanitize::htmlDecode($this->getDbField('toolbar')).'
]
});'; });';
$html .= '}); </script>'; $html .= '}); </script>';