Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for vim mode in Text Editor #90

Merged
merged 2 commits into from
Jul 31, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@
"@jupyterlab/application": "^4.0.3",
"@jupyterlab/cells": "^4.0.3",
"@jupyterlab/codemirror": "^4.0.3",
"@jupyterlab/fileeditor": "^4.0.3",
"@jupyterlab/notebook": "^4.0.3",
"@jupyterlab/settingregistry": "^4.0.3",
"@lumino/commands": "^2.0.1",
Expand All @@ -74,6 +75,7 @@
"@codemirror/language": "^6.8.0",
"@codemirror/search": "^6.5.0",
"@jupyterlab/builder": "^4.0.0",
"@jupyterlab/codeeditor": "^4.0.3",
"@types/codemirror": "^0.0.87",
"@types/json-schema": "^7.0.11",
"@types/react": "^18.0.26",
Expand Down
33 changes: 32 additions & 1 deletion schema/plugin.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,31 @@
"selector": ".jp-Notebook.jp-mod-editMode",
"disabled": true
},
{
"command": "vim:enter-normal-mode",
"keys": ["Escape"],
"selector": ".jp-FileEditor"
},
{
"command": "documentsearch:end",
"keys": ["Escape"],
"selector": ".jp-mod-searchable .jp-FileEditor .cm-vimMode"
},
{
"command": "documentsearch:end",
"keys": ["Escape"],
"selector": ".jp-mod-searchable .jp-Notebook .cm-vimMode"
},
{
"command": "documentsearch:end",
"keys": ["Escape"],
"selector": ".jp-mod-search-active .jp-FileEditor .cm-vimMode"
},
{
"command": "documentsearch:end",
"keys": ["Escape"],
"selector": ".jp-mod-search-active .jp-Notebook .cm-vimMode"
},
{
"selector": ".jp-NotebookPanel[data-jp-vim-mode='true'] .jp-Notebook.jp-mod-editMode",
"keys": ["Ctrl O", "U"],
Expand Down Expand Up @@ -256,7 +281,13 @@
"enabled": {
"type": "boolean",
"title": "Enabled",
"description": "Enable/disable notebook vim (may require a page refresh)",
"description": "Enable/disable vim extension (may require a page refresh)",
"default": true
},
"enabledInEditors": {
"type": "boolean",
"title": "Enabled in Text Editor",
"description": "Enable/disable vim in text editors (may require a page refresh)",
"default": true
},
"extraKeybindings": {
Expand Down
Loading