diff --git a/services/web/frontend/js/features/source-editor/extensions/keybindings.ts b/services/web/frontend/js/features/source-editor/extensions/keybindings.ts index d4e3e772d8..02544251e1 100644 --- a/services/web/frontend/js/features/source-editor/extensions/keybindings.ts +++ b/services/web/frontend/js/features/source-editor/extensions/keybindings.ts @@ -8,6 +8,7 @@ import { import { EmacsHandler } from '@replit/codemirror-emacs' import { CodeMirror } from '@replit/codemirror-vim' import { foldCode, toggleFold, unfoldCode } from '@codemirror/language' +import { EditorView } from '@codemirror/view' import { cursorToBeginningOfVisualLine, cursorToEndOfVisualLine, @@ -174,7 +175,16 @@ const options = [ load: () => import('@replit/codemirror-emacs').then(m => { customiseEmacsOnce() - return m.emacs() + return [ + m.emacs(), + EditorView.domEventHandlers({ + keydown(event) { + if (event.ctrlKey && event.key === 's') { + event.stopPropagation() + } + }, + }), + ] }), }, ]