You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
diff --git a/packages/app-cli/tests/support/plugins/codemirror6/src/contentScript.ts b/packages/app-cli/tests/support/plugins/codemirror6/src/contentScript.ts
index af0532dcf..3a816a16c 100644
--- a/packages/app-cli/tests/support/plugins/codemirror6/src/contentScript.ts+++ b/packages/app-cli/tests/support/plugins/codemirror6/src/contentScript.ts@@ -47,7 +47,7 @@ export default (_context: ContentScriptContext): CodeMirrorContentScriptModule =
// We can also register editor commands. These commands can be later executed with:
// joplin.commands.execute('editor.execCommand', { name: 'name-here', args: [] })
- codeMirrorWrapper.registerCommand('wrap-selection-with-tag', (tagName: string) => {+ (codeMirrorWrapper as any).defineExtension('wrap-selection-with-tag', (tagName: string) => {
const editor: EditorView = codeMirrorWrapper.editor;
// See https://codemirror.net/examples/change/
Build and add the CodeMirror 6 demo plugin (packages/app-cli/tests/support/plugins/codemirror6/) as a development plugin.
Verify that running :underline from the command palette works.
Open settings
Close settings
Verify that running :underline from the command palette no longer works.
Expected behaviour
Currently, CodeMirror5Emulation.defineExtension only works if the extension is not already present. This is different from the behavior of .defineExtension in CodeMirror 5, which overrides previous extension values.
Operating system
Linux
Joplin version
2.14.16
Desktop version info
No response
Current behaviour
packages/app-cli/tests/support/plugins/codemirror6/
) as a development plugin.:underline
from the command palette works.:underline
from the command palette no longer works.Expected behaviour
Currently,
CodeMirror5Emulation.defineExtension
only works if the extension is not already present. This is different from the behavior of.defineExtension
in CodeMirror 5, which overrides previous extension values.Note: This is breaking a downstream pull request in some cases.
Logs
No response
The text was updated successfully, but these errors were encountered: