Restore previous codemirror tab behavior (#8461)

* Restore previous tab behavior

* Handle via ondemand logic

* Combine imports
This commit is contained in:
Philip Allgaier
2021-02-25 22:24:07 +01:00
committed by GitHub
parent f44d867d3a
commit 2f7f677549
2 changed files with 9 additions and 2 deletions

View File

@@ -131,7 +131,14 @@ export class HaCodeEditor extends UpdatingElement {
loaded.lineNumbers(),
loaded.keymap.of([
...loaded.defaultKeymap,
loaded.defaultTabBinding,
{
key: "Tab",
run: loaded.indentMore,
},
{
key: "Shift-Tab",
run: loaded.indentLess,
},
saveKeyBinding,
]),
loaded.tagExtension(modeTag, this._mode),