]> BookStack Code Mirror - bookstack/blobdiff - resources/js/markdown/common-events.js
respective book and chapter structure added.
[bookstack] / resources / js / markdown / common-events.js
index 3afd03dd5fd2dd6baa8ce9691421d59f4f00274a..c3d803f7048c579b8c86f1e371e9c2b483927be0 100644 (file)
@@ -6,23 +6,22 @@ function getContentToInsert({html, markdown}) {
  * @param {MarkdownEditor} editor
  */
 export function listen(editor) {
-
-    window.$events.listen('editor::replace', (eventContent) => {
+    window.$events.listen('editor::replace', eventContent => {
         const markdown = getContentToInsert(eventContent);
         editor.actions.replaceContent(markdown);
     });
 
-    window.$events.listen('editor::append', (eventContent) => {
+    window.$events.listen('editor::append', eventContent => {
         const markdown = getContentToInsert(eventContent);
         editor.actions.appendContent(markdown);
     });
 
-    window.$events.listen('editor::prepend', (eventContent) => {
+    window.$events.listen('editor::prepend', eventContent => {
         const markdown = getContentToInsert(eventContent);
         editor.actions.prependContent(markdown);
     });
 
-    window.$events.listen('editor::insert', (eventContent) => {
+    window.$events.listen('editor::insert', eventContent => {
         const markdown = getContentToInsert(eventContent);
         editor.actions.insertContent(markdown);
     });
@@ -30,4 +29,4 @@ export function listen(editor) {
     window.$events.listen('editor::focus', () => {
         editor.actions.focus();
     });
-}
\ No newline at end of file
+}