diff --git a/src/packages/editor-stats/src/editor-stats-view.coffee b/src/packages/editor-stats/src/editor-stats-view.coffee index 16c12bc6f..a35de475e 100644 --- a/src/packages/editor-stats/src/editor-stats-view.coffee +++ b/src/packages/editor-stats/src/editor-stats-view.coffee @@ -39,6 +39,17 @@ class EditorStatsView extends ScrollView @rootView.on 'keyup', @track @rootView.on 'mousedown', @track + append: -> + w = @.width() + h = @.height() + [pt, pl, pb, pr] = [0,0,0,0] + + d3.select(@.get(0)).append('svg') + .attr('width', w) + .attr('height', h) + .append('g') + .attr('transform', "translate(#{pl},#{pt})") + track: => date = new Date times = time date @@ -57,6 +68,7 @@ class EditorStatsView extends ScrollView attach: -> @rootView.append @ @focus() + @append() detach: => super()