diff --git a/frontend/src/components/NoteEditor.vue b/frontend/src/components/NoteEditor.vue index c41f7ec..f8cc462 100644 --- a/frontend/src/components/NoteEditor.vue +++ b/frontend/src/components/NoteEditor.vue @@ -10,6 +10,14 @@ import { takeMorphOrigin } from "../composables/useEditorMorph"; import { prefersReducedMotion } from "../composables/useReducedMotion"; import type { Note, NoteLabel, NoteRevision } from "../stores/notes"; import { LABEL_CHIP_CLASSES, type NoteColor } from "../notes/colors"; +import { + afterEnter, + type EditorBlock, + joinBlocks, + plusTask, + splitBlocks, + withoutIndex, +} from "../notes/blocks"; // One modal editor for BOTH composing and editing — a single surface (the board's // "Take a note…" bar just opens this in compose mode). `note` = the note being edited, @@ -24,7 +32,14 @@ const emit = defineEmits<{ (e: "close"): void; (e: "navigate", id: string): void const notes = useNotesStore(); const noteId = ref(props.note?.id ?? null); -const body = ref(props.note?.body ?? props.initialBody); +// BLOCKS rather than one string, because a checklist item is drawn as a real checkbox +// and a widget cannot live inside a