import { Edit, EditShape } from "../model/Edit.js"; import { EditionOp } from "./draft.js"; import { Edition } from "../model/Edition.js"; /** * A guess at the shape of an edit, from the symbols it exchanges and * from the systems the version and the one it is based on are coded * for, or nothing where it takes no shape the guess knows. It looks at * the edit alone: a single expression deleted is taken for a redundancy * removed, which `proposeEdits` checks against the text. * @category Lookups */ export declare const shapeOf: (edition: Edition, versionId: string, edit: Readonly) => EditShape | undefined; /** * Replaces the edits with a single one carrying all their insertions * and deletions. It keeps the first motivation of the editor's that any * of them states, and where none does, it has the one its shape calls * for (`motivationProposedFor`), so that a merge says it is a musical * or a technical change, unless the version derives from none. A * grouping that says no more is the program's by rule * (`isCollationsOwn`), until the editor says why it was made. * @category Operations */ export declare const mergeEdits: (versionId: string, toMerge: readonly Edit[]) => EditionOp; /** * Replaces the edit with one edit per inserted and one per deleted * symbol. Each part keeps the motivation of the edit, since splitting * an edit does not change why it was made. * @category Operations */ export declare const splitEdit: (versionId: string, toSplit: Edit) => EditionOp;