From dcb2566712a2ca96e711b22ef1a0351c637f249a Mon Sep 17 00:00:00 2001
From: chris <kokosias@yahoo.gr>
Date: Thu, 13 Aug 2020 00:04:01 +0300
Subject: [PATCH] use name and enable terser

---
 wax-prosemirror-components/rollup.config.js    |  2 +-
 wax-prosemirror-core/rollup.config.js          |  2 +-
 wax-prosemirror-layouts/rollup.config.js       |  2 +-
 wax-prosemirror-plugins/rollup.config.js       |  2 +-
 wax-prosemirror-schema/rollup.config.js        |  2 +-
 wax-prosemirror-services/rollup.config.js      |  2 +-
 .../src/BaseService/RedoService/Redo.js        |  1 +
 .../src/BaseService/SaveService/Save.js        | 12 +++++++-----
 .../src/BaseService/UndoService/Undo.js        |  1 +
 .../src/CodeBlockService/CodeBlockTool.js      |  1 +
 .../DisplayBlockLevel/AuthorService/Author.js  |  1 +
 .../EpigraphPoetryService/EpigraphPoetry.js    |  1 +
 .../EpigraphProseService/EpigraphProse.js      |  1 +
 .../HeadingService/Heading1.js                 |  1 +
 .../HeadingService/Heading2.js                 |  1 +
 .../HeadingService/Heading3.js                 |  1 +
 .../SubTitleService/SubTitle.js                |  1 +
 .../DisplayBlockLevel/TitleService/Title.js    |  1 +
 .../src/ImageService/Image.js                  |  1 +
 .../src/InlineAnnotations/CodeService/Code.js  |  3 ++-
 .../EmphasisService/Emphasis.js                |  3 ++-
 .../StrikeThroughService/StrikeThrough.js      | 18 ++++++++++--------
 .../InlineAnnotations/StrongService/Strong.js  | 16 +++++++++-------
 .../SubscriptService/Subscript.js              | 16 +++++++++-------
 .../SuperscriptService/Superscript.js          | 16 +++++++++-------
 .../UnderlineService/Underline.js              | 16 +++++++++-------
 .../src/LinkService/LinkTool.js                | 13 +++++++------
 .../BulletListService/BulletList.js            |  6 ++++--
 .../src/ListsService/JoinUpService/JoinUp.js   | 14 ++++++++------
 .../src/ListsService/LiftService/Lift.js       | 14 ++++++++------
 .../OrderedListService/OrderedList.js          |  1 +
 .../src/NoteService/Note.js                    |  4 +++-
 .../EditTableService/TableDropDownOptions.js   |  1 +
 .../TablesService/InsertTableService/Table.js  |  1 +
 .../BlockQuoteService/BlockQuote.js            |  1 +
 .../ExtractPoetryService/ExtractPoetry.js      |  3 ++-
 .../ExtractProseService/ExtractProse.js        |  3 ++-
 .../ParagraphContinued.js                      |  3 ++-
 .../ParagraphService/Paragraph.js              |  4 +++-
 .../SourceNoteService/SourceNote.js            |  1 +
 .../AcceptTrackChange.js                       |  1 +
 .../EnableTrackChange.js                       |  1 +
 .../RejectTrackChange.js                       |  1 +
 wax-prosemirror-services/src/lib/ToolGroup.js  |  5 ++---
 wax-prosemirror-services/src/lib/Tools.js      |  2 +-
 wax-prosemirror-themes/rollup.config.js        |  2 +-
 wax-prosemirror-utilities/rollup.config.js     |  2 +-
 47 files changed, 127 insertions(+), 80 deletions(-)

diff --git a/wax-prosemirror-components/rollup.config.js b/wax-prosemirror-components/rollup.config.js
index 776c3cdd2..24921acbc 100644
--- a/wax-prosemirror-components/rollup.config.js
+++ b/wax-prosemirror-components/rollup.config.js
@@ -22,7 +22,7 @@ export default {
       runtimeHelpers: true,
     }),
     commonjs(),
-    // terser(),
+    terser(),
   ],
   external: [
     'wax-prosemirror-themes',
diff --git a/wax-prosemirror-core/rollup.config.js b/wax-prosemirror-core/rollup.config.js
index 15579cf57..f2b2c1be2 100644
--- a/wax-prosemirror-core/rollup.config.js
+++ b/wax-prosemirror-core/rollup.config.js
@@ -26,7 +26,7 @@ export default {
       runtimeHelpers: true,
     }),
     commonjs(),
-    // terser(),
+    terser(),
   ],
   external: [
     '@fortawesome/react-fontawesome',
diff --git a/wax-prosemirror-layouts/rollup.config.js b/wax-prosemirror-layouts/rollup.config.js
index 63bc022a1..15f2b480f 100644
--- a/wax-prosemirror-layouts/rollup.config.js
+++ b/wax-prosemirror-layouts/rollup.config.js
@@ -22,7 +22,7 @@ export default {
       runtimeHelpers: true,
     }),
     commonjs(),
-    // terser(),
+    terser(),
   ],
   external: [
     '@fortawesome/react-fontawesome',
diff --git a/wax-prosemirror-plugins/rollup.config.js b/wax-prosemirror-plugins/rollup.config.js
index 77ded1e2e..1f3d57d4d 100644
--- a/wax-prosemirror-plugins/rollup.config.js
+++ b/wax-prosemirror-plugins/rollup.config.js
@@ -21,6 +21,6 @@ export default {
       runtimeHelpers: true,
     }),
     commonjs(),
-    // terser(),
+    terser(),
   ],
 };
diff --git a/wax-prosemirror-schema/rollup.config.js b/wax-prosemirror-schema/rollup.config.js
index a2329d43d..43dfe7a10 100644
--- a/wax-prosemirror-schema/rollup.config.js
+++ b/wax-prosemirror-schema/rollup.config.js
@@ -21,7 +21,7 @@ export default {
       runtimeHelpers: true,
     }),
     commonjs(),
-    // terser(),
+    terser(),
   ],
   external: ['uuid', 'wax-prosemirror-utilities'],
 };
diff --git a/wax-prosemirror-services/rollup.config.js b/wax-prosemirror-services/rollup.config.js
index 9104a937f..7e63479d1 100644
--- a/wax-prosemirror-services/rollup.config.js
+++ b/wax-prosemirror-services/rollup.config.js
@@ -26,7 +26,7 @@ export default {
       runtimeHelpers: true,
     }),
     commonjs(),
-    // terser(),
+    terser(),
   ],
   external: [
     'uuid',
diff --git a/wax-prosemirror-services/src/BaseService/RedoService/Redo.js b/wax-prosemirror-services/src/BaseService/RedoService/Redo.js
index ead618d61..095a111d3 100644
--- a/wax-prosemirror-services/src/BaseService/RedoService/Redo.js
+++ b/wax-prosemirror-services/src/BaseService/RedoService/Redo.js
@@ -9,6 +9,7 @@ class Redo extends Tools {
   title = 'Redo last undone change';
   content = icons.redo;
   onlyOnMain = true;
+  name = 'Redo';
 
   get run() {
     return (state, dispatch) => {
diff --git a/wax-prosemirror-services/src/BaseService/SaveService/Save.js b/wax-prosemirror-services/src/BaseService/SaveService/Save.js
index 6d43004ad..ea7c9c3db 100644
--- a/wax-prosemirror-services/src/BaseService/SaveService/Save.js
+++ b/wax-prosemirror-services/src/BaseService/SaveService/Save.js
@@ -1,11 +1,13 @@
-import Tools from "../../lib/Tools";
-import { injectable } from "inversify";
-import { icons } from "wax-prosemirror-components";
+import Tools from '../../lib/Tools';
+import { injectable } from 'inversify';
+import { icons } from 'wax-prosemirror-components';
 
+export default
 @injectable()
-export default class Save extends Tools {
-  title = "Save changes";
+class Save extends Tools {
+  title = 'Save changes';
   content = icons.save;
+  name = 'Save';
 
   get run() {}
 
diff --git a/wax-prosemirror-services/src/BaseService/UndoService/Undo.js b/wax-prosemirror-services/src/BaseService/UndoService/Undo.js
index 071547dce..635163611 100644
--- a/wax-prosemirror-services/src/BaseService/UndoService/Undo.js
+++ b/wax-prosemirror-services/src/BaseService/UndoService/Undo.js
@@ -9,6 +9,7 @@ class Undo extends Tools {
   title = 'Undo last change';
   content = icons.undo;
   onlyOnMain = true;
+  name = 'Undo';
 
   get run() {
     return (state, dispatch) => {
diff --git a/wax-prosemirror-services/src/CodeBlockService/CodeBlockTool.js b/wax-prosemirror-services/src/CodeBlockService/CodeBlockTool.js
index b533ca58d..49bba48d5 100644
--- a/wax-prosemirror-services/src/CodeBlockService/CodeBlockTool.js
+++ b/wax-prosemirror-services/src/CodeBlockService/CodeBlockTool.js
@@ -7,6 +7,7 @@ import Tools from '../lib/Tools';
 class CodeBlockTool extends Tools {
   title = 'Insert Code Block';
   content = icons.code_block;
+  name = 'CodeBlockTool';
 
   get run() {
     return (state, dispatch) => {
diff --git a/wax-prosemirror-services/src/DisplayBlockLevel/AuthorService/Author.js b/wax-prosemirror-services/src/DisplayBlockLevel/AuthorService/Author.js
index a3ee0f83e..eef6df395 100644
--- a/wax-prosemirror-services/src/DisplayBlockLevel/AuthorService/Author.js
+++ b/wax-prosemirror-services/src/DisplayBlockLevel/AuthorService/Author.js
@@ -6,6 +6,7 @@ import Tools from '../../lib/Tools';
 class Author extends Tools {
   title = 'Change to Author';
   content = 'Author';
+  name = 'Author';
 
   get run() {
     return (state, dispatch) => {
diff --git a/wax-prosemirror-services/src/DisplayBlockLevel/EpigraphPoetryService/EpigraphPoetry.js b/wax-prosemirror-services/src/DisplayBlockLevel/EpigraphPoetryService/EpigraphPoetry.js
index b0637041a..86703bcc9 100644
--- a/wax-prosemirror-services/src/DisplayBlockLevel/EpigraphPoetryService/EpigraphPoetry.js
+++ b/wax-prosemirror-services/src/DisplayBlockLevel/EpigraphPoetryService/EpigraphPoetry.js
@@ -6,6 +6,7 @@ import Tools from '../../lib/Tools';
 class EpigraphPoetry extends Tools {
   title = 'Change to Epigraph Poetry';
   content = 'Epigraph Poetry';
+  name = 'EpigraphPoetry';
 
   get run() {
     return (state, dispatch) => {
diff --git a/wax-prosemirror-services/src/DisplayBlockLevel/EpigraphProseService/EpigraphProse.js b/wax-prosemirror-services/src/DisplayBlockLevel/EpigraphProseService/EpigraphProse.js
index 7ec1f1494..170d559d8 100644
--- a/wax-prosemirror-services/src/DisplayBlockLevel/EpigraphProseService/EpigraphProse.js
+++ b/wax-prosemirror-services/src/DisplayBlockLevel/EpigraphProseService/EpigraphProse.js
@@ -7,6 +7,7 @@ export default
 class EpigraphProse extends Tools {
   title = 'Change to Epigraph Prose';
   content = 'Epigraph Prose';
+  name = 'EpigraphProse';
 
   get run() {
     return (state, dispatch) => {
diff --git a/wax-prosemirror-services/src/DisplayBlockLevel/HeadingService/Heading1.js b/wax-prosemirror-services/src/DisplayBlockLevel/HeadingService/Heading1.js
index ce22bd8b3..c064fd695 100644
--- a/wax-prosemirror-services/src/DisplayBlockLevel/HeadingService/Heading1.js
+++ b/wax-prosemirror-services/src/DisplayBlockLevel/HeadingService/Heading1.js
@@ -7,6 +7,7 @@ export default
 class Heading1 extends Tools {
   title = 'Change to heading level 1';
   content = 'Heading 1';
+  name = 'Heading1';
 
   get run() {
     return (state, dispatch) => {
diff --git a/wax-prosemirror-services/src/DisplayBlockLevel/HeadingService/Heading2.js b/wax-prosemirror-services/src/DisplayBlockLevel/HeadingService/Heading2.js
index da4295986..061b45e86 100644
--- a/wax-prosemirror-services/src/DisplayBlockLevel/HeadingService/Heading2.js
+++ b/wax-prosemirror-services/src/DisplayBlockLevel/HeadingService/Heading2.js
@@ -7,6 +7,7 @@ export default
 class Heading2 extends Tools {
   title = 'Change to heading level 2';
   content = 'Heading 2';
+  name = 'Heading2';
 
   get run() {
     return (state, dispatch) => {
diff --git a/wax-prosemirror-services/src/DisplayBlockLevel/HeadingService/Heading3.js b/wax-prosemirror-services/src/DisplayBlockLevel/HeadingService/Heading3.js
index 1706b0c14..642e44d34 100644
--- a/wax-prosemirror-services/src/DisplayBlockLevel/HeadingService/Heading3.js
+++ b/wax-prosemirror-services/src/DisplayBlockLevel/HeadingService/Heading3.js
@@ -7,6 +7,7 @@ export default
 class Heading3 extends Tools {
   title = 'Change to heading level 3';
   content = 'Heading 3';
+  name = 'Heading3';
 
   get run() {
     return (state, dispatch) => {
diff --git a/wax-prosemirror-services/src/DisplayBlockLevel/SubTitleService/SubTitle.js b/wax-prosemirror-services/src/DisplayBlockLevel/SubTitleService/SubTitle.js
index d8957703e..ee18810ff 100644
--- a/wax-prosemirror-services/src/DisplayBlockLevel/SubTitleService/SubTitle.js
+++ b/wax-prosemirror-services/src/DisplayBlockLevel/SubTitleService/SubTitle.js
@@ -6,6 +6,7 @@ import { Commands } from 'wax-prosemirror-utilities';
 export default class SubTitle extends Tools {
   title = 'Change to Subtitle';
   content = 'Subtitle';
+  name = 'SubTitle';
 
   get run() {
     return (state, dispatch) => {
diff --git a/wax-prosemirror-services/src/DisplayBlockLevel/TitleService/Title.js b/wax-prosemirror-services/src/DisplayBlockLevel/TitleService/Title.js
index 7548b7b70..37a70eb6a 100644
--- a/wax-prosemirror-services/src/DisplayBlockLevel/TitleService/Title.js
+++ b/wax-prosemirror-services/src/DisplayBlockLevel/TitleService/Title.js
@@ -6,6 +6,7 @@ import { Commands } from 'wax-prosemirror-utilities';
 export default class Title extends Tools {
   title = 'Change to Title';
   content = 'Title';
+  name = 'Title';
 
   get run() {
     return (state, dispatch) => {
diff --git a/wax-prosemirror-services/src/ImageService/Image.js b/wax-prosemirror-services/src/ImageService/Image.js
index 726284945..83c3f235c 100644
--- a/wax-prosemirror-services/src/ImageService/Image.js
+++ b/wax-prosemirror-services/src/ImageService/Image.js
@@ -12,6 +12,7 @@ export default
 class Image extends Tools {
   title = 'Insert image';
   content = icons.image;
+  name = 'Image';
 
   get run() {
     return () => true;
diff --git a/wax-prosemirror-services/src/InlineAnnotations/CodeService/Code.js b/wax-prosemirror-services/src/InlineAnnotations/CodeService/Code.js
index a6ccd2ffc..413d7b842 100644
--- a/wax-prosemirror-services/src/InlineAnnotations/CodeService/Code.js
+++ b/wax-prosemirror-services/src/InlineAnnotations/CodeService/Code.js
@@ -1,14 +1,15 @@
 import { toggleMark } from 'prosemirror-commands';
 import { Commands } from 'wax-prosemirror-utilities';
-import Tools from '../../lib/Tools';
 import { injectable } from 'inversify';
 import { icons } from 'wax-prosemirror-components';
+import Tools from '../../lib/Tools';
 
 export default
 @injectable()
 class Code extends Tools {
   title = 'Toggle code';
   content = icons.code;
+  name = 'Code';
 
   get run() {
     return (state, dispatch) => {
diff --git a/wax-prosemirror-services/src/InlineAnnotations/EmphasisService/Emphasis.js b/wax-prosemirror-services/src/InlineAnnotations/EmphasisService/Emphasis.js
index 89f79677f..afacd594d 100644
--- a/wax-prosemirror-services/src/InlineAnnotations/EmphasisService/Emphasis.js
+++ b/wax-prosemirror-services/src/InlineAnnotations/EmphasisService/Emphasis.js
@@ -1,14 +1,15 @@
 import { toggleMark } from 'prosemirror-commands';
 import { Commands } from 'wax-prosemirror-utilities';
-import Tools from '../../lib/Tools';
 import { injectable } from 'inversify';
 import { icons } from 'wax-prosemirror-components';
+import Tools from '../../lib/Tools';
 
 export default
 @injectable()
 class Emphasis extends Tools {
   title = 'Toggle emphasis';
   content = icons.em;
+  name = 'Emphasis';
 
   get run() {
     return (state, dispatch) => {
diff --git a/wax-prosemirror-services/src/InlineAnnotations/StrikeThroughService/StrikeThrough.js b/wax-prosemirror-services/src/InlineAnnotations/StrikeThroughService/StrikeThrough.js
index 60b3be567..f070bc17d 100644
--- a/wax-prosemirror-services/src/InlineAnnotations/StrikeThroughService/StrikeThrough.js
+++ b/wax-prosemirror-services/src/InlineAnnotations/StrikeThroughService/StrikeThrough.js
@@ -1,13 +1,15 @@
-import { toggleMark } from "prosemirror-commands";
-import { Commands } from "wax-prosemirror-utilities";
-import Tools from "../../lib/Tools";
-import { injectable } from "inversify";
-import { icons } from "wax-prosemirror-components";
+import { toggleMark } from 'prosemirror-commands';
+import { Commands } from 'wax-prosemirror-utilities';
+import { injectable } from 'inversify';
+import { icons } from 'wax-prosemirror-components';
+import Tools from '../../lib/Tools';
 
+export default
 @injectable()
-export default class StrikeThrough extends Tools {
-  title = "Toggle strikethrough";
+class StrikeThrough extends Tools {
+  title = 'Toggle strikethrough';
   content = icons.strikethrough;
+  name = 'StrikeThrough';
 
   get run() {
     return (state, dispatch) => {
@@ -18,7 +20,7 @@ export default class StrikeThrough extends Tools {
   get active() {
     return state => {
       return Commands.markActive(state.config.schema.marks.strikethrough)(
-        state
+        state,
       );
     };
   }
diff --git a/wax-prosemirror-services/src/InlineAnnotations/StrongService/Strong.js b/wax-prosemirror-services/src/InlineAnnotations/StrongService/Strong.js
index 989f238a2..ef85988a5 100644
--- a/wax-prosemirror-services/src/InlineAnnotations/StrongService/Strong.js
+++ b/wax-prosemirror-services/src/InlineAnnotations/StrongService/Strong.js
@@ -1,13 +1,15 @@
-import { toggleMark } from "prosemirror-commands";
-import { Commands } from "wax-prosemirror-utilities";
-import Tools from "../../lib/Tools";
-import { injectable } from "inversify";
-import { icons } from "wax-prosemirror-components";
+import { toggleMark } from 'prosemirror-commands';
+import { Commands } from 'wax-prosemirror-utilities';
+import Tools from '../../lib/Tools';
+import { injectable } from 'inversify';
+import { icons } from 'wax-prosemirror-components';
 
+export default
 @injectable()
-export default class Strong extends Tools {
-  title = "Toggle strong";
+class Strong extends Tools {
+  title = 'Toggle strong';
   content = icons.strong;
+  name = 'Strong';
 
   get run() {
     return (state, dispatch) => {
diff --git a/wax-prosemirror-services/src/InlineAnnotations/SubscriptService/Subscript.js b/wax-prosemirror-services/src/InlineAnnotations/SubscriptService/Subscript.js
index 9bfd47526..9e5e19410 100644
--- a/wax-prosemirror-services/src/InlineAnnotations/SubscriptService/Subscript.js
+++ b/wax-prosemirror-services/src/InlineAnnotations/SubscriptService/Subscript.js
@@ -1,13 +1,15 @@
-import { toggleMark } from "prosemirror-commands";
-import { Commands } from "wax-prosemirror-utilities";
-import Tools from "../../lib/Tools";
-import { injectable } from "inversify";
-import { icons } from "wax-prosemirror-components";
+import { toggleMark } from 'prosemirror-commands';
+import { Commands } from 'wax-prosemirror-utilities';
+import { injectable } from 'inversify';
+import { icons } from 'wax-prosemirror-components';
+import Tools from '../../lib/Tools';
 
+export default
 @injectable()
-export default class Subscript extends Tools {
-  title = "Toggle subscript";
+class Subscript extends Tools {
+  title = 'Toggle subscript';
   content = icons.subscript;
+  name = 'Subscript';
 
   get run() {
     return (state, dispatch) => {
diff --git a/wax-prosemirror-services/src/InlineAnnotations/SuperscriptService/Superscript.js b/wax-prosemirror-services/src/InlineAnnotations/SuperscriptService/Superscript.js
index f502bbf7c..64fbd2a46 100644
--- a/wax-prosemirror-services/src/InlineAnnotations/SuperscriptService/Superscript.js
+++ b/wax-prosemirror-services/src/InlineAnnotations/SuperscriptService/Superscript.js
@@ -1,13 +1,15 @@
-import { toggleMark } from "prosemirror-commands";
-import { Commands } from "wax-prosemirror-utilities";
-import Tools from "../../lib/Tools";
-import { injectable } from "inversify";
-import { icons } from "wax-prosemirror-components";
+import { toggleMark } from 'prosemirror-commands';
+import { Commands } from 'wax-prosemirror-utilities';
+import { injectable } from 'inversify';
+import { icons } from 'wax-prosemirror-components';
+import Tools from '../../lib/Tools';
 
+export default
 @injectable()
-export default class Superscript extends Tools {
-  title = "Toggle superscript";
+class Superscript extends Tools {
+  title = 'Toggle superscript';
   content = icons.superscript;
+  name = 'Superscript';
 
   get run() {
     return (state, dispatch) => {
diff --git a/wax-prosemirror-services/src/InlineAnnotations/UnderlineService/Underline.js b/wax-prosemirror-services/src/InlineAnnotations/UnderlineService/Underline.js
index 168dcb15f..9947a9817 100644
--- a/wax-prosemirror-services/src/InlineAnnotations/UnderlineService/Underline.js
+++ b/wax-prosemirror-services/src/InlineAnnotations/UnderlineService/Underline.js
@@ -1,13 +1,15 @@
-import { toggleMark } from "prosemirror-commands";
-import { Commands } from "wax-prosemirror-utilities";
-import Tools from "../../lib/Tools";
-import { injectable } from "inversify";
-import { icons } from "wax-prosemirror-components";
+import { toggleMark } from 'prosemirror-commands';
+import { Commands } from 'wax-prosemirror-utilities';
+import { injectable } from 'inversify';
+import { icons } from 'wax-prosemirror-components';
+import Tools from '../../lib/Tools';
 
+export default
 @injectable()
-export default class Underline extends Tools {
-  title = "Toggle underline";
+class Underline extends Tools {
+  title = 'Toggle underline';
   content = icons.underline;
+  name = 'Underline';
 
   get run() {
     return (state, dispatch) => {
diff --git a/wax-prosemirror-services/src/LinkService/LinkTool.js b/wax-prosemirror-services/src/LinkService/LinkTool.js
index 424444dc1..ca9e24b66 100644
--- a/wax-prosemirror-services/src/LinkService/LinkTool.js
+++ b/wax-prosemirror-services/src/LinkService/LinkTool.js
@@ -1,13 +1,14 @@
-import { injectable } from "inversify";
-import { toggleMark } from "prosemirror-commands";
-import { Commands } from "wax-prosemirror-utilities";
-import Tools from "../lib/Tools";
-import { icons } from "wax-prosemirror-components";
+import { injectable } from 'inversify';
+import { toggleMark } from 'prosemirror-commands';
+import { Commands } from 'wax-prosemirror-utilities';
+import Tools from '../lib/Tools';
+import { icons } from 'wax-prosemirror-components';
 
 @injectable()
 export default class LinkTool extends Tools {
-  title = "Add or remove link";
+  title = 'Add or remove link';
   content = icons.link;
+  name = 'LinkTool';
 
   get run() {
     return (state, dispatch) => {
diff --git a/wax-prosemirror-services/src/ListsService/BulletListService/BulletList.js b/wax-prosemirror-services/src/ListsService/BulletListService/BulletList.js
index eab23cb2a..7eaed9bc1 100644
--- a/wax-prosemirror-services/src/ListsService/BulletListService/BulletList.js
+++ b/wax-prosemirror-services/src/ListsService/BulletListService/BulletList.js
@@ -1,13 +1,15 @@
-import Tools from '../../lib/Tools';
 import { injectable } from 'inversify';
 import { icons } from 'wax-prosemirror-components';
 import { wrapInList } from 'prosemirror-schema-list';
 import { Commands } from 'wax-prosemirror-utilities';
+import Tools from '../../lib/Tools';
 
+export default
 @injectable()
-export default class BulletList extends Tools {
+class BulletList extends Tools {
   title = 'Wrap in bullet list';
   content = icons.bullet_list;
+  name = 'BulletList';
 
   get run() {
     return (state, dispatch) => {
diff --git a/wax-prosemirror-services/src/ListsService/JoinUpService/JoinUp.js b/wax-prosemirror-services/src/ListsService/JoinUpService/JoinUp.js
index 0e5907bd1..41239d986 100644
--- a/wax-prosemirror-services/src/ListsService/JoinUpService/JoinUp.js
+++ b/wax-prosemirror-services/src/ListsService/JoinUpService/JoinUp.js
@@ -1,12 +1,14 @@
-import { joinUp } from "prosemirror-commands";
-import Tools from "../../lib/Tools";
-import { injectable } from "inversify";
-import { icons } from "wax-prosemirror-components";
+import { joinUp } from 'prosemirror-commands';
+import Tools from '../../lib/Tools';
+import { injectable } from 'inversify';
+import { icons } from 'wax-prosemirror-components';
 
+export default
 @injectable()
-export default class JoinUp extends Tools {
-  title = "Join with above block";
+class JoinUp extends Tools {
+  title = 'Join with above block';
   content = icons.join_up;
+  name = 'JoinUp';
 
   get run() {
     return joinUp;
diff --git a/wax-prosemirror-services/src/ListsService/LiftService/Lift.js b/wax-prosemirror-services/src/ListsService/LiftService/Lift.js
index 2bf470082..452d24663 100644
--- a/wax-prosemirror-services/src/ListsService/LiftService/Lift.js
+++ b/wax-prosemirror-services/src/ListsService/LiftService/Lift.js
@@ -1,12 +1,14 @@
-import { lift } from "prosemirror-commands";
-import Tools from "../../lib/Tools";
-import { injectable } from "inversify";
-import { icons } from "wax-prosemirror-components";
+import { lift } from 'prosemirror-commands';
+import Tools from '../../lib/Tools';
+import { injectable } from 'inversify';
+import { icons } from 'wax-prosemirror-components';
 
+export default
 @injectable()
-export default class Lift extends Tools {
-  title = "Lift out of enclosing block";
+class Lift extends Tools {
+  title = 'Lift out of enclosing block';
   content = icons.lift;
+  name = 'Lift';
 
   get run() {
     return lift;
diff --git a/wax-prosemirror-services/src/ListsService/OrderedListService/OrderedList.js b/wax-prosemirror-services/src/ListsService/OrderedListService/OrderedList.js
index e421df095..7cf174b45 100644
--- a/wax-prosemirror-services/src/ListsService/OrderedListService/OrderedList.js
+++ b/wax-prosemirror-services/src/ListsService/OrderedListService/OrderedList.js
@@ -8,6 +8,7 @@ import { Commands } from 'wax-prosemirror-utilities';
 export default class OrderedList extends Tools {
   title = 'Wrap in ordered list';
   content = icons.ordered_list;
+  name = 'OrderedList';
 
   get run() {
     return (state, dispatch) => {
diff --git a/wax-prosemirror-services/src/NoteService/Note.js b/wax-prosemirror-services/src/NoteService/Note.js
index 75f04f45b..c86840e98 100644
--- a/wax-prosemirror-services/src/NoteService/Note.js
+++ b/wax-prosemirror-services/src/NoteService/Note.js
@@ -4,10 +4,12 @@ import { icons } from 'wax-prosemirror-components';
 import { Fragment } from 'prosemirror-model';
 import { v4 as uuidv4 } from 'uuid';
 
+export default
 @injectable()
-export default class Note extends Tools {
+class Note extends Tools {
   title = 'Insert Note';
   content = icons.footnote;
+  name = 'Note';
 
   get run() {
     return (state, dispatch) => {
diff --git a/wax-prosemirror-services/src/TablesService/EditTableService/TableDropDownOptions.js b/wax-prosemirror-services/src/TablesService/EditTableService/TableDropDownOptions.js
index d48701582..411384c05 100644
--- a/wax-prosemirror-services/src/TablesService/EditTableService/TableDropDownOptions.js
+++ b/wax-prosemirror-services/src/TablesService/EditTableService/TableDropDownOptions.js
@@ -11,6 +11,7 @@ import Tools from '../../lib/Tools';
 export default class TableDropDownOptions extends Tools {
   title = 'Select Options';
   content = 'table';
+  name = 'TableDropDownOptions';
 
   get run() {
     return (state, dispatch, tableFn) => {
diff --git a/wax-prosemirror-services/src/TablesService/InsertTableService/Table.js b/wax-prosemirror-services/src/TablesService/InsertTableService/Table.js
index 5e0f68505..00ae9ee39 100644
--- a/wax-prosemirror-services/src/TablesService/InsertTableService/Table.js
+++ b/wax-prosemirror-services/src/TablesService/InsertTableService/Table.js
@@ -8,6 +8,7 @@ export default
 class Table extends Tools {
   title = 'Insert table';
   content = icons.table;
+  name = 'Table';
 
   get run() {
     return (state, dispatch) => {
diff --git a/wax-prosemirror-services/src/TextBlockLevel/BlockQuoteService/BlockQuote.js b/wax-prosemirror-services/src/TextBlockLevel/BlockQuoteService/BlockQuote.js
index 2c2e9ceb2..e2e0d3c6a 100644
--- a/wax-prosemirror-services/src/TextBlockLevel/BlockQuoteService/BlockQuote.js
+++ b/wax-prosemirror-services/src/TextBlockLevel/BlockQuoteService/BlockQuote.js
@@ -6,6 +6,7 @@ import { wrapIn } from 'prosemirror-commands';
 class BlockQuote extends Tools {
   title = 'Change to Block Quote';
   content = 'Block Quote';
+  name = 'BlockQuote';
 
   get run() {
     return (state, dispatch) => {
diff --git a/wax-prosemirror-services/src/TextBlockLevel/ExtractPoetryService/ExtractPoetry.js b/wax-prosemirror-services/src/TextBlockLevel/ExtractPoetryService/ExtractPoetry.js
index 8ec0b529d..529cc75c3 100644
--- a/wax-prosemirror-services/src/TextBlockLevel/ExtractPoetryService/ExtractPoetry.js
+++ b/wax-prosemirror-services/src/TextBlockLevel/ExtractPoetryService/ExtractPoetry.js
@@ -1,11 +1,12 @@
-import Tools from '../../lib/Tools';
 import { injectable } from 'inversify';
 import { Commands } from 'wax-prosemirror-utilities';
+import Tools from '../../lib/Tools';
 
 @injectable()
 class ExtractPoetry extends Tools {
   title = 'Change to Extract Poetry';
   content = 'Extract Poetry';
+  name = 'ExtractPoetry';
 
   get run() {
     return (state, dispatch) => {
diff --git a/wax-prosemirror-services/src/TextBlockLevel/ExtractProseService/ExtractProse.js b/wax-prosemirror-services/src/TextBlockLevel/ExtractProseService/ExtractProse.js
index c3acd93e4..7e2d707b1 100644
--- a/wax-prosemirror-services/src/TextBlockLevel/ExtractProseService/ExtractProse.js
+++ b/wax-prosemirror-services/src/TextBlockLevel/ExtractProseService/ExtractProse.js
@@ -1,11 +1,12 @@
-import Tools from '../../lib/Tools';
 import { injectable } from 'inversify';
 import { Commands } from 'wax-prosemirror-utilities';
+import Tools from '../../lib/Tools';
 
 @injectable()
 class ExtractProse extends Tools {
   title = 'Change to Extract Prose';
   content = 'Extract Prose';
+  name = 'ExtractProse';
 
   get run() {
     return (state, dispatch) => {
diff --git a/wax-prosemirror-services/src/TextBlockLevel/ParagraphContinuedService/ParagraphContinued.js b/wax-prosemirror-services/src/TextBlockLevel/ParagraphContinuedService/ParagraphContinued.js
index c3d9b03ed..926eb2588 100644
--- a/wax-prosemirror-services/src/TextBlockLevel/ParagraphContinuedService/ParagraphContinued.js
+++ b/wax-prosemirror-services/src/TextBlockLevel/ParagraphContinuedService/ParagraphContinued.js
@@ -1,11 +1,12 @@
-import Tools from '../../lib/Tools';
 import { injectable } from 'inversify';
 import { Commands } from 'wax-prosemirror-utilities';
+import Tools from '../../lib/Tools';
 
 @injectable()
 class ParagraphContinued extends Tools {
   title = 'Change to Paragraph Continued';
   content = 'Paragraph Continued';
+  name = 'ParagraphContinued';
 
   get run() {
     return (state, dispatch) => {
diff --git a/wax-prosemirror-services/src/TextBlockLevel/ParagraphService/Paragraph.js b/wax-prosemirror-services/src/TextBlockLevel/ParagraphService/Paragraph.js
index 918ae7607..f7c892c42 100644
--- a/wax-prosemirror-services/src/TextBlockLevel/ParagraphService/Paragraph.js
+++ b/wax-prosemirror-services/src/TextBlockLevel/ParagraphService/Paragraph.js
@@ -2,10 +2,12 @@ import Tools from '../../lib/Tools';
 import { injectable } from 'inversify';
 import { Commands } from 'wax-prosemirror-utilities';
 
+export default 
 @injectable()
-export default class Paragraph extends Tools {
+class Paragraph extends Tools {
   title = 'Change to Paragraph';
   content = 'Paragraph';
+  name = 'Paragraph';
 
   get run() {
     return (state, dispatch) => {
diff --git a/wax-prosemirror-services/src/TextBlockLevel/SourceNoteService/SourceNote.js b/wax-prosemirror-services/src/TextBlockLevel/SourceNoteService/SourceNote.js
index b40a17d1d..c641f496c 100644
--- a/wax-prosemirror-services/src/TextBlockLevel/SourceNoteService/SourceNote.js
+++ b/wax-prosemirror-services/src/TextBlockLevel/SourceNoteService/SourceNote.js
@@ -6,6 +6,7 @@ import { Commands } from 'wax-prosemirror-utilities';
 class SourceNote extends Tools {
   title = 'Change to Source Note';
   content = 'Source Note';
+  name = 'SourceNote';
 
   get run() {
     return (state, dispatch) => {
diff --git a/wax-prosemirror-services/src/TrackChangeService/AcceptTrackChangeService/AcceptTrackChange.js b/wax-prosemirror-services/src/TrackChangeService/AcceptTrackChangeService/AcceptTrackChange.js
index 6eae10118..dc63a32a7 100644
--- a/wax-prosemirror-services/src/TrackChangeService/AcceptTrackChangeService/AcceptTrackChange.js
+++ b/wax-prosemirror-services/src/TrackChangeService/AcceptTrackChangeService/AcceptTrackChange.js
@@ -9,6 +9,7 @@ export default
 class AcceptTrackChange extends Tools {
   title = 'Accept Changes';
   content = 'Accept';
+  name = 'AcceptTrackChange';
 
   get run() {
     return (state, dispatch) => {
diff --git a/wax-prosemirror-services/src/TrackChangeService/EnableTrackChangeService/EnableTrackChange.js b/wax-prosemirror-services/src/TrackChangeService/EnableTrackChangeService/EnableTrackChange.js
index cc34abaef..9ad60b2b5 100644
--- a/wax-prosemirror-services/src/TrackChangeService/EnableTrackChangeService/EnableTrackChange.js
+++ b/wax-prosemirror-services/src/TrackChangeService/EnableTrackChangeService/EnableTrackChange.js
@@ -10,6 +10,7 @@ export default
 class EnableTrackChange extends Tools {
   title = 'Toggle Track Changes';
   content = 'track changes';
+  name = 'EnableTrackChange';
 
   get run() {
     return state => {
diff --git a/wax-prosemirror-services/src/TrackChangeService/RejectTrackChangeService/RejectTrackChange.js b/wax-prosemirror-services/src/TrackChangeService/RejectTrackChangeService/RejectTrackChange.js
index 24d68f97e..e7edca812 100644
--- a/wax-prosemirror-services/src/TrackChangeService/RejectTrackChangeService/RejectTrackChange.js
+++ b/wax-prosemirror-services/src/TrackChangeService/RejectTrackChangeService/RejectTrackChange.js
@@ -14,6 +14,7 @@ export default
 class RejectTrackChange extends Tools {
   title = 'Reject Changes';
   content = 'Reject';
+  name = 'RejectTrackChange';
 
   get run() {
     return (state, dispatch) => {
diff --git a/wax-prosemirror-services/src/lib/ToolGroup.js b/wax-prosemirror-services/src/lib/ToolGroup.js
index 5c5b0c792..93ce54c13 100644
--- a/wax-prosemirror-services/src/lib/ToolGroup.js
+++ b/wax-prosemirror-services/src/lib/ToolGroup.js
@@ -18,7 +18,7 @@ export default class ToolGroup {
 
     if (include.length > 0) {
       this._tools.map(tool => {
-        if (include.includes(tool.constructor.name)) {
+        if (include.includes(tool.name)) {
           tool.displayTool();
         } else {
           tool.hideTool();
@@ -26,7 +26,7 @@ export default class ToolGroup {
       });
     } else {
       this._tools.map(tool => {
-        if (exclude.includes(tool.constructor.name)) {
+        if (exclude.includes(tool.name)) {
           tool.hideTool();
         }
       });
@@ -38,7 +38,6 @@ export default class ToolGroup {
     if (more.length > 0) {
       this._tools.map(tool => {
         if (more.includes(tool.name)) {
-          console.log(tool);
           tool.hideInToolGroup();
         } else {
           tool.displayInToolGroup();
diff --git a/wax-prosemirror-services/src/lib/Tools.js b/wax-prosemirror-services/src/lib/Tools.js
index 7480015a6..4d9e90bfd 100644
--- a/wax-prosemirror-services/src/lib/Tools.js
+++ b/wax-prosemirror-services/src/lib/Tools.js
@@ -13,7 +13,7 @@ class Tools {
   onlyOnMain = false;
   config = {};
   pmplugins = {};
-  name = name;
+  name = 'name';
   constructor(@inject('Config') config, @inject('PmPlugins') pmplugins) {
     this.config = config;
     this.pmplugins = pmplugins;
diff --git a/wax-prosemirror-themes/rollup.config.js b/wax-prosemirror-themes/rollup.config.js
index 8e17dca19..3c39189e3 100644
--- a/wax-prosemirror-themes/rollup.config.js
+++ b/wax-prosemirror-themes/rollup.config.js
@@ -21,7 +21,7 @@ export default {
       runtimeHelpers: true,
     }),
     commonjs(),
-    // terser(),
+    terser(),
   ],
   external: ['styled-components'],
 };
diff --git a/wax-prosemirror-utilities/rollup.config.js b/wax-prosemirror-utilities/rollup.config.js
index 04222edfb..be04b1162 100644
--- a/wax-prosemirror-utilities/rollup.config.js
+++ b/wax-prosemirror-utilities/rollup.config.js
@@ -21,7 +21,7 @@ export default {
       runtimeHelpers: true,
     }),
     commonjs(),
-    // terser(),
+    terser(),
   ],
   external: ['uuid'],
 };
-- 
GitLab