import { WMermaidNodeView } from "./MermaidNodeView/index.js";
import { MermaidSpecs } from "./MermaidSpecs/index.js";
import { MermaidAction } from "./MermaidSpecs/const.js";
import { addMermaid } from "./actions.js";
export const Mermaid = (builder, options) => {
    builder.use(MermaidSpecs, {
        nodeView: MermaidNodeViewFactory(options),
    });
    builder.addAction(MermaidAction, () => addMermaid);
};
const MermaidNodeViewFactory = (options) => () => (node, view, getPos) => {
    return new WMermaidNodeView(node, view, getPos, options);
};
//# sourceMappingURL=index.js.map
