Browse Source

clean up the codemirror extension

Steven Silvester 8 years ago
parent
commit
e410abf4fc

+ 8 - 2
packages/codemirror-extension/package.json

@@ -11,7 +11,13 @@
   "directories": {
     "lib": "lib/"
   },
-  "dependencies": {},
+  "dependencies": {
+    "@jupyterlab/application": "^0.1.0",
+    "@jupyterlab/apputils": "^0.1.0",
+    "@jupyterlab/codeeditor": "^0.1.0",
+    "@jupyterlab/codemirror": "^0.1.0",
+    "@phosphor/widgets": "^0.3.1"
+  },
   "devDependencies": {
     "rimraf": "^2.5.2",
     "typescript": "^2.2.1"
@@ -30,4 +36,4 @@
     "url": "https://github.com/jupyterlab/jupyterlab/issues"
   },
   "homepage": "https://github.com/jupyterlab/jupyterlab"
-}
+}

+ 5 - 10
packages/codemirror-extension/src → packages/codemirror-extension/src/index.ts

@@ -1,34 +1,29 @@
 // Copyright (c) Jupyter Development Team.
 // Distributed under the terms of the Modified BSD License.
 
-import 'codemirror/addon/edit/matchbrackets.js';
-import 'codemirror/addon/edit/closebrackets.js';
-import 'codemirror/addon/comment/comment.js';
-import 'codemirror/keymap/vim.js';
-
 import {
   Menu
 } from '@phosphor/widgets';
 
 import {
   JupyterLab, JupyterLabPlugin
-} from '../application';
+} from '@jupyterlab/application';
 
 import {
   ICommandPalette, IMainMenu
-} from '../apputils';
+} from '@jupyterlab/apputils';
 
 import {
   IEditorServices
-} from '../codeeditor';
+} from '@jupyterlab/codeeditor';
 
 import {
   editorServices, CodeMirrorEditor
-} from '../codemirror';
+} from '@jupyterlab/codemirror';
 
 import {
   IEditorTracker
-} from '../editorwidget';
+} from '@jupyterlab/editorwidget';
 
 
 /**

+ 5 - 0
packages/codemirror/src/editor.ts

@@ -36,6 +36,11 @@ import {
   loadModeByMIME
 } from './';
 
+import 'codemirror/addon/edit/matchbrackets.js';
+import 'codemirror/addon/edit/closebrackets.js';
+import 'codemirror/addon/comment/comment.js';
+import 'codemirror/keymap/vim.js';
+
 
 /**
  * The class name added to CodeMirrorWidget instances.