Ian Rose 8 years ago
parent
commit
bb685f687a

+ 3 - 3
packages/codemirror/src/editor.ts

@@ -611,9 +611,9 @@ class CodeMirrorEditor implements CodeEditor.IEditor {
    * Converts an editor selection to a code mirror selection.
    */
   private _toCodeMirrorSelection(selection: CodeEditor.IRange): CodeMirror.Selection {
-    //Selections only appear to render correctly if the anchor
-    //is before the head in the document. That is, reverse selections
-    //do not appear as intended.
+    // Selections only appear to render correctly if the anchor
+    // is before the head in the document. That is, reverse selections
+    // do not appear as intended.
     let forward: boolean = (selection.start.line < selection.end.line) ||
                            (selection.start.line === selection.end.line &&
                             selection.start.column <= selection.end.column);

+ 4 - 4
packages/fileeditor/src/widget.ts

@@ -52,7 +52,7 @@ class FileEditor extends CodeEditorWrapper {
     if (context.model.modelDB.isCollaborative) {
       let modelDB = context.model.modelDB;
       modelDB.connected.then(() => {
-        //Setup the selection style for collaborators
+        // Setup the selection style for collaborators
         let localCollaborator = modelDB.collaborators.localCollaborator;
         this.editor.uuid = localCollaborator.sessionId;
         this.editor.selectionStyle = {
@@ -60,7 +60,7 @@ class FileEditor extends CodeEditorWrapper {
         };
 
         modelDB.collaborators.changed.connect(this._onCollaboratorsChanged, this);
-        //Trigger an initial onCollaboratorsChanged event.
+        // Trigger an initial onCollaboratorsChanged event.
         this._onCollaboratorsChanged();
       });
     }
@@ -141,8 +141,8 @@ class FileEditor extends CodeEditorWrapper {
   }
 
   private _onCollaboratorsChanged(): void {
-    //if there are selections corresponding to non-collaborators,
-    //they are stale and should be removed.
+    // If there are selections corresponding to non-collaborators,
+    // they are stale and should be removed.
     for (let key of this.editor.model.selections.keys()) {
       if (!this._context.model.modelDB.collaborators.has(key)) {
         this.editor.model.selections.delete(key);

+ 1 - 1
packages/notebook/src/widget.ts

@@ -964,7 +964,7 @@ class Notebook extends StaticNotebook {
       let modelDB = this.model.modelDB;
       modelDB.connected.then(() => {
         if (!cell.isDisposed) {
-          //Setup the selection style for collaborators
+          // Setup the selection style for collaborators.
           let localCollaborator = modelDB.collaborators.localCollaborator;
           cell.editor.uuid = localCollaborator.sessionId;
           cell.editor.selectionStyle = {