New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@jupyterlab/codemirror-extension

Package Overview
Dependencies
Maintainers
6
Versions
391
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@jupyterlab/codemirror-extension - npm Package Compare versions

Comparing version 0.9.0 to 0.10.0

42

lib/index.js

@@ -27,2 +27,4 @@ "use strict";

CommandIDs.changeMode = 'codemirror:change-mode';
CommandIDs.find = 'codemirror:find';
CommandIDs.findAndReplace = 'codemirror:find-and-replace';
})(CommandIDs || (CommandIDs = {}));

@@ -156,9 +158,33 @@ ;

});
commands.addCommand(CommandIDs.find, {
label: 'Find',
execute: function () {
var widget = tracker.currentWidget;
if (!widget) {
return;
}
var editor = widget.editor;
editor.execCommand('find');
},
isEnabled: hasWidget
});
commands.addCommand(CommandIDs.findAndReplace, {
label: 'Find & Replace',
execute: function () {
var widget = tracker.currentWidget;
if (!widget) {
return;
}
var editor = widget.editor;
editor.execCommand('replace');
},
isEnabled: hasWidget
});
commands.addCommand(CommandIDs.changeMode, {
label: function (args) { return args['name']; },
execute: function (args) {
var mode = args['mode'];
var name = args['name'];
var widget = tracker.currentWidget;
if (mode && widget) {
var spec = codemirror_1.Mode.findByName(mode);
if (name && widget) {
var spec = codemirror_1.Mode.findByName(name);
if (spec) {

@@ -177,4 +203,4 @@ widget.model.mimeType = spec.mime;

var spec = codemirror_1.Mode.findByMIME(mime);
var mode = spec && spec.mode;
return args['mode'] === mode;
var name = spec && spec.name;
return args['name'] === name;
}

@@ -187,2 +213,6 @@ });

}).forEach(function (spec) {
// Avoid mode name with a curse word.
if (spec.mode.indexOf('brainf') === 0) {
return;
}
modeMenu.addItem({

@@ -223,2 +253,4 @@ command: CommandIDs.changeMode,

menu.addItem({ type: 'submenu', submenu: tabMenu });
menu.addItem({ command: CommandIDs.find });
menu.addItem({ command: CommandIDs.findAndReplace });
menu.addItem({ type: 'separator' });

@@ -225,0 +257,0 @@ menu.addItem({ command: 'fileeditor:toggle-line-numbers' });

19

package.json
{
"name": "@jupyterlab/codemirror-extension",
"version": "0.9.0",
"version": "0.10.0",
"description": "JupyterLab - CodeMirror Provider Extension",

@@ -16,8 +16,9 @@ "main": "lib/index.js",

"dependencies": {
"@jupyterlab/application": "^0.9.0",
"@jupyterlab/apputils": "^0.9.0",
"@jupyterlab/coreutils": "^0.9.0",
"@jupyterlab/codeeditor": "^0.9.0",
"@jupyterlab/codemirror": "^0.9.0",
"@jupyterlab/fileeditor": "^0.9.0",
"@jupyterlab/application": "^0.10.0",
"@jupyterlab/apputils": "^0.10.0",
"@jupyterlab/coreutils": "^0.10.0",
"@jupyterlab/codeeditor": "^0.10.0",
"@jupyterlab/codemirror": "^0.10.0",
"@jupyterlab/fileeditor": "^0.10.0",
"@phosphor/coreutils": "^1.2.0",
"@phosphor/widgets": "^1.3.0"

@@ -36,5 +37,3 @@ },

"extension": true,
"schemas": [
"schema/jupyter.services.codemirror-commands.json"
]
"schemaDir": "schema"
},

@@ -41,0 +40,0 @@ "repository": {

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc