mirror of
https://github.com/zadam/trilium.git
synced 2025-12-24 00:59:55 +01:00
fix(code): reintroduce indent with tab
This commit is contained in:
@@ -1,5 +1,5 @@
|
|||||||
import { defaultKeymap } from "@codemirror/commands";
|
import { defaultKeymap, indentWithTab } from "@codemirror/commands";
|
||||||
import { EditorView, keymap, lineNumbers, ViewUpdate, type EditorViewConfig } from "@codemirror/view";
|
import { EditorView, keymap, lineNumbers, ViewUpdate, type EditorViewConfig, type KeyBinding } from "@codemirror/view";
|
||||||
|
|
||||||
type ContentChangedListener = () => void;
|
type ContentChangedListener = () => void;
|
||||||
|
|
||||||
@@ -13,7 +13,10 @@ export default class CodeMirror extends EditorView {
|
|||||||
|
|
||||||
constructor(config: EditorConfig) {
|
constructor(config: EditorConfig) {
|
||||||
let extensions = [
|
let extensions = [
|
||||||
keymap.of(defaultKeymap),
|
keymap.of([
|
||||||
|
...defaultKeymap,
|
||||||
|
indentWithTab
|
||||||
|
]),
|
||||||
lineNumbers()
|
lineNumbers()
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user