// editor-entry.js — the editor bundle's entry (spec §6.2). Loaded as a // module, so deferred, only on pages the viewer may edit; it mounts the // editor on the page's
(page.mjs). The fidelity layer is // exported too, for the gates and for a look from the console. import { createSchema } from './schema.mjs' import { start } from './page.mjs' export { createSchema } export { fromMarkdown } from './fromMarkdown.mjs' export { serialise, serialiseDetailed, structureCheck, docBlocks } from './serialize.mjs' export { Fidelity, mount, recordBody, rebuild, applyBody, prepareSave, reparse, settle, fidelityPlugin, fidelityKey } from './fidelity.mjs' export { clipboardPlugin, copyData, pasteTransaction, textSlice, mapaType } from './clipboard.mjs' export const schema = createSchema() // The page's editor, once mounted: the gates read it. export const editor = typeof document === 'undefined' ? null : start() if (editor) globalThis.mapaEditor = editor