1/** 2 * @factory/editor — the inline rich-text extension factory. 3 * 4 * `factoryEditorExtensions()` is the single import the apps/web per-block 5 * Tiptap editors (e.g. `components/editor/inline-editor.tsx`) need for the 6 * Factory-specific inline vocabulary: 7 * 8 * extensions: [ 9 * StarterKit, …, 10 * ...factoryEditorExtensions() // mention, equation, highlight 11 * ] 12 * 13 * Ordering note: the web spreads this array LAST so these definitions win 14 * over any StarterKit conflict. All extensions are registered by unique 15 * names (`factory*`) so they never shadow StarterKit. The block-canvas 16 * kernel (codec/autosave/slash/menus) lives at the package root — see 17 * `@factory/editor`'s index — and is consumed by the canvas wiring, not by 18 * the inline editors. 19 */ 20 21import type { AnyExtension } from "@tiptap/core"; 22 23import { EquationNode } from "./nodes/equation.js"; 24import { InlineAtomNode } from "./nodes/inline-atom.js"; 25import { MentionNode } from "./nodes/mention.js"; 26import { HighlightMark } from "./marks/highlight.js"; 27 28/** The Factory inline extensions (mention chips, inline math, highlight, atoms). */ 29export function factoryEditorExtensions(): AnyExtension[] { 30 return [MentionNode, EquationNode, HighlightMark, InlineAtomNode]; 31} 32