Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
@blocknote/ariakit
@blocknote/code-block
@blocknote/core
@blocknote/mantine
@blocknote/react
@blocknote/server-util
@blocknote/shadcn
@blocknote/xl-ai
@blocknote/xl-docx-exporter
@blocknote/xl-email-exporter
@blocknote/xl-multi-column
@blocknote/xl-odt-exporter
@blocknote/xl-pdf-exporter
commit: |
| import { createStore, StoreApi } from "zustand/vanilla"; | ||
|
|
||
| import { | ||
| aiDocumentFormats, | ||
| buildAIRequest, | ||
| defaultAIRequestSender, | ||
| executeAIRequest, | ||
| } from "./api/index.js"; | ||
| import { createAgentCursorPlugin } from "./plugins/AgentCursorPlugin.js"; | ||
| import { AIRequestHelpers, InvokeAIOptions } from "./types.js"; | ||
|
|
||
| type ReadonlyStoreApi<T> = Pick< | ||
| StoreApi<T>, |
There was a problem hiding this comment.
Why wrap in an editor.onCreate? I'm actually uncertain that onCreate gets invoked right now, does it? Is it on mount?
There was a problem hiding this comment.
The underlying TipTap editor is undefined when the extension constructor is run, and so an error gets thrown attempting to call tiptapEditor.on("update", ...) (within editor.onChange(...)). Wrapping it in editor.onCreate fixes this. Maybe onMount would be better than onCreate? Any way that that we can ensure the TipTap editor is already initialized.
There was a problem hiding this comment.
We need to fix this then, because I don't think this is a great pattern
… into ai-menu-auto-scroll
No description provided.