(chore): update codebase

This commit is contained in:
Alois 2026-05-01 19:57:03 +02:00
commit 4e8d46b20e
106 changed files with 29936 additions and 1023 deletions

View file

@ -16,7 +16,7 @@
"@codemirror/commands": "^6.10.2",
"@codemirror/lang-markdown": "^6.5.0",
"@codemirror/state": "^6.5.4",
"@codemirror/view": "^6.39.15",
"@codemirror/view": "^6.41.1",
"@tensamin/ui": "*",
"react": "^19.2.0",
"react-dom": "^19.2.0"

View file

@ -13,6 +13,7 @@ import {
placeholder,
ViewPlugin,
type DecorationSet,
type KeyBinding,
type ViewUpdate,
} from "@codemirror/view";
import {
@ -159,6 +160,12 @@ function createEditorExtensions(
getInvertEnterBehavior: () => boolean,
onSubmit: () => void,
): Extension[] {
const editorKeymap = [
...defaultKeymap,
...historyKeymap,
indentWithTab,
] as unknown as readonly KeyBinding[];
const customEnterKeymap = keymap.of([
{
key: "Shift-Enter",
@ -187,7 +194,7 @@ function createEditorExtensions(
return [
history(),
markdown(),
keymap.of([...defaultKeymap, ...historyKeymap, indentWithTab]),
keymap.of(editorKeymap),
Prec.highest(customEnterKeymap),
EditorView.lineWrapping,
placeholder(getPlaceholder() ?? ""),