From cbd6eef04a097912466794d1e88defb03c8fcdbf Mon Sep 17 00:00:00 2001 From: Min RK Date: Wed, 4 Jan 2017 13:20:13 +0100 Subject: [PATCH] get preact from script tag doesn't seem to like loading with require --- notebook/static/notebook/js/notebook.js | 11 ++++----- notebook/templates/page.html | 15 +++++++----- package.json | 4 ++++ setupbase.py | 32 +++++++++++++++++++++---- tools/build-main.js | 2 +- 5 files changed, 46 insertions(+), 18 deletions(-) diff --git a/notebook/static/notebook/js/notebook.js b/notebook/static/notebook/js/notebook.js index 42eb3344b..ffa0fae22 100644 --- a/notebook/static/notebook/js/notebook.js +++ b/notebook/static/notebook/js/notebook.js @@ -30,9 +30,7 @@ define([ './celltoolbarpresets/attachments', './scrollmanager', './commandpalette', - // FIXME: shortcut-editor uses preact, - // which doesn't boewr install - // 'notebook/js/shortcuteditor', + './shortcuteditor', ], function ( $, IPython, @@ -57,10 +55,11 @@ define([ slideshow_celltoolbar, attachments_celltoolbar, scrollmanager, - commandpalette - // ShortcutEditor + commandpalette, + shortcuteditor ) { + var ShortcutEditor = shortcuteditor.ShortcutEditor; var _SOFT_SELECTION_CLASS = 'jupyter-soft-selected'; function soft_selected(cell){ @@ -443,7 +442,7 @@ define([ Notebook.prototype.show_shortcuts_editor = function() { // FIXME: ShortcutEditor disabled for now - // new ShortcutEditor(this); + new ShortcutEditor(this); }; /** diff --git a/notebook/templates/page.html b/notebook/templates/page.html index 0c34b5e17..e9c56c865 100644 --- a/notebook/templates/page.html +++ b/notebook/templates/page.html @@ -16,7 +16,10 @@ {% endblock %} - + + + +