fix: canvas again gets opportunity to react to footnote being closed
[fnpeditor.git] / src / editor / plugins / core / canvasElements.js
index 37eefb8..e74adee 100644 (file)
@@ -1,6 +1,7 @@
 define(function(require) {
     
 'use strict';
+var $ = require('libs/jquery');
 
 
 var widgets = {
@@ -49,7 +50,7 @@ var widgets = {
         });
         return mydom;
     }
-}
+};
 
 
 var comment = {
@@ -99,15 +100,15 @@ var footnote = {
         }
         this._container().toggle(toggle);
         if(!options.silent) {
-            this.trigger('elementToggled', toggle, this.documentElement);
+            this.trigger('elementToggled', toggle, this);
         }
     }
-}
+};
 
 
 return [
-    {klass: 'comment', element: comment},
-    {klass: 'footnote', element: footnote}
+    {tag: 'aside',   klass: 'comment', prototype: comment, extending: {tag: 'div'}},
+    {tag: 'aside', klass: 'footnote', prototype: footnote, extending: {tag: 'aside'}}
 ];